dweb-transports/dist/dweb-transports-bundle.js

512 lines
3.6 MiB
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

!function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var i in e)n.d(r,i,function(t){return e[t]}.bind(null,i));return r},n.n=function(e){var t=e&&e.__esModule?function t(){return e.default}:function t(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=639)}([function(e,t,n){"use strict";(function(e){
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/
var r=n(644),i=n(325),o=n(49);function s(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function l(e,t){if(a()<t)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t),e.__proto__=u.prototype):(null===e&&(e=new u(t)),e.length=t),e}function u(e,t,n){if(!(u.TYPED_ARRAY_SUPPORT||this instanceof u))return new u(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return p(this,e)}return c(this,e,t,n)}function c(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?g(e,t,n,r):"string"==typeof t?d(e,t,n):y(e,t)}function h(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t,n,r){return h(t),t<=0?l(e,t):void 0!==n?"string"==typeof r?l(e,t).fill(n,r):l(e,t).fill(n):l(e,t)}function p(e,t){if(h(t),e=l(e,t<0?0:0|v(t)),!u.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function d(e,t,n){if("string"==typeof n&&""!==n||(n="utf8"),!u.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|_(t,n);e=l(e,r);var i=e.write(t,n);return i!==r&&(e=e.slice(0,i)),e}function m(e,t){var n=t.length<0?0:0|v(t.length);e=l(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function g(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");return t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r),u.TYPED_ARRAY_SUPPORT?(e=t,e.__proto__=u.prototype):e=m(e,t),e}function y(e,t){if(u.isBuffer(t)){var n=0|v(t.length);return e=l(e,n),0===e.length?e:(t.copy(e,0,0,n),e)}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||te(t.length)?l(e,0):m(e,t);if("Buffer"===t.type&&o(t.data))return m(e,t.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}function v(e){if(e>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function b(e){return+e!=e&&(e=0),u.alloc(+e)}function _(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return Z(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return X(e).length;default:if(r)return Z(e).length;t=(""+t).toLowerCase(),r=!0}}function w(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if(n>>>=0,t>>>=0,n<=t)return"";for(e||(e="utf8");;)switch(e){case"hex":return M(this,t,n);case"utf8":case"utf-8":return B(this,t,n);case"ascii":return N(this,t,n);case"latin1":case"binary":return D(this,t,n);case"base64":return R(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function k(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function E(e,t,n,r,i){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return-1;n=e.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:S(e,t,n,r,i);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):S(e,[t],n,r,i);throw new TypeError("val must be string, number or Buffer")}function S(e,t,n,r,i){var o=1,s=e.length,a=t.length,l;if(void 0!==r&&(r=String(r).toLowerCase(),"ucs2"===r||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;o=2,s/=2,a/=2,n/=2}function u(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(i){var c=-1;for(l=n;l<s;l++)if(u(e,l)===u(t,-1===c?0:l-c)){if(-1===c&&(c=l),l-c+1===a)return c*o}else-1!==c&&(l-=l-c),c=-1}else for(n+a>s&&(n=s-a),l=n;l>=0;l--){for(var h=!0,f=0;f<a;f++)if(u(e,l+f)!==u(t,f)){h=!1;break}if(h)return l}return-1}function x(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;var o=t.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var s=0;s<r;++s){var a=parseInt(t.substr(2*s,2),16);if(isNaN(a))return s;e[n+s]=a}return s}function C(e,t,n,r){return ee(Z(t,e.length-n),e,n,r)}function A(e,t,n,r){return ee(J(t),e,n,r)}function T(e,t,n,r){return A(e,t,n,r)}function I(e,t,n,r){return ee(X(t),e,n,r)}function j(e,t,n,r){return ee(Q(t,e.length-n),e,n,r)}function R(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function B(e,t,n){n=Math.min(e.length,n);for(var r=[],i=t;i<n;){var o=e[i],s=null,a=o>239?4:o>223?3:o>191?2:1,l,u,c,h;if(i+a<=n)switch(a){case 1:o<128&&(s=o);break;case 2:l=e[i+1],128==(192&l)&&(h=(31&o)<<6|63&l,h>127&&(s=h));break;case 3:l=e[i+1],u=e[i+2],128==(192&l)&&128==(192&u)&&(h=(15&o)<<12|(63&l)<<6|63&u,h>2047&&(h<55296||h>57343)&&(s=h));break;case 4:l=e[i+1],u=e[i+2],c=e[i+3],128==(192&l)&&128==(192&u)&&128==(192&c)&&(h=(15&o)<<18|(63&l)<<12|(63&u)<<6|63&c,h>65535&&h<1114112&&(s=h))}null===s?(s=65533,a=1):s>65535&&(s-=65536,r.push(s>>>10&1023|55296),s=56320|1023&s),r.push(s),i+=a}return P(r)}t.Buffer=u,t.SlowBuffer=b,t.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:s(),t.kMaxLength=a(),u.poolSize=8192,u._augment=function(e){return e.__proto__=u.prototype,e},u.from=function(e,t,n){return c(null,e,t,n)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(e,t,n){return f(null,e,t,n)},u.allocUnsafe=function(e){return p(null,e)},u.allocUnsafeSlow=function(e){return p(null,e)},u.isBuffer=function e(t){return!(null==t||!t._isBuffer)},u.compare=function e(t,n){if(!u.isBuffer(t)||!u.isBuffer(n))throw new TypeError("Arguments must be Buffers");if(t===n)return 0;for(var r=t.length,i=n.length,o=0,s=Math.min(r,i);o<s;++o)if(t[o]!==n[o]){r=t[o],i=n[o];break}return r<i?-1:i<r?1:0},u.isEncoding=function e(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function e(t,n){if(!o(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return u.alloc(0);var r;if(void 0===n)for(n=0,r=0;r<t.length;++r)n+=t[r].length;var i=u.allocUnsafe(n),s=0;for(r=0;r<t.length;++r){var a=t[r];if(!u.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(i,s),s+=a.length}return i},u.byteLength=_,u.prototype._isBuffer=!0,u.prototype.swap16=function e(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var n=0;n<t;n+=2)k(this,n,n+1);return this},u.prototype.swap32=function e(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var n=0;n<t;n+=4)k(this,n,n+3),k(this,n+1,n+2);return this},u.prototype.swap64=function e(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var n=0;n<t;n+=8)k(this,n,n+7),k(this,n+1,n+6),k(this,n+2,n+5),k(this,n+3,n+4);return this},u.prototype.toString=function e(){var t=0|this.length;return 0===t?"":0===arguments.length?B(this,0,t):w.apply(this,arguments)},u.prototype.equals=function e(t){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===u.compare(this,t)},u.prototype.inspect=function e(){var n="",r=t.INSPECT_MAX_BYTES;return this.length>0&&(n=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(n+=" ... ")),"<Buffer "+n+">"},u.prototype.compare=function e(t,n,r,i,o){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===n&&(n=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===o&&(o=this.length),n<0||r>t.length||i<0||o>this.length)throw new RangeError("out of range index");if(i>=o&&n>=r)return 0;if(i>=o)return-1;if(n>=r)return 1;if(n>>>=0,r>>>=0,i>>>=0,o>>>=0,this===t)return 0;for(var s=o-i,a=r-n,l=Math.min(s,a),c=this.slice(i,o),h=t.slice(n,r),f=0;f<l;++f)if(c[f]!==h[f]){s=c[f],a=h[f];break}return s<a?-1:a<s?1:0},u.prototype.includes=function e(t,n,r){return-1!==this.indexOf(t,n,r)},u.prototype.indexOf=function e(t,n,r){return E(this,t,n,r,!0)},u.prototype.lastIndexOf=function e(t,n,r){return E(this,t,n,r,!1)},u.prototype.write=function e(t,n,r,i){if(void 0===n)i="utf8",r=this.length,n=0;else if(void 0===r&&"string"==typeof n)i=n,r=this.length,n=0;else{if(!isFinite(n))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");n|=0,isFinite(r)?(r|=0,void 0===i&&(i="utf8")):(i=r,r=void 0)}var o=this.length-n;if((void 0===r||r>o)&&(r=o),t.length>0&&(r<0||n<0)||n>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var s=!1;;)switch(i){case"hex":return x(this,t,n,r);case"utf8":case"utf-8":return C(this,t,n,r);case"ascii":return A(this,t,n,r);case"latin1":case"binary":return T(this,t,n,r);case"base64":return I(this,t,n,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return j(this,t,n,r);default:if(s)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),s=!0}},u.prototype.toJSON=function e(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var O=4096;function P(e){var t=e.length;if(t<=O)return String.fromCharCode.apply(String,e);for(var n="",r=0;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=O));return n}function N(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(127&e[i]);return r}function D(e,t,n){var r="";n=Math.min(e.length,n);for(var i=t;i<n;++i)r+=String.fromCharCode(e[i]);return r}function M(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=t;o<n;++o)i+=Y(e[o]);return i}function F(e,t,n){for(var r=e.slice(t,n),i="",o=0;o<r.length;o+=2)i+=String.fromCharCode(r[o]+256*r[o+1]);return i}function L(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function U(e,t,n,r,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||t<o)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function q(e,t,n,r){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-n,2);i<o;++i)e[n+i]=(t&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function z(e,t,n,r){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-n,4);i<o;++i)e[n+i]=t>>>8*(r?i:3-i)&255}function K(e,t,n,r,i,o){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function H(e,t,n,r,o){return o||K(e,t,n,4,3.4028234663852886e38,-3.4028234663852886e38),i.write(e,t,n,r,23,4),n+4}function V(e,t,n,r,o){return o||K(e,t,n,8,1.7976931348623157e308,-1.7976931348623157e308),i.write(e,t,n,r,52,8),n+8}u.prototype.slice=function e(t,n){var r=this.length,i;if(t=~~t,n=void 0===n?r:~~n,t<0?(t+=r,t<0&&(t=0)):t>r&&(t=r),n<0?(n+=r,n<0&&(n=0)):n>r&&(n=r),n<t&&(n=t),u.TYPED_ARRAY_SUPPORT)i=this.subarray(t,n),i.__proto__=u.prototype;else{var o=n-t;i=new u(o,void 0);for(var s=0;s<o;++s)i[s]=this[s+t]}return i},u.prototype.readUIntLE=function e(t,n,r){t|=0,n|=0,r||L(t,n,this.length);for(var i=this[t],o=1,s=0;++s<n&&(o*=256);)i+=this[t+s]*o;return i},u.prototype.readUIntBE=function e(t,n,r){t|=0,n|=0,r||L(t,n,this.length);for(var i=this[t+--n],o=1;n>0&&(o*=256);)i+=this[t+--n]*o;return i},u.prototype.readUInt8=function e(t,n){return n||L(t,1,this.length),this[t]},u.prototype.readUInt16LE=function e(t,n){return n||L(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUInt16BE=function e(t,n){return n||L(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUInt32LE=function e(t,n){return n||L(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUInt32BE=function e(t,n){return n||L(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readIntLE=function e(t,n,r){t|=0,n|=0,r||L(t,n,this.length);for(var i=this[t],o=1,s=0;++s<n&&(o*=256);)i+=this[t+s]*o;return o*=128,i>=o&&(i-=Math.pow(2,8*n)),i},u.prototype.readIntBE=function e(t,n,r){t|=0,n|=0,r||L(t,n,this.length);for(var i=n,o=1,s=this[t+--i];i>0&&(o*=256);)s+=this[t+--i]*o;return o*=128,s>=o&&(s-=Math.pow(2,8*n)),s},u.prototype.readInt8=function e(t,n){return n||L(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function e(t,n){n||L(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function e(t,n){n||L(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function e(t,n){return n||L(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function e(t,n){return n||L(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readFloatLE=function e(t,n){return n||L(t,4,this.length),i.read(this,t,!0,23,4)},u.prototype.readFloatBE=function e(t,n){return n||L(t,4,this.length),i.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function e(t,n){return n||L(t,8,this.length),i.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function e(t,n){return n||L(t,8,this.length),i.read(this,t,!1,52,8)},u.prototype.writeUIntLE=function e(t,n,r,i){if(t=+t,n|=0,r|=0,!i){var o=Math.pow(2,8*r)-1;U(this,t,n,r,o,0)}var s=1,a=0;for(this[n]=255&t;++a<r&&(s*=256);)this[n+a]=t/s&255;return n+r},u.prototype.writeUIntBE=function e(t,n,r,i){if(t=+t,n|=0,r|=0,!i){var o=Math.pow(2,8*r)-1;U(this,t,n,r,o,0)}var s=r-1,a=1;for(this[n+s]=255&t;--s>=0&&(a*=256);)this[n+s]=t/a&255;return n+r},u.prototype.writeUInt8=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,1,255,0),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[n]=255&t,n+1},u.prototype.writeUInt16LE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):q(this,t,n,!0),n+2},u.prototype.writeUInt16BE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):q(this,t,n,!1),n+2},u.prototype.writeUInt32LE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[n+3]=t>>>24,this[n+2]=t>>>16,this[n+1]=t>>>8,this[n]=255&t):z(this,t,n,!0),n+4},u.prototype.writeUInt32BE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):z(this,t,n,!1),n+4},u.prototype.writeIntLE=function e(t,n,r,i){if(t=+t,n|=0,!i){var o=Math.pow(2,8*r-1);U(this,t,n,r,o-1,-o)}var s=0,a=1,l=0;for(this[n]=255&t;++s<r&&(a*=256);)t<0&&0===l&&0!==this[n+s-1]&&(l=1),this[n+s]=(t/a>>0)-l&255;return n+r},u.prototype.writeIntBE=function e(t,n,r,i){if(t=+t,n|=0,!i){var o=Math.pow(2,8*r-1);U(this,t,n,r,o-1,-o)}var s=r-1,a=1,l=0;for(this[n+s]=255&t;--s>=0&&(a*=256);)t<0&&0===l&&0!==this[n+s+1]&&(l=1),this[n+s]=(t/a>>0)-l&255;return n+r},u.prototype.writeInt8=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,1,127,-128),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[n]=255&t,n+1},u.prototype.writeInt16LE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8):q(this,t,n,!0),n+2},u.prototype.writeInt16BE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[n]=t>>>8,this[n+1]=255&t):q(this,t,n,!1),n+2},u.prototype.writeInt32LE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[n]=255&t,this[n+1]=t>>>8,this[n+2]=t>>>16,this[n+3]=t>>>24):z(this,t,n,!0),n+4},u.prototype.writeInt32BE=function e(t,n,r){return t=+t,n|=0,r||U(this,t,n,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),u.TYPED_ARRAY_SUPPORT?(this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=255&t):z(this,t,n,!1),n+4},u.prototype.writeFloatLE=function e(t,n,r){return H(this,t,n,!0,r)},u.prototype.writeFloatBE=function e(t,n,r){return H(this,t,n,!1,r)},u.prototype.writeDoubleLE=function e(t,n,r){return V(this,t,n,!0,r)},u.prototype.writeDoubleBE=function e(t,n,r){return V(this,t,n,!1,r)},u.prototype.copy=function e(t,n,r,i){if(r||(r=0),i||0===i||(i=this.length),n>=t.length&&(n=t.length),n||(n=0),i>0&&i<r&&(i=r),i===r)return 0;if(0===t.length||0===this.length)return 0;if(n<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-n<i-r&&(i=t.length-n+r);var o=i-r,s;if(this===t&&r<n&&n<i)for(s=o-1;s>=0;--s)t[s+n]=this[s+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(s=0;s<o;++s)t[s+n]=this[s+r];else Uint8Array.prototype.set.call(t,this.subarray(r,r+o),n);return o},u.prototype.fill=function e(t,n,r,i){if("string"==typeof t){if("string"==typeof n?(i=n,n=0,r=this.length):"string"==typeof r&&(i=r,r=this.length),1===t.length){var o=t.charCodeAt(0);o<256&&(t=o)}if(void 0!==i&&"string"!=typeof i)throw new TypeError("encoding must be a string");if("string"==typeof i&&!u.isEncoding(i))throw new TypeError("Unknown encoding: "+i)}else"number"==typeof t&&(t&=255);if(n<0||this.length<n||this.length<r)throw new RangeError("Out of range index");if(r<=n)return this;var s;if(n>>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"==typeof t)for(s=n;s<r;++s)this[s]=t;else{var a=u.isBuffer(t)?t:Z(new u(t,i).toString()),l=a.length;for(s=0;s<r-n;++s)this[s+n]=a[s%l]}return this};var $=/[^+\/0-9A-Za-z-_]/g;function W(e){if(e=G(e).replace($,""),e.length<2)return"";for(;e.length%4!=0;)e+="=";return e}function G(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Y(e){return e<16?"0"+e.toString(16):e.toString(16)}function Z(e,t){var n;t=t||1/0;for(var r=e.length,i=null,o=[],s=0;s<r;++s){if(n=e.charCodeAt(s),n>55295&&n<57344){if(!i){if(n>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(s+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function J(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}function Q(e,t){for(var n,r,i,o=[],s=0;s<e.length&&!((t-=2)<0);++s)n=e.charCodeAt(s),r=n>>8,i=n%256,o.push(i),o.push(r);return o}function X(e){return r.toByteArray(W(e))}function ee(e,t,n,r){for(var i=0;i<r&&!(i+n>=t.length||i>=e.length);++i)t[i+n]=e[i];return i}function te(e){return e!=e}}).call(this,n(8))},function(e,t){"function"==typeof Object.create?e.exports=function e(t,n){n&&(t.super_=n,t.prototype=Object.create(n.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:e.exports=function e(t,n){if(n){t.super_=n;var r=function(){};r.prototype=n.prototype,t.prototype=new r,t.prototype.constructor=t}}},function(e,t,n){
/** PROMISIFY CALLBACK-STYLE FUNCTIONS TO ES6 PROMISES
*
* EXAMPLE:
* const fn = promisify( (callback) => callback(null, "Hello world!") );
* fn((err, str) => console.log(str));
* fn().then((str) => console.log(str));
* //Both functions, will log 'Hello world!'
*
* Note: The function you pass, may have any arguments you want, but the latest
* have to be the callback, which you will call with: next(err, value)
*
* @param method: Function/Array/Map = The function(s) to promisify
* @param options: Map =
* "context" (default is function): The context which to apply the called function
* "replace" (default is falsy): When passed an array/map, if to replace the original object
*
* @return: A promise if passed a function, otherwise the object with the promises
*
* @license: MIT
* @version: 1.0.3
* @author: Manuel Di Iorio
**/
var r=function(e,t){return function(){var n=Array.prototype.slice.call(arguments),r=n.length-1,i=n&&n.length>0?n[r]:null,o="function"==typeof i?i:null;return o?e.apply(t,n):new Promise(function(r,i){n.push(function(e,t){if(e)return i(e);r(t)}),e.apply(t,n)})}};e.exports=function(e,t){t=t||{};var n=Object.prototype.toString.call(e);if("[object Object]"===n||"[object Array]"===n){var i=t.replace?e:{};for(var o in e)e.hasOwnProperty(o)&&(i[o]=r(e[o]));return i}return r(e,t.context||e)}},function(e,t){var n=e.exports={},r,i;function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(e){if(r===setTimeout)return setTimeout(e,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(e,0);try{return r(e,0)}catch(t){try{return r.call(null,e,0)}catch(t){return r.call(this,e,0)}}}function l(e){if(i===clearTimeout)return clearTimeout(e);if((i===s||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(e);try{return i(e)}catch(t){try{return i.call(null,e)}catch(t){return i.call(this,e)}}}!function(){try{r="function"==typeof setTimeout?setTimeout:o}catch(e){r=o}try{i="function"==typeof clearTimeout?clearTimeout:s}catch(e){i=s}}();var u=[],c=!1,h,f=-1;function p(){c&&h&&(c=!1,h.length?u=h.concat(u):f=-1,u.length&&d())}function d(){if(!c){var e=a(p);c=!0;for(var t=u.length;t;){for(h=u,u=[];++f<t;)h&&h[f].run();f=-1,t=u.length}h=null,c=!1,l(e)}}function m(e,t){this.fun=e,this.array=t}function g(){}n.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];u.push(new m(e,t)),1!==u.length||c||a(d)},m.prototype.run=function(){this.fun.apply(null,this.array)},n.title="browser",n.browser=!0,n.env={},n.argv=[],n.version="",n.versions={},n.on=g,n.addListener=g,n.once=g,n.off=g,n.removeListener=g,n.removeAllListeners=g,n.emit=g,n.prependListener=g,n.prependOnceListener=g,n.listeners=function(e){return[]},n.binding=function(e){throw new Error("process.binding is not supported")},n.cwd=function(){return"/"},n.chdir=function(e){throw new Error("process.chdir is not supported")},n.umask=function(){return 0}},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),!this.useColors)return;const n="color: "+this.color;t.splice(1,0,n,"color: inherit");let r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,e=>{"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}function s(...e){return"object"==typeof console&&console.log&&console.log(...e)}function a(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function l(){let e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return localStorage}catch(e){}}t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage=u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(643)(t);const{formatters:c}=e.exports;c.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){var r=n(0),i=r.Buffer;function o(e,t){for(var n in e)t[n]=e[n]}function s(e,t,n){return i(e,t,n)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?e.exports=r:(o(r,t),t.Buffer=s),o(i,s),s.from=function(e,t,n){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,n)},s.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError("Argument must be a number");var r=i(e);return void 0!==t?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r},s.allocUnsafe=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return i(e)},s.allocUnsafeSlow=function(e){if("number"!=typeof e)throw new TypeError("Argument must be a number");return r.SlowBuffer(e)}},function(e,t,n){"use strict";var r="object"==typeof Reflect?Reflect:null,i=r&&"function"==typeof r.apply?r.apply:function e(t,n,r){return Function.prototype.apply.call(t,n,r)},o;function s(e){console&&console.warn&&console.warn(e)}o=r&&"function"==typeof r.ownKeys?r.ownKeys:Object.getOwnPropertySymbols?function e(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function e(t){return Object.getOwnPropertyNames(t)};var a=Number.isNaN||function e(t){return t!=t};function l(){l.init.call(this)}e.exports=l,l.EventEmitter=l,l.prototype._events=void 0,l.prototype._eventsCount=0,l.prototype._maxListeners=void 0;var u=10;function c(e){return void 0===e._maxListeners?l.defaultMaxListeners:e._maxListeners}function h(e,t,n,r){var i,o,a;if("function"!=typeof n)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof n);if(o=e._events,void 0===o?(o=e._events=Object.create(null),e._eventsCount=0):(void 0!==o.newListener&&(e.emit("newListener",t,n.listener?n.listener:n),o=e._events),a=o[t]),void 0===a)a=o[t]=n,++e._eventsCount;else if("function"==typeof a?a=o[t]=r?[n,a]:[a,n]:r?a.unshift(n):a.push(n),i=c(e),i>0&&a.length>i&&!a.warned){a.warned=!0;var l=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");l.name="MaxListenersExceededWarning",l.emitter=e,l.type=t,l.count=a.length,s(l)}return e}function f(){for(var e=[],t=0;t<arguments.length;t++)e.push(arguments[t]);this.fired||(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,i(this.listener,this.target,e))}function p(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=f.bind(r);return i.listener=n,r.wrapFn=i,i}function d(e,t,n){var r=e._events;if(void 0===r)return[];var i=r[t];return void 0===i?[]:"function"==typeof i?n?[i.listener||i]:[i]:n?v(i):g(i,i.length)}function m(e){var t=this._events;if(void 0!==t){var n=t[e];if("function"==typeof n)return 1;if(void 0!==n)return n.length}return 0}function g(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function y(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function v(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}Object.defineProperty(l,"defaultMaxListeners",{enumerable:!0,get:function(){return u},set:function(e){if("number"!=typeof e||e<0||a(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");u=e}}),l.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},l.prototype.setMaxListeners=function e(t){if("number"!=typeof t||t<0||a(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this},l.prototype.getMaxListeners=function e(){return c(this)},l.prototype.emit=function e(t){for(var n=[],r=1;r<arguments.length;r++)n.push(arguments[r]);var o="error"===t,s=this._events;if(void 0!==s)o=o&&void 0===s.error;else if(!o)return!1;if(o){var a;if(n.length>0&&(a=n[0]),a instanceof Error)throw a;var l=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw l.context=a,l}var u=s[t];if(void 0===u)return!1;if("function"==typeof u)i(u,this,n);else for(var c=u.length,h=g(u,c),r=0;r<c;++r)i(h[r],this,n);return!0},l.prototype.addListener=function e(t,n){return h(this,t,n,!1)},l.prototype.on=l.prototype.addListener,l.prototype.prependListener=function e(t,n){return h(this,t,n,!0)},l.prototype.once=function e(t,n){if("function"!=typeof n)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof n);return this.on(t,p(this,t,n)),this},l.prototype.prependOnceListener=function e(t,n){if("function"!=typeof n)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof n);return this.prependListener(t,p(this,t,n)),this},l.prototype.removeListener=function e(t,n){var r,i,o,s,a;if("function"!=typeof n)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof n);if(i=this._events,void 0===i)return this;if(r=i[t],void 0===r)return this;if(r===n||r.listener===n)0==--this._eventsCount?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit("removeListener",t,r.listener||n));else if("function"!=typeof r){for(o=-1,s=r.length-1;s>=0;s--)if(r[s]===n||r[s].listener===n){a=r[s].listener,o=s;break}if(o<0)return this;0===o?r.shift():y(r,o),1===r.length&&(i[t]=r[0]),void 0!==i.removeListener&&this.emit("removeListener",t,a||n)}return this},l.prototype.off=l.prototype.removeListener,l.prototype.removeAllListeners=function e(t){var n,r,i;if(r=this._events,void 0===r)return this;if(void 0===r.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==r[t]&&(0==--this._eventsCount?this._events=Object.create(null):delete r[t]),this;if(0===arguments.length){var o=Object.keys(r),s;for(i=0;i<o.length;++i)s=o[i],"removeListener"!==s&&this.removeAllListeners(s);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(n=r[t],"function"==typeof n)this.removeListener(t,n);else if(void 0!==n)for(i=n.length-1;i>=0;i--)this.removeListener(t,n[i]);return this},l.prototype.listeners=function e(t){return d(this,t,!0)},l.prototype.rawListeners=function e(t){return d(this,t,!1)},l.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):m.call(e,t)},l.prototype.listenerCount=m,l.prototype.eventNames=function e(){return this._eventsCount>0?o(this._events):[]}},function(e,t,n){(function(e){function n(e){return Array.isArray?Array.isArray(e):"[object Array]"===g(e)}function r(e){return"boolean"==typeof e}function i(e){return null===e}function o(e){return null==e}function s(e){return"number"==typeof e}function a(e){return"string"==typeof e}function l(e){return"symbol"==typeof e}function u(e){return void 0===e}function c(e){return"[object RegExp]"===g(e)}function h(e){return"object"==typeof e&&null!==e}function f(e){return"[object Date]"===g(e)}function p(e){return"[object Error]"===g(e)||e instanceof Error}function d(e){return"function"==typeof e}function m(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e}function g(e){return Object.prototype.toString.call(e)}t.isArray=n,t.isBoolean=r,t.isNull=i,t.isNullOrUndefined=o,t.isNumber=s,t.isString=a,t.isSymbol=l,t.isUndefined=u,t.isRegExp=c,t.isObject=h,t.isDate=f,t.isError=p,t.isFunction=d,t.isPrimitive=m,t.isBuffer=e.isBuffer}).call(this,n(0).Buffer)},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(60),o=n(115),s=n(95),a=n(707),l=n(39);class u{constructor(n,s,a){if(e.exports.isCID(n)){let e=n;return this.version=e.version,this.codec=e.codec,void(this.multihash=t.from(e.multihash))}if("string"==typeof n)if(i.isEncoded(n)){const e=i.decode(n);n=parseInt(e.slice(0,1).toString("hex"),16),s=o.getCodec(e.slice(1)),a=o.rmPrefix(e.slice(1))}else s="dag-pb",a=r.fromB58String(n),n=0;else if(t.isBuffer(n)){const e=n.slice(0,1),t=parseInt(e.toString("hex"),16);if(0===t||1===t){const e=n;n=t,s=o.getCodec(e.slice(1)),a=o.rmPrefix(e.slice(1))}else s="dag-pb",a=n,n=0}this.codec=s,this.version=n,this.multihash=a,u.validateCID(this)}get buffer(){let e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=t.concat([t.from("01","hex"),o.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}get prefix(){return t.concat([t.from(`0${this.version}`,"hex"),o.getCodeVarint(this.codec),r.prefix(this.multihash)])}toV0(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");const{name:e,length:t}=r.decode(this.multihash);if("sha2-256"!==e)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==t)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new c(0,this.codec,this.multihash)}toV1(){return new c(1,this.codec,this.multihash)}toBaseEncodedString(e){switch(e=e||"base58btc",this.version){case 0:if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");return r.toB58String(this.multihash);case 1:return i.encode(e,this.buffer).toString();default:throw new Error("Unsupported version")}}toString(e){return this.toBaseEncodedString(e)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}static validateCID(e){let t=a.checkCIDComponents(e);if(t)throw new Error(t)}}const c=l(u,{className:"CID",symbolName:"@ipld/js-cid/CID"});c.codecs=s,e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){if(t=(0,l.default)(t||s.default),!(0,i.default)(e))return t(new Error("First argument to waterfall must be an array of functions"));if(!e.length)return t();var n=0;function r(t){var r=(0,d.default)(e[n++]);t.push((0,f.default)(o)),r.apply(null,t)}function o(i){if(i||n===e.length)return t.apply(null,arguments);r((0,c.default)(arguments,1))}r([])};var r=n(65),i=m(r),o=n(58),s=m(o),a=n(183),l=m(a),u=n(86),c=m(u),h=n(107),f=m(h),p=n(37),d=m(p);function m(e){return e&&e.__esModule?e:{default:e}}e.exports=t.default},function(e,t,n){"use strict";(function(t){function n(e,n,r,i){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var o=arguments.length,s,a;switch(o){case 0:case 1:return t.nextTick(e);case 2:return t.nextTick(function t(){e.call(null,n)});case 3:return t.nextTick(function t(){e.call(null,n,r)});case 4:return t.nextTick(function t(){e.call(null,n,r,i)});default:for(s=new Array(o-1),a=0;a<s.length;)s[a++]=arguments[a];return t.nextTick(function t(){e.apply(null,s)})}}void 0===t||!t.version||0===t.version.indexOf("v0.")||0===t.version.indexOf("v1.")&&0!==t.version.indexOf("v1.8.")?e.exports={nextTick:n}:e.exports=t}).call(this,n(3))},function(e,t,n){"use strict";e.exports=function e(t){var n=arguments.length;if("function"==typeof t&&1===t.length){for(var r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return function(t){if(null==r)throw new TypeError("partial sink should only be called once!");var i=r;switch(r=null,n){case 1:return e(t,i[0]);case 2:return e(t,i[0],i[1]);case 3:return e(t,i[0],i[1],i[2]);case 4:return e(t,i[0],i[1],i[2],i[3]);default:return i.unshift(t),e.apply(null,i)}}}var o=t;o&&"function"==typeof o.source&&(o=o.source);for(var i=1;i<n;i++){var s=arguments[i];"function"==typeof s?o=s(o):s&&"object"==typeof s&&(s.sink(o),o=s.source)}return o}},function(e,t,n){"use strict";function r(e,t,n){var r=e instanceof Error?e:new Error(e),i;if("object"==typeof t?n=t:null!=t&&(r.code=t),n)for(i in n)r[i]=n[i];return r}e.exports=r},function(e,t,n){(function(e){var r=Object.getOwnPropertyDescriptors||function e(t){for(var n=Object.keys(t),r={},i=0;i<n.length;i++)r[n[i]]=Object.getOwnPropertyDescriptor(t,n[i]);return r},i=/%[sdj%]/g;t.format=function(e){if(!k(e)){for(var t=[],n=0;n<arguments.length;n++)t.push(a(arguments[n]));return t.join(" ")}for(var n=1,r=arguments,o=r.length,s=String(e).replace(i,function(e){if("%%"===e)return"%";if(n>=o)return e;switch(e){case"%s":return String(r[n++]);case"%d":return Number(r[n++]);case"%j":try{return JSON.stringify(r[n++])}catch(e){return"[Circular]"}default:return e}}),l=r[n];n<o;l=r[++n])b(l)||!C(l)?s+=" "+l:s+=" "+a(l);return s},t.deprecate=function(n,r){if(void 0!==e&&!0===e.noDeprecation)return n;if(void 0===e)return function(){return t.deprecate(n,r).apply(this,arguments)};var i=!1;function o(){if(!i){if(e.throwDeprecation)throw new Error(r);e.traceDeprecation?console.trace(r):console.error(r),i=!0}return n.apply(this,arguments)}return o};var o={},s;function a(e,n){var r={seen:[],stylize:u};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),v(n)?r.showHidden=n:n&&t._extend(r,n),S(r.showHidden)&&(r.showHidden=!1),S(r.depth)&&(r.depth=2),S(r.colors)&&(r.colors=!1),S(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=l),h(r,e,r.depth)}function l(e,t){var n=a.styles[t];return n?"["+a.colors[n][0]+"m"+e+"["+a.colors[n][1]+"m":e}function u(e,t){return e}function c(e){var t={};return e.forEach(function(e,n){t[e]=!0}),t}function h(e,n,r){if(e.customInspect&&n&&I(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var i=n.inspect(r,e);return k(i)||(i=h(e,i,r)),i}var o=f(e,n);if(o)return o;var s=Object.keys(n),a=c(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(n)),T(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return p(n);if(0===s.length){if(I(n)){var l=n.name?": "+n.name:"";return e.stylize("[Function"+l+"]","special")}if(x(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(A(n))return e.stylize(Date.prototype.toString.call(n),"date");if(T(n))return p(n)}var u="",v=!1,b=["{","}"],_;if(y(n)&&(v=!0,b=["[","]"]),I(n)){var w=n.name?": "+n.name:"";u=" [Function"+w+"]"}return x(n)&&(u=" "+RegExp.prototype.toString.call(n)),A(n)&&(u=" "+Date.prototype.toUTCString.call(n)),T(n)&&(u=" "+p(n)),0!==s.length||v&&0!=n.length?r<0?x(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special"):(e.seen.push(n),_=v?d(e,n,r,a,s):s.map(function(t){return m(e,n,r,a,t,v)}),e.seen.pop(),g(_,u,b)):b[0]+u+b[1]}function f(e,t){if(S(t))return e.stylize("undefined","undefined");if(k(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return w(t)?e.stylize(""+t,"number"):v(t)?e.stylize(""+t,"boolean"):b(t)?e.stylize("null","null"):void 0}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function d(e,t,n,r,i){for(var o=[],s=0,a=t.length;s<a;++s)N(t,String(s))?o.push(m(e,t,n,r,String(s),!0)):o.push("");return i.forEach(function(i){i.match(/^\d+$/)||o.push(m(e,t,n,r,i,!0))}),o}function m(e,t,n,r,i,o){var s,a,l;if(l=Object.getOwnPropertyDescriptor(t,i)||{value:t[i]},l.get?a=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(a=e.stylize("[Setter]","special")),N(r,i)||(s="["+i+"]"),a||(e.seen.indexOf(l.value)<0?(a=b(n)?h(e,l.value,null):h(e,l.value,n-1),a.indexOf("\n")>-1&&(a=o?a.split("\n").map(function(e){return" "+e}).join("\n").substr(2):"\n"+a.split("\n").map(function(e){return" "+e}).join("\n"))):a=e.stylize("[Circular]","special")),S(s)){if(o&&i.match(/^\d+$/))return a;s=JSON.stringify(""+i),s.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function g(e,t,n){var r=0,i=e.reduce(function(e,t){return r++,t.indexOf("\n")>=0&&r++,e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0);return i>60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}function y(e){return Array.isArray(e)}function v(e){return"boolean"==typeof e}function b(e){return null===e}function _(e){return null==e}function w(e){return"number"==typeof e}function k(e){return"string"==typeof e}function E(e){return"symbol"==typeof e}function S(e){return void 0===e}function x(e){return C(e)&&"[object RegExp]"===R(e)}function C(e){return"object"==typeof e&&null!==e}function A(e){return C(e)&&"[object Date]"===R(e)}function T(e){return C(e)&&("[object Error]"===R(e)||e instanceof Error)}function I(e){return"function"==typeof e}function j(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e}function R(e){return Object.prototype.toString.call(e)}function B(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(n){if(S(s)&&(s=e.env.NODE_DEBUG||""),n=n.toUpperCase(),!o[n])if(new RegExp("\\b"+n+"\\b","i").test(s)){var r=e.pid;o[n]=function(){var e=t.format.apply(t,arguments);console.error("%s %d: %s",n,r,e)}}else o[n]=function(){};return o[n]},t.inspect=a,a.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},a.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=y,t.isBoolean=v,t.isNull=b,t.isNullOrUndefined=_,t.isNumber=w,t.isString=k,t.isSymbol=E,t.isUndefined=S,t.isRegExp=x,t.isObject=C,t.isDate=A,t.isError=T,t.isFunction=I,t.isPrimitive=j,t.isBuffer=n(726);var O=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(){var e=new Date,t=[B(e.getHours()),B(e.getMinutes()),B(e.getSeconds())].join(":");return[e.getDate(),O[e.getMonth()],t].join(" ")}function N(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){console.log("%s - %s",P(),t.format.apply(t,arguments))},t.inherits=n(727),t._extend=function(e,t){if(!t||!C(t))return e;for(var n=Object.keys(t),r=n.length;r--;)e[n[r]]=t[n[r]];return e};var D="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function M(e,t){if(!e){var n=new Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}function F(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');function n(){for(var n=[],r=0;r<arguments.length;r++)n.push(arguments[r]);var i=n.pop();if("function"!=typeof i)throw new TypeError("The last argument must be of type Function");var o=this,s=function(){return i.apply(o,arguments)};t.apply(this,n).then(function(t){e.nextTick(s,null,t)},function(t){e.nextTick(M,t,s)})}return Object.setPrototypeOf(n,Object.getPrototypeOf(t)),Object.defineProperties(n,r(t)),n}t.promisify=function e(t){if("function"!=typeof t)throw new TypeError('The "original" argument must be of type Function');if(D&&t[D]){var n=t[D];if("function"!=typeof n)throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(n,D,{value:n,enumerable:!1,writable:!1,configurable:!0}),n}function n(){for(var e,n,r=new Promise(function(t,r){e=t,n=r}),i=[],o=0;o<arguments.length;o++)i.push(arguments[o]);i.push(function(t,r){t?n(t):e(r)});try{t.apply(this,i)}catch(e){n(e)}return r}return Object.setPrototypeOf(n,Object.getPrototypeOf(t)),D&&Object.defineProperty(n,D,{value:n,enumerable:!1,writable:!1,configurable:!0}),Object.defineProperties(n,r(t))},t.promisify.custom=D,t.callbackify=F}).call(this,n(3))},function(e,t,n){"use strict";(function(r){const i=n(27),o=n(368),s=n(24),a=n(10),l=n(39);class u{constructor(e,t,n){s(r.isBuffer(e),"invalid id provided"),t&&n&&s(t.public.bytes.equals(n.bytes),"inconsistent arguments"),this._id=e,this._idB58String=i.toB58String(this.id),this._privKey=t,this._pubKey=n}get id(){return this._id}set id(e){throw new Error("Id is immutable")}get privKey(){return this._privKey}set privKey(e){this._privKey=e}get pubKey(){return this._pubKey?this._pubKey:this._privKey?this._privKey.public:void 0}set pubKey(e){this._pubKey=e}marshalPubKey(){if(this.pubKey)return o.marshalPublicKey(this.pubKey)}marshalPrivKey(){if(this.privKey)return o.marshalPrivateKey(this.privKey)}toPrint(){let e=this.toB58String();e.startsWith("Qm")&&(e=e.slice(2));let t=6;return e.length<t&&(t=e.length),"<peer.ID "+e.substr(0,t)+">"}toJSON(){return{id:this.toB58String(),privKey:h(this.marshalPrivKey()),pubKey:h(this.marshalPubKey())}}toHexString(){return i.toHexString(this.id)}toBytes(){return this.id}toB58String(){return this._idB58String}isEqual(e){if(r.isBuffer(e))return this.id.equals(e);if(e.id)return this.id.equals(e.id);throw new Error("not valid Id")}isValid(e){this.privKey&&this.privKey.public&&this.privKey.public.bytes&&r.isBuffer(this.pubKey.bytes)&&this.privKey.public.bytes.equals(this.pubKey.bytes)?e():e(new Error("Keys not match"))}}const c=l(u,{className:"PeerId",symbolName:"@libp2p/js-peer-id/PeerId"});function h(e){if(e)return e.toString("base64")}t=e.exports=c,t.create=function(e,t){"function"==typeof e&&(t=e,e={}),e=e||{},e.bits=e.bits||2048,a([t=>o.generateKeyPair("RSA",e.bits,t),(e,t)=>e.public.hash((n,r)=>{t(n,r,e)})],(e,n,r)=>{if(e)return t(e);t(null,new c(n,r))})},t.createFromHexString=function(e){return new c(i.fromHexString(e))},t.createFromBytes=function(e){return new c(e)},t.createFromB58String=function(e){return new c(i.fromB58String(e))},t.createFromPubKey=function(e,t){if("function"!=typeof t)throw new Error("callback is required");let n;try{let i=e;if("string"==typeof i&&(i=r.from(e,"base64")),!r.isBuffer(i))throw new Error("Supplied key is neither a base64 string nor a buffer");n=o.unmarshalPublicKey(i)}catch(e){return t(e)}n.hash((e,r)=>{if(e)return t(e);t(null,new c(r,null,n))})},t.createFromPrivKey=function(e,t){if("function"!=typeof t)throw new Error("callback is required");let n=e;try{if("string"==typeof n&&(n=r.from(e,"base64")),!r.isBuffer(n))throw new Error("Supplied key is neither a base64 string nor a buffer")}catch(e){return t(e)}a([e=>o.unmarshalPrivateKey(n,e),(e,t)=>e.public.hash((n,r)=>{t(n,r,e)})],(e,n,r)=>{if(e)return t(e);t(null,new c(n,r,r.public))})},t.createFromJSON=function(e,t){if("function"!=typeof t)throw new Error("callback is required");let n,s,l,u;try{n=i.fromB58String(e.id),s=e.privKey&&r.from(e.privKey,"base64"),l=e.pubKey&&r.from(e.pubKey,"base64"),u=l&&o.unmarshalPublicKey(l)}catch(e){return t(e)}s?a([e=>o.unmarshalPrivateKey(s,e),(e,t)=>e.public.hash((n,r)=>{t(n,r,e)}),(e,t,n)=>{u?u.hash((r,i)=>{n(r,e,t,i)}):n(null,e,t)}],(e,r,i,o)=>e?t(e):u&&!r.equals(o)?t(new Error("Public and private key do not match")):n&&!r.equals(n)?t(new Error("Id and private key do not match")):void t(null,new c(n,i,u))):t(null,new c(n,null,u))},t.isPeerId=function(e){return Boolean("object"==typeof e&&e._id&&e._idB58String)}}).call(this,n(0).Buffer)},function(e,t){},function(e,t,n){t=e.exports=n(335),t.Stream=t,t.Readable=t,t.Writable=n(339),t.Duplex=n(113),t.Transform=n(340),t.PassThrough=n(674),t.finished=n(245),t.pipeline=n(675)},function(e,t,n){"use strict";var r=n(5).Buffer,i=r.isEncoding||function(e){switch(e=""+e,e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function o(e){if(!e)return"utf8";for(var t;;)switch(e){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return e;default:if(t)return;e=(""+e).toLowerCase(),t=!0}}function s(e){var t=o(e);if("string"!=typeof t&&(r.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}function a(e){var t;switch(this.encoding=s(e),this.encoding){case"utf16le":this.text=d,this.end=m,t=4;break;case"utf8":this.fillLast=h,t=4;break;case"base64":this.text=g,this.end=y,t=3;break;default:return this.write=v,void(this.end=b)}this.lastNeed=0,this.lastTotal=0,this.lastChar=r.allocUnsafe(t)}function l(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function u(e,t,n){var r=t.length-1;if(r<n)return 0;var i=l(t[r]);return i>=0?(i>0&&(e.lastNeed=i-1),i):--r<n||-2===i?0:(i=l(t[r]),i>=0?(i>0&&(e.lastNeed=i-2),i):--r<n||-2===i?0:(i=l(t[r]),i>=0?(i>0&&(2===i?i=0:e.lastNeed=i-3),i):0))}function c(e,t,n){if(128!=(192&t[0]))return e.lastNeed=0,"<22>";if(e.lastNeed>1&&t.length>1){if(128!=(192&t[1]))return e.lastNeed=1,"<22>";if(e.lastNeed>2&&t.length>2&&128!=(192&t[2]))return e.lastNeed=2,"<22>"}}function h(e){var t=this.lastTotal-this.lastNeed,n=c(this,e,t);return void 0!==n?n:this.lastNeed<=e.length?(e.copy(this.lastChar,t,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(e.copy(this.lastChar,t,0,e.length),void(this.lastNeed-=e.length))}function f(e,t){var n=u(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=n;var r=e.length-(n-this.lastNeed);return e.copy(this.lastChar,0,r),e.toString("utf8",t,r)}function p(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"<22>":t}function d(e,t){if((e.length-t)%2==0){var n=e.toString("utf16le",t);if(n){var r=n.charCodeAt(n.length-1);if(r>=55296&&r<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],n.slice(0,-1)}return n}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function m(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var n=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,n)}return t}function g(e,t){var n=(e.length-t)%3;return 0===n?e.toString("base64",t):(this.lastNeed=3-n,this.lastTotal=3,1===n?this.lastChar[0]=e[e.length-1]:(this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1]),e.toString("base64",t,e.length-n))}function y(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function v(e){return e.toString(this.encoding)}function b(e){return e&&e.length?this.write(e):""}t.StringDecoder=a,a.prototype.write=function(e){if(0===e.length)return"";var t,n;if(this.lastNeed){if(t=this.fillLast(e),void 0===t)return"";n=this.lastNeed,this.lastNeed=0}else n=0;return n<e.length?t?t+this.text(e,n):this.text(e,n):t||""},a.prototype.end=p,a.prototype.text=f,a.prototype.fillLast=function(e){if(this.lastNeed<=e.length)return e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);e.copy(this.lastChar,this.lastTotal-this.lastNeed,0,e.length),this.lastNeed-=e.length}},function(e,t,n){"use strict";var r=n(696),i=n(700),o=n(704);for(var s in t=e.exports=n(12),t.pull=t,r)t[s]=r[s];for(var s in o)t[s]=o[s];for(var s in i)t[s]=i[s]},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(180),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}t.default=i.default,e.exports=t.default},function(e,t){e.exports={options:{usePureJavaScript:!1}}},function(e,t,n){"use strict";(function(r){const i=n(805),o=n(260),s=n(35),a=n(70),l=n(39),u=l.proto(function(e){if(!(this instanceof u))return new u(e);if(null==e&&(e=""),e instanceof r)this.buffer=i.fromBuffer(e);else if("string"==typeof e||e instanceof String){if(e.length>0&&"/"!==e.charAt(0))throw new Error(`multiaddr "${e}" must start with a "/"`);this.buffer=i.fromString(e)}else{if(!(e.buffer&&e.protos&&e.protoCodes))throw new Error("addr must be a string, Buffer, or another Multiaddr");this.buffer=i.fromBuffer(e.buffer)}},{className:"Multiaddr",symbolName:"@multiformats/js-multiaddr/multiaddr"});u.prototype.toString=function e(){return i.bufferToString(this.buffer)},u.prototype.toJSON=u.prototype.toString,u.prototype.toOptions=function e(){const t={},n=this.toString().split("/");return t.family="ip4"===n[1]?"ipv4":"ipv6",t.host=n[2],t.transport=n[3],t.port=n[4],t},u.prototype.inspect=function e(){return"<Multiaddr "+this.buffer.toString("hex")+" - "+i.bufferToString(this.buffer)+">"},u.prototype.protos=function e(){return this.protoCodes().map(e=>Object.assign({},o(e)))},u.prototype.protoCodes=function e(){const t=[],n=this.buffer;let r=0;for(;r<n.length;){const e=s.decode(n,r),a=s.decode.bytes,l=o(e),u=i.sizeForAddr(l,n.slice(r+a));r+=u+a,t.push(e)}return t},u.prototype.protoNames=function e(){return this.protos().map(e=>e.name)},u.prototype.tuples=function e(){return i.bufferToTuples(this.buffer)},u.prototype.stringTuples=function e(){const t=i.bufferToTuples(this.buffer);return i.tuplesToStringTuples(t)},u.prototype.encapsulate=function e(t){return t=u(t),u(this.toString()+t.toString())},u.prototype.decapsulate=function e(t){t=t.toString();const n=this.toString(),r=n.lastIndexOf(t);if(r<0)throw new Error("Address "+this+" does not contain subaddress: "+t);return u(n.slice(0,r))},u.prototype.getPeerId=function e(){let t=null;try{t=this.stringTuples().filter(e=>{if(e[0]===o.names.ipfs.code)return!0})[0][1],a.decode(t)}catch(e){t=null}return t},u.prototype.getPath=function e(){let t=null;try{t=this.stringTuples().filter(e=>{const t=o(e[0]);if(t.path)return!0})[0][1]}catch(e){t=null}return t},u.prototype.equals=function e(t){return this.buffer.equals(t.buffer)},u.prototype.nodeAddress=function e(){const t=this.protoCodes(),n=this.protoNames(),r=this.toString().split("/").slice(1);if(r.length<4)throw new Error('multiaddr must have a valid format: "/{ip4, ip6, dns4, dns6}/{address}/{tcp, udp}/{port}".');if(4!==t[0]&&41!==t[0]&&54!==t[0]&&55!==t[0])throw new Error(`no protocol with name: "'${n[0]}'". Must have a valid family name: "{ip4, ip6, dns4, dns6}".`);if("tcp"!==r[2]&&"udp"!==r[2])throw new Error(`no protocol with name: "'${n[1]}'". Must have a valid transport protocol: "{tcp, udp}".`);return{family:41===t[0]||55===t[0]?6:4,address:r[1],port:r[3]}},u.fromNodeAddress=function e(t,n){if(!t)throw new Error("requires node address object");if(!n)throw new Error("requires transport protocol");const r="IPv6"===t.family?"ip6":"ip4";return u("/"+[r,t.address,n,t.port].join("/"))},u.prototype.isThinWaistAddress=function e(t){const n=(t||this).protos();return 2===n.length&&((4===n[0].code||41===n[0].code)&&(6===n[1].code||273===n[1].code))},u.protocols=o,u.isName=function e(t){return!!u.isMultiaddr(t)&&t.protos().some(e=>e.resolvable)},u.resolve=function e(t,n){return u.isMultiaddr(t)&&u.isName(t)?n(new Error("not implemented yet")):n(new Error("not a valid name"))},t=e.exports=u}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(536),i=n(537),o=n(22);e.exports=(e=>{const t=r();if("function"==typeof e)return e;if("object"==typeof e)return i(e);if("string"==typeof e){const n=o(e).nodeAddress();return t.host=n.address,t.port=n.port,i(t)}throw new Error("Argument must be a send function or a config object.")})},function(e,t,n){"use strict";(function(t){var r=n(725);
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/function i(e,t){if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);i<o;++i)if(e[i]!==t[i]){n=e[i],r=t[i];break}return n<r?-1:r<n?1:0}function o(e){return t.Buffer&&"function"==typeof t.Buffer.isBuffer?t.Buffer.isBuffer(e):!(null==e||!e._isBuffer)}var s=n(14),a=Object.prototype.hasOwnProperty,l=Array.prototype.slice,u="foo"===function e(){}.name;function c(e){return Object.prototype.toString.call(e)}function h(e){return!o(e)&&("function"==typeof t.ArrayBuffer&&("function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):!!e&&(e instanceof DataView||!!(e.buffer&&e.buffer instanceof ArrayBuffer))))}var f=e.exports=b,p=/\s*function\s+([^\(\s]*)\s*/;function d(e){if(s.isFunction(e)){if(u)return e.name;var t=e.toString(),n=t.match(p);return n&&n[1]}}function m(e,t){return"string"==typeof e?e.length<t?e:e.slice(0,t):e}function g(e){if(u||!s.isFunction(e))return s.inspect(e);var t=d(e),n=t?": "+t:"";return"[Function"+n+"]"}function y(e){return m(g(e.actual),128)+" "+e.operator+" "+m(g(e.expected),128)}function v(e,t,n,r,i){throw new f.AssertionError({message:n,actual:e,expected:t,operator:r,stackStartFunction:i})}function b(e,t){e||v(e,!0,t,"==",f.ok)}function _(e,t,n,r){if(e===t)return!0;if(o(e)&&o(t))return 0===i(e,t);if(s.isDate(e)&&s.isDate(t))return e.getTime()===t.getTime();if(s.isRegExp(e)&&s.isRegExp(t))return e.source===t.source&&e.global===t.global&&e.multiline===t.multiline&&e.lastIndex===t.lastIndex&&e.ignoreCase===t.ignoreCase;if(null!==e&&"object"==typeof e||null!==t&&"object"==typeof t){if(h(e)&&h(t)&&c(e)===c(t)&&!(e instanceof Float32Array||e instanceof Float64Array))return 0===i(new Uint8Array(e.buffer),new Uint8Array(t.buffer));if(o(e)!==o(t))return!1;r=r||{actual:[],expected:[]};var a=r.actual.indexOf(e);return-1!==a&&a===r.expected.indexOf(t)||(r.actual.push(e),r.expected.push(t),k(e,t,n,r))}return n?e===t:e==t}function w(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function k(e,t,n,r){if(null===e||void 0===e||null===t||void 0===t)return!1;if(s.isPrimitive(e)||s.isPrimitive(t))return e===t;if(n&&Object.getPrototypeOf(e)!==Object.getPrototypeOf(t))return!1;var i=w(e),o=w(t);if(i&&!o||!i&&o)return!1;if(i)return e=l.call(e),t=l.call(t),_(e,t,n);var a=T(e),u=T(t),c,h;if(a.length!==u.length)return!1;for(a.sort(),u.sort(),h=a.length-1;h>=0;h--)if(a[h]!==u[h])return!1;for(h=a.length-1;h>=0;h--)if(c=a[h],!_(e[c],t[c],n,r))return!1;return!0}function E(e,t,n){_(e,t,!0)&&v(e,t,n,"notDeepStrictEqual",E)}function S(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function x(e){var t;try{e()}catch(e){t=e}return t}function C(e,t,n,r){var i;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof n&&(r=n,n=null),i=x(t),r=(n&&n.name?" ("+n.name+").":".")+(r?" "+r:"."),e&&!i&&v(i,n,"Missing expected exception"+r);var o="string"==typeof r,a=!e&&s.isError(i),l=!e&&i&&!n;if((a&&o&&S(i,n)||l)&&v(i,n,"Got unwanted exception"+r),e&&i&&n&&!S(i,n)||!e&&i)throw i}function A(e,t){e||v(e,!0,t,"==",A)}f.AssertionError=function e(t){this.name="AssertionError",this.actual=t.actual,this.expected=t.expected,this.operator=t.operator,t.message?(this.message=t.message,this.generatedMessage=!1):(this.message=y(this),this.generatedMessage=!0);var n=t.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,n);else{var r=new Error;if(r.stack){var i=r.stack,o=d(n),s=i.indexOf("\n"+o);if(s>=0){var a=i.indexOf("\n",s+1);i=i.substring(a+1)}this.stack=i}}},s.inherits(f.AssertionError,Error),f.fail=v,f.ok=b,f.equal=function e(t,n,r){t!=n&&v(t,n,r,"==",f.equal)},f.notEqual=function e(t,n,r){t==n&&v(t,n,r,"!=",f.notEqual)},f.deepEqual=function e(t,n,r){_(t,n,!1)||v(t,n,r,"deepEqual",f.deepEqual)},f.deepStrictEqual=function e(t,n,r){_(t,n,!0)||v(t,n,r,"deepStrictEqual",f.deepStrictEqual)},f.notDeepEqual=function e(t,n,r){_(t,n,!1)&&v(t,n,r,"notDeepEqual",f.notDeepEqual)},f.notDeepStrictEqual=E,f.strictEqual=function e(t,n,r){t!==n&&v(t,n,r,"===",f.strictEqual)},f.notStrictEqual=function e(t,n,r){t===n&&v(t,n,r,"!==",f.notStrictEqual)},f.throws=function(e,t,n){C(!0,e,t,n)},f.doesNotThrow=function(e,t,n){C(!1,e,t,n)},f.ifError=function(e){if(e)throw e},f.strict=r(A,f,{equal:f.strictEqual,deepEqual:f.deepStrictEqual,notEqual:f.notStrictEqual,notDeepEqual:f.notDeepStrictEqual}),f.strict.strict=f.strict;var T=Object.keys||function(e){var t=[];for(var n in e)a.call(e,n)&&t.push(n);return t}}).call(this,n(8))},function(e,t,n){(function(t,r){var i=n(24),o=n(62).Stream,s=n(14),a=/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;function l(e){return e.charAt(0).toUpperCase()+e.slice(1)}function u(e,t,n,r,o){throw new i.AssertionError({message:s.format("%s (%s) is required",e,t),actual:void 0===o?typeof r:o(r),expected:t,operator:n||"===",stackStartFunction:u.caller})}function c(e){return Object.prototype.toString.call(e).slice(8,-1)}function h(){}var f={bool:{check:function(e){return"boolean"==typeof e}},func:{check:function(e){return"function"==typeof e}},string:{check:function(e){return"string"==typeof e}},object:{check:function(e){return"object"==typeof e&&null!==e}},number:{check:function(e){return"number"==typeof e&&!isNaN(e)}},finite:{check:function(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}},buffer:{check:function(e){return t.isBuffer(e)},operator:"Buffer.isBuffer"},array:{check:function(e){return Array.isArray(e)},operator:"Array.isArray"},stream:{check:function(e){return e instanceof o},operator:"instanceof",actual:c},date:{check:function(e){return e instanceof Date},operator:"instanceof",actual:c},regexp:{check:function(e){return e instanceof RegExp},operator:"instanceof",actual:c},uuid:{check:function(e){return"string"==typeof e&&a.test(e)},operator:"isUUID"}};function p(e){var t=Object.keys(f),n;return n=r.env.NODE_NDEBUG?h:function(e,t){e||u(t,"true",e)},t.forEach(function(t){if(e)n[t]=h;else{var r=f[t];n[t]=function(e,n){r.check(e)||u(n,t,r.operator,e,r.actual)}}}),t.forEach(function(t){var r="optional"+l(t);if(e)n[r]=h;else{var i=f[t];n[r]=function(e,n){void 0!==e&&null!==e&&(i.check(e)||u(n,t,i.operator,e,i.actual))}}}),t.forEach(function(t){var r="arrayOf"+l(t);if(e)n[r]=h;else{var i=f[t],o="["+t+"]";n[r]=function(e,t){var n;for(Array.isArray(e)||u(t,o,i.operator,e,i.actual),n=0;n<e.length;n++)i.check(e[n])||u(t,o,i.operator,e,i.actual)}}}),t.forEach(function(t){var r="optionalArrayOf"+l(t);if(e)n[r]=h;else{var i=f[t],o="["+t+"]";n[r]=function(e,t){var n;if(void 0!==e&&null!==e)for(Array.isArray(e)||u(t,o,i.operator,e,i.actual),n=0;n<e.length;n++)i.check(e[n])||u(t,o,i.operator,e,i.actual)}}}),Object.keys(i).forEach(function(t){n[t]="AssertionError"!==t&&e?h:i[t]}),n._setExports=p,n}e.exports=p(r.env.NODE_NDEBUG)}).call(this,n(0).Buffer,n(3))},function(e,t,n){var r=n(973);function i(e){var t=function(){return t.called?t.value:(t.called=!0,t.value=e.apply(this,arguments))};return t.called=!1,t}function o(e){var t=function(){if(t.called)throw new Error(t.onceError);return t.called=!0,t.value=e.apply(this,arguments)},n=e.name||"Function wrapped with `once`";return t.onceError=n+" shouldn't be called more than once",t.called=!1,t}e.exports=r(i),e.exports.strict=r(o),i.proto=i(function(){Object.defineProperty(Function.prototype,"once",{value:function(){return i(this)},configurable:!0}),Object.defineProperty(Function.prototype,"onceStrict",{value:function(){return o(this)},configurable:!0})})},function(e,t,n){"use strict";(function(e){const r=n(70),i=n(682);t.names=i.names,t.codes=i.codes,t.defaultLengths=i.defaultLengths;const o=n(35);function s(e){t.decode(e)}t.toHexString=function t(n){if(!e.isBuffer(n))throw new Error("must be passed a buffer");return n.toString("hex")},t.fromHexString=function t(n){return e.from(n,"hex")},t.toB58String=function t(n){if(!e.isBuffer(n))throw new Error("must be passed a buffer");return r.encode(n)},t.fromB58String=function t(n){let i=n;return e.isBuffer(n)&&(i=n.toString()),e.from(r.decode(i))},t.decode=function n(r){if(!e.isBuffer(r))throw new Error("multihash must be a Buffer");if(r.length<3)throw new Error("multihash too short. must be > 3 bytes.");let s=o.decode(r);if(!t.isValidCode(s))throw new Error(`multihash unknown function code: 0x${s.toString(16)}`);r=r.slice(o.decode.bytes);let a=o.decode(r);if(a<1)throw new Error(`multihash invalid length: 0x${a.toString(16)}`);if(r=r.slice(o.decode.bytes),r.length!==a)throw new Error(`multihash length inconsistent: 0x${r.toString("hex")}`);return{code:s,name:i.codes[s],length:a,digest:r}},t.encode=function n(r,i,s){if(!r||!i)throw new Error("multihash encode requires at least two args: digest, code");const a=t.coerceCode(i);if(!e.isBuffer(r))throw new Error("digest should be a Buffer");if(null==s&&(s=r.length),s&&r.length!==s)throw new Error("digest length should be equal to specified length.");return e.concat([e.from(o.encode(a)),e.from(o.encode(s)),r])},t.coerceCode=function e(n){let r=n;if("string"==typeof n){if(!i.names[n])throw new Error(`Unrecognized hash function named: ${n}`);r=i.names[n]}if("number"!=typeof r)throw new Error(`Hash function code should be a number. Got: ${r}`);if(!i.codes[r]&&!t.isAppCode(r))throw new Error(`Unrecognized function code: ${r}`);return r},t.isAppCode=function e(t){return t>0&&t<16},t.isValidCode=function e(n){return!!t.isAppCode(n)||!!i.codes[n]},t.validate=s,t.prefix=function e(t){return s(t),t.slice(0,2)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(403),i=n(832),o=n(262),s=n(406);t.Key=r,t.MemoryDatastore=i,t.utils=o,t.Errors=s},function(e,t,n){"use strict";(function(t){var r=n(0),i=r.Buffer,o={},s;for(s in r)r.hasOwnProperty(s)&&"SlowBuffer"!==s&&"Buffer"!==s&&(o[s]=r[s]);var a=o.Buffer={};for(s in i)i.hasOwnProperty(s)&&"allocUnsafe"!==s&&"allocUnsafeSlow"!==s&&(a[s]=i[s]);if(o.Buffer.prototype=i.prototype,a.from&&a.from!==Uint8Array.from||(a.from=function(e,t,n){if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type '+typeof e);if(e&&void 0===e.length)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);return i(e,t,n)}),a.alloc||(a.alloc=function(e,t,n){if("number"!=typeof e)throw new TypeError('The "size" argument must be of type number. Received type '+typeof e);if(e<0||e>=2*(1<<30))throw new RangeError('The value "'+e+'" is invalid for option "size"');var r=i(e);return t&&0!==t.length?"string"==typeof n?r.fill(t,n):r.fill(t):r.fill(0),r}),!o.kStringMaxLength)try{o.kStringMaxLength=t.binding("buffer").kStringMaxLength}catch(e){}o.constants||(o.constants={MAX_LENGTH:o.kMaxLength},o.kStringMaxLength&&(o.constants.MAX_STRING_LENGTH=o.kStringMaxLength)),e.exports=o}).call(this,n(3))},function(e,t,n){(function(t,r){var i=n(21),o=n(745),s=e.exports=i.util=i.util||{};function a(e){if(8!==e&&16!==e&&24!==e&&32!==e)throw new Error("Only 8, 16, 24, or 32 bits supported: "+e)}function l(e){if(this.data="",this.read=0,"string"==typeof e)this.data=e;else if(s.isArrayBuffer(e)||s.isArrayBufferView(e))if(void 0!==r&&e instanceof r)this.data=e.toString("binary");else{var t=new Uint8Array(e);try{this.data=String.fromCharCode.apply(null,t)}catch(e){for(var n=0;n<t.length;++n)this.putByte(t[n])}}else(e instanceof l||"object"==typeof e&&"string"==typeof e.data&&"number"==typeof e.read)&&(this.data=e.data,this.read=e.read);this._constructedStringLength=0}!function(){if(void 0!==t&&t.nextTick&&!t.browser)return s.nextTick=t.nextTick,void("function"==typeof setImmediate?s.setImmediate=setImmediate:s.setImmediate=s.nextTick);if("function"==typeof setImmediate)return s.setImmediate=function(){return setImmediate.apply(void 0,arguments)},void(s.nextTick=function(e){return setImmediate(e)});if(s.setImmediate=function(e){setTimeout(e,0)},"undefined"!=typeof window&&"function"==typeof window.postMessage){var e="forge.setImmediate",n=[];function r(t){if(t.source===window&&t.data===e){t.stopPropagation();var r=n.slice();n.length=0,r.forEach(function(e){e()})}}s.setImmediate=function(t){n.push(t),1===n.length&&window.postMessage(e,"*")},window.addEventListener("message",r,!0)}if("undefined"!=typeof MutationObserver){var i=Date.now(),o=!0,a=document.createElement("div"),n=[];new MutationObserver(function(){var e=n.slice();n.length=0,e.forEach(function(e){e()})}).observe(a,{attributes:!0});var l=s.setImmediate;s.setImmediate=function(e){Date.now()-i>15?(i=Date.now(),l(e)):(n.push(e),1===n.length&&a.setAttribute("a",o=!o))}}s.nextTick=s.setImmediate}(),s.isNodejs=void 0!==t&&t.versions&&t.versions.node,s.isArray=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},s.isArrayBuffer=function(e){return"undefined"!=typeof ArrayBuffer&&e instanceof ArrayBuffer},s.isArrayBufferView=function(e){return e&&s.isArrayBuffer(e.buffer)&&void 0!==e.byteLength},s.ByteBuffer=l,s.ByteStringBuffer=l;var u=4096;function c(e,t){t=t||{},this.read=t.readOffset||0,this.growSize=t.growSize||1024;var n=s.isArrayBuffer(e),r=s.isArrayBufferView(e);if(n||r)return this.data=n?new DataView(e):new DataView(e.buffer,e.byteOffset,e.byteLength),void(this.write="writeOffset"in t?t.writeOffset:this.data.byteLength);this.data=new DataView(new ArrayBuffer(0)),this.write=0,null!==e&&void 0!==e&&this.putBytes(e),"writeOffset"in t&&(this.write=t.writeOffset)}s.ByteStringBuffer.prototype._optimizeConstructedString=function(e){this._constructedStringLength+=e,this._constructedStringLength>4096&&(this.data.substr(0,1),this._constructedStringLength=0)},s.ByteStringBuffer.prototype.length=function(){return this.data.length-this.read},s.ByteStringBuffer.prototype.isEmpty=function(){return this.length()<=0},s.ByteStringBuffer.prototype.putByte=function(e){return this.putBytes(String.fromCharCode(e))},s.ByteStringBuffer.prototype.fillWithByte=function(e,t){e=String.fromCharCode(e);for(var n=this.data;t>0;)1&t&&(n+=e),t>>>=1,t>0&&(e+=e);return this.data=n,this._optimizeConstructedString(t),this},s.ByteStringBuffer.prototype.putBytes=function(e){return this.data+=e,this._optimizeConstructedString(e.length),this},s.ByteStringBuffer.prototype.putString=function(e){return this.putBytes(s.encodeUtf8(e))},s.ByteStringBuffer.prototype.putInt16=function(e){return this.putBytes(String.fromCharCode(e>>8&255)+String.fromCharCode(255&e))},s.ByteStringBuffer.prototype.putInt24=function(e){return this.putBytes(String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e))},s.ByteStringBuffer.prototype.putInt32=function(e){return this.putBytes(String.fromCharCode(e>>24&255)+String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e))},s.ByteStringBuffer.prototype.putInt16Le=function(e){return this.putBytes(String.fromCharCode(255&e)+String.fromCharCode(e>>8&255))},s.ByteStringBuffer.prototype.putInt24Le=function(e){return this.putBytes(String.fromCharCode(255&e)+String.fromCharCode(e>>8&255)+String.fromCharCode(e>>16&255))},s.ByteStringBuffer.prototype.putInt32Le=function(e){return this.putBytes(String.fromCharCode(255&e)+String.fromCharCode(e>>8&255)+String.fromCharCode(e>>16&255)+String.fromCharCode(e>>24&255))},s.ByteStringBuffer.prototype.putInt=function(e,t){a(t);var n="";do{t-=8,n+=String.fromCharCode(e>>t&255)}while(t>0);return this.putBytes(n)},s.ByteStringBuffer.prototype.putSignedInt=function(e,t){return e<0&&(e+=2<<t-1),this.putInt(e,t)},s.ByteStringBuffer.prototype.putBuffer=function(e){return this.putBytes(e.getBytes())},s.ByteStringBuffer.prototype.getByte=function(){return this.data.charCodeAt(this.read++)},s.ByteStringBuffer.prototype.getInt16=function(){var e=this.data.charCodeAt(this.read)<<8^this.data.charCodeAt(this.read+1);return this.read+=2,e},s.ByteStringBuffer.prototype.getInt24=function(){var e=this.data.charCodeAt(this.read)<<16^this.data.charCodeAt(this.read+1)<<8^this.data.charCodeAt(this.read+2);return this.read+=3,e},s.ByteStringBuffer.prototype.getInt32=function(){var e=this.data.charCodeAt(this.read)<<24^this.data.charCodeAt(this.read+1)<<16^this.data.charCodeAt(this.read+2)<<8^this.data.charCodeAt(this.read+3);return this.read+=4,e},s.ByteStringBuffer.prototype.getInt16Le=function(){var e=this.data.charCodeAt(this.read)^this.data.charCodeAt(this.read+1)<<8;return this.read+=2,e},s.ByteStringBuffer.prototype.getInt24Le=function(){var e=this.data.charCodeAt(this.read)^this.data.charCodeAt(this.read+1)<<8^this.data.charCodeAt(this.read+2)<<16;return this.read+=3,e},s.ByteStringBuffer.prototype.getInt32Le=function(){var e=this.data.charCodeAt(this.read)^this.data.charCodeAt(this.read+1)<<8^this.data.charCodeAt(this.read+2)<<16^this.data.charCodeAt(this.read+3)<<24;return this.read+=4,e},s.ByteStringBuffer.prototype.getInt=function(e){a(e);var t=0;do{t=(t<<8)+this.data.charCodeAt(this.read++),e-=8}while(e>0);return t},s.ByteStringBuffer.prototype.getSignedInt=function(e){var t=this.getInt(e),n=2<<e-2;return t>=n&&(t-=n<<1),t},s.ByteStringBuffer.prototype.getBytes=function(e){var t;return e?(e=Math.min(this.length(),e),t=this.data.slice(this.read,this.read+e),this.read+=e):0===e?t="":(t=0===this.read?this.data:this.data.slice(this.read),this.clear()),t},s.ByteStringBuffer.prototype.bytes=function(e){return void 0===e?this.data.slice(this.read):this.data.slice(this.read,this.read+e)},s.ByteStringBuffer.prototype.at=function(e){return this.data.charCodeAt(this.read+e)},s.ByteStringBuffer.prototype.setAt=function(e,t){return this.data=this.data.substr(0,this.read+e)+String.fromCharCode(t)+this.data.substr(this.read+e+1),this},s.ByteStringBuffer.prototype.last=function(){return this.data.charCodeAt(this.data.length-1)},s.ByteStringBuffer.prototype.copy=function(){var e=s.createBuffer(this.data);return e.read=this.read,e},s.ByteStringBuffer.prototype.compact=function(){return this.read>0&&(this.data=this.data.slice(this.read),this.read=0),this},s.ByteStringBuffer.prototype.clear=function(){return this.data="",this.read=0,this},s.ByteStringBuffer.prototype.truncate=function(e){var t=Math.max(0,this.length()-e);return this.data=this.data.substr(this.read,t),this.read=0,this},s.ByteStringBuffer.prototype.toHex=function(){for(var e="",t=this.read;t<this.data.length;++t){var n=this.data.charCodeAt(t);n<16&&(e+="0"),e+=n.toString(16)}return e},s.ByteStringBuffer.prototype.toString=function(){return s.decodeUtf8(this.bytes())},s.DataBuffer=c,s.DataBuffer.prototype.length=function(){return this.write-this.read},s.DataBuffer.prototype.isEmpty=function(){return this.length()<=0},s.DataBuffer.prototype.accommodate=function(e,t){if(this.length()>=e)return this;t=Math.max(t||this.growSize,e);var n=new Uint8Array(this.data.buffer,this.data.byteOffset,this.data.byteLength),r=new Uint8Array(this.length()+t);return r.set(n),this.data=new DataView(r.buffer),this},s.DataBuffer.prototype.putByte=function(e){return this.accommodate(1),this.data.setUint8(this.write++,e),this},s.DataBuffer.prototype.fillWithByte=function(e,t){this.accommodate(t);for(var n=0;n<t;++n)this.data.setUint8(e);return this},s.DataBuffer.prototype.putBytes=function(e,t){if(s.isArrayBufferView(e)){var n=new Uint8Array(e.buffer,e.byteOffset,e.byteLength),r=n.byteLength-n.byteOffset;this.accommodate(r);var i=new Uint8Array(this.data.buffer,this.write);return i.set(n),this.write+=r,this}if(s.isArrayBuffer(e)){var n=new Uint8Array(e);this.accommodate(n.byteLength);var i=new Uint8Array(this.data.buffer);return i.set(n,this.write),this.write+=n.byteLength,this}if(e instanceof s.DataBuffer||"object"==typeof e&&"number"==typeof e.read&&"number"==typeof e.write&&s.isArrayBufferView(e.data)){var n=new Uint8Array(e.data.byteLength,e.read,e.length());this.accommodate(n.byteLength);var i=new Uint8Array(e.data.byteLength,this.write);return i.set(n),this.write+=n.byteLength,this}if(e instanceof s.ByteStringBuffer&&(e=e.data,t="binary"),t=t||"binary","string"==typeof e){var o;if("hex"===t)return this.accommodate(Math.ceil(e.length/2)),o=new Uint8Array(this.data.buffer,this.write),this.write+=s.binary.hex.decode(e,o,this.write),this;if("base64"===t)return this.accommodate(3*Math.ceil(e.length/4)),o=new Uint8Array(this.data.buffer,this.write),this.write+=s.binary.base64.decode(e,o,this.write),this;if("utf8"===t&&(e=s.encodeUtf8(e),t="binary"),"binary"===t||"raw"===t)return this.accommodate(e.length),o=new Uint8Array(this.data.buffer,this.write),this.write+=s.binary.raw.decode(o),this;if("utf16"===t)return this.accommodate(2*e.length),o=new Uint16Array(this.data.buffer,this.write),this.write+=s.text.utf16.encode(o),this;throw new Error("Invalid encoding: "+t)}throw Error("Invalid parameter: "+e)},s.DataBuffer.prototype.putBuffer=function(e){return this.putBytes(e),e.clear(),this},s.DataBuffer.prototype.putString=function(e){return this.putBytes(e,"utf16")},s.DataBuffer.prototype.putInt16=function(e){return this.accommodate(2),this.data.setInt16(this.write,e),this.write+=2,this},s.DataBuffer.prototype.putInt24=function(e){return this.accommodate(3),this.data.setInt16(this.write,e>>8&65535),this.data.setInt8(this.write,e>>16&255),this.write+=3,this},s.DataBuffer.prototype.putInt32=function(e){return this.accommodate(4),this.data.setInt32(this.write,e),this.write+=4,this},s.DataBuffer.prototype.putInt16Le=function(e){return this.accommodate(2),this.data.setInt16(this.write,e,!0),this.write+=2,this},s.DataBuffer.prototype.putInt24Le=function(e){return this.accommodate(3),this.data.setInt8(this.write,e>>16&255),this.data.setInt16(this.write,e>>8&65535,!0),this.write+=3,this},s.DataBuffer.prototype.putInt32Le=function(e){return this.accommodate(4),this.data.setInt32(this.write,e,!0),this.write+=4,this},s.DataBuffer.prototype.putInt=function(e,t){a(t),this.accommodate(t/8);do{t-=8,this.data.setInt8(this.write++,e>>t&255)}while(t>0);return this},s.DataBuffer.prototype.putSignedInt=function(e,t){return a(t),this.accommodate(t/8),e<0&&(e+=2<<t-1),this.putInt(e,t)},s.DataBuffer.prototype.getByte=function(){return this.data.getInt8(this.read++)},s.DataBuffer.prototype.getInt16=function(){var e=this.data.getInt16(this.read);return this.read+=2,e},s.DataBuffer.prototype.getInt24=function(){var e=this.data.getInt16(this.read)<<8^this.data.getInt8(this.read+2);return this.read+=3,e},s.DataBuffer.prototype.getInt32=function(){var e=this.data.getInt32(this.read);return this.read+=4,e},s.DataBuffer.prototype.getInt16Le=function(){var e=this.data.getInt16(this.read,!0);return this.read+=2,e},s.DataBuffer.prototype.getInt24Le=function(){var e=this.data.getInt8(this.read)^this.data.getInt16(this.read+1,!0)<<8;return this.read+=3,e},s.DataBuffer.prototype.getInt32Le=function(){var e=this.data.getInt32(this.read,!0);return this.read+=4,e},s.DataBuffer.prototype.getInt=function(e){a(e);var t=0;do{t=(t<<8)+this.data.getInt8(this.read++),e-=8}while(e>0);return t},s.DataBuffer.prototype.getSignedInt=function(e){var t=this.getInt(e),n=2<<e-2;return t>=n&&(t-=n<<1),t},s.DataBuffer.prototype.getBytes=function(e){var t;return e?(e=Math.min(this.length(),e),t=this.data.slice(this.read,this.read+e),this.read+=e):0===e?t="":(t=0===this.read?this.data:this.data.slice(this.read),this.clear()),t},s.DataBuffer.prototype.bytes=function(e){return void 0===e?this.data.slice(this.read):this.data.slice(this.read,this.read+e)},s.DataBuffer.prototype.at=function(e){return this.data.getUint8(this.read+e)},s.DataBuffer.prototype.setAt=function(e,t){return this.data.setUint8(e,t),this},s.DataBuffer.prototype.last=function(){return this.data.getUint8(this.write-1)},s.DataBuffer.prototype.copy=function(){return new s.DataBuffer(this)},s.DataBuffer.prototype.compact=function(){if(this.read>0){var e=new Uint8Array(this.data.buffer,this.read),t=new Uint8Array(e.byteLength);t.set(e),this.data=new DataView(t),this.write-=this.read,this.read=0}return this},s.DataBuffer.prototype.clear=function(){return this.data=new DataView(new ArrayBuffer(0)),this.read=this.write=0,this},s.DataBuffer.prototype.truncate=function(e){return this.write=Math.max(0,this.length()-e),this.read=Math.min(this.read,this.write),this},s.DataBuffer.prototype.toHex=function(){for(var e="",t=this.read;t<this.data.byteLength;++t){var n=this.data.getUint8(t);n<16&&(e+="0"),e+=n.toString(16)}return e},s.DataBuffer.prototype.toString=function(e){var t=new Uint8Array(this.data,this.read,this.length());if(e=e||"utf8","binary"===e||"raw"===e)return s.binary.raw.encode(t);if("hex"===e)return s.binary.hex.encode(t);if("base64"===e)return s.binary.base64.encode(t);if("utf8"===e)return s.text.utf8.decode(t);if("utf16"===e)return s.text.utf16.decode(t);throw new Error("Invalid encoding: "+e)},s.createBuffer=function(e,t){return t=t||"raw",void 0!==e&&"utf8"===t&&(e=s.encodeUtf8(e)),new s.ByteBuffer(e)},s.fillString=function(e,t){for(var n="";t>0;)1&t&&(n+=e),t>>>=1,t>0&&(e+=e);return n},s.xorBytes=function(e,t,n){for(var r="",i="",o="",s=0,a=0;n>0;--n,++s)i=e.charCodeAt(s)^t.charCodeAt(s),a>=10&&(r+=o,o="",a=0),o+=String.fromCharCode(i),++a;return r+=o,r},s.hexToBytes=function(e){var t="",n=0;for(!0&e.length&&(n=1,t+=String.fromCharCode(parseInt(e[0],16)));n<e.length;n+=2)t+=String.fromCharCode(parseInt(e.substr(n,2),16));return t},s.bytesToHex=function(e){return s.createBuffer(e).toHex()},s.int32ToBytes=function(e){return String.fromCharCode(e>>24&255)+String.fromCharCode(e>>16&255)+String.fromCharCode(e>>8&255)+String.fromCharCode(255&e)};var h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",f=[62,-1,-1,-1,63,52,53,54,55,56,57,58,59,60,61,-1,-1,-1,64,-1,-1,-1,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,-1,-1,-1,-1,-1,-1,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],p="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";s.encode64=function(e,t){for(var n="",r="",i,o,s,a=0;a<e.length;)i=e.charCodeAt(a++),o=e.charCodeAt(a++),s=e.charCodeAt(a++),n+=h.charAt(i>>2),n+=h.charAt((3&i)<<4|o>>4),isNaN(o)?n+="==":(n+=h.charAt((15&o)<<2|s>>6),n+=isNaN(s)?"=":h.charAt(63&s)),t&&n.length>t&&(r+=n.substr(0,t)+"\r\n",n=n.substr(t));return r+=n,r},s.decode64=function(e){e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");for(var t="",n,r,i,o,s=0;s<e.length;)n=f[e.charCodeAt(s++)-43],r=f[e.charCodeAt(s++)-43],i=f[e.charCodeAt(s++)-43],o=f[e.charCodeAt(s++)-43],t+=String.fromCharCode(n<<2|r>>4),64!==i&&(t+=String.fromCharCode((15&r)<<4|i>>2),64!==o&&(t+=String.fromCharCode((3&i)<<6|o)));return t},s.encodeUtf8=function(e){return unescape(encodeURIComponent(e))},s.decodeUtf8=function(e){return decodeURIComponent(escape(e))},s.binary={raw:{},hex:{},base64:{},base58:{},baseN:{encode:o.encode,decode:o.decode}},s.binary.raw.encode=function(e){return String.fromCharCode.apply(null,e)},s.binary.raw.decode=function(e,t,n){var r=t;r||(r=new Uint8Array(e.length)),n=n||0;for(var i=n,o=0;o<e.length;++o)r[i++]=e.charCodeAt(o);return t?i-n:r},s.binary.hex.encode=s.bytesToHex,s.binary.hex.decode=function(e,t,n){var r=t;r||(r=new Uint8Array(Math.ceil(e.length/2))),n=n||0;var i=0,o=n;for(1&e.length&&(i=1,r[o++]=parseInt(e[0],16));i<e.length;i+=2)r[o++]=parseInt(e.substr(i,2),16);return t?o-n:r},s.binary.base64.encode=function(e,t){for(var n="",r="",i,o,s,a=0;a<e.byteLength;)i=e[a++],o=e[a++],s=e[a++],n+=h.charAt(i>>2),n+=h.charAt((3&i)<<4|o>>4),isNaN(o)?n+="==":(n+=h.charAt((15&o)<<2|s>>6),n+=isNaN(s)?"=":h.charAt(63&s)),t&&n.length>t&&(r+=n.substr(0,t)+"\r\n",n=n.substr(t));return r+=n,r},s.binary.base64.decode=function(e,t,n){var r=t,i,o,s,a;r||(r=new Uint8Array(3*Math.ceil(e.length/4))),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,""),n=n||0;for(var l=0,u=n;l<e.length;)i=f[e.charCodeAt(l++)-43],o=f[e.charCodeAt(l++)-43],s=f[e.charCodeAt(l++)-43],a=f[e.charCodeAt(l++)-43],r[u++]=i<<2|o>>4,64!==s&&(r[u++]=(15&o)<<4|s>>2,64!==a&&(r[u++]=(3&s)<<6|a));return t?u-n:r.subarray(0,u)},s.binary.base58.encode=function(e,t){return s.binary.baseN.encode(e,p,t)},s.binary.base58.decode=function(e,t){return s.binary.baseN.decode(e,p,t)},s.text={utf8:{},utf16:{}},s.text.utf8.encode=function(e,t,n){e=s.encodeUtf8(e);var r=t;r||(r=new Uint8Array(e.length)),n=n||0;for(var i=n,o=0;o<e.length;++o)r[i++]=e.charCodeAt(o);return t?i-n:r},s.text.utf8.decode=function(e){return s.decodeUtf8(String.fromCharCode.apply(null,e))},s.text.utf16.encode=function(e,t,n){var r=t;r||(r=new Uint8Array(2*e.length));var i=new Uint16Array(r.buffer);n=n||0;for(var o=n,s=n,a=0;a<e.length;++a)i[s++]=e.charCodeAt(a),o+=2;return t?o-n:r},s.text.utf16.decode=function(e){return String.fromCharCode.apply(null,new Uint16Array(e.buffer))},s.deflate=function(e,t,n){if(t=s.decode64(e.deflate(s.encode64(t)).rval),n){var r=2,i=t.charCodeAt(1);32&i&&(r=6),t=t.substring(r,t.length-4)}return t},s.inflate=function(e,t,n){var r=e.inflate(s.encode64(t)).rval;return null===r?null:s.decode64(r)};var d=function(e,t,n){if(!e)throw new Error("WebStorage not available.");var r;if(null===n?r=e.removeItem(t):(n=s.encode64(JSON.stringify(n)),r=e.setItem(t,n)),void 0!==r&&!0!==r.rval){var i=new Error(r.error.message);throw i.id=r.error.id,i.name=r.error.name,i}},m=function(e,t){if(!e)throw new Error("WebStorage not available.");var n=e.getItem(t);if(e.init)if(null===n.rval){if(n.error){var r=new Error(n.error.message);throw r.id=n.error.id,r.name=n.error.name,r}n=null}else n=n.rval;return null!==n&&(n=JSON.parse(s.decode64(n))),n},g=function(e,t,n,r){var i=m(e,t);null===i&&(i={}),i[n]=r,d(e,t,i)},y=function(e,t,n){var r=m(e,t);return null!==r&&(r=n in r?r[n]:null),r},v=function(e,t,n){var r=m(e,t);if(null!==r&&n in r){delete r[n];var i=!0;for(var o in r){i=!1;break}i&&(r=null),d(e,t,r)}},b=function(e,t){d(e,t,null)},_=function(e,t,n){var r=null,i;void 0===n&&(n=["web","flash"]);var o=!1,s=null;for(var a in n){i=n[a];try{if("flash"===i||"both"===i){if(null===t[0])throw new Error("Flash local storage not available.");r=e.apply(this,t),o="flash"===i}"web"!==i&&"both"!==i||(t[0]=localStorage,r=e.apply(this,t),o=!0)}catch(e){s=e}if(o)break}if(!o)throw s;return r};s.setItem=function(e,t,n,r,i){_(g,arguments,i)},s.getItem=function(e,t,n,r){return _(y,arguments,r)},s.removeItem=function(e,t,n,r){_(v,arguments,r)},s.clearItems=function(e,t,n){_(b,arguments,n)},s.parseUrl=function(e){var t=/^(https?):\/\/([^:&^\/]*):?(\d*)(.*)$/g;t.lastIndex=0;var n=t.exec(e),r=null===n?null:{full:e,scheme:n[1],host:n[2],port:n[3],path:n[4]};return r&&(r.fullHost=r.host,r.port?80!==r.port&&"http"===r.scheme?r.fullHost+=":"+r.port:443!==r.port&&"https"===r.scheme&&(r.fullHost+=":"+r.port):"http"===r.scheme?r.port=80:"https"===r.scheme&&(r.port=443),r.full=r.scheme+"://"+r.fullHost),r};var w=null;s.getQueryVariables=function(e){var t=function(e){for(var t={},n=e.split("&"),r=0;r<n.length;r++){var i=n[r].indexOf("="),o,s;i>0?(o=n[r].substring(0,i),s=n[r].substring(i+1)):(o=n[r],s=null),o in t||(t[o]=[]),o in Object.prototype||null===s||t[o].push(unescape(s))}return t},n;return void 0===e?(null===w&&(w="undefined"!=typeof window&&window.location&&window.location.search?t(window.location.search.substring(1)):{}),n=w):n=t(e),n},s.parseFragment=function(e){var t=e,n="",r=e.indexOf("?");r>0&&(t=e.substring(0,r),n=e.substring(r+1));var i=t.split("/");i.length>0&&""===i[0]&&i.shift();var o=""===n?{}:s.getQueryVariables(n);return{pathString:t,queryString:n,path:i,query:o}},s.makeRequest=function(e){var t=s.parseFragment(e),n={path:t.pathString,query:t.queryString,getPath:function(e){return void 0===e?t.path:t.path[e]},getQuery:function(e,n){var r;return void 0===e?r=t.query:(r=t.query[e],r&&void 0!==n&&(r=r[n])),r},getQueryLast:function(e,t){var r,i=n.getQuery(e);return r=i?i[i.length-1]:t,r}};return n},s.makeLink=function(e,t,n){e=jQuery.isArray(e)?e.join("/"):e;var r=jQuery.param(t||{});return n=n||"",e+(r.length>0?"?"+r:"")+(n.length>0?"#"+n:"")},s.setPath=function(e,t,n){if("object"==typeof e&&null!==e)for(var r=0,i=t.length;r<i;){var o=t[r++];if(r==i)e[o]=n;else{var s=o in e;(!s||s&&"object"!=typeof e[o]||s&&null===e[o])&&(e[o]={}),e=e[o]}}},s.getPath=function(e,t,n){for(var r=0,i=t.length,o=!0;o&&r<i&&"object"==typeof e&&null!==e;){var s=t[r++];o=s in e,o&&(e=e[s])}return o?e:n},s.deletePath=function(e,t){if("object"==typeof e&&null!==e)for(var n=0,r=t.length;n<r;){var i=t[n++];if(n==r)delete e[i];else{if(!(i in e)||"object"!=typeof e[i]||null===e[i])break;e=e[i]}}},s.isEmpty=function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0},s.format=function(e){for(var t=/%./g,n,r,i=0,o=[],s=0;n=t.exec(e);){r=e.substring(s,t.lastIndex-2),r.length>0&&o.push(r),s=t.lastIndex;var a=n[0][1];switch(a){case"s":case"o":i<arguments.length?o.push(arguments[1+i++]):o.push("<?>");break;case"%":o.push("%");break;default:o.push("<%"+a+"?>")}}return o.push(e.substring(s)),o.join("")},s.formatNumber=function(e,t,n,r){var i=e,o=isNaN(t=Math.abs(t))?2:t,s=void 0===n?",":n,a=void 0===r?".":r,l=i<0?"-":"",u=parseInt(i=Math.abs(+i||0).toFixed(o),10)+"",c=u.length>3?u.length%3:0;return l+(c?u.substr(0,c)+a:"")+u.substr(c).replace(/(\d{3})(?=\d)/g,"$1"+a)+(o?s+Math.abs(i-u).toFixed(o).slice(2):"")},s.formatSize=function(e){return e=e>=1073741824?s.formatNumber(e/1073741824,2,".","")+" GiB":e>=1048576?s.formatNumber(e/1048576,2,".","")+" MiB":e>=1024?s.formatNumber(e/1024,0)+" KiB":s.formatNumber(e,0)+" bytes",e},s.bytesFromIP=function(e){return-1!==e.indexOf(".")?s.bytesFromIPv4(e):-1!==e.indexOf(":")?s.bytesFromIPv6(e):null},s.bytesFromIPv4=function(e){if(e=e.split("."),4!==e.length)return null;for(var t=s.createBuffer(),n=0;n<e.length;++n){var r=parseInt(e[n],10);if(isNaN(r))return null;t.putByte(r)}return t.getBytes()},s.bytesFromIPv6=function(e){var t=0;e=e.split(":").filter(function(e){return 0===e.length&&++t,!0});for(var n=2*(8-e.length+t),r=s.createBuffer(),i=0;i<8;++i)if(e[i]&&0!==e[i].length){var o=s.hexToBytes(e[i]);o.length<2&&r.putByte(0),r.putBytes(o)}else r.fillWithByte(0,n),n=0;return r.getBytes()},s.bytesToIP=function(e){return 4===e.length?s.bytesToIPv4(e):16===e.length?s.bytesToIPv6(e):null},s.bytesToIPv4=function(e){if(4!==e.length)return null;for(var t=[],n=0;n<e.length;++n)t.push(e.charCodeAt(n));return t.join(".")},s.bytesToIPv6=function(e){if(16!==e.length)return null;for(var t=[],n=[],r=0,i=0;i<e.length;i+=2){for(var o=s.bytesToHex(e[i]+e[i+1]);"0"===o[0]&&"0"!==o;)o=o.substr(1);if("0"===o){var a=n[n.length-1],l=t.length;a&&l===a.end+1?(a.end=l,a.end-a.start>n[r].end-n[r].start&&(r=n.length-1)):n.push({start:l,end:l})}t.push(o)}if(n.length>0){var u=n[r];u.end-u.start>0&&(t.splice(u.start,u.end-u.start+1,""),0===u.start&&t.unshift(""),7===u.end&&t.push(""))}return t.join(":")},s.estimateCores=function(e,t){if("function"==typeof e&&(t=e,e={}),e=e||{},"cores"in s&&!e.update)return t(null,s.cores);if("undefined"!=typeof navigator&&"hardwareConcurrency"in navigator&&navigator.hardwareConcurrency>0)return s.cores=navigator.hardwareConcurrency,t(null,s.cores);if("undefined"==typeof Worker)return s.cores=1,t(null,s.cores);if("undefined"==typeof Blob)return s.cores=2,t(null,s.cores);var n=URL.createObjectURL(new Blob(["(",function(){self.addEventListener("message",function(e){for(var t=Date.now(),n=t+4;Date.now()<n;);self.postMessage({st:t,et:n})})}.toString(),")()"],{type:"application/javascript"}));function r(e,a,l){if(0===a){var u=Math.floor(e.reduce(function(e,t){return e+t},0)/e.length);return s.cores=Math.max(1,u),URL.revokeObjectURL(n),t(null,s.cores)}i(l,function(t,n){e.push(o(l,n)),r(e,a-1,l)})}function i(e,t){for(var r=[],i=[],o=0;o<e;++o){var s=new Worker(n);s.addEventListener("message",function(n){if(i.push(n.data),i.length===e){for(var o=0;o<e;++o)r[o].terminate();t(null,i)}}),r.push(s)}for(var o=0;o<e;++o)r[o].postMessage(o)}function o(e,t){for(var n=[],r=0;r<e;++r)for(var i=t[r],o=n[r]=[],s=0;s<e;++s)if(r!==s){var a=t[s];(i.st>a.st&&i.st<a.et||a.st>i.st&&a.st<i.et)&&o.push(s)}return n.reduce(function(e,t){return Math.max(e,t.length)},0)}r([],5,16)}}).call(this,n(3),n(0).Buffer)},function(e,t,n){"use strict";const r=n(15),{ensureMultiaddr:i}=n(392),o=n(811),s=n(24);class a{constructor(e){s(e,"Missing peerId. Use Peer.create(cb) to create one"),this.id=e,this.multiaddrs=new o,this.protocols=new Set,this._connectedMultiaddr=void 0}connect(e){if(e=i(e),!this.multiaddrs.has(e)&&e.toString()!==`/ipfs/${this.id.toB58String()}`)throw new Error("can't be connected to missing multiaddr from set");this._connectedMultiaddr=e}disconnect(){this._connectedMultiaddr=void 0}isConnected(){return this._connectedMultiaddr}}a.create=((e,t)=>{if("function"==typeof e)return t=e,e=null,void r.create((e,n)=>{if(e)return t(e);t(null,new a(n))});"function"==typeof e.toJSON?t(null,new a(e)):r.createFromJSON(e,(e,n)=>t(e,new a(n)))}),a.isPeerInfo=(e=>Boolean("object"==typeof e&&e.id&&e.multiaddrs)),e.exports=a},function(e,t,n){"use strict";var r=n(179),i=n(640);function o(){this.protocol=null,this.slashes=null,this.auth=null,this.host=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.query=null,this.pathname=null,this.path=null,this.href=null}t.parse=w,t.resolve=E,t.resolveObject=S,t.format=k,t.Url=o;var s=/^([a-z0-9.+-]+:)/i,a=/:[0-9]*$/,l=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,u=["<",">",'"',"`"," ","\r","\n","\t"],c=["{","}","|","\\","^","`"].concat(u),h=["'"].concat(c),f=["%","/","?",";","#"].concat(h),p=["/","?","#"],d=255,m=/^[+a-z0-9A-Z_-]{0,63}$/,g=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,y={javascript:!0,"javascript:":!0},v={javascript:!0,"javascript:":!0},b={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},_=n(145);function w(e,t,n){if(e&&i.isObject(e)&&e instanceof o)return e;var r=new o;return r.parse(e,t,n),r}function k(e){return i.isString(e)&&(e=w(e)),e instanceof o?e.format():o.prototype.format.call(e)}function E(e,t){return w(e,!1,!0).resolve(t)}function S(e,t){return e?w(e,!1,!0).resolveObject(t):t}o.prototype.parse=function(e,t,n){if(!i.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+typeof e);var o=e.indexOf("?"),a=-1!==o&&o<e.indexOf("#")?"?":"#",u=e.split(a),c=/\\/g;u[0]=u[0].replace(c,"/"),e=u.join(a);var d=e;if(d=d.trim(),!n&&1===e.split("#").length){var w=l.exec(d);if(w)return this.path=d,this.href=d,this.pathname=w[1],w[2]?(this.search=w[2],this.query=t?_.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var k=s.exec(d);if(k){k=k[0];var E=k.toLowerCase();this.protocol=E,d=d.substr(k.length)}if(n||k||d.match(/^\/\/[^@\/]+@[^@\/]+/)){var S="//"===d.substr(0,2);!S||k&&v[k]||(d=d.substr(2),this.slashes=!0)}if(!v[k]&&(S||k&&!b[k])){for(var x=-1,C=0,A,T;C<p.length;C++){var I=d.indexOf(p[C]);-1!==I&&(-1===x||I<x)&&(x=I)}T=-1===x?d.lastIndexOf("@"):d.lastIndexOf("@",x),-1!==T&&(A=d.slice(0,T),d=d.slice(T+1),this.auth=decodeURIComponent(A)),x=-1;for(var C=0;C<f.length;C++){var I=d.indexOf(f[C]);-1!==I&&(-1===x||I<x)&&(x=I)}-1===x&&(x=d.length),this.host=d.slice(0,x),d=d.slice(x),this.parseHost(),this.hostname=this.hostname||"";var j="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!j)for(var R=this.hostname.split(/\./),C=0,B=R.length;C<B;C++){var O=R[C];if(O&&!O.match(m)){for(var P="",N=0,D=O.length;N<D;N++)O.charCodeAt(N)>127?P+="x":P+=O[N];if(!P.match(m)){var M=R.slice(0,C),F=R.slice(C+1),L=O.match(g);L&&(M.push(L[1]),F.unshift(L[2])),F.length&&(d="/"+F.join(".")+d),this.hostname=M.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),j||(this.hostname=r.toASCII(this.hostname));var U=this.port?":"+this.port:"",q=this.hostname||"";this.host=q+U,this.href+=this.host,j&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==d[0]&&(d="/"+d))}if(!y[E])for(var C=0,B=h.length;C<B;C++){var z=h[C];if(-1!==d.indexOf(z)){var K=encodeURIComponent(z);K===z&&(K=escape(z)),d=d.split(z).join(K)}}var H=d.indexOf("#");-1!==H&&(this.hash=d.substr(H),d=d.slice(0,H));var V=d.indexOf("?");if(-1!==V?(this.search=d.substr(V),this.query=d.substr(V+1),t&&(this.query=_.parse(this.query)),d=d.slice(0,V)):t&&(this.search="",this.query={}),d&&(this.pathname=d),b[E]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){var U=this.pathname||"",$=this.search||"";this.path=U+$}return this.href=this.format(),this},o.prototype.format=function(){var e=this.auth||"";e&&(e=encodeURIComponent(e),e=e.replace(/%3A/i,":"),e+="@");var t=this.protocol||"",n=this.pathname||"",r=this.hash||"",o=!1,s="";this.host?o=e+this.host:this.hostname&&(o=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(o+=":"+this.port)),this.query&&i.isObject(this.query)&&Object.keys(this.query).length&&(s=_.stringify(this.query));var a=this.search||s&&"?"+s||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||b[t])&&!1!==o?(o="//"+(o||""),n&&"/"!==n.charAt(0)&&(n="/"+n)):o||(o=""),r&&"#"!==r.charAt(0)&&(r="#"+r),a&&"?"!==a.charAt(0)&&(a="?"+a),n=n.replace(/[?#]/g,function(e){return encodeURIComponent(e)}),a=a.replace("#","%23"),t+o+n+a+r},o.prototype.resolve=function(e){return this.resolveObject(w(e,!1,!0)).format()},o.prototype.resolveObject=function(e){if(i.isString(e)){var t=new o;t.parse(e,!1,!0),e=t}for(var n=new o,r=Object.keys(this),s=0;s<r.length;s++){var a=r[s];n[a]=this[a]}if(n.hash=e.hash,""===e.href)return n.href=n.format(),n;if(e.slashes&&!e.protocol){for(var l=Object.keys(e),u=0;u<l.length;u++){var c=l[u];"protocol"!==c&&(n[c]=e[c])}return b[n.protocol]&&n.hostname&&!n.pathname&&(n.path=n.pathname="/"),n.href=n.format(),n}if(e.protocol&&e.protocol!==n.protocol){if(!b[e.protocol]){for(var h=Object.keys(e),f=0;f<h.length;f++){var p=h[f];n[p]=e[p]}return n.href=n.format(),n}if(n.protocol=e.protocol,e.host||v[e.protocol])n.pathname=e.pathname;else{for(var d=(e.pathname||"").split("/");d.length&&!(e.host=d.shift()););e.host||(e.host=""),e.hostname||(e.hostname=""),""!==d[0]&&d.unshift(""),d.length<2&&d.unshift(""),n.pathname=d.join("/")}if(n.search=e.search,n.query=e.query,n.host=e.host||"",n.auth=e.auth,n.hostname=e.hostname||e.host,n.port=e.port,n.pathname||n.search){var m=n.pathname||"",g=n.search||"";n.path=m+g}return n.slashes=n.slashes||e.slashes,n.href=n.format(),n}var y=n.pathname&&"/"===n.pathname.charAt(0),_=e.host||e.pathname&&"/"===e.pathname.charAt(0),w=_||y||n.host&&e.pathname,k=w,E=n.pathname&&n.pathname.split("/")||[],d=e.pathname&&e.pathname.split("/")||[],S=n.protocol&&!b[n.protocol];if(S&&(n.hostname="",n.port=null,n.host&&(""===E[0]?E[0]=n.host:E.unshift(n.host)),n.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===d[0]?d[0]=e.host:d.unshift(e.host)),e.host=null),w=w&&(""===d[0]||""===E[0])),_)n.host=e.host||""===e.host?e.host:n.host,n.hostname=e.hostname||""===e.hostname?e.hostname:n.hostname,n.search=e.search,n.query=e.query,E=d;else if(d.length)E||(E=[]),E.pop(),E=E.concat(d),n.search=e.search,n.query=e.query;else if(!i.isNullOrUndefined(e.search)){if(S){n.hostname=n.host=E.shift();var x=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");x&&(n.auth=x.shift(),n.host=n.hostname=x.shift())}return n.search=e.search,n.query=e.query,i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.href=n.format(),n}if(!E.length)return n.pathname=null,n.search?n.path="/"+n.search:n.path=null,n.href=n.format(),n;for(var C=E.slice(-1)[0],A=(n.host||e.host||E.length>1)&&("."===C||".."===C)||""===C,T=0,I=E.length;I>=0;I--)C=E[I],"."===C?E.splice(I,1):".."===C?(E.splice(I,1),T++):T&&(E.splice(I,1),T--);if(!w&&!k)for(;T--;T)E.unshift("..");!w||""===E[0]||E[0]&&"/"===E[0].charAt(0)||E.unshift(""),A&&"/"!==E.join("/").substr(-1)&&E.push("");var j=""===E[0]||E[0]&&"/"===E[0].charAt(0);if(S){n.hostname=n.host=j?"":E.length?E.shift():"";var x=!!(n.host&&n.host.indexOf("@")>0)&&n.host.split("@");x&&(n.auth=x.shift(),n.host=n.hostname=x.shift())}return w=w||n.host&&E.length,w&&!j&&E.unshift(""),E.length?n.pathname=E.join("/"):(n.pathname=null,n.path=null),i.isNull(n.pathname)&&i.isNull(n.search)||(n.path=(n.pathname?n.pathname:"")+(n.search?n.search:"")),n.auth=e.auth||n.auth,n.slashes=n.slashes||e.slashes,n.href=n.format(),n},o.prototype.parseHost=function(){var e=this.host,t=a.exec(e);t&&(t=t[0],":"!==t&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},function(e,t,n){"use strict";var r=n(185);e.exports=function e(t){return r(function(e,t){return e.push(t),e},[],t)}},function(e,t,n){"use strict";t.DAGNode=n(192),t.DAGLink=n(96),t.resolver=n(366),t.util=n(194)},function(e,t,n){e.exports={encode:n(683),decode:n(684),encodingLength:n(685)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(241),i=a(r),o=n(402),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t){(0,s.default)(i.default,e,t)}e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isAsync=void 0;var r=n(652),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}var s="function"==typeof Symbol;function a(e){return s&&"AsyncFunction"===e[Symbol.toStringTag]}function l(e){return a(e)?(0,i.default)(e):e}t.default=l,t.isAsync=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(241),i=u(r),o=n(333),s=u(o),a=n(37),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e,t,n){(0,i.default)(e,(0,s.default)((0,l.default)(t)),n)}e.exports=t.default},function(e,t,n){"use strict";function r(e,{className:t,symbolName:n}){const r=Symbol.for(n),i={[t]:class extends e{constructor(...e){super(...e),Object.defineProperty(this,r,{value:!0})}get[Symbol.toStringTag](){return t}}}[t];return i[`is${t}`]=(e=>!(!e||!e[r])),i}function i(e,{className:t,symbolName:n,withoutNew:r}){const i=Symbol.for(n),o={[t]:function(...t){if(r&&!(this instanceof o))return new o(...t);const n=e.call(this,...t)||this;return n&&!n[i]&&Object.defineProperty(n,i,{value:!0}),n}}[t];return o.prototype=Object.create(e.prototype),o.prototype.constructor=o,Object.defineProperty(o.prototype,Symbol.toStringTag,{get:()=>t}),o[`is${t}`]=(e=>!(!e||!e[i])),o}e.exports=r,e.exports.proto=i},function(e,t,n){"use strict";var r=n(343);e.exports=function e(t,n){if(!t)return function(e,t){return e?r(t,e,n):t(!0)};Array.isArray(t)||(t=Object.keys(t).map(function(e){return t[e]}));var i=0;return function(e,o){if(e)return r(o,e,n);i>=t.length?o(!0):o(null,t[i++])}}},function(e,t,n){(function(t){e.exports=g;var r=n(25),i=n(48),o=n(16),s=n(172),a=n(83),l=n(317).DiffieHellman,u=n(76),c=n(42),h=n(46),f;try{f=n(614)}catch(e){}var p=u.InvalidAlgorithmError,d=u.KeyParseError,m={};function g(e){r.object(e,"options"),r.arrayOfObject(e.parts,"options.parts"),r.string(e.type,"options.type"),r.optionalString(e.comment,"options.comment");var t=i.info[e.type];if("object"!=typeof t)throw new p(e.type);for(var n={},o=0,s;o<e.parts.length;++o){var a=e.parts[o];n[a.name]=a}if(this.type=e.type,this.parts=e.parts,this.part=n,this.comment=void 0,this.source=e.source,this._rfc4253Cache=e._rfc4253Cache,this._hashCache={},this.curve=void 0,"ecdsa"===this.type){var l=this.part.curve.data.toString();this.curve=l,s=i.curves[l].size}else if("ed25519"===this.type||"curve25519"===this.type)s=256,this.curve="curve25519";else{var u=this.part[t.sizePart];s=u.data.length,s=8*s-c.countZeros(u.data)}this.size=s}m.auto=n(615),m.pem=n(92),m.pkcs1=n(318),m.pkcs8=n(176),m.rfc4253=n(93),m.ssh=n(617),m["ssh-private"]=n(238),m.openssh=m["ssh-private"],m.dnssec=n(319),m.putty=n(618),m.ppk=m.putty,g.formats=m,g.prototype.toBuffer=function(e,t){return void 0===e&&(e="ssh"),r.string(e,"format"),r.object(m[e],"formats[format]"),r.optionalObject(t,"options"),"rfc4253"===e?(void 0===this._rfc4253Cache&&(this._rfc4253Cache=m.rfc4253.write(this)),this._rfc4253Cache):m[e].write(this,t)},g.prototype.toString=function(e,t){return this.toBuffer(e,t).toString()},g.prototype.hash=function(e,t){if(r.string(e,"algorithm"),r.optionalString(t,"type"),void 0===t&&(t="ssh"),e=e.toLowerCase(),void 0===i.hashAlgs[e])throw new p(e);var n=e+"||"+t,s;if(this._hashCache[n])return this._hashCache[n];if("ssh"===t)s=this.toBuffer("rfc4253");else{if("spki"!==t)throw new Error("Hash type "+t+" not supported");s=m.pkcs8.pkcs8ToBuffer(this)}var a=o.createHash(e).update(s).digest();return this._hashCache[n]=a,a},g.prototype.fingerprint=function(e,t){void 0===e&&(e="sha256"),void 0===t&&(t="ssh"),r.string(e,"algorithm"),r.string(t,"type");var n={type:"key",hash:this.hash(e,t),algorithm:e,hashType:t};return new s(n)},g.prototype.defaultHashAlgorithm=function(){var e="sha1";return"rsa"===this.type&&(e="sha256"),"dsa"===this.type&&this.size>1024&&(e="sha256"),"ed25519"===this.type&&(e="sha512"),"ecdsa"===this.type&&(e=this.size<=256?"sha256":this.size<=384?"sha384":"sha512"),e},g.prototype.createVerify=function(e){if(void 0===e&&(e=this.defaultHashAlgorithm()),r.string(e,"hash algorithm"),"ed25519"===this.type&&void 0!==f)return new f.Verifier(this,e);if("curve25519"===this.type)throw new Error("Curve25519 keys are not suitable for signing or verification");var n,i,s;try{i=e.toUpperCase(),n=o.createVerify(i)}catch(e){s=e}(void 0===n||s instanceof Error&&s.message.match(/Unknown message digest/))&&(i="RSA-",i+=e.toUpperCase(),n=o.createVerify(i)),r.ok(n,"failed to create verifier");var l=n.verify.bind(n),u=this.toBuffer("pkcs8"),c=this.curve,h=this;return n.verify=function(n,r){if(a.isSignature(n,[2,0]))return n.type===h.type&&((!n.hashAlgorithm||n.hashAlgorithm===e)&&((!n.curve||"ecdsa"!==h.type||n.curve===c)&&l(u,n.toBuffer("asn1"))));if("string"==typeof n||t.isBuffer(n))return l(u,n,r);throw a.isSignature(n,[1,0])?new Error("signature was created by too old a version of sshpk and cannot be verified"):new TypeError("signature must be a string, Buffer, or Signature object")},n},g.prototype.createDiffieHellman=function(){if("rsa"===this.type)throw new Error("RSA keys do not support Diffie-Hellman");return new l(this)},g.prototype.createDH=g.prototype.createDiffieHellman,g.parse=function(e,t,n){"string"!=typeof e&&r.buffer(e,"data"),void 0===t&&(t="auto"),r.string(t,"format"),"string"==typeof n&&(n={filename:n}),r.optionalObject(n,"options"),void 0===n&&(n={}),r.optionalString(n.filename,"options.filename"),void 0===n.filename&&(n.filename="(unnamed)"),r.object(m[t],"formats[format]");try{var i=m[t].read(e,n);return i instanceof h&&(i=i.toPublic()),i.comment||(i.comment=n.filename),i}catch(e){if("KeyEncryptedError"===e.name)throw e;throw new d(n.filename,t,e)}},g.isKey=function(e,t){return c.isCompatible(e,g,t)},g.prototype._sshpkApiVersion=[1,7],g._oldVersionDetect=function(e){return r.func(e.toBuffer),r.func(e.fingerprint),e.createDH?[1,4]:e.defaultHashAlgorithm?[1,3]:e.formats.auto?[1,2]:e.formats.pkcs1?[1,1]:[1,0]}}).call(this,n(0).Buffer)},function(e,t,n){e.exports={bufferSplit:w,addRSAMissing:B,calculateDSAPublic:I,calculateED25519Public:j,calculateX25519Public:R,mpNormalize:x,mpDenormalize:C,ecNormalize:k,countZeros:_,assertCompatible:m,isCompatible:d,opensslKeyDeriv:v,opensshCipherInfo:P,publicFromPrivateECDSA:O,zeroPadToLength:A,writeBitString:S,readBitString:E,pbkdf2:b};var r=n(25),i=n(29).Buffer,o=n(46),s=n(41),a=n(16),l=n(48),u=n(84),c=n(237),h=n(173).BigInteger,f=n(174),p=3;function d(e,t,n){if(null===e||"object"!=typeof e)return!1;if(void 0===n&&(n=t.prototype._sshpkApiVersion),e instanceof t&&t.prototype._sshpkApiVersion[0]==n[0])return!0;for(var r=Object.getPrototypeOf(e),i=0;r.constructor.name!==t.name;)if(r=Object.getPrototypeOf(r),!r||++i>p)return!1;if(r.constructor.name!==t.name)return!1;var o=r._sshpkApiVersion;return void 0===o&&(o=t._oldVersionDetect(e)),!(o[0]!=n[0]||o[1]<n[1])}function m(e,t,n,i){if(void 0===i&&(i="object"),r.ok(e,i+" must not be null"),r.object(e,i+" must be an object"),void 0===n&&(n=t.prototype._sshpkApiVersion),!(e instanceof t&&t.prototype._sshpkApiVersion[0]==n[0])){for(var o=Object.getPrototypeOf(e),s=0;o.constructor.name!==t.name;)o=Object.getPrototypeOf(o),r.ok(o&&++s<=p,i+" must be a "+t.name+" instance");r.strictEqual(o.constructor.name,t.name,i+" must be a "+t.name+" instance");var a=o._sshpkApiVersion;void 0===a&&(a=t._oldVersionDetect(e)),r.ok(a[0]==n[0]&&a[1]>=n[1],i+" must be compatible with "+t.name+" klass version "+n[0]+"."+n[1])}}var g={"des-ede3-cbc":{key:24,iv:8},"aes-128-cbc":{key:16,iv:16},"aes-256-cbc":{key:32,iv:16}},y=8;function v(e,t,n,o){r.buffer(t,"salt"),r.buffer(n,"passphrase"),r.number(o,"iteration count");var s=g[e],l,u,c;r.object(s,"supported cipher"),t=t.slice(0,y);for(var h=i.alloc(0);h.length<s.key+s.iv;){c=[],u&&c.push(u),c.push(n),c.push(t),l=i.concat(c);for(var f=0;f<o;++f)l=a.createHash("md5").update(l).digest();h=i.concat([h,l]),u=l}return{key:h.slice(0,s.key),iv:h.slice(s.key,s.key+s.iv)}}function b(e,t,n,r,o){var s=i.alloc(t.length+4);t.copy(s);for(var l=0,u=[],c=1;l<r;){var h=f(c++);l+=h.length,u.push(h)}return i.concat(u).slice(0,r);function f(t){s.writeUInt32BE(t,s.length-4);var r=a.createHmac(e,o);r.update(s);for(var i=r.digest(),l=i,u=1;u++<n;){r=a.createHmac(e,o),r.update(l),l=r.digest();for(var c=0;c<i.length;++c)i[c]^=l[c]}return i}}function _(e){for(var t=0,n=8;t<e.length;){var r=1<<n;if((e[t]&r)===r)break;n--,n<0&&(t++,n=8)}return 8*t+(8-n)-1}function w(e,t){r.buffer(e),r.string(t);for(var n=[],i=0,o=0,s=0;s<e.length;++s)if(e[s]===t.charCodeAt(o)?++o:o=e[s]===t.charCodeAt(0)?1:0,o>=t.length){var a=s+1;n.push(e.slice(i,a-o)),i=a,o=0}return i<=e.length&&n.push(e.slice(i,e.length)),n}function k(e,t){if(r.buffer(e),0===e[0]&&4===e[1])return t?e:e.slice(1);if(4===e[0]){if(!t)return e}else{for(;0===e[0];)e=e.slice(1);if(2===e[0]||3===e[0])throw new Error("Compressed elliptic curve points are not supported");if(4!==e[0])throw new Error("Not a valid elliptic curve point");if(!t)return e}var n=i.alloc(e.length+1);return n[0]=0,e.copy(n,1),n}function E(e,t){void 0===t&&(t=u.Ber.BitString);var n=e.readString(t,!0);return r.strictEqual(n[0],0,"bit strings with unused bits are not supported (0x"+n[0].toString(16)+")"),n.slice(1)}function S(e,t,n){void 0===n&&(n=u.Ber.BitString);var r=i.alloc(t.length+1);r[0]=0,t.copy(r,1),e.writeBuffer(r,n)}function x(e){for(r.buffer(e);e.length>1&&0===e[0]&&0==(128&e[1]);)e=e.slice(1);if(128==(128&e[0])){var t=i.alloc(e.length+1);t[0]=0,e.copy(t,1),e=t}return e}function C(e){for(r.buffer(e);e.length>1&&0===e[0];)e=e.slice(1);return e}function A(e,t){for(r.buffer(e),r.number(t);e.length>t;)r.equal(e[0],0),e=e.slice(1);for(;e.length<t;){var n=i.alloc(e.length+1);n[0]=0,e.copy(n,1),e=n}return e}function T(e){var t=i.from(e.toByteArray());return t=x(t),t}function I(e,t,n){r.buffer(e),r.buffer(t),r.buffer(n),e=new h(e),t=new h(t),n=new h(n);var i=e.modPow(n,t),o=T(i);return o}function j(e){r.buffer(e);var t=f.sign.keyPair.fromSeed(new Uint8Array(e));return i.from(t.publicKey)}function R(e){r.buffer(e);var t=f.box.keyPair.fromSeed(new Uint8Array(e));return i.from(t.publicKey)}function B(e){r.object(e),m(e,o,[1,1]);var t=new h(e.part.d.data),n;if(!e.part.dmodp){var i=new h(e.part.p.data),s=t.mod(i.subtract(1));n=T(s),e.part.dmodp={name:"dmodp",data:n},e.parts.push(e.part.dmodp)}if(!e.part.dmodq){var a=new h(e.part.q.data),l=t.mod(a.subtract(1));n=T(l),e.part.dmodq={name:"dmodq",data:n},e.parts.push(e.part.dmodq)}}function O(e,t){r.string(e,"curveName"),r.buffer(t);var n=l.curves[e],o=new h(n.p),a=new h(n.a),u=new h(n.b),f=new c.ECCurveFp(o,a,u),p=f.decodePointHex(n.G.toString("hex")),d=new h(x(t)),m=p.multiply(d);m=i.from(f.encodePointHex(m),"hex");var g=[];g.push({name:"curve",data:i.from(e)}),g.push({name:"Q",data:m});var y=new s({type:"ecdsa",curve:f,parts:g});return y}function P(e){var t={};switch(e){case"3des-cbc":t.keySize=24,t.blockSize=8,t.opensslName="des-ede3-cbc";break;case"blowfish-cbc":t.keySize=16,t.blockSize=8,t.opensslName="bf-cbc";break;case"aes128-cbc":case"aes128-ctr":case"aes128-gcm@openssh.com":t.keySize=16,t.blockSize=16,t.opensslName="aes-128-"+e.slice(7,10);break;case"aes192-cbc":case"aes192-ctr":case"aes192-gcm@openssh.com":t.keySize=24,t.blockSize=16,t.opensslName="aes-192-"+e.slice(7,10);break;case"aes256-cbc":case"aes256-ctr":case"aes256-gcm@openssh.com":t.keySize=32,t.blockSize=16,t.opensslName="aes-256-"+e.slice(7,10);break;default:throw new Error('Unsupported openssl cipher "'+e+'"')}return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(402),i=a(r),o=n(201),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t){(0,i.default)(s.default,e,t)}e.exports=t.default},function(e,t,n){"use strict";(function(e){const r=n(4),i=n(56),o=n(27),s=n(28).Key,a=n(409),l=n(271),u=n(59),c=n(123).Record,h=n(20),f=n(15);t.convertBuffer=((e,t)=>{i.digest(e,"sha2-256",t)}),t.convertPeerId=((e,t)=>{i.digest(e.id,"sha2-256",t)}),t.bufferToKey=(e=>new s("/"+t.encodeBase32(e),!1)),t.keyForPublicKey=(t=>e.concat([e.from("/pk/"),t.id])),t.isPublicKeyKey=(e=>"/pk/"===e.slice(0,4).toString()),t.fromPublicKeyKey=(e=>new f(e.slice(4))),t.now=(()=>Date.now()),t.encodeBase32=(e=>{const t=new a.Encoder;return t.write(e).finalize()}),t.decodeBase32=(t=>{const n=new a.Decoder;return e.from(n.write(t).finalize())}),t.sortClosestPeers=((e,n,r)=>{u(e,(e,r)=>{t.convertPeerId(e,(t,i)=>{if(t)return r(t);r(null,{peer:e,distance:l(i,n)})})},(e,n)=>{if(e)return r(e);r(null,n.sort(t.xorCompare).map(e=>e.peer))})}),t.xorCompare=((e,t)=>l.compare(e.distance,t.distance)),t.pathSize=((e,t)=>Math.ceil(e/t)),t.createPutRecord=((e,t,n)=>{const r=new Date,i=new c(e,t,r);h(()=>{n(null,i.serialize())})}),t.logger=((e,t)=>{const n=["libp2p","dht"];t&&n.push(t),e&&n.push(`${e.toB58String().slice(0,8)}`),r.formatters.b=(e=>o.toB58String(e));const i=r(n.join(":"));return i.error=r(n.concat(["error"]).join(":")),i})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(57),i=r(n(1120)),o=i.Data,s=["raw","directory","file","metadata","symlink","hamt-sharded-directory"],a=["directory","hamt-sharded-directory"];function l(e,t){if(!(this instanceof l))return new l(e,t);if(-1===s.indexOf(e))throw new Error("Type: "+e+" is not valid");this.type=e,this.data=t,this.blockSizes=[],this.addBlockSize=(e=>{this.blockSizes.push(e)}),this.removeBlockSize=(e=>{this.blockSizes.splice(e,1)}),this.fileSize=(()=>{if(a.indexOf(this.type)>=0)return;let e=0;return this.blockSizes.forEach(t=>{e+=t}),t&&(e+=t.length),e}),this.marshal=(()=>{let e;switch(this.type){case"raw":e=o.DataType.Raw;break;case"directory":e=o.DataType.Directory;break;case"file":e=o.DataType.File;break;case"metadata":e=o.DataType.Metadata;break;case"symlink":e=o.DataType.Symlink;break;case"hamt-sharded-directory":e=o.DataType.HAMTShard;break;default:throw new Error(`Unkown type: "${this.type}"`)}let t=this.fileSize(),n=this.data;this.data&&this.data.length||(n=void 0);let r=this.blockSizes;return this.blockSizes&&this.blockSizes.length||(r=void 0),o.encode({Type:e,Data:n,filesize:t,blocksizes:r,hashType:this.hashType,fanout:this.fanout})})}l.unmarshal=(e=>{const t=o.decode(e);t.Data||(t.Data=void 0);const n=new l(s[t.Type],t.Data);return n.blockSizes=t.blocksizes,n}),t=e.exports=l},function(e,t,n){e.exports=k;var r=n(25),i=n(29).Buffer,o=n(48),s=n(16),a=n(172),l=n(83),u=n(76),c=n(14),h=n(42),f=n(317),p=f.generateECDSA,d=f.generateED25519,m=n(614),g=n(174),y=n(41),v=u.InvalidAlgorithmError,b=u.KeyParseError,_=u.KeyEncryptedError,w={};function k(e){r.object(e,"options"),y.call(this,e),this._pubCache=void 0}w.auto=n(615),w.pem=n(92),w.pkcs1=n(318),w.pkcs8=n(176),w.rfc4253=n(93),w["ssh-private"]=n(238),w.openssh=w["ssh-private"],w.ssh=w["ssh-private"],w.dnssec=n(319),c.inherits(k,y),k.formats=w,k.prototype.toBuffer=function(e,t){return void 0===e&&(e="pkcs1"),r.string(e,"format"),r.object(w[e],"formats[format]"),r.optionalObject(t,"options"),w[e].write(this,t)},k.prototype.hash=function(e,t){return this.toPublic().hash(e,t)},k.prototype.fingerprint=function(e,t){return this.toPublic().fingerprint(e,t)},k.prototype.toPublic=function(){if(this._pubCache)return this._pubCache;for(var e=o.info[this.type],t=[],n=0;n<e.parts.length;++n){var r=e.parts[n];t.push(this.part[r])}return this._pubCache=new y({type:this.type,source:this,parts:t}),this.comment&&(this._pubCache.comment=this.comment),this._pubCache},k.prototype.derive=function(e){var t,n,o;if(r.string(e,"type"),"ed25519"===this.type&&"curve25519"===e)return t=this.part.k.data,0===t[0]&&(t=t.slice(1)),o=g.box.keyPair.fromSecretKey(new Uint8Array(t)),n=i.from(o.publicKey),new k({type:"curve25519",parts:[{name:"A",data:h.mpNormalize(n)},{name:"k",data:h.mpNormalize(t)}]});if("curve25519"===this.type&&"ed25519"===e)return t=this.part.k.data,0===t[0]&&(t=t.slice(1)),o=g.sign.keyPair.fromSeed(new Uint8Array(t)),n=i.from(o.publicKey),new k({type:"ed25519",parts:[{name:"A",data:h.mpNormalize(n)},{name:"k",data:h.mpNormalize(t)}]});throw new Error("Key derivation not supported from "+this.type+" to "+e)},k.prototype.createVerify=function(e){return this.toPublic().createVerify(e)},k.prototype.createSign=function(e){if(void 0===e&&(e=this.defaultHashAlgorithm()),r.string(e,"hash algorithm"),"ed25519"===this.type&&void 0!==m)return new m.Signer(this,e);if("curve25519"===this.type)throw new Error("Curve25519 keys are not suitable for signing or verification");var t,n,o;try{n=e.toUpperCase(),t=s.createSign(n)}catch(e){o=e}(void 0===t||o instanceof Error&&o.message.match(/Unknown message digest/))&&(n="RSA-",n+=e.toUpperCase(),t=s.createSign(n)),r.ok(t,"failed to create verifier");var a=t.sign.bind(t),u=this.toBuffer("pkcs1"),c=this.type,h=this.curve;return t.sign=function(){var t=a(u);return"string"==typeof t&&(t=i.from(t,"binary")),t=l.parse(t,c,"asn1"),t.hashAlgorithm=e,t.curve=h,t},t},k.parse=function(e,t,n){"string"!=typeof e&&r.buffer(e,"data"),void 0===t&&(t="auto"),r.string(t,"format"),"string"==typeof n&&(n={filename:n}),r.optionalObject(n,"options"),void 0===n&&(n={}),r.optionalString(n.filename,"options.filename"),void 0===n.filename&&(n.filename="(unnamed)"),r.object(w[t],"formats[format]");try{var i=w[t].read(e,n);return r.ok(i instanceof k,"key is not a private key"),i.comment||(i.comment=n.filename),i}catch(e){if("KeyEncryptedError"===e.name)throw e;throw new b(n.filename,t,e)}},k.isPrivateKey=function(e,t){return h.isCompatible(e,k,t)},k.generate=function(e,t){switch(void 0===t&&(t={}),r.object(t,"options"),e){case"ecdsa":return void 0===t.curve&&(t.curve="nistp256"),r.string(t.curve,"options.curve"),p(t.curve);case"ed25519":return d();default:throw new Error('Key generation not supported with key type "'+e+'"')}},k.prototype._sshpkApiVersion=[1,6],k._oldVersionDetect=function(e){return r.func(e.toPublic),r.func(e.createSign),e.derive?[1,3]:e.defaultHashAlgorithm?[1,2]:e.formats.auto?[1,1]:[1,0]}},function(e,t,n){"use strict";(function(r){Object.defineProperty(t,"__esModule",{value:!0});var i=n(180),o;o=i.hasNextTick?r.nextTick:i.hasSetImmediate?setImmediate:i.fallback,t.default=(0,i.wrap)(o),e.exports=t.default}).call(this,n(3))},function(e,t,n){var r=n(29).Buffer,i={dsa:{parts:["p","q","g","y"],sizePart:"p"},rsa:{parts:["e","n"],sizePart:"n"},ecdsa:{parts:["curve","Q"],sizePart:"Q"},ed25519:{parts:["A"],sizePart:"A"}};i.curve25519=i.ed25519;var o={dsa:{parts:["p","q","g","y","x"]},rsa:{parts:["n","e","d","iqmp","p","q"]},ecdsa:{parts:["curve","Q","d"]},ed25519:{parts:["A","k"]}};o.curve25519=o.ed25519;var s={md5:!0,sha1:!0,sha256:!0,sha384:!0,sha512:!0},a={nistp256:{size:256,pkcs8oid:"1.2.840.10045.3.1.7",p:r.from("00ffffffff 00000001 00000000 0000000000000000 ffffffff ffffffff ffffffff".replace(/ /g,""),"hex"),a:r.from("00FFFFFFFF 00000001 00000000 0000000000000000 FFFFFFFF FFFFFFFF FFFFFFFC".replace(/ /g,""),"hex"),b:r.from("5ac635d8 aa3a93e7 b3ebbd55 769886bc651d06b0 cc53b0f6 3bce3c3e 27d2604b".replace(/ /g,""),"hex"),s:r.from("00c49d3608 86e70493 6a6678e1 139d26b7819f7e90".replace(/ /g,""),"hex"),n:r.from("00ffffffff 00000000 ffffffff ffffffffbce6faad a7179e84 f3b9cac2 fc632551".replace(/ /g,""),"hex"),G:r.from("046b17d1f2 e12c4247 f8bce6e5 63a440f277037d81 2deb33a0 f4a13945 d898c2964fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e162bce3357 6b315ece cbb64068 37bf51f5".replace(/ /g,""),"hex")},nistp384:{size:384,pkcs8oid:"1.3.132.0.34",p:r.from("00ffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff fffffffeffffffff 00000000 00000000 ffffffff".replace(/ /g,""),"hex"),a:r.from("00FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFEFFFFFFFF 00000000 00000000 FFFFFFFC".replace(/ /g,""),"hex"),b:r.from("b3312fa7 e23ee7e4 988e056b e3f82d19181d9c6e fe814112 0314088f 5013875ac656398d 8a2ed19d 2a85c8ed d3ec2aef".replace(/ /g,""),"hex"),s:r.from("00a335926a a319a27a 1d00896a 6773a4827acdac73".replace(/ /g,""),"hex"),n:r.from("00ffffffff ffffffff ffffffff ffffffffffffffff ffffffff c7634d81 f4372ddf581a0db2 48b0a77a ecec196a ccc52973".replace(/ /g,""),"hex"),G:r.from("04aa87ca22 be8b0537 8eb1c71e f320ad746e1d3b62 8ba79b98 59f741e0 82542a385502f25d bf55296c 3a545e38 72760ab73617de4a 96262c6f 5d9e98bf 9292dc29f8f41dbd 289a147c e9da3113 b5f0b8c00a60b1ce 1d7e819d 7a431d7c 90ea0e5f".replace(/ /g,""),"hex")},nistp521:{size:521,pkcs8oid:"1.3.132.0.35",p:r.from("01ffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffffffff".replace(/ /g,""),"hex"),a:r.from("01FFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFFFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFC".replace(/ /g,""),"hex"),b:r.from("51953eb961 8e1c9a1f 929a21a0 b68540eea2da725b 99b315f3 b8b48991 8ef109e156193951 ec7e937b 1652c0bd 3bb1bf073573df88 3d2c34f1 ef451fd4 6b503f00".replace(/ /g,""),"hex"),s:r.from("00d09e8800 291cb853 96cc6717 393284aaa0da64ba".replace(/ /g,""),"hex"),n:r.from("01ffffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff fffffffa51868783 bf2f966b 7fcc0148 f709a5d03bb5c9b8 899c47ae bb6fb71e 91386409".replace(/ /g,""),"hex"),G:r.from("0400c6 858e06b7 0404e9cd 9e3ecb66 2395b4429c648139 053fb521 f828af60 6b4d3dbaa14b5e77 efe75928 fe1dc127 a2ffa8de3348b3c1 856a429b f97e7e31 c2e5bd660118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd998f54449 579b4468 17afbd17 273e662c97ee7299 5ef42640 c550b901 3fad0761353c7086 a272c240 88be9476 9fd16650".replace(/ /g,""),"hex")}};e.exports={info:i,privInfo:o,hashAlgs:s,curves:a}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){function n(e,t){if(r("noDeprecation"))return e;var n=!1;function i(){if(!n){if(r("throwDeprecation"))throw new Error(t);r("traceDeprecation")?console.trace(t):console.warn(t),n=!0}return e.apply(this,arguments)}return i}function r(e){try{if(!t.localStorage)return!1}catch(e){return!1}var n=t.localStorage[e];return null!=n&&"true"===String(n).toLowerCase()}e.exports=n}).call(this,n(8))},function(e,t,n){"use strict";const r=n(391),i=n(813),o=n(368);t=e.exports,t.aes=i,t.hmac=r,t.keys=o,t.randomBytes=n(256),t.pbkdf2=n(825)},function(e,t,n){"use strict";const r=n(896),i=n(897);t.encode=r,t.decode=i.decode,t.decodeFromReader=i.decodeFromReader},function(e,t,n){(function(t){var r=n(26),i=n(212),o=n(990),s=function(){},a=/^v?\.0/.test(t.version),l=function(e){return"function"==typeof e},u=function(e){return!!a&&(!!o&&((e instanceof(o.ReadStream||s)||e instanceof(o.WriteStream||s))&&l(e.close)))},c=function(e){return e.setHeader&&l(e.abort)},h=function(e,t,n,o){o=r(o);var a=!1;e.on("close",function(){a=!0}),i(e,{readable:t,writable:n},function(e){if(e)return o(e);a=!0,o()});var h=!1;return function(t){if(!a&&!h)return h=!0,u(e)?e.close(s):c(e)?e.abort():l(e.destroy)?e.destroy():void o(t||new Error("stream was destroyed"))}},f=function(e){e()},p=function(e,t){return e.pipe(t)},d=function(){var e=Array.prototype.slice.call(arguments),t=l(e[e.length-1]||s)&&e.pop()||s,n;if(Array.isArray(e[0])&&(e=e[0]),e.length<2)throw new Error("pump requires two streams per minimum");var r=e.map(function(i,o){var s=o<e.length-1,a=o>0;return h(i,s,a,function(e){n||(n=e),e&&r.forEach(f),s||(r.forEach(f),t(n))})});return e.reduce(p)};e.exports=d}).call(this,n(3))},function(e,t,n){(function(e){function n(e,t){for(var n=0,r=e.length-1;r>=0;r--){var i=e[r];"."===i?e.splice(r,1):".."===i?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function r(e){"string"!=typeof e&&(e+="");var t=0,n=-1,r=!0,i;for(i=e.length-1;i>=0;--i)if(47===e.charCodeAt(i)){if(!r){t=i+1;break}}else-1===n&&(r=!1,n=i+1);return-1===n?"":e.slice(t,n)}function i(e,t){if(e.filter)return e.filter(t);for(var n=[],r=0;r<e.length;r++)t(e[r],r,e)&&n.push(e[r]);return n}t.resolve=function(){for(var t="",r=!1,o=arguments.length-1;o>=-1&&!r;o--){var s=o>=0?arguments[o]:e.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(t=s+"/"+t,r="/"===s.charAt(0))}return t=n(i(t.split("/"),function(e){return!!e}),!r).join("/"),(r?"/":"")+t||"."},t.normalize=function(e){var r=t.isAbsolute(e),s="/"===o(e,-1);return e=n(i(e.split("/"),function(e){return!!e}),!r).join("/"),e||r||(e="."),e&&s&&(e+="/"),(r?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(i(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},t.relative=function(e,n){function r(e){for(var t=0;t<e.length&&""===e[t];t++);for(var n=e.length-1;n>=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var i=r(e.split("/")),o=r(n.split("/")),s=Math.min(i.length,o.length),a=s,l=0;l<s;l++)if(i[l]!==o[l]){a=l;break}for(var u=[],l=a;l<i.length;l++)u.push("..");return u=u.concat(o.slice(a)),u.join("/")},t.sep="/",t.delimiter=":",t.dirname=function(e){if("string"!=typeof e&&(e+=""),0===e.length)return".";for(var t=e.charCodeAt(0),n=47===t,r=-1,i=!0,o=e.length-1;o>=1;--o)if(t=e.charCodeAt(o),47===t){if(!i){r=o;break}}else i=!1;return-1===r?n?"/":".":n&&1===r?"/":e.slice(0,r)},t.basename=function(e,t){var n=r(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!=typeof e&&(e+="");for(var t=-1,n=0,r=-1,i=!0,o=0,s=e.length-1;s>=0;--s){var a=e.charCodeAt(s);if(47!==a)-1===r&&(i=!1,r=s+1),46===a?-1===t?t=s:1!==o&&(o=1):-1!==t&&(o=-1);else if(!i){n=s+1;break}}return-1===t||-1===r||0===o||1===o&&t===r-1&&t===n+1?"":e.slice(t,r)};var o="b"==="ab".substr(-1)?function(e,t,n){return e.substr(t,n)}:function(e,t,n){return t<0&&(t=e.length+t),e.substr(t,n)}}).call(this,n(3))},function(e,t,n){var r;!function(i){"use strict";var o,s=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,l=Math.ceil,u=Math.floor,c="[BigNumber Error] ",h=c+"Number primitive has more than 15 significant digits: ",f=1e14,p=14,d=9007199254740991,m=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],g=1e7,y=1e9;function v(e){var t,n,r,i=H.prototype={constructor:H,toString:null,valueOf:null},o=new H(1),C=20,A=4,T=-7,I=21,j=-1e7,R=1e7,B=!1,O=1,P=0,N={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},D="0123456789abcdefghijklmnopqrstuvwxyz",M,F,L,U,q,z,K;function H(e,t){var i,o,a,l,c,f,m,g,y=this;if(!(y instanceof H))return new H(e,t);if(null==t){if(e&&!0===e._isBigNumber)return y.s=e.s,void(!e.c||e.e>R?y.c=y.e=null:e.e<j?y.c=[y.e=0]:(y.e=e.e,y.c=e.c.slice()));if((f="number"==typeof e)&&0*e==0){if(y.s=1/e<0?(e=-e,-1):1,e===~~e){for(l=0,c=e;c>=10;c/=10,l++);return void(l>R?y.c=y.e=null:(y.e=l,y.c=[e]))}g=String(e)}else{if(!s.test(g=String(e)))return r(y,g,f);y.s=45==g.charCodeAt(0)?(g=g.slice(1),-1):1}(l=g.indexOf("."))>-1&&(g=g.replace(".","")),(c=g.search(/e/i))>0?(l<0&&(l=c),l+=+g.slice(c+1),g=g.substring(0,c)):l<0&&(l=g.length)}else{if(k(t,2,D.length,"Base"),10==t)return y=new H(e),G(y,C+y.e+1,A);if(g=String(e),f="number"==typeof e){if(0*e!=0)return r(y,g,f,t);if(y.s=1/e<0?(g=g.slice(1),-1):1,H.DEBUG&&g.replace(/^0\.0*|\./,"").length>15)throw Error(h+e)}else y.s=45===g.charCodeAt(0)?(g=g.slice(1),-1):1;for(i=D.slice(0,t),l=c=0,m=g.length;c<m;c++)if(i.indexOf(o=g.charAt(c))<0){if("."==o){if(c>l){l=m;continue}}else if(!a&&(g==g.toUpperCase()&&(g=g.toLowerCase())||g==g.toLowerCase()&&(g=g.toUpperCase()))){a=!0,c=-1,l=0;continue}return r(y,String(e),f,t)}f=!1,g=n(g,t,10,y.s),(l=g.indexOf("."))>-1?g=g.replace(".",""):l=g.length}for(c=0;48===g.charCodeAt(c);c++);for(m=g.length;48===g.charCodeAt(--m););if(g=g.slice(c,++m)){if(m-=c,f&&H.DEBUG&&m>15&&(e>d||e!==u(e)))throw Error(h+y.s*e);if((l=l-c-1)>R)y.c=y.e=null;else if(l<j)y.c=[y.e=0];else{if(y.e=l,y.c=[],c=(l+1)%p,l<0&&(c+=p),c<m){for(c&&y.c.push(+g.slice(0,c)),m-=p;c<m;)y.c.push(+g.slice(c,c+=p));c=p-(g=g.slice(c)).length}else c-=m;for(;c--;g+="0");y.c.push(+g)}}else y.c=[y.e=0]}function V(e,t,n,r){var i,o,s,a,l;if(null==n?n=A:k(n,0,8),!e.c)return e.toString();if(i=e.c[0],s=e.e,null==t)l=_(e.c),l=1==r||2==r&&(s<=T||s>=I)?S(l,s):x(l,s,"0");else if(e=G(new H(e),t,n),o=e.e,l=_(e.c),a=l.length,1==r||2==r&&(t<=o||o<=T)){for(;a<t;l+="0",a++);l=S(l,o)}else if(t-=s,l=x(l,o,"0"),o+1>a){if(--t>0)for(l+=".";t--;l+="0");}else if(t+=o-a,t>0)for(o+1==a&&(l+=".");t--;l+="0");return e.s<0&&i?"-"+l:l}function $(e,t){for(var n,r=1,i=new H(e[0]);r<e.length;r++){if(n=new H(e[r]),!n.s){i=n;break}t.call(i,n)&&(i=n)}return i}function W(e,t,n){for(var r=1,i=t.length;!t[--i];t.pop());for(i=t[0];i>=10;i/=10,r++);return(n=r+n*p-1)>R?e.c=e.e=null:n<j?e.c=[e.e=0]:(e.e=n,e.c=t),e}function G(e,t,n,r){var i,o,s,a,c,h,d,g=e.c,y=m;if(g){e:{for(i=1,a=g[0];a>=10;a/=10,i++);if(o=t-i,o<0)o+=p,s=t,c=g[h=0],d=c/y[i-s-1]%10|0;else if(h=l((o+1)/p),h>=g.length){if(!r)break e;for(;g.length<=h;g.push(0));c=d=0,i=1,o%=p,s=o-p+1}else{for(c=a=g[h],i=1;a>=10;a/=10,i++);o%=p,s=o-p+i,d=s<0?0:c/y[i-s-1]%10|0}if(r=r||t<0||null!=g[h+1]||(s<0?c:c%y[i-s-1]),r=n<4?(d||r)&&(0==n||n==(e.s<0?3:2)):d>5||5==d&&(4==n||r||6==n&&(o>0?s>0?c/y[i-s]:0:g[h-1])%10&1||n==(e.s<0?8:7)),t<1||!g[0])return g.length=0,r?(t-=e.e+1,g[0]=y[(p-t%p)%p],e.e=-t||0):g[0]=e.e=0,e;if(0==o?(g.length=h,a=1,h--):(g.length=h+1,a=y[p-o],g[h]=s>0?u(c/y[i-s]%y[s])*a:0),r)for(;;){if(0==h){for(o=1,s=g[0];s>=10;s/=10,o++);for(s=g[0]+=a,a=1;s>=10;s/=10,a++);o!=a&&(e.e++,g[0]==f&&(g[0]=1));break}if(g[h]+=a,g[h]!=f)break;g[h--]=0,a=1}for(o=g.length;0===g[--o];g.pop());}e.e>R?e.c=e.e=null:e.e<j&&(e.c=[e.e=0])}return e}function Y(e){var t,n=e.e;return null===n?e.toString():(t=_(e.c),t=n<=T||n>=I?S(t,n):x(t,n,"0"),e.s<0?"-"+t:t)}return H.clone=v,H.ROUND_UP=0,H.ROUND_DOWN=1,H.ROUND_CEIL=2,H.ROUND_FLOOR=3,H.ROUND_HALF_UP=4,H.ROUND_HALF_DOWN=5,H.ROUND_HALF_EVEN=6,H.ROUND_HALF_CEIL=7,H.ROUND_HALF_FLOOR=8,H.EUCLID=9,H.config=H.set=function(e){var t,n;if(null!=e){if("object"!=typeof e)throw Error(c+"Object expected: "+e);if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(n=e[t],k(n,0,y,t),C=n),e.hasOwnProperty(t="ROUNDING_MODE")&&(n=e[t],k(n,0,8,t),A=n),e.hasOwnProperty(t="EXPONENTIAL_AT")&&(n=e[t],n&&n.pop?(k(n[0],-y,0,t),k(n[1],0,y,t),T=n[0],I=n[1]):(k(n,-y,y,t),T=-(I=n<0?-n:n))),e.hasOwnProperty(t="RANGE"))if(n=e[t],n&&n.pop)k(n[0],-y,-1,t),k(n[1],1,y,t),j=n[0],R=n[1];else{if(k(n,-y,y,t),!n)throw Error(c+t+" cannot be zero: "+n);j=-(R=n<0?-n:n)}if(e.hasOwnProperty(t="CRYPTO")){if(n=e[t],n!==!!n)throw Error(c+t+" not true or false: "+n);if(n){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw B=!n,Error(c+"crypto unavailable");B=n}else B=n}if(e.hasOwnProperty(t="MODULO_MODE")&&(n=e[t],k(n,0,9,t),O=n),e.hasOwnProperty(t="POW_PRECISION")&&(n=e[t],k(n,0,y,t),P=n),e.hasOwnProperty(t="FORMAT")){if(n=e[t],"object"!=typeof n)throw Error(c+t+" not an object: "+n);N=n}if(e.hasOwnProperty(t="ALPHABET")){if(n=e[t],"string"!=typeof n||/^.$|[+-.\s]|(.).*\1/.test(n))throw Error(c+t+" invalid: "+n);D=n}}return{DECIMAL_PLACES:C,ROUNDING_MODE:A,EXPONENTIAL_AT:[T,I],RANGE:[j,R],CRYPTO:B,MODULO_MODE:O,POW_PRECISION:P,FORMAT:N,ALPHABET:D}},H.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!H.DEBUG)return!0;var t,n,r=e.c,i=e.e,o=e.s;e:if("[object Array]"=={}.toString.call(r)){if((1===o||-1===o)&&i>=-y&&i<=y&&i===u(i)){if(0===r[0]){if(0===i&&1===r.length)return!0;break e}if(t=(i+1)%p,t<1&&(t+=p),String(r[0]).length==t){for(t=0;t<r.length;t++)if(n=r[t],n<0||n>=f||n!==u(n))break e;if(0!==n)return!0}}}else if(null===r&&null===i&&(null===o||1===o||-1===o))return!0;throw Error(c+"Invalid BigNumber: "+e)},H.maximum=H.max=function(){return $(arguments,i.lt)},H.minimum=H.min=function(){return $(arguments,i.gt)},H.random=(M=9007199254740992,F=Math.random()*M&2097151?function(){return u(Math.random()*M)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)},function(e){var t,n,r,i,s,a=0,h=[],f=new H(o);if(null==e?e=C:k(e,0,y),i=l(e/p),B)if(crypto.getRandomValues){for(t=crypto.getRandomValues(new Uint32Array(i*=2));a<i;)s=131072*t[a]+(t[a+1]>>>11),s>=9e15?(n=crypto.getRandomValues(new Uint32Array(2)),t[a]=n[0],t[a+1]=n[1]):(h.push(s%1e14),a+=2);a=i/2}else{if(!crypto.randomBytes)throw B=!1,Error(c+"crypto unavailable");for(t=crypto.randomBytes(i*=7);a<i;)s=281474976710656*(31&t[a])+1099511627776*t[a+1]+4294967296*t[a+2]+16777216*t[a+3]+(t[a+4]<<16)+(t[a+5]<<8)+t[a+6],s>=9e15?crypto.randomBytes(7).copy(t,a):(h.push(s%1e14),a+=7);a=i/7}if(!B)for(;a<i;)s=F(),s<9e15&&(h[a++]=s%1e14);for(i=h[--a],e%=p,i&&e&&(s=m[p-e],h[a]=u(i/s)*s);0===h[a];h.pop(),a--);if(a<0)h=[r=0];else{for(r=-1;0===h[0];h.splice(0,1),r-=p);for(a=1,s=h[0];s>=10;s/=10,a++);a<p&&(r-=p-a)}return f.e=r,f.c=h,f}),H.sum=function(){for(var e=1,t=arguments,n=new H(t[0]);e<t.length;)n=n.plus(t[e++]);return n},n=function(){var e="0123456789";function n(e,t,n,r){for(var i,o=[0],s,a=0,l=e.length;a<l;){for(s=o.length;s--;o[s]*=t);for(o[0]+=r.indexOf(e.charAt(a++)),i=0;i<o.length;i++)o[i]>n-1&&(null==o[i+1]&&(o[i+1]=0),o[i+1]+=o[i]/n|0,o[i]%=n)}return o.reverse()}return function(r,i,o,s,a){var l,u,c,h,f,p,d,m,g=r.indexOf("."),y=C,v=A;for(g>=0&&(h=P,P=0,r=r.replace(".",""),m=new H(i),p=m.pow(r.length-g),P=h,m.c=n(x(_(p.c),p.e,"0"),10,o,e),m.e=m.c.length),d=n(r,i,o,a?(l=D,e):(l=e,D)),c=h=d.length;0==d[--h];d.pop());if(!d[0])return l.charAt(0);if(g<0?--c:(p.c=d,p.e=c,p.s=s,p=t(p,m,y,v,o),d=p.c,f=p.r,c=p.e),u=c+y+1,g=d[u],h=o/2,f=f||u<0||null!=d[u+1],f=v<4?(null!=g||f)&&(0==v||v==(p.s<0?3:2)):g>h||g==h&&(4==v||f||6==v&&1&d[u-1]||v==(p.s<0?8:7)),u<1||!d[0])r=f?x(l.charAt(1),-y,l.charAt(0)):l.charAt(0);else{if(d.length=u,f)for(--o;++d[--u]>o;)d[u]=0,u||(++c,d=[1].concat(d));for(h=d.length;!d[--h];);for(g=0,r="";g<=h;r+=l.charAt(d[g++]));r=x(r,c,l.charAt(0))}return r}}(),t=function(){function e(e,t,n){var r,i,o,s,a=0,l=e.length,u=t%g,c=t/g|0;for(e=e.slice();l--;)o=e[l]%g,s=e[l]/g|0,r=c*o+s*u,i=u*o+r%g*g+a,a=(i/n|0)+(r/g|0)+c*s,e[l]=i%n;return a&&(e=[a].concat(e)),e}function t(e,t,n,r){var i,o;if(n!=r)o=n>r?1:-1;else for(i=o=0;i<n;i++)if(e[i]!=t[i]){o=e[i]>t[i]?1:-1;break}return o}function n(e,t,n,r){for(var i=0;n--;)e[n]-=i,i=e[n]<t[n]?1:0,e[n]=i*r+e[n]-t[n];for(;!e[0]&&e.length>1;e.splice(0,1));}return function(r,i,o,s,a){var l,c,h,d,m,g,y,v,_,w,k,E,S,x,C,A,T,I=r.s==i.s?1:-1,j=r.c,R=i.c;if(!(j&&j[0]&&R&&R[0]))return new H(r.s&&i.s&&(j?!R||j[0]!=R[0]:R)?j&&0==j[0]||!R?0*I:I/0:NaN);for(v=new H(I),_=v.c=[],c=r.e-i.e,I=o+c+1,a||(a=f,c=b(r.e/p)-b(i.e/p),I=I/p|0),h=0;R[h]==(j[h]||0);h++);if(R[h]>(j[h]||0)&&c--,I<0)_.push(1),d=!0;else{for(x=j.length,A=R.length,h=0,I+=2,m=u(a/(R[0]+1)),m>1&&(R=e(R,m,a),j=e(j,m,a),A=R.length,x=j.length),S=A,w=j.slice(0,A),k=w.length;k<A;w[k++]=0);T=R.slice(),T=[0].concat(T),C=R[0],R[1]>=a/2&&C++;do{if(m=0,l=t(R,w,A,k),l<0){if(E=w[0],A!=k&&(E=E*a+(w[1]||0)),m=u(E/C),m>1)for(m>=a&&(m=a-1),g=e(R,m,a),y=g.length,k=w.length;1==t(g,w,y,k);)m--,n(g,A<y?T:R,y,a),y=g.length,l=1;else 0==m&&(l=m=1),g=R.slice(),y=g.length;if(y<k&&(g=[0].concat(g)),n(w,g,k,a),k=w.length,-1==l)for(;t(R,w,A,k)<1;)m++,n(w,A<k?T:R,k,a),k=w.length}else 0===l&&(m++,w=[0]);_[h++]=m,w[0]?w[k++]=j[S]||0:(w=[j[S]],k=1)}while((S++<x||null!=w[0])&&I--);d=null!=w[0],_[0]||_.splice(0,1)}if(a==f){for(h=1,I=_[0];I>=10;I/=10,h++);G(v,o+(v.e=h+c*p-1)+1,s,d)}else v.e=c,v.r=+d;return v}}(),L=/^(-?)0([xbo])(?=\w[\w.]*$)/i,U=/^([^.]+)\.$/,q=/^\.([^.]+)$/,z=/^-?(Infinity|NaN)$/,K=/^\s*\+(?=[\w.])|^\s+|\s+$/g,r=function(e,t,n,r){var i,o=n?t:t.replace(K,"");if(z.test(o))e.s=isNaN(o)?null:o<0?-1:1;else{if(!n&&(o=o.replace(L,function(e,t,n){return i="x"==(n=n.toLowerCase())?16:"b"==n?2:8,r&&r!=i?e:t}),r&&(i=r,o=o.replace(U,"$1").replace(q,"0.$1")),t!=o))return new H(o,i);if(H.DEBUG)throw Error(c+"Not a"+(r?" base "+r:"")+" number: "+t);e.s=null}e.c=e.e=null},i.absoluteValue=i.abs=function(){var e=new H(this);return e.s<0&&(e.s=1),e},i.comparedTo=function(e,t){return w(this,new H(e,t))},i.decimalPlaces=i.dp=function(e,t){var n,r,i,o=this;if(null!=e)return k(e,0,y),null==t?t=A:k(t,0,8),G(new H(o),e+o.e+1,t);if(!(n=o.c))return null;if(r=((i=n.length-1)-b(this.e/p))*p,i=n[i])for(;i%10==0;i/=10,r--);return r<0&&(r=0),r},i.dividedBy=i.div=function(e,n){return t(this,new H(e,n),C,A)},i.dividedToIntegerBy=i.idiv=function(e,n){return t(this,new H(e,n),0,1)},i.exponentiatedBy=i.pow=function(e,t){var n,r,i,s,a,h,f,d,m,g=this;if(e=new H(e),e.c&&!e.isInteger())throw Error(c+"Exponent not an integer: "+Y(e));if(null!=t&&(t=new H(t)),h=e.e>14,!g.c||!g.c[0]||1==g.c[0]&&!g.e&&1==g.c.length||!e.c||!e.c[0])return m=new H(Math.pow(+Y(g),h?2-E(e):+Y(e))),t?m.mod(t):m;if(f=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new H(NaN);r=!f&&g.isInteger()&&t.isInteger(),r&&(g=g.mod(t))}else{if(e.e>9&&(g.e>0||g.e<-1||(0==g.e?g.c[0]>1||h&&g.c[1]>=24e7:g.c[0]<8e13||h&&g.c[0]<=9999975e7)))return s=g.s<0&&E(e)?-0:0,g.e>-1&&(s=1/s),new H(f?1/s:s);P&&(s=l(P/p+2))}for(h?(n=new H(.5),f&&(e.s=1),d=E(e)):(i=Math.abs(+Y(e)),d=i%2),m=new H(o);;){if(d){if(m=m.times(g),!m.c)break;s?m.c.length>s&&(m.c.length=s):r&&(m=m.mod(t))}if(i){if(i=u(i/2),0===i)break;d=i%2}else if(e=e.times(n),G(e,e.e+1,1),e.e>14)d=E(e);else{if(i=+Y(e),0===i)break;d=i%2}g=g.times(g),s?g.c&&g.c.length>s&&(g.c.length=s):r&&(g=g.mod(t))}return r?m:(f&&(m=o.div(m)),t?m.mod(t):s?G(m,P,A,a):m)},i.integerValue=function(e){var t=new H(this);return null==e?e=A:k(e,0,8),G(t,t.e+1,e)},i.isEqualTo=i.eq=function(e,t){return 0===w(this,new H(e,t))},i.isFinite=function(){return!!this.c},i.isGreaterThan=i.gt=function(e,t){return w(this,new H(e,t))>0},i.isGreaterThanOrEqualTo=i.gte=function(e,t){return 1===(t=w(this,new H(e,t)))||0===t},i.isInteger=function(){return!!this.c&&b(this.e/p)>this.c.length-2},i.isLessThan=i.lt=function(e,t){return w(this,new H(e,t))<0},i.isLessThanOrEqualTo=i.lte=function(e,t){return-1===(t=w(this,new H(e,t)))||0===t},i.isNaN=function(){return!this.s},i.isNegative=function(){return this.s<0},i.isPositive=function(){return this.s>0},i.isZero=function(){return!!this.c&&0==this.c[0]},i.minus=function(e,t){var n,r,i,o,s=this,a=s.s;if(e=new H(e,t),t=e.s,!a||!t)return new H(NaN);if(a!=t)return e.s=-t,s.plus(e);var l=s.e/p,u=e.e/p,c=s.c,h=e.c;if(!l||!u){if(!c||!h)return c?(e.s=-t,e):new H(h?s:NaN);if(!c[0]||!h[0])return h[0]?(e.s=-t,e):new H(c[0]?s:3==A?-0:0)}if(l=b(l),u=b(u),c=c.slice(),a=l-u){for((o=a<0)?(a=-a,i=c):(u=l,i=h),i.reverse(),t=a;t--;i.push(0));i.reverse()}else for(r=(o=(a=c.length)<(t=h.length))?a:t,a=t=0;t<r;t++)if(c[t]!=h[t]){o=c[t]<h[t];break}if(o&&(i=c,c=h,h=i,e.s=-e.s),t=(r=h.length)-(n=c.length),t>0)for(;t--;c[n++]=0);for(t=f-1;r>a;){if(c[--r]<h[r]){for(n=r;n&&!c[--n];c[n]=t);--c[n],c[r]+=f}c[r]-=h[r]}for(;0==c[0];c.splice(0,1),--u);return c[0]?W(e,c,u):(e.s=3==A?-1:1,e.c=[e.e=0],e)},i.modulo=i.mod=function(e,n){var r,i,o=this;return e=new H(e,n),!o.c||!e.s||e.c&&!e.c[0]?new H(NaN):!e.c||o.c&&!o.c[0]?new H(o):(9==O?(i=e.s,e.s=1,r=t(o,e,0,3),e.s=i,r.s*=i):r=t(o,e,0,O),e=o.minus(r.times(e)),e.c[0]||1!=O||(e.s=o.s),e)},i.multipliedBy=i.times=function(e,t){var n,r,i,o,s,a,l,u,c,h,d,m,y,v,_,w=this,k=w.c,E=(e=new H(e,t)).c;if(!(k&&E&&k[0]&&E[0]))return!w.s||!e.s||k&&!k[0]&&!E||E&&!E[0]&&!k?e.c=e.e=e.s=null:(e.s*=w.s,k&&E?(e.c=[0],e.e=0):e.c=e.e=null),e;for(r=b(w.e/p)+b(e.e/p),e.s*=w.s,l=k.length,h=E.length,l<h&&(y=k,k=E,E=y,i=l,l=h,h=i),i=l+h,y=[];i--;y.push(0));for(v=f,_=g,i=h;--i>=0;){for(n=0,d=E[i]%_,m=E[i]/_|0,s=l,o=i+s;o>i;)u=k[--s]%_,c=k[s]/_|0,a=m*u+c*d,u=d*u+a%_*_+y[o]+n,n=(u/v|0)+(a/_|0)+m*c,y[o--]=u%v;y[o]=n}return n?++r:y.splice(0,1),W(e,y,r)},i.negated=function(){var e=new H(this);return e.s=-e.s||null,e},i.plus=function(e,t){var n,r=this,i=r.s;if(e=new H(e,t),t=e.s,!i||!t)return new H(NaN);if(i!=t)return e.s=-t,r.minus(e);var o=r.e/p,s=e.e/p,a=r.c,l=e.c;if(!o||!s){if(!a||!l)return new H(i/0);if(!a[0]||!l[0])return l[0]?e:new H(a[0]?r:0*i)}if(o=b(o),s=b(s),a=a.slice(),i=o-s){for(i>0?(s=o,n=l):(i=-i,n=a),n.reverse();i--;n.push(0));n.reverse()}for(i=a.length,t=l.length,i-t<0&&(n=l,l=a,a=n,t=i),i=0;t;)i=(a[--t]=a[t]+l[t]+i)/f|0,a[t]=f===a[t]?0:a[t]%f;return i&&(a=[i].concat(a),++s),W(e,a,s)},i.precision=i.sd=function(e,t){var n,r,i,o=this;if(null!=e&&e!==!!e)return k(e,1,y),null==t?t=A:k(t,0,8),G(new H(o),e,t);if(!(n=o.c))return null;if(i=n.length-1,r=i*p+1,i=n[i]){for(;i%10==0;i/=10,r--);for(i=n[0];i>=10;i/=10,r++);}return e&&o.e+1>r&&(r=o.e+1),r},i.shiftedBy=function(e){return k(e,-d,d),this.times("1e"+e)},i.squareRoot=i.sqrt=function(){var e,n,r,i,o,s=this,a=s.c,l=s.s,u=s.e,c=C+4,h=new H("0.5");if(1!==l||!a||!a[0])return new H(!l||l<0&&(!a||a[0])?NaN:a?s:1/0);if(l=Math.sqrt(+Y(s)),0==l||l==1/0?(n=_(a),(n.length+u)%2==0&&(n+="0"),l=Math.sqrt(+n),u=b((u+1)/2)-(u<0||u%2),l==1/0?n="1e"+u:(n=l.toExponential(),n=n.slice(0,n.indexOf("e")+1)+u),r=new H(n)):r=new H(l+""),r.c[0])for(u=r.e,l=u+c,l<3&&(l=0);;)if(o=r,r=h.times(o.plus(t(s,o,c,1))),_(o.c).slice(0,l)===(n=_(r.c)).slice(0,l)){if(r.e<u&&--l,n=n.slice(l-3,l+1),"9999"!=n&&(i||"4999"!=n)){+n&&(+n.slice(1)||"5"!=n.charAt(0))||(G(r,r.e+C+2,1),e=!r.times(r).eq(s));break}if(!i&&(G(o,o.e+C+2,0),o.times(o).eq(s))){r=o;break}c+=4,l+=4,i=1}return G(r,r.e+C+1,A,e)},i.toExponential=function(e,t){return null!=e&&(k(e,0,y),e++),V(this,e,t,1)},i.toFixed=function(e,t){return null!=e&&(k(e,0,y),e=e+this.e+1),V(this,e,t)},i.toFormat=function(e,t,n){var r,i=this;if(null==n)null!=e&&t&&"object"==typeof t?(n=t,t=null):e&&"object"==typeof e?(n=e,e=t=null):n=N;else if("object"!=typeof n)throw Error(c+"Argument not an object: "+n);if(r=i.toFixed(e,t),i.c){var o,s=r.split("."),a=+n.groupSize,l=+n.secondaryGroupSize,u=n.groupSeparator||"",h=s[0],f=s[1],p=i.s<0,d=p?h.slice(1):h,m=d.length;if(l&&(o=a,a=l,l=o,m-=o),a>0&&m>0){for(o=m%a||a,h=d.substr(0,o);o<m;o+=a)h+=u+d.substr(o,a);l>0&&(h+=u+d.slice(o)),p&&(h="-"+h)}r=f?h+(n.decimalSeparator||"")+((l=+n.fractionGroupSize)?f.replace(new RegExp("\\d{"+l+"}\\B","g"),"$&"+(n.fractionGroupSeparator||"")):f):h}return(n.prefix||"")+r+(n.suffix||"")},i.toFraction=function(e){var n,r,i,s,a,l,u,h,f,d,g,y,v=this,b=v.c;if(null!=e&&(u=new H(e),!u.isInteger()&&(u.c||1!==u.s)||u.lt(o)))throw Error(c+"Argument "+(u.isInteger()?"out of range: ":"not an integer: ")+Y(u));if(!b)return new H(v);for(n=new H(o),f=r=new H(o),i=h=new H(o),y=_(b),a=n.e=y.length-v.e-1,n.c[0]=m[(l=a%p)<0?p+l:l],e=!e||u.comparedTo(n)>0?a>0?n:f:u,l=R,R=1/0,u=new H(y),h.c[0]=0;d=t(u,n,0,1),s=r.plus(d.times(i)),1!=s.comparedTo(e);)r=i,i=s,f=h.plus(d.times(s=f)),h=s,n=u.minus(d.times(s=n)),u=s;return s=t(e.minus(r),i,0,1),h=h.plus(s.times(f)),r=r.plus(s.times(i)),h.s=f.s=v.s,a*=2,g=t(f,i,a,A).minus(v).abs().comparedTo(t(h,r,a,A).minus(v).abs())<1?[f,i]:[h,r],R=l,g},i.toNumber=function(){return+Y(this)},i.toPrecision=function(e,t){return null!=e&&k(e,1,y),V(this,e,t,2)},i.toString=function(e){var t,r=this,i=r.s,o=r.e;return null===o?i?(t="Infinity",i<0&&(t="-"+t)):t="NaN":(null==e?t=o<=T||o>=I?S(_(r.c),o):x(_(r.c),o,"0"):10===e?(r=G(new H(r),C+o+1,A),t=x(_(r.c),r.e,"0")):(k(e,2,D.length,"Base"),t=n(x(_(r.c),o,"0"),10,e,i,!0)),i<0&&r.c[0]&&(t="-"+t)),t},i.valueOf=i.toJSON=function(){return Y(this)},i._isBigNumber=!0,a&&(i[Symbol.toStringTag]="BigNumber",i[Symbol.for("nodejs.util.inspect.custom")]=i.valueOf),null!=e&&H.set(e),H}function b(e){var t=0|e;return e>0||e===t?t:t-1}function _(e){for(var t,n,r=1,i=e.length,o=e[0]+"";r<i;){for(t=e[r++]+"",n=p-t.length;n--;t="0"+t);o+=t}for(i=o.length;48===o.charCodeAt(--i););return o.slice(0,i+1||1)}function w(e,t){var n,r,i=e.c,o=t.c,s=e.s,a=t.s,l=e.e,u=t.e;if(!s||!a)return null;if(n=i&&!i[0],r=o&&!o[0],n||r)return n?r?0:-a:s;if(s!=a)return s;if(n=s<0,r=l==u,!i||!o)return r?0:!i^n?1:-1;if(!r)return l>u^n?1:-1;for(a=(l=i.length)<(u=o.length)?l:u,s=0;s<a;s++)if(i[s]!=o[s])return i[s]>o[s]^n?1:-1;return l==u?0:l>u^n?1:-1}function k(e,t,n,r){if(e<t||e>n||e!==u(e))throw Error(c+(r||"Argument")+("number"==typeof e?e<t||e>n?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function E(e){var t=e.c.length-1;return b(e.e/p)==t&&e.c[t]%2!=0}function S(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function x(e,t,n){var r,i;if(t<0){for(i=n+".";++t;i+=n);e=i+e}else if(r=e.length,++t>r){for(i=n,t-=r;--t;i+=n);e+=i}else t<r&&(e=e.slice(0,t)+"."+e.slice(t));return e}o=v(),o.default=o.BigNumber=o,r=function(){return o}.call(t,n,t,e),void 0===r||(e.exports=r)}(this)},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(715);function o(e,t,n,i){if("function"==typeof n&&(i=n,n=void 0),!i)throw new Error("Missing callback");o.digest(e,t,n,(e,o)=>{if(e)return i(e);i(null,r.encode(o,t,n))})}e.exports=o,o.Buffer=t,o.multihash=r,o.digest=function(e,t,n,r){if("function"==typeof n&&(r=n,n=void 0),!r)throw new Error("Missing callback");let i=r,s;n&&(i=((e,t)=>{if(e)return r(e);r(null,t.slice(0,n))}));try{s=o.createHash(t)}catch(e){return i(e)}s(e,i)},o.createHash=function(e){if(e=r.coerceCode(e),!o.functions[e])throw new Error("multihash function "+e+" not yet supported");return o.functions[e]},o.functions={17:i.sha1,18:i.sha2256,19:i.sha2512,20:i.sha3512,21:i.sha3384,22:i.sha3256,23:i.sha3224,24:i.shake128,25:i.shake256,26:i.keccak224,27:i.keccak256,28:i.keccak384,29:i.keccak512,34:i.murmur3128,35:i.murmur332,86:i.dblSha2256},i.addBlake(o.functions)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){var r=n(729),i=n(733),o=function(e){if(!e)return null;var t={};return Object.keys(e).forEach(function(n){t[n]=e[n].value}),t};e.exports=function(e,n){if(n||(n={}),!e)throw new Error("Pass in a .proto string or a protobuf-schema parsed object");var s="object"!=typeof e||t.isBuffer(e)?r.parse(e):e,a=function(){var e=this;i(s,n.encodings||{}).forEach(function(t){e[t.name]=o(t.values)||t})};return a.prototype.toString=function(){return r.stringify(s)},a.prototype.toJSON=function(){return s},new a}}).call(this,n(0).Buffer)},function(e,t){function n(){}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(110),i=a(r),o=n(334),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,i.default)(s.default),e.exports=t.default},function(e,t,n){"use strict";(function(r){const i=n(686);t=e.exports=s,t.encode=a,t.decode=l,t.isEncoded=u,t.names=Object.freeze(Object.keys(i.names)),t.codes=Object.freeze(Object.keys(i.codes));const o=new Error("Unsupported encoding");function s(e,t){if(!t)throw new Error("requires an encoded buffer");const n=h(e),i=r.from(n.code),o=n.name;return c(o,t),r.concat([i,t])}function a(e,t){const n=h(e),i=n.name;return s(i,r.from(n.encode(t)))}function l(e){r.isBuffer(e)&&(e=e.toString());const t=e.substring(0,1);e=e.substring(1,e.length),"string"==typeof e&&(e=r.from(e));const n=h(t);return r.from(n.decode(e.toString()))}function u(e){if(r.isBuffer(e)&&(e=e.toString()),"[object String]"!==Object.prototype.toString.call(e))return!1;const t=e.substring(0,1);try{const e=h(t);return e.name}catch(e){return!1}}function c(e,t){const n=h(e);n.decode(t.toString())}function h(e){let t;if(i.names[e])t=i.names[e];else{if(!i.codes[e])throw o;t=i.codes[e]}if(!t.isImplemented())throw new Error("Base "+e+" is not implemented yet");return t}}).call(this,n(0).Buffer)},function(e,t,n){t.source=n(188),t.through=n(709),t.sink=n(348),t.duplex=n(349)},function(e,t,n){e.exports=o;var r=n(6).EventEmitter,i=n(1);function o(){r.call(this)}i(o,r),o.Readable=n(258),o.Writable=n(786),o.Duplex=n(787),o.Transform=n(788),o.PassThrough=n(789),o.Stream=o,o.prototype.pipe=function(e,t){var n=this;function i(t){e.writable&&!1===e.write(t)&&n.pause&&n.pause()}function o(){n.readable&&n.resume&&n.resume()}n.on("data",i),e.on("drain",o),e._isStdio||t&&!1===t.end||(n.on("end",a),n.on("close",l));var s=!1;function a(){s||(s=!0,e.end())}function l(){s||(s=!0,"function"==typeof e.destroy&&e.destroy())}function u(e){if(c(),0===r.listenerCount(this,"error"))throw e}function c(){n.removeListener("data",i),e.removeListener("drain",o),n.removeListener("end",a),n.removeListener("close",l),n.removeListener("error",u),e.removeListener("error",u),n.removeListener("end",c),n.removeListener("close",c),e.removeListener("close",c)}return n.on("error",u),e.on("error",u),n.on("end",c),n.on("close",c),e.on("close",c),e.emit("pipe",n),e}},function(e,t){function n(e,t){"function"==typeof e&&(t=e,e=!1);var n=[],r,i,o;function s(e,t){e&&(r=e,i&&c(r)),i=t,u()}function a(e){o=o||e||!0,u()}function l(e){o||(i?c(r,e):n.push(e))}return e?{push:l,end:a,source:s,buffer:n}:(s.push=l,s.end=a,s.buffer=n,s);function u(){i&&(r?c(r):!n.length&&o?c(o):n.length&&c(null,n.shift()))}function c(e,n){var r=i;if(e&&t){var o=t;t=null,o(!0===e?null:e)}i=null,r(e,n)}}e.exports=n},function(e,t,n){"use strict";t.Connection=n(939)},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){"use strict";function r(e){return e}var i=n(151);e.exports=function e(t){return t?(t=i(t),function(e){return function(n,r){e(n,function(n,i){try{i=n?null:t(i)}catch(t){return e(t,function(){return r(t)})}r(n,i)})}}):r}},function(e,t,n){"use strict";var r=n(345);e.exports=function e(t){return t=r(t),function(e){return function n(r,i){for(var o,s=!0;s;)s=!1,o=!0,e(r,function(e,r){if(!e&&!t(r))return o?s=!0:n(e,i);i(e,r)}),o=!1}}}},function(e,t){e.exports=r;var n=Object.prototype.hasOwnProperty;function r(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var i in r)n.call(r,i)&&(e[i]=r[i])}return e}},function(e,t,n){(function(r){var i=n(12),o=n(461);function s(e){e.destroy?e.destroy():console.error("warning, stream-to-pull-stream: \nthe wrapped node-stream does not implement `destroy`, \nthis may cause resource leaks.")}function a(e,t,n){var i,a=!1,l;function u(){l||(l=!0,n&&n(!0===i?null:i))}function c(){a||(a=!0,f(),i?u():e(i=!0,u))}function h(t){f(),i||e(i=t,u)}function f(){t.on("finish",c),t.removeListener("close",c),t.removeListener("error",h)}t.on("close",c),t.on("finish",c),t.on("error",h),r.nextTick(function(){o(function(n){e(null,function(e,r){if(i=i||e,!0===e)return t._isStdio?u():t.end();if(i=i||e)return s(t),u(i);if(t._isStdio)t.write(r,function(){n()});else{var o=t.write(r);!1===o?t.once("drain",n):n()}})})})}function l(e,t,n){function r(i){t.forEach(function(t){e.removeListener(t,r)}),n(i)}return t.forEach(function(t){e.on(t,r)}),e}function u(e){var t=!1,n=!1,r;function i(){var t=e.read();if(null!==t&&r){var n=r;r=null,n(null,t)}}return e.on("readable",function(){n=!0,r&&i()}).on("end",function(){t=!0,r&&r(t)}).on("error",function(e){t=e,r&&r(t)}),function(e,o){r=o,t?o(t):n&&i()}}function c(e){var t=[],n=[],r,i=!1,o;function a(){for(;(t.length||r)&&n.length;)n.shift()(t.length?null:r,t.shift());!t.length&&i&&(i=!1,e.resume())}return e.on("data",function(n){t.push(n),a(),t.length&&e.pause&&(i=!0,e.pause())}),e.on("end",function(){r=!0,a()}),e.on("close",function(){r=!0,a()}),e.on("error",function(e){r=e,a()}),function(t,i){if(!i)throw new Error("*must* provide cb");if(t){function o(){for(;n.length;)n.shift()(t);i(t)}if(r)return o();e.once("close",o),s(e)}else n.push(i),a()}}var h=c,f=function(e,t){return function(n){return a(n,e,t)}},p=function(e){return c(e)};t=e.exports=function(e,t){return e.writable&&e.write?e.readable?function(n){return a(n,e,t),c(e)}:f(e,t):p(e)},t.sink=f,t.source=p,t.read=h,t.read1=c,t.read2=u,t.duplex=function(e,t){return{source:p(e),sink:f(e,t)}},t.transform=function(e){return function(t){var n=p(e);return f(e)(t),n}}}).call(this,n(3))},function(e,t,n){var r=n(681),i="123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz";e.exports=r(i)},function(e,t,n){"use strict";e.exports=function e(t){return function(e,n){n(t)}}},function(e,t,n){"use strict";const r=n(22),i=I("dns4"),o=I("dns6"),s=T(I("dnsaddr"),i,o),a=T(I("ip4"),I("ip6")),l=T(A(a,I("tcp")),A(s,I("tcp"))),u=A(a,I("udp")),c=A(u,I("utp")),h=T(A(s,I("tcp")),s),f=T(A(l,I("ws")),A(h,I("ws"))),p=T(A(l,I("wss")),A(h,I("wss"))),d=T(A(l,I("http")),A(a,I("http")),A(h,I("http")),A(h)),m=T(A(l,I("https")),A(a,I("https")),A(h,I("https"))),g=T(A(f,I("p2p-webrtc-star"),I("ipfs")),A(p,I("p2p-webrtc-star"),I("ipfs"))),y=T(A(f,I("p2p-websocket-star"),I("ipfs")),A(p,I("p2p-websocket-star"),I("ipfs")),A(f,I("p2p-websocket-star")),A(p,I("p2p-websocket-star"))),v=T(A(d,I("p2p-webrtc-direct")),A(m,I("p2p-webrtc-direct"))),b=T(f,p,d,m,g,v,l,c),_=T(A(b,I("p2p-stardust"),I("ipfs")),A(b,I("p2p-stardust")));let w=T(A(b,I("ipfs")),g,I("ipfs"));const k=T(A(w,I("p2p-circuit"),w),A(w,I("p2p-circuit")),A(I("p2p-circuit"),w),A(b,I("p2p-circuit")),A(I("p2p-circuit"),b),I("p2p-circuit")),E=()=>T(A(k,E),k),S=E(),x=T(A(S,w,S),A(w,S),A(S,w),S,w);function C(e){return function t(n){if(!r.isMultiaddr(n))try{n=r(n)}catch(e){return!1}let i=e(n.protoNames());return null!==i&&0===i.length}}function A(){const e=Array.from(arguments);function t(t){return t.length<e.length?null:(e.some(e=>{if(t="function"==typeof e?e().partialMatch(t):e.partialMatch(t),null===t)return!0}),t)}return{toString:function(){return"{ "+e.join(" ")+" }"},input:e,matches:C(t),partialMatch:t}}function T(){const e=Array.from(arguments);function t(t){let n=null;return e.some(e=>{const r="function"==typeof e?e().partialMatch(t):e.partialMatch(t);if(r)return n=r,!0}),n}const n={toString:function(){return"{ "+e.join(" ")+" }"},input:e,matches:C(t),partialMatch:t};return n}function I(e){const t=e;function n(e){if("string"==typeof e)try{e=r(e)}catch(e){return!1}const n=e.protoNames();return 1===n.length&&n[0]===t}function i(e){return 0===e.length?null:e[0]===t?e.slice(1):null}return{toString:function(){return t},matches:n,partialMatch:i}}t.DNS=h,t.DNS4=i,t.DNS6=o,t.IP=a,t.TCP=l,t.UDP=u,t.UTP=c,t.HTTP=d,t.HTTPS=m,t.WebSockets=f,t.WebSocketsSecure=p,t.WebSocketStar=y,t.WebRTCStar=g,t.WebRTCDirect=v,t.Reliable=b,t.Stardust=_,t.Circuit=S,t.IPFS=x},function(e,t,n){"use strict";const r=n(227);e.exports={addLink:n(490),countStreamBytes:n(1197),createLock:n(1198),createNode:n(1214),formatCid:n(1215),limitStreamBytes:n(1216),loadNode:n(1217),removeLink:n(1218),toMfsPath:n(495),toPathComponents:n(295),toPullSource:n(1219),toSourcesAndDestination:n(1228),toSources:n(504),toTrail:n(1229),updateMfsRoot:n(1230),updateTree:n(1231),withMfsRoot:n(496),zeros:n(1234),FILE_SEPARATOR:r.FILE_SEPARATOR,MAX_CHUNK_SIZE:r.MAX_CHUNK_SIZE,MAX_LINKS:r.MAX_LINKS,FILE_TYPES:r.FILE_TYPES}},function(e,t,n){"use strict";function r(e){return e}var i=n(151);e.exports=function e(t){if(!t)return r;t=i(t);var n=!1,o,s;return function(e){return function r(i,a){if(s)return a(s);i?(s=i,e(i,n?function(e){n?o=a:a(i)}:function(e){a(i)})):e(null,function(e,i){e?a(e):s?a(s):(n=!0,t(i,function(e,t){n=!1,s?(a(s),o&&o(s)):e?r(e,a):a(null,t)}))})}}}},function(e,t,n){"use strict";(function(t){const r=n(70),i=n(27),o=n(60),s=n(9),a=/^https?:\/\/[^/]+\/(ip(f|n)s)\/((\w+).*)/,l=/^\/(ip(f|n)s)\/((\w+).*)/,u=1,c=4,h=/^https?:\/\/([^/]+)\.(ip(?:f|n)s)\.[^/]+/,f=1,p=2;function d(e){const n=b(e);try{const e=t.from(r.decode(n));return i.decode(e),!0}catch(e){return!1}}function m(e){try{return o.isEncoded(e)}catch(e){return!1}}function g(e){try{return s.isCID(new s(e))}catch(e){return!1}}function y(e,t,n=u,r=c){const i=b(e);if(!i)return!1;const o=i.match(t);if(!o)return!1;if("ipfs"!==o[n])return!1;let s=o[r];return s&&t===h&&(s=s.toLowerCase()),g(s)}function v(e,t,n=u,r){const i=b(e);if(!i)return!1;const o=i.match(t);if(!o)return!1;if("ipns"!==o[n])return!1;if(r&&t===h){let e=o[r];return e=e.toLowerCase(),g(e)}return!0}function b(e){return t.isBuffer(e)?r.encode(e):"string"==typeof e&&e}const _=e=>y(e,h,2,1),w=e=>v(e,h,2,1);e.exports={multihash:d,cid:g,base32cid:e=>"base32"===m(e)&&g(e),ipfsSubdomain:_,ipnsSubdomain:w,subdomain:e=>_(e)||w(e),subdomainPattern:h,ipfsUrl:e=>y(e,a),ipnsUrl:e=>v(e,a),url:e=>y(e,a)||v(e,a),urlPattern:a,ipfsPath:e=>y(e,l),ipnsPath:e=>v(e,l),path:e=>y(e,l)||v(e,l),pathPattern:l,urlOrPath:e=>y(e,a)||v(e,a)||y(e,l)||v(e,l)}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(25),i=n(14);function o(e,t){Error.captureStackTrace&&Error.captureStackTrace(this,o),this.name="FingerprintFormatError",this.fingerprint=e,this.format=t,this.message="Fingerprint format is not supported, or is invalid: ",void 0!==e&&(this.message+=" fingerprint = "+e),void 0!==t&&(this.message+=" format = "+t)}function s(e){Error.captureStackTrace&&Error.captureStackTrace(this,s),this.name="InvalidAlgorithmError",this.algorithm=e,this.message='Algorithm "'+e+'" is not supported'}function a(e,t,n){Error.captureStackTrace&&Error.captureStackTrace(this,a),this.name="KeyParseError",this.format=t,this.keyName=e,this.innerErr=n,this.message="Failed to parse "+e+" as a valid "+t+" format key: "+n.message}function l(e,t,n){Error.captureStackTrace&&Error.captureStackTrace(this,l),this.name="SignatureParseError",this.type=e,this.format=t,this.innerErr=n,this.message="Failed to parse the given data as a "+e+" signature in "+t+" format: "+n.message}function u(e,t,n){Error.captureStackTrace&&Error.captureStackTrace(this,u),this.name="CertificateParseError",this.format=t,this.certName=e,this.innerErr=n,this.message="Failed to parse "+e+" as a valid "+t+" format certificate: "+n.message}function c(e,t){Error.captureStackTrace&&Error.captureStackTrace(this,c),this.name="KeyEncryptedError",this.format=t,this.keyName=e,this.message="The "+t+" format key "+e+" is encrypted (password-protected), and no passphrase was provided in `options`"}i.inherits(o,Error),i.inherits(s,Error),i.inherits(a,Error),i.inherits(l,Error),i.inherits(u,Error),i.inherits(c,Error),e.exports={FingerprintFormatError:o,InvalidAlgorithmError:s,KeyParseError:a,SignatureParseError:l,KeyEncryptedError:c,CertificateParseError:u}},function(e,t){errors={};class n extends Error{constructor(e){super(e||"Coding Error"),this.name="CodingError"}}errors.CodingError=n;class r extends Error{constructor(e){super("To be implemented: "+e),this.name="ToBeImplementedError"}}errors.ToBeImplementedError=r;class i extends Error{constructor(e){super(e||"Transport failure"),this.name="TransportError"}}errors.TransportError=i;class o extends Error{constructor(e){super(e||"Timed out"),this.name="TimeoutError"}}errors.TimeoutError=o;class s extends Error{constructor(e){super(e||"Intentionally Unimplemented Function"),this.name="IntentionallyUnimplementedError"}}errors.IntentionallyUnimplementedError=s,t=e.exports=errors},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=7*o,a=365.25*o;function l(e){if(e=String(e),!(e.length>100)){var t=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(t){var l=parseFloat(t[1]),u=(t[2]||"ms").toLowerCase();switch(u){case"years":case"year":case"yrs":case"yr":case"y":return l*a;case"weeks":case"week":case"w":return l*s;case"days":case"day":case"d":return l*o;case"hours":case"hour":case"hrs":case"hr":case"h":return l*i;case"minutes":case"minute":case"mins":case"min":case"m":return l*r;case"seconds":case"second":case"secs":case"sec":case"s":return l*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return l;default:return}}}}function u(e){var t=Math.abs(e);return t>=o?Math.round(e/o)+"d":t>=i?Math.round(e/i)+"h":t>=r?Math.round(e/r)+"m":t>=n?Math.round(e/n)+"s":e+"ms"}function c(e){var t=Math.abs(e);return t>=o?h(e,t,o,"day"):t>=i?h(e,t,i,"hour"):t>=r?h(e,t,r,"minute"):t>=n?h(e,t,n,"second"):e+" ms"}function h(e,t,n,r){var i=t>=1.5*n;return Math.round(e/n)+" "+r+(i?"s":"")}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return l(e);if("number"===n&&isFinite(e))return t.long?c(e):u(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(327),i="object"==typeof self&&self&&self.Object===Object&&self,o=r||i||Function("return this")();e.exports=o},function(e,t,n){(function(t){var r=n(62);e.exports=o,e.exports.source=function(e){return o(null,e)},e.exports.sink=function(e){return o(e,null)};var i="undefined"==typeof setImmediate?t.nextTick:setImmediate;function o(e,t){e&&"object"==typeof e&&(t=e.source,e=e.sink);var n=[],o=[],s,a,l=new r,u;l.writable=l.readable=!0,l.write=function(e){return n.length?n.shift()(null,e):o.push(e),n.length||(a=!0),!!n.length},l.end=function(){t?o.length?g():t(s=!0,n.length?n.shift():function(){}):n.length&&n.shift()(!0)},l.source=function(e,t){o.length?(t(null,o.shift()),o.length||l.emit("drain")):((s=s||e)?t(s):n.push(t),a&&(a=!1,l.emit("drain")))},e&&(u=e(l.source)),u&&!t&&(t=u);var c=[],h=[],f=!1,p=!1,d=!1;if(l.sink=function(e){t=e,i(g)},t){l.sink(t);var m=l.pipe.bind(l);l.pipe=function(e,t){var n=m(e,t);return l.paused&&l.resume(),n}}function g(){if(p=!1,t&&!d){for(;c.length&&!l.paused;)l.emit("data",c.shift());if(!l.paused){if(f)return l.emit("end");d=!0,t(null,function e(n,r){d=!1,l.paused?(!0===n?f=n:n?l.emit("error",n):c.push(r),p=!0):n&&!0!==(s=n)?l.emit("error",n):(s=s||n)?l.emit("end"):(l.emit("data",r),d=!0,t(null,e))})}}}return l.pause=function(){return l.paused=!0,l},l.resume=function(){return l.paused=!1,g(),l},l.destroy=function(){!s&&t&&t(s=!0,function(){}),s=!0,n.length&&n.shift()(!0),l.emit("close")},l}}).call(this,n(3))},function(e,t,n){"use strict";(function(t){const r=n(12),i=n(40),o=n(71),s=n(67),a=n(66),l=n(9),u=n(1181).createResolver;function c(e){let n=e,r="/";if(t.isBuffer(e)&&(n=new l(e).toBaseEncodedString()),"string"==typeof e){0===e.indexOf("/ipfs/")&&(e=n=e.substring(6));const t=e.indexOf("/");t>0&&(n=e.substring(0,t),r=e.substring(t))}else l.isCID(n)&&(n=n.toBaseEncodedString());return n=new l(n).toBaseEncodedString(),{base:n,rest:p(r)}}const h={maxDepth:1/0,offset:void 0,length:void 0,fullPath:!1};function f(e){return e.reduce((e,t)=>(e.length&&(e+="/"),e+t),"")}e.exports=((e,t,n)=>{let p;n=Object.assign({},h,n);try{p=c(e)}catch(e){return o(e)}const d=f([p.base].concat(p.rest.slice(0,p.rest.length-1))).length,m=new l(p.base);return r(i([{cid:m,name:p.base,path:p.base,pathRest:p.rest,depth:0}]),u(t,n),s(Boolean),a(e=>({depth:e.depth,name:e.name,path:n.fullPath?e.path:g(e),size:e.size,cid:e.cid,content:e.content,type:e.type})));function g(e){if(!p.rest.length)return e.path;let t=e.path.substring(d);return"/"===t.charAt(0)&&(t=t.substring(1)),t||(t=p.rest[p.rest.length-1]||p.base),t}});const p=(e="")=>(e.trim().match(/([^\\^/]|\\\/)+/g)||[]).filter(Boolean)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(9);e.exports=function(e){if(t.isBuffer(e))return new r(e).toString();if(r.isCID(e))return e.toString();if("string"!=typeof e)throw new Error("unexpected cid type: "+typeof e);return new r(e.split("/")[0]),e}}).call(this,n(0).Buffer)},function(e,t,n){e.exports=p;var r=n(25),i=n(29).Buffer,o=n(48),s=n(16),a=n(76),l=n(42),u=n(84),c=n(175),h=a.InvalidAlgorithmError,f=a.SignatureParseError;function p(e){r.object(e,"options"),r.arrayOfObject(e.parts,"options.parts"),r.string(e.type,"options.type");for(var t={},n=0;n<e.parts.length;++n){var i=e.parts[n];t[i.name]=i}this.type=e.type,this.hashAlgorithm=e.hashAlgo,this.curve=e.curve,this.parts=e.parts,this.part=t}function d(e,t,n,i){if("ssh"===n){try{var o=new c({buffer:e}),s=o.readString()}catch(e){}if(void 0!==o){var a="SSH signature does not match expected type (expected "+t+", got "+s+")";switch(s){case"ssh-rsa":r.strictEqual(t,"rsa",a),i.hashAlgo="sha1";break;case"rsa-sha2-256":r.strictEqual(t,"rsa",a),i.hashAlgo="sha256";break;case"rsa-sha2-512":r.strictEqual(t,"rsa",a),i.hashAlgo="sha512";break;case"ssh-ed25519":r.strictEqual(t,"ed25519",a),i.hashAlgo="sha512";break;default:throw new Error("Unknown SSH signature type: "+s)}var l=o.readPart();return r.ok(o.atEnd(),"extra trailing bytes"),l.name="sig",i.parts.push(l),new p(i)}}return i.parts.push({name:"sig",data:e}),new p(i)}function m(e,t,n,r){var i=new u.BerReader(e);i.readSequence();var o=i.readString(u.Ber.Integer,!0),s=i.readString(u.Ber.Integer,!0);return r.parts.push({name:"r",data:l.mpNormalize(o)}),r.parts.push({name:"s",data:l.mpNormalize(s)}),new p(r)}function g(e,t,n,i){if(40!=e.length){var o=new c({buffer:e}),s=o.readBuffer();"ssh-dss"===s.toString("ascii")&&(s=o.readBuffer()),r.ok(o.atEnd(),"extra trailing bytes"),r.strictEqual(s.length,40,"invalid inner length"),e=s}return i.parts.push({name:"r",data:e.slice(0,20)}),i.parts.push({name:"s",data:e.slice(20,40)}),new p(i)}function y(e,t,n,i){var o=new c({buffer:e}),s,a,l=o.readBuffer(),u=l.toString("ascii");if("ecdsa-"===u.slice(0,6)){var h=u.split("-");switch(r.strictEqual(h[0],"ecdsa"),r.strictEqual(h[1],"sha2"),i.curve=h[2],i.curve){case"nistp256":i.hashAlgo="sha256";break;case"nistp384":i.hashAlgo="sha384";break;case"nistp521":i.hashAlgo="sha512";break;default:throw new Error("Unsupported ECDSA curve: "+i.curve)}l=o.readBuffer(),r.ok(o.atEnd(),"extra trailing bytes on outer"),o=new c({buffer:l}),s=o.readPart()}else s={data:l};return a=o.readPart(),r.ok(o.atEnd(),"extra trailing bytes"),s.name="r",a.name="s",i.parts.push(s),i.parts.push(a),new p(i)}p.prototype.toBuffer=function(e){var t;void 0===e&&(e="asn1"),r.string(e,"format");var n="ssh-"+this.type;switch(this.type){case"rsa":switch(this.hashAlgorithm){case"sha256":n="rsa-sha2-256";break;case"sha512":n="rsa-sha2-512";break;case"sha1":case void 0:break;default:throw new Error("SSH signature format does not support hash algorithm "+this.hashAlgorithm)}return"ssh"===e?(t=new c({}),t.writeString(n),t.writePart(this.part.sig),t.toBuffer()):this.part.sig.data;case"ed25519":return"ssh"===e?(t=new c({}),t.writeString(n),t.writePart(this.part.sig),t.toBuffer()):this.part.sig.data;case"dsa":case"ecdsa":var o,s;if("asn1"===e){var a=new u.BerWriter;return a.startSequence(),o=l.mpNormalize(this.part.r.data),s=l.mpNormalize(this.part.s.data),a.writeBuffer(o,u.Ber.Integer),a.writeBuffer(s,u.Ber.Integer),a.endSequence(),a.buffer}if("ssh"===e&&"dsa"===this.type){if(t=new c({}),t.writeString("ssh-dss"),o=this.part.r.data,o.length>20&&0===o[0]&&(o=o.slice(1)),s=this.part.s.data,s.length>20&&0===s[0]&&(s=s.slice(1)),this.hashAlgorithm&&"sha1"!==this.hashAlgorithm||o.length+s.length!==40)throw new Error("OpenSSH only supports DSA signatures with SHA1 hash");return t.writeBuffer(i.concat([o,s])),t.toBuffer()}if("ssh"===e&&"ecdsa"===this.type){var h=new c({}),f;o=this.part.r.data,h.writeBuffer(o),h.writePart(this.part.s),t=new c({}),0===o[0]&&(o=o.slice(1));var p=8*o.length;return 256===p?f="nistp256":384===p?f="nistp384":528===p&&(f="nistp521"),t.writeString("ecdsa-sha2-"+f),t.writeBuffer(h.toBuffer()),t.toBuffer()}throw new Error("Invalid signature format");default:throw new Error("Invalid signature data")}},p.prototype.toString=function(e){return r.optionalString(e,"format"),this.toBuffer(e).toString("base64")},p.parse=function(e,t,n){"string"==typeof e&&(e=i.from(e,"base64")),r.buffer(e,"data"),r.string(n,"format"),r.string(t,"type");var o={};o.type=t.toLowerCase(),o.parts=[];try{switch(r.ok(e.length>0,"signature must not be empty"),o.type){case"rsa":case"ed25519":return d(e,t,n,o);case"dsa":case"ecdsa":return"asn1"===n?m(e,t,n,o):"dsa"===o.type?g(e,t,n,o):y(e,t,n,o);default:throw new h(t)}}catch(e){if(e instanceof h)throw e;throw new f(t,n,e)}},p.isSignature=function(e,t){return l.isCompatible(e,p,t)},p.prototype._sshpkApiVersion=[2,1],p._oldVersionDetect=function(e){return r.func(e.toBuffer),e.hasOwnProperty("hashAlgorithm")?[2,0]:[1,0]}},function(e,t,n){var r=n(1652);e.exports={Ber:r,BerReader:r.Reader,BerWriter:r.Writer}},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){"use strict";function r(e,t){t|=0;for(var n=Math.max(e.length-t,0),r=Array(n),i=0;i<n;i++)r[i]=e[t+i];return r}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t){function n(e){return null!=e&&"object"==typeof e}e.exports=n},function(e,t,n){"use strict";e.exports=function e(){return function(e,t){t(!0)}}},function(e,t,n){"use strict";const r=n(351),i=Object.prototype.hasOwnProperty,o=Object.propertyIsEnumerable,s=(e,t,n)=>Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0}),a=this,l={concatArrays:!1},u=e=>{const t=[];for(const n in e)i.call(e,n)&&t.push(n);if(Object.getOwnPropertySymbols){const n=Object.getOwnPropertySymbols(e);for(let r=0;r<n.length;r++)o.call(e,n[r])&&t.push(n[r])}return t};function c(e){return Array.isArray(e)?h(e):r(e)?f(e):e}function h(e){const t=e.slice(0,0);return u(e).forEach(n=>{s(t,n,c(e[n]))}),t}function f(e){const t=null===Object.getPrototypeOf(e)?Object.create(null):{};return u(e).forEach(n=>{s(t,n,c(e[n]))}),t}const p=(e,t,n,r)=>(n.forEach(n=>{n in e&&e[n]!==Object.getPrototypeOf(e)?s(e,n,m(e[n],t[n],r)):s(e,n,c(t[n]))}),e),d=(e,t,n)=>{let r=e.slice(0,0),o=0;return[e,t].forEach(t=>{const a=[];for(let n=0;n<t.length;n++)i.call(t,n)&&(a.push(String(n)),s(r,o++,t===e?t[n]:c(t[n])));r=p(r,t,u(t).filter(e=>-1===a.indexOf(e)),n)}),r};function m(e,t,n){return n.concatArrays&&Array.isArray(e)&&Array.isArray(t)?d(e,t,n):r(t)&&r(e)?p(e,t,u(t),n):c(t)}e.exports=function(){const e=m(c(l),this!==a&&this||{},l);let t={foobar:{}};for(let n=0;n<arguments.length;n++){const i=arguments[n];if(void 0!==i){if(!r(i))throw new TypeError("`"+i+"` is not an Option Object");t=m(t,{foobar:i},e)}}return t.foobar}},function(e,t,n){"use strict";(function(t){const r=n(24),i=n(31),o=n(15),s=n(57),a=n(123).Record,l=s(n(1013)),u=l.Message.MessageType,c=l.Message.ConnectionType;class h{constructor(e,n,i){n&&r(t.isBuffer(n)),this.type=e,this.key=n,this._clusterLevelRaw=i,this.closerPeers=[],this.providerPeers=[],this.record=null}get clusterLevel(){const e=this._clusterLevelRaw-1;return e<0?0:e}set clusterLevel(e){this._clusterLevelRaw=e}serialize(){const e={key:this.key,type:this.type,clusterLevelRaw:this._clusterLevelRaw,closerPeers:this.closerPeers.map(f),providerPeers:this.providerPeers.map(f)};return this.record&&(t.isBuffer(this.record)?e.record=this.record:e.record=this.record.serialize()),l.Message.encode(e)}static deserialize(e){const t=l.Message.decode(e),n=new h(t.type,t.key,t.clusterLevelRaw);return n.closerPeers=t.closerPeers.map(p),n.providerPeers=t.providerPeers.map(p),t.record&&(n.record=a.deserialize(t.record)),n}}function f(e){const t={id:e.id.id,addrs:e.multiaddrs.toArray().map(e=>e.buffer)};return e.isConnected()?t.connection=c.CONNECTED:t.connection=c.NOT_CONNECTED,t}function p(e){const t=new i(new o(e.id));return e.addrs.forEach(e=>t.multiaddrs.add(e)),t}h.TYPES=u,h.CONNECTION_TYPES=c,e.exports=h}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(53),i=n(166);function o(e,t){r(e,i(e=>t(null,e)),e=>{e&&t(e)})}e.exports=o},function(e,t,n){e.exports={read:k,write:E};var r=n(25),i=n(84),o=n(16),s=n(29).Buffer,a=n(48),l=n(42),u=n(41),c=n(46),h=n(318),f=n(176),p=n(238),d=n(93),m=n(76),g="1.2.840.113549.1.5.13",y="1.2.840.113549.1.5.12",v={"1.2.840.113549.3.7":"3des-cbc","2.16.840.1.101.3.4.1.2":"aes128-cbc","2.16.840.1.101.3.4.1.42":"aes256-cbc"},b={};Object.keys(v).forEach(function(e){b[v[e]]=e});var _={"1.2.840.113549.2.7":"sha1","1.2.840.113549.2.9":"sha256","1.2.840.113549.2.11":"sha512"},w={};function k(e,t,n){var a=e;"string"!=typeof e&&(r.buffer(e,"buf"),e=e.toString("ascii"));for(var u=e.trim().split(/[\r\n]+/g),c,b=-1,w;!c&&b<u.length;)c=u[++b].match(/[-]+[ ]*BEGIN ([A-Z0-9][A-Za-z0-9]+ )?(PUBLIC|PRIVATE) KEY[ ]*[-]+/);r.ok(c,"invalid PEM header");for(var k=u.length;!w&&k>0;)w=u[--k].match(/[-]+[ ]*END ([A-Z0-9][A-Za-z0-9]+ )?(PUBLIC|PRIVATE) KEY[ ]*[-]+/);r.ok(w,"invalid PEM footer"),r.equal(c[2],w[2]);var E=c[2].toLowerCase(),S;c[1]&&(r.equal(c[1],w[1],"PEM header and footer mismatch"),S=c[1].trim()),u=u.slice(b,k+1);for(var x={},C,A,T;u=u.slice(1),c=u[0].match(/^([A-Za-z0-9-]+): (.+)$/),c;)x[c[1].toLowerCase()]=c[2];if(u=u.slice(0,-1).join(""),e=s.from(u,"base64"),x["proc-type"]){var I=x["proc-type"].split(",");if("4"===I[0]&&"ENCRYPTED"===I[1]){if("string"==typeof t.passphrase&&(t.passphrase=s.from(t.passphrase,"utf-8")),!s.isBuffer(t.passphrase))throw new m.KeyEncryptedError(t.filename,"PEM");I=x["dek-info"].split(","),r.ok(2===I.length),C=I[0].toLowerCase(),T=s.from(I[1],"hex"),A=l.opensslKeyDeriv(C,T,t.passphrase,1).key}}if(S&&"encrypted"===S.toLowerCase()){var j=new i.BerReader(e),R;j.readSequence(),j.readSequence(),R=j.offset+j.length;var B=j.readOID();if(B!==g)throw new Error("Unsupported PEM/PKCS8 encryption scheme: "+B);j.readSequence(),j.readSequence();var O=j.offset+j.length,P=j.readOID();if(P!==y)throw new Error("Unsupported PBES2 KDF: "+P);j.readSequence();var N=j.readString(i.Ber.OctetString,!0),D=j.readInt(),M="sha1";if(j.offset<O){j.readSequence();var F=j.readOID();if(M=_[F],void 0===M)throw new Error("Unsupported PBKDF2 hash: "+F)}j._offset=O,j.readSequence();var L=j.readOID();if(C=v[L],void 0===C)throw new Error("Unsupported PBES2 cipher: "+L);if(T=j.readString(i.Ber.OctetString,!0),j._offset=R,e=j.readString(i.Ber.OctetString,!0),"string"==typeof t.passphrase&&(t.passphrase=s.from(t.passphrase,"utf-8")),!s.isBuffer(t.passphrase))throw new m.KeyEncryptedError(t.filename,"PEM");var U=l.opensshCipherInfo(C);C=U.opensslName,A=l.pbkdf2(M,N,D,U.keySize,t.passphrase),S=void 0}if(C&&A&&T){var q=o.createDecipheriv(C,A,T),z,K=[];for(q.once("error",function(e){if(-1!==e.toString().indexOf("bad decrypt"))throw new Error("Incorrect passphrase supplied, could not decrypt key");throw e}),q.write(e),q.end();null!==(z=q.read());)K.push(z);e=s.concat(K)}if(S&&"openssh"===S.toLowerCase())return p.readSSHPrivate(E,e,t);if(S&&"ssh2"===S.toLowerCase())return d.readType(E,e,t);var H=new i.BerReader(e);return H.originalInput=a,H.readSequence(),S?(n&&r.strictEqual(n,"pkcs1"),h.readPkcs1(S,E,H)):(n&&r.strictEqual(n,"pkcs8"),f.readPkcs8(S,E,H))}function E(e,t,n){r.object(e);var o={ecdsa:"EC",rsa:"RSA",dsa:"DSA",ed25519:"EdDSA"}[e.type],a,l=new i.BerWriter;if(c.isPrivateKey(e))n&&"pkcs8"===n?(a="PRIVATE KEY",f.writePkcs8(l,e)):(n&&r.strictEqual(n,"pkcs1"),a=o+" PRIVATE KEY",h.writePkcs1(l,e));else{if(!u.isKey(e))throw new Error("key is not a Key or PrivateKey");n&&"pkcs1"===n?(a=o+" PUBLIC KEY",h.writePkcs1(l,e)):(n&&r.strictEqual(n,"pkcs8"),a="PUBLIC KEY",f.writePkcs8(l,e))}var p=l.buffer.toString("base64"),d=p.length+p.length/64+18+16+2*a.length+10,m=s.alloc(d),g=0;g+=m.write("-----BEGIN "+a+"-----\n",g);for(var y=0;y<p.length;){var v=y+64;v>p.length&&(v=p.length),g+=m.write(p.slice(y,v),g),m[g++]=10,y=v}return g+=m.write("-----END "+a+"-----\n",g),m.slice(0,g)}Object.keys(_).forEach(function(e){w[_[e]]=e})},function(e,t,n){e.exports={read:f.bind(void 0,!1,void 0),readType:f.bind(void 0,!1),write:p,readPartial:f.bind(void 0,!0),readInternal:f,keyTypeToAlg:h,algToKeyType:c};var r=n(25),i=n(29).Buffer,o=n(48),s=n(42),a=n(41),l=n(46),u=n(175);function c(e){if(r.string(e),"ssh-dss"===e)return"dsa";if("ssh-rsa"===e)return"rsa";if("ssh-ed25519"===e)return"ed25519";if("ssh-curve25519"===e)return"curve25519";if(e.match(/^ecdsa-sha2-/))return"ecdsa";throw new Error("Unknown algorithm "+e)}function h(e){if(r.object(e),"dsa"===e.type)return"ssh-dss";if("rsa"===e.type)return"ssh-rsa";if("ed25519"===e.type)return"ssh-ed25519";if("curve25519"===e.type)return"ssh-curve25519";if("ecdsa"===e.type)return"ecdsa-sha2-"+e.part.curve.data.toString();throw new Error("Unknown key type "+e.type)}function f(e,t,n,h){"string"==typeof n&&(n=i.from(n)),r.buffer(n,"buf");var f={},p=f.parts=[],d=new u({buffer:n}),m=d.readString();r.ok(!d.atEnd(),"key must have at least one part"),f.type=c(m);var g=o.info[f.type].parts.length;for(t&&"private"===t&&(g=o.privInfo[f.type].parts.length);!d.atEnd()&&p.length<g;)p.push(d.readPart());for(;!e&&!d.atEnd();)p.push(d.readPart());r.ok(p.length>=1,"key must have at least one part"),r.ok(e||d.atEnd(),"leftover bytes at end of key");var y=a,v=o.info[f.type];if("private"!==t&&v.parts.length===p.length||(v=o.privInfo[f.type],y=l),r.strictEqual(v.parts.length,p.length),"ecdsa"===f.type){var b=/^ecdsa-sha2-(.+)$/.exec(m);r.ok(null!==b),r.strictEqual(b[1],p[0].data.toString())}for(var _=!0,w=0;w<v.parts.length;++w){var k=p[w],E;if(k.name=v.parts[w],"ed25519"===f.type&&"k"===k.name&&(k.data=k.data.slice(0,32)),"curve"!==k.name&&!1!==v.normalize)E="ed25519"===f.type?s.zeroPadToLength(k.data,32):s.mpNormalize(k.data),E.toString("binary")!==k.data.toString("binary")&&(k.data=E,_=!1)}return _&&(f._rfc4253Cache=d.toBuffer()),e&&"object"==typeof e&&(e.remainder=d.remainder(),e.consumed=d._offset),new y(f)}function p(e,t){r.object(e);var n=h(e),a,c=o.info[e.type];l.isPrivateKey(e)&&(c=o.privInfo[e.type]);var f=c.parts,p=new u({});for(p.writeString(n),a=0;a<f.length;++a){var d=e.part[f[a]].data;!1!==c.normalize&&(d="ed25519"===e.type?s.zeroPadToLength(d,32):s.mpNormalize(d)),"ed25519"===e.type&&"k"===f[a]&&(d=i.concat([d,e.part.A.data])),p.writeBuffer(d)}return p.toBuffer()}},function(e,t,n){const r=n(32),i=n(77),o=n(146),s=n(4)("dweb-transports"),a=n(240),l=n(38),u=n(59);class c{constructor(e){}static _connected(){return this._transports.filter(e=>!e.status)}static p_connectedNames(e){const t=this._connected().map(e=>e.name);if(!e)return new Promise((e,n)=>e(t));e(null,t)}static async p_connectedNamesParm(){return(await this.p_connectedNames()).map(e=>"transport="+e).join("&")}static p_statuses(e){const t=c._transports.map(e=>({name:e.name,status:e.status}));if(!e)return new Promise((e,n)=>e(t));e(null,t)}static validFor(e,t,n){return"string"==typeof e&&(e=[e]),e&&e[0]||["store","newlisturls","newdatabase","newtable","seed"].includes(t)?e&&e.length>0?[].concat(...e.map(e=>"string"==typeof e?r.parse(e):e).map(e=>this._transports.filter(r=>r.validFor(e,t,n)).map(t=>[e,t]))):this._transports.filter(e=>e.validFor(void 0,t,n)).map(e=>[void 0,e]):(console.error("Transports.validFor called with invalid arguments: urls=",e,"func=",t),[])}static async p_urlsValidFor(e,t,n){return this.validFor(e,t,n).map(e=>e[0])}static http(){return c._connected().find(e=>"HTTP"===e.name)}static wolk(){return c._connected().find(e=>"WOLK"===e.name)}static ipfs(){return c._connected().find(e=>"IPFS"===e.name)}static webtorrent(){return c._connected().find(e=>"WEBTORRENT"===e.name)}static gun(){return c._connected().find(e=>"GUN"===e.name)}static async p_resolveNames(e){return this.mirror?Array.isArray(e)?this.gatewayUrls(e):this.gatewayUrl(url):this.namingcb?await this.namingcb(e):e}static resolveNamesWith(e){this.namingcb=e}static togglePaused(e,t){const n=this._transports.find(t=>t.name===e);n?n.togglePaused(e=>t(null,e.status)):t(void 0)}static async _p_rawstore(e,t){let n=[],r=await Promise.all(e.map(async function(e){try{s("Storing %d bytes to %s",t.length,e.name);let r=await e.p_rawstore(t);return s("Storing %d bytes to %s succeeded: %s",t.length,e.name,r),r}catch(r){return s("Storing %d bytes to %s failed: %s",t.length,e.name,r.message),void n.push(r)}}));if(r=r.filter(e=>!!e),!r.length)throw s("Storing %d bytes failed on all transports",t.length),new i.TransportError(n.map(e=>e.message).join(", "));return r}static async p_rawstore(e){let t=this.validFor(void 0,"store").map(([e,t])=>t);if(!t.length)throw s("Storing %d bytes failed: no transports available",e.length),new i.TransportError("Transports.p_rawstore: Cant find transport for store");return this._p_rawstore(t,e)}static async p_rawfetch(e,t={}){if(!e.length)throw new i.TransportError("Transports.p_rawfetch given an empty list of urls");let n=await this.p_resolveNames(e);if(!n.length)throw new i.TransportError("Transports.p_rawfetch none of the urls resolved: "+e);let r=this.validFor(n,"fetch",{noCache:t.noCache});if(!r.length)throw new i.TransportError("Transports.p_rawfetch cant find any transport for urls: "+n);let o=[],a=[];for(const[e,n]of r)try{s("Fetching %s via %s",e.href,n.name);let r=await n.p_rawfetch(e,t);return s("Fetching %s via %s succeeded %d bytes",e.href,n.name,r.length),t.relay&&a.length&&(s("Fetching attempting relay of %d bytes from %s to %o",r.length,e.href,a.map(e=>e.name)),this._p_rawstore(a,r).then(e=>s("Fetching relayed %d bytes to %o",r.length,e))),r}catch(t){a.push(n),o.push(t),s("Fetching %s via %s failed: %s",e.href,n.name,t.message)}throw s("Fetching %o failed on all transports",e),new i.TransportError(o.map(e=>e.message).join(", "))}static fetch(e,t={},n){"function"==typeof t&&(n=t,t={});const r=this.p_rawfetch(e,t);if(!n)return r;r.then(e=>{try{n(null,e)}catch(e){s("Uncaught error in fetch %O",e)}}).catch(e=>n(e))}static seed({directoryPath:e,fileRelativePath:t,ipfsHash:n,urlToFile:r,torrentRelativePath:i},o){if(!o)return new Promise((e,t)=>{try{a.call(this,(n,r)=>{n?t(n):e(r)})}catch(e){t(e)}});try{a.call(this,o)}catch(e){o(e)}function a(o){let a=this.validFor(void 0,"seed").map(([e,t])=>t);if(a.length){const s={};l(a,(o,a)=>o.seed({directoryPath:e,torrentRelativePath:i,fileRelativePath:t,ipfsHash:n,urlToFile:r},(e,t)=>{s[o.name]=e?{err:e.message}:t,a(null)}),e=>o(null,s))}else s("Seeding: no transports available"),o(null)}}static async p_rawlist(e){e=await this.p_resolveNames(e);let t=this.validFor(e,"list");if(!t.length)throw new i.TransportError('Transports.p_rawlist: Cant find transport to "list" urls:'+e.join(","));let n=[],r=await Promise.all(t.map(async function([e,t]){try{s("Listing %s via %s",e,t.name);let r=await t.p_rawlist(e);return s("Listing %s via %s retrieved %d items",e,t.name,r.length),r}catch(r){return s("Listing %s via %s failed: %s",e,t.name,r.message),n.push(r),[]}}));if(n.length>=t.length)throw s("Listing %o failed on all transports",e),new i.TransportError(n.map(e=>e.message).join(", "));let o={};return[].concat(...r).filter(e=>!o[e.signature]&&(o[e.signature]=!0))}static async p_rawadd(e,t){e=await this.p_resolveNames(e);let n=this.validFor(e,"add");if(!n.length)throw s("Adding to %o failed: no transports available",e),new i.TransportError("Transports.p_rawstore: Cant find transport for urls:"+e.join(","));let r=[];if(await Promise.all(n.map(async function([e,n]){try{return s("Adding to %s via %s",e,n.name),await n.p_rawadd(e,t),void s("Adding to %s via %s succeeded",e,n.name)}catch(t){return s("Adding to %s via %s failed: %s",e,n.name,t.message),void r.push(t)}})),r.length>=n.length)throw s("Adding to %o failed on all transports",e),new i.TransportError(r.map(e=>e.message).join(", "))}static listmonitor(e,t,n={}){this.validFor(e,"listmonitor").map(([e,r])=>{r.listmonitor(e,t,n),s("Monitoring list %s via %s",e,r.name)})}static async p_newlisturls(e){let t=await Promise.all(this.validFor(void 0,"newlisturls").map(([t,n])=>n.p_newlisturls(e)));return[t.map(e=>e[0]),t.map(e=>e[1])]}static async p_f_createReadStream(e,{wanturl:t=!1,preferredTransports:n=[]}={}){let r=this.validFor(e,"createReadStream",{});if(!r.length)throw s("Opening stream from %o failed: no transports available",e),new i.TransportError("Transports.p_createReadStream cant find any transport for urls: "+e);let o=[];r.sort((e,t)=>(n.indexOf(e[1].name)+1||999+Math.random())-(n.indexOf(t[1].name)+1||999+Math.random()));for(const[e,n]of r)try{s("Opening stream from %s via %s",e.href,n.name);let r=await n.p_f_createReadStream(e,{wanturl:t});return s("Opening stream from %s via %s succeeded",e.href,n.name),r}catch(t){o.push(t),s("Opening stream from %s via %s failed: %s",e.href,n.name,t.message)}throw s("Opening stream from %o failed on all transports",e),new i.TransportError(o.map(e=>e.message).join(", "))}static createReadStream(e,t,n){"function"==typeof t&&(n=t,t={start:0}),DwebTransports.p_f_createReadStream(e,{preferredTransports:t.preferredTransports||[]}).then(e=>{let r=e(t);if(!n)return r;n(null,r)}).catch(e=>{e instanceof i.TransportError?console.warn("Transports.createReadStream caught",e.message):console.error("Transports.createReadStream caught",e),n?n(e):reject(e)})}static async p_get(e,t){let n=this.validFor(e,"get"),r=Array.isArray(t)?`${t.length} keys`:t;if(!n.length)throw s("Getting %s from %o failed: no transports available",r,e),new i.TransportError("Transports.p_get cant find any transport to get keys from urls: "+e);let o=[];for(const[e,i]of n)try{s("Getting %s from %s via %s",r,e.href,i.name);let n=await i.p_get(e,t);return s("Getting %s from %s via %s succeeded length=%d",r,e.href,i.name,n.length),n}catch(t){o.push(t),s("Getting %s from %s via %s failed: %s",r,e.href,i.name,t.message)}throw s("Getting %s from %o failed on all transports",r,e),new i.TransportError(o.map(e=>e.message).join(", "))}static async p_set(e,t,n){e=await this.p_resolveNames(e);let r="object"==typeof t?`${t.length} keys`:t,o=this.validFor(e,"set");if(!o.length)throw s("Setting %s on %o failed: no transports available",r,e),new i.TransportError("Transports.p_set cant find any transport for urls: "+e);let a=[],l=!1;if(await Promise.all(o.map(async function([e,i]){try{s("Setting %s on %s via %s",r,e.href,i.name),await i.p_set(e,t,n),s("Setting %s on %s via %s succeeded",r,e.href,i.name),l=!0}catch(t){s("Setting %s on %s via %s failed: %s",r,e.href,i.name,t.message),a.push(t)}})),!l)throw s("Setting %s on %o failed on all transports",r,e),new i.TransportError(a.map(e=>e.message).join(", "))}static async p_delete(e,t){e=await this.p_resolveNames(e);let n=Array.isArray(t)?`${t.length} keys`:t,r=this.validFor(e,"set");if(!r.length)throw s("Deleting %s on %o failed: no transports available",n,e),new i.TransportError("Transports.p_set cant find any transport for urls: "+e);let o=[],a=!1;if(await Promise.all(r.map(async function([e,r]){try{s("Deleting %s on %s via %s",n,e.href,r.name),await r.p_delete(e,t),s("Deleting %s on %s via %s succeeded",n,e.href,r.name),a=!0}catch(t){s("Deleting %s on %s via %s failed: %s",n,e.href,r.name,t.message),o.push(t)}})),!a)throw s("Deleting %s on %o failed on all transports",n,e),new i.TransportError(o.map(e=>e.message).join(", "))}static async p_keys(e){e=await this.p_resolveNames(e);let t=this.validFor(e,"keys");if(!t.length)throw s("Getting all keys on %o failed: no transports available",e),new i.TransportError("Transports.p_keys cant find any transport for urls: "+e);let n=[];for(const[e,r]of t)try{s("Getting all keys on %s via %s",e.href,r.name);let t=await r.p_keys(e);return s("Getting all keys on %s via %s succeeded with %d keys",e.href,r.name,t.length),t}catch(t){n.push(t),s("Getting all keys on %s via %s failed: %s",e.href,r.name,t.message)}throw s("Getting all keys on %o failed on all transports",e),new i.TransportError(n.map(e=>e.message).join(", "))}static async p_getall(e){e=await this.p_resolveNames(e);let t=this.validFor(e,"getall");if(!t.length)throw s("Getting all values on %o failed: no transports available",e),new i.TransportError("Transports.p_getall cant find any transport for urls: "+e);let n=[];for(const[e,r]of t)try{s("Getting all values on %s via %s",e.href,r.name);let t=await r.p_getall(e);return s("Getting all values on %s via %s succeeded with %d values",e.href,r.name,t.length),t}catch(t){n.push(t),s("Getting all values on %s via %s failed: %s",e.href,r.name,t.message)}throw s("Getting all keys on %o failed on all transports",e),new i.TransportError(n.map(e=>e.message).join(", "))}static async p_newdatabase(e){let t=await Promise.all(this.validFor(void 0,"newdatabase").map(([t,n])=>n.p_newdatabase(e)));return{privateurls:t.map(e=>e.privateurl),publicurls:t.map(e=>e.publicurl)}}static async p_newtable(e,t){let n=await Promise.all(this.validFor(void 0,"newtable").map(([n,r])=>r.p_newtable(e,t)));return{privateurls:n.map(e=>e.privateurl),publicurls:n.map(e=>e.publicurl)}}static async p_connection(e){e=await this.p_resolveNames(e),await Promise.all(this.validFor(e,"connection").map(([e,t])=>t.p_connection(e)))}static monitor(e,t,{current:n=!1}={}){this.validFor(e,"monitor").map(([e,r])=>{s("Monitoring table %s via %s",e,r.name),r.monitor(e,t,{current:n})})}static addtransport(e){c._transports.push(e)}static setup0(e,t,n){let r={http:{urlbase:"http://localhost:4244"}};return e.map(e=>{let n=this._transportclasses["LOCAL"===e?"HTTP":e];return n?(s("Setting up connection to %s with options %o",e,t),n.setup0("LOCAL"===e?r:t)):void s("Connection to %s unavailable",e)}).filter(e=>!!e)}static p_setup1(e,t){const n=Promise.all(this._transports.filter(e=>!this._optionspaused.includes(e.name)).map(t=>(s("Connection stage 1 to %s",t.name),t.p_setup1(e))));if(!t)return n;n.catch(e=>t(e)).then(e=>t(null,e))}static p_setup2(e,t){const n=Promise.all(this._transports.filter(e=>!this._optionspaused.includes(e.name)).map(t=>(s("Connection stage 2 to %s",t.name),t.p_setup2(e))));if(!t)return n;n.catch(e=>t(e)).then(e=>t(null,e))}static p_stop(e,t){if(!t)return new Promise((e,t)=>{try{n.call(this,(n,r)=>{n?t(n):e(r)})}catch(e){t(e)}});try{n.call(this,t)}catch(e){t(e)}function n(t){u(this._connected(),(t,n)=>{s("Stopping %s",t.name),t.stop(e,n)},t)}}static async refreshstatus(e){let t=["transportstatus0","transportstatus1","transportstatus2","transportstatus3","transportstatus4"],n=e.statuselement;n&&(n.classList.remove(...t),n.classList.add(t[e.status])),c.statuscb&&c.statuscb(e)}static connect(e,t){const n=this.p_connect(e);if(!t)return n;n.catch(e=>t(e)).then(e=>t(null,e))}static async p_connect(e){try{e=e||{};let t=e.transports;this._optionspaused=(e.paused||[]).map(e=>e.toUpperCase()),t&&t.length||(t=e.defaulttransports||[]),t.length||(t=["HTTP","IPFS","WEBTORRENT","WOLK"]),t=t.map(e=>e.toUpperCase());let n=this.setup0(t,e);if(["statuscb","mirror"].forEach(t=>{e[t]&&(this[t]=e[t])}),e.statuselement){let t=e.statuselement;for(;t.lastChild;)t.removeChild(t.lastChild);t.appendChild(o.createElement("UL",{},n.map(e=>{let t=o.createElement("LI",{onclick:"this.source.togglePaused(DwebTransports.refreshstatus);",source:e,name:e.name},e.name);return e.statuselement=t,t})))}await this.p_setup1(this.refreshstatus),await this.p_setup2(this.refreshstatus),s("Connection completed to %o",this._connected().map(e=>e.name))}catch(e){throw console.error("ERROR in p_connect:",e.message),e}}static async p_urlsFrom(e){if("string"==typeof e&&(e="["===e[0]?JSON.parse(e):e.includes(",")?e.split(","):[e]),!Array.isArray(e))throw new Error(`Unparsable url: ${e}`);return e}static async p_httpfetchurl(e){return c.http()._url(e.find(e=>e.startsWith("contenthash")||e.startsWith("http")),"content/rawfetch")}static canonicalName(e,t={}){"string"!=typeof e&&(e=r.parse(e).href);const n=["dweb.me","ipfs.io"],i=["ipfs","gun","magnet","yjs","wolk","arc","contenthash","http","https"],o=["arc","http","https"],s=[/^http[s]?:[/]+([^/]+)[/](\w+)[/](.*)/i],a=[/^dweb:[/]+(\w+)[/]+(.*)/i,/^\w+:[/]+(\w+)[/](.*)/i,/^(\w+):[/]*(.*)/i,/^[/]*(\w+)[/](.*)/i,/^[/]*dweb[/]*(\w+)[/](.*)/i],l=[/^http[s]?:[/]+[^/]+[/](archive).(org)[/]*(.*)/i,/^http[s]?:[/]+[^/]+[/]arc[/](archive).(org)[/]*(.*)/i,/^http[s]?:[/]+dweb.(\w+)[.]([^/]+)[/]*(.*)/i,/^(http[s])?:[/]+([^/]+)[/]+(.*)/i];for(let t of s){let r=e.match(t);if(r&&n.includes(r[1])&&i.includes(r[2]))return{proto:r[2],internal:r[3]}}for(let t of l){let n=e.match(t);if(n)return i.includes(n[1])?{proto:n[1],internal:o.includes(n[1])?[n[2],n[3]].join("/"):n[3]}:{proto:"arc",internal:[[n[1],n[2]].join("."),n[3]].join("/")}}for(let t of a){let n=e.match(t);if(n&&i.includes(n[1]))return{proto:n[1],internal:n[2]}}}static canonicalUrl(e,t={}){let n=this.canonicalName(e,t);return n.protocol+":/"+n.internal}static _o2url(e){return["http","https"].includes(e.proto)?[e.proto,e.internal].join("://"):e.proto?[this.mirror,e.proto,e.internal].join("/"):e.internal}static gatewayUrl(e){let t=c.canonicalName(e);return t?this._o2url(t):e}static gatewayUrls(e){const t=e.map(e=>c.canonicalName(e)||{proto:void 0,internal:e}),n=t.filter(e=>["arc"].includes(e.proto));return(n.length?n:t).map(e=>this._o2url(e))}}c._transports=[],c.namingcb=void 0,c._transportclasses={},c.httptools=a,t=e.exports=c},function(e,t,n){"use strict";(function(e){t.protobuf=e.from("50","hex"),t.cbor=e.from("51","hex"),t.rlp=e.from("60","hex"),t.bencode=e.from("63","hex"),t.multicodec=e.from("30","hex"),t.multihash=e.from("31","hex"),t.multiaddr=e.from("32","hex"),t.multibase=e.from("33","hex"),t.identity=e.from("00","hex"),t.sha1=e.from("11","hex"),t["sha2-256"]=e.from("12","hex"),t["sha2-512"]=e.from("13","hex"),t["sha3-512"]=e.from("14","hex"),t["sha3-384"]=e.from("15","hex"),t["sha3-256"]=e.from("16","hex"),t["sha3-224"]=e.from("17","hex"),t["shake-128"]=e.from("18","hex"),t["shake-256"]=e.from("19","hex"),t["keccak-224"]=e.from("1a","hex"),t["keccak-256"]=e.from("1b","hex"),t["keccak-384"]=e.from("1c","hex"),t["keccak-512"]=e.from("1d","hex"),t["murmur3-128"]=e.from("22","hex"),t["murmur3-32"]=e.from("23","hex"),t["dbl-sha2-256"]=e.from("56","hex"),t.md4=e.from("d4","hex"),t.md5=e.from("d5","hex"),t.bmt=e.from("d6","hex"),t.x11=e.from("1100","hex"),t["blake2b-8"]=e.from("b201","hex"),t["blake2b-16"]=e.from("b202","hex"),t["blake2b-24"]=e.from("b203","hex"),t["blake2b-32"]=e.from("b204","hex"),t["blake2b-40"]=e.from("b205","hex"),t["blake2b-48"]=e.from("b206","hex"),t["blake2b-56"]=e.from("b207","hex"),t["blake2b-64"]=e.from("b208","hex"),t["blake2b-72"]=e.from("b209","hex"),t["blake2b-80"]=e.from("b20a","hex"),t["blake2b-88"]=e.from("b20b","hex"),t["blake2b-96"]=e.from("b20c","hex"),t["blake2b-104"]=e.from("b20d","hex"),t["blake2b-112"]=e.from("b20e","hex"),t["blake2b-120"]=e.from("b20f","hex"),t["blake2b-128"]=e.from("b210","hex"),t["blake2b-136"]=e.from("b211","hex"),t["blake2b-144"]=e.from("b212","hex"),t["blake2b-152"]=e.from("b213","hex"),t["blake2b-160"]=e.from("b214","hex"),t["blake2b-168"]=e.from("b215","hex"),t["blake2b-176"]=e.from("b216","hex"),t["blake2b-184"]=e.from("b217","hex"),t["blake2b-192"]=e.from("b218","hex"),t["blake2b-200"]=e.from("b219","hex"),t["blake2b-208"]=e.from("b21a","hex"),t["blake2b-216"]=e.from("b21b","hex"),t["blake2b-224"]=e.from("b21c","hex"),t["blake2b-232"]=e.from("b21d","hex"),t["blake2b-240"]=e.from("b21e","hex"),t["blake2b-248"]=e.from("b21f","hex"),t["blake2b-256"]=e.from("b220","hex"),t["blake2b-264"]=e.from("b221","hex"),t["blake2b-272"]=e.from("b222","hex"),t["blake2b-280"]=e.from("b223","hex"),t["blake2b-288"]=e.from("b224","hex"),t["blake2b-296"]=e.from("b225","hex"),t["blake2b-304"]=e.from("b226","hex"),t["blake2b-312"]=e.from("b227","hex"),t["blake2b-320"]=e.from("b228","hex"),t["blake2b-328"]=e.from("b229","hex"),t["blake2b-336"]=e.from("b22a","hex"),t["blake2b-344"]=e.from("b22b","hex"),t["blake2b-352"]=e.from("b22c","hex"),t["blake2b-360"]=e.from("b22d","hex"),t["blake2b-368"]=e.from("b22e","hex"),t["blake2b-376"]=e.from("b22f","hex"),t["blake2b-384"]=e.from("b230","hex"),t["blake2b-392"]=e.from("b231","hex"),t["blake2b-400"]=e.from("b232","hex"),t["blake2b-408"]=e.from("b233","hex"),t["blake2b-416"]=e.from("b234","hex"),t["blake2b-424"]=e.from("b235","hex"),t["blake2b-432"]=e.from("b236","hex"),t["blake2b-440"]=e.from("b237","hex"),t["blake2b-448"]=e.from("b238","hex"),t["blake2b-456"]=e.from("b239","hex"),t["blake2b-464"]=e.from("b23a","hex"),t["blake2b-472"]=e.from("b23b","hex"),t["blake2b-480"]=e.from("b23c","hex"),t["blake2b-488"]=e.from("b23d","hex"),t["blake2b-496"]=e.from("b23e","hex"),t["blake2b-504"]=e.from("b23f","hex"),t["blake2b-512"]=e.from("b240","hex"),t["blake2s-8"]=e.from("b241","hex"),t["blake2s-16"]=e.from("b242","hex"),t["blake2s-24"]=e.from("b243","hex"),t["blake2s-32"]=e.from("b244","hex"),t["blake2s-40"]=e.from("b245","hex"),t["blake2s-48"]=e.from("b246","hex"),t["blake2s-56"]=e.from("b247","hex"),t["blake2s-64"]=e.from("b248","hex"),t["blake2s-72"]=e.from("b249","hex"),t["blake2s-80"]=e.from("b24a","hex"),t["blake2s-88"]=e.from("b24b","hex"),t["blake2s-96"]=e.from("b24c","hex"),t["blake2s-104"]=e.from("b24d","hex"),t["blake2s-112"]=e.from("b24e","hex"),t["blake2s-120"]=e.from("b24f","hex"),t["blake2s-128"]=e.from("b250","hex"),t["blake2s-136"]=e.from("b251","hex"),t["blake2s-144"]=e.from("b252","hex"),t["blake2s-152"]=e.from("b253","hex"),t["blake2s-160"]=e.from("b254","hex"),t["blake2s-168"]=e.from("b255","hex"),t["blake2s-176"]=e.from("b256","hex"),t["blake2s-184"]=e.from("b257","hex"),t["blake2s-192"]=e.from("b258","hex"),t["blake2s-200"]=e.from("b259","hex"),t["blake2s-208"]=e.from("b25a","hex"),t["blake2s-216"]=e.from("b25b","hex"),t["blake2s-224"]=e.from("b25c","hex"),t["blake2s-232"]=e.from("b25d","hex"),t["blake2s-240"]=e.from("b25e","hex"),t["blake2s-248"]=e.from("b25f","hex"),t["blake2s-256"]=e.from("b260","hex"),t["skein256-8"]=e.from("b301","hex"),t["skein256-16"]=e.from("b302","hex"),t["skein256-24"]=e.from("b303","hex"),t["skein256-32"]=e.from("b304","hex"),t["skein256-40"]=e.from("b305","hex"),t["skein256-48"]=e.from("b306","hex"),t["skein256-56"]=e.from("b307","hex"),t["skein256-64"]=e.from("b308","hex"),t["skein256-72"]=e.from("b309","hex"),t["skein256-80"]=e.from("b30a","hex"),t["skein256-88"]=e.from("b30b","hex"),t["skein256-96"]=e.from("b30c","hex"),t["skein256-104"]=e.from("b30d","hex"),t["skein256-112"]=e.from("b30e","hex"),t["skein256-120"]=e.from("b30f","hex"),t["skein256-128"]=e.from("b310","hex"),t["skein256-136"]=e.from("b311","hex"),t["skein256-144"]=e.from("b312","hex"),t["skein256-152"]=e.from("b313","hex"),t["skein256-160"]=e.from("b314","hex"),t["skein256-168"]=e.from("b315","hex"),t["skein256-176"]=e.from("b316","hex"),t["skein256-184"]=e.from("b317","hex"),t["skein256-192"]=e.from("b318","hex"),t["skein256-200"]=e.from("b319","hex"),t["skein256-208"]=e.from("b31a","hex"),t["skein256-216"]=e.from("b31b","hex"),t["skein256-224"]=e.from("b31c","hex"),t["skein256-232"]=e.from("b31d","hex"),t["skein256-240"]=e.from("b31e","hex"),t["skein256-248"]=e.from("b31f","hex"),t["skein256-256"]=e.from("b320","hex"),t["skein512-8"]=e.from("b321","hex"),t["skein512-16"]=e.from("b322","hex"),t["skein512-24"]=e.from("b323","hex"),t["skein512-32"]=e.from("b324","hex"),t["skein512-40"]=e.from("b325","hex"),t["skein512-48"]=e.from("b326","hex"),t["skein512-56"]=e.from("b327","hex"),t["skein512-64"]=e.from("b328","hex"),t["skein512-72"]=e.from("b329","hex"),t["skein512-80"]=e.from("b32a","hex"),t["skein512-88"]=e.from("b32b","hex"),t["skein512-96"]=e.from("b32c","hex"),t["skein512-104"]=e.from("b32d","hex"),t["skein512-112"]=e.from("b32e","hex"),t["skein512-120"]=e.from("b32f","hex"),t["skein512-128"]=e.from("b330","hex"),t["skein512-136"]=e.from("b331","hex"),t["skein512-144"]=e.from("b332","hex"),t["skein512-152"]=e.from("b333","hex"),t["skein512-160"]=e.from("b334","hex"),t["skein512-168"]=e.from("b335","hex"),t["skein512-176"]=e.from("b336","hex"),t["skein512-184"]=e.from("b337","hex"),t["skein512-192"]=e.from("b338","hex"),t["skein512-200"]=e.from("b339","hex"),t["skein512-208"]=e.from("b33a","hex"),t["skein512-216"]=e.from("b33b","hex"),t["skein512-224"]=e.from("b33c","hex"),t["skein512-232"]=e.from("b33d","hex"),t["skein512-240"]=e.from("b33e","hex"),t["skein512-248"]=e.from("b33f","hex"),t["skein512-256"]=e.from("b340","hex"),t["skein512-264"]=e.from("b341","hex"),t["skein512-272"]=e.from("b342","hex"),t["skein512-280"]=e.from("b343","hex"),t["skein512-288"]=e.from("b344","hex"),t["skein512-296"]=e.from("b345","hex"),t["skein512-304"]=e.from("b346","hex"),t["skein512-312"]=e.from("b347","hex"),t["skein512-320"]=e.from("b348","hex"),t["skein512-328"]=e.from("b349","hex"),t["skein512-336"]=e.from("b34a","hex"),t["skein512-344"]=e.from("b34b","hex"),t["skein512-352"]=e.from("b34c","hex"),t["skein512-360"]=e.from("b34d","hex"),t["skein512-368"]=e.from("b34e","hex"),t["skein512-376"]=e.from("b34f","hex"),t["skein512-384"]=e.from("b350","hex"),t["skein512-392"]=e.from("b351","hex"),t["skein512-400"]=e.from("b352","hex"),t["skein512-408"]=e.from("b353","hex"),t["skein512-416"]=e.from("b354","hex"),t["skein512-424"]=e.from("b355","hex"),t["skein512-432"]=e.from("b356","hex"),t["skein512-440"]=e.from("b357","hex"),t["skein512-448"]=e.from("b358","hex"),t["skein512-456"]=e.from("b359","hex"),t["skein512-464"]=e.from("b35a","hex"),t["skein512-472"]=e.from("b35b","hex"),t["skein512-480"]=e.from("b35c","hex"),t["skein512-488"]=e.from("b35d","hex"),t["skein512-496"]=e.from("b35e","hex"),t["skein512-504"]=e.from("b35f","hex"),t["skein512-512"]=e.from("b360","hex"),t["skein1024-8"]=e.from("b361","hex"),t["skein1024-16"]=e.from("b362","hex"),t["skein1024-24"]=e.from("b363","hex"),t["skein1024-32"]=e.from("b364","hex"),t["skein1024-40"]=e.from("b365","hex"),t["skein1024-48"]=e.from("b366","hex"),t["skein1024-56"]=e.from("b367","hex"),t["skein1024-64"]=e.from("b368","hex"),t["skein1024-72"]=e.from("b369","hex"),t["skein1024-80"]=e.from("b36a","hex"),t["skein1024-88"]=e.from("b36b","hex"),t["skein1024-96"]=e.from("b36c","hex"),t["skein1024-104"]=e.from("b36d","hex"),t["skein1024-112"]=e.from("b36e","hex"),t["skein1024-120"]=e.from("b36f","hex"),t["skein1024-128"]=e.from("b370","hex"),t["skein1024-136"]=e.from("b371","hex"),t["skein1024-144"]=e.from("b372","hex"),t["skein1024-152"]=e.from("b373","hex"),t["skein1024-160"]=e.from("b374","hex"),t["skein1024-168"]=e.from("b375","hex"),t["skein1024-176"]=e.from("b376","hex"),t["skein1024-184"]=e.from("b377","hex"),t["skein1024-192"]=e.from("b378","hex"),t["skein1024-200"]=e.from("b379","hex"),t["skein1024-208"]=e.from("b37a","hex"),t["skein1024-216"]=e.from("b37b","hex"),t["skein1024-224"]=e.from("b37c","hex"),t["skein1024-232"]=e.from("b37d","hex"),t["skein1024-240"]=e.from("b37e","hex"),t["skein1024-248"]=e.from("b37f","hex"),t["skein1024-256"]=e.from("b380","hex"),t["skein1024-264"]=e.from("b381","hex"),t["skein1024-272"]=e.from("b382","hex"),t["skein1024-280"]=e.from("b383","hex"),t["skein1024-288"]=e.from("b384","hex"),t["skein1024-296"]=e.from("b385","hex"),t["skein1024-304"]=e.from("b386","hex"),t["skein1024-312"]=e.from("b387","hex"),t["skein1024-320"]=e.from("b388","hex"),t["skein1024-328"]=e.from("b389","hex"),t["skein1024-336"]=e.from("b38a","hex"),t["skein1024-344"]=e.from("b38b","hex"),t["skein1024-352"]=e.from("b38c","hex"),t["skein1024-360"]=e.from("b38d","hex"),t["skein1024-368"]=e.from("b38e","hex"),t["skein1024-376"]=e.from("b38f","hex"),t["skein1024-384"]=e.from("b390","hex"),t["skein1024-392"]=e.from("b391","hex"),t["skein1024-400"]=e.from("b392","hex"),t["skein1024-408"]=e.from("b393","hex"),t["skein1024-416"]=e.from("b394","hex"),t["skein1024-424"]=e.from("b395","hex"),t["skein1024-432"]=e.from("b396","hex"),t["skein1024-440"]=e.from("b397","hex"),t["skein1024-448"]=e.from("b398","hex"),t["skein1024-456"]=e.from("b399","hex"),t["skein1024-464"]=e.from("b39a","hex"),t["skein1024-472"]=e.from("b39b","hex"),t["skein1024-480"]=e.from("b39c","hex"),t["skein1024-488"]=e.from("b39d","hex"),t["skein1024-496"]=e.from("b39e","hex"),t["skein1024-504"]=e.from("b39f","hex"),t["skein1024-512"]=e.from("b3a0","hex"),t["skein1024-520"]=e.from("b3a1","hex"),t["skein1024-528"]=e.from("b3a2","hex"),t["skein1024-536"]=e.from("b3a3","hex"),t["skein1024-544"]=e.from("b3a4","hex"),t["skein1024-552"]=e.from("b3a5","hex"),t["skein1024-560"]=e.from("b3a6","hex"),t["skein1024-568"]=e.from("b3a7","hex"),t["skein1024-576"]=e.from("b3a8","hex"),t["skein1024-584"]=e.from("b3a9","hex"),t["skein1024-592"]=e.from("b3aa","hex"),t["skein1024-600"]=e.from("b3ab","hex"),t["skein1024-608"]=e.from("b3ac","hex"),t["skein1024-616"]=e.from("b3ad","hex"),t["skein1024-624"]=e.from("b3ae","hex"),t["skein1024-632"]=e.from("b3af","hex"),t["skein1024-640"]=e.from("b3b0","hex"),t["skein1024-648"]=e.from("b3b1","hex"),t["skein1024-656"]=e.from("b3b2","hex"),t["skein1024-664"]=e.from("b3b3","hex"),t["skein1024-672"]=e.from("b3b4","hex"),t["skein1024-680"]=e.from("b3b5","hex"),t["skein1024-688"]=e.from("b3b6","hex"),t["skein1024-696"]=e.from("b3b7","hex"),t["skein1024-704"]=e.from("b3b8","hex"),t["skein1024-712"]=e.from("b3b9","hex"),t["skein1024-720"]=e.from("b3ba","hex"),t["skein1024-728"]=e.from("b3bb","hex"),t["skein1024-736"]=e.from("b3bc","hex"),t["skein1024-744"]=e.from("b3bd","hex"),t["skein1024-752"]=e.from("b3be","hex"),t["skein1024-760"]=e.from("b3bf","hex"),t["skein1024-768"]=e.from("b3c0","hex"),t["skein1024-776"]=e.from("b3c1","hex"),t["skein1024-784"]=e.from("b3c2","hex"),t["skein1024-792"]=e.from("b3c3","hex"),t["skein1024-800"]=e.from("b3c4","hex"),t["skein1024-808"]=e.from("b3c5","hex"),t["skein1024-816"]=e.from("b3c6","hex"),t["skein1024-824"]=e.from("b3c7","hex"),t["skein1024-832"]=e.from("b3c8","hex"),t["skein1024-840"]=e.from("b3c9","hex"),t["skein1024-848"]=e.from("b3ca","hex"),t["skein1024-856"]=e.from("b3cb","hex"),t["skein1024-864"]=e.from("b3cc","hex"),t["skein1024-872"]=e.from("b3cd","hex"),t["skein1024-880"]=e.from("b3ce","hex"),t["skein1024-888"]=e.from("b3cf","hex"),t["skein1024-896"]=e.from("b3d0","hex"),t["skein1024-904"]=e.from("b3d1","hex"),t["skein1024-912"]=e.from("b3d2","hex"),t["skein1024-920"]=e.from("b3d3","hex"),t["skein1024-928"]=e.from("b3d4","hex"),t["skein1024-936"]=e.from("b3d5","hex"),t["skein1024-944"]=e.from("b3d6","hex"),t["skein1024-952"]=e.from("b3d7","hex"),t["skein1024-960"]=e.from("b3d8","hex"),t["skein1024-968"]=e.from("b3d9","hex"),t["skein1024-976"]=e.from("b3da","hex"),t["skein1024-984"]=e.from("b3db","hex"),t["skein1024-992"]=e.from("b3dc","hex"),t["skein1024-1000"]=e.from("b3dd","hex"),t["skein1024-1008"]=e.from("b3de","hex"),t["skein1024-1016"]=e.from("b3df","hex"),t["skein1024-1024"]=e.from("b3e0","hex"),t.ip4=e.from("04","hex"),t.tcp=e.from("06","hex"),t.dccp=e.from("21","hex"),t.ip6=e.from("29","hex"),t.ip6zone=e.from("2a","hex"),t.dns=e.from("35","hex"),t.dns4=e.from("36","hex"),t.dns6=e.from("37","hex"),t.dnsaddr=e.from("38","hex"),t.sctp=e.from("84","hex"),t.udp=e.from("0111","hex"),t["p2p-webrtc-star"]=e.from("0113","hex"),t["p2p-webrtc-direct"]=e.from("0114","hex"),t["p2p-stardust"]=e.from("0115","hex"),t["p2p-circuit"]=e.from("0122","hex"),t.udt=e.from("012d","hex"),t.utp=e.from("012e","hex"),t.unix=e.from("0190","hex"),t.p2p=e.from("01a5","hex"),t.ipfs=e.from("01a5","hex"),t.https=e.from("01bb","hex"),t.onion=e.from("01bc","hex"),t.onion3=e.from("01bd","hex"),t.garlic64=e.from("01be","hex"),t.garlic32=e.from("01bf","hex"),t.quic=e.from("01cc","hex"),t.ws=e.from("01dd","hex"),t.wss=e.from("01de","hex"),t["p2p-websocket-star"]=e.from("01df","hex"),t.http=e.from("01e0","hex"),t.raw=e.from("55","hex"),t["dag-pb"]=e.from("70","hex"),t["dag-cbor"]=e.from("71","hex"),t["libp2p-key"]=e.from("72","hex"),t["git-raw"]=e.from("78","hex"),t["torrent-info"]=e.from("7b","hex"),t["torrent-file"]=e.from("7c","hex"),t["leofcoin-block"]=e.from("81","hex"),t["leofcoin-tx"]=e.from("82","hex"),t["leofcoin-pr"]=e.from("83","hex"),t["eth-block"]=e.from("90","hex"),t["eth-block-list"]=e.from("91","hex"),t["eth-tx-trie"]=e.from("92","hex"),t["eth-tx"]=e.from("93","hex"),t["eth-tx-receipt-trie"]=e.from("94","hex"),t["eth-tx-receipt"]=e.from("95","hex"),t["eth-state-trie"]=e.from("96","hex"),t["eth-account-snapshot"]=e.from("97","hex"),t["eth-storage-trie"]=e.from("98","hex"),t["bitcoin-block"]=e.from("b0","hex"),t["bitcoin-tx"]=e.from("b1","hex"),t["zcash-block"]=e.from("c0","hex"),t["zcash-tx"]=e.from("c1","hex"),t["stellar-block"]=e.from("d0","hex"),t["stellar-tx"]=e.from("d1","hex"),t["decred-block"]=e.from("e0","hex"),t["decred-tx"]=e.from("e1","hex"),t["dash-block"]=e.from("f0","hex"),t["dash-tx"]=e.from("f1","hex"),t["swarm-manifest"]=e.from("fa","hex"),t["swarm-feed"]=e.from("fb","hex"),t["dag-json"]=e.from("0129","hex"),t.path=e.from("2f","hex"),t["ipld-ns"]=e.from("e2","hex"),t["ipfs-ns"]=e.from("e3","hex"),t["swarm-ns"]=e.from("e4","hex"),t["ed25519-pub"]=e.from("ed","hex"),t["holochain-adr-v0"]=e.from("807124","hex"),t["holochain-adr-v1"]=e.from("817124","hex"),t["holochain-key-v0"]=e.from("947124","hex"),t["holochain-key-v1"]=e.from("957124","hex"),t["holochain-sig-v0"]=e.from("a27124","hex"),t["holochain-sig-v1"]=e.from("a37124","hex")}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(9),o=n(24),s=n(39);class a{constructor(e,t,n){o(n,"A link requires a cid to point to"),this._name=e||"",this._nameBuf=null,this._size=t,this._cid=new i(n)}toString(){return`DAGLink <${this._cid.toBaseEncodedString()} - name: "${this.name}", size: ${this.size}>`}toJSON(){return this._json||(this._json=Object.freeze({name:this.name,size:this.size,cid:this._cid.toBaseEncodedString()})),Object.assign({},this._json)}get name(){return this._name}get nameAsBuffer(){return null!==this._nameBuf?this._nameBuf:(this._nameBuf=r.from(this._name),this._nameBuf)}set name(e){throw new Error("Can't set property: 'name' is immutable")}get size(){return this._size}set size(e){throw new Error("Can't set property: 'size' is immutable")}get cid(){return this._cid}set cid(e){throw new Error("Can't set property: 'cid' is immutable")}}t=e.exports=s(a,{className:"DAGLink",symbolName:"@ipld/js-ipld-dag-pb/daglink"}),t.create=n(740),t.util=n(741)}).call(this,n(0).Buffer)},function(e,t,n){var r=n(21);e.exports=r.md=r.md||{},r.md.algorithms=r.md.algorithms||{}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(381),a=n(259);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){var r=n(5).Buffer,i=n(62).Transform,o=n(18).StringDecoder,s=n(1);function a(e){i.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}s(a,i),a.prototype.update=function(e,t,n){"string"==typeof e&&(e=r.from(e,t));var i=this._update(e);return this.hashMode?this:(n&&(i=this._toString(i,n)),i)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(e,t,n){var r;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){r=e}finally{n(r)}},a.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},a.prototype._finalOrDigest=function(e){var t=this.__final()||r.alloc(0);return e&&(t=this._toString(t,e,!0)),t},a.prototype._toString=function(e,t,n){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var r=this._decoder.write(e);return n&&(r+=this._decoder.end()),r},e.exports=a},function(e,t,n){"use strict";const r=n(4),i=(e,t)=>{const n=["bitswap"];t&&n.push(t),e&&n.push(`${e.toB58String().slice(0,8)}`);const i=r(n.join(":"));return i.error=r(n.concat(["error"]).join(":")),i},o=(e,t,n)=>{let r=0;const i=n.length;for(;r<i;){if(e(t,n[r]))return!0;r+=1}return!1},s=(e,t)=>{let n=0;const r=t.length,i=[];let s;for(;n<r;)s=t[n],o(e,s,i)||(i[i.length]=s),n+=1;return i},a=(e,t)=>t.reduce((t,n)=>{const r=e(n);return t[r]?t[r].push(n):t[r]=[n],t},{}),l=(e,t,n)=>t.filter(t=>!o(e,t,n)),u=(e,t)=>Array.prototype.slice.call(t,0).sort((t,n)=>{const r=e(t),i=e(n);return r<i?-1:r>i?1:0});e.exports={logger:i,includesWith:o,uniqWith:s,groupBy:a,pullAllWith:l,sortBy:u}},function(e,t,n){"use strict";(function(t,r){var i=65536,o=4294967295;function s(){throw new Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}var a=n(5).Buffer,l=t.crypto||t.msCrypto;function u(e,t){if(e>o)throw new RangeError("requested too many random bytes");var n=a.allocUnsafe(e);if(e>0)if(e>i)for(var s=0;s<e;s+=i)l.getRandomValues(n.slice(s,s+i));else l.getRandomValues(n);return"function"==typeof t?r.nextTick(function(){t(null,n)}):n}l&&l.getRandomValues?e.exports=u:e.exports=s}).call(this,n(8),n(3))},function(e,t,n){var r=n(429),i=n(63),o=n(213),s=n(214);function a(e){var t=0;return function(n,r,i){t++||e(n,r,i)}}function l(e){return"function"==typeof e}e.exports=function(e,t){l(e)&&(t=e,e={}),t=a(t||function e(){});var n=r(e&&e.timeout||5e3),u=i(function(e){e&&t(e)}),c=s();return{handshake:{read:n.read,abort:function(e){u.end(e),n.abort(e,function(e){}),t(e)},write:u.push,rest:function(){return u.end(),{source:n.read(),sink:c.sink}}},sink:n,source:o([u,c.source])}}},function(e,t,n){var r=n(1077),i=n(1080);function o(e,t){var n=i(e,t);return r(n)?n:void 0}e.exports=o},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(529),a=n(532);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){(function(t){var r=n(1297),i=n(1298);e.exports=function e(n,o,s){if("number"!=typeof n)throw new TypeError('"size" argument must be a number');if(n<0)throw new RangeError('"size" argument must not be negative');if(t.alloc)return t.alloc(n,o,s);var a=i(n);return 0===n?a:void 0===o?r(a,0):("string"!=typeof s&&(s=void 0),r(a,o,s))}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var n=(0,s.default)(e);return(0,i.default)(function(e,t){n(e[0],t)},t,1)};var r=n(646),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}e.exports=t.default},function(e,t,n){"use strict";function r(e){return function(){if(null===e)throw new Error("Callback was already called.");var t=e;e=null,t.apply(this,arguments)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t,n){var r=n(182),i=n(653),o=n(654),s="[object Null]",a="[object Undefined]",l=r?r.toStringTag:void 0;function u(e){return null==e?void 0===e?a:s:l&&l in Object(e)?i(e):o(e)}e.exports=u},function(e,t,n){"use strict";function r(e,t){return function(n,r,i){return e(n,t,r,i)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(241),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e){return function(t,n,r){return e(i.default,t,(0,s.default)(n),r)}}e.exports=t.default},function(e,t,n){const r=n(32),i=n(17),o=n(77);function s(e,t){return new Promise(n=>{setTimeout(()=>{n(t)},e)})}class a{constructor(e){}static setup0(e){throw new o.IntentionallyUnimplementedError("Intentionally undefined function Transport.setup0 should have been subclassed")}p_setup1(e){return this}p_setup2(e){return this}static async p_setup(e,t){let n=await this.setup0(e).p_setup1(t);return n.p_setup2(t)}stop(e,t){this.status=a.STATUS_FAILED,e&&e(this),t(null,this)}togglePaused(e){switch(this.status){case a.STATUS_CONNECTED:this.status=a.STATUS_PAUSED;break;case a.STATUS_PAUSED:this.status=a.STATUS_CONNECTED;break;case a.STATUS_LOADED:this.p_setup1(e).then(t=>t.p_setup2(e))}e&&e(this)}async p_status(){return this.status}connected(){return!this.status}supports(e,t,{noCache:n}={}){if("string"==typeof e&&(e=r.parse(e)),e&&!e.protocol)throw new Error("URL failed to specific a scheme (before :) "+e.href);return(!e||this.supportURLs.includes(e.protocol.slice(0,-1)))&&(!t||this.supportFunctions.includes(t))&&(!n||this.supportFeatures.includes("noCache"))}validFor(e,t,n){return this.connected()&&this.supports(e,t,n)}p_rawstore(e,t){throw new o.ToBeImplementedError("Intentionally undefined function Transport.p_rawstore should have been subclassed")}async p_rawstoreCaught(e){try{return await this.p_rawstore(e)}catch(e){}}p_store(){throw new o.ToBeImplementedError("Undefined function Transport.p_store - may define higher level semantics here (see Python)")}p_rawfetch(e,{timeoutMS:t,start:n,end:r,relay:i=!1}={}){return console.assert(!1,"Intentionally undefined function Transport.p_rawfetch should have been subclassed"),"UNIMPLEMENTED"}p_fetch(){throw new o.ToBeImplementedError("Undefined function Transport.p_fetch - may define higher level semantics here (see Python)")}p_rawadd(e,t){throw new o.ToBeImplementedError("Undefined function Transport.p_rawadd")}p_rawlist(e){throw new o.ToBeImplementedError("Undefined function Transport.p_rawlist")}p_list(){throw new Error("Undefined function Transport.p_list")}p_newlisturls(e){throw new Error("undefined function Transport.p_newlisturls")}p_rawreverse(e){throw new o.ToBeImplementedError("Undefined function Transport.p_rawreverse")}listmonitor(e,t,{current:n=!1}={}){console.log("Undefined function Transport.listmonitor")}async p_newdatabase(e){throw new o.ToBeImplementedError("Undefined function Transport.p_newdatabase")}async p_newtable(e,t){throw new o.ToBeImplementedError("Undefined function Transport.p_newtable")}async p_set(e,t,n){throw new o.ToBeImplementedError("Undefined function Transport.p_set")}async p_get(e,t){throw new o.ToBeImplementedError("Undefined function Transport.p_get")}async p_delete(e,t){throw new o.ToBeImplementedError("Undefined function Transport.p_delete")}async p_keys(e){throw new o.ToBeImplementedError("Undefined function Transport.p_keys")}async p_getall(e){throw new o.ToBeImplementedError("Undefined function Transport.p_keys")}static async p_f_createReadStream(e,{wanturl:t=!1}){}static mergeoptions(e){let t={};for(let n=0;n<arguments.length;n++){let r=arguments[n];for(let n in r){let i=r[n];null!==i&&("object"==typeof i&&!Array.isArray(i)&&t[n]?t[n]=a.mergeoptions(e[n],r[n]):t[n]=r[n])}}return t}async p_test_list({urlexpectedsubstring:e}={}){console.log(this.name,"p_test_kvt");try{let t=await this.p_newlisturls("NACL VERIFY:1234567LIST"),n=t.publicurl;console.log("newlisturls=",n),console.assert(!e||n.includes(e)),await this.p_rawadd(n,"testvalue");let r=await this.p_rawlist(n);console.assert(1===r.length&&"testvalue"===r[0]),await this.p_rawadd(n,{foo:"bar"}),r=await this.p_rawlist(n),console.assert(2===r.length&&"bar"===r[1].foo),await this.p_rawadd(n,[1,2,3]),r=await this.p_rawlist(n),console.assert(2===r.length&&3===r[2].length&&2===r[2][1]),await s(200),console.log(this.name,"p_test_list complete")}catch(e){throw console.log("Exception thrown in ",this.name,"p_test_list:",e.message),e}}async p_test_kvt(e){console.log(this.name,"p_test_kvt");try{let t=await this.p_newtable("NACL VERIFY:1234567KVT","mytable"),n=t.publicurl;console.log("newtable=",n),console.assert(n.includes(e)),await this.p_set(n,"testkey","testvalue");let r=await this.p_get(n,"testkey");console.assert("testvalue"===r),await this.p_set(n,"testkey2",{foo:"bar"}),r=await this.p_get(n,"testkey2"),console.assert("bar"===r.foo),await this.p_set(n,"testkey3",[1,2,3]),r=await this.p_get(n,"testkey3"),console.assert(2===r[1]),r=await this.p_keys(n),console.assert(r.includes("testkey")&&r.includes("testkey3")&&3===r.length),await this.p_delete(n,["testkey"]),r=await this.p_getall(n),console.log("getall=>",r),console.assert("bar"===r.testkey2.foo&&2===r.testkey3[1]&&!r.testkey),await s(200),console.log(this.name,"p_test_kvt complete")}catch(e){throw console.log("Exception thrown in ",this.name,"p_test_kvt:",e.message),e}}}a.STATUS_CONNECTED=0,a.STATUS_FAILED=1,a.STATUS_STARTING=2,a.STATUS_LOADED=3,a.STATUS_PAUSED=4,a.STATUSTEXT=["Connected","Failed","Starting","Loaded","Paused"],t=e.exports=a},function(e,t,n){"use strict";function r(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var i={};function o(e,t,n){function o(e,n,r){return"string"==typeof t?t:t(e,n,r)}n||(n=Error);var s=function(e){function t(t,n,r){return e.call(this,o(t,n,r))||this}return r(t,e),t}(n);s.prototype.name=n.name,s.prototype.code=e,i[e]=s}function s(e,t){if(Array.isArray(e)){var n=e.length;return e=e.map(function(e){return String(e)}),n>2?"one of ".concat(t," ").concat(e.slice(0,n-1).join(", "),", or ")+e[n-1]:2===n?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}function a(e,t,n){return e.substr(!n||n<0?0:+n,t.length)===t}function l(e,t,n){return(void 0===n||n>e.length)&&(n=e.length),e.substring(n-t.length,n)===t}function u(e,t,n){return"number"!=typeof n&&(n=0),!(n+t.length>e.length)&&-1!==e.indexOf(t,n)}o("ERR_INVALID_OPT_VALUE",function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'},TypeError),o("ERR_INVALID_ARG_TYPE",function(e,t,n){var r,i;if("string"==typeof t&&a(t,"not ")?(r="must not be",t=t.replace(/^not /,"")):r="must be",l(e," argument"))i="The ".concat(e," ").concat(r," ").concat(s(t,"type"));else{var o=u(e,".")?"property":"argument";i='The "'.concat(e,'" ').concat(o," ").concat(r," ").concat(s(t,"type"))}return i+=". Received type ".concat(typeof n),i},TypeError),o("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),o("ERR_METHOD_NOT_IMPLEMENTED",function(e){return"The "+e+" method is not implemented"}),o("ERR_STREAM_PREMATURE_CLOSE","Premature close"),o("ERR_STREAM_DESTROYED",function(e){return"Cannot call "+e+" after a stream was destroyed"}),o("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),o("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),o("ERR_STREAM_WRITE_AFTER_END","write after end"),o("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),o("ERR_UNKNOWN_ENCODING",function(e){return"Unknown encoding: "+e},TypeError),o("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=i},function(e,t,n){"use strict";(function(t){var r=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=u;var i=n(335),o=n(339);n(1)(u,i);for(var s=r(o.prototype),a=0;a<s.length;a++){var l=s[a];u.prototype[l]||(u.prototype[l]=o.prototype[l])}function u(e){if(!(this instanceof u))return new u(e);i.call(this,e),o.call(this,e),this.allowHalfOpen=!0,e&&(!1===e.readable&&(this.readable=!1),!1===e.writable&&(this.writable=!1),!1===e.allowHalfOpen&&(this.allowHalfOpen=!1,this.once("end",c)))}function c(){this._writableState.ended||t.nextTick(h,this)}function h(e){e.end()}Object.defineProperty(u.prototype,"writableHighWaterMark",{enumerable:!1,get:function e(){return this._writableState.highWaterMark}}),Object.defineProperty(u.prototype,"writableBuffer",{enumerable:!1,get:function e(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(u.prototype,"writableLength",{enumerable:!1,get:function e(){return this._writableState.length}}),Object.defineProperty(u.prototype,"destroyed",{enumerable:!1,get:function e(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function e(t){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=t,this._writableState.destroyed=t)}})}).call(this,n(3))},function(e,t,n){"use strict";(function(t){const r=n(680),i=n(39);class o{constructor(e,n){if(!e||!t.isBuffer(e))throw new Error("first argument must be a buffer");if(!n||!r.isCID(n))throw new Error("second argument must be a CID");this._data=e,this._cid=n}get data(){return this._data}set data(e){throw new Error("Tried to change an immutable block")}get cid(){return this._cid}set cid(e){throw new Error("Tried to change an immutable block")}}e.exports=i(o,{className:"Block",symbolName:"@ipfs/js-ipfs-block/block"})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(35),o=n(692),s=n(342),a=n(341);t=e.exports,t.addPrefix=((e,t)=>{let n;if(r.isBuffer(e))n=a.varintBufferEncode(e);else{if(!o[e])throw new Error("multicodec not recognized");n=o[e]}return r.concat([n,t])}),t.rmPrefix=(e=>(i.decode(e),e.slice(i.decode.bytes))),t.getCodec=(e=>{const t=a.varintBufferDecode(e),n=s[t.toString("hex")];if(void 0===n)throw new Error("Code `0x"+t.toString("hex")+"` not found");return n}),t.getName=(e=>s[e.toString(16)]),t.getNumber=(e=>{const t=o[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return a.varintBufferDecode(t)[0]}),t.getCode=(e=>i.decode(e)),t.getCodeVarint=(e=>{const t=o[e];if(void 0===t)throw new Error("Codec `"+e+"` not found");return t}),t.getVarint=(e=>i.encode(e));const l=n(693);Object.assign(t,l),t.print=n(694)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=n(343);e.exports=function e(t,n){return function(e,i){if(e)return r(i,e,n);if(null!=t){var o=t;t=null,i(null,o)}else i(!0)}}},function(e,t,n){var r=n(21);n(30),n(152);var i=e.exports=r.asn1=r.asn1||{};function o(e,t,n){if(n>t){var r=new Error("Too few bytes to parse DER.");throw r.available=e.length(),r.remaining=t,r.requested=n,r}}i.Class={UNIVERSAL:0,APPLICATION:64,CONTEXT_SPECIFIC:128,PRIVATE:192},i.Type={NONE:0,BOOLEAN:1,INTEGER:2,BITSTRING:3,OCTETSTRING:4,NULL:5,OID:6,ODESC:7,EXTERNAL:8,REAL:9,ENUMERATED:10,EMBEDDED:11,UTF8:12,ROID:13,SEQUENCE:16,SET:17,PRINTABLESTRING:19,IA5STRING:22,UTCTIME:23,GENERALIZEDTIME:24,BMPSTRING:30},i.create=function(e,t,n,o,s){if(r.util.isArray(o)){for(var a=[],l=0;l<o.length;++l)void 0!==o[l]&&a.push(o[l]);o=a}var u={tagClass:e,type:t,constructed:n,composed:n||r.util.isArray(o),value:o};return s&&"bitStringContents"in s&&(u.bitStringContents=s.bitStringContents,u.original=i.copy(u)),u},i.copy=function(e,t){var n;if(r.util.isArray(e)){n=[];for(var o=0;o<e.length;++o)n.push(i.copy(e[o],t));return n}return"string"==typeof e?e:(n={tagClass:e.tagClass,type:e.type,constructed:e.constructed,composed:e.composed,value:i.copy(e.value,t)},t&&!t.excludeBitStringContents&&(n.bitStringContents=e.bitStringContents),n)},i.equals=function(e,t,n){if(r.util.isArray(e)){if(!r.util.isArray(t))return!1;if(e.length!==t.length)return!1;for(var o=0;o<e.length;++o)if(!i.equals(e[o],t[o]))return!1;return!0}if(typeof e!=typeof t)return!1;if("string"==typeof e)return e===t;var s=e.tagClass===t.tagClass&&e.type===t.type&&e.constructed===t.constructed&&e.composed===t.composed&&i.equals(e.value,t.value);return n&&n.includeBitStringContents&&(s=s&&e.bitStringContents===t.bitStringContents),s},i.getBerValueLength=function(e){var t=e.getByte();if(128!==t){var n,r=128&t;return n=r?e.getInt((127&t)<<3):t,n}};var s=function(e,t){var n=e.getByte();if(t--,128!==n){var r,i=128&n;if(i){var s=127&n;o(e,t,s),r=e.getInt(s<<3)}else r=n;if(r<0)throw new Error("Negative length: "+r);return r}};function a(e,t,n,r){var l;o(e,t,2);var u=e.getByte();t--;var c=192&u,h=31&u;l=e.length();var f=s(e,t),p,d;if(t-=l-e.length(),void 0!==f&&f>t){if(r.strict){var m=new Error("Too few bytes to read ASN.1 value.");throw m.available=e.length(),m.remaining=t,m.requested=f,m}f=t}var g=32==(32&u);if(g)if(p=[],void 0===f)for(;;){if(o(e,t,2),e.bytes(2)===String.fromCharCode(0,0)){e.getBytes(2),t-=2;break}l=e.length(),p.push(a(e,t,n+1,r)),t-=l-e.length()}else for(;f>0;)l=e.length(),p.push(a(e,f,n+1,r)),t-=l-e.length(),f-=l-e.length();if(void 0===p&&c===i.Class.UNIVERSAL&&h===i.Type.BITSTRING&&(d=e.bytes(f)),void 0===p&&r.decodeBitStrings&&c===i.Class.UNIVERSAL&&h===i.Type.BITSTRING&&f>1){var y=e.read,v=t,b=0;if(h===i.Type.BITSTRING&&(o(e,t,1),b=e.getByte(),t--),0===b)try{l=e.length();var _={verbose:r.verbose,strict:!0,decodeBitStrings:!0},w=a(e,t,n+1,_),k=l-e.length();t-=k,h==i.Type.BITSTRING&&k++;var E=w.tagClass;k!==f||E!==i.Class.UNIVERSAL&&E!==i.Class.CONTEXT_SPECIFIC||(p=[w])}catch(e){}void 0===p&&(e.read=y,t=v)}if(void 0===p){if(void 0===f){if(r.strict)throw new Error("Non-constructed ASN.1 object of indefinite length.");f=t}if(h===i.Type.BMPSTRING)for(p="";f>0;f-=2)o(e,t,2),p+=String.fromCharCode(e.getInt16()),t-=2;else p=e.getBytes(f)}var S=void 0===d?null:{bitStringContents:d};return i.create(c,h,g,p,S)}i.fromDer=function(e,t){return void 0===t&&(t={strict:!0,decodeBitStrings:!0}),"boolean"==typeof t&&(t={strict:t,decodeBitStrings:!0}),"strict"in t||(t.strict=!0),"decodeBitStrings"in t||(t.decodeBitStrings=!0),"string"==typeof e&&(e=r.util.createBuffer(e)),a(e,e.length(),0,t)},i.toDer=function(e){var t=r.util.createBuffer(),n=e.tagClass|e.type,o=r.util.createBuffer(),s=!1;if("bitStringContents"in e&&(s=!0,e.original&&(s=i.equals(e,e.original))),s)o.putBytes(e.bitStringContents);else if(e.composed){e.constructed?n|=32:o.putByte(0);for(var a=0;a<e.value.length;++a)void 0!==e.value[a]&&o.putBuffer(i.toDer(e.value[a]))}else if(e.type===i.Type.BMPSTRING)for(var a=0;a<e.value.length;++a)o.putInt16(e.value.charCodeAt(a));else e.type===i.Type.INTEGER&&e.value.length>1&&(0===e.value.charCodeAt(0)&&0==(128&e.value.charCodeAt(1))||255===e.value.charCodeAt(0)&&128==(128&e.value.charCodeAt(1)))?o.putBytes(e.value.substr(1)):o.putBytes(e.value);if(t.putByte(n),o.length()<=127)t.putByte(127&o.length());else{var l=o.length(),u="";do{u+=String.fromCharCode(255&l),l>>>=8}while(l>0);t.putByte(128|u.length);for(var a=u.length-1;a>=0;--a)t.putByte(u.charCodeAt(a))}return t.putBuffer(o),t},i.oidToDer=function(e){var t=e.split("."),n=r.util.createBuffer(),i,o,s,a;n.putByte(40*parseInt(t[0],10)+parseInt(t[1],10));for(var l=2;l<t.length;++l){i=!0,o=[],s=parseInt(t[l],10);do{a=127&s,s>>>=7,i||(a|=128),o.push(a),i=!1}while(s>0);for(var u=o.length-1;u>=0;--u)n.putByte(o[u])}return n},i.derToOid=function(e){var t;"string"==typeof e&&(e=r.util.createBuffer(e));var n=e.getByte();t=Math.floor(n/40)+"."+n%40;for(var i=0;e.length()>0;)n=e.getByte(),i<<=7,128&n?i+=127&n:(t+="."+(i+n),i=0);return t},i.utcTimeToDate=function(e){var t=new Date,n=parseInt(e.substr(0,2),10);n=n>=50?1900+n:2e3+n;var r=parseInt(e.substr(2,2),10)-1,i=parseInt(e.substr(4,2),10),o=parseInt(e.substr(6,2),10),s=parseInt(e.substr(8,2),10),a=0;if(e.length>11){var l=e.charAt(10),u=10;"+"!==l&&"-"!==l&&(a=parseInt(e.substr(10,2),10),u+=2)}if(t.setUTCFullYear(n,r,i),t.setUTCHours(o,s,a,0),u&&(l=e.charAt(u),"+"===l||"-"===l)){var c=parseInt(e.substr(u+1,2),10),h=parseInt(e.substr(u+4,2),10),f=60*c+h;f*=6e4,"+"===l?t.setTime(+t-f):t.setTime(+t+f)}return t},i.generalizedTimeToDate=function(e){var t=new Date,n=parseInt(e.substr(0,4),10),r=parseInt(e.substr(4,2),10)-1,i=parseInt(e.substr(6,2),10),o=parseInt(e.substr(8,2),10),s=parseInt(e.substr(10,2),10),a=parseInt(e.substr(12,2),10),l=0,u=0,c=!1;"Z"===e.charAt(e.length-1)&&(c=!0);var h=e.length-5,f=e.charAt(h);if("+"===f||"-"===f){var p=parseInt(e.substr(h+1,2),10),d=parseInt(e.substr(h+4,2),10);u=60*p+d,u*=6e4,"+"===f&&(u*=-1),c=!0}return"."===e.charAt(14)&&(l=1e3*parseFloat(e.substr(14),10)),c?(t.setUTCFullYear(n,r,i),t.setUTCHours(o,s,a,l),t.setTime(+t+u)):(t.setFullYear(n,r,i),t.setHours(o,s,a,l)),t},i.dateToUtcTime=function(e){if("string"==typeof e)return e;var t="",n=[];n.push((""+e.getUTCFullYear()).substr(2)),n.push(""+(e.getUTCMonth()+1)),n.push(""+e.getUTCDate()),n.push(""+e.getUTCHours()),n.push(""+e.getUTCMinutes()),n.push(""+e.getUTCSeconds());for(var r=0;r<n.length;++r)n[r].length<2&&(t+="0"),t+=n[r];return t+="Z",t},i.dateToGeneralizedTime=function(e){if("string"==typeof e)return e;var t="",n=[];n.push(""+e.getUTCFullYear()),n.push(""+(e.getUTCMonth()+1)),n.push(""+e.getUTCDate()),n.push(""+e.getUTCHours()),n.push(""+e.getUTCMinutes()),n.push(""+e.getUTCSeconds());for(var r=0;r<n.length;++r)n[r].length<2&&(t+="0"),t+=n[r];return t+="Z",t},i.integerToDer=function(e){var t=r.util.createBuffer();if(e>=-128&&e<128)return t.putSignedInt(e,8);if(e>=-32768&&e<32768)return t.putSignedInt(e,16);if(e>=-8388608&&e<8388608)return t.putSignedInt(e,24);if(e>=-2147483648&&e<2147483648)return t.putSignedInt(e,32);var n=new Error("Integer too large; max is 32-bits.");throw n.integer=e,n},i.derToInteger=function(e){"string"==typeof e&&(e=r.util.createBuffer(e));var t=8*e.length();if(t>32)throw new Error("Integer too large; max is 32-bits.");return e.getSignedInt(t)},i.validate=function(e,t,n,o){var s=!1;if(e.tagClass!==t.tagClass&&void 0!==t.tagClass||e.type!==t.type&&void 0!==t.type)o&&(e.tagClass!==t.tagClass&&o.push("["+t.name+'] Expected tag class "'+t.tagClass+'", got "'+e.tagClass+'"'),e.type!==t.type&&o.push("["+t.name+'] Expected type "'+t.type+'", got "'+e.type+'"'));else if(e.constructed===t.constructed||void 0===t.constructed){if(s=!0,t.value&&r.util.isArray(t.value))for(var a=0,l=0;s&&l<t.value.length;++l)s=t.value[l].optional||!1,e.value[a]&&(s=i.validate(e.value[a],t.value[l],n,o),s?++a:t.value[l].optional&&(s=!0)),!s&&o&&o.push("["+t.name+'] Tag class "'+t.tagClass+'", type "'+t.type+'" expected value length "'+t.value.length+'", got "'+e.value.length+'"');var u;if(s&&n)if(t.capture&&(n[t.capture]=e.value),t.captureAsn1&&(n[t.captureAsn1]=e),t.captureBitStringContents&&"bitStringContents"in e&&(n[t.captureBitStringContents]=e.bitStringContents),t.captureBitStringValue&&"bitStringContents"in e)if(e.bitStringContents.length<2)n[t.captureBitStringValue]="";else{var c=e.bitStringContents.charCodeAt(0);if(0!==c)throw new Error("captureBitStringValue only supported for zero unused bits");n[t.captureBitStringValue]=e.bitStringContents.slice(1)}}else o&&o.push("["+t.name+'] Expected constructed "'+t.constructed+'", got "'+e.constructed+'"');return s};var l=/[^\\u0000-\\u00ff]/;i.prettyPrint=function(e,t,n){var o="";t=t||0,n=n||2,t>0&&(o+="\n");for(var s="",a=0;a<t*n;++a)s+=" ";switch(o+=s+"Tag: ",e.tagClass){case i.Class.UNIVERSAL:o+="Universal:";break;case i.Class.APPLICATION:o+="Application:";break;case i.Class.CONTEXT_SPECIFIC:o+="Context-Specific:";break;case i.Class.PRIVATE:o+="Private:"}if(e.tagClass===i.Class.UNIVERSAL)switch(o+=e.type,e.type){case i.Type.NONE:o+=" (None)";break;case i.Type.BOOLEAN:o+=" (Boolean)";break;case i.Type.INTEGER:o+=" (Integer)";break;case i.Type.BITSTRING:o+=" (Bit string)";break;case i.Type.OCTETSTRING:o+=" (Octet string)";break;case i.Type.NULL:o+=" (Null)";break;case i.Type.OID:o+=" (Object Identifier)";break;case i.Type.ODESC:o+=" (Object Descriptor)";break;case i.Type.EXTERNAL:o+=" (External or Instance of)";break;case i.Type.REAL:o+=" (Real)";break;case i.Type.ENUMERATED:o+=" (Enumerated)";break;case i.Type.EMBEDDED:o+=" (Embedded PDV)";break;case i.Type.UTF8:o+=" (UTF8)";break;case i.Type.ROID:o+=" (Relative Object Identifier)";break;case i.Type.SEQUENCE:o+=" (Sequence)";break;case i.Type.SET:o+=" (Set)";break;case i.Type.PRINTABLESTRING:o+=" (Printable String)";break;case i.Type.IA5String:o+=" (IA5String (ASCII))";break;case i.Type.UTCTIME:o+=" (UTC time)";break;case i.Type.GENERALIZEDTIME:o+=" (Generalized time)";break;case i.Type.BMPSTRING:o+=" (BMP String)"}else o+=e.type;if(o+="\n",o+=s+"Constructed: "+e.constructed+"\n",e.composed){for(var u=0,c="",a=0;a<e.value.length;++a)void 0!==e.value[a]&&(u+=1,c+=i.prettyPrint(e.value[a],t+1,n),a+1<e.value.length&&(c+=","));o+=s+"Sub values: "+u+c}else{if(o+=s+"Value: ",e.type===i.Type.OID){var h=i.derToOid(e.value);o+=h,r.pki&&r.pki.oids&&h in r.pki.oids&&(o+=" ("+r.pki.oids[h]+") ")}if(e.type===i.Type.INTEGER)try{o+=i.derToInteger(e.value)}catch(t){o+="0x"+r.util.bytesToHex(e.value)}else if(e.type===i.Type.BITSTRING){if(e.value.length>1?o+="0x"+r.util.bytesToHex(e.value.slice(1)):o+="(none)",e.value.length>0){var f=e.value.charCodeAt(0);1==f?o+=" (1 unused bit shown)":f>1&&(o+=" ("+f+" unused bits shown)")}}else e.type===i.Type.OCTETSTRING?(l.test(e.value)||(o+="("+e.value+") "),o+="0x"+r.util.bytesToHex(e.value)):e.type===i.Type.UTF8?o+=r.util.decodeUtf8(e.value):e.type===i.Type.PRINTABLESTRING||e.type===i.Type.IA5String?o+=e.value:l.test(e.value)?o+="0x"+r.util.bytesToHex(e.value):0===e.value.length?o+="[null]":o+=e.value}return o}},function(e,t,n){var r=n(21);n(196),n(747),n(748),n(30),r.random&&r.random.getBytes?e.exports=r.random:function(t){var n={},i=new Array(4),o=r.util.createBuffer();function s(){var e=r.prng.create(n);return e.getBytes=function(t,n){return e.generate(t,n)},e.getBytesSync=function(t){return e.generate(t)},e}n.formatKey=function(e){var t=r.util.createBuffer(e);return e=new Array(4),e[0]=t.getInt32(),e[1]=t.getInt32(),e[2]=t.getInt32(),e[3]=t.getInt32(),r.aes._expandKey(e,!1)},n.formatSeed=function(e){var t=r.util.createBuffer(e);return e=new Array(4),e[0]=t.getInt32(),e[1]=t.getInt32(),e[2]=t.getInt32(),e[3]=t.getInt32(),e},n.cipher=function(e,t){return r.aes._updateBlock(e,t,i,!1),o.putInt32(i[0]),o.putInt32(i[1]),o.putInt32(i[2]),o.putInt32(i[3]),o.getBytes()},n.increment=function(e){return++e[3],e},n.md=r.md.sha256;var a=s(),l=null;if("undefined"!=typeof window){var u=window.crypto||window.msCrypto;u&&u.getRandomValues&&(l=function(e){return u.getRandomValues(e)})}if(r.options.usePureJavaScript||!r.util.isNodejs&&!l){if("undefined"==typeof window||window.document,a.collectInt(+new Date,32),"undefined"!=typeof navigator){var c="";for(var h in navigator)try{"string"==typeof navigator[h]&&(c+=navigator[h])}catch(e){}a.collect(c),c=null}t&&(t().mousemove(function(e){a.collectInt(e.clientX,16),a.collectInt(e.clientY,16)}),t().keypress(function(e){a.collectInt(e.charCode,8)}))}if(r.random)for(var h in a)r.random[h]=a[h];else r.random=a;r.random.createInstance=s,e.exports=r.random}("undefined"!=typeof jQuery?jQuery:null)},function(e,t,n){"use strict";const r=t;r.bignum=n(757),r.define=n(759).define,r.base=n(153),r.constants=n(375),r.decoders=n(764),r.encoders=n(766)},function(e,t,n){var r=n(5).Buffer;function i(e,t){this._block=r.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=r.from(e,t));for(var n=this._block,i=this._blockSize,o=e.length,s=this._len,a=0;a<o;){for(var l=s%i,u=Math.min(o-a,i-l),c=0;c<u;c++)n[l+c]=e[a+c];s+=u,a+=u,s%i==0&&this._update(n)}return this._len+=o,this},i.prototype.digest=function(e){var t=this._len%this._blockSize;this._block[t]=128,this._block.fill(0,t+1),t>=this._finalSize&&(this._update(this._block),this._block.fill(0));var n=8*this._len;if(n<=4294967295)this._block.writeUInt32BE(n,this._blockSize-4);else{var r=(4294967295&n)>>>0,i=(n-r)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(r,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},function(e,t,n){var r=n(404),i=n(405);function o(e,t,n){var o=t&&n||0;"string"==typeof e&&(t="binary"===e?new Array(16):null,e=null),e=e||{};var s=e.random||(e.rng||r)();if(s[6]=15&s[6]|64,s[8]=63&s[8]|128,t)for(var a=0;a<16;++a)t[o+a]=s[a];return t||i(s)}e.exports=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(430),i=a(r),o=n(109),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default,1),e.exports=t.default},function(e,t,n){"use strict";e.exports={Record:n(916),validator:n(919),selection:n(927)}},function(e,t,n){function r(e){if(e)return i(e)}function i(e){for(var t in r.prototype)e[t]=r.prototype[t];return e}e.exports=r,r.prototype.on=r.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},r.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this},r.prototype.off=r.prototype.removeListener=r.prototype.removeAllListeners=r.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var n=this._callbacks["$"+e],r;if(!n)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return this},r.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),n=this._callbacks["$"+e];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this},r.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},r.prototype.hasListeners=function(e){return!!this.listeners(e).length}},function(e,t,n){var r=n(953),i=n(449),o=n(955),s=n(956),a=n(957),l;"undefined"!=typeof ArrayBuffer&&(l=n(958));var u="undefined"!=typeof navigator&&/Android/i.test(navigator.userAgent),c="undefined"!=typeof navigator&&/PhantomJS/i.test(navigator.userAgent),h=u||c;t.protocol=3;var f=t.packets={open:0,close:1,ping:2,pong:3,message:4,upgrade:5,noop:6},p=r(f),d={type:"error",data:"parser error"},m=n(959);function g(e,n){var r="b"+t.packets[e.type]+e.data.data;return n(r)}function y(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var i=e.data,o=new Uint8Array(i),s=new Uint8Array(1+i.byteLength);s[0]=f[e.type];for(var a=0;a<o.length;a++)s[a+1]=o[a];return r(s.buffer)}function v(e,n,r){if(!n)return t.encodeBase64Packet(e,r);var i=new FileReader;return i.onload=function(){t.encodePacket({type:e.type,data:i.result},n,!0,r)},i.readAsArrayBuffer(e.data)}function b(e,n,r){if(!n)return t.encodeBase64Packet(e,r);if(h)return v(e,n,r);var i=new Uint8Array(1);i[0]=f[e.type];var o=new m([i.buffer,e.data]);return r(o)}function _(e){try{e=a.decode(e,{strict:!1})}catch(e){return!1}return e}function w(e,t,n){for(var r=new Array(e.length),i=s(e.length,n),o=function(e,n,i){t(n,function(t,n){r[e]=n,i(t,r)})},a=0;a<e.length;a++)o(a,e[a],i)}t.encodePacket=function(e,t,n,r){"function"==typeof t&&(r=t,t=!1),"function"==typeof n&&(r=n,n=null);var i=void 0===e.data?void 0:e.data.buffer||e.data;if("undefined"!=typeof ArrayBuffer&&i instanceof ArrayBuffer)return y(e,t,r);if(void 0!==m&&i instanceof m)return b(e,t,r);if(i&&i.base64)return g(e,r);var o=f[e.type];return void 0!==e.data&&(o+=n?a.encode(String(e.data),{strict:!1}):String(e.data)),r(""+o)},t.encodeBase64Packet=function(e,n){var r="b"+t.packets[e.type],i;if(void 0!==m&&e.data instanceof m){var o=new FileReader;return o.onload=function(){var e=o.result.split(",")[1];n(r+e)},o.readAsDataURL(e.data)}try{i=String.fromCharCode.apply(null,new Uint8Array(e.data))}catch(t){for(var s=new Uint8Array(e.data),a=new Array(s.length),l=0;l<s.length;l++)a[l]=s[l];i=String.fromCharCode.apply(null,a)}return r+=btoa(i),n(r)},t.decodePacket=function(e,n,r){if(void 0===e)return d;if("string"==typeof e){if("b"===e.charAt(0))return t.decodeBase64Packet(e.substr(1),n);if(r&&(e=_(e),!1===e))return d;var i=e.charAt(0);return Number(i)==i&&p[i]?e.length>1?{type:p[i],data:e.substring(1)}:{type:p[i]}:d}var s=new Uint8Array(e),i=s[0],a=o(e,1);return m&&"blob"===n&&(a=new m([a])),{type:p[i],data:a}},t.decodeBase64Packet=function(e,t){var n=p[e.charAt(0)];if(!l)return{type:n,data:{base64:!0,data:e.substr(1)}};var r=l.decode(e.substr(1));return"blob"===t&&m&&(r=new m([r])),{type:n,data:r}},t.encodePayload=function(e,n,r){"function"==typeof n&&(r=n,n=null);var o=i(e);if(n&&o)return m&&!h?t.encodePayloadAsBlob(e,r):t.encodePayloadAsArrayBuffer(e,r);if(!e.length)return r("0:");function s(e){return e.length+":"+e}function a(e,r){t.encodePacket(e,!!o&&n,!1,function(e){r(null,s(e))})}w(e,a,function(e,t){return r(t.join(""))})},t.decodePayload=function(e,n,r){if("string"!=typeof e)return t.decodePayloadAsBinary(e,n,r);var i;if("function"==typeof n&&(r=n,n=null),""===e)return r(d,0,1);for(var o="",s,a,l=0,u=e.length;l<u;l++){var c=e.charAt(l);if(":"===c){if(""===o||o!=(s=Number(o)))return r(d,0,1);if(a=e.substr(l+1,s),o!=a.length)return r(d,0,1);if(a.length){if(i=t.decodePacket(a,n,!1),d.type===i.type&&d.data===i.data)return r(d,0,1);var h=r(i,l+s,u);if(!1===h)return}l+=s,o=""}else o+=c}return""!==o?r(d,0,1):void 0},t.encodePayloadAsArrayBuffer=function(e,n){if(!e.length)return n(new ArrayBuffer(0));function r(e,n){t.encodePacket(e,!0,!0,function(e){return n(null,e)})}w(e,r,function(e,t){var r=t.reduce(function(e,t){var n;return n="string"==typeof t?t.length:t.byteLength,e+n.toString().length+n+2},0),i=new Uint8Array(r),o=0;return t.forEach(function(e){var t="string"==typeof e,n=e;if(t){for(var r=new Uint8Array(e.length),s=0;s<e.length;s++)r[s]=e.charCodeAt(s);n=r.buffer}i[o++]=t?0:1;for(var a=n.byteLength.toString(),s=0;s<a.length;s++)i[o++]=parseInt(a[s]);i[o++]=255;for(var r=new Uint8Array(n),s=0;s<r.length;s++)i[o++]=r[s]}),n(i.buffer)})},t.encodePayloadAsBlob=function(e,n){function r(e,n){t.encodePacket(e,!0,!0,function(e){var t=new Uint8Array(1);if(t[0]=1,"string"==typeof e){for(var r=new Uint8Array(e.length),i=0;i<e.length;i++)r[i]=e.charCodeAt(i);e=r.buffer,t[0]=0}for(var o=e instanceof ArrayBuffer?e.byteLength:e.size,s=o.toString(),a=new Uint8Array(s.length+1),i=0;i<s.length;i++)a[i]=parseInt(s[i]);if(a[s.length]=255,m){var l=new m([t.buffer,a.buffer,e]);n(null,l)}})}w(e,r,function(e,t){return n(new m(t))})},t.decodePayloadAsBinary=function(e,n,r){"function"==typeof n&&(r=n,n=null);for(var i=e,s=[];i.byteLength>0;){for(var a=new Uint8Array(i),l=0===a[0],u="",c=1;255!==a[c];c++){if(u.length>310)return r(d,0,1);u+=a[c]}i=o(i,2+u.length),u=parseInt(u);var h=o(i,0,u);if(l)try{h=String.fromCharCode.apply(null,new Uint8Array(h))}catch(e){var f=new Uint8Array(h);h="";for(var c=0;c<f.length;c++)h+=String.fromCharCode(f[c])}s.push(h),i=o(i,u)}var p=s.length;s.forEach(function(e,i){r(t.decodePacket(e,n,!0),i,p)})}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(456),a=n(459);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";const r=t.second=1e3,i=t.minute=60*r,o=t.hour=60*i;t.MAX_RECORD_AGE=36*o,t.PROTOCOL_DHT="/ipfs/kad/1.0.0",t.PROVIDERS_KEY_PREFIX="/providers/",t.PROVIDERS_LRU_CACHE_SIZE=256,t.PROVIDERS_VALIDITY=24*o,t.PROVIDERS_CLEANUP_INTERVAL=o,t.READ_MESSAGE_TIMEOUT=10*r,t.GET_MANY_RECORD_COUNT=16,t.K=20,t.ALPHA=3,t.maxMessageSize=2<<22,t.defaultRandomWalk={enabled:!0,queriesPerPeriod:1,interval:5*i,timeout:10*r,delay:10*r}},function(e,t,n){"use strict";var r=e.exports=function(e){return null!==e&&"object"==typeof e&&"function"==typeof e.pipe};r.writable=function(e){return r(e)&&!1!==e.writable&&"function"==typeof e._write&&"object"==typeof e._writableState},r.readable=function(e){return r(e)&&!1!==e.readable&&"function"==typeof e._read&&"object"==typeof e._readableState},r.duplex=function(e){return r.writable(e)&&r.readable(e)},r.transform=function(e){return r.duplex(e)&&"function"==typeof e._transform&&"object"==typeof e._transformState}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(497),a=n(500);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";const r=n(17).Transform;class i extends r{constructor(e){const t=Object.assign({},e||{},{objectMode:!0});super(t)}_transform(e,t,n){if(!e.Hash)return n();n(null,{path:e.Name,hash:e.Hash,size:parseInt(e.Size,10)})}}e.exports=i},function(e,t,n){(function(e){var r=n(1275),i=n(516),o=n(68),s=n(514),a=n(32),l=t;l.request=function(t,n){t="string"==typeof t?a.parse(t):o(t);var i=-1===e.location.protocol.search(/^https?:$/)?"http:":"",s=t.protocol||i,l=t.hostname||t.host,u=t.port,c=t.path||"/";l&&-1!==l.indexOf(":")&&(l="["+l+"]"),t.url=(l?s+"//"+l:"")+(u?":"+u:"")+c,t.method=(t.method||"GET").toUpperCase(),t.headers=t.headers||{};var h=new r(t);return n&&h.on("response",n),h},l.get=function e(t,n){var r=l.request(t,n);return r.end(),r},l.ClientRequest=r,l.IncomingMessage=i.IncomingMessage,l.Agent=function(){},l.Agent.defaultMaxSockets=4,l.globalAgent=new l.Agent,l.STATUS_CODES=s,l.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}).call(this,n(8))},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(518),a=n(521);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(524),a=n(527);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";const r=n(299);e.exports=((e,t)=>{const n=r(e,t);return(e,t,r)=>{n(e,t,(e,t)=>{if(e)return r(e);r(null,t[0])})}})},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(554),a=n(557);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(559),a=n(562);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(565),a=n(568);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(571),a=n(574);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(576),a=n(579);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(582),a=n(585);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(591),a=n(594);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";var r=n(11),i=Object.keys||function(e){var t=[];for(var n in e)t.push(n);return t};e.exports=h;var o=n(7);o.inherits=n(1);var s=n(599),a=n(602);o.inherits(h,s);for(var l=i(a.prototype),u=0;u<l.length;u++){var c=l[u];h.prototype[c]||(h.prototype[c]=a.prototype[c])}function h(e){if(!(this instanceof h))return new h(e);s.call(this,e),a.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",f)}function f(){this.allowHalfOpen||this._writableState.ended||r.nextTick(p,this)}function p(e){e.end()}Object.defineProperty(h.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(h.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed&&this._writableState.destroyed)},set:function(e){void 0!==this._readableState&&void 0!==this._writableState&&(this._readableState.destroyed=e,this._writableState.destroyed=e)}}),h.prototype._destroy=function(e,t){this.push(null),this.end(),r.nextTick(t,e)}},function(e,t,n){"use strict";function r(e,t){for(var n in t=t||{},e)t[n]=e[n];return t}function i(e,t,n){var r=n?" !== ":" === ",i=n?" || ":" && ",o=n?"!":"",s=n?"":"!";switch(e){case"null":return t+r+"null";case"array":return o+"Array.isArray("+t+")";case"object":return"("+o+t+i+"typeof "+t+r+'"object"'+i+s+"Array.isArray("+t+"))";case"integer":return"(typeof "+t+r+'"number"'+i+s+"("+t+" % 1)"+i+t+r+t+")";default:return"typeof "+t+r+'"'+e+'"'}}function o(e,t){switch(e.length){case 1:return i(e[0],t,!0);default:var n="",r=l(e);for(var o in r.array&&r.object&&(n=r.null?"(":"(!"+t+" || ",n+="typeof "+t+' !== "object")',delete r.null,delete r.array,delete r.object),r.number&&delete r.integer,r)n+=(n?" && ":"")+i(o,t,!0);return n}}e.exports={copy:r,checkDataType:i,checkDataTypes:o,coerceToTypes:a,toHash:l,getProperty:h,escapeQuotes:f,equal:n(322),ucs2length:n(1681),varOccurences:p,varReplace:d,cleanUpCode:v,finalCleanUpCode:T,schemaHasRules:I,schemaHasRulesExcept:j,schemaUnknownRules:R,toQuotedString:B,getPathExpr:O,getPath:P,getData:M,unescapeFragment:L,unescapeJsonPointer:z,escapeFragment:U,escapeJsonPointer:q};var s=l(["string","number","integer","boolean","null"]);function a(e,t){if(Array.isArray(t)){for(var n=[],r=0;r<t.length;r++){var i=t[r];s[i]?n[n.length]=i:"array"===e&&"array"===i&&(n[n.length]=i)}if(n.length)return n}else{if(s[t])return[t];if("array"===e&&"array"===t)return["array"]}}function l(e){for(var t={},n=0;n<e.length;n++)t[e[n]]=!0;return t}var u=/^[a-z$_][a-z$_0-9]*$/i,c=/'|\\/g;function h(e){return"number"==typeof e?"["+e+"]":u.test(e)?"."+e:"['"+f(e)+"']"}function f(e){return e.replace(c,"\\$&").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\f/g,"\\f").replace(/\t/g,"\\t")}function p(e,t){t+="[^0-9]";var n=e.match(new RegExp(t,"g"));return n?n.length:0}function d(e,t,n){return t+="([^0-9])",n=n.replace(/\$/g,"$$$$"),e.replace(new RegExp(t,"g"),n+"$1")}var m=/else\s*{\s*}/g,g=/if\s*\([^)]+\)\s*\{\s*\}(?!\s*else)/g,y=/if\s*\(([^)]+)\)\s*\{\s*\}\s*else(?!\s*if)/g;function v(e){return e.replace(m,"").replace(g,"").replace(y,"if (!($1))")}var b=/[^v.]errors/g,_=/var errors = 0;|var vErrors = null;|validate.errors = vErrors;/g,w=/var errors = 0;|var vErrors = null;/g,k="return errors === 0;",E="validate.errors = null; return true;",S=/if \(errors === 0\) return data;\s*else throw new ValidationError\(vErrors\);/,x="return data;",C=/[^A-Za-z_$]rootData[^A-Za-z0-9_$]/g,A=/if \(rootData === undefined\) rootData = data;/;function T(e,t){var n=e.match(b);return n&&2==n.length&&(e=t?e.replace(w,"").replace(S,x):e.replace(_,"").replace(k,E)),n=e.match(C),n&&3===n.length?e.replace(A,""):e}function I(e,t){if("boolean"==typeof e)return!e;for(var n in e)if(t[n])return!0}function j(e,t,n){if("boolean"==typeof e)return!e&&"not"!=n;for(var r in e)if(r!=n&&t[r])return!0}function R(e,t){if("boolean"!=typeof e)for(var n in e)if(!t[n])return n}function B(e){return"'"+f(e)+"'"}function O(e,t,n,r){var i=n?"'/' + "+t+(r?"":".replace(/~/g, '~0').replace(/\\//g, '~1')"):r?"'[' + "+t+" + ']'":"'[\\'' + "+t+" + '\\']'";return F(e,i)}function P(e,t,n){var r=B(n?"/"+q(t):h(t));return F(e,r)}var N=/^\/(?:[^~]|~0|~1)*$/,D=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function M(e,t,n){var r,i,o,s;if(""===e)return"rootData";if("/"==e[0]){if(!N.test(e))throw new Error("Invalid JSON-pointer: "+e);i=e,o="rootData"}else{if(s=e.match(D),!s)throw new Error("Invalid JSON-pointer: "+e);if(r=+s[1],i=s[2],"#"==i){if(r>=t)throw new Error("Cannot access property/index "+r+" levels up, current level is "+t);return n[t-r]}if(r>t)throw new Error("Cannot access data "+r+" levels up, current level is "+t);if(o="data"+(t-r||""),!i)return o}for(var a=o,l=i.split("/"),u=0;u<l.length;u++){var c=l[u];c&&(o+=h(z(c)),a+=" && "+o)}return a}function F(e,t){return'""'==e?t:(e+" + "+t).replace(/' \+ '/g,"")}function L(e){return z(decodeURIComponent(e))}function U(e){return encodeURIComponent(q(e))}function q(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}function z(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}},function(e,t,n){(function(e,t){!function(){var r;"undefined"!=typeof window&&(r=window),void 0!==e&&(r=e),r=r||{};var i=r.console||{log:function(){}};function o(e,t){return t?n(1784)(e):e.slice?o[r(e)]:function(t,n){e(t={exports:{}}),o[r(n)]=t.exports};function r(e){return e.split("/").slice(-1).toString().replace(".js","")}}var s=t;o(function(e){var t={fn:{is:function(e){return!!e&&"function"==typeof e}}};t.bi={is:function(e){return e instanceof Boolean||"boolean"==typeof e}},t.num={is:function(e){return!r(e)&&(e-parseFloat(e)+1>=0||1/0===e||-1/0===e)}},t.text={is:function(e){return"string"==typeof e}},t.text.ify=function(e){return t.text.is(e)?e:"undefined"!=typeof JSON?JSON.stringify(e):e&&e.toString?e.toString():e},t.text.random=function(e,t){var n="";for(e=e||24,t=t||"0123456789ABCDEFGHIJKLMNOPQRSTUVWXZabcdefghijklmnopqrstuvwxyz";e>0;)n+=t.charAt(Math.floor(Math.random()*t.length)),e--;return n},t.text.match=function(e,t){var n,r;return"string"==typeof e&&("string"==typeof t&&(t={"=":t}),t=t||{},n=t["="]||t["*"]||t[">"]||t["<"],e===n||r===t["="]&&(n=t["*"]||t[">"]||t["<"],e.slice(0,(n||"").length)===n||r===t["*"]&&(r!==t[">"]&&r!==t["<"]?e>=t[">"]&&e<=t["<"]:r!==t[">"]&&e>=t[">"]||r!==t["<"]&&e<=t["<"])))},t.list={is:function(e){return e instanceof Array}},t.list.slit=Array.prototype.slice,t.list.sort=function(e){return function(t,n){return t&&n?(t=t[e],n=n[e],t<n?-1:t>n?1:0):0}},t.list.map=function(e,t,n){return a(e,t,n)},t.list.index=1,t.obj={is:function(e){return!!e&&(e instanceof Object&&e.constructor===Object||"Object"===Object.prototype.toString.call(e).match(/^\[object (\w+)\]$/)[1])}},t.obj.put=function(e,t,n){return(e||{})[t]=n,e},t.obj.has=function(e,t){return e&&Object.prototype.hasOwnProperty.call(e,t)},t.obj.del=function(e,t){if(e)return e[t]=null,delete e[t],e},t.obj.as=function(e,t,n,r){return e[t]=e[t]||(r===n?{}:n)},t.obj.ify=function(e){if(o(e))return e;try{e=JSON.parse(e)}catch(t){e={}}return e},function(){var e;function n(t,n){s(this,n)&&e!==this[n]||(this[n]=t)}t.obj.to=function(e,t){return t=t||{},a(e,n,t),t}}(),t.obj.copy=function(e){return e?JSON.parse(JSON.stringify(e)):e},function(){function e(e,t){var n=this.n;if(!n||!(t===n||o(n)&&s(n,t)))return!!t||void 0}t.obj.empty=function(t,n){return!t||!a(t,e,{n:n})}}(),function(){function e(t,n){if(2===arguments.length)return e.r=e.r||{},void(e.r[t]=n);e.r=e.r||[],e.r.push(t)}var i=Object.keys;t.obj.map=function(a,l,u){var c,h=0,f,p,d,m,g=n(l);if(e.r=null,i&&o(a)&&(d=i(a),m=!0),r(a)||d)for(f=(d||a).length;h<f;h++){var y=h+t.list.index;if(g){if(p=m?l.call(u||this,a[d[h]],d[h],e):l.call(u||this,a[h],y,e),p!==c)return p}else if(l===a[m?d[h]:h])return d?d[h]:y}else for(h in a)if(g){if(s(a,h)&&(p=u?l.call(u,a[h],h,e):l(a[h],h,e),p!==c))return p}else if(l===a[h])return h;return g?e.r:t.list.index?0:-1}}(),t.time={},t.time.is=function(e){return e?e instanceof Date:+(new Date).getTime()};var n=t.fn.is,r=t.list.is,i=t.obj,o=i.is,s=i.has,a=i.map;e.exports=t})(o,"./type"),o(function(e){e.exports=function e(t,n,r){if(!t)return{to:e};var i,t=(this.tag||(this.tag={}))[t]||(this.tag[t]={tag:t,to:e._={next:function(e){var t;(t=this.to)&&t.next(e)}}});if(n instanceof Function){var o={off:e.off||(e.off=function(){if(this.next===e._.next)return!0;this===this.the.last&&(this.the.last=this.back),this.to.back=this.back,this.next=e._.next,this.back.to=this.to,this.the.last===this.the&&delete this.on.tag[this.the.tag]}),to:e._,next:n,the:t,on:this,as:r};return(o.back=t.last||t).to=o,t.last=o}return(t=t.to)&&i!==n&&t.next(n),t}})(o,"./onto"),o(function(e){function t(e,t,r,i,o){if(e<t)return{defer:!0};if(t<r)return{historical:!0};if(r<t)return{converge:!0,incoming:!0};if(t===r){if(i=n(i)||"",o=n(o)||"",i===o)return{state:!0};if(i<o)return{converge:!0,current:!0};if(o<i)return{converge:!0,incoming:!0}}return{err:"Invalid CRDT Data: "+i+" to "+o+" at "+t+" to "+r+"!"}}if("undefined"==typeof JSON)throw new Error("JSON is not included in this browser. Please load it first: ajax.cdnjs.com/ajax/libs/json2/20110223/json2.js");var n=JSON.stringify,r;e.exports=t})(o,"./HAM"),o(function(e){var t=o("./type"),n={is:function(e){return e!==i&&(null===e||e!==1/0&&(!!(l(e)||s(e)||a(e))||(n.link.is(e)||!1)))}};n.link=n.rel={_:"#"},function(){function e(e,t){var n=this;return n.id?n.id=!1:t==r&&l(e)?void(n.id=e):n.id=!1}n.link.is=function(t){if(t&&t[r]&&!t._&&c(t)){var n={};if(f(t,e,n),n.id)return n.id}return!1}}(),n.link.ify=function(e){return h({},r,e)},t.obj.has._=".";var r=n.link._,i,s=t.bi.is,a=t.num.is,l=t.text.is,u=t.obj,c=u.is,h=u.put,f=u.map;e.exports=n})(o,"./val"),o(function(e){var t=o("./type"),n=o("./val"),r={_:"_",soul:function(e,t){return e&&e._&&e._[t||h]}};r.soul.ify=function(e,t){return t="string"==typeof t?{soul:t}:t||{},e=e||{},e._=e._||{},e._[h]=t.soul||e._[h]||c(),e},r.soul._=n.link._,function(){function e(e,t){if(t!==r._)return!n.is(e)||void(this.cb&&this.cb.call(this.as,e,t,this.n,this.s))}r.is=function(t,n,i){var o;return!!s(t)&&(!!(o=r.soul(t))&&!l(t,e,{as:i,cb:n,s:o,n:t}))}}(),function(){function e(e,t){var r=this.o,i,o;if(r.map)return i=r.map.call(this.as,e,""+t,r.node),void(o===i?a(r.node,t):r.node&&(r.node[t]=i));n.is(e)&&(r.node[t]=e)}r.ify=function(t,n,i){return n?"string"==typeof n?n={soul:n}:n instanceof Function&&(n={map:n}):n={},n.map&&(n.node=n.map.call(i,t,f,n.node||{})),(n.node=r.soul.ify(n.node||{},n))&&l(t,e,{o:n,as:i}),n.node}}();var i=t.obj,s=i.is,a=i.del,l=i.map,u=t.text,c=u.random,h=r.soul._,f;e.exports=r})(o,"./node"),o(function(e){var t=o("./type"),n=o("./node");function r(){var e;return e=i(),s<e?(a=0,s=e+r.drift):s=e+(a+=1)/l+r.drift}var i=t.time.is,s=-1/0,a=0,l=1e3,u="undefined"!=typeof performance&&(performance.timing&&performance),c=u&&u.timing&&u.timing.navigationStart||(u=!1);r._=">",r.drift=0,r.is=function(e,t,n){var i=t&&e&&e[w]&&e[w][r._]||n;if(i)return v(i=i[t])?i:-1/0},r.lex=function(){return r().toString(36).replace(".","")},r.ify=function(e,t,i,o,s){if(!e||!e[w]){if(!s)return;e=n.soul.ify(e,s)}var a=f(e[w],r._);return k!==t&&t!==w&&(v(i)&&(a[t]=i),k!==o&&(e[t]=o)),e},r.to=function(e,t,i){var o=(e||{})[t];return d(o)&&(o=g(o)),r.ify(i,t,r.is(e,t),o,n.soul(e))},function(){function e(e,t){w!==t&&r.ify(this.o,t,this.s)}r.map=function(t,n,i){var o,s=d(s=t||n)?s:null;return t=_(t=t||n)?t:null,s&&!t?(n=v(n)?n:r(),s[w]=s[w]||{},m(s,e,{o:s,s:n}),s):(i=i||d(n)?n:o,n=v(n)?n:r(),function(r,s,a,l){if(!t)return e.call({o:a,s:n},r,s),r;t.call(i||this||{},r,s,a,l),p(a,s)&&o===a[s]||e.call({o:a,s:n},r,s)})}}();var h=t.obj,f=h.as,p=h.has,d=h.is,m=h.map,g=h.copy,y=t.num,v=y.is,b=t.fn,_=b.is,w=n._,k;e.exports=r})(o,"./state"),o(function(e){var t=o("./type"),n=o("./val"),r=o("./node"),i={};!function(){function e(e,n){if(!e||n!==r.soul(e)||!r.is(e,this.fn,this.as))return!0;this.cb&&(t.n=e,t.as=this.as,this.cb.call(t.as,e,n,t))}function t(e){e&&r.is(t.n,e,t.as)}i.is=function(t,n,r,i){return!(!t||!l(t)||h(t))&&!p(t,e,{cb:n,fn:r,as:i})}}(),function(){function e(e,t){var i;return(i=h(e,t))?i:(t.env=e,t.soul=s,r.ify(t.obj,o,t)&&(t.link=t.link||n.link.ify(r.soul(t.node)),t.obj!==e.shell&&(e.graph[n.link.is(t.link)]=t.node)),t)}function o(t,i,o){var s=this,l=s.env,h,f;if(r._===i&&c(t,n.link._))return o._;if(h=a(t,i,o,s,l)){if(i||(s.node=s.node||o||{},c(t,r._)&&r.soul(t)&&(s.node._=d(t._)),s.node=r.soul.ify(s.node,n.link.is(s.link)),s.link=s.link||n.link.ify(r.soul(s.node))),(f=l.map)&&(f.call(l.as||{},t,i,o,s),c(o,i))){if(t=o[i],m===t)return void u(o,i);if(!(h=a(t,i,o,s,l)))return}if(!i)return s.node;if(!0===h)return t;if(f=e(l,{obj:t,path:s.path.concat(i)}),f.node)return f.link}}function s(e){var t=this,i=n.link.is(t.link),o=t.env.graph;t.link=t.link||n.link.ify(e),t.link[n.link._]=e,t.node&&t.node[r._]&&(t.node[r._][n.link._]=e),c(o,i)&&(o[e]=o[i],u(o,i))}function a(e,r,i,o,s){var u;return!!n.is(e)||(l(e)?1:(u=s.invalid)?(e=u.call(s.as||{},e,r,i),a(e,r,i,o,s)):(s.err="Invalid value at '"+o.path.concat(r).join(".")+"'!",void(t.list.is(e)&&(s.err+=" Use `.set(item)` instead of an Array."))))}function h(e,t){for(var n=e.seen,r=n.length,i;r--;)if(i=n[r],t.obj===i.obj)return i;n.push(t)}i.ify=function(t,r,i){var o={path:[],obj:t};return r?"string"==typeof r?r={soul:r}:r instanceof Function&&(r.map=r):r={},r.soul&&(o.link=n.link.ify(r.soul)),r.shell=(i||{}).shell,r.graph=r.graph||{},r.seen=r.seen||[],r.as=r.as||i,e(r,o),r.root=o.node,r.graph}}(),i.node=function(e){var t=r.soul(e);if(t)return f({},t,e)},function(){function e(e,t){var o,s;if(r._!==t)(o=n.link.is(e))?(s=this.opt.seen[o])?this.obj[t]=s:this.obj[t]=this.opt.seen[o]=i.to(this.graph,o,this.opt):this.obj[t]=e;else{if(h(e,n.link._))return;this.obj[t]=d(e)}}i.to=function(t,n,r){if(t){var i={};return r=r||{seen:{}},p(t[n],e,{obj:i,graph:t,opt:r}),i}}}();var s=t.fn.is,a=t.obj,l=a.is,u=a.del,c=a.has,h=a.empty,f=a.put,p=a.map,d=a.copy,m;e.exports=i})(o,"./graph"),o(function(e){o("./onto"),e.exports=function e(t,n){if(this.on){if(!(t instanceof Function)){if(!t||!n)return;var r=t["#"]||t,i=(this.tag||empty)[r];if(!i)return;return i=this.on(r,n),clearTimeout(i.err),!0}var r=n&&n["#"]||Math.random().toString(36).slice(2);if(!t)return r;var o=this.on(r,t,n);return o.err=o.err||setTimeout(function(){o.next({err:"Error: No ACK received yet.",lack:!0}),o.off()},(this.opt||{}).lack||9e3),r}}})(o,"./ask"),o(function(e){var t=o("./type");function n(e){var n={s:{}};return e=e||{max:1e3,age:9e3},n.check=function(e){var t;return!!(t=n.s[e])&&(t.pass?t.pass=!1:n.track(e))},n.track=function(i,o){var s=n.s[i]||(n.s[i]={});return s.was=r(),o&&(s.pass=!0),n.to||(n.to=setTimeout(function(){var i=r();t.obj.map(n.s,function(r,o){r&&e.age>i-r.was||t.obj.del(n.s,o)}),n.to=null},e.age+9)),s},n}var r=t.time.is;e.exports=n})(o,"./dup"),o(function(e){function t(e){return e instanceof t?(this._={gun:this,$:this}).$:this instanceof t?t.create(this._={gun:this,$:this,opt:e}):new t(e)}t.is=function(e){return e instanceof t||e&&e._&&e===e._.$||!1},t.version=.9,t.chain=t.prototype,t.chain.toJSON=function(){};var n=o("./type");n.obj.to(n,t),t.HAM=o("./HAM"),t.val=o("./val"),t.node=o("./node"),t.state=o("./state"),t.graph=o("./graph"),t.on=o("./onto"),t.ask=o("./ask"),t.dup=o("./dup"),function(){function e(n){var r=this,i=r.as,o=i.at||i,s=o.$,a,l;(l=n["#"])||(l=n["#"]=u(9)),(a=o.dup).check(l)?i.out===n.out&&(n.out=k,r.to.next(n)):(a.track(l),o.ask(n["@"],n)||(n.get&&t.on.get(n,s),n.put&&t.on.put(n,s)),r.to.next(n),i.out||(n.out=e,o.on("out",n)))}t.create=function(n){n.root=n.root||n,n.graph=n.graph||{},n.on=n.on||t.on,n.ask=n.ask||t.ask,n.dup=n.dup||t.dup();var r=n.$.opt(n.opt);return n.once||(n.on("in",e,n),n.on("out",e,{at:n,out:e}),t.on("create",n),n.on("create",n)),n.once=1,r}}(),function(){function e(e,n,r,i){var o=this,s=t.state.is(r,n),a;if(!s)return o.err="Error: No state on '"+n+"' in node '"+i+"'!";var l=o.graph[i]||w,u=t.state.is(l,n,!0),c=l[n],h=t.HAM(o.machine,s,u,e,c);h.incoming?(o.put[i]=t.state.to(r,n,o.put[i]),(o.diff||(o.diff={}))[i]=t.state.to(r,n,o.diff[i]),o.souls[i]=!0):h.defer&&(o.defer=s<(o.defer||1/0)?s:o.defer)}function n(e,t){var n=this,s=n.$._,a=(s.next||w)[t];if(!a){if(!(s.opt||w).super)return void(n.souls[t]=!1);a=n.$.get(t)._}var l=n.map[t]={put:e,get:t,$:a.$},u={ctx:n,msg:l};n.async=!!s.tag.node,n.ack&&(l["@"]=n.ack),d(e,r,u),n.async&&(n.and||s.on("node",function(e){this.to.next(e),e===n.map[e.get]&&(n.souls[e.get]=!1,d(e.put,i,e),d(n.souls,function(e){if(e)return e})||n.c||(n.c=1,this.off(),d(n.map,o,n)))}),n.and=!0,s.on("node",l))}function r(e,n){var r=this.ctx,i=r.graph,o=this.msg,s=o.get,a=o.put,l=o.$._,u;i[s]=t.state.to(a,n,i[s]),r.async||(l.put=t.state.to(a,n,l.put))}function i(e,n){var r=this,i=r.put,o=r.$._;o.put=t.state.to(i,n,o.put)}function o(e,t){e.$&&(this.cat.stop=this.stop,e.$._.on("in",e),this.cat.stop=null)}t.on.put=function(r,i){var s=i._,a={$:i,graph:s.graph,put:{},map:{},souls:{},machine:t.state(),ack:r["@"],cat:s,stop:{}};if(t.graph.is(r.put,null,e,a)||(a.err="Error: Invalid graph!"),a.err)return s.on("in",{"@":r["#"],err:t.log(a.err)});d(a.put,n,a),a.async||d(a.map,o,a),k!==a.defer&&setTimeout(function(){t.on.put(r,i)},a.defer-a.machine),a.diff&&s.on("put",p(r,{put:a.diff}))},t.on.get=function(e,n){var r=n._,i=e.get,o=i[y],s=r.graph[o],a=i[v],l,u=r.next||(r.next={}),c=u[o];if(!s)return r.on("get",e);if(a){if("string"!=typeof a||!f(s,a))return r.on("get",e);s=t.state.to(s,a)}else s=t.obj.copy(s);s=t.graph.node(s),l=(c||w).ack,r.on("in",{"@":e["#"],how:"mem",put:s,$:n}),r.on("get",e)}}(),t.chain.opt=function(e){e=e||{};var n=this,i=n._,o=e.peers||e;return h(e)||(e={}),h(i.opt)||(i.opt=e),l(o)&&(o=[o]),r(o)&&(o=d(o,function(e,t,n){t={},t.id=t.url=e,n(e,t)}),h(i.opt.peers)||(i.opt.peers={}),i.opt.peers=p(o,i.opt.peers)),i.opt.peers=i.opt.peers||{},p(e,i.opt),t.on("opt",i),i.opt.uuid=i.opt.uuid||function(){return g()+u(12)},n};var r=t.list.is,a=t.text,l=a.is,u=a.random,c=t.obj,h=c.is,f=c.has,p=c.to,d=c.map,m=c.copy,g=t.state.lex,y=t.val.link._,v=".",b=t.node._,_=t.val.link.is,w={},k;i.debug=function(e,t){return i.debug.i&&e===i.debug.i&&i.debug.i++&&(i.log.apply(i,arguments)||t)},t.log=function(){return!t.log.off&&i.log.apply(i,arguments),[].slice.call(arguments).join(" ")},t.log.once=function(e,n,r){return(r=t.log.once)[e]=r[e]||0,r[e]++||t.log(n)},t.log.once("welcome","Hello wonderful person! :) Thanks for using GUN, feel free to ask for help on https://gitter.im/amark/gun and ask StackOverflow questions tagged with 'gun'!"),"undefined"!=typeof window&&((window.GUN=window.Gun=t).window=window);try{void 0!==s&&(s.exports=t)}catch(e){}e.exports=t})(o,"./root"),o(function(e){var t=o("./root");t.chain.back=function(e,i){var o;if(e=e||1,-1===e||1/0===e)return this._.root.$;if(1===e)return(this._.back||this._).$;var s=this,a=s._;if("string"==typeof e&&(e=e.split(".")),e instanceof Array){for(var l=0,u=e.length,o=a;l<u;l++)o=(o||n)[e[l]];return r!==o?i?s:o:(o=a.back)?o.$.back(e,i):void 0}if(e instanceof Function){for(var c,o={back:a};(o=o.back)&&r===(c=e(o,i)););return c}return t.num.is(e)?(a.back||a).$.back(e-1):this};var n={},r})(o,"./back"),o(function(e){var t=o("./root");function n(e){var n,r,i=this.as,o=i.back,s=i.root,a;if(e.$||(e.$=i.$),this.to.next(e),r=e.get){if(i.lex&&(e.get=v(i.lex,e.get)),r["#"]||i.soul){if(r["#"]=r["#"]||i.soul,e["#"]||(e["#"]=_(9)),o=s.$.get(r["#"])._,r=r["."]){if(m(o.put,r)){if(n=o.$.get(r)._,(a=n.ack)||(n.ack=-1),o.on("in",{$:o.$,put:t.state.to(o.put,r),get:o.get}),a)return}else if("string"!=typeof r){var n={},l=(o.put||{})._;t.obj.map(o.put,function(e,i){t.text.match(i,r)&&(n[i]=e)}),t.obj.empty(n)||(n._=l,o.on("in",{$:o.$,put:n,get:o.get}))}}else{if(a=o.ack,a||(o.ack=-1),m(o,"put")&&o.on("in",o),a)return;e.$=o.$}return s.ask(h,e),s.on("in",e)}if(s.now&&(s.now[i.id]=s.now[i.id]||!0,i.pass={}),r["."])return i.get?(e={get:{".":i.get},$:i.$},o.ask||(o.ask={}),o.ask[i.get]=e.$._,o.on("out",e)):(e={get:{},$:i.$},o.on("out",e));if(i.ack=i.ack||-1,i.get)return e.$=i.$,r["."]=i.get,(o.ask||(o.ask={}))[i.get]=e.$._,o.on("out",e)}return o.on("out",e)}function r(e){var n=this,r=n.as,o=r.root,a=e.$,c=(a||f)._||f,h=e.put,d,g;if(r.get&&e.get!==r.get&&(e=v(e,{get:r.get})),r.has&&c!==r&&(e=v(e,{$:r.$}),c.ack&&(r.ack=c.ack)),p===h){if(g=c.put,n.to.next(e),r.soul)return;if(p===g&&p!==c.put)return;return s(r,e,n),r.has&&u(r,e),y(c.echo,r.id),void y(r.map,c.id)}if(r.soul)return n.to.next(e),s(r,e,n),void(r.next&&b(h,l,{msg:e,cat:r}));if(!(d=t.val.link.is(h)))return t.val.is(h)?(r.has||r.soul?u(r,e):(c.has||c.soul)&&((c.echo||(c.echo={}))[r.id]=c.echo[c.id]||r,(r.map||(r.map={}))[c.id]=r.map[c.id]||{at:c}),n.to.next(e),void s(r,e,n)):(r.has&&c!==r&&m(c,"put")&&(r.put=c.put),(d=t.node.soul(h))&&c.has&&(c.put=r.root.$.get(d)._.put),g=(o.stop||{})[c.id],n.to.next(e),i(r,e,c,d),s(r,e,n),void(r.next&&b(h,l,{msg:e,cat:r})));var _=o.stop;g=o.stop||{},g=g[c.id]||(g[c.id]={}),g.is=g.is||c.put,g[r.id]=c.put||!0,n.to.next(e),i(r,e,c,d),s(r,e,n)}function i(e,n,r,o){if(o&&k!==e.get){var s=e.root.$.get(o)._;e.has?r=s:r.has&&i(r,n,r,o),r!==e&&(r.$||(r={}),(r.echo||(r.echo={}))[e.id]=r.echo[e.id]||e,e.has&&!(e.map||f)[r.id]&&u(e,n),s=r.id?(e.map||(e.map={}))[r.id]=e.map[r.id]||{at:r}:{},(o!==s.link||s.pass||e.pass)&&(e.pass&&(t.obj.map(e.map,function(e){e.pass=!0}),y(e,"pass")),s.pass&&y(s,"pass"),e.has&&(e.link=o),c(e,s.link=o)))}}function s(e,t,n){e.echo&&b(e.echo,a,t)}function a(e){e&&e.on&&e.on("in",this)}function l(e,n){var r=this.cat,i=r.next||f,o=this.msg,s,a,l;(k!==n||i[n])&&(a=i[n])&&(a.has?(p!==a.put&&t.val.link.is(e)||(a.put=e),s=a.$):(l=o.$)&&(l=(s=o.$.get(n))._,p!==l.put&&t.val.link.is(e)||(l.put=e)),a.on("in",{put:e,get:n,$:s,via:o}))}function u(e,n){if(e.has||e.soul){var r=e.map,i=e.root;e.map=null,e.has&&(e.dub&&e.root.stop&&(e.dub=null),e.link=null),(e.pass||n["@"]||null!==r)&&(p===r&&t.val.link.is(e.put)||(b(r,function(t){(t=t.at)&&y(t.echo,e.id)}),r=e.put,b(e.next,function(t,n){if(p===r&&p!==e.put)return!0;t.put=p,t.ack&&(t.ack=-1),t.on("in",{get:n,$:t.$,put:p})})))}}function c(e,n){var r=e.root.$.get(n)._,i=e.lex;(!e.ack&&!i||((i=i||{})["#"]=n,r.on("out",{get:i}),e.ask))&&(r=e.ask,t.obj.del(e,"ask"),b(r||e.next,function(e,t){var r=e.lex||{};r["#"]=n,r["."]=r["."]||t,e.on("out",{get:r})}),t.obj.del(e,"ask"))}function h(e,n){var r=this.as,i=r.get||f,o=r.$._,s=(e.put||f)[i["#"]];if(o.ack&&(o.ack=o.ack+1||1),e.put&&("string"!=typeof i["."]||m(s,o.get)))k!=i["."]?t.on.put(e,o.root.$):o.on("in",{get:o.get,put:t.val.link.ify(i["#"]),$:o.$,"@":e["@"]});else{if(o.put!==p)return;o.on("in",{get:o.get,put:o.put=p,$:o.$,"@":e["@"]})}}t.chain.chain=function(e){var i=this,o=i._,s=new(e||i).constructor(i),a=s._,l;return a.root=l=o.root,a.id=++l.once,a.back=i._,a.on=t.on,a.on("in",r,a),a.on("out",n,a),s};var f={},p,d=t.obj,m=d.has,g=d.put,y=d.del,v=d.to,b=d.map,_=t.text.random,w=t.val.link._,k=t.node._})(o,"./chain"),o(function(e){var t=o("./root");function n(e,t){var n=t._,r=n.next,i=t.chain(),o=i._;return r||(r=n.next={}),r[o.get=e]=o,t===n.root.$?o.soul=e:(n.soul||n.has)&&(o.has=e),o}function r(e,t,n,r){var i=e._,o=0,s;return(s=i.soul||i.link||i.dub)?(t(s,r,i),e):(e.get(function(e,n){if(!(g===e.put&&(s=(l(i.root.opt.peers,function(e,t,n){n(t)})||[]).length)&&++o<s)){n.rid(e);var a=(a=e.$)&&a._||{};s=a.link||a.soul||f.is(e.put)||p(e.put)||a.dub,t(s,r,e,n)}},{out:{get:{".":!0}}}),e)}function i(e){var n=this,r=n.as,i=r.at,o=i.root,s=e.$,a=(s||{})._||{},l=e.put||a.put,u;if((u=o.now)&&n!==u[r.now])return n.to.next(e);if(n.seen&&a.id&&n.seen[a.id])return n.to.next(e);if((u=l)&&u[f._]&&(u=f.is(u))&&(u=(e.$$=a.root.gun.get(u))._,g!==u.put&&(e=c(e,{put:l=u.put}))),(u=o.mum)&&a.id){var h=a.id+(n.id||(n.id=t.text.random(9)));if(u[h])return;g===l||f.is(l)||(u[h]=!0)}r.use(e,n),n.stun?n.stun=null:n.to.next(e)}function s(e){var t=this.on;if(!e||t.soul||t.has)return this.off();if(e=(e=(e=e.$||e)._||e).id){var n=t.map,r,i;if(r=(i=this.seen||(this.seen={}))[e])return!0;i[e]=!0}}t.chain.get=function(e,o,l){var u,c;if("string"!=typeof e){if(e instanceof Function){if(!0===o)return r(this,e,o,l);u=this;var p=u._,d=p.root,c=d.now,g;l=o||{},l.at=p,l.use=e,l.out=l.out||{},l.out.get=l.out.get||{},(g=p.on("in",i,l)).rid=s,(d.now={$:1})[l.now=p.id]=g;var y=d.mum;return d.mum={},p.on("out",l.out),d.mum=y,d.now=c,u}return h(e)?this.get(""+e,o,l):(c=f.is(e))?this.get(c,o,l):a.is(e)?(u=this,(c=((c=e["#"])||m)["="]||c)&&(u=u.get(c)),u._.lex=e,u):((l=this.chain())._.err={err:t.log("Invalid get request!",e)},o&&o.call(l,l._.err),l)}var v=this,b=this._,_=b.next||m;return(u=_[e])||(u=n(e,this)),u=u.$,(c=this._.stun)&&(u._.stun=u._.stun||c),o&&o instanceof Function&&u.get(o,l),u};var a=t.obj,l=a.map,u=a.has,c=t.obj.to,h=t.num.is,f=t.val.link,p=t.node.soul,d=t.node._,m={},g})(o,"./get"),o(function(e){var t=o("./root");function n(e){e.batch=s;var n=e.opt||{},r=e.env=t.state.map(l,n.state);if(r.soul=e.soul,e.graph=t.graph.ify(e.data,r,e),r.err)return(e.ack||v).call(e,e.out={err:t.log(r.err)}),void(e.res&&e.res());e.batch()}function r(e){var t;e&&e()}function s(){var e=this;e.graph&&!m(e.stun,a)&&(e.res=e.res||function(e){e&&e()},e.res(function(){var n=e.$.back(-1)._,r=n.ask(function(r){n.root.on("ack",r),r.err&&t.log(r),++i>(e.acks||0)&&this.off(),e.ack&&e.ack(r,this)},e.opt),i=0,o=n.root.now;f.del(n.root,"now");var s=n.root.mum;n.root.mum={},e.ref._.on("out",{$:e.ref,put:e.out=e.env.graph,opt:e.opt,"#":r}),n.root.mum=s?f.to(s,n.root.mum):s,n.root.now=o},e),e.res&&e.res())}function a(e,t){if(e)return!0}function l(e,n,r,i){var o=this,s=t.is(e);!n&&i.path.length&&(o.res||b)(function(){for(var n=i.path,r=o.ref,a=o.opt,l=0,c=n.length;l<c;l++)r=r.get(n[l]);s&&(r=e);var h=r._.dub;if(h||(h=t.node.soul(i.obj)))return r.back(-1).get(h),void i.soul(h);(o.stun=o.stun||{})[n]=!0,r.get(u,!0,{as:{at:i,as:o,p:n}})},{as:o,at:i})}function u(e,n,r,i){var n=n.as,o=n.at;n=n.as;var s=((r||{}).$||{})._||{};e=s.dub=s.dub||e||t.node.soul(o.obj)||t.node.soul(r.put||s.put)||t.val.link.is(r.put||s.put)||(n.via.back("opt.uuid")||t.text.random)(),i&&(i.stun=!0),e?c(s,s.dub=e,o,n):s.via.back("opt.uuid")(function(e,r){if(e)return t.log(e);c(s,s.dub=s.dub||r,o,n)})}function c(e,t,n,r){e.$.back(-1).get(t),n.soul(t),r.stun[n.path]=!1,r.batch()}function h(e,n,r,o){if(n=n.as,r.$&&r.$._)if(r.err)i.log("Please report this as an issue! Put.any.err");else{var s=r.$._,a=s.put,l=n.opt||{},u,c;if(!(c=n.ref)||!c._.now){if(o&&(o.stun=!0),n.ref!==n.$){if(c=n.$._.get||s.get,!c)return void i.log("Please report this as an issue! Put.no.get");n.data=d({},c,n.data),c=null}if(g===a){if(!s.get)return;e||(c=s.$.back(function(e){if(e.link||e.soul)return e.link||e.soul;n.data=d({},e.get,n.data)})),c=c||s.soul||s.link||s.dub,s=c?s.root.$.get(c)._:s,n.soul=c,a=n.data}n.not||(n.soul=n.soul||e)||(n.path&&p(n.data)?n.soul=(l.uuid||n.via.back("opt.uuid")||t.text.random)():(_==s.get&&(n.soul=(s.put||y)["#"]||s.dub),n.soul=n.soul||s.soul||s.link||(l.uuid||n.via.back("opt.uuid")||t.text.random)()),n.soul)?n.ref.put(n.data,n.soul,n):n.via.back("opt.uuid")(function(e,r){if(e)return t.log(e);n.ref.put(n.data,n.soul=r,n)})}}}t.chain.put=function(e,i,o){var s=this,a=s._,l=a.root.$,u=l._,c=100,f;if(!u.puta)if(f=u.puts){if(f>c){if((u.stack||(u.stack=[])).push([s,e,i,o]),u.puto)return;return u.puto=setTimeout(function e(){var t=u.stack.splice(0,c),n=0,r;for(u.puta=!0;r=t[n++];)r[0].put(r[1],r[2],r[3]);if(delete u.puta,u.stack.length)return u.puto=setTimeout(e,0);u.stack=u.puts=u.puto=null},0),s}++u.puts}else u.puts=1;return o=o||{},o.data=e,o.via=o.$=o.via||o.$||s,"string"==typeof i?o.soul=i:o.ack=o.ack||i,a.soul&&(o.soul=a.soul),o.soul||l===s?p(o.data)?(o.soul=o.soul||(o.not=t.node.soul(o.data)||(o.via.back("opt.uuid")||t.text.random)()),o.soul?(o.$=l.get(o.soul),o.ref=o.$,n(o),s):(o.via.back("opt.uuid")(function(e,n){if(e)return t.log(e);(o.ref||o.$).put(o.data,o.soul=n,o)}),s)):((o.ack||v).call(o,o.out={err:t.log("Data saved to the root level of the graph must be a node (an object), not a",typeof o.data,'of "'+o.data+'"!')}),o.res&&o.res(),s):t.is(e)?(e.get(function(e,n,r){if(!e)return t.log("The reference you are saving is a",typeof r.put,'"'+r.put+'", not a node (object)!');s.put(t.val.link.ify(e),i,o)},!0),s):(a.has&&(f=t.val.link.is(e))&&(a.dub=f),o.ref=o.ref||l._===(f=a.back)?s:f.$,o.ref._.soul&&t.val.is(o.data)&&a.get?(o.data=d({},a.get,o.data),o.ref.put(o.data,o.soul,o),s):(o.ref.get(h,!0,{as:o}),o.out||(o.res=o.res||r,o.$._.stun=o.ref._.stun),s))};var f=t.obj,p=f.is,d=f.put,m=f.map,g,y={},v=function(){},b=function(e,t){e.call(t||y)},_=t.node._})(o,"./put"),o(function(e){var t=o("./root");o("./chain"),o("./back"),o("./put"),o("./get"),e.exports=t})(o,"./index"),o(function(e){var t=o("./index");function n(e,t){var n=this,r=e.$,i=(r||{})._||{},o=i.put||e.put,s=n.at,a;if(f!==o){if(a=e.$$){if(a=e.$$._,f===a.put)return;o=a.put}n.change&&(o=e.put),n.as?n.ok.call(n.as,e,t):n.ok.call(r,o,e.get,e,t)}}function r(e,n,i){if(e.$){var o=this.as,a=o.at,l=e.$,u=l._,h=u.put||e.put,p,d;(d=e.$$)&&(p=d=e.$$._,f!==p.put&&(h=p.put)),(d=n.wait)&&(d=d[u.id])&&clearTimeout(d),!i&&(f===h||u.soul||u.link||p&&!(0<p.ack))||f===h&&(d=(s(u.root.opt.peers,function(e,t,n){n(t)})||[]).length)&&!i&&(p||u).ack<=d?d=(n.wait={})[u.id]=setTimeout(function(){r.call({as:o},e,n,d||1)},o.wait||99):(p&&f===p.put&&(d=c.is(h))&&(h=t.node.ify({},d)),n.rid(e),o.ok.call(l||o.$,h,e.get))}else n.off()}t.chain.on=function(e,t,r,i){var o=this,s=o._,a,l,u;if("string"==typeof e)return t?(l=s.on(e,t,r||s,i),r&&r.$&&(r.subs||(r.subs=[])).push(l),o):s.on(e);var c=t;return c=!0===c?{change:!0}:c||{},c.at=s,c.ok=e,o.get(n,c),o},t.chain.val=function(e,n){return t.log.once("onceval","Future Breaking API Change: .val -> .once, apologies unexpected."),this.once(e,n)},t.chain.once=function(e,n){var i=this,o=i._,s=o.put;if(0<o.ack&&f!==s)return(e||h).call(i,s,o.get),i;if(!e){t.log.once("valonce","Chainable val is experimental, its behavior and API may change moving forward. Please play with it and report bugs and ideas on how to improve it.");var a=i.chain();return a._.nix=i.once(function(){a._.on("in",i._)}),a}return(n=n||{}).ok=e,n.at=o,n.out={"#":t.text.random(9)},i.get(r,{as:n}),n.async=!0,i},t.chain.off=function(){var e=this,t=e._,n,r=t.back;if(r)return t.ack=0,(n=r.next)&&n[t.get]&&l(n,t.get),(n=r.ask)&&l(n,t.get),(n=r.put)&&l(n,t.get),(n=t.soul)&&l(r.root.graph,n),(n=t.map)&&s(n,function(e){e.link&&r.root.$.get(e.link).off()}),(n=t.next)&&s(n,function(e){e.$.off()}),t.on("off",{}),e};var i=t.obj,s=i.map,a=i.has,l=i.del,u=i.to,c=t.val.link,h=function(){},f})(o,"./on"),o(function(e){var t=o("./index");function n(e){if(!e.put||t.val.is(e.put))return this.to.next(e);this.as.nix&&this.off(),i(e.put,r,{at:this.as,msg:e}),this.to.next(e)}function r(e,n){if(u!==n){var r=this.msg,i=r.$,o=i._,s=this.at,a=o.lex;a&&!t.text.match(n,a["."]||a["#"]||a)||(((a=i.get(n)._).echo||(a.echo={}))[s.id]=a.echo[s.id]||s)}}t.chain.map=function(e,r,i){var o=this,a=o._,l;return e?(t.log.once("mapfn","Map functions are experimental, their behavior and API may change moving forward. Please play with it and report bugs and ideas on how to improve it."),l=o.chain(),o.map().on(function(n,r,i,o){var a=(e||s).call(this,n,r,i,o);if(c!==a)return n===a?l._.on("in",i):t.is(a)?l._.on("in",a._):void l._.on("in",{get:r,put:a})}),l):(l=a.each)?l:(a.each=l=o.chain(),l._.nix=o.back("nix"),o.on("in",n,l._),l)};var i=t.obj.map,s=function(){},a=s,l=s,u=t.node._,c})(o,"./map"),o(function(e){var t=o("./index");t.chain.set=function(e,n,r){var i=this,o;return n=n||function(){},r=r||{},r.item=r.item||e,(o=t.node.soul(e))&&(e=t.obj.put({},o,t.val.link.ify(o))),t.is(e)?(e.get(function(e,o,s){if(!e)return n.call(i,{err:t.log('Only a node can be linked! Not "'+s.put+'"!')});i.put(t.obj.put({},e,t.val.link.ify(e)),n,r)},!0),e):(t.obj.is(e)&&(e=i.back(-1).get(o=o||t.node.soul(e)||i.back("opt.uuid")()).put(e)),i.get(o||t.state.lex()+t.text.random(7)).put(e,n,r))}})(o,"./set"),o(function(e){if("undefined"!=typeof Gun){var t,n=function(){},r,o;try{r=(Gun.window||n).localStorage}catch(e){}r||(i.log("Warning: No localStorage exists to persist data to!"),r={setItem:function(e,t){this[e]=t},removeItem:function(e){delete this[e]},getItem:function(e){return this[e]}}),Gun.on("create",function(e){var t=this.to,n=e.opt;if(e.once)return t.next(e);n.prefix=n.file||"gun/";var i=Gun.obj.ify(r.getItem("gap/"+n.prefix))||{},o=Gun.obj.empty,s,a,l;if(!o(i)){var u=Gun.obj.ify(r.getItem(n.prefix))||{},c={};Gun.obj.map(i,function(e,t){Gun.obj.map(e,function(e,n){c[t]=Gun.state.to(u[t],n,c[t])})}),setTimeout(function(){e.on("out",{put:c,"#":e.ask(h)})},1)}function h(e){if(!e.err&&e.ok){var t=e["@"];setTimeout(function(){Gun.obj.map(i,function(e,n){Gun.obj.map(e,function(n,r){t===n&&delete e[r]}),o(e)&&delete i[n]}),p()},n.wait||1)}}e.on("out",function(e){e.lS||(Gun.is(e.$)&&e.put&&!e["@"]&&(s=e["#"],Gun.graph.is(e.put,null,f),a||(a=setTimeout(p,n.wait||1))),this.to.next(e))}),e.on("ack",h),t.next(e);var f=function(e,t,n,r){(i[r]||(i[r]={}))[t]=s},p=function(){clearTimeout(a),a=!1;try{r.setItem("gap/"+n.prefix,JSON.stringify(i))}catch(e){Gun.log(err=e||"localStorage failure")}}}),Gun.on("create",function(e){this.to.next(e);var t=e.opt;if(!e.once&&!1!==t.localStorage){t.prefix=t.file||"gun/";var n=e.graph,i={},o=0,s,a=Gun.obj.ify(r.getItem(t.prefix))||{},l=function(){},u;e.on("localStorage",a),e.on("put",function(e){if(this.to.next(e),Gun.graph.is(e.put,null,c),e["@"]||(i[e["#"]]=!0),o+=1,o>=(t.batch||1e3))return h();s||(s=setTimeout(h,t.wait||1))}),e.on("get",function(t){this.to.next(t);var n=t.get,r,i,o;function s(){if(n&&(r=n["#"])){var s=n["."];i=a[r]||o,i&&s&&(i=Gun.state.to(i,s)),e.on("in",{"@":t["#"],put:Gun.graph.node(i),how:"lS",lS:t.$})}}Gun.debug?setTimeout(s,1):s()});var c=function(e,t,n,r){a[r]=Gun.state.to(n,t,a[r])},h=function(n){var l;o=0,clearTimeout(s),s=!1;var u=i;i={},n&&(a=n);try{r.setItem(t.prefix,JSON.stringify(a))}catch(n){Gun.log(l=(n||"localStorage failure")+" Consider using GUN's IndexedDB plugin for RAD for more storage space, https://gun.eco/docs/RAD#install"),e.on("localStorage:error",{err:l,file:t.prefix,flush:a,retry:h})}(l||Gun.obj.empty(t.peers))&&Gun.obj.map(u,function(t,n){e.on("in",{"@":n,err:l,ok:0})})}}})}})(o,"./adapters/localStorage"),o(function(e){var t=o("../type");function n(e){var n=function(){},o=e.opt||{};o.log=o.log||i.log,o.gap=o.gap||o.wait||1,o.pack=o.pack||.3*(o.memory?1e3*o.memory*1e3:1399e6);var a=e.dup;n.hear=function(r,i){if(r){var u,c,h,f=r[0];if(o.pack<=r.length)return n.say({dam:"!",err:"Message too big!"},i);if("{"!=r[2]&&(n.hear.d+=r.length||0,++n.hear.c),"["!==f){if("{"===f||t.obj.is(r)&&(u=r)){try{u=u||JSON.parse(r)}catch(e){return o.log("DAM JSON parse error",e)}if(!u)return;if((c=u["#"])||(c=u["#"]=t.text.random(9)),a.check(c))return;if(a.track(c,!0).it=u,(h=u["##"])||s===u.put||(h=u["##"]=t.obj.hash(u.put)),h&&(f=u["@"]||u.get&&c)){if(a.check(f+h))return;a.track(f+h,!0).it=u}return(u._=function(){}).via=i,(f=u["><"])&&(u._.to=t.obj.map(f.split(","),l)),u.dam?void((f=n.hear[u.dam])&&f(u,i,e)):void e.on("in",u)}}else{try{u=JSON.parse(r)}catch(e){o.log("DAM JSON parse error",e)}if(!u)return;for(var p=0,d;d=u[p++];)n.hear(d,i)}}};var l=function(e,t,n){n(e,!0)};function u(e,t){try{var r=t.wire;t.say?t.say(e):r.send&&r.send(e),n.say.d+=e.length||0,++n.say.c}catch(n){(t.queue=t.queue||[]).push(e)}}n.hear.c=n.hear.d=0,function(){var e;function i(t){n.say(e,t)}function l(e){var t=e.batch;if(e.batch=e.tail=null,t&&t.length){try{t=1===t.length?t[0]:JSON.stringify(t)}catch(e){return o.log("DAM JSON stringify error",e)}t&&u(t,e)}}n.say=function(c,h){if(this.to&&this.to.next(c),!c)return!1;var f,p,d,m,g=c._||(c._=function(){});if((f=c["#"])||(f=c["#"]=t.text.random(9)),(p=c["##"])||s===c.put||(p=c["##"]=t.obj.hash(c.put)),!(m=g.raw)&&(m=g.raw=n.raw(c),p&&(d=c["@"])&&(a.track(d+p).it=c,d=(a.s[d]||r).it))){if(p===d["##"])return!1;d["##"]=p}if(a.track(f).it=c,h||(h=(d=a.s[c["@"]])&&(d=d.it)&&(d=d._)&&(d=d.via)),!h&&n.way)return n.way(c);if(!h||!h.id)return e=c,!!t.obj.is(h||o.peers)&&void t.obj.map(h||o.peers,i);if(!h.wire&&n.wire&&n.wire(h),f!==h.last){if(h.last=f,h===g.via)return!1;if((d=g.to)&&(d[h.url]||d[h.pid]||d[h.id]))return!1;if(h.batch){if(h.tail=(d=h.tail||0)+m.length,h.tail<=o.pack)return void h.batch.push(m);l(h)}h.batch=[],setTimeout(function(){l(h)},o.gap),u(m,h)}},n.say.c=n.say.d=0}(),function(){n.raw=function(n){if(!n)return"";var r=n._||{},i,s,a;if(a=r.raw)return a;if("string"==typeof n)return n;if(!n.dam){var l=0,u=[];t.obj.map(o.peers,function(e){if(u.push(e.url||e.pid||e.id),++l>9)return!0}),l>1&&(n["><"]=u.join())}var c=e(n);return r&&(r.raw=c),c};var e=JSON.stringify,r=":])([:"}(),n.hi=function(r){var i=r.wire||{};r.id?o.peers[r.url||r.id]=r:(i=r.id=r.id||t.text.random(9),n.say({dam:"?"},o.peers[i]=r)),r.met=r.met||+new Date,i.hied||e.on(i.hied="hi",r),i=r.queue,r.queue=[],t.obj.map(i,function(e){u(e,r)})},n.bye=function(r){t.obj.del(o.peers,r.id),e.on("bye",r);var i=+new Date;i-=r.met||i,n.bye.time=((n.bye.time||i)+i)/2},n.hear["!"]=function(e,t){o.log("Error:",e.err)},n.hear["?"]=function(e,t){e.pid?t.pid||(t.pid=e.pid):n.say({dam:"?",pid:o.pid,"@":e["#"]},t)},e.on("create",function(e){e.opt.pid=e.opt.pid||t.text.random(9),this.to.next(e),e.on("out",n.say)});var c={};return e.on("bye",function(e,t){this.to.next(e),(t=e.url)&&(c[t]=!0,setTimeout(function(){delete c[t]},o.lack||9e3))}),e.on("hi",function(r,i){this.to.next(r),(i=r.url)&&c[i]&&(delete c[i],t.obj.map(e.next,function(o,s){i={},i[s]=e.graph[s],n.say({"##":t.obj.hash(i),get:{"#":s}},r)}))}),n}!function(){t.text.hash=function(e){if("string"!=typeof e)return{err:1};var t=0;if(!e.length)return t;for(var n=0,r=e.length,i;n<r;++n)i=e.charCodeAt(n),t=(t<<5)-t+i,t|=0;return t};var e=JSON.stringify,n;function r(e,n){var r;return n instanceof Object?(t.obj.map(Object.keys(n).sort(),i,{to:r={},on:n}),r):n}function i(e){this.to[e]=this.on[e]}t.obj.hash=function(i,o){if(o||n!==(i=e(i,r)))return t.text.hash(o||i||"")},t.obj.hash.sort=r}();var r=!0,s;Object.keys=Object.keys||function(e){return map(e,function(e,t,n){n(t)})};try{e.exports=n}catch(e){}})(o,"./adapters/mesh"),o(function(t){var n=o("../index");n.Mesh=o("./mesh"),n.on("opt",function(t){this.to.next(t);var r=t.opt;if(!t.once&&!1!==r.WebSocket){var i;"undefined"!=typeof window&&(i=window),void 0!==e&&(i=e),i=i||{};var o=r.WebSocket||i.WebSocket||i.webkitWebSocket||i.mozWebSocket;if(o){r.WebSocket=o;var s=r.mesh=r.mesh||n.Mesh(t),a=s.wire||r.wire;s.wire=r.wire=c;var l=2e3,u="undefined"!=typeof document&&document}}function c(e){try{if(!e||!e.url)return n&&n(e);var t=e.url.replace("http","ws"),n=e.wire=new r.WebSocket(t);return n.onclose=function(){r.mesh.bye(e),h(e)},n.onerror=function(t){h(e),t&&t.code},n.onopen=function(){r.mesh.hi(e)},n.onmessage=function(t){t&&r.mesh.hear(t.data||t,e)},n}catch(e){}}function h(e){clearTimeout(e.defer),u&&e.retry<=0||(e.retry=(e.retry||r.retry||60)-1,e.defer=setTimeout(function t(){if(u&&u.hidden)return setTimeout(t,l);c(e)},l))}});var r=function(){}})(o,"./adapters/websocket")}()}).call(this,n(8),n(85)(e))},function(e,t,n){"use strict";t.decode=t.parse=n(641),t.encode=t.stringify=n(642)},function(e,t,n){const r=n(77);utils={},utils.consolearr=(e=>e&&e.length>0?[e.length+" items inc:",e[e.length-1]]:e),utils.stringfrom=function(e,t={}){try{return"Url"===e.constructor.name?e.href:"string"==typeof e?e:e.toString()}catch(t){throw new r.CodingError(`Unable to turn ${e} into a string ${t.message}`)}},utils.p_timeout=function(e,t,n){let i=null;return Promise.race([new Promise((e,o)=>{i=setTimeout(o,t,new r.TimeoutError(n||`Timed out in ${t}ms`))}),e.then(e=>(clearTimeout(i),e))])},utils.createElement=function(e,t,n){var r=document.createElement(e);for(let e in t){let n="classname"===e.toLowerCase()?"class":e;if("dangerouslySetInnerHTML"===e&&(r.innerHTML=t[e].__html,delete t.dangerouslySetInnerHTML),t.hasOwnProperty(e)){let i=t[e];if(!0===i)r.setAttribute(n,e);else if("object"!=typeof i||Array.isArray(i))!1!==i&&null!=i&&r.setAttribute(n,i.toString());else if(["style"].includes(n))for(let e in i)r[n][e]=i[e];else r[n]=i}}for(let e=2;e<arguments.length;e++){let t=arguments[e];t&&(Array.isArray(t)?t.map(e=>r.appendChild(null==e.nodeType?document.createTextNode(e.toString()):e)):r.appendChild(null==t.nodeType?document.createTextNode(t.toString()):t))}return r},t=e.exports=utils},function(e,t,n){var r=n(148),i=n(242);function o(e){return null!=e&&i(e.length)&&!r(e)}e.exports=o},function(e,t,n){var r=n(108),i=n(181),o="[object AsyncFunction]",s="[object Function]",a="[object GeneratorFunction]",l="[object Proxy]";function u(e){if(!i(e))return!1;var t=r(e);return t==s||t==a||t==o||t==l}e.exports=u},function(e,t,n){var r=n(657),i=n(664),o=n(147);function s(e){return o(e)?r(e):i(e)}e.exports=s},function(e,t,n){"use strict";e.exports=function e(t,n){var r,i;function o(e){if(r=e,i)return o.abort();!function e(){for(var o=!0,s=!1;o;)if(s=!1,r(null,function(a,l){if(s=!0,a=a||i){if(o=!1,n)n(!0===a?null:a);else if(a&&!0!==a)throw a}else t&&!1===t(l)||i?(o=!1,r(i||!0,n||function(){})):o||e()}),!s)return void(o=!1)}()}return o.abort=function(e,t){if("function"==typeof e&&(t=e,e=!0),i=e||!0,r)return r(i,t||function(){})},o}},function(e,t){e.exports=function e(t){return t&&("string"==typeof t?function(e){return e[t]}:"object"==typeof t&&"function"==typeof t.exec?function(e){var n=t.exec(e);return n&&n[0]}:t)}},function(e,t,n){var r=n(21);r.pki=r.pki||{};var i=e.exports=r.pki.oids=r.oids=r.oids||{};function o(e,t){i[e]=t,i[t]=e}function s(e,t){i[e]=t}o("1.2.840.113549.1.1.1","rsaEncryption"),o("1.2.840.113549.1.1.4","md5WithRSAEncryption"),o("1.2.840.113549.1.1.5","sha1WithRSAEncryption"),o("1.2.840.113549.1.1.7","RSAES-OAEP"),o("1.2.840.113549.1.1.8","mgf1"),o("1.2.840.113549.1.1.9","pSpecified"),o("1.2.840.113549.1.1.10","RSASSA-PSS"),o("1.2.840.113549.1.1.11","sha256WithRSAEncryption"),o("1.2.840.113549.1.1.12","sha384WithRSAEncryption"),o("1.2.840.113549.1.1.13","sha512WithRSAEncryption"),o("1.2.840.10040.4.3","dsa-with-sha1"),o("1.3.14.3.2.7","desCBC"),o("1.3.14.3.2.26","sha1"),o("2.16.840.1.101.3.4.2.1","sha256"),o("2.16.840.1.101.3.4.2.2","sha384"),o("2.16.840.1.101.3.4.2.3","sha512"),o("1.2.840.113549.2.5","md5"),o("1.2.840.113549.1.7.1","data"),o("1.2.840.113549.1.7.2","signedData"),o("1.2.840.113549.1.7.3","envelopedData"),o("1.2.840.113549.1.7.4","signedAndEnvelopedData"),o("1.2.840.113549.1.7.5","digestedData"),o("1.2.840.113549.1.7.6","encryptedData"),o("1.2.840.113549.1.9.1","emailAddress"),o("1.2.840.113549.1.9.2","unstructuredName"),o("1.2.840.113549.1.9.3","contentType"),o("1.2.840.113549.1.9.4","messageDigest"),o("1.2.840.113549.1.9.5","signingTime"),o("1.2.840.113549.1.9.6","counterSignature"),o("1.2.840.113549.1.9.7","challengePassword"),o("1.2.840.113549.1.9.8","unstructuredAddress"),o("1.2.840.113549.1.9.14","extensionRequest"),o("1.2.840.113549.1.9.20","friendlyName"),o("1.2.840.113549.1.9.21","localKeyId"),o("1.2.840.113549.1.9.22.1","x509Certificate"),o("1.2.840.113549.1.12.10.1.1","keyBag"),o("1.2.840.113549.1.12.10.1.2","pkcs8ShroudedKeyBag"),o("1.2.840.113549.1.12.10.1.3","certBag"),o("1.2.840.113549.1.12.10.1.4","crlBag"),o("1.2.840.113549.1.12.10.1.5","secretBag"),o("1.2.840.113549.1.12.10.1.6","safeContentsBag"),o("1.2.840.113549.1.5.13","pkcs5PBES2"),o("1.2.840.113549.1.5.12","pkcs5PBKDF2"),o("1.2.840.113549.1.12.1.1","pbeWithSHAAnd128BitRC4"),o("1.2.840.113549.1.12.1.2","pbeWithSHAAnd40BitRC4"),o("1.2.840.113549.1.12.1.3","pbeWithSHAAnd3-KeyTripleDES-CBC"),o("1.2.840.113549.1.12.1.4","pbeWithSHAAnd2-KeyTripleDES-CBC"),o("1.2.840.113549.1.12.1.5","pbeWithSHAAnd128BitRC2-CBC"),o("1.2.840.113549.1.12.1.6","pbewithSHAAnd40BitRC2-CBC"),o("1.2.840.113549.2.7","hmacWithSHA1"),o("1.2.840.113549.2.8","hmacWithSHA224"),o("1.2.840.113549.2.9","hmacWithSHA256"),o("1.2.840.113549.2.10","hmacWithSHA384"),o("1.2.840.113549.2.11","hmacWithSHA512"),o("1.2.840.113549.3.7","des-EDE3-CBC"),o("2.16.840.1.101.3.4.1.2","aes128-CBC"),o("2.16.840.1.101.3.4.1.22","aes192-CBC"),o("2.16.840.1.101.3.4.1.42","aes256-CBC"),o("2.5.4.3","commonName"),o("2.5.4.5","serialName"),o("2.5.4.6","countryName"),o("2.5.4.7","localityName"),o("2.5.4.8","stateOrProvinceName"),o("2.5.4.10","organizationName"),o("2.5.4.11","organizationalUnitName"),o("2.16.840.1.113730.1.1","nsCertType"),s("2.5.29.1","authorityKeyIdentifier"),s("2.5.29.2","keyAttributes"),s("2.5.29.3","certificatePolicies"),s("2.5.29.4","keyUsageRestriction"),s("2.5.29.5","policyMapping"),s("2.5.29.6","subtreesConstraint"),s("2.5.29.7","subjectAltName"),s("2.5.29.8","issuerAltName"),s("2.5.29.9","subjectDirectoryAttributes"),s("2.5.29.10","basicConstraints"),s("2.5.29.11","nameConstraints"),s("2.5.29.12","policyConstraints"),s("2.5.29.13","basicConstraints"),o("2.5.29.14","subjectKeyIdentifier"),o("2.5.29.15","keyUsage"),s("2.5.29.16","privateKeyUsagePeriod"),o("2.5.29.17","subjectAltName"),o("2.5.29.18","issuerAltName"),o("2.5.29.19","basicConstraints"),s("2.5.29.20","cRLNumber"),s("2.5.29.21","cRLReason"),s("2.5.29.22","expirationDate"),s("2.5.29.23","instructionCode"),s("2.5.29.24","invalidityDate"),s("2.5.29.25","cRLDistributionPoints"),s("2.5.29.26","issuingDistributionPoint"),s("2.5.29.27","deltaCRLIndicator"),s("2.5.29.28","issuingDistributionPoint"),s("2.5.29.29","certificateIssuer"),s("2.5.29.30","nameConstraints"),o("2.5.29.31","cRLDistributionPoints"),o("2.5.29.32","certificatePolicies"),s("2.5.29.33","policyMappings"),s("2.5.29.34","policyConstraints"),o("2.5.29.35","authorityKeyIdentifier"),s("2.5.29.36","policyConstraints"),o("2.5.29.37","extKeyUsage"),s("2.5.29.46","freshestCRL"),s("2.5.29.54","inhibitAnyPolicy"),o("1.3.6.1.4.1.11129.2.4.2","timestampList"),o("1.3.6.1.5.5.7.1.1","authorityInfoAccess"),o("1.3.6.1.5.5.7.3.1","serverAuth"),o("1.3.6.1.5.5.7.3.2","clientAuth"),o("1.3.6.1.5.5.7.3.3","codeSigning"),o("1.3.6.1.5.5.7.3.4","emailProtection"),o("1.3.6.1.5.5.7.3.8","timeStamping")},function(e,t,n){"use strict";const r=t;r.Reporter=n(760).Reporter,r.DecoderBuffer=n(374).DecoderBuffer,r.EncoderBuffer=n(374).EncoderBuffer,r.Node=n(761)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=f;var r=n(58),i=h(r),o=n(86),s=h(o),a=n(107),l=h(a),u=n(37),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n){n=(0,l.default)(n||i.default);var r=(0,c.default)(t);if(!e())return n(null);var o=function(t){if(t)return n(t);if(e())return r(o);var i=(0,s.default)(arguments,1);n.apply(null,[null].concat(i))};r(o)}e.exports=t.default},function(e,t,n){(function(t){e.exports=function e(n,r){for(var i=Math.min(n.length,r.length),o=new t(i),s=0;s<i;++s)o[s]=n[s]^r[s];return o}}).call(this,n(0).Buffer)},function(e,t){function n(e){return e}e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(58),i=a(r),o=n(243),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t){return function(n,r,o,a){a=a||i.default;var l=!1,u;n(r,function(n,r,i){o(n,function(r,o){r?i(r):e(o)&&!u?(l=!0,u=t(!0,n),i(null,s.default)):i()})},function(e){e?a(e):a(null,l?u:t(!1))})}}e.exports=t.default},function(e,t,n){"use strict";(function(t){const r=n(906),i=n(907),{Key:o}=n(28),s=n(51),a=n(15),l=n(27),u=n(4),c=u("jsipns");c.error=u("jsipns:error");const h=n(908),{parseRFC3339:f}=n(909),p=n(910),d=l.names.id,m="/ipns/",g=(e,t,n,r,o)=>{const s=new i(Date.now()+Number(r)).toString(),a=h.ValidityType.EOL;v(e,t,n,s,a,o)},y=(e,t,n,r,i)=>{const o=h.ValidityType.EOL;v(e,t,n,r,o,i)},v=(e,t,n,r,i,o)=>{x(e,t,i,r,(e,s)=>{if(e)return c.error("record signature creation failed"),o(Object.assign(new Error("record signature verification failed"),{code:p.ERR_SIGNATURE_CREATION}));const a={value:t,signature:s,validityType:i,validity:r,sequence:n};return c(`ipns entry for ${t} created`),o(null,a)})},b=(e,t,n)=>{const{value:r,validityType:i,validity:o}=t,s=A(r,i,o);e.verify(s,t.signature,(e,t)=>{if(e||!t)return c.error("record signature verification failed"),n(Object.assign(new Error("record signature verification failed"),{code:p.ERR_SIGNATURE_VERIFICATION}));if(i===h.ValidityType.EOL){let e;try{e=f(o.toString())}catch(e){return c.error("unrecognized validity format (not an rfc3339 format)"),n(Object.assign(new Error("unrecognized validity format (not an rfc3339 format)"),{code:p.ERR_UNRECOGNIZED_FORMAT}))}if(e<Date.now())return c.error("record has expired"),n(Object.assign(new Error("record has expired"),{code:p.ERR_IPNS_EXPIRED_RECORD}))}else if(i)return c.error("unrecognized validity type"),n(Object.assign(new Error("unrecognized validity type"),{code:p.ERR_UNRECOGNIZED_VALIDITY}));return c(`ipns entry for ${r} is valid`),n(null,null)})},_=(e,t,n)=>{if(!e||!e.bytes||!t){const e="one or more of the provided parameters are not defined";return c.error(e),n(Object.assign(new Error(e),{code:p.ERR_UNDEFINED_PARAMETER}))}a.createFromPubKey(e.bytes,(r,i)=>{if(r)return c.error(r),n(Object.assign(new Error(r),{code:p.ERR_PEER_ID_FROM_PUBLIC_KEY}));let o;try{o=T(i)}catch(r){return c.error(r),n(Object.assign(new Error(r),{code:p.ERR_PUBLIC_KEY_FROM_ID}))}if(o)return n(null,null);try{t.pubKey=s.keys.marshalPublicKey(e)}catch(r){return c.error(r),n(r)}n(null,t)})},w=(e,t,n)=>{if(!t||!e){const e="one or more of the provided parameters are not defined";return c.error(e),n(Object.assign(new Error(e),{code:p.ERR_UNDEFINED_PARAMETER}))}if(t.pubKey){let e;try{e=s.keys.unmarshalPublicKey(t.pubKey)}catch(e){return c.error(e),n(e)}return n(null,e)}e.pubKey?n(null,e.pubKey):n(Object.assign(new Error("no public key is available"),{code:p.ERR_UNDEFINED_PARAMETER}))},k=e=>r(e,"RFC4648",{padding:!1}),E=e=>new o(`/ipns/${k(e)}`),S=e=>{const n=t.from("/pk/"),r=t.from("/ipns/");return{routingPubKey:new o(t.concat([n,e])),pkKey:new o(k(t.concat([n,e]))),routingKey:new o(t.concat([r,e])),ipnsKey:new o(k(t.concat([r,e])))}},x=(e,t,n,r,i)=>{const o=A(t,n,r);e.sign(o,(e,t)=>e?i(e):i(null,t))},C=e=>{if("0"===e.toString())return"EOL";{const t=`unrecognized validity type ${e.toString()}`;throw c.error(t),Object.assign(new Error(t),{code:p.ERR_UNRECOGNIZED_VALIDITY})}},A=(e,n,r)=>{const i=t.from(e),o=t.from(C(n)),s=t.from(r);return t.concat([i,s,o])},T=e=>{const t=l.decode(e.id);return t.code!==d?null:s.keys.unmarshalPublicKey(t.digest)},I=h.encode,j=h.decode,R={validate:(e,t,n)=>{const r=j(e),i=t.slice("/ipns/".length);let o;try{o=a.createFromBytes(i)}catch(e){return n(e)}w(o,r,(e,t)=>{if(e)return n(e);b(t,r,e=>{if(e)return n(e);n(null,!0)})})},select:(e,t,n)=>{const r=j(e),i=j(t),o=r.sequence>i.sequence?0:1;if("function"!=typeof n)return o;n(null,o)}};e.exports={create:g,createWithExpiration:y,validate:b,embedPublicKey:_,extractPublicKey:w,getLocalKey:E,getIdKeys:S,marshal:I,unmarshal:j,validator:R,namespace:"/ipns/",namespaceLength:"/ipns/".length}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(326),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t,n){var r=(0,s.default)(e);return(0,i.default)(function(i,o){var s=!1,a;function l(){var t=e.name||"anonymous",r=new Error('Callback function "'+t+'" timed out.');r.code="ETIMEDOUT",n&&(r.info=n),s=!0,o(r)}i.push(function(){s||(o.apply(null,arguments),clearTimeout(a))}),a=setTimeout(l,t),r.apply(null,i)})}e.exports=t.default},function(e,t,n){const r=n(6).EventEmitter,i=n(24),o=n(1033);function s(e,t){"object"==typeof e&&(t=e,e="START"),i.equal(typeof e,"string"),i.equal(typeof t,"object"),i.ok(t[e],"invalid starting state "+e),i.ok(o.validate(t));const n=new r;return l._graph=o.reachable(t),l._emitter=n,l._events=t,l._state=e,l.emit=l,l.on=s,l;function s(e,t){n.on(e,t)}function l(e){const t=l._events[l._state][e];if(!a(l._state,t,l._graph)){const t="invalid transition: "+l._state+" -> "+e;return n.emit("error",t)}const r=l._state+":leave",i=t+":enter";return l._state?o():s();function o(){n._events[r]?n.emit(r,s):s()}function s(){n._events[i]?n.emit(i,u):u()}function u(){l._state=t,n.emit(t),n.emit("done")}}}function a(e,t,n){if(!t)return!1;if(!e)return!0;const r=n[e];return!(!r||!r[t])&&1===r[t].length}e.exports=s},function(e,t,n){"use strict";const r=n(22),i=n(31),o=n(15),s=n(162);e.exports=function(e){function t(e){let t=null;if(r.isMultiaddr(e)){const n=r(e);t=n.getPeerId()}else i.isPeerInfo(e)&&(t=e.id.toB58String());return t}function n(t){let n;if(i.isPeerInfo(t))n=t;else if(r.isMultiaddr(t)){const r=t.getPeerId();try{n=e._peerBook.get(r)}catch(e){n=new i(o.createFromB58String(r))}n.multiaddrs.add(t)}else if(o.isPeerId(t)){const r=t.toB58String();n=e._peerBook.has(r)?e._peerBook.get(r):t}return n}function a(t){return e.muxedConns[t]||e.conns[t]}function l(e,t,n){return n=n||(()=>{}),e.write(s.CircuitRelay.encode({type:s.CircuitRelay.Type.STATUS,code:t})),n()}function u(e,t,n,i){try{e.dstPeer.addrs.forEach(e=>r(e))}catch(e){return l(t,n===s.CircuitRelay.Type.HOP?s.CircuitRelay.Status.HOP_DST_MULTIADDR_INVALID:s.CircuitRelay.Status.STOP_DST_MULTIADDR_INVALID),i(e)}try{e.srcPeer.addrs.forEach(e=>r(e))}catch(e){return l(t,n===s.CircuitRelay.Type.HOP?s.CircuitRelay.Status.HOP_SRC_MULTIADDR_INVALID:s.CircuitRelay.Status.STOP_SRC_MULTIADDR_INVALID),i(e)}return i(null)}function c(e){return"string"==typeof e?o.createFromB58String(e):o.createFromBytes(e)}return{getB58String:t,peerInfoFromMa:n,isPeerConnected:a,validateAddrs:u,writeResponse:l,peerIdFromId:c}}},function(e,t,n){"use strict";const r=n(57);e.exports=r("\nmessage CircuitRelay {\n\n enum Status {\n SUCCESS = 100;\n HOP_SRC_ADDR_TOO_LONG = 220;\n HOP_DST_ADDR_TOO_LONG = 221;\n HOP_SRC_MULTIADDR_INVALID = 250;\n HOP_DST_MULTIADDR_INVALID = 251;\n HOP_NO_CONN_TO_DST = 260;\n HOP_CANT_DIAL_DST = 261;\n HOP_CANT_OPEN_DST_STREAM = 262;\n HOP_CANT_SPEAK_RELAY = 270;\n HOP_CANT_RELAY_TO_SELF = 280;\n STOP_SRC_ADDR_TOO_LONG = 320;\n STOP_DST_ADDR_TOO_LONG = 321;\n STOP_SRC_MULTIADDR_INVALID = 350;\n STOP_DST_MULTIADDR_INVALID = 351;\n STOP_RELAY_REFUSED = 390;\n MALFORMED_MESSAGE = 400;\n }\n\n enum Type { // RPC identifier, either HOP, STOP or STATUS\n HOP = 1;\n STOP = 2;\n STATUS = 3;\n CAN_HOP = 4;\n }\n\n message Peer {\n required bytes id = 1; // peer id\n repeated bytes addrs = 2; // peer's known addresses\n }\n\n optional Type type = 1; // Type of the message\n\n optional Peer srcPeer = 2; // srcPeer and dstPeer are used when Type is HOP or STATUS\n optional Peer dstPeer = 3;\n\n optional Status code = 4; // Status code, used when Type is STATUS\n}\n")},function(e,t,n){"use strict";const r=n(2),i=n(59),o=n(200),s=n(9),a="ERR_BAD_PATH";function l(e){const t=new Error("invalid ipfs ref path");e=e.replace(/^\/ipfs\//,"");const n=e.match(/([^/]+(?:\/[^/]+)*)\/?$/);if(!n)throw t;const[r,...i]=n[1].split("/");if(o.cid(r))return{hash:r,links:i};throw t}t.OFFLINE_ERROR="This command must be run in online mode. Try running 'ipfs daemon' first.";const u=e=>{if(o.cid(e))return`/ipfs/${e}`;if(o.path(e))return e;throw Object.assign(new Error(`invalid ${e} path`),{code:a})},c=r(function(e,n,r){Array.isArray(n)||(n=[n]),i(n,(n,r)=>{if("string"!=typeof n){let e;try{e=new s(n)}catch(e){return r(e)}return r(null,e.buffer)}let i;try{i=t.parseIpfsPath(n)}catch(e){return r(e)}const o=new s(i.hash),a=i.links;if(!a.length)return r(null,o.buffer);function l(t,n,i,o){if(i)return r(i);if(!n.length)return r(null,t.buffer);const s=n[0],a=o.links.find(e=>e.name===s);if(!a)return r(new Error(`no link named "${s}" under ${t.toBaseEncodedString()}`));e.get(a.cid,l.bind(null,a.cid,n.slice(1)))}e.get(o,l.bind(null,o,a))},r)});t.normalizePath=u,t.parseIpfsPath=l,t.resolvePath=c},function(e,t){function n(e){return"function"==typeof e}function r(e){return"object"==typeof e&&i(e.source)&&o(e.sink)}function i(e){return n(e)&&2===e.length}function o(e){return n(e)&&1===e.length}t.isDuplex=r,t.isSource=i,t.isSink=o},function(e,t,n){var r=n(461);e.exports=function(e,t){return function(n){var i=[],o,s;function a(e){i.push(e)}e=e||function(e){this.queue(e)},t=t||function(){this.queue(null)};var l={emit:function(e,t){"data"==e&&a(t),"end"==e&&(o=!0,a(null)),"error"==e&&(s=t)},queue:a},u;return function(a,c){if(o=o||a,a)return n(a,function(){if(u){var e=u;u=null,e(a)}c(a)});u=c,r(function r(a){if(u)if(c=u,s)u=null,c(s);else if(i.length){var h=i.shift();u=null,c(null===h,h)}else n(o,function(i,h){if(i&&!0!==i)return s=i,a();if(o=o||i)t.call(l);else if(null!==h&&(e.call(l,h),s||o))return n(s||o,function(){u=null,c(s||o)});a(r)})})}}}},function(e,t,n){(function(t){var r=n(17).Writable,i=n(1),o=Uint8Array;function s(e,t){if(!(this instanceof s))return new s(e,t);"function"==typeof e&&(t=e,e={}),e||(e={});var n=e.encoding,i=!1;n?(n=String(n).toLowerCase(),"u8"!==n&&"uint8"!==n||(n="uint8array")):i=!0,r.call(this,{objectMode:!0}),this.encoding=n,this.shouldInferEncoding=i,t&&this.on("finish",function(){t(this.getBody())}),this.body=[]}function a(e){return/Array\]$/.test(Object.prototype.toString.call(e))}function l(e){return"string"==typeof e||a(e)||e&&"function"==typeof e.subarray}function u(e){for(var n=[],r=0;r<e.length;r++){var i=e[r];"string"==typeof i?n.push(i):t.isBuffer(i)?n.push(i):l(i)?n.push(t.from(i)):n.push(t.from(String(i)))}return t.isBuffer(e[0])?(n=t.concat(n),n=n.toString("utf8")):n=n.join(""),n}function c(e){for(var n=[],r=0;r<e.length;r++){var i=e[r];t.isBuffer(i)?n.push(i):l(i)?n.push(t.from(i)):n.push(t.from(String(i)))}return t.concat(n)}function h(e){for(var t=[],n=0;n<e.length;n++)t.push.apply(t,e[n]);return t}function f(e){for(var n=0,r=0;r<e.length;r++)"string"==typeof e[r]&&(e[r]=t.from(e[r])),n+=e[r].length;for(var i=new o(n),r=0,s=0;r<e.length;r++)for(var a=e[r],l=0;l<a.length;l++)i[s++]=a[l];return i}e.exports=s,i(s,r),s.prototype._write=function(e,t,n){this.body.push(e),n()},s.prototype.inferEncoding=function(e){var n=void 0===e?this.body[0]:e;return t.isBuffer(n)?"buffer":"undefined"!=typeof Uint8Array&&n instanceof Uint8Array?"uint8array":Array.isArray(n)?"array":"string"==typeof n?"string":"[object Object]"===Object.prototype.toString.call(n)?"object":"buffer"},s.prototype.getBody=function(){return this.encoding||0!==this.body.length?(this.shouldInferEncoding&&(this.encoding=this.inferEncoding()),"array"===this.encoding?h(this.body):"string"===this.encoding?u(this.body):"buffer"===this.encoding?c(this.body):"uint8array"===this.encoding?f(this.body):this.body):[]}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(17).Duplex,i=n(122),o=n(128),s=n(26),a=n(1264),l=n(1268);function u(e){const t=e.path?encodeURIComponent(e.path):"",n={"Content-Disposition":`file; filename="${t}"`};return e.content?e.symlink?n["Content-Type"]="application/symlink":n["Content-Type"]="application/octet-stream":n["Content-Type"]="application/x-directory",n}function c(e,t,n){return t in e?e[t]:n in e?e[n]:void 0}e.exports=((e,t)=>n=>{let h,f=!1,p=!1;n=n?Object.assign({},n,n.qs):{};const d=new l,m=new r({objectMode:!0});m._read=(e=>{}),m._write=((e,t,r)=>{const o=s(r);try{const r=a(e,n).map(e=>Object.assign({headers:u(e)},e));p=!0,i(r,(e,n)=>d.write(e,t,n),e=>{if(p=!1,e)return o(e);f&&d.end(),o()})}catch(e){o(e)}}),m.once("finish",()=>{f||(f=!0,p||d.end())});const g=n.qs||{};g["cid-version"]=c(n,"cid-version","cidVersion"),g["raw-leaves"]=c(n,"raw-leaves","rawLeaves"),g["only-hash"]=c(n,"only-hash","onlyHash"),g["wrap-with-directory"]=c(n,"wrap-with-directory","wrapWithDirectory"),g.hash=c(n,"hash","hashAlg");const y={path:t,qs:g,args:n.args,multipart:!0,multipartBoundary:d._boundary,stream:!0,recursive:!0,progress:n.progress};return d.on("error",e=>{m.emit("error",e)}),h=e(y,(e,t)=>{if(e)return m.emit("error",e);if(!t)return m.push(null);if(!o(t))return m.push(t),void m.push(null);if(t.on("error",e=>m.emit("error",e)),n.converter){t.on("data",e=>{e.Bytes&&n.progress&&n.progress(e.Bytes)});const e=n.converter,r=new e;r.once("end",()=>m.push(null)),r.on("data",e=>m.push(e)),t.pipe(r)}else t.on("data",e=>{e.Bytes&&n.progress&&n.progress(e.Bytes),m.push(e)}),t.once("end",()=>m.push(null))}),h.on("drain",()=>d.emit("drain")),d.pipe(h),m})},function(e,t){e.exports=!1},function(e,t,n){var r=n(131),i=n(32),o=e.exports;for(var s in r)r.hasOwnProperty(s)&&(o[s]=r[s]);function a(e){if("string"==typeof e&&(e=i.parse(e)),e.protocol||(e.protocol="https:"),"https:"!==e.protocol)throw new Error('Protocol "'+e.protocol+'" not supported. Expected "https:"');return e}o.request=function(e,t){return e=a(e),r.request.call(this,e,t)},o.get=function(e,t){return e=a(e),r.get.call(this,e,t)}},function(e,t,n){(function(t){function n(e,n){var r,i,o,s=!0;function a(e){function i(){n&&n(e,r),n=null}s?t.nextTick(i):i()}function l(e,t,n){r[e]=n,(0==--i||t)&&a(t)}Array.isArray(e)?(r=[],i=e.length):(o=Object.keys(e),r={},i=o.length),i?o?o.forEach(function(t){e[t](function(e,n){l(t,e,n)})}):e.forEach(function(e,t){e(function(e,n){l(t,e,n)})}):a(null),s=!1}e.exports=n}).call(this,n(3))},function(e,t,n){var r=n(1544),i=new r,o="undefined"!=typeof window?window:self,s=o.crypto||o.msCrypto||{},a=s.subtle||s.webkitSubtle;function l(e){return i.digest(e)}try{a.digest({name:"sha-1"},new Uint8Array).catch(function(){a=!1})}catch(e){a=!1}function u(e,t){a?("string"==typeof e&&(e=c(e)),a.digest({name:"sha-1"},e).then(function e(n){t(h(new Uint8Array(n)))},function n(r){t(l(e))})):setTimeout(t,0,l(e))}function c(e){for(var t=e.length,n=new Uint8Array(t),r=0;r<t;r++)n[r]=e.charCodeAt(r);return n}function h(e){for(var t=e.length,n=[],r=0;r<t;r++){var i=e[r];n.push((i>>>4).toString(16)),n.push((15&i).toString(16))}return n.join("")}e.exports=u,e.exports.sync=l},function(e,t,n){e.exports=d;var r=n(25),i=n(29).Buffer,o=n(48),s=n(16),a=n(76),l=n(41),u=n(46),c=n(177),h=n(42),f=a.FingerprintFormatError,p=a.InvalidAlgorithmError;function d(e){if(r.object(e,"options"),r.string(e.type,"options.type"),r.buffer(e.hash,"options.hash"),r.string(e.algorithm,"options.algorithm"),this.algorithm=e.algorithm.toLowerCase(),!0!==o.hashAlgs[this.algorithm])throw new p(this.algorithm);this.hash=e.hash,this.type=e.type,this.hashType=e.hashType}d.prototype.toString=function(e){switch(void 0===e&&(e="md5"===this.algorithm||"spki"===this.hashType?"hex":"base64"),r.string(e),e){case"hex":return"spki"===this.hashType?this.hash.toString("hex"):y(this.hash.toString("hex"));case"base64":return"spki"===this.hashType?this.hash.toString("base64"):b(this.algorithm,this.hash.toString("base64"));default:throw new f(void 0,e)}},d.prototype.matches=function(e){r.object(e,"key or certificate"),"key"===this.type&&"ssh"!==this.hashType?(h.assertCompatible(e,l,[1,7],"key with spki"),u.isPrivateKey(e)&&h.assertCompatible(e,u,[1,6],"privatekey with spki support")):"key"===this.type?h.assertCompatible(e,l,[1,0],"key"):h.assertCompatible(e,c,[1,0],"certificate");var t=e.hash(this.algorithm,this.hashType),n=s.createHash(this.algorithm).update(t).digest("base64");return void 0===this.hash2&&(this.hash2=s.createHash(this.algorithm).update(this.hash).digest("base64")),this.hash2===n};var m=/^[A-Za-z0-9+\/=]+$/,g=/^[a-fA-F0-9]+$/;function y(e){return e.replace(/(.{2})(?=.)/g,"$1:")}function v(e){return e.replace(/=*$/,"")}function b(e,t){return e.toUpperCase()+":"+v(t)}d.parse=function(e,t){var n,s,a;r.string(e,"fingerprint"),Array.isArray(t)&&(a=t,t={}),r.optionalObject(t,"options"),void 0===t&&(t={}),void 0!==t.enAlgs&&(a=t.enAlgs),void 0!==t.algorithms&&(a=t.algorithms),r.optionalArrayOfString(a,"algorithms");var l="ssh";void 0!==t.hashType&&(l=t.hashType),r.string(l,"options.hashType");var u=e.split(":");if(2==u.length){if(n=u[0].toLowerCase(),!m.test(u[1]))throw new f(e);try{s=i.from(u[1],"base64")}catch(t){throw new f(e)}}else if(u.length>2){if(n="md5","md5"===u[0].toLowerCase()&&(u=u.slice(1)),u=u.map(function(t){for(;t.length<2;)t="0"+t;if(t.length>2)throw new f(e);return t}),u=u.join(""),!g.test(u)||u.length%2!=0)throw new f(e);try{s=i.from(u,"hex")}catch(t){throw new f(e)}}else{if(g.test(e))s=i.from(e,"hex");else{if(!m.test(e))throw new f(e);s=i.from(e,"base64")}switch(s.length){case 32:n="sha256";break;case 16:n="md5";break;case 20:n="sha1";break;case 64:n="sha512";break;default:throw new f(e)}void 0===t.hashType&&(l="spki")}if(void 0===n)throw new f(e);if(void 0===o.hashAlgs[n])throw new p(n);if(void 0!==a&&(a=a.map(function(e){return e.toLowerCase()}),-1===a.indexOf(n)))throw new p(n);return new d({algorithm:n,hash:s,type:t.type||"key",hashType:l})},d.isFingerprint=function(e,t){return h.isCompatible(e,d,t)},d.prototype._sshpkApiVersion=[1,2],d._oldVersionDetect=function(e){return r.func(e.toString),r.func(e.matches),[1,0]}},function(e,t,n){(function(){var n,r=0xdeadbeefcafe,i=!0;function o(e,t,n){null!=e&&("number"==typeof e?this.fromNumber(e,t,n):null==t&&"string"!=typeof e?this.fromString(e,256):this.fromString(e,t))}function s(){return new o(null)}function a(e,t,n,r,i,o){for(;--o>=0;){var s=t*this[e++]+n[r]+i;i=Math.floor(s/67108864),n[r++]=67108863&s}return i}function l(e,t,n,r,i,o){for(var s=32767&t,a=t>>15;--o>=0;){var l=32767&this[e],u=this[e++]>>15,c=a*l+u*s;l=s*l+((32767&c)<<15)+n[r]+(1073741823&i),i=(l>>>30)+(c>>>15)+a*u+(i>>>30),n[r++]=1073741823&l}return i}function u(e,t,n,r,i,o){for(var s=16383&t,a=t>>14;--o>=0;){var l=16383&this[e],u=this[e++]>>14,c=a*l+u*s;l=s*l+((16383&c)<<14)+n[r]+i,i=(l>>28)+(c>>14)+a*u,n[r++]=268435455&l}return i}var c="undefined"!=typeof navigator;c&&"Microsoft Internet Explorer"==navigator.appName?(o.prototype.am=l,n=30):c&&"Netscape"!=navigator.appName?(o.prototype.am=a,n=26):(o.prototype.am=u,n=28),o.prototype.DB=n,o.prototype.DM=(1<<n)-1,o.prototype.DV=1<<n;var h=52;o.prototype.FV=Math.pow(2,52),o.prototype.F1=52-n,o.prototype.F2=2*n-52;var f="0123456789abcdefghijklmnopqrstuvwxyz",p=new Array,d,m;for(d="0".charCodeAt(0),m=0;m<=9;++m)p[d++]=m;for(d="a".charCodeAt(0),m=10;m<36;++m)p[d++]=m;for(d="A".charCodeAt(0),m=10;m<36;++m)p[d++]=m;function g(e){return f.charAt(e)}function y(e,t){var n=p[e.charCodeAt(t)];return null==n?-1:n}function v(e){for(var t=this.t-1;t>=0;--t)e[t]=this[t];e.t=this.t,e.s=this.s}function b(e){this.t=1,this.s=e<0?-1:0,e>0?this[0]=e:e<-1?this[0]=e+this.DV:this.t=0}function _(e){var t=s();return t.fromInt(e),t}function w(e,t){var n;if(16==t)n=4;else if(8==t)n=3;else if(256==t)n=8;else if(2==t)n=1;else if(32==t)n=5;else{if(4!=t)return void this.fromRadix(e,t);n=2}this.t=0,this.s=0;for(var r=e.length,i=!1,s=0;--r>=0;){var a=8==n?255&e[r]:y(e,r);a<0?"-"==e.charAt(r)&&(i=!0):(i=!1,0==s?this[this.t++]=a:s+n>this.DB?(this[this.t-1]|=(a&(1<<this.DB-s)-1)<<s,this[this.t++]=a>>this.DB-s):this[this.t-1]|=a<<s,s+=n,s>=this.DB&&(s-=this.DB))}8==n&&0!=(128&e[0])&&(this.s=-1,s>0&&(this[this.t-1]|=(1<<this.DB-s)-1<<s)),this.clamp(),i&&o.ZERO.subTo(this,this)}function k(){for(var e=this.s&this.DM;this.t>0&&this[this.t-1]==e;)--this.t}function E(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)return this.toRadix(e);t=2}var n=(1<<t)-1,r,i=!1,o="",s=this.t,a=this.DB-s*this.DB%t;if(s-- >0)for(a<this.DB&&(r=this[s]>>a)>0&&(i=!0,o=g(r));s>=0;)a<t?(r=(this[s]&(1<<a)-1)<<t-a,r|=this[--s]>>(a+=this.DB-t)):(r=this[s]>>(a-=t)&n,a<=0&&(a+=this.DB,--s)),r>0&&(i=!0),i&&(o+=g(r));return i?o:"0"}function S(){var e=s();return o.ZERO.subTo(this,e),e}function x(){return this.s<0?this.negate():this}function C(e){var t=this.s-e.s;if(0!=t)return t;var n=this.t;if(t=n-e.t,0!=t)return this.s<0?-t:t;for(;--n>=0;)if(0!=(t=this[n]-e[n]))return t;return 0}function A(e){var t=1,n;return 0!=(n=e>>>16)&&(e=n,t+=16),0!=(n=e>>8)&&(e=n,t+=8),0!=(n=e>>4)&&(e=n,t+=4),0!=(n=e>>2)&&(e=n,t+=2),0!=(n=e>>1)&&(e=n,t+=1),t}function T(){return this.t<=0?0:this.DB*(this.t-1)+A(this[this.t-1]^this.s&this.DM)}function I(e,t){var n;for(n=this.t-1;n>=0;--n)t[n+e]=this[n];for(n=e-1;n>=0;--n)t[n]=0;t.t=this.t+e,t.s=this.s}function j(e,t){for(var n=e;n<this.t;++n)t[n-e]=this[n];t.t=Math.max(this.t-e,0),t.s=this.s}function R(e,t){var n=e%this.DB,r=this.DB-n,i=(1<<r)-1,o=Math.floor(e/this.DB),s=this.s<<n&this.DM,a;for(a=this.t-1;a>=0;--a)t[a+o+1]=this[a]>>r|s,s=(this[a]&i)<<n;for(a=o-1;a>=0;--a)t[a]=0;t[o]=s,t.t=this.t+o+1,t.s=this.s,t.clamp()}function B(e,t){t.s=this.s;var n=Math.floor(e/this.DB);if(n>=this.t)t.t=0;else{var r=e%this.DB,i=this.DB-r,o=(1<<r)-1;t[0]=this[n]>>r;for(var s=n+1;s<this.t;++s)t[s-n-1]|=(this[s]&o)<<i,t[s-n]=this[s]>>r;r>0&&(t[this.t-n-1]|=(this.s&o)<<i),t.t=this.t-n,t.clamp()}}function O(e,t){for(var n=0,r=0,i=Math.min(e.t,this.t);n<i;)r+=this[n]-e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r-=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r-=e[n],t[n++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t[n++]=this.DV+r:r>0&&(t[n++]=r),t.t=n,t.clamp()}function P(e,t){var n=this.abs(),r=e.abs(),i=n.t;for(t.t=i+r.t;--i>=0;)t[i]=0;for(i=0;i<r.t;++i)t[i+n.t]=n.am(0,r[i],t,i,0,n.t);t.s=0,t.clamp(),this.s!=e.s&&o.ZERO.subTo(t,t)}function N(e){for(var t=this.abs(),n=e.t=2*t.t;--n>=0;)e[n]=0;for(n=0;n<t.t-1;++n){var r=t.am(n,t[n],e,2*n,0,1);(e[n+t.t]+=t.am(n+1,2*t[n],e,2*n+1,r,t.t-n-1))>=t.DV&&(e[n+t.t]-=t.DV,e[n+t.t+1]=1)}e.t>0&&(e[e.t-1]+=t.am(n,t[n],e,2*n,0,1)),e.s=0,e.clamp()}function D(e,t,n){var r=e.abs();if(!(r.t<=0)){var i=this.abs();if(i.t<r.t)return null!=t&&t.fromInt(0),void(null!=n&&this.copyTo(n));null==n&&(n=s());var a=s(),l=this.s,u=e.s,c=this.DB-A(r[r.t-1]);c>0?(r.lShiftTo(c,a),i.lShiftTo(c,n)):(r.copyTo(a),i.copyTo(n));var h=a.t,f=a[h-1];if(0!=f){var p=f*(1<<this.F1)+(h>1?a[h-2]>>this.F2:0),d=this.FV/p,m=(1<<this.F1)/p,g=1<<this.F2,y=n.t,v=y-h,b=null==t?s():t;for(a.dlShiftTo(v,b),n.compareTo(b)>=0&&(n[n.t++]=1,n.subTo(b,n)),o.ONE.dlShiftTo(h,b),b.subTo(a,a);a.t<h;)a[a.t++]=0;for(;--v>=0;){var _=n[--y]==f?this.DM:Math.floor(n[y]*d+(n[y-1]+g)*m);if((n[y]+=a.am(0,_,n,v,0,h))<_)for(a.dlShiftTo(v,b),n.subTo(b,n);n[y]<--_;)n.subTo(b,n)}null!=t&&(n.drShiftTo(h,t),l!=u&&o.ZERO.subTo(t,t)),n.t=h,n.clamp(),c>0&&n.rShiftTo(c,n),l<0&&o.ZERO.subTo(n,n)}}}function M(e){var t=s();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(o.ZERO)>0&&e.subTo(t,t),t}function F(e){this.m=e}function L(e){return e.s<0||e.compareTo(this.m)>=0?e.mod(this.m):e}function U(e){return e}function q(e){e.divRemTo(this.m,null,e)}function z(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function K(e,t){e.squareTo(t),this.reduce(t)}function H(){if(this.t<1)return 0;var e=this[0];if(0==(1&e))return 0;var t=3&e;return t=t*(2-(15&e)*t)&15,t=t*(2-(255&e)*t)&255,t=t*(2-((65535&e)*t&65535))&65535,t=t*(2-e*t%this.DV)%this.DV,t>0?this.DV-t:-t}function V(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function $(e){var t=s();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(o.ZERO)>0&&this.m.subTo(t,t),t}function W(e){var t=s();return e.copyTo(t),this.reduce(t),t}function G(e){for(;e.t<=this.mt2;)e[e.t++]=0;for(var t=0;t<this.m.t;++t){var n=32767&e[t],r=n*this.mpl+((n*this.mph+(e[t]>>15)*this.mpl&this.um)<<15)&e.DM;for(n=t+this.m.t,e[n]+=this.m.am(0,r,e,t,0,this.m.t);e[n]>=e.DV;)e[n]-=e.DV,e[++n]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)}function Y(e,t){e.squareTo(t),this.reduce(t)}function Z(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function J(){return 0==(this.t>0?1&this[0]:this.s)}function Q(e,t){if(e>4294967295||e<1)return o.ONE;var n=s(),r=s(),i=t.convert(this),a=A(e)-1;for(i.copyTo(n);--a>=0;)if(t.sqrTo(n,r),(e&1<<a)>0)t.mulTo(r,i,n);else{var l=n;n=r,r=l}return t.revert(n)}function X(e,t){var n;return n=e<256||t.isEven()?new F(t):new V(t),this.exp(e,n)}function ee(){var e=s();return this.copyTo(e),e}function te(){if(this.s<0){if(1==this.t)return this[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this[0];if(0==this.t)return 0}return(this[1]&(1<<32-this.DB)-1)<<this.DB|this[0]}function ne(){return 0==this.t?this.s:this[0]<<24>>24}function re(){return 0==this.t?this.s:this[0]<<16>>16}function ie(e){return Math.floor(Math.LN2*this.DB/Math.log(e))}function oe(){return this.s<0?-1:this.t<=0||1==this.t&&this[0]<=0?0:1}function se(e){if(null==e&&(e=10),0==this.signum()||e<2||e>36)return"0";var t=this.chunkSize(e),n=Math.pow(e,t),r=_(n),i=s(),o=s(),a="";for(this.divRemTo(r,i,o);i.signum()>0;)a=(n+o.intValue()).toString(e).substr(1)+a,i.divRemTo(r,i,o);return o.intValue().toString(e)+a}function ae(e,t){this.fromInt(0),null==t&&(t=10);for(var n=this.chunkSize(t),r=Math.pow(t,n),i=!1,s=0,a=0,l=0;l<e.length;++l){var u=y(e,l);u<0?"-"==e.charAt(l)&&0==this.signum()&&(i=!0):(a=t*a+u,++s>=n&&(this.dMultiply(r),this.dAddOffset(a,0),s=0,a=0))}s>0&&(this.dMultiply(Math.pow(t,s)),this.dAddOffset(a,0)),i&&o.ZERO.subTo(this,this)}function le(e,t,n){if("number"==typeof t)if(e<2)this.fromInt(1);else for(this.fromNumber(e,n),this.testBit(e-1)||this.bitwiseTo(o.ONE.shiftLeft(e-1),ge,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(t);)this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(o.ONE.shiftLeft(e-1),this);else{var r=new Array,i=7&e;r.length=1+(e>>3),t.nextBytes(r),i>0?r[0]&=(1<<i)-1:r[0]=0,this.fromString(r,256)}}function ue(){var e=this.t,t=new Array;t[0]=this.s;var n=this.DB-e*this.DB%8,r,i=0;if(e-- >0)for(n<this.DB&&(r=this[e]>>n)!=(this.s&this.DM)>>n&&(t[i++]=r|this.s<<this.DB-n);e>=0;)n<8?(r=(this[e]&(1<<n)-1)<<8-n,r|=this[--e]>>(n+=this.DB-8)):(r=this[e]>>(n-=8)&255,n<=0&&(n+=this.DB,--e)),0!=(128&r)&&(r|=-256),0==i&&(128&this.s)!=(128&r)&&++i,(i>0||r!=this.s)&&(t[i++]=r);return t}function ce(e){return 0==this.compareTo(e)}function he(e){return this.compareTo(e)<0?this:e}function fe(e){return this.compareTo(e)>0?this:e}function pe(e,t,n){var r,i,o=Math.min(e.t,this.t);for(r=0;r<o;++r)n[r]=t(this[r],e[r]);if(e.t<this.t){for(i=e.s&this.DM,r=o;r<this.t;++r)n[r]=t(this[r],i);n.t=this.t}else{for(i=this.s&this.DM,r=o;r<e.t;++r)n[r]=t(i,e[r]);n.t=e.t}n.s=t(this.s,e.s),n.clamp()}function de(e,t){return e&t}function me(e){var t=s();return this.bitwiseTo(e,de,t),t}function ge(e,t){return e|t}function ye(e){var t=s();return this.bitwiseTo(e,ge,t),t}function ve(e,t){return e^t}function be(e){var t=s();return this.bitwiseTo(e,ve,t),t}function _e(e,t){return e&~t}function we(e){var t=s();return this.bitwiseTo(e,_e,t),t}function ke(){for(var e=s(),t=0;t<this.t;++t)e[t]=this.DM&~this[t];return e.t=this.t,e.s=~this.s,e}function Ee(e){var t=s();return e<0?this.rShiftTo(-e,t):this.lShiftTo(e,t),t}function Se(e){var t=s();return e<0?this.lShiftTo(-e,t):this.rShiftTo(e,t),t}function xe(e){if(0==e)return-1;var t=0;return 0==(65535&e)&&(e>>=16,t+=16),0==(255&e)&&(e>>=8,t+=8),0==(15&e)&&(e>>=4,t+=4),0==(3&e)&&(e>>=2,t+=2),0==(1&e)&&++t,t}function Ce(){for(var e=0;e<this.t;++e)if(0!=this[e])return e*this.DB+xe(this[e]);return this.s<0?this.t*this.DB:-1}function Ae(e){for(var t=0;0!=e;)e&=e-1,++t;return t}function Te(){for(var e=0,t=this.s&this.DM,n=0;n<this.t;++n)e+=Ae(this[n]^t);return e}function Ie(e){var t=Math.floor(e/this.DB);return t>=this.t?0!=this.s:0!=(this[t]&1<<e%this.DB)}function je(e,t){var n=o.ONE.shiftLeft(e);return this.bitwiseTo(n,t,n),n}function Re(e){return this.changeBit(e,ge)}function Be(e){return this.changeBit(e,_e)}function Oe(e){return this.changeBit(e,ve)}function Pe(e,t){for(var n=0,r=0,i=Math.min(e.t,this.t);n<i;)r+=this[n]+e[n],t[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r+=e.s;n<this.t;)r+=this[n],t[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r+=e[n],t[n++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t[n++]=r:r<-1&&(t[n++]=this.DV+r),t.t=n,t.clamp()}function Ne(e){var t=s();return this.addTo(e,t),t}function De(e){var t=s();return this.subTo(e,t),t}function Me(e){var t=s();return this.multiplyTo(e,t),t}function Fe(){var e=s();return this.squareTo(e),e}function Le(e){var t=s();return this.divRemTo(e,t,null),t}function Ue(e){var t=s();return this.divRemTo(e,null,t),t}function qe(e){var t=s(),n=s();return this.divRemTo(e,t,n),new Array(t,n)}function ze(e){this[this.t]=this.am(0,e-1,this,0,0,this.t),++this.t,this.clamp()}function Ke(e,t){if(0!=e){for(;this.t<=t;)this[this.t++]=0;for(this[t]+=e;this[t]>=this.DV;)this[t]-=this.DV,++t>=this.t&&(this[this.t++]=0),++this[t]}}function He(){}function Ve(e){return e}function $e(e,t,n){e.multiplyTo(t,n)}function We(e,t){e.squareTo(t)}function Ge(e){return this.exp(e,new He)}function Ye(e,t,n){var r=Math.min(this.t+e.t,t),i;for(n.s=0,n.t=r;r>0;)n[--r]=0;for(i=n.t-this.t;r<i;++r)n[r+this.t]=this.am(0,e[r],n,r,0,this.t);for(i=Math.min(e.t,t);r<i;++r)this.am(0,e[r],n,r,0,t-r);n.clamp()}function Ze(e,t,n){--t;var r=n.t=this.t+e.t-t;for(n.s=0;--r>=0;)n[r]=0;for(r=Math.max(t-this.t,0);r<e.t;++r)n[this.t+r-t]=this.am(t-r,e[r],n,0,0,this.t+r-t);n.clamp(),n.drShiftTo(1,n)}function Je(e){this.r2=s(),this.q3=s(),o.ONE.dlShiftTo(2*e.t,this.r2),this.mu=this.r2.divide(e),this.m=e}function Qe(e){if(e.s<0||e.t>2*this.m.t)return e.mod(this.m);if(e.compareTo(this.m)<0)return e;var t=s();return e.copyTo(t),this.reduce(t),t}function Xe(e){return e}function et(e){for(e.drShiftTo(this.m.t-1,this.r2),e.t>this.m.t+1&&(e.t=this.m.t+1,e.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);e.compareTo(this.r2)<0;)e.dAddOffset(1,this.m.t+1);for(e.subTo(this.r2,e);e.compareTo(this.m)>=0;)e.subTo(this.m,e)}function tt(e,t){e.squareTo(t),this.reduce(t)}function nt(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function rt(e,t){var n=e.bitLength(),r,i=_(1),o;if(n<=0)return i;r=n<18?1:n<48?3:n<144?4:n<768?5:6,o=n<8?new F(t):t.isEven()?new Je(t):new V(t);var a=new Array,l=3,u=r-1,c=(1<<r)-1;if(a[1]=o.convert(this),r>1){var h=s();for(o.sqrTo(a[1],h);l<=c;)a[l]=s(),o.mulTo(h,a[l-2],a[l]),l+=2}var f=e.t-1,p,d=!0,m=s(),g;for(n=A(e[f])-1;f>=0;){for(n>=u?p=e[f]>>n-u&c:(p=(e[f]&(1<<n+1)-1)<<u-n,f>0&&(p|=e[f-1]>>this.DB+n-u)),l=r;0==(1&p);)p>>=1,--l;if((n-=l)<0&&(n+=this.DB,--f),d)a[p].copyTo(i),d=!1;else{for(;l>1;)o.sqrTo(i,m),o.sqrTo(m,i),l-=2;l>0?o.sqrTo(i,m):(g=i,i=m,m=g),o.mulTo(m,a[p],i)}for(;f>=0&&0==(e[f]&1<<n);)o.sqrTo(i,m),g=i,i=m,m=g,--n<0&&(n=this.DB-1,--f)}return o.revert(i)}function it(e){var t=this.s<0?this.negate():this.clone(),n=e.s<0?e.negate():e.clone();if(t.compareTo(n)<0){var r=t;t=n,n=r}var i=t.getLowestSetBit(),o=n.getLowestSetBit();if(o<0)return t;for(i<o&&(o=i),o>0&&(t.rShiftTo(o,t),n.rShiftTo(o,n));t.signum()>0;)(i=t.getLowestSetBit())>0&&t.rShiftTo(i,t),(i=n.getLowestSetBit())>0&&n.rShiftTo(i,n),t.compareTo(n)>=0?(t.subTo(n,t),t.rShiftTo(1,t)):(n.subTo(t,n),n.rShiftTo(1,n));return o>0&&n.lShiftTo(o,n),n}function ot(e){if(e<=0)return 0;var t=this.DV%e,n=this.s<0?e-1:0;if(this.t>0)if(0==t)n=this[0]%e;else for(var r=this.t-1;r>=0;--r)n=(t*n+this[r])%e;return n}function st(e){var t=e.isEven();if(this.isEven()&&t||0==e.signum())return o.ZERO;for(var n=e.clone(),r=this.clone(),i=_(1),s=_(0),a=_(0),l=_(1);0!=n.signum();){for(;n.isEven();)n.rShiftTo(1,n),t?(i.isEven()&&s.isEven()||(i.addTo(this,i),s.subTo(e,s)),i.rShiftTo(1,i)):s.isEven()||s.subTo(e,s),s.rShiftTo(1,s);for(;r.isEven();)r.rShiftTo(1,r),t?(a.isEven()&&l.isEven()||(a.addTo(this,a),l.subTo(e,l)),a.rShiftTo(1,a)):l.isEven()||l.subTo(e,l),l.rShiftTo(1,l);n.compareTo(r)>=0?(n.subTo(r,n),t&&i.subTo(a,i),s.subTo(l,s)):(r.subTo(n,r),t&&a.subTo(i,a),l.subTo(s,l))}return 0!=r.compareTo(o.ONE)?o.ZERO:l.compareTo(e)>=0?l.subtract(e):l.signum()<0?(l.addTo(e,l),l.signum()<0?l.add(e):l):l}F.prototype.convert=L,F.prototype.revert=U,F.prototype.reduce=q,F.prototype.mulTo=z,F.prototype.sqrTo=K,V.prototype.convert=$,V.prototype.revert=W,V.prototype.reduce=G,V.prototype.mulTo=Z,V.prototype.sqrTo=Y,o.prototype.copyTo=v,o.prototype.fromInt=b,o.prototype.fromString=w,o.prototype.clamp=k,o.prototype.dlShiftTo=I,o.prototype.drShiftTo=j,o.prototype.lShiftTo=R,o.prototype.rShiftTo=B,o.prototype.subTo=O,o.prototype.multiplyTo=P,o.prototype.squareTo=N,o.prototype.divRemTo=D,o.prototype.invDigit=H,o.prototype.isEven=J,o.prototype.exp=Q,o.prototype.toString=E,o.prototype.negate=S,o.prototype.abs=x,o.prototype.compareTo=C,o.prototype.bitLength=T,o.prototype.mod=M,o.prototype.modPowInt=X,o.ZERO=_(0),o.ONE=_(1),He.prototype.convert=Ve,He.prototype.revert=Ve,He.prototype.mulTo=$e,He.prototype.sqrTo=We,Je.prototype.convert=Qe,Je.prototype.revert=Xe,Je.prototype.reduce=et,Je.prototype.mulTo=nt,Je.prototype.sqrTo=tt;var at=[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],lt=(1<<26)/at[at.length-1],ut,ct,ht;function ft(e){var t,n=this.abs();if(1==n.t&&n[0]<=at[at.length-1]){for(t=0;t<at.length;++t)if(n[0]==at[t])return!0;return!1}if(n.isEven())return!1;for(t=1;t<at.length;){for(var r=at[t],i=t+1;i<at.length&&r<lt;)r*=at[i++];for(r=n.modInt(r);t<i;)if(r%at[t++]==0)return!1}return n.millerRabin(e)}function pt(e){var t=this.subtract(o.ONE),n=t.getLowestSetBit();if(n<=0)return!1;var r=t.shiftRight(n);e=e+1>>1,e>at.length&&(e=at.length);for(var i=s(),a=0;a<e;++a){i.fromInt(at[Math.floor(Math.random()*at.length)]);var l=i.modPow(r,this);if(0!=l.compareTo(o.ONE)&&0!=l.compareTo(t)){for(var u=1;u++<n&&0!=l.compareTo(t);)if(l=l.modPowInt(2,this),0==l.compareTo(o.ONE))return!1;if(0!=l.compareTo(t))return!1}}return!0}function dt(e){ct[ht++]^=255&e,ct[ht++]^=e>>8&255,ct[ht++]^=e>>16&255,ct[ht++]^=e>>24&255,ht>=Ct&&(ht-=Ct)}function mt(){dt((new Date).getTime())}if(o.prototype.chunkSize=ie,o.prototype.toRadix=se,o.prototype.fromRadix=ae,o.prototype.fromNumber=le,o.prototype.bitwiseTo=pe,o.prototype.changeBit=je,o.prototype.addTo=Pe,o.prototype.dMultiply=ze,o.prototype.dAddOffset=Ke,o.prototype.multiplyLowerTo=Ye,o.prototype.multiplyUpperTo=Ze,o.prototype.modInt=ot,o.prototype.millerRabin=pt,o.prototype.clone=ee,o.prototype.intValue=te,o.prototype.byteValue=ne,o.prototype.shortValue=re,o.prototype.signum=oe,o.prototype.toByteArray=ue,o.prototype.equals=ce,o.prototype.min=he,o.prototype.max=fe,o.prototype.and=me,o.prototype.or=ye,o.prototype.xor=be,o.prototype.andNot=we,o.prototype.not=ke,o.prototype.shiftLeft=Ee,o.prototype.shiftRight=Se,o.prototype.getLowestSetBit=Ce,o.prototype.bitCount=Te,o.prototype.testBit=Ie,o.prototype.setBit=Re,o.prototype.clearBit=Be,o.prototype.flipBit=Oe,o.prototype.add=Ne,o.prototype.subtract=De,o.prototype.multiply=Me,o.prototype.divide=Le,o.prototype.remainder=Ue,o.prototype.divideAndRemainder=qe,o.prototype.modPow=rt,o.prototype.modInverse=st,o.prototype.pow=Ge,o.prototype.gcd=it,o.prototype.isProbablePrime=ft,o.prototype.square=Fe,o.prototype.Barrett=Je,null==ct){var gt;if(ct=new Array,ht=0,"undefined"!=typeof window&&window.crypto)if(window.crypto.getRandomValues){var yt=new Uint8Array(32);for(window.crypto.getRandomValues(yt),gt=0;gt<32;++gt)ct[ht++]=yt[gt]}else if("Netscape"==navigator.appName&&navigator.appVersion<"5"){var vt=window.crypto.random(32);for(gt=0;gt<vt.length;++gt)ct[ht++]=255&vt.charCodeAt(gt)}for(;ht<Ct;)gt=Math.floor(65536*Math.random()),ct[ht++]=gt>>>8,ct[ht++]=255&gt;ht=0,mt()}function bt(){if(null==ut){for(mt(),ut=xt(),ut.init(ct),ht=0;ht<ct.length;++ht)ct[ht]=0;ht=0}return ut.next()}function _t(e){var t;for(t=0;t<e.length;++t)e[t]=bt()}function wt(){}function kt(){this.i=0,this.j=0,this.S=new Array}function Et(e){var t,n,r;for(t=0;t<256;++t)this.S[t]=t;for(n=0,t=0;t<256;++t)n=n+this.S[t]+e[t%e.length]&255,r=this.S[t],this.S[t]=this.S[n],this.S[n]=r;this.i=0,this.j=0}function St(){var e;return this.i=this.i+1&255,this.j=this.j+this.S[this.i]&255,e=this.S[this.i],this.S[this.i]=this.S[this.j],this.S[this.j]=e,this.S[e+this.S[this.i]&255]}function xt(){return new kt}wt.prototype.nextBytes=_t,kt.prototype.init=Et,kt.prototype.next=St;var Ct=256;o.SecureRandom=wt,o.BigInteger=o,t=e.exports=o}).call(this)},function(e,t,n){!function(e){"use strict";var t=function(e){var t,n=new Float64Array(16);if(e)for(t=0;t<e.length;t++)n[t]=e[t];return n},r=function(){throw new Error("no PRNG")},i=new Uint8Array(16),o=new Uint8Array(32);o[0]=9;var s=t(),a=t([1]),l=t([56129,1]),u=t([30883,4953,19914,30187,55467,16705,2637,112,59544,30585,16505,36039,65139,11119,27886,20995]),c=t([61785,9906,39828,60374,45398,33411,5274,224,53552,61171,33010,6542,64743,22239,55772,9222]),h=t([54554,36645,11616,51542,42930,38181,51040,26924,56412,64982,57905,49316,21502,52590,14035,8553]),f=t([26200,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214]),p=t([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function d(e,t,n,r){e[t]=n>>24&255,e[t+1]=n>>16&255,e[t+2]=n>>8&255,e[t+3]=255&n,e[t+4]=r>>24&255,e[t+5]=r>>16&255,e[t+6]=r>>8&255,e[t+7]=255&r}function m(e,t,n,r,i){var o,s=0;for(o=0;o<i;o++)s|=e[t+o]^n[r+o];return(1&s-1>>>8)-1}function g(e,t,n,r){return m(e,t,n,r,16)}function y(e,t,n,r){return m(e,t,n,r,32)}function v(e,t,n,r){for(var i=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,o=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,a=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,f=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,d=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,m=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,v=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,b=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=i,w=o,k=s,E=a,S=l,x=u,C=c,A=h,T=f,I=p,j=d,R=m,B=g,O=y,P=v,N=b,D,M=0;M<20;M+=2)D=_+B|0,S^=D<<7|D>>>25,D=S+_|0,T^=D<<9|D>>>23,D=T+S|0,B^=D<<13|D>>>19,D=B+T|0,_^=D<<18|D>>>14,D=x+w|0,I^=D<<7|D>>>25,D=I+x|0,O^=D<<9|D>>>23,D=O+I|0,w^=D<<13|D>>>19,D=w+O|0,x^=D<<18|D>>>14,D=j+C|0,P^=D<<7|D>>>25,D=P+j|0,k^=D<<9|D>>>23,D=k+P|0,C^=D<<13|D>>>19,D=C+k|0,j^=D<<18|D>>>14,D=N+R|0,E^=D<<7|D>>>25,D=E+N|0,A^=D<<9|D>>>23,D=A+E|0,R^=D<<13|D>>>19,D=R+A|0,N^=D<<18|D>>>14,D=_+E|0,w^=D<<7|D>>>25,D=w+_|0,k^=D<<9|D>>>23,D=k+w|0,E^=D<<13|D>>>19,D=E+k|0,_^=D<<18|D>>>14,D=x+S|0,C^=D<<7|D>>>25,D=C+x|0,A^=D<<9|D>>>23,D=A+C|0,S^=D<<13|D>>>19,D=S+A|0,x^=D<<18|D>>>14,D=j+I|0,R^=D<<7|D>>>25,D=R+j|0,T^=D<<9|D>>>23,D=T+R|0,I^=D<<13|D>>>19,D=I+T|0,j^=D<<18|D>>>14,D=N+P|0,B^=D<<7|D>>>25,D=B+N|0,O^=D<<9|D>>>23,D=O+B|0,P^=D<<13|D>>>19,D=P+O|0,N^=D<<18|D>>>14;_=_+i|0,w=w+o|0,k=k+s|0,E=E+a|0,S=S+l|0,x=x+u|0,C=C+c|0,A=A+h|0,T=T+f|0,I=I+p|0,j=j+d|0,R=R+m|0,B=B+g|0,O=O+y|0,P=P+v|0,N=N+b|0,e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=w>>>0&255,e[5]=w>>>8&255,e[6]=w>>>16&255,e[7]=w>>>24&255,e[8]=k>>>0&255,e[9]=k>>>8&255,e[10]=k>>>16&255,e[11]=k>>>24&255,e[12]=E>>>0&255,e[13]=E>>>8&255,e[14]=E>>>16&255,e[15]=E>>>24&255,e[16]=S>>>0&255,e[17]=S>>>8&255,e[18]=S>>>16&255,e[19]=S>>>24&255,e[20]=x>>>0&255,e[21]=x>>>8&255,e[22]=x>>>16&255,e[23]=x>>>24&255,e[24]=C>>>0&255,e[25]=C>>>8&255,e[26]=C>>>16&255,e[27]=C>>>24&255,e[28]=A>>>0&255,e[29]=A>>>8&255,e[30]=A>>>16&255,e[31]=A>>>24&255,e[32]=T>>>0&255,e[33]=T>>>8&255,e[34]=T>>>16&255,e[35]=T>>>24&255,e[36]=I>>>0&255,e[37]=I>>>8&255,e[38]=I>>>16&255,e[39]=I>>>24&255,e[40]=j>>>0&255,e[41]=j>>>8&255,e[42]=j>>>16&255,e[43]=j>>>24&255,e[44]=R>>>0&255,e[45]=R>>>8&255,e[46]=R>>>16&255,e[47]=R>>>24&255,e[48]=B>>>0&255,e[49]=B>>>8&255,e[50]=B>>>16&255,e[51]=B>>>24&255,e[52]=O>>>0&255,e[53]=O>>>8&255,e[54]=O>>>16&255,e[55]=O>>>24&255,e[56]=P>>>0&255,e[57]=P>>>8&255,e[58]=P>>>16&255,e[59]=P>>>24&255,e[60]=N>>>0&255,e[61]=N>>>8&255,e[62]=N>>>16&255,e[63]=N>>>24&255}function b(e,t,n,r){for(var i=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,o=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,a=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,f=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,d=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,m=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,v=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,b=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=i,w=o,k=s,E=a,S=l,x=u,C=c,A=h,T=f,I=p,j=d,R=m,B=g,O=y,P=v,N=b,D,M=0;M<20;M+=2)D=_+B|0,S^=D<<7|D>>>25,D=S+_|0,T^=D<<9|D>>>23,D=T+S|0,B^=D<<13|D>>>19,D=B+T|0,_^=D<<18|D>>>14,D=x+w|0,I^=D<<7|D>>>25,D=I+x|0,O^=D<<9|D>>>23,D=O+I|0,w^=D<<13|D>>>19,D=w+O|0,x^=D<<18|D>>>14,D=j+C|0,P^=D<<7|D>>>25,D=P+j|0,k^=D<<9|D>>>23,D=k+P|0,C^=D<<13|D>>>19,D=C+k|0,j^=D<<18|D>>>14,D=N+R|0,E^=D<<7|D>>>25,D=E+N|0,A^=D<<9|D>>>23,D=A+E|0,R^=D<<13|D>>>19,D=R+A|0,N^=D<<18|D>>>14,D=_+E|0,w^=D<<7|D>>>25,D=w+_|0,k^=D<<9|D>>>23,D=k+w|0,E^=D<<13|D>>>19,D=E+k|0,_^=D<<18|D>>>14,D=x+S|0,C^=D<<7|D>>>25,D=C+x|0,A^=D<<9|D>>>23,D=A+C|0,S^=D<<13|D>>>19,D=S+A|0,x^=D<<18|D>>>14,D=j+I|0,R^=D<<7|D>>>25,D=R+j|0,T^=D<<9|D>>>23,D=T+R|0,I^=D<<13|D>>>19,D=I+T|0,j^=D<<18|D>>>14,D=N+P|0,B^=D<<7|D>>>25,D=B+N|0,O^=D<<9|D>>>23,D=O+B|0,P^=D<<13|D>>>19,D=P+O|0,N^=D<<18|D>>>14;e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=x>>>0&255,e[5]=x>>>8&255,e[6]=x>>>16&255,e[7]=x>>>24&255,e[8]=j>>>0&255,e[9]=j>>>8&255,e[10]=j>>>16&255,e[11]=j>>>24&255,e[12]=N>>>0&255,e[13]=N>>>8&255,e[14]=N>>>16&255,e[15]=N>>>24&255,e[16]=C>>>0&255,e[17]=C>>>8&255,e[18]=C>>>16&255,e[19]=C>>>24&255,e[20]=A>>>0&255,e[21]=A>>>8&255,e[22]=A>>>16&255,e[23]=A>>>24&255,e[24]=T>>>0&255,e[25]=T>>>8&255,e[26]=T>>>16&255,e[27]=T>>>24&255,e[28]=I>>>0&255,e[29]=I>>>8&255,e[30]=I>>>16&255,e[31]=I>>>24&255}function _(e,t,n,r){v(e,t,n,r)}function w(e,t,n,r){b(e,t,n,r)}var k=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function E(e,t,n,r,i,o,s){var a=new Uint8Array(16),l=new Uint8Array(64),u,c;for(c=0;c<16;c++)a[c]=0;for(c=0;c<8;c++)a[c]=o[c];for(;i>=64;){for(_(l,a,s,k),c=0;c<64;c++)e[t+c]=n[r+c]^l[c];for(u=1,c=8;c<16;c++)u=u+(255&a[c])|0,a[c]=255&u,u>>>=8;i-=64,t+=64,r+=64}if(i>0)for(_(l,a,s,k),c=0;c<i;c++)e[t+c]=n[r+c]^l[c];return 0}function S(e,t,n,r,i){var o=new Uint8Array(16),s=new Uint8Array(64),a,l;for(l=0;l<16;l++)o[l]=0;for(l=0;l<8;l++)o[l]=r[l];for(;n>=64;){for(_(s,o,i,k),l=0;l<64;l++)e[t+l]=s[l];for(a=1,l=8;l<16;l++)a=a+(255&o[l])|0,o[l]=255&a,a>>>=8;n-=64,t+=64}if(n>0)for(_(s,o,i,k),l=0;l<n;l++)e[t+l]=s[l];return 0}function x(e,t,n,r,i){var o=new Uint8Array(32);w(o,r,i,k);for(var s=new Uint8Array(8),a=0;a<8;a++)s[a]=r[a+16];return S(e,t,n,s,o)}function C(e,t,n,r,i,o,s){var a=new Uint8Array(32);w(a,o,s,k);for(var l=new Uint8Array(8),u=0;u<8;u++)l[u]=o[u+16];return E(e,t,n,r,i,l,a)}var A=function(e){var t,n,r,i,o,s,a,l;this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.leftover=0,this.fin=0,t=255&e[0]|(255&e[1])<<8,this.r[0]=8191&t,n=255&e[2]|(255&e[3])<<8,this.r[1]=8191&(t>>>13|n<<3),r=255&e[4]|(255&e[5])<<8,this.r[2]=7939&(n>>>10|r<<6),i=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(r>>>7|i<<9),o=255&e[8]|(255&e[9])<<8,this.r[4]=255&(i>>>4|o<<12),this.r[5]=o>>>1&8190,s=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(o>>>14|s<<2),a=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(s>>>11|a<<5),l=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(a>>>8|l<<8),this.r[9]=l>>>5&127,this.pad[0]=255&e[16]|(255&e[17])<<8,this.pad[1]=255&e[18]|(255&e[19])<<8,this.pad[2]=255&e[20]|(255&e[21])<<8,this.pad[3]=255&e[22]|(255&e[23])<<8,this.pad[4]=255&e[24]|(255&e[25])<<8,this.pad[5]=255&e[26]|(255&e[27])<<8,this.pad[6]=255&e[28]|(255&e[29])<<8,this.pad[7]=255&e[30]|(255&e[31])<<8};function T(e,t,n,r,i,o){var s=new A(o);return s.update(n,r,i),s.finish(e,t),0}function I(e,t,n,r,i,o){var s=new Uint8Array(16);return T(s,0,n,r,i,o),g(e,t,s,0)}function j(e,t,n,r,i){var o;if(n<32)return-1;for(C(e,0,t,0,n,r,i),T(e,16,e,32,n-32,e),o=0;o<16;o++)e[o]=0;return 0}function R(e,t,n,r,i){var o,s=new Uint8Array(32);if(n<32)return-1;if(x(s,0,32,r,i),0!==I(t,16,t,32,n-32,s))return-1;for(C(e,0,t,0,n,r,i),o=0;o<32;o++)e[o]=0;return 0}function B(e,t){var n;for(n=0;n<16;n++)e[n]=0|t[n]}function O(e){var t,n,r=1;for(t=0;t<16;t++)n=e[t]+r+65535,r=Math.floor(n/65536),e[t]=n-65536*r;e[0]+=r-1+37*(r-1)}function P(e,t,n){for(var r,i=~(n-1),o=0;o<16;o++)r=i&(e[o]^t[o]),e[o]^=r,t[o]^=r}function N(e,n){var r,i,o,s=t(),a=t();for(r=0;r<16;r++)a[r]=n[r];for(O(a),O(a),O(a),i=0;i<2;i++){for(s[0]=a[0]-65517,r=1;r<15;r++)s[r]=a[r]-65535-(s[r-1]>>16&1),s[r-1]&=65535;s[15]=a[15]-32767-(s[14]>>16&1),o=s[15]>>16&1,s[14]&=65535,P(a,s,1-o)}for(r=0;r<16;r++)e[2*r]=255&a[r],e[2*r+1]=a[r]>>8}function D(e,t){var n=new Uint8Array(32),r=new Uint8Array(32);return N(n,e),N(r,t),y(n,0,r,0)}function M(e){var t=new Uint8Array(32);return N(t,e),1&t[0]}function F(e,t){var n;for(n=0;n<16;n++)e[n]=t[2*n]+(t[2*n+1]<<8);e[15]&=32767}function L(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]+n[r]}function U(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]-n[r]}function q(e,t,n){var r,i,o=0,s=0,a=0,l=0,u=0,c=0,h=0,f=0,p=0,d=0,m=0,g=0,y=0,v=0,b=0,_=0,w=0,k=0,E=0,S=0,x=0,C=0,A=0,T=0,I=0,j=0,R=0,B=0,O=0,P=0,N=0,D=n[0],M=n[1],F=n[2],L=n[3],U=n[4],q=n[5],z=n[6],K=n[7],H=n[8],V=n[9],$=n[10],W=n[11],G=n[12],Y=n[13],Z=n[14],J=n[15];r=t[0],o+=r*D,s+=r*M,a+=r*F,l+=r*L,u+=r*U,c+=r*q,h+=r*z,f+=r*K,p+=r*H,d+=r*V,m+=r*$,g+=r*W,y+=r*G,v+=r*Y,b+=r*Z,_+=r*J,r=t[1],s+=r*D,a+=r*M,l+=r*F,u+=r*L,c+=r*U,h+=r*q,f+=r*z,p+=r*K,d+=r*H,m+=r*V,g+=r*$,y+=r*W,v+=r*G,b+=r*Y,_+=r*Z,w+=r*J,r=t[2],a+=r*D,l+=r*M,u+=r*F,c+=r*L,h+=r*U,f+=r*q,p+=r*z,d+=r*K,m+=r*H,g+=r*V,y+=r*$,v+=r*W,b+=r*G,_+=r*Y,w+=r*Z,k+=r*J,r=t[3],l+=r*D,u+=r*M,c+=r*F,h+=r*L,f+=r*U,p+=r*q,d+=r*z,m+=r*K,g+=r*H,y+=r*V,v+=r*$,b+=r*W,_+=r*G,w+=r*Y,k+=r*Z,E+=r*J,r=t[4],u+=r*D,c+=r*M,h+=r*F,f+=r*L,p+=r*U,d+=r*q,m+=r*z,g+=r*K,y+=r*H,v+=r*V,b+=r*$,_+=r*W,w+=r*G,k+=r*Y,E+=r*Z,S+=r*J,r=t[5],c+=r*D,h+=r*M,f+=r*F,p+=r*L,d+=r*U,m+=r*q,g+=r*z,y+=r*K,v+=r*H,b+=r*V,_+=r*$,w+=r*W,k+=r*G,E+=r*Y,S+=r*Z,x+=r*J,r=t[6],h+=r*D,f+=r*M,p+=r*F,d+=r*L,m+=r*U,g+=r*q,y+=r*z,v+=r*K,b+=r*H,_+=r*V,w+=r*$,k+=r*W,E+=r*G,S+=r*Y,x+=r*Z,C+=r*J,r=t[7],f+=r*D,p+=r*M,d+=r*F,m+=r*L,g+=r*U,y+=r*q,v+=r*z,b+=r*K,_+=r*H,w+=r*V,k+=r*$,E+=r*W,S+=r*G,x+=r*Y,C+=r*Z,A+=r*J,r=t[8],p+=r*D,d+=r*M,m+=r*F,g+=r*L,y+=r*U,v+=r*q,b+=r*z,_+=r*K,w+=r*H,k+=r*V,E+=r*$,S+=r*W,x+=r*G,C+=r*Y,A+=r*Z,T+=r*J,r=t[9],d+=r*D,m+=r*M,g+=r*F,y+=r*L,v+=r*U,b+=r*q,_+=r*z,w+=r*K,k+=r*H,E+=r*V,S+=r*$,x+=r*W,C+=r*G,A+=r*Y,T+=r*Z,I+=r*J,r=t[10],m+=r*D,g+=r*M,y+=r*F,v+=r*L,b+=r*U,_+=r*q,w+=r*z,k+=r*K,E+=r*H,S+=r*V,x+=r*$,C+=r*W,A+=r*G,T+=r*Y,I+=r*Z,j+=r*J,r=t[11],g+=r*D,y+=r*M,v+=r*F,b+=r*L,_+=r*U,w+=r*q,k+=r*z,E+=r*K,S+=r*H,x+=r*V,C+=r*$,A+=r*W,T+=r*G,I+=r*Y,j+=r*Z,R+=r*J,r=t[12],y+=r*D,v+=r*M,b+=r*F,_+=r*L,w+=r*U,k+=r*q,E+=r*z,S+=r*K,x+=r*H,C+=r*V,A+=r*$,T+=r*W,I+=r*G,j+=r*Y,R+=r*Z,B+=r*J,r=t[13],v+=r*D,b+=r*M,_+=r*F,w+=r*L,k+=r*U,E+=r*q,S+=r*z,x+=r*K,C+=r*H,A+=r*V,T+=r*$,I+=r*W,j+=r*G,R+=r*Y,B+=r*Z,O+=r*J,r=t[14],b+=r*D,_+=r*M,w+=r*F,k+=r*L,E+=r*U,S+=r*q,x+=r*z,C+=r*K,A+=r*H,T+=r*V,I+=r*$,j+=r*W,R+=r*G,B+=r*Y,O+=r*Z,P+=r*J,r=t[15],_+=r*D,w+=r*M,k+=r*F,E+=r*L,S+=r*U,x+=r*q,C+=r*z,A+=r*K,T+=r*H,I+=r*V,j+=r*$,R+=r*W,B+=r*G,O+=r*Y,P+=r*Z,N+=r*J,o+=38*w,s+=38*k,a+=38*E,l+=38*S,u+=38*x,c+=38*C,h+=38*A,f+=38*T,p+=38*I,d+=38*j,m+=38*R,g+=38*B,y+=38*O,v+=38*P,b+=38*N,i=1,r=o+i+65535,i=Math.floor(r/65536),o=r-65536*i,r=s+i+65535,i=Math.floor(r/65536),s=r-65536*i,r=a+i+65535,i=Math.floor(r/65536),a=r-65536*i,r=l+i+65535,i=Math.floor(r/65536),l=r-65536*i,r=u+i+65535,i=Math.floor(r/65536),u=r-65536*i,r=c+i+65535,i=Math.floor(r/65536),c=r-65536*i,r=h+i+65535,i=Math.floor(r/65536),h=r-65536*i,r=f+i+65535,i=Math.floor(r/65536),f=r-65536*i,r=p+i+65535,i=Math.floor(r/65536),p=r-65536*i,r=d+i+65535,i=Math.floor(r/65536),d=r-65536*i,r=m+i+65535,i=Math.floor(r/65536),m=r-65536*i,r=g+i+65535,i=Math.floor(r/65536),g=r-65536*i,r=y+i+65535,i=Math.floor(r/65536),y=r-65536*i,r=v+i+65535,i=Math.floor(r/65536),v=r-65536*i,r=b+i+65535,i=Math.floor(r/65536),b=r-65536*i,r=_+i+65535,i=Math.floor(r/65536),_=r-65536*i,o+=i-1+37*(i-1),i=1,r=o+i+65535,i=Math.floor(r/65536),o=r-65536*i,r=s+i+65535,i=Math.floor(r/65536),s=r-65536*i,r=a+i+65535,i=Math.floor(r/65536),a=r-65536*i,r=l+i+65535,i=Math.floor(r/65536),l=r-65536*i,r=u+i+65535,i=Math.floor(r/65536),u=r-65536*i,r=c+i+65535,i=Math.floor(r/65536),c=r-65536*i,r=h+i+65535,i=Math.floor(r/65536),h=r-65536*i,r=f+i+65535,i=Math.floor(r/65536),f=r-65536*i,r=p+i+65535,i=Math.floor(r/65536),p=r-65536*i,r=d+i+65535,i=Math.floor(r/65536),d=r-65536*i,r=m+i+65535,i=Math.floor(r/65536),m=r-65536*i,r=g+i+65535,i=Math.floor(r/65536),g=r-65536*i,r=y+i+65535,i=Math.floor(r/65536),y=r-65536*i,r=v+i+65535,i=Math.floor(r/65536),v=r-65536*i,r=b+i+65535,i=Math.floor(r/65536),b=r-65536*i,r=_+i+65535,i=Math.floor(r/65536),_=r-65536*i,o+=i-1+37*(i-1),e[0]=o,e[1]=s,e[2]=a,e[3]=l,e[4]=u,e[5]=c,e[6]=h,e[7]=f,e[8]=p,e[9]=d,e[10]=m,e[11]=g,e[12]=y,e[13]=v,e[14]=b,e[15]=_}function z(e,t){q(e,t,t)}function K(e,n){var r=t(),i;for(i=0;i<16;i++)r[i]=n[i];for(i=253;i>=0;i--)z(r,r),2!==i&&4!==i&&q(r,r,n);for(i=0;i<16;i++)e[i]=r[i]}function H(e,n){var r=t(),i;for(i=0;i<16;i++)r[i]=n[i];for(i=250;i>=0;i--)z(r,r),1!==i&&q(r,r,n);for(i=0;i<16;i++)e[i]=r[i]}function V(e,n,r){var i=new Uint8Array(32),o=new Float64Array(80),s,a,u=t(),c=t(),h=t(),f=t(),p=t(),d=t();for(a=0;a<31;a++)i[a]=n[a];for(i[31]=127&n[31]|64,i[0]&=248,F(o,r),a=0;a<16;a++)c[a]=o[a],f[a]=u[a]=h[a]=0;for(u[0]=f[0]=1,a=254;a>=0;--a)s=i[a>>>3]>>>(7&a)&1,P(u,c,s),P(h,f,s),L(p,u,h),U(u,u,h),L(h,c,f),U(c,c,f),z(f,p),z(d,u),q(u,h,u),q(h,c,p),L(p,u,h),U(u,u,h),z(c,u),U(h,f,d),q(u,h,l),L(u,u,f),q(h,h,u),q(u,f,d),q(f,c,o),z(c,p),P(u,c,s),P(h,f,s);for(a=0;a<16;a++)o[a+16]=u[a],o[a+32]=h[a],o[a+48]=c[a],o[a+64]=f[a];var m=o.subarray(32),g=o.subarray(16);return K(m,m),q(g,g,m),N(e,g),0}function $(e,t){return V(e,t,o)}function W(e,t){return r(t,32),$(e,t)}function G(e,t,n){var r=new Uint8Array(32);return V(r,n,t),w(e,i,r,k)}A.prototype.blocks=function(e,t,n){for(var r=this.fin?0:2048,i,o,s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E=this.h[0],S=this.h[1],x=this.h[2],C=this.h[3],A=this.h[4],T=this.h[5],I=this.h[6],j=this.h[7],R=this.h[8],B=this.h[9],O=this.r[0],P=this.r[1],N=this.r[2],D=this.r[3],M=this.r[4],F=this.r[5],L=this.r[6],U=this.r[7],q=this.r[8],z=this.r[9];n>=16;)i=255&e[t+0]|(255&e[t+1])<<8,E+=8191&i,o=255&e[t+2]|(255&e[t+3])<<8,S+=8191&(i>>>13|o<<3),s=255&e[t+4]|(255&e[t+5])<<8,x+=8191&(o>>>10|s<<6),a=255&e[t+6]|(255&e[t+7])<<8,C+=8191&(s>>>7|a<<9),l=255&e[t+8]|(255&e[t+9])<<8,A+=8191&(a>>>4|l<<12),T+=l>>>1&8191,u=255&e[t+10]|(255&e[t+11])<<8,I+=8191&(l>>>14|u<<2),c=255&e[t+12]|(255&e[t+13])<<8,j+=8191&(u>>>11|c<<5),h=255&e[t+14]|(255&e[t+15])<<8,R+=8191&(c>>>8|h<<8),B+=h>>>5|r,f=0,p=f,p+=E*O,p+=S*(5*z),p+=x*(5*q),p+=C*(5*U),p+=A*(5*L),f=p>>>13,p&=8191,p+=T*(5*F),p+=I*(5*M),p+=j*(5*D),p+=R*(5*N),p+=B*(5*P),f+=p>>>13,p&=8191,d=f,d+=E*P,d+=S*O,d+=x*(5*z),d+=C*(5*q),d+=A*(5*U),f=d>>>13,d&=8191,d+=T*(5*L),d+=I*(5*F),d+=j*(5*M),d+=R*(5*D),d+=B*(5*N),f+=d>>>13,d&=8191,m=f,m+=E*N,m+=S*P,m+=x*O,m+=C*(5*z),m+=A*(5*q),f=m>>>13,m&=8191,m+=T*(5*U),m+=I*(5*L),m+=j*(5*F),m+=R*(5*M),m+=B*(5*D),f+=m>>>13,m&=8191,g=f,g+=E*D,g+=S*N,g+=x*P,g+=C*O,g+=A*(5*z),f=g>>>13,g&=8191,g+=T*(5*q),g+=I*(5*U),g+=j*(5*L),g+=R*(5*F),g+=B*(5*M),f+=g>>>13,g&=8191,y=f,y+=E*M,y+=S*D,y+=x*N,y+=C*P,y+=A*O,f=y>>>13,y&=8191,y+=T*(5*z),y+=I*(5*q),y+=j*(5*U),y+=R*(5*L),y+=B*(5*F),f+=y>>>13,y&=8191,v=f,v+=E*F,v+=S*M,v+=x*D,v+=C*N,v+=A*P,f=v>>>13,v&=8191,v+=T*O,v+=I*(5*z),v+=j*(5*q),v+=R*(5*U),v+=B*(5*L),f+=v>>>13,v&=8191,b=f,b+=E*L,b+=S*F,b+=x*M,b+=C*D,b+=A*N,f=b>>>13,b&=8191,b+=T*P,b+=I*O,b+=j*(5*z),b+=R*(5*q),b+=B*(5*U),f+=b>>>13,b&=8191,_=f,_+=E*U,_+=S*L,_+=x*F,_+=C*M,_+=A*D,f=_>>>13,_&=8191,_+=T*N,_+=I*P,_+=j*O,_+=R*(5*z),_+=B*(5*q),f+=_>>>13,_&=8191,w=f,w+=E*q,w+=S*U,w+=x*L,w+=C*F,w+=A*M,f=w>>>13,w&=8191,w+=T*D,w+=I*N,w+=j*P,w+=R*O,w+=B*(5*z),f+=w>>>13,w&=8191,k=f,k+=E*z,k+=S*q,k+=x*U,k+=C*L,k+=A*F,f=k>>>13,k&=8191,k+=T*M,k+=I*D,k+=j*N,k+=R*P,k+=B*O,f+=k>>>13,k&=8191,f=(f<<2)+f|0,f=f+p|0,p=8191&f,f>>>=13,d+=f,E=p,S=d,x=m,C=g,A=y,T=v,I=b,j=_,R=w,B=k,t+=16,n-=16;this.h[0]=E,this.h[1]=S,this.h[2]=x,this.h[3]=C,this.h[4]=A,this.h[5]=T,this.h[6]=I,this.h[7]=j,this.h[8]=R,this.h[9]=B},A.prototype.finish=function(e,t){var n=new Uint16Array(10),r,i,o,s;if(this.leftover){for(s=this.leftover,this.buffer[s++]=1;s<16;s++)this.buffer[s]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(r=this.h[1]>>>13,this.h[1]&=8191,s=2;s<10;s++)this.h[s]+=r,r=this.h[s]>>>13,this.h[s]&=8191;for(this.h[0]+=5*r,r=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=r,r=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=r,n[0]=this.h[0]+5,r=n[0]>>>13,n[0]&=8191,s=1;s<10;s++)n[s]=this.h[s]+r,r=n[s]>>>13,n[s]&=8191;for(n[9]-=8192,i=(1^r)-1,s=0;s<10;s++)n[s]&=i;for(i=~i,s=0;s<10;s++)this.h[s]=this.h[s]&i|n[s];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),o=this.h[0]+this.pad[0],this.h[0]=65535&o,s=1;s<8;s++)o=(this.h[s]+this.pad[s]|0)+(o>>>16)|0,this.h[s]=65535&o;e[t+0]=this.h[0]>>>0&255,e[t+1]=this.h[0]>>>8&255,e[t+2]=this.h[1]>>>0&255,e[t+3]=this.h[1]>>>8&255,e[t+4]=this.h[2]>>>0&255,e[t+5]=this.h[2]>>>8&255,e[t+6]=this.h[3]>>>0&255,e[t+7]=this.h[3]>>>8&255,e[t+8]=this.h[4]>>>0&255,e[t+9]=this.h[4]>>>8&255,e[t+10]=this.h[5]>>>0&255,e[t+11]=this.h[5]>>>8&255,e[t+12]=this.h[6]>>>0&255,e[t+13]=this.h[6]>>>8&255,e[t+14]=this.h[7]>>>0&255,e[t+15]=this.h[7]>>>8&255},A.prototype.update=function(e,t,n){var r,i;if(this.leftover){for(i=16-this.leftover,i>n&&(i=n),r=0;r<i;r++)this.buffer[this.leftover+r]=e[t+r];if(n-=i,t+=i,this.leftover+=i,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(n>=16&&(i=n-n%16,this.blocks(e,t,i),t+=i,n-=i),n){for(r=0;r<n;r++)this.buffer[this.leftover+r]=e[t+r];this.leftover+=n}};var Y=j,Z=R;function J(e,t,n,r,i,o){var s=new Uint8Array(32);return G(s,i,o),Y(e,t,n,r,s)}function Q(e,t,n,r,i,o){var s=new Uint8Array(32);return G(s,i,o),Z(e,t,n,r,s)}var X=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function ee(e,t,n,r){for(var i=new Int32Array(16),o=new Int32Array(16),s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E,S,x,C,A,T,I,j,R,B=e[0],O=e[1],P=e[2],N=e[3],D=e[4],M=e[5],F=e[6],L=e[7],U=t[0],q=t[1],z=t[2],K=t[3],H=t[4],V=t[5],$=t[6],W=t[7],G=0;r>=128;){for(S=0;S<16;S++)x=8*S+G,i[S]=n[x+0]<<24|n[x+1]<<16|n[x+2]<<8|n[x+3],o[S]=n[x+4]<<24|n[x+5]<<16|n[x+6]<<8|n[x+7];for(S=0;S<80;S++)if(s=B,a=O,l=P,u=N,c=D,h=M,f=F,p=L,d=U,m=q,g=z,y=K,v=H,b=V,_=$,w=W,C=L,A=W,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=(D>>>14|H<<18)^(D>>>18|H<<14)^(H>>>9|D<<23),A=(H>>>14|D<<18)^(H>>>18|D<<14)^(D>>>9|H<<23),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=D&M^~D&F,A=H&V^~H&$,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=X[2*S],A=X[2*S+1],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=i[S%16],A=o[S%16],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,k=65535&j|R<<16,E=65535&T|I<<16,C=k,A=E,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=(B>>>28|U<<4)^(U>>>2|B<<30)^(U>>>7|B<<25),A=(U>>>28|B<<4)^(B>>>2|U<<30)^(B>>>7|U<<25),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=B&O^B&P^O&P,A=U&q^U&z^q&z,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,p=65535&j|R<<16,w=65535&T|I<<16,C=u,A=y,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=k,A=E,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,u=65535&j|R<<16,y=65535&T|I<<16,O=s,P=a,N=l,D=u,M=c,F=h,L=f,B=p,q=d,z=m,K=g,H=y,V=v,$=b,W=_,U=w,S%16==15)for(x=0;x<16;x++)C=i[x],A=o[x],T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=i[(x+9)%16],A=o[(x+9)%16],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,k=i[(x+1)%16],E=o[(x+1)%16],C=(k>>>1|E<<31)^(k>>>8|E<<24)^k>>>7,A=(E>>>1|k<<31)^(E>>>8|k<<24)^(E>>>7|k<<25),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,k=i[(x+14)%16],E=o[(x+14)%16],C=(k>>>19|E<<13)^(E>>>29|k<<3)^k>>>6,A=(E>>>19|k<<13)^(k>>>29|E<<3)^(E>>>6|k<<26),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,i[x]=65535&j|R<<16,o[x]=65535&T|I<<16;C=B,A=U,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[0],A=t[0],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[0]=B=65535&j|R<<16,t[0]=U=65535&T|I<<16,C=O,A=q,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[1],A=t[1],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[1]=O=65535&j|R<<16,t[1]=q=65535&T|I<<16,C=P,A=z,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[2],A=t[2],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[2]=P=65535&j|R<<16,t[2]=z=65535&T|I<<16,C=N,A=K,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[3],A=t[3],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[3]=N=65535&j|R<<16,t[3]=K=65535&T|I<<16,C=D,A=H,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[4],A=t[4],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[4]=D=65535&j|R<<16,t[4]=H=65535&T|I<<16,C=M,A=V,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[5],A=t[5],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[5]=M=65535&j|R<<16,t[5]=V=65535&T|I<<16,C=F,A=$,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[6],A=t[6],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[6]=F=65535&j|R<<16,t[6]=$=65535&T|I<<16,C=L,A=W,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[7],A=t[7],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[7]=L=65535&j|R<<16,t[7]=W=65535&T|I<<16,G+=128,r-=128}return r}function te(e,t,n){var r=new Int32Array(8),i=new Int32Array(8),o=new Uint8Array(256),s,a=n;for(r[0]=1779033703,r[1]=3144134277,r[2]=1013904242,r[3]=2773480762,r[4]=1359893119,r[5]=2600822924,r[6]=528734635,r[7]=1541459225,i[0]=4089235720,i[1]=2227873595,i[2]=4271175723,i[3]=1595750129,i[4]=2917565137,i[5]=725511199,i[6]=4215389547,i[7]=327033209,ee(r,i,t,n),n%=128,s=0;s<n;s++)o[s]=t[a-n+s];for(o[n]=128,n=256-128*(n<112?1:0),o[n-9]=0,d(o,n-8,a/536870912|0,a<<3),ee(r,i,o,n),s=0;s<8;s++)d(e,8*s,r[s],i[s]);return 0}function ne(e,n){var r=t(),i=t(),o=t(),s=t(),a=t(),l=t(),u=t(),h=t(),f=t();U(r,e[1],e[0]),U(f,n[1],n[0]),q(r,r,f),L(i,e[0],e[1]),L(f,n[0],n[1]),q(i,i,f),q(o,e[3],n[3]),q(o,o,c),q(s,e[2],n[2]),L(s,s,s),U(a,i,r),U(l,s,o),L(u,s,o),L(h,i,r),q(e[0],a,l),q(e[1],h,u),q(e[2],u,l),q(e[3],a,h)}function re(e,t,n){var r;for(r=0;r<4;r++)P(e[r],t[r],n)}function ie(e,n){var r=t(),i=t(),o=t();K(o,n[2]),q(r,n[0],o),q(i,n[1],o),N(e,i),e[31]^=M(r)<<7}function oe(e,t,n){var r,i;for(B(e[0],s),B(e[1],a),B(e[2],a),B(e[3],s),i=255;i>=0;--i)r=n[i/8|0]>>(7&i)&1,re(e,t,r),ne(t,e),ne(e,e),re(e,t,r)}function se(e,n){var r=[t(),t(),t(),t()];B(r[0],h),B(r[1],f),B(r[2],a),q(r[3],h,f),oe(e,r,n)}function ae(e,n,i){var o=new Uint8Array(64),s=[t(),t(),t(),t()],a;for(i||r(n,32),te(o,n,32),o[0]&=248,o[31]&=127,o[31]|=64,se(s,o),ie(e,s),a=0;a<32;a++)n[a+32]=e[a];return 0}var le=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function ue(e,t){var n,r,i,o;for(r=63;r>=32;--r){for(n=0,i=r-32,o=r-12;i<o;++i)t[i]+=n-16*t[r]*le[i-(r-32)],n=t[i]+128>>8,t[i]-=256*n;t[i]+=n,t[r]=0}for(n=0,i=0;i<32;i++)t[i]+=n-(t[31]>>4)*le[i],n=t[i]>>8,t[i]&=255;for(i=0;i<32;i++)t[i]-=n*le[i];for(r=0;r<32;r++)t[r+1]+=t[r]>>8,e[r]=255&t[r]}function ce(e){var t=new Float64Array(64),n;for(n=0;n<64;n++)t[n]=e[n];for(n=0;n<64;n++)e[n]=0;ue(e,t)}function he(e,n,r,i){var o=new Uint8Array(64),s=new Uint8Array(64),a=new Uint8Array(64),l,u,c=new Float64Array(64),h=[t(),t(),t(),t()];te(o,i,32),o[0]&=248,o[31]&=127,o[31]|=64;var f=r+64;for(l=0;l<r;l++)e[64+l]=n[l];for(l=0;l<32;l++)e[32+l]=o[32+l];for(te(a,e.subarray(32),r+32),ce(a),se(h,a),ie(e,h),l=32;l<64;l++)e[l]=i[l];for(te(s,e,r+64),ce(s),l=0;l<64;l++)c[l]=0;for(l=0;l<32;l++)c[l]=a[l];for(l=0;l<32;l++)for(u=0;u<32;u++)c[l+u]+=s[l]*o[u];return ue(e.subarray(32),c),f}function fe(e,n){var r=t(),i=t(),o=t(),l=t(),c=t(),h=t(),f=t();return B(e[2],a),F(e[1],n),z(o,e[1]),q(l,o,u),U(o,o,e[2]),L(l,e[2],l),z(c,l),z(h,c),q(f,h,c),q(r,f,o),q(r,r,l),H(r,r),q(r,r,o),q(r,r,l),q(r,r,l),q(e[0],r,l),z(i,e[0]),q(i,i,l),D(i,o)&&q(e[0],e[0],p),z(i,e[0]),q(i,i,l),D(i,o)?-1:(M(e[0])===n[31]>>7&&U(e[0],s,e[0]),q(e[3],e[0],e[1]),0)}function pe(e,n,r,i){var o,s,a=new Uint8Array(32),l=new Uint8Array(64),u=[t(),t(),t(),t()],c=[t(),t(),t(),t()];if(s=-1,r<64)return-1;if(fe(c,i))return-1;for(o=0;o<r;o++)e[o]=n[o];for(o=0;o<32;o++)e[o+32]=i[o];if(te(l,e,r),ce(l),oe(u,c,l),se(c,n.subarray(32)),ne(u,c),ie(a,u),r-=64,y(n,0,a,0)){for(o=0;o<r;o++)e[o]=0;return-1}for(o=0;o<r;o++)e[o]=n[o+64];return s=r,s}var de=32,me=24,ge=32,ye=16,ve=32,be=32,_e=32,we=32,ke=32,Ee=me,Se=32,xe=16,Ce=64,Ae=32,Te=64,Ie=32,je=64;function Re(e,t){if(e.length!==de)throw new Error("bad key size");if(t.length!==me)throw new Error("bad nonce size")}function Be(e,t){if(e.length!==_e)throw new Error("bad public key size");if(t.length!==we)throw new Error("bad secret key size")}function Oe(){var e,t;for(t=0;t<arguments.length;t++)if("[object Uint8Array]"!==(e=Object.prototype.toString.call(arguments[t])))throw new TypeError("unexpected type "+e+", use Uint8Array")}function Pe(e){for(var t=0;t<e.length;t++)e[t]=0}e.lowlevel={crypto_core_hsalsa20:w,crypto_stream_xor:C,crypto_stream:x,crypto_stream_salsa20_xor:E,crypto_stream_salsa20:S,crypto_onetimeauth:T,crypto_onetimeauth_verify:I,crypto_verify_16:g,crypto_verify_32:y,crypto_secretbox:j,crypto_secretbox_open:R,crypto_scalarmult:V,crypto_scalarmult_base:$,crypto_box_beforenm:G,crypto_box_afternm:Y,crypto_box:J,crypto_box_open:Q,crypto_box_keypair:W,crypto_hash:te,crypto_sign:he,crypto_sign_keypair:ae,crypto_sign_open:pe,crypto_secretbox_KEYBYTES:de,crypto_secretbox_NONCEBYTES:me,crypto_secretbox_ZEROBYTES:32,crypto_secretbox_BOXZEROBYTES:16,crypto_scalarmult_BYTES:32,crypto_scalarmult_SCALARBYTES:32,crypto_box_PUBLICKEYBYTES:_e,crypto_box_SECRETKEYBYTES:we,crypto_box_BEFORENMBYTES:32,crypto_box_NONCEBYTES:Ee,crypto_box_ZEROBYTES:32,crypto_box_BOXZEROBYTES:16,crypto_sign_BYTES:64,crypto_sign_PUBLICKEYBYTES:32,crypto_sign_SECRETKEYBYTES:64,crypto_sign_SEEDBYTES:32,crypto_hash_BYTES:64},e.util||(e.util={},e.util.decodeUTF8=e.util.encodeUTF8=e.util.encodeBase64=e.util.decodeBase64=function(){throw new Error("nacl.util moved into separate package: https://github.com/dchest/tweetnacl-util-js")}),e.randomBytes=function(e){var t=new Uint8Array(e);return r(t,e),t},e.secretbox=function(e,t,n){Oe(e,t,n),Re(n,t);for(var r=new Uint8Array(32+e.length),i=new Uint8Array(r.length),o=0;o<e.length;o++)r[o+32]=e[o];return j(i,r,r.length,t,n),i.subarray(16)},e.secretbox.open=function(e,t,n){Oe(e,t,n),Re(n,t);for(var r=new Uint8Array(16+e.length),i=new Uint8Array(r.length),o=0;o<e.length;o++)r[o+16]=e[o];return!(r.length<32)&&(0===R(i,r,r.length,t,n)&&i.subarray(32))},e.secretbox.keyLength=de,e.secretbox.nonceLength=me,e.secretbox.overheadLength=16,e.scalarMult=function(e,t){if(Oe(e,t),32!==e.length)throw new Error("bad n size");if(32!==t.length)throw new Error("bad p size");var n=new Uint8Array(32);return V(n,e,t),n},e.scalarMult.base=function(e){if(Oe(e),32!==e.length)throw new Error("bad n size");var t=new Uint8Array(32);return $(t,e),t},e.scalarMult.scalarLength=32,e.scalarMult.groupElementLength=32,e.box=function(t,n,r,i){var o=e.box.before(r,i);return e.secretbox(t,n,o)},e.box.before=function(e,t){Oe(e,t),Be(e,t);var n=new Uint8Array(32);return G(n,e,t),n},e.box.after=e.secretbox,e.box.open=function(t,n,r,i){var o=e.box.before(r,i);return e.secretbox.open(t,n,o)},e.box.open.after=e.secretbox.open,e.box.keyPair=function(){var e=new Uint8Array(_e),t=new Uint8Array(we);return W(e,t),{publicKey:e,secretKey:t}},e.box.keyPair.fromSecretKey=function(e){if(Oe(e),e.length!==we)throw new Error("bad secret key size");var t=new Uint8Array(_e);return $(t,e),{publicKey:t,secretKey:new Uint8Array(e)}},e.box.publicKeyLength=_e,e.box.secretKeyLength=we,e.box.sharedKeyLength=32,e.box.nonceLength=Ee,e.box.overheadLength=e.secretbox.overheadLength,e.sign=function(e,t){if(Oe(e,t),64!==t.length)throw new Error("bad secret key size");var n=new Uint8Array(64+e.length);return he(n,e,e.length,t),n},e.sign.open=function(e,t){if(2!==arguments.length)throw new Error("nacl.sign.open accepts 2 arguments; did you mean to use nacl.sign.detached.verify?");if(Oe(e,t),32!==t.length)throw new Error("bad public key size");var n=new Uint8Array(e.length),r=pe(n,e,e.length,t);if(r<0)return null;for(var i=new Uint8Array(r),o=0;o<i.length;o++)i[o]=n[o];return i},e.sign.detached=function(t,n){for(var r=e.sign(t,n),i=new Uint8Array(64),o=0;o<i.length;o++)i[o]=r[o];return i},e.sign.detached.verify=function(e,t,n){if(Oe(e,t,n),64!==t.length)throw new Error("bad signature size");if(32!==n.length)throw new Error("bad public key size");var r=new Uint8Array(64+e.length),i=new Uint8Array(64+e.length),o;for(o=0;o<64;o++)r[o]=t[o];for(o=0;o<e.length;o++)r[o+64]=e[o];return pe(i,r,r.length,n)>=0},e.sign.keyPair=function(){var e=new Uint8Array(32),t=new Uint8Array(64);return ae(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(Oe(e),64!==e.length)throw new Error("bad secret key size");for(var t=new Uint8Array(32),n=0;n<t.length;n++)t[n]=e[32+n];return{publicKey:t,secretKey:new Uint8Array(e)}},e.sign.keyPair.fromSeed=function(e){if(Oe(e),32!==e.length)throw new Error("bad seed size");for(var t=new Uint8Array(32),n=new Uint8Array(64),r=0;r<32;r++)n[r]=e[r];return ae(t,n,!0),{publicKey:t,secretKey:n}},e.sign.publicKeyLength=32,e.sign.secretKeyLength=64,e.sign.seedLength=32,e.sign.signatureLength=64,e.hash=function(e){Oe(e);var t=new Uint8Array(64);return te(t,e,e.length),t},e.hash.hashLength=64,e.verify=function(e,t){return Oe(e,t),0!==e.length&&0!==t.length&&(e.length===t.length&&0===m(e,0,t,0,e.length))},e.setPRNG=function(e){r=e},function(){var t="undefined"!=typeof self?self.crypto||self.msCrypto:null;if(t&&t.getRandomValues){var r=65536;e.setPRNG(function(e,n){var r,i=new Uint8Array(n);for(r=0;r<n;r+=65536)t.getRandomValues(i.subarray(r,r+Math.min(n-r,65536)));for(r=0;r<n;r++)e[r]=i[r];Pe(i)})}else t=n(1655),t&&t.randomBytes&&e.setPRNG(function(e,n){var r,i=t.randomBytes(n);for(r=0;r<n;r++)e[r]=i[r];Pe(i)})}()}(e.exports?e.exports:self.nacl=self.nacl||{})},function(e,t,n){e.exports=o;var r=n(25),i=n(29).Buffer;function o(e){r.object(e,"options"),void 0!==e.buffer&&r.buffer(e.buffer,"options.buffer"),this._size=e.buffer?e.buffer.length:1024,this._buffer=e.buffer||i.alloc(this._size),this._offset=0}o.prototype.toBuffer=function(){return this._buffer.slice(0,this._offset)},o.prototype.atEnd=function(){return this._offset>=this._buffer.length},o.prototype.remainder=function(){return this._buffer.slice(this._offset)},o.prototype.skip=function(e){this._offset+=e},o.prototype.expand=function(){this._size*=2;var e=i.alloc(this._size);this._buffer.copy(e,0),this._buffer=e},o.prototype.readPart=function(){return{data:this.readBuffer()}},o.prototype.readBuffer=function(){var e=this._buffer.readUInt32BE(this._offset);this._offset+=4,r.ok(this._offset+e<=this._buffer.length,"length out of bounds at +0x"+this._offset.toString(16)+" (data truncated?)");var t=this._buffer.slice(this._offset,this._offset+e);return this._offset+=e,t},o.prototype.readString=function(){return this.readBuffer().toString()},o.prototype.readCString=function(){for(var e=this._offset;e<this._buffer.length&&0!==this._buffer[e];)e++;r.ok(e<this._buffer.length,"c string does not terminate");var t=this._buffer.slice(this._offset,e).toString();return this._offset=e+1,t},o.prototype.readInt=function(){var e=this._buffer.readUInt32BE(this._offset);return this._offset+=4,e},o.prototype.readInt64=function(){r.ok(this._offset+8<this._buffer.length,"buffer not long enough to read Int64");var e=this._buffer.slice(this._offset,this._offset+8);return this._offset+=8,e},o.prototype.readChar=function(){var e=this._buffer[this._offset++];return e},o.prototype.writeBuffer=function(e){for(;this._offset+4+e.length>this._size;)this.expand();this._buffer.writeUInt32BE(e.length,this._offset),this._offset+=4,e.copy(this._buffer,this._offset),this._offset+=e.length},o.prototype.writeString=function(e){this.writeBuffer(i.from(e,"utf8"))},o.prototype.writeCString=function(e){for(;this._offset+1+e.length>this._size;)this.expand();this._buffer.write(e,this._offset),this._offset+=e.length,this._buffer[this._offset++]=0},o.prototype.writeInt=function(e){for(;this._offset+4>this._size;)this.expand();this._buffer.writeUInt32BE(e,this._offset),this._offset+=4},o.prototype.writeInt64=function(e){if(r.buffer(e,"value"),e.length>8){for(var t=e.slice(0,e.length-8),n=0;n<t.length;++n)r.strictEqual(t[n],0,"must fit in 64 bits of precision");e=e.slice(e.length-8,e.length)}for(;this._offset+8>this._size;)this.expand();e.copy(this._buffer,this._offset),this._offset+=8},o.prototype.writeChar=function(e){for(;this._offset+1>this._size;)this.expand();this._buffer[this._offset++]=e},o.prototype.writePart=function(e){this.writeBuffer(e.data)},o.prototype.write=function(e){for(;this._offset+e.length>this._size;)this.expand();e.copy(this._buffer,this._offset),this._offset+=e.length}},function(e,t,n){e.exports={read:h,readPkcs8:d,write:f,writePkcs8:A,pkcs8ToBuffer:C,readECDSACurve:b,writeECDSACurve:B};var r=n(25),i=n(84),o=n(29).Buffer,s=n(48),a=n(42),l=n(41),u=n(46),c=n(92);function h(e,t){return c.read(e,t,"pkcs8")}function f(e,t){return c.write(e,t,"pkcs8")}function p(e,t){return r.strictEqual(e.peek(),i.Ber.Integer,t+" is not an Integer"),a.mpNormalize(e.readString(i.Ber.Integer,!0))}function d(e,t,n){n.peek()===i.Ber.Integer&&(r.strictEqual(t,"private","unexpected Integer at start of public key"),n.readString(i.Ber.Integer,!0)),n.readSequence();var o=n.offset+n.length,s=n.readOID();switch(s){case"1.2.840.113549.1.1.1":return n._offset=o,"public"===t?m(n):g(n);case"1.2.840.10040.4.1":return"public"===t?y(n):v(n);case"1.2.840.10045.2.1":return"public"===t?w(n):_(n);case"1.3.101.112":return"public"===t?k(n):S(n);case"1.3.101.110":return"public"===t?E(n):x(n);default:throw new Error("Unknown key type OID "+s)}}function m(e){e.readSequence(i.Ber.BitString),e.readByte(),e.readSequence();var t=p(e,"modulus"),n=p(e,"exponent"),r={type:"rsa",source:e.originalInput,parts:[{name:"e",data:n},{name:"n",data:t}]};return new l(r)}function g(e){e.readSequence(i.Ber.OctetString),e.readSequence();var t=p(e,"version");r.equal(t[0],0,"unknown RSA private key version");var n=p(e,"modulus"),o=p(e,"public exponent"),s=p(e,"private exponent"),a=p(e,"prime1"),l=p(e,"prime2"),c=p(e,"exponent1"),h=p(e,"exponent2"),f=p(e,"iqmp"),d={type:"rsa",parts:[{name:"n",data:n},{name:"e",data:o},{name:"d",data:s},{name:"iqmp",data:f},{name:"p",data:a},{name:"q",data:l},{name:"dmodp",data:c},{name:"dmodq",data:h}]};return new u(d)}function y(e){e.readSequence();var t=p(e,"p"),n=p(e,"q"),r=p(e,"g");e.readSequence(i.Ber.BitString),e.readByte();var o=p(e,"y"),s={type:"dsa",parts:[{name:"p",data:t},{name:"q",data:n},{name:"g",data:r},{name:"y",data:o}]};return new l(s)}function v(e){e.readSequence();var t=p(e,"p"),n=p(e,"q"),r=p(e,"g");e.readSequence(i.Ber.OctetString);var o=p(e,"x"),s=a.calculateDSAPublic(r,t,o),l={type:"dsa",parts:[{name:"p",data:t},{name:"q",data:n},{name:"g",data:r},{name:"y",data:s},{name:"x",data:o}]};return new u(l)}function b(e){var t,n,l,u,c;if(e.peek()===i.Ber.OID){var h=e.readOID();for(n=Object.keys(s.curves),l=0;l<n.length;++l)if(u=n[l],c=s.curves[u],c.pkcs8oid===h){t=u;break}}else{e.readSequence();var f=e.readString(i.Ber.Integer,!0);r.strictEqual(f[0],1,"ECDSA key not version 1");var p={};e.readSequence();var d=e.readOID();r.strictEqual(d,"1.2.840.10045.1.1","ECDSA key is not from a prime-field");var m=p.p=a.mpNormalize(e.readString(i.Ber.Integer,!0));p.size=8*m.length-a.countZeros(m),e.readSequence(),p.a=a.mpNormalize(e.readString(i.Ber.OctetString,!0)),p.b=a.mpNormalize(e.readString(i.Ber.OctetString,!0)),e.peek()===i.Ber.BitString&&(p.s=e.readString(i.Ber.BitString,!0)),p.G=e.readString(i.Ber.OctetString,!0),r.strictEqual(p.G[0],4,"uncompressed G is required"),p.n=a.mpNormalize(e.readString(i.Ber.Integer,!0)),p.h=a.mpNormalize(e.readString(i.Ber.Integer,!0)),r.strictEqual(p.h[0],1,"a cofactor=1 curve is required"),n=Object.keys(s.curves);var g=Object.keys(p);for(l=0;l<n.length;++l){u=n[l],c=s.curves[u];for(var y=!0,v=0;v<g.length;++v){var b=g[v];if(void 0!==c[b])if("object"==typeof c[b]&&void 0!==c[b].equals){if(!c[b].equals(p[b])){y=!1;break}}else if(o.isBuffer(c[b])){if(c[b].toString("binary")!==p[b].toString("binary")){y=!1;break}}else if(c[b]!==p[b]){y=!1;break}}if(y){t=u;break}}}return t}function _(e){var t=b(e);r.string(t,"a known elliptic curve"),e.readSequence(i.Ber.OctetString),e.readSequence();var n=p(e,"version");r.equal(n[0],1,"unknown version of ECDSA key");var s=e.readString(i.Ber.OctetString,!0),l;if(160==e.peek()&&(e.readSequence(160),e._offset+=e.length),161==e.peek()&&(e.readSequence(161),l=e.readString(i.Ber.BitString,!0),l=a.ecNormalize(l)),void 0===l){var c=a.publicFromPrivateECDSA(t,s);l=c.part.Q.data}var h={type:"ecdsa",parts:[{name:"curve",data:o.from(t)},{name:"Q",data:l},{name:"d",data:s}]};return new u(h)}function w(e){var t=b(e);r.string(t,"a known elliptic curve");var n=e.readString(i.Ber.BitString,!0);n=a.ecNormalize(n);var s={type:"ecdsa",parts:[{name:"curve",data:o.from(t)},{name:"Q",data:n}]};return new l(s)}function k(e){0===e.peek()&&e.readByte();var t=a.readBitString(e),n={type:"ed25519",parts:[{name:"A",data:a.zeroPadToLength(t,32)}]};return new l(n)}function E(e){var t=a.readBitString(e),n={type:"curve25519",parts:[{name:"A",data:a.zeroPadToLength(t,32)}]};return new l(n)}function S(e){0===e.peek()&&e.readByte(),e.readSequence(i.Ber.OctetString);var t=e.readString(i.Ber.OctetString,!0),n;t=a.zeroPadToLength(t,32),e.peek()===i.Ber.BitString?(n=a.readBitString(e),n=a.zeroPadToLength(n,32)):n=a.calculateED25519Public(t);var r={type:"ed25519",parts:[{name:"A",data:a.zeroPadToLength(n,32)},{name:"k",data:a.zeroPadToLength(t,32)}]};return new u(r)}function x(e){0===e.peek()&&e.readByte(),e.readSequence(i.Ber.OctetString);var t=e.readString(i.Ber.OctetString,!0);t=a.zeroPadToLength(t,32);var n=a.calculateX25519Public(t),r={type:"curve25519",parts:[{name:"A",data:a.zeroPadToLength(n,32)},{name:"k",data:a.zeroPadToLength(t,32)}]};return new u(r)}function C(e){var t=new i.BerWriter;return A(t,e),t.buffer}function A(e,t){if(e.startSequence(),u.isPrivateKey(t)){var n=o.from([0]);e.writeBuffer(n,i.Ber.Integer)}switch(e.startSequence(),t.type){case"rsa":e.writeOID("1.2.840.113549.1.1.1"),u.isPrivateKey(t)?T(t,e):I(t,e);break;case"dsa":e.writeOID("1.2.840.10040.4.1"),u.isPrivateKey(t)?j(t,e):R(t,e);break;case"ecdsa":e.writeOID("1.2.840.10045.2.1"),u.isPrivateKey(t)?P(t,e):O(t,e);break;case"ed25519":if(e.writeOID("1.3.101.112"),u.isPrivateKey(t))throw new Error("Ed25519 private keys in pkcs8 format are not supported");N(t,e);break;default:throw new Error("Unsupported key type: "+t.type)}e.endSequence()}function T(e,t){t.writeNull(),t.endSequence(),t.startSequence(i.Ber.OctetString),t.startSequence();var n=o.from([0]);t.writeBuffer(n,i.Ber.Integer),t.writeBuffer(e.part.n.data,i.Ber.Integer),t.writeBuffer(e.part.e.data,i.Ber.Integer),t.writeBuffer(e.part.d.data,i.Ber.Integer),t.writeBuffer(e.part.p.data,i.Ber.Integer),t.writeBuffer(e.part.q.data,i.Ber.Integer),e.part.dmodp&&e.part.dmodq||a.addRSAMissing(e),t.writeBuffer(e.part.dmodp.data,i.Ber.Integer),t.writeBuffer(e.part.dmodq.data,i.Ber.Integer),t.writeBuffer(e.part.iqmp.data,i.Ber.Integer),t.endSequence(),t.endSequence()}function I(e,t){t.writeNull(),t.endSequence(),t.startSequence(i.Ber.BitString),t.writeByte(0),t.startSequence(),t.writeBuffer(e.part.n.data,i.Ber.Integer),t.writeBuffer(e.part.e.data,i.Ber.Integer),t.endSequence(),t.endSequence()}function j(e,t){t.startSequence(),t.writeBuffer(e.part.p.data,i.Ber.Integer),t.writeBuffer(e.part.q.data,i.Ber.Integer),t.writeBuffer(e.part.g.data,i.Ber.Integer),t.endSequence(),t.endSequence(),t.startSequence(i.Ber.OctetString),t.writeBuffer(e.part.x.data,i.Ber.Integer),t.endSequence()}function R(e,t){t.startSequence(),t.writeBuffer(e.part.p.data,i.Ber.Integer),t.writeBuffer(e.part.q.data,i.Ber.Integer),t.writeBuffer(e.part.g.data,i.Ber.Integer),t.endSequence(),t.endSequence(),t.startSequence(i.Ber.BitString),t.writeByte(0),t.writeBuffer(e.part.y.data,i.Ber.Integer),t.endSequence()}function B(e,t){var n=s.curves[e.curve];if(n.pkcs8oid)t.writeOID(n.pkcs8oid);else{t.startSequence();var r=o.from([1]);t.writeBuffer(r,i.Ber.Integer),t.startSequence(),t.writeOID("1.2.840.10045.1.1"),t.writeBuffer(n.p,i.Ber.Integer),t.endSequence(),t.startSequence();var a=n.p;0===a[0]&&(a=a.slice(1)),t.writeBuffer(a,i.Ber.OctetString),t.writeBuffer(n.b,i.Ber.OctetString),t.writeBuffer(n.s,i.Ber.BitString),t.endSequence(),t.writeBuffer(n.G,i.Ber.OctetString),t.writeBuffer(n.n,i.Ber.Integer);var l=n.h;l||(l=o.from([1])),t.writeBuffer(l,i.Ber.Integer),t.endSequence()}}function O(e,t){B(e,t),t.endSequence();var n=a.ecNormalize(e.part.Q.data,!0);t.writeBuffer(n,i.Ber.BitString)}function P(e,t){B(e,t),t.endSequence(),t.startSequence(i.Ber.OctetString),t.startSequence();var n=o.from([1]);t.writeBuffer(n,i.Ber.Integer),t.writeBuffer(e.part.d.data,i.Ber.OctetString),t.startSequence(161);var r=a.ecNormalize(e.part.Q.data,!0);t.writeBuffer(r,i.Ber.BitString),t.endSequence(),t.endSequence(),t.endSequence()}function N(e,t){t.endSequence(),a.writeBitString(t,e.part.A.data)}function D(e,t){t.endSequence();var n=a.mpNormalize(e.part.k.data,!0);t.startSequence(i.Ber.OctetString),t.writeBuffer(n,i.Ber.OctetString),t.endSequence()}},function(e,t,n){e.exports=v;var r=n(25),i=n(29).Buffer,o=n(48),s=n(16),a=n(172),l=n(83),u=n(76),c=n(14),h=n(42),f=n(41),p=n(46),d=n(178),m={};m.openssh=n(1658),m.x509=n(619),m.pem=n(1659);var g=u.CertificateParseError,y=u.InvalidAlgorithmError;function v(e){r.object(e,"options"),r.arrayOfObject(e.subjects,"options.subjects"),h.assertCompatible(e.subjects[0],d,[1,0],"options.subjects"),h.assertCompatible(e.subjectKey,f,[1,0],"options.subjectKey"),h.assertCompatible(e.issuer,d,[1,0],"options.issuer"),void 0!==e.issuerKey&&h.assertCompatible(e.issuerKey,f,[1,0],"options.issuerKey"),r.object(e.signatures,"options.signatures"),r.buffer(e.serial,"options.serial"),r.date(e.validFrom,"options.validFrom"),r.date(e.validUntil,"optons.validUntil"),r.optionalArrayOfString(e.purposes,"options.purposes"),this._hashCache={},this.subjects=e.subjects,this.issuer=e.issuer,this.subjectKey=e.subjectKey,this.issuerKey=e.issuerKey,this.signatures=e.signatures,this.serial=e.serial,this.validFrom=e.validFrom,this.validUntil=e.validUntil,this.purposes=e.purposes}v.formats=m,v.prototype.toBuffer=function(e,t){return void 0===e&&(e="x509"),r.string(e,"format"),r.object(m[e],"formats[format]"),r.optionalObject(t,"options"),m[e].write(this,t)},v.prototype.toString=function(e,t){return void 0===e&&(e="pem"),this.toBuffer(e,t).toString()},v.prototype.fingerprint=function(e){void 0===e&&(e="sha256"),r.string(e,"algorithm");var t={type:"certificate",hash:this.hash(e),algorithm:e};return new a(t)},v.prototype.hash=function(e){if(r.string(e,"algorithm"),e=e.toLowerCase(),void 0===o.hashAlgs[e])throw new y(e);if(this._hashCache[e])return this._hashCache[e];var t=s.createHash(e).update(this.toBuffer("x509")).digest();return this._hashCache[e]=t,t},v.prototype.isExpired=function(e){return void 0===e&&(e=new Date),!(e.getTime()>=this.validFrom.getTime()&&e.getTime()<this.validUntil.getTime())},v.prototype.isSignedBy=function(e){return h.assertCompatible(e,v,[1,0],"issuer"),!!this.issuer.equals(e.subjects[0])&&(!(this.issuer.purposes&&this.issuer.purposes.length>0&&-1===this.issuer.purposes.indexOf("ca"))&&this.isSignedByKey(e.subjectKey))},v.prototype.getExtension=function(e){r.string(e,"keyOrOid");var t=this.getExtensions().filter(function(t){return"x509"===t.format?t.oid===e:"openssh"===t.format&&t.name===e})[0];return t},v.prototype.getExtensions=function(){var e=[],t=this.signatures.x509;t&&t.extras&&t.extras.exts&&t.extras.exts.forEach(function(t){t.format="x509",e.push(t)});var n=this.signatures.openssh;return n&&n.exts&&n.exts.forEach(function(t){t.format="openssh",e.push(t)}),e},v.prototype.isSignedByKey=function(e){if(h.assertCompatible(e,f,[1,2],"issuerKey"),void 0!==this.issuerKey)return this.issuerKey.fingerprint("sha512").matches(e);var t=Object.keys(this.signatures)[0],n=m[t].verify(this,e);return n&&(this.issuerKey=e),n},v.prototype.signWith=function(e){h.assertCompatible(e,p,[1,2],"key");for(var t=Object.keys(m),n=!1,r=0;r<t.length;++r)if("pem"!==t[r]){var i=m[t[r]].sign(this,e);!0===i&&(n=!0)}if(!n)throw new Error("Failed to sign the certificate for any available certificate formats")},v.createSelfSigned=function(e,t,n){var o;o=Array.isArray(e)?e:[e],r.arrayOfObject(o),o.forEach(function(e){h.assertCompatible(e,d,[1,0],"subject")}),h.assertCompatible(t,p,[1,2],"private key"),r.optionalObject(n,"options"),void 0===n&&(n={}),r.optionalObject(n.validFrom,"options.validFrom"),r.optionalObject(n.validUntil,"options.validUntil");var s=n.validFrom,a=n.validUntil;if(void 0===s&&(s=new Date),void 0===a){r.optionalNumber(n.lifetime,"options.lifetime");var l=n.lifetime;void 0===l&&(l=31536e4),a=new Date,a.setTime(a.getTime()+1e3*l)}r.optionalBuffer(n.serial,"options.serial");var u=n.serial;void 0===u&&(u=i.from("0000000000000001","hex"));var c=n.purposes;if(void 0===c&&(c=[]),-1===c.indexOf("signature")&&c.push("signature"),-1===c.indexOf("ca")&&c.push("ca"),-1===c.indexOf("crl")&&c.push("crl"),c.length<=3){var f=o.filter(function(e){return"host"===e.type}),m=o.filter(function(e){return"user"===e.type});f.length>0&&-1===c.indexOf("serverAuth")&&c.push("serverAuth"),m.length>0&&-1===c.indexOf("clientAuth")&&c.push("clientAuth"),(m.length>0||f.length>0)&&(-1===c.indexOf("keyAgreement")&&c.push("keyAgreement"),"rsa"===t.type&&-1===c.indexOf("encryption")&&c.push("encryption"))}var g=new v({subjects:o,issuer:o[0],subjectKey:t.toPublic(),issuerKey:t.toPublic(),signatures:{},serial:u,validFrom:s,validUntil:a,purposes:c});return g.signWith(t),g},v.create=function(e,t,n,o,s){var a;a=Array.isArray(e)?e:[e],r.arrayOfObject(a),a.forEach(function(e){h.assertCompatible(e,d,[1,0],"subject")}),h.assertCompatible(t,f,[1,0],"key"),p.isPrivateKey(t)&&(t=t.toPublic()),h.assertCompatible(n,d,[1,0],"issuer"),h.assertCompatible(o,p,[1,2],"issuer key"),r.optionalObject(s,"options"),void 0===s&&(s={}),r.optionalObject(s.validFrom,"options.validFrom"),r.optionalObject(s.validUntil,"options.validUntil");var l=s.validFrom,u=s.validUntil;if(void 0===l&&(l=new Date),void 0===u){r.optionalNumber(s.lifetime,"options.lifetime");var c=s.lifetime;void 0===c&&(c=31536e4),u=new Date,u.setTime(u.getTime()+1e3*c)}r.optionalBuffer(s.serial,"options.serial");var m=s.serial;void 0===m&&(m=i.from("0000000000000001","hex"));var g=s.purposes;void 0===g&&(g=[]),-1===g.indexOf("signature")&&g.push("signature"),!0===s.ca&&(-1===g.indexOf("ca")&&g.push("ca"),-1===g.indexOf("crl")&&g.push("crl"));var y=a.filter(function(e){return"host"===e.type}),b=a.filter(function(e){return"user"===e.type});y.length>0&&-1===g.indexOf("serverAuth")&&g.push("serverAuth"),b.length>0&&-1===g.indexOf("clientAuth")&&g.push("clientAuth"),(b.length>0||y.length>0)&&(-1===g.indexOf("keyAgreement")&&g.push("keyAgreement"),"rsa"===t.type&&-1===g.indexOf("encryption")&&g.push("encryption"));var _=new v({subjects:a,issuer:n,subjectKey:t,issuerKey:o.toPublic(),signatures:{},serial:m,validFrom:l,validUntil:u,purposes:g});return _.signWith(o),_},v.parse=function(e,t,n){"string"!=typeof e&&r.buffer(e,"data"),void 0===t&&(t="auto"),r.string(t,"format"),"string"==typeof n&&(n={filename:n}),r.optionalObject(n,"options"),void 0===n&&(n={}),r.optionalString(n.filename,"options.filename"),void 0===n.filename&&(n.filename="(unnamed)"),r.object(m[t],"formats[format]");try{var i=m[t].read(e,n);return i}catch(e){throw new g(n.filename,t,e)}},v.isCertificate=function(e,t){return h.isCompatible(e,v,t)},v.prototype._sshpkApiVersion=[1,1],v._oldVersionDetect=function(e){return[1,0]}},function(e,t,n){e.exports=g;var r=n(25),i=n(48),o=n(16),s=n(172),a=n(83),l=n(76),u=n(14),c=n(42),h=n(84),f=n(29).Buffer,p=/^([*]|[a-z0-9][a-z0-9\-]{0,62})(?:\.([*]|[a-z0-9][a-z0-9\-]{0,62}))*$/i,d={cn:"2.5.4.3",o:"2.5.4.10",ou:"2.5.4.11",l:"2.5.4.7",s:"2.5.4.8",c:"2.5.4.6",sn:"2.5.4.4",postalCode:"2.5.4.17",serialNumber:"2.5.4.5",street:"2.5.4.9",x500UniqueIdentifier:"2.5.4.45",role:"2.5.4.72",telephoneNumber:"2.5.4.20",description:"2.5.4.13",dc:"0.9.2342.19200300.100.1.25",uid:"0.9.2342.19200300.100.1.1",mail:"0.9.2342.19200300.100.1.3",title:"2.5.4.12",gn:"2.5.4.42",initials:"2.5.4.43",pseudonym:"2.5.4.65",emailAddress:"1.2.840.113549.1.9.1"},m={};function g(e){var t=this;if(r.object(e,"options"),r.arrayOfObject(e.components,"options.components"),this.components=e.components,this.componentLookup={},this.components.forEach(function(e){e.name&&!e.oid&&(e.oid=d[e.name]),e.oid&&!e.name&&(e.name=m[e.oid]),void 0===t.componentLookup[e.name]&&(t.componentLookup[e.name]=[]),t.componentLookup[e.name].push(e)}),this.componentLookup.cn&&this.componentLookup.cn.length>0&&(this.cn=this.componentLookup.cn[0].value),r.optionalString(e.type,"options.type"),void 0===e.type)1===this.components.length&&this.componentLookup.cn&&1===this.componentLookup.cn.length&&this.componentLookup.cn[0].value.match(p)?(this.type="host",this.hostname=this.componentLookup.cn[0].value):this.componentLookup.dc&&this.components.length===this.componentLookup.dc.length?(this.type="host",this.hostname=this.componentLookup.dc.map(function(e){return e.value}).join(".")):this.componentLookup.uid&&this.components.length===this.componentLookup.uid.length?(this.type="user",this.uid=this.componentLookup.uid[0].value):this.componentLookup.cn&&1===this.componentLookup.cn.length&&this.componentLookup.cn[0].value.match(p)?(this.type="host",this.hostname=this.componentLookup.cn[0].value):this.componentLookup.uid&&1===this.componentLookup.uid.length?(this.type="user",this.uid=this.componentLookup.uid[0].value):this.componentLookup.mail&&1===this.componentLookup.mail.length?(this.type="email",this.email=this.componentLookup.mail[0].value):this.componentLookup.cn&&1===this.componentLookup.cn.length?(this.type="user",this.uid=this.componentLookup.cn[0].value):this.type="unknown";else if(this.type=e.type,"host"===this.type)this.hostname=e.hostname;else if("user"===this.type)this.uid=e.uid;else{if("email"!==this.type)throw new Error("Unknown type "+this.type);this.email=e.email}}Object.keys(d).forEach(function(e){m[d[e]]=e}),g.prototype.toString=function(){return this.components.map(function(e){var t=e.name.toUpperCase();t=t.replace(/=/g,"\\=");var n=e.value;return n=n.replace(/,/g,"\\,"),t+"="+n}).join(", ")},g.prototype.get=function(e,t){r.string(e,"name");var n=this.componentLookup[e];if(void 0!==n&&0!==n.length){if(!t&&n.length>1)throw new Error("Multiple values for attribute "+e);return t?n.map(function(e){return e.value}):n[0].value}},g.prototype.toArray=function(e){return this.components.map(function(e){return{name:e.name,value:e.value}})};var y=/[^a-zA-Z0-9 '(),+.\/:=?-]/,v=/[^\x00-\x7f]/;function b(e,t){if("**"===e||"**"===t)return!0;var n=e.split("."),r=t.split(".");if(n.length!==r.length)return!1;for(var i=0;i<n.length;++i)if("*"!==n[i]&&"*"!==r[i]&&n[i]!==r[i])return!1;return!0}g.prototype.toAsn1=function(e,t){e.startSequence(t),this.components.forEach(function(t){if(e.startSequence(h.Ber.Constructor|h.Ber.Set),e.startSequence(),e.writeOID(t.oid),t.asn1type===h.Ber.Utf8String||t.value.match(v)){var n=f.from(t.value,"utf8");e.writeBuffer(n,h.Ber.Utf8String)}else if(t.asn1type===h.Ber.IA5String||t.value.match(y))e.writeString(t.value,h.Ber.IA5String);else{var r=h.Ber.PrintableString;void 0!==t.asn1type&&(r=t.asn1type),e.writeString(t.value,r)}e.endSequence(),e.endSequence()}),e.endSequence()},g.prototype.equals=function(e){if(!g.isIdentity(e,[1,0]))return!1;if(e.components.length!==this.components.length)return!1;for(var t=0;t<this.components.length;++t){if(this.components[t].oid!==e.components[t].oid)return!1;if(!b(this.components[t].value,e.components[t].value))return!1}return!0},g.forHost=function(e){return r.string(e,"hostname"),new g({type:"host",hostname:e,components:[{name:"cn",value:e}]})},g.forUser=function(e){return r.string(e,"uid"),new g({type:"user",uid:e,components:[{name:"uid",value:e}]})},g.forEmail=function(e){return r.string(e,"email"),new g({type:"email",email:e,components:[{name:"mail",value:e}]})},g.parseDN=function(e){r.string(e,"dn");for(var t=[""],n=0,i=e;i.length>0;){var o;if(null!==(o=/^,/.exec(i)))t[++n]="",i=i.slice(o[0].length);else if(null!==(o=/^\\,/.exec(i)))t[n]+=",",i=i.slice(o[0].length);else if(null!==(o=/^\\./.exec(i)))t[n]+=o[0],i=i.slice(o[0].length);else{if(null===(o=/^[^\\,]+/.exec(i)))throw new Error("Failed to parse DN");t[n]+=o[0],i=i.slice(o[0].length)}}var s=t.map(function(e){e=e.trim();for(var t=e.indexOf("=");t>0&&"\\"===e.charAt(t-1);)t=e.indexOf("=",t+1);if(-1===t)throw new Error("Failed to parse DN");var n=e.slice(0,t).toLowerCase().replace(/\\=/g,"="),r=e.slice(t+1);return{name:n,value:r}});return new g({components:s})},g.fromArray=function(e){return r.arrayOfObject(e,"components"),e.forEach(function(e){if(r.object(e,"component"),r.string(e.name,"component.name"),!f.isBuffer(e.value)&&"string"!=typeof e.value)throw new Error("Invalid component value")}),new g({components:e})},g.parseAsn1=function(e,t){var n=[];e.readSequence(t);for(var r=e.offset+e.length;e.offset<r;){e.readSequence(h.Ber.Constructor|h.Ber.Set);var i=e.offset+e.length;e.readSequence();var o=e.readOID(),s=e.peek(),a;switch(s){case h.Ber.PrintableString:case h.Ber.IA5String:case h.Ber.OctetString:case h.Ber.T61String:a=e.readString(s);break;case h.Ber.Utf8String:a=e.readString(s,!0),a=a.toString("utf8");break;case h.Ber.CharacterString:case h.Ber.BMPString:a=e.readString(s,!0),a=a.toString("utf16le");break;default:throw new Error("Unknown asn1 type "+s)}n.push({oid:o,asn1type:s,value:a}),e._offset=i}return e._offset=r,new g({components:n})},g.isIdentity=function(e,t){return c.isCompatible(e,g,t)},g.prototype._sshpkApiVersion=[1,0],g._oldVersionDetect=function(e){return[1,0]}},function(e,t,n){(function(e,r){var i;/*! https://mths.be/punycode v1.4.1 by @mathias */!function(o){var s=t&&!t.nodeType&&t,a=e&&!e.nodeType&&e,l="object"==typeof r&&r;l.global!==l&&l.window!==l&&l.self!==l||(o=l);var u,c=2147483647,h=36,f=1,p=26,d=38,m=700,g=72,y=128,v="-",b=/^xn--/,_=/[^\x20-\x7E]/,w=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},E=h-f,S=Math.floor,x=String.fromCharCode,C;function A(e){throw new RangeError(k[e])}function T(e,t){for(var n=e.length,r=[];n--;)r[n]=t(e[n]);return r}function I(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(w,".");var i=e.split("."),o=T(i,t).join(".");return r+o}function j(e){for(var t=[],n=0,r=e.length,i,o;n<r;)i=e.charCodeAt(n++),i>=55296&&i<=56319&&n<r?(o=e.charCodeAt(n++),56320==(64512&o)?t.push(((1023&i)<<10)+(1023&o)+65536):(t.push(i),n--)):t.push(i);return t}function R(e){return T(e,function(e){var t="";return e>65535&&(e-=65536,t+=x(e>>>10&1023|55296),e=56320|1023&e),t+=x(e),t}).join("")}function B(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:h}function O(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function P(e,t,n){var r=0;for(e=n?S(e/m):e>>1,e+=S(e/t);e>E*p>>1;r+=h)e=S(e/E);return S(r+(E+1)*e/(e+d))}function N(e){var t=[],n=e.length,r,i=0,o=y,s=g,a,l,u,d,m,b,_,w,k;for(a=e.lastIndexOf(v),a<0&&(a=0),l=0;l<a;++l)e.charCodeAt(l)>=128&&A("not-basic"),t.push(e.charCodeAt(l));for(u=a>0?a+1:0;u<n;){for(d=i,m=1,b=h;u>=n&&A("invalid-input"),_=B(e.charCodeAt(u++)),(_>=h||_>S((c-i)/m))&&A("overflow"),i+=_*m,w=b<=s?f:b>=s+p?p:b-s,!(_<w);b+=h)k=h-w,m>S(c/k)&&A("overflow"),m*=k;r=t.length+1,s=P(i-d,r,0==d),S(i/r)>c-o&&A("overflow"),o+=S(i/r),i%=r,t.splice(i++,0,o)}return R(t)}function D(e){var t,n,r,i,o,s,a,l,u,d,m,b=[],_,w,k,E;for(e=j(e),_=e.length,t=y,n=0,o=g,s=0;s<_;++s)m=e[s],m<128&&b.push(x(m));for(r=i=b.length,i&&b.push(v);r<_;){for(a=c,s=0;s<_;++s)m=e[s],m>=t&&m<a&&(a=m);for(w=r+1,a-t>S((c-n)/w)&&A("overflow"),n+=(a-t)*w,t=a,s=0;s<_;++s)if(m=e[s],m<t&&++n>c&&A("overflow"),m==t){for(l=n,u=h;d=u<=o?f:u>=o+p?p:u-o,!(l<d);u+=h)E=l-d,k=h-d,b.push(x(O(d+E%k,0))),l=S(E/k);b.push(x(O(l,0))),o=P(n,w,r==i),n=0,++r}++n,++t}return b.join("")}function M(e){return I(e,function(e){return b.test(e)?N(e.slice(4).toLowerCase()):e})}function F(e){return I(e,function(e){return _.test(e)?"xn--"+D(e):e})}u={version:"1.4.1",ucs2:{decode:j,encode:R},decode:N,encode:D,toASCII:F,toUnicode:M},i=function(){return u}.call(t,n,t,e),void 0===i||(e.exports=i)}(this)}).call(this,n(85)(e),n(8))},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0}),t.hasNextTick=t.hasSetImmediate=void 0,t.fallback=u,t.wrap=c;var r=n(86),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}var s=t.hasSetImmediate="function"==typeof setImmediate&&setImmediate,a=t.hasNextTick="object"==typeof e&&"function"==typeof e.nextTick,l;function u(e){setTimeout(e,0)}function c(e){return function(t){var n=(0,i.default)(arguments,1);e(function(){t.apply(null,n)})}}l=s?setImmediate:a?e.nextTick:u,t.default=c(l)}).call(this,n(3))},function(e,t){function n(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}e.exports=n},function(e,t,n){var r=n(79),i=r.Symbol;e.exports=i},function(e,t,n){"use strict";function r(e){return function(){if(null!==e){var t=e;e=null,t.apply(this,arguments)}}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t){function n(e){return e<10?"0"+e:e}var r=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,i=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,o,s,a={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},l;function u(e){return i.lastIndex=0,i.test(e)?'"'+e.replace(i,function(e){var t=a[e];return"string"==typeof t?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}function c(e,t){var n,r,i,a,h=o,f,p=t[e];switch(p&&"object"==typeof p&&"function"==typeof p.toJSON&&(p=p.toJSON(e)),"function"==typeof l&&(p=l.call(t,e,p)),typeof p){case"string":return u(p);case"number":return isFinite(p)?String(p):"null";case"boolean":case"null":return String(p);case"object":if(!p)return"null";if(o+=s,f=[],"[object Array]"===Object.prototype.toString.apply(p)){for(a=p.length,n=0;n<a;n+=1)f[n]=c(n,p)||"null";return i=0===f.length?"[]":o?"[\n"+o+f.join(",\n"+o)+"\n"+h+"]":"["+f.join(",")+"]",o=h,i}if(l&&"object"==typeof l)for(a=l.length,n=0;n<a;n+=1)"string"==typeof l[n]&&(r=l[n],i=c(r,p),i&&f.push(u(r)+(o?": ":":")+i));else{var d=Object.keys(p).sort();for(n in d)r=d[n],Object.prototype.hasOwnProperty.call(p,r)&&(i=c(r,p),i&&f.push(u(r)+(o?": ":":")+i))}return i=0===f.length?"{}":o?"{\n"+o+f.join(",\n"+o)+"\n"+h+"}":"{"+f.join(",")+"}",o=h,i}}var h=function(e,t,n){var r;if(o="",s="","number"==typeof n)for(r=0;r<n;r+=1)s+=" ";else"string"==typeof n&&(s=n);if(l=t,t&&"function"!=typeof t&&("object"!=typeof t||"number"!=typeof t.length))throw new Error("JSON.stringify");return c("",{"":e})};e.exports=h},function(e,t,n){"use strict";var r=n(150);e.exports=function e(t,n,i){i||(i=n,n=null);var o=r(function(e){n=t(n,e)},function(e){i(e,n)});return 2===arguments.length?function(e){e(null,function(t,r){if(t)return i(!0===t?null:t);n=r,o(e)})}:o}},function(e,t,n){"use strict";e.exports=function e(t,n){var r=!1;function i(e){!r&&n&&(r=!0,n(!0===e?null:e))}return function(e){return function(n,r){return n&&i(n),e(n,function(e,n){e?i(e):t&&t(n),r(e,n)})}}}},function(e,t,n){"use strict";var r=n(40),i=n(116);e.exports=function e(){return function(e){var t;return function(n,o){function s(){t(null,function(t,n){!0===t?a():t?e(!0,function(e){o(t)}):o(null,n)})}function a(){t=null,e(null,function(e,n){if(e)return o(e);Array.isArray(n)||n&&"object"==typeof n?n=r(n):"function"!=typeof n&&(n=i(n)),t=n,s()})}n?t?t(n,function(t){e(t||n,o)}):e(n,o):t?s():a()}}}},function(e,t){e.exports=function(){var e,t,n,r,i=function(i,o){e?e(i,o):i?(r=i,n=o):t=o};return i.resolve=function(i){if(e)throw new Error("already resolved");if(e=i,!e)throw new Error("no read cannot resolve!"+e);t&&i(null,t),n&&i(r,n)},i.abort=function(e){i.resolve(function(t,n){n(e||!0)})},i}},function(e,t,n){"use strict";t.util=n(352),t.resolver=n(365)},function(e,t,n){"use strict";const r=n(55);t.MT={POS_INT:0,NEG_INT:1,BYTE_STRING:2,UTF8_STRING:3,ARRAY:4,MAP:5,TAG:6,SIMPLE_FLOAT:7},t.TAG={DATE_STRING:0,DATE_EPOCH:1,POS_BIGINT:2,NEG_BIGINT:3,DECIMAL_FRAC:4,BIGFLOAT:5,BASE64URL_EXPECTED:21,BASE64_EXPECTED:22,BASE16_EXPECTED:23,CBOR:24,URI:32,BASE64URL:33,BASE64:34,REGEXP:35,MIME:36},t.NUMBYTES={ZERO:0,ONE:24,TWO:25,FOUR:26,EIGHT:27,INDEFINITE:31},t.SIMPLE={FALSE:20,TRUE:21,NULL:22,UNDEFINED:23},t.SYMS={NULL:Symbol("null"),UNDEFINED:Symbol("undef"),PARENT:Symbol("parent"),BREAK:Symbol("break"),STREAM:Symbol("stream")},t.SHIFT32=Math.pow(2,32),t.SHIFT16=Math.pow(2,16),t.MAX_SAFE_HIGH=2097151,t.NEG_ONE=new r(-1),t.TEN=new r(10),t.TWO=new r(2),t.PARENT={ARRAY:0,OBJECT:1,MAP:2,TAG:3,BYTE_STRING:4,UTF8_STRING:5}},function(e,t,n){"use strict";const{URLWithLegacySupport:r,format:i,URLSearchParams:o,defaultBase:s}=n(356),a=n(713);e.exports={URL:r,URLSearchParams:o,format:i,relative:a,defaultBase:s}},function(e,t,n){"use strict";(function(r){const i=n(24),o=n(39);class s{constructor(e,t,n){0!==n&&i(n,"A DAGNode requires it's serialized size"),this._data=e||r.alloc(0),this._links=t||[],this._serializedSize=n}toJSON(){return this._json||(this._json=Object.freeze({data:this.data,links:this.links.map(e=>e.toJSON()),size:this.size})),Object.assign({},this._json)}toString(){return`DAGNode <data: "${this.data.toString("base64")}", links: ${this.links.length}, size: ${this.size}>`}get data(){return this._data}set data(e){throw new Error("Can't set property: 'data' is immutable")}get links(){return this._links}set links(e){throw new Error("Can't set property: 'links' is immutable")}get size(){return void 0===this._size&&(this._size=this.links.reduce((e,t)=>e+t.size,this._serializedSize)),this._size}set size(e){throw new Error("Can't set property: 'size' is immutable")}}t=e.exports=o(s,{className:"DAGNode",symbolName:"@ipld/js-ipld-dag-pb/dagnode"}),t.create=n(193),t.clone=n(742),t.addLink=n(743),t.rmLink=n(744)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(728),{serialize:i}=n(194),o=n(195),s=o.linkSort,a=n(192),l=n(96);function u(e,n,o){if("function"==typeof e?(o=e,e=void 0):"string"==typeof e&&(e=t.from(e)),"function"==typeof n&&(o=n,n=[]),!t.isBuffer(e))return o(new Error("Passed 'data' is not a buffer or a string!"));n=n.map(e=>l.isDAGLink(e)?e:l.util.createDagLinkFromB58EncodedHash(e)),n=r(n,s),i({data:e,links:n},(t,r)=>t?o(t):o(null,new a(e,n,r.length)))}e.exports=u}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(9),o=n(57),s=o(n(739)),a=n(366),l=n(96),u=n(192),c=n(56),h=n(10),f=n(20);function p(e,t,n){"function"==typeof t&&(n=t,t={}),t=t||{};const o=t.hashAlg||a.defaultHashAlg;let s=t.version;void 0===s&&(s="sha2-256"===o?0:1),h([t=>{if(r.isBuffer(e))return t(null,e);d(e,t)},(e,t)=>c(e,o,t),(e,t)=>t(null,new i(s,a.multicodec,e))],n)}function d(e,t){let n,{data:r,links:i=[]}=e;!u.isDAGNode(e)&&i&&(i=i.map(e=>l.isDAGLink(e)?e:l.util.createDagLinkFromB58EncodedHash(e)));try{n=s.PBNode.encode(g({data:r,links:i}))}catch(e){return t(e)}t(null,n)}function m(e,t){const n=s.PBNode.decode(e),i=n.Links.map(e=>new l(e.Name,e.Tsize,e.Hash)),o=null==n.Data?r.alloc(0):n.Data;f(()=>t(null,new u(o,i,e.length)))}function g(e){const t={};return e.data&&e.data.length>0?t.Data=e.data:t.Data=null,e.links&&e.links.length>0?t.Links=e.links.map(e=>({Hash:e.cid.buffer,Name:e.name,Tsize:e.size})):t.Links=null,t}t=e.exports,t.serialize=d,t.deserialize=m,t.cid=p}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(96),{cid:o}=n(194);function s(e){let t;return e.data&&e.data.length>0?(t=r.alloc(e.data.length),e.data.copy(t)):t=r.alloc(0),t}function a(e){return e.links.slice()}function l(e,t){return r.compare(e.nameAsBuffer,t.nameAsBuffer)}function u(e,t,n){"function"==typeof t&&(n=t,t={}),o(e,t,(r,o)=>{if(r)return n(r);n(null,new i(t.name||"",e.size,o))})}t=e.exports,t.cloneData=s,t.cloneLinks=a,t.linkSort=l,t.toDAGLink=u}).call(this,n(0).Buffer)},function(e,t,n){var r=n(21);function i(e,t){var n=function(){return new r.aes.Algorithm(e,t)};r.cipher.registerAlgorithm(e,n)}n(370),n(371),n(30),e.exports=r.aes=r.aes||{},r.aes.startEncrypting=function(e,t,n,r){var i=m({key:e,output:n,decrypt:!1,mode:r});return i.start(t),i},r.aes.createEncryptionCipher=function(e,t){return m({key:e,output:null,decrypt:!1,mode:t})},r.aes.startDecrypting=function(e,t,n,r){var i=m({key:e,output:n,decrypt:!0,mode:r});return i.start(t),i},r.aes.createDecryptionCipher=function(e,t){return m({key:e,output:null,decrypt:!0,mode:t})},r.aes.Algorithm=function(e,t){o||f();var n=this;n.name=e,n.mode=new t({blockSize:16,cipher:{encrypt:function(e,t){return d(n._w,e,t,!1)},decrypt:function(e,t){return d(n._w,e,t,!0)}}}),n._init=!1},r.aes.Algorithm.prototype.initialize=function(e){if(!this._init){var t=e.key,n;if("string"!=typeof t||16!==t.length&&24!==t.length&&32!==t.length){if(r.util.isArray(t)&&(16===t.length||24===t.length||32===t.length)){n=t,t=r.util.createBuffer();for(var i=0;i<n.length;++i)t.putByte(n[i])}}else t=r.util.createBuffer(t);if(!r.util.isArray(t)){n=t,t=[];var o=n.length();if(16===o||24===o||32===o){o>>>=2;for(var i=0;i<o;++i)t.push(n.getInt32())}}if(!r.util.isArray(t)||4!==t.length&&6!==t.length&&8!==t.length)throw new Error("Invalid key parameter.");var s=this.mode.name,a=-1!==["CFB","OFB","CTR","GCM"].indexOf(s);this._w=p(t,e.decrypt&&!a),this._init=!0}},r.aes._expandKey=function(e,t){return o||f(),p(e,t)},r.aes._updateBlock=d,i("AES-ECB",r.cipher.modes.ecb),i("AES-CBC",r.cipher.modes.cbc),i("AES-CFB",r.cipher.modes.cfb),i("AES-OFB",r.cipher.modes.ofb),i("AES-CTR",r.cipher.modes.ctr),i("AES-GCM",r.cipher.modes.gcm);var o=!1,s=4,a,l,u,c,h;function f(){o=!0,u=[0,1,2,4,8,16,32,64,128,27,54];for(var e=new Array(256),t=0;t<128;++t)e[t]=t<<1,e[t+128]=t+128<<1^283;a=new Array(256),l=new Array(256),c=new Array(4),h=new Array(4);for(var t=0;t<4;++t)c[t]=new Array(256),h[t]=new Array(256);for(var n=0,r=0,i,s,f,p,d,m,g,t=0;t<256;++t){p=r^r<<1^r<<2^r<<3^r<<4,p=p>>8^255&p^99,a[n]=p,l[p]=n,d=e[p],i=e[n],s=e[i],f=e[s],m=d<<24^p<<16^p<<8^p^d,g=(i^s^f)<<24^(n^f)<<16^(n^s^f)<<8^n^i^f;for(var y=0;y<4;++y)c[y][n]=m,h[y][p]=g,m=m<<24|m>>>8,g=g<<24|g>>>8;0===n?n=r=1:(n=i^e[e[e[i^f]]],r^=e[e[r]])}}function p(e,t){for(var n=e.slice(0),r,i=1,o=n.length,l=o+6+1,c=s*l,f=o;f<c;++f)r=n[f-1],f%o==0?(r=a[r>>>16&255]<<24^a[r>>>8&255]<<16^a[255&r]<<8^a[r>>>24]^u[i]<<24,i++):o>6&&f%o==4&&(r=a[r>>>24]<<24^a[r>>>16&255]<<16^a[r>>>8&255]<<8^a[255&r]),n[f]=n[f-o]^r;if(t){var p,d=h[0],m=h[1],g=h[2],y=h[3],v=n.slice(0);c=n.length;for(var f=0,b=c-s;f<c;f+=s,b-=s)if(0===f||f===c-s)v[f]=n[b],v[f+1]=n[b+3],v[f+2]=n[b+2],v[f+3]=n[b+1];else for(var _=0;_<s;++_)p=n[b+_],v[f+(3&-_)]=d[a[p>>>24]]^m[a[p>>>16&255]]^g[a[p>>>8&255]]^y[a[255&p]];n=v}return n}function d(e,t,n,r){var i=e.length/4-1,o,s,u,f,p,d,m,g,y,v,b,_;r?(o=h[0],s=h[1],u=h[2],f=h[3],p=l):(o=c[0],s=c[1],u=c[2],f=c[3],p=a),d=t[0]^e[0],m=t[r?3:1]^e[1],g=t[2]^e[2],y=t[r?1:3]^e[3];for(var w=3,k=1;k<i;++k)v=o[d>>>24]^s[m>>>16&255]^u[g>>>8&255]^f[255&y]^e[++w],b=o[m>>>24]^s[g>>>16&255]^u[y>>>8&255]^f[255&d]^e[++w],_=o[g>>>24]^s[y>>>16&255]^u[d>>>8&255]^f[255&m]^e[++w],y=o[y>>>24]^s[d>>>16&255]^u[m>>>8&255]^f[255&g]^e[++w],d=v,m=b,g=_;n[0]=p[d>>>24]<<24^p[m>>>16&255]<<16^p[g>>>8&255]<<8^p[255&y]^e[++w],n[r?3:1]=p[m>>>24]<<24^p[g>>>16&255]<<16^p[y>>>8&255]<<8^p[255&d]^e[++w],n[2]=p[g>>>24]<<24^p[y>>>16&255]<<16^p[d>>>8&255]<<8^p[255&m]^e[++w],n[r?1:3]=p[y>>>24]<<24^p[d>>>16&255]<<16^p[m>>>8&255]<<8^p[255&g]^e[++w]}function m(e){e=e||{};var t=(e.mode||"CBC").toUpperCase(),n="AES-"+t,i;i=e.decrypt?r.cipher.createDecipher(n,e.key):r.cipher.createCipher(n,e.key);var o=i.start;return i.start=function(e,t){var n=null;t instanceof r.util.ByteBuffer&&(n=t,t={}),t=t||{},t.output=n,t.iv=e,o.call(i,t)},i}},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(799),o;function s(){this.negative=0,this.words=null,this.length=0}s.fromNumber=function(e){var t=new s;return t.words=[67108863&e],t.length=1,t},s.fromBuffer=function(e){var t=new s;return t.words=new Array(10),t.words[0]=(3&e[28])<<24|e[29]<<16|e[30]<<8|e[31],t.words[1]=(15&e[25])<<22|e[26]<<14|e[27]<<6|e[28]>>>2,t.words[2]=(63&e[22])<<20|e[23]<<12|e[24]<<4|e[25]>>>4,t.words[3]=(255&e[19])<<18|e[20]<<10|e[21]<<2|e[22]>>>6,t.words[4]=(3&e[15])<<24|e[16]<<16|e[17]<<8|e[18],t.words[5]=(15&e[12])<<22|e[13]<<14|e[14]<<6|e[15]>>>2,t.words[6]=(63&e[9])<<20|e[10]<<12|e[11]<<4|e[12]>>>4,t.words[7]=(255&e[6])<<18|e[7]<<10|e[8]<<2|e[9]>>>6,t.words[8]=(3&e[2])<<24|e[3]<<16|e[4]<<8|e[5],t.words[9]=e[0]<<14|e[1]<<6|e[2]>>>2,t.length=10,t.strip()},s.prototype.toBuffer=function(){for(var e=this.words,t=this.length;t<10;++t)e[t]=0;return r.from([e[9]>>>14&255,e[9]>>>6&255,(63&e[9])<<2|e[8]>>>24&3,e[8]>>>16&255,e[8]>>>8&255,255&e[8],e[7]>>>18&255,e[7]>>>10&255,e[7]>>>2&255,(3&e[7])<<6|e[6]>>>20&63,e[6]>>>12&255,e[6]>>>4&255,(15&e[6])<<4|e[5]>>>22&15,e[5]>>>14&255,e[5]>>>6&255,(63&e[5])<<2|e[4]>>>24&3,e[4]>>>16&255,e[4]>>>8&255,255&e[4],e[3]>>>18&255,e[3]>>>10&255,e[3]>>>2&255,(3&e[3])<<6|e[2]>>>20&63,e[2]>>>12&255,e[2]>>>4&255,(15&e[2])<<4|e[1]>>>22&15,e[1]>>>14&255,e[1]>>>6&255,(63&e[1])<<2|e[0]>>>24&3,e[0]>>>16&255,e[0]>>>8&255,255&e[0]])},s.prototype.clone=function(){var e=new s;e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];return e.length=this.length,e.negative=this.negative,e},s.prototype.strip=function(){for(;this.length>1&&0==(0|this.words[this.length-1]);)this.length--;return this},s.prototype.normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},s.prototype.isEven=function(){return 0==(1&this.words[0])},s.prototype.isOdd=function(){return 1==(1&this.words[0])},s.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},s.prototype.ucmp=function(e){if(this.length!==e.length)return this.length>e.length?1:-1;for(var t=this.length-1;t>=0;--t)if(this.words[t]!==e.words[t])return this.words[t]>e.words[t]?1:-1;return 0},s.prototype.gtOne=function(){return this.length>1||this.words[0]>1},s.prototype.isOverflow=function(){return this.ucmp(s.n)>=0},s.prototype.isHigh=function(){return 1===this.ucmp(s.nh)},s.prototype.bitLengthGT256=function(){return this.length>10||10===this.length&&this.words[9]>4194303},s.prototype.iuaddn=function(e){this.words[0]+=e;for(var t=0;this.words[t]>67108863&&t<this.length;++t)this.words[t]-=67108864,this.words[t+1]+=1;return t===this.length&&(this.words[t]=1,this.length+=1),this},s.prototype.iadd=function(e){if(this.negative!==e.negative)return 0!==this.negative?(this.negative=0,this.isub(e),this.negative^=1):(e.negative=0,this.isub(e),e.negative=1),this.normSign();var t,n;this.length>e.length?(t=this,n=e):(t=e,n=this);for(var r=0,i=0;r<n.length;++r){var o=t.words[r]+n.words[r]+i;this.words[r]=67108863&o,i=o>>>26}for(;0!==i&&r<t.length;++r)o=t.words[r]+i,this.words[r]=67108863&o,i=o>>>26;if(this.length=t.length,0!==i)this.words[this.length++]=i;else if(t!==this)for(;r<t.length;++r)this.words[r]=t.words[r];return this},s.prototype.add=function(e){return this.clone().iadd(e)},s.prototype.isub=function(e){if(this.negative!==e.negative)return 0!==this.negative?(this.negative=0,this.iadd(e),this.negative=1):(e.negative=0,this.iadd(e),e.negative=1),this.normSign();var t=this.ucmp(e),n,r;if(0===t)return this.negative=0,this.words[0]=0,this.length=1,this;t>0?(n=this,r=e):(n=e,r=this);for(var i=0,o=0;i<r.length;++i){var s=n.words[i]-r.words[i]+o;o=s>>26,this.words[i]=67108863&s}for(;0!==o&&i<n.length;++i)s=n.words[i]+o,o=s>>26,this.words[i]=67108863&s;if(0===o&&i<n.length&&n!==this)for(;i<n.length;++i)this.words[i]=n.words[i];return this.length=Math.max(this.length,i),n!==this&&(this.negative^=1),this.strip().normSign()},s.prototype.sub=function(e){return this.clone().isub(e)},s.umulTo=function(e,t,n){n.length=e.length+t.length-1;var r=e.words[0],i=t.words[0],o=r*i,s=o/67108864|0;n.words[0]=67108863&o;for(var a=1,l=n.length;a<l;a++){for(var u=s>>>26,c=67108863&s,h=Math.max(0,a-e.length+1),f=Math.min(a,t.length-1);h<=f;h++){var p=a-h,d=e.words[p],m=t.words[h],g=d*m+c;u+=g/67108864|0,c=67108863&g}n.words[a]=c,s=u}return 0!==s&&(n.words[n.length++]=s),n.strip()},s.umulTo10x10=Math.imul?i.umulTo10x10:s.umulTo,s.umulnTo=function(e,t,n){if(0===t)return n.words=[0],n.length=1,n;for(var r=0,i=0;r<e.length;++r){var o=e.words[r]*t+i;n.words[r]=67108863&o,i=o/67108864|0}return i>0?(n.words[r]=i,n.length=e.length+1):n.length=e.length,n},s.prototype.umul=function(e){var t=new s;return t.words=new Array(this.length+e.length),10===this.length&&10===e.length?s.umulTo10x10(this,e,t):1===this.length?s.umulnTo(e,this.words[0],t):1===e.length?s.umulnTo(this,e.words[0],t):s.umulTo(this,e,t)},s.prototype.isplit=function(e){e.length=Math.min(this.length,9);for(var t=0;t<e.length;++t)e.words[t]=this.words[t];if(this.length<=9)return this.words[0]=0,this.length=1,this;var n=this.words[9];for(e.words[e.length++]=4194303&n,t=10;t<this.length;++t){var r=this.words[t];this.words[t-10]=(4194303&r)<<4|n>>>22,n=r}return n>>>=22,this.words[t-10]=n,0===n&&this.length>10?this.length-=10:this.length-=9,this},s.prototype.fireduce=function(){return this.isOverflow()&&this.isub(s.n),this},s.prototype.ureduce=function(){var e=this.clone().isplit(s.tmp).umul(s.nc).iadd(s.tmp);return e.bitLengthGT256()&&(e=e.isplit(s.tmp).umul(s.nc).iadd(s.tmp),e.bitLengthGT256()&&(e=e.isplit(s.tmp).umul(s.nc).iadd(s.tmp))),e.fireduce()},s.prototype.ishrn=function(e){for(var t=(1<<e)-1,n=26-e,r=this.length-1,i=0;r>=0;--r){var o=this.words[r];this.words[r]=i<<n|o>>>e,i=o&t}return this.length>1&&0===this.words[this.length-1]&&(this.length-=1),this},s.prototype.uinvm=function(){for(var e=this.clone(),t=s.n.clone(),n=s.fromNumber(1),r=s.fromNumber(0),i=s.fromNumber(0),o=s.fromNumber(1);e.isEven()&&t.isEven();){for(var a=1,l=1;0==(e.words[0]&l)&&0==(t.words[0]&l)&&a<26;++a,l<<=1);e.ishrn(a),t.ishrn(a)}for(var u=t.clone(),c=e.clone();!e.isZero();){for(var h=0,f=1;0==(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.ishrn(h);h-- >0;)(n.isOdd()||r.isOdd())&&(n.iadd(u),r.isub(c)),n.ishrn(1),r.ishrn(1);for(var p=0,d=1;0==(t.words[0]&d)&&p<26;++p,d<<=1);if(p>0)for(t.ishrn(p);p-- >0;)(i.isOdd()||o.isOdd())&&(i.iadd(u),o.isub(c)),i.ishrn(1),o.ishrn(1);e.ucmp(t)>=0?(e.isub(t),n.isub(i),r.isub(o)):(t.isub(e),i.isub(n),o.isub(r))}if(1===i.negative){i.negative=0;var m=i.ureduce();return m.negative^=1,m.normSign().iadd(s.n)}return i.ureduce()},s.prototype.imulK=function(){this.words[this.length]=0,this.words[this.length+1]=0,this.length+=2;for(var e=0,t=0;e<this.length;++e){var n=0|this.words[e];t+=977*n,this.words[e]=67108863&t,t=64*n+(t/67108864|0)}return 0===this.words[this.length-1]&&(this.length-=1,0===this.words[this.length-1]&&(this.length-=1)),this},s.prototype.redIReduce=function(){this.isplit(s.tmp).imulK().iadd(s.tmp),this.bitLengthGT256()&&this.isplit(s.tmp).imulK().iadd(s.tmp);var e=this.ucmp(s.p);return 0===e?(this.words[0]=0,this.length=1):e>0?this.isub(s.p):this.strip(),this},s.prototype.redNeg=function(){return this.isZero()?s.fromNumber(0):s.p.sub(this)},s.prototype.redAdd=function(e){return this.clone().redIAdd(e)},s.prototype.redIAdd=function(e){return this.iadd(e),this.ucmp(s.p)>=0&&this.isub(s.p),this},s.prototype.redIAdd7=function(){return this.iuaddn(7),this.ucmp(s.p)>=0&&this.isub(s.p),this},s.prototype.redSub=function(e){return this.clone().redISub(e)},s.prototype.redISub=function(e){return this.isub(e),0!==this.negative&&this.iadd(s.p),this},s.prototype.redMul=function(e){return this.umul(e).redIReduce()},s.prototype.redSqr=function(){return this.umul(this).redIReduce()},s.prototype.redSqrt=function(){if(this.isZero())return this.clone();for(var e=this.redSqr(),t=e.redSqr(),n=t.redSqr().redMul(t),r=n.redMul(e),i=r.redMul(this),o=i,s=0;s<54;++s)o=o.redSqr().redSqr().redSqr().redSqr().redMul(i);for(o=o.redSqr().redSqr().redSqr().redSqr().redMul(r),s=0;s<5;++s)o=o.redSqr().redSqr().redSqr().redSqr().redMul(i);return o=o.redSqr().redSqr().redSqr().redSqr().redMul(n),o=o.redSqr().redSqr().redSqr().redSqr().redSqr().redSqr().redMul(n),0===o.redSqr().ucmp(this)?o:null},s.prototype.redInvm=function(){for(var e=this.clone(),t=s.p.clone(),n=s.fromNumber(1),r=s.fromNumber(0),i;e.gtOne()&&t.gtOne();){for(var o=0,a=1;0==(e.words[0]&a)&&o<26;++o,a<<=1);if(o>0)for(e.ishrn(o);o-- >0;)n.isOdd()&&n.iadd(s.p),n.ishrn(1);for(var l=0,u=1;0==(t.words[0]&u)&&l<26;++l,u<<=1);if(l>0)for(t.ishrn(l);l-- >0;)r.isOdd()&&r.iadd(s.p),r.ishrn(1);e.ucmp(t)>=0?(e.isub(t),n.isub(r)):(t.isub(e),r.isub(n))}return i=1===e.length&&1===e.words[0]?n:r,0!==i.negative&&i.iadd(s.p),0!==i.negative?(i.negative=0,i.redIReduce().redNeg()):i.redIReduce()},s.prototype.getNAF=function(e){for(var t=[],n=1<<e+1,r=n-1,i=n>>1,o=this.clone();!o.isZero();){for(var s=0,a=1;0==(o.words[0]&a)&&s<26;++s,a<<=1)t.push(0);if(0!==s)o.ishrn(s);else{var l=o.words[0]&r;if(l>=i)t.push(i-l),o.iuaddn(l-i).ishrn(1);else if(t.push(l),o.words[0]-=l,!o.isZero()){for(s=e-1;s>0;--s)t.push(0);o.ishrn(e)}}}return t},s.prototype.inspect=function(){if(this.isZero())return"0";for(var e=this.toBuffer().toString("hex"),t=0;"0"===e[t];++t);return e.slice(t)},s.n=s.fromBuffer(r.from("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141","hex")),s.nh=s.n.clone().ishrn(1),s.nc=s.fromBuffer(r.from("000000000000000000000000000000014551231950B75FC4402DA1732FC9BEBF","hex")),s.p=s.fromBuffer(r.from("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F","hex")),s.psn=s.p.sub(s.n),s.tmp=new s,s.tmp.words=new Array(10),o=s.fromNumber(1),o.words[3]=0,e.exports=s},function(e,t){t.endianness=function(){return"LE"},t.hostname=function(){return"undefined"!=typeof location?location.hostname:""},t.loadavg=function(){return[]},t.uptime=function(){return 0},t.freemem=function(){return Number.MAX_VALUE},t.totalmem=function(){return Number.MAX_VALUE},t.cpus=function(){return[]},t.type=function(){return"Browser"},t.release=function(){return"undefined"!=typeof navigator?navigator.appVersion:""},t.networkInterfaces=t.getNetworkInterfaces=function(){return{}},t.arch=function(){return"javascript"},t.platform=function(){return"browser"},t.tmpdir=t.tmpDir=function(){return"/tmp"},t.EOL="\n",t.homedir=function(){return"/"}},function(e,t,n){var r=n(5).Buffer;function i(e){r.isBuffer(e)||(e=r.from(e));for(var t=e.length/4|0,n=new Array(t),i=0;i<t;i++)n[i]=e.readUInt32BE(4*i);return n}function o(e){for(var t=0;0<e.length;e++)e[0]=0}function s(e,t,n,r,i){for(var o=n[0],s=n[1],a=n[2],l=n[3],u=e[0]^t[0],c=e[1]^t[1],h=e[2]^t[2],f=e[3]^t[3],p,d,m,g,y=4,v=1;v<i;v++)p=o[u>>>24]^s[c>>>16&255]^a[h>>>8&255]^l[255&f]^t[y++],d=o[c>>>24]^s[h>>>16&255]^a[f>>>8&255]^l[255&u]^t[y++],m=o[h>>>24]^s[f>>>16&255]^a[u>>>8&255]^l[255&c]^t[y++],g=o[f>>>24]^s[u>>>16&255]^a[c>>>8&255]^l[255&h]^t[y++],u=p,c=d,h=m,f=g;return p=(r[u>>>24]<<24|r[c>>>16&255]<<16|r[h>>>8&255]<<8|r[255&f])^t[y++],d=(r[c>>>24]<<24|r[h>>>16&255]<<16|r[f>>>8&255]<<8|r[255&u])^t[y++],m=(r[h>>>24]<<24|r[f>>>16&255]<<16|r[u>>>8&255]<<8|r[255&c])^t[y++],g=(r[f>>>24]<<24|r[u>>>16&255]<<16|r[c>>>8&255]<<8|r[255&h])^t[y++],p>>>=0,d>>>=0,m>>>=0,g>>>=0,[p,d,m,g]}var a=[0,1,2,4,8,16,32,64,128,27,54],l=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var n=[],r=[],i=[[],[],[],[]],o=[[],[],[],[]],s=0,a=0,l=0;l<256;++l){var u=a^a<<1^a<<2^a<<3^a<<4;u=u>>>8^255&u^99,n[s]=u,r[u]=s;var c=e[s],h=e[c],f=e[h],p=257*e[u]^16843008*u;i[0][s]=p<<24|p>>>8,i[1][s]=p<<16|p>>>16,i[2][s]=p<<8|p>>>24,i[3][s]=p,p=16843009*f^65537*h^257*c^16843008*s,o[0][u]=p<<24|p>>>8,o[1][u]=p<<16|p>>>16,o[2][u]=p<<8|p>>>24,o[3][u]=p,0===s?s=a=1:(s=c^e[e[e[f^c]]],a^=e[e[a]])}return{SBOX:n,INV_SBOX:r,SUB_MIX:i,INV_SUB_MIX:o}}();function u(e){this._key=i(e),this._reset()}u.blockSize=16,u.keySize=32,u.prototype.blockSize=u.blockSize,u.prototype.keySize=u.keySize,u.prototype._reset=function(){for(var e=this._key,t=e.length,n=t+6,r=4*(n+1),i=[],o=0;o<t;o++)i[o]=e[o];for(o=t;o<r;o++){var s=i[o-1];o%t==0?(s=s<<8|s>>>24,s=l.SBOX[s>>>24]<<24|l.SBOX[s>>>16&255]<<16|l.SBOX[s>>>8&255]<<8|l.SBOX[255&s],s^=a[o/t|0]<<24):t>6&&o%t==4&&(s=l.SBOX[s>>>24]<<24|l.SBOX[s>>>16&255]<<16|l.SBOX[s>>>8&255]<<8|l.SBOX[255&s]),i[o]=i[o-t]^s}for(var u=[],c=0;c<r;c++){var h=r-c,f=i[h-(c%4?0:4)];u[c]=c<4||h<=4?f:l.INV_SUB_MIX[0][l.SBOX[f>>>24]]^l.INV_SUB_MIX[1][l.SBOX[f>>>16&255]]^l.INV_SUB_MIX[2][l.SBOX[f>>>8&255]]^l.INV_SUB_MIX[3][l.SBOX[255&f]]}this._nRounds=n,this._keySchedule=i,this._invKeySchedule=u},u.prototype.encryptBlockRaw=function(e){return e=i(e),s(e,this._keySchedule,l.SUB_MIX,l.SBOX,this._nRounds)},u.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),n=r.allocUnsafe(16);return n.writeUInt32BE(t[0],0),n.writeUInt32BE(t[1],4),n.writeUInt32BE(t[2],8),n.writeUInt32BE(t[3],12),n},u.prototype.decryptBlock=function(e){e=i(e);var t=e[1];e[1]=e[3],e[3]=t;var n=s(e,this._invKeySchedule,l.INV_SUB_MIX,l.INV_SBOX,this._nRounds),o=r.allocUnsafe(16);return o.writeUInt32BE(n[0],0),o.writeUInt32BE(n[3],4),o.writeUInt32BE(n[2],8),o.writeUInt32BE(n[1],12),o},u.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},e.exports.AES=u},function(e,t,n){"use strict";(function(t){const r=n(70),i=n(27),o=n(60),s=n(22),a=n(72),l=n(826),u=/^https?:\/\/[^/]+\/(ip(f|n)s)\/((\w+).*)/,c=/^\/(ip(f|n)s)\/((\w+).*)/,h=1,f=4,p=/^https?:\/\/([^/]+)\.(ip(?:f|n)s)\.[^/]+/,d=1,m=2;function g(e){const n=S(e);try{const e=t.from(r.decode(n));return i.decode(e),!0}catch(e){return!1}}function y(e){try{return o.isEncoded(e)}catch(e){return!1}}function v(e){try{return new l(e),!0}catch(e){return!1}}function b(e){if(!e)return!1;if(s.isMultiaddr(e))return!0;try{return new s(e),!0}catch(e){return!1}}function _(e){return b(e)&&a.IPFS.matches(e)}function w(e,t,n=h,r=f){const i=S(e);if(!i)return!1;const o=i.match(t);if(!o)return!1;if("ipfs"!==o[n])return!1;let s=o[r];return s&&t===p&&(s=s.toLowerCase()),v(s)}function k(e,t,n=h,r){const i=S(e);if(!i)return!1;const o=i.match(t);if(!o)return!1;if("ipns"!==o[n])return!1;if(r&&t===p){let e=o[r];return e=e.toLowerCase(),v(e)}return!0}function E(e){return"string"==typeof e}function S(e){return t.isBuffer(e)?r.encode(e):!!E(e)&&e}const x=e=>w(e,p,2,1),C=e=>k(e,p,2,1);e.exports={multihash:g,multiaddr:b,peerMultiaddr:_,cid:v,base32cid:e=>"base32"===y(e)&&v(e),ipfsSubdomain:x,ipnsSubdomain:C,subdomain:e=>x(e)||C(e),subdomainPattern:p,ipfsUrl:e=>w(e,u),ipnsUrl:e=>k(e,u),url:e=>w(e,u)||k(e,u),urlPattern:u,ipfsPath:e=>w(e,c),ipnsPath:e=>k(e,c),path:e=>w(e,c)||k(e,c),pathPattern:c,urlOrPath:e=>w(e,u)||k(e,u)||w(e,c)||k(e,c),cidPath:e=>E(e)&&!v(e)&&w(`/ipfs/${e}`,c)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(328),i=a(r),o=n(109),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default,1),e.exports=t.default},function(e,t,n){var r,i;r=this,e.exports=function(e,t,n,r,i){for(t=t.split?t.split("."):t,r=0;r<t.length;r++)e=e?e[t[r]]:i;return e===i?n:e}},function(e,t,n){"use strict";const r=n(19);class i{constructor(e,t){this.child=e,this.transform=t}open(e){this.child.open(e)}put(e,t,n){this.child.put(this.transform.convert(e),t,n)}get(e,t){this.child.get(this.transform.convert(e),t)}has(e,t){this.child.has(this.transform.convert(e),t)}delete(e,t){this.child.delete(this.transform.convert(e),t)}batch(){const e=this.child.batch();return{put:(t,n)=>{e.put(this.transform.convert(t),n)},delete:t=>{e.delete(this.transform.convert(t))},commit:t=>{e.commit(t)}}}query(e){return r(this.child.query(e),r.map(e=>(e.key=this.transform.invert(e.key),e)))}close(e){this.child.close(e)}}e.exports=i},function(e,t,n){"use strict";(function(t){const r=n(19),i=n(849),o=n(28).utils.asyncFilter,s=n(28).utils.asyncSort,a=n(28).Key,l=n(28).Errors,u=n(858);class c{constructor(e,t){let r;t&&t.db?(r=t.db,delete t.db):r=n(862),this.db=i(u(r(e),{valueEncoding:"binary"}),Object.assign({},t,{compression:!1}),e=>{if(e)throw e})}open(e){this.db.open(t=>{if(t)return e(l.dbOpenFailedError(t));e()})}put(e,t,n){this.db.put(e.toString(),t,e=>{if(e)return n(l.dbWriteFailedError(e));n()})}get(e,t){this.db.get(e.toString(),(e,n)=>{if(e)return t(l.notFoundError(e));t(null,n)})}has(e,t){this.db.get(e.toString(),(e,n)=>{if(e)return e.notFound?void t(null,!1):void t(e);t(null,!0)})}delete(e,t){this.db.del(e.toString(),e=>{if(e)return t(l.dbDeleteFailedError(e));t()})}close(e){this.db.close(e)}batch(){const e=[];return{put:(t,n)=>{e.push({type:"put",key:t.toString(),value:n})},delete:t=>{e.push({type:"del",key:t.toString()})},commit:t=>{this.db.batch(e,t)}}}query(e){let n=!0;null!=e.keysOnly&&(n=!e.keysOnly);const i=this.db.db.iterator({keys:!0,values:n,keyAsBuffer:!0}),l=(e,r)=>{if(e)return i.end(t=>{r(t||e)});i.next((e,o,s)=>{if(e)return r(e);if(null==e&&null==o&&null==s)return i.end(e=>{r(e||!0)});const l={key:new a(o,!1)};n&&(l.value=t.from(s)),r(null,l)})};let u=[l],c=[];if(null!=e.prefix){const t=e.prefix;c.push((e,n)=>n(null,e.key.toString().startsWith(t)))}if(null!=e.filters&&(c=c.concat(e.filters)),u=u.concat(c.map(e=>o(e))),null!=e.orders&&(u=u.concat(e.orders.map(e=>s(e)))),null!=e.offset){let t=0;u.push(r.filter(()=>t++>=e.offset))}return null!=e.limit&&u.push(r.take(e.limit)),r.apply(null,u)}}e.exports=c}).call(this,n(0).Buffer)},function(e,t){t.getCallback=function(e,t){return"function"==typeof e?e:t},t.getOptions=function(e){return"object"==typeof e&&null!==e?e:{}}},function(e,t,n){"use strict";const r=n(57),i=n(114),o=n(889),s=n(24),a=n(38),l=n(47),u=n(9),c=n(342),h=n(890),f=n(56),p=r(n(891)),d=n(892);class m{constructor(e){this.full=e,this.wantlist=new Map,this.blocks=new Map}get empty(){return 0===this.blocks.size&&0===this.wantlist.size}addEntry(e,t,n){s(e&&u.isCID(e),"must be a valid cid");const r=e.buffer.toString(),i=this.wantlist.get(r);i?(i.priority=t,i.cancel=Boolean(n)):this.wantlist.set(r,new d(e,t,n))}addBlock(e){s(i.isBlock(e),"must be a valid cid");const t=e.cid.buffer.toString();this.blocks.set(t,e)}cancel(e){s(u.isCID(e),"must be a valid cid");const t=e.buffer.toString();this.wantlist.delete(t),this.addEntry(e,0,!0)}serializeToBitswap100(){const e={wantlist:{entries:Array.from(this.wantlist.values()).map(e=>({block:e.cid.buffer,priority:Number(e.priority),cancel:Boolean(e.cancel)}))},blocks:Array.from(this.blocks.values()).map(e=>e.data)};return this.full&&(e.wantlist.full=!0),p.Message.encode(e)}serializeToBitswap110(){const e={wantlist:{entries:Array.from(this.wantlist.values()).map(e=>({block:e.cid.buffer,priority:Number(e.priority),cancel:Boolean(e.cancel)}))},payload:[]};return this.full&&(e.wantlist.full=!0),this.blocks.forEach(t=>{e.payload.push({prefix:t.cid.prefix,data:t.data})}),p.Message.encode(e)}equals(e){const t=(e,t)=>{if(e.equals&&"function"==typeof e.equals)return e.equals(t)};return!(this.full!==e.full||!o(this.wantlist,e.wantlist,t)||!o(this.blocks,e.blocks,t))}get[Symbol.toStringTag](){const e=Array.from(this.wantlist.keys()),t=Array.from(this.blocks.keys());return`BitswapMessage <full: ${this.full}, list: ${e}, blocks: ${t}>`}}m.deserialize=((e,t)=>{let n;try{n=p.Message.decode(e)}catch(e){return l(()=>t(e))}const r=n.wantlist&&n.wantlist.full||!1,o=new m(r);return n.wantlist&&n.wantlist.entries.forEach(e=>{let n;try{n=new u(e.block)}catch(e){return t(e)}o.addEntry(n,e.priority,e.cancel)}),n.blocks.length>0?a(n.blocks,(e,n)=>{f(e,"sha2-256",(r,s)=>{if(r)return n(r);let a;try{a=new u(s)}catch(r){return t(r)}o.addBlock(new i(e,a)),n()})},e=>{if(e)return t(e);t(null,o)}):n.payload.length>0?a(n.payload,(e,t)=>{if(!e.prefix||!e.data)return l(t);const n=h(e.prefix),r=n[0],s=n[1],a=n[2];f(e.data,a,(n,a)=>{if(n)return t(n);let l;try{l=new u(r,c[s.toString("16")],a)}catch(n){return t(n)}o.addBlock(new i(e.data,l)),t()})},e=>{if(e)return t(e);t(null,o)}):void t(null,o)}),m.Entry=d,e.exports=m},function(e,t,n){"use strict";const{sortBy:r}=n(100),i=n(893);class o{constructor(e){this.set=new Map,this._stats=e}get length(){return this.set.size}add(e,t){const n=e.buffer.toString(),r=this.set.get(n);r?(r.inc(),r.priority=t):(this.set.set(n,new i(e,t)),this._stats&&this._stats.push(null,"wantListSize",1))}remove(e){const t=e.buffer.toString(),n=this.set.get(t);n&&(n.dec(),n.hasRefs()||(this.set.delete(t),this._stats&&this._stats.push(null,"wantListSize",-1)))}removeForce(e){this.set.has(e)&&this.set.delete(e)}forEach(e){return this.set.forEach(e)}entries(){return this.set.entries()}sortedEntries(){return new Map(r(e=>e[1].key,Array.from(this.set.entries())))}contains(e){const t=e.buffer.toString();return this.set.get(t)}}o.Entry=i,e.exports=o},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(943),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t){t.encode=function(e){var t="";for(var n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t},t.decode=function(e){for(var t={},n=e.split("&"),r=0,i=n.length;r<i;r++){var o=n[r].split("=");t[decodeURIComponent(o[0])]=decodeURIComponent(o[1])}return t}},function(e,t){e.exports=function(e,t){var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(960),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t,n){var r=n(26),i=function(){},o=function(e){return e.setHeader&&"function"==typeof e.abort},s=function(e){return e.stdio&&Array.isArray(e.stdio)&&3===e.stdio.length},a=function(e,t,n){if("function"==typeof t)return a(e,null,t);t||(t={}),n=r(n||i);var l=e._writableState,u=e._readableState,c=t.readable||!1!==t.readable&&e.readable,h=t.writable||!1!==t.writable&&e.writable,f=function(){e.writable||p()},p=function(){h=!1,c||n.call(e)},d=function(){c=!1,h||n.call(e)},m=function(t){n.call(e,t?new Error("exited with error code: "+t):null)},g=function(t){n.call(e,t)},y=function(){return(!c||u&&u.ended)&&(!h||l&&l.ended)?void 0:n.call(e,new Error("premature close"))},v=function(){e.req.on("finish",p)};return o(e)?(e.on("complete",p),e.on("abort",y),e.req?v():e.on("request",v)):h&&!l&&(e.on("end",f),e.on("close",f)),s(e)&&e.on("exit",m),e.on("end",d),e.on("finish",p),!1!==t.error&&e.on("error",g),e.on("close",y),function(){e.removeListener("complete",p),e.removeListener("abort",y),e.removeListener("request",v),e.req&&e.req.removeListener("finish",p),e.removeListener("end",f),e.removeListener("close",f),e.removeListener("finish",p),e.removeListener("exit",m),e.removeListener("end",d),e.removeListener("error",g),e.removeListener("close",y)}};e.exports=a},function(e,t){var n=function(){};function r(e,t,n){var r=e.length;if(!r)return n(t);function i(){--r||n(t)}e.forEach(function(e){e?e(t,i):i()}),r||i()}e.exports=function(e){return function(t,n){!function i(){t?r(e,t,n):e.length?e[0]?e[0](null,function(t,o){t?(e.shift(),!0===t?i():r(e,t,n)):n(null,o)}):(e.shift(),i()):n(!0)}()}}},function(e,t,n){"use strict";e.exports=function(){var e,t;function n(n){if("function"!=typeof n)throw new Error("read must be function");if(e)throw new Error("already piped");if(e=n,t){var r=t;t=null,e.apply(null,r)}}function r(n,r){e?e(n,r):t=[n,r]}return{source:r,sink:n}}},function(e,t,n){"use strict";t.Listener=t.listener=n(1046),t.Dialer=t.dialer=n(1050),t.matchSemver=n(1051),t.matchExact=n(469)},function(e,t,n){"use strict";(function(r){const i=n(12),o=n(40),s=n(33),a=n(52),l=n(4);function u(){return(~~(1e9*Math.random())).toString(36)}function c(e,t){i(o(r.isBuffer(e)?[e]:[r.from(e)]),a.encode(),s((e,n)=>{if(e)return t(e);t(null,n[0])}))}function h(e){const t=u();function n(e){return n=>{Array.isArray(n)&&(n=n.join(" ")),e("(%s) %s",t,n)}}const r=n(l("mss:"+e));return r.error=n(l("mss:"+e+":error")),r}t=e.exports,t.writeEncoded=((e,t,n)=>{c(t,(t,r)=>{if(t)return n(t);e.write(r)})}),t.log={},t.log.dialer=(()=>h("dialer\t")),t.log.listener=(()=>h("listener\t"))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(13);e.exports={CONNECTION_FAILED:e=>r(e,"CONNECTION_FAILED"),DIAL_ABORTED:()=>r("Dial was aborted","DIAL_ABORTED"),ERR_BLACKLISTED:()=>r("Dial is currently blacklisted for this peer","ERR_BLACKLISTED"),DIAL_SELF:()=>r("A node cannot dial itself","DIAL_SELF"),INVALID_STATE_TRANSITION:e=>r(e,"INVALID_STATE_TRANSITION"),NO_TRANSPORTS_REGISTERED:()=>r("No transports registered, dial not possible","NO_TRANSPORTS_REGISTERED"),PROTECTOR_REQUIRED:()=>r("No protector provided with private network enforced","PROTECTOR_REQUIRED"),UNEXPECTED_END:()=>r("Unexpected end of input from reader.","UNEXPECTED_END"),maybeUnexpectedEnd:t=>!0===t?e.exports.UNEXPECTED_END():t}},function(e,t,n){var r=n(103),i=r(Object,"create");e.exports=i},function(e,t,n){var r=n(1085),i=n(1086),o=n(1087),s=n(1088),a=n(1089);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=i,l.prototype.get=o,l.prototype.has=s,l.prototype.set=a,e.exports=l},function(e,t,n){var r=n(480);function i(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}e.exports=i},function(e,t,n){var r=n(1091);function i(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}e.exports=i},function(e,t,n){var r=n(285),i=1/0;function o(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}e.exports=o},function(e,t,n){var r=n(1149);function i(e,t){return(e=e||[]).push(t),e}e.exports=function(e,t,n,o){var s,a,l;function u(i){var c=null,h=!1,f=0;if(l=i,s)return i(!!s.abort||s,function(e){o(e),a&&a()});var p=!1,d=r(function(){p||s||(p=!0,i(null,function(e,r){p=!1,function(e,r){s||(s=e,s?h||o(!0===s?null:s):(c=t(c,r),f=c&&c.length||0,null!=c&&m(),f<n&&d()))}(e,r)}))});function m(){if(!h){var t=c;c=null,h=!0,f=0,e(t,function(e){h=!1,!0!==s||f?s&&!0!==s?(o(s),a&&a()):e?i(s=!!e.abort||e,o):f?m():d():o(e)})}}u.abort=function(e){a=function(t){e&&e()};var t=new Error("aborted");t.abort=!0,i(s=t,function(e){e=!0===e?null:e,h||(o&&o(e),a&&a(e))})},d()}return t=t||i,u.abort=function(e){s=new Error("aborted before connecting"),a=function(t){e&&e()}},u}},function(e,t,n){"use strict";(function(t){const{util:{cid:r}}=n(34),i=0,o="sha2-256",s="dag-pb",a=(e,n,a,l)=>{let u=a.cidVersion||i,c=a.hashAlg||o,h=a.codec||s;if(t.isBuffer(e)&&(u=1,h="raw"),"sha2-256"!==c&&(u=1),a.onlyHash)return r(e,{version:u,hashAlg:c},(t,n)=>{l(t,{cid:n,node:e})});n.put(e,{version:u,hashAlg:c,format:h},(t,n)=>{l(t,{cid:n,node:e})})};e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(1164),i=n(154),o=n(10),s=n(34),a=n(45),l=s.DAGLink,u=s.DAGNode,c=n(56),h=n(293),f=n(224),p=n(1165),d=n(12),m=n(344),g=n(74),y=n(1168),v=function(e){return new Promise((n,r)=>{c(e,"murmur3-128",(e,i)=>{if(e)r(e);else{const e=i.slice(2,10),r=e.length,o=t.alloc(r);for(let t=0;t<r;t++)o[r-t-1]=e[t];n(o)}})})};v.code=34;const b={hashFn:v};class _ extends h{constructor(e,t){const n=Object.assign({},b,t);super(e,n),this._bucket=y(n)}async put(e,t,n){try{return await this._bucket.put(e,t),n()}catch(e){return n(e)}}async get(e,t){try{return t(null,await this._bucket.get(e))}catch(e){return t(e)}}childCount(){return this._bucket.leafCount()}directChildrenCount(){return this._bucket.childrenCount()}onlyChild(e){try{return e(null,this._bucket.onlyChild())}catch(t){return e(t)}}eachChildSeries(e,t){d(p(this._bucket.eachLeafSeries()),g((t,n)=>{e(t.key,t.value,n)}),m(t))}flush(e,t,n,r){k(this._options,this._bucket,e,t,n,(e,t)=>{if(e)return r(e);this.multihash=t.cid.buffer,this.size=t.node.size,r(null,t)})}}function w(e,t){return new _(e,t)}function k(e,n,s,c,h,p){const d=n._children;let m=0;const g=[];function v(t,n,i){const o=r(n.toString(16).toUpperCase(),2,"0");if(y.isBucket(t))k(e,t,s,c,null,(e,{cid:t,node:n})=>{e?i(e):(g.push(new l(o,n.size,t)),i())});else{const e=t.value,n=o+t.key;g.push(new l(n,e.size,e.multihash)),i()}}function b(r,i){const l=t.from(d.bitField().reverse()),p=new a("hamt-sharded-directory",l);p.fanout=n.tableSize(),p.hashType=e.hashFn.code,o([e=>u.create(p.marshal(),r,e),(t,n)=>f(t,c,e,n),({cid:e,node:t},n)=>{const r={path:s,size:t.size,multihash:e.buffer};h&&h.push(r),n(null,{cid:e,node:t})}],i)}i(()=>m<d.length,e=>{const t=d.get(m);t?v(t,m,t=>{m++,e(t)}):(m++,e())},e=>{e?p(e):b(g,p)})}e.exports=w,e.exports.hashFn=v}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(e){const r=n(9);function i(e){const t={},n=e.split("-");switch(n.length){case 1:t.avgChunkSize=262144;break;case 2:t.avgChunkSize=o(n[1],"avg");break;case 4:t.minChunkSize=o(n[1],"min"),t.avgChunkSize=o(n[2],"avg"),t.maxChunkSize=o(n[3],"max");break;default:throw new Error('Incorrect chunker format (expected "rabin" "rabin-[avg]" or "rabin-[min]-[avg]-[max]"')}return t}function o(e,t){let n=parseInt(e);if(isNaN(n))throw new Error(`Chunker parameter ${t} must be an integer`);return n}t.normalizePath=(t=>e.isBuffer(t)?new r(t).toString():r.isCID(t)?t.toString():(0===t.indexOf("/ipfs/")&&(t=t.substring("/ipfs/".length)),"/"===t.charAt(t.length-1)&&(t=t.substring(0,t.length-1)),t)),t.parseChunkerString=(e=>{if(e){if(e.startsWith("size-")){const t=e.split("-")[1],n=parseInt(t);if(isNaN(n))throw new Error("Chunker parameter size must be an integer");return{chunker:"fixed",chunkerOptions:{maxChunkSize:n}}}if(e.startsWith("rabin"))return{chunker:"rabin",chunkerOptions:i(e)};throw new Error(`Unrecognized chunker option: ${e}`)}return{chunker:"fixed"}})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(28).Key,i={file:0,directory:1,"hamt-sharded-directory":1};e.exports={FILE_SEPARATOR:"/",MFS_ROOT_KEY:new r("/local/filesroot"),MAX_CHUNK_SIZE:262144,MAX_LINKS:174,FILE_TYPES:i}},function(e,t,n){"use strict";var r=n(1202),i="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_-",o,s,a;function l(){a=!1}function u(e){if(e){if(e!==o){if(e.length!==i.length)throw new Error("Custom alphabet for shortid must be "+i.length+" unique characters. You submitted "+e.length+" characters: "+e);var t=e.split("").filter(function(e,t,n){return t!==n.lastIndexOf(e)});if(t.length)throw new Error("Custom alphabet for shortid must be "+i.length+" unique characters. These characters were not unique: "+t.join(", "));o=e,l()}}else o!==i&&(o=i,l())}function c(e){return u(e),o}function h(e){r.seed(e),s!==e&&(l(),s=e)}function f(){o||u(i);for(var e=o.split(""),t=[],n=r.nextValue(),s;e.length>0;)n=r.nextValue(),s=Math.floor(n*e.length),t.push(e.splice(s,1)[0]);return t.join("")}function p(){return a||(a=f(),a)}function d(e){var t=p();return t[e]}function m(){return o||i}e.exports={get:m,characters:c,seed:h,lookup:d,shuffled:p}},function(e,t,n){"use strict";(function(t){const r=n(45).unmarshal,{formatCid:i,toMfsPath:o,loadNode:s}=n(73),a=n(10),l=n(12),u=n(33),c=n(74),h=n(81),f=n(4)("ipfs:mfs:stat"),p={hash:!1,size:!1,withLocal:!1,cidBase:"base58btc"};e.exports=(e=>(function n(d,m,g){"function"==typeof m&&(g=m,m={}),m=Object.assign({},p,m),f(`Fetching stats for ${d}`),a([t=>o(e,d,t),({mfsPath:n,depth:o},a)=>{l(h(n,e.ipld,{maxDepth:o}),c((n,o)=>m.hash?o(null,{hash:i(n.cid,m.cidBase)}):m.size?o(null,{size:n.size}):void s(e,{cid:n.cid},(e,n)=>{if(e)return o(e);const{node:s,cid:a}=n;if(t.isBuffer(s))return o(null,{hash:i(a,m.cidBase),size:s.length,cumulativeSize:s.length,blocks:0,type:"file",local:void 0,sizeLocal:void 0,withLocality:!1});const l=r(s.data);let u=s.links.length;"file"===l.type&&(u=l.blockSizes.length),o(null,{hash:i(a,m.cidBase),size:l.fileSize()||0,cumulativeSize:s.size,blocks:u,type:l.type,local:void 0,sizeLocal:void 0,withLocality:!1})})),u((e,t)=>e?a(e):t.length?(f(`Stats for ${d}`,t[0]),a(null,t[0])):a(new Error(`${d} does not exist`))))}],g)}))}).call(this,n(0).Buffer)},function(e,t,n){t=e.exports=n(529),t.Stream=t,t.Readable=t,t.Writable=n(532),t.Duplex=n(104),t.Transform=n(535),t.PassThrough=n(1299)},function(e,t,n){var r=e.exports;r.encode=n(1520),r.decode=n(1521),r.byteLength=r.encodingLength=function(e){return r.encode(e).length}},function(e,t,n){"use strict";function r(e,t){for(var n=1,r=e.length,i=e[0],o=e[0],s=1;s<r;++s)if(o=i,i=e[s],t(i,o)){if(s===n){n++;continue}e[n++]=i}return e.length=n,e}function i(e){for(var t=1,n=e.length,r=e[0],i=e[0],o=1;o<n;++o,i=r)if(i=r,r=e[o],r!==i){if(o===t){t++;continue}e[t++]=r}return e.length=t,e}function o(e,t,n){return 0===e.length?e:t?(n||e.sort(t),r(e,t)):(n||e.sort(),i(e))}e.exports=o},function(e,t,n){(function(t){var n=void 0!==t?t:Uint8Array;function r(e,t){if(!(this instanceof r))return new r(e,t);0===arguments.length&&(e=0),this.grow=t&&(isFinite(t.grow)&&i(t.grow)||t.grow)||0,"number"!=typeof e&&void 0!==e||(e=new n(i(e)),e.fill&&!e._isBuffer&&e.fill(0)),this.buffer=e}function i(e){var t=e>>3;return e%8!=0&&t++,t}r.prototype.get=function(e){var t=e>>3;return t<this.buffer.length&&!!(this.buffer[t]&128>>e%8)},r.prototype.set=function(e,t){var n=e>>3;t||1===arguments.length?(this.buffer.length<n+1&&this._grow(Math.max(n+1,Math.min(2*this.buffer.length,this.grow))),this.buffer[n]|=128>>e%8):n<this.buffer.length&&(this.buffer[n]&=~(128>>e%8))},r.prototype._grow=function(e){if(this.buffer.length<e&&e<=this.grow){var t=new n(e);if(t.fill&&t.fill(0),this.buffer.copy)this.buffer.copy(t,0);else for(var r=0;r<this.buffer.length;r++)t[r]=this.buffer[r];this.buffer=t}},e.exports=r}).call(this,n(0).Buffer)},function(e,t,n){var r=n(596),i=n(105),o=n(310),s=n(1613),a=4294967295,l=t,u=t.containers={moov:["mvhd","meta","traks","mvex"],trak:["tkhd","tref","trgr","edts","meta","mdia","udta"],edts:["elst"],mdia:["mdhd","hdlr","elng","minf"],minf:["vmhd","smhd","hmhd","sthd","nmhd","dinf","stbl"],dinf:["dref"],stbl:["stsd","stts","ctts","cslg","stsc","stsz","stz2","stco","co64","stss","stsh","padb","stdp","sdtp","sbgps","sgpds","subss","saizs","saios"],mvex:["mehd","trexs","leva"],moof:["mfhd","meta","trafs"],traf:["tfhd","tfdt","trun","sbgps","sgpds","subss","saizs","saios","meta"]};l.encode=function(e,t,n){return l.encodingLength(e),n=n||0,t=t||i(e.length),l._encode(e,t,n)},l._encode=function(e,t,n){var i=e.type,o=e.length;o>4294967295&&(o=1),t.writeUInt32BE(o,n),t.write(e.type,n+4,4,"ascii");var a=n+8;if(1===o&&(r.encode(e.length,t,a),a+=8),s.fullBoxes[i]&&(t.writeUInt32BE(e.flags||0,a),t.writeUInt8(e.version||0,a),a+=4),u[i]){var c=u[i];c.forEach(function(n){if(5===n.length){var r=e[n]||[];n=n.substr(0,4),r.forEach(function(e){l._encode(e,t,a),a+=l.encode.bytes})}else e[n]&&(l._encode(e[n],t,a),a+=l.encode.bytes)}),e.otherBoxes&&e.otherBoxes.forEach(function(e){l._encode(e,t,a),a+=l.encode.bytes})}else if(s[i]){var h=s[i].encode;h(e,t,a),a+=h.bytes}else{if(!e.buffer)throw new Error("Either `type` must be set to a known type (not'"+i+"') or `buffer` must be set");var f=e.buffer;f.copy(t,a),a+=e.buffer.length}return l.encode.bytes=a-n,t},l.readHeaders=function(e,t,n){if(t=t||0,n=n||e.length,n-t<8)return 8;var i=e.readUInt32BE(t),o=e.toString("ascii",t+4,t+8),a=t+8,l,u;if(1===i){if(n-t<16)return 16;i=r.decode(e,a),a+=8}return s.fullBoxes[o]&&(l=e.readUInt8(a),u=16777215&e.readUInt32BE(a),a+=4),{length:i,headersLen:a-t,contentLen:i-(a-t),type:o,version:l,flags:u}},l.decode=function(e,t,n){t=t||0,n=n||e.length;var r=l.readHeaders(e,t,n);if(!r||r.length>n-t)throw new Error("Data too short");return l.decodeWithoutHeaders(r,e,t+r.headersLen,t+r.length)},l.decodeWithoutHeaders=function(e,t,n,r){n=n||0,r=r||t.length;var i=e.type,a={};if(u[i]){a.otherBoxes=[];for(var c=u[i],h=n;r-h>=8;){var f=l.decode(t,h,r);if(h+=f.length,c.indexOf(f.type)>=0)a[f.type]=f;else if(c.indexOf(f.type+"s")>=0){var p=f.type+"s",d=a[p]=a[p]||[];d.push(f)}else a.otherBoxes.push(f)}}else if(s[i]){var m=s[i].decode;a=m(t,n,r)}else a.buffer=o(t.slice(n,r));return a.length=e.length,a.contentLen=e.contentLen,a.type=e.type,a.version=e.version,a.flags=e.flags,a},l.encodingLength=function(e){var t=e.type,n=8;if(s.fullBoxes[t]&&(n+=4),u[t]){var r=u[t];r.forEach(function(t){if(5===t.length){var r=e[t]||[];t=t.substr(0,4),r.forEach(function(e){e.type=t,n+=l.encodingLength(e)})}else if(e[t]){var i=e[t];i.type=t,n+=l.encodingLength(i)}}),e.otherBoxes&&e.otherBoxes.forEach(function(e){n+=l.encodingLength(e)})}else if(s[t])n+=s[t].encodingLength(e);else{if(!e.buffer)throw new Error("Either `type` must be set to a known type (not'"+t+"') or `buffer` must be set");n+=e.buffer.length}return n>4294967295&&(n+=8),e.length=n,n}},function(e,t,n){"use strict";var r="undefined"!=typeof Uint8Array&&"undefined"!=typeof Uint16Array&&"undefined"!=typeof Int32Array;function i(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.assign=function(e){for(var t=Array.prototype.slice.call(arguments,1);t.length;){var n=t.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(var r in n)i(n,r)&&(e[r]=n[r])}}return e},t.shrinkBuf=function(e,t){return e.length===t?e:e.subarray?e.subarray(0,t):(e.length=t,e)};var o={arraySet:function(e,t,n,r,i){if(t.subarray&&e.subarray)e.set(t.subarray(n,n+r),i);else for(var o=0;o<r;o++)e[i+o]=t[n+o]},flattenChunks:function(e){var t,n,r,i,o,s;for(r=0,t=0,n=e.length;t<n;t++)r+=e[t].length;for(s=new Uint8Array(r),i=0,t=0,n=e.length;t<n;t++)o=e[t],s.set(o,i),i+=o.length;return s}},s={arraySet:function(e,t,n,r,i){for(var o=0;o<r;o++)e[i+o]=t[n+o]},flattenChunks:function(e){return[].concat.apply([],e)}};t.setTyped=function(e){e?(t.Buf8=Uint8Array,t.Buf16=Uint16Array,t.Buf32=Int32Array,t.assign(t,o)):(t.Buf8=Array,t.Buf16=Array,t.Buf32=Array,t.assign(t,s))},t.setTyped(r)},function(e,t,n){var r=n(25),i=n(314),o=n(14),s={sha1:!0,sha256:!0,sha512:!0},a={rsa:!0,dsa:!0,ecdsa:!0};function l(e,t){Error.captureStackTrace&&Error.captureStackTrace(this,t||l),this.message=e,this.name=t.name}function u(e){l.call(this,e,u)}function c(e){var t=e.toLowerCase().split("-");if(2!==t.length)throw new u(t[0].toUpperCase()+" is not a valid algorithm");if("hmac"!==t[0]&&!a[t[0]])throw new u(t[0].toUpperCase()+" type keys are not supported");if(!s[t[1]])throw new u(t[1].toUpperCase()+" is not a supported hash algorithm");return t}o.inherits(l,Error),o.inherits(u,l),e.exports={HASH_ALGOS:s,PK_ALGOS:a,HttpSignatureError:l,InvalidAlgorithmError:u,validateAlgorithm:c,sshKeyToPEM:function e(t){r.string(t,"ssh_key");var n=i.parseKey(t,"ssh");return n.toString("pem")},fingerprint:function e(t){r.string(t,"ssh_key");var n=i.parseKey(t,"ssh");return n.fingerprint("md5").toString("hex")},pemToRsaSSHKey:function e(t,n){r.equal("string",typeof t,"typeof pem");var o=i.parseKey(t,"pem");return o.comment=n,o.toString("ssh")}}},function(e,t,n){var r=n(173).BigInteger,i=r.prototype.Barrett;function o(e,t){this.x=t,this.q=e}function s(e){return e==this||this.q.equals(e.q)&&this.x.equals(e.x)}function a(){return this.x}function l(){return new o(this.q,this.x.negate().mod(this.q))}function u(e){return new o(this.q,this.x.add(e.toBigInteger()).mod(this.q))}function c(e){return new o(this.q,this.x.subtract(e.toBigInteger()).mod(this.q))}function h(e){return new o(this.q,this.x.multiply(e.toBigInteger()).mod(this.q))}function f(){return new o(this.q,this.x.square().mod(this.q))}function p(e){return new o(this.q,this.x.multiply(e.toBigInteger().modInverse(this.q)).mod(this.q))}function d(e,t,n,i){this.curve=e,this.x=t,this.y=n,this.z=null==i?r.ONE:i,this.zinv=null}function m(){null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.x.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)}function g(){null==this.zinv&&(this.zinv=this.z.modInverse(this.curve.q));var e=this.y.toBigInteger().multiply(this.zinv);return this.curve.reduce(e),this.curve.fromBigInteger(e)}function y(e){return e==this||(this.isInfinity()?e.isInfinity():e.isInfinity()?this.isInfinity():(t=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),!!t.equals(r.ZERO)&&(n=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q),n.equals(r.ZERO))));var t,n}function v(){return null==this.x&&null==this.y||this.z.equals(r.ZERO)&&!this.y.toBigInteger().equals(r.ZERO)}function b(){return new d(this.curve,this.x,this.y.negate(),this.z)}function _(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.y.toBigInteger().multiply(this.z).subtract(this.y.toBigInteger().multiply(e.z)).mod(this.curve.q),n=e.x.toBigInteger().multiply(this.z).subtract(this.x.toBigInteger().multiply(e.z)).mod(this.curve.q);if(r.ZERO.equals(n))return r.ZERO.equals(t)?this.twice():this.curve.getInfinity();var i=new r("3"),o=this.x.toBigInteger(),s=this.y.toBigInteger(),a=e.x.toBigInteger(),l=e.y.toBigInteger(),u=n.square(),c=u.multiply(n),h=o.multiply(u),f=t.square().multiply(this.z),p=f.subtract(h.shiftLeft(1)).multiply(e.z).subtract(c).multiply(n).mod(this.curve.q),m=h.multiply(i).multiply(t).subtract(s.multiply(c)).subtract(f.multiply(t)).multiply(e.z).add(t.multiply(c)).mod(this.curve.q),g=c.multiply(this.z).multiply(e.z).mod(this.curve.q);return new d(this.curve,this.curve.fromBigInteger(p),this.curve.fromBigInteger(m),g)}function w(){if(this.isInfinity())return this;if(0==this.y.toBigInteger().signum())return this.curve.getInfinity();var e=new r("3"),t=this.x.toBigInteger(),n=this.y.toBigInteger(),i=n.multiply(this.z),o=i.multiply(n).mod(this.curve.q),s=this.curve.a.toBigInteger(),a=t.square().multiply(e);r.ZERO.equals(s)||(a=a.add(this.z.square().multiply(s))),a=a.mod(this.curve.q);var l=a.square().subtract(t.shiftLeft(3).multiply(o)).shiftLeft(1).multiply(i).mod(this.curve.q),u=a.multiply(e).multiply(t).subtract(o.shiftLeft(1)).shiftLeft(2).multiply(o).subtract(a.square().multiply(a)).mod(this.curve.q),c=i.square().multiply(i).shiftLeft(3).mod(this.curve.q);return new d(this.curve,this.curve.fromBigInteger(l),this.curve.fromBigInteger(u),c)}function k(e){if(this.isInfinity())return this;if(0==e.signum())return this.curve.getInfinity();var t=e,n=t.multiply(new r("3")),i=this.negate(),o=this,s;for(s=n.bitLength()-2;s>0;--s){o=o.twice();var a=n.testBit(s),l=t.testBit(s);a!=l&&(o=o.add(a?this:i))}return o}function E(e,t,n){var r;r=e.bitLength()>n.bitLength()?e.bitLength()-1:n.bitLength()-1;for(var i=this.curve.getInfinity(),o=this.add(t);r>=0;)i=i.twice(),e.testBit(r)?i=n.testBit(r)?i.add(o):i.add(this):n.testBit(r)&&(i=i.add(t)),--r;return i}function S(e,t,n){this.q=e,this.a=this.fromBigInteger(t),this.b=this.fromBigInteger(n),this.infinity=new d(this,null,null),this.reducer=new i(this.q)}function x(){return this.q}function C(){return this.a}function A(){return this.b}function T(e){return e==this||this.q.equals(e.q)&&this.a.equals(e.a)&&this.b.equals(e.b)}function I(){return this.infinity}function j(e){return new o(this.q,e)}function R(e){this.reducer.reduce(e)}function B(e){switch(parseInt(e.substr(0,2),16)){case 0:return this.infinity;case 2:case 3:return null;case 4:case 6:case 7:var t=(e.length-2)/2,n=e.substr(2,t),i=e.substr(t+2,t);return new d(this,this.fromBigInteger(new r(n,16)),this.fromBigInteger(new r(i,16)));default:return null}}function O(e){if(e.isInfinity())return"00";var t=e.getX().toBigInteger().toString(16),n=e.getY().toBigInteger().toString(16),r=this.getQ().toString(16).length;for(r%2!=0&&r++;t.length<r;)t="0"+t;for(;n.length<r;)n="0"+n;return"04"+t+n}o.prototype.equals=s,o.prototype.toBigInteger=a,o.prototype.negate=l,o.prototype.add=u,o.prototype.subtract=c,o.prototype.multiply=h,o.prototype.square=f,o.prototype.divide=p,d.prototype.getX=m,d.prototype.getY=g,d.prototype.equals=y,d.prototype.isInfinity=v,d.prototype.negate=b,d.prototype.add=_,d.prototype.twice=w,d.prototype.multiply=k,d.prototype.multiplyTwo=E,S.prototype.getQ=x,S.prototype.getA=C,S.prototype.getB=A,S.prototype.equals=T,S.prototype.getInfinity=I,S.prototype.fromBigInteger=j,S.prototype.reduce=R,S.prototype.encodePointHex=O,S.prototype.decodePointHex=function(e){var t;switch(parseInt(e.substr(0,2),16)){case 0:return this.infinity;case 2:t=!1;case 3:void 0==t&&(t=!0);var n=e.length-2,i=e.substr(2,n),o=this.fromBigInteger(new r(i,16)),s=o.multiply(o.square().add(this.getA())).add(this.getB()),a=s.sqrt();if(null==a)throw"Invalid point compression";var l=a.toBigInteger();return l.testBit(0)!=t&&(a=this.fromBigInteger(this.getQ().subtract(l))),new d(this,o,a);case 4:case 6:case 7:var n=(e.length-2)/2,i=e.substr(2,n),u=e.substr(n+2,n);return new d(this,this.fromBigInteger(new r(i,16)),this.fromBigInteger(new r(u,16)));default:return null}},S.prototype.encodeCompressedPointHex=function(e){if(e.isInfinity())return"00";var t=e.getX().toBigInteger().toString(16),n=this.getQ().toString(16).length,r;for(n%2!=0&&n++;t.length<n;)t="0"+t;return r=e.getY().toBigInteger().isEven()?"02":"03",r+t},o.prototype.getR=function(){if(void 0!=this.r)return this.r;this.r=null;var e=this.q.bitLength();if(e>128){var t=this.q.shiftRight(e-64);-1==t.intValue()&&(this.r=r.ONE.shiftLeft(e).subtract(this.q))}return this.r},o.prototype.modMult=function(e,t){return this.modReduce(e.multiply(t))},o.prototype.modReduce=function(e){if(null!=this.getR()){for(var t=q.bitLength();e.bitLength()>t+1;){var n=e.shiftRight(t),i=e.subtract(n.shiftLeft(t));this.getR().equals(r.ONE)||(n=n.multiply(this.getR())),e=n.add(i)}for(;e.compareTo(q)>=0;)e=e.subtract(q)}else e=e.mod(q);return e},o.prototype.sqrt=function(){if(!this.q.testBit(0))throw"unsupported";if(this.q.testBit(1)){var e=new o(this.q,this.x.modPow(this.q.shiftRight(2).add(r.ONE),this.q));return e.square().equals(this)?e:null}var t=this.q.subtract(r.ONE),n=t.shiftRight(1);if(!this.x.modPow(n,this.q).equals(r.ONE))return null;var i=t.shiftRight(2),s=i.shiftLeft(1).add(r.ONE),a=this.x,l=modDouble(modDouble(a)),u,c;do{var h;do{h=new r(this.q.bitLength(),new SecureRandom)}while(h.compareTo(this.q)>=0||!h.multiply(h).subtract(l).modPow(n,this.q).equals(t));var f=this.lucasSequence(h,a,s);if(u=f[0],c=f[1],this.modMult(c,c).equals(l))return c.testBit(0)&&(c=c.add(q)),c=c.shiftRight(1),new o(q,c)}while(u.equals(r.ONE)||u.equals(t));return null},o.prototype.lucasSequence=function(e,t,n){for(var i=n.bitLength(),o=n.getLowestSetBit(),s=r.ONE,a=r.TWO,l=e,u=r.ONE,c=r.ONE,h=i-1;h>=o+1;--h)u=this.modMult(u,c),n.testBit(h)?(c=this.modMult(u,t),s=this.modMult(s,l),a=this.modReduce(l.multiply(a).subtract(e.multiply(u))),l=this.modReduce(l.multiply(l).subtract(c.shiftLeft(1)))):(c=u,s=this.modReduce(s.multiply(a).subtract(u)),l=this.modReduce(l.multiply(a).subtract(e.multiply(u))),a=this.modReduce(a.multiply(a).subtract(u.shiftLeft(1))));u=this.modMult(u,c),c=this.modMult(u,t),s=this.modReduce(s.multiply(a).subtract(u)),a=this.modReduce(l.multiply(a).subtract(e.multiply(u))),u=this.modMult(u,c);for(var h=1;h<=o;++h)s=this.modMult(s,a),a=this.modReduce(a.multiply(a).subtract(u.shiftLeft(1))),u=this.modMult(u,u);return[s,a]};var t={ECCurveFp:S,ECPointFp:d,ECFieldElementFp:o};e.exports=t},function(e,t,n){e.exports={read:g,readSSHPrivate:v,write:b};var r=n(25),i=n(84),o=n(29).Buffer,s=n(48),a=n(42),l=n(16),u=n(41),c=n(46),h=n(92),f=n(93),p=n(175),d=n(76),m;function g(e,t){return h.read(e,t)}var y="openssh-key-v1";function v(e,t,i){t=new p({buffer:t});var s=t.readCString();r.strictEqual(s,y,"bad magic string");var u=t.readString(),c=t.readString(),h=t.readBuffer(),g=t.readInt();if(1!==g)throw new Error("OpenSSH-format key file contains multiple keys: this is unsupported.");var v=t.readBuffer();if("public"===e)return r.ok(t.atEnd(),"excess bytes left after key"),f.read(v);var b=t.readBuffer();r.ok(t.atEnd(),"excess bytes left after key");var _=new p({buffer:h});switch(c){case"none":if("none"!==u)throw new Error('OpenSSH-format key uses KDF "none" but specifies a cipher other than "none"');break;case"bcrypt":var w=_.readBuffer(),k=_.readInt(),E=a.opensshCipherInfo(u);if(void 0===m&&(m=n(616)),"string"==typeof i.passphrase&&(i.passphrase=o.from(i.passphrase,"utf-8")),!o.isBuffer(i.passphrase))throw new d.KeyEncryptedError(i.filename,"OpenSSH");var S=new Uint8Array(i.passphrase),x=new Uint8Array(w),C=new Uint8Array(E.keySize+E.blockSize),A=m.pbkdf(S,S.length,x,x.length,C,C.length,k);if(0!==A)throw new Error("bcrypt_pbkdf function returned failure, parameters invalid");C=o.from(C);var T=C.slice(0,E.keySize),I=C.slice(E.keySize,E.keySize+E.blockSize),j=l.createDecipheriv(E.opensslName,T,I);j.setAutoPadding(!1);var R,B=[];for(j.once("error",function(e){if(-1!==e.toString().indexOf("bad decrypt"))throw new Error("Incorrect passphrase supplied, could not decrypt key");throw e}),j.write(b),j.end();null!==(R=j.read());)B.push(R);b=o.concat(B);break;default:throw new Error('OpenSSH-format key uses unknown KDF "'+c+'"')}t=new p({buffer:b});var O=t.readInt(),P=t.readInt();if(O!==P)throw new Error("Incorrect passphrase supplied, could not decrypt key");var N={},D=f.readInternal(N,"private",t.remainder());t.skip(N.consumed);var M=t.readString();return D.comment=M,D}function b(e,t){var i;i=c.isPrivateKey(e)?e.toPublic():e;var s="none",u="none",h=o.alloc(0),f={blockSize:8},d,g;if(void 0!==t&&(d=t.passphrase,"string"==typeof d&&(d=o.from(d,"utf-8")),void 0!==d&&(r.buffer(d,"options.passphrase"),r.optionalString(t.cipher,"options.cipher"),s=t.cipher,void 0===s&&(s="aes128-ctr"),f=a.opensshCipherInfo(s),u="bcrypt")),c.isPrivateKey(e)){g=new p({});var v=l.randomBytes(4).readUInt32BE(0);g.writeInt(v),g.writeInt(v),g.write(e.toBuffer("rfc4253")),g.writeString(e.comment||"");for(var b=1;g._offset%f.blockSize!=0;)g.writeChar(b++);g=g.toBuffer()}switch(u){case"none":break;case"bcrypt":var _=l.randomBytes(16),w=16,k=new p({});k.writeBuffer(_),k.writeInt(16),h=k.toBuffer(),void 0===m&&(m=n(616));var E=new Uint8Array(d),S=new Uint8Array(_),x=new Uint8Array(f.keySize+f.blockSize),C=m.pbkdf(E,E.length,S,S.length,x,x.length,16);if(0!==C)throw new Error("bcrypt_pbkdf function returned failure, parameters invalid");x=o.from(x);var A=x.slice(0,f.keySize),T=x.slice(f.keySize,f.keySize+f.blockSize),I=l.createCipheriv(f.opensslName,A,T);I.setAutoPadding(!1);var j,R=[];for(I.once("error",function(e){throw e}),I.write(g),I.end();null!==(j=I.read());)R.push(j);g=o.concat(R);break;default:throw new Error("Unsupported kdf "+u)}var B=new p({}),O;B.writeCString(y),B.writeString(s),B.writeString(u),B.writeBuffer(h),B.writeInt(1),B.writeBuffer(i.toBuffer("rfc4253")),g&&B.writeBuffer(g),B=B.toBuffer(),O=c.isPrivateKey(e)?"OPENSSH PRIVATE KEY":"OPENSSH PUBLIC KEY";var P=B.toString("base64"),N=P.length+P.length/70+18+16+2*O.length+10;B=o.alloc(N);var D=0;D+=B.write("-----BEGIN "+O+"-----\n",D);for(var M=0;M<P.length;){var F=M+70;F>P.length&&(F=P.length),D+=B.write(P.slice(M,F),D),B[D++]=10,M=F}return D+=B.write("-----END "+O+"-----\n",D),B.slice(0,D)}},function(e,t,n){e.exports={DataError:n(1765),InvalidAccessError:n(1766),KeyFormatNotSupportedError:n(1767),CurrentlyNotSupportedError:n(1768),NotSupportedError:n(324),OperationError:n(1769),QuotaExceededError:n(1770),TypeMismatchError:n(1771)}},function(e,t,n){(function(r){const i=n(645),o=n(77),s=n(4)("dweb-transports:httptools"),a=n(106);let l;function u({concurrency:e}){l=a((e,t)=>{e.loopguard===("undefined"!=typeof window&&window.loopguard)?fetch(e.req).then(n=>{s("Fetch of %s succeeded",e.what),l.concurrency=Math.min(l.concurrency+1,l.running()+6),t(null),e.cb(null,n)}).catch(n=>{l.concurrency=Math.max(l.concurrency-1,6,l.running()-1),t(n),--e.count>0?(s("Retrying fetch of %s in %s ms: %s",e.what,e.ms,n.message),l.push(e)):(s("Requeued fetch of %s failed: %s",e.what,n.message),e.cb(n))}):s("Dropping fetch of %s as window changed from %s to %s",e.what,e.loopguard,window.loopguard)},e)}function c(e,t,n,r){return new Promise((i,o)=>{n=n||1,l.push({req:e,count:n,ms:t,what:r,loopguard:"undefined"!=typeof window&&window.loopguard,cb:(e,t)=>{e?o(e):i(t)}})})}async function h(e,t,n,r){let i,o="undefined"!=typeof window&&window.loopguard;for(n=n||1;n--&&o===("undefined"!=typeof window&&window.loopguard);)try{return await fetch(e)}catch(e){i=e,s("Delaying %s by %d ms because %s",r,t,e.message),await new Promise(e=>{setTimeout(()=>{e()},t)}),t=Math.floor(t*(1+Math.random()))}throw console.warn("loopfetch of",r,"failed"),o!==("undefined"!=typeof window&&window.loopguard)?(s("Looping exited because of page change %s",r),new Error("Looping exited because of page change "+r)):i}"undefined"==typeof fetch&&(fetch=i,Headers=fetch.Headers,Request=fetch.Request),httptools={},u({concurrency:6}),httptools.p_httpfetch=async function(e,t,{wantstream:n=!1,retries:i}={}){try{s("p_httpfetch: %s %o",e,t.headers.range||"");let a=new Request(e,t),l=await c(a,500,i,"fetching "+e);if(l.ok){let e=l.headers.get("Content-Type");return n?l.body:void 0!==e&&e.startsWith("application/json")?l.json():void 0!==e&&e.startsWith("text")?l.text():new r(await l.arrayBuffer())}throw new o.TransportError(`Transport Error ${e} ${l.status}: ${l.statusText}`)}catch(t){throw s("p_httpfetch failed: %s",t.message),t instanceof o.TransportError?t:new o.TransportError(`Transport error thrown by ${e}: ${t.message}`)}},httptools.p_GET=function(e,t={},n){"function"==typeof t&&(n=t,t={});let r=new Headers;(t.start||t.end)&&r.append("range",`bytes=${t.start||0}-${t.end<1/0?t.end:""}`);const i=void 0===t.retries?12:t.retries;let o={method:"GET",headers:r,mode:"cors",cache:t.noCache?"no-cache":"default",redirect:"follow",keepalive:!0};const a=httptools.p_httpfetch(e,o,{retries:i,wantstream:t.wantstream});if(!n)return a;a.then(e=>{try{n(null,e)}catch(e){s("Uncaught error %O",e)}}).catch(e=>n(e))},httptools.p_POST=function(e,t={},n){"function"==typeof t&&(n=t,t={});const r=void 0===t.retries?0:t.retries;let i={method:"POST",headers:{},body:t.data,mode:"cors",cache:"default",redirect:"follow",keepalive:!1};t.contenttype&&(i.headers["Content-Type"]=t.contenttype);const o=httptools.p_httpfetch(e,i,{retries:r});if(!n)return o;o.then(e=>n(null,e)).catch(e=>n(e))},t=e.exports=httptools}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){var r=(0,i.default)(e)?_:w;r(e,(0,v.default)(t),n)};var r=n(147),i=b(r),o=n(243),s=b(o),a=n(328),l=b(a),u=n(109),c=b(u),h=n(58),f=b(h),p=n(183),d=b(p),m=n(107),g=b(m),y=n(37),v=b(y);function b(e){return e&&e.__esModule?e:{default:e}}function _(e,t,n){n=(0,d.default)(n||f.default);var r=0,i=0,o=e.length;function a(e,t){e?n(e):++i!==o&&t!==s.default||n(null)}for(0===o&&n(null);r<o;r++)t(e[r],r,(0,g.default)(a))}var w=(0,c.default)(l.default,1/0);e.exports=t.default},function(e,t){var n=9007199254740991;function r(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=n}e.exports=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default={},e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=d;var r=n(58),i=p(r),o=n(183),s=p(o),a=n(655),l=p(a),u=n(107),c=p(u),h=n(243),f=p(h);function p(e){return e&&e.__esModule?e:{default:e}}function d(e){return function(t,n,r){if(r=(0,s.default)(r||i.default),e<=0||!t)return r(null);var o=(0,l.default)(t),a=!1,u=0,h=!1;function p(e,t){if(u-=1,e)a=!0,r(e);else{if(t===f.default||a&&u<=0)return a=!0,r(null);h||d()}}function d(){for(h=!0;u<e&&!a;){var t=o();if(null===t)return a=!0,void(u<=0&&r(null));u+=1,n(t.value,t.key,(0,c.default)(p))}h=!1}d()}}e.exports=t.default},function(e,t,n){"use strict";var r=n(112).codes.ERR_STREAM_PREMATURE_CLOSE;function i(e){var t=!1;return function(){if(!t){t=!0;for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];e.apply(this,r)}}}function o(){}function s(e){return e.setHeader&&"function"==typeof e.abort}function a(e,t,n){if("function"==typeof t)return a(e,null,t);t||(t={}),n=i(n||o);var l=t.readable||!1!==t.readable&&e.readable,u=t.writable||!1!==t.writable&&e.writable,c=function t(){e.writable||f()},h=e._writableState&&e._writableState.finished,f=function t(){u=!1,h=!0,l||n.call(e)},p=e._readableState&&e._readableState.endEmitted,d=function t(){l=!1,p=!0,u||n.call(e)},m=function t(r){n.call(e,r)},g=function t(){var i;return l&&!p?(e._readableState&&e._readableState.ended||(i=new r),n.call(e,i)):u&&!h?(e._writableState&&e._writableState.ended||(i=new r),n.call(e,i)):void 0},y=function t(){e.req.on("finish",f)};return s(e)?(e.on("complete",f),e.on("abort",g),e.req?y():e.on("request",y)):u&&!e._writableState&&(e.on("end",c),e.on("close",c)),e.on("end",d),e.on("finish",f),!1!==t.error&&e.on("error",m),e.on("close",g),function(){e.removeListener("complete",f),e.removeListener("abort",g),e.removeListener("request",y),e.req&&e.req.removeListener("finish",f),e.removeListener("end",c),e.removeListener("close",c),e.removeListener("finish",f),e.removeListener("end",d),e.removeListener("error",m),e.removeListener("close",g)}}e.exports=a},function(e,t,n){"use strict";e.exports=function e(t,n){n=n||{};var r=n.last||!1,i=!1;if("number"==typeof t){r=!0;var o=t;t=function(){return--o}}return function(e){function n(t){e(!0,function(e){r=!1,t(e||!0)})}return function(o,s){i&&!o?r?n(s):s(i):(i=o)?e(i,s):e(null,function(e,o){(i=i||e)?s(i):t(o)?s(null,o):(i=!0,r?s(null,o):n(s))})}}}},function(e,t,n){"use strict";(function(e){const r=n(55),i=n(190),o=i.SHIFT32,s=i.SHIFT16,a=2097151;function l(e){return e<16?"0"+e.toString(16):e.toString(16)}t.parseHalf=function e(t){var n,r,i;return i=128&t[0]?-1:1,n=(124&t[0])>>2,r=(3&t[0])<<8|t[1],n?31===n?i*(r?NaN:Infinity):i*Math.pow(2,n-25)*(1024+r):5.960464477539063e-8*i*r},t.arrayBufferToBignumber=function(e){const t=e.byteLength;let n="";for(let r=0;r<t;r++)n+=l(e[r]);return new r(n,16)},t.buildMap=(e=>{const t=new Map,n=Object.keys(e),r=n.length;for(let i=0;i<r;i++)t.set(n[i],e[n[i]]);return t}),t.buildInt32=((e,t)=>e*s+t),t.buildInt64=((e,n,i,s)=>{const a=t.buildInt32(e,n),l=t.buildInt32(i,s);return a>2097151?new r(a).times(o).plus(l):a*o+l}),t.writeHalf=function t(n,r){const i=e.allocUnsafe(4);i.writeFloatBE(r,0);const o=i.readUInt32BE(0);if(0!=(8191&o))return!1;var s=o>>16&32768;const a=o>>23&255,l=8388607&o;if(a>=113&&a<=142)s+=(a-112<<10)+(l>>13);else{if(!(a>=103&&a<113))return!1;if(l&(1<<126-a)-1)return!1;s+=l+8388608>>126-a}return n.writeUInt16BE(s,0),!0},t.keySorter=function(e,t){var n=e[0].byteLength,r=t[0].byteLength;return n>r?1:r>n?-1:e[0].compare(t[0])},t.isNegativeZero=(e=>0===e&&1/e<0),t.nextPowerOf2=(e=>{let t=0;if(e&&!(e&e-1))return e;for(;0!==e;)e>>=1,t+=1;return 1<<t})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";t.defined=function(e){return null!==e&&void 0!==e&&("number"!=typeof e||!isNaN(e))}},function(e,t,n){"use strict";e.exports="enum KeyType {\n RSA = 0;\n Ed25519 = 1;\n Secp256k1 = 2;\n}\nmessage PublicKey {\n required KeyType Type = 1;\n required bytes Data = 2;\n}\nmessage PrivateKey {\n required KeyType Type = 1;\n required bytes Data = 2;\n}"},function(e,t,n){var r=n(21);if(n(117),n(369),n(152),n(746),n(750),n(118),n(30),void 0===i)var i=r.jsbn.BigInteger;var o=r.asn1;r.pki=r.pki||{},e.exports=r.pki.rsa=r.rsa=r.rsa||{};var s=r.pki,a=[6,4,2,4,2,4,6,2],l={name:"PrivateKeyInfo",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"PrivateKeyInfo.version",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyVersion"},{name:"PrivateKeyInfo.privateKeyAlgorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"AlgorithmIdentifier.algorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"privateKeyOid"}]},{name:"PrivateKeyInfo",tagClass:o.Class.UNIVERSAL,type:o.Type.OCTETSTRING,constructed:!1,capture:"privateKey"}]},u={name:"RSAPrivateKey",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"RSAPrivateKey.version",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyVersion"},{name:"RSAPrivateKey.modulus",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyModulus"},{name:"RSAPrivateKey.publicExponent",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyPublicExponent"},{name:"RSAPrivateKey.privateExponent",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyPrivateExponent"},{name:"RSAPrivateKey.prime1",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyPrime1"},{name:"RSAPrivateKey.prime2",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyPrime2"},{name:"RSAPrivateKey.exponent1",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyExponent1"},{name:"RSAPrivateKey.exponent2",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyExponent2"},{name:"RSAPrivateKey.coefficient",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"privateKeyCoefficient"}]},c={name:"RSAPublicKey",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"RSAPublicKey.modulus",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"publicKeyModulus"},{name:"RSAPublicKey.exponent",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"publicKeyExponent"}]},h=r.pki.rsa.publicKeyValidator={name:"SubjectPublicKeyInfo",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,captureAsn1:"subjectPublicKeyInfo",value:[{name:"SubjectPublicKeyInfo.AlgorithmIdentifier",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"AlgorithmIdentifier.algorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"publicKeyOid"}]},{name:"SubjectPublicKeyInfo.subjectPublicKey",tagClass:o.Class.UNIVERSAL,type:o.Type.BITSTRING,constructed:!1,value:[{name:"SubjectPublicKeyInfo.subjectPublicKey.RSAPublicKey",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,optional:!0,captureAsn1:"rsaPublicKey"}]}]},f=function(e){var t;if(!(e.algorithm in s.oids)){var n=new Error("Unknown message digest algorithm.");throw n.algorithm=e.algorithm,n}t=s.oids[e.algorithm];var r=o.oidToDer(t).getBytes(),i=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[]),a=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[]);a.value.push(o.create(o.Class.UNIVERSAL,o.Type.OID,!1,r)),a.value.push(o.create(o.Class.UNIVERSAL,o.Type.NULL,!1,""));var l=o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,e.digest().getBytes());return i.value.push(a),i.value.push(l),o.toDer(i).getBytes()},p=function(e,t,n){if(n)return e.modPow(t.e,t.n);if(!t.p||!t.q)return e.modPow(t.d,t.n);var o;t.dP||(t.dP=t.d.mod(t.p.subtract(i.ONE))),t.dQ||(t.dQ=t.d.mod(t.q.subtract(i.ONE))),t.qInv||(t.qInv=t.q.modInverse(t.p));do{o=new i(r.util.bytesToHex(r.random.getBytes(t.n.bitLength()/8)),16)}while(o.compareTo(t.n)>=0||!o.gcd(t.n).equals(i.ONE));e=e.multiply(o.modPow(t.e,t.n)).mod(t.n);for(var s=e.mod(t.p).modPow(t.dP,t.p),a=e.mod(t.q).modPow(t.dQ,t.q);s.compareTo(a)<0;)s=s.add(t.p);var l=s.subtract(a).multiply(t.qInv).mod(t.p).multiply(t.q).add(a);return l=l.multiply(o.modInverse(t.n)).mod(t.n),l};function d(e,t,n){var i=r.util.createBuffer(),o=Math.ceil(t.n.bitLength()/8);if(e.length>o-11){var s=new Error("Message is too long for PKCS#1 v1.5 padding.");throw s.length=e.length,s.max=o-11,s}i.putByte(0),i.putByte(n);var a=o-3-e.length,l;if(0===n||1===n){l=0===n?0:255;for(var u=0;u<a;++u)i.putByte(l)}else for(;a>0;){for(var c=0,h=r.random.getBytes(a),u=0;u<a;++u)l=h.charCodeAt(u),0===l?++c:i.putByte(l);a=c}return i.putByte(0),i.putBytes(e),i}function m(e,t,n,i){var o=Math.ceil(t.n.bitLength()/8),s=r.util.createBuffer(e),a=s.getByte(),l=s.getByte();if(0!==a||n&&0!==l&&1!==l||!n&&2!=l||n&&0===l&&void 0===i)throw new Error("Encryption block is invalid.");var u=0;if(0===l){u=o-3-i;for(var c=0;c<u;++c)if(0!==s.getByte())throw new Error("Encryption block is invalid.")}else if(1===l)for(u=0;s.length()>1;){if(255!==s.getByte()){--s.read;break}++u}else if(2===l)for(u=0;s.length()>1;){if(0===s.getByte()){--s.read;break}++u}var h=s.getByte();if(0!==h||u!==o-3-s.length())throw new Error("Encryption block is invalid.");return s.getBytes()}function g(e,t,n){"function"==typeof t&&(n=t,t={}),t=t||{};var o={algorithm:{name:t.algorithm||"PRIMEINC",options:{workers:t.workers||2,workLoad:t.workLoad||100,workerScript:t.workerScript}}};function a(){l(e.pBits,function(t,r){return t?n(t):(e.p=r,null!==e.q?u(t,e.q):void l(e.qBits,u))})}function l(e,t){r.prime.generateProbablePrime(e,o,t)}function u(t,r){if(t)return n(t);if(e.q=r,e.p.compareTo(e.q)<0){var o=e.p;e.p=e.q,e.q=o}if(0!==e.p.subtract(i.ONE).gcd(e.e).compareTo(i.ONE))return e.p=null,void a();if(0!==e.q.subtract(i.ONE).gcd(e.e).compareTo(i.ONE))return e.q=null,void l(e.qBits,u);if(e.p1=e.p.subtract(i.ONE),e.q1=e.q.subtract(i.ONE),e.phi=e.p1.multiply(e.q1),0!==e.phi.gcd(e.e).compareTo(i.ONE))return e.p=e.q=null,void a();if(e.n=e.p.multiply(e.q),e.n.bitLength()!==e.bits)return e.q=null,void l(e.qBits,u);var c=e.e.modInverse(e.phi);e.keys={privateKey:s.rsa.setPrivateKey(e.n,e.e,c,e.p,e.q,c.mod(e.p1),c.mod(e.q1),e.q.modInverse(e.p)),publicKey:s.rsa.setPublicKey(e.n,e.e)},n(null,e.keys)}"prng"in t&&(o.prng=t.prng),a()}function y(e){var t=e.toString(16);t[0]>="8"&&(t="00"+t);var n=r.util.hexToBytes(t);return n.length>1&&(0===n.charCodeAt(0)&&0==(128&n.charCodeAt(1))||255===n.charCodeAt(0)&&128==(128&n.charCodeAt(1)))?n.substr(1):n}function v(e){return e<=100?27:e<=150?18:e<=200?15:e<=250?12:e<=300?9:e<=350?8:e<=400?7:e<=500?6:e<=600?5:e<=800?4:e<=1250?3:2}function b(e){return"undefined"!=typeof window&&"object"==typeof window.crypto&&"object"==typeof window.crypto.subtle&&"function"==typeof window.crypto.subtle[e]}function _(e){return"undefined"!=typeof window&&"object"==typeof window.msCrypto&&"object"==typeof window.msCrypto.subtle&&"function"==typeof window.msCrypto.subtle[e]}function w(e){for(var t=r.util.hexToBytes(e.toString(16)),n=new Uint8Array(t.length),i=0;i<t.length;++i)n[i]=t.charCodeAt(i);return n}function k(e){if("RSA"!==e.kty)throw new Error('Unsupported key algorithm "'+e.kty+'"; algorithm must be "RSA".');return s.setRsaPrivateKey(S(e.n),S(e.e),S(e.d),S(e.p),S(e.q),S(e.dp),S(e.dq),S(e.qi))}function E(e){if("RSA"!==e.kty)throw new Error('Key algorithm must be "RSA".');return s.setRsaPublicKey(S(e.n),S(e.e))}function S(e){return new i(r.util.bytesToHex(r.util.decode64(e)),16)}s.rsa.encrypt=function(e,t,n){var o=n,s,a=Math.ceil(t.n.bitLength()/8);!1!==n&&!0!==n?(o=2===n,s=d(e,t,n)):(s=r.util.createBuffer(),s.putBytes(e));for(var l=new i(s.toHex(),16),u=p(l,t,o),c=u.toString(16),h=r.util.createBuffer(),f=a-Math.ceil(c.length/2);f>0;)h.putByte(0),--f;return h.putBytes(r.util.hexToBytes(c)),h.getBytes()},s.rsa.decrypt=function(e,t,n,o){var s=Math.ceil(t.n.bitLength()/8);if(e.length!==s){var a=new Error("Encrypted message length is invalid.");throw a.length=e.length,a.expected=s,a}var l=new i(r.util.createBuffer(e).toHex(),16);if(l.compareTo(t.n)>=0)throw new Error("Encrypted message is invalid.");for(var u=p(l,t,n),c=u.toString(16),h=r.util.createBuffer(),f=s-Math.ceil(c.length/2);f>0;)h.putByte(0),--f;return h.putBytes(r.util.hexToBytes(c)),!1!==o?m(h.getBytes(),t,n):h.getBytes()},s.rsa.createKeyPairGenerationState=function(e,t,n){"string"==typeof e&&(e=parseInt(e,10)),e=e||2048,n=n||{};var o=n.prng||r.random,s={nextBytes:function(e){for(var t=o.getBytesSync(e.length),n=0;n<e.length;++n)e[n]=t.charCodeAt(n)}},a=n.algorithm||"PRIMEINC",l;if("PRIMEINC"!==a)throw new Error("Invalid key generation algorithm: "+a);return l={algorithm:a,state:0,bits:e,rng:s,eInt:t||65537,e:new i(null),p:null,q:null,qBits:e>>1,pBits:e-(e>>1),pqState:0,num:null,keys:null},l.e.fromInt(l.eInt),l},s.rsa.stepKeyPairGenerationState=function(e,t){"algorithm"in e||(e.algorithm="PRIMEINC");var n=new i(null);n.fromInt(30);for(var r=0,o=function(e,t){return e|t},l=+new Date,u,c=0;null===e.keys&&(t<=0||c<t);){if(0===e.state){var h=null===e.p?e.pBits:e.qBits,f=h-1;0===e.pqState?(e.num=new i(h,e.rng),e.num.testBit(f)||e.num.bitwiseTo(i.ONE.shiftLeft(f),o,e.num),e.num.dAddOffset(31-e.num.mod(n).byteValue(),0),r=0,++e.pqState):1===e.pqState?e.num.bitLength()>h?e.pqState=0:e.num.isProbablePrime(v(e.num.bitLength()))?++e.pqState:e.num.dAddOffset(a[r++%8],0):2===e.pqState?e.pqState=0===e.num.subtract(i.ONE).gcd(e.e).compareTo(i.ONE)?3:0:3===e.pqState&&(e.pqState=0,null===e.p?e.p=e.num:e.q=e.num,null!==e.p&&null!==e.q&&++e.state,e.num=null)}else if(1===e.state)e.p.compareTo(e.q)<0&&(e.num=e.p,e.p=e.q,e.q=e.num),++e.state;else if(2===e.state)e.p1=e.p.subtract(i.ONE),e.q1=e.q.subtract(i.ONE),e.phi=e.p1.multiply(e.q1),++e.state;else if(3===e.state)0===e.phi.gcd(e.e).compareTo(i.ONE)?++e.state:(e.p=null,e.q=null,e.state=0);else if(4===e.state)e.n=e.p.multiply(e.q),e.n.bitLength()===e.bits?++e.state:(e.q=null,e.state=0);else if(5===e.state){var p=e.e.modInverse(e.phi);e.keys={privateKey:s.rsa.setPrivateKey(e.n,e.e,p,e.p,e.q,p.mod(e.p1),p.mod(e.q1),e.q.modInverse(e.p)),publicKey:s.rsa.setPublicKey(e.n,e.e)}}u=+new Date,c+=u-l,l=u}return null!==e.keys},s.rsa.generateKeyPair=function(e,t,n,i){if(1===arguments.length?"object"==typeof e?(n=e,e=void 0):"function"==typeof e&&(i=e,e=void 0):2===arguments.length?"number"==typeof e?"function"==typeof t?(i=t,t=void 0):"number"!=typeof t&&(n=t,t=void 0):(n=e,i=t,e=void 0,t=void 0):3===arguments.length&&("number"==typeof t?"function"==typeof n&&(i=n,n=void 0):(i=n,n=t,t=void 0)),n=n||{},void 0===e&&(e=n.bits||2048),void 0===t&&(t=n.e||65537),!r.options.usePureJavaScript&&i&&e>=256&&e<=16384&&(65537===t||3===t)){if(b("generateKey")&&b("exportKey"))return window.crypto.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:e,publicExponent:w(t),hash:{name:"SHA-256"}},!0,["sign","verify"]).then(function(e){return window.crypto.subtle.exportKey("pkcs8",e.privateKey)}).then(void 0,function(e){i(e)}).then(function(e){if(e){var t=s.privateKeyFromAsn1(o.fromDer(r.util.createBuffer(e)));i(null,{privateKey:t,publicKey:s.setRsaPublicKey(t.n,t.e)})}});if(_("generateKey")&&_("exportKey")){var a=window.msCrypto.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:e,publicExponent:w(t),hash:{name:"SHA-256"}},!0,["sign","verify"]);return a.oncomplete=function(e){var t=e.target.result,n=window.msCrypto.subtle.exportKey("pkcs8",t.privateKey);n.oncomplete=function(e){var t=e.target.result,n=s.privateKeyFromAsn1(o.fromDer(r.util.createBuffer(t)));i(null,{privateKey:n,publicKey:s.setRsaPublicKey(n.n,n.e)})},n.onerror=function(e){i(e)}},void(a.onerror=function(e){i(e)})}}var l=s.rsa.createKeyPairGenerationState(e,t,n);if(!i)return s.rsa.stepKeyPairGenerationState(l,0),l.keys;g(l,n,i)},s.setRsaPublicKey=s.rsa.setPublicKey=function(e,t){var n={n:e,e:t,encrypt:function(e,t,i){if("string"==typeof t?t=t.toUpperCase():void 0===t&&(t="RSAES-PKCS1-V1_5"),"RSAES-PKCS1-V1_5"===t)t={encode:function(e,t,n){return d(e,t,2).getBytes()}};else if("RSA-OAEP"===t||"RSAES-OAEP"===t)t={encode:function(e,t){return r.pkcs1.encode_rsa_oaep(t,e,i)}};else if(-1!==["RAW","NONE","NULL",null].indexOf(t))t={encode:function(e){return e}};else if("string"==typeof t)throw new Error('Unsupported encryption scheme: "'+t+'".');var o=t.encode(e,n,!0);return s.rsa.encrypt(o,n,!0)},verify:function(e,t,r){"string"==typeof r?r=r.toUpperCase():void 0===r&&(r="RSASSA-PKCS1-V1_5"),"RSASSA-PKCS1-V1_5"===r?r={verify:function(e,t){t=m(t,n,!0);var r=o.fromDer(t);return e===r.value[1].value}}:"NONE"!==r&&"NULL"!==r&&null!==r||(r={verify:function(e,t){return t=m(t,n,!0),e===t}});var i=s.rsa.decrypt(t,n,!0,!1);return r.verify(e,i,n.n.bitLength())}};return n},s.setRsaPrivateKey=s.rsa.setPrivateKey=function(e,t,n,i,o,a,l,u){var c={n:e,e:t,d:n,p:i,q:o,dP:a,dQ:l,qInv:u,decrypt:function(e,t,n){"string"==typeof t?t=t.toUpperCase():void 0===t&&(t="RSAES-PKCS1-V1_5");var i=s.rsa.decrypt(e,c,!1,!1);if("RSAES-PKCS1-V1_5"===t)t={decode:m};else if("RSA-OAEP"===t||"RSAES-OAEP"===t)t={decode:function(e,t){return r.pkcs1.decode_rsa_oaep(t,e,n)}};else{if(-1===["RAW","NONE","NULL",null].indexOf(t))throw new Error('Unsupported encryption scheme: "'+t+'".');t={decode:function(e){return e}}}return t.decode(i,c,!1)},sign:function(e,t){var n=!1;"string"==typeof t&&(t=t.toUpperCase()),void 0===t||"RSASSA-PKCS1-V1_5"===t?(t={encode:f},n=1):"NONE"!==t&&"NULL"!==t&&null!==t||(t={encode:function(){return e}},n=1);var r=t.encode(e,c.n.bitLength());return s.rsa.encrypt(r,c,n)}};return c},s.wrapRsaPrivateKey=function(e){return o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,o.integerToDer(0).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(s.oids.rsaEncryption).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.NULL,!1,"")]),o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,o.toDer(e).getBytes())])},s.privateKeyFromAsn1=function(e){var t={},n=[],a,c,h,f,p,d,m,g;if(o.validate(e,l,t,n)&&(e=o.fromDer(r.util.createBuffer(t.privateKey))),t={},n=[],!o.validate(e,u,t,n)){var y=new Error("Cannot read private key. ASN.1 object does not contain an RSAPrivateKey.");throw y.errors=n,y}return a=r.util.createBuffer(t.privateKeyModulus).toHex(),c=r.util.createBuffer(t.privateKeyPublicExponent).toHex(),h=r.util.createBuffer(t.privateKeyPrivateExponent).toHex(),f=r.util.createBuffer(t.privateKeyPrime1).toHex(),p=r.util.createBuffer(t.privateKeyPrime2).toHex(),d=r.util.createBuffer(t.privateKeyExponent1).toHex(),m=r.util.createBuffer(t.privateKeyExponent2).toHex(),g=r.util.createBuffer(t.privateKeyCoefficient).toHex(),s.setRsaPrivateKey(new i(a,16),new i(c,16),new i(h,16),new i(f,16),new i(p,16),new i(d,16),new i(m,16),new i(g,16))},s.privateKeyToAsn1=s.privateKeyToRSAPrivateKey=function(e){return o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,o.integerToDer(0).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.n)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.e)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.d)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.p)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.q)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.dP)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.dQ)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.qInv))])},s.publicKeyFromAsn1=function(e){var t={},n=[];if(o.validate(e,h,t,n)){var a=o.derToOid(t.publicKeyOid);if(a!==s.oids.rsaEncryption){var l=new Error("Cannot read public key. Unknown OID.");throw l.oid=a,l}e=t.rsaPublicKey}if(n=[],!o.validate(e,c,t,n)){var l=new Error("Cannot read public key. ASN.1 object does not contain an RSAPublicKey.");throw l.errors=n,l}var u=r.util.createBuffer(t.publicKeyModulus).toHex(),f=r.util.createBuffer(t.publicKeyExponent).toHex();return s.setRsaPublicKey(new i(u,16),new i(f,16))},s.publicKeyToAsn1=s.publicKeyToSubjectPublicKeyInfo=function(e){return o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(s.oids.rsaEncryption).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.NULL,!1,"")]),o.create(o.Class.UNIVERSAL,o.Type.BITSTRING,!1,[s.publicKeyToRSAPublicKey(e)])])},s.publicKeyToRSAPublicKey=function(e){return o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.n)),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,y(e.e))])}},function(e,t,n){var r=n(21);if(n(196),n(117),n(252),n(97),n(152),n(373),n(253),n(118),n(752),n(250),n(30),void 0===i)var i=r.jsbn.BigInteger;var o=r.asn1,s=r.pki=r.pki||{};e.exports=s.pbe=r.pbe=r.pbe||{};var a=s.oids,l={name:"EncryptedPrivateKeyInfo",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"EncryptedPrivateKeyInfo.encryptionAlgorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"AlgorithmIdentifier.algorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"encryptionOid"},{name:"AlgorithmIdentifier.parameters",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,captureAsn1:"encryptionParams"}]},{name:"EncryptedPrivateKeyInfo.encryptedData",tagClass:o.Class.UNIVERSAL,type:o.Type.OCTETSTRING,constructed:!1,capture:"encryptedData"}]},u={name:"PBES2Algorithms",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"PBES2Algorithms.keyDerivationFunc",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"PBES2Algorithms.keyDerivationFunc.oid",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"kdfOid"},{name:"PBES2Algorithms.params",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"PBES2Algorithms.params.salt",tagClass:o.Class.UNIVERSAL,type:o.Type.OCTETSTRING,constructed:!1,capture:"kdfSalt"},{name:"PBES2Algorithms.params.iterationCount",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"kdfIterationCount"},{name:"PBES2Algorithms.params.keyLength",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,optional:!0,capture:"keyLength"},{name:"PBES2Algorithms.params.prf",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,optional:!0,value:[{name:"PBES2Algorithms.params.prf.algorithm",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"prfOid"}]}]}]},{name:"PBES2Algorithms.encryptionScheme",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"PBES2Algorithms.encryptionScheme.oid",tagClass:o.Class.UNIVERSAL,type:o.Type.OID,constructed:!1,capture:"encOid"},{name:"PBES2Algorithms.encryptionScheme.iv",tagClass:o.Class.UNIVERSAL,type:o.Type.OCTETSTRING,constructed:!1,capture:"encIv"}]}]},c={name:"pkcs-12PbeParams",tagClass:o.Class.UNIVERSAL,type:o.Type.SEQUENCE,constructed:!0,value:[{name:"pkcs-12PbeParams.salt",tagClass:o.Class.UNIVERSAL,type:o.Type.OCTETSTRING,constructed:!1,capture:"salt"},{name:"pkcs-12PbeParams.iterations",tagClass:o.Class.UNIVERSAL,type:o.Type.INTEGER,constructed:!1,capture:"iterations"}]};function h(e,t){return e.start().update(t).digest().getBytes()}function f(e){var t;if(e){if(t=s.oids[o.derToOid(e)],!t){var n=new Error("Unsupported PRF OID.");throw n.oid=e,n.supported=["hmacWithSHA1","hmacWithSHA224","hmacWithSHA256","hmacWithSHA384","hmacWithSHA512"],n}}else t="hmacWithSHA1";return p(t)}function p(e){var t=r.md;switch(e){case"hmacWithSHA224":t=r.md.sha512;case"hmacWithSHA1":case"hmacWithSHA256":case"hmacWithSHA384":case"hmacWithSHA512":e=e.substr(8).toLowerCase();break;default:var n=new Error("Unsupported PRF algorithm.");throw n.algorithm=e,n.supported=["hmacWithSHA1","hmacWithSHA224","hmacWithSHA256","hmacWithSHA384","hmacWithSHA512"],n}if(!(t&&e in t))throw new Error("Unknown hash algorithm: "+e);return t[e].create()}function d(e,t,n,i){var a=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,e),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,t.getBytes())]);return"hmacWithSHA1"!==i&&a.value.push(o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,r.util.hexToBytes(n.toString(16))),o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(s.oids[i]).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.NULL,!1,"")])),a}s.encryptPrivateKeyInfo=function(e,t,n){n=n||{},n.saltSize=n.saltSize||8,n.count=n.count||2048,n.algorithm=n.algorithm||"aes128",n.prfAlgorithm=n.prfAlgorithm||"sha1";var i=r.random.getBytesSync(n.saltSize),l=n.count,u=o.integerToDer(l),c,h,f;if(0===n.algorithm.indexOf("aes")||"des"===n.algorithm){var m,g,y;switch(n.algorithm){case"aes128":c=16,m=16,g=a["aes128-CBC"],y=r.aes.createEncryptionCipher;break;case"aes192":c=24,m=16,g=a["aes192-CBC"],y=r.aes.createEncryptionCipher;break;case"aes256":c=32,m=16,g=a["aes256-CBC"],y=r.aes.createEncryptionCipher;break;case"des":c=8,m=8,g=a.desCBC,y=r.des.createEncryptionCipher;break;default:var v=new Error("Cannot encrypt private key. Unknown encryption algorithm.");throw v.algorithm=n.algorithm,v}var b="hmacWith"+n.prfAlgorithm.toUpperCase(),_=p(b),w=r.pkcs5.pbkdf2(t,i,l,c,_),k=r.random.getBytesSync(m),E=y(w);E.start(k),E.update(o.toDer(e)),E.finish(),f=E.output.getBytes();var S=d(i,u,c,b);h=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(a.pkcs5PBES2).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(a.pkcs5PBKDF2).getBytes()),S]),o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(g).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,k)])])])}else{if("3des"!==n.algorithm){var v=new Error("Cannot encrypt private key. Unknown encryption algorithm.");throw v.algorithm=n.algorithm,v}c=24;var x=new r.util.ByteBuffer(i),w=s.pbe.generatePkcs12Key(t,x,1,l,c),k=s.pbe.generatePkcs12Key(t,x,2,l,c),E=r.des.createEncryptionCipher(w);E.start(k),E.update(o.toDer(e)),E.finish(),f=E.output.getBytes(),h=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OID,!1,o.oidToDer(a["pbeWithSHAAnd3-KeyTripleDES-CBC"]).getBytes()),o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,i),o.create(o.Class.UNIVERSAL,o.Type.INTEGER,!1,u.getBytes())])])}var C=o.create(o.Class.UNIVERSAL,o.Type.SEQUENCE,!0,[h,o.create(o.Class.UNIVERSAL,o.Type.OCTETSTRING,!1,f)]);return C},s.decryptPrivateKeyInfo=function(e,t){var n=null,i={},a=[];if(!o.validate(e,l,i,a)){var u=new Error("Cannot read encrypted private key. ASN.1 object is not a supported EncryptedPrivateKeyInfo.");throw u.errors=a,u}var c=o.derToOid(i.encryptionOid),h=s.pbe.getCipher(c,i.encryptionParams,t),f=r.util.createBuffer(i.encryptedData);return h.update(f),h.finish()&&(n=o.fromDer(h.output)),n},s.encryptedPrivateKeyToPem=function(e,t){var n={type:"ENCRYPTED PRIVATE KEY",body:o.toDer(e).getBytes()};return r.pem.encode(n,{maxline:t})},s.encryptedPrivateKeyFromPem=function(e){var t=r.pem.decode(e)[0];if("ENCRYPTED PRIVATE KEY"!==t.type){var n=new Error('Could not convert encrypted private key from PEM; PEM header type is "ENCRYPTED PRIVATE KEY".');throw n.headerType=t.type,n}if(t.procType&&"ENCRYPTED"===t.procType.type)throw new Error("Could not convert encrypted private key from PEM; PEM is encrypted.");return o.fromDer(t.body)},s.encryptRsaPrivateKey=function(e,t,n){if(n=n||{},!n.legacy){var i=s.wrapRsaPrivateKey(s.privateKeyToAsn1(e));return i=s.encryptPrivateKeyInfo(i,t,n),s.encryptedPrivateKeyToPem(i)}var a,l,u,c;switch(n.algorithm){case"aes128":a="AES-128-CBC",u=16,l=r.random.getBytesSync(16),c=r.aes.createEncryptionCipher;break;case"aes192":a="AES-192-CBC",u=24,l=r.random.getBytesSync(16),c=r.aes.createEncryptionCipher;break;case"aes256":a="AES-256-CBC",u=32,l=r.random.getBytesSync(16),c=r.aes.createEncryptionCipher;break;case"3des":a="DES-EDE3-CBC",u=24,l=r.random.getBytesSync(8),c=r.des.createEncryptionCipher;break;case"des":a="DES-CBC",u=8,l=r.random.getBytesSync(8),c=r.des.createEncryptionCipher;break;default:var h=new Error('Could not encrypt RSA private key; unsupported encryption algorithm "'+n.algorithm+'".');throw h.algorithm=n.algorithm,h}var f=r.pbe.opensslDeriveBytes(t,l.substr(0,8),u),p=c(f);p.start(l),p.update(o.toDer(s.privateKeyToAsn1(e))),p.finish();var d={type:"RSA PRIVATE KEY",procType:{version:"4",type:"ENCRYPTED"},dekInfo:{algorithm:a,parameters:r.util.bytesToHex(l).toUpperCase()},body:p.output.getBytes()};return r.pem.encode(d)},s.decryptRsaPrivateKey=function(e,t){var n=null,i=r.pem.decode(e)[0];if("ENCRYPTED PRIVATE KEY"!==i.type&&"PRIVATE KEY"!==i.type&&"RSA PRIVATE KEY"!==i.type){var a=new Error('Could not convert private key from PEM; PEM header type is not "ENCRYPTED PRIVATE KEY", "PRIVATE KEY", or "RSA PRIVATE KEY".');throw a.headerType=a,a}if(i.procType&&"ENCRYPTED"===i.procType.type){var l,u;switch(i.dekInfo.algorithm){case"DES-CBC":l=8,u=r.des.createDecryptionCipher;break;case"DES-EDE3-CBC":l=24,u=r.des.createDecryptionCipher;break;case"AES-128-CBC":l=16,u=r.aes.createDecryptionCipher;break;case"AES-192-CBC":l=24,u=r.aes.createDecryptionCipher;break;case"AES-256-CBC":l=32,u=r.aes.createDecryptionCipher;break;case"RC2-40-CBC":l=5,u=function(e){return r.rc2.createDecryptionCipher(e,40)};break;case"RC2-64-CBC":l=8,u=function(e){return r.rc2.createDecryptionCipher(e,64)};break;case"RC2-128-CBC":l=16,u=function(e){return r.rc2.createDecryptionCipher(e,128)};break;default:var a=new Error('Could not decrypt private key; unsupported encryption algorithm "'+i.dekInfo.algorithm+'".');throw a.algorithm=i.dekInfo.algorithm,a}var c=r.util.hexToBytes(i.dekInfo.parameters),h=r.pbe.opensslDeriveBytes(t,c.substr(0,8),l),f=u(h);if(f.start(c),f.update(r.util.createBuffer(i.body)),!f.finish())return n;n=f.output.getBytes()}else n=i.body;return n="ENCRYPTED PRIVATE KEY"===i.type?s.decryptPrivateKeyInfo(o.fromDer(n),t):o.fromDer(n),null!==n&&(n=s.privateKeyFromAsn1(n)),n},s.pbe.generatePkcs12Key=function(e,t,n,i,o,s){var a,l;if(void 0===s||null===s){if(!("sha1"in r.md))throw new Error('"sha1" hash algorithm unavailable.');s=r.md.sha1.create()}var u=s.digestLength,c=s.blockLength,h=new r.util.ByteBuffer,f=new r.util.ByteBuffer;if(null!==e&&void 0!==e){for(l=0;l<e.length;l++)f.putInt16(e.charCodeAt(l));f.putInt16(0)}var p=f.length(),d=t.length(),m=new r.util.ByteBuffer;m.fillWithByte(n,c);var g=c*Math.ceil(d/c),y=new r.util.ByteBuffer;for(l=0;l<g;l++)y.putByte(t.at(l%d));var v=c*Math.ceil(p/c),b=new r.util.ByteBuffer;for(l=0;l<v;l++)b.putByte(f.at(l%p));var _=y;_.putBuffer(b);for(var w=Math.ceil(o/u),k=1;k<=w;k++){var E=new r.util.ByteBuffer;E.putBytes(m.bytes()),E.putBytes(_.bytes());for(var S=0;S<i;S++)s.start(),s.update(E.getBytes()),E=s.digest();var x=new r.util.ByteBuffer;for(l=0;l<c;l++)x.putByte(E.at(l%u));var C=Math.ceil(d/c)+Math.ceil(p/c),A=new r.util.ByteBuffer;for(a=0;a<C;a++){var T=new r.util.ByteBuffer(_.getBytes(c)),I=511;for(l=x.length()-1;l>=0;l--)I>>=8,I+=x.at(l)+T.at(l),T.setAt(l,255&I);A.putBuffer(T)}_=A,h.putBuffer(E)}return h.truncate(h.length()-o),h},s.pbe.getCipher=function(e,t,n){switch(e){case s.oids.pkcs5PBES2:return s.pbe.getCipherForPBES2(e,t,n);case s.oids["pbeWithSHAAnd3-KeyTripleDES-CBC"]:case s.oids["pbewithSHAAnd40BitRC2-CBC"]:return s.pbe.getCipherForPKCS12PBE(e,t,n);default:var r=new Error("Cannot read encrypted PBE data block. Unsupported OID.");throw r.oid=e,r.supportedOids=["pkcs5PBES2","pbeWithSHAAnd3-KeyTripleDES-CBC","pbewithSHAAnd40BitRC2-CBC"],r}},s.pbe.getCipherForPBES2=function(e,t,n){var i={},a=[];if(!o.validate(t,u,i,a)){var l=new Error("Cannot read password-based-encryption algorithm parameters. ASN.1 object is not a supported EncryptedPrivateKeyInfo.");throw l.errors=a,l}if(e=o.derToOid(i.kdfOid),e!==s.oids.pkcs5PBKDF2){var l=new Error("Cannot read encrypted private key. Unsupported key derivation function OID.");throw l.oid=e,l.supportedOids=["pkcs5PBKDF2"],l}if(e=o.derToOid(i.encOid),e!==s.oids["aes128-CBC"]&&e!==s.oids["aes192-CBC"]&&e!==s.oids["aes256-CBC"]&&e!==s.oids["des-EDE3-CBC"]&&e!==s.oids.desCBC){var l=new Error("Cannot read encrypted private key. Unsupported encryption scheme OID.");throw l.oid=e,l.supportedOids=["aes128-CBC","aes192-CBC","aes256-CBC","des-EDE3-CBC","desCBC"],l}var c=i.kdfSalt,h=r.util.createBuffer(i.kdfIterationCount),p,d;switch(h=h.getInt(h.length()<<3),s.oids[e]){case"aes128-CBC":p=16,d=r.aes.createDecryptionCipher;break;case"aes192-CBC":p=24,d=r.aes.createDecryptionCipher;break;case"aes256-CBC":p=32,d=r.aes.createDecryptionCipher;break;case"des-EDE3-CBC":p=24,d=r.des.createDecryptionCipher;break;case"desCBC":p=8,d=r.des.createDecryptionCipher}var m=f(i.prfOid),g=r.pkcs5.pbkdf2(n,c,h,p,m),y=i.encIv,v=d(g);return v.start(y),v},s.pbe.getCipherForPKCS12PBE=function(e,t,n){var i={},a=[];if(!o.validate(t,c,i,a)){var l=new Error("Cannot read password-based-encryption algorithm parameters. ASN.1 object is not a supported EncryptedPrivateKeyInfo.");throw l.errors=a,l}var u=r.util.createBuffer(i.salt),h=r.util.createBuffer(i.iterations),p,d,m;switch(h=h.getInt(h.length()<<3),e){case s.oids["pbeWithSHAAnd3-KeyTripleDES-CBC"]:p=24,d=8,m=r.des.startDecrypting;break;case s.oids["pbewithSHAAnd40BitRC2-CBC"]:p=5,d=8,m=function(e,t){var n=r.rc2.createDecryptionCipher(e,40);return n.start(t,null),n};break;default:var l=new Error("Cannot read PKCS #12 PBE data block. Unsupported OID.");throw l.oid=e,l}var g=f(i.prfOid),y=s.pbe.generatePkcs12Key(n,u,1,h,p,g);g.start();var v=s.pbe.generatePkcs12Key(n,u,2,h,d,g);return m(y,v)},s.pbe.opensslDeriveBytes=function(e,t,n,i){if(void 0===i||null===i){if(!("md5"in r.md))throw new Error('"md5" hash algorithm unavailable.');i=r.md.md5.create()}null===t&&(t="");for(var o=[h(i,e+t)],s=16,a=1;s<n;++a,s+=16)o.push(h(i,o[a-1]+e+t));return o.join("").substr(0,n)}},function(e,t,n){var r=n(21);function i(e,t){var n=function(){return new r.des.Algorithm(e,t)};r.cipher.registerAlgorithm(e,n)}n(370),n(371),n(30),e.exports=r.des=r.des||{},r.des.startEncrypting=function(e,t,n,r){var i=m({key:e,output:n,decrypt:!1,mode:r||(null===t?"ECB":"CBC")});return i.start(t),i},r.des.createEncryptionCipher=function(e,t){return m({key:e,output:null,decrypt:!1,mode:t})},r.des.startDecrypting=function(e,t,n,r){var i=m({key:e,output:n,decrypt:!0,mode:r||(null===t?"ECB":"CBC")});return i.start(t),i},r.des.createDecryptionCipher=function(e,t){return m({key:e,output:null,decrypt:!0,mode:t})},r.des.Algorithm=function(e,t){var n=this;n.name=e,n.mode=new t({blockSize:8,cipher:{encrypt:function(e,t){return d(n._keys,e,t,!1)},decrypt:function(e,t){return d(n._keys,e,t,!0)}}}),n._init=!1},r.des.Algorithm.prototype.initialize=function(e){if(!this._init){var t=r.util.createBuffer(e.key);if(0===this.name.indexOf("3DES")&&24!==t.length())throw new Error("Invalid Triple-DES key size: "+8*t.length());this._keys=p(t),this._init=!0}},i("DES-ECB",r.cipher.modes.ecb),i("DES-CBC",r.cipher.modes.cbc),i("DES-CFB",r.cipher.modes.cfb),i("DES-OFB",r.cipher.modes.ofb),i("DES-CTR",r.cipher.modes.ctr),i("3DES-ECB",r.cipher.modes.ecb),i("3DES-CBC",r.cipher.modes.cbc),i("3DES-CFB",r.cipher.modes.cfb),i("3DES-OFB",r.cipher.modes.ofb),i("3DES-CTR",r.cipher.modes.ctr);var o=[16843776,0,65536,16843780,16842756,66564,4,65536,1024,16843776,16843780,1024,16778244,16842756,16777216,4,1028,16778240,16778240,66560,66560,16842752,16842752,16778244,65540,16777220,16777220,65540,0,1028,66564,16777216,65536,16843780,4,16842752,16843776,16777216,16777216,1024,16842756,65536,66560,16777220,1024,4,16778244,66564,16843780,65540,16842752,16778244,16777220,1028,66564,16843776,1028,16778240,16778240,0,65540,66560,0,16842756],s=[-2146402272,-2147450880,32768,1081376,1048576,32,-2146435040,-2147450848,-2147483616,-2146402272,-2146402304,-2147483648,-2147450880,1048576,32,-2146435040,1081344,1048608,-2147450848,0,-2147483648,32768,1081376,-2146435072,1048608,-2147483616,0,1081344,32800,-2146402304,-2146435072,32800,0,1081376,-2146435040,1048576,-2147450848,-2146435072,-2146402304,32768,-2146435072,-2147450880,32,-2146402272,1081376,32,32768,-2147483648,32800,-2146402304,1048576,-2147483616,1048608,-2147450848,-2147483616,1048608,1081344,0,-2147450880,32800,-2147483648,-2146435040,-2146402272,1081344],a=[520,134349312,0,134348808,134218240,0,131592,134218240,131080,134217736,134217736,131072,134349320,131080,134348800,520,134217728,8,134349312,512,131584,134348800,134348808,131592,134218248,131584,131072,134218248,8,134349320,512,134217728,134349312,134217728,131080,520,131072,134349312,134218240,0,512,131080,134349320,134218240,134217736,512,0,134348808,134218248,131072,134217728,134349320,8,131592,131584,134217736,134348800,134218248,520,134348800,131592,8,134348808,131584],l=[8396801,8321,8321,128,8396928,8388737,8388609,8193,0,8396800,8396800,8396929,129,0,8388736,8388609,1,8192,8388608,8396801,128,8388608,8193,8320,8388737,1,8320,8388736,8192,8396928,8396929,129,8388736,8388609,8396800,8396929,129,0,0,8396800,8320,8388736,8388737,1,8396801,8321,8321,128,8396929,129,1,8192,8388609,8193,8396928,8388737,8193,8320,8388608,8396801,128,8388608,8192,8396928],u=[256,34078976,34078720,1107296512,524288,256,1073741824,34078720,1074266368,524288,33554688,1074266368,1107296512,1107820544,524544,1073741824,33554432,1074266112,1074266112,0,1073742080,1107820800,1107820800,33554688,1107820544,1073742080,0,1107296256,34078976,33554432,1107296256,524544,524288,1107296512,256,33554432,1073741824,34078720,1107296512,1074266368,33554688,1073741824,1107820544,34078976,1074266368,256,33554432,1107820544,1107820800,524544,1107296256,1107820800,34078720,0,1074266112,1107296256,524544,33554688,1073742080,524288,0,1074266112,34078976,1073742080],c=[536870928,541065216,16384,541081616,541065216,16,541081616,4194304,536887296,4210704,4194304,536870928,4194320,536887296,536870912,16400,0,4194320,536887312,16384,4210688,536887312,16,541065232,541065232,0,4210704,541081600,16400,4210688,541081600,536870912,536887296,16,541065232,4210688,541081616,4194304,16400,536870928,4194304,536887296,536870912,16400,536870928,541081616,4210688,541065216,4210704,541081600,0,541065232,16,16384,541065216,4210704,16384,4194320,536887312,0,541081600,536870912,4194320,536887312],h=[2097152,69206018,67110914,0,2048,67110914,2099202,69208064,69208066,2097152,0,67108866,2,67108864,69206018,2050,67110912,2099202,2097154,67110912,67108866,69206016,69208064,2097154,69206016,2048,2050,69208066,2099200,2,67108864,2099200,67108864,2099200,2097152,67110914,67110914,69206018,69206018,2,2097154,67108864,67110912,2097152,69208064,2050,2099202,69208064,2050,67108866,69208066,69206016,2099200,0,2,69208066,0,2099202,69206016,2048,67108866,67110912,2048,2097154],f=[268439616,4096,262144,268701760,268435456,268439616,64,268435456,262208,268697600,268701760,266240,268701696,266304,4096,64,268697600,268435520,268439552,4160,266240,262208,268697664,268701696,4160,0,0,268697664,268435520,268439552,266304,262144,266304,262144,268701696,4096,64,268697664,4096,266304,268439552,64,268435520,268697600,268697664,268435456,262144,268439616,0,268701760,262208,268435520,268697600,268439552,268439616,0,268701760,266240,266240,4160,4160,262208,268435456,268701696];function p(e){for(var t=[0,4,536870912,536870916,65536,65540,536936448,536936452,512,516,536871424,536871428,66048,66052,536936960,536936964],n=[0,1,1048576,1048577,67108864,67108865,68157440,68157441,256,257,1048832,1048833,67109120,67109121,68157696,68157697],r=[0,8,2048,2056,16777216,16777224,16779264,16779272,0,8,2048,2056,16777216,16777224,16779264,16779272],i=[0,2097152,134217728,136314880,8192,2105344,134225920,136323072,131072,2228224,134348800,136445952,139264,2236416,134356992,136454144],o=[0,262144,16,262160,0,262144,16,262160,4096,266240,4112,266256,4096,266240,4112,266256],s=[0,1024,32,1056,0,1024,32,1056,33554432,33555456,33554464,33555488,33554432,33555456,33554464,33555488],a=[0,268435456,524288,268959744,2,268435458,524290,268959746,0,268435456,524288,268959744,2,268435458,524290,268959746],l=[0,65536,2048,67584,536870912,536936448,536872960,536938496,131072,196608,133120,198656,537001984,537067520,537004032,537069568],u=[0,262144,0,262144,2,262146,2,262146,33554432,33816576,33554432,33816576,33554434,33816578,33554434,33816578],c=[0,268435456,8,268435464,0,268435456,8,268435464,1024,268436480,1032,268436488,1024,268436480,1032,268436488],h=[0,32,0,32,1048576,1048608,1048576,1048608,8192,8224,8192,8224,1056768,1056800,1056768,1056800],f=[0,16777216,512,16777728,2097152,18874368,2097664,18874880,67108864,83886080,67109376,83886592,69206016,85983232,69206528,85983744],p=[0,4096,134217728,134221824,524288,528384,134742016,134746112,16,4112,134217744,134221840,524304,528400,134742032,134746128],d=[0,4,256,260,0,4,256,260,1,5,257,261,1,5,257,261],m=e.length()>8?3:1,g=[],y=[0,0,1,1,1,1,1,1,0,1,1,1,1,1,1,0],v=0,b,_=0;_<m;_++){var w=e.getInt32(),k=e.getInt32();b=252645135&(w>>>4^k),k^=b,w^=b<<4,b=65535&(k>>>-16^w),w^=b,k^=b<<-16,b=858993459&(w>>>2^k),k^=b,w^=b<<2,b=65535&(k>>>-16^w),w^=b,k^=b<<-16,b=1431655765&(w>>>1^k),k^=b,w^=b<<1,b=16711935&(k>>>8^w),w^=b,k^=b<<8,b=1431655765&(w>>>1^k),k^=b,w^=b<<1,b=w<<8|k>>>20&240,w=k<<24|k<<8&16711680|k>>>8&65280|k>>>24&240,k=b;for(var E=0;E<y.length;++E){y[E]?(w=w<<2|w>>>26,k=k<<2|k>>>26):(w=w<<1|w>>>27,k=k<<1|k>>>27),w&=-15,k&=-15;var S=t[w>>>28]|n[w>>>24&15]|r[w>>>20&15]|i[w>>>16&15]|o[w>>>12&15]|s[w>>>8&15]|a[w>>>4&15],x=l[k>>>28]|u[k>>>24&15]|c[k>>>20&15]|h[k>>>16&15]|f[k>>>12&15]|p[k>>>8&15]|d[k>>>4&15];b=65535&(x>>>16^S),g[v++]=S^b,g[v++]=x^b<<16}}return g}function d(e,t,n,r){var i=32===e.length?3:9,p,d;p=3===i?r?[30,-2,-2]:[0,32,2]:r?[94,62,-2,32,64,2,30,-2,-2]:[0,32,2,62,30,-2,64,96,2];var m=t[0],g=t[1];d=252645135&(m>>>4^g),g^=d,m^=d<<4,d=65535&(m>>>16^g),g^=d,m^=d<<16,d=858993459&(g>>>2^m),m^=d,g^=d<<2,d=16711935&(g>>>8^m),m^=d,g^=d<<8,d=1431655765&(m>>>1^g),g^=d,m^=d<<1,m=m<<1|m>>>31,g=g<<1|g>>>31;for(var y=0;y<i;y+=3){for(var v=p[y+1],b=p[y+2],_=p[y];_!=v;_+=b){var w=g^e[_],k=(g>>>4|g<<28)^e[_+1];d=m,m=g,g=d^(s[w>>>24&63]|l[w>>>16&63]|c[w>>>8&63]|f[63&w]|o[k>>>24&63]|a[k>>>16&63]|u[k>>>8&63]|h[63&k])}d=m,m=g,g=d}m=m>>>1|m<<31,g=g>>>1|g<<31,d=1431655765&(m>>>1^g),g^=d,m^=d<<1,d=16711935&(g>>>8^m),m^=d,g^=d<<8,d=858993459&(g>>>2^m),m^=d,g^=d<<2,d=65535&(m>>>16^g),g^=d,m^=d<<16,d=252645135&(m>>>4^g),g^=d,m^=d<<4,n[0]=m,n[1]=g}function m(e){e=e||{};var t=(e.mode||"CBC").toUpperCase(),n="DES-"+t,i;i=e.decrypt?r.cipher.createDecipher(n,e.key):r.cipher.createCipher(n,e.key);var o=i.start;return i.start=function(e,t){var n=null;t instanceof r.util.ByteBuffer&&(n=t,t={}),t=t||{},t.output=n,t.iv=e,o.call(i,t)},i}},function(e,t,n){var r=n(21);n(30);var i=e.exports=r.pem=r.pem||{};function o(e){for(var t=e.name+": ",n=[],r=function(e,t){return" "+t},i=0;i<e.values.length;++i)n.push(e.values[i].replace(/^(\S+\r\n)/,r));t+=n.join(",")+"\r\n";for(var o=0,s=-1,i=0;i<t.length;++i,++o)if(o>65&&-1!==s){var a=t[s];","===a?(++s,t=t.substr(0,s)+"\r\n "+t.substr(s)):t=t.substr(0,s)+"\r\n"+a+t.substr(s+1),o=i-s-1,s=-1,++i}else" "!==t[i]&&"\t"!==t[i]&&","!==t[i]||(s=i);return t}function s(e){return e.replace(/^\s+/,"")}i.encode=function(e,t){t=t||{};var n="-----BEGIN "+e.type+"-----\r\n",i;if(e.procType&&(i={name:"Proc-Type",values:[String(e.procType.version),e.procType.type]},n+=o(i)),e.contentDomain&&(i={name:"Content-Domain",values:[e.contentDomain]},n+=o(i)),e.dekInfo&&(i={name:"DEK-Info",values:[e.dekInfo.algorithm]},e.dekInfo.parameters&&i.values.push(e.dekInfo.parameters),n+=o(i)),e.headers)for(var s=0;s<e.headers.length;++s)n+=o(e.headers[s]);return e.procType&&(n+="\r\n"),n+=r.util.encode64(e.body,t.maxline||64)+"\r\n",n+="-----END "+e.type+"-----\r\n",n},i.decode=function(e){for(var t=[],n=/\s*-----BEGIN ([A-Z0-9- ]+)-----\r?\n?([\x21-\x7e\s]+?(?:\r?\n\r?\n))?([:A-Za-z0-9+\/=\s]+?)-----END \1-----/g,i=/([\x21-\x7e]+):\s*([\x21-\x7e\s^:]+)/,o=/\r?\n/,a;a=n.exec(e),a;){var l={type:a[1],procType:null,contentDomain:null,dekInfo:null,headers:[],body:r.util.decode64(a[3])};if(t.push(l),a[2]){for(var u=a[2].split(o),c=0;a&&c<u.length;){for(var h=u[c].replace(/\s+$/,""),f=c+1;f<u.length;++f){var p=u[f];if(!/\s/.test(p[0]))break;h+=p,c=f}if(a=h.match(i),a){for(var d={name:a[1],values:[]},m=a[2].split(","),g=0;g<m.length;++g)d.values.push(s(m[g]));if(l.procType)if(l.contentDomain||"Content-Domain"!==d.name)if(l.dekInfo||"DEK-Info"!==d.name)l.headers.push(d);else{if(0===d.values.length)throw new Error('Invalid PEM formatted message. The "DEK-Info" header must have at least one subfield.');l.dekInfo={algorithm:m[0],parameters:m[1]||null}}else l.contentDomain=m[0]||"";else{if("Proc-Type"!==d.name)throw new Error('Invalid PEM formatted message. The first encapsulated header must be "Proc-Type".');if(2!==d.values.length)throw new Error('Invalid PEM formatted message. The "Proc-Type" header must have two subfields.');l.procType={version:m[0],type:m[1]}}}++c}if("ENCRYPTED"===l.procType&&!l.dekInfo)throw new Error('Invalid PEM formatted message. The "DEK-Info" header must be present if "Proc-Type" is "ENCRYPTED".')}}if(0===t.length)throw new Error("Invalid PEM formatted message.");return t}},function(e,t,n){"use strict";e.exports=function e(t,n){return t.then(e=>{n(null,e)},e=>{n(e)})}},function(e,t,n){"use strict";e.exports=self.crypto||self.msCrypto},function(e,t,n){"use strict";const r=n(755);e.exports=function(e){if(!e||"number"!=typeof e)throw new Error("first argument must be a Number bigger than 0");return r(e)}},function(e,t,n){"use strict";var r=n(1),i=n(380),o=n(5).Buffer,s=new Array(16);function a(){i.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function l(e,t){return e<<t|e>>>32-t}function u(e,t,n,r,i,o,s){return l(e+(t&n|~t&r)+i+o|0,s)+t|0}function c(e,t,n,r,i,o,s){return l(e+(t&r|n&~r)+i+o|0,s)+t|0}function h(e,t,n,r,i,o,s){return l(e+(t^n^r)+i+o|0,s)+t|0}function f(e,t,n,r,i,o,s){return l(e+(n^(t|~r))+i+o|0,s)+t|0}r(a,i),a.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var n=this._a,r=this._b,i=this._c,o=this._d;n=u(n,r,i,o,e[0],3614090360,7),o=u(o,n,r,i,e[1],3905402710,12),i=u(i,o,n,r,e[2],606105819,17),r=u(r,i,o,n,e[3],3250441966,22),n=u(n,r,i,o,e[4],4118548399,7),o=u(o,n,r,i,e[5],1200080426,12),i=u(i,o,n,r,e[6],2821735955,17),r=u(r,i,o,n,e[7],4249261313,22),n=u(n,r,i,o,e[8],1770035416,7),o=u(o,n,r,i,e[9],2336552879,12),i=u(i,o,n,r,e[10],4294925233,17),r=u(r,i,o,n,e[11],2304563134,22),n=u(n,r,i,o,e[12],1804603682,7),o=u(o,n,r,i,e[13],4254626195,12),i=u(i,o,n,r,e[14],2792965006,17),r=u(r,i,o,n,e[15],1236535329,22),n=c(n,r,i,o,e[1],4129170786,5),o=c(o,n,r,i,e[6],3225465664,9),i=c(i,o,n,r,e[11],643717713,14),r=c(r,i,o,n,e[0],3921069994,20),n=c(n,r,i,o,e[5],3593408605,5),o=c(o,n,r,i,e[10],38016083,9),i=c(i,o,n,r,e[15],3634488961,14),r=c(r,i,o,n,e[4],3889429448,20),n=c(n,r,i,o,e[9],568446438,5),o=c(o,n,r,i,e[14],3275163606,9),i=c(i,o,n,r,e[3],4107603335,14),r=c(r,i,o,n,e[8],1163531501,20),n=c(n,r,i,o,e[13],2850285829,5),o=c(o,n,r,i,e[2],4243563512,9),i=c(i,o,n,r,e[7],1735328473,14),r=c(r,i,o,n,e[12],2368359562,20),n=h(n,r,i,o,e[5],4294588738,4),o=h(o,n,r,i,e[8],2272392833,11),i=h(i,o,n,r,e[11],1839030562,16),r=h(r,i,o,n,e[14],4259657740,23),n=h(n,r,i,o,e[1],2763975236,4),o=h(o,n,r,i,e[4],1272893353,11),i=h(i,o,n,r,e[7],4139469664,16),r=h(r,i,o,n,e[10],3200236656,23),n=h(n,r,i,o,e[13],681279174,4),o=h(o,n,r,i,e[0],3936430074,11),i=h(i,o,n,r,e[3],3572445317,16),r=h(r,i,o,n,e[6],76029189,23),n=h(n,r,i,o,e[9],3654602809,4),o=h(o,n,r,i,e[12],3873151461,11),i=h(i,o,n,r,e[15],530742520,16),r=h(r,i,o,n,e[2],3299628645,23),n=f(n,r,i,o,e[0],4096336452,6),o=f(o,n,r,i,e[7],1126891415,10),i=f(i,o,n,r,e[14],2878612391,15),r=f(r,i,o,n,e[5],4237533241,21),n=f(n,r,i,o,e[12],1700485571,6),o=f(o,n,r,i,e[3],2399980690,10),i=f(i,o,n,r,e[10],4293915773,15),r=f(r,i,o,n,e[1],2240044497,21),n=f(n,r,i,o,e[8],1873313359,6),o=f(o,n,r,i,e[15],4264355552,10),i=f(i,o,n,r,e[6],2734768916,15),r=f(r,i,o,n,e[13],1309151649,21),n=f(n,r,i,o,e[4],4149444226,6),o=f(o,n,r,i,e[11],3174756917,10),i=f(i,o,n,r,e[2],718787259,15),r=f(r,i,o,n,e[9],3951481745,21),this._a=this._a+n|0,this._b=this._b+r|0,this._c=this._c+i|0,this._d=this._d+o|0},a.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=o.allocUnsafe(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},e.exports=a},function(e,t,n){t=e.exports=n(381),t.Stream=t,t.Readable=t,t.Writable=n(259),t.Duplex=n(98),t.Transform=n(384),t.PassThrough=n(785)},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(382),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(383),y;function v(){}function b(e,t){l=l||n(98),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(98),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";function r(e){if("number"==typeof e){if(r.codes[e])return r.codes[e];throw new Error("no protocol with code: "+e)}if("string"==typeof e||e instanceof String){if(r.names[e])return r.names[e];throw new Error("no protocol with name: "+e)}throw new Error("invalid protocol id type: "+e)}const i=-1;function o(e,t,n,r,i){return{code:e,size:t,name:n,resolvable:Boolean(r),path:Boolean(i)}}r.lengthPrefixedVarSize=i,r.V=i,r.table=[[4,32,"ip4"],[6,16,"tcp"],[33,16,"dccp"],[41,128,"ip6"],[42,i,"ip6zone"],[53,i,"dns","resolvable"],[54,i,"dns4","resolvable"],[55,i,"dns6","resolvable"],[56,i,"dnsaddr","resolvable"],[132,16,"sctp"],[273,16,"udp"],[275,0,"p2p-webrtc-star"],[276,0,"p2p-webrtc-direct"],[277,0,"p2p-stardust"],[290,0,"p2p-circuit"],[301,0,"udt"],[302,0,"utp"],[400,i,"unix",!1,"path"],[421,i,"p2p"],[421,i,"ipfs"],[443,0,"https"],[444,96,"onion"],[445,296,"onion3"],[446,i,"garlic64"],[460,0,"quic"],[477,0,"ws"],[478,0,"wss"],[479,0,"p2p-websocket-star"],[480,0,"http"]],r.names={},r.codes={},r.table.map(e=>{const t=o.apply(null,e);r.codes[t.code]=t,r.names[t.name]=t}),r.object=o,e.exports=r},function(e,t,n){"use strict";const r=n(10),i=n(43),o=n(36),s=n(38),a=n(202),l=n(24),u=n(54),c=n(4),h=n(55),f=n(12),p=n(185),d=n(830),m=n(831),g=n(833),y=n(835),v=n(837),b=n(838),_=n(848),w=n(867),k=n(868),E=c("repo"),S=Number.MAX_SAFE_INTEGER,x={memory:n(424),fs:n(424)},C=n(869).repoVersion;class A{constructor(e,t){l.strictEqual(typeof e,"string","missing repoPath"),this.options=B(t),this.closed=!0,this.path=e,this._locker=this._getLocker(),this.root=d.create("root",this.path,this.options),this.version=m(this.root),this.config=g(this.root),this.spec=y(this.root),this.apiAddr=v(this.root)}init(e,t){E("initializing at: %s",this.path),i([e=>this.root.open(j(e)),t=>this.config.set(O(e),t),t=>this.spec.set(P(e),t),e=>this.version.set(C,e)],t)}open(e){this.closed?(E("opening at: %s",this.path),r([e=>this.root.open(j(e)),e=>this._isInitialized(e),e=>this._openLock(this.path,e),(e,t)=>{E("aquired repo.lock"),this.lockfile=e,t()},e=>{E("creating datastore"),this.datastore=d.create("datastore",u.join(this.path,"datastore"),this.options),E("creating blocks");const t=d.create("blocks",u.join(this.path,"blocks"),this.options);b(t,this.options.storageBackendOptions.blocks,e)},(e,t)=>{this.blocks=e,t()},e=>{E("creating keystore"),this.keys=d.create("keys",u.join(this.path,"keys"),this.options),e()},e=>{this.closed=!1,E("all opened"),e()}],t=>{t&&this.lockfile?this._closeLock(n=>{n?E("error removing lock",n):this.lockfile=null,e(t)}):e(t)})):setImmediate(()=>e(new Error("repo is already open")))}_getLocker(){return"string"==typeof this.options.lock?(l(x[this.options.lock],"Unknown lock type: "+this.options.lock),x[this.options.lock]):(l(this.options.lock,"No lock provided"),this.options.lock)}_openLock(e,t){this._locker.lock(e,(e,n)=>{if(e)return t(e,null);l.strictEqual(typeof n.close,"function","Locks must have a close method"),t(null,n)})}_closeLock(e){if(this.lockfile)return this.lockfile.close(e);e()}_isInitialized(e){E("init check"),o({config:e=>this.config.exists(e),spec:e=>this.spec.exists(e),version:e=>this.version.check(C,e)},(t,n)=>{if(E("init",t,n),t&&!n.config)return e(Object.assign(new Error("repo is not initialized yet"),{code:k.ERR_REPO_NOT_INITIALIZED,path:this.path}));e(t)})}close(e){if(this.closed)return e(new Error("repo is already closed"));E("closing at: %s",this.path),i([e=>this.apiAddr.delete(R(e)),e=>{s([this.blocks,this.keys,this.datastore],(e,t)=>e.close(t),e)},e=>{E("unlocking"),this.closed=!0,this._closeLock(e)},e=>{this.lockfile=null,e()}],t=>e(t))}exists(e){this.version.exists(e)}stat(e,t){"function"==typeof e&&(t=e,e={}),e=Object.assign({},{human:!1},e),o({storageMax:e=>this.config.get("Datastore.StorageMax",(t,n)=>{e(null,new h(t?S:n))}),version:e=>this.version.get(e),blocks:e=>this.blocks.query({},(t,n)=>{n=n||[];const r=new h(n.length);let i=new h(0);n.forEach(e=>{i=i.plus(e.value.byteLength).plus(e.key._buf.byteLength)}),e(t,{count:r,size:i})}),datastore:e=>T(this.datastore,e),keys:e=>T(this.keys,e)},(n,r)=>{if(n)return t(n);let i=r.blocks.size.plus(r.datastore).plus(r.keys);e.human&&(i=i.div(1048576)),t(null,{repoPath:this.path,storageMax:r.storageMax,version:r.version,numObjects:r.blocks.count,repoSize:i})})}}function T(e,t){f(e.query({}),p((e,t)=>e.plus(t.value.byteLength).plus(t.key._buf.byteLength),new h(0),t))}function I(e,t){return n=>{t(n&&!e(n)?n:null)}}function j(e){return I(e=>"Already open"===e.message,e)}function R(e){return I(e=>e&&(e.code===k.ERR_REPO_NOT_INITIALIZED||e.message.startsWith("ENOENT")),e)}function B(e){const t=Object.assign({},_,e);return t.storageBackends=Object.assign({},_.storageBackends,t.storageBackends),t.storageBackendOptions=Object.assign({},_.storageBackendOptions,t.storageBackendOptions),t}function O(e){return e.datastore=Object.assign({},w,a(e,"datastore",{})),e}function P(e){const t=Object.assign({},w.Spec,a(e,"datastore.Spec",{}));return{type:t.type,mounts:t.mounts.map(e=>({mountpoint:e.mountpoint,type:e.child.type,path:e.child.path,shardFunc:e.child.shardFunc}))}}e.exports=A,e.exports.repoVersion=C,e.exports.errors=k},function(e,t,n){"use strict";const r=n(19),i=n(188),o=n(54),s=n(198),a=n(121);t.asyncFilter=function(e){let t=!1,n,r;return function(i){return function o(s,a){if(r)return a(r);s?(r=s,i(s,t?()=>{t?n=a:a(s)}:a)):i(null,(i,s)=>{i?a(i):r?a(r):(t=!0,e(s,(e,i)=>{t=!1,r?(a(r),n(r)):e?o(e,a):i?a(null,s):o(null,a)}))})}}},t.asyncSort=function(e){const t=i(),n=r.collect((n,i)=>{if(n)return t.abort(n);e(i,(e,n)=>{if(e)return t.abort(e);t.resolve(r.values(i))})});return function(e){return n(e),t}},t.replaceStartWith=function(e,t){const n=new RegExp("^"+t);return e.replace(n,"")},t.tmpdir=(()=>o.join(s.tmpdir(),a()))},function(e,t,n){var r=n(855).create,i=r("LevelUPError"),o=r("NotFoundError",i);o.prototype.notFound=!0,o.prototype.status=404,e.exports={LevelUPError:i,InitializationError:r("InitializationError",i),OpenError:r("OpenError",i),ReadError:r("ReadError",i),WriteError:r("WriteError",i),NotFoundError:o,EncodingError:r("EncodingError",i)}},function(e,t,n){t.AbstractLevelDOWN=n(859),t.AbstractIterator=n(418),t.AbstractChainedBatch=n(419)},function(e,t,n){"use strict";const r=1e3;e.exports={maxProvidersPerRequest:3,providerRequestTimeout:1e4,hasBlockTimeout:15e3,provideTimeout:15e3,kMaxPriority:Math.pow(2,31)-1,rebroadcastDelay:1e4,maxListeners:1e3}},function(e,t,n){var r=n(945)("socket.io-parser"),i=n(124),o=n(948),s=n(444),a=n(445);function l(){}t.protocol=4,t.types=["CONNECT","DISCONNECT","EVENT","ACK","ERROR","BINARY_EVENT","BINARY_ACK"],t.CONNECT=0,t.DISCONNECT=1,t.EVENT=2,t.ACK=3,t.ERROR=4,t.BINARY_EVENT=5,t.BINARY_ACK=6,t.Encoder=l,t.Decoder=p;var u=t.ERROR+'"encode error"';function c(e){var n=""+e.type;if(t.BINARY_EVENT!==e.type&&t.BINARY_ACK!==e.type||(n+=e.attachments+"-"),e.nsp&&"/"!==e.nsp&&(n+=e.nsp+","),null!=e.id&&(n+=e.id),null!=e.data){var i=h(e.data);if(!1===i)return u;n+=i}return r("encoded %j as %s",e,n),n}function h(e){try{return JSON.stringify(e)}catch(e){return!1}}function f(e,t){function n(e){var n=o.deconstructPacket(e),r=c(n.packet),i=n.buffers;i.unshift(r),t(i)}o.removeBlobs(e,n)}function p(){this.reconstructor=null}function d(e){var n=0,i={type:Number(e.charAt(0))};if(null==t.types[i.type])return y("unknown packet type "+i.type);if(t.BINARY_EVENT===i.type||t.BINARY_ACK===i.type){for(var o="";"-"!==e.charAt(++n)&&(o+=e.charAt(n),n!=e.length););if(o!=Number(o)||"-"!==e.charAt(n))throw new Error("Illegal attachments");i.attachments=Number(o)}if("/"===e.charAt(n+1))for(i.nsp="";++n;){var a=e.charAt(n);if(","===a)break;if(i.nsp+=a,n===e.length)break}else i.nsp="/";var l=e.charAt(n+1);if(""!==l&&Number(l)==l){for(i.id="";++n;){var a=e.charAt(n);if(null==a||Number(a)!=a){--n;break}if(i.id+=e.charAt(n),n===e.length)break}i.id=Number(i.id)}if(e.charAt(++n)){var u=m(e.substr(n)),c=!1!==u&&(i.type===t.ERROR||s(u));if(!c)return y("invalid payload");i.data=u}return r("decoded %s as %j",e,i),i}function m(e){try{return JSON.parse(e)}catch(e){return!1}}function g(e){this.reconPack=e,this.buffers=[]}function y(e){return{type:t.ERROR,data:"parser error: "+e}}l.prototype.encode=function(e,n){if(r("encoding packet %j",e),t.BINARY_EVENT===e.type||t.BINARY_ACK===e.type)f(e,n);else{var i=c(e);n([i])}},i(p.prototype),p.prototype.add=function(e){var n;if("string"==typeof e)n=d(e),t.BINARY_EVENT===n.type||t.BINARY_ACK===n.type?(this.reconstructor=new g(n),0===this.reconstructor.reconPack.attachments&&this.emit("decoded",n)):this.emit("decoded",n);else{if(!a(e)&&!e.base64)throw new Error("Unknown type: "+e);if(!this.reconstructor)throw new Error("got binary data when not reconstructing a packet");n=this.reconstructor.takeBinaryData(e),n&&(this.reconstructor=null,this.emit("decoded",n))}},p.prototype.destroy=function(){this.reconstructor&&this.reconstructor.finishedReconstruction()},g.prototype.takeBinaryData=function(e){if(this.buffers.push(e),this.buffers.length===this.reconPack.attachments){var t=o.reconstructPacket(this.reconPack,this.buffers);return this.finishedReconstruction(),t}return null},g.prototype.finishedReconstruction=function(){this.reconPack=null,this.buffers=[]}},function(e,t,n){var r=n(951);e.exports=function(e){var t=e.xdomain,n=e.xscheme,i=e.enablesXDR;try{if("undefined"!=typeof XMLHttpRequest&&(!t||r))return new XMLHttpRequest}catch(e){}try{if("undefined"!=typeof XDomainRequest&&!n&&i)return new XDomainRequest}catch(e){}if(!t)try{return new(self[["Active"].concat("Object").join("X")])("Microsoft.XMLHTTP")}catch(e){}}},function(e,t,n){var r=n(125),i=n(124);function o(e){this.path=e.path,this.hostname=e.hostname,this.port=e.port,this.secure=e.secure,this.query=e.query,this.timestampParam=e.timestampParam,this.timestampRequests=e.timestampRequests,this.readyState="",this.agent=e.agent||!1,this.socket=e.socket,this.enablesXDR=e.enablesXDR,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.forceNode=e.forceNode,this.isReactNative=e.isReactNative,this.extraHeaders=e.extraHeaders,this.localAddress=e.localAddress}e.exports=o,i(o.prototype),o.prototype.onError=function(e,t){var n=new Error(e);return n.type="TransportError",n.description=t,this.emit("error",n),this},o.prototype.open=function(){return"closed"!==this.readyState&&""!==this.readyState||(this.readyState="opening",this.doOpen()),this},o.prototype.close=function(){return"opening"!==this.readyState&&"open"!==this.readyState||(this.doClose(),this.onClose()),this},o.prototype.send=function(e){if("open"!==this.readyState)throw new Error("Transport not open");this.write(e)},o.prototype.onOpen=function(){this.readyState="open",this.writable=!0,this.emit("open")},o.prototype.onData=function(e){var t=r.decodePacket(e,this.socket.binaryType);this.onPacket(t)},o.prototype.onPacket=function(e){this.emit("packet",e)},o.prototype.onClose=function(){this.readyState="closed",this.emit("close")}},function(e,t,n){"use strict";(function(e){const r=n(56),i=n(52),o=n(12),s=n(40),a=n(33),l=n(51),u=n(36);function c(e,t,n){l.hmac.create(e,t,n)}function h(e,t,n,r){if("AES-128"===e||"AES-256"===e)return l.aes.create(n,t,r);r(new Error(`unrecognized cipher type: ${e}`))}t.exchanges=["P-256","P-384","P-521"],t.ciphers=["AES-256","AES-128"],t.hashes=["SHA256","SHA512"],t.theBest=((e,t,n)=>{let r,i;if(e<0)r=n,i=t;else{if(!(e>0))return t[0];r=t,i=n}for(let e of r)for(let t of i)if(e===t)return e;throw new Error("No algorithms in common!")}),t.makeMacAndCipher=((e,t)=>{u([t=>c(e.hashT,e.keys.macKey,t),t=>h(e.cipherT,e.keys.iv,e.keys.cipherKey,t)],(n,r)=>{if(n)return t(n);e.mac=r[0],e.cipher=r[1],t()})}),t.selectBest=((n,r,i)=>{t.digest(e.concat([r.pubKeyBytes,n.nonce]),(o,s)=>{if(o)return i(o);t.digest(e.concat([n.pubKeyBytes,r.nonce]),(o,a)=>{if(o)return i(o);const l=e.compare(s,a);if(0===l)return i(new Error("you are trying to talk to yourself"));i(null,{curveT:t.theBest(l,n.exchanges,r.exchanges),cipherT:t.theBest(l,n.ciphers,r.ciphers),hashT:t.theBest(l,n.hashes,r.hashes),order:l})})})}),t.digest=((e,t)=>{r.digest(e,"sha2-256",e.length,t)}),t.write=function e(t,n,r){r=r||(()=>{}),o(s([n]),i.encode({fixed:!0,bytes:4}),a((e,n)=>{if(e)return r(e);t.shake.write(n[0]),r()}))},t.read=function e(t,n){i.decodeFromReader(t,{fixed:!0,bytes:4},n)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(e){const r=n(57),i=n(15),o=n(51),s=n(36),a=n(10),l=n(4),u=l("libp2p:secio");u.error=l("libp2p:secio:error");const c=r(n(994)),h=n(269),f=16;t.createProposal=(e=>(e.proposal.out={rand:o.randomBytes(16),pubkey:e.key.local.public.bytes,exchanges:h.exchanges.join(","),ciphers:h.ciphers.join(","),hashes:h.hashes.join(",")},e.proposalEncoded.out=c.Propose.encode(e.proposal.out),e.proposalEncoded.out)),t.createExchange=((t,n)=>{o.keys.generateEphemeralKeyPair(t.protocols.local.curveT,(r,i)=>{if(r)return n(r);t.ephemeralKey.local=i.key,t.shared.generate=i.genSharedKey;const o=e.concat([t.proposalEncoded.out,t.proposalEncoded.in,t.ephemeralKey.local]);t.key.local.sign(o,(e,r)=>{if(e)return n(e);t.exchange.out={epubkey:t.ephemeralKey.local,signature:r},n(null,c.Exchange.encode(t.exchange.out))})})}),t.identify=((e,t,n)=>{u("1.1 identify"),e.proposalEncoded.in=t,e.proposal.in=c.Propose.decode(t);const r=e.proposal.in.pubkey;e.key.remote=o.keys.unmarshalPublicKey(r),i.createFromPubKey(r.toString("base64"),(t,r)=>{if(t)return n(t);if(e.id.remote){if(e.id.remote.toB58String()!==r.toB58String())return n(new Error("dialed to the wrong peer, Ids do not match"))}else e.id.remote=r;u("1.1 identify - %s - identified remote peer as %s",e.id.local.toB58String(),e.id.remote.toB58String()),n()})}),t.selectProtocols=((e,t)=>{u("1.2 selection");const n={pubKeyBytes:e.key.local.public.bytes,exchanges:h.exchanges,hashes:h.hashes,ciphers:h.ciphers,nonce:e.proposal.out.rand},r={pubKeyBytes:e.proposal.in.pubkey,exchanges:e.proposal.in.exchanges.split(","),hashes:e.proposal.in.hashes.split(","),ciphers:e.proposal.in.ciphers.split(","),nonce:e.proposal.in.rand};h.selectBest(n,r,(n,r)=>{if(n)return t(n);e.protocols.remote={order:r.order,curveT:r.curveT,cipherT:r.cipherT,hashT:r.hashT},e.protocols.local={order:r.order,curveT:r.curveT,cipherT:r.cipherT,hashT:r.hashT},t()})}),t.verify=((t,n,r)=>{u("2.1. verify"),t.exchange.in=c.Exchange.decode(n),t.ephemeralKey.remote=t.exchange.in.epubkey;const i=e.concat([t.proposalEncoded.in,t.proposalEncoded.out,t.ephemeralKey.remote]);t.key.remote.verify(i,t.exchange.in.signature,(e,t)=>e?r(e):t?(u("2.1. verify - signature verified"),void r()):r(new Error("Bad signature")))}),t.generateKeys=((e,t)=>{u("2.2. keys"),a([t=>e.shared.generate(e.exchange.in.epubkey,t),(t,n)=>{e.shared.secret=t,o.keys.keyStretcher(e.protocols.local.cipherT,e.protocols.local.hashT,e.shared.secret,n)},(t,n)=>{if(e.protocols.local.order>0)e.protocols.local.keys=t.k1,e.protocols.remote.keys=t.k2;else{if(!(e.protocols.local.order<0))return n(new Error("you are trying to talk to yourself"));e.protocols.local.keys=t.k2,e.protocols.remote.keys=t.k1}u("2.3. mac + cipher"),s([t=>h.makeMacAndCipher(e.protocols.local,t),t=>h.makeMacAndCipher(e.protocols.remote,t)],n)}],t)}),t.verifyNonce=((e,t)=>{const n=e.proposal.out.rand;if(!n.equals(t))throw new Error(`Failed to read our encrypted nonce: ${n.toString("hex")} != ${t.toString("hex")}`)})}).call(this,n(0).Buffer)},function(e,t,n){(function(t){function n(e,n){if(e.length!==n.length)throw new Error("Inputs should have the same length");for(var r=t.allocUnsafe(e.length),i=0;i<e.length;i++)r[i]=e[i]^n[i];return r}e.exports=n,n.compare=function e(t,n){if(t.length!==n.length)throw new Error("Inputs should have the same length");for(var r=0;r<t.length;r++)if(t[r]!==n[r])return t[r]<n[r]?-1:1;return 0},n.gt=function e(t,r){return 1===n.compare(t,r)},n.lt=function e(t,r){return-1===n.compare(t,r)},n.eq=function e(t,r){return 0===n.compare(t,r)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(60),o=n(115),s=n(95),a=n(1019),l=n(39);class u{constructor(n,s,a,l="base58btc"){if(e.exports.isCID(n)){const e=n;return this.version=e.version,this.codec=e.codec,this.multihash=t.from(e.multihash),void(this.multibaseName=e.multibaseName)}if("string"==typeof n){const e=i.isEncoded(n);if(e){const t=i.decode(n);this.version=parseInt(t.slice(0,1).toString("hex"),16),this.codec=o.getCodec(t.slice(1)),this.multihash=o.rmPrefix(t.slice(1)),this.multibaseName=e}else this.version=0,this.codec="dag-pb",this.multihash=r.fromB58String(n),this.multibaseName="base58btc";return u.validateCID(this),void Object.defineProperty(this,"string",{value:n})}if(t.isBuffer(n)){const e=n.slice(0,1),t=parseInt(e.toString("hex"),16);if(0===t||1===t){const e=n;this.version=t,this.codec=o.getCodec(e.slice(1)),this.multihash=o.rmPrefix(e.slice(1)),this.multibaseName=0===t?"base58btc":l}else this.version=0,this.codec="dag-pb",this.multihash=n,this.multibaseName="base58btc";u.validateCID(this)}else this.version=n,this.codec=s,this.multihash=a,this.multibaseName=l,u.validateCID(this)}get buffer(){let e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=t.concat([t.from("01","hex"),o.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}get prefix(){return t.concat([t.from(`0${this.version}`,"hex"),o.getCodeVarint(this.codec),r.prefix(this.multihash)])}toV0(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");const{name:e,length:t}=r.decode(this.multihash);if("sha2-256"!==e)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==t)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new c(0,this.codec,this.multihash)}toV1(){return new c(1,this.codec,this.multihash)}toBaseEncodedString(e=this.multibaseName){if(this.string&&e===this.multibaseName)return this.string;let t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=r.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=i.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}toString(e){return this.toBaseEncodedString(e)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}static validateCID(e){let t=a.checkCIDComponents(e);if(t)throw new Error(t)}}const c=l(u,{className:"CID",symbolName:"@ipld/js-cid/CID"});c.codecs=s,e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(244),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e){return function(t,n,r,o){return e((0,i.default)(n),t,(0,s.default)(r),o)}}e.exports=t.default},function(e,t,n){"use strict";e.exports=n(1035)},function(e,t,n){"use strict";const r=n(40),i=n(33),o=n(88),s=n(12),a=n(52),l=n(102),u=n(4),c=u("libp2p:circuit:stream-handler");c.err=u("libp2p:circuit:error:stream-handler");class h{constructor(e,t,n,r){this.conn=e,this.stream=null,this.shake=null,this.timeout=t||6e4,this.maxLength=r||4096,"function"==typeof t&&(this.timeout=n||6e4),this.stream=l({timeout:this.timeout},t),this.shake=this.stream.handshake,s(this.stream,e,this.stream)}isValid(){return this.conn&&this.shake&&this.stream}read(e){if(!this.isValid())return e(new Error("handler is not in a valid state"));a.decodeFromReader(this.shake,{maxLength:this.maxLength},(t,n)=>t?(c.err(t),e(t)):e(null,n))}write(e,t){if(t=t||(()=>{}),!this.isValid())return t(new Error("handler is not in a valid state"));s(r([e]),a.encode(),i((e,n)=>{if(e)return c.err(e),this.shake.abort(e),t(e);n.forEach(e=>this.shake.write(e)),t()}))}getRawConn(){return this.conn}rest(){const e=this.shake.rest();return this.conn=null,this.stream=null,this.shake=null,e}close(){this.isValid()&&s(o(),this.rest())}}e.exports=h},function(e,t,n){"use strict";e.exports={relay:"/libp2p/circuit/relay/0.1.0"}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=f;var r=n(58),i=h(r),o=n(122),s=h(o),a=n(37),l=h(a),u=n(86),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t){var n=null,r;t=t||i.default,(0,s.default)(e,function(e,t){(0,l.default)(e)(function(e,i){r=arguments.length>2?(0,c.default)(arguments,1):i,n=e,t(!e)})},function(){t(n,r)})}e.exports=t.default},function(e,t,n){"use strict";e.exports={BLACK_LIST_TTL:3e5,BLACK_LIST_ATTEMPTS:5,DIAL_TIMEOUT:3e4,MAX_COLD_CALLS:50,MAX_PARALLEL_DIALS:100,QUARTER_HOUR:9e5,PRIORITY_HIGH:10,PRIORITY_LOW:20}},function(e,t,n){"use strict";const r=n(280);e.exports.msHandle=((e,t)=>new Promise((n,r)=>{e.handle(t,e=>{if(e)return r(e);n()})})),e.exports.msSelect=((e,t)=>new Promise((n,r)=>{e.select(t,(e,t)=>{if(e)return r(e);n(t)})})),e.exports.identifyDialer=((e,t)=>new Promise((n,i)=>{r.dialer(e,t,(e,t,r)=>{if(e)return i(e);n({peerInfo:t,observedAddrs:r})})})),e.exports.uniqueBy=((e,t)=>[...new Map(e.map(e=>[t(e),e])).values()])},function(e,t,n){"use strict";t=e.exports,t.multicodec="/ipfs/id/1.0.0",t.listener=n(1043),t.dialer=n(1044),t.message=n(281)},function(e,t,n){"use strict";const r=n(57),i="\nmessage Identify {\n // protocolVersion determines compatibility between peers\n optional string protocolVersion = 5; // e.g. ipfs/1.0.0\n\n // agentVersion is like a UserAgent string in browsers, or client version in bittorrent\n // includes the client name and client.\n optional string agentVersion = 6; // e.g. go-ipfs/0.1.0\n\n // publicKey is this node's public key (which also gives its node.ID)\n // - may not need to be sent, as secure channel implies it has been sent.\n // - then again, if we change / disable secure channel, may still want it.\n optional bytes publicKey = 1;\n\n // listenAddrs are the multiaddrs the sender node listens for open connections on\n repeated bytes listenAddrs = 2;\n\n // oservedAddr is the multiaddr of the remote endpoint that the sender node perceives\n // this is useful information to convey to the other side, as it helps the remote endpoint\n // determine whether its connection to the local peer goes through NAT.\n optional bytes observedAddr = 4;\n\n repeated string protocols = 3;\n}\n";e.exports=r(i).Identify},function(e,t,n){"use strict";const r=n(64).Connection,i=n(12);e.exports=((e,t,n,o)=>{const s=new Promise((e,t)=>{n.getPeerInfo((t,r)=>{if(!t&&r)return void e(r);const i=n.setPeerInfo;n.setPeerInfo=(t=>{i.call(n,t),e(t)})})}),a={source:i(n,o.incoming(e,t,s)),sink:i(o.outgoing(e,t,s),n)};return new r(a,n)})},function(e,t,n){"use strict";e.exports={PROTOCOL:"/ipfs/ping/1.0.0",PING_LENGTH:32}},function(e,t,n){var r=n(65),i=n(285),o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,s=/^\w*$/;function a(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!i(e))||(s.test(e)||!o.test(e)||null!=t&&e in Object(t))}e.exports=a},function(e,t,n){var r=n(108),i=n(87),o="[object Symbol]";function s(e){return"symbol"==typeof e||i(e)&&r(e)==o}e.exports=s},function(e,t,n){var r=n(1074),i=n(1090),o=n(1092),s=n(1093),a=n(1094);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=i,l.prototype.get=o,l.prototype.has=s,l.prototype.set=a,e.exports=l},function(e,t,n){var r=n(103),i=n(79),o=r(i,"Map");e.exports=o},function(e,t,n){var r=n(1095);function i(e){return null==e?"":r(e)}e.exports=i},function(e,t,n){"use strict";t.messages={NOT_STARTED_YET:"The libp2p node is not started yet",DHT_DISABLED:"DHT is not available"},t.codes={DHT_DISABLED:"ERR_DHT_DISABLED",PUBSUB_NOT_STARTED:"ERR_PUBSUB_NOT_STARTED",ERR_NODE_NOT_STARTED:"ERR_NODE_NOT_STARTED",ERR_DISCOVERED_SELF:"ERR_DISCOVERED_SELF"}},function(e,t,n){"use strict";const r=n(57),i=r(n(1108)),o=i.RPC,s=r(n(1109));t=e.exports,t.rpc=i,t.td=s,t.RPC=o,t.Message=o.Message,t.SubOpts=o.SubOpts},function(e,t,n){var r=n(1154);e.exports=function(e,t,n){n=void 0===n||n;var i=!1,o;return function(s){var a=0,l=0,u=0,c=[],h=!1,f=!1,p,d;function m(){if(p){var e=p;if(d)return p=null,e(d);if(Object.hasOwnProperty.call(c,l)){p=null;var n=c[l];delete c[l],l++,e(null,n),t&&g()}else l>=u&&f&&(p=null,e(f))}}var g=r(function(){if(h=!0,f)return m();i||t&&a-t>=l||(i=!0,s(o,function(t,r){if(i=!1,t)u=a,f=t,m();else{var o=a++;e(r,function(e,t){n?c[o]=t:c.push(t),e&&(d=e),m()}),f||g()}}))});return function(e,t){e?s(f=o=e,function(e){if(t)return t(e)}):(p=t,h||g(),m())}}}},function(e,t,n){"use strict";const r=n(165),i=100;e.exports=function e(t){const n=t||100;var i=[];return r(function e(t){for(i=i.concat(t);i.length>=n;){const e=n,t=i.slice(0,e);i=i.slice(e),this.queue(t)}},function e(t){i.length&&(this.queue(i),i=[]),this.queue(null)})}},function(e,t,n){"use strict";e.exports=class e{constructor(e,t){this._options=t||{},Object.assign(this,e)}}},function(e,t,n){"use strict";const r=n(1169),i=n(1170),o={bits:8};class s{constructor(e,t,n){if(this._options=Object.assign({},o,e),this._popCount=0,this._parent=t,this._posAtParent=n,!this._options.hashFn)throw new Error("please define an options.hashFn");this._options.hash||(this._options.hash=i(this._options.hashFn)),this._children=new r}static isBucket(e){return e instanceof s}async put(e,t){const n=await this._findNewBucketAndPos(e);await n.bucket._putAt(n,e,t)}async get(e){const t=await this._findChild(e);if(t)return t.value}async del(e){const t=await this._findPlace(e),n=t.bucket._at(t.pos);n&&n.key===e&&t.bucket._delAt(t.pos)}leafCount(){return this._children.compactArray().reduce((e,t)=>t instanceof s?e+t.leafCount():e+1,0)}childrenCount(){return this._children.length}onlyChild(){return this._children.get(0)}*eachLeafSeries(){const e=this._children.compactArray();for(const t of e)if(t instanceof s)for(const e of t.eachLeafSeries())yield e;else yield t}serialize(e,t){return t(this._children.reduce((n,r,i)=>(r&&(r instanceof s?n.push(r.serialize(e,t)):n.push(e(r,i))),n),[]))}async asyncTransform(e,t){return c(this,e,t)}toJSON(){return this.serialize(l,u)}prettyPrint(){return JSON.stringify(this.toJSON(),null," ")}tableSize(){return Math.pow(2,this._options.bits)}async _findChild(e){const t=await this._findPlace(e),n=t.bucket._at(t.pos);if(n&&n.key===e)return n}async _findPlace(e){const t=this._options.hash(e),n=await t.take(this._options.bits),r=this._children.get(n);return r instanceof s?r._findPlace(t):{bucket:this,pos:n,hash:t}}async _findNewBucketAndPos(e){const t=await this._findPlace(e),n=t.bucket._at(t.pos);if(n&&n.key!==e){const e=new s(this._options,t.bucket,t.pos);t.bucket._putObjectAt(t.pos,e);const r=await e._findPlace(n.hash);return r.bucket._putAt(r,n.key,n.value),e._findNewBucketAndPos(t.hash)}return t}_putAt(e,t,n){this._putObjectAt(e.pos,{key:t,value:n,hash:e.hash})}_putObjectAt(e,t){this._children.get(e)||this._popCount++,this._children.set(e,t)}_delAt(e){this._children.get(e)&&this._popCount--,this._children.unset(e),this._level()}_level(){if(this._parent&&this._popCount<=1)if(1===this._popCount){const e=this._children.find(a);if(!(e instanceof s)){const t=e.hash;t.untake(this._options.bits);const n={pos:this._posAtParent,hash:t};this._parent._putAt(n,e.key,e.value)}}else this._parent._delAt(this._posAtParent)}_at(e){return this._children.get(e)}}function a(e){return Boolean(e)}function l(e,t){return e.key}function u(e){return e}async function c(e,t,n){const r=[];for(const i of e._children.compactArray()){if(i instanceof s)await c(i,t,n);else{const n=await t(i);r.push({bitField:e._children.bitField(),children:n})}return n(r)}}e.exports=s},function(e,t,n){"use strict";const r=(e="")=>(e.trim().match(/([^\\^/]|\\\/)+/g)||[]).filter(Boolean);e.exports=r},function(e,t,n){"use strict";(function(t){const r=n(10),i=n(45),o=n(81),{loadNode:s,formatCid:a,toMfsPath:l,FILE_SEPARATOR:u,FILE_TYPES:c}=n(73),h=n(12),f=n(33),p=n(74),d=n(67),m=n(116),g=n(71),y=n(61),v={long:!1,cidBase:"base58btc"};e.exports=(e=>(function n(b,_={}){"object"==typeof b&&(_=b,b=u),void 0===b&&(b=u),_=Object.assign({},v,_),_.long=_.l||_.long;const w=y.source();return r([t=>l(e,b,t),({mfsPath:t,depth:n},r)=>{h(o(t,e.ipld,{maxDepth:n}),f((i,s)=>{if(i)return r(i);if(s.length>1)return r(new Error(`Path ${b} had ${s.length} roots`));const a=s[0];if(!a)return r(new Error(`${b} does not exist`));if("dir"!==a.type)return r(null,m(a));let l=!0;return r(null,h(o(t,e.ipld,{maxDepth:n+1}),d(()=>!l||(l=!1,!1))))}))},(n,r)=>{r(null,h(n,p((n,r)=>{if(!_.long)return r(null,{name:n.name,type:0,size:0,hash:""});s(e,{cid:n.cid},(e,o)=>{if(e)return r(e);if(t.isBuffer(o.node))return r(null,{name:n.name,type:0,hash:a(n.cid,_.cidBase),size:o.node.length});const s=i.unmarshal(o.node.data);r(null,{name:n.name,type:c[s.type],hash:a(n.cid,_.cidBase),size:s.fileSize()||0})})})))}],(e,t)=>{if(e)return w.resolve(g(e));w.resolve(t)}),w}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(10),i=n(59),o=n(4)("ipfs:mfs:mkdir"),s=n(81),a=n(12),l=n(67),u=n(66),c=n(33),{createNode:h,toMfsPath:f,toPathComponents:p,updateMfsRoot:d,updateTree:m,FILE_SEPARATOR:g}=n(73),y={parents:!1,hashAlg:"sha2-256",cidVersion:0,shardSplitThreshold:1e3,format:"dag-pb",flush:!0};e.exports=(e=>(function t(n,v,b){if("function"==typeof v&&(b=v,v={}),v=Object.assign({},y,v),v.parents=v.p||v.parents,v.cidVersion=v.cidVersion||0,!n)return b(new Error("no path given to Mkdir"));if(n=n.trim(),n===g)return b(v.parents?null:new Error(`cannot create directory '${g}': Already exists`));o(`Creating ${n}`);const _=p(n);r([t=>f(e,n,t),({mfsDirectory:t,mfsPath:n,root:r},i)=>{const o=p(n).slice(1);let h=0,f="";a(s(n,e.ipld,{fullPath:!0}),l(e=>e.name===o[h]&&(h++,!0)),u(e=>{const t=`${f}${f?"/":""}${o[e.depth]}`;if("dir"!==e.type)throw new Error(`cannot access ${t}: Not a directory`);return f=t,{cid:e.cid,name:e.name}}),c(i))},(t,n)=>{if(_.unshift("/"),t.length===_.length)return n(new Error("file already exists"));i(_.map((e,t)=>({part:e,index:t})),({part:n,index:i},o)=>t[i]?o(null,{name:n,...t[i]}):i===_.length-1||v.parents?void r([t=>h(e,"directory",v,t),({cid:e,node:t},r)=>{r(null,{cid:e,size:t.size,name:n})}],o):o(new Error("file does not exist")),n)},(t,n)=>m(e,t,v,n),({cid:t},n)=>d(e,t,n)],e=>{e&&e.message.includes("file already exists")&&v.parents&&(e=null),b(e)})}))},function(e,t,n){"use strict";const r=n(81),i=n(12),o=n(116),s=n(74),a=n(187),l=n(67),u=n(61),c=n(33),{toMfsPath:h}=n(73),f=n(4)("ipfs:mfs:read-pull-stream"),p={offset:0,length:void 0};e.exports=(e=>(function t(n,d={}){d=Object.assign({},p,d),d.length=d.length||d.count,f(`Reading ${n}`);const m=u.source();return i(o(n),s((t,n)=>h(e,t,n)),s(({mfsPath:t,root:n},o)=>(f(`Exporting ${t}`),i(r(t,e.ipld,{offset:d.offset,length:d.length}),c(o)))),a(),l(),c((e,t)=>{if(e)return m.abort(e);if(!t||!t.length)return m.abort(new Error(`${n} does not exist`));const r=t[0];return"file"!==r.type?m.abort(new Error(`${n} was not a file`)):r.content?(f(`Got ${n} content`),void m.resolve(t[0].content)):m.abort(new Error(`Could not load content stream from ${n}`))})),m}))},function(e,t,n){"use strict";const r=n(26),i=n(166),o=n(167);e.exports=((e,t)=>{const n=o(e,t);return(e,t,o)=>{const s=r(o),a=n(t),l=i(e=>s(null,e));a.once("error",s),a.pipe(l),a.write(e),a.end()}})},function(e,t,n){"use strict";const r=n(53),i=n(1290),o=n(17).Readable;class s extends o{constructor(e){const t=Object.assign(e||{},{objectMode:!0});super(t)}_read(){}}const a=(e,t)=>{let n=new s,o=i.extract();o.on("entry",(e,t,r)=>{t.on("end",r),"directory"!==e.type?n.push({path:e.name,content:t}):(n.push({path:e.name}),t.resume())}).on("finish",()=>n.push(null)),r(e,o),t(null,n)};e.exports=a},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Array.isArray,o=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),s=function e(t){for(;t.length>1;){var n=t.pop(),r=n.obj[n.prop];if(i(r)){for(var o=[],s=0;s<r.length;++s)void 0!==r[s]&&o.push(r[s]);n.obj[n.prop]=o}}},a=function e(t,n){for(var r=n&&n.plainObjects?Object.create(null):{},i=0;i<t.length;++i)void 0!==t[i]&&(r[i]=t[i]);return r},l=function e(t,n,o){if(!n)return t;if("object"!=typeof n){if(i(t))t.push(n);else{if(!t||"object"!=typeof t)return[t,n];(o&&(o.plainObjects||o.allowPrototypes)||!r.call(Object.prototype,n))&&(t[n]=!0)}return t}if(!t||"object"!=typeof t)return[t].concat(n);var s=t;return i(t)&&!i(n)&&(s=a(t,o)),i(t)&&i(n)?(n.forEach(function(n,i){if(r.call(t,i)){var s=t[i];s&&"object"==typeof s&&n&&"object"==typeof n?t[i]=e(s,n,o):t.push(n)}else t[i]=n}),t):Object.keys(n).reduce(function(t,i){var s=n[i];return r.call(t,i)?t[i]=e(t[i],s,o):t[i]=s,t},s)},u=function e(t,n){return Object.keys(n).reduce(function(e,t){return e[t]=n[t],e},t)},c=function(e,t,n){var r=e.replace(/\+/g," ");if("iso-8859-1"===n)return r.replace(/%[0-9a-f]{2}/gi,unescape);try{return decodeURIComponent(r)}catch(e){return r}},h=function e(t,n,r){if(0===t.length)return t;var i="string"==typeof t?t:String(t);if("iso-8859-1"===r)return escape(i).replace(/%u[0-9a-f]{4}/gi,function(e){return"%26%23"+parseInt(e.slice(2),16)+"%3B"});for(var s="",a=0;a<i.length;++a){var l=i.charCodeAt(a);45===l||46===l||95===l||126===l||l>=48&&l<=57||l>=65&&l<=90||l>=97&&l<=122?s+=i.charAt(a):l<128?s+=o[l]:l<2048?s+=o[192|l>>6]+o[128|63&l]:l<55296||l>=57344?s+=o[224|l>>12]+o[128|l>>6&63]+o[128|63&l]:(a+=1,l=65536+((1023&l)<<10|1023&i.charCodeAt(a)),s+=o[240|l>>18]+o[128|l>>12&63]+o[128|l>>6&63]+o[128|63&l])}return s},f=function e(t){for(var n=[{obj:{o:t},prop:"o"}],r=[],i=0;i<n.length;++i)for(var o=n[i],a=o.obj[o.prop],l=Object.keys(a),u=0;u<l.length;++u){var c=l[u],h=a[c];"object"==typeof h&&null!==h&&-1===r.indexOf(h)&&(n.push({obj:a,prop:c}),r.push(h))}return s(n),t},p=function e(t){return"[object RegExp]"===Object.prototype.toString.call(t)},d=function e(t){return!(!t||"object"!=typeof t)&&!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))},m=function e(t,n){return[].concat(t,n)};e.exports={arrayToObject:a,assign:u,combine:m,compact:f,decode:c,encode:h,isBuffer:d,isRegExp:p,merge:l}},function(e,t,n){var r=n(1311),i=n(1312),o=n(198).EOL,s=n(539);function a(e){function t(t){try{if(t)return JSON.parse(t)}catch(n){e.strict&&this.emit("error",new Error("Could not parse row "+t.slice(0,50)+"..."))}}return e=e||{},e.strict=!1!==e.strict,i(t,e)}function l(e){return r.obj(e,function(e,t,n){n(null,s(e)+o)})}e.exports=a,e.exports.serialize=e.exports.stringify=l,e.exports.parse=a},function(e,t,n){"use strict";const r=n(1328),i=Symbol("max"),o=Symbol("length"),s=Symbol("lengthCalculator"),a=Symbol("allowStale"),l=Symbol("maxAge"),u=Symbol("dispose"),c=Symbol("noDisposeOnSet"),h=Symbol("lruList"),f=Symbol("cache"),p=Symbol("updateAgeOnGet"),d=()=>1;class m{constructor(e){if("number"==typeof e&&(e={max:e}),e||(e={}),e.max&&("number"!=typeof e.max||e.max<0))throw new TypeError("max must be a non-negative number");const t=this[i]=e.max||1/0,n=e.length||d;if(this[s]="function"!=typeof n?d:n,this[a]=e.stale||!1,e.maxAge&&"number"!=typeof e.maxAge)throw new TypeError("maxAge must be a number");this[l]=e.maxAge||0,this[u]=e.dispose,this[c]=e.noDisposeOnSet||!1,this[p]=e.updateAgeOnGet||!1,this.reset()}set max(e){if("number"!=typeof e||e<0)throw new TypeError("max must be a non-negative number");this[i]=e||1/0,v(this)}get max(){return this[i]}set allowStale(e){this[a]=!!e}get allowStale(){return this[a]}set maxAge(e){if("number"!=typeof e)throw new TypeError("maxAge must be a non-negative number");this[l]=e,v(this)}get maxAge(){return this[l]}set lengthCalculator(e){"function"!=typeof e&&(e=d),e!==this[s]&&(this[s]=e,this[o]=0,this[h].forEach(e=>{e.length=this[s](e.value,e.key),this[o]+=e.length})),v(this)}get lengthCalculator(){return this[s]}get length(){return this[o]}get itemCount(){return this[h].length}rforEach(e,t){t=t||this;for(let n=this[h].tail;null!==n;){const r=n.prev;w(this,e,n,t),n=r}}forEach(e,t){t=t||this;for(let n=this[h].head;null!==n;){const r=n.next;w(this,e,n,t),n=r}}keys(){return this[h].toArray().map(e=>e.key)}values(){return this[h].toArray().map(e=>e.value)}reset(){this[u]&&this[h]&&this[h].length&&this[h].forEach(e=>this[u](e.key,e.value)),this[f]=new Map,this[h]=new r,this[o]=0}dump(){return this[h].map(e=>!y(this,e)&&{k:e.key,v:e.value,e:e.now+(e.maxAge||0)}).toArray().filter(e=>e)}dumpLru(){return this[h]}set(e,t,n){if(n=n||this[l],n&&"number"!=typeof n)throw new TypeError("maxAge must be a number");const r=n?Date.now():0,a=this[s](t,e);if(this[f].has(e)){if(a>this[i])return b(this,this[f].get(e)),!1;const s=this[f].get(e),l=s.value;return this[u]&&(this[c]||this[u](e,l.value)),l.now=r,l.maxAge=n,l.value=t,this[o]+=a-l.length,l.length=a,this.get(e),v(this),!0}const p=new _(e,t,a,r,n);return p.length>this[i]?(this[u]&&this[u](e,t),!1):(this[o]+=p.length,this[h].unshift(p),this[f].set(e,this[h].head),v(this),!0)}has(e){if(!this[f].has(e))return!1;const t=this[f].get(e).value;return!y(this,t)}get(e){return g(this,e,!0)}peek(e){return g(this,e,!1)}pop(){const e=this[h].tail;return e?(b(this,e),e.value):null}del(e){b(this,this[f].get(e))}load(e){this.reset();const t=Date.now();for(let n=e.length-1;n>=0;n--){const r=e[n],i=r.e||0;if(0===i)this.set(r.k,r.v);else{const e=i-t;e>0&&this.set(r.k,r.v,e)}}}prune(){this[f].forEach((e,t)=>g(this,t,!1))}}const g=(e,t,n)=>{const r=e[f].get(t);if(r){const t=r.value;if(y(e,t)){if(b(e,r),!e[a])return}else n&&(e[p]&&(r.value.now=Date.now()),e[h].unshiftNode(r));return t.value}},y=(e,t)=>{if(!t||!t.maxAge&&!e[l])return!1;const n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[l]&&n>e[l]},v=e=>{if(e[o]>e[i])for(let t=e[h].tail;e[o]>e[i]&&null!==t;){const n=t.prev;b(e,t),t=n}},b=(e,t)=>{if(t){const n=t.value;e[u]&&e[u](n.key,n.value),e[o]-=n.length,e[f].delete(n.key),e[h].removeNode(t)}};class _{constructor(e,t,n,r,i){this.key=e,this.value=t,this.length=n,this.now=r,this.maxAge=i||0}}const w=(e,t,n,r)=>{let i=n.value;y(e,i)&&(b(e,n),e[a]||(i=void 0)),i&&t.call(r,i.value,i.key,e)};e.exports=m},function(e,t,n){"use strict";const r=n(91);function i(e,t,n){"function"==typeof e.pipe?r(e,(e,r)=>{if(e)return n(e);t(r,n)}):t(e,n)}e.exports=i},function(e,t,n){"use strict";const r=n(17).Transform,i=n(1362);class o extends r{constructor(e){const t=Object.assign(e||{},{objectMode:!0});super(t)}_transform(e,t,n){try{const t=i(e);if(this.push(t),!t.success)throw new Error(t.text)}catch(e){return n(e)}n()}}e.exports=o},function(e,t,n){"use strict";const r=n(55);e.exports=(e=>({totalIn:new r(e.TotalIn),totalOut:new r(e.TotalOut),rateIn:new r(e.RateIn),rateOut:new r(e.RateOut)}))},function(e,t,n){(function(t){e.exports=h;const r=n(552),i=n(1548),o=n(131),s=n(169),a=n(26),l=n(145),u=n(32),c=e=>null!==e&&"object"==typeof e&&"function"==typeof e.pipe;function h(e,n){if(e=Object.assign({maxRedirects:10},"string"==typeof e?{url:e}:e),n=a(n),e.url){const{hostname:t,port:n,protocol:r,auth:i,path:o}=u.parse(e.url);delete e.url,t||n||r||i?Object.assign(e,{hostname:t,port:n,protocol:r,auth:i,path:o}):e.path=o}const r={"accept-encoding":"gzip, deflate"};let f;e.headers&&Object.keys(e.headers).forEach(t=>r[t.toLowerCase()]=e.headers[t]),e.headers=r,e.body?f=e.json&&!c(e.body)?JSON.stringify(e.body):e.body:e.form&&(f="string"==typeof e.form?e.form:l.stringify(e.form),e.headers["content-type"]="application/x-www-form-urlencoded"),f&&(e.method||(e.method="POST"),c(f)||(e.headers["content-length"]=t.byteLength(f)),e.json&&!e.form&&(e.headers["content-type"]="application/json")),delete e.body,delete e.form,e.json&&(e.headers.accept="application/json"),e.method&&(e.method=e.method.toUpperCase());const p="https:"===e.protocol?s:o,d=p.request(e,t=>{if(t.statusCode>=300&&t.statusCode<400&&t.headers.location)return e.url=t.headers.location,delete e.headers.host,t.resume(),"POST"===e.method&&[301,302].includes(t.statusCode)&&(e.method="GET",delete e.headers["content-length"],delete e.headers["content-type"]),0==e.maxRedirects--?n(new Error("too many redirects")):h(e,n);const r="function"==typeof i&&"HEAD"!==e.method;n(null,r?i(t):t)});return d.on("timeout",()=>{d.abort(),n(new Error("Request timed out"))}),d.on("error",n),c(f)?f.on("error",n).pipe(d):d.end(f),d}h.concat=((e,t)=>h(e,(n,i)=>{if(n)return t(n);r(i,(n,r)=>{if(n)return t(n);if(e.json)try{r=JSON.parse(r.toString())}catch(n){return t(n,i,r)}t(null,i,r)})})),["get","post","put","patch","head","delete"].forEach(e=>{h[e]=((t,n)=>("string"==typeof t&&(t={url:t}),h(Object.assign({method:e.toUpperCase()},t),n)))})}).call(this,n(0).Buffer)},function(e,t,n){(function(t){e.exports=h;var r=n(4)("simple-peer"),i=n(455),o=n(1),s=n(101),a=n(1552),l=65536,u=5e3,c=5e3;function h(e){var t=this;if(!(t instanceof h))return new h(e);if(t._id=s(4).toString("hex").slice(0,7),t._debug("new peer %o",e),e=Object.assign({allowHalfOpen:!1},e),a.Duplex.call(t,e),t.channelName=e.initiator?e.channelName||s(20).toString("hex"):null,t.initiator=e.initiator||!1,t.channelConfig=e.channelConfig||h.channelConfig,t.config=Object.assign({},h.config,e.config),t.offerOptions=e.offerOptions||{},t.answerOptions=e.answerOptions||{},t.sdpTransform=e.sdpTransform||function(e){return e},t.streams=e.streams||(e.stream?[e.stream]:[]),t.trickle=void 0===e.trickle||e.trickle,t.allowHalfTrickle=void 0!==e.allowHalfTrickle&&e.allowHalfTrickle,t.iceCompleteTimeout=e.iceCompleteTimeout||u,t.destroyed=!1,t.connected=!1,t.remoteAddress=void 0,t.remoteFamily=void 0,t.remotePort=void 0,t.localAddress=void 0,t.localFamily=void 0,t.localPort=void 0,t._wrtc=e.wrtc&&"object"==typeof e.wrtc?e.wrtc:i(),!t._wrtc)throw"undefined"==typeof window?p("No WebRTC support: Specify `opts.wrtc` option in this environment","ERR_WEBRTC_SUPPORT"):p("No WebRTC support: Not a supported browser","ERR_WEBRTC_SUPPORT");t._pcReady=!1,t._channelReady=!1,t._iceComplete=!1,t._iceCompleteTimer=null,t._channel=null,t._pendingCandidates=[],t._isNegotiating=!t.initiator,t._batchedNegotiation=!1,t._queuedNegotiation=!1,t._sendersAwaitingStable=[],t._senderMap=new Map,t._firstStable=!0,t._closingInterval=null,t._remoteTracks=[],t._remoteStreams=[],t._chunk=null,t._cb=null,t._interval=null;try{t._pc=new t._wrtc.RTCPeerConnection(t.config)}catch(e){t.destroy(e)}t._isReactNativeWebrtc="number"==typeof t._pc._peerConnectionId,t._pc.oniceconnectionstatechange=function(){t._onIceStateChange()},t._pc.onicegatheringstatechange=function(){t._onIceStateChange()},t._pc.onsignalingstatechange=function(){t._onSignalingStateChange()},t._pc.onicecandidate=function(e){t._onIceCandidate(e)},t.initiator?t._setupData({channel:t._pc.createDataChannel(t.channelName,t.channelConfig)}):t._pc.ondatachannel=function(e){t._setupData(e)},t.streams&&t.streams.forEach(function(e){t.addStream(e)}),t._pc.ontrack=function(e){t._onTrack(e)},t.initiator&&t._needsNegotiation(),t._onFinishBound=function(){t._onFinish()},t.once("finish",t._onFinishBound)}function f(e){return e.replace(/a=ice-options:trickle\s\n/g,"")}function p(e,t){var n=new Error(e);return n.code=t,n}o(h,a.Duplex),h.WEBRTC_SUPPORT=!!i(),h.config={iceServers:[{urls:"stun:stun.l.google.com:19302"},{urls:"stun:global.stun.twilio.com:3478?transport=udp"}],sdpSemantics:"unified-plan"},h.channelConfig={},Object.defineProperty(h.prototype,"bufferSize",{get:function(){var e=this;return this._channel&&this._channel.bufferedAmount||0}}),h.prototype.address=function(){var e=this;return{port:this.localPort,family:this.localFamily,address:this.localAddress}},h.prototype.signal=function(e){var t=this;if(t.destroyed)throw p("cannot signal after peer is destroyed","ERR_SIGNALING");if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e={}}t._debug("signal()"),e.renegotiate&&t.initiator&&(t._debug("got request to renegotiate"),t._needsNegotiation()),e.transceiverRequest&&t.initiator&&(t._debug("got request for transceiver"),t.addTransceiver(e.transceiverRequest.kind,e.transceiverRequest.init)),e.candidate&&(t._pc.localDescription&&t._pc.localDescription.type&&t._pc.remoteDescription&&t._pc.remoteDescription.type?t._addIceCandidate(e.candidate):t._pendingCandidates.push(e.candidate)),e.sdp&&t._pc.setRemoteDescription(new t._wrtc.RTCSessionDescription(e)).then(function(){t.destroyed||(t._pendingCandidates.forEach(function(e){t._addIceCandidate(e)}),t._pendingCandidates=[],"offer"===t._pc.remoteDescription.type&&t._createAnswer())}).catch(function(e){t.destroy(p(e,"ERR_SET_REMOTE_DESCRIPTION"))}),e.sdp||e.candidate||e.renegotiate||e.transceiverRequest||t.destroy(p("signal() called with invalid signal data","ERR_SIGNALING"))},h.prototype._addIceCandidate=function(e){var t=this;t._pc.addIceCandidate(new t._wrtc.RTCIceCandidate(e)).catch(function(e){if("closed"!==t._pc.signalingState&&"Failed to set ICE candidate; RTCPeerConnection is closed."===e.message)return t._debug("ignoring incorrect wrtc error");t.destroy(p(e,"ERR_ADD_ICE_CANDIDATE"))})},h.prototype.send=function(e){var t=this;this._channel.send(e)},h.prototype.addTransceiver=function(e,t){var n=this;if(this._debug("addTransceiver()"),this.initiator)try{this._pc.addTransceiver(e,t),this._needsNegotiation()}catch(e){this.destroy(e)}else this.emit("signal",{transceiverRequest:{kind:e,init:t}})},h.prototype.addStream=function(e){var t=this;t._debug("addStream()"),e.getTracks().forEach(function(n){t.addTrack(n,e)})},h.prototype.addTrack=function(e,t){var n=this;this._debug("addTrack()");var r=this._senderMap.get(e)||new Map,i=r.get(t);i?i.removed?this.destroy(p("Track has been removed. You should enable/disable tracks that you want to re-add."),"ERR_SENDER_REMOVED"):this.destroy(p("Track has already been added to that stream."),"ERR_SENDER_ALREADY_ADDED"):(i=this._pc.addTrack(e,t),r.set(t,i),this._senderMap.set(e,r),this._needsNegotiation())},h.prototype.replaceTrack=function(e,t,n){var r=this;this._debug("replaceTrack()");var i=this._senderMap.get(e),o=i?i.get(n):null;o||this.destroy(p("Cannot replace track that was never added."),"ERR_TRACK_NOT_ADDED"),t&&this._senderMap.set(t,i),null!=o.replaceTrack?o.replaceTrack(t):this.destroy(p("replaceTrack is not supported in this browser","ERR_UNSUPPORTED_REPLACETRACK"))},h.prototype.removeTrack=function(e,t){var n=this;this._debug("removeSender()");var r=this._senderMap.get(e),i=r?r.get(t):null;i||this.destroy(p("Cannot remove track that was never added.","ERR_TRACK_NOT_ADDED"));try{i.removed=!0,this._pc.removeTrack(i)}catch(e){"NS_ERROR_UNEXPECTED"===e.name?this._sendersAwaitingStable.push(i):this.destroy(e)}this._needsNegotiation()},h.prototype.removeStream=function(e){var t=this;t._debug("removeSenders()"),e.getTracks().forEach(function(n){t.removeTrack(n,e)})},h.prototype._needsNegotiation=function(){var e=this;e._debug("_needsNegotiation"),e._batchedNegotiation||(e._batchedNegotiation=!0,setTimeout(function(){e._batchedNegotiation=!1,e._debug("starting batched negotiation"),e.negotiate()},0))},h.prototype.negotiate=function(){var e=this;e.initiator?e._isNegotiating?(e._queuedNegotiation=!0,e._debug("already negotiating, queueing")):(e._debug("start negotiation"),setTimeout(()=>{e._createOffer()},0)):e._isNegotiating||(e._debug("requesting negotiation from initiator"),e.emit("signal",{renegotiate:!0})),e._isNegotiating=!0},h.prototype.destroy=function(e){var t=this;this._destroy(e,function(){})},h.prototype._destroy=function(e,t){var n=this;if(!this.destroyed){if(this._debug("destroy (error: %s)",e&&(e.message||e)),this.readable=this.writable=!1,this._readableState.ended||this.push(null),this._writableState.finished||this.end(),this.destroyed=!0,this.connected=!1,this._pcReady=!1,this._channelReady=!1,this._remoteTracks=null,this._remoteStreams=null,this._senderMap=null,clearInterval(this._closingInterval),this._closingInterval=null,clearInterval(this._interval),this._interval=null,this._chunk=null,this._cb=null,this._onFinishBound&&this.removeListener("finish",this._onFinishBound),this._onFinishBound=null,this._channel){try{this._channel.close()}catch(e){}this._channel.onmessage=null,this._channel.onopen=null,this._channel.onclose=null,this._channel.onerror=null}if(this._pc){try{this._pc.close()}catch(e){}this._pc.oniceconnectionstatechange=null,this._pc.onicegatheringstatechange=null,this._pc.onsignalingstatechange=null,this._pc.onicecandidate=null,this._pc.ontrack=null,this._pc.ondatachannel=null}this._pc=null,this._channel=null,e&&this.emit("error",e),this.emit("close"),t()}},h.prototype._setupData=function(e){var t=this;if(!e.channel)return t.destroy(p("Data channel event is missing `channel` property","ERR_DATA_CHANNEL"));t._channel=e.channel,t._channel.binaryType="arraybuffer","number"==typeof t._channel.bufferedAmountLowThreshold&&(t._channel.bufferedAmountLowThreshold=65536),t.channelName=t._channel.label,t._channel.onmessage=function(e){t._onChannelMessage(e)},t._channel.onbufferedamountlow=function(){t._onChannelBufferedAmountLow()},t._channel.onopen=function(){t._onChannelOpen()},t._channel.onclose=function(){t._onChannelClose()},t._channel.onerror=function(e){t.destroy(p(e,"ERR_DATA_CHANNEL"))};var n=!1;t._closingInterval=setInterval(function(){t._channel&&"closing"===t._channel.readyState?(n&&t._onChannelClose(),n=!0):n=!1},5e3)},h.prototype._read=function(){},h.prototype._write=function(e,t,n){var r=this;if(this.destroyed)return n(p("cannot write after peer is destroyed","ERR_DATA_CHANNEL"));if(this.connected){try{this.send(e)}catch(e){return this.destroy(p(e,"ERR_DATA_CHANNEL"))}this._channel.bufferedAmount>65536?(this._debug("start backpressure: bufferedAmount %d",this._channel.bufferedAmount),this._cb=n):n(null)}else this._debug("write before connect"),this._chunk=e,this._cb=n},h.prototype._onFinish=function(){var e=this;function t(){setTimeout(function(){e.destroy()},1e3)}e.destroyed||(e.connected?t():e.once("connect",t))},h.prototype._startIceCompleteTimeout=function(){var e=this;e.destroyed||e._iceCompleteTimer||(e._debug("started iceComplete timeout"),e._iceCompleteTimer=setTimeout(function(){e._iceComplete||(e._iceComplete=!0,e._debug("iceComplete timeout completed"),e.emit("iceTimeout"),e.emit("_iceComplete"))},e.iceCompleteTimeout))},h.prototype._createOffer=function(){var e=this;e.destroyed||e._pc.createOffer(e.offerOptions).then(function(t){function n(){e._debug("createOffer success"),e.destroyed||(e.trickle||e._iceComplete?i():e.once("_iceComplete",i))}function r(t){e.destroy(p(t,"ERR_SET_LOCAL_DESCRIPTION"))}function i(){if(!e.destroyed){var n=e._pc.localDescription||t;e._debug("signal"),e.emit("signal",{type:n.type,sdp:n.sdp})}}e.destroyed||(e.trickle||e.allowHalfTrickle||(t.sdp=f(t.sdp)),t.sdp=e.sdpTransform(t.sdp),e._pc.setLocalDescription(t).then(n).catch(r))}).catch(function(t){e.destroy(p(t,"ERR_CREATE_OFFER"))})},h.prototype._requestMissingTransceivers=function(){var e=this;e._pc.getTransceivers&&e._pc.getTransceivers().forEach(t=>{!t.mid&&t.sender.track&&e.addTransceiver(t.sender.track.kind)})},h.prototype._createAnswer=function(){var e=this;e.destroyed||e._pc.createAnswer(e.answerOptions).then(function(t){function n(){e.destroyed||(e.trickle||e._iceComplete?i():e.once("_iceComplete",i))}function r(t){e.destroy(p(t,"ERR_SET_LOCAL_DESCRIPTION"))}function i(){if(!e.destroyed){var n=e._pc.localDescription||t;e._debug("signal"),e.emit("signal",{type:n.type,sdp:n.sdp}),e.initiator||e._requestMissingTransceivers()}}e.destroyed||(e.trickle||e.allowHalfTrickle||(t.sdp=f(t.sdp)),t.sdp=e.sdpTransform(t.sdp),e._pc.setLocalDescription(t).then(n).catch(r))}).catch(function(t){e.destroy(p(t,"ERR_CREATE_ANSWER"))})},h.prototype._onIceStateChange=function(){var e=this;if(!this.destroyed){var t=this._pc.iceConnectionState,n=this._pc.iceGatheringState;this._debug("iceStateChange (connection: %s) (gathering: %s)",t,n),this.emit("iceStateChange",t,n),"connected"!==t&&"completed"!==t||(this._pcReady=!0,this._maybeReady()),"failed"===t&&this.destroy(p("Ice connection failed.","ERR_ICE_CONNECTION_FAILURE")),"closed"===t&&this.destroy(p("Ice connection closed.","ERR_ICE_CONNECTION_CLOSED"))}},h.prototype.getStats=function(e){var t=this;function n(e){return"[object Array]"===Object.prototype.toString.call(e.values)&&e.values.forEach(function(t){Object.assign(e,t)}),e}0===t._pc.getStats.length?t._pc.getStats().then(function(t){var r=[];t.forEach(function(e){r.push(n(e))}),e(null,r)},function(t){e(t)}):t._isReactNativeWebrtc?t._pc.getStats(null,function(t){var r=[];t.forEach(function(e){r.push(n(e))}),e(null,r)},function(t){e(t)}):t._pc.getStats.length>0?t._pc.getStats(function(r){if(!t.destroyed){var i=[];r.result().forEach(function(e){var t={};e.names().forEach(function(n){t[n]=e.stat(n)}),t.id=e.id,t.type=e.type,t.timestamp=e.timestamp,i.push(n(t))}),e(null,i)}},function(t){e(t)}):e(null,[])},h.prototype._maybeReady=function(){var e=this;function t(){e.destroyed||e.getStats(function(n,r){if(!e.destroyed){n&&(r=[]);var i={},o={},s={},a=!1;if(r.forEach(function(e){"remotecandidate"!==e.type&&"remote-candidate"!==e.type||(i[e.id]=e),"localcandidate"!==e.type&&"local-candidate"!==e.type||(o[e.id]=e),"candidatepair"!==e.type&&"candidate-pair"!==e.type||(s[e.id]=e)}),r.forEach(function(e){"transport"===e.type&&e.selectedCandidatePairId&&u(s[e.selectedCandidatePairId]),("googCandidatePair"===e.type&&"true"===e.googActiveConnection||("candidatepair"===e.type||"candidate-pair"===e.type)&&e.selected)&&u(e)}),a||Object.keys(s).length&&!Object.keys(o).length){if(e._connecting=!1,e.connected=!0,e._chunk){try{e.send(e._chunk)}catch(n){return e.destroy(p(n,"ERR_DATA_CHANNEL"))}e._chunk=null,e._debug('sent chunk from "write before connect"');var l=e._cb;e._cb=null,l(null)}"number"!=typeof e._channel.bufferedAmountLowThreshold&&(e._interval=setInterval(function(){e._onInterval()},150),e._interval.unref&&e._interval.unref()),e._debug("connect"),e.emit("connect")}else setTimeout(t,100)}function u(t){a=!0;var n=o[t.localCandidateId];n&&(n.ip||n.address)?(e.localAddress=n.ip||n.address,e.localPort=Number(n.port)):n&&n.ipAddress?(e.localAddress=n.ipAddress,e.localPort=Number(n.portNumber)):"string"==typeof t.googLocalAddress&&(n=t.googLocalAddress.split(":"),e.localAddress=n[0],e.localPort=Number(n[1])),e.localAddress&&(e.localFamily=e.localAddress.includes(":")?"IPv6":"IPv4");var r=i[t.remoteCandidateId];r&&(r.ip||r.address)?(e.remoteAddress=r.ip||r.address,e.remotePort=Number(r.port)):r&&r.ipAddress?(e.remoteAddress=r.ipAddress,e.remotePort=Number(r.portNumber)):"string"==typeof t.googRemoteAddress&&(r=t.googRemoteAddress.split(":"),e.remoteAddress=r[0],e.remotePort=Number(r[1])),e.remoteAddress&&(e.remoteFamily=e.remoteAddress.includes(":")?"IPv6":"IPv4"),e._debug("connect local: %s:%s remote: %s:%s",e.localAddress,e.localPort,e.remoteAddress,e.remotePort)}})}e._debug("maybeReady pc %s channel %s",e._pcReady,e._channelReady),!e.connected&&!e._connecting&&e._pcReady&&e._channelReady&&(e._connecting=!0,t())},h.prototype._onInterval=function(){var e=this;!this._cb||!this._channel||this._channel.bufferedAmount>65536||this._onChannelBufferedAmountLow()},h.prototype._onSignalingStateChange=function(){var e=this;e.destroyed||("stable"!==e._pc.signalingState||e._firstStable||(e._isNegotiating=!1,e._debug("flushing sender queue",e._sendersAwaitingStable),e._sendersAwaitingStable.forEach(function(t){e._pc.removeTrack(t),e._queuedNegotiation=!0}),e._sendersAwaitingStable=[],e._queuedNegotiation&&(e._debug("flushing negotiation queue"),e._queuedNegotiation=!1,e._needsNegotiation()),e._debug("negotiate"),e.emit("negotiate")),e._firstStable=!1,e._debug("signalingStateChange %s",e._pc.signalingState),e.emit("signalingStateChange",e._pc.signalingState))},h.prototype._onIceCandidate=function(e){var t=this;this.destroyed||(e.candidate&&this.trickle?this.emit("signal",{candidate:{candidate:e.candidate.candidate,sdpMLineIndex:e.candidate.sdpMLineIndex,sdpMid:e.candidate.sdpMid}}):e.candidate||this._iceComplete||(this._iceComplete=!0,this.emit("_iceComplete")),e.candidate&&this._startIceCompleteTimeout())},h.prototype._onChannelMessage=function(e){var n=this;if(!this.destroyed){var r=e.data;r instanceof ArrayBuffer&&(r=t.from(r)),this.push(r)}},h.prototype._onChannelBufferedAmountLow=function(){var e=this;if(!this.destroyed&&this._cb){this._debug("ending backpressure: bufferedAmount %d",this._channel.bufferedAmount);var t=this._cb;this._cb=null,t(null)}},h.prototype._onChannelOpen=function(){var e=this;this.connected||this.destroyed||(this._debug("on channel open"),this._channelReady=!0,this._maybeReady())},h.prototype._onChannelClose=function(){var e=this;this.destroyed||(this._debug("on channel close"),this.destroy())},h.prototype._onTrack=function(e){var t=this;t.destroyed||e.streams.forEach(function(n){t._debug("on track"),t.emit("track",e.track,n),t._remoteTracks.push({track:e.track,stream:n}),t._remoteStreams.some(function(e){return e.id===n.id})||(t._remoteStreams.push(n),setTimeout(function(){t.emit("stream",n)},0))})},h.prototype._debug=function(){var e=this,t=[].slice.call(arguments);t[0]="["+this._id+"] "+t[0],r.apply(null,t)}}).call(this,n(0).Buffer)},function(e,t){var n=1,r=65535,i=4,o,s=function(){n=n+1&65535};e.exports=function(e){o||(o=setInterval(s,250),o.unref&&o.unref());var t=4*(e||5),r=[0],i=1,a=n-1&65535;return function(e){var o=n-a&65535;for(o>t&&(o=t),a=n;o--;)i===t&&(i=0),r[i]=r[0===i?t-1:i-1],i++;e&&(r[i-1]+=e);var s=r[i-1],l=r.length<t?0:r[i===t?0:i];return r.length<4?s:4*(s-l)/r.length}}},function(e,t,n){(function(t){var n=Object.prototype.toString,r="function"==typeof t.alloc&&"function"==typeof t.allocUnsafe&&"function"==typeof t.from;function i(e){return"ArrayBuffer"===n.call(e).slice(8,-1)}function o(e,n,i){n>>>=0;var o=e.byteLength-n;if(o<0)throw new RangeError("'offset' is out of bounds");if(void 0===i)i=o;else if(i>>>=0,i>o)throw new RangeError("'length' is out of bounds");return r?t.from(e.slice(n,n+i)):new t(new Uint8Array(e.slice(n,n+i)))}function s(e,n){if("string"==typeof n&&""!==n||(n="utf8"),!t.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');return r?t.from(e,n):new t(e,n)}function a(e,n,a){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return i(e)?o(e,n,a):"string"==typeof e?s(e,n):r?t.from(e):new t(e)}e.exports=a}).call(this,n(0).Buffer)},function(e){e.exports={name:"webtorrent",description:"Streaming torrent client",version:"0.103.1",author:{name:"WebTorrent, LLC",email:"feross@webtorrent.io",url:"https://webtorrent.io"},browser:{"./lib/server.js":!1,"./lib/tcp-pool.js":!1,"bittorrent-dht/client":!1,"fs-chunk-store":"memory-chunk-store","load-ip-set":!1,net:!1,os:!1,ut_pex:!1},browserify:{transform:["package-json-versionify"]},bugs:{url:"https://github.com/webtorrent/webtorrent/issues"},dependencies:{"addr-to-ip-port":"^1.4.2",bitfield:"^2.0.0","bittorrent-dht":"^9.0.0","bittorrent-protocol":"^3.0.0","chunk-store-stream":"^3.0.1","create-torrent":"^3.33.0",debug:"^4.1.0","end-of-stream":"^1.1.0","fs-chunk-store":"^1.6.2","immediate-chunk-store":"^2.0.0","load-ip-set":"^2.1.0","memory-chunk-store":"^1.2.0",mime:"^2.4.0",multistream:"^2.0.5","package-json-versionify":"^1.0.2","parse-numeric-range":"^0.0.2","parse-torrent":"^6.1.2",pump:"^3.0.0","random-iterate":"^1.0.1",randombytes:"^2.0.3","range-parser":"^1.2.0","readable-stream":"^3.0.6","render-media":"^3.0.0","run-parallel":"^1.1.6","run-parallel-limit":"^1.0.3","safe-buffer":"^5.0.1","simple-concat":"^1.0.0","simple-get":"^3.0.1","simple-peer":"^9.0.0","simple-sha1":"^2.0.8",speedometer:"^1.0.0","stream-to-blob":"^1.0.0","stream-to-blob-url":"^2.1.0","stream-with-known-length-to-buffer":"^1.0.0","torrent-discovery":"^9.1.1","torrent-piece":"^2.0.0",uniq:"^1.0.1","unordered-array-remove":"^1.0.2",ut_metadata:"^3.3.0",ut_pex:"^1.1.1"},devDependencies:{airtap:"2.0.2","babel-minify":"^0.5.0","bittorrent-tracker":"^9.4.0",brfs:"^2.0.0",browserify:"^16.2.3","cross-spawn":"^6.0.3",electron:"^4.0.0",finalhandler:"^1.0.0","network-address":"^1.1.0","run-series":"^1.1.4","serve-static":"^1.11.1",standard:"*",tape:"^4.6.0","webtorrent-fixtures":"^1.5.0"},engines:{node:">=4"},homepage:"https://webtorrent.io",keywords:["bittorrent","bittorrent client","download","mad science","p2p","peer-to-peer","peers","streaming","swarm","torrent","web torrent","webrtc","webrtc data","webtorrent"],license:"MIT",main:"index.js",repository:{type:"git",url:"git://github.com/webtorrent/webtorrent.git"},scripts:{build:"browserify -s WebTorrent -e ./ | minify > webtorrent.min.js","build-debug":"browserify -s WebTorrent -e ./ > webtorrent.debug.js",size:"npm run build && cat webtorrent.min.js | gzip | wc -c",test:"standard && npm run test-node && npm run test-browser","test-browser":"airtap -- test/*.js test/browser/*.js","test-browser-local":"airtap --local -- test/*.js test/browser/*.js","test-node":"tape test/*.js test/node/*.js","update-authors":"./scripts/update-authors.sh"}}},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,i=Object.prototype.toString,o=Object.defineProperty,s=Object.getOwnPropertyDescriptor,a=function e(t){return"function"==typeof Array.isArray?Array.isArray(t):"[object Array]"===i.call(t)},l=function e(t){if(!t||"[object Object]"!==i.call(t))return!1;var n=r.call(t,"constructor"),o=t.constructor&&t.constructor.prototype&&r.call(t.constructor.prototype,"isPrototypeOf"),s;if(t.constructor&&!n&&!o)return!1;for(s in t);return void 0===s||r.call(t,s)},u=function e(t,n){o&&"__proto__"===n.name?o(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},c=function e(t,n){if("__proto__"===n){if(!r.call(t,n))return;if(s)return s(t,n).value}return t[n]};e.exports=function e(){var t,n,r,i,o,s,h=arguments[0],f=1,p=arguments.length,d=!1;for("boolean"==typeof h&&(d=h,h=arguments[1]||{},f=2),(null==h||"object"!=typeof h&&"function"!=typeof h)&&(h={});f<p;++f)if(t=arguments[f],null!=t)for(n in t)r=c(h,n),i=c(t,n),h!==i&&(d&&i&&(l(i)||(o=a(i)))?(o?(o=!1,s=r&&a(r)?r:[]):s=r&&l(r)?r:{},u(h,{name:n,newValue:e(d,s,i)})):void 0!==i&&u(h,{name:n,newValue:i}));return h}},function(e,t,n){"use strict";(function(e){var r=n(539),i=n(16),o=n(5).Buffer,s="undefined"==typeof setImmediate?e.nextTick:setImmediate;function a(e){return e.body||e.requestBodyStream||e.json&&"boolean"!=typeof e.json||e.multipart}function l(e,t){var n;try{n=JSON.stringify(e,t)}catch(i){n=r(e,t)}return n}function u(e){return i.createHash("md5").update(e).digest("hex")}function c(e){return e.readable&&e.path&&e.mode}function h(e){return o.from(e||"","utf8").toString("base64")}function f(e){var t={};return Object.keys(e).forEach(function(n){t[n]=e[n]}),t}function p(){var t=e.version.replace("v","").split(".");return{major:parseInt(t[0],10),minor:parseInt(t[1],10),patch:parseInt(t[2],10)}}t.paramsHaveRequestBody=a,t.safeStringify=l,t.md5=u,t.isReadStream=c,t.toBase64=h,t.copy=f,t.version=p,t.defer=s}).call(this,n(3))},function(e,t,n){var r=n(41),i=n(172),o=n(83),s=n(46),a=n(177),l=n(178),u=n(76);e.exports={Key:r,parseKey:r.parse,Fingerprint:i,parseFingerprint:i.parse,Signature:o,parseSignature:o.parse,PrivateKey:s,parsePrivateKey:s.parse,generatePrivateKey:s.generate,Certificate:a,parseCertificate:a.parse,createSelfSignedCertificate:a.createSelfSigned,createCertificate:a.create,Identity:l,identityFromDN:l.parseDN,identityForHost:l.forHost,identityForUser:l.forUser,identityForEmail:l.forEmail,identityFromArray:l.fromArray,FingerprintFormatError:u.FingerprintFormatError,InvalidAlgorithmError:u.InvalidAlgorithmError,KeyParseError:u.KeyParseError,SignatureParseError:u.SignatureParseError,KeyEncryptedError:u.KeyEncryptedError,CertificateParseError:u.CertificateParseError}},function(e,t){e.exports={newInvalidAsn1Error:function(e){var t=new Error;return t.name="InvalidAsn1Error",t.message=e||"",t}}},function(e,t){e.exports={EOC:0,Boolean:1,Integer:2,BitString:3,OctetString:4,Null:5,OID:6,ObjectDescriptor:7,External:8,Real:9,Enumeration:10,PDV:11,Utf8String:12,RelativeOID:13,Sequence:16,Set:17,NumericString:18,PrintableString:19,T61String:20,VideotexString:21,IA5String:22,UTCTime:23,GeneralizedTime:24,GraphicString:25,VisibleString:26,GeneralString:28,UniversalString:29,CharacterString:30,BMPString:31,Constructor:32,Context:128}},function(e,t,n){e.exports={DiffieHellman:m,generateECDSA:_,generateED25519:b};var r=n(25),i=n(16),o=n(29).Buffer,s=n(48),a=n(42),l=n(174),u=n(41),c=n(46),h=void 0!==i.createECDH,f=n(1656),p=n(237),d=n(173).BigInteger;function m(e){if(a.assertCompatible(e,u,[1,4],"key"),this._isPriv=c.isPrivateKey(e,[1,3]),this._algo=e.type,this._curve=e.curve,this._key=e,"dsa"===e.type){if(!h)throw new Error("Due to bugs in the node 0.10 crypto API, node 0.12.x or later is required to use DH");this._dh=i.createDiffieHellman(e.part.p.data,void 0,e.part.g.data,void 0),this._p=e.part.p,this._g=e.part.g,this._isPriv&&this._dh.setPrivateKey(e.part.x.data),this._dh.setPublicKey(e.part.y.data)}else if("ecdsa"===e.type){if(!h)return this._ecParams=new g(this._curve),void(this._isPriv&&(this._priv=new v(this._ecParams,e.part.d.data)));var t={nistp256:"prime256v1",nistp384:"secp384r1",nistp521:"secp521r1"}[e.curve];if(this._dh=i.createECDH(t),"object"!=typeof this._dh||"function"!=typeof this._dh.setPrivateKey)return h=!1,void m.call(this,e);this._isPriv&&this._dh.setPrivateKey(e.part.d.data),this._dh.setPublicKey(e.part.Q.data)}else{if("curve25519"!==e.type)throw new Error("DH not supported for "+e.type+" keys");this._isPriv&&(a.assertCompatible(e,c,[1,5],"key"),this._priv=e.part.k.data)}}function g(e){var t=s.curves[e];r.object(t);var n=new d(t.p),i=new d(t.a),o=new d(t.b),a=new d(t.n),l=d.ONE,u=new p.ECCurveFp(n,i,o),c=u.decodePointHex(t.G.toString("hex"));this.curve=u,this.g=c,this.n=a,this.h=l}function y(e,t){this._params=e,0===t[0]&&(t=t.slice(1)),this._pub=e.getCurve().decodePointHex(t.toString("hex"))}function v(e,t){this._params=e,this._priv=new d(a.mpNormalize(t))}function b(){var e=l.sign.keyPair(),t=o.from(e.secretKey),n=o.from(e.publicKey);r.strictEqual(t.length,64),r.strictEqual(n.length,32);var i=[];i.push({name:"A",data:n}),i.push({name:"k",data:t.slice(0,32)});var s=new c({type:"ed25519",parts:i});return s}function _(e){var t=[],n;if(h){var r={nistp256:"prime256v1",nistp384:"secp384r1",nistp521:"secp521r1"}[e],s=i.createECDH(r);return s.generateKeys(),t.push({name:"curve",data:o.from(e)}),t.push({name:"Q",data:s.getPublicKey()}),t.push({name:"d",data:s.getPrivateKey()}),n=new c({type:"ecdsa",curve:e,parts:t}),n}var a=new g(e),l=a.getN(),u=Math.ceil((l.bitLength()+64)/8),f=new d(i.randomBytes(u)),p=l.subtract(d.ONE),m=f.mod(p).add(d.ONE),y=a.getG().multiply(m);return m=o.from(m.toByteArray()),y=o.from(a.getCurve().encodePointHex(y),"hex"),t.push({name:"curve",data:o.from(e)}),t.push({name:"Q",data:y}),t.push({name:"d",data:m}),n=new c({type:"ecdsa",curve:e,parts:t}),n}m.prototype.getPublicKey=function(){return this._isPriv?this._key.toPublic():this._key},m.prototype.getPrivateKey=function(){return this._isPriv?this._key:void 0},m.prototype.getKey=m.prototype.getPrivateKey,m.prototype._keyCheck=function(e,t){if(r.object(e,"key"),t||a.assertCompatible(e,c,[1,3],"key"),a.assertCompatible(e,u,[1,4],"key"),e.type!==this._algo)throw new Error("A "+e.type+" key cannot be used in "+this._algo+" Diffie-Hellman");if(e.curve!==this._curve)throw new Error("A key from the "+e.curve+" curve cannot be used with a "+this._curve+" Diffie-Hellman");"dsa"===e.type&&(r.deepEqual(e.part.p,this._p,"DSA key prime does not match"),r.deepEqual(e.part.g,this._g,"DSA key generator does not match"))},m.prototype.setKey=function(e){if(this._keyCheck(e),"dsa"===e.type)this._dh.setPrivateKey(e.part.x.data),this._dh.setPublicKey(e.part.y.data);else if("ecdsa"===e.type)h?(this._dh.setPrivateKey(e.part.d.data),this._dh.setPublicKey(e.part.Q.data)):this._priv=new v(this._ecParams,e.part.d.data);else if("curve25519"===e.type){var t=e.part.k;e.part.k||(t=e.part.r),this._priv=t.data,0===this._priv[0]&&(this._priv=this._priv.slice(1)),this._priv=this._priv.slice(0,32)}this._key=e,this._isPriv=!0},m.prototype.setPrivateKey=m.prototype.setKey,m.prototype.computeSecret=function(e){if(this._keyCheck(e,!0),!this._isPriv)throw new Error("DH exchange has not been initialized with a private key yet");var t;if("dsa"===this._algo)return this._dh.computeSecret(e.part.y.data);if("ecdsa"===this._algo)return h?this._dh.computeSecret(e.part.Q.data):(t=new y(this._ecParams,e.part.Q.data),this._priv.deriveSharedSecret(t));if("curve25519"===this._algo){for(t=e.part.A.data;0===t[0]&&t.length>32;)t=t.slice(1);var n=this._priv;r.strictEqual(t.length,32),r.strictEqual(n.length,32);var i=l.box.before(new Uint8Array(t),new Uint8Array(n));return o.from(i)}throw new Error("Invalid algorithm: "+this._algo)},m.prototype.generateKey=function(){var e=[],t,n;if("dsa"===this._algo)return this._dh.generateKeys(),e.push({name:"p",data:this._p.data}),e.push({name:"q",data:this._key.part.q.data}),e.push({name:"g",data:this._g.data}),e.push({name:"y",data:this._dh.getPublicKey()}),e.push({name:"x",data:this._dh.getPrivateKey()}),this._key=new c({type:"dsa",parts:e}),this._isPriv=!0,this._key;if("ecdsa"===this._algo){if(h)return this._dh.generateKeys(),e.push({name:"curve",data:o.from(this._curve)}),e.push({name:"Q",data:this._dh.getPublicKey()}),e.push({name:"d",data:this._dh.getPrivateKey()}),this._key=new c({type:"ecdsa",curve:this._curve,parts:e}),this._isPriv=!0,this._key;var s=this._ecParams.getN(),a=new d(i.randomBytes(s.bitLength())),u=s.subtract(d.ONE);return t=a.mod(u).add(d.ONE),n=this._ecParams.getG().multiply(t),t=o.from(t.toByteArray()),n=o.from(this._ecParams.getCurve().encodePointHex(n),"hex"),this._priv=new v(this._ecParams,t),e.push({name:"curve",data:o.from(this._curve)}),e.push({name:"Q",data:n}),e.push({name:"d",data:t}),this._key=new c({type:"ecdsa",curve:this._curve,parts:e}),this._isPriv=!0,this._key}if("curve25519"===this._algo){var f=l.box.keyPair();return t=o.from(f.secretKey),n=o.from(f.publicKey),t=o.concat([t,n]),r.strictEqual(t.length,64),r.strictEqual(n.length,32),e.push({name:"A",data:n}),e.push({name:"k",data:t}),this._key=new c({type:"curve25519",parts:e}),this._isPriv=!0,this._key}throw new Error("Invalid algorithm: "+this._algo)},m.prototype.generateKeys=m.prototype.generateKey,g.prototype.getCurve=function(){return this.curve},g.prototype.getG=function(){return this.g},g.prototype.getN=function(){return this.n},g.prototype.getH=function(){return this.h},v.prototype.deriveSharedSecret=function(e){r.ok(e instanceof y);var t=e._pub.multiply(this._priv);return o.from(t.getX().toBigInteger().toByteArray())}},function(e,t,n){e.exports={read:p,readPkcs1:g,write:d,writePkcs1:S};var r=n(25),i=n(84),o=n(29).Buffer,s=n(48),a=n(42),l=n(41),u=n(46),c=n(92),h=n(176),f=h.readECDSACurve;function p(e,t){return c.read(e,t,"pkcs1")}function d(e,t){return c.write(e,t,"pkcs1")}function m(e,t){return r.strictEqual(e.peek(),i.Ber.Integer,t+" is not an Integer"),a.mpNormalize(e.readString(i.Ber.Integer,!0))}function g(e,t,n){switch(e){case"RSA":if("public"===t)return y(n);if("private"===t)return v(n);throw new Error("Unknown key type: "+t);case"DSA":if("public"===t)return w(n);if("private"===t)return b(n);throw new Error("Unknown key type: "+t);case"EC":case"ECDSA":if("private"===t)return E(n);if("public"===t)return k(n);throw new Error("Unknown key type: "+t);case"EDDSA":case"EdDSA":if("private"===t)return _(n);throw new Error(t+" keys not supported with EdDSA");default:throw new Error("Unknown key algo: "+e)}}function y(e){var t=m(e,"modulus"),n=m(e,"exponent"),r={type:"rsa",parts:[{name:"e",data:n},{name:"n",data:t}]};return new l(r)}function v(e){var t=m(e,"version");r.strictEqual(t[0],0);var n=m(e,"modulus"),i=m(e,"public exponent"),o=m(e,"private exponent"),s=m(e,"prime1"),a=m(e,"prime2"),l=m(e,"exponent1"),c=m(e,"exponent2"),h=m(e,"iqmp"),f={type:"rsa",parts:[{name:"n",data:n},{name:"e",data:i},{name:"d",data:o},{name:"iqmp",data:h},{name:"p",data:s},{name:"q",data:a},{name:"dmodp",data:l},{name:"dmodq",data:c}]};return new u(f)}function b(e){var t=m(e,"version");r.strictEqual(t.readUInt8(0),0);var n=m(e,"p"),i=m(e,"q"),o=m(e,"g"),s=m(e,"y"),a=m(e,"x"),l={type:"dsa",parts:[{name:"p",data:n},{name:"q",data:i},{name:"g",data:o},{name:"y",data:s},{name:"x",data:a}]};return new u(l)}function _(e){var t=m(e,"version");r.strictEqual(t.readUInt8(0),1);var n=e.readString(i.Ber.OctetString,!0);e.readSequence(160);var o=e.readOID();r.strictEqual(o,"1.3.101.112","the ed25519 curve identifier"),e.readSequence(161);var s=a.readBitString(e),l={type:"ed25519",parts:[{name:"A",data:a.zeroPadToLength(s,32)},{name:"k",data:n}]};return new u(l)}function w(e){var t=m(e,"y"),n=m(e,"p"),r=m(e,"q"),i=m(e,"g"),o={type:"dsa",parts:[{name:"y",data:t},{name:"p",data:n},{name:"q",data:r},{name:"g",data:i}]};return new l(o)}function k(e){e.readSequence();var t=e.readOID();r.strictEqual(t,"1.2.840.10045.2.1","must be ecPublicKey");for(var n=e.readOID(),u,c=Object.keys(s.curves),h=0;h<c.length;++h){var f=c[h],p=s.curves[f];if(p.pkcs8oid===n){u=f;break}}r.string(u,"a known ECDSA named curve");var d=e.readString(i.Ber.BitString,!0);d=a.ecNormalize(d);var m={type:"ecdsa",parts:[{name:"curve",data:o.from(u)},{name:"Q",data:d}]};return new l(m)}function E(e){var t=m(e,"version");r.strictEqual(t.readUInt8(0),1);var n=e.readString(i.Ber.OctetString,!0);e.readSequence(160);var s=f(e);r.string(s,"a known elliptic curve"),e.readSequence(161);var l=e.readString(i.Ber.BitString,!0);l=a.ecNormalize(l);var c={type:"ecdsa",parts:[{name:"curve",data:o.from(s)},{name:"Q",data:l},{name:"d",data:n}]};return new u(c)}function S(e,t){switch(e.startSequence(),t.type){case"rsa":u.isPrivateKey(t)?C(e,t):x(e,t);break;case"dsa":u.isPrivateKey(t)?A(e,t):T(e,t);break;case"ecdsa":u.isPrivateKey(t)?j(e,t):I(e,t);break;case"ed25519":u.isPrivateKey(t)?R(e,t):B(e,t);break;default:throw new Error("Unknown key algo: "+t.type)}e.endSequence()}function x(e,t){e.writeBuffer(t.part.n.data,i.Ber.Integer),e.writeBuffer(t.part.e.data,i.Ber.Integer)}function C(e,t){var n=o.from([0]);e.writeBuffer(n,i.Ber.Integer),e.writeBuffer(t.part.n.data,i.Ber.Integer),e.writeBuffer(t.part.e.data,i.Ber.Integer),e.writeBuffer(t.part.d.data,i.Ber.Integer),e.writeBuffer(t.part.p.data,i.Ber.Integer),e.writeBuffer(t.part.q.data,i.Ber.Integer),t.part.dmodp&&t.part.dmodq||a.addRSAMissing(t),e.writeBuffer(t.part.dmodp.data,i.Ber.Integer),e.writeBuffer(t.part.dmodq.data,i.Ber.Integer),e.writeBuffer(t.part.iqmp.data,i.Ber.Integer)}function A(e,t){var n=o.from([0]);e.writeBuffer(n,i.Ber.Integer),e.writeBuffer(t.part.p.data,i.Ber.Integer),e.writeBuffer(t.part.q.data,i.Ber.Integer),e.writeBuffer(t.part.g.data,i.Ber.Integer),e.writeBuffer(t.part.y.data,i.Ber.Integer),e.writeBuffer(t.part.x.data,i.Ber.Integer)}function T(e,t){e.writeBuffer(t.part.y.data,i.Ber.Integer),e.writeBuffer(t.part.p.data,i.Ber.Integer),e.writeBuffer(t.part.q.data,i.Ber.Integer),e.writeBuffer(t.part.g.data,i.Ber.Integer)}function I(e,t){e.startSequence(),e.writeOID("1.2.840.10045.2.1");var n=t.part.curve.data.toString(),o=s.curves[n].pkcs8oid;r.string(o,"a known ECDSA named curve"),e.writeOID(o),e.endSequence();var l=a.ecNormalize(t.part.Q.data,!0);e.writeBuffer(l,i.Ber.BitString)}function j(e,t){var n=o.from([1]);e.writeBuffer(n,i.Ber.Integer),e.writeBuffer(t.part.d.data,i.Ber.OctetString),e.startSequence(160);var l=t.part.curve.data.toString(),u=s.curves[l].pkcs8oid;r.string(u,"a known ECDSA named curve"),e.writeOID(u),e.endSequence(),e.startSequence(161);var c=a.ecNormalize(t.part.Q.data,!0);e.writeBuffer(c,i.Ber.BitString),e.endSequence()}function R(e,t){var n=o.from([1]);e.writeBuffer(n,i.Ber.Integer),e.writeBuffer(t.part.k.data,i.Ber.OctetString),e.startSequence(160),e.writeOID("1.3.101.112"),e.endSequence(),e.startSequence(161),a.writeBitString(e,t.part.A.data),e.endSequence()}function B(e,t){throw new Error("Public keys are not supported for EdDSA PKCS#1")}},function(e,t,n){e.exports={read:f,write:w};var r=n(25),i=n(29).Buffer,o=n(41),s=n(46),a=n(42),l=n(175),u=n(317),c={"rsa-sha1":5,"rsa-sha256":8,"rsa-sha512":10,"ecdsa-p256-sha256":13,"ecdsa-p384-sha384":14},h={};function f(e,t){"string"!=typeof e&&(r.buffer(e,"buf"),e=e.toString("ascii"));var n=e.split("\n");if(n[0].match(/^Private-key-format\: v1/)){var i=n[1].split(" "),o=parseInt(i[1],10),s=i[2];if(!h[o])throw new Error("Unsupported algorithm: "+s);return g(o,n.slice(2))}for(var a=0;n[a].match(/^\;/);)a++;if((n[a].match(/\. IN KEY /)||n[a].match(/\. IN DNSKEY /))&&0===n[a+1].length)return p(n[a]);throw new Error("Cannot parse dnssec key")}function p(e){var t=e.split(" "),n=parseInt(t[5],10);if(!h[n])throw new Error("Unsupported algorithm: "+n);var r=t.slice(6,t.length).join(),s=i.from(r,"base64");if(h[n].match(/^RSA-/)){var l=s.readUInt8(0);if(3!=l&&1!=l)throw new Error("Cannot parse dnssec key: unsupported exponent length");var u=s.slice(1,l+1);u=a.mpNormalize(u);var c=s.slice(1+l);c=a.mpNormalize(c);var f={type:"rsa",parts:[]};return f.parts.push({name:"e",data:u}),f.parts.push({name:"n",data:c}),new o(f)}if("ECDSA-P384-SHA384"===h[n]||"ECDSA-P256-SHA256"===h[n]){var p="nistp384",d=384;h[n].match(/^ECDSA-P256-SHA256/)&&(p="nistp256",d=256);var m={type:"ecdsa",curve:p,size:d,parts:[{name:"curve",data:i.from(p)},{name:"Q",data:a.ecNormalize(s)}]};return new o(m)}throw new Error("Unsupported algorithm: "+h[n])}function d(e){return i.from(e.split(" ")[1],"base64")}function m(e){var t={};e.forEach(function(e){"Modulus:"===e.split(" ")[0]?t.n=d(e):"PublicExponent:"===e.split(" ")[0]?t.e=d(e):"PrivateExponent:"===e.split(" ")[0]?t.d=d(e):"Prime1:"===e.split(" ")[0]?t.p=d(e):"Prime2:"===e.split(" ")[0]?t.q=d(e):"Exponent1:"===e.split(" ")[0]?t.dmodp=d(e):"Exponent2:"===e.split(" ")[0]?t.dmodq=d(e):"Coefficient:"===e.split(" ")[0]&&(t.iqmp=d(e))});var n={type:"rsa",parts:[{name:"e",data:a.mpNormalize(t.e)},{name:"n",data:a.mpNormalize(t.n)},{name:"d",data:a.mpNormalize(t.d)},{name:"p",data:a.mpNormalize(t.p)},{name:"q",data:a.mpNormalize(t.q)},{name:"dmodp",data:a.mpNormalize(t.dmodp)},{name:"dmodq",data:a.mpNormalize(t.dmodq)},{name:"iqmp",data:a.mpNormalize(t.iqmp)}]};return new s(n)}function g(e,t){if(h[e].match(/^RSA-/))return m(t);if("ECDSA-P384-SHA384"===h[e]||"ECDSA-P256-SHA256"===h[e]){var n=i.from(t[0].split(" ")[1],"base64"),r="nistp384",o=384;"ECDSA-P256-SHA256"===h[e]&&(r="nistp256",o=256);var l=a.publicFromPrivateECDSA(r,n),u=l.part.Q.data,c={type:"ecdsa",curve:r,size:o,parts:[{name:"curve",data:i.from(r)},{name:"d",data:n},{name:"Q",data:u}]};return new s(c)}throw new Error("Unsupported algorithm: "+h[e])}function y(e){var t=e.getFullYear()+"",n=e.getMonth()+1,r=t+n+e.getUTCDate();return r+=""+e.getUTCHours()+e.getUTCMinutes(),r+=e.getUTCSeconds(),r}function v(e){if(e&&e.hashAlgo&&"sha1"!==e.hashAlgo){if("sha256"===e.hashAlgo)return"8 (RSASHA256)";if("sha512"===e.hashAlgo)return"10 (RSASHA512)";throw new Error("Unknown or unsupported hash: "+e.hashAlgo)}return"5 (RSASHA1)"}function b(e,t){e.part.dmodp&&e.part.dmodq||a.addRSAMissing(e);var n="";n+="Private-key-format: v1.3\n",n+="Algorithm: "+v(t)+"\n";var r=a.mpDenormalize(e.part.n.data);n+="Modulus: "+r.toString("base64")+"\n";var o=a.mpDenormalize(e.part.e.data);n+="PublicExponent: "+o.toString("base64")+"\n";var s=a.mpDenormalize(e.part.d.data);n+="PrivateExponent: "+s.toString("base64")+"\n";var l=a.mpDenormalize(e.part.p.data);n+="Prime1: "+l.toString("base64")+"\n";var u=a.mpDenormalize(e.part.q.data);n+="Prime2: "+u.toString("base64")+"\n";var c=a.mpDenormalize(e.part.dmodp.data);n+="Exponent1: "+c.toString("base64")+"\n";var h=a.mpDenormalize(e.part.dmodq.data);n+="Exponent2: "+h.toString("base64")+"\n";var f=a.mpDenormalize(e.part.iqmp.data);n+="Coefficient: "+f.toString("base64")+"\n";var p=new Date;return n+="Created: "+y(p)+"\n",n+="Publish: "+y(p)+"\n",n+="Activate: "+y(p)+"\n",i.from(n,"ascii")}function _(e,t){var n="";if(n+="Private-key-format: v1.3\n","nistp256"===e.curve)n+="Algorithm: 13 (ECDSAP256SHA256)\n";else{if("nistp384"!==e.curve)throw new Error("Unsupported curve");n+="Algorithm: 14 (ECDSAP384SHA384)\n"}var r=e.part.d.data.toString("base64");n+="PrivateKey: "+r+"\n";var o=new Date;return n+="Created: "+y(o)+"\n",n+="Publish: "+y(o)+"\n",n+="Activate: "+y(o)+"\n",i.from(n,"ascii")}function w(e,t){if(s.isPrivateKey(e)){if("rsa"===e.type)return b(e,t);if("ecdsa"===e.type)return _(e,t);throw new Error("Unsupported algorithm: "+e.type)}throw o.isKey(e)?new Error('Format "dnssec" only supports writing private keys'):new Error("key is not a Key or PrivateKey")}Object.keys(c).forEach(function(e){h[c[e]]=e.toUpperCase()})},function(e,t){function n(e){this.dict=e||{}}n.prototype.set=function(e,t,n){if("object"!=typeof e){void 0===n&&(n=!0);var r=this.has(e);return!n&&r?this.dict[r]=this.dict[r]+","+t:this.dict[r||e]=t,r}for(var i in e)this.set(i,e[i],t)},n.prototype.has=function(e){for(var t=Object.keys(this.dict),e=e.toLowerCase(),n=0;n<t.length;n++)if(t[n].toLowerCase()===e)return t[n];return!1},n.prototype.get=function(e){var t,n;e=e.toLowerCase();var r=this.dict;return Object.keys(r).forEach(function(i){n=i.toLowerCase(),e===n&&(t=r[i])}),t},n.prototype.swap=function(e){var t=this.has(e);if(t!==e){if(!t)throw new Error('There is no header than matches "'+e+'"');this.dict[e]=this.dict[t],delete this.dict[t]}},n.prototype.del=function(e){var t=this.has(e);return delete this.dict[t||e]},e.exports=function(e){return new n(e)},e.exports.httpify=function(e,t){var r=new n(t);return e.setHeader=function(e,t,n){if(void 0!==t)return r.set(e,t,n)},e.hasHeader=function(e){return r.has(e)},e.getHeader=function(e){return r.get(e)},e.removeHeader=function(e){return r.del(e)},e.headers=r.dict,r}},function(e,t,n){"use strict";var r=n(1680),i=n(322),o=n(143),s=n(624),a=n(1682);function l(e,t,n){var r=this._refs[n];if("string"==typeof r){if(!this._refs[r])return l.call(this,e,t,r);r=this._refs[r]}if(r=r||this._schemas[n],r instanceof s)return d(r.schema,this._opts.inlineRefs)?r.schema:r.validate||this._compile(r);var i=u.call(this,t,n),o,a,c;return i&&(o=i.schema,t=i.root,c=i.baseId),o instanceof s?a=o.validate||e.call(this,o.schema,t,void 0,c):void 0!==o&&(a=d(o,this._opts.inlineRefs)?o:e.call(this,o,t,void 0,c)),a}function u(e,t){var n=r.parse(t),i=v(n),o=y(this._getId(e.schema));if(0===Object.keys(e.schema).length||i!==o){var a=_(i),l=this._refs[a];if("string"==typeof l)return c.call(this,e,l,n);if(l instanceof s)l.validate||this._compile(l),e=l;else{if(l=this._schemas[a],!(l instanceof s))return;if(l.validate||this._compile(l),a==_(t))return{schema:l,root:e,baseId:o};e=l}if(!e.schema)return;o=y(this._getId(e.schema))}return f.call(this,n,o,e.schema,e)}function c(e,t,n){var r=u.call(this,e,t);if(r){var i=r.schema,o=r.baseId;e=r.root;var s=this._getId(i);return s&&(o=w(o,s)),f.call(this,n,o,i,e)}}e.exports=l,l.normalizeId=_,l.fullPath=y,l.url=w,l.ids=k,l.inlineRef=d,l.schema=u;var h=o.toHash(["properties","patternProperties","enum","dependencies","definitions"]);function f(e,t,n,r){if(e.fragment=e.fragment||"","/"==e.fragment.slice(0,1)){for(var i=e.fragment.split("/"),s=1;s<i.length;s++){var a=i[s];if(a){if(a=o.unescapeFragment(a),n=n[a],void 0===n)break;var l;if(!h[a]&&(l=this._getId(n),l&&(t=w(t,l)),n.$ref)){var c=w(t,n.$ref),f=u.call(this,r,c);f&&(n=f.schema,r=f.root,t=f.baseId)}}}return void 0!==n&&n!==r.schema?{schema:n,root:r,baseId:t}:void 0}}var p=o.toHash(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum"]);function d(e,t){return!1!==t&&(void 0===t||!0===t?m(e):t?g(e)<=t:void 0)}function m(e){var t;if(Array.isArray(e)){for(var n=0;n<e.length;n++)if(t=e[n],"object"==typeof t&&!m(t))return!1}else for(var r in e){if("$ref"==r)return!1;if(t=e[r],"object"==typeof t&&!m(t))return!1}return!0}function g(e){var t=0,n;if(Array.isArray(e)){for(var r=0;r<e.length;r++)if(n=e[r],"object"==typeof n&&(t+=g(n)),t==1/0)return 1/0}else for(var i in e){if("$ref"==i)return 1/0;if(p[i])t++;else if(n=e[i],"object"==typeof n&&(t+=g(n)+1),t==1/0)return 1/0}return t}function y(e,t){!1!==t&&(e=_(e));var n=r.parse(e);return v(n)}function v(e){return r.serialize(e).split("#")[0]+"#"}var b=/#\/?$/;function _(e){return e?e.replace(b,""):""}function w(e,t){return t=_(t),r.resolve(e,t)}function k(e){var t=_(this._getId(e)),n={"":t},s={"":y(t,!1)},l={},u=this;return a(e,{allKeys:!0},function(e,t,a,c,h,f,p){if(""!==t){var d=u._getId(e),m=n[c],g=s[c]+"/"+h;if(void 0!==p&&(g+="/"+("number"==typeof p?p:o.escapeFragment(p))),"string"==typeof d){d=m=_(m?r.resolve(m,d):d);var y=u._refs[d];if("string"==typeof y&&(y=u._refs[y]),y&&y.schema){if(!i(e,y.schema))throw new Error('id "'+d+'" resolves to more than one schema')}else if(d!=_(g))if("#"==d[0]){if(l[d]&&!i(e,l[d]))throw new Error('id "'+d+'" resolves to more than one schema');l[d]=e}else u._refs[d]=g}n[t]=m,s[t]=g}}),l}},function(e,t,n){"use strict";var r=Array.isArray,i=Object.keys,o=Object.prototype.hasOwnProperty;e.exports=function e(t,n){if(t===n)return!0;if(t&&n&&"object"==typeof t&&"object"==typeof n){var s=r(t),a=r(n),l,u,c;if(s&&a){if(u=t.length,u!=n.length)return!1;for(l=u;0!=l--;)if(!e(t[l],n[l]))return!1;return!0}if(s!=a)return!1;var h=t instanceof Date,f=n instanceof Date;if(h!=f)return!1;if(h&&f)return t.getTime()==n.getTime();var p=t instanceof RegExp,d=n instanceof RegExp;if(p!=d)return!1;if(p&&d)return t.toString()==n.toString();var m=i(t);if(u=m.length,u!==i(n).length)return!1;for(l=u;0!=l--;)if(!o.call(n,m[l]))return!1;for(l=u;0!=l--;)if(c=m[l],!e(t[c],n[c]))return!1;return!0}return t!=t&&n!=n}},function(e,t,n){"use strict";var r=n(321);function i(e){this.message="validation failed",this.errors=e,this.ajv=this.validation=!0}function o(e,t,n){this.message=n||o.message(e,t),this.missingRef=r.url(e,t),this.missingSchema=r.normalizeId(r.fullPath(this.missingRef))}function s(e){return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}e.exports={Validation:s(i),MissingRef:s(o)},o.message=function(e,t){return"can't resolve reference "+t+" from id "+e}},function(e,t){class n extends Error{constructor(e){super(),this.message=`${e} is not a supported algorithm`}}e.exports=n},function(e,t){t.read=function(e,t,n,r,i){var o,s,a=8*i-r-1,l=(1<<a)-1,u=l>>1,c=-7,h=n?i-1:0,f=n?-1:1,p=e[t+h];for(h+=f,o=p&(1<<-c)-1,p>>=-c,c+=a;c>0;o=256*o+e[t+h],h+=f,c-=8);for(s=o&(1<<-c)-1,o>>=-c,c+=r;c>0;s=256*s+e[t+h],h+=f,c-=8);if(0===o)o=1-u;else{if(o===l)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,r),o-=u}return(p?-1:1)*s*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var s,a,l,u=8*o-i-1,c=(1<<u)-1,h=c>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:o-1,d=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,s=c):(s=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-s))<1&&(s--,l*=2),t+=s+h>=1?f/l:f*Math.pow(2,1-h),t*l>=2&&(s++,l/=2),s+h>=c?(a=0,s=c):s+h>=1?(a=(t*l-1)*Math.pow(2,i),s+=h):(a=t*Math.pow(2,h-1)*Math.pow(2,i),s=0));i>=8;e[n+p]=255&a,p+=d,a/=256,i-=8);for(s=s<<i|a,u+=i;u>0;e[n+p]=255&s,p+=d,s/=256,u-=8);e[n+p-d]|=128*m}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(){var t=(0,i.default)(arguments),n=t.pop();e.call(this,t,n)}};var r=n(86),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}e.exports=t.default},function(e,t,n){(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.exports=n}).call(this,n(8))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(244),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t,n,r){(0,i.default)(t)(e,(0,s.default)(n),r)}e.exports=t.default},function(e,t,n){var r=n(659),i=n(87),o=Object.prototype,s=o.hasOwnProperty,a=o.propertyIsEnumerable,l=r(function(){return arguments}())?r:function(e){return i(e)&&s.call(e,"callee")&&!a.call(e,"callee")};e.exports=l},function(e,t,n){(function(e){var r=n(79),i=n(660),o=t&&!t.nodeType&&t,s=o&&"object"==typeof e&&e&&!e.nodeType&&e,a=s&&s.exports===o,l=a?r.Buffer:void 0,u=l?l.isBuffer:void 0,c=u||i;e.exports=c}).call(this,n(85)(e))},function(e,t){var n=9007199254740991,r=/^(?:0|[1-9]\d*)$/;function i(e,t){var i=typeof e;return t=null==t?n:t,!!t&&("number"==i||"symbol"!=i&&r.test(e))&&e>-1&&e%1==0&&e<t}e.exports=i},function(e,t,n){var r=n(661),i=n(662),o=n(663),s=o&&o.isTypedArray,a=s?i(s):r;e.exports=a},function(e,t,n){"use strict";function r(e){return function(t,n,r){return e(t,r)}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(58),i=a(r),o=n(37),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t,n,r){r=r||i.default,t=t||[];var o=[],a=0,l=(0,s.default)(n);e(t,function(e,t,n){var r=a++;l(e,function(e,t){o[r]=t,n(e)})},function(e){r(e,o)})}e.exports=t.default},function(e,t,n){"use strict";(function(t,r){var i;e.exports=j,j.ReadableState=I;var o=n(6).EventEmitter,s=function e(t,n){return t.listeners(n).length},a=n(336),l=n(0).Buffer,u=t.Uint8Array||function(){};function c(e){return l.from(e)}function h(e){return l.isBuffer(e)||e instanceof u}var f=n(669),p;p=f&&f.debuglog?f.debuglog("stream"):function e(){};var d=n(670),m=n(337),g=n(338),y=g.getHighWaterMark,v=n(112).codes,b=v.ERR_INVALID_ARG_TYPE,_=v.ERR_STREAM_PUSH_AFTER_EOF,w=v.ERR_METHOD_NOT_IMPLEMENTED,k=v.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,E=n(672),S=E.emitExperimentalWarning,x,C;n(1)(j,a);var A=["error","close","destroy","pause","resume"];function T(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function I(e,t,r){i=i||n(113),e=e||{},"boolean"!=typeof r&&(r=t instanceof i),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode),this.highWaterMark=y(this,e,"readableHighWaterMark",r),this.buffer=new d,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==e.emitClose,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(x||(x=n(18).StringDecoder),this.decoder=new x(e.encoding),this.encoding=e.encoding)}function j(e){if(i=i||n(113),!(this instanceof j))return new j(e);var t=this instanceof i;this._readableState=new I(e,this,t),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),a.call(this)}function R(e,t,n,r,i){p("readableAddChunk",t);var o=e._readableState,s;if(null===t)o.reading=!1,M(e,o);else if(i||(s=O(o,t)),s)e.emit("error",s);else if(o.objectMode||t&&t.length>0)if("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===l.prototype||(t=c(t)),r)o.endEmitted?e.emit("error",new k):B(e,o,t,!0);else if(o.ended)e.emit("error",new _);else{if(o.destroyed)return!1;o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?B(e,o,t,!1):U(e,o)):B(e,o,t,!1)}else r||(o.reading=!1,U(e,o));return!o.ended&&(o.length<o.highWaterMark||0===o.length)}function B(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(t.awaitDrain=0,e.emit("data",n)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&F(e)),U(e,t)}function O(e,t){var n;return h(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new b("chunk",["string","Buffer","Uint8Array"],t)),n}Object.defineProperty(j.prototype,"destroyed",{enumerable:!1,get:function e(){return void 0!==this._readableState&&this._readableState.destroyed},set:function e(t){this._readableState&&(this._readableState.destroyed=t)}}),j.prototype.destroy=m.destroy,j.prototype._undestroy=m.undestroy,j.prototype._destroy=function(e,t){t(e)},j.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=l.from(e,t),t=""),r=!0),R(this,e,t,!1,r)},j.prototype.unshift=function(e){return R(this,e,null,!0,!1)},j.prototype.isPaused=function(){return!1===this._readableState.flowing},j.prototype.setEncoding=function(e){return x||(x=n(18).StringDecoder),this._readableState.decoder=new x(e),this._readableState.encoding=this._readableState.decoder.encoding,this};var P=8388608;function N(e){return e>=P?e=P:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function D(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=N(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function M(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,t.sync?F(e):(t.needReadable=!1,t.emittedReadable||(t.emittedReadable=!0,L(e)))}}function F(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(p("emitReadable",t.flowing),t.emittedReadable=!0,r.nextTick(L,e))}function L(e){var t=e._readableState;p("emitReadable_",t.destroyed,t.length,t.ended),t.destroyed||!t.length&&!t.ended||e.emit("readable"),t.needReadable=!t.flowing&&!t.ended&&t.length<=t.highWaterMark,W(e)}function U(e,t){t.readingMore||(t.readingMore=!0,r.nextTick(q,e,t))}function q(e,t){for(;!t.reading&&!t.ended&&(t.length<t.highWaterMark||t.flowing&&0===t.length);){var n=t.length;if(p("maybeReadMore read 0"),e.read(0),n===t.length)break}t.readingMore=!1}function z(e){return function t(){var n=e._readableState;p("pipeOnDrain",n.awaitDrain),n.awaitDrain&&n.awaitDrain--,0===n.awaitDrain&&s(e,"data")&&(n.flowing=!0,W(e))}}function K(e){var t=e._readableState;t.readableListening=e.listenerCount("readable")>0,t.resumeScheduled&&!t.paused?t.flowing=!0:e.listenerCount("data")>0&&e.resume()}function H(e){p("readable nexttick read 0"),e.read(0)}function V(e,t){t.resumeScheduled||(t.resumeScheduled=!0,r.nextTick($,e,t))}function $(e,t){p("resume",t.reading),t.reading||e.read(0),t.resumeScheduled=!1,e.emit("resume"),W(e),t.flowing&&!t.reading&&e.read(0)}function W(e){var t=e._readableState;for(p("flow",t.flowing);t.flowing&&null!==e.read(););}function G(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.first():t.buffer.concat(t.length),t.buffer.clear()):n=t.buffer.consume(e,t.decoder),n);var n}function Y(e){var t=e._readableState;p("endReadable",t.endEmitted),t.endEmitted||(t.ended=!0,r.nextTick(Z,t,e))}function Z(e,t){p("endReadableNT",e.endEmitted,e.length),e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function J(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}j.prototype.read=function(e){p("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&((0!==t.highWaterMark?t.length>=t.highWaterMark:t.length>0)||t.ended))return p("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?Y(this):F(this),null;if(e=D(e,t),0===e&&t.ended)return 0===t.length&&Y(this),null;var r=t.needReadable,i;return p("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,p("length less than watermark",r)),t.ended||t.reading?(r=!1,p("reading or ended",r)):r&&(p("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=D(n,t))),i=e>0?G(e,t):null,null===i?(t.needReadable=!0,e=0):(t.length-=e,t.awaitDrain=0),0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&Y(this)),null!==i&&this.emit("data",i),i},j.prototype._read=function(e){this.emit("error",new w("_read()"))},j.prototype.pipe=function(e,t){var n=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=e;break;case 1:i.pipes=[i.pipes,e];break;default:i.pipes.push(e)}i.pipesCount+=1,p("pipe count=%d opts=%j",i.pipesCount,t);var o=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=o?u:v;function l(e,t){p("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,f())}function u(){p("onend"),e.end()}i.endEmitted?r.nextTick(a):n.once("end",a),e.on("unpipe",l);var c=z(n);e.on("drain",c);var h=!1;function f(){p("cleanup"),e.removeListener("close",g),e.removeListener("finish",y),e.removeListener("drain",c),e.removeListener("error",m),e.removeListener("unpipe",l),n.removeListener("end",u),n.removeListener("end",v),n.removeListener("data",d),h=!0,!i.awaitDrain||e._writableState&&!e._writableState.needDrain||c()}function d(t){p("ondata");var r=e.write(t);p("dest.write",r),!1===r&&((1===i.pipesCount&&i.pipes===e||i.pipesCount>1&&-1!==J(i.pipes,e))&&!h&&(p("false write response, pause",i.awaitDrain),i.awaitDrain++),n.pause())}function m(t){p("onerror",t),v(),e.removeListener("error",m),0===s(e,"error")&&e.emit("error",t)}function g(){e.removeListener("finish",y),v()}function y(){p("onfinish"),e.removeListener("close",g),v()}function v(){p("unpipe"),n.unpipe(e)}return n.on("data",d),T(e,"error",m),e.once("close",g),e.once("finish",y),e.emit("pipe",n),i.flowing||(p("pipe resume"),n.resume()),e},j.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,{hasUnpiped:!1});return this}var s=J(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},j.prototype.on=function(e,t){var n=a.prototype.on.call(this,e,t),i=this._readableState;return"data"===e?(i.readableListening=this.listenerCount("readable")>0,!1!==i.flowing&&this.resume()):"readable"===e&&(i.endEmitted||i.readableListening||(i.readableListening=i.needReadable=!0,i.flowing=!1,i.emittedReadable=!1,p("on readable",i.length,i.reading),i.length?F(this):i.reading||r.nextTick(H,this))),n},j.prototype.addListener=j.prototype.on,j.prototype.removeListener=function(e,t){var n=a.prototype.removeListener.call(this,e,t);return"readable"===e&&r.nextTick(K,this),n},j.prototype.removeAllListeners=function(e){var t=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==e&&void 0!==e||r.nextTick(K,this),t},j.prototype.resume=function(){var e=this._readableState;return e.flowing||(p("resume"),e.flowing=!e.readableListening,V(this,e)),e.paused=!1,this},j.prototype.pause=function(){return p("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(p("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},j.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(p("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(p("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function t(n){return function t(){return e[n].apply(e,arguments)}}(i));for(var o=0;o<A.length;o++)e.on(A[o],this.emit.bind(this,A[o]));return this._read=function(t){p("wrapped _read",t),r&&(r=!1,e.resume())},this},"function"==typeof Symbol&&(j.prototype[Symbol.asyncIterator]=function(){return S("Readable[Symbol.asyncIterator]"),void 0===C&&(C=n(673)),C(this)}),Object.defineProperty(j.prototype,"readableHighWaterMark",{enumerable:!1,get:function e(){return this._readableState.highWaterMark}}),Object.defineProperty(j.prototype,"readableBuffer",{enumerable:!1,get:function e(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(j.prototype,"readableFlowing",{enumerable:!1,get:function e(){return this._readableState.flowing},set:function e(t){this._readableState&&(this._readableState.flowing=t)}}),j._fromList=G,Object.defineProperty(j.prototype,"readableLength",{enumerable:!1,get:function e(){return this._readableState.length}})}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";(function(t){function n(e,n){var o=this,a=this._readableState&&this._readableState.destroyed,l=this._writableState&&this._writableState.destroyed;return a||l?(n?n(e):!e||this._writableState&&this._writableState.errorEmitted||t.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!n&&e?(t.nextTick(r,o,e),o._writableState&&(o._writableState.errorEmitted=!0)):n?(t.nextTick(i,o),n(e)):t.nextTick(i,o)}),this)}function r(e,t){s(e,t),i(e)}function i(e){e._writableState&&!e._writableState.emitClose||e._readableState&&!e._readableState.emitClose||e.emit("close")}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:n,undestroy:o}}).call(this,n(3))},function(e,t,n){"use strict";var r=n(112).codes.ERR_INVALID_OPT_VALUE;function i(e,t,n){return null!=e.highWaterMark?e.highWaterMark:t?e[n]:null}function o(e,t,n,o){var s=i(t,o,n);if(null!=s){if(!isFinite(s)||Math.floor(s)!==s||s<0){var a=o?n:"highWaterMark";throw new r(a,s)}return Math.floor(s)}return e.objectMode?16:16384}e.exports={getHighWaterMark:o}},function(e,t,n){"use strict";(function(t,r){function i(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function o(e){var t=this;this.next=null,this.entry=null,this.finish=function(){V(t,e)}}var s;e.exports=T,T.WritableState=A;var a={deprecate:n(50)},l=n(336),u=n(0).Buffer,c=t.Uint8Array||function(){};function h(e){return u.from(e)}function f(e){return u.isBuffer(e)||e instanceof c}var p=n(337),d=n(338),m=d.getHighWaterMark,g=n(112).codes,y=g.ERR_INVALID_ARG_TYPE,v=g.ERR_METHOD_NOT_IMPLEMENTED,b=g.ERR_MULTIPLE_CALLBACK,_=g.ERR_STREAM_CANNOT_PIPE,w=g.ERR_STREAM_DESTROYED,k=g.ERR_STREAM_NULL_VALUES,E=g.ERR_STREAM_WRITE_AFTER_END,S=g.ERR_UNKNOWN_ENCODING,x;function C(){}function A(e,t,r){s=s||n(113),e=e||{},"boolean"!=typeof r&&(r=t instanceof s),this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode),this.highWaterMark=m(this,e,"writableHighWaterMark",r),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var i=!1===e.decodeStrings;this.decodeStrings=!i,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){D(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!1!==e.emitClose,this.bufferedRequestCount=0,this.corkedRequestsFree=new o(this)}function T(e){s=s||n(113);var t=this instanceof s;if(!t&&!x.call(T,this))return new T(e);this._writableState=new A(e,this,t),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),l.call(this)}function I(e,t){var n=new E;e.emit("error",n),r.nextTick(t,n)}function j(e,t,n,i){var o;return null===n?o=new k:"string"==typeof n||t.objectMode||(o=new y("chunk",["string","Buffer"],n)),!o||(e.emit("error",o),r.nextTick(i,o),!1)}function R(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=u.from(t,n)),t}function B(e,t,n,r,i,o){if(!n){var s=R(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else O(e,t,!1,a,r,i,o);return l}function O(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,t.destroyed?t.onwrite(new w("write")):n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function P(e,t,n,i,o){--t.pendingcb,n?(r.nextTick(o,i),r.nextTick(K,e,t),e._writableState.errorEmitted=!0,e.emit("error",i)):(o(i),e._writableState.errorEmitted=!0,e.emit("error",i),K(e,t))}function N(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function D(e,t){var n=e._writableState,i=n.sync,o=n.writecb;if("function"!=typeof o)throw new b;if(N(n),t)P(e,n,i,t,o);else{var s=U(n)||e.destroyed;s||n.corked||n.bufferProcessing||!n.bufferedRequest||L(e,n),i?r.nextTick(M,e,n,s,o):M(e,n,s,o)}}function M(e,t,n,r){n||F(e,t),t.pendingcb--,r(),K(e,t)}function F(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function L(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),s=t.corkedRequestsFree;s.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,O(e,t,!0,t.length,i,"",s.finish),t.pendingcb++,t.lastBufferedRequest=null,s.next?(t.corkedRequestsFree=s.next,s.next=null):t.corkedRequestsFree=new o(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(O(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function U(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function q(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),K(e,t)})}function z(e,t){t.prefinished||t.finalCalled||("function"!=typeof e._final||t.destroyed?(t.prefinished=!0,e.emit("prefinish")):(t.pendingcb++,t.finalCalled=!0,r.nextTick(q,e,t)))}function K(e,t){var n=U(t);return n&&(z(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function H(e,t,n){t.ending=!0,K(e,t),n&&(t.finished?r.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function V(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree.next=e}n(1)(T,l),A.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(A.prototype,"buffer",{get:a.deprecate(function e(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(x=Function.prototype[Symbol.hasInstance],Object.defineProperty(T,Symbol.hasInstance,{value:function e(t){return!!x.call(this,t)||this===T&&(t&&t._writableState instanceof A)}})):x=function e(t){return t instanceof this},T.prototype.pipe=function(){this.emit("error",new _)},T.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&f(e);return o&&!u.isBuffer(e)&&(e=h(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=C),r.ending?I(this,n):(o||j(this,r,e,n))&&(r.pendingcb++,i=B(this,r,o,e,t,n)),i},T.prototype.cork=function(){this._writableState.corked++},T.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.bufferProcessing||!e.bufferedRequest||L(this,e))},T.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new S(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(T.prototype,"writableBuffer",{enumerable:!1,get:function e(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(T.prototype,"writableHighWaterMark",{enumerable:!1,get:function e(){return this._writableState.highWaterMark}}),T.prototype._write=function(e,t,n){n(new v("_write()"))},T.prototype._writev=null,T.prototype.end=function(e,t,n){var r=this._writableState;return"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||H(this,r,n),this},Object.defineProperty(T.prototype,"writableLength",{enumerable:!1,get:function e(){return this._writableState.length}}),Object.defineProperty(T.prototype,"destroyed",{enumerable:!1,get:function e(){return void 0!==this._writableState&&this._writableState.destroyed},set:function e(t){this._writableState&&(this._writableState.destroyed=t)}}),T.prototype.destroy=p.destroy,T.prototype._undestroy=p.undestroy,T.prototype._destroy=function(e,t){t(e)}}).call(this,n(8),n(3))},function(e,t,n){"use strict";e.exports=c;var r=n(112).codes,i=r.ERR_METHOD_NOT_IMPLEMENTED,o=r.ERR_MULTIPLE_CALLBACK,s=r.ERR_TRANSFORM_ALREADY_TRANSFORMING,a=r.ERR_TRANSFORM_WITH_LENGTH_0,l=n(113);function u(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(null===r)return this.emit("error",new o);n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function c(e){if(!(this instanceof c))return new c(e);l.call(this,e),this._transformState={afterTransform:u.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",h)}function h(){var e=this;"function"!=typeof this._flush||this._readableState.destroyed?f(this,null,null):this._flush(function(t,n){f(e,t,n)})}function f(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new a;if(e._transformState.transforming)throw new s;return e.push(null)}n(1)(c,l),c.prototype.push=function(e,t){return this._transformState.needTransform=!1,l.prototype.push.call(this,e,t)},c.prototype._transform=function(e,t,n){n(new i("_transform()"))},c.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},c.prototype._read=function(e){var t=this._transformState;null===t.writechunk||t.transforming?t.needTransform=!0:(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform))},c.prototype._destroy=function(e,t){l.prototype._destroy.call(this,e,function(e){t(e)})}},function(e,t,n){"use strict";(function(t){const r=n(35);function i(e){return parseInt(e.toString("hex"),16)}function o(e){let n=e.toString(16);return n.length%2==1&&(n="0"+n),t.from(n,"hex")}function s(e){return t.from(r.encode(i(e)))}function a(e){return o(r.decode(e))}e.exports={numberToBuffer:o,bufferToNumber:i,varintBufferEncode:s,varintBufferDecode:a}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(95),i={};e.exports=i;for(let e in r){let t=r[e];i[t.toString("hex")]=e}},function(e,t){e.exports=function e(t,n,r){t(n),r&&r(!0===n?null:n)}},function(e,t,n){"use strict";var r=n(150);e.exports=function e(t){return r(null,t)}},function(e,t,n){var r=n(151);function i(e){return e}e.exports=function e(t){return"object"==typeof t&&"function"==typeof t.test?function(e){return t.test(e)}:r(t)||i}},function(e,t,n){"use strict";function r(e){return e}var i=n(151),o=n(67);e.exports=function e(t,n){t=i(t)||r;var s={};return o(function(e){var r=t(e);return s[r]?!!n:(s[r]=!0,!n)})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=n(708),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}function s(e,t,n){(0,i.default)(e,function(){return!t.apply(this,arguments)},n)}e.exports=t.default},function(e,t){e.exports=function(e){var t,n=!1;function r(r){if(!r)throw new Error("must be passed a readable");t=r,n&&e(t)}return r.resolve=r.ready=r.start=function(i){return n=!0,e=i||e,t&&e(t),r},r}},function(e,t,n){var r=n(188),i=n(348);e.exports=function(){var e=r(),t=i();return{source:e,sink:t,resolve:function(n){e.resolve(n.source),t.resolve(n.sink)}}}},function(e,t){var n=t.once=function(e){return function(t,n){if(t)return n(t);if(null!=e){var r=e;e=null,n(null,r)}else n(!0)}},r=t.depthFirst=function(e,t){var r=[],i;return r.unshift(n(e)),function e(n,o){return r.length?i?o(i):void r[0](n,function(n,s){if(n){if(!0!==n){for(i=n,r.shift();r.length;)r.shift()(n,function(){});return o(n)}return r.shift(),e(null,o)}r.unshift(t(s)),o(n,s)}):o(!0)}},i=t.widthFirst=function(e,t){var r=[];return r.push(n(e)),function e(n,i){if(!r.length)return i(!0);r[0](n,function(n,o){if(n)return r.shift(),e(null,i);r.push(t(o)),i(n,o)})}},o=t.leafFirst=function(e,t){var r=[],i=[];return r.push(n(e)),function e(n,o){r[0](n,function(n,s){if(n)return r.shift(),i.length?o(null,i.shift()):o(!0);r.unshift(t(s)),i.unshift(s),e(null,o)})}}},function(e,t,n){"use strict";var r=Object.prototype.toString;e.exports=function(e){var t;return"[object Object]"===r.call(e)&&(t=Object.getPrototypeOf(e),null===t||t===Object.getPrototypeOf({}))}},function(e,t,n){"use strict";(function(r){const i=n(710),o=n(56),s=n(9),a=n(722),l=n(365),u=42;function c(e){return"string"==typeof e?e=new s(e).buffer:s.isCID(e)&&(e=e.buffer),new i.Tagged(u,r.concat([r.from("00","hex"),e]))}const h=new i.Decoder({tags:{[u]:e=>(e=e.slice(1),new s(e))}});function f(e){let t;try{t=a(e)}catch(e){t=!1}if(t)throw new Error("The object passed has circular references");function n(e){if(!e||r.isBuffer(e)||"string"==typeof e)return e;if(Array.isArray(e))return e.map(n);if(s.isCID(e))return c(e);const t=Object.keys(e);if(1===t.length&&"/"===t[0])return c(e["/"]);if(t.length>0){const r={};return t.forEach(t=>{"object"==typeof e[t]?r[t]=n(e[t]):r[t]=e[t]}),r}return e}return n(e)}t=e.exports,t.serialize=((e,t)=>{let n;try{const r=f(e);n=i.encode(r)}catch(e){return setImmediate(()=>t(e))}setImmediate(()=>t(null,n))}),t.deserialize=((e,t)=>{let n;try{n=h.decodeFirst(e)}catch(e){return setImmediate(()=>t(e))}setImmediate(()=>t(null,n))}),t.cid=((e,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};const i=n.hashAlg||l.defaultHashAlg,a=n.hashLen,u=void 0===n.version?1:n.version;t.serialize(e,(e,t)=>{if(e)return r(e);o(t,i,a,(e,t)=>{if(e)return r(e);r(null,new s(u,l.multicodec,t))})})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t,r){const i=n(325),o=n(55),s=n(712),a=n(247),l=n(190),u=n(354),c=n(355),{URL:h}=n(191);class f{constructor(e){e=e||{},!e.size||e.size<65536?e.size=65536:e.size=a.nextPowerOf2(e.size),this._heap=new ArrayBuffer(e.size),this._heap8=new Uint8Array(this._heap),this._buffer=t.from(this._heap),this._reset(),this._knownTags=Object.assign({0:e=>new Date(e),1:e=>new Date(1e3*e),2:e=>a.arrayBufferToBignumber(e),3:e=>l.NEG_ONE.minus(a.arrayBufferToBignumber(e)),4:e=>l.TEN.pow(e[0]).times(e[1]),5:e=>l.TWO.pow(e[0]).times(e[1]),32:e=>new h(e),35:e=>new RegExp(e)},e.tags),this.parser=s(r,{log:console.log.bind(console),pushInt:this.pushInt.bind(this),pushInt32:this.pushInt32.bind(this),pushInt32Neg:this.pushInt32Neg.bind(this),pushInt64:this.pushInt64.bind(this),pushInt64Neg:this.pushInt64Neg.bind(this),pushFloat:this.pushFloat.bind(this),pushFloatSingle:this.pushFloatSingle.bind(this),pushFloatDouble:this.pushFloatDouble.bind(this),pushTrue:this.pushTrue.bind(this),pushFalse:this.pushFalse.bind(this),pushUndefined:this.pushUndefined.bind(this),pushNull:this.pushNull.bind(this),pushInfinity:this.pushInfinity.bind(this),pushInfinityNeg:this.pushInfinityNeg.bind(this),pushNaN:this.pushNaN.bind(this),pushNaNNeg:this.pushNaNNeg.bind(this),pushArrayStart:this.pushArrayStart.bind(this),pushArrayStartFixed:this.pushArrayStartFixed.bind(this),pushArrayStartFixed32:this.pushArrayStartFixed32.bind(this),pushArrayStartFixed64:this.pushArrayStartFixed64.bind(this),pushObjectStart:this.pushObjectStart.bind(this),pushObjectStartFixed:this.pushObjectStartFixed.bind(this),pushObjectStartFixed32:this.pushObjectStartFixed32.bind(this),pushObjectStartFixed64:this.pushObjectStartFixed64.bind(this),pushByteString:this.pushByteString.bind(this),pushByteStringStart:this.pushByteStringStart.bind(this),pushUtf8String:this.pushUtf8String.bind(this),pushUtf8StringStart:this.pushUtf8StringStart.bind(this),pushSimpleUnassigned:this.pushSimpleUnassigned.bind(this),pushTagUnassigned:this.pushTagUnassigned.bind(this),pushTagStart:this.pushTagStart.bind(this),pushTagStart4:this.pushTagStart4.bind(this),pushTagStart8:this.pushTagStart8.bind(this),pushBreak:this.pushBreak.bind(this)},this._heap)}get _depth(){return this._parents.length}get _currentParent(){return this._parents[this._depth-1]}get _ref(){return this._currentParent.ref}_closeParent(){var e=this._parents.pop();if(e.length>0)throw new Error(`Missing ${e.length} elements`);switch(e.type){case l.PARENT.TAG:this._push(this.createTag(e.ref[0],e.ref[1]));break;case l.PARENT.BYTE_STRING:this._push(this.createByteString(e.ref,e.length));break;case l.PARENT.UTF8_STRING:this._push(this.createUtf8String(e.ref,e.length));break;case l.PARENT.MAP:if(e.values%2>0)throw new Error("Odd number of elements in the map");this._push(this.createMap(e.ref,e.length));break;case l.PARENT.OBJECT:if(e.values%2>0)throw new Error("Odd number of elements in the map");this._push(this.createObject(e.ref,e.length));break;case l.PARENT.ARRAY:this._push(this.createArray(e.ref,e.length))}this._currentParent&&this._currentParent.type===l.PARENT.TAG&&this._dec()}_dec(){const e=this._currentParent;e.length<0||(e.length--,0===e.length&&this._closeParent())}_push(e,t){const n=this._currentParent;switch(n.values++,n.type){case l.PARENT.ARRAY:case l.PARENT.BYTE_STRING:case l.PARENT.UTF8_STRING:n.length>-1?this._ref[this._ref.length-n.length]=e:this._ref.push(e),this._dec();break;case l.PARENT.OBJECT:null!=n.tmpKey?(this._ref[n.tmpKey]=e,n.tmpKey=null,this._dec()):(n.tmpKey=e,"string"!=typeof n.tmpKey&&(n.type=l.PARENT.MAP,n.ref=a.buildMap(n.ref)));break;case l.PARENT.MAP:null!=n.tmpKey?(this._ref.set(n.tmpKey,e),n.tmpKey=null,this._dec()):n.tmpKey=e;break;case l.PARENT.TAG:this._ref.push(e),t||this._dec();break;default:throw new Error("Unknown parent type")}}_createParent(e,t,n){this._parents[this._depth]={type:t,length:n,ref:e,values:0,tmpKey:null}}_reset(){this._res=[],this._parents=[{type:l.PARENT.ARRAY,length:-1,ref:this._res,values:0,tmpKey:null}]}createTag(e,t){const n=this._knownTags[e];return n?n(t):new c(e,t)}createMap(e,t){return e}createObject(e,t){return e}createArray(e,t){return e}createByteString(e,n){return t.concat(e)}createByteStringFromHeap(e,n){return e===n?t.alloc(0):t.from(this._heap.slice(e,n))}createInt(e){return e}createInt32(e,t){return a.buildInt32(e,t)}createInt64(e,t,n,r){return a.buildInt64(e,t,n,r)}createFloat(e){return e}createFloatSingle(e,t,n,r){return i.read([e,t,n,r],0,!1,23,4)}createFloatDouble(e,t,n,r,o,s,a,l){return i.read([e,t,n,r,o,s,a,l],0,!1,52,8)}createInt32Neg(e,t){return-1-a.buildInt32(e,t)}createInt64Neg(e,t,n,r){const i=a.buildInt32(e,t),s=a.buildInt32(n,r);return i>l.MAX_SAFE_HIGH?l.NEG_ONE.minus(new o(i).times(l.SHIFT32).plus(s)):-1-(i*l.SHIFT32+s)}createTrue(){return!0}createFalse(){return!1}createNull(){return null}createUndefined(){}createInfinity(){return 1/0}createInfinityNeg(){return-1/0}createNaN(){return NaN}createNaNNeg(){return NaN}createUtf8String(e,t){return e.join("")}createUtf8StringFromHeap(e,t){return e===t?"":this._buffer.toString("utf8",e,t)}createSimpleUnassigned(e){return new u(e)}pushInt(e){this._push(this.createInt(e))}pushInt32(e,t){this._push(this.createInt32(e,t))}pushInt64(e,t,n,r){this._push(this.createInt64(e,t,n,r))}pushFloat(e){this._push(this.createFloat(e))}pushFloatSingle(e,t,n,r){this._push(this.createFloatSingle(e,t,n,r))}pushFloatDouble(e,t,n,r,i,o,s,a){this._push(this.createFloatDouble(e,t,n,r,i,o,s,a))}pushInt32Neg(e,t){this._push(this.createInt32Neg(e,t))}pushInt64Neg(e,t,n,r){this._push(this.createInt64Neg(e,t,n,r))}pushTrue(){this._push(this.createTrue())}pushFalse(){this._push(this.createFalse())}pushNull(){this._push(this.createNull())}pushUndefined(){this._push(this.createUndefined())}pushInfinity(){this._push(this.createInfinity())}pushInfinityNeg(){this._push(this.createInfinityNeg())}pushNaN(){this._push(this.createNaN())}pushNaNNeg(){this._push(this.createNaNNeg())}pushArrayStart(){this._createParent([],l.PARENT.ARRAY,-1)}pushArrayStartFixed(e){this._createArrayStartFixed(e)}pushArrayStartFixed32(e,t){const n=a.buildInt32(e,t);this._createArrayStartFixed(n)}pushArrayStartFixed64(e,t,n,r){const i=a.buildInt64(e,t,n,r);this._createArrayStartFixed(i)}pushObjectStart(){this._createObjectStartFixed(-1)}pushObjectStartFixed(e){this._createObjectStartFixed(e)}pushObjectStartFixed32(e,t){const n=a.buildInt32(e,t);this._createObjectStartFixed(n)}pushObjectStartFixed64(e,t,n,r){const i=a.buildInt64(e,t,n,r);this._createObjectStartFixed(i)}pushByteStringStart(){this._parents[this._depth]={type:l.PARENT.BYTE_STRING,length:-1,ref:[],values:0,tmpKey:null}}pushByteString(e,t){this._push(this.createByteStringFromHeap(e,t))}pushUtf8StringStart(){this._parents[this._depth]={type:l.PARENT.UTF8_STRING,length:-1,ref:[],values:0,tmpKey:null}}pushUtf8String(e,t){this._push(this.createUtf8StringFromHeap(e,t))}pushSimpleUnassigned(e){this._push(this.createSimpleUnassigned(e))}pushTagStart(e){this._parents[this._depth]={type:l.PARENT.TAG,length:1,ref:[e]}}pushTagStart4(e,t){this.pushTagStart(a.buildInt32(e,t))}pushTagStart8(e,t,n,r){this.pushTagStart(a.buildInt64(e,t,n,r))}pushTagUnassigned(e){this._push(this.createTag(e))}pushBreak(){if(this._currentParent.length>-1)throw new Error("Unexpected break");this._closeParent()}_createObjectStartFixed(e){0!==e?this._createParent({},l.PARENT.OBJECT,e):this._push(this.createObject({}))}_createArrayStartFixed(e){0!==e?this._createParent(new Array(e),l.PARENT.ARRAY,e):this._push(this.createArray([]))}_decode(e){if(0===e.byteLength)throw new Error("Input too short");this._reset(),this._heap8.set(e);const t=this.parser.parse(e.byteLength);if(this._depth>1){for(;0===this._currentParent.length;)this._closeParent();if(this._depth>1)throw new Error("Undeterminated nesting")}if(t>0)throw new Error("Failed to parse");if(0===this._res.length)throw new Error("No valid result")}decodeFirst(e){return this._decode(e),this._res[0]}decodeAll(e){return this._decode(e),this._res}static decode(e,n){"string"==typeof e&&(e=t.from(e,n||"hex"));const r=new f({size:e.length});return r.decodeFirst(e)}static decodeAll(e,n){"string"==typeof e&&(e=t.from(e,n||"hex"));const r=new f({size:e.length});return r.decodeAll(e)}}f.decodeFirst=f.decode,e.exports=f}).call(this,n(0).Buffer,n(8))},function(e,t,n){"use strict";const r=n(190),i=r.MT,o=r.SIMPLE,s=r.SYMS;class a{constructor(e){if("number"!=typeof e)throw new Error("Invalid Simple type: "+typeof e);if(e<0||e>255||(0|e)!==e)throw new Error("value must be a small positive integer: "+e);this.value=e}toString(){return"simple("+this.value+")"}inspect(){return"simple("+this.value+")"}encodeCBOR(e){return e._pushInt(this.value,i.SIMPLE_FLOAT)}static isSimple(e){return e instanceof a}static decode(e,t){switch(null==t&&(t=!0),e){case o.FALSE:return!1;case o.TRUE:return!0;case o.NULL:return t?null:s.NULL;case o.UNDEFINED:return t?void 0:s.UNDEFINED;case-1:if(!t)throw new Error("Invalid BREAK");return s.BREAK;default:return new a(e)}}}e.exports=a},function(e,t,n){"use strict";class r{constructor(e,t,n){if(this.tag=e,this.value=t,this.err=n,"number"!=typeof this.tag)throw new Error("Invalid tag type ("+typeof this.tag+")");if(this.tag<0||(0|this.tag)!==this.tag)throw new Error("Tag must be a positive integer: "+this.tag)}toString(){return`${this.tag}(${JSON.stringify(this.value)})`}encodeCBOR(e){return e._pushTag(this.tag),e.pushAny(this.value)}convert(e){var t,n;if(n=null!=e?e[this.tag]:void 0,"function"!=typeof n&&(n=r["_tag"+this.tag],"function"!=typeof n))return this;try{return n.call(r,this.value)}catch(e){return t=e,this.err=t,this}}}e.exports=r},function(e,t,n){"use strict";const r=self.location?self.location.protocol+"//"+self.location.host:"",i=self.URL;class o{constructor(e,t=r){this.super=new i(e,t),this.path=this.pathname+this.search,this.auth=this.username&&this.password?this.username+":"+this.password:null,this.query=this.search&&this.search.startsWith("?")?this.search.slice(1):null}get hash(){return this.super.hash}get host(){return this.super.host}get hostname(){return this.super.hostname}get href(){return this.super.href}get origin(){return this.super.origin}get password(){return this.super.password}get pathname(){return this.super.pathname}get port(){return this.super.port}get protocol(){return this.super.protocol}get search(){return this.super.search}get searchParams(){return this.super.searchParams}get username(){return this.super.username}set hash(e){this.super.hash=e}set host(e){this.super.host=e}set hostname(e){this.super.hostname=e}set href(e){this.super.href=e}set origin(e){this.super.origin=e}set password(e){this.super.password=e}set pathname(e){this.super.pathname=e}set port(e){this.super.port=e}set protocol(e){this.super.protocol=e}set search(e){this.super.search=e}set searchParams(e){this.super.searchParams=e}set username(e){this.super.username=e}createObjectURL(e){return this.super.createObjectURL(e)}revokeObjectURL(e){this.super.revokeObjectURL(e)}toJSON(){return this.super.toJSON()}toString(){return this.super.toString()}format(){return this.toString()}}function s(e){if("string"==typeof e){const t=new i(e);return t.toString()}if(!(e instanceof i)){const t=e.username&&e.password?`${e.username}:${e.password}@`:"",n=e.auth?e.auth+"@":"",r=e.port?":"+e.port:"",i=e.protocol?e.protocol+"//":"",o=e.host||"",s=e.hostname||"",a=e.search||(e.query?"?"+e.query:""),l=e.hash||"",u=e.pathname||"",c=e.path||u+a;return`${i}${t||n}${o||s+r}${c}${l}`}}e.exports={URLWithLegacySupport:o,URLSearchParams:self.URLSearchParams,defaultBase:r,format:s}},function(e,t,n){(function(r,i){var o;
/**
* [js-sha3]{@link https://github.com/emn178/js-sha3}
*
* @version 0.8.0
* @author Chen, Yi-Cyuan [emn178@gmail.com]
* @copyright Chen, Yi-Cyuan 2015-2018
* @license MIT
*/
/**
* [js-sha3]{@link https://github.com/emn178/js-sha3}
*
* @version 0.8.0
* @author Chen, Yi-Cyuan [emn178@gmail.com]
* @copyright Chen, Yi-Cyuan 2015-2018
* @license MIT
*/
!function(){"use strict";var s="input is invalid type",a="finalize already called",l="object"==typeof window,u=l?window:{};u.JS_SHA3_NO_WINDOW&&(l=!1);var c=!l&&"object"==typeof self,h=!u.JS_SHA3_NO_NODE_JS&&"object"==typeof r&&r.versions&&r.versions.node;h?u=i:c&&(u=self);var f=!u.JS_SHA3_NO_COMMON_JS&&"object"==typeof e&&e.exports,p=n(358),d=!u.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,m="0123456789abcdef".split(""),g=[31,7936,2031616,520093696],y=[4,1024,262144,67108864],v=[1,256,65536,16777216],b=[6,1536,393216,100663296],_=[0,8,16,24],w=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],k=[224,256,384,512],E=[128,256],S=["hex","buffer","arrayBuffer","array","digest"],x={128:168,256:136};!u.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(e){return"[object Array]"===Object.prototype.toString.call(e)}),!d||!u.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(e){return"object"==typeof e&&e.buffer&&e.buffer.constructor===ArrayBuffer});for(var C=function(e,t,n){return function(r){return new H(e,t,e).update(r)[n]()}},A=function(e,t,n){return function(r,i){return new H(e,t,i).update(r)[n]()}},T=function(e,t,n){return function(t,r,i,o){return D["cshake"+e].update(t,r,i,o)[n]()}},I=function(e,t,n){return function(t,r,i,o){return D["kmac"+e].update(t,r,i,o)[n]()}},j=function(e,t,n,r){for(var i=0;i<S.length;++i){var o=S[i];e[o]=t(n,r,o)}return e},R=function(e,t){var n=C(e,t,"hex");return n.create=function(){return new H(e,t,e)},n.update=function(e){return n.create().update(e)},j(n,C,e,t)},B=function(e,t){var n=A(e,t,"hex");return n.create=function(n){return new H(e,t,n)},n.update=function(e,t){return n.create(t).update(e)},j(n,A,e,t)},O=function(e,t){var n=x[e],r=T(e,t,"hex");return r.create=function(r,i,o){return i||o?new H(e,t,r).bytepad([i,o],n):D["shake"+e].create(r)},r.update=function(e,t,n,i){return r.create(t,n,i).update(e)},j(r,T,e,t)},P=function(e,t){var n=x[e],r=I(e,t,"hex");return r.create=function(r,i,o){return new V(e,t,i).bytepad(["KMAC",o],n).bytepad([r],n)},r.update=function(e,t,n,i){return r.create(e,n,i).update(t)},j(r,I,e,t)},N=[{name:"keccak",padding:v,bits:k,createMethod:R},{name:"sha3",padding:b,bits:k,createMethod:R},{name:"shake",padding:g,bits:E,createMethod:B},{name:"cshake",padding:y,bits:E,createMethod:O},{name:"kmac",padding:y,bits:E,createMethod:P}],D={},M=[],F=0;F<N.length;++F)for(var L=N[F],U=L.bits,q=0;q<U.length;++q){var z=L.name+"_"+U[q];if(M.push(z),D[z]=L.createMethod(U[q],L.padding),"sha3"!==L.name){var K=L.name+U[q];M.push(K),D[K]=D[z]}}function H(e,t,n){this.blocks=[],this.s=[],this.padding=t,this.outputBits=n,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(e<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=n>>5,this.extraBytes=(31&n)>>3;for(var r=0;r<50;++r)this.s[r]=0}function V(e,t,n){H.call(this,e,t,n)}H.prototype.update=function(e){if(this.finalized)throw new Error(a);var t,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(s);if(null===e)throw new Error(s);if(d&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||d&&ArrayBuffer.isView(e)))throw new Error(s);t=!0}for(var r=this.blocks,i=this.byteCount,o=e.length,l=this.blockCount,u=0,c=this.s,h,f;u<o;){if(this.reset)for(this.reset=!1,r[0]=this.block,h=1;h<l+1;++h)r[h]=0;if(t)for(h=this.start;u<o&&h<i;++u)r[h>>2]|=e[u]<<_[3&h++];else for(h=this.start;u<o&&h<i;++u)f=e.charCodeAt(u),f<128?r[h>>2]|=f<<_[3&h++]:f<2048?(r[h>>2]|=(192|f>>6)<<_[3&h++],r[h>>2]|=(128|63&f)<<_[3&h++]):f<55296||f>=57344?(r[h>>2]|=(224|f>>12)<<_[3&h++],r[h>>2]|=(128|f>>6&63)<<_[3&h++],r[h>>2]|=(128|63&f)<<_[3&h++]):(f=65536+((1023&f)<<10|1023&e.charCodeAt(++u)),r[h>>2]|=(240|f>>18)<<_[3&h++],r[h>>2]|=(128|f>>12&63)<<_[3&h++],r[h>>2]|=(128|f>>6&63)<<_[3&h++],r[h>>2]|=(128|63&f)<<_[3&h++]);if(this.lastByteIndex=h,h>=i){for(this.start=h-i,this.block=r[l],h=0;h<l;++h)c[h]^=r[h];$(c),this.reset=!0}else this.start=h}return this},H.prototype.encode=function(e,t){var n=255&e,r=1,i=[n];for(e>>=8,n=255&e;n>0;)i.unshift(n),e>>=8,n=255&e,++r;return t?i.push(r):i.unshift(r),this.update(i),i.length},H.prototype.encodeString=function(e){var t,n=typeof e;if("string"!==n){if("object"!==n)throw new Error(s);if(null===e)throw new Error(s);if(d&&e.constructor===ArrayBuffer)e=new Uint8Array(e);else if(!(Array.isArray(e)||d&&ArrayBuffer.isView(e)))throw new Error(s);t=!0}var r=0,i=e.length;if(t)r=i;else for(var o=0;o<e.length;++o){var a=e.charCodeAt(o);a<128?r+=1:a<2048?r+=2:a<55296||a>=57344?r+=3:(a=65536+((1023&a)<<10|1023&e.charCodeAt(++o)),r+=4)}return r+=this.encode(8*r),this.update(e),r},H.prototype.bytepad=function(e,t){for(var n=this.encode(t),r=0;r<e.length;++r)n+=this.encodeString(e[r]);var i=t-n%t,o=[];return o.length=i,this.update(o),this},H.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var e=this.blocks,t=this.lastByteIndex,n=this.blockCount,r=this.s;if(e[t>>2]|=this.padding[3&t],this.lastByteIndex===this.byteCount)for(e[0]=e[n],t=1;t<n+1;++t)e[t]=0;for(e[n-1]|=2147483648,t=0;t<n;++t)r[t]^=e[t];$(r)}},H.prototype.toString=H.prototype.hex=function(){this.finalize();for(var e=this.blockCount,t=this.s,n=this.outputBlocks,r=this.extraBytes,i=0,o=0,s="",a;o<n;){for(i=0;i<e&&o<n;++i,++o)a=t[i],s+=m[a>>4&15]+m[15&a]+m[a>>12&15]+m[a>>8&15]+m[a>>20&15]+m[a>>16&15]+m[a>>28&15]+m[a>>24&15];o%e==0&&($(t),i=0)}return r&&(a=t[i],s+=m[a>>4&15]+m[15&a],r>1&&(s+=m[a>>12&15]+m[a>>8&15]),r>2&&(s+=m[a>>20&15]+m[a>>16&15])),s},H.prototype.arrayBuffer=function(){this.finalize();var e=this.blockCount,t=this.s,n=this.outputBlocks,r=this.extraBytes,i=0,o=0,s=this.outputBits>>3,a;a=r?new ArrayBuffer(n+1<<2):new ArrayBuffer(s);for(var l=new Uint32Array(a);o<n;){for(i=0;i<e&&o<n;++i,++o)l[o]=t[i];o%e==0&&$(t)}return r&&(l[i]=t[i],a=a.slice(0,s)),a},H.prototype.buffer=H.prototype.arrayBuffer,H.prototype.digest=H.prototype.array=function(){this.finalize();for(var e=this.blockCount,t=this.s,n=this.outputBlocks,r=this.extraBytes,i=0,o=0,s=[],a,l;o<n;){for(i=0;i<e&&o<n;++i,++o)a=o<<2,l=t[i],s[a]=255&l,s[a+1]=l>>8&255,s[a+2]=l>>16&255,s[a+3]=l>>24&255;o%e==0&&$(t)}return r&&(a=o<<2,l=t[i],s[a]=255&l,r>1&&(s[a+1]=l>>8&255),r>2&&(s[a+2]=l>>16&255)),s},V.prototype=new H,V.prototype.finalize=function(){return this.encode(this.outputBits,!0),H.prototype.finalize.call(this)};var $=function(e){var t,n,r,i,o,s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,k,E,S,x,C,A,T,I,j,R,B,O,P,N,D,M,F,L,U,q,z,K,H,V,$,W,G,Y,Z,J,Q,X,ee,te,ne,re,ie,oe,se,ae,le,ue,ce;for(r=0;r<48;r+=2)i=e[0]^e[10]^e[20]^e[30]^e[40],o=e[1]^e[11]^e[21]^e[31]^e[41],s=e[2]^e[12]^e[22]^e[32]^e[42],a=e[3]^e[13]^e[23]^e[33]^e[43],l=e[4]^e[14]^e[24]^e[34]^e[44],u=e[5]^e[15]^e[25]^e[35]^e[45],c=e[6]^e[16]^e[26]^e[36]^e[46],h=e[7]^e[17]^e[27]^e[37]^e[47],f=e[8]^e[18]^e[28]^e[38]^e[48],p=e[9]^e[19]^e[29]^e[39]^e[49],t=f^(s<<1|a>>>31),n=p^(a<<1|s>>>31),e[0]^=t,e[1]^=n,e[10]^=t,e[11]^=n,e[20]^=t,e[21]^=n,e[30]^=t,e[31]^=n,e[40]^=t,e[41]^=n,t=i^(l<<1|u>>>31),n=o^(u<<1|l>>>31),e[2]^=t,e[3]^=n,e[12]^=t,e[13]^=n,e[22]^=t,e[23]^=n,e[32]^=t,e[33]^=n,e[42]^=t,e[43]^=n,t=s^(c<<1|h>>>31),n=a^(h<<1|c>>>31),e[4]^=t,e[5]^=n,e[14]^=t,e[15]^=n,e[24]^=t,e[25]^=n,e[34]^=t,e[35]^=n,e[44]^=t,e[45]^=n,t=l^(f<<1|p>>>31),n=u^(p<<1|f>>>31),e[6]^=t,e[7]^=n,e[16]^=t,e[17]^=n,e[26]^=t,e[27]^=n,e[36]^=t,e[37]^=n,e[46]^=t,e[47]^=n,t=c^(i<<1|o>>>31),n=h^(o<<1|i>>>31),e[8]^=t,e[9]^=n,e[18]^=t,e[19]^=n,e[28]^=t,e[29]^=n,e[38]^=t,e[39]^=n,e[48]^=t,e[49]^=n,d=e[0],m=e[1],W=e[11]<<4|e[10]>>>28,G=e[10]<<4|e[11]>>>28,I=e[20]<<3|e[21]>>>29,j=e[21]<<3|e[20]>>>29,ae=e[31]<<9|e[30]>>>23,le=e[30]<<9|e[31]>>>23,K=e[40]<<18|e[41]>>>14,H=e[41]<<18|e[40]>>>14,N=e[2]<<1|e[3]>>>31,D=e[3]<<1|e[2]>>>31,g=e[13]<<12|e[12]>>>20,y=e[12]<<12|e[13]>>>20,Y=e[22]<<10|e[23]>>>22,Z=e[23]<<10|e[22]>>>22,R=e[33]<<13|e[32]>>>19,B=e[32]<<13|e[33]>>>19,ue=e[42]<<2|e[43]>>>30,ce=e[43]<<2|e[42]>>>30,te=e[5]<<30|e[4]>>>2,ne=e[4]<<30|e[5]>>>2,M=e[14]<<6|e[15]>>>26,F=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,b=e[24]<<11|e[25]>>>21,J=e[34]<<15|e[35]>>>17,Q=e[35]<<15|e[34]>>>17,O=e[45]<<29|e[44]>>>3,P=e[44]<<29|e[45]>>>3,x=e[6]<<28|e[7]>>>4,C=e[7]<<28|e[6]>>>4,re=e[17]<<23|e[16]>>>9,ie=e[16]<<23|e[17]>>>9,L=e[26]<<25|e[27]>>>7,U=e[27]<<25|e[26]>>>7,_=e[36]<<21|e[37]>>>11,k=e[37]<<21|e[36]>>>11,X=e[47]<<24|e[46]>>>8,ee=e[46]<<24|e[47]>>>8,V=e[8]<<27|e[9]>>>5,$=e[9]<<27|e[8]>>>5,A=e[18]<<20|e[19]>>>12,T=e[19]<<20|e[18]>>>12,oe=e[29]<<7|e[28]>>>25,se=e[28]<<7|e[29]>>>25,q=e[38]<<8|e[39]>>>24,z=e[39]<<8|e[38]>>>24,E=e[48]<<14|e[49]>>>18,S=e[49]<<14|e[48]>>>18,e[0]=d^~g&v,e[1]=m^~y&b,e[10]=x^~A&I,e[11]=C^~T&j,e[20]=N^~M&L,e[21]=D^~F&U,e[30]=V^~W&Y,e[31]=$^~G&Z,e[40]=te^~re&oe,e[41]=ne^~ie&se,e[2]=g^~v&_,e[3]=y^~b&k,e[12]=A^~I&R,e[13]=T^~j&B,e[22]=M^~L&q,e[23]=F^~U&z,e[32]=W^~Y&J,e[33]=G^~Z&Q,e[42]=re^~oe&ae,e[43]=ie^~se&le,e[4]=v^~_&E,e[5]=b^~k&S,e[14]=I^~R&O,e[15]=j^~B&P,e[24]=L^~q&K,e[25]=U^~z&H,e[34]=Y^~J&X,e[35]=Z^~Q&ee,e[44]=oe^~ae&ue,e[45]=se^~le&ce,e[6]=_^~E&d,e[7]=k^~S&m,e[16]=R^~O&x,e[17]=B^~P&C,e[26]=q^~K&N,e[27]=z^~H&D,e[36]=J^~X&V,e[37]=Q^~ee&$,e[46]=ae^~ue&te,e[47]=le^~ce&ne,e[8]=E^~d&g,e[9]=S^~m&y,e[18]=O^~x&A,e[19]=P^~C&T,e[28]=K^~N&M,e[29]=H^~D&F,e[38]=X^~V&W,e[39]=ee^~$&G,e[48]=ue^~te&re,e[49]=ce^~ne&ie,e[0]^=w[r],e[1]^=w[r+1]};if(f)e.exports=D;else{for(F=0;F<M.length;++F)u[M[F]]=D[M[F]];p&&(o=function(){return D}.call(t,n,t,e),void 0===o||(e.exports=o))}}()}).call(this,n(3),n(8))},function(e,t){(function(t){e.exports=t}).call(this,{})},function(e,t,n){e.exports=n(716)},function(e,t,n){"use strict";(function(e,n){t.toCallback=(t=>(function(n,r){let i;try{i=t(n)}catch(t){return void e.nextTick(r,t)}e.nextTick(r,null,i)})),t.toBuf=((e,t)=>r=>{let i=e(r,t);return n.from(i,"hex")}),t.fromString=((e,t)=>r=>{const i=n.isBuffer(r)?r.toString():r;return e(i,t)}),t.fromNumberTo32BitBuf=((e,t)=>r=>{let i=e(r,t);const o=new Array(4);for(let e=0;e<4;e++)o[e]=255&i,i>>=8;return n.from(o)})}).call(this,n(3),n(0).Buffer)},function(e,t,n){(function(t){var r=n(718),i=n(362),o;function s(e,t){return"function"!=typeof t?e:e.then(function(e){o(function(){t(null,e)})},function(e){o(function(){t(e)})})}function a(e){return s(this,e)}function l(e){if(e&&i(e)){e.nodeify=a;var t=e.then;return e.then=function(){return l(t.apply(this,arguments))},e}"function"==typeof e?e.prototype.nodeify=a:r.prototype.nodeify=a}function u(e){if(!(this instanceof u))return new u(e);r.call(this,e),l(this)}o="function"==typeof setImmediate?setImmediate:"object"==typeof t&&t&&t.nextTick?t.nextTick:function(e){setTimeout(e,0)},e.exports=s,s.extend=l,s.Promise=u,u.prototype=Object.create(r.prototype),u.prototype.constructor=u}).call(this,n(3))},function(e,t){function n(e){return e&&"function"==typeof e.then}e.exports=n},function(e,t,n){var r=n(720),i=n(721);e.exports={blake2b:r.blake2b,blake2bHex:r.blake2bHex,blake2bInit:r.blake2bInit,blake2bUpdate:r.blake2bUpdate,blake2bFinal:r.blake2bFinal,blake2s:i.blake2s,blake2sHex:i.blake2sHex,blake2sInit:i.blake2sInit,blake2sUpdate:i.blake2sUpdate,blake2sFinal:i.blake2sFinal}},function(e,t,n){(function(t){var n="Input must be an string, Buffer or Uint8Array";function r(e){var r;if(e instanceof Uint8Array)r=e;else if(e instanceof t)r=new Uint8Array(e);else{if("string"!=typeof e)throw new Error(n);r=new Uint8Array(t.from(e,"utf8"))}return r}function i(e){return Array.prototype.map.call(e,function(e){return(e<16?"0":"")+e.toString(16)}).join("")}function o(e){return(4294967296+e).toString(16).substring(1)}function s(e,t,n){for(var r="\n"+e+" = ",i=0;i<t.length;i+=2){if(32===n)r+=o(t[i]).toUpperCase(),r+=" ",r+=o(t[i+1]).toUpperCase();else{if(64!==n)throw new Error("Invalid size "+n);r+=o(t[i+1]).toUpperCase(),r+=o(t[i]).toUpperCase()}i%6==4?r+="\n"+new Array(e.length+4).join(" "):i<t.length-2&&(r+=" ")}console.log(r)}function a(e,t,n){for(var r=(new Date).getTime(),i=new Uint8Array(t),o=0;o<t;o++)i[o]=o%256;var s=(new Date).getTime();for(console.log("Generated random input in "+(s-r)+"ms"),r=s,o=0;o<n;o++){var a=e(i),l=(new Date).getTime(),u=l-r;r=l,console.log("Hashed in "+u+"ms: "+a.substring(0,20)+"..."),console.log(Math.round(t/(1<<20)/(u/1e3)*100)/100+" MB PER SECOND")}}e.exports={normalizeInput:r,toHex:i,debugPrint:s,testSpeed:a}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(352),o=n(724),s=n(9);function a(e,t){return t=t||"/",0===Object.keys(e).length?[]:o(e).reduce(function(e,n){s.isCID(n)&&this.update(void 0);const r=this.path.join(t);return""!==r&&e.push({path:r,value:n}),e},[])}t=e.exports,t.multicodec="dag-cbor",t.defaultHashAlg="sha2-256",t.resolve=((e,t,n)=>{"function"==typeof t&&(n=t,t=void 0),i.deserialize(e,(e,i)=>{if(e)return n(e);if(!t||"/"===t)return n(null,{value:i,remainderPath:""});const s=t.split("/"),a=o(i).get(s);if(void 0!==a)return n(null,{value:a,remainderPath:""});let l;const u=s.length;for(let e=0;e<u;e++){const e=s.shift();if(Array.isArray(i)&&!r.isBuffer(i)&&(l=i[Number(e)]),!i[e])return l?(s.unshift(e),n(null,{value:l,remainderPath:s.join("/")})):n(new Error("path not available at root"));l=i[e],i=l}})}),t.tree=((e,t,n)=>{"function"==typeof t&&(n=t,t=void 0),t=t||{},i.deserialize(e,(e,t)=>{if(e)return n(e);const r=a(t),i=r.map(e=>e.path);n(null,i)})}),t.isLink=((e,n,r)=>{t.resolve(e,n,(e,t)=>e?r(e):t.remainderPath.length>0?r(new Error("path out of scope")):void(s.isCID(t.value)?r(null,t.value):r(null,!1)))})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(10),i=n(9),o=n(194);t=e.exports,t.multicodec="dag-pb",t.defaultHashAlg="sha2-256",t.resolve=((e,t,n)=>{r([t=>o.deserialize(e,t),(e,r)=>{if(!t)return n(null,{value:e,remainderPath:""});const i=t.split("/");if("Links"===i[0]){let t="";if(!i[1])return r(null,{value:e.links.map(e=>e.toJSON()),remainderPath:""});const n={};e.links.forEach((e,t)=>{const r=e.toJSON();n[t]=n[r.name]={cid:r.cid,name:r.name,size:r.size}});let o=n[i[1]];"Hash"===i[2]?o={"/":o.cid}:"Tsize"===i[2]?o=o.size:"Name"===i[2]&&(o=o.name),t=i.slice(3).join("/"),r(null,{value:o,remainderPath:t})}else if("Data"===i[0])r(null,{value:e.data,remainderPath:""});else{const t={};e.links.forEach((e,n)=>{const r=e.toJSON();t[r.name]={cid:r.cid,name:r.name,size:r.size}});const n=t[i[0]];if(n)return r(null,{value:{"/":n.cid},remainderPath:i.slice(1).join("/")});r(new Error("path not available"))}}],n)}),t.tree=((e,t,n)=>{"function"==typeof t&&(n=t,t={}),t=t||{},o.deserialize(e,(e,t)=>{if(e)return n(e);const r=[];r.push("Links"),t.links.forEach((e,t)=>{r.push(`Links/${t}/Name`),r.push(`Links/${t}/Tsize`),r.push(`Links/${t}/Hash`)}),r.push("Data"),n(null,r)})}),t.isLink=((e,n,r)=>{t.resolve(e,n,(e,t)=>{if(e)return r(e);if(t.remainderPath.length>0)return r(new Error("path out of scope"));if("object"==typeof t.value&&t.value["/"]){let n;try{n=i.isCID(new i(t.value["/"]))}catch(e){n=!1}if(n)return r(null,t.value)}r(null,!1)})})},function(e,t,n){"use strict";const r=n(9),i=n(56);e.exports={resolver:{multicodec:"raw",defaultHashAlg:"sha2-256",resolve:(e,t,n)=>{n(null,{value:e,remainderPath:""})},tree:(e,t,n)=>{"function"==typeof t&&(n=t),n(null,[])}},util:{deserialize:(e,t)=>{t(null,e)},serialize:(e,t)=>{t(null,e)},cid:(e,t,n)=>{"function"==typeof t&&(n=t,t={}),t=t||{};const o=t.hashAlg||"sha2-256",s=void 0===t.version?1:t.version;i(e,o,(e,t)=>{if(e)return n(e);n(null,new r(s,"raw",t))})}}}},function(e,t,n){"use strict";(function(r){const i=n(57),o=i(n(249));n(117),n(250),n(251);const s=n(21);t=e.exports;const a={rsa:n(753),ed25519:n(769),secp256k1:n(773)(o,n(256))};function l(e){const t=a[e.toLowerCase()];return void 0!==t}t.supportedKeys=a,t.keysPBM=o,t.keyStretcher=n(801),t.generateEphemeralKeyPair=n(803),t.generateKeyPair=((e,t,n)=>{let r=a[e.toLowerCase()];if(!r)return n(new Error("invalid or unsupported key type"));r.generateKeyPair(t,n)}),t.generateKeyPairFromSeed=((e,t,n,r)=>{let i=a[e.toLowerCase()];return i?"ed25519"!==e.toLowerCase()?r(new Error("Seed key derivation is unimplemented for RSA or secp256k1")):void i.generateKeyPairFromSeed(t,n,r):r(new Error("invalid or unsupported key type"))}),t.unmarshalPublicKey=(e=>{const t=o.PublicKey.decode(e),n=t.Data;switch(t.Type){case o.KeyType.RSA:return a.rsa.unmarshalRsaPublicKey(n);case o.KeyType.Ed25519:return a.ed25519.unmarshalEd25519PublicKey(n);case o.KeyType.Secp256k1:if(a.secp256k1)return a.secp256k1.unmarshalSecp256k1PublicKey(n);throw new Error("secp256k1 support requires libp2p-crypto-secp256k1 package");default:throw new Error("invalid or unsupported key type")}}),t.marshalPublicKey=((e,t)=>{if(t=(t||"rsa").toLowerCase(),!l(t))throw new Error("invalid or unsupported key type");return e.bytes}),t.unmarshalPrivateKey=((e,t)=>{let n;try{n=o.PrivateKey.decode(e)}catch(e){return t(e)}const r=n.Data;switch(n.Type){case o.KeyType.RSA:return a.rsa.unmarshalRsaPrivateKey(r,t);case o.KeyType.Ed25519:return a.ed25519.unmarshalEd25519PrivateKey(r,t);case o.KeyType.Secp256k1:return a.secp256k1?a.secp256k1.unmarshalSecp256k1PrivateKey(r,t):t(new Error("secp256k1 support requires libp2p-crypto-secp256k1 package"));default:t(new Error("invalid or unsupported key type"))}}),t.marshalPrivateKey=((e,t)=>{if(t=(t||"rsa").toLowerCase(),!l(t))throw new Error("invalid or unsupported key type");return e.bytes}),t.import=((e,t,n)=>{try{const i=s.pki.decryptRsaPrivateKey(e,t);if(null===i)throw new Error("Cannot read the key, most likely the password is wrong or not a RSA key");let o=s.asn1.toDer(s.pki.privateKeyToAsn1(i));return o=r.from(o.getBytes(),"binary"),a.rsa.unmarshalRsaPrivateKey(o,n)}catch(e){n(e)}})}).call(this,n(0).Buffer)},function(e,t,n){var r=n(21),i;e.exports=r.jsbn=r.jsbn||{};var o=0xdeadbeefcafe,s=!0;function a(e,t,n){this.data=[],null!=e&&("number"==typeof e?this.fromNumber(e,t,n):null==t&&"string"!=typeof e?this.fromString(e,256):this.fromString(e,t))}function l(){return new a(null)}function u(e,t,n,r,i,o){for(;--o>=0;){var s=t*this.data[e++]+n.data[r]+i;i=Math.floor(s/67108864),n.data[r++]=67108863&s}return i}function c(e,t,n,r,i,o){for(var s=32767&t,a=t>>15;--o>=0;){var l=32767&this.data[e],u=this.data[e++]>>15,c=a*l+u*s;l=s*l+((32767&c)<<15)+n.data[r]+(1073741823&i),i=(l>>>30)+(c>>>15)+a*u+(i>>>30),n.data[r++]=1073741823&l}return i}function h(e,t,n,r,i,o){for(var s=16383&t,a=t>>14;--o>=0;){var l=16383&this.data[e],u=this.data[e++]>>14,c=a*l+u*s;l=s*l+((16383&c)<<14)+n.data[r]+i,i=(l>>28)+(c>>14)+a*u,n.data[r++]=268435455&l}return i}r.jsbn.BigInteger=a,"undefined"==typeof navigator?(a.prototype.am=h,i=28):"Microsoft Internet Explorer"==navigator.appName?(a.prototype.am=c,i=30):"Netscape"!=navigator.appName?(a.prototype.am=u,i=26):(a.prototype.am=h,i=28),a.prototype.DB=i,a.prototype.DM=(1<<i)-1,a.prototype.DV=1<<i;var f=52;a.prototype.FV=Math.pow(2,52),a.prototype.F1=52-i,a.prototype.F2=2*i-52;var p="0123456789abcdefghijklmnopqrstuvwxyz",d=new Array,m,g;for(m="0".charCodeAt(0),g=0;g<=9;++g)d[m++]=g;for(m="a".charCodeAt(0),g=10;g<36;++g)d[m++]=g;for(m="A".charCodeAt(0),g=10;g<36;++g)d[m++]=g;function y(e){return p.charAt(e)}function v(e,t){var n=d[e.charCodeAt(t)];return null==n?-1:n}function b(e){for(var t=this.t-1;t>=0;--t)e.data[t]=this.data[t];e.t=this.t,e.s=this.s}function _(e){this.t=1,this.s=e<0?-1:0,e>0?this.data[0]=e:e<-1?this.data[0]=e+this.DV:this.t=0}function w(e){var t=l();return t.fromInt(e),t}function k(e,t){var n;if(16==t)n=4;else if(8==t)n=3;else if(256==t)n=8;else if(2==t)n=1;else if(32==t)n=5;else{if(4!=t)return void this.fromRadix(e,t);n=2}this.t=0,this.s=0;for(var r=e.length,i=!1,o=0;--r>=0;){var s=8==n?255&e[r]:v(e,r);s<0?"-"==e.charAt(r)&&(i=!0):(i=!1,0==o?this.data[this.t++]=s:o+n>this.DB?(this.data[this.t-1]|=(s&(1<<this.DB-o)-1)<<o,this.data[this.t++]=s>>this.DB-o):this.data[this.t-1]|=s<<o,o+=n,o>=this.DB&&(o-=this.DB))}8==n&&0!=(128&e[0])&&(this.s=-1,o>0&&(this.data[this.t-1]|=(1<<this.DB-o)-1<<o)),this.clamp(),i&&a.ZERO.subTo(this,this)}function E(){for(var e=this.s&this.DM;this.t>0&&this.data[this.t-1]==e;)--this.t}function S(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)return this.toRadix(e);t=2}var n=(1<<t)-1,r,i=!1,o="",s=this.t,a=this.DB-s*this.DB%t;if(s-- >0)for(a<this.DB&&(r=this.data[s]>>a)>0&&(i=!0,o=y(r));s>=0;)a<t?(r=(this.data[s]&(1<<a)-1)<<t-a,r|=this.data[--s]>>(a+=this.DB-t)):(r=this.data[s]>>(a-=t)&n,a<=0&&(a+=this.DB,--s)),r>0&&(i=!0),i&&(o+=y(r));return i?o:"0"}function x(){var e=l();return a.ZERO.subTo(this,e),e}function C(){return this.s<0?this.negate():this}function A(e){var t=this.s-e.s;if(0!=t)return t;var n=this.t;if(t=n-e.t,0!=t)return this.s<0?-t:t;for(;--n>=0;)if(0!=(t=this.data[n]-e.data[n]))return t;return 0}function T(e){var t=1,n;return 0!=(n=e>>>16)&&(e=n,t+=16),0!=(n=e>>8)&&(e=n,t+=8),0!=(n=e>>4)&&(e=n,t+=4),0!=(n=e>>2)&&(e=n,t+=2),0!=(n=e>>1)&&(e=n,t+=1),t}function I(){return this.t<=0?0:this.DB*(this.t-1)+T(this.data[this.t-1]^this.s&this.DM)}function j(e,t){var n;for(n=this.t-1;n>=0;--n)t.data[n+e]=this.data[n];for(n=e-1;n>=0;--n)t.data[n]=0;t.t=this.t+e,t.s=this.s}function R(e,t){for(var n=e;n<this.t;++n)t.data[n-e]=this.data[n];t.t=Math.max(this.t-e,0),t.s=this.s}function B(e,t){var n=e%this.DB,r=this.DB-n,i=(1<<r)-1,o=Math.floor(e/this.DB),s=this.s<<n&this.DM,a;for(a=this.t-1;a>=0;--a)t.data[a+o+1]=this.data[a]>>r|s,s=(this.data[a]&i)<<n;for(a=o-1;a>=0;--a)t.data[a]=0;t.data[o]=s,t.t=this.t+o+1,t.s=this.s,t.clamp()}function O(e,t){t.s=this.s;var n=Math.floor(e/this.DB);if(n>=this.t)t.t=0;else{var r=e%this.DB,i=this.DB-r,o=(1<<r)-1;t.data[0]=this.data[n]>>r;for(var s=n+1;s<this.t;++s)t.data[s-n-1]|=(this.data[s]&o)<<i,t.data[s-n]=this.data[s]>>r;r>0&&(t.data[this.t-n-1]|=(this.s&o)<<i),t.t=this.t-n,t.clamp()}}function P(e,t){for(var n=0,r=0,i=Math.min(e.t,this.t);n<i;)r+=this.data[n]-e.data[n],t.data[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r-=e.s;n<this.t;)r+=this.data[n],t.data[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r-=e.data[n],t.data[n++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t.data[n++]=this.DV+r:r>0&&(t.data[n++]=r),t.t=n,t.clamp()}function N(e,t){var n=this.abs(),r=e.abs(),i=n.t;for(t.t=i+r.t;--i>=0;)t.data[i]=0;for(i=0;i<r.t;++i)t.data[i+n.t]=n.am(0,r.data[i],t,i,0,n.t);t.s=0,t.clamp(),this.s!=e.s&&a.ZERO.subTo(t,t)}function D(e){for(var t=this.abs(),n=e.t=2*t.t;--n>=0;)e.data[n]=0;for(n=0;n<t.t-1;++n){var r=t.am(n,t.data[n],e,2*n,0,1);(e.data[n+t.t]+=t.am(n+1,2*t.data[n],e,2*n+1,r,t.t-n-1))>=t.DV&&(e.data[n+t.t]-=t.DV,e.data[n+t.t+1]=1)}e.t>0&&(e.data[e.t-1]+=t.am(n,t.data[n],e,2*n,0,1)),e.s=0,e.clamp()}function M(e,t,n){var r=e.abs();if(!(r.t<=0)){var i=this.abs();if(i.t<r.t)return null!=t&&t.fromInt(0),void(null!=n&&this.copyTo(n));null==n&&(n=l());var o=l(),s=this.s,u=e.s,c=this.DB-T(r.data[r.t-1]);c>0?(r.lShiftTo(c,o),i.lShiftTo(c,n)):(r.copyTo(o),i.copyTo(n));var h=o.t,f=o.data[h-1];if(0!=f){var p=f*(1<<this.F1)+(h>1?o.data[h-2]>>this.F2:0),d=this.FV/p,m=(1<<this.F1)/p,g=1<<this.F2,y=n.t,v=y-h,b=null==t?l():t;for(o.dlShiftTo(v,b),n.compareTo(b)>=0&&(n.data[n.t++]=1,n.subTo(b,n)),a.ONE.dlShiftTo(h,b),b.subTo(o,o);o.t<h;)o.data[o.t++]=0;for(;--v>=0;){var _=n.data[--y]==f?this.DM:Math.floor(n.data[y]*d+(n.data[y-1]+g)*m);if((n.data[y]+=o.am(0,_,n,v,0,h))<_)for(o.dlShiftTo(v,b),n.subTo(b,n);n.data[y]<--_;)n.subTo(b,n)}null!=t&&(n.drShiftTo(h,t),s!=u&&a.ZERO.subTo(t,t)),n.t=h,n.clamp(),c>0&&n.rShiftTo(c,n),s<0&&a.ZERO.subTo(n,n)}}}function F(e){var t=l();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(a.ZERO)>0&&e.subTo(t,t),t}function L(e){this.m=e}function U(e){return e.s<0||e.compareTo(this.m)>=0?e.mod(this.m):e}function q(e){return e}function z(e){e.divRemTo(this.m,null,e)}function K(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function H(e,t){e.squareTo(t),this.reduce(t)}function V(){if(this.t<1)return 0;var e=this.data[0];if(0==(1&e))return 0;var t=3&e;return t=t*(2-(15&e)*t)&15,t=t*(2-(255&e)*t)&255,t=t*(2-((65535&e)*t&65535))&65535,t=t*(2-e*t%this.DV)%this.DV,t>0?this.DV-t:-t}function $(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function W(e){var t=l();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(a.ZERO)>0&&this.m.subTo(t,t),t}function G(e){var t=l();return e.copyTo(t),this.reduce(t),t}function Y(e){for(;e.t<=this.mt2;)e.data[e.t++]=0;for(var t=0;t<this.m.t;++t){var n=32767&e.data[t],r=n*this.mpl+((n*this.mph+(e.data[t]>>15)*this.mpl&this.um)<<15)&e.DM;for(n=t+this.m.t,e.data[n]+=this.m.am(0,r,e,t,0,this.m.t);e.data[n]>=e.DV;)e.data[n]-=e.DV,e.data[++n]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)}function Z(e,t){e.squareTo(t),this.reduce(t)}function J(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function Q(){return 0==(this.t>0?1&this.data[0]:this.s)}function X(e,t){if(e>4294967295||e<1)return a.ONE;var n=l(),r=l(),i=t.convert(this),o=T(e)-1;for(i.copyTo(n);--o>=0;)if(t.sqrTo(n,r),(e&1<<o)>0)t.mulTo(r,i,n);else{var s=n;n=r,r=s}return t.revert(n)}function ee(e,t){var n;return n=e<256||t.isEven()?new L(t):new $(t),this.exp(e,n)}function te(){var e=l();return this.copyTo(e),e}function ne(){if(this.s<0){if(1==this.t)return this.data[0]-this.DV;if(0==this.t)return-1}else{if(1==this.t)return this.data[0];if(0==this.t)return 0}return(this.data[1]&(1<<32-this.DB)-1)<<this.DB|this.data[0]}function re(){return 0==this.t?this.s:this.data[0]<<24>>24}function ie(){return 0==this.t?this.s:this.data[0]<<16>>16}function oe(e){return Math.floor(Math.LN2*this.DB/Math.log(e))}function se(){return this.s<0?-1:this.t<=0||1==this.t&&this.data[0]<=0?0:1}function ae(e){if(null==e&&(e=10),0==this.signum()||e<2||e>36)return"0";var t=this.chunkSize(e),n=Math.pow(e,t),r=w(n),i=l(),o=l(),s="";for(this.divRemTo(r,i,o);i.signum()>0;)s=(n+o.intValue()).toString(e).substr(1)+s,i.divRemTo(r,i,o);return o.intValue().toString(e)+s}function le(e,t){this.fromInt(0),null==t&&(t=10);for(var n=this.chunkSize(t),r=Math.pow(t,n),i=!1,o=0,s=0,l=0;l<e.length;++l){var u=v(e,l);u<0?"-"==e.charAt(l)&&0==this.signum()&&(i=!0):(s=t*s+u,++o>=n&&(this.dMultiply(r),this.dAddOffset(s,0),o=0,s=0))}o>0&&(this.dMultiply(Math.pow(t,o)),this.dAddOffset(s,0)),i&&a.ZERO.subTo(this,this)}function ue(e,t,n){if("number"==typeof t)if(e<2)this.fromInt(1);else for(this.fromNumber(e,n),this.testBit(e-1)||this.bitwiseTo(a.ONE.shiftLeft(e-1),ye,this),this.isEven()&&this.dAddOffset(1,0);!this.isProbablePrime(t);)this.dAddOffset(2,0),this.bitLength()>e&&this.subTo(a.ONE.shiftLeft(e-1),this);else{var r=new Array,i=7&e;r.length=1+(e>>3),t.nextBytes(r),i>0?r[0]&=(1<<i)-1:r[0]=0,this.fromString(r,256)}}function ce(){var e=this.t,t=new Array;t[0]=this.s;var n=this.DB-e*this.DB%8,r,i=0;if(e-- >0)for(n<this.DB&&(r=this.data[e]>>n)!=(this.s&this.DM)>>n&&(t[i++]=r|this.s<<this.DB-n);e>=0;)n<8?(r=(this.data[e]&(1<<n)-1)<<8-n,r|=this.data[--e]>>(n+=this.DB-8)):(r=this.data[e]>>(n-=8)&255,n<=0&&(n+=this.DB,--e)),0!=(128&r)&&(r|=-256),0==i&&(128&this.s)!=(128&r)&&++i,(i>0||r!=this.s)&&(t[i++]=r);return t}function he(e){return 0==this.compareTo(e)}function fe(e){return this.compareTo(e)<0?this:e}function pe(e){return this.compareTo(e)>0?this:e}function de(e,t,n){var r,i,o=Math.min(e.t,this.t);for(r=0;r<o;++r)n.data[r]=t(this.data[r],e.data[r]);if(e.t<this.t){for(i=e.s&this.DM,r=o;r<this.t;++r)n.data[r]=t(this.data[r],i);n.t=this.t}else{for(i=this.s&this.DM,r=o;r<e.t;++r)n.data[r]=t(i,e.data[r]);n.t=e.t}n.s=t(this.s,e.s),n.clamp()}function me(e,t){return e&t}function ge(e){var t=l();return this.bitwiseTo(e,me,t),t}function ye(e,t){return e|t}function ve(e){var t=l();return this.bitwiseTo(e,ye,t),t}function be(e,t){return e^t}function _e(e){var t=l();return this.bitwiseTo(e,be,t),t}function we(e,t){return e&~t}function ke(e){var t=l();return this.bitwiseTo(e,we,t),t}function Ee(){for(var e=l(),t=0;t<this.t;++t)e.data[t]=this.DM&~this.data[t];return e.t=this.t,e.s=~this.s,e}function Se(e){var t=l();return e<0?this.rShiftTo(-e,t):this.lShiftTo(e,t),t}function xe(e){var t=l();return e<0?this.lShiftTo(-e,t):this.rShiftTo(e,t),t}function Ce(e){if(0==e)return-1;var t=0;return 0==(65535&e)&&(e>>=16,t+=16),0==(255&e)&&(e>>=8,t+=8),0==(15&e)&&(e>>=4,t+=4),0==(3&e)&&(e>>=2,t+=2),0==(1&e)&&++t,t}function Ae(){for(var e=0;e<this.t;++e)if(0!=this.data[e])return e*this.DB+Ce(this.data[e]);return this.s<0?this.t*this.DB:-1}function Te(e){for(var t=0;0!=e;)e&=e-1,++t;return t}function Ie(){for(var e=0,t=this.s&this.DM,n=0;n<this.t;++n)e+=Te(this.data[n]^t);return e}function je(e){var t=Math.floor(e/this.DB);return t>=this.t?0!=this.s:0!=(this.data[t]&1<<e%this.DB)}function Re(e,t){var n=a.ONE.shiftLeft(e);return this.bitwiseTo(n,t,n),n}function Be(e){return this.changeBit(e,ye)}function Oe(e){return this.changeBit(e,we)}function Pe(e){return this.changeBit(e,be)}function Ne(e,t){for(var n=0,r=0,i=Math.min(e.t,this.t);n<i;)r+=this.data[n]+e.data[n],t.data[n++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r+=e.s;n<this.t;)r+=this.data[n],t.data[n++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;n<e.t;)r+=e.data[n],t.data[n++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t.data[n++]=r:r<-1&&(t.data[n++]=this.DV+r),t.t=n,t.clamp()}function De(e){var t=l();return this.addTo(e,t),t}function Me(e){var t=l();return this.subTo(e,t),t}function Fe(e){var t=l();return this.multiplyTo(e,t),t}function Le(e){var t=l();return this.divRemTo(e,t,null),t}function Ue(e){var t=l();return this.divRemTo(e,null,t),t}function qe(e){var t=l(),n=l();return this.divRemTo(e,t,n),new Array(t,n)}function ze(e){this.data[this.t]=this.am(0,e-1,this,0,0,this.t),++this.t,this.clamp()}function Ke(e,t){if(0!=e){for(;this.t<=t;)this.data[this.t++]=0;for(this.data[t]+=e;this.data[t]>=this.DV;)this.data[t]-=this.DV,++t>=this.t&&(this.data[this.t++]=0),++this.data[t]}}function He(){}function Ve(e){return e}function $e(e,t,n){e.multiplyTo(t,n)}function We(e,t){e.squareTo(t)}function Ge(e){return this.exp(e,new He)}function Ye(e,t,n){var r=Math.min(this.t+e.t,t),i;for(n.s=0,n.t=r;r>0;)n.data[--r]=0;for(i=n.t-this.t;r<i;++r)n.data[r+this.t]=this.am(0,e.data[r],n,r,0,this.t);for(i=Math.min(e.t,t);r<i;++r)this.am(0,e.data[r],n,r,0,t-r);n.clamp()}function Ze(e,t,n){--t;var r=n.t=this.t+e.t-t;for(n.s=0;--r>=0;)n.data[r]=0;for(r=Math.max(t-this.t,0);r<e.t;++r)n.data[this.t+r-t]=this.am(t-r,e.data[r],n,0,0,this.t+r-t);n.clamp(),n.drShiftTo(1,n)}function Je(e){this.r2=l(),this.q3=l(),a.ONE.dlShiftTo(2*e.t,this.r2),this.mu=this.r2.divide(e),this.m=e}function Qe(e){if(e.s<0||e.t>2*this.m.t)return e.mod(this.m);if(e.compareTo(this.m)<0)return e;var t=l();return e.copyTo(t),this.reduce(t),t}function Xe(e){return e}function et(e){for(e.drShiftTo(this.m.t-1,this.r2),e.t>this.m.t+1&&(e.t=this.m.t+1,e.clamp()),this.mu.multiplyUpperTo(this.r2,this.m.t+1,this.q3),this.m.multiplyLowerTo(this.q3,this.m.t+1,this.r2);e.compareTo(this.r2)<0;)e.dAddOffset(1,this.m.t+1);for(e.subTo(this.r2,e);e.compareTo(this.m)>=0;)e.subTo(this.m,e)}function tt(e,t){e.squareTo(t),this.reduce(t)}function nt(e,t,n){e.multiplyTo(t,n),this.reduce(n)}function rt(e,t){var n=e.bitLength(),r,i=w(1),o;if(n<=0)return i;r=n<18?1:n<48?3:n<144?4:n<768?5:6,o=n<8?new L(t):t.isEven()?new Je(t):new $(t);var s=new Array,a=3,u=r-1,c=(1<<r)-1;if(s[1]=o.convert(this),r>1){var h=l();for(o.sqrTo(s[1],h);a<=c;)s[a]=l(),o.mulTo(h,s[a-2],s[a]),a+=2}var f=e.t-1,p,d=!0,m=l(),g;for(n=T(e.data[f])-1;f>=0;){for(n>=u?p=e.data[f]>>n-u&c:(p=(e.data[f]&(1<<n+1)-1)<<u-n,f>0&&(p|=e.data[f-1]>>this.DB+n-u)),a=r;0==(1&p);)p>>=1,--a;if((n-=a)<0&&(n+=this.DB,--f),d)s[p].copyTo(i),d=!1;else{for(;a>1;)o.sqrTo(i,m),o.sqrTo(m,i),a-=2;a>0?o.sqrTo(i,m):(g=i,i=m,m=g),o.mulTo(m,s[p],i)}for(;f>=0&&0==(e.data[f]&1<<n);)o.sqrTo(i,m),g=i,i=m,m=g,--n<0&&(n=this.DB-1,--f)}return o.revert(i)}function it(e){var t=this.s<0?this.negate():this.clone(),n=e.s<0?e.negate():e.clone();if(t.compareTo(n)<0){var r=t;t=n,n=r}var i=t.getLowestSetBit(),o=n.getLowestSetBit();if(o<0)return t;for(i<o&&(o=i),o>0&&(t.rShiftTo(o,t),n.rShiftTo(o,n));t.signum()>0;)(i=t.getLowestSetBit())>0&&t.rShiftTo(i,t),(i=n.getLowestSetBit())>0&&n.rShiftTo(i,n),t.compareTo(n)>=0?(t.subTo(n,t),t.rShiftTo(1,t)):(n.subTo(t,n),n.rShiftTo(1,n));return o>0&&n.lShiftTo(o,n),n}function ot(e){if(e<=0)return 0;var t=this.DV%e,n=this.s<0?e-1:0;if(this.t>0)if(0==t)n=this.data[0]%e;else for(var r=this.t-1;r>=0;--r)n=(t*n+this.data[r])%e;return n}function st(e){var t=e.isEven();if(this.isEven()&&t||0==e.signum())return a.ZERO;for(var n=e.clone(),r=this.clone(),i=w(1),o=w(0),s=w(0),l=w(1);0!=n.signum();){for(;n.isEven();)n.rShiftTo(1,n),t?(i.isEven()&&o.isEven()||(i.addTo(this,i),o.subTo(e,o)),i.rShiftTo(1,i)):o.isEven()||o.subTo(e,o),o.rShiftTo(1,o);for(;r.isEven();)r.rShiftTo(1,r),t?(s.isEven()&&l.isEven()||(s.addTo(this,s),l.subTo(e,l)),s.rShiftTo(1,s)):l.isEven()||l.subTo(e,l),l.rShiftTo(1,l);n.compareTo(r)>=0?(n.subTo(r,n),t&&i.subTo(s,i),o.subTo(l,o)):(r.subTo(n,r),t&&s.subTo(i,s),l.subTo(o,l))}return 0!=r.compareTo(a.ONE)?a.ZERO:l.compareTo(e)>=0?l.subtract(e):l.signum()<0?(l.addTo(e,l),l.signum()<0?l.add(e):l):l}L.prototype.convert=U,L.prototype.revert=q,L.prototype.reduce=z,L.prototype.mulTo=K,L.prototype.sqrTo=H,$.prototype.convert=W,$.prototype.revert=G,$.prototype.reduce=Y,$.prototype.mulTo=J,$.prototype.sqrTo=Z,a.prototype.copyTo=b,a.prototype.fromInt=_,a.prototype.fromString=k,a.prototype.clamp=E,a.prototype.dlShiftTo=j,a.prototype.drShiftTo=R,a.prototype.lShiftTo=B,a.prototype.rShiftTo=O,a.prototype.subTo=P,a.prototype.multiplyTo=N,a.prototype.squareTo=D,a.prototype.divRemTo=M,a.prototype.invDigit=V,a.prototype.isEven=Q,a.prototype.exp=X,a.prototype.toString=S,a.prototype.negate=x,a.prototype.abs=C,a.prototype.compareTo=A,a.prototype.bitLength=I,a.prototype.mod=F,a.prototype.modPowInt=ee,a.ZERO=w(0),a.ONE=w(1),He.prototype.convert=Ve,He.prototype.revert=Ve,He.prototype.mulTo=$e,He.prototype.sqrTo=We,Je.prototype.convert=Qe,Je.prototype.revert=Xe,Je.prototype.reduce=et,Je.prototype.mulTo=nt,Je.prototype.sqrTo=tt;var at=[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],lt=(1<<26)/at[at.length-1];function ut(e){var t,n=this.abs();if(1==n.t&&n.data[0]<=at[at.length-1]){for(t=0;t<at.length;++t)if(n.data[0]==at[t])return!0;return!1}if(n.isEven())return!1;for(t=1;t<at.length;){for(var r=at[t],i=t+1;i<at.length&&r<lt;)r*=at[i++];for(r=n.modInt(r);t<i;)if(r%at[t++]==0)return!1}return n.millerRabin(e)}function ct(e){var t=this.subtract(a.ONE),n=t.getLowestSetBit();if(n<=0)return!1;for(var r=t.shiftRight(n),i=ht(),o,s=0;s<e;++s){do{o=new a(this.bitLength(),i)}while(o.compareTo(a.ONE)<=0||o.compareTo(t)>=0);var l=o.modPow(r,this);if(0!=l.compareTo(a.ONE)&&0!=l.compareTo(t)){for(var u=1;u++<n&&0!=l.compareTo(t);)if(l=l.modPowInt(2,this),0==l.compareTo(a.ONE))return!1;if(0!=l.compareTo(t))return!1}}return!0}function ht(){return{nextBytes:function(e){for(var t=0;t<e.length;++t)e[t]=Math.floor(256*Math.random())}}}a.prototype.chunkSize=oe,a.prototype.toRadix=ae,a.prototype.fromRadix=le,a.prototype.fromNumber=ue,a.prototype.bitwiseTo=de,a.prototype.changeBit=Re,a.prototype.addTo=Ne,a.prototype.dMultiply=ze,a.prototype.dAddOffset=Ke,a.prototype.multiplyLowerTo=Ye,a.prototype.multiplyUpperTo=Ze,a.prototype.modInt=ot,a.prototype.millerRabin=ct,a.prototype.clone=te,a.prototype.intValue=ne,a.prototype.byteValue=re,a.prototype.shortValue=ie,a.prototype.signum=se,a.prototype.toByteArray=ce,a.prototype.equals=he,a.prototype.min=fe,a.prototype.max=pe,a.prototype.and=ge,a.prototype.or=ve,a.prototype.xor=_e,a.prototype.andNot=ke,a.prototype.not=Ee,a.prototype.shiftLeft=Se,a.prototype.shiftRight=xe,a.prototype.getLowestSetBit=Ae,a.prototype.bitCount=Ie,a.prototype.testBit=je,a.prototype.setBit=Be,a.prototype.clearBit=Oe,a.prototype.flipBit=Pe,a.prototype.add=De,a.prototype.subtract=Me,a.prototype.multiply=Fe,a.prototype.divide=Le,a.prototype.remainder=Ue,a.prototype.divideAndRemainder=qe,a.prototype.modPow=rt,a.prototype.modInverse=st,a.prototype.pow=Ge,a.prototype.gcd=it,a.prototype.isProbablePrime=ut},function(e,t,n){var r=n(21);n(30),e.exports=r.cipher=r.cipher||{},r.cipher.algorithms=r.cipher.algorithms||{},r.cipher.createCipher=function(e,t){var n=e;if("string"==typeof n&&(n=r.cipher.getAlgorithm(n),n&&(n=n())),!n)throw new Error("Unsupported algorithm: "+e);return new r.cipher.BlockCipher({algorithm:n,key:t,decrypt:!1})},r.cipher.createDecipher=function(e,t){var n=e;if("string"==typeof n&&(n=r.cipher.getAlgorithm(n),n&&(n=n())),!n)throw new Error("Unsupported algorithm: "+e);return new r.cipher.BlockCipher({algorithm:n,key:t,decrypt:!0})},r.cipher.registerAlgorithm=function(e,t){e=e.toUpperCase(),r.cipher.algorithms[e]=t},r.cipher.getAlgorithm=function(e){return e=e.toUpperCase(),e in r.cipher.algorithms?r.cipher.algorithms[e]:null};var i=r.cipher.BlockCipher=function(e){this.algorithm=e.algorithm,this.mode=this.algorithm.mode,this.blockSize=this.mode.blockSize,this._finish=!1,this._input=null,this.output=null,this._op=e.decrypt?this.mode.decrypt:this.mode.encrypt,this._decrypt=e.decrypt,this.algorithm.initialize(e)};i.prototype.start=function(e){e=e||{};var t={};for(var n in e)t[n]=e[n];t.decrypt=this._decrypt,this._finish=!1,this._input=r.util.createBuffer(),this.output=e.output||r.util.createBuffer(),this.mode.start(t)},i.prototype.update=function(e){for(e&&this._input.putBuffer(e);!this._op.call(this.mode,this._input,this.output,this._finish)&&!this._finish;);this._input.compact()},i.prototype.finish=function(e){!e||"ECB"!==this.mode.name&&"CBC"!==this.mode.name||(this.mode.pad=function(t){return e(this.blockSize,t,!1)},this.mode.unpad=function(t){return e(this.blockSize,t,!0)});var t={};return t.decrypt=this._decrypt,t.overflow=this._input.length()%this.blockSize,!(!this._decrypt&&this.mode.pad&&!this.mode.pad(this._input,t))&&(this._finish=!0,this.update(),!(this._decrypt&&this.mode.unpad&&!this.mode.unpad(this.output,t))&&!(this.mode.afterFinish&&!this.mode.afterFinish(this.output,t)))}},function(e,t,n){var r=n(21);n(30),r.cipher=r.cipher||{};var i=e.exports=r.cipher.modes=r.cipher.modes||{};function o(e){if("string"==typeof e&&(e=r.util.createBuffer(e)),r.util.isArray(e)&&e.length>4){var t=e;e=r.util.createBuffer();for(var n=0;n<t.length;++n)e.putByte(t[n])}return r.util.isArray(e)||(e=[e.getInt32(),e.getInt32(),e.getInt32(),e.getInt32()]),e}function s(e){e[e.length-1]=e[e.length-1]+1&4294967295}function a(e){return[e/4294967296|0,4294967295&e]}i.ecb=function(e){e=e||{},this.name="ECB",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=new Array(this._ints),this._outBlock=new Array(this._ints)},i.ecb.prototype.start=function(e){},i.ecb.prototype.encrypt=function(e,t,n){if(e.length()<this.blockSize&&!(n&&e.length()>0))return!0;for(var r=0;r<this._ints;++r)this._inBlock[r]=e.getInt32();this.cipher.encrypt(this._inBlock,this._outBlock);for(var r=0;r<this._ints;++r)t.putInt32(this._outBlock[r])},i.ecb.prototype.decrypt=function(e,t,n){if(e.length()<this.blockSize&&!(n&&e.length()>0))return!0;for(var r=0;r<this._ints;++r)this._inBlock[r]=e.getInt32();this.cipher.decrypt(this._inBlock,this._outBlock);for(var r=0;r<this._ints;++r)t.putInt32(this._outBlock[r])},i.ecb.prototype.pad=function(e,t){var n=e.length()===this.blockSize?this.blockSize:this.blockSize-e.length();return e.fillWithByte(n,n),!0},i.ecb.prototype.unpad=function(e,t){if(t.overflow>0)return!1;var n=e.length(),r=e.at(n-1);return!(r>this.blockSize<<2)&&(e.truncate(r),!0)},i.cbc=function(e){e=e||{},this.name="CBC",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=new Array(this._ints),this._outBlock=new Array(this._ints)},i.cbc.prototype.start=function(e){if(null===e.iv){if(!this._prev)throw new Error("Invalid IV parameter.");this._iv=this._prev.slice(0)}else{if(!("iv"in e))throw new Error("Invalid IV parameter.");this._iv=o(e.iv),this._prev=this._iv.slice(0)}},i.cbc.prototype.encrypt=function(e,t,n){if(e.length()<this.blockSize&&!(n&&e.length()>0))return!0;for(var r=0;r<this._ints;++r)this._inBlock[r]=this._prev[r]^e.getInt32();this.cipher.encrypt(this._inBlock,this._outBlock);for(var r=0;r<this._ints;++r)t.putInt32(this._outBlock[r]);this._prev=this._outBlock},i.cbc.prototype.decrypt=function(e,t,n){if(e.length()<this.blockSize&&!(n&&e.length()>0))return!0;for(var r=0;r<this._ints;++r)this._inBlock[r]=e.getInt32();this.cipher.decrypt(this._inBlock,this._outBlock);for(var r=0;r<this._ints;++r)t.putInt32(this._prev[r]^this._outBlock[r]);this._prev=this._inBlock.slice(0)},i.cbc.prototype.pad=function(e,t){var n=e.length()===this.blockSize?this.blockSize:this.blockSize-e.length();return e.fillWithByte(n,n),!0},i.cbc.prototype.unpad=function(e,t){if(t.overflow>0)return!1;var n=e.length(),r=e.at(n-1);return!(r>this.blockSize<<2)&&(e.truncate(r),!0)},i.cfb=function(e){e=e||{},this.name="CFB",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=null,this._outBlock=new Array(this._ints),this._partialBlock=new Array(this._ints),this._partialOutput=r.util.createBuffer(),this._partialBytes=0},i.cfb.prototype.start=function(e){if(!("iv"in e))throw new Error("Invalid IV parameter.");this._iv=o(e.iv),this._inBlock=this._iv.slice(0),this._partialBytes=0},i.cfb.prototype.encrypt=function(e,t,n){var r=e.length();if(0===r)return!0;if(this.cipher.encrypt(this._inBlock,this._outBlock),0===this._partialBytes&&r>=this.blockSize)for(var i=0;i<this._ints;++i)this._inBlock[i]=e.getInt32()^this._outBlock[i],t.putInt32(this._inBlock[i]);else{var o=(this.blockSize-r)%this.blockSize;o>0&&(o=this.blockSize-o),this._partialOutput.clear();for(var i=0;i<this._ints;++i)this._partialBlock[i]=e.getInt32()^this._outBlock[i],this._partialOutput.putInt32(this._partialBlock[i]);if(o>0)e.read-=this.blockSize;else for(var i=0;i<this._ints;++i)this._inBlock[i]=this._partialBlock[i];if(this._partialBytes>0&&this._partialOutput.getBytes(this._partialBytes),o>0&&!n)return t.putBytes(this._partialOutput.getBytes(o-this._partialBytes)),this._partialBytes=o,!0;t.putBytes(this._partialOutput.getBytes(r-this._partialBytes)),this._partialBytes=0}},i.cfb.prototype.decrypt=function(e,t,n){var r=e.length();if(0===r)return!0;if(this.cipher.encrypt(this._inBlock,this._outBlock),0===this._partialBytes&&r>=this.blockSize)for(var i=0;i<this._ints;++i)this._inBlock[i]=e.getInt32(),t.putInt32(this._inBlock[i]^this._outBlock[i]);else{var o=(this.blockSize-r)%this.blockSize;o>0&&(o=this.blockSize-o),this._partialOutput.clear();for(var i=0;i<this._ints;++i)this._partialBlock[i]=e.getInt32(),this._partialOutput.putInt32(this._partialBlock[i]^this._outBlock[i]);if(o>0)e.read-=this.blockSize;else for(var i=0;i<this._ints;++i)this._inBlock[i]=this._partialBlock[i];if(this._partialBytes>0&&this._partialOutput.getBytes(this._partialBytes),o>0&&!n)return t.putBytes(this._partialOutput.getBytes(o-this._partialBytes)),this._partialBytes=o,!0;t.putBytes(this._partialOutput.getBytes(r-this._partialBytes)),this._partialBytes=0}},i.ofb=function(e){e=e||{},this.name="OFB",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=null,this._outBlock=new Array(this._ints),this._partialOutput=r.util.createBuffer(),this._partialBytes=0},i.ofb.prototype.start=function(e){if(!("iv"in e))throw new Error("Invalid IV parameter.");this._iv=o(e.iv),this._inBlock=this._iv.slice(0),this._partialBytes=0},i.ofb.prototype.encrypt=function(e,t,n){var r=e.length();if(0===e.length())return!0;if(this.cipher.encrypt(this._inBlock,this._outBlock),0===this._partialBytes&&r>=this.blockSize)for(var i=0;i<this._ints;++i)t.putInt32(e.getInt32()^this._outBlock[i]),this._inBlock[i]=this._outBlock[i];else{var o=(this.blockSize-r)%this.blockSize;o>0&&(o=this.blockSize-o),this._partialOutput.clear();for(var i=0;i<this._ints;++i)this._partialOutput.putInt32(e.getInt32()^this._outBlock[i]);if(o>0)e.read-=this.blockSize;else for(var i=0;i<this._ints;++i)this._inBlock[i]=this._outBlock[i];if(this._partialBytes>0&&this._partialOutput.getBytes(this._partialBytes),o>0&&!n)return t.putBytes(this._partialOutput.getBytes(o-this._partialBytes)),this._partialBytes=o,!0;t.putBytes(this._partialOutput.getBytes(r-this._partialBytes)),this._partialBytes=0}},i.ofb.prototype.decrypt=i.ofb.prototype.encrypt,i.ctr=function(e){e=e||{},this.name="CTR",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=null,this._outBlock=new Array(this._ints),this._partialOutput=r.util.createBuffer(),this._partialBytes=0},i.ctr.prototype.start=function(e){if(!("iv"in e))throw new Error("Invalid IV parameter.");this._iv=o(e.iv),this._inBlock=this._iv.slice(0),this._partialBytes=0},i.ctr.prototype.encrypt=function(e,t,n){var r=e.length();if(0===r)return!0;if(this.cipher.encrypt(this._inBlock,this._outBlock),0===this._partialBytes&&r>=this.blockSize)for(var i=0;i<this._ints;++i)t.putInt32(e.getInt32()^this._outBlock[i]);else{var o=(this.blockSize-r)%this.blockSize;o>0&&(o=this.blockSize-o),this._partialOutput.clear();for(var i=0;i<this._ints;++i)this._partialOutput.putInt32(e.getInt32()^this._outBlock[i]);if(o>0&&(e.read-=this.blockSize),this._partialBytes>0&&this._partialOutput.getBytes(this._partialBytes),o>0&&!n)return t.putBytes(this._partialOutput.getBytes(o-this._partialBytes)),this._partialBytes=o,!0;t.putBytes(this._partialOutput.getBytes(r-this._partialBytes)),this._partialBytes=0}s(this._inBlock)},i.ctr.prototype.decrypt=i.ctr.prototype.encrypt,i.gcm=function(e){e=e||{},this.name="GCM",this.cipher=e.cipher,this.blockSize=e.blockSize||16,this._ints=this.blockSize/4,this._inBlock=new Array(this._ints),this._outBlock=new Array(this._ints),this._partialOutput=r.util.createBuffer(),this._partialBytes=0,this._R=3774873600},i.gcm.prototype.start=function(e){if(!("iv"in e))throw new Error("Invalid IV parameter.");var t=r.util.createBuffer(e.iv),n;if(this._cipherLength=0,n="additionalData"in e?r.util.createBuffer(e.additionalData):r.util.createBuffer(),this._tagLength="tagLength"in e?e.tagLength:128,this._tag=null,e.decrypt&&(this._tag=r.util.createBuffer(e.tag).getBytes(),this._tag.length!==this._tagLength/8))throw new Error("Authentication tag does not match tag length.");this._hashBlock=new Array(this._ints),this.tag=null,this._hashSubkey=new Array(this._ints),this.cipher.encrypt([0,0,0,0],this._hashSubkey),this.componentBits=4,this._m=this.generateHashTable(this._hashSubkey,this.componentBits);var i=t.length();if(12===i)this._j0=[t.getInt32(),t.getInt32(),t.getInt32(),1];else{for(this._j0=[0,0,0,0];t.length()>0;)this._j0=this.ghash(this._hashSubkey,this._j0,[t.getInt32(),t.getInt32(),t.getInt32(),t.getInt32()]);this._j0=this.ghash(this._hashSubkey,this._j0,[0,0].concat(a(8*i)))}this._inBlock=this._j0.slice(0),s(this._inBlock),this._partialBytes=0,n=r.util.createBuffer(n),this._aDataLength=a(8*n.length());var o=n.length()%this.blockSize;for(o&&n.fillWithByte(0,this.blockSize-o),this._s=[0,0,0,0];n.length()>0;)this._s=this.ghash(this._hashSubkey,this._s,[n.getInt32(),n.getInt32(),n.getInt32(),n.getInt32()])},i.gcm.prototype.encrypt=function(e,t,n){var r=e.length();if(0===r)return!0;if(this.cipher.encrypt(this._inBlock,this._outBlock),0===this._partialBytes&&r>=this.blockSize){for(var i=0;i<this._ints;++i)t.putInt32(this._outBlock[i]^=e.getInt32());this._cipherLength+=this.blockSize}else{var o=(this.blockSize-r)%this.blockSize;o>0&&(o=this.blockSize-o),this._partialOutput.clear();for(var i=0;i<this._ints;++i)this._partialOutput.putInt32(e.getInt32()^this._outBlock[i]);if(0===o||n){if(n){var a=r%this.blockSize;this._cipherLength+=a,this._partialOutput.truncate(this.blockSize-a)}else this._cipherLength+=this.blockSize;for(var i=0;i<this._ints;++i)this._outBlock[i]=this._partialOutput.getInt32();this._partialOutput.read-=this.blockSize}if(this._partialBytes>0&&this._partialOutput.getBytes(this._partialBytes),o>0&&!n)return e.read-=this.blockSize,t.putBytes(this._partialOutput.getBytes(o-this._partialBytes)),this._partialBytes=o,!0;t.putBytes(this._partialOutput.getBytes(r-this._partialBytes)),this._partialBytes=0}this._s=this.ghash(this._hashSubkey,this._s,this._outBlock),s(this._inBlock)},i.gcm.prototype.decrypt=function(e,t,n){var r=e.length();if(r<this.blockSize&&!(n&&r>0))return!0;this.cipher.encrypt(this._inBlock,this._outBlock),s(this._inBlock),this._hashBlock[0]=e.getInt32(),this._hashBlock[1]=e.getInt32(),this._hashBlock[2]=e.getInt32(),this._hashBlock[3]=e.getInt32(),this._s=this.ghash(this._hashSubkey,this._s,this._hashBlock);for(var i=0;i<this._ints;++i)t.putInt32(this._outBlock[i]^this._hashBlock[i]);r<this.blockSize?this._cipherLength+=r%this.blockSize:this._cipherLength+=this.blockSize},i.gcm.prototype.afterFinish=function(e,t){var n=!0;t.decrypt&&t.overflow&&e.truncate(this.blockSize-t.overflow),this.tag=r.util.createBuffer();var i=this._aDataLength.concat(a(8*this._cipherLength));this._s=this.ghash(this._hashSubkey,this._s,i);var o=[];this.cipher.encrypt(this._j0,o);for(var s=0;s<this._ints;++s)this.tag.putInt32(this._s[s]^o[s]);return this.tag.truncate(this.tag.length()%(this._tagLength/8)),t.decrypt&&this.tag.bytes()!==this._tag&&(n=!1),n},i.gcm.prototype.multiply=function(e,t){for(var n=[0,0,0,0],r=t.slice(0),i=0;i<128;++i){var o=e[i/32|0]&1<<31-i%32;o&&(n[0]^=r[0],n[1]^=r[1],n[2]^=r[2],n[3]^=r[3]),this.pow(r,r)}return n},i.gcm.prototype.pow=function(e,t){for(var n=1&e[3],r=3;r>0;--r)t[r]=e[r]>>>1|(1&e[r-1])<<31;t[0]=e[0]>>>1,n&&(t[0]^=this._R)},i.gcm.prototype.tableMultiply=function(e){for(var t=[0,0,0,0],n=0;n<32;++n){var r=n/8|0,i=e[r]>>>4*(7-n%8)&15,o=this._m[n][i];t[0]^=o[0],t[1]^=o[1],t[2]^=o[2],t[3]^=o[3]}return t},i.gcm.prototype.ghash=function(e,t,n){return t[0]^=n[0],t[1]^=n[1],t[2]^=n[2],t[3]^=n[3],this.tableMultiply(t)},i.gcm.prototype.generateHashTable=function(e,t){for(var n=8/t,r=4*n,i=16*n,o=new Array(i),s=0;s<i;++s){var a=[0,0,0,0],l=s/r|0,u=(r-1-s%r)*t;a[l]=1<<t-1<<u,o[s]=this.generateSubHashTable(this.multiply(a,e),t)}return o},i.gcm.prototype.generateSubHashTable=function(e,t){var n=1<<t,r=n>>>1,i=new Array(n);i[r]=e.slice(0);for(var o=r>>>1;o>0;)this.pow(i[2*o],i[o]=[]),o>>=1;for(o=2;o<r;){for(var s=1;s<o;++s){var a=i[o],l=i[s];i[o+s]=[a[0]^l[0],a[1]^l[1],a[2]^l[2],a[3]^l[3]]}o*=2}for(i[0]=[0,0,0,0],o=r+1;o<n;++o){var u=i[o^r];i[o]=[e[0]^u[0],e[1]^u[1],e[2]^u[2],e[3]^u[3]]}return i}},function(e,t){},function(e,t,n){(function(t){var r=n(21);n(751),n(97),n(30);var i=r.pkcs5=r.pkcs5||{},o;r.util.isNodejs&&!r.options.usePureJavaScript&&(o=n(372)),e.exports=r.pbkdf2=i.pbkdf2=function(e,n,i,s,a,l){if("function"==typeof a&&(l=a,a=null),r.util.isNodejs&&!r.options.usePureJavaScript&&o.pbkdf2&&(null===a||"object"!=typeof a)&&(o.pbkdf2Sync.length>4||!a||"sha1"===a))return"string"!=typeof a&&(a="sha1"),e=new t(e,"binary"),n=new t(n,"binary"),l?4===o.pbkdf2Sync.length?o.pbkdf2(e,n,i,s,function(e,t){if(e)return l(e);l(null,t.toString("binary"))}):o.pbkdf2(e,n,i,s,a,function(e,t){if(e)return l(e);l(null,t.toString("binary"))}):4===o.pbkdf2Sync.length?o.pbkdf2Sync(e,n,i,s).toString("binary"):o.pbkdf2Sync(e,n,i,s,a).toString("binary");if(void 0!==a&&null!==a||(a="sha1"),"string"==typeof a){if(!(a in r.md.algorithms))throw new Error("Unknown hash algorithm: "+a);a=r.md[a].create()}var u=a.digestLength;if(s>4294967295*u){var c=new Error("Derived key is too long.");if(l)return l(c);throw c}var h=Math.ceil(s/u),f=s-(h-1)*u,p=r.hmac.create();p.start(a,e);var d="",m,g,y;if(!l){for(var v=1;v<=h;++v){p.start(null,null),p.update(n),p.update(r.util.int32ToBytes(v)),m=y=p.digest().getBytes();for(var b=2;b<=i;++b)p.start(null,null),p.update(y),g=p.digest().getBytes(),m=r.util.xorBytes(m,g,u),y=g;d+=v<h?m:m.substr(0,f)}return d}var v=1,b;function _(){if(v>h)return l(null,d);p.start(null,null),p.update(n),p.update(r.util.int32ToBytes(v)),m=y=p.digest().getBytes(),b=2,w()}function w(){if(b<=i)return p.start(null,null),p.update(y),g=p.digest().getBytes(),m=r.util.xorBytes(m,g,u),y=g,++b,r.util.setImmediate(w);d+=v<h?m:m.substr(0,f),++v,_()}_()}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(1),i=n(153).Reporter,o=n(0).Buffer;function s(e,t){i.call(this,t),o.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function a(e,t){if(Array.isArray(e))this.length=0,this.value=e.map(function(e){return a.isEncoderBuffer(e)||(e=new a(e,t)),this.length+=e.length,e},this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=o.byteLength(e);else{if(!o.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}r(s,i),t.DecoderBuffer=s,s.isDecoderBuffer=function e(t){if(t instanceof s)return!0;const n="object"==typeof t&&o.isBuffer(t.base)&&"DecoderBuffer"===t.constructor.name&&"number"==typeof t.offset&&"number"==typeof t.length&&"function"==typeof t.save&&"function"==typeof t.restore&&"function"==typeof t.isEmpty&&"function"==typeof t.readUInt8&&"function"==typeof t.skip&&"function"==typeof t.raw;return n},s.prototype.save=function e(){return{offset:this.offset,reporter:i.prototype.save.call(this)}},s.prototype.restore=function e(t){const n=new s(this.base);return n.offset=t.offset,n.length=this.offset,this.offset=t.offset,i.prototype.restore.call(this,t.reporter),n},s.prototype.isEmpty=function e(){return this.offset===this.length},s.prototype.readUInt8=function e(t){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(t||"DecoderBuffer overrun")},s.prototype.skip=function e(t,n){if(!(this.offset+t<=this.length))return this.error(n||"DecoderBuffer overrun");const r=new s(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+t,this.offset+=t,r},s.prototype.raw=function e(t){return this.base.slice(t?t.offset:this.offset,this.length)},t.EncoderBuffer=a,a.isEncoderBuffer=function e(t){if(t instanceof a)return!0;const n="object"==typeof t&&"EncoderBuffer"===t.constructor.name&&"number"==typeof t.length&&"function"==typeof t.join;return n},a.prototype.join=function e(t,n){return t||(t=new o(this.length)),n||(n=0),0===this.length?t:(Array.isArray(this.value)?this.value.forEach(function(e){e.join(t,n),n+=e.length}):("number"==typeof this.value?t[n]=this.value:"string"==typeof this.value?t.write(this.value,n):o.isBuffer(this.value)&&this.value.copy(t,n),n+=this.length),t)}},function(e,t,n){"use strict";const r=t;r._reverse=function e(t){const n={};return Object.keys(t).forEach(function(e){(0|e)==e&&(e|=0);const r=t[e];n[r]=e}),n},r.der=n(763)},function(e,t,n){"use strict";const r=n(1),i=n(119),o=i.base,s=i.bignum,a=i.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){o.Node.call(this,"der",e)}function c(e,t){let n=e.readUInt8(t);if(e.isError(n))return n;const r=a.tagClass[n>>6],i=0==(32&n);if(31==(31&n)){let r=n;for(n=0;128==(128&r);){if(r=e.readUInt8(t),e.isError(r))return r;n<<=7,n|=127&r}}else n&=31;const o=a.tag[n];return{cls:r,primitive:i,tag:n,tagStr:o}}function h(e,t,n){let r=e.readUInt8(n);if(e.isError(r))return r;if(!t&&128===r)return null;if(0==(128&r))return r;const i=127&r;if(i>4)return e.error("length octect is too long");r=0;for(let t=0;t<i;t++){r<<=8;const t=e.readUInt8(n);if(e.isError(t))return t;r|=t}return r}e.exports=l,l.prototype.decode=function e(t,n){return o.DecoderBuffer.isDecoderBuffer(t)||(t=new o.DecoderBuffer(t,n)),this.tree._decode(t,n)},r(u,o.Node),u.prototype._peekTag=function e(t,n,r){if(t.isEmpty())return!1;const i=t.save(),o=c(t,'Failed to peek tag: "'+n+'"');return t.isError(o)?o:(t.restore(i),o.tag===n||o.tagStr===n||o.tagStr+"of"===n||r)},u.prototype._decodeTag=function e(t,n,r){const i=c(t,'Failed to decode tag of "'+n+'"');if(t.isError(i))return i;let o=h(t,i.primitive,'Failed to get length of "'+n+'"');if(t.isError(o))return o;if(!r&&i.tag!==n&&i.tagStr!==n&&i.tagStr+"of"!==n)return t.error('Failed to match tag: "'+n+'"');if(i.primitive||null!==o)return t.skip(o,'Failed to match body of: "'+n+'"');const s=t.save(),a=this._skipUntilEnd(t,'Failed to skip indefinite length body: "'+this.tag+'"');return t.isError(a)?a:(o=t.offset-s.offset,t.restore(s),t.skip(o,'Failed to match body of: "'+n+'"'))},u.prototype._skipUntilEnd=function e(t,n){for(;;){const e=c(t,n);if(t.isError(e))return e;const r=h(t,e.primitive,n);if(t.isError(r))return r;let i;if(i=e.primitive||null!==r?t.skip(r):this._skipUntilEnd(t,n),t.isError(i))return i;if("end"===e.tagStr)break}},u.prototype._decodeList=function e(t,n,r,i){const o=[];for(;!t.isEmpty();){const e=this._peekTag(t,"end");if(t.isError(e))return e;const n=r.decode(t,"der",i);if(t.isError(n)&&e)break;o.push(n)}return o},u.prototype._decodeStr=function e(t,n){if("bitstr"===n){const e=t.readUInt8();return t.isError(e)?e:{unused:e,data:t.raw()}}if("bmpstr"===n){const e=t.raw();if(e.length%2==1)return t.error("Decoding of string type: bmpstr length mismatch");let n="";for(let t=0;t<e.length/2;t++)n+=String.fromCharCode(e.readUInt16BE(2*t));return n}if("numstr"===n){const e=t.raw().toString("ascii");return this._isNumstr(e)?e:t.error("Decoding of string type: numstr unsupported characters")}if("octstr"===n)return t.raw();if("objDesc"===n)return t.raw();if("printstr"===n){const e=t.raw().toString("ascii");return this._isPrintstr(e)?e:t.error("Decoding of string type: printstr unsupported characters")}return/str$/.test(n)?t.raw().toString():t.error("Decoding of string type: "+n+" unsupported")},u.prototype._decodeObjid=function e(t,n,r){let i;const o=[];let s=0,a=0;for(;!t.isEmpty();)a=t.readUInt8(),s<<=7,s|=127&a,0==(128&a)&&(o.push(s),s=0);128&a&&o.push(s);const l=o[0]/40|0,u=o[0]%40;if(i=r?o:[l,u].concat(o.slice(1)),n){let e=n[i.join(" ")];void 0===e&&(e=n[i.join(".")]),void 0!==e&&(i=e)}return i},u.prototype._decodeTime=function e(t,n){const r=t.raw().toString();let i,o,s,a,l,u;if("gentime"===n)i=0|r.slice(0,4),o=0|r.slice(4,6),s=0|r.slice(6,8),a=0|r.slice(8,10),l=0|r.slice(10,12),u=0|r.slice(12,14);else{if("utctime"!==n)return t.error("Decoding "+n+" time is not supported yet");i=0|r.slice(0,2),o=0|r.slice(2,4),s=0|r.slice(4,6),a=0|r.slice(6,8),l=0|r.slice(8,10),u=0|r.slice(10,12),i=i<70?2e3+i:1900+i}return Date.UTC(i,o-1,s,a,l,u,0)},u.prototype._decodeNull=function e(){return null},u.prototype._decodeBool=function e(t){const n=t.readUInt8();return t.isError(n)?n:0!==n},u.prototype._decodeInt=function e(t,n){const r=t.raw();let i=new s(r);return n&&(i=n[i.toString(10)]||i),i},u.prototype._use=function e(t,n){return"function"==typeof t&&(t=t(n)),t._getDecoder("der").tree}},function(e,t,n){"use strict";const r=n(1),i=n(0).Buffer,o=n(119),s=o.base,a=o.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new u,this.tree._init(e.body)}function u(e){s.Node.call(this,"der",e)}function c(e){return e<10?"0"+e:e}function h(e,t,n,r){let i;if("seqof"===e?e="seq":"setof"===e&&(e="set"),a.tagByName.hasOwnProperty(e))i=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return r.error("Unknown tag: "+e);i=e}return i>=31?r.error("Multi-octet tag encoding unsupported"):(t||(i|=32),i|=a.tagClassByName[n||"universal"]<<6,i)}e.exports=l,l.prototype.encode=function e(t,n){return this.tree._encode(t,n).join()},r(u,s.Node),u.prototype._encodeComposite=function e(t,n,r,o){const s=h(t,n,r,this.reporter);if(o.length<128){const e=new i(2);return e[0]=s,e[1]=o.length,this._createEncoderBuffer([e,o])}let a=1;for(let e=o.length;e>=256;e>>=8)a++;const l=new i(2+a);l[0]=s,l[1]=128|a;for(let e=1+a,t=o.length;t>0;e--,t>>=8)l[e]=255&t;return this._createEncoderBuffer([l,o])},u.prototype._encodeStr=function e(t,n){if("bitstr"===n)return this._createEncoderBuffer([0|t.unused,t.data]);if("bmpstr"===n){const e=new i(2*t.length);for(let n=0;n<t.length;n++)e.writeUInt16BE(t.charCodeAt(n),2*n);return this._createEncoderBuffer(e)}return"numstr"===n?this._isNumstr(t)?this._createEncoderBuffer(t):this.reporter.error("Encoding of string type: numstr supports only digits and space"):"printstr"===n?this._isPrintstr(t)?this._createEncoderBuffer(t):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(n)?this._createEncoderBuffer(t):"objDesc"===n?this._createEncoderBuffer(t):this.reporter.error("Encoding of string type: "+n+" unsupported")},u.prototype._encodeObjid=function e(t,n,r){if("string"==typeof t){if(!n)return this.reporter.error("string objid given, but no values map found");if(!n.hasOwnProperty(t))return this.reporter.error("objid not found in values map");t=n[t].split(/[\s.]+/g);for(let e=0;e<t.length;e++)t[e]|=0}else if(Array.isArray(t)){t=t.slice();for(let e=0;e<t.length;e++)t[e]|=0}if(!Array.isArray(t))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(t));if(!r){if(t[1]>=40)return this.reporter.error("Second objid identifier OOB");t.splice(0,2,40*t[0]+t[1])}let o=0;for(let e=0;e<t.length;e++){let n=t[e];for(o++;n>=128;n>>=7)o++}const s=new i(o);let a=s.length-1;for(let e=t.length-1;e>=0;e--){let n=t[e];for(s[a--]=127&n;(n>>=7)>0;)s[a--]=128|127&n}return this._createEncoderBuffer(s)},u.prototype._encodeTime=function e(t,n){let r;const i=new Date(t);return"gentime"===n?r=[c(i.getUTCFullYear()),c(i.getUTCMonth()+1),c(i.getUTCDate()),c(i.getUTCHours()),c(i.getUTCMinutes()),c(i.getUTCSeconds()),"Z"].join(""):"utctime"===n?r=[c(i.getUTCFullYear()%100),c(i.getUTCMonth()+1),c(i.getUTCDate()),c(i.getUTCHours()),c(i.getUTCMinutes()),c(i.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+n+" time is not supported yet"),this._encodeStr(r,"octstr")},u.prototype._encodeNull=function e(){return this._createEncoderBuffer("")},u.prototype._encodeInt=function e(t,n){if("string"==typeof t){if(!n)return this.reporter.error("String int or enum given, but no values map");if(!n.hasOwnProperty(t))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(t));t=n[t]}if("number"!=typeof t&&!i.isBuffer(t)){const e=t.toArray();!t.sign&&128&e[0]&&e.unshift(0),t=new i(e)}if(i.isBuffer(t)){let e=t.length;0===t.length&&e++;const n=new i(e);return t.copy(n),0===t.length&&(n[0]=0),this._createEncoderBuffer(n)}if(t<128)return this._createEncoderBuffer(t);if(t<256)return this._createEncoderBuffer([0,t]);let r=1;for(let e=t;e>=256;e>>=8)r++;const o=new Array(r);for(let e=o.length-1;e>=0;e--)o[e]=255&t,t>>=8;return 128&o[0]&&o.unshift(0),this._createEncoderBuffer(new i(o))},u.prototype._encodeBool=function e(t){return this._createEncoderBuffer(t?255:0)},u.prototype._use=function e(t,n){return"function"==typeof t&&(t=t(n)),t._getEncoder("der").tree},u.prototype._skipDefault=function e(t,n,r){const i=this._baseState;let o;if(null===i.default)return!1;const s=t.join();if(void 0===i.defaultBuffer&&(i.defaultBuffer=this._encodeValue(i.default,n,r).join()),s.length!==i.defaultBuffer.length)return!1;for(o=0;o<s.length;o++)if(s[o]!==i.defaultBuffer[o])return!1;return!0}},function(e,t,n){"use strict";(function(e){const r=n(119).bignum;t.toBase64=function t(n,r){let i=n.toArrayLike(e,"be",r).toString("base64");return i.replace(/(=*)$/,"").replace(/\+/g,"-").replace(/\//g,"_")},t.toBn=function t(n){return new r(e.from(n,"base64"))}}).call(this,n(0).Buffer)},function(e){e.exports={COMPRESSED_TYPE_INVALID:"compressed should be a boolean",EC_PRIVATE_KEY_TYPE_INVALID:"private key should be a Buffer",EC_PRIVATE_KEY_LENGTH_INVALID:"private key length is invalid",EC_PRIVATE_KEY_RANGE_INVALID:"private key range is invalid",EC_PRIVATE_KEY_TWEAK_ADD_FAIL:"tweak out of range or resulting private key is invalid",EC_PRIVATE_KEY_TWEAK_MUL_FAIL:"tweak out of range",EC_PRIVATE_KEY_EXPORT_DER_FAIL:"couldn't export to DER format",EC_PRIVATE_KEY_IMPORT_DER_FAIL:"couldn't import from DER format",EC_PUBLIC_KEYS_TYPE_INVALID:"public keys should be an Array",EC_PUBLIC_KEYS_LENGTH_INVALID:"public keys Array should have at least 1 element",EC_PUBLIC_KEY_TYPE_INVALID:"public key should be a Buffer",EC_PUBLIC_KEY_LENGTH_INVALID:"public key length is invalid",EC_PUBLIC_KEY_PARSE_FAIL:"the public key could not be parsed or is invalid",EC_PUBLIC_KEY_CREATE_FAIL:"private was invalid, try again",EC_PUBLIC_KEY_TWEAK_ADD_FAIL:"tweak out of range or resulting public key is invalid",EC_PUBLIC_KEY_TWEAK_MUL_FAIL:"tweak out of range",EC_PUBLIC_KEY_COMBINE_FAIL:"the sum of the public keys is not valid",ECDH_FAIL:"scalar was invalid (zero or overflow)",ECDSA_SIGNATURE_TYPE_INVALID:"signature should be a Buffer",ECDSA_SIGNATURE_LENGTH_INVALID:"signature length is invalid",ECDSA_SIGNATURE_PARSE_FAIL:"couldn't parse signature",ECDSA_SIGNATURE_PARSE_DER_FAIL:"couldn't parse DER signature",ECDSA_SIGNATURE_SERIALIZE_DER_FAIL:"couldn't serialize signature to DER format",ECDSA_SIGN_FAIL:"nonce generation function failed or private key is invalid",ECDSA_RECOVER_FAIL:"couldn't recover public key from signature",MSG32_TYPE_INVALID:"message should be a Buffer",MSG32_LENGTH_INVALID:"message length is invalid",OPTIONS_TYPE_INVALID:"options should be an Object",OPTIONS_DATA_TYPE_INVALID:"options.data should be a Buffer",OPTIONS_DATA_LENGTH_INVALID:"options.data length is invalid",OPTIONS_NONCEFN_TYPE_INVALID:"options.noncefn should be a Function",RECOVERY_ID_TYPE_INVALID:"recovery should be a Number",RECOVERY_ID_VALUE_INVALID:"recovery should have value between -1 and 4",TWEAK_TYPE_INVALID:"tweak should be a Buffer",TWEAK_LENGTH_INVALID:"tweak length is invalid"}},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(62).Transform,o=n(1);function s(e,t){if(!r.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}function a(e){i.call(this),this._block=r.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}o(a,i),a.prototype._transform=function(e,t,n){var r=null;try{this.update(e,t)}catch(e){r=e}n(r)},a.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},a.prototype.update=function(e,t){if(s(e,"Data"),this._finalized)throw new Error("Digest already called");r.isBuffer(e)||(e=r.from(e,t));for(var n=this._block,i=0;this._blockOffset+e.length-i>=this._blockSize;){for(var o=this._blockOffset;o<this._blockSize;)n[o++]=e[i++];this._update(),this._blockOffset=0}for(;i<e.length;)n[this._blockOffset++]=e[i++];for(var a=0,l=8*e.length;l>0;++a)this._length[a]+=l,l=this._length[a]/4294967296|0,l>0&&(this._length[a]-=4294967296*l);return this},a.prototype._update=function(){throw new Error("_update is not implemented")},a.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();void 0!==e&&(t=t.toString(e)),this._block.fill(0),this._blockOffset=0;for(var n=0;n<4;++n)this._length[n]=0;return t},a.prototype._digest=function(){throw new Error("_digest is not implemented")},e.exports=a},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(382),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(782),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(783),v=n(383),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(98),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(98),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";e.exports=s;var r=n(98),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){"use strict";var r=n(0).Buffer,i=n(1),o=n(380),s=new Array(16),a=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],l=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],u=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],c=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],h=[0,1518500249,1859775393,2400959708,2840853838],f=[1352829926,1548603684,1836072691,2053994217,0];function p(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function d(e,t){return e<<t|e>>>32-t}function m(e,t,n,r,i,o,s,a){return d(e+(t^n^r)+o+s|0,a)+i|0}function g(e,t,n,r,i,o,s,a){return d(e+(t&n|~t&r)+o+s|0,a)+i|0}function y(e,t,n,r,i,o,s,a){return d(e+((t|~n)^r)+o+s|0,a)+i|0}function v(e,t,n,r,i,o,s,a){return d(e+(t&r|n&~r)+o+s|0,a)+i|0}function b(e,t,n,r,i,o,s,a){return d(e+(t^(n|~r))+o+s|0,a)+i|0}i(p,o),p.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var n=0|this._a,r=0|this._b,i=0|this._c,o=0|this._d,p=0|this._e,_=0|this._a,w=0|this._b,k=0|this._c,E=0|this._d,S=0|this._e,x=0;x<80;x+=1){var C,A;x<16?(C=m(n,r,i,o,p,e[a[x]],h[0],u[x]),A=b(_,w,k,E,S,e[l[x]],f[0],c[x])):x<32?(C=g(n,r,i,o,p,e[a[x]],h[1],u[x]),A=v(_,w,k,E,S,e[l[x]],f[1],c[x])):x<48?(C=y(n,r,i,o,p,e[a[x]],h[2],u[x]),A=y(_,w,k,E,S,e[l[x]],f[2],c[x])):x<64?(C=v(n,r,i,o,p,e[a[x]],h[3],u[x]),A=g(_,w,k,E,S,e[l[x]],f[3],c[x])):(C=b(n,r,i,o,p,e[a[x]],h[4],u[x]),A=m(_,w,k,E,S,e[l[x]],f[4],c[x])),n=p,p=o,o=d(i,10),i=r,r=C,_=S,S=E,E=d(k,10),k=w,w=A}var T=this._b+i+E|0;this._b=this._c+o+S|0,this._c=this._d+p+_|0,this._d=this._e+n+w|0,this._e=this._a+r+k|0,this._a=T},p.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var e=r.alloc?r.alloc(20):new r(20);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e.writeInt32LE(this._e,16),e},e.exports=p},function(e,t,n){var t=e.exports=function e(n){n=n.toLowerCase();var r=t[n];if(!r)throw new Error(n+" is not supported (we accept pull requests)");return new r};t.sha=n(790),t.sha1=n(791),t.sha224=n(792),t.sha256=n(387),t.sha384=n(793),t.sha512=n(388)},function(e,t,n){var r=n(1),i=n(120),o=n(5).Buffer,s=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],a=new Array(64);function l(){this.init(),this._w=a,i.call(this,64,56)}function u(e,t,n){return n^e&(t^n)}function c(e,t,n){return e&t|n&(e|t)}function h(e){return(e>>>2|e<<30)^(e>>>13|e<<19)^(e>>>22|e<<10)}function f(e){return(e>>>6|e<<26)^(e>>>11|e<<21)^(e>>>25|e<<7)}function p(e){return(e>>>7|e<<25)^(e>>>18|e<<14)^e>>>3}function d(e){return(e>>>17|e<<15)^(e>>>19|e<<13)^e>>>10}r(l,i),l.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},l.prototype._update=function(e){for(var t=this._w,n=0|this._a,r=0|this._b,i=0|this._c,o=0|this._d,a=0|this._e,l=0|this._f,m=0|this._g,g=0|this._h,y=0;y<16;++y)t[y]=e.readInt32BE(4*y);for(;y<64;++y)t[y]=d(t[y-2])+t[y-7]+p(t[y-15])+t[y-16]|0;for(var v=0;v<64;++v){var b=g+f(a)+u(a,l,m)+s[v]+t[v]|0,_=h(n)+c(n,r,i)|0;g=m,m=l,l=a,a=o+b|0,o=i,i=r,r=n,n=b+_|0}this._a=n+this._a|0,this._b=r+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=a+this._e|0,this._f=l+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},l.prototype._hash=function(){var e=o.allocUnsafe(32);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e.writeInt32BE(this._h,28),e},e.exports=l},function(e,t,n){var r=n(1),i=n(120),o=n(5).Buffer,s=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],a=new Array(160);function l(){this.init(),this._w=a,i.call(this,128,112)}function u(e,t,n){return n^e&(t^n)}function c(e,t,n){return e&t|n&(e|t)}function h(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function f(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function p(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^e>>>7}function d(e,t){return(e>>>1|t<<31)^(e>>>8|t<<24)^(e>>>7|t<<25)}function m(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^e>>>6}function g(e,t){return(e>>>19|t<<13)^(t>>>29|e<<3)^(e>>>6|t<<26)}function y(e,t){return e>>>0<t>>>0?1:0}r(l,i),l.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},l.prototype._update=function(e){for(var t=this._w,n=0|this._ah,r=0|this._bh,i=0|this._ch,o=0|this._dh,a=0|this._eh,l=0|this._fh,v=0|this._gh,b=0|this._hh,_=0|this._al,w=0|this._bl,k=0|this._cl,E=0|this._dl,S=0|this._el,x=0|this._fl,C=0|this._gl,A=0|this._hl,T=0;T<32;T+=2)t[T]=e.readInt32BE(4*T),t[T+1]=e.readInt32BE(4*T+4);for(;T<160;T+=2){var I=t[T-30],j=t[T-30+1],R=p(I,j),B=d(j,I);I=t[T-4],j=t[T-4+1];var O=m(I,j),P=g(j,I),N=t[T-14],D=t[T-14+1],M=t[T-32],F=t[T-32+1],L=B+D|0,U=R+N+y(L,B)|0;L=L+P|0,U=U+O+y(L,P)|0,L=L+F|0,U=U+M+y(L,F)|0,t[T]=U,t[T+1]=L}for(var q=0;q<160;q+=2){U=t[q],L=t[q+1];var z=c(n,r,i),K=c(_,w,k),H=h(n,_),V=h(_,n),$=f(a,S),W=f(S,a),G=s[q],Y=s[q+1],Z=u(a,l,v),J=u(S,x,C),Q=A+W|0,X=b+$+y(Q,A)|0;Q=Q+J|0,X=X+Z+y(Q,J)|0,Q=Q+Y|0,X=X+G+y(Q,Y)|0,Q=Q+L|0,X=X+U+y(Q,L)|0;var ee=V+K|0,te=H+z+y(ee,V)|0;b=v,A=C,v=l,C=x,l=a,x=S,S=E+Q|0,a=o+X+y(S,E)|0,o=i,E=k,i=r,k=w,r=n,w=_,_=Q+ee|0,n=X+te+y(_,Q)|0}this._al=this._al+_|0,this._bl=this._bl+w|0,this._cl=this._cl+k|0,this._dl=this._dl+E|0,this._el=this._el+S|0,this._fl=this._fl+x|0,this._gl=this._gl+C|0,this._hl=this._hl+A|0,this._ah=this._ah+n+y(this._al,_)|0,this._bh=this._bh+r+y(this._bl,w)|0,this._ch=this._ch+i+y(this._cl,k)|0,this._dh=this._dh+o+y(this._dl,E)|0,this._eh=this._eh+a+y(this._el,S)|0,this._fh=this._fh+l+y(this._fl,x)|0,this._gh=this._gh+v+y(this._gl,C)|0,this._hh=this._hh+b+y(this._hl,A)|0},l.prototype._hash=function(){var e=o.allocUnsafe(64);function t(t,n,r){e.writeInt32BE(t,r),e.writeInt32BE(n,r+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),t(this._gh,this._gl,48),t(this._hh,this._hl,56),e},e.exports=l},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(197),o=n(390);function s(e,t){null===e&&null===t?(this.x=this.y=null,this.inf=!0):(this.x=e,this.y=t,this.inf=!1)}s.fromPublicKey=function(e){var t=e[0],n,r;return 33!==e.length||2!==t&&3!==t?65!==e.length||4!==t&&6!==t&&7!==t?null:(n=i.fromBuffer(e.slice(1,33)),r=i.fromBuffer(e.slice(33,65)),n.ucmp(i.p)>=0||r.ucmp(i.p)>=0?null:6!==t&&7!==t||r.isOdd()===(7===t)?0!==n.redSqr().redMul(n).redIAdd7().ucmp(r.redSqr())?null:new s(n,r):null):(n=i.fromBuffer(e.slice(1,33)),n.ucmp(i.p)>=0?null:(r=n.redSqr().redMul(n).redIAdd7().redSqrt(),null===r?null:(3===t!==r.isOdd()&&(r=r.redNeg()),new s(n,r))))},s.prototype.toPublicKey=function(e){var t=this.x,n=this.y,i;return e?(i=r.alloc(33),i[0]=n.isOdd()?3:2,t.toBuffer().copy(i,1)):(i=r.alloc(65),i[0]=4,t.toBuffer().copy(i,1),n.toBuffer().copy(i,33)),i},s.fromECJPoint=function(e){if(e.inf)return new s(null,null);var t=e.z.redInvm(),n=t.redSqr(),r=e.x.redMul(n),i=e.y.redMul(n).redMul(t);return new s(r,i)},s.prototype.toECJPoint=function(){return this.inf?new o(null,null,null):new o(this.x,this.y,o.one)},s.prototype.neg=function(){return this.inf?this:new s(this.x,this.y.redNeg())},s.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(0===this.x.ucmp(e.x))return 0===this.y.ucmp(e.y)?this.dbl():new s(null,null);var t=this.y.redSub(e.y);t.isZero()||(t=t.redMul(this.x.redSub(e.x).redInvm()));var n=t.redSqr().redISub(this.x).redISub(e.x),r=t.redMul(this.x.redSub(n)).redISub(this.y);return new s(n,r)},s.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(e.isZero())return new s(null,null);var t=this.x.redSqr(),n=t.redAdd(t).redIAdd(t).redMul(e.redInvm()),r=n.redSqr().redISub(this.x.redAdd(this.x)),i=n.redMul(this.x.redSub(r)).redISub(this.y);return new s(r,i)},s.prototype.mul=function(e){for(var t=this._getNAFPoints(4),n=t.points,r=e.getNAF(t.wnd),i=new o(null,null,null),a=r.length-1;a>=0;a--){for(var l=0;a>=0&&0===r[a];a--,++l);if(a>=0&&(l+=1),i=i.dblp(l),a<0)break;var u=r[a];i=u>0?i.mixedAdd(n[u-1>>1]):i.mixedAdd(n[-u-1>>1].neg())}return s.fromECJPoint(i)},s.prototype._getNAFPoints1=function(){return{wnd:1,points:[this]}},s.prototype._getNAFPoints=function(e){var t=new Array((1<<e)-1);t[0]=this;for(var n=this.dbl(),r=1;r<t.length;++r)t[r]=t[r-1].add(n);return{wnd:e,points:t}},e.exports=s},function(e,t,n){"use strict";var r=n(197);function i(e,t,n){null===e&&null===t&&null===n?(this.x=i.one,this.y=i.one,this.z=i.zero):(this.x=e,this.y=t,this.z=n),this.zOne=this.z===i.one}i.zero=r.fromNumber(0),i.one=r.fromNumber(1),i.prototype.neg=function(){return this.inf?this:new i(this.x,this.y.redNeg(),this.z)},i.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;var t=e.z.redSqr(),n=this.z.redSqr(),r=this.x.redMul(t),o=e.x.redMul(n),s=this.y.redMul(t).redMul(e.z),a=e.y.redMul(n).redMul(this.z),l=r.redSub(o),u=s.redSub(a);if(l.isZero())return u.isZero()?this.dbl():new i(null,null,null);var c=l.redSqr(),h=r.redMul(c),f=c.redMul(l),p=u.redSqr().redIAdd(f).redISub(h).redISub(h),d=u.redMul(h.redISub(p)).redISub(s.redMul(f)),m=this.z.redMul(e.z).redMul(l);return new i(p,d,m)},i.prototype.mixedAdd=function(e){if(this.inf)return e.toECJPoint();if(e.inf)return this;var t=this.z.redSqr(),n=this.x,r=e.x.redMul(t),o=this.y,s=e.y.redMul(t).redMul(this.z),a=n.redSub(r),l=o.redSub(s);if(a.isZero())return l.isZero()?this.dbl():new i(null,null,null);var u=a.redSqr(),c=n.redMul(u),h=u.redMul(a),f=l.redSqr().redIAdd(h).redISub(c).redISub(c),p=l.redMul(c.redISub(f)).redISub(o.redMul(h)),d=this.z.redMul(a);return new i(f,p,d)},i.prototype.dbl=function(){if(this.inf)return this;var e,t,n;if(this.zOne){var r=this.x.redSqr(),o=this.y.redSqr(),s=o.redSqr(),a=this.x.redAdd(o).redSqr().redISub(r).redISub(s);a=a.redIAdd(a);var l=r.redAdd(r).redIAdd(r),u=l.redSqr().redISub(a).redISub(a),c=s.redIAdd(s).redIAdd(s).redIAdd(s);e=u,t=l.redMul(a.redISub(u)).redISub(c),n=this.y.redAdd(this.y)}else{var h=this.x.redSqr(),f=this.y.redSqr(),p=f.redSqr(),d=this.x.redAdd(f).redSqr().redISub(h).redISub(p);d=d.redIAdd(d);var m=h.redAdd(h).redIAdd(h),g=m.redSqr(),y=p.redIAdd(p).redIAdd(p).redIAdd(p);e=g.redISub(d).redISub(d),t=m.redMul(d.redISub(e)).redISub(y),n=this.y.redMul(this.z),n=n.redIAdd(n)}return new i(e,t,n)},i.prototype.dblp=function(e){if(0===e||this.inf)return this;for(var t=this,n=0;n<e;n++)t=t.dbl();return t},Object.defineProperty(i.prototype,"inf",{enumerable:!0,get:function(){return this.z.isZero()}}),e.exports=i},function(e,t,n){"use strict";(function(e){const r=n(254),i=n(255),o=n(802),s={SHA1:"SHA-1",SHA256:"SHA-256",SHA512:"SHA-512"},a=(t,n,o)=>{r(i.subtle.sign({name:"HMAC"},t,n).then(t=>e.from(t)),o)};t.create=function(e,t,n){const l=s[e];r(i.subtle.importKey("raw",t,{name:"HMAC",hash:{name:l}},!1,["sign"]).then(t=>({digest(e,n){a(t,e,n)},length:o[e]})),n)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(22);function i(e){return r.isMultiaddr(e)?e:r(e)}e.exports={ensureMultiaddr:i}},function(e,t,n){var r={ECB:n(817),CBC:n(818),CFB:n(819),CFB8:n(820),CFB1:n(821),OFB:n(822),CTR:n(394),GCM:n(394)},i=n(396);for(var o in i)i[o].module=r[i[o].mode];e.exports=i},function(e,t,n){var r=n(155),i=n(5).Buffer,o=n(395);function s(e){var t=e._cipher.encryptBlockRaw(e._prev);return o(e._prev),t}var a=16;t.encrypt=function(e,t){var n=Math.ceil(t.length/16),o=e._cache.length;e._cache=i.concat([e._cache,i.allocUnsafe(16*n)]);for(var a=0;a<n;a++){var l=s(e),u=o+16*a;e._cache.writeUInt32BE(l[0],u+0),e._cache.writeUInt32BE(l[1],u+4),e._cache.writeUInt32BE(l[2],u+8),e._cache.writeUInt32BE(l[3],u+12)}var c=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),r(t,c)}},function(e,t){function n(e){for(var t=e.length,n;t--;){if(n=e.readUInt8(t),255!==n){n++,e.writeUInt8(n,t);break}e.writeUInt8(0,t)}}e.exports=n},function(e){e.exports={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128:{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},aes192:{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},aes256:{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}}},function(e,t,n){var r=n(199),i=n(5).Buffer,o=n(99),s=n(1),a=n(823),l=n(155),u=n(395);function c(e,t){var n=0;e.length!==t.length&&n++;for(var r=Math.min(e.length,t.length),i=0;i<r;++i)n+=e[i]^t[i];return n}function h(e,t,n){if(12===t.length)return e._finID=i.concat([t,i.from([0,0,0,1])]),i.concat([t,i.from([0,0,0,2])]);var r=new a(n),o=t.length,s=o%16;r.update(t),s&&(s=16-s,r.update(i.alloc(s,0))),r.update(i.alloc(8,0));var l=8*o,c=i.alloc(8);c.writeUIntBE(l,0,8),r.update(c),e._finID=r.state;var h=i.from(e._finID);return u(h),h}function f(e,t,n,s){o.call(this);var l=i.alloc(4,0);this._cipher=new r.AES(t);var u=this._cipher.encryptBlock(l);this._ghash=new a(u),n=h(this,n,u),this._prev=i.from(n),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=s,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}s(f,o),f.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=i.alloc(t,0),this._ghash.update(t))}this._called=!0;var n=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(n),this._len+=e.length,n},f.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=l(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&c(e,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=e,this._cipher.scrub()},f.prototype.getAuthTag=function e(){if(this._decrypt||!i.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},f.prototype.setAuthTag=function e(t){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=t},f.prototype.setAAD=function e(t){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(t),this._alen+=t.length},e.exports=f},function(e,t,n){var r=n(199),i=n(5).Buffer,o=n(99),s=n(1);function a(e,t,n,s){o.call(this),this._cipher=new r.AES(t),this._prev=i.from(n),this._cache=i.allocUnsafe(0),this._secCache=i.allocUnsafe(0),this._decrypt=s,this._mode=e}s(a,o),a.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},a.prototype._final=function(){this._cipher.scrub()},e.exports=a},function(e,t,n){var r=n(5).Buffer,i=n(257);function o(e,t,n,o){if(r.isBuffer(e)||(e=r.from(e,"binary")),t&&(r.isBuffer(t)||(t=r.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var s=n/8,a=r.alloc(s),l=r.alloc(o||0),u=r.alloc(0);s>0||o>0;){var c=new i;c.update(u),c.update(e),t&&c.update(t),u=c.digest();var h=0;if(s>0){var f=a.length-s;h=Math.min(s,u.length),u.copy(a,f,0,h),s-=h}if(h<u.length&&o>0){var p=l.length-o,d=Math.min(o,u.length-h);u.copy(l,p,h,h+d),o-=d}}return u.fill(0),{key:a,iv:l}}e.exports=o},function(e,t,n){"use strict";(function(t){const r=n(70),i=n(15),o=n(31);function s(e){let n;if("string"==typeof e)n=e;else if(t.isBuffer(e))n=r.encode(e).toString();else if(i.isPeerId(e))n=e.toB58String();else{if(!o.isPeerInfo(e))throw new Error("not valid PeerId or PeerInfo, or B58Str");n=e.id.toB58String()}return n}class a{constructor(){this._peers={}}has(e){const t=s(e);return Boolean(this._peers[t])}put(e,t){const n=this._peers[e.id.toB58String()];if(!n||t)return this._peers[e.id.toB58String()]=e,e;e.multiaddrs.forEach(e=>n.multiaddrs.add(e));const r=e.isConnected();return r&&n.connect(r),e.protocols.forEach(e=>n.protocols.add(e)),!n.id.privKey&&e.id.privKey&&(n.id.privKey=e.id.privKey),!n.id.pubKey&&e.id.pubKey&&(n.id.pubKey=e.id.pubKey),n}get(e){const t=s(e),n=this._peers[t];if(n)return n;throw new Error("PeerInfo not found")}getAll(){return this._peers}getAllArray(){return Object.keys(this._peers).map(e=>this._peers[e])}getMultiaddrs(e){const t=this.get(e);return t.multiaddrs.toArray()}remove(e){const t=s(e);this._peers[t]&&delete this._peers[t]}}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";n.r(t),n.d(t,"struct",function(){return K}),n.d(t,"superstruct",function(){return z}),n.d(t,"isStruct",function(){return y}),n.d(t,"StructError",function(){return r});class r extends TypeError{static format(e){const{type:t,path:n,value:r}=e,i=`Expected a value of type \`${t}\`${n.length?` for \`${n.join(".")}\``:""} but received \`${JSON.stringify(r)}\`.`;return i}constructor(e){const t=r.format(e);super(t);const{data:n,path:i,value:o,reason:s,type:a,errors:l=[]}=e;this.data=n,this.path=i,this.value=o,this.reason=s,this.type=a,this.errors=l,l.length||l.push(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack}}var i=Object.prototype.toString,o=function e(t){if(void 0===t)return"undefined";if(null===t)return"null";var n=typeof t;if("boolean"===n)return"boolean";if("string"===n)return"string";if("number"===n)return"number";if("symbol"===n)return"symbol";if("function"===n)return h(t)?"generatorfunction":"function";if(a(t))return"array";if(d(t))return"buffer";if(p(t))return"arguments";if(u(t))return"date";if(l(t))return"error";if(c(t))return"regexp";switch(s(t)){case"Symbol":return"symbol";case"Promise":return"promise";case"WeakMap":return"weakmap";case"WeakSet":return"weakset";case"Map":return"map";case"Set":return"set";case"Int8Array":return"int8array";case"Uint8Array":return"uint8array";case"Uint8ClampedArray":return"uint8clampedarray";case"Int16Array":return"int16array";case"Uint16Array":return"uint16array";case"Int32Array":return"int32array";case"Uint32Array":return"uint32array";case"Float32Array":return"float32array";case"Float64Array":return"float64array"}if(f(t))return"generator";switch(n=i.call(t),n){case"[object Object]":return"object";case"[object Map Iterator]":return"mapiterator";case"[object Set Iterator]":return"setiterator";case"[object String Iterator]":return"stringiterator";case"[object Array Iterator]":return"arrayiterator"}return n.slice(8,-1).toLowerCase().replace(/\s/g,"")};function s(e){return e.constructor?e.constructor.name:null}function a(e){return Array.isArray?Array.isArray(e):e instanceof Array}function l(e){return e instanceof Error||"string"==typeof e.message&&e.constructor&&"number"==typeof e.constructor.stackTraceLimit}function u(e){return e instanceof Date||"function"==typeof e.toDateString&&"function"==typeof e.getDate&&"function"==typeof e.setDate}function c(e){return e instanceof RegExp||"string"==typeof e.flags&&"boolean"==typeof e.ignoreCase&&"boolean"==typeof e.multiline&&"boolean"==typeof e.global}function h(e,t){return"GeneratorFunction"===s(e)}function f(e){return"function"==typeof e.throw&&"function"==typeof e.return&&"function"==typeof e.next}function p(e){try{if("number"==typeof e.length&&"function"==typeof e.callee)return!0}catch(e){if(-1!==e.message.indexOf("callee"))return!0}return!1}function d(e){return!(!e.constructor||"function"!=typeof e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const m="@@__STRUCT__@@",g="@@__KIND__@@";function y(e){return!(!e||!e[m])}function v(e,t){return"function"==typeof e?e(t):e}var b=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};class _{constructor(e,t,n){this.name=e,this.type=t,this.validate=n}}function w(e,t,n){if(y(e))return e[g];if(e instanceof _)return e;switch(o(e)){case"array":return e.length>1?D(e,t,n):j(e,t,n);case"function":return x(e,t,n);case"object":return B(e,t,n);case"string":{let r=!0,i;if(e.endsWith("?")&&(r=!1,e=e.slice(0,-1)),e.includes("|")){const r=e.split(/\s*\|\s*/g);i=M(r,t,n)}else if(e.includes("&")){const r=e.split(/\s*&\s*/g);i=F(r,t,n)}else i=N(e,t,n);return r||(i=O(i,void 0,n)),i}}throw new Error(`Invalid schema: ${e}`)}function k(e,t,n){if("array"!==o(e)||2!==e.length)throw new Error(`Invalid schema: ${e}`);const r=N("object",void 0,n),i=w(e[0],void 0,n),s=w(e[1],void 0,n),a="dict",l=`dict<${i.type},${s.type}>`,u=e=>{const n=v(t);e=n?b({},n,e):e;const[o]=r.validate(e);if(o)return o.type=l,[o];const a={},u=[];for(let t in e){const n=e[t],[r,o]=i.validate(t);if(r){const n=r.errors||[r];n.forEach(n=>{n.path=[t].concat(n.path),n.data=e,u.push(n)});continue}t=o;const[l,c]=s.validate(n);if(l){const n=l.errors||[l];n.forEach(n=>{n.path=[t].concat(n.path),n.data=e,u.push(n)})}else a[t]=c}if(u.length){const e=u[0];return e.errors=u,[e]}return[void 0,a]};return new _(a,l,u)}function E(e,t,n){if("array"!==o(e))throw new Error(`Invalid schema: ${e}`);const r="enum",i=e.map(e=>{try{return JSON.stringify(e)}catch(t){return String(e)}}).join(" | "),s=(n=v(t))=>e.includes(n)?[void 0,n]:[{data:n,path:[],value:n,type:i}];return new _(r,i,s)}function S(e,t,n){const r=E(e,void 0,n),i=j([r],t,n);return i}function x(e,t,n){if("function"!==o(e))throw new Error(`Invalid schema: ${e}`);const r="function",i="<function>",s=(n=v(t),r)=>{const s=e(n,r);let a={path:[],reason:null},l;switch(o(s)){case"boolean":l=s;break;case"string":l=!1,a.reason=s;break;case"object":l=!1,a=b({},a,s);break;default:throw new Error(`Invalid result: ${s}`)}return l?[void 0,n]:[b({type:i,value:n,data:n},a)]};return new _(r,i,s)}function C(e,t,n){const r="instance",i=`instance<${e.name}>`,o=(n=v(t))=>n instanceof e?[void 0,n]:[{data:n,path:[],value:n,type:i}];return new _(r,i,o)}function A(e,t,n){if("object"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=[],i={};for(const t in e){r.push(t);const o=e[t],s=w(o,void 0,n);i[t]=s}const s="interface",a=`{${r.join()}}`,l=e=>{const n=v(t);e=n?b({},n,e):e;const r=[],o=e;for(const n in i){let s=e[n];const a=i[n];if(void 0===s){const r=t&&t[n];s=v(r,e)}const[l,u]=a.validate(s,e);if(l){const t=l.errors||[l];t.forEach(t=>{t.path=[n].concat(t.path),t.data=e,r.push(t)})}else(n in e||void 0!==u)&&(o[n]=u)}if(r.length){const e=r[0];return e.errors=r,[e]}return[void 0,o]};return new _(s,a,l)}function T(e,t,n){if("function"!==o(e))throw new Error(`Invalid schema: ${e}`);let r,i;const s="lazy",a="lazy...",l=t=>(i=e(),r.name=i.kind,r.type=i.type,r.validate=i.validate,r.validate(t));return r=new _(s,a,l),r}function I(e,t,n){if("function"!==o(e))throw new Error(`Invalid schema: ${e}`);const r="dynamic",i="dynamic...",s=(n=v(t),r)=>{const i=e(n,r);if("function"!==o(i))throw new Error(`Invalid schema: ${i}`);const[s,a]=i.validate(n);return s?[s]:[void 0,a]};return new _(r,i,s)}function j(e,t,n){if("array"!==o(e)||1!==e.length)throw new Error(`Invalid schema: ${e}`);const r=N("array",void 0,n),i=w(e[0],void 0,n),s="list",a=`[${i.type}]`,l=(e=v(t))=>{const[n,o]=r.validate(e);if(n)return n.type=a,[n];e=o;const s=[],l=[];for(let t=0;t<e.length;t++){const n=e[t],[r,o]=i.validate(n);if(r){const n=r.errors||[r];n.forEach(n=>{n.path=[t].concat(n.path),n.data=e,s.push(n)})}else l[t]=o}if(s.length){const e=s[0];return e.errors=s,[e]}return[void 0,l]};return new _(s,a,l)}function R(e,t,n){const r="literal",i=`literal: ${JSON.stringify(e)}`,o=(n=v(t))=>n===e?[void 0,n]:[{data:n,path:[],value:n,type:i}];return new _(r,i,o)}function B(e,t,n){if("object"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=N("object",void 0,n),i=[],s={};for(const t in e){i.push(t);const r=e[t],o=w(r,void 0,n);s[t]=o}const a="object",l=`{${i.join()}}`,u=(e=v(t))=>{const[n]=r.validate(e);if(n)return n.type=l,[n];const i=[],o={},a=Object.keys(e),u=Object.keys(s),c=new Set(a.concat(u));if(c.forEach(n=>{let r=e[n];const a=s[n];if(void 0===r){const i=t&&t[n];r=v(i,e)}if(!a){const t={data:e,path:[n],value:r};return void i.push(t)}const[l,u]=a.validate(r,e);if(l){const t=l.errors||[l];t.forEach(t=>{t.path=[n].concat(t.path),t.data=e,i.push(t)})}else(n in e||void 0!==u)&&(o[n]=u)}),i.length){const e=i[0];return e.errors=i,[e]}return[void 0,o]};return new _(a,l,u)}function O(e,t,n){return M([e,"undefined"],t,n)}function P(e,t,n){if("object"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=N("object",void 0,n),i=[],s={};for(const t in e){i.push(t);const r=e[t],o=w(r,void 0,n);s[t]=o}const a="partial",l=`{${i.join()},...}`,u=(e=v(t))=>{const[n]=r.validate(e);if(n)return n.type=l,[n];const i=[],o={};for(const n in s){let r=e[n];const a=s[n];if(void 0===r){const i=t&&t[n];r=v(i,e)}const[l,u]=a.validate(r,e);if(l){const t=l.errors||[l];t.forEach(t=>{t.path=[n].concat(t.path),t.data=e,i.push(t)})}else(n in e||void 0!==u)&&(o[n]=u)}if(i.length){const e=i[0];return e.errors=i,[e]}return[void 0,o]};return new _(a,l,u)}function N(e,t,n){if("string"!==o(e))throw new Error(`Invalid schema: ${e}`);const{types:r}=n,i=r[e];if("function"!==o(i))throw new Error(`Invalid type: ${e}`);const s=x(i,t,n),a="scalar",l=e,u=e=>{const[t,n]=s.validate(e);return t?(t.type=l,[t]):[void 0,n]};return new _(a,l,u)}function D(e,t,n){if("array"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=e.map(e=>w(e,void 0,n)),i=N("array",void 0,n),s="tuple",a=`[${r.map(e=>e.type).join()}]`,l=(e=v(t))=>{const[n]=i.validate(e);if(n)return n.type=a,[n];const o=[],s=[],l=Math.max(e.length,r.length);for(let t=0;t<l;t++){const n=r[t],i=e[t];if(!n){const n={data:e,path:[t],value:i};s.push(n);continue}const[a,l]=n.validate(i);if(a){const n=a.errors||[a];n.forEach(n=>{n.path=[t].concat(n.path),n.data=e,s.push(n)})}else o[t]=l}if(s.length){const e=s[0];return e.errors=s,[e]}return[void 0,o]};return new _(s,a,l)}function M(e,t,n){if("array"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=e.map(e=>w(e,void 0,n)),i="union",s=r.map(e=>e.type).join(" | "),a=(e=v(t))=>{const n=[];for(const t of r){const[r,i]=t.validate(e);if(!r)return[void 0,i];n.push(r)}return n[0].type=s,n};return new _(i,s,a)}function F(e,t,n){if("array"!==o(e))throw new Error(`Invalid schema: ${e}`);const r=e.map(e=>w(e,void 0,n)),i="intersection",s=r.map(e=>e.type).join(" & "),a=(e=v(t))=>{let n=e;for(const e of r){const[t,r]=e.validate(n);if(t)return t.type=s,[t];n=r}return[void 0,n]};return new _(i,s,a)}const L={any:w,dict:k,enum:E,enums:S,function:x,instance:C,interface:A,lazy:T,list:j,literal:R,object:B,optional:O,partial:P,scalar:N,tuple:D,union:M,intersection:F,dynamic:I},U=["arguments","array","boolean","buffer","error","float32array","float64array","function","generatorfunction","int16array","int32array","int8array","map","null","number","object","promise","regexp","set","string","symbol","uint16array","uint32array","uint8array","uint8clampedarray","undefined","weakmap","weakset"],q={any:e=>void 0!==e};function z(e={}){const t=b({},q,e.types||{});function n(e,n,i={}){y(e)&&(e=e.schema);const o=L.any(e,n,b({},i,{types:t}));function s(e){if(this instanceof s)throw new Error("Invalid `new` keyword!");return s.assert(e)}return Object.defineProperty(s,m,{value:!0}),Object.defineProperty(s,g,{value:o}),s.kind=o.name,s.type=o.type,s.schema=e,s.defaults=n,s.options=i,s.assert=(e=>{const[t,n]=o.validate(e);if(t)throw new r(t);return n}),s.test=(e=>{const[t]=o.validate(e);return!t}),s.validate=(e=>{const[t,n]=o.validate(e);return t?[new r(t)]:[void 0,n]}),s}return Object.keys(L).forEach(e=>{const r=L[e];n[e]=((e,i,o)=>{const s=r(e,i,b({},o,{types:t})),a=n(s,i,o);return a})}),n}U.forEach(e=>{q[e]=(t=>o(t)===e)}),q.date=(e=>"date"===o(e)&&!isNaN(e));const K=z()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=f;var r=n(58),i=h(r),o=n(147),s=h(o),a=n(86),l=h(a),u=n(37),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n){n=n||i.default;var r=(0,s.default)(t)?[]:{};e(t,function(e,t,n){(0,c.default)(e)(function(e,i){arguments.length>2&&(i=(0,l.default)(arguments,1)),r[t]=i,n(e)})},function(e){n(e,r)})}e.exports=t.default},function(e,t,n){"use strict";(function(t){const r=n(121),i=n(39),o="/",s=t.from(o),a=s[0];class l{constructor(e,n){if("string"==typeof e?this._buf=t.from(e):t.isBuffer(e)&&(this._buf=e),null==n&&(n=!0),n&&this.clean(),0===this._buf.length||this._buf[0]!==a)throw new Error(`Invalid key: ${this.toString()}`)}toString(e){return this._buf.toString(e||"utf8")}toBuffer(){return this._buf}get[Symbol.toStringTag](){return`[Key ${this.toString()}]`}static withNamespaces(e){return new h(e.join(o))}static random(){return new h(r().replace(/-/g,""))}clean(){for(this._buf&&0!==this._buf.length||(this._buf=t.from(o)),this._buf[0]!==a&&(this._buf=t.concat([s,this._buf]));this._buf.length>1&&this._buf[this._buf.length-1]===a;)this._buf=this._buf.slice(0,-1)}less(e){const t=this.list(),n=e.list();for(let e=0;e<t.length;e++){if(n.length<e+1)return!1;const r=t[e],i=n[e];if(r<i)return!0;if(r>i)return!1}return t.length<n.length}reverse(){return l.withNamespaces(this.list().slice().reverse())}namespaces(){return this.list()}baseNamespace(){const e=this.namespaces();return e[e.length-1]}list(){return this.toString().split(o).slice(1)}type(){return u(this.baseNamespace())}name(){return c(this.baseNamespace())}instance(e){return new h(this.toString()+":"+e)}path(){let e=this.parent().toString();return e.endsWith(o)||(e+=o),e+=this.type(),new h(e)}parent(){const e=this.list();return 1===e.length?new h(o):new h(e.slice(0,-1).join(o))}child(e){return this.toString()===o?e:e.toString()===o?this:new h(this.toString()+e.toString(),!1)}isAncestorOf(e){return e.toString()!==this.toString()&&e.toString().startsWith(this.toString())}isDecendantOf(e){return e.toString()!==this.toString()&&this.toString().startsWith(e.toString())}isTopLevel(){return 1===this.list().length}}function u(e){const t=e.split(":");return t.length<2?"":t.slice(0,-1).join(":")}function c(e){const t=e.split(":");return t[t.length-1]}const h=i(l,{className:"Key",symbolName:"@ipfs/interface-datastore/key"});e.exports=h}).call(this,n(0).Buffer)},function(e,t){var n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(n){var r=new Uint8Array(16);e.exports=function e(){return n(r),r}}else{var i=new Array(16);e.exports=function e(){for(var t=0,n;t<16;t++)0==(3&t)&&(n=4294967296*Math.random()),i[t]=n>>>((3&t)<<3)&255;return i}}},function(e,t){for(var n=[],r=0;r<256;++r)n[r]=(r+256).toString(16).substr(1);function i(e,t){var r=t||0,i=n;return[i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],"-",i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]],i[e[r++]]].join("")}e.exports=i},function(e,t,n){"use strict";const r=n(13);e.exports.dbOpenFailedError=(e=>(e=e||new Error("Cannot open database"),r(e,"ERR_DB_OPEN_FAILED"))),e.exports.dbDeleteFailedError=(e=>(e=e||new Error("Delete failed"),r(e,"ERR_DB_DELETE_FAILED"))),e.exports.dbWriteFailedError=(e=>(e=e||new Error("Write failed"),r(e,"ERR_DB_WRITE_FAILED"))),e.exports.notFoundError=(e=>(e=e||new Error("Not Found"),r(e,"ERR_NOT_FOUND")))},function(e,t,n){"use strict";const r=n(203),i=n(839),o=n(841),s=n(843),a=n(844),l=n(408);t.KeytransformDatastore=r,t.ShardingDatastore=i,t.MountDatastore=o,t.TieredDatastore=s,t.NamespaceDatastore=a,t.shard=l},function(e,t,n){"use strict";const r=n(28).Key,i=n(840),o=t.PREFIX="/repo/flatfs/shard/",s=t.SHARDING_FN="SHARDING";t.README_FN="_README";class a{constructor(e){this.param=e}fun(e){throw new Error("implement me")}toString(){return`${o}v1/${this.name}/${this.param}`}}class l extends a{constructor(e){super(e),this._padding="".padStart(e,"_"),this.name="prefix"}fun(e){return(e+this._padding).slice(0,this.param)}}class u extends a{constructor(e){super(e),this._padding="".padStart(e,"_"),this.name="suffix"}fun(e){const t=this._padding+e;return t.slice(t.length-this.param)}}class c extends a{constructor(e){super(e),this._padding="".padStart(e+1,"_"),this.name="next-to-last"}fun(e){const t=this._padding+e,n=t.length-this.param-1;return t.slice(n,n+this.param)}}function h(e){if(e=e.trim(),0===e.length)throw new Error("empty shard string");if(!e.startsWith(o))throw new Error(`invalid or no path prefix: ${e}`);const t=e.slice(o.length).split("/"),n=t[0];if("v1"!==n)throw new Error(`expect 'v1' version, got '${n}'`);const r=t[1];if(!t[2])throw new Error("missing param");const i=parseInt(t[2],10);switch(r){case"prefix":return new l(i);case"suffix":return new u(i);case"next-to-last":return new c(i);default:throw new Error(`unkown sharding function: ${r}`)}}t.readShardFun=((e,t,n)=>{const i=new r(e).child(new r(s)),o="function"==typeof t.getRaw?t.getRaw.bind(t):t.get.bind(t);o(i,(e,t)=>{if(e)return n(e);let r;try{r=h((t||"").toString().trim())}catch(e){return n(e)}n(null,r)})}),t.readme=i,t.parseShardFun=h,t.Prefix=l,t.Suffix=u,t.NextToLast=c},function(e,t,n){"use strict";var r=function(e,t){return t||(t={}),e.split("").forEach(function(e,n){e in t||(t[e]=n)}),t},i={alphabet:"ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",charmap:{0:14,1:8}};i.charmap=r(i.alphabet,i.charmap);var o={alphabet:"0123456789ABCDEFGHJKMNPQRSTVWXYZ",charmap:{O:0,I:1,L:1}};o.charmap=r(o.alphabet,o.charmap);var s={alphabet:"0123456789ABCDEFGHIJKLMNOPQRSTUV",charmap:{}};function a(e){if(this.buf=[],this.shift=8,this.carry=0,e){switch(e.type){case"rfc4648":this.charmap=t.rfc4648.charmap;break;case"crockford":this.charmap=t.crockford.charmap;break;case"base32hex":this.charmap=t.base32hex.charmap;break;default:throw new Error("invalid type")}e.charmap&&(this.charmap=e.charmap)}}function l(e){if(this.buf="",this.shift=3,this.carry=0,e){switch(e.type){case"rfc4648":this.alphabet=t.rfc4648.alphabet;break;case"crockford":this.alphabet=t.crockford.alphabet;break;case"base32hex":this.alphabet=t.base32hex.alphabet;break;default:throw new Error("invalid type")}e.alphabet?this.alphabet=e.alphabet:e.lc&&(this.alphabet=this.alphabet.toLowerCase())}}s.charmap=r(s.alphabet,s.charmap),a.prototype.charmap=i.charmap,a.prototype.write=function(e){var t=this.charmap,n=this.buf,r=this.shift,i=this.carry;return e.toUpperCase().split("").forEach(function(e){if("="!=e){var o=255&t[e];r-=5,r>0?i|=o<<r:r<0?(n.push(i|o>>-r),r+=8,i=o<<r&255):(n.push(i|o),r=8,i=0)}}),this.shift=r,this.carry=i,this},a.prototype.finalize=function(e){return e&&this.write(e),8!==this.shift&&0!==this.carry&&(this.buf.push(this.carry),this.shift=8,this.carry=0),this.buf},l.prototype.alphabet=i.alphabet,l.prototype.write=function(e){var t=this.shift,n=this.carry,r,i,o;for(o=0;o<e.length;o++)i=e[o],r=n|i>>t,this.buf+=this.alphabet[31&r],t>5&&(t-=5,r=i>>t,this.buf+=this.alphabet[31&r]),t=5-t,n=i<<t,t=8-t;return this.shift=t,this.carry=n,this},l.prototype.finalize=function(e){return e&&this.write(e),3!==this.shift&&(this.buf+=this.alphabet[31&this.carry],this.shift=3,this.carry=0),this.buf},t.encode=function(e,t){return new l(t).finalize(e)},t.decode=function(e,t){return new a(t).finalize(e)},t.Decoder=a,t.Encoder=l,t.charmap=r,t.crockford=o,t.rfc4648=i,t.base32hex=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(845),i=a(r),o=n(110),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default),e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=g;var r=n(412),i=p(r),o=n(147),s=p(o),a=n(413),l=p(a),u=n(58),c=p(u),h=n(37),f=p(h);function p(e){return e&&e.__esModule?e:{default:e}}function d(e,t,n,r){var i=new Array(t.length);e(t,function(e,t,r){n(e,function(e,n){i[t]=!!n,r(e)})},function(e){if(e)return r(e);for(var n=[],o=0;o<t.length;o++)i[o]&&n.push(t[o]);r(null,n)})}function m(e,t,n,r){var o=[];e(t,function(e,t,r){n(e,function(n,i){n?r(n):(i&&o.push({index:t,value:e}),r())})},function(e){e?r(e):r(null,(0,i.default)(o.sort(function(e,t){return e.index-t.index}),(0,l.default)("value")))})}function g(e,t,n,r){var i=(0,s.default)(t)?d:m;i(e,t,(0,f.default)(n),r||c.default)}e.exports=t.default},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}e.exports=n},function(e,t){function n(e){return function(t){return null==t?void 0:t[e]}}e.exports=n},function(e,t,n){t.AbstractLevelDOWN=n(851),t.AbstractIterator=n(415),t.AbstractChainedBatch=n(416)},function(e,t,n){(function(t){function n(e){if("object"!=typeof e||null===e)throw new TypeError("First argument must be an abstract-leveldown compliant store");this.db=e,this._ended=!1,this._nexting=!1}n.prototype.next=function(e){var n=this;if("function"!=typeof e)throw new Error("next() requires a callback argument");return n._ended?(t.nextTick(e,new Error("cannot call next() after end()")),n):n._nexting?(t.nextTick(e,new Error("cannot call next() before previous next() has completed")),n):(n._nexting=!0,n._next(function(){n._nexting=!1,e.apply(null,arguments)}),n)},n.prototype._next=function(e){t.nextTick(e)},n.prototype.seek=function(e){if(this._ended)throw new Error("cannot call seek() after end()");if(this._nexting)throw new Error("cannot call seek() before next() has completed");e=this.db._serializeKey(e),this._seek(e)},n.prototype._seek=function(e){},n.prototype.end=function(e){if("function"!=typeof e)throw new Error("end() requires a callback argument");if(this._ended)return t.nextTick(e,new Error("end() already called on iterator"));this._ended=!0,this._end(e)},n.prototype._end=function(e){t.nextTick(e)},e.exports=n}).call(this,n(3))},function(e,t){function n(e){if("object"!=typeof e||null===e)throw new TypeError("First argument must be an abstract-leveldown compliant store");this.db=e,this._operations=[],this._written=!1}n.prototype._checkWritten=function(){if(this._written)throw new Error("write() already called on this batch")},n.prototype.put=function(e,t){this._checkWritten();var n=this.db._checkKey(e)||this.db._checkValue(t);if(n)throw n;return e=this.db._serializeKey(e),t=this.db._serializeValue(t),this._put(e,t),this},n.prototype._put=function(e,t){this._operations.push({type:"put",key:e,value:t})},n.prototype.del=function(e){this._checkWritten();var t=this.db._checkKey(e);if(t)throw t;return e=this.db._serializeKey(e),this._del(e),this},n.prototype._del=function(e){this._operations.push({type:"del",key:e})},n.prototype.clear=function(){return this._checkWritten(),this._clear(),this},n.prototype._clear=function(){this._operations=[]},n.prototype.write=function(e,t){if(this._checkWritten(),"function"==typeof e&&(t=e),"function"!=typeof t)throw new Error("write() requires a callback argument");"object"==typeof e&&null!==e||(e={}),this._written=!0,this._write(e,t)},n.prototype._write=function(e,t){this.db._batch(this._operations,e,t)},e.exports=n},function(e,t){function n(){var e,t=new Promise(function(t,n){e=function e(r,i){r?n(r):t(i)}});return e.promise=t,e}e.exports=n},function(e,t,n){(function(t){function n(e){if("object"!=typeof e||null===e)throw new TypeError("First argument must be an abstract-leveldown compliant store");this.db=e,this._ended=!1,this._nexting=!1}n.prototype.next=function(e){var n=this;if("function"!=typeof e)throw new Error("next() requires a callback argument");return n._ended?(t.nextTick(e,new Error("cannot call next() after end()")),n):n._nexting?(t.nextTick(e,new Error("cannot call next() before previous next() has completed")),n):(n._nexting=!0,n._next(function(){n._nexting=!1,e.apply(null,arguments)}),n)},n.prototype._next=function(e){t.nextTick(e)},n.prototype.seek=function(e){if(this._ended)throw new Error("cannot call seek() after end()");if(this._nexting)throw new Error("cannot call seek() before next() has completed");e=this.db._serializeKey(e),this._seek(e)},n.prototype._seek=function(e){},n.prototype.end=function(e){if("function"!=typeof e)throw new Error("end() requires a callback argument");if(this._ended)return t.nextTick(e,new Error("end() already called on iterator"));this._ended=!0,this._end(e)},n.prototype._end=function(e){t.nextTick(e)},e.exports=n}).call(this,n(3))},function(e,t){function n(e){if("object"!=typeof e||null===e)throw new TypeError("First argument must be an abstract-leveldown compliant store");this.db=e,this._operations=[],this._written=!1}n.prototype._checkWritten=function(){if(this._written)throw new Error("write() already called on this batch")},n.prototype.put=function(e,t){this._checkWritten();var n=this.db._checkKey(e)||this.db._checkValue(t);if(n)throw n;return e=this.db._serializeKey(e),t=this.db._serializeValue(t),this._put(e,t),this},n.prototype._put=function(e,t){this._operations.push({type:"put",key:e,value:t})},n.prototype.del=function(e){this._checkWritten();var t=this.db._checkKey(e);if(t)throw t;return e=this.db._serializeKey(e),this._del(e),this},n.prototype._del=function(e){this._operations.push({type:"del",key:e})},n.prototype.clear=function(){return this._checkWritten(),this._clear(),this},n.prototype._clear=function(){this._operations=[]},n.prototype.write=function(e,t){if(this._checkWritten(),"function"==typeof e&&(t=e),"function"!=typeof t)throw new Error("write() requires a callback argument");"object"==typeof e&&null!==e||(e={}),this._written=!0,this._write(e,t)},n.prototype._write=function(e,t){this.db._batch(this._operations,e,t)},e.exports=n},function(e,t,n){t.AbstractLevelDOWN=n(421),t.AbstractIterator=n(422),t.AbstractChainedBatch=n(423),t.isLevelDOWN=n(863)},function(e,t,n){(function(t,r){var i=n(68),o=n(422),s=n(423);function a(e){if(!arguments.length||void 0===e)throw new Error("constructor requires at least a location argument");if("string"!=typeof e)throw new Error("constructor requires a location string argument");this.location=e,this.status="new"}a.prototype.open=function(e,n){var r=this,i=this.status;if("function"==typeof e&&(n=e),"function"!=typeof n)throw new Error("open() requires a callback argument");"object"!=typeof e&&(e={}),e.createIfMissing=0!=e.createIfMissing,e.errorIfExists=!!e.errorIfExists,"function"==typeof this._open?(this.status="opening",this._open(e,function(e){if(e)return r.status=i,n(e);r.status="open",n()})):(this.status="open",t.nextTick(n))},a.prototype.close=function(e){var n=this,r=this.status;if("function"!=typeof e)throw new Error("close() requires a callback argument");"function"==typeof this._close?(this.status="closing",this._close(function(t){if(t)return n.status=r,e(t);n.status="closed",e()})):(this.status="closed",t.nextTick(e))},a.prototype.get=function(e,n,r){var i;if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("get() requires a callback argument");return(i=this._checkKey(e,"key",this._isBuffer))?r(i):(this._isBuffer(e)||(e=String(e)),"object"!=typeof n&&(n={}),n.asBuffer=0!=n.asBuffer,"function"==typeof this._get?this._get(e,n,r):void t.nextTick(function(){r(new Error("NotFound"))}))},a.prototype.put=function(e,n,r,i){var o;if("function"==typeof r&&(i=r),"function"!=typeof i)throw new Error("put() requires a callback argument");return(o=this._checkKey(e,"key",this._isBuffer))?i(o):(this._isBuffer(e)||(e=String(e)),null==n||this._isBuffer(n)||t.browser||(n=String(n)),"object"!=typeof r&&(r={}),"function"==typeof this._put?this._put(e,n,r,i):void t.nextTick(i))},a.prototype.del=function(e,n,r){var i;if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("del() requires a callback argument");return(i=this._checkKey(e,"key",this._isBuffer))?r(i):(this._isBuffer(e)||(e=String(e)),"object"!=typeof n&&(n={}),"function"==typeof this._del?this._del(e,n,r):void t.nextTick(r))},a.prototype.batch=function(e,n,r){if(!arguments.length)return this._chainedBatch();if("function"==typeof n&&(r=n),"function"==typeof e&&(r=e),"function"!=typeof r)throw new Error("batch(array) requires a callback argument");if(!Array.isArray(e))return r(new Error("batch(array) requires an array argument"));n&&"object"==typeof n||(n={});for(var i=0,o=e.length,s,a;i<o;i++)if(s=e[i],"object"==typeof s){if(a=this._checkKey(s.type,"type",this._isBuffer))return r(a);if(a=this._checkKey(s.key,"key",this._isBuffer))return r(a)}if("function"==typeof this._batch)return this._batch(e,n,r);t.nextTick(r)},a.prototype.approximateSize=function(e,n,r){if(null==e||null==n||"function"==typeof e||"function"==typeof n)throw new Error("approximateSize() requires valid `start`, `end` and `callback` arguments");if("function"!=typeof r)throw new Error("approximateSize() requires a callback argument");if(this._isBuffer(e)||(e=String(e)),this._isBuffer(n)||(n=String(n)),"function"==typeof this._approximateSize)return this._approximateSize(e,n,r);t.nextTick(function(){r(null,0)})},a.prototype._setupIteratorOptions=function(e){var t=this;return e=i(e),["start","end","gt","gte","lt","lte"].forEach(function(n){e[n]&&t._isBuffer(e[n])&&0===e[n].length&&delete e[n]}),e.reverse=!!e.reverse,e.keys=0!=e.keys,e.values=0!=e.values,e.limit="limit"in e?e.limit:-1,e.keyAsBuffer=0!=e.keyAsBuffer,e.valueAsBuffer=0!=e.valueAsBuffer,e},a.prototype.iterator=function(e){return"object"!=typeof e&&(e={}),e=this._setupIteratorOptions(e),"function"==typeof this._iterator?this._iterator(e):new o(this)},a.prototype._chainedBatch=function(){return new s(this)},a.prototype._isBuffer=function(e){return r.isBuffer(e)},a.prototype._checkKey=function(e,t){if(null===e||void 0===e)return new Error(t+" cannot be `null` or `undefined`");if(this._isBuffer(e)){if(0===e.length)return new Error(t+" cannot be an empty Buffer")}else if(""===String(e))return new Error(t+" cannot be an empty String")},e.exports=a}).call(this,n(3),n(0).Buffer)},function(e,t,n){(function(t){function n(e){this.db=e,this._ended=!1,this._nexting=!1}n.prototype.next=function(e){var n=this;if("function"!=typeof e)throw new Error("next() requires a callback argument");return n._ended?e(new Error("cannot call next() after end()")):n._nexting?e(new Error("cannot call next() before previous next() has completed")):(n._nexting=!0,"function"==typeof n._next?n._next(function(){n._nexting=!1,e.apply(null,arguments)}):void t.nextTick(function(){n._nexting=!1,e()}))},n.prototype.end=function(e){if("function"!=typeof e)throw new Error("end() requires a callback argument");return this._ended?e(new Error("end() already called on iterator")):(this._ended=!0,"function"==typeof this._end?this._end(e):void t.nextTick(e))},e.exports=n}).call(this,n(3))},function(e,t,n){(function(t){function n(e){this._db=e,this._operations=[],this._written=!1}n.prototype._checkWritten=function(){if(this._written)throw new Error("write() already called on this batch")},n.prototype.put=function(e,t){this._checkWritten();var n=this._db._checkKey(e,"key",this._db._isBuffer);if(n)throw n;return this._db._isBuffer(e)||(e=String(e)),this._db._isBuffer(t)||(t=String(t)),"function"==typeof this._put?this._put(e,t):this._operations.push({type:"put",key:e,value:t}),this},n.prototype.del=function(e){this._checkWritten();var t=this._db._checkKey(e,"key",this._db._isBuffer);if(t)throw t;return this._db._isBuffer(e)||(e=String(e)),"function"==typeof this._del?this._del(e):this._operations.push({type:"del",key:e}),this},n.prototype.clear=function(){return this._checkWritten(),this._operations=[],"function"==typeof this._clear&&this._clear(),this},n.prototype.write=function(e,n){if(this._checkWritten(),"function"==typeof e&&(n=e),"function"!=typeof n)throw new Error("write() requires a callback argument");return"object"!=typeof e&&(e={}),this._written=!0,"function"==typeof this._write?this._write(n):"function"==typeof this._db._batch?this._db._batch(this._operations,e,n):void t.nextTick(n)},e.exports=n}).call(this,n(3))},function(e,t,n){"use strict";const r=n(4),i=n(20),o=r("repo:lock"),s="repo.lock",a={};t.lock=((e,t)=>{const n=e+"/"+s;o("locking %s",n),a[n]=!0;const r={close(e){a[n]&&delete a[n],i(e)}};i(()=>{t(null,r)})}),t.locked=((e,t)=>{const n=e+"/"+s;o("checking lock: %s");const r=a[n];i(()=>{t(null,r)})})},function(e,t,n){"use strict";e.exports=n(872)},function(e,t,n){"use strict";function r(e,t){return t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t,n){var r=n(21);n(196),n(117),n(252),n(97),n(881),n(152),n(253),n(883),n(250),n(30);var i=r.asn1,o=e.exports=r.pki=r.pki||{},s=o.oids,a={};a.CN=s.commonName,a.commonName="CN",a.C=s.countryName,a.countryName="C",a.L=s.localityName,a.localityName="L",a.ST=s.stateOrProvinceName,a.stateOrProvinceName="ST",a.O=s.organizationName,a.organizationName="O",a.OU=s.organizationalUnitName,a.organizationalUnitName="OU",a.E=s.emailAddress,a.emailAddress="E";var l=r.pki.rsa.publicKeyValidator,u={name:"Certificate",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"Certificate.TBSCertificate",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"tbsCertificate",value:[{name:"Certificate.TBSCertificate.version",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,constructed:!0,optional:!0,value:[{name:"Certificate.TBSCertificate.version.integer",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"certVersion"}]},{name:"Certificate.TBSCertificate.serialNumber",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"certSerialNumber"},{name:"Certificate.TBSCertificate.signature",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"Certificate.TBSCertificate.signature.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"certinfoSignatureOid"},{name:"Certificate.TBSCertificate.signature.parameters",tagClass:i.Class.UNIVERSAL,optional:!0,captureAsn1:"certinfoSignatureParams"}]},{name:"Certificate.TBSCertificate.issuer",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"certIssuer"},{name:"Certificate.TBSCertificate.validity",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"Certificate.TBSCertificate.validity.notBefore (utc)",tagClass:i.Class.UNIVERSAL,type:i.Type.UTCTIME,constructed:!1,optional:!0,capture:"certValidity1UTCTime"},{name:"Certificate.TBSCertificate.validity.notBefore (generalized)",tagClass:i.Class.UNIVERSAL,type:i.Type.GENERALIZEDTIME,constructed:!1,optional:!0,capture:"certValidity2GeneralizedTime"},{name:"Certificate.TBSCertificate.validity.notAfter (utc)",tagClass:i.Class.UNIVERSAL,type:i.Type.UTCTIME,constructed:!1,optional:!0,capture:"certValidity3UTCTime"},{name:"Certificate.TBSCertificate.validity.notAfter (generalized)",tagClass:i.Class.UNIVERSAL,type:i.Type.GENERALIZEDTIME,constructed:!1,optional:!0,capture:"certValidity4GeneralizedTime"}]},{name:"Certificate.TBSCertificate.subject",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"certSubject"},l,{name:"Certificate.TBSCertificate.issuerUniqueID",tagClass:i.Class.CONTEXT_SPECIFIC,type:1,constructed:!0,optional:!0,value:[{name:"Certificate.TBSCertificate.issuerUniqueID.id",tagClass:i.Class.UNIVERSAL,type:i.Type.BITSTRING,constructed:!1,captureBitStringValue:"certIssuerUniqueId"}]},{name:"Certificate.TBSCertificate.subjectUniqueID",tagClass:i.Class.CONTEXT_SPECIFIC,type:2,constructed:!0,optional:!0,value:[{name:"Certificate.TBSCertificate.subjectUniqueID.id",tagClass:i.Class.UNIVERSAL,type:i.Type.BITSTRING,constructed:!1,captureBitStringValue:"certSubjectUniqueId"}]},{name:"Certificate.TBSCertificate.extensions",tagClass:i.Class.CONTEXT_SPECIFIC,type:3,constructed:!0,captureAsn1:"certExtensions",optional:!0}]},{name:"Certificate.signatureAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"Certificate.signatureAlgorithm.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"certSignatureOid"},{name:"Certificate.TBSCertificate.signature.parameters",tagClass:i.Class.UNIVERSAL,optional:!0,captureAsn1:"certSignatureParams"}]},{name:"Certificate.signatureValue",tagClass:i.Class.UNIVERSAL,type:i.Type.BITSTRING,constructed:!1,captureBitStringValue:"certSignature"}]},c={name:"rsapss",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"rsapss.hashAlgorithm",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,constructed:!0,value:[{name:"rsapss.hashAlgorithm.AlgorithmIdentifier",tagClass:i.Class.UNIVERSAL,type:i.Class.SEQUENCE,constructed:!0,optional:!0,value:[{name:"rsapss.hashAlgorithm.AlgorithmIdentifier.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"hashOid"}]}]},{name:"rsapss.maskGenAlgorithm",tagClass:i.Class.CONTEXT_SPECIFIC,type:1,constructed:!0,value:[{name:"rsapss.maskGenAlgorithm.AlgorithmIdentifier",tagClass:i.Class.UNIVERSAL,type:i.Class.SEQUENCE,constructed:!0,optional:!0,value:[{name:"rsapss.maskGenAlgorithm.AlgorithmIdentifier.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"maskGenOid"},{name:"rsapss.maskGenAlgorithm.AlgorithmIdentifier.params",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"rsapss.maskGenAlgorithm.AlgorithmIdentifier.params.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"maskGenHashOid"}]}]}]},{name:"rsapss.saltLength",tagClass:i.Class.CONTEXT_SPECIFIC,type:2,optional:!0,value:[{name:"rsapss.saltLength.saltLength",tagClass:i.Class.UNIVERSAL,type:i.Class.INTEGER,constructed:!1,capture:"saltLength"}]},{name:"rsapss.trailerField",tagClass:i.Class.CONTEXT_SPECIFIC,type:3,optional:!0,value:[{name:"rsapss.trailer.trailer",tagClass:i.Class.UNIVERSAL,type:i.Class.INTEGER,constructed:!1,capture:"trailer"}]}]},h={name:"CertificationRequestInfo",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"certificationRequestInfo",value:[{name:"CertificationRequestInfo.integer",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"certificationRequestInfoVersion"},{name:"CertificationRequestInfo.subject",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"certificationRequestInfoSubject"},l,{name:"CertificationRequestInfo.attributes",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,constructed:!0,optional:!0,capture:"certificationRequestInfoAttributes",value:[{name:"CertificationRequestInfo.attributes",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"CertificationRequestInfo.attributes.type",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1},{name:"CertificationRequestInfo.attributes.value",tagClass:i.Class.UNIVERSAL,type:i.Type.SET,constructed:!0}]}]}]},f={name:"CertificationRequest",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"csr",value:[h,{name:"CertificationRequest.signatureAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"CertificationRequest.signatureAlgorithm.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"csrSignatureOid"},{name:"CertificationRequest.signatureAlgorithm.parameters",tagClass:i.Class.UNIVERSAL,optional:!0,captureAsn1:"csrSignatureParams"}]},{name:"CertificationRequest.signature",tagClass:i.Class.UNIVERSAL,type:i.Type.BITSTRING,constructed:!1,captureBitStringValue:"csrSignature"}]};function p(e,t){"string"==typeof t&&(t={shortName:t});for(var n=null,r,i=0;null===n&&i<e.attributes.length;++i)r=e.attributes[i],t.type&&t.type===r.type?n=r:t.name&&t.name===r.name?n=r:t.shortName&&t.shortName===r.shortName&&(n=r);return n}o.RDNAttributesAsArray=function(e,t){for(var n=[],r,o,l,u=0;u<e.value.length;++u){r=e.value[u];for(var c=0;c<r.value.length;++c)l={},o=r.value[c],l.type=i.derToOid(o.value[0].value),l.value=o.value[1].value,l.valueTagClass=o.value[1].type,l.type in s&&(l.name=s[l.type],l.name in a&&(l.shortName=a[l.name])),t&&(t.update(l.type),t.update(l.value)),n.push(l)}return n},o.CRIAttributesAsArray=function(e){for(var t=[],n=0;n<e.length;++n)for(var r=e[n],l=i.derToOid(r.value[0].value),u=r.value[1].value,c=0;c<u.length;++c){var h={};if(h.type=l,h.value=u[c].value,h.valueTagClass=u[c].type,h.type in s&&(h.name=s[h.type],h.name in a&&(h.shortName=a[h.name])),h.type===s.extensionRequest){h.extensions=[];for(var f=0;f<h.value.length;++f)h.extensions.push(o.certificateExtensionFromAsn1(h.value[f]))}t.push(h)}return t};var d=function(e,t,n){var r={};if(e!==s["RSASSA-PSS"])return r;n&&(r={hash:{algorithmOid:s.sha1},mgf:{algorithmOid:s.mgf1,hash:{algorithmOid:s.sha1}},saltLength:20});var o={},a=[];if(!i.validate(t,c,o,a)){var l=new Error("Cannot read RSASSA-PSS parameter block.");throw l.errors=a,l}return void 0!==o.hashOid&&(r.hash=r.hash||{},r.hash.algorithmOid=i.derToOid(o.hashOid)),void 0!==o.maskGenOid&&(r.mgf=r.mgf||{},r.mgf.algorithmOid=i.derToOid(o.maskGenOid),r.mgf.hash=r.mgf.hash||{},r.mgf.hash.algorithmOid=i.derToOid(o.maskGenHashOid)),void 0!==o.saltLength&&(r.saltLength=o.saltLength.charCodeAt(0)),r};function m(e){for(var t=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]),n,o,s=e.attributes,a=0;a<s.length;++a){n=s[a];var l=n.value,u=i.Type.PRINTABLESTRING;"valueTagClass"in n&&(u=n.valueTagClass,u===i.Type.UTF8&&(l=r.util.encodeUtf8(l))),o=i.create(i.Class.UNIVERSAL,i.Type.SET,!0,[i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(n.type).getBytes()),i.create(i.Class.UNIVERSAL,u,!1,l)])]),t.value.push(o)}return t}function g(e){for(var t={},n=0;n<e.length;++n){var o=e[n];if(o.shortName&&(o.valueTagClass===i.Type.UTF8||o.valueTagClass===i.Type.PRINTABLESTRING||o.valueTagClass===i.Type.IA5STRING)){var s=o.value;o.valueTagClass===i.Type.UTF8&&(s=r.util.encodeUtf8(o.value)),o.shortName in t?r.util.isArray(t[o.shortName])?t[o.shortName].push(s):t[o.shortName]=[t[o.shortName],s]:t[o.shortName]=s}}return t}function y(e){for(var t,n=0;n<e.length;++n){if(t=e[n],void 0===t.name&&(t.type&&t.type in o.oids?t.name=o.oids[t.type]:t.shortName&&t.shortName in a&&(t.name=o.oids[a[t.shortName]])),void 0===t.type){if(!(t.name&&t.name in o.oids)){var r=new Error("Attribute type not specified.");throw r.attribute=t,r}t.type=o.oids[t.name]}if(void 0===t.shortName&&t.name&&t.name in a&&(t.shortName=a[t.name]),t.type===s.extensionRequest&&(t.valueConstructed=!0,t.valueTagClass=i.Type.SEQUENCE,!t.value&&t.extensions)){t.value=[];for(var l=0;l<t.extensions.length;++l)t.value.push(o.certificateExtensionToAsn1(v(t.extensions[l])))}if(void 0===t.value){var r=new Error("Attribute value not specified.");throw r.attribute=t,r}}}function v(e,t){if(t=t||{},void 0===e.name&&e.id&&e.id in o.oids&&(e.name=o.oids[e.id]),void 0===e.id){if(!(e.name&&e.name in o.oids)){var n=new Error("Extension ID not specified.");throw n.extension=e,n}e.id=o.oids[e.name]}if(void 0!==e.value)return e;if("keyUsage"===e.name){var a=0,l=0,u=0;e.digitalSignature&&(l|=128,a=7),e.nonRepudiation&&(l|=64,a=6),e.keyEncipherment&&(l|=32,a=5),e.dataEncipherment&&(l|=16,a=4),e.keyAgreement&&(l|=8,a=3),e.keyCertSign&&(l|=4,a=2),e.cRLSign&&(l|=2,a=1),e.encipherOnly&&(l|=1,a=0),e.decipherOnly&&(u|=128,a=7);var c=String.fromCharCode(a);0!==u?c+=String.fromCharCode(l)+String.fromCharCode(u):0!==l&&(c+=String.fromCharCode(l)),e.value=i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,c)}else if("basicConstraints"===e.name)e.value=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]),e.cA&&e.value.value.push(i.create(i.Class.UNIVERSAL,i.Type.BOOLEAN,!1,String.fromCharCode(255))),"pathLenConstraint"in e&&e.value.value.push(i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.pathLenConstraint).getBytes()));else if("extKeyUsage"===e.name){e.value=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);var h=e.value.value;for(var f in e)!0===e[f]&&(f in s?h.push(i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(s[f]).getBytes())):-1!==f.indexOf(".")&&h.push(i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(f).getBytes())))}else if("nsCertType"===e.name){var a=0,l=0;e.client&&(l|=128,a=7),e.server&&(l|=64,a=6),e.email&&(l|=32,a=5),e.objsign&&(l|=16,a=4),e.reserved&&(l|=8,a=3),e.sslCA&&(l|=4,a=2),e.emailCA&&(l|=2,a=1),e.objCA&&(l|=1,a=0);var c=String.fromCharCode(a);0!==l&&(c+=String.fromCharCode(l)),e.value=i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,c)}else if("subjectAltName"===e.name||"issuerAltName"===e.name){var p;e.value=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);for(var d=0;d<e.altNames.length;++d){p=e.altNames[d];var c=p.value;if(7===p.type&&p.ip){if(c=r.util.bytesFromIP(p.ip),null===c){var n=new Error('Extension "ip" value is not a valid IPv4 or IPv6 address.');throw n.extension=e,n}}else 8===p.type&&(c=p.oid?i.oidToDer(i.oidToDer(p.oid)):i.oidToDer(c));e.value.value.push(i.create(i.Class.CONTEXT_SPECIFIC,p.type,!1,c))}}else if("subjectKeyIdentifier"===e.name&&t.cert){var g=t.cert.generateSubjectKeyIdentifier();e.subjectKeyIdentifier=g.toHex(),e.value=i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,g.getBytes())}else if("authorityKeyIdentifier"===e.name&&t.cert){e.value=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);var h=e.value.value;if(e.keyIdentifier){var y=!0===e.keyIdentifier?t.cert.generateSubjectKeyIdentifier().getBytes():e.keyIdentifier;h.push(i.create(i.Class.CONTEXT_SPECIFIC,0,!1,y))}if(e.authorityCertIssuer){var v=[i.create(i.Class.CONTEXT_SPECIFIC,4,!0,[m(!0===e.authorityCertIssuer?t.cert.issuer:e.authorityCertIssuer)])];h.push(i.create(i.Class.CONTEXT_SPECIFIC,1,!0,v))}if(e.serialNumber){var b=r.util.hexToBytes(!0===e.serialNumber?t.cert.serialNumber:e.serialNumber);h.push(i.create(i.Class.CONTEXT_SPECIFIC,2,!1,b))}}else if("cRLDistributionPoints"===e.name){e.value=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);for(var h=e.value.value,_=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]),w=i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[]),p,d=0;d<e.altNames.length;++d){p=e.altNames[d];var c=p.value;if(7===p.type&&p.ip){if(c=r.util.bytesFromIP(p.ip),null===c){var n=new Error('Extension "ip" value is not a valid IPv4 or IPv6 address.');throw n.extension=e,n}}else 8===p.type&&(c=p.oid?i.oidToDer(i.oidToDer(p.oid)):i.oidToDer(c));w.value.push(i.create(i.Class.CONTEXT_SPECIFIC,p.type,!1,c))}_.value.push(i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[w])),h.push(_)}if(void 0===e.value){var n=new Error("Extension value not specified.");throw n.extension=e,n}return e}function b(e,t){switch(e){case s["RSASSA-PSS"]:var n=[];return void 0!==t.hash.algorithmOid&&n.push(i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(t.hash.algorithmOid).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")])])),void 0!==t.mgf.algorithmOid&&n.push(i.create(i.Class.CONTEXT_SPECIFIC,1,!0,[i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(t.mgf.algorithmOid).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(t.mgf.hash.algorithmOid).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")])])])),void 0!==t.saltLength&&n.push(i.create(i.Class.CONTEXT_SPECIFIC,2,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(t.saltLength).getBytes())])),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,n);default:return i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")}}function _(e){var t=i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[]);if(0===e.attributes.length)return t;for(var n=e.attributes,o=0;o<n.length;++o){var s=n[o],a=s.value,l=i.Type.UTF8;"valueTagClass"in s&&(l=s.valueTagClass),l===i.Type.UTF8&&(a=r.util.encodeUtf8(a));var u=!1;"valueConstructed"in s&&(u=s.valueConstructed);var c=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(s.type).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SET,!0,[i.create(i.Class.UNIVERSAL,l,u,a)])]);t.value.push(c)}return t}o.certificateFromPem=function(e,t,n){var s=r.pem.decode(e)[0];if("CERTIFICATE"!==s.type&&"X509 CERTIFICATE"!==s.type&&"TRUSTED CERTIFICATE"!==s.type){var a=new Error('Could not convert certificate from PEM; PEM header type is not "CERTIFICATE", "X509 CERTIFICATE", or "TRUSTED CERTIFICATE".');throw a.headerType=s.type,a}if(s.procType&&"ENCRYPTED"===s.procType.type)throw new Error("Could not convert certificate from PEM; PEM is encrypted.");var l=i.fromDer(s.body,n);return o.certificateFromAsn1(l,t)},o.certificateToPem=function(e,t){var n={type:"CERTIFICATE",body:i.toDer(o.certificateToAsn1(e)).getBytes()};return r.pem.encode(n,{maxline:t})},o.publicKeyFromPem=function(e){var t=r.pem.decode(e)[0];if("PUBLIC KEY"!==t.type&&"RSA PUBLIC KEY"!==t.type){var n=new Error('Could not convert public key from PEM; PEM header type is not "PUBLIC KEY" or "RSA PUBLIC KEY".');throw n.headerType=t.type,n}if(t.procType&&"ENCRYPTED"===t.procType.type)throw new Error("Could not convert public key from PEM; PEM is encrypted.");var s=i.fromDer(t.body);return o.publicKeyFromAsn1(s)},o.publicKeyToPem=function(e,t){var n={type:"PUBLIC KEY",body:i.toDer(o.publicKeyToAsn1(e)).getBytes()};return r.pem.encode(n,{maxline:t})},o.publicKeyToRSAPublicKeyPem=function(e,t){var n={type:"RSA PUBLIC KEY",body:i.toDer(o.publicKeyToRSAPublicKey(e)).getBytes()};return r.pem.encode(n,{maxline:t})},o.getPublicKeyFingerprint=function(e,t){t=t||{};var n=t.md||r.md.sha1.create(),s=t.type||"RSAPublicKey",a;switch(s){case"RSAPublicKey":a=i.toDer(o.publicKeyToRSAPublicKey(e)).getBytes();break;case"SubjectPublicKeyInfo":a=i.toDer(o.publicKeyToAsn1(e)).getBytes();break;default:throw new Error('Unknown fingerprint type "'+t.type+'".')}n.start(),n.update(a);var l=n.digest();if("hex"===t.encoding){var u=l.toHex();return t.delimiter?u.match(/.{2}/g).join(t.delimiter):u}if("binary"===t.encoding)return l.getBytes();if(t.encoding)throw new Error('Unknown encoding "'+t.encoding+'".');return l},o.certificationRequestFromPem=function(e,t,n){var s=r.pem.decode(e)[0];if("CERTIFICATE REQUEST"!==s.type){var a=new Error('Could not convert certification request from PEM; PEM header type is not "CERTIFICATE REQUEST".');throw a.headerType=s.type,a}if(s.procType&&"ENCRYPTED"===s.procType.type)throw new Error("Could not convert certification request from PEM; PEM is encrypted.");var l=i.fromDer(s.body,n);return o.certificationRequestFromAsn1(l,t)},o.certificationRequestToPem=function(e,t){var n={type:"CERTIFICATE REQUEST",body:i.toDer(o.certificationRequestToAsn1(e)).getBytes()};return r.pem.encode(n,{maxline:t})},o.createCertificate=function(){var e={version:2,serialNumber:"00",signatureOid:null,signature:null,siginfo:{}};return e.siginfo.algorithmOid=null,e.validity={},e.validity.notBefore=new Date,e.validity.notAfter=new Date,e.issuer={},e.issuer.getField=function(t){return p(e.issuer,t)},e.issuer.addField=function(t){y([t]),e.issuer.attributes.push(t)},e.issuer.attributes=[],e.issuer.hash=null,e.subject={},e.subject.getField=function(t){return p(e.subject,t)},e.subject.addField=function(t){y([t]),e.subject.attributes.push(t)},e.subject.attributes=[],e.subject.hash=null,e.extensions=[],e.publicKey=null,e.md=null,e.setSubject=function(t,n){y(t),e.subject.attributes=t,delete e.subject.uniqueId,n&&(e.subject.uniqueId=n),e.subject.hash=null},e.setIssuer=function(t,n){y(t),e.issuer.attributes=t,delete e.issuer.uniqueId,n&&(e.issuer.uniqueId=n),e.issuer.hash=null},e.setExtensions=function(t){for(var n=0;n<t.length;++n)v(t[n],{cert:e});e.extensions=t},e.getExtension=function(t){"string"==typeof t&&(t={name:t});for(var n=null,r,i=0;null===n&&i<e.extensions.length;++i)r=e.extensions[i],t.id&&r.id===t.id?n=r:t.name&&r.name===t.name&&(n=r);return n},e.sign=function(t,n){e.md=n||r.md.sha1.create();var a=s[e.md.algorithm+"WithRSAEncryption"];if(!a){var l=new Error("Could not compute certificate digest. Unknown message digest algorithm OID.");throw l.algorithm=e.md.algorithm,l}e.signatureOid=e.siginfo.algorithmOid=a,e.tbsCertificate=o.getTBSCertificate(e);var u=i.toDer(e.tbsCertificate);e.md.update(u.getBytes()),e.signature=t.sign(e.md)},e.verify=function(t){var n=!1;if(!e.issued(t)){var a=t.issuer,l=e.subject,u=new Error("The parent certificate did not issue the given child certificate; the child certificate's issuer does not match the parent's subject.");throw u.expectedIssuer=a.attributes,u.actualIssuer=l.attributes,u}var c=t.md;if(null===c){if(t.signatureOid in s){var h=s[t.signatureOid];switch(h){case"sha1WithRSAEncryption":c=r.md.sha1.create();break;case"md5WithRSAEncryption":c=r.md.md5.create();break;case"sha256WithRSAEncryption":c=r.md.sha256.create();break;case"sha384WithRSAEncryption":c=r.md.sha384.create();break;case"sha512WithRSAEncryption":c=r.md.sha512.create();break;case"RSASSA-PSS":c=r.md.sha256.create()}}if(null===c){var u=new Error("Could not compute certificate digest. Unknown signature OID.");throw u.signatureOid=t.signatureOid,u}var f=t.tbsCertificate||o.getTBSCertificate(t),p=i.toDer(f);c.update(p.getBytes())}if(null!==c){var d;switch(t.signatureOid){case s.sha1WithRSAEncryption:d=void 0;break;case s["RSASSA-PSS"]:var m,g;if(m=s[t.signatureParameters.mgf.hash.algorithmOid],void 0===m||void 0===r.md[m]){var u=new Error("Unsupported MGF hash function.");throw u.oid=t.signatureParameters.mgf.hash.algorithmOid,u.name=m,u}if(g=s[t.signatureParameters.mgf.algorithmOid],void 0===g||void 0===r.mgf[g]){var u=new Error("Unsupported MGF function.");throw u.oid=t.signatureParameters.mgf.algorithmOid,u.name=g,u}if(g=r.mgf[g].create(r.md[m].create()),m=s[t.signatureParameters.hash.algorithmOid],void 0===m||void 0===r.md[m])throw{message:"Unsupported RSASSA-PSS hash function.",oid:t.signatureParameters.hash.algorithmOid,name:m};d=r.pss.create(r.md[m].create(),g,t.signatureParameters.saltLength)}n=e.publicKey.verify(c.digest().getBytes(),t.signature,d)}return n},e.isIssuer=function(t){var n=!1,r=e.issuer,i=t.subject;if(r.hash&&i.hash)n=r.hash===i.hash;else if(r.attributes.length===i.attributes.length){var o,s;n=!0;for(var a=0;n&&a<r.attributes.length;++a)o=r.attributes[a],s=i.attributes[a],o.type===s.type&&o.value===s.value||(n=!1)}return n},e.issued=function(t){return t.isIssuer(e)},e.generateSubjectKeyIdentifier=function(){return o.getPublicKeyFingerprint(e.publicKey,{type:"RSAPublicKey"})},e.verifySubjectKeyIdentifier=function(){for(var t=s.subjectKeyIdentifier,n=0;n<e.extensions.length;++n){var i=e.extensions[n];if(i.id===t){var o=e.generateSubjectKeyIdentifier().getBytes();return r.util.hexToBytes(i.subjectKeyIdentifier)===o}}return!1},e},o.certificateFromAsn1=function(e,t){var n={},a=[];if(!i.validate(e,u,n,a)){var l=new Error("Cannot read X.509 certificate. ASN.1 object is not an X509v3 Certificate.");throw l.errors=a,l}var c=i.derToOid(n.publicKeyOid);if(c!==o.oids.rsaEncryption)throw new Error("Cannot read public key. OID is not RSA.");var h=o.createCertificate();h.version=n.certVersion?n.certVersion.charCodeAt(0):0;var f=r.util.createBuffer(n.certSerialNumber);h.serialNumber=f.toHex(),h.signatureOid=r.asn1.derToOid(n.certSignatureOid),h.signatureParameters=d(h.signatureOid,n.certSignatureParams,!0),h.siginfo.algorithmOid=r.asn1.derToOid(n.certinfoSignatureOid),h.siginfo.parameters=d(h.siginfo.algorithmOid,n.certinfoSignatureParams,!1),h.signature=n.certSignature;var m=[];if(void 0!==n.certValidity1UTCTime&&m.push(i.utcTimeToDate(n.certValidity1UTCTime)),void 0!==n.certValidity2GeneralizedTime&&m.push(i.generalizedTimeToDate(n.certValidity2GeneralizedTime)),void 0!==n.certValidity3UTCTime&&m.push(i.utcTimeToDate(n.certValidity3UTCTime)),void 0!==n.certValidity4GeneralizedTime&&m.push(i.generalizedTimeToDate(n.certValidity4GeneralizedTime)),m.length>2)throw new Error("Cannot read notBefore/notAfter validity times; more than two times were provided in the certificate.");if(m.length<2)throw new Error("Cannot read notBefore/notAfter validity times; they were not provided as either UTCTime or GeneralizedTime.");if(h.validity.notBefore=m[0],h.validity.notAfter=m[1],h.tbsCertificate=n.tbsCertificate,t){if(h.md=null,h.signatureOid in s){var c=s[h.signatureOid];switch(c){case"sha1WithRSAEncryption":h.md=r.md.sha1.create();break;case"md5WithRSAEncryption":h.md=r.md.md5.create();break;case"sha256WithRSAEncryption":h.md=r.md.sha256.create();break;case"sha384WithRSAEncryption":h.md=r.md.sha384.create();break;case"sha512WithRSAEncryption":h.md=r.md.sha512.create();break;case"RSASSA-PSS":h.md=r.md.sha256.create()}}if(null===h.md){var l=new Error("Could not compute certificate digest. Unknown signature OID.");throw l.signatureOid=h.signatureOid,l}var g=i.toDer(h.tbsCertificate);h.md.update(g.getBytes())}var v=r.md.sha1.create();h.issuer.getField=function(e){return p(h.issuer,e)},h.issuer.addField=function(e){y([e]),h.issuer.attributes.push(e)},h.issuer.attributes=o.RDNAttributesAsArray(n.certIssuer,v),n.certIssuerUniqueId&&(h.issuer.uniqueId=n.certIssuerUniqueId),h.issuer.hash=v.digest().toHex();var b=r.md.sha1.create();return h.subject.getField=function(e){return p(h.subject,e)},h.subject.addField=function(e){y([e]),h.subject.attributes.push(e)},h.subject.attributes=o.RDNAttributesAsArray(n.certSubject,b),n.certSubjectUniqueId&&(h.subject.uniqueId=n.certSubjectUniqueId),h.subject.hash=b.digest().toHex(),n.certExtensions?h.extensions=o.certificateExtensionsFromAsn1(n.certExtensions):h.extensions=[],h.publicKey=o.publicKeyFromAsn1(n.subjectPublicKeyInfo),h},o.certificateExtensionsFromAsn1=function(e){for(var t=[],n=0;n<e.value.length;++n)for(var r=e.value[n],i=0;i<r.value.length;++i)t.push(o.certificateExtensionFromAsn1(r.value[i]));return t},o.certificateExtensionFromAsn1=function(e){var t={};if(t.id=i.derToOid(e.value[0].value),t.critical=!1,e.value[1].type===i.Type.BOOLEAN?(t.critical=0!==e.value[1].value.charCodeAt(0),t.value=e.value[2].value):t.value=e.value[1].value,t.id in s)if(t.name=s[t.id],"keyUsage"===t.name){var n=i.fromDer(t.value),o=0,a=0;n.value.length>1&&(o=n.value.charCodeAt(1),a=n.value.length>2?n.value.charCodeAt(2):0),t.digitalSignature=128==(128&o),t.nonRepudiation=64==(64&o),t.keyEncipherment=32==(32&o),t.dataEncipherment=16==(16&o),t.keyAgreement=8==(8&o),t.keyCertSign=4==(4&o),t.cRLSign=2==(2&o),t.encipherOnly=1==(1&o),t.decipherOnly=128==(128&a)}else if("basicConstraints"===t.name){var n=i.fromDer(t.value);n.value.length>0&&n.value[0].type===i.Type.BOOLEAN?t.cA=0!==n.value[0].value.charCodeAt(0):t.cA=!1;var l=null;n.value.length>0&&n.value[0].type===i.Type.INTEGER?l=n.value[0].value:n.value.length>1&&(l=n.value[1].value),null!==l&&(t.pathLenConstraint=i.derToInteger(l))}else if("extKeyUsage"===t.name)for(var n=i.fromDer(t.value),u=0;u<n.value.length;++u){var c=i.derToOid(n.value[u].value);c in s?t[s[c]]=!0:t[c]=!0}else if("nsCertType"===t.name){var n=i.fromDer(t.value),o=0;n.value.length>1&&(o=n.value.charCodeAt(1)),t.client=128==(128&o),t.server=64==(64&o),t.email=32==(32&o),t.objsign=16==(16&o),t.reserved=8==(8&o),t.sslCA=4==(4&o),t.emailCA=2==(2&o),t.objCA=1==(1&o)}else if("subjectAltName"===t.name||"issuerAltName"===t.name){var h;t.altNames=[];for(var n=i.fromDer(t.value),f=0;f<n.value.length;++f){h=n.value[f];var p={type:h.type,value:h.value};switch(t.altNames.push(p),h.type){case 1:case 2:case 6:break;case 7:p.ip=r.util.bytesToIP(h.value);break;case 8:p.oid=i.derToOid(h.value)}}}else if("subjectKeyIdentifier"===t.name){var n=i.fromDer(t.value);t.subjectKeyIdentifier=r.util.bytesToHex(n.value)}return t},o.certificationRequestFromAsn1=function(e,t){var n={},a=[];if(!i.validate(e,f,n,a)){var l=new Error("Cannot read PKCS#10 certificate request. ASN.1 object is not a PKCS#10 CertificationRequest.");throw l.errors=a,l}var u=i.derToOid(n.publicKeyOid);if(u!==o.oids.rsaEncryption)throw new Error("Cannot read public key. OID is not RSA.");var c=o.createCertificationRequest();if(c.version=n.csrVersion?n.csrVersion.charCodeAt(0):0,c.signatureOid=r.asn1.derToOid(n.csrSignatureOid),c.signatureParameters=d(c.signatureOid,n.csrSignatureParams,!0),c.siginfo.algorithmOid=r.asn1.derToOid(n.csrSignatureOid),c.siginfo.parameters=d(c.siginfo.algorithmOid,n.csrSignatureParams,!1),c.signature=n.csrSignature,c.certificationRequestInfo=n.certificationRequestInfo,t){if(c.md=null,c.signatureOid in s){var u=s[c.signatureOid];switch(u){case"sha1WithRSAEncryption":c.md=r.md.sha1.create();break;case"md5WithRSAEncryption":c.md=r.md.md5.create();break;case"sha256WithRSAEncryption":c.md=r.md.sha256.create();break;case"sha384WithRSAEncryption":c.md=r.md.sha384.create();break;case"sha512WithRSAEncryption":c.md=r.md.sha512.create();break;case"RSASSA-PSS":c.md=r.md.sha256.create()}}if(null===c.md){var l=new Error("Could not compute certification request digest. Unknown signature OID.");throw l.signatureOid=c.signatureOid,l}var h=i.toDer(c.certificationRequestInfo);c.md.update(h.getBytes())}var m=r.md.sha1.create();return c.subject.getField=function(e){return p(c.subject,e)},c.subject.addField=function(e){y([e]),c.subject.attributes.push(e)},c.subject.attributes=o.RDNAttributesAsArray(n.certificationRequestInfoSubject,m),c.subject.hash=m.digest().toHex(),c.publicKey=o.publicKeyFromAsn1(n.subjectPublicKeyInfo),c.getAttribute=function(e){return p(c,e)},c.addAttribute=function(e){y([e]),c.attributes.push(e)},c.attributes=o.CRIAttributesAsArray(n.certificationRequestInfoAttributes||[]),c},o.createCertificationRequest=function(){var e={version:0,signatureOid:null,signature:null,siginfo:{}};return e.siginfo.algorithmOid=null,e.subject={},e.subject.getField=function(t){return p(e.subject,t)},e.subject.addField=function(t){y([t]),e.subject.attributes.push(t)},e.subject.attributes=[],e.subject.hash=null,e.publicKey=null,e.attributes=[],e.getAttribute=function(t){return p(e,t)},e.addAttribute=function(t){y([t]),e.attributes.push(t)},e.md=null,e.setSubject=function(t){y(t),e.subject.attributes=t,e.subject.hash=null},e.setAttributes=function(t){y(t),e.attributes=t},e.sign=function(t,n){e.md=n||r.md.sha1.create();var a=s[e.md.algorithm+"WithRSAEncryption"];if(!a){var l=new Error("Could not compute certification request digest. Unknown message digest algorithm OID.");throw l.algorithm=e.md.algorithm,l}e.signatureOid=e.siginfo.algorithmOid=a,e.certificationRequestInfo=o.getCertificationRequestInfo(e);var u=i.toDer(e.certificationRequestInfo);e.md.update(u.getBytes()),e.signature=t.sign(e.md)},e.verify=function(){var t=!1,n=e.md;if(null===n){if(e.signatureOid in s){var a=s[e.signatureOid];switch(a){case"sha1WithRSAEncryption":n=r.md.sha1.create();break;case"md5WithRSAEncryption":n=r.md.md5.create();break;case"sha256WithRSAEncryption":n=r.md.sha256.create();break;case"sha384WithRSAEncryption":n=r.md.sha384.create();break;case"sha512WithRSAEncryption":n=r.md.sha512.create();break;case"RSASSA-PSS":n=r.md.sha256.create()}}if(null===n){var l=new Error("Could not compute certification request digest. Unknown signature OID.");throw l.signatureOid=e.signatureOid,l}var u=e.certificationRequestInfo||o.getCertificationRequestInfo(e),c=i.toDer(u);n.update(c.getBytes())}if(null!==n){var h;switch(e.signatureOid){case s.sha1WithRSAEncryption:break;case s["RSASSA-PSS"]:var f,p;if(f=s[e.signatureParameters.mgf.hash.algorithmOid],void 0===f||void 0===r.md[f]){var l=new Error("Unsupported MGF hash function.");throw l.oid=e.signatureParameters.mgf.hash.algorithmOid,l.name=f,l}if(p=s[e.signatureParameters.mgf.algorithmOid],void 0===p||void 0===r.mgf[p]){var l=new Error("Unsupported MGF function.");throw l.oid=e.signatureParameters.mgf.algorithmOid,l.name=p,l}if(p=r.mgf[p].create(r.md[f].create()),f=s[e.signatureParameters.hash.algorithmOid],void 0===f||void 0===r.md[f]){var l=new Error("Unsupported RSASSA-PSS hash function.");throw l.oid=e.signatureParameters.hash.algorithmOid,l.name=f,l}h=r.pss.create(r.md[f].create(),p,e.signatureParameters.saltLength)}t=e.publicKey.verify(n.digest().getBytes(),e.signature,h)}return t},e},o.getTBSCertificate=function(e){var t=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes())]),i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,r.util.hexToBytes(e.serialNumber)),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.siginfo.algorithmOid).getBytes()),b(e.siginfo.algorithmOid,e.siginfo.parameters)]),m(e.issuer),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.UTCTIME,!1,i.dateToUtcTime(e.validity.notBefore)),i.create(i.Class.UNIVERSAL,i.Type.UTCTIME,!1,i.dateToUtcTime(e.validity.notAfter))]),m(e.subject),o.publicKeyToAsn1(e.publicKey)]);return e.issuer.uniqueId&&t.value.push(i.create(i.Class.CONTEXT_SPECIFIC,1,!0,[i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,String.fromCharCode(0)+e.issuer.uniqueId)])),e.subject.uniqueId&&t.value.push(i.create(i.Class.CONTEXT_SPECIFIC,2,!0,[i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,String.fromCharCode(0)+e.subject.uniqueId)])),e.extensions.length>0&&t.value.push(o.certificateExtensionsToAsn1(e.extensions)),t},o.getCertificationRequestInfo=function(e){var t=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes()),m(e.subject),o.publicKeyToAsn1(e.publicKey),_(e)]);return t},o.distinguishedNameToAsn1=function(e){return m(e)},o.certificateToAsn1=function(e){var t=e.tbsCertificate||o.getTBSCertificate(e);return i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[t,i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.signatureOid).getBytes()),b(e.signatureOid,e.signatureParameters)]),i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,String.fromCharCode(0)+e.signature)])},o.certificateExtensionsToAsn1=function(e){var t=i.create(i.Class.CONTEXT_SPECIFIC,3,!0,[]),n=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);t.value.push(n);for(var r=0;r<e.length;++r)n.value.push(o.certificateExtensionToAsn1(e[r]));return t},o.certificateExtensionToAsn1=function(e){var t=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[]);t.value.push(i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.id).getBytes())),e.critical&&t.value.push(i.create(i.Class.UNIVERSAL,i.Type.BOOLEAN,!1,String.fromCharCode(255)));var n=e.value;return"string"!=typeof e.value&&(n=i.toDer(n).getBytes()),t.value.push(i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,n)),t},o.certificationRequestToAsn1=function(e){var t=e.certificationRequestInfo||o.getCertificationRequestInfo(e);return i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[t,i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.signatureOid).getBytes()),b(e.signatureOid,e.signatureParameters)]),i.create(i.Class.UNIVERSAL,i.Type.BITSTRING,!1,String.fromCharCode(0)+e.signature)])},o.createCaStore=function(e){var t={certs:{}};function n(e){return s(e),t.certs[e.hash]||null}function s(e){if(!e.hash){var t=r.md.sha1.create();e.attributes=o.RDNAttributesAsArray(m(e),t),e.hash=t.digest().toHex()}}if(t.getIssuer=function(e){var t=n(e.issuer);return t},t.addCertificate=function(e){if("string"==typeof e&&(e=r.pki.certificateFromPem(e)),s(e.subject),!t.hasCertificate(e))if(e.subject.hash in t.certs){var n=t.certs[e.subject.hash];r.util.isArray(n)||(n=[n]),n.push(e),t.certs[e.subject.hash]=n}else t.certs[e.subject.hash]=e},t.hasCertificate=function(e){"string"==typeof e&&(e=r.pki.certificateFromPem(e));var t=n(e.subject);if(!t)return!1;r.util.isArray(t)||(t=[t]);for(var s=i.toDer(o.certificateToAsn1(e)).getBytes(),a=0;a<t.length;++a){var l=i.toDer(o.certificateToAsn1(t[a])).getBytes();if(s===l)return!0}return!1},t.listAllCertificates=function(){var e=[];for(var n in t.certs)if(t.certs.hasOwnProperty(n)){var i=t.certs[n];if(r.util.isArray(i))for(var o=0;o<i.length;++o)e.push(i[o]);else e.push(i)}return e},t.removeCertificate=function(e){var a;if("string"==typeof e&&(e=r.pki.certificateFromPem(e)),s(e.subject),!t.hasCertificate(e))return null;var l=n(e.subject);if(!r.util.isArray(l))return a=t.certs[e.subject.hash],delete t.certs[e.subject.hash],a;for(var u=i.toDer(o.certificateToAsn1(e)).getBytes(),c=0;c<l.length;++c){var h=i.toDer(o.certificateToAsn1(l[c])).getBytes();u===h&&(a=l[c],l.splice(c,1))}return 0===l.length&&delete t.certs[e.subject.hash],a},e)for(var a=0;a<e.length;++a){var l=e[a];t.addCertificate(l)}return t},o.certificateError={bad_certificate:"forge.pki.BadCertificate",unsupported_certificate:"forge.pki.UnsupportedCertificate",certificate_revoked:"forge.pki.CertificateRevoked",certificate_expired:"forge.pki.CertificateExpired",certificate_unknown:"forge.pki.CertificateUnknown",unknown_ca:"forge.pki.UnknownCertificateAuthority"},o.verifyCertificateChain=function(e,t,n){t=t.slice(0);var i=t.slice(0),s=new Date,a=!0,l=null,u=0;do{var c=t.shift(),h=null,f=!1;if((s<c.validity.notBefore||s>c.validity.notAfter)&&(l={message:"Certificate is not valid yet or has expired.",error:o.certificateError.certificate_expired,notBefore:c.validity.notBefore,notAfter:c.validity.notAfter,now:s}),null===l){if(h=t[0]||e.getIssuer(c),null===h&&c.isIssuer(c)&&(f=!0,h=c),h){var p=h;r.util.isArray(p)||(p=[p]);for(var d=!1;!d&&p.length>0;){h=p.shift();try{d=h.verify(c)}catch(e){}}d||(l={message:"Certificate signature is invalid.",error:o.certificateError.bad_certificate})}null!==l||h&&!f||e.hasCertificate(c)||(l={message:"Certificate is not trusted.",error:o.certificateError.unknown_ca})}if(null===l&&h&&!c.isIssuer(h)&&(l={message:"Certificate issuer is invalid.",error:o.certificateError.bad_certificate}),null===l)for(var m={keyUsage:!0,basicConstraints:!0},g=0;null===l&&g<c.extensions.length;++g){var y=c.extensions[g];!y.critical||y.name in m||(l={message:"Certificate has an unsupported critical extension.",error:o.certificateError.unsupported_certificate})}if(null===l&&(!a||0===t.length&&(!h||f))){var v=c.getExtension("basicConstraints"),b=c.getExtension("keyUsage");if(null!==b&&(b.keyCertSign&&null!==v||(l={message:"Certificate keyUsage or basicConstraints conflict or indicate that the certificate is not a CA. If the certificate is the only one in the chain or isn't the first then the certificate must be a valid CA.",error:o.certificateError.bad_certificate})),null!==l||null===v||v.cA||(l={message:"Certificate basicConstraints indicates the certificate is not a CA.",error:o.certificateError.bad_certificate}),null===l&&null!==b&&"pathLenConstraint"in v){var _=u-1;_>v.pathLenConstraint&&(l={message:"Certificate basicConstraints pathLenConstraint violated.",error:o.certificateError.bad_certificate})}}var w=null===l||l.error,k=n?n(w,u,i):w;if(!0!==k)throw!0===w&&(l={message:"The application rejected the certificate.",error:o.certificateError.bad_certificate}),(k||0===k)&&("object"!=typeof k||r.util.isArray(k)?"string"==typeof k&&(l.error=k):(k.message&&(l.message=k.message),k.error&&(l.error=k.error))),l;l=null,a=!1,++u}while(t.length>0);return!0}},function(e,t){function n(e,t,n){var r;return function(){if(!t)return e.apply(this,arguments);var i=this,o=arguments,s=n&&!r;return clearTimeout(r),r=setTimeout(function(){if(r=null,!s)return e.apply(i,o)},t),s?e.apply(this,arguments):void 0}}e.exports=n},function(e,t,n){"use strict";var r=n(898);function i(e){return Number.isFinite(e)}function o(e){return"function"==typeof e}function s(e,t){return t?function(n,r){var i=setTimeout(function(){e(new Error("pull-reader: read exceeded timeout"),r)},t);e(n,function(e,t){clearTimeout(i),r(e,t)})}:e}e.exports=function(e){var t=[],n,a,l=!1,u=r(),c,h,f;function p(){for(;t.length;)if(null==t[0].length&&u.has(1))t.shift().cb(null,u.get());else if(u.has(t[0].length)){var e=t.shift();e.cb(null,u.get(e.length))}else if(1==c&&t[0].length&&u.length<t[0].length){var n="stream ended with:"+u.length+" but wanted:"+t[0].length;t.shift().cb(new Error(n))}else{if(!c)return!!t.length;t.shift().cb(c)}return t.length||!u.has(1)||f}function d(){var e=p();e&&!l&&(!n||l||h||(l=!0,a(null,function(e,t){if(l=!1,e)return c=e,p();u.add(t),d()})))}function m(r){if(f){for(;t.length;)t.shift().cb(f);return cb&&cb(f)}a=s(r,e),n=r,d()}return m.abort=function(e,r){f=e||!0,n?(l=!0,n(f,function(){for(;t.length;)t.shift().cb(f);r&&r(f)})):r()},m.read=function(r,a,c){if(o(a)&&(c=a,a=e),!o(c))return h=!0,function(e,r){if(l||u.has(1)){if(e)return n(e,r);t.push({length:null,cb:r}),d()}else s(n,a)(e,function(e,t){r(e,t)})};t.push({length:i(r)?r:null,cb:c}),d()},m}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(244),i=u(r),o=n(333),s=u(o),a=n(37),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e,t,n,r){(0,i.default)(t)(e,(0,s.default)((0,l.default)(n)),r)}e.exports=t.default},function(e,t,n){"use strict";const r=Math.exp;t=e.exports=function e(t){if("number"!=typeof t)throw new Error("must provide a timespan to the moving average constructor");if(t<=0)throw new Error("must provide a timespan > 0 to the moving average constructor");let n,i=0,o=0,s=0,a,l={};function u(e,n){return 1-r(-(e-n)/t)}return l.push=function e(t,r){if(a){const e=u(t,a),l=r-n,c=e*l;n=e*r+(1-e)*n,i=(1-e)*(i+l*c),o=Math.sqrt(i),s=n+e*l}else n=r;a=t},l.movingAverage=function e(){return n},l.variance=function e(){return i},l.deviation=function e(){return o},l.forecast=function e(){return s},l}},function(e,t,n){"use strict";const{createFromPrivKey:r}=n(15),i=n(43),o=n(904),s=n(13),a=n(4),l=a("ipfs:ipns");l.error=a("ipfs:ipns:error");const u=n(905),c=n(911),h=n(912),f=n(433),p=6e4;class d{constructor(e,t,n,r,i){this.publisher=new u(e,t),this.republisher=new c(this.publisher,t,n,r,i),this.resolver=new h(e),this.cache=new o({max:1e3}),this.routing=e}publish(e,t,n,o){i([t=>r(e.bytes,t),r=>this.publisher.publishWithEOL(e,t,n,r)],(e,r)=>{if(e)return l.error(e),o(e);l(`IPNS value ${t} was published correctly`);const i=r[0].toB58String(),s=parseFloat(n),a=s<p?s:p;this.cache.set(i,t,{ttl:a}),l(`IPNS value ${t} was cached correctly`),o(null,{name:i,value:t})})}resolve(e,t,n){if("string"!=typeof e){const e="name received is not valid";return l.error(e),n(s(new Error(e),"ERR_INVALID_NAME"))}if("function"==typeof t&&(n=t,t={}),t=t||{},!t.nocache&&!t.recursive){const t=e.split("/")[2],r=this.cache.get(t);if(r)return n(null,{path:r})}this.resolver.resolve(e,t,(t,r)=>{if(t)return l.error(t),n(t);l(`IPNS record from ${e} was resolved correctly`),n(null,{path:r})})}initializeKeyspace(e,t,n){this.publisher.publish(e,t,n)}}t=e.exports=d,t.path=f},function(e,t,n){"use strict";const r=n(200),i=n(4),o=i("ipfs:ipns:path");o.error=i("ipfs:ipns:path:error");const s=(e,t,n)=>{if(r.ipnsPath(t))return o(`resolve ipns path ${t}`),e._ipns.resolve(t,n);e.dag.get(t.substring("/ipfs/".length),(e,t)=>e?n(e):n(null,t))};e.exports={resolvePath:s}},function(e,t,n){"use strict";(function(r){const i=n(158),{fromB58String:o,toB58String:s}=n(27),a=n(914),l=n(39),u=n(13),c=n(4),h=c("ipfs:ipns:pubsub");h.error=c("ipfs:ipns:pubsub:error");class f{constructor(e,t,n){this._pubsub=e,this._subscriptions={},this._handleSubscriptionKey=this._handleSubscriptionKey.bind(this),this._pubsubDs=new a(e,t,n,i.validator,this._handleSubscriptionKey)}put(e,t,n){this._pubsubDs.put(e,t,n)}get(e,t){this._pubsubDs.get(e,(n,r)=>{const o=e.slice(0,i.namespaceLength);if(o.toString()===i.namespace){const t=e.toString(),n=s(e.slice(i.namespaceLength));this._subscriptions[t]=n,h(`subscribed pubsub ${t}: ${n}`)}if(n)return t(n);t(null,r)})}_handleSubscriptionKey(e,t){const n=this._subscriptions[e];if(!n){const n=`key ${e} does not correspond to a subscription`;return h.error(n),t(u(new Error(n),"ERR_INVALID_KEY"))}let r;try{r=i.getIdKeys(o(n))}catch(e){return h.error(e),t(e)}t(null,r.routingKey.toBuffer())}getSubscriptions(e){const t=Object.values(this._subscriptions).filter(Boolean);return e(null,t.map(e=>`${i.namespace}${e}`))}cancel(e,t){if("string"!=typeof e){const e="received subscription name is not valid";return h.error(e),t(u(new Error(e),"ERR_INVALID_SUBSCRIPTION_NAME"))}e.startsWith(i.namespace)&&(e=e.substring(i.namespaceLength));const n=Object.keys(this._subscriptions).find(t=>this._subscriptions[t]===e);if(!n)return t(null,{canceled:!1});try{const e=r.from(n);this._pubsubDs.unsubscribe(e)}catch(e){return t(e)}this._subscriptions[n]=void 0,h(`unsubscribed pubsub ${n}: ${e}`),t(null,{canceled:!0})}}t=e.exports=l(f,{className:"IpnsPubsubDatastore",symbolName:"@js-ipfs/ipns/IpnsPubsubDatastore"})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const{Key:i}=n(28),{Record:o}=n(123),{encodeBase32:s}=n(438),a=n(13),l=n(4),u=l("ipfs:ipns:offline-datastore");u.error=l("ipfs:ipns:offline-datastore:error");class c{constructor(e){this._repo=e}put(e,t,n){if(!r.isBuffer(e)){const e="Offline datastore key must be a buffer";return u.error(e),n(a(new Error(e),"ERR_INVALID_KEY"))}if(!r.isBuffer(t)){const e="Offline datastore value must be a buffer";return u.error(e),n(a(new Error(e),"ERR_INVALID_VALUE"))}let i;try{i=this._routingKey(e)}catch(e){const t="Not possible to generate the routing key";return u.error(t),n(a(new Error(t),"ERR_GENERATING_ROUTING_KEY"))}const s=new o(e,t);this._repo.datastore.put(i,s.serialize(),n)}get(e,t){if(!r.isBuffer(e)){const e="Offline datastore key must be a buffer";return u.error(e),t(a(new Error(e),"ERR_INVALID_KEY"))}let n;try{n=this._routingKey(e)}catch(e){const n="Not possible to generate the routing key";return u.error(n),t(a(new Error(n),"ERR_GENERATING_ROUTING_KEY"))}this._repo.datastore.get(n,(e,n)=>{if(e)return t(e);let r;try{r=o.deserialize(n)}catch(e){return u.error(e),t(e)}t(null,r.value)})}_routingKey(e){return new i("/"+s(e),!1)}}t=e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){var r=n(920);e.exports=function(e,t,n){for(var i=-1,o=[],s=n?t.length:0;(i=r(e,t))>-1;)o.push(e.slice(0,i+s)),e=e.slice(i+t.length,e.length);return o.push(e),o}},function(e,t,n){"use strict";(function(e,n){t.toCallback=(t=>(function(n,r){let i;try{i=t(n)}catch(t){return void e.nextTick(r,t)}e.nextTick(r,null,i)})),t.toBuf=((e,t)=>r=>{let i=e(r,t);return n.from(i,"hex")}),t.fromString=((e,t)=>r=>{const i=n.isBuffer(r)?r.toString():r;return e(i,t)}),t.fromNumberTo32BitBuf=((e,t)=>r=>{let i=e(r,t);const o=new Array(4);for(let e=0;e<4;e++)o[e]=255&i,i>>=8;return n.from(o)})}).call(this,n(3),n(0).Buffer)},function(e,t,n){"use strict";const r=n(60),i=n(158);e.exports={encodeBase32:e=>{const t=r.encode("base32",e).slice(1);return t.toString().toUpperCase()},validator:{func:(e,t,n)=>i.validator.validate(t,e,n)},selector:(e,t)=>i.validator.select(t[0],t[1])}},function(e,t,n){"use strict";const r=n(202),i=n(89),o=n(438);function s({datastore:e,peerInfo:t,peerBook:s,options:a,config:l}){const u={datastore:e,peerInfo:t,peerBook:s,config:{peerDiscovery:{mdns:{enabled:r(a,"config.Discovery.MDNS.Enabled",r(l,"Discovery.MDNS.Enabled",!0))},webRTCStar:{enabled:r(a,"config.Discovery.webRTCStar.Enabled",r(l,"Discovery.webRTCStar.Enabled",!0))},bootstrap:{list:r(a,"config.Bootstrap",r(l,"Bootstrap",[]))}},relay:{enabled:r(a,"relay.enabled",r(l,"relay.enabled",!0)),hop:{enabled:r(a,"relay.hop.enabled",r(l,"relay.hop.enabled",!1)),active:r(a,"relay.hop.active",r(l,"relay.hop.active",!1))}},dht:{kBucketSize:r(a,"dht.kBucketSize",20),enabled:!1,randomWalk:{enabled:!1},validators:{ipns:o.validator},selectors:{ipns:o.selector}},EXPERIMENTAL:{pubsub:r(a,"EXPERIMENTAL.pubsub",!1)}},connectionManager:r(a,"connectionManager",{maxPeers:r(l,"Swarm.ConnMgr.HighWater"),minPeers:r(l,"Swarm.ConnMgr.LowWater")})},c=i(u,r(a,"libp2p",{})),h=n(930);return new h(c)}e.exports=function e(t,n){const r=t._options||{};n=n||{};const i="function"==typeof r.libp2p?r.libp2p:s,{datastore:o}=t._repo,a=t._peerInfo,l=t._peerInfoBook,e=i({options:r,config:n,datastore:o,peerInfo:a,peerBook:l});return e.on("stop",()=>{a.multiaddrs.clear()}),e.on("start",()=>{a.multiaddrs.forEach(e=>{t._print("Swarm listening on",e.toString())})}),e.on("peer:connect",e=>l.put(e)),e}},function(e,t,n){"use strict";const r=n(931),i=n(72),o=n(39),s=n(64).Connection,a=n(441),l=n(4),u=l("libp2p:websockets:dialer"),c=n(940);class h{dial(e,t,n){"function"==typeof t&&(n=t,t={}),n=n||function(){};const i=a(e);u("dialing %s",i);const o=r(i,{binary:!0,onConnect:e=>{n(e)}}),l=new s(o);return l.getObservedAddrs=(t=>t(null,[e])),l.close=(e=>o.close(e)),l}createListener(e,t){return"function"==typeof e&&(t=e,e={}),c(e,t)}filter(e){return Array.isArray(e)||(e=[e]),e.filter(e=>!e.protoNames().includes("p2p-circuit")&&(e.protoNames().includes("ipfs")&&(e=e.decapsulate("ipfs")),i.WebSockets.matches(e)||i.WebSocketsSecure.matches(e)))}}e.exports=o(h,{className:"WebSockets",symbolName:"@libp2p/js-libp2p-websockets/websockets"})},function(e,t,n){const r=n(22),i=(e,t)=>t,o={ip4:i,ip6:(e,t,n,r)=>1===r.length&&"ip6"===r[0].protocol?t:`[${t}]`,tcp:(e,t,n,r)=>r.some(e=>["http","https","ws","wss"].includes(e.protocol))?`${e}:${t}`:`tcp://${e}:${t}`,udp:(e,t)=>`udp://${e}:${t}`,dnsaddr:i,dns4:i,dns6:i,ipfs:(e,t)=>`${e}/ipfs/${t}`,p2p:(e,t)=>`${e}/p2p/${t}`,http:e=>`http://${e}`,https:e=>`https://${e}`,ws:e=>`ws://${e}`,wss:e=>`wss://${e}`,"p2p-websocket-star":e=>`${e}/p2p-websocket-star`,"p2p-webrtc-star":e=>`${e}/p2p-webrtc-star`,"p2p-webrtc-direct":e=>`${e}/p2p-webrtc-direct`};e.exports=(e=>r(e).stringTuples().map(e=>({protocol:r.protocols.codes[e[0]].name,content:e[1]})).reduce((e,t,n,r)=>{const i=o[t.protocol];if(!i)throw new Error(`Unsupported protocol ${t.protocol}`);return i(e,t.content,n,r)},""))},function(e,t,n){var r=n(942),i=n(266),o=n(446),s=n(208)("socket.io-client");e.exports=t=l;var a=t.managers={};function l(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var n=r(e),i=n.source,l=n.id,u=n.path,c=a[l]&&u in a[l].nsps,h=t.forceNew||t["force new connection"]||!1===t.multiplex||c,f;return h?(s("ignoring socket cache for %s",i),f=o(i,t)):(a[l]||(s("new io instance for %s",i),a[l]=o(i,t)),f=a[l]),n.query&&!t.query&&(t.query=n.query),f.socket(n.path,t)}t.protocol=i.protocol,t.connect=l,t.Manager=n(446),t.Socket=n(452)},function(e,t){var n=/^(?:(?![^:@]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@]*)(?::([^:@]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,r=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];e.exports=function e(t){var i=t,o=t.indexOf("["),s=t.indexOf("]");-1!=o&&-1!=s&&(t=t.substring(0,o)+t.substring(o,s).replace(/:/g,";")+t.substring(s,t.length));for(var a=n.exec(t||""),l={},u=14;u--;)l[r[u]]=a[u]||"";return-1!=o&&-1!=s&&(l.source=i,l.host=l.host.substring(1,l.host.length-1).replace(/;/g,":"),l.authority=l.authority.replace("[","").replace("]","").replace(/;/g,":"),l.ipv6uri=!0),l}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){(function(t){e.exports=o;var n="function"==typeof t&&"function"==typeof t.isBuffer,r="function"==typeof ArrayBuffer,i=function(e){return"function"==typeof ArrayBuffer.isView?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer};function o(e){return n&&t.isBuffer(e)||r&&(e instanceof ArrayBuffer||i(e))}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(949),i=n(452),o=n(124),s=n(266),a=n(453),l=n(454),u=n(208)("socket.io-client:manager"),c=n(451),h=n(966),f=Object.prototype.hasOwnProperty;function p(e,t){if(!(this instanceof p))return new p(e,t);e&&"object"==typeof e&&(t=e,e=void 0),t=t||{},t.path=t.path||"/socket.io",this.nsps={},this.subs=[],this.opts=t,this.reconnection(!1!==t.reconnection),this.reconnectionAttempts(t.reconnectionAttempts||1/0),this.reconnectionDelay(t.reconnectionDelay||1e3),this.reconnectionDelayMax(t.reconnectionDelayMax||5e3),this.randomizationFactor(t.randomizationFactor||.5),this.backoff=new h({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(null==t.timeout?2e4:t.timeout),this.readyState="closed",this.uri=e,this.connecting=[],this.lastPing=null,this.encoding=!1,this.packetBuffer=[];var n=t.parser||s;this.encoder=new n.Encoder,this.decoder=new n.Decoder,this.autoConnect=!1!==t.autoConnect,this.autoConnect&&this.open()}e.exports=p,p.prototype.emitAll=function(){for(var e in this.emit.apply(this,arguments),this.nsps)f.call(this.nsps,e)&&this.nsps[e].emit.apply(this.nsps[e],arguments)},p.prototype.updateSocketIds=function(){for(var e in this.nsps)f.call(this.nsps,e)&&(this.nsps[e].id=this.generateId(e))},p.prototype.generateId=function(e){return("/"===e?"":e+"#")+this.engine.id},o(p.prototype),p.prototype.reconnection=function(e){return arguments.length?(this._reconnection=!!e,this):this._reconnection},p.prototype.reconnectionAttempts=function(e){return arguments.length?(this._reconnectionAttempts=e,this):this._reconnectionAttempts},p.prototype.reconnectionDelay=function(e){return arguments.length?(this._reconnectionDelay=e,this.backoff&&this.backoff.setMin(e),this):this._reconnectionDelay},p.prototype.randomizationFactor=function(e){return arguments.length?(this._randomizationFactor=e,this.backoff&&this.backoff.setJitter(e),this):this._randomizationFactor},p.prototype.reconnectionDelayMax=function(e){return arguments.length?(this._reconnectionDelayMax=e,this.backoff&&this.backoff.setMax(e),this):this._reconnectionDelayMax},p.prototype.timeout=function(e){return arguments.length?(this._timeout=e,this):this._timeout},p.prototype.maybeReconnectOnOpen=function(){!this.reconnecting&&this._reconnection&&0===this.backoff.attempts&&this.reconnect()},p.prototype.open=p.prototype.connect=function(e,t){if(u("readyState %s",this.readyState),~this.readyState.indexOf("open"))return this;u("opening %s",this.uri),this.engine=r(this.uri,this.opts);var n=this.engine,i=this;this.readyState="opening",this.skipReconnect=!1;var o=a(n,"open",function(){i.onopen(),e&&e()}),s=a(n,"error",function(t){if(u("connect_error"),i.cleanup(),i.readyState="closed",i.emitAll("connect_error",t),e){var n=new Error("Connection error");n.data=t,e(n)}else i.maybeReconnectOnOpen()});if(!1!==this._timeout){var l=this._timeout;u("connect attempt will timeout after %d",l);var c=setTimeout(function(){u("connect attempt timed out after %d",l),o.destroy(),n.close(),n.emit("error","timeout"),i.emitAll("connect_timeout",l)},l);this.subs.push({destroy:function(){clearTimeout(c)}})}return this.subs.push(o),this.subs.push(s),this},p.prototype.onopen=function(){u("open"),this.cleanup(),this.readyState="open",this.emit("open");var e=this.engine;this.subs.push(a(e,"data",l(this,"ondata"))),this.subs.push(a(e,"ping",l(this,"onping"))),this.subs.push(a(e,"pong",l(this,"onpong"))),this.subs.push(a(e,"error",l(this,"onerror"))),this.subs.push(a(e,"close",l(this,"onclose"))),this.subs.push(a(this.decoder,"decoded",l(this,"ondecoded")))},p.prototype.onping=function(){this.lastPing=new Date,this.emitAll("ping")},p.prototype.onpong=function(){this.emitAll("pong",new Date-this.lastPing)},p.prototype.ondata=function(e){this.decoder.add(e)},p.prototype.ondecoded=function(e){this.emit("packet",e)},p.prototype.onerror=function(e){u("error",e),this.emitAll("error",e)},p.prototype.socket=function(e,t){var n=this.nsps[e];if(!n){n=new i(this,e,t),this.nsps[e]=n;var r=this;n.on("connecting",o),n.on("connect",function(){n.id=r.generateId(e)}),this.autoConnect&&o()}function o(){~c(r.connecting,n)||r.connecting.push(n)}return n},p.prototype.destroy=function(e){var t=c(this.connecting,e);~t&&this.connecting.splice(t,1),this.connecting.length||this.close()},p.prototype.packet=function(e){u("writing packet %j",e);var t=this;e.query&&0===e.type&&(e.nsp+="?"+e.query),t.encoding?t.packetBuffer.push(e):(t.encoding=!0,this.encoder.encode(e,function(n){for(var r=0;r<n.length;r++)t.engine.write(n[r],e.options);t.encoding=!1,t.processPacketQueue()}))},p.prototype.processPacketQueue=function(){if(this.packetBuffer.length>0&&!this.encoding){var e=this.packetBuffer.shift();this.packet(e)}},p.prototype.cleanup=function(){u("cleanup");for(var e=this.subs.length,t=0;t<e;t++){var n=this.subs.shift();n.destroy()}this.packetBuffer=[],this.encoding=!1,this.lastPing=null,this.decoder.destroy()},p.prototype.close=p.prototype.disconnect=function(){u("disconnect"),this.skipReconnect=!0,this.reconnecting=!1,"opening"===this.readyState&&this.cleanup(),this.backoff.reset(),this.readyState="closed",this.engine&&this.engine.close()},p.prototype.onclose=function(e){u("onclose"),this.cleanup(),this.backoff.reset(),this.readyState="closed",this.emit("close",e),this._reconnection&&!this.skipReconnect&&this.reconnect()},p.prototype.reconnect=function(){if(this.reconnecting||this.skipReconnect)return this;var e=this;if(this.backoff.attempts>=this._reconnectionAttempts)u("reconnect failed"),this.backoff.reset(),this.emitAll("reconnect_failed"),this.reconnecting=!1;else{var t=this.backoff.duration();u("will wait %dms before reconnect attempt",t),this.reconnecting=!0;var n=setTimeout(function(){e.skipReconnect||(u("attempting reconnect"),e.emitAll("reconnect_attempt",e.backoff.attempts),e.emitAll("reconnecting",e.backoff.attempts),e.skipReconnect||e.open(function(t){t?(u("reconnect attempt error"),e.reconnecting=!1,e.reconnect(),e.emitAll("reconnect_error",t.data)):(u("reconnect success"),e.onreconnect())}))},t);this.subs.push({destroy:function(){clearTimeout(n)}})}},p.prototype.onreconnect=function(){var e=this.backoff.attempts;this.reconnecting=!1,this.backoff.reset(),this.updateSocketIds(),this.emitAll("reconnect",e)}},function(e,t,n){var r=n(267),i=n(952),o=n(962),s=n(963);function a(e){var t,n=!1,s=!1,a=!1!==e.jsonp;if("undefined"!=typeof location){var l="https:"===location.protocol,u=location.port;u||(u=l?443:80),n=e.hostname!==location.hostname||u!==e.port,s=e.secure!==l}if(e.xdomain=n,e.xscheme=s,t=new r(e),"open"in t&&!e.forceJSONP)return new i(e);if(!a)throw new Error("JSONP disabled");return new o(e)}t.polling=a,t.websocket=s},function(e,t,n){var r=n(268),i=n(209),o=n(125),s=n(210),a=n(450),l=n(211)("engine.io-client:polling");e.exports=f;var u=(c=n(267),h=new c({xdomain:!1}),null!=h.responseType),c,h;function f(e){var t=e&&e.forceBase64;u&&!t||(this.supportsBinary=!1),r.call(this,e)}s(f,r),f.prototype.name="polling",f.prototype.doOpen=function(){this.poll()},f.prototype.pause=function(e){var t=this;function n(){l("paused"),t.readyState="paused",e()}if(this.readyState="pausing",this.polling||!this.writable){var r=0;this.polling&&(l("we are currently polling - waiting to pause"),r++,this.once("pollComplete",function(){l("pre-pause polling complete"),--r||n()})),this.writable||(l("we are currently writing - waiting to pause"),r++,this.once("drain",function(){l("pre-pause writing complete"),--r||n()}))}else n()},f.prototype.poll=function(){l("polling"),this.polling=!0,this.doPoll(),this.emit("poll")},f.prototype.onData=function(e){var t=this;l("polling got data %s",e);var n=function(e,n,r){if("opening"===t.readyState&&t.onOpen(),"close"===e.type)return t.onClose(),!1;t.onPacket(e)};o.decodePayload(e,this.socket.binaryType,n),"closed"!==this.readyState&&(this.polling=!1,this.emit("pollComplete"),"open"===this.readyState?this.poll():l('ignoring poll - transport state "%s"',this.readyState))},f.prototype.doClose=function(){var e=this;function t(){l("writing close packet"),e.write([{type:"close"}])}"open"===this.readyState?(l("transport open - closing"),t()):(l("transport not open - deferring close"),this.once("open",t))},f.prototype.write=function(e){var t=this;this.writable=!1;var n=function(){t.writable=!0,t.emit("drain")};o.encodePayload(e,this.supportsBinary,function(e){t.doWrite(e,n)})},f.prototype.uri=function(){var e=this.query||{},t=this.secure?"https":"http",n="";!1!==this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||e.sid||(e.b64=1),e=i.encode(e),this.port&&("https"===t&&443!==Number(this.port)||"http"===t&&80!==Number(this.port))&&(n=":"+this.port),e.length&&(e="?"+e);var r=-1!==this.hostname.indexOf(":");return t+"://"+(r?"["+this.hostname+"]":this.hostname)+n+this.path+e}},function(e,t,n){(function(t){var r=n(954),i=Object.prototype.toString,o="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===i.call(Blob),s="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===i.call(File);function a(e){if(!e||"object"!=typeof e)return!1;if(r(e)){for(var n=0,i=e.length;n<i;n++)if(a(e[n]))return!0;return!1}if("function"==typeof t&&t.isBuffer&&t.isBuffer(e)||"function"==typeof ArrayBuffer&&e instanceof ArrayBuffer||o&&e instanceof Blob||s&&e instanceof File)return!0;if(e.toJSON&&"function"==typeof e.toJSON&&1===arguments.length)return a(e.toJSON(),!0);for(var l in e)if(Object.prototype.hasOwnProperty.call(e,l)&&a(e[l]))return!0;return!1}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""),i=64,o={},s=0,a=0,l;function u(e){var t="";do{t=r[e%i]+t,e=Math.floor(e/i)}while(e>0);return t}function c(e){var t=0;for(a=0;a<e.length;a++)t=t*i+o[e.charAt(a)];return t}function h(){var e=u(+new Date);return e!==l?(s=0,l=e):e+"."+u(s++)}for(;a<i;a++)o[r[a]]=a;h.encode=u,h.decode=c,e.exports=h},function(e,t){var n=[].indexOf;e.exports=function(e,t){if(n)return e.indexOf(t);for(var r=0;r<e.length;++r)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(266),i=n(124),o=n(965),s=n(453),a=n(454),l=n(208)("socket.io-client:socket"),u=n(209),c=n(449);e.exports=t=p;var h={connect:1,connect_error:1,connect_timeout:1,connecting:1,disconnect:1,error:1,reconnect:1,reconnect_attempt:1,reconnect_failed:1,reconnect_error:1,reconnecting:1,ping:1,pong:1},f=i.prototype.emit;function p(e,t,n){this.io=e,this.nsp=t,this.json=this,this.ids=0,this.acks={},this.receiveBuffer=[],this.sendBuffer=[],this.connected=!1,this.disconnected=!0,this.flags={},n&&n.query&&(this.query=n.query),this.io.autoConnect&&this.open()}i(p.prototype),p.prototype.subEvents=function(){if(!this.subs){var e=this.io;this.subs=[s(e,"open",a(this,"onopen")),s(e,"packet",a(this,"onpacket")),s(e,"close",a(this,"onclose"))]}},p.prototype.open=p.prototype.connect=function(){return this.connected?this:(this.subEvents(),this.io.open(),"open"===this.io.readyState&&this.onopen(),this.emit("connecting"),this)},p.prototype.send=function(){var e=o(arguments);return e.unshift("message"),this.emit.apply(this,e),this},p.prototype.emit=function(e){if(h.hasOwnProperty(e))return f.apply(this,arguments),this;var t=o(arguments),n={type:(void 0!==this.flags.binary?this.flags.binary:c(t))?r.BINARY_EVENT:r.EVENT,data:t,options:{}};return n.options.compress=!this.flags||!1!==this.flags.compress,"function"==typeof t[t.length-1]&&(l("emitting packet with ack id %d",this.ids),this.acks[this.ids]=t.pop(),n.id=this.ids++),this.connected?this.packet(n):this.sendBuffer.push(n),this.flags={},this},p.prototype.packet=function(e){e.nsp=this.nsp,this.io.packet(e)},p.prototype.onopen=function(){if(l("transport is open - connecting"),"/"!==this.nsp)if(this.query){var e="object"==typeof this.query?u.encode(this.query):this.query;l("sending connect packet with query %s",e),this.packet({type:r.CONNECT,query:e})}else this.packet({type:r.CONNECT})},p.prototype.onclose=function(e){l("close (%s)",e),this.connected=!1,this.disconnected=!0,delete this.id,this.emit("disconnect",e)},p.prototype.onpacket=function(e){var t=e.nsp===this.nsp,n=e.type===r.ERROR&&"/"===e.nsp;if(t||n)switch(e.type){case r.CONNECT:this.onconnect();break;case r.EVENT:case r.BINARY_EVENT:this.onevent(e);break;case r.ACK:case r.BINARY_ACK:this.onack(e);break;case r.DISCONNECT:this.ondisconnect();break;case r.ERROR:this.emit("error",e.data)}},p.prototype.onevent=function(e){var t=e.data||[];l("emitting event %j",t),null!=e.id&&(l("attaching ack callback to event"),t.push(this.ack(e.id))),this.connected?f.apply(this,t):this.receiveBuffer.push(t)},p.prototype.ack=function(e){var t=this,n=!1;return function(){if(!n){n=!0;var i=o(arguments);l("sending ack %j",i),t.packet({type:c(i)?r.BINARY_ACK:r.ACK,id:e,data:i})}}},p.prototype.onack=function(e){var t=this.acks[e.id];"function"==typeof t?(l("calling ack %s with %j",e.id,e.data),t.apply(this,e.data),delete this.acks[e.id]):l("bad ack %s",e.id)},p.prototype.onconnect=function(){this.connected=!0,this.disconnected=!1,this.emit("connect"),this.emitBuffered()},p.prototype.emitBuffered=function(){var e;for(e=0;e<this.receiveBuffer.length;e++)f.apply(this,this.receiveBuffer[e]);for(this.receiveBuffer=[],e=0;e<this.sendBuffer.length;e++)this.packet(this.sendBuffer[e]);this.sendBuffer=[]},p.prototype.ondisconnect=function(){l("server disconnect (%s)",this.nsp),this.destroy(),this.onclose("io server disconnect")},p.prototype.destroy=function(){if(this.subs){for(var e=0;e<this.subs.length;e++)this.subs[e].destroy();this.subs=null}this.io.destroy(this)},p.prototype.close=p.prototype.disconnect=function(){return this.connected&&(l("performing disconnect (%s)",this.nsp),this.packet({type:r.DISCONNECT})),this.destroy(),this.connected&&this.onclose("io client disconnect"),this},p.prototype.compress=function(e){return this.flags.compress=e,this},p.prototype.binary=function(e){return this.flags.binary=e,this}},function(e,t){function n(e,t,n){return e.on(t,n),{destroy:function(){e.removeListener(t,n)}}}e.exports=n},function(e,t){var n=[].slice;e.exports=function(e,t){if("string"==typeof t&&(t=e[t]),"function"!=typeof t)throw new Error("bind() requires a function");var r=n.call(arguments,2);return function(){return t.apply(e,r.concat(n.call(arguments)))}}},function(e,t){e.exports=function e(){if("undefined"==typeof window)return null;var t={RTCPeerConnection:window.RTCPeerConnection||window.mozRTCPeerConnection||window.webkitRTCPeerConnection,RTCSessionDescription:window.RTCSessionDescription||window.mozRTCSessionDescription||window.webkitRTCSessionDescription,RTCIceCandidate:window.RTCIceCandidate||window.mozRTCIceCandidate||window.webkitRTCIceCandidate};return t.RTCPeerConnection?t:null}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(457),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(969),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(970),v=n(458),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(126),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(126),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(457),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(458),y;function v(){}function b(e,t){l=l||n(126),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(126),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(126),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t){var n=e.exports=function(e){!function t(){var n=!0,r=!1,i=!1;do{i=!0,n=!1,e.call(this,function(){i?n=!0:t()}),i=!1}while(n)}()}},function(e,t,n){"use strict";(function(r){const i=n(22),o=n(15),s=n(51),a=n(72);function l(e){const t=e.protos(),n=t[0].name,r=t[1].name,i=t[2].name,o=e.stringTuples(),s=o[1][1];if("tcp"!==r||"ws"!==i&&"wss"!==i)throw new Error("invalid multiaddr: "+e.toString());let a=o[0][1];"ip6"===n&&(a="["+a+"]");let l="wss"===i?"https":"http",u="ws"===i&&80===s||"wss"===i&&443===s?"":s;return l+"://"+a+(u?":"+u:"")}const u={string:e=>"string"==typeof e,object:e=>"object"==typeof e,multiaddr:e=>{if(u.string(e))try{return i(e),!0}catch(e){return!1}},function:e=>"function"==typeof e};function c(e,t){if(!Array.isArray(t))throw new Error("Data is not an array");e.forEach((e,n)=>{if(!u[e])throw console.error("Type %s does not exist",e),new Error("Type "+e+" does not exist");if(!u[e](t[n]))throw new Error("Data at index "+n+" is invalid for type "+e)})}function h(e){e||(e=(()=>{}));const t=this;t.requests={},t.addRequest=((e,n,r)=>{t.requests[e]={def:n,handle:r}}),t.handleSocket=(n=>{n.r={},Object.keys(t.requests).forEach(r=>{const i=t.requests[r];n.on(r,function(){const t=[...arguments];try{c(i.def,t),t.unshift(n),i.handle.apply(null,t)}catch(i){e(i),e("peer %s has sent invalid data for request %s",n.id||"<server>",r,t)}})})})}function f(e,t,n){o.createFromPubKey(r.from(e,"hex"),(i,o)=>i?n(new Error("Crypto error")):o.toB58String()!==t?n(new Error("Id is not matching")):n(null,s.keys.unmarshalPublicKey(r.from(e,"hex"))))}t=e.exports,t.cleanUrlSIO=l,t.validate=c,t.Protocol=h,t.getIdAndValidate=f,t.validateMa=(e=>a.WebSocketStar.matches(i(e)))}).call(this,n(0).Buffer)},function(e,t,n){var r=n(981),i=n(121),o=i;o.v1=r,o.v4=i,e.exports=o},function(e,t,n){"use strict";e.exports="/mplex/6.7.0"},function(e,t,n){"use strict";const r=n(27),i=n(44),o=n(1004);class s{constructor(e,t,n){this.dht=e,this.key=t,this.makePath=n,this._log=i.logger(this.dht.peerInfo.id,"query:"+r.toB58String(t)),this.running=!1,this._onStart=this._onStart.bind(this),this._onComplete=this._onComplete.bind(this)}run(e,t){return this.dht._queryManager.running?0===e.length?(this._log.error("Running query with no peers"),t(null,{finalSet:new Set,paths:[]})):(this._run=new o(this),this._log(`query running with K=${this.dht.kBucketSize}, A=${this.dht.concurrency}, D=${Math.min(this.dht.disjointPaths,e.length)}`),this._run.once("start",this._onStart),this._run.once("complete",this._onComplete),void this._run.execute(e,t)):(this._log.error("Attempt to run query after shutdown"),t(null,{finalSet:new Set,paths:[]}))}_onStart(){this.running=!0,this._startTime=Date.now(),this._log("query:start"),this.dht._queryManager.queryStarted(this)}_onComplete(){this.stop()}stop(){this._log(`query:done in ${Date.now()-this._startTime}ms`),this._run&&this._log(`${this._run.errors.length} of ${this._run.peersSeen.size} peers errored (${this._run.errors.length/this._run.peersSeen.size*100}% fail rate)`),this.running&&(this._run.removeListener("start",this._onStart),this._run.removeListener("complete",this._onComplete),this.running=!1,this._run&&this._run.stop(),this.dht._queryManager.queryCompleted(this))}}e.exports=s},function(e,t){e.exports=function(e){if(!e)throw Error("hashlru must have a max value, of type number, greater than 0");var t=0,n=Object.create(null),r=Object.create(null);function i(i,o){n[i]=o,t++,t>=e&&(t=0,r=n,n=Object.create(null))}return{has:function(e){return void 0!==n[e]||void 0!==r[e]},remove:function(e){void 0!==n[e]&&(n[e]=void 0),void 0!==r[e]&&(r[e]=void 0)},get:function(e){var t=n[e];return void 0!==t?t:void 0!==(t=r[e])?(i(e,t),t):void 0},set:function(e,t){void 0!==n[e]?n[e]=t:i(e,t)},clear:function(){n=Object.create(null),r=Object.create(null)}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(273),i=a(r),o=n(334),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,i.default)(s.default),e.exports=t.default},function(e,t,n){"use strict";(function(t){const r=n(102),i=n(52),o=n(216),s=o.writeEncoded;function a(e,n,o){const a=r({timeout:6e4},n),l=a.handshake;return o("writing multicodec: "+e),s(l,t.from(e+"\n"),n),i.decodeFromReader(l,(t,r)=>{if(t)return n(t);const i=r.toString().slice(0,-1);if(i!==e)return n(new Error(`"${e}" not supported`),l.rest());o("received ack: "+i),n(null,l.rest())}),a}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";function r(e,t,n){const r=e===t;n(null,r)}e.exports=r},function(e,t,n){"use strict";t=e.exports,t.PROTOCOL_ID="/multistream/1.0.0"},function(e,t,n){"use strict";const r=n(160),i=n(274),o=n(215),s=n(39),a=n(472),l=n(36),u=n(47),c=n(280),h=n(13),{msHandle:f,msSelect:p,identifyDialer:d}=n(279),m=n(282),{CONNECTION_FAILED:g,DIAL_SELF:y,INVALID_STATE_TRANSITION:v,NO_TRANSPORTS_REGISTERED:b,maybeUnexpectedEnd:_}=n(217);class w extends a{constructor({_switch:e,peerInfo:t,muxer:n,conn:i,type:o="out"}){super({_switch:e,name:`${o}:${e._peerInfo.id.toB58String().slice(0,8)}`}),this.theirPeerInfo=t,this.theirB58Id=this.theirPeerInfo.id.toB58String(),this.conn=i,this.muxer=n;let s="DISCONNECTED";this.muxer&&(s="MUXED"),this._state=r(s,{DISCONNECTED:{dial:"DIALING",disconnect:"DISCONNECTED",done:"DISCONNECTED"},DIALING:{abort:"ABORTED",done:"DIALED",error:"ERRORED",disconnect:"DISCONNECTING"},DIALED:{encrypt:"ENCRYPTING",privatize:"PRIVATIZING"},PRIVATIZING:{done:"PRIVATIZED",abort:"ABORTED",disconnect:"DISCONNECTING"},PRIVATIZED:{encrypt:"ENCRYPTING"},ENCRYPTING:{done:"ENCRYPTED",error:"ERRORED",disconnect:"DISCONNECTING"},ENCRYPTED:{upgrade:"UPGRADING",disconnect:"DISCONNECTING"},UPGRADING:{stop:"CONNECTED",done:"MUXED",error:"ERRORED",disconnect:"DISCONNECTING"},MUXED:{disconnect:"DISCONNECTING"},CONNECTED:{disconnect:"DISCONNECTING"},DISCONNECTING:{done:"DISCONNECTED",disconnect:"DISCONNECTING"},ABORTED:{},ERRORED:{disconnect:"DISCONNECTING"}}),this._state.on("DISCONNECTED",()=>this._onDisconnected()),this._state.on("DIALING",()=>this._onDialing()),this._state.on("DIALED",()=>this._onDialed()),this._state.on("PRIVATIZING",()=>this._onPrivatizing()),this._state.on("PRIVATIZED",()=>this._onPrivatized()),this._state.on("ENCRYPTING",()=>this._onEncrypting()),this._state.on("ENCRYPTED",()=>{this.log("successfully encrypted connection to %s",this.theirB58Id),this.emit("encrypted",this.conn)}),this._state.on("UPGRADING",()=>this._onUpgrading()),this._state.on("MUXED",()=>{this.log("successfully muxed connection to %s",this.theirB58Id),delete this.switch.conns[this.theirB58Id],this.emit("muxed",this.muxer)}),this._state.on("CONNECTED",()=>{this.log("unmuxed connection opened to %s",this.theirB58Id),this.emit("unmuxed",this.conn)}),this._state.on("DISCONNECTING",()=>this._onDisconnecting()),this._state.on("ABORTED",()=>this._onAborted()),this._state.on("ERRORED",()=>this._onErrored()),this._state.on("error",e=>this._onStateError(e))}dial(){return this.theirB58Id===this.ourPeerInfo.id.toB58String()?this.emit("error",y()):"DIALING"===this.getState()?this.log("attempted to dial while already dialing, ignoring"):void this._state("dial")}shake(e,t){return e?this.muxer&&this.muxer.newStream?this.muxer.newStream((n,r)=>{if(n)return t(n,null);this.log("created new stream to %s",this.theirB58Id),this._protocolHandshake(e,r,t)}):void this._protocolHandshake(e,this.conn,t):t(null,null)}upgrade(){this._state("upgrade")}_onDialing(){if(this.log("dialing %s",this.theirB58Id),!this.switch.hasTransports())return this.close(b());const e=this.switch.availableTransports(this.theirPeerInfo),t=Boolean(this.switch.transports[i.tag]);t&&!e.includes(i.tag)&&e.push(i.tag);const n=r=>{let o=r;if(!o)return t?this.close(g(`No available transports to dial peer ${this.theirB58Id}!`)):this.close(g(`Circuit not enabled and all transports failed to dial peer ${this.theirB58Id}!`));o===i.tag&&this.theirPeerInfo.multiaddrs.add(`/p2p-circuit/p2p/${this.theirB58Id}`),this.log("dialing transport %s",o),this.switch.transport.dial(o,this.theirPeerInfo,(t,r)=>{if(t)return this.emit("error:connection_attempt_failed",t),this.log(t),n(e.shift());this.conn=m(o,null,r,this.switch.observer),this._state("done")})};n(e.shift())}_onDialed(){this.log("successfully dialed %s",this.theirB58Id),this.emit("connected",this.conn)}_onDisconnecting(){this.log("disconnecting from %s",this.theirB58Id,Boolean(this.muxer)),delete this.switch.conns[this.theirB58Id];let e=[];if(this.muxer&&e.push(e=>{this.muxer.end(()=>{delete this.muxer,e()})}),this.conn){try{this.conn.source.abort()}catch(e){}delete this.conn}l(e,()=>{this._state("done")})}_onEncrypting(){const e=new o.Dialer;e.handle(this.conn,t=>{if(t)return this.close(_(t));this.log("selecting crypto %s to %s",this.switch.crypto.tag,this.theirB58Id),e.select(this.switch.crypto.tag,(e,t)=>{if(e)return this.close(_(e));const n=m(null,this.switch.crypto.tag,t,this.switch.observer),r=this.switch.crypto.encrypt(this.ourPeerInfo.id,n,this.theirPeerInfo.id,e=>{if(e)return this.close(e);this.conn=r,this.conn.setPeerInfo(this.theirPeerInfo),this._state("done")})})})}_onUpgrading(){const e=Object.keys(this.switch.muxers);if(this.log("upgrading connection to %s",this.theirB58Id),0===e.length)return this._state("stop");const t=new o.Dialer;t.handle(this.conn,n=>{if(n)return this._didUpgrade(n);const r=n=>{this.log("selecting %s",n),t.select(n,(t,i)=>{if(t)return 0===e.length?this._didUpgrade(t):r(e.shift());const o=m(null,n,i,this.switch.observer);this.muxer=this.switch.muxers[n].dialer(o),this.muxer.once("close",()=>{this.close()}),this.muxer.on("stream",e=>{this.log("new stream created via muxer to %s",this.theirB58Id),e.setPeerInfo(this.theirPeerInfo),this.switch.protocolMuxer(null)(e)}),this._didUpgrade(null),this.switch.identify&&this._identify((e,t)=>{if(e)return this.close(e);this.theirPeerInfo=this.switch._peerBook.put(t.peerInfo)})})};r(e.shift())})}_identify(e){if(!this.muxer)return u(e,h("The connection was already closed","ERR_CONNECTION_CLOSED"));this.muxer.newStream(async(t,n)=>{if(t)return e(t);const r=new o.Dialer;let i;try{await f(r,n);const o=await p(r,c.multicodec);i=await d(o,this.theirPeerInfo)}catch(t){return e(t)}e(null,i)})}_didUpgrade(e){if(e)return this.log("Error upgrading connection:",e),this.switch.conns[this.theirB58Id]=this,this.emit("error:upgrade_failed",e),this._state("stop");this._state("done")}_protocolHandshake(e,t,n){const r=new o.Dialer;r.handle(t,t=>{if(t)return n(t,null);r.select(e,(t,r)=>{if(t)return this.log("could not perform protocol handshake:",t),n(t,null);const i=m(null,e,r,this.switch.observer);this.log("successfully performed handshake of %s to %s",e,this.theirB58Id),this.emit("connection",i),n(null,i)})})}_onStateError(e){this.emit("error",v(e)),this.log(e)}}e.exports=s(w,{className:"ConnectionFSM",symbolName:"libp2p-switch/ConnectionFSM"})},function(e,t,n){"use strict";const r=n(6).EventEmitter,i=n(4),o=n(39);class s extends r{constructor({_switch:e,name:t}){super(),this.switch=e,this.ourPeerInfo=this.switch._peerInfo,this.log=i(`libp2p:conn:${t}`),this.log.error=i(`libp2p:conn:${t}:error`)}close(e){"DISCONNECTING"!==this._state._state&&(this.log("closing connection to %s",this.theirB58Id),e&&this._events.error&&this.emit("error",e),this._state("disconnect"))}emit(e,...t){"error"!==e||this._events.error?super.emit(e,...t):this.log.error(...t)}getState(){return this._state._state}encrypt(){this._state("encrypt")}protect(){this._state("privatize")}upgrade(){this._state("upgrade")}_onDisconnected(){this.switch.connection.remove(this),this.log("disconnected from %s",this.theirB58Id),this.emit("close"),this.removeAllListeners()}_onPrivatized(){this.emit("private",this.conn)}_onPrivatizing(){if(!this.switch.protector)return this._state("done");this.conn=this.switch.protector.protect(this.conn,e=>{if(e)return this.close(e);this.log("successfully privatized conn to %s",this.theirB58Id),this.conn.setPeerInfo(this.theirPeerInfo),this._state("done")})}}e.exports=o(s,{className:"BaseConnection",symbolName:"libp2p-switch/BaseConnection"})},function(e,t,n){"use strict";const r=n(20);e.exports={tag:"/plaintext/1.0.0",encrypt:(e,t,n,i)=>("function"==typeof n&&(i=n,n=void 0),r(()=>i()),t)}},function(e,t,n){"use strict";const r=n(15),i=n(31),o=n(22);function s(e,t){let n;if(i.isPeerInfo(e))return t.put(e);if(o.isMultiaddr(e)){const o=e.getPeerId();try{n=t.get(o)}catch(e){n=new i(r.createFromB58String(o))}return n.multiaddrs.add(e),n}if(r.isPeerId(e)){const n=e.toB58String();try{return t.get(n)}catch(e){throw new Error(`Couldnt get PeerInfo for ${n}`)}}throw new Error("peer type not recognized")}e.exports=s},function(e,t,n){"use strict";var r=n(1056);function i(e,t,n){var i=this;function o(){i._rescheduled>0?(i._scheduled=i._rescheduled-(r()-i._started),i._timer=setTimeout(o,i._scheduled),i._rescheduled=0):e.apply(null,i._args)}this._started=r(),this._rescheduled=0,this._scheduled=t,this._args=n,this._timer=setTimeout(o,t)}function o(){if("function"!=typeof arguments[0])throw new Error("callback needed");if("number"!=typeof arguments[1])throw new Error("timeout needed");var e;if(arguments.length>0){e=new Array(arguments.length-2);for(var t=0;t<e.length;t++)e[t]=arguments[t+2]}return new i(arguments[0],arguments[1],e)}i.prototype.reschedule=function(e){var t=r();return!(t+e-(this._started+this._scheduled)<0)&&(this._started=t,this._rescheduled=e,!0)},i.prototype.clear=function(){clearTimeout(this._timer)},e.exports=o},function(e,t,n){var r=n(477);function i(e,t,n){var i=null==e?void 0:r(e,t);return void 0===i?n:i}e.exports=i},function(e,t,n){var r=n(478),i=n(222);function o(e,t){t=r(t,e);for(var n=0,o=t.length;null!=e&&n<o;)e=e[i(t[n++])];return n&&n==o?e:void 0}e.exports=o},function(e,t,n){var r=n(65),i=n(284),o=n(1071),s=n(288);function a(e,t){return r(e)?e:i(e,t)?[e]:o(s(e))}e.exports=a},function(e,t){var n=Function.prototype,r=n.toString;function i(e){if(null!=e){try{return r.call(e)}catch(e){}try{return e+""}catch(e){}}return""}e.exports=i},function(e,t){function n(e,t){return e===t||e!=e&&t!=t}e.exports=n},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(1097),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t,n){"use strict";const r=n(6),i=n(12),o=n(88),s=n(38),a=n(1105),l=n(4),u=n(13),c=n(1107),h=n(290),{signMessage:f}=n(1110),p=n(1111),d=n(47);class m extends r{constructor(e,t,n,r){super(),r={signMessages:!0,...r},this.log=l(e),this.log.err=l(`${e}:error`),this.multicodec=t,this.libp2p=n,this.started=!1,r.signMessages&&(this.peerId=this.libp2p.peerInfo.id),this.topics=new Map,this.seenCache=new a,this.peers=new Map,this._dials=new Set,this._onConnection=this._onConnection.bind(this),this._dialPeer=this._dialPeer.bind(this)}_addPeer(e){const t=e.info.id.toB58String();let n=this.peers.get(t);return n||(this.log("new peer",t),this.peers.set(t,e),n=e,e.once("close",()=>this._removePeer(e))),++n._references,n}_removePeer(e){const t=e.info.id.toB58String();return this.log("remove",t,e._references),0==--e._references&&(this.log("delete peer",t),this.peers.delete(t)),e}_dialPeer(e,t){t=t||function e(){};const n=e.id.toB58String(),r=this.peers.get(n);return r&&r.isConnected?d(()=>t()):this._dials.has(n)?(this.log("already dialing %s, ignoring dial attempt",n),d(()=>t())):(this._dials.add(n),this.log("dialing %s",n),void this.libp2p.dialProtocol(e,this.multicodec,(r,i)=>{this.log("dial to %s complete",n);const o=!this._dials.has(n);return this._dials.delete(n),r?(this.log.err(r),t()):o?(this.log("pubsub was stopped, not processing dial to %s",n),t()):void this._onDial(e,i,t)}))}_onDial(e,t,n){const r=e.id.toB58String();this.log("connected",r);const i=this._addPeer(new c(e));i.attachConnection(t),d(()=>n())}_onConnection(e,t){t.getPeerInfo((e,n)=>{if(e)return this.log.err("Failed to identify incomming conn",e),i(o(),t);const r=n.id.toB58String(),s=this._addPeer(new c(n));this._processConnection(r,t,s)})}_processConnection(e,t,n){throw u("_processConnection must be implemented by the subclass","ERR_NOT_IMPLEMENTED")}_onConnectionEnd(e,t,n){n&&"socket hang up"!==n.message&&this.log.err(n),this.log("connection ended",e,n?n.message:""),this._removePeer(t)}_buildMessage(e,t){const n=p.normalizeOutRpcMessage(e);this.peerId?f(this.peerId,n,t):d(t,null,n)}publish(e,t,n){throw u("publish must be implemented by the subclass","ERR_NOT_IMPLEMENTED")}subscribe(e){throw u("subscribe must be implemented by the subclass","ERR_NOT_IMPLEMENTED")}unsubscribe(e){throw u("unsubscribe must be implemented by the subclass","ERR_NOT_IMPLEMENTED")}start(e){if(this.started)return d(()=>e(new Error("already started")));this.log("starting"),this.libp2p.handle(this.multicodec,this._onConnection),this.libp2p.on("peer:connect",this._dialPeer);const t=Object.values(this.libp2p.peerBook.getAll());s(t,(e,t)=>this._dialPeer(e,t),t=>{d(()=>{this.log("started"),this.started=!0,e(t)})})}stop(e){if(!this.started)return d(()=>e(new Error("not started yet")));this.libp2p.unhandle(this.multicodec),this.libp2p.removeListener("peer:connect",this._dialPeer),this._dials=new Set,this.log("stopping"),s(this.peers.values(),(e,t)=>e.close(t),t=>{if(t)return e(t);this.log("stopped"),this.peers=new Map,this.started=!1,e()})}}e.exports=m,e.exports.message=h,e.exports.utils=p},function(e){e.exports={name:"ipfs",version:"0.35.0",description:"JavaScript implementation of the IPFS specification",leadMaintainer:"Alan Shaw <alan@tableflip.io>",bin:{jsipfs:"src/cli/bin.js"},main:"src/core/index.js",browser:{"./src/core/components/init-assets.js":!1,"./src/core/runtime/add-from-fs-nodejs.js":"./src/core/runtime/add-from-fs-browser.js","./src/core/runtime/config-nodejs.js":"./src/core/runtime/config-browser.js","./src/core/runtime/dns-nodejs.js":"./src/core/runtime/dns-browser.js","./src/core/runtime/fetch-nodejs.js":"./src/core/runtime/fetch-browser.js","./src/core/runtime/libp2p-nodejs.js":"./src/core/runtime/libp2p-browser.js","./src/core/runtime/preload-nodejs.js":"./src/core/runtime/preload-browser.js","./src/core/runtime/repo-nodejs.js":"./src/core/runtime/repo-browser.js","./src/core/runtime/ipld-nodejs.js":"./src/core/runtime/ipld-browser.js","./test/utils/create-repo-nodejs.js":"./test/utils/create-repo-browser.js",stream:"readable-stream",joi:"joi-browser"},"browser-all-ipld-formats":{"./src/core/runtime/ipld-browser.js":"./src/core/runtime/ipld-browser-all.js"},engines:{node:">=10.0.0",npm:">=6.0.0"},scripts:{lint:"aegir lint",build:"aegir build",test:"aegir test -t node -t browser -t webworker --no-cors --timeout=10000","test:node":"aegir test -t node --timeout=10000","test:browser":"aegir test -t browser --no-cors --timeout=10000","test:webworker":"aegir test -t webworker --no-cors --timeout=10000","test:node:core":"aegir test -t node -f test/core/**/*.js --timeout=10000","test:node:http":"aegir test -t node -f test/http-api/index.js --timeout=10000","test:node:gateway":"aegir test -t node -f test/gateway/index.js --timeout=10000","test:node:cli":"aegir test -t node -f test/cli/index.js --timeout=10000","test:node:interface":"aegir test -t node -f test/core/interface.spec.js --timeout=10000","test:bootstrapers":"IPFS_TEST=bootstrapers aegir test -t browser -f test/bootstrapers.js --timeout=10000",benchmark:'echo "Error: no benchmarks yet" && exit 1',"benchmark:node":'echo "Error: no benchmarks yet" && exit 1',"benchmark:node:core":'echo "Error: no benchmarks yet" && exit 1',"benchmark:node:http":'echo "Error: no benchmarks yet" && exit 1',"benchmark:browser":'echo "Error: no benchmarks yet" && exit 1',release:"aegir release -t node -t browser","release-minor":"aegir release --type minor -t node -t browser","release-major":"aegir release --type major -t node -t browser"},repository:{type:"git",url:"git+https://github.com/ipfs/js-ipfs.git"},keywords:["IPFS"],license:"MIT",bugs:{url:"https://github.com/ipfs/js-ipfs/issues"},homepage:"https://github.com/ipfs/js-ipfs#readme",devDependencies:{aegir:"^18.1.0",chai:"^4.2.0",delay:"^4.1.0","detect-node":"^2.0.4","dir-compare":"^1.4.0","dirty-chai":"^2.0.1",execa:"^1.0.0","form-data":"^2.3.3",hat:"0.0.3","interface-ipfs-core":"~0.99.1","ipfsd-ctl":"~0.42.0","libp2p-websocket-star":"~0.10.2",ncp:"^2.0.0",qs:"^6.5.2",rimraf:"^2.6.2",sinon:"^7.3.1","stream-to-promise":"^2.2.0"},dependencies:{async:"^2.6.1","bignumber.js":"^8.0.2","binary-querystring":"~0.1.2",bl:"^3.0.0",boom:"^7.2.0",bs58:"^4.0.1",byteman:"^1.3.5","cid-tool":"~0.2.0",cids:"~0.5.8","class-is":"^1.1.0","datastore-core":"~0.6.0","datastore-pubsub":"~0.1.1",debug:"^4.1.0",dlv:"^1.1.2","err-code":"^1.1.2","file-type":"^10.2.0",fnv1a:"^1.0.1","fsm-event":"^2.1.0","get-folder-size":"^2.0.0",glob:"^7.1.3",hapi:"^18.0.0","hapi-pino":"^5.2.0","human-to-milliseconds":"^1.0.0","interface-datastore":"~0.6.0","ipfs-bitswap":"~0.23.0","ipfs-block":"~0.8.0","ipfs-block-service":"~0.15.1","ipfs-http-client":"^30.1.1","ipfs-http-response":"~0.2.1","ipfs-mfs":"~0.10.2","ipfs-multipart":"~0.1.0","ipfs-repo":"~0.26.1","ipfs-unixfs":"~0.1.16","ipfs-unixfs-exporter":"~0.36.1","ipfs-unixfs-importer":"~0.38.5",ipld:"~0.21.1","ipld-bitcoin":"~0.1.8","ipld-dag-cbor":"~0.13.1","ipld-dag-pb":"~0.15.3","ipld-ethereum":"^2.0.1","ipld-git":"~0.3.0","ipld-raw":"^2.0.1","ipld-zcash":"~0.1.6",ipns:"~0.5.0","is-ipfs":"~0.6.0","is-pull-stream":"~0.0.0","is-stream":"^1.1.0","iso-url":"~0.4.6",joi:"^14.3.0","just-flatten-it":"^2.1.0","just-safe-set":"^2.1.0",libp2p:"~0.25.0","libp2p-bootstrap":"~0.9.3","libp2p-crypto":"~0.16.0","libp2p-kad-dht":"~0.14.12","libp2p-keychain":"~0.4.1","libp2p-mdns":"~0.12.0","libp2p-mplex":"~0.8.4","libp2p-record":"~0.6.1","libp2p-secio":"~0.11.0","libp2p-tcp":"~0.13.0","libp2p-webrtc-star":"~0.15.5","libp2p-websocket-star-multi":"~0.4.0","libp2p-websockets":"~0.12.2",lodash:"^4.17.11",mafmt:"^6.0.2","merge-options":"^1.0.1","mime-types":"^2.1.21",mkdirp:"~0.5.1",multiaddr:"^6.0.0","multiaddr-to-uri":"^4.0.1",multibase:"~0.6.0",multicodec:"~0.5.0",multihashes:"~0.4.14","multihashing-async":"~0.5.1","node-fetch":"^2.3.0","peer-book":"~0.9.0","peer-id":"~0.12.0","peer-info":"~0.15.0",progress:"^2.0.1","promisify-es6":"^1.0.3",protons:"^1.0.1","pull-abortable":"^4.1.1","pull-cat":"^1.1.11","pull-defer":"~0.2.3","pull-file":"^1.1.0","pull-ndjson":"~0.1.1","pull-pushable":"^2.2.0","pull-sort":"^1.0.1","pull-stream":"^3.6.9","pull-stream-to-stream":"^1.3.4","readable-stream":"^3.1.1",receptacle:"^1.3.2","stream-to-pull-stream":"^1.7.3",superstruct:"~0.6.0","tar-stream":"^2.0.0",temp:"~0.9.0","update-notifier":"^2.5.0","uri-to-multiaddr":"^3.0.1",varint:"^5.0.0",yargs:"^13.2.2","yargs-promise":"^1.1.0"},optionalDependencies:{"prom-client":"^11.1.3","prometheus-gc-stats":"~0.6.0"},contributors:["0xflotus <0xflotus@gmail.com>","A_A <21040751+Otto-AA@users.noreply.github.com>","Alan Shaw <alan.shaw@protocol.ai>","Alan Shaw <alan@tableflip.io>","Alex North <alex@alexnorth.me>","Alex Potsides <alex@achingbrain.net>","Andrew Nesbitt <andrewnez@gmail.com>","Andrew de Andrade <andrew@deandrade.com.br>","André Cruz <andremiguelcruz@msn.com>","Arkadiy Kukarkin <parkan@users.noreply.github.com>","Arpit Agarwal <93arpit@gmail.com>","Arpit Agarwal <atvanguard@users.noreply.github.com>","Bernard Mordan <bernard@tableflip.io>","Brian Vander Schaaf <bvs330@gmail.com>","Bruno Zell <bruno.zzell@gmail.com>","CHEVALAY JOSSELIN <josselin54.chevalay@gmail.com>","Caio Gondim <me@caiogondim.com>","Chance Hudson <jchancehud@gmail.com>","Christian Couder <chriscool@tuxfamily.org>","Dafeng <dfguo.joe@gmail.com>","Dan Ordille <dordille@gmail.com>","Daniel J. O'Quinn <danieljoquinn@gmail.com>","Daniela Borges Matos de Carvalho <alunassertiva@gmail.com>","David Dias <daviddias.p@gmail.com>","David Gilbertson <gilbertson.david@gmail.com>","David da Silva <dasilvacontin@gmail.com>","Diogo Silva <fsdiogo@gmail.com>","Dmitriy Ryajov <dryajov@gmail.com>","Dzmitry Das <dbachko@gmail.com>","Enrico Marino <enrico.marino@email.com>","Faheel Ahmad <faheel@live.in>","Felix Yan <felixonmars@archlinux.org>","Francisco Baio Dias <xicombd@gmail.com>","Francisco Baio Dias <francisco@typeform.com>","Friedel Ziegelmayer <dignifiedquire@gmail.com>","Gar <gar+gh@danger.computer>","Georgios Rassias <georassias@gmail.com>","Gorka Ludlow <gorka@aquigorka.com>","Grant Herman <grantlouisherman041@gmail.com>","Greenkeeper <support@greenkeeper.io>","Haad <haadcode@users.noreply.github.com>","Haoliang Yu <haoliangyu@users.noreply.github.com>","Harsh Vakharia <harshjv@users.noreply.github.com>","Henrique Dias <hacdias@gmail.com>","Henry Rodrick <moshisushi@gmail.com>","Heo Sangmin <heo@mapiacompany.com>","Hugo Dias <mail@hugodias.me>","Hugo Dias <hugomrdias@gmail.com>","Irakli Gozalishvili <contact@gozala.io>","Jacob Heun <jacobheun@gmail.com>","Jacob Heun <jake@andyet.net>","Jade Meskill <jade.meskill@gmail.com>","Johannes Wikner <johannes.wikner@gmail.com>","Jon Schlinkert <dev@sellside.com>","Jonathan <jkrone@vt.edu>","João Antunes <j.goncalo.antunes@gmail.com>","João Santos <joaosantos15@users.noreply.github.com>","Kevin Wang <kevin@fossa.io>","Lars Gierth <larsg@systemli.org>","Lukas Drgon <lukas.drgon@gmail.com>","Maciej Krüger <mkg20001@gmail.com>","Marcin Rataj <lidel@lidel.org>","Marius Darila <marius.darila@gmail.com>","Mat Kelly <machawk1@gmail.com>","Michelle Lee <michelle@protocol.ai>","Mikeal Rogers <mikeal.rogers@gmail.com>","Mithgol <getgit@mithgol.ru>","Molly <momack2@users.noreply.github.com>","Mounish Sai <pvsmounish@gmail.com>","My9Bot <34904312+My9Bot@users.noreply.github.com>","Nitin Patel <31539366+niinpatel@users.noreply.github.com>","Nuno Nogueira <nunofmn@gmail.com>","Oli Evans <oli@tableflip.io>","Oskar Nyberg <oskar@oskarnyberg.com>","Pascal Precht <pascal.precht@googlemail.com>","Pau Ramon Revilla <masylum@gmail.com>","Paulo Rodrigues <me@paulogr.com>","Pedro Teixeira <i@pgte.me>","Portia Burton <plburton@gmail.com>","Raoul Millais <raoul@raoulmillais.com>","RasmusErik Voel Jensen <github@solsort.com>","Richard Littauer <richard.littauer@gmail.com>","Richard Schneider <makaretu@gmail.com>","Rob Brackett <rob@robbrackett.com>","Rod Keys <rod@zokos.com>","Sangwon Hong <qpakzk@gmail.com>","Sid Harder <sideharder@gmail.com>","SidHarder <softwarenavigator@gmail.com>","Stephen Whitmore <stephen.whitmore@gmail.com>","Stephen Whitmore <noffle@users.noreply.github.com>","Steven Allen <steven@stebalien.com>","Terence Pae <terencepae@gmail.com>","Uroš Jurglič <jurglic@gmail.com>","Vasco Santos <vasco.santos@ua.pt>","Vasco Santos <vasco.santos@moxy.studio>","Volker Mische <volker.mische@gmail.com>","Xiao Liang <yxliang01@users.noreply.github.com>","Yahya <ya7yaz@gmail.com>","Yole <yole@ultiledger.io>","bitspill <bitspill+github@bitspill.net>","datafatmunger <jbg@peerparty.org>","dirkmc <dirk@mccormick.cx>","haad <haad@headbanggames.com>","jbenet <juan@benet.ai>","jonahweissman <19804455+jonahweissman@users.noreply.github.com>","kevingzhang <kevin.zhang.canada@gmail.com>","kumavis <kumavis@users.noreply.github.com>","nginnever <ginneversource@gmail.com>","npmcdn-to-unpkg-bot <npmcdn-to-unpkg-bot@users.noreply.github.com>","robbsolter <35879806+robbsolter@users.noreply.github.com>","seungwon-kang <ksw3894@gmail.com>","tcme <hi@this-connect.me>","victorbjelkholm <victorbjelkholm@gmail.com>","Łukasz Magiera <magik6k@users.noreply.github.com>","Максим Ильин <negamaxi@gmail.com>"]}},function(e,t,n){"use strict";const r=n(2),i=n(261).repoVersion;e.exports=function e(t){return{init:(e,t,n)=>{},version:r(e=>{t._repo._isInitialized(n=>{if(n){const t=[/Key not found in database \[\/version\]/,/ENOENT/,/repo is not initialized yet/].some(e=>e.test(n.message));return t?e(null,i):e(n)}t._repo.version.get(e)})}),gc:r((e,t)=>{"function"==typeof e&&(t=e,e={}),t(new Error("Not implemented"))}),stat:r((e,n)=>{"function"==typeof e&&(n=e,e={}),t._repo.stat(e,(e,t)=>{if(e)return n(e);n(null,{numObjects:t.numObjects,repoSize:t.repoSize,repoPath:t.repoPath,version:t.version.toString(),storageMax:t.storageMax})})}),path:()=>t._repo.path}}},function(e,t,n){"use strict";e.exports=(()=>({Addresses:{Swarm:[],API:"",Gateway:""},Discovery:{MDNS:{Enabled:!1,Interval:10},webRTCStar:{Enabled:!0}},Bootstrap:["/dns4/ams-1.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLer265NRgSp2LA3dPaeykiS1J6DifTC88f5uVQKNAd","/dns4/lon-1.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLMeWqB7YGVLJN3pNLQpmmEk35v6wYtsMGLzSr5QBU3","/dns4/sfo-3.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLPppuBtQSGwKDZT2M73ULpjvfd3aZ6ha4oFGL1KrGM","/dns4/sgp-1.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLSafTMBsPKadTEgaXctDQVcqN88CNLHXMkTNwMKPnu","/dns4/nyc-1.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLueR4xBeUbY9WZ9xGUUxunbKWcrNFTDAadQJmocnWm","/dns4/nyc-2.bootstrap.libp2p.io/tcp/443/wss/ipfs/QmSoLV4Bbm51jM9C4gDYZQ9Cy3U6aXMJDAbzgu2fzaDs64","/dns4/node0.preload.ipfs.io/tcp/443/wss/ipfs/QmZMxNdpMkewiVZLMRxaNxUeZpDUb34pWjZ1kZvsd16Zic","/dns4/node1.preload.ipfs.io/tcp/443/wss/ipfs/Qmbut9Ywz9YEDrz8ySBSgWyJk41Uvm2QJPhwDJzJyGFsD6"],Swarm:{ConnMgr:{LowWater:200,HighWater:500}}}))},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(19),o=n(1141),s=n(128),a=n(164).isSource;e.exports=function(e){const n=r((n,r,l)=>{"function"==typeof r&&(l=r,r={}),r=r||{};const u=e=>t.isBuffer(e)||s.readable(e)||a(e),c=e=>"object"==typeof e&&(e.content?u(e.content):Boolean(e.path)&&"string"==typeof e.path),h=e=>u(e)||c(e),f=h(n)||Array.isArray(n)&&n.every(h);if(!f)return l(new Error("invalid input: expected buffer, readable stream, pull stream, object or array of objects"));i(i.values([n]),e.addPullStream(r),o((e,t)=>e.path<t.path?1:e.path>t.path?-1:0),i.collect(l))});return function(){const e=Array.from(arguments);return 1===e.length&&a(e[0])&&e.push({}),n.apply(null,e)}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=n(1148)},function(e,t){e.exports=function(e){var t,n,r;function i(e){return n=e,function(e,i){r?t=[e,i]:n(e,i)}}return i.pause=function(){r||(r=!0,e&&e(r))},i.resume=function(){if(r&&(r=!1,e&&e(r),t)){var i=t;t=null,n(i[0],i[1])}},i}},function(e,t,n){"use strict";(function(t){e.exports=function e(n,r,i,o){const s=n.length,a=r+s;return i>=a||o<r?t.alloc(0):(o>=r&&o<a&&(n=n.slice(0,o-r)),i>=r&&i<a&&(n=n.slice(i-r)),n)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const{DAGNode:r,DAGLink:i}=n(34),o=n(9),s=n(10),a=n(154),l=n(4)("ipfs:mfs:core:utils:add-link"),u=n(45),c=n(225),{updateHamtDirectory:h,recreateHamtLevel:f,createShard:p,toPrefix:d,addLinksToHamtBucket:m}=n(491),g={parent:void 0,cid:void 0,name:"",size:void 0,flush:!0,cidVersion:0,hashAlg:"sha2-256",codec:"dag-pb",shardSplitThreshold:1e3},y=(e,t,n)=>{if(t=Object.assign({},g,t),!t.parentCid)return n(new Error("No parent CID passed to addLink"));if(!o.isCID(t.parentCid))return n(new Error("Invalid CID passed to addLink"));if(!t.parent)return l("Loading parent node",t.parentCid.toBaseEncodedString()),s([n=>e.ipld.get(t.parentCid,n),(e,t)=>t(null,e.value),(n,r)=>y(e,{...t,parent:n},r)],n);if(!t.cid)return n(new Error("No child cid passed to addLink"));if(!t.name)return n(new Error("No child name passed to addLink"));if(o.isCID(t.cid)||(t.cid=new o(t.cid)),!t.size&&0!==t.size)return n(new Error("No child size passed to addLink"));const r=u.unmarshal(t.parent.data);return"hamt-sharded-directory"===r.type?(l("Adding link to sharded directory"),_(e,t,n)):t.parent.links.length>=t.shardSplitThreshold?(l("Converting directory to sharded directory"),v(e,t,n)):(l(`Adding ${t.name} to regular directory`),void b(e,t,n))},v=(e,t,n)=>{p(e,t.parent.links.map(e=>({name:e.name,size:e.size,multihash:e.cid.buffer})).concat({name:t.name,size:t.size,multihash:t.cid.buffer}),{},(e,t)=>{e||l("Converted directory to sharded directory",t.cid.toBaseEncodedString()),n(e,t)})},b=(e,t,n)=>{s([e=>r.rmLink(t.parent,t.name,e),(e,n)=>r.addLink(e,new i(t.name,t.size,t.cid),n),(n,r)=>{e.ipld.put(n,{version:t.cidVersion,format:t.codec,hashAlg:t.hashAlg,hashOnly:!t.flush},(e,t)=>r(e,{node:n,cid:t}))}],n)},_=(e,t,n)=>w(e,t,(i,o)=>{if(i)return n(i);const{shard:a,path:l}=o;a.flush("",e.ipld,null,async(i,o)=>{if(i)return n(i);const a=t.parent.links.find(e=>e.name.substring(0,2)===l[0].prefix),u=o.node.links.find(e=>e.name.substring(0,2)===l[0].prefix);s([e=>{if(!a)return e(null,t.parent);r.rmLink(t.parent,a.name,e)},(e,t)=>r.addLink(e,u,t),(n,r)=>h(e,n.links,l[0].bucket,t,r)],n)})}),w=(e,t,n)=>{const r={name:t.name,cid:t.cid,size:t.size};f(t.parent.links,null,null,null,async(i,o)=>{if(i)return n(i);const s=new c({root:!0,dir:!0,parent:null,parentKey:null,path:"",dirty:!0,flat:!1});s._bucket=o;const u=await o._findNewBucketAndPos(r.name),h=k(u);h[0].node=t.parent;let p=0;a(()=>p<h.length,t=>{let n=h[p];p++;let i=n.node,a=i.links.find(e=>e.name.substring(0,2)===n.prefix);return a?a.name===`${n.prefix}${r.name}`?(l(`Link ${n.prefix}${r.name} will be replaced`),p=h.length,t(null,s)):a.name.length>2?(l(`Link ${a.name} will be replaced with a subshard`),p=h.length,t(null,s)):(l(`Found subshard ${n.prefix}`),void e.ipld.get(a.cid,(e,i)=>{if(e)return t(e);if(!h[p]){l(`Loaded new subshard ${n.prefix}`);const e=i.value;return f(e.links,o,n.bucket,parseInt(n.prefix,16),async n=>{if(n)return t(n);const i=await o._findNewBucketAndPos(r.name);return h.push({bucket:i.bucket,prefix:d(i.pos),node:e}),t(null,s)})}const a=h[p];m(i.value.links,a.bucket,o,e=>{a.node=i.value,t(e,s)})})):(l(`Link ${n.prefix}${r.name} will be added`),p=h.length,t(null,s))},(e,t)=>{if(e)return n(e);t.put(r.name,{size:r.size,multihash:r.cid.buffer},e=>{n(e,{shard:t,path:h})})})})},k=e=>{let t=e.bucket,n=e.pos,r=[{bucket:t,prefix:d(n)}];for(t=e.bucket._parent,n=e.bucket._posAtParent;t;)r.push({bucket:t,prefix:d(n)}),n=t._posAtParent,t=t._parent;return r.reverse(),r};e.exports=y},function(e,t,n){"use strict";(function(t){const{DAGNode:r}=n(34),i=n(10),o=n(154),s=n(43),a=n(294),l=n(225),u=n(4)("ipfs:mfs:core:utils:hamt-utils"),c=n(45),h=(e,n,o,s,a)=>{i([e=>{const i=t.from(o._children.bitField().reverse()),s=new c("hamt-sharded-directory",i);s.fanout=o.tableSize(),s.hashType=l.hashFn.code,r.create(s.marshal(),n,e)},(t,n)=>{e.ipld.put(t,{version:s.cidVersion,format:s.codec,hashAlg:s.hashAlg,hashOnly:!s.flush},(e,r)=>n(e,{node:t,cid:r}))}],a)},f=(e,t,n,r,i)=>{const o=new a({hashFn:l.hashFn,hash:n?n._options.hash:void 0},n,r);n&&n._putObjectAt(r,o),p(e,o,t,i)},p=(e,t,n,r)=>{Promise.all(e.map(e=>{if(2===e.name.length){const n=parseInt(e.name,16);return t._putObjectAt(n,new a({hashFn:l.hashFn},t,n)),Promise.resolve()}return(n||t).put(e.name.substring(2),{size:e.size,multihash:e.cid})})).then(()=>r(null,t),r)},d=e=>e.toString("16").toUpperCase().padStart(2,"0").substring(0,2),m=(e,t,n,r)=>{f(n.links,null,null,null,async(i,s)=>{if(i)return r(i);const a=await s._findNewBucketAndPos(t);let l=[{bucket:a.bucket,prefix:d(a.pos)}],c=a.bucket;for(;c!==s;)l.push({bucket:c,prefix:d(c._posAtParent)}),c=c._parent;l[l.length-1].node=n;let h=l.length;o(()=>h>0,n=>{h--;const r=l[h],i=r.node.links.filter(e=>e.name.substring(0,2)===r.prefix).pop();return i?i.name===`${r.prefix}${t}`?(u(`Link ${r.prefix}${t} will be replaced`),n(null,l)):(u(`Found subshard ${r.prefix}`),void e.ipld.get(i.cid,(e,i)=>{if(e)return n(e);if(!l[h-1]){u(`Loaded new subshard ${r.prefix}`);const e=i.value;return f(e.links,s,r.bucket,parseInt(r.prefix,16),async(r,i)=>{if(r)return n(r);const o=await s._findNewBucketAndPos(t);h++,l.unshift({bucket:o.bucket,prefix:d(o.pos),node:e}),n()})}const o=l[h-1];p(i.value.links,o.bucket,s,e=>{o.node=i.value,n(e)})})):(u(`Link ${r.prefix}${t} will be added`),n(null,l))},async(e,n)=>{await s.put(t,!0),r(e,{rootBucket:s,path:n})})})},g=(e,t,n,r)=>{const i=new l({root:!0,dir:!0,parent:null,parentKey:null,path:"",dirty:!0,flat:!1,...n}),o=t.map(e=>t=>{i.put(e.name,{size:e.size,multihash:e.multihash},t)});return s(o,t=>{if(t)return r(t);i.flush("",e.ipld,null,r)})};e.exports={generatePath:m,updateHamtDirectory:h,recreateHamtLevel:f,addLinksToHamtBucket:p,toPrefix:d,createShard:g}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=n(1201)},function(e,t){e.exports={WORKER_REQUEST_READ_LOCK:"lock:worker:request-read",WORKER_RELEASE_READ_LOCK:"lock:worker:release-read",MASTER_GRANT_READ_LOCK:"lock:master:grant-read",WORKER_REQUEST_WRITE_LOCK:"lock:worker:request-write",WORKER_RELEASE_WRITE_LOCK:"lock:worker:release-write",MASTER_GRANT_WRITE_LOCK:"lock:master:grant-write"}},function(e,t){const n={},r=e=>{e.addEventListener("message",t=>{r.dispatchEvent("message",e,t)}),e.port&&e.port.addEventListener("message",t=>{r.dispatchEvent("message",e,t)})};r.addEventListener=((e,t)=>{n[e]||(n[e]=[]),n[e].push(t)}),r.removeEventListener=((e,t)=>{n[e]&&(n[e]=n[e].filter(e=>e===t))}),r.dispatchEvent=function(){const e=Array.prototype.slice.call(arguments),t=e.shift();n[t]&&n[t].forEach(t=>t.apply(null,e))},e.exports=r},function(e,t,n){"use strict";const{FILE_SEPARATOR:r}=n(227),i=n(496),o=n(10),s=n(36),a=n(295),l="ipfs",u=(e,t,n)=>{let l=Array.isArray(t);const u=Array.isArray(t)?t:[t];o([t=>{s({paths:e=>{let t;try{t=u.map(e=>{if(e=(e||"").trim(),e=e.replace(/(\/\/+)/g,"/"),!e)throw new Error("paths must not be empty");if(e.substring(0,1)!==r)throw new Error(`paths must start with a leading ${r}`);return e.substring(e.length-r.length)===r&&(e=e.substring(0,e.length-r.length)),a(e)})}catch(t){return e(t)}e(null,t)},root:t=>i(e,t)},t)},({paths:e,root:t},n)=>{n(null,e.map(e=>{if("ipfs"===e[0]){let n;return n=2===e.length?`${r}${e.join(r)}`:`${r}${e.slice(0,e.length-1).join(r)}`,{type:"ipfs",depth:e.length-2,mfsPath:`${r}${e.join(r)}`,mfsDirectory:n,root:t,parts:e,path:`${r}${e.join(r)}`,name:e[e.length-1]}}const n=`/ipfs/${t.toBaseEncodedString()}/${e.join(r)}`,i=`/ipfs/${t.toBaseEncodedString()}/${e.slice(0,e.length-1).join(r)}`;return{type:"mfs",depth:e.length,mfsDirectory:i,mfsPath:n,root:t,parts:e,path:`${r}${e.join(r)}`,name:e[e.length-1]}}))},(e,t)=>{if(l)return t(null,e);t(null,e[0])}],n)};e.exports=u},function(e,t,n){"use strict";const r=n(9),i=n(45),{DAGNode:o}=n(34),s=n(4)("ipfs:mfs:utils:with-mfs-root"),a=n(10),{MFS_ROOT_KEY:l}=n(227),u=(e,t)=>{a([t=>e.repo.datastore.open(e=>t(e)),t=>{e.repo.datastore.get(l,(n,u)=>{if(n&&(n.notFound||"ERR_NOT_FOUND"===n.code))return s("Creating new MFS root"),a([e=>o.create(new i("directory").marshal(),e),(t,n)=>e.ipld.put(t,{version:0,hashAlg:"sha2-256",format:"dag-pb"},n),(t,n)=>e.repo.datastore.put(l,t.buffer,e=>n(e,t))],t);t(n,u?new r(u):null)})},(e,t)=>{s(`Fetched MFS root ${e.toBaseEncodedString()}`),t(null,e)}],t)};e.exports=u},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(498),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1223),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1224),v=n(499),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(129),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(129),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(498),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(499),y;function v(){}function b(e,t){l=l||n(129),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(129),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(129),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){(function(t){var r=n(503).strict;e.exports=function e(n){if(r(n)){var i=t.from(n.buffer);return n.byteLength!==n.buffer.byteLength&&(i=i.slice(n.byteOffset,n.byteOffset+n.byteLength)),i}return t.from(n)}}).call(this,n(0).Buffer)},function(e,t){e.exports=i,i.strict=o,i.loose=s;var n=Object.prototype.toString,r={"[object Int8Array]":!0,"[object Int16Array]":!0,"[object Int32Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Uint16Array]":!0,"[object Uint32Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0};function i(e){return o(e)||s(e)}function o(e){return e instanceof Int8Array||e instanceof Int16Array||e instanceof Int32Array||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Uint16Array||e instanceof Uint32Array||e instanceof Float32Array||e instanceof Float64Array}function s(e){return r[n.call(e)]}},function(e,t,n){"use strict";const r=n(495);function i(e,t,n,i){t=t.slice();const o=Object.assign({},n,t.filter(e=>"object"==typeof e).pop()||{});Array.isArray(t[0])&&(t=t[0]);const s=t.filter(e=>"string"==typeof e).map(e=>e.trim());r(e,s,(e,t)=>{i(e,{sources:t,options:o})})}e.exports=i},function(e,t,n){"use strict";const r=n(10),i=n(36),{addLink:o,updateTree:s,updateMfsRoot:a,toTrail:l,toSourcesAndDestination:u,toMfsPath:c}=n(73),h=n(229),f=n(297),p=n(4)("ipfs:mfs:cp"),d={parents:!1,flush:!0,format:"dag-pb",hashAlg:"sha2-256",shardSplitThreshold:1e3};e.exports=(e=>(function t(){const n=Array.from(arguments),i=n.pop();r([t=>u(e,n,d,t),({sources:e,destination:t,options:n},r)=>e.length?t?(n.parents=n.p||n.parents,void r(null,{sources:e,destination:t,options:n})):r(new Error("Please supply a destination")):r(new Error("Please supply at least one source")),({sources:t,destination:n,options:r},i)=>l(e,n.mfsPath,r,(o,s)=>{if(o)return i(o);if(s.length===n.parts.length)return p("Destination does not exist"),1===t.length?(p("Only one source, copying to a file"),m(e,t.pop(),n,s,r,i)):(p("Multiple sources, copying to a directory"),g(e,t,n,s,r,i));const a=s[s.length-1];if("dir"===a.type)return p("Destination is a directory"),g(e,t,n,s,r,i);i(new Error("directory already has entry by that name"))})],i)}));const m=(e,t,n,i,l,u)=>{r([n=>y(e,t,l,n),(t,s)=>{const a=i[i.length-1],l=t[t.length-1];r([t=>e.ipld.get(a.cid,t),(t,r)=>o(e,{parent:t.value,parentCid:a.cid,size:l.size,cid:l.cid,name:n.parts[n.parts.length-1]},r),({node:e,cid:t},n)=>{a.node=e,a.cid=t,a.size=e.size,n(null,i)}],s)},(t,n)=>s(e,t,l,n),({cid:t},n)=>a(e,t,n)],e=>u(e))},g=(e,t,n,u,d,m)=>{r([t=>{if(u.length!==n.parts.length+1)return p("Making destination directory",n.path),r([t=>f(e)(n.path,d,t),t=>c(e,n.path,t),(t,r)=>{n=t,l(e,n.mfsPath,d,r)}],(e,n)=>{if(e)return t(e);u=n,t()});t()},n=>i(t.map(t=>n=>y(e,t,d,n)),n),(l,c)=>{r([r=>{i(t.map(t=>r=>{h(e)(`${n.path}/${t.name}`,d,e=>{if(e)return e.message.includes("does not exist")?r():r(e);r(new Error("directory already has entry by that name"))})}),e=>r(e))},n=>{const i=u[u.length-1];r([t=>e.ipld.get(i.cid,t),(e,t)=>t(null,{cid:i.cid,node:e.value})].concat(l.map((n,r)=>(i,s)=>{const a=n[n.length-1];p(`Adding ${t[r].name} to ${i.cid.toBaseEncodedString()}`),o(e,{parent:i.node,parentCid:i.cid,size:a.size,cid:a.cid,name:t[r].name},(e,t)=>{if(e)return s(e);p(`New directory hash ${t.cid.toBaseEncodedString()}`),s(e,t)})})),n)},({node:e,cid:t},n)=>{const r=u[u.length-1];r.node=e,r.cid=t,r.size=e.size,n(null,u)},(t,n)=>s(e,t,d,n),({cid:t},n)=>a(e,t,n)],c)}],e=>m(e))},y=(e,t,n,r)=>{l(e,t.mfsPath,n,(e,n)=>e?r(e):"ipfs"===t.type?r(null,n):n.length!==t.parts.length+1?r(new Error(`${t.path} does not exist`)):void r(null,n))}},function(e,t,n){"use strict";const r=n(10),i=n(43),{updateTree:o,updateMfsRoot:s,toSources:a,removeLink:l,toMfsPath:u,toTrail:c,FILE_SEPARATOR:h}=n(73),f={recursive:!1,cidVersion:0,hashAlg:"sha2-256",format:"dag-pb"};e.exports=(e=>(function t(){const n=Array.from(arguments),o=n.pop();r([t=>a(e,n,f,t),({sources:t,options:n},r)=>{if(!t.length)return r(new Error("Please supply at least one path to remove"));i(t.map(t=>r=>p(e,t.path,n,r)),e=>r(e))}],o)}));const p=(e,t,n,i)=>{if(t===h)return i(new Error("Cannot delete root"));r([n=>u(e,t,n),({mfsPath:t,parts:r},i)=>c(e,t,n,(e,n)=>i(e,{mfsPath:t,parts:r,trail:n})),({trail:i},o)=>{const s=i.pop(),a=i[i.length-1];return a?"dir"!==s.type||n.recursive?void r([t=>l(e,{parentCid:a.cid,name:s.name},t),({cid:e},t)=>{a.cid=e,t(null,i)}],o):o(new Error(`${t} is a directory, use -r to remove directories`)):o(new Error(`${t} does not exist`))},(t,r)=>o(e,t,n,r),({cid:t},n)=>s(e,t,n)],i)}},function(e,t,n){"use strict";const r=n(163).OFFLINE_ERROR,i=n(2),o=n(20),s=n(55),a=n(9),l=n(15),u=n(13);function c(e,t){return Array.from(e).map(e=>({"/":e[1].cid.toBaseEncodedString()}))}e.exports=function e(t){return{wantlist:i((e,n)=>{if("function"==typeof e&&(n=e,e=null),!t.isOnline())return o(()=>n(new Error(r)));let i;if(e){try{e=l.createFromB58String(e)}catch(t){e=null}if(!e)return o(()=>n(new Error("Invalid peerId")));i=t._bitswap.wantlistForPeer(e)}else i=t._bitswap.getWantlist();o(()=>n(null,{Keys:c(i)}))}),stat:i(e=>{if(!t.isOnline())return o(()=>e(new Error(r)));const n=t._bitswap.stat().snapshot;o(()=>{e(null,{provideBufLen:parseInt(n.providesBufferLength.toString()),blocksReceived:new s(n.blocksReceived),wantlist:c(t._bitswap.getWantlist()),peers:t._bitswap.peers().map(e=>e.toB58String()),dupBlksReceived:new s(n.dupBlksReceived),dupDataReceived:new s(n.dupDataReceived),dataReceived:new s(n.dataReceived),blocksSent:new s(n.blocksSent),dataSent:new s(n.dataSent)})})}),unwant:i((e,n)=>{if(!t.isOnline())return o(()=>n(new Error(r)));Array.isArray(e)||(e=[e]);try{e=e.map(e=>a.isCID(e)?e:new a(e))}catch(e){return o(()=>n(u(e,"ERR_INVALID_CID")))}o(()=>n(null,t._bitswap.unwant(e)))})}}},function(e,t,n){"use strict";const r=n(2),i=/^((\d+(\.\d+)*)(ns|ms|us|µs|m|s|h))+$/,o=/((\d+(\.\d+)*)(ns|ms|us|µs|m|s|h))/g,s=/(ns|ms|us|µs|m|s|h)/g,a={ns:1e-6,us:.001,"µs":.001,ms:1,s:1e3,m:6e4,h:36e5};function l(e){let t=e.match(s)[0];return e=e.substring(0,e.length-t.length),parseFloat(e)*a[t]}e.exports=r(function(e,t){return"string"!=typeof e?t(new Error("the first argument must be a string")):i.test(e)?void t(null,e.match(o).reduce((e,t)=>e+l(t),0)):t(new Error("invalid time"))})},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(166),o=n(26),s=n(128),a=n(510),l=n(164).isSource,u=n(130),c=n(167);e.exports=(e=>{const n=c(e,"add"),h=r((e,r,c)=>{"function"==typeof r&&(c=r,r=null);const h=o(c);r||(r={}),r.converter=u;const f=e=>t.isBuffer(e)||s.readable(e)||l(e),p=e=>"object"==typeof e&&(e.content?f(e.content):Boolean(e.path)&&a(e.path)),d=e=>f(e)||p(e),m=d(e)||Array.isArray(e)&&e.every(d);if(!m)return h(new Error("invalid input: expected buffer, readable stream, pull stream, object or array of objects"));const g=[].concat(e),y=n({qs:r}),v=i(e=>h(null,e));y.once("error",h),y.pipe(v),g.forEach(e=>y.write(e)),y.end()});return function(){const e=Array.from(arguments);return 1===e.length&&l(e[0])&&e.push({}),h.apply(null,e)}})}).call(this,n(0).Buffer)},function(e,t,n){var r=n(108),i=n(65),o=n(87),s="[object String]";function a(e){return"string"==typeof e||!i(e)&&o(e)&&r(e)==s}e.exports=a},function(e,t,n){"use strict";const r=n(1273),i=n(169);e.exports=(e=>0===e.indexOf("https")?i.request:r.request)},function(e,t,n){(function(e){var n;function r(){if(void 0!==n)return n;if(e.XMLHttpRequest){n=new e.XMLHttpRequest;try{n.open("GET",e.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function i(e){var t=r();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}function o(e){return"function"==typeof e}t.fetch=o(e.fetch)&&o(e.ReadableStream),t.writableStream=o(e.WritableStream),t.abortController=o(e.AbortController),t.arraybuffer=t.fetch||i("arraybuffer"),t.msstream=!t.fetch&&i("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&i("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!r()&&o(r().overrideMimeType),n=null}).call(this,n(8))},function(e,t,n){(function(e,r,i){var o=n(512),s=n(1),a=n(17),l=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},u=t.IncomingMessage=function(t,n,s,l){var u=this;if(a.Readable.call(u),u._mode=s,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",function(){e.nextTick(function(){u.emit("close")})}),"fetch"===s){if(u._fetchResponse=n,u.url=n.url,u.statusCode=n.status,u.statusMessage=n.statusText,n.headers.forEach(function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)}),o.writableStream){var c=new WritableStream({write:function(e){return new Promise(function(t,n){u._destroyed?n():u.push(r.from(e))?t():u._resumeFetch=t})},close:function(){i.clearTimeout(l),u._destroyed||u.push(null)},abort:function(e){u._destroyed||u.emit("error",e)}});try{return void n.body.pipeTo(c).catch(function(e){i.clearTimeout(l),u._destroyed||u.emit("error",e)})}catch(e){}}var h=n.body.getReader();function f(){h.read().then(function(e){if(!u._destroyed){if(e.done)return i.clearTimeout(l),void u.push(null);u.push(r.from(e.value)),f()}}).catch(function(e){i.clearTimeout(l),u._destroyed||u.emit("error",e)})}f()}else{u._xhr=t,u._pos=0,u.url=t.responseURL,u.statusCode=t.status,u.statusMessage=t.statusText;var p=t.getAllResponseHeaders().split(/\r?\n/);if(p.forEach(function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var n=t[1].toLowerCase();"set-cookie"===n?(void 0===u.headers[n]&&(u.headers[n]=[]),u.headers[n].push(t[2])):void 0!==u.headers[n]?u.headers[n]+=", "+t[2]:u.headers[n]=t[2],u.rawHeaders.push(t[1],t[2])}}),u._charset="x-user-defined",!o.overrideMimeType){var d=u.rawHeaders["mime-type"];if(d){var m=d.match(/;\s*charset=([^;])(;|$)/);m&&(u._charset=m[1].toLowerCase())}u._charset||(u._charset="utf-8")}}};s(u,a.Readable),u.prototype._read=function(){var e=this,t=this._resumeFetch;t&&(this._resumeFetch=null,t())},u.prototype._onXHRProgress=function(){var e=this,t=e._xhr,n=null;switch(e._mode){case"text":if(n=t.responseText,n.length>e._pos){var o=n.substr(e._pos);if("x-user-defined"===e._charset){for(var s=r.alloc(o.length),a=0;a<o.length;a++)s[a]=255&o.charCodeAt(a);e.push(s)}else e.push(o,e._charset);e._pos=n.length}break;case"arraybuffer":if(t.readyState!==l.DONE||!t.response)break;n=t.response,e.push(r.from(new Uint8Array(n)));break;case"moz-chunked-arraybuffer":if(n=t.response,t.readyState!==l.LOADING||!n)break;e.push(r.from(new Uint8Array(n)));break;case"ms-stream":if(n=t.response,t.readyState!==l.LOADING)break;var u=new i.MSStreamReader;u.onprogress=function(){u.result.byteLength>e._pos&&(e.push(r.from(new Uint8Array(u.result.slice(e._pos)))),e._pos=u.result.byteLength)},u.onload=function(){e.push(null)},u.readAsArrayBuffer(n)}e._xhr.readyState===l.DONE&&"ms-stream"!==e._mode&&e.push(null)}}).call(this,n(3),n(0).Buffer,n(8))},function(e,t){e.exports={100:"Continue",101:"Switching Protocols",102:"Processing",200:"OK",201:"Created",202:"Accepted",203:"Non-Authoritative Information",204:"No Content",205:"Reset Content",206:"Partial Content",207:"Multi-Status",208:"Already Reported",226:"IM Used",300:"Multiple Choices",301:"Moved Permanently",302:"Found",303:"See Other",304:"Not Modified",305:"Use Proxy",307:"Temporary Redirect",308:"Permanent Redirect",400:"Bad Request",401:"Unauthorized",402:"Payment Required",403:"Forbidden",404:"Not Found",405:"Method Not Allowed",406:"Not Acceptable",407:"Proxy Authentication Required",408:"Request Timeout",409:"Conflict",410:"Gone",411:"Length Required",412:"Precondition Failed",413:"Payload Too Large",414:"URI Too Long",415:"Unsupported Media Type",416:"Range Not Satisfiable",417:"Expectation Failed",418:"I'm a teapot",421:"Misdirected Request",422:"Unprocessable Entity",423:"Locked",424:"Failed Dependency",425:"Unordered Collection",426:"Upgrade Required",428:"Precondition Required",429:"Too Many Requests",431:"Request Header Fields Too Large",451:"Unavailable For Legal Reasons",500:"Internal Server Error",501:"Not Implemented",502:"Bad Gateway",503:"Service Unavailable",504:"Gateway Timeout",505:"HTTP Version Not Supported",506:"Variant Also Negotiates",507:"Insufficient Storage",508:"Loop Detected",509:"Bandwidth Limit Exceeded",510:"Not Extended",511:"Network Authentication Required"}},function(e,t,n){(function(e){t.fetch=a(e.fetch)&&a(e.ReadableStream),t.writableStream=a(e.WritableStream),t.abortController=a(e.AbortController),t.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),t.blobConstructor=!0}catch(e){}var n;function r(){if(void 0!==n)return n;if(e.XMLHttpRequest){n=new e.XMLHttpRequest;try{n.open("GET",e.XDomainRequest?"/":"https://example.com")}catch(e){n=null}}else n=null;return n}function i(e){var t=r();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}var o=void 0!==e.ArrayBuffer,s=o&&a(e.ArrayBuffer.prototype.slice);function a(e){return"function"==typeof e}t.arraybuffer=t.fetch||o&&i("arraybuffer"),t.msstream=!t.fetch&&s&&i("ms-stream"),t.mozchunkedarraybuffer=!t.fetch&&o&&i("moz-chunked-arraybuffer"),t.overrideMimeType=t.fetch||!!r()&&a(r().overrideMimeType),t.vbArray=a(e.VBArray),n=null}).call(this,n(8))},function(e,t,n){(function(e,r,i){var o=n(515),s=n(1),a=n(517),l=t.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},u=t.IncomingMessage=function(t,n,s,l){var u=this;if(a.Readable.call(u),u._mode=s,u.headers={},u.rawHeaders=[],u.trailers={},u.rawTrailers=[],u.on("end",function(){e.nextTick(function(){u.emit("close")})}),"fetch"===s){if(u._fetchResponse=n,u.url=n.url,u.statusCode=n.status,u.statusMessage=n.statusText,n.headers.forEach(function(e,t){u.headers[t.toLowerCase()]=e,u.rawHeaders.push(t,e)}),o.writableStream){var c=new WritableStream({write:function(e){return new Promise(function(t,n){u._destroyed?n():u.push(new r(e))?t():u._resumeFetch=t})},close:function(){i.clearTimeout(l),u._destroyed||u.push(null)},abort:function(e){u._destroyed||u.emit("error",e)}});try{return void n.body.pipeTo(c).catch(function(e){i.clearTimeout(l),u._destroyed||u.emit("error",e)})}catch(e){}}var h=n.body.getReader();function f(){h.read().then(function(e){if(!u._destroyed){if(e.done)return i.clearTimeout(l),void u.push(null);u.push(new r(e.value)),f()}}).catch(function(e){i.clearTimeout(l),u._destroyed||u.emit("error",e)})}f()}else{u._xhr=t,u._pos=0,u.url=t.responseURL,u.statusCode=t.status,u.statusMessage=t.statusText;var p=t.getAllResponseHeaders().split(/\r?\n/);if(p.forEach(function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var n=t[1].toLowerCase();"set-cookie"===n?(void 0===u.headers[n]&&(u.headers[n]=[]),u.headers[n].push(t[2])):void 0!==u.headers[n]?u.headers[n]+=", "+t[2]:u.headers[n]=t[2],u.rawHeaders.push(t[1],t[2])}}),u._charset="x-user-defined",!o.overrideMimeType){var d=u.rawHeaders["mime-type"];if(d){var m=d.match(/;\s*charset=([^;])(;|$)/);m&&(u._charset=m[1].toLowerCase())}u._charset||(u._charset="utf-8")}}};s(u,a.Readable),u.prototype._read=function(){var e=this,t=this._resumeFetch;t&&(this._resumeFetch=null,t())},u.prototype._onXHRProgress=function(){var e=this,t=e._xhr,n=null;switch(e._mode){case"text:vbarray":if(t.readyState!==l.DONE)break;try{n=new i.VBArray(t.responseBody).toArray()}catch(e){}if(null!==n){e.push(new r(n));break}case"text":try{n=t.responseText}catch(t){e._mode="text:vbarray";break}if(n.length>e._pos){var o=n.substr(e._pos);if("x-user-defined"===e._charset){for(var s=new r(o.length),a=0;a<o.length;a++)s[a]=255&o.charCodeAt(a);e.push(s)}else e.push(o,e._charset);e._pos=n.length}break;case"arraybuffer":if(t.readyState!==l.DONE||!t.response)break;n=t.response,e.push(new r(new Uint8Array(n)));break;case"moz-chunked-arraybuffer":if(n=t.response,t.readyState!==l.LOADING||!n)break;e.push(new r(new Uint8Array(n)));break;case"ms-stream":if(n=t.response,t.readyState!==l.LOADING)break;var u=new i.MSStreamReader;u.onprogress=function(){u.result.byteLength>e._pos&&(e.push(new r(new Uint8Array(u.result.slice(e._pos)))),e._pos=u.result.byteLength)},u.onload=function(){e.push(null)},u.readAsArrayBuffer(n)}e._xhr.readyState===l.DONE&&"ms-stream"!==e._mode&&e.push(null)}}).call(this,n(3),n(0).Buffer,n(8))},function(e,t,n){t=e.exports=n(518),t.Stream=t,t.Readable=t,t.Writable=n(521),t.Duplex=n(132),t.Transform=n(522),t.PassThrough=n(1279)},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(519),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1276),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1277),v=n(520),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(132),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(132),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(519),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(520),y;function v(){}function b(e,t){l=l||n(132),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(132),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(132),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){var r=n(0).Buffer;e.exports=function(e){if(e instanceof Uint8Array){if(0===e.byteOffset&&e.byteLength===e.buffer.byteLength)return e.buffer;if("function"==typeof e.buffer.slice)return e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength)}if(r.isBuffer(e)){for(var t=new Uint8Array(e.length),n=e.length,i=0;i<n;i++)t[i]=e[i];return t.buffer}throw new Error("Argument must be a Buffer")}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(525),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1283),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1284),v=n(526),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(133),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(133),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(525),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(526),y;function v(){}function b(e,t){l=l||n(133),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(133),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(133),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(530),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1294),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1295),v=n(531),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(104),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(104),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(530),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(531),y;function v(){}function b(e,t){l=l||n(104),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(104),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){(function(e){var r=n(534),i=n(105),o="0000000000000000000",s="7777777777777777777",a="0".charCodeAt(0),l="ustar\x0000",u=parseInt("7777",8),c=function(e,t,n){return"number"!=typeof e?n:(e=~~e,e>=t?t:e>=0?e:(e+=t,e>=0?e:0))},h=function(e){switch(e){case 0:return"file";case 1:return"link";case 2:return"symlink";case 3:return"character-device";case 4:return"block-device";case 5:return"directory";case 6:return"fifo";case 7:return"contiguous-file";case 72:return"pax-header";case 55:return"pax-global-header";case 27:return"gnu-long-link-path";case 28:case 30:return"gnu-long-path"}return null},f=function(e){switch(e){case"file":return 0;case"link":return 1;case"symlink":return 2;case"character-device":return 3;case"block-device":return 4;case"directory":return 5;case"fifo":return 6;case"contiguous-file":return 7;case"pax-header":return 72}return 0},p=function(e,t,n,r){for(;n<r;n++)if(e[n]===t)return n;return r},d=function(e){for(var t=256,n=0;n<148;n++)t+=e[n];for(var r=156;r<512;r++)t+=e[r];return t},m=function(e,t){return e=e.toString(8),e.length>t?s.slice(0,t)+" ":o.slice(0,t-e.length)+e+" "};function g(e){var t;if(128===e[0])t=!0;else{if(255!==e[0])return null;t=!1}for(var n=!1,r=[],i=e.length-1;i>0;i--){var o=e[i];t?r.push(o):n&&0===o?r.push(0):n?(n=!1,r.push(256-o)):r.push(255-o)}var s=0,a=r.length;for(i=0;i<a;i++)s+=r[i]*Math.pow(256,i);return t?s:-1*s}var y=function(e,t,n){if(e=e.slice(t,t+n),t=0,128&e[t])return g(e);for(;t<e.length&&32===e[t];)t++;for(var r=c(p(e,32,t,e.length),e.length,e.length);t<r&&0===e[t];)t++;return r===t?0:parseInt(e.slice(t,r).toString(),8)},v=function(e,t,n,r){return e.slice(t,p(e,0,t,t+n)).toString(r)},b=function(t){var n=e.byteLength(t),r=Math.floor(Math.log(n)/Math.log(10))+1;return n+r>=Math.pow(10,r)&&r++,n+r+t};t.decodeLongPath=function(e,t){return v(e,0,e.length,t)},t.encodePax=function(e){var t="";e.name&&(t+=b(" path="+e.name+"\n")),e.linkname&&(t+=b(" linkpath="+e.linkname+"\n"));var n=e.pax;if(n)for(var i in n)t+=b(" "+i+"="+n[i]+"\n");return r(t)},t.decodePax=function(e){for(var t={};e.length;){for(var n=0;n<e.length&&32!==e[n];)n++;var r=parseInt(e.slice(0,n).toString(),10);if(!r)return t;var i=e.slice(n+1,r-1).toString(),o=i.indexOf("=");if(-1===o)return t;t[i.slice(0,o)]=i.slice(o+1),e=e.slice(r)}return t},t.encode=function(t){var n=i(512),r=t.name,o="";if(5===t.typeflag&&"/"!==r[r.length-1]&&(r+="/"),e.byteLength(r)!==r.length)return null;for(;e.byteLength(r)>100;){var s=r.indexOf("/");if(-1===s)return null;o+=o?"/"+r.slice(0,s):r.slice(0,s),r=r.slice(s+1)}return e.byteLength(r)>100||e.byteLength(o)>155?null:t.linkname&&e.byteLength(t.linkname)>100?null:(n.write(r),n.write(m(t.mode&u,6),100),n.write(m(t.uid,6),108),n.write(m(t.gid,6),116),n.write(m(t.size,11),124),n.write(m(t.mtime.getTime()/1e3|0,11),136),n[156]=a+f(t.type),t.linkname&&n.write(t.linkname,157),n.write(l,257),t.uname&&n.write(t.uname,265),t.gname&&n.write(t.gname,297),n.write(m(t.devmajor||0,6),329),n.write(m(t.devminor||0,6),337),o&&n.write(o,345),n.write(m(d(n),6),148),n)},t.decode=function(e,t){var n=0===e[156]?0:e[156]-a,r=v(e,0,100,t),i=y(e,100,8),o=y(e,108,8),s=y(e,116,8),l=y(e,124,12),u=y(e,136,12),c=h(n),f=0===e[157]?null:v(e,157,100,t),p=v(e,265,32),m=v(e,297,32),g=y(e,329,8),b=y(e,337,8);e[345]&&(r=v(e,345,155,t)+"/"+r),0===n&&r&&"/"===r[r.length-1]&&(n=5);var _=d(e);if(256===_)return null;if(_!==y(e,148,8))throw new Error("Invalid tar header. Maybe the tar is corrupted or it needs to be gunzipped?");return{name:r,mode:i,uid:o,gid:s,size:l,mtime:new Date(1e3*u),type:c,linkname:f,uname:p,gname:m,devmajor:g,devminor:b}}}).call(this,n(0).Buffer)},function(e,t,n){(function(t){e.exports=i;var n=t.from&&t.from!==Uint8Array.from?t.from:r;function r(e,n){return new t(e,n)}function i(e,r){if(t.isBuffer(e))return e;if("string"==typeof e)return n(e,r);if(Array.isArray(e))return n(e);throw new Error("Input should be a buffer or a string")}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=s;var r=n(104),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){"use strict";const r=n(1307);t=e.exports=(()=>({"api-path":"/api/v0/","user-agent":`/node-${r.name}/${r.version}/`,host:"localhost",port:"5001",protocol:"http"}))},function(e,t,n){"use strict";(function(r){const i=n(1308),o=n(301).encode,s=n(168),a=n(302),l=n(53),u=n(26),c=n(91),h=n(1313),f=n(511),p=n(4)("ipfs-http-client:request");function d(e,t){const n=new Error(`Server responded with ${e.statusCode}`);h(e,(e,r)=>{if(e)return t(e);r&&(n.code=r.Code,n.message=r.Message||r.toString(),n.type=r.Type),t(n)})}function m(e,t){return n=>{const r=Boolean(n.headers["x-stream-output"]),i=Boolean(n.headers["x-chunked-output"]),o=n.headers["content-type"]&&0===n.headers["content-type"].indexOf("application/json");if(n.req?p(n.req.method,`${n.req.getHeaders().host}${n.req.path}`,n.statusCode,n.statusMessage):p(n.url,n.statusCode,n.statusMessage),n.statusCode>=400||!n.statusCode)return d(n,t);if(r&&!e)return t(null,n);if(i&&o){const e=a.parse();return l(n,e),n.on("end",()=>{let t=n.trailers["x-stream-error"];if(t){try{t=JSON.parse(t)}catch(e){t={Message:t}}e.emit("error",new Error(t.Message))}}),t(null,e)}return o?h(n,t):c(n,t)}}function g(e,t,n){n=u(n),t.qs=t.qs||{},Array.isArray(t.path)&&(t.path=t.path.join("/")),t.args&&!Array.isArray(t.args)&&(t.args=[t.args]),t.args&&(t.qs.arg=t.args),t.progress&&(t.qs.progress=!0),t.qs.r&&(t.qs.recursive=t.qs.r,delete t.qs.r),t.qs["stream-channels"]=!0,t.stream&&(t.buffer=!1),delete t.qs.followSymlinks;const a="POST",l=Object.assign({},e.headers);if(s&&(l["User-Agent"]=e["user-agent"]),t.multipart){if(!t.multipartBoundary)return n(new Error("No multipartBoundary"));l["Content-Type"]=`multipart/form-data; boundary=${t.multipartBoundary}`}const c=i.stringify(t.qs,{arrayFormat:"repeat",encoder:e=>{if(r.isBuffer(e)){let t="";for(const n of e)if(n>=65&&n<=90||n>=97&&n<=122||n>=48&&n<=57||45===n||46===n||95===n||126===n)t+=String.fromCharCode(n);else{const e=n.toString(16),r=1===e.length?`0${e}`:e;t+=`%${r}`}return t}return o(e)}}),h={hostname:e.host,path:`${e["api-path"]}${t.path}?${c}`,port:e.port,method:"POST",headers:l,protocol:`${e.protocol}:`},p=f(e.protocol)(h,m(t.buffer,n));return p.on("error",e=>{n(e)}),t.stream||p.end(),p}t=e.exports=(e=>{const t=(t,n)=>"object"!=typeof t?n(new Error("no options were passed")):g(e,t,n);return t.andTransform=((e,n,r)=>t(e,(e,t)=>{if(e)return r(e);n(t,r)})),t})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=String.prototype.replace,i=/%20/g;e.exports={default:"RFC3986",formatters:{RFC1738:function(e){return r.call(e,i,"+")},RFC3986:function(e){return e}},RFC1738:"RFC1738",RFC3986:"RFC3986"}},function(e,t){function n(e,t,n,i){return JSON.stringify(e,r(t,i),n)}function r(e,t){var n=[],r=[];return null==t&&(t=function(e,t){return n[0]===t?"[Circular ~]":"[Circular ~."+r.slice(0,n.indexOf(t)).join(".")+"]"}),function(i,o){if(n.length>0){var s=n.indexOf(this);~s?n.splice(s+1):n.push(this),~s?r.splice(s,1/0,i):r.push(i),~n.indexOf(o)&&(o=t.call(this,i,o))}else n.push(o);return null==e?o:e.call(this,i,o)}}t=e.exports=n,t.getSerialize=r},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{get:n(1316)(t),stat:n(1317)(t),put:n(1318)(t)}})},function(e,t,n){"use strict";e.exports=(e=>{const t=e.pop();let n={},r=[];return Array.isArray(e[e.length-1])||"object"!=typeof e[e.length-1]||(n=e.pop()),r=1===e.length&&Array.isArray(e[0])?e[0]:e,{callback:t,sources:r,opts:n}})},function(e,t,n){var r=n(219),i=n(1429),o=n(1430),s=n(1431),a=n(1432),l=n(1433);function u(e){var t=this.__data__=new r(e);this.size=t.size}u.prototype.clear=i,u.prototype.delete=o,u.prototype.get=s,u.prototype.has=a,u.prototype.set=l,e.exports=u},function(e,t,n){var r=n(1434),i=n(87);function o(e,t,n,s,a){return e===t||(null==e||null==t||!i(e)&&!i(t)?e!=e&&t!=t:r(e,t,n,s,o,a))}e.exports=o},function(e,t,n){var r=n(1435),i=n(1438),o=n(1439),s=1,a=2;function l(e,t,n,l,u,c){var h=n&s,f=e.length,p=t.length;if(f!=p&&!(h&&p>f))return!1;var d=c.get(e);if(d&&c.get(t))return d==t;var m=-1,g=!0,y=n&a?new r:void 0;for(c.set(e,t),c.set(t,e);++m<f;){var v=e[m],b=t[m];if(l)var _=h?l(b,v,m,t,e,c):l(v,b,m,e,t,c);if(void 0!==_){if(_)continue;g=!1;break}if(y){if(!i(t,function(e,t){if(!o(y,t)&&(v===e||u(v,e,n,l,c)))return y.push(t)})){g=!1;break}}else if(v!==b&&!u(v,b,n,l,c)){g=!1;break}}return c.delete(e),c.delete(t),g}e.exports=l},function(e,t,n){var r=n(181);function i(e){return e==e&&!r(e)}e.exports=i},function(e,t){function n(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}e.exports=n},function(e,t,n){"use strict";const{Transform:r,PassThrough:i}=n(17),o=n(53),s=n(302),a=n(128),l=e=>({name:e.Name,type:e.Type,size:e.Size,hash:e.Hash});e.exports=(e=>(t,n)=>{n=n||{};const u=new r({objectMode:!0,transform(e,t,n){n(null,l(e))}}),c=new i({objectMode:!0});return e({path:"files/ls",args:t,qs:Object.assign({},n,{stream:!0})},(e,t)=>{if(e)return c.destroy(e);if(a(t)){const e=s.parse();o(t,e,u,c)}else{const e=t.Entries||[];e.forEach(e=>{c.write(l(e))}),c.end()}}),c})},function(e,t,n){(function(e,n){var r=200,i="__lodash_hash_undefined__",o=9007199254740991,s="[object Arguments]",a="[object Array]",l="[object Boolean]",u="[object Date]",c="[object Error]",h="[object Function]",f="[object GeneratorFunction]",p="[object Map]",d="[object Number]",m="[object Object]",g="[object Promise]",y="[object RegExp]",v="[object Set]",b="[object String]",_="[object Symbol]",w="[object WeakMap]",k="[object ArrayBuffer]",E="[object DataView]",S="[object Float32Array]",x="[object Float64Array]",C="[object Int8Array]",A="[object Int16Array]",T="[object Int32Array]",I="[object Uint8Array]",j="[object Uint8ClampedArray]",R="[object Uint16Array]",B="[object Uint32Array]",O=/[\\^$.*+?()[\]{}|]/g,P=/\w*$/,N=/^\[object .+?Constructor\]$/,D=/^(?:0|[1-9]\d*)$/,M={};M[s]=M[a]=M[k]=M[E]=M[l]=M[u]=M[S]=M[x]=M[C]=M[A]=M[T]=M[p]=M[d]=M[m]=M[y]=M[v]=M[b]=M[_]=M[I]=M[j]=M[R]=M[B]=!0,M[c]=M[h]=M[w]=!1;var F="object"==typeof e&&e&&e.Object===Object&&e,L="object"==typeof self&&self&&self.Object===Object&&self,U=F||L||Function("return this")(),q=t&&!t.nodeType&&t,z=q&&"object"==typeof n&&n&&!n.nodeType&&n,K=z&&z.exports===q;function H(e,t){return e.set(t[0],t[1]),e}function V(e,t){return e.add(t),e}function $(e,t){for(var n=-1,r=e?e.length:0;++n<r&&!1!==t(e[n],n,e););return e}function W(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function G(e,t,n,r){var i=-1,o=e?e.length:0;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}function Y(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Z(e,t){return null==e?void 0:e[t]}function J(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function Q(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function X(e,t){return function(n){return e(t(n))}}function ee(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var te=Array.prototype,ne=Function.prototype,re=Object.prototype,ie=U["__core-js_shared__"],oe=(se=/[^.]+$/.exec(ie&&ie.keys&&ie.keys.IE_PROTO||""),se?"Symbol(src)_1."+se:""),se,ae=ne.toString,le=re.hasOwnProperty,ue=re.toString,ce=RegExp("^"+ae.call(le).replace(O,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),he=K?U.Buffer:void 0,fe=U.Symbol,pe=U.Uint8Array,de=X(Object.getPrototypeOf,Object),me=Object.create,ge=re.propertyIsEnumerable,ye=te.splice,ve=Object.getOwnPropertySymbols,be=he?he.isBuffer:void 0,_e=X(Object.keys,Object),we=At(U,"DataView"),ke=At(U,"Map"),Ee=At(U,"Promise"),Se=At(U,"Set"),xe=At(U,"WeakMap"),Ce=At(Object,"create"),Ae=Mt(we),Te=Mt(ke),Ie=Mt(Ee),je=Mt(Se),Re=Mt(xe),Be=fe?fe.prototype:void 0,Oe=Be?Be.valueOf:void 0;function Pe(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ne(){this.__data__=Ce?Ce(null):{}}function De(e){return this.has(e)&&delete this.__data__[e]}function Me(e){var t=this.__data__;if(Ce){var n=t[e];return n===i?void 0:n}return le.call(t,e)?t[e]:void 0}function Fe(e){var t=this.__data__;return Ce?void 0!==t[e]:le.call(t,e)}function Le(e,t){var n=this.__data__;return n[e]=Ce&&void 0===t?i:t,this}function Ue(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function qe(){this.__data__=[]}function ze(e){var t=this.__data__,n=st(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():ye.call(t,n,1),!0}function Ke(e){var t=this.__data__,n=st(t,e);return n<0?void 0:t[n][1]}function He(e){return st(this.__data__,e)>-1}function Ve(e,t){var n=this.__data__,r=st(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}function $e(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function We(){this.__data__={hash:new Pe,map:new(ke||Ue),string:new Pe}}function Ge(e){return Ct(this,e).delete(e)}function Ye(e){return Ct(this,e).get(e)}function Ze(e){return Ct(this,e).has(e)}function Je(e,t){return Ct(this,e).set(e,t),this}function Qe(e){this.__data__=new Ue(e)}function Xe(){this.__data__=new Ue}function et(e){return this.__data__.delete(e)}function tt(e){return this.__data__.get(e)}function nt(e){return this.__data__.has(e)}function rt(e,t){var n=this.__data__;if(n instanceof Ue){var i=n.__data__;if(!ke||i.length<r-1)return i.push([e,t]),this;n=this.__data__=new $e(i)}return n.set(e,t),this}function it(e,t){var n=qt(e)||Ut(e)?Y(e.length,String):[],r=n.length,i=!!r;for(var o in e)!t&&!le.call(e,o)||i&&("length"==o||Ot(o,r))||n.push(o);return n}function ot(e,t,n){var r=e[t];le.call(e,t)&&Lt(r,n)&&(void 0!==n||t in e)||(e[t]=n)}function st(e,t){for(var n=e.length;n--;)if(Lt(e[n][0],t))return n;return-1}function at(e,t){return e&&Et(t,Yt(t),e)}function lt(e,t,n,r,i,o,a){var l;if(r&&(l=o?r(e,i,o,a):r(e)),void 0!==l)return l;if(!Wt(e))return e;var u=qt(e);if(u){if(l=jt(e),!t)return kt(e,l)}else{var c=It(e),p=c==h||c==f;if(Ht(e))return dt(e,t);if(c==m||c==s||p&&!o){if(J(e))return o?e:{};if(l=Rt(p?{}:e),!t)return St(e,at(l,e))}else{if(!M[c])return o?e:{};l=Bt(e,c,lt,t)}}a||(a=new Qe);var d=a.get(e);if(d)return d;if(a.set(e,l),!u)var g=n?xt(e):Yt(e);return $(g||e,function(i,o){g&&(o=i,i=e[o]),ot(l,o,lt(i,t,n,r,o,e,a))}),l}function ut(e){return Wt(e)?me(e):{}}function ct(e,t,n){var r=t(e);return qt(e)?r:W(r,n(e))}function ht(e){return ue.call(e)}function ft(e){if(!Wt(e)||Nt(e))return!1;var t=Vt(e)||J(e)?ce:N;return t.test(Mt(e))}function pt(e){if(!Dt(e))return _e(e);var t=[];for(var n in Object(e))le.call(e,n)&&"constructor"!=n&&t.push(n);return t}function dt(e,t){if(t)return e.slice();var n=new e.constructor(e.length);return e.copy(n),n}function mt(e){var t=new e.constructor(e.byteLength);return new pe(t).set(new pe(e)),t}function gt(e,t){var n=t?mt(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}function yt(e,t,n){var r=t?n(Q(e),!0):Q(e);return G(r,H,new e.constructor)}function vt(e){var t=new e.constructor(e.source,P.exec(e));return t.lastIndex=e.lastIndex,t}function bt(e,t,n){var r=t?n(ee(e),!0):ee(e);return G(r,V,new e.constructor)}function _t(e){return Oe?Object(Oe.call(e)):{}}function wt(e,t){var n=t?mt(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function kt(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}function Et(e,t,n,r){n||(n={});for(var i=-1,o=t.length;++i<o;){var s=t[i],a=r?r(n[s],e[s],s,n,e):void 0;ot(n,s,void 0===a?e[s]:a)}return n}function St(e,t){return Et(e,Tt(e),t)}function xt(e){return ct(e,Yt,Tt)}function Ct(e,t){var n=e.__data__;return Pt(t)?n["string"==typeof t?"string":"hash"]:n.map}function At(e,t){var n=Z(e,t);return ft(n)?n:void 0}Pe.prototype.clear=Ne,Pe.prototype.delete=De,Pe.prototype.get=Me,Pe.prototype.has=Fe,Pe.prototype.set=Le,Ue.prototype.clear=qe,Ue.prototype.delete=ze,Ue.prototype.get=Ke,Ue.prototype.has=He,Ue.prototype.set=Ve,$e.prototype.clear=We,$e.prototype.delete=Ge,$e.prototype.get=Ye,$e.prototype.has=Ze,$e.prototype.set=Je,Qe.prototype.clear=Xe,Qe.prototype.delete=et,Qe.prototype.get=tt,Qe.prototype.has=nt,Qe.prototype.set=rt;var Tt=ve?X(ve,Object):Zt,It=ht;function jt(e){var t=e.length,n=e.constructor(t);return t&&"string"==typeof e[0]&&le.call(e,"index")&&(n.index=e.index,n.input=e.input),n}function Rt(e){return"function"!=typeof e.constructor||Dt(e)?{}:ut(de(e))}function Bt(e,t,n,r){var i=e.constructor;switch(t){case k:return mt(e);case l:case u:return new i(+e);case E:return gt(e,r);case S:case x:case C:case A:case T:case I:case j:case R:case B:return wt(e,r);case p:return yt(e,r,n);case d:case b:return new i(e);case y:return vt(e);case v:return bt(e,r,n);case _:return _t(e)}}function Ot(e,t){return t=null==t?o:t,!!t&&("number"==typeof e||D.test(e))&&e>-1&&e%1==0&&e<t}function Pt(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function Nt(e){return!!oe&&oe in e}function Dt(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||re;return e===n}function Mt(e){if(null!=e){try{return ae.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Ft(e){return lt(e,!0,!0)}function Lt(e,t){return e===t||e!=e&&t!=t}function Ut(e){return Kt(e)&&le.call(e,"callee")&&(!ge.call(e,"callee")||ue.call(e)==s)}(we&&It(new we(new ArrayBuffer(1)))!=E||ke&&It(new ke)!=p||Ee&&It(Ee.resolve())!=g||Se&&It(new Se)!=v||xe&&It(new xe)!=w)&&(It=function(e){var t=ue.call(e),n=t==m?e.constructor:void 0,r=n?Mt(n):void 0;if(r)switch(r){case Ae:return E;case Te:return p;case Ie:return g;case je:return v;case Re:return w}return t});var qt=Array.isArray;function zt(e){return null!=e&&$t(e.length)&&!Vt(e)}function Kt(e){return Gt(e)&&zt(e)}var Ht=be||Jt;function Vt(e){var t=Wt(e)?ue.call(e):"";return t==h||t==f}function $t(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=o}function Wt(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Gt(e){return!!e&&"object"==typeof e}function Yt(e){return zt(e)?it(e):pt(e)}function Zt(){return[]}function Jt(){return!1}n.exports=Ft}).call(this,n(8),n(85)(e))},function(e,t,n){"use strict";e.exports="ipfs-pubsub-room/v2"},function(e,t,n){"use strict";(function(t){e.exports=(e=>{let n=e;return t.isBuffer(n)||(n=t.from(n)),n})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=(e=>e._libp2pNode||e.libp2p)},function(e,t,n){(function(t){e.exports=function(e,n){var r=[];e.on("data",function(e){r.push(e)}),e.once("end",function(){n&&n(null,t.concat(r)),n=null}),e.once("error",function(e){n&&n(e),n=null})}}).call(this,n(0).Buffer)},function(e,t,n){(function(t){var r=n(1),i=n(1522).Transform,o=n(1527);function s(e,t){if(!(this instanceof s))return new s(e,t);i.call(this),t||(t={}),"object"==typeof e&&(t=e,e=t.size),this.size=e||512,t.nopad?this._zeroPadding=!1:this._zeroPadding=o(t.zeroPadding,!0),this._buffered=[],this._bufferedBytes=0}e.exports=s,r(s,i),s.prototype._transform=function(e,n,r){for(this._bufferedBytes+=e.length,this._buffered.push(e);this._bufferedBytes>=this.size;){var i=t.concat(this._buffered);this._bufferedBytes-=this.size,this.push(i.slice(0,this.size)),this._buffered=[i.slice(this.size,i.length)]}r()},s.prototype._flush=function(){if(this._bufferedBytes&&this._zeroPadding){var e=new t(this.size-this._bufferedBytes);e.fill(0),this._buffered.push(e),this.push(t.concat(this._buffered)),this._buffered=null}else this._bufferedBytes&&(this.push(t.concat(this._buffered)),this._buffered=null);this.push(null)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(555),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1523),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1524),v=n(556),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(135),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(135),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(555),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(556),y;function v(){}function b(e,t){l=l||n(135),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(135),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(135),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(560),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1532),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1533),v=n(561),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(136),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(136),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(560),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(561),y;function v(){}function b(e,t){l=l||n(136),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(136),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(136),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){e.exports=o;var r=n(1),i=n(1539);function o(e,t){var n=this;if(!(n instanceof o))return new o(e,t);i.Readable.call(n,t),n.destroyed=!1,n._drained=!1,n._forwarding=!1,n._current=null,n._toStreams2=t&&t.objectMode?s:a,"function"==typeof e?n._queue=e:(n._queue=e.map(n._toStreams2),n._queue.forEach(function(e){"function"!=typeof e&&n._attachErrorListener(e)})),n._next()}function s(e){return l(e,{objectMode:!0,highWaterMark:16})}function a(e){return l(e)}function l(e,t){if(!e||"function"==typeof e||e._readableState)return e;var n=new i.Readable(t).wrap(e);return e.destroy&&(n.destroy=e.destroy.bind(e)),n}r(o,i.Readable),o.obj=function(e){return new o(e,{objectMode:!0,highWaterMark:16})},o.prototype._read=function(){this._drained=!0,this._forward()},o.prototype._forward=function(){if(!this._forwarding&&this._drained&&this._current){var e;for(this._forwarding=!0;null!==(e=this._current.read());)this._drained=this.push(e);this._forwarding=!1}},o.prototype.destroy=function(e){this.destroyed||(this.destroyed=!0,this._current&&this._current.destroy&&this._current.destroy(),"function"!=typeof this._queue&&this._queue.forEach(function(e){e.destroy&&e.destroy()}),e&&this.emit("error",e),this.emit("close"))},o.prototype._next=function(){var e=this;if(e._current=null,"function"==typeof e._queue)e._queue(function(t,n){if(t)return e.destroy(t);n=e._toStreams2(n),e._attachErrorListener(n),e._gotNextStream(n)});else{var t=e._queue.shift();"function"==typeof t&&(t=e._toStreams2(t()),e._attachErrorListener(t)),e._gotNextStream(t)}},o.prototype._gotNextStream=function(e){var t=this;if(!e)return t.push(null),void t.destroy();function n(){t._forward()}function r(){e._readableState.ended||t.destroy()}function i(){t._current=null,e.removeListener("readable",n),e.removeListener("end",i),e.removeListener("close",r),t._next()}t._current=e,t._forward(),e.on("readable",n),e.once("end",i),e.once("close",r)},o.prototype._attachErrorListener=function(e){var t=this;function n(r){e.removeListener("error",n),t.destroy(r)}e&&e.once("error",n)}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(566),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1540),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1541),v=n(567),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(137),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(137),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(566),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(567),y;function v(){}function b(e,t){l=l||n(137),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(137),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(137),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){(function(t,r){const i=n(231),o=n(1547),s=n(16),a=n(307),l=n(1549),u=n(54),c=n(171),h=n(232);function f(e){if("string"==typeof e&&/^(stream-)?magnet:/.test(e))return l(e);if("string"==typeof e&&(/^[a-f0-9]{40}$/i.test(e)||/^[a-z2-7]{32}$/i.test(e)))return l(`magnet:?xt=urn:btih:${e}`);if(t.isBuffer(e)&&20===e.length)return l(`magnet:?xt=urn:btih:${e.toString("hex")}`);if(t.isBuffer(e))return d(e);if(e&&e.infoHash)return e.infoHash=e.infoHash.toLowerCase(),e.announce||(e.announce=[]),"string"==typeof e.announce&&(e.announce=[e.announce]),e.urlList||(e.urlList=[]),e;throw new Error("Invalid torrent identifier")}function p(e,t){let n;if("function"!=typeof t)throw new Error("second argument must be a Function");try{n=f(e)}catch(e){}function i(e){try{n=f(e)}catch(e){return t(e)}n&&n.infoHash?t(null,n):t(new Error("Invalid torrent identifier"))}n&&n.infoHash?r.nextTick(()=>{t(null,n)}):g(e)?o(e,(e,n)=>{if(e)return t(new Error(`Error converting Blob: ${e.message}`));i(n)}):"function"==typeof a&&/^https?:/.test(e)?a.concat({url:e,timeout:3e4,headers:{"user-agent":"WebTorrent (https://webtorrent.io)"}},(e,n,r)=>{if(e)return t(new Error(`Error downloading torrent: ${e.message}`));i(r)}):"function"==typeof s.readFile&&"string"==typeof e?s.readFile(e,(e,n)=>{if(e)return t(new Error("Invalid torrent identifier"));i(n)}):r.nextTick(()=>{t(new Error("Invalid torrent identifier"))})}function d(e){t.isBuffer(e)&&(e=i.decode(e)),b(e.info,"info"),b(e.info["name.utf-8"]||e.info.name,"info.name"),b(e.info["piece length"],"info['piece length']"),b(e.info.pieces,"info.pieces"),e.info.files?e.info.files.forEach(e=>{b("number"==typeof e.length,"info.files[0].length"),b(e["path.utf-8"]||e.path,"info.files[0].path")}):b("number"==typeof e.info.length,"info.length");const n={info:e.info,infoBuffer:i.encode(e.info),name:(e.info["name.utf-8"]||e.info.name).toString(),announce:[]};n.infoHash=c.sync(n.infoBuffer),n.infoHashBuffer=t.from(n.infoHash,"hex"),void 0!==e.info.private&&(n.private=!!e.info.private),e["creation date"]&&(n.created=new Date(1e3*e["creation date"])),e["created by"]&&(n.createdBy=e["created by"].toString()),t.isBuffer(e.comment)&&(n.comment=e.comment.toString()),Array.isArray(e["announce-list"])&&e["announce-list"].length>0?e["announce-list"].forEach(e=>{e.forEach(e=>{n.announce.push(e.toString())})}):e.announce&&n.announce.push(e.announce.toString()),t.isBuffer(e["url-list"])&&(e["url-list"]=e["url-list"].length>0?[e["url-list"]]:[]),n.urlList=(e["url-list"]||[]).map(e=>e.toString()),h(n.announce),h(n.urlList);const r=e.info.files||[e.info];n.files=r.map((e,t)=>{const i=[].concat(n.name,e["path.utf-8"]||e.path||[]).map(e=>e.toString());return{path:u.join.apply(null,[u.sep].concat(i)).slice(1),name:i[i.length-1],length:e.length,offset:r.slice(0,t).reduce(y,0)}}),n.length=r.reduce(y,0);const o=n.files[n.files.length-1];return n.pieceLength=e.info["piece length"],n.lastPieceLength=(o.offset+o.length)%n.pieceLength||n.pieceLength,n.pieces=v(e.info.pieces),n}function m(e){const n={info:e.info};return n["announce-list"]=(e.announce||[]).map(e=>(n.announce||(n.announce=e),e=t.from(e,"utf8"),[e])),n["url-list"]=e.urlList||[],void 0!==e.private&&(n.private=Number(e.private)),e.created&&(n["creation date"]=e.created.getTime()/1e3|0),e.createdBy&&(n["created by"]=e.createdBy),e.comment&&(n.comment=e.comment),i.encode(n)}function g(e){return"undefined"!=typeof Blob&&e instanceof Blob}function y(e,t){return e+t.length}function v(e){const t=[];for(let n=0;n<e.length;n+=20)t.push(e.slice(n,n+20).toString("hex"));return t}function b(e,t){if(!e)throw new Error(`Torrent is missing required field: ${t}`)}e.exports=f,e.exports.remote=p,e.exports.toMagnetURI=l.encode,e.exports.toTorrentFile=m,t.alloc(0)}).call(this,n(0).Buffer,n(3))},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(572),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1553),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1554),v=n(573),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(138),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(138),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(572),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(573),y;function v(){}function b(e,t){l=l||n(138),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(138),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(138),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(577),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1562),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1563),v=n(578),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(139),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(139),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(577),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(578),y;function v(){}function b(e,t){l=l||n(139),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(139),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(139),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){var r=n(5).Buffer;t.DEFAULT_ANNOUNCE_PEERS=50,t.MAX_ANNOUNCE_PEERS=82,t.binaryToHex=function(e){return"string"!=typeof e&&(e=String(e)),r.from(e,"binary").toString("hex")},t.hexToBinary=function(e){return"string"!=typeof e&&(e=String(e)),r.from(e,"hex").toString("binary")};var i=n(1571);Object.assign(t,i)},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(583),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1579),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1580),v=n(584),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(140),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(140),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(583),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(584),y;function v(){}function b(e,t){l=l||n(140),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(140),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(140),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){e.exports=l;var r=n(1),i=n(17),o=n(523),s="undefined"!=typeof window&&window.MediaSource,a=60;function l(e,t){var n=this;if(!(n instanceof l))return new l(e,t);if(!s)throw new Error("web browser lacks MediaSource support");t||(t={}),n._debug=t.debug,n._bufferDuration=t.bufferDuration||a,n._elem=e,n._mediaSource=new s,n._streams=[],n.detailedError=null,n._errorHandler=function(){n._elem.removeEventListener("error",n._errorHandler);var e=n._streams.slice();e.forEach(function(e){e.destroy(n._elem.error)})},n._elem.addEventListener("error",n._errorHandler),n._elem.src=window.URL.createObjectURL(n._mediaSource)}function u(e,t){var n=this;if(i.Writable.call(n),n._wrapper=e,n._elem=e._elem,n._mediaSource=e._mediaSource,n._allStreams=e._streams,n._allStreams.push(n),n._bufferDuration=e._bufferDuration,n._sourceBuffer=null,n._debugBuffers=[],n._openHandler=function(){n._onSourceOpen()},n._flowHandler=function(){n._flow()},n._errorHandler=function(e){n.destroyed||n.emit("error",e)},"string"==typeof t)n._type=t,"open"===n._mediaSource.readyState?n._createSourceBuffer():n._mediaSource.addEventListener("sourceopen",n._openHandler);else if(null===t._sourceBuffer)t.destroy(),n._type=t._type,n._mediaSource.addEventListener("sourceopen",n._openHandler);else{if(!t._sourceBuffer)throw new Error("The argument to MediaElementWrapper.createWriteStream must be a string or a previous stream returned from that function");t.destroy(),n._type=t._type,n._sourceBuffer=t._sourceBuffer,n._debugBuffers=t._debugBuffers,n._sourceBuffer.addEventListener("updateend",n._flowHandler),n._sourceBuffer.addEventListener("error",n._errorHandler)}n._elem.addEventListener("timeupdate",n._flowHandler),n.on("error",function(e){n._wrapper.error(e)}),n.on("finish",function(){if(!n.destroyed&&(n._finished=!0,n._allStreams.every(function(e){return e._finished}))){n._wrapper._dumpDebugData();try{n._mediaSource.endOfStream()}catch(e){}}})}l.prototype.createWriteStream=function(e){var t=this;return new u(this,e)},l.prototype.error=function(e){var t=this;this.detailedError||(this.detailedError=e),this._dumpDebugData();try{this._mediaSource.endOfStream("decode")}catch(e){}try{window.URL.revokeObjectURL(this._elem.src)}catch(e){}},l.prototype._dumpDebugData=function(){var e=this;this._debug&&(this._debug=!1,this._streams.forEach(function(e,t){h(e._debugBuffers,"mediasource-stream-"+t)}))},r(u,i.Writable),u.prototype._onSourceOpen=function(){var e=this;this.destroyed||(this._mediaSource.removeEventListener("sourceopen",this._openHandler),this._createSourceBuffer())},u.prototype.destroy=function(e){var t=this;this.destroyed||(this.destroyed=!0,this._allStreams.splice(this._allStreams.indexOf(this),1),this._mediaSource.removeEventListener("sourceopen",this._openHandler),this._elem.removeEventListener("timeupdate",this._flowHandler),this._sourceBuffer&&(this._sourceBuffer.removeEventListener("updateend",this._flowHandler),this._sourceBuffer.removeEventListener("error",this._errorHandler),"open"===this._mediaSource.readyState&&this._sourceBuffer.abort()),e&&this.emit("error",e),this.emit("close"))},u.prototype._createSourceBuffer=function(){var e=this;if(!this.destroyed)if(s.isTypeSupported(this._type)){if(this._sourceBuffer=this._mediaSource.addSourceBuffer(this._type),this._sourceBuffer.addEventListener("updateend",this._flowHandler),this._sourceBuffer.addEventListener("error",this._errorHandler),this._cb){var t=this._cb;this._cb=null,t()}}else this.destroy(new Error("The provided type is not supported"))},u.prototype._write=function(e,t,n){var r=this;if(!r.destroyed)if(r._sourceBuffer){if(r._sourceBuffer.updating)return n(new Error("Cannot append buffer while source buffer updating"));var i=o(e);r._wrapper._debug&&r._debugBuffers.push(i);try{r._sourceBuffer.appendBuffer(i)}catch(e){return void r.destroy(e)}r._cb=n}else r._cb=function(i){if(i)return n(i);r._write(e,t,n)}},u.prototype._flow=function(){var e=this;if(!this.destroyed&&this._sourceBuffer&&!this._sourceBuffer.updating&&!("open"===this._mediaSource.readyState&&this._getBufferDuration()>this._bufferDuration)&&this._cb){var t=this._cb;this._cb=null,t()}};var c=0;function h(e,t){var n=document.createElement("a");n.href=window.URL.createObjectURL(new window.Blob(e)),n.download=t,n.click()}u.prototype._getBufferDuration=function(){for(var e=this,t=this._sourceBuffer.buffered,n=this._elem.currentTime,r=-1,i=0;i<t.length;i++){var o=t.start(i),s=t.end(i)+0;if(o>n)break;(r>=0||n<=s)&&(r=s)}var a=r-n;return a<0&&(a=0),a}},function(e,t,n){var r=n(589);e.exports=function e(t,n,i){if("function"==typeof n)return e(t,null,n);r(t,n,function(e,t){if(e)return i(e);var n=URL.createObjectURL(t);i(null,n)})}},function(e,t,n){var r=n(26);e.exports=function e(t,n,i){if("function"==typeof n)return e(t,null,n);i=r(i);var o=[];t.on("data",function(e){o.push(e)}).on("end",function(){var e=n?new Blob(o,{type:n}):new Blob(o);i(null,e)}).on("error",i)}},function(e,t,n){t=e.exports=n(591),t.Stream=t,t.Readable=t,t.Writable=n(594),t.Duplex=n(141),t.Transform=n(595),t.PassThrough=n(1611)},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(592),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1608),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1609),v=n(593),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(141),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(141),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(592),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(593),y;function v(){}function b(e,t){l=l||n(141),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(141),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(141),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){var r=n(105),i=Math.pow(2,32);t.encodingLength=function(){return 8},t.encode=function(e,t,n){t||(t=r(8)),n||(n=0);var o=Math.floor(e/i),s=e-o*i;return t.writeUInt32BE(o,n),t.writeUInt32BE(s,n+4),t},t.decode=function(e,t){t||(t=0);var n=e.readUInt32BE(t),r=e.readUInt32BE(t+4);return n*i+r},t.encode.bytes=8,t.decode.bytes=8},function(e,t){function n(e,t){if(!(t>=e.length||t<0)){var n=e.pop();if(t<e.length){var r=e[t];return e[t]=n,r}return n}}e.exports=n},function(e,t,n){(function(t){const r=n(597),i=n(231),o=n(233),s=n(1620)("bittorrent-protocol"),a=n(68),l=n(101),u=n(309),c=n(1622),h=4e5,f=55e3,p=t.from("BitTorrent protocol"),d=t.from([0,0,0,0]),m=t.from([0,0,0,1,0]),g=t.from([0,0,0,1,1]),y=t.from([0,0,0,1,2]),v=t.from([0,0,0,1,3]),b=[0,0,0,0,0,0,0,0],_=[0,0,0,3,9,0,0];class w{constructor(e,t,n,r){this.piece=e,this.offset=t,this.length=n,this.callback=r}}class k extends c.Duplex{constructor(){super(),this._debugId=l(4).toString("hex"),this._debug("new wire"),this.peerId=null,this.peerIdBuffer=null,this.type=null,this.amChoking=!0,this.amInterested=!1,this.peerChoking=!0,this.peerInterested=!1,this.peerPieces=new o(0,{grow:h}),this.peerExtensions={},this.requests=[],this.peerRequests=[],this.extendedMapping={},this.peerExtendedMapping={},this.extendedHandshake={},this.peerExtendedHandshake={},this._ext={},this._nextExt=1,this.uploaded=0,this.downloaded=0,this.uploadSpeed=u(),this.downloadSpeed=u(),this._keepAliveInterval=null,this._timeout=null,this._timeoutMs=0,this.destroyed=!1,this._finished=!1,this._parserSize=0,this._parser=null,this._buffer=[],this._bufferSize=0,this.on("finish",this._onFinish),this._parseHandshake()}setKeepAlive(e){this._debug("setKeepAlive %s",e),clearInterval(this._keepAliveInterval),!1!==e&&(this._keepAliveInterval=setInterval(()=>{this.keepAlive()},f))}setTimeout(e,t){this._debug("setTimeout ms=%d unref=%s",e,t),this._clearTimeout(),this._timeoutMs=e,this._timeoutUnref=!!t,this._updateTimeout()}destroy(){this.destroyed||(this.destroyed=!0,this._debug("destroy"),this.emit("close"),this.end())}end(...e){this._debug("end"),this._onUninterested(),this._onChoke(),super.end(...e)}use(e){const t=e.prototype.name;if(!t)throw new Error('Extension class requires a "name" property on the prototype');this._debug("use extension.name=%s",t);const n=this._nextExt,r=new e(this);function i(){}"function"!=typeof r.onHandshake&&(r.onHandshake=i),"function"!=typeof r.onExtendedHandshake&&(r.onExtendedHandshake=i),"function"!=typeof r.onMessage&&(r.onMessage=i),this.extendedMapping[n]=t,this._ext[t]=r,this[t]=r,this._nextExt+=1}keepAlive(){this._debug("keep-alive"),this._push(d)}handshake(e,n,r){let i,o;if("string"==typeof e?(e=e.toLowerCase(),i=t.from(e,"hex")):(i=e,e=i.toString("hex")),"string"==typeof n?o=t.from(n,"hex"):(o=n,n=o.toString("hex")),20!==i.length||20!==o.length)throw new Error("infoHash and peerId MUST have length 20");this._debug("handshake i=%s p=%s exts=%o",e,n,r);const s=t.from(b);s[5]|=16,r&&r.dht&&(s[7]|=1),this._push(t.concat([p,s,i,o])),this._handshakeSent=!0,this.peerExtensions.extended&&!this._extendedHandshakeSent&&this._sendExtendedHandshake()}_sendExtendedHandshake(){const e=a(this.extendedHandshake);e.m={};for(const t in this.extendedMapping){const n=this.extendedMapping[t];e.m[n]=Number(t)}this.extended(0,i.encode(e)),this._extendedHandshakeSent=!0}choke(){if(!this.amChoking){for(this.amChoking=!0,this._debug("choke");this.peerRequests.length;)this.peerRequests.pop();this._push(m)}}unchoke(){this.amChoking&&(this.amChoking=!1,this._debug("unchoke"),this._push(g))}interested(){this.amInterested||(this.amInterested=!0,this._debug("interested"),this._push(y))}uninterested(){this.amInterested&&(this.amInterested=!1,this._debug("uninterested"),this._push(v))}have(e){this._debug("have %d",e),this._message(4,[e],null)}bitfield(e){this._debug("bitfield"),t.isBuffer(e)||(e=e.buffer),this._message(5,[],e)}request(e,t,n,r){return r||(r=(()=>{})),this._finished?r(new Error("wire is closed")):this.peerChoking?r(new Error("peer is choking")):(this._debug("request index=%d offset=%d length=%d",e,t,n),this.requests.push(new w(e,t,n,r)),this._updateTimeout(),void this._message(6,[e,t,n],null))}piece(e,t,n){this._debug("piece index=%d offset=%d",e,t),this.uploaded+=n.length,this.uploadSpeed(n.length),this.emit("upload",n.length),this._message(7,[e,t],n)}cancel(e,t,n){this._debug("cancel index=%d offset=%d length=%d",e,t,n),this._callback(this._pull(this.requests,e,t,n),new Error("request was cancelled"),null),this._message(8,[e,t,n],null)}port(e){this._debug("port %d",e);const n=t.from(_);n.writeUInt16BE(e,5),this._push(n)}extended(e,n){if(this._debug("extended ext=%s",e),"string"==typeof e&&this.peerExtendedMapping[e]&&(e=this.peerExtendedMapping[e]),"number"!=typeof e)throw new Error(`Unrecognized extension: ${e}`);{const r=t.from([e]),o=t.isBuffer(n)?n:i.encode(n);this._message(20,[],t.concat([r,o]))}}_read(){}_message(e,n,r){const i=r?r.length:0,o=t.allocUnsafe(5+4*n.length);o.writeUInt32BE(o.length+i-4,0),o[4]=e;for(let e=0;e<n.length;e++)o.writeUInt32BE(n[e],5+4*e);this._push(o),r&&this._push(r)}_push(e){if(!this._finished)return this.push(e)}_onKeepAlive(){this._debug("got keep-alive"),this.emit("keep-alive")}_onHandshake(e,t,n){const r=e.toString("hex"),i=t.toString("hex");let o;for(o in this._debug("got handshake i=%s p=%s exts=%o",r,i,n),this.peerId=i,this.peerIdBuffer=t,this.peerExtensions=n,this.emit("handshake",r,i,n),this._ext)this._ext[o].onHandshake(r,i,n);n.extended&&this._handshakeSent&&!this._extendedHandshakeSent&&this._sendExtendedHandshake()}_onChoke(){for(this.peerChoking=!0,this._debug("got choke"),this.emit("choke");this.requests.length;)this._callback(this.requests.pop(),new Error("peer is choking"),null)}_onUnchoke(){this.peerChoking=!1,this._debug("got unchoke"),this.emit("unchoke")}_onInterested(){this.peerInterested=!0,this._debug("got interested"),this.emit("interested")}_onUninterested(){this.peerInterested=!1,this._debug("got uninterested"),this.emit("uninterested")}_onHave(e){this.peerPieces.get(e)||(this._debug("got have %d",e),this.peerPieces.set(e,!0),this.emit("have",e))}_onBitField(e){this.peerPieces=new o(e),this._debug("got bitfield"),this.emit("bitfield",this.peerPieces)}_onRequest(e,t,n){if(this.amChoking)return;this._debug("got request index=%d offset=%d length=%d",e,t,n);const r=(r,o)=>{if(i===this._pull(this.peerRequests,e,t,n))return r?this._debug("error satisfying request index=%d offset=%d length=%d (%s)",e,t,n,r.message):void this.piece(e,t,o)};var i=new w(e,t,n,r);this.peerRequests.push(i),this.emit("request",e,t,n,r)}_onPiece(e,t,n){this._debug("got piece index=%d offset=%d",e,t),this._callback(this._pull(this.requests,e,t,n.length),null,n),this.downloaded+=n.length,this.downloadSpeed(n.length),this.emit("download",n.length),this.emit("piece",e,t,n)}_onCancel(e,t,n){this._debug("got cancel index=%d offset=%d length=%d",e,t,n),this._pull(this.peerRequests,e,t,n),this.emit("cancel",e,t,n)}_onPort(e){this._debug("got port %d",e),this.emit("port",e)}_onExtended(e,t){if(0===e){let e,n;try{e=i.decode(t)}catch(e){this._debug("ignoring invalid extended handshake: %s",e.message||e)}if(!e)return;if(this.peerExtendedHandshake=e,"object"==typeof e.m)for(n in e.m)this.peerExtendedMapping[n]=Number(e.m[n].toString());for(n in this._ext)this.peerExtendedMapping[n]&&this._ext[n].onExtendedHandshake(this.peerExtendedHandshake);this._debug("got extended handshake"),this.emit("extended","handshake",this.peerExtendedHandshake)}else this.extendedMapping[e]&&(e=this.extendedMapping[e],this._ext[e]&&this._ext[e].onMessage(t)),this._debug("got extended message ext=%s",e),this.emit("extended",e,t)}_onTimeout(){this._debug("request timed out"),this._callback(this.requests.shift(),new Error("request has timed out"),null),this.emit("timeout")}_write(e,n,r){for(this._bufferSize+=e.length,this._buffer.push(e);this._bufferSize>=this._parserSize;){const e=1===this._buffer.length?this._buffer[0]:t.concat(this._buffer);this._bufferSize-=this._parserSize,this._buffer=this._bufferSize?[e.slice(this._parserSize)]:[],this._parser(e.slice(0,this._parserSize))}r(null)}_callback(e,t,n){e&&(this._clearTimeout(),this.peerChoking||this._finished||this._updateTimeout(),e.callback(t,n))}_clearTimeout(){this._timeout&&(clearTimeout(this._timeout),this._timeout=null)}_updateTimeout(){this._timeoutMs&&this.requests.length&&!this._timeout&&(this._timeout=setTimeout(()=>this._onTimeout(),this._timeoutMs),this._timeoutUnref&&this._timeout.unref&&this._timeout.unref())}_parse(e,t){this._parserSize=e,this._parser=t}_onMessageLength(e){const t=e.readUInt32BE(0);t>0?this._parse(t,this._onMessage):(this._onKeepAlive(),this._parse(4,this._onMessageLength))}_onMessage(e){switch(this._parse(4,this._onMessageLength),e[0]){case 0:return this._onChoke();case 1:return this._onUnchoke();case 2:return this._onInterested();case 3:return this._onUninterested();case 4:return this._onHave(e.readUInt32BE(1));case 5:return this._onBitField(e.slice(1));case 6:return this._onRequest(e.readUInt32BE(1),e.readUInt32BE(5),e.readUInt32BE(9));case 7:return this._onPiece(e.readUInt32BE(1),e.readUInt32BE(5),e.slice(9));case 8:return this._onCancel(e.readUInt32BE(1),e.readUInt32BE(5),e.readUInt32BE(9));case 9:return this._onPort(e.readUInt16BE(1));case 20:return this._onExtended(e.readUInt8(1),e.slice(2));default:return this._debug("got unknown message"),this.emit("unknownmessage",e)}}_parseHandshake(){this._parse(1,e=>{const t=e.readUInt8(0);this._parse(t+48,e=>{const n=e.slice(0,t);if("BitTorrent protocol"!==n.toString())return this._debug("Error: wire not speaking BitTorrent protocol (%s)",n.toString()),void this.end();e=e.slice(t),this._onHandshake(e.slice(8,28),e.slice(28,48),{dht:!!(1&e[7]),extended:!!(16&e[5])}),this._parse(4,this._onMessageLength)})})}_onFinish(){for(this._finished=!0,this.push(null);this.read(););for(clearInterval(this._keepAliveInterval),this._parse(Number.MAX_VALUE,()=>{});this.peerRequests.length;)this.peerRequests.pop();for(;this.requests.length;)this._callback(this.requests.pop(),new Error("wire was closed"),null)}_debug(...e){e[0]=`[${this._debugId}] ${e[0]}`,s(...e)}_pull(e,t,n,i){for(let o=0;o<e.length;o++){const s=e[o];if(s.piece===t&&s.offset===n&&s.length===i)return r(e,o),s}return null}}e.exports=k}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t,r){var i=n(11);e.exports=E;var o=n(49),s;E.ReadableState=k;var a=n(6).EventEmitter,l=function(e,t){return e.listeners(t).length},u=n(600),c=n(5).Buffer,h=t.Uint8Array||function(){};function f(e){return c.from(e)}function p(e){return c.isBuffer(e)||e instanceof h}var d=n(7);d.inherits=n(1);var m=n(1623),g=void 0;g=m&&m.debuglog?m.debuglog("stream"):function(){};var y=n(1624),v=n(601),b;d.inherits(E,u);var _=["error","close","destroy","pause","resume"];function w(e,t,n){if("function"==typeof e.prependListener)return e.prependListener(t,n);e._events&&e._events[t]?o(e._events[t])?e._events[t].unshift(n):e._events[t]=[n,e._events[t]]:e.on(t,n)}function k(e,t){s=s||n(142),e=e||{};var r=t instanceof s;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,o=e.readableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new y,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(b||(b=n(18).StringDecoder),this.decoder=new b(e.encoding),this.encoding=e.encoding)}function E(e){if(s=s||n(142),!(this instanceof E))return new E(e);this._readableState=new k(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),u.call(this)}function S(e,t,n,r,i){var o=e._readableState,s;null===t?(o.reading=!1,R(e,o)):(i||(s=C(o,t)),s?e.emit("error",s):o.objectMode||t&&t.length>0?("string"==typeof t||o.objectMode||Object.getPrototypeOf(t)===c.prototype||(t=f(t)),r?o.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):x(e,o,t,!0):o.ended?e.emit("error",new Error("stream.push() after EOF")):(o.reading=!1,o.decoder&&!n?(t=o.decoder.write(t),o.objectMode||0!==t.length?x(e,o,t,!1):P(e,o)):x(e,o,t,!1))):r||(o.reading=!1));return A(o)}function x(e,t,n,r){t.flowing&&0===t.length&&!t.sync?(e.emit("data",n),e.read(0)):(t.length+=t.objectMode?1:n.length,r?t.buffer.unshift(n):t.buffer.push(n),t.needReadable&&B(e)),P(e,t)}function C(e,t){var n;return p(t)||"string"==typeof t||void 0===t||e.objectMode||(n=new TypeError("Invalid non-string/buffer chunk")),n}function A(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}Object.defineProperty(E.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),E.prototype.destroy=v.destroy,E.prototype._undestroy=v.undestroy,E.prototype._destroy=function(e,t){this.push(null),t(e)},E.prototype.push=function(e,t){var n=this._readableState,r;return n.objectMode?r=!0:"string"==typeof e&&(t=t||n.defaultEncoding,t!==n.encoding&&(e=c.from(e,t),t=""),r=!0),S(this,e,t,!1,r)},E.prototype.unshift=function(e){return S(this,e,null,!0,!1)},E.prototype.isPaused=function(){return!1===this._readableState.flowing},E.prototype.setEncoding=function(e){return b||(b=n(18).StringDecoder),this._readableState.decoder=new b(e),this._readableState.encoding=e,this};var T=8388608;function I(e){return e>=T?e=T:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}function j(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=I(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function R(e,t){if(!t.ended){if(t.decoder){var n=t.decoder.end();n&&n.length&&(t.buffer.push(n),t.length+=t.objectMode?1:n.length)}t.ended=!0,B(e)}}function B(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(g("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?i.nextTick(O,e):O(e))}function O(e){g("emit readable"),e.emit("readable"),U(e)}function P(e,t){t.readingMore||(t.readingMore=!0,i.nextTick(N,e,t))}function N(e,t){for(var n=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(g("maybeReadMore read 0"),e.read(0),n!==t.length);)n=t.length;t.readingMore=!1}function D(e){return function(){var t=e._readableState;g("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&l(e,"data")&&(t.flowing=!0,U(e))}}function M(e){g("readable nexttick read 0"),e.read(0)}function F(e,t){t.resumeScheduled||(t.resumeScheduled=!0,i.nextTick(L,e,t))}function L(e,t){t.reading||(g("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),U(e),t.flowing&&!t.reading&&e.read(0)}function U(e){var t=e._readableState;for(g("flow",t.flowing);t.flowing&&null!==e.read(););}function q(e,t){return 0===t.length?null:(t.objectMode?n=t.buffer.shift():!e||e>=t.length?(n=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):n=z(e,t.buffer,t.decoder),n);var n}function z(e,t,n){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():n?K(e,t):H(e,t),r}function K(e,t){var n=t.head,r=1,i=n.data;for(e-=i.length;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),e-=s,0===e){s===o.length?(++r,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n,n.data=o.slice(s));break}++r}return t.length-=r,i}function H(e,t){var n=c.allocUnsafe(e),r=t.head,i=1;for(r.data.copy(n),e-=r.data.length;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(o.copy(n,n.length-e,0,s),e-=s,0===e){s===o.length?(++i,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=o.slice(s));break}++i}return t.length-=i,n}function V(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,i.nextTick($,t,e))}function $(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function W(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1}E.prototype.read=function(e){g("read",e),e=parseInt(e,10);var t=this._readableState,n=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return g("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?V(this):B(this),null;if(e=j(e,t),0===e&&t.ended)return 0===t.length&&V(this),null;var r=t.needReadable,i;return g("need readable",r),(0===t.length||t.length-e<t.highWaterMark)&&(r=!0,g("length less than watermark",r)),t.ended||t.reading?(r=!1,g("reading or ended",r)):r&&(g("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=j(n,t))),i=e>0?q(e,t):null,null===i?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),n!==e&&t.ended&&V(this)),null!==i&&this.emit("data",i),i},E.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},E.prototype.pipe=function(e,t){var n=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=e;break;case 1:o.pipes=[o.pipes,e];break;default:o.pipes.push(e)}o.pipesCount+=1,g("pipe count=%d opts=%j",o.pipesCount,t);var s=(!t||!1!==t.end)&&e!==r.stdout&&e!==r.stderr,a=s?c:_;function u(e,t){g("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,p())}function c(){g("onend"),e.end()}o.endEmitted?i.nextTick(a):n.once("end",a),e.on("unpipe",u);var h=D(n);e.on("drain",h);var f=!1;function p(){g("cleanup"),e.removeListener("close",v),e.removeListener("finish",b),e.removeListener("drain",h),e.removeListener("error",y),e.removeListener("unpipe",u),n.removeListener("end",c),n.removeListener("end",_),n.removeListener("data",m),f=!0,!o.awaitDrain||e._writableState&&!e._writableState.needDrain||h()}var d=!1;function m(t){g("ondata"),d=!1;var r=e.write(t);!1!==r||d||((1===o.pipesCount&&o.pipes===e||o.pipesCount>1&&-1!==W(o.pipes,e))&&!f&&(g("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,d=!0),n.pause())}function y(t){g("onerror",t),_(),e.removeListener("error",y),0===l(e,"error")&&e.emit("error",t)}function v(){e.removeListener("finish",b),_()}function b(){g("onfinish"),e.removeListener("close",v),_()}function _(){g("unpipe"),n.unpipe(e)}return n.on("data",m),w(e,"error",y),e.once("close",v),e.once("finish",b),e.emit("pipe",n),o.flowing||(g("pipe resume"),n.resume()),e},E.prototype.unpipe=function(e){var t=this._readableState,n={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes?this:(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,n),this);if(!e){var r=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)r[o].emit("unpipe",this,n);return this}var s=W(t.pipes,e);return-1===s?this:(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,n),this)},E.prototype.on=function(e,t){var n=u.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&B(this):i.nextTick(M,this))}return n},E.prototype.addListener=E.prototype.on,E.prototype.resume=function(){var e=this._readableState;return e.flowing||(g("resume"),e.flowing=!0,F(this,e)),this},E.prototype.pause=function(){return g("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(g("pause"),this._readableState.flowing=!1,this.emit("pause")),this},E.prototype.wrap=function(e){var t=this,n=this._readableState,r=!1;for(var i in e.on("end",function(){if(g("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&t.push(e)}t.push(null)}),e.on("data",function(i){if(g("wrapped data"),n.decoder&&(i=n.decoder.write(i)),(!n.objectMode||null!==i&&void 0!==i)&&(n.objectMode||i&&i.length)){var o=t.push(i);o||(r=!0,e.pause())}}),e)void 0===this[i]&&"function"==typeof e[i]&&(this[i]=function(t){return function(){return e[t].apply(e,arguments)}}(i));for(var o=0;o<_.length;o++)e.on(_[o],this.emit.bind(this,_[o]));return this._read=function(t){g("wrapped _read",t),r&&(r=!1,e.resume())},this},Object.defineProperty(E.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),E._fromList=q}).call(this,n(8),n(3))},function(e,t,n){e.exports=n(6).EventEmitter},function(e,t,n){"use strict";var r=n(11);function i(e,t){var n=this,i=this._readableState&&this._readableState.destroyed,o=this._writableState&&this._writableState.destroyed;return i||o?(t?t(e):!e||this._writableState&&this._writableState.errorEmitted||r.nextTick(s,this,e),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(r.nextTick(s,n,e),n._writableState&&(n._writableState.errorEmitted=!0)):t&&t(e)}),this)}function o(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function s(e,t){e.emit("error",t)}e.exports={destroy:i,undestroy:o}},function(e,t,n){"use strict";(function(t,r){var i=n(11);function o(e,t,n){this.chunk=e,this.encoding=t,this.callback=n,this.next=null}function s(e){var t=this;this.next=null,this.entry=null,this.finish=function(){M(t,e)}}e.exports=_;var a=!t.browser&&["v0.10","v0.9."].indexOf(t.version.slice(0,5))>-1?setImmediate:i.nextTick,l;_.WritableState=b;var u=n(7);u.inherits=n(1);var c={deprecate:n(50)},h=n(600),f=n(5).Buffer,p=r.Uint8Array||function(){};function d(e){return f.from(e)}function m(e){return f.isBuffer(e)||e instanceof p}var g=n(601),y;function v(){}function b(e,t){l=l||n(142),e=e||{};var r=t instanceof l;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,o=e.writableHighWaterMark,a=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r&&(o||0===o)?o:a,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var u=!1===e.decodeStrings;this.decodeStrings=!u,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){T(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new s(this)}function _(e){if(l=l||n(142),!(y.call(_,this)||this instanceof l))return new _(e);this._writableState=new b(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev),"function"==typeof e.destroy&&(this._destroy=e.destroy),"function"==typeof e.final&&(this._final=e.final)),h.call(this)}function w(e,t){var n=new Error("write after end");e.emit("error",n),i.nextTick(t,n)}function k(e,t,n,r){var o=!0,s=!1;return null===n?s=new TypeError("May not write null values to stream"):"string"==typeof n||void 0===n||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),i.nextTick(r,s),o=!1),o}function E(e,t,n){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=f.from(t,n)),t}function S(e,t,n,r,i,o){if(!n){var s=E(t,r,i);r!==s&&(n=!0,i="buffer",r=s)}var a=t.objectMode?1:r.length;t.length+=a;var l=t.length<t.highWaterMark;if(l||(t.needDrain=!0),t.writing||t.corked){var u=t.lastBufferedRequest;t.lastBufferedRequest={chunk:r,encoding:i,isBuf:n,callback:o,next:null},u?u.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else x(e,t,!1,a,r,i,o);return l}function x(e,t,n,r,i,o,s){t.writelen=r,t.writecb=s,t.writing=!0,t.sync=!0,n?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function C(e,t,n,r,o){--t.pendingcb,n?(i.nextTick(o,r),i.nextTick(N,e,t),e._writableState.errorEmitted=!0,e.emit("error",r)):(o(r),e._writableState.errorEmitted=!0,e.emit("error",r),N(e,t))}function A(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}function T(e,t){var n=e._writableState,r=n.sync,i=n.writecb;if(A(n),t)C(e,n,r,t,i);else{var o=B(n);o||n.corked||n.bufferProcessing||!n.bufferedRequest||R(e,n),r?a(I,e,n,o,i):I(e,n,o,i)}}function I(e,t,n,r){n||j(e,t),t.pendingcb--,r(),N(e,t)}function j(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}function R(e,t){t.bufferProcessing=!0;var n=t.bufferedRequest;if(e._writev&&n&&n.next){var r=t.bufferedRequestCount,i=new Array(r),o=t.corkedRequestsFree;o.entry=n;for(var a=0,l=!0;n;)i[a]=n,n.isBuf||(l=!1),n=n.next,a+=1;i.allBuffers=l,x(e,t,!0,t.length,i,"",o.finish),t.pendingcb++,t.lastBufferedRequest=null,o.next?(t.corkedRequestsFree=o.next,o.next=null):t.corkedRequestsFree=new s(t),t.bufferedRequestCount=0}else{for(;n;){var u=n.chunk,c=n.encoding,h=n.callback,f=t.objectMode?1:u.length;if(x(e,t,!1,f,u,c,h),n=n.next,t.bufferedRequestCount--,t.writing)break}null===n&&(t.lastBufferedRequest=null)}t.bufferedRequest=n,t.bufferProcessing=!1}function B(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function O(e,t){e._final(function(n){t.pendingcb--,n&&e.emit("error",n),t.prefinished=!0,e.emit("prefinish"),N(e,t)})}function P(e,t){t.prefinished||t.finalCalled||("function"==typeof e._final?(t.pendingcb++,t.finalCalled=!0,i.nextTick(O,e,t)):(t.prefinished=!0,e.emit("prefinish")))}function N(e,t){var n=B(t);return n&&(P(e,t),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),n}function D(e,t,n){t.ending=!0,N(e,t),n&&(t.finished?i.nextTick(n):e.once("finish",n)),t.ended=!0,e.writable=!1}function M(e,t,n){var r=e.entry;for(e.entry=null;r;){var i=r.callback;t.pendingcb--,i(n),r=r.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}u.inherits(_,h),b.prototype.getBuffer=function e(){for(var t=this.bufferedRequest,n=[];t;)n.push(t),t=t.next;return n},function(){try{Object.defineProperty(b.prototype,"buffer",{get:c.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(e){}}(),"function"==typeof Symbol&&Symbol.hasInstance&&"function"==typeof Function.prototype[Symbol.hasInstance]?(y=Function.prototype[Symbol.hasInstance],Object.defineProperty(_,Symbol.hasInstance,{value:function(e){return!!y.call(this,e)||this===_&&(e&&e._writableState instanceof b)}})):y=function(e){return e instanceof this},_.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},_.prototype.write=function(e,t,n){var r=this._writableState,i=!1,o=!r.objectMode&&m(e);return o&&!f.isBuffer(e)&&(e=d(e)),"function"==typeof t&&(n=t,t=null),o?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof n&&(n=v),r.ended?w(this,n):(o||k(this,r,e,n))&&(r.pendingcb++,i=S(this,r,o,e,t,n)),i},_.prototype.cork=function(){var e=this._writableState;e.corked++},_.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||R(this,e))},_.prototype.setDefaultEncoding=function e(t){if("string"==typeof t&&(t=t.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((t+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(_.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),_.prototype._write=function(e,t,n){n(new Error("_write() is not implemented"))},_.prototype._writev=null,_.prototype.end=function(e,t,n){var r=this._writableState;"function"==typeof e?(n=e,e=null,t=null):"function"==typeof t&&(n=t,t=null),null!==e&&void 0!==e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||D(this,r,n)},Object.defineProperty(_.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),_.prototype.destroy=g.destroy,_.prototype._undestroy=g.undestroy,_.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,n(3),n(8))},function(e,t,n){"use strict";e.exports=s;var r=n(142),i=n(7);function o(e,t){var n=this._transformState;n.transforming=!1;var r=n.writecb;if(!r)return this.emit("error",new Error("write callback called multiple times"));n.writechunk=null,n.writecb=null,null!=t&&this.push(t),r(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}function s(e){if(!(this instanceof s))return new s(e);r.call(this,e),this._transformState={afterTransform:o.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.on("prefinish",a)}function a(){var e=this;"function"==typeof this._flush?this._flush(function(t,n){l(e,t,n)}):l(this,null,null)}function l(e,t,n){if(t)return e.emit("error",t);if(null!=n&&e.push(n),e._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(e._transformState.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}i.inherits=n(1),i.inherits(s,r),s.prototype.push=function(e,t){return this._transformState.needTransform=!1,r.prototype.push.call(this,e,t)},s.prototype._transform=function(e,t,n){throw new Error("_transform() is not implemented")},s.prototype._write=function(e,t,n){var r=this._transformState;if(r.writecb=n,r.writechunk=e,r.writeencoding=t,!r.transforming){var i=this._readableState;(r.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},s.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},s.prototype._destroy=function(e,t){var n=this;r.prototype._destroy.call(this,e,function(e){t(e),n.emit("close")})}},function(e,t,n){const r=n(1631);e.exports.FS=r;const i=n(1781);e.exports.WOLK=i},function(e,t,n){"use strict";var r=n(312),i=n(606),o=n(313),s=o.paramsHaveRequestBody;function a(e,t,n){"function"==typeof t&&(n=t);var i={};return"object"==typeof t?r(i,t,{uri:e}):r(i,"string"==typeof e?{uri:e}:e),i.callback=n||i.callback,i}function l(e,t,n){if(void 0===e)throw new Error("undefined is not a valid uri or options object.");var r=a(e,t,n);if("HEAD"===r.method&&s(r))throw new Error("HTTP HEAD requests MUST NOT include a request body.");return new l.Request(r)}function u(e){var t=e.toUpperCase();return function(e,n,r){var i=a(e,n,r);return i.method=t,l(i,i.callback)}}function c(e,t,n,i){return function(o,s,l){var u=a(o,s,l),c={};return r(!0,c,t,u),c.pool=u.pool||t.pool,i&&(c.method=i.toUpperCase()),"function"==typeof n&&(e=n),e(c,c.callback)}}l.get=u("get"),l.head=u("head"),l.options=u("options"),l.post=u("post"),l.put=u("put"),l.patch=u("patch"),l.del=u("delete"),l.delete=u("delete"),l.jar=function(e){return i.jar(e)},l.cookie=function(e){return i.parse(e)},l.defaults=function(e,t){var n=this;e=e||{},"function"==typeof e&&(t=e,e={});var r=c(n,e,t),i=["get","head","post","put","patch","del","delete"];return i.forEach(function(i){r[i]=c(n[i],e,t,i)}),r.cookie=c(n.cookie,e,t),r.jar=n.jar,r.defaults=n.defaults,r},l.forever=function(e,t){var n={};return t&&r(n,t),e&&(n.agentOptions=e),n.forever=!0,l.defaults(n)},e.exports=l,l.Request=n(1636),l.initParams=a,Object.defineProperty(l,"debug",{enumerable:!0,get:function(){return l.Request.debug},set:function(e){l.Request.debug=e}})},function(e,t,n){"use strict";var r=n(1632),i=r.Cookie,o=r.CookieJar;function s(e){var t=this;this._jar=new o(e,{looseMode:!0})}t.parse=function(e){if(e&&e.uri&&(e=e.uri),"string"!=typeof e)throw new Error("The cookie function only accepts STRING as param");return i.parse(e,{loose:!0})},s.prototype.setCookie=function(e,t,n){var r=this;return this._jar.setCookieSync(e,t,n||{})},s.prototype.getCookieString=function(e){var t=this;return this._jar.getCookieStringSync(e)},s.prototype.getCookies=function(e){var t=this;return this._jar.getCookiesSync(e)},t.jar=function(e){return new s(e)}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2018, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(608);function i(e){return r.get(e)}t.getPublicSuffix=i},function(e,t,n){"use strict";var r=n(179),i={};i.rules=n(1633).map(function(e){return{rule:e,suffix:e.replace(/^(\*\.|\!)/,""),punySuffix:-1,wildcard:"*"===e.charAt(0),exception:"!"===e.charAt(0)}}),i.endsWith=function(e,t){return-1!==e.indexOf(t,e.length-t.length)},i.findRule=function(e){var t=r.toASCII(e);return i.rules.reduce(function(e,n){return-1===n.punySuffix&&(n.punySuffix=r.toASCII(n.suffix)),i.endsWith(t,"."+n.punySuffix)||t===n.punySuffix?n:e},null)},t.errorCodes={DOMAIN_TOO_SHORT:"Domain name too short.",DOMAIN_TOO_LONG:"Domain name too long. It should be no more than 255 chars.",LABEL_STARTS_WITH_DASH:"Domain name label can not start with a dash.",LABEL_ENDS_WITH_DASH:"Domain name label can not end with a dash.",LABEL_TOO_LONG:"Domain name label should be at most 63 chars long.",LABEL_TOO_SHORT:"Domain name label should be at least 1 character long.",LABEL_INVALID_CHARS:"Domain name label can only contain alphanumeric characters or dashes."},i.validate=function(e){var t=r.toASCII(e);if(t.length<1)return"DOMAIN_TOO_SHORT";if(t.length>255)return"DOMAIN_TOO_LONG";for(var n=t.split("."),i,o=0;o<n.length;++o){if(i=n[o],!i.length)return"LABEL_TOO_SHORT";if(i.length>63)return"LABEL_TOO_LONG";if("-"===i.charAt(0))return"LABEL_STARTS_WITH_DASH";if("-"===i.charAt(i.length-1))return"LABEL_ENDS_WITH_DASH";if(!/^[a-z0-9\-]+$/.test(i))return"LABEL_INVALID_CHARS"}},t.parse=function(e){if("string"!=typeof e)throw new TypeError("Domain name must be a string.");var n=e.slice(0).toLowerCase();"."===n.charAt(n.length-1)&&(n=n.slice(0,n.length-1));var o=i.validate(n);if(o)return{input:e,error:{message:t.errorCodes[o],code:o}};var s={input:e,tld:null,sld:null,domain:null,subdomain:null,listed:!1},a=n.split(".");if("local"===a[a.length-1])return s;var l=function(){return/xn--/.test(n)?(s.domain&&(s.domain=r.toASCII(s.domain)),s.subdomain&&(s.subdomain=r.toASCII(s.subdomain)),s):s},u=i.findRule(n);if(!u)return a.length<2?s:(s.tld=a.pop(),s.sld=a.pop(),s.domain=[s.sld,s.tld].join("."),a.length&&(s.subdomain=a.pop()),l());s.listed=!0;var c=u.suffix.split("."),h=a.slice(0,a.length-c.length);return u.exception&&h.push(c.shift()),s.tld=c.join("."),h.length?(u.wildcard&&(c.unshift(h.pop()),s.tld=c.join(".")),h.length?(s.sld=h.pop(),s.domain=[s.sld,s.tld].join("."),h.length&&(s.subdomain=h.join(".")),l()):l()):l()},t.get=function(e){return e&&t.parse(e).domain||null},t.isValid=function(e){var n=t.parse(e);return Boolean(n.domain&&n.listed)}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/function r(){}t.Store=r,r.prototype.synchronous=!1,r.prototype.findCookie=function(e,t,n,r){throw new Error("findCookie is not implemented")},r.prototype.findCookies=function(e,t,n){throw new Error("findCookies is not implemented")},r.prototype.putCookie=function(e,t){throw new Error("putCookie is not implemented")},r.prototype.updateCookie=function(e,t,n){throw new Error("updateCookie is not implemented")},r.prototype.removeCookie=function(e,t,n,r){throw new Error("removeCookie is not implemented")},r.prototype.removeCookies=function(e,t,n){throw new Error("removeCookies is not implemented")},r.prototype.getAllCookies=function(e){throw new Error("getAllCookies is not implemented (therefore jar cannot be serialized)")}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(607);function i(e){var t=r.getPublicSuffix(e);if(!t)return null;if(t==e)return[e];for(var n=e.slice(0,-(t.length+1)),i=n.split(".").reverse(),o=t,s=[o];i.length;)o=i.shift()+"."+o,s.push(o);return s}t.permuteDomain=i},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/function r(e,t){if(t===e)return!0;var n=e.indexOf(t);if(0===n){if("/"===t.substr(-1))return!0;if("/"===e.substr(t.length,1))return!0}return!1}t.pathMatch=r},function(e,t,n){"use strict";function r(e,t,n,r){for(var i=65535&e|0,o=e>>>16&65535|0,s=0;0!==n;){s=n>2e3?2e3:n,n-=s;do{i=i+t[r++]|0,o=o+i|0}while(--s);i%=65521,o%=65521}return i|o<<16|0}e.exports=r},function(e,t,n){"use strict";function r(){for(var e,t=[],n=0;n<256;n++){e=n;for(var r=0;r<8;r++)e=1&e?3988292384^e>>>1:e>>>1;t[n]=e}return t}var i=r();function o(e,t,n,r){var o=i,s=r+n;e^=-1;for(var a=r;a<s;a++)e=e>>>8^o[255&(e^t[a])];return-1^e}e.exports=o},function(e,t,n){e.exports={Verifier:u,Signer:c};var r=n(174),i=n(62),o=n(14),s=n(25),a=n(29).Buffer,l=n(83);function u(e,t){if("sha512"!==t.toLowerCase())throw new Error("ED25519 only supports the use of SHA-512 hashes");this.key=e,this.chunks=[],i.Writable.call(this,{})}function c(e,t){if("sha512"!==t.toLowerCase())throw new Error("ED25519 only supports the use of SHA-512 hashes");this.key=e,this.chunks=[],i.Writable.call(this,{})}o.inherits(u,i.Writable),u.prototype._write=function(e,t,n){this.chunks.push(e),n()},u.prototype.update=function(e){"string"==typeof e&&(e=a.from(e,"binary")),this.chunks.push(e)},u.prototype.verify=function(e,t){var n;if(l.isSignature(e,[2,0])){if("ed25519"!==e.type)return!1;n=e.toBuffer("raw")}else if("string"==typeof e)n=a.from(e,"base64");else if(l.isSignature(e,[1,0]))throw new Error("signature was created by too old a version of sshpk and cannot be verified");return s.buffer(n),r.sign.detached.verify(new Uint8Array(a.concat(this.chunks)),new Uint8Array(n),new Uint8Array(this.key.part.A.data))},o.inherits(c,i.Writable),c.prototype._write=function(e,t,n){this.chunks.push(e),n()},c.prototype.update=function(e){"string"==typeof e&&(e=a.from(e,"binary")),this.chunks.push(e)},c.prototype.sign=function(){var e=r.sign.detached(new Uint8Array(a.concat(this.chunks)),new Uint8Array(a.concat([this.key.part.k.data,this.key.part.A.data]))),t=a.from(e),n=l.parse(t,"ed25519","raw");return n.hashAlgorithm="sha512",n}},function(e,t,n){e.exports={read:d,write:b};var r=n(25),i=n(29).Buffer,o=n(42),s=n(41),a=n(46),l=n(92),u=n(617),c=n(93),h=n(319),f=n(618),p="Private-key-format: v1";function d(e,t){if("string"==typeof e){if(e.trim().match(/^[-]+[ ]*BEGIN/))return l.read(e,t);if(e.match(/^\s*ssh-[a-z]/))return u.read(e,t);if(e.match(/^\s*ecdsa-/))return u.read(e,t);if(e.match(/^putty-user-key-file-2:/i))return f.read(e,t);if(v(e))return h.read(e,t);e=i.from(e,"binary")}else{if(r.buffer(e),y(e))return l.read(e,t);if(g(e))return u.read(e,t);if(m(e))return f.read(e,t);if(v(e))return h.read(e,t)}if(e.readUInt32BE(0)<e.length)return c.read(e,t);throw new Error("Failed to auto-detect format of key")}function m(e){for(var t=0;t<e.length&&(32===e[t]||10===e[t]||9===e[t]);)++t;return t+22<=e.length&&"putty-user-key-file-2:"===e.slice(t,t+22).toString("ascii").toLowerCase()}function g(e){for(var t=0;t<e.length&&(32===e[t]||10===e[t]||9===e[t]);)++t;return t+4<=e.length&&"ssh-"===e.slice(t,t+4).toString("ascii")||t+6<=e.length&&"ecdsa-"===e.slice(t,t+6).toString("ascii")}function y(e){for(var t=0;t<e.length&&(32===e[t]||10===e[t]);)++t;if(45!==e[t])return!1;for(;t<e.length&&45===e[t];)++t;for(;t<e.length&&32===e[t];)++t;return!(t+5>e.length||"BEGIN"!==e.slice(t,t+5).toString("ascii"))}function v(e){if(e.length<=p.length)return!1;var t=e.slice(0,p.length);if(t.toString("ascii")===p)return!0;"string"!=typeof e&&(e=e.toString("ascii"));for(var n=e.split("\n"),r=0;n[r].match(/^\;/);)r++;return!!n[r].toString("ascii").match(/\. IN KEY /)||!!n[r].toString("ascii").match(/\. IN DNSKEY /)}function b(e,t){throw new Error('"auto" format cannot be used for writing')}},function(e,t,n){"use strict";var r=n(174).lowlevel.crypto_hash,i=0,o=function(){this.S=[new Uint32Array([3509652390,2564797868,805139163,3491422135,3101798381,1780907670,3128725573,4046225305,614570311,3012652279,134345442,2240740374,1667834072,1901547113,2757295779,4103290238,227898511,1921955416,1904987480,2182433518,2069144605,3260701109,2620446009,720527379,3318853667,677414384,3393288472,3101374703,2390351024,1614419982,1822297739,2954791486,3608508353,3174124327,2024746970,1432378464,3864339955,2857741204,1464375394,1676153920,1439316330,715854006,3033291828,289532110,2706671279,2087905683,3018724369,1668267050,732546397,1947742710,3462151702,2609353502,2950085171,1814351708,2050118529,680887927,999245976,1800124847,3300911131,1713906067,1641548236,4213287313,1216130144,1575780402,4018429277,3917837745,3693486850,3949271944,596196993,3549867205,258830323,2213823033,772490370,2760122372,1774776394,2652871518,566650946,4142492826,1728879713,2882767088,1783734482,3629395816,2517608232,2874225571,1861159788,326777828,3124490320,2130389656,2716951837,967770486,1724537150,2185432712,2364442137,1164943284,2105845187,998989502,3765401048,2244026483,1075463327,1455516326,1322494562,910128902,469688178,1117454909,936433444,3490320968,3675253459,1240580251,122909385,2157517691,634681816,4142456567,3825094682,3061402683,2540495037,79693498,3249098678,1084186820,1583128258,426386531,1761308591,1047286709,322548459,995290223,1845252383,2603652396,3431023940,2942221577,3202600964,3727903485,1712269319,422464435,3234572375,1170764815,3523960633,3117677531,1434042557,442511882,3600875718,1076654713,1738483198,4213154764,2393238008,3677496056,1014306527,4251020053,793779912,2902807211,842905082,4246964064,1395751752,1040244610,2656851899,3396308128,445077038,3742853595,3577915638,679411651,2892444358,2354009459,1767581616,3150600392,3791627101,3102740896,284835224,4246832056,1258075500,768725851,2589189241,3069724005,3532540348,1274779536,3789419226,2764799539,1660621633,3471099624,4011903706,913787905,3497959166,737222580,2514213453,2928710040,3937242737,1804850592,3499020752,2949064160,2386320175,2390070455,2415321851,4061277028,2290661394,2416832540,1336762016,1754252060,3520065937,3014181293,791618072,3188594551,3933548030,2332172193,3852520463,3043980520,413987798,3465142937,3030929376,4245938359,2093235073,3534596313,375366246,2157278981,2479649556,555357303,3870105701,2008414854,3344188149,4221384143,3956125452,2067696032,3594591187,2921233993,2428461,544322398,577241275,1471733935,610547355,4027169054,1432588573,1507829418,2025931657,3646575487,545086370,48609733,2200306550,1653985193,298326376,1316178497,3007786442,2064951626,458293330,2589141269,3591329599,3164325604,727753846,2179363840,146436021,1461446943,4069977195,705550613,3059967265,3887724982,4281599278,3313849956,1404054877,2845806497,146425753,1854211946]),new Uint32Array([1266315497,3048417604,3681880366,3289982499,290971e4,1235738493,2632868024,2414719590,3970600049,1771706367,1449415276,3266420449,422970021,1963543593,2690192192,3826793022,1062508698,1531092325,1804592342,2583117782,2714934279,4024971509,1294809318,4028980673,1289560198,2221992742,1669523910,35572830,157838143,1052438473,1016535060,1802137761,1753167236,1386275462,3080475397,2857371447,1040679964,2145300060,2390574316,1461121720,2956646967,4031777805,4028374788,33600511,2920084762,1018524850,629373528,3691585981,3515945977,2091462646,2486323059,586499841,988145025,935516892,3367335476,2599673255,2839830854,265290510,3972581182,2759138881,3795373465,1005194799,847297441,406762289,1314163512,1332590856,1866599683,4127851711,750260880,613907577,1450815602,3165620655,3734664991,3650291728,3012275730,3704569646,1427272223,778793252,1343938022,2676280711,2052605720,1946737175,3164576444,3914038668,3967478842,3682934266,1661551462,3294938066,4011595847,840292616,3712170807,616741398,312560963,711312465,1351876610,322626781,1910503582,271666773,2175563734,1594956187,70604529,3617834859,1007753275,1495573769,4069517037,2549218298,2663038764,504708206,2263041392,3941167025,2249088522,1514023603,1998579484,1312622330,694541497,2582060303,2151582166,1382467621,776784248,2618340202,3323268794,2497899128,2784771155,503983604,4076293799,907881277,423175695,432175456,1378068232,4145222326,3954048622,3938656102,3820766613,2793130115,2977904593,26017576,3274890735,3194772133,1700274565,1756076034,4006520079,3677328699,720338349,1533947780,354530856,688349552,3973924725,1637815568,332179504,3949051286,53804574,2852348879,3044236432,1282449977,3583942155,3416972820,4006381244,1617046695,2628476075,3002303598,1686838959,431878346,2686675385,1700445008,1080580658,1009431731,832498133,3223435511,2605976345,2271191193,2516031870,1648197032,4164389018,2548247927,300782431,375919233,238389289,3353747414,2531188641,2019080857,1475708069,455242339,2609103871,448939670,3451063019,1395535956,2413381860,1841049896,1491858159,885456874,4264095073,4001119347,1565136089,3898914787,1108368660,540939232,1173283510,2745871338,3681308437,4207628240,3343053890,4016749493,1699691293,1103962373,3625875870,2256883143,3830138730,1031889488,3479347698,1535977030,4236805024,3251091107,2132092099,1774941330,1199868427,1452454533,157007616,2904115357,342012276,595725824,1480756522,206960106,497939518,591360097,863170706,2375253569,3596610801,1814182875,2094937945,3421402208,1082520231,3463918190,2785509508,435703966,3908032597,1641649973,2842273706,3305899714,1510255612,2148256476,2655287854,3276092548,4258621189,236887753,3681803219,274041037,1734335097,3815195456,3317970021,1899903192,1026095262,4050517792,356393447,2410691914,3873677099,3682840055]),new Uint32Array([3913112168,2491498743,4132185628,2489919796,1091903735,1979897079,3170134830,3567386728,3557303409,857797738,1136121015,1342202287,507115054,2535736646,337727348,3213592640,1301675037,2528481711,1895095763,1721773893,3216771564,62756741,2142006736,835421444,2531993523,1442658625,3659876326,2882144922,676362277,1392781812,170690266,3921047035,1759253602,3611846912,1745797284,664899054,1329594018,3901205900,3045908486,2062866102,2865634940,3543621612,3464012697,1080764994,553557557,3656615353,3996768171,991055499,499776247,1265440854,648242737,3940784050,980351604,3713745714,1749149687,3396870395,4211799374,3640570775,1161844396,3125318951,1431517754,545492359,4268468663,3499529547,1437099964,2702547544,3433638243,2581715763,2787789398,1060185593,1593081372,2418618748,4260947970,69676912,2159744348,86519011,2512459080,3838209314,1220612927,3339683548,133810670,1090789135,1078426020,1569222167,845107691,3583754449,4072456591,1091646820,628848692,1613405280,3757631651,526609435,236106946,48312990,2942717905,3402727701,1797494240,859738849,992217954,4005476642,2243076622,3870952857,3732016268,765654824,3490871365,2511836413,1685915746,3888969200,1414112111,2273134842,3281911079,4080962846,172450625,2569994100,980381355,4109958455,2819808352,2716589560,2568741196,3681446669,3329971472,1835478071,660984891,3704678404,4045999559,3422617507,3040415634,1762651403,1719377915,3470491036,2693910283,3642056355,3138596744,1364962596,2073328063,1983633131,926494387,3423689081,2150032023,4096667949,1749200295,3328846651,309677260,2016342300,1779581495,3079819751,111262694,1274766160,443224088,298511866,1025883608,3806446537,1145181785,168956806,3641502830,3584813610,1689216846,3666258015,3200248200,1692713982,2646376535,4042768518,1618508792,1610833997,3523052358,4130873264,2001055236,3610705100,2202168115,4028541809,2961195399,1006657119,2006996926,3186142756,1430667929,3210227297,1314452623,4074634658,4101304120,2273951170,1399257539,3367210612,3027628629,1190975929,2062231137,2333990788,2221543033,2438960610,1181637006,548689776,2362791313,3372408396,3104550113,3145860560,296247880,1970579870,3078560182,3769228297,1714227617,3291629107,3898220290,166772364,1251581989,493813264,448347421,195405023,2709975567,677966185,3703036547,1463355134,2715995803,1338867538,1343315457,2802222074,2684532164,233230375,2599980071,2000651841,3277868038,1638401717,4028070440,3237316320,6314154,819756386,300326615,590932579,1405279636,3267499572,3150704214,2428286686,3959192993,3461946742,1862657033,1266418056,963775037,2089974820,2263052895,1917689273,448879540,3550394620,3981727096,150775221,3627908307,1303187396,508620638,2975983352,2726630617,1817252668,1876281319,1457606340,908771278,3720792119,3617206836,2455994898,1729034894,1080033504]),new Uint32Array([976866871,3556439503,2881648439,1522871579,1555064734,1336096578,3548522304,2579274686,3574697629,3205460757,3593280638,3338716283,3079412587,564236357,2993598910,1781952180,1464380207,3163844217,3332601554,1699332808,1393555694,1183702653,3581086237,1288719814,691649499,2847557200,2895455976,3193889540,2717570544,1781354906,1676643554,2592534050,3230253752,1126444790,2770207658,2633158820,2210423226,2615765581,2414155088,3127139286,673620729,2805611233,1269405062,4015350505,3341807571,4149409754,1057255273,2012875353,2162469141,2276492801,2601117357,993977747,3918593370,2654263191,753973209,36408145,2530585658,25011837,3520020182,2088578344,530523599,2918365339,1524020338,1518925132,3760827505,3759777254,1202760957,3985898139,3906192525,674977740,4174734889,2031300136,2019492241,3983892565,4153806404,3822280332,352677332,2297720250,60907813,90501309,3286998549,1016092578,2535922412,2839152426,457141659,509813237,4120667899,652014361,1966332200,2975202805,55981186,2327461051,676427537,3255491064,2882294119,3433927263,1307055953,942726286,933058658,2468411793,3933900994,4215176142,1361170020,2001714738,2830558078,3274259782,1222529897,1679025792,2729314320,3714953764,1770335741,151462246,3013232138,1682292957,1483529935,471910574,1539241949,458788160,3436315007,1807016891,3718408830,978976581,1043663428,3165965781,1927990952,4200891579,2372276910,3208408903,3533431907,1412390302,2931980059,4132332400,1947078029,3881505623,4168226417,2941484381,1077988104,1320477388,886195818,18198404,3786409e3,2509781533,112762804,3463356488,1866414978,891333506,18488651,661792760,1628790961,3885187036,3141171499,876946877,2693282273,1372485963,791857591,2686433993,3759982718,3167212022,3472953795,2716379847,445679433,3561995674,3504004811,3574258232,54117162,3331405415,2381918588,3769707343,4154350007,1140177722,4074052095,668550556,3214352940,367459370,261225585,2610173221,4209349473,3468074219,3265815641,314222801,3066103646,3808782860,282218597,3406013506,3773591054,379116347,1285071038,846784868,2669647154,3771962079,3550491691,2305946142,453669953,1268987020,3317592352,3279303384,3744833421,2610507566,3859509063,266596637,3847019092,517658769,3462560207,3443424879,370717030,4247526661,2224018117,4143653529,4112773975,2788324899,2477274417,1456262402,2901442914,1517677493,1846949527,2295493580,3734397586,2176403920,1280348187,1908823572,3871786941,846861322,1172426758,3287448474,3383383037,1655181056,3139813346,901632758,1897031941,2986607138,3066810236,3447102507,1393639104,373351379,950779232,625454576,3124240540,4148612726,2007998917,544563296,2244738638,2330496472,2058025392,1291430526,424198748,50039436,29584100,3605783033,2429876329,2791104160,1057563949,3255363231,3075367218,3463963227,1469046755,985887462])],this.P=new Uint32Array([608135816,2242054355,320440878,57701188,2752067618,698298832,137296536,3964562569,1160258022,953160567,3193202383,887688300,3232508343,3380367581,1065670069,3041331479,2450970073,2306472731])};function s(e,t,n){return(e[0][t[n+3]]+e[1][t[n+2]]^e[2][t[n+1]])+e[3][t[n]]}function a(e,t){var n,r=0;for(n=0;n<4;n++,i++)i>=t&&(i=0),r=r<<8|e[i];return r}o.prototype.encipher=function(e,t){void 0===t&&(t=new Uint8Array(e.buffer),0!==e.byteOffset&&(t=t.subarray(e.byteOffset))),e[0]^=this.P[0];for(var n=1;n<16;n+=2)e[1]^=s(this.S,t,0)^this.P[n],e[0]^=s(this.S,t,4)^this.P[n+1];var r=e[0];e[0]=e[1]^this.P[17],e[1]=r},o.prototype.decipher=function(e){var t=new Uint8Array(e.buffer);0!==e.byteOffset&&(t=t.subarray(e.byteOffset)),e[0]^=this.P[17];for(var n=16;n>0;n-=2)e[1]^=s(this.S,t,0)^this.P[n],e[0]^=s(this.S,t,4)^this.P[n-1];var r=e[0];e[0]=e[1]^this.P[0],e[1]=r},o.prototype.expand0state=function(e,t){var n=new Uint32Array(2),r,o,s=new Uint8Array(n.buffer);for(r=0,i=0;r<18;r++)this.P[r]^=a(e,t);for(i=0,r=0;r<18;r+=2)this.encipher(n,s),this.P[r]=n[0],this.P[r+1]=n[1];for(r=0;r<4;r++)for(o=0;o<256;o+=2)this.encipher(n,s),this.S[r][o]=n[0],this.S[r][o+1]=n[1]},o.prototype.expandstate=function(e,t,n,r){var o=new Uint32Array(2),s,l;for(s=0,i=0;s<18;s++)this.P[s]^=a(n,r);for(s=0,i=0;s<18;s+=2)o[0]^=a(e,t),o[1]^=a(e,t),this.encipher(o),this.P[s]=o[0],this.P[s+1]=o[1];for(s=0;s<4;s++)for(l=0;l<256;l+=2)o[0]^=a(e,t),o[1]^=a(e,t),this.encipher(o),this.S[s][l]=o[0],this.S[s][l+1]=o[1];i=0},o.prototype.enc=function(e,t){for(var n=0;n<t;n++)this.encipher(e.subarray(2*n))},o.prototype.dec=function(e,t){for(var n=0;n<t;n++)this.decipher(e.subarray(2*n))};var l=8,u=32;function c(e,t,n){var r=new o,i=new Uint32Array(l),s,u=new Uint8Array([79,120,121,99,104,114,111,109,97,116,105,99,66,108,111,119,102,105,115,104,83,119,97,116,68,121,110,97,109,105,116,101]);for(r.expandstate(t,64,e,64),s=0;s<64;s++)r.expand0state(t,64),r.expand0state(e,64);for(s=0;s<l;s++)i[s]=a(u,u.byteLength);for(s=0;s<64;s++)r.enc(i,i.byteLength/8);for(s=0;s<l;s++)n[4*s+3]=i[s]>>>24,n[4*s+2]=i[s]>>>16,n[4*s+1]=i[s]>>>8,n[4*s+0]=i[s]}function h(e,t,n,i,o,s,a){var l=new Uint8Array(64),h=new Uint8Array(64),f=new Uint8Array(u),p=new Uint8Array(u),d=new Uint8Array(i+4),m,g,y,v,b,_,w=s;if(a<1)return-1;if(0===t||0===i||0===s||s>f.byteLength*f.byteLength||i>1<<20)return-1;for(v=Math.floor((s+f.byteLength-1)/f.byteLength),y=Math.floor((s+v-1)/v),m=0;m<i;m++)d[m]=n[m];for(r(l,e,t),_=1;s>0;_++){for(d[i+0]=_>>>24,d[i+1]=_>>>16,d[i+2]=_>>>8,d[i+3]=_,r(h,d,i+4),c(l,h,p),m=f.byteLength;m--;)f[m]=p[m];for(m=1;m<a;m++)for(r(h,p,p.byteLength),c(l,h,p),g=0;g<f.byteLength;g++)f[g]^=p[g];for(y=Math.min(y,s),m=0;m<y&&(b=m*v+(_-1),!(b>=w));m++)o[b]=f[m];s-=m}return 0}e.exports={BLOCKS:l,HASHSIZE:u,hash:c,pbkdf:h}},function(e,t,n){e.exports={read:f,write:p};var r=n(25),i=n(29).Buffer,o=n(93),s=n(42),a=n(41),l=n(46),u=n(238),c=/^([a-z0-9-]+)[ \t]+([a-zA-Z0-9+\/]+[=]*)([ \t]+([^ \t][^\n]*[\n]*)?)?$/,h=/^([a-z0-9-]+)[ \t\n]+([a-zA-Z0-9+\/][a-zA-Z0-9+\/ \t\n=]*)([^a-zA-Z0-9+\/ \t\n=].*)?$/;function f(e,t){"string"!=typeof e&&(r.buffer(e,"buf"),e=e.toString("ascii"));var n=e.trim().replace(/[\\\r]/g,""),s=n.match(c);s||(s=n.match(h)),r.ok(s,"key must match regex");var a=o.algToKeyType(s[1]),l=i.from(s[2],"base64"),u,f={};if(s[4])try{u=o.read(l)}catch(e){s=n.match(h),r.ok(s,"key must match regex"),l=i.from(s[2],"base64"),u=o.readInternal(f,"public",l)}else u=o.readInternal(f,"public",l);if(r.strictEqual(a,u.type),s[4]&&s[4].length>0)u.comment=s[4];else if(f.consumed){var p=s[2]+(s[3]?s[3]:""),d=4*Math.ceil(f.consumed/3);p=p.slice(0,d-2).replace(/[^a-zA-Z0-9+\/=]/g,"")+p.slice(d-2);var m=f.consumed%3;for(m>0&&"="!==p.slice(d-1,d)&&d--;"="===p.slice(d,d+1);)d++;var g=p.slice(d);g=g.replace(/[\r\n]/g," ").replace(/^\s+/,""),g.match(/^[a-zA-Z0-9]/)&&(u.comment=g)}return u}function p(e,t){if(r.object(e),!a.isKey(e))throw new Error("Must be a public key");var n=[],s=o.keyTypeToAlg(e);n.push(s);var l=o.write(e);return n.push(l.toString("base64")),e.comment&&n.push(e.comment),i.from(n.join(" "))}},function(e,t,n){e.exports={read:l,write:c};var r=n(25),i=n(29).Buffer,o=n(93),s=n(41),a=n(76);function l(e,t){for(var n=e.toString("ascii").split(/[\r\n]+/),s=!1,a,l=0;l<n.length;)if(a=u(n[l++]),a&&"putty-user-key-file-2"===a[0].toLowerCase()){s=!0;break}if(!s)throw new Error("No PuTTY format first line found");var c=a[1];a=u(n[l++]),r.equal(a[0].toLowerCase(),"encryption"),a=u(n[l++]),r.equal(a[0].toLowerCase(),"comment");var h=a[1];a=u(n[l++]),r.equal(a[0].toLowerCase(),"public-lines");var f=parseInt(a[1],10);if(!isFinite(f)||f<0||f>n.length)throw new Error("Invalid public-lines count");var p=i.from(n.slice(l,l+f).join(""),"base64"),d=o.algToKeyType(c),m=o.read(p);if(m.type!==d)throw new Error("Outer key algorithm mismatch");return m.comment=h,m}function u(e){var t=e.indexOf(":");if(-1===t)return null;var n=e.slice(0,t);for(++t;" "===e[t];)++t;var r=e.slice(t);return[n,r]}function c(e,t){if(r.object(e),!s.isKey(e))throw new Error("Must be a public key");var n=o.keyTypeToAlg(e),a=o.write(e),l=e.comment||"",u=a.toString("base64"),c=h(u,64);return c.unshift("Public-Lines: "+c.length),c.unshift("Comment: "+l),c.unshift("Encryption: none"),c.unshift("PuTTY-User-Key-File-2: "+n),i.from(c.join("\n")+"\n")}function h(e,t){for(var n=[],r=0;r<e.length;)n.push(e.slice(r,r+64)),r+=64;return n}},function(e,t,n){e.exports={read:w,verify:g,sign:D,signAsync:M,write:F};var r=n(25),i=n(84),o=n(29).Buffer,s=n(48),a=n(42),l=n(41),u=n(46),c=n(92),h=n(178),f=n(83),p=n(177),d=n(176);function m(e,t){return r.strictEqual(e.peek(),i.Ber.Integer,t+" is not an Integer"),a.mpNormalize(e.readString(i.Ber.Integer,!0))}function g(e,t){var n=e.signatures.x509;r.object(n,"x509 signature");var o=n.algo.split("-");if(o[0]!==t.type)return!1;var s=n.cache;if(void 0===s){var a=new i.BerWriter;L(e,a),s=a.buffer}var l=t.createVerify(o[1]);return l.write(s),l.verify(n.signature)}function y(e){return i.Ber.Context|i.Ber.Constructor|e}function v(e){return i.Ber.Context|e}var b={"rsa-md5":"1.2.840.113549.1.1.4","rsa-sha1":"1.2.840.113549.1.1.5","rsa-sha256":"1.2.840.113549.1.1.11","rsa-sha384":"1.2.840.113549.1.1.12","rsa-sha512":"1.2.840.113549.1.1.13","dsa-sha1":"1.2.840.10040.4.3","dsa-sha256":"2.16.840.1.101.3.4.3.2","ecdsa-sha1":"1.2.840.10045.4.1","ecdsa-sha256":"1.2.840.10045.4.3.2","ecdsa-sha384":"1.2.840.10045.4.3.3","ecdsa-sha512":"1.2.840.10045.4.3.4","ed25519-sha512":"1.3.101.112"};Object.keys(b).forEach(function(e){b[b[e]]=e}),b["1.3.14.3.2.3"]="rsa-md5",b["1.3.14.3.2.29"]="rsa-sha1";var _={issuerKeyId:"2.5.29.35",altName:"2.5.29.17",basicConstraints:"2.5.29.19",keyUsage:"2.5.29.15",extKeyUsage:"2.5.29.37"};function w(e,t){"string"==typeof e&&(e=o.from(e,"binary")),r.buffer(e,"buf");var n=new i.BerReader(e);if(n.readSequence(),Math.abs(n.length-n.remain)>1)throw new Error("DER sequence does not contain whole byte stream");var s=n.offset;n.readSequence();var a=n.offset+n.length,l=a;if(n.peek()===y(0)){n.readSequence(y(0));var u=n.readInt();r.ok(u<=3,"only x.509 versions up to v3 supported")}var c={signatures:{}},g=c.signatures.x509={};g.extras={},c.serial=m(n,"serial"),n.readSequence();var v=n.offset+n.length,_=n.readOID(),w=b[_];if(void 0===w)throw new Error("unknown signature algorithm "+_);if(n._offset=v,c.issuer=h.parseAsn1(n),n.readSequence(),c.validFrom=k(n),c.validUntil=k(n),c.subjects=[h.parseAsn1(n)],n.readSequence(),v=n.offset+n.length,c.subjectKey=d.readPkcs8(void 0,"public",n),n._offset=v,n.peek()===y(1)&&(n.readSequence(y(1)),g.extras.issuerUniqueID=e.slice(n.offset,n.offset+n.length),n._offset+=n.length),n.peek()===y(2)&&(n.readSequence(y(2)),g.extras.subjectUniqueID=e.slice(n.offset,n.offset+n.length),n._offset+=n.length),n.peek()===y(3)){n.readSequence(y(3));var E=n.offset+n.length;for(n.readSequence();n.offset<E;)T(c,e,n);r.strictEqual(n.offset,E)}r.strictEqual(n.offset,a),n.readSequence(),v=n.offset+n.length;var S=n.readOID(),x=b[S];if(void 0===x)throw new Error("unknown signature algorithm "+S);n._offset=v;var C=n.readString(i.Ber.BitString,!0);0===C[0]&&(C=C.slice(1));var A=x.split("-");return g.signature=f.parse(C,A[0],"asn1"),g.signature.hashAlgorithm=A[1],g.algo=x,g.cache=e.slice(s,l),new p(c)}function k(e){if(e.peek()===i.Ber.UTCTime)return j(e.readString(i.Ber.UTCTime));if(e.peek()===i.Ber.GeneralizedTime)return B(e.readString(i.Ber.GeneralizedTime));throw new Error("Unsupported date format")}function E(e,t){t.getUTCFullYear()>=2050||t.getUTCFullYear()<1950?e.writeString(N(t),i.Ber.GeneralizedTime):e.writeString(P(t),i.Ber.UTCTime)}var S={OtherName:y(0),RFC822Name:v(1),DNSName:v(2),X400Address:y(3),DirectoryName:y(4),EDIPartyName:y(5),URI:v(6),IPAddress:v(7),OID:v(8)},x={serverAuth:"1.3.6.1.5.5.7.3.1",clientAuth:"1.3.6.1.5.5.7.3.2",codeSigning:"1.3.6.1.5.5.7.3.3",joyentDocker:"1.3.6.1.4.1.38678.1.4.1",joyentCmon:"1.3.6.1.4.1.38678.1.4.2"},C={};Object.keys(x).forEach(function(e){C[x[e]]=e});var A=["signature","identity","keyEncryption","encryption","keyAgreement","ca","crl"];function T(e,t,n){n.readSequence();var r=n.offset+n.length,o=n.readOID(),s,a=e.signatures.x509,l;switch(a.extras.exts||(a.extras.exts=[]),n.peek()===i.Ber.Boolean&&(l=n.readBoolean()),o){case _.basicConstraints:n.readSequence(i.Ber.OctetString),n.readSequence();var u=n.offset+n.length,c=!1;n.peek()===i.Ber.Boolean&&(c=n.readBoolean()),void 0===e.purposes&&(e.purposes=[]),!0===c&&e.purposes.push("ca");var f={oid:o,critical:l};n.offset<u&&n.peek()===i.Ber.Integer&&(f.pathLen=n.readInt()),a.extras.exts.push(f);break;case _.extKeyUsage:n.readSequence(i.Ber.OctetString),n.readSequence(),void 0===e.purposes&&(e.purposes=[]);for(var p=n.offset+n.length;n.offset<p;){var d=n.readOID();e.purposes.push(C[d]||d)}-1!==e.purposes.indexOf("serverAuth")&&-1===e.purposes.indexOf("clientAuth")?e.subjects.forEach(function(e){"host"!==e.type&&(e.type="host",e.hostname=e.uid||e.email||e.components[0].value)}):-1!==e.purposes.indexOf("clientAuth")&&-1===e.purposes.indexOf("serverAuth")&&e.subjects.forEach(function(e){"user"!==e.type&&(e.type="user",e.uid=e.hostname||e.email||e.components[0].value)}),a.extras.exts.push({oid:o,critical:l});break;case _.keyUsage:n.readSequence(i.Ber.OctetString);var m=n.readString(i.Ber.BitString,!0),g=U(m,A);g.forEach(function(t){void 0===e.purposes&&(e.purposes=[]),-1===e.purposes.indexOf(t)&&e.purposes.push(t)}),a.extras.exts.push({oid:o,critical:l,bits:m});break;case _.altName:n.readSequence(i.Ber.OctetString),n.readSequence();for(var y=n.offset+n.length;n.offset<y;)switch(n.peek()){case S.OtherName:case S.EDIPartyName:n.readSequence(),n._offset+=n.length;break;case S.OID:n.readOID(S.OID);break;case S.RFC822Name:var v=n.readString(S.RFC822Name);s=h.forEmail(v),e.subjects[0].equals(s)||e.subjects.push(s);break;case S.DirectoryName:n.readSequence(S.DirectoryName),s=h.parseAsn1(n),e.subjects[0].equals(s)||e.subjects.push(s);break;case S.DNSName:var b=n.readString(S.DNSName);s=h.forHost(b),e.subjects[0].equals(s)||e.subjects.push(s);break;default:n.readString(n.peek())}a.extras.exts.push({oid:o,critical:l});break;default:a.extras.exts.push({oid:o,critical:l,data:n.readString(i.Ber.OctetString,!0)})}n._offset=r}var I=/^([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})?Z$/;function j(e){var t=e.match(I);r.ok(t,"timestamps must be in UTC");var n=new Date,i=n.getUTCFullYear(),o=100*Math.floor(i/100),s=parseInt(t[1],10);return s+=i%100<50&&s>=60?o-1:o,n.setUTCFullYear(s,parseInt(t[2],10)-1,parseInt(t[3],10)),n.setUTCHours(parseInt(t[4],10),parseInt(t[5],10)),t[6]&&t[6].length>0&&n.setUTCSeconds(parseInt(t[6],10)),n}var R=/^([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})?Z$/;function B(e){var t=e.match(R);r.ok(t);var n=new Date;return n.setUTCFullYear(parseInt(t[1],10),parseInt(t[2],10)-1,parseInt(t[3],10)),n.setUTCHours(parseInt(t[4],10),parseInt(t[5],10)),t[6]&&t[6].length>0&&n.setUTCSeconds(parseInt(t[6],10)),n}function O(e,t){void 0===t&&(t=2);for(var n=""+e;n.length<t;)n="0"+n;return n}function P(e){var t="";return t+=O(e.getUTCFullYear()%100),t+=O(e.getUTCMonth()+1),t+=O(e.getUTCDate()),t+=O(e.getUTCHours()),t+=O(e.getUTCMinutes()),t+=O(e.getUTCSeconds()),t+="Z",t}function N(e){var t="";return t+=O(e.getUTCFullYear(),4),t+=O(e.getUTCMonth()+1),t+=O(e.getUTCDate()),t+=O(e.getUTCHours()),t+=O(e.getUTCMinutes()),t+=O(e.getUTCSeconds()),t+="Z",t}function D(e,t){void 0===e.signatures.x509&&(e.signatures.x509={});var n=e.signatures.x509;if(n.algo=t.type+"-"+t.defaultHashAlgorithm(),void 0===b[n.algo])return!1;var r=new i.BerWriter;L(e,r);var o=r.buffer;n.cache=o;var s=t.createSign();return s.write(o),e.signatures.x509.signature=s.sign(),!0}function M(e,t,n){void 0===e.signatures.x509&&(e.signatures.x509={});var r=e.signatures.x509,o=new i.BerWriter;L(e,o);var s=o.buffer;r.cache=s,t(s,function(e,t){e?n(e):(r.algo=t.type+"-"+t.hashAlgorithm,void 0!==b[r.algo]?(r.signature=t,n()):n(new Error('Invalid signing algorithm "'+r.algo+'"')))})}function F(e,t){var n=e.signatures.x509;r.object(n,"x509 signature");var s=new i.BerWriter;s.startSequence(),n.cache?(s._ensure(n.cache.length),n.cache.copy(s._buf,s._offset),s._offset+=n.cache.length):L(e,s),s.startSequence(),s.writeOID(b[n.algo]),n.algo.match(/^rsa-/)&&s.writeNull(),s.endSequence();var a=n.signature.toBuffer("asn1"),l=o.alloc(a.length+1);return l[0]=0,a.copy(l,1),s.writeBuffer(l,i.Ber.BitString),s.endSequence(),s.buffer}function L(e,t){var n=e.signatures.x509;r.object(n,"x509 signature"),t.startSequence(),t.startSequence(y(0)),t.writeInt(2),t.endSequence(),t.writeBuffer(a.mpNormalize(e.serial),i.Ber.Integer),t.startSequence(),t.writeOID(b[n.algo]),n.algo.match(/^rsa-/)&&t.writeNull(),t.endSequence(),e.issuer.toAsn1(t),t.startSequence(),E(t,e.validFrom),E(t,e.validUntil),t.endSequence();var o=e.subjects[0],s=e.subjects.slice(1);if(o.toAsn1(t),d.writePkcs8(t,e.subjectKey),n.extras&&n.extras.issuerUniqueID&&t.writeBuffer(n.extras.issuerUniqueID,y(1)),n.extras&&n.extras.subjectUniqueID&&t.writeBuffer(n.extras.subjectUniqueID,y(2)),s.length>0||"host"===o.type||void 0!==e.purposes&&e.purposes.length>0||n.extras&&n.extras.exts){t.startSequence(y(3)),t.startSequence();var l=[];void 0!==e.purposes&&e.purposes.length>0&&(l.push({oid:_.basicConstraints,critical:!0}),l.push({oid:_.keyUsage,critical:!0}),l.push({oid:_.extKeyUsage,critical:!0})),l.push({oid:_.altName}),n.extras&&n.extras.exts&&(l=n.extras.exts);for(var u=0;u<l.length;++u){if(t.startSequence(),t.writeOID(l[u].oid),void 0!==l[u].critical&&t.writeBoolean(l[u].critical),l[u].oid===_.altName){t.startSequence(i.Ber.OctetString),t.startSequence(),"host"===o.type&&t.writeString(o.hostname,v(2));for(var c=0;c<s.length;++c)"host"===s[c].type?t.writeString(s[c].hostname,S.DNSName):"email"===s[c].type?t.writeString(s[c].email,S.RFC822Name):(t.startSequence(S.DirectoryName),s[c].toAsn1(t),t.endSequence());t.endSequence(),t.endSequence()}else if(l[u].oid===_.basicConstraints){t.startSequence(i.Ber.OctetString),t.startSequence();var h=-1!==e.purposes.indexOf("ca"),f=l[u].pathLen;t.writeBoolean(h),void 0!==f&&t.writeInt(f),t.endSequence(),t.endSequence()}else if(l[u].oid===_.extKeyUsage)t.startSequence(i.Ber.OctetString),t.startSequence(),e.purposes.forEach(function(e){if("ca"!==e&&-1===A.indexOf(e)){var n=e;void 0!==x[e]&&(n=x[e]),t.writeOID(n)}}),t.endSequence(),t.endSequence();else if(l[u].oid===_.keyUsage){if(t.startSequence(i.Ber.OctetString),void 0!==l[u].bits)t.writeBuffer(l[u].bits,i.Ber.BitString);else{var p=q(e.purposes,A);t.writeBuffer(p,i.Ber.BitString)}t.endSequence()}else t.writeBuffer(l[u].data,i.Ber.OctetString);t.endSequence()}t.endSequence(),t.endSequence()}t.endSequence()}function U(e,t){for(var n=8*(e.length-1)-e[0],r={},i=0;i<n;++i){var o=1+Math.floor(i/8),s=7-i%8,a=1<<s,l=0!=(e[o]&a),u=t[i];l&&"string"==typeof u&&(r[u]=!0)}return Object.keys(r)}function q(e,t){var n=t.length,r=Math.ceil(n/8),i=8*r-n,s=o.alloc(1+r);s[0]=i;for(var a=0;a<n;++a){var l=1+Math.floor(a/8),u=7-a%8,c=1<<u,h=t[a];if(void 0!==h){var f=-1!==e.indexOf(h);f&&(s[l]|=c)}}return s}},function(e,t,n){var r=n(62);function i(e){return e instanceof r.Stream}function o(e){return i(e)&&"function"==typeof e._read&&"object"==typeof e._readableState}function s(e){return i(e)&&"function"==typeof e._write&&"object"==typeof e._writableState}function a(e){return o(e)&&s(e)}e.exports=i,e.exports.isReadable=o,e.exports.isWritable=s,e.exports.isDuplex=a},function(e,t,n){"use strict";var r=n(1674),i=n(1675),o=n(623);e.exports={formats:o,parse:i,stringify:r}},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,i=function(){for(var e=[],t=0;t<256;++t)e.push("%"+((t<16?"0":"")+t.toString(16)).toUpperCase());return e}(),o=function e(t){for(var n;t.length;){var r=t.pop();if(n=r.obj[r.prop],Array.isArray(n)){for(var i=[],o=0;o<n.length;++o)void 0!==n[o]&&i.push(n[o]);r.obj[r.prop]=i}}return n},s=function e(t,n){for(var r=n&&n.plainObjects?Object.create(null):{},i=0;i<t.length;++i)void 0!==t[i]&&(r[i]=t[i]);return r},a=function e(t,n,i){if(!n)return t;if("object"!=typeof n){if(Array.isArray(t))t.push(n);else{if("object"!=typeof t)return[t,n];(i.plainObjects||i.allowPrototypes||!r.call(Object.prototype,n))&&(t[n]=!0)}return t}if("object"!=typeof t)return[t].concat(n);var o=t;return Array.isArray(t)&&!Array.isArray(n)&&(o=s(t,i)),Array.isArray(t)&&Array.isArray(n)?(n.forEach(function(n,o){r.call(t,o)?t[o]&&"object"==typeof t[o]?t[o]=e(t[o],n,i):t.push(n):t[o]=n}),t):Object.keys(n).reduce(function(t,o){var s=n[o];return r.call(t,o)?t[o]=e(t[o],s,i):t[o]=s,t},o)},l=function e(t,n){return Object.keys(n).reduce(function(e,t){return e[t]=n[t],e},t)},u=function(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(t){return e}},c=function e(t){if(0===t.length)return t;for(var n="string"==typeof t?t:String(t),r="",o=0;o<n.length;++o){var s=n.charCodeAt(o);45===s||46===s||95===s||126===s||s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122?r+=n.charAt(o):s<128?r+=i[s]:s<2048?r+=i[192|s>>6]+i[128|63&s]:s<55296||s>=57344?r+=i[224|s>>12]+i[128|s>>6&63]+i[128|63&s]:(o+=1,s=65536+((1023&s)<<10|1023&n.charCodeAt(o)),r+=i[240|s>>18]+i[128|s>>12&63]+i[128|s>>6&63]+i[128|63&s])}return r},h=function e(t){for(var n=[{obj:{o:t},prop:"o"}],r=[],i=0;i<n.length;++i)for(var s=n[i],a=s.obj[s.prop],l=Object.keys(a),u=0;u<l.length;++u){var c=l[u],h=a[c];"object"==typeof h&&null!==h&&-1===r.indexOf(h)&&(n.push({obj:a,prop:c}),r.push(h))}return o(n)},f=function e(t){return"[object RegExp]"===Object.prototype.toString.call(t)},p=function e(t){return null!==t&&void 0!==t&&!!(t.constructor&&t.constructor.isBuffer&&t.constructor.isBuffer(t))};e.exports={arrayToObject:s,assign:l,compact:h,decode:u,encode:c,isBuffer:p,isRegExp:f,merge:a}},function(e,t,n){"use strict";var r=String.prototype.replace,i=/%20/g;e.exports={default:"RFC3986",formatters:{RFC1738:function(e){return r.call(e,i,"+")},RFC3986:function(e){return e}},RFC1738:"RFC1738",RFC3986:"RFC3986"}},function(e,t,n){"use strict";var r=n(143);function i(e){r.copy(e,this)}e.exports=i},function(e,t,n){"use strict";e.exports=function(e,t){t||(t={}),"function"==typeof t&&(t={cmp:t});var n="boolean"==typeof t.cycles&&t.cycles,r=t.cmp&&(i=t.cmp,function(e){return function(t,n){var r={key:t,value:e[t]},o={key:n,value:e[n]};return i(r,o)}}),i,o=[];return function e(t){if(t&&t.toJSON&&"function"==typeof t.toJSON&&(t=t.toJSON()),void 0!==t){if("number"==typeof t)return isFinite(t)?""+t:"null";if("object"!=typeof t)return JSON.stringify(t);var i,s;if(Array.isArray(t)){for(s="[",i=0;i<t.length;i++)i&&(s+=","),s+=e(t[i])||"null";return s+"]"}if(null===t)return"null";if(-1!==o.indexOf(t)){if(n)return JSON.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}var a=o.push(t)-1,l=Object.keys(t).sort(r&&r(t));for(s="",i=0;i<l.length;i++){var u=l[i],c=e(t[u]);c&&(s&&(s+=","),s+=JSON.stringify(u)+":"+c)}return o.splice(a,1),"{"+s+"}"}}(e)}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i="",o=!0===t.schema.$async,s=t.util.schemaHasRulesExcept(t.schema,t.RULES.all,"$ref"),a=t.self._getId(t.schema);if(t.opts.strictKeywords){var l=t.util.schemaUnknownRules(t.schema,t.RULES.keywords);if(l){var u="unknown keyword: "+l;if("log"!==t.opts.strictKeywords)throw new Error(u);t.logger.warn(u)}}if(t.isTop&&(i+=" var validate = ",o&&(t.async=!0,i+="async "),i+="function(data, dataPath, parentData, parentDataProperty, rootData) { 'use strict'; ",a&&(t.opts.sourceCode||t.opts.processCode)&&(i+=" /*# sourceURL="+a+" */ ")),"boolean"==typeof t.schema||!s&&!t.schema.$ref){var n="false schema",c=t.level,h=t.dataLevel,f=t.schema[n],p=t.schemaPath+t.util.getProperty(n),d=t.errSchemaPath+"/"+n,m=!t.opts.allErrors,g,y="data"+(h||""),v="valid"+c;if(!1===t.schema){t.isTop?m=!0:i+=" var "+v+" = false; ";var b=b||[];b.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(g||"false schema")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(d)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: 'boolean schema is false' "),t.opts.verbose&&(i+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+y+" "),i+=" } "):i+=" {} ";var _=i;i=b.pop(),!t.compositeRule&&m?t.async?i+=" throw new ValidationError(["+_+"]); ":i+=" validate.errors = ["+_+"]; return false; ":i+=" var err = "+_+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else t.isTop?i+=o?" return data; ":" validate.errors = null; return true; ":i+=" var "+v+" = true; ";return t.isTop&&(i+=" }; return validate; "),i}if(t.isTop){var w=t.isTop,c=t.level=0,h=t.dataLevel=0,y="data";if(t.rootId=t.resolve.fullPath(t.self._getId(t.root.schema)),t.baseId=t.baseId||t.rootId,delete t.isTop,t.dataPathArr=[void 0],void 0!==t.schema.default&&t.opts.useDefaults&&t.opts.strictDefaults){var k="default is ignored in the schema root";if("log"!==t.opts.strictDefaults)throw new Error(k);t.logger.warn(k)}i+=" var vErrors = null; ",i+=" var errors = 0; ",i+=" if (rootData === undefined) rootData = data; "}else{var c=t.level,h=t.dataLevel,y="data"+(h||"");if(a&&(t.baseId=t.resolve.url(t.baseId,a)),o&&!t.async)throw new Error("async schema in sync schema");i+=" var errs_"+c+" = errors;"}var v="valid"+c,m=!t.opts.allErrors,E="",S="",g,x=t.schema.type,C=Array.isArray(x);if(x&&t.opts.nullable&&!0===t.schema.nullable&&(C?-1==x.indexOf("null")&&(x=x.concat("null")):"null"!=x&&(x=[x,"null"],C=!0)),C&&1==x.length&&(x=x[0],C=!1),t.schema.$ref&&s){if("fail"==t.opts.extendRefs)throw new Error('$ref: validation keywords used in schema at path "'+t.errSchemaPath+'" (see option extendRefs)');!0!==t.opts.extendRefs&&(s=!1,t.logger.warn('$ref: keywords ignored in schema at path "'+t.errSchemaPath+'"'))}if(t.schema.$comment&&t.opts.$comment&&(i+=" "+t.RULES.all.$comment.code(t,"$comment")),x){if(t.opts.coerceTypes)var A=t.util.coerceToTypes(t.opts.coerceTypes,x);var T=t.RULES.types[x];if(A||C||!0===T||T&&!ne(T)){var p=t.schemaPath+".type",d=t.errSchemaPath+"/type",p=t.schemaPath+".type",d=t.errSchemaPath+"/type",I=C?"checkDataTypes":"checkDataType";if(i+=" if ("+t.util[I](x,y,!0)+") { ",A){var j="dataType"+c,R="coerced"+c;i+=" var "+j+" = typeof "+y+"; ","array"==t.opts.coerceTypes&&(i+=" if ("+j+" == 'object' && Array.isArray("+y+")) "+j+" = 'array'; "),i+=" var "+R+" = undefined; ";var B="",O=A;if(O)for(var P,N=-1,D=O.length-1;N<D;)P=O[N+=1],N&&(i+=" if ("+R+" === undefined) { ",B+="}"),"array"==t.opts.coerceTypes&&"array"!=P&&(i+=" if ("+j+" == 'array' && "+y+".length == 1) { "+R+" = "+y+" = "+y+"[0]; "+j+" = typeof "+y+"; } "),"string"==P?i+=" if ("+j+" == 'number' || "+j+" == 'boolean') "+R+" = '' + "+y+"; else if ("+y+" === null) "+R+" = ''; ":"number"==P||"integer"==P?(i+=" if ("+j+" == 'boolean' || "+y+" === null || ("+j+" == 'string' && "+y+" && "+y+" == +"+y+" ","integer"==P&&(i+=" && !("+y+" % 1)"),i+=")) "+R+" = +"+y+"; "):"boolean"==P?i+=" if ("+y+" === 'false' || "+y+" === 0 || "+y+" === null) "+R+" = false; else if ("+y+" === 'true' || "+y+" === 1) "+R+" = true; ":"null"==P?i+=" if ("+y+" === '' || "+y+" === 0 || "+y+" === false) "+R+" = null; ":"array"==t.opts.coerceTypes&&"array"==P&&(i+=" if ("+j+" == 'string' || "+j+" == 'number' || "+j+" == 'boolean' || "+y+" == null) "+R+" = ["+y+"]; ");i+=" "+B+" if ("+R+" === undefined) { ";var b=b||[];b.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(g||"type")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(d)+" , params: { type: '",i+=C?""+x.join(","):""+x,i+="' } ",!1!==t.opts.messages&&(i+=" , message: 'should be ",i+=C?""+x.join(","):""+x,i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+y+" "),i+=" } "):i+=" {} ";var _=i;i=b.pop(),!t.compositeRule&&m?t.async?i+=" throw new ValidationError(["+_+"]); ":i+=" validate.errors = ["+_+"]; return false; ":i+=" var err = "+_+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else { ";var M=h?"data"+(h-1||""):"parentData",F=h?t.dataPathArr[h]:"parentDataProperty";i+=" "+y+" = "+R+"; ",h||(i+="if ("+M+" !== undefined)"),i+=" "+M+"["+F+"] = "+R+"; } "}else{var b=b||[];b.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(g||"type")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(d)+" , params: { type: '",i+=C?""+x.join(","):""+x,i+="' } ",!1!==t.opts.messages&&(i+=" , message: 'should be ",i+=C?""+x.join(","):""+x,i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+y+" "),i+=" } "):i+=" {} ";var _=i;i=b.pop(),!t.compositeRule&&m?t.async?i+=" throw new ValidationError(["+_+"]); ":i+=" validate.errors = ["+_+"]; return false; ":i+=" var err = "+_+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}i+=" } "}}if(t.schema.$ref&&!s)i+=" "+t.RULES.all.$ref.code(t,"$ref")+" ",m&&(i+=" } if (errors === ",i+=w?"0":"errs_"+c,i+=") { ",S+="}");else{var L=t.RULES;if(L)for(var T,U=-1,q=L.length-1;U<q;)if(T=L[U+=1],ne(T)){if(T.type&&(i+=" if ("+t.util.checkDataType(T.type,y)+") { "),t.opts.useDefaults)if("object"==T.type&&t.schema.properties){var f=t.schema.properties,z=Object.keys(f),K=z;if(K)for(var H,V=-1,$=K.length-1;V<$;){H=K[V+=1];var W=f[H];if(void 0!==W.default){var G=y+t.util.getProperty(H);if(t.compositeRule){if(t.opts.strictDefaults){var k="default is ignored for: "+G;if("log"!==t.opts.strictDefaults)throw new Error(k);t.logger.warn(k)}}else i+=" if ("+G+" === undefined ","empty"==t.opts.useDefaults&&(i+=" || "+G+" === null || "+G+" === '' "),i+=" ) "+G+" = ","shared"==t.opts.useDefaults?i+=" "+t.useDefault(W.default)+" ":i+=" "+JSON.stringify(W.default)+" ",i+="; "}}}else if("array"==T.type&&Array.isArray(t.schema.items)){var Y=t.schema.items;if(Y)for(var W,N=-1,Z=Y.length-1;N<Z;)if(W=Y[N+=1],void 0!==W.default){var G=y+"["+N+"]";if(t.compositeRule){if(t.opts.strictDefaults){var k="default is ignored for: "+G;if("log"!==t.opts.strictDefaults)throw new Error(k);t.logger.warn(k)}}else i+=" if ("+G+" === undefined ","empty"==t.opts.useDefaults&&(i+=" || "+G+" === null || "+G+" === '' "),i+=" ) "+G+" = ","shared"==t.opts.useDefaults?i+=" "+t.useDefault(W.default)+" ":i+=" "+JSON.stringify(W.default)+" ",i+="; "}}var J=T.rules;if(J)for(var Q,X=-1,ee=J.length-1;X<ee;)if(Q=J[X+=1],re(Q)){var te=Q.code(t,Q.keyword,T.type);te&&(i+=" "+te+" ",m&&(E+="}"))}if(m&&(i+=" "+E+" ",E=""),T.type&&(i+=" } ",x&&x===T.type&&!A)){i+=" else { ";var p=t.schemaPath+".type",d=t.errSchemaPath+"/type",b=b||[];b.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(g||"type")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(d)+" , params: { type: '",i+=C?""+x.join(","):""+x,i+="' } ",!1!==t.opts.messages&&(i+=" , message: 'should be ",i+=C?""+x.join(","):""+x,i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+p+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+y+" "),i+=" } "):i+=" {} ";var _=i;i=b.pop(),!t.compositeRule&&m?t.async?i+=" throw new ValidationError(["+_+"]); ":i+=" validate.errors = ["+_+"]; return false; ":i+=" var err = "+_+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } "}m&&(i+=" if (errors === ",i+=w?"0":"errs_"+c,i+=") { ",S+="}")}}function ne(e){for(var t=e.rules,n=0;n<t.length;n++)if(re(t[n]))return!0}function re(e){return void 0!==t.schema[e.keyword]||e.implements&&ie(e)}function ie(e){for(var n=e.implements,r=0;r<n.length;r++)if(void 0!==t.schema[n[r]])return!0}return m&&(i+=" "+S+" "),w?(o?(i+=" if (errors === 0) return data; ",i+=" else throw new ValidationError(vErrors); "):(i+=" validate.errors = vErrors; ",i+=" return errors === 0; "),i+=" }; return validate;"):i+=" var "+v+" = errors === errs_"+c+";",i=t.util.cleanUpCode(i),w&&(i=t.util.finalCleanUpCode(i,o)),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h,f="data"+(s||""),p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="maximum"==n,g=m?"exclusiveMaximum":"exclusiveMinimum",y=t.schema[g],v=t.opts.$data&&y&&y.$data,b=m?"<":">",_=m?">":"<",h=void 0;if(v){var w=t.util.getData(y.$data,s,t.dataPathArr),k="exclusive"+o,E="exclType"+o,S="exclIsNumber"+o,x="op"+o,C="' + "+x+" + '";i+=" var schemaExcl"+o+" = "+w+"; ",w="schemaExcl"+o,i+=" var "+k+"; var "+E+" = typeof "+w+"; if ("+E+" != 'boolean' && "+E+" != 'undefined' && "+E+" != 'number') { ";var h=g,A=A||[];A.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"_exclusiveLimit")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: '"+g+" should be boolean' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var T=i;i=A.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+T+"]); ":i+=" validate.errors = ["+T+"]; return false; ":i+=" var err = "+T+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),i+=" "+E+" == 'number' ? ( ("+k+" = "+d+" === undefined || "+w+" "+b+"= "+d+") ? "+f+" "+_+"= "+w+" : "+f+" "+_+" "+d+" ) : ( ("+k+" = "+w+" === true) ? "+f+" "+_+"= "+d+" : "+f+" "+_+" "+d+" ) || "+f+" !== "+f+") { var op"+o+" = "+k+" ? '"+b+"' : '"+b+"='; ",void 0===a&&(h=g,u=t.errSchemaPath+"/"+g,d=w,p=v)}else{var S="number"==typeof y,C=b;if(S&&p){var x="'"+C+"'";i+=" if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),i+=" ( "+d+" === undefined || "+y+" "+b+"= "+d+" ? "+f+" "+_+"= "+y+" : "+f+" "+_+" "+d+" ) || "+f+" !== "+f+") { "}else{S&&void 0===a?(k=!0,h=g,u=t.errSchemaPath+"/"+g,d=y,_+="="):(S&&(d=Math[m?"min":"max"](y,a)),y===(!S||d)?(k=!0,h=g,u=t.errSchemaPath+"/"+g,_+="="):(k=!1,C+="="));var x="'"+C+"'";i+=" if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),i+=" "+f+" "+_+" "+d+" || "+f+" !== "+f+") { "}}h=h||n;var A=A||[];A.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"_limit")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { comparison: "+x+", limit: "+d+", exclusive: "+k+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be "+C+" ",i+=p?"' + "+d:d+"'"),t.opts.verbose&&(i+=" , schema: ",i+=p?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var T=i;return i=A.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+T+"]); ":i+=" validate.errors = ["+T+"]; return false; ":i+=" var err = "+T+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h,f="data"+(s||""),p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="maxItems"==n?">":"<";i+="if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),i+=" "+f+".length "+m+" "+d+") { ";var h=n,g=g||[];g.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"_limitItems")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { limit: "+d+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have ",i+="maxItems"==n?"more":"fewer",i+=" than ",i+=p?"' + "+d+" + '":""+a,i+=" items' "),t.opts.verbose&&(i+=" , schema: ",i+=p?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var y=i;return i=g.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+y+"]); ":i+=" validate.errors = ["+y+"]; return false; ":i+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h,f="data"+(s||""),p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="maxLength"==n?">":"<";i+="if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),!1===t.opts.unicode?i+=" "+f+".length ":i+=" ucs2length("+f+") ",i+=" "+m+" "+d+") { ";var h=n,g=g||[];g.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"_limitLength")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { limit: "+d+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT be ",i+="maxLength"==n?"longer":"shorter",i+=" than ",i+=p?"' + "+d+" + '":""+a,i+=" characters' "),t.opts.verbose&&(i+=" , schema: ",i+=p?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var y=i;return i=g.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+y+"]); ":i+=" validate.errors = ["+y+"]; return false; ":i+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h,f="data"+(s||""),p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="maxProperties"==n?">":"<";i+="if ( ",p&&(i+=" ("+d+" !== undefined && typeof "+d+" != 'number') || "),i+=" Object.keys("+f+").length "+m+" "+d+") { ";var h=n,g=g||[];g.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"_limitProperties")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { limit: "+d+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have ",i+="maxProperties"==n?"more":"fewer",i+=" than ",i+=p?"' + "+d+" + '":""+a,i+=" properties' "),t.opts.verbose&&(i+=" , schema: ",i+=p?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var y=i;return i=g.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+y+"]); ":i+=" validate.errors = ["+y+"]; return false; ":i+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",c&&(i+=" else { "),i}},function(e){e.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"http://json-schema.org/draft-07/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:!0}},function(e,t,n){"use strict";function r(e,t,n){this.name="RequestError",this.message=String(e),this.cause=e,this.error=e,this.options=t,this.response=n,Error.captureStackTrace&&Error.captureStackTrace(this)}function i(e,t,n,r){this.name="StatusCodeError",this.statusCode=e,this.message=e+" - "+(JSON&&JSON.stringify?JSON.stringify(t):t),this.error=t,this.options=n,this.response=r,Error.captureStackTrace&&Error.captureStackTrace(this)}function o(e,t,n){this.name="TransformError",this.message=String(e),this.cause=e,this.error=e,this.options=t,this.response=n,Error.captureStackTrace&&Error.captureStackTrace(this)}r.prototype=Object.create(Error.prototype),r.prototype.constructor=r,i.prototype=Object.create(Error.prototype),i.prototype.constructor=i,o.prototype=Object.create(Error.prototype),o.prototype.constructor=o,e.exports={RequestError:r,StatusCodeError:i,TransformError:o}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2018, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(608);function i(e){return r.get(e)}t.getPublicSuffix=i},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/function r(){}t.Store=r,r.prototype.synchronous=!1,r.prototype.findCookie=function(e,t,n,r){throw new Error("findCookie is not implemented")},r.prototype.findCookies=function(e,t,n){throw new Error("findCookies is not implemented")},r.prototype.putCookie=function(e,t){throw new Error("putCookie is not implemented")},r.prototype.updateCookie=function(e,t,n){throw new Error("updateCookie is not implemented")},r.prototype.removeCookie=function(e,t,n,r){throw new Error("removeCookie is not implemented")},r.prototype.removeCookies=function(e,t,n){throw new Error("removeCookies is not implemented")},r.prototype.removeAllCookies=function(e){throw new Error("removeAllCookies is not implemented")},r.prototype.getAllCookies=function(e){throw new Error("getAllCookies is not implemented (therefore jar cannot be serialized)")}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(633);function i(e){var t=r.getPublicSuffix(e);if(!t)return null;if(t==e)return[e];for(var n=e.slice(0,-(t.length+1)),i=n.split(".").reverse(),o=t,s=[o];i.length;)o=i.shift()+"."+o,s.push(o);return s}t.permuteDomain=i},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/function r(e,t){if(t===e)return!0;var n=e.indexOf(t);if(0===n){if("/"===t.substr(-1))return!0;if("/"===e.substr(t.length,1))return!0}return!1}t.pathMatch=r},function(e,t,n){!function(){function t(){var e=function(t,n,r){if(t=""+t,r||s===n||(e.last=t<e.last?e.last:t,delete(e.$||{})[a]),r=r||e.$||(e.$={}),!t&&Object.keys(r).length)return r;for(var o=0,l=t.length-1,u=t[o],c,h;!(c=r[u])&&o<l;)u+=t[++o];if(c){if(o!=l)return s!==n&&delete c[a],e(t.slice(++o),n,c||(c={}));if(s===n)return s===(h=c[""])?c:h;c[""]=n}else{if(!i(r,function(e,i){var o=0,a="";if((i||"").length)for(;i[o]==t[o];)a+=i[o++];if(a){if(s===n){if(o<=l)return;return(h||(h={}))[i.slice(o)]=e}var u={};return u[i.slice(o)]=e,o=t.slice(o),""===o?u[""]=n:(u[o]={})[""]=n,r[a]=u,delete r[i],!0}})){if(s===n)return;(r[u]||(r[u]={}))[""]=n}if(s===n)return h}};return e}if(t.map=function e(t,n,r,i){i=i||[];var l="function"==typeof t?t.$||{}:t;if(l){var u=(l[a]||o).sort||(l[a]=function e(){return e.sort=Object.keys(l).sort(),e}()).sort;r=!0===r?{branch:!0}:r||{},r.reverse&&(u=u.slice().reverse());for(var c=r.start,h=r.end,f=0,p=u.length;f<p;f++){var d=u[f],m=l[d],g,y,v;if(m&&""!==d&&a!==d&&(y=i.slice(),y.push(d),v=y.join(""),!(s!==c&&v<(c||"").slice(0,v.length)||s!==h&&(h||"￿")<v))){if(s!==(g=m[""])){if(g=n(g,v,d,i),s!==g)return g}else if(r.branch&&(g=n(s,v,d,i),s!==g))return g;if(i=y,g=e(m,n,r,i),s!==g)return g;i.pop()}}}},Object.keys=Object.keys||function(e){return i(e,function(e,t,n){n(t)})},"undefined"!=typeof window){var r=window.Gun;window.Radix=t}else{var r=n(144);try{e.exports=t}catch(e){}}var i=r.obj.map,o={},s,a=String.fromCharCode(24)}()},function(e,t,n){!function(){function t(e){e=e||{},e.log=e.log||console.log,e.file=String(e.file||"radata");var n=(t.has||(t.has={}))[e.file];if(n)return n;function r(e){return encodeURIComponent(e).replace(/\*/g,"%2A")}function i(e){return y!==e&&(!e||"object"!=typeof e)}e.pack=e.pack||.3*(e.memory?1e3*e.memory*1e3:1399e6),e.until=e.until||e.wait||250,e.batch=e.batch||1e4,e.chunk=e.chunk||10485760,e.code=e.code||{},e.code.from=e.code.from||"!";var a=o.obj.map,l=!1;if(!e.store)return e.log("ERROR: Radisk needs `opt.store` interface with `{get: fn, put: fn (, list: fn)}`!");if(!e.store.put)return e.log("ERROR: Radisk needs `store.put` interface with `(file, data, cb)`!");if(!e.store.get)return e.log("ERROR: Radisk needs `store.get` interface with `(file, cb)`!");e.store.list;var u=function(t,n,r){if(t=""+t,n instanceof Function){var o=r||{};if(r=n,n=u.batch(t),y!==n&&(r(y,u.range(n,o),o),i(n)))return;return u.thrash.at&&(n=u.thrash.at(t),y!==n&&(r(y,u.range(n,o),o),i(n)))?void r(y,n,o):u.read(t,r,o)}if(u.batch(t,n),r&&u.batch.acks.push(r),++u.batch.ed>=e.batch)return u.thrash();u.batch.to||(u.batch.to=setTimeout(u.thrash,e.until||1))},c,h,f,p,d;u.batch=s(),u.batch.acks=[],u.batch.ed=0,u.thrash=function(){var t=u.thrash;if(t.ing)return t.more=!0;t.more=!1,t.ing=!0;var n=t.at=u.batch,r=0;clearTimeout(u.batch.to),u.batch=null,u.batch=s(),u.batch.acks=[],u.batch.ed=0,u.save(n,function(i,o){++r>1?e.log("RAD ERR: Radisk has callbacked multiple times, please report this as a BUG at github.com/amark/gun/issues ! "+r):(i&&e.log("err",i),a(n.acks,function(e){e(i,o)}),t.at=null,t.ing=!1,t.more&&t())})},u.save=function(t,n){var r=function e(){};r.find=function(e,t){if(!(t<r.start))return r.start=t,u.list(r.lex),!0},r.lex=function(t){if(t=y===t?y:decodeURIComponent(t),!t||t>r.start)return r.mix(r.file||e.code.from,r.start,r.end=t),!0;r.file=t},r.mix=function(e,i,o){r.start=r.end=r.file=y,u.parse(e,function(a,l){if(a)return n(a);l=l||s(),s.map(t,function(e,t){if(!(t<i))return o&&o<t?r.start=t:void l(t,e)}),u.write(e,l,r.next)})},r.next=function(e,i){return(r.err=e)?n(e):r.start?s.map(t,r.find):void n(e,i)},s.map(t,r.find)},u.write=function(n,i,o,a){a="object"==typeof a?a:{force:a};var l=function e(){};if(l.text="",l.count=0,l.file=n,l.each=function(n,r,u,c){if(y!==n&&l.count++,e.pack<=(n||"").length)return o("Record too big!"),!0;var h=t.encode(c.length)+"#"+t.encode(u)+(y===n?"":":"+t.encode(n))+"\n";if(e.chunk<l.text.length+h.length&&1<l.count&&!a.force)return l.text="",l.limit=Math.ceil(l.count/2),l.count=0,l.sub=s(),s.map(i,l.slice),!0;l.text+=h},l.write=function(){var t=r(n),i;e.store.put(t,l.text,function(e){if(e)return o(e);u.list.add(t,o)})},l.slice=function(e,t){if(!(t<l.file)){if(l.limit<++l.count){var n=l.file;return l.file=t,l.count=0,u.write(n,l.sub,l.next,a),!0}l.sub(t,e)}},l.next=function(e){if(e)return o(e);l.sub=s(),s.map(i,l.slice)||u.write(l.file,l.sub,o,a)},e.jsonify)return u.write.jsonify(l,n,i,o,a);s.map(i,l.each,!0)||l.write()},u.write.jsonify=function(t,n,r,i,o){var a,l;try{a=JSON.stringify(r.$)}catch(e){return i("Record too big!")}e.chunk<a.length&&!o.force&&s.map(r,t.each,!0)||(t.text=a,t.write())},u.range=function(e,t){if(e&&t){if(y===t.start&&y===t.end)return e;if(i(e))return e;var n=s();return s.map(e,function(e,t){n(t,e)},t),n("")}},c={},u.read=function(t,n,r){if(r=r||{},g&&!r.next){var o=g(t);if(i(o))return void n(y,o,r)}r.span=y!==r.start||y!==r.end;var s=function e(){};s.lex=function(e){var i;if(e=y===e?y:decodeURIComponent(e),i=r.next||t||(r.reverse?r.end||"￿":r.start||""),!e||(r.reverse?e<i:e>i))return(r.next||r.reverse)&&(s.file=e),(i=c[s.file])?(i.push({key:t,ack:n,file:s.file,opt:r}),!0):(c[s.file]=[{key:t,ack:n,file:s.file,opt:r}],s.file?(u.parse(s.file,s.it),!0):(s.it(null,y,{}),!0));s.file=e},s.it=function(t,n,r){(s.err=t)&&e.log("err",t),s.info=r,n&&(g=s.disk=n),n=c[s.file],delete c[s.file],a(n,s.ack)},s.ack=function(e){if(e.ack){var t=e.key,n=e.opt,r=s.info,i=s.disk||m,o=u.range(i(t),n),a=i.last;if(n.parsed=(n.parsed||0)+(r.parsed||0),n.chunks=(n.chunks||0)+1,n.some||(n.some=y!==o),y!==o)e.ack(s.err,o,n);else if(!e.file)return void(!n.some&&e.ack(s.err,y,n));if(!n.span){if(/*!last || */a===t)return void(!n.some&&e.ack(s.err,y,n));if(a&&a>t&&0!=a.indexOf(t))return void(!n.some&&e.ack(s.err,y,n))}n.some&&n.parsed>=n.limit||(n.next=e.file,u.read(t,e.ack,n))}},r.reverse&&(s.lex.reverse=!0),u.list(s.lex)},function(){var n={},i=String.fromCharCode(31);u.parse=function(o,l,u){var c;if(c=n[o])return c.push(l);c=n[o]=[l];var h=function e(){},f={};if(h.disk=s(),h.read=function(t,r){var i,s,s;if(delete n[o],(h.err=t)||(h.not=!r))return a(c,h.ack);if("string"!=typeof r){try{e.pack<=r.length?h.err="Chunk too big!":r=r.toString()}catch(e){h.err=e}if(h.err)return a(c,h.ack)}if(f.parsed=r.length,e.jsonify){try{var l=JSON.parse(r);return h.disk.$=l,void a(c,h.ack)}catch(e){i=e}if("{"===r[0])return h.err=i||"JSON error!",a(c,h.ack)}var i=h.split(r),u=[],p,d,m;if(!i||0!==i[1])return h.err="File '"+o+"' does not have root radix! ",a(c,h.ack);for(;i;)d=m=y,p=i[1],i=h.split(i[2])||"","#"==i[0]&&(d=i[1],u=u.slice(0,p),p<=u.length&&u.push(d)),i=h.split(i[2])||"","\n"!=i[0]&&("="!=i[0]&&":"!=i[0]||(m=i[1]),y!==d&&y!==m&&h.disk(u.join(""),m),i=h.split(i[2]));a(c,h.ack)},h.split=function(e){if(e){var n=[],r={},o=-1,s="",a,l;if(o=e.indexOf(i),e[o])return s=e.slice(0,o),n[0]=s,n[1]=a=t.decode(e.slice(o),r),n[2]=e.slice(o+r.i),n}},h.ack=function(e){if(e)return h.err||h.not?e(h.err,y,f):void e(y,h.disk,f)},u)return h.read(null,u);e.store.get(r(o),h.read)}}(),p=String.fromCharCode(28),d=r(p),u.list=function(e){if(h){var t={reverse:e.reverse?1:0};s.map(h,function(t,n){return e(n)},t)||e()}else{if(f)return f.push(e);f=[e],u.parse(p,u.list.init)}},u.list.add=function(e,t){var n=h(e);if(n||e===d)return t(y,1);h(e,!0),t.listed=(t.listed||0)+1,u.write(p,h,function(e,n){if(e)return t(e);t.listed=(t.listed||0)-1,0===t.listed&&t(y,1)},!0)},u.list.init=function(t,n){if(t)return e.log("list",t),void setTimeout(function(){u.parse(p,u.list.init)},1e3);n?u.list.drain(n):e.store.list?e.store.list(function(e){if(h=h||s(),!e)return u.list.drain(h);u.list.add(e,m)}):u.list.drain(s())},u.list.drain=function(e,t){u.list.dir=h=e,t=f,f=null,o.list.map(t,function(e){u.list(e)})};var m=function(){},g,y;return t.has[e.file]=u,u}var r,i;if(r=String.fromCharCode(31),t.encode=function(e,t,n){n=n||r;var i=n,s;if("string"==typeof e){for(var a=e.indexOf(n);-1!=a;)i+=n,a=e.indexOf(n,a+1);return i+'"'+e+n}return e&&e["#"]&&(s=o.val.link.is(e))?i+"#"+s+i:o.num.is(e)?i+"+"+(e||0)+i:null===e?i+" "+i:!0===e?i+"+"+i:!1===e?i+"-"+i:void 0},t.decode=function(e,t,n){n=n||r;var i="",s=-1,a=0,l,u;if(n===e[0]){for(;n===e[++s];)++a;for(u=e[l=a]||!0;--a>=0;)s=e.indexOf(n,s+1);return-1==s&&(s=e.length),i=e.slice(l+1,s),t&&(t.i=s+1),'"'===u?i:"#"===u?o.val.link.ify(i):"+"===u?0===i.length||parseFloat(i):" "===u?null:"-"!==u&&void 0}},"undefined"!=typeof window){var o=window.Gun,s=window.Radix;window.Radisk=t}else{var o=n(144),s=n(637);try{e.exports=t}catch(e){}}t.Radix=s}()},function(e,t,n){const r=n(94);n(668),n(676),n(1482),n(1517),n(1630),n(1783),"undefined"!=typeof window&&(window.DwebTransports=r),t=e.exports=r},function(e,t,n){"use strict";e.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"==typeof e&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},function(e,t,n){"use strict";function r(e,t){return Object.prototype.hasOwnProperty.call(e,t)}e.exports=function(e,t,n,o){t=t||"&",n=n||"=";var s={};if("string"!=typeof e||0===e.length)return s;var a=/\+/g;e=e.split(t);var l=1e3;o&&"number"==typeof o.maxKeys&&(l=o.maxKeys);var u=e.length;l>0&&u>l&&(u=l);for(var c=0;c<u;++c){var h=e[c].replace(a,"%20"),f=h.indexOf(n),p,d,m,g;f>=0?(p=h.substr(0,f),d=h.substr(f+1)):(p=h,d=""),m=decodeURIComponent(p),g=decodeURIComponent(d),r(s,m)?i(s[m])?s[m].push(g):s[m]=[s[m],g]:s[m]=g}return s};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},function(e,t,n){"use strict";var r=function(e){switch(typeof e){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};e.exports=function(e,t,n,a){return t=t||"&",n=n||"=",null===e&&(e=void 0),"object"==typeof e?o(s(e),function(s){var a=encodeURIComponent(r(s))+n;return i(e[s])?o(e[s],function(e){return a+encodeURIComponent(r(e))}).join(t):a+encodeURIComponent(r(e[s]))}).join(t):a?encodeURIComponent(r(a))+n+encodeURIComponent(r(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function o(e,t){if(e.map)return e.map(t);for(var n=[],r=0;r<e.length;r++)n.push(t(e[r],r));return n}var s=Object.keys||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.push(n);return t}},function(e,t,n){function r(e){function t(e){let t=0;for(let n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){let n;function s(...e){if(!s.enabled)return;const t=s,i=Number(new Date),o=i-(n||i);t.diff=o,t.prev=n,t.curr=i,n=i,e[0]=r.coerce(e[0]),"string"!=typeof e[0]&&e.unshift("%O");let a=0;e[0]=e[0].replace(/%([a-zA-Z%])/g,(n,i)=>{if("%%"===n)return n;a++;const o=r.formatters[i];if("function"==typeof o){const r=e[a];n=o.call(t,r),e.splice(a,1),a--}return n}),r.formatArgs.call(t,e);const l=t.log||r.log;l.apply(t,e)}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){const e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){const n=r(this.namespace+(void 0===t?":":t)+e);return n.log=this.log,n}function s(e){let t;r.save(e),r.names=[],r.skips=[];const n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){const e=r.instances[t];e.enabled=r.enabled(e.namespace)}}function a(){const e=[...r.names.map(u),...r.skips.map(u).map(e=>"-"+e)].join(",");return r.enable(""),e}function l(e){if("*"===e[e.length-1])return!0;let t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e.toString().substring(2,e.toString().length-2).replace(/\.\*\?$/,"*")}function c(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=c,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(t=>{r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t,n){"use strict";t.byteLength=c,t.toByteArray=f,t.fromByteArray=m;for(var r=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",a=0,l=s.length;a<l;++a)r[a]=s[a],i[s.charCodeAt(a)]=a;function u(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}function c(e){var t=u(e),n=t[0],r=t[1];return 3*(n+r)/4-r}function h(e,t,n){return 3*(t+n)/4-n}function f(e){for(var t,n=u(e),r=n[0],s=n[1],a=new o(h(e,r,s)),l=0,c=s>0?r-4:r,f=0;f<c;f+=4)t=i[e.charCodeAt(f)]<<18|i[e.charCodeAt(f+1)]<<12|i[e.charCodeAt(f+2)]<<6|i[e.charCodeAt(f+3)],a[l++]=t>>16&255,a[l++]=t>>8&255,a[l++]=255&t;return 2===s&&(t=i[e.charCodeAt(f)]<<2|i[e.charCodeAt(f+1)]>>4,a[l++]=255&t),1===s&&(t=i[e.charCodeAt(f)]<<10|i[e.charCodeAt(f+1)]<<4|i[e.charCodeAt(f+2)]>>2,a[l++]=t>>8&255,a[l++]=255&t),a}function p(e){return r[e>>18&63]+r[e>>12&63]+r[e>>6&63]+r[63&e]}function d(e,t,n){for(var r,i=[],o=t;o<n;o+=3)r=(e[o]<<16&16711680)+(e[o+1]<<8&65280)+(255&e[o+2]),i.push(p(r));return i.join("")}function m(e){for(var t,n=e.length,i=n%3,o=[],s=16383,a=0,l=n-i;a<l;a+=16383)o.push(d(e,a,a+16383>l?l:a+16383));return 1===i?(t=e[n-1],o.push(r[t>>2]+r[t<<4&63]+"==")):2===i&&(t=(e[n-2]<<8)+e[n-1],o.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"=")),o.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(e,t){},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=v;var r=n(647),i=y(r),o=n(65),s=y(o),a=n(58),l=y(a),u=n(107),c=y(u),h=n(180),f=y(h),p=n(651),d=y(p),m=n(37),g=y(m);function y(e){return e&&e.__esModule?e:{default:e}}function v(e,t,n){if(null==t)t=1;else if(0===t)throw new Error("Concurrency must not be zero");var r=(0,g.default)(e),o=0,a=[],u=!1;function h(e,t,n){if(null!=n&&"function"!=typeof n)throw new Error("task callback must be a function");if(y.started=!0,(0,s.default)(e)||(e=[e]),0===e.length&&y.idle())return(0,f.default)(function(){y.drain()});for(var r=0,i=e.length;r<i;r++){var o={data:e[r],callback:n||l.default};t?y._tasks.unshift(o):y._tasks.push(o)}u||(u=!0,(0,f.default)(function(){u=!1,y.process()}))}function p(e){return function(t){o-=1;for(var n=0,r=e.length;n<r;n++){var s=e[n],l=(0,i.default)(a,s,0);0===l?a.shift():l>0&&a.splice(l,1),s.callback.apply(s,arguments),null!=t&&y.error(t,s.data)}o<=y.concurrency-y.buffer&&y.unsaturated(),y.idle()&&y.drain(),y.process()}}var m=!1,y={_tasks:new d.default,concurrency:t,payload:n,saturated:l.default,unsaturated:l.default,buffer:t/4,empty:l.default,drain:l.default,error:l.default,started:!1,paused:!1,push:function(e,t){h(e,!1,t)},kill:function(){y.drain=l.default,y._tasks.empty()},unshift:function(e,t){h(e,!0,t)},remove:function(e){y._tasks.remove(e)},process:function(){if(!m){for(m=!0;!y.paused&&o<y.concurrency&&y._tasks.length;){var e=[],t=[],n=y._tasks.length;y.payload&&(n=Math.min(n,y.payload));for(var i=0;i<n;i++){var s=y._tasks.shift();e.push(s),a.push(s),t.push(s.data)}o+=1,0===y._tasks.length&&y.empty(),o===y.concurrency&&y.saturated();var l=(0,c.default)(p(e));r(t,l)}m=!1}},length:function(){return y._tasks.length},running:function(){return o},workersList:function(){return a},idle:function(){return y._tasks.length+o===0},pause:function(){y.paused=!0},resume:function(){!1!==y.paused&&(y.paused=!1,(0,f.default)(y.process))}};return y}e.exports=t.default},function(e,t,n){var r=n(648),i=n(649),o=n(650);function s(e,t,n){return t==t?o(e,t,n):r(e,i,n)}e.exports=s},function(e,t){function n(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o<i;)if(t(e[o],o,e))return o;return-1}e.exports=n},function(e,t){function n(e){return e!=e}e.exports=n},function(e,t){function n(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1}e.exports=n},function(e,t,n){"use strict";function r(){this.head=this.tail=null,this.length=0}function i(e,t){e.length=1,e.head=e.tail=t}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,r.prototype.removeLink=function(e){return e.prev?e.prev.next=e.next:this.head=e.next,e.next?e.next.prev=e.prev:this.tail=e.prev,e.prev=e.next=null,this.length-=1,e},r.prototype.empty=function(){for(;this.head;)this.shift();return this},r.prototype.insertAfter=function(e,t){t.prev=e,t.next=e.next,e.next?e.next.prev=t:this.tail=t,e.next=t,this.length+=1},r.prototype.insertBefore=function(e,t){t.prev=e.prev,t.next=e,e.prev?e.prev.next=t:this.head=t,e.prev=t,this.length+=1},r.prototype.unshift=function(e){this.head?this.insertBefore(this.head,e):i(this,e)},r.prototype.push=function(e){this.tail?this.insertAfter(this.tail,e):i(this,e)},r.prototype.shift=function(){return this.head&&this.removeLink(this.head)},r.prototype.pop=function(){return this.tail&&this.removeLink(this.tail)},r.prototype.toArray=function(){for(var e=Array(this.length),t=this.head,n=0;n<this.length;n++)e[n]=t.data,t=t.next;return e},r.prototype.remove=function(e){for(var t=this.head;t;){var n=t.next;e(t)&&this.removeLink(t),t=n}return this},e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(181),i=u(r),o=n(326),s=u(o),a=n(180),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e){return(0,s.default)(function(t,n){var r;try{r=e.apply(this,t)}catch(e){return n(e)}(0,i.default)(r)&&"function"==typeof r.then?r.then(function(e){h(n,null,e)},function(e){h(n,e.message?e:new Error(e))}):n(null,r)})}function h(e,t,n){try{e(t,n)}catch(e){(0,l.default)(f,e)}}function f(e){throw e}e.exports=t.default},function(e,t,n){var r=n(182),i=Object.prototype,o=i.hasOwnProperty,s=i.toString,a=r?r.toStringTag:void 0;function l(e){var t=o.call(e,a),n=e[a];try{e[a]=void 0;var r=!0}catch(e){}var i=s.call(e);return r&&(t?e[a]=n:delete e[a]),i}e.exports=l},function(e,t){var n=Object.prototype,r=n.toString;function i(e){return r.call(e)}e.exports=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=p;var r=n(147),i=u(r),o=n(656),s=u(o),a=n(149),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e){var t=-1,n=e.length;return function r(){return++t<n?{value:e[t],key:t}:null}}function h(e){var t=-1;return function n(){var r=e.next();return r.done?null:(t++,{value:r.value,key:t})}}function f(e){var t=(0,l.default)(e),n=-1,r=t.length;return function i(){var o=t[++n];return n<r?{value:e[o],key:o}:null}}function p(e){if((0,i.default)(e))return c(e);var t=(0,s.default)(e);return t?h(t):f(e)}e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return r&&e[r]&&e[r]()};var r="function"==typeof Symbol&&Symbol.iterator;e.exports=t.default},function(e,t,n){var r=n(658),i=n(329),o=n(65),s=n(330),a=n(331),l=n(332),u=Object.prototype,c=u.hasOwnProperty;function h(e,t){var n=o(e),u=!n&&i(e),h=!n&&!u&&s(e),f=!n&&!u&&!h&&l(e),p=n||u||h||f,d=p?r(e.length,String):[],m=d.length;for(var g in e)!t&&!c.call(e,g)||p&&("length"==g||h&&("offset"==g||"parent"==g)||f&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||a(g,m))||d.push(g);return d}e.exports=h},function(e,t){function n(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}e.exports=n},function(e,t,n){var r=n(108),i=n(87),o="[object Arguments]";function s(e){return i(e)&&r(e)==o}e.exports=s},function(e,t){function n(){return!1}e.exports=n},function(e,t,n){var r=n(108),i=n(242),o=n(87),s="[object Arguments]",a="[object Array]",l="[object Boolean]",u="[object Date]",c="[object Error]",h="[object Function]",f="[object Map]",p="[object Number]",d="[object Object]",m="[object RegExp]",g="[object Set]",y="[object String]",v="[object WeakMap]",b="[object ArrayBuffer]",_="[object DataView]",w="[object Float32Array]",k="[object Float64Array]",E="[object Int8Array]",S="[object Int16Array]",x="[object Int32Array]",C="[object Uint8Array]",A="[object Uint8ClampedArray]",T="[object Uint16Array]",I="[object Uint32Array]",j={};function R(e){return o(e)&&i(e.length)&&!!j[r(e)]}j[w]=j[k]=j[E]=j[S]=j[x]=j[C]=j[A]=j[T]=j[I]=!0,j[s]=j[a]=j[b]=j[l]=j[_]=j[u]=j[c]=j[h]=j[f]=j[p]=j[d]=j[m]=j[g]=j[y]=j[v]=!1,e.exports=R},function(e,t){function n(e){return function(t){return e(t)}}e.exports=n},function(e,t,n){(function(e){var r=n(327),i=t&&!t.nodeType&&t,o=i&&"object"==typeof e&&e&&!e.nodeType&&e,s=o&&o.exports===i,a=s&&r.process,l=function(){try{var e=o&&o.require&&o.require("util").types;return e||a&&a.binding&&a.binding("util")}catch(e){}}();e.exports=l}).call(this,n(85)(e))},function(e,t,n){var r=n(665),i=n(666),o=Object.prototype,s=o.hasOwnProperty;function a(e){if(!r(e))return i(e);var t=[];for(var n in Object(e))s.call(e,n)&&"constructor"!=n&&t.push(n);return t}e.exports=a},function(e,t){var n=Object.prototype;function r(e){var t=e&&e.constructor,r="function"==typeof t&&t.prototype||n;return e===r}e.exports=r},function(e,t,n){var r=n(667),i=r(Object.keys,Object);e.exports=i},function(e,t){function n(e,t){return function(n){return e(t(n))}}e.exports=n},function(e,t,n){const r=n(111),i=n(94),o=n(240),s=n(32),a=n(17),l=n(4)("dweb-transports:http"),u=n(184);defaulthttpoptions={urlbase:"https://dweb.me",heartbeat:{delay:3e4}},servercommands={rawfetch:"contenthash",rawstore:"contenturl/rawstore",rawadd:"void/rawadd",rawlist:"metadata/rawlist",get:"get/table",set:"set/table",delete:"delete/table",keys:"keys/table",getall:"getall/table"};class c extends r{constructor(e){super(e),this.options=e,this.urlbase=e.urlbase,this.supportURLs=["contenthash","http","https"],this.supportFunctions=["fetch","store","add","list","reverse","newlisturls","get","set","keys","getall","delete","newtable","newdatabase"],this.supportFeatures=["noCache"],"undefined"==typeof window&&this.supportFunctions.push("createReadStream"),this.supportFeatures=["fetch.range","noCache"],this.name="HTTP",this.status=r.STATUS_LOADED}static setup0(e){let t=r.mergeoptions(defaulthttpoptions,e.http);try{let e=new c(t);return i.addtransport(e),e}catch(e){throw console.error("HTTP unable to setup0",e.message),e}}p_setup1(e){return new Promise((t,n)=>{this.status=r.STATUS_STARTING,e&&e(this),this.updateStatus((n,r)=>{e&&e(this),this.startHeartbeat(this.options.heartbeat),t(this)})})}async p_status(e){if(!e)return new Promise((e,t)=>{try{this.updateStatus((n,r)=>{n?t(n):e(r)})}catch(e){t(e)}});try{this.updateStatus(e)}catch(t){e(t)}}updateStatus(e){this.updateInfo((t,n)=>{t?(l("Error status call to info failed %s",t.message),this.status=r.STATUS_FAILED,e(null,this.status)):(this.info=n,this.status=r.STATUS_CONNECTED,e(null,this.status))})}startHeartbeat({delay:e,statusCB:t}){e&&(l("HTTP Starting Heartbeat"),this.HTTPheartbeatTimer=setInterval(()=>{this.updateStatus((e,n)=>{t&&t(this)},(e,t)=>{})},e))}stopHeartbeat(){this.HTTPheartbeatTimer&&(l("HTTP stopping heartbeat"),clearInterval(this.HTTPheartbeatTimer))}stop(e,t){this.stopHeartbeat(),this.status=r.STATUS_FAILED,e&&e(this),t(null,this)}_cmdurl(e){return`${this.urlbase}/${e}`}_url(e,t,n){if(!e)throw new errors.CodingError(`${t}: requires url`);return"string"!=typeof e&&(e=e.href),e=e.replace("contenthash:/contenthash",this._cmdurl(t)),e=e.replace("getall/table",t),e+=n?"?"+n:"",e}validFor(e,t,n){return(this.connected()||e.protocol.startsWith("http")&&!e.href.startsWith(this.urlbase))&&this.supports(e,t,n)}async p_rawfetch(e,t={}){if(("string"==typeof e?e:e.href).includes("/getall/table"))throw new Error("Probably dont want to be calling p_rawfetch on a KeyValueTable, especially since dont know if its keyvaluetable or subclass");return await o.p_GET(this._url(e,servercommands.rawfetch),t)}p_rawlist(e){if(!e)throw new errors.CodingError("TransportHTTP.p_rawlist: requires url");return o.p_GET(this._url(e,servercommands.rawlist))}rawreverse(){throw new errors.ToBeImplementedError("Undefined function TransportHTTP.rawreverse")}async p_rawstore(e){console.assert(e,"TransportHttp.p_rawstore: requires data");const t=await o.p_POST(this._cmdurl(servercommands.rawstore),{data:e,contenttype:"application/octet-stream"});let n=s.parse(t),r=n.pathname.split("/");return`contenthash:/contenthash/${r.slice(-1)}`}p_rawadd(e,t){if(!e||!t)throw new errors.CodingError("TransportHTTP.p_rawadd: invalid parms",e,t);const n=u(t.preflight(Object.assign({},t)))+"\n";return o.p_POST(this._url(e,servercommands.rawadd),{data:n,contenttype:"application/json"})}p_newlisturls(e){let t=e._publicurls.map(e=>s.parse(e)).find(e=>"https:"===e.protocol&&["gateway.dweb.me","dweb.me"].includes(e.host)&&(e.pathname.includes("/content/rawfetch")||e.pathname.includes("/contenthash/"))||"contenthash:"===e.protocol&&"contenthash"===e.pathname.split("/")[1]);return t||(t=`contenthash:/contenthash/${e.keypair.verifyexportmultihashsha256_58()}`),[t,t]}async p_f_createReadStream(e,{wanturl:t=!1}={}){try{let n=this;return t?e:function(t){return n.createReadStream(e,t)}}catch(e){throw e}}createReadStream(e,t){let n;return l("createreadstream %s %o",s.parse(e).href,t),n=new a.PassThrough,o.p_GET(this._url(e,servercommands.rawfetch),Object.assign({wantstream:!0},t)).then(e=>e.pipe(n)).catch(e=>{console.warn(this.name,"createReadStream caught error",e.message),"function"==typeof n.destroy?n.destroy(e):n.emit("error",e)}),n}async p_createReadStream(e,t){l("createreadstream %s %o",s.parse(e).href,t);try{return await o.p_GET(this._url(e,servercommands.rawfetch),Object.assign({wantstream:!0},t))}catch(e){throw console.warn(this.name,"caught error",e),e}}async p_newdatabase(e){e.hasOwnProperty("keypair")&&(e=e.keypair.signingexport());let t=`${this.urlbase}/getall/table/${encodeURIComponent(e)}`;return{publicurl:t,privateurl:t}}async p_newtable(e,t){if(!e)throw new errors.CodingError("p_newtable currently requires a pubkey");let n=await this.p_newdatabase(e);return{privateurl:`${n.privateurl}/${t}`,publicurl:`${n.publicurl}/${t}`}}async p_set(e,t,n){if(!e||!t)throw new errors.CodingError("TransportHTTP.p_set: invalid parms",e,keyvalyes);if("string"==typeof t){let r=u([{key:t,value:n}]);await o.p_POST(this._url(e,servercommands.set),{data:r,contenttype:"application/json"})}else{let n=u(Object.keys(t).map(e=>({key:e,value:t[e]})));await o.p_POST(this._url(e,servercommands.set),{data:n,contenttype:"application/json"})}}_keyparm(e){return`key=${encodeURIComponent(e)}`}async p_get(e,t){if(!e&&t)throw new errors.CodingError("TransportHTTP.p_get: requires url and at least one key");let n=Array.isArray(t)?t.map(e=>this._keyparm(e)).join("&"):this._keyparm(t);const r=await o.p_GET(this._url(e,servercommands.get,n));return Array.isArray(t)?r:r[t]}async p_delete(e,t){if(!e&&t)throw new errors.CodingError("TransportHTTP.p_get: requires url and at least one key");let n=t.map(e=>this._keyparm(e)).join("&");await o.p_GET(this._url(e,servercommands.delete,n))}async p_keys(e){if(!e&&keys)throw new errors.CodingError("TransportHTTP.p_get: requires url and at least one key");return await o.p_GET(this._url(e,servercommands.keys))}async p_getall(e){if(!e&&keys)throw new errors.CodingError("TransportHTTP.p_get: requires url and at least one key");return await o.p_GET(this._url(e,servercommands.getall))}async p_info(){return new Promise((e,t)=>{try{this.updateInfo((n,r)=>{n?t(n):e(r)})}catch(e){t(e)}})}updateInfo(e){o.p_GET(`${this.urlbase}/info`,{retries:1},e)}static async p_test(e={}){console.log("TransportHTTP.test");try{let t=await this.p_setup(e);console.log("HTTP connected");let n=await t.p_info();console.log("TransportHTTP info=",n),n=await t.p_status(),console.assert(n===r.STATUS_CONNECTED),await t.p_test_kvt("NACL%20VERIFY")}catch(e){throw console.log("Exception thrown in TransportHTTP.test:",e.message),e}}static async test(){return this}}i._transportclasses.HTTP=c,t=e.exports=c},function(e,t){},function(e,t,n){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},r=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),r.forEach(function(t){i(e,t,n[t])})}return e}function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var o=n(0),s=o.Buffer,a=n(671),l=a.inspect,u=l&&l.custom||"inspect";function c(e,t,n){s.prototype.copy.call(e,t,n)}e.exports=function(){function e(){this.head=null,this.tail=null,this.length=0}var t=e.prototype;return t.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},t.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},t.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.clear=function e(){this.head=this.tail=null,this.length=0},t.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},t.concat=function e(t){if(0===this.length)return s.alloc(0);for(var n=s.allocUnsafe(t>>>0),r=this.head,i=0;r;)c(r.data,n,i),i+=r.data.length,r=r.next;return n},t.consume=function e(t,n){var r;return t<this.head.data.length?(r=this.head.data.slice(0,t),this.head.data=this.head.data.slice(t)):r=t===this.head.data.length?this.shift():n?this._getString(t):this._getBuffer(t),r},t.first=function e(){return this.head.data},t._getString=function e(t){var n=this.head,r=1,i=n.data;for(t-=i.length;n=n.next;){var o=n.data,s=t>o.length?o.length:t;if(s===o.length?i+=o:i+=o.slice(0,t),t-=s,0===t){s===o.length?(++r,n.next?this.head=n.next:this.head=this.tail=null):(this.head=n,n.data=o.slice(s));break}++r}return this.length-=r,i},t._getBuffer=function e(t){var n=s.allocUnsafe(t),r=this.head,i=1;for(r.data.copy(n),t-=r.data.length;r=r.next;){var o=r.data,a=t>o.length?o.length:t;if(o.copy(n,n.length-t,0,a),t-=a,0===t){a===o.length?(++i,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=o.slice(a));break}++i}return this.length-=i,n},t[u]=function(e,t){return l(this,r({},t,{depth:0,customInspect:!1}))},e}()},function(e,t){},function(e,t,n){"use strict";(function(t){var n=new Set;function r(e){if(!n.has(e)){var r=e+" is an experimental feature. This feature could change at any time";n.add(e),t.emitWarning(r,"ExperimentalWarning")}}function i(){}e.exports.emitExperimentalWarning=t.emitWarning?r:i}).call(this,n(3))},function(e,t,n){"use strict";(function(t){var r;function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var o=n(245),s=Symbol("lastResolve"),a=Symbol("lastReject"),l=Symbol("error"),u=Symbol("ended"),c=Symbol("lastPromise"),h=Symbol("handlePromise"),f=Symbol("stream");function p(e,t){return{value:e,done:t}}function d(e){var t=e[s];if(null!==t){var n=e[f].read();null!==n&&(e[c]=null,e[s]=null,e[a]=null,t(p(n,!1)))}}function m(e){t.nextTick(d,e)}function g(e,t){return function(n,r){e.then(function(){t[u]?n(p(void 0,!0)):t[h](n,r)},r)}}var y=Object.getPrototypeOf(function(){}),v=Object.setPrototypeOf((r={get stream(){return this[f]},next:function e(){var n=this,r=this[l];if(null!==r)return Promise.reject(r);if(this[u])return Promise.resolve(p(void 0,!0));if(this[f].destroyed)return new Promise(function(e,r){t.nextTick(function(){n[l]?r(n[l]):e(p(void 0,!0))})});var i=this[c],o;if(i)o=new Promise(g(i,this));else{var s=this[f].read();if(null!==s)return Promise.resolve(p(s,!1));o=new Promise(this[h])}return this[c]=o,o}},i(r,Symbol.asyncIterator,function(){return this}),i(r,"return",function e(){var t=this;return new Promise(function(e,n){t[f].destroy(null,function(t){t?n(t):e(p(void 0,!0))})})}),r),y),b=function e(t){var n,r=Object.create(v,(n={},i(n,f,{value:t,writable:!0}),i(n,s,{value:null,writable:!0}),i(n,a,{value:null,writable:!0}),i(n,l,{value:null,writable:!0}),i(n,u,{value:t._readableState.endEmitted,writable:!0}),i(n,h,{value:function e(t,n){var i=r[f].read();i?(r[c]=null,r[s]=null,r[a]=null,t(p(i,!1))):(r[s]=t,r[a]=n)},writable:!0}),n));return r[c]=null,o(t,function(e){if(e&&"ERR_STREAM_PREMATURE_CLOSE"!==e.code){var t=r[a];return null!==t&&(r[c]=null,r[s]=null,r[a]=null,t(e)),void(r[l]=e)}var n=r[s];null!==n&&(r[c]=null,r[s]=null,r[a]=null,n(p(void 0,!0))),r[u]=!0}),t.on("readable",m.bind(null,r)),r};e.exports=b}).call(this,n(3))},function(e,t,n){"use strict";e.exports=i;var r=n(340);function i(e){if(!(this instanceof i))return new i(e);r.call(this,e)}n(1)(i,r),i.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){"use strict";var r;function i(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}var o=n(112).codes,s=o.ERR_MISSING_ARGS,a=o.ERR_STREAM_DESTROYED;function l(e){if(e)throw e}function u(e){return e.setHeader&&"function"==typeof e.abort}function c(e,t,o,s){s=i(s);var l=!1;e.on("close",function(){l=!0}),void 0===r&&(r=n(245)),r(e,{readable:t,writable:o},function(e){if(e)return s(e);l=!0,s()});var c=!1;return function(t){if(!l&&!c)return c=!0,u(e)?e.abort():"function"==typeof e.destroy?e.destroy():void s(t||new a("pipe"))}}function h(e){e()}function f(e,t){return e.pipe(t)}function p(e){return e.length?"function"!=typeof e[e.length-1]?l:e.pop():l}function d(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=p(t),i;if(Array.isArray(t[0])&&(t=t[0]),t.length<2)throw new s("streams");var o=t.map(function(e,n){var s=n<t.length-1,a=n>0;return c(e,s,a,function(e){i||(i=e),e&&o.forEach(h),s||(o.forEach(h),r(i))})});return t.reduce(f)}e.exports=d},function(e,t,n){(function(r,i){const o=n(240),s=n(4)("dweb-transports:ipfs"),a=n(677),l=n(1262),u=n(9),c=n(45),h=n(32),f=n(17),p=n(77),d=n(111),m=n(94),g=n(146),y={repo:"/tmp/dweb_ipfsv3107",config:{Bootstrap:["/dns4/dweb.me/tcp/4245/wss/ipfs/QmQz3p44VVQDeAieaW28DMjcTVzLbpxqaQB9bkXnyd7HY5"]},EXPERIMENTAL:{pubsub:!0},preload:{enabled:!1}};class v extends d{constructor(e){super(e),["urlUrlstore","httpIPFSgateway"].forEach(t=>{this[t]=e[t],delete e[t]}),this.ipfs=void 0,this.options=e,this.name="IPFS",this.supportURLs=["ipfs"],this.supportFunctions=["fetch","store","seed","createReadStream"],this.supportFeatures=["noCache"],this.status=d.STATUS_LOADED}_ipfsversion(e,t,n){e.version((r,i)=>{r?(s("IPFS via %s present but unresponsive: %o",t,i),this.ipfstype="FAILED",n(r)):(s("IPFS available via %s: %o",t,i),this.ipfstype=t,n(null,e))})}IPFSAutoConnect(e){if(r.ipfs)this._ipfsversion(r.ipfs,"global.ipfs",e);else if("undefined"!=typeof window&&window.ipfs)this._ipfsversion(window.ipfs,"window.ipfs",e);else{var t=l("localhost","5001",{protocol:"http"});t.version((n,r)=>{n?(s("IPFS via API failed %s, trying running own IPFS client",n.message),t=new a(this.options),t.on("ready",()=>{this._ipfsversion(t,"client",e)}),t.on("error",t=>{s("IPFS via client error %s",t.message),e(t)})):this._ipfsversion(t,"API",e)})}}static setup0(e){const t=d.mergeoptions(y,e.ipfs);s("setup options=%o",t);const n=new v(t);return m.addtransport(n),n}p_setup1(e,t){if(!t)return new Promise((e,t)=>{try{n.call(this,(n,r)=>{n?t(n):e(r)})}catch(e){t(e)}});try{n.call(this,t)}catch(e){t(e)}function n(t){this.status=d.STATUS_STARTING,e&&e(this),this.IPFSAutoConnect((n,r)=>{n?(s("Failed to connect %s",n.message),this.status=d.STATUS_FAILED):(this.ipfs=r,this.status=d.STATUS_CONNECTED),e&&e(this),t(null,this)})}}p_setup2(e){return this.status===d.STATUS_FAILED&&s("Stage 1 failed, skipping"),this}stop(e,t){"client"===this.ipfstype?this.ipfs.stop((n,r)=>{this.status=d.STATUS_FAILED,e&&e(this),t(n,r)}):(this.status=d.STATUS_FAILED,e&&e(this),t(miull,this))}async p_status(){return this.status=await this.ipfs.isOnline()?d.STATUS_CONNECTED:d.STATUS_FAILED,super.p_status()}static urlFrom(e){if(e instanceof u)return"ipfs:/ipfs/"+e.toBaseEncodedString();if("object"==typeof e&&e.hash)return"ipfs:/ipfs/"+e.hash;if("string"==typeof e)return"ipfs:/ipfs/"+e;throw new p.CodingError("TransportIPFS.urlFrom: Cant convert to url from",e)}static cidFrom(e){if(e instanceof u)return e;if("string"==typeof e&&(e=h.parse(e)),e&&e.pathname){const t=e.pathname.split("/");if(!["ipfs:","dweb:"].includes(e.protocol)||"ipfs"!==t[1]||t.length<3)throw new p.TransportError("TransportIPFS.cidFrom bad format for url should be dweb: or ipfs:/ipfs/...: "+e.href);if(t.length>3)throw new p.TransportError("TransportIPFS.cidFrom not supporting paths in url yet, should be dweb: or ipfs:/ipfs/...: "+e.href);return new u(t[2])}throw new p.CodingError("TransportIPFS.cidFrom: Cant convert url",e)}static _stringFrom(e){return e instanceof u?"/ipfs/"+e.toBaseEncodedString():"object"==typeof e&&e.path?e.path:void 0}static ipfsFrom(e){if(e=this._stringFrom(e),e.indexOf("/ipfs/")>-1)return e.slice(e.indexOf("/ipfs/"));throw new p.CodingError(`TransportIPFS.ipfsFrom: Cant convert url ${e} into a path starting /ipfs/`)}ipfsGatewayFrom(e){if(e=this._stringFrom(e),e.indexOf("/ipfs/")>-1)return this.httpIPFSgateway+e.slice(e.indexOf("/ipfs/"));throw new p.CodingError(`TransportIPFS.ipfsGatewayFrom: Cant convert url ${e} into a path starting /ipfs/`)}static multihashFrom(e){if(e instanceof u)return e.toBaseEncodedString();if("object"==typeof e&&e.path&&(e=e.path),"string"==typeof e){const t=e.indexOf("/ipfs/");if(t>-1)return e.slice(t+6)}throw new p.CodingError(`Cant turn ${e} into a multihash`)}async p_rawfetch(e,{timeoutMS:t=6e4,relay:n=!1}={}){if(!e)throw new p.CodingError("TransportIPFS.p_rawfetch: requires url");const r=v.cidFrom(e),i=v.ipfsFrom(e);try{const n=await g.p_timeout(this.ipfs.dag.get(r),t,"Timed out IPFS fetch of "+v._stringFrom(r));if(n.remainderPath.length)throw new p.TransportError("Not yet supporting paths in p_rawfetch");let a;return"DAGNode"===n.value.constructor.name?a=await this.ipfs.cat(i):(s("Found a raw IPFS block (unusual) - not a DAGNode - handling as such"),a=n.value),a}catch(n){if(s("Caught error '%s' fetching via IPFS",n.message),!this.httpIPFSgateway)throw n;try{s("Trying IPFS HTTP gateway");let n=this.ipfsGatewayFrom(e);return await g.p_timeout(o.p_GET(n),t,"Timed out IPFS fetch of "+n)}catch(e){throw e}}}async p_rawstore(e){console.assert(e,"TransportIPFS.p_rawstore: requires data");const t=e instanceof i?e:new i(e),n=(await this.ipfs.add(t,{"cid-version":1,hashAlg:"sha2-256"}))[0];return v.urlFrom(n)}seed({directoryPath:e,fileRelativePath:t,ipfsHash:n,urlToFile:r},i){if(this.urlUrlstore&&r){const e=`${this.urlUrlstore}?arg=${encodeURIComponent(r)}`;o.p_GET(e,{retries:0},(e,t)=>{e?(s("IPFS.seed for %s failed in http: %s",r,e.message),i(e)):(s("Added %s to IPFS key=",r,t.Key),n&&n!==t.Key&&s("ipfs hash doesnt match expected metadata has %s daemon returned %s",n,t.Key),i(null,t))})}else s("IPFS.seed support requires urlUrlstore and urlToFile"),i(new Error("IPFS.seed support requires urlUrlstore and urlToFile"))}async p_f_createReadStream(e,{wanturl:t=!1}={}){let n;try{let r=e.pathname.split("/ipfs/")[1];if(r.includes("/"))throw new CodingError("Should not be seeing URLS with a path here:"+e);let i=this;return t?e:function e(t){s("reading from stream %o %o",r,t||"");const o=t?t.start:0,a=t&&t.end?o+t.end+1:void 0;return n&&n.destroy&&n.destroy(),n=i.ipfs.catReadableStream(r,{offset:o,length:a&&a-o}),n.on("error",e=>console.error(e)),n}}catch(e){throw n&&n.destroy&&n.destroy(),e}}static async p_test(e){console.log("TransportIPFS.test");try{const t=await this.p_setup(e);console.log(t.name,"setup");const n=await t.p_status();let r;console.assert(n===d.STATUS_CONNECTED);const i="The quick brown fox",o="ipfs:/ipfs/zdpuAscRnisRkYnEyJAp1LydQ3po25rCEDPPEDMymYRfN1yPK",s="1114",a=await t.p_rawstore(i);console.log("rawstore returned",a);const l=v.cidFrom(a);console.assert(a===o,"url should match url from rawstore");const u=a.split("/")[2],c=v.urlFrom(l);console.assert(a===c,"Should round trip"),r=a;const h=await t.p_rawfetch(r);return console.assert(h.toString()===i,"Should fetch block stored above"),t}catch(e){throw console.log("Exception thrown in TransportIPFS.test:",e.message),e}}}m._transportclasses.IPFS=v,t=e.exports=v}).call(this,n(8),n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(678),i=n(679),o=n(15),s=n(31),a=n(51),l=n(200),u=n(22),c=n(27),h=n(400),f=n(60),p=n(115),d=n(56),m=n(9),g=n(4),y=n(89),v=n(6),b=n(828),_=n(829),w=n(870),k=n(1254),E=n(1255),S=n(1259),x=n(1260);class C extends v{constructor(e){super();const t={init:!0,start:!0,EXPERIMENTAL:{},preload:{enabled:!0,addresses:["/dnsaddr/node0.preload.ipfs.io/https","/dnsaddr/node1.preload.ipfs.io/https"]}};e=b.validate(e||{}),this._options=y(t,e),!1===e.init&&(this._options.init=!1),!1!==e.start&&(this._options.start=!0),"string"==typeof e.repo||void 0===e.repo?this._repo=k(e.repo):this._repo=e.repo,this.log=g("ipfs"),this.log.err=g("ipfs:err"),this._peerInfoBook=new h,this._peerInfo=void 0,this._bitswap=void 0,this._blockService=new r(this._repo),this._ipld=new i(x(this._blockService,this._options.ipld,this.log)),this._preload=E(this),this._mfsPreload=S(this),this._ipns=void 0,this._print=this._options.silent?this.log:console.log,this.init=w.init(this),this.preStart=w.preStart(this),this.start=w.start(this),this.stop=w.stop(this),this.shutdown=this.stop,this.isOnline=w.isOnline(this),Object.assign(this,w.filesRegular(this)),this.version=w.version(this),this.id=w.id(this),this.repo=w.repo(this),this.bootstrap=w.bootstrap(this),this.config=w.config(this),this.block=w.block(this),this.object=w.object(this),this.dag=w.dag(this),this.files=w.filesMFS(this),this.libp2p=null,this.swarm=w.swarm(this),this.name=w.name(this),this.bitswap=w.bitswap(this),this.pin=w.pin(this),this.ping=w.ping(this),this.pingPullStream=w.pingPullStream(this),this.pingReadableStream=w.pingReadableStream(this),this.pubsub=w.pubsub(this),this.dht=w.dht(this),this.dns=w.dns(this),this.key=w.key(this),this.stats=w.stats(this),this.resolve=w.resolve(this),this._options.EXPERIMENTAL.pubsub&&this.log("EXPERIMENTAL pubsub is enabled"),this._options.EXPERIMENTAL.ipnsPubsub&&(this._options.EXPERIMENTAL.pubsub||(this.log("EXPERIMENTAL pubsub is enabled to use IPNS pubsub"),this._options.EXPERIMENTAL.pubsub=!0),this.log("EXPERIMENTAL IPNS pubsub is enabled")),this._options.EXPERIMENTAL.sharding&&this.log("EXPERIMENTAL sharding is enabled"),this.state=n(1261)(this),_(this)}}e.exports=C;const A=t;Object.assign(e.exports,{crypto:a,isIPFS:l,Buffer:A,CID:m,multiaddr:u,multibase:f,multihash:c,multihashing:d,multicodec:p,PeerId:o,PeerInfo:s}),e.exports.createNode=(e=>new C(e))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(59);class i{constructor(e){this._repo=e,this._bitswap=null}setExchange(e){this._bitswap=e}unsetExchange(){this._bitswap=null}hasExchange(){return null!=this._bitswap}put(e,t){this.hasExchange()?this._bitswap.put(e,t):this._repo.blocks.put(e,t)}putMany(e,t){this.hasExchange()?this._bitswap.putMany(e,t):this._repo.blocks.putMany(e,t)}get(e,t){this.hasExchange()?this._bitswap.get(e,t):this._repo.blocks.get(e,t)}getMany(e,t){Array.isArray(e)?this.hasExchange()?this._bitswap.getMany(e,t):r(e,(e,t)=>this._repo.blocks.get(e,t),t):t(new Error("first arg must be an array of cids"))}delete(e,t){this._repo.blocks.delete(e,t)}}e.exports=i},function(e,t,n){"use strict";const r=n(114),i=n(19),o=n(9),s=n(347),a=n(54).join,l=n(54).sep,u=n(61).source,c=n(350),h=n(59),f=n(10),p=n(89),d=n(189),m=n(34),g=n(367);function y(){}class v{constructor(e){const t=p(v.defaultOptions,e);if(!t.blockService)throw new Error("Missing blockservice");this.bs=t.blockService,this.resolvers={},this.support={},this.support.add=((e,t,n)=>{if(this.resolvers[e])throw new Error('Resolver already exists for codec "'+e+'"');this.resolvers[e]={resolver:t,util:n}}),this.support.load=t.loadFormat||((e,t)=>{t(new Error(`No resolver found for codec "${e}"`))}),this.support.rm=(e=>{this.resolvers[e]&&delete this.resolvers[e]});for(const e of t.formats){const{resolver:t,util:n}=e,r=t.multicodec;this.support.add(r,t,n)}}get(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n={}),"string"==typeof t&&(t=a("/",t).substr(1).split(l).join("/")),""===t||!t)return this._get(e,(t,n)=>{if(t)return r(t);r(null,{value:n,remainderPath:"",cid:e})});let i;s(n=>{this._getFormat(e.codec,(r,o)=>{if(r)return n(r);this.bs.get(e,(e,r)=>{if(e)return n(e);o.resolver.resolve(r.data,t,(e,r)=>{if(e)return n(e);i=r.value,t=r.remainderPath,n()})})})},()=>{const r=!t||""===t||"/"===t,o=i&&!v._maybeCID(i);return r&&o||n.localResolve?(e=v._maybeCID(i)||e,!0):(i=v._maybeCID(i),i&&(e=i),!1)},(n,o)=>n?r(n):r(null,{value:i,remainderPath:t,cid:e}))}getStream(e,t,n){const r=u();return this.get(e,t,n,(e,t)=>{if(e)return r.resolve(i.error(e));r.resolve(i.values([t]))}),r}getMany(e,t){if(!Array.isArray(e))return t(new Error("Argument must be an array of CIDs"));this.bs.getMany(e,(e,n)=>{if(e)return t(e);h(n,(e,t)=>{this._getFormat(e.cid.codec,(n,r)=>{if(n)return t(n);r.util.deserialize(e.data,t)})},t)})}put(e,t,n){return"function"==typeof t?(n=t,setImmediate(()=>n(new Error("IPLDResolver.put requires options")))):(n=n||y,t.cid&&o.isCID(t.cid)?t.onlyHash?setImmediate(()=>n(null,t.cid)):this._put(t.cid,e,n):void this._getFormat(t.format,(r,i)=>{if(r)return n(r);i.util.cid(e,t,(r,i)=>r?n(r):t.onlyHash?n(null,i):void this._put(i,e,n))}))}treeStream(e,t,n){let r;return"object"==typeof t&&(n=t,t=void 0),n=n||{},n.recursive||(r=u(),f([t=>this._getFormat(e.codec,t),(t,n)=>this.bs.get(e,(e,r)=>{if(e)return n(e);n(null,t,r)}),(e,t,n)=>e.resolver.tree(t.data,n)],(e,t)=>{if(e)return r.abort(e),r;r.resolve(i.values(t))})),n.recursive&&(r=i(c.widthFirst({basePath:null,cid:e},e=>{if("string"==typeof e)return i.empty();const t=u(),n=e.cid;return f([e=>this._getFormat(n.codec,e),(e,t)=>this.bs.get(n,(n,r)=>{if(n)return t(n);t(null,e,r)}),(e,t,n)=>e.resolver.tree(t.data,(r,i)=>{if(r)return n(r);h(i,(n,r)=>{e.resolver.isLink(t.data,n,(e,t)=>{if(e)return r(e);r(null,{path:n,link:t})})},n)})],(n,r)=>{if(n)return t.abort(n),t;t.resolve(i.values(r.map(t=>{const n=e.basePath?e.basePath+"/"+t.path:t.path;return t.link?{basePath:n,cid:v._maybeCID(t.link)}:n})))}),t}),i.map(e=>"string"==typeof e?e:e.basePath),i.filter(Boolean))),t?i(r,i.map(e=>{if(0===e.indexOf(t))return e=e.slice(t.length+1),e}),i.filter(Boolean)):r}remove(e,t){this.bs.delete(e,t)}_get(e,t){f([t=>this._getFormat(e.codec,t),(t,n)=>this.bs.get(e,(e,r)=>{if(e)return n(e);n(null,t,r)}),(e,t,n)=>{e.util.deserialize(t.data,(e,t)=>{if(e)return n(e);n(null,t)})}],t)}_getFormat(e,t){if(this.resolvers[e])return t(null,this.resolvers[e]);this.support.load(e,(n,r)=>{if(n)return t(n);this.resolvers[e]=r,t(null,r)})}_put(e,t,n){n=n||y,f([t=>this._getFormat(e.codec,t),(e,n)=>e.util.serialize(t,n),(t,n)=>this.bs.put(new r(t,e),n)],t=>{if(t)return n(t);n(null,e)})}static _maybeCID(e){return o.isCID(e)?e:e&&void 0!==e["/"]?new o(e["/"]):null}}v.defaultOptions={formats:[d,m,g]},e.exports=v},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(60),o=n(115),s=n(95),a=n(695),l=n(39);class u{constructor(e,n,s,a){if(c.isCID(e)){const n=e;return this.version=n.version,this.codec=n.codec,this.multihash=t.from(n.multihash),void(this.multibaseName=n.multibaseName||(0===n.version?"base58btc":"base32"))}if("string"==typeof e){const t=i.isEncoded(e);if(t){const n=i.decode(e);this.version=parseInt(n.slice(0,1).toString("hex"),16),this.codec=o.getCodec(n.slice(1)),this.multihash=o.rmPrefix(n.slice(1)),this.multibaseName=t}else this.version=0,this.codec="dag-pb",this.multihash=r.fromB58String(e),this.multibaseName="base58btc";return u.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(t.isBuffer(e)){const t=e.slice(0,1),n=parseInt(t.toString("hex"),16);if(1===n){const t=e;this.version=n,this.codec=o.getCodec(t.slice(1)),this.multihash=o.rmPrefix(t.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";u.validateCID(this)}else this.version=e,this.codec=n,this.multihash=s,this.multibaseName=a||(0===e?"base58btc":"base32"),u.validateCID(this)}get buffer(){let e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=t.concat([t.from("01","hex"),o.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}get prefix(){return t.concat([t.from(`0${this.version}`,"hex"),o.getCodeVarint(this.codec),r.prefix(this.multihash)])}toV0(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");const{name:e,length:t}=r.decode(this.multihash);if("sha2-256"!==e)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==t)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new c(0,this.codec,this.multihash)}toV1(){return new c(1,this.codec,this.multihash)}toBaseEncodedString(e=this.multibaseName){if(this.string&&e===this.multibaseName)return this.string;let t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=r.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=i.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}toString(e){return this.toBaseEncodedString(e)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}static validateCID(e){let t=a.checkCIDComponents(e);if(t)throw new Error(t)}}const c=l(u,{className:"CID",symbolName:"@ipld/js-cid/CID"});c.codecs=s,e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){const r=n(5).Buffer;e.exports=function e(t){if(t.length>=255)throw new TypeError("Alphabet too long");const n=new Uint8Array(256);n.fill(255);for(let e=0;e<t.length;e++){const r=t.charAt(e),i=r.charCodeAt(0);if(255!==n[i])throw new TypeError(r+" is ambiguous");n[i]=e}const i=t.length,o=t.charAt(0),s=Math.log(i)/Math.log(256),a=Math.log(256)/Math.log(i);function l(e){if(!r.isBuffer(e))throw new TypeError("Expected Buffer");if(0===e.length)return"";let n=0,s=0,l=0;const u=e.length;for(;l!==u&&0===e[l];)l++,n++;const c=(u-l)*a+1>>>0,h=new Uint8Array(c);for(;l!==u;){let t=e[l],n=0;for(let e=c-1;(0!==t||n<s)&&-1!==e;e--,n++)t+=256*h[e]>>>0,h[e]=t%i>>>0,t=t/i>>>0;if(0!==t)throw new Error("Non-zero carry");s=n,l++}let f=c-s;for(;f!==c&&0===h[f];)f++;let p=o.repeat(n);for(;f<c;++f)p+=t.charAt(h[f]);return p}function u(e){if("string"!=typeof e)throw new TypeError("Expected String");if(0===e.length)return r.alloc(0);let t=0;if(" "===e[t])return;let a=0,l=0;for(;e[t]===o;)a++,t++;const u=(e.length-t)*s+1>>>0,c=new Uint8Array(u);for(;e[t];){let r=n[e.charCodeAt(t)];if(255===r)return;let o=0;for(let e=u-1;(0!==r||o<l)&&-1!==e;e--,o++)r+=i*c[e]>>>0,c[e]=r%256>>>0,r=r/256>>>0;if(0!==r)throw new Error("Non-zero carry");l=o,t++}if(" "===e[t])return;let h=u-l;for(;h!==u&&0===c[h];)h++;const f=r.allocUnsafe(a+(u-h));f.fill(0,0,a);let p=a;for(;h!==u;)f[p++]=c[h++];return f}function c(e){const t=u(e);if(t)return t;throw new Error("Non-base"+i+" character")}return{encode:l,decodeUnsafe:u,decode:c}}},function(e,t,n){"use strict";t.names=Object.freeze({id:0,sha1:17,"sha2-256":18,"sha2-512":19,"dbl-sha2-256":86,"sha3-224":23,"sha3-256":22,"sha3-384":21,"sha3-512":20,"shake-128":24,"shake-256":25,"keccak-224":26,"keccak-256":27,"keccak-384":28,"keccak-512":29,"murmur3-128":34,"murmur3-32":35,"blake2b-8":45569,"blake2b-16":45570,"blake2b-24":45571,"blake2b-32":45572,"blake2b-40":45573,"blake2b-48":45574,"blake2b-56":45575,"blake2b-64":45576,"blake2b-72":45577,"blake2b-80":45578,"blake2b-88":45579,"blake2b-96":45580,"blake2b-104":45581,"blake2b-112":45582,"blake2b-120":45583,"blake2b-128":45584,"blake2b-136":45585,"blake2b-144":45586,"blake2b-152":45587,"blake2b-160":45588,"blake2b-168":45589,"blake2b-176":45590,"blake2b-184":45591,"blake2b-192":45592,"blake2b-200":45593,"blake2b-208":45594,"blake2b-216":45595,"blake2b-224":45596,"blake2b-232":45597,"blake2b-240":45598,"blake2b-248":45599,"blake2b-256":45600,"blake2b-264":45601,"blake2b-272":45602,"blake2b-280":45603,"blake2b-288":45604,"blake2b-296":45605,"blake2b-304":45606,"blake2b-312":45607,"blake2b-320":45608,"blake2b-328":45609,"blake2b-336":45610,"blake2b-344":45611,"blake2b-352":45612,"blake2b-360":45613,"blake2b-368":45614,"blake2b-376":45615,"blake2b-384":45616,"blake2b-392":45617,"blake2b-400":45618,"blake2b-408":45619,"blake2b-416":45620,"blake2b-424":45621,"blake2b-432":45622,"blake2b-440":45623,"blake2b-448":45624,"blake2b-456":45625,"blake2b-464":45626,"blake2b-472":45627,"blake2b-480":45628,"blake2b-488":45629,"blake2b-496":45630,"blake2b-504":45631,"blake2b-512":45632,"blake2s-8":45633,"blake2s-16":45634,"blake2s-24":45635,"blake2s-32":45636,"blake2s-40":45637,"blake2s-48":45638,"blake2s-56":45639,"blake2s-64":45640,"blake2s-72":45641,"blake2s-80":45642,"blake2s-88":45643,"blake2s-96":45644,"blake2s-104":45645,"blake2s-112":45646,"blake2s-120":45647,"blake2s-128":45648,"blake2s-136":45649,"blake2s-144":45650,"blake2s-152":45651,"blake2s-160":45652,"blake2s-168":45653,"blake2s-176":45654,"blake2s-184":45655,"blake2s-192":45656,"blake2s-200":45657,"blake2s-208":45658,"blake2s-216":45659,"blake2s-224":45660,"blake2s-232":45661,"blake2s-240":45662,"blake2s-248":45663,"blake2s-256":45664,"Skein256-8":45825,"Skein256-16":45826,"Skein256-24":45827,"Skein256-32":45828,"Skein256-40":45829,"Skein256-48":45830,"Skein256-56":45831,"Skein256-64":45832,"Skein256-72":45833,"Skein256-80":45834,"Skein256-88":45835,"Skein256-96":45836,"Skein256-104":45837,"Skein256-112":45838,"Skein256-120":45839,"Skein256-128":45840,"Skein256-136":45841,"Skein256-144":45842,"Skein256-152":45843,"Skein256-160":45844,"Skein256-168":45845,"Skein256-176":45846,"Skein256-184":45847,"Skein256-192":45848,"Skein256-200":45849,"Skein256-208":45850,"Skein256-216":45851,"Skein256-224":45852,"Skein256-232":45853,"Skein256-240":45854,"Skein256-248":45855,"Skein256-256":45856,"Skein512-8":45857,"Skein512-16":45858,"Skein512-24":45859,"Skein512-32":45860,"Skein512-40":45861,"Skein512-48":45862,"Skein512-56":45863,"Skein512-64":45864,"Skein512-72":45865,"Skein512-80":45866,"Skein512-88":45867,"Skein512-96":45868,"Skein512-104":45869,"Skein512-112":45870,"Skein512-120":45871,"Skein512-128":45872,"Skein512-136":45873,"Skein512-144":45874,"Skein512-152":45875,"Skein512-160":45876,"Skein512-168":45877,"Skein512-176":45878,"Skein512-184":45879,"Skein512-192":45880,"Skein512-200":45881,"Skein512-208":45882,"Skein512-216":45883,"Skein512-224":45884,"Skein512-232":45885,"Skein512-240":45886,"Skein512-248":45887,"Skein512-256":45888,"Skein512-264":45889,"Skein512-272":45890,"Skein512-280":45891,"Skein512-288":45892,"Skein512-296":45893,"Skein512-304":45894,"Skein512-312":45895,"Skein512-320":45896,"Skein512-328":45897,"Skein512-336":45898,"Skein512-344":45899,"Skein512-352":45900,"Skein512-360":45901,"Skein512-368":45902,"Skein512-376":45903,"Skein512-384":45904,"Skein512-392":45905,"Skein512-400":45906,"Skein512-408":45907,"Skein512-416":45908,"Skein512-424":45909,"Skein512-432":45910,"Skein512-440":45911,"Skein512-448":45912,"Skein512-456":45913,"Skein512-464":45914,"Skein512-472":45915,"Skein512-480":45916,"Skein512-488":45917,"Skein512-496":45918,"Skein512-504":45919,"Skein512-512":45920,"Skein1024-8":45921,"Skein1024-16":45922,"Skein1024-24":45923,"Skein1024-32":45924,"Skein1024-40":45925,"Skein1024-48":45926,"Skein1024-56":45927,"Skein1024-64":45928,"Skein1024-72":45929,"Skein1024-80":45930,"Skein1024-88":45931,"Skein1024-96":45932,"Skein1024-104":45933,"Skein1024-112":45934,"Skein1024-120":45935,"Skein1024-128":45936,"Skein1024-136":45937,"Skein1024-144":45938,"Skein1024-152":45939,"Skein1024-160":45940,"Skein1024-168":45941,"Skein1024-176":45942,"Skein1024-184":45943,"Skein1024-192":45944,"Skein1024-200":45945,"Skein1024-208":45946,"Skein1024-216":45947,"Skein1024-224":45948,"Skein1024-232":45949,"Skein1024-240":45950,"Skein1024-248":45951,"Skein1024-256":45952,"Skein1024-264":45953,"Skein1024-272":45954,"Skein1024-280":45955,"Skein1024-288":45956,"Skein1024-296":45957,"Skein1024-304":45958,"Skein1024-312":45959,"Skein1024-320":45960,"Skein1024-328":45961,"Skein1024-336":45962,"Skein1024-344":45963,"Skein1024-352":45964,"Skein1024-360":45965,"Skein1024-368":45966,"Skein1024-376":45967,"Skein1024-384":45968,"Skein1024-392":45969,"Skein1024-400":45970,"Skein1024-408":45971,"Skein1024-416":45972,"Skein1024-424":45973,"Skein1024-432":45974,"Skein1024-440":45975,"Skein1024-448":45976,"Skein1024-456":45977,"Skein1024-464":45978,"Skein1024-472":45979,"Skein1024-480":45980,"Skein1024-488":45981,"Skein1024-496":45982,"Skein1024-504":45983,"Skein1024-512":45984,"Skein1024-520":45985,"Skein1024-528":45986,"Skein1024-536":45987,"Skein1024-544":45988,"Skein1024-552":45989,"Skein1024-560":45990,"Skein1024-568":45991,"Skein1024-576":45992,"Skein1024-584":45993,"Skein1024-592":45994,"Skein1024-600":45995,"Skein1024-608":45996,"Skein1024-616":45997,"Skein1024-624":45998,"Skein1024-632":45999,"Skein1024-640":46e3,"Skein1024-648":46001,"Skein1024-656":46002,"Skein1024-664":46003,"Skein1024-672":46004,"Skein1024-680":46005,"Skein1024-688":46006,"Skein1024-696":46007,"Skein1024-704":46008,"Skein1024-712":46009,"Skein1024-720":46010,"Skein1024-728":46011,"Skein1024-736":46012,"Skein1024-744":46013,"Skein1024-752":46014,"Skein1024-760":46015,"Skein1024-768":46016,"Skein1024-776":46017,"Skein1024-784":46018,"Skein1024-792":46019,"Skein1024-800":46020,"Skein1024-808":46021,"Skein1024-816":46022,"Skein1024-824":46023,"Skein1024-832":46024,"Skein1024-840":46025,"Skein1024-848":46026,"Skein1024-856":46027,"Skein1024-864":46028,"Skein1024-872":46029,"Skein1024-880":46030,"Skein1024-888":46031,"Skein1024-896":46032,"Skein1024-904":46033,"Skein1024-912":46034,"Skein1024-920":46035,"Skein1024-928":46036,"Skein1024-936":46037,"Skein1024-944":46038,"Skein1024-952":46039,"Skein1024-960":46040,"Skein1024-968":46041,"Skein1024-976":46042,"Skein1024-984":46043,"Skein1024-992":46044,"Skein1024-1000":46045,"Skein1024-1008":46046,"Skein1024-1016":46047,"Skein1024-1024":46048}),t.codes=Object.freeze({17:"sha1",18:"sha2-256",19:"sha2-512",86:"dbl-sha2-256",23:"sha3-224",22:"sha3-256",21:"sha3-384",20:"sha3-512",24:"shake-128",25:"shake-256",26:"keccak-224",27:"keccak-256",28:"keccak-384",29:"keccak-512",34:"murmur3-128",35:"murmur3-32",45569:"blake2b-8",45570:"blake2b-16",45571:"blake2b-24",45572:"blake2b-32",45573:"blake2b-40",45574:"blake2b-48",45575:"blake2b-56",45576:"blake2b-64",45577:"blake2b-72",45578:"blake2b-80",45579:"blake2b-88",45580:"blake2b-96",45581:"blake2b-104",45582:"blake2b-112",45583:"blake2b-120",45584:"blake2b-128",45585:"blake2b-136",45586:"blake2b-144",45587:"blake2b-152",45588:"blake2b-160",45589:"blake2b-168",45590:"blake2b-176",45591:"blake2b-184",45592:"blake2b-192",45593:"blake2b-200",45594:"blake2b-208",45595:"blake2b-216",45596:"blake2b-224",45597:"blake2b-232",45598:"blake2b-240",45599:"blake2b-248",45600:"blake2b-256",45601:"blake2b-264",45602:"blake2b-272",45603:"blake2b-280",45604:"blake2b-288",45605:"blake2b-296",45606:"blake2b-304",45607:"blake2b-312",45608:"blake2b-320",45609:"blake2b-328",45610:"blake2b-336",45611:"blake2b-344",45612:"blake2b-352",45613:"blake2b-360",45614:"blake2b-368",45615:"blake2b-376",45616:"blake2b-384",45617:"blake2b-392",45618:"blake2b-400",45619:"blake2b-408",45620:"blake2b-416",45621:"blake2b-424",45622:"blake2b-432",45623:"blake2b-440",45624:"blake2b-448",45625:"blake2b-456",45626:"blake2b-464",45627:"blake2b-472",45628:"blake2b-480",45629:"blake2b-488",45630:"blake2b-496",45631:"blake2b-504",45632:"blake2b-512",45633:"blake2s-8",45634:"blake2s-16",45635:"blake2s-24",45636:"blake2s-32",45637:"blake2s-40",45638:"blake2s-48",45639:"blake2s-56",45640:"blake2s-64",45641:"blake2s-72",45642:"blake2s-80",45643:"blake2s-88",45644:"blake2s-96",45645:"blake2s-104",45646:"blake2s-112",45647:"blake2s-120",45648:"blake2s-128",45649:"blake2s-136",45650:"blake2s-144",45651:"blake2s-152",45652:"blake2s-160",45653:"blake2s-168",45654:"blake2s-176",45655:"blake2s-184",45656:"blake2s-192",45657:"blake2s-200",45658:"blake2s-208",45659:"blake2s-216",45660:"blake2s-224",45661:"blake2s-232",45662:"blake2s-240",45663:"blake2s-248",45664:"blake2s-256",45825:"Skein256-8",45826:"Skein256-16",45827:"Skein256-24",45828:"Skein256-32",45829:"Skein256-40",45830:"Skein256-48",45831:"Skein256-56",45832:"Skein256-64",45833:"Skein256-72",45834:"Skein256-80",45835:"Skein256-88",45836:"Skein256-96",45837:"Skein256-104",45838:"Skein256-112",45839:"Skein256-120",45840:"Skein256-128",45841:"Skein256-136",45842:"Skein256-144",45843:"Skein256-152",45844:"Skein256-160",45845:"Skein256-168",45846:"Skein256-176",45847:"Skein256-184",45848:"Skein256-192",45849:"Skein256-200",45850:"Skein256-208",45851:"Skein256-216",45852:"Skein256-224",45853:"Skein256-232",45854:"Skein256-240",45855:"Skein256-248",45856:"Skein256-256",45857:"Skein512-8",45858:"Skein512-16",45859:"Skein512-24",45860:"Skein512-32",45861:"Skein512-40",45862:"Skein512-48",45863:"Skein512-56",45864:"Skein512-64",45865:"Skein512-72",45866:"Skein512-80",45867:"Skein512-88",45868:"Skein512-96",45869:"Skein512-104",45870:"Skein512-112",45871:"Skein512-120",45872:"Skein512-128",45873:"Skein512-136",45874:"Skein512-144",45875:"Skein512-152",45876:"Skein512-160",45877:"Skein512-168",45878:"Skein512-176",45879:"Skein512-184",45880:"Skein512-192",45881:"Skein512-200",45882:"Skein512-208",45883:"Skein512-216",45884:"Skein512-224",45885:"Skein512-232",45886:"Skein512-240",45887:"Skein512-248",45888:"Skein512-256",45889:"Skein512-264",45890:"Skein512-272",45891:"Skein512-280",45892:"Skein512-288",45893:"Skein512-296",45894:"Skein512-304",45895:"Skein512-312",45896:"Skein512-320",45897:"Skein512-328",45898:"Skein512-336",45899:"Skein512-344",45900:"Skein512-352",45901:"Skein512-360",45902:"Skein512-368",45903:"Skein512-376",45904:"Skein512-384",45905:"Skein512-392",45906:"Skein512-400",45907:"Skein512-408",45908:"Skein512-416",45909:"Skein512-424",45910:"Skein512-432",45911:"Skein512-440",45912:"Skein512-448",45913:"Skein512-456",45914:"Skein512-464",45915:"Skein512-472",45916:"Skein512-480",45917:"Skein512-488",45918:"Skein512-496",45919:"Skein512-504",45920:"Skein512-512",45921:"Skein1024-8",45922:"Skein1024-16",45923:"Skein1024-24",45924:"Skein1024-32",45925:"Skein1024-40",45926:"Skein1024-48",45927:"Skein1024-56",45928:"Skein1024-64",45929:"Skein1024-72",45930:"Skein1024-80",45931:"Skein1024-88",45932:"Skein1024-96",45933:"Skein1024-104",45934:"Skein1024-112",45935:"Skein1024-120",45936:"Skein1024-128",45937:"Skein1024-136",45938:"Skein1024-144",45939:"Skein1024-152",45940:"Skein1024-160",45941:"Skein1024-168",45942:"Skein1024-176",45943:"Skein1024-184",45944:"Skein1024-192",45945:"Skein1024-200",45946:"Skein1024-208",45947:"Skein1024-216",45948:"Skein1024-224",45949:"Skein1024-232",45950:"Skein1024-240",45951:"Skein1024-248",45952:"Skein1024-256",45953:"Skein1024-264",45954:"Skein1024-272",45955:"Skein1024-280",45956:"Skein1024-288",45957:"Skein1024-296",45958:"Skein1024-304",45959:"Skein1024-312",45960:"Skein1024-320",45961:"Skein1024-328",45962:"Skein1024-336",45963:"Skein1024-344",45964:"Skein1024-352",45965:"Skein1024-360",45966:"Skein1024-368",45967:"Skein1024-376",45968:"Skein1024-384",45969:"Skein1024-392",45970:"Skein1024-400",45971:"Skein1024-408",45972:"Skein1024-416",45973:"Skein1024-424",45974:"Skein1024-432",45975:"Skein1024-440",45976:"Skein1024-448",45977:"Skein1024-456",45978:"Skein1024-464",45979:"Skein1024-472",45980:"Skein1024-480",45981:"Skein1024-488",45982:"Skein1024-496",45983:"Skein1024-504",45984:"Skein1024-512",45985:"Skein1024-520",45986:"Skein1024-528",45987:"Skein1024-536",45988:"Skein1024-544",45989:"Skein1024-552",45990:"Skein1024-560",45991:"Skein1024-568",45992:"Skein1024-576",45993:"Skein1024-584",45994:"Skein1024-592",45995:"Skein1024-600",45996:"Skein1024-608",45997:"Skein1024-616",45998:"Skein1024-624",45999:"Skein1024-632",46000:"Skein1024-640",46001:"Skein1024-648",46002:"Skein1024-656",46003:"Skein1024-664",46004:"Skein1024-672",46005:"Skein1024-680",46006:"Skein1024-688",46007:"Skein1024-696",46008:"Skein1024-704",46009:"Skein1024-712",46010:"Skein1024-720",46011:"Skein1024-728",46012:"Skein1024-736",46013:"Skein1024-744",46014:"Skein1024-752",46015:"Skein1024-760",46016:"Skein1024-768",46017:"Skein1024-776",46018:"Skein1024-784",46019:"Skein1024-792",46020:"Skein1024-800",46021:"Skein1024-808",46022:"Skein1024-816",46023:"Skein1024-824",46024:"Skein1024-832",46025:"Skein1024-840",46026:"Skein1024-848",46027:"Skein1024-856",46028:"Skein1024-864",46029:"Skein1024-872",46030:"Skein1024-880",46031:"Skein1024-888",46032:"Skein1024-896",46033:"Skein1024-904",46034:"Skein1024-912",46035:"Skein1024-920",46036:"Skein1024-928",46037:"Skein1024-936",46038:"Skein1024-944",46039:"Skein1024-952",46040:"Skein1024-960",46041:"Skein1024-968",46042:"Skein1024-976",46043:"Skein1024-984",46044:"Skein1024-992",46045:"Skein1024-1000",46046:"Skein1024-1008",46047:"Skein1024-1016",46048:"Skein1024-1024"}),t.defaultLengths=Object.freeze({17:20,18:32,19:64,86:32,23:28,22:32,21:48,20:64,24:32,25:64,26:28,27:32,28:48,29:64,34:32,45569:1,45570:2,45571:3,45572:4,45573:5,45574:6,45575:7,45576:8,45577:9,45578:10,45579:11,45580:12,45581:13,45582:14,45583:15,45584:16,45585:17,45586:18,45587:19,45588:20,45589:21,45590:22,45591:23,45592:24,45593:25,45594:26,45595:27,45596:28,45597:29,45598:30,45599:31,45600:32,45601:33,45602:34,45603:35,45604:36,45605:37,45606:38,45607:39,45608:40,45609:41,45610:42,45611:43,45612:44,45613:45,45614:46,45615:47,45616:48,45617:49,45618:50,45619:51,45620:52,45621:53,45622:54,45623:55,45624:56,45625:57,45626:58,45627:59,45628:60,45629:61,45630:62,45631:63,45632:64,45633:1,45634:2,45635:3,45636:4,45637:5,45638:6,45639:7,45640:8,45641:9,45642:10,45643:11,45644:12,45645:13,45646:14,45647:15,45648:16,45649:17,45650:18,45651:19,45652:20,45653:21,45654:22,45655:23,45656:24,45657:25,45658:26,45659:27,45660:28,45661:29,45662:30,45663:31,45664:32,45825:1,45826:2,45827:3,45828:4,45829:5,45830:6,45831:7,45832:8,45833:9,45834:10,45835:11,45836:12,45837:13,45838:14,45839:15,45840:16,45841:17,45842:18,45843:19,45844:20,45845:21,45846:22,45847:23,45848:24,45849:25,45850:26,45851:27,45852:28,45853:29,45854:30,45855:31,45856:32,45857:1,45858:2,45859:3,45860:4,45861:5,45862:6,45863:7,45864:8,45865:9,45866:10,45867:11,45868:12,45869:13,45870:14,45871:15,45872:16,45873:17,45874:18,45875:19,45876:20,45877:21,45878:22,45879:23,45880:24,45881:25,45882:26,45883:27,45884:28,45885:29,45886:30,45887:31,45888:32,45889:33,45890:34,45891:35,45892:36,45893:37,45894:38,45895:39,45896:40,45897:41,45898:42,45899:43,45900:44,45901:45,45902:46,45903:47,45904:48,45905:49,45906:50,45907:51,45908:52,45909:53,45910:54,45911:55,45912:56,45913:57,45914:58,45915:59,45916:60,45917:61,45918:62,45919:63,45920:64,45921:1,45922:2,45923:3,45924:4,45925:5,45926:6,45927:7,45928:8,45929:9,45930:10,45931:11,45932:12,45933:13,45934:14,45935:15,45936:16,45937:17,45938:18,45939:19,45940:20,45941:21,45942:22,45943:23,45944:24,45945:25,45946:26,45947:27,45948:28,45949:29,45950:30,45951:31,45952:32,45953:33,45954:34,45955:35,45956:36,45957:37,45958:38,45959:39,45960:40,45961:41,45962:42,45963:43,45964:44,45965:45,45966:46,45967:47,45968:48,45969:49,45970:50,45971:51,45972:52,45973:53,45974:54,45975:55,45976:56,45977:57,45978:58,45979:59,45980:60,45981:61,45982:62,45983:63,45984:64,45985:65,45986:66,45987:67,45988:68,45989:69,45990:70,45991:71,45992:72,45993:73,45994:74,45995:75,45996:76,45997:77,45998:78,45999:79,46000:80,46001:81,46002:82,46003:83,46004:84,46005:85,46006:86,46007:87,46008:88,46009:89,46010:90,46011:91,46012:92,46013:93,46014:94,46015:95,46016:96,46017:97,46018:98,46019:99,46020:100,46021:101,46022:102,46023:103,46024:104,46025:105,46026:106,46027:107,46028:108,46029:109,46030:110,46031:111,46032:112,46033:113,46034:114,46035:115,46036:116,46037:117,46038:118,46039:119,46040:120,46041:121,46042:122,46043:123,46044:124,46045:125,46046:126,46047:127,46048:128})},function(e,t){e.exports=s;var n=128,r=127,i=-128,o=Math.pow(2,31);function s(e,t,r){t=t||[],r=r||0;for(var a=r;e>=o;)t[r++]=255&e|n,e/=128;for(;e&i;)t[r++]=255&e|n,e>>>=7;return t[r]=0|e,s.bytes=r-a+1,t}},function(e,t){e.exports=i;var n=128,r=127;function i(e,t){var o=0,t=t||0,s=0,a=t,l,u=e.length;do{if(a>=u)throw i.bytes=0,new RangeError("Could not decode varint");l=e[a++],o+=s<28?(l&r)<<s:(l&r)*Math.pow(2,s),s+=7}while(l>=n);return i.bytes=a-t,o}},function(e,t){var n=Math.pow(2,7),r=Math.pow(2,14),i=Math.pow(2,21),o=Math.pow(2,28),s=Math.pow(2,35),a=Math.pow(2,42),l=Math.pow(2,49),u=Math.pow(2,56),c=Math.pow(2,63);e.exports=function(e){return e<n?1:e<r?2:e<i?3:e<o?4:e<s?5:e<a?6:e<l?7:e<u?8:e<c?9:10}},function(e,t,n){"use strict";const r=n(687),i=n(688),o=n(689),s=n(690),a=n(691),l=[["base1","1","","1"],["base2","0",i,"01"],["base8","7",i,"01234567"],["base10","9",i,"0123456789"],["base16","f",o,"0123456789abcdef"],["base32","b",s,"abcdefghijklmnopqrstuvwxyz234567"],["base32pad","c",s,"abcdefghijklmnopqrstuvwxyz234567="],["base32hex","v",s,"0123456789abcdefghijklmnopqrstuv"],["base32hexpad","t",s,"0123456789abcdefghijklmnopqrstuv="],["base32z","h",s,"ybndrfg8ejkmcpqxot1uwisza345h769"],["base58flickr","Z",i,"123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ"],["base58btc","z",i,"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"],["base64","m",a,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"],["base64pad","M",a,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="],["base64url","u",a,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_"],["base64urlpad","U",a,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_="]],u=l.reduce((e,t)=>(e[t[0]]=new r(t[0],t[1],t[2],t[3]),e),{}),c=l.reduce((e,t)=>(e[t[1]]=u[t[0]],e),{});e.exports={names:u,codes:c}},function(e,t,n){"use strict";class r{constructor(e,t,n,r){this.name=e,this.code=t,this.alphabet=r,n&&r&&(this.engine=n(r))}encode(e){return this.engine.encode(e)}decode(e){return this.engine.decode(e)}isImplemented(){return this.engine}}e.exports=r},function(e,t,n){var r=n(5).Buffer;e.exports=function e(t){for(var n={},i=t.length,o=t.charAt(0),s=0;s<t.length;s++){var a=t.charAt(s);if(void 0!==n[a])throw new TypeError(a+" is ambiguous");n[a]=s}function l(e){if(0===e.length)return"";for(var n=[0],r=0;r<e.length;++r){for(var s=0,a=e[r];s<n.length;++s)a+=n[s]<<8,n[s]=a%i,a=a/i|0;for(;a>0;)n.push(a%i),a=a/i|0}for(var l="",u=0;0===e[u]&&u<e.length-1;++u)l+=o;for(var c=n.length-1;c>=0;--c)l+=t[n[c]];return l}function u(e){if("string"!=typeof e)throw new TypeError("Expected String");if(0===e.length)return r.allocUnsafe(0);for(var t=[0],s=0;s<e.length;s++){var a=n[e[s]];if(void 0===a)return;for(var l=0,u=a;l<t.length;++l)u+=t[l]*i,t[l]=255&u,u>>=8;for(;u>0;)t.push(255&u),u>>=8}for(var c=0;e[c]===o&&c<e.length-1;++c)t.push(0);return r.from(t.reverse())}function c(e){var t=u(e);if(t)return t;throw new Error("Non-base"+i+" character")}return{encode:l,decodeUnsafe:u,decode:c}}},function(e,t,n){"use strict";(function(t){e.exports=function e(n){return{encode:e=>"string"==typeof e?t.from(e).toString("hex"):e.toString("hex"),decode(e){for(let t of e)if(n.indexOf(t)<0)throw new Error("invalid base16 character");return t.from(e,"hex")}}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){function n(e,t){e=e.replace(new RegExp("=","g"),"");let n=e.length,r=0,i=0,o=0,s=new Uint8Array(5*n/8|0);for(let a=0;a<n;a++)i=i<<5|t.indexOf(e[a]),r+=5,r>=8&&(s[o++]=i>>>r-8&255,r-=8);return s.buffer}function r(e,t){let n=e.byteLength,r=new Uint8Array(e),i=t.indexOf("=")===t.length-1;i&&(t=t.substring(0,t.length-2));let o=0,s=0,a="";for(let e=0;e<n;e++)for(s=s<<8|r[e],o+=8;o>=5;)a+=t[s>>>o-5&31],o-=5;if(o>0&&(a+=t[s<<5-o&31]),i)for(;a.length%8!=0;)a+="=";return a}e.exports=function e(i){return{encode:e=>r("string"==typeof e?t.from(e):e,i),decode(e){for(let t of e)if(i.indexOf(t)<0)throw new Error("invalid base32 character");return n(e,i)}}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){e.exports=function e(n){const r=n.indexOf("=")>-1,i=n.indexOf("-")>-1&&n.indexOf("_")>-1;return{encode(e){let n="";n="string"==typeof e?t.from(e).toString("base64"):e.toString("base64"),i&&(n=n.replace(/\+/g,"-").replace(/\//g,"_"));const o=n.indexOf("=");return o>0&&!r&&(n=n.substring(0,o)),n},decode(e){for(let t of e)if(n.indexOf(t)<0)throw new Error("invalid base64 character");return t.from(e,"base64")}}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(95),i=n(341).varintBufferEncode,o={};e.exports=o;for(let e in r){let t=r[e];o[e]=i(t)}},function(e,t,n){"use strict";e.exports=Object.freeze({PROTOBUF:80,CBOR:81,RLP:96,BENCODE:99,MULTICODEC:48,MULTIHASH:49,MULTIADDR:50,MULTIBASE:51,IDENTITY:0,SHA1:17,SHA2_256:18,SHA2_512:19,SHA3_512:20,SHA3_384:21,SHA3_256:22,SHA3_224:23,SHAKE_128:24,SHAKE_256:25,KECCAK_224:26,KECCAK_256:27,KECCAK_384:28,KECCAK_512:29,MURMUR3_128:34,MURMUR3_32:35,DBL_SHA2_256:86,MD4:212,MD5:213,BMT:214,X11:4352,BLAKE2B_8:45569,BLAKE2B_16:45570,BLAKE2B_24:45571,BLAKE2B_32:45572,BLAKE2B_40:45573,BLAKE2B_48:45574,BLAKE2B_56:45575,BLAKE2B_64:45576,BLAKE2B_72:45577,BLAKE2B_80:45578,BLAKE2B_88:45579,BLAKE2B_96:45580,BLAKE2B_104:45581,BLAKE2B_112:45582,BLAKE2B_120:45583,BLAKE2B_128:45584,BLAKE2B_136:45585,BLAKE2B_144:45586,BLAKE2B_152:45587,BLAKE2B_160:45588,BLAKE2B_168:45589,BLAKE2B_176:45590,BLAKE2B_184:45591,BLAKE2B_192:45592,BLAKE2B_200:45593,BLAKE2B_208:45594,BLAKE2B_216:45595,BLAKE2B_224:45596,BLAKE2B_232:45597,BLAKE2B_240:45598,BLAKE2B_248:45599,BLAKE2B_256:45600,BLAKE2B_264:45601,BLAKE2B_272:45602,BLAKE2B_280:45603,BLAKE2B_288:45604,BLAKE2B_296:45605,BLAKE2B_304:45606,BLAKE2B_312:45607,BLAKE2B_320:45608,BLAKE2B_328:45609,BLAKE2B_336:45610,BLAKE2B_344:45611,BLAKE2B_352:45612,BLAKE2B_360:45613,BLAKE2B_368:45614,BLAKE2B_376:45615,BLAKE2B_384:45616,BLAKE2B_392:45617,BLAKE2B_400:45618,BLAKE2B_408:45619,BLAKE2B_416:45620,BLAKE2B_424:45621,BLAKE2B_432:45622,BLAKE2B_440:45623,BLAKE2B_448:45624,BLAKE2B_456:45625,BLAKE2B_464:45626,BLAKE2B_472:45627,BLAKE2B_480:45628,BLAKE2B_488:45629,BLAKE2B_496:45630,BLAKE2B_504:45631,BLAKE2B_512:45632,BLAKE2S_8:45633,BLAKE2S_16:45634,BLAKE2S_24:45635,BLAKE2S_32:45636,BLAKE2S_40:45637,BLAKE2S_48:45638,BLAKE2S_56:45639,BLAKE2S_64:45640,BLAKE2S_72:45641,BLAKE2S_80:45642,BLAKE2S_88:45643,BLAKE2S_96:45644,BLAKE2S_104:45645,BLAKE2S_112:45646,BLAKE2S_120:45647,BLAKE2S_128:45648,BLAKE2S_136:45649,BLAKE2S_144:45650,BLAKE2S_152:45651,BLAKE2S_160:45652,BLAKE2S_168:45653,BLAKE2S_176:45654,BLAKE2S_184:45655,BLAKE2S_192:45656,BLAKE2S_200:45657,BLAKE2S_208:45658,BLAKE2S_216:45659,BLAKE2S_224:45660,BLAKE2S_232:45661,BLAKE2S_240:45662,BLAKE2S_248:45663,BLAKE2S_256:45664,SKEIN256_8:45825,SKEIN256_16:45826,SKEIN256_24:45827,SKEIN256_32:45828,SKEIN256_40:45829,SKEIN256_48:45830,SKEIN256_56:45831,SKEIN256_64:45832,SKEIN256_72:45833,SKEIN256_80:45834,SKEIN256_88:45835,SKEIN256_96:45836,SKEIN256_104:45837,SKEIN256_112:45838,SKEIN256_120:45839,SKEIN256_128:45840,SKEIN256_136:45841,SKEIN256_144:45842,SKEIN256_152:45843,SKEIN256_160:45844,SKEIN256_168:45845,SKEIN256_176:45846,SKEIN256_184:45847,SKEIN256_192:45848,SKEIN256_200:45849,SKEIN256_208:45850,SKEIN256_216:45851,SKEIN256_224:45852,SKEIN256_232:45853,SKEIN256_240:45854,SKEIN256_248:45855,SKEIN256_256:45856,SKEIN512_8:45857,SKEIN512_16:45858,SKEIN512_24:45859,SKEIN512_32:45860,SKEIN512_40:45861,SKEIN512_48:45862,SKEIN512_56:45863,SKEIN512_64:45864,SKEIN512_72:45865,SKEIN512_80:45866,SKEIN512_88:45867,SKEIN512_96:45868,SKEIN512_104:45869,SKEIN512_112:45870,SKEIN512_120:45871,SKEIN512_128:45872,SKEIN512_136:45873,SKEIN512_144:45874,SKEIN512_152:45875,SKEIN512_160:45876,SKEIN512_168:45877,SKEIN512_176:45878,SKEIN512_184:45879,SKEIN512_192:45880,SKEIN512_200:45881,SKEIN512_208:45882,SKEIN512_216:45883,SKEIN512_224:45884,SKEIN512_232:45885,SKEIN512_240:45886,SKEIN512_248:45887,SKEIN512_256:45888,SKEIN512_264:45889,SKEIN512_272:45890,SKEIN512_280:45891,SKEIN512_288:45892,SKEIN512_296:45893,SKEIN512_304:45894,SKEIN512_312:45895,SKEIN512_320:45896,SKEIN512_328:45897,SKEIN512_336:45898,SKEIN512_344:45899,SKEIN512_352:45900,SKEIN512_360:45901,SKEIN512_368:45902,SKEIN512_376:45903,SKEIN512_384:45904,SKEIN512_392:45905,SKEIN512_400:45906,SKEIN512_408:45907,SKEIN512_416:45908,SKEIN512_424:45909,SKEIN512_432:45910,SKEIN512_440:45911,SKEIN512_448:45912,SKEIN512_456:45913,SKEIN512_464:45914,SKEIN512_472:45915,SKEIN512_480:45916,SKEIN512_488:45917,SKEIN512_496:45918,SKEIN512_504:45919,SKEIN512_512:45920,SKEIN1024_8:45921,SKEIN1024_16:45922,SKEIN1024_24:45923,SKEIN1024_32:45924,SKEIN1024_40:45925,SKEIN1024_48:45926,SKEIN1024_56:45927,SKEIN1024_64:45928,SKEIN1024_72:45929,SKEIN1024_80:45930,SKEIN1024_88:45931,SKEIN1024_96:45932,SKEIN1024_104:45933,SKEIN1024_112:45934,SKEIN1024_120:45935,SKEIN1024_128:45936,SKEIN1024_136:45937,SKEIN1024_144:45938,SKEIN1024_152:45939,SKEIN1024_160:45940,SKEIN1024_168:45941,SKEIN1024_176:45942,SKEIN1024_184:45943,SKEIN1024_192:45944,SKEIN1024_200:45945,SKEIN1024_208:45946,SKEIN1024_216:45947,SKEIN1024_224:45948,SKEIN1024_232:45949,SKEIN1024_240:45950,SKEIN1024_248:45951,SKEIN1024_256:45952,SKEIN1024_264:45953,SKEIN1024_272:45954,SKEIN1024_280:45955,SKEIN1024_288:45956,SKEIN1024_296:45957,SKEIN1024_304:45958,SKEIN1024_312:45959,SKEIN1024_320:45960,SKEIN1024_328:45961,SKEIN1024_336:45962,SKEIN1024_344:45963,SKEIN1024_352:45964,SKEIN1024_360:45965,SKEIN1024_368:45966,SKEIN1024_376:45967,SKEIN1024_384:45968,SKEIN1024_392:45969,SKEIN1024_400:45970,SKEIN1024_408:45971,SKEIN1024_416:45972,SKEIN1024_424:45973,SKEIN1024_432:45974,SKEIN1024_440:45975,SKEIN1024_448:45976,SKEIN1024_456:45977,SKEIN1024_464:45978,SKEIN1024_472:45979,SKEIN1024_480:45980,SKEIN1024_488:45981,SKEIN1024_496:45982,SKEIN1024_504:45983,SKEIN1024_512:45984,SKEIN1024_520:45985,SKEIN1024_528:45986,SKEIN1024_536:45987,SKEIN1024_544:45988,SKEIN1024_552:45989,SKEIN1024_560:45990,SKEIN1024_568:45991,SKEIN1024_576:45992,SKEIN1024_584:45993,SKEIN1024_592:45994,SKEIN1024_600:45995,SKEIN1024_608:45996,SKEIN1024_616:45997,SKEIN1024_624:45998,SKEIN1024_632:45999,SKEIN1024_640:46e3,SKEIN1024_648:46001,SKEIN1024_656:46002,SKEIN1024_664:46003,SKEIN1024_672:46004,SKEIN1024_680:46005,SKEIN1024_688:46006,SKEIN1024_696:46007,SKEIN1024_704:46008,SKEIN1024_712:46009,SKEIN1024_720:46010,SKEIN1024_728:46011,SKEIN1024_736:46012,SKEIN1024_744:46013,SKEIN1024_752:46014,SKEIN1024_760:46015,SKEIN1024_768:46016,SKEIN1024_776:46017,SKEIN1024_784:46018,SKEIN1024_792:46019,SKEIN1024_800:46020,SKEIN1024_808:46021,SKEIN1024_816:46022,SKEIN1024_824:46023,SKEIN1024_832:46024,SKEIN1024_840:46025,SKEIN1024_848:46026,SKEIN1024_856:46027,SKEIN1024_864:46028,SKEIN1024_872:46029,SKEIN1024_880:46030,SKEIN1024_888:46031,SKEIN1024_896:46032,SKEIN1024_904:46033,SKEIN1024_912:46034,SKEIN1024_920:46035,SKEIN1024_928:46036,SKEIN1024_936:46037,SKEIN1024_944:46038,SKEIN1024_952:46039,SKEIN1024_960:46040,SKEIN1024_968:46041,SKEIN1024_976:46042,SKEIN1024_984:46043,SKEIN1024_992:46044,SKEIN1024_1000:46045,SKEIN1024_1008:46046,SKEIN1024_1016:46047,SKEIN1024_1024:46048,IP4:4,TCP:6,DCCP:33,IP6:41,IP6ZONE:42,DNS:53,DNS4:54,DNS6:55,DNSADDR:56,SCTP:132,UDP:273,P2P_WEBRTC_STAR:275,P2P_WEBRTC_DIRECT:276,P2P_STARDUST:277,P2P_CIRCUIT:290,UDT:301,UTP:302,UNIX:400,P2P:421,IPFS:421,HTTPS:443,ONION:444,ONION3:445,GARLIC64:446,GARLIC32:447,QUIC:460,WS:477,WSS:478,P2P_WEBSOCKET_STAR:479,HTTP:480,RAW:85,DAG_PB:112,DAG_CBOR:113,LIBP2P_KEY:114,GIT_RAW:120,TORRENT_INFO:123,TORRENT_FILE:124,LEOFCOIN_BLOCK:129,LEOFCOIN_TX:130,LEOFCOIN_PR:131,ETH_BLOCK:144,ETH_BLOCK_LIST:145,ETH_TX_TRIE:146,ETH_TX:147,ETH_TX_RECEIPT_TRIE:148,ETH_TX_RECEIPT:149,ETH_STATE_TRIE:150,ETH_ACCOUNT_SNAPSHOT:151,ETH_STORAGE_TRIE:152,BITCOIN_BLOCK:176,BITCOIN_TX:177,ZCASH_BLOCK:192,ZCASH_TX:193,STELLAR_BLOCK:208,STELLAR_TX:209,DECRED_BLOCK:224,DECRED_TX:225,DASH_BLOCK:240,DASH_TX:241,SWARM_MANIFEST:250,SWARM_FEED:251,DAG_JSON:297,PATH:47,IPLD_NS:226,IPFS_NS:227,SWARM_NS:228,ED25519_PUB:237,HOLOCHAIN_ADR_V0:8417572,HOLOCHAIN_ADR_V1:8483108,HOLOCHAIN_KEY_V0:9728292,HOLOCHAIN_KEY_V1:9793828,HOLOCHAIN_SIG_V0:10645796,HOLOCHAIN_SIG_V1:10711332})},function(e,t,n){"use strict";e.exports=Object.freeze({80:"protobuf",81:"cbor",96:"rlp",99:"bencode",48:"multicodec",49:"multihash",50:"multiaddr",51:"multibase",0:"identity",17:"sha1",18:"sha2-256",19:"sha2-512",20:"sha3-512",21:"sha3-384",22:"sha3-256",23:"sha3-224",24:"shake-128",25:"shake-256",26:"keccak-224",27:"keccak-256",28:"keccak-384",29:"keccak-512",34:"murmur3-128",35:"murmur3-32",86:"dbl-sha2-256",212:"md4",213:"md5",214:"bmt",4352:"x11",45569:"blake2b-8",45570:"blake2b-16",45571:"blake2b-24",45572:"blake2b-32",45573:"blake2b-40",45574:"blake2b-48",45575:"blake2b-56",45576:"blake2b-64",45577:"blake2b-72",45578:"blake2b-80",45579:"blake2b-88",45580:"blake2b-96",45581:"blake2b-104",45582:"blake2b-112",45583:"blake2b-120",45584:"blake2b-128",45585:"blake2b-136",45586:"blake2b-144",45587:"blake2b-152",45588:"blake2b-160",45589:"blake2b-168",45590:"blake2b-176",45591:"blake2b-184",45592:"blake2b-192",45593:"blake2b-200",45594:"blake2b-208",45595:"blake2b-216",45596:"blake2b-224",45597:"blake2b-232",45598:"blake2b-240",45599:"blake2b-248",45600:"blake2b-256",45601:"blake2b-264",45602:"blake2b-272",45603:"blake2b-280",45604:"blake2b-288",45605:"blake2b-296",45606:"blake2b-304",45607:"blake2b-312",45608:"blake2b-320",45609:"blake2b-328",45610:"blake2b-336",45611:"blake2b-344",45612:"blake2b-352",45613:"blake2b-360",45614:"blake2b-368",45615:"blake2b-376",45616:"blake2b-384",45617:"blake2b-392",45618:"blake2b-400",45619:"blake2b-408",45620:"blake2b-416",45621:"blake2b-424",45622:"blake2b-432",45623:"blake2b-440",45624:"blake2b-448",45625:"blake2b-456",45626:"blake2b-464",45627:"blake2b-472",45628:"blake2b-480",45629:"blake2b-488",45630:"blake2b-496",45631:"blake2b-504",45632:"blake2b-512",45633:"blake2s-8",45634:"blake2s-16",45635:"blake2s-24",45636:"blake2s-32",45637:"blake2s-40",45638:"blake2s-48",45639:"blake2s-56",45640:"blake2s-64",45641:"blake2s-72",45642:"blake2s-80",45643:"blake2s-88",45644:"blake2s-96",45645:"blake2s-104",45646:"blake2s-112",45647:"blake2s-120",45648:"blake2s-128",45649:"blake2s-136",45650:"blake2s-144",45651:"blake2s-152",45652:"blake2s-160",45653:"blake2s-168",45654:"blake2s-176",45655:"blake2s-184",45656:"blake2s-192",45657:"blake2s-200",45658:"blake2s-208",45659:"blake2s-216",45660:"blake2s-224",45661:"blake2s-232",45662:"blake2s-240",45663:"blake2s-248",45664:"blake2s-256",45825:"skein256-8",45826:"skein256-16",45827:"skein256-24",45828:"skein256-32",45829:"skein256-40",45830:"skein256-48",45831:"skein256-56",45832:"skein256-64",45833:"skein256-72",45834:"skein256-80",45835:"skein256-88",45836:"skein256-96",45837:"skein256-104",45838:"skein256-112",45839:"skein256-120",45840:"skein256-128",45841:"skein256-136",45842:"skein256-144",45843:"skein256-152",45844:"skein256-160",45845:"skein256-168",45846:"skein256-176",45847:"skein256-184",45848:"skein256-192",45849:"skein256-200",45850:"skein256-208",45851:"skein256-216",45852:"skein256-224",45853:"skein256-232",45854:"skein256-240",45855:"skein256-248",45856:"skein256-256",45857:"skein512-8",45858:"skein512-16",45859:"skein512-24",45860:"skein512-32",45861:"skein512-40",45862:"skein512-48",45863:"skein512-56",45864:"skein512-64",45865:"skein512-72",45866:"skein512-80",45867:"skein512-88",45868:"skein512-96",45869:"skein512-104",45870:"skein512-112",45871:"skein512-120",45872:"skein512-128",45873:"skein512-136",45874:"skein512-144",45875:"skein512-152",45876:"skein512-160",45877:"skein512-168",45878:"skein512-176",45879:"skein512-184",45880:"skein512-192",45881:"skein512-200",45882:"skein512-208",45883:"skein512-216",45884:"skein512-224",45885:"skein512-232",45886:"skein512-240",45887:"skein512-248",45888:"skein512-256",45889:"skein512-264",45890:"skein512-272",45891:"skein512-280",45892:"skein512-288",45893:"skein512-296",45894:"skein512-304",45895:"skein512-312",45896:"skein512-320",45897:"skein512-328",45898:"skein512-336",45899:"skein512-344",45900:"skein512-352",45901:"skein512-360",45902:"skein512-368",45903:"skein512-376",45904:"skein512-384",45905:"skein512-392",45906:"skein512-400",45907:"skein512-408",45908:"skein512-416",45909:"skein512-424",45910:"skein512-432",45911:"skein512-440",45912:"skein512-448",45913:"skein512-456",45914:"skein512-464",45915:"skein512-472",45916:"skein512-480",45917:"skein512-488",45918:"skein512-496",45919:"skein512-504",45920:"skein512-512",45921:"skein1024-8",45922:"skein1024-16",45923:"skein1024-24",45924:"skein1024-32",45925:"skein1024-40",45926:"skein1024-48",45927:"skein1024-56",45928:"skein1024-64",45929:"skein1024-72",45930:"skein1024-80",45931:"skein1024-88",45932:"skein1024-96",45933:"skein1024-104",45934:"skein1024-112",45935:"skein1024-120",45936:"skein1024-128",45937:"skein1024-136",45938:"skein1024-144",45939:"skein1024-152",45940:"skein1024-160",45941:"skein1024-168",45942:"skein1024-176",45943:"skein1024-184",45944:"skein1024-192",45945:"skein1024-200",45946:"skein1024-208",45947:"skein1024-216",45948:"skein1024-224",45949:"skein1024-232",45950:"skein1024-240",45951:"skein1024-248",45952:"skein1024-256",45953:"skein1024-264",45954:"skein1024-272",45955:"skein1024-280",45956:"skein1024-288",45957:"skein1024-296",45958:"skein1024-304",45959:"skein1024-312",45960:"skein1024-320",45961:"skein1024-328",45962:"skein1024-336",45963:"skein1024-344",45964:"skein1024-352",45965:"skein1024-360",45966:"skein1024-368",45967:"skein1024-376",45968:"skein1024-384",45969:"skein1024-392",45970:"skein1024-400",45971:"skein1024-408",45972:"skein1024-416",45973:"skein1024-424",45974:"skein1024-432",45975:"skein1024-440",45976:"skein1024-448",45977:"skein1024-456",45978:"skein1024-464",45979:"skein1024-472",45980:"skein1024-480",45981:"skein1024-488",45982:"skein1024-496",45983:"skein1024-504",45984:"skein1024-512",45985:"skein1024-520",45986:"skein1024-528",45987:"skein1024-536",45988:"skein1024-544",45989:"skein1024-552",45990:"skein1024-560",45991:"skein1024-568",45992:"skein1024-576",45993:"skein1024-584",45994:"skein1024-592",45995:"skein1024-600",45996:"skein1024-608",45997:"skein1024-616",45998:"skein1024-624",45999:"skein1024-632",46000:"skein1024-640",46001:"skein1024-648",46002:"skein1024-656",46003:"skein1024-664",46004:"skein1024-672",46005:"skein1024-680",46006:"skein1024-688",46007:"skein1024-696",46008:"skein1024-704",46009:"skein1024-712",46010:"skein1024-720",46011:"skein1024-728",46012:"skein1024-736",46013:"skein1024-744",46014:"skein1024-752",46015:"skein1024-760",46016:"skein1024-768",46017:"skein1024-776",46018:"skein1024-784",46019:"skein1024-792",46020:"skein1024-800",46021:"skein1024-808",46022:"skein1024-816",46023:"skein1024-824",46024:"skein1024-832",46025:"skein1024-840",46026:"skein1024-848",46027:"skein1024-856",46028:"skein1024-864",46029:"skein1024-872",46030:"skein1024-880",46031:"skein1024-888",46032:"skein1024-896",46033:"skein1024-904",46034:"skein1024-912",46035:"skein1024-920",46036:"skein1024-928",46037:"skein1024-936",46038:"skein1024-944",46039:"skein1024-952",46040:"skein1024-960",46041:"skein1024-968",46042:"skein1024-976",46043:"skein1024-984",46044:"skein1024-992",46045:"skein1024-1000",46046:"skein1024-1008",46047:"skein1024-1016",46048:"skein1024-1024",4:"ip4",6:"tcp",33:"dccp",41:"ip6",42:"ip6zone",53:"dns",54:"dns4",55:"dns6",56:"dnsaddr",132:"sctp",273:"udp",275:"p2p-webrtc-star",276:"p2p-webrtc-direct",277:"p2p-stardust",290:"p2p-circuit",301:"udt",302:"utp",400:"unix",421:"p2p",443:"https",444:"onion",445:"onion3",446:"garlic64",447:"garlic32",460:"quic",477:"ws",478:"wss",479:"p2p-websocket-star",480:"http",85:"raw",112:"dag-pb",113:"dag-cbor",114:"libp2p-key",120:"git-raw",123:"torrent-info",124:"torrent-file",129:"leofcoin-block",130:"leofcoin-tx",131:"leofcoin-pr",144:"eth-block",145:"eth-block-list",146:"eth-tx-trie",147:"eth-tx",148:"eth-tx-receipt-trie",149:"eth-tx-receipt",150:"eth-state-trie",151:"eth-account-snapshot",152:"eth-storage-trie",176:"bitcoin-block",177:"bitcoin-tx",192:"zcash-block",193:"zcash-tx",208:"stellar-block",209:"stellar-tx",224:"decred-block",225:"decred-tx",240:"dash-block",241:"dash-tx",250:"swarm-manifest",251:"swarm-feed",297:"dag-json",47:"path",226:"ipld-ns",227:"ipfs-ns",228:"swarm-ns",237:"ed25519-pub",8417572:"holochain-adr-v0",8483108:"holochain-adr-v1",9728292:"holochain-key-v0",9793828:"holochain-key-v1",10645796:"holochain-sig-v0",10711332:"holochain-sig-v1"})},function(e,t,n){"use strict";(function(t){const r=n(27);var i={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!t.isBuffer(e.multihash))return"multihash must be a Buffer";try{r.validate(e.multihash)}catch(e){let t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports={keys:n(697),once:n(116),values:n(40),count:n(698),infinite:n(699),empty:n(88),error:n(71)}},function(e,t,n){"use strict";var r=n(40);e.exports=function(e){return r(Object.keys(e))}},function(e,t,n){"use strict";e.exports=function e(t){var n=0;return t=t||1/0,function(e,r){return e?r&&r(e):n>t?r(!0):void r(null,n++)}}},function(e,t,n){"use strict";e.exports=function e(t){return t=t||Math.random,function(e,n){return e?n&&n(e):n(null,t())}}},function(e,t,n){"use strict";e.exports={drain:n(150),onEnd:n(344),log:n(701),find:n(702),reduce:n(185),collect:n(33),concat:n(703)}},function(e,t,n){"use strict";var r=n(150);e.exports=function e(t){return r(function(e){console.log(e)},t)}},function(e,t,n){"use strict";function r(e){return e}var i=n(151),o=n(150);e.exports=function e(t,n){var s=!1;return n?t=i(t)||r:(n=t,t=r),o(function(e){if(t(e))return s=!0,n(null,e),!1},function(e){s||n(!0===e?null:e,null)})}},function(e,t,n){"use strict";var r=n(185);e.exports=function e(t){return r(function(e,t){return e+t},"",t)}},function(e,t,n){"use strict";e.exports={map:n(66),asyncMap:n(74),filter:n(67),filterNot:n(705),through:n(186),take:n(246),unique:n(346),nonUnique:n(706),flatten:n(187)}},function(e,t,n){"use strict";var r=n(345),i=n(67);e.exports=function e(t){return t=r(t),i(function(e){return!t(e)})}},function(e,t,n){"use strict";var r=n(346);e.exports=function e(t){return r(t,!0)}},function(e,t,n){"use strict";(function(t){const r=n(27);var i={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(!t.isBuffer(e.multihash))return"multihash must be a Buffer";try{r.validate(e.multihash)}catch(e){let t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=f;var r=n(58),i=h(r),o=n(86),s=h(o),a=n(107),l=h(a),u=n(37),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n){n=(0,l.default)(n||i.default);var r=(0,c.default)(e),o=function(e){if(e)return n(e);var i=(0,s.default)(arguments,1);if(t.apply(this,i))return r(o);n.apply(null,[null].concat(i))};r(o)}e.exports=t.default},function(e,t){e.exports=function(){var e,t,n,r,i;function o(o){return i?i(o):(e=o,function(e,i){t?t(e,i):(r=e,n=i)})}return o.resolve=function(o){if(i)throw new Error("already resolved");if(i=o,!i)throw new Error("resolve *must* be passed a transform stream");e&&(t=i(e),n&&t(r,n))},o}},function(e,t,n){"use strict";t.Diagnose=n(711),t.Decoder=n(353),t.Encoder=n(714),t.Simple=n(354),t.Tagged=n(355),t.decodeAll=t.Decoder.decodeAll,t.decodeFirst=t.Decoder.decodeFirst,t.diagnose=t.Diagnose.diagnose,t.encode=t.Encoder.encode,t.decode=t.Decoder.decode,t.leveldb={decode:t.Decoder.decodeAll,encode:t.Encoder.encode,buffer:!0,name:"cbor"}},function(e,t,n){"use strict";(function(t){const r=n(353),i=n(247);class o extends r{createTag(e,t){return`${e}(${t})`}createInt(e){return super.createInt(e).toString()}createInt32(e,t){return super.createInt32(e,t).toString()}createInt64(e,t,n,r){return super.createInt64(e,t,n,r).toString()}createInt32Neg(e,t){return super.createInt32Neg(e,t).toString()}createInt64Neg(e,t,n,r){return super.createInt64Neg(e,t,n,r).toString()}createTrue(){return"true"}createFalse(){return"false"}createFloat(e){const t=super.createFloat(e);return i.isNegativeZero(e)?"-0_1":`${t}_1`}createFloatSingle(e,t,n,r){const i=super.createFloatSingle(e,t,n,r);return`${i}_2`}createFloatDouble(e,t,n,r,i,o,s,a){const l=super.createFloatDouble(e,t,n,r,i,o,s,a);return`${l}_3`}createByteString(e,t){const n=e.join(", ");return-1===t?`(_ ${n})`:`h'${n}`}createByteStringFromHeap(e,n){const r=t.from(super.createByteStringFromHeap(e,n)).toString("hex");return`h'${r}'`}createInfinity(){return"Infinity_1"}createInfinityNeg(){return"-Infinity_1"}createNaN(){return"NaN_1"}createNaNNeg(){return"-NaN_1"}createNull(){return"null"}createUndefined(){return"undefined"}createSimpleUnassigned(e){return`simple(${e})`}createArray(e,t){const n=super.createArray(e,t);return-1===t?`[_ ${n.join(", ")}]`:`[${n.join(", ")}]`}createMap(e,t){const n=super.createMap(e),r=Array.from(n.keys()).reduce(s(n),"");return-1===t?`{_ ${r}}`:`{${r}}`}createObject(e,t){const n=super.createObject(e),r=Object.keys(n).reduce(s(n),"");return-1===t?`{_ ${r}}`:`{${r}}`}createUtf8String(e,t){const n=e.join(", ");return-1===t?`(_ ${n})`:`"${n}"`}createUtf8StringFromHeap(e,n){const r=t.from(super.createUtf8StringFromHeap(e,n)).toString("utf8");return`"${r}"`}static diagnose(e,n){"string"==typeof e&&(e=t.from(e,n||"hex"));const r=new o;return r.decodeFirst(e)}}function s(e){return(t,n)=>t?`${t}, ${n}: ${e[n]}`:`${n}: ${e[n]}`}e.exports=o}).call(this,n(0).Buffer)},function(e,t){e.exports=function e(t,n,r){"use asm";var i=new t.Uint8Array(r);var o=n.pushInt;var s=n.pushInt32;var a=n.pushInt32Neg;var l=n.pushInt64;var u=n.pushInt64Neg;var c=n.pushFloat;var h=n.pushFloatSingle;var f=n.pushFloatDouble;var p=n.pushTrue;var d=n.pushFalse;var m=n.pushUndefined;var g=n.pushNull;var y=n.pushInfinity;var v=n.pushInfinityNeg;var b=n.pushNaN;var _=n.pushNaNNeg;var w=n.pushArrayStart;var k=n.pushArrayStartFixed;var E=n.pushArrayStartFixed32;var S=n.pushArrayStartFixed64;var x=n.pushObjectStart;var C=n.pushObjectStartFixed;var A=n.pushObjectStartFixed32;var T=n.pushObjectStartFixed64;var I=n.pushByteString;var j=n.pushByteStringStart;var R=n.pushUtf8String;var B=n.pushUtf8StringStart;var O=n.pushSimpleUnassigned;var P=n.pushTagStart;var N=n.pushTagStart4;var D=n.pushTagStart8;var M=n.pushTagUnassigned;var F=n.pushBreak;var L=t.Math.pow;var U=0;var q=0;var z=0;function K(e){e=e|0;U=0;q=e;while((U|0)<(q|0)){z=Je[i[U]&255](i[U]|0)|0;if((z|0)>0){break}}return z|0}function H(e){e=e|0;if(((U|0)+(e|0)|0)<(q|0)){return 0}return 1}function V(e){e=e|0;return i[e|0]<<8|i[e+1|0]|0}function $(e){e=e|0;return i[e|0]<<24|i[e+1|0]<<16|i[e+2|0]<<8|i[e+3|0]|0}function W(e){e=e|0;o(e|0);U=U+1|0;return 0}function G(e){e=e|0;if(H(1)|0){return 1}o(i[U+1|0]|0);U=U+2|0;return 0}function Y(e){e=e|0;if(H(2)|0){return 1}o(V(U+1|0)|0);U=U+3|0;return 0}function Z(e){e=e|0;if(H(4)|0){return 1}s(V(U+1|0)|0,V(U+3|0)|0);U=U+5|0;return 0}function J(e){e=e|0;if(H(8)|0){return 1}l(V(U+1|0)|0,V(U+3|0)|0,V(U+5|0)|0,V(U+7|0)|0);U=U+9|0;return 0}function Q(e){e=e|0;o(-1-(e-32|0)|0);U=U+1|0;return 0}function X(e){e=e|0;if(H(1)|0){return 1}o(-1-(i[U+1|0]|0)|0);U=U+2|0;return 0}function ee(e){e=e|0;var t=0;if(H(2)|0){return 1}t=V(U+1|0)|0;o(-1-(t|0)|0);U=U+3|0;return 0}function te(e){e=e|0;if(H(4)|0){return 1}a(V(U+1|0)|0,V(U+3|0)|0);U=U+5|0;return 0}function ne(e){e=e|0;if(H(8)|0){return 1}u(V(U+1|0)|0,V(U+3|0)|0,V(U+5|0)|0,V(U+7|0)|0);U=U+9|0;return 0}function re(e){e=e|0;var t=0;var n=0;var r=0;r=e-64|0;if(H(r|0)|0){return 1}t=U+1|0;n=(U+1|0)+(r|0)|0;I(t|0,n|0);U=n|0;return 0}function ie(e){e=e|0;var t=0;var n=0;var r=0;if(H(1)|0){return 1}r=i[U+1|0]|0;t=U+2|0;n=(U+2|0)+(r|0)|0;if(H(r+1|0)|0){return 1}I(t|0,n|0);U=n|0;return 0}function oe(e){e=e|0;var t=0;var n=0;var r=0;if(H(2)|0){return 1}r=V(U+1|0)|0;t=U+3|0;n=(U+3|0)+(r|0)|0;if(H(r+2|0)|0){return 1}I(t|0,n|0);U=n|0;return 0}function se(e){e=e|0;var t=0;var n=0;var r=0;if(H(4)|0){return 1}r=$(U+1|0)|0;t=U+5|0;n=(U+5|0)+(r|0)|0;if(H(r+4|0)|0){return 1}I(t|0,n|0);U=n|0;return 0}function ae(e){e=e|0;return 1}function le(e){e=e|0;j();U=U+1|0;return 0}function ue(e){e=e|0;var t=0;var n=0;var r=0;r=e-96|0;if(H(r|0)|0){return 1}t=U+1|0;n=(U+1|0)+(r|0)|0;R(t|0,n|0);U=n|0;return 0}function ce(e){e=e|0;var t=0;var n=0;var r=0;if(H(1)|0){return 1}r=i[U+1|0]|0;t=U+2|0;n=(U+2|0)+(r|0)|0;if(H(r+1|0)|0){return 1}R(t|0,n|0);U=n|0;return 0}function he(e){e=e|0;var t=0;var n=0;var r=0;if(H(2)|0){return 1}r=V(U+1|0)|0;t=U+3|0;n=(U+3|0)+(r|0)|0;if(H(r+2|0)|0){return 1}R(t|0,n|0);U=n|0;return 0}function fe(e){e=e|0;var t=0;var n=0;var r=0;if(H(4)|0){return 1}r=$(U+1|0)|0;t=U+5|0;n=(U+5|0)+(r|0)|0;if(H(r+4|0)|0){return 1}R(t|0,n|0);U=n|0;return 0}function pe(e){e=e|0;return 1}function de(e){e=e|0;B();U=U+1|0;return 0}function me(e){e=e|0;k(e-128|0);U=U+1|0;return 0}function ge(e){e=e|0;if(H(1)|0){return 1}k(i[U+1|0]|0);U=U+2|0;return 0}function ye(e){e=e|0;if(H(2)|0){return 1}k(V(U+1|0)|0);U=U+3|0;return 0}function ve(e){e=e|0;if(H(4)|0){return 1}E(V(U+1|0)|0,V(U+3|0)|0);U=U+5|0;return 0}function be(e){e=e|0;if(H(8)|0){return 1}S(V(U+1|0)|0,V(U+3|0)|0,V(U+5|0)|0,V(U+7|0)|0);U=U+9|0;return 0}function _e(e){e=e|0;w();U=U+1|0;return 0}function we(e){e=e|0;var t=0;t=e-160|0;if(H(t|0)|0){return 1}C(t|0);U=U+1|0;return 0}function ke(e){e=e|0;if(H(1)|0){return 1}C(i[U+1|0]|0);U=U+2|0;return 0}function Ee(e){e=e|0;if(H(2)|0){return 1}C(V(U+1|0)|0);U=U+3|0;return 0}function Se(e){e=e|0;if(H(4)|0){return 1}A(V(U+1|0)|0,V(U+3|0)|0);U=U+5|0;return 0}function xe(e){e=e|0;if(H(8)|0){return 1}T(V(U+1|0)|0,V(U+3|0)|0,V(U+5|0)|0,V(U+7|0)|0);U=U+9|0;return 0}function Ce(e){e=e|0;x();U=U+1|0;return 0}function Ae(e){e=e|0;P(e-192|0|0);U=U+1|0;return 0}function Te(e){e=e|0;P(e|0);U=U+1|0;return 0}function Ie(e){e=e|0;P(e|0);U=U+1|0;return 0}function je(e){e=e|0;P(e|0);U=U+1|0;return 0}function Re(e){e=e|0;P(e|0);U=U+1|0;return 0}function Be(e){e=e|0;P(e-192|0|0);U=U+1|0;return 0}function Oe(e){e=e|0;P(e|0);U=U+1|0;return 0}function Pe(e){e=e|0;P(e|0);U=U+1|0;return 0}function Ne(e){e=e|0;P(e|0);U=U+1|0;return 0}function De(e){e=e|0;if(H(1)|0){return 1}P(i[U+1|0]|0);U=U+2|0;return 0}function Me(e){e=e|0;if(H(2)|0){return 1}P(V(U+1|0)|0);U=U+3|0;return 0}function Fe(e){e=e|0;if(H(4)|0){return 1}N(V(U+1|0)|0,V(U+3|0)|0);U=U+5|0;return 0}function Le(e){e=e|0;if(H(8)|0){return 1}D(V(U+1|0)|0,V(U+3|0)|0,V(U+5|0)|0,V(U+7|0)|0);U=U+9|0;return 0}function Ue(e){e=e|0;O((e|0)-224|0);U=U+1|0;return 0}function qe(e){e=e|0;d();U=U+1|0;return 0}function ze(e){e=e|0;p();U=U+1|0;return 0}function Ke(e){e=e|0;g();U=U+1|0;return 0}function He(e){e=e|0;m();U=U+1|0;return 0}function Ve(e){e=e|0;if(H(1)|0){return 1}O(i[U+1|0]|0);U=U+2|0;return 0}function $e(e){e=e|0;var t=0;var n=0;var r=1.0;var o=0.0;var s=0.0;var a=0.0;if(H(2)|0){return 1}t=i[U+1|0]|0;n=i[U+2|0]|0;if((t|0)&0x80){r=-1.0}o=+(((t|0)&0x7C)>>2);s=+(((t|0)&0x03)<<8|n);if(+o==0.0){c(+(+r*+5.9604644775390625e-8*+s))}else if(+o==31.0){if(+r==1.0){if(+s>0.0){b()}else{y()}}else{if(+s>0.0){_()}else{v()}}}else{c(+(+r*L(+2,+(+o-25.0))*+(1024.0+s)))}U=U+3|0;return 0}function We(e){e=e|0;if(H(4)|0){return 1}h(i[U+1|0]|0,i[U+2|0]|0,i[U+3|0]|0,i[U+4|0]|0);U=U+5|0;return 0}function Ge(e){e=e|0;if(H(8)|0){return 1}f(i[U+1|0]|0,i[U+2|0]|0,i[U+3|0]|0,i[U+4|0]|0,i[U+5|0]|0,i[U+6|0]|0,i[U+7|0]|0,i[U+8|0]|0);U=U+9|0;return 0}function Ye(e){e=e|0;return 1}function Ze(e){e=e|0;F();U=U+1|0;return 0}var Je=[W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,W,G,Y,Z,J,Ye,Ye,Ye,Ye,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,Q,X,ee,te,ne,Ye,Ye,Ye,Ye,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,re,ie,oe,se,ae,Ye,Ye,Ye,le,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ue,ce,he,fe,pe,Ye,Ye,Ye,de,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,me,ge,ye,ve,be,Ye,Ye,Ye,_e,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,we,ke,Ee,Se,xe,Ye,Ye,Ye,Ce,Ae,Ae,Ae,Ae,Ae,Ae,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,Be,De,Me,Fe,Le,Ye,Ye,Ye,Ye,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,Ue,qe,ze,Ke,He,Ve,$e,We,Ge,Ye,Ye,Ye,Ze];return{parse:K}}},function(e,t,n){"use strict";const{URLWithLegacySupport:r,format:i}=n(356);e.exports=((e,t={},n={},o)=>{let s=t.protocol?t.protocol.replace(":",""):"http",a;s=(n[s]||o||s)+":";try{a=new r(e)}catch(e){a={}}const l=Object.assign({},t,{protocol:s||a.protocol,host:t.host||a.host});return new r(e,i(l)).toString()})},function(e,t,n){"use strict";(function(t){const{URL:r}=n(191),i=n(55),o=n(247),s=n(190),a=s.MT,l=s.NUMBYTES,u=s.SHIFT32,c=s.SYMS,h=s.TAG,f=s.MT.SIMPLE_FLOAT<<5|s.NUMBYTES.TWO,p=s.MT.SIMPLE_FLOAT<<5|s.NUMBYTES.FOUR,d=s.MT.SIMPLE_FLOAT<<5|s.NUMBYTES.EIGHT,m=s.MT.SIMPLE_FLOAT<<5|s.SIMPLE.TRUE,g=s.MT.SIMPLE_FLOAT<<5|s.SIMPLE.FALSE,y=s.MT.SIMPLE_FLOAT<<5|s.SIMPLE.UNDEFINED,v=s.MT.SIMPLE_FLOAT<<5|s.SIMPLE.NULL,b=new i("0x20000000000000"),_=t.from("f97e00","hex"),w=t.from("f9fc00","hex"),k=t.from("f97c00","hex");function E(e){return{}.toString.call(e).slice(8,-1)}class S{constructor(e){e=e||{},this.streaming="function"==typeof e.stream,this.onData=e.stream,this.semanticTypes=[[r,this._pushUrl],[i,this._pushBigNumber]];const t=e.genTypes||[],n=t.length;for(let e=0;e<n;e++)this.addSemanticType(t[e][0],t[e][1]);this._reset()}addSemanticType(e,t){const n=this.semanticTypes.length;for(let r=0;r<n;r++){const n=this.semanticTypes[r][0];if(n===e){const e=this.semanticTypes[r][1];return this.semanticTypes[r][1]=t,e}}return this.semanticTypes.push([e,t]),null}push(e){return!e||(this.result[this.offset]=e,this.resultMethod[this.offset]=0,this.resultLength[this.offset]=e.length,this.offset++,this.streaming&&this.onData(this.finalize()),!0)}pushWrite(e,t,n){return this.result[this.offset]=e,this.resultMethod[this.offset]=t,this.resultLength[this.offset]=n,this.offset++,this.streaming&&this.onData(this.finalize()),!0}_pushUInt8(e){return this.pushWrite(e,1,1)}_pushUInt16BE(e){return this.pushWrite(e,2,2)}_pushUInt32BE(e){return this.pushWrite(e,3,4)}_pushDoubleBE(e){return this.pushWrite(e,4,8)}_pushNaN(){return this.push(_)}_pushInfinity(e){const t=e<0?w:k;return this.push(t)}_pushFloat(e){const n=t.allocUnsafe(2);if(o.writeHalf(n,e)&&o.parseHalf(n)===e)return this._pushUInt8(f)&&this.push(n);const r=t.allocUnsafe(4);return r.writeFloatBE(e,0),r.readFloatBE(0)===e?this._pushUInt8(p)&&this.push(r):this._pushUInt8(d)&&this._pushDoubleBE(e)}_pushInt(e,t,n){const r=t<<5;return e<24?this._pushUInt8(r|e):e<=255?this._pushUInt8(r|l.ONE)&&this._pushUInt8(e):e<=65535?this._pushUInt8(r|l.TWO)&&this._pushUInt16BE(e):e<=4294967295?this._pushUInt8(r|l.FOUR)&&this._pushUInt32BE(e):e<=Number.MAX_SAFE_INTEGER?this._pushUInt8(r|l.EIGHT)&&this._pushUInt32BE(Math.floor(e/u))&&this._pushUInt32BE(e%u):t===a.NEG_INT?this._pushFloat(n):this._pushFloat(e)}_pushIntNum(e){return e<0?this._pushInt(-e-1,a.NEG_INT,e):this._pushInt(e,a.POS_INT)}_pushNumber(e){switch(!1){case e==e:return this._pushNaN(e);case isFinite(e):return this._pushInfinity(e);case e%1!=0:return this._pushIntNum(e);default:return this._pushFloat(e)}}_pushString(e){const n=t.byteLength(e,"utf8");return this._pushInt(n,a.UTF8_STRING)&&this.pushWrite(e,5,n)}_pushBoolean(e){return this._pushUInt8(e?m:g)}_pushUndefined(e){return this._pushUInt8(y)}_pushArray(e,t){const n=t.length;if(!e._pushInt(n,a.ARRAY))return!1;for(let r=0;r<n;r++)if(!e.pushAny(t[r]))return!1;return!0}_pushTag(e){return this._pushInt(e,a.TAG)}_pushDate(e,t){return e._pushTag(h.DATE_EPOCH)&&e.pushAny(Math.round(t/1e3))}_pushBuffer(e,t){return e._pushInt(t.length,a.BYTE_STRING)&&e.push(t)}_pushNoFilter(e,t){return e._pushBuffer(e,t.slice())}_pushRegexp(e,t){return e._pushTag(h.REGEXP)&&e.pushAny(t.source)}_pushSet(e,t){if(!e._pushInt(t.size,a.ARRAY))return!1;for(let n of t)if(!e.pushAny(n))return!1;return!0}_pushUrl(e,t){return e._pushTag(h.URI)&&e.pushAny(t.format())}_pushBigint(e){let n=h.POS_BIGINT;e.isNegative()&&(e=e.negated().minus(1),n=h.NEG_BIGINT);let r=e.toString(16);r.length%2&&(r="0"+r);const i=t.from(r,"hex");return this._pushTag(n)&&this._pushBuffer(this,i)}_pushBigNumber(e,t){if(t.isNaN())return e._pushNaN();if(!t.isFinite())return e._pushInfinity(t.isNegative()?-1/0:1/0);if(t.isInteger())return e._pushBigint(t);if(!e._pushTag(h.DECIMAL_FRAC)||!e._pushInt(2,a.ARRAY))return!1;const n=t.decimalPlaces(),r=t.multipliedBy(new i(10).pow(n));return!!e._pushIntNum(-n)&&(r.abs().isLessThan(b)?e._pushIntNum(r.toNumber()):e._pushBigint(r))}_pushMap(e,t){return!!e._pushInt(t.size,a.MAP)&&this._pushRawMap(t.size,Array.from(t))}_pushObject(e){if(!e)return this._pushUInt8(v);for(var t=this.semanticTypes.length,n=0;n<t;n++)if(e instanceof this.semanticTypes[n][0])return this.semanticTypes[n][1].call(e,this,e);var r=e.encodeCBOR;if("function"==typeof r)return r.call(e,this);var i=Object.keys(e),o=i.length;return!!this._pushInt(o,a.MAP)&&this._pushRawMap(o,i.map(t=>[t,e[t]]))}_pushRawMap(e,t){t=t.map(function(e){return e[0]=S.encode(e[0]),e}).sort(o.keySorter);for(var n=0;n<e;n++){if(!this.push(t[n][0]))return!1;if(!this.pushAny(t[n][1]))return!1}return!0}write(e){return this.pushAny(e)}pushAny(e){var n=E(e);switch(n){case"Number":return this._pushNumber(e);case"String":return this._pushString(e);case"Boolean":return this._pushBoolean(e);case"Object":return this._pushObject(e);case"Array":return this._pushArray(this,e);case"Uint8Array":return this._pushBuffer(this,t.isBuffer(e)?e:t.from(e));case"Null":return this._pushUInt8(v);case"Undefined":return this._pushUndefined(e);case"Map":return this._pushMap(this,e);case"Set":return this._pushSet(this,e);case"URL":return this._pushUrl(this,e);case"BigNumber":return this._pushBigNumber(this,e);case"Date":return this._pushDate(this,e);case"RegExp":return this._pushRegexp(this,e);case"Symbol":switch(e){case c.NULL:return this._pushObject(null);case c.UNDEFINED:return this._pushUndefined(void 0);default:throw new Error("Unknown symbol: "+e.toString())}default:throw new Error("Unknown type: "+typeof e+", "+(e?e.toString():""))}}finalize(){if(0===this.offset)return null;for(var e=this.result,n=this.resultLength,r=this.resultMethod,i=this.offset,o=0,s=0;s<i;s++)o+=n[s];var a=t.allocUnsafe(o),l=0,u=0;for(s=0;s<i;s++){switch(u=n[s],r[s]){case 0:e[s].copy(a,l);break;case 1:a.writeUInt8(e[s],l,!0);break;case 2:a.writeUInt16BE(e[s],l,!0);break;case 3:a.writeUInt32BE(e[s],l,!0);break;case 4:a.writeDoubleBE(e[s],l,!0);break;case 5:a.write(e[s],l,u,"utf8");break;default:throw new Error("unkown method")}l+=u}var c=a;return this._reset(),c}_reset(){this.result=[],this.resultMethod=[],this.resultLength=[],this.offset=0}static encode(e){const t=new S,n=t.pushAny(e);if(!n)throw new Error("Failed to encode input");return t.finalize()}}e.exports=S}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(357),i=n(359),o=n(360),s=n(717),a=o.toCallback,l=o.toBuf,u=o.fromString,c=o.fromNumberTo32BitBuf,h=(e,n)=>{s.sha2256(e,(e,r)=>{e&&n(e),s.sha2256(t.from(r),n)})};e.exports={sha1:s.sha1,sha2256:s.sha2256,sha2512:s.sha2512,sha3512:a(l(r.sha3_512)),sha3384:a(l(r.sha3_384)),sha3256:a(l(r.sha3_256)),sha3224:a(l(r.sha3_224)),shake128:a(l(r.shake_128,128)),shake256:a(l(r.shake_256,256)),keccak224:a(l(r.keccak_224)),keccak256:a(l(r.keccak_256)),keccak384:a(l(r.keccak_384)),keccak512:a(l(r.keccak_512)),murmur3128:a(l(u(i.x64.hash128))),murmur332:a(c(u(i.x86.hash32))),addBlake:n(719),dblSha2256:h}}).call(this,n(0).Buffer)},function(e,t,n){!function(n,r){"use strict";var i={version:"3.0.1",x86:{},x64:{}};function o(e,t){return(65535&e)*t+(((e>>>16)*t&65535)<<16)}function s(e,t){return e<<t|e>>>32-t}function a(e){return e^=e>>>16,e=o(e,2246822507),e^=e>>>13,e=o(e,3266489909),e^=e>>>16,e}function l(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]+t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]+t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]+t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]+t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function u(e,t){e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]],t=[t[0]>>>16,65535&t[0],t[1]>>>16,65535&t[1]];var n=[0,0,0,0];return n[3]+=e[3]*t[3],n[2]+=n[3]>>>16,n[3]&=65535,n[2]+=e[2]*t[3],n[1]+=n[2]>>>16,n[2]&=65535,n[2]+=e[3]*t[2],n[1]+=n[2]>>>16,n[2]&=65535,n[1]+=e[1]*t[3],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[2]*t[2],n[0]+=n[1]>>>16,n[1]&=65535,n[1]+=e[3]*t[1],n[0]+=n[1]>>>16,n[1]&=65535,n[0]+=e[0]*t[3]+e[1]*t[2]+e[2]*t[1]+e[3]*t[0],n[0]&=65535,[n[0]<<16|n[1],n[2]<<16|n[3]]}function c(e,t){return t%=64,32===t?[e[1],e[0]]:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t|e[0]>>>32-t]:(t-=32,[e[1]<<t|e[0]>>>32-t,e[0]<<t|e[1]>>>32-t])}function h(e,t){return t%=64,0===t?e:t<32?[e[0]<<t|e[1]>>>32-t,e[1]<<t]:[e[1]<<t-32,0]}function f(e,t){return[e[0]^t[0],e[1]^t[1]]}function p(e){return e=f(e,[0,e[0]>>>1]),e=u(e,[4283543511,3981806797]),e=f(e,[0,e[0]>>>1]),e=u(e,[3301882366,444984403]),e=f(e,[0,e[0]>>>1]),e}i.x86.hash32=function(e,t){e=e||"",t=t||0;for(var n=e.length%4,r=e.length-n,i=t,l=0,u=3432918353,c=461845907,h=0;h<r;h+=4)l=255&e.charCodeAt(h)|(255&e.charCodeAt(h+1))<<8|(255&e.charCodeAt(h+2))<<16|(255&e.charCodeAt(h+3))<<24,l=o(l,u),l=s(l,15),l=o(l,c),i^=l,i=s(i,13),i=o(i,5)+3864292196;switch(l=0,n){case 3:l^=(255&e.charCodeAt(h+2))<<16;case 2:l^=(255&e.charCodeAt(h+1))<<8;case 1:l^=255&e.charCodeAt(h),l=o(l,u),l=s(l,15),l=o(l,c),i^=l}return i^=e.length,i=a(i),i>>>0},i.x86.hash128=function(e,t){e=e||"",t=t||0;for(var n=e.length%16,r=e.length-n,i=t,l=t,u=t,c=t,h=0,f=0,p=0,d=0,m=597399067,g=2869860233,y=951274213,v=2716044179,b=0;b<r;b+=16)h=255&e.charCodeAt(b)|(255&e.charCodeAt(b+1))<<8|(255&e.charCodeAt(b+2))<<16|(255&e.charCodeAt(b+3))<<24,f=255&e.charCodeAt(b+4)|(255&e.charCodeAt(b+5))<<8|(255&e.charCodeAt(b+6))<<16|(255&e.charCodeAt(b+7))<<24,p=255&e.charCodeAt(b+8)|(255&e.charCodeAt(b+9))<<8|(255&e.charCodeAt(b+10))<<16|(255&e.charCodeAt(b+11))<<24,d=255&e.charCodeAt(b+12)|(255&e.charCodeAt(b+13))<<8|(255&e.charCodeAt(b+14))<<16|(255&e.charCodeAt(b+15))<<24,h=o(h,m),h=s(h,15),h=o(h,g),i^=h,i=s(i,19),i+=l,i=o(i,5)+1444728091,f=o(f,g),f=s(f,16),f=o(f,y),l^=f,l=s(l,17),l+=u,l=o(l,5)+197830471,p=o(p,y),p=s(p,17),p=o(p,v),u^=p,u=s(u,15),u+=c,u=o(u,5)+2530024501,d=o(d,v),d=s(d,18),d=o(d,m),c^=d,c=s(c,13),c+=i,c=o(c,5)+850148119;switch(h=0,f=0,p=0,d=0,n){case 15:d^=e.charCodeAt(b+14)<<16;case 14:d^=e.charCodeAt(b+13)<<8;case 13:d^=e.charCodeAt(b+12),d=o(d,v),d=s(d,18),d=o(d,m),c^=d;case 12:p^=e.charCodeAt(b+11)<<24;case 11:p^=e.charCodeAt(b+10)<<16;case 10:p^=e.charCodeAt(b+9)<<8;case 9:p^=e.charCodeAt(b+8),p=o(p,y),p=s(p,17),p=o(p,v),u^=p;case 8:f^=e.charCodeAt(b+7)<<24;case 7:f^=e.charCodeAt(b+6)<<16;case 6:f^=e.charCodeAt(b+5)<<8;case 5:f^=e.charCodeAt(b+4),f=o(f,g),f=s(f,16),f=o(f,y),l^=f;case 4:h^=e.charCodeAt(b+3)<<24;case 3:h^=e.charCodeAt(b+2)<<16;case 2:h^=e.charCodeAt(b+1)<<8;case 1:h^=e.charCodeAt(b),h=o(h,m),h=s(h,15),h=o(h,g),i^=h}return i^=e.length,l^=e.length,u^=e.length,c^=e.length,i+=l,i+=u,i+=c,l+=i,u+=i,c+=i,i=a(i),l=a(l),u=a(u),c=a(c),i+=l,i+=u,i+=c,l+=i,u+=i,c+=i,("00000000"+(i>>>0).toString(16)).slice(-8)+("00000000"+(l>>>0).toString(16)).slice(-8)+("00000000"+(u>>>0).toString(16)).slice(-8)+("00000000"+(c>>>0).toString(16)).slice(-8)},i.x64.hash128=function(e,t){e=e||"",t=t||0;for(var n=e.length%16,r=e.length-n,i=[0,t],o=[0,t],s=[0,0],a=[0,0],d=[2277735313,289559509],m=[1291169091,658871167],g=0;g<r;g+=16)s=[255&e.charCodeAt(g+4)|(255&e.charCodeAt(g+5))<<8|(255&e.charCodeAt(g+6))<<16|(255&e.charCodeAt(g+7))<<24,255&e.charCodeAt(g)|(255&e.charCodeAt(g+1))<<8|(255&e.charCodeAt(g+2))<<16|(255&e.charCodeAt(g+3))<<24],a=[255&e.charCodeAt(g+12)|(255&e.charCodeAt(g+13))<<8|(255&e.charCodeAt(g+14))<<16|(255&e.charCodeAt(g+15))<<24,255&e.charCodeAt(g+8)|(255&e.charCodeAt(g+9))<<8|(255&e.charCodeAt(g+10))<<16|(255&e.charCodeAt(g+11))<<24],s=u(s,d),s=c(s,31),s=u(s,m),i=f(i,s),i=c(i,27),i=l(i,o),i=l(u(i,[0,5]),[0,1390208809]),a=u(a,m),a=c(a,33),a=u(a,d),o=f(o,a),o=c(o,31),o=l(o,i),o=l(u(o,[0,5]),[0,944331445]);switch(s=[0,0],a=[0,0],n){case 15:a=f(a,h([0,e.charCodeAt(g+14)],48));case 14:a=f(a,h([0,e.charCodeAt(g+13)],40));case 13:a=f(a,h([0,e.charCodeAt(g+12)],32));case 12:a=f(a,h([0,e.charCodeAt(g+11)],24));case 11:a=f(a,h([0,e.charCodeAt(g+10)],16));case 10:a=f(a,h([0,e.charCodeAt(g+9)],8));case 9:a=f(a,[0,e.charCodeAt(g+8)]),a=u(a,m),a=c(a,33),a=u(a,d),o=f(o,a);case 8:s=f(s,h([0,e.charCodeAt(g+7)],56));case 7:s=f(s,h([0,e.charCodeAt(g+6)],48));case 6:s=f(s,h([0,e.charCodeAt(g+5)],40));case 5:s=f(s,h([0,e.charCodeAt(g+4)],32));case 4:s=f(s,h([0,e.charCodeAt(g+3)],24));case 3:s=f(s,h([0,e.charCodeAt(g+2)],16));case 2:s=f(s,h([0,e.charCodeAt(g+1)],8));case 1:s=f(s,[0,e.charCodeAt(g)]),s=u(s,d),s=c(s,31),s=u(s,m),i=f(i,s)}return i=f(i,[0,e.length]),o=f(o,[0,e.length]),i=l(i,o),o=l(o,i),i=p(i),o=p(o),i=l(i,o),o=l(o,i),("00000000"+(i[0]>>>0).toString(16)).slice(-8)+("00000000"+(i[1]>>>0).toString(16)).slice(-8)+("00000000"+(o[0]>>>0).toString(16)).slice(-8)+("00000000"+(o[1]>>>0).toString(16)).slice(-8)},e.exports&&(t=e.exports=i),t.murmurHash3=i}(this)},function(e,t,n){"use strict";(function(t){const r=n(361),i=o();function o(){return self.crypto?self.crypto.subtle||self.crypto.webkitSubtle:self.msCrypto?self.msCrypto.subtle:void 0}function s(e){if(!i)throw new Error("Please use a browser with webcrypto support and ensure the code has been delivered securely via HTTPS/TLS and run within a Secure Context");return(n,o)=>{const s=i.digest({name:e},n);if("function"!=typeof s.then)return s.onerror=(()=>{o(new Error(`hashing data using ${e}`))}),void(s.oncomplete=(e=>{o(null,e.target.result)}));r(s.then(e=>t.from(new Uint8Array(e))),o)}}function a(e,t){s("SHA-1")(e,t)}function l(e,t){s("SHA-256")(e,t)}function u(e,t){s("SHA-512")(e,t)}e.exports={sha1:a,sha2256:l,sha2512:u}}).call(this,n(0).Buffer)},function(e,t,n){(function(t){var r=n(362),i;i="function"==typeof setImediate?setImediate:"object"==typeof t&&t&&t.nextTick?t.nextTick:function(e){setTimeout(e,0)};var o=[];function s(e){if(!(this instanceof s))return"function"==typeof e?new s(e):a();var t=!1,n=!1,l,u=[],c=!1;function h(e){u.length?(c=!0,u.shift()(e||!1)):c=!1}function f(e,r){return new s(function(o){function s(t){var s=n?e:r;if("function"==typeof s){function a(){var e;try{e=s(l)}catch(e){return o.reject(e),h()}o.fulfill(e),h(!0)}t?a():i(a)}else n?(o.fulfill(l),h(t)):(o.reject(l),h(t))}u.push(s),t&&!c&&h()})}this.then=f,function(){function i(e){t||(r(e)?e.then(i,s):(t=n=!0,l=e,h()))}function s(e){t||(t=!0,n=!1,l=e,h())}for(var a={fulfill:i,reject:s},u=0;u<o.length;u++)o[u](this,a);if("function"==typeof e)try{e(a)}catch(e){a.reject(e)}}()}function a(){var e,t=new s(function(t){e=t});return{resolver:e,promise:t}}e.exports=s,s.use=function(e){o.push(e)}}).call(this,n(3))},function(e,t,n){"use strict";(function(t){const r=n(363),i=n(360).toCallback,o=45569,s=45633,a={init:r.blake2bInit,update:r.blake2bUpdate,digest:r.blake2bFinal},l={init:r.blake2sInit,update:r.blake2sUpdate,digest:r.blake2sFinal},u=(e,n)=>i(r=>{const i=n.init(e,null);return n.update(i,r),t.from(n.digest(i))});e.exports=(e=>{for(let t=0;t<64;t++)e[o+t]=u(t+1,a);for(let t=0;t<32;t++)e[s+t]=u(t+1,l)})}).call(this,n(0).Buffer)},function(e,t,n){var r=n(364);function i(e,t,n){var r=e[t]+e[n],i=e[t+1]+e[n+1];r>=4294967296&&i++,e[t]=r,e[t+1]=i}function o(e,t,n,r){var i=e[t]+n;n<0&&(i+=4294967296);var o=e[t+1]+r;i>=4294967296&&o++,e[t]=i,e[t+1]=o}function s(e,t){return e[t]^e[t+1]<<8^e[t+2]<<16^e[t+3]<<24}function a(e,t,n,r,s,a){var l=f[s],u=f[s+1],c=f[a],p=f[a+1];i(h,e,t),o(h,e,l,u);var d=h[r]^h[e],m=h[r+1]^h[e+1];h[r]=m,h[r+1]=d,i(h,n,r),d=h[t]^h[n],m=h[t+1]^h[n+1],h[t]=d>>>24^m<<8,h[t+1]=m>>>24^d<<8,i(h,e,t),o(h,e,c,p),d=h[r]^h[e],m=h[r+1]^h[e+1],h[r]=d>>>16^m<<16,h[r+1]=m>>>16^d<<16,i(h,n,r),d=h[t]^h[n],m=h[t+1]^h[n+1],h[t]=m>>>31^d<<1,h[t+1]=d>>>31^m<<1}var l=new Uint32Array([4089235720,1779033703,2227873595,3144134277,4271175723,1013904242,1595750129,2773480762,2917565137,1359893119,725511199,2600822924,4215389547,528734635,327033209,1541459225]),u=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3,11,8,12,0,5,2,15,13,10,14,3,6,7,1,9,4,7,9,3,1,13,12,11,14,2,6,5,10,4,0,15,8,9,0,5,7,2,4,10,15,14,1,11,12,6,8,3,13,2,12,6,10,0,11,8,3,4,13,7,5,15,14,1,9,12,5,1,15,14,13,4,10,0,7,6,3,9,2,8,11,13,11,7,14,12,1,3,9,5,0,15,4,8,6,2,10,6,15,14,9,11,3,0,8,12,2,13,7,1,4,10,5,10,2,8,4,7,6,1,5,15,11,9,14,3,12,13,0,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3],c=new Uint8Array(u.map(function(e){return 2*e})),h=new Uint32Array(32),f=new Uint32Array(32);function p(e,t){var n=0;for(n=0;n<16;n++)h[n]=e.h[n],h[n+16]=l[n];for(h[24]=h[24]^e.t,h[25]=h[25]^e.t/4294967296,t&&(h[28]=~h[28],h[29]=~h[29]),n=0;n<32;n++)f[n]=s(e.b,4*n);for(n=0;n<12;n++)a(0,8,16,24,c[16*n+0],c[16*n+1]),a(2,10,18,26,c[16*n+2],c[16*n+3]),a(4,12,20,28,c[16*n+4],c[16*n+5]),a(6,14,22,30,c[16*n+6],c[16*n+7]),a(0,10,20,30,c[16*n+8],c[16*n+9]),a(2,12,22,24,c[16*n+10],c[16*n+11]),a(4,14,16,26,c[16*n+12],c[16*n+13]),a(6,8,18,28,c[16*n+14],c[16*n+15]);for(n=0;n<16;n++)e.h[n]=e.h[n]^h[n]^h[n+16]}function d(e,t){if(0===e||e>64)throw new Error("Illegal output length, expected 0 < length <= 64");if(t&&t.length>64)throw new Error("Illegal key, expected Uint8Array with 0 < length <= 64");for(var n={b:new Uint8Array(128),h:new Uint32Array(16),t:0,c:0,outlen:e},r=0;r<16;r++)n.h[r]=l[r];var i=t?t.length:0;return n.h[0]^=16842752^i<<8^e,t&&(m(n,t),n.c=128),n}function m(e,t){for(var n=0;n<t.length;n++)128===e.c&&(e.t+=e.c,p(e,!1),e.c=0),e.b[e.c++]=t[n]}function g(e){for(e.t+=e.c;e.c<128;)e.b[e.c++]=0;p(e,!0);for(var t=new Uint8Array(e.outlen),n=0;n<e.outlen;n++)t[n]=e.h[n>>2]>>8*(3&n);return t}function y(e,t,n){n=n||64,e=r.normalizeInput(e);var i=d(n,t);return m(i,e),g(i)}function v(e,t,n){var i=y(e,t,n);return r.toHex(i)}e.exports={blake2b:y,blake2bHex:v,blake2bInit:d,blake2bUpdate:m,blake2bFinal:g}},function(e,t,n){var r=n(364);function i(e,t){return e[t]^e[t+1]<<8^e[t+2]<<16^e[t+3]<<24}function o(e,t,n,r,i,o){u[e]=u[e]+u[t]+i,u[r]=s(u[r]^u[e],16),u[n]=u[n]+u[r],u[t]=s(u[t]^u[n],12),u[e]=u[e]+u[t]+o,u[r]=s(u[r]^u[e],8),u[n]=u[n]+u[r],u[t]=s(u[t]^u[n],7)}function s(e,t){return e>>>t^e<<32-t}var a=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),l=new Uint8Array([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3,11,8,12,0,5,2,15,13,10,14,3,6,7,1,9,4,7,9,3,1,13,12,11,14,2,6,5,10,4,0,15,8,9,0,5,7,2,4,10,15,14,1,11,12,6,8,3,13,2,12,6,10,0,11,8,3,4,13,7,5,15,14,1,9,12,5,1,15,14,13,4,10,0,7,6,3,9,2,8,11,13,11,7,14,12,1,3,9,5,0,15,4,8,6,2,10,6,15,14,9,11,3,0,8,12,2,13,7,1,4,10,5,10,2,8,4,7,6,1,5,15,11,9,14,3,12,13,0]),u=new Uint32Array(16),c=new Uint32Array(16);function h(e,t){var n=0;for(n=0;n<8;n++)u[n]=e.h[n],u[n+8]=a[n];for(u[12]^=e.t,u[13]^=e.t/4294967296,t&&(u[14]=~u[14]),n=0;n<16;n++)c[n]=i(e.b,4*n);for(n=0;n<10;n++)o(0,4,8,12,c[l[16*n+0]],c[l[16*n+1]]),o(1,5,9,13,c[l[16*n+2]],c[l[16*n+3]]),o(2,6,10,14,c[l[16*n+4]],c[l[16*n+5]]),o(3,7,11,15,c[l[16*n+6]],c[l[16*n+7]]),o(0,5,10,15,c[l[16*n+8]],c[l[16*n+9]]),o(1,6,11,12,c[l[16*n+10]],c[l[16*n+11]]),o(2,7,8,13,c[l[16*n+12]],c[l[16*n+13]]),o(3,4,9,14,c[l[16*n+14]],c[l[16*n+15]]);for(n=0;n<8;n++)e.h[n]^=u[n]^u[n+8]}function f(e,t){if(!(e>0&&e<=32))throw new Error("Incorrect output length, should be in [1, 32]");var n=t?t.length:0;if(t&&!(n>0&&n<=32))throw new Error("Incorrect key length, should be in [1, 32]");var r={h:new Uint32Array(a),b:new Uint32Array(64),c:0,t:0,outlen:e};return r.h[0]^=16842752^n<<8^e,n>0&&(p(r,t),r.c=64),r}function p(e,t){for(var n=0;n<t.length;n++)64===e.c&&(e.t+=e.c,h(e,!1),e.c=0),e.b[e.c++]=t[n]}function d(e){for(e.t+=e.c;e.c<64;)e.b[e.c++]=0;h(e,!0);for(var t=new Uint8Array(e.outlen),n=0;n<e.outlen;n++)t[n]=e.h[n>>2]>>8*(3&n)&255;return t}function m(e,t,n){n=n||32,e=r.normalizeInput(e);var i=f(n,t);return p(i,e),d(i)}function g(e,t,n){var i=m(e,t,n);return r.toHex(i)}e.exports={blake2s:m,blake2sHex:g,blake2sInit:f,blake2sUpdate:p,blake2sFinal:d}},function(e,t,n){var r=n(723);function i(e){if(!(e instanceof Object))throw new TypeError('"obj" must be an object (or inherit from it)');return o(e)}function o(e,t){for(var n in t=new r(e,t),e){var i=e[n];if(i instanceof Object&&(t.contains(i)||o(i,t)))return!0}return!1}e.exports=i},function(e,t){function n(e,t){this.value=e,this.next=t}e.exports=n,n.prototype.contains=function(e){for(var t=this;t;){if(t.value===e)return!0;t=t.next}return!1}},function(e,t){var n=e.exports=function(e){return new r(e)};function r(e){this.value=e}function i(e,t,n){var r=[],i=[],a=!0;return function e(l){var u=n?o(l):l,c={},h=!0,f={node:u,node_:l,path:[].concat(r),parent:i[i.length-1],parents:i,key:r.slice(-1)[0],isRoot:0===r.length,level:r.length,circular:null,update:function(e,t){f.isRoot||(f.parent.node[f.key]=e),f.node=e,t&&(h=!1)},delete:function(e){delete f.parent.node[f.key],e&&(h=!1)},remove:function(e){d(f.parent.node)?f.parent.node.splice(f.key,1):delete f.parent.node[f.key],e&&(h=!1)},keys:null,before:function(e){c.before=e},after:function(e){c.after=e},pre:function(e){c.pre=e},post:function(e){c.post=e},stop:function(){a=!1},block:function(){h=!1}};if(!a)return f;function p(){if("object"==typeof f.node&&null!==f.node){f.keys&&f.node_===f.node||(f.keys=s(f.node)),f.isLeaf=0==f.keys.length;for(var e=0;e<i.length;e++)if(i[e].node_===l){f.circular=i[e];break}}else f.isLeaf=!0,f.keys=null;f.notLeaf=!f.isLeaf,f.notRoot=!f.isRoot}p();var y=t.call(f,f.node);return void 0!==y&&f.update&&f.update(y),c.before&&c.before.call(f,f.node),h?("object"!=typeof f.node||null===f.node||f.circular||(i.push(f),p(),m(f.keys,function(t,i){r.push(t),c.pre&&c.pre.call(f,f.node[t],t);var o=e(f.node[t]);n&&g.call(f.node,t)&&(f.node[t]=o.node),o.isLast=i==f.keys.length-1,o.isFirst=0==i,c.post&&c.post.call(f,o),r.pop()}),i.pop()),c.after&&c.after.call(f,f.node),f):f}(e).node}function o(e){if("object"==typeof e&&null!==e){var t;if(d(e))t=[];else if(l(e))t=new Date(e.getTime?e.getTime():e);else if(u(e))t=new RegExp(e);else if(c(e))t={message:e.message};else if(h(e))t=new Boolean(e);else if(f(e))t=new Number(e);else if(p(e))t=new String(e);else if(Object.create&&Object.getPrototypeOf)t=Object.create(Object.getPrototypeOf(e));else if(e.constructor===Object)t={};else{var n=e.constructor&&e.constructor.prototype||e.__proto__||{},r=function(){};r.prototype=n,t=new r}return m(s(e),function(n){t[n]=e[n]}),t}return e}r.prototype.get=function(e){for(var t=this.value,n=0;n<e.length;n++){var r=e[n];if(!t||!g.call(t,r)){t=void 0;break}t=t[r]}return t},r.prototype.has=function(e){for(var t=this.value,n=0;n<e.length;n++){var r=e[n];if(!t||!g.call(t,r))return!1;t=t[r]}return!0},r.prototype.set=function(e,t){for(var n=this.value,r=0;r<e.length-1;r++){var i=e[r];g.call(n,i)||(n[i]={}),n=n[i]}return n[e[r]]=t,t},r.prototype.map=function(e){return i(this.value,e,!0)},r.prototype.forEach=function(e){return this.value=i(this.value,e,!1),this.value},r.prototype.reduce=function(e,t){var n=1===arguments.length,r=n?this.value:t;return this.forEach(function(t){this.isRoot&&n||(r=e.call(this,r,t))}),r},r.prototype.paths=function(){var e=[];return this.forEach(function(t){e.push(this.path)}),e},r.prototype.nodes=function(){var e=[];return this.forEach(function(t){e.push(this.node)}),e},r.prototype.clone=function(){var e=[],t=[];return function n(r){for(var i=0;i<e.length;i++)if(e[i]===r)return t[i];if("object"==typeof r&&null!==r){var a=o(r);return e.push(r),t.push(a),m(s(r),function(e){a[e]=n(r[e])}),e.pop(),t.pop(),a}return r}(this.value)};var s=Object.keys||function e(t){var n=[];for(var r in t)n.push(r);return n};function a(e){return Object.prototype.toString.call(e)}function l(e){return"[object Date]"===a(e)}function u(e){return"[object RegExp]"===a(e)}function c(e){return"[object Error]"===a(e)}function h(e){return"[object Boolean]"===a(e)}function f(e){return"[object Number]"===a(e)}function p(e){return"[object String]"===a(e)}var d=Array.isArray||function e(t){return"[object Array]"===Object.prototype.toString.call(t)},m=function(e,t){if(e.forEach)return e.forEach(t);for(var n=0;n<e.length;n++)t(e[n],n,e)};m(s(r.prototype),function(e){n[e]=function(t){var n=[].slice.call(arguments,1),i=new r(t);return i[e].apply(i,n)}});var g=Object.hasOwnProperty||function(e,t){return t in e}},function(e,t,n){"use strict";
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function s(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function a(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(e){return t[e]});if("0123456789"!==r.join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach(function(e){i[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(e){return!1}}e.exports=a()?Object.assign:function(e,t){for(var n,a=s(e),l,u=1;u<arguments.length;u++){for(var c in n=Object(arguments[u]),n)i.call(n,c)&&(a[c]=n[c]);if(r){l=r(n);for(var h=0;h<l.length;h++)o.call(n,l[h])&&(a[l[h]]=n[l[h]])}}return a}},function(e,t){e.exports=function e(t){return t&&"object"==typeof t&&"function"==typeof t.copy&&"function"==typeof t.fill&&"function"==typeof t.readUInt8}},function(e,t){"function"==typeof Object.create?e.exports=function e(t,n){t.super_=n,t.prototype=Object.create(n.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function e(t,n){t.super_=n;var r=function(){};r.prototype=n.prototype,t.prototype=new r,t.prototype.constructor=t}},function(e,t,n){
//! stable.js 0.1.8, https://github.com/Two-Screen/stable
//! © 2018 Angry Bytes and contributors. MIT licensed.
var r,i;r=this,i=function(){"use strict";var e=function(e,n){return t(e.slice(),n)};function t(e,t){"function"!=typeof t&&(t=function(e,t){return String(e).localeCompare(t)});var r=e.length;if(r<=1)return e;for(var i=new Array(r),o=1;o<r;o*=2){n(e,t,o,i);var s=e;e=i,i=s}return e}e.inplace=function(e,r){var i=t(e,r);return i!==e&&n(i,null,e.length,e),e};var n=function(e,t,n,r){var i=e.length,o=0,s=2*n,a,l,u,c,h;for(a=0;a<i;a+=s)for(l=a+n,u=l+n,l>i&&(l=i),u>i&&(u=i),c=a,h=l;;)if(c<l&&h<u)t(e[c],e[h])<=0?r[o++]=e[c++]:r[o++]=e[h++];else if(c<l)r[o++]=e[c++];else{if(!(h<u))break;r[o++]=e[h++]}};return e},e.exports=i()},function(e,t,n){var r=n(730),i=n(732);e.exports=r,e.exports.parse=r,e.exports.stringify=i},function(e,t,n){var r=n(731),i=536870911,o=["int32","int64","uint32","uint64","sint32","sint64","bool","fixed64","sfixed64","double","fixed32","sfixed32","float"],s=function(e){for(var t={};e.length;)switch(e[0]){case"[":case",":e.shift();var n=e.shift();if("("===n&&(n=e.shift(),e.shift()),"="!==e[0])throw new Error("Unexpected token in field options: "+e[0]);if(e.shift(),"]"===e[0])throw new Error("Unexpected ] in field option");t[n]=e.shift();break;case"]":return e.shift(),t;default:throw new Error("Unexpected token in field options: "+e[0])}throw new Error("No closing tag for field options")},a=function(e){for(var t={name:null,type:null,tag:-1,map:null,oneof:null,required:!1,repeated:!1,options:{}};e.length;)switch(e[0]){case"=":e.shift(),t.tag=Number(e.shift());break;case"map":if(t.type="map",t.map={from:null,to:null},e.shift(),"<"!==e[0])throw new Error("Unexpected token in map type: "+e[0]);if(e.shift(),t.map.from=e.shift(),","!==e[0])throw new Error("Unexpected token in map type: "+e[0]);if(e.shift(),t.map.to=e.shift(),">"!==e[0])throw new Error("Unexpected token in map type: "+e[0]);e.shift(),t.name=e.shift();break;case"repeated":case"required":case"optional":var n=e.shift();t.required="required"===n,t.repeated="repeated"===n,t.type=e.shift(),t.name=e.shift();break;case"[":t.options=s(e);break;case";":if(null===t.name)throw new Error("Missing field name");if(null===t.type)throw new Error("Missing type in message field: "+t.name);if(-1===t.tag)throw new Error("Missing tag number in message field: "+t.name);return e.shift(),t;default:throw new Error("Unexpected token in message field: "+e[0])}throw new Error("No ; found for message field")},l=function(e){for(var t={enums:[],messages:[],fields:[],extends:[],extensions:null};e.length;)switch(e[0]){case"map":case"repeated":case"optional":case"required":t.fields.push(a(e));break;case"enum":t.enums.push(m(e));break;case"message":t.messages.push(h(e));break;case"extensions":t.extensions=c(e);break;case"oneof":e.shift();var n=e.shift();if("{"!==e[0])throw new Error("Unexpected token in oneof: "+e[0]);for(e.shift();"}"!==e[0];){e.unshift("optional");var r=a(e);r.oneof=n,t.fields.push(r)}e.shift();break;case"extend":t.extends.push(u(e));break;case";":e.shift();break;case"reserved":case"option":for(e.shift();";"!==e[0];)e.shift();break;default:e.unshift("optional"),t.fields.push(a(e))}return t},u=function(e){var t={name:e[1],message:h(e)};return t},c=function(e){e.shift();var t=Number(e.shift());if(isNaN(t))throw new Error("Invalid from in extensions definition");if("to"!==e.shift())throw new Error("Expected keyword 'to' in extensions definition");var n=e.shift();if("max"===n&&(n=536870911),n=Number(n),isNaN(n))throw new Error("Invalid to in extensions definition");if(";"!==e.shift())throw new Error("Missing ; in extensions definition");return{from:t,to:n}},h=function(e){e.shift();var t=1,n=[],r={name:e.shift(),enums:[],extends:[],messages:[],fields:[]};if("{"!==e[0])throw new Error("Expected { but found "+e[0]);for(e.shift();e.length;){if("{"===e[0]?t++:"}"===e[0]&&t--,!t)return e.shift(),n=l(n),r.enums=n.enums,r.messages=n.messages,r.fields=n.fields,r.extends=n.extends,r.extensions=n.extensions,r;n.push(e.shift())}if(t)throw new Error("No closing tag for message")},f=function(e){e.shift();var t=e.shift();if(";"!==e[0])throw new Error("Expected ; but found "+e[0]);return e.shift(),t},p=function(e){if(e.shift(),"="!==e[0])throw new Error("Expected = but found "+e[0]);e.shift();var t=e.shift();switch(t){case'"proto2"':t=2;break;case'"proto3"':t=3;break;default:throw new Error("Expected protobuf syntax version but found "+t)}if(";"!==e[0])throw new Error("Expected ; but found "+e[0]);return e.shift(),t},d=function(e){if(e.length<4)throw new Error("Invalid enum value: "+e.slice(0,3).join(" "));if("="!==e[1])throw new Error("Expected = but found "+e[1]);if(";"!==e[3]&&"["!==e[3])throw new Error("Expected ; or [ but found "+e[1]);var t=e.shift();e.shift();var n={value:null,options:{}};return n.value=Number(e.shift()),"["===e[0]&&(n.options=s(e)),e.shift(),{name:t,val:n}},m=function(e){e.shift();var t={},n={name:e.shift(),values:{},options:{}};if("{"!==e[0])throw new Error("Expected { but found "+e[0]);for(e.shift();e.length;){if("}"===e[0])return e.shift(),";"===e[0]&&e.shift(),n;if("option"!==e[0]){var r=d(e);n.values[r.name]=r.val}else t=g(e),n.options[t.name]=t.value}throw new Error("No closing tag for enum")},g=function(e){for(var t=null,n=null,r=function(e){return"true"===e||"false"!==e&&e.replace(/^"+|"+$/gm,"")};e.length;){if(";"===e[0])return e.shift(),{name:t,value:n};switch(e[0]){case"option":e.shift();var i="("===e[0];if(i&&e.shift(),t=e.shift(),i){if(")"!==e[0])throw new Error("Expected ) but found "+e[0]);e.shift()}"."===e[0][0]&&(t+=e.shift());break;case"=":if(e.shift(),null===t)throw new Error("Expected key for option with value: "+e[0]);if(n=r(e.shift()),"optimize_for"===t&&!/^(SPEED|CODE_SIZE|LITE_RUNTIME)$/.test(n))throw new Error("Unexpected value for option optimize_for: "+n);"{"===n&&(n=y(e));break;default:throw new Error("Unexpected token in option: "+e[0])}}},y=function(e){for(var t=function(e){return"true"===e||"false"!==e&&e.replace(/^"+|"+$/gm,"")},n={};e.length;){if("}"===e[0])return e.shift(),n;var r="("===e[0];r&&e.shift();var i=e.shift();if(r){if(")"!==e[0])throw new Error("Expected ) but found "+e[0]);e.shift()}var o=null;switch(e[0]){case":":if(void 0!==n[i])throw new Error("Duplicate option map key "+i);e.shift(),o=t(e.shift()),"{"===o&&(o=y(e)),n[i]=o,";"===e[0]&&e.shift();break;case"{":if(e.shift(),o=y(e),void 0===n[i]&&(n[i]=[]),!Array.isArray(n[i]))throw new Error("Duplicate option map key "+i);n[i].push(o);break;default:throw new Error("Unexpected token in option map: "+e[0])}}throw new Error("No closing tag for option map")},v=function(e){e.shift();var t=e.shift().replace(/^"+|"+$/gm,"");if(";"!==e[0])throw new Error("Unexpected token: "+e[0]+'. Expected ";"');return e.shift(),t},b=function(e){e.shift();var t={name:e.shift(),methods:[],options:{}};if("{"!==e[0])throw new Error("Expected { but found "+e[0]);for(e.shift();e.length;){if("}"===e[0])return e.shift(),";"===e[0]&&e.shift(),t;switch(e[0]){case"option":var n=g(e);if(void 0!==t.options[n.name])throw new Error("Duplicate option "+n.name);t.options[n.name]=n.value;break;case"rpc":t.methods.push(_(e));break;default:throw new Error("Unexpected token in service: "+e[0])}}throw new Error("No closing tag for service")},_=function(e){e.shift();var t={name:e.shift(),input_type:null,output_type:null,client_streaming:!1,server_streaming:!1,options:{}};if("("!==e[0])throw new Error("Expected ( but found "+e[0]);if(e.shift(),"stream"===e[0]&&(e.shift(),t.client_streaming=!0),t.input_type=e.shift(),")"!==e[0])throw new Error("Expected ) but found "+e[0]);if(e.shift(),"returns"!==e[0])throw new Error("Expected returns but found "+e[0]);if(e.shift(),"("!==e[0])throw new Error("Expected ( but found "+e[0]);if(e.shift(),"stream"===e[0]&&(e.shift(),t.server_streaming=!0),t.output_type=e.shift(),")"!==e[0])throw new Error("Expected ) but found "+e[0]);if(e.shift(),";"===e[0])return e.shift(),t;if("{"!==e[0])throw new Error("Expected { but found "+e[0]);for(e.shift();e.length;){if("}"===e[0])return e.shift(),";"===e[0]&&e.shift(),t;if("option"!==e[0])throw new Error("Unexpected token in rpc options: "+e[0]);var n=g(e);if(void 0!==t.options[n.name])throw new Error("Duplicate option "+n.name);t.options[n.name]=n.value}throw new Error("No closing tag for rpc")},w=function(e){for(var t=r(e.toString()),n=0;n<t.length;n++){var i;if(/^("|')([^'"]*)$/.test(t[n]))for(i=1===t[n].length?n+1:n;i<t.length;i++)if(/^([^'"]*)("|')$/.test(t[i])){t=t.slice(0,n).concat(t.slice(n,i+1).join("")).concat(t.slice(i+1));break}}for(var s={syntax:3,package:null,imports:[],enums:[],messages:[],options:{},extends:[]},a=!0;t.length;){switch(t[0]){case"package":s.package=f(t);break;case"syntax":if(!a)throw new Error("Protobuf syntax version should be first thing in file");s.syntax=p(t);break;case"message":s.messages.push(h(t));break;case"enum":s.enums.push(m(t));break;case"option":var l=g(t);if(s.options[l.name])throw new Error("Duplicate option "+l.name);s.options[l.name]=l.value;break;case"import":s.imports.push(v(t));break;case"extend":s.extends.push(u(t));break;case"service":s.services||(s.services=[]),s.services.push(b(t));break;default:throw new Error("Unexpected token: "+t[0])}a=!1}return s.extends.forEach(function(e){s.messages.forEach(function(t){t.name===e.name&&e.message.fields.forEach(function(e){if(!t.extensions||e.tag<t.extensions.from||e.tag>t.extensions.to)throw new Error(t.name+" does not declare "+e.tag+" as an extension number");t.fields.push(e)})})}),s.messages.forEach(function(e){e.fields.forEach(function(t){var n,r,i,a;function l(e){return e.name===t.type}function u(e){return e.name===i}if(t.options&&"true"===t.options.packed&&-1===o.indexOf(t.type)){if(-1===t.type.indexOf(".")){if(e.enums&&e.enums.some(l))return}else{if(n=t.type.split("."),n.length>2)throw new Error("what is this?");if(r=n[0],i=n[1],s.messages.some(function(e){if(e.name===r)return a=e,e}),a&&a.enums&&a.enums.some(u))return}throw new Error("Fields of type "+t.type+' cannot be declared [packed=true]. Only repeated fields of primitive numeric types (types which use the varint, 32-bit, or 64-bit wire types) can be declared "packed". See https://developers.google.com/protocol-buffers/docs/encoding#optional')}})}),s};e.exports=w},function(e,t){e.exports=function(e){var t=function(e){var t=e.indexOf("//");return t>-1?e.slice(0,t):e},n=function(){var e=!1;return function(t){return"/*"===t?(e=!0,!1):"*/"===t?(e=!1,!1):!e}},r=function(e){return e.trim()};return e.replace(/([;,{}()=:[\]<>]|\/\*|\*\/)/g," $1 ").split(/\n/).map(r).filter(Boolean).map(t).map(r).filter(Boolean).join("\n").split(/\s+|\n+/gm).filter(n())}},function(e,t){var n=function(e,t){var n=e.repeated?"repeated":e.required?"required":"optional";"map"===e.type&&(n="map<"+e.map.from+","+e.map.to+">"),e.oneof&&(n="");var r=Object.keys(e.options||{}).map(function(t){return t+" = "+e.options[t]}).join(",");return r&&(r=" ["+r+"]"),t.push((n?n+" ":"")+("map"===e.map?"":e.type+" ")+e.name+" = "+e.tag+r+";"),t},r=function(e,t){t.push("message "+e.name+" {"),e.enums||(e.enums=[]),e.enums.forEach(function(e){t.push(i(e,[]))}),e.messages||(e.messages=[]),e.messages.forEach(function(e){t.push(r(e,[]))});var o={};return e.fields||(e.fields=[]),e.fields.forEach(function(e){e.oneof?(o[e.oneof]||(o[e.oneof]=[]),o[e.oneof].push(n(e,[]))):t.push(n(e,[]))}),Object.keys(o).forEach(function(e){o[e].unshift("oneof "+e+" {"),o[e].push("}"),t.push(o[e])}),t.push("}",""),t},i=function(e,t){t.push("enum "+e.name+" {"),e.options||(e.options={});var n=s(e.options,[]);return n.length>1&&t.push(n.slice(0,-1)),Object.keys(e.values).map(function(n){var r=o(e.values[n]);t.push([n+" = "+r+";"])}),t.push("}",""),t},o=function(e,t){var n=Object.keys(e.options||{}).map(function(t){return t+" = "+e.options[t]}).join(",");n&&(n=" ["+n+"]");var r=e.value+n;return r},s=function(e,t){var n=Object.keys(e);return n.forEach(function(n){var r=e[n];~n.indexOf(".")&&(n="("+n+")");var i=typeof r;"object"===i?(r=a(r,[]),r.length&&t.push("option "+n+" = {",r,"};")):("string"===i&&"optimize_for"!==n&&(r='"'+r+'"'),t.push("option "+n+" = "+r+";"))}),n.length>0&&t.push(""),t},a=function(e,t){var n=Object.keys(e);return n.forEach(function(n){var r=e[n],i=typeof r;"object"===i?Array.isArray(r)?r.forEach(function(e){e=a(e,[]),e.length&&t.push(n+" {",e,"}")}):(r=a(r,[]),r.length&&t.push(n+" {",r,"}")):("string"===i&&(r='"'+r+'"'),t.push(n+": "+r))}),t},l=function(e,t){return t.push("service "+e.name+" {"),e.options||(e.options={}),s(e.options,t),e.methods||(e.methods=[]),e.methods.forEach(function(e){t.push(u(e,[]))}),t.push("}",""),t},u=function(e,t){var n="rpc "+e.name+"(";e.client_streaming&&(n+="stream "),n+=e.input_type+") returns (",e.server_streaming&&(n+="stream "),n+=e.output_type+")",e.options||(e.options={});var r=s(e.options,[]);return r.length>1?t.push(n+" {",r.slice(0,-1),"}"):t.push(n+";"),t},c=function(e){return function(t){return Array.isArray(t)?t.map(c(e+" ")).join("\n"):e+t}};e.exports=function(e){var t=[];return t.push('syntax = "proto'+e.syntax+'";',""),e.package&&t.push("package "+e.package+";",""),e.options||(e.options={}),s(e.options,t),e.enums||(e.enums=[]),e.enums.forEach(function(e){i(e,t)}),e.messages||(e.messages=[]),e.messages.forEach(function(e){r(e,t)}),e.services&&e.services.forEach(function(e){l(e,t)}),t.map(c("")).join("\n")}},function(e,t,n){"use strict";var r=n(734),i=n(736),o=n(737),s=n(738),a=n(35),l=function(e){if(!e)return null;var t={};return Object.keys(e).forEach(function(n){t[n]=e[n].value}),t};e.exports=function(e,t){var n={},u={},c={},h=function(e,t){e.enums&&e.enums.forEach(function(e){e.id=t+(t?".":"")+e.name,u[e.id]=e,h(e,e.id)}),e.messages&&e.messages.forEach(function(r){r.id=t+(t?".":"")+r.name,n[r.id]=r,r.fields.forEach(function(r){if(r.map){var i="Map_"+r.map.from+"_"+r.map.to,o={name:i,enums:[],messages:[],fields:[{name:"key",type:r.map.from,tag:1,repeated:!1,required:!0},{name:"value",type:r.map.to,tag:2,repeated:!1,required:!1}],extensions:null,id:t+(t?".":"")+i};n[o.id]||(n[o.id]=o,e.messages.push(o)),r.type=i,r.repeated=!0}}),h(r,r.id)})};h(e,"");var f=function(e){var t=Object.keys(e.values||[]).map(function(t){return parseInt(e.values[t].value,10)}),n=function e(n,r,i){if(!t.length||-1===t.indexOf(n))throw new Error("Invalid enum value: "+n);return a.encode(n,r,i),e.bytes=a.encode.bytes,r},i=function e(n,r){var i=a.decode(n,r);if(!t.length||-1===t.indexOf(i))throw new Error("Invalid enum value: "+i);return e.bytes=a.decode.bytes,i};return r.make(0,n,i,a.encodingLength)},p=function(e,t){e.messages.forEach(function(n){t[n.name]=d(n.name,e.id)}),e.enums.forEach(function(e){t[e.name]=l(e.values)}),t.type=2,t.message=!0,t.name=e.name;var n={};e.fields.forEach(function(e){e.oneof&&(n[e.oneof]||(n[e.oneof]=[]),n[e.oneof].push(e.name))});var r=e.fields.map(function(t){return d(t.type,e.id)}),a=s(e,r,n),u=o(e,d,r,n,a),c=i(e,d,r);return u.bytes=c.bytes=0,t.buffer=!0,t.encode=u,t.decode=c,t.encodingLength=a,t},d=function(e,i,o){if(t&&t[e])return t[e];if(r[e])return r[e];var s=(i?i+"."+e:e).split(".").map(function(t,n,r){return r.slice(0,n).concat(e).join(".")}).reverse().reduce(function(e,t){return e||n[t]||u[t]},null);if(!1===o)return s;if(!s)throw new Error("Could not resolve "+e);if(s.values)return f(s);var a=c[s.id]||p(s,c[s.id]={});return a};return(e.enums||[]).concat((e.messages||[]).map(function(e){return d(e.id)}))}},function(e,t,n){"use strict";var r=n(35),i=n(735),o=n(5).Buffer,s=function(e,t,n,r){return t.bytes=n.bytes=0,{type:e,encode:t,decode:n,encodingLength:r}},a,l,u,c,h;t.make=s,t.bytes=(l=function(e){return o.isBuffer(e)?e.length:o.byteLength(e)},u=function(e){var t=l(e);return r.encodingLength(t)+t},c=function(e,t,n){var i=n,s=l(e);return r.encode(s,t,n),n+=r.encode.bytes,o.isBuffer(e)?e.copy(t,n):t.write(e,n,s),n+=s,c.bytes=n-i,t},h=function(e,t){var n=t,i=r.decode(e,t);t+=r.decode.bytes;var o=e.slice(t,t+i);return t+=o.length,h.bytes=t-n,o},s(2,c,h,u)),t.string=function(){var e=function(e){var t=o.byteLength(e);return r.encodingLength(t)+t},t=function(e,n,i){var s=i,a=o.byteLength(e);return r.encode(a,n,i,"utf-8"),i+=r.encode.bytes,n.write(e,i,a),i+=a,t.bytes=i-s,n},n=function(e,t){var i=t,o=r.decode(e,t);t+=r.decode.bytes;var s=e.toString("utf-8",t,t+o);return t+=o,n.bytes=t-i,s};return s(2,t,n,e)}(),t.bool=function(){var e=function(e){return 1},t=function(e,n,r){return n[r]=e?1:0,t.bytes=1,n},n=function(e,t){var r=e[t]>0;return n.bytes=1,r};return s(0,t,n,e)}(),t.int32=function(){var e=function(t,n){var i=r.decode(t,n);return e.bytes=r.decode.bytes,i>2147483647?i-4294967296:i},t=function(e,n,i){return r.encode(e<0?e+4294967296:e,n,i),t.bytes=r.encode.bytes,n},n=function(e){return r.encodingLength(e<0?e+4294967296:e)};return s(0,r.encode,e,n)}(),t.int64=function(){var e=function(t,n){var i=r.decode(t,n);if(i>=Math.pow(2,63)){for(var s=9;255===t[n+s-1];)s--;s=s||9;var a=o.allocUnsafe(s);t.copy(a,0,n,n+s),a[s-1]=127&a[s-1],i=-1*r.decode(a,0),e.bytes=10}else e.bytes=r.decode.bytes;return i},t=function(e,n,i){if(e<0){var o=i+9;for(r.encode(-1*e,n,i),i+=r.encode.bytes-1,n[i]=128|n[i];i<o-1;)i++,n[i]=255;n[o]=1,t.bytes=10}else r.encode(e,n,i),t.bytes=r.encode.bytes;return n},n=function(e){return e<0?10:r.encodingLength(e)};return s(0,t,e,n)}(),t.sint32=t.sint64=s(0,i.encode,i.decode,i.encodingLength),t.uint32=t.uint64=t.enum=t.varint=s(0,r.encode,r.decode,r.encodingLength),t.fixed64=t.sfixed64=function(){var e=function(e){return 8},t=function(e,n,r){return e.copy(n,r),t.bytes=8,n},n=function(e,t){var r=e.slice(t,t+8);return n.bytes=8,r};return s(1,t,n,e)}(),t.double=function(){var e=function(e){return 8},t=function(e,n,r){return n.writeDoubleLE(e,r),t.bytes=8,n},n=function(e,t){var r=e.readDoubleLE(t);return n.bytes=8,r};return s(1,t,n,e)}(),t.fixed32=function(){var e=function(e){return 4},t=function(e,n,r){return n.writeUInt32LE(e,r),t.bytes=4,n},n=function(e,t){var r=e.readUInt32LE(t);return n.bytes=4,r};return s(5,t,n,e)}(),t.sfixed32=function(){var e=function(e){return 4},t=function(e,n,r){return n.writeInt32LE(e,r),t.bytes=4,n},n=function(e,t){var r=e.readInt32LE(t);return n.bytes=4,r};return s(5,t,n,e)}(),t.float=function(){var e=function(e){return 4},t=function(e,n,r){return n.writeFloatLE(e,r),t.bytes=4,n},n=function(e,t){var r=e.readFloatLE(t);return n.bytes=4,r};return s(5,t,n,e)}()},function(e,t,n){var r=n(35);t.encode=function e(t,n,i){t=t>=0?2*t:-2*t-1;var o=r.encode(t,n,i);return e.bytes=r.encode.bytes,o},t.decode=function e(t,n){var i=r.decode(t,n);return e.bytes=r.decode.bytes,1&i?(i+1)/-2:i/2},t.encodingLength=function(e){return r.encodingLength(e>=0?2*e:-2*e-1)}},function(e,t,n){"use strict";var r=n(35),i=n(248).defined;function o(e,t,n){for(var o=[],l={},u=[],c=[],h=0;h<n.length;h++){var f=e.fields[h];l[f.tag]=h;var p=f.options&&f.options.default,d=t(f.type,e.id,!1);c[h]=[p,d&&d.values],e.fields[h].packed=f.repeated&&f.options&&f.options.packed&&"false"!==f.options.packed,f.required&&o.push(f.name),f.oneof&&u.push(f.name)}function m(e,t,n,i,o,s){var a=t.name;if(t.oneof)for(var l=Object.keys(n),c=0;c<l.length;c++)u.indexOf(l[c])>-1&&delete n[l[c]];if(e.message){var h=r.decode(i,o);o+=r.decode.bytes;var f=e.decode(i,o,o+h);t.map?(n[a]=n[a]||{},n[a][f.key]=f.value):t.repeated?(n[a]=n[a]||[],n[a].push(f)):n[a]=f}else t.repeated?(n[a]=n[a]||[],n[a].push(e.decode(i,o))):n[a]=e.decode(i,o);return o+=e.decode.bytes,o}return function t(h,f,p){if(null==f&&(f=0),null==p&&(p=h.length),!(p<=h.length&&f<=h.length))throw new Error("Decoded message is not valid");for(var d=f,g={},y;;){if(p<=f){var v="",b=0,_,w;for(b=0;b<o.length;b++)if(v=o[b],!i(g[v]))throw new Error("Decoded message is not valid, missing required field: "+v);for(b=0;b<n.length;b++)if(y=e.fields[b],w=c[b][0],_=c[b][1],v=y.name,!i(g[v])){var k=!1;if(y.oneof)for(var E=Object.keys(g),S=0;S<E.length;S++)if(u.indexOf(E[S])>-1){k=!0;break}k||(_?y.repeated?g[v]=[]:(w=w&&_[w]?_[w].value:_[Object.keys(_)[0]].value,g[v]=parseInt(w||0,10)):g[v]=a(y,w))}return t.bytes=f-d,g}var x=r.decode(h,f);f+=r.decode.bytes;var C=x>>3,A=l[C];if(null!=A){var T=n[A];if(y=e.fields[A],y.packed){var I=r.decode(h,f);for(f+=r.decode.bytes,I+=f;f<I;)f=m(T,y,g,h,f,A)}else f=m(T,y,g,h,f,A)}else f=s(7&x,h,f)}}}var s=function(e,t,n){switch(e){case 0:return r.decode(t,n),n+r.decode.bytes;case 1:return n+8;case 2:var i=r.decode(t,n);return n+r.decode.bytes+i;case 3:case 4:throw new Error("Groups are not supported");case 5:return n+4;default:throw new Error("Unknown wire type: "+e)}},a=function(e,t){if(e.map)return{};if(e.repeated)return[];switch(e.type){case"string":return null!=t?t:"";case"bool":return"true"===t;case"float":case"double":case"sfixed32":case"fixed32":case"varint":case"enum":case"uint64":case"uint32":case"int64":case"int32":case"sint64":case"sint32":return parseInt(t||0,10);default:return null}};e.exports=o},function(e,t,n){"use strict";(function(t){var r=n(248).defined,i=n(35);function o(e,n,o,s,a){for(var l=Object.keys(s),u=o.length,c={},h=0;h<u;h++){c[h]={p:i.encode(e.fields[h].tag<<3|2),h:i.encode(e.fields[h].tag<<3|o[h].type)};var f=e.fields[h];e.fields[h].packed=f.repeated&&f.options&&f.options.packed&&"false"!==f.options.packed}function p(e,t,n,r,o,s){var a=0;if(!o)for(a=0;a<n.length;a++)e[t++]=n[a];return r.message&&(i.encode(r.encodingLength(s),e,t),t+=i.encode.bytes),r.encode(s,e,t),t+r.encode.bytes}return function n(h,f,d){null==d&&(d=0),null==f&&(f=t.allocUnsafe(a(h)));var m=d,g=Object.keys(h),y=0,v=!1;for(y=0;y<l.length;y++){var b=l[y],_=s[y];if(g.indexOf(_)>-1){if(v)throw new Error("only one of the properties defined in oneof "+b+" can be set");v=!0}}for(y=0;y<u;y++){var w=o[y],k=e.fields[y],E=h[k.name],S=0;if(r(E)){var x=c[y].p,C=c[y].h,A=k.packed,T;if(k.map){var I=Object.keys(E);for(S=0;S<I.length;S++)I[S]={key:I[S],value:E[I[S]]};E=I}if(A){var j=0;for(S=0;S<E.length;S++)r(E[S])&&(j+=w.encodingLength(E[S]));if(j){for(S=0;S<C.length;S++)f[d++]=x[S];i.encode(j,f,d),d+=i.encode.bytes}}if(k.repeated)for(S=0;S<E.length;S++)T=E[S],r(T)&&(d=p(f,d,C,w,A,T));else d=p(f,d,C,w,A,E)}else if(k.required)throw new Error(k.name+" is required")}return n.bytes=d-m,f}}e.exports=o}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=n(248).defined,i=n(35);function o(e,t,n){for(var o=Object.keys(n),s=t.length,a=new Array(s),l=0;l<e.fields.length;l++){a[l]=i.encodingLength(e.fields[l].tag<<3|t[l].type);var u=e.fields[l];e.fields[l].packed=u.repeated&&u.options&&u.options.packed&&"false"!==u.options.packed}return function l(u){var c=0,h=0,f=0;for(h=0;h<o.length;h++){var p=o[h],d=n[p],m=!1;for(f=0;f<d.length;f++)if(r(u[d[f]])){if(m)throw new Error("only one of the properties defined in oneof "+p+" can be set");m=!0}}for(h=0;h<s;h++){var g=t[h],y=e.fields[h],v=u[y.name],b=a[h],_;if(r(v)){if(y.map){var w=Object.keys(v);for(f=0;f<w.length;f++)w[f]={key:w[f],value:v[w[f]]};v=w}if(y.packed){var k=0;for(f=0;f<v.length;f++)r(v[f])&&(_=g.encodingLength(v[f]),k+=_,g.message&&(k+=i.encodingLength(_)));k&&(c+=b+k+i.encodingLength(k))}else if(y.repeated)for(f=0;f<v.length;f++)r(v[f])&&(_=g.encodingLength(v[f]),c+=b+_+(g.message?i.encodingLength(_):0));else _=g.encodingLength(v),c+=b+_+(g.message?i.encodingLength(_):0)}else if(y.required)throw new Error(y.name+" is required")}return c}}e.exports=o},function(e,t,n){"use strict";e.exports="// An IPFS MerkleDAG Link\nmessage PBLink {\n\n // multihash of the target object\n optional bytes Hash = 1;\n\n // utf string name. should be unique per object\n optional string Name = 2;\n\n // cumulative size of target object\n optional uint64 Tsize = 3;\n}\n\n// An IPFS MerkleDAG Node\nmessage PBNode {\n\n // refs to other objects\n repeated PBLink Links = 2;\n\n // opaque user data\n optional bytes Data = 1;\n}"},function(e,t,n){"use strict";const r=n(96);function i(e,t,n,i){const o=new r(e,t,n);i(null,o)}e.exports=i},function(e,t,n){"use strict";const r=n(96);function i(e){return new r(e.name?e.name:e.Name,e.size?e.size:e.Size,e.hash||e.Hash||e.multihash||e.cid)}t=e.exports,t.createDagLinkFromB58EncodedHash=i},function(e,t,n){"use strict";const r=n(195),i=r.cloneLinks,o=r.cloneData,s=n(193);function a(e,t){const n=o(e),r=i(e);s(n,r,t)}e.exports=a},function(e,t,n){"use strict";const r=n(195),i=r.cloneLinks,o=r.cloneData,s=r.toDAGLink,a=n(96),l=n(192),u=n(193);function c(e,t){if(a.isDAGLink(e))return t(null,e);if(l.isDAGNode(e))return s(e,{},t);try{t(null,new a(e.name,e.size,e.multihash||e.hash||e.cid))}catch(e){return t(e)}}function h(e,t,n){const r=i(e),s=o(e);c(t,(e,t)=>{if(e)return n(e);r.push(t),u(s,r,n)})}e.exports=h},function(e,t,n){"use strict";(function(t){const r=n(195),i=r.cloneLinks,o=r.cloneData,s=n(193),a=n(9);function l(e,n,r){const l=o(e);let u=i(e);if("string"==typeof n)u=u.filter(e=>e.name!==n);else{if(!t.isBuffer(n)&&!a.isCID(n))return r(new Error("second arg needs to be a name or CID"),null);u=u.filter(e=>!e.cid.equals(n))}s(l,u,r)}e.exports=l}).call(this,n(0).Buffer)},function(e,t,n){(function(t){var n={};e.exports=n;var r={};function i(e,t){var n=0,r=t.length,i=t.charAt(0),o=[0];for(n=0;n<e.length();++n){for(var s=0,a=e.at(n);s<o.length;++s)a+=o[s]<<8,o[s]=a%r,a=a/r|0;for(;a>0;)o.push(a%r),a=a/r|0}var l="";for(n=0;0===e.at(n)&&n<e.length()-1;++n)l+=i;for(n=o.length-1;n>=0;--n)l+=t[o[n]];return l}n.encode=function(e,t,n){if("string"!=typeof t)throw new TypeError('"alphabet" must be a string.');if(void 0!==n&&"number"!=typeof n)throw new TypeError('"maxline" must be a number.');var r="";if(e instanceof Uint8Array){var o=0,s=t.length,a=t.charAt(0),l=[0];for(o=0;o<e.length;++o){for(var u=0,c=e[o];u<l.length;++u)c+=l[u]<<8,l[u]=c%s,c=c/s|0;for(;c>0;)l.push(c%s),c=c/s|0}for(o=0;0===e[o]&&o<e.length-1;++o)r+=a;for(o=l.length-1;o>=0;--o)r+=t[l[o]]}else r=i(e,t);if(n){var h=new RegExp(".{1,"+n+"}","g");r=r.match(h).join("\r\n")}return r},n.decode=function(e,n){if("string"!=typeof e)throw new TypeError('"input" must be a string.');if("string"!=typeof n)throw new TypeError('"alphabet" must be a string.');var i=r[n];if(!i){i=r[n]=[];for(var o=0;o<n.length;++o)i[n.charCodeAt(o)]=o}e=e.replace(/\s/g,"");for(var s=n.length,a=n.charAt(0),l=[0],o=0;o<e.length;o++){var u=i[e.charCodeAt(o)];if(void 0===u)return;for(var c=0,h=u;c<l.length;++c)h+=l[c]*s,l[c]=255&h,h>>=8;for(;h>0;)l.push(255&h),h>>=8}for(var f=0;e[f]===a&&f<e.length-1;++f)l.push(0);return void 0!==t?t.from(l.reverse()):new Uint8Array(l.reverse())}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(21);n(30),n(118),n(749);var i=e.exports=r.pkcs1=r.pkcs1||{};function o(e,t,n){n||(n=r.md.sha1.create());for(var i="",o=Math.ceil(t/n.digestLength),s=0;s<o;++s){var a=String.fromCharCode(s>>24&255,s>>16&255,s>>8&255,255&s);n.start(),n.update(e+a),i+=n.digest().getBytes()}return i.substring(0,t)}i.encode_rsa_oaep=function(e,t,n){var i,s,a,l;"string"==typeof n?(i=n,s=arguments[3]||void 0,a=arguments[4]||void 0):n&&(i=n.label||void 0,s=n.seed||void 0,a=n.md||void 0,n.mgf1&&n.mgf1.md&&(l=n.mgf1.md)),a?a.start():a=r.md.sha1.create(),l||(l=a);var u=Math.ceil(e.n.bitLength()/8),c=u-2*a.digestLength-2;if(t.length>c){var h=new Error("RSAES-OAEP input message length is too long.");throw h.length=t.length,h.maxLength=c,h}i||(i=""),a.update(i,"raw");for(var f=a.digest(),p="",d=c-t.length,m=0;m<d;m++)p+="\0";var g=f.getBytes()+p+""+t;if(s){if(s.length!==a.digestLength){var h=new Error("Invalid RSAES-OAEP seed. The seed length must match the digest length.");throw h.seedLength=s.length,h.digestLength=a.digestLength,h}}else s=r.random.getBytes(a.digestLength);var y=o(s,u-a.digestLength-1,l),v=r.util.xorBytes(g,y,g.length),b=o(v,a.digestLength,l),_=r.util.xorBytes(s,b,s.length);return"\0"+_+v},i.decode_rsa_oaep=function(e,t,n){var i,s,a;"string"==typeof n?(i=n,s=arguments[3]||void 0):n&&(i=n.label||void 0,s=n.md||void 0,n.mgf1&&n.mgf1.md&&(a=n.mgf1.md));var l=Math.ceil(e.n.bitLength()/8);if(t.length!==l){var u=new Error("RSAES-OAEP encoded message length is invalid.");throw u.length=t.length,u.expectedLength=l,u}if(void 0===s?s=r.md.sha1.create():s.start(),a||(a=s),l<2*s.digestLength+2)throw new Error("RSAES-OAEP key is too short for the hash function.");i||(i=""),s.update(i,"raw");for(var c=s.digest().getBytes(),h=t.charAt(0),f=t.substring(1,s.digestLength+1),p=t.substring(1+s.digestLength),d=o(p,s.digestLength,a),m=r.util.xorBytes(f,d,f.length),g=o(m,l-s.digestLength-1,a),y=r.util.xorBytes(p,g,p.length),v=y.substring(0,s.digestLength),u="\0"!==h,b=0;b<s.digestLength;++b)u|=c.charAt(b)!==v.charAt(b);for(var _=1,w=s.digestLength,k=s.digestLength;k<y.length;k++){var E=y.charCodeAt(k),S=1&E^1,x=_?65534:0;u|=E&x,_&=S,w+=_}if(u||1!==y.charCodeAt(w))throw new Error("Invalid RSAES-OAEP padding.");return y.substring(w+1)}},function(e,t,n){var r=n(21);n(97),n(30);var i=e.exports=r.sha256=r.sha256||{};r.md.sha256=r.md.algorithms.sha256=i,i.create=function(){s||l();var e=null,t=r.util.createBuffer(),n=new Array(64),i={algorithm:"sha256",blockLength:64,digestLength:32,messageLength:0,fullMessageLength:null,messageLengthSize:8,start:function(){i.messageLength=0,i.fullMessageLength=i.messageLength64=[];for(var n=i.messageLengthSize/4,o=0;o<n;++o)i.fullMessageLength.push(0);return t=r.util.createBuffer(),e={h0:1779033703,h1:3144134277,h2:1013904242,h3:2773480762,h4:1359893119,h5:2600822924,h6:528734635,h7:1541459225},i}};return i.start(),i.update=function(o,s){"utf8"===s&&(o=r.util.encodeUtf8(o));var a=o.length;i.messageLength+=a,a=[a/4294967296>>>0,a>>>0];for(var l=i.fullMessageLength.length-1;l>=0;--l)i.fullMessageLength[l]+=a[1],a[1]=a[0]+(i.fullMessageLength[l]/4294967296>>>0),i.fullMessageLength[l]=i.fullMessageLength[l]>>>0,a[0]=a[1]/4294967296>>>0;return t.putBytes(o),u(e,n,t),(t.read>2048||0===t.length())&&t.compact(),i},i.digest=function(){var s=r.util.createBuffer();s.putBytes(t.bytes());var a=i.fullMessageLength[i.fullMessageLength.length-1]+i.messageLengthSize,l=a&i.blockLength-1,c,h;s.putBytes(o.substr(0,i.blockLength-l));for(var f=8*i.fullMessageLength[0],p=0;p<i.fullMessageLength.length-1;++p)c=8*i.fullMessageLength[p+1],h=c/4294967296>>>0,f+=h,s.putInt32(f>>>0),f=c>>>0;s.putInt32(f);var d={h0:e.h0,h1:e.h1,h2:e.h2,h3:e.h3,h4:e.h4,h5:e.h5,h6:e.h6,h7:e.h7};u(d,n,s);var m=r.util.createBuffer();return m.putInt32(d.h0),m.putInt32(d.h1),m.putInt32(d.h2),m.putInt32(d.h3),m.putInt32(d.h4),m.putInt32(d.h5),m.putInt32(d.h6),m.putInt32(d.h7),m},i};var o=null,s=!1,a=null;function l(){o=String.fromCharCode(128),o+=r.util.fillString(String.fromCharCode(0),64),a=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],s=!0}function u(e,t,n){for(var r,i,o,s,l,u,c,h,f,p,d,m,g,y,v,b=n.length();b>=64;){for(c=0;c<16;++c)t[c]=n.getInt32();for(;c<64;++c)r=t[c-2],r=(r>>>17|r<<15)^(r>>>19|r<<13)^r>>>10,i=t[c-15],i=(i>>>7|i<<25)^(i>>>18|i<<14)^i>>>3,t[c]=r+t[c-7]+i+t[c-16]|0;for(h=e.h0,f=e.h1,p=e.h2,d=e.h3,m=e.h4,g=e.h5,y=e.h6,v=e.h7,c=0;c<64;++c)s=(m>>>6|m<<26)^(m>>>11|m<<21)^(m>>>25|m<<7),l=y^m&(g^y),o=(h>>>2|h<<30)^(h>>>13|h<<19)^(h>>>22|h<<10),u=h&f|p&(h^f),r=v+s+l+a[c]+t[c],i=o+u,v=y,y=g,g=m,m=d+r>>>0,d=p,p=f,f=h,h=r+i>>>0;e.h0=e.h0+h|0,e.h1=e.h1+f|0,e.h2=e.h2+p|0,e.h3=e.h3+d|0,e.h4=e.h4+m|0,e.h5=e.h5+g|0,e.h6=e.h6+y|0,e.h7=e.h7+v|0,b-=64}}},function(e,t,n){(function(t){var r=n(21);n(30);var i=null;!r.util.isNodejs||r.options.usePureJavaScript||t.versions["node-webkit"]||(i=n(372));var o=e.exports=r.prng=r.prng||{};o.create=function(e){for(var t={plugin:e,key:null,seed:null,time:null,reseeds:0,generated:0,keyBytes:""},n=e.md,o=new Array(32),s=0;s<32;++s)o[s]=n.create();function a(e){if(t.pools[0].messageLength>=32)return u(),e();var n=32-t.pools[0].messageLength<<5;t.seedFile(n,function(n,r){if(n)return e(n);t.collect(r),u(),e()})}function l(){if(t.pools[0].messageLength>=32)return u();var e=32-t.pools[0].messageLength<<5;t.collect(t.seedFileSync(e)),u()}function u(){t.reseeds=4294967295===t.reseeds?0:t.reseeds+1;var e=t.plugin.md.create();e.update(t.keyBytes);for(var n=1,r=0;r<32;++r)t.reseeds%n==0&&(e.update(t.pools[r].digest().getBytes()),t.pools[r].start()),n<<=1;t.keyBytes=e.digest().getBytes(),e.start(),e.update(t.keyBytes);var i=e.digest().getBytes();t.key=t.plugin.formatKey(t.keyBytes),t.seed=t.plugin.formatSeed(i),t.generated=0}function c(e){var t=null;if("undefined"!=typeof window){var n=window.crypto||window.msCrypto;n&&n.getRandomValues&&(t=function(e){return n.getRandomValues(e)})}var i=r.util.createBuffer();if(t)for(;i.length()<e;){var o=Math.max(1,Math.min(e-i.length(),65536)/4),s=new Uint32Array(Math.floor(o));try{t(s);for(var a=0;a<s.length;++a)i.putInt32(s[a])}catch(e){if(!("undefined"!=typeof QuotaExceededError&&e instanceof QuotaExceededError))throw e}}if(i.length()<e)for(var l,u,c,h=Math.floor(65536*Math.random());i.length()<e;){u=16807*(65535&h),l=16807*(h>>16),u+=(32767&l)<<16,u+=l>>15,u=(2147483647&u)+(u>>31),h=4294967295&u;for(var a=0;a<3;++a)c=h>>>(a<<3),c^=Math.floor(256*Math.random()),i.putByte(String.fromCharCode(255&c))}return i.getBytes(e)}return t.pools=o,t.pool=0,t.generate=function(e,n){if(!n)return t.generateSync(e);var i=t.plugin.cipher,o=t.plugin.increment,s=t.plugin.formatKey,l=t.plugin.formatSeed,u=r.util.createBuffer();function c(h){if(h)return n(h);if(u.length()>=e)return n(null,u.getBytes(e));if(t.generated>1048575&&(t.key=null),null===t.key)return r.util.nextTick(function(){a(c)});var f=i(t.key,t.seed);t.generated+=f.length,u.putBytes(f),t.key=s(i(t.key,o(t.seed))),t.seed=l(i(t.key,t.seed)),r.util.setImmediate(c)}t.key=null,c()},t.generateSync=function(e){var n=t.plugin.cipher,i=t.plugin.increment,o=t.plugin.formatKey,s=t.plugin.formatSeed;t.key=null;for(var a=r.util.createBuffer();a.length()<e;){t.generated>1048575&&(t.key=null),null===t.key&&l();var u=n(t.key,t.seed);t.generated+=u.length,a.putBytes(u),t.key=o(n(t.key,i(t.seed))),t.seed=s(n(t.key,t.seed))}return a.getBytes(e)},i?(t.seedFile=function(e,t){i.randomBytes(e,function(e,n){if(e)return t(e);t(null,n.toString())})},t.seedFileSync=function(e){return i.randomBytes(e).toString()}):(t.seedFile=function(e,t){try{t(null,c(e))}catch(e){t(e)}},t.seedFileSync=c),t.collect=function(e){for(var n=e.length,r=0;r<n;++r)t.pools[t.pool].update(e.substr(r,1)),t.pool=31===t.pool?0:t.pool+1},t.collectInt=function(e,n){for(var r="",i=0;i<n;i+=8)r+=String.fromCharCode(e>>i&255);t.collect(r)},t.registerWorker=function(e){if(e===self)t.seedFile=function(e,t){function n(e){var r=e.data;r.forge&&r.forge.prng&&(self.removeEventListener("message",n),t(r.forge.prng.err,r.forge.prng.bytes))}self.addEventListener("message",n),self.postMessage({forge:{prng:{needed:e}}})};else{var n=function(n){var r=n.data;r.forge&&r.forge.prng&&t.seedFile(r.forge.prng.needed,function(t,n){e.postMessage({forge:{prng:{err:t,bytes:n}}})})};e.addEventListener("message",n)}},t}}).call(this,n(3))},function(e,t,n){var r=n(21);n(97),n(30);var i=e.exports=r.sha1=r.sha1||{};r.md.sha1=r.md.algorithms.sha1=i,i.create=function(){s||a();var e=null,t=r.util.createBuffer(),n=new Array(80),i={algorithm:"sha1",blockLength:64,digestLength:20,messageLength:0,fullMessageLength:null,messageLengthSize:8,start:function(){i.messageLength=0,i.fullMessageLength=i.messageLength64=[];for(var n=i.messageLengthSize/4,o=0;o<n;++o)i.fullMessageLength.push(0);return t=r.util.createBuffer(),e={h0:1732584193,h1:4023233417,h2:2562383102,h3:271733878,h4:3285377520},i}};return i.start(),i.update=function(o,s){"utf8"===s&&(o=r.util.encodeUtf8(o));var a=o.length;i.messageLength+=a,a=[a/4294967296>>>0,a>>>0];for(var u=i.fullMessageLength.length-1;u>=0;--u)i.fullMessageLength[u]+=a[1],a[1]=a[0]+(i.fullMessageLength[u]/4294967296>>>0),i.fullMessageLength[u]=i.fullMessageLength[u]>>>0,a[0]=a[1]/4294967296>>>0;return t.putBytes(o),l(e,n,t),(t.read>2048||0===t.length())&&t.compact(),i},i.digest=function(){var s=r.util.createBuffer();s.putBytes(t.bytes());var a=i.fullMessageLength[i.fullMessageLength.length-1]+i.messageLengthSize,u=a&i.blockLength-1,c,h;s.putBytes(o.substr(0,i.blockLength-u));for(var f=8*i.fullMessageLength[0],p=0;p<i.fullMessageLength.length-1;++p)c=8*i.fullMessageLength[p+1],h=c/4294967296>>>0,f+=h,s.putInt32(f>>>0),f=c>>>0;s.putInt32(f);var d={h0:e.h0,h1:e.h1,h2:e.h2,h3:e.h3,h4:e.h4};l(d,n,s);var m=r.util.createBuffer();return m.putInt32(d.h0),m.putInt32(d.h1),m.putInt32(d.h2),m.putInt32(d.h3),m.putInt32(d.h4),m},i};var o=null,s=!1;function a(){o=String.fromCharCode(128),o+=r.util.fillString(String.fromCharCode(0),64),s=!0}function l(e,t,n){for(var r,i,o,s,a,l,u,c,h=n.length();h>=64;){for(i=e.h0,o=e.h1,s=e.h2,a=e.h3,l=e.h4,c=0;c<16;++c)r=n.getInt32(),t[c]=r,u=a^o&(s^a),r=(i<<5|i>>>27)+u+l+1518500249+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;for(;c<20;++c)r=t[c-3]^t[c-8]^t[c-14]^t[c-16],r=r<<1|r>>>31,t[c]=r,u=a^o&(s^a),r=(i<<5|i>>>27)+u+l+1518500249+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;for(;c<32;++c)r=t[c-3]^t[c-8]^t[c-14]^t[c-16],r=r<<1|r>>>31,t[c]=r,u=o^s^a,r=(i<<5|i>>>27)+u+l+1859775393+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;for(;c<40;++c)r=t[c-6]^t[c-16]^t[c-28]^t[c-32],r=r<<2|r>>>30,t[c]=r,u=o^s^a,r=(i<<5|i>>>27)+u+l+1859775393+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;for(;c<60;++c)r=t[c-6]^t[c-16]^t[c-28]^t[c-32],r=r<<2|r>>>30,t[c]=r,u=o&s|a&(o^s),r=(i<<5|i>>>27)+u+l+2400959708+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;for(;c<80;++c)r=t[c-6]^t[c-16]^t[c-28]^t[c-32],r=r<<2|r>>>30,t[c]=r,u=o^s^a,r=(i<<5|i>>>27)+u+l+3395469782+r,l=a,a=s,s=(o<<30|o>>>2)>>>0,o=i,i=r;e.h0=e.h0+i|0,e.h1=e.h1+o|0,e.h2=e.h2+s|0,e.h3=e.h3+a|0,e.h4=e.h4+l|0,h-=64}}},function(e,t,n){var r=n(21);n(30),n(369),n(118),function(){if(r.prime)e.exports=r.prime;else{var t=e.exports=r.prime=r.prime||{},n=r.jsbn.BigInteger,i=[6,4,2,4,2,4,6,2],o=new n(null);o.fromInt(30);var s=function(e,t){return e|t};t.generateProbablePrime=function(e,t,n){"function"==typeof t&&(n=t,t={}),t=t||{};var i=t.algorithm||"PRIMEINC";"string"==typeof i&&(i={name:i}),i.options=i.options||{};var o=t.prng||r.random,s={nextBytes:function(e){for(var t=o.getBytesSync(e.length),n=0;n<e.length;++n)e[n]=t.charCodeAt(n)}};if("PRIMEINC"===i.name)return a(e,s,i.options,n);throw new Error("Invalid prime generation algorithm: "+i.name)}}function a(e,t,n,r){return"workers"in n?c(e,t,n,r):l(e,t,n,r)}function l(e,t,n,r){var i=h(e,t),o=0,s=f(i.bitLength());"millerRabinTests"in n&&(s=n.millerRabinTests);var a=10;"maxBlockTime"in n&&(a=n.maxBlockTime),u(i,e,t,0,s,a,r)}function u(e,t,n,o,s,a,l){var c=+new Date;do{if(e.bitLength()>t&&(e=h(t,n)),e.isProbablePrime(s))return l(null,e);e.dAddOffset(i[o++%8],0)}while(a<0||+new Date-c<a);r.util.setImmediate(function(){u(e,t,n,o,s,a,l)})}function c(e,t,i,o){if("undefined"==typeof Worker)return l(e,t,i,o);var s=h(e,t),a=i.workers,u=i.workLoad||100,c=30*u/8,f=i.workerScript||"forge/prime.worker.js";if(-1===a)return r.util.estimateCores(function(e,t){e&&(t=2),a=t-1,p()});function p(){a=Math.max(1,a);for(var r=[],i=0;i<a;++i)r[i]=new Worker(f);for(var l=a,i=0;i<a;++i)r[i].addEventListener("message",d);var p=!1;function d(i){if(!p){--l;var a=i.data;if(a.found){for(var f=0;f<r.length;++f)r[f].terminate();return p=!0,o(null,new n(a.prime,16))}s.bitLength()>e&&(s=h(e,t));var d=s.toString(16);i.target.postMessage({hex:d,workLoad:u}),s.dAddOffset(c,0)}}}p()}function h(e,t){var r=new n(e,t),i=e-1;return r.testBit(i)||r.bitwiseTo(n.ONE.shiftLeft(i),s,r),r.dAddOffset(31-r.mod(o).byteValue(),0),r}function f(e){return e<=100?27:e<=150?18:e<=200?15:e<=250?12:e<=300?9:e<=350?8:e<=400?7:e<=500?6:e<=600?5:e<=800?4:e<=1250?3:2}}()},function(e,t,n){var r=n(21);n(97),n(30);var i=e.exports=r.hmac=r.hmac||{};i.create=function(){var e=null,t=null,n=null,i=null,o={start:function(o,s){if(null!==o)if("string"==typeof o){if(o=o.toLowerCase(),!(o in r.md.algorithms))throw new Error('Unknown hash algorithm "'+o+'"');t=r.md.algorithms[o].create()}else t=o;if(null===s)s=e;else{if("string"==typeof s)s=r.util.createBuffer(s);else if(r.util.isArray(s)){var a=s;s=r.util.createBuffer();for(var l=0;l<a.length;++l)s.putByte(a[l])}var u=s.length();u>t.blockLength&&(t.start(),t.update(s.bytes()),s=t.digest()),n=r.util.createBuffer(),i=r.util.createBuffer(),u=s.length();for(var l=0;l<u;++l){var a=s.at(l);n.putByte(54^a),i.putByte(92^a)}if(u<t.blockLength)for(var a=t.blockLength-u,l=0;l<a;++l)n.putByte(54),i.putByte(92);e=s,n=n.bytes(),i=i.bytes()}t.start(),t.update(n)},update:function(e){t.update(e)},getMac:function(){var e=t.digest().bytes();return t.start(),t.update(i),t.update(e),t.digest()}};return o.digest=o.getMac,o}},function(e,t,n){var r=n(21);n(30);var i=[217,120,249,196,25,221,181,237,40,233,253,121,74,160,216,157,198,126,55,131,43,118,83,142,98,76,100,136,68,139,251,162,23,154,89,245,135,179,79,19,97,69,109,141,9,129,125,50,189,143,64,235,134,183,123,11,240,149,33,34,92,107,78,130,84,214,101,147,206,96,178,28,115,86,192,20,167,140,241,220,18,117,202,31,59,190,228,209,66,61,212,48,163,60,182,38,111,191,14,218,70,105,7,87,39,242,29,155,188,148,67,3,248,17,199,246,144,239,62,231,6,195,213,47,200,102,30,215,8,232,234,222,128,82,238,247,132,170,114,172,53,77,106,42,150,26,210,113,90,21,73,116,75,159,208,94,4,24,164,236,194,224,65,110,15,81,203,204,36,145,175,80,161,244,112,57,153,124,58,133,35,184,180,122,252,2,54,91,37,85,151,49,45,93,250,152,227,138,146,174,5,223,41,16,103,108,186,201,211,0,230,207,225,158,168,44,99,22,1,63,88,226,137,169,13,56,52,27,171,51,255,176,187,72,12,95,185,177,205,46,197,243,219,71,229,165,156,119,10,166,32,104,254,127,193,173],o=[1,2,3,5],s=function(e,t){return e<<t&65535|(65535&e)>>16-t},a=function(e,t){return(65535&e)>>t|e<<16-t&65535};e.exports=r.rc2=r.rc2||{},r.rc2.expandKey=function(e,t){"string"==typeof e&&(e=r.util.createBuffer(e)),t=t||128;var n=e,o=e.length(),s=t,a=Math.ceil(s/8),l=255>>(7&s),u;for(u=o;u<128;u++)n.putByte(i[n.at(u-1)+n.at(u-o)&255]);for(n.setAt(128-a,i[n.at(128-a)&l]),u=127-a;u>=0;u--)n.setAt(u,i[n.at(u+1)^n.at(u+a)]);return n};var l=function(e,t,n){var i=!1,l=null,u=null,c=null,h,f,p,d,m=[];for(e=r.rc2.expandKey(e,t),p=0;p<64;p++)m.push(e.getInt16Le());n?(h=function(e){for(p=0;p<4;p++)e[p]+=m[d]+(e[(p+3)%4]&e[(p+2)%4])+(~e[(p+3)%4]&e[(p+1)%4]),e[p]=s(e[p],o[p]),d++},f=function(e){for(p=0;p<4;p++)e[p]+=m[63&e[(p+3)%4]]}):(h=function(e){for(p=3;p>=0;p--)e[p]=a(e[p],o[p]),e[p]-=m[d]+(e[(p+3)%4]&e[(p+2)%4])+(~e[(p+3)%4]&e[(p+1)%4]),d--},f=function(e){for(p=3;p>=0;p--)e[p]-=m[63&e[(p+3)%4]]});var g=function(e){var t=[];for(p=0;p<4;p++){var r=l.getInt16Le();null!==c&&(n?r^=c.getInt16Le():c.putInt16Le(r)),t.push(65535&r)}d=n?0:63;for(var i=0;i<e.length;i++)for(var o=0;o<e[i][0];o++)e[i][1](t);for(p=0;p<4;p++)null!==c&&(n?c.putInt16Le(t[p]):t[p]^=c.getInt16Le()),u.putInt16Le(t[p])},y=null;return y={start:function(e,t){e&&"string"==typeof e&&(e=r.util.createBuffer(e)),i=!1,l=r.util.createBuffer(),u=t||new r.util.createBuffer,c=e,y.output=u},update:function(e){for(i||l.putBuffer(e);l.length()>=8;)g([[5,h],[1,f],[6,h],[1,f],[5,h]])},finish:function(e){var t=!0;if(n)if(e)t=e(8,l,!n);else{var r=8===l.length()?8:8-l.length();l.fillWithByte(r,r)}if(t&&(i=!0,y.update()),!n&&(t=0===l.length(),t))if(e)t=e(8,u,!n);else{var o=u.length(),s=u.at(o-1);s>o?t=!1:u.truncate(s)}return t}},y};r.rc2.startEncrypting=function(e,t,n){var i=r.rc2.createEncryptionCipher(e,128);return i.start(t,n),i},r.rc2.createEncryptionCipher=function(e,t){return l(e,t,!0)},r.rc2.startDecrypting=function(e,t,n){var i=r.rc2.createDecryptionCipher(e,128);return i.start(t,n),i},r.rc2.createDecryptionCipher=function(e,t){return l(e,t,!1)}},function(e,t,n){"use strict";const r=n(56),i=n(57),o=n(70),s=n(47),a=n(754),l=i(n(249));n(768),n(251);const u=n(21);class c{constructor(e){this._key=e}verify(e,t,n){g(n),a.hashAndVerify(this._key,t,e,n)}marshal(){return a.utils.jwkToPkix(this._key)}get bytes(){return l.PublicKey.encode({Type:l.KeyType.RSA,Data:this.marshal()})}encrypt(e){return this._key.encrypt(e,"RSAES-PKCS1-V1_5")}equals(e){return this.bytes.equals(e.bytes)}hash(e){g(e),r(this.bytes,"sha2-256",e)}}class h{constructor(e,t){this._key=e,this._publicKey=t}genSecret(){return a.getRandomValues(16)}sign(e,t){g(t),a.hashAndSign(this._key,e,t)}get public(){if(!this._publicKey)throw new Error("public key not provided");return new c(this._publicKey)}decrypt(e,t){a.decrypt(this._key,e,t)}marshal(){return a.utils.jwkToPkcs1(this._key)}get bytes(){return l.PrivateKey.encode({Type:l.KeyType.RSA,Data:this.marshal()})}equals(e){return this.bytes.equals(e.bytes)}hash(e){g(e),r(this.bytes,"sha2-256",e)}id(e){this.public.hash((t,n)=>{if(t)return e(t);e(null,o.encode(n))})}export(e,t,n){"function"==typeof t&&(n=t,t=e,e="pkcs-8"),g(n),s(()=>{let r=null,i=null;try{const n=new u.util.ByteBuffer(this.marshal()),o=u.asn1.fromDer(n),s=u.pki.privateKeyFromAsn1(o);if("pkcs-8"===e){const e={algorithm:"aes256",count:1e4,saltSize:16,prfAlgorithm:"sha512"};i=u.pki.encryptRsaPrivateKey(s,t,e)}else r=new Error(`Unknown export format '${e}'`)}catch(e){r=e}n(r,i)})}}function f(e,t){const n=a.utils.pkcs1ToJwk(e);a.unmarshalPrivateKey(n,(e,n)=>{if(e)return t(e);t(null,new h(n.privateKey,n.publicKey))})}function p(e){const t=a.utils.pkixToJwk(e);return new c(t)}function d(e,t){a.unmarshalPrivateKey(e,(e,n)=>{if(e)return t(e);t(null,new h(n.privateKey,n.publicKey))})}function m(e,t){a.generateKey(e,(e,n)=>{if(e)return t(e);t(null,new h(n.privateKey,n.publicKey))})}function g(e){if("function"!=typeof e)throw new Error("callback is required")}e.exports={RsaPublicKey:c,RsaPrivateKey:h,unmarshalRsaPublicKey:p,unmarshalRsaPrivateKey:f,generateKeyPair:m,fromJwk:d}},function(e,t,n){"use strict";(function(e){const r=n(254),i=n(255),o=n(256);function s(e){return Promise.all([i.subtle.exportKey("jwk",e.privateKey),i.subtle.exportKey("jwk",e.publicKey)])}function a(e){return i.subtle.importKey("jwk",{kty:e.kty,n:e.n,e:e.e},{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}},!0,["verify"])}t.utils=n(756),t.generateKey=function(e,t){r(i.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:e,publicExponent:new Uint8Array([1,0,1]),hash:{name:"SHA-256"}},!0,["sign","verify"]).then(s).then(e=>({privateKey:e[0],publicKey:e[1]})),t)},t.unmarshalPrivateKey=function(e,t){const n=i.subtle.importKey("jwk",e,{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}},!0,["sign"]);r(Promise.all([n,a(e)]).then(e=>s({privateKey:e[0],publicKey:e[1]})).then(e=>({privateKey:e[0],publicKey:e[1]})),t)},t.getRandomValues=o,t.hashAndSign=function(t,n,o){r(i.subtle.importKey("jwk",t,{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}},!1,["sign"]).then(e=>i.subtle.sign({name:"RSASSA-PKCS1-v1_5"},e,Uint8Array.from(n))).then(t=>e.from(t)),o)},t.hashAndVerify=function(e,t,n,o){r(i.subtle.importKey("jwk",e,{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}},!1,["verify"]).then(e=>i.subtle.verify({name:"RSASSA-PKCS1-v1_5"},e,t,n)),o)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t,n){const r=t.crypto||t.msCrypto,i=65536;function o(){throw new Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}function s(e){const t=new Uint8Array(e);let o=0;if(e>0)if(e>i)for(;o<t;)o+i>t?r.getRandomValues(t.subarray(o,t-o)):(r.getRandomValues(t.subarray(o,o+i)),o+=i);else r.getRandomValues(t);return n.from(t)}r&&r.getRandomValues?e.exports=s:e.exports=o}).call(this,n(8),n(0).Buffer)},function(e,t,n){"use strict";const r=n(119),i=n(378),o=i.toBase64,s=i.toBn,a=r.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())}),l=r.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid({"1.2.840.113549.1.1.1":"rsa"}),this.key("none").optional().null_(),this.key("curve").optional().objid(),this.key("params").optional().seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()))}),u=r.define("RSAPublicKey",function(){this.seq().obj(this.key("algorithm").use(l),this.key("subjectPublicKey").bitstr())}),c=r.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});t.pkcs1ToJwk=function(e){const t=a.decode(e,"der");return{kty:"RSA",n:o(t.modulus),e:o(t.publicExponent),d:o(t.privateExponent),p:o(t.prime1),q:o(t.prime2),dp:o(t.exponent1),dq:o(t.exponent2),qi:o(t.coefficient),alg:"RS256",kid:"2011-04-29"}},t.jwkToPkcs1=function(e){return a.encode({version:0,modulus:s(e.n),publicExponent:s(e.e),privateExponent:s(e.d),prime1:s(e.p),prime2:s(e.q),exponent1:s(e.dp),exponent2:s(e.dq),coefficient:s(e.qi)},"der")},t.pkixToJwk=function(e){const t=u.decode(e,"der"),n=c.decode(t.subjectPublicKey.data,"der");return{kty:"RSA",n:o(n.modulus),e:o(n.publicExponent),alg:"RS256",kid:"2011-04-29"}},t.jwkToPkix=function(e){return u.encode({algorithm:{algorithm:"rsa",none:null},subjectPublicKey:{data:c.encode({modulus:s(e.n),publicExponent:s(e.e)},"der")}},"der")}},function(e,t,n){(function(e){!function(e,t){"use strict";function r(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}function o(e,t,n){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(n=t,t=10),this._init(e||0,t||10,n||"be"))}var s;"object"==typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{s=n(758).Buffer}catch(e){}function a(e,t,n){for(var r=0,i=Math.min(e.length,n),o=t;o<i;o++){var s=e.charCodeAt(o)-48;r<<=4,r|=s>=49&&s<=54?s-49+10:s>=17&&s<=22?s-17+10:15&s}return r}function l(e,t,n,r){for(var i=0,o=Math.min(e.length,n),s=t;s<o;s++){var a=e.charCodeAt(s)-48;i*=r,i+=a>=49?a-49+10:a>=17?a-17+10:a}return i}o.isBN=function e(t){return t instanceof o||null!==t&&"object"==typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function e(t,n){return t.cmp(n)>0?t:n},o.min=function e(t,n){return t.cmp(n)<0?t:n},o.prototype._init=function e(t,n,i){if("number"==typeof t)return this._initNumber(t,n,i);if("object"==typeof t)return this._initArray(t,n,i);"hex"===n&&(n=16),r(n===(0|n)&&n>=2&&n<=36),t=t.toString().replace(/\s+/g,"");var o=0;"-"===t[0]&&o++,16===n?this._parseHex(t,o):this._parseBase(t,n,o),"-"===t[0]&&(this.negative=1),this.strip(),"le"===i&&this._initArray(this.toArray(),n,i)},o.prototype._initNumber=function e(t,n,i){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(r(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===i&&this._initArray(this.toArray(),n,i)},o.prototype._initArray=function e(t,n,i){if(r("number"==typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var s,a,l=0;if("be"===i)for(o=t.length-1,s=0;o>=0;o-=3)a=t[o]|t[o-1]<<8|t[o-2]<<16,this.words[s]|=a<<l&67108863,this.words[s+1]=a>>>26-l&67108863,l+=24,l>=26&&(l-=26,s++);else if("le"===i)for(o=0,s=0;o<t.length;o+=3)a=t[o]|t[o+1]<<8|t[o+2]<<16,this.words[s]|=a<<l&67108863,this.words[s+1]=a>>>26-l&67108863,l+=24,l>=26&&(l-=26,s++);return this.strip()},o.prototype._parseHex=function e(t,n){this.length=Math.ceil((t.length-n)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var i,o,s=0;for(r=t.length-6,i=0;r>=n;r-=6)o=a(t,r,r+6),this.words[i]|=o<<s&67108863,this.words[i+1]|=o>>>26-s&4194303,s+=24,s>=26&&(s-=26,i++);r+6!==n&&(o=a(t,n,r+6),this.words[i]|=o<<s&67108863,this.words[i+1]|=o>>>26-s&4194303),this.strip()},o.prototype._parseBase=function e(t,n,r){this.words=[0],this.length=1;for(var i=0,o=1;o<=67108863;o*=n)i++;i--,o=o/n|0;for(var s=t.length-r,a=s%i,u=Math.min(s,s-a)+r,c=0,h=r;h<u;h+=i)c=l(t,h,h+i,n),this.imuln(o),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c);if(0!==a){var f=1;for(c=l(t,h,t.length,n),h=0;h<a;h++)f*=n;this.imuln(f),this.words[0]+c<67108864?this.words[0]+=c:this._iaddn(c)}},o.prototype.copy=function e(t){t.words=new Array(this.length);for(var n=0;n<this.length;n++)t.words[n]=this.words[n];t.length=this.length,t.negative=this.negative,t.red=this.red},o.prototype.clone=function e(){var t=new o(null);return this.copy(t),t},o.prototype._expand=function e(t){for(;this.length<t;)this.words[this.length++]=0;return this},o.prototype.strip=function e(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function e(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function e(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var u=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],c=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],h=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function f(e){for(var t=new Array(e.bitLength()),n=0;n<t.length;n++){var r=n/26|0,i=n%26;t[n]=(e.words[r]&1<<i)>>>i}return t}function p(e,t,n){n.negative=t.negative^e.negative;var r=e.length+t.length|0;n.length=r,r=r-1|0;var i=0|e.words[0],o=0|t.words[0],s=i*o,a=67108863&s,l=s/67108864|0;n.words[0]=a;for(var u=1;u<r;u++){for(var c=l>>>26,h=67108863&l,f=Math.min(u,t.length-1),p=Math.max(0,u-e.length+1);p<=f;p++){var d=u-p|0;i=0|e.words[d],o=0|t.words[p],s=i*o+h,c+=s/67108864|0,h=67108863&s}n.words[u]=0|h,l=0|c}return 0!==l?n.words[u]=0|l:n.length--,n.strip()}o.prototype.toString=function e(t,n){var i;if(t=t||10,n=0|n||1,16===t||"hex"===t){i="";for(var o=0,s=0,a=0;a<this.length;a++){var l=this.words[a],f=(16777215&(l<<o|s)).toString(16);s=l>>>24-o&16777215,i=0!==s||a!==this.length-1?u[6-f.length]+f+i:f+i,o+=2,o>=26&&(o-=26,a--)}for(0!==s&&(i=s.toString(16)+i);i.length%n!=0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}if(t===(0|t)&&t>=2&&t<=36){var p=c[t],d=h[t];i="";var m=this.clone();for(m.negative=0;!m.isZero();){var g=m.modn(d).toString(t);m=m.idivn(d),i=m.isZero()?g+i:u[p-g.length]+g+i}for(this.isZero()&&(i="0"+i);i.length%n!=0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}r(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function e(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function e(){return this.toString(16)},o.prototype.toBuffer=function e(t,n){return r(void 0!==s),this.toArrayLike(s,t,n)},o.prototype.toArray=function e(t,n){return this.toArrayLike(Array,t,n)},o.prototype.toArrayLike=function e(t,n,i){var o=this.byteLength(),s=i||Math.max(1,o);r(o<=s,"byte array longer than desired length"),r(s>0,"Requested array length <= 0"),this.strip();var a="le"===n,l=new t(s),u,c,h=this.clone();if(a){for(c=0;!h.isZero();c++)u=h.andln(255),h.iushrn(8),l[c]=u;for(;c<s;c++)l[c]=0}else{for(c=0;c<s-o;c++)l[c]=0;for(c=0;!h.isZero();c++)u=h.andln(255),h.iushrn(8),l[s-c-1]=u}return l},Math.clz32?o.prototype._countBits=function e(t){return 32-Math.clz32(t)}:o.prototype._countBits=function e(t){var n=t,r=0;return n>=4096&&(r+=13,n>>>=13),n>=64&&(r+=7,n>>>=7),n>=8&&(r+=4,n>>>=4),n>=2&&(r+=2,n>>>=2),r+n},o.prototype._zeroBits=function e(t){if(0===t)return 26;var n=t,r=0;return 0==(8191&n)&&(r+=13,n>>>=13),0==(127&n)&&(r+=7,n>>>=7),0==(15&n)&&(r+=4,n>>>=4),0==(3&n)&&(r+=2,n>>>=2),0==(1&n)&&r++,r},o.prototype.bitLength=function e(){var t=this.words[this.length-1],n=this._countBits(t);return 26*(this.length-1)+n},o.prototype.zeroBits=function e(){if(this.isZero())return 0;for(var t=0,n=0;n<this.length;n++){var r=this._zeroBits(this.words[n]);if(t+=r,26!==r)break}return t},o.prototype.byteLength=function e(){return Math.ceil(this.bitLength()/8)},o.prototype.toTwos=function e(t){return 0!==this.negative?this.abs().inotn(t).iaddn(1):this.clone()},o.prototype.fromTwos=function e(t){return this.testn(t-1)?this.notn(t).iaddn(1).ineg():this.clone()},o.prototype.isNeg=function e(){return 0!==this.negative},o.prototype.neg=function e(){return this.clone().ineg()},o.prototype.ineg=function e(){return this.isZero()||(this.negative^=1),this},o.prototype.iuor=function e(t){for(;this.length<t.length;)this.words[this.length++]=0;for(var n=0;n<t.length;n++)this.words[n]=this.words[n]|t.words[n];return this.strip()},o.prototype.ior=function e(t){return r(0==(this.negative|t.negative)),this.iuor(t)},o.prototype.or=function e(t){return this.length>t.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function e(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function e(t){var n;n=this.length>t.length?t:this;for(var r=0;r<n.length;r++)this.words[r]=this.words[r]&t.words[r];return this.length=n.length,this.strip()},o.prototype.iand=function e(t){return r(0==(this.negative|t.negative)),this.iuand(t)},o.prototype.and=function e(t){return this.length>t.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function e(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function e(t){var n,r;this.length>t.length?(n=this,r=t):(n=t,r=this);for(var i=0;i<r.length;i++)this.words[i]=n.words[i]^r.words[i];if(this!==n)for(;i<n.length;i++)this.words[i]=n.words[i];return this.length=n.length,this.strip()},o.prototype.ixor=function e(t){return r(0==(this.negative|t.negative)),this.iuxor(t)},o.prototype.xor=function e(t){return this.length>t.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function e(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function e(t){r("number"==typeof t&&t>=0);var n=0|Math.ceil(t/26),i=t%26;this._expand(n),i>0&&n--;for(var o=0;o<n;o++)this.words[o]=67108863&~this.words[o];return i>0&&(this.words[o]=~this.words[o]&67108863>>26-i),this.strip()},o.prototype.notn=function e(t){return this.clone().inotn(t)},o.prototype.setn=function e(t,n){r("number"==typeof t&&t>=0);var i=t/26|0,o=t%26;return this._expand(i+1),this.words[i]=n?this.words[i]|1<<o:this.words[i]&~(1<<o),this.strip()},o.prototype.iadd=function e(t){var n,r,i;if(0!==this.negative&&0===t.negative)return this.negative=0,n=this.isub(t),this.negative^=1,this._normSign();if(0===this.negative&&0!==t.negative)return t.negative=0,n=this.isub(t),t.negative=1,n._normSign();this.length>t.length?(r=this,i=t):(r=t,i=this);for(var o=0,s=0;s<i.length;s++)n=(0|r.words[s])+(0|i.words[s])+o,this.words[s]=67108863&n,o=n>>>26;for(;0!==o&&s<r.length;s++)n=(0|r.words[s])+o,this.words[s]=67108863&n,o=n>>>26;if(this.length=r.length,0!==o)this.words[this.length]=o,this.length++;else if(r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this},o.prototype.add=function e(t){var n;return 0!==t.negative&&0===this.negative?(t.negative=0,n=this.sub(t),t.negative^=1,n):0===t.negative&&0!==this.negative?(this.negative=0,n=t.sub(this),this.negative=1,n):this.length>t.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function e(t){if(0!==t.negative){t.negative=0;var n=this.iadd(t);return t.negative=1,n._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r=this.cmp(t),i,o;if(0===r)return this.negative=0,this.length=1,this.words[0]=0,this;r>0?(i=this,o=t):(i=t,o=this);for(var s=0,a=0;a<o.length;a++)n=(0|i.words[a])-(0|o.words[a])+s,s=n>>26,this.words[a]=67108863&n;for(;0!==s&&a<i.length;a++)n=(0|i.words[a])+s,s=n>>26,this.words[a]=67108863&n;if(0===s&&a<i.length&&i!==this)for(;a<i.length;a++)this.words[a]=i.words[a];return this.length=Math.max(this.length,a),i!==this&&(this.negative=1),this.strip()},o.prototype.sub=function e(t){return this.clone().isub(t)};var d=function e(t,n,r){var i=t.words,o=n.words,s=r.words,a=0,l,u,c,h=0|i[0],f=8191&h,p=h>>>13,d=0|i[1],m=8191&d,g=d>>>13,y=0|i[2],v=8191&y,b=y>>>13,_=0|i[3],w=8191&_,k=_>>>13,E=0|i[4],S=8191&E,x=E>>>13,C=0|i[5],A=8191&C,T=C>>>13,I=0|i[6],j=8191&I,R=I>>>13,B=0|i[7],O=8191&B,P=B>>>13,N=0|i[8],D=8191&N,M=N>>>13,F=0|i[9],L=8191&F,U=F>>>13,q=0|o[0],z=8191&q,K=q>>>13,H=0|o[1],V=8191&H,$=H>>>13,W=0|o[2],G=8191&W,Y=W>>>13,Z=0|o[3],J=8191&Z,Q=Z>>>13,X=0|o[4],ee=8191&X,te=X>>>13,ne=0|o[5],re=8191&ne,ie=ne>>>13,oe=0|o[6],se=8191&oe,ae=oe>>>13,le=0|o[7],ue=8191&le,ce=le>>>13,he=0|o[8],fe=8191&he,pe=he>>>13,de=0|o[9],me=8191&de,ge=de>>>13;r.negative=t.negative^n.negative,r.length=19,l=Math.imul(f,z),u=Math.imul(f,K),u=u+Math.imul(p,z)|0,c=Math.imul(p,K);var ye=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(ye>>>26)|0,ye&=67108863,l=Math.imul(m,z),u=Math.imul(m,K),u=u+Math.imul(g,z)|0,c=Math.imul(g,K),l=l+Math.imul(f,V)|0,u=u+Math.imul(f,$)|0,u=u+Math.imul(p,V)|0,c=c+Math.imul(p,$)|0;var ve=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(ve>>>26)|0,ve&=67108863,l=Math.imul(v,z),u=Math.imul(v,K),u=u+Math.imul(b,z)|0,c=Math.imul(b,K),l=l+Math.imul(m,V)|0,u=u+Math.imul(m,$)|0,u=u+Math.imul(g,V)|0,c=c+Math.imul(g,$)|0,l=l+Math.imul(f,G)|0,u=u+Math.imul(f,Y)|0,u=u+Math.imul(p,G)|0,c=c+Math.imul(p,Y)|0;var be=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(be>>>26)|0,be&=67108863,l=Math.imul(w,z),u=Math.imul(w,K),u=u+Math.imul(k,z)|0,c=Math.imul(k,K),l=l+Math.imul(v,V)|0,u=u+Math.imul(v,$)|0,u=u+Math.imul(b,V)|0,c=c+Math.imul(b,$)|0,l=l+Math.imul(m,G)|0,u=u+Math.imul(m,Y)|0,u=u+Math.imul(g,G)|0,c=c+Math.imul(g,Y)|0,l=l+Math.imul(f,J)|0,u=u+Math.imul(f,Q)|0,u=u+Math.imul(p,J)|0,c=c+Math.imul(p,Q)|0;var _e=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(_e>>>26)|0,_e&=67108863,l=Math.imul(S,z),u=Math.imul(S,K),u=u+Math.imul(x,z)|0,c=Math.imul(x,K),l=l+Math.imul(w,V)|0,u=u+Math.imul(w,$)|0,u=u+Math.imul(k,V)|0,c=c+Math.imul(k,$)|0,l=l+Math.imul(v,G)|0,u=u+Math.imul(v,Y)|0,u=u+Math.imul(b,G)|0,c=c+Math.imul(b,Y)|0,l=l+Math.imul(m,J)|0,u=u+Math.imul(m,Q)|0,u=u+Math.imul(g,J)|0,c=c+Math.imul(g,Q)|0,l=l+Math.imul(f,ee)|0,u=u+Math.imul(f,te)|0,u=u+Math.imul(p,ee)|0,c=c+Math.imul(p,te)|0;var we=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(we>>>26)|0,we&=67108863,l=Math.imul(A,z),u=Math.imul(A,K),u=u+Math.imul(T,z)|0,c=Math.imul(T,K),l=l+Math.imul(S,V)|0,u=u+Math.imul(S,$)|0,u=u+Math.imul(x,V)|0,c=c+Math.imul(x,$)|0,l=l+Math.imul(w,G)|0,u=u+Math.imul(w,Y)|0,u=u+Math.imul(k,G)|0,c=c+Math.imul(k,Y)|0,l=l+Math.imul(v,J)|0,u=u+Math.imul(v,Q)|0,u=u+Math.imul(b,J)|0,c=c+Math.imul(b,Q)|0,l=l+Math.imul(m,ee)|0,u=u+Math.imul(m,te)|0,u=u+Math.imul(g,ee)|0,c=c+Math.imul(g,te)|0,l=l+Math.imul(f,re)|0,u=u+Math.imul(f,ie)|0,u=u+Math.imul(p,re)|0,c=c+Math.imul(p,ie)|0;var ke=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(ke>>>26)|0,ke&=67108863,l=Math.imul(j,z),u=Math.imul(j,K),u=u+Math.imul(R,z)|0,c=Math.imul(R,K),l=l+Math.imul(A,V)|0,u=u+Math.imul(A,$)|0,u=u+Math.imul(T,V)|0,c=c+Math.imul(T,$)|0,l=l+Math.imul(S,G)|0,u=u+Math.imul(S,Y)|0,u=u+Math.imul(x,G)|0,c=c+Math.imul(x,Y)|0,l=l+Math.imul(w,J)|0,u=u+Math.imul(w,Q)|0,u=u+Math.imul(k,J)|0,c=c+Math.imul(k,Q)|0,l=l+Math.imul(v,ee)|0,u=u+Math.imul(v,te)|0,u=u+Math.imul(b,ee)|0,c=c+Math.imul(b,te)|0,l=l+Math.imul(m,re)|0,u=u+Math.imul(m,ie)|0,u=u+Math.imul(g,re)|0,c=c+Math.imul(g,ie)|0,l=l+Math.imul(f,se)|0,u=u+Math.imul(f,ae)|0,u=u+Math.imul(p,se)|0,c=c+Math.imul(p,ae)|0;var Ee=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,l=Math.imul(O,z),u=Math.imul(O,K),u=u+Math.imul(P,z)|0,c=Math.imul(P,K),l=l+Math.imul(j,V)|0,u=u+Math.imul(j,$)|0,u=u+Math.imul(R,V)|0,c=c+Math.imul(R,$)|0,l=l+Math.imul(A,G)|0,u=u+Math.imul(A,Y)|0,u=u+Math.imul(T,G)|0,c=c+Math.imul(T,Y)|0,l=l+Math.imul(S,J)|0,u=u+Math.imul(S,Q)|0,u=u+Math.imul(x,J)|0,c=c+Math.imul(x,Q)|0,l=l+Math.imul(w,ee)|0,u=u+Math.imul(w,te)|0,u=u+Math.imul(k,ee)|0,c=c+Math.imul(k,te)|0,l=l+Math.imul(v,re)|0,u=u+Math.imul(v,ie)|0,u=u+Math.imul(b,re)|0,c=c+Math.imul(b,ie)|0,l=l+Math.imul(m,se)|0,u=u+Math.imul(m,ae)|0,u=u+Math.imul(g,se)|0,c=c+Math.imul(g,ae)|0,l=l+Math.imul(f,ue)|0,u=u+Math.imul(f,ce)|0,u=u+Math.imul(p,ue)|0,c=c+Math.imul(p,ce)|0;var Se=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Se>>>26)|0,Se&=67108863,l=Math.imul(D,z),u=Math.imul(D,K),u=u+Math.imul(M,z)|0,c=Math.imul(M,K),l=l+Math.imul(O,V)|0,u=u+Math.imul(O,$)|0,u=u+Math.imul(P,V)|0,c=c+Math.imul(P,$)|0,l=l+Math.imul(j,G)|0,u=u+Math.imul(j,Y)|0,u=u+Math.imul(R,G)|0,c=c+Math.imul(R,Y)|0,l=l+Math.imul(A,J)|0,u=u+Math.imul(A,Q)|0,u=u+Math.imul(T,J)|0,c=c+Math.imul(T,Q)|0,l=l+Math.imul(S,ee)|0,u=u+Math.imul(S,te)|0,u=u+Math.imul(x,ee)|0,c=c+Math.imul(x,te)|0,l=l+Math.imul(w,re)|0,u=u+Math.imul(w,ie)|0,u=u+Math.imul(k,re)|0,c=c+Math.imul(k,ie)|0,l=l+Math.imul(v,se)|0,u=u+Math.imul(v,ae)|0,u=u+Math.imul(b,se)|0,c=c+Math.imul(b,ae)|0,l=l+Math.imul(m,ue)|0,u=u+Math.imul(m,ce)|0,u=u+Math.imul(g,ue)|0,c=c+Math.imul(g,ce)|0,l=l+Math.imul(f,fe)|0,u=u+Math.imul(f,pe)|0,u=u+Math.imul(p,fe)|0,c=c+Math.imul(p,pe)|0;var xe=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(xe>>>26)|0,xe&=67108863,l=Math.imul(L,z),u=Math.imul(L,K),u=u+Math.imul(U,z)|0,c=Math.imul(U,K),l=l+Math.imul(D,V)|0,u=u+Math.imul(D,$)|0,u=u+Math.imul(M,V)|0,c=c+Math.imul(M,$)|0,l=l+Math.imul(O,G)|0,u=u+Math.imul(O,Y)|0,u=u+Math.imul(P,G)|0,c=c+Math.imul(P,Y)|0,l=l+Math.imul(j,J)|0,u=u+Math.imul(j,Q)|0,u=u+Math.imul(R,J)|0,c=c+Math.imul(R,Q)|0,l=l+Math.imul(A,ee)|0,u=u+Math.imul(A,te)|0,u=u+Math.imul(T,ee)|0,c=c+Math.imul(T,te)|0,l=l+Math.imul(S,re)|0,u=u+Math.imul(S,ie)|0,u=u+Math.imul(x,re)|0,c=c+Math.imul(x,ie)|0,l=l+Math.imul(w,se)|0,u=u+Math.imul(w,ae)|0,u=u+Math.imul(k,se)|0,c=c+Math.imul(k,ae)|0,l=l+Math.imul(v,ue)|0,u=u+Math.imul(v,ce)|0,u=u+Math.imul(b,ue)|0,c=c+Math.imul(b,ce)|0,l=l+Math.imul(m,fe)|0,u=u+Math.imul(m,pe)|0,u=u+Math.imul(g,fe)|0,c=c+Math.imul(g,pe)|0,l=l+Math.imul(f,me)|0,u=u+Math.imul(f,ge)|0,u=u+Math.imul(p,me)|0,c=c+Math.imul(p,ge)|0;var Ce=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,l=Math.imul(L,V),u=Math.imul(L,$),u=u+Math.imul(U,V)|0,c=Math.imul(U,$),l=l+Math.imul(D,G)|0,u=u+Math.imul(D,Y)|0,u=u+Math.imul(M,G)|0,c=c+Math.imul(M,Y)|0,l=l+Math.imul(O,J)|0,u=u+Math.imul(O,Q)|0,u=u+Math.imul(P,J)|0,c=c+Math.imul(P,Q)|0,l=l+Math.imul(j,ee)|0,u=u+Math.imul(j,te)|0,u=u+Math.imul(R,ee)|0,c=c+Math.imul(R,te)|0,l=l+Math.imul(A,re)|0,u=u+Math.imul(A,ie)|0,u=u+Math.imul(T,re)|0,c=c+Math.imul(T,ie)|0,l=l+Math.imul(S,se)|0,u=u+Math.imul(S,ae)|0,u=u+Math.imul(x,se)|0,c=c+Math.imul(x,ae)|0,l=l+Math.imul(w,ue)|0,u=u+Math.imul(w,ce)|0,u=u+Math.imul(k,ue)|0,c=c+Math.imul(k,ce)|0,l=l+Math.imul(v,fe)|0,u=u+Math.imul(v,pe)|0,u=u+Math.imul(b,fe)|0,c=c+Math.imul(b,pe)|0,l=l+Math.imul(m,me)|0,u=u+Math.imul(m,ge)|0,u=u+Math.imul(g,me)|0,c=c+Math.imul(g,ge)|0;var Ae=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,l=Math.imul(L,G),u=Math.imul(L,Y),u=u+Math.imul(U,G)|0,c=Math.imul(U,Y),l=l+Math.imul(D,J)|0,u=u+Math.imul(D,Q)|0,u=u+Math.imul(M,J)|0,c=c+Math.imul(M,Q)|0,l=l+Math.imul(O,ee)|0,u=u+Math.imul(O,te)|0,u=u+Math.imul(P,ee)|0,c=c+Math.imul(P,te)|0,l=l+Math.imul(j,re)|0,u=u+Math.imul(j,ie)|0,u=u+Math.imul(R,re)|0,c=c+Math.imul(R,ie)|0,l=l+Math.imul(A,se)|0,u=u+Math.imul(A,ae)|0,u=u+Math.imul(T,se)|0,c=c+Math.imul(T,ae)|0,l=l+Math.imul(S,ue)|0,u=u+Math.imul(S,ce)|0,u=u+Math.imul(x,ue)|0,c=c+Math.imul(x,ce)|0,l=l+Math.imul(w,fe)|0,u=u+Math.imul(w,pe)|0,u=u+Math.imul(k,fe)|0,c=c+Math.imul(k,pe)|0,l=l+Math.imul(v,me)|0,u=u+Math.imul(v,ge)|0,u=u+Math.imul(b,me)|0,c=c+Math.imul(b,ge)|0;var Te=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Te>>>26)|0,Te&=67108863,l=Math.imul(L,J),u=Math.imul(L,Q),u=u+Math.imul(U,J)|0,c=Math.imul(U,Q),l=l+Math.imul(D,ee)|0,u=u+Math.imul(D,te)|0,u=u+Math.imul(M,ee)|0,c=c+Math.imul(M,te)|0,l=l+Math.imul(O,re)|0,u=u+Math.imul(O,ie)|0,u=u+Math.imul(P,re)|0,c=c+Math.imul(P,ie)|0,l=l+Math.imul(j,se)|0,u=u+Math.imul(j,ae)|0,u=u+Math.imul(R,se)|0,c=c+Math.imul(R,ae)|0,l=l+Math.imul(A,ue)|0,u=u+Math.imul(A,ce)|0,u=u+Math.imul(T,ue)|0,c=c+Math.imul(T,ce)|0,l=l+Math.imul(S,fe)|0,u=u+Math.imul(S,pe)|0,u=u+Math.imul(x,fe)|0,c=c+Math.imul(x,pe)|0,l=l+Math.imul(w,me)|0,u=u+Math.imul(w,ge)|0,u=u+Math.imul(k,me)|0,c=c+Math.imul(k,ge)|0;var Ie=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,l=Math.imul(L,ee),u=Math.imul(L,te),u=u+Math.imul(U,ee)|0,c=Math.imul(U,te),l=l+Math.imul(D,re)|0,u=u+Math.imul(D,ie)|0,u=u+Math.imul(M,re)|0,c=c+Math.imul(M,ie)|0,l=l+Math.imul(O,se)|0,u=u+Math.imul(O,ae)|0,u=u+Math.imul(P,se)|0,c=c+Math.imul(P,ae)|0,l=l+Math.imul(j,ue)|0,u=u+Math.imul(j,ce)|0,u=u+Math.imul(R,ue)|0,c=c+Math.imul(R,ce)|0,l=l+Math.imul(A,fe)|0,u=u+Math.imul(A,pe)|0,u=u+Math.imul(T,fe)|0,c=c+Math.imul(T,pe)|0,l=l+Math.imul(S,me)|0,u=u+Math.imul(S,ge)|0,u=u+Math.imul(x,me)|0,c=c+Math.imul(x,ge)|0;var je=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(je>>>26)|0,je&=67108863,l=Math.imul(L,re),u=Math.imul(L,ie),u=u+Math.imul(U,re)|0,c=Math.imul(U,ie),l=l+Math.imul(D,se)|0,u=u+Math.imul(D,ae)|0,u=u+Math.imul(M,se)|0,c=c+Math.imul(M,ae)|0,l=l+Math.imul(O,ue)|0,u=u+Math.imul(O,ce)|0,u=u+Math.imul(P,ue)|0,c=c+Math.imul(P,ce)|0,l=l+Math.imul(j,fe)|0,u=u+Math.imul(j,pe)|0,u=u+Math.imul(R,fe)|0,c=c+Math.imul(R,pe)|0,l=l+Math.imul(A,me)|0,u=u+Math.imul(A,ge)|0,u=u+Math.imul(T,me)|0,c=c+Math.imul(T,ge)|0;var Re=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Re>>>26)|0,Re&=67108863,l=Math.imul(L,se),u=Math.imul(L,ae),u=u+Math.imul(U,se)|0,c=Math.imul(U,ae),l=l+Math.imul(D,ue)|0,u=u+Math.imul(D,ce)|0,u=u+Math.imul(M,ue)|0,c=c+Math.imul(M,ce)|0,l=l+Math.imul(O,fe)|0,u=u+Math.imul(O,pe)|0,u=u+Math.imul(P,fe)|0,c=c+Math.imul(P,pe)|0,l=l+Math.imul(j,me)|0,u=u+Math.imul(j,ge)|0,u=u+Math.imul(R,me)|0,c=c+Math.imul(R,ge)|0;var Be=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Be>>>26)|0,Be&=67108863,l=Math.imul(L,ue),u=Math.imul(L,ce),u=u+Math.imul(U,ue)|0,c=Math.imul(U,ce),l=l+Math.imul(D,fe)|0,u=u+Math.imul(D,pe)|0,u=u+Math.imul(M,fe)|0,c=c+Math.imul(M,pe)|0,l=l+Math.imul(O,me)|0,u=u+Math.imul(O,ge)|0,u=u+Math.imul(P,me)|0,c=c+Math.imul(P,ge)|0;var Oe=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,l=Math.imul(L,fe),u=Math.imul(L,pe),u=u+Math.imul(U,fe)|0,c=Math.imul(U,pe),l=l+Math.imul(D,me)|0,u=u+Math.imul(D,ge)|0,u=u+Math.imul(M,me)|0,c=c+Math.imul(M,ge)|0;var Pe=(a+l|0)+((8191&u)<<13)|0;a=(c+(u>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,l=Math.imul(L,me),u=Math.imul(L,ge),u=u+Math.imul(U,me)|0,c=Math.imul(U,ge);var Ne=(a+l|0)+((8191&u)<<13)|0;return a=(c+(u>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,s[0]=ye,s[1]=ve,s[2]=be,s[3]=_e,s[4]=we,s[5]=ke,s[6]=Ee,s[7]=Se,s[8]=xe,s[9]=Ce,s[10]=Ae,s[11]=Te,s[12]=Ie,s[13]=je,s[14]=Re,s[15]=Be,s[16]=Oe,s[17]=Pe,s[18]=Ne,0!==a&&(s[19]=a,r.length++),r};function m(e,t,n){n.negative=t.negative^e.negative,n.length=e.length+t.length;for(var r=0,i=0,o=0;o<n.length-1;o++){var s=i;i=0;for(var a=67108863&r,l=Math.min(o,t.length-1),u=Math.max(0,o-e.length+1);u<=l;u++){var c=o-u,h=0|e.words[c],f=0|t.words[u],p=h*f,d=67108863&p;s=s+(p/67108864|0)|0,d=d+a|0,a=67108863&d,s=s+(d>>>26)|0,i+=s>>>26,s&=67108863}n.words[o]=a,r=s,s=i}return 0!==r?n.words[o]=r:n.length--,n.strip()}function g(e,t,n){var r=new y;return r.mulp(e,t,n)}function y(e,t){this.x=e,this.y=t}Math.imul||(d=p),o.prototype.mulTo=function e(t,n){var r,i=this.length+t.length;return r=10===this.length&&10===t.length?d(this,t,n):i<63?p(this,t,n):i<1024?m(this,t,n):g(this,t,n),r},y.prototype.makeRBT=function e(t){for(var n=new Array(t),r=o.prototype._countBits(t)-1,i=0;i<t;i++)n[i]=this.revBin(i,r,t);return n},y.prototype.revBin=function e(t,n,r){if(0===t||t===r-1)return t;for(var i=0,o=0;o<n;o++)i|=(1&t)<<n-o-1,t>>=1;return i},y.prototype.permute=function e(t,n,r,i,o,s){for(var a=0;a<s;a++)i[a]=n[t[a]],o[a]=r[t[a]]},y.prototype.transform=function e(t,n,r,i,o,s){this.permute(s,t,n,r,i,o);for(var a=1;a<o;a<<=1)for(var l=a<<1,u=Math.cos(2*Math.PI/l),c=Math.sin(2*Math.PI/l),h=0;h<o;h+=l)for(var f=u,p=c,d=0;d<a;d++){var m=r[h+d],g=i[h+d],y=r[h+d+a],v=i[h+d+a],b=f*y-p*v;v=f*v+p*y,y=b,r[h+d]=m+y,i[h+d]=g+v,r[h+d+a]=m-y,i[h+d+a]=g-v,d!==l&&(b=u*f-c*p,p=u*p+c*f,f=b)}},y.prototype.guessLen13b=function e(t,n){var r=1|Math.max(n,t),i=1&r,o=0;for(r=r/2|0;r;r>>>=1)o++;return 1<<o+1+i},y.prototype.conjugate=function e(t,n,r){if(!(r<=1))for(var i=0;i<r/2;i++){var o=t[i];t[i]=t[r-i-1],t[r-i-1]=o,o=n[i],n[i]=-n[r-i-1],n[r-i-1]=-o}},y.prototype.normalize13b=function e(t,n){for(var r=0,i=0;i<n/2;i++){var o=8192*Math.round(t[2*i+1]/n)+Math.round(t[2*i]/n)+r;t[i]=67108863&o,r=o<67108864?0:o/67108864|0}return t},y.prototype.convert13b=function e(t,n,i,o){for(var s=0,a=0;a<n;a++)s+=0|t[a],i[2*a]=8191&s,s>>>=13,i[2*a+1]=8191&s,s>>>=13;for(a=2*n;a<o;++a)i[a]=0;r(0===s),r(0==(-8192&s))},y.prototype.stub=function e(t){for(var n=new Array(t),r=0;r<t;r++)n[r]=0;return n},y.prototype.mulp=function e(t,n,r){var i=2*this.guessLen13b(t.length,n.length),o=this.makeRBT(i),s=this.stub(i),a=new Array(i),l=new Array(i),u=new Array(i),c=new Array(i),h=new Array(i),f=new Array(i),p=r.words;p.length=i,this.convert13b(t.words,t.length,a,i),this.convert13b(n.words,n.length,c,i),this.transform(a,s,l,u,i,o),this.transform(c,s,h,f,i,o);for(var d=0;d<i;d++){var m=l[d]*h[d]-u[d]*f[d];u[d]=l[d]*f[d]+u[d]*h[d],l[d]=m}return this.conjugate(l,u,i),this.transform(l,u,p,s,i,o),this.conjugate(p,s,i),this.normalize13b(p,i),r.negative=t.negative^n.negative,r.length=t.length+n.length,r.strip()},o.prototype.mul=function e(t){var n=new o(null);return n.words=new Array(this.length+t.length),this.mulTo(t,n)},o.prototype.mulf=function e(t){var n=new o(null);return n.words=new Array(this.length+t.length),g(this,t,n)},o.prototype.imul=function e(t){return this.clone().mulTo(t,this)},o.prototype.imuln=function e(t){r("number"==typeof t),r(t<67108864);for(var n=0,i=0;i<this.length;i++){var o=(0|this.words[i])*t,s=(67108863&o)+(67108863&n);n>>=26,n+=o/67108864|0,n+=s>>>26,this.words[i]=67108863&s}return 0!==n&&(this.words[i]=n,this.length++),this},o.prototype.muln=function e(t){return this.clone().imuln(t)},o.prototype.sqr=function e(){return this.mul(this)},o.prototype.isqr=function e(){return this.imul(this.clone())},o.prototype.pow=function e(t){var n=f(t);if(0===n.length)return new o(1);for(var r=this,i=0;i<n.length&&0===n[i];i++,r=r.sqr());if(++i<n.length)for(var s=r.sqr();i<n.length;i++,s=s.sqr())0!==n[i]&&(r=r.mul(s));return r},o.prototype.iushln=function e(t){r("number"==typeof t&&t>=0);var n=t%26,i=(t-n)/26,o=67108863>>>26-n<<26-n,s;if(0!==n){var a=0;for(s=0;s<this.length;s++){var l=this.words[s]&o,u=(0|this.words[s])-l<<n;this.words[s]=u|a,a=l>>>26-n}a&&(this.words[s]=a,this.length++)}if(0!==i){for(s=this.length-1;s>=0;s--)this.words[s+i]=this.words[s];for(s=0;s<i;s++)this.words[s]=0;this.length+=i}return this.strip()},o.prototype.ishln=function e(t){return r(0===this.negative),this.iushln(t)},o.prototype.iushrn=function e(t,n,i){var o;r("number"==typeof t&&t>=0),o=n?(n-n%26)/26:0;var s=t%26,a=Math.min((t-s)/26,this.length),l=67108863^67108863>>>s<<s,u=i;if(o-=a,o=Math.max(0,o),u){for(var c=0;c<a;c++)u.words[c]=this.words[c];u.length=a}if(0===a);else if(this.length>a)for(this.length-=a,c=0;c<this.length;c++)this.words[c]=this.words[c+a];else this.words[0]=0,this.length=1;var h=0;for(c=this.length-1;c>=0&&(0!==h||c>=o);c--){var f=0|this.words[c];this.words[c]=h<<26-s|f>>>s,h=f&l}return u&&0!==h&&(u.words[u.length++]=h),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function e(t,n,i){return r(0===this.negative),this.iushrn(t,n,i)},o.prototype.shln=function e(t){return this.clone().ishln(t)},o.prototype.ushln=function e(t){return this.clone().iushln(t)},o.prototype.shrn=function e(t){return this.clone().ishrn(t)},o.prototype.ushrn=function e(t){return this.clone().iushrn(t)},o.prototype.testn=function e(t){r("number"==typeof t&&t>=0);var n=t%26,i=(t-n)/26,o=1<<n;if(this.length<=i)return!1;var s=this.words[i];return!!(s&o)},o.prototype.imaskn=function e(t){r("number"==typeof t&&t>=0);var n=t%26,i=(t-n)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=i)return this;if(0!==n&&i++,this.length=Math.min(i,this.length),0!==n){var o=67108863^67108863>>>n<<n;this.words[this.length-1]&=o}return this.strip()},o.prototype.maskn=function e(t){return this.clone().imaskn(t)},o.prototype.iaddn=function e(t){return r("number"==typeof t),r(t<67108864),t<0?this.isubn(-t):0!==this.negative?1===this.length&&(0|this.words[0])<t?(this.words[0]=t-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(t),this.negative=1,this):this._iaddn(t)},o.prototype._iaddn=function e(t){this.words[0]+=t;for(var n=0;n<this.length&&this.words[n]>=67108864;n++)this.words[n]-=67108864,n===this.length-1?this.words[n+1]=1:this.words[n+1]++;return this.length=Math.max(this.length,n+1),this},o.prototype.isubn=function e(t){if(r("number"==typeof t),r(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var n=0;n<this.length&&this.words[n]<0;n++)this.words[n]+=67108864,this.words[n+1]-=1;return this.strip()},o.prototype.addn=function e(t){return this.clone().iaddn(t)},o.prototype.subn=function e(t){return this.clone().isubn(t)},o.prototype.iabs=function e(){return this.negative=0,this},o.prototype.abs=function e(){return this.clone().iabs()},o.prototype._ishlnsubmul=function e(t,n,i){var o=t.length+i,s,a;this._expand(o);var l=0;for(s=0;s<t.length;s++){a=(0|this.words[s+i])+l;var u=(0|t.words[s])*n;a-=67108863&u,l=(a>>26)-(u/67108864|0),this.words[s+i]=67108863&a}for(;s<this.length-i;s++)a=(0|this.words[s+i])+l,l=a>>26,this.words[s+i]=67108863&a;if(0===l)return this.strip();for(r(-1===l),l=0,s=0;s<this.length;s++)a=-(0|this.words[s])+l,l=a>>26,this.words[s]=67108863&a;return this.negative=1,this.strip()},o.prototype._wordDiv=function e(t,n){var r=this.length-t.length,i=this.clone(),s=t,a=0|s.words[s.length-1],l=this._countBits(a);r=26-l,0!==r&&(s=s.ushln(r),i.iushln(r),a=0|s.words[s.length-1]);var u=i.length-s.length,c;if("mod"!==n){c=new o(null),c.length=u+1,c.words=new Array(c.length);for(var h=0;h<c.length;h++)c.words[h]=0}var f=i.clone()._ishlnsubmul(s,1,u);0===f.negative&&(i=f,c&&(c.words[u]=1));for(var p=u-1;p>=0;p--){var d=67108864*(0|i.words[s.length+p])+(0|i.words[s.length+p-1]);for(d=Math.min(d/a|0,67108863),i._ishlnsubmul(s,d,p);0!==i.negative;)d--,i.negative=0,i._ishlnsubmul(s,1,p),i.isZero()||(i.negative^=1);c&&(c.words[p]=d)}return c&&c.strip(),i.strip(),"div"!==n&&0!==r&&i.iushrn(r),{div:c||null,mod:i}},o.prototype.divmod=function e(t,n,i){return r(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(l=this.neg().divmod(t,n),"mod"!==n&&(s=l.div.neg()),"div"!==n&&(a=l.mod.neg(),i&&0!==a.negative&&a.iadd(t)),{div:s,mod:a}):0===this.negative&&0!==t.negative?(l=this.divmod(t.neg(),n),"mod"!==n&&(s=l.div.neg()),{div:s,mod:l.mod}):0!=(this.negative&t.negative)?(l=this.neg().divmod(t.neg(),n),"div"!==n&&(a=l.mod.neg(),i&&0!==a.negative&&a.isub(t)),{div:l.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===n?{div:this.divn(t.words[0]),mod:null}:"mod"===n?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,n);var s,a,l},o.prototype.div=function e(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function e(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function e(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function e(t){var n=this.divmod(t);if(n.mod.isZero())return n.div;var r=0!==n.div.negative?n.mod.isub(t):n.mod,i=t.ushrn(1),o=t.andln(1),s=r.cmp(i);return s<0||1===o&&0===s?n.div:0!==n.div.negative?n.div.isubn(1):n.div.iaddn(1)},o.prototype.modn=function e(t){r(t<=67108863);for(var n=(1<<26)%t,i=0,o=this.length-1;o>=0;o--)i=(n*i+(0|this.words[o]))%t;return i},o.prototype.idivn=function e(t){r(t<=67108863);for(var n=0,i=this.length-1;i>=0;i--){var o=(0|this.words[i])+67108864*n;this.words[i]=o/t|0,n=o%t}return this.strip()},o.prototype.divn=function e(t){return this.clone().idivn(t)},o.prototype.egcd=function e(t){r(0===t.negative),r(!t.isZero());var n=this,i=t.clone();n=0!==n.negative?n.umod(t):n.clone();for(var s=new o(1),a=new o(0),l=new o(0),u=new o(1),c=0;n.isEven()&&i.isEven();)n.iushrn(1),i.iushrn(1),++c;for(var h=i.clone(),f=n.clone();!n.isZero();){for(var p=0,d=1;0==(n.words[0]&d)&&p<26;++p,d<<=1);if(p>0)for(n.iushrn(p);p-- >0;)(s.isOdd()||a.isOdd())&&(s.iadd(h),a.isub(f)),s.iushrn(1),a.iushrn(1);for(var m=0,g=1;0==(i.words[0]&g)&&m<26;++m,g<<=1);if(m>0)for(i.iushrn(m);m-- >0;)(l.isOdd()||u.isOdd())&&(l.iadd(h),u.isub(f)),l.iushrn(1),u.iushrn(1);n.cmp(i)>=0?(n.isub(i),s.isub(l),a.isub(u)):(i.isub(n),l.isub(s),u.isub(a))}return{a:l,b:u,gcd:i.iushln(c)}},o.prototype._invmp=function e(t){r(0===t.negative),r(!t.isZero());var n=this,i=t.clone();n=0!==n.negative?n.umod(t):n.clone();for(var s=new o(1),a=new o(0),l=i.clone(),u;n.cmpn(1)>0&&i.cmpn(1)>0;){for(var c=0,h=1;0==(n.words[0]&h)&&c<26;++c,h<<=1);if(c>0)for(n.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(l),s.iushrn(1);for(var f=0,p=1;0==(i.words[0]&p)&&f<26;++f,p<<=1);if(f>0)for(i.iushrn(f);f-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);n.cmp(i)>=0?(n.isub(i),s.isub(a)):(i.isub(n),a.isub(s))}return u=0===n.cmpn(1)?s:a,u.cmpn(0)<0&&u.iadd(t),u},o.prototype.gcd=function e(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var n=this.clone(),r=t.clone();n.negative=0,r.negative=0;for(var i=0;n.isEven()&&r.isEven();i++)n.iushrn(1),r.iushrn(1);for(;;){for(;n.isEven();)n.iushrn(1);for(;r.isEven();)r.iushrn(1);var o=n.cmp(r);if(o<0){var s=n;n=r,r=s}else if(0===o||0===r.cmpn(1))break;n.isub(r)}return r.iushln(i)},o.prototype.invm=function e(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function e(){return 0==(1&this.words[0])},o.prototype.isOdd=function e(){return 1==(1&this.words[0])},o.prototype.andln=function e(t){return this.words[0]&t},o.prototype.bincn=function e(t){r("number"==typeof t);var n=t%26,i=(t-n)/26,o=1<<n;if(this.length<=i)return this._expand(i+1),this.words[i]|=o,this;for(var s=o,a=i;0!==s&&a<this.length;a++){var l=0|this.words[a];l+=s,s=l>>>26,l&=67108863,this.words[a]=l}return 0!==s&&(this.words[a]=s,this.length++),this},o.prototype.isZero=function e(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function e(t){var n=t<0,i;if(0!==this.negative&&!n)return-1;if(0===this.negative&&n)return 1;if(this.strip(),this.length>1)i=1;else{n&&(t=-t),r(t<=67108863,"Number is too big");var o=0|this.words[0];i=o===t?0:o<t?-1:1}return 0!==this.negative?0|-i:i},o.prototype.cmp=function e(t){if(0!==this.negative&&0===t.negative)return-1;if(0===this.negative&&0!==t.negative)return 1;var n=this.ucmp(t);return 0!==this.negative?0|-n:n},o.prototype.ucmp=function e(t){if(this.length>t.length)return 1;if(this.length<t.length)return-1;for(var n=0,r=this.length-1;r>=0;r--){var i=0|this.words[r],o=0|t.words[r];if(i!==o){i<o?n=-1:i>o&&(n=1);break}}return n},o.prototype.gtn=function e(t){return 1===this.cmpn(t)},o.prototype.gt=function e(t){return 1===this.cmp(t)},o.prototype.gten=function e(t){return this.cmpn(t)>=0},o.prototype.gte=function e(t){return this.cmp(t)>=0},o.prototype.ltn=function e(t){return-1===this.cmpn(t)},o.prototype.lt=function e(t){return-1===this.cmp(t)},o.prototype.lten=function e(t){return this.cmpn(t)<=0},o.prototype.lte=function e(t){return this.cmp(t)<=0},o.prototype.eqn=function e(t){return 0===this.cmpn(t)},o.prototype.eq=function e(t){return 0===this.cmp(t)},o.red=function e(t){return new S(t)},o.prototype.toRed=function e(t){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function e(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function e(t){return this.red=t,this},o.prototype.forceRed=function e(t){return r(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function e(t){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function e(t){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function e(t){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function e(t){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function e(t){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function e(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function e(t){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function e(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function e(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function e(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function e(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function e(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function e(t){return r(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var v={k256:null,p224:null,p192:null,p25519:null};function b(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function _(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function k(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function E(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(e){if("string"==typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else r(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function x(e){S.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function e(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function e(t){var n=t,r;do{this.split(n,this.tmp),n=this.imulK(n),n=n.iadd(this.tmp),r=n.bitLength()}while(r>this.n);var i=r<this.n?-1:n.ucmp(this.p);return 0===i?(n.words[0]=0,n.length=1):i>0?n.isub(this.p):n.strip(),n},b.prototype.split=function e(t,n){t.iushrn(this.n,0,n)},b.prototype.imulK=function e(t){return t.imul(this.k)},i(_,b),_.prototype.split=function e(t,n){for(var r=4194303,i=Math.min(t.length,9),o=0;o<i;o++)n.words[o]=t.words[o];if(n.length=i,t.length<=9)return t.words[0]=0,void(t.length=1);var s=t.words[9];for(n.words[n.length++]=s&r,o=10;o<t.length;o++){var a=0|t.words[o];t.words[o-10]=(a&r)<<4|s>>>22,s=a}s>>>=22,t.words[o-10]=s,0===s&&t.length>10?t.length-=10:t.length-=9},_.prototype.imulK=function e(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var n=0,r=0;r<t.length;r++){var i=0|t.words[r];n+=977*i,t.words[r]=67108863&n,n=64*i+(n/67108864|0)}return 0===t.words[t.length-1]&&(t.length--,0===t.words[t.length-1]&&t.length--),t},i(w,b),i(k,b),i(E,b),E.prototype.imulK=function e(t){for(var n=0,r=0;r<t.length;r++){var i=19*(0|t.words[r])+n,o=67108863&i;i>>>=26,t.words[r]=o,n=i}return 0!==n&&(t.words[t.length++]=n),t},o._prime=function e(t){if(v[t])return v[t];var e;if("k256"===t)e=new _;else if("p224"===t)e=new w;else if("p192"===t)e=new k;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new E}return v[t]=e,e},S.prototype._verify1=function e(t){r(0===t.negative,"red works only with positives"),r(t.red,"red works only with red numbers")},S.prototype._verify2=function e(t,n){r(0==(t.negative|n.negative),"red works only with positives"),r(t.red&&t.red===n.red,"red works only with red numbers")},S.prototype.imod=function e(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},S.prototype.neg=function e(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},S.prototype.add=function e(t,n){this._verify2(t,n);var r=t.add(n);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function e(t,n){this._verify2(t,n);var r=t.iadd(n);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function e(t,n){this._verify2(t,n);var r=t.sub(n);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function e(t,n){this._verify2(t,n);var r=t.isub(n);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function e(t,n){return this._verify1(t),this.imod(t.ushln(n))},S.prototype.imul=function e(t,n){return this._verify2(t,n),this.imod(t.imul(n))},S.prototype.mul=function e(t,n){return this._verify2(t,n),this.imod(t.mul(n))},S.prototype.isqr=function e(t){return this.imul(t,t.clone())},S.prototype.sqr=function e(t){return this.mul(t,t)},S.prototype.sqrt=function e(t){if(t.isZero())return t.clone();var n=this.m.andln(3);if(r(n%2==1),3===n){var i=this.m.add(new o(1)).iushrn(2);return this.pow(t,i)}for(var s=this.m.subn(1),a=0;!s.isZero()&&0===s.andln(1);)a++,s.iushrn(1);r(!s.isZero());var l=new o(1).toRed(this),u=l.redNeg(),c=this.m.subn(1).iushrn(1),h=this.m.bitLength();for(h=new o(2*h*h).toRed(this);0!==this.pow(h,c).cmp(u);)h.redIAdd(u);for(var f=this.pow(h,s),p=this.pow(t,s.addn(1).iushrn(1)),d=this.pow(t,s),m=a;0!==d.cmp(l);){for(var g=d,y=0;0!==g.cmp(l);y++)g=g.redSqr();r(y<m);var v=this.pow(f,new o(1).iushln(m-y-1));p=p.redMul(v),f=v.redSqr(),d=d.redMul(f),m=y}return p},S.prototype.invm=function e(t){var n=t._invmp(this.m);return 0!==n.negative?(n.negative=0,this.imod(n).redNeg()):this.imod(n)},S.prototype.pow=function e(t,n){if(n.isZero())return new o(1).toRed(this);if(0===n.cmpn(1))return t.clone();var r=4,i=new Array(16);i[0]=new o(1).toRed(this),i[1]=t;for(var s=2;s<i.length;s++)i[s]=this.mul(i[s-1],t);var a=i[0],l=0,u=0,c=n.bitLength()%26;for(0===c&&(c=26),s=n.length-1;s>=0;s--){for(var h=n.words[s],f=c-1;f>=0;f--){var p=h>>f&1;a!==i[0]&&(a=this.sqr(a)),0!==p||0!==l?(l<<=1,l|=p,u++,(4===u||0===s&&0===f)&&(a=this.mul(a,i[l]),u=0,l=0)):u=0}c=26}return a},S.prototype.convertTo=function e(t){var n=t.umod(this.m);return n===t?n.clone():n},S.prototype.convertFrom=function e(t){var n=t.clone();return n.red=null,n},o.mont=function e(t){return new x(t)},i(x,S),x.prototype.convertTo=function e(t){return this.imod(t.ushln(this.shift))},x.prototype.convertFrom=function e(t){var n=this.imod(t.mul(this.rinv));return n.red=null,n},x.prototype.imul=function e(t,n){if(t.isZero()||n.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(n),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),o=r.isub(i).iushrn(this.shift),s=o;return o.cmp(this.m)>=0?s=o.isub(this.m):o.cmpn(0)<0&&(s=o.iadd(this.m)),s._forceRed(this)},x.prototype.mul=function e(t,n){if(t.isZero()||n.isZero())return new o(0)._forceRed(this);var r=t.mul(n),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),s=r.isub(i).iushrn(this.shift),a=s;return s.cmp(this.m)>=0?a=s.isub(this.m):s.cmpn(0)<0&&(a=s.iadd(this.m)),a._forceRed(this)},x.prototype.invm=function e(t){var n=this.imod(t._invmp(this.m).mul(this.r2));return n._forceRed(this)}}(e,this)}).call(this,n(85)(e))},function(e,t){},function(e,t,n){"use strict";const r=n(119),i=n(1),o=t;function s(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}o.define=function e(t,n){return new s(t,n)},s.prototype._createNamed=function e(t){const n=this.name;function r(e){this._initNamed(e,n)}return i(r,t),r.prototype._initNamed=function e(n,r){t.call(this,n,r)},new r(this)},s.prototype._getDecoder=function e(t){return t=t||"der",this.decoders.hasOwnProperty(t)||(this.decoders[t]=this._createNamed(r.decoders[t])),this.decoders[t]},s.prototype.decode=function e(t,n,r){return this._getDecoder(n).decode(t,r)},s.prototype._getEncoder=function e(t){return t=t||"der",this.encoders.hasOwnProperty(t)||(this.encoders[t]=this._createNamed(r.encoders[t])),this.encoders[t]},s.prototype.encode=function e(t,n,r){return this._getEncoder(n).encode(t,r)}},function(e,t,n){"use strict";const r=n(1);function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}t.Reporter=i,i.prototype.isError=function e(t){return t instanceof o},i.prototype.save=function e(){const t=this._reporterState;return{obj:t.obj,pathLen:t.path.length}},i.prototype.restore=function e(t){const n=this._reporterState;n.obj=t.obj,n.path=n.path.slice(0,t.pathLen)},i.prototype.enterKey=function e(t){return this._reporterState.path.push(t)},i.prototype.exitKey=function e(t){const n=this._reporterState;n.path=n.path.slice(0,t-1)},i.prototype.leaveKey=function e(t,n,r){const i=this._reporterState;this.exitKey(t),null!==i.obj&&(i.obj[n]=r)},i.prototype.path=function e(){return this._reporterState.path.join("/")},i.prototype.enterObject=function e(){const t=this._reporterState,n=t.obj;return t.obj={},n},i.prototype.leaveObject=function e(t){const n=this._reporterState,r=n.obj;return n.obj=t,r},i.prototype.error=function e(t){let n;const r=this._reporterState,i=t instanceof o;if(n=i?t:new o(r.path.map(function(e){return"["+JSON.stringify(e)+"]"}).join(""),t.message||t,t.stack),!r.options.partial)throw n;return i||r.errors.push(n),n},i.prototype.wrapResult=function e(t){const n=this._reporterState;return n.options.partial?{result:this.isError(t)?null:t,errors:n.errors}:t},r(o,Error),o.prototype.rethrow=function e(t){if(this.message=t+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,o),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},function(e,t,n){"use strict";const r=n(153).Reporter,i=n(153).EncoderBuffer,o=n(153).DecoderBuffer,s=n(762),a=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],l=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(a),u=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function c(e,t,n){const r={};this._baseState=r,r.name=n,r.enc=e,r.parent=t||null,r.children=null,r.tag=null,r.args=null,r.reverseArgs=null,r.choice=null,r.optional=!1,r.any=!1,r.obj=!1,r.use=null,r.useDecoder=null,r.key=null,r.default=null,r.explicit=null,r.implicit=null,r.contains=null,r.parent||(r.children=[],this._wrap())}e.exports=c;const h=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];c.prototype.clone=function e(){const t=this._baseState,n={};h.forEach(function(e){n[e]=t[e]});const r=new this.constructor(n.parent);return r._baseState=n,r},c.prototype._wrap=function e(){const t=this._baseState;l.forEach(function(e){this[e]=function n(){const r=new this.constructor(this);return t.children.push(r),r[e].apply(r,arguments)}},this)},c.prototype._init=function e(t){const n=this._baseState;s(null===n.parent),t.call(this),n.children=n.children.filter(function(e){return e._baseState.parent===this},this),s.equal(n.children.length,1,"Root node can have only one child")},c.prototype._useArgs=function e(t){const n=this._baseState,r=t.filter(function(e){return e instanceof this.constructor},this);t=t.filter(function(e){return!(e instanceof this.constructor)},this),0!==r.length&&(s(null===n.children),n.children=r,r.forEach(function(e){e._baseState.parent=this},this)),0!==t.length&&(s(null===n.args),n.args=t,n.reverseArgs=t.map(function(e){if("object"!=typeof e||e.constructor!==Object)return e;const t={};return Object.keys(e).forEach(function(n){n==(0|n)&&(n|=0);const r=e[n];t[r]=n}),t}))},u.forEach(function(e){c.prototype[e]=function t(){const n=this._baseState;throw new Error(e+" not implemented for encoding: "+n.enc)}}),a.forEach(function(e){c.prototype[e]=function t(){const n=this._baseState,r=Array.prototype.slice.call(arguments);return s(null===n.tag),n.tag=e,this._useArgs(r),this}}),c.prototype.use=function e(t){s(t);const n=this._baseState;return s(null===n.use),n.use=t,this},c.prototype.optional=function e(){const t=this._baseState;return t.optional=!0,this},c.prototype.def=function e(t){const n=this._baseState;return s(null===n.default),n.default=t,n.optional=!0,this},c.prototype.explicit=function e(t){const n=this._baseState;return s(null===n.explicit&&null===n.implicit),n.explicit=t,this},c.prototype.implicit=function e(t){const n=this._baseState;return s(null===n.explicit&&null===n.implicit),n.implicit=t,this},c.prototype.obj=function e(){const t=this._baseState,n=Array.prototype.slice.call(arguments);return t.obj=!0,0!==n.length&&this._useArgs(n),this},c.prototype.key=function e(t){const n=this._baseState;return s(null===n.key),n.key=t,this},c.prototype.any=function e(){const t=this._baseState;return t.any=!0,this},c.prototype.choice=function e(t){const n=this._baseState;return s(null===n.choice),n.choice=t,this._useArgs(Object.keys(t).map(function(e){return t[e]})),this},c.prototype.contains=function e(t){const n=this._baseState;return s(null===n.use),n.contains=t,this},c.prototype._decode=function e(t,n){const r=this._baseState;if(null===r.parent)return t.wrapResult(r.children[0]._decode(t,n));let i=r.default,s=!0,a=null,l;if(null!==r.key&&(a=t.enterKey(r.key)),r.optional){let e=null;if(null!==r.explicit?e=r.explicit:null!==r.implicit?e=r.implicit:null!==r.tag&&(e=r.tag),null!==e||r.any){if(s=this._peekTag(t,e,r.any),t.isError(s))return s}else{const e=t.save();try{null===r.choice?this._decodeGeneric(r.tag,t,n):this._decodeChoice(t,n),s=!0}catch(e){s=!1}t.restore(e)}}if(r.obj&&s&&(l=t.enterObject()),s){if(null!==r.explicit){const e=this._decodeTag(t,r.explicit);if(t.isError(e))return e;t=e}const e=t.offset;if(null===r.use&&null===r.choice){let e;r.any&&(e=t.save());const n=this._decodeTag(t,null!==r.implicit?r.implicit:r.tag,r.any);if(t.isError(n))return n;r.any?i=t.raw(e):t=n}if(n&&n.track&&null!==r.tag&&n.track(t.path(),e,t.length,"tagged"),n&&n.track&&null!==r.tag&&n.track(t.path(),t.offset,t.length,"content"),r.any||(i=null===r.choice?this._decodeGeneric(r.tag,t,n):this._decodeChoice(t,n)),t.isError(i))return i;if(r.any||null!==r.choice||null===r.children||r.children.forEach(function e(r){r._decode(t,n)}),r.contains&&("octstr"===r.tag||"bitstr"===r.tag)){const e=new o(i);i=this._getUse(r.contains,t._reporterState.obj)._decode(e,n)}}return r.obj&&s&&(i=t.leaveObject(l)),null===r.key||null===i&&!0!==s?null!==a&&t.exitKey(a):t.leaveKey(a,r.key,i),i},c.prototype._decodeGeneric=function e(t,n,r){const i=this._baseState;return"seq"===t||"set"===t?null:"seqof"===t||"setof"===t?this._decodeList(n,t,i.args[0],r):/str$/.test(t)?this._decodeStr(n,t,r):"objid"===t&&i.args?this._decodeObjid(n,i.args[0],i.args[1],r):"objid"===t?this._decodeObjid(n,null,null,r):"gentime"===t||"utctime"===t?this._decodeTime(n,t,r):"null_"===t?this._decodeNull(n,r):"bool"===t?this._decodeBool(n,r):"objDesc"===t?this._decodeStr(n,t,r):"int"===t||"enum"===t?this._decodeInt(n,i.args&&i.args[0],r):null!==i.use?this._getUse(i.use,n._reporterState.obj)._decode(n,r):n.error("unknown tag: "+t)},c.prototype._getUse=function e(t,n){const r=this._baseState;return r.useDecoder=this._use(t,n),s(null===r.useDecoder._baseState.parent),r.useDecoder=r.useDecoder._baseState.children[0],r.implicit!==r.useDecoder._baseState.implicit&&(r.useDecoder=r.useDecoder.clone(),r.useDecoder._baseState.implicit=r.implicit),r.useDecoder},c.prototype._decodeChoice=function e(t,n){const r=this._baseState;let i=null,o=!1;return Object.keys(r.choice).some(function(e){const s=t.save(),a=r.choice[e];try{const r=a._decode(t,n);if(t.isError(r))return!1;i={type:e,value:r},o=!0}catch(e){return t.restore(s),!1}return!0},this),o?i:t.error("Choice not matched")},c.prototype._createEncoderBuffer=function e(t){return new i(t,this.reporter)},c.prototype._encode=function e(t,n,r){const i=this._baseState;if(null!==i.default&&i.default===t)return;const o=this._encodeValue(t,n,r);return void 0===o||this._skipDefault(o,n,r)?void 0:o},c.prototype._encodeValue=function e(t,n,i){const o=this._baseState;if(null===o.parent)return o.children[0]._encode(t,n||new r);let s=null;if(this.reporter=n,o.optional&&void 0===t){if(null===o.default)return;t=o.default}let a=null,l=!1;if(o.any)s=this._createEncoderBuffer(t);else if(o.choice)s=this._encodeChoice(t,n);else if(o.contains)a=this._getUse(o.contains,i)._encode(t,n),l=!0;else if(o.children)a=o.children.map(function(e){if("null_"===e._baseState.tag)return e._encode(null,n,t);if(null===e._baseState.key)return n.error("Child should have a key");const r=n.enterKey(e._baseState.key);if("object"!=typeof t)return n.error("Child expected, but input is not object");const i=e._encode(t[e._baseState.key],n,t);return n.leaveKey(r),i},this).filter(function(e){return e}),a=this._createEncoderBuffer(a);else if("seqof"===o.tag||"setof"===o.tag){if(!o.args||1!==o.args.length)return n.error("Too many args for : "+o.tag);if(!Array.isArray(t))return n.error("seqof/setof, but data is not Array");const e=this.clone();e._baseState.implicit=null,a=this._createEncoderBuffer(t.map(function(e){const r=this._baseState;return this._getUse(r.args[0],t)._encode(e,n)},e))}else null!==o.use?s=this._getUse(o.use,i)._encode(t,n):(a=this._encodePrimitive(o.tag,t),l=!0);if(!o.any&&null===o.choice){const e=null!==o.implicit?o.implicit:o.tag,t=null===o.implicit?"universal":"context";null===e?null===o.use&&n.error("Tag could be omitted only for .use()"):null===o.use&&(s=this._encodeComposite(e,l,t,a))}return null!==o.explicit&&(s=this._encodeComposite(o.explicit,!1,"context",s)),s},c.prototype._encodeChoice=function e(t,n){const r=this._baseState,i=r.choice[t.type];return i||s(!1,t.type+" not found in "+JSON.stringify(Object.keys(r.choice))),i._encode(t.value,n)},c.prototype._encodePrimitive=function e(t,n){const r=this._baseState;if(/str$/.test(t))return this._encodeStr(n,t);if("objid"===t&&r.args)return this._encodeObjid(n,r.reverseArgs[0],r.args[1]);if("objid"===t)return this._encodeObjid(n,null,null);if("gentime"===t||"utctime"===t)return this._encodeTime(n,t);if("null_"===t)return this._encodeNull();if("int"===t||"enum"===t)return this._encodeInt(n,r.args&&r.reverseArgs[0]);if("bool"===t)return this._encodeBool(n);if("objDesc"===t)return this._encodeStr(n,t);throw new Error("Unsupported tag: "+t)},c.prototype._isNumstr=function e(t){return/^[0-9 ]*$/.test(t)},c.prototype._isPrintstr=function e(t){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(t)}},function(e,t){function n(e,t){if(!e)throw new Error(t||"Assertion failed")}e.exports=n,n.equal=function e(t,n,r){if(t!=n)throw new Error(r||"Assertion failed: "+t+" != "+n)}},function(e,t,n){"use strict";const r=n(375);t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r._reverse(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=r._reverse(t.tag)},function(e,t,n){"use strict";const r=t;r.der=n(376),r.pem=n(765)},function(e,t,n){"use strict";const r=n(1),i=n(0).Buffer,o=n(376);function s(e){o.call(this,e),this.enc="pem"}r(s,o),e.exports=s,s.prototype.decode=function e(t,n){const r=t.toString().split(/[\r\n]+/g),s=n.label.toUpperCase(),a=/^-----(BEGIN|END) ([^-]+)-----$/;let l=-1,u=-1;for(let e=0;e<r.length;e++){const t=r[e].match(a);if(null!==t&&t[2]===s){if(-1!==l){if("END"!==t[1])break;u=e;break}if("BEGIN"!==t[1])break;l=e}}if(-1===l||-1===u)throw new Error("PEM section not found for: "+s);const c=r.slice(l+1,u).join("");c.replace(/[^a-z0-9+/=]+/gi,"");const h=new i(c,"base64");return o.prototype.decode.call(this,h,n)}},function(e,t,n){"use strict";const r=t;r.der=n(377),r.pem=n(767)},function(e,t,n){"use strict";const r=n(1),i=n(377);function o(e){i.call(this,e),this.enc="pem"}r(o,i),e.exports=o,o.prototype.encode=function e(t,n){const r=i.prototype.encode.call(this,t),o=r.toString("base64"),s=["-----BEGIN "+n.label+"-----"];for(let e=0;e<o.length;e+=64)s.push(o.slice(e,e+64));return s.push("-----END "+n.label+"-----"),s.join("\n")}},function(e,t,n){var r=n(21);n(97),n(30);var i=e.exports=r.sha512=r.sha512||{};r.md.sha512=r.md.algorithms.sha512=i;var o=r.sha384=r.sha512.sha384=r.sha512.sha384||{};o.create=function(){return i.create("SHA-384")},r.md.sha384=r.md.algorithms.sha384=o,r.sha512.sha256=r.sha512.sha256||{create:function(){return i.create("SHA-512/256")}},r.md["sha512/256"]=r.md.algorithms["sha512/256"]=r.sha512.sha256,r.sha512.sha224=r.sha512.sha224||{create:function(){return i.create("SHA-512/224")}},r.md["sha512/224"]=r.md.algorithms["sha512/224"]=r.sha512.sha224,i.create=function(e){if(a||c(),void 0===e&&(e="SHA-512"),!(e in u))throw new Error("Invalid SHA-512 algorithm: "+e);for(var t=u[e],n=null,i=r.util.createBuffer(),o=new Array(80),l=0;l<80;++l)o[l]=new Array(2);var f=64;switch(e){case"SHA-384":f=48;break;case"SHA-512/256":f=32;break;case"SHA-512/224":f=28}var p={algorithm:e.replace("-","").toLowerCase(),blockLength:128,digestLength:f,messageLength:0,fullMessageLength:null,messageLengthSize:16,start:function(){p.messageLength=0,p.fullMessageLength=p.messageLength128=[];for(var e=p.messageLengthSize/4,o=0;o<e;++o)p.fullMessageLength.push(0);i=r.util.createBuffer(),n=new Array(t.length);for(var o=0;o<t.length;++o)n[o]=t[o].slice(0);return p}};return p.start(),p.update=function(e,t){"utf8"===t&&(e=r.util.encodeUtf8(e));var s=e.length;p.messageLength+=s,s=[s/4294967296>>>0,s>>>0];for(var a=p.fullMessageLength.length-1;a>=0;--a)p.fullMessageLength[a]+=s[1],s[1]=s[0]+(p.fullMessageLength[a]/4294967296>>>0),p.fullMessageLength[a]=p.fullMessageLength[a]>>>0,s[0]=s[1]/4294967296>>>0;return i.putBytes(e),h(n,o,i),(i.read>2048||0===i.length())&&i.compact(),p},p.digest=function(){var t=r.util.createBuffer();t.putBytes(i.bytes());var a=p.fullMessageLength[p.fullMessageLength.length-1]+p.messageLengthSize,l=a&p.blockLength-1,u,c;t.putBytes(s.substr(0,p.blockLength-l));for(var f=8*p.fullMessageLength[0],d=0;d<p.fullMessageLength.length-1;++d)u=8*p.fullMessageLength[d+1],c=u/4294967296>>>0,f+=c,t.putInt32(f>>>0),f=u>>>0;t.putInt32(f);for(var m=new Array(n.length),d=0;d<n.length;++d)m[d]=n[d].slice(0);h(m,o,t);var g=r.util.createBuffer(),y;y="SHA-512"===e?m.length:"SHA-384"===e?m.length-2:m.length-4;for(var d=0;d<y;++d)g.putInt32(m[d][0]),d===y-1&&"SHA-512/224"===e||g.putInt32(m[d][1]);return g},p};var s=null,a=!1,l=null,u=null;function c(){s=String.fromCharCode(128),s+=r.util.fillString(String.fromCharCode(0),128),l=[[1116352408,3609767458],[1899447441,602891725],[3049323471,3964484399],[3921009573,2173295548],[961987163,4081628472],[1508970993,3053834265],[2453635748,2937671579],[2870763221,3664609560],[3624381080,2734883394],[310598401,1164996542],[607225278,1323610764],[1426881987,3590304994],[1925078388,4068182383],[2162078206,991336113],[2614888103,633803317],[3248222580,3479774868],[3835390401,2666613458],[4022224774,944711139],[264347078,2341262773],[604807628,2007800933],[770255983,1495990901],[1249150122,1856431235],[1555081692,3175218132],[1996064986,2198950837],[2554220882,3999719339],[2821834349,766784016],[2952996808,2566594879],[3210313671,3203337956],[3336571891,1034457026],[3584528711,2466948901],[113926993,3758326383],[338241895,168717936],[666307205,1188179964],[773529912,1546045734],[1294757372,1522805485],[1396182291,2643833823],[1695183700,2343527390],[1986661051,1014477480],[2177026350,1206759142],[2456956037,344077627],[2730485921,1290863460],[2820302411,3158454273],[3259730800,3505952657],[3345764771,106217008],[3516065817,3606008344],[3600352804,1432725776],[4094571909,1467031594],[275423344,851169720],[430227734,3100823752],[506948616,1363258195],[659060556,3750685593],[883997877,3785050280],[958139571,3318307427],[1322822218,3812723403],[1537002063,2003034995],[1747873779,3602036899],[1955562222,1575990012],[2024104815,1125592928],[2227730452,2716904306],[2361852424,442776044],[2428436474,593698344],[2756734187,3733110249],[3204031479,2999351573],[3329325298,3815920427],[3391569614,3928383900],[3515267271,566280711],[3940187606,3454069534],[4118630271,4000239992],[116418474,1914138554],[174292421,2731055270],[289380356,3203993006],[460393269,320620315],[685471733,587496836],[852142971,1086792851],[1017036298,365543100],[1126000580,2618297676],[1288033470,3409855158],[1501505948,4234509866],[1607167915,987167468],[1816402316,1246189591]],u={},u["SHA-512"]=[[1779033703,4089235720],[3144134277,2227873595],[1013904242,4271175723],[2773480762,1595750129],[1359893119,2917565137],[2600822924,725511199],[528734635,4215389547],[1541459225,327033209]],u["SHA-384"]=[[3418070365,3238371032],[1654270250,914150663],[2438529370,812702999],[355462360,4144912697],[1731405415,4290775857],[2394180231,1750603025],[3675008525,1694076839],[1203062813,3204075428]],u["SHA-512/256"]=[[573645204,4230739756],[2673172387,3360449730],[596883563,1867755857],[2520282905,1497426621],[2519219938,2827943907],[3193839141,1401305490],[721525244,746961066],[246885852,2177182882]],u["SHA-512/224"]=[[2352822216,424955298],[1944164710,2312950998],[502970286,855612546],[1738396948,1479516111],[258812777,2077511080],[2011393907,79989058],[1067287976,1780299464],[286451373,2446758561]],a=!0}function h(e,t,n){for(var r,i,o,s,a,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E,S,x,C,A,T,I,j,R,B,O,P,N,D,M,F,L=n.length();L>=128;){for(B=0;B<16;++B)t[B][0]=n.getInt32()>>>0,t[B][1]=n.getInt32()>>>0;for(;B<80;++B)N=t[B-2],O=N[0],P=N[1],r=((O>>>19|P<<13)^(P>>>29|O<<3)^O>>>6)>>>0,i=((O<<13|P>>>19)^(P<<3|O>>>29)^(O<<26|P>>>6))>>>0,M=t[B-15],O=M[0],P=M[1],o=((O>>>1|P<<31)^(O>>>8|P<<24)^O>>>7)>>>0,s=((O<<31|P>>>1)^(O<<24|P>>>8)^(O<<25|P>>>7))>>>0,D=t[B-7],F=t[B-16],P=i+D[1]+s+F[1],t[B][0]=r+D[0]+o+F[0]+(P/4294967296>>>0)>>>0,t[B][1]=P>>>0;for(g=e[0][0],y=e[0][1],v=e[1][0],b=e[1][1],_=e[2][0],w=e[2][1],k=e[3][0],E=e[3][1],S=e[4][0],x=e[4][1],C=e[5][0],A=e[5][1],T=e[6][0],I=e[6][1],j=e[7][0],R=e[7][1],B=0;B<80;++B)c=((S>>>14|x<<18)^(S>>>18|x<<14)^(x>>>9|S<<23))>>>0,h=((S<<18|x>>>14)^(S<<14|x>>>18)^(x<<23|S>>>9))>>>0,f=(T^S&(C^T))>>>0,p=(I^x&(A^I))>>>0,a=((g>>>28|y<<4)^(y>>>2|g<<30)^(y>>>7|g<<25))>>>0,u=((g<<4|y>>>28)^(y<<30|g>>>2)^(y<<25|g>>>7))>>>0,d=(g&v|_&(g^v))>>>0,m=(y&b|w&(y^b))>>>0,P=R+h+p+l[B][1]+t[B][1],r=j+c+f+l[B][0]+t[B][0]+(P/4294967296>>>0)>>>0,i=P>>>0,P=u+m,o=a+d+(P/4294967296>>>0)>>>0,s=P>>>0,j=T,R=I,T=C,I=A,C=S,A=x,P=E+i,S=k+r+(P/4294967296>>>0)>>>0,x=P>>>0,k=_,E=w,_=v,w=b,v=g,b=y,P=i+s,g=r+o+(P/4294967296>>>0)>>>0,y=P>>>0;P=e[0][1]+y,e[0][0]=e[0][0]+g+(P/4294967296>>>0)>>>0,e[0][1]=P>>>0,P=e[1][1]+b,e[1][0]=e[1][0]+v+(P/4294967296>>>0)>>>0,e[1][1]=P>>>0,P=e[2][1]+w,e[2][0]=e[2][0]+_+(P/4294967296>>>0)>>>0,e[2][1]=P>>>0,P=e[3][1]+E,e[3][0]=e[3][0]+k+(P/4294967296>>>0)>>>0,e[3][1]=P>>>0,P=e[4][1]+x,e[4][0]=e[4][0]+S+(P/4294967296>>>0)>>>0,e[4][1]=P>>>0,P=e[5][1]+A,e[5][0]=e[5][0]+C+(P/4294967296>>>0)>>>0,e[5][1]=P>>>0,P=e[6][1]+I,e[6][0]=e[6][0]+T+(P/4294967296>>>0)>>>0,e[6][1]=P>>>0,P=e[7][1]+R,e[7][0]=e[7][0]+j+(P/4294967296>>>0)>>>0,e[7][1]=P>>>0,L-=128}}},function(e,t,n){"use strict";(function(t){const r=n(56),i=n(57),o=n(70),s=n(770),a=i(n(249));class l{constructor(e){this._key=m(e,s.publicKeyLength)}verify(e,t,n){d(n),s.hashAndVerify(this._key,t,e,n)}marshal(){return t.from(this._key)}get bytes(){return a.PublicKey.encode({Type:a.KeyType.Ed25519,Data:this.marshal()})}equals(e){return this.bytes.equals(e.bytes)}hash(e){d(e),r(this.bytes,"sha2-256",e)}}class u{constructor(e,t){this._key=m(e,s.privateKeyLength),this._publicKey=m(t,s.publicKeyLength)}sign(e,t){d(t),s.hashAndSign(this._key,e,t)}get public(){if(!this._publicKey)throw new Error("public key not provided");return new l(this._publicKey)}marshal(){return t.concat([t.from(this._key),t.from(this._publicKey)])}get bytes(){return a.PrivateKey.encode({Type:a.KeyType.Ed25519,Data:this.marshal()})}equals(e){return this.bytes.equals(e.bytes)}hash(e){d(e),r(this.bytes,"sha2-256",e)}id(e){this.public.hash((t,n)=>{if(t)return e(t);e(null,o.encode(n))})}}function c(e,t){try{e=m(e,s.privateKeyLength+s.publicKeyLength)}catch(e){return t(e)}const n=e.slice(0,s.privateKeyLength),r=e.slice(s.privateKeyLength,e.length);t(null,new u(n,r))}function h(e){return e=m(e,s.publicKeyLength),new l(e)}function f(e,t){void 0===t&&"function"==typeof e&&(t=e),s.generateKey((e,n)=>{if(e)return t(e);let r;try{r=new u(n.secretKey,n.publicKey)}catch(e){return void t(e)}t(null,r)})}function p(e,t,n){void 0===n&&"function"==typeof t&&(n=t),s.generateKeyFromSeed(e,(e,t)=>{if(e)return n(e);let r;try{r=new u(t.secretKey,t.publicKey)}catch(e){return void n(e)}n(null,r)})}function d(e){if("function"!=typeof e)throw new Error("callback is required")}function m(e,n){if(t.isBuffer(e)&&(e=new Uint8Array(e)),!(e instanceof Uint8Array)||e.length!==n)throw new Error("Key must be a Uint8Array or Buffer of length "+n);return e}e.exports={Ed25519PublicKey:l,Ed25519PrivateKey:u,unmarshalEd25519PrivateKey:c,unmarshalEd25519PublicKey:h,generateKeyPair:f,generateKeyPairFromSeed:p}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(e){const r=n(771),i=n(47);t.publicKeyLength=r.sign.publicKeyLength,t.privateKeyLength=r.sign.secretKeyLength,t.generateKey=function(e){i(()=>{let t;try{t=r.sign.keyPair()}catch(t){return e(t)}e(null,t)})},t.generateKeyFromSeed=function(e,t){i(()=>{let n;try{n=r.sign.keyPair.fromSeed(e)}catch(e){return t(e)}t(null,n)})},t.hashAndSign=function(t,n,o){i(()=>{o(null,e.from(r.sign.detached(n,t)))})},t.hashAndVerify=function(e,t,n,o){i(()=>{let i;try{i=r.sign.detached.verify(n,t,e)}catch(e){return o(e)}o(null,i)})}}).call(this,n(0).Buffer)},function(e,t,n){!function(e){"use strict";var t=function(e){var t,n=new Float64Array(16);if(e)for(t=0;t<e.length;t++)n[t]=e[t];return n},r=function(){throw new Error("no PRNG")},i=new Uint8Array(16),o=new Uint8Array(32);o[0]=9;var s=t(),a=t([1]),l=t([56129,1]),u=t([30883,4953,19914,30187,55467,16705,2637,112,59544,30585,16505,36039,65139,11119,27886,20995]),c=t([61785,9906,39828,60374,45398,33411,5274,224,53552,61171,33010,6542,64743,22239,55772,9222]),h=t([54554,36645,11616,51542,42930,38181,51040,26924,56412,64982,57905,49316,21502,52590,14035,8553]),f=t([26200,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214,26214]),p=t([41136,18958,6951,50414,58488,44335,6150,12099,55207,15867,153,11085,57099,20417,9344,11139]);function d(e,t,n,r){e[t]=n>>24&255,e[t+1]=n>>16&255,e[t+2]=n>>8&255,e[t+3]=255&n,e[t+4]=r>>24&255,e[t+5]=r>>16&255,e[t+6]=r>>8&255,e[t+7]=255&r}function m(e,t,n,r,i){var o,s=0;for(o=0;o<i;o++)s|=e[t+o]^n[r+o];return(1&s-1>>>8)-1}function g(e,t,n,r){return m(e,t,n,r,16)}function y(e,t,n,r){return m(e,t,n,r,32)}function v(e,t,n,r){for(var i=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,o=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,a=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,f=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,d=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,m=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,v=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,b=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=i,w=o,k=s,E=a,S=l,x=u,C=c,A=h,T=f,I=p,j=d,R=m,B=g,O=y,P=v,N=b,D,M=0;M<20;M+=2)D=_+B|0,S^=D<<7|D>>>25,D=S+_|0,T^=D<<9|D>>>23,D=T+S|0,B^=D<<13|D>>>19,D=B+T|0,_^=D<<18|D>>>14,D=x+w|0,I^=D<<7|D>>>25,D=I+x|0,O^=D<<9|D>>>23,D=O+I|0,w^=D<<13|D>>>19,D=w+O|0,x^=D<<18|D>>>14,D=j+C|0,P^=D<<7|D>>>25,D=P+j|0,k^=D<<9|D>>>23,D=k+P|0,C^=D<<13|D>>>19,D=C+k|0,j^=D<<18|D>>>14,D=N+R|0,E^=D<<7|D>>>25,D=E+N|0,A^=D<<9|D>>>23,D=A+E|0,R^=D<<13|D>>>19,D=R+A|0,N^=D<<18|D>>>14,D=_+E|0,w^=D<<7|D>>>25,D=w+_|0,k^=D<<9|D>>>23,D=k+w|0,E^=D<<13|D>>>19,D=E+k|0,_^=D<<18|D>>>14,D=x+S|0,C^=D<<7|D>>>25,D=C+x|0,A^=D<<9|D>>>23,D=A+C|0,S^=D<<13|D>>>19,D=S+A|0,x^=D<<18|D>>>14,D=j+I|0,R^=D<<7|D>>>25,D=R+j|0,T^=D<<9|D>>>23,D=T+R|0,I^=D<<13|D>>>19,D=I+T|0,j^=D<<18|D>>>14,D=N+P|0,B^=D<<7|D>>>25,D=B+N|0,O^=D<<9|D>>>23,D=O+B|0,P^=D<<13|D>>>19,D=P+O|0,N^=D<<18|D>>>14;_=_+i|0,w=w+o|0,k=k+s|0,E=E+a|0,S=S+l|0,x=x+u|0,C=C+c|0,A=A+h|0,T=T+f|0,I=I+p|0,j=j+d|0,R=R+m|0,B=B+g|0,O=O+y|0,P=P+v|0,N=N+b|0,e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=w>>>0&255,e[5]=w>>>8&255,e[6]=w>>>16&255,e[7]=w>>>24&255,e[8]=k>>>0&255,e[9]=k>>>8&255,e[10]=k>>>16&255,e[11]=k>>>24&255,e[12]=E>>>0&255,e[13]=E>>>8&255,e[14]=E>>>16&255,e[15]=E>>>24&255,e[16]=S>>>0&255,e[17]=S>>>8&255,e[18]=S>>>16&255,e[19]=S>>>24&255,e[20]=x>>>0&255,e[21]=x>>>8&255,e[22]=x>>>16&255,e[23]=x>>>24&255,e[24]=C>>>0&255,e[25]=C>>>8&255,e[26]=C>>>16&255,e[27]=C>>>24&255,e[28]=A>>>0&255,e[29]=A>>>8&255,e[30]=A>>>16&255,e[31]=A>>>24&255,e[32]=T>>>0&255,e[33]=T>>>8&255,e[34]=T>>>16&255,e[35]=T>>>24&255,e[36]=I>>>0&255,e[37]=I>>>8&255,e[38]=I>>>16&255,e[39]=I>>>24&255,e[40]=j>>>0&255,e[41]=j>>>8&255,e[42]=j>>>16&255,e[43]=j>>>24&255,e[44]=R>>>0&255,e[45]=R>>>8&255,e[46]=R>>>16&255,e[47]=R>>>24&255,e[48]=B>>>0&255,e[49]=B>>>8&255,e[50]=B>>>16&255,e[51]=B>>>24&255,e[52]=O>>>0&255,e[53]=O>>>8&255,e[54]=O>>>16&255,e[55]=O>>>24&255,e[56]=P>>>0&255,e[57]=P>>>8&255,e[58]=P>>>16&255,e[59]=P>>>24&255,e[60]=N>>>0&255,e[61]=N>>>8&255,e[62]=N>>>16&255,e[63]=N>>>24&255}function b(e,t,n,r){for(var i=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,o=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,a=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,u=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,c=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,h=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,f=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,d=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,m=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,v=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,b=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=i,w=o,k=s,E=a,S=l,x=u,C=c,A=h,T=f,I=p,j=d,R=m,B=g,O=y,P=v,N=b,D,M=0;M<20;M+=2)D=_+B|0,S^=D<<7|D>>>25,D=S+_|0,T^=D<<9|D>>>23,D=T+S|0,B^=D<<13|D>>>19,D=B+T|0,_^=D<<18|D>>>14,D=x+w|0,I^=D<<7|D>>>25,D=I+x|0,O^=D<<9|D>>>23,D=O+I|0,w^=D<<13|D>>>19,D=w+O|0,x^=D<<18|D>>>14,D=j+C|0,P^=D<<7|D>>>25,D=P+j|0,k^=D<<9|D>>>23,D=k+P|0,C^=D<<13|D>>>19,D=C+k|0,j^=D<<18|D>>>14,D=N+R|0,E^=D<<7|D>>>25,D=E+N|0,A^=D<<9|D>>>23,D=A+E|0,R^=D<<13|D>>>19,D=R+A|0,N^=D<<18|D>>>14,D=_+E|0,w^=D<<7|D>>>25,D=w+_|0,k^=D<<9|D>>>23,D=k+w|0,E^=D<<13|D>>>19,D=E+k|0,_^=D<<18|D>>>14,D=x+S|0,C^=D<<7|D>>>25,D=C+x|0,A^=D<<9|D>>>23,D=A+C|0,S^=D<<13|D>>>19,D=S+A|0,x^=D<<18|D>>>14,D=j+I|0,R^=D<<7|D>>>25,D=R+j|0,T^=D<<9|D>>>23,D=T+R|0,I^=D<<13|D>>>19,D=I+T|0,j^=D<<18|D>>>14,D=N+P|0,B^=D<<7|D>>>25,D=B+N|0,O^=D<<9|D>>>23,D=O+B|0,P^=D<<13|D>>>19,D=P+O|0,N^=D<<18|D>>>14;e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=x>>>0&255,e[5]=x>>>8&255,e[6]=x>>>16&255,e[7]=x>>>24&255,e[8]=j>>>0&255,e[9]=j>>>8&255,e[10]=j>>>16&255,e[11]=j>>>24&255,e[12]=N>>>0&255,e[13]=N>>>8&255,e[14]=N>>>16&255,e[15]=N>>>24&255,e[16]=C>>>0&255,e[17]=C>>>8&255,e[18]=C>>>16&255,e[19]=C>>>24&255,e[20]=A>>>0&255,e[21]=A>>>8&255,e[22]=A>>>16&255,e[23]=A>>>24&255,e[24]=T>>>0&255,e[25]=T>>>8&255,e[26]=T>>>16&255,e[27]=T>>>24&255,e[28]=I>>>0&255,e[29]=I>>>8&255,e[30]=I>>>16&255,e[31]=I>>>24&255}function _(e,t,n,r){v(e,t,n,r)}function w(e,t,n,r){b(e,t,n,r)}var k=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function E(e,t,n,r,i,o,s){var a=new Uint8Array(16),l=new Uint8Array(64),u,c;for(c=0;c<16;c++)a[c]=0;for(c=0;c<8;c++)a[c]=o[c];for(;i>=64;){for(_(l,a,s,k),c=0;c<64;c++)e[t+c]=n[r+c]^l[c];for(u=1,c=8;c<16;c++)u=u+(255&a[c])|0,a[c]=255&u,u>>>=8;i-=64,t+=64,r+=64}if(i>0)for(_(l,a,s,k),c=0;c<i;c++)e[t+c]=n[r+c]^l[c];return 0}function S(e,t,n,r,i){var o=new Uint8Array(16),s=new Uint8Array(64),a,l;for(l=0;l<16;l++)o[l]=0;for(l=0;l<8;l++)o[l]=r[l];for(;n>=64;){for(_(s,o,i,k),l=0;l<64;l++)e[t+l]=s[l];for(a=1,l=8;l<16;l++)a=a+(255&o[l])|0,o[l]=255&a,a>>>=8;n-=64,t+=64}if(n>0)for(_(s,o,i,k),l=0;l<n;l++)e[t+l]=s[l];return 0}function x(e,t,n,r,i){var o=new Uint8Array(32);w(o,r,i,k);for(var s=new Uint8Array(8),a=0;a<8;a++)s[a]=r[a+16];return S(e,t,n,s,o)}function C(e,t,n,r,i,o,s){var a=new Uint8Array(32);w(a,o,s,k);for(var l=new Uint8Array(8),u=0;u<8;u++)l[u]=o[u+16];return E(e,t,n,r,i,l,a)}var A=function(e){var t,n,r,i,o,s,a,l;this.buffer=new Uint8Array(16),this.r=new Uint16Array(10),this.h=new Uint16Array(10),this.pad=new Uint16Array(8),this.leftover=0,this.fin=0,t=255&e[0]|(255&e[1])<<8,this.r[0]=8191&t,n=255&e[2]|(255&e[3])<<8,this.r[1]=8191&(t>>>13|n<<3),r=255&e[4]|(255&e[5])<<8,this.r[2]=7939&(n>>>10|r<<6),i=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(r>>>7|i<<9),o=255&e[8]|(255&e[9])<<8,this.r[4]=255&(i>>>4|o<<12),this.r[5]=o>>>1&8190,s=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(o>>>14|s<<2),a=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(s>>>11|a<<5),l=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(a>>>8|l<<8),this.r[9]=l>>>5&127,this.pad[0]=255&e[16]|(255&e[17])<<8,this.pad[1]=255&e[18]|(255&e[19])<<8,this.pad[2]=255&e[20]|(255&e[21])<<8,this.pad[3]=255&e[22]|(255&e[23])<<8,this.pad[4]=255&e[24]|(255&e[25])<<8,this.pad[5]=255&e[26]|(255&e[27])<<8,this.pad[6]=255&e[28]|(255&e[29])<<8,this.pad[7]=255&e[30]|(255&e[31])<<8};function T(e,t,n,r,i,o){var s=new A(o);return s.update(n,r,i),s.finish(e,t),0}function I(e,t,n,r,i,o){var s=new Uint8Array(16);return T(s,0,n,r,i,o),g(e,t,s,0)}function j(e,t,n,r,i){var o;if(n<32)return-1;for(C(e,0,t,0,n,r,i),T(e,16,e,32,n-32,e),o=0;o<16;o++)e[o]=0;return 0}function R(e,t,n,r,i){var o,s=new Uint8Array(32);if(n<32)return-1;if(x(s,0,32,r,i),0!==I(t,16,t,32,n-32,s))return-1;for(C(e,0,t,0,n,r,i),o=0;o<32;o++)e[o]=0;return 0}function B(e,t){var n;for(n=0;n<16;n++)e[n]=0|t[n]}function O(e){var t,n,r=1;for(t=0;t<16;t++)n=e[t]+r+65535,r=Math.floor(n/65536),e[t]=n-65536*r;e[0]+=r-1+37*(r-1)}function P(e,t,n){for(var r,i=~(n-1),o=0;o<16;o++)r=i&(e[o]^t[o]),e[o]^=r,t[o]^=r}function N(e,n){var r,i,o,s=t(),a=t();for(r=0;r<16;r++)a[r]=n[r];for(O(a),O(a),O(a),i=0;i<2;i++){for(s[0]=a[0]-65517,r=1;r<15;r++)s[r]=a[r]-65535-(s[r-1]>>16&1),s[r-1]&=65535;s[15]=a[15]-32767-(s[14]>>16&1),o=s[15]>>16&1,s[14]&=65535,P(a,s,1-o)}for(r=0;r<16;r++)e[2*r]=255&a[r],e[2*r+1]=a[r]>>8}function D(e,t){var n=new Uint8Array(32),r=new Uint8Array(32);return N(n,e),N(r,t),y(n,0,r,0)}function M(e){var t=new Uint8Array(32);return N(t,e),1&t[0]}function F(e,t){var n;for(n=0;n<16;n++)e[n]=t[2*n]+(t[2*n+1]<<8);e[15]&=32767}function L(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]+n[r]}function U(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]-n[r]}function q(e,t,n){var r,i,o=0,s=0,a=0,l=0,u=0,c=0,h=0,f=0,p=0,d=0,m=0,g=0,y=0,v=0,b=0,_=0,w=0,k=0,E=0,S=0,x=0,C=0,A=0,T=0,I=0,j=0,R=0,B=0,O=0,P=0,N=0,D=n[0],M=n[1],F=n[2],L=n[3],U=n[4],q=n[5],z=n[6],K=n[7],H=n[8],V=n[9],$=n[10],W=n[11],G=n[12],Y=n[13],Z=n[14],J=n[15];r=t[0],o+=r*D,s+=r*M,a+=r*F,l+=r*L,u+=r*U,c+=r*q,h+=r*z,f+=r*K,p+=r*H,d+=r*V,m+=r*$,g+=r*W,y+=r*G,v+=r*Y,b+=r*Z,_+=r*J,r=t[1],s+=r*D,a+=r*M,l+=r*F,u+=r*L,c+=r*U,h+=r*q,f+=r*z,p+=r*K,d+=r*H,m+=r*V,g+=r*$,y+=r*W,v+=r*G,b+=r*Y,_+=r*Z,w+=r*J,r=t[2],a+=r*D,l+=r*M,u+=r*F,c+=r*L,h+=r*U,f+=r*q,p+=r*z,d+=r*K,m+=r*H,g+=r*V,y+=r*$,v+=r*W,b+=r*G,_+=r*Y,w+=r*Z,k+=r*J,r=t[3],l+=r*D,u+=r*M,c+=r*F,h+=r*L,f+=r*U,p+=r*q,d+=r*z,m+=r*K,g+=r*H,y+=r*V,v+=r*$,b+=r*W,_+=r*G,w+=r*Y,k+=r*Z,E+=r*J,r=t[4],u+=r*D,c+=r*M,h+=r*F,f+=r*L,p+=r*U,d+=r*q,m+=r*z,g+=r*K,y+=r*H,v+=r*V,b+=r*$,_+=r*W,w+=r*G,k+=r*Y,E+=r*Z,S+=r*J,r=t[5],c+=r*D,h+=r*M,f+=r*F,p+=r*L,d+=r*U,m+=r*q,g+=r*z,y+=r*K,v+=r*H,b+=r*V,_+=r*$,w+=r*W,k+=r*G,E+=r*Y,S+=r*Z,x+=r*J,r=t[6],h+=r*D,f+=r*M,p+=r*F,d+=r*L,m+=r*U,g+=r*q,y+=r*z,v+=r*K,b+=r*H,_+=r*V,w+=r*$,k+=r*W,E+=r*G,S+=r*Y,x+=r*Z,C+=r*J,r=t[7],f+=r*D,p+=r*M,d+=r*F,m+=r*L,g+=r*U,y+=r*q,v+=r*z,b+=r*K,_+=r*H,w+=r*V,k+=r*$,E+=r*W,S+=r*G,x+=r*Y,C+=r*Z,A+=r*J,r=t[8],p+=r*D,d+=r*M,m+=r*F,g+=r*L,y+=r*U,v+=r*q,b+=r*z,_+=r*K,w+=r*H,k+=r*V,E+=r*$,S+=r*W,x+=r*G,C+=r*Y,A+=r*Z,T+=r*J,r=t[9],d+=r*D,m+=r*M,g+=r*F,y+=r*L,v+=r*U,b+=r*q,_+=r*z,w+=r*K,k+=r*H,E+=r*V,S+=r*$,x+=r*W,C+=r*G,A+=r*Y,T+=r*Z,I+=r*J,r=t[10],m+=r*D,g+=r*M,y+=r*F,v+=r*L,b+=r*U,_+=r*q,w+=r*z,k+=r*K,E+=r*H,S+=r*V,x+=r*$,C+=r*W,A+=r*G,T+=r*Y,I+=r*Z,j+=r*J,r=t[11],g+=r*D,y+=r*M,v+=r*F,b+=r*L,_+=r*U,w+=r*q,k+=r*z,E+=r*K,S+=r*H,x+=r*V,C+=r*$,A+=r*W,T+=r*G,I+=r*Y,j+=r*Z,R+=r*J,r=t[12],y+=r*D,v+=r*M,b+=r*F,_+=r*L,w+=r*U,k+=r*q,E+=r*z,S+=r*K,x+=r*H,C+=r*V,A+=r*$,T+=r*W,I+=r*G,j+=r*Y,R+=r*Z,B+=r*J,r=t[13],v+=r*D,b+=r*M,_+=r*F,w+=r*L,k+=r*U,E+=r*q,S+=r*z,x+=r*K,C+=r*H,A+=r*V,T+=r*$,I+=r*W,j+=r*G,R+=r*Y,B+=r*Z,O+=r*J,r=t[14],b+=r*D,_+=r*M,w+=r*F,k+=r*L,E+=r*U,S+=r*q,x+=r*z,C+=r*K,A+=r*H,T+=r*V,I+=r*$,j+=r*W,R+=r*G,B+=r*Y,O+=r*Z,P+=r*J,r=t[15],_+=r*D,w+=r*M,k+=r*F,E+=r*L,S+=r*U,x+=r*q,C+=r*z,A+=r*K,T+=r*H,I+=r*V,j+=r*$,R+=r*W,B+=r*G,O+=r*Y,P+=r*Z,N+=r*J,o+=38*w,s+=38*k,a+=38*E,l+=38*S,u+=38*x,c+=38*C,h+=38*A,f+=38*T,p+=38*I,d+=38*j,m+=38*R,g+=38*B,y+=38*O,v+=38*P,b+=38*N,i=1,r=o+i+65535,i=Math.floor(r/65536),o=r-65536*i,r=s+i+65535,i=Math.floor(r/65536),s=r-65536*i,r=a+i+65535,i=Math.floor(r/65536),a=r-65536*i,r=l+i+65535,i=Math.floor(r/65536),l=r-65536*i,r=u+i+65535,i=Math.floor(r/65536),u=r-65536*i,r=c+i+65535,i=Math.floor(r/65536),c=r-65536*i,r=h+i+65535,i=Math.floor(r/65536),h=r-65536*i,r=f+i+65535,i=Math.floor(r/65536),f=r-65536*i,r=p+i+65535,i=Math.floor(r/65536),p=r-65536*i,r=d+i+65535,i=Math.floor(r/65536),d=r-65536*i,r=m+i+65535,i=Math.floor(r/65536),m=r-65536*i,r=g+i+65535,i=Math.floor(r/65536),g=r-65536*i,r=y+i+65535,i=Math.floor(r/65536),y=r-65536*i,r=v+i+65535,i=Math.floor(r/65536),v=r-65536*i,r=b+i+65535,i=Math.floor(r/65536),b=r-65536*i,r=_+i+65535,i=Math.floor(r/65536),_=r-65536*i,o+=i-1+37*(i-1),i=1,r=o+i+65535,i=Math.floor(r/65536),o=r-65536*i,r=s+i+65535,i=Math.floor(r/65536),s=r-65536*i,r=a+i+65535,i=Math.floor(r/65536),a=r-65536*i,r=l+i+65535,i=Math.floor(r/65536),l=r-65536*i,r=u+i+65535,i=Math.floor(r/65536),u=r-65536*i,r=c+i+65535,i=Math.floor(r/65536),c=r-65536*i,r=h+i+65535,i=Math.floor(r/65536),h=r-65536*i,r=f+i+65535,i=Math.floor(r/65536),f=r-65536*i,r=p+i+65535,i=Math.floor(r/65536),p=r-65536*i,r=d+i+65535,i=Math.floor(r/65536),d=r-65536*i,r=m+i+65535,i=Math.floor(r/65536),m=r-65536*i,r=g+i+65535,i=Math.floor(r/65536),g=r-65536*i,r=y+i+65535,i=Math.floor(r/65536),y=r-65536*i,r=v+i+65535,i=Math.floor(r/65536),v=r-65536*i,r=b+i+65535,i=Math.floor(r/65536),b=r-65536*i,r=_+i+65535,i=Math.floor(r/65536),_=r-65536*i,o+=i-1+37*(i-1),e[0]=o,e[1]=s,e[2]=a,e[3]=l,e[4]=u,e[5]=c,e[6]=h,e[7]=f,e[8]=p,e[9]=d,e[10]=m,e[11]=g,e[12]=y,e[13]=v,e[14]=b,e[15]=_}function z(e,t){q(e,t,t)}function K(e,n){var r=t(),i;for(i=0;i<16;i++)r[i]=n[i];for(i=253;i>=0;i--)z(r,r),2!==i&&4!==i&&q(r,r,n);for(i=0;i<16;i++)e[i]=r[i]}function H(e,n){var r=t(),i;for(i=0;i<16;i++)r[i]=n[i];for(i=250;i>=0;i--)z(r,r),1!==i&&q(r,r,n);for(i=0;i<16;i++)e[i]=r[i]}function V(e,n,r){var i=new Uint8Array(32),o=new Float64Array(80),s,a,u=t(),c=t(),h=t(),f=t(),p=t(),d=t();for(a=0;a<31;a++)i[a]=n[a];for(i[31]=127&n[31]|64,i[0]&=248,F(o,r),a=0;a<16;a++)c[a]=o[a],f[a]=u[a]=h[a]=0;for(u[0]=f[0]=1,a=254;a>=0;--a)s=i[a>>>3]>>>(7&a)&1,P(u,c,s),P(h,f,s),L(p,u,h),U(u,u,h),L(h,c,f),U(c,c,f),z(f,p),z(d,u),q(u,h,u),q(h,c,p),L(p,u,h),U(u,u,h),z(c,u),U(h,f,d),q(u,h,l),L(u,u,f),q(h,h,u),q(u,f,d),q(f,c,o),z(c,p),P(u,c,s),P(h,f,s);for(a=0;a<16;a++)o[a+16]=u[a],o[a+32]=h[a],o[a+48]=c[a],o[a+64]=f[a];var m=o.subarray(32),g=o.subarray(16);return K(m,m),q(g,g,m),N(e,g),0}function $(e,t){return V(e,t,o)}function W(e,t){return r(t,32),$(e,t)}function G(e,t,n){var r=new Uint8Array(32);return V(r,n,t),w(e,i,r,k)}A.prototype.blocks=function(e,t,n){for(var r=this.fin?0:2048,i,o,s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E=this.h[0],S=this.h[1],x=this.h[2],C=this.h[3],A=this.h[4],T=this.h[5],I=this.h[6],j=this.h[7],R=this.h[8],B=this.h[9],O=this.r[0],P=this.r[1],N=this.r[2],D=this.r[3],M=this.r[4],F=this.r[5],L=this.r[6],U=this.r[7],q=this.r[8],z=this.r[9];n>=16;)i=255&e[t+0]|(255&e[t+1])<<8,E+=8191&i,o=255&e[t+2]|(255&e[t+3])<<8,S+=8191&(i>>>13|o<<3),s=255&e[t+4]|(255&e[t+5])<<8,x+=8191&(o>>>10|s<<6),a=255&e[t+6]|(255&e[t+7])<<8,C+=8191&(s>>>7|a<<9),l=255&e[t+8]|(255&e[t+9])<<8,A+=8191&(a>>>4|l<<12),T+=l>>>1&8191,u=255&e[t+10]|(255&e[t+11])<<8,I+=8191&(l>>>14|u<<2),c=255&e[t+12]|(255&e[t+13])<<8,j+=8191&(u>>>11|c<<5),h=255&e[t+14]|(255&e[t+15])<<8,R+=8191&(c>>>8|h<<8),B+=h>>>5|r,f=0,p=f,p+=E*O,p+=S*(5*z),p+=x*(5*q),p+=C*(5*U),p+=A*(5*L),f=p>>>13,p&=8191,p+=T*(5*F),p+=I*(5*M),p+=j*(5*D),p+=R*(5*N),p+=B*(5*P),f+=p>>>13,p&=8191,d=f,d+=E*P,d+=S*O,d+=x*(5*z),d+=C*(5*q),d+=A*(5*U),f=d>>>13,d&=8191,d+=T*(5*L),d+=I*(5*F),d+=j*(5*M),d+=R*(5*D),d+=B*(5*N),f+=d>>>13,d&=8191,m=f,m+=E*N,m+=S*P,m+=x*O,m+=C*(5*z),m+=A*(5*q),f=m>>>13,m&=8191,m+=T*(5*U),m+=I*(5*L),m+=j*(5*F),m+=R*(5*M),m+=B*(5*D),f+=m>>>13,m&=8191,g=f,g+=E*D,g+=S*N,g+=x*P,g+=C*O,g+=A*(5*z),f=g>>>13,g&=8191,g+=T*(5*q),g+=I*(5*U),g+=j*(5*L),g+=R*(5*F),g+=B*(5*M),f+=g>>>13,g&=8191,y=f,y+=E*M,y+=S*D,y+=x*N,y+=C*P,y+=A*O,f=y>>>13,y&=8191,y+=T*(5*z),y+=I*(5*q),y+=j*(5*U),y+=R*(5*L),y+=B*(5*F),f+=y>>>13,y&=8191,v=f,v+=E*F,v+=S*M,v+=x*D,v+=C*N,v+=A*P,f=v>>>13,v&=8191,v+=T*O,v+=I*(5*z),v+=j*(5*q),v+=R*(5*U),v+=B*(5*L),f+=v>>>13,v&=8191,b=f,b+=E*L,b+=S*F,b+=x*M,b+=C*D,b+=A*N,f=b>>>13,b&=8191,b+=T*P,b+=I*O,b+=j*(5*z),b+=R*(5*q),b+=B*(5*U),f+=b>>>13,b&=8191,_=f,_+=E*U,_+=S*L,_+=x*F,_+=C*M,_+=A*D,f=_>>>13,_&=8191,_+=T*N,_+=I*P,_+=j*O,_+=R*(5*z),_+=B*(5*q),f+=_>>>13,_&=8191,w=f,w+=E*q,w+=S*U,w+=x*L,w+=C*F,w+=A*M,f=w>>>13,w&=8191,w+=T*D,w+=I*N,w+=j*P,w+=R*O,w+=B*(5*z),f+=w>>>13,w&=8191,k=f,k+=E*z,k+=S*q,k+=x*U,k+=C*L,k+=A*F,f=k>>>13,k&=8191,k+=T*M,k+=I*D,k+=j*N,k+=R*P,k+=B*O,f+=k>>>13,k&=8191,f=(f<<2)+f|0,f=f+p|0,p=8191&f,f>>>=13,d+=f,E=p,S=d,x=m,C=g,A=y,T=v,I=b,j=_,R=w,B=k,t+=16,n-=16;this.h[0]=E,this.h[1]=S,this.h[2]=x,this.h[3]=C,this.h[4]=A,this.h[5]=T,this.h[6]=I,this.h[7]=j,this.h[8]=R,this.h[9]=B},A.prototype.finish=function(e,t){var n=new Uint16Array(10),r,i,o,s;if(this.leftover){for(s=this.leftover,this.buffer[s++]=1;s<16;s++)this.buffer[s]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(r=this.h[1]>>>13,this.h[1]&=8191,s=2;s<10;s++)this.h[s]+=r,r=this.h[s]>>>13,this.h[s]&=8191;for(this.h[0]+=5*r,r=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=r,r=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=r,n[0]=this.h[0]+5,r=n[0]>>>13,n[0]&=8191,s=1;s<10;s++)n[s]=this.h[s]+r,r=n[s]>>>13,n[s]&=8191;for(n[9]-=8192,i=(1^r)-1,s=0;s<10;s++)n[s]&=i;for(i=~i,s=0;s<10;s++)this.h[s]=this.h[s]&i|n[s];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),o=this.h[0]+this.pad[0],this.h[0]=65535&o,s=1;s<8;s++)o=(this.h[s]+this.pad[s]|0)+(o>>>16)|0,this.h[s]=65535&o;e[t+0]=this.h[0]>>>0&255,e[t+1]=this.h[0]>>>8&255,e[t+2]=this.h[1]>>>0&255,e[t+3]=this.h[1]>>>8&255,e[t+4]=this.h[2]>>>0&255,e[t+5]=this.h[2]>>>8&255,e[t+6]=this.h[3]>>>0&255,e[t+7]=this.h[3]>>>8&255,e[t+8]=this.h[4]>>>0&255,e[t+9]=this.h[4]>>>8&255,e[t+10]=this.h[5]>>>0&255,e[t+11]=this.h[5]>>>8&255,e[t+12]=this.h[6]>>>0&255,e[t+13]=this.h[6]>>>8&255,e[t+14]=this.h[7]>>>0&255,e[t+15]=this.h[7]>>>8&255},A.prototype.update=function(e,t,n){var r,i;if(this.leftover){for(i=16-this.leftover,i>n&&(i=n),r=0;r<i;r++)this.buffer[this.leftover+r]=e[t+r];if(n-=i,t+=i,this.leftover+=i,this.leftover<16)return;this.blocks(this.buffer,0,16),this.leftover=0}if(n>=16&&(i=n-n%16,this.blocks(e,t,i),t+=i,n-=i),n){for(r=0;r<n;r++)this.buffer[this.leftover+r]=e[t+r];this.leftover+=n}};var Y=j,Z=R;function J(e,t,n,r,i,o){var s=new Uint8Array(32);return G(s,i,o),Y(e,t,n,r,s)}function Q(e,t,n,r,i,o){var s=new Uint8Array(32);return G(s,i,o),Z(e,t,n,r,s)}var X=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function ee(e,t,n,r){for(var i=new Int32Array(16),o=new Int32Array(16),s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E,S,x,C,A,T,I,j,R,B=e[0],O=e[1],P=e[2],N=e[3],D=e[4],M=e[5],F=e[6],L=e[7],U=t[0],q=t[1],z=t[2],K=t[3],H=t[4],V=t[5],$=t[6],W=t[7],G=0;r>=128;){for(S=0;S<16;S++)x=8*S+G,i[S]=n[x+0]<<24|n[x+1]<<16|n[x+2]<<8|n[x+3],o[S]=n[x+4]<<24|n[x+5]<<16|n[x+6]<<8|n[x+7];for(S=0;S<80;S++)if(s=B,a=O,l=P,u=N,c=D,h=M,f=F,p=L,d=U,m=q,g=z,y=K,v=H,b=V,_=$,w=W,C=L,A=W,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=(D>>>14|H<<18)^(D>>>18|H<<14)^(H>>>9|D<<23),A=(H>>>14|D<<18)^(H>>>18|D<<14)^(D>>>9|H<<23),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=D&M^~D&F,A=H&V^~H&$,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=X[2*S],A=X[2*S+1],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=i[S%16],A=o[S%16],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,k=65535&j|R<<16,E=65535&T|I<<16,C=k,A=E,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=(B>>>28|U<<4)^(U>>>2|B<<30)^(U>>>7|B<<25),A=(U>>>28|B<<4)^(B>>>2|U<<30)^(B>>>7|U<<25),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,C=B&O^B&P^O&P,A=U&q^U&z^q&z,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,p=65535&j|R<<16,w=65535&T|I<<16,C=u,A=y,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=k,A=E,T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,u=65535&j|R<<16,y=65535&T|I<<16,O=s,P=a,N=l,D=u,M=c,F=h,L=f,B=p,q=d,z=m,K=g,H=y,V=v,$=b,W=_,U=w,S%16==15)for(x=0;x<16;x++)C=i[x],A=o[x],T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=i[(x+9)%16],A=o[(x+9)%16],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,k=i[(x+1)%16],E=o[(x+1)%16],C=(k>>>1|E<<31)^(k>>>8|E<<24)^k>>>7,A=(E>>>1|k<<31)^(E>>>8|k<<24)^(E>>>7|k<<25),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,k=i[(x+14)%16],E=o[(x+14)%16],C=(k>>>19|E<<13)^(E>>>29|k<<3)^k>>>6,A=(E>>>19|k<<13)^(k>>>29|E<<3)^(E>>>6|k<<26),T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,i[x]=65535&j|R<<16,o[x]=65535&T|I<<16;C=B,A=U,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[0],A=t[0],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[0]=B=65535&j|R<<16,t[0]=U=65535&T|I<<16,C=O,A=q,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[1],A=t[1],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[1]=O=65535&j|R<<16,t[1]=q=65535&T|I<<16,C=P,A=z,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[2],A=t[2],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[2]=P=65535&j|R<<16,t[2]=z=65535&T|I<<16,C=N,A=K,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[3],A=t[3],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[3]=N=65535&j|R<<16,t[3]=K=65535&T|I<<16,C=D,A=H,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[4],A=t[4],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[4]=D=65535&j|R<<16,t[4]=H=65535&T|I<<16,C=M,A=V,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[5],A=t[5],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[5]=M=65535&j|R<<16,t[5]=V=65535&T|I<<16,C=F,A=$,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[6],A=t[6],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[6]=F=65535&j|R<<16,t[6]=$=65535&T|I<<16,C=L,A=W,T=65535&A,I=A>>>16,j=65535&C,R=C>>>16,C=e[7],A=t[7],T+=65535&A,I+=A>>>16,j+=65535&C,R+=C>>>16,I+=T>>>16,j+=I>>>16,R+=j>>>16,e[7]=L=65535&j|R<<16,t[7]=W=65535&T|I<<16,G+=128,r-=128}return r}function te(e,t,n){var r=new Int32Array(8),i=new Int32Array(8),o=new Uint8Array(256),s,a=n;for(r[0]=1779033703,r[1]=3144134277,r[2]=1013904242,r[3]=2773480762,r[4]=1359893119,r[5]=2600822924,r[6]=528734635,r[7]=1541459225,i[0]=4089235720,i[1]=2227873595,i[2]=4271175723,i[3]=1595750129,i[4]=2917565137,i[5]=725511199,i[6]=4215389547,i[7]=327033209,ee(r,i,t,n),n%=128,s=0;s<n;s++)o[s]=t[a-n+s];for(o[n]=128,n=256-128*(n<112?1:0),o[n-9]=0,d(o,n-8,a/536870912|0,a<<3),ee(r,i,o,n),s=0;s<8;s++)d(e,8*s,r[s],i[s]);return 0}function ne(e,n){var r=t(),i=t(),o=t(),s=t(),a=t(),l=t(),u=t(),h=t(),f=t();U(r,e[1],e[0]),U(f,n[1],n[0]),q(r,r,f),L(i,e[0],e[1]),L(f,n[0],n[1]),q(i,i,f),q(o,e[3],n[3]),q(o,o,c),q(s,e[2],n[2]),L(s,s,s),U(a,i,r),U(l,s,o),L(u,s,o),L(h,i,r),q(e[0],a,l),q(e[1],h,u),q(e[2],u,l),q(e[3],a,h)}function re(e,t,n){var r;for(r=0;r<4;r++)P(e[r],t[r],n)}function ie(e,n){var r=t(),i=t(),o=t();K(o,n[2]),q(r,n[0],o),q(i,n[1],o),N(e,i),e[31]^=M(r)<<7}function oe(e,t,n){var r,i;for(B(e[0],s),B(e[1],a),B(e[2],a),B(e[3],s),i=255;i>=0;--i)r=n[i/8|0]>>(7&i)&1,re(e,t,r),ne(t,e),ne(e,e),re(e,t,r)}function se(e,n){var r=[t(),t(),t(),t()];B(r[0],h),B(r[1],f),B(r[2],a),q(r[3],h,f),oe(e,r,n)}function ae(e,n,i){var o=new Uint8Array(64),s=[t(),t(),t(),t()],a;for(i||r(n,32),te(o,n,32),o[0]&=248,o[31]&=127,o[31]|=64,se(s,o),ie(e,s),a=0;a<32;a++)n[a+32]=e[a];return 0}var le=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function ue(e,t){var n,r,i,o;for(r=63;r>=32;--r){for(n=0,i=r-32,o=r-12;i<o;++i)t[i]+=n-16*t[r]*le[i-(r-32)],n=t[i]+128>>8,t[i]-=256*n;t[i]+=n,t[r]=0}for(n=0,i=0;i<32;i++)t[i]+=n-(t[31]>>4)*le[i],n=t[i]>>8,t[i]&=255;for(i=0;i<32;i++)t[i]-=n*le[i];for(r=0;r<32;r++)t[r+1]+=t[r]>>8,e[r]=255&t[r]}function ce(e){var t=new Float64Array(64),n;for(n=0;n<64;n++)t[n]=e[n];for(n=0;n<64;n++)e[n]=0;ue(e,t)}function he(e,n,r,i){var o=new Uint8Array(64),s=new Uint8Array(64),a=new Uint8Array(64),l,u,c=new Float64Array(64),h=[t(),t(),t(),t()];te(o,i,32),o[0]&=248,o[31]&=127,o[31]|=64;var f=r+64;for(l=0;l<r;l++)e[64+l]=n[l];for(l=0;l<32;l++)e[32+l]=o[32+l];for(te(a,e.subarray(32),r+32),ce(a),se(h,a),ie(e,h),l=32;l<64;l++)e[l]=i[l];for(te(s,e,r+64),ce(s),l=0;l<64;l++)c[l]=0;for(l=0;l<32;l++)c[l]=a[l];for(l=0;l<32;l++)for(u=0;u<32;u++)c[l+u]+=s[l]*o[u];return ue(e.subarray(32),c),f}function fe(e,n){var r=t(),i=t(),o=t(),l=t(),c=t(),h=t(),f=t();return B(e[2],a),F(e[1],n),z(o,e[1]),q(l,o,u),U(o,o,e[2]),L(l,e[2],l),z(c,l),z(h,c),q(f,h,c),q(r,f,o),q(r,r,l),H(r,r),q(r,r,o),q(r,r,l),q(r,r,l),q(e[0],r,l),z(i,e[0]),q(i,i,l),D(i,o)&&q(e[0],e[0],p),z(i,e[0]),q(i,i,l),D(i,o)?-1:(M(e[0])===n[31]>>7&&U(e[0],s,e[0]),q(e[3],e[0],e[1]),0)}function pe(e,n,r,i){var o,s,a=new Uint8Array(32),l=new Uint8Array(64),u=[t(),t(),t(),t()],c=[t(),t(),t(),t()];if(s=-1,r<64)return-1;if(fe(c,i))return-1;for(o=0;o<r;o++)e[o]=n[o];for(o=0;o<32;o++)e[o+32]=i[o];if(te(l,e,r),ce(l),oe(u,c,l),se(c,n.subarray(32)),ne(u,c),ie(a,u),r-=64,y(n,0,a,0)){for(o=0;o<r;o++)e[o]=0;return-1}for(o=0;o<r;o++)e[o]=n[o+64];return s=r,s}var de=32,me=24,ge=32,ye=16,ve=32,be=32,_e=32,we=32,ke=32,Ee=me,Se=32,xe=16,Ce=64,Ae=32,Te=64,Ie=32,je=64;function Re(e,t){if(e.length!==de)throw new Error("bad key size");if(t.length!==me)throw new Error("bad nonce size")}function Be(e,t){if(e.length!==_e)throw new Error("bad public key size");if(t.length!==we)throw new Error("bad secret key size")}function Oe(){for(var e=0;e<arguments.length;e++)if(!(arguments[e]instanceof Uint8Array))throw new TypeError("unexpected type, use Uint8Array")}function Pe(e){for(var t=0;t<e.length;t++)e[t]=0}e.lowlevel={crypto_core_hsalsa20:w,crypto_stream_xor:C,crypto_stream:x,crypto_stream_salsa20_xor:E,crypto_stream_salsa20:S,crypto_onetimeauth:T,crypto_onetimeauth_verify:I,crypto_verify_16:g,crypto_verify_32:y,crypto_secretbox:j,crypto_secretbox_open:R,crypto_scalarmult:V,crypto_scalarmult_base:$,crypto_box_beforenm:G,crypto_box_afternm:Y,crypto_box:J,crypto_box_open:Q,crypto_box_keypair:W,crypto_hash:te,crypto_sign:he,crypto_sign_keypair:ae,crypto_sign_open:pe,crypto_secretbox_KEYBYTES:de,crypto_secretbox_NONCEBYTES:me,crypto_secretbox_ZEROBYTES:32,crypto_secretbox_BOXZEROBYTES:16,crypto_scalarmult_BYTES:32,crypto_scalarmult_SCALARBYTES:32,crypto_box_PUBLICKEYBYTES:_e,crypto_box_SECRETKEYBYTES:we,crypto_box_BEFORENMBYTES:32,crypto_box_NONCEBYTES:Ee,crypto_box_ZEROBYTES:32,crypto_box_BOXZEROBYTES:16,crypto_sign_BYTES:64,crypto_sign_PUBLICKEYBYTES:32,crypto_sign_SECRETKEYBYTES:64,crypto_sign_SEEDBYTES:32,crypto_hash_BYTES:64},e.randomBytes=function(e){var t=new Uint8Array(e);return r(t,e),t},e.secretbox=function(e,t,n){Oe(e,t,n),Re(n,t);for(var r=new Uint8Array(32+e.length),i=new Uint8Array(r.length),o=0;o<e.length;o++)r[o+32]=e[o];return j(i,r,r.length,t,n),i.subarray(16)},e.secretbox.open=function(e,t,n){Oe(e,t,n),Re(n,t);for(var r=new Uint8Array(16+e.length),i=new Uint8Array(r.length),o=0;o<e.length;o++)r[o+16]=e[o];return r.length<32?null:0!==R(i,r,r.length,t,n)?null:i.subarray(32)},e.secretbox.keyLength=de,e.secretbox.nonceLength=me,e.secretbox.overheadLength=16,e.scalarMult=function(e,t){if(Oe(e,t),32!==e.length)throw new Error("bad n size");if(32!==t.length)throw new Error("bad p size");var n=new Uint8Array(32);return V(n,e,t),n},e.scalarMult.base=function(e){if(Oe(e),32!==e.length)throw new Error("bad n size");var t=new Uint8Array(32);return $(t,e),t},e.scalarMult.scalarLength=32,e.scalarMult.groupElementLength=32,e.box=function(t,n,r,i){var o=e.box.before(r,i);return e.secretbox(t,n,o)},e.box.before=function(e,t){Oe(e,t),Be(e,t);var n=new Uint8Array(32);return G(n,e,t),n},e.box.after=e.secretbox,e.box.open=function(t,n,r,i){var o=e.box.before(r,i);return e.secretbox.open(t,n,o)},e.box.open.after=e.secretbox.open,e.box.keyPair=function(){var e=new Uint8Array(_e),t=new Uint8Array(we);return W(e,t),{publicKey:e,secretKey:t}},e.box.keyPair.fromSecretKey=function(e){if(Oe(e),e.length!==we)throw new Error("bad secret key size");var t=new Uint8Array(_e);return $(t,e),{publicKey:t,secretKey:new Uint8Array(e)}},e.box.publicKeyLength=_e,e.box.secretKeyLength=we,e.box.sharedKeyLength=32,e.box.nonceLength=Ee,e.box.overheadLength=e.secretbox.overheadLength,e.sign=function(e,t){if(Oe(e,t),64!==t.length)throw new Error("bad secret key size");var n=new Uint8Array(64+e.length);return he(n,e,e.length,t),n},e.sign.open=function(e,t){if(Oe(e,t),32!==t.length)throw new Error("bad public key size");var n=new Uint8Array(e.length),r=pe(n,e,e.length,t);if(r<0)return null;for(var i=new Uint8Array(r),o=0;o<i.length;o++)i[o]=n[o];return i},e.sign.detached=function(t,n){for(var r=e.sign(t,n),i=new Uint8Array(64),o=0;o<i.length;o++)i[o]=r[o];return i},e.sign.detached.verify=function(e,t,n){if(Oe(e,t,n),64!==t.length)throw new Error("bad signature size");if(32!==n.length)throw new Error("bad public key size");var r=new Uint8Array(64+e.length),i=new Uint8Array(64+e.length),o;for(o=0;o<64;o++)r[o]=t[o];for(o=0;o<e.length;o++)r[o+64]=e[o];return pe(i,r,r.length,n)>=0},e.sign.keyPair=function(){var e=new Uint8Array(32),t=new Uint8Array(64);return ae(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(Oe(e),64!==e.length)throw new Error("bad secret key size");for(var t=new Uint8Array(32),n=0;n<t.length;n++)t[n]=e[32+n];return{publicKey:t,secretKey:new Uint8Array(e)}},e.sign.keyPair.fromSeed=function(e){if(Oe(e),32!==e.length)throw new Error("bad seed size");for(var t=new Uint8Array(32),n=new Uint8Array(64),r=0;r<32;r++)n[r]=e[r];return ae(t,n,!0),{publicKey:t,secretKey:n}},e.sign.publicKeyLength=32,e.sign.secretKeyLength=64,e.sign.seedLength=32,e.sign.signatureLength=64,e.hash=function(e){Oe(e);var t=new Uint8Array(64);return te(t,e,e.length),t},e.hash.hashLength=64,e.verify=function(e,t){return Oe(e,t),0!==e.length&&0!==t.length&&(e.length===t.length&&0===m(e,0,t,0,e.length))},e.setPRNG=function(e){r=e},function(){var t="undefined"!=typeof self?self.crypto||self.msCrypto:null;if(t&&t.getRandomValues){var r=65536;e.setPRNG(function(e,n){var r,i=new Uint8Array(n);for(r=0;r<n;r+=65536)t.getRandomValues(i.subarray(r,r+Math.min(n-r,65536)));for(r=0;r<n;r++)e[r]=i[r];Pe(i)})}else t=n(772),t&&t.randomBytes&&e.setPRNG(function(e,n){var r,i=t.randomBytes(n);for(r=0;r<n;r++)e[r]=i[r];Pe(i)})}()}(e.exports?e.exports:self.nacl=self.nacl||{})},function(e,t){},function(e,t,n){"use strict";const r=n(70),i=n(56);e.exports=((e,t,o)=>{o=o||n(774)(t);class s{constructor(e){o.validatePublicKey(e),this._key=e}verify(e,t,n){h(n),o.hashAndVerify(this._key,t,e,n)}marshal(){return o.compressPublicKey(this._key)}get bytes(){return e.PublicKey.encode({Type:e.KeyType.Secp256k1,Data:this.marshal()})}equals(e){return this.bytes.equals(e.bytes)}hash(e){h(e),i(this.bytes,"sha2-256",e)}}class a{constructor(e,t){this._key=e,this._publicKey=t||o.computePublicKey(e),o.validatePrivateKey(this._key),o.validatePublicKey(this._publicKey)}sign(e,t){h(t),o.hashAndSign(this._key,e,t)}get public(){return new s(this._publicKey)}marshal(){return this._key}get bytes(){return e.PrivateKey.encode({Type:e.KeyType.Secp256k1,Data:this.marshal()})}equals(e){return this.bytes.equals(e.bytes)}hash(e){h(e),i(this.bytes,"sha2-256",e)}id(e){this.public.hash((t,n)=>{if(t)return e(t);e(null,r.encode(n))})}}function l(e,t){t(null,new a(e),null)}function u(e){return new s(e)}function c(e,t){void 0===t&&"function"==typeof e&&(t=e),h(t),o.generateKey((e,n)=>{if(e)return t(e);let r;try{r=new a(n)}catch(e){return t(e)}t(null,r)})}function h(e){if("function"!=typeof e)throw new Error("callback is required")}return{Secp256k1PublicKey:s,Secp256k1PrivateKey:a,unmarshalSecp256k1PrivateKey:l,unmarshalSecp256k1PublicKey:u,generateKeyPair:c}})},function(e,t,n){"use strict";const r=n(775),i=n(56),o=n(20),s="sha2-256";e.exports=(e=>{const t=32;function n(t){const n=(e,n)=>o(()=>t(e,n));let i;do{i=e(32)}while(!r.privateKeyVerify(i));n(null,i)}function a(e,t,n){const a=(e,t)=>o(()=>n(e,t));i.digest(t,s,(t,n)=>{if(t)return a(t);try{const i=r.sign(n,e),o=r.signatureExport(i.signature);return a(null,o)}catch(t){a(t)}})}function l(e,t,n,a){const l=(e,t)=>o(()=>a(e,t));i.digest(n,s,(n,i)=>{if(n)return l(n);try{t=r.signatureImport(t);const o=r.verify(i,t,e);return l(null,o)}catch(n){l(n)}})}function u(e){if(!r.publicKeyVerify(e))throw new Error("Invalid public key");return r.publicKeyConvert(e,!0)}function c(e){return r.publicKeyConvert(e,!1)}function h(e){if(!r.privateKeyVerify(e))throw new Error("Invalid private key")}function f(e){if(!r.publicKeyVerify(e))throw new Error("Invalid public key")}function p(e){return h(e),r.publicKeyCreate(e)}return{generateKey:n,privateKeyLength:32,hashAndSign:a,hashAndVerify:l,compressPublicKey:u,decompressPublicKey:c,validatePrivateKey:h,validatePublicKey:f,computePublicKey:p}})},function(e,t,n){"use strict";e.exports=n(776)(n(780))},function(e,t,n){"use strict";var r=n(777),i=n(778),o=n(379);function s(e,t){return void 0===e?t:(r.isBoolean(e,o.COMPRESSED_TYPE_INVALID),e)}e.exports=function(e){return{privateKeyVerify:function(t){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),32===t.length&&e.privateKeyVerify(t)},privateKeyExport:function(t,n){r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),n=s(n,!0);var a=e.privateKeyExport(t,n);return i.privateKeyExport(t,a,n)},privateKeyImport:function(t){if(r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),t=i.privateKeyImport(t),t&&32===t.length&&e.privateKeyVerify(t))return t;throw new Error(o.EC_PRIVATE_KEY_IMPORT_DER_FAIL)},privateKeyNegate:function(t){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),e.privateKeyNegate(t)},privateKeyModInverse:function(t){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),e.privateKeyModInverse(t)},privateKeyTweakAdd:function(t,n){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),r.isBuffer(n,o.TWEAK_TYPE_INVALID),r.isBufferLength(n,32,o.TWEAK_LENGTH_INVALID),e.privateKeyTweakAdd(t,n)},privateKeyTweakMul:function(t,n){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),r.isBuffer(n,o.TWEAK_TYPE_INVALID),r.isBufferLength(n,32,o.TWEAK_LENGTH_INVALID),e.privateKeyTweakMul(t,n)},publicKeyCreate:function(t,n){return r.isBuffer(t,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(t,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),n=s(n,!0),e.publicKeyCreate(t,n)},publicKeyConvert:function(t,n){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),n=s(n,!0),e.publicKeyConvert(t,n)},publicKeyVerify:function(t){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),e.publicKeyVerify(t)},publicKeyTweakAdd:function(t,n,i){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),r.isBuffer(n,o.TWEAK_TYPE_INVALID),r.isBufferLength(n,32,o.TWEAK_LENGTH_INVALID),i=s(i,!0),e.publicKeyTweakAdd(t,n,i)},publicKeyTweakMul:function(t,n,i){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),r.isBuffer(n,o.TWEAK_TYPE_INVALID),r.isBufferLength(n,32,o.TWEAK_LENGTH_INVALID),i=s(i,!0),e.publicKeyTweakMul(t,n,i)},publicKeyCombine:function(t,n){r.isArray(t,o.EC_PUBLIC_KEYS_TYPE_INVALID),r.isLengthGTZero(t,o.EC_PUBLIC_KEYS_LENGTH_INVALID);for(var i=0;i<t.length;++i)r.isBuffer(t[i],o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t[i],33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID);return n=s(n,!0),e.publicKeyCombine(t,n)},signatureNormalize:function(t){return r.isBuffer(t,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isBufferLength(t,64,o.ECDSA_SIGNATURE_LENGTH_INVALID),e.signatureNormalize(t)},signatureExport:function(t){r.isBuffer(t,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isBufferLength(t,64,o.ECDSA_SIGNATURE_LENGTH_INVALID);var n=e.signatureExport(t);return i.signatureExport(n)},signatureImport:function(t){r.isBuffer(t,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isLengthGTZero(t,o.ECDSA_SIGNATURE_LENGTH_INVALID);var n=i.signatureImport(t);if(n)return e.signatureImport(n);throw new Error(o.ECDSA_SIGNATURE_PARSE_DER_FAIL)},signatureImportLax:function(t){r.isBuffer(t,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isLengthGTZero(t,o.ECDSA_SIGNATURE_LENGTH_INVALID);var n=i.signatureImportLax(t);if(n)return e.signatureImport(n);throw new Error(o.ECDSA_SIGNATURE_PARSE_DER_FAIL)},sign:function(t,n,i){r.isBuffer(t,o.MSG32_TYPE_INVALID),r.isBufferLength(t,32,o.MSG32_LENGTH_INVALID),r.isBuffer(n,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(n,32,o.EC_PRIVATE_KEY_LENGTH_INVALID);var s=null,a=null;return void 0!==i&&(r.isObject(i,o.OPTIONS_TYPE_INVALID),void 0!==i.data&&(r.isBuffer(i.data,o.OPTIONS_DATA_TYPE_INVALID),r.isBufferLength(i.data,32,o.OPTIONS_DATA_LENGTH_INVALID),s=i.data),void 0!==i.noncefn&&(r.isFunction(i.noncefn,o.OPTIONS_NONCEFN_TYPE_INVALID),a=i.noncefn)),e.sign(t,n,a,s)},verify:function(t,n,i){return r.isBuffer(t,o.MSG32_TYPE_INVALID),r.isBufferLength(t,32,o.MSG32_LENGTH_INVALID),r.isBuffer(n,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isBufferLength(n,64,o.ECDSA_SIGNATURE_LENGTH_INVALID),r.isBuffer(i,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(i,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),e.verify(t,n,i)},recover:function(t,n,i,a){return r.isBuffer(t,o.MSG32_TYPE_INVALID),r.isBufferLength(t,32,o.MSG32_LENGTH_INVALID),r.isBuffer(n,o.ECDSA_SIGNATURE_TYPE_INVALID),r.isBufferLength(n,64,o.ECDSA_SIGNATURE_LENGTH_INVALID),r.isNumber(i,o.RECOVERY_ID_TYPE_INVALID),r.isNumberInInterval(i,-1,4,o.RECOVERY_ID_VALUE_INVALID),a=s(a,!0),e.recover(t,n,i,a)},ecdh:function(t,n){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),r.isBuffer(n,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(n,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),e.ecdh(t,n)},ecdhUnsafe:function(t,n,i){return r.isBuffer(t,o.EC_PUBLIC_KEY_TYPE_INVALID),r.isBufferLength2(t,33,65,o.EC_PUBLIC_KEY_LENGTH_INVALID),r.isBuffer(n,o.EC_PRIVATE_KEY_TYPE_INVALID),r.isBufferLength(n,32,o.EC_PRIVATE_KEY_LENGTH_INVALID),i=s(i,!0),e.ecdhUnsafe(t,n,i)}}}},function(e,t,n){"use strict";(function(e){var n=Object.prototype.toString;t.isArray=function(e,t){if(!Array.isArray(e))throw TypeError(t)},t.isBoolean=function(e,t){if("[object Boolean]"!==n.call(e))throw TypeError(t)},t.isBuffer=function(t,n){if(!e.isBuffer(t))throw TypeError(n)},t.isFunction=function(e,t){if("[object Function]"!==n.call(e))throw TypeError(t)},t.isNumber=function(e,t){if("[object Number]"!==n.call(e))throw TypeError(t)},t.isObject=function(e,t){if("[object Object]"!==n.call(e))throw TypeError(t)},t.isBufferLength=function(e,t,n){if(e.length!==t)throw RangeError(n)},t.isBufferLength2=function(e,t,n,r){if(e.length!==t&&e.length!==n)throw RangeError(r)},t.isLengthGTZero=function(e,t){if(0===e.length)throw RangeError(t)},t.isNumberInInterval=function(e,t,n,r){if(e<=t||e>=n)throw RangeError(r)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(779),o=r.from([48,129,211,2,1,1,4,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,129,133,48,129,130,2,1,1,48,44,6,7,42,134,72,206,61,1,1,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,255,252,47,48,6,4,1,0,4,1,7,4,33,2,121,190,102,126,249,220,187,172,85,160,98,149,206,135,11,7,2,155,252,219,45,206,40,217,89,242,129,91,22,248,23,152,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,186,174,220,230,175,72,160,59,191,210,94,140,208,54,65,65,2,1,1,161,36,3,34,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),s=r.from([48,130,1,19,2,1,1,4,32,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,160,129,165,48,129,162,2,1,1,48,44,6,7,42,134,72,206,61,1,1,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,255,255,252,47,48,6,4,1,0,4,1,7,4,65,4,121,190,102,126,249,220,187,172,85,160,98,149,206,135,11,7,2,155,252,219,45,206,40,217,89,242,129,91,22,248,23,152,72,58,218,119,38,163,196,101,93,164,251,252,14,17,8,168,253,23,180,72,166,133,84,25,156,71,208,143,251,16,212,184,2,33,0,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,254,186,174,220,230,175,72,160,59,191,210,94,140,208,54,65,65,2,1,1,161,68,3,66,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);t.privateKeyExport=function(e,t,n){var i=r.from(n?o:s);return e.copy(i,n?8:9),t.copy(i,n?181:214),i},t.privateKeyImport=function(e){var t=e.length,n=0;if(!(t<n+1||48!==e[n])&&(n+=1,!(t<n+1)&&128&e[n])){var r=127&e[n];if(n+=1,!(r<1||r>2||t<n+r)){var i=e[n+r-1]|(r>1?e[n+r-2]<<8:0);if(n+=r,!(t<n+i||t<n+3||2!==e[n]||1!==e[n+1]||1!==e[n+2]||(n+=3,t<n+2||4!==e[n]||e[n+1]>32||t<n+2+e[n+1])))return e.slice(n+2,n+2+e[n+1])}}},t.signatureExport=function(e){for(var t=r.concat([r.from([0]),e.r]),n=33,o=0;n>1&&0===t[o]&&!(128&t[o+1]);--n,++o);for(var s=r.concat([r.from([0]),e.s]),a=33,l=0;a>1&&0===s[l]&&!(128&s[l+1]);--a,++l);return i.encode(t.slice(o),s.slice(l))},t.signatureImport=function(e){var t=r.alloc(32,0),n=r.alloc(32,0);try{var o=i.decode(e);if(33===o.r.length&&0===o.r[0]&&(o.r=o.r.slice(1)),o.r.length>32)throw new Error("R length is too long");if(33===o.s.length&&0===o.s[0]&&(o.s=o.s.slice(1)),o.s.length>32)throw new Error("S length is too long")}catch(e){return}return o.r.copy(t,32-o.r.length),o.s.copy(n,32-o.s.length),{r:t,s:n}},t.signatureImportLax=function(e){var t=r.alloc(32,0),n=r.alloc(32,0),i=e.length,o=0;if(48===e[o++]){var s=e[o++];if(!(128&s&&(o+=s-128,o>i))&&2===e[o++]){var a=e[o++];if(128&a){if(s=a-128,o+s>i)return;for(;s>0&&0===e[o];o+=1,s-=1);for(a=0;s>0;o+=1,s-=1)a=(a<<8)+e[o]}if(!(a>i-o)){var l=o;if(o+=a,2===e[o++]){var u=e[o++];if(128&u){if(s=u-128,o+s>i)return;for(;s>0&&0===e[o];o+=1,s-=1);for(u=0;s>0;o+=1,s-=1)u=(u<<8)+e[o]}if(!(u>i-o)){var c=o;for(o+=u;a>0&&0===e[l];a-=1,l+=1);if(!(a>32)){var h=e.slice(l,l+a);for(h.copy(t,32-h.length);u>0&&0===e[c];u-=1,c+=1);if(!(u>32)){var f=e.slice(c,c+u);return f.copy(n,32-f.length),{r:t,s:n}}}}}}}}}},function(e,t,n){var r=n(5).Buffer;function i(e){if(e.length<8)return!1;if(e.length>72)return!1;if(48!==e[0])return!1;if(e[1]!==e.length-2)return!1;if(2!==e[2])return!1;var t=e[3];if(0===t)return!1;if(5+t>=e.length)return!1;if(2!==e[4+t])return!1;var n=e[5+t];return 0!==n&&(6+t+n===e.length&&(!(128&e[4])&&(!(t>1&&0===e[4]&&!(128&e[5]))&&(!(128&e[t+6])&&!(n>1&&0===e[t+6]&&!(128&e[t+7]))))))}function o(e){if(e.length<8)throw new Error("DER sequence length is too short");if(e.length>72)throw new Error("DER sequence length is too long");if(48!==e[0])throw new Error("Expected DER sequence");if(e[1]!==e.length-2)throw new Error("DER sequence length is invalid");if(2!==e[2])throw new Error("Expected DER integer");var t=e[3];if(0===t)throw new Error("R length is zero");if(5+t>=e.length)throw new Error("R length is too long");if(2!==e[4+t])throw new Error("Expected DER integer (2)");var n=e[5+t];if(0===n)throw new Error("S length is zero");if(6+t+n!==e.length)throw new Error("S length is invalid");if(128&e[4])throw new Error("R value is negative");if(t>1&&0===e[4]&&!(128&e[5]))throw new Error("R value excessively padded");if(128&e[t+6])throw new Error("S value is negative");if(n>1&&0===e[t+6]&&!(128&e[t+7]))throw new Error("S value excessively padded");return{r:e.slice(4,4+t),s:e.slice(6+t)}}function s(e,t){var n=e.length,i=t.length;if(0===n)throw new Error("R length is zero");if(0===i)throw new Error("S length is zero");if(n>33)throw new Error("R length is too long");if(i>33)throw new Error("S length is too long");if(128&e[0])throw new Error("R value is negative");if(128&t[0])throw new Error("S value is negative");if(n>1&&0===e[0]&&!(128&e[1]))throw new Error("R value excessively padded");if(i>1&&0===t[0]&&!(128&t[1]))throw new Error("S value excessively padded");var o=r.allocUnsafe(6+n+i);return o[0]=48,o[1]=o.length-2,o[2]=2,o[3]=e.length,e.copy(o,4),o[4+n]=2,o[5+n]=t.length,t.copy(o,6+n),o}e.exports={check:i,decode:o,encode:s}},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(781),o=n(794),s=n(379),a=n(197),l=n(389),u=n(800);t.privateKeyVerify=function(e){var t=a.fromBuffer(e);return!(t.isOverflow()||t.isZero())},t.privateKeyExport=function(e,t){var n=a.fromBuffer(e);if(n.isOverflow()||n.isZero())throw new Error(s.EC_PRIVATE_KEY_EXPORT_DER_FAIL);return u.mul(n).toPublicKey(t)},t.privateKeyNegate=function(e){var t=a.fromBuffer(e);return t.isZero()?r.alloc(32):(t.ucmp(a.n)>0&&t.isub(a.n),a.n.sub(t).toBuffer())},t.privateKeyModInverse=function(e){var t=a.fromBuffer(e);if(t.isOverflow()||t.isZero())throw new Error(s.EC_PRIVATE_KEY_RANGE_INVALID);return t.uinvm().toBuffer()},t.privateKeyTweakAdd=function(e,t){var n=a.fromBuffer(t);if(n.isOverflow())throw new Error(s.EC_PRIVATE_KEY_TWEAK_ADD_FAIL);if(n.iadd(a.fromBuffer(e)),n.isOverflow()&&n.isub(a.n),n.isZero())throw new Error(s.EC_PRIVATE_KEY_TWEAK_ADD_FAIL);return n.toBuffer()},t.privateKeyTweakMul=function(e,t){var n=a.fromBuffer(t);if(n.isOverflow()||n.isZero())throw new Error(s.EC_PRIVATE_KEY_TWEAK_MUL_FAIL);var r=a.fromBuffer(e);return n.umul(r).ureduce().toBuffer()},t.publicKeyCreate=function(e,t){var n=a.fromBuffer(e);if(n.isOverflow()||n.isZero())throw new Error(s.EC_PUBLIC_KEY_CREATE_FAIL);return u.mul(n).toPublicKey(t)},t.publicKeyConvert=function(e,t){var n=l.fromPublicKey(e);if(null===n)throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);return n.toPublicKey(t)},t.publicKeyVerify=function(e){return null!==l.fromPublicKey(e)},t.publicKeyTweakAdd=function(e,t,n){var r=l.fromPublicKey(e);if(null===r)throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);if(t=a.fromBuffer(t),t.isOverflow())throw new Error(s.EC_PUBLIC_KEY_TWEAK_ADD_FAIL);var i=u.mul(t).add(r);if(i.inf)throw new Error(s.EC_PUBLIC_KEY_TWEAK_ADD_FAIL);return i.toPublicKey(n)},t.publicKeyTweakMul=function(e,t,n){var r=l.fromPublicKey(e);if(null===r)throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);if(t=a.fromBuffer(t),t.isOverflow()||t.isZero())throw new Error(s.EC_PUBLIC_KEY_TWEAK_MUL_FAIL);return r.mul(t).toPublicKey(n)},t.publicKeyCombine=function(e,t){for(var n=new Array(e.length),r=0;r<e.length;++r)if(n[r]=l.fromPublicKey(e[r]),null===n[r])throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);for(var i=n[0],o=1;o<n.length;++o)i=i.add(n[o]);if(i.inf)throw new Error(s.EC_PUBLIC_KEY_COMBINE_FAIL);return i.toPublicKey(t)},t.signatureNormalize=function(e){var t=a.fromBuffer(e.slice(0,32)),n=a.fromBuffer(e.slice(32,64));if(t.isOverflow()||n.isOverflow())throw new Error(s.ECDSA_SIGNATURE_PARSE_FAIL);var i=r.from(e);return n.isHigh()&&a.n.sub(n).toBuffer().copy(i,32),i},t.signatureExport=function(e){var t=e.slice(0,32),n=e.slice(32,64);if(a.fromBuffer(t).isOverflow()||a.fromBuffer(n).isOverflow())throw new Error(s.ECDSA_SIGNATURE_PARSE_FAIL);return{r:t,s:n}},t.signatureImport=function(e){var t=a.fromBuffer(e.r);t.isOverflow()&&(t=a.fromNumber(0));var n=a.fromBuffer(e.s);return n.isOverflow()&&(n=a.fromNumber(0)),r.concat([t.toBuffer(),n.toBuffer()])},t.sign=function(e,t,n,i){var l=a.fromBuffer(t);if(l.isOverflow()||l.isZero())throw new Error(s.ECDSA_SIGN_FAIL);if(null===n){var c=new o("sha256",t,e,i);n=function(){return c.generate(32)}}for(var h=a.fromBuffer(e),f=0;;++f){var p=n(e,t,null,i,f);if(!r.isBuffer(p)||32!==p.length)throw new Error(s.ECDSA_SIGN_FAIL);var d=a.fromBuffer(p);if(!d.isOverflow()&&!d.isZero()){var m=u.mul(d),g=m.x.fireduce();if(!g.isZero()){var y=d.uinvm().umul(g.umul(l).ureduce().iadd(h).fireduce()).ureduce();if(!y.isZero()){var v=(0!==m.x.ucmp(g)?2:0)|(m.y.isOdd()?1:0);return y.isHigh()&&(y=a.n.sub(y),v^=1),{signature:r.concat([g.toBuffer(),y.toBuffer()]),recovery:v}}}}}},t.verify=function(e,t,n){var r=a.fromBuffer(t.slice(0,32)),i=a.fromBuffer(t.slice(32,64));if(r.isOverflow()||i.isOverflow())throw new Error(s.ECDSA_SIGNATURE_PARSE_FAIL);if(i.isHigh()||r.isZero()||i.isZero())return!1;var o=l.fromPublicKey(n);if(null===o)throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);var c=i.uinvm(),h=c.umul(a.fromBuffer(e)).ureduce(),f=c.umul(r).ureduce(),p=u.mulAdd(h,o,f);if(p.inf)return!1;var d=p.z.redSqr();return 0===r.redMul(d).ucmp(p.x)||!(r.ucmp(a.psn)>=0)&&0===r.iadd(a.psn).redMul(d).ucmp(p.x)},t.recover=function(e,t,n,i){var o=a.fromBuffer(t.slice(0,32)),c=a.fromBuffer(t.slice(32,64));if(o.isOverflow()||c.isOverflow())throw new Error(s.ECDSA_SIGNATURE_PARSE_FAIL);do{if(o.isZero()||c.isZero())break;var h=o;if(n>>1){if(h.ucmp(a.psn)>=0)break;h=o.add(a.n)}var f=r.concat([r.from([2+(1&n)]),h.toBuffer()]),p=l.fromPublicKey(f);if(null===p)break;var d=o.uinvm(),m=a.n.sub(a.fromBuffer(e)).umul(d).ureduce(),g=c.umul(d).ureduce(),y=l.fromECJPoint(u.mulAdd(m,p,g));return y.toPublicKey(i)}while(0);throw new Error(s.ECDSA_RECOVER_FAIL)},t.ecdh=function(e,n){var r=t.ecdhUnsafe(e,n,!0);return i("sha256").update(r).digest()},t.ecdhUnsafe=function(e,t,n){var r=l.fromPublicKey(e);if(null===r)throw new Error(s.EC_PUBLIC_KEY_PARSE_FAIL);var i=a.fromBuffer(t);if(i.isOverflow()||i.isZero())throw new Error(s.ECDH_FAIL);return r.mul(i).toPublicKey(n)}},function(e,t,n){"use strict";var r=n(1),i=n(257),o=n(385),s=n(386),a=n(99);function l(e){a.call(this,"digest"),this._hash=e}r(l,a),l.prototype._update=function(e){this._hash.update(e)},l.prototype._final=function(){return this._hash.digest()},e.exports=function e(t){return t=t.toLowerCase(),"md5"===t?new i:"rmd160"===t||"ripemd160"===t?new o:new l(s(t))}},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(784);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(384),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){e.exports=n(259)},function(e,t,n){e.exports=n(98)},function(e,t,n){e.exports=n(258).Transform},function(e,t,n){e.exports=n(258).PassThrough},function(e,t,n){var r=n(1),i=n(120),o=n(5).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],a=new Array(80);function l(){this.init(),this._w=a,i.call(this,64,56)}function u(e){return e<<5|e>>>27}function c(e){return e<<30|e>>>2}function h(e,t,n,r){return 0===e?t&n|~t&r:2===e?t&n|t&r|n&r:t^n^r}r(l,i),l.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},l.prototype._update=function(e){for(var t=this._w,n=0|this._a,r=0|this._b,i=0|this._c,o=0|this._d,a=0|this._e,l=0;l<16;++l)t[l]=e.readInt32BE(4*l);for(;l<80;++l)t[l]=t[l-3]^t[l-8]^t[l-14]^t[l-16];for(var f=0;f<80;++f){var p=~~(f/20),d=u(n)+h(p,r,i,o)+a+t[f]+s[p]|0;a=o,o=i,i=c(r),r=n,n=d}this._a=n+this._a|0,this._b=r+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=a+this._e|0},l.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=l},function(e,t,n){var r=n(1),i=n(120),o=n(5).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],a=new Array(80);function l(){this.init(),this._w=a,i.call(this,64,56)}function u(e){return e<<1|e>>>31}function c(e){return e<<5|e>>>27}function h(e){return e<<30|e>>>2}function f(e,t,n,r){return 0===e?t&n|~t&r:2===e?t&n|t&r|n&r:t^n^r}r(l,i),l.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},l.prototype._update=function(e){for(var t=this._w,n=0|this._a,r=0|this._b,i=0|this._c,o=0|this._d,a=0|this._e,l=0;l<16;++l)t[l]=e.readInt32BE(4*l);for(;l<80;++l)t[l]=u(t[l-3]^t[l-8]^t[l-14]^t[l-16]);for(var p=0;p<80;++p){var d=~~(p/20),m=c(n)+f(d,r,i,o)+a+t[p]+s[d]|0;a=o,o=i,i=h(r),r=n,n=m}this._a=n+this._a|0,this._b=r+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=a+this._e|0},l.prototype._hash=function(){var e=o.allocUnsafe(20);return e.writeInt32BE(0|this._a,0),e.writeInt32BE(0|this._b,4),e.writeInt32BE(0|this._c,8),e.writeInt32BE(0|this._d,12),e.writeInt32BE(0|this._e,16),e},e.exports=l},function(e,t,n){var r=n(1),i=n(387),o=n(120),s=n(5).Buffer,a=new Array(64);function l(){this.init(),this._w=a,o.call(this,64,56)}r(l,i),l.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},l.prototype._hash=function(){var e=s.allocUnsafe(28);return e.writeInt32BE(this._a,0),e.writeInt32BE(this._b,4),e.writeInt32BE(this._c,8),e.writeInt32BE(this._d,12),e.writeInt32BE(this._e,16),e.writeInt32BE(this._f,20),e.writeInt32BE(this._g,24),e},e.exports=l},function(e,t,n){var r=n(1),i=n(388),o=n(120),s=n(5).Buffer,a=new Array(160);function l(){this.init(),this._w=a,o.call(this,128,112)}r(l,i),l.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},l.prototype._hash=function(){var e=s.allocUnsafe(48);function t(t,n,r){e.writeInt32BE(t,r),e.writeInt32BE(n,r+4)}return t(this._ah,this._al,0),t(this._bh,this._bl,8),t(this._ch,this._cl,16),t(this._dh,this._dl,24),t(this._eh,this._el,32),t(this._fh,this._fl,40),e},e.exports=l},function(e,t,n){"use strict";(function(t){var r=n(795),i=n(798),o=new t(0),s=new t([0]),a=new t([1]);function l(e,t,n,r){var o=i[e];if(void 0===o)throw new Error("hash "+e+" is not supported");this._algo=e,this._securityStrength=o.securityStrength/8,this._outlen=o.outlen/8,this._reseedInterval=281474976710656,this._init(t,n,r)}l.prototype._update=function(e){var t=r(this._algo,this._K).update(this._V).update(s);e&&t.update(e),this._K=t.digest(),this._V=r(this._algo,this._K).update(this._V).digest(),e&&(this._K=r(this._algo,this._K).update(this._V).update(a).update(e).digest(),this._V=r(this._algo,this._K).update(this._V).digest())},l.prototype._init=function(e,n,r){if(e.length<this._securityStrength)throw new Error("Not enough entropy");this._K=new t(this._outlen),this._V=new t(this._outlen);for(var i=0;i<this._K.length;++i)this._K[i]=0,this._V[i]=1;this._update(t.concat([e,n,r||o])),this._reseed=1},l.prototype.reseed=function(e,n){if(e.length<this._securityStrength)throw new Error("Not enough entropy");this._update(t.concat([e,n||o])),this._reseed=1},l.prototype.generate=function(e,n){if(this._reseed>this._reseedInterval)throw new Error("Reseed is required");n&&0===n.length&&(n=void 0),n&&this._update(n);for(var i=new t(0);i.length<e;)this._V=r(this._algo,this._K).update(this._V).digest(),i=t.concat([i,this._V]);return this._update(n),this._reseed+=1,i.slice(0,e)},e.exports=l}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=n(1),i=n(796),o=n(99),s=n(5).Buffer,a=n(797),l=n(385),u=n(386),c=s.alloc(128);function h(e,t){o.call(this,"digest"),"string"==typeof t&&(t=s.from(t));var n="sha512"===e||"sha384"===e?128:64;if(this._alg=e,this._key=t,t.length>n){var r="rmd160"===e?new l:u(e);t=r.update(t).digest()}else t.length<n&&(t=s.concat([t,c],n));for(var i=this._ipad=s.allocUnsafe(n),a=this._opad=s.allocUnsafe(n),h=0;h<n;h++)i[h]=54^t[h],a[h]=92^t[h];this._hash="rmd160"===e?new l:u(e),this._hash.update(i)}r(h,o),h.prototype._update=function(e){this._hash.update(e)},h.prototype._final=function(){var e=this._hash.digest(),t="rmd160"===this._alg?new l:u(this._alg);return t.update(this._opad).update(e).digest()},e.exports=function e(t,n){return t=t.toLowerCase(),"rmd160"===t||"ripemd160"===t?new h("rmd160",n):"md5"===t?new i(a,n):new h(t,n)}},function(e,t,n){"use strict";var r=n(1),i=n(5).Buffer,o=n(99),s=i.alloc(128),a=64;function l(e,t){o.call(this,"digest"),"string"==typeof t&&(t=i.from(t)),this._alg=e,this._key=t,t.length>a?t=e(t):t.length<a&&(t=i.concat([t,s],a));for(var n=this._ipad=i.allocUnsafe(a),r=this._opad=i.allocUnsafe(a),l=0;l<a;l++)n[l]=54^t[l],r[l]=92^t[l];this._hash=[n]}r(l,o),l.prototype._update=function(e){this._hash.push(e)},l.prototype._final=function(){var e=this._alg(i.concat(this._hash));return this._alg(i.concat([this._opad,e]))},e.exports=l},function(e,t,n){var r=n(257);e.exports=function(e){return(new r).update(e).digest()}},function(e){e.exports={sha1:{securityStrength:128,outlen:160,seedlen:440},sha224:{securityStrength:192,outlen:224,seedlen:440},sha256:{securityStrength:256,outlen:256,seedlen:440},sha384:{securityStrength:256,outlen:384,seedlen:888},sha512:{securityStrength:256,outlen:512,seedlen:888}}},function(e,t,n){"use strict";t.umulTo10x10=function(e,t,n){var r=e.words,i=t.words,o=n.words,s=0,a,l,u,c=0|r[0],h=8191&c,f=c>>>13,p=0|r[1],d=8191&p,m=p>>>13,g=0|r[2],y=8191&g,v=g>>>13,b=0|r[3],_=8191&b,w=b>>>13,k=0|r[4],E=8191&k,S=k>>>13,x=0|r[5],C=8191&x,A=x>>>13,T=0|r[6],I=8191&T,j=T>>>13,R=0|r[7],B=8191&R,O=R>>>13,P=0|r[8],N=8191&P,D=P>>>13,M=0|r[9],F=8191&M,L=M>>>13,U=0|i[0],q=8191&U,z=U>>>13,K=0|i[1],H=8191&K,V=K>>>13,$=0|i[2],W=8191&$,G=$>>>13,Y=0|i[3],Z=8191&Y,J=Y>>>13,Q=0|i[4],X=8191&Q,ee=Q>>>13,te=0|i[5],ne=8191&te,re=te>>>13,ie=0|i[6],oe=8191&ie,se=ie>>>13,ae=0|i[7],le=8191&ae,ue=ae>>>13,ce=0|i[8],he=8191&ce,fe=ce>>>13,pe=0|i[9],de=8191&pe,me=pe>>>13;n.length=19,a=Math.imul(h,q),l=Math.imul(h,z),l+=Math.imul(f,q),u=Math.imul(f,z);var ge=s+a+((8191&l)<<13);s=u+(l>>>13)+(ge>>>26),ge&=67108863,a=Math.imul(d,q),l=Math.imul(d,z),l+=Math.imul(m,q),u=Math.imul(m,z),a+=Math.imul(h,H),l+=Math.imul(h,V),l+=Math.imul(f,H),u+=Math.imul(f,V);var ye=s+a+((8191&l)<<13);s=u+(l>>>13)+(ye>>>26),ye&=67108863,a=Math.imul(y,q),l=Math.imul(y,z),l+=Math.imul(v,q),u=Math.imul(v,z),a+=Math.imul(d,H),l+=Math.imul(d,V),l+=Math.imul(m,H),u+=Math.imul(m,V),a+=Math.imul(h,W),l+=Math.imul(h,G),l+=Math.imul(f,W),u+=Math.imul(f,G);var ve=s+a+((8191&l)<<13);s=u+(l>>>13)+(ve>>>26),ve&=67108863,a=Math.imul(_,q),l=Math.imul(_,z),l+=Math.imul(w,q),u=Math.imul(w,z),a+=Math.imul(y,H),l+=Math.imul(y,V),l+=Math.imul(v,H),u+=Math.imul(v,V),a+=Math.imul(d,W),l+=Math.imul(d,G),l+=Math.imul(m,W),u+=Math.imul(m,G),a+=Math.imul(h,Z),l+=Math.imul(h,J),l+=Math.imul(f,Z),u+=Math.imul(f,J);var be=s+a+((8191&l)<<13);s=u+(l>>>13)+(be>>>26),be&=67108863,a=Math.imul(E,q),l=Math.imul(E,z),l+=Math.imul(S,q),u=Math.imul(S,z),a+=Math.imul(_,H),l+=Math.imul(_,V),l+=Math.imul(w,H),u+=Math.imul(w,V),a+=Math.imul(y,W),l+=Math.imul(y,G),l+=Math.imul(v,W),u+=Math.imul(v,G),a+=Math.imul(d,Z),l+=Math.imul(d,J),l+=Math.imul(m,Z),u+=Math.imul(m,J),a+=Math.imul(h,X),l+=Math.imul(h,ee),l+=Math.imul(f,X),u+=Math.imul(f,ee);var _e=s+a+((8191&l)<<13);s=u+(l>>>13)+(_e>>>26),_e&=67108863,a=Math.imul(C,q),l=Math.imul(C,z),l+=Math.imul(A,q),u=Math.imul(A,z),a+=Math.imul(E,H),l+=Math.imul(E,V),l+=Math.imul(S,H),u+=Math.imul(S,V),a+=Math.imul(_,W),l+=Math.imul(_,G),l+=Math.imul(w,W),u+=Math.imul(w,G),a+=Math.imul(y,Z),l+=Math.imul(y,J),l+=Math.imul(v,Z),u+=Math.imul(v,J),a+=Math.imul(d,X),l+=Math.imul(d,ee),l+=Math.imul(m,X),u+=Math.imul(m,ee),a+=Math.imul(h,ne),l+=Math.imul(h,re),l+=Math.imul(f,ne),u+=Math.imul(f,re);var we=s+a+((8191&l)<<13);s=u+(l>>>13)+(we>>>26),we&=67108863,a=Math.imul(I,q),l=Math.imul(I,z),l+=Math.imul(j,q),u=Math.imul(j,z),a+=Math.imul(C,H),l+=Math.imul(C,V),l+=Math.imul(A,H),u+=Math.imul(A,V),a+=Math.imul(E,W),l+=Math.imul(E,G),l+=Math.imul(S,W),u+=Math.imul(S,G),a+=Math.imul(_,Z),l+=Math.imul(_,J),l+=Math.imul(w,Z),u+=Math.imul(w,J),a+=Math.imul(y,X),l+=Math.imul(y,ee),l+=Math.imul(v,X),u+=Math.imul(v,ee),a+=Math.imul(d,ne),l+=Math.imul(d,re),l+=Math.imul(m,ne),u+=Math.imul(m,re),a+=Math.imul(h,oe),l+=Math.imul(h,se),l+=Math.imul(f,oe),u+=Math.imul(f,se);var ke=s+a+((8191&l)<<13);s=u+(l>>>13)+(ke>>>26),ke&=67108863,a=Math.imul(B,q),l=Math.imul(B,z),l+=Math.imul(O,q),u=Math.imul(O,z),a+=Math.imul(I,H),l+=Math.imul(I,V),l+=Math.imul(j,H),u+=Math.imul(j,V),a+=Math.imul(C,W),l+=Math.imul(C,G),l+=Math.imul(A,W),u+=Math.imul(A,G),a+=Math.imul(E,Z),l+=Math.imul(E,J),l+=Math.imul(S,Z),u+=Math.imul(S,J),a+=Math.imul(_,X),l+=Math.imul(_,ee),l+=Math.imul(w,X),u+=Math.imul(w,ee),a+=Math.imul(y,ne),l+=Math.imul(y,re),l+=Math.imul(v,ne),u+=Math.imul(v,re),a+=Math.imul(d,oe),l+=Math.imul(d,se),l+=Math.imul(m,oe),u+=Math.imul(m,se),a+=Math.imul(h,le),l+=Math.imul(h,ue),l+=Math.imul(f,le),u+=Math.imul(f,ue);var Ee=s+a+((8191&l)<<13);s=u+(l>>>13)+(Ee>>>26),Ee&=67108863,a=Math.imul(N,q),l=Math.imul(N,z),l+=Math.imul(D,q),u=Math.imul(D,z),a+=Math.imul(B,H),l+=Math.imul(B,V),l+=Math.imul(O,H),u+=Math.imul(O,V),a+=Math.imul(I,W),l+=Math.imul(I,G),l+=Math.imul(j,W),u+=Math.imul(j,G),a+=Math.imul(C,Z),l+=Math.imul(C,J),l+=Math.imul(A,Z),u+=Math.imul(A,J),a+=Math.imul(E,X),l+=Math.imul(E,ee),l+=Math.imul(S,X),u+=Math.imul(S,ee),a+=Math.imul(_,ne),l+=Math.imul(_,re),l+=Math.imul(w,ne),u+=Math.imul(w,re),a+=Math.imul(y,oe),l+=Math.imul(y,se),l+=Math.imul(v,oe),u+=Math.imul(v,se),a+=Math.imul(d,le),l+=Math.imul(d,ue),l+=Math.imul(m,le),u+=Math.imul(m,ue),a+=Math.imul(h,he),l+=Math.imul(h,fe),l+=Math.imul(f,he),u+=Math.imul(f,fe);var Se=s+a+((8191&l)<<13);s=u+(l>>>13)+(Se>>>26),Se&=67108863,a=Math.imul(F,q),l=Math.imul(F,z),l+=Math.imul(L,q),u=Math.imul(L,z),a+=Math.imul(N,H),l+=Math.imul(N,V),l+=Math.imul(D,H),u+=Math.imul(D,V),a+=Math.imul(B,W),l+=Math.imul(B,G),l+=Math.imul(O,W),u+=Math.imul(O,G),a+=Math.imul(I,Z),l+=Math.imul(I,J),l+=Math.imul(j,Z),u+=Math.imul(j,J),a+=Math.imul(C,X),l+=Math.imul(C,ee),l+=Math.imul(A,X),u+=Math.imul(A,ee),a+=Math.imul(E,ne),l+=Math.imul(E,re),l+=Math.imul(S,ne),u+=Math.imul(S,re),a+=Math.imul(_,oe),l+=Math.imul(_,se),l+=Math.imul(w,oe),u+=Math.imul(w,se),a+=Math.imul(y,le),l+=Math.imul(y,ue),l+=Math.imul(v,le),u+=Math.imul(v,ue),a+=Math.imul(d,he),l+=Math.imul(d,fe),l+=Math.imul(m,he),u+=Math.imul(m,fe),a+=Math.imul(h,de),l+=Math.imul(h,me),l+=Math.imul(f,de),u+=Math.imul(f,me);var xe=s+a+((8191&l)<<13);s=u+(l>>>13)+(xe>>>26),xe&=67108863,a=Math.imul(F,H),l=Math.imul(F,V),l+=Math.imul(L,H),u=Math.imul(L,V),a+=Math.imul(N,W),l+=Math.imul(N,G),l+=Math.imul(D,W),u+=Math.imul(D,G),a+=Math.imul(B,Z),l+=Math.imul(B,J),l+=Math.imul(O,Z),u+=Math.imul(O,J),a+=Math.imul(I,X),l+=Math.imul(I,ee),l+=Math.imul(j,X),u+=Math.imul(j,ee),a+=Math.imul(C,ne),l+=Math.imul(C,re),l+=Math.imul(A,ne),u+=Math.imul(A,re),a+=Math.imul(E,oe),l+=Math.imul(E,se),l+=Math.imul(S,oe),u+=Math.imul(S,se),a+=Math.imul(_,le),l+=Math.imul(_,ue),l+=Math.imul(w,le),u+=Math.imul(w,ue),a+=Math.imul(y,he),l+=Math.imul(y,fe),l+=Math.imul(v,he),u+=Math.imul(v,fe),a+=Math.imul(d,de),l+=Math.imul(d,me),l+=Math.imul(m,de),u+=Math.imul(m,me);var Ce=s+a+((8191&l)<<13);s=u+(l>>>13)+(Ce>>>26),Ce&=67108863,a=Math.imul(F,W),l=Math.imul(F,G),l+=Math.imul(L,W),u=Math.imul(L,G),a+=Math.imul(N,Z),l+=Math.imul(N,J),l+=Math.imul(D,Z),u+=Math.imul(D,J),a+=Math.imul(B,X),l+=Math.imul(B,ee),l+=Math.imul(O,X),u+=Math.imul(O,ee),a+=Math.imul(I,ne),l+=Math.imul(I,re),l+=Math.imul(j,ne),u+=Math.imul(j,re),a+=Math.imul(C,oe),l+=Math.imul(C,se),l+=Math.imul(A,oe),u+=Math.imul(A,se),a+=Math.imul(E,le),l+=Math.imul(E,ue),l+=Math.imul(S,le),u+=Math.imul(S,ue),a+=Math.imul(_,he),l+=Math.imul(_,fe),l+=Math.imul(w,he),u+=Math.imul(w,fe),a+=Math.imul(y,de),l+=Math.imul(y,me),l+=Math.imul(v,de),u+=Math.imul(v,me);var Ae=s+a+((8191&l)<<13);s=u+(l>>>13)+(Ae>>>26),Ae&=67108863,a=Math.imul(F,Z),l=Math.imul(F,J),l+=Math.imul(L,Z),u=Math.imul(L,J),a+=Math.imul(N,X),l+=Math.imul(N,ee),l+=Math.imul(D,X),u+=Math.imul(D,ee),a+=Math.imul(B,ne),l+=Math.imul(B,re),l+=Math.imul(O,ne),u+=Math.imul(O,re),a+=Math.imul(I,oe),l+=Math.imul(I,se),l+=Math.imul(j,oe),u+=Math.imul(j,se),a+=Math.imul(C,le),l+=Math.imul(C,ue),l+=Math.imul(A,le),u+=Math.imul(A,ue),a+=Math.imul(E,he),l+=Math.imul(E,fe),l+=Math.imul(S,he),u+=Math.imul(S,fe),a+=Math.imul(_,de),l+=Math.imul(_,me),l+=Math.imul(w,de),u+=Math.imul(w,me);var Te=s+a+((8191&l)<<13);s=u+(l>>>13)+(Te>>>26),Te&=67108863,a=Math.imul(F,X),l=Math.imul(F,ee),l+=Math.imul(L,X),u=Math.imul(L,ee),a+=Math.imul(N,ne),l+=Math.imul(N,re),l+=Math.imul(D,ne),u+=Math.imul(D,re),a+=Math.imul(B,oe),l+=Math.imul(B,se),l+=Math.imul(O,oe),u+=Math.imul(O,se),a+=Math.imul(I,le),l+=Math.imul(I,ue),l+=Math.imul(j,le),u+=Math.imul(j,ue),a+=Math.imul(C,he),l+=Math.imul(C,fe),l+=Math.imul(A,he),u+=Math.imul(A,fe),a+=Math.imul(E,de),l+=Math.imul(E,me),l+=Math.imul(S,de),u+=Math.imul(S,me);var Ie=s+a+((8191&l)<<13);s=u+(l>>>13)+(Ie>>>26),Ie&=67108863,a=Math.imul(F,ne),l=Math.imul(F,re),l+=Math.imul(L,ne),u=Math.imul(L,re),a+=Math.imul(N,oe),l+=Math.imul(N,se),l+=Math.imul(D,oe),u+=Math.imul(D,se),a+=Math.imul(B,le),l+=Math.imul(B,ue),l+=Math.imul(O,le),u+=Math.imul(O,ue),a+=Math.imul(I,he),l+=Math.imul(I,fe),l+=Math.imul(j,he),u+=Math.imul(j,fe),a+=Math.imul(C,de),l+=Math.imul(C,me),l+=Math.imul(A,de),u+=Math.imul(A,me);var je=s+a+((8191&l)<<13);s=u+(l>>>13)+(je>>>26),je&=67108863,a=Math.imul(F,oe),l=Math.imul(F,se),l+=Math.imul(L,oe),u=Math.imul(L,se),a+=Math.imul(N,le),l+=Math.imul(N,ue),l+=Math.imul(D,le),u+=Math.imul(D,ue),a+=Math.imul(B,he),l+=Math.imul(B,fe),l+=Math.imul(O,he),u+=Math.imul(O,fe),a+=Math.imul(I,de),l+=Math.imul(I,me),l+=Math.imul(j,de),u+=Math.imul(j,me);var Re=s+a+((8191&l)<<13);s=u+(l>>>13)+(Re>>>26),Re&=67108863,a=Math.imul(F,le),l=Math.imul(F,ue),l+=Math.imul(L,le),u=Math.imul(L,ue),a+=Math.imul(N,he),l+=Math.imul(N,fe),l+=Math.imul(D,he),u+=Math.imul(D,fe),a+=Math.imul(B,de),l+=Math.imul(B,me),l+=Math.imul(O,de),u+=Math.imul(O,me);var Be=s+a+((8191&l)<<13);s=u+(l>>>13)+(Be>>>26),Be&=67108863,a=Math.imul(F,he),l=Math.imul(F,fe),l+=Math.imul(L,he),u=Math.imul(L,fe),a+=Math.imul(N,de),l+=Math.imul(N,me),l+=Math.imul(D,de),u+=Math.imul(D,me);var Oe=s+a+((8191&l)<<13);s=u+(l>>>13)+(Oe>>>26),Oe&=67108863,a=Math.imul(F,de),l=Math.imul(F,me),l+=Math.imul(L,de),u=Math.imul(L,me);var Pe=s+a+((8191&l)<<13);return s=u+(l>>>13)+(Pe>>>26),Pe&=67108863,o[0]=ge,o[1]=ye,o[2]=ve,o[3]=be,o[4]=_e,o[5]=we,o[6]=ke,o[7]=Ee,o[8]=Se,o[9]=xe,o[10]=Ce,o[11]=Ae,o[12]=Te,o[13]=Ie,o[14]=je,o[15]=Re,o[16]=Be,o[17]=Oe,o[18]=Pe,0!==s&&(o[19]=s,n.length++),n}},function(e,t,n){"use strict";var r=n(5).Buffer,i=n(197),o=n(389),s=n(390);function a(){this.x=i.fromBuffer(r.from("79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798","hex")),this.y=i.fromBuffer(r.from("483ADA7726A3C4655DA4FBFC0E1108A8FD17B448A68554199C47D08FFB10D4B8","hex")),this.inf=!1,this._precompute()}a.prototype._precompute=function(){for(var e=new o(this.x,this.y),t=4,n=new Array(1+Math.ceil(64.25)),r=n[0]=e,i=1;i<n.length;++i){for(var s=0;s<4;s++)r=r.dbl();n[i]=r}this.precomputed={naf:e._getNAFPoints(7),doubles:{step:4,points:n,negpoints:n.map(function(e){return e.neg()})}}},a.prototype.mul=function(e){for(var t=this.precomputed.doubles.step,n=this.precomputed.doubles.points,r=this.precomputed.doubles.negpoints,i=e.getNAF(1),a=((1<<t+1)-(t%2==0?2:1))/3,l=[],u=0;u<i.length;u+=t){for(var c=0,h=u+t-1;h>=u;h--)c=(c<<1)+i[h];l.push(c)}for(var f=new s(null,null,null),p=new s(null,null,null),d=a;d>0;d--){for(var m=0;m<l.length;m++)l[m]===d?p=p.mixedAdd(n[m]):l[m]===-d&&(p=p.mixedAdd(r[m]));f=f.add(p)}return o.fromECJPoint(f)},a.prototype.mulAdd=function(e,t,n){for(var r=this.precomputed.naf,i=t._getNAFPoints1(),o=[r.points,i.points],a=[e.getNAF(r.wnd),n.getNAF(i.wnd)],l=new s(null,null,null),u=[null,null],c=Math.max(a[0].length,a[1].length);c>=0;c--){for(var h=0;c>=0&&(u[0]=0|a[0][c],u[1]=0|a[1][c],0===u[0]&&0===u[1]);++h,--c);if(c>=0&&(h+=1),l=l.dblp(h),c<0)break;for(var f=0;f<2;f++){var p=u[f],d;0!==p&&(p>0?d=o[f][p>>1]:p<0&&(d=o[f][-p>>1].neg()),l=void 0===d.z?l.mixedAdd(d):l.add(d))}}return l},e.exports=new a},function(e,t,n){"use strict";(function(t){const r=n(154),i=n(391),o={"AES-128":{ivSize:16,keySize:16},"AES-256":{ivSize:16,keySize:32},Blowfish:{ivSize:8,cipherKeySize:32}};e.exports=((e,n,s,a)=>{const l=o[e];if(!l)return a(new Error("unkown cipherType passed"));if(!n)return a(new Error("unkown hashType passed"));const u=l.keySize,c=l.ivSize,h=20,f=t.from("key expansion"),p=2*(c+u+20);i.create(n,s,(e,n)=>{if(e)return a(e);n.digest(f,(e,i)=>{if(e)return a(e);let o=[],s=0;function l(e){n.digest(t.concat([i,f]),(t,r)=>{if(t)return e(t);let a=r.length;s+a>p&&(a=p-s),o.push(r),s+=a,n.digest(i,(t,n)=>{if(t)return e(t);i=n,e()})})}function h(e){if(e)return a(e);const n=p/2,r=t.concat(o),i=r.slice(0,n),s=r.slice(n,p),l=e=>({iv:e.slice(0,c),cipherKey:e.slice(c,c+u),macKey:e.slice(c+u)});a(null,{k1:l(i),k2:l(s)})}r(()=>s<p,l,h)})})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports={SHA1:20,SHA256:32,SHA512:64}},function(e,t,n){"use strict";const r=n(804);e.exports=((e,t)=>{r.generateEphmeralKeyPair(e,t)})},function(e,t,n){"use strict";(function(e){const r=n(255),i=n(254),o=n(119).bignum,s=n(378),a=s.toBase64,l=s.toBn,u={"P-256":256,"P-384":384,"P-521":521};t.generateEphmeralKeyPair=function(t,n){i(r.subtle.generateKey({name:"ECDH",namedCurve:t},!0,["deriveBits"]).then(n=>{const o=(o,s,a)=>{let l;"function"==typeof s&&(a=s,s=void 0),l=s?r.subtle.importKey("jwk",p(t,s),{name:"ECDH",namedCurve:t},!1,["deriveBits"]):Promise.resolve(n.privateKey);const c=Promise.all([r.subtle.importKey("jwk",f(t,o),{name:"ECDH",namedCurve:t},!1,[]),l]);i(c.then(e=>r.subtle.deriveBits({name:"ECDH",namedCurve:t,public:e[0]},e[1],u[t])).then(t=>e.from(t)),a)};return r.subtle.exportKey("jwk",n.publicKey).then(e=>({key:h(e),genSharedKey:o}))}),n)};const c={"P-256":32,"P-384":48,"P-521":66};function h(t){const n=c[t.crv];return e.concat([e.from([4]),l(t.x).toArrayLike(e,"be",n),l(t.y).toArrayLike(e,"be",n)],1+2*n)}function f(t,n){const r=c[t];if(!n.slice(0,1).equals(e.from([4])))throw new Error("Invalid key format");const i=new o(n.slice(1,r+1)),s=new o(n.slice(1+r));return{kty:"EC",crv:t,x:a(i,r),y:a(s,r),ext:!0}}function p(e,t){const n=f(e,t.public);return n.d=a(new o(t.private)),n}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(806),i=n(260),o=n(35);function s(e){const t=[],n=e.split("/").slice(1);if(1===n.length&&""===n[0])return[];for(let r=0;r<n.length;r++){const o=n[r],s=i(o);if(0!==s.size){if(r++,r>=n.length)throw _("invalid address: "+e);if(s.path){t.push([o,b(n.slice(r).join("/"))]);break}t.push([o,n[r]])}else t.push([o])}return t}function a(e){const t=[];return e.map(e=>{const n=w(e);t.push(n.name),e.length>1&&t.push(e[1])}),b(t.join("/"))}function l(e){return e.map(e=>{Array.isArray(e)||(e=[e]);const t=w(e);return e.length>1?[t.code,r.toBuffer(t.code,e[1])]:[t.code]})}function u(e){return e.map(e=>{const t=w(e);return e.length>1?[t.code,r.toString(t.code,e[1])]:[t.code]})}function c(e){return g(t.concat(e.map(e=>{const n=w(e);let r=t.from(o.encode(n.code));return e.length>1&&(r=t.concat([r,e[1]])),r})))}function h(e,t){if(e.size>0)return e.size/8;if(0===e.size)return 0;{const e=o.decode(t);return e+o.decode.bytes}}function f(e){const t=[];let n=0;for(;n<e.length;){const r=o.decode(e,n),s=o.decode.bytes,a=i(r),l=h(a,e.slice(n+s));if(0===l){t.push([r]),n+=s;continue}const u=e.slice(n+s,n+s+l);if(n+=l+s,n>e.length)throw _("Invalid address buffer: "+e.toString("hex"));t.push([r,u])}return t}function p(e){const t=f(e),n=u(t);return a(n)}function d(e){e=b(e);const t=s(e),n=l(t);return c(n)}function m(e){return d(e)}function g(e){const n=y(e);if(n)throw n;return t.from(e)}function y(e){try{f(e)}catch(e){return e}}function v(e){return void 0===y(e)}function b(e){return"/"+e.trim().split("/").filter(e=>e).join("/")}function _(e){return new Error("Error parsing address: "+e)}function w(e){const t=i(e[0]);return t}e.exports={stringToStringTuples:s,stringTuplesToString:a,tuplesToStringTuples:u,stringTuplesToTuples:l,bufferToTuples:f,tuplesToBuffer:c,bufferToString:p,stringToBuffer:d,fromString:m,fromBuffer:g,validateBuffer:y,isValidBuffer:v,cleanPath:b,ParseError:_,protoFromTuple:w,sizeForAddr:h}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(807),i=n(808),o=n(260),s=n(70),a=n(810),l=n(35);function u(e,n){return n instanceof t?u.toString(e,n):u.toBuffer(e,n)}function c(e){if(!i(e))throw new Error("invalid ip address");return r.toBuffer(e)}function h(e){const t=r.toString(e);if(!i(t))throw new Error("invalid ip address");return t}function f(e){const n=t.alloc(2);return n.writeUInt16BE(e,0),n}function p(e){return e.readUInt16BE(0)}function d(e){const n=t.from(e),r=t.from(l.encode(n.length));return t.concat([r,n])}function m(e){const t=l.decode(e);if(e=e.slice(l.decode.bytes),e.length!==t)throw new Error("inconsistent lengths");return e.toString()}function g(e){const n=t.from(s.decode(e)),r=t.from(l.encode(n.length));return t.concat([r,n])}function y(e){const t=l.decode(e),n=e.slice(l.decode.bytes);if(n.length!==t)throw new Error("inconsistent lengths");return s.encode(n)}function v(e){const n=e.split(":");if(2!==n.length)throw new Error("failed to parse onion addr: "+n+" does not contain a port number");if(16!==n[0].length)throw new Error("failed to parse onion addr: "+n[0]+" not a Tor onion address.");const r=t.from(a.decode.asBytes(n[0].toUpperCase())),i=parseInt(n[1],10);if(i<1||i>65536)throw new Error("Port number is not in range(1, 65536)");const o=f(i);return t.concat([r,o])}function b(e){const n=e.split(":");if(2!==n.length)throw new Error("failed to parse onion addr: "+n+" does not contain a port number");if(56!==n[0].length)throw new Error("failed to parse onion addr: "+n[0]+" not a Tor onion3 address.");const r=t.from(a.decode.asBytes(n[0].toUpperCase())),i=parseInt(n[1],10);if(i<1||i>65536)throw new Error("Port number is not in range(1, 65536)");const o=f(i);return t.concat([r,o])}function _(e){const t=e.slice(0,e.length-2),n=e.slice(e.length-2),r=a.encode(t).toString("ascii").toLowerCase(),i=p(n);return r+":"+i}e.exports=u,u.toString=function e(t,n){switch(t=o(t),t.code){case 4:case 41:return h(n);case 6:case 273:case 33:case 132:return p(n);case 53:case 54:case 55:case 56:case 400:return m(n);case 421:return y(n);case 444:case 445:return _(n);default:return n.toString("hex")}},u.toBuffer=function e(n,r){switch(n=o(n),n.code){case 4:case 41:return c(r);case 6:case 273:case 33:case 132:return f(parseInt(r,10));case 53:case 54:case 55:case 56:case 400:return d(r);case 421:return g(r);case 444:return v(r);case 445:return b(r);default:return t.from(r,"hex")}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=t,i=n(0).Buffer,o=n(198);r.toBuffer=function(e,t,n){var r;if(n=~~n,this.isV4Format(e))r=t||new i(n+4),e.split(/\./g).map(function(e){r[n++]=255&parseInt(e,10)});else if(this.isV6Format(e)){var o=e.split(":",8),s;for(s=0;s<o.length;s++){var a=this.isV4Format(o[s]),l;a&&(l=this.toBuffer(o[s]),o[s]=l.slice(0,2).toString("hex")),l&&++s<8&&o.splice(s,0,l.slice(2,4).toString("hex"))}if(""===o[0])for(;o.length<8;)o.unshift("0");else if(""===o[o.length-1])for(;o.length<8;)o.push("0");else if(o.length<8){for(s=0;s<o.length&&""!==o[s];s++);var u=[s,1];for(s=9-o.length;s>0;s--)u.push("0");o.splice.apply(o,u)}for(r=t||new i(n+16),s=0;s<o.length;s++){var c=parseInt(o[s],16);r[n++]=c>>8&255,r[n++]=255&c}}if(!r)throw Error("Invalid ip address: "+e);return r},r.toString=function(e,t,n){t=~~t,n=n||e.length-t;var r=[];if(4===n){for(var i=0;i<n;i++)r.push(e[t+i]);r=r.join(".")}else if(16===n){for(var i=0;i<n;i+=2)r.push(e.readUInt16BE(t+i).toString(16));r=r.join(":"),r=r.replace(/(^|:)0(:0)*:0(:|$)/,"$1::$3"),r=r.replace(/:{3,4}/,"::")}return r};var s=/^(\d{1,3}\.){3,3}\d{1,3}$/,a=/^(::)?(((\d{1,3}\.){3}(\d{1,3}){1})?([0-9a-f]){0,4}:{0,2}){1,8}(::)?$/i;function l(e){return e?e.toLowerCase():"ipv4"}r.isV4Format=function(e){return s.test(e)},r.isV6Format=function(e){return a.test(e)},r.fromPrefixLen=function(e,t){t=e>32?"ipv6":l(t);var n=4;"ipv6"===t&&(n=16);for(var o=new i(n),s=0,a=o.length;s<a;++s){var u=8;e<8&&(u=e),e-=u,o[s]=255&~(255>>u)}return r.toString(o)},r.mask=function(e,t){e=r.toBuffer(e),t=r.toBuffer(t);var n=new i(Math.max(e.length,t.length)),o=0;if(e.length===t.length)for(o=0;o<e.length;o++)n[o]=e[o]&t[o];else if(4===t.length)for(o=0;o<t.length;o++)n[o]=e[e.length-4+o]&t[o];else{for(var o=0;o<n.length-6;o++)n[o]=0;for(n[10]=255,n[11]=255,o=0;o<e.length;o++)n[o+12]=e[o]&t[o+12];o+=12}for(;o<n.length;o++)n[o]=0;return r.toString(n)},r.cidr=function(e){var t=e.split("/"),n=t[0];if(2!==t.length)throw new Error("invalid CIDR subnet: "+n);var i=r.fromPrefixLen(parseInt(t[1],10));return r.mask(n,i)},r.subnet=function(e,t){for(var n=r.toLong(r.mask(e,t)),i=r.toBuffer(t),o=0,s=0;s<i.length;s++)if(255===i[s])o+=8;else for(var a=255&i[s];a;)a=a<<1&255,o++;var l=Math.pow(2,32-o);return{networkAddress:r.fromLong(n),firstAddress:l<=2?r.fromLong(n):r.fromLong(n+1),lastAddress:l<=2?r.fromLong(n+l-1):r.fromLong(n+l-2),broadcastAddress:r.fromLong(n+l-1),subnetMask:t,subnetMaskLength:o,numHosts:l<=2?l:l-2,length:l,contains:function(e){return n===r.toLong(r.mask(e,t))}}},r.cidrSubnet=function(e){var t=e.split("/"),n=t[0];if(2!==t.length)throw new Error("invalid CIDR subnet: "+n);var i=r.fromPrefixLen(parseInt(t[1],10));return r.subnet(n,i)},r.not=function(e){for(var t=r.toBuffer(e),n=0;n<t.length;n++)t[n]=255^t[n];return r.toString(t)},r.or=function(e,t){if(e=r.toBuffer(e),t=r.toBuffer(t),e.length===t.length){for(var n=0;n<e.length;++n)e[n]|=t[n];return r.toString(e)}var i=e,o=t;t.length>e.length&&(i=t,o=e);for(var s=i.length-o.length,n=s;n<i.length;++n)i[n]|=o[n-s];return r.toString(i)},r.isEqual=function(e,t){if(e=r.toBuffer(e),t=r.toBuffer(t),e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}if(4===t.length){var i=t;t=e,e=i}for(var n=0;n<10;n++)if(0!==t[n])return!1;var o=t.readUInt16BE(10);if(0!==o&&65535!==o)return!1;for(var n=0;n<4;n++)if(e[n]!==t[n+12])return!1;return!0},r.isPrivate=function(e){return/^(::f{4}:)?10\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?192\.168\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?172\.(1[6-9]|2\d|30|31)\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?127\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^(::f{4}:)?169\.254\.([0-9]{1,3})\.([0-9]{1,3})$/i.test(e)||/^f[cd][0-9a-f]{2}:/i.test(e)||/^fe80:/i.test(e)||/^::1$/.test(e)||/^::$/.test(e)},r.isPublic=function(e){return!r.isPrivate(e)},r.isLoopback=function(e){return/^(::f{4}:)?127\.([0-9]{1,3})\.([0-9]{1,3})\.([0-9]{1,3})/.test(e)||/^fe80::1$/.test(e)||/^::1$/.test(e)||/^::$/.test(e)},r.loopback=function(e){if(e=l(e),"ipv4"!==e&&"ipv6"!==e)throw new Error("family must be ipv4 or ipv6");return"ipv4"===e?"127.0.0.1":"fe80::1"},r.address=function(e,t){var n=o.networkInterfaces(),i;if(t=l(t),e&&"private"!==e&&"public"!==e){var s=n[e].filter(function(e){var n=e.family.toLowerCase();return n===t});if(0===s.length)return;return s[0].address}var i=Object.keys(n).map(function(i){var o=n[i].filter(function(n){return n.family=n.family.toLowerCase(),n.family===t&&!r.isLoopback(n.address)&&(!e||("public"===e?r.isPrivate(n.address):r.isPublic(n.address)))});return o.length?o[0].address:void 0}).filter(Boolean);return i.length?i[0]:r.loopback(t)},r.toLong=function(e){var t=0;return e.split(".").forEach(function(e){t<<=8,t+=parseInt(e)}),t>>>0},r.fromLong=function(e){return(e>>>24)+"."+(e>>16&255)+"."+(e>>8&255)+"."+(255&e)}},function(e,t,n){"use strict";const r=n(809),i=e.exports=(e=>r({exact:!0}).test(e));i.v4=(e=>r.v4({exact:!0}).test(e)),i.v6=(e=>r.v6({exact:!0}).test(e))},function(e,t,n){"use strict";const r="(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])(?:\\.(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])){3}",i="[0-9a-fA-F]{1,4}",o=`\n(\n(?:${i}:){7}(?:${i}|:)| // 1:2:3:4:5:6:7:: 1:2:3:4:5:6:7:8\n(?:${i}:){6}(?:${r}|:${i}|:)| // 1:2:3:4:5:6:: 1:2:3:4:5:6::8 1:2:3:4:5:6::8 1:2:3:4:5:6::1.2.3.4\n(?:${i}:){5}(?::${r}|(:${i}){1,2}|:)| // 1:2:3:4:5:: 1:2:3:4:5::7:8 1:2:3:4:5::8 1:2:3:4:5::7:1.2.3.4\n(?:${i}:){4}(?:(:${i}){0,1}:${r}|(:${i}){1,3}|:)| // 1:2:3:4:: 1:2:3:4::6:7:8 1:2:3:4::8 1:2:3:4::6:7:1.2.3.4\n(?:${i}:){3}(?:(:${i}){0,2}:${r}|(:${i}){1,4}|:)| // 1:2:3:: 1:2:3::5:6:7:8 1:2:3::8 1:2:3::5:6:7:1.2.3.4\n(?:${i}:){2}(?:(:${i}){0,3}:${r}|(:${i}){1,5}|:)| // 1:2:: 1:2::4:5:6:7:8 1:2::8 1:2::4:5:6:7:1.2.3.4\n(?:${i}:){1}(?:(:${i}){0,4}:${r}|(:${i}){1,6}|:)| // 1:: 1::3:4:5:6:7:8 1::8 1::3:4:5:6:7:1.2.3.4\n(?::((?::${i}){0,5}:${r}|(?::${i}){1,7}|:)) // ::2:3:4:5:6:7:8 ::2:3:4:5:6:7:8 ::8 ::1.2.3.4\n)(%[0-9a-zA-Z]{1,})? // %eth0 %1\n`.replace(/\s*\/\/.*$/gm,"").replace(/\n/g,"").trim(),s=e.exports=(e=>e&&e.exact?new RegExp(`(?:^${r}$)|(?:^${o}$)`):new RegExp(`(?:${r})|(?:${o})`,"g"));s.v4=(e=>e&&e.exact?new RegExp(`^${r}$`):new RegExp(r,"g")),s.v6=(e=>e&&e.exact?new RegExp(`^${o}$`):new RegExp(o,"g"))},function(e,t,n){(function(t,r){var i;
/*
* [hi-base32]{@link https://github.com/emn178/hi-base32}
*
* @version 0.5.0
* @author Chen, Yi-Cyuan [emn178@gmail.com]
* @copyright Chen, Yi-Cyuan 2015-2018
* @license MIT
*/
/*
* [hi-base32]{@link https://github.com/emn178/hi-base32}
*
* @version 0.5.0
* @author Chen, Yi-Cyuan [emn178@gmail.com]
* @copyright Chen, Yi-Cyuan 2015-2018
* @license MIT
*/
!function(){"use strict";var o="object"==typeof window?window:{},s=!o.HI_BASE32_NO_NODE_JS&&"object"==typeof t&&t.versions&&t.versions.node;s&&(o=r);var a=!o.HI_BASE32_NO_COMMON_JS&&"object"==typeof e&&e.exports,l=n(358),u="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567".split(""),c={A:0,B:1,C:2,D:3,E:4,F:5,G:6,H:7,I:8,J:9,K:10,L:11,M:12,N:13,O:14,P:15,Q:16,R:17,S:18,T:19,U:20,V:21,W:22,X:23,Y:24,Z:25,2:26,3:27,4:28,5:29,6:30,7:31},h=[0,0,0,0,0,0,0,0],f=function(e,t){t.length>10&&(t="..."+t.substr(-10));var n=new Error("Decoded data is not valid UTF-8. Maybe try base32.decode.asBytes()? Partial data after reading "+e+" bytes: "+t+" <-");throw n.position=e,n},p=function(e){for(var t="",n=e.length,r=0,i=0,o,s;r<n;)if(o=e[r++],o<=127)t+=String.fromCharCode(o);else{o>191&&o<=223?(s=31&o,i=1):o<=239?(s=15&o,i=2):o<=247?(s=7&o,i=3):f(r,t);for(var a=0;a<i;++a)o=e[r++],(o<128||o>191)&&f(r,t),s<<=6,s+=63&o;s>=55296&&s<=57343&&f(r,t),s>1114111&&f(r,t),s<=65535?t+=String.fromCharCode(s):(s-=65536,t+=String.fromCharCode(55296+(s>>10)),t+=String.fromCharCode(56320+(1023&s)))}return t},d=function(e){if(!/^[A-Z2-7=]+$/.test(e))throw new Error("Invalid base32 characters");e=e.replace(/=/g,"");for(var t,n,r,i,o,s,a,l,u=[],h=0,f=e.length,p=0,d=f>>3<<3;p<d;)t=c[e.charAt(p++)],n=c[e.charAt(p++)],r=c[e.charAt(p++)],i=c[e.charAt(p++)],o=c[e.charAt(p++)],s=c[e.charAt(p++)],a=c[e.charAt(p++)],l=c[e.charAt(p++)],u[h++]=255&(t<<3|n>>>2),u[h++]=255&(n<<6|r<<1|i>>>4),u[h++]=255&(i<<4|o>>>1),u[h++]=255&(o<<7|s<<2|a>>>3),u[h++]=255&(a<<5|l);var m=f-d;return 2===m?(t=c[e.charAt(p++)],n=c[e.charAt(p++)],u[h++]=255&(t<<3|n>>>2)):4===m?(t=c[e.charAt(p++)],n=c[e.charAt(p++)],r=c[e.charAt(p++)],i=c[e.charAt(p++)],u[h++]=255&(t<<3|n>>>2),u[h++]=255&(n<<6|r<<1|i>>>4)):5===m?(t=c[e.charAt(p++)],n=c[e.charAt(p++)],r=c[e.charAt(p++)],i=c[e.charAt(p++)],o=c[e.charAt(p++)],u[h++]=255&(t<<3|n>>>2),u[h++]=255&(n<<6|r<<1|i>>>4),u[h++]=255&(i<<4|o>>>1)):7===m&&(t=c[e.charAt(p++)],n=c[e.charAt(p++)],r=c[e.charAt(p++)],i=c[e.charAt(p++)],o=c[e.charAt(p++)],s=c[e.charAt(p++)],a=c[e.charAt(p++)],u[h++]=255&(t<<3|n>>>2),u[h++]=255&(n<<6|r<<1|i>>>4),u[h++]=255&(i<<4|o>>>1),u[h++]=255&(o<<7|s<<2|a>>>3)),u},m=function(e){for(var t,n,r,i,o,s="",a=e.length,l=0,c=5*parseInt(a/5);l<c;)t=e.charCodeAt(l++),n=e.charCodeAt(l++),r=e.charCodeAt(l++),i=e.charCodeAt(l++),o=e.charCodeAt(l++),s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[31&(i<<3|o>>>5)]+u[31&o];var h=a-c;return 1===h?(t=e.charCodeAt(l),s+=u[t>>>3]+u[t<<2&31]+"======"):2===h?(t=e.charCodeAt(l++),n=e.charCodeAt(l),s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[n<<4&31]+"===="):3===h?(t=e.charCodeAt(l++),n=e.charCodeAt(l++),r=e.charCodeAt(l),s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[r<<1&31]+"==="):4===h&&(t=e.charCodeAt(l++),n=e.charCodeAt(l++),r=e.charCodeAt(l++),i=e.charCodeAt(l),s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[i<<3&31]+"="),s},g=function(e){var t,n,r,i,o,s,a=!1,l="",c=0,f,p=0,d=0,m=e.length;do{for(h[0]=h[5],h[1]=h[6],h[2]=h[7],f=p;c<m&&f<5;++c)s=e.charCodeAt(c),s<128?h[f++]=s:s<2048?(h[f++]=192|s>>6,h[f++]=128|63&s):s<55296||s>=57344?(h[f++]=224|s>>12,h[f++]=128|s>>6&63,h[f++]=128|63&s):(s=65536+((1023&s)<<10|1023&e.charCodeAt(++c)),h[f++]=240|s>>18,h[f++]=128|s>>12&63,h[f++]=128|s>>6&63,h[f++]=128|63&s);d+=f-p,p=f-5,c===m&&++c,c>m&&f<6&&(a=!0),t=h[0],f>4?(n=h[1],r=h[2],i=h[3],o=h[4],l+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[31&(i<<3|o>>>5)]+u[31&o]):1===f?l+=u[t>>>3]+u[t<<2&31]+"======":2===f?(n=h[1],l+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[n<<4&31]+"===="):3===f?(n=h[1],r=h[2],l+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[r<<1&31]+"==="):(n=h[1],r=h[2],i=h[3],l+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[i<<3&31]+"=")}while(!a);return l},y=function(e){for(var t,n,r,i,o,s="",a=e.length,l=0,c=5*parseInt(a/5);l<c;)t=e[l++],n=e[l++],r=e[l++],i=e[l++],o=e[l++],s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[31&(i<<3|o>>>5)]+u[31&o];var h=a-c;return 1===h?(t=e[l],s+=u[t>>>3]+u[t<<2&31]+"======"):2===h?(t=e[l++],n=e[l],s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[n<<4&31]+"===="):3===h?(t=e[l++],n=e[l++],r=e[l],s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[r<<1&31]+"==="):4===h&&(t=e[l++],n=e[l++],r=e[l++],i=e[l],s+=u[t>>>3]+u[31&(t<<2|n>>>6)]+u[n>>>1&31]+u[31&(n<<4|r>>>4)]+u[31&(r<<1|i>>>7)]+u[i>>>2&31]+u[i<<3&31]+"="),s},v=function(e,t){var n="string"!=typeof e;return n&&e.constructor===ArrayBuffer&&(e=new Uint8Array(e)),n?y(e):t?m(e):g(e)},b=function(e,t){if(!t)return p(d(e));if(!/^[A-Z2-7=]+$/.test(e))throw new Error("Invalid base32 characters");var n,r,i,o,s,a,l,u,h="",f=e.indexOf("=");-1===f&&(f=e.length);for(var m=0,g=f>>3<<3;m<g;)n=c[e.charAt(m++)],r=c[e.charAt(m++)],i=c[e.charAt(m++)],o=c[e.charAt(m++)],s=c[e.charAt(m++)],a=c[e.charAt(m++)],l=c[e.charAt(m++)],u=c[e.charAt(m++)],h+=String.fromCharCode(255&(n<<3|r>>>2))+String.fromCharCode(255&(r<<6|i<<1|o>>>4))+String.fromCharCode(255&(o<<4|s>>>1))+String.fromCharCode(255&(s<<7|a<<2|l>>>3))+String.fromCharCode(255&(l<<5|u));var y=f-g;return 2===y?(n=c[e.charAt(m++)],r=c[e.charAt(m++)],h+=String.fromCharCode(255&(n<<3|r>>>2))):4===y?(n=c[e.charAt(m++)],r=c[e.charAt(m++)],i=c[e.charAt(m++)],o=c[e.charAt(m++)],h+=String.fromCharCode(255&(n<<3|r>>>2))+String.fromCharCode(255&(r<<6|i<<1|o>>>4))):5===y?(n=c[e.charAt(m++)],r=c[e.charAt(m++)],i=c[e.charAt(m++)],o=c[e.charAt(m++)],s=c[e.charAt(m++)],h+=String.fromCharCode(255&(n<<3|r>>>2))+String.fromCharCode(255&(r<<6|i<<1|o>>>4))+String.fromCharCode(255&(o<<4|s>>>1))):7===y&&(n=c[e.charAt(m++)],r=c[e.charAt(m++)],i=c[e.charAt(m++)],o=c[e.charAt(m++)],s=c[e.charAt(m++)],a=c[e.charAt(m++)],l=c[e.charAt(m++)],h+=String.fromCharCode(255&(n<<3|r>>>2))+String.fromCharCode(255&(r<<6|i<<1|o>>>4))+String.fromCharCode(255&(o<<4|s>>>1))+String.fromCharCode(255&(s<<7|a<<2|l>>>3))),h},_={encode:v,decode:b};b.asBytes=d,a?e.exports=_:(o.base32=_,l&&(i=function(){return _}.call(_,n,_,e),void 0===i||(e.exports=i)))}()}).call(this,n(3),n(8))},function(e,t,n){"use strict";const{ensureMultiaddr:r}=n(392),i=n(812);class o{constructor(e){this._multiaddrs=e||[],this._observedMultiaddrs=[]}add(e){e=r(e),this.has(e)||this._multiaddrs.push(e)}addSafe(e){e=r(e);const t=this._observedMultiaddrs.some((t,n)=>{if(t.equals(e))return this.add(e),this._observedMultiaddrs.splice(n,1),!0});t||this._observedMultiaddrs.push(e)}toArray(){return this._multiaddrs.slice()}get size(){return this._multiaddrs.length}forEach(e){return this._multiaddrs.forEach(e)}filterBy(e){return"object"!=typeof e||"function"!=typeof e.matches||"function"!=typeof e.partialMatch||"function"!=typeof e.toString?[]:this._multiaddrs.filter(t=>e.matches(t))}has(e){return e=r(e),this._multiaddrs.some(t=>t.equals(e))}delete(e){e=r(e),this._multiaddrs.some((t,n)=>{if(t.equals(e))return this._multiaddrs.splice(n,1),!0})}replace(e,t){Array.isArray(e)||(e=[e]),Array.isArray(t)||(t=[t]),e.forEach(e=>this.delete(e)),t.forEach(e=>this.add(e))}clear(){this._multiaddrs=[]}distinct(){return i(this._multiaddrs,e=>[e.toOptions().port,e.toOptions().transport].join())}}e.exports=o},function(e,t,n){"use strict";function r(e,t){var n=[],r={};if("function"!=typeof t){var i=t;t=function e(t){return t[i]}}return e.forEach(function e(i){var o=t(i);r[o]||(r[o]=!0,n.push(i))}),n}e.exports=r},function(e,t,n){"use strict";const r=n(814),i={16:"aes-128-ctr",32:"aes-256-ctr"};t.create=function(e,t,n){const o=i[e.length];if(!o)return n(new Error("Invalid key length"));const s=r.createCipheriv(o,e,t),a=r.createDecipheriv(o,e,t),l={encrypt(e,t){t(null,s.update(e))},decrypt(e,t){t(null,a.update(e))}};n(null,l)}},function(e,t,n){"use strict";const r=n(815);e.exports={createCipheriv:r.createCipheriv,createDecipheriv:r.createDecipheriv}},function(e,t,n){var r=n(816),i=n(824),o=n(396);function s(){return Object.keys(o)}t.createCipher=t.Cipher=r.createCipher,t.createCipheriv=t.Cipheriv=r.createCipheriv,t.createDecipher=t.Decipher=i.createDecipher,t.createDecipheriv=t.Decipheriv=i.createDecipheriv,t.listCiphers=t.getCiphers=s},function(e,t,n){var r=n(393),i=n(397),o=n(5).Buffer,s=n(398),a=n(99),l=n(199),u=n(399),c=n(1);function h(e,t,n){a.call(this),this._cache=new p,this._cipher=new l.AES(t),this._prev=o.from(n),this._mode=e,this._autopadding=!0}c(h,a),h.prototype._update=function(e){var t,n;this._cache.add(e);for(var r=[];t=this._cache.get();)n=this._mode.encrypt(this,t),r.push(n);return o.concat(r)};var f=o.alloc(16,16);function p(){this.cache=o.allocUnsafe(0)}function d(e,t,n){var a=r[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=o.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof n&&(n=o.from(n)),"GCM"!==a.mode&&n.length!==a.iv)throw new TypeError("invalid iv length "+n.length);return"stream"===a.type?new s(a.module,t,n):"auth"===a.type?new i(a.module,t,n):new h(a.module,t,n)}function m(e,t){var n=r[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");var i=u(t,!1,n.key,n.iv);return d(e,i.key,i.iv)}h.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(f))throw this._cipher.scrub(),new Error("data not multiple of block length")},h.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},p.prototype.add=function(e){this.cache=o.concat([this.cache,e])},p.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},p.prototype.flush=function(){for(var e=16-this.cache.length,t=o.allocUnsafe(e),n=-1;++n<e;)t.writeUInt8(e,n);return o.concat([this.cache,t])},t.createCipheriv=d,t.createCipher=m},function(e,t){t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},function(e,t,n){var r=n(155);t.encrypt=function(e,t){var n=r(t,e._prev);return e._prev=e._cipher.encryptBlock(n),e._prev},t.decrypt=function(e,t){var n=e._prev;e._prev=t;var i=e._cipher.decryptBlock(t);return r(i,n)}},function(e,t,n){var r=n(5).Buffer,i=n(155);function o(e,t,n){var o=t.length,s=i(t,e._cache);return e._cache=e._cache.slice(o),e._prev=r.concat([e._prev,n?t:s]),s}t.encrypt=function(e,t,n){for(var i=r.allocUnsafe(0),s;t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=r.allocUnsafe(0)),!(e._cache.length<=t.length)){i=r.concat([i,o(e,t,n)]);break}s=e._cache.length,i=r.concat([i,o(e,t.slice(0,s),n)]),t=t.slice(s)}return i}},function(e,t,n){var r=n(5).Buffer;function i(e,t,n){var i=e._cipher.encryptBlock(e._prev),o=i[0]^t;return e._prev=r.concat([e._prev.slice(1),r.from([n?t:o])]),o}t.encrypt=function(e,t,n){for(var o=t.length,s=r.allocUnsafe(o),a=-1;++a<o;)s[a]=i(e,t[a],n);return s}},function(e,t,n){var r=n(5).Buffer;function i(e,t,n){for(var r,i=-1,s=8,a=0,l,u;++i<8;)r=e._cipher.encryptBlock(e._prev),l=t&1<<7-i?128:0,u=r[0]^l,a+=(128&u)>>i%8,e._prev=o(e._prev,n?l:u);return a}function o(e,t){var n=e.length,i=-1,o=r.allocUnsafe(e.length);for(e=r.concat([e,r.from([t])]);++i<n;)o[i]=e[i]<<1|e[i+1]>>7;return o}t.encrypt=function(e,t,n){for(var o=t.length,s=r.allocUnsafe(o),a=-1;++a<o;)s[a]=i(e,t[a],n);return s}},function(e,t,n){(function(e){var r=n(155);function i(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(t,n){for(;t._cache.length<n.length;)t._cache=e.concat([t._cache,i(t)]);var o=t._cache.slice(0,n.length);return t._cache=t._cache.slice(n.length),r(n,o)}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(5).Buffer,i=r.alloc(16,0);function o(e){return[e.readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)]}function s(e){var t=r.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function a(e){this.h=e,this.state=r.alloc(16,0),this.cache=r.allocUnsafe(0)}a.prototype.ghash=function(e){for(var t=-1;++t<e.length;)this.state[t]^=e[t];this._multiply()},a.prototype._multiply=function(){for(var e=o(this.h),t=[0,0,0,0],n,r,i,a=-1;++a<128;){for(r=0!=(this.state[~~(a/8)]&1<<7-a%8),r&&(t[0]^=e[0],t[1]^=e[1],t[2]^=e[2],t[3]^=e[3]),i=0!=(1&e[3]),n=3;n>0;n--)e[n]=e[n]>>>1|(1&e[n-1])<<31;e[0]=e[0]>>>1,i&&(e[0]=e[0]^225<<24)}this.state=s(t)},a.prototype.update=function(e){var t;for(this.cache=r.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},a.prototype.final=function(e,t){return this.cache.length&&this.ghash(r.concat([this.cache,i],16)),this.ghash(s([0,e,0,t])),this.state},e.exports=a},function(e,t,n){var r=n(397),i=n(5).Buffer,o=n(393),s=n(398),a=n(99),l=n(199),u=n(399),c=n(1);function h(e,t,n){a.call(this),this._cache=new f,this._last=void 0,this._cipher=new l.AES(t),this._prev=i.from(n),this._mode=e,this._autopadding=!0}function f(){this.cache=i.allocUnsafe(0)}function p(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var n=-1;++n<t;)if(e[n+(16-t)]!==t)throw new Error("unable to decrypt data");if(16!==t)return e.slice(0,16-t)}function d(e,t,n){var a=o[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof n&&(n=i.from(n)),"GCM"!==a.mode&&n.length!==a.iv)throw new TypeError("invalid iv length "+n.length);if("string"==typeof t&&(t=i.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===a.type?new s(a.module,t,n,!0):"auth"===a.type?new r(a.module,t,n,!0):new h(a.module,t,n)}function m(e,t){var n=o[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");var r=u(t,!1,n.key,n.iv);return d(e,r.key,r.iv)}c(h,a),h.prototype._update=function(e){var t,n;this._cache.add(e);for(var r=[];t=this._cache.get(this._autopadding);)n=this._mode.decrypt(this,t),r.push(n);return i.concat(r)},h.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return p(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},h.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},f.prototype.add=function(e){this.cache=i.concat([this.cache,e])},f.prototype.get=function(e){var t;if(e){if(this.cache.length>16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},f.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=m,t.createDecipheriv=d},function(e,t,n){"use strict";const r=n(373),i=n(30),o={sha1:"sha1","sha2-256":"sha256","sha2-512":"sha512"};function s(e,t,n,s,a){const l=o[a];if(!l)throw new Error(`Hash '${a}' is unknown or not supported`);const u=r(e,t,n,s,l);return i.encode64(u)}e.exports=s},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(60),o=n(115),s=n(95),a=n(827),l=n(39);class u{constructor(e,n,s,a){if(c.isCID(e)){const n=e;return this.version=n.version,this.codec=n.codec,this.multihash=t.from(n.multihash),void(this.multibaseName=n.multibaseName||(0===n.version?"base58btc":"base32"))}if("string"==typeof e){const t=i.isEncoded(e);if(t){const n=i.decode(e);this.version=parseInt(n.slice(0,1).toString("hex"),16),this.codec=o.getCodec(n.slice(1)),this.multihash=o.rmPrefix(n.slice(1)),this.multibaseName=t}else this.version=0,this.codec="dag-pb",this.multihash=r.fromB58String(e),this.multibaseName="base58btc";return u.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(t.isBuffer(e)){const t=e.slice(0,1),n=parseInt(t.toString("hex"),16);if(1===n){const t=e;this.version=n,this.codec=o.getCodec(t.slice(1)),this.multihash=o.rmPrefix(t.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";u.validateCID(this)}else this.version=e,this.codec=n,this.multihash=s,this.multibaseName=a||(0===e?"base58btc":"base32"),u.validateCID(this)}get buffer(){let e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=t.concat([t.from("01","hex"),o.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}get prefix(){return t.concat([t.from(`0${this.version}`,"hex"),o.getCodeVarint(this.codec),r.prefix(this.multihash)])}toV0(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");const{name:e,length:t}=r.decode(this.multihash);if("sha2-256"!==e)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==t)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new c(0,this.codec,this.multihash)}toV1(){return new c(1,this.codec,this.multihash)}toBaseEncodedString(e=this.multibaseName){if(this.string&&e===this.multibaseName)return this.string;let t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=r.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=i.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}toString(e){return this.toBaseEncodedString(e)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}static validateCID(e){let t=a.checkCIDComponents(e);if(t)throw new Error(t)}}const c=l(u,{className:"CID",symbolName:"@ipld/js-cid/CID"});c.codecs=s,e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(27);var i={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!t.isBuffer(e.multihash))return"multihash must be a Buffer";try{r.validate(e.multihash)}catch(e){let t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(22),i=n(72),{struct:o,superstruct:s}=n(401),{optional:a,union:l}=o,u=s({types:{multiaddr:e=>{if(null===e)return`multiaddr invalid, value must be a string, Buffer, or another Multiaddr got ${e}`;try{r(e)}catch(e){return`multiaddr invalid, ${e.message}`}return!0},"multiaddr-ipfs":e=>!!i.IPFS.matches(e)||"multiaddr IPFS invalid"}}),c=u({repo:a(u("object|string")),repoOwner:"boolean?",preload:u({enabled:"boolean?",addresses:a(u(["multiaddr"])),interval:"number?"},{enabled:!0,interval:3e4}),init:a(l(["boolean",u({bits:"number?",emptyRepo:"boolean?",privateKey:a(u("object|string")),pass:"string?"})])),start:"boolean?",offline:"boolean?",pass:"string?",silent:"boolean?",relay:"object?",EXPERIMENTAL:a(u({pubsub:"boolean?",ipnsPubsub:"boolean?",sharding:"boolean?",dht:"boolean?"})),connectionManager:"object?",config:a(u({API:"object?",Addresses:a(u({Swarm:a(u(["multiaddr"])),API:"multiaddr?",Gateway:"multiaddr"})),Discovery:a(u({MDNS:a(u({Enabled:"boolean?",Interval:"number?"})),webRTCStar:a(u({Enabled:"boolean?"}))})),Bootstrap:a(u(["multiaddr-ipfs"]))})),libp2p:a(l(["function","object"]))},{repoOwner:!0}),h=e=>{const[t,n]=c.validate(e);if(t)throw t;return n};e.exports={validate:h}},function(e,t,n){"use strict";const r=n(10),i=n(261).errors;function o(e){return!!e&&(e.code===i.ERR_REPO_NOT_INITIALIZED||!!(e.message.match(/not found/)||e.message.match(/ENOENT/)||e.message.match(/No value/)))}e.exports=(e=>{e.log("booting");const t=e._options,n=t.init,i=t.start;r([t=>{if(!e._repo.closed)return t(null,!0);e._repo.open((e,n)=>o(e)?t(null,!1):e?t(e):void t(null,!0))},(r,i)=>{if(r)return e.init({repo:e._repo},e=>{if(e)return i(Object.assign(e,{emitted:!0}));i()});if(n){const n=Object.assign({bits:2048,pass:e._options.pass},"object"==typeof t.init?t.init:{});return e.init(n,e=>{if(e)return i(Object.assign(e,{emitted:!0}));i()})}i()},t=>{if(!i)return t();e.start(e=>{if(e)return t(Object.assign(e,{emitted:!0}));t()})}],t=>{t?t.emitted||e.emit("error",t):(e.log("booted"),e.emit("ready"))})})},function(e,t,n){"use strict";t.create=function e(t,n,r){const i=r.storageBackends[t],o=Object.assign({},r.storageBackendOptions[t]||{});return new i(n,o)}},function(e,t,n){"use strict";(function(t){const r=n(28).Key,i=n(4),o=i("repo:version"),s=new r("version");e.exports=(e=>({exists(t){e.has(s,t)},get(t){e.get(s,(e,n)=>{if(e)return t(e);t(null,parseInt(n.toString().trim(),10))})},set(n,r){e.put(s,t.from(String(n)),r)},check(e,t){this.get((n,r)=>{if(n)return t(n);o("comparing version: %s and %s",r,e);const i=6===r&&7===e||6===e&&7===r;if(r!==e&&!i)return t(new Error(`ipfs repo needs migration: expected version v${e}, found version v${r}`));t()})}}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(19),i=n(20),o=n(262).asyncFilter,s=n(262).asyncSort,a=n(403),l=n(406);class u{constructor(){this.data={}}open(e){i(e)}put(e,t,n){this.data[e.toString()]=t,i(n)}get(e,t){this.has(e,(n,r)=>n?t(n):r?void t(null,this.data[e.toString()]):t(l.notFoundError()))}has(e,t){i(()=>{t(null,void 0!==this.data[e.toString()])})}delete(e,t){delete this.data[e.toString()],i(()=>{t()})}batch(){let e=[],t=[];return{put(t,n){e.push([t,n])},delete(e){t.push(e)},commit:n=>{e.forEach(e=>{this.data[e[0].toString()]=e[1]}),e=[],t.forEach(e=>{delete this.data[e.toString()]}),t=[],i(n)}}}query(e){let t=[r.keys(this.data),r.map(e=>({key:new a(e),value:this.data[e]}))],n=[];if(null!=e.prefix){const t=e.prefix;n.push((e,n)=>n(null,e.key.toString().startsWith(t)))}if(null!=e.filters&&(n=n.concat(e.filters)),t=t.concat(n.map(e=>o(e))),null!=e.orders&&(t=t.concat(e.orders.map(e=>s(e)))),null!=e.offset){let n=0;t.push(r.filter(()=>n++>=e.offset))}return null!=e.limit&&t.push(r.take(e.limit)),!0===e.keysOnly&&t.push(r.map(e=>({key:e.key}))),r.apply(null,t)}close(e){i(e)}}e.exports=u},function(e,t,n){"use strict";const r=n(28).Key,i=n(106),o=n(10),s=n(202),a=n(834),l=n(0).Buffer,u=new r("config");e.exports=(e=>{const t=i(r,1),n={get(t,n){"function"==typeof t&&(n=t,t=void 0),t||(t=void 0),e.get(u,(e,r)=>{if(e)return n(e);let i;try{i=JSON.parse(r.toString())}catch(e){return n(e)}if(void 0===t)return n(null,i);if("string"!=typeof t)return n(new Error("Key "+t+" must be a string."));const o=s(i,t,null);if(null===o)return n(new Error("Key "+t+" does not exist in config."));n(null,o)})},set(e,n,r){if("function"==typeof n)r=n,n=e,e=void 0;else if(!e||"string"!=typeof e)return r(new Error("Invalid key type"));if(void 0===n||l.isBuffer(n))return r(new Error("Invalid value type"));t.push({key:e,value:n},r)},exists(t){e.has(u,t)}};return n;function r(e,t){const r=e.key,i=e.value;r?o([e=>n.get(e),(e,t)=>{a(e,r,i),t(null,e)},c],t):c(i,t)}function c(t,n){const r=l.from(JSON.stringify(t,null,2));e.put(u,r,n)}})},function(e,t){function n(e,t,n){"string"==typeof t&&(t=t.split(".")),"symbol"==typeof t&&(t=[t]);var r=t.pop(),i;if(!r)return!1;for(;i=t.shift();)if(void 0===e[i]&&(e[i]={}),e=e[i],!e||"object"!=typeof e)return!1;return e[r]=n,!0}e.exports=n},function(e,t,n){"use strict";(function(t){const r=n(28).Key,i=n(836),o=new r("datastore_spec");e.exports=(e=>({exists(t){e.has(o,t)},get(t){e.get(o,(e,n)=>{if(e)return t(e);t(null,JSON.parse(n.toString()))})},set(n,r){e.put(o,t.from(JSON.stringify(i(n,{deep:!0}))),r)}}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(351);e.exports=((e,t)=>{if(!r(e))throw new TypeError("Expected a plain object");if(t=t||{},"function"==typeof t)throw new TypeError("Specify the compare function as an option instead");const n=t.deep,i=[],o=[],s=e=>{const a=i.indexOf(e);if(-1!==a)return o[a];const l={},u=Object.keys(e).sort(t.compare);i.push(e),o.push(l);for(let t=0;t<u.length;t++){const i=u[t],o=e[i];if(n&&Array.isArray(o)){const e=[];for(let t=0;t<o.length;t++)e[t]=r(o[t])?s(o[t]):o[t];l[i]=e}else l[i]=n&&r(o)?s(o):o}return l};return s(e)})},function(e,t,n){"use strict";(function(t){const r=n(28).Key,i=new r("api");e.exports=(e=>({get(t){e.get(i,(e,n)=>t(e,n&&n.toString()))},set(n,r){e.put(i,t.from(n.toString()),r)},delete(t){e.delete(i,t)}}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(407),i=r.ShardingDatastore,o=n(28).Key,s=n(409),a=n(114),l=n(20),u=n(410),c=n(846),h=n(12),f=n(33),p=e=>{const t=new s.Encoder;return new o("/"+t.write(e).finalize(),!1)},d=e=>p(e.buffer);function m(e,t,n){if(t.sharding){const t=new r.shard.NextToLast(2);i.createOrOpen(e,t,n)}else l(()=>n(null,e))}function g(e){return{query(t,n){h(e.query(t),f(n))},get(t,n){if(!c.isCID(t))return l(()=>{n(new Error("Not a valid cid"))});const r=d(t);e.get(r,(i,o)=>{if(i){if("ERR_NOT_FOUND"===i.code){const o=y(t);if(!o)return n(i);const s=d(o);return e.get(s,(i,o)=>{if(i)return n(i);e.put(r,o,e=>{if(e)return n(e);n(null,new a(o,t))})})}return n(i)}n(null,new a(o,t))})},put(t,n){if(!a.isBlock(t))return l(()=>{n(new Error("invalid block"))});const r=d(t.cid);e.has(r,(i,o)=>i?n(i):o?n():void e.put(r,t.data,n))},putMany(t,n){const r=t.map(e=>({key:d(e.cid),block:e})),i=e.batch();u(r,(t,n)=>e.has(t.key,n),(e,t)=>{if(e)return n(e);t.forEach(e=>{i.put(e.key,e.block.data)}),i.commit(n)})},has(t,n){if(!c.isCID(t))return l(()=>{n(new Error("Not a valid cid"))});e.has(d(t),(r,i)=>{if(r)return n(r);if(i)return n(null,!0);const o=y(t);if(!o)return n(null,!1);e.has(d(o),n)})},delete(t,n){if(!c.isCID(t))return l(()=>{n(new Error("Not a valid cid"))});e.delete(d(t),n)},close(t){e.close(t)}}}function y(e){try{return 0===e.version?e.toV1():e.toV0()}catch(e){return null}}e.exports=((e,t,n)=>{m(e,t,(e,t)=>{if(e)return n(e);n(null,g(t))})})},function(e,t,n){"use strict";(function(t){const r=n(10),i=n(36),o=n(28).Key,s=n(408),a=n(203),l=new o(s.SHARDING_FN),u=new o(s.README_FN);class c{constructor(e,t){this.child=new a(e,{convert:this._convertKey.bind(this),invert:this._invertKey.bind(this)}),this.shard=t}open(e){this.child.open(e)}_convertKey(e){const t=e.toString();if(t===l.toString()||t===u.toString())return e;const n=new o(this.shard.fun(t));return n.child(e)}_invertKey(e){const t=e.toString();return t===l.toString()||t===u.toString()?e:o.withNamespaces(e.list().slice(1))}static createOrOpen(e,t,n){c.create(e,t,t=>{if(t&&"datastore exists"!==t.message)return n(t);c.open(e,n)})}static open(e,t){r([t=>s.readShardFun("/",e,t),(t,n)=>{n(null,new c(e,t))}],t)}static create(e,n,r){e.has(l,(o,a)=>{if(o)return r(o);if(!a){const o="function"==typeof e.putRaw?e.putRaw.bind(e):e.put.bind(e);return i([e=>o(l,t.from(n.toString()+"\n"),e),e=>o(u,t.from(s.readme),e)],e=>r(e))}s.readShardFun("/",e,(e,t)=>{if(e)return r(e);const i=(t||"").toString(),o=n.toString();if(i!==o)return r(new Error(`specified fun ${o} does not match repo shard fun ${i}`));r(new Error("datastore exists"))})})}put(e,t,n){this.child.put(e,t,n)}get(e,t){this.child.get(e,t)}has(e,t){this.child.has(e,t)}delete(e,t){this.child.delete(e,t)}batch(){return this.child.batch()}query(e){const t={keysOnly:e.keysOnly,offset:e.offset,limit:e.limit,filters:[(e,t)=>t(null,e.key.toString()!==l.toString()),(e,t)=>t(null,e.key.toString()!==u.toString())]};if(null!=e.prefix&&t.filters.push((t,n)=>{n(null,this._invertKey(t.key).toString().startsWith(e.prefix))}),null!=e.filters){const n=e.filters.map(e=>(t,n)=>{e(Object.assign({},t,{key:this._invertKey(t.key)}),n)});t.filters=t.filters.concat(n)}return null!=e.orders&&(t.orders=e.orders.map(e=>(t,n)=>{t.forEach(e=>{e.key=this._invertKey(e.key)}),e(t,(e,t)=>{if(e)return n(e);t.forEach(e=>{e.key=this._convertKey(e.key)}),n(null,t)})})),this.child.query(t)}close(e){this.child.close(e)}}e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports="This is a repository of IPLD objects. Each IPLD object is in a single file,\nnamed <base32 encoding of cid>.data. Where <base32 encoding of cid> is the\n\"base32\" encoding of the CID (as specified in\nhttps://github.com/multiformats/multibase) without the 'B' prefix.\nAll the object files are placed in a tree of directories, based on a\nfunction of the CID. This is a form of sharding similar to\nthe objects directory in git repositories. Previously, we used\nprefixes, we now use the next-to-last two charters.\n func NextToLast(base32cid string) {\n nextToLastLen := 2\n offset := len(base32cid) - nextToLastLen - 1\n return str[offset : offset+nextToLastLen]\n }\nFor example, an object with a base58 CIDv1 of\n zb2rhYSxw4ZjuzgCnWSt19Q94ERaeFhu9uSqRgjSdx9bsgM6f\nhas a base32 CIDv1 of\n BAFKREIA22FLID5AJ2KU7URG47MDLROZIH6YF2KALU2PWEFPVI37YLKRSCA\nand will be placed at\n SC/AFKREIA22FLID5AJ2KU7URG47MDLROZIH6YF2KALU2PWEFPVI37YLKRSCA.data\nwith 'SC' being the last-to-next two characters and the 'B' at the\nbeginning of the CIDv1 string is the multibase prefix that is not\nstored in the filename.\n"},function(e,t,n){"use strict";const r=n(38),i=n(842),o=n(19),s=n(28).Key,a=n(28).Errors,l=n(28).utils,u=l.asyncFilter,c=l.asyncSort,h=l.replaceStartWith,f=n(203);class p{constructor(e){this.mounts=e.slice()}open(e){r(this.mounts,(e,t)=>{e.datastore.open(t)},e)}_lookup(e){for(let t of this.mounts)if(t.prefix.toString()===e.toString()||t.prefix.isAncestorOf(e)){const n=h(e.toString(),t.prefix.toString());return{datastore:t.datastore,mountpoint:t.prefix,rest:new s(n)}}}put(e,t,n){const r=this._lookup(e);if(null==r)return n(a.dbWriteFailedError(new Error("No datastore mounted for this key")));r.datastore.put(r.rest,t,n)}get(e,t){const n=this._lookup(e);if(null==n)return t(a.notFoundError(new Error("No datastore mounted for this key")));n.datastore.get(n.rest,t)}has(e,t){const n=this._lookup(e);null!=n?n.datastore.has(n.rest,t):t(null,!1)}delete(e,t){const n=this._lookup(e);if(null==n)return t(a.dbDeleteFailedError(new Error("No datastore mounted for this key")));n.datastore.delete(n.rest,t)}close(e){r(this.mounts,(e,t)=>{e.datastore.close(t)},e)}batch(){const e={},t=t=>{const n=this._lookup(t);if(null==n)throw new Error("No datastore mounted for this key");const r=n.mountpoint.toString();return null==e[r]&&(e[r]=n.datastore.batch()),{batch:e[r],rest:n.rest}};return{put:(e,n)=>{const r=t(e);r.batch.put(r.rest,n)},delete:e=>{const n=t(e);n.batch.delete(n.rest)},commit:t=>{r(Object.keys(e),(t,n)=>{e[t].commit(n)},t)}}}query(e){const t=this.mounts.map(t=>{const n=new f(t.datastore,{convert:e=>{throw new Error("should never be called")},invert:e=>t.prefix.child(e)});let r;return null!=e.prefix&&(r=h(e.prefix,t.prefix.toString())),n.query({prefix:r,filters:e.filters,keysOnly:e.keysOnly})});let n=[i(t)];if(null!=e.filters&&(n=n.concat(e.filters.map(e=>u(e)))),null!=e.orders&&(n=n.concat(e.orders.map(e=>c(e)))),null!=e.offset){let t=0;n.push(o.filter(()=>t++>=e.offset))}return null!=e.limit&&n.push(o.take(e.limit)),o.apply(null,n)}}e.exports=p},function(e,t){e.exports=function(e){var t=!!e,n=(e||[]).map(s),r=0,i,o;function s(e){return{ready:!1,reading:!1,ended:!1,read:e,data:null}}function a(){if(o){l();var e=n.length,s=o;if(0===e&&(i||t))return o=null,void s(i||!0);for(var a=0;a<e;a++){var u=n[(r+a)%e];if(u.ready&&!u.ended){var c=u.data;return u.ready=!1,u.data=null,r++,o=null,s(null,c)}}}}function l(){for(var e=n.length;e--;)n[e].ended&&n.splice(e,1)}function u(){for(var e=n.length;e--;)!function(t){if(e>n.length)throw new Error("this should never happen");if(!(t.reading||t.ended||t.ready)){t.reading=!0;var r=!0;t.read(i,function e(n,o){t.data=o,t.ready=!0,t.reading=!1,!0===n||i?t.ended=!0:n&&(i=t.ended=n),i&&!n&&t.read(i,e),r||a()}),r=!1}}(n[e]);a()}function c(e,t){i=i||e,o=t,u()}return c.add=function(e){if(!e)return t=!0,u();n.push(s(e)),u()},c.cap=function(e){c.add(null)},c}},function(e,t,n){"use strict";const r=n(38),i=n(154),o=n(28).Errors;class s{constructor(e){this.stores=e.slice()}open(e){r(this.stores,(e,t)=>{e.open(t)},t=>{if(t)return e(o.dbOpenFailedError());e()})}put(e,t,n){r(this.stores,(n,r)=>{n.put(e,t,r)},e=>{if(e)return n(o.dbWriteFailedError());n()})}get(e,t){const n=this.stores.length;let r=!1,s=0;i(()=>!r&&s<n,t=>{const n=this.stores[s++];n.get(e,(e,n)=>{if(null==e)return r=!0,t(null,n);t()})},(e,n)=>{if(e||!n)return t(o.notFoundError());t(null,n)})}has(e,t){const n=this.stores.length;let r=!1,o=0;i(()=>!r&&o<n,t=>{const n=this.stores[o++];n.has(e,(e,n)=>{if(null==e)return r=!0,t(null,n);t()})},t)}delete(e,t){r(this.stores,(t,n)=>{t.delete(e,n)},e=>{if(e)return t(o.dbDeleteFailedError());t()})}close(e){r(this.stores,(e,t)=>{e.close(t)},e)}batch(){const e=this.stores.map(e=>e.batch());return{put:(t,n)=>{e.forEach(e=>e.put(t,n))},delete:t=>{e.forEach(e=>e.delete(t))},commit:t=>{r(e,(e,t)=>{e.commit(t)},t)}}}query(e){return this.stores[this.stores.length-1].query(e)}}e.exports=s},function(e,t,n){"use strict";const r=n(28).Key,i=n(203);class o extends i{constructor(e,t){super(e,{convert:e=>t.child(e),invert(e){if("/"===t.toString())return e;if(!t.isAncestorOf(e))throw new Error(`Expected prefix: (${t.toString()}) in key: ${e.toString()}`);return new r(e.toString().slice(t.toString().length),!1)}}),this.prefix=t}query(e){return e.prefix&&"/"!==this.prefix.toString()?super.query(Object.assign({},e,{prefix:this.prefix.child(new r(e.prefix)).toString()})):super.query(e)}}e.exports=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=n(411),i=o(r);function o(e){return e&&e.__esModule?e:{default:e}}function s(e,t,n,r){(0,i.default)(e,t,function(e,t){n(e,function(e,n){t(e,!n)})},r)}e.exports=t.default},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(60),o=n(115),s=n(95),a=n(847),l=n(39);class u{constructor(e,n,s,a){if(c.isCID(e)){const n=e;return this.version=n.version,this.codec=n.codec,this.multihash=t.from(n.multihash),void(this.multibaseName=n.multibaseName||(0===n.version?"base58btc":"base32"))}if("string"==typeof e){const t=i.isEncoded(e);if(t){const n=i.decode(e);this.version=parseInt(n.slice(0,1).toString("hex"),16),this.codec=o.getCodec(n.slice(1)),this.multihash=o.rmPrefix(n.slice(1)),this.multibaseName=t}else this.version=0,this.codec="dag-pb",this.multihash=r.fromB58String(e),this.multibaseName="base58btc";return u.validateCID(this),void Object.defineProperty(this,"string",{value:e})}if(t.isBuffer(e)){const t=e.slice(0,1),n=parseInt(t.toString("hex"),16);if(1===n){const t=e;this.version=n,this.codec=o.getCodec(t.slice(1)),this.multihash=o.rmPrefix(t.slice(1)),this.multibaseName="base32"}else this.version=0,this.codec="dag-pb",this.multihash=e,this.multibaseName="base58btc";u.validateCID(this)}else this.version=e,this.codec=n,this.multihash=s,this.multibaseName=a||(0===e?"base58btc":"base32"),u.validateCID(this)}get buffer(){let e=this._buffer;if(!e){if(0===this.version)e=this.multihash;else{if(1!==this.version)throw new Error("unsupported version");e=t.concat([t.from("01","hex"),o.getCodeVarint(this.codec),this.multihash])}Object.defineProperty(this,"_buffer",{value:e})}return e}get prefix(){return t.concat([t.from(`0${this.version}`,"hex"),o.getCodeVarint(this.codec),r.prefix(this.multihash)])}toV0(){if("dag-pb"!==this.codec)throw new Error("Cannot convert a non dag-pb CID to CIDv0");const{name:e,length:t}=r.decode(this.multihash);if("sha2-256"!==e)throw new Error("Cannot convert non sha2-256 multihash CID to CIDv0");if(32!==t)throw new Error("Cannot convert non 32 byte multihash CID to CIDv0");return new c(0,this.codec,this.multihash)}toV1(){return new c(1,this.codec,this.multihash)}toBaseEncodedString(e=this.multibaseName){if(this.string&&e===this.multibaseName)return this.string;let t=null;if(0===this.version){if("base58btc"!==e)throw new Error("not supported with CIDv0, to support different bases, please migrate the instance do CIDv1, you can do that through cid.toV1()");t=r.toB58String(this.multihash)}else{if(1!==this.version)throw new Error("unsupported version");t=i.encode(e,this.buffer).toString()}return e===this.multibaseName&&Object.defineProperty(this,"string",{value:t}),t}toString(e){return this.toBaseEncodedString(e)}toJSON(){return{codec:this.codec,version:this.version,hash:this.multihash}}equals(e){return this.codec===e.codec&&this.version===e.version&&this.multihash.equals(e.multihash)}static validateCID(e){let t=a.checkCIDComponents(e);if(t)throw new Error(t)}}const c=l(u,{className:"CID",symbolName:"@ipld/js-cid/CID"});c.codecs=s,e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(27);var i={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!t.isBuffer(e.multihash))return"multihash must be a Buffer";try{r.validate(e.multihash)}catch(e){let t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports={lock:"memory",storageBackends:{root:n(204),blocks:n(204),keys:n(204),datastore:n(204)},storageBackendOptions:{root:{extension:""},blocks:{sharding:!1},keys:{sharding:!1}}}},function(e,t,n){(function(t){var r=n(6).EventEmitter,i=n(14).inherits,o=n(68),s=n(850),a=n(853),l=n(854),u=n(263),c=n(24),h=n(417),f=n(205).getCallback,p=n(205).getOptions,d=u.WriteError,m=u.ReadError,g=u.NotFoundError,y=u.OpenError,v=u.InitializationError;function b(e,n,i){if(!(this instanceof b))return new b(e,n,i);var o;if(r.call(this),this.setMaxListeners(1/0),"function"==typeof n&&(i=n,n={}),n=n||{},!e||"object"!=typeof e){if(o=new v("First argument must be an abstract-leveldown compliant store"),"function"==typeof i)return t.nextTick(i,o);throw o}c.strictEqual(typeof e.status,"string",".status required, old abstract-leveldown"),this.options=p(n),this._db=e,this.db=new s(e),this.open(i)}function _(e,n){if(!e._isOpening()&&!e.isOpen())return t.nextTick(n,new m("Database is not open")),!0}b.prototype.emit=r.prototype.emit,b.prototype.once=r.prototype.once,i(b,r),b.prototype.open=function(e){var n=this,r;return e||(e=h(),r=e.promise),this.isOpen()?(t.nextTick(e,null,n),r):this._isOpening()?(this.once("open",function(){e(null,n)}),r):(this.emit("opening"),this.db.open(this.options,function(t){if(t)return e(new y(t));n.db=n._db,e(null,n),n.emit("open"),n.emit("ready")}),r)},b.prototype.close=function(e){var n=this,r;return e||(e=h(),r=e.promise),this.isOpen()?(this.db.close(function(){n.emit("closed"),e.apply(null,arguments)}),this.emit("closing"),this.db=new s(this._db)):this.isClosed()?t.nextTick(e):"closing"===this.db.status?this.once("closed",e):this._isOpening()&&this.once("open",function(){n.close(e)}),r},b.prototype.isOpen=function(){return"open"===this.db.status},b.prototype._isOpening=function(){return"opening"===this.db.status},b.prototype.isClosed=function(){return/^clos|new/.test(this.db.status)},b.prototype.get=function(e,t,n){if(null===e||void 0===e)throw new m("get() requires a key argument");var r;return n=f(t,n),n||(n=h(),r=n.promise),_(this,n)?r:(t=p(t),this.db.get(e,t,function(t,r){if(t)return t=/notfound/i.test(t)||t.notFound?new g("Key not found in database ["+e+"]",t):new m(t),n(t);n(null,r)}),r)},b.prototype.put=function(e,t,n,r){if(null===e||void 0===e)throw new d("put() requires a key argument");var i=this,o;return r=f(n,r),r||(r=h(),o=r.promise),_(this,r)?o:(n=p(n),this.db.put(e,t,n,function(n){if(n)return r(new d(n));i.emit("put",e,t),r()}),o)},b.prototype.del=function(e,t,n){if(null===e||void 0===e)throw new d("del() requires a key argument");var r=this,i;return n=f(t,n),n||(n=h(),i=n.promise),_(this,n)?i:(t=p(t),this.db.del(e,t,function(t){if(t)return n(new d(t));r.emit("del",e),n()}),i)},b.prototype.batch=function(e,t,n){if(!arguments.length)return new l(this);if(!Array.isArray(e))throw new d("batch() requires an array argument");var r=this,i;return n=f(t,n),n||(n=h(),i=n.promise),_(this,n)?i:(t=p(t),this.db.batch(e,t,function(t){if(t)return n(new d(t));r.emit("batch",e),n()}),i)},b.prototype.iterator=function(e){return this.db.iterator(e)},b.prototype.readStream=b.prototype.createReadStream=function(e){return e=o({keys:!0,values:!0},e),"number"!=typeof e.limit&&(e.limit=-1),new a(this.db.iterator(e),e)},b.prototype.keyStream=b.prototype.createKeyStream=function(e){return this.createReadStream(o(e,{keys:!0,values:!1}))},b.prototype.valueStream=b.prototype.createValueStream=function(e){return this.createReadStream(o(e,{keys:!1,values:!0}))},b.prototype.toString=function(){return"LevelUP"},b.errors=u,e.exports=b.default=b}).call(this,n(3))},function(e,t,n){var r=n(414).AbstractLevelDOWN,i=n(1),o=n(852),s="put get del batch".split(" ");function a(e){r.call(this,""),this._db=e,this._operations=[],this._iterators=[],u(this)}function l(e){s.concat("iterator").forEach(function(t){e["_"+t]=function(){return this._db[t].apply(this._db,arguments)}}),e._db.approximateSize&&(e.approximateSize=function(){return this._db.approximateSize.apply(this._db,arguments)})}function u(e){s.forEach(function(t){e["_"+t]=function(){this._operations.push({method:t,args:arguments})}}),"function"==typeof e._db.approximateSize&&(e.approximateSize=function(){this._operations.push({method:"approximateSize",args:arguments})}),e._iterator=function(e){var t=new o(e);return this._iterators.push(t),t}}i(a,r),a.prototype._open=function(e,t){var n=this;this._db.open(e,function(e){if(e)return t(e);n._operations.forEach(function(e){n._db[e.method].apply(n._db,e.args)}),n._operations=[],n._iterators.forEach(function(e){e.setDb(n._db)}),n._iterators=[],l(n),t()})},a.prototype._close=function(e){var t=this;this._db.close(function(n){if(n)return e(n);u(t),e()})},a.prototype._serializeKey=function(e){return e},a.prototype._serializeValue=function(e){return e},e.exports=a,e.exports.DeferredIterator=o},function(e,t,n){(function(t,r){var i=n(68),o=n(415),s=n(416),a=Object.prototype.hasOwnProperty,l="start end gt gte lt lte".split(" ");function u(){this.status="new"}function c(e,t){var n={};for(var r in t)if(a.call(t,r)){var i=t[r];h(r)&&(i=e._serializeKey(i)),n[r]=i}return n}function h(e){return-1!==l.indexOf(e)}u.prototype.open=function(e,t){var n=this,r=this.status;if("function"==typeof e&&(t=e),"function"!=typeof t)throw new Error("open() requires a callback argument");"object"==typeof e&&null!==e||(e={}),e.createIfMissing=!1!==e.createIfMissing,e.errorIfExists=!!e.errorIfExists,this.status="opening",this._open(e,function(e){if(e)return n.status=r,t(e);n.status="open",t()})},u.prototype._open=function(e,n){t.nextTick(n)},u.prototype.close=function(e){var t=this,n=this.status;if("function"!=typeof e)throw new Error("close() requires a callback argument");this.status="closing",this._close(function(r){if(r)return t.status=n,e(r);t.status="closed",e()})},u.prototype._close=function(e){t.nextTick(e)},u.prototype.get=function(e,n,r){if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("get() requires a callback argument");var i=this._checkKey(e);if(i)return t.nextTick(r,i);e=this._serializeKey(e),"object"==typeof n&&null!==n||(n={}),n.asBuffer=!1!==n.asBuffer,this._get(e,n,r)},u.prototype._get=function(e,n,r){t.nextTick(function(){r(new Error("NotFound"))})},u.prototype.put=function(e,n,r,i){if("function"==typeof r&&(i=r),"function"!=typeof i)throw new Error("put() requires a callback argument");var o=this._checkKey(e)||this._checkValue(n);if(o)return t.nextTick(i,o);e=this._serializeKey(e),n=this._serializeValue(n),"object"==typeof r&&null!==r||(r={}),this._put(e,n,r,i)},u.prototype._put=function(e,n,r,i){t.nextTick(i)},u.prototype.del=function(e,n,r){if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("del() requires a callback argument");var i=this._checkKey(e);if(i)return t.nextTick(r,i);e=this._serializeKey(e),"object"==typeof n&&null!==n||(n={}),this._del(e,n,r)},u.prototype._del=function(e,n,r){t.nextTick(r)},u.prototype.batch=function(e,n,r){if(!arguments.length)return this._chainedBatch();if("function"==typeof n&&(r=n),"function"==typeof e&&(r=e),"function"!=typeof r)throw new Error("batch(array) requires a callback argument");if(!Array.isArray(e))return t.nextTick(r,new Error("batch(array) requires an array argument"));if(0===e.length)return t.nextTick(r);"object"==typeof n&&null!==n||(n={});for(var o=new Array(e.length),s=0;s<e.length;s++){if("object"!=typeof e[s]||null===e[s])return t.nextTick(r,new Error("batch(array) element must be an object and not `null`"));var a=i(e[s]);if("put"!==a.type&&"del"!==a.type)return t.nextTick(r,new Error("`type` must be 'put' or 'del'"));var l=this._checkKey(a.key);if(l)return t.nextTick(r,l);if(a.key=this._serializeKey(a.key),"put"===a.type){var u=this._checkValue(a.value);if(u)return t.nextTick(r,u);a.value=this._serializeValue(a.value)}o[s]=a}this._batch(o,n,r)},u.prototype._batch=function(e,n,r){t.nextTick(r)},u.prototype._setupIteratorOptions=function(e){return e=c(this,e),e.reverse=!!e.reverse,e.keys=!1!==e.keys,e.values=!1!==e.values,e.limit="limit"in e?e.limit:-1,e.keyAsBuffer=!1!==e.keyAsBuffer,e.valueAsBuffer=!1!==e.valueAsBuffer,e},u.prototype.iterator=function(e){return"object"==typeof e&&null!==e||(e={}),e=this._setupIteratorOptions(e),this._iterator(e)},u.prototype._iterator=function(e){return new o(this)},u.prototype._chainedBatch=function(){return new s(this)},u.prototype._serializeKey=function(e){return e},u.prototype._serializeValue=function(e){return e},u.prototype._checkKey=function(e){return null===e||void 0===e?new Error("key cannot be `null` or `undefined`"):r.isBuffer(e)&&0===e.length?new Error("key cannot be an empty Buffer"):""===e?new Error("key cannot be an empty String"):Array.isArray(e)&&0===e.length?new Error("key cannot be an empty Array"):void 0},u.prototype._checkValue=function(e){if(null===e||void 0===e)return new Error("value cannot be `null` or `undefined`")},e.exports=u}).call(this,n(3),n(0).Buffer)},function(e,t,n){var r=n(414).AbstractIterator,i=n(1);function o(e){r.call(this,e),this._options=e,this._iterator=null,this._operations=[]}i(o,r),o.prototype.setDb=function(e){var t=this._iterator=e.iterator(this._options);this._operations.forEach(function(e){t[e.method].apply(t,e.args)})},o.prototype._operation=function(e,t){if(this._iterator)return this._iterator[e].apply(this._iterator,t);this._operations.push({method:e,args:t})},"next end".split(" ").forEach(function(e){o.prototype["_"+e]=function(){this._operation(e,arguments)}}),e.exports=o},function(e,t,n){var r=n(1),i=n(17).Readable,o=n(68);function s(e,t){if(!(this instanceof s))return new s(e,t);t=t||{},i.call(this,o(t,{objectMode:!0})),this._iterator=e,this._options=t,this.on("end",this.destroy.bind(this,null,null))}e.exports=s,r(s,i),s.prototype._read=function(){var e=this,t=this._options;this.destroyed||this._iterator.next(function(n,r,i){if(!e.destroyed)return n?e.destroy(n):void(void 0===r&&void 0===i?e.push(null):!1!==t.keys&&!1===t.values?e.push(r):!1===t.keys&&!1!==t.values?e.push(i):e.push({key:r,value:i}))})},s.prototype._destroy=function(e,t){this._iterator.end(function(n){t(e||n)})}},function(e,t,n){var r=n(263).WriteError,i=n(417),o=n(205).getCallback,s=n(205).getOptions;function a(e){this._levelup=e,this.batch=e.db.batch(),this.ops=[],this.length=0}a.prototype.put=function(e,t){try{this.batch.put(e,t)}catch(e){throw new r(e)}return this.ops.push({type:"put",key:e,value:t}),this.length++,this},a.prototype.del=function(e){try{this.batch.del(e)}catch(e){throw new r(e)}return this.ops.push({type:"del",key:e}),this.length++,this},a.prototype.clear=function(){try{this.batch.clear()}catch(e){throw new r(e)}return this.ops=[],this.length=0,this},a.prototype.write=function(e,t){var n=this._levelup,a=this.ops,l;t=o(e,t),t||(t=i(),l=t.promise),e=s(e);try{this.batch.write(e,function(e){if(e)return t(new r(e));n.emit("batch",a),t()})}catch(e){throw new r(e)}return l},e.exports=a},function(e,t,n){var r=e.exports.all=[{errno:-2,code:"ENOENT",description:"no such file or directory"},{errno:-1,code:"UNKNOWN",description:"unknown error"},{errno:0,code:"OK",description:"success"},{errno:1,code:"EOF",description:"end of file"},{errno:2,code:"EADDRINFO",description:"getaddrinfo error"},{errno:3,code:"EACCES",description:"permission denied"},{errno:4,code:"EAGAIN",description:"resource temporarily unavailable"},{errno:5,code:"EADDRINUSE",description:"address already in use"},{errno:6,code:"EADDRNOTAVAIL",description:"address not available"},{errno:7,code:"EAFNOSUPPORT",description:"address family not supported"},{errno:8,code:"EALREADY",description:"connection already in progress"},{errno:9,code:"EBADF",description:"bad file descriptor"},{errno:10,code:"EBUSY",description:"resource busy or locked"},{errno:11,code:"ECONNABORTED",description:"software caused connection abort"},{errno:12,code:"ECONNREFUSED",description:"connection refused"},{errno:13,code:"ECONNRESET",description:"connection reset by peer"},{errno:14,code:"EDESTADDRREQ",description:"destination address required"},{errno:15,code:"EFAULT",description:"bad address in system call argument"},{errno:16,code:"EHOSTUNREACH",description:"host is unreachable"},{errno:17,code:"EINTR",description:"interrupted system call"},{errno:18,code:"EINVAL",description:"invalid argument"},{errno:19,code:"EISCONN",description:"socket is already connected"},{errno:20,code:"EMFILE",description:"too many open files"},{errno:21,code:"EMSGSIZE",description:"message too long"},{errno:22,code:"ENETDOWN",description:"network is down"},{errno:23,code:"ENETUNREACH",description:"network is unreachable"},{errno:24,code:"ENFILE",description:"file table overflow"},{errno:25,code:"ENOBUFS",description:"no buffer space available"},{errno:26,code:"ENOMEM",description:"not enough memory"},{errno:27,code:"ENOTDIR",description:"not a directory"},{errno:28,code:"EISDIR",description:"illegal operation on a directory"},{errno:29,code:"ENONET",description:"machine is not on the network"},{errno:31,code:"ENOTCONN",description:"socket is not connected"},{errno:32,code:"ENOTSOCK",description:"socket operation on non-socket"},{errno:33,code:"ENOTSUP",description:"operation not supported on socket"},{errno:34,code:"ENOENT",description:"no such file or directory"},{errno:35,code:"ENOSYS",description:"function not implemented"},{errno:36,code:"EPIPE",description:"broken pipe"},{errno:37,code:"EPROTO",description:"protocol error"},{errno:38,code:"EPROTONOSUPPORT",description:"protocol not supported"},{errno:39,code:"EPROTOTYPE",description:"protocol wrong type for socket"},{errno:40,code:"ETIMEDOUT",description:"connection timed out"},{errno:41,code:"ECHARSET",description:"invalid Unicode character"},{errno:42,code:"EAIFAMNOSUPPORT",description:"address family for hostname not supported"},{errno:44,code:"EAISERVICE",description:"servname not supported for ai_socktype"},{errno:45,code:"EAISOCKTYPE",description:"ai_socktype not supported"},{errno:46,code:"ESHUTDOWN",description:"cannot send after transport endpoint shutdown"},{errno:47,code:"EEXIST",description:"file already exists"},{errno:48,code:"ESRCH",description:"no such process"},{errno:49,code:"ENAMETOOLONG",description:"name too long"},{errno:50,code:"EPERM",description:"operation not permitted"},{errno:51,code:"ELOOP",description:"too many symbolic links encountered"},{errno:52,code:"EXDEV",description:"cross-device link not permitted"},{errno:53,code:"ENOTEMPTY",description:"directory not empty"},{errno:54,code:"ENOSPC",description:"no space left on device"},{errno:55,code:"EIO",description:"i/o error"},{errno:56,code:"EROFS",description:"read-only file system"},{errno:57,code:"ENODEV",description:"no such device"},{errno:58,code:"ESPIPE",description:"invalid seek"},{errno:59,code:"ECANCELED",description:"operation canceled"}];e.exports.errno={},e.exports.code={},r.forEach(function(t){e.exports.errno[t.errno]=t,e.exports.code[t.code]=t}),e.exports.custom=n(856)(e.exports),e.exports.create=e.exports.custom.createError},function(e,t,n){var r=n(857);function i(e,t,n){t&&"string"!=typeof t&&(t=t.message||t.name),r(this,{type:e,name:e,cause:"string"!=typeof t?t:n,message:t},"ewr")}function o(e,t){Error.call(this),Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor),i.call(this,"CustomError",e,t)}function s(e,t,n){var r=function(n,o){i.call(this,t,n,o),"FilesystemError"==t&&(this.code=this.cause.code,this.path=this.cause.path,this.errno=this.cause.errno,this.message=(e.errno[this.cause.errno]?e.errno[this.cause.errno].description:this.cause.message)+(this.cause.path?" ["+this.cause.path+"]":"")),Error.call(this),Error.captureStackTrace&&Error.captureStackTrace(this,r)};return r.prototype=n?new n:new o,r}o.prototype=new Error,e.exports=function(e){var t=function(t,n){return s(e,t,n)};return{CustomError:o,FilesystemError:t("FilesystemError"),createError:t}}},function(e,t,n){
/*!
* prr
* (c) 2013 Rod Vagg <rod@vagg.org>
* https://github.com/rvagg/prr
* License: MIT
*/
var r,i,o;r="prr",i=this,o=function(){var e="function"==typeof Object.defineProperty?function(e,t,n){return Object.defineProperty(e,t,n),e}:function(e,t,n){return e[t]=n.value,e},t=function(e,t){var n="object"==typeof t,r=!n&&"string"==typeof t,i=function(e){return n?!!t[e]:!!r&&t.indexOf(e[0])>-1};return{enumerable:i("enumerable"),configurable:i("configurable"),writable:i("writable"),value:e}},n=function(n,r,i,o){var s;if(o=t(i,o),"object"==typeof r){for(s in r)Object.hasOwnProperty.call(r,s)&&(o.value=r[s],e(n,s,o));return n}return e(n,r,o)};return n},e.exports?e.exports=o():i.prr=o()},function(e,t,n){"use strict";var r=n(264).AbstractLevelDOWN,i=n(264).AbstractChainedBatch,o=n(264).AbstractIterator,s=n(1),a=n(860),l=n(263).EncodingError;function u(e,t){if(!(this instanceof u))return new u(e,t);r.call(this,""),t=t||{},void 0===t.keyEncoding&&(t.keyEncoding="utf8"),void 0===t.valueEncoding&&(t.valueEncoding="utf8"),this.db=e,this.codec=new a(t)}function c(e,t){o.call(this,e),this.codec=e.codec,this.keys=t.keys,this.values=t.values,this.opts=this.codec.encodeLtgt(t),this.it=e.db.iterator(this.opts)}function h(e,t){i.call(this,e),this.codec=e.codec,this.batch=e.db.batch()}e.exports=u.default=u,s(u,r),u.prototype._serializeKey=u.prototype._serializeValue=function(e){return e},u.prototype._open=function(e,t){this.db.open(e,t)},u.prototype._close=function(e){this.db.close(e)},u.prototype._put=function(e,t,n,r){e=this.codec.encodeKey(e,n),t=this.codec.encodeValue(t,n),this.db.put(e,t,n,r)},u.prototype._get=function(e,t,n){var r=this;e=this.codec.encodeKey(e,t),t.asBuffer=this.codec.valueAsBuffer(t),this.db.get(e,t,function(e,i){if(e)return n(e);try{i=r.codec.decodeValue(i,t)}catch(e){return n(new l(e))}n(null,i)})},u.prototype._del=function(e,t,n){e=this.codec.encodeKey(e,t),this.db.del(e,t,n)},u.prototype._chainedBatch=function(){return new h(this)},u.prototype._batch=function(e,t,n){e=this.codec.encodeBatch(e,t),this.db.batch(e,t,n)},u.prototype._iterator=function(e){return e.keyAsBuffer=this.codec.keyAsBuffer(e),e.valueAsBuffer=this.codec.valueAsBuffer(e),new c(this,e)},u.prototype.approximateSize=function(e,t,n,r){return e=this.codec.encodeKey(e,n),t=this.codec.encodeKey(t,n),this.db.approximateSize(e,t,n,r)},s(c,o),c.prototype._next=function(e){var t=this;this.it.next(function(n,r,i){if(n)return e(n);try{r=t.keys&&void 0!==r?t.codec.decodeKey(r,t.opts):void 0,i=t.values&&void 0!==i?t.codec.decodeValue(i,t.opts):void 0}catch(n){return e(new l(n))}e(null,r,i)})},c.prototype._seek=function(e){e=this.codec.encodeKey(e,this.opts),this.it.seek(e)},c.prototype._end=function(e){this.it.end(e)},s(h,i),h.prototype._put=function(e,t){e=this.codec.encodeKey(e),t=this.codec.encodeValue(t),this.batch.put(e,t)},h.prototype._del=function(e){e=this.codec.encodeKey(e),this.batch.del(e)},h.prototype._clear=function(){this.batch.clear()},h.prototype._write=function(e,t){this.batch.write(e,t)}},function(e,t,n){(function(t,r){var i=n(68),o=n(418),s=n(419),a=Object.prototype.hasOwnProperty,l="start end gt gte lt lte".split(" ");function u(){this.status="new"}function c(e,t){var n={};for(var r in t)if(a.call(t,r)){var i=t[r];h(r)&&(i=e._serializeKey(i)),n[r]=i}return n}function h(e){return-1!==l.indexOf(e)}u.prototype.open=function(e,t){var n=this,r=this.status;if("function"==typeof e&&(t=e),"function"!=typeof t)throw new Error("open() requires a callback argument");"object"==typeof e&&null!==e||(e={}),e.createIfMissing=!1!==e.createIfMissing,e.errorIfExists=!!e.errorIfExists,this.status="opening",this._open(e,function(e){if(e)return n.status=r,t(e);n.status="open",t()})},u.prototype._open=function(e,n){t.nextTick(n)},u.prototype.close=function(e){var t=this,n=this.status;if("function"!=typeof e)throw new Error("close() requires a callback argument");this.status="closing",this._close(function(r){if(r)return t.status=n,e(r);t.status="closed",e()})},u.prototype._close=function(e){t.nextTick(e)},u.prototype.get=function(e,n,r){if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("get() requires a callback argument");var i=this._checkKey(e);if(i)return t.nextTick(r,i);e=this._serializeKey(e),"object"==typeof n&&null!==n||(n={}),n.asBuffer=!1!==n.asBuffer,this._get(e,n,r)},u.prototype._get=function(e,n,r){t.nextTick(function(){r(new Error("NotFound"))})},u.prototype.put=function(e,n,r,i){if("function"==typeof r&&(i=r),"function"!=typeof i)throw new Error("put() requires a callback argument");var o=this._checkKey(e)||this._checkValue(n);if(o)return t.nextTick(i,o);e=this._serializeKey(e),n=this._serializeValue(n),"object"==typeof r&&null!==r||(r={}),this._put(e,n,r,i)},u.prototype._put=function(e,n,r,i){t.nextTick(i)},u.prototype.del=function(e,n,r){if("function"==typeof n&&(r=n),"function"!=typeof r)throw new Error("del() requires a callback argument");var i=this._checkKey(e);if(i)return t.nextTick(r,i);e=this._serializeKey(e),"object"==typeof n&&null!==n||(n={}),this._del(e,n,r)},u.prototype._del=function(e,n,r){t.nextTick(r)},u.prototype.batch=function(e,n,r){if(!arguments.length)return this._chainedBatch();if("function"==typeof n&&(r=n),"function"==typeof e&&(r=e),"function"!=typeof r)throw new Error("batch(array) requires a callback argument");if(!Array.isArray(e))return t.nextTick(r,new Error("batch(array) requires an array argument"));if(0===e.length)return t.nextTick(r);"object"==typeof n&&null!==n||(n={});for(var o=new Array(e.length),s=0;s<e.length;s++){if("object"!=typeof e[s]||null===e[s])return t.nextTick(r,new Error("batch(array) element must be an object and not `null`"));var a=i(e[s]);if("put"!==a.type&&"del"!==a.type)return t.nextTick(r,new Error("`type` must be 'put' or 'del'"));var l=this._checkKey(a.key);if(l)return t.nextTick(r,l);if(a.key=this._serializeKey(a.key),"put"===a.type){var u=this._checkValue(a.value);if(u)return t.nextTick(r,u);a.value=this._serializeValue(a.value)}o[s]=a}this._batch(o,n,r)},u.prototype._batch=function(e,n,r){t.nextTick(r)},u.prototype._setupIteratorOptions=function(e){return e=c(this,e),e.reverse=!!e.reverse,e.keys=!1!==e.keys,e.values=!1!==e.values,e.limit="limit"in e?e.limit:-1,e.keyAsBuffer=!1!==e.keyAsBuffer,e.valueAsBuffer=!1!==e.valueAsBuffer,e},u.prototype.iterator=function(e){return"object"==typeof e&&null!==e||(e={}),e=this._setupIteratorOptions(e),this._iterator(e)},u.prototype._iterator=function(e){return new o(this)},u.prototype._chainedBatch=function(){return new s(this)},u.prototype._serializeKey=function(e){return e},u.prototype._serializeValue=function(e){return e},u.prototype._checkKey=function(e){return null===e||void 0===e?new Error("key cannot be `null` or `undefined`"):r.isBuffer(e)&&0===e.length?new Error("key cannot be an empty Buffer"):""===e?new Error("key cannot be an empty String"):Array.isArray(e)&&0===e.length?new Error("key cannot be an empty Array"):void 0},u.prototype._checkValue=function(e){if(null===e||void 0===e)return new Error("value cannot be `null` or `undefined`")},e.exports=u}).call(this,n(3),n(0).Buffer)},function(e,t,n){var r=n(861);function i(e){if(!(this instanceof i))return new i(e);this.opts=e||{},this.encodings=r}e.exports=i,i.prototype._encoding=function(e){return"string"==typeof e&&(e=r[e]),e||(e=r.id),e},i.prototype._keyEncoding=function(e,t){return this._encoding(t&&t.keyEncoding||e&&e.keyEncoding||this.opts.keyEncoding)},i.prototype._valueEncoding=function(e,t){return this._encoding(t&&(t.valueEncoding||t.encoding)||e&&(e.valueEncoding||e.encoding)||this.opts.valueEncoding||this.opts.encoding)},i.prototype.encodeKey=function(e,t,n){return this._keyEncoding(t,n).encode(e)},i.prototype.encodeValue=function(e,t,n){return this._valueEncoding(t,n).encode(e)},i.prototype.decodeKey=function(e,t){return this._keyEncoding(t).decode(e)},i.prototype.decodeValue=function(e,t){return this._valueEncoding(t).decode(e)},i.prototype.encodeBatch=function(e,t){var n=this;return e.map(function(e){var r={type:e.type,key:n.encodeKey(e.key,t,e)};return n.keyAsBuffer(t,e)&&(r.keyEncoding="binary"),e.prefix&&(r.prefix=e.prefix),"value"in e&&(r.value=n.encodeValue(e.value,t,e),n.valueAsBuffer(t,e)&&(r.valueEncoding="binary")),r})};var o=["lt","gt","lte","gte","start","end"];i.prototype.encodeLtgt=function(e){var t=this,n={};return Object.keys(e).forEach(function(r){n[r]=o.indexOf(r)>-1?t.encodeKey(e[r],e):e[r]}),n},i.prototype.createStreamDecoder=function(e){var t=this;return e.keys&&e.values?function(n,r){return{key:t.decodeKey(n,e),value:t.decodeValue(r,e)}}:e.keys?function(n){return t.decodeKey(n,e)}:e.values?function(n,r){return t.decodeValue(r,e)}:function(){}},i.prototype.keyAsBuffer=function(e){return this._keyEncoding(e).buffer},i.prototype.valueAsBuffer=function(e){return this._valueEncoding(e).buffer}},function(e,t,n){(function(e){t.utf8=t["utf-8"]={encode:function(e){return i(e)?e:String(e)},decode:r,buffer:!1,type:"utf8"},t.json={encode:JSON.stringify,decode:JSON.parse,buffer:!1,type:"json"},t.binary={encode:function(t){return i(t)?t:e.from(t)},decode:r,buffer:!0,type:"binary"},t.none={encode:r,decode:r,buffer:!1,type:"id"},t.id=t.none;var n=["hex","ascii","base64","ucs2","ucs-2","utf16le","utf-16le"];function r(e){return e}function i(t){return void 0===t||null===t||e.isBuffer(t)}n.forEach(function(n){t[n]={encode:function(t){return i(t)?t:e.from(t,n)},decode:function(e){return e.toString(n)},buffer:!0,type:n}})}).call(this,n(0).Buffer)},function(e,t,n){(function(t,r){e.exports=l;var i=n(420).AbstractLevelDOWN,o=n(14),s=n(864),a=n(68);function l(e){if(!(this instanceof l))return new l(e);i.call(this,e)}o.inherits(l,i),l.prototype._open=function(e,t){var n=this;if(this._idbOpts=a({storeName:this.location,keyEncoding:"none",valueEncoding:"none"},e),this._idbOpts.idb)o(this._idbOpts.idb);else{var r=indexedDB.open(this.location);r.onerror=i,r.onsuccess=function(){o(r.result)}}function i(e){t(e.target.error)}function o(r){n._db=r;var i=n._db.objectStoreNames.contains(n._idbOpts.storeName);if(e.errorIfExists&&i)return n._db.close(),void t(new Error("store already exists"));if(!e.createIfMissing&&!i)return n._db.close(),void t(new Error("store does not exist"));if(e.createIfMissing&&!i){n._db.close();var o=indexedDB.open(n.location,n._db.version+1);return o.onerror=function(e){t(e.target.error)},o.onupgradeneeded=function(){var e=o.result;e.createObjectStore(n._idbOpts.storeName,n._idbOpts)},void(o.onsuccess=function(){n._db=o.result,t(null,n)})}t(null,n)}},l.prototype._get=function(e,n,r){n=a(this._idbOpts,n);var i=e;"binary"!==n.keyEncoding||Array.isArray(e)||(e=Array.prototype.slice.call(e));var o=this._db.transaction(this._idbOpts.storeName),s=o.objectStore(this._idbOpts.storeName).openCursor(IDBKeyRange.only(e));o.onabort=function(){r(o.error)},s.onsuccess=function(){var e=s.result;if(e){var o=e.value;if(o instanceof Uint8Array&&(o=new t(o)),"binary"!==n.valueEncoding||t.isBuffer(o)||(o=new t(o)),n.asBuffer&&!t.isBuffer(o))if(null==o)o=new t(0);else if("string"==typeof o)o=new t(o);else if("boolean"==typeof o)o=new t(String(o));else if("number"==typeof o)o=new t(String(o));else if(Array.isArray(o))o=new t(String(o));else{if(!(o instanceof Uint8Array))return void r(new TypeError("can't coerce `"+o.constructor.name+"` into a Buffer"));o=new t(o)}r(null,o,i)}else r(new Error("NotFound"))}},l.prototype._del=function(e,t,n){t=a(this._idbOpts,t),"binary"!==t.keyEncoding||Array.isArray(e)||(e=Array.prototype.slice.call(e));var r="readwrite";!0===t.sync&&(r="readwriteflush");var i=this._db.transaction(this._idbOpts.storeName,r),o=i.objectStore(this._idbOpts.storeName).delete(e);i.onabort=function(){n(i.error)},i.oncomplete=function(){n()}},l.prototype._put=function(e,t,n,r){n=a(this._idbOpts,n),"binary"!==n.keyEncoding||Array.isArray(e)||(e=Array.prototype.slice.call(e));var i="readwrite";!0===n.sync&&(i="readwriteflush");var o=this._db.transaction(this._idbOpts.storeName,i),s=o.objectStore(this._idbOpts.storeName).put(t,e);o.onabort=function(){r(o.error)},o.oncomplete=function(){r()}},l.prototype._iterator=function(e){return new s(this,e)},l.prototype._batch=function(e,t,n){if(0===e.length)return r.nextTick(n);var i="readwrite";!0===t.sync&&(i="readwriteflush");var o=this._db.transaction(this._idbOpts.storeName,i),s=o.objectStore(this._idbOpts.storeName);o.onabort=function(){n(o.error)},o.oncomplete=function(){n()},e.forEach(function(e){var n=a(t,e);"binary"!==n.keyEncoding||Array.isArray(e.key)||(e.key=Array.prototype.slice.call(e.key)),"del"===e.type?s.delete(e.key):s.put(e.value,e.key)})},l.prototype._close=function(e){this._db.close(),r.nextTick(e)},l.prototype._approximateSize=function(e,t,n){var i=new Error("Not implemented");if(!n)throw i;r.nextTick(function(){n(i)})},l.destroy=function(e,t){var n;if(null!=e&&"object"==typeof e)n=a({location:e.location,storeName:e.location},e._idbOpts);else{if("string"!=typeof e)throw new TypeError("location must be a string or an object");n={location:e,storeName:e}}if("string"!=typeof n.location)throw new TypeError("location must be a string");if("string"!=typeof n.storeName)throw new TypeError("db.storeName must be a string");var r=indexedDB.open(n.location);r.onerror=function(e){t(e.target.error)},r.onsuccess=function(){var e=r.result;function i(e){var n=indexedDB.deleteDatabase(e);n.onerror=function(e){t(e.target.error)},n.onsuccess=function(){t()}}if(e.close(),0!==e.objectStoreNames.length)if(e.objectStoreNames.contains(n.storeName)){var o=indexedDB.open(n.location,e.version+1);o.onerror=function(e){t(e.target.error)},o.onupgradeneeded=function(){e=o.result,e.deleteObjectStore(n.storeName)},o.onsuccess=function(){e=o.result,e.close(),0===e.objectStoreNames.length?i(n.location):t()}}else t();else i(n.location)}}}).call(this,n(0).Buffer,n(3))},function(e,t,n){var r=n(421);function i(e){return!(!e||"object"!=typeof e)&&Object.keys(r.prototype).filter(function(e){return"_"!=e[0]&&"approximateSize"!=e}).every(function(t){return"function"==typeof e[t]})}e.exports=i},function(e,t,n){(function(t,r){var i=n(14),o=n(420).AbstractIterator,s=n(865),a=n(866),l=n(62),u=n(68),c=l.Writable;function h(e,t){if(this._db=e._db,this._idbOpts=e._idbOpts,o.call(this,e),this._options=u({snapshot:!0},this._idbOpts,t),this._limit=this._options.limit,null!=this._limit&&-1!==this._limit||(this._limit=1/0),"number"!=typeof this._limit)throw new TypeError("options.limit must be a number");0!==this._limit&&(this._count=0,this._startCursor(this._options))}e.exports=h,i.inherits(h,o),h.prototype._startCursor=function(e){e=u(this._options,e);var t=this,n=null,r=s.lowerBound(e),i=s.upperBound(e),o=s.lowerBoundExclusive(e),l=s.upperBoundExclusive(e),h=e.reverse?"prev":"next";if(r&&("binary"!==e.keyEncoding||Array.isArray(r)||(r=Array.prototype.slice.call(r))),i&&("binary"!==e.keyEncoding||Array.isArray(i)||(i=Array.prototype.slice.call(i))),r&&i)try{n=IDBKeyRange.bound(r,i,o,l)}catch(e){return void(this._keyRangeError=!0)}else r?n=IDBKeyRange.lowerBound(r,o):i&&(n=IDBKeyRange.upperBound(i,l));this._reader=a(this._db,this._idbOpts.storeName,u(e,{range:n,direction:h})),this._reader.on("error",function(e){var n=t._callback;t._callback=!1,n?n(e):t._readNext=function(t){t(e)}}),this._reader.pipe(new c({objectMode:!0,write:function(e,n,r){if(t._count++>=t._limit)return t._reader.pause(),t._reader.unpipe(this),r(),void this.end();var i=t._callback;t._callback=!1,i?t._processItem(e,function(e,t,n){r(e),i(e,t,n)}):t._readNext=function(n){t._processItem(e,function(e,t,i){r(e),n(e,t,i)})}}})).on("finish",function(){var e=t._callback;t._callback=!1,e?e():t._readNext=function(e){e()}})},h.prototype._processItem=function(e,n){if("function"!=typeof n)throw new TypeError("cb must be a function");var r=e.key,i=e.value;if(i instanceof Uint8Array&&(i=new t(i)),"binary"===this._options.keyEncoding&&Array.isArray(r)&&(r=new t(r)),"binary"!==this._options.valueEncoding||t.isBuffer(i)||(i=new t(i)),this._options.keyAsBuffer&&!t.isBuffer(r))if(null==r)r=new t(0);else if("string"==typeof r)r=new t(r);else if("boolean"==typeof r)r=new t(String(r));else if("number"==typeof r)r=new t(String(r));else if(Array.isArray(r))r=new t(String(r));else{if(!(r instanceof Uint8Array))throw new TypeError("can't coerce `"+r.constructor.name+"` into a Buffer");r=new t(r)}if(this._options.valueAsBuffer&&!t.isBuffer(i))if(null==i)i=new t(0);else if("string"==typeof i)i=new t(i);else if("boolean"==typeof i)i=new t(String(i));else if("number"==typeof i)i=new t(String(i));else if(Array.isArray(i))i=new t(String(i));else{if(!(i instanceof Uint8Array))throw new TypeError("can't coerce `"+i.constructor.name+"` into a Buffer");i=new t(i)}n(null,r,i)},h.prototype._next=function(e){if(this._callback)throw new Error("callback already exists");if(this._keyRangeError||0===this._limit)e();else{var t=this._readNext;this._readNext=!1,t?r.nextTick(function(){t(e)}):this._callback=e}}}).call(this,n(0).Buffer,n(3))},function(e,t,n){(function(e){function n(e){return void 0!==e&&""!==e}function r(e,t){return Object.hasOwnProperty.call(e,t)}function i(e,t){return Object.hasOwnProperty.call(e,t)&&t}t.compare=function(t,n){if(e.isBuffer(t)){for(var r=Math.min(t.length,n.length),i=0;i<r;i++){var o=t[i]-n[i];if(o)return o}return t.length-n.length}return t<n?-1:t>n?1:0};var o=t.lowerBoundKey=function(e){return i(e,"gt")||i(e,"gte")||i(e,"min")||(e.reverse?i(e,"end"):i(e,"start"))||void 0},s=t.lowerBound=function(e,t){var n=o(e);return n?e[n]:t},a=t.lowerBoundInclusive=function(e){return!r(e,"gt")},l=t.upperBoundInclusive=function(e){return!r(e,"lt")},u=t.lowerBoundExclusive=function(e){return!a(e)},c=t.upperBoundExclusive=function(e){return!l(e)},h=t.upperBoundKey=function(e){return i(e,"lt")||i(e,"lte")||i(e,"max")||(e.reverse?i(e,"start"):i(e,"end"))||void 0},f=t.upperBound=function(e,t){var n=h(e);return n?e[n]:t};function p(e){return e}t.start=function(e,t){return e.reverse?f(e,t):s(e,t)},t.end=function(e,t){return e.reverse?s(e,t):f(e,t)},t.startInclusive=function(e){return e.reverse?l(e):a(e)},t.endInclusive=function(e){return e.reverse?a(e):l(e)},t.toLtgt=function(e,n,i,o,s){n=n||{},i=i||p;var a=arguments.length>3,l=t.lowerBoundKey(e),u=t.upperBoundKey(e);return l?"gt"===l?n.gt=i(e.gt,!1):n.gte=i(e[l],!1):a&&(n.gte=i(o,!1)),u?"lt"===u?n.lt=i(e.lt,!0):n.lte=i(e[u],!0):a&&(n.lte=i(s,!0)),null!=e.reverse&&(n.reverse=!!e.reverse),r(n,"max")&&delete n.max,r(n,"min")&&delete n.min,r(n,"start")&&delete n.start,r(n,"end")&&delete n.end,n},t.contains=function(e,r,i){i=i||t.compare;var o=s(e);if(n(o)){var a=i(r,o);if(a<0||0===a&&u(e))return!1}var l=f(e);if(n(l)){var a=i(r,l);if(a>0||0===a&&c(e))return!1}return!0},t.filter=function(e,n){return function(r){return t.contains(e,r,n)}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";var r=n(62),i=n(68);function o(e,t,n){if("object"!=typeof e)throw new TypeError("db must be an object");if("string"!=typeof t)throw new TypeError("storeName must be a string");if(null==n&&(n={}),"object"!=typeof n)throw new TypeError("opts must be an object");var o=new r.Transform(i(n,{objectMode:!0,transform:function(e,t,n){n(null,e)}}));n=i({snapshot:!1},n);var s=null;function a(){var r,i,l,u,c=n.direction||"next",h=n.range||{},f;r=h.lower,i=h.upper,l=!!h.lowerOpen,u=!!h.upperOpen,s&&("next"===c?(l=!0,r=s):(u=!0,i=s)),r&&i?f=IDBKeyRange.bound(r,i,l,u):r?f=IDBKeyRange.lowerBound(r,l):i&&(f=IDBKeyRange.upperBound(i,u));var p=e.transaction(t,"readonly"),d=p.objectStore(t);o._cursorsOpened++;var m=d.openCursor(f,n.direction);function g(e){try{e.continue()}catch(e){"TransactionInactiveError"!==e.name||n.snapshot?o.emit("error",e):a()}}m.onsuccess=function(){var e=m.result;if(e){s=e.key;var t=o.write({key:e.key,value:e.value});n.snapshot||t?g(e):o.once("drain",function(){g(e)})}else o.end()},p.onabort=function(){o.emit("error",p.error)},p.onerror=function(){o.emit("error",p.error)}}return o._cursorsOpened=0,a(),o}e.exports=o},function(e,t,n){"use strict";e.exports={Spec:{type:"mount",mounts:[{mountpoint:"/blocks",type:"measure",prefix:"flatfs.datastore",child:{type:"flatfs",path:"blocks",sync:!0,shardFunc:"/repo/flatfs/shard/v1/next-to-last/2"}},{mountpoint:"/",type:"measure",prefix:"leveldb.datastore",child:{type:"levelds",path:"datastore",compression:"none"}}]}}},function(e,t,n){"use strict";t.ERR_REPO_NOT_INITIALIZED="ERR_REPO_NOT_INITIALIZED"},function(e,t,n){"use strict";e.exports={repoVersion:7}},function(e,t,n){"use strict";t.preStart=n(871),t.start=n(886),t.stop=n(1115),t.isOnline=n(1116),t.version=n(1117),t.id=n(1118),t.repo=n(484),t.init=n(1119),t.bootstrap=n(1122),t.config=n(1123),t.block=n(1124),t.object=n(1125),t.dag=n(1126),t.libp2p=n(439),t.swarm=n(1128),t.ping=n(1129),t.pingPullStream=n(1130),t.pingReadableStream=n(1131),t.pin=n(1132),t.filesRegular=n(1140),t.filesMFS=n(1194),t.bitswap=n(507),t.pubsub=n(1242),t.dht=n(1243),t.dns=n(1246),t.key=n(1248),t.stats=n(1249),t.resolve=n(1250),t.name=n(1252)},function(e,t,n){"use strict";const r=n(15),i=n(31),o=n(22),s=n(10),a=n(425),l=n(89),u=n(885);e.exports=function e(t){return e=>{t.log("pre-start");const n=t._options.pass;s([e=>t._repo.config.get(e),(e,n)=>{if(!t._options.config)return n(null,e);e=l(e,t._options.config),t.config.replace(e,t=>{if(t)return n(t);n(null,e)})},(e,n)=>{if(e.Keychain)return n(null,e);e.Keychain=a.generateOptions(),t.config.set("Keychain",e.Keychain,r=>{t.log("using default keychain options"),n(r,e)})},(e,r)=>{if(t._keychain);else if(n){const r=Object.assign({passPhrase:n},e.Keychain);t._keychain=new a(t._repo.keys,r),t.log("keychain constructed")}else t._keychain=new u,t.log("no keychain, use --pass");r(null,e)},(e,t)=>{const n=e.Identity.PrivKey;r.createFromPrivKey(n,(n,r)=>{t(n,e,r)})},(e,r,i)=>{if(!n)return i(null,e,r);t._keychain.findKeyByName("self",n=>{if(n)return t.log('Creating "self" key'),t._keychain.importPeer("self",r,t=>i(t,e,r));i(null,e,r)})},(e,n,r)=>{t.log("peer created"),t._peerInfo=new i(n),e.Addresses&&e.Addresses.Swarm&&e.Addresses.Swarm.forEach(e=>{let n=o(e);n.getPeerId()&&(n=n.encapsulate("/ipfs/"+t._peerInfo.id.toB58String())),t._peerInfo.multiaddrs.add(n)}),r()},e=>t.pin._load(e)],e)}}},function(e,t,n){"use strict";const r=n(873),i=n(89),o=n(51),s=n(28),a=n(33),l=n(12),u=n(877),c=n(13),h="/pkcs8/",f="/info/",p={minKeyLength:14,minSaltLength:16,minIterationCount:1e3},d={dek:{keyLength:64,iterationCount:1e4,salt:"you should override this value with a crypto secure random number",hash:"sha2-512"}};function m(e){return!!e&&("string"==typeof e&&e===r(e.trim()))}function g(e,t){const n=200,r=1e3,i=800*Math.random()+200;setTimeout(e,i,t,null)}function y(e){return new s.Key(h+e)}function v(e){return new s.Key(f+e)}class b{constructor(e,t){if(!e)throw new Error("store is required");this.store=e;const n=i(d,t);if(!n.passPhrase||n.passPhrase.length<20)throw new Error("passPhrase must be least 20 characters");if(n.dek.keyLength<p.minKeyLength)throw new Error(`dek.keyLength must be least ${p.minKeyLength} bytes`);if(n.dek.salt.length<p.minSaltLength)throw new Error(`dek.saltLength must be least ${p.minSaltLength} bytes`);if(n.dek.iterationCount<p.minIterationCount)throw new Error(`dek.iterationCount must be least ${p.minIterationCount}`);const r=o.pbkdf2(n.passPhrase,n.dek.salt,n.dek.iterationCount,n.dek.keyLength,n.dek.hash);Object.defineProperty(this,"_",{value:()=>r})}get cms(){return new u(this)}static generateOptions(){const e=Object.assign({},d),t=3*Math.ceil(p.minSaltLength/3);return e.dek.salt=o.randomBytes(t).toString("base64"),e}static get options(){return d}createKey(e,t,n,r){const i=this;if(!m(e)||"self"===e)return g(r,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));if("string"!=typeof t)return g(r,c(new Error(`Invalid key type '${t}'`),"ERR_INVALID_KEY_TYPE"));if(!Number.isSafeInteger(n))return g(r,c(new Error(`Invalid key size '${n}'`),"ERR_INVALID_KEY_SIZE"));const s=y(e);i.store.has(s,(a,l)=>{if(a)return g(r,a);if(l)return g(r,c(new Error(`Key '${e}' already exists`),"ERR_KEY_ALREADY_EXISTS"));switch(t.toLowerCase()){case"rsa":if(n<2048)return g(r,c(new Error(`Invalid RSA key size ${n}`),"ERR_INVALID_KEY_SIZE"))}o.keys.generateKeyPair(t,n,(t,n)=>{if(t)return g(r,t);n.id((t,o)=>{if(t)return g(r,t);n.export(this._(),(t,n)=>{if(t)return g(r,t);const a={name:e,id:o},l=i.store.batch();l.put(s,n),l.put(v(e),JSON.stringify(a)),l.commit(e=>{if(e)return g(r,e);r(null,a)})})})})})}listKeys(e){const t=this,n={prefix:f};l(this.store.query(n),a((t,n)=>{if(t)return g(e,t);const r=n.map(e=>JSON.parse(e.value));e(null,r)}))}findKeyById(e,t){this.listKeys((n,r)=>{if(n)return g(t,n);const i=r.find(t=>t.id===e);t(null,i)})}findKeyByName(e,t){if(!m(e))return g(t,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));const n=v(e);this.store.get(n,(n,r)=>{if(n)return g(t,c(new Error(`Key '${e}' does not exist. ${n.message}`),"ERR_KEY_NOT_FOUND"));t(null,JSON.parse(r.toString()))})}removeKey(e,t){const n=this;if(!m(e)||"self"===e)return g(t,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));const r=y(e);n.findKeyByName(e,(i,o)=>{if(i)return g(t,i);const s=n.store.batch();s.delete(r),s.delete(v(e)),s.commit(e=>{if(e)return g(t,e);t(null,o)})})}renameKey(e,t,n){const r=this;if(!m(e)||"self"===e)return g(n,c(new Error(`Invalid old key name '${e}'`),"ERR_OLD_KEY_NAME_INVALID"));if(!m(t)||"self"===t)return g(n,c(new Error(`Invalid new key name '${t}'`),"ERR_NEW_KEY_NAME_INVALID"));const i=y(e),o=y(t),s=v(e),a=v(t);this.store.get(i,(l,u)=>{if(l)return g(n,c(new Error(`Key '${e}' does not exist. ${l.message}`),"ERR_KEY_NOT_FOUND"));const h=u.toString();r.store.has(o,(e,l)=>e?g(n,e):l?g(n,c(new Error(`Key '${t}' already exists`),"ERR_KEY_ALREADY_EXISTS")):void r.store.get(s,(e,l)=>{if(e)return g(n,e);const u=JSON.parse(l.toString());u.name=t;const c=r.store.batch();c.put(o,h),c.put(a,JSON.stringify(u)),c.delete(i),c.delete(s),c.commit(e=>{if(e)return g(n,e);n(null,u)})}))})}exportKey(e,t,n){if(!m(e))return g(n,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));if(!t)return g(n,c(new Error("Password is required"),"ERR_PASSWORD_REQUIRED"));const r=y(e);this.store.get(r,(r,i)=>{if(r)return g(n,c(new Error(`Key '${e}' does not exist. ${r.message}`),"ERR_KEY_NOT_FOUND"));const s=i.toString();o.keys.import(s,this._(),(e,r)=>{if(e)return g(n,e);r.export(t,n)})})}importKey(e,t,n,r){const i=this;if(!m(e)||"self"===e)return g(r,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));if(!t)return g(r,"PEM encoded key is required");const s=y(e);i.store.has(s,(a,l)=>a?g(r,a):l?g(r,c(new Error(`Key '${e}' already exists`),"ERR_KEY_ALREADY_EXISTS")):void o.keys.import(t,n,(t,n)=>{if(t)return g(r,c(new Error("Cannot read the key, most likely the password is wrong"),"ERR_CANNOT_READ_KEY"));n.id((t,o)=>{if(t)return g(r,t);n.export(this._(),(t,n)=>{if(t)return g(r,t);const a={name:e,id:o},l=i.store.batch();l.put(s,n),l.put(v(e),JSON.stringify(a)),l.commit(e=>{if(e)return g(r,e);r(null,a)})})})}))}importPeer(e,t,n){const r=this;if(!m(e))return g(n,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));if(!t||!t.privKey)return g(n,c(new Error("Peer.privKey is required"),"ERR_MISSING_PRIVATE_KEY"));const i=t.privKey,o=y(e);r.store.has(o,(t,s)=>t?g(n,t):s?g(n,c(new Error(`Key '${e}' already exists`),"ERR_KEY_ALREADY_EXISTS")):void i.id((t,s)=>{if(t)return g(n,t);i.export(this._(),(t,i)=>{if(t)return g(n,t);const a={name:e,id:s},l=r.store.batch();l.put(o,i),l.put(v(e),JSON.stringify(a)),l.commit(e=>{if(e)return g(n,e);n(null,a)})})}))}_getPrivateKey(e,t){if(!m(e))return g(t,c(new Error(`Invalid key name '${e}'`),"ERR_INVALID_KEY_NAME"));this.store.get(y(e),(n,r)=>{if(n)return g(t,c(new Error(`Key '${e}' does not exist. ${n.message}`),"ERR_KEY_NOT_FOUND"));t(null,r.toString())})}}e.exports=b},function(e,t,n){"use strict";var r=n(874),i=/[\/\?<>\\:\*\|":]/g,o=/[\x00-\x1f\x80-\x9f]/g,s=/^\.+$/,a=/^(con|prn|aux|nul|com[0-9]|lpt[0-9])(\..*)?$/i,l=/[\. ]+$/;function u(e,t){var n=e.replace(i,t).replace(o,t).replace(s,t).replace(a,t).replace(l,t);return r(n,255)}e.exports=function(e,t){var n=t&&t.replacement||"",r=u(e,n);return""===n?r:u(r,"")}},function(e,t,n){"use strict";var r=n(875),i=n(876);e.exports=r.bind(null,i)},function(e,t,n){"use strict";function r(e){return e>=55296&&e<=56319}function i(e){return e>=56320&&e<=57343}e.exports=function e(t,n,o){if("string"!=typeof n)throw new Error("Input must be string");for(var s=n.length,a=0,l,u,c=0;c<s;c+=1){if(l=n.charCodeAt(c),u=n[c],r(l)&&i(n.charCodeAt(c+1))&&(c+=1,u+=n[c]),a+=t(u),a===o)return n.slice(0,c+1);if(a>o)return n.slice(0,c-u.length+1)}return n}},function(e,t,n){"use strict";function r(e){return e>=55296&&e<=56319}function i(e){return e>=56320&&e<=57343}e.exports=function e(t){if("string"!=typeof t)throw new Error("Input must be string");for(var n=t.length,o=0,s=null,a=null,l=0;l<n;l++)s=t.charCodeAt(l),i(s)?null!=a&&r(a)?o+=1:o+=3:s<=127?o+=1:s>=128&&s<=2047?o+=2:s>=2048&&s<=65535&&(o+=3),a=s;return o}},function(e,t,n){"use strict";(function(t){const r=n(20),i=n(43),o=n(878),s=n(10);n(879),n(251);const a=n(21),l=n(884),u=n(13);class c{constructor(e){if(!e)throw u(new Error("keychain is required"),"ERR_KEYCHAIN_REQUIRED");this.keychain=e}encrypt(e,n,o){const s=this,c=(e,t)=>r(()=>o(e,t));if(!t.isBuffer(n))return c(u(new Error("Plain data must be a Buffer"),"ERR_INVALID_PARAMS"));i([t=>s.keychain.findKeyByName(e,t),t=>s.keychain._getPrivateKey(e,t)],(e,r)=>{if(e)return c(e);let i=r[0],u=r[1];try{const r=a.pki.decryptRsaPrivateKey(u,s.keychain._());l.certificateForKey(i,r,(e,r)=>{if(e)return o(e);const i=a.pkcs7.createEnvelopedData();i.addRecipient(r),i.content=a.util.createBuffer(n),i.encrypt();const s=a.asn1.toDer(i.toAsn1()).getBytes();c(null,t.from(s,"binary"))})}catch(e){c(e)}})}decrypt(e,n){const i=(e,t)=>r(()=>n(e,t));if(!t.isBuffer(e))return i(u(new Error("CMS data is required"),"ERR_INVALID_PARAMS"));const l=this;let c;try{const t=a.util.createBuffer(e.toString("binary")),n=a.asn1.fromDer(t);c=a.pkcs7.messageFromAsn1(n)}catch(e){return i(u(new Error("Invalid CMS: "+e.message),"ERR_INVALID_CMS"))}const h=c.recipients.filter(e=>e.issuer.find(e=>"O"===e.shortName&&"ipfs"===e.value)).filter(e=>e.issuer.find(e=>"CN"===e.shortName)).map(e=>({recipient:e,keyId:e.issuer.find(e=>"CN"===e.shortName).value}));o(h,(e,t)=>l.keychain.findKeyById(e.keyId,(e,n)=>t(null,!e&&n)),(e,n)=>{if(e)return i(e);if(!n){const t=h.map(e=>e.keyId);return e=u(new Error("Decryption needs one of the key(s): "+t.join(", ")),"ERR_MISSING_KEYS",{missingKeys:t}),i(e)}s([e=>l.keychain.findKeyById(n.keyId,e),(e,t)=>l.keychain._getPrivateKey(e.name,t)],(e,r)=>{if(e)return i(e);const o=a.pki.decryptRsaPrivateKey(r,l.keychain._());c.decrypt(n.recipient,o),i(null,t.from(c.content.getBytes(),"binary"))})})}}e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(156),i=h(r),o=n(157),s=h(o),a=n(110),l=h(a),u=n(426),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}t.default=(0,l.default)((0,s.default)(i.default,c.default)),e.exports=t.default},function(e,t,n){var r=n(21);n(196),n(117),n(252),n(152),n(253),n(880),n(118),n(30),n(427);var i=r.asn1,o=e.exports=r.pkcs7=r.pkcs7||{};function s(e){var t={},n=[];if(!i.validate(e,o.asn1.recipientInfoValidator,t,n)){var s=new Error("Cannot read PKCS#7 RecipientInfo. ASN.1 object is not an PKCS#7 RecipientInfo.");throw s.errors=n,s}return{version:t.version.charCodeAt(0),issuer:r.pki.RDNAttributesAsArray(t.issuer),serialNumber:r.util.createBuffer(t.serial).toHex(),encryptedContent:{algorithm:i.derToOid(t.encAlgorithm),parameter:t.encParameter.value,content:t.encKey}}}function a(e){return i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[r.pki.distinguishedNameToAsn1({attributes:e.issuer}),i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,r.util.hexToBytes(e.serialNumber))]),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.encryptedContent.algorithm).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")]),i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,e.encryptedContent.content)])}function l(e){for(var t=[],n=0;n<e.length;++n)t.push(s(e[n]));return t}function u(e){for(var t=[],n=0;n<e.length;++n)t.push(a(e[n]));return t}function c(e){var t={},n=[];if(!i.validate(e,o.asn1.signerInfoValidator,t,n)){var s=new Error("Cannot read PKCS#7 SignerInfo. ASN.1 object is not an PKCS#7 SignerInfo.");throw s.errors=n,s}var a={version:t.version.charCodeAt(0),issuer:r.pki.RDNAttributesAsArray(t.issuer),serialNumber:r.util.createBuffer(t.serial).toHex(),digestAlgorithm:i.derToOid(t.digestAlgorithm),signatureAlgorithm:i.derToOid(t.signatureAlgorithm),signature:t.signature,authenticatedAttributes:[],unauthenticatedAttributes:[]},l=t.authenticatedAttributes||[],u=t.unauthenticatedAttributes||[];return a}function h(e){var t=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[r.pki.distinguishedNameToAsn1({attributes:e.issuer}),i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,r.util.hexToBytes(e.serialNumber))]),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.digestAlgorithm).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")])]);if(e.authenticatedAttributesAsn1&&t.value.push(e.authenticatedAttributesAsn1),t.value.push(i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.signatureAlgorithm).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")])),t.value.push(i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,e.signature)),e.unauthenticatedAttributes.length>0){for(var n=i.create(i.Class.CONTEXT_SPECIFIC,1,!0,[]),o=0;o<e.unauthenticatedAttributes.length;++o){var s=e.unauthenticatedAttributes[o];n.values.push(d(s))}t.value.push(n)}return t}function f(e){for(var t=[],n=0;n<e.length;++n)t.push(c(e[n]));return t}function p(e){for(var t=[],n=0;n<e.length;++n)t.push(h(e[n]));return t}function d(e){var t;if(e.type===r.pki.oids.contentType)t=i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.value).getBytes());else if(e.type===r.pki.oids.messageDigest)t=i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,e.value.bytes());else if(e.type===r.pki.oids.signingTime){var n=new Date("1950-01-01T00:00:00Z"),o=new Date("2050-01-01T00:00:00Z"),s=e.value;if("string"==typeof s){var a=Date.parse(s);s=isNaN(a)?13===s.length?i.utcTimeToDate(s):i.generalizedTimeToDate(s):new Date(a)}t=s>=n&&s<o?i.create(i.Class.UNIVERSAL,i.Type.UTCTIME,!1,i.dateToUtcTime(s)):i.create(i.Class.UNIVERSAL,i.Type.GENERALIZEDTIME,!1,i.dateToGeneralizedTime(s))}return i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.type).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SET,!0,[t])])}function m(e){return[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(r.pki.oids.data).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.algorithm).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,e.parameter.getBytes())]),i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,e.content.getBytes())])]}function g(e,t,n){var o={},s=[];if(!i.validate(t,n,o,s)){var a=new Error("Cannot read PKCS#7 message. ASN.1 object is not a supported PKCS#7 message.");throw a.errors=a,a}var l=i.derToOid(o.contentType);if(l!==r.pki.oids.data)throw new Error("Unsupported PKCS#7 message. Only wrapped ContentType Data supported.");if(o.encryptedContent){var u="";if(r.util.isArray(o.encryptedContent))for(var c=0;c<o.encryptedContent.length;++c){if(o.encryptedContent[c].type!==i.Type.OCTETSTRING)throw new Error("Malformed PKCS#7 message, expecting encrypted content constructed of only OCTET STRING objects.");u+=o.encryptedContent[c].value}else u=o.encryptedContent;e.encryptedContent={algorithm:i.derToOid(o.encAlgorithm),parameter:r.util.createBuffer(o.encParameter.value),content:r.util.createBuffer(u)}}if(o.content){var u="";if(r.util.isArray(o.content))for(var c=0;c<o.content.length;++c){if(o.content[c].type!==i.Type.OCTETSTRING)throw new Error("Malformed PKCS#7 message, expecting content constructed of only OCTET STRING objects.");u+=o.content[c].value}else u=o.content;e.content=r.util.createBuffer(u)}return e.version=o.version.charCodeAt(0),e.rawCapture=o,o}function y(e){if(void 0===e.encryptedContent.key)throw new Error("Symmetric key not available.");if(void 0===e.content){var t;switch(e.encryptedContent.algorithm){case r.pki.oids["aes128-CBC"]:case r.pki.oids["aes192-CBC"]:case r.pki.oids["aes256-CBC"]:t=r.aes.createDecryptionCipher(e.encryptedContent.key);break;case r.pki.oids.desCBC:case r.pki.oids["des-EDE3-CBC"]:t=r.des.createDecryptionCipher(e.encryptedContent.key);break;default:throw new Error("Unsupported symmetric cipher, OID "+e.encryptedContent.algorithm)}if(t.start(e.encryptedContent.parameter),t.update(e.encryptedContent.content),!t.finish())throw new Error("Symmetric decryption failed.");e.content=t.output}}o.messageFromPem=function(e){var t=r.pem.decode(e)[0];if("PKCS7"!==t.type){var n=new Error('Could not convert PKCS#7 message from PEM; PEM header type is not "PKCS#7".');throw n.headerType=t.type,n}if(t.procType&&"ENCRYPTED"===t.procType.type)throw new Error("Could not convert PKCS#7 message from PEM; PEM is encrypted.");var s=i.fromDer(t.body);return o.messageFromAsn1(s)},o.messageToPem=function(e,t){var n={type:"PKCS7",body:i.toDer(e.toAsn1()).getBytes()};return r.pem.encode(n,{maxline:t})},o.messageFromAsn1=function(e){var t={},n=[];if(!i.validate(e,o.asn1.contentInfoValidator,t,n)){var s=new Error("Cannot read PKCS#7 message. ASN.1 object is not an PKCS#7 ContentInfo.");throw s.errors=n,s}var a=i.derToOid(t.contentType),l;switch(a){case r.pki.oids.envelopedData:l=o.createEnvelopedData();break;case r.pki.oids.encryptedData:l=o.createEncryptedData();break;case r.pki.oids.signedData:l=o.createSignedData();break;default:throw new Error("Cannot read PKCS#7 message. ContentType with OID "+a+" is not (yet) supported.")}return l.fromAsn1(t.content.value[0]),l},o.createSignedData=function(){var e=null;return e={type:r.pki.oids.signedData,version:1,certificates:[],crls:[],signers:[],digestAlgorithmIdentifiers:[],contentInfo:null,signerInfos:[],fromAsn1:function(t){if(g(e,t,o.asn1.signedDataValidator),e.certificates=[],e.crls=[],e.digestAlgorithmIdentifiers=[],e.contentInfo=null,e.signerInfos=[],e.rawCapture.certificates)for(var n=e.rawCapture.certificates.value,i=0;i<n.length;++i)e.certificates.push(r.pki.certificateFromAsn1(n[i]))},toAsn1:function(){e.contentInfo||e.sign();for(var t=[],n=0;n<e.certificates.length;++n)t.push(r.pki.certificateToAsn1(e.certificates[n]));var o=[],s=i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SET,!0,e.digestAlgorithmIdentifiers),e.contentInfo])]);return t.length>0&&s.value[0].value.push(i.create(i.Class.CONTEXT_SPECIFIC,0,!0,t)),o.length>0&&s.value[0].value.push(i.create(i.Class.CONTEXT_SPECIFIC,1,!0,o)),s.value[0].value.push(i.create(i.Class.UNIVERSAL,i.Type.SET,!0,e.signerInfos)),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.type).getBytes()),s])},addSigner:function(t){var n=t.issuer,i=t.serialNumber;if(t.certificate){var o=t.certificate;"string"==typeof o&&(o=r.pki.certificateFromPem(o)),n=o.issuer.attributes,i=o.serialNumber}var s=t.key;if(!s)throw new Error("Could not add PKCS#7 signer; no private key specified.");"string"==typeof s&&(s=r.pki.privateKeyFromPem(s));var a=t.digestAlgorithm||r.pki.oids.sha1;switch(a){case r.pki.oids.sha1:case r.pki.oids.sha256:case r.pki.oids.sha384:case r.pki.oids.sha512:case r.pki.oids.md5:break;default:throw new Error("Could not add PKCS#7 signer; unknown message digest algorithm: "+a)}var l=t.authenticatedAttributes||[];if(l.length>0){for(var u=!1,c=!1,h=0;h<l.length;++h){var f=l[h];if(u||f.type!==r.pki.oids.contentType){if(c||f.type!==r.pki.oids.messageDigest);else if(c=!0,u)break}else if(u=!0,c)break}if(!u||!c)throw new Error("Invalid signer.authenticatedAttributes. If signer.authenticatedAttributes is specified, then it must contain at least two attributes, PKCS #9 content-type and PKCS #9 message-digest.")}e.signers.push({key:s,version:1,issuer:n,serialNumber:i,digestAlgorithm:a,signatureAlgorithm:r.pki.oids.rsaEncryption,signature:null,authenticatedAttributes:l,unauthenticatedAttributes:[]})},sign:function(o){var s;(o=o||{},"object"!=typeof e.content||null===e.contentInfo)&&(e.contentInfo=i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(r.pki.oids.data).getBytes())]),"content"in e&&(e.content instanceof r.util.ByteBuffer?s=e.content.bytes():"string"==typeof e.content&&(s=r.util.encodeUtf8(e.content)),o.detached?e.detachedContent=i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,s):e.contentInfo.value.push(i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.OCTETSTRING,!1,s)]))));if(0!==e.signers.length){var a=t();n(a)}},verify:function(){throw new Error("PKCS#7 signature verification not yet implemented.")},addCertificate:function(t){"string"==typeof t&&(t=r.pki.certificateFromPem(t)),e.certificates.push(t)},addCertificateRevokationList:function(e){throw new Error("PKCS#7 CRL support not yet implemented.")}},e;function t(){for(var t={},n=0;n<e.signers.length;++n){var o=e.signers[n],s=o.digestAlgorithm;s in t||(t[s]=r.md[r.pki.oids[s]].create()),0===o.authenticatedAttributes.length?o.md=t[s]:o.md=r.md[r.pki.oids[s]].create()}for(var s in e.digestAlgorithmIdentifiers=[],t)e.digestAlgorithmIdentifiers.push(i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(s).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.NULL,!1,"")]));return t}function n(t){var n;if(e.detachedContent?n=e.detachedContent:(n=e.contentInfo.value[1],n=n.value[0]),!n)throw new Error("Could not sign PKCS#7 message; there is no content to sign.");var o=i.derToOid(e.contentInfo.value[0].value),s=i.toDer(n);for(var a in s.getByte(),i.getBerValueLength(s),s=s.getBytes(),t)t[a].start().update(s);for(var l=new Date,u=0;u<e.signers.length;++u){var c=e.signers[u];if(0===c.authenticatedAttributes.length){if(o!==r.pki.oids.data)throw new Error("Invalid signer; authenticatedAttributes must be present when the ContentInfo content type is not PKCS#7 Data.")}else{c.authenticatedAttributesAsn1=i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[]);for(var h=i.create(i.Class.UNIVERSAL,i.Type.SET,!0,[]),f=0;f<c.authenticatedAttributes.length;++f){var m=c.authenticatedAttributes[f];m.type===r.pki.oids.messageDigest?m.value=t[c.digestAlgorithm].digest():m.type===r.pki.oids.signingTime&&(m.value||(m.value=l)),h.value.push(d(m)),c.authenticatedAttributesAsn1.value.push(d(m))}s=i.toDer(h).getBytes(),c.md.start().update(s)}c.signature=c.key.sign(c.md,"RSASSA-PKCS1-V1_5")}e.signerInfos=p(e.signers)}},o.createEncryptedData=function(){var e=null;return e={type:r.pki.oids.encryptedData,version:0,encryptedContent:{algorithm:r.pki.oids["aes256-CBC"]},fromAsn1:function(t){g(e,t,o.asn1.encryptedDataValidator)},decrypt:function(t){void 0!==t&&(e.encryptedContent.key=t),y(e)}},e},o.createEnvelopedData=function(){var e=null;return e={type:r.pki.oids.envelopedData,version:0,recipients:[],encryptedContent:{algorithm:r.pki.oids["aes256-CBC"]},fromAsn1:function(t){var n=g(e,t,o.asn1.envelopedDataValidator);e.recipients=l(n.recipientInfos.value)},toAsn1:function(){return i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.OID,!1,i.oidToDer(e.type).getBytes()),i.create(i.Class.CONTEXT_SPECIFIC,0,!0,[i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,[i.create(i.Class.UNIVERSAL,i.Type.INTEGER,!1,i.integerToDer(e.version).getBytes()),i.create(i.Class.UNIVERSAL,i.Type.SET,!0,u(e.recipients)),i.create(i.Class.UNIVERSAL,i.Type.SEQUENCE,!0,m(e.encryptedContent))])])])},findRecipient:function(t){for(var n=t.issuer.attributes,r=0;r<e.recipients.length;++r){var i=e.recipients[r],o=i.issuer;if(i.serialNumber===t.serialNumber&&o.length===n.length){for(var s=!0,a=0;a<n.length;++a)if(o[a].type!==n[a].type||o[a].value!==n[a].value){s=!1;break}if(s)return i}}return null},decrypt:function(t,n){if(void 0===e.encryptedContent.key&&void 0!==t&&void 0!==n)switch(t.encryptedContent.algorithm){case r.pki.oids.rsaEncryption:case r.pki.oids.desCBC:var i=n.decrypt(t.encryptedContent.content);e.encryptedContent.key=r.util.createBuffer(i);break;default:throw new Error("Unsupported asymmetric cipher, OID "+t.encryptedContent.algorithm)}y(e)},addRecipient:function(t){e.recipients.push({version:0,issuer:t.issuer.attributes,serialNumber:t.serialNumber,encryptedContent:{algorithm:r.pki.oids.rsaEncryption,key:t.publicKey}})},encrypt:function(t,n){if(void 0===e.encryptedContent.content){var i,o,s;switch(n=n||e.encryptedContent.algorithm,t=t||e.encryptedContent.key,n){case r.pki.oids["aes128-CBC"]:i=16,o=16,s=r.aes.createEncryptionCipher;break;case r.pki.oids["aes192-CBC"]:i=24,o=16,s=r.aes.createEncryptionCipher;break;case r.pki.oids["aes256-CBC"]:i=32,o=16,s=r.aes.createEncryptionCipher;break;case r.pki.oids["des-EDE3-CBC"]:i=24,o=8,s=r.des.createEncryptionCipher;break;default:throw new Error("Unsupported symmetric cipher, OID "+n)}if(void 0===t)t=r.util.createBuffer(r.random.getBytes(i));else if(t.length()!=i)throw new Error("Symmetric key has wrong length; got "+t.length()+" bytes, expected "+i+".");e.encryptedContent.algorithm=n,e.encryptedContent.key=t,e.encryptedContent.parameter=r.util.createBuffer(r.random.getBytes(o));var a=s(t);if(a.start(e.encryptedContent.parameter.copy()),a.update(e.content),!a.finish())throw new Error("Symmetric encryption failed.");e.encryptedContent.content=a.output}for(var l=0;l<e.recipients.length;++l){var u=e.recipients[l];if(void 0===u.encryptedContent.content)switch(u.encryptedContent.algorithm){case r.pki.oids.rsaEncryption:u.encryptedContent.content=u.encryptedContent.key.encrypt(e.encryptedContent.key.data);break;default:throw new Error("Unsupported asymmetric cipher, OID "+u.encryptedContent.algorithm)}}}},e}},function(e,t,n){var r=n(21);n(117),n(30);var i=r.asn1,o=e.exports=r.pkcs7asn1=r.pkcs7asn1||{};r.pkcs7=r.pkcs7||{},r.pkcs7.asn1=o;var s={name:"ContentInfo",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"ContentInfo.ContentType",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"contentType"},{name:"ContentInfo.content",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,constructed:!0,optional:!0,captureAsn1:"content"}]};o.contentInfoValidator=s;var a={name:"EncryptedContentInfo",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"EncryptedContentInfo.contentType",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"contentType"},{name:"EncryptedContentInfo.contentEncryptionAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"EncryptedContentInfo.contentEncryptionAlgorithm.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"encAlgorithm"},{name:"EncryptedContentInfo.contentEncryptionAlgorithm.parameter",tagClass:i.Class.UNIVERSAL,captureAsn1:"encParameter"}]},{name:"EncryptedContentInfo.encryptedContent",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,capture:"encryptedContent",captureAsn1:"encryptedContentAsn1"}]};o.envelopedDataValidator={name:"EnvelopedData",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"EnvelopedData.Version",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"version"},{name:"EnvelopedData.RecipientInfos",tagClass:i.Class.UNIVERSAL,type:i.Type.SET,constructed:!0,captureAsn1:"recipientInfos"}].concat(a)},o.encryptedDataValidator={name:"EncryptedData",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"EncryptedData.Version",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"version"}].concat(a)};var l={name:"SignerInfo",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"SignerInfo.version",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1},{name:"SignerInfo.issuerAndSerialNumber",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"SignerInfo.issuerAndSerialNumber.issuer",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"issuer"},{name:"SignerInfo.issuerAndSerialNumber.serialNumber",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"serial"}]},{name:"SignerInfo.digestAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"SignerInfo.digestAlgorithm.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"digestAlgorithm"},{name:"SignerInfo.digestAlgorithm.parameter",tagClass:i.Class.UNIVERSAL,constructed:!1,captureAsn1:"digestParameter",optional:!0}]},{name:"SignerInfo.authenticatedAttributes",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,constructed:!0,optional:!0,capture:"authenticatedAttributes"},{name:"SignerInfo.digestEncryptionAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,capture:"signatureAlgorithm"},{name:"SignerInfo.encryptedDigest",tagClass:i.Class.UNIVERSAL,type:i.Type.OCTETSTRING,constructed:!1,capture:"signature"},{name:"SignerInfo.unauthenticatedAttributes",tagClass:i.Class.CONTEXT_SPECIFIC,type:1,constructed:!0,optional:!0,capture:"unauthenticatedAttributes"}]};o.signedDataValidator={name:"SignedData",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"SignedData.Version",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"version"},{name:"SignedData.DigestAlgorithms",tagClass:i.Class.UNIVERSAL,type:i.Type.SET,constructed:!0,captureAsn1:"digestAlgorithms"},s,{name:"SignedData.Certificates",tagClass:i.Class.CONTEXT_SPECIFIC,type:0,optional:!0,captureAsn1:"certificates"},{name:"SignedData.CertificateRevocationLists",tagClass:i.Class.CONTEXT_SPECIFIC,type:1,optional:!0,captureAsn1:"crls"},{name:"SignedData.SignerInfos",tagClass:i.Class.UNIVERSAL,type:i.Type.SET,capture:"signerInfos",optional:!0,value:[l]}]},o.recipientInfoValidator={name:"RecipientInfo",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"RecipientInfo.version",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"version"},{name:"RecipientInfo.issuerAndSerial",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"RecipientInfo.issuerAndSerial.issuer",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,captureAsn1:"issuer"},{name:"RecipientInfo.issuerAndSerial.serialNumber",tagClass:i.Class.UNIVERSAL,type:i.Type.INTEGER,constructed:!1,capture:"serial"}]},{name:"RecipientInfo.keyEncryptionAlgorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.SEQUENCE,constructed:!0,value:[{name:"RecipientInfo.keyEncryptionAlgorithm.algorithm",tagClass:i.Class.UNIVERSAL,type:i.Type.OID,constructed:!1,capture:"encAlgorithm"},{name:"RecipientInfo.keyEncryptionAlgorithm.parameter",tagClass:i.Class.UNIVERSAL,constructed:!1,captureAsn1:"encParameter"}]},{name:"RecipientInfo.encryptedKey",tagClass:i.Class.UNIVERSAL,type:i.Type.OCTETSTRING,constructed:!1,capture:"encKey"}]}},function(e,t,n){var r=n(21);n(882),e.exports=r.mgf=r.mgf||{},r.mgf.mgf1=r.mgf1},function(e,t,n){var r=n(21);n(30),r.mgf=r.mgf||{};var i=e.exports=r.mgf.mgf1=r.mgf1=r.mgf1||{};i.create=function(e){var t={generate:function(t,n){for(var i=new r.util.ByteBuffer,o=Math.ceil(n/e.digestLength),s=0;s<o;s++){var a=new r.util.ByteBuffer;a.putInt32(s),e.start(),e.update(t+a.getBytes()),i.putBuffer(e.digest())}return i.truncate(i.length()-n),i.getBytes()}};return t}},function(e,t,n){var r=n(21);n(118),n(30);var i=e.exports=r.pss=r.pss||{};i.create=function(e){3===arguments.length&&(e={md:arguments[0],mgf:arguments[1],saltLength:arguments[2]});var t=e.md,n=e.mgf,i=t.digestLength,o=e.salt||null,s;if("string"==typeof o&&(o=r.util.createBuffer(o)),"saltLength"in e)s=e.saltLength;else{if(null===o)throw new Error("Salt length not specified or specific salt not given.");s=o.length()}if(null!==o&&o.length()!==s)throw new Error("Given salt length does not match length of given salt.");var a=e.prng||r.random,l={encode:function(e,l){var u,c=l-1,h=Math.ceil(c/8),f=e.digest().getBytes(),p;if(h<i+s+2)throw new Error("Message is too long to encrypt.");p=null===o?a.getBytesSync(s):o.bytes();var d=new r.util.ByteBuffer;d.fillWithByte(0,8),d.putBytes(f),d.putBytes(p),t.start(),t.update(d.getBytes());var m=t.digest().getBytes(),g=new r.util.ByteBuffer;g.fillWithByte(0,h-s-i-2),g.putByte(1),g.putBytes(p);var y=g.getBytes(),v=h-i-1,b=n.generate(m,v),_="";for(u=0;u<v;u++)_+=String.fromCharCode(y.charCodeAt(u)^b.charCodeAt(u));var w=65280>>8*h-c&255;return _=String.fromCharCode(_.charCodeAt(0)&~w)+_.substr(1),_+m+String.fromCharCode(188)},verify:function(e,o,a){var l,u=a-1,c=Math.ceil(u/8);if(o=o.substr(-c),c<i+s+2)throw new Error("Inconsistent parameters to PSS signature verification.");if(188!==o.charCodeAt(c-1))throw new Error("Encoded message does not end in 0xBC.");var h=c-i-1,f=o.substr(0,h),p=o.substr(h,i),d=65280>>8*c-u&255;if(0!=(f.charCodeAt(0)&d))throw new Error("Bits beyond keysize not zero as expected.");var m=n.generate(p,h),g="";for(l=0;l<h;l++)g+=String.fromCharCode(f.charCodeAt(l)^m.charCodeAt(l));g=String.fromCharCode(g.charCodeAt(0)&~d)+g.substr(1);var y=c-i-s-2;for(l=0;l<y;l++)if(0!==g.charCodeAt(l))throw new Error("Leftmost octets not zero as expected");if(1!==g.charCodeAt(y))throw new Error("Inconsistent PSS signature, 0x01 marker not found");var v=g.substr(-s),b=new r.util.ByteBuffer;b.fillWithByte(0,8),b.putBytes(e),b.putBytes(v),t.start(),t.update(b.getBytes());var _=t.digest().getBytes();return p===_}};return l}},function(e,t,n){"use strict";n(427);const r=n(21),i=r.pki;t=e.exports,t.certificateForKey=((e,t,n)=>{const r=i.setRsaPublicKey(t.n,t.e),o=i.createCertificate();o.publicKey=r,o.serialNumber="01",o.validity.notBefore=new Date,o.validity.notAfter=new Date,o.validity.notAfter.setFullYear(o.validity.notBefore.getFullYear()+10);const s=[{name:"organizationName",value:"ipfs"},{shortName:"OU",value:"keystore"},{name:"commonName",value:e.id}];return o.setSubject(s),o.setIssuer(s),o.setExtensions([{name:"basicConstraints",cA:!0},{name:"keyUsage",keyCertSign:!0,digitalSignature:!0,nonRepudiation:!0,keyEncipherment:!0,dataEncipherment:!0},{name:"extKeyUsage",serverAuth:!0,clientAuth:!0,codeSigning:!0,emailProtection:!0,timeStamping:!0},{name:"nsCertType",client:!0,server:!0,email:!0,objsign:!0,sslCA:!0,emailCA:!0,objCA:!0}]),o.sign(t),n(null,o)})},function(e,t,n){"use strict";function r(){throw new Error("Key management requires '--pass ...' option")}class i{static get options(){r()}static generateOptions(){r()}createKey(){r()}listKeys(){r()}findKeyById(){r()}findKeyByName(){r()}renameKey(){r()}removeKey(){r()}exportKey(){r()}importKey(){r()}importPeer(){r()}get cms(){r()}}e.exports=i},function(e,t,n){"use strict";const r=n(43),i=n(887),o=n(20),s=n(2),a=n(432),l=n(913),u=n(439);e.exports=(e=>s(t=>{const n=n=>{if(n)return o(()=>e.emit("error",n)),t(n);e.state.started(),o(()=>e.emit("start")),t()};if("stopped"!==e.state.state())return n(new Error(`Not able to start from state: ${e.state.state()}`));e.log("starting"),e.state.start(),r([t=>{e._repo.closed?e._repo.open(t):t()},t=>{e._repo.config.get((n,r)=>{if(n)return t(n);const i=u(e,r);i.start(n=>{if(n)return t(n);e.libp2p=i,t()})})},t=>{const n=l(e);e._ipns=new a(n,e._repo.datastore,e._peerInfo,e._keychain,e._options),e._bitswap=new i(e.libp2p,e._repo.blocks,{statsEnabled:!0}),e._bitswap.start(),e._blockService.setExchange(e._bitswap),e._preload.start(),e._ipns.republisher.start(),e._mfsPreload.start(t)}],n)}))},function(e,t,n){"use strict";const r=n(10),i=n(410),o=n(38),s=n(43),a=n(59),l=n(47),u=n(888),c=n(895),h=n(899),f=n(901),p=n(100).logger,d=n(902),m={statsEnabled:!1,statsComputeThrottleTimeout:1e3,statsComputeThrottleMaxQueueSize:1e3},g=["blocksReceived","dataReceived","dupBlksReceived","dupDataReceived","blocksSent","dataSent","providesBufferLength","wantListLength","peerCount"];class y{constructor(e,t,n){this._libp2p=e,this._log=p(this.peerInfo.id),this._options=Object.assign({},m,n),this._stats=new d(g,{enabled:this._options.statsEnabled,computeThrottleTimeout:this._options.statsComputeThrottleTimeout,computeThrottleMaxQueueSize:this._options.statsComputeThrottleMaxQueueSize}),this.network=new c(e,this,{},this._stats),this.blockstore=t,this.engine=new h(this.peerInfo.id,t,this.network,this._stats),this.wm=new u(this.peerInfo.id,this.network,this._stats),this.notifications=new f(this.peerInfo.id)}get peerInfo(){return this._libp2p.peerInfo}_receiveMessage(e,t,n){this.engine.messageReceived(e,t,r=>{if(r&&this._log("failed to receive message",t),0===t.blocks.size)return n();const i=Array.from(t.blocks.values()),s=i.filter(e=>this.wm.wantlist.contains(e.cid)).map(e=>e.cid);this.wm.cancelWants(s),o(i,(t,n)=>this._handleReceivedBlock(e,t,n),n)})}_handleReceivedBlock(e,t,n){this._log("received block"),r([e=>this.blockstore.has(t.cid,e),(n,r)=>{if(this._updateReceiveCounters(e.toB58String(),t,n),n)return l(r);this._putBlock(t,r)}],n)}_updateReceiveCounters(e,t,n){this._stats.push(e,"blocksReceived",1),this._stats.push(e,"dataReceived",t.data.length),n&&(this._stats.push(e,"dupBlksReceived",1),this._stats.push(e,"dupDataReceived",t.data.length))}_receiveError(e){this._log.error("ReceiveError: %s",e.message)}_onPeerConnected(e){this.wm.connected(e)}_onPeerDisconnected(e){this.wm.disconnected(e),this.engine.peerDisconnected(e),this._stats.disconnected(e)}_putBlock(e,t){this.blockstore.put(e,n=>{if(n)return t(n);this.notifications.hasBlock(e),this.network.provide(e.cid,e=>{e&&this._log.error("Failed to provide: %s",e.message)}),this.engine.receivedBlocks([e.cid]),t()})}enableStats(){this._stats.enable()}disableStats(){this._stats.disable()}wantlistForPeer(e){return this.engine.wantlistForPeer(e)}ledgerForPeer(e){return this.engine.ledgerForPeer(e)}get(e,t){this.getMany([e],(e,n)=>{if(e)return t(e);n&&n.length>0?t(null,n[0]):t()})}getMany(e,t){let n=e.length;const i=[];let o=!1;const s=(e,t)=>{i.push(e),this.notifications.wantBlock(e,n=>{this.wm.cancelWants([e]),t(null,n)},()=>{this.wm.cancelWants([e]),t(null,void 0)}),n||this.wm.wantBlocks(i)};a(e,(t,a)=>{r([e=>this.blockstore.has(t,e),(r,a)=>{if(n--,r)return n||this.wm.wantBlocks(i),this.blockstore.get(t,a);o||(o=!0,this.network.findAndConnect(e[0],e=>{e&&this._log.error(e)})),s(t,a)}],a)},t)}unwant(e){Array.isArray(e)||(e=[e]),this.wm.unwantBlocks(e),e.forEach(e=>this.notifications.unwantBlock(e))}cancelWants(e){Array.isArray(e)||(e=[e]),this.wm.cancelWants(e)}put(e,t){this._log("putting block"),r([t=>this.blockstore.has(e.cid,t),(t,n)=>{if(t)return l(n);this._putBlock(e,n)}],t)}putMany(e,t){r([t=>i(e,(e,t)=>{this.blockstore.has(e.cid,t)},t),(e,t)=>this.blockstore.putMany(e,n=>{if(n)return t(n);e.forEach(e=>{this.notifications.hasBlock(e),this.engine.receivedBlocks([e.cid]),this.network.provide(e.cid,e=>{e&&this._log.error("Failed to provide: %s",e.message)})}),t()})],t)}getWantlist(){return this.wm.wantlist.entries()}peers(){return this.engine.peers()}stat(){return this._stats}start(e){s([e=>this.wm.start(e),e=>this.network.start(e),e=>this.engine.start(e)],e)}stop(e){this._stats.stop(),s([e=>this.wm.stop(e),e=>this.network.stop(e),e=>this.engine.stop(e)],e)}}e.exports=y},function(e,t,n){"use strict";const r=n(47),i=n(206),o=n(207),s=n(265),a=n(894),l=n(100).logger;e.exports=class e{constructor(e,t,n){this.peers=new Map,this.wantlist=new o(n),this.network=t,this._stats=n,this._peerId=e,this._log=l(e,"want")}_addEntries(e,t,n){const r=e.map((e,n)=>new i.Entry(e,s.kMaxPriority-n,t));r.forEach(e=>{e.cancel?n?this.wantlist.removeForce(e.cid):this.wantlist.remove(e.cid):(this._log("adding to wl"),this.wantlist.add(e.cid,e.priority))});for(let e of this.peers.values())e.addEntries(r)}_startPeerHandler(e){let t=this.peers.get(e.toB58String());if(t)return void t.refcnt++;t=new a(this._peerId,e,this.network);const n=new i(!0);for(let e of this.wantlist.entries())n.addEntry(e[1].cid,e[1].priority);return t.addMessage(n),this.peers.set(e.toB58String(),t),t}_stopPeerHandler(e){const t=this.peers.get(e.toB58String());t&&(t.refcnt--,t.refcnt>0||this.peers.delete(e.toB58String()))}wantBlocks(e){this._addEntries(e,!1)}unwantBlocks(e){this._log("unwant blocks: %s",e.length),this._addEntries(e,!0,!0)}cancelWants(e){this._log("cancel wants: %s",e.length),this._addEntries(e,!0)}connectedPeers(){return Array.from(this.peers.keys())}connected(e){this._startPeerHandler(e)}disconnected(e){this._stopPeerHandler(e)}start(e){this.timer=setInterval(()=>{this._log("resend full-wantlist");const e=new i(!0);this.wantlist.forEach(t=>{e.addEntry(t.cid,t.priority)}),this.peers.forEach(t=>t.addMessage(e))},6e4),r(()=>e())}stop(e){this.peers.forEach(e=>this.disconnected(e.peerId)),clearInterval(this.timer),r(()=>e())}}},function(e,t,n){(function(e,n){var r=200,i="__lodash_hash_undefined__",o=1,s=2,a=9007199254740991,l="[object Arguments]",u="[object Array]",c="[object Boolean]",h="[object Date]",f="[object Error]",p="[object Function]",d="[object GeneratorFunction]",m="[object Map]",g="[object Number]",y="[object Object]",v="[object Promise]",b="[object RegExp]",_="[object Set]",w="[object String]",k="[object Symbol]",E="[object WeakMap]",S="[object ArrayBuffer]",x="[object DataView]",C="[object Float32Array]",A="[object Float64Array]",T="[object Int8Array]",I="[object Int16Array]",j="[object Int32Array]",R="[object Uint8Array]",B="[object Uint8ClampedArray]",O="[object Uint16Array]",P="[object Uint32Array]",N=/[\\^$.*+?()[\]{}|]/g,D=/^\[object .+?Constructor\]$/,M=/^(?:0|[1-9]\d*)$/,F={};F[C]=F[A]=F[T]=F[I]=F[j]=F[R]=F[B]=F[O]=F[P]=!0,F[l]=F[u]=F[S]=F[c]=F[x]=F[h]=F[f]=F[p]=F[m]=F[g]=F[y]=F[b]=F[_]=F[w]=F[E]=!1;var L="object"==typeof e&&e&&e.Object===Object&&e,U="object"==typeof self&&self&&self.Object===Object&&self,q=L||U||Function("return this")(),z=t&&!t.nodeType&&t,K=z&&"object"==typeof n&&n&&!n.nodeType&&n,H=K&&K.exports===z,V=H&&L.process,$=function(){try{return V&&V.binding("util")}catch(e){}}(),W=$&&$.isTypedArray;function G(e,t){for(var n=-1,r=e?e.length:0;++n<r;)if(t(e[n],n,e))return!0;return!1}function Y(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Z(e){return function(t){return e(t)}}function J(e,t){return null==e?void 0:e[t]}function Q(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function X(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function ee(e,t){return function(n){return e(t(n))}}function te(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var ne=Array.prototype,re=Function.prototype,ie=Object.prototype,oe=q["__core-js_shared__"],se=(ae=/[^.]+$/.exec(oe&&oe.keys&&oe.keys.IE_PROTO||""),ae?"Symbol(src)_1."+ae:""),ae,le=re.toString,ue=ie.hasOwnProperty,ce=ie.toString,he=RegExp("^"+le.call(ue).replace(N,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fe=q.Symbol,pe=q.Uint8Array,de=ie.propertyIsEnumerable,me=ne.splice,ge=ee(Object.keys,Object),ye=mt(q,"DataView"),ve=mt(q,"Map"),be=mt(q,"Promise"),_e=mt(q,"Set"),we=mt(q,"WeakMap"),ke=mt(Object,"create"),Ee=wt(ye),Se=wt(ve),xe=wt(be),Ce=wt(_e),Ae=wt(we),Te=fe?fe.prototype:void 0,Ie=Te?Te.valueOf:void 0;function je(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Re(){this.__data__=ke?ke(null):{}}function Be(e){return this.has(e)&&delete this.__data__[e]}function Oe(e){var t=this.__data__;if(ke){var n=t[e];return n===i?void 0:n}return ue.call(t,e)?t[e]:void 0}function Pe(e){var t=this.__data__;return ke?void 0!==t[e]:ue.call(t,e)}function Ne(e,t){var n=this.__data__;return n[e]=ke&&void 0===t?i:t,this}function De(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Me(){this.__data__=[]}function Fe(e){var t=this.__data__,n=it(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():me.call(t,n,1),!0}function Le(e){var t=this.__data__,n=it(t,e);return n<0?void 0:t[n][1]}function Ue(e){return it(this.__data__,e)>-1}function qe(e,t){var n=this.__data__,r=it(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}function ze(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ke(){this.__data__={hash:new je,map:new(ve||De),string:new je}}function He(e){return dt(this,e).delete(e)}function Ve(e){return dt(this,e).get(e)}function $e(e){return dt(this,e).has(e)}function We(e,t){return dt(this,e).set(e,t),this}function Ge(e){var t=-1,n=e?e.length:0;for(this.__data__=new ze;++t<n;)this.add(e[t])}function Ye(e){return this.__data__.set(e,i),this}function Ze(e){return this.__data__.has(e)}function Je(e){this.__data__=new De(e)}function Qe(){this.__data__=new De}function Xe(e){return this.__data__.delete(e)}function et(e){return this.__data__.get(e)}function tt(e){return this.__data__.has(e)}function nt(e,t){var n=this.__data__;if(n instanceof De){var i=n.__data__;if(!ve||i.length<r-1)return i.push([e,t]),this;n=this.__data__=new ze(i)}return n.set(e,t),this}function rt(e,t){var n=St(e)||Et(e)?Y(e.length,String):[],r=n.length,i=!!r;for(var o in e)!t&&!ue.call(e,o)||i&&("length"==o||yt(o,r))||n.push(o);return n}function it(e,t){for(var n=e.length;n--;)if(kt(e[n][0],t))return n;return-1}function ot(e){return ce.call(e)}function st(e,t,n,r,i){return e===t||(null==e||null==t||!jt(e)&&!Rt(t)?e!=e&&t!=t:at(e,t,st,n,r,i))}function at(e,t,n,r,i,o){var a=St(e),c=St(t),h=u,f=u;a||(h=gt(e),h=h==l?y:h),c||(f=gt(t),f=f==l?y:f);var p=h==y&&!Q(e),d=f==y&&!Q(t),m=h==f;if(m&&!p)return o||(o=new Je),a||Bt(e)?ht(e,t,n,r,i,o):ft(e,t,h,n,r,i,o);if(!(i&s)){var g=p&&ue.call(e,"__wrapped__"),v=d&&ue.call(t,"__wrapped__");if(g||v){var b=g?e.value():e,_=v?t.value():t;return o||(o=new Je),n(b,_,r,i,o)}}return!!m&&(o||(o=new Je),pt(e,t,n,r,i,o))}function lt(e){if(!jt(e)||bt(e))return!1;var t=Tt(e)||Q(e)?he:D;return t.test(wt(e))}function ut(e){return Rt(e)&&It(e.length)&&!!F[ce.call(e)]}function ct(e){if(!_t(e))return ge(e);var t=[];for(var n in Object(e))ue.call(e,n)&&"constructor"!=n&&t.push(n);return t}function ht(e,t,n,r,i,a){var l=i&s,u=e.length,c=t.length;if(u!=c&&!(l&&c>u))return!1;var h=a.get(e);if(h&&a.get(t))return h==t;var f=-1,p=!0,d=i&o?new Ge:void 0;for(a.set(e,t),a.set(t,e);++f<u;){var m=e[f],g=t[f];if(r)var y=l?r(g,m,f,t,e,a):r(m,g,f,e,t,a);if(void 0!==y){if(y)continue;p=!1;break}if(d){if(!G(t,function(e,t){if(!d.has(t)&&(m===e||n(m,e,r,i,a)))return d.add(t)})){p=!1;break}}else if(m!==g&&!n(m,g,r,i,a)){p=!1;break}}return a.delete(e),a.delete(t),p}function ft(e,t,n,r,i,a,l){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case S:return!(e.byteLength!=t.byteLength||!r(new pe(e),new pe(t)));case c:case h:case g:return kt(+e,+t);case f:return e.name==t.name&&e.message==t.message;case b:case w:return e==t+"";case m:var u=X;case _:var p=a&s;if(u||(u=te),e.size!=t.size&&!p)return!1;var d=l.get(e);if(d)return d==t;a|=o,l.set(e,t);var y=ht(u(e),u(t),r,i,a,l);return l.delete(e),y;case k:if(Ie)return Ie.call(e)==Ie.call(t)}return!1}function pt(e,t,n,r,i,o){var a=i&s,l=Ot(e),u=l.length,c=Ot(t),h=c.length;if(u!=h&&!a)return!1;for(var f=u;f--;){var p=l[f];if(!(a?p in t:ue.call(t,p)))return!1}var d=o.get(e);if(d&&o.get(t))return d==t;var m=!0;o.set(e,t),o.set(t,e);for(var g=a;++f<u;){p=l[f];var y=e[p],v=t[p];if(r)var b=a?r(v,y,p,t,e,o):r(y,v,p,e,t,o);if(!(void 0===b?y===v||n(y,v,r,i,o):b)){m=!1;break}g||(g="constructor"==p)}if(m&&!g){var _=e.constructor,w=t.constructor;_!=w&&"constructor"in e&&"constructor"in t&&!("function"==typeof _&&_ instanceof _&&"function"==typeof w&&w instanceof w)&&(m=!1)}return o.delete(e),o.delete(t),m}function dt(e,t){var n=e.__data__;return vt(t)?n["string"==typeof t?"string":"hash"]:n.map}function mt(e,t){var n=J(e,t);return lt(n)?n:void 0}je.prototype.clear=Re,je.prototype.delete=Be,je.prototype.get=Oe,je.prototype.has=Pe,je.prototype.set=Ne,De.prototype.clear=Me,De.prototype.delete=Fe,De.prototype.get=Le,De.prototype.has=Ue,De.prototype.set=qe,ze.prototype.clear=Ke,ze.prototype.delete=He,ze.prototype.get=Ve,ze.prototype.has=$e,ze.prototype.set=We,Ge.prototype.add=Ge.prototype.push=Ye,Ge.prototype.has=Ze,Je.prototype.clear=Qe,Je.prototype.delete=Xe,Je.prototype.get=et,Je.prototype.has=tt,Je.prototype.set=nt;var gt=ot;function yt(e,t){return t=null==t?a:t,!!t&&("number"==typeof e||M.test(e))&&e>-1&&e%1==0&&e<t}function vt(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function bt(e){return!!se&&se in e}function _t(e){var t=e&&e.constructor,n="function"==typeof t&&t.prototype||ie;return e===n}function wt(e){if(null!=e){try{return le.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function kt(e,t){return e===t||e!=e&&t!=t}function Et(e){return Ct(e)&&ue.call(e,"callee")&&(!de.call(e,"callee")||ce.call(e)==l)}(ye&&gt(new ye(new ArrayBuffer(1)))!=x||ve&&gt(new ve)!=m||be&&gt(be.resolve())!=v||_e&&gt(new _e)!=_||we&&gt(new we)!=E)&&(gt=function(e){var t=ce.call(e),n=t==y?e.constructor:void 0,r=n?wt(n):void 0;if(r)switch(r){case Ee:return x;case Se:return m;case xe:return v;case Ce:return _;case Ae:return E}return t});var St=Array.isArray;function xt(e){return null!=e&&It(e.length)&&!Tt(e)}function Ct(e){return Rt(e)&&xt(e)}function At(e,t,n){n="function"==typeof n?n:void 0;var r=n?n(e,t):void 0;return void 0===r?st(e,t,n):!!r}function Tt(e){var t=jt(e)?ce.call(e):"";return t==p||t==d}function It(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=a}function jt(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Rt(e){return!!e&&"object"==typeof e}var Bt=W?Z(W):ut;function Ot(e){return xt(e)?rt(e):ct(e)}n.exports=At}).call(this,n(8),n(85)(e))},function(e,t,n){"use strict";(function(t){const r=n(35);e.exports=(e=>{if(!t.isBuffer(e))throw new Error("arg needs to be a buffer");let n=[];for(;e.length>0;){const t=r.decode(e);n.push(t),e=e.slice(r.decode.bytes)}return n})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports="\n message Message {\n message Wantlist {\n message Entry {\n // changed from string to bytes, it makes a difference in JavaScript\n optional bytes block = 1; // the block cid (cidV0 in bitswap 1.0.0, cidV1 in bitswap 1.1.0)\n optional int32 priority = 2; // the priority (normalized). default to 1\n optional bool cancel = 3; // whether this revokes an entry\n }\n\n repeated Entry entries = 1; // a list of wantlist entries\n optional bool full = 2; // whether this is the full wantlist. default to false\n }\n\n message Block {\n optional bytes prefix = 1; // CID prefix (cid version, multicodec and multihash prefix (type + length)\n optional bytes data = 2;\n }\n\n optional Wantlist wantlist = 1;\n repeated bytes blocks = 2; // used to send Blocks in bitswap 1.0.0\n repeated Block payload = 3; // used to send Blocks in bitswap 1.1.0\n }\n"},function(e,t,n){"use strict";const r=n(207).Entry,i=n(9),o=n(24);e.exports=class e{constructor(e,t,n){o(i.isCID(e),"needs valid cid"),this.entry=new r(e,t),this.cancel=Boolean(n)}get cid(){return this.entry.cid}set cid(e){this.entry.cid=e}get priority(){return this.entry.priority}set priority(e){this.entry.priority=e}get[Symbol.toStringTag](){const e=this.cid.toBaseEncodedString();return`BitswapMessageEntry ${e} <cancel: ${this.cancel}, priority: ${this.priority}>`}equals(e){return this.cancel===e.cancel&&this.entry.equals(e.entry)}}},function(e,t,n){"use strict";const r=n(24),i=n(9);class o{constructor(e,t){r(i.isCID(e),"must be valid CID"),this._refCounter=1,this.cid=e,this.priority=t||1}inc(){this._refCounter+=1}dec(){this._refCounter=Math.max(0,this._refCounter-1)}hasRefs(){return this._refCounter>0}get[Symbol.toStringTag](){const e=this.cid.toBaseEncodedString();return`WantlistEntry <key: ${e}, priority: ${this.priority}, refs: ${this._refCounter}>`}equals(e){return this._refCounter===e._refCounter&&this.cid.equals(e.cid)&&this.priority===e.priority}}e.exports=o},function(e,t,n){"use strict";const r=n(428),i=n(206),o=n(100).logger;e.exports=class e{constructor(e,t,n){this.peerId=t,this.network=n,this.refcnt=1,this._entries=[],this._log=o(e,"msgqueue",t.toB58String().slice(0,8)),this.sendEntries=r(this._sendEntries.bind(this),200)}addMessage(e){e.empty||this.send(e)}addEntries(e){this._entries=this._entries.concat(e),this.sendEntries()}_sendEntries(){if(!this._entries.length)return;const e=new i(!1);this._entries.forEach(t=>{t.cancel?e.cancel(t.cid):e.addEntry(t.cid,t.priority)}),this._entries=[],this.addMessage(e)}send(e){this.network.connectTo(this.peerId,t=>{t?this._log.error("cant connect to peer %s: %s",this.peerId.toB58String(),t.message):(this._log("sending message"),this.network.sendMessage(this.peerId,e,e=>{e&&this._log.error("send error: %s",e.message)}))})}}},function(e,t,n){"use strict";const r=n(52),i=n(19),o=n(10),s=n(38),a=n(47),l=n(206),u=n(265),c=n(100).logger,h="/ipfs/bitswap/1.0.0",f="/ipfs/bitswap/1.1.0";class p{constructor(e,t,n,r){this._log=c(e.peerInfo.id,"network"),n=n||{},this.libp2p=e,this.bitswap=t,this.b100Only=n.b100Only||!1,this._stats=r,this._running=!1}start(e){this._running=!0,this._onPeerConnect=this._onPeerConnect.bind(this),this._onPeerDisconnect=this._onPeerDisconnect.bind(this),this._onConnection=this._onConnection.bind(this),this.libp2p.handle(h,this._onConnection),this.b100Only||this.libp2p.handle(f,this._onConnection),this.libp2p.on("peer:connect",this._onPeerConnect),this.libp2p.on("peer:disconnect",this._onPeerDisconnect),this.libp2p.peerBook.getAllArray().filter(e=>e.isConnected()).forEach(e=>this._onPeerConnect(e)),a(()=>e())}stop(e){this._running=!1,this.libp2p.unhandle(h),this.b100Only||this.libp2p.unhandle(f),this.libp2p.removeListener("peer:connect",this._onPeerConnect),this.libp2p.removeListener("peer:disconnect",this._onPeerDisconnect),a(()=>e())}_onConnection(e,t){this._running&&(this._log("incomming new bitswap connection: %s",e),i(t,r.decode(),i.asyncMap((e,t)=>l.deserialize(e,t)),i.asyncMap((e,n)=>{t.getPeerInfo((t,r)=>{if(t)return n(t);this.bitswap._receiveMessage(r.id,e,n)})}),i.onEnd(e=>{this._log("ending connection"),e&&this.bitswap._receiveError(e)})))}_onPeerConnect(e){this._running&&this.bitswap._onPeerConnected(e.id)}_onPeerDisconnect(e){this._running&&this.bitswap._onPeerDisconnected(e.id)}findProviders(e,t,n){this.libp2p.contentRouting.findProviders(e,{maxTimeout:u.providerRequestTimeout,maxNumProviders:t},n)}findAndConnect(e,t){o([t=>this.findProviders(e,u.maxProvidersPerRequest,t),(e,t)=>{this._log("connecting to providers",e.map(e=>e.id.toB58String())),s(e,(e,t)=>this.connectTo(e,t))}],t)}provide(e,t){this.libp2p.contentRouting.provide(e,t)}sendMessage(e,t,n){if(!this._running)return n(new Error("network isn't running"));const r=e.toB58String()?e.toB58String():e.id.toB58String();this._log("sendMessage to %s",r,t),this._dialPeer(e,(r,i,o)=>{if(r)return n(r);let s;switch(o){case h:s=t.serializeToBitswap100();break;case f:s=t.serializeToBitswap110();break;default:return n(new Error("Unkown protocol: "+o))}d(i,s,e=>{e&&this._log.error(e)}),n(),this._updateSentStats(e,t.blocks)})}connectTo(e,t){if(!this._running)return t(new Error("network isn't running"));this.libp2p.dial(e,t)}_dialPeer(e,t){this.libp2p.dialProtocol(e,f,(n,r)=>{n?this.libp2p.dialProtocol(e,h,(e,n)=>{if(e)return t(e);t(null,n,h)}):t(null,r,f)})}_updateSentStats(e,t){const n=e.toB58String();this._stats&&(t.forEach(e=>this._stats.push(n,"dataSent",e.data.length)),this._stats.push(n,"blocksSent",t.size))}}function d(e,t,n){i(i.values([t]),r.encode(),e,i.onEnd(n))}e.exports=p},function(e,t,n){"use strict";const r=n(5).Buffer;e.exports=o;const i=10240;function o(e){e=Object.assign({fixed:!1},e||{});const t=n(35);let i=e.fixed?null:s(),o=0,a=!1;return n=>(l,u)=>{if(l&&(a=l),a)return u(a);n(null,(n,l)=>{if(n&&(a=n),a)return u(a);if(!a&&!r.isBuffer(l))return a=new Error("data must be a buffer"),u(a);const c=a?0:l.length;let h;if(e.fixed?(h=r.alloc(4),h.writeInt32BE(c,0)):(t.encode(c,i,o),o+=t.encode.bytes,h=i.slice(o-t.encode.bytes,o),i.length-o<100&&(i=s(),o=0)),a)return u(null,h);u(null,r.concat([h,l],(e.fixed?4:t.encode.bytes)+c))})}}function s(){return r.alloc(i)}},function(e,t,n){"use strict";const r=n(35),i=n(429),o=n(5).Buffer,s=n(63);t.decode=c,t.decodeFromReader=h;const a=128,l=e=>!(128&e),u=4194304;function c(e){let t=new i,n=s(e=>{t.abort(e)});return r=>{function i(){let r=!0,o=!1;const s=(e,t)=>{o=!0,e?(n.end(e),r=!1):(n.push(t),r||i())};for(;r;)o=!1,f(t,e,s),o||(r=!1)}return t(r),i(),n}}function h(e,t,n){"function"==typeof t&&(n=t,t={}),f(e,t,function e(t,r){if(t)return n(!0===t?new Error("Unexpected end of input from reader."):t);n(null,r)})}function f(e,t,n){t=Object.assign({fixed:!1,maxLength:u},t||{}),t.fixed?p(e,t.maxLength,n):d(e,t.maxLength,n)}function p(e,t,n){e.read(4,(r,i)=>{if(r)return n(r);const o=i.readInt32BE(0);if(o>t)return n(new Error("size longer than max permitted length of "+t+"!"));m(e,o,n)})}function d(e,t,n){let i=[];function s(){e.read(1,(a,u)=>{if(a)return n(a);if(i.push(u),u&&!l(u[0]))return void s();const c=r.decode(o.concat(i));if(c>t)return n(new Error("size longer than max permitted length of "+t+"!"));m(e,c,(e,t)=>e?n(e):(i=[],t.length<c?n(new Error("Message length does not match prefix specified length.")):void n(null,t)))})}0===i.length&&s()}function m(e,t,n){e.read(t,(e,t)=>{if(e)return n(e);n(null,t)})}},function(e,t,n){(function(t){e.exports=function(){var e=[],n=0;function r(){return e.reduce(function(e,t){return e+t.length},0)}return{length:n,data:this,add:function(r){if(!t.isBuffer(r))throw new Error("data must be a buffer, was: "+JSON.stringify(r));return this.length=n+=r.length,e.push(r),this},has:function(e){return null==e?n>0:n>=e},get:function(r){var i;if(null==r||r===n){n=0;var o=e;return e=[],1==o.length?o[0]:t.concat(o)}if(e.length>1&&r<=(i=e[0].length)){var s=e[0].slice(0,r);return r===i?e.shift():e[0]=e[0].slice(r,i),n-=r,s}if(r<n){for(var a=[],l=0;l+e[0].length<r;){var u=e.shift();l+=u.length,a.push(u)}return l<r&&(a.push(e[0].slice(0,r-l)),e[0]=e[0].slice(r-l,e[0].length),this.length=n-=r),t.concat(a)}throw new Error("could not get "+r+" bytes")}}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(38),i=n(122),o=n(10),s=n(47),a=n(59),l=n(428),u=n(206),c=n(207),h=n(900),{logger:f,groupBy:p,pullAllWith:d,uniqWith:m}=n(100),g=524288;class y{constructor(e,t,n,r){this._log=f(e,"engine"),this.blockstore=t,this.network=n,this._stats=r,this.ledgerMap=new Map,this._running=!1,this._tasks=[],this._outbox=l(this._processTasks.bind(this),100)}_sendBlocks(e,t,n){const r=t.reduce((e,t)=>e+t.data.byteLength,0);if(r<g)return this._sendSafeBlocks(e,t,n);let o=0,a=[],l=t.length;i(t,(t,n)=>{if(l--,a.push(t),o+=t.data.byteLength,o>=g||0===l){o=0;const t=a.slice();a=[],this._sendSafeBlocks(e,t,e=>{e&&this._log("sendblock error: %s",e.message),n()})}else s(n)},n)}_sendSafeBlocks(e,t,n){const r=new u(!1);t.forEach(e=>r.addBlock(e)),this.network.sendMessage(e,r,n)}_processTasks(){if(!this._running||!this._tasks.length)return;const e=this._tasks;this._tasks=[];const t=e.map(e=>e.entry),n=t.map(e=>e.cid),i=m((e,t)=>e.equals(t),n),s=p(e=>e.target.toB58String(),e);o([e=>a(i,(e,t)=>{this.blockstore.get(e,t)},e),(e,t)=>r(Object.values(s),(t,r)=>{const i=t[0].target,o=n.map(t=>e.find(e=>e.cid.equals(t)));this._sendBlocks(i,o,e=>{e?this._log.error("should never happen: ",e):o.forEach(e=>this.messageSent(i,e)),r()})},t)],e=>{this._tasks=[],e&&this._log.error(e)})}wantlistForPeer(e){const t=e.toB58String();return this.ledgerMap.has(t)?this.ledgerMap.get(t).wantlist.sortedEntries():new Map}ledgerForPeer(e){const t=e.toB58String(),n=this.ledgerMap.get(t);return n?{peer:n.partner.toPrint(),value:n.debtRatio(),sent:n.accounting.bytesSent,recv:n.accounting.bytesRecv,exchanged:n.exchangeCount}:null}peers(){return Array.from(this.ledgerMap.values()).map(e=>e.partner)}receivedBlocks(e){e.length&&(this.ledgerMap.forEach(t=>{e.map(e=>t.wantlistContains(e)).filter(Boolean).forEach(e=>{this._tasks.push({entry:e,target:t.partner})})}),this._outbox())}messageReceived(e,t,n){const r=this._findOrCreate(e);if(t.empty)return s(n);if(t.full&&(r.wantlist=new c),this._processBlocks(t.blocks,r),0===t.wantlist.size)return s(n);let i=[],o=[];t.wantlist.forEach(e=>{e.cancel?(r.cancelWant(e.cid),i.push(e)):(r.wants(e.cid,e.priority),o.push(e))}),this._cancelWants(r,e,i),this._addWants(r,e,o,n)}_cancelWants(e,t,n){const r=t.toB58String();this._tasks=d((e,t)=>{const n=e.target.toB58String()===r,i=e.entry.cid.equals(t.cid);return n&&i},this._tasks,n)}_addWants(e,t,n,i){r(n,(e,n)=>{this.blockstore.has(e.cid,(r,i)=>{r?this._log.error("failed existence check"):i&&this._tasks.push({entry:e.entry,target:t}),n()})},()=>{this._outbox(),i()})}_processBlocks(e,t,n){const r=[];e.forEach((e,n)=>{this._log("got block (%s bytes)",e.data.length),t.receivedBytes(e.data.length),r.push(e.cid)}),this.receivedBlocks(r)}messageSent(e,t){const n=this._findOrCreate(e);n.sentBytes(t?t.data.length:0),t&&t.cid&&n.wantlist.remove(t.cid)}numBytesSentTo(e){return this._findOrCreate(e).accounting.bytesSent}numBytesReceivedFrom(e){return this._findOrCreate(e).accounting.bytesRecv}peerDisconnected(e){}_findOrCreate(e){const t=e.toB58String();if(this.ledgerMap.has(t))return this.ledgerMap.get(t);const n=new h(e);return this.ledgerMap.set(t,n),this._stats&&this._stats.push(t,"peerCount",1),n}start(e){this._running=!0,s(()=>e())}stop(e){this._running=!1,s(()=>e())}}e.exports=y},function(e,t,n){"use strict";const r=n(207);class i{constructor(e){this.partner=e,this.wantlist=new r,this.exchangeCount=0,this.sentToPeer=new Map,this.accounting={bytesSent:0,bytesRecv:0}}sentBytes(e){this.exchangeCount++,this.lastExchange=(new Date).getTime(),this.accounting.bytesSent+=e}receivedBytes(e){this.exchangeCount++,this.lastExchange=(new Date).getTime(),this.accounting.bytesRecv+=e}wants(e,t){this.wantlist.add(e,t)}cancelWant(e){this.wantlist.remove(e)}wantlistContains(e){return this.wantlist.contains(e)}debtRatio(){return this.accounting.bytesSent/(this.accounting.bytesRecv+1)}}e.exports=i},function(e,t,n){"use strict";const r=n(6).EventEmitter,i=n(265),o=n(100).logger,s=e=>`unwant:${e}`,a=e=>`block:${e}`;class l extends r{constructor(e){super(),this.setMaxListeners(i.maxListeners),this._log=o(e,"notif"),this._unwantListeners={},this._blockListeners={}}hasBlock(e){const t=`block:${e.cid.buffer.toString()}`;this._log(t),this.emit(t,e)}wantBlock(e,t,n){const r=e.buffer.toString();this._log(`wantBlock:${r}`),this._unwantListeners[r]=(()=>{this._log(`manual unwant: ${r}`),this._cleanup(r),n()}),this._blockListeners[r]=(e=>{this._cleanup(r),t(e)}),this.once(s(r),this._unwantListeners[r]),this.once(a(r),this._blockListeners[r])}unwantBlock(e){const t=`unwant:${e.buffer.toString()}`;this._log(t),this.emit(t)}_cleanup(e){this._unwantListeners[e]&&(this.removeListener(s(e),this._unwantListeners[e]),delete this._unwantListeners[e]),this._blockListeners[e]&&(this.removeListener(a(e),this._blockListeners[e]),delete this._blockListeners[e])}}e.exports=l},function(e,t,n){"use strict";const r=n(6),i=n(903),o={movingAverageIntervals:[6e4,3e5,9e5]};class s extends r{constructor(e,t){super();const n=Object.assign({},o,t);if("number"!=typeof n.computeThrottleTimeout)throw new Error("need computeThrottleTimeout");if("number"!=typeof n.computeThrottleMaxQueueSize)throw new Error("need computeThrottleMaxQueueSize");this._initialCounters=e,this._options=n,this._enabled=this._options.enabled,this._global=new i(e,n),this._global.on("update",e=>this.emit("update",e)),this._peers=new Map}enable(){this._enabled=!0,this._options.enabled=!0,this._global.enable()}disable(){this._enabled=!1,this._options.enabled=!1,this._global.disable()}stop(){this._enabled=!1,this._global.stop();for(let e of this._peers)e[1].stop()}get snapshot(){return this._global.snapshot}get movingAverages(){return this._global.movingAverages}forPeer(e){return e.toB58String&&(e=e.toB58String()),this._peers.get(e)}push(e,t,n){if(this._enabled&&(this._global.push(t,n),e)){let r=this._peers.get(e);r||(r=new i(this._initialCounters,this._options),this._peers.set(e,r)),r.push(t,n)}}disconnected(e){const t=e.toB58String(),n=this._peers.get(t);n&&(n.stop(),this._peers.delete(t))}}e.exports=s},function(e,t,n){"use strict";const r=n(6),i=n(55),o=n(431);class s extends r{constructor(e,t){super(),this._options=t,this._queue=[],this._stats={},this._frequencyLastTime=Date.now(),this._frequencyAccumulators={},this._movingAverages={},this._update=this._update.bind(this),e.forEach(e=>{this._stats[e]=i(0),this._movingAverages[e]={},this._options.movingAverageIntervals.forEach(t=>{const n=this._movingAverages[e][t]=o(t);n.push(this._frequencyLastTime,0)})}),this._enabled=this._options.enabled}enable(){this._enabled=!0}disable(){this._disabled=!0}stop(){this._timeout&&clearTimeout(this._timeout)}get snapshot(){return Object.assign({},this._stats)}get movingAverages(){return Object.assign({},this._movingAverages)}push(e,t){this._enabled&&(this._queue.push([e,t,Date.now()]),this._resetComputeTimeout())}_resetComputeTimeout(){this._timeout&&clearTimeout(this._timeout),this._timeout=setTimeout(this._update,this._nextTimeout())}_nextTimeout(){const e=this._queue.length/this._options.computeThrottleMaxQueueSize;return Math.max(this._options.computeThrottleTimeout*(1-e),0)}_update(){if(this._timeout=null,this._queue.length){let e;for(;this._queue.length;){const t=e=this._queue.shift();this._applyOp(t)}this._updateFrequency(e[2]),this.emit("update",this._stats)}}_updateFrequency(e){const t=e-this._frequencyLastTime;Object.keys(this._stats).forEach(n=>{this._updateFrequencyFor(n,t,e)}),this._frequencyLastTime=e}_updateFrequencyFor(e,t,n){const r=this._frequencyAccumulators[e]||0;this._frequencyAccumulators[e]=0;const i=r/t*1e3;let s=this._movingAverages[e];s||(s=this._movingAverages[e]={}),this._options.movingAverageIntervals.forEach(e=>{let t=s[e];t||(t=s[e]=o(e)),t.push(n,i)})}_applyOp(e){const t=e[0],n=e[1];if("number"!=typeof n)throw new Error("invalid increment number:",n);let r;r=this._stats.hasOwnProperty(t)?this._stats[t]:this._stats[t]=i(0),this._stats[t]=r.plus(n),this._frequencyAccumulators[t]||(this._frequencyAccumulators[t]=0),this._frequencyAccumulators[t]+=n}}e.exports=s},function(e,t,n){"use strict";e.exports=a;var r=n(78),i=a.prototype,o=new Date%1e9;function s(){return(1e9*Math.random()>>>0)+o++}function a(e){e=e||{},this.id=e.id||s(),this.max=e.max||1/0,this.items=e.items||[],this._lookup={},this.size=this.items.length,this.lastModified=new Date(e.lastModified||new Date);for(var t,n,r=this.items.length;r--;)t=this.items[r],n=new Date(t.expires)-new Date,this._lookup[t.key]=t,n>0?this.expire(t.key,n):n<=0&&this.delete(t.key)}i.has=function(e){return e in this._lookup},i.get=function(e){if(!this.has(e))return null;var t=this._lookup[e];return t.refresh&&this.expire(e,t.refresh),this.items.splice(this.items.indexOf(t),1),this.items.push(t),t.value},i.meta=function(e){if(!this.has(e))return null;var t=this._lookup[e];return"meta"in t?t.meta:null},i.set=function(e,t,n){var r=this._lookup[e],i=this._lookup[e]={key:e,value:t};return this.lastModified=new Date,r?(clearTimeout(r.timeout),this.items.splice(this.items.indexOf(r),1,i)):(this.size>=this.max&&this.delete(this.items[0].key),this.items.push(i),this.size++),n&&("ttl"in n&&this.expire(e,n.ttl),"meta"in n&&(i.meta=n.meta),n.refresh&&(i.refresh=n.ttl)),this},i.delete=function(e){var t=this._lookup[e];return!!t&&(this.lastModified=new Date,this.items.splice(this.items.indexOf(t),1),clearTimeout(t.timeout),delete this._lookup[e],this.size--,this)},i.expire=function(e,t){var n=t||0,i=this._lookup[e];if(!i)return this;if("string"==typeof n&&(n=r(t)),"number"!=typeof n)throw new TypeError("Expiration time must be a string or number.");return clearTimeout(i.timeout),i.timeout=setTimeout(this.delete.bind(this,i.key),n),i.expires=Number(new Date)+n,this},i.clear=function(){for(var e=this.items.length;e--;)this.delete(this.items[e].key);return this},i.toJSON=function(){for(var e=new Array(this.items.length),t,n=e.length;n--;)t=this.items[n],e[n]={key:t.key,meta:t.meta,value:t.value,expires:t.expires,refresh:t.refresh};return{id:this.id,max:isFinite(this.max)?this.max:void 0,lastModified:this.lastModified,items:e}}},function(e,t,n){"use strict";const r=n(15),{Key:i}=n(28),o=n(43),s=n(13),a=n(4),l=a("ipfs:ipns:publisher");l.error=a("ipfs:ipns:publisher:error");const u=n(158),c=36e5;class h{constructor(e,t){this._routing=e,this._datastore=t}publishWithEOL(e,t,n,i){if(!e||!e.bytes){const e="one or more of the provided parameters are not defined";return l.error(e),i(s(new Error(e),"ERR_UNDEFINED_PARAMETER"))}r.createFromPrivKey(e.bytes,(r,o)=>{if(r)return i(r);this._updateOrCreateRecord(e,t,n,o,(e,t)=>{if(e)return i(e);this._putRecordToRouting(t,o,i)})})}publish(e,t,n){this.publishWithEOL(e,t,c,n)}_putRecordToRouting(e,t,n){if(!r.isPeerId(t)){const e="peerId received is not valid";return l.error(e),n(s(new Error(e),"ERR_INVALID_PEER_ID"))}const i=t._pubKey;u.embedPublicKey(i,e,(r,s)=>{if(r)return n(r);let a;try{a=u.getIdKeys(t.toBytes())}catch(r){return l.error(r),n(r)}o([n=>this._publishEntry(a.routingKey,s||e,t,n),e=>this._publishPublicKey(a.routingPubKey,i,t,e)],t=>{if(t)return l.error(t),n(t);n(null,s||e)})})}_publishEntry(e,t,n,r){if(!i.isKey(e)){const e="datastore key does not have a valid format";return l.error(e),r(s(new Error(e),"ERR_INVALID_DATASTORE_KEY"))}let o;try{o=u.marshal(t)}catch(e){return l.error(e),r(e)}this._routing.put(e.toBuffer(),o,(t,n)=>{if(t){const t=`ipns record for ${e.toString()} could not be stored in the routing`;return l.error(t),r(s(new Error(t),"ERR_PUTTING_TO_ROUTING"))}l(`ipns record for ${e.toString()} was stored in the routing`),r(null,n)})}_publishPublicKey(e,t,n,r){if(!i.isKey(e)){const e="datastore key does not have a valid format";return l.error(e),r(s(new Error(e),"ERR_INVALID_DATASTORE_KEY"))}if(!t||!t.bytes){const e="one or more of the provided parameters are not defined";return l.error(e),r(s(new Error(e),"ERR_UNDEFINED_PARAMETER"))}this._routing.put(e.toBuffer(),t.bytes,(t,n)=>{if(t){const t=`public key for ${e.toString()} could not be stored in the routing`;return l.error(t),r(s(new Error(t),"ERR_PUTTING_TO_ROUTING"))}l(`public key for ${e.toString()} was stored in the routing`),r(null,n)})}_getPublished(e,t,n){if(!r.isPeerId(e)){const e="peerId received is not valid";return l.error(e),n(s(new Error(e),"ERR_INVALID_PEER_ID"))}t=t||{};const i=!1!==t.checkRouting;this._datastore.get(u.getLocalKey(e.id),(t,r)=>{if(t){if("ERR_NOT_FOUND"!==t.code){const t=`unexpected error getting the ipns record ${e.id} from datastore`;return l.error(t),n(s(new Error(t),"ERR_UNEXPECTED_DATASTORE_RESPONSE"))}if(!i)return n(s(t));let r;try{r=u.getIdKeys(e.toBytes())}catch(t){return l.error(t),n(t)}this._routing.get(r.routingKey.toBuffer(),(e,t)=>{if(e)return n(e);this._unmarshalData(t,n)})}else this._unmarshalData(r,n)})}_unmarshalData(e,t){let n;try{n=u.unmarshal(e)}catch(e){return l.error(e),t(s(e,"ERR_INVALID_RECORD_DATA"))}t(null,n)}_updateOrCreateRecord(e,t,n,i,o){if(!r.isPeerId(i)){const e="peerId received is not valid";return l.error(e),o(s(new Error(e),"ERR_INVALID_PEER_ID"))}const a={checkRouting:!0};this._getPublished(i,a,(r,a)=>{if(r&&"ERR_NOT_FOUND"!==r.code){const e=`unexpected error when determining the last published IPNS record for ${i.id}`;return l.error(e),o(s(new Error(e),"ERR_DETERMINING_PUBLISHED_RECORD"))}let c=0;a&&void 0!==a.sequence&&(c=a.value.toString()!==t?a.sequence+1:a.sequence),u.create(e,t,c,n,(e,n)=>{if(e){const e=`ipns record for ${t} could not be created`;return l.error(e),o(s(new Error(e),"ERR_CREATING_IPNS_RECORD"))}const r=u.marshal(n);this._datastore.put(u.getLocalKey(i.id),r,(e,r)=>{if(e){const e=`ipns record for ${t} could not be stored in the datastore`;return l.error(e),o(s(new Error(e),"ERR_STORING_IN_DATASTORE"))}l(`ipns record for ${t} was stored in the datastore`),o(null,n)})})})}}t=e.exports=h},function(e,t){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",r="0123456789ABCDEFGHIJKLMNOPQRSTUV",i="0123456789ABCDEFGHJKMNPQRSTVWXYZ";e.exports=function e(t,o,s){var a,l;switch(s=s||{},o){case"RFC3548":case"RFC4648":a=n,l=!0;break;case"RFC4648-HEX":a=r,l=!0;break;case"Crockford":a=i,l=!1;break;default:throw new Error("Unknown base32 variant: "+o)}for(var u=void 0!==s.padding?s.padding:l,c=t.byteLength,h=new Uint8Array(t),f=0,p=0,d="",m=0;m<c;m++)for(p=p<<8|h[m],f+=8;f>=5;)d+=a[p>>>f-5&31],f-=5;if(f>0&&(d+=a[p<<5-f&31]),u)for(;d.length%8!=0;)d+="=";return d}},function(e,t,n){
/**
* Timestamp for 64-bit time_t, nanosecond precision and strftime
*
* @author Yusuke Kawasaki
* @license MIT
* @see https://github.com/kawanet/timestamp-nano
*/
var r=function(){e.exports=v;var t=86400,n=3200,r=146097*n/400,i=t*r,o=1e3*i,s=1e11*t,a=16777216,l=4294967296,u=1e6,c=1e9,h="000000000",f=Math.trunc||N,p=v.prototype;v.fromDate=C,v.fromInt64BE=O(0,1,2,3,0,4),v.fromInt64LE=O(3,2,1,0,4,0),v.fromString=x,v.fromTimeT=A,p.year=0,p.time=0,p.nano=0,p.addNano=E,p.getNano=S,p.getTimeT=I,p.getYear=b,p.toDate=w,p.toJSON=j,p.toString=R,p.writeInt64BE=B(0,1,2,3,0,4),p.writeInt64LE=B(3,2,1,0,4,0);var d="%Y-%m-%dT%H:%M:%S.%NZ",m=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],g=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],y={"%":"%",F:"%Y-%m-%d",n:"\n",R:"%H:%M",T:"%H:%M:%S",t:"\t",X:"%T",Z:"GMT",z:"+0000"};return v;function v(e,t,n){var r=this;if(!(r instanceof v))return new v(e,t,n);r.time=+e||0,r.nano=+t||0,r.year=+n||0,_(r)}function b(){var e=this.toDate().getUTCFullYear();return e+this.year}function _(e){var t=e.year,r=e.time,i=e.nano,a,l;if(i<0||u<=i){var c=Math.floor(i/u);i-=c*u,r+=c,a=1}var h=t%n;if(r<-s||s<r||h){l=f(r/o),l&&(t+=l*n,r-=l*o);var p=k(r);p.setUTCFullYear(h+p.getUTCFullYear()),t-=h,r=+p,l=f(t/n);var d=r+l*o;l&&-s<=d&&d<=s&&(t-=l*n,r=d),a=1}return a&&(e.year=t,e.time=r,e.nano=i),e}function w(){var e=_(this);return k(e.time)}function k(e){var t=new Date(0);return t.setTime(e),t}function E(e){return this.nano+=+e||0,this}function S(){var e=_(this);return(e.time%1e3*u+ +e.nano+c)%c}function x(e){var t,n=new v;e+="";var r=e.replace(/^\s*[+\-]?\d+/,function(e){var t=+e,r=1970+(t-1970)%400;return n.year=t-r,r}).replace(/(?:Z|([+\-]\d{2}):?(\d{2}))$/,function(e,n,r){return n<0&&(r*=-1),t=6e4*(60*+n+ +r),""}).replace(/\.\d+$/,function(e){return n.nano=+(e+h).substr(1,9),""}).split(/\D+/);if(r.length>1?r[1]--:r[1]=0,n.time=t=Date.UTC.apply(Date,r)-(t||0),isNaN(t))throw new TypeError("Invalid Date");return _(n)}function C(e){return new v(+e)}function A(e){return T(e,0)}function T(e,t){t|=0,t*=l,e=+e||0;var r=f(t/i)+f(e/i),o=t%i+e%i,s=f(o/i);return s&&(r+=s,o-=s*i),new v(1e3*o,0,r*n)}function I(){var e=_(this),i=Math.floor(e.time/1e3),o=e.year;return o&&(i+=o*r*t/n),i}function j(){return this.toString().replace(/0{1,6}Z$/,"Z")}function R(e){var t=this,n=t.toDate(),r={H:u,L:f,M:c,N:p,S:h,Y:o,a:v,b:b,d:a,e:l,m:s};return i(e||d);function i(e){return e.replace(/%./g,function(e){var t=e[1],n=y[t],o=r[t];return n?i(n):o?o():e})}function o(){var e=t.getYear();return e>999999?"+"+e:e>9999?"+"+F(e,6):e>=0?F(e,4):e>=-999999?"-"+F(-e,6):e}function s(){return M(n.getUTCMonth()+1)}function a(){return M(n.getUTCDate())}function l(){return D(n.getUTCDate())}function u(){return M(n.getUTCHours())}function c(){return M(n.getUTCMinutes())}function h(){return M(n.getUTCSeconds())}function f(){return F(n.getUTCMilliseconds(),3)}function p(){return F(t.getNano(),9)}function v(){return g[n.getUTCDay()]}function b(){return m[n.getUTCMonth()]}}function B(e,i,o,s,a,u){return c;function c(e,i){var o=_(this);e||(e=new Array(8)),P(e,i|=0);var s=Math.floor(o.time/1e3),c=o.year*(r*t/n),p=f(c/l)+f(s/l),d=c%l+s%l,m=Math.floor(d/l);return m&&(p+=m,d-=m*l),h(e,i+a,p),h(e,i+u,d),e}function h(t,n,r){t[n+e]=r>>24&255,t[n+i]=r>>16&255,t[n+o]=r>>8&255,t[n+s]=255&r}}function O(e,t,n,r,i,o){return s;function s(e,t){P(e,t|=0);var n=l(e,t+i),r=l(e,t+o);return T(r,n)}function l(i,o){return i[o+e]*a+(i[o+t]<<16|i[o+n]<<8|i[o+r])}}function P(e,t){var n=e&&e.length;if(null==n)throw new TypeError("Invalid Buffer");if(n<t+8)throw new RangeError("Out of range")}function N(e){var t=e-e%1;return 0===t&&(e<0||0===e&&1/e!=1/0)?-0:t}function D(e){return(e>9?"":" ")+(0|e)}function M(e){return(e>9?"":"0")+(0|e)}function F(e,t){return(h+(0|e)).substr(-t)}}()},function(e,t,n){"use strict";const r=n(57),i='\nmessage IpnsEntry {\n enum ValidityType {\n\t\tEOL = 0; // setting an EOL says "this record is valid until..."\n\t}\n\n required bytes value = 1;\n\trequired bytes signature = 2;\n\n\toptional ValidityType validityType = 3;\n\toptional bytes validity = 4;\n\n\toptional uint64 sequence = 5;\n\n\toptional uint64 ttl = 6;\n\n\t// in order for nodes to properly validate a record upon receipt, they need the public\n\t// key associated with it. For old RSA keys, its easiest if we just send this as part of\n\t// the record itself. For newer ed25519 keys, the public key can be embedded in the\n\t// peerID, making this field unnecessary.\n\toptional bytes pubKey = 7;\n}\n';e.exports=r(i).IpnsEntry},function(e,t,n){"use strict";e.exports.toRFC3339=(e=>{const t=e.getUTCFullYear(),n=String(e.getUTCMonth()+1).padStart(2,"0"),r=String(e.getUTCDate()).padStart(2,"0"),i=String(e.getUTCHours()).padStart(2,"0"),o=String(e.getUTCMinutes()).padStart(2,"0"),s=String(e.getUTCSeconds()).padStart(2,"0"),a=e.getUTCMilliseconds(),l=1e3*a*1e3;return`${t}-${n}-${r}T${i}:${o}:${s}.${l}Z`}),e.exports.parseRFC3339=(e=>{const t=new RegExp("(\\d{4})-(\\d{2})-(\\d{2})T(\\d{2}):(\\d{2}):(\\d{2})\\.(\\d+)Z"),n=String(e).trim().match(t);if(!n)throw new Error("Invalid format");const r=parseInt(n[1],10),i=parseInt(n[2],10)-1,o=parseInt(n[3],10),s=parseInt(n[4],10),a=parseInt(n[5],10),l=parseInt(n[6],10),u=parseInt(n[7].slice(0,-6),10);return new Date(Date.UTC(r,i,o,s,a,l,u))})},function(e,t,n){"use strict";t.ERR_IPNS_EXPIRED_RECORD="ERR_IPNS_EXPIRED_RECORD",t.ERR_UNRECOGNIZED_VALIDITY="ERR_UNRECOGNIZED_VALIDITY",t.ERR_SIGNATURE_CREATION="ERR_SIGNATURE_CREATION",t.ERR_SIGNATURE_VERIFICATION="ERR_SIGNATURE_VERIFICATION",t.ERR_UNRECOGNIZED_FORMAT="ERR_UNRECOGNIZED_FORMAT",t.ERR_PEER_ID_FROM_PUBLIC_KEY="ERR_PEER_ID_FROM_PUBLIC_KEY",t.ERR_PUBLIC_KEY_FROM_ID="ERR_PUBLIC_KEY_FROM_ID",t.ERR_UNDEFINED_PARAMETER="ERR_UNDEFINED_PARAMETER"},function(e,t,n){"use strict";(function(r){const i=n(158),o=n(51),s=n(15),a=n(13),l=n(4),u=n(38),c=n(10),h=l("ipfs:ipns:republisher");h.error=l("ipfs:ipns:republisher:error");const f=6e4,p=60*f,d=4*p,m=24*p;class g{constructor(e,t,n,r,i){this._publisher=e,this._datastore=t,this._peerInfo=n,this._keychain=r,this._options=i,this._republishHandle=null}start(){if(this._republishHandle){const e="already running";throw h.error(e),a(new Error(e),"ERR_REPUBLISH_ALREADY_RUNNING")}const e={_onCancel:null,_timeoutId:null,runPeriodically:(t,n)=>{e._timeoutId=setTimeout(()=>{e._timeoutId=null,t(r=>{if(e._onCancel)return e._onCancel();e.runPeriodically(t,r||n)})},n)},cancel:t=>{if(e._timeoutId)return clearTimeout(e._timeoutId),t();e._onCancel=t}},{privKey:t}=this._peerInfo.id,{pass:n}=this._options;e.runPeriodically(e=>{this._republishEntries(t,n,()=>e(d))},f),this._republishHandle=e}stop(e){const t=this._republishHandle;if(!t){const t="not running";return h.error(t),e(a(new Error(t),"ERR_REPUBLISH_NOT_RUNNING"))}this._republishHandle=null,t.cancel(e)}_republishEntries(e,t,n){this._republishEntry(e,e=>{if(e){const e="cannot republish entry for the node's private key";h.error(e)}else t?this._keychain.listKeys((e,r)=>{e?h.error(e):u(r,(e,n)=>{c([n=>this._keychain.exportKey(e.name,t,n),(e,n)=>o.keys.import(e,t,n)],(e,t)=>{e?h.error(e):this._republishEntry(t,n)})},e=>{e&&h.error(e),n(null)})}):n(null)})}_republishEntry(e,t){if(!e||!e.bytes){const e="one or more of the provided parameters are not defined";return h.error(e),t(a(new Error(e),"ERR_UNDEFINED_PARAMETER"))}c([t=>s.createFromPrivKey(e.bytes,t),(e,t)=>this._getPreviousValue(e,t)],(n,r)=>{if(n)return t("ERR_NO_ENTRY_FOUND"===n.code?null:n);this._publisher.publishWithEOL(e,r,m,t)})}_getPreviousValue(e,t){if(!s.isPeerId(e)){const e="peerId received is not valid";return h.error(e),t(a(new Error(e),"ERR_INVALID_PEER_ID"))}this._datastore.get(i.getLocalKey(e.id),(n,o)=>{if(n&&n.notFound){const n=`no previous entry for record with id: ${e.id}`;return h.error(n),t(a(new Error(n),"ERR_NO_ENTRY_FOUND"))}if(n)return t(n);if(!r.isBuffer(o)){const e="found ipns record that we couldn't process";return h.error(e),t(a(new Error(e),"ERR_INVALID_IPNS_RECORD"))}let s;try{s=i.unmarshal(o)}catch(n){const e="found ipns record that we couldn't convert to a value";return h.error(e),t(a(new Error(e),"ERR_INVALID_IPNS_RECORD"))}t(null,s.value)})}}t=e.exports=g}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(158),i=n(51),o=n(15),s=n(13),a=n(4),l=a("ipfs:ipns:resolver");l.error=a("ipfs:ipns:resolver:error");const u=32;class c{constructor(e){this._routing=e}resolve(e,t,n){if("function"==typeof t&&(n=t,t={}),"string"!=typeof e){const e="one or more of the provided parameters are not valid";return l.error(e),n(s(new Error(e),"ERR_INVALID_PARAMETER"))}t=t||{};const r=t.recursive&&"true"===t.recursive.toString(),i=e.split("/");if(3!==i.length||""!==i[0]){const t=`invalid name syntax for ${e}`;return l.error(t),n(s(new Error(t),"ERR_INVALID_NAME_SYNTAX"))}const o=i[2];let a;r&&(a=u),this.resolver(o,a,(t,r)=>{if(t)return n(t);l(`${e} was locally resolved correctly`),n(null,r)})}resolver(e,t,n){if(0===t){const e=`could not resolve name (recursion limit of ${u} exceeded)`;return l.error(e),n(s(new Error(e),"ERR_RESOLVE_RECURSION_LIMIT"))}this._resolveName(e,(e,r)=>{if(e)return n(e);const i=r.split("/");if("ipfs"===i[1]||!t)return n(null,r);this.resolver(i[2],t-1,n)})}_resolveName(e,t){let n;try{n=o.createFromB58String(e)}catch(e){return t(e)}const{routingKey:a,routingPubKey:u}=r.getIdKeys(n.toBytes());this._routing.get(a.toBuffer(),(o,c)=>{if(o){if("ERR_NOT_FOUND"!==o.code){const e=`unexpected error getting the ipns record ${n.id}`;return l.error(e),t(s(new Error(e),"ERR_UNEXPECTED_ERROR_GETTING_RECORD"))}const r=`record requested was not found for ${e} (${a}) in the network`;return l.error(r),t(s(new Error(r),"ERR_NO_RECORD_FOUND"))}let h;try{h=r.unmarshal(c)}catch(o){const e="found ipns record that we couldn't convert to a value";return l.error(e),t(s(new Error(e),"ERR_INVALID_RECORD_RECEIVED"))}if(h.pubKey)return this._validateRecord(n,h,t);this._routing.get(a.toBuffer(),(r,o)=>{if(r){if("ERR_NOT_FOUND"!==r.code){const e=`unexpected error getting the public key for the ipns record ${n.id}`;return l.error(e),t(s(new Error(e),"ERR_UNEXPECTED_ERROR_GETTING_PUB_KEY"))}const i=`public key requested was not found for ${e} (${u}) in the network`;return l.error(i),t(s(new Error(i),"ERR_NO_RECORD_FOUND"))}try{n.pubKey=i.keys.unmarshalPublicKey(o)}catch(r){const e="found public key record that we couldn't convert to a value";return l.error(e),t(s(new Error(e),"ERR_INVALID_PUB_KEY_RECEIVED"))}this._validateRecord(n,h,t)})})}_validateRecord(e,t,n){r.extractPublicKey(e,t,(e,i)=>{if(e)return n(e);r.validate(i,t,e=>{if(e)return n(e);n(null,t.value.toString())})})}}t=e.exports=c},function(e,t,n){"use strict";const{TieredDatastore:r}=n(407),i=n(202),o=n(434),s=n(435);e.exports=(e=>{const t=[];let n;if(i(e._options,"EXPERIMENTAL.ipnsPubsub",!1)){const r=e.libp2p.pubsub,i=e._repo.datastore,s=e._peerInfo.id;n=new o(r,i,s),t.push(n)}if(i(e._options,"offline")||!i(e._options,"libp2p.dht.enabled",!1)){const n=new s(e._repo);t.push(n)}else t.push(e.libp2p.dht);return new r(t)})},function(e,t,n){"use strict";(function(r){const{Key:i}=n(28),{encodeBase32:o,keyToTopic:s,topicToKey:a}=n(915),l=n(13),u=n(24),c=n(4),h=c("datastore-pubsub:publisher");h.error=c("datastore-pubsub:publisher:error");class f{constructor(e,t,n,r,i){u.strictEqual(typeof r,"object","missing validator"),u.strictEqual(typeof r.validate,"function","missing validate function"),u.strictEqual(typeof r.select,"function","missing select function"),i&&u.strictEqual(typeof i,"function","invalid subscriptionKeyFn received"),this._pubsub=e,this._datastore=t,this._peerId=n,this._validator=r,this._handleSubscriptionKeyFn=i,this._onMessage=this._onMessage.bind(this)}put(e,t,n){if(!r.isBuffer(e)){const e="datastore key does not have a valid format";return h.error(e),n(l(new Error(e),"ERR_INVALID_DATASTORE_KEY"))}if(!r.isBuffer(t)){const e="received value is not a buffer";return h.error(e),n(l(new Error(e),"ERR_INVALID_VALUE_RECEIVED"))}const i=s(e);h(`publish value for topic ${i}`),this._pubsub.publish(i,t,n)}get(e,t){if(!r.isBuffer(e)){const e="datastore key does not have a valid format";return h.error(e),t(l(new Error(e),"ERR_INVALID_DATASTORE_KEY"))}const n=s(e);this._pubsub.ls((r,i)=>r?t(r):i&&Array.isArray(i)&&i.indexOf(n)>-1?this._getLocal(e,t):void this._pubsub.subscribe(n,this._onMessage,r=>{if(r){const e=`cannot subscribe topic ${n}`;return h.error(e),t(l(new Error(e),"ERR_SUBSCRIBING_TOPIC"))}h(`subscribed values for key ${n}`),this._getLocal(e,t)}))}unsubscribe(e){const t=s(e);this._pubsub.unsubscribe(t,this._onMessage)}_getLocal(e,t){const n=new i("/"+o(e),!1);this._datastore.get(n,(e,i)=>{if(e){if("ERR_NOT_FOUND"!==e.code){const e=`unexpected error getting the ipns record for ${n.toString()}`;return h.error(e),t(l(new Error(e),"ERR_UNEXPECTED_ERROR_GETTING_RECORD"))}const r=`local record requested was not found for ${n.toString()}`;return h.error(r),t(l(new Error(r),"ERR_NOT_FOUND"))}if(!r.isBuffer(i)){const e="found record that we couldn't convert to a value";return h.error(e),t(l(new Error(e),"ERR_INVALID_RECORD_RECEIVED"))}t(null,i)})}_onMessage(e){const{data:t,from:n,topicIDs:r}=e;let i;try{i=a(r[0])}catch(e){return void h.error(e)}h(`message received for ${i} topic`),n!==this._peerId.toB58String()?this._handleSubscriptionKeyFn?this._handleSubscriptionKeyFn(i,(e,n)=>{e?h.error("message discarded by the subscriptionKeyFn"):this._storeIfSubscriptionIsBetter(n,t)}):this._storeIfSubscriptionIsBetter(i,t):h("message discarded as it is from the same peer")}_storeIfSubscriptionIsBetter(e,t){this._isBetter(e,t,(n,i)=>{!n&&i&&this._storeRecord(r.from(e),t)})}_validateRecord(e,t,n){this._validator.validate(e,t,n)}_selectRecord(e,t,n){this._validator.select(e,t,(e,t)=>{if(e)return h.error(e),n(e);n(null,0===t)})}_isBetter(e,t,n){this._validateRecord(t,e,(r,o)=>{if(r||!o){const e="record received through pubsub is not valid";return h.error(e),n(l(new Error(e),"ERR_NOT_VALID_RECORD"))}const s=new i(e);this._getLocal(s.toBuffer(),(e,r)=>e?n(null,!0):r.equals(t)?n(null,!1):void this._selectRecord(t,r,n))})}_storeRecord(e,t){const n=new i("/"+o(e),!1);this._datastore.put(n,t,t=>{t?h.error(`record for ${e.toString()} could not be stored in the routing`):h(`record for ${e.toString()} was stored in the datastore`)})}open(e){const t="open function was not implemented yet";return h.error(t),e(l(new Error(t),"ERR_NOT_IMPLEMENTED_YET"))}has(e,t){const n="has function was not implemented yet";return h.error(n),t(l(new Error(n),"ERR_NOT_IMPLEMENTED_YET"))}delete(e,t){const n="delete function was not implemented yet";return h.error(n),t(l(new Error(n),"ERR_NOT_IMPLEMENTED_YET"))}close(e){const t="close function was not implemented yet";return h.error(t),e(l(new Error(t),"ERR_NOT_IMPLEMENTED_YET"))}batch(){const e="batch function was not implemented yet";throw h.error(e),l(new Error(e),"ERR_NOT_IMPLEMENTED_YET")}query(){const e="query function was not implemented yet";throw h.error(e),l(new Error(e),"ERR_NOT_IMPLEMENTED_YET")}}t=e.exports=f}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(60),i=n(13),o="/record/",s="u";e.exports.encodeBase32=(e=>r.encode("base32",e).slice(1)),e.exports.keyToTopic=(e=>{const t=r.encode("base64url",e).slice(1).toString();return`/record/${t}`}),e.exports.topicToKey=(e=>{if(e.substring(0,o.length)!==o)throw i(new Error("topic received is not from a record"),"ERR_TOPIC_IS_NOT_FROM_RECORD_NAMESPACE");const t=`u${e.substring(o.length)}`;return r.decode(t).toString()})},function(e,t,n){"use strict";(function(t){const r=n(57),i=n(24),o=r(n(917)).Record,s=n(918);class a{constructor(e,n,r){e&&i(t.isBuffer(e),"key must be a Buffer"),n&&i(t.isBuffer(n),"value must be a buffer"),this.key=e,this.value=n,this.timeReceived=r}serialize(){return o.encode(this.prepareSerialize())}prepareSerialize(){return{key:this.key,value:this.value,timeReceived:this.timeReceived&&s.toRFC3339(this.timeReceived)}}static deserialize(e){const t=o.decode(e);return a.fromDeserialized(t)}static fromDeserialized(e){let t;e.timeReceived&&(t=s.parseRFC3339(e.timeReceived));const n=new a(e.key,e.value,t);return n}}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports="// Record represents a dht record that contains a value\n// for a key value pair\nmessage Record {\n // The key that references this record\n bytes key = 1;\n\n // The actual value this record is storing\n bytes value = 2;\n\n // Note: These fields were removed from the Record message\n // hash of the authors public key\n // optional bytes author = 3;\n // A PKI signature for the key+value+author\n // optional bytes signature = 4;\n\n // Time the record was received, set by receiver\n optional string timeReceived = 5;\n}"},function(e,t,n){"use strict";e.exports.toRFC3339=(e=>{const t=e.getUTCFullYear(),n=String(e.getUTCMonth()+1).padStart(2,"0"),r=String(e.getUTCDate()).padStart(2,"0"),i=String(e.getUTCHours()).padStart(2,"0"),o=String(e.getUTCMinutes()).padStart(2,"0"),s=String(e.getUTCSeconds()).padStart(2,"0"),a=e.getUTCMilliseconds(),l=1e3*a*1e3;return`${t}-${n}-${r}T${i}:${o}:${s}.${l}Z`}),e.exports.parseRFC3339=(e=>{const t=new RegExp("(\\d{4})-(\\d{2})-(\\d{2})T(\\d{2}):(\\d{2}):(\\d{2})\\.(\\d+)Z"),n=String(e).trim().match(t);if(!n)throw new Error("Invalid format");const r=parseInt(n[1],10),i=parseInt(n[2],10)-1,o=parseInt(n[3],10),s=parseInt(n[4],10),a=parseInt(n[5],10),l=parseInt(n[6],10),u=parseInt(n[7].slice(0,-6),10);return new Date(Date.UTC(r,i,o,s,a,l,u))})},function(e,t,n){"use strict";(function(t){const r=n(436),i=n(13),o=(e,n,o)=>{const s=n.key,a=r(s,t.from("/"));if(a.length<3)return o();const l=e[a[1].toString()];if(!l){const e="Invalid record keytype";return o(i(new Error(e),"ERR_INVALID_RECORD_KEY_TYPE"))}l.func(s,n.value,o)};e.exports={verifyRecord:o,validators:n(921)}}).call(this,n(0).Buffer)},function(e,t){e.exports=function e(t,n,r){r=r||0;for(var i=0,o=-1,s=r;s<t.length;++s)if(t[s]==n[i]){if(-1==o&&(o=s),++i,i==n.length)break}else o=-1,i=0;return o>-1&&t.length-o<n.length?-1:o}},function(e,t,n){"use strict";e.exports={pk:n(922)}},function(e,t,n){"use strict";(function(t){const r=n(20),i=n(923),o=(e,n,o)=>{const s=e=>r(()=>o(e));if(!t.isBuffer(e))return s(new Error('"key" must be a Buffer'));if(e.length<3)return s(new Error("invalid public key record"));const a=e.slice(0,4).toString();if("/pk/"!==a)return s(new Error("key was not prefixed with /pk/"));const l=e.slice(4);i(n,"sha2-256",(e,t)=>e?s(e):l.equals(t)?void s():s(new Error("public key does not match passed in key")))};e.exports={func:o,sign:!1}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(27),i=n(924);function o(e,t,n,i){if("function"==typeof n&&(i=n,n=void 0),!i)throw new Error("Missing callback");o.digest(e,t,n,(e,o)=>{if(e)return i(e);i(null,r.encode(o,t,n))})}e.exports=o,o.Buffer=t,o.multihash=r,o.digest=function(e,t,n,r){if("function"==typeof n&&(r=n,n=void 0),!r)throw new Error("Missing callback");let i=r,s;n&&(i=((e,t)=>{if(e)return r(e);r(null,t.slice(0,n))}));try{s=o.createHash(t)}catch(e){return i(e)}s(e,i)},o.createHash=function(e){if(e=r.coerceCode(e),!o.functions[e])throw new Error("multihash function "+e+" not yet supported");return o.functions[e]},o.functions={17:i.sha1,18:i.sha2256,19:i.sha2512,20:i.sha3512,21:i.sha3384,22:i.sha3256,23:i.sha3224,24:i.shake128,25:i.shake256,26:i.keccak224,27:i.keccak256,28:i.keccak384,29:i.keccak512,34:i.murmur3128,35:i.murmur332,86:i.dblSha2256},i.addBlake(o.functions),o.validate=((e,n,i)=>{let s=r.decode(n).name;o(e,s,(e,r)=>{if(e)return i(e);i(e,0===t.compare(n,r))})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(357),i=n(359),o=n(437),s=n(925),a=o.toCallback,l=o.toBuf,u=o.fromString,c=o.fromNumberTo32BitBuf,h=(e,n)=>{s.sha2256(e,(e,r)=>{e&&n(e),s.sha2256(t.from(r),n)})};e.exports={sha1:s.sha1,sha2256:s.sha2256,sha2512:s.sha2512,sha3512:a(l(r.sha3_512)),sha3384:a(l(r.sha3_384)),sha3256:a(l(r.sha3_256)),sha3224:a(l(r.sha3_224)),shake128:a(l(r.shake_128,128)),shake256:a(l(r.shake_256,256)),keccak224:a(l(r.keccak_224)),keccak256:a(l(r.keccak_256)),keccak384:a(l(r.keccak_384)),keccak512:a(l(r.keccak_512)),murmur3128:a(l(u(i.x64.hash128))),murmur332:a(c(u(i.x86.hash32))),addBlake:n(926),dblSha2256:h}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(361),i=o();function o(){return self.crypto?self.crypto.subtle||self.crypto.webkitSubtle:self.msCrypto?self.msCrypto.subtle:void 0}function s(e){if(!i)throw new Error("Please use a browser with webcrypto support and ensure the code has been delivered securely via HTTPS/TLS and run within a Secure Context");return(n,o)=>{const s=i.digest({name:e},n);if("function"!=typeof s.then)return s.onerror=(()=>{o(new Error(`hashing data using ${e}`))}),void(s.oncomplete=(e=>{o(null,e.target.result)}));r(s.then(e=>t.from(new Uint8Array(e))),o)}}function a(e,t){s("SHA-1")(e,t)}function l(e,t){s("SHA-256")(e,t)}function u(e,t){s("SHA-512")(e,t)}e.exports={sha1:a,sha2256:l,sha2512:u}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(363),i=n(437).toCallback,o=45569,s=45633,a={init:r.blake2bInit,update:r.blake2bUpdate,digest:r.blake2bFinal},l={init:r.blake2sInit,update:r.blake2sUpdate,digest:r.blake2sFinal},u=(e,n)=>i(r=>{const i=n.init(e,null);return n.update(i,r),t.from(n.digest(i))});e.exports=(e=>{for(let t=0;t<64;t++)e[o+t]=u(t+1,a);for(let t=0;t<32;t++)e[s+t]=u(t+1,l)})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(436),i=n(13),o=(e,n,o)=>{if(0===o.length){const e="No records given";throw i(new Error(e),"ERR_NO_RECORDS_RECEIVED")}const s=r(n,t.from("/"));if(s.length<3){const e="Record key does not have a selector function";throw i(new Error(e),"ERR_NO_SELECTOR_FUNCTION_FOR_RECORD_KEY")}const a=e[s[1].toString()];if(!a){const e=`Unrecognized key prefix: ${s[1]}`;throw i(new Error(e),"ERR_UNRECOGNIZED_KEY_PREFIX")}return a(n,o)};e.exports={bestRecord:o,selectors:n(928)}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports={pk:n(929)}},function(e,t,n){"use strict";const r=(e,t)=>0;e.exports=r},function(e,t,n){"use strict";const r=n(440),i=n(941),o=n(976),s=n(985),a=n(991),l=n(999),u=n(1e3),c=n(1032),h=n(89),f=n(22);class p extends c{constructor(e){const t=new i({id:e.peerInfo.id}),n=e.peerInfo.multiaddrs.toArray().map(String).filter(e=>e.includes("p2p-websocket-star"));e.peerInfo.multiaddrs.replace(n.map(f),"/p2p-websocket-star");const c=new o({servers:n,id:e.peerInfo.id,ignore_no_online:!n.length||e.wsStarIgnoreErrors}),p={switch:{blacklistTTL:12e4,blackListAttempts:5,maxParallelDials:100,maxColdCalls:25,dialTimeout:2e4},modules:{transport:[r,t,c],streamMuxer:[s],connEncryption:[a],peerDiscovery:[t.discovery,c.discovery,l],dht:u},config:{peerDiscovery:{autoDial:!0,bootstrap:{enabled:!0},webRTCStar:{enabled:!0},websocketStar:{enabled:!0}},dht:{enabled:!1},EXPERIMENTAL:{pubsub:!1}}};super(h(p,e))}}e.exports=p},function(e,t,n){"use strict";var r=n(932),i=n(934),o=n(938);function s(e){return"function"==typeof e}e.exports=function(e,t){s(t)&&(t={onConnect:t});var n="undefined"==typeof window?{}:window.location,a=o(e,n),l=new r(a),u=i(l,t);return u.remoteAddress=a,u.close=function(e){s(e)&&l.addEventListener("close",e),l.close()},l.addEventListener("open",function(e){t&&s(t.onConnect)&&t.onConnect(null,u)}),u},e.exports.connect=e.exports},function(e,t,n){e.exports="undefined"==typeof WebSocket?n(933):WebSocket},function(e,t){},function(e,t,n){var r=n(935),i=n(936);function o(e,t){var n=e.upgradeReq||{};return t&&t.binaryType?e.binaryType=t.binaryType:t&&t.binary&&(e.binaryType="arraybuffer"),{source:r(e,t&&t.onConnect),sink:i(e,t),headers:n.headers,url:n.url,upgrade:n.upgrade,method:n.method}}e.exports=o},function(e,t,n){var r=n(5).Buffer;function i(e){return e instanceof ArrayBuffer||null!=e&&null!=e.constructor&&"ArrayBuffer"===e.constructor.name&&"number"==typeof e.byteLength}e.exports=function(e,t){var n=[],o,s,a=!1;function l(t,r){if(o=null,s)return r(s);t?(o=r,e.close()):n.length>0?r(null,n.shift()):o=r}return e.addEventListener("message",function(e){var t=e.data;if(i(t)&&(t=r.from(t)),o)return o(null,t);n.push(t)}),e.addEventListener("close",function(e){s||o&&o(s=!0)}),e.addEventListener("error",function(e){s||(s=e,a||(a=!0,t&&t(e)),o&&o(s))}),e.addEventListener("open",function(e){a||s||(a=!0)}),l}},function(e,t,n){(function(t){var r=n(937),i="undefined"!=typeof setImmediate?setImmediate:t.nextTick;e.exports=function(e,t){return function(n){t=t||{};var o=!1!==t.closeOnEnd,s="function"==typeof t?t:t.onClose;function a(t,l){t?o&&e.readyState<=1&&(s&&e.addEventListener("close",function(e){if(e.wasClean||1006===e.code)s();else{var t=new Error("ws error");t.event=e,s(t)}}),e.close()):r(e,function(t){if(t)return n(t,function(){});e.send(l),i(function(){n(null,a)})})}n(null,a)}}}).call(this,n(3))},function(e,t){e.exports=function(e,t){var n=e&&(e.removeEventListener||e.removeListener);function r(){"function"==typeof n&&(n.call(e,"open",i),n.call(e,"error",o))}function i(e){r(),t()}function o(e){r(),t(e)}return e.readyState>=2?t(!0):1===e.readyState?t():(e.addEventListener("open",i),void e.addEventListener("error",o))}},function(e,t,n){var{relative:r}=n(191),i={http:"ws",https:"wss"},o="ws";e.exports=function(e,t){return r(e,t,i,o)}},function(e,t,n){"use strict";const r=n(349);e.exports=class e{constructor(e,t){this.peerInfo=null,this.conn=r(),e?this.setInnerConn(e,t):t&&(this.info=t)}get source(){return this.conn.source}get sink(){return this.conn.sink}getPeerInfo(e){return this.info&&this.info.getPeerInfo?this.info.getPeerInfo(e):this.peerInfo?void e(null,this.peerInfo):e(new Error("Peer Info not set yet"))}setPeerInfo(e){if(this.info&&this.info.setPeerInfo)return this.info.setPeerInfo(e);this.peerInfo=e}getObservedAddrs(e){if(this.info&&this.info.getObservedAddrs)return this.info.getObservedAddrs(e);e(null,[])}setInnerConn(e,t){this.conn.resolve(e),this.info=t||e}}},function(e,t,n){"use strict";e.exports=function(){throw new Error("WebSocket Servers can not be created in the browser!")}},function(e,t,n){"use strict";const r=n(4),i=r("libp2p:webrtc-star"),o=n(22),s=n(72),a=n(39),l=n(442),u=n(6).EventEmitter,c=n(967),h=n(15),f=n(31),p=n(64).Connection,d=n(69),m=n(26),g=n(20),y=n(974),v=n(975),b=v.cleanUrlSIO,_=v.cleanMultiaddr,w=m(()=>{}),k={transports:["websocket"],"force new connection":!0};class E{constructor(e){e=e||{},this.maSelf=void 0,this.sioOptions={transports:["websocket"],"force new connection":!0},e.wrtc&&(this.wrtc=e.wrtc),this.discovery=new u,this.discovery.tag="webRTCStar",this.discovery.start=(e=>{g(e)}),this.discovery.stop=(e=>{g(e)}),this.listenersRefs={},this._peerDiscovered=this._peerDiscovered.bind(this)}dial(e,t,n){"function"==typeof t&&(n=t,t={}),n=n?m(n):w;const r=(~~(1e9*Math.random())).toString(36)+Date.now(),o=this.listenersRefs[Object.keys(this.listenersRefs)[0]].io,s={initiator:!0,trickle:!1};let a;this.wrtc&&(s.wrtc=this.wrtc);try{a=new c(s)}catch(e){return i("Could not create connection:",e),n(e)}const l=new p(d.duplex(a));let u=!1;return a.on("signal",t=>{o.emit("ss-handshake",{intentId:r,srcMultiaddr:this.maSelf.toString(),dstMultiaddr:e.toString(),signal:t})}),a.once("timeout",()=>n(new Error("timeout"))),a.once("error",e=>{u||n(e)}),o.on("ws-handshake",t=>{if(t.intentId===r&&t.err)return n(new Error(t.err));t.intentId===r&&t.answer&&(a.once("connect",()=>{u=!0,l.destroy=a.destroy.bind(a),a.once("close",()=>l.destroy()),l.getObservedAddrs=(t=>t(null,[e])),n(null,l)}),a.signal(t.signal))}),l}createListener(e,t){"function"==typeof e&&(t=e,e={});const n=new u;return n.listen=((e,r)=>{if(r=r?m(r):w,!y.support&&!this.wrtc)return g(()=>r(new Error("no WebRTC support")));this.maSelf=e;const o=b(e);i("Dialing to Signalling Server on: "+o),n.io=l.connect(o,k),n.io.once("connect_error",r),n.io.once("error",e=>{n.emit("error",e),n.emit("close")}),n.io.on("ws-handshake",a),n.io.on("ws-peer",this._peerDiscovered),n.io.on("connect",()=>{n.io.emit("ss-join",e.toString())}),n.io.once("connect",()=>{n.emit("listening"),r()});const s=this;function a(e){if(e.answer||e.err)return;const o={trickle:!1};let a;s.wrtc&&(o.wrtc=s.wrtc);try{a=new c(o)}catch(e){return i("Could not create incoming connection:",e),r(e)}const l=new p(d.duplex(a));a.once("connect",()=>{l.getObservedAddrs=(t=>t(null,[e.srcMultiaddr])),n.emit("connection",l),t(l)}),a.once("signal",t=>{e.signal=t,e.answer=!0,n.io.emit("ss-handshake",e)}),a.signal(e.signal)}}),n.close=(e=>{e=e?m(e):w,n.io.emit("ss-leave"),g(()=>{n.emit("close"),e()})}),n.getAddrs=(e=>{g(()=>e(null,[this.maSelf]))}),this.listenersRefs[o.toString()]=n,n}filter(e){return Array.isArray(e)||(e=[e]),e.filter(e=>!(e.protoNames().indexOf("p2p-circuit")>-1)&&s.WebRTCStar.matches(e))}_peerDiscovered(e){i("Peer Discovered:",e),e=_(e);const t=e.split("/ipfs/"),n=t[t.length-1],r=h.createFromB58String(n),s=new f(r);s.multiaddrs.add(o(e)),this.discovery.emit("peer",s)}}e.exports=a(E,{className:"WebRTCStar",symbolName:"@libp2p/js-libp2p-webrtc-star/webrtcstar"})},function(e,t,n){var r=n(443),i=n(208)("socket.io-client:url");function o(e,t){var n=e;t=t||"undefined"!=typeof location&&location,null==e&&(e=t.protocol+"//"+t.host),"string"==typeof e&&("/"===e.charAt(0)&&(e="/"===e.charAt(1)?t.protocol+e:t.host+e),/^(https?|wss?):\/\//.test(e)||(i("protocol-less url %s",e),e=void 0!==t?t.protocol+"//"+e:"https://"+e),i("parse %s",e),n=r(e)),n.port||(/^(http|ws)$/.test(n.protocol)?n.port="80":/^(http|ws)s$/.test(n.protocol)&&(n.port="443")),n.path=n.path||"/";var o=-1!==n.host.indexOf(":"),s=o?"["+n.host+"]":n.host;return n.id=n.protocol+"://"+s+":"+n.port,n.href=n.protocol+"://"+s+(t&&t.port===n.port?"":":"+n.port),n}e.exports=o},function(e,t,n){function r(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=i.log||t.log||console.log.bind(console);u.apply(e,s)}}return i.namespace=e,i.enabled=t.enabled(e),i.useColors=t.useColors(),i.color=r(e),i.destroy=o,"function"==typeof t.init&&t.init(i),t.instances.push(i),i}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}function s(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),i=r.length;for(n=0;n<i;n++)r[n]&&(e=r[n].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var o=t.instances[n];o.enabled=t.enabled(o.namespace)}}function a(){t.enable("")}function l(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=i.debug=i.default=i,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(944),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(946),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t,n){function r(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=i.log||t.log||console.log.bind(console);u.apply(e,s)}}return i.namespace=e,i.enabled=t.enabled(e),i.useColors=t.useColors(),i.color=r(e),i.destroy=o,"function"==typeof t.init&&t.init(i),t.instances.push(i),i}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}function s(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),i=r.length;for(n=0;n<i;n++)r[n]&&(e=r[n].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var o=t.instances[n];o.enabled=t.enabled(o.namespace)}}function a(){t.enable("")}function l(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=i.debug=i.default=i,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(947),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){var r=n(444),i=n(445),o=Object.prototype.toString,s="function"==typeof Blob||"undefined"!=typeof Blob&&"[object BlobConstructor]"===o.call(Blob),a="function"==typeof File||"undefined"!=typeof File&&"[object FileConstructor]"===o.call(File);function l(e,t){if(!e)return e;if(i(e)){var n={_placeholder:!0,num:t.length};return t.push(e),n}if(r(e)){for(var o=new Array(e.length),s=0;s<e.length;s++)o[s]=l(e[s],t);return o}if("object"==typeof e&&!(e instanceof Date)){var o={};for(var a in e)o[a]=l(e[a],t);return o}return e}function u(e,t){if(!e)return e;if(e&&e._placeholder)return t[e.num];if(r(e))for(var n=0;n<e.length;n++)e[n]=u(e[n],t);else if("object"==typeof e)for(var i in e)e[i]=u(e[i],t);return e}t.deconstructPacket=function(e){var t=[],n=e.data,r=e;return r.data=l(n,t),r.attachments=t.length,{packet:r,buffers:t}},t.reconstructPacket=function(e,t){return e.data=u(e.data,t),e.attachments=void 0,e},t.removeBlobs=function(e,t){function n(e,u,c){if(!e)return e;if(s&&e instanceof Blob||a&&e instanceof File){o++;var h=new FileReader;h.onload=function(){c?c[u]=this.result:l=this.result,--o||t(l)},h.readAsArrayBuffer(e)}else if(r(e))for(var f=0;f<e.length;f++)n(e[f],f,e);else if("object"==typeof e&&!i(e))for(var p in e)n(e[p],p,e)}var o=0,l=e;n(l),o||t(l)}},function(e,t,n){e.exports=n(950),e.exports.parser=n(125)},function(e,t,n){var r=n(447),i=n(124),o=n(211)("engine.io-client:socket"),s=n(451),a=n(125),l=n(443),u=n(209);function c(e,t){if(!(this instanceof c))return new c(e,t);t=t||{},e&&"object"==typeof e&&(t=e,e=null),e?(e=l(e),t.hostname=e.host,t.secure="https"===e.protocol||"wss"===e.protocol,t.port=e.port,e.query&&(t.query=e.query)):t.host&&(t.hostname=l(t.host).host),this.secure=null!=t.secure?t.secure:"undefined"!=typeof location&&"https:"===location.protocol,t.hostname&&!t.port&&(t.port=this.secure?"443":"80"),this.agent=t.agent||!1,this.hostname=t.hostname||("undefined"!=typeof location?location.hostname:"localhost"),this.port=t.port||("undefined"!=typeof location&&location.port?location.port:this.secure?443:80),this.query=t.query||{},"string"==typeof this.query&&(this.query=u.decode(this.query)),this.upgrade=!1!==t.upgrade,this.path=(t.path||"/engine.io").replace(/\/$/,"")+"/",this.forceJSONP=!!t.forceJSONP,this.jsonp=!1!==t.jsonp,this.forceBase64=!!t.forceBase64,this.enablesXDR=!!t.enablesXDR,this.timestampParam=t.timestampParam||"t",this.timestampRequests=t.timestampRequests,this.transports=t.transports||["polling","websocket"],this.transportOptions=t.transportOptions||{},this.readyState="",this.writeBuffer=[],this.prevBufferLen=0,this.policyPort=t.policyPort||843,this.rememberUpgrade=t.rememberUpgrade||!1,this.binaryType=null,this.onlyBinaryUpgrades=t.onlyBinaryUpgrades,this.perMessageDeflate=!1!==t.perMessageDeflate&&(t.perMessageDeflate||{}),!0===this.perMessageDeflate&&(this.perMessageDeflate={}),this.perMessageDeflate&&null==this.perMessageDeflate.threshold&&(this.perMessageDeflate.threshold=1024),this.pfx=t.pfx||null,this.key=t.key||null,this.passphrase=t.passphrase||null,this.cert=t.cert||null,this.ca=t.ca||null,this.ciphers=t.ciphers||null,this.rejectUnauthorized=void 0===t.rejectUnauthorized||t.rejectUnauthorized,this.forceNode=!!t.forceNode,this.isReactNative="undefined"!=typeof navigator&&"string"==typeof navigator.product&&"reactnative"===navigator.product.toLowerCase(),("undefined"==typeof self||this.isReactNative)&&(t.extraHeaders&&Object.keys(t.extraHeaders).length>0&&(this.extraHeaders=t.extraHeaders),t.localAddress&&(this.localAddress=t.localAddress)),this.id=null,this.upgrades=null,this.pingInterval=null,this.pingTimeout=null,this.pingIntervalTimer=null,this.pingTimeoutTimer=null,this.open()}function h(e){var t={};for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}e.exports=c,c.priorWebsocketSuccess=!1,i(c.prototype),c.protocol=a.protocol,c.Socket=c,c.Transport=n(268),c.transports=n(447),c.parser=n(125),c.prototype.createTransport=function(e){o('creating transport "%s"',e);var t=h(this.query);t.EIO=a.protocol,t.transport=e;var n=this.transportOptions[e]||{};this.id&&(t.sid=this.id);var i=new r[e]({query:t,socket:this,agent:n.agent||this.agent,hostname:n.hostname||this.hostname,port:n.port||this.port,secure:n.secure||this.secure,path:n.path||this.path,forceJSONP:n.forceJSONP||this.forceJSONP,jsonp:n.jsonp||this.jsonp,forceBase64:n.forceBase64||this.forceBase64,enablesXDR:n.enablesXDR||this.enablesXDR,timestampRequests:n.timestampRequests||this.timestampRequests,timestampParam:n.timestampParam||this.timestampParam,policyPort:n.policyPort||this.policyPort,pfx:n.pfx||this.pfx,key:n.key||this.key,passphrase:n.passphrase||this.passphrase,cert:n.cert||this.cert,ca:n.ca||this.ca,ciphers:n.ciphers||this.ciphers,rejectUnauthorized:n.rejectUnauthorized||this.rejectUnauthorized,perMessageDeflate:n.perMessageDeflate||this.perMessageDeflate,extraHeaders:n.extraHeaders||this.extraHeaders,forceNode:n.forceNode||this.forceNode,localAddress:n.localAddress||this.localAddress,requestTimeout:n.requestTimeout||this.requestTimeout,protocols:n.protocols||void 0,isReactNative:this.isReactNative});return i},c.prototype.open=function(){var e;if(this.rememberUpgrade&&c.priorWebsocketSuccess&&-1!==this.transports.indexOf("websocket"))e="websocket";else{if(0===this.transports.length){var t=this;return void setTimeout(function(){t.emit("error","No transports available")},0)}e=this.transports[0]}this.readyState="opening";try{e=this.createTransport(e)}catch(e){return this.transports.shift(),void this.open()}e.open(),this.setTransport(e)},c.prototype.setTransport=function(e){o("setting transport %s",e.name);var t=this;this.transport&&(o("clearing existing transport %s",this.transport.name),this.transport.removeAllListeners()),this.transport=e,e.on("drain",function(){t.onDrain()}).on("packet",function(e){t.onPacket(e)}).on("error",function(e){t.onError(e)}).on("close",function(){t.onClose("transport close")})},c.prototype.probe=function(e){o('probing transport "%s"',e);var t=this.createTransport(e,{probe:1}),n=!1,r=this;function i(){if(r.onlyBinaryUpgrades){var i=!this.supportsBinary&&r.transport.supportsBinary;n=n||i}n||(o('probe transport "%s" opened',e),t.send([{type:"ping",data:"probe"}]),t.once("packet",function(i){if(!n)if("pong"===i.type&&"probe"===i.data){if(o('probe transport "%s" pong',e),r.upgrading=!0,r.emit("upgrading",t),!t)return;c.priorWebsocketSuccess="websocket"===t.name,o('pausing current transport "%s"',r.transport.name),r.transport.pause(function(){n||"closed"!==r.readyState&&(o("changing transport and sending upgrade packet"),f(),r.setTransport(t),t.send([{type:"upgrade"}]),r.emit("upgrade",t),t=null,r.upgrading=!1,r.flush())})}else{o('probe transport "%s" failed',e);var s=new Error("probe error");s.transport=t.name,r.emit("upgradeError",s)}}))}function s(){n||(n=!0,f(),t.close(),t=null)}function a(n){var i=new Error("probe error: "+n);i.transport=t.name,s(),o('probe transport "%s" failed because of error: %s',e,n),r.emit("upgradeError",i)}function l(){a("transport closed")}function u(){a("socket closed")}function h(e){t&&e.name!==t.name&&(o('"%s" works - aborting "%s"',e.name,t.name),s())}function f(){t.removeListener("open",i),t.removeListener("error",a),t.removeListener("close",l),r.removeListener("close",u),r.removeListener("upgrading",h)}c.priorWebsocketSuccess=!1,t.once("open",i),t.once("error",a),t.once("close",l),this.once("close",u),this.once("upgrading",h),t.open()},c.prototype.onOpen=function(){if(o("socket open"),this.readyState="open",c.priorWebsocketSuccess="websocket"===this.transport.name,this.emit("open"),this.flush(),"open"===this.readyState&&this.upgrade&&this.transport.pause){o("starting upgrade probes");for(var e=0,t=this.upgrades.length;e<t;e++)this.probe(this.upgrades[e])}},c.prototype.onPacket=function(e){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState)switch(o('socket receive: type "%s", data "%s"',e.type,e.data),this.emit("packet",e),this.emit("heartbeat"),e.type){case"open":this.onHandshake(JSON.parse(e.data));break;case"pong":this.setPing(),this.emit("pong");break;case"error":var t=new Error("server error");t.code=e.data,this.onError(t);break;case"message":this.emit("data",e.data),this.emit("message",e.data)}else o('packet received with socket readyState "%s"',this.readyState)},c.prototype.onHandshake=function(e){this.emit("handshake",e),this.id=e.sid,this.transport.query.sid=e.sid,this.upgrades=this.filterUpgrades(e.upgrades),this.pingInterval=e.pingInterval,this.pingTimeout=e.pingTimeout,this.onOpen(),"closed"!==this.readyState&&(this.setPing(),this.removeListener("heartbeat",this.onHeartbeat),this.on("heartbeat",this.onHeartbeat))},c.prototype.onHeartbeat=function(e){clearTimeout(this.pingTimeoutTimer);var t=this;t.pingTimeoutTimer=setTimeout(function(){"closed"!==t.readyState&&t.onClose("ping timeout")},e||t.pingInterval+t.pingTimeout)},c.prototype.setPing=function(){var e=this;clearTimeout(e.pingIntervalTimer),e.pingIntervalTimer=setTimeout(function(){o("writing ping packet - expecting pong within %sms",e.pingTimeout),e.ping(),e.onHeartbeat(e.pingTimeout)},e.pingInterval)},c.prototype.ping=function(){var e=this;this.sendPacket("ping",function(){e.emit("ping")})},c.prototype.onDrain=function(){this.writeBuffer.splice(0,this.prevBufferLen),this.prevBufferLen=0,0===this.writeBuffer.length?this.emit("drain"):this.flush()},c.prototype.flush=function(){"closed"!==this.readyState&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length&&(o("flushing %d packets in socket",this.writeBuffer.length),this.transport.send(this.writeBuffer),this.prevBufferLen=this.writeBuffer.length,this.emit("flush"))},c.prototype.write=c.prototype.send=function(e,t,n){return this.sendPacket("message",e,t,n),this},c.prototype.sendPacket=function(e,t,n,r){if("function"==typeof t&&(r=t,t=void 0),"function"==typeof n&&(r=n,n=null),"closing"!==this.readyState&&"closed"!==this.readyState){n=n||{},n.compress=!1!==n.compress;var i={type:e,data:t,options:n};this.emit("packetCreate",i),this.writeBuffer.push(i),r&&this.once("flush",r),this.flush()}},c.prototype.close=function(){if("opening"===this.readyState||"open"===this.readyState){this.readyState="closing";var e=this;this.writeBuffer.length?this.once("drain",function(){this.upgrading?r():t()}):this.upgrading?r():t()}function t(){e.onClose("forced close"),o("socket closing - telling transport to close"),e.transport.close()}function n(){e.removeListener("upgrade",n),e.removeListener("upgradeError",n),t()}function r(){e.once("upgrade",n),e.once("upgradeError",n)}return this},c.prototype.onError=function(e){o("socket error %j",e),c.priorWebsocketSuccess=!1,this.emit("error",e),this.onClose("transport error",e)},c.prototype.onClose=function(e,t){if("opening"===this.readyState||"open"===this.readyState||"closing"===this.readyState){o('socket close with reason: "%s"',e);var n=this;clearTimeout(this.pingIntervalTimer),clearTimeout(this.pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),this.readyState="closed",this.id=null,this.emit("close",e,t),this.writeBuffer=[],this.prevBufferLen=0}},c.prototype.filterUpgrades=function(e){for(var t=[],n=0,r=e.length;n<r;n++)~s(this.transports,e[n])&&t.push(e[n]);return t}},function(e,t){try{e.exports="undefined"!=typeof XMLHttpRequest&&"withCredentials"in new XMLHttpRequest}catch(t){e.exports=!1}},function(e,t,n){var r=n(267),i=n(448),o=n(124),s=n(210),a=n(211)("engine.io-client:polling-xhr");function l(){}function u(e){if(i.call(this,e),this.requestTimeout=e.requestTimeout,this.extraHeaders=e.extraHeaders,"undefined"!=typeof location){var t="https:"===location.protocol,n=location.port;n||(n=t?443:80),this.xd="undefined"!=typeof location&&e.hostname!==location.hostname||n!==e.port,this.xs=e.secure!==t}}function c(e){this.method=e.method||"GET",this.uri=e.uri,this.xd=!!e.xd,this.xs=!!e.xs,this.async=!1!==e.async,this.data=void 0!==e.data?e.data:null,this.agent=e.agent,this.isBinary=e.isBinary,this.supportsBinary=e.supportsBinary,this.enablesXDR=e.enablesXDR,this.requestTimeout=e.requestTimeout,this.pfx=e.pfx,this.key=e.key,this.passphrase=e.passphrase,this.cert=e.cert,this.ca=e.ca,this.ciphers=e.ciphers,this.rejectUnauthorized=e.rejectUnauthorized,this.extraHeaders=e.extraHeaders,this.create()}if(e.exports=u,e.exports.Request=c,s(u,i),u.prototype.supportsBinary=!0,u.prototype.request=function(e){return e=e||{},e.uri=this.uri(),e.xd=this.xd,e.xs=this.xs,e.agent=this.agent||!1,e.supportsBinary=this.supportsBinary,e.enablesXDR=this.enablesXDR,e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized,e.requestTimeout=this.requestTimeout,e.extraHeaders=this.extraHeaders,new c(e)},u.prototype.doWrite=function(e,t){var n="string"!=typeof e&&void 0!==e,r=this.request({method:"POST",data:e,isBinary:n}),i=this;r.on("success",t),r.on("error",function(e){i.onError("xhr post error",e)}),this.sendXhr=r},u.prototype.doPoll=function(){a("xhr poll");var e=this.request(),t=this;e.on("data",function(e){t.onData(e)}),e.on("error",function(e){t.onError("xhr poll error",e)}),this.pollXhr=e},o(c.prototype),c.prototype.create=function(){var e={agent:this.agent,xdomain:this.xd,xscheme:this.xs,enablesXDR:this.enablesXDR};e.pfx=this.pfx,e.key=this.key,e.passphrase=this.passphrase,e.cert=this.cert,e.ca=this.ca,e.ciphers=this.ciphers,e.rejectUnauthorized=this.rejectUnauthorized;var t=this.xhr=new r(e),n=this;try{a("xhr open %s: %s",this.method,this.uri),t.open(this.method,this.uri,this.async);try{if(this.extraHeaders)for(var i in t.setDisableHeaderCheck&&t.setDisableHeaderCheck(!0),this.extraHeaders)this.extraHeaders.hasOwnProperty(i)&&t.setRequestHeader(i,this.extraHeaders[i])}catch(e){}if("POST"===this.method)try{this.isBinary?t.setRequestHeader("Content-type","application/octet-stream"):t.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch(e){}try{t.setRequestHeader("Accept","*/*")}catch(e){}"withCredentials"in t&&(t.withCredentials=!0),this.requestTimeout&&(t.timeout=this.requestTimeout),this.hasXDR()?(t.onload=function(){n.onLoad()},t.onerror=function(){n.onError(t.responseText)}):t.onreadystatechange=function(){if(2===t.readyState)try{var e=t.getResponseHeader("Content-Type");n.supportsBinary&&"application/octet-stream"===e&&(t.responseType="arraybuffer")}catch(e){}4===t.readyState&&(200===t.status||1223===t.status?n.onLoad():setTimeout(function(){n.onError(t.status)},0))},a("xhr data %s",this.data),t.send(this.data)}catch(e){return void setTimeout(function(){n.onError(e)},0)}"undefined"!=typeof document&&(this.index=c.requestsCount++,c.requests[this.index]=this)},c.prototype.onSuccess=function(){this.emit("success"),this.cleanup()},c.prototype.onData=function(e){this.emit("data",e),this.onSuccess()},c.prototype.onError=function(e){this.emit("error",e),this.cleanup(!0)},c.prototype.cleanup=function(e){if(void 0!==this.xhr&&null!==this.xhr){if(this.hasXDR()?this.xhr.onload=this.xhr.onerror=l:this.xhr.onreadystatechange=l,e)try{this.xhr.abort()}catch(e){}"undefined"!=typeof document&&delete c.requests[this.index],this.xhr=null}},c.prototype.onLoad=function(){var e;try{var t;try{t=this.xhr.getResponseHeader("Content-Type")}catch(e){}e="application/octet-stream"===t&&this.xhr.response||this.xhr.responseText}catch(e){this.onError(e)}null!=e&&this.onData(e)},c.prototype.hasXDR=function(){return"undefined"!=typeof XDomainRequest&&!this.xs&&this.enablesXDR},c.prototype.abort=function(){this.cleanup()},c.requestsCount=0,c.requests={},"undefined"!=typeof document)if("function"==typeof attachEvent)attachEvent("onunload",f);else if("function"==typeof addEventListener){var h="onpagehide"in self?"pagehide":"unload";addEventListener(h,f,!1)}function f(){for(var e in c.requests)c.requests.hasOwnProperty(e)&&c.requests[e].abort()}},function(e,t){e.exports=Object.keys||function e(t){var n=[],r=Object.prototype.hasOwnProperty;for(var i in t)r.call(t,i)&&n.push(i);return n}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t){e.exports=function(e,t,n){var r=e.byteLength;if(t=t||0,n=n||r,e.slice)return e.slice(t,n);if(t<0&&(t+=r),n<0&&(n+=r),n>r&&(n=r),t>=r||t>=n||0===r)return new ArrayBuffer(0);for(var i=new Uint8Array(e),o=new Uint8Array(n-t),s=t,a=0;s<n;s++,a++)o[a]=i[s];return o.buffer}},function(e,t){function n(e,t,n){var i=!1;return n=n||r,o.count=e,0===e?t():o;function o(e,r){if(o.count<=0)throw new Error("after called too many times");--o.count,e?(i=!0,t(e),t=n):0!==o.count||i||t(null,r)}}function r(){}e.exports=n},function(e,t){
/*! https://mths.be/utf8js v2.1.2 by @mathias */
var n=String.fromCharCode,r,i,o;function s(e){for(var t=[],n=0,r=e.length,i,o;n<r;)i=e.charCodeAt(n++),i>=55296&&i<=56319&&n<r?(o=e.charCodeAt(n++),56320==(64512&o)?t.push(((1023&i)<<10)+(1023&o)+65536):(t.push(i),n--)):t.push(i);return t}function a(e){for(var t=e.length,r=-1,i,o="";++r<t;)i=e[r],i>65535&&(i-=65536,o+=n(i>>>10&1023|55296),i=56320|1023&i),o+=n(i);return o}function l(e,t){if(e>=55296&&e<=57343){if(t)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value");return!1}return!0}function u(e,t){return n(e>>t&63|128)}function c(e,t){if(0==(4294967168&e))return n(e);var r="";return 0==(4294965248&e)?r=n(e>>6&31|192):0==(4294901760&e)?(l(e,t)||(e=65533),r=n(e>>12&15|224),r+=u(e,6)):0==(4292870144&e)&&(r=n(e>>18&7|240),r+=u(e,12),r+=u(e,6)),r+=n(63&e|128),r}function h(e,t){t=t||{};for(var n=!1!==t.strict,r=s(e),i=r.length,o=-1,a,l="";++o<i;)a=r[o],l+=c(a,n);return l}function f(){if(o>=i)throw Error("Invalid byte index");var e=255&r[o];if(o++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function p(e){var t,n,s,a,u;if(o>i)throw Error("Invalid byte index");if(o==i)return!1;if(t=255&r[o],o++,0==(128&t))return t;if(192==(224&t)){if(n=f(),u=(31&t)<<6|n,u>=128)return u;throw Error("Invalid continuation byte")}if(224==(240&t)){if(n=f(),s=f(),u=(15&t)<<12|n<<6|s,u>=2048)return l(u,e)?u:65533;throw Error("Invalid continuation byte")}if(240==(248&t)&&(n=f(),s=f(),a=f(),u=(7&t)<<18|n<<12|s<<6|a,u>=65536&&u<=1114111))return u;throw Error("Invalid UTF-8 detected")}function d(e,t){t=t||{};var n=!1!==t.strict;r=s(e),i=r.length,o=0;for(var l=[],u;!1!==(u=p(n));)l.push(u);return a(l)}e.exports={version:"2.1.2",encode:h,decode:d}},function(e,t){!function(){"use strict";for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=new Uint8Array(256),r=0;r<e.length;r++)n[e.charCodeAt(r)]=r;t.encode=function(t){var n=new Uint8Array(t),r,i=n.length,o="";for(r=0;r<i;r+=3)o+=e[n[r]>>2],o+=e[(3&n[r])<<4|n[r+1]>>4],o+=e[(15&n[r+1])<<2|n[r+2]>>6],o+=e[63&n[r+2]];return i%3==2?o=o.substring(0,o.length-1)+"=":i%3==1&&(o=o.substring(0,o.length-2)+"=="),o},t.decode=function(e){var t=.75*e.length,r=e.length,i,o=0,s,a,l,u;"="===e[e.length-1]&&(t--,"="===e[e.length-2]&&t--);var c=new ArrayBuffer(t),h=new Uint8Array(c);for(i=0;i<r;i+=4)s=n[e.charCodeAt(i)],a=n[e.charCodeAt(i+1)],l=n[e.charCodeAt(i+2)],u=n[e.charCodeAt(i+3)],h[o++]=s<<2|a>>4,h[o++]=(15&a)<<4|l>>2,h[o++]=(3&l)<<6|63&u;return c}}()},function(e,t){var n=void 0!==n?n:"undefined"!=typeof WebKitBlobBuilder?WebKitBlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder&&MozBlobBuilder,r=function(){try{var e=new Blob(["hi"]);return 2===e.size}catch(e){return!1}}(),i=r&&function(){try{var e=new Blob([new Uint8Array([1,2])]);return 2===e.size}catch(e){return!1}}(),o=n&&n.prototype.append&&n.prototype.getBlob;function s(e){return e.map(function(e){if(e.buffer instanceof ArrayBuffer){var t=e.buffer;if(e.byteLength!==t.byteLength){var n=new Uint8Array(e.byteLength);n.set(new Uint8Array(t,e.byteOffset,e.byteLength)),t=n.buffer}return t}return e})}function a(e,t){t=t||{};var r=new n;return s(e).forEach(function(e){r.append(e)}),t.type?r.getBlob(t.type):r.getBlob()}function l(e,t){return new Blob(s(e),t||{})}"undefined"!=typeof Blob&&(a.prototype=Blob.prototype,l.prototype=Blob.prototype),e.exports=r?i?Blob:l:o?a:void 0},function(e,t,n){function r(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=i.log||t.log||console.log.bind(console);u.apply(e,s)}}return i.namespace=e,i.enabled=t.enabled(e),i.useColors=t.useColors(),i.color=r(e),i.destroy=o,"function"==typeof t.init&&t.init(i),t.instances.push(i),i}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}function s(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),i=r.length;for(n=0;n<i;n++)r[n]&&(e=r[n].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var o=t.instances[n];o.enabled=t.enabled(o.namespace)}}function a(){t.enable("")}function l(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=i.debug=i.default=i,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(961),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var r=n(448),i=n(210);e.exports=c;var o=/\n/g,s=/\\n/g,a;function l(){}function u(){return"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==t?t:{}}function c(e){if(r.call(this,e),this.query=this.query||{},!a){var t=u();a=t.___eio=t.___eio||[]}this.index=a.length;var n=this;a.push(function(e){n.onData(e)}),this.query.j=this.index,"function"==typeof addEventListener&&addEventListener("beforeunload",function(){n.script&&(n.script.onerror=l)},!1)}i(c,r),c.prototype.supportsBinary=!1,c.prototype.doClose=function(){this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),this.form&&(this.form.parentNode.removeChild(this.form),this.form=null,this.iframe=null),r.prototype.doClose.call(this)},c.prototype.doPoll=function(){var e=this,t=document.createElement("script");this.script&&(this.script.parentNode.removeChild(this.script),this.script=null),t.async=!0,t.src=this.uri(),t.onerror=function(t){e.onError("jsonp poll error",t)};var n=document.getElementsByTagName("script")[0];n?n.parentNode.insertBefore(t,n):(document.head||document.body).appendChild(t),this.script=t;var r="undefined"!=typeof navigator&&/gecko/i.test(navigator.userAgent);r&&setTimeout(function(){var e=document.createElement("iframe");document.body.appendChild(e),document.body.removeChild(e)},100)},c.prototype.doWrite=function(e,t){var n=this;if(!this.form){var r=document.createElement("form"),i=document.createElement("textarea"),a=this.iframeId="eio_iframe_"+this.index,l;r.className="socketio",r.style.position="absolute",r.style.top="-1000px",r.style.left="-1000px",r.target=a,r.method="POST",r.setAttribute("accept-charset","utf-8"),i.name="d",r.appendChild(i),document.body.appendChild(r),this.form=r,this.area=i}function u(){c(),t()}function c(){if(n.iframe)try{n.form.removeChild(n.iframe)}catch(e){n.onError("jsonp polling iframe removal error",e)}try{var e='<iframe src="javascript:0" name="'+n.iframeId+'">';l=document.createElement(e)}catch(e){l=document.createElement("iframe"),l.name=n.iframeId,l.src="javascript:0"}l.id=n.iframeId,n.form.appendChild(l),n.iframe=l}this.form.action=this.uri(),c(),e=e.replace(s,"\\\n"),this.area.value=e.replace(o,"\\n");try{this.form.submit()}catch(e){}this.iframe.attachEvent?this.iframe.onreadystatechange=function(){"complete"===n.iframe.readyState&&u()}:this.iframe.onload=u}}).call(this,n(8))},function(e,t,n){(function(t){var r=n(268),i=n(125),o=n(209),s=n(210),a=n(450),l=n(211)("engine.io-client:websocket"),u,c;if("undefined"!=typeof WebSocket)u=WebSocket;else if("undefined"!=typeof self)u=self.WebSocket||self.MozWebSocket;else try{c=n(964)}catch(e){}var h=u||c;function f(e){var t=e&&e.forceBase64;t&&(this.supportsBinary=!1),this.perMessageDeflate=e.perMessageDeflate,this.usingBrowserWebSocket=u&&!e.forceNode,this.protocols=e.protocols,this.usingBrowserWebSocket||(h=c),r.call(this,e)}e.exports=f,s(f,r),f.prototype.name="websocket",f.prototype.supportsBinary=!0,f.prototype.doOpen=function(){if(this.check()){var e=this.uri(),t=this.protocols,n={agent:this.agent,perMessageDeflate:this.perMessageDeflate};n.pfx=this.pfx,n.key=this.key,n.passphrase=this.passphrase,n.cert=this.cert,n.ca=this.ca,n.ciphers=this.ciphers,n.rejectUnauthorized=this.rejectUnauthorized,this.extraHeaders&&(n.headers=this.extraHeaders),this.localAddress&&(n.localAddress=this.localAddress);try{this.ws=this.usingBrowserWebSocket&&!this.isReactNative?t?new h(e,t):new h(e):new h(e,t,n)}catch(e){return this.emit("error",e)}void 0===this.ws.binaryType&&(this.supportsBinary=!1),this.ws.supports&&this.ws.supports.binary?(this.supportsBinary=!0,this.ws.binaryType="nodebuffer"):this.ws.binaryType="arraybuffer",this.addEventListeners()}},f.prototype.addEventListeners=function(){var e=this;this.ws.onopen=function(){e.onOpen()},this.ws.onclose=function(){e.onClose()},this.ws.onmessage=function(t){e.onData(t.data)},this.ws.onerror=function(t){e.onError("websocket error",t)}},f.prototype.write=function(e){var n=this;this.writable=!1;for(var r=e.length,o=0,s=r;o<s;o++)!function(e){i.encodePacket(e,n.supportsBinary,function(i){if(!n.usingBrowserWebSocket){var o={};if(e.options&&(o.compress=e.options.compress),n.perMessageDeflate){var s="string"==typeof i?t.byteLength(i):i.length;s<n.perMessageDeflate.threshold&&(o.compress=!1)}}try{n.usingBrowserWebSocket?n.ws.send(i):n.ws.send(i,o)}catch(e){l("websocket closed before onclose event")}--r||a()})}(e[o]);function a(){n.emit("flush"),setTimeout(function(){n.writable=!0,n.emit("drain")},0)}},f.prototype.onClose=function(){r.prototype.onClose.call(this)},f.prototype.doClose=function(){void 0!==this.ws&&this.ws.close()},f.prototype.uri=function(){var e=this.query||{},t=this.secure?"wss":"ws",n="";this.port&&("wss"===t&&443!==Number(this.port)||"ws"===t&&80!==Number(this.port))&&(n=":"+this.port),this.timestampRequests&&(e[this.timestampParam]=a()),this.supportsBinary||(e.b64=1),e=o.encode(e),e.length&&(e="?"+e);var r=-1!==this.hostname.indexOf(":");return t+"://"+(r?"["+this.hostname+"]":this.hostname)+n+this.path+e},f.prototype.check=function(){return!(!h||"__initialize"in h&&this.name===f.prototype.name)}}).call(this,n(0).Buffer)},function(e,t){},function(e,t){function n(e,t){var n=[];t=t||0;for(var r=t||0;r<e.length;r++)n[r-t]=e[r];return n}e.exports=n},function(e,t){function n(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}e.exports=n,n.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=0==(1&Math.floor(10*t))?e-n:e+n}return 0|Math.min(e,this.max)},n.prototype.reset=function(){this.attempts=0},n.prototype.setMin=function(e){this.ms=e},n.prototype.setMax=function(e){this.max=e},n.prototype.setJitter=function(e){this.jitter=e}},function(e,t,n){(function(t){e.exports=h;var r=n(4)("simple-peer"),i=n(455),o=n(1),s=n(101),a=n(968),l=65536,u=5e3,c=5e3;function h(e){var t=this;if(!(t instanceof h))return new h(e);if(t._id=s(4).toString("hex").slice(0,7),t._debug("new peer %o",e),e=Object.assign({allowHalfOpen:!1},e),a.Duplex.call(t,e),t.channelName=e.initiator?e.channelName||s(20).toString("hex"):null,t.initiator=e.initiator||!1,t.channelConfig=e.channelConfig||h.channelConfig,t.config=Object.assign({},h.config,e.config),t.offerOptions=e.offerOptions||{},t.answerOptions=e.answerOptions||{},t.sdpTransform=e.sdpTransform||function(e){return e},t.streams=e.streams||(e.stream?[e.stream]:[]),t.trickle=void 0===e.trickle||e.trickle,t.allowHalfTrickle=void 0!==e.allowHalfTrickle&&e.allowHalfTrickle,t.iceCompleteTimeout=e.iceCompleteTimeout||u,t.destroyed=!1,t.connected=!1,t.remoteAddress=void 0,t.remoteFamily=void 0,t.remotePort=void 0,t.localAddress=void 0,t.localFamily=void 0,t.localPort=void 0,t._wrtc=e.wrtc&&"object"==typeof e.wrtc?e.wrtc:i(),!t._wrtc)throw"undefined"==typeof window?p("No WebRTC support: Specify `opts.wrtc` option in this environment","ERR_WEBRTC_SUPPORT"):p("No WebRTC support: Not a supported browser","ERR_WEBRTC_SUPPORT");t._pcReady=!1,t._channelReady=!1,t._iceComplete=!1,t._iceCompleteTimer=null,t._channel=null,t._pendingCandidates=[],t._isNegotiating=!t.initiator,t._batchedNegotiation=!1,t._queuedNegotiation=!1,t._sendersAwaitingStable=[],t._senderMap=new Map,t._firstStable=!0,t._closingInterval=null,t._remoteTracks=[],t._remoteStreams=[],t._chunk=null,t._cb=null,t._interval=null;try{t._pc=new t._wrtc.RTCPeerConnection(t.config)}catch(e){t.destroy(e)}t._isReactNativeWebrtc="number"==typeof t._pc._peerConnectionId,t._pc.oniceconnectionstatechange=function(){t._onIceStateChange()},t._pc.onicegatheringstatechange=function(){t._onIceStateChange()},t._pc.onsignalingstatechange=function(){t._onSignalingStateChange()},t._pc.onicecandidate=function(e){t._onIceCandidate(e)},t.initiator?t._setupData({channel:t._pc.createDataChannel(t.channelName,t.channelConfig)}):t._pc.ondatachannel=function(e){t._setupData(e)},t.streams&&t.streams.forEach(function(e){t.addStream(e)}),t._pc.ontrack=function(e){t._onTrack(e)},t.initiator&&t._needsNegotiation(),t._onFinishBound=function(){t._onFinish()},t.once("finish",t._onFinishBound)}function f(e){return e.replace(/a=ice-options:trickle\s\n/g,"")}function p(e,t){var n=new Error(e);return n.code=t,n}o(h,a.Duplex),h.WEBRTC_SUPPORT=!!i(),h.config={iceServers:[{urls:"stun:stun.l.google.com:19302"},{urls:"stun:global.stun.twilio.com:3478?transport=udp"}],sdpSemantics:"unified-plan"},h.channelConfig={},Object.defineProperty(h.prototype,"bufferSize",{get:function(){var e=this;return this._channel&&this._channel.bufferedAmount||0}}),h.prototype.address=function(){var e=this;return{port:this.localPort,family:this.localFamily,address:this.localAddress}},h.prototype.signal=function(e){var t=this;if(t.destroyed)throw p("cannot signal after peer is destroyed","ERR_SIGNALING");if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e={}}t._debug("signal()"),e.renegotiate&&t.initiator&&(t._debug("got request to renegotiate"),t._needsNegotiation()),e.transceiverRequest&&t.initiator&&(t._debug("got request for transceiver"),t.addTransceiver(e.transceiverRequest.kind,e.transceiverRequest.init)),e.candidate&&(t._pc.localDescription&&t._pc.localDescription.type&&t._pc.remoteDescription&&t._pc.remoteDescription.type?t._addIceCandidate(e.candidate):t._pendingCandidates.push(e.candidate)),e.sdp&&t._pc.setRemoteDescription(new t._wrtc.RTCSessionDescription(e)).then(function(){t.destroyed||(t._pendingCandidates.forEach(function(e){t._addIceCandidate(e)}),t._pendingCandidates=[],"offer"===t._pc.remoteDescription.type&&t._createAnswer())}).catch(function(e){t.destroy(p(e,"ERR_SET_REMOTE_DESCRIPTION"))}),e.sdp||e.candidate||e.renegotiate||e.transceiverRequest||t.destroy(p("signal() called with invalid signal data","ERR_SIGNALING"))},h.prototype._addIceCandidate=function(e){var t=this;t._pc.addIceCandidate(new t._wrtc.RTCIceCandidate(e)).catch(function(e){t.destroy(p(e,"ERR_ADD_ICE_CANDIDATE"))})},h.prototype.send=function(e){var t=this;this._channel.send(e)},h.prototype.addTransceiver=function(e,t){var n=this;if(this._debug("addTransceiver()"),this.initiator)try{this._pc.addTransceiver(e,t),this._needsNegotiation()}catch(e){this.destroy(e)}else this.emit("signal",{transceiverRequest:{kind:e,init:t}})},h.prototype.addStream=function(e){var t=this;t._debug("addStream()"),e.getTracks().forEach(function(n){t.addTrack(n,e)})},h.prototype.addTrack=function(e,t){var n=this;this._debug("addTrack()");var r=this._senderMap.get(e)||new Map,i=r.get(t);i?i.removed?this.destroy(p("Track has been removed. You should enable/disable tracks that you want to re-add."),"ERR_SENDER_REMOVED"):this.destroy(p("Track has already been added to that stream."),"ERR_SENDER_ALREADY_ADDED"):(i=this._pc.addTrack(e,t),r.set(t,i),this._senderMap.set(e,r),this._needsNegotiation())},h.prototype.replaceTrack=function(e,t,n){var r=this;this._debug("replaceTrack()");var i=this._senderMap.get(e),o=i?i.get(n):null;o||this.destroy(p("Cannot replace track that was never added."),"ERR_TRACK_NOT_ADDED"),t&&this._senderMap.set(t,i),null!=o.replaceTrack?o.replaceTrack(t):this.destroy(p("replaceTrack is not supported in this browser","ERR_UNSUPPORTED_REPLACETRACK"))},h.prototype.removeTrack=function(e,t){var n=this;this._debug("removeSender()");var r=this._senderMap.get(e),i=r?r.get(t):null;i||this.destroy(p("Cannot remove track that was never added.","ERR_TRACK_NOT_ADDED"));try{i.removed=!0,this._pc.removeTrack(i)}catch(e){"NS_ERROR_UNEXPECTED"===e.name?this._sendersAwaitingStable.push(i):this.destroy(e)}this._needsNegotiation()},h.prototype.removeStream=function(e){var t=this;t._debug("removeSenders()"),e.getTracks().forEach(function(n){t.removeTrack(n,e)})},h.prototype._needsNegotiation=function(){var e=this;e._debug("_needsNegotiation"),e._batchedNegotiation||(e._batchedNegotiation=!0,setTimeout(function(){e._batchedNegotiation=!1,e._debug("starting batched negotiation"),e.negotiate()},0))},h.prototype.negotiate=function(){var e=this;e.initiator?e._isNegotiating?(e._queuedNegotiation=!0,e._debug("already negotiating, queueing")):(e._debug("start negotiation"),setTimeout(()=>{e._createOffer()},0)):e._isNegotiating||(e._debug("requesting negotiation from initiator"),e.emit("signal",{renegotiate:!0})),e._isNegotiating=!0},h.prototype.destroy=function(e){var t=this;this._destroy(e,function(){})},h.prototype._destroy=function(e,t){var n=this;if(!this.destroyed){if(this._debug("destroy (error: %s)",e&&(e.message||e)),this.readable=this.writable=!1,this._readableState.ended||this.push(null),this._writableState.finished||this.end(),this.destroyed=!0,this.connected=!1,this._pcReady=!1,this._channelReady=!1,this._remoteTracks=null,this._remoteStreams=null,this._senderMap=null,clearInterval(this._closingInterval),this._closingInterval=null,clearInterval(this._interval),this._interval=null,this._chunk=null,this._cb=null,this._onFinishBound&&this.removeListener("finish",this._onFinishBound),this._onFinishBound=null,this._channel){try{this._channel.close()}catch(e){}this._channel.onmessage=null,this._channel.onopen=null,this._channel.onclose=null,this._channel.onerror=null}if(this._pc){try{this._pc.close()}catch(e){}this._pc.oniceconnectionstatechange=null,this._pc.onicegatheringstatechange=null,this._pc.onsignalingstatechange=null,this._pc.onicecandidate=null,this._pc.ontrack=null,this._pc.ondatachannel=null}this._pc=null,this._channel=null,e&&this.emit("error",e),this.emit("close"),t()}},h.prototype._setupData=function(e){var t=this;if(!e.channel)return t.destroy(p("Data channel event is missing `channel` property","ERR_DATA_CHANNEL"));t._channel=e.channel,t._channel.binaryType="arraybuffer","number"==typeof t._channel.bufferedAmountLowThreshold&&(t._channel.bufferedAmountLowThreshold=65536),t.channelName=t._channel.label,t._channel.onmessage=function(e){t._onChannelMessage(e)},t._channel.onbufferedamountlow=function(){t._onChannelBufferedAmountLow()},t._channel.onopen=function(){t._onChannelOpen()},t._channel.onclose=function(){t._onChannelClose()},t._channel.onerror=function(e){t.destroy(p(e,"ERR_DATA_CHANNEL"))};var n=!1;t._closingInterval=setInterval(function(){t._channel&&"closing"===t._channel.readyState?(n&&t._onChannelClose(),n=!0):n=!1},5e3)},h.prototype._read=function(){},h.prototype._write=function(e,t,n){var r=this;if(this.destroyed)return n(p("cannot write after peer is destroyed","ERR_DATA_CHANNEL"));if(this.connected){try{this.send(e)}catch(e){return this.destroy(p(e,"ERR_DATA_CHANNEL"))}this._channel.bufferedAmount>65536?(this._debug("start backpressure: bufferedAmount %d",this._channel.bufferedAmount),this._cb=n):n(null)}else this._debug("write before connect"),this._chunk=e,this._cb=n},h.prototype._onFinish=function(){var e=this;function t(){setTimeout(function(){e.destroy()},1e3)}e.destroyed||(e.connected?t():e.once("connect",t))},h.prototype._startIceCompleteTimeout=function(){var e=this;e.destroyed||e._iceCompleteTimer||(e._debug("started iceComplete timeout"),e._iceCompleteTimer=setTimeout(function(){e._iceComplete||(e._iceComplete=!0,e._debug("iceComplete timeout completed"),e.emit("iceTimeout"),e.emit("_iceComplete"))},e.iceCompleteTimeout))},h.prototype._createOffer=function(){var e=this;e.destroyed||e._pc.createOffer(e.offerOptions).then(function(t){function n(){e._debug("createOffer success"),e.destroyed||(e.trickle||e._iceComplete?i():e.once("_iceComplete",i))}function r(t){e.destroy(p(t,"ERR_SET_LOCAL_DESCRIPTION"))}function i(){if(!e.destroyed){var n=e._pc.localDescription||t;e._debug("signal"),e.emit("signal",{type:n.type,sdp:n.sdp})}}e.destroyed||(e.trickle||e.allowHalfTrickle||(t.sdp=f(t.sdp)),t.sdp=e.sdpTransform(t.sdp),e._pc.setLocalDescription(t).then(n).catch(r))}).catch(function(t){e.destroy(p(t,"ERR_CREATE_OFFER"))})},h.prototype._requestMissingTransceivers=function(){var e=this;e._pc.getTransceivers&&e._pc.getTransceivers().forEach(t=>{t.mid||!t.sender.track||t.requested||(t.requested=!0,e.addTransceiver(t.sender.track.kind))})},h.prototype._createAnswer=function(){var e=this;e.destroyed||e._pc.createAnswer(e.answerOptions).then(function(t){function n(){e.destroyed||(e.trickle||e._iceComplete?i():e.once("_iceComplete",i))}function r(t){e.destroy(p(t,"ERR_SET_LOCAL_DESCRIPTION"))}function i(){if(!e.destroyed){var n=e._pc.localDescription||t;e._debug("signal"),e.emit("signal",{type:n.type,sdp:n.sdp}),e.initiator||e._requestMissingTransceivers()}}e.destroyed||(e.trickle||e.allowHalfTrickle||(t.sdp=f(t.sdp)),t.sdp=e.sdpTransform(t.sdp),e._pc.setLocalDescription(t).then(n).catch(r))}).catch(function(t){e.destroy(p(t,"ERR_CREATE_ANSWER"))})},h.prototype._onIceStateChange=function(){var e=this;if(!this.destroyed){var t=this._pc.iceConnectionState,n=this._pc.iceGatheringState;this._debug("iceStateChange (connection: %s) (gathering: %s)",t,n),this.emit("iceStateChange",t,n),"connected"!==t&&"completed"!==t||(this._pcReady=!0,this._maybeReady()),"failed"===t&&this.destroy(p("Ice connection failed.","ERR_ICE_CONNECTION_FAILURE")),"closed"===t&&this.destroy(p("Ice connection closed.","ERR_ICE_CONNECTION_CLOSED"))}},h.prototype.getStats=function(e){var t=this;function n(e){return"[object Array]"===Object.prototype.toString.call(e.values)&&e.values.forEach(function(t){Object.assign(e,t)}),e}0===t._pc.getStats.length?t._pc.getStats().then(function(t){var r=[];t.forEach(function(e){r.push(n(e))}),e(null,r)},function(t){e(t)}):t._isReactNativeWebrtc?t._pc.getStats(null,function(t){var r=[];t.forEach(function(e){r.push(n(e))}),e(null,r)},function(t){e(t)}):t._pc.getStats.length>0?t._pc.getStats(function(r){if(!t.destroyed){var i=[];r.result().forEach(function(e){var t={};e.names().forEach(function(n){t[n]=e.stat(n)}),t.id=e.id,t.type=e.type,t.timestamp=e.timestamp,i.push(n(t))}),e(null,i)}},function(t){e(t)}):e(null,[])},h.prototype._maybeReady=function(){var e=this;function t(){e.destroyed||e.getStats(function(n,r){if(!e.destroyed){n&&(r=[]);var i={},o={},s={},a=!1;if(r.forEach(function(e){"remotecandidate"!==e.type&&"remote-candidate"!==e.type||(i[e.id]=e),"localcandidate"!==e.type&&"local-candidate"!==e.type||(o[e.id]=e),"candidatepair"!==e.type&&"candidate-pair"!==e.type||(s[e.id]=e)}),r.forEach(function(e){"transport"===e.type&&e.selectedCandidatePairId&&u(s[e.selectedCandidatePairId]),("googCandidatePair"===e.type&&"true"===e.googActiveConnection||("candidatepair"===e.type||"candidate-pair"===e.type)&&e.selected)&&u(e)}),a||Object.keys(s).length&&!Object.keys(o).length){if(e._connecting=!1,e.connected=!0,e._chunk){try{e.send(e._chunk)}catch(n){return e.destroy(p(n,"ERR_DATA_CHANNEL"))}e._chunk=null,e._debug('sent chunk from "write before connect"');var l=e._cb;e._cb=null,l(null)}"number"!=typeof e._channel.bufferedAmountLowThreshold&&(e._interval=setInterval(function(){e._onInterval()},150),e._interval.unref&&e._interval.unref()),e._debug("connect"),e.emit("connect")}else setTimeout(t,100)}function u(t){a=!0;var n=o[t.localCandidateId];n&&(n.ip||n.address)?(e.localAddress=n.ip||n.address,e.localPort=Number(n.port)):n&&n.ipAddress?(e.localAddress=n.ipAddress,e.localPort=Number(n.portNumber)):"string"==typeof t.googLocalAddress&&(n=t.googLocalAddress.split(":"),e.localAddress=n[0],e.localPort=Number(n[1])),e.localAddress&&(e.localFamily=e.localAddress.includes(":")?"IPv6":"IPv4");var r=i[t.remoteCandidateId];r&&(r.ip||r.address)?(e.remoteAddress=r.ip||r.address,e.remotePort=Number(r.port)):r&&r.ipAddress?(e.remoteAddress=r.ipAddress,e.remotePort=Number(r.portNumber)):"string"==typeof t.googRemoteAddress&&(r=t.googRemoteAddress.split(":"),e.remoteAddress=r[0],e.remotePort=Number(r[1])),e.remoteAddress&&(e.remoteFamily=e.remoteAddress.includes(":")?"IPv6":"IPv4"),e._debug("connect local: %s:%s remote: %s:%s",e.localAddress,e.localPort,e.remoteAddress,e.remotePort)}})}e._debug("maybeReady pc %s channel %s",e._pcReady,e._channelReady),!e.connected&&!e._connecting&&e._pcReady&&e._channelReady&&(e._connecting=!0,t())},h.prototype._onInterval=function(){var e=this;!this._cb||!this._channel||this._channel.bufferedAmount>65536||this._onChannelBufferedAmountLow()},h.prototype._onSignalingStateChange=function(){var e=this;e.destroyed||("stable"!==e._pc.signalingState||e._firstStable||(e._isNegotiating=!1,e._debug("flushing sender queue",e._sendersAwaitingStable),e._sendersAwaitingStable.forEach(function(t){e._pc.removeTrack(t),e._queuedNegotiation=!0}),e._sendersAwaitingStable=[],e._queuedNegotiation&&(e._debug("flushing negotiation queue"),e._queuedNegotiation=!1,e._needsNegotiation()),e._debug("negotiate"),e.emit("negotiate")),e._firstStable=!1,e._debug("signalingStateChange %s",e._pc.signalingState),e.emit("signalingStateChange",e._pc.signalingState))},h.prototype._onIceCandidate=function(e){var t=this;this.destroyed||(e.candidate&&this.trickle?this.emit("signal",{candidate:{candidate:e.candidate.candidate,sdpMLineIndex:e.candidate.sdpMLineIndex,sdpMid:e.candidate.sdpMid}}):e.candidate||this._iceComplete||(this._iceComplete=!0,this.emit("_iceComplete")),e.candidate&&this._startIceCompleteTimeout())},h.prototype._onChannelMessage=function(e){var n=this;if(!this.destroyed){var r=e.data;r instanceof ArrayBuffer&&(r=t.from(r)),this.push(r)}},h.prototype._onChannelBufferedAmountLow=function(){var e=this;if(!this.destroyed&&this._cb){this._debug("ending backpressure: bufferedAmount %d",this._channel.bufferedAmount);var t=this._cb;this._cb=null,t(null)}},h.prototype._onChannelOpen=function(){var e=this;this.connected||this.destroyed||(this._debug("on channel open"),this._channelReady=!0,this._maybeReady())},h.prototype._onChannelClose=function(){var e=this;this.destroyed||(this._debug("on channel close"),this.destroy())},h.prototype._onTrack=function(e){var t=this;t.destroyed||e.streams.forEach(function(n){t._debug("on track"),t.emit("track",e.track,n),t._remoteTracks.push({track:e.track,stream:n}),t._remoteStreams.some(function(e){return e.id===n.id})||(t._remoteStreams.push(n),setTimeout(function(){t.emit("stream",n)},0))})},h.prototype._debug=function(){var e=this,t=[].slice.call(arguments);t[0]="["+this._id+"] "+t[0],r.apply(null,t)}}).call(this,n(0).Buffer)},function(e,t,n){t=e.exports=n(456),t.Stream=t,t.Readable=t,t.Writable=n(459),t.Duplex=n(126),t.Transform=n(460),t.PassThrough=n(972)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(971);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(460),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){function n(e,t){if(e&&t)return n(e)(t);if("function"!=typeof e)throw new TypeError("need wrapper function");return Object.keys(e).forEach(function(t){r[t]=e[t]}),r;function r(){for(var t=new Array(arguments.length),n=0;n<t.length;n++)t[n]=arguments[n];var r=e.apply(this,t),i=t[t.length-1];return"function"==typeof r&&r!==i&&Object.keys(i).forEach(function(e){r[e]=i[e]}),r}}e.exports=n},function(e,t){var n,r;self.mozRTCPeerConnection||navigator.mozGetUserMedia?(n="moz",r=parseInt(navigator.userAgent.match(/Firefox\/([0-9]+)\./)[1],10)):(self.webkitRTCPeerConnection||navigator.webkitGetUserMedia)&&(n="webkit",r=navigator.userAgent.match(/Chrom(e|ium)/)&&parseInt(navigator.userAgent.match(/Chrom(e|ium)\/([0-9]+)\./)[2],10));var i=self.RTCPeerConnection||self.mozRTCPeerConnection||self.webkitRTCPeerConnection,o=self.mozRTCIceCandidate||self.RTCIceCandidate,s=self.mozRTCSessionDescription||self.RTCSessionDescription,a=self.webkitMediaStream||self.MediaStream,l="https:"===self.location.protocol&&("webkit"===n&&r>=26||"moz"===n&&r>=33),u=self.AudioContext||self.webkitAudioContext,c=self.document&&document.createElement("video"),h=c&&c.canPlayType&&"probably"===c.canPlayType('video/webm; codecs="vp8", vorbis'),f=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.msGetUserMedia||navigator.mozGetUserMedia;e.exports={prefix:n,browserVersion:r,support:!!i&&!!f,supportRTCPeerConnection:!!i,supportVp8:h,supportGetUserMedia:!!f,supportDataChannel:!!(i&&i.prototype&&i.prototype.createDataChannel),supportWebAudio:!(!u||!u.prototype.createMediaStreamSource),supportMediaStream:!(!a||!a.prototype.removeTrack),supportScreenSharing:!!l,AudioContext:u,PeerConnection:i,SessionDescription:s,IceCandidate:o,MediaStream:a,getUserMedia:f}},function(e,t,n){"use strict";const r=n(22);function i(e){const t=e.toString().split("/"),n=e.protos()[1].name,i=e.protos()[2].name,o=e.stringTuples()[1][1];if("tcp"!==n||"ws"!==i&&"wss"!==i)throw new Error("invalid multiaddr: "+e.toString());return r.isName(e)?"ws"===i?"http://"+t[2]+(80===o?"":":"+o):"wss"===i?"https://"+t[2]+(443===o?"":":"+o):void 0:"http://"+t[2]+":"+t[4]}function o(e){const t="/libp2p-webrtc-star";if(-1!==e.indexOf(t)){e=e.substring(t.length,e.length);let n=r(e);const i=n.stringTuples().filter(e=>421===e[0])[0];n=n.decapsulate("ipfs"),n=n.encapsulate("/p2p-webrtc-star"),n=n.encapsulate(`/ipfs/${i[1]}`),e=n.toString()}return e}t=e.exports,t.cleanUrlSIO=i,t.cleanMultiaddr=o},function(e,t,n){"use strict";const r=n(4),i=r("libp2p:websocket-star:multi"),o=n(26),s=n(6).EventEmitter,a=n(59),l=n(36),u=n(22),c=n(72),h=n(977);class f{constructor(e){this.opt=e||{},this.servers=e.servers||[],this.ws=new h(this.opt),this.discovery=this.ws.discovery}dial(e,t,n){return i("dial",e),this.ws.dial(e,t,n)}createListener(e,t){"function"==typeof e&&(t=e,e={});const n=new s;return n.servers={},n.online=[],this.servers.forEach(r=>{const i=this.ws.createListener(e,t);i.once("error",()=>{}),i.url=r,n.servers[r]=i}),n.listen=((e,t)=>{const r=e.toString().split("ipfs/").pop();i("listen on %s server(s) with id %s",this.servers.length,r),l(this.servers.map(e=>n.servers[e]).map(e=>t=>{i("listen %s",e.url);const s=o(r=>(i("listen %s ok %s",e.url,!r),r?t(i(r)):(n.online.push(e),t())));setTimeout(s,this.opt.timeout||5e3,new Error("Timeout")),e.listen(u(e.url).encapsulate("/ipfs/"+r),s)}),()=>{if(n.online.length||this.opt.ignore_no_online)n.emit("listening"),t();else{const e=new Error("Couldn't listen on any of the servers");n.emit("error",e),t(e)}})}),n.close=(e=>l(n.online.map(e=>t=>e.close(t)),t=>e(t,n.online=[]))),n.getAddrs=(e=>a(n.online,(e,t)=>e.getAddrs(t),(t,n)=>t?e(t):e(null,n.reduce((e,t)=>e.concat(t),[])))),n}filter(e){return Array.isArray(e)||(e=[e]),e.filter(e=>e.toString().startsWith("/p2p-websocket-star")||c.WebSocketStar.matches(e))}}e.exports=f},function(e,t,n){"use strict";const r=n(4),i=r("libp2p:websocket-star"),o=n(22),s=n(6).EventEmitter,a=n(15),l=n(31),u=n(64).Connection,c=n(20),h=n(462),f=n(978),p=h.cleanUrlSIO,d=n(72),m=n(39);class g{constructor(e){e=e||{},this.id=e.id,this.flag=e.allowJoinWithDisabledChallenge,this.discovery=new s,this.discovery.tag="websocketStar",this.discovery.start=(e=>{c(e)}),this.discovery.stop=(e=>{c(e)}),this.listeners_list={},this._peerDiscovered=this._peerDiscovered.bind(this)}lazySetId(e){e&&(this.id=e,this.canCrypto=!0)}dial(e,t,n){let r;"function"==typeof t&&(n=t,t={});try{r=p(e)}catch(e){return n(e)}const i=this.listeners_list[r];return i?i.dial(e,t,n):(n(new Error("No listener for this server")),new u)}createListener(e,t){"function"==typeof e&&(t=e,e={});const n=new f({id:this.id,handler:t,listeners:this.listeners_list,flag:this.flag});return n.on("peer",this._peerDiscovered),n}filter(e){return Array.isArray(e)||(e=[e]),e.filter(e=>d.WebSocketStar.matches(e))}_peerDiscovered(e){i("Peer Discovered:",e);const t=e.split("/ipfs/").pop(),n=a.createFromB58String(t),r=new l(n);r.multiaddrs.add(o(e)),this.discovery.emit("peer",r)}}e.exports=m(g,{className:"WebsocketStar",symbolName:"@libp2p/js-libp2p-websocket-star/websocketstar"})},function(e,t,n){"use strict";(function(t){const r=n(4),i=r("libp2p:websocket-star:listener"),o=n(22),s=n(442),a=n(979),l=n(463),u=n(43),c=n(6).EventEmitter,h=n(64).Connection,f=n(26),p=n(20),d=n(462),m=d.cleanUrlSIO,g=n(51),y=n(12),v=n(186),b=n(984),_=f(()=>{}),w={transports:["websocket"],"force new connection":!0};class k extends c{constructor(e){super(),this.id=e.id,this.log=i.bind(i,"listener#offline"),this.canCrypto=Boolean(e.id),this._handler=e.handler||_,this.listeners_list=e.listeners||{},this.flag=e.flag,this.conns=[],this.connected=!1}_up(e){if(e=e?f(e):_,this.io)return e();this.log=i.bind(i,"listener#"+this.server),this.log("dialing to signalling server");const t=this.io=s.connect(this.server,w);a(t,{codec:"buffer"}),t.once("error",e),t.once("connect_error",e),t.once("connect",e);const n=new d.Protocol(this.log);n.addRequest("ws-peer",["multiaddr"],(e,t)=>this.emit("peer",t)),n.addRequest("ss-incomming",["string","multiaddr","function"],this._incommingDial.bind(this)),n.handleSocket(t)}_down(){this.io&&(this.io.disconnect(),this.emit("close"),delete this.io)}_cryptoChallenge(e){if(!this.io)return e(new Error("Not connected"));const n=this.canCrypto?g.keys.marshalPublicKey(this.id.pubKey).toString("hex"):"",r=this.ma.toString();this.io.emit("ss-join",r,n,(n,r,i)=>{if(n)return e(n);if(r){if(!this.canCrypto)return this._down(),e(new Error("Can't sign cryptoChallenge: No id provided"));this.log("performing cryptoChallenge"),this.id.privKey.sign(t.from(r),(t,n)=>{if(t)return e(t);this.signature=n.toString("hex"),this._join(e)})}else{if(!this.flag)return this._down(),e(new Error('Tried to listen on a server with crypto challenge disabled!\n This is prohibited by default and can lead to security issues!\n Please set "allowJoinWithDisabledChallenge" to true in the constructor options (but only if you know what you are doing)!'));this.signature="_",e(null,null,i)}})}_crypto(e){if(e=e?f(e):_,this.log("joining"),!this.io)return e(new Error("Not connected"));this.signature?this._join(e):this._cryptoChallenge(e)}_join(e){this.io.emit("ss-join",this.ma.toString(),this.signature,e)}_incommingDial(e,t,n,r){this.log("dial#"+t+" incomming from",n);const i=o(n),s=this.io.createSource(t+".dialer"),a=this.io.createSink(t+".listener");r();const l=new h({sink:a,source:s},{getObservedAddrs:e=>e(null,[i])});this.emit("connection",l),this._handler(l)}listen(e,t){if(this.ma=e,this.server=m(e),this.listeners_list[this.server]=this,t=t?f(t):_,this.connected)return this.closing=!1,p(()=>t());u([e=>this._up(e),e=>this._crypto((t,n,r)=>e(t,r))],(e,[n,r])=>{if(e){if(e.description&&"ENOTFOUND"===e.description.code){const t=e.description.hostname;e=Object.assign(new Error(`WebSocket connection failed on ${t}`),{code:b.ERR_WS_STAR_WEBSOCKET_CONNECTION})}return this.log("error",e),e instanceof Error||(e=new Error(e)),this._down(),this.emit("error",e),this.emit("close"),t(e)}this.log("success"),this.connected=!0,this.io.on("reconnect",()=>{this.signature=null,this._crypto((e,t,n)=>{if(e)this.log("reconnect error",e),this.emit("error",e);else{this.log("reconnected");for(const e of n||[])this.emit("peer",e)}})}),this.emit("listening");for(const e of r||[])this.emit("peer",e);t()})}getAddrs(e){p(()=>e(null,this.ma?[this.ma]:[]))}get activeConnections(){return this.conns=this.conns.filter(e=>e.sink||e.source),Boolean(this.conns.length)}maybeClose(){!this.activeConnections&&this.closing&&(this.connected=!1,this.closing=!1,this.log("no more connections and listener is offline - closing"),this._down())}close(e){e=e?f(e):_,this.closing=!0,this.maybeClose(),e()}stateWatch(e,t){let n={sink:!0,source:!0};const r=e=>v(e=>e,t=>{n[e]=!1,n.sink||n.source||this.maybeClose()});return this.conns.push(n),{sink:y(r("sink"),e),source:y(t,r("source"))}}dial(e,t,n){"function"==typeof t&&(n=t,t={});const r=o(e),s=new h(null),a=l(),u=this.log.bind(i,"dial#"+a);n=n?f(n):_;let c=this.io;if(!c)return n(new Error("Not listening"));const p=c.createSink(a+".dialer");return u("dialing",e.toString()),c.emit("ss-dial",this.ma.toString(),e.toString(),a,e=>{if(e)return n(e instanceof Error?e:new Error(e));u(e?"error: "+e.toString():"success");const t=c.createSource(a+".listener");s.setInnerConn(this.stateWatch(p,t),{getObservedAddrs:e=>e(null,[r])}),n(null,s)}),s}}e.exports=k}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(980),i=n(463),o=n(19),s=(e,t)=>"socket.io-pull-stream."+e+(t?"."+t:""),a=n(982),l=a("socket.io-pull-stream");function u(e,t){if(null==t)return t;try{return e(t)}catch(e){return console.error("Codec Error"),console.error(e),!1}}const c={hex:{encode:e=>e.toString("hex"),decode:e=>t.from(e,"hex")},plain:{encode:e=>e,decode:e=>e},buffer:{encode:e=>t.from(e),decode:e=>t.from(e)}};function h(e){if(e||(e="plain"),"object"==typeof e)return e;const t=c[e];if(!t)throw new Error("Invalid codec "+e);return t}function f(e,t,n){const i=r(),o=e.sioplog.bind(e.sioplog,"source("+t+")"),a=h(n.codec).decode;function l(){e.removeAllListeners(s("error",t)),e.removeAllListeners(s("queue",t))}return o("create source"),e.emit(s("accept",t)),e.on(s("error",t),e=>{o(!0===e?"finish":"error"),l(),i.append({end:e})}),e.on(s("queue",t),e=>{o("queue data"),i.append({data:u(a,e)})}),e.once("disconnect",()=>{l(),i.append({end:!0})}),function(e,t){if(o("reading"),e)return t(e);i.get((e,n)=>e?t(e):n.end?(i.error(n.end),t(n.end)):t(null,n.data))}}function p(e,t,n){const i=r(),o=e.sioplog.bind(e.sioplog," sink("+t+")"),a=h(n.codec).encode;let l;function c(e){i.append({err:e}),l=e}return o("create sink"),e.once(s("accept",t),()=>{function n(){i.get((r,l)=>{let{data:c,err:h}=l||{};if(r&&(h=r),o("send",h&&!0===h?"finish":h?"error":c?"data":"<invalid>"),h&&!r&&i.error(h),h)return e.emit(s("error",t),h);c&&e.emit(s("queue",t),u(a,c)),n()})}o("start transmission"),n()}),e.once("disconnect",()=>c(!0)),function(e){e(null,function t(n,r){return n?c(n):l?e(l,t):(i.append({data:r}),void e(null,t))})}}e.exports=function e(t,n){t.createSink||(t.sioplog=t.id?l.bind(l,"["+t.id+"]"):l,t.createSink=((e,r)=>{e||(e=i());const o=p(t,e,n||r);return o.id=e,o}),t.createSource=((e,r)=>{const i=f(t,e,n||r);return i.id=e,i}),t.createProxy=((e,n,r)=>{o(t.createSource(e,r),n.createSink(e,r))}))}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(6).EventEmitter;function i(){const e=new r;let t=[],n;function i(){e.removeAllListeners("err"),e.removeAllListeners("data")}return{append:r=>{if(n)return n;t.push(r),e.emit("data")},prepend:e=>{if(n)return n;t.unshift(e)},error:t=>{n=t,e.emit("err",t)},get:r=>(i(),n?r(n):t.length?r(null,t.shift()):(e.once("err",e=>{i(),r(e)}),void e.once("data",()=>(i(),r(null,t.shift()))))),height:()=>t.length}}e.exports=i},function(e,t,n){var r=n(404),i=n(405),o,s,a=0,l=0;function u(e,t,n){var u=t&&n||0,c=t||[];e=e||{};var h=e.node||o,f=void 0!==e.clockseq?e.clockseq:s;if(null==h||null==f){var p=r();null==h&&(h=o=[1|p[0],p[1],p[2],p[3],p[4],p[5]]),null==f&&(f=s=16383&(p[6]<<8|p[7]))}var d=void 0!==e.msecs?e.msecs:(new Date).getTime(),m=void 0!==e.nsecs?e.nsecs:l+1,g=d-a+(m-l)/1e4;if(g<0&&void 0===e.clockseq&&(f=f+1&16383),(g<0||d>a)&&void 0===e.nsecs&&(m=0),m>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");a=d,l=m,s=f,d+=122192928e5;var y=(1e4*(268435455&d)+m)%4294967296;c[u++]=y>>>24&255,c[u++]=y>>>16&255,c[u++]=y>>>8&255,c[u++]=255&y;var v=d/4294967296*1e4&268435455;c[u++]=v>>>8&255,c[u++]=255&v,c[u++]=v>>>24&15|16,c[u++]=v>>>16&255,c[u++]=f>>>8|128,c[u++]=255&f;for(var b=0;b<6;++b)c[u+b]=h[b];return t||i(c)}e.exports=u},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(983)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t,n){"use strict";t.ERR_WS_STAR_WEBSOCKET_CONNECTION="ERR_WS_STAR_WEBSOCKET_CONNECTION"},function(e,t,n){"use strict";const r=n(80),i=n(986),o=n(464),s=n(988),a=n(53);function l(e,t){const n=r(e);n.on("end",()=>n.destroy());const o=new i({halfOpen:!0,initiator:!t});return a(n,o,n),new s(e,o)}t=e.exports=l,t.multicodec=o,t.dialer=(e=>l(e,!1)),t.listener=(e=>l(e,!0))},function(e,t,n){"use strict";(function(t){const r=n(17),i=n(35),o=n(4),s=n(987),a=t.from([0]),l=t.alloc(0);let u=t.alloc(10240),c=0;class h extends r.Duplex{constructor(e,n){super(),"function"==typeof e&&(n=e,e={}),e||(e={}),n&&this.on("stream",n),this.destroyed=!1,this.limit=e.limit||0,null==e.initiator&&(e.initiator=!0),this.initiator=e.initiator,this._corked=0,this._options=e,this._binaryName=Boolean(e.binaryName),this._local=[],this._remote=[],this._list=this._local,this._receiving=null,this._chunked=!1,this._state=0,this._type=0,this._channel=0,this._missing=0,this._message=null,this.log=o("mplex:main:"+Math.floor(1e5*Math.random())),this.log("construction");let r=100;this.limit&&(r=i.encodingLength(this.limit)),this._buf=t.alloc(r),this._ptr=0,this._awaitChannelDrains=0,this._onwritedrain=null,this._ondrain=[],this._finished=!1,this.once("finish",this._clear),this._nextId=this.initiator?0:1}_nextStreamId(){let e=this._nextId;return this._nextId+=2,e}createStream(e,t){if(this.destroyed)throw new Error("Multiplexer is destroyed");const n=this._nextStreamId();let r=this._name(e||n.toString());const i=Object.assign(this._options,t);this.log("createStream: %s",n,r.toString(),i);const o=new s(r,this,i);return this._addChannel(o,n,this._local)}receiveStream(e,t){if(this.destroyed)throw new Error("Multiplexer is destroyed");if(void 0===e||null===e)throw new Error("Name is needed when receiving a stream");const n=this._name(e);this.log("receiveStream: "+n.toString());const r=new s(n,this,Object.assign(this._options,t));if(this._receiving||(this._receiving={}),this._receiving[r.name])throw new Error("You are already receiving this stream");return this._receiving[r.name]=r,r}_name(e){return this._binaryName?t.isBuffer(e)?e:t.from(e):e.toString()}_send(e,n){const r=n?n.length:0,o=c;this.log("_send",e,r),i.encode(e,u,c),c+=i.encode.bytes,i.encode(r,u,c),c+=i.encode.bytes;let s=u.slice(o,c);return u.length-c<100&&(u=t.alloc(10240),c=0),n&&(s=t.concat([s,n])),this.push(s)}_addChannel(e,t,n){return this.log("_addChannel",t),n[t]=e,e.on("finalize",()=>{this.log("_remove channel",t),n[t]=null}),e.open(t,n===this._local),e}_writeVarint(e,t){for(;t<e.length;t++){if(this._ptr===this._buf.length)return this._lengthError(e);if(this._buf[this._ptr++]=e[t],!(128&e[t])){if(0===this._state){const e=i.decode(this._buf);this._type=7&e,this._channel=e>>3,this._list=1&this._type?this._local:this._remote;const t=this._list.length>this._channel&&this._list[this._channel]&&this._list[this._channel].chunked;this._chunked=Boolean(1===this._type||2===this._type)&&t}else if(this._missing=i.decode(this._buf),this.limit&&this._missing>this.limit)return this._lengthError(e);return this._state++,this._ptr=0,t+1}}return e.length}_lengthError(e){return this.destroy(new Error("Incoming message is too big")),e.length}_writeMessage(e,n){const r=e.length-n,i=this._missing;if(!this._message){if(i<=r)return this._missing=0,this._push(e.slice(n,n+i)),n+i;if(this._chunked)return this._missing-=r,this._push(e.slice(n,e.length)),e.length;this._message=t.alloc(i)}return e.copy(this._message,this._ptr,n,n+i),i<=r?(this._missing=0,this._push(this._message),n+i):(this._missing-=r,this._ptr+=r,e.length)}_push(e){if(this.log("_push",e.length),this._missing||(this._ptr=0,this._state=0,this._message=null),0===this._type){if(this.log("open",this._channel),this.destroyed||this._finished)return;let t,n;return t=this._binaryName?e:e.toString()||this._channel.toString(),this.log("open name",t),void(this._receiving&&this._receiving[t]?(n=this._receiving[t],delete this._receiving[t],this._addChannel(n,this._channel,this._list)):(n=new s(t,this,this._options),this.emit("stream",this._addChannel(n,this._channel,this._list),n.name)))}const t=this._list[this._channel];if(t)switch(this._type){case 5:case 6:{const n=new Error(e.toString()||"Channel destroyed");return t.local=!1,void t.destroy(n)}case 3:case 4:return void t.push(null);case 1:case 2:t.push(e)||(this._awaitChannelDrains++,t._awaitDrain++)}}_onchanneldrain(e){if(this._awaitChannelDrains-=e,this._awaitChannelDrains)return;const t=this._onwritedrain;this._onwritedrain=null,t&&t()}_write(e,t,n){if(this.log("_write",e.length),this._finished)return void n();if(this._corked)return void this._onuncork(this._write.bind(this,e,t,n));if(e===a)return void this._finish(n);let r=0;for(;r<e.length;)r=2===this._state?this._writeMessage(e,r):this._writeVarint(e,r);2!==this._state||this._missing||this._push(l),this._awaitChannelDrains?this._onwritedrain=n:n()}_finish(e){this._onuncork(()=>{!1===this._writableState.prefinished&&(this._writableState.prefinished=!0),this.emit("prefinish"),this._onuncork(e)})}cork(){1==++this._corked&&this.emit("cork")}uncork(){this._corked&&0==--this._corked&&this.emit("uncork")}end(e,t,n){return this.log("end"),"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e&&this.write(e),this._writableState.ending||this.write(a),r.Writable.prototype.end.call(this,n)}_onuncork(e){this._corked?this.once("uncork",e):e()}_read(){for(;this._ondrain.length;)this._ondrain.shift()()}_clear(){if(this.log("_clear"),this._finished)return;this._finished=!0;const e=this._local.concat(this._remote);this._local=[],this._remote=[],e.forEach(function(e){e&&(e.local=!1,e.destroy(null))}),this.push(null)}finalize(){this._clear()}_destroy(e,t){this.log("destroy");const n=this._local.concat(this._remote);n.forEach(function(t){t&&t.destroy(e||new Error("Channel destroyed"))}),this._clear(),t(e)}}e.exports=h}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(17),i=n(4);class o extends r.Duplex{constructor(e,t,n){const r=Boolean(n.halfOpen);super({allowHalfOpen:r}),this.name=e,this.log=i("mplex:channel:"+this.name.toString()),this.channel=0,this.initiator=!1,this.chunked=Boolean(n.chunked),this.halfOpen=r,this.destroyed=!1,this.finalized=!1,this.local=!0,this._multiplex=t,this._dataHeader=0,this._opened=!1,this._awaitDrain=0,this._lazy=Boolean(n.lazy);let o=!1,s=!1;this.log("open, halfOpen: "+this.halfOpen),this.once("end",()=>{this.log("end"),this._read(),this.destroyed||(s=!0,o?this._finalize():this.halfOpen||this.end())}),this.once("finish",function e(){if(!this.destroyed){if(!this._opened)return this.once("open",e);this._lazy&&this.initiator&&this._open(),this._multiplex._send(this.channel<<3|(this.initiator?4:3),null),o=!0,s&&this._finalize()}})}emit(e,...t){"error"!==e||this._events.error?super.emit(e,...t):this.log("error",...t)}_destroy(e,n){if(this.log("_destroy:"+(this.local?"local":"remote")),this.local&&this._opened){this._lazy&&this.initiator&&this._open();const n=e?t.from(e.message):null;try{this._multiplex._send(this.channel<<3|(this.initiator?6:5),n)}catch(e){}}this._finalize(),n(e)}_finalize(){this.finalized||(this.finalized=!0,this.emit("finalize"))}_write(e,t,n){if(this.log("write: ",e.length),!this._opened)return void this.once("open",()=>{this._write(e,t,n)});if(this.destroyed)return void n();this._lazy&&this.initiator&&this._open();const r=this._multiplex._send(this._dataHeader,e);r?n():this._multiplex._ondrain.push(n)}_read(){if(this._awaitDrain){const e=this._awaitDrain;this._awaitDrain=0,this._multiplex._onchanneldrain(e)}}_open(){let e=null;t.isBuffer(this.name)?e=this.name:this.name!==this.channel.toString()&&(e=t.from(this.name)),this._lazy=!1,this._multiplex._send(this.channel<<3|0,e)}open(e,t){this.log("open: "+e),this.channel=e,this.initiator=t,this._dataHeader=e<<3|(t?2:1),this._opened=!0,!this._lazy&&this.initiator&&this._open(),this.emit("open")}}e.exports=o}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(6).EventEmitter,i=n(64).Connection,o=n(69),s=n(19),a=n(989),l=n(20),u=n(4),c=u("mplex");c.error=u("mplex:error");const h=n(464);function f(){}function p(e){return{source:s(e.source,a(e=>{if("Channel destroyed"!==e.message)return!1})),sink:e.sink}}class d extends r{constructor(e,t){super(),this.multiplex=t,this.conn=e,this.multicodec=h,t.on("close",()=>this.emit("close")),t.on("error",e=>this.emit("error",e)),t.on("stream",(e,t)=>{const n=new i(p(o.duplex(e)),this.conn);this.emit("stream",n)})}emit(e,...t){"error"!==e||this._events.error?super.emit(e,...t):c.error("error",...t)}newStream(e){let t;e=e||f;try{t=this.multiplex.createStream()}catch(t){return l(()=>e(t))}const n=new i(p(o.duplex(t)),this.conn);return l(()=>e(null,n)),n}end(e,t){"function"==typeof e&&(t=e,e=null),t=t||f,this.multiplex.destroy(e),t()}}e.exports=d},function(e,t){e.exports=function e(t){var n;return t=t||function e(){},function e(r){return function e(i,o){r(i,function e(r,i){if(n)return o(!0);if(r&&!0!==r){var s=t(r);return!1===s?o(r):s&&!0!==s?(n=!0,o(null,s)):o(!0)}o(r,i)})}}}},function(e,t){},function(e,t,n){"use strict";const r=n(12),i=n(64).Connection,o=n(24),s=n(31),a=n(4),l=n(26),u=a("libp2p:secio");u.error=a("libp2p:secio:error");const c=n(992),h=n(998);e.exports={tag:"/secio/1.0.0",encrypt(e,t,n,a){o(e,"no local private key provided"),o(t,"no connection for the handshake provided"),"function"==typeof n&&(a=n,n=void 0),a=l(a||function(e){e&&u.error(e)});const f=3e5,p=new h(e,n,3e5,a);function d(e){if(e)return a(e);t.getPeerInfo((e,n)=>{m.setInnerConn(new i(p.secure,t)),e&&m.setPeerInfo(new s(p.id.remote)),a()})}const m=new i(void 0,t);return r(t,c(p,d),t),m}}},function(e,t,n){"use strict";const r=n(43),i=n(993),o=n(995),s=n(996);e.exports=function e(t,n){return r([e=>i(t,e),e=>o(t,e),e=>s(t,e)],e=>{t.cleanSecrets(),e&&(!0===e&&(e=new Error("Stream ended prematurely")),t.shake.abort(e)),n(e)}),t.stream}},function(e,t,n){"use strict";const r=n(4),i=n(10),o=n(269),s=n(270),a=r("libp2p:secio");a.error=r("libp2p:secio:error"),e.exports=function e(t,n){a("1. propose - start"),a("1. propose - writing proposal"),o.write(t,s.createProposal(t)),i([e=>o.read(t.shake,e),(e,n)=>{a("1. propose - reading proposal",e),s.identify(t,e,n)},e=>s.selectProtocols(t,e)],e=>{if(e)return n(e);a("1. propose - finish"),n()})}},function(e,t,n){"use strict";e.exports="message Propose {\n optional bytes rand = 1;\n optional bytes pubkey = 2;\n optional string exchanges = 3;\n optional string ciphers = 4;\n optional string hashes = 5;\n}\n\nmessage Exchange {\n optional bytes epubkey = 1;\n optional bytes signature = 2;\n}"},function(e,t,n){"use strict";const r=n(4),i=n(10),o=n(269),s=n(270),a=r("libp2p:secio");a.error=r("libp2p:secio:error"),e.exports=function e(t,n){a("2. exchange - start"),a("2. exchange - writing exchange"),i([e=>s.createExchange(t,e),(e,n)=>{o.write(t,e),o.read(t.shake,n)},(e,n)=>{a("2. exchange - reading exchange"),s.verify(t,e,n)},e=>s.generateKeys(t,e)],e=>{if(e)return n(e);a("2. exchange - finish"),n()})}},function(e,t,n){"use strict";const r=n(12),i=n(71),o=n(102),s=n(4),a=s("libp2p:secio");a.error=s("libp2p:secio:error");const l=n(997),u=n(270);e.exports=function e(t,n){a("3. finish - start");const s=t.protocols,c=t.shake.rest(),h=o({timeout:t.timeout},e=>{if(e)throw e});r(c,l.createUnboxStream(s.remote.cipher,s.remote.mac),h,l.createBoxStream(s.local.cipher,s.local.mac),c),h.handshake.write(t.proposal.in.rand),h.handshake.read(t.proposal.in.rand.length,(e,r)=>{const o=e=>{a.error(e),t.secure.resolve({source:i(e),sink(e){}}),n(e)};if(e)return o(e);try{u.verifyNonce(t,r)}catch(e){return o(e)}a("3. finish - finish"),t.secure.resolve(h.handshake.rest()),n()})}},function(e,t,n){"use strict";(function(e){const r=n(12),i=n(66),o=n(74),s=n(52),a={fixed:!0,bytes:4};function l(){return i(t=>"string"==typeof t?e.from(t,"utf-8"):t)}t.createBoxStream=((t,n)=>r(l(),o((r,i)=>{t.encrypt(r,(t,r)=>{if(t)return i(t);n.digest(r,(t,n)=>{if(t)return i(t);i(null,e.concat([r,n]))})})}),s.encode(a))),t.createUnboxStream=((e,t)=>r(l(),s.decode(a),o((n,r)=>{const i=n.length,o=t.length;if(i<o)return r(new Error(`buffer (${i}) shorter than MAC size (${o})`));const s=i-o,a=n.slice(0,s),l=n.slice(s);t.digest(a,(t,n)=>t?r(t):l.equals(n)?void e.decrypt(a,(e,t)=>{if(e)return r(e);r(null,t)}):r(new Error(`MAC Invalid: ${l.toString("hex")} != ${n.toString("hex")}`)))})))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(102),i=n(61);class o{constructor(e,t,n,o){"function"==typeof n&&(o=n,n=void 0),this.setup(),this.id.local=e,this.id.remote=t,this.key.local=e.privKey,this.timeout=n||6e4,o=o||(()=>{}),this.secure=i.duplex(),this.stream=r({timeout:this.timeout},o),this.shake=this.stream.handshake,delete this.stream.handshake}setup(){this.id={local:null,remote:null},this.key={local:null,remote:null},this.shake=null,this.cleanSecrets()}cleanSecrets(){this.shared={},this.ephemeralKey={local:null,remote:null},this.proposal={in:null,out:null},this.proposalEncoded={in:null,out:null},this.protocols={local:null,remote:null},this.exchange={in:null,out:null}}}e.exports=o},function(e,t,n){"use strict";const r=n(15),i=n(31),o=n(22),s=n(72),a=n(6).EventEmitter,l=n(4),u=n(47),c=l("libp2p:bootstrap");function h(e){try{return s.IPFS.matches(e)}catch(e){return!1}}c.error=l("libp2p:bootstrap:error");class f extends a{constructor(e){super(),this._list=e.list,this._interval=e.interval||1e4,this._timer=null}start(e){if(this._timer)return u(()=>e());this._timer=setInterval(()=>this._discoverBootstrapPeers(),this._interval),u(()=>{e(),this._discoverBootstrapPeers()})}_discoverBootstrapPeers(){this._list.forEach(e=>{if(!h(e))return c.error("Invalid multiaddr");const t=o(e),n=r.createFromB58String(t.getPeerId());i.create(n,(e,n)=>{if(e)return c.error("Invalid bootstrap peer id",e);n.multiaddrs.add(t),this.emit("peer",n)})})}stop(e){u(e),this._timer&&(clearInterval(this._timer),this._timer=null)}}t=e.exports=f,t.tag="bootstrap"},function(e,t,n){"use strict";const{EventEmitter:r}=n(6),i=n(123),o=n(28).MemoryDatastore,s=n(10),a=n(38),l=n(1001),u=n(159),c=n(15),h=n(31),f=n(51),p=n(13),d=n(1002),m=n(44),g=n(127),y=n(465),v=n(1011),b=n(1022),_=n(1025),w=n(90),k=n(1026),E=n(1031),S=n(24);class x extends r{constructor(e,t){super(),S(e,"libp2p-kad-dht requires a instance of Switch"),t=t||{},t.validators=t.validators||{},t.selectors=t.selectors||{},this.switch=e,this.kBucketSize=t.kBucketSize||g.K,this.concurrency=t.concurrency||g.ALPHA,this.disjointPaths=Math.ceil(this.kBucketSize/2),this.routingTable=new d(this.peerInfo.id,this.kBucketSize),this.datastore=t.datastore||new o,this.providers=new _(this.datastore,this.peerInfo.id),this.validators={pk:i.validator.validators.pk,...t.validators},this.selectors={pk:i.selection.selectors.pk,...t.selectors},this.network=new v(this),this._log=m.logger(this.peerInfo.id);const n=b(this);Object.keys(n).forEach(e=>{this[e]=n[e]}),this.randomWalk=new k(this,t.randomWalk),this._queryManager=new E}get isStarted(){return this._running}start(e){this._running=!0,this._queryManager.start(),this.network.start(t=>{if(t)return e(t);this.randomWalk.start(),e()})}stop(e){this._running=!1,this.randomWalk.stop(),this.providers.stop(),this._queryManager.stop(),this.network.stop(e)}get peerInfo(){return this.switch._peerInfo}get peerBook(){return this.switch._peerBook}put(e,t,n,r){"function"==typeof n?(r=n,n={}):n=n||{},this._log("PutValue %b",e),s([n=>m.createPutRecord(e,t,n),(t,r)=>s([n=>this._putLocal(e,t,n),t=>this.getClosestPeers(e,{shallow:!0},t),(r,i)=>{n.minPeers=n.minPeers||r.length,l(r,(n,r)=>{this._putValueToPeer(e,t,n,e=>{if(e)return this._log.error("Failed to put to peer (%b): %s",n.id,e),r(null,!1);r(null,!0)})},(e,t)=>{if(e)return i(e);if(n.minPeers>t.length){const e=p(new Error("Failed to put value to enough peers"),"ERR_NOT_ENOUGH_PUT_PEERS");return this._log.error(e),i(e)}i()})}],r)],r)}get(e,t,n){"function"==typeof t?(n=t,t={}):t=t||{},t.maxTimeout||t.timeout?t.maxTimeout&&!t.timeout&&(t.timeout=t.maxTimeout):t.timeout=g.minute,this._get(e,t,n)}getMany(e,t,n,r){"function"==typeof n?(r=n,n={}):n=n||{},n.maxTimeout||n.timeout?n.maxTimeout&&!n.timeout&&(n.timeout=n.maxTimeout):n.timeout=g.minute,this._log("getMany %b (%s)",e,t);let i=[];this._getLocal(e,(o,a)=>{if(o&&0===t)return r(o);if(null==o&&i.push({val:a.value,from:this.peerInfo.id}),i.length>=t)return r(null,i);const l=[];s([t=>m.convertBuffer(e,t),(r,o)=>{const s=this.routingTable.closestPeers(r,this.kBucketSize);if(this._log("peers in rt: %d",s.length),0===s.length){const e="Failed to lookup key! No peers from routing table!";return this._log.error(e),o(p(new Error(e),"ERR_NO_PEERS_IN_ROUTING_TABLE"))}const a=new y(this,e,(n,r)=>{const o=m.pathSize(t-i.length,r),s=[];return l.push(s),(t,n)=>{this._getValueOrPeers(t,e,(e,r,i)=>{if(e&&"ERR_INVALID_RECORD"!==e.code)return n(e);const a={closerPeers:i};(r&&r.value||e&&"ERR_INVALID_RECORD"===e.code)&&s.push({val:r&&r.value,from:t}),s.length>=o&&(a.pathComplete=!0),n(null,a)})}});u(e=>{a.run(s,e)},n.timeout)((e,t)=>{a.stop(),o(e,t)})}],e=>{if(i=[].concat.apply(i,l).slice(0,t),e&&0===i.length)return r(e);r(null,i)})})}getClosestPeers(e,t,n){this._log("getClosestPeers to %b",e),"function"==typeof t&&(n=t,t={shallow:!1}),m.convertBuffer(e,(r,i)=>{if(r)return n(r);const o=this.routingTable.closestPeers(i,this.kBucketSize),a=new y(this,e,()=>(n,r)=>{s([t=>this._closerPeersSingle(e,n,t),(e,n)=>{n(null,{closerPeers:e,pathComplete:!!t.shallow||void 0})}],r)});a.run(o,(e,t)=>e?n(e):t&&t.finalSet?void s([e=>m.sortClosestPeers(Array.from(t.finalSet),i,e),(e,t)=>t(null,e.slice(0,this.kBucketSize))],n):n(null,[]))})}getPublicKey(e,t){let n;if(this._log("getPublicKey %s",e.toB58String()),this.peerBook.has(e)){if(n=this.peerBook.get(e),n&&n.id.pubKey)return this._log("getPublicKey: found local copy"),t(null,n.id.pubKey)}else n=this.peerBook.put(new h(e));this._getPublicKeyFromNode(e,(r,i)=>{if(!r)return n.id=new c(e.id,null,i),this.peerBook.put(n),t(null,i);const o=m.keyForPublicKey(e);this.get(o,(r,i)=>{if(r)return t(r);const o=f.unmarshalPublicKey(i);n.id=new c(e,null,o),this.peerBook.put(n),t(null,o)})})}findPeerLocal(e,t){this._log("findPeerLocal %s",e.toB58String()),this.routingTable.find(e,(e,n)=>e?t(e):n&&this.peerBook.has(n)?void t(null,this.peerBook.get(n)):t())}provide(e,t){this._log("provide: %s",e.toBaseEncodedString());const n=[];s([t=>this.providers.addProvider(e,this.peerInfo.id,t),t=>this.getClosestPeers(e.buffer,t),(t,r)=>{const i=new w(w.TYPES.ADD_PROVIDER,e.buffer,0);i.providerPeers=t.map(e=>new h(e)),a(t,(t,r)=>{this._log("putProvider %s to %s",e.toBaseEncodedString(),t.toB58String()),this.network.sendMessage(t,i,e=>{e&&n.push(e),r()})},r)}],e=>{n.length&&(e=p(`Failed to provide to ${n.length} of ${this.kBucketSize} peers`,"ERR_SOME_PROVIDES_FAILED",{errors:n})),t(e)})}findProviders(e,t,n){"function"==typeof t?(n=t,t={}):t=t||{},t.maxTimeout||t.timeout?t.maxTimeout&&!t.timeout&&(t.timeout=t.maxTimeout):t.timeout=g.minute,t.maxNumProviders=t.maxNumProviders||g.K,this._log("findProviders %s",e.toBaseEncodedString()),this._findNProviders(e,t.timeout,t.maxNumProviders,n)}findPeer(e,t,n){"function"==typeof t?(n=t,t={}):t=t||{},t.maxTimeout||t.timeout?t.maxTimeout&&!t.timeout&&(t.timeout=t.maxTimeout):t.timeout=g.minute,this._log("findPeer %s",e.toB58String()),this.findPeerLocal(e,(r,i)=>r?n(r):null!=i?(this._log("found local"),n(null,i)):void s([t=>m.convertPeerId(e,t),(n,r)=>{const i=this.routingTable.closestPeers(n,this.kBucketSize);if(0===i.length)return r(p(new Error("Peer lookup failed"),"ERR_LOOKUP_FAILED"));const o=i.find(t=>t.isEqual(e));if(o&&this.peerBook.has(e))return this._log("found in peerbook"),r(null,this.peerBook.get(e));const a=new y(this,e.id,()=>(t,n)=>{s([n=>this._findPeerSingle(t,e,n),(t,n)=>{const r=t.closerPeers.find(t=>t.id.isEqual(e));if(r)return n(null,{peer:r,queryComplete:!0});n(null,{closerPeers:t.closerPeers})}],n)});u(e=>{a.run(i,e)},t.timeout)((e,t)=>{a.stop(),r(e,t)})},(t,n)=>{let r=!1;if(t.paths.forEach(e=>{e.success&&(r=!0,this.peerBook.put(e.peer))}),this._log("findPeer %s: %s",e.toB58String(),r),!r)return n(p(new Error("No peer found"),"ERR_NOT_FOUND"));n(null,this.peerBook.get(e))}],n))}_peerDiscovered(e){this.emit("peer",e)}}e.exports=x},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(411),i=a(r),o=n(110),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default),e.exports=t.default},function(e,t,n){"use strict";const r=n(1003),i=n(44);class o{constructor(e,t){this.self=e,this._onPing=this._onPing.bind(this),i.convertPeerId(e,(e,n)=>{if(e)throw e;this.kb=new r({localNodeId:n,numberOfNodesPerKBucket:t,numberOfNodesToPing:1}),this.kb.on("ping",this._onPing)})}_onPing(e,t){const n=e[0];this.kb.remove(n.id),this.kb.add(t)}get size(){return this.kb.count()}find(e,t){i.convertPeerId(e,(n,r)=>{if(n)return t(n);const i=this.closestPeer(r);if(i&&i.isEqual(e))return t(null,i);t()})}closestPeer(e,t){const n=this.closestPeers(e,1);if(n.length>0)return n[0]}closestPeers(e,t){return this.kb.closest(e,t).map(e=>e.peer)}add(e,t){i.convertPeerId(e,(n,r)=>{if(n)return t(n);this.kb.add({id:r,peer:e}),t()})}remove(e,t){i.convertPeerId(e,(e,n)=>{if(e)return t(e);this.kb.remove(n),t()})}}e.exports=o},function(e,t,n){"use strict";const r=n(101),{EventEmitter:i}=n(6);function o(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let n=0,r=e.length;n<r;++n)if(e[n]!==t[n])return!1;return!0}function s(){return{contacts:[],dontSplit:!1,left:null,right:null}}function a(e,t){if(!(t instanceof Uint8Array))throw new TypeError(e+" is not a Uint8Array")}class l extends i{constructor(e={}){super(),this.localNodeId=e.localNodeId||r(20),this.numberOfNodesPerKBucket=e.numberOfNodesPerKBucket||20,this.numberOfNodesToPing=e.numberOfNodesToPing||3,this.distance=e.distance||l.distance,this.arbiter=e.arbiter||l.arbiter,this.metadata=Object.assign({},e.metadata),a("option.localNodeId as parameter 1",this.localNodeId),this.root={contacts:[],dontSplit:!1,left:null,right:null}}static arbiter(e,t){return e.vectorClock>t.vectorClock?e:t}static distance(e,t){let n=0,r=0;const i=Math.min(e.length,t.length),o=Math.max(e.length,t.length);for(;r<i;++r)n=256*n+(e[r]^t[r]);for(;r<o;++r)n=256*n+255;return n}add(e){a("contact.id",(e||{}).id);let t=0,n=this.root;for(;null===n.contacts;)n=this._determineNode(n,e.id,t++);const r=this._indexOf(n,e.id);return r>=0?(this._update(n,r,e),this):n.contacts.length<this.numberOfNodesPerKBucket?(n.contacts.push(e),this.emit("added",e),this):n.dontSplit?(this.emit("ping",n.contacts.slice(0,this.numberOfNodesToPing),e),this):(this._split(n,t),this.add(e))}closest(e,t=1/0){if(a("id",e),!Number.isInteger(t)&&t!==1/0||t<=0)throw new TypeError("n is not positive number");let n=[];for(let r=[this.root],i=0;r.length>0&&n.length<t;){const t=r.pop();if(null===t.contacts){const n=this._determineNode(t,e,i++);r.push(t.left===n?t.right:t.left),r.push(n)}else n=n.concat(t.contacts)}return n.map(t=>[this.distance(t.id,e),t]).sort((e,t)=>e[0]-t[0]).slice(0,t).map(e=>e[1])}count(){let e=0;for(const t=[this.root];t.length>0;){const n=t.pop();null===n.contacts?t.push(n.right,n.left):e+=n.contacts.length}return e}_determineNode(e,t,n){const r=n>>3,i=n%8;if(t.length<=r&&0!==i)return e.left;const o=t[r];return o&1<<7-i?e.right:e.left}get(e){a("id",e);let t=0,n=this.root;for(;null===n.contacts;)n=this._determineNode(n,e,t++);const r=this._indexOf(n,e);return r>=0?n.contacts[r]:null}_indexOf(e,t){for(let n=0;n<e.contacts.length;++n)if(o(e.contacts[n].id,t))return n;return-1}remove(e){a("the id as parameter 1",e);let t=0,n=this.root;for(;null===n.contacts;)n=this._determineNode(n,e,t++);const r=this._indexOf(n,e);if(r>=0){const e=n.contacts.splice(r,1)[0];this.emit("removed",e)}return this}_split(e,t){e.left={contacts:[],dontSplit:!1,left:null,right:null},e.right={contacts:[],dontSplit:!1,left:null,right:null};for(const n of e.contacts)this._determineNode(e,n.id,t).contacts.push(n);e.contacts=null;const n=this._determineNode(e,this.localNodeId,t),r=e.left===n?e.right:e.left;r.dontSplit=!0}toArray(){let e=[];for(const t=[this.root];t.length>0;){const n=t.pop();null===n.contacts?t.push(n.right,n.left):e=e.concat(n.contacts)}return e}_update(e,t,n){if(!o(e.contacts[t].id,n.id))throw new Error("wrong index for _update");const r=e.contacts[t],i=this.arbiter(r,n);i===r&&r!==n||(e.contacts.splice(t,1),e.contacts.push(i),this.emit("updated",r,i))}}e.exports=l},function(e,t,n){"use strict";const r=n(1005),i=n(6),o=n(38),s=n(1006),a=n(1010),l=n(44);class u extends i{constructor(e){super(),this.query=e,this.running=!1,this.workers=[],this.peersSeen=new Set,this.errors=[],this.peersQueried=null}stop(){if(this.running){this.running=!1;for(const e of this.workers)e.stop()}}execute(e,t){const n=[],r=Math.min(this.query.dht.disjointPaths,e.length);for(let e=0;e<r;e++)n.push(new s(this,this.query.makePath(e,r)));e.forEach((e,t)=>{n[t%r].addInitialPeer(e)}),this.executePaths(n,e=>{if(e)return t(e);const r={finalSet:new Set(this.peersQueried.peers),paths:[]};for(const e of n)e.res&&(e.res.pathComplete||e.res.queryComplete)&&(e.res.success=!0,r.paths.push(e.res));t(e,r)})}executePaths(e,t){this.running=!0,this.emit("start"),o(e,(e,t)=>e.execute(t),e=>(this.stop(),this.emit("complete"),e?t(e):this.errors.length===this.peersSeen.size?t(this.errors[0]):void t()))}workerQueue(e,t){this.init(()=>this.startWorker(e,t))}startWorker(e,t){const n=new a(this.query.dht,this,e,this.query._log);this.workers.push(n),n.execute(t)}init(e){if(this.peersQueried)return e();this.awaitingKey?this.awaitingKey.push(e):(this.awaitingKey=[e],l.convertBuffer(this.query.key,(e,t)=>{this.peersQueried=new r(t,this.query.dht.kBucketSize);for(const t of this.awaitingKey)t(e);this.awaitingKey=void 0}))}continueQuerying(e,t){if(this.peersQueried.length<this.peersQueried.capacity)return t(null,!0);const n=e.queue.workersList().map(e=>e.data);this.peersQueried.anyCloser(n,(e,n)=>e?t(e):n?t(null,!0):void t(null,!1))}}e.exports=u},function(e,t,n){"use strict";const r=n(271),i=n(44),o=n(59);class s{constructor(e,t){this.originDhtKey=e,this.capacity=t,this.peerDistances=[]}get length(){return this.peerDistances.length}get peers(){return this.peerDistances.map(e=>e.peerId)}add(e,t){if(this.peerDistances.find(t=>t.peerId.id.equals(e.id)))return t();i.convertPeerId(e,(n,i)=>{if(n)return t(n);const o={peerId:e,distance:r(this.originDhtKey,i)};this.peerDistances.push(o),this.peerDistances.sort((e,t)=>r.compare(e.distance,t.distance)),this.peerDistances=this.peerDistances.slice(0,this.capacity),t()})}anyCloser(e,t){return e.length?this.length?void o(e,(e,t)=>i.convertPeerId(e,t),(e,n)=>{if(e)return t(e);const i=this.peerDistances[this.peerDistances.length-1].distance;for(const e of n){const n=r(this.originDhtKey,e);if(r.compare(n,i)<0)return t(null,!0)}return t(null,!1)}):t(null,!0):t(null,!1)}}e.exports=s},function(e,t,n){"use strict";const r=n(38),i=n(159),o=n(10),s=n(1007),a=3e4;class l{constructor(e,t){this.run=e,this.queryFunc=i(t,a),this.initialPeers=[],this.peersToQuery=null}addInitialPeer(e){this.initialPeers.push(e)}execute(e){o([e=>s.fromKey(this.run.query.key,e),(e,t)=>{this.peersToQuery=e,r(this.initialPeers,this.addPeerToQuery.bind(this),t)},e=>{this.run.workerQueue(this,e)}],e)}addPeerToQuery(e,t){return this.run.query.dht._isSelf(e)?t():this.run.peersSeen.has(e)?t():void this.peersToQuery.enqueue(e,t)}}e.exports=l},function(e,t,n){"use strict";const r=n(1008),i=n(271),o=n(4),s=n(44),a=o("libp2p:dht:peer-queue");class l{static fromPeerId(e,t){s.convertPeerId(e,(e,n)=>{if(e)return t(e);t(null,new l(n))})}static fromKey(e,t){s.convertBuffer(e,(e,n)=>{if(e)return t(e);t(null,new l(n))})}constructor(e){a("create: %b",e),this.from=e,this.heap=new r(s.xorCompare)}enqueue(e,t){a("enqueue %s",e.toB58String()),s.convertPeerId(e,(n,r)=>{if(n)return t(n);const o={id:e,distance:i(this.from,r)};this.heap.push(o),t()})}dequeue(){const e=this.heap.pop();return a("dequeue %s",e.id.toB58String()),e.id}get length(){return this.heap.size()}}e.exports=l},function(e,t,n){e.exports=n(1009)},function(e,t,n){var r,i,o;(function(){var n,s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w;a=Math.floor,d=Math.min,s=function(e,t){return e<t?-1:e>t?1:0},p=function(e,t,n,r,i){var o;if(null==n&&(n=0),null==i&&(i=s),n<0)throw new Error("lo must be non-negative");for(null==r&&(r=e.length);n<r;)o=a((n+r)/2),i(t,e[o])<0?r=o:n=o+1;return[].splice.apply(e,[n,n-n].concat(t)),t},c=function(e,t,n){return null==n&&(n=s),e.push(t),v(e,0,e.length-1,n)},u=function(e,t){var n,r;return null==t&&(t=s),n=e.pop(),e.length?(r=e[0],e[0]=n,b(e,0,t)):r=n,r},f=function(e,t,n){var r;return null==n&&(n=s),r=e[0],e[0]=t,b(e,0,n),r},h=function(e,t,n){var r;return null==n&&(n=s),e.length&&n(e[0],t)<0&&(r=[e[0],t],t=r[0],e[0]=r[1],b(e,0,n)),t},l=function(e,t){var n,r,i,o,l,u,c,h;for(null==t&&(t=s),u=function(){h=[];for(var t=0,n=a(e.length/2);0<=n?t<n:t>n;0<=n?t++:t--)h.push(t);return h}.apply(this).reverse(),c=[],r=0,o=u.length;r<o;r++)n=u[r],c.push(b(e,n,t));return c},y=function(e,t,n){var r;if(null==n&&(n=s),r=e.indexOf(t),-1!==r)return v(e,0,r,n),b(e,r,n)},m=function(e,t,n){var r,i,o,a,u;if(null==n&&(n=s),i=e.slice(0,t),!i.length)return i;for(l(i,n),u=e.slice(t),o=0,a=u.length;o<a;o++)r=u[o],h(i,r,n);return i.sort(n).reverse()},g=function(e,t,n){var r,i,o,a,c,h,f,m,g,y;if(null==n&&(n=s),10*t<=e.length){if(a=e.slice(0,t).sort(n),!a.length)return a;for(o=a[a.length-1],m=e.slice(t),c=0,f=m.length;c<f;c++)r=m[c],n(r,o)<0&&(p(a,r,0,null,n),a.pop(),o=a[a.length-1]);return a}for(l(e,n),y=[],i=h=0,g=d(t,e.length);0<=g?h<g:h>g;i=0<=g?++h:--h)y.push(u(e,n));return y},v=function(e,t,n,r){var i,o,a;for(null==r&&(r=s),i=e[n];n>t&&(a=n-1>>1,o=e[a],r(i,o)<0);)e[n]=o,n=a;return e[n]=i},b=function(e,t,n){var r,i,o,a,l;for(null==n&&(n=s),i=e.length,l=t,o=e[t],r=2*t+1;r<i;)a=r+1,a<i&&!(n(e[r],e[a])<0)&&(r=a),e[t]=e[r],t=r,r=2*t+1;return e[t]=o,v(e,l,t,n)},n=function(){function e(e){this.cmp=null!=e?e:s,this.nodes=[]}return e.push=c,e.pop=u,e.replace=f,e.pushpop=h,e.heapify=l,e.updateItem=y,e.nlargest=m,e.nsmallest=g,e.prototype.push=function(e){return c(this.nodes,e,this.cmp)},e.prototype.pop=function(){return u(this.nodes,this.cmp)},e.prototype.peek=function(){return this.nodes[0]},e.prototype.contains=function(e){return-1!==this.nodes.indexOf(e)},e.prototype.replace=function(e){return f(this.nodes,e,this.cmp)},e.prototype.pushpop=function(e){return h(this.nodes,e,this.cmp)},e.prototype.heapify=function(){return l(this.nodes,this.cmp)},e.prototype.updateItem=function(e){return y(this.nodes,e,this.cmp)},e.prototype.clear=function(){return this.nodes=[]},e.prototype.empty=function(){return 0===this.nodes.length},e.prototype.size=function(){return this.nodes.length},e.prototype.clone=function(){var t;return t=new e,t.nodes=this.nodes.slice(0),t},e.prototype.toArray=function(){return this.nodes.slice(0)},e.prototype.insert=e.prototype.push,e.prototype.top=e.prototype.peek,e.prototype.front=e.prototype.peek,e.prototype.has=e.prototype.contains,e.prototype.copy=e.prototype.clone,e}(),_=this,w=function(){return n},i=[],r=w,o="function"==typeof r?r.apply(t,i):r,void 0===o||(e.exports=o)}).call(this)},function(e,t,n){"use strict";const r=n(38),i=n(106);class o{constructor(e,t,n,r){this.dht=e,this.run=t,this.path=n,this.log=r,this.concurrency=this.dht.concurrency,this.queue=this.setupQueue()}setupQueue(){const e=i(this.processNext.bind(this),this.concurrency);return e.error=(e=>{this.log.error("queue",e),this.stop(e)}),e.drain=(()=>{this.log("queue:drain"),this.stop()}),e.unsaturated=(()=>{this.running&&this.fill()}),e.buffer=0,e}stop(e){this.running&&(this.running=!1,this.queue.kill(),this.log("worker:stop, %d workers still running",this.run.workers.filter(e=>e.running).length),this.callbackFn(e))}execute(e){this.running=!0,this.callbackFn=e,this.fill()}fill(){for(;this.queue.running()+this.queue.length()<this.concurrency&&this.path.peersToQuery.length>0;)this.queue.push(this.path.peersToQuery.dequeue())}processNext(e,t){return this.running?this.run.peersSeen.has(e)?t():void this.run.continueQuerying(this,(n,r)=>this.running?n?t(n):r?this.run.peersSeen.has(e)?t():(this.run.peersSeen.add(e),this.log("queue:work"),void this.execQuery(e,(e,n)=>this.running?(this.log("queue:work:done",e,n),e?t(e):n&&n.queryComplete?(this.log("query:complete"),this.run.stop(),t()):n&&n.pathComplete?(this.stop(),t()):void t()):t())):(this.stop(),t()):t()):t()}execQuery(e,t){this.path.queryFunc(e,(n,i)=>this.running?n?(this.run.errors.push(n),t()):void this.run.peersQueried.add(e,e=>e?t(e):i.pathComplete||i.queryComplete?(this.path.res=i,t(null,{pathComplete:i.pathComplete,queryComplete:i.queryComplete})):i.closerPeers&&i.closerPeers.length>0?r(i.closerPeers,(e,t)=>{if(this.dht._isSelf(e.id))return t();e=this.dht.peerBook.put(e),this.dht._peerDiscovered(e),this.path.addPeerToQuery(e.id,t)},t):void t()):t())}}e.exports=o},function(e,t,n){"use strict";const r=n(19),i=n(159),o=n(52),s=n(20),a=n(13),l=n(1012),u=n(127),c=n(90),h=n(44);class f{constructor(e){this.dht=e,this.readMessageTimeout=u.READ_MESSAGE_TIMEOUT,this._log=h.logger(this.dht.peerInfo.id,"net"),this._rpc=l(this.dht),this._onPeerConnected=this._onPeerConnected.bind(this),this._running=!1}start(e){const t=t=>s(()=>e(t));return this._running?t(a(new Error("Network is already running"),"ERR_NETWORK_ALREADY_RUNNING")):this.dht.isStarted?(this._running=!0,this.dht.switch.handle(u.PROTOCOL_DHT,this._rpc),this.dht.switch.on("peer-mux-established",this._onPeerConnected),void t()):t(a(new Error("Can not start network"),"ERR_CANNOT_START_NETWORK"))}stop(e){const t=t=>s(()=>e(t));if(!this.dht.isStarted&&!this.isStarted)return t(a(new Error("Network is already stopped"),"ERR_NETWORK_ALREADY_STOPPED"));this._running=!1,this.dht.switch.removeListener("peer-mux-established",this._onPeerConnected),this.dht.switch.unhandle(u.PROTOCOL_DHT),t()}get isStarted(){return this._running}get isConnected(){return this.dht.isStarted&&this.isStarted}_onPeerConnected(e){if(!this.isConnected)return this._log.error("Network is offline");this.dht.switch.dial(e,u.PROTOCOL_DHT,(t,n)=>{if(t)return this._log("%s does not support protocol: %s",e.id.toB58String(),u.PROTOCOL_DHT);r(r.empty(),n),this.dht._add(e,t=>{if(t)return this._log.error("Failed to add to the routing table",t);this._log("added to the routing table: %s",e.id.toB58String())})})}sendRequest(e,t,n){if(!this.isConnected)return n(a(new Error("Network is offline"),"ERR_NETWORK_OFFLINE"));this._log("sending to: %s",e.toB58String()),this.dht.switch.dial(e,u.PROTOCOL_DHT,(e,r)=>{if(e)return n(e);this._writeReadMessage(r,t.serialize(),n)})}sendMessage(e,t,n){if(!this.isConnected)return s(()=>n(a(new Error("Network is offline"),"ERR_NETWORK_OFFLINE")));this._log("sending to: %s",e.toB58String()),this.dht.switch.dial(e,u.PROTOCOL_DHT,(e,r)=>{if(e)return n(e);this._writeMessage(r,t.serialize(),n)})}_writeReadMessage(e,t,n){i(p,this.readMessageTimeout)(e,t,n)}_writeMessage(e,t,n){r(r.values([t]),o.encode(),e,r.onEnd(n))}}function p(e,t,n){r(r.values([t]),o.encode(),e,r.filter(e=>e.length<u.maxMessageSize),o.decode(),r.collect((e,t)=>{if(e)return n(e);if(0===t.length)return n(a(new Error("No message received"),"ERR_NO_MESSAGE_RECEIVED"));let r;try{r=c.deserialize(t[0])}catch(e){return n(a(e,"ERR_FAILED_DESERIALIZE_RESPONSE"))}n(null,r)}))}e.exports=f},function(e,t,n){"use strict";const r=n(19),i=n(52),o=n(90),s=n(1014),a=n(44),l=n(127);e.exports=(e=>{const t=a.logger(e.peerInfo.id,"rpc"),n=s(e);function u(r,i,o){e._add(r,e=>{e&&(t.error("Failed to update the kbucket store"),t.error(e));const s=n(i.type);if(!s)return t.error(`no handler found for message type: ${i.type}`),o();s(r,i,o)})}return function e(n,s){s.getPeerInfo((e,n)=>{if(e)return t.error("Failed to get peer info"),void t.error(e);t("from: %s",n.id.toB58String()),r(s,i.decode(),r.filter(e=>e.length<l.maxMessageSize),r.map(e=>{let n;try{n=o.deserialize(e)}catch(e){return void t.error("failed to read incoming message",e)}return n}),r.filter(Boolean),r.asyncMap((e,t)=>u(n,e,t)),r.filter(Boolean),r.map(e=>{let n;try{n=e.serialize()}catch(e){return void t.error("failed to send message",e)}return n}),r.filter(Boolean),i.encode(),s)})}})},function(e,t,n){"use strict";e.exports='// can\'t use, because protocol-buffers doesn\'t support imports\n// so we have to duplicate for now :(\n// import "record.proto";\n\nmessage Record {\n // adjusted for javascript\n optional bytes key = 1;\n optional bytes value = 2;\n optional bytes author = 3;\n optional bytes signature = 4;\n optional string timeReceived = 5;\n}\n\nmessage Message {\n enum MessageType {\n PUT_VALUE = 0;\n GET_VALUE = 1;\n ADD_PROVIDER = 2;\n GET_PROVIDERS = 3;\n FIND_NODE = 4;\n PING = 5;\n }\n\n enum ConnectionType {\n // sender does not have a connection to peer, and no extra information (default)\n NOT_CONNECTED = 0;\n\n // sender has a live connection to peer\n CONNECTED = 1;\n\n // sender recently connected to peer\n CAN_CONNECT = 2;\n\n // sender recently tried to connect to peer repeatedly but failed to connect\n // ("try" here is loose, but this should signal "made strong effort, failed")\n CANNOT_CONNECT = 3;\n }\n\n message Peer {\n // ID of a given peer.\n optional bytes id = 1;\n\n // multiaddrs for a given peer\n repeated bytes addrs = 2;\n\n // used to signal the sender\'s connection capabilities to the peer\n optional ConnectionType connection = 3;\n }\n\n // defines what type of message it is.\n optional MessageType type = 1;\n\n // defines what coral cluster level this query/response belongs to.\n // in case we want to implement coral\'s cluster rings in the future.\n optional int32 clusterLevelRaw = 10;\n\n // Used to specify the key associated with this message.\n // PUT_VALUE, GET_VALUE, ADD_PROVIDER, GET_PROVIDERS\n // adjusted for javascript\n optional bytes key = 2;\n\n // Used to return a value\n // PUT_VALUE, GET_VALUE\n // adjusted Record to bytes for js\n optional bytes record = 3;\n\n // Used to return peers closer to a key in a query\n // GET_VALUE, GET_PROVIDERS, FIND_NODE\n repeated Peer closerPeers = 8;\n\n // Used to return Providers\n // GET_VALUE, ADD_PROVIDER, GET_PROVIDERS\n repeated Peer providerPeers = 9;\n}'},function(e,t,n){"use strict";const r=n(90).TYPES;e.exports=(e=>{const t={[r.GET_VALUE]:n(1015)(e),[r.PUT_VALUE]:n(1016)(e),[r.FIND_NODE]:n(1017)(e),[r.ADD_PROVIDER]:n(1018)(e),[r.GET_PROVIDERS]:n(1020)(e),[r.PING]:n(1021)(e)};return function e(n){return t[n]}})},function(e,t,n){"use strict";const r=n(36),i=n(123).Record,o=n(13),s=n(90),a=n(44);e.exports=(e=>{const t=a.logger(e.peerInfo.id,"rpc:get-value");return function n(l,u,c){const h=u.key;if(t("key: %b",h),!h||0===h.length)return c(o(new Error("Invalid key"),"ERR_INVALID_KEY"));const f=new s(s.TYPES.GET_VALUE,h,u.clusterLevel);if(a.isPublicKeyKey(h)){t("is public key");const n=a.fromPublicKeyKey(h);let r;if(e._isSelf(n)?r=e.peerInfo:e.peerBook.has(n)&&(r=e.peerBook.get(n)),r&&r.id.pubKey)return t("returning found public key"),f.record=new i(h,r.id.pubKey.bytes),c(null,f)}r([t=>e._checkLocalDatastore(h,t),t=>e._betterPeersToQuery(u,l,t)],(e,n)=>{if(e)return c(e);const r=n[0],i=n[1];r&&(t("got record"),f.record=r),i.length>0&&(t("got closer %s",i.length),f.closerPeers=i),c(null,f)})}})},function(e,t,n){"use strict";const r=n(44),i=n(13);e.exports=(e=>{const t=r.logger(e.peerInfo.id,"rpc:put-value");return function n(o,s,a){const l=s.key;t("key: %b",l);const u=s.record;if(!u){const e=`Empty record from: ${o.id.toB58String()}`;return t.error(e),a(i(new Error(e),"ERR_EMPTY_RECORD"))}e._verifyRecordLocally(u,n=>{if(n)return t.error(n.message),a(n);u.timeReceived=new Date;const i=r.bufferToKey(u.key);e.datastore.put(i,u.serialize(),e=>{if(e)return a(e);a(null,s)})})}})},function(e,t,n){"use strict";(function(t){const r=n(10),i=n(90),o=n(44);e.exports=(e=>{const n=o.logger(e.peerInfo.id,"rpc:find-node");return function o(s,a,l){n("start"),r([t=>{if(a.key.equals(e.peerInfo.id.id))return t(null,[e.peerInfo]);e._betterPeersToQuery(a,s,t)},(e,r)=>{const o=new i(a.type,t.alloc(0),a.clusterLevel);e.length>0?o.closerPeers=e:n("handle FindNode %s: could not find anything",s.id.toB58String()),r(null,o)}],l)}})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(272),i=n(44),o=n(13);e.exports=(e=>{const t=i.logger(e.peerInfo.id,"rpc:add-provider");return function n(i,s,a){if(t("start"),!s.key||0===s.key.length)return a(o(new Error("Missing key"),"ERR_MISSING_KEY"));let l;try{l=new r(s.key)}catch(e){const t=`Invalid CID: ${e.message}`;return a(o(new Error(t),"ERR_INVALID_CID"))}s.providerPeers.forEach(n=>{n.id.isEqual(i.id)?n.multiaddrs.size<1?t("no valid addresses for provider %s. Ignore",i.id.toB58String()):(t("received provider %s for %s (addrs %s)",i.id.toB58String(),l.toBaseEncodedString(),n.multiaddrs.toArray().map(e=>e.toString())),e._isSelf(n.id)||e.peerBook.put(n)):t("invalid provider peer %s from %s",n.id.toB58String(),i.id.toB58String())}),e.providers.addProvider(l,i.id,a)}})},function(e,t,n){"use strict";(function(t){const r=n(27);var i={checkCIDComponents:function(e){if(null==e)return"null values are not valid CIDs";if(0!==e.version&&1!==e.version)return"Invalid version, must be a number equal to 1 or 0";if("string"!=typeof e.codec)return"codec must be string";if(0===e.version){if("dag-pb"!==e.codec)return"codec must be 'dag-pb' for CIDv0";if("base58btc"!==e.multibaseName)return"multibaseName must be 'base58btc' for CIDv0"}if(!t.isBuffer(e.multihash))return"multihash must be a Buffer";try{r.validate(e.multihash)}catch(e){let t=e.message;return t||(t="Multihash validation failed"),t}}};e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(272),i=n(36),o=n(31),s=n(13),a=n(90),l=n(44);e.exports=(e=>{const t=l.logger(e.peerInfo.id,"rpc:get-providers");return function n(u,c,h){let f;try{f=new r(c.key)}catch(e){return h(s(new Error(`Invalid CID: ${e.message}`),"ERR_INVALID_CID"))}t("%s",f.toBaseEncodedString());const p=l.bufferToKey(f.buffer);i([n=>e.datastore.has(p,(e,r)=>{if(e)return t.error("Failed to check datastore existence",e),n(null,!1);n(null,r)}),t=>e.providers.getProviders(f,t),t=>e._betterPeersToQuery(c,u,t)],(n,r)=>{if(n)return h(n);const i=r[0],s=r[2],l=r[1].map(t=>e.peerBook.has(t)?e.peerBook.get(t):e.peerBook.put(new o(t)));i&&l.push(e.peerInfo);const u=new a(c.type,c.key,c.clusterLevel);l.length>0&&(u.providerPeers=l),s.length>0&&(u.closerPeers=s),t("got %s providers %s closerPeers",l.length,s.length),h(null,u)})}})},function(e,t,n){"use strict";const r=n(44);e.exports=(e=>{const t=r.logger(e.peerInfo.id,"rpc:ping");return function e(n,r,i){t("from %s",n.id.toB58String()),i(null,r)}})},function(e,t,n){"use strict";const r=n(15),i=n(123),o=n(10),s=n(38),a=n(159),l=n(31),u=n(13),c=n(44),h=n(90),f=n(127),p=n(465),d=n(1023),m=i.Record;e.exports=(e=>({_nearestPeersToQuery(t,n){c.convertBuffer(t.key,(t,r)=>{if(t)return n(t);let i;try{i=e.routingTable.closestPeers(r,e.kBucketSize)}catch(t){return n(t)}n(null,i.map(t=>e.peerBook.has(t)?e.peerBook.get(t):e.peerBook.put(new l(t))))})},_betterPeersToQuery(t,n,r){e._log("betterPeersToQuery"),e._nearestPeersToQuery(t,(t,i)=>{if(t)return r(t);const o=i.filter(t=>e._isSelf(t.id)?(e._log.error("trying to return self as closer"),!1):!t.id.isEqual(n.id));r(null,o)})},_checkLocalDatastore(t,n){e._log("checkLocalDatastore: %b",t);const r=c.bufferToKey(t);e.datastore.has(r,(t,i)=>t?n(t):i?void e.datastore.get(r,(t,i)=>{if(t)return n(t);const o=i;let s;try{s=m.deserialize(o)}catch(t){return n(t)}return s?null==s.timeReceived||c.now()-s.timeReceived>f.MAX_RECORD_AGE?e.datastore.delete(r,n):void n(null,s):n(u(new Error("Invalid record"),"ERR_INVALID_RECORD"))}):n())},_add(t,n){t=e.peerBook.put(t),e.routingTable.add(t.id,n)},_verifyRecordLocally(t,n){e._log("verifyRecordLocally"),i.validator.verifyRecord(e.validators,t,n)},_closerPeersSingle(t,n,i){e._log("_closerPeersSingle %b from %s",t,n.toB58String()),e._findPeerSingle(n,new r(t),(t,n)=>{if(t)return i(t);const r=n.closerPeers.filter(t=>!e._isSelf(t.id));i(null,r)})},_isSelf:t=>t&&e.peerInfo.id.id.equals(t.id),_findPeerSingle(t,n,r){e._log("_findPeerSingle %s",t.toB58String());const i=new h(h.TYPES.FIND_NODE,n.id,0);e.network.sendRequest(t,i,r)},_putValueToPeer(t,n,r,i){const o=new h(h.TYPES.PUT_VALUE,t,0);o.record=n,e.network.sendRequest(r,o,(e,t)=>e?i(e):t.record.value.equals(m.deserialize(n).value)?void i():i(u(new Error("value not put correctly"),"ERR_PUT_VALUE_INVALID")))},_putLocal(t,n,r){e.datastore.put(c.bufferToKey(t),n,r)},_get(t,n,r){e._log("_get %b",t),o([r=>e.getMany(t,f.GET_MANY_RECORD_COUNT,n,r),(n,r)=>{const a=n.map(e=>e.val);let l=0;try{l=i.selection.bestRecord(e.selectors,t,a)}catch(e){if("ERR_NO_SELECTOR_FUNCTION_FOR_RECORD_KEY"!==e.code)return r(e)}const h=a[l];if(e._log("GetValue %b %s",t,h),!h)return r(u(new Error("best value was not found"),"ERR_NOT_FOUND"));o([e=>c.createPutRecord(t,h,e),(r,i)=>s(n,(n,i)=>n.val.equals(h)?i():e._isSelf(n.from)?e._putLocal(t,r,t=>{t&&e._log.error("Failed error correcting self",t),i()}):void e._putValueToPeer(t,r,n.from,t=>{t&&e._log.error("Failed error correcting entry",t),i()}),i)],e=>r(e,e?null:h))}],r)},_getLocal(t,n){e._log("getLocal %b",t),o([n=>e.datastore.get(c.bufferToKey(t),n),(n,r)=>{let i;e._log("found %b in local datastore",t);try{i=m.deserialize(n)}catch(e){return r(e)}e._verifyRecordLocally(i,e=>{if(e)return r(e);r(null,i)})}],n)},_getValueOrPeers(t,n,r){o([r=>e._getValueSingle(t,n,r),(t,n)=>{const r=t.closerPeers,i=t.record;return i?e._verifyRecordOnline(i,t=>{if(t){const t="invalid record received, discarded";return e._log(t),n(u(new Error(t),"ERR_INVALID_RECORD"))}return n(null,i,r)}):r.length>0?n(null,null,r):void n(u(new Error("Not found"),"ERR_NOT_FOUND"))}],r)},_getValueSingle(t,n,r){const i=new h(h.TYPES.GET_VALUE,n,0);e.network.sendRequest(t,i,r)},_verifyRecordOnline(t,n){i.validator.verifyRecord(e.validators,t,n)},_getPublicKeyFromNode(t,n){const i=c.keyForPublicKey(t);o([n=>e._getValueSingle(t,i,n),(e,n)=>{if(!e.record||!e.record.value)return n(u(new Error(`Node not responding with its public key: ${t.toB58String()}`),"ERR_INVALID_RECORD"));r.createFromPubKey(e.record.value,n)},(e,n)=>{if(!e.isEqual(t))return n(u(new Error("public key does not match id"),"ERR_PUBLIC_KEY_DOES_NOT_MATCH_ID"));n(null,e.pubKey)}],n)},_findNProviders(t,n,r,i){let s=new d(r);e.providers.getProviders(t,(u,h)=>{if(u)return i(u);if(h.forEach(t=>{let n;n=e.peerBook.has(t)?e.peerBook.get(t):e.peerBook.put(new l(t)),s.push(n)}),s.length>=r)return i(null,s.toArray());const f=[],m=new p(e,t.buffer,(n,i)=>{const a=c.pathSize(s.length-r,i),l=new d(a);return f.push(l),(n,r)=>{o([r=>e._findProvidersSingle(n,t,r),(t,n)=>{const r=t.providerPeers;if(e._log("(%s) found %s provider entries",e.peerInfo.id.toB58String(),r.length),r.forEach(t=>{l.push(e.peerBook.put(t))}),l.length>=a)return n(null,{pathComplete:!0});n(null,{closerPeers:t.closerPeers})}],r)}}),g=e.routingTable.closestPeers(t.buffer,e.kBucketSize);a(e=>m.run(g,e),n)(e=>{if(m.stop(),f.forEach(e=>{e.toArray().forEach(e=>{s.push(e)})}),e)return"ETIMEDOUT"===e.code&&s.length>0?i(null,s.toArray()):i(e);i(null,s.toArray())})})},_findProvidersSingle(t,n,r){const i=new h(h.TYPES.GET_PROVIDERS,n.buffer,0);e.network.sendRequest(t,i,r)}}))},function(e,t,n){"use strict";const r=n(1024);class i extends r{constructor(e){super(),this.limit=e}push(e){return this.length<this.limit&&super.push(e)}}e.exports=i},function(e,t,n){"use strict";class r{constructor(){this.list=[]}push(e){return!this.has(e)&&(this.list.push(e),!0)}has(e){const t=this.list.find(t=>t.id.isEqual(e.id));return Boolean(t)}toArray(){return this.list.slice()}pop(){return this.list.pop()}get length(){return this.list.length}}e.exports=r},function(e,t,n){"use strict";(function(t){const r=n(466),i=n(35),o=n(38),s=n(19),a=n(272),l=n(15),u=n(28).Key,c=n(127),h=n(44);class f{constructor(e,t,n){this.datastore=e,this._log=h.logger(t,"providers"),this.cleanupInterval=c.PROVIDERS_CLEANUP_INTERVAL,this.provideValidity=c.PROVIDERS_VALIDITY,this.lruCacheSize=n||c.PROVIDERS_LRU_CACHE_SIZE,this.providers=r(this.lruCacheSize)}stop(){this._cleaner&&(clearInterval(this._cleaner),this._cleaner=null)}_cleanup(){this._getProviderCids((e,t)=>{if(e)return this._log.error("Failed to get cids",e);o(t,(e,t)=>{this._getProvidersMap(e,(n,r)=>n?t(n):(r.forEach((e,t)=>{this._log("comparing: %s - %s > %s",Date.now(),e,this.provideValidity),Date.now()-e>this.provideValidity&&r.delete(t)}),0===r.size?this._deleteProvidersMap(e,t):void t()))},e=>{if(e)return this._log.error("Failed to cleanup",e);this._log("Cleanup successfull")})})}_getProviderCids(e){s(this.datastore.query({prefix:c.PROVIDERS_KEY_PREFIX}),s.map(e=>{const t=e.key.toString().split("/");if(4!==t.length)return void this._log.error("incorrectly formatted provider entry in datastore: %s",e.key);let n,r;try{n=h.decodeBase32(t[2])}catch(e){return void this._log.error("error decoding base32 provider key: %s",t[2])}try{r=new a(n)}catch(e){this._log.error("error converting key to cid from datastore: %s",e.message)}return r}),s.filter(Boolean),s.collect(e))}_getProvidersMap(e,t){const n=this.providers.get(p(e));if(!n)return m(this.datastore,e,t);t(null,n)}_deleteProvidersMap(e,t){const n=p(e);this.providers.set(n,null);const r=this.datastore.batch();s(this.datastore.query({keysOnly:!0,prefix:n}),s.through(e=>r.delete(e.key)),s.onEnd(e=>{if(e)return t(e);r.commit(t)}))}get cleanupInterval(){return this._cleanupInterval}set cleanupInterval(e){this._cleanupInterval=e,this._cleaner&&clearInterval(this._cleaner),this._cleaner=setInterval(()=>this._cleanup(),this.cleanupInterval)}addProvider(e,t,n){this._log("addProvider %s",e.toBaseEncodedString());const r=p(e),i=this.providers.get(r),o=(i,o)=>{if(i)return n(i);this._log("loaded %s provs",o.size);const s=Date.now();o.set(t,s),this.providers.set(r,o),d(this.datastore,e,t,s,n)};i?o(null,i):m(this.datastore,e,o)}getProviders(e,t){this._log("getProviders %s",e.toBaseEncodedString()),this._getProvidersMap(e,(e,n)=>{if(e)return t(e);t(null,Array.from(n.keys()))})}}function p(e){return c.PROVIDERS_KEY_PREFIX+h.encodeBase32(e.buffer)}function d(e,n,r,o,s){const a=[p(n),"/",h.encodeBase32(r.id)].join("");e.put(new u(a),t.from(i.encode(o)),s)}function m(e,t,n){s(e.query({prefix:p(t)}),s.map(e=>{const t=e.key.toString().split("/"),n=t[t.length-1],r=h.decodeBase32(n);return[new l(r),g(e.value)]}),s.collect((e,t)=>e?n(e):n(null,new Map(t))))}function g(e){return i.decode(e)}e.exports=f}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(1027),i=n(51),o=n(10),s=n(56),a=n(15),l=n(24),u=n(127),{logger:c}=n(44),h=n(1030),f=n(13);class p{constructor(e,t){l(e,"Random Walk needs an instance of the Kademlia DHT"),this._options={...u.defaultRandomWalk,...t},this._kadDHT=e,this.log=c(e.peerInfo.id,"random-walk")}start(){!this._timeoutId&&this._options.enabled&&(this._timeoutId=setTimeout(()=>{this._runPeriodically(e=>{this._walk(this._options.queriesPerPeriod,this._options.timeout,()=>e(this._options.interval))},0)},this._options.delay))}stop(){clearTimeout(this._timeoutId),this._timeoutId=null,this._controller&&this._controller.abort()}_runPeriodically(e,t){this._timeoutId=setTimeout(()=>{e(t=>{this._runPeriodically(e,t)})},t)}_walk(e,t,n){this.log("start"),this._controller=new h,r(e,(e,n)=>{this.log("running query %d",e),o([e=>this._randomPeerId(e),(e,n)=>{if(!this._controller)return n();this._query(e,{timeout:t,signal:this._controller.signal},n)}],t=>{if(t&&"ETIMEDOUT"!==t.code)return this.log.error("query %d finished with error",e,t),n(t);this.log("finished query %d",e),n(null)})},e=>{this._controller=null,this.log("finished queries"),n(e)})}_query(e,t,n){this.log("query:%s",e.toB58String()),this._kadDHT.findPeer(e,t,(t,r)=>t&&"ERR_NOT_FOUND"===t.code?n():t?n(t):(this.log("query:found",r),void n(f(new Error(`random-walk: ACTUALLY FOUND PEER: ${r}, ${e.toB58String()}`),"ERR_FOUND_RANDOM_PEER"))))}_randomPeerId(e){s(i.randomBytes(16),"sha2-256",(t,n)=>{if(t)return e(t);e(null,new a(n))})}}e.exports=p},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1028),i=a(r),o=n(109),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default,1/0),e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(467),i=u(r),o=n(1029),s=u(o),a=n(37),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e,t,n,r){var o=(0,l.default)(n);(0,i.default)((0,s.default)(0,e,1),t,o,r)}e.exports=t.default},function(e,t){var n=Math.ceil,r=Math.max;function i(e,t,i,o){for(var s=-1,a=r(n((t-e)/(i||1)),0),l=Array(a);a--;)l[o?a:++s]=e,e+=i;return l}e.exports=i},function(e,t,n){"use strict";const{AbortController:r,AbortSignal:i}="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0;e.exports=r,e.exports.AbortSignal=i,e.exports.default=r},function(e,t,n){"use strict";class r{constructor(){this.queries=new Set,this.running=!1}queryStarted(e){this.queries.add(e)}queryCompleted(e){this.queries.delete(e)}start(){this.running=!0}stop(){this.running=!1;for(const e of this.queries)e.stop();this.queries.clear()}}e.exports=r},function(e,t,n){"use strict";(function(t){const r=n(160),i=n(6).EventEmitter,o=n(4),s=o("libp2p");s.error=o("libp2p:error");const a=n(13),l=n(38),u=n(43),c=n(36),h=n(47),f=n(400),p=n(31),d=n(1034),m=n(1064),g=n(440),y=n(1068),{emitFirst:v}=n(1099),b=n(1100),_=n(1101),w=n(1102),k=n(1103),E=n(1113),S=n(1114).validate,{codes:x}=n(289),C=(e,t)=>a(new Error(`libp2p cannot ${e} when not started; state is ${t}`),x.ERR_NODE_NOT_STARTED);class A extends i{constructor(e){if(super(),this._options=S(e),this.datastore=this._options.datastore,this.peerInfo=this._options.peerInfo,this.peerBook=this._options.peerBook||new f,this._modules=this._options.modules,this._config=this._options.config,this._transport=[],this._discovery=[],this._switch=new d(this.peerInfo,this.peerBook,this._options.switch),this._switch.on("error",(...e)=>this.emit("error",...e)),this.stats=this._switch.stats,this.connectionManager=new y(this,this._options.connectionManager),this._modules.streamMuxer){let e=this._modules.streamMuxer;e.forEach(e=>this._switch.connection.addStreamMuxer(e)),this._switch.connection.reuse(),this._switch.connection.enableCircuitRelay(this._config.relay),this._switch.on("peer-mux-established",e=>{this.emit("peer:connect",e)}),this._switch.on("peer-mux-closed",e=>{this.emit("peer:disconnect",e)})}if(this._switch.on("connection:start",e=>{this.emit("connection:start",e)}),this._switch.on("connection:end",e=>{this.emit("connection:end",e)}),this._modules.connEncryption){let e=this._modules.connEncryption;e.forEach(e=>{this._switch.connection.crypto(e.tag,e.encrypt)})}if(this._modules.connProtector)this._switch.protector=this._modules.connProtector;else if(t.env.LIBP2P_FORCE_PNET)throw new Error("Private network is enforced, but no protector was provided");if(this._config.dht.enabled){const e=this._modules.dht;this._dht=new e(this._switch,{datastore:this.datastore,...this._config.dht})}this._config.EXPERIMENTAL.pubsub&&(this.pubsub=k(this)),this.peerRouting=b(this),this.contentRouting=_(this),this.dht=w(this),this._getPeerInfo=E(this),m.mount(this._switch),this.state=new r("STOPPED",{STOPPED:{start:"STARTING",stop:"STOPPED"},STARTING:{done:"STARTED",abort:"STOPPED",stop:"STOPPING"},STARTED:{stop:"STOPPING",start:"STARTED"},STOPPING:{stop:"STOPPING",done:"STOPPED"}}),this.state.on("STARTING",()=>{s("libp2p is starting"),this._onStarting()}),this.state.on("STOPPING",()=>{s("libp2p is stopping"),this._onStopping()}),this.state.on("STARTED",()=>{s("libp2p has started"),this.emit("start")}),this.state.on("STOPPED",()=>{s("libp2p has stopped"),this.emit("stop")}),this.state.on("error",e=>{s.error(e),this.emit("error",e)}),this.state.on("STARTED",()=>{this.peerBook.getAllArray().forEach(e=>{this.emit("peer:discovery",e),this._maybeConnect(e)})}),this._peerDiscovered=this._peerDiscovered.bind(this)}emit(e,...t){"error"!==e||this._events.error?super.emit(e,...t):s.error(...t)}start(e=(()=>{})){v(this,["error","start"],e),this.state("start")}stop(e=(()=>{})){v(this,["error","stop"],e),this.state("stop")}isStarted(){return!!this.state&&"STARTED"===this.state._state}dial(e,t){this.dialProtocol(e,null,t)}dialProtocol(e,t,n){if(!this.isStarted())return n(C("dial",this.state._state));"function"==typeof t&&(n=t,t=void 0),this._getPeerInfo(e,(e,r)=>{if(e)return n(e);this._switch.dial(r,t,n)})}dialFSM(e,t,n){if(!this.isStarted())return n(C("dial",this.state._state));"function"==typeof t&&(n=t,t=void 0),this._getPeerInfo(e,(e,r)=>{if(e)return n(e);this._switch.dialFSM(r,t,n)})}hangUp(e,t){this._getPeerInfo(e,(e,n)=>{if(e)return t(e);this._switch.hangUp(n,t)})}ping(e,t){if(!this.isStarted())return t(C("ping",this.state._state));this._getPeerInfo(e,(e,n)=>{if(e)return t(e);t(null,new m(this._switch,n))})}handle(e,t,n){this._switch.handle(e,t,n)}unhandle(e){this._switch.unhandle(e)}_onStarting(){if(!this._modules.transport)return this.emit("error",new Error("no transports were present")),this.state("abort");let e;const t=[],n=[];this.peerInfo.multiaddrs.toArray().forEach(e=>{e.getPeerId()||(t.push(e),n.push(e.encapsulate("/p2p/"+this.peerInfo.id.toB58String())))}),this.peerInfo.multiaddrs.replace(t,n);const r=this.peerInfo.multiaddrs.toArray();this._modules.transport.forEach(t=>{let n;n="function"==typeof t?new t({libp2p:this}):t,n.filter(r).length>0?this._switch.transport.add(n.tag||n[Symbol.toStringTag],n):g.isWebSockets(n)&&(e=n),this._transport.push(n)}),u([e=>{this.connectionManager.start(),this._switch.start(e)},t=>{e&&this._switch.transport.add(e.tag||e.constructor.name,e);const n=this.peerInfo.multiaddrs.toArray();n.forEach(e=>{e.toString().match(/\/p2p-circuit($|\/)/)||this._transport.find(t=>t.filter(e).length>0)||this.peerInfo.multiaddrs.delete(e)}),t()},e=>{this._dht?this._dht.start(()=>{this._dht.on("peer",this._peerDiscovered),e()}):e()},e=>{if(this._floodSub)return this._floodSub.start(e);e()},e=>{this._modules.peerDiscovery?this._setupPeerDiscovery(e):e()}],e=>{if(e)return s.error(e),this.emit("error",e),this.state("stop");this.state("done")})}_onStopping(){u([e=>{c(this._discovery.map(e=>(e.removeListener("peer",this._peerDiscovered),t=>e.stop(e=>{s.error("an error occurred stopping the discovery service",e),t()}))),e)},e=>{if(this._floodSub)return this._floodSub.stop(e);e()},e=>{if(this._dht)return this._dht.removeListener("peer",this._peerDiscovered),this._dht.stop(e);e()},e=>{this.connectionManager.stop(),this._switch.stop(e)},e=>{this._switch.transport.removeAll(()=>e())}],e=>{e&&(s.error(e),this.emit("error",e)),this.state("done")})}_peerDiscovered(e){e.id.toB58String()!==this.peerInfo.id.toB58String()?(e=this.peerBook.put(e),this.isStarted()&&(this.emit("peer:discovery",e),this._maybeConnect(e))):s.error(new Error(x.ERR_DISCOVERED_SELF))}_maybeConnect(e){if(!0===this._config.peerDiscovery.autoDial&&!e.isConnected()){const t=this._options.connectionManager.minPeers||0;t>Object.keys(this._switch.connection.connections).length&&(s("connecting to discovered peer"),this._switch.dialer.connect(e,e=>{e&&s.error("could not connect to discovered peer",e)}))}}_setupPeerDiscovery(e){for(const e of this._modules.peerDiscovery){let t={enabled:!0};if(e.tag&&this._config.peerDiscovery&&this._config.peerDiscovery[e.tag]&&(t={...t,...this._config.peerDiscovery[e.tag]}),t.enabled){let n;n="function"==typeof e?new e(Object.assign({},t,{peerInfo:this.peerInfo})):e,n.on("peer",this._peerDiscovered),this._discovery.push(n)}}l(this._discovery,(e,t)=>{e.start(t)},e)}}e.exports=A,e.exports.createLibp2p=((e,t)=>{if(e.peerInfo)return h(t,null,new A(e));p.create((n,r)=>{if(n)return t(n);e.peerInfo=r,t(null,new A(e))})})}).call(this,n(3))},function(e,t){function n(e,t){for(var n in e){var r=e[n];t(r,n,e)}}function r(e){return Object.keys(e).sort()}function i(e,t){return~e.indexOf(t)}function o(e,t){return e.filter(function(e){return i(t,e)})}function s(e,t){return e.filter(function(e){return!i(t,e)})}function a(e,t){return e.filter(function(e){return!i(t,e)}).concat(t.filter(function(t){return!i(e,t)})).sort()}function l(e,t){if(e.length!=t.length)return!1;for(var n in e)if(t[n]!==e[n])return!1}function u(e){for(var t in e)return!1;return!0}var c=t.validate=function(e){var t=Object.keys(e);return n(e,function(t,r){n(t,function(t,n){if(!e[t])throw new Error("invalid transition from state:"+r+" to state:"+t+" on event:"+n)})}),!0},h=t.reachable=function(e){var t={},r=!1;do{r=!1,n(e,function(e,i){var o=t[i]=t[i]||{};n(e,function(e,t){o[e]||(o[e]=[t],r=!0)}),n(e,function(e,i){var s=t[e];n(s,function(e,t){o[t]||(o[t]=[i].concat(e),r=!0)})})})}while(r);return t};t.terminal=t.deadlock=function(e){var t=[];return n(e,function(e,n){u(e)&&t.push(n)}),t};var f=t.livelock=function(e,t){var r=h(e),o=[];return n(r,function(e,r){i(t,r)||n(t,function(t){e[t]||i(o,r)||o.push(r)})}),o.sort()};function p(e){var t=[];return n(e,function(e,r){n(e,function(e,n){i(t,n)||t.push(n)})}),t.sort()}var d=t.combine=function(e,t,n,i){var s={},l=p(e),u=p(t),c=a(l,u);function h(n,i){var a=n+"-"+i,l;s[a]||(s[a]={}),l=s[a];var u=r(e[n]),f=r(t[i]),p=o(u,f);return p.forEach(function(r){l[r]=e[n][r]+"-"+t[i][r],s[l[r]]||h(e[n][r],t[i][r])}),o(c,u).forEach(function(t){l[t]=e[n][t]+"-"+i,s[l[t]]||h(e[n][t],i)}),o(c,f).forEach(function(e){l[e]=n+"-"+t[i][e],s[l[e]]||h(n,t[i][e])}),s[a]}return h(n,i),s}},function(e,t,n){"use strict";const r=n(160),i=n(6).EventEmitter,o=n(38),s=n(122),a=n(43),l=n(274),u=n(1040),c=n(1045),h=n(474),f=n(1053),p=n(1057),d=n(1059),m=n(473),g=n(1060),y=n(1061),v=n(24),b=n(217),_=n(4),w=_("libp2p:switch");w.error=_("libp2p:switch:error");class k extends i{constructor(e,t,n){super(),v(e,"You must provide a `peerInfo`"),v(t,"You must provide a `peerBook`"),this._peerInfo=e,this._peerBook=t,this._options=n||{},this.setMaxListeners(1/0),this.transports={},this.conns={},this.protocols={},this.muxers={},this.identify=!1,this.crypto=m,this.protector=this._options.protector||null,this.transport=new u(this),this.connection=new c(this),this.observer=g(this),this.stats=y(this.observer,this._options.stats),this.protocolMuxer=d(this.protocols,this.observer),this._connectionHandler=p(this),this.state=new r("STOPPED",{STOPPED:{start:"STARTING",stop:"STOPPING"},STARTING:{done:"STARTED",stop:"STOPPING"},STARTED:{stop:"STOPPING",start:"STARTED"},STOPPING:{stop:"STOPPING",done:"STOPPED"}}),this.state.on("STARTING",()=>{w("The switch is starting"),this._onStarting()}),this.state.on("STOPPING",()=>{w("The switch is stopping"),this._onStopping()}),this.state.on("STARTED",()=>{w("The switch has started"),this.emit("start")}),this.state.on("STOPPED",()=>{w("The switch has stopped"),this.emit("stop")}),this.state.on("error",e=>{w.error(e),this.emit("error",e)}),this.dialer=f(this),this.dial=this.dialer.dial,this.dialFSM=this.dialer.dialFSM}availableTransports(e){const t=e.multiaddrs.toArray(),n=Object.keys(this.transports);return n.filter(e=>this.transports[e].filter(t).length>0).sort((e,t)=>e===l.tag?1:t===l.tag?-1:e<t?-1:1)}handle(e,t,n){this.protocols[e]={handlerFunc:t,matchFunc:n},this._peerInfo.protocols.add(e)}unhandle(e){this.protocols[e]&&delete this.protocols[e],this._peerInfo.protocols.delete(e)}hangUp(e,t){const n=h(e,this._peerBook),r=n.id.toB58String(),i=[...this.connection.getAllById(r)];o(i,(e,t)=>{e.once("close",t),e.close()},t)}hasTransports(){const e=Object.keys(this.transports).filter(e=>e!==l.tag);return e&&e.length>0}start(e=(()=>{})){this.once("start",e),this.state("start")}stop(e=(()=>{})){this.once("stop",e),this.state("stop")}_onStarting(){this.stats.start(),s(this.availableTransports(this._peerInfo),(e,t)=>{this.transport.listen(e,{},null,t)},e=>{if(e)return w.error(e),this.emit("error",e),this.state("stop");this.state("done")})}_onStopping(){this.stats.stop(),a([e=>{o(this.transports,(e,t)=>{o(e.listeners,(e,t)=>{e.close(e=>{e&&w.error(e),t()})},t)},e)},e=>o(this.connection.getAll(),(e,t)=>{e.once("close",t),e.close()},e)],e=>{this.state("done")})}}e.exports=k,e.exports.errors=b},function(e,t,n){"use strict";const r=n(72),i=n(22),o=n(1036),s=n(161),a=n(4),l=a("libp2p:circuit:transportdialer");l.err=a("libp2p:circuit:error:transportdialer");const u=n(1037);class c{static get tag(){return"Circuit"}constructor(e,t){this.options=t||{},this.swarm=e,this.dialer=null,this.utils=s(e),this.peerInfo=this.swarm._peerInfo,this.relays=this.filter(this.peerInfo.multiaddrs.toArray()),0===this.relays.length&&this.peerInfo.multiaddrs.add(`/p2p-circuit/ipfs/${this.peerInfo.id.toB58String()}`),this.dialer=new o(e,t),this.swarm.on("peer-mux-established",e=>{this.dialer.canHop(e)}),this.swarm.on("peer-mux-closed",e=>{this.dialer.relayPeers.delete(e.id.toB58String())})}_dialSwarmRelays(){this.relays.forEach(e=>{let t=e.toString().split("/p2p-circuit").filter(e=>e.length);t.forEach(e=>{const t=this.utils.peerInfoFromMa(i(e));this.dialer._dialRelay(t)})})}dial(e,t,n){return this.dialer.dial(e,t,n)}createListener(e,t){"function"==typeof e&&(t=e,e=this.options||{});const n=u(this.swarm,e,t);return n.on("listen",this._dialSwarmRelays.bind(this)),n}filter(e){return Array.isArray(e)||(e=[e]),e.filter(e=>r.Circuit.matches(e))}}e.exports=c},function(e,t,n){"use strict";const r=n(26),i=n(15),o=n(10),s=n(20),a=n(22),l=n(64).Connection,u=n(161),c=n(275),h=n(4),f=h("libp2p:circuit:dialer");f.err=h("libp2p:circuit:error:dialer");const p=n(276),d=n(162);class m{constructor(e,t){this.swarm=e,this.relayPeers=new Map,this.relayConns=new Map,this.options=t,this.utils=u(e)}_dialRelayHelper(e,t){return this.relayConns.has(e.id.toB58String())?t(null,this.relayConns.get(e.id.toB58String())):this._dialRelay(e,t)}dial(e,t){t=t||(()=>{});const n=e.toString();if(!n.includes("/p2p-circuit"))return f.err("invalid circuit address"),t(new Error("invalid circuit address"));const r=n.split("p2p-circuit"),i="/"===r[0]?null:a(r[0]),o=a(r[1]||r[0]),u=new l;return s(this._dialPeer.bind(this),o,i,(e,n)=>{if(e)return f.err(e),t(e);u.setInnerConn(n),t(null,u)}),u}canHop(e,t){t=r(t||(()=>{})),this._dialRelayHelper(e,(n,r)=>{if(n)return t(n);const i=new c(r);o([e=>i.write(d.CircuitRelay.encode({type:d.CircuitRelay.Type.CAN_HOP}),e),e=>i.read(e)],(n,r)=>{if(n)return t(n);const o=d.CircuitRelay.decode(r);if(o.code!==d.CircuitRelay.Status.SUCCESS){const n=new Error(`HOP not supported, skipping - ${this.utils.getB58String(e)}`);return f(n),t(n)}f("HOP supported adding as relay - %s",this.utils.getB58String(e)),this.relayPeers.set(this.utils.getB58String(e),e),i.close(),t()})})}_dialPeer(e,t,n){if("function"==typeof t&&(n=t,t=null),n||(n=(()=>{})),e=a(e),t)return this._negotiateRelay(t,e,(e,t)=>e?(f.err("An error has occurred negotiating the relay connection",e),n(e)):n(null,t));{const t=Array.from(this.relayPeers.values());let r=i=>{if(!i){let e="no relay peers were found or all relays failed to dial";return f.err(e),n(e)}return this._negotiateRelay(i,e,(e,i)=>{if(e)return f.err(e),r(t.shift());n(null,i)})};r(t.shift())}}_negotiateRelay(e,t,n){t=a(t),e=this.utils.peerInfoFromMa(e);const r=this.swarm._peerInfo.multiaddrs.toArray();this._dialRelayHelper(e,(e,s)=>{if(e)return f.err(e),n(e);let a=new c(s);o([e=>{let n;f("negotiating relay for peer %s",t.getPeerId());try{n=i.createFromB58String(t.getPeerId()).id}catch(t){return e(t)}a.write(d.CircuitRelay.encode({type:d.CircuitRelay.Type.HOP,srcPeer:{id:this.swarm._peerInfo.id.id,addrs:r.map(e=>e.buffer)},dstPeer:{id:n,addrs:[t.buffer]}}),e)},e=>a.read(e)],(e,t)=>{if(e)return n(e);const r=d.CircuitRelay.decode(t);return r.type!==d.CircuitRelay.Type.STATUS?n(new Error("Got invalid message type - "+`expected ${d.CircuitRelay.Type.STATUS} got ${r.type}`)):r.code!==d.CircuitRelay.Status.SUCCESS?n(new Error(`Got ${r.code} error code trying to dial over relay`)):void n(null,new l(a.rest()))})})}_dialRelay(e,t){t=r(t||(()=>{})),this.swarm.dial(e,p.relay,r((e,n)=>{if(e)return f.err(e),t(e);t(null,n)}))}}e.exports=m},function(e,t,n){"use strict";const r=n(20),i=n(276),o=n(6).EventEmitter,s=n(22),a=n(72),l=n(1038),u=n(1039),c=n(162),h=n(161),f=n(275),p=n(4),d=p("libp2p:circuit:listener");d.err=p("libp2p:circuit:error:listener"),e.exports=((e,t,n)=>{const p=new o,m=h(e);return p.stopHandler=new l(e),p.stopHandler.on("connection",e=>p.emit("connection",e)),p.hopHandler=new u(e,t.hop),p.listen=((t,o)=>{o=o||(()=>{}),e.handle(i.relay,(e,t)=>{const r=new f(t);r.read((e,t)=>{if(e)return void d.err(e);let i=null;try{i=c.CircuitRelay.decode(t)}catch(e){return m.writeResponse(r,c.CircuitRelay.Status.MALFORMED_MESSAGE)}switch(i.type){case c.CircuitRelay.Type.CAN_HOP:case c.CircuitRelay.Type.HOP:return p.hopHandler.handle(i,r);case c.CircuitRelay.Type.STOP:return p.stopHandler.handle(i,r,n);default:return m.writeResponse(r,c.CircuitRelay.Status.INVALID_MSG_TYPE),r.close()}})}),r(()=>p.emit("listen")),o()}),p.close=(t=>{e.unhandle(i.relay),r(()=>p.emit("close")),t()}),p.getAddrs=(t=>{let n=e._peerInfo.multiaddrs.toArray(),r=n.filter(t=>a.Circuit.matches(t)&&!t.toString().includes(e._peerInfo.id.toB58String()));r.length&&(n=r);let i=[];n.forEach(t=>{const n=`/p2p-circuit/ipfs/${e._peerInfo.id.toB58String()}`;if(t.toString()!==n)if(a.Circuit.matches(t))i.push(t.encapsulate(`/ipfs/${e._peerInfo.id.toB58String()}`));else if(t.getPeerId())i.push(s("/p2p-circuit").encapsulate(t));else{const n=`${t}/ipfs/${e._peerInfo.id.toB58String()}`;i.push(s("/p2p-circuit").encapsulate(n))}else i.push(s(n))}),t(null,i)}),p})},function(e,t,n){"use strict";const r=n(20),i=n(6).EventEmitter,o=n(64).Connection,s=n(161),a=n(31),l=n(162).CircuitRelay,u=n(43),c=n(4),h=c("libp2p:circuit:stop");h.err=c("libp2p:circuit:error:stop");class f extends i{constructor(e){super(),this.swarm=e,this.utils=s(e)}handle(e,t,n){n=n||(()=>{}),u([n=>this.utils.validateAddrs(e,t,l.Type.STOP,n),e=>this.utils.writeResponse(t,l.Status.Success,e)],i=>{if(i)return n(),h(i);const s=new a(this.utils.peerIdFromId(e.srcPeer.id));e.srcPeer.addrs.forEach(e=>s.multiaddrs.add(e));const l=new o(t.rest());l.setPeerInfo(s),r(()=>this.emit("connection",l)),n(l)})}}e.exports=f},function(e,t,n){"use strict";const r=n(12),i=n(4),o=n(31),s=n(15),a=n(6).EventEmitter,l=n(26),u=n(161),c=n(275),h=n(162).CircuitRelay,f=n(22),p=n(43),d=n(10),m=n(20),g=n(276),y=i("libp2p:circuit:relay");y.err=i("libp2p:circuit:error:relay");class v extends a{constructor(e,t){super(),this.swarm=e,this.peerInfo=this.swarm._peerInfo,this.utils=u(e),this.config=t||{active:!1,enabled:!1},this.active=this.config.active}handle(e,t){if(!this.config.enabled)return this.utils.writeResponse(t,h.Status.HOP_CANT_SPEAK_RELAY),t.close();if(e.type===h.Type.CAN_HOP)return this.utils.writeResponse(t,h.Status.SUCCESS),t.close();let n=null,r=null;try{n=s.createFromBytes(e.srcPeer.id).toB58String(),r=s.createFromBytes(e.dstPeer.id).toB58String()}catch(e){if(y.err(e),!n)return this.utils.writeResponse(t,h.Status.HOP_SRC_MULTIADDR_INVALID),t.close();if(!r)return this.utils.writeResponse(t,h.Status.HOP_DST_MULTIADDR_INVALID),t.close()}if(n===r)return this.utils.writeResponse(t,h.Status.HOP_CANT_RELAY_TO_SELF),t.close();if(!e.dstPeer.addrs.length){const t=f(`/p2p-circuit/ipfs/${r}`).buffer;e.dstPeer.addrs.push(t)}y("trying to establish a circuit: %s <-> %s",n,r);const i=()=>(this.utils.writeResponse(t,h.Status.HOP_NO_CONN_TO_DST),t.close()),o=e=>{let t;try{if(t=this.swarm._peerBook.get(r),!t.isConnected()&&!this.active){const t=new Error(`No Connection to peer ${r}`);return i(t),e(t)}}catch(t){if(!this.active)return i(t),e(t)}e()};p([n=>this.utils.validateAddrs(e,t,h.Type.HOP,n),e=>o(e),n=>this._circuit(t,e,n)],e=>{if(e)return y.err(e),t.close(),m(()=>this.emit("circuit:error",e));m(()=>this.emit("circuit:success"))})}_connectToStop(e,t,n){this._dialPeer(e,(e,r)=>e?(this.utils.writeResponse(t,h.Status.HOP_CANT_DIAL_DST),y.err(e),n(e)):this.utils.writeResponse(t,h.Status.SUCCESS,e=>e?(y.err(e),n(e)):n(null,r)))}_negotiateStop(e,t,n,r){const i=Object.assign({},n,{type:h.Type.STOP});e.write(h.encode(i),n=>{if(n)return this.utils.writeResponse(t,h.Status.HOP_CANT_OPEN_DST_STREAM),y.err(n),r(n);e.read((e,t)=>{if(e)return y.err(e),r(e);const n=h.decode(t);return n.code!==h.Status.SUCCESS?r(new Error("Unable to create circuit!")):r(null,t)})})}_circuit(e,t,n){let i=null;d([n=>this._connectToStop(t.dstPeer,e,n),(n,r)=>{i=new c(n),this._negotiateStop(i,e,t,r)}],o=>{if(o)return e&&e.close(),i&&i.close(),n(o);const a=e.rest(),l=i.rest(),u=s.createFromBytes(t.srcPeer.id).toB58String(),c=s.createFromBytes(t.dstPeer.id).toB58String();r(a,l,a),y("circuit %s <-> %s established",u,c),n()})}_dialPeer(e,t){const n=new o(s.createFromBytes(e.id));e.addrs.forEach(e=>n.multiaddrs.add(e)),this.swarm.dial(n,g.relay,l((e,n)=>{if(e)return y.err(e),t(e);t(null,n)}))}}e.exports=v},function(e,t,n){"use strict";const r=n(36),i=n(26),o=n(4),s=o("libp2p:switch:transport"),a=n(1041),{DIAL_TIMEOUT:l}=n(278),{uniqueBy:u}=n(279),c=8;class h{constructor(e){this.switch=e,this.dialer=new a(c,this.switch._options.dialTimeout||l)}add(e,t){if(s("adding %s",e),this.switch.transports[e])throw new Error("There is already a transport with this key");this.switch.transports[e]=t,this.switch.transports[e].listeners||(this.switch.transports[e].listeners=[])}remove(e,t){if(t=t||function(){},!this.switch.transports[e])return t();this.close(e,n=>{delete this.switch.transports[e],t(n)})}removeAll(e){const t=Object.keys(this.switch.transports).map(e=>t=>{this.remove(e,t)});r(t,e)}dial(e,t,n){const r=this.switch.transports[e];let i=t.multiaddrs.toArray();Array.isArray(i)||(i=[i]),i=h.dialables(r,i,this.switch._peerInfo),s("dialing %s",e,i.map(e=>e.toString())),this.dialer.dialMany(t.id,r,i,(e,r)=>{if(e)return n(e);t.connect(r.multiaddr),n(null,r.conn)})}listen(e,t,n,o){n=this.switch._connectionHandler(e,n);const s=this.switch.transports[e];let a=this.switch._peerInfo.multiaddrs.toArray();a=u(a,e=>{const t=Number(e.toOptions().port);return isNaN(t)||0===t?e.toString():t});const l=h.dialables(s,a);s.listeners||(s.listeners=[]);let c=[];const f=l.map(e=>t=>{const r=i(t),o=s.createListener(n);o.once("error",r),o.listen(e,e=>{if(e)return r(e);o.removeListener("error",r),o.getAddrs((e,t)=>{if(e)return r(e);c=c.concat(t),s.listeners.push(o),r()})})});r(f,e=>{if(e)return o(e);this.switch._peerInfo.multiaddrs.replace(l,c),o()})}close(e,t){const n=this.switch.transports[e];if(!n)return t(new Error(`Trying to close non existing transport: ${e}`));r(n.listeners.map(e=>t=>{e.close(t)}),t)}static dialables(e,t,n){if(!e||!e.filter)return[];const r=e.filter(t);if(!n||!r.length)return r;const i=f(n),o=r.filter(e=>!i.some(t=>d(e).startsWith(t)));return o}}function f(e){const t=e.id.toB58String();return e.multiaddrs.toArray().reduce((e,n)=>{const r=n.getPeerId();n=n.toString();const i=r?n.slice(0,n.lastIndexOf(`/ipfs/${r}`)):`${n}/ipfs/${t}`;return e.concat([n,i])},[]).filter(e=>Boolean(e)).concat(`/ipfs/${t}`)}const p=["p2p-circuit","p2p-websocket-star","p2p-webrtc-star","p2p-stardust"];function d(e){const t=e.protoNames().reverse(),n=t.find(e=>p.includes(e));return e=e.toString(),n?e.slice(e.lastIndexOf(n)+n.length):e}e.exports=h},function(e,t,n){"use strict";const r=n(277),i=n(4),o=i("libp2p:switch:dialer"),s=n(1042);class a{constructor(e,t){o("create: %s peer limit, %s dial timeout",e,t),this.perPeerLimit=e,this.dialTimeout=t,this.queues=new Map}dialMany(e,t,n,i){o("dialMany:start");const s={cancel:!1};let a=[];const l=n.map(n=>r=>this.dialSingle(e,t,n,s,(e,t)=>e?(a.push(e),r(e)):r(null,t)));r(l,(e,t)=>{if(t&&t.conn)return o("dialMany:success"),i(null,t);o("dialMany:error"),i(a)})}dialSingle(e,t,n,r,i){const a=e.toB58String();let l;o("dialSingle: %s:%s",a,n.toString()),this.queues.has(a)?l=this.queues.get(a):(l=new s(this.perPeerLimit,this.dialTimeout),this.queues.set(a,l)),l.push(t,n,r,i)}}e.exports=a},function(e,t,n){"use strict";const r=n(64).Connection,i=n(12),o=n(88),s=n(159),a=n(106),l=n(4),u=n(26),c=l("libp2p:switch:dialer:queue");c.error=l("libp2p:switch:dialer:queue:error");class h{constructor(e,t){this.dialTimeout=t,this.queue=a((e,t)=>{this._doWork(e.transport,e.addr,e.token,t)},e)}_doWork(e,t,n,s){s=u(s),c("work:start"),this._dialWithTimeout(e,t,(a,l)=>{if(a)return c.error(`${e.constructor.name}:work`,a),s(a);if(n.cancel)return c("work:cancel"),i(o(),l),"function"==typeof l.close?l.close(e=>s(null)):s(null);n.cancel=!0,c("work:success");const u=new r;u.setInnerConn(l),s(null,{multiaddr:t,conn:l})})}_dialWithTimeout(e,t,n){s(n=>{const r=e.dial(t,e=>{if(e)return n(e);n(null,r)})},this.dialTimeout)(n)}push(e,t,n,r){this.queue.push({transport:e,addr:t,token:n},r)}}e.exports=h},function(e,t,n){"use strict";(function(t){const r=n(12),i=n(40),o=n(52),s=n(281);e.exports=((e,n)=>{e.getObservedAddrs((a,l)=>{if(a)return;l=l[0];let u=t.alloc(0);n.id.pubKey&&(u=n.id.pubKey.bytes);const c=s.encode({protocolVersion:"ipfs/0.1.0",agentVersion:"na",publicKey:u,listenAddrs:n.multiaddrs.toArray().map(e=>e.buffer),observedAddr:l?l.buffer:t.from(""),protocols:Array.from(n.protocols)});r(i([c]),o.encode(),e)})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(31),i=n(15),o=n(22),s=n(12),a=n(246),l=n(33),u=n(52),c=n(281);function h(e){if(!f(e))return[];let t=e.observedAddr;return Array.isArray(t)||(t=[t]),t.map(e=>o(e))}function f(e){return e.observedAddr&&e.observedAddr.length>0}e.exports=((e,t,n)=>{"function"==typeof t&&(n=t,t=null,console.warn("WARNING: no expected peer info was given, identify will not be able to verify peer integrity")),s(e,u.decode(),a(1),l((e,s)=>{if(e)return n(e);if(0===s.length)return n(new Error("conn was closed, did not receive data"));const a=c.decode(s[0]);i.createFromPubKey(a.publicKey,(e,i)=>{if(e)return n(e);const s=new r(i);if(t&&t.id.toB58String()!==i.toB58String())return n(new Error("invalid peer"));try{a.listenAddrs.map(o).forEach(e=>s.multiaddrs.add(e))}catch(e){return n(e)}let l;try{l=h(a)}catch(e){return n(e)}s.protocols=new Set(a.protocols),n(null,s,l)})}))})},function(e,t,n){"use strict";const r=n(280),i=n(215),o=n(4),s=o("libp2p:switch:conn-manager"),a=n(26),l=n(471),{msHandle:u,msSelect:c,identifyDialer:h}=n(279),f=n(274),p=n(473);class d{constructor(e){this.switch=e,this.connections={}}add(e){this.connections[e.theirB58Id]=this.connections[e.theirB58Id]||[],this.get(e)||(this.connections[e.theirB58Id].push(e),this.switch.emit("connection:start",e.theirPeerInfo),"MUXED"===e.getState()?(this.switch.emit("peer-mux-established",e.theirPeerInfo),this.switch.dialer.clearBlacklist(e.theirPeerInfo)):e.once("muxed",()=>{this.switch.emit("peer-mux-established",e.theirPeerInfo),this.switch.dialer.clearBlacklist(e.theirPeerInfo)}))}get(e){if(!this.connections[e.theirB58Id])return null;for(let t=0;t<this.connections[e.theirB58Id].length;t++)if(this.connections[e.theirB58Id][t]===e)return this.connections[e.theirB58Id][t];return null}getOne(e){if(this.connections[e])for(var t=0;t<this.connections[e].length;t++)if("MUXED"===this.connections[e][t].getState())return this.connections[e][t];return null}remove(e){if(this.connections[e.theirB58Id]){for(let t=0;t<this.connections[e.theirB58Id].length;t++)if(this.connections[e.theirB58Id][t]===e){this.connections[e.theirB58Id].splice(t,1);break}0===this.connections[e.theirB58Id].length&&(delete this.connections[e.theirB58Id],e.theirPeerInfo.disconnect(),this.switch.emit("peer-mux-closed",e.theirPeerInfo)),this.switch.emit("connection:end",e.theirPeerInfo)}else e.theirPeerInfo&&(e.theirPeerInfo.disconnect(),this.switch.emit("peer-mux-closed",e.theirPeerInfo))}getAll(){let e=[];for(const t of Object.values(this.connections))e=[...e,...t];return e}getAllById(e){return this.connections[e]||[]}addStreamMuxer(e){this.switch.muxers[e.multicodec]=e,this.switch.handle(e.multicodec,(t,n)=>{const o=e.listener(n);return o.on("stream",this.switch.protocolMuxer(null)),this.switch.identify&&n.getPeerInfo((e,t)=>{!e&&t||s("crypto peerInfo wasnt found"),n.getPeerInfo=(async e=>{const n=o.newStream(),s=new i.Dialer;let l;e=a(e);try{await u(s,n);const i=await c(s,r.multicodec);l=await h(i,t)}catch(t){return o.end(()=>{e(t,null)})}const{peerInfo:f}=l;f&&n.setPeerInfo(f),e(null,f)}),n.getPeerInfo((e,t)=>{if(e)return s("identify not successful");const r=t.id.toB58String();t=this.switch._peerBook.put(t);const i=new l({_switch:this.switch,peerInfo:t,muxer:o,conn:n,type:"inc"});this.switch.connection.add(i),t.isConnected()||(t.multiaddrs.size>0?t.connect(t.multiaddrs.toArray()[0]):t.connect(`/ipfs/${r}`)),o.once("close",()=>{i.close()})})}),n})}crypto(e,t){e||t||(e=p.tag,t=p.encrypt),this.switch.crypto={tag:e,encrypt:t}}enableCircuitRelay(e){e=e||{},e.enabled&&(e.hop||Object.assign(e,{hop:{enabled:!1,active:!1}}),this.switch.transport.add(f.tag,new f(this.switch,e)))}reuse(){this.switch.identify=!0,this.switch.handle(r.multicodec,(e,t)=>{r.listener(t,this.switch._peerInfo)})}}e.exports=d},function(e,t,n){"use strict";const r=n(12),i=n(24),o=n(468),s=n(1047),a=n(1049),l=n(469),u=n(216),c=n(64).Connection,h=n(470).PROTOCOL_ID;class f{constructor(){this.handlers={ls:{handlerFunc:(e,t)=>a(this,t),matchFunc:l}},this.log=u.log.listener()}handle(e,t){this.log("listener handle conn");const n=o(h,(n,i)=>{if(n)return t(n);const o=new c(i,e),a=s(o,this.handlers,this.log);r(o,a,o),t()},this.log);r(e,n,e)}addHandler(e,t,n){this.log("adding handler: "+e),i("function"==typeof t,"handler must be a function"),this.handlers[e]&&this.log("overwriting handler for "+e),n||(n=l),this.handlers[e]={handlerFunc:t,matchFunc:n}}}e.exports=f},function(e,t,n){"use strict";(function(t){const r=n(102),i=n(52),o=n(64).Connection,s=n(216).writeEncoded,a=n(1048);function l(e,n,a){const l=e=>{a.error(e)},c=r({timeout:6e4},l),h=c.handshake;return f(),c;function f(){i.decodeFromReader(h,(r,i)=>{if(r)return l(r);a("received:",i.toString());const c=i.toString().slice(0,-1);u(c,n,(r,u)=>{if(r)return l(r);const p=u;if(p){a("send ack back of: "+c),s(h,i,l);const t=new o(h.rest(),e);n[p].handlerFunc(c,t)}else a("not supported protocol: "+c),s(h,t.from("na\n")),f()})})}}function u(e,t,n){const r=Object.keys(t);let i=!1;a(r,(n,r)=>{t[n].matchFunc(n,e,(e,t)=>{if(e)return r(e);t&&(i=n),r()})},e=>{if(e)return n(e);n(null,i)})}e.exports=l}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(157),i=u(r),o=n(110),s=u(o),a=n(156),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)((0,i.default)(Boolean,l.default)),e.exports=t.default},function(e,t,n){"use strict";(function(t){const r=n(12),i=n(40),o=n(52),s=n(35);function a(e,n){const a=Object.keys(e.handlers).filter(e=>"ls"!==e),l=a.length,u=a.reduce((e,n)=>{const r=t.from(n+"\n"),i=s.encodingLength(r.length);return e+i},0),c=t.concat([t.from(s.encode(l)),t.from(s.encode(u)),t.from("\n")]),h=a.map(e=>t.from(e+"\n"));r(i([c].concat(h)),o.encode(),n)}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(35),i=n(12),o=n(66),s=n(33),a=n(246),l=n(52),u=n(64).Connection,c=n(216),h=n(468),f=n(26),p=n(470).PROTOCOL_ID;class d{constructor(){this.conn=null,this.log=c.log.dialer()}handle(e,t){this.log("dialer handle conn"),t=f(t);const n=h(p,(n,r)=>{if(n)return t(n);this.log("handshake success"),this.conn=new u(r,e),t()},this.log);try{i(e,n,e)}catch(e){this.log.error(e),t(e)}}select(e,t){if(this.log("dialer select "+e),t=f(t),!this.conn)return t(new Error("multistream handshake has not finalized yet"));const n=h(e,(e,n)=>{if(e)return this.conn=new u(n,this.conn),t(e);t(null,new u(n,this.conn))},this.log);i(this.conn,n,this.conn)}ls(e){e=f(e);const t=h("ls",(t,n)=>{if(t)return e(t);i(n,l.decode(),g(n),o(m),s((t,n)=>{if(t)return e(t);e(null,n.slice(1))}))},this.log);i(this.conn,t,this.conn)}}function m(e){return e.toString().slice(0,-1)}function g(e){let t=!0,n=0;return a(e=>(r.decode(e),n=r.decode(e,r.decode.bytes),!0))}e.exports=d},function(e,t,n){"use strict";const r=n(1052);function i(e,t,n){const i=e.split("/"),o=t.split("/"),s=i[1],a=i[2],l=o[1],u=o[2];if(s!==l)return n(null,!1);const c=r.satisfies(a,"~"+u);n(null,c)}e.exports=i},function(e,t,n){(function(n){var r;t=e.exports=ee,r="object"==typeof n&&n.env&&n.env.NODE_DEBUG&&/\bsemver\b/i.test(n.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments,0);e.unshift("SEMVER"),console.log.apply(console,e)}:function(){},t.SEMVER_SPEC_VERSION="2.0.0";var i=256,o=Number.MAX_SAFE_INTEGER||9007199254740991,s=16,a=t.re=[],l=t.src=[],u=0,c=u++;l[c]="0|[1-9]\\d*";var h=u++;l[h]="[0-9]+";var f=u++;l[f]="\\d*[a-zA-Z-][a-zA-Z0-9-]*";var p=u++;l[p]="("+l[c]+")\\.("+l[c]+")\\.("+l[c]+")";var d=u++;l[d]="("+l[h]+")\\.("+l[h]+")\\.("+l[h]+")";var m=u++;l[m]="(?:"+l[c]+"|"+l[f]+")";var g=u++;l[g]="(?:"+l[h]+"|"+l[f]+")";var y=u++;l[y]="(?:-("+l[m]+"(?:\\."+l[m]+")*))";var v=u++;l[v]="(?:-?("+l[g]+"(?:\\."+l[g]+")*))";var b=u++;l[b]="[0-9A-Za-z-]+";var _=u++;l[_]="(?:\\+("+l[b]+"(?:\\."+l[b]+")*))";var w=u++,k="v?"+l[p]+l[y]+"?"+l[_]+"?";l[w]="^"+k+"$";var E="[v=\\s]*"+l[d]+l[v]+"?"+l[_]+"?",S=u++;l[S]="^"+E+"$";var x=u++;l[x]="((?:<|>)?=?)";var C=u++;l[C]=l[h]+"|x|X|\\*";var A=u++;l[A]=l[c]+"|x|X|\\*";var T=u++;l[T]="[v=\\s]*("+l[A]+")(?:\\.("+l[A]+")(?:\\.("+l[A]+")(?:"+l[y]+")?"+l[_]+"?)?)?";var I=u++;l[I]="[v=\\s]*("+l[C]+")(?:\\.("+l[C]+")(?:\\.("+l[C]+")(?:"+l[v]+")?"+l[_]+"?)?)?";var j=u++;l[j]="^"+l[x]+"\\s*"+l[T]+"$";var R=u++;l[R]="^"+l[x]+"\\s*"+l[I]+"$";var B=u++;l[B]="(?:^|[^\\d])(\\d{1,16})(?:\\.(\\d{1,16}))?(?:\\.(\\d{1,16}))?(?:$|[^\\d])";var O=u++;l[O]="(?:~>?)";var P=u++;l[P]="(\\s*)"+l[O]+"\\s+",a[P]=new RegExp(l[P],"g");var N="$1~",D=u++;l[D]="^"+l[O]+l[T]+"$";var M=u++;l[M]="^"+l[O]+l[I]+"$";var F=u++;l[F]="(?:\\^)";var L=u++;l[L]="(\\s*)"+l[F]+"\\s+",a[L]=new RegExp(l[L],"g");var U="$1^",q=u++;l[q]="^"+l[F]+l[T]+"$";var z=u++;l[z]="^"+l[F]+l[I]+"$";var K=u++;l[K]="^"+l[x]+"\\s*("+E+")$|^$";var H=u++;l[H]="^"+l[x]+"\\s*("+k+")$|^$";var V=u++;l[V]="(\\s*)"+l[x]+"\\s*("+E+"|"+l[T]+")",a[V]=new RegExp(l[V],"g");var $="$1$2$3",W=u++;l[W]="^\\s*("+l[T]+")\\s+-\\s+("+l[T]+")\\s*$";var G=u++;l[G]="^\\s*("+l[I]+")\\s+-\\s+("+l[I]+")\\s*$";var Y=u++;l[Y]="(<|>)?=?\\s*\\*";for(var Z=0;Z<u;Z++)r(Z,l[Z]),a[Z]||(a[Z]=new RegExp(l[Z]));function J(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof ee)return e;if("string"!=typeof e)return null;if(e.length>i)return null;var n=t.loose?a[S]:a[w];if(!n.test(e))return null;try{return new ee(e,t)}catch(e){return null}}function Q(e,t){var n=J(e,t);return n?n.version:null}function X(e,t){var n=J(e.trim().replace(/^[=v]+/,""),t);return n?n.version:null}function ee(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof ee){if(e.loose===t.loose)return e;e=e.version}else if("string"!=typeof e)throw new TypeError("Invalid Version: "+e);if(e.length>i)throw new TypeError("version is longer than "+i+" characters");if(!(this instanceof ee))return new ee(e,t);r("SemVer",e,t),this.options=t,this.loose=!!t.loose;var n=e.trim().match(t.loose?a[S]:a[w]);if(!n)throw new TypeError("Invalid Version: "+e);if(this.raw=e,this.major=+n[1],this.minor=+n[2],this.patch=+n[3],this.major>o||this.major<0)throw new TypeError("Invalid major version");if(this.minor>o||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>o||this.patch<0)throw new TypeError("Invalid patch version");n[4]?this.prerelease=n[4].split(".").map(function(e){if(/^[0-9]+$/.test(e)){var t=+e;if(t>=0&&t<o)return t}return e}):this.prerelease=[],this.build=n[5]?n[5].split("."):[],this.format()}function te(e,t,n,r){"string"==typeof n&&(r=n,n=void 0);try{return new ee(e,n).inc(t,r).version}catch(e){return null}}function ne(e,t){if(ge(e,t))return null;var n=J(e),r=J(t),i="";if(n.prerelease.length||r.prerelease.length){i="pre";var o="prerelease"}for(var s in n)if(("major"===s||"minor"===s||"patch"===s)&&n[s]!==r[s])return i+s;return o}t.parse=J,t.valid=Q,t.clean=X,t.SemVer=ee,ee.prototype.format=function(){return this.version=this.major+"."+this.minor+"."+this.patch,this.prerelease.length&&(this.version+="-"+this.prerelease.join(".")),this.version},ee.prototype.toString=function(){return this.version},ee.prototype.compare=function(e){return r("SemVer.compare",this.version,this.options,e),e instanceof ee||(e=new ee(e,this.options)),this.compareMain(e)||this.comparePre(e)},ee.prototype.compareMain=function(e){return e instanceof ee||(e=new ee(e,this.options)),ie(this.major,e.major)||ie(this.minor,e.minor)||ie(this.patch,e.patch)},ee.prototype.comparePre=function(e){if(e instanceof ee||(e=new ee(e,this.options)),this.prerelease.length&&!e.prerelease.length)return-1;if(!this.prerelease.length&&e.prerelease.length)return 1;if(!this.prerelease.length&&!e.prerelease.length)return 0;var t=0;do{var n=this.prerelease[t],i=e.prerelease[t];if(r("prerelease compare",t,n,i),void 0===n&&void 0===i)return 0;if(void 0===i)return 1;if(void 0===n)return-1;if(n!==i)return ie(n,i)}while(++t)},ee.prototype.inc=function(e,t){switch(e){case"premajor":this.prerelease.length=0,this.patch=0,this.minor=0,this.major++,this.inc("pre",t);break;case"preminor":this.prerelease.length=0,this.patch=0,this.minor++,this.inc("pre",t);break;case"prepatch":this.prerelease.length=0,this.inc("patch",t),this.inc("pre",t);break;case"prerelease":0===this.prerelease.length&&this.inc("patch",t),this.inc("pre",t);break;case"major":0===this.minor&&0===this.patch&&0!==this.prerelease.length||this.major++,this.minor=0,this.patch=0,this.prerelease=[];break;case"minor":0===this.patch&&0!==this.prerelease.length||this.minor++,this.patch=0,this.prerelease=[];break;case"patch":0===this.prerelease.length&&this.patch++,this.prerelease=[];break;case"pre":if(0===this.prerelease.length)this.prerelease=[0];else{for(var n=this.prerelease.length;--n>=0;)"number"==typeof this.prerelease[n]&&(this.prerelease[n]++,n=-2);-1===n&&this.prerelease.push(0)}t&&(this.prerelease[0]===t?isNaN(this.prerelease[1])&&(this.prerelease=[t,0]):this.prerelease=[t,0]);break;default:throw new Error("invalid increment argument: "+e)}return this.format(),this.raw=this.version,this},t.inc=te,t.diff=ne,t.compareIdentifiers=ie;var re=/^[0-9]+$/;function ie(e,t){var n=re.test(e),r=re.test(t);return n&&r&&(e=+e,t=+t),e===t?0:n&&!r?-1:r&&!n?1:e<t?-1:1}function oe(e,t){return ie(t,e)}function se(e,t){return new ee(e,t).major}function ae(e,t){return new ee(e,t).minor}function le(e,t){return new ee(e,t).patch}function ue(e,t,n){return new ee(e,n).compare(new ee(t,n))}function ce(e,t){return ue(e,t,!0)}function he(e,t,n){return ue(t,e,n)}function fe(e,n){return e.sort(function(e,r){return t.compare(e,r,n)})}function pe(e,n){return e.sort(function(e,r){return t.rcompare(e,r,n)})}function de(e,t,n){return ue(e,t,n)>0}function me(e,t,n){return ue(e,t,n)<0}function ge(e,t,n){return 0===ue(e,t,n)}function ye(e,t,n){return 0!==ue(e,t,n)}function ve(e,t,n){return ue(e,t,n)>=0}function be(e,t,n){return ue(e,t,n)<=0}function _e(e,t,n,r){switch(t){case"===":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e===n;case"!==":return"object"==typeof e&&(e=e.version),"object"==typeof n&&(n=n.version),e!==n;case"":case"=":case"==":return ge(e,n,r);case"!=":return ye(e,n,r);case">":return de(e,n,r);case">=":return ve(e,n,r);case"<":return me(e,n,r);case"<=":return be(e,n,r);default:throw new TypeError("Invalid operator: "+t)}}function we(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof we){if(e.loose===!!t.loose)return e;e=e.value}if(!(this instanceof we))return new we(e,t);r("comparator",e,t),this.options=t,this.loose=!!t.loose,this.parse(e),this.semver===ke?this.value="":this.value=this.operator+this.semver.version,r("comp",this)}t.rcompareIdentifiers=oe,t.major=se,t.minor=ae,t.patch=le,t.compare=ue,t.compareLoose=ce,t.rcompare=he,t.sort=fe,t.rsort=pe,t.gt=de,t.lt=me,t.eq=ge,t.neq=ye,t.gte=ve,t.lte=be,t.cmp=_e,t.Comparator=we;var ke={};function Ee(e,t){if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),e instanceof Ee)return e.loose===!!t.loose&&e.includePrerelease===!!t.includePrerelease?e:new Ee(e.raw,t);if(e instanceof we)return new Ee(e.value,t);if(!(this instanceof Ee))return new Ee(e,t);if(this.options=t,this.loose=!!t.loose,this.includePrerelease=!!t.includePrerelease,this.raw=e,this.set=e.split(/\s*\|\|\s*/).map(function(e){return this.parseRange(e.trim())},this).filter(function(e){return e.length}),!this.set.length)throw new TypeError("Invalid SemVer Range: "+e);this.format()}function Se(e,t){return new Ee(e,t).set.map(function(e){return e.map(function(e){return e.value}).join(" ").trim().split(" ")})}function xe(e,t){return r("comp",e,t),e=Ie(e,t),r("caret",e),e=Ae(e,t),r("tildes",e),e=Re(e,t),r("xrange",e),e=Oe(e,t),r("stars",e),e}function Ce(e){return!e||"x"===e.toLowerCase()||"*"===e}function Ae(e,t){return e.trim().split(/\s+/).map(function(e){return Te(e,t)}).join(" ")}function Te(e,t){var n=t.loose?a[M]:a[D];return e.replace(n,function(t,n,i,o,s){var a;return r("tilde",e,t,n,i,o,s),Ce(n)?a="":Ce(i)?a=">="+n+".0.0 <"+(+n+1)+".0.0":Ce(o)?a=">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0":s?(r("replaceTilde pr",s),a=">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+(+i+1)+".0"):a=">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0",r("tilde return",a),a})}function Ie(e,t){return e.trim().split(/\s+/).map(function(e){return je(e,t)}).join(" ")}function je(e,t){r("caret",e,t);var n=t.loose?a[z]:a[q];return e.replace(n,function(t,n,i,o,s){var a;return r("caret",e,t,n,i,o,s),Ce(n)?a="":Ce(i)?a=">="+n+".0.0 <"+(+n+1)+".0.0":Ce(o)?a="0"===n?">="+n+"."+i+".0 <"+n+"."+(+i+1)+".0":">="+n+"."+i+".0 <"+(+n+1)+".0.0":s?(r("replaceCaret pr",s),a="0"===n?"0"===i?">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+i+"."+(+o+1):">="+n+"."+i+"."+o+"-"+s+" <"+n+"."+(+i+1)+".0":">="+n+"."+i+"."+o+"-"+s+" <"+(+n+1)+".0.0"):(r("no pr"),a="0"===n?"0"===i?">="+n+"."+i+"."+o+" <"+n+"."+i+"."+(+o+1):">="+n+"."+i+"."+o+" <"+n+"."+(+i+1)+".0":">="+n+"."+i+"."+o+" <"+(+n+1)+".0.0"),r("caret return",a),a})}function Re(e,t){return r("replaceXRanges",e,t),e.split(/\s+/).map(function(e){return Be(e,t)}).join(" ")}function Be(e,t){e=e.trim();var n=t.loose?a[R]:a[j];return e.replace(n,function(t,n,i,o,s,a){r("xRange",e,t,n,i,o,s,a);var l=Ce(i),u=l||Ce(o),c=u||Ce(s),h=c;return"="===n&&h&&(n=""),l?t=">"===n||"<"===n?"<0.0.0":"*":n&&h?(u&&(o=0),s=0,">"===n?(n=">=",u?(i=+i+1,o=0,s=0):(o=+o+1,s=0)):"<="===n&&(n="<",u?i=+i+1:o=+o+1),t=n+i+"."+o+"."+s):u?t=">="+i+".0.0 <"+(+i+1)+".0.0":c&&(t=">="+i+"."+o+".0 <"+i+"."+(+o+1)+".0"),r("xRange return",t),t})}function Oe(e,t){return r("replaceStars",e,t),e.trim().replace(a[Y],"")}function Pe(e,t,n,r,i,o,s,a,l,u,c,h,f){return t=Ce(n)?"":Ce(r)?">="+n+".0.0":Ce(i)?">="+n+"."+r+".0":">="+t,a=Ce(l)?"":Ce(u)?"<"+(+l+1)+".0.0":Ce(c)?"<"+l+"."+(+u+1)+".0":h?"<="+l+"."+u+"."+c+"-"+h:"<="+a,(t+" "+a).trim()}function Ne(e,t,n){for(var i=0;i<e.length;i++)if(!e[i].test(t))return!1;if(t.prerelease.length&&!n.includePrerelease){for(i=0;i<e.length;i++)if(r(e[i].semver),e[i].semver!==ke&&e[i].semver.prerelease.length>0){var o=e[i].semver;if(o.major===t.major&&o.minor===t.minor&&o.patch===t.patch)return!0}return!1}return!0}function De(e,t,n){try{t=new Ee(t,n)}catch(e){return!1}return t.test(e)}function Me(e,t,n){var r=null,i=null;try{var o=new Ee(t,n)}catch(e){return null}return e.forEach(function(e){o.test(e)&&(r&&-1!==i.compare(e)||(r=e,i=new ee(r,n)))}),r}function Fe(e,t,n){var r=null,i=null;try{var o=new Ee(t,n)}catch(e){return null}return e.forEach(function(e){o.test(e)&&(r&&1!==i.compare(e)||(r=e,i=new ee(r,n)))}),r}function Le(e,t){e=new Ee(e,t);var n=new ee("0.0.0");if(e.test(n))return n;if(n=new ee("0.0.0-0"),e.test(n))return n;n=null;for(var r=0;r<e.set.length;++r){var i=e.set[r];i.forEach(function(e){var t=new ee(e.semver.version);switch(e.operator){case">":0===t.prerelease.length?t.patch++:t.prerelease.push(0),t.raw=t.format();case"":case">=":n&&!de(n,t)||(n=t);break;case"<":case"<=":break;default:throw new Error("Unexpected operation: "+e.operator)}})}return n&&e.test(n)?n:null}function Ue(e,t){try{return new Ee(e,t).range||"*"}catch(e){return null}}function qe(e,t,n){return Ke(e,t,"<",n)}function ze(e,t,n){return Ke(e,t,">",n)}function Ke(e,t,n,r){var i,o,s,a,l;switch(e=new ee(e,r),t=new Ee(t,r),n){case">":i=de,o=be,s=me,a=">",l=">=";break;case"<":i=me,o=ve,s=de,a="<",l="<=";break;default:throw new TypeError('Must provide a hilo val of "<" or ">"')}if(De(e,t,r))return!1;for(var u=0;u<t.set.length;++u){var c=t.set[u],h=null,f=null;if(c.forEach(function(e){e.semver===ke&&(e=new we(">=0.0.0")),h=h||e,f=f||e,i(e.semver,h.semver,r)?h=e:s(e.semver,f.semver,r)&&(f=e)}),h.operator===a||h.operator===l)return!1;if((!f.operator||f.operator===a)&&o(e,f.semver))return!1;if(f.operator===l&&s(e,f.semver))return!1}return!0}function He(e,t){var n=J(e,t);return n&&n.prerelease.length?n.prerelease:null}function Ve(e,t,n){return e=new Ee(e,n),t=new Ee(t,n),e.intersects(t)}function $e(e){if(e instanceof ee)return e;if("string"!=typeof e)return null;var t=e.match(a[B]);return null==t?null:J(t[1]+"."+(t[2]||"0")+"."+(t[3]||"0"))}we.prototype.parse=function(e){var t=this.options.loose?a[K]:a[H],n=e.match(t);if(!n)throw new TypeError("Invalid comparator: "+e);this.operator=n[1],"="===this.operator&&(this.operator=""),n[2]?this.semver=new ee(n[2],this.options.loose):this.semver=ke},we.prototype.toString=function(){return this.value},we.prototype.test=function(e){return r("Comparator.test",e,this.options.loose),this.semver===ke||("string"==typeof e&&(e=new ee(e,this.options)),_e(e,this.operator,this.semver,this.options))},we.prototype.intersects=function(e,t){if(!(e instanceof we))throw new TypeError("a Comparator is required");var n;if(t&&"object"==typeof t||(t={loose:!!t,includePrerelease:!1}),""===this.operator)return n=new Ee(e.value,t),De(this.value,n,t);if(""===e.operator)return n=new Ee(this.value,t),De(e.semver,n,t);var r=!(">="!==this.operator&&">"!==this.operator||">="!==e.operator&&">"!==e.operator),i=!("<="!==this.operator&&"<"!==this.operator||"<="!==e.operator&&"<"!==e.operator),o=this.semver.version===e.semver.version,s=!(">="!==this.operator&&"<="!==this.operator||">="!==e.operator&&"<="!==e.operator),a=_e(this.semver,"<",e.semver,t)&&(">="===this.operator||">"===this.operator)&&("<="===e.operator||"<"===e.operator),l=_e(this.semver,">",e.semver,t)&&("<="===this.operator||"<"===this.operator)&&(">="===e.operator||">"===e.operator);return r||i||o&&s||a||l},t.Range=Ee,Ee.prototype.format=function(){return this.range=this.set.map(function(e){return e.join(" ").trim()}).join("||").trim(),this.range},Ee.prototype.toString=function(){return this.range},Ee.prototype.parseRange=function(e){var t=this.options.loose;e=e.trim();var n=t?a[G]:a[W];e=e.replace(n,Pe),r("hyphen replace",e),e=e.replace(a[V],"$1$2$3"),r("comparator trim",e,a[V]),e=e.replace(a[P],"$1~"),e=e.replace(a[L],"$1^"),e=e.split(/\s+/).join(" ");var i=t?a[K]:a[H],o=e.split(" ").map(function(e){return xe(e,this.options)},this).join(" ").split(/\s+/);return this.options.loose&&(o=o.filter(function(e){return!!e.match(i)})),o=o.map(function(e){return new we(e,this.options)},this),o},Ee.prototype.intersects=function(e,t){if(!(e instanceof Ee))throw new TypeError("a Range is required");return this.set.some(function(n){return n.every(function(n){return e.set.some(function(e){return e.every(function(e){return n.intersects(e,t)})})})})},t.toComparators=Se,Ee.prototype.test=function(e){if(!e)return!1;"string"==typeof e&&(e=new ee(e,this.options));for(var t=0;t<this.set.length;t++)if(Ne(this.set[t],e,this.options))return!0;return!1},t.satisfies=De,t.maxSatisfying=Me,t.minSatisfying=Fe,t.minVersion=Le,t.validRange=Ue,t.ltr=qe,t.gtr=ze,t.outside=Ke,t.prerelease=He,t.intersects=Ve,t.coerce=$e}).call(this,n(3))},function(e,t,n){"use strict";const r=n(1054),i=n(474),{BLACK_LIST_ATTEMPTS:o,BLACK_LIST_TTL:s,MAX_COLD_CALLS:a,MAX_PARALLEL_DIALS:l,PRIORITY_HIGH:u,PRIORITY_LOW:c}=n(278);e.exports=function(e){const t=new r(e);function n({peerInfo:n,protocol:r,options:o,callback:s}){"function"==typeof r&&(s=r,r=null);try{n=i(n,e._peerBook)}catch(e){return s(e)}t.add({peerInfo:n,protocol:r,options:o,callback:s})}function h(e){t.start(),e()}function f(e){t.stop(),e()}function p(e){t.clearBlacklist(e)}function d(e,t,r){"function"==typeof t&&(r=t,t=null),t={useFSM:!1,priority:c,...t},n({peerInfo:e,protocol:null,options:t,callback:r})}function m(e,t,r){n({peerInfo:e,protocol:t,options:{useFSM:!1,priority:u},callback:r})}function g(e,t,r){n({peerInfo:e,protocol:t,options:{useFSM:!0,priority:u},callback:r})}return e.state.on("STARTED:enter",h),e.state.on("STOPPING:enter",f),{connect:d,dial:m,dialFSM:g,clearBlacklist:p,BLACK_LIST_ATTEMPTS:isNaN(e._options.blackListAttempts)?o:e._options.blackListAttempts,BLACK_LIST_TTL:isNaN(e._options.blacklistTTL)?s:e._options.blacklistTTL,MAX_COLD_CALLS:isNaN(e._options.maxColdCalls)?a:e._options.maxColdCalls,MAX_PARALLEL_DIALS:isNaN(e._options.maxParallelDials)?l:e._options.maxParallelDials}}},function(e,t,n){"use strict";const r=n(26),i=n(1055),{DIAL_ABORTED:o}=n(217),s=n(47),a=n(475),{QUARTER_HOUR:l,PRIORITY_HIGH:u}=n(278),c=n(4),h=c("libp2p:switch:dial:manager"),f=()=>{};class p{constructor(e){this._queue=new Set,this._coldCallQueue=new Set,this._dialingQueues=new Set,this._queues={},this.switch=e,this._cleanInterval=a(this._clean.bind(this),l),this.start()}_clean(){const e=Object.values(this._queues);e.forEach(e=>{if(e.blackListed===1/0)return e.abort(),void delete this._queues[e.id];if(!e.blackListed&&!e.isRunning&&e.length<1){let t=!1;try{const n=this.switch._peerBook.get(e.id);t=Boolean(n.isConnected())}catch(e){}t||(e.abort(),delete this._queues[e.id])}}),this._cleanInterval.reschedule(l)}start(){this.isRunning=!0}stop(){this.isRunning=!1,this._queue.clear(),this._coldCallQueue.clear(),this._cleanInterval.clear();const e=Object.values(this._queues);e.forEach(e=>{e.abort(),delete this._queues[e.id]})}add({peerInfo:e,protocol:t,options:n,callback:i}){i=i?r(i):f;const a=this.getQueue(e);if(n.priority>u){if(this._coldCallQueue.size>=this.switch.dialer.MAX_COLD_CALLS)return s(i,o());if(this._queue.has(a.id))return s(i,o())}a.add(t,n.useFSM,i),e.isConnected()?a.start():a.isDialAllowed()&&(a.isRunning||(n.priority<=u?(this._queue.add(a.id),this._coldCallQueue.delete(a.id)):this._coldCallQueue.add(a.id)),this.run())}run(){if(this.isRunning&&this._dialingQueues.size<this.switch.dialer.MAX_PARALLEL_DIALS){let e={done:!0};if(this._queue.size>0?(e=this._queue.values().next(),this._queue.delete(e.value)):this._coldCallQueue.size>0&&(e=this._coldCallQueue.values().next(),this._coldCallQueue.delete(e.value)),e.done)return;let t=this._queues[e.value];if(!t)return void h("missing queue %s, maybe it was aborted?",e.value);this._dialingQueues.add(t.id),t.start()}}clearBlacklist(e){const t=this.getQueue(e);t.blackListed=null,t.blackListCount=0}_onQueueStopped(e){this._dialingQueues.delete(e),this.run()}getQueue(e){const t=e.id.toB58String();return this._queues[t]=this._queues[t]||new i(t,this.switch,this._onQueueStopped.bind(this)),this._queues[t]}}e.exports=p},function(e,t,n){"use strict";const r=n(471),{DIAL_ABORTED:i,ERR_BLACKLISTED:o}=n(217),s=n(47),a=n(26),l=n(4),u=l("libp2p:switch:dial");function c({protocol:e,connection:t,callback:n}){if(!e)return n();t.shake(e,(e,r)=>{if(!r)return n(e);r.setPeerInfo(t.theirPeerInfo),n(null,r)})}u.error=l("libp2p:switch:dial:error");class h{constructor(e,t,n){this.id=e,this.switch=t,this._queue=[],this.blackListed=null,this.blackListCount=0,this.isRunning=!1,this.onStopped=n}get length(){return this._queue.length}add(e,t,n){if(!this.isDialAllowed())return s(n,o());this._queue.push({protocol:e,useFSM:t,callback:n})}isDialAllowed(){return!this.blackListed||Date.now()>this.blackListed&&(this.blackListed=null,!0)}start(){return!this.isRunning&&(u("starting dial queue to %s",this.id),this.isRunning=!0,this._run(),!0)}stop(){this.isRunning&&(u("stopping dial queue to %s",this.id),this.isRunning=!1,this.onStopped(this.id))}abort(){for(;this.length>0;){let e=this._queue.shift();e.callback(i())}this.stop()}blacklist(){if(this.blackListCount++,this.blackListCount>=this.switch.dialer.BLACK_LIST_ATTEMPTS)return void(this.blackListed=1/0);let e=this.switch.dialer.BLACK_LIST_TTL*Math.pow(this.blackListCount,3);const t=.9*e,n=1.1*e;e=Math.floor(Math.random()*(n-t)+t),this.blackListed=Date.now()+e,this.abort()}_getOrCreateConnection(e){let t=this.switch.connection.getOne(this.id),n=!1;return t||(t=new r({_switch:this.switch,peerInfo:e,muxer:null,conn:null}),this.switch.connection.add(t),t.once("connected",()=>t.protect()),t.once("private",()=>t.encrypt()),t.once("encrypted",()=>t.upgrade()),n=!0),{connectionFSM:t,didCreate:n}}_run(){if(this.length<1||!this.isRunning)return u("stopping the queue for %s",this.id),this.stop();const e=a(()=>{u("starting next dial to %s",this.id),this._run()}),t=this.switch._peerBook.get(this.id);let n=this._queue.shift(),{connectionFSM:r,didCreate:i}=this._getOrCreateConnection(t);if(n.useFSM&&s(n.callback,null,r),["MUXED","CONNECTED"].includes(r.getState()))return n.connection=r,c(n),void e();r.once("error",e=>{n.callback(e),t.protocols.size>0&&t.isConnected()||this.blacklist()}),r.once("close",()=>{e()}),r.once("muxed",()=>{this.blackListCount=0,n.connection=r,c(n),e()}),r.once("unmuxed",()=>{this.blackListCount=0,n.connection=r,c(n),e()}),i&&r.dial()}}e.exports=h},function(e,t,n){"use strict";e.exports=function e(){return Date.now()}},function(e,t,n){"use strict";const r=n(4),i=n(1058),o=n(282);function s(e){const t=r("libp2p:switch:listener");return function(n,r){return function(s){t("received incoming connection for transport %s",n),s.getPeerInfo((a,l)=>{const u=n?o(n,null,s,e.observer):s,c=new i({connection:u,_switch:e,transportKey:n,peerInfo:l});c.once("error",e=>t(e)),c.once("private",e=>{if(r)return r(e);c.encrypt()}),c.once("encrypted",()=>c.upgrade()),c.protect()})}}}e.exports=s},function(e,t,n){"use strict";const r=n(160),i=n(215),o=n(39),s=n(472);class a extends s{constructor({connection:e,_switch:t,transportKey:n,peerInfo:o}){super({_switch:t,name:`inc:${t._peerInfo.id.toB58String().slice(0,8)}`}),this.conn=e,this.theirPeerInfo=o||null,this.theirB58Id=this.theirPeerInfo?this.theirPeerInfo.id.toB58String():null,this.ourPeerInfo=this.switch._peerInfo,this.transportKey=n,this.protocolMuxer=this.switch.protocolMuxer(this.transportKey),this.msListener=new i.Listener,this._state=r("DIALED",{DISCONNECTED:{disconnect:"DISCONNECTED"},DIALED:{privatize:"PRIVATIZING",encrypt:"ENCRYPTING"},PRIVATIZING:{done:"PRIVATIZED",disconnect:"DISCONNECTING"},PRIVATIZED:{encrypt:"ENCRYPTING"},ENCRYPTING:{done:"ENCRYPTED",disconnect:"DISCONNECTING"},ENCRYPTED:{upgrade:"UPGRADING",disconnect:"DISCONNECTING"},UPGRADING:{done:"MUXED"},MUXED:{disconnect:"DISCONNECTING"},DISCONNECTING:{done:"DISCONNECTED"}}),this._state.on("DISCONNECTED",()=>this._onDisconnected()),this._state.on("PRIVATIZING",()=>this._onPrivatizing()),this._state.on("PRIVATIZED",()=>this._onPrivatized()),this._state.on("ENCRYPTING",()=>this._onEncrypting()),this._state.on("ENCRYPTED",()=>{this.log("successfully encrypted connection to %s",this.theirB58Id||"unknown peer"),this.emit("encrypted",this.conn)}),this._state.on("UPGRADING",()=>this._onUpgrading()),this._state.on("MUXED",()=>{this.log("successfully muxed connection to %s",this.theirB58Id||"unknown peer"),this.emit("muxed",this.conn)}),this._state.on("DISCONNECTING",()=>{this._state("done")})}_onEncrypting(){this.log("encrypting connection via %s",this.switch.crypto.tag),this.msListener.addHandler(this.switch.crypto.tag,(e,t)=>{this.conn=this.switch.crypto.encrypt(this.ourPeerInfo.id,t,void 0,e=>{if(e)return this.close(e);this.conn.getPeerInfo((e,t)=>{this.theirPeerInfo=t,this._state("done")})})},null),this.msListener.handle(this.conn,e=>{e&&this.emit("crypto handshaking failed",e)})}_onUpgrading(){this.log("adding the protocol muxer to the connection"),this.protocolMuxer(this.conn,this.msListener),this._state("done")}}e.exports=o(a,{className:"IncomingConnectionFSM",symbolName:"libp2p-switch/IncomingConnectionFSM"})},function(e,t,n){"use strict";const r=n(215),i=n(282),o=n(4),s=o("libp2p:switch:protocol-muxer");s.error=o("libp2p:switch:protocol-muxer:error"),e.exports=function e(t,n){return e=>(o,a)=>{const l=a||new r.Listener;let u;u=e&&!a?i(e,null,o,n):o,Object.keys(t).forEach(e=>{if(!e)return;const r=(e,r)=>{s("registering handler with protocol %s",e);const o=t[e];if(o){const t=o&&o.handlerFunc;if(t){const s=i(null,e,r,n);t(o,s)}}};l.addHandler(e,r,t[e].matchFunc)}),l.handle(u,e=>{e&&s.error("multistream handshake failed",e)})}}},function(e,t,n){"use strict";const r=n(66),i=n(6);e.exports=(e=>{const t=Object.assign(new i,{incoming:n("in"),outgoing:n("out")});return e.on("peer-mux-established",e=>{t.emit("peer:connected",e.id.toB58String())}),e.on("peer-mux-closed",e=>{t.emit("peer:closed",e.id.toB58String())}),t;function n(e){return(t,n,i)=>r(r=>(o(i,t,n,e,r.length),r))}function o(e,n,r,i,o){e.then(e=>{if(e){const s=e.id.toB58String();t.emit("message",s,n,r,i,o)}})}})},function(e,t,n){"use strict";const r=n(6),i=n(1062),o=n(1063),s={computeThrottleMaxQueueSize:1e3,computeThrottleTimeout:2e3,movingAverageIntervals:[6e4,3e5,9e5],maxOldPeersRetention:50},a=["dataReceived","dataSent"],l={in:"dataReceived",out:"dataSent"};e.exports=((e,t)=>{const n=Object.assign({},s,t),u=new i(a,n),c=Object.assign(new r,{start:g,stop:y,global:u,peers:()=>Array.from(f.keys()),forPeer:e=>f.get(e)||h.get(e),transports:()=>Array.from(p.keys()),forTransport:e=>p.get(e),protocols:()=>Array.from(d.keys()),forProtocol:e=>d.get(e)});u.on("update",v);const h=o(n.maxOldPeersRetention),f=new Map,p=new Map,d=new Map;return e.on("peer:closed",e=>{const t=f.get(e);t&&(t.removeListener("update",v),t.stop(),f.delete(e),h.set(e,t))}),c;function m(e,t,r,o,s){const c=l[o];if(t){u.push(c,s);let t=f.get(e);t||(t=h.get(e),t?h.delete(e):t=new i(a,n),t.on("update",v),t.start(),f.set(e,t)),t.push(c,s)}if(t){let e=p.get(t);e||(e=new i(a,n),e.on("update",v),p.set(t,e)),e.push(c,s)}if(r){let e=d.get(r);e||(e=new i(a,n),e.on("update",v),d.set(r,e)),e.push(c,s)}}function g(){e.on("message",m),u.start();for(let e of f.values())e.start();for(let e of p.values())e.start()}function y(){e.removeListener("message",m),u.stop();for(let e of f.values())e.stop();for(let e of p.values())e.stop()}function v(){c.emit("update")}})},function(e,t,n){"use strict";const r=n(6),i=n(55),o=n(431),s=n(475);class a extends r{constructor(e,t){super(),this._options=t,this._queue=[],this._stats={},this._frequencyLastTime=Date.now(),this._frequencyAccumulators={},this._movingAverages={},this._update=this._update.bind(this);const n=this._options.movingAverageIntervals;for(var r=0;r<e.length;r++){var s=e[r];this._stats[s]=i(0),this._movingAverages[s]={};for(var a=0;a<n.length;a++){var l=n[a],u=this._movingAverages[s][l]=o(l);u.push(this._frequencyLastTime,0)}}}start(){this._queue.length&&this._resetComputeTimeout()}stop(){this._timeout&&(this._timeout.clear(),this._timeout=null)}get snapshot(){return Object.assign({},this._stats)}get movingAverages(){return Object.assign({},this._movingAverages)}push(e,t){this._queue.push([e,t,Date.now()]),this._resetComputeTimeout()}_resetComputeTimeout(){this._timeout?this._timeout.reschedule(this._nextTimeout()):this._timeout=s(this._update,this._nextTimeout())}_nextTimeout(){const e=this._queue.length/this._options.computeThrottleMaxQueueSize,t=Math.max(this._options.computeThrottleTimeout*(1-e),0);return t}_update(){if(this._timeout=null,this._queue.length){let e;for(;this._queue.length;){const t=e=this._queue.shift();this._applyOp(t)}this._updateFrequency(e[2]),this.emit("update",this._stats)}}_updateFrequency(e){const t=e-this._frequencyLastTime;Object.keys(this._stats).forEach(n=>{this._updateFrequencyFor(n,t,e)}),this._frequencyLastTime=e}_updateFrequencyFor(e,t,n){const r=this._frequencyAccumulators[e]||0;this._frequencyAccumulators[e]=0;const i=t||1,s=r/i*1e3;let a=this._movingAverages[e];a||(a=this._movingAverages[e]={});const l=this._options.movingAverageIntervals;for(var u=0;u<l.length;u++){var c=l[u],h=a[c];h||(h=a[c]=o(c)),h.push(n,s)}}_applyOp(e){const t=e[0],n=e[1];if("number"!=typeof n)throw new Error("invalid increment number:",n);let r;r=this._stats.hasOwnProperty(t)?this._stats[t]:this._stats[t]=i(0),this._stats[t]=r.plus(n),this._frequencyAccumulators[t]||(this._frequencyAccumulators[t]=0),this._frequencyAccumulators[t]+=n}}e.exports=a},function(e,t,n){"use strict";const r=n(466);e.exports=(e=>{const t=r(e);return t.delete=t.remove,t})},function(e,t,n){"use strict";const r=n(1065);t=e.exports=n(1066),t.mount=r.mount,t.unmount=r.unmount},function(e,t,n){"use strict";const r=n(12),i=n(102),o=n(283),s=o.PROTOCOL,a=o.PING_LENGTH,l=n(4),u=l("libp2p-ping");function c(e){e.handle(s,(e,t)=>{const n=i({timeout:0}),o=n.handshake;function s(){o.read(a,(e,t)=>{if(!0!==e)return e?u.error(e):(o.write(t),s())})}r(t,n,t),s()})}function h(e){e.unhandle(s)}u.error=l("libp2p-ping:error"),t=e.exports,t.mount=c,t.unmount=h},function(e,t,n){"use strict";const r=n(6).EventEmitter,i=n(12),o=n(88),s=n(102),a=n(283),l=n(1067),u=l.rnd,c=n(4),h=c("libp2p-ping");h.error=c("libp2p-ping:error");const f=a.PROTOCOL,p=a.PING_LENGTH;class d extends r{constructor(e,t){super(),this._stopped=!1,this.peer=t,this.swarm=e}start(){h("dialing %s to %s",f,this.peer.id.toB58String()),this.swarm.dial(this.peer,f,(e,t)=>{if(e)return this.emit("error",e);const n=s({timeout:0});this.shake=n.handshake,i(n,t,n);const r=this;function o(){let e=new Date,t=u(p);r.shake.write(t),r.shake.read(p,(n,i)=>{let s=new Date;if(n||!t.equals(i)){const e=new Error("Received wrong ping ack");return r.emit("error",e)}r.emit("ping",s-e),r._stopped||o()})}o()})}stop(){!this._stopped&&this.shake&&(this._stopped=!0,i(o(),this.shake.rest()))}}e.exports=d},function(e,t,n){"use strict";const r=n(51),i=n(283);t=e.exports,t.rnd=(e=>(e||(e=i.PING_LENGTH),r.randomBytes(e)))},function(e,t,n){"use strict";const r=n(6),i=n(1069).default,o=n(4)("libp2p:connection-manager"),s={maxPeers:1/0,minPeers:0,maxData:1/0,maxSentData:1/0,maxReceivedData:1/0,maxEventLoopDelay:1/0,pollInterval:2e3,movingAverageInterval:6e4,defaultPeerValue:1};class a extends r{constructor(e,t){if(super(),this._libp2p=e,this._options=Object.assign({},s,t),this._options.maxPeersPerProtocol=u(this._options.maxPeersPerProtocol),o("options: %j",this._options),this._stats=e.stats,t&&!this._stats)throw new Error("No libp2p.stats");this._peerValues=new Map,this._peers=new Map,this._peerProtocols=new Map,this._peerCountPerProtocol=new Map,this._onStatsUpdate=this._onStatsUpdate.bind(this),this._onPeerConnect=this._onPeerConnect.bind(this),this._onPeerDisconnect=this._onPeerDisconnect.bind(this),this._libp2p.isStarted()?this._onceStarted():this._libp2p.once("start",this._onceStarted.bind(this))}start(){this._stats.on("update",this._onStatsUpdate),this._libp2p.on("connection:start",this._onPeerConnect),this._libp2p.on("connection:end",this._onPeerDisconnect),this._latencyMonitor=new i({dataEmitIntervalMs:this._options.pollInterval}),this._onLatencyMeasure=this._onLatencyMeasure.bind(this),this._latencyMonitor.on("data",this._onLatencyMeasure)}stop(){this._stats.removeListener("update",this._onStatsUpdate),this._libp2p.removeListener("connection:start",this._onPeerConnect),this._libp2p.removeListener("connection:end",this._onPeerDisconnect),this._latencyMonitor.removeListener("data",this._onLatencyMeasure)}setPeerValue(e,t){if(t<0||t>1)throw new Error("value should be a number between 0 and 1");e.toB58String&&(e=e.toB58String()),this._peerValues.set(e,t)}_onceStarted(){this._peerId=this._libp2p.peerInfo.id.toB58String()}_onStatsUpdate(){const e=this._stats.global.movingAverages,t=e.dataReceived[this._options.movingAverageInterval].movingAverage();this._checkLimit("maxReceivedData",t);const n=e.dataSent[this._options.movingAverageInterval].movingAverage();this._checkLimit("maxSentData",n);const r=t+n;this._checkLimit("maxData",r),o("stats update",r)}_onPeerConnect(e){const t=e.id.toB58String();o("%s: connected to %s",this._peerId,t),this._peerValues.set(t,this._options.defaultPeerValue),this._peers.set(t,e),this.emit("connected",t),this._checkLimit("maxPeers",this._peers.size),c(e).forEach(e=>{const n=this._peerCountPerProtocol[e];n||(this._peerCountPerProtocol[e]=0),this._peerCountPerProtocol[e]++;let r=this._peerProtocols[t];r||(r=this._peerProtocols[t]=new Set),r.add(e),this._checkProtocolMaxPeersLimit(e,this._peerCountPerProtocol[e])})}_onPeerDisconnect(e){const t=e.id.toB58String();o("%s: disconnected from %s",this._peerId,t),this._peerValues.delete(t),this._peers.delete(t);const n=this._peerProtocols[t];n&&Array.from(n).forEach(e=>{const t=this._peerCountPerProtocol[e];t&&this._peerCountPerProtocol[e]--}),this.emit("disconnected",t)}_onLatencyMeasure(e){this._checkLimit("maxEventLoopDelay",e.avgMs)}_checkLimit(e,t){const n=this._options[e];o("checking limit of %s. current value: %d of %d",e,t,n),t>n&&(o("%s: limit exceeded: %s, %d",this._peerId,e,t),this.emit("limit:exceeded",e,t),this._maybeDisconnectOne())}_checkProtocolMaxPeersLimit(e,t){o("checking protocol limit. current value of %s is %d",e,t);const n=this._options.maxPeersPerProtocol[e];t>n&&(o("%s: protocol max peers limit exceeded: %s, %d",this._peerId,e,t),this.emit("limit:exceeded",e,t),this._maybeDisconnectOne())}_maybeDisconnectOne(){if(this._options.minPeers<this._peerValues.size){const e=Array.from(this._peerValues).sort(l);o("%s: sorted peer values: %j",this._peerId,e);const t=e[0];if(t){const e=t[0];o("%s: lowest value peer is %s",this._peerId,e),o("%s: forcing disconnection from %j",this._peerId,e),this._disconnectPeer(e)}}}_disconnectPeer(e){o("preemptively disconnecting peer",e),this.emit("%s: disconnect:preemptive",this._peerId,e);const t=this._peers.get(e);this._libp2p.hangUp(t,e=>{e&&this.emit("error",e)})}}function l(e,t){return e[1]-t[1]}function u(e){return e||(e={}),Object.keys(e).forEach(t=>{const n=e[t];delete e[t],e[t.toLowerCase()]=n}),e}function c(e){const t=new Set;return e.multiaddrs.forEach(e=>{e.protos().map(h).forEach(e=>{t.add(e)})}),Array.from(t)}function h(e){return e.name.toLowerCase()}e.exports=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=n(1070).default},function(e,t,n){"use strict";(function(e){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=n(6),o=f(i),s=n(476),a=f(s),l=n(148),u=f(l),c=n(1096),h=f(c);function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function m(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var g=n(481)("latency-monitor:LatencyMonitor"),y=function(t){function n(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=t.latencyCheckIntervalMs,i=t.dataEmitIntervalMs,o=t.asyncTestFn,s=t.latencyRandomPercentage;p(this,n);var l=d(this,(n.__proto__||Object.getPrototypeOf(n)).call(this)),u=l;return u.latencyCheckIntervalMs=r||500,u.latencyRandomPercentage=s||10,u._latecyCheckMultiply=u.latencyRandomPercentage/100*2*u.latencyCheckIntervalMs,u._latecyCheckSubtract=u._latecyCheckMultiply/2,u.dataEmitIntervalMs=null===i||0===i?void 0:i||5e3,g("latencyCheckIntervalMs: %s dataEmitIntervalMs: %s",u.latencyCheckIntervalMs,u.dataEmitIntervalMs),u.dataEmitIntervalMs?g("Expecting ~%s events per summary",u.latencyCheckIntervalMs/u.dataEmitIntervalMs):g("Not emitting summaries"),u.asyncTestFn=o,e&&e.hrtime?(g("Using process.hrtime for timing"),u.now=e.hrtime,u.getDeltaMS=function(e){var t=u.now(e);return 1e3*t[0]+t[1]/1e6}):"undefined"!=typeof window&&(0,a.default)(window,"performance.now")?(g("Using performance.now for timing"),u.now=window.performance.now.bind(window.performance),u.getDeltaMS=function(e){return Math.round(u.now()-e)}):(g("Using Date.now for timing"),u.now=Date.now,u.getDeltaMS=function(e){return u.now()-e}),u._latencyData=u._initLatencyData(),v()&&(u._visibilityChangeEmitter=new h.default,u._visibilityChangeEmitter.on("visibilityChange",function(e){e?u._startTimers():(u._emitSummary(),u._stopTimers())})),u._visibilityChangeEmitter&&!u._visibilityChangeEmitter.isVisible()||u._startTimers(),l}return m(n,t),r(n,[{key:"_startTimers",value:function e(){var t=this;this._checkLatencyID||(this._checkLatency(),this.dataEmitIntervalMs&&(this._emitIntervalID=setInterval(function(){return t._emitSummary()},this.dataEmitIntervalMs),(0,u.default)(this._emitIntervalID.unref)&&this._emitIntervalID.unref()))}},{key:"_stopTimers",value:function e(){this._checkLatencyID&&(clearTimeout(this._checkLatencyID),this._checkLatencyID=void 0),this._emitIntervalID&&(clearInterval(this._emitIntervalID),this._emitIntervalID=void 0)}},{key:"_emitSummary",value:function e(){var t=this.getSummary();t.events>0&&this.emit("data",t)}},{key:"getSummary",value:function e(){var t={events:this._latencyData.events,minMs:this._latencyData.minMs,maxMs:this._latencyData.maxMs,avgMs:this._latencyData.events?this._latencyData.totalMs/this._latencyData.events:Number.POSITIVE_INFINITY,lengthMs:this.getDeltaMS(this._latencyData.startTime)};return this._latencyData=this._initLatencyData(),g("Summary: %O",t),t}},{key:"_checkLatency",value:function e(){var t=this,n=this,r=Math.random()*n._latecyCheckMultiply-n._latecyCheckSubtract,i={deltaOffset:Math.ceil(n.latencyCheckIntervalMs+r),startTime:n.now()},o=function e(){if(t._checkLatencyID){var r=n.getDeltaMS(i.startTime)-i.deltaOffset;n._checkLatency(),n._latencyData.events++,n._latencyData.minMs=Math.min(n._latencyData.minMs,r),n._latencyData.maxMs=Math.max(n._latencyData.maxMs,r),n._latencyData.totalMs+=r,g("MS: %s Data: %O",r,n._latencyData)}};g("localData: %O",i),this._checkLatencyID=setTimeout(function(){n.asyncTestFn?(i.deltaOffset=0,i.startTime=n.now(),n.asyncTestFn(o)):(i.deltaOffset-=1,o())},i.deltaOffset),(0,u.default)(this._checkLatencyID.unref)&&this._checkLatencyID.unref()}},{key:"_initLatencyData",value:function e(){return{startTime:this.now(),minMs:Number.POSITIVE_INFINITY,maxMs:Number.NEGATIVE_INFINITY,events:0,totalMs:0}}}]),n}(o.default);function v(){return"undefined"!=typeof window}t.default=y}).call(this,n(3))},function(e,t,n){var r=n(1072),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,o=/\\(\\)?/g,s=r(function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(i,function(e,n,r,i){t.push(r?i.replace(o,"$1"):n||e)}),t});e.exports=s},function(e,t,n){var r=n(1073),i=500;function o(e){var t=r(e,function(e){return n.size===i&&n.clear(),e}),n=t.cache;return t}e.exports=o},function(e,t,n){var r=n(286),i="Expected a function";function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError(i);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=e.apply(this,r);return n.cache=o.set(i,s)||o,s};return n.cache=new(o.Cache||r),n}o.Cache=r,e.exports=o},function(e,t,n){var r=n(1075),i=n(219),o=n(287);function s(){this.size=0,this.__data__={hash:new r,map:new(o||i),string:new r}}e.exports=s},function(e,t,n){var r=n(1076),i=n(1081),o=n(1082),s=n(1083),a=n(1084);function l(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}l.prototype.clear=r,l.prototype.delete=i,l.prototype.get=o,l.prototype.has=s,l.prototype.set=a,e.exports=l},function(e,t,n){var r=n(218);function i(){this.__data__=r?r(null):{},this.size=0}e.exports=i},function(e,t,n){var r=n(148),i=n(1078),o=n(181),s=n(479),a=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,u=Function.prototype,c=Object.prototype,h=u.toString,f=c.hasOwnProperty,p=RegExp("^"+h.call(f).replace(a,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function d(e){if(!o(e)||i(e))return!1;var t=r(e)?p:l;return t.test(s(e))}e.exports=d},function(e,t,n){var r=n(1079),i=(o=/[^.]+$/.exec(r&&r.keys&&r.keys.IE_PROTO||""),o?"Symbol(src)_1."+o:""),o;function s(e){return!!i&&i in e}e.exports=s},function(e,t,n){var r=n(79),i=r["__core-js_shared__"];e.exports=i},function(e,t){function n(e,t){return null==e?void 0:e[t]}e.exports=n},function(e,t){function n(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}e.exports=n},function(e,t,n){var r=n(218),i="__lodash_hash_undefined__",o=Object.prototype,s=o.hasOwnProperty;function a(e){var t=this.__data__;if(r){var n=t[e];return n===i?void 0:n}return s.call(t,e)?t[e]:void 0}e.exports=a},function(e,t,n){var r=n(218),i=Object.prototype,o=i.hasOwnProperty;function s(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}e.exports=s},function(e,t,n){var r=n(218),i="__lodash_hash_undefined__";function o(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?i:t,this}e.exports=o},function(e,t){function n(){this.__data__=[],this.size=0}e.exports=n},function(e,t,n){var r=n(220),i=Array.prototype,o=i.splice;function s(e){var t=this.__data__,n=r(t,e);if(n<0)return!1;var i=t.length-1;return n==i?t.pop():o.call(t,n,1),--this.size,!0}e.exports=s},function(e,t,n){var r=n(220);function i(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}e.exports=i},function(e,t,n){var r=n(220);function i(e){return r(this.__data__,e)>-1}e.exports=i},function(e,t,n){var r=n(220);function i(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}e.exports=i},function(e,t,n){var r=n(221);function i(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}e.exports=i},function(e,t){function n(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}e.exports=n},function(e,t,n){var r=n(221);function i(e){return r(this,e).get(e)}e.exports=i},function(e,t,n){var r=n(221);function i(e){return r(this,e).has(e)}e.exports=i},function(e,t,n){var r=n(221);function i(e,t){var n=r(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}e.exports=i},function(e,t,n){var r=n(182),i=n(412),o=n(65),s=n(285),a=1/0,l=r?r.prototype:void 0,u=l?l.toString:void 0;function c(e){if("string"==typeof e)return e;if(o(e))return i(e,c)+"";if(s(e))return u?u.call(e):"";var t=e+"";return"0"==t&&1/e==-a?"-0":t}e.exports=c},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=n(6),o=s(i);function s(e){return e&&e.__esModule?e:{default:e}}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function u(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var c=n(481)("latency-monitor:VisibilityChangeEmitter"),h=function(e){function t(){a(this,t);var e=l(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return"undefined"==typeof document?(c('This is not a browser, no "document" found. Stopping.'),l(e)):(e._initializeVisibilityVarNames(),e._addVisibilityChangeListener(),e)}return u(t,e),r(t,[{key:"_initializeVisibilityVarNames",value:function e(){var t=void 0,n=void 0;void 0!==document.hidden?(t="hidden",n="visibilitychange"):void 0!==document.mozHidden?(t="mozHidden",n="mozvisibilitychange"):void 0!==document.msHidden?(t="msHidden",n="msvisibilitychange"):void 0!==document.webkitHidden&&(t="webkitHidden",n="webkitvisibilitychange"),this._hidden=t,this._visibilityChange=n}},{key:"_addVisibilityChangeListener",value:function e(){void 0===document.addEventListener||void 0===document[this._hidden]?c("Checking page visibility requires a browser that supports the Page Visibility API."):document.addEventListener(this._visibilityChange,this._handleVisibilityChange.bind(this),!1)}},{key:"isVisible",value:function e(){if(void 0!==this._hidden&&void 0!==document[this._hidden])return!document[this._hidden]}},{key:"_handleVisibilityChange",value:function e(){var t=!document[this._hidden];c(t?"Page Visible":"Page Hidden"),this.emit("visibilityChange",t)}}]),t}(o.default);t.default=h},function(e,t,n){var r;function i(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function o(e){function n(){if(n.enabled){var e=n,i=+new Date,o=i-(r||i);e.diff=o,e.prev=r,e.curr=i,r=i;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=n.log||t.log||console.log.bind(console);u.apply(e,s)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=i(e),"function"==typeof t.init&&t.init(n),n}function s(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,i=0;i<r;i++)n[i]&&(e=n[i].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))}function a(){t.enable("")}function l(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=o.debug=o.default=o,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(1098),t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){"use strict";const r=n(26);function i(e,t,n){n=r(n),t.forEach(r=>{e.once(r,(...r)=>{t.forEach(t=>{e.removeListener(t,n)}),n.apply(e,r)})})}e.exports.emitFirst=i},function(e,t,n){"use strict";const r=n(277),i=n(13);e.exports=(e=>{const t=e._modules.peerRouting||[];return e._dht&&t.unshift(e._dht),{findPeer:(e,n,o)=>{"function"==typeof n&&(o=n,n={}),t.length||o(i(new Error("No peer routers available"),"NO_ROUTERS_AVAILABLE"));const s=t.map(t=>r=>t.findPeer(e,n,(e,t)=>e?r(e):t&&0!==Object.keys(t).length?void r(null,t):r(i(new Error("not found"),"NOT_FOUND"),null)));r(s,(e,t)=>{if(e&&"NOT_FOUND"!==e.code)return o(e);t=t||[],o(null,t)})}}})},function(e,t,n){"use strict";const r=n(277),i=n(36),o=n(13);e.exports=(e=>{const t=e._modules.contentRouting||[];return e._dht&&t.unshift(e._dht),{findProviders:(e,n,i)=>{if("function"==typeof n?(i=n,n={}):"number"==typeof n&&(n={maxTimeout:n}),!t.length)return i(o(new Error("No content routers available"),"NO_ROUTERS_AVAILABLE"));const s=t.map(t=>r=>t.findProviders(e,n,(e,t)=>e?r(e):t&&0!==Object.keys(t).length?void r(null,t):r(o(new Error("not found"),"NOT_FOUND"),null)));r(s,(e,t)=>{if(e&&"NOT_FOUND"!==e.code)return i(e);t=t||[],i(null,t)})},provide:(e,n)=>{if(!t.length)return n(o(new Error("No content routers available"),"NO_ROUTERS_AVAILABLE"));i(t.map(t=>n=>t.provide(e,n)),n)}}})},function(e,t,n){"use strict";const r=n(47),i=n(13),{messages:o,codes:s}=n(289);e.exports=(e=>({put:(t,n,a)=>{if(!e._dht)return r(a,i(new Error(o.DHT_DISABLED),s.DHT_DISABLED));e._dht.put(t,n,a)},get:(t,n,a)=>{if("function"==typeof n&&(a=n,n={}),!e._dht)return r(a,i(new Error(o.DHT_DISABLED),s.DHT_DISABLED));e._dht.get(t,n,a)},getMany:(t,n,a,l)=>{if("function"==typeof a&&(l=a,a={}),!e._dht)return r(l,i(new Error(o.DHT_DISABLED),s.DHT_DISABLED));e._dht.getMany(t,n,a,l)}}))},function(e,t,n){"use strict";(function(t){const r=n(47),{messages:i,codes:o}=n(289),s=n(1104),a=n(13);e.exports=(e=>{const n=new s(e);return e._floodSub=n,{subscribe:(t,s,l,u)=>{if("function"==typeof s&&(u=l,l=s,s={}),!e.isStarted()&&!n.started)return r(u,a(new Error(i.NOT_STARTED_YET),o.PUBSUB_NOT_STARTED));function c(e){0===n.listenerCount(t)&&n.subscribe(t),n.on(t,l),r(e)}c(u)},unsubscribe:(t,s,l)=>{if(!e.isStarted()&&!n.started)return r(l,a(new Error(i.NOT_STARTED_YET),o.PUBSUB_NOT_STARTED));s||l?n.removeListener(t,s):n.removeAllListeners(t),0===n.listenerCount(t)&&n.unsubscribe(t),"function"==typeof l&&r(()=>l())},publish:(s,l,u)=>e.isStarted()||n.started?t.isBuffer(l)?void n.publish(s,l,u):r(u,a(new Error("data must be a Buffer"),"ERR_DATA_IS_NOT_A_BUFFER")):r(u,a(new Error(i.NOT_STARTED_YET),o.PUBSUB_NOT_STARTED)),ls:t=>{if(!e.isStarted()&&!n.started)return r(t,a(new Error(i.NOT_STARTED_YET),o.PUBSUB_NOT_STARTED));const s=Array.from(n.subscriptions);r(()=>t(null,s))},peers:(t,s)=>{if(!e.isStarted()&&!n.started)return r(s,a(new Error(i.NOT_STARTED_YET),o.PUBSUB_NOT_STARTED));"function"==typeof t&&(s=t,t=null);const l=Array.from(n.peers.values()).filter(e=>!t||e.topics.has(t)).map(e=>e.info.id.toB58String());r(()=>s(null,l))},setMaxListeners:e=>n.setMaxListeners(e)}})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(19),i=n(52),o=n(24),s=n(482),{message:a,utils:l}=n(482),u=n(1112),c=u.multicodec,h=l.ensureArray,f=n(20),p=n(59),d=()=>{};class m extends s{constructor(e){super("libp2p:floodsub",c,e),this.subscriptions=new Set}_onDial(e,t,n){super._onDial(e,t,t=>{if(t)return n(t);const r=e.id.toB58String(),i=this.peers.get(r);i&&i.isWritable&&i.sendSubscriptions(this.subscriptions),f(()=>n())})}_processConnection(e,t,n){r(t,i.decode(),r.map(e=>a.rpc.RPC.decode(e)),r.drain(t=>this._onRpc(e,t),t=>this._onConnectionEnd(e,n,t)))}_onRpc(e,t){if(!t)return;this.log("rpc from",e);const n=t.subscriptions,r=t.msgs;if(r&&r.length&&this._processRpcMessages(l.normalizeInRpcMessages(t.msgs)),n&&n.length){const t=this.peers.get(e);t&&(t.updateSubscriptions(n),this.emit("floodsub:subscription-change",t.info,t.topics,n))}}_processRpcMessages(e){e.forEach(e=>{const t=l.msgId(e.from,e.seqno);this.seenCache.has(t)||(this.seenCache.put(t),this._emitMessages(e.topicIDs,[e]),this._forwardMessages(e.topicIDs,[e]))})}_emitMessages(e,t){e.forEach(e=>{this.subscriptions.has(e)&&t.forEach(t=>{this.emit(e,t)})})}_forwardMessages(e,t){this.peers.forEach(n=>{n.isWritable&&l.anyMatch(n.topics,e)&&(n.sendMessages(l.normalizeOutRpcMessages(t)),this.log("publish msgs on topics",e,n.info.id.toB58String()))})}stop(e){super.stop(t=>{if(t)return e(t);this.subscriptions=new Set,e()})}publish(e,t,n){o(this.started,"FloodSub is not started"),n=n||d,this.log("publish",e,t),e=h(e),t=h(t);const r=this.libp2p.peerInfo.id.toB58String(),i=(t,n)=>{const i=l.randomSeqno();this.seenCache.put(l.msgId(r,i));const o={from:r,data:t,seqno:i,topicIDs:e};this._emitMessages(e,[o]),this._buildMessage(o,n)};p(t,i,(t,r)=>{if(t)return n(t);this._forwardMessages(e,r),n(null)})}subscribe(e){function t(n){if(n&&n.isWritable)return n.sendSubscriptions(e);const r=()=>{n.removeListener("connection",r),t(n)};n.on("connection",r),n.once("close",()=>n.removeListener("connection",r))}o(this.started,"FloodSub is not started"),e=h(e),e.forEach(e=>this.subscriptions.add(e)),this.peers.forEach(e=>t(e))}unsubscribe(e){function t(n){n&&n.isWritable?n.sendUnsubscriptions(e):f(t.bind(n))}this.started&&(e=h(e),e.forEach(e=>this.subscriptions.delete(e)),this.peers.forEach(e=>t(e)))}}e.exports=m},function(e,t,n){"use strict";const r=n(1106);function i(e){if(!(this instanceof i))return new i(e);e=e||{};const t=e.validity||30,n=new Map,s=r(()=>{n.forEach((e,r)=>{const i=e.validity||t,s=o(e.timestamp);s>i&&n.delete(r)})},200);this.put=((e,t,r)=>{this.has(e)||n.set(e,{value:t,timestamp:new Date,validity:r}),s()}),this.get=(e=>{if(n.has(e))return n.get(e).value;throw new Error("key does not exist")}),this.has=(e=>n.has(e))}function o(e){const t=new Date,n=t.getTime()-e.getTime();return Math.floor(n/1e3)}t=e.exports=i},function(e,t,n){(function(t){var n="Expected a function",r=NaN,i="[object Symbol]",o=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,a=/^0b[01]+$/i,l=/^0o[0-7]+$/i,u=parseInt,c="object"==typeof t&&t&&t.Object===Object&&t,h="object"==typeof self&&self&&self.Object===Object&&self,f=c||h||Function("return this")(),p=Object.prototype,d=p.toString,m=Math.max,g=Math.min,y=function(){return f.Date.now()};function v(e,t,r){var i,o,s,a,l,u,c=0,h=!1,f=!1,p=!0;if("function"!=typeof e)throw new TypeError(n);function d(t){var n=i,r=o;return i=o=void 0,c=t,a=e.apply(r,n),a}function v(e){return c=e,l=setTimeout(k,t),h?d(e):a}function b(e){var n=e-u,r=e-c,i=t-n;return f?g(i,s-r):i}function w(e){var n=e-u,r=e-c;return void 0===u||n>=t||n<0||f&&r>=s}function k(){var e=y();if(w(e))return S(e);l=setTimeout(k,b(e))}function S(e){return l=void 0,p&&i?d(e):(i=o=void 0,a)}function x(){void 0!==l&&clearTimeout(l),c=0,i=u=o=l=void 0}function C(){return void 0===l?a:S(y())}function A(){var e=y(),n=w(e);if(i=arguments,o=this,u=e,n){if(void 0===l)return v(u);if(f)return l=setTimeout(k,t),d(u)}return void 0===l&&(l=setTimeout(k,t)),a}return t=E(t)||0,_(r)&&(h=!!r.leading,f="maxWait"in r,s=f?m(E(r.maxWait)||0,t):s,p="trailing"in r?!!r.trailing:p),A.cancel=x,A.flush=C,A}function b(e,t,r){var i=!0,o=!0;if("function"!=typeof e)throw new TypeError(n);return _(r)&&(i="leading"in r?!!r.leading:i,o="trailing"in r?!!r.trailing:o),v(e,t,{leading:i,maxWait:t,trailing:o})}function _(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function w(e){return!!e&&"object"==typeof e}function k(e){return"symbol"==typeof e||w(e)&&d.call(e)==i}function E(e){if("number"==typeof e)return e;if(k(e))return r;if(_(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=_(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(o,"");var n=a.test(e);return n||l.test(e)?u(e.slice(2),n?2:8):s.test(e)?r:+e}e.exports=b}).call(this,n(8))},function(e,t,n){"use strict";const r=n(52),i=n(63),o=n(19),s=n(20),a=n(6),{RPC:l}=n(290);class u extends a{constructor(e){super(),this.info=e,this.conn=null,this.topics=new Set,this.stream=null,this._references=0}get isConnected(){return Boolean(this.conn)}get isWritable(){return Boolean(this.stream)}write(e){if(!this.isWritable){const e=this.info.id.toB58String();throw new Error("No writable connection to "+e)}this.stream.push(e)}attachConnection(e){this.conn=e,this.stream=new i,o(this.stream,r.encode(),e,o.onEnd(()=>{this.conn=null,this.stream=null,this.emit("close")})),this.emit("connection")}_sendRawSubscriptions(e,t){if(0===e.size)return;const n=[];e.forEach(e=>{n.push({subscribe:t,topicID:e})}),this.write(l.encode({subscriptions:n}))}sendSubscriptions(e){this._sendRawSubscriptions(e,!0)}sendUnsubscriptions(e){this._sendRawSubscriptions(e,!1)}sendMessages(e){this.write(l.encode({msgs:e}))}updateSubscriptions(e){e.forEach(e=>{e.subscribe?this.topics.add(e.topicID):this.topics.delete(e.topicID)})}close(e){this._references=1,this.stream&&this.stream.end(),s(()=>{this.conn=null,this.stream=null,this.emit("close"),e()})}}e.exports=u},function(e,t,n){"use strict";e.exports="\nmessage RPC {\n repeated SubOpts subscriptions = 1;\n repeated Message msgs = 2;\n\n message SubOpts {\n optional bool subscribe = 1; // subscribe or unsubcribe\n optional string topicID = 2;\n }\n\n message Message {\n optional bytes from = 1;\n optional bytes data = 2;\n optional bytes seqno = 3;\n repeated string topicIDs = 4;\n optional bytes signature = 5;\n optional bytes key = 6;\n }\n}"},function(e,t,n){"use strict";e.exports="\n// topicCID = cid(merkledag_protobuf(topicDescriptor)); (not the topic.name)\nmessage TopicDescriptor {\n optional string name = 1;\n optional AuthOpts auth = 2;\n optional EncOpts enc = 2;\n\n message AuthOpts {\n optional AuthMode mode = 1;\n repeated bytes keys = 2; // root keys to trust\n\n enum AuthMode {\n NONE = 0; // no authentication, anyone can publish\n KEY = 1; // only messages signed by keys in the topic descriptor are accepted\n WOT = 2; // web of trust, certificates can allow publisher set to grow\n }\n }\n\n message EncOpts {\n optional EncMode mode = 1;\n repeated bytes keyHashes = 2; // the hashes of the shared keys used (salted)\n\n enum EncMode {\n NONE = 0; // no encryption, anyone can read\n SHAREDKEY = 1; // messages are encrypted with shared key\n WOT = 2; // web of trust, certificates can allow publisher set to grow\n }\n }\n}"},function(e,t,n){"use strict";(function(t){const{Message:r}=n(290),i=t.from("libp2p-pubsub:");e.exports.SignPrefix=i,e.exports.signMessage=function(e,n,o){const s=t.concat([i,r.encode(n)]);e.privKey.sign(s,(t,r)=>{if(t)return o(t);o(null,{...n,signature:r,key:e.pubKey.bytes})})}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){const i=n(51),o=n(70);t=e.exports,t.randomSeqno=(()=>i.randomBytes(20)),t.msgId=((e,t)=>e+t.toString("hex")),t.anyMatch=((e,t)=>{let n;n=Array.isArray(t)?e=>t.indexOf(e)>-1:e=>t.has(e);for(let t of e)if(n(t))return!0;return!1}),t.ensureArray=(e=>Array.isArray(e)?e:[e]),t.normalizeInRpcMessages=(e=>e?e.map(e=>{const t=Object.assign({},e);return r.isBuffer(e.from)&&(t.from=o.encode(e.from)),t}):e),t.normalizeOutRpcMessage=(e=>{const t=Object.assign({},e);return("string"==typeof e.from||e.from instanceof String)&&(t.from=o.decode(e.from)),t}),t.normalizeOutRpcMessages=(e=>e?e.map(t.normalizeOutRpcMessage):e)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(4),i=r("libp2p:floodsub");i.err=r("libp2p:floodsub:error"),e.exports={log:i,multicodec:"/floodsub/1.0.0"}},function(e,t,n){"use strict";const r=n(15),i=n(31),o=n(22),s=n(13);e.exports=(e=>(function(t,n){let a;if(i.isPeerInfo(t))a=t;else if(o.isMultiaddr(t)||"string"==typeof t){if("string"==typeof t)try{t=o(t)}catch(e){return n(s(e,"ERR_INVALID_MULTIADDR"))}const l=t.getPeerId();if(!l)return n(s(new Error("peer multiaddr instance or string must include peerId"),"ERR_INVALID_MULTIADDR"));try{a=e.peerBook.get(l)}catch(e){a=new i(r.createFromB58String(l))}a.multiaddrs.add(t)}else{if(!r.isPeerId(t))return n(s(new Error(`${a} is not a valid peer type`),"ERR_INVALID_PEER_TYPE"));{const r=t.toB58String();try{a=e.peerBook.get(r)}catch(r){return e.peerRouting.findPeer(t,n)}}}n(null,a)}))},function(e,t,n){"use strict";const{struct:r,superstruct:i}=n(401),{optional:o,list:s}=r,a=i(),l=a.union([a.interface({createListener:"function",dial:"function"}),"function"]),u=a({connEncryption:o(s([a("object|function")])),connProtector:a.union(["undefined",a.interface({protect:"function"})]),contentRouting:o(s(["object"])),dht:o(a("null|function|object")),peerDiscovery:o(s([a("object|function")])),peerRouting:o(s(["object"])),streamMuxer:o(s([a("object|function")])),transport:a.intersection([[l],a.interface({length:e=>e>0||"ERROR_EMPTY"})])}),c=a({peerDiscovery:a("object",{autoDial:!0}),relay:a({enabled:"boolean",hop:o(a({enabled:"boolean",active:"boolean"},{enabled:!1,active:!1}))},{enabled:!0}),dht:a("object?",{enabled:!1,kBucketSize:20,randomWalk:{enabled:!1,queriesPerPeriod:1,interval:3e5,timeout:1e4}}),EXPERIMENTAL:a({pubsub:"boolean"},{pubsub:!1})},{}),h=a({switch:"object?",connectionManager:a("object",{minPeers:25}),datastore:"object?",peerInfo:"object",peerBook:"object?",modules:u,config:c});e.exports.validate=(e=>{const[t,n]=h.validate(e);if(t)throw new Error(`${t.message}${t.reason?" - "+t.reason:""}`);return n.config.dht.enabled&&a("function|object")(n.modules.dht),void 0===n.config.peerDiscovery.autoDial&&(n.config.peerDiscovery.autoDial=!0),n})},function(e,t,n){"use strict";const r=n(36),i=n(2);e.exports=(e=>i(t=>(t=t||function e(){},e.log("stop"),"stopped"===e.state.state()?t(new Error("Already stopped")):"running"!==e.state.state()?t(new Error("Not able to stop from state: "+e.state.state())):(e.state.stop(),e._blockService.unsetExchange(),e._bitswap.stop(),e._preload.stop(),void r([t=>e._ipns.republisher.stop(t),t=>e._mfsPreload.stop(t),t=>{const n=e.libp2p;e.libp2p=null,n.stop(t)}],n=>{e._repo.close(r=>{if(n||r)return e.emit("error",n||r),t(n||r);e.state.stopped(),e.emit("stop"),t()})})))))},function(e,t,n){"use strict";e.exports=function e(t){return()=>Boolean(t._bitswap&&t.libp2p&&t.libp2p.isStarted())}},function(e,t,n){"use strict";const r=n(483),i=n(2);e.exports=function e(t){return i((e,n)=>{"function"==typeof e&&(n=e,e={}),t.repo.version((e,t)=>{if(e)return n(e);n(null,{version:r.version,repo:t,commit:""})})})}},function(e,t,n){"use strict";const r=n(2),i=n(20),o=n(483).version;e.exports=function e(t){return r((e,n)=>{"function"==typeof e&&(n=e,e={}),i(()=>n(null,{id:t._peerInfo.id.toB58String(),publicKey:t._peerInfo.id.pubKey.bytes.toString("base64"),addresses:t._peerInfo.multiaddrs.toArray().map(e=>e.toString()).filter(e=>e.indexOf("ipfs")>=0).sort(),agentVersion:`js-ipfs/${o}`,protocolVersion:"9000"}))})}},function(e,t,n){"use strict";(function(t){const r=n(15),i=n(89),o=n(10),s=n(36),a=n(2),l=n(485),u=n(425),{DAGNode:c}=n(34),h=n(45),f=n(432),p=n(435),d=n(1121);e.exports=function e(n){return a((e,a)=>{"function"==typeof e&&(a=e,e={});const m=(e,t)=>{if(e)return n.emit("error",e),a(e);n.preStart(e=>{if(e)return n.emit("error",e),a(e);n.state.initialized(),n.emit("init"),a(null,t)})};if("uninitialized"!==n.state.state())return m(new Error("Not able to init from state: "+n.state.state()));if(n.state.init(),n.log("init"),e.repo)return n._repo=e.repo,m(null,!0);e.emptyRepo=e.emptyRepo||!1,e.bits=Number(e.bits)||2048,e.log=e.log||function(){};const g=i(l(),n._options.config);let y;o([e=>n._repo.exists(e),(i,o)=>{if(n.log("repo exists?",i),!0===i)return o(new Error("repo already exists"));e.privateKey?(n.log("using user-supplied private-key"),"object"==typeof e.privateKey?o(null,e.privateKey):r.createFromPrivKey(t.from(e.privateKey,"base64"),o)):(e.log(`generating ${e.bits}-bit RSA keypair...`,!1),n.log("generating peer id: %s bits",e.bits),r.create({bits:e.bits},o))},(t,r)=>{n.log("identity generated"),g.Identity={PeerID:t.toB58String(),PrivKey:t.privKey.bytes.toString("base64")},y=t.privKey,e.pass&&(g.Keychain=u.generateOptions()),e.log("done"),e.log("peer identity: "+g.Identity.PeerID),n._repo.init(g,r)},(e,t)=>n._repo.open(t),t=>{if(n.log("repo opened"),e.pass){n.log("creating keychain");const r=Object.assign({passPhrase:e.pass},g.Keychain);n._keychain=new u(n._repo.keys,r),n._keychain.importPeer("self",{privKey:y},t)}else t(null,!0)},(e,t)=>{const r=new p(n._repo);n._ipns=new f(r,n._repo.datastore,n._peerInfo,n._keychain,n._options),t(null,!0)},(t,r)=>{if(e.emptyRepo)return r(null,!0);const i=[e=>{o([e=>c.create(new h("directory").marshal(),e),(e,t)=>n.dag.put(e,{version:0,format:"dag-pb",hashAlg:"sha2-256"},t),(e,t)=>n._ipns.initializeKeyspace(y,e.toBaseEncodedString(),t)],e)}];"function"==typeof d&&i.push(t=>d(n,e.log,t)),n.log("adding assets"),s(i,e=>{e?r(e):r(null,!0)})}],m)})}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports="message Data {\n enum DataType {\n Raw = 0;\n Directory = 1;\n File = 2;\n Metadata = 3;\n Symlink = 4;\n HAMTShard = 5;\n }\n\n required DataType Type = 1;\n optional bytes Data = 2;\n optional uint64 filesize = 3;\n repeated uint64 blocksizes = 4;\n\n optional uint64 hashType = 5;\n optional uint64 fanout = 6;\n}\n\nmessage Metadata {\n optional string MimeType = 1;\n}"},function(e,t){},function(e,t,n){"use strict";const r=n(485),i=n(72).IPFS.matches,o=n(2);function s(e){try{return i(e)}catch(e){return!1}}function a(e){return new Error(`${e} is not a valid Multiaddr`)}e.exports=function e(t){return{list:o(e=>{t._repo.config.get((t,n)=>{if(t)return e(t);e(null,{Peers:n.Bootstrap})})}),add:o((e,n,i)=>{if("function"==typeof n&&(i=n,n={default:!1}),e&&!s(e))return setImmediate(()=>i(a(e)));t._repo.config.get((o,s)=>{if(o)return i(o);n.default?s.Bootstrap=r().Bootstrap:e&&-1===s.Bootstrap.indexOf(e)&&s.Bootstrap.push(e),t._repo.config.set(s,t=>{if(t)return i(t);i(null,{Peers:n.default?r().Bootstrap:[e]})})})}),rm:o((e,n,r)=>{if("function"==typeof n&&(r=n,n={all:!1}),e&&!s(e))return setImmediate(()=>r(a(e)));t._repo.config.get((i,o)=>{if(i)return r(i);n.all?o.Bootstrap=[]:o.Bootstrap=o.Bootstrap.filter(t=>t!==e),t._repo.config.set(o,t=>{if(t)return r(t);const i=[];!n.all&&e&&i.push(e),r(null,{Peers:i})})})})}}},function(e,t,n){"use strict";const r=n(2);e.exports=function e(t){return{get:r((e,n)=>("function"==typeof e&&(n=e,e=void 0),t._repo.config.get(e,n))),set:r((e,n,r)=>{t._repo.config.set(e,n,r)}),replace:r((e,n)=>{t._repo.config.set(e,n)})}}},function(e,t,n){"use strict";const r=n(114),i=n(56),o=n(9),s=n(10),a=n(20),l=n(2),u=n(13);function c(e){return o.isCID(e)?e:new o(e)}e.exports=function e(t){return{get:l((e,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};try{e=c(e)}catch(e){return a(()=>r(u(e,"ERR_INVALID_CID")))}!1!==n.preload&&t._preload(e),t._blockService.get(e,r)}),put:l((e,n,a)=>{if(a=a||function e(){},"function"==typeof n&&(a=n,n={}),n=n||{},Array.isArray(e))return a(new Error("Array is not supported"));s([t=>{if(r.isBlock(e))return t(null,e);if(n.cid&&o.isCID(n.cid))return t(null,new r(e,n.cid));const s=n.mhtype||"sha2-256",a=n.format||"dag-pb";let l;l=null==n.version?"sha2-256"===s&&"dag-pb"===a?0:1:n.version,i(e,s,(n,i)=>{if(n)return t(n);let s;try{s=new o(l,a,i)}catch(n){return t(n)}t(null,new r(e,s))})},(e,r)=>t._blockService.put(e,i=>{if(i)return r(i);!1!==n.preload&&t._preload(e.cid),r(null,e)})],a)}),rm:l((e,n)=>{try{e=c(e)}catch(e){return a(()=>n(u(e,"ERR_INVALID_CID")))}t._blockService.delete(e,n)}),stat:l((e,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};try{e=c(e)}catch(e){return a(()=>r(u(e,"ERR_INVALID_CID")))}!1!==n.preload&&t._preload(e),t._blockService.get(e,(t,n)=>{if(t)return r(t);r(null,{key:e.toString(),size:n.data.length})})})}}},function(e,t,n){"use strict";(function(t){const r=n(10),i=n(36),o=n(20),s=n(2),a=n(34),l=a.DAGNode,u=a.DAGLink,c=n(9),h=n(27),f=n(45),p=n(13);function d(e,n){if("string"==typeof e)return"base58"!==n&&n?t.from(e,n):e;if(t.isBuffer(e))return e;if(c.isCID(e))return e.buffer;throw new Error("unsupported multihash")}function m(e,t,n){switch(t){case"json":return g(e,n);case"protobuf":return y(e,n);default:n(new Error(`unkown encoding: ${t}`))}}function g(e,n){let r,i;try{const o=JSON.parse(e.toString());i=(o.Links||[]).map(e=>new u(e.Name||e.name,e.Size||e.size,h.fromB58String(e.Hash||e.hash||e.multihash))),r=t.from(o.Data)}catch(e){return n(new Error("failed to parse JSON: "+e))}l.create(r,i,n)}function y(e,t){a.util.deserialize(e,t)}e.exports=function e(n){function h(e){return(t,i,o)=>{"function"==typeof i&&(o=i,i={}),i=i||{},r([e=>{n.object.get(t,i,e)},(t,r)=>{e(t,(e,t)=>{if(e)return r(e);n._ipld.put(t,{version:0,hashAlg:"sha2-256",format:"dag-pb"},(e,t)=>{if(e)return r(e);!1!==i.preload&&n._preload(t),r(null,t)})})}],o)}}return{new:s((e,r,i)=>{let s;if("function"==typeof e&&(i=e,e=void 0,r={}),"function"==typeof r&&(i=r,r={}),r=r||{},e){if("unixfs-dir"!==e)return o(()=>i(new Error("unknown template")));s=new f("directory").marshal()}else s=t.alloc(0);l.create(s,(e,t)=>{if(e)return i(e);n._ipld.put(t,{version:0,hashAlg:"sha2-256",format:"dag-pb"},(e,t)=>{if(e)return i(e);!1!==r.preload&&n._preload(t),i(null,t)})})}),put:s((e,r,i)=>{"function"==typeof r&&(i=r,r={}),r=r||{};const o=r.enc;let s;if(t.isBuffer(e))o?m(e,o,(e,t)=>{if(e)return i(e);s=t,a()}):l.create(e,(e,t)=>{if(e)return i(e);s=t,a()});else if(l.isDAGNode(e))s=e,a();else{if("object"!=typeof e)return i(new Error("obj not recognized"));l.create(e.Data,e.Links,(e,t)=>{if(e)return i(e);s=t,a()})}function a(){n._ipld.put(s,{version:0,hashAlg:"sha2-256",format:"dag-pb"},(e,t)=>{if(e)return i(e);!1!==r.preload&&n._preload(t),i(null,t)})}}),get:s((e,t,r)=>{let i,s;"function"==typeof t&&(r=t,t={}),t=t||{};try{i=d(e,t.enc)}catch(e){return o(()=>r(p(e,"ERR_INVALID_MULTIHASH")))}try{s=new c(i)}catch(e){return o(()=>r(p(e,"ERR_INVALID_CID")))}1===t.cidVersion&&(s=s.toV1()),!1!==t.preload&&n._preload(s),n._ipld.get(s,(e,t)=>{if(e)return r(e);r(null,t.value)})}),data:s((e,t,r)=>{"function"==typeof t&&(r=t,t={}),n.object.get(e,t,(e,t)=>{if(e)return r(e);r(null,t.data)})}),links:s((e,t,r)=>{"function"==typeof t&&(r=t,t={}),n.object.get(e,t,(e,t)=>{if(e)return r(e);r(null,t.links)})}),stat:s((e,t,o)=>{"function"==typeof t&&(o=t,t={}),t=t||{},r([r=>n.object.get(e,t,r),(e,t)=>{i({serialized:t=>a.util.serialize(e,t),cid:t=>a.util.cid(e,t),node:t=>t(null,e)},t)}],(e,t)=>{if(e)return o(e);const n=t.serialized.length,r=t.node.links.reduce((e,t)=>e+t.size,0);o(null,{Hash:t.cid.toBaseEncodedString(),NumLinks:t.node.links.length,BlockSize:n,LinksSize:n-t.node.data.length,DataSize:t.node.data.length,CumulativeSize:n+r})})}),patch:s({addLink(e,t,n,r){h((e,n)=>{l.addLink(e,t,n)})(e,n,r)},rmLink(e,t,n,r){h((e,n)=>{u.isDAGLink(t)?t=t._name:t&&t.name&&(t=t.name),l.rmLink(e,t,n)})(e,n,r)},appendData(e,n,r,i){h((e,r)=>{const i=t.concat([e.data,n]);l.create(i,e.links,r)})(e,r,i)},setData(e,t,n,r){h((e,n)=>{l.create(t,e.links,n)})(e,n,r)}})}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(9),o=n(19),s=n(59),a=n(20),l=n(1127),u=n(13);e.exports=function e(n){return{put:r((e,t,r)=>{if("function"==typeof t&&(r=t,t={}),t=t||{},t.cid&&(t.format||t.hashAlg))return r(new Error("Can't put dag node. Please provide either `cid` OR `format` and `hashAlg` options."));if(t.format&&!t.hashAlg||!t.format&&t.hashAlg)return r(new Error("Can't put dag node. Please provide `format` AND `hashAlg` options."));const i={format:"dag-cbor",hashAlg:"sha2-256"};t=t.cid?t:Object.assign({},i,t),n._ipld.put(e,t,(e,i)=>{if(e)return r(e);!1!==t.preload&&n._preload(i),r(null,i)})}),get:r((e,r,o,s)=>{if("function"==typeof r&&(s=r,r=void 0),"function"==typeof o&&(s=o,"string"!=typeof r?(o=r,r=null):o={}),o=o||{},"string"==typeof e){const t=e.split("/");try{e=new i(t[0])}catch(e){return a(()=>s(u(e,"ERR_INVALID_CID")))}t.shift(),r=t.length>0?t.join("/"):"/"}else if(t.isBuffer(e))try{e=new i(e)}catch(e){return a(()=>s(u(e,"ERR_INVALID_CID")))}!1!==o.preload&&n._preload(e),n._ipld.get(e,r,o,s)}),tree:r((e,t,r,s)=>{if("object"==typeof t&&(s=r,r=t,t=void 0),"function"==typeof t&&(s=t,t=void 0),"function"==typeof r&&(s=r,r={}),r=r||{},"string"==typeof e){const n=e.split("/");try{e=new i(n[0])}catch(e){return a(()=>s(u(e,"ERR_INVALID_CID")))}n.shift(),t=n.length>0?n.join("/"):void 0}!1!==r.preload&&n._preload(e),o(n._ipld.treeStream(e,t,r),o.collect(s))}),_getRecursive:r((e,t,r)=>{let o;"function"==typeof t&&(r=t,t={}),t=t||{};try{o=new i(e)}catch(e){return a(()=>r(u(e,"ERR_INVALID_CID")))}n.dag.get(o,"",t,(e,i)=>{if(e)return r(e);s(i.value.links,(e,r)=>{n.dag._getRecursive(e.cid,t,r)},(e,t)=>{if(e)return r(e);r(null,l([i.value,t]))})})})}}}).call(this,n(0).Buffer)},function(e,t){function n(e){if(!Array.isArray(e))throw new Error("expected an array");for(var t=[],r=e.length,i=0;i<r;i++){var o=e[i];Array.isArray(o)?t.push.apply(t,n(o)):t.push(o)}return t}e.exports=n},function(e,t,n){"use strict";const r=n(2),i=n(163).OFFLINE_ERROR;e.exports=function e(t){return{peers:r((e,n)=>{if("function"==typeof e&&(n=e,e={}),e=e||{},!t.isOnline())return n(new Error(i));const r=e.v||e.verbose,o=[];Object.values(t._peerInfoBook.getAll()).forEach(e=>{const t=e.isConnected();if(!t)return;const n={addr:t,peer:e.id};r&&(n.latency="unknown"),o.push(n)}),n(null,o)}),addrs:r(e=>{if(!t.isOnline())return e(new Error(i));const n=Object.values(t._peerInfoBook.getAll());e(null,n)}),localAddrs:r(e=>{if(!t.isOnline())return e(new Error(i));e(null,t.libp2p.peerInfo.multiaddrs.toArray())}),connect:r((e,n)=>{if(!t.isOnline())return n(new Error(i));t.libp2p.dial(e,n)}),disconnect:r((e,n)=>{if(!t.isOnline())return n(new Error(i));t.libp2p.hangUp(e,n)}),filters:r(e=>e(new Error("Not implemented")))}}},function(e,t,n){"use strict";const r=n(2),i=n(12);e.exports=function e(t){return r((e,n,r)=>{"function"==typeof n&&(r=n,n={}),i(t.pingPullStream(e,n),i.collect(r))})}},function(e,t,n){"use strict";const r=n(4),i=n(163).OFFLINE_ERROR,o=n(15),s=n(19),a=n(63),l=r("ipfs:pingPullStream");function u(e){const t={success:!0,time:0,text:""};return Object.assign(t,e)}function c(e,t,n,r){let i,s;try{i=o.createFromB58String(n)}catch(e){return r(e)}try{s=e.peerBook.get(i)}catch(o){return l("Peer not found in peer book, trying peer routing"),t.push(u({text:`Looking up peer ${n}`})),e.peerRouting.findPeer(i,r)}r(null,s)}function h(e,t,n,r,i){e.ping(r,(e,o)=>{if(e)return i(e);let s=0,a=0;t.push(u({text:`PING ${r.id.toB58String()}`})),o.on("ping",e=>{if(t.push(u({time:e})),a+=e,s++,s>=n){const e=a/n;o.stop(),t.push(u({text:`Average latency: ${e}ms`})),t.end()}}),o.on("error",e=>{l.error(e),o.stop(),i(e)}),o.start()})}l.error=r("ipfs:pingPullStream:error"),e.exports=function e(t){return(e,n)=>{if(!t.isOnline())return s.error(new Error(i));n=Object.assign({count:10},n);const r=a();return c(t.libp2p,r,e,(e,i)=>{if(e)return l.error(e),void r.end(e);h(t.libp2p,r,n.count,i,e=>{e&&(l.error(e),r.push(u({success:!1,text:e.toString()})),r.end())})}),r}}},function(e,t,n){"use strict";const r=n(80);e.exports=function e(t){return(e,n)=>r.source(t.pingPullStream(e,n))}},function(e,t,n){"use strict";(function(t){const r=n(2),{DAGNode:i,DAGLink:o,util:s}=n(34),a=n(9),l=n(59),u=n(1133),c=n(43),h=n(36),f=n(430),p=n(10),d=n(1134),m=n(20),{Key:g}=n(28),y=n(13),v=n(60),b=n(1135),{resolvePath:_}=n(163),w=300,k=new g("/local/pins");function E(e){return new a(e).toBaseEncodedString()}function S(e){const t=`Invalid type '${e}', must be one of {direct, indirect, recursive, all}`;return y(new Error(t),"ERR_INVALID_PIN_TYPE")}e.exports=(e=>{const n=e._repo,g=e.dag,x=b(g),C={direct:"direct",recursive:"recursive",indirect:"indirect",all:"all"};let A=new Set,T=new Set;const I=()=>Array.from(A).map(e=>new a(e).buffer),j=()=>Array.from(T).map(e=>new a(e).buffer);function R(e){const t=new Set;f(j(),w,(e,n)=>{g._getRecursive(e,(e,r)=>{if(e)return n(e);l(r,(e,t)=>s.cid(e,t),(e,r)=>{if(e)return n(e);r.map(e=>e.toBaseEncodedString()).filter(e=>!T.has(e)).forEach(e=>t.add(e)),n()})})},n=>{if(n)return e(n);e(null,Array.from(t))})}function B(r){let s,a,l;c([e=>p([e=>x.storeSet(I(),e),({node:e,cid:t},n)=>o.create(C.direct,e.size,t,n),(e,t)=>{s=e,t(null)}],e),e=>p([e=>x.storeSet(j(),e),({node:e,cid:t},n)=>o.create(C.recursive,e.size,t,n),(e,t)=>{a=e,t(null)}],e),e=>i.create(t.alloc(0),(t,n)=>{if(t)return e(t);g.put(n,{version:0,hashAlg:"sha2-256",format:"dag-pb",preload:!1},e)}),e=>i.create(t.alloc(0),[s,a],(t,n)=>{if(t)return e(t);l=n,g.put(l,{version:0,hashAlg:"sha2-256",format:"dag-pb",preload:!1},(t,n)=>{t||(l.multihash=n.buffer),e(t)})}),e=>n.closed?n.open(e):e(null,null),e=>n.datastore.put(k,l.multihash,e)],(t,n)=>t?r(t):(e.log(`Flushed pins with root: ${l}`),r(null,l)))}const O={add:r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};const i=null==n.recursive||n.recursive;_(e.object,t,(e,t)=>{if(e)return r(e);l(t,(e,t)=>{const r=E(e);if(i){if(T.has(r))return t(null,r);g._getRecursive(r,{preload:n.preload},e=>e?t(e):t(null,r))}else{if(T.has(r))return t(new Error(`${r} already pinned recursively`));if(A.has(r))return t(null,r);g.get(new a(e),{preload:n.preload},e=>e?t(e):t(null,r))}},(e,t)=>{if(e)return r(e);const n=i?T:A;t.forEach(e=>n.add(e)),B((e,n)=>{if(e)return r(e);r(null,t.map(e=>({hash:e})))})})})}),rm:r((t,n,r)=>{"function"==typeof n&&(r=n),n=n||{};const i=null==n.recursive||n.recursive;if(n.cidBase&&!v.names.includes(n.cidBase))return m(()=>{r(y(new Error("invalid multibase"),"ERR_INVALID_MULTIBASE"))});_(e.object,t,(t,n)=>{if(t)return r(t);l(n,(e,t)=>{O._isPinnedWithType(e,C.all,(n,r)=>{if(n)return t(n);const{pinned:o,reason:s}=r,a=E(e);if(!o)return t(new Error(`${a} is not pinned`));switch(s){case C.recursive:return i?t(null,a):t(new Error(`${a} is pinned recursively`));case C.direct:return t(null,a);default:return t(new Error(`${a} is pinned indirectly under ${s}`))}})},(t,n)=>{if(t)return r(t);n.forEach(e=>{i&&T.has(e)?T.delete(e):A.delete(e)}),B((t,i)=>{if(t)return r(t);e.log(`Removed pins: ${n}`),r(null,n.map(e=>({hash:e})))})})})}),ls:r((t,n,r)=>{let i=C.all;if("function"==typeof t&&(r=t,n={},t=null),"function"==typeof n&&(r=n),t&&t.type&&(n=t,t=null),n=n||{},n.type){if("string"!=typeof n.type)return m(()=>r(S(n.type)));i=n.type.toLowerCase()}if(!Object.keys(C).includes(i))return m(()=>r(S(i)));if(t)p([n=>_(e.object,t,n),(e,t)=>u(e,(e,t)=>O._isPinnedWithType(e,C.all,t),t),(e,t)=>{if(e=e.filter(e=>e.pinned).map(({key:e,reason:t})=>{switch(t){case C.direct:case C.recursive:return{hash:e,type:t};default:return{hash:e,type:`${C.indirect} through ${t}`}}}),!e.length)return t(new Error("Path is not pinned"));t(null,e)}],r);else{let e=[];i!==C.direct&&i!==C.all||(e=e.concat(Array.from(A).map(e=>({type:C.direct,hash:e})))),i!==C.recursive&&i!==C.all||(e=e.concat(Array.from(T).map(e=>({type:C.recursive,hash:e})))),i===C.indirect||i===C.all?R((t,n)=>t?r(t):(e=e.filter(({hash:e})=>!n.includes(e)||n.includes(e)&&!A.has(e)).concat(n.map(e=>({type:C.indirect,hash:e}))),r(null,e))):r(null,e)}}),_isPinnedWithType:r((e,t,n)=>{const r=E(e),{recursive:i,direct:o,all:s}=C;return t!==i&&t!==s||!T.has(r)?t===i?n(null,{key:r,pinned:!1}):t!==o&&t!==s||!A.has(r)?t===o?n(null,{key:r,pinned:!1}):void d(j().map(e=>new a(e)),w,(e,t)=>{p([t=>g.get(e,"",{preload:!1},t),(e,t)=>t(null,e.value),(e,t)=>x.hasDescendant(e,r,t)],t)},(e,t)=>n(e,{key:r,pinned:Boolean(t),reason:t})):n(null,{key:r,pinned:!0,reason:o}):n(null,{key:r,pinned:!0,reason:i})}),_load:r(t=>{p([e=>n.closed?n.datastore.open(e):e(null,null),(e,t)=>n.datastore.has(k,t),(e,t)=>e?t():t(new Error("No pins to load")),e=>n.datastore.get(k,e),(e,t)=>{g.get(new a(e),"",{preload:!1},t)}],(n,r)=>{if(n)return"No pins to load"===n.message?(e.log("No pins to load"),t()):t(n);h([e=>x.loadSet(r.value,C.recursive,e),e=>x.loadSet(r.value,C.direct,e)],(n,r)=>{if(n)return t(n);const[i,o]=r;return A=new Set(o.map(E)),T=new Set(i.map(E)),e.log("Loaded pins from the datastore"),t(null)})})})};return O})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(467),i=a(r),o=n(109),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default,1),e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(156),i=h(r),o=n(157),s=h(o),a=n(273),l=h(a),u=n(426),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}t.default=(0,l.default)((0,s.default)(i.default,c.default)),e.exports=t.default},function(e,t,n){"use strict";(function(r){const i=n(27),o=n(9),s=n(57),a=n(1136),l=n(35),{DAGNode:u,DAGLink:c}=n(34),h=n(1137),f=n(201),p=n(1139),d="QmdfTbBqBPQ7VNxZEYEj14VmRuZBkqFbiwReogJgS1zR1n",m=i.fromB58String(d),g=256,y=8192,v=s(p);function b(e){return new o(e).toBaseEncodedString()}function _(e){const t=e.data,n=l.decode(t),r=l.decode.bytes;if(r<=0)throw new Error("Invalid Set header length");if(r+n>t.length)throw new Error("Impossibly large set header length");const i=t.slice(r,n+r),o=v.Set.decode(i);if(1!==o.version)throw new Error(`Unsupported Set version: ${o.version}`);if(o.fanout>e.links.length)throw new Error("Impossibly large fanout");return{header:o,data:t.slice(n+r)}}function w(e,t){const n=r.alloc(4);n.writeUInt32LE(e,0);const i=r.concat([n,r.from(b(t))]);return a(i.toString("binary"))}t=e.exports=function(e){const t={hasDescendant:(t,n,i)=>{const s={};return(o.isCID(n)||r.isBuffer(n))&&(n=b(n)),a(t,i);function a(t,r){h(t.links,({cid:t},r)=>{const i=b(t);return i===n?r(null,!0):i in s?r(null,!1):(s[i]=!0,void e.get(t,"",{preload:!1},(e,t)=>{if(e)return r(e);a(t.value,r)}))},r)}},storeSet:(n,i)=>{const s=n.map(e=>(("string"==typeof e||r.isBuffer(e))&&(e=new o(e)),{key:e,data:null}));t.storeItems(s,(t,n)=>{if(t)return i(t);e.put(n,{version:0,format:"dag-pb",hashAlg:"sha2-256",preload:!1},(e,t)=>{if(e)return i(e,t);i(null,{node:n,cid:t})})})},storeItems:(t,n)=>{return i(t,0,n);function i(t,n,o){const s=v.Set.encode({version:1,fanout:g,seed:n}),a=r.concat([r.from(l.encode(s.length)),s]),h=[];for(let e=0;e<g;e++)h.push(new c("",1,m));if(t.length<=y){const e=t.map(e=>({link:new c("",1,e.key),data:e.data||r.alloc(0)})).sort((e,t)=>r.compare(e.link.cid.buffer,t.link.cid.buffer)),n=h.concat(e.map(e=>e.link)),i=r.concat([a].concat(e.map(e=>e.data)));u.create(i,n,(e,t)=>e?o(e):o(null,t))}else{const e=t.reduce((e,t)=>{const r=w(n,t.key)%g;return e[r]=r in e?e[r].concat([t]):[t],e},{});f(e,(e,t,r)=>{i(e,n+1,(e,n)=>p(e,n,t,r))},e=>{if(e)return o(e);u.create(a,h,(e,t)=>e?o(e):o(null,t))})}function p(t,n,r,i){if(t)return i(t);const o={version:0,hashAlg:"sha2-256",format:"dag-pb",preload:!1};e.put(n,o,(e,t)=>{if(e)return i(e);h[r]=new c("",n.size,t),i(null)})}}},loadSet:(n,r,i)=>{const o=n.links.find(e=>e.name===r);if(!o)return i(new Error("No link found with name "+r));e.get(o.cid,"",{preload:!1},(e,n)=>{if(e)return i(e);const r=[],o=e=>r.push(e.cid.buffer);t.walkItems(n.value,o,e=>e?i(e):i(null,r))})},walkItems:(n,r,i)=>{let o;try{o=_(n)}catch(e){return i(e)}f(n.links,(n,i,s)=>{if(i<o.header.fanout){const i=n.cid.buffer;if(!m.equals(i))return e.get(i,"",{preload:!1},(e,n)=>{if(e)return s(e);t.walkItems(n.value,r,s)})}else r(n,i,o.data);s(null)},i)}};return t}}).call(this,n(0).Buffer)},function(e,t){function n(e){for(var t=n.BASE,r=0,i=e.length;r<i;r++)t^=e.charCodeAt(r),t+=(t<<1)+(t<<4)+(t<<7)+(t<<8)+(t<<24);return t>>>0}n.BASE=2166136261,e.exports=n},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(1138),i=a(r),o=n(109),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)(i.default,1),e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(157),i=u(r),o=n(273),s=u(o),a=n(156),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)((0,i.default)(Boolean,l.default)),e.exports=t.default},function(e,t,n){"use strict";e.exports='\n syntax = "proto2";\n\n package ipfs.pin;\n\n option go_package = "pb";\n\n message Set {\n optional uint32 version = 1;\n optional uint32 fanout = 2;\n optional fixed32 seed = 3;\n }\n'},function(e,t,n){"use strict";e.exports=(e=>({add:n(486)(e),addFromFs:n(1142)(e),addFromStream:n(1144)(e),addFromURL:n(1145)(e),addPullStream:n(1147)(e),addReadableStream:n(1178)(e),cat:n(1179)(e),catPullStream:n(1180)(e),catReadableStream:n(1187)(e),get:n(1188)(e),getPullStream:n(1189)(e),getReadableStream:n(1190)(e),ls:n(1191)(e),lsPullStream:n(1192)(e),lsReadableStream:n(1193)(e)}))},function(e,t,n){var r=n(188),i=n(71),o=n(40),s=n(33);e.exports=function(e){var t=r(),n=s(function(n,r){if(n)return t.resolve(i(n));t.resolve(o(r.sort(e)))});return function(e){return n(e),t}}},function(e,t,n){"use strict";e.exports=(e=>n(1143)(e))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((...e)=>{const t=e.pop();t(new Error("not available in the browser"))}))},function(e,t,n){"use strict";e.exports=(e=>n(486)(e))},function(e,t,n){"use strict";(function(t){const{URL:r}=n(191),i=n(1146);e.exports=(e=>async(n,o,s)=>{let a;"function"==typeof o&&(s=o,o={});try{const l=new r(n),u=await i(n);if(!u.ok)throw new Error("unexpected status code: "+u.status);const c=t.from(await u.arrayBuffer()),h=decodeURIComponent(l.pathname.split("/").pop());a=await e.add({content:c,path:h},o)}catch(e){if(s)return s(e);throw e}return s&&s(null,a),a})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=fetch},function(e,t,n){"use strict";(function(t){const r=n(487),i=n(19),o=n(69),s=n(10),a=n(128),l=n(164).isSource,u=n(9),{parseChunkerString:c}=n(226),h="wrapper/";function f(){}function p(e,n,r,i){r=r||{};let o=new u(e.multihash);1===r.cidVersion&&(o=o.toV1()),s([t=>r.onlyHash?t(null,e):n.object.get(e.multihash,Object.assign({},r,{preload:!1}),t),(n,i)=>{const s=o.toBaseEncodedString();let a=n.size;t.isBuffer(n)&&(a=n.length),i(null,{path:r.wrapWithDirectory?e.path.substring(h.length):e.path||s,hash:s,size:a})}],i)}function d(e,n){return Array.isArray(e)||(e=[e]),e.map(e=>{if(t.isBuffer(e)&&(e={path:"",content:i.values([e])}),a.readable(e)&&(e={path:"",content:o.source(e)}),l(e)&&(e={path:"",content:e}),e&&e.content&&"function"!=typeof e.content&&(t.isBuffer(e.content)&&(e.content=i.values([e.content])),a.readable(e.content)&&(e.content=o.source(e.content))),n.wrapWithDirectory&&!e.path)throw new Error("Must provide a path when wrapping with a directory");return n.wrapWithDirectory&&(e.path=h+e.path),e})}function m(e,t,n){const r=n.wrapWithDirectory?""===e.path:!e.path.includes("/"),i=r&&!n.onlyHash&&!1!==n.preload;return i&&t._preload(e.hash),e}function g(e,t,n,r){const i=!("pin"in n)||n.pin,o=!e.path.includes("/"),s=i&&o&&!n.onlyHash&&!n.hashAlg;if(s)return t.pin.add(e.hash,{preload:!1},t=>r(t,e));r(null,e)}e.exports=function(e){return function t(n){let o;n=n||{};try{o=c(n.chunker)}catch(e){return i.map(()=>{throw e})}const s=Object.assign({},{shardSplitThreshold:e._options.EXPERIMENTAL.sharding?1e3:1/0},n,o);s.hashAlg&&1!==s.cidVersion&&(s.cidVersion=1);let a=0;const l=s.progress||f,u=e=>{a+=e,l(a)};return s.progress=u,i(i.map(e=>d(e,s)),i.flatten(),r(e._ipld,s),i.asyncMap((t,n)=>p(t,e,s,n)),i.map(t=>m(t,e,s)),i.asyncMap((t,n)=>g(t,e,s,n)))}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(488),i=n(12),o=n(66),s=n(223),a=n(63),l=n(24),u=n(20),c=n(1150),h=n(1161),f=n(1173),p={chunker:"fixed",rawLeaves:!1,hashOnly:!1,cidVersion:0,hash:null,leafType:"file",hashAlg:"sha2-256"};e.exports=function(e,n){const d=Object.assign({},p,n);d.cidVersion=d.cidVersion||0,d.cidVersion>0&&void 0===n.rawLeaves&&(d.rawLeaves=!0),n&&void 0!==n.hash&&void 0===n.rawLeaves&&(d.rawLeaves=!0);const m=f[d.chunker];l(m,"Unknkown chunker named "+d.chunker);let g=0;const y=[],v={sink:s((e,t)=>{g+=e.length,e.forEach(e=>v.source.push(e)),u(t)},null,1,e=>v.source.end(e)),source:a()},b=c(m,e,d),_=h(e,d),w=_.stream(),k=r(()=>{});return i(v,k,b,o(e=>(g--,g||t.nextTick(()=>{for(;y.length;)y.shift()()}),e)),w),{sink:v.sink,source:w.source,flush:E};function E(e){function t(){_.flush((t,n)=>{if(t)return w.source.end(t),void e(t);k.resume(),e(null,n)})}k.pause(),g?y.push(t):t()}}}).call(this,n(3))},function(e,t){e.exports=function(e){var t=!1,n=0;return function(){if(n=!0,!t){for(t=!0;n;)n=!1,e();t=!1}}}},function(e,t,n){"use strict";const r=n(24),i=n(1151),o=n(1152),s={flat:n(1156),balanced:n(1157),trickle:n(1159)},a={strategy:"balanced",highWaterMark:100,reduceSingleLeafToSelf:!0};e.exports=function(e,t,n){r(e,"Missing chunker creator function"),r(t,"Missing IPLD");const l=Object.assign({},a,n),u=l.strategy,c=s[u];r(c,"Unknown importer build strategy name: "+u);const h=o(e,t,c,l);return i(h,t,l)}},function(e,t,n){"use strict";const r=n(63),i=n(223);e.exports=function e(t,n,o){const s=r(),a=i(t(s),null,o.highWaterMark,e=>s.end(e));return{source:s,sink:a}}},function(e,t,n){"use strict";(function(t){const r=n(1153),i=n(45),o=n(12),s=n(40),a=n(33),l=n(186),u=n(165),c=n(36),h=n(10),f=n(291),p=n(224),d=n(1155),{DAGNode:m}=n(34),g={chunkerOptions:{maxChunkSize:262144,avgChunkSize:262144},rawLeaves:!1,hashAlg:"sha2-256",leafType:"file",cidVersion:0,progress:()=>{}};e.exports=function e(n,y,v,b){const _=r({},g,b);return _.progress="function"==typeof _.progress?_.progress:g.progress,function(e){return function(t,n){c(t.map(t=>n=>{if(!t.content)return w(t,(t,r)=>{if(t)return n(t);r&&e.push(r),n()});k(t,(t,r)=>{if(t)return n(t);r&&e.push(r),n()})}),n)}};function w(e,t){const n=new i("directory");h([e=>m.create(n.marshal(),[],e),(e,t)=>p(e,y,_,t)],(n,r)=>{if(n)return t(n);t(null,{path:e.path,multihash:r.cid.buffer,size:r.node.size})})}function k(e,r){if(t.isBuffer(e.content)&&(e.content=s([e.content])),"function"!=typeof e.content)return r(new Error("invalid content"));const c=v(d(e,y,_),_);let g,b;try{g=n(_.chunkerOptions)}catch(e){return r(e)}let w=0;o(e.content,g,l(e=>{_.progress(e.length)}),f((e,t)=>{h([t=>{if(_.rawLeaves)return t(null,{size:e.length,leafSize:e.length,data:e});const n=new i(_.leafType,e);m.create(n.marshal(),[],(e,r)=>{if(e)return t(e);t(null,{size:r.size,leafSize:n.fileSize(),data:r})})},(e,t)=>{p(e.data,y,_,(n,r)=>{if(n)return t(n);t(null,{size:e.size,leafSize:e.leafSize,data:r.node,multihash:r.cid.buffer,path:e.path,name:""})})}],t)}),u(function e(t){w++,b&&this.queue(b),b=t},function e(){b&&(1===w&&(b.single=!0),this.queue(b)),this.queue(null)}),c,a((e,t)=>{e?r(e):r(null,t[0])}))}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){
/*!
* @description Recursive object extending
* @author Viacheslav Lotsmanov <lotsmanov89@gmail.com>
* @license MIT
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2018 Viacheslav Lotsmanov
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
* the Software, and to permit persons to whom the Software is furnished to do so,
* subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
* FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
* COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
* IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
* CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
function n(e){return e instanceof t||e instanceof Date||e instanceof RegExp}function r(e){if(e instanceof t){var n=t.alloc?t.alloc(e.length):new t(e.length);return e.copy(n),n}if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);throw new Error("Unexpected situation")}function i(e){var t=[];return e.forEach(function(e,o){"object"==typeof e&&null!==e?Array.isArray(e)?t[o]=i(e):n(e)?t[o]=r(e):t[o]=s({},e):t[o]=e}),t}function o(e,t){return"__proto__"===t?void 0:e[t]}var s=e.exports=function(){if(arguments.length<1||"object"!=typeof arguments[0])return!1;if(arguments.length<2)return arguments[0];var e=arguments[0],t=Array.prototype.slice.call(arguments,1),a,l,u;return t.forEach(function(t){"object"!=typeof t||null===t||Array.isArray(t)||Object.keys(t).forEach(function(u){return l=o(e,u),a=o(t,u),a===e?void 0:"object"!=typeof a||null===a?void(e[u]=a):Array.isArray(a)?void(e[u]=i(a)):n(a)?void(e[u]=r(a)):"object"!=typeof l||null===l||Array.isArray(l)?void(e[u]=s({},a)):void(e[u]=s(l,a))})}),e}}).call(this,n(0).Buffer)},function(e,t){e.exports=function(e){var t=!1,n=0;return function(){if(n=!0,!t){for(t=!0;n;)n=!1,e();t=!1}}}},function(e,t,n){"use strict";const r=n(10),i=n(34),o=n(45),s=n(224),a=i.DAGLink,l=i.DAGNode;e.exports=function e(t,n,i){return function(e,u){if(1===e.length&&e[0].single&&i.reduceSingleLeafToSelf){const n=e[0];return u(null,{size:n.size,leafSize:n.leafSize,multihash:n.multihash,path:t.path,name:n.name})}const c=new o("file"),h=e.map(e=>(c.addBlockSize(e.leafSize),new a(e.name,e.size,e.multihash)));r([e=>l.create(c.marshal(),h,e),(e,t)=>s(e,n,i,t)],(e,n)=>{if(e)return u(e);u(null,{size:n.node.size,leafSize:c.fileSize(),multihash:n.cid.buffer,path:t.path,name:""})})}}},function(e,t,n){"use strict";const r=n(12),i=n(74),o=n(33),s=n(63),a=n(214),l=n(292);e.exports=function(e,t){const n=a(),u=n.source,c=s();return r(u,l(1/0),i(e),o((e,t)=>{e?c.end(e):1===t.length?(c.push(t[0]),c.end()):t.length>1?c.end(new Error("expected a maximum of 1 roots and got "+t.length)):c.end()})),{sink:n.sink,source:c}}},function(e,t,n){"use strict";const r=n(1158),i={maxChildrenPerNode:174};e.exports=function(e,t){const n=Object.assign({},i,t);return r(e,n)}},function(e,t,n){"use strict";const r=n(12),i=n(40),o=n(74),s=n(33),a=n(63),l=n(214),u=n(292);e.exports=function e(t,n){const c=l(),h=c.source,f=a();function p(e,a){let l=e;function c(e,t){e?a(e):t.length>1?p(t,a):a(null,t)}Array.isArray(l)&&(l=i(l)),r(l,u(n.maxChildrenPerNode),o(t),s(c))}return p(h,(e,t)=>{e?f.end(e):1===t.length?(f.push(t[0]),f.end()):t.length>1?f.end(new Error("expected a maximum of 1 roots and got "+t.length)):f.end()}),{sink:c.sink,source:f}}},function(e,t,n){"use strict";const r=n(1160),i={maxChildrenPerNode:174,layerRepeat:4};e.exports=function(e,t){const n=Object.assign({},i,t);return r(e,n)}},function(e,t,n){"use strict";const r=n(12),i=n(74),o=n(33),s=n(63),a=n(292),l=n(214),u=n(165),c=n(223),h=n(488);e.exports=function e(t,n){const f=l(),p=s(),d=h(()=>{});let m=0;return r(f.source,d,g(0,-1),a(1/0),i(t),o((e,t)=>{e?p.end(e):1===t.length?(p.push(t[0]),p.end()):t.length>1?p.end(new Error("expected a maximum of 1 roots and got "+t.length)):p.end()})),{sink:f.sink,source:p};function g(e,l){let h=0,f=0,p,y=!1;const v=s();return{source:v,sink:c(b,null,1,w)};function b(n,l){let c=!1;const h=n[0];f&&!p&&(p=s(),r(p,g(e+1,f-1),u(function(e){this.queue(e)},function(e){e?this.emit("error",e):(c||(c=!0,m++,d.pause()),this.queue(null))}),a(1/0),i(t),o((e,t)=>{m--,e?v.end(e):(t.forEach(e=>{v.push(e)}),_())}))),p?p.push(h):(v.push(h),_()),l()}function _(){p=null,h++,(0===f&&h===n.maxChildrenPerNode||f>0&&h===n.layerRepeat)&&(h=0,f++),(!y&&l>=0&&f>l||y&&!m)&&(y=!0,v.end()),m||d.resume()}function w(e){e?v.end(e):p?y||(y=!0,p.end()):v.end()}}}},function(e,t,n){"use strict";(function(t){const r=n(122),i=n(201),o=n(10),s=n(106),a=n(223),l=n(63),u=n(1162),c=n(1163),h=n(293),f=n(1172);e.exports=d;const p={wrap:!1,shardSplitThreshold:1e3,onlyHash:!1};function d(e,n){const d=Object.assign({},p,n),m=s(v,1);let g=_(),y=u({path:"",root:!0,dir:!0,dirty:!1,flat:!0},d);return{flush:k,stream:b};function v(e,t){const n=e.args.concat(function(){e.cb.apply(null,arguments),t()});e.fn.apply(null,n)}function b(){return g}function _(){const e=a(n,null,1,i),t=l();return{sink:e,source:t};function n(e,n){r(e,(e,n)=>{m.push({fn:w,args:[e],cb:r=>{r?n(r):(t.push(e),n())}})},n)}function i(e){k(n=>{t.end(n||e)})}}function w(e,t){const n=f(e.path||"");let r=y;const s=n.length-1;let a="";i(n,(t,n,i)=>{a&&(a+="/"),a+=t;const l=n===s;r.dirty=!0,r.multihash=null,r.size=null,l?o([n=>r.put(t,e,n),e=>c(null,r,d.shardSplitThreshold,d,e),(e,t)=>{y=e,t()}],i):r.get(t,(e,n)=>{if(e)return void i(e);let o=n;o&&o instanceof h||(o=u({dir:!0,parent:r,parentKey:t,path:a,dirty:!0,flat:!0},d));const s=r;r=o,s.put(t,o,i)})},t)}function k(e){m.push({fn:E,args:["",y],cb:(t,n)=>{t?e(t):e(null,n&&n.multihash)}})}function E(e,n,r){if(n.dir){if(n.root&&n.childCount()>1&&!d.wrap)return void r(new Error("detected more than one root"));n.eachChildSeries((t,n,r)=>{E(e?e+"/"+t:t,n,r)},t=>{t?r(t):S(e,n,r)})}else t.nextTick(r)}function S(t,n,r){!n.root||d.wrap?n.dirty?(n.dirty=!1,n.flush(t,e,g.source,(e,t)=>{e?r(e):r(null,t)})):r(null,n.multihash):n.onlyChild((e,t)=>{e?r(e):r(null,t)})}}}).call(this,n(3))},function(e,t,n){"use strict";(function(t){const r=n(122),i=n(10),o=n(34),s=n(45),a=o.DAGLink,l=o.DAGNode,u=n(293),c=n(224);class h extends u{constructor(e,t){super(e,t),this._children={}}put(e,n,r){this.multihash=void 0,this.size=void 0,this._children[e]=n,t.nextTick(r)}get(e,n){t.nextTick(()=>n(null,this._children[e]))}childCount(){return Object.keys(this._children).length}directChildrenCount(){return this.childCount()}onlyChild(e){t.nextTick(()=>e(null,this._children[Object.keys(this._children)[0]]))}eachChildSeries(e,t){r(Object.keys(this._children),(t,n)=>{e(t,this._children[t],n)},t)}flush(e,t,n,r){const o=Object.keys(this._children).map(e=>{const t=this._children[e];return new a(e,t.size,t.multihash)}),u=new s("directory");i([e=>l.create(u.marshal(),o,e),(e,n)=>c(e,t,this._options,n),({cid:t,node:r},i)=>{this.multihash=t.buffer,this.size=r.size;const o={path:e,multihash:t.buffer,size:r.size};n.push(o),i(null,r)}],r)}}function f(e,t){return new h(e,t)}e.exports=f}).call(this,n(3))},function(e,t,n){"use strict";const r=n(10),i=n(225);function o(e,t,n,i,a){s(t,n,i,(s,l)=>{if(s)return void a(s);const u=l.parent;u?r([n=>{l!==t?(e&&(e.parent=l),u.put(l.parentKey,l,n)):n()},e=>{u?o(l,u,n,i,e):e(null,l)}],a):a(null,l)})}function s(e,t,n,r){e.flat&&e.directChildrenCount()>=t?a(e,n,r):r(null,e)}function a(e,t,n){const r=i({root:e.root,dir:!0,parent:e.parent,parentKey:e.parentKey,path:e.path,dirty:e.dirty,flat:!1},t);e.eachChildSeries((e,t,n)=>{r.put(e,t,n)},e=>{e?n(e):n(e,r)})}e.exports=o},function(e,t,n){"use strict";e.exports=i;var r=[""," "," "," "," "," "," "," "," "," "];function i(e,t,n){if(e+="",t-=e.length,t<=0)return e;if(n||0===n||(n=" "),n+=""," "===n&&t<10)return r[t]+e;for(var i="";1&t&&(i+=n),t>>=1,t;)n+=n;return i+e}},function(e,t,n){const r=n(1166),i=n(1167);function o(e){return e=r(e),async(t,n)=>{if(t){if(e.return)try{await e.return()}catch(e){return n(e)}return n(t)}let r;try{r=await e.next()}catch(e){return n(e)}if(r.done)return n(!0);n(null,r.value)}}o.source=o,o.transform=o.through=(e=>t=>o(e(i(t)))),o.duplex=(e=>({sink:o.sink(e.sink),source:o(e.source)})),o.sink=(e=>t=>{e({[Symbol.asyncIterator](){return this},next:()=>new Promise((e,n)=>{t(null,(t,r)=>!0===t?e({done:!0,value:r}):t?n(t):void e({done:!1,value:r}))}),return:()=>new Promise((e,n)=>{t(!0,(t,r)=>{if(t&&!0!==t)return n(t);e({done:!0,value:r})})}),throw:e=>new Promise((n,r)=>{t(e,(e,t)=>{if(e&&!0!==e)return r(e);n({done:!0,value:t})})})})}),e.exports=o},function(e,t){e.exports=function e(t){if(t){if("function"==typeof t[Symbol.iterator])return t[Symbol.iterator]();if("function"==typeof t[Symbol.asyncIterator])return t[Symbol.asyncIterator]();if("function"==typeof t.next)return t}throw new Error("argument is not an iterator or iterable")}},function(e,t,n){const r=n(19);e.exports=(e=>(async function*(){let t;const n=e=>{t=(()=>new Promise((t,n)=>{e(null,(e,r)=>!0===e?t({end:e}):e?n(e):void t({data:r}))}))};for(r(e,n);;){const{end:e,data:n}=await t();if(e)break;yield n}})())},function(e,t,n){"use strict";const r=n(294);e.exports=function e(t){return new r(t)},e.exports.isBucket=r.isBucket},function(e,t,n){"use strict";const r=7;function i(e,t){return e+o(t)}function o(e){let t=e;return t-=t>>1&1431655765,t=(858993459&t)+(t>>2&858993459),16843009*(t+(t>>4)&252645135)>>24}function s(e,t){return e[0]-t[0]}function a(e){return e[1]}e.exports=class e{constructor(){this._bitArrays=[],this._data=[],this._length=0,this._changedLength=!1,this._changedData=!1}set(e,t){let n=this._internalPositionFor(e,!1);if(void 0===t)-1!==n&&(this._unsetInternalPos(n),this._unsetBit(e),this._changedLength=!0,this._changedData=!0);else{let r=!1;-1===n?(n=this._data.length,this._setBit(e),this._changedData=!0):r=!0,this._setInternalPos(n,e,t,r),this._changedLength=!0}}unset(e){this.set(e,void 0)}get(e){this._sortData();const t=this._internalPositionFor(e,!0);if(-1!==t)return this._data[t][1]}push(e){return this.set(this.length,e),this.length}get length(){if(this._sortData(),this._changedLength){const e=this._data[this._data.length-1];this._length=e?e[0]+1:0,this._changedLength=!1}return this._length}forEach(e){let t=0;for(;t<this.length;)e(this.get(t),t,this),t++}map(e){let t=0,n=new Array(this.length);for(;t<this.length;)n[t]=e(this.get(t),t,this),t++;return n}reduce(e,t){let n=0,r=t;for(;n<this.length;){const t=this.get(n);r=e(r,t,n),n++}return r}find(e){let t=0,n,r;for(;t<this.length&&!n;)r=this.get(t),n=e(r),t++;return n?r:void 0}_internalPositionFor(e,t){const n=this._bytePosFor(e,t);if(n>=this._bitArrays.length)return-1;const r=this._bitArrays[n],s=e-7*n,a=(r&1<<s)>0;if(!a)return-1;const l=this._bitArrays.slice(0,n).reduce(i,0),u=~(4294967295<<s+1),c=o(r&u),h=l+c-1;return h}_bytePosFor(e,t){const n=Math.floor(e/7),r=n+1;for(;!t&&this._bitArrays.length<r;)this._bitArrays.push(0);return n}_setBit(e){const t=this._bytePosFor(e,!1);this._bitArrays[t]|=1<<e-7*t}_unsetBit(e){const t=this._bytePosFor(e,!1);this._bitArrays[t]&=~(1<<e-7*t)}_setInternalPos(e,t,n,r){const i=this._data,o=[t,n];if(r)this._sortData(),i[e]=o;else{if(i.length)if(i[i.length-1][0]>=t)i.push(o);else if(i[0][0]<=t)i.unshift(o);else{const e=Math.round(i.length/2);this._data=i.slice(0,e).concat(o).concat(i.slice(e))}else this._data.push(o);this._changedData=!0,this._changedLength=!0}}_unsetInternalPos(e){this._data.splice(e,1)}_sortData(){this._changedData&&this._data.sort(s),this._changedData=!1}bitField(){const e=[];let t=8,n=0,r=0,i;const o=this._bitArrays.slice();for(;o.length||n;){0===n&&(i=o.shift(),n=7);const s=Math.min(n,t),a=~(255<<s),l=i&a;r|=l<<8-t,i>>>=s,n-=s,t-=s,t&&(n||o.length)||(e.push(r),r=0,t=8)}for(var s=e.length-1;s>0;s--){const t=e[s];if(0!==t)break;e.pop()}return e}compactArray(){return this._sortData(),this._data.map(a)}}},function(e,t,n){"use strict";(function(t){const r=n(1171);e.exports=function e(t){return function e(n){return n instanceof i?n:new i(n,t)}};class i{constructor(e,n){if("string"!=typeof e&&!t.isBuffer(e))throw new Error("can only hash strings or buffers");this._value=e,this._hashFn=n,this._depth=-1,this._availableBits=0,this._currentBufferIndex=0,this._buffers=[]}async take(e){let t=e;for(;this._availableBits<t;)await this._produceMoreBits();let n=0;for(;t>0;){const e=this._buffers[this._currentBufferIndex],r=Math.min(e.availableBits(),t),i=e.take(r);n=(n<<r)+i,t-=r,this._availableBits-=r,0===e.availableBits()&&this._currentBufferIndex++}return n}untake(e){let t=e;for(;t>0;){const e=this._buffers[this._currentBufferIndex],n=Math.min(e.totalBits()-e.availableBits(),t);e.untake(n),t-=n,this._availableBits+=n,this._currentBufferIndex>0&&e.totalBits()===e.availableBits()&&(this._depth--,this._currentBufferIndex--)}}async _produceMoreBits(){this._depth++;const e=this._depth?this._value+this._depth:this._value,t=await this._hashFn(e),n=new r(t);this._buffers.push(n),this._availableBits+=n.availableBits()}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=[255,254,252,248,240,224,192,128],i=[1,3,7,15,31,63,127,255];function o(e,t,n){const r=s(t,n);return(e&r)>>>t}function s(e,t){return r[e]&i[Math.min(t+e-1,7)]}e.exports=class e{constructor(e){this._value=e,this._currentBytePos=e.length-1,this._currentBitPos=7}availableBits(){return this._currentBitPos+1+8*this._currentBytePos}totalBits(){return 8*this._value.length}take(e){let t=e,n=0;for(;t&&this._haveBits();){const e=this._value[this._currentBytePos],r=this._currentBitPos+1,i=Math.min(r,t),s=o(e,r-i,i);n=(n<<i)+s,t-=i,this._currentBitPos-=i,this._currentBitPos<0&&(this._currentBitPos=7,this._currentBytePos--)}return n}untake(e){for(this._currentBitPos+=e;this._currentBitPos>7;)this._currentBitPos-=8,this._currentBytePos+=1}_haveBits(){return this._currentBytePos>=0}}},function(e,t,n){"use strict";const r=(e="")=>(e.trim().match(/([^\\^/]|\\\/)+/g)||[]).filter(Boolean);e.exports=r},function(e,t,n){"use strict";const r={fixed:n(1174),rabin:n(1176)};e.exports=r},function(e,t,n){"use strict";(function(t){const r=n(1175),i=n(165);e.exports=(e=>{let n="number"==typeof e?e:e.maxChunkSize,o=new r,s=0,a=!1;return i(function e(t){for(o.append(t),s+=t.length;s>=n;)if(this.queue(o.slice(0,n)),a=!0,n===o.length)o=new r,s=0;else{const e=new r;e.append(o.shallowSlice(n)),o=e,s-=n}},function e(){s&&(this.queue(o.slice(0,s)),a=!0),a||this.queue(t.alloc(0)),this.queue(null)})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){var r=n(17).Duplex,i=n(14);function o(e){if(!(this instanceof o))return new o(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function e(t){this._callback&&(this._callback(t),this._callback=null)}.bind(this);this.on("pipe",function e(n){n.on("error",t)}),this.on("unpipe",function e(n){n.removeListener("error",t)})}else this.append(e);r.call(this)}i.inherits(o,r),o.prototype._offset=function e(t){var n=0,r=0,i;if(0===t)return[0,0];for(;r<this._bufs.length;r++){if(i=n+this._bufs[r].length,t<i||r==this._bufs.length-1)return[r,t-n];n=i}},o.prototype._reverseOffset=function(e){for(var t=e[0],n=e[1],r=0;r<t;r++)n+=this._bufs[r].length;return n},o.prototype.append=function e(n){var r=0;if(t.isBuffer(n))this._appendBuffer(n);else if(Array.isArray(n))for(;r<n.length;r++)this.append(n[r]);else if(n instanceof o)for(;r<n._bufs.length;r++)this.append(n._bufs[r]);else null!=n&&("number"==typeof n&&(n=n.toString()),this._appendBuffer(t.from(n)));return this},o.prototype._appendBuffer=function e(t){this._bufs.push(t),this.length+=t.length},o.prototype._write=function e(t,n,r){this._appendBuffer(t),"function"==typeof r&&r()},o.prototype._read=function e(t){if(!this.length)return this.push(null);t=Math.min(t,this.length),this.push(this.slice(0,t)),this.consume(t)},o.prototype.end=function e(t){r.prototype.end.call(this,t),this._callback&&(this._callback(null,this.slice()),this._callback=null)},o.prototype.get=function e(t){if(!(t>this.length||t<0)){var n=this._offset(t);return this._bufs[n[0]][n[1]]}},o.prototype.slice=function e(t,n){return"number"==typeof t&&t<0&&(t+=this.length),"number"==typeof n&&n<0&&(n+=this.length),this.copy(null,0,t,n)},o.prototype.copy=function e(n,r,i,o){if(("number"!=typeof i||i<0)&&(i=0),("number"!=typeof o||o>this.length)&&(o=this.length),i>=this.length)return n||t.alloc(0);if(o<=0)return n||t.alloc(0);var e=!!n,s=this._offset(i),a=o-i,l=a,u=e&&r||0,c=s[1],h,f;if(0===i&&o==this.length){if(!e)return 1===this._bufs.length?this._bufs[0]:t.concat(this._bufs,this.length);for(f=0;f<this._bufs.length;f++)this._bufs[f].copy(n,u),u+=this._bufs[f].length;return n}if(l<=this._bufs[s[0]].length-c)return e?this._bufs[s[0]].copy(n,r,c,c+l):this._bufs[s[0]].slice(c,c+l);for(e||(n=t.allocUnsafe(a)),f=s[0];f<this._bufs.length;f++){if(h=this._bufs[f].length-c,!(l>h)){this._bufs[f].copy(n,u,c,c+l);break}this._bufs[f].copy(n,u,c),u+=h,l-=h,c&&(c=0)}return n},o.prototype.shallowSlice=function e(t,n){if(t=t||0,n="number"!=typeof n?this.length:n,t<0&&(t+=this.length),n<0&&(n+=this.length),t===n)return new o;var r=this._offset(t),i=this._offset(n),s=this._bufs.slice(r[0],i[0]+1);return 0==i[1]?s.pop():s[s.length-1]=s[s.length-1].slice(0,i[1]),0!=r[1]&&(s[0]=s[0].slice(r[1])),new o(s)},o.prototype.toString=function e(t,n,r){return this.slice(n,r).toString(t)},o.prototype.consume=function e(t){for(;this._bufs.length;){if(!(t>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(t),this.length-=t;break}t-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},o.prototype.duplicate=function e(){for(var t=0,n=new o;t<this._bufs.length;t++)n.append(this._bufs[t]);return n},o.prototype._destroy=function e(t,n){this._bufs.length=0,this.length=0,n(t)},o.prototype.indexOf=function(e,n,r){if(void 0===r&&"string"==typeof n&&(r=n,n=void 0),"function"==typeof e||Array.isArray(e))throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.');if("number"==typeof e?e=t.from([e]):"string"==typeof e?e=t.from(e,r):e instanceof o?e=e.slice():t.isBuffer(e)||(e=t.from(e)),n=Number(n||0),isNaN(n)&&(n=0),n<0&&(n=this.length+n),n<0&&(n=0),0===e.length)return n>this.length?this.length:n;for(var i=this._offset(n),s=i[0],a=i[1];s<this._bufs.length;s++){for(var l=this._bufs[s];a<l.length;){var u=l.length-a;if(u>=e.length){var c=l.indexOf(e,a);if(-1!==c)return this._reverseOffset([s,c]);a=l.length-e.length+1}else{var h=this._reverseOffset([s,a]);if(this._match(h,e))return h;a++}}a=0}return-1},o.prototype._match=function(e,t){if(this.length-e<t.length)return!1;for(var n=0;n<t.length;n++)if(this.get(e+n)!==t[n])return!1;return!0},function(){var e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(var t in e)!function(t){o.prototype[t]=null===e[t]?function(e,n){return this.slice(e,e+n)[t](0,n)}:function(n){return this.slice(n,n+e[t])[t](0)}}(t)}(),e.exports=o}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(69),i=n(165);let o;e.exports=(e=>{if(!o)try{if(o=n(1177),"function"!=typeof o)throw new Error("createRabin was not a function")}catch(e){const t=new Error("Rabin chunker not available, it may have failed to install or not be supported on this platform");return i(function(){this.emit("error",t)})}let t,s,a;e.minChunkSize&&e.maxChunkSize&&e.avgChunkSize?(a=e.avgChunkSize,t=e.minChunkSize,s=e.maxChunkSize):(a=e.avgChunkSize,t=a/3,s=a+a/2);const l=Math.floor(Math.log2(a)),u=o({min:t,max:s,bits:l,window:e.window||16,polynomial:e.polynomial||"0x3DF305DFB2A805"});return r.duplex(u)})},function(e,t){},function(e,t,n){"use strict";const r=n(19),i=n(63),o=n(17).Duplex;class s extends o{constructor(e,t,n){super(Object.assign({objectMode:!0},n)),this._pullStream=e,this._pushable=t,this._waitingPullFlush=[]}_read(){this._pullStream(null,(e,t)=>{for(;this._waitingPullFlush.length;){const e=this._waitingPullFlush.shift();e()}e?e instanceof Error?this.emit("error",e):this.push(null):this.push(t)})}_write(e,t,n){this._waitingPullFlush.push(n),this._pushable.push(e)}}e.exports=function(e){return t=>{t=t||{};const n=i(),o=r(n,e.addPullStream(t)),a=new s(o,n);return a.once("finish",()=>n.end()),a}}},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(19);e.exports=function(e){return r((n,r,o)=>{"function"==typeof r&&(o=r,r={}),i(e.catPullStream(n,r),i.collect((e,n)=>{if(e)return o(e);o(null,t.concat(n))}))})}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(81),i=n(19),o=n(61),{normalizePath:s}=n(226);e.exports=function(e){return function t(n,a){if("function"==typeof n)throw new Error("You must supply an ipfsPath");a=a||{},n=s(n);const l=n.split("/"),u=l[l.length-1];!1!==a.preload&&e._preload(l[0]);const c=o.source();return i(r(n,e._ipld,a),i.filter(e=>e.path===u),i.take(1),i.collect((e,t)=>{if(e)return c.abort(e);if(!t.length)return c.abort(new Error("No such file"));const n=t[0];return n.content||"dir"!==n.type?n.content?void c.resolve(n.content):c.abort(new Error("this dag node has no content")):c.abort(new Error("this dag node is a directory"))})),c}}},function(e,t,n){"use strict";(function(t){const r=n(45),i=n(12),o=n(71),s=n(67),a=n(187),l=n(66),u=n(291),c=n(10),h={directory:n(1182),"hamt-sharded-directory":n(1183),file:n(1184),object:n(1185),raw:n(1186)};function f(e,t,n,r){return n||(n=0),n>t.maxDepth?l(d):i(u((n,r)=>"number"!=typeof n.depth?o(new Error("no depth")):n.object?r(null,m(null,n.object,n,t)):void c([t=>e.get(n.cid,t),(e,r)=>r(null,m(n.cid,e.value,n,t))],r)),a(),s(Boolean),s(e=>e.depth<=t.maxDepth));function m(t,n,i,o){return g({cid:t,node:n,name:i.name,path:i.path,pathRest:i.pathRest,dag:e,parentNode:i.parent||r,depth:i.depth,options:o})}function g({cid:e,node:t,name:n,path:r,pathRest:i,dag:s,parentNode:a,depth:l,options:u}){let c;try{c=p(t)}catch(e){return o(e)}const d=h[c];if(!d)return o(new Error("Unkown node type "+c));const m=f(s,u,l,t);return d(e,t,n,r,i,m,s,a,l,u)}}function p(e){return t.isBuffer(e)?"raw":t.isBuffer(e.data)?r.unmarshal(e.data).type:"object"}function d(e){return e}e.exports=Object.assign({createResolver:f,typeOf:p},h)}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(12),i=n(40),o=n(67),s=n(66),a=n(213);function l(e,t,n,l,u,c,h,f,p,d){const m=u[0],g={name:n,depth:p,path:l,cid:e,size:0,type:"dir"};if(d.maxDepth&&d.maxDepth<=p)return i([g]);const y=[r(i(t.links),o(e=>void 0===m||e.name===m),s(e=>({depth:p+1,size:0,name:e.name,path:l+"/"+e.name,cid:e.cid,linkName:e.name,pathRest:u.slice(1),type:"dir"})),c)];return u.length&&!d.fullPath||y.unshift(i([g])),a(y)}e.exports=l},function(e,t,n){"use strict";const r=n(61),i=n(12),o=n(71),s=n(40),a=n(67),l=n(66),u=n(213),c=n(294),h=n(225),f=n(10);function p(e,t,n,p,v,b,_,w,k,E){let S;if(w&&w.path===p||(S={name:n,depth:k,path:p,cid:e,size:0,type:"dir"}),E.maxDepth&&E.maxDepth<=k)return s([S]);if(!v.length){const e=[i(s(t.links),l(e=>{const t=e.name.substring(2),n=t?p+"/"+t:p;return{depth:t?k+1:k,name:t,path:n,cid:e.cid,pathRest:t?v.slice(1):v,parent:S||w}}),b)];return e.unshift(s([S])),u(e)}const x=r.source(),C=v[0];return f([e=>E.rootBucket?d(t.links,E.lastBucket,E.rootBucket,e):(E.rootBucket=new c({hashFn:h.hashFn}),E.hamtDepth=1,d(t.links,E.rootBucket,E.rootBucket,e)),e=>g(C,E.rootBucket,e),(e,n)=>{let r=m(e.pos);const o=y(e);o.length>E.hamtDepth&&(E.lastBucket=o[E.hamtDepth],r=m(E.lastBucket._posAtParent));const u=[i(s(t.links),l(e=>{const t=e.name.substring(0,2),n=e.name.substring(2),i=n?p+"/"+n:p;return t===r&&((!n||n===C)&&(n?(delete E.rootBucket,delete E.lastBucket,delete E.hamtDepth):E.hamtDepth++,{depth:n?k+1:k,name:n,path:i,cid:e.cid,pathRest:n?v.slice(1):v,parent:S||w}))}),a(Boolean),b)];E.fullPath&&u.unshift(s([S])),n(null,u)}],(e,t)=>{if(e)return x.resolve(o(e));x.resolve(u(t))}),x}e.exports=p;const d=(e,t,n,r)=>{Promise.all(e.map(e=>{if(2===e.name.length){const n=parseInt(e.name,16);return t._putObjectAt(n,new c({hashFn:h.hashFn},t,n))}return n.put(e.name.substring(2),!0)})).then(()=>r(),r)},m=e=>e.toString("16").toUpperCase().padStart(2,"0").substring(0,2),g=(e,t,n)=>{t._findNewBucketAndPos(e).then(e=>{n&&n(null,e)},n)},y=e=>{let t=e.bucket;const n=[];for(;t._parent;)n.push(t),t=t._parent;return n.push(t),n.reverse()}},function(e,t,n){"use strict";(function(t){const r=n(350),i=n(45),o=n(12),s=n(40),a=n(71),l=n(116),u=n(88),c=n(67),h=n(187),f=n(66),p=n(291),d=n(489);function m(e,n,i,s,a){if(s===i||0===a)return l(t.alloc(0));const u=s+a;return o(r.depthFirst({node:n,start:0,end:i},g(e,s,u)),f(y(s,u)),c(Boolean))}function g(e,n,r){let s=0;return function c({node:f}){if(t.isBuffer(f))return u();let d;try{d=i.unmarshal(f.data)}catch(e){return a(e)}const m=Boolean(d.data&&d.data.length);m&&f.links.length&&(s+=d.data.length);const g=f.links.map((e,t)=>{const n={link:e,start:s,end:s+d.blockSizes[t],size:d.blockSizes[t]};return s=n.end,n}).filter(e=>n>=e.start&&n<e.end||r>e.start&&r<=e.end||n<e.start&&r>e.end);return g.length&&(s=g[0].start),o(l(g),p((t,n)=>{e.getMany(t.map(e=>e.link.cid),(e,r)=>{if(e)return n(e);n(null,r.map((e,n)=>{const r=t[n];return{start:r.start,end:r.end,node:e,size:r.size}}))})}),h())}}function y(e,n){let r=-1;return function o({node:s,start:a,end:l}){let u;if(t.isBuffer(s))u=s;else try{const e=i.unmarshal(s.data);if(!e.data){if(e.blockSizes.length)return;return t.alloc(0)}u=e.data}catch(e){throw new Error(`Failed to unmarshal node - ${e.message}`)}if(u&&u.length){-1===r&&(r=a);const t=d(u,r,e,n);return r+=u.length,t}return t.alloc(0)}}e.exports=((e,n,r,o,c,h,f,p,d,g)=>{const y=c[0];if(void 0!==y&&y!==o)return u();let v;try{v=i.unmarshal(n.data)}catch(e){return a(e)}const b=v.fileSize();let _=g.offset,w=g.length;if(_<0)return a(new Error("Offset must be greater than or equal to 0"));if(_>b)return a(new Error("Offset must be less than the file size"));if(w<0)return a(new Error("Length must be greater than or equal to 0"));if(0===w)return l({depth:d,content:l(t.alloc(0)),name:r,path:o,cid:e,size:b,type:"file"});_||(_=0),(!w||_+w>b)&&(w=b-_);const k=m(f,n,b,_,w);return s([{depth:d,content:k,name:r,path:o,cid:e,size:b,type:"file"}])})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(9),i=n(12),o=n(40),s=n(71);e.exports=((e,t,n,a,l,u,c,h,f)=>{let p;if(l.length){const e=l[0];p=t[e];const n=a+"/"+e;if(!p)return s(new Error("not found"));const c=r.isCID(p);return i(o([{depth:f,name:e,path:n,pathRest:l.slice(1),cid:c&&p,object:!c&&p,parent:h}]),u)}return s(new Error("invalid node type"))})},function(e,t,n){"use strict";(function(t){const r=n(71),i=n(116),o=n(88),s=n(489);e.exports=((e,n,a,l,u,c,h,f,p,d)=>{const m=u[0];if(void 0!==m&&m!==l)return o();const g=n.length;let y=d.offset,v=d.length;return y<0?r(new Error("Offset must be greater than or equal to 0")):y>g?r(new Error("Offset must be less than the file size")):v<0?r(new Error("Length must be greater than or equal to 0")):0===v?i({depth:p,content:i(t.alloc(0)),cid:e,name:a,path:l,size:g,type:"raw"}):(y||(y=0),(!v||y+v>g)&&(v=g-y),i({depth:p,content:i(s(n,0,y,y+v)),cid:e,name:a,path:l,size:g,type:"raw"}))})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(80);e.exports=function(e){return(t,n)=>r.source(e.catPullStream(t,n))}},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(19);e.exports=function(e){return r((n,r,o)=>{"function"==typeof r&&(o=r,r={}),r=r||{},i(e.getPullStream(n,r),i.asyncMap((e,n)=>{e.content?i(e.content,i.collect((r,i)=>{if(r)return n(r);e.content=t.concat(i),n(null,e)})):n(null,e)}),i.collect(o))})}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(81),i=n(19),o=n(13),{normalizePath:s}=n(226);e.exports=function(e){return(t,n)=>{if(n=n||{},!1!==n.preload){let n;try{n=s(t).split("/")}catch(e){return i.error(o(e,"ERR_INVALID_PATH"))}e._preload(n[0])}return i(r(t,e._ipld,n),i.map(e=>(e.hash=e.cid.toString(),delete e.cid,e)))}}},function(e,t,n){"use strict";const r=n(19),i=n(80);e.exports=function(e){return(t,n)=>(n=n||{},i.source(r(e.getPullStream(t,n),r.map(e=>(e.content&&(e.content=i.source(e.content),e.content.pause()),e)))))}},function(e,t,n){"use strict";const r=n(2),i=n(19);e.exports=function(e){return r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{},i(e.lsPullStream(t,n),i.collect((e,t)=>{if(e)return r(e);r(null,t)}))})}},function(e,t,n){"use strict";(function(t){const r=n(81),i=n(19),{normalizePath:o}=n(226);e.exports=function(e){return function(n,s){s=s||{};const a=o(n),l=s.recursive,u=a.split("/"),c=u.length,h=l?t.Infinity:c;return s.maxDepth=s.maxDepth||h,!1!==s.preload&&e._preload(u[0]),i(r(n,e._ipld,s),i.filter(e=>l?e.depth>=c:e.depth===c),i.map(e=>(e.hash=e.cid.toString(),delete e.cid,delete e.content,e)))}}}).call(this,n(8))},function(e,t,n){"use strict";const r=n(80);e.exports=function(e){return(t,n)=>r.source(e.lsPullStream(t,n))}},function(e,t,n){"use strict";const r=n(1195);e.exports=(e=>r({ipld:e._ipld,repo:e._repo,repoOwner:e._options.repoOwner}))},function(e,t,n){"use strict";e.exports=n(1196)},function(e,t,n){"use strict";const r=n(24),i=n(2),{createLock:o}=n(73),s={ls:n(1235),stat:n(229)},a={cp:n(505),flush:n(1236),mkdir:n(297),mv:n(1237),rm:n(506)},l={write:n(1238),read:n(1239)},u={readPullStream:n(298),readReadableStream:n(1240),lsPullStream:n(296),lsReadableStream:n(1241)},c=({options:e,mfs:t,operations:n,lock:r})=>{Object.keys(n).forEach(o=>{t[o]=i(r(n[o](e)))})},h={repoOwner:!0,ipld:null,repo:null};e.exports=(e=>{const{repoOwner:t}=Object.assign({},h||{},e);r(e.ipld,"MFS requires an IPLD instance"),r(e.repo,"MFS requires an ipfs-repo instance");const n=o(t),f=e=>n.readLock(e),p=e=>n.writeLock(e),d={};return c({options:e,mfs:d,operations:s,lock:f}),c({options:e,mfs:d,operations:a,lock:p}),Object.keys(l).forEach(t=>{d[t]=i(l[t](e))}),Object.keys(u).forEach(t=>{d[t]=u[t](e)}),d})},function(e,t,n){"use strict";const r=n(186),i=e=>{let t=0;return r(e=>(t+=e.length,e),()=>{e(t)})};e.exports=i},function(e,t,n){"use strict";const r=n(1199),i=n(4)("ipfs:mfs:lock");let o;e.exports=(e=>{if(o)return o;const t=r({singleProcess:e}),n=(e,n,r,o)=>{i(`Queuing ${e} operation`),t[`${e}Lock`](()=>new Promise((t,o)=>{r.push((n,r)=>{if(i(`${e.substring(0,1).toUpperCase()}${e.substring(1)} operation callback invoked${n?" with error: "+n.message:""}`),n)return o(n);t(r)}),i(`Starting ${e} operation`),n.apply(null,r)})).then(t=>{i(`Finished ${e} operation`),o(null,t)},t=>{i(`Finished ${e} operation with error: ${t.message}`),o(t)})};return o={readLock:e=>(function(){const t=Array.from(arguments);let r=t.pop();n("read",e,t,r)}),writeLock:e=>(function(){const t=Array.from(arguments);let r=t.pop();n("write",e,t,r)})},o})},function(e,t,n){(function(t){const r=n(1200),i=n(1210),o=n(1211),{timeout:s}=n(1213),a=n(494),l={};let u;const c=(e,t)=>{if(u.isWorker)return{readLock:u.readLock(e,t),writeLock:u.writeLock(e,t)};const n=new o({concurrency:1});let r=null;return{readLock:e=>{if(r)return r.add(()=>s(e(),t.timeout));r=new o({concurrency:t.concurrency,autoStart:!1});const i=r,a=r.add(()=>s(e(),t.timeout));return n.add(()=>(i.start(),i.onIdle().then(()=>{r===i&&(r=null)}))),a},writeLock:e=>(r=null,n.add(()=>s(e(),t.timeout)))}},h={concurrency:1/0,timeout:846e5,global:t,singleProcess:!1};e.exports=((e,t)=>(t||(t={}),"object"==typeof e&&(t=e,e="lock"),e||(e="lock"),t=Object.assign({},h,t),u||(u=r(t)||i(t),u.isWorker||(u.on("requestReadLock",(e,t)=>{l[e]&&l[e].readLock(t)}),u.on("requestWriteLock",(e,t)=>{l[e]&&l[e].writeLock(t)}))),l[e]||(l[e]=c(e,t)),l[e])),e.exports.Worker=function(e,n){let r;n=n||t.Worker;try{r=new n(e)}catch(t){t.message.includes("not a constructor")&&(r=n(e))}if(!r)throw new Error("Could not create Worker from",n);return a(r),r}}).call(this,n(8))},function(e,t,n){(function(t){const r=n(6).EventEmitter,i=n(492),{WORKER_REQUEST_READ_LOCK:o,WORKER_RELEASE_READ_LOCK:s,MASTER_GRANT_READ_LOCK:a,WORKER_REQUEST_WRITE_LOCK:l,WORKER_RELEASE_WRITE_LOCK:u,MASTER_GRANT_WRITE_LOCK:c}=n(493);let h;const f=(e,t,n,r,i)=>(o,s)=>{s&&s.type===n&&e.emit(t,s.name,()=>(o.send({type:i,name:s.name,identifier:s.identifier}),new Promise(e=>{const t=n=>{n&&n.type===r&&n.identifier===s.identifier&&(o.removeListener("message",t),e())};o.on("message",t)})))},p=(e,n,r,o)=>s=>{const a=i.generate();return t.send({type:n,identifier:a,name:e}),new Promise((n,i)=>{const l=u=>{if(u&&u.type===r&&u.identifier===a){t.removeListener("message",l);let r=null;s().catch(e=>{r=e}).then(s=>{if(t.send({type:o,identifier:a,name:e}),r)return i(r);n(s)})}};t.on("message",l)})};e.exports=(e=>{try{if(h=n(1209),!Object.keys(h).length)return}catch(e){return}if(h.isMaster||e.singleProcess){const e=new r;return h.on("message",f(e,"requestReadLock",o,s,a)),h.on("message",f(e,"requestWriteLock",l,u,c)),e}return{isWorker:!0,readLock:(e,t)=>p(e,o,a,s),writeLock:(e,t)=>p(e,l,c,u)}})}).call(this,n(3))},function(e,t,n){"use strict";var r=n(228),i=n(1203),o=n(1207),s=n(1208)||0;function a(t){return r.seed(t),e.exports}function l(t){return s=t,e.exports}function u(e){return void 0!==e&&r.characters(e),r.shuffled()}function c(){return i(s)}e.exports=c,e.exports.generate=c,e.exports.seed=a,e.exports.worker=l,e.exports.characters=u,e.exports.isValid=o},function(e,t,n){"use strict";var r=1;function i(){return r=(9301*r+49297)%233280,r/233280}function o(e){r=e}e.exports={nextValue:i,seed:o}},function(e,t,n){"use strict";var r=n(1204),i=n(228),o=1459707606518,s=6,a,l;function u(e){var t="",n=Math.floor(.001*(Date.now()-o));return n===l?a++:(a=0,l=n),t+=r(s),t+=r(e),a>0&&(t+=r(a)),t+=r(n),t}e.exports=u},function(e,t,n){"use strict";var r=n(228),i=n(1205),o=n(1206);function s(e){for(var t=0,n,s="";!n;)s+=o(i,r.get(),1),n=e<Math.pow(16,t+1),t++;return s}e.exports=s},function(e,t,n){"use strict";var r="object"==typeof window&&(window.crypto||window.msCrypto),i;i=r&&r.getRandomValues?function(e){return r.getRandomValues(new Uint8Array(e))}:function(e){for(var t=[],n=0;n<e;n++)t.push(Math.floor(256*Math.random()));return t},e.exports=i},function(e,t){e.exports=function(e,t,n){var r=(2<<Math.log(t.length-1)/Math.LN2)-1,i=Math.ceil(1.6*r*n/t.length);n=+n;for(var o="";;)for(var s=e(i),a=0;a<i;a++){var l=s[a]&r;if(t[l]&&(o+=t[l],o.length===n))return o}}},function(e,t,n){"use strict";var r=n(228);function i(e){if(!e||"string"!=typeof e||e.length<6)return!1;var t=new RegExp("[^"+r.get().replace(/[|\\{}()[\]^$+*?.-]/g,"\\$&")+"]");return!t.test(e)}e.exports=i},function(e,t,n){"use strict";e.exports=0},function(e,t){},function(e,t,n){(function(t){const r=n(6).EventEmitter,i=n(492),{WORKER_REQUEST_READ_LOCK:o,WORKER_RELEASE_READ_LOCK:s,MASTER_GRANT_READ_LOCK:a,WORKER_REQUEST_WRITE_LOCK:l,WORKER_RELEASE_WRITE_LOCK:u,MASTER_GRANT_WRITE_LOCK:c}=n(493),h=n(494),f=(e,t,n,r,i)=>(o,s)=>{if(!s||!s.data||s.data.type!==n)return;const a={type:s.data.type,name:s.data.name,identifier:s.data.identifier};e.emit(t,a.name,()=>(o.postMessage({type:i,name:a.name,identifier:a.identifier}),new Promise(e=>{const t=n=>{if(!n||!n.data)return;const i={type:n.data.type,name:n.data.name,identifier:n.data.identifier};i&&i.type===r&&i.identifier===a.identifier&&(o.removeEventListener("message",t),e())};o.addEventListener("message",t)})))},p=(e,t,n,r,o)=>s=>{const a=i.generate();return e.postMessage({type:n,identifier:a,name:t}),new Promise((n,i)=>{const l=u=>{if(!u||!u.data)return;const c={type:u.data.type,identifier:u.data.identifier};if(c&&c.type===r&&c.identifier===a){let r;e.removeEventListener("message",l),s().catch(e=>{r=e}).then(s=>(e.postMessage({type:o,identifier:a,name:t}),r?i(r):n(s)))}};e.addEventListener("message",l)})},d={global:t,singleProcess:!1};e.exports=(e=>{e=Object.assign({},d,e);const t=!!e.global.document||e.singleProcess;if(t){const e=new r;return h.addEventListener("message",f(e,"requestReadLock",o,s,a)),h.addEventListener("message",f(e,"requestWriteLock",l,u,c)),e}return{isWorker:!0,readLock:(e,t)=>p(t.global,e,o,a,s),writeLock:(e,t)=>p(t.global,e,l,c,u)}})}).call(this,n(8))},function(e,t,n){"use strict";const r=n(1212);function i(e,t,n){let r=0,i=e.length;for(;i>0;){const o=i/2|0;let s=r+o;n(e[s],t)<=0?(r=++s,i-=o+1):i=o}return r}class o{constructor(){this._queue=[]}enqueue(e,t){t={priority:0,...t};const n={priority:t.priority,run:e};if(this.size&&this._queue[this.size-1].priority>=t.priority)return void this._queue.push(n);const r=i(this._queue,n,(e,t)=>t.priority-e.priority);this._queue.splice(r,0,n)}dequeue(){return this._queue.shift().run}get size(){return this._queue.length}}e.exports=class e extends r{constructor(e){if(super(),e={carryoverConcurrencyCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:o,...e},!("number"==typeof e.concurrency&&e.concurrency>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e.concurrency}\` (${typeof e.concurrency})`);if(!("number"==typeof e.intervalCap&&e.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap}\` (${typeof e.intervalCap})`);if(!(Number.isFinite(e.interval)&&e.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval}\` (${typeof e.interval})`);this._carryoverConcurrencyCount=e.carryoverConcurrencyCount,this._isIntervalIgnored=e.intervalCap===1/0||0===e.interval,this._intervalCount=0,this._intervalCap=e.intervalCap,this._interval=e.interval,this._intervalId=null,this._intervalEnd=0,this._timeoutId=null,this.queue=new e.queueClass,this._queueClass=e.queueClass,this._pendingCount=0,this._concurrency=e.concurrency,this._isPaused=!1===e.autoStart,this._resolveEmpty=(()=>{}),this._resolveIdle=(()=>{})}get _doesIntervalAllowAnother(){return this._isIntervalIgnored||this._intervalCount<this._intervalCap}get _doesConcurrentAllowAnother(){return this._pendingCount<this._concurrency}_next(){this._pendingCount--,this._tryToStartAnother()}_resolvePromises(){this._resolveEmpty(),this._resolveEmpty=(()=>{}),0===this._pendingCount&&(this._resolveIdle(),this._resolveIdle=(()=>{}))}_onResumeInterval(){this._onInterval(),this._initializeIntervalIfNeeded(),this._timeoutId=null}_intervalPaused(){const e=Date.now();if(null===this._intervalId){const t=this._intervalEnd-e;if(!(t<0))return null===this._timeoutId&&(this._timeoutId=setTimeout(()=>{this._onResumeInterval()},t)),!0;this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0}return!1}_tryToStartAnother(){if(0===this.queue.size)return clearInterval(this._intervalId),this._intervalId=null,this._resolvePromises(),!1;if(!this._isPaused){const e=!this._intervalPaused();if(this._doesIntervalAllowAnother&&this._doesConcurrentAllowAnother)return this.emit("active"),this.queue.dequeue()(),e&&this._initializeIntervalIfNeeded(),!0}return!1}_initializeIntervalIfNeeded(){this._isIntervalIgnored||null!==this._intervalId||(this._intervalId=setInterval(()=>this._onInterval(),this._interval),this._intervalEnd=Date.now()+this._interval)}_onInterval(){for(0===this._intervalCount&&0===this._pendingCount&&(clearInterval(this._intervalId),this._intervalId=null),this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0;this._tryToStartAnother(););}async add(e,t){return new Promise((n,r)=>{const i=async()=>{this._pendingCount++,this._intervalCount++;try{n(await e())}catch(e){r(e)}this._next()};this.queue.enqueue(i,t),this._tryToStartAnother()})}async addAll(e,t){return Promise.all(e.map(e=>this.add(e,t)))}start(){if(this._isPaused)for(this._isPaused=!1;this._tryToStartAnother(););}pause(){this._isPaused=!0}clear(){this.queue=new this._queueClass}async onEmpty(){if(0!==this.queue.size)return new Promise(e=>{const t=this._resolveEmpty;this._resolveEmpty=(()=>{t(),e()})})}async onIdle(){if(0!==this._pendingCount||0!==this.queue.size)return new Promise(e=>{const t=this._resolveIdle;this._resolveIdle=(()=>{t(),e()})})}get size(){return this.queue.size}get pending(){return this._pendingCount}get isPaused(){return this._isPaused}}},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,i="~";function o(){}function s(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function a(e,t,n,r,o){if("function"!=typeof n)throw new TypeError("The listener must be a function");var a=new s(n,r||e,o),l=i?i+t:t;return e._events[l]?e._events[l].fn?e._events[l]=[e._events[l],a]:e._events[l].push(a):(e._events[l]=a,e._eventsCount++),e}function l(e,t){0==--e._eventsCount?e._events=new o:delete e._events[t]}function u(){this._events=new o,this._eventsCount=0}Object.create&&(o.prototype=Object.create(null),(new o).__proto__||(i=!1)),u.prototype.eventNames=function e(){var t=[],n,o;if(0===this._eventsCount)return t;for(o in n=this._events)r.call(n,o)&&t.push(i?o.slice(1):o);return Object.getOwnPropertySymbols?t.concat(Object.getOwnPropertySymbols(n)):t},u.prototype.listeners=function e(t){var n=i?i+t:t,r=this._events[n];if(!r)return[];if(r.fn)return[r.fn];for(var o=0,s=r.length,a=new Array(s);o<s;o++)a[o]=r[o].fn;return a},u.prototype.listenerCount=function e(t){var n=i?i+t:t,r=this._events[n];return r?r.fn?1:r.length:0},u.prototype.emit=function e(t,n,r,o,s,a){var l=i?i+t:t;if(!this._events[l])return!1;var u=this._events[l],c=arguments.length,h,f;if(u.fn){switch(u.once&&this.removeListener(t,u.fn,void 0,!0),c){case 1:return u.fn.call(u.context),!0;case 2:return u.fn.call(u.context,n),!0;case 3:return u.fn.call(u.context,n,r),!0;case 4:return u.fn.call(u.context,n,r,o),!0;case 5:return u.fn.call(u.context,n,r,o,s),!0;case 6:return u.fn.call(u.context,n,r,o,s,a),!0}for(f=1,h=new Array(c-1);f<c;f++)h[f-1]=arguments[f];u.fn.apply(u.context,h)}else{var p=u.length,d;for(f=0;f<p;f++)switch(u[f].once&&this.removeListener(t,u[f].fn,void 0,!0),c){case 1:u[f].fn.call(u[f].context);break;case 2:u[f].fn.call(u[f].context,n);break;case 3:u[f].fn.call(u[f].context,n,r);break;case 4:u[f].fn.call(u[f].context,n,r,o);break;default:if(!h)for(d=1,h=new Array(c-1);d<c;d++)h[d-1]=arguments[d];u[f].fn.apply(u[f].context,h)}}return!0},u.prototype.on=function e(t,n,r){return a(this,t,n,r,!1)},u.prototype.once=function e(t,n,r){return a(this,t,n,r,!0)},u.prototype.removeListener=function e(t,n,r,o){var s=i?i+t:t;if(!this._events[s])return this;if(!n)return l(this,s),this;var a=this._events[s];if(a.fn)a.fn!==n||o&&!a.once||r&&a.context!==r||l(this,s);else{for(var u=0,c=[],h=a.length;u<h;u++)(a[u].fn!==n||o&&!a[u].once||r&&a[u].context!==r)&&c.push(a[u]);c.length?this._events[s]=1===c.length?c[0]:c:l(this,s)}return this},u.prototype.removeAllListeners=function e(t){var n;return t?(n=i?i+t:t,this._events[n]&&l(this,n)):(this._events=new o,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=i,u.EventEmitter=u,e.exports=u},function(e,t,n){"use strict";var r,i=e.exports.timeout=function(e,t){var n=new r,i;return Promise.race([e,new Promise(function(e,r){i=setTimeout(function(){r(n)},t)})]).then(function(e){return clearTimeout(i),e},function(e){throw clearTimeout(i),e})};r=e.exports.TimeoutError=function(){Error.call(this),this.stack=Error().stack,this.message="Timeout"},r.prototype=Object.create(Error.prototype),r.prototype.name="TimeoutError"},function(e,t,n){"use strict";const r=n(10),i=n(45),{DAGNode:o}=n(34),s=(e,t,n,s)=>{r([e=>o.create(new i(t).marshal(),[],e),(t,r)=>e.ipld.put(t,{version:n.cidVersion,format:n.format,hashAlg:n.hashAlg},(e,n)=>r(e,{cid:n,node:t}))],s)};e.exports=s},function(e,t,n){"use strict";(function(t){const r=n(9);e.exports=((e,n)=>(t.isBuffer(e)&&(e=new r(e)),"base58btc"===n?e.toBaseEncodedString():e.toV1().toBaseEncodedString(n)))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(74),i=e=>{let t=0;return r((n,r)=>{if(t>e)return r(!0);t+n.length>e&&(n=n.slice(0,e-t)),t+=n.length,r(null,n)})};e.exports=i},function(e,t,n){"use strict";const r=n(10),i=n(9),o=n(4)("ipfs:mfs:utils:load-node"),s=(e,t,n)=>{const s=new i(t.cid);o(`Loading DAGNode for child ${s.toBaseEncodedString()}`),r([t=>e.ipld.get(s,t),(e,t)=>t(null,{node:e.value,cid:s})],n)};e.exports=s},function(e,t,n){"use strict";const{DAGNode:r,DAGLink:i}=n(34),o=n(10),s=n(9),a=n(4)("ipfs:mfs:core:utils:remove-link"),l=n(45),{generatePath:u,updateHamtDirectory:c}=n(491),h={parent:void 0,parentCid:void 0,name:"",flush:!0,cidVersion:0,hashAlg:"sha2-256",codec:"dag-pb",shardSplitThreshold:1e3},f=(e,t,n)=>{if(t=Object.assign({},h,t),!t.parentCid)return n(new Error("No parent CID passed to removeLink"));if(!s.isCID(t.parentCid))return n(new Error("Invalid CID passed to addLink"));if(!t.parent)return a("Loading parent node",t.parentCid.toBaseEncodedString()),o([n=>e.ipld.get(t.parentCid,n),(e,t)=>t(null,e.value),(n,r)=>f(e,{...t,parent:n},r)],n);if(!t.name)return n(new Error("No child name passed to removeLink"));const r=l.unmarshal(t.parent.data);return"hamt-sharded-directory"===r.type?(a(`Removing ${t.name} from sharded directory`),d(e,t,n)):(a(`Removing link ${t.name} regular directory`),p(e,t,n))},p=(e,t,n)=>{o([e=>r.rmLink(t.parent,t.name,e),(n,r)=>{e.ipld.put(n,{version:t.cidVersion,format:t.codec,hashAlg:t.hashAlg},(e,t)=>r(e,{node:n,cid:t}))},(e,t)=>{a("Updated regular directory",e.cid.toBaseEncodedString()),t(null,e)}],n)},d=(e,t,n)=>o([n=>u(e,t.name,t.parent,n),({rootBucket:e,path:n},r)=>{e.del(t.name).then(()=>r(null,{rootBucket:e,path:n}),r)},({rootBucket:n,path:r},i)=>{m(e,r,{name:t.name,cid:t.cid,size:t.size},t,(e,t={})=>i(e,{rootBucket:n,...t}))},({rootBucket:n,node:r},i)=>c(e,r.links,n,t,i)],n),m=(e,t,n,i,s)=>{const{bucket:l,prefix:u,node:h}=t.pop(),f=h.links.find(e=>e.name.substring(0,2)===u);return f?o([s=>f.name===`${u}${n.name}`?(a(`Removing existing link ${f.name}`),o([e=>r.rmLink(h,f.name,e),(t,n)=>{e.ipld.put(t,{version:i.cidVersion,format:i.codec,hashAlg:i.hashAlg,hashOnly:!i.flush},(e,r)=>n(e,{node:t,cid:r}))},(e,t)=>{l.del(n.name).then(()=>t(null,e),t)},(t,n)=>c(e,t.node.links,l,i,n)],s)):(a(`Descending into sub-shard ${f.name} for ${u}${n.name}`),o([r=>m(e,t,n,i,r),(t,n)=>{let r=u;1===t.node.links.length&&(a(`Removing subshard for ${u}`),t.cid=t.node.links[0].cid,t.node=t.node.links[0],r=`${u}${t.node.name.substring(2)}`),a(`Updating shard ${u} with name ${r}`),g(e,l,h,u,r,t.node.size,t.cid,i,n)}],s))],s):s(new Error(`No link found with prefix ${u} for file ${n.name}`))},g=async(e,t,n,s,a,l,u,h,f)=>{o([e=>r.rmLink(n,s,e),(e,t)=>r.addLink(e,new i(a,l,u),t),(n,r)=>c(e,n.links,t,h,r)],f)};e.exports=f},function(e,t,n){"use strict";(function(t,r){const i=n(69),o=n(128),s=n(1220),a=n(164),l=n(1227),u=n(40),c=n(4)("ipfs:mfs:utils:to-pull-source"),h=n(10),f=(e,n,f)=>e?t.isBuffer(e)?(c("Content was a buffer"),n.length||0===n.length||(n.length=n.length||e.length),f(null,u([e]))):"string"==typeof e||e instanceof String?(c("Content was a path"),h([t=>n.length?t(null,{size:n.length}):l.stat(e,t),(t,r)=>{n.length=t.size,r(null,i.source(l.createReadStream(e)))}],f)):(r.Blob&&e instanceof r.Blob&&(c("Content was an HTML5 Blob"),n.length=n.length||e.size,e=s(e)),o(e)?(c("Content was a Node stream"),f(null,i.source(e))):a.isSource(e)?(c("Content was a pull-stream"),f(null,e)):void f(new Error(`Don't know how to convert ${e} into a pull stream source`))):f(new Error("paths must start with a leading /"));e.exports=f}).call(this,n(0).Buffer,n(8))},function(e,t,n){var r=n(1221),i=n(502);e.exports=function(e,t){t=t||{};var n=t.offset||0,o=t.chunkSize||1048576,s=new FileReader(e),a=r(function(t,r){if(n>=e.size)return r(null,null);s.onloadend=function e(t){var n=t.target.result;n instanceof ArrayBuffer&&(n=i(new Uint8Array(t.target.result))),r(null,n)};var a=n+o,l=e.slice(n,a);s.readAsArrayBuffer(l),n=a});return a.name=e.name,a.size=e.size,a.type=e.type,a.lastModified=e.lastModified,s.onerror=function(e){a.destroy(e)},a}},function(e,t,n){(function(t){var r=n(1222).Readable,i=n(1);e.exports=a,a.ctor=l,a.obj=u;var o=l();function s(e){return e=e.slice(),function(t,n){var r=null,i=e.length?e.shift():null;i instanceof Error&&(r=i,i=null),n(r,i)}}function a(e,t){("object"!=typeof e||Array.isArray(e))&&(t=e,e={});var n=new o(e);return n._from=Array.isArray(t)?s(t):t||c,n}function l(e,n){function o(t){if(!(this instanceof o))return new o(t);this._reading=!1,this._callback=s,this.destroyed=!1,r.call(this,t||e);var n=this,i=this._readableState.highWaterMark;function s(e,t){if(!n.destroyed){if(e)return n.destroy(e);if(null===t)return n.push(null);n._reading=!1,n.push(t)&&n._read(i)}}}return"function"==typeof e&&(n=e,e={}),e=h(e),i(o,r),o.prototype._from=n||c,o.prototype._read=function(e){this._reading||this.destroyed||(this._reading=!0,this._from(e,this._callback))},o.prototype.destroy=function(e){if(!this.destroyed){this.destroyed=!0;var n=this;t.nextTick(function(){e&&n.emit("error",e),n.emit("close")})}},o}function u(e,t){return("function"==typeof e||Array.isArray(e))&&(t=e,e={}),e=h(e),e.objectMode=!0,e.highWaterMark=16,a(e,t)}function c(){}function h(e){return e=e||{},e}}).call(this,n(3))},function(e,t,n){t=e.exports=n(497),t.Stream=t,t.Readable=t,t.Writable=n(500),t.Duplex=n(129),t.Transform=n(501),t.PassThrough=n(1226)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1225);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(501),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){},function(e,t,n){"use strict";const r=n(504);function i(e,t,n,i){r(e,t,n,(e,t)=>{if(e)return i(e);const n=t.sources.pop();i(null,{destination:n,...t})})}e.exports=i},function(e,t,n){"use strict";const r=n(295),i=n(81),o=n(12),s=n(67),a=n(66),l=n(33),u=n(4)("ipfs:mfs:utils:to-trail"),c=(e,t,n,c)=>{const h=r(t).slice(1),f=`/${h.slice(1).join("/")}`;let p=0;u(`Creating trail for path ${t} ${h}`);let d="";o(i(t,e.ipld,{fullPath:!0,maxDepth:h.length-1}),s(e=>(u(`Saw node ${e.name} for segment ${h[p]} at depth ${e.depth}`),e.name===h[p]&&(p++,!0))),a(e=>{let t="/",n=t;if(d&&(t=`${"/"===d?"":d}/${h[e.depth]}`,n=e.name),d=t,d!==f&&"dir"!==e.type)throw new Error(`cannot access ${d}: Not a directory ${f}`);return{name:n,cid:e.cid,size:e.size,type:e.type}}),l(c))};e.exports=c},function(e,t,n){"use strict";const r=n(4)("ipfs:mfs:utils:update-mfs:root"),i=n(10),o=n(9),{MFS_ROOT_KEY:s}=n(227),a=(e,t,n)=>{const a=new o(t);r(`New MFS root will be ${a.toBaseEncodedString()}`),i([t=>e.repo.datastore.put(s,a.buffer,e=>t(e))],e=>n(e,a))};e.exports=a},function(e,t,n){"use strict";const r=n(10),i=n(1232),o=n(490),s={shardSplitThreshold:1e3},a=(e,t,n,a)=>{n=Object.assign({},s,n),r([n=>e.ipld.getMany(t.map(e=>e.cid),n),(r,s)=>{let a=t.length-1;i(t,null,(i,s,l)=>{const u=r[a],c=t[a].cid;if(a--,!i)return l(null,s);o(e,{parent:u,parentCid:c,name:i.name,cid:i.cid,size:i.size,flush:n.flush,shardSplitThreshold:n.shardSplitThreshold},(e,t)=>{if(e)return l(e);l(e,{cid:t.cid,node:t.node,name:s.name,size:t.node.size})})},s)}],a)};e.exports=a},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=l;var r=n(1233),i=a(r),o=n(86),s=a(o);function a(e){return e&&e.__esModule?e:{default:e}}function l(e,t,n,r){var o=(0,s.default)(e).reverse();(0,i.default)(o,t,n,r)}e.exports=t.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=f;var r=n(201),i=h(r),o=n(58),s=h(o),a=n(183),l=h(a),u=n(37),c=h(u);function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n,r){r=(0,l.default)(r||s.default);var o=(0,c.default)(n);(0,i.default)(e,function(e,n,r){o(t,e,function(e,n){t=n,r(e)})},function(e){r(e,t)})}e.exports=t.default},function(e,t,n){"use strict";(function(t){const n=(e=1/0,n=4096)=>{let r=0;return(i,o)=>{if(i)return o&&o(i);if(r>=e){const e=!0;return o(e)}let s=n;r+s>e&&(s=e-r),r+=s,o(null,t.alloc(s,0))}};e.exports=n}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const{FILE_SEPARATOR:r}=n(73),i=n(12),o=n(33),s=n(296);e.exports=(e=>(function t(n,a,l){"function"==typeof n&&(l=n,n=r,a={}),"function"==typeof a&&(l=a,a={}),i(s(e)(n,a),o(l))}))},function(e,t,n){"use strict";const r=n(10),i=n(229),{FILE_SEPARATOR:o}=n(73),s={};e.exports=(e=>(function t(n,a,l){"function"==typeof a&&(l=a,a={}),"function"==typeof n&&(l=n,a={},n=o),n||(n=o),a=Object.assign({},s,a),r([t=>i(e)(n,a,t),(e,t)=>t()],l)}))},function(e,t,n){"use strict";const r=n(43),i=n(10),{toSources:o}=n(73),s=n(505),a=n(506),l={parents:!1,recursive:!1,flush:!0,format:"dag-pb",hashAlg:"sha2-256",shardSplitThreshold:1e3};e.exports=(e=>(function t(){let n=Array.from(arguments);const u=n.pop();Array.isArray(n[0])&&(n=n[0].concat(n.slice(1))),i([t=>o(e,n,l,t),({sources:t,options:n},i)=>{const o=t.map(e=>e.path).concat(n),l=t.slice(0,-1).map(e=>e.path).concat(Object.assign(n,{recursive:!0}));r([t=>s(e).apply(null,o.concat(t)),t=>a(e).apply(null,l.concat(t))],i)}],u)}))},function(e,t,n){"use strict";const r=n(2),i=n(10),o=n(36),s=n(43),{createLock:a,updateMfsRoot:l,addLink:u,updateTree:c,toMfsPath:h,toPathComponents:f,toPullSource:p,loadNode:d,limitStreamBytes:m,countStreamBytes:g,toTrail:y,zeros:v}=n(73),{unmarshal:b}=n(45),_=n(12),w=n(213),k=n(33),E=n(88),S=n(71),x=n(4)("ipfs:mfs:write"),C=n(40),A=n(81),T=n(487),I=n(61),j=n(9),R=n(229),B=n(297),O={offset:0,length:void 0,create:!1,truncate:!1,rawLeaves:!1,reduceSingleLeafToSelf:!1,cidVersion:0,hashAlg:"sha2-256",format:"dag-pb",parents:!1,progress:()=>{},strategy:"trickle",flush:!0,leafType:"raw",shardSplitThreshold:1e3};e.exports=function e(t){return r((e,n,r,l)=>("function"==typeof r&&(l=r,r={}),r=Object.assign({},O,r),r.offset<0?l(new Error("cannot have negative write offset")):r.length<0?l(new Error("cannot have negative byte count")):(r.length||0===r.length||(r.length=1/0),r.cidVersion=r.cidVersion||0,void i([l=>{a().readLock(a=>{i([i=>{o({source:e=>p(n,r,e),path:n=>h(t,e,n)},i)},({source:n,path:{mfsPath:r,mfsDirectory:i}},o)=>{s({mfsDirectory:e=>R(t)(i,{unsorted:!0,long:!0},(t,n)=>{t&&t.message.includes("does not exist")&&(t=null),e(t,n)}),mfsPath:e=>R(t)(r,{unsorted:!0,long:!0},(t,n)=>{t&&t.message.includes("does not exist")&&(t=null),e(t,n)})},(t,r={})=>{o(t,{source:n,path:e,mfsDirectory:r.mfsDirectory,mfsPath:r.mfsPath})})}],a)})(l)},({source:e,path:n,mfsDirectory:i,mfsPath:o},s)=>r.parents||i?r.create||o?void P(t,r,n,e,o,s):s(new Error("file does not exist")):s(new Error("directory does not exist"))],e=>l(e)))))};const P=(e,t,n,r,o,s)=>{i([t=>{if(o)return d(e,{cid:o.hash},t);t(null,null)},(n,i)=>{const{cid:o,node:s}=n||{};N(e,o,s,r,t,i)},(r,o)=>{a().writeLock(o=>{const s=f(n),a=s.pop();i([n=>R(e)(`/${s.join("/")}`,t,(e,t)=>{e&&e.message.includes("does not exist")&&(e=null),n(null,Boolean(t))}),(n,r)=>{if(n)return r();B(e)(`/${s.join("/")}`,t,r)},t=>h(e,n,t),({mfsDirectory:n,root:i},o)=>{y(e,n,t,(n,i)=>{if(n)return o(n);const s=i[i.length-1];if("dir"!==s.type)return o(new Error(`cannot write to ${s.name}: Not a directory`));e.ipld.get(s.cid,(n,l)=>{if(n)return o(n);u(e,{parent:l.value,parentCid:s.cid,name:a,cid:r.cid,size:r.size,flush:t.flush,shardSplitThreshold:t.shardSplitThreshold},(e,t)=>{if(e)return o(e);s.cid=t.cid,s.size=t.node.size,o(null,i)})})})},(n,r)=>c(e,n,t,r),({cid:t},n)=>l(e,t,n)],o)})(o)}],s)},N=(e,t,n,r,i,o)=>{let s;n?(s=b(n.data),x(`Overwriting file ${t.toBaseEncodedString()} offset ${i.offset} length ${i.length}`)):x(`Writing file offset ${i.offset} length ${i.length}`);const a=[];if(i.offset>0)if(n&&s.fileSize()>i.offset){x(`Writing first ${i.offset} bytes of original file`);const n=I.source();a.push(n),_(A(t,e.ipld,{offset:0,length:i.offset}),k((e,t)=>{if(e)return n.resolve(S(e));n.resolve(t[0].content)}))}else x(`Writing zeros for first ${i.offset} bytes`),a.push(v(i.offset));const l=I.source();a.push(_(r,m(i.length),g(r=>{if(x(`Wrote ${r} bytes`),n&&!i.truncate){const n=s.fileSize(),o=i.offset+r;n>o?(x(`Writing last ${n-o} of ${n} bytes from original file`),_(A(t,e.ipld,{offset:o}),k((e,t)=>{if(e)return l.resolve(S(e));l.resolve(t[0].content)}))):(x("Not writing last bytes from original file"),l.resolve(E()))}}))),n&&!i.truncate&&a.push(l),_(C([{path:"",content:w(a)}]),T(e.ipld,{progress:i.progress,hashAlg:i.hashAlg,cidVersion:i.cidVersion,strategy:i.strategy,rawLeaves:i.rawLeaves,reduceSingleLeafToSelf:i.reduceSingleLeafToSelf,leafType:i.leafType}),k((e,t)=>{if(e)return o(e);const n=t.pop(),r=new j(n.multihash);x(`Wrote ${r.toBaseEncodedString()}`),o(null,{cid:r,size:n.size})}))}},function(e,t,n){"use strict";(function(t){const r=n(12),i=n(33),o=n(298);e.exports=(e=>(function n(s,a,l){"function"==typeof a&&(l=a,a={}),r(o(e)(s,a),i((e,n)=>e?l(e):l(null,t.concat(n))))}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(298),i=n(80);e.exports=(e=>(function t(n,o={}){return i.source(r(e)(n,o))}))},function(e,t,n){"use strict";const r=n(296),i=n(80);e.exports=(e=>(function t(n,o={}){return i.source(r(e)(n,o))}))},function(e,t,n){"use strict";const r=n(2),i=n(20),o=n(13),s=()=>o(new Error("pubsub experiment is not enabled"),"ERR_PUBSUB_DISABLED");e.exports=function e(t){return{subscribe:(e,n,r,o)=>("function"==typeof r&&(o=r,r={}),t._options.EXPERIMENTAL.pubsub?o?void t.libp2p.pubsub.subscribe(e,r,n,o):new Promise((i,o)=>{t.libp2p.pubsub.subscribe(e,r,n,e=>{if(e)return o(e);i()})}):o?i(()=>o(s())):Promise.reject(s())),unsubscribe:(e,n,r)=>t._options.EXPERIMENTAL.pubsub?(t.libp2p.pubsub.unsubscribe(e,n),r?void i(()=>r()):Promise.resolve()):r?i(()=>r(s())):Promise.reject(s()),publish:r((e,n,r)=>{if(!t._options.EXPERIMENTAL.pubsub)return i(()=>r(s()));t.libp2p.pubsub.publish(e,n,r)}),ls:r(e=>{if(!t._options.EXPERIMENTAL.pubsub)return i(()=>e(s()));t.libp2p.pubsub.ls(e)}),peers:r((e,n)=>{if(!t._options.EXPERIMENTAL.pubsub)return i(()=>n(s()));t.libp2p.pubsub.peers(e,n)}),setMaxListeners(e){if(!t._options.EXPERIMENTAL.pubsub)throw s();t.libp2p.pubsub.setMaxListeners(e)}}}},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(1244),o=n(15),s=n(31),a=n(9),l=n(38),u=n(47),c=n(13),h=n(4),f=h("ipfs:dht");f.error=h("ipfs:dht:error"),e.exports=(e=>({get:r((n,r,i)=>{if("function"==typeof r&&(i=r,r={}),r=r||{},!t.isBuffer(n))try{n=new a(n).buffer}catch(e){return f.error(e),u(()=>i(c(e,"ERR_INVALID_CID")))}e.libp2p.dht.get(n,r,i)}),put:r((n,r,i)=>{if(!t.isBuffer(n))try{n=new a(n).buffer}catch(e){return f.error(e),u(()=>i(c(e,"ERR_INVALID_CID")))}e.libp2p.dht.put(n,r,i)}),findProvs:r((t,n,r)=>{if("function"==typeof n&&(r=n,n={}),n=n||{},"string"==typeof t)try{t=new a(t)}catch(e){return f.error(e),u(()=>r(c(e,"ERR_INVALID_CID")))}e.libp2p.contentRouting.findProviders(t,n,r)}),findPeer:r((t,n)=>{"string"==typeof t&&(t=o.createFromB58String(t)),e.libp2p.peerRouting.findPeer(t,n)}),provide:r((t,n,r)=>{Array.isArray(t)||(t=[t]),"function"==typeof n&&(r=n,n={}),n=n||{},i(t,(t,n)=>{e._repo.blocks.has(t,n)},(i,o)=>{if(i)return r(i);if(!o){const e="block(s) not found locally, cannot provide";return f.error(e),r(c(e,"ERR_BLOCK_NOT_FOUND"))}if(n.recursive)return r(c("not implemented yet","ERR_NOT_IMPLEMENTED_YET"));l(t,(t,n)=>{e.libp2p.contentRouting.provide(t,n)},r)})}),query:r((t,n)=>{if("string"==typeof t)try{t=o.createFromB58String(t)}catch(e){return f.error(e),n(e)}e.libp2p._dht.getClosestPeers(t.toBytes(),(e,t)=>{if(e)return f.error(e),n(e);n(null,t.map(e=>new s(e)))})})}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(157),i=u(r),o=n(110),s=u(o),a=n(1245),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}t.default=(0,s.default)((0,i.default)(l.default,l.default)),e.exports=t.default},function(e,t,n){"use strict";function r(e){return!e}Object.defineProperty(t,"__esModule",{value:!0}),t.default=r,e.exports=t.default},function(e,t,n){"use strict";const r=n(1247),i=n(2);e.exports=(()=>i((e,t,n)=>{if("string"!=typeof e)return n(new Error("Invalid arguments, domain must be a string"));"function"==typeof t&&(n=t,t={}),t=t||{},r(e,t,n)}))},function(e,t,n){"use strict";e.exports=((e,t,n)=>{"function"==typeof t&&(n=t,t={}),t=t||{},e=encodeURIComponent(e);let r=`https://ipfs.io/api/v0/dns?arg=${e}`;Object.keys(t).forEach(e=>{r+=`&${encodeURIComponent(e)}=${encodeURIComponent(t[e])}`}),self.fetch(r,{mode:"cors"}).then(e=>e.json()).then(e=>e.Path?n(null,e.Path):n(new Error(e.Message))).catch(e=>{n(e)})})},function(e,t,n){"use strict";const r=n(2);e.exports=function e(t){return{gen:r((e,n,r)=>{n=n||{},t._keychain.createKey(e,n.type,n.size,r)}),info:r((e,n)=>{t._keychain.findKeyByName(e,n)}),list:r(e=>{t._keychain.listKeys(e)}),rm:r((e,n)=>{t._keychain.removeKey(e,n)}),rename:r((e,n,r)=>{t._keychain.renameKey(e,n,(t,n)=>{if(t)return r(t);const i={was:e,now:n.name,id:n.id,overwrite:!1};r(null,i)})}),import:r((e,n,r,i)=>{t._keychain.importKey(e,n,r,i)}),export:r((e,n,r)=>{t._keychain.exportKey(e,n,r)})}}},function(e,t,n){"use strict";const r=n(2),i=n(55),o=n(63),s=n(508),a=n(80),l=n(13);function u(e,t){return new Promise((n,r)=>{let o;o=t.peer?e.libp2p.stats.forPeer(t.peer):t.proto?e.libp2p.stats.forProtocol(t.proto):e.libp2p.stats.global,n(o?{totalIn:o.snapshot.dataReceived,totalOut:o.snapshot.dataSent,rateIn:new i(o.movingAverages.dataReceived[6e4].movingAverage()/60),rateOut:new i(o.movingAverages.dataSent[6e4].movingAverage()/60)}:{totalIn:new i(0),totalOut:new i(0),rateIn:new i(0),rateOut:new i(0)})})}e.exports=function e(t){const i=e=>{e=e||{};let n=null,r=o(!0,()=>{n&&clearInterval(n)});return e.poll?s(e.interval||"1s",(i,o)=>{if(i)return r.end(l(i,"ERR_INVALID_POLL_INTERVAL"));n=setInterval(()=>{u(t,e).then(e=>r.push(e)).catch(e=>r.end(e))},o)}):u(t,e).then(e=>{r.push(e),r.end()}).catch(e=>r.end(e)),r.source};return{bitswap:n(507)(t).stat,repo:n(484)(t).stat,bw:r((e,n)=>{"function"==typeof e&&(n=e,e={}),e=e||{},u(t,e).then(e=>n(null,e)).catch(e=>n(e))}),bwReadableStream:e=>a.source(i(e)),bwPullStream:i}}},function(e,t,n){"use strict";const r=n(2),i=n(200),o=n(20),s=n(347),a=n(9),{cidToString:l}=n(1251);e.exports=(e=>{return r((e,n,r)=>{if("function"==typeof n&&(r=n,n={}),n=n||{},!i.path(e))return o(()=>r(new Error("invalid argument")));if(!i.ipfsPath(e))return o(()=>r(new Error("resolve non-IPFS names is not implemented")));const s=e.split("/"),u=new a(s[2]);if(3===s.length)return o(()=>r(null,`/ipfs/${l(u,{base:n.cidBase})}`));const c=s.slice(3).join("/");t(u,c,(e,t)=>{if(e)return r(e);const{cid:i,remainderPath:o}=t;r(null,`/ipfs/${l(i,{base:n.cidBase})}${o?"/"+o:""}`)})});function t(t,n,r){let i,o;s(r=>{e.block.get(t,(s,a)=>{if(s)return r(s);const l=e._ipld.resolvers[t.codec];if(!l)return r(new Error(`No resolver found for codec "${t.codec}"`));l.resolver.resolve(a.data,n,(e,t)=>{if(e)return r(e);i=t.value,o=t.remainderPath,r()})})},()=>{if(i&&i["/"])t=new a(i["/"]),n=o;else{if(!a.isCID(i))return!0;t=i,n=o}return!n||"/"===n},e=>{if(e)return r(e);r(null,{cid:t,remainderPath:n})})}})},function(e,t,n){"use strict";const r=n(9);t.cidToString=((e,t)=>{if(t=t||{},t.base=t.base||null,t.upgrade=!1!==t.upgrade,r.isCID(e)||(e=new r(e)),0===e.version&&t.base&&"base58btc"!==t.base){if(!t.upgrade)return e.toString();e=e.toV1()}return e.toBaseEncodedString(t.base)})},function(e,t,n){"use strict";const r=n(4),i=n(2),o=n(10),s=n(36),a=n(508),l=n(51),u=n(13),c=r("ipfs:name");c.error=r("ipfs:name:error");const h=n(1253),f=n(163),p=n(433),d=(e,t,n)=>{if("self"===t)return n(null,e._peerInfo.id.privKey);const r=e._options.pass;o([n=>e._keychain.exportKey(t,r,n),(e,t)=>l.keys.import(e,r,t)],(e,t)=>e?(c.error(e),n(u(e,"ERR_CANNOT_GET_KEY"))):n(null,t))};e.exports=function e(t){return{publish:i((e,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};const i=!(!1===n.resolve),o=n.lifetime||"24h",l=n.key||"self";if(!t.isOnline()){const e=f.OFFLINE_ERROR;return c.error(e),r(u(e,"OFFLINE_ERROR"))}try{e=f.normalizePath(e)}catch(e){return c.error(e),r(e)}s([e=>a(o,e),e=>d(t,l,e),n=>"true"===i.toString()?p.resolvePath(t,e,n):n()],(n,i)=>{if(n)return c.error(n),r(n);const o=i[0].toFixed(6),s=i[1];t._ipns.publish(s,e,o,r)})}),resolve:i((e,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{};const i=n.nocache&&"true"===n.nocache.toString(),o=n.recursive&&"true"===n.recursive.toString(),s=t._options.offline;if(!t.isOnline()&&!s){const e=f.OFFLINE_ERROR;return c.error(e),r(u(e,"OFFLINE_ERROR"))}if(s&&i){const e="cannot specify both offline and nocache";return c.error(e),r(u(new Error(e),"ERR_NOCACHE_AND_OFFLINE"))}e||(e=t._peerInfo.id.toB58String()),e.startsWith("/ipns/")||(e=`/ipns/${e}`);const a={nocache:i,recursive:o};t._ipns.resolve(e,a,r)}),pubsub:h(t)}}},function(e,t,n){"use strict";const r=n(4),i=n(13),o=n(2),s=n(434),a=r("ipfs:name-pubsub");a.error=r("ipfs:name-pubsub:error");const l=e=>{try{return Boolean(u(e))}catch(e){return!1}},u=e=>{if(!e._ipns||!e._options.EXPERIMENTAL.ipnsPubsub){const e="IPNS pubsub subsystem is not enabled";throw i(e,"ERR_IPNS_PUBSUB_NOT_ENABLED")}if(s.isIpnsPubsubDatastore(e._ipns.routing))return e._ipns.routing;const t=(e._ipns.routing.stores||[]).find(e=>s.isIpnsPubsubDatastore(e));if(!t){const e="IPNS pubsub datastore not found";throw i(e,"ERR_PUBSUB_DATASTORE_NOT_FOUND")}return t};e.exports=function e(t){return{state:o(e=>{e(null,{enabled:l(t)})}),cancel:o((e,n)=>{let r;try{r=u(t)}catch(e){return n(e)}r.cancel(e,n)}),subs:o(e=>{let n;try{n=u(t)}catch(t){return e(t)}n.getSubscriptions(e)})}}},function(e,t,n){"use strict";const r=n(261);e.exports=(e=>{const t=e||"ipfs";return new r(t)})},function(e,t,n){"use strict";const r=n(20),i=n(1256),o=n(441),s=n(4),a=n(9),l=n(1258),u=s("ipfs:preload");u.error=s("ipfs:preload:error");const c=e=>{e&&u.error(e)};function h(e){return e.endsWith("http")||e.endsWith("https")||(e+="/http"),o(e)}e.exports=(e=>{const t=e._options.preload||{};if(t.enabled=Boolean(t.enabled),t.addresses=t.addresses||[],!t.enabled||!t.addresses.length){u("preload disabled");const e=(e,t)=>{t&&r(()=>t())};return e.start=(()=>{}),e.stop=(()=>{}),e}let n=!0,o=[];const s=t.addresses.map(h),f=(e,t)=>{if(t=t||c,"string"!=typeof e)try{e=new a(e).toBaseEncodedString()}catch(e){return r(()=>t(e))}const h=Array.from(s);let f;const p=Date.now();i({times:h.length},t=>{if(n)return t(new Error(`preload aborted for ${e}`));o=o.filter(e=>e!==f);const r=h.shift();f=l(`${r}/api/v0/refs?r=true&arg=${e}`,t),o=o.concat(f)},n=>{if(o=o.filter(e=>e!==f),n)return t(n);u(`preloaded ${e} in ${Date.now()-p}ms`),t()})};return f.start=(()=>{n=!1}),f.stop=(()=>{n=!0,u(`canceling ${o.length} pending preload request(s)`),o.forEach(e=>e.cancel()),o=[]}),f})},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(58),i=u(r),o=n(1257),s=u(o),a=n(37),l=u(a);function u(e){return e&&e.__esModule?e:{default:e}}function c(e,t,n){var r=5,o=0,a={times:r,intervalFunc:(0,s.default)(o)};function u(e,t){if("object"==typeof t)e.times=+t.times||r,e.intervalFunc="function"==typeof t.interval?t.interval:(0,s.default)(+t.interval||o),e.errorFilter=t.errorFilter;else{if("number"!=typeof t&&"string"!=typeof t)throw new Error("Invalid arguments for async.retry");e.times=+t||r}}if(arguments.length<3&&"function"==typeof e?(n=t||i.default,t=e):(u(a,e),n=n||i.default),"function"!=typeof t)throw new Error("Invalid arguments for async.retry");var c=(0,l.default)(t),h=1;function f(){c(function(e){e&&h++<a.times&&("function"!=typeof a.errorFilter||a.errorFilter(e))?setTimeout(f,a.intervalFunc(h)):n.apply(null,arguments)})}f()}e.exports=t.default},function(e,t){function n(e){return function(){return e}}e.exports=n},function(e,t,n){"use strict";const r=n(4),i=r("ipfs:preload");i.error=r("ipfs:preload:error"),e.exports=function e(t,n){i(t);const r=new AbortController,o=r.signal;return fetch(t,{signal:o}).then(e=>{if(!e.ok)throw i.error("failed to preload",t,e.status,e.statusText),new Error(`failed to preload ${t}`);return e.text()}).then(()=>n()).catch(n),{cancel:()=>r.abort()}}},function(e,t,n){"use strict";const r=n(4),i=r("ipfs:mfs-preload");i.error=r("ipfs:mfs-preload:error"),e.exports=(e=>{const t=e._options.preload||{};if(t.interval=t.interval||3e4,!t.enabled)return i("MFS preload disabled"),{start:e=>setImmediate(e),stop:e=>setImmediate(e)};let n,r;const o=()=>{e.files.stat("/",(s,a)=>s?(r=setTimeout(o,t.interval),i.error("failed to stat MFS root for preload",s)):n!==a.hash?(i(`preloading updated MFS root ${n} -> ${a.hash}`),e._preload(a.hash,e=>{if(r=setTimeout(o,t.interval),e)return i.error(`failed to preload MFS root ${a.hash}`,e);n=a.hash})):void(r=setTimeout(o,t.interval)))};return{start(s){e.files.stat("/",(e,a)=>{if(e)return s(e);n=a.hash,i(`monitoring MFS root ${n}`),r=setTimeout(o,t.interval),s()})},stop(e){clearTimeout(r),e()}}})},function(e,t,n){"use strict";const r=n(89),i=n(189),o=n(34),s=n(367);e.exports=((e,t={})=>r.call({concatArrays:!0},{blockService:e,formats:[i,o,s]},t))},function(e,t,n){"use strict";const r=n(4),i=r("ipfs:state");i.error=r("ipfs:state:error");const o=n(160);e.exports=(e=>{const t=o("uninitialized",{uninitialized:{init:"initializing",initialized:"stopped"},initializing:{initialized:"stopped"},stopped:{start:"starting"},starting:{started:"running"},running:{stop:"stopping"},stopping:{stopped:"stopped"}});return t.on("error",e=>i.error(e)),t.on("done",()=>i("-> "+t._state)),t.init=(()=>{t("init")}),t.initialized=(()=>{t("initialized")}),t.stop=(()=>{t("stop")}),t.stopped=(()=>{t("stopped")}),t.start=(()=>{t("start")}),t.started=(()=>{t("started")}),t.state=(()=>t._state),t})},function(e,t,n){"use strict";(function(t){const r=n(22),i=n(1263),o=n(536),s=n(537);function a(e,n,a){let u={};if(e)r.isMultiaddr(e)?u=l(e):"object"==typeof e?u=e:"string"==typeof e&&("/"===e[0]?u=l(r(e)):u.host=e);else if("undefined"!=typeof self){const e=self.location.host.split(":");u.host=e[0],u.port=e[1]}n&&"object"!=typeof n&&(n={port:n});const c=Object.assign(o(),u,n,a),h=s(c),f=i(h,c);return f.send=h,f.Buffer=t,f}function l(e){const t=e.nodeAddress();return{host:t.address,port:t.port}}e.exports=a}).call(this,n(0).Buffer)},function(e,t,n){"use strict";function r(){const e={add:n(509),addReadableStream:n(1269),addPullStream:n(1270),addFromFs:n(1271),addFromURL:n(1272),addFromStream:n(509),cat:n(1280),catReadableStream:n(1287),catPullStream:n(1288),get:n(1289),getReadableStream:n(1304),getPullStream:n(1305),ls:n(1306),lsReadableStream:n(1314),lsPullStream:n(1315),block:n(540),bitswap:n(1319),dag:n(1323),object:n(1326),pin:n(1339),bootstrap:n(1343),dht:n(1347),name:n(1354),ping:n(1361),pingReadableStream:n(1363),pingPullStream:n(1364),swarm:n(1365),pubsub:n(1371),dns:n(1375),commands:n(1376),config:n(1377),diag:n(1382),id:n(1386),key:n(1387),log:n(1394),mount:n(1398),refs:n(1399),repo:n(1400),stop:n(1404),stats:n(1405),update:n(1411),version:n(1412),types:n(1413),resolve:n(1414)};return e.shutdown=e.stop,e.files=(e=>n(1415)(e)),e.util=((e,t)=>({getEndpointConfig:n(1481)(t),crypto:n(51),isIPFS:n(75)})),e}function i(e,t){const n=r(),i={};return Object.keys(n).forEach(r=>{i[r]=n[r](e,t)}),i}e.exports=i},function(e,t,n){"use strict";const r=n(168),i=n(1265);function o(e,t){const r=n(54),i=n(1266),o=n(1267),s=null==e.followSymlinks||e.followSymlinks;t=r.resolve(t);const a=i.statSync(t);if(a.isDirectory()&&!e.recursive)throw new Error("Can only add directories using --recursive");if(a.isDirectory()&&e.recursive){t=t.split(r.sep).join("/");const n=t+(t.endsWith("/")?"":"/");let a=n.split("/");a=a[a.length-2]+"/";const l=new o.sync.GlobSync("**/*",{cwd:t,follow:s,dot:e.hidden,ignore:e.ignore});return l.found.map(e=>{const t=n+e;return!0===l.symlinks[t]?{path:a+e,symlink:!0,dir:!1,content:i.readlinkSync(t)}:"FILE"===l.cache[t]?{path:a+e,symlink:!1,dir:!1,content:i.createReadStream(t)}:"DIR"===l.cache[t]||l.cache[t]instanceof Array?{path:a+e,symlink:!1,dir:!0}:void 0}).filter(Boolean)}return{path:r.basename(t),content:i.createReadStream(t)}}function s(e,t){let n=[].concat(e);return i(n,e=>{if("string"==typeof e){if(!r)throw new Error("Can only add file paths in node");return o(t,e)}return e.path&&!e.content?(e.dir=!0,e):e.content||e.dir?e:{path:"",symlink:!1,dir:!1,content:e}})}t=e.exports=s},function(e,t,n){"use strict";e.exports=function(e,t,n){var r=[];return Array.isArray(e)?(e.forEach(function(e,i,o){var s=t.call(n,e,i,o);Array.isArray(s)?r.push.apply(r,s):null!=s&&r.push(s)}),r):r}},function(e,t){},function(e,t){},function(e,t,n){"use strict";(function(t){const r=n(17).Transform,i=n(168),o=n(164).isSource,s=n(80),a="--",l="\r\n",u=t.from(l);class c extends r{constructor(e){super(Object.assign({},e,{objectMode:!0,highWaterMark:1})),this._boundary=this._generateBoundary(),this._files=[],this._draining=!1}_flush(){this.push(t.from(a+this._boundary+a+l)),this.push(null)}_generateBoundary(){for(var e="--------------------------",t=0;t<24;t++)e+=Math.floor(10*Math.random()).toString(16);return e}_transform(e,n,r){if(t.isBuffer(e))return this.push(e),r();this._files.push(e),this._maybeDrain(r)}_maybeDrain(e){if(this._draining)this.once("drained all files",e);else if(this._files.length){this._draining=!0;const t=this._files.shift();this._pushFile(t,t=>{this._draining=!1,t?this.emit("error",t):this._maybeDrain(e)})}else this.emit("drained all files"),e()}_pushFile(e,n){const r=this._leading(e.headers||{});this.push(r);let a=e.content||t.alloc(0);if(t.isBuffer(a))return this.push(a),this.push(u),n();o(a)&&(a=s.source(a)),a.once("error",this.emit.bind(this,"error")),a.once("end",()=>{this.push(u),n()}),a.on("data",e=>{const t=this.push(e);!t&&i&&(a.pause(),this.once("drain",()=>a.resume()))})}_leading(e){var n=[a+this._boundary];Object.keys(e).forEach(t=>{n.push(t+": "+e[t])}),n.push(""),n.push("");const r=n.join(l);return t.from(r)}}e.exports=c}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(167),i=n(130);e.exports=(e=>t=>(t=t||{},t.converter=i,r(e,"add")(t)))},function(e,t,n){"use strict";const r=n(167),i=n(130),o=n(69);e.exports=(e=>t=>(t=t||{},t.converter=i,o(r(e,"add")({qs:t}))))},function(e,t,n){"use strict";const r=n(168),i=n(2),o=n(299),s=n(130);e.exports=(e=>{const t=o(e,"add");return i((e,n,i)=>{if("function"==typeof n&&void 0===i&&(i=n,n={}),"function"==typeof n&&"function"==typeof i&&(i=n,n={}),!r)return i(new Error("fsAdd does not work in the browser"));if("string"!=typeof e)return i(new Error('"path" must be a string'));const o={qs:n,converter:s};t(e,o,i)})})},function(e,t,n){"use strict";const r=n(2),{URL:i}=n(32),o=n(511),s=n(299),a=n(130);e.exports=(e=>{const t=s(e,"add");return r((e,n,r)=>{if("function"==typeof n&&void 0===r&&(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),!l(e))return r(new Error('"url" param must be an http(s) url'));u(e,n,t,r)})});const l=e=>"string"==typeof e&&e.startsWith("http"),u=(e,t,n,r)=>{const s=new i(e),c=o(s.protocol)(e,e=>{if(e.statusCode>=400)return r(new Error(`Failed to download with ${e.statusCode}`));const i=e.headers.location;if(e.statusCode>=300&&e.statusCode<400&&i){if(!l(i))return r(new Error("redirection url must be an http(s) url"));u(i,t,n,r)}else{const i={qs:t,converter:a},o=decodeURIComponent(s.pathname.split("/").pop());n({content:e,path:o},i,r)}});c.once("error",r),c.end()}},function(e,t,n){(function(e){var r=n(1274),i=n(513),o=n(68),s=n(514),a=n(32),l=t;l.request=function(t,n){t="string"==typeof t?a.parse(t):o(t);var i=-1===e.location.protocol.search(/^https?:$/)?"http:":"",s=t.protocol||i,l=t.hostname||t.host,u=t.port,c=t.path||"/";l&&-1!==l.indexOf(":")&&(l="["+l+"]"),t.url=(l?s+"//"+l:"")+(u?":"+u:"")+c,t.method=(t.method||"GET").toUpperCase(),t.headers=t.headers||{};var h=new r(t);return n&&h.on("response",n),h},l.get=function e(t,n){var r=l.request(t,n);return r.end(),r},l.ClientRequest=r,l.IncomingMessage=i.IncomingMessage,l.Agent=function(){},l.Agent.defaultMaxSockets=4,l.globalAgent=new l.Agent,l.STATUS_CODES=s,l.METHODS=["CHECKOUT","CONNECT","COPY","DELETE","GET","HEAD","LOCK","M-SEARCH","MERGE","MKACTIVITY","MKCOL","MOVE","NOTIFY","OPTIONS","PATCH","POST","PROPFIND","PROPPATCH","PURGE","PUT","REPORT","SEARCH","SUBSCRIBE","TRACE","UNLOCK","UNSUBSCRIBE"]}).call(this,n(8))},function(e,t,n){(function(t,r,i){var o=n(512),s=n(1),a=n(513),l=n(17),u=a.IncomingMessage,c=a.readyStates;function h(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":"text"}var f=e.exports=function(e){var n=this,r;l.Writable.call(n),n._opts=e,n._body=[],n._headers={},e.auth&&n.setHeader("Authorization","Basic "+t.from(e.auth).toString("base64")),Object.keys(e.headers).forEach(function(t){n.setHeader(t,e.headers[t])});var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,r=!0;else if("prefer-streaming"===e.mode)r=!1;else if("allow-wrong-content-type"===e.mode)r=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");r=!0}n._mode=h(r,i),n._fetchTimer=null,n.on("finish",function(){n._onFinish()})};function p(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}s(f,l.Writable),f.prototype.setHeader=function(e,t){var n=this,r=e.toLowerCase();-1===d.indexOf(r)&&(this._headers[r]={name:e,value:t})},f.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},f.prototype.removeHeader=function(e){var t=this;delete this._headers[e.toLowerCase()]},f.prototype._onFinish=function(){var e=this;if(!e._destroyed){var t=e._opts,n=e._headers,s=null;"GET"!==t.method&&"HEAD"!==t.method&&(s=new Blob(e._body,{type:(n["content-type"]||{}).value||""}));var a=[];if(Object.keys(n).forEach(function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach(function(e){a.push([t,e])}):a.push([t,r])}),"fetch"===e._mode){var l=null,u=null;if(o.abortController){var h=new AbortController;l=h.signal,e._fetchAbortController=h,"requestTimeout"in t&&0!==t.requestTimeout&&(e._fetchTimer=r.setTimeout(function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()},t.requestTimeout))}r.fetch(e._opts.url,{method:e._opts.method,headers:a,body:s||void 0,mode:"cors",credentials:t.withCredentials?"include":"same-origin",signal:l}).then(function(t){e._fetchResponse=t,e._connect()},function(t){r.clearTimeout(e._fetchTimer),e._destroyed||e.emit("error",t)})}else{var f=e._xhr=new r.XMLHttpRequest;try{f.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick(function(){e.emit("error",t)})}"responseType"in f&&(f.responseType=e._mode),"withCredentials"in f&&(f.withCredentials=!!t.withCredentials),"text"===e._mode&&"overrideMimeType"in f&&f.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in t&&(f.timeout=t.requestTimeout,f.ontimeout=function(){e.emit("requestTimeout")}),a.forEach(function(e){f.setRequestHeader(e[0],e[1])}),e._response=null,f.onreadystatechange=function(){switch(f.readyState){case c.LOADING:case c.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(f.onprogress=function(){e._onXHRProgress()}),f.onerror=function(){e._destroyed||e.emit("error",new Error("XHR error"))};try{f.send(s)}catch(t){return void i.nextTick(function(){e.emit("error",t)})}}}},f.prototype._onXHRProgress=function(){var e=this;p(this._xhr)&&!this._destroyed&&(this._response||this._connect(),this._response._onXHRProgress())},f.prototype._connect=function(){var e=this;e._destroyed||(e._response=new u(e._xhr,e._fetchResponse,e._mode,e._fetchTimer),e._response.on("error",function(t){e.emit("error",t)}),e.emit("response",e._response))},f.prototype._write=function(e,t,n){var r=this;this._body.push(e),n()},f.prototype.abort=f.prototype.destroy=function(){var e=this;this._destroyed=!0,r.clearTimeout(this._fetchTimer),this._response&&(this._response._destroyed=!0),this._xhr?this._xhr.abort():this._fetchAbortController&&this._fetchAbortController.abort()},f.prototype.end=function(e,t,n){var r=this;"function"==typeof e&&(n=e,e=void 0),l.Writable.prototype.end.call(this,e,t,n)},f.prototype.flushHeaders=function(){},f.prototype.setTimeout=function(){},f.prototype.setNoDelay=function(){},f.prototype.setSocketKeepAlive=function(){};var d=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]}).call(this,n(0).Buffer,n(8),n(3))},function(e,t,n){(function(t,r,i){var o=n(515),s=n(1),a=n(516),l=n(517),u=n(523),c=a.IncomingMessage,h=a.readyStates;function f(e,t){return o.fetch&&t?"fetch":o.mozchunkedarraybuffer?"moz-chunked-arraybuffer":o.msstream?"ms-stream":o.arraybuffer&&e?"arraybuffer":o.vbArray&&e?"text:vbarray":"text"}var p=e.exports=function(e){var n=this,r;l.Writable.call(n),n._opts=e,n._body=[],n._headers={},e.auth&&n.setHeader("Authorization","Basic "+new t(e.auth).toString("base64")),Object.keys(e.headers).forEach(function(t){n.setHeader(t,e.headers[t])});var i=!0;if("disable-fetch"===e.mode||"requestTimeout"in e&&!o.abortController)i=!1,r=!0;else if("prefer-streaming"===e.mode)r=!1;else if("allow-wrong-content-type"===e.mode)r=!o.overrideMimeType;else{if(e.mode&&"default"!==e.mode&&"prefer-fast"!==e.mode)throw new Error("Invalid value for opts.mode");r=!0}n._mode=f(r,i),n._fetchTimer=null,n.on("finish",function(){n._onFinish()})};function d(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}}s(p,l.Writable),p.prototype.setHeader=function(e,t){var n=this,r=e.toLowerCase();-1===m.indexOf(r)&&(this._headers[r]={name:e,value:t})},p.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},p.prototype.removeHeader=function(e){var t=this;delete this._headers[e.toLowerCase()]},p.prototype._onFinish=function(){var e=this;if(!e._destroyed){var n=e._opts,s=e._headers,a=null;"GET"!==n.method&&"HEAD"!==n.method&&(a=o.arraybuffer?u(t.concat(e._body)):o.blobConstructor?new r.Blob(e._body.map(function(e){return u(e)}),{type:(s["content-type"]||{}).value||""}):t.concat(e._body).toString());var l=[];if(Object.keys(s).forEach(function(e){var t=s[e].name,n=s[e].value;Array.isArray(n)?n.forEach(function(e){l.push([t,e])}):l.push([t,n])}),"fetch"===e._mode){var c=null,f=null;if(o.abortController){var p=new AbortController;c=p.signal,e._fetchAbortController=p,"requestTimeout"in n&&0!==n.requestTimeout&&(e._fetchTimer=r.setTimeout(function(){e.emit("requestTimeout"),e._fetchAbortController&&e._fetchAbortController.abort()},n.requestTimeout))}r.fetch(e._opts.url,{method:e._opts.method,headers:l,body:a||void 0,mode:"cors",credentials:n.withCredentials?"include":"same-origin",signal:c}).then(function(t){e._fetchResponse=t,e._connect()},function(t){r.clearTimeout(e._fetchTimer),e._destroyed||e.emit("error",t)})}else{var d=e._xhr=new r.XMLHttpRequest;try{d.open(e._opts.method,e._opts.url,!0)}catch(t){return void i.nextTick(function(){e.emit("error",t)})}"responseType"in d&&(d.responseType=e._mode.split(":")[0]),"withCredentials"in d&&(d.withCredentials=!!n.withCredentials),"text"===e._mode&&"overrideMimeType"in d&&d.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in n&&(d.timeout=n.requestTimeout,d.ontimeout=function(){e.emit("requestTimeout")}),l.forEach(function(e){d.setRequestHeader(e[0],e[1])}),e._response=null,d.onreadystatechange=function(){switch(d.readyState){case h.LOADING:case h.DONE:e._onXHRProgress()}},"moz-chunked-arraybuffer"===e._mode&&(d.onprogress=function(){e._onXHRProgress()}),d.onerror=function(){e._destroyed||e.emit("error",new Error("XHR error"))};try{d.send(a)}catch(t){return void i.nextTick(function(){e.emit("error",t)})}}}},p.prototype._onXHRProgress=function(){var e=this;d(this._xhr)&&!this._destroyed&&(this._response||this._connect(),this._response._onXHRProgress())},p.prototype._connect=function(){var e=this;e._destroyed||(e._response=new c(e._xhr,e._fetchResponse,e._mode,e._fetchTimer),e._response.on("error",function(t){e.emit("error",t)}),e.emit("response",e._response))},p.prototype._write=function(e,t,n){var r=this;this._body.push(e),n()},p.prototype.abort=p.prototype.destroy=function(){var e=this;this._destroyed=!0,r.clearTimeout(this._fetchTimer),this._response&&(this._response._destroyed=!0),this._xhr?this._xhr.abort():this._fetchAbortController&&this._fetchAbortController.abort()},p.prototype.end=function(e,t,n){var r=this;"function"==typeof e&&(n=e,e=void 0),l.Writable.prototype.end.call(this,e,t,n)},p.prototype.flushHeaders=function(){},p.prototype.setTimeout=function(){},p.prototype.setNoDelay=function(){},p.prototype.setSocketKeepAlive=function(){};var m=["accept-charset","accept-encoding","access-control-request-headers","access-control-request-method","connection","content-length","cookie","cookie2","date","dnt","expect","host","keep-alive","origin","referer","te","trailer","transfer-encoding","upgrade","via"]}).call(this,n(0).Buffer,n(8),n(3))},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1278);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(522),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){"use strict";const r=n(2),i=n(82),o=n(75),s=n(1281);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={});try{t=i(t)}catch(e){if(!o.ipfsPath(t))return r(e)}const a={offset:n.offset,length:n.length};e({path:"cat",args:t,buffer:n.buffer,qs:a},(e,t)=>{if(e)return r(e);t.pipe(s((e,t)=>{if(e)return r(e);r(null,t)}))})}))},function(e,t,n){"use strict";var r=n(1282).Duplex,i=n(14),o=n(5).Buffer;function s(e){if(!(this instanceof s))return new s(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function e(t){this._callback&&(this._callback(t),this._callback=null)}.bind(this);this.on("pipe",function e(n){n.on("error",t)}),this.on("unpipe",function e(n){n.removeListener("error",t)})}else this.append(e);r.call(this)}i.inherits(s,r),s.prototype._offset=function e(t){var n=0,r=0,i;if(0===t)return[0,0];for(;r<this._bufs.length;r++){if(i=n+this._bufs[r].length,t<i||r==this._bufs.length-1)return[r,t-n];n=i}},s.prototype._reverseOffset=function(e){for(var t=e[0],n=e[1],r=0;r<t;r++)n+=this._bufs[r].length;return n},s.prototype.append=function e(t){var n=0;if(o.isBuffer(t))this._appendBuffer(t);else if(Array.isArray(t))for(;n<t.length;n++)this.append(t[n]);else if(t instanceof s)for(;n<t._bufs.length;n++)this.append(t._bufs[n]);else null!=t&&("number"==typeof t&&(t=t.toString()),this._appendBuffer(o.from(t)));return this},s.prototype._appendBuffer=function e(t){this._bufs.push(t),this.length+=t.length},s.prototype._write=function e(t,n,r){this._appendBuffer(t),"function"==typeof r&&r()},s.prototype._read=function e(t){if(!this.length)return this.push(null);t=Math.min(t,this.length),this.push(this.slice(0,t)),this.consume(t)},s.prototype.end=function e(t){r.prototype.end.call(this,t),this._callback&&(this._callback(null,this.slice()),this._callback=null)},s.prototype.get=function e(t){if(!(t>this.length||t<0)){var n=this._offset(t);return this._bufs[n[0]][n[1]]}},s.prototype.slice=function e(t,n){return"number"==typeof t&&t<0&&(t+=this.length),"number"==typeof n&&n<0&&(n+=this.length),this.copy(null,0,t,n)},s.prototype.copy=function e(t,n,r,i){if(("number"!=typeof r||r<0)&&(r=0),("number"!=typeof i||i>this.length)&&(i=this.length),r>=this.length)return t||o.alloc(0);if(i<=0)return t||o.alloc(0);var e=!!t,s=this._offset(r),a=i-r,l=a,u=e&&n||0,c=s[1],h,f;if(0===r&&i==this.length){if(!e)return 1===this._bufs.length?this._bufs[0]:o.concat(this._bufs,this.length);for(f=0;f<this._bufs.length;f++)this._bufs[f].copy(t,u),u+=this._bufs[f].length;return t}if(l<=this._bufs[s[0]].length-c)return e?this._bufs[s[0]].copy(t,n,c,c+l):this._bufs[s[0]].slice(c,c+l);for(e||(t=o.allocUnsafe(a)),f=s[0];f<this._bufs.length;f++){if(h=this._bufs[f].length-c,!(l>h)){this._bufs[f].copy(t,u,c,c+l);break}this._bufs[f].copy(t,u,c),u+=h,l-=h,c&&(c=0)}return t},s.prototype.shallowSlice=function e(t,n){if(t=t||0,n="number"!=typeof n?this.length:n,t<0&&(t+=this.length),n<0&&(n+=this.length),t===n)return new s;var r=this._offset(t),i=this._offset(n),o=this._bufs.slice(r[0],i[0]+1);return 0==i[1]?o.pop():o[o.length-1]=o[o.length-1].slice(0,i[1]),0!=r[1]&&(o[0]=o[0].slice(r[1])),new s(o)},s.prototype.toString=function e(t,n,r){return this.slice(n,r).toString(t)},s.prototype.consume=function e(t){for(;this._bufs.length;){if(!(t>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(t),this.length-=t;break}t-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},s.prototype.duplicate=function e(){for(var t=0,n=new s;t<this._bufs.length;t++)n.append(this._bufs[t]);return n},s.prototype.destroy=function e(){this._bufs.length=0,this.length=0,this.push(null)},s.prototype.indexOf=function(e,t,n){if(void 0===n&&"string"==typeof t&&(n=t,t=void 0),"function"==typeof e||Array.isArray(e))throw new TypeError('The "value" argument must be one of type string, Buffer, BufferList, or Uint8Array.');if("number"==typeof e?e=o.from([e]):"string"==typeof e?e=o.from(e,n):e instanceof s?e=e.slice():o.isBuffer(e)||(e=o.from(e)),t=Number(t||0),isNaN(t)&&(t=0),t<0&&(t=this.length+t),t<0&&(t=0),0===e.length)return t>this.length?this.length:t;for(var r=this._offset(t),i=r[0],a=r[1];i<this._bufs.length;i++){for(var l=this._bufs[i];a<l.length;){var u=l.length-a;if(u>=e.length){var c=l.indexOf(e,a);if(-1!==c)return this._reverseOffset([i,c]);a=l.length-e.length+1}else{var h=this._reverseOffset([i,a]);if(this._match(h,e))return h;a++}}a=0}return-1},s.prototype._match=function(e,t){if(this.length-e<t.length)return!1;for(var n=0;n<t.length;n++)if(this.get(e+n)!==t[n])return!1;return!0},function(){var e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1,readIntBE:null,readIntLE:null,readUIntBE:null,readUIntLE:null};for(var t in e)!function(t){s.prototype[t]=null===e[t]?function(e,n){return this.slice(e,e+n)[t](0,n)}:function(n){return this.slice(n,n+e[t])[t](0)}}(t)}(),e.exports=s},function(e,t,n){t=e.exports=n(524),t.Stream=t,t.Readable=t,t.Writable=n(527),t.Duplex=n(133),t.Transform=n(528),t.PassThrough=n(1286)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1285);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(528),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){"use strict";const r=n(82),i=n(75),o=n(17),s=n(53);e.exports=(e=>(t,n)=>{n=n||{};const a=new o.PassThrough;try{t=r(t)}catch(e){if(!i.ipfsPath(t))return a.destroy(e)}const l={offset:n.offset,length:n.length};return e({path:"cat",args:t,buffer:n.buffer,qs:l},(e,t)=>{if(e)return a.destroy(e);s(t,a)}),a})},function(e,t,n){"use strict";const r=n(82),i=n(75),o=n(69),s=n(61);e.exports=(e=>(t,n)=>{n=n||{};const a=s.source();try{t=r(t)}catch(e){if(!i.ipfsPath(t))return a.end(e)}const l={offset:n.offset,length:n.length};return e({path:"cat",args:t,buffer:n.buffer,qs:l},(e,t)=>{if(e)return a.end(e);a.resolve(o(t))}),a})},function(e,t,n){"use strict";const r=n(2),i=n(82),o=n(300),s=n(166),a=n(1303),l=n(75);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={});try{t=i(t)}catch(e){if(!l.ipfsPath(t))return r(e)}const u={path:"get",args:t,qs:n};e.andTransform(u,o,(e,t)=>{if(e)return r(e);const n=[];t.pipe(a.obj((e,t,r)=>{e.content?e.content.pipe(s(t=>{n.push({path:e.path,content:t})})):n.push(e),r()},()=>r(null,n)))})}))},function(e,t,n){t.extract=n(1291),t.pack=n(1300)},function(e,t,n){var r=n(14),i=n(1292),o=n(68),s=n(533),a=n(230).Writable,l=n(230).PassThrough,u=function(){},c=function(e){return e&=511,e&&512-e},h=function(e,t){var n=new p(e,t);return n.end(),n},f=function(e,t){return t.path&&(e.name=t.path),t.linkpath&&(e.linkname=t.linkpath),t.size&&(e.size=parseInt(t.size,10)),e.pax=t,e},p=function(e,t){this._parent=e,this.offset=t,l.call(this)};r.inherits(p,l),p.prototype.destroy=function(e){this._parent.destroy(e)};var d=function(e){if(!(this instanceof d))return new d(e);a.call(this,e),e=e||{},this._offset=0,this._buffer=i(),this._missing=0,this._partial=!1,this._onparse=u,this._header=null,this._stream=null,this._overflow=null,this._cb=null,this._locked=!1,this._destroyed=!1,this._pax=null,this._paxGlobal=null,this._gnuLongPath=null,this._gnuLongLinkPath=null;var t=this,n=t._buffer,r=function(){t._continue()},l=function(e){if(t._locked=!1,e)return t.destroy(e);t._stream||r()},m=function(){t._stream=null;var e=c(t._header.size);e?t._parse(e,g):t._parse(512,w),t._locked||r()},g=function(){t._buffer.consume(c(t._header.size)),t._parse(512,w),r()},y=function(){var e=t._header.size;t._paxGlobal=s.decodePax(n.slice(0,e)),n.consume(e),m()},v=function(){var e=t._header.size;t._pax=s.decodePax(n.slice(0,e)),t._paxGlobal&&(t._pax=o(t._paxGlobal,t._pax)),n.consume(e),m()},b=function(){var r=t._header.size;this._gnuLongPath=s.decodeLongPath(n.slice(0,r),e.filenameEncoding),n.consume(r),m()},_=function(){var r=t._header.size;this._gnuLongLinkPath=s.decodeLongPath(n.slice(0,r),e.filenameEncoding),n.consume(r),m()},w=function(){var i=t._offset,o;try{o=t._header=s.decode(n.slice(0,512),e.filenameEncoding)}catch(e){t.emit("error",e)}return n.consume(512),o?"gnu-long-path"===o.type?(t._parse(o.size,b),void r()):"gnu-long-link-path"===o.type?(t._parse(o.size,_),void r()):"pax-global-header"===o.type?(t._parse(o.size,y),void r()):"pax-header"===o.type?(t._parse(o.size,v),void r()):(t._gnuLongPath&&(o.name=t._gnuLongPath,t._gnuLongPath=null),t._gnuLongLinkPath&&(o.linkname=t._gnuLongLinkPath,t._gnuLongLinkPath=null),t._pax&&(t._header=o=f(o,t._pax),t._pax=null),t._locked=!0,o.size&&"directory"!==o.type?(t._stream=new p(t,i),t.emit("entry",o,t._stream,l),t._parse(o.size,m),void r()):(t._parse(512,w),void t.emit("entry",o,h(t,i),l))):(t._parse(512,w),void r())};this._onheader=w,this._parse(512,w)};r.inherits(d,a),d.prototype.destroy=function(e){this._destroyed||(this._destroyed=!0,e&&this.emit("error",e),this.emit("close"),this._stream&&this._stream.emit("close"))},d.prototype._parse=function(e,t){this._destroyed||(this._offset+=e,this._missing=e,t===this._onheader&&(this._partial=!1),this._onparse=t)},d.prototype._continue=function(){if(!this._destroyed){var e=this._cb;this._cb=u,this._overflow?this._write(this._overflow,void 0,e):e()}},d.prototype._write=function(e,t,n){if(!this._destroyed){var r=this._stream,i=this._buffer,o=this._missing;if(e.length&&(this._partial=!0),e.length<o)return this._missing-=e.length,this._overflow=null,r?r.write(e,n):(i.append(e),n());this._cb=n,this._missing=0;var s=null;e.length>o&&(s=e.slice(o),e=e.slice(0,o)),r?r.end(e):i.append(e),this._overflow=s,this._onparse()}},d.prototype._final=function(e){if(this._partial)return this.destroy(new Error("Unexpected end of data"));e()},e.exports=d},function(e,t,n){var r=n(1293),i=n(14),o=n(5).Buffer;function s(e){if(!(this instanceof s))return new s(e);if(this._bufs=[],this.length=0,"function"==typeof e){this._callback=e;var t=function e(t){this._callback&&(this._callback(t),this._callback=null)}.bind(this);this.on("pipe",function e(n){n.on("error",t)}),this.on("unpipe",function e(n){n.removeListener("error",t)})}else this.append(e);r.call(this)}i.inherits(s,r),s.prototype._offset=function e(t){var n=0,r=0,i;if(0===t)return[0,0];for(;r<this._bufs.length;r++){if(i=n+this._bufs[r].length,t<i||r==this._bufs.length-1)return[r,t-n];n=i}},s.prototype.append=function e(t){var n=0;if(o.isBuffer(t))this._appendBuffer(t);else if(Array.isArray(t))for(;n<t.length;n++)this.append(t[n]);else if(t instanceof s)for(;n<t._bufs.length;n++)this.append(t._bufs[n]);else null!=t&&("number"==typeof t&&(t=t.toString()),this._appendBuffer(o.from(t)));return this},s.prototype._appendBuffer=function e(t){this._bufs.push(t),this.length+=t.length},s.prototype._write=function e(t,n,r){this._appendBuffer(t),"function"==typeof r&&r()},s.prototype._read=function e(t){if(!this.length)return this.push(null);t=Math.min(t,this.length),this.push(this.slice(0,t)),this.consume(t)},s.prototype.end=function e(t){r.prototype.end.call(this,t),this._callback&&(this._callback(null,this.slice()),this._callback=null)},s.prototype.get=function e(t){return this.slice(t,t+1)[0]},s.prototype.slice=function e(t,n){return"number"==typeof t&&t<0&&(t+=this.length),"number"==typeof n&&n<0&&(n+=this.length),this.copy(null,0,t,n)},s.prototype.copy=function e(t,n,r,i){if(("number"!=typeof r||r<0)&&(r=0),("number"!=typeof i||i>this.length)&&(i=this.length),r>=this.length)return t||o.alloc(0);if(i<=0)return t||o.alloc(0);var e=!!t,s=this._offset(r),a=i-r,l=a,u=e&&n||0,c=s[1],h,f;if(0===r&&i==this.length){if(!e)return 1===this._bufs.length?this._bufs[0]:o.concat(this._bufs,this.length);for(f=0;f<this._bufs.length;f++)this._bufs[f].copy(t,u),u+=this._bufs[f].length;return t}if(l<=this._bufs[s[0]].length-c)return e?this._bufs[s[0]].copy(t,n,c,c+l):this._bufs[s[0]].slice(c,c+l);for(e||(t=o.allocUnsafe(a)),f=s[0];f<this._bufs.length;f++){if(h=this._bufs[f].length-c,!(l>h)){this._bufs[f].copy(t,u,c,c+l);break}this._bufs[f].copy(t,u,c),u+=h,l-=h,c&&(c=0)}return t},s.prototype.shallowSlice=function e(t,n){t=t||0,n=n||this.length,t<0&&(t+=this.length),n<0&&(n+=this.length);var r=this._offset(t),i=this._offset(n),o=this._bufs.slice(r[0],i[0]+1);return 0==i[1]?o.pop():o[o.length-1]=o[o.length-1].slice(0,i[1]),0!=r[1]&&(o[0]=o[0].slice(r[1])),new s(o)},s.prototype.toString=function e(t,n,r){return this.slice(n,r).toString(t)},s.prototype.consume=function e(t){for(;this._bufs.length;){if(!(t>=this._bufs[0].length)){this._bufs[0]=this._bufs[0].slice(t),this.length-=t;break}t-=this._bufs[0].length,this.length-=this._bufs[0].length,this._bufs.shift()}return this},s.prototype.duplicate=function e(){for(var t=0,n=new s;t<this._bufs.length;t++)n.append(this._bufs[t]);return n},s.prototype.destroy=function e(){this._bufs.length=0,this.length=0,this.push(null)},function(){var e={readDoubleBE:8,readDoubleLE:8,readFloatBE:4,readFloatLE:4,readInt32BE:4,readInt32LE:4,readUInt32BE:4,readUInt32LE:4,readInt16BE:2,readInt16LE:2,readUInt16BE:2,readUInt16LE:2,readInt8:1,readUInt8:1};for(var t in e)!function(t){s.prototype[t]=function(n){return this.slice(n,n+e[t])[t](0)}}(t)}(),e.exports=s},function(e,t,n){e.exports=n(104)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1296);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){(function(t){var n=function(){try{if(!t.isEncoding("latin1"))return!1;var e=t.alloc?t.alloc(4):new t(4);return e.fill("ab","ucs2"),"61006200"===e.toString("hex")}catch(e){return!1}}();function r(e){return 1===e.length&&e.charCodeAt(0)<256}function i(e,t,n,r){if(n<0||r>e.length)throw new RangeError("Out of range index");return n>>>=0,r=void 0===r?e.length:r>>>0,r>n&&e.fill(t,n,r),e}function o(e,t,n,r){if(n<0||r>e.length)throw new RangeError("Out of range index");if(r<=n)return e;n>>>=0,r=void 0===r?e.length:r>>>0;for(var i=n,o=t.length;i<=r-o;)t.copy(e,i),i+=o;return i!==r&&t.copy(e,i,0,r-i),e}function s(e,s,a,l,u){if(n)return e.fill(s,a,l,u);if("number"==typeof s)return i(e,s,a,l);if("string"==typeof s){if("string"==typeof a?(u=a,a=0,l=e.length):"string"==typeof l&&(u=l,l=e.length),void 0!==u&&"string"!=typeof u)throw new TypeError("encoding must be a string");if("latin1"===u&&(u="binary"),"string"==typeof u&&!t.isEncoding(u))throw new TypeError("Unknown encoding: "+u);if(""===s)return i(e,0,a,l);if(r(s))return i(e,s.charCodeAt(0),a,l);s=new t(s,u)}return t.isBuffer(s)?o(e,s,a,l):i(e,0,a,l)}e.exports=s}).call(this,n(0).Buffer)},function(e,t,n){(function(t){function n(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative');return t.allocUnsafe?t.allocUnsafe(e):new t(e)}e.exports=n}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=o;var r=n(535),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){(function(t,r){var i=n(1301),o=n(212),s=n(14),a=n(105),l=n(534),u=n(230).Readable,c=n(230).Writable,h=n(18).StringDecoder,f=n(533),p=parseInt("755",8),d=parseInt("644",8),m=a(1024),g=function(){},y=function(e,t){t&=511,t&&e.push(m.slice(0,512-t))};function v(e){switch(e&i.S_IFMT){case i.S_IFBLK:return"block-device";case i.S_IFCHR:return"character-device";case i.S_IFDIR:return"directory";case i.S_IFIFO:return"fifo";case i.S_IFLNK:return"symlink"}return"file"}var b=function(e){c.call(this),this.written=0,this._to=e,this._destroyed=!1};s.inherits(b,c),b.prototype._write=function(e,t,n){if(this.written+=e.length,this._to.push(e))return n();this._to._drain=n},b.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var _=function(){c.call(this),this.linkname="",this._decoder=new h("utf-8"),this._destroyed=!1};s.inherits(_,c),_.prototype._write=function(e,t,n){this.linkname+=this._decoder.write(e),n()},_.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var w=function(){c.call(this),this._destroyed=!1};s.inherits(w,c),w.prototype._write=function(e,t,n){n(new Error("No body allowed for this entry"))},w.prototype.destroy=function(){this._destroyed||(this._destroyed=!0,this.emit("close"))};var k=function(e){if(!(this instanceof k))return new k(e);u.call(this,e),this._drain=g,this._finalized=!1,this._finalizing=!1,this._destroyed=!1,this._stream=null};s.inherits(k,u),k.prototype.entry=function(e,n,i){if(this._stream)throw new Error("already piping an entry");if(!this._finalized&&!this._destroyed){"function"==typeof n&&(i=n,n=null),i||(i=g);var s=this;if(e.size&&"symlink"!==e.type||(e.size=0),e.type||(e.type=v(e.mode)),e.mode||(e.mode="directory"===e.type?p:d),e.uid||(e.uid=0),e.gid||(e.gid=0),e.mtime||(e.mtime=new Date),"string"==typeof n&&(n=l(n)),t.isBuffer(n))return e.size=n.length,this._encode(e),this.push(n),y(s,e.size),r.nextTick(i),new w;if("symlink"===e.type&&!e.linkname){var a=new _;return o(a,function(t){if(t)return s.destroy(),i(t);e.linkname=a.linkname,s._encode(e),i()}),a}if(this._encode(e),"file"!==e.type&&"contiguous-file"!==e.type)return r.nextTick(i),new w;var u=new b(this);return this._stream=u,o(u,function(t){return s._stream=null,t?(s.destroy(),i(t)):u.written!==e.size?(s.destroy(),i(new Error("size mismatch"))):(y(s,e.size),s._finalizing&&s.finalize(),void i())}),u}},k.prototype.finalize=function(){this._stream?this._finalizing=!0:this._finalized||(this._finalized=!0,this.push(m),this.push(null))},k.prototype.destroy=function(e){this._destroyed||(this._destroyed=!0,e&&this.emit("error",e),this.emit("close"),this._stream&&this._stream.destroy&&this._stream.destroy())},k.prototype._encode=function(e){if(!e.pax){var t=f.encode(e);if(t)return void this.push(t)}this._encodePax(e)},k.prototype._encodePax=function(e){var t=f.encodePax({name:e.name,linkname:e.linkname,pax:e.pax}),n={name:"PaxHeader",mode:e.mode,uid:e.uid,gid:e.gid,size:t.length,mtime:e.mtime,type:"pax-header",linkname:e.linkname&&"PaxHeader",uname:e.uname,gname:e.gname,devmajor:e.devmajor,devminor:e.devminor};this.push(f.encode(n)),this.push(t),y(this,t.length),n.size=e.size,n.type=e.type,this.push(f.encode(n))},k.prototype._read=function(e){var t=this._drain;this._drain=g,t()},e.exports=k}).call(this,n(0).Buffer,n(3))},function(e,t,n){e.exports=n(1302)},function(e){e.exports={O_RDONLY:0,O_WRONLY:1,O_RDWR:2,S_IFMT:61440,S_IFREG:32768,S_IFDIR:16384,S_IFCHR:8192,S_IFBLK:24576,S_IFIFO:4096,S_IFLNK:40960,S_IFSOCK:49152,O_CREAT:512,O_EXCL:2048,O_NOCTTY:131072,O_TRUNC:1024,O_APPEND:8,O_DIRECTORY:1048576,O_NOFOLLOW:256,O_SYNC:128,O_SYMLINK:2097152,O_NONBLOCK:4,S_IRWXU:448,S_IRUSR:256,S_IWUSR:128,S_IXUSR:64,S_IRWXG:56,S_IRGRP:32,S_IWGRP:16,S_IXGRP:8,S_IRWXO:7,S_IROTH:4,S_IWOTH:2,S_IXOTH:1,E2BIG:7,EACCES:13,EADDRINUSE:48,EADDRNOTAVAIL:49,EAFNOSUPPORT:47,EAGAIN:35,EALREADY:37,EBADF:9,EBADMSG:94,EBUSY:16,ECANCELED:89,ECHILD:10,ECONNABORTED:53,ECONNREFUSED:61,ECONNRESET:54,EDEADLK:11,EDESTADDRREQ:39,EDOM:33,EDQUOT:69,EEXIST:17,EFAULT:14,EFBIG:27,EHOSTUNREACH:65,EIDRM:90,EILSEQ:92,EINPROGRESS:36,EINTR:4,EINVAL:22,EIO:5,EISCONN:56,EISDIR:21,ELOOP:62,EMFILE:24,EMLINK:31,EMSGSIZE:40,EMULTIHOP:95,ENAMETOOLONG:63,ENETDOWN:50,ENETRESET:52,ENETUNREACH:51,ENFILE:23,ENOBUFS:55,ENODATA:96,ENODEV:19,ENOENT:2,ENOEXEC:8,ENOLCK:77,ENOLINK:97,ENOMEM:12,ENOMSG:91,ENOPROTOOPT:42,ENOSPC:28,ENOSR:98,ENOSTR:99,ENOSYS:78,ENOTCONN:57,ENOTDIR:20,ENOTEMPTY:66,ENOTSOCK:38,ENOTSUP:45,ENOTTY:25,ENXIO:6,EOPNOTSUPP:102,EOVERFLOW:84,EPERM:1,EPIPE:32,EPROTO:100,EPROTONOSUPPORT:43,EPROTOTYPE:41,ERANGE:34,EROFS:30,ESPIPE:29,ESRCH:3,ESTALE:70,ETIME:101,ETIMEDOUT:60,ETXTBSY:26,EWOULDBLOCK:35,EXDEV:18,SIGHUP:1,SIGINT:2,SIGQUIT:3,SIGILL:4,SIGTRAP:5,SIGABRT:6,SIGIOT:6,SIGBUS:10,SIGFPE:8,SIGKILL:9,SIGUSR1:30,SIGSEGV:11,SIGUSR2:31,SIGPIPE:13,SIGALRM:14,SIGTERM:15,SIGCHLD:20,SIGCONT:19,SIGSTOP:17,SIGTSTP:18,SIGTTIN:21,SIGTTOU:22,SIGURG:16,SIGXCPU:24,SIGXFSZ:25,SIGVTALRM:26,SIGPROF:27,SIGWINCH:28,SIGIO:23,SIGSYS:12,SSL_OP_ALL:2147486719,SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION:262144,SSL_OP_CIPHER_SERVER_PREFERENCE:4194304,SSL_OP_CISCO_ANYCONNECT:32768,SSL_OP_COOKIE_EXCHANGE:8192,SSL_OP_CRYPTOPRO_TLSEXT_BUG:2147483648,SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS:2048,SSL_OP_EPHEMERAL_RSA:0,SSL_OP_LEGACY_SERVER_CONNECT:4,SSL_OP_MICROSOFT_BIG_SSLV3_BUFFER:32,SSL_OP_MICROSOFT_SESS_ID_BUG:1,SSL_OP_MSIE_SSLV2_RSA_PADDING:0,SSL_OP_NETSCAPE_CA_DN_BUG:536870912,SSL_OP_NETSCAPE_CHALLENGE_BUG:2,SSL_OP_NETSCAPE_DEMO_CIPHER_CHANGE_BUG:1073741824,SSL_OP_NETSCAPE_REUSE_CIPHER_CHANGE_BUG:8,SSL_OP_NO_COMPRESSION:131072,SSL_OP_NO_QUERY_MTU:4096,SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION:65536,SSL_OP_NO_SSLv2:16777216,SSL_OP_NO_SSLv3:33554432,SSL_OP_NO_TICKET:16384,SSL_OP_NO_TLSv1:67108864,SSL_OP_NO_TLSv1_1:268435456,SSL_OP_NO_TLSv1_2:134217728,SSL_OP_PKCS1_CHECK_1:0,SSL_OP_PKCS1_CHECK_2:0,SSL_OP_SINGLE_DH_USE:1048576,SSL_OP_SINGLE_ECDH_USE:524288,SSL_OP_SSLEAY_080_CLIENT_DH_BUG:128,SSL_OP_SSLREF2_REUSE_CERT_TYPE_BUG:0,SSL_OP_TLS_BLOCK_PADDING_BUG:512,SSL_OP_TLS_D5_BUG:256,SSL_OP_TLS_ROLLBACK_BUG:8388608,ENGINE_METHOD_DSA:2,ENGINE_METHOD_DH:4,ENGINE_METHOD_RAND:8,ENGINE_METHOD_ECDH:16,ENGINE_METHOD_ECDSA:32,ENGINE_METHOD_CIPHERS:64,ENGINE_METHOD_DIGESTS:128,ENGINE_METHOD_STORE:256,ENGINE_METHOD_PKEY_METHS:512,ENGINE_METHOD_PKEY_ASN1_METHS:1024,ENGINE_METHOD_ALL:65535,ENGINE_METHOD_NONE:0,DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6,F_OK:0,R_OK:4,W_OK:2,X_OK:1,UV_UDP_REUSEADDR:4}},function(e,t,n){(function(t){var r=n(17).Transform,i=n(14).inherits;function o(e){r.call(this,e),this._destroyed=!1}function s(e,t,n){n(null,e)}function a(e){return function(t,n,r){return"function"==typeof t&&(r=n,n=t,t={}),"function"!=typeof n&&(n=s),"function"!=typeof r&&(r=null),e(t,n,r)}}i(o,r),o.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var n=this;t.nextTick(function(){e&&n.emit("error",e),n.emit("close")})}},e.exports=a(function(e,t,n){var r=new o(e);return r._transform=t,n&&(r._flush=n),r}),e.exports.ctor=a(function(e,t,n){function r(t){if(!(this instanceof r))return new r(t);this.options=Object.assign({},e,t),o.call(this,this.options)}return i(r,o),r.prototype._transform=t,n&&(r.prototype._flush=n),r}),e.exports.obj=a(function(e,t,n){var r=new o(Object.assign({objectMode:!0,highWaterMark:16},e));return r._transform=t,n&&(r._flush=n),r})}).call(this,n(3))},function(e,t,n){"use strict";const r=n(82),i=n(300),o=n(75),s=n(17),a=n(53);e.exports=(e=>(t,n)=>{n=n||{};const l=new s.PassThrough({objectMode:!0});try{t=r(t)}catch(e){if(!o.ipfsPath(t))return l.destroy(e)}const u={path:"get",args:t,qs:n};return e.andTransform(u,i,(e,t)=>{if(e)return l.destroy(e);a(t,l)}),l})},function(e,t,n){"use strict";const r=n(82),i=n(300),o=n(75),s=n(19),a=n(69),l=n(61);e.exports=(e=>(t,n)=>{n=n||{};const u=l.source();try{t=r(t)}catch(e){if(!o.ipfsPath(t))return u.end(e)}const c={path:"get",args:t,qs:n};return e.andTransform(c,i,(e,t)=>{if(e)return u.end(e);u.resolve(s(a.source(t),s.map(e=>{const{path:t,content:n}=e;return n?{path:t,content:a.source(n)}:e})))}),u})},function(e,t,n){"use strict";const r=n(2),i=n(75),o=n(23),s=n(82);function a(e){switch(e.Type){case 1:case 5:return"dir";case 2:return"file";default:return"unknown"}}e.exports=(e=>{const t=o(e);return r((e,n,r)=>{"function"==typeof n&&(r=n,n={});try{e=s(e)}catch(t){if(!i.ipfsPath(e))return r(t)}t({path:"ls",args:e,qs:n},(t,n)=>{if(t)return r(t);let i=n.Objects;return i?(i=i[0],i?(i=i.Links,Array.isArray(i)?(i=i.map(t=>({name:t.Name,path:e+"/"+t.Name,size:t.Size,hash:t.Hash,type:a(t),depth:t.Depth||1})),void r(null,i)):r(new Error("expected one array in results.Objects[0].Links"))):r(new Error("expected one array in results.Objects"))):r(new Error("expected .Objects in results"))})})})},function(e){e.exports={name:"ipfs-http-client",version:"29.1.1",description:"A client library for the IPFS HTTP API",leadMaintainer:"Alan Shaw <alan@tableflip.io>",main:"src/index.js",browser:{glob:!1,fs:!1,stream:"readable-stream",http:"stream-http"},scripts:{test:"aegir test","test:node":"aegir test -t node","test:browser":"aegir test -t browser","test:webworker":"aegir test -t webworker",lint:"aegir lint",build:"aegir build",release:"aegir release ","release-minor":"aegir release --type minor ","release-major":"aegir release --type major ",coverage:"aegir coverage --timeout 100000","coverage-publish":"aegir coverage --provider coveralls --timeout 100000","dep-check":"npx dependency-check package.json './test/**/*.js' './src/**/*.js'"},dependencies:{async:"^2.6.1","bignumber.js":"^8.0.2",bl:"^2.1.2",bs58:"^4.0.1",cids:"~0.5.5","concat-stream":"^2.0.0",debug:"^4.1.0","detect-node":"^2.0.4","end-of-stream":"^1.4.1","err-code":"^1.1.2",flatmap:"0.0.3",glob:"^7.1.3","ipfs-block":"~0.8.0","ipfs-unixfs":"~0.1.16","ipld-dag-cbor":"~0.13.0","ipld-dag-pb":"~0.15.0","is-ipfs":"~0.4.7","is-pull-stream":"0.0.0","is-stream":"^1.1.0","libp2p-crypto":"~0.16.0",lodash:"^4.17.11","lru-cache":"^5.1.1",multiaddr:"^6.0.0",multibase:"~0.6.0",multihashes:"~0.4.14",ndjson:"^1.5.0",once:"^1.4.0","peer-id":"~0.12.1","peer-info":"~0.15.0","promisify-es6":"^1.0.3","pull-defer":"~0.2.3","pull-pushable":"^2.2.0","pull-stream-to-stream":"^1.3.4",pump:"^3.0.0",qs:"^6.5.2","readable-stream":"^3.0.6","stream-http":"^3.0.0","stream-to-pull-stream":"^1.7.2",streamifier:"~0.1.1","tar-stream":"^1.6.2",through2:"^3.0.0"},engines:{node:">=10.0.0",npm:">=3.0.0"},repository:{type:"git",url:"https://github.com/ipfs/js-ipfs-http-client"},devDependencies:{aegir:"^18.0.2","browser-process-platform":"~0.1.1",chai:"^4.2.0","cross-env":"^5.2.0","dirty-chai":"^2.0.1","eslint-plugin-react":"^7.11.1","go-ipfs-dep":"~0.4.18","interface-ipfs-core":"~0.96.0","ipfsd-ctl":"github:ipfs/js-ipfsd-ctl",nock:"^10.0.2","pull-stream":"^3.6.9","stream-equal":"^1.1.1"},keywords:["ipfs"],contributors:["Alan Shaw <alan.shaw@protocol.ai>","Alan Shaw <alan@tableflip.io>","Alex Mingoia <talk@alexmingoia.com>","Alex Potsides <alex@achingbrain.net>","Antonio Tenorio-Fornés <antoniotenorio@ucm.es>","Bruno Barbieri <bbarbieri@delivery.com>","Clemo <flipflopsimsommer@users.noreply.github.com>","Connor Keenan <ckeenan89@gmail.com>","Danny <dannyid@protonmail.com>","David Braun <David.Braun@Toptal.com>","David Dias <daviddias.p@gmail.com>","Diogo Silva <fsdiogo@gmail.com>","Dmitriy Ryajov <dryajov@gmail.com>","Dmitry Nikulin <dmitr-nikulin@mail.ru>","Donatas Stundys <donatas.stundys@necolt.com>","Fil <fil@rezo.net>","Filip Š <filip.stamcar@hotmail.com>","Francisco Baio Dias <xicombd@gmail.com>","Friedel Ziegelmayer <dignifiedquire@gmail.com>","Gar <gar+gh@danger.computer>","Gavin McDermott <gavinmcdermott@gmail.com>","Greenkeeper <support@greenkeeper.io>","Haad <haadcode@users.noreply.github.com>","Harlan T Wood <harlantwood@users.noreply.github.com>","Harlan T Wood <code@harlantwood.net>","Henrique Dias <hacdias@gmail.com>","Holodisc <holodiscent@gmail.com>","Hugo Dias <mail@hugodias.me>","JGAntunes <j.goncalo.antunes@gmail.com>","Jacob Heun <jacobheun@gmail.com>","James Halliday <substack@gmail.com>","Jason Carver <jacarver@linkedin.com>","Jason Papakostas <vith@users.noreply.github.com>","Jeff Downie <JeffDownie@users.noreply.github.com>","Jeromy <why@ipfs.io>","Jeromy <jeromyj@gmail.com>","Joe Turgeon <arithmetric@gmail.com>","Jonathan <jkrone@vt.edu>","Juan Batiz-Benet <juan@benet.ai>","Kevin Wang <kevin@fossa.io>","Kristoffer Ström <kristoffer@rymdkoloni.se>","Marcin Rataj <lidel@lidel.org>","Matt Bell <mappum@gmail.com>","Maxime Lathuilière <k@maxlath.eu>","Michael Muré <batolettre@gmail.com>","Mikeal Rogers <mikeal.rogers@gmail.com>","Mitar <mitar.git@tnode.com>","Mithgol <getgit@mithgol.ru>","Mohamed Abdulaziz <mohamed@mohamedabdulaziz.com>","Nuno Nogueira <nunofmn@gmail.com>","Níckolas Goline <nickolas.goline@gmail.com>","Oli Evans <oli@tableflip.io>","Orie Steele <orie@ohs.io>","Pedro Teixeira <i@pgte.me>","Pete Thomas <pete@xminusone.net>","Richard Littauer <richard.littauer@gmail.com>","Richard Schneider <makaretu@gmail.com>","Roman Khafizianov <requilence@gmail.com>","SeungWon <ksw3894@gmail.com>","Stephen Whitmore <stephen.whitmore@gmail.com>","Tara Vancil <tbvanc@gmail.com>","Travis Person <travis@protocol.ai>","Travis Person <travis.person@gmail.com>","Vasco Santos <vasco.santos@ua.pt>","Vasco Santos <vasco.santos@moxy.studio>","Victor Bjelkholm <victor@typeform.com>","Volker Mische <volker.mische@gmail.com>","Zhiyuan Lin <edsgerlin@gmail.com>","dmitriy ryajov <dryajov@dmitriys-MacBook-Pro.local>","elsehow <yes@cosmopol.is>","ethers <ethereum@outlook.com>","haad <haad@headbanggames.com>","kumavis <kumavis@users.noreply.github.com>","leekt216 <leekt216@gmail.com>","nginnever <ginneversource@gmail.com>","noah the goodra <peterpan0413@live.com>","priecint <tp-dev@seznam.cz>","samuli <samuli@nugg.ad>","shunkin <hiyoko.san.ipod@gmail.com>","victorbjelkholm <victorbjelkholm@gmail.com>","Łukasz Magiera <magik6k@users.noreply.github.com>","Łukasz Magiera <magik6k@gmail.com>"],license:"MIT",bugs:{url:"https://github.com/ipfs/js-ipfs-http-client/issues"},homepage:"https://github.com/ipfs/js-ipfs-http-client"}},function(e,t,n){"use strict";var r=n(1309),i=n(1310),o=n(538);e.exports={formats:o,parse:i,stringify:r}},function(e,t,n){"use strict";var r=n(301),i=n(538),o=Object.prototype.hasOwnProperty,s={brackets:function e(t){return t+"[]"},comma:"comma",indices:function e(t,n){return t+"["+n+"]"},repeat:function e(t){return t}},a=Array.isArray,l=Array.prototype.push,u=function(e,t){l.apply(e,a(t)?t:[t])},c=Date.prototype.toISOString,h={addQueryPrefix:!1,allowDots:!1,charset:"utf-8",charsetSentinel:!1,delimiter:"&",encode:!0,encoder:r.encode,encodeValuesOnly:!1,formatter:i.formatters[i.default],indices:!1,serializeDate:function e(t){return c.call(t)},skipNulls:!1,strictNullHandling:!1},f=function e(t,n,i,o,s,l,c,f,p,d,m,g,y){var v=t;if("function"==typeof c?v=c(n,v):v instanceof Date?v=d(v):"comma"===i&&a(v)&&(v=v.join(",")),null===v){if(o)return l&&!g?l(n,h.encoder,y):n;v=""}if("string"==typeof v||"number"==typeof v||"boolean"==typeof v||r.isBuffer(v)){if(l){var b=g?n:l(n,h.encoder,y);return[m(b)+"="+m(l(v,h.encoder,y))]}return[m(n)+"="+m(String(v))]}var _=[],w;if(void 0===v)return _;if(a(c))w=c;else{var k=Object.keys(v);w=f?k.sort(f):k}for(var E=0;E<w.length;++E){var S=w[E];s&&null===v[S]||(a(v)?u(_,e(v[S],"function"==typeof i?i(n,S):n,i,o,s,l,c,f,p,d,m,g,y)):u(_,e(v[S],n+(p?"."+S:"["+S+"]"),i,o,s,l,c,f,p,d,m,g,y)))}return _},p=function e(t){if(!t)return h;if(null!==t.encoder&&void 0!==t.encoder&&"function"!=typeof t.encoder)throw new TypeError("Encoder has to be a function.");var n=t.charset||h.charset;if(void 0!==t.charset&&"utf-8"!==t.charset&&"iso-8859-1"!==t.charset)throw new TypeError("The charset option must be either utf-8, iso-8859-1, or undefined");var r=i.default;if(void 0!==t.format){if(!o.call(i.formatters,t.format))throw new TypeError("Unknown format option provided.");r=t.format}var s=i.formatters[r],l=h.filter;return("function"==typeof t.filter||a(t.filter))&&(l=t.filter),{addQueryPrefix:"boolean"==typeof t.addQueryPrefix?t.addQueryPrefix:h.addQueryPrefix,allowDots:void 0===t.allowDots?h.allowDots:!!t.allowDots,charset:n,charsetSentinel:"boolean"==typeof t.charsetSentinel?t.charsetSentinel:h.charsetSentinel,delimiter:void 0===t.delimiter?h.delimiter:t.delimiter,encode:"boolean"==typeof t.encode?t.encode:h.encode,encoder:"function"==typeof t.encoder?t.encoder:h.encoder,encodeValuesOnly:"boolean"==typeof t.encodeValuesOnly?t.encodeValuesOnly:h.encodeValuesOnly,filter:l,formatter:s,serializeDate:"function"==typeof t.serializeDate?t.serializeDate:h.serializeDate,skipNulls:"boolean"==typeof t.skipNulls?t.skipNulls:h.skipNulls,sort:"function"==typeof t.sort?t.sort:null,strictNullHandling:"boolean"==typeof t.strictNullHandling?t.strictNullHandling:h.strictNullHandling}};e.exports=function(e,t){var n=e,r=p(t),i,o;"function"==typeof r.filter?(o=r.filter,n=o("",n)):a(r.filter)&&(o=r.filter,i=o);var l=[],c;if("object"!=typeof n||null===n)return"";c=t&&t.arrayFormat in s?t.arrayFormat:t&&"indices"in t?t.indices?"indices":"repeat":"indices";var h=s[c];i||(i=Object.keys(n)),r.sort&&i.sort(r.sort);for(var d=0;d<i.length;++d){var m=i[d];r.skipNulls&&null===n[m]||u(l,f(n[m],m,h,r.strictNullHandling,r.skipNulls,r.encode?r.encoder:null,r.filter,r.sort,r.allowDots,r.serializeDate,r.formatter,r.encodeValuesOnly,r.charset))}var g=l.join(r.delimiter),y=!0===r.addQueryPrefix?"?":"";return r.charsetSentinel&&("iso-8859-1"===r.charset?y+="utf8=%26%2310003%3B&":y+="utf8=%E2%9C%93&"),g.length>0?y+g:""}},function(e,t,n){"use strict";var r=n(301),i=Object.prototype.hasOwnProperty,o={allowDots:!1,allowPrototypes:!1,arrayLimit:20,charset:"utf-8",charsetSentinel:!1,comma:!1,decoder:r.decode,delimiter:"&",depth:5,ignoreQueryPrefix:!1,interpretNumericEntities:!1,parameterLimit:1e3,parseArrays:!0,plainObjects:!1,strictNullHandling:!1},s=function(e){return e.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(parseInt(t,10))})},a="utf8=%26%2310003%3B",l="utf8=%E2%9C%93",u=function e(t,n){var u={},c=n.ignoreQueryPrefix?t.replace(/^\?/,""):t,h=n.parameterLimit===1/0?void 0:n.parameterLimit,f=c.split(n.delimiter,h),p=-1,d,m=n.charset;if(n.charsetSentinel)for(d=0;d<f.length;++d)0===f[d].indexOf("utf8=")&&(f[d]===l?m="utf-8":f[d]===a&&(m="iso-8859-1"),p=d,d=f.length);for(d=0;d<f.length;++d)if(d!==p){var g=f[d],y=g.indexOf("]="),v=-1===y?g.indexOf("="):y+1,b,_;-1===v?(b=n.decoder(g,o.decoder,m),_=n.strictNullHandling?null:""):(b=n.decoder(g.slice(0,v),o.decoder,m),_=n.decoder(g.slice(v+1),o.decoder,m)),_&&n.interpretNumericEntities&&"iso-8859-1"===m&&(_=s(_)),_&&n.comma&&_.indexOf(",")>-1&&(_=_.split(",")),i.call(u,b)?u[b]=r.combine(u[b],_):u[b]=_}return u},c=function(e,t,n){for(var r=t,i=e.length-1;i>=0;--i){var o,s=e[i];if("[]"===s&&n.parseArrays)o=[].concat(r);else{o=n.plainObjects?Object.create(null):{};var a="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(a,10);n.parseArrays||""!==a?!isNaN(l)&&s!==a&&String(l)===a&&l>=0&&n.parseArrays&&l<=n.arrayLimit?(o=[],o[l]=r):o[a]=r:o={0:r}}r=o}return r},h=function e(t,n,r){if(t){var o=r.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,s=/(\[[^[\]]*])/,a=/(\[[^[\]]*])/g,l=s.exec(o),u=l?o.slice(0,l.index):o,h=[];if(u){if(!r.plainObjects&&i.call(Object.prototype,u)&&!r.allowPrototypes)return;h.push(u)}for(var f=0;null!==(l=a.exec(o))&&f<r.depth;){if(f+=1,!r.plainObjects&&i.call(Object.prototype,l[1].slice(1,-1))&&!r.allowPrototypes)return;h.push(l[1])}return l&&h.push("["+o.slice(l.index)+"]"),c(h,n,r)}},f=function e(t){if(!t)return o;if(null!==t.decoder&&void 0!==t.decoder&&"function"!=typeof t.decoder)throw new TypeError("Decoder has to be a function.");if(void 0!==t.charset&&"utf-8"!==t.charset&&"iso-8859-1"!==t.charset)throw new Error("The charset option must be either utf-8, iso-8859-1, or undefined");var n=void 0===t.charset?o.charset:t.charset;return{allowDots:void 0===t.allowDots?o.allowDots:!!t.allowDots,allowPrototypes:"boolean"==typeof t.allowPrototypes?t.allowPrototypes:o.allowPrototypes,arrayLimit:"number"==typeof t.arrayLimit?t.arrayLimit:o.arrayLimit,charset:n,charsetSentinel:"boolean"==typeof t.charsetSentinel?t.charsetSentinel:o.charsetSentinel,comma:"boolean"==typeof t.comma?t.comma:o.comma,decoder:"function"==typeof t.decoder?t.decoder:o.decoder,delimiter:"string"==typeof t.delimiter||r.isRegExp(t.delimiter)?t.delimiter:o.delimiter,depth:"number"==typeof t.depth?t.depth:o.depth,ignoreQueryPrefix:!0===t.ignoreQueryPrefix,interpretNumericEntities:"boolean"==typeof t.interpretNumericEntities?t.interpretNumericEntities:o.interpretNumericEntities,parameterLimit:"number"==typeof t.parameterLimit?t.parameterLimit:o.parameterLimit,parseArrays:!1!==t.parseArrays,plainObjects:"boolean"==typeof t.plainObjects?t.plainObjects:o.plainObjects,strictNullHandling:"boolean"==typeof t.strictNullHandling?t.strictNullHandling:o.strictNullHandling}};e.exports=function(e,t){var n=f(t);if(""===e||null===e||void 0===e)return n.plainObjects?Object.create(null):{};for(var i="string"==typeof e?u(e,n):e,o=n.plainObjects?Object.create(null):{},s=Object.keys(i),a=0;a<s.length;++a){var l=s[a],c=h(l,i[l],n);o=r.merge(o,c,n)}return r.compact(o)}},function(e,t,n){(function(t){var r=n(17).Transform,i=n(14).inherits;function o(e){r.call(this,e),this._destroyed=!1}function s(e,t,n){n(null,e)}function a(e){return function(t,n,r){return"function"==typeof t&&(r=n,n=t,t={}),"function"!=typeof n&&(n=s),"function"!=typeof r&&(r=null),e(t,n,r)}}i(o,r),o.prototype.destroy=function(e){if(!this._destroyed){this._destroyed=!0;var n=this;t.nextTick(function(){e&&n.emit("error",e),n.emit("close")})}},e.exports=a(function(e,t,n){var r=new o(e);return r._transform=t,n&&(r._flush=n),r}),e.exports.ctor=a(function(e,t,n){function r(t){if(!(this instanceof r))return new r(t);this.options=Object.assign({},e,t),o.call(this,this.options)}return i(r,o),r.prototype._transform=t,n&&(r.prototype._flush=n),r}),e.exports.obj=a(function(e,t,n){var r=new o(Object.assign({objectMode:!0,highWaterMark:16},e));return r._transform=t,n&&(r._flush=n),r})}).call(this,n(3))},function(e,t,n){"use strict";const{Transform:r}=n(17),{StringDecoder:i}=n(18),o=Symbol("last"),s=Symbol("decoder");function a(e,t,n){var r;if(this.overflow){var i=this[s].write(e);if(r=i.split(this.matcher),1===r.length)return n();r.shift(),this.overflow=!1}else this[o]+=this[s].write(e),r=this[o].split(this.matcher);this[o]=r.pop();for(var a=0;a<r.length;a++)u(this,this.mapper(r[a]));if(this.overflow=this[o].length>this.maxLength,this.overflow&&!this.skipOverflow)return n(new Error("maximum buffer reached"));n()}function l(e){this[o]+=this[s].end(),this[o]&&u(this,this.mapper(this[o])),e()}function u(e,t){void 0!==t&&e.push(t)}function c(e){return e}function h(e,t,n){switch(e=e||/\r?\n/,t=t||c,n=n||{},arguments.length){case 1:"function"==typeof e?(t=e,e=/\r?\n/):"object"!=typeof e||e instanceof RegExp||(n=e,e=/\r?\n/);break;case 2:"function"==typeof e?(n=t,t=e,e=/\r?\n/):"object"==typeof t&&(n=t,t=c)}n=Object.assign({},n),n.transform=a,n.flush=l,n.readableObjectMode=!0;const u=new r(n);return u[o]="",u[s]=new i("utf8"),u.matcher=e,u.mapper=t,u.maxLength=n.maxLength,u.skipOverflow=n.skipOverflow,u.overflow=!1,u}e.exports=h},function(e,t,n){"use strict";(function(t){const r=n(91);function i(e,n){r(e,(e,r)=>{if(e)return n(e);if(!r||0===r.length)return n();let i;t.isBuffer(r)&&(r=r.toString());try{i=JSON.parse(r)}catch(e){return n(e)}n(null,i)})}e.exports=i}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(23),i=n(17),o=n(75),s=n(82);function a(e){switch(e.Type){case 1:case 5:return"dir";case 2:return"file";default:return"unknown"}}e.exports=(e=>{const t=r(e);return(e,n,r)=>{"function"==typeof n&&(r=n,n={});try{e=s(e)}catch(t){if(!o.ipfsPath(e))return r(t)}const l=new i.PassThrough({objectMode:!0});return t({path:"ls",args:e,qs:n},(t,n)=>{if(t)return r(t);let i=n.Objects;return i?(i=i[0],i?(i=i.Links,Array.isArray(i)?(i=i.map(t=>({depth:1,name:t.Name,path:e+"/"+t.Name,size:t.Size,hash:t.Hash,type:a(t)})),i.forEach(e=>l.write(e)),void l.end()):r(new Error("expected one array in results.Objects[0].Links"))):r(new Error("expected one array in results.Objects"))):r(new Error("expected .Objects in results"))}),l}})},function(e,t,n){"use strict";const r=n(23),i=n(19),o=n(61),s=n(75),a=n(82);function l(e){switch(e.Type){case 1:case 5:return"dir";case 2:return"file";default:return"unknown"}}e.exports=(e=>{const t=r(e);return(e,n,r)=>{"function"==typeof n&&(r=n,n={});try{e=a(e)}catch(t){if(!s.ipfsPath(e))return r(t)}const u=o.source();return t({path:"ls",args:e,qs:n},(t,n)=>{if(t)return r(t);let o=n.Objects;return o?(o=o[0],o?(o=o.Links,Array.isArray(o)?(o=o.map(t=>({depth:1,name:t.Name,path:e+"/"+t.Name,size:t.Size,hash:t.Hash,type:l(t)})),void u.resolve(i.values(o))):r(new Error("expected one array in results.Objects[0].Links"))):r(new Error("expected one array in results.Objects"))):r(new Error("expected .Objects in results"))}),u}})},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(114),o=n(9),s=n(91);e.exports=(e=>r((n,r,a)=>{let l;"function"==typeof r&&(a=r,r={});try{if(o.isCID(n))l=n,n=l.toBaseEncodedString();else if(t.isBuffer(n))l=new o(n),n=l.toBaseEncodedString();else{if("string"!=typeof n)return a(new Error("invalid argument"));l=new o(n)}}catch(e){return a(e)}const u=(e,n)=>{t.isBuffer(e)?n(null,new i(e,l)):Array.isArray(e)&&0===e.length?n(null,new i(t.alloc(0),l)):s(e,(e,r)=>{if(e)return n(e);r.length||(r=t.alloc(0)),n(null,new i(r,l))})},c={path:"block/get",args:n,qs:r};e.andTransform(c,u,a)}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(2),i=n(9),o=n(27);e.exports=(e=>r((t,n,r)=>{t&&i.isCID(t)&&(t=o.toB58String(t.multihash)),"function"==typeof n&&(r=n,n={});const s={path:"block/stat",args:t,qs:n},a=(e,t)=>{t(null,{key:e.Key,size:e.Size})};e.andTransform(s,a,r)}))},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(114),o=n(9),s=n(27),a=n(134);e.exports=(e=>{const n=a(e,"block/put");return r((e,r,a)=>{if("function"==typeof r&&(a=r,r={}),r=r||{},Array.isArray(e))return a(new Error("block.put accepts only one block"));if(t.isBuffer(e)&&(e={data:e}),!e||!e.data)return a(new Error("invalid block arg"));const l={};if(e.cid||r.cid){let t;try{t=new o(e.cid||r.cid)}catch(e){return a(e)}const{name:n,length:i}=s.decode(t.multihash);l.format=t.codec,l.mhtype=n,l.mhlen=i,l.version=t.version}else r.format&&(l.format=r.format),r.mhtype&&(l.mhtype=r.mhtype),r.mhlen&&(l.mhlen=r.mhlen),null!=r.version&&(l.version=r.version);n(e.data,{qs:l},(t,r)=>{if(t)return"dag-pb"===l.format||"dag-cbor"===l.format?(l.format="dag-pb"===l.format?"protobuf":"cbor",n(e.data,{qs:l},(t,n)=>{if(t)return a(t);a(null,new i(e.data,new o(n.Key)))})):a(t);a(null,new i(e.data,new o(r.Key)))})})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{wantlist:n(1320)(t),stat:n(1321)(t),unwant:n(1322)(t)}})},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r)=>{if("function"==typeof t?(r=t,n={},t=null):"function"==typeof n&&(r=n,n={}),t)try{n.peer=new i(t).toBaseEncodedString()}catch(e){return r(e)}e({path:"bitswap/wantlist",qs:n},r)}))},function(e,t,n){"use strict";const r=n(2),i=n(55),o=function(e,t){t(null,{provideBufLen:e.ProvideBufLen,wantlist:e.Wantlist||[],peers:e.Peers||[],blocksReceived:new i(e.BlocksReceived),dataReceived:new i(e.DataReceived),blocksSent:new i(e.BlocksSent),dataSent:new i(e.DataSent),dupBlksReceived:new i(e.DupBlksReceived),dupDataReceived:new i(e.DupDataReceived)})};e.exports=(e=>r(t=>{e.andTransform({path:"bitswap/stat"},o,t)}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={});try{t=new i(t)}catch(e){return r(e)}e({path:"bitswap/unwant",args:t.toBaseEncodedString(),qs:n},r)}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{get:n(1324)(t),put:n(1325)(t)}})},function(e,t,n){"use strict";const r=n(34),i=n(189),o=n(2),s=n(9),a=n(10),l=n(540),u={"dag-cbor":i.resolver,"dag-pb":r.resolver};e.exports=(e=>o((t,n,r,i)=>{"function"==typeof n&&(i=n,n=void 0),"function"==typeof r&&(i=r,r={}),r=r||{},n=n||"",s.isCID(t)&&(t=t.toBaseEncodedString()),a([i=>{e({path:"dag/resolve",args:t+"/"+n,qs:r},i)},(t,n)=>{l(e).get(new s(t.Cid["/"]),(e,r)=>{n(e,r,t.RemPath)})},(e,t,n)=>{const r=u[e.cid.codec];if(!r){const t=new Error('ipfs-http-client is missing DAG resolver for "'+e.cid.codec+'" multicodec');return t.missingMulticodec=e.cid.codec,void n(t)}r.resolve(e.data,t,n)}],i)}))},function(e,t,n){"use strict";const r=n(34),i=n(189),o=n(2),s=n(9),a=n(27),l=n(134);e.exports=(e=>{const t=l(e,"dag/put");return o((e,n,o)=>{if("function"==typeof n&&(o=n),n=n||{},n.hash&&(n.hashAlg=n.hash,delete n.hash),n.cid&&(n.format||n.hashAlg))return o(new Error("Can't put dag node. Please provide either `cid` OR `format` and `hash` options."));if(n.format&&!n.hashAlg||!n.format&&n.hashAlg)return o(new Error("Can't put dag node. Please provide `format` AND `hash` options."));if(n.cid){let e;try{e=new s(n.cid)}catch(e){return o(e)}n.format=e.codec,n.hashAlg=a.decode(e.multihash).name,delete n.cid}const l={format:"dag-cbor",hashAlg:"sha2-256",inputEnc:"raw"};function u(e,r){if(e)return o(e);const i={qs:{hash:n.hashAlg,format:n.format,"input-enc":n.inputEnc}};t(r,i,(e,t)=>e?o(e):t.Cid?o(null,new s(t.Cid["/"])):o(t))}n=Object.assign(l,n),"dag-cbor"===n.format?i.util.serialize(e,u):"dag-pb"===n.format?r.util.serialize(e,u):u(null,e)})})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{get:n(1327)(t),put:n(1330)(t),data:n(1331)(t),links:n(1332)(t),stat:n(1333)(t),new:n(1334)(t),patch:{addLink:n(1335)(t),rmLink:n(1336)(t),setData:n(1337)(t),appendData:n(1338)(t)}}})},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(34),o=i.DAGNode,s=i.DAGLink,a=n(9),l=n(303),u={max:128},c=new l(u);e.exports=(e=>r((n,r,i)=>{let l;"function"==typeof r&&(i=r,r={}),r||(r={});try{n=new a(n),l=n.toBaseEncodedString()}catch(e){return i(e)}const u=c.get(l);if(u)return i(null,u);e({path:"object/get",args:l,qs:{"data-encoding":"base64"}},(e,n)=>{if(e)return i(e);n.Data=t.from(n.Data,"base64");const r=n.Links.map(e=>new s(e.Name,e.Size,e.Hash));o.create(n.Data,r,(e,t)=>{if(e)return i(e);c.set(l,t),i(null,t)})})}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";function r(e){var t=this;if(t instanceof r||(t=new r),t.tail=null,t.head=null,t.length=0,e&&"function"==typeof e.forEach)e.forEach(function(e){t.push(e)});else if(arguments.length>0)for(var n=0,i=arguments.length;n<i;n++)t.push(arguments[n]);return t}function i(e,t){e.tail=new s(t,e.tail,null,e),e.head||(e.head=e.tail),e.length++}function o(e,t){e.head=new s(t,null,e.head,e),e.tail||(e.tail=e.head),e.length++}function s(e,t,n,r){if(!(this instanceof s))return new s(e,t,n,r);this.list=r,this.value=e,t?(t.next=this,this.prev=t):this.prev=null,n?(n.prev=this,this.next=n):this.next=null}e.exports=r,r.Node=s,r.create=r,r.prototype.removeNode=function(e){if(e.list!==this)throw new Error("removing node which does not belong to this list");var t=e.next,n=e.prev;t&&(t.prev=n),n&&(n.next=t),e===this.head&&(this.head=t),e===this.tail&&(this.tail=n),e.list.length--,e.next=null,e.prev=null,e.list=null},r.prototype.unshiftNode=function(e){if(e!==this.head){e.list&&e.list.removeNode(e);var t=this.head;e.list=this,e.next=t,t&&(t.prev=e),this.head=e,this.tail||(this.tail=e),this.length++}},r.prototype.pushNode=function(e){if(e!==this.tail){e.list&&e.list.removeNode(e);var t=this.tail;e.list=this,e.prev=t,t&&(t.next=e),this.tail=e,this.head||(this.head=e),this.length++}},r.prototype.push=function(){for(var e=0,t=arguments.length;e<t;e++)i(this,arguments[e]);return this.length},r.prototype.unshift=function(){for(var e=0,t=arguments.length;e<t;e++)o(this,arguments[e]);return this.length},r.prototype.pop=function(){if(this.tail){var e=this.tail.value;return this.tail=this.tail.prev,this.tail?this.tail.next=null:this.head=null,this.length--,e}},r.prototype.shift=function(){if(this.head){var e=this.head.value;return this.head=this.head.next,this.head?this.head.prev=null:this.tail=null,this.length--,e}},r.prototype.forEach=function(e,t){t=t||this;for(var n=this.head,r=0;null!==n;r++)e.call(t,n.value,r,this),n=n.next},r.prototype.forEachReverse=function(e,t){t=t||this;for(var n=this.tail,r=this.length-1;null!==n;r--)e.call(t,n.value,r,this),n=n.prev},r.prototype.get=function(e){for(var t=0,n=this.head;null!==n&&t<e;t++)n=n.next;if(t===e&&null!==n)return n.value},r.prototype.getReverse=function(e){for(var t=0,n=this.tail;null!==n&&t<e;t++)n=n.prev;if(t===e&&null!==n)return n.value},r.prototype.map=function(e,t){t=t||this;for(var n=new r,i=this.head;null!==i;)n.push(e.call(t,i.value,this)),i=i.next;return n},r.prototype.mapReverse=function(e,t){t=t||this;for(var n=new r,i=this.tail;null!==i;)n.push(e.call(t,i.value,this)),i=i.prev;return n},r.prototype.reduce=function(e,t){var n,r=this.head;if(arguments.length>1)n=t;else{if(!this.head)throw new TypeError("Reduce of empty list with no initial value");r=this.head.next,n=this.head.value}for(var i=0;null!==r;i++)n=e(n,r.value,i),r=r.next;return n},r.prototype.reduceReverse=function(e,t){var n,r=this.tail;if(arguments.length>1)n=t;else{if(!this.tail)throw new TypeError("Reduce of empty list with no initial value");r=this.tail.prev,n=this.tail.value}for(var i=this.length-1;null!==r;i--)n=e(n,r.value,i),r=r.prev;return n},r.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;null!==n;t++)e[t]=n.value,n=n.next;return e},r.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;null!==n;t++)e[t]=n.value,n=n.prev;return e},r.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var n=new r;if(t<e||t<0)return n;e<0&&(e=0),t>this.length&&(t=this.length);for(var i=0,o=this.head;null!==o&&i<e;i++)o=o.next;for(;null!==o&&i<t;i++,o=o.next)n.push(o.value);return n},r.prototype.sliceReverse=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var n=new r;if(t<e||t<0)return n;e<0&&(e=0),t>this.length&&(t=this.length);for(var i=this.length,o=this.tail;null!==o&&i>t;i--)o=o.prev;for(;null!==o&&i>e;i--,o=o.prev)n.push(o.value);return n},r.prototype.reverse=function(){for(var e=this.head,t=this.tail,n=e;null!==n;n=n.prev){var r=n.prev;n.prev=n.next,n.next=r}return this.head=t,this.tail=e,this};try{n(1329)(r)}catch(e){}},function(e,t,n){"use strict";e.exports=function(e){e.prototype[Symbol.iterator]=function*(){for(let e=this.head;e;e=e.next)yield e.value}}},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(9),{DAGNode:o}=n(34),s=n(134),a=n(26);e.exports=(e=>{const n=s(e,"object/put");return r((e,r,s)=>{"function"==typeof r&&(s=r,r={});const l=a(s);r||(r={});let u={Data:null,Links:[]},c;if(t.isBuffer(e))r.enc||(u={Data:e.toString(),Links:[]});else if(o.isDAGNode(e))u={Data:e.data.toString(),Links:e.links.map(e=>{const t=e.toJSON();return t.hash=t.cid,t})};else{if("object"!=typeof e)return l(new Error("obj not recognized"));u.Data=e.Data.toString(),u.Links=e.Links}c=t.isBuffer(e)&&r.enc?e:t.from(JSON.stringify(u));const h=r.enc||"json",f={qs:{inputenc:h}};n(c,f,(e,t)=>{if(e)return l(e);l(null,new i(t.Hash))})})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(2),i=n(91),o=n(9),s=n(303),a={max:128},l=new s(a);e.exports=(e=>r((t,n,r)=>{let s;"function"==typeof n&&(r=n,n={}),n||(n={});try{t=new o(t),s=t.toBaseEncodedString()}catch(e){return r(e)}const a=l.get(s);if(a)return r(null,a.data);e({path:"object/data",args:s},(e,t)=>{if(e)return r(e);"function"==typeof t.pipe?i(t,r):r(null,t)})}))},function(e,t,n){"use strict";const r=n(2),i=n(34),o=i.DAGLink,s=n(9),a=n(303),l={max:128},u=new a(l);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n||(n={});try{t=new s(t)}catch(e){return r(e)}const i=u.get(t.toString());if(i)return r(null,i.links);e({path:"object/links",args:t.toString()},(e,t)=>{if(e)return r(e);let n=[];t.Links&&(n=t.Links.map(e=>new o(e.Name,e.Size,e.Hash))),r(null,n)})}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n||(n={});try{t=new i(t)}catch(e){return r(e)}e({path:"object/stat",args:t.toString()},r)}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t=void 0),e({path:"object/new",args:t},(e,t)=>{if(e)return n(e);n(null,new i(t.Hash))})}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r,o)=>{"function"==typeof r&&(o=r,r={}),r||(r={});try{t=new i(t)}catch(e){return o(e)}e({path:"object/patch/add-link",args:[t.toString(),n.name,n.cid.toString()]},(e,t)=>{if(e)return o(e);o(null,new i(t.Hash))})}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r,o)=>{"function"==typeof r&&(o=r,r={}),r||(r={});try{t=new i(t)}catch(e){return o(e)}e({path:"object/patch/rm-link",args:[t.toString(),n.name]},(e,t)=>{if(e)return o(e);o(null,new i(t.Hash))})}))},function(e,t,n){"use strict";const r=n(2),i=n(26),o=n(9),s=n(134);e.exports=(e=>{const t=s(e,"object/patch/set-data");return r((e,n,r,s)=>{"function"==typeof r&&(s=r,r={});const a=i(s);r||(r={});try{e=new o(e)}catch(e){return a(e)}t(n,{args:[e.toString()]},(e,t)=>{if(e)return a(e);a(null,new o(t.Hash))})})})},function(e,t,n){"use strict";const r=n(2),i=n(26),o=n(9),s=n(134);e.exports=(e=>{const t=s(e,"object/patch/append-data");return r((e,n,r,s)=>{"function"==typeof r&&(s=r,r={});const a=i(s);r||(r={});try{e=new o(e)}catch(e){return a(e)}t(n,{args:[e.toString()]},(e,t)=>{if(e)return a(e);a(null,new o(t.Hash))})})})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{add:n(1340)(t),rm:n(1341)(t),ls:n(1342)(t)}})},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n=null),e({path:"pin/add",args:t,qs:n},(e,t)=>{if(e)return r(e);r(null,t.Pins.map(e=>({hash:e})))})}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n=null),e({path:"pin/rm",args:t,qs:n},(e,t)=>{if(e)return r(e);r(null,t.Pins.map(e=>({hash:e})))})}))},function(e,t,n){"use strict";const r=n(2),i=n(149);e.exports=(e=>r((t,n,r)=>{"function"==typeof t&&(r=t,n=null,t=null),"function"==typeof n&&(r=n,n=null),t&&t.type&&(n=t,t=null),e({path:"pin/ls",args:t,qs:n},(e,t)=>{if(e)return r(e);r(null,i(t.Keys).map(e=>({hash:e,type:t.Keys[e].Type})))})}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{add:n(1344)(t),rm:n(1345)(t),list:n(1346)(t)}})},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),t&&"object"==typeof t&&(n=t,t=void 0),e({path:"bootstrap/add",args:t,qs:n},r)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),t&&"object"==typeof t&&(n=t,t=void 0),e({path:"bootstrap/rm",args:t,qs:n},r)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"bootstrap/list",qs:t},n)}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{get:n(1348)(t),put:n(1349)(t),findProvs:n(1350)(t),findPeer:n(1351)(t),provide:n(1352)(t),query:n(1353)(t)}})},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{function i(e,t,n){if(t)return e(t);if(!n)return e(new Error("empty response"));if(0===n.length)return e(new Error("no value returned for key"));if(Array.isArray(n)&&(n=n[0]),5===n.Type)e(null,n.Extra);else{let t=new Error("key was not found (type 6)");e(t)}}"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),e({path:"dht/get",args:t,qs:n},i.bind(null,r))}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r,i)=>{"function"!=typeof r||i||(i=r,r={}),"function"==typeof r&&"function"==typeof i&&(i=r,r={}),e({path:"dht/put",args:[t,n],qs:r},i)}))},function(e,t,n){"use strict";const r=n(2),i=n(304),o=n(22),s=n(15),a=n(31),l=n(13);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={});const u=(e,t)=>{if(Array.isArray(e)&&(e=e[0]),4!==e.Type){const e="key was not found (type 4)";return t(l(new Error(e),"ERR_KEY_TYPE_4_NOT_FOUND"))}const n=e.Responses.map(e=>{const t=new a(s.createFromB58String(e.ID));return e.Addrs.forEach(e=>{const n=o(e);t.multiaddrs.add(n)}),t});t(null,n)};e({path:"dht/findprovs",args:t,qs:n},(e,t)=>{if(e)return r(e);i(t,u,r)})}))},function(e,t,n){"use strict";const r=n(2),i=n(304),o=n(22),s=n(15),a=n(31),l=n(13);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={});const u=(e,t)=>{if(Array.isArray(e)&&(e=e[0]),2!==e.Type){const e="key was not found (type 2)";return t(l(new Error(e),"ERR_KEY_TYPE_2_NOT_FOUND"))}const n=e.Responses[0],r=new a(s.createFromB58String(n.ID));n.Addrs.forEach(e=>{const t=o(e);r.multiaddrs.add(t)}),t(null,r)};e({path:"dht/findpeer",args:t,qs:n},(e,t)=>{if(e)return r(e);i(t,u,r)})}))},function(e,t,n){"use strict";const r=n(2),i=n(9);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),Array.isArray(t)||(t=[t]);try{t=t.map(e=>new i(e).toBaseEncodedString("base58btc"))}catch(e){return r(e)}e({path:"dht/provide",args:t,qs:n},r)}))},function(e,t,n){"use strict";const r=n(2),i=n(304),o=n(15),s=n(31);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={});const a=(e,t)=>{const n=e.map(e=>new s(o.createFromB58String(e.ID)));t(null,n)};e({path:"dht/query",args:t,qs:n},(e,t)=>{if(e)return r(e);i(t,a,r)})}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{publish:n(1355)(t),resolve:n(1356)(t),pubsub:n(1357)(t)}})},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{name:e.Name,value:e.Value})};e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e.andTransform({path:"name/publish",args:t,qs:n},i,r)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,e.Path)};e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e.andTransform({path:"name/resolve",args:t,qs:n},i,r)}))},function(e,t,n){"use strict";e.exports=(e=>({cancel:n(1358)(e),state:n(1359)(e),subs:n(1360)(e)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{canceled:void 0===e.Canceled||!0===e.Canceled})};e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e.andTransform({path:"name/pubsub/cancel",args:t,qs:n},i,r)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{enabled:e.Enabled})};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"name/pubsub/state",qs:t},i,n)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,e.Strings||[])};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"name/pubsub/subs",qs:t},i,n)}))},function(e,t,n){"use strict";const r=n(2),i=n(53),o=n(17).Writable,s=n(23),a=n(305);e.exports=(e=>{const t=s(e);return r((e,n,r)=>{if("function"==typeof n&&(r=n,n={}),n.n&&n.count)return r(new Error("Use either n or count, not both"));n.n||n.count||(n.n=1);const s={path:"ping",args:e,qs:n},l=(e,t)=>{const n=new a,r=[];i(e,n,new o({objectMode:!0,write(e,t,n){r.push(e),n()}}),e=>{if(e)return t(e);t(null,r)})};t.andTransform(s,l,r)})})},function(e,t,n){"use strict";function r(e){return e&&"boolean"==typeof e.Success}e.exports=function e(t){if(!r(t))throw new Error("Invalid ping message received");return{success:t.Success,time:t.Time,text:t.Text}}},function(e,t,n){"use strict";const r=n(53),i=n(23),o=n(305);e.exports=(e=>{const t=i(e);return(e,n={})=>{n.n||n.count||(n.n=1);const i={path:"ping",args:e,qs:n},s=new o;return t(i,(e,t)=>{if(e)return s.emit("error",e);r(t,s)}),s}})},function(e,t,n){"use strict";const r=n(69),i=n(61),o=n(53),s=n(23),a=n(305);e.exports=(e=>{const t=s(e);return(e,n={})=>{n.n||n.count||(n.n=1);const s={path:"ping",args:e,qs:n},l=i.source(),u=new a;return t(s,(e,t)=>{if(e)return l.abort(e);o(t,u),l.resolve(r.source(u))}),l}})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{peers:n(1366)(t),connect:n(1367)(t),disconnect:n(1368)(t),addrs:n(1369)(t),localAddrs:n(1370)(t)}})},function(e,t,n){"use strict";const r=n(2),i=n(22),o=n(15);function s(e,t){return Array.isArray(t.Strings)?t.Strings.map(a.bind(null,e)):Array.isArray(t.Peers)?t.Peers.map(l.bind(null,e)):[]}function a(e,t){const n={};try{if(e){const e=t.split(" ");n.addr=i(e[0]),n.latency=e[1]}else n.addr=i(t);n.peer=o.createFromB58String(n.addr.getPeerId())}catch(e){n.error=e,n.rawPeerInfo=t}return n}function l(e,t){const n={};try{n.addr=i(t.Addr),n.peer=o.createFromB58String(t.Peer),n.muxer=t.Muxer}catch(e){n.error=e,n.rawPeerInfo=t}return t.Latency&&(n.latency=t.Latency),t.Streams&&(n.streams=t.Streams),n}e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={});const r=t.v||t.verbose;e({path:"swarm/peers",qs:t},(e,t)=>{if(e)return n(e);const i=s(r,t);n(null,i)})}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e({path:"swarm/connect",args:t,qs:n},r)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e({path:"swarm/disconnect",args:t,qs:n},r)}))},function(e,t,n){"use strict";const r=n(2),i=n(31),o=n(15),s=n(22);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"swarm/addrs",qs:t},(e,t)=>{if(e)return n(e);const r=Object.keys(t.Addrs).map(e=>{const n=new i(o.createFromB58String(e));return t.Addrs[e].forEach(e=>{n.multiaddrs.add(s(e))}),n});n(null,r)})}))},function(e,t,n){"use strict";const r=n(2),i=n(22);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"swarm/addrs/local",qs:t},(e,t)=>{if(e)return n(e);n(null,t.Strings.map(e=>i(e)))})}))},function(e,t,n){"use strict";(function(t){const r=n(2),i=n(6),o=n(212),s=n(168),a=n(20),l=n(1372),u=n(1374),c=n(23),h=()=>new Error("pubsub is currently not supported when run in the browser");e.exports=(e=>{const n=c(e),f=new i,p={};return f.id=Math.random(),{subscribe:(e,t,n,r)=>{const i={discover:!1};return"function"==typeof n&&(r=n,n=i),n||(n=i),s?r?void d(e,t,n,r):new Promise((r,i)=>{d(e,t,n,e=>{if(e)return i(e);r()})}):r?a(()=>r(h())):Promise.reject(h())},unsubscribe:(e,t,n)=>{if(!s)return n?a(()=>n(h())):Promise.reject(h());if(0===f.listenerCount(e)||!p[e]){const t=new Error(`Not subscribed to '${e}'`);return n?a(()=>n(t)):Promise.reject(t)}return f.removeListener(e,t),0===f.listenerCount(e)?n?(o(p[e].res,e=>{setTimeout(()=>n(e))}),p[e].req.abort(),void(p[e]=null)):new Promise((t,n)=>{o(p[e].res,e=>{setTimeout(()=>{if(e)return n(e);t()})}),p[e].req.abort(),p[e]=null}):n?void a(()=>n()):Promise.resolve()},publish:r((e,r,i)=>{if(!s)return i(h());if(!t.isBuffer(r))return i(new Error("data must be a Buffer"));const o={path:"pubsub/pub",args:[e,r]};n(o,i)}),ls:r(e=>{if(!s)return e(h());const t={path:"pubsub/ls"};n.andTransform(t,u,e)}),peers:r((e,t)=>{if(!s)return t(h());const r={path:"pubsub/peers",args:[e]};n.andTransform(r,u,t)}),setMaxListeners:e=>f.setMaxListeners(e)};function d(e,t,r,i){if(f.on(e,t),p[e])return i();const s={path:"pubsub/sub",args:[e],qs:{discover:r.discover}};p[e]={},p[e].req=n.andTransform(s,l.from,(n,r)=>{if(n)return p[e]=null,f.removeListener(e,t),i(n);p[e].res=r,r.on("data",t=>{f.emit(e,t)}),r.on("error",e=>{f.emit("error",e)}),o(r,n=>{n&&f.emit("error",n),p[e]=null,f.removeListener(e,t)}),i()})}})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(17).Transform,i=n(1373);class o extends r{constructor(e){const t=Object.assign(e||{},{objectMode:!0});super(t)}static from(e,t){let n=e.pipe(new o);e.on("end",()=>n.emit("end")),t(null,n)}_transform(e,t,n){if(0===Object.keys(e).length)return n();try{const t=i.deserialize(e,"base64");this.push(t),n()}catch(e){return n(e)}}}e.exports=o},function(e,t,n){"use strict";(function(t){const r=n(70);function i(e){const t=JSON.parse(e);return o(t)}function o(e){if(!s(e))throw new Error("Not a pubsub message");return{from:r.encode(t.from(e.from,"base64")).toString(),seqno:t.from(e.seqno,"base64"),data:t.from(e.data,"base64"),topicIDs:e.topicIDs||e.topicCIDs}}function s(e){return e&&e.from&&e.seqno&&e.data&&(e.topicIDs||e.topicCIDs)}e.exports={deserialize(e,t){if(t=t?t.toLowerCase():"json","json"===t)return i(e);if("base64"===t)return o(e);throw new Error(`Unsupported encoding: '${t}'`)}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";function r(e,t){t(null,e.Strings||[])}e.exports=r},function(e,t,n){"use strict";const r=n(2),i=n(23),o=function(e,t){t(null,e.Path)};e.exports=(e=>{const t=i(e);return r((e,n,r)=>{"function"==typeof n&&(r=n,n={}),t.andTransform({path:"dns",args:e,qs:n},o,r)})})},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return r(e=>{t({path:"commands"},e)})})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{get:n(1378)(t),set:n(1379)(t),replace:n(1380)(t)}})},function(e,t,n){"use strict";(function(t){const r=n(2),i=function(e,n){t.isBuffer(e)?n(null,JSON.parse(e.toString())):n(null,e)};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t=void 0),t?e.andTransform({path:"config",args:t,buffer:!0},i,(e,t)=>{if(e)return n(e);n(null,t.Value)}):e.andTransform({path:"config/show",buffer:!0},i,n)}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(2);e.exports=(e=>r((n,r,i,o)=>("function"==typeof i&&(o=i,i={}),"string"!=typeof n?o(new Error("Invalid key type")):void 0===r||t.isBuffer(r)?o(new Error("Invalid value type")):("object"==typeof r&&(r=JSON.stringify(r),i={json:!0}),"boolean"==typeof r&&(r=r.toString(),i={bool:!0}),void e({path:"config",args:[n,r],qs:i,files:void 0,buffer:!0},o)))))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){const r=n(1381),i=n(2),o=n(134);e.exports=(e=>{const n=o(e,"config/replace");return i((e,i)=>{"object"==typeof e&&(e=r.createReadStream(t.from(JSON.stringify(e)))),n(e,{},i)})})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){var r=n(14),i=n(62);e.exports.createReadStream=function(e,t){return new o(e,t)};var o=function(e,n){e instanceof t||"string"==typeof e?(n=n||{},i.Readable.call(this,{highWaterMark:n.highWaterMark,encoding:n.encoding})):i.Readable.call(this,{objectMode:!0}),this._object=e};r.inherits(o,i.Readable),o.prototype._read=function(){this.push(this._object),this._object=null}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{net:n(1383)(t),sys:n(1384)(t),cmds:n(1385)(t)}})},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"diag/net",qs:t},n)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"diag/sys",qs:t},n)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"diag/cmds",qs:t},n)}))},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return r((e,n)=>{"function"==typeof e&&(n=e,e=void 0),t({path:"id",args:e},(e,t)=>{if(e)return n(e);const r={id:t.ID,publicKey:t.PublicKey,addresses:t.Addresses,agentVersion:t.AgentVersion,protocolVersion:t.ProtocolVersion};n(null,r)})})})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{gen:n(1388)(t),list:n(1389)(t),rename:n(1390)(t),rm:n(1391)(t),export:n(1392)(t),import:n(1393)(t)}})},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{id:e.Id,name:e.Name})};e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e.andTransform({path:"key/gen",args:t,qs:n},i,r)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,e.Keys.map(e=>({id:e.Id,name:e.Name})))};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"key/list",qs:t},i,n)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{id:e.Id,was:e.Was,now:e.Now,overwrite:e.Overwrite})};e.exports=(e=>r((t,n,r)=>{e.andTransform({path:"key/rename",args:[t,n]},i,r)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{id:e.Keys[0].Id,name:e.Keys[0].Name})};e.exports=(e=>r((t,n)=>{e.andTransform({path:"key/rm",args:t},i,n)}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{e({path:"key/export",args:t,qs:{password:n}},(e,t)=>{if(e)return r(e);r(null,t.toString())})}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,{id:e.Id,name:e.Name})};e.exports=(e=>r((t,n,r,o)=>{e.andTransform({path:"key/import",args:t,qs:{pem:n,password:r}},i,o)}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{tail:n(1395)(t),ls:n(1396)(t),level:n(1397)(t)}})},function(e,t,n){"use strict";const r=n(2),i=n(53),o=n(302);e.exports=(e=>r(t=>e({path:"log/tail"},(e,n)=>{if(e)return t(e);const r=o.parse();i(n,r),t(null,r)})))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r(t=>{e({path:"log/ls"},(e,n)=>{if(e)return t(e);t(null,n.Strings)})}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r,i)=>("function"==typeof r&&(i=r,r={}),"string"!=typeof t?i(new Error("Invalid subsystem type")):"string"!=typeof n?i(new Error("Invalid level type")):void e({path:"log/level",args:[t,n],qs:r,files:void 0,buffer:!0},i))))},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return r((e,n,r)=>{"function"==typeof e?(r=e,e=null):"function"==typeof n&&(r=n,n=null);const i={};e&&(i.f=e),n&&(i.n=n),t({path:"mount",qs:i},r)})})},function(e,t,n){"use strict";const r=n(2),i=n(91),o=n(23);e.exports=(e=>{const t=o(e),n=r((e,n,r)=>{"function"==typeof n&&(r=n,n={});const o={path:"refs",args:e,qs:n};t.andTransform(o,i,r)});return n.local=r((e,n)=>{"function"==typeof e&&(n=e,e={});const r={path:"refs/local",qs:e};t.andTransform(r,i,n)}),n})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{gc:n(1401)(t),stat:n(1402)(t),version:n(1403)(t)}})},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e({path:"repo/gc",qs:t},n)}))},function(e,t,n){"use strict";const r=n(2),i=n(55),o=function(e,t){t(null,{numObjects:new i(e.NumObjects),repoSize:new i(e.RepoSize),repoPath:e.RepoPath,version:e.Version,storageMax:new i(e.StorageMax)})};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"repo/stat",qs:t},o,n)}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){t(null,e.Version)};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"repo/version",qs:t},i,n)}))},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return r(e=>{t({path:"shutdown"},e)})})},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{bitswap:n(1406)(t),bw:n(1407)(t),bwReadableStream:n(1408)(t),bwPullStream:n(1409)(t),repo:n(1410)(t)}})},function(e,t,n){"use strict";const r=n(2),i=n(55),o=function(e,t){t(null,{provideBufLen:e.ProvideBufLen,wantlist:e.Wantlist||[],peers:e.Peers||[],blocksReceived:new i(e.BlocksReceived),dataReceived:new i(e.DataReceived),blocksSent:new i(e.BlocksSent),dataSent:new i(e.DataSent),dupBlksReceived:new i(e.DupBlksReceived),dupDataReceived:new i(e.DupDataReceived)})};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"stats/bitswap",qs:t},o,n)}))},function(e,t,n){"use strict";const r=n(2),i=n(91),o=n(306),s=(e,t)=>i(e,(e,n)=>{if(e)return t(e);t(null,o(n[0]))});e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"stats/bw",qs:t},s,n)}))},function(e,t,n){"use strict";const r=n(17),i=n(53),o=n(306);e.exports=(e=>t=>{t=t||{};const n=new r.Transform({objectMode:!0,transform(e,t,n){n(null,o(e))}});return e({path:"stats/bw",qs:t},(e,t)=>{if(e)return n.destroy(e);i(t,n)}),n})},function(e,t,n){"use strict";const r=n(69),i=n(19),o=n(306),s=n(61);e.exports=(e=>t=>{t=t||{};const n=s.source();return e({path:"stats/bw",qs:t},(e,t)=>{if(e)return n.end(e);n.resolve(i(r.source(t),i.map(o)))}),n})},function(e,t,n){"use strict";const r=n(2),i=n(55),o=function(e,t){t(null,{numObjects:new i(e.NumObjects),repoSize:new i(e.RepoSize),repoPath:e.RepoPath,version:e.Version,storageMax:new i(e.StorageMax)})};e.exports=(e=>r((t,n)=>{"function"==typeof t&&(n=t,t={}),e.andTransform({path:"stats/repo",qs:t},o,n)}))},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return{apply:r((e,n)=>{"function"==typeof e&&(n=e,e={}),t({path:"update",qs:e},n)}),check:r((e,n)=>{"function"==typeof e&&(n=e,e={}),t({path:"update/check",qs:e},n)}),log:r((e,n)=>{"function"==typeof e&&(n=e,e={}),t({path:"update/log",qs:e},n)})}})},function(e,t,n){"use strict";const r=n(2),i=n(23);e.exports=(e=>{const t=i(e);return r((e,n)=>{"function"==typeof e&&(n=e,e={}),t({path:"version",qs:e},(e,t)=>{if(e)return n(e);const r={version:t.Version,commit:t.Commit,repo:t.Repo};n(null,r)})})})},function(e,t,n){"use strict";(function(t){const r=n(9),i=n(22),o=n(60),s=n(27),a=n(15),l=n(31);e.exports=(()=>({Buffer:t,CID:r,multiaddr:i,multibase:o,multihash:s,PeerId:a,PeerInfo:l}))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(2),i=n(60),o=n(9);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n=n||{},n.cidBase&&(n["cid-base"]=n.cidBase,delete n.cidBase);const s=(e,t)=>{if(!n["cid-base"])return t(null,e.Path);const r=e.Path.split("/");if(i.isEncoded(r[2])!==n["cid-base"])try{let i=new o(r[2]);0===i.version&&"base58btc"!==n["cid-base"]&&(i=i.toV1()),r[2]=i.toBaseEncodedString(n["cid-base"]),e.Path=r.join("/")}catch(e){return t(e)}t(null,e.Path)};e.andTransform({path:"resolve",args:t,qs:n},s,r)}))},function(e,t,n){"use strict";const r=n(23);e.exports=(e=>{const t=r(e);return{cp:n(1416)(t),mkdir:n(1417)(t),flush:n(1418)(t),stat:n(1419)(t),rm:n(1473)(t),ls:n(1474)(t),lsReadableStream:n(547)(t),lsPullStream:n(1475)(t),read:n(1476)(t),readReadableStream:n(1477)(t),readPullStream:n(1478)(t),write:n(1479)(t),mv:n(1480)(t)}})},function(e,t,n){"use strict";const r=n(2),i=n(541);e.exports=(e=>r(function(){const{callback:t,sources:n,opts:r}=i(Array.prototype.slice.call(arguments));e({path:"files/cp",args:n,qs:r},e=>t(e))}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e({path:"files/mkdir",args:t,qs:n},e=>r(e))}))},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n)=>("function"==typeof t&&(n=t,t="/"),e({path:"files/flush",args:t},e=>n(e)))))},function(e,t,n){"use strict";const r=n(2),i=n(1420),o=n(1463),s=function(e,t){t(null,{type:e.Type,blocks:e.Blocks,size:e.Size,hash:e.Hash,cumulativeSize:e.CumulativeSize,withLocality:e.WithLocality||!1,local:e.Local||void 0,sizeLocal:e.SizeLocal||void 0})};e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),n=i(n,(e,t)=>o(t)),e.andTransform({path:"files/stat",args:t,qs:n},s,r)}))},function(e,t,n){var r=n(1421),i=n(1423),o=n(1426);function s(e,t){var n={};return t=o(t,3),i(e,function(e,i,o){r(n,t(e,i,o),e)}),n}e.exports=s},function(e,t,n){var r=n(1422);function i(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}e.exports=i},function(e,t,n){var r=n(103),i=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=i},function(e,t,n){var r=n(1424),i=n(149);function o(e,t){return e&&r(e,t,i)}e.exports=o},function(e,t,n){var r=n(1425),i=r();e.exports=i},function(e,t){function n(e){return function(t,n,r){for(var i=-1,o=Object(t),s=r(t),a=s.length;a--;){var l=s[e?a:++i];if(!1===n(o[l],l,o))break}return t}}e.exports=n},function(e,t,n){var r=n(1427),i=n(1457),o=n(156),s=n(65),a=n(1461);function l(e){return"function"==typeof e?e:null==e?o:"object"==typeof e?s(e)?i(e[0],e[1]):r(e):a(e)}e.exports=l},function(e,t,n){var r=n(1428),i=n(1456),o=n(546);function s(e){var t=i(e);return 1==t.length&&t[0][2]?o(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}e.exports=s},function(e,t,n){var r=n(542),i=n(543),o=1,s=2;function a(e,t,n,a){var l=n.length,u=l,c=!a;if(null==e)return!u;for(e=Object(e);l--;){var h=n[l];if(c&&h[2]?h[1]!==e[h[0]]:!(h[0]in e))return!1}for(;++l<u;){h=n[l];var f=h[0],p=e[f],d=h[1];if(c&&h[2]){if(void 0===p&&!(f in e))return!1}else{var m=new r;if(a)var g=a(p,d,f,e,t,m);if(!(void 0===g?i(d,p,o|s,a,m):g))return!1}}return!0}e.exports=a},function(e,t,n){var r=n(219);function i(){this.__data__=new r,this.size=0}e.exports=i},function(e,t){function n(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}e.exports=n},function(e,t){function n(e){return this.__data__.get(e)}e.exports=n},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t,n){var r=n(219),i=n(287),o=n(286),s=200;function a(e,t){var n=this.__data__;if(n instanceof r){var a=n.__data__;if(!i||a.length<s-1)return a.push([e,t]),this.size=++n.size,this;n=this.__data__=new o(a)}return n.set(e,t),this.size=n.size,this}e.exports=a},function(e,t,n){var r=n(542),i=n(544),o=n(1440),s=n(1444),a=n(1451),l=n(65),u=n(330),c=n(332),h=1,f="[object Arguments]",p="[object Array]",d="[object Object]",m=Object.prototype,g=m.hasOwnProperty;function y(e,t,n,m,y,v){var b=l(e),_=l(t),w=b?p:a(e),k=_?p:a(t);w=w==f?d:w,k=k==f?d:k;var E=w==d,S=k==d,x=w==k;if(x&&u(e)){if(!u(t))return!1;b=!0,E=!1}if(x&&!E)return v||(v=new r),b||c(e)?i(e,t,n,m,y,v):o(e,t,w,n,m,y,v);if(!(n&h)){var C=E&&g.call(e,"__wrapped__"),A=S&&g.call(t,"__wrapped__");if(C||A){var T=C?e.value():e,I=A?t.value():t;return v||(v=new r),y(T,I,n,m,v)}}return!!x&&(v||(v=new r),s(e,t,n,m,y,v))}e.exports=y},function(e,t,n){var r=n(286),i=n(1436),o=n(1437);function s(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}s.prototype.add=s.prototype.push=i,s.prototype.has=o,e.exports=s},function(e,t){var n="__lodash_hash_undefined__";function r(e){return this.__data__.set(e,n),this}e.exports=r},function(e,t){function n(e){return this.__data__.has(e)}e.exports=n},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}e.exports=n},function(e,t){function n(e,t){return e.has(t)}e.exports=n},function(e,t,n){var r=n(182),i=n(1441),o=n(480),s=n(544),a=n(1442),l=n(1443),u=1,c=2,h="[object Boolean]",f="[object Date]",p="[object Error]",d="[object Map]",m="[object Number]",g="[object RegExp]",y="[object Set]",v="[object String]",b="[object Symbol]",_="[object ArrayBuffer]",w="[object DataView]",k=r?r.prototype:void 0,E=k?k.valueOf:void 0;function S(e,t,n,r,k,S,x){switch(n){case w:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return!(e.byteLength!=t.byteLength||!S(new i(e),new i(t)));case h:case f:case m:return o(+e,+t);case p:return e.name==t.name&&e.message==t.message;case g:case v:return e==t+"";case d:var C=a;case y:var A=r&u;if(C||(C=l),e.size!=t.size&&!A)return!1;var T=x.get(e);if(T)return T==t;r|=c,x.set(e,t);var I=s(C(e),C(t),r,k,S,x);return x.delete(e),I;case b:if(E)return E.call(e)==E.call(t)}return!1}e.exports=S},function(e,t,n){var r=n(79),i=r.Uint8Array;e.exports=i},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}e.exports=n},function(e,t){function n(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}e.exports=n},function(e,t,n){var r=n(1445),i=1,o=Object.prototype,s=o.hasOwnProperty;function a(e,t,n,o,a,l){var u=n&i,c=r(e),h=c.length,f=r(t),p=f.length;if(h!=p&&!u)return!1;for(var d=h;d--;){var m=c[d];if(!(u?m in t:s.call(t,m)))return!1}var g=l.get(e);if(g&&l.get(t))return g==t;var y=!0;l.set(e,t),l.set(t,e);for(var v=u;++d<h;){m=c[d];var b=e[m],_=t[m];if(o)var w=u?o(_,b,m,t,e,l):o(b,_,m,e,t,l);if(!(void 0===w?b===_||a(b,_,n,o,l):w)){y=!1;break}v||(v="constructor"==m)}if(y&&!v){var k=e.constructor,E=t.constructor;k!=E&&"constructor"in e&&"constructor"in t&&!("function"==typeof k&&k instanceof k&&"function"==typeof E&&E instanceof E)&&(y=!1)}return l.delete(e),l.delete(t),y}e.exports=a},function(e,t,n){var r=n(1446),i=n(1448),o=n(149);function s(e){return r(e,o,i)}e.exports=s},function(e,t,n){var r=n(1447),i=n(65);function o(e,t,n){var o=t(e);return i(e)?o:r(o,n(e))}e.exports=o},function(e,t){function n(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}e.exports=n},function(e,t,n){var r=n(1449),i=n(1450),o=Object.prototype,s=o.propertyIsEnumerable,a=Object.getOwnPropertySymbols,l=a?function(e){return null==e?[]:(e=Object(e),r(a(e),function(t){return s.call(e,t)}))}:i;e.exports=l},function(e,t){function n(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var s=e[n];t(s,n,e)&&(o[i++]=s)}return o}e.exports=n},function(e,t){function n(){return[]}e.exports=n},function(e,t,n){var r=n(1452),i=n(287),o=n(1453),s=n(1454),a=n(1455),l=n(108),u=n(479),c="[object Map]",h="[object Object]",f="[object Promise]",p="[object Set]",d="[object WeakMap]",m="[object DataView]",g=u(r),y=u(i),v=u(o),b=u(s),_=u(a),w=l;(r&&w(new r(new ArrayBuffer(1)))!=m||i&&w(new i)!=c||o&&w(o.resolve())!=f||s&&w(new s)!=p||a&&w(new a)!=d)&&(w=function(e){var t=l(e),n=t==h?e.constructor:void 0,r=n?u(n):"";if(r)switch(r){case g:return m;case y:return c;case v:return f;case b:return p;case _:return d}return t}),e.exports=w},function(e,t,n){var r=n(103),i=n(79),o=r(i,"DataView");e.exports=o},function(e,t,n){var r=n(103),i=n(79),o=r(i,"Promise");e.exports=o},function(e,t,n){var r=n(103),i=n(79),o=r(i,"Set");e.exports=o},function(e,t,n){var r=n(103),i=n(79),o=r(i,"WeakMap");e.exports=o},function(e,t,n){var r=n(545),i=n(149);function o(e){for(var t=i(e),n=t.length;n--;){var o=t[n],s=e[o];t[n]=[o,s,r(s)]}return t}e.exports=o},function(e,t,n){var r=n(543),i=n(476),o=n(1458),s=n(284),a=n(545),l=n(546),u=n(222),c=1,h=2;function f(e,t){return s(e)&&a(t)?l(u(e),t):function(n){var s=i(n,e);return void 0===s&&s===t?o(n,e):r(t,s,c|h)}}e.exports=f},function(e,t,n){var r=n(1459),i=n(1460);function o(e,t){return null!=e&&i(e,t,r)}e.exports=o},function(e,t){function n(e,t){return null!=e&&t in Object(e)}e.exports=n},function(e,t,n){var r=n(478),i=n(329),o=n(65),s=n(331),a=n(242),l=n(222);function u(e,t,n){t=r(t,e);for(var u=-1,c=t.length,h=!1;++u<c;){var f=l(t[u]);if(!(h=null!=e&&n(e,f)))break;e=e[f]}return h||++u!=c?h:(c=null==e?0:e.length,!!c&&a(c)&&s(f,c)&&(o(e)||i(e)))}e.exports=u},function(e,t,n){var r=n(413),i=n(1462),o=n(284),s=n(222);function a(e){return o(e)?r(s(e)):i(e)}e.exports=a},function(e,t,n){var r=n(477);function i(e){return function(t){return r(t,e)}}e.exports=i},function(e,t,n){var r=n(1464),i=r(function(e,t,n){return e+(n?"-":"")+t.toLowerCase()});e.exports=i},function(e,t,n){var r=n(1465),i=n(1466),o=n(1469),s="[']",a=RegExp("[']","g");function l(e){return function(t){return r(o(i(t).replace(a,"")),e,"")}}e.exports=l},function(e,t){function n(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}e.exports=n},function(e,t,n){var r=n(1467),i=n(288),o=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,s="\\u0300-\\u036f",a="\\ufe20-\\ufe2f",l="\\u20d0-\\u20ff",u="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",c="["+u+"]",h=RegExp(c,"g");function f(e){return e=i(e),e&&e.replace(o,r).replace(h,"")}e.exports=f},function(e,t,n){var r=n(1468),i={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},o=r(i);e.exports=o},function(e,t){function n(e){return function(t){return null==e?void 0:e[t]}}e.exports=n},function(e,t,n){var r=n(1470),i=n(1471),o=n(288),s=n(1472);function a(e,t,n){return e=o(e),t=n?void 0:t,void 0===t?i(e)?s(e):r(e):e.match(t)||[]}e.exports=a},function(e,t){var n=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;function r(e){return e.match(n)||[]}e.exports=r},function(e,t){var n=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;function r(e){return n.test(e)}e.exports=r},function(e,t){var n="\\ud800-\\udfff",r="\\u0300-\\u036f",i="\\ufe20-\\ufe2f",o="\\u20d0-\\u20ff",s="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",a="\\u2700-\\u27bf",l="a-z\\xdf-\\xf6\\xf8-\\xff",u="\\xac\\xb1\\xd7\\xf7",c="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",h="\\u2000-\\u206f",f=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",p="A-Z\\xc0-\\xd6\\xd8-\\xde",d="\\ufe0e\\ufe0f",m=u+c+"\\u2000-\\u206f"+f,g="[']",y="["+m+"]",v="["+s+"]",b="\\d+",_="[\\u2700-\\u27bf]",w="["+l+"]",k="[^"+n+m+b+a+l+p+"]",E="\\ud83c[\\udffb-\\udfff]",S="(?:"+v+"|"+E+")",x="[^\\ud800-\\udfff]",C="(?:\\ud83c[\\udde6-\\uddff]){2}",A="[\\ud800-\\udbff][\\udc00-\\udfff]",T="["+p+"]",I="\\u200d",j="(?:"+w+"|"+k+")",R="(?:"+T+"|"+k+")",B="(?:['](?:d|ll|m|re|s|t|ve))?",O="(?:['](?:D|LL|M|RE|S|T|VE))?",P=S+"?",N="[\\ufe0e\\ufe0f]?",D="(?:\\u200d(?:"+[x,C,A].join("|")+")"+N+P+")*",M="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",F="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",L=N+P+D,U="(?:"+[_,C,A].join("|")+")"+L,q=RegExp([T+"?"+w+"+"+B+"(?="+[y,T,"$"].join("|")+")",R+"+"+O+"(?="+[y,T+j,"$"].join("|")+")",T+"?"+j+"+"+B,T+"+"+O,F,M,b,U].join("|"),"g");function z(e){return e.match(q)||[]}e.exports=z},function(e,t,n){"use strict";const r=n(2);e.exports=(e=>r((t,n,r)=>{"function"!=typeof n||r||(r=n,n={}),"function"==typeof n&&"function"==typeof r&&(r=n,n={}),e({path:"files/rm",args:t,qs:n},e=>r(e))}))},function(e,t,n){"use strict";const r=n(2),i=function(e,t){const n=e.Entries||[];t(null,n.map(e=>({name:e.Name,type:e.Type,size:e.Size,hash:e.Hash})))};e.exports=(e=>r((t,n,r)=>("function"==typeof n&&(r=n,n={}),"function"==typeof t&&(r=t,n={},t=null),e.andTransform({path:"files/ls",args:t,qs:n},i,r))))},function(e,t,n){"use strict";const r=n(69),i=n(547);e.exports=(e=>(t,n)=>(n=n||{},r.source(i(e)(t,n))))},function(e,t,n){"use strict";const r=n(2),i=n(91);e.exports=(e=>r((t,n,r)=>{"function"==typeof n&&(r=n,n={}),e.andTransform({path:"files/read",args:t,qs:n},i,r)}))},function(e,t,n){"use strict";const r=n(17),i=n(53);e.exports=(e=>(t,n)=>{n=n||{};const o=new r.PassThrough;return e({path:"files/read",args:t,qs:n},(e,t)=>{if(e)return o.destroy(e);i(t,o)}),o})},function(e,t,n){"use strict";const r=n(69),i=n(61);e.exports=(e=>(t,n)=>{n=n||{};const o=i.source();return e({path:"files/read",args:t,qs:n},(e,t)=>{if(e)return o.abort(e);o.resolve(r(t))}),o})},function(e,t,n){"use strict";const r=n(2),i=n(166),o=n(26),s=n(130),a=n(167);e.exports=(e=>{const t=a(e,"files/write");return r((e,n,r,a)=>{"function"!=typeof r||a||(a=r,r={}),"function"==typeof r&&"function"==typeof a&&(a=r,r={});const l=[].concat(n),u=o(a),c={args:e,qs:r,converter:s},h=t({qs:c}),f=i(e=>u(null,e));h.once("error",u),h.pipe(f),l.forEach(e=>h.write(e)),h.end()})})},function(e,t,n){"use strict";const r=n(2),i=n(541);e.exports=(e=>r(function(){const{callback:t,sources:n,opts:r}=i(Array.prototype.slice.call(arguments));e({path:"files/mv",args:n,qs:r},e=>t(e))}))},function(e,t,n){"use strict";e.exports=(e=>()=>({host:e.host,port:e.port,protocol:e.protocol,"api-path":e["api-path"]}))},function(e,t,n){const r=n(32),i=n(4)("dweb-transports:yjs"),o=n(184),s=n(1483);function a(e,t){return new Promise(n=>{setTimeout(()=>{n(t)},e)})}n(1494)(s),n(1496)(s),n(1497)(s),n(1499)(s),n(1500)(s),n(1516)(s);const l=n(77),u=n(111),c=n(94),h=n(146);let f={db:{name:"indexeddb"},connector:{name:"ipfs"}};class p extends u{constructor(e){super(e),this.options=e,this.name="YJS",this.supportURLs=["yjs"],this.supportFunctions=["fetch","add","list","listmonitor","newlisturls","connection","get","set","getall","keys","newdatabase","newtable","monitor"],this.supportFeatures=[],this.status=u.STATUS_LOADED}async p__y(e,t){"string"!=typeof e&&(e=e.href),console.assert(e.startsWith("yjs:/yjs/"));try{if(this.yarrays[e])return this.yarrays[e];{let n=u.mergeoptions(this.options,{connector:{room:e}},t);return this.yarrays[e]=await s(n)}}catch(e){throw console.error("Failed to initialize Y",e.message),e}}async p__yarray(e){return this.p__y(e,{share:{array:"Array"}})}async p_connection(e){return this.p__y(e,{share:{map:"Map"}})}static setup0(e){let t=u.mergeoptions(f,e.yjs);i("YJS options %o",t);let n=new p(t);return c.addtransport(n),n}async p_setup2(e){try{this.status=u.STATUS_STARTING,e&&e(this),this.options.connector.ipfs=c.ipfs().ipfs,this.yarrays={},await this.p_status()}catch(e){console.error(this.name,"failed to start",e),this.status=u.STATUS_FAILED}return e&&e(this),this}async p_status(){return this.status=await this.options.connector.ipfs.isOnline()?u.STATUS_CONNECTED:u.STATUS_FAILED,super.p_status()}async p_rawlist(e){try{let t=await this.p__yarray(e),n=t.share.array.toArray();return n}catch(e){throw e}}listmonitor(e,t,{current:n=!1}={}){let r=this.yarrays["string"==typeof e?e:e.href];console.assert(r,"Should always exist before calling listmonitor - async call p__yarray(url) to create"),n&&r.share.array.toArray.map(t),r.share.array.observe(e=>{"insert"===e.type&&(i("resources inserted %o",e.values),e.values.map(t))})}rawreverse(){throw new l.ToBeImplementedError("Undefined function TransportYJS.rawreverse")}async p_rawadd(e,t){console.assert(e&&t.urls.length&&t.signature&&t.signedby.length,"TransportYJS.p_rawadd args",e,t);let n=t.preflight(Object.assign({},t)),r=await this.p__yarray(e);r.share.array.push([n])}p_newlisturls(e){let t=e._publicurls.map(e=>r.parse(e)).find(e=>"ipfs"===e.protocol&&e.pathname.includes("/ipfs/")||"yjs:"===e.protocol);return t||(t=`yjs:/yjs/${e.keypair.verifyexportmultihashsha256_58()}`),[t,t]}async p_newdatabase(e){e.hasOwnProperty("keypair")&&(e=e.keypair.signingexport());let t=`yjs:/yjs/${encodeURIComponent(e)}`;return{publicurl:t,privateurl:t}}async p_newtable(e,t){if(!e)throw new l.CodingError("p_newtable currently requires a pubkey");let n=await this.p_newdatabase(e);return{privateurl:`${n.privateurl}/${t}`,publicurl:`${n.publicurl}/${t}`}}async p_set(e,t,n){let r=await this.p_connection(e);"string"==typeof t?r.share.map.set(t,o(n)):Object.keys(t).map(e=>r.share.map.set(e,t[e]))}_p_get(e,t){if(Array.isArray(t))return t.reduce(function(t,n){let r=e.share.map.get(n);return t[n]="string"==typeof r?JSON.parse(r):r,t},{});{let n=e.share.map.get(t);return"string"==typeof n?JSON.parse(n):n}}async p_get(e,t){return this._p_get(await this.p_connection(e),t)}async p_delete(e,t){let n=await this.p_connection(e);"string"==typeof t?n.share.map.delete(t):t.map(e=>n.share.map.delete(e))}async p_keys(e){let t=await this.p_connection(e);return t.share.map.keys()}async p_getall(e){let t=await this.p_connection(e),n=t.share.map.keys();return this._p_get(t,n)}async p_rawfetch(e){return{table:"keyvaluetable",_map:await this.p_getall(e)}}async monitor(e,t,{current:n=!1}={}){e="string"==typeof e?e:e.href;let r=this.yarrays[e];if(!r)throw new l.CodingError("Should always exist before calling monitor - async call p__yarray(url) to create");n&&r.share.map.keys().forEach(e=>{let n=r.share.map.get[e];t({type:"set",key:e,value:"string"==typeof n?JSON.parse(n):n})}),r.share.map.observe(n=>{if(["add","update"].includes(n.type)&&(i("YJS monitor: %o %s %s %o",e,n.type,n.name,n.value),"update"!==n.type||n.oldValue!==n.value)){let e={type:{add:"set",update:"set",delete:"delete"}[n.type],value:JSON.parse(n.value),key:n.name};t(e)}})}static async p_test(e={}){console.log("TransportHTTP.test");try{let t=await this.p_setup(e);console.log("HTTP connected");let n=await t.p_info();console.log("TransportHTTP info=",n),n=await t.p_status(),console.assert(n===u.STATUS_CONNECTED),await t.p_test_kvt("NACL%20VERIFY")}catch(e){throw console.log("Exception thrown in TransportHTTP.test:",e.message),e}}}p.Y=s,c._transportclasses.YJS=p,t=e.exports=p},function(e,t,n){"use strict";n(1484)(o),n(1485)(o),n(1486)(o),n(1487)(o),n(1488)(o),n(1489)(o),o.debug=n(1490);var r={};function i(e){var t;t=null===o.sourceDir?null:o.sourceDir||"/bower_components";for(var i="undefined"!=typeof regeneratorRuntime?".js":".es6",s=[],a=0;a<e.length;a++){var l=e[a].split("(")[0],u="y-"+l.toLowerCase();if(null==o[l])if(null==r[l])if("undefined"!=typeof window&&"undefined"!==window.Y){if(null!=t){var c=document.createElement("script");c.src=t+"/"+u+"/"+u+i,document.head.appendChild(c)}let e={};r[l]=e,e.promise=new Promise(function(t){e.resolve=t}),s.push(e.promise)}else console.info("YJS: Please do not depend on automatic requiring of modules anymore! Extend modules as follows `require('y-modulename')(Y)`"),n(1493)(u)(o);else s.push(r[e[a]].promise)}return Promise.all(s)}function o(e){e.hasOwnProperty("sourceDir")&&(o.sourceDir=e.sourceDir),e.types=null!=e.types?e.types:[];var t=[e.db.name,e.connector.name].concat(e.types);for(var n in e.share)t.push(e.share[n]);return new Promise(function(n,r){null==e?r("An options object is expected! "):null==e.connector?r("You must specify a connector! (missing connector property)"):null==e.connector.name?r("You must specify connector name! (missing connector.name property)"):null==e.db?r("You must specify a database! (missing db property)"):null==e.connector.name?r("You must specify db name! (missing db.name property)"):(e=o.utils.copyObject(e),e.connector=o.utils.copyObject(e.connector),e.db=o.utils.copyObject(e.db),e.share=o.utils.copyObject(e.share),setTimeout(function(){o.requestModules(t).then(function(){var t=new s(e);t.db.whenUserIdSet(function(){t.init(function(){n(t)})})}).catch(r)},0))})}e.exports=o,o.requiringModules=r,o.extend=function(e,t){if(2===arguments.length&&"string"==typeof e)t instanceof o.utils.CustomTypeDefinition?o[e]=t.parseArguments:o[e]=t,null!=r[e]&&(r[e].resolve(),delete r[e]);else for(var n=0;n<arguments.length;n++){var i=arguments[n];if("function"!=typeof i)throw new Error("Expected function!");i(o)}},o.requestModules=i;class s{constructor(e,t){this.options=e,this.db=new o[e.db.name](this,e.db),this.connector=new o[e.connector.name](this,e.connector),this.connected=!0}init(e){var t=this.options,n={};this.share=n,this.db.requestTransaction(function*r(){for(var i in t.share){var s=t.share[i].split("("),a=s.splice(0,1),l=o[a],u=l.typeDefinition,c=["_",u.struct+"_"+a+"_"+i+"_"+s],h=[];if(1===s.length){try{h=JSON.parse("["+s[0].split(")")[0]+"]")}catch(e){throw new Error("Was not able to parse type definition! (share."+i+")")}if(null==l.typeDefinition.parseArguments)throw new Error(a+" does not expect arguments!");h=u.parseArguments(h[0])[1]}n[i]=yield*this.store.initType.call(this,c,h)}this.store.whenTransactionsFinished().then(e)})}isConnected(){return this.connector.isSynced}disconnect(){return this.connected?(this.connected=!1,this.connector.disconnect()):Promise.resolve()}reconnect(){return this.connected?Promise.resolve():(this.connected=!0,this.connector.reconnect())}destroy(){var e=this;return this.close().then(function(){return null!=e.db.deleteDB?e.db.deleteDB():Promise.resolve()})}close(){var e=this;return this.share=null,null!=this.connector.destroy?this.connector.destroy():this.connector.disconnect(),this.db.whenTransactionsFinished(function(){return this.db.destroyTypes(),this.db.requestTransaction(function*(){yield*e.db.destroy()}),this.db.whenTransactionsFinished()})}}},function(e,t){function n(e){return"read"===e||"write"===e}function r(e){return"write"===e}e.exports=function(e){class t{constructor(t,n){if(this.y=t,null==n&&(n={}),null==n.role||"master"===n.role)this.role="master";else{if("slave"!==n.role)throw new Error("Role must be either 'master' or 'slave'!");this.role="slave"}this.log=e.debug("y:connector"),this.logMessage=e.debug("y:connector-message"),this.y.db.forwardAppliedOperations=n.forwardAppliedOperations||!1,this.role=n.role,this.connections={},this.isSynced=!1,this.userEventListeners=[],this.whenSyncedListeners=[],this.currentSyncTarget=null,this.syncingClients=[],this.forwardToSyncingClients=!1!==n.forwardToSyncingClients,this.debug=!0===n.debug,this.syncStep2=Promise.resolve(),this.broadcastOpBuffer=[],this.protocolVersion=11,this.authInfo=n.auth||null,this.checkAuth=n.checkAuth||function(){return Promise.resolve("write")},!0===n.generateUserId&&this.setUserId(e.utils.generateGuid())}resetAuth(e){this.authInfo!==e&&(this.authInfo=e,this.broadcast({type:"auth",auth:this.authInfo}))}reconnect(){return this.log("reconnecting.."),this.y.db.startGarbageCollector()}disconnect(){return this.log("discronnecting.."),this.connections={},this.isSynced=!1,this.currentSyncTarget=null,this.syncingClients=[],this.whenSyncedListeners=[],this.y.db.stopGarbageCollector(),this.y.db.whenTransactionsFinished()}repair(){for(var e in this.log("Repairing the state of Yjs. This can happen if messages get lost, and Yjs detects that something is wrong. If this happens often, please report an issue here: https://github.com/y-js/yjs/issues"),this.connections)this.connections[e].isSynced=!1;this.isSynced=!1,this.currentSyncTarget=null,this.findNextSyncTarget()}setUserId(e){return null==this.userId?(this.log('Set userId to "%s"',e),this.userId=e,this.y.db.setUserId(e)):null}onUserEvent(e){this.userEventListeners.push(e)}removeUserEventListener(e){this.userEventListeners=this.userEventListeners.filter(e=>{})}userLeft(e){if(null!=this.connections[e])for(var t of(this.log("User left: %s",e),delete this.connections[e],e===this.currentSyncTarget&&(this.currentSyncTarget=null,this.findNextSyncTarget()),this.syncingClients=this.syncingClients.filter(function(t){return t!==e}),this.userEventListeners))t({action:"userLeft",user:e})}userJoined(e,t){if(null==t)throw new Error("You must specify the role of the joined user!");if(null!=this.connections[e])throw new Error("This user already joined!");for(var n of(this.log("User joined: %s",e),this.connections[e]={isSynced:!1,role:t},this.userEventListeners))n({action:"userJoined",user:e,role:t});null==this.currentSyncTarget&&this.findNextSyncTarget()}whenSynced(e){this.isSynced?e():this.whenSyncedListeners.push(e)}findNextSyncTarget(){if(null==this.currentSyncTarget){var e=null;for(var t in this.connections)if(!this.connections[t].isSynced){e=t;break}var n=this;null!=e?(this.currentSyncTarget=e,this.y.db.requestTransaction(function*(){var t=yield*this.getStateSet(),r=yield*this.getDeleteSet(),i={type:"sync step 1",stateSet:t,deleteSet:r,protocolVersion:n.protocolVersion,auth:n.authInfo};n.send(e,i)})):n.isSynced||this.y.db.requestTransaction(function*(){if(!n.isSynced){for(var e of(n.isSynced=!0,yield*this.garbageCollectAfterSync(),n.whenSyncedListeners))e();n.whenSyncedListeners=[]}})}}send(e,t){this.log("Send '%s' to %s",t.type,e),this.logMessage("Message: %j",t)}broadcast(e){this.log("Broadcast '%s'",e.type),this.logMessage("Message: %j",e)}broadcastOps(t){t=t.map(function(t){return e.Struct[t.struct].encode(t)});var n=this;function r(){n.broadcastOpBuffer.length>0&&(n.broadcast({type:"update",ops:n.broadcastOpBuffer}),n.broadcastOpBuffer=[])}0===this.broadcastOpBuffer.length?(this.broadcastOpBuffer=t,this.y.db.transactionInProgress?this.y.db.whenTransactionsFinished().then(r):setTimeout(r,0)):this.broadcastOpBuffer=this.broadcastOpBuffer.concat(t)}receiveMessage(e,t){if(e===this.userId)return Promise.resolve();if(this.log("Receive '%s' from %s",t.type,e),this.logMessage("Message: %j",t),null!=t.protocolVersion&&t.protocolVersion!==this.protocolVersion)return this.log(`You tried to sync with a yjs instance that has a different protocol version\n (You: ${this.protocolVersion}, Client: ${t.protocolVersion}).\n The sync was stopped. You need to upgrade your dependencies (especially Yjs & the Connector)!\n `),this.send(e,{type:"sync stop",protocolVersion:this.protocolVersion}),Promise.reject("Incompatible protocol version");if(null!=t.auth&&null!=this.connections[e]){var i=this.checkAuth(t.auth,this.y,e);this.connections[e].auth=i,i.then(t=>{for(var n of this.userEventListeners)n({action:"userAuthenticated",user:e,auth:t})})}else null!=this.connections[e]&&null==this.connections[e].auth&&(this.connections[e].auth=this.checkAuth(null,this.y,e));return null!=this.connections[e]&&null!=this.connections[e].auth?this.connections[e].auth.then(i=>{if("sync step 1"===t.type&&n(i)){let n=this,o=t;this.y.db.requestTransaction(function*(){var t=yield*this.getStateSet();r(i)&&(yield*this.applyDeleteSet(o.deleteSet));var s=yield*this.getDeleteSet(),a={type:"sync step 2",stateSet:t,deleteSet:s,protocolVersion:this.protocolVersion,auth:this.authInfo};a.os=yield*this.getOperations(o.stateSet),n.send(e,a),this.forwardToSyncingClients?(n.syncingClients.push(e),setTimeout(function(){n.syncingClients=n.syncingClients.filter(function(t){return t!==e}),n.send(e,{type:"sync done"})},5e3)):n.send(e,{type:"sync done"})})}else if("sync step 2"===t.type&&r(i)){var o=this.y.db,s={};s.promise=new Promise(function(e){s.resolve=e}),this.syncStep2=s.promise;let e=t;o.requestTransaction(function*(){yield*this.applyDeleteSet(e.deleteSet),null!=e.osUntransformed?yield*this.applyOperationsUntransformed(e.osUntransformed,e.stateSet):this.store.apply(e.os),s.resolve()})}else if("sync done"===t.type){var a=this;this.syncStep2.then(function(){a._setSyncedWith(e)})}else if("update"===t.type&&r(i)){if(this.forwardToSyncingClients)for(var l of this.syncingClients)this.send(l,t);if(this.y.db.forwardAppliedOperations){var u=t.ops.filter(function(e){return"Delete"===e.struct});u.length>0&&this.broadcastOps(u)}this.y.db.apply(t.ops)}}):Promise.reject("Unable to deliver message")}_setSyncedWith(e){var t=this.connections[e];null!=t&&(t.isSynced=!0),e===this.currentSyncTarget&&(this.currentSyncTarget=null,this.findNextSyncTarget())}parseMessageFromXml(e){function t(e){for(var r of e.children)return"true"===r.getAttribute("isArray")?t(r):n(r)}function n(e){var r={};for(var i in e.attrs){var o=e.attrs[i],s=parseInt(o,10);isNaN(s)||""+s!==o?r[i]=o:r[i]=s}for(var a in e.children){var l=a.name;"true"===a.getAttribute("isArray")?r[l]=t(a):r[l]=n(a)}return r}n(e)}encodeMessageToXml(e,t){function n(e,t){for(var i in t){var o=t[i];null==i||(o.constructor===Object?n(e.c(i),o):o.constructor===Array?r(e.c(i),o):e.setAttribute(i,o))}}function r(e,t){for(var i of(e.setAttribute("isArray","true"),t))i.constructor===Object?n(e.c("array-element"),i):r(e.c("array-element"),i)}if(t.constructor===Object)n(e.c("y",{xmlns:"http://y.ninja/connector-stanza"}),t);else{if(t.constructor!==Array)throw new Error("I can't encode this json!");r(e.c("y",{xmlns:"http://y.ninja/connector-stanza"}),t)}}}e.AbstractConnector=t}},function(e,t,n){"use strict";e.exports=function(e){class t{constructor(e,t){this.y=e,this.dbOpts=t;var n=this,r;function i(){return n.whenTransactionsFinished().then(function(){return n.gc1.length>0||n.gc2.length>0?(n.y.connector.isSynced||console.warn("gc should be empty when not synced!"),new Promise(e=>{n.requestTransaction(function*(){if(null!=n.y.connector&&n.y.connector.isSynced){for(var t=0;t<n.gc2.length;t++){var r=n.gc2[t];yield*this.garbageCollectOperation(r)}n.gc2=n.gc1,n.gc1=[]}n.gcTimeout>0&&(n.gcInterval=setTimeout(i,n.gcTimeout)),e()})})):(n.gcTimeout>0&&(n.gcInterval=setTimeout(i,n.gcTimeout)),Promise.resolve())})}this.userId=null,this.userIdPromise=new Promise(function(e){r=e}),this.userIdPromise.resolve=r,this.forwardAppliedOperations=!1,this.listenersById={},this.listenersByIdExecuteNow=[],this.listenersByIdRequestPending=!1,this.initializedTypes={},this.waitingTransactions=[],this.transactionInProgress=!1,this.transactionIsFlushed=!1,"undefined"!=typeof YConcurrency_TestingMode&&(this.executeOrder=[]),this.gc1=[],this.gc2=[],this.garbageCollect=i,this.startGarbageCollector(),this.repairCheckInterval=t.repairCheckInterval?t.repairCheckInterval:6e3,this.opsReceivedTimestamp=new Date,this.startRepairCheck()}startGarbageCollector(){this.gc=null==this.dbOpts.gc||this.dbOpts.gc,this.gc?this.gcTimeout=this.dbOpts.gcTimeout?this.dbOpts.gcTimeout:5e4:this.gcTimeout=-1,this.gcTimeout>0&&this.garbageCollect()}startRepairCheck(){var e=this;this.repairCheckInterval>0&&(this.repairCheckIntervalHandler=setInterval(function t(){new Date-e.opsReceivedTimestamp>e.repairCheckInterval&&Object.keys(e.listenersById).length>0&&(e.listenersById={},e.opsReceivedTimestamp=new Date,e.y.connector.repair())},this.repairCheckInterval))}stopRepairCheck(){clearInterval(this.repairCheckIntervalHandler)}queueGarbageCollector(e){this.y.connector.isSynced&&this.gc&&this.gc1.push(e)}emptyGarbageCollector(){return new Promise(e=>{var t=()=>{this.gc1.length>0||this.gc2.length>0?this.garbageCollect().then(t):e()};setTimeout(t,0)})}addToDebug(){if("undefined"!=typeof YConcurrency_TestingMode){var e=Array.prototype.map.call(arguments,function(e){return"string"==typeof e?e:JSON.stringify(e)}).join("").replace(/"/g,"'").replace(/,/g,", ").replace(/:/g,": ");this.executeOrder.push(e)}}getDebugData(){console.log(this.executeOrder.join("\n"))}stopGarbageCollector(){var e=this;return this.gc=!1,this.gcTimeout=-1,new Promise(function(t){e.requestTransaction(function*(){var n=e.gc1.concat(e.gc2);e.gc1=[],e.gc2=[];for(var r=0;r<n.length;r++){var i=yield*this.getOperation(n[r]);null!=i&&(delete i.gc,yield*this.setOperation(i))}t()})})}*addToGarbageCollector(e,t){if(null==e.gc&&!0===e.deleted&&this.store.gc&&this.store.y.connector.isSynced){var n=!1;if(null!=t&&!0===t.deleted?n=!0:null!=e.content&&e.content.length>1&&(e=yield*this.getInsertionCleanStart([e.id[0],e.id[1]+1]),n=!0),n)return e.gc=!0,yield*this.setOperation(e),this.store.queueGarbageCollector(e.id),!0}return!1}removeFromGarbageCollector(t){function n(n){return!e.utils.compareIds(n,t.id)}this.gc1=this.gc1.filter(n),this.gc2=this.gc2.filter(n),delete t.gc}destroyTypes(){for(var e in this.initializedTypes){var t=this.initializedTypes[e];null!=t._destroy?t._destroy():console.error("The type you included does not provide destroy functionality, it will remain in memory (updating your packages will help).")}}*destroy(){clearInterval(this.gcInterval),this.gcInterval=null,this.stopRepairCheck()}setUserId(e){if(!this.userIdPromise.inProgress){this.userIdPromise.inProgress=!0;var t=this;t.requestTransaction(function*(){t.userId=e;var n=yield*this.getState(e);t.opClock=n.clock,t.userIdPromise.resolve(e)})}return this.userIdPromise}whenUserIdSet(e){this.userIdPromise.then(e)}getNextOpId(e){if(null==e)throw new Error("getNextOpId expects the number of created ids to create!");if(null==this.userId)throw new Error("OperationStore not yet initialized!");var t=[this.userId,this.opClock];return this.opClock+=e,t}apply(t){this.opsReceivedTimestamp=new Date;for(var n=0;n<t.length;n++){var r=t[n];if(null==r.id||r.id[0]!==this.y.connector.userId){var i=e.Struct[r.struct].requiredOps(r);null!=r.requires&&(i=i.concat(r.requires)),this.whenOperationsExist(i,r)}}}whenOperationsExist(e,t){if(e.length>0){let n={op:t,missing:e.length};for(let t=0;t<e.length;t++){let r=e[t],i=JSON.stringify(r),o=this.listenersById[i];null==o&&(o=[],this.listenersById[i]=o),o.push(n)}}else this.listenersByIdExecuteNow.push({op:t});if(!this.listenersByIdRequestPending){this.listenersByIdRequestPending=!0;var n=this;this.requestTransaction(function*(){var e=n.listenersByIdExecuteNow;n.listenersByIdExecuteNow=[];var t=n.listenersById;n.listenersById={},n.listenersByIdRequestPending=!1;for(let t=0;t<e.length;t++){let r=e[t].op;yield*n.tryExecute.call(this,r)}for(var r in t){var i=t[r],o=JSON.parse(r),s;if(s="string"==typeof o[1]?yield*this.getOperation(o):yield*this.getInsertion(o),null==s)n.listenersById[r]=i;else for(let e=0;e<i.length;e++){let t=i[e],r=t.op;0==--t.missing&&(yield*n.tryExecute.call(this,r))}}})}}*tryExecute(t){if(this.store.addToDebug("yield* this.store.tryExecute.call(this, ",JSON.stringify(t),")"),"Delete"===t.struct)yield*e.Struct.Delete.execute.call(this,t);else{for(var n=yield*this.getInsertion(t.id);null!=n&&null!=n.content&&n.id[1]+n.content.length<t.id[1]+t.content.length;){var r=n.content.length-(t.id[1]-n.id[1]);t.content.splice(0,r),t.id=[t.id[0],t.id[1]+r],t.left=e.utils.getLastId(n),t.origin=t.left,n=yield*this.getOperation(t.id)}if(null==n){var i=t.id,o=yield*this.isGarbageCollected(i);o||(yield*e.Struct[t.struct].execute.call(this,t),yield*this.addOperation(t),yield*this.store.operationAdded(this,t),t=yield*this.getOperation(i),yield*this.tryCombineWithLeft(t))}}}*operationAdded(t,n){if("Delete"===n.struct){var r=this.initializedTypes[JSON.stringify(n.targetParent)];null!=r&&(yield*r._changed(t,n))}else{yield*t.updateState(n.id[0]);var i=null!=n.content?n.content.length:1;for(let e=0;e<i;e++){var o=JSON.stringify([n.id[0],n.id[1]+e]),s=this.listenersById[o];if(delete this.listenersById[o],null!=s)for(var a in s){var l=s[a];0==--l.missing&&this.whenOperationsExist([],l.op)}}var u=this.initializedTypes[JSON.stringify(n.parent)];if(null!=n.parent){var c=yield*t.isDeleted(n.parent);if(c)return void(yield*t.deleteList(n.id))}if(null!=u){let r=e.utils.copyOperation(n);yield*u._changed(t,r)}if(!n.deleted){var h=null!=n.content?n.content.length:1,f=n.id;for(let e=0;e<h;e++){var p=[f[0],f[1]+e],d=yield*t.isDeleted(p);if(d){var m={struct:"Delete",target:p};yield*this.tryExecute.call(t,m)}}}}}whenTransactionsFinished(){if(this.transactionInProgress){if(null==this.transactionsFinished){var e,t=new Promise(function(t){e=t});this.transactionsFinished={resolve:e,promise:t}}return this.transactionsFinished.promise}return Promise.resolve()}getNextRequest(){return 0===this.waitingTransactions.length?this.transactionIsFlushed?(this.transactionInProgress=!1,this.transactionIsFlushed=!1,null!=this.transactionsFinished&&(this.transactionsFinished.resolve(),this.transactionsFinished=null),null):(this.transactionIsFlushed=!0,function*(){yield*this.flush()}):(this.transactionIsFlushed=!1,this.waitingTransactions.shift())}requestTransaction(e,t){this.waitingTransactions.push(e),this.transactionInProgress||(this.transactionInProgress=!0,setTimeout(()=>{this.transact(this.getNextRequest())},0))}getType(e){return this.initializedTypes[JSON.stringify(e)]}*initType(t,n){var r=JSON.stringify(t),i=this.store.initializedTypes[r];if(null==i){var o=yield*this.getOperation(t);null!=o&&(i=yield*e[o.type].typeDefinition.initType.call(this,this.store,o,n),this.store.initializedTypes[r]=i)}return i}createType(t,n){var r=t[0].struct;n=n||this.getNextOpId(1);var i=e.Struct[r].create(n);i.type=t[0].name,this.requestTransaction(function*(){"_"===i.id[0]?yield*this.setOperation(i):yield*this.applyCreatedOperations([i])});var o=e[i.type].typeDefinition.createType(this,i,t[1]);return this.initializedTypes[JSON.stringify(i.id)]=o,o}}e.AbstractDatabase=t}},function(e,t,n){"use strict";e.exports=function(e){class t{*applyCreatedOperations(t){for(var n=[],r=0;r<t.length;r++){var i=t[r];yield*this.store.tryExecute.call(this,i),null!=i.id&&"string"==typeof i.id[1]||n.push(e.Struct[i.struct].encode(i))}n.length>0&&this.store.y.connector.broadcastOps(n)}*deleteList(e){for(;null!=e;){if(e=yield*this.getOperation(e),!e.gc){e.gc=!0,e.deleted=!0,yield*this.setOperation(e);var t=null!=e.content?e.content.length:1;yield*this.markDeleted(e.id,t),null!=e.opContent&&(yield*this.deleteOperation(e.opContent)),this.store.queueGarbageCollector(e.id)}e=e.right}}*deleteOperation(e,t,n){for(null==t&&(t=1),yield*this.markDeleted(e,t);t>0;){var r=!1,i=yield*this.os.findWithUpperBound([e[0],e[1]+t-1]),o=null!=i&&null!=i.content?i.content.length:1;if(null==i||i.id[0]!==e[0]||i.id[1]+o<=e[1]?(i=null,t=0):(i.deleted||(i.id[1]<e[1]&&(i=yield*this.getInsertionCleanStart(e),o=i.content.length),i.id[1]+o>e[1]+t&&(i=yield*this.getInsertionCleanEnd([e[0],e[1]+t-1]),o=i.content.length)),t=i.id[1]-e[1]),null!=i){if(!i.deleted){if(r=!0,i.deleted=!0,null!=i.start&&(yield*this.deleteList(i.start)),null!=i.map)for(var s in i.map)yield*this.deleteList(i.map[s]);if(null!=i.opContent&&(yield*this.deleteOperation(i.opContent)),null!=i.requires)for(var a=0;a<i.requires.length;a++)yield*this.deleteOperation(i.requires[a])}var l,u;l=null!=i.left?yield*this.getInsertion(i.left):null,yield*this.setOperation(i),u=null!=i.right?yield*this.getOperation(i.right):null,r&&!n&&(yield*this.store.operationAdded(this,{struct:"Delete",target:i.id,length:o,targetParent:i.parent})),yield*this.store.addToGarbageCollector.call(this,i,l),null!=u&&(yield*this.store.addToGarbageCollector.call(this,u,i))}}}*markGarbageCollected(t,n){this.store.addToDebug("yield* this.markGarbageCollected(",t,", ",n,")");var r=yield*this.markDeleted(t,n);if(r.id[1]<t[1]&&!r.gc){var i=r.len-(t[1]-r.id[1]);r.len-=i,yield*this.ds.put(r),r={id:t,len:i,gc:!1},yield*this.ds.put(r)}var o=yield*this.ds.findPrev(t),s=yield*this.ds.findNext(t);t[1]+n<r.id[1]+r.len&&!r.gc&&(yield*this.ds.put({id:[t[0],t[1]+n],len:r.len-n,gc:!1}),r.len=n),r.gc=!0,null!=o&&o.gc&&e.utils.compareIds([o.id[0],o.id[1]+o.len],r.id)&&(o.len+=r.len,yield*this.ds.delete(r.id),r=o),null!=s&&s.gc&&e.utils.compareIds([r.id[0],r.id[1]+r.len],s.id)&&(r.len+=s.len,yield*this.ds.delete(s.id)),yield*this.ds.put(r),yield*this.updateState(r.id[0])}*markDeleted(e,t){null==t&&(t=1);var n=yield*this.ds.findWithUpperBound(e);if(null!=n&&n.id[0]===e[0])if(n.id[1]<=e[1]&&e[1]<=n.id[1]+n.len){var r=e[1]+t-(n.id[1]+n.len);if(!(r>0))return n;if(n.gc){if(r=n.id[1]+n.len-e[1],!(r<t))throw new Error("Cannot happen! (it dit though.. :()");n={id:[e[0],e[1]+r],len:t-r,gc:!1},yield*this.ds.put(n)}else n.len+=r}else n={id:e,len:t,gc:!1},yield*this.ds.put(n);else n={id:e,len:t,gc:!1},yield*this.ds.put(n);var i=yield*this.ds.findNext(n.id);if(null!=i&&n.id[0]===i.id[0]&&n.id[1]+n.len>=i.id[1])for(r=n.id[1]+n.len-i.id[1];r>=0;){if(i.gc){n.len-=r,r>=i.len&&(r-=i.len,r>0&&(yield*this.ds.put(n),yield*this.markDeleted([i.id[0],i.id[1]+i.len],r)));break}if(!(r>i.len)){n.len+=i.len-r,yield*this.ds.delete(i.id);break}var o=yield*this.ds.findNext(i.id);if(yield*this.ds.delete(i.id),null==o||n.id[0]!==o.id[0])break;i=o,r=n.id[1]+n.len-i.id[1]}return yield*this.ds.put(n),n}*garbageCollectAfterSync(){(this.store.gc1.length>0||this.store.gc2.length>0)&&console.warn("gc should be empty after sync"),this.store.gc&&(yield*this.os.iterate(this,null,null,function*(e){if(e.gc&&(delete e.gc,yield*this.setOperation(e)),null!=e.parent){var t=yield*this.isDeleted(e.parent);if(t){if(e.gc=!0,!e.deleted&&(yield*this.markDeleted(e.id,null!=e.content?e.content.length:1),e.deleted=!0,null!=e.opContent&&(yield*this.deleteOperation(e.opContent)),null!=e.requires))for(var n=0;n<e.requires.length;n++)yield*this.deleteOperation(e.requires[n]);return yield*this.setOperation(e),void this.store.gc1.push(e.id)}}if(e.deleted){var r=null;null!=e.left&&(r=yield*this.getInsertion(e.left)),yield*this.store.addToGarbageCollector.call(this,e,r)}}))}*garbageCollectOperation(t){this.store.addToDebug("yield* this.garbageCollectOperation(",t,")");var n=yield*this.getOperation(t);if(yield*this.markGarbageCollected(t,null!=n&&null!=n.content?n.content.length:1),null!=n){var r=[],i;null!=n.opContent&&r.push(n.opContent),null!=n.requires&&(r=r.concat(n.requires));for(var o=0;o<r.length;o++){var s=yield*this.getOperation(r[o]);null!=s?(s.deleted||(yield*this.deleteOperation(s.id),s=yield*this.getOperation(s.id)),s.gc=!0,yield*this.setOperation(s),this.store.queueGarbageCollector(s.id)):yield*this.markGarbageCollected(r[o],1)}if(null!=n.left){var a=yield*this.getInsertion(n.left);a.right=n.right,yield*this.setOperation(a)}if(null!=n.right){var l=yield*this.getOperation(n.right);if(l.left=n.left,yield*this.setOperation(l),null!=n.originOf&&n.originOf.length>0){for(var u=n.left,c=null;null!=u&&(c=yield*this.getInsertion(u),!c.deleted);)u=c.left;for(var h in n.originOf){var f=yield*this.getOperation(n.originOf[h]);null!=f&&(f.origin=u,yield*this.setOperation(f))}null!=u&&(null==c.originOf?c.originOf=n.originOf:c.originOf=n.originOf.concat(c.originOf),yield*this.setOperation(c))}}if(null!=n.origin){var p=yield*this.getInsertion(n.origin);p.originOf=p.originOf.filter(function(n){return!e.utils.compareIds(t,n)}),yield*this.setOperation(p)}if(null!=n.parent&&(i=yield*this.getOperation(n.parent)),null!=i){var d=!1;null!=n.parentSub?e.utils.compareIds(i.map[n.parentSub],n.id)&&(d=!0,null!=n.right?i.map[n.parentSub]=n.right:delete i.map[n.parentSub]):(e.utils.compareIds(i.start,n.id)&&(d=!0,i.start=n.right),e.utils.matchesId(n,i.end)&&(d=!0,i.end=n.left)),d&&(yield*this.setOperation(i))}yield*this.removeOperation(n.id)}}*checkDeleteStoreForState(e){var t=yield*this.ds.findWithUpperBound([e.user,e.clock]);null!=t&&t.id[0]===e.user&&t.gc&&(e.clock=Math.max(e.clock,t.id[1]+t.len))}*updateState(e){var t=yield*this.getState(e);yield*this.checkDeleteStoreForState(t);for(var n=yield*this.getInsertion([e,t.clock]),r=null!=n&&null!=n.content?n.content.length:1;null!=n&&e===n.id[0]&&n.id[1]<=t.clock&&n.id[1]+r>t.clock;)t.clock+=r,yield*this.checkDeleteStoreForState(t),n=yield*this.os.findNext(n.id),r=null!=n&&null!=n.content?n.content.length:1;yield*this.setState(t)}*applyDeleteSet(e){var t=[];for(var n in e){var r=e[n],i=0,o=r[i];for(yield*this.ds.iterate(this,[n,0],[n,Number.MAX_VALUE],function*(e){for(;null!=o;){var s=0;if(e.id[1]+e.len<=o[0])break;o[0]<e.id[1]?(s=Math.min(e.id[1]-o[0],o[1]),t.push([n,o[0],s,o[2]])):(s=e.id[1]+e.len-o[0],o[2]&&!e.gc&&t.push([n,o[0],Math.min(s,o[1]),o[2]])),o[1]<=s?o=r[++i]:(o[0]=o[0]+s,o[1]=o[1]-s)}});i<r.length;i++)o=r[i],t.push([n,o[0],o[1],o[2]])}for(var s=0;s<t.length;s++){var a=t[s];if(yield*this.deleteOperation([a[0],a[1]],a[2]),a[3]){yield*this.markGarbageCollected([a[0],a[1]],a[2]);for(var l=a[1]+a[2];l>=a[1];){var u=yield*this.os.findWithUpperBound([a[0],l-1]);if(null==u)break;var c=null!=u.content?u.content.length:1;if(u.id[0]!==a[0]||u.id[1]+c<=a[1])break;u.id[1]+c>a[1]+a[2]&&(u=yield*this.getInsertionCleanEnd([a[0],a[1]+a[2]-1])),u.id[1]<a[1]&&(u=yield*this.getInsertionCleanStart([a[0],a[1]])),l=u.id[1],yield*this.garbageCollectOperation(u.id)}}if(this.store.forwardAppliedOperations){var h=[];h.push({struct:"Delete",target:[a[0],a[1]],length:a[2]}),this.store.y.connector.broadcastOps(h)}}}*isGarbageCollected(e){var t=yield*this.ds.findWithUpperBound(e);return null!=t&&t.id[0]===e[0]&&e[1]<t.id[1]+t.len&&t.gc}*getDeleteSet(){var e={};return yield*this.ds.iterate(this,null,null,function*(t){var n=t.id[0],r=t.id[1],i=t.len,o=t.gc,s=e[n];void 0===s&&(s=[],e[n]=s),s.push([r,i,o])}),e}*isDeleted(e){var t=yield*this.ds.findWithUpperBound(e);return null!=t&&t.id[0]===e[0]&&e[1]<t.id[1]+t.len}*setOperation(e){return yield*this.os.put(e),e}*addOperation(e){yield*this.os.put(e),this.store.forwardAppliedOperations&&"string"!=typeof e.id[1]&&this.store.y.connector.broadcastOps([e])}*tryCombineWithLeft(t){if(null!=t&&null!=t.left&&null!=t.content&&t.left[0]===t.id[0]&&e.utils.compareIds(t.left,t.origin)){var n=yield*this.getInsertion(t.left);null==n.content||n.id[1]+n.content.length!==t.id[1]||1!==n.originOf.length||n.gc||n.deleted||t.gc||t.deleted||(null!=t.originOf?n.originOf=t.originOf:delete n.originOf,n.content=n.content.concat(t.content),n.right=t.right,yield*this.os.delete(t.id),yield*this.setOperation(n))}}*getInsertion(e){var t=yield*this.os.findWithUpperBound(e);if(null==t)return null;var n=null!=t.content?t.content.length:1;return e[0]===t.id[0]&&e[1]<t.id[1]+n?t:null}*getInsertionCleanStartEnd(e){return yield*this.getInsertionCleanStart(e),yield*this.getInsertionCleanEnd(e)}*getInsertionCleanStart(t){var n=yield*this.getInsertion(t);if(null!=n){if(n.id[1]===t[1])return n;var r=e.utils.copyObject(n);n.content=r.content.splice(t[1]-n.id[1]),n.id=t;var i=e.utils.getLastId(r);return n.origin=i,r.originOf=[n.id],r.right=n.id,n.left=i,yield*this.setOperation(r),yield*this.setOperation(n),r.gc&&this.store.queueGarbageCollector(n.id),n}return null}*getInsertionCleanEnd(t){var n=yield*this.getInsertion(t);if(null!=n){if(null==n.content||n.id[1]+n.content.length-1===t[1])return n;var r=e.utils.copyObject(n);r.content=n.content.splice(t[1]-n.id[1]+1),r.id=[t[0],t[1]+1];var i=e.utils.getLastId(n);return r.origin=i,n.originOf=[r.id],n.right=r.id,r.left=i,yield*this.setOperation(r),yield*this.setOperation(n),n.gc&&this.store.queueGarbageCollector(r.id),n}return null}*getOperation(t){var n=yield*this.os.find(t);if("_"!==t[0]||null!=n)return n;var r=t[1].split("_");if(r.length>1){var i=r[0],o=e.Struct[i].create(t);return o.type=r[1],yield*this.setOperation(o),o}return console.error("Unexpected case. How can this happen?"),null}*removeOperation(e){yield*this.os.delete(e)}*setState(e){var t={id:[e.user],clock:e.clock};yield*this.ss.put(t)}*getState(e){var t=yield*this.ss.find([e]),n=null==t?null:t.clock;return null==n&&(n=0),{user:e,clock:n}}*getStateVector(){var e=[];return yield*this.ss.iterate(this,null,null,function*(t){e.push({user:t.id[0],clock:t.clock})}),e}*getStateSet(){var e={};return yield*this.ss.iterate(this,null,null,function*(t){e[t.id[0]]=t.clock}),e}*getOperations(t){null==t&&(t={});var n=[],r=yield*this.getStateVector();for(var i of r){var o=i.user;if("_"!==o){var s=t[o]||0;if(s>0){var a=yield*this.getInsertion([o,s]);null!=a&&(s=a.id[1],t[o]=s)}yield*this.os.iterate(this,[o,s],[o,Number.MAX_VALUE],function*(r){if(r=e.Struct[r.struct].encode(r),"Insert"!==r.struct)n.push(r);else if(null==r.right||r.right[1]<(t[r.right[0]]||0))for(var i=r,o=[r],s=r.right;;){if(null==i.left){r.left=null,n.push(r),e.utils.compareIds(i.id,r.id)||(i=e.Struct[r.struct].encode(i),i.right=o[o.length-1].id,n.push(i));break}for(i=yield*this.getInsertion(i.left);o.length>0&&e.utils.matchesId(i,o[o.length-1].origin);)o.pop();if(i.id[1]<(t[i.id[0]]||0)){r.left=e.utils.getLastId(i),n.push(r);break}if(e.utils.matchesId(i,r.origin))r.left=r.origin,n.push(r),r=e.Struct[r.struct].encode(i),r.right=s,o.length>0&&console.log("This should not happen .. :( please report this"),o=[r];else{var a=e.Struct[r.struct].encode(i);a.right=o[o.length-1].id,a.left=a.origin,n.push(a),o.push(i)}}})}}return n.reverse()}*getOperationsUntransformed(){var e=[];return yield*this.os.iterate(this,null,null,function*(t){"_"!==t.id[0]&&e.push(t)}),{untransformed:e}}*applyOperationsUntransformed(t,n){for(var r=t.untransformed,i=0;i<r.length;i++){var o=r[i];if(null!=o.parent&&"_"===o.parent[0]&&"Insert"===o.struct)if(null!=o.parentSub&&null==o.left){let e=yield*this.getOperation(o.parent);e.map[o.parentSub]=o.id,yield*this.setOperation(e)}else if(null==o.right||null==o.left){let t=yield*this.getOperation(o.parent);null==o.right&&(t.end=e.utils.getLastId(o)),null==o.left&&(t.start=o.id),yield*this.setOperation(t)}yield*this.os.put(o)}for(var s in n)yield*this.ss.put({id:[s],clock:n[s]})}*flush(){yield*this.os.flush(),yield*this.ss.flush(),yield*this.ds.flush()}}e.Transaction=t}},function(e,t,n){"use strict";e.exports=function(e){var t={Delete:{encode:function(e){return{target:e.target,length:e.length||0,struct:"Delete"}},requiredOps:function(e){return[]},execute:function*(e){return yield*this.deleteOperation(e.target,e.length||1)}},Insert:{encode:function(e){var t={id:e.id,left:e.left,right:e.right,origin:e.origin,parent:e.parent,struct:e.struct};return null!=e.parentSub&&(t.parentSub=e.parentSub),e.hasOwnProperty("opContent")?t.opContent=e.opContent:t.content=e.content.slice(),t},requiredOps:function(t){var n=[];return null!=t.left&&n.push(t.left),null!=t.right&&n.push(t.right),null==t.origin||e.utils.compareIds(t.left,t.origin)||n.push(t.origin),n.push(t.parent),null!=t.opContent&&n.push(t.opContent),n},getDistanceToOrigin:function*(t){if(null==t.left)return 0;for(var n=0,r=yield*this.getInsertion(t.left);!e.utils.matchesId(r,t.origin)&&(n++,null!=r.left);)r=yield*this.getInsertion(r.left);return n},execute:function*(n){var r,i=[];if(null!=n.origin){var o=yield*this.getInsertionCleanEnd(n.origin);null==o.originOf&&(o.originOf=[]),o.originOf.push(n.id),yield*this.setOperation(o),null!=o.right&&i.push(o.right)}var s=r=yield*t.Insert.getDistanceToOrigin.call(this,n),a,l,u;if(null!=n.left)a=yield*this.getInsertionCleanEnd(n.left),e.utils.compareIds(n.left,n.origin)||null==a.right||i.push(a.right),a=null==a.right?null:yield*this.getOperation(a.right);else{l=yield*this.getOperation(n.parent);let e=n.parentSub?l.map[n.parentSub]:l.start;u=null==e?null:yield*this.getOperation(e),a=u}for(null!=n.right&&(i.push(n.right),yield*this.getInsertionCleanStart(n.right));null!=a&&!e.utils.compareIds(a.id,n.right);){var c=yield*t.Insert.getDistanceToOrigin.call(this,a);if(c===r)a.id[0]<n.id[0]&&(n.left=e.utils.getLastId(a),s=r+1);else{if(!(c<r))break;r-s<=c&&(n.left=e.utils.getLastId(a),s=r+1)}r++,a=null!=a.right?yield*this.getInsertion(a.right):null}var h=null,f=null;for(null==l&&(l=yield*this.getOperation(n.parent)),null!=n.left?(h=yield*this.getInsertion(n.left),n.right=h.right,h.right=n.id,yield*this.setOperation(h)):n.right=n.parentSub?l.map[n.parentSub]||null:l.start,null!=n.right&&(f=yield*this.getOperation(n.right),f.left=e.utils.getLastId(n),null!=f.gc&&(null!=f.content&&f.content.length>1&&(f=yield*this.getInsertionCleanEnd(f.id)),this.store.removeFromGarbageCollector(f)),yield*this.setOperation(f)),null!=n.parentSub?(null==h&&(l.map[n.parentSub]=n.id,yield*this.setOperation(l)),null!=n.right&&(yield*this.deleteOperation(n.right,1,!0)),null!=n.left&&(yield*this.deleteOperation(n.id,1,!0))):null!=f&&null!=h||(null==f&&(l.end=e.utils.getLastId(n)),null==h&&(l.start=n.id),yield*this.setOperation(l)),r=0;r<i.length;r++){var p=yield*this.getOperation(i[r]);yield*this.tryCombineWithLeft(p)}}},List:{create:function(e){return{start:null,end:null,struct:"List",id:e}},encode:function(e){var t={struct:"List",id:e.id,type:e.type};return null!=e.requires&&(t.requires=e.requires),null!=e.info&&(t.info=e.info),t},requiredOps:function(){return[]},execute:function*(e){e.start=null,e.end=null},ref:function*(e,t){if(null==e.start)return null;for(var n=null,r=yield*this.getOperation(e.start);r.deleted||(n=r,t--),t>=0&&null!=r.right;)r=yield*this.getOperation(r.right);return n},map:function*(e,t){e=e.start;for(var n=[];null!=e;){var r=yield*this.getOperation(e);r.deleted||n.push(t(r)),e=r.right}return n}},Map:{create:function(e){return{id:e,map:{},struct:"Map"}},encode:function(e){var t={struct:"Map",type:e.type,id:e.id,map:{}};return null!=e.requires&&(t.requires=e.requires),null!=e.info&&(t.info=e.info),t},requiredOps:function(){return[]},execute:function*(){},get:function*(e,t){var n=e.map[t];if(null!=n){var r=yield*this.getOperation(n);return null==r||r.deleted?void 0:null==r.opContent?r.content[0]:yield*this.getType(r.opContent)}}}};e.Struct=t}},function(e,t,n){"use strict";e.exports=function(e){e.utils={},e.utils.bubbleEvent=function(e,t){for(e.eventHandler.callEventListeners(t),t.path=[];null!=e&&null!=e._deepEventHandler;){e._deepEventHandler.callEventListeners(t);var n=null;null!=e._parent&&(n=e.os.getType(e._parent)),null!=n&&null!=n._getPathToChild?(t.path=[n._getPathToChild(e._model)].concat(t.path),e=n):e=null}};class t{constructor(){this.eventListeners=[]}destroy(){this.eventListeners=null}addEventListener(e){this.eventListeners.push(e)}removeEventListener(e){this.eventListeners=this.eventListeners.filter(function(t){return e!==t})}removeAllEventListeners(){this.eventListeners=[]}callEventListeners(e){for(var t=0;t<this.eventListeners.length;t++)try{var n={};for(var r in e)n[r]=e[r];this.eventListeners[t](n)}catch(e){console.error('Your observer threw an error. This error was caught so that Yjs still can ensure data consistency! In order to debug this error you have to check "Pause On Caught Exceptions"',e)}}}e.utils.EventListenerHandler=t;class n extends t{constructor(e){super(),this.waiting=[],this.awaiting=0,this.onevent=e}destroy(){super.destroy(),this.waiting=null,this.onevent=null}receivedOp(e){if(this.awaiting<=0)this.onevent(e);else if("Delete"===e.struct){var t=this,n=function e(n){if(null==n.length)throw new Error("This shouldn't happen! d.length must be defined!");for(var r=0;r<t.waiting.length;r++){var i=t.waiting[r];if("Insert"===i.struct&&i.id[0]===n.target[0]){var o=i.hasOwnProperty("content")?i.content.length:1,s=n.target[1],a=n.target[1]+(n.length||1),l=i.id[1],u=i.id[1]+o;if(u<=s||a<=l)continue;if(l<s){if(s<u){if(u<a){i.content.splice(s-l),n.length=a-u,n.target=[n.target[0],u];continue}if(u===a)return void i.content.splice(s-l);var c={id:[i.id[0],a],content:i.content.slice(a-l),struct:"Insert"};return t.waiting.push(c),void i.content.splice(s-l)}}else{if(s===l){if(u<a){n.length=a-u,n.target=[n.target[0],u],i.content=[];continue}return u===a?void t.waiting.splice(r,1):(i.content=i.content.slice(a-l),void(i.id=[i.id[0],a]))}if(l<a){if(u<a)return t.waiting.splice(r,1),e({target:[n.target[0],s],length:l-s,struct:"Delete"}),void e({target:[n.target[0],u],length:u-a,struct:"Delete"});if(u===a){t.waiting.splice(r,1),r--,n.length-=o;continue}n.length=l-s,i.content.splice(0,a-l),i.id=[i.id[0],a];continue}}}}t.waiting.push(n)};null==e.key?n(e):this.waiting.push(e)}else this.waiting.push(e)}awaitAndPrematurelyCall(t){this.awaiting++,t.map(e.utils.copyOperation).forEach(this.onevent)}*awaitOps(t,n,r){function i(t){for(var n=[];t.length>0;)for(var r=0;r<t.length;r++){for(var i=!0,o=0;o<t.length;o++)if(e.utils.matchesId(t[o],t[r].left)){i=!1;break}i&&(n.push(t.splice(r,1)[0]),r--)}return n}var o=this.waiting.length;if(yield*n.apply(t,r),this.waiting.splice(o),this.awaiting>0&&this.awaiting--,0===this.awaiting&&this.waiting.length>0){for(let n=0;n<this.waiting.length;n++){var s=this.waiting[n];if("Insert"===s.struct){var a=yield*t.getInsertion(s.id);if(null!=a.parentSub&&null!=a.left)this.waiting.splice(n,1),n--;else if(e.utils.compareIds(a.id,s.id))if(null==a.left)s.left=null;else{for(var l=yield*t.getInsertion(a.left);null!=l.deleted;){if(null==l.left){l=null;break}l=yield*t.getInsertion(l.left)}s.left=null!=l?e.utils.getLastId(l):null}else s.left=[s.id[0],s.id[1]-1]}}if(null!=this._pullChanges&&this._pullChanges(),0===this.awaiting){var u=[],c=[];this.waiting.forEach(function(e){"Delete"===e.struct?c.push(e):u.push(e)}),this.waiting=[],u=i(u);for(var h=0;h<u.length;h++){if(0!==this.awaiting){this.waiting=this.waiting.concat(u.slice(h));break}this.onevent(u[h])}for(h=0;h<c.length;h++){if(0!==this.awaiting){this.waiting=this.waiting.concat(c.slice(h));break}this.onevent(c[h])}}}}awaitedInserts(t){for(var n=this.waiting.splice(this.waiting.length-t),r=0;r<n.length;r++){var i=n[r];if("Insert"!==i.struct)throw new Error("Expected Insert Operation!");for(var o=this.waiting.length-1;o>=0;o--){let t=this.waiting[o];"Insert"===t.struct&&(e.utils.matchesId(t,i.left)?(t.right=i.id,i.left=t.left):e.utils.compareIds(t.id,i.right)&&(t.left=e.utils.getLastId(i),i.right=t.right))}}this._tryCallEvents(t)}awaitedDeletes(t,n){for(var r=this.waiting.splice(this.waiting.length-t),i=0;i<r.length;i++){var o=r[i];if("Delete"!==o.struct)throw new Error("Expected Delete Operation!");if(null!=n)for(var s=0;s<this.waiting.length;s++){let t=this.waiting[s];"Insert"===t.struct&&e.utils.compareIds(o.target,t.left)&&(t.left=n)}}this._tryCallEvents(t)}_tryCallEvents(){function t(t){for(var n=[];t.length>0;)for(var r=0;r<t.length;r++){for(var i=!0,o=0;o<t.length;o++)if(e.utils.matchesId(t[o],t[r].left)){i=!1;break}i&&(n.push(t.splice(r,1)[0]),r--)}return n}if(this.awaiting>0&&this.awaiting--,0===this.awaiting&&this.waiting.length>0){var n=[],r=[];this.waiting.forEach(function(e){"Delete"===e.struct?r.push(e):n.push(e)}),n=t(n),n.forEach(this.onevent),r.forEach(this.onevent),this.waiting=[]}}}e.utils.EventHandler=n;class r{getPath(){var e=null;if(null!=this._parent&&(e=this.os.getType(this._parent)),null!=e&&null!=e._getPathToChild){var t=e._getPathToChild(this._model),n=e.getPath();return n.push(t),n}return[]}}e.utils.CustomType=r;class i{constructor(e){if(null==e.struct||null==e.initType||null==e.class||null==e.name||null==e.createType)throw new Error("Custom type was not initialized correctly!");this.struct=e.struct,this.initType=e.initType,this.createType=e.createType,this.class=e.class,this.name=e.name,null!=e.appendAdditionalInfo&&(this.appendAdditionalInfo=e.appendAdditionalInfo),this.parseArguments=(e.parseArguments||function(){return[this]}).bind(this),this.parseArguments.typeDefinition=this}}function o(e){var t={};for(var n in e)t[n]=e[n];return t}function s(e){return e=o(e),null!=e.content&&(e.content=e.content.map(function(e){return e})),e}function a(e,t){return e[0]<t[0]||e[0]===t[0]&&(e[1]<t[1]||typeof e[1]<typeof t[1])}function l(e,t){return e.target[0]===t[0]&&e.target[1]<=t[1]&&t[1]<e.target[1]+(e.length||1)}function u(e,t){return null==e||null==t?e===t:e[0]===t[0]&&e[1]===t[1]}function c(e,t){return null==t||null==e?t===e:t[0]===e.id[0]?null==e.content?t[1]===e.id[1]:t[1]>=e.id[1]&&t[1]<e.id[1]+e.content.length:void 0}function h(e){return null==e.content||1===e.content.length?e.id:[e.id[0],e.id[1]+e.content.length-1]}function f(e){for(var t=new Array(e),n=0;n<t.length;n++)t[n]={id:[null,null]};return t}function p(e){class t extends e{constructor(e,t){super(e,t),this.writeBuffer=f(5),this.readBuffer=f(10)}*find(e,t){var n,r,i;for(n=this.readBuffer.length-1;n>=0;n--)if(r=this.readBuffer[n],r.id[1]===e[1]&&r.id[0]===e[0]){for(;n<this.readBuffer.length-1;n++)this.readBuffer[n]=this.readBuffer[n+1];return this.readBuffer[this.readBuffer.length-1]=r,r}for(n=this.writeBuffer.length-1;n>=0;n--)if(r=this.writeBuffer[n],r.id[1]===e[1]&&r.id[0]===e[0]){i=r;break}if(n<0&&void 0===t&&(i=yield*super.find(e)),null!=i){for(n=0;n<this.readBuffer.length-1;n++)this.readBuffer[n]=this.readBuffer[n+1];this.readBuffer[this.readBuffer.length-1]=i}return i}*put(e){var t=e.id,n,r;for(n=this.writeBuffer.length-1;n>=0;n--)if(r=this.writeBuffer[n],r.id[1]===t[1]&&r.id[0]===t[0]){for(;n<this.writeBuffer.length-1;n++)this.writeBuffer[n]=this.writeBuffer[n+1];this.writeBuffer[this.writeBuffer.length-1]=e;break}if(n<0){var i=this.writeBuffer[0];for(null!==i.id[0]&&(yield*super.put(i)),n=0;n<this.writeBuffer.length-1;n++)this.writeBuffer[n]=this.writeBuffer[n+1];this.writeBuffer[this.writeBuffer.length-1]=e}for(n=0;n<this.readBuffer.length-1;n++)r=this.readBuffer[n+1],r.id[1]===t[1]&&r.id[0]===t[0]?this.readBuffer[n]=e:this.readBuffer[n]=r;this.readBuffer[this.readBuffer.length-1]=e}*delete(e){var t,n;for(t=0;t<this.readBuffer.length;t++)n=this.readBuffer[t],n.id[1]===e[1]&&n.id[0]===e[0]&&(this.readBuffer[t]={id:[null,null]});yield*this.flush(),yield*super.delete(e)}*findWithLowerBound(e){var t=yield*this.find(e,!0);return null!=t?t:(yield*this.flush(),yield*super.findWithLowerBound.apply(this,arguments))}*findWithUpperBound(e){var t=yield*this.find(e,!0);return null!=t?t:(yield*this.flush(),yield*super.findWithUpperBound.apply(this,arguments))}*findNext(){return yield*this.flush(),yield*super.findNext.apply(this,arguments)}*findPrev(){return yield*this.flush(),yield*super.findPrev.apply(this,arguments)}*iterate(){yield*this.flush(),yield*super.iterate.apply(this,arguments)}*flush(){for(var e=0;e<this.writeBuffer.length;e++){var t=this.writeBuffer[e];null!==t.id[0]&&(yield*super.put(t),this.writeBuffer[e]={id:[null,null]})}}}return t}function d(e){return e?(e^16*Math.random()>>e/4).toString(16):([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,d)}e.utils.CustomTypeDefinition=i,e.utils.isTypeDefinition=function t(n){if(null!=n){if(n instanceof e.utils.CustomTypeDefinition)return[n];if(n.constructor===Array&&n[0]instanceof e.utils.CustomTypeDefinition)return n;if(n instanceof Function&&n.typeDefinition instanceof e.utils.CustomTypeDefinition)return[n.typeDefinition]}return!1},e.utils.copyObject=o,e.utils.copyOperation=s,e.utils.smaller=a,e.utils.inDeletionRange=l,e.utils.compareIds=u,e.utils.matchesId=c,e.utils.getLastId=h,e.utils.createSmallLookupBuffer=p,e.utils.generateGuid=d}},function(e,t,n){"use strict";e.exports=function(e){var t={users:{},buffers:{},removeUser:function(e){for(var t in this.users)this.users[t].userLeft(e);delete this.users[e],delete this.buffers[e]},addUser:function(e){for(var t in this.users[e.userId]=e,this.buffers[e.userId]={},this.users)if(t!==e.userId){var n=this.users[t];n.userJoined(e.userId,"master"),e.userJoined(n.userId,"master")}},whenTransactionsFinished:function(){var e=this;return new Promise(function(t,n){setTimeout(function(){var r=[];for(var i in e.users)r.push(e.users[i].y.db.whenTransactionsFinished());Promise.all(r).then(t,n)},10)})},flushOne:function e(){var n=[];for(var r in t.buffers){let e=t.buffers[r];var i=!1;for(let t in e)if(e[t].length>0){i=!0;break}i&&n.push(r)}if(n.length>0){var o=getRandom(n);let e=t.buffers[o],r=getRandom(Object.keys(e));var s=e[r].shift();0===e[r].length&&delete e[r];var a=t.users[o];return a.receiveMessage(s[0],s[1]).then(function(){return a.y.db.whenTransactionsFinished()},function(){})}return!1},flushAll:function(){return new Promise(function(e){function n(){var r=t.flushOne();if(r){for(;r;)r=t.flushOne();t.whenTransactionsFinished().then(n)}else r=t.flushOne(),r?r.then(function(){t.whenTransactionsFinished().then(n)}):e()}t.whenTransactionsFinished().then(n)})}};e.utils.globalRoom=t;var n=0;class r extends e.AbstractConnector{constructor(e,r){if(void 0===r)throw new Error("Options must not be undefined!");r.role="master",r.forwardToSyncingClients=!1,super(e,r),this.setUserId(n+++"").then(()=>{t.addUser(this)}),this.globalRoom=t,this.syncingClientDuration=0}receiveMessage(e,t){return super.receiveMessage(e,JSON.parse(JSON.stringify(t)))}send(e,n){var r=t.buffers[e];null!=r&&(null==r[this.userId]&&(r[this.userId]=[]),r[this.userId].push(JSON.parse(JSON.stringify([this.userId,n]))))}broadcast(e){for(var n in t.buffers){var r=t.buffers[n];null==r[this.userId]&&(r[this.userId]=[]),r[this.userId].push(JSON.parse(JSON.stringify([this.userId,e])))}}isDisconnected(){return null==t.users[this.userId]}reconnect(){return this.isDisconnected()&&(t.addUser(this),super.reconnect()),e.utils.globalRoom.flushAll()}disconnect(){var e=Promise.resolve();this.isDisconnected()||(t.removeUser(this.userId),e=super.disconnect());var n=this;return e.then(function(){return n.y.db.whenTransactionsFinished()})}flush(){var e=this;return async(function*(){for(var n=t.buffers[e.userId];Object.keys(n).length>0;){var r=getRandom(Object.keys(n)),i=n[r].shift();0===n[r].length&&delete n[r],yield this.receiveMessage(i[0],i[1])}yield e.whenTransactionsFinished()})}}e.Test=r}},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(1491),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t,n){var r;function i(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function o(e){function n(){if(n.enabled){var e=n,i=+new Date,o=i-(r||i);e.diff=o,e.prev=r,e.curr=i,r=i;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=n.log||t.log||console.log.bind(console);u.apply(e,s)}}return n.namespace=e,n.enabled=t.enabled(e),n.useColors=t.useColors(),n.color=i(e),"function"==typeof t.init&&t.init(n),n}function s(e){t.save(e),t.names=[],t.skips=[];for(var n=("string"==typeof e?e:"").split(/[\s,]+/),r=n.length,i=0;i<r;i++)n[i]&&(e=n[i].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))}function a(){t.enable("")}function l(e){var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=o.debug=o.default=o,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(1492),t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t){function n(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id=1493},function(e,t,n){"use strict";function r(e){n(1495)(e);class t extends e.Transaction{constructor(e){super(e),this.store=e,this.ss=e.ss,this.os=e.os,this.ds=e.ds}}var r=e.utils.RBTree,i=e.utils.createSmallLookupBuffer(r);class o extends e.AbstractDatabase{constructor(e,t){super(e,t),this.os=new i,this.ds=new r,this.ss=new i}logTable(){var e=this;this.requestTransaction(function*(){console.log("User: ",this.store.y.connector.userId,"=============================="),console.log("State Set (SS):",yield*this.getStateSet()),console.log("Operation Store (OS):"),yield*this.os.logTable(),console.log("Deletion Store (DS):"),yield*this.ds.logTable(),(this.store.gc1.length>0||this.store.gc2.length>0)&&console.warn("GC1|2 not empty!",this.store.gc1,this.store.gc2),"{}"!==JSON.stringify(this.store.listenersById)&&console.warn("listenersById not empty!"),"[]"!==JSON.stringify(this.store.listenersByIdExecuteNow)&&console.warn("listenersByIdExecuteNow not empty!"),this.store.transactionInProgress&&console.warn("Transaction still in progress!")},!0)}transact(e){for(var n=new t(this);null!==e;){for(var r=e.call(n),i=r.next();!i.done;)i=r.next(i.value);e=this.getNextRequest()}}*destroy(){yield*super.destroy(),delete this.os,delete this.ss,delete this.ds}}e.extend("memory",o)}e.exports=r,"undefined"!=typeof Y&&r(Y)},function(e,t,n){"use strict";e.exports=function(e){class t{constructor(e){if(this.val=e,this.color=!0,this._left=null,this._right=null,this._parent=null,null===e.id)throw new Error("You must define id!")}isRed(){return this.color}isBlack(){return!this.color}redden(){return this.color=!0,this}blacken(){return this.color=!1,this}get grandparent(){return this.parent.parent}get parent(){return this._parent}get sibling(){return this===this.parent.left?this.parent.right:this.parent.left}get left(){return this._left}get right(){return this._right}set left(e){null!==e&&(e._parent=this),this._left=e}set right(e){null!==e&&(e._parent=this),this._right=e}rotateLeft(e){var t=this.parent,n=this.right,r=this.right.left;if(n.left=this,this.right=r,null===t)e.root=n,n._parent=null;else if(t.left===this)t.left=n;else{if(t.right!==this)throw new Error("The elements are wrongly connected!");t.right=n}}next(){if(null!==this.right){for(var e=this.right;null!==e.left;)e=e.left;return e}for(var t=this;null!==t.parent&&t!==t.parent.left;)t=t.parent;return t.parent}prev(){if(null!==this.left){for(var e=this.left;null!==e.right;)e=e.right;return e}for(var t=this;null!==t.parent&&t!==t.parent.right;)t=t.parent;return t.parent}rotateRight(e){var t=this.parent,n=this.left,r=this.left.right;if(n.right=this,this.left=r,null===t)e.root=n,n._parent=null;else if(t.left===this)t.left=n;else{if(t.right!==this)throw new Error("The elements are wrongly connected!");t.right=n}}getUncle(){return this.parent===this.parent.parent.left?this.parent.parent.right:this.parent.parent.left}}class n{constructor(){this.root=null,this.length=0}*findNext(e){return yield*this.findWithLowerBound([e[0],e[1]+1])}*findPrev(e){return yield*this.findWithUpperBound([e[0],e[1]-1])}findNodeWithLowerBound(t){if(void 0===t)throw new Error("You must define from!");var n=this.root;if(null===n)return null;for(;;)if(null!==t&&!e.utils.smaller(t,n.val.id)||null===n.left){if(null===t||!e.utils.smaller(n.val.id,t))return n;if(null===n.right)return n.next();n=n.right}else n=n.left}findNodeWithUpperBound(t){if(void 0===t)throw new Error("You must define from!");var n=this.root;if(null===n)return null;for(;;)if(null!==t&&!e.utils.smaller(n.val.id,t)||null===n.right){if(null===t||!e.utils.smaller(t,n.val.id))return n;if(null===n.left)return n.prev();n=n.left}else n=n.right}findSmallestNode(){for(var e=this.root;null!=e&&null!=e.left;)e=e.left;return e}*findWithLowerBound(e){var t=this.findNodeWithLowerBound(e);return null==t?null:t.val}*findWithUpperBound(e){var t=this.findNodeWithUpperBound(e);return null==t?null:t.val}*iterate(t,n,r,i){var o;for(o=null===n?this.findSmallestNode():this.findNodeWithLowerBound(n);null!==o&&(null===r||e.utils.smaller(o.val.id,r)||e.utils.compareIds(o.val.id,r));)yield*i.call(t,o.val),o=o.next();return!0}*logTable(e,t,n){null==n&&(n=function(){return!0}),null==e&&(e=null),null==t&&(t=null);var r=[];yield*this.iterate(this,e,t,function*(e){if(n(e)){var t={};for(var i in e)"object"==typeof e[i]?t[i]=JSON.stringify(e[i]):t[i]=e[i];r.push(t)}}),null!=console.table&&console.table(r)}*find(e){var t;return(t=this.findNode(e))?t.val:null}findNode(t){if(null==t||t.constructor!==Array)throw new Error("Expect id to be an array!");var n=this.root;if(null===n)return!1;for(;;){if(null===n)return!1;if(e.utils.smaller(t,n.val.id))n=n.left;else{if(!e.utils.smaller(n.val.id,t))return n;n=n.right}}}*delete(e){if(null==e||e.constructor!==Array)throw new Error("id is expected to be an Array!");var n=this.findNode(e);if(null!=n){if(this.length--,null!==n.left&&null!==n.right){for(var r=n.left;null!==r.right;)r=r.right;n.val=r.val,n=r}var i,o=n.left||n.right;if(null===o?(i=!0,o=new t({id:0}),o.blacken(),n.right=o):i=!1,null!==n.parent){if(n.parent.left===n)n.parent.left=o;else{if(n.parent.right!==n)throw new Error("Impossible!");n.parent.right=o}if(n.isBlack()&&(o.isRed()?o.blacken():this._fixDelete(o)),this.root.blacken(),i)if(o.parent.left===o)o.parent.left=null;else{if(o.parent.right!==o)throw new Error("Impossible #3");o.parent.right=null}}else i?this.root=null:(this.root=o,o.blacken(),o._parent=null)}}_fixDelete(e){function t(e){return null===e||e.isBlack()}function n(e){return null!==e&&e.isRed()}if(null!==e.parent){var r=e.sibling;if(n(r)){if(e.parent.redden(),r.blacken(),e===e.parent.left)e.parent.rotateLeft(this);else{if(e!==e.parent.right)throw new Error("Impossible #2");e.parent.rotateRight(this)}r=e.sibling}e.parent.isBlack()&&r.isBlack()&&t(r.left)&&t(r.right)?(r.redden(),this._fixDelete(e.parent)):e.parent.isRed()&&r.isBlack()&&t(r.left)&&t(r.right)?(r.redden(),e.parent.blacken()):(e===e.parent.left&&r.isBlack()&&n(r.left)&&t(r.right)?(r.redden(),r.left.blacken(),r.rotateRight(this),r=e.sibling):e===e.parent.right&&r.isBlack()&&n(r.right)&&t(r.left)&&(r.redden(),r.right.blacken(),r.rotateLeft(this),r=e.sibling),r.color=e.parent.color,e.parent.blacken(),e===e.parent.left?(r.right.blacken(),e.parent.rotateLeft(this)):(r.left.blacken(),e.parent.rotateRight(this)))}}*put(n){if(null==n||null==n.id||n.id.constructor!==Array)throw new Error("v is expected to have an id property which is an Array!");var r=new t(n);if(null!==this.root){for(var i=this.root;;)if(e.utils.smaller(r.val.id,i.val.id)){if(null===i.left){i.left=r;break}i=i.left}else{if(!e.utils.smaller(i.val.id,r.val.id))return i.val=r.val,i;if(null===i.right){i.right=r;break}i=i.right}this._fixInsert(r)}else this.root=r;return this.length++,this.root.blacken(),r}_fixInsert(e){if(null!==e.parent){if(!e.parent.isBlack()){var t=e.getUncle();null!==t&&t.isRed()?(e.parent.blacken(),t.blacken(),e.grandparent.redden(),this._fixInsert(e.grandparent)):(e===e.parent.right&&e.parent===e.grandparent.left?(e.parent.rotateLeft(this),e=e.left):e===e.parent.left&&e.parent===e.grandparent.right&&(e.parent.rotateRight(this),e=e.right),e.parent.blacken(),e.grandparent.redden(),e===e.parent.left?e.grandparent.rotateRight(this):e.grandparent.rotateLeft(this))}}else e.blacken()}*flush(){}}e.utils.RBTree=n}},function(e,t,n){"use strict";function r(e){class t extends e.utils.CustomType{constructor(t,n,r){super(),this.os=t,this._model=n,this._content=r,this._parent=null,this._deepEventHandler=new e.utils.EventListenerHandler,this.eventHandler=new e.utils.EventHandler(t=>{if("Insert"===t.struct){if(this._content.some(function(n){return e.utils.compareIds(n.id,t.id)}))return;let o;if(null===t.left)o=0;else if(o=1+this._content.findIndex(function(n){return e.utils.compareIds(n.id,t.left)}),o<=0)throw new Error("Unexpected operation!");var n,r;if(t.hasOwnProperty("opContent")){this._content.splice(o,0,{id:t.id,type:t.opContent}),r=1;let e=this.os.getType(t.opContent);e._parent=this._model,n=[e]}else{var i=t.content.map(function(e,n){return{id:[t.id[0],t.id[1]+n],val:e}});i.length<3e4?this._content.splice.apply(this._content,[o,0].concat(i)):this._content=this._content.slice(0,o).concat(i).concat(this._content.slice(o)),n=t.content,r=t.content.length}e.utils.bubbleEvent(this,{type:"insert",object:this,index:o,values:n,length:r})}else{if("Delete"!==t.struct)throw new Error("Unexpected struct!");for(var o=0;o<this._content.length&&t.length>0;o++){var s=this._content[o];if(e.utils.inDeletionRange(t,s.id)){var a;for(a=1;a<t.length&&o+a<this._content.length&&e.utils.inDeletionRange(t,this._content[o+a].id);a++);s=this._content[o+a-1],t.length-=s.id[1]-t.target[1]+1,t.target=[s.id[0],s.id[1]+1];let n=this._content.splice(o,a),r=n.map(e=>null!=e.val?e.val:this.os.getType(e.type));e.utils.bubbleEvent(this,{type:"delete",object:this,index:o,values:r,_content:n,length:a})}}}})}_getPathToChild(t){return this._content.findIndex(n=>null!=n.type&&e.utils.compareIds(n.type,t))}_destroy(){this.eventHandler.destroy(),this.eventHandler=null,this._content=null,this._model=null,this._parent=null,this.os=null}get length(){return this._content.length}get(e){if(null==e||"number"!=typeof e)throw new Error("pos must be a number!");if(!(e>=this._content.length))return null==this._content[e].type?this._content[e].val:this.os.getType(this._content[e].type)}toArray(){return this._content.map((e,t)=>null!=e.type?this.os.getType(e.type):e.val)}push(e){return this.insert(this._content.length,e)}insert(t,n){if("number"!=typeof t)throw new Error("pos must be a number!");if(!Array.isArray(n))throw new Error("contents must be an Array of objects!");if(0!==n.length){if(t>this._content.length||t<0)throw new Error("This position exceeds the range of the array!");for(var r=0===t?null:this._content[t-1].id,i=[],o=r,s=0;s<n.length;){for(var a={left:o,origin:o,parent:this._model,struct:"Insert"},l=[],u;s<n.length;){var c=n[s++];if(u=e.utils.isTypeDefinition(c),u){if(l.length>0){s--;break}break}l.push(c)}if(l.length>0)a.content=l,a.id=this.os.getNextOpId(l.length);else{var h=this.os.getNextOpId(1);this.os.createType(u,h),a.opContent=h,a.id=this.os.getNextOpId(1)}i.push(a),o=a.id}var f=this.eventHandler;this.os.requestTransaction(function*(){var e;if(null!=r){var t=yield*this.getInsertionCleanEnd(r);e=t.right}else e=(yield*this.getOperation(i[0].parent)).start;for(var n=0;n<i.length;n++){var o=i[n];o.right=e}yield*f.awaitOps(this,this.applyCreatedOperations,[i])}),f.awaitAndPrematurelyCall(i)}}delete(t,n){if(null==n&&(n=1),"number"!=typeof n)throw new Error("length must be a number!");if("number"!=typeof t)throw new Error("pos must be a number!");if(t+n>this._content.length||t<0||n<0)throw new Error("The deletion range exceeds the range of the array!");if(0!==n){for(var r=this.eventHandler,i=[],o=0;o<n;o+=a){var s=this._content[t+o].id,a;for(a=1;o+a<n&&e.utils.compareIds(this._content[t+o+a].id,[s[0],s[1]+a]);a++);i.push({target:s,struct:"Delete",length:a})}this.os.requestTransaction(function*(){yield*r.awaitOps(this,this.applyCreatedOperations,[i])}),r.awaitAndPrematurelyCall(i)}}observe(e){this.eventHandler.addEventListener(e)}observeDeep(e){this._deepEventHandler.addEventListener(e)}unobserve(e){this.eventHandler.removeEventListener(e)}unobserveDeep(e){this._deepEventHandler.removeEventListener(e)}*_changed(e,t){if(!t.deleted){if("Insert"===t.struct){for(var n=t.left,r;null!=n&&(r=yield*e.getInsertion(n),r.deleted);)n=r.left;t.left=n,null!=t.opContent&&(yield*e.store.initType.call(e,t.opContent))}this.eventHandler.receivedOp(t)}}}e.extend("Array",new e.utils.CustomTypeDefinition({name:"Array",class:t,struct:"List",initType:function*n(r,i){var o=[],s=[];yield*e.Struct.List.map.call(this,i,function(e){e.hasOwnProperty("opContent")?(o.push({id:e.id,type:e.opContent}),s.push(e.opContent)):e.content.forEach(function(t,n){o.push({id:[e.id[0],e.id[1]+n],val:e.content[n]})})});for(var a=0;a<s.length;a++){var l=yield*this.store.initType.call(this,s[a]);l._parent=i.id}return new t(r,i.id,o)},createType:function e(n,r){return new t(n,r.id,[])}}))}e.exports=r,"undefined"!=typeof Y&&r(Y)},function(e,t,n){"use strict";var r=n(1498),i={major:0,minor:0};function o(e){e.requestModules(["Array"]).then(function(){class t extends e.Array.typeDefinition.class{constructor(e,t,n){super(e,t,n),this.textfields=[],this.aceInstances=[],this.codeMirrorInstances=[],this.monacoInstances=[]}toString(){return this._content.map(function(e){return e.val}).join("")}insert(e,t){for(var n=t.split(""),r=0;r<n.length;r++)/[\uD800-\uDFFF]/.test(n[r])&&(n[r]=n[r]+n[r+1],n[r+1]="",r++);super.insert(e,n)}delete(e,t){if(null==t&&(t=1),"number"!=typeof t)throw new Error("length must be a number!");if("number"!=typeof e)throw new Error("pos must be a number!");if(e+t>this._content.length||e<0||t<0)throw new Error("The deletion range exceeds the range of the array!");if(0!==t)if(this._content.length>e+t&&""===this._content[e+t].val&&2===this._content[e+t-1].val.length){let n=this._content[e+t-1].val[0];super.delete(e,t+1),super.insert(e,[n])}else if(e>0&&""===this._content[e].val&&2===this._content[e-1].val.length){let n=this._content[e-1].val[1];super.delete(e-1,t+1),super.insert(e-1,[n])}else super.delete(e,t)}unbindAll(){this.unbindTextareaAll(),this.unbindAceAll(),this.unbindCodeMirrorAll(),this.unbindMonacoAll()}unbindMonaco(e){var t=this.monacoInstances.findIndex(function(t){return t.editor===e});if(t>=0){var n=this.monacoInstances[t];this.unobserve(n.yCallback),n.disposeBinding(),this.monacoInstances.splice(t,1)}}unbindMonacoAll(){for(let e=this.monacoInstances.length-1;e>=0;e--)this.unbindMonaco(this.monacoInstances[e].editor)}bindMonaco(e,t){var n=this;t=t||{};var r=!0;function o(e){if(r){r=!1;try{e()}catch(e){throw r=!0,new Error(e)}r=!0}}function s(e){o(function(){for(var t=0,r=1;r<e.range.startLineNumber;t++)"\n"===n._content[t].val&&r++;var i=t+e.range.startColumn-1;e.rangeLength>0&&n.delete(i,e.rangeLength),n.insert(i,e.text)})}e.setValue(this.toString());var a=e.onDidChangeModelContent(s).dispose;function l(t){o(function(){let n=e.model.getPositionAt(t.index);var r,o;"insert"===t.type?(r=n,o=t.values.join("")):"delete"===t.type&&(r=e.model.modifyPosition(n,t.length),o="");var s={startLineNumber:n.lineNumber,startColumn:n.column,endLineNumber:r.lineNumber,endColumn:r.column},a={major:i.major,minor:i.minor++};e.executeEdits("Yjs",[{id:a,range:s,text:o,forceMoveMarkers:!0}])})}this.observe(l),this.monacoInstances.push({editor:e,yCallback:l,monacoCallback:s,disposeBinding:a})}unbindCodeMirror(e){var t=this.codeMirrorInstances.findIndex(function(t){return t.editor===e});if(t>=0){var n=this.codeMirrorInstances[t];this.unobserve(n.yCallback),n.editor.off("changes",n.codeMirrorCallback),this.codeMirrorInstances.splice(t,1)}}unbindCodeMirrorAll(){for(let e=this.codeMirrorInstances.length-1;e>=0;e--)this.unbindCodeMirror(this.codeMirrorInstances[e].editor)}bindCodeMirror(e,t){var n=this;t=t||{};var r=!0;function i(e){if(r){r=!1;try{e()}catch(e){throw r=!0,new Error(e)}r=!0}}function o(t,r){i(function(){for(var t=0;t<r.length;t++){var i=r[t],o=e.indexFromPos(i.from);if(i.removed.length>0){for(var s=0,a=0;a<i.removed.length;a++)s+=i.removed[a].length;s+=i.removed.length-1,n.delete(o,s)}n.insert(o,i.text.join("\n"))}})}function s(t){i(function(){let n=e.posFromIndex(t.index);if("insert"===t.type){let r=n;e.replaceRange(t.values.join(""),n,r)}else if("delete"===t.type){let r=e.posFromIndex(t.index+t.length);e.replaceRange("",n,r)}})}e.setValue(this.toString()),e.on("changes",o),this.observe(s),this.codeMirrorInstances.push({editor:e,yCallback:s,codeMirrorCallback:o})}unbindAce(e){var t=this.aceInstances.findIndex(function(t){return t.editor===e});if(t>=0){var n=this.aceInstances[t];this.unobserve(n.yCallback),n.editor.off("change",n.aceCallback),this.aceInstances.splice(t,1)}}unbindAceAll(){for(let e=this.aceInstances.length-1;e>=0;e--)this.unbindAce(this.aceInstances[e].editor)}bindAce(e,t){var n=this;t=t||{};var r=!0,i;function o(e){if(r){r=!1;try{e()}catch(e){throw r=!0,new Error(e)}r=!0}}function s(t){o(function(){var r,i,o=e.getSession().getDocument();"insert"===t.action?(r=o.positionToIndex(t.start,0),n.insert(r,t.lines.join("\n"))):"remove"===t.action&&(r=o.positionToIndex(t.start,0),i=t.lines.join("\n").length,n.delete(r,i))})}e.setValue(this.toString()),e.on("change",s),e.selection.clearSelection(),i="undefined"!=typeof ace&&null==t.aceClass?ace:t.aceClass;var a=t.aceRequire||i.require,l=a("ace/range").Range;function u(t){var n=e.getSession().getDocument();o(function(){if("insert"===t.type){let e=n.indexToPosition(t.index,0);n.insert(e,t.values.join(""))}else if("delete"===t.type){let r=n.indexToPosition(t.index,0),i=n.indexToPosition(t.index+t.length,0);var e=new l(r.row,r.column,i.row,i.column);n.remove(e)}})}this.observe(u),this.aceInstances.push({editor:e,yCallback:u,aceCallback:s})}bind(){var e=arguments[0];e instanceof Element?this.bindTextarea.apply(this,arguments):null!=e&&null!=e.session&&null!=e.getSession&&null!=e.setValue?this.bindAce.apply(this,arguments):null!=e&&null!=e.posFromIndex&&null!=e.replaceRange?this.bindCodeMirror.apply(this,arguments):null!=e&&null!=e.onDidChangeModelContent?this.bindMonaco.apply(this,arguments):console.error("Cannot bind, unsupported editor!")}unbindTextarea(e){var t=this.textfields.findIndex(function(t){return t.editor===e});if(t>=0){var n=this.textfields[t];this.unobserve(n.yCallback);var r=n.editor;r.removeEventListener("input",n.eventListener),this.textfields.splice(t,1)}}unbindTextareaAll(){for(let e=this.textfields.length-1;e>=0;e--)this.unbindTextarea(this.textfields[e].editor)}bindTextarea(e,t){t=t||window,null==t.getSelection&&(t=window);for(var n=0;n<this.textfields.length;n++)if(this.textfields[n].editor===e)return;var i=!0;function o(e){if(i){i=!1;try{e()}catch(e){throw i=!0,new Error(e)}i=!0}}var s=this,a,l,u,c;function h(e){o(()=>{var t,n;if("insert"===e.type){t=e.index,n=function(e){return e<=t?e:(e+=1,e)};var r=a(n);l(r)}else"delete"===e.type&&(t=e.index,n=function(e){return e<t?e:(e-=1,e)},r=a(n),l(r))})}e.value=this.toString(),null!=e.selectionStart&&null!=e.setSelectionRange?(a=function(t){var n=e.selectionStart,r=e.selectionEnd;return null!=t&&(n=t(n),r=t(r)),{left:n,right:r}},l=function(t){u(s.toString()),e.setSelectionRange(t.left,t.right)},u=function(t){e.value=t},c=function(){return e.value}):(a=function(n){var r={},i=t.getSelection(),o=e.textContent.length;r.left=Math.min(i.anchorOffset,o),r.right=Math.min(i.focusOffset,o),null!=n&&(r.left=n(r.left),r.right=n(r.right));var s=i.focusNode;return s===e||s===e.childNodes[0]?r.isReal=!0:r.isReal=!1,r},l=function(n){u(s.toString());var r=e.childNodes[0];if(n.isReal&&null!=r){n.left<0&&(n.left=0),n.right=Math.max(n.left,n.right),n.right>r.length&&(n.right=r.length),n.left=Math.min(n.left,n.right);var i=document.createRange();i.setStart(r,n.left),i.setEnd(r,n.right);var o=t.getSelection();o.removeAllRanges(),o.addRange(i)}},u=function(t){e.innerText=t},c=function(){return e.innerText}),u(this.toString()),this.observe(h);var f=function e(){o(function(){for(var e=a(function(e){return e}),t=s.toString(),n=c(),i=r(t,n,e.left),o=0,l=0;l<i.length;l++){var u=i[l];0===u[0]?o+=u[1].length:-1===u[0]?s.delete(o,u[1].length):(s.insert(o,u[1]),o+=u[1].length)}})};e.addEventListener("input",f),this.textfields.push({editor:e,yCallback:h,eventListener:f})}_destroy(){this.unbindAll(),this.textfields=null,this.aceInstances=null,super._destroy()}}e.extend("Text",new e.utils.CustomTypeDefinition({name:"Text",class:t,struct:"List",initType:function*n(r,i){var o=[];return yield*e.Struct.List.map.call(this,i,function(e){if(e.hasOwnProperty("opContent"))throw new Error("Text must not contain types!");e.content.forEach(function(t,n){o.push({id:[e.id[0],e.id[1]+n],val:e.content[n]})})}),new t(r,i.id,o)},createType:function e(n,r){return new t(n,r.id,[])}}))})}e.exports=o,"undefined"!=typeof Y&&o(Y)},function(e,t){var n=-1,r=1,i=0;function o(e,t,n,r){if(e===t)return e?[[i,e]]:[];if(null!=n){var o=b(e,t,n);if(o)return o}var a=u(e,t),l=e.substring(0,a);e=e.substring(a),t=t.substring(a),a=c(e,t);var h=e.substring(e.length-a);e=e.substring(0,e.length-a),t=t.substring(0,t.length-a);var p=s(e,t);return l&&p.unshift([i,l]),h&&p.push([i,h]),f(p,r),p}function s(e,t){var s;if(!e)return[[r,t]];if(!t)return[[n,e]];var l=e.length>t.length?e:t,u=e.length>t.length?t:e,c=l.indexOf(u);if(-1!==c)return s=[[r,l.substring(0,c)],[i,u],[r,l.substring(c+u.length)]],e.length>t.length&&(s[0][0]=s[2][0]=n),s;if(1===u.length)return[[n,e],[r,t]];var f=h(e,t);if(f){var p=f[0],d=f[1],m=f[2],g=f[3],y=f[4],v=o(p,m),b=o(d,g);return v.concat([[i,y]],b)}return a(e,t)}function a(e,t){for(var i=e.length,o=t.length,s=Math.ceil((i+o)/2),a=s,u=2*s,c=new Array(u),h=new Array(u),f=0;f<u;f++)c[f]=-1,h[f]=-1;c[a+1]=0,h[a+1]=0;for(var p=i-o,d=p%2!=0,m=0,g=0,y=0,v=0,b=0;b<s;b++){for(var _=-b+m;_<=b-g;_+=2){var w=a+_,k;k=_===-b||_!==b&&c[w-1]<c[w+1]?c[w+1]:c[w-1]+1;for(var E=k-_;k<i&&E<o&&e.charAt(k)===t.charAt(E);)k++,E++;if(c[w]=k,k>i)g+=2;else if(E>o)m+=2;else if(d){var S=a+p-_;if(S>=0&&S<u&&-1!==h[S]){var x=i-h[S];if(k>=x)return l(e,t,k,E)}}}for(var C=-b+y;C<=b-v;C+=2){var S=a+C,x;x=C===-b||C!==b&&h[S-1]<h[S+1]?h[S+1]:h[S-1]+1;for(var A=x-C;x<i&&A<o&&e.charAt(i-x-1)===t.charAt(o-A-1);)x++,A++;if(h[S]=x,x>i)v+=2;else if(A>o)y+=2;else if(!d){var w=a+p-C;if(w>=0&&w<u&&-1!==c[w]){var k=c[w],E=a+k-w;if(x=i-x,k>=x)return l(e,t,k,E)}}}}return[[n,e],[r,t]]}function l(e,t,n,r){var i=e.substring(0,n),s=t.substring(0,r),a=e.substring(n),l=t.substring(r),u=o(i,s),c=o(a,l);return u.concat(c)}function u(e,t){if(!e||!t||e.charAt(0)!==t.charAt(0))return 0;for(var n=0,r=Math.min(e.length,t.length),i=r,o=0;n<i;)e.substring(o,i)==t.substring(o,i)?(n=i,o=n):r=i,i=Math.floor((r-n)/2+n);return p(e.charCodeAt(i-1))&&i--,i}function c(e,t){if(!e||!t||e.slice(-1)!==t.slice(-1))return 0;for(var n=0,r=Math.min(e.length,t.length),i=r,o=0;n<i;)e.substring(e.length-i,e.length-o)==t.substring(t.length-i,t.length-o)?(n=i,o=n):r=i,i=Math.floor((r-n)/2+n);return d(e.charCodeAt(e.length-i))&&i--,i}function h(e,t){var n=e.length>t.length?e:t,r=e.length>t.length?t:e;if(n.length<4||2*r.length<n.length)return null;function i(e,t,n){for(var r=e.substring(n,n+Math.floor(e.length/4)),i=-1,o="",s,a,l,h;-1!==(i=t.indexOf(r,i+1));){var f=u(e.substring(n),t.substring(i)),p=c(e.substring(0,n),t.substring(0,i));o.length<p+f&&(o=t.substring(i-p,i)+t.substring(i,i+f),s=e.substring(0,n-p),a=e.substring(n+f),l=t.substring(0,i-p),h=t.substring(i+f))}return 2*o.length>=e.length?[s,a,l,h,o]:null}var o=i(n,r,Math.ceil(n.length/4)),s=i(n,r,Math.ceil(n.length/2)),a,l,h,f,p;if(!o&&!s)return null;a=s?o&&o[4].length>s[4].length?o:s:o,e.length>t.length?(l=a[0],h=a[1],f=a[2],p=a[3]):(f=a[0],p=a[1],l=a[2],h=a[3]);var d=a[4];return[l,h,f,p,d]}function f(e,t){e.push([i,""]);for(var o=0,s=0,a=0,l="",h="",p;o<e.length;)if(o<e.length-1&&!e[o][1])e.splice(o,1);else switch(e[o][0]){case r:a++,h+=e[o][1],o++;break;case n:s++,l+=e[o][1],o++;break;case i:var d=o-a-s-1;if(t){if(d>=0&&g(e[d][1])){var y=e[d][1].slice(-1);if(e[d][1]=e[d][1].slice(0,-1),l=y+l,h=y+h,!e[d][1]){e.splice(d,1),o--;var v=d-1;e[v]&&e[v][0]===r&&(a++,h=e[v][1]+h,v--),e[v]&&e[v][0]===n&&(s++,l=e[v][1]+l,v--),d=v}}if(m(e[o][1])){var y=e[o][1].charAt(0);e[o][1]=e[o][1].slice(1),l+=y,h+=y}}if(o<e.length-1&&!e[o][1]){e.splice(o,1);break}if(l.length>0||h.length>0){l.length>0&&h.length>0&&(p=u(h,l),0!==p&&(d>=0?e[d][1]+=h.substring(0,p):(e.splice(0,0,[i,h.substring(0,p)]),o++),h=h.substring(p),l=l.substring(p)),p=c(h,l),0!==p&&(e[o][1]=h.substring(h.length-p)+e[o][1],h=h.substring(0,h.length-p),l=l.substring(0,l.length-p)));var b=a+s;0===l.length&&0===h.length?(e.splice(o-b,b),o-=b):0===l.length?(e.splice(o-b,b,[r,h]),o=o-b+1):0===h.length?(e.splice(o-b,b,[n,l]),o=o-b+1):(e.splice(o-b,b,[n,l],[r,h]),o=o-b+2)}0!==o&&e[o-1][0]===i?(e[o-1][1]+=e[o][1],e.splice(o,1)):o++,a=0,s=0,l="",h=""}""===e[e.length-1][1]&&e.pop();var _=!1;for(o=1;o<e.length-1;)e[o-1][0]===i&&e[o+1][0]===i&&(e[o][1].substring(e[o][1].length-e[o-1][1].length)===e[o-1][1]?(e[o][1]=e[o-1][1]+e[o][1].substring(0,e[o][1].length-e[o-1][1].length),e[o+1][1]=e[o-1][1]+e[o+1][1],e.splice(o-1,1),_=!0):e[o][1].substring(0,e[o+1][1].length)==e[o+1][1]&&(e[o-1][1]+=e[o+1][1],e[o][1]=e[o][1].substring(e[o+1][1].length)+e[o+1][1],e.splice(o+1,1),_=!0)),o++;_&&f(e,t)}function p(e){return e>=55296&&e<=56319}function d(e){return e>=56320&&e<=57343}function m(e){return d(e.charCodeAt(0))}function g(e){return p(e.charCodeAt(e.length-1))}function y(e){for(var t=[],n=0;n<e.length;n++)e[n][1].length>0&&t.push(e[n]);return t}function v(e,t,o,s){return g(e)||m(s)?null:y([[i,e],[n,t],[r,o],[i,s]])}function b(e,t,n){var r="number"==typeof n?{index:n,length:0}:n.oldRange,i="number"==typeof n?null:n.newRange,o=e.length,s=t.length;if(0===r.length&&(null===i||0===i.length)){var a=r.index,l=e.slice(0,a),u=e.slice(a),c=i?i.index:null,h=a+s-o;if((null===c||c===h)&&!(h<0||h>s)){var f=t.slice(0,h),p=t.slice(h);if(p===u){var d=Math.min(a,h),m=l.slice(0,d),g=f.slice(0,d);if(m===g){var y=l.slice(d),b=f.slice(d);return v(m,y,b,u)}}}if(null===c||c===a){var _=a,f=t.slice(0,_),p=t.slice(_);if(f===l){var w=Math.min(o-_,s-_),k=u.slice(u.length-w),E=p.slice(p.length-w);if(k===E){var y=u.slice(0,u.length-w),b=p.slice(0,p.length-w);return v(l,y,b,k)}}}}if(r.length>0&&i&&0===i.length){var m=e.slice(0,r.index),k=e.slice(r.index+r.length),d=m.length,w=k.length;if(!(s<d+w)){var g=t.slice(0,d),E=t.slice(s-w);if(m===g&&k===E){var y=e.slice(d,o-w),b=t.slice(d,s-w);return v(m,y,b,k)}}}return null}function _(e,t,n){return o(e,t,n,!0)}_.INSERT=r,_.DELETE=n,_.EQUAL=i,e.exports=_},function(e,t,n){"use strict";function r(e){class t extends e.utils.CustomType{constructor(t,n,r,i){super(),this._model=n.id,this._parent=null,this._deepEventHandler=new e.utils.EventListenerHandler,this.os=t,this.map=e.utils.copyObject(n.map),this.contents=r,this.opContents=i,this.eventHandler=new e.utils.EventHandler(t=>{var n,r="Delete"===t.struct?t.key:t.parentSub;if(n=null!=this.opContents[r]?this.os.getType(this.opContents[r]):this.contents[r],"Insert"===t.struct){var i;if(null===t.left&&!e.utils.compareIds(t.id,this.map[r]))null!=t.opContent?(i=this.os.getType(t.opContent),i._parent=this._model,delete this.contents[r],t.deleted?delete this.opContents[r]:this.opContents[r]=t.opContent):(i=t.content[0],delete this.opContents[r],t.deleted?delete this.contents[r]:this.contents[r]=t.content[0]),this.map[r]=t.id,void 0===n?e.utils.bubbleEvent(this,{name:r,object:this,type:"add",value:i}):e.utils.bubbleEvent(this,{name:r,object:this,oldValue:n,type:"update",value:i})}else{if("Delete"!==t.struct)throw new Error("Unexpected Operation!");e.utils.compareIds(this.map[r],t.target)&&(delete this.opContents[r],delete this.contents[r],e.utils.bubbleEvent(this,{name:r,object:this,oldValue:n,type:"delete"}))}})}_getPathToChild(t){return Object.keys(this.opContents).find(n=>e.utils.compareIds(this.opContents[n],t))}_destroy(){this.eventHandler.destroy(),this.eventHandler=null,this.contents=null,this.opContents=null,this._model=null,this._parent=null,this.os=null,this.map=null}get(e){if(null==e||"string"!=typeof e)throw new Error("You must specify a key (as string)!");return null==this.opContents[e]?this.contents[e]:this.os.getType(this.opContents[e])}keys(){return Object.keys(this.contents).concat(Object.keys(this.opContents))}keysPrimitives(){return Object.keys(this.contents)}keysTypes(){return Object.keys(this.opContents)}getPrimitive(t){if(null==t)return e.utils.copyObject(this.contents);if("string"!=typeof t)throw new Error("Key is expected to be a string!");return this.contents[t]}getType(e){if(null==e||"string"!=typeof e)throw new Error("You must specify a key (as string)!");return null!=this.opContents[e]?this.os.getType(this.opContents[e]):null}delete(t){var n=this.map[t];if(null!=n){var r={target:n,struct:"Delete"},i=this.eventHandler,o=e.utils.copyObject(r);o.key=t,this.os.requestTransaction(function*(){yield*i.awaitOps(this,this.applyCreatedOperations,[[r]])}),i.awaitAndPrematurelyCall([o])}}set(t,n){var r=this.map[t]||null,i={id:this.os.getNextOpId(1),left:null,right:r,origin:null,parent:this._model,parentSub:t,struct:"Insert"},o=this.eventHandler,s=e.utils.isTypeDefinition(n);if(!1!==s){var a=this.os.createType(s);return i.opContent=a._model,this.os.requestTransaction(function*(){yield*o.awaitOps(this,this.applyCreatedOperations,[[i]])}),o.awaitAndPrematurelyCall([i]),a}return i.content=[n],this.os.requestTransaction(function*(){yield*o.awaitOps(this,this.applyCreatedOperations,[[i]])}),o.awaitAndPrematurelyCall([i]),n}observe(e){this.eventHandler.addEventListener(e)}observeDeep(e){this._deepEventHandler.addEventListener(e)}unobserve(e){this.eventHandler.removeEventListener(e)}unobserveDeep(e){this._deepEventHandler.removeEventListener(e)}observePath(n,r){var i=this,o;function s(e){e.name===o&&r(i.get(o))}if(n.length<1)return r(this),function(){};if(1===n.length)return o=n[0],r(i.get(o)),this.observe(s),function(){i.unobserve(r)};var a,l=function(){var o=i.get(n[0]);o instanceof t||(o=i.set(n[0],e.Map)),a=o.observePath(n.slice(1),r)},u=function(e){e.name===n[0]&&(null!=a&&a(),"add"!==e.type&&"update"!==e.type||l())};return i.observe(u),l(),function(){null!=a&&a(),i.unobserve(u)}}*_changed(e,t){if("Delete"===t.struct){if(null==t.key){var n=yield*e.getOperation(t.target);t.key=n.parentSub}}else null!=t.opContent&&(yield*e.store.initType.call(e,t.opContent));this.eventHandler.receivedOp(t)}}e.extend("Map",new e.utils.CustomTypeDefinition({name:"Map",class:t,struct:"Map",initType:function*e(n,r){var i={},o={},s=r.map;for(var a in s){var l=yield*this.getOperation(s[a]);if(!l.deleted)if(null!=l.opContent){o[a]=l.opContent;var u=yield*this.store.initType.call(this,l.opContent);u._parent=r.id}else i[a]=l.content[0]}return new t(n,r,i,o)},createType:function e(n,r){return new t(n,r,{},{})}}))}e.exports=r,"undefined"!=typeof Y&&r(Y)},function(e,t,n){"use strict";const r=n(1501)("y-ipfs-connector"),i=n(6),o=n(1503),s=n(106),a=n(5).Buffer,l=n(1514),u=n(1515);function c(e){class t extends e.AbstractConnector{constructor(e,t){if(void 0===t)throw new Error("Options must not be undefined!");if(null==t.room)throw new Error("You must define a room name!");if(!t.ipfs)throw new Error("You must define a started IPFS object inside options");t.role||(t.role="master"),super(e,t),this._yConnectorOptions=t,this.ipfs=t.ipfs;const n=this.ipfsPubSubTopic="y-ipfs:rooms:"+t.room;this.roomEmitter=t.roomEmitter||new i,this.roomEmitter.peers=(()=>this._room.getPeers()),this.roomEmitter.id=(()=>n),this._receiveQueue=s(this._processQueue.bind(this),1),this._room=o(this.ipfs,n),this._room.setMaxListeners(1/0),this._room.on("error",e=>{console.error(e)}),this._room.on("message",e=>{if(this.ipfs._peerInfo&&e.from===this.ipfs._peerInfo.id.toB58String())return;const n=()=>{let n;n=this._yConnectorOptions.decode?this._yConnectorOptions.decode(e.data):u(e.data);const r=()=>{const t=u(n.payload);this.roomEmitter.emit("received message",e.from,t),null!==t.type&&this._queueReceiveMessage(e.from,t)};if(t.verifySignature){const i=n.signature&&a.from(n.signature,"base64");t.verifySignature.call(null,e.from,a.from(n.payload),i,(t,n)=>{t?console.error("Error verifying signature from peer "+e.from+". Discarding message.",t):n?r():console.error("Invalid signature from peer "+e.from+". Discarding message.")})}else r()};if(this._room.hasPeer(e.from))n();else{const t=r=>{r===e.from&&(this._room.removeListener("peer joined",t),n())};this._room.on("peer joined",t)}}),this._room.on("peer joined",e=>{this.roomEmitter.emit("peer joined",e),this.userJoined(e,"master")}),this._room.on("peer left",e=>{this.roomEmitter.emit("peer left",e),this.userLeft(e)}),this.ipfs.isOnline()?this._start():this.ipfs.once("ready",this._start.bind(this))}_queueReceiveMessage(e,t){this._receiveQueue.push({from:e,message:t})}_processQueue(e,t){const n=e.from,r=e.message;n===this._ipfsUserId?t():this._room.hasPeer(n)?(this.receiveMessage(n,r),t()):(this._receiveQueue.unshift(e),setTimeout(t,500))}_start(){const e=this.ipfs._peerInfo.id.toB58String();this._ipfsUserId=e,this.setUserId(e)}disconnect(){r("disconnect"),this._room.leave(),super.disconnect()}send(e,t){this._encodeMessage(t,(n,r)=>{if(n)throw n;this._yConnectorOptions.encode&&(r=this._yConnectorOptions.encode(r)),this._room.sendTo(e,r),this.roomEmitter.emit("sent message",e,t)})}broadcast(e){this._encodeMessage(e,(t,n)=>{if(t)throw t;this._yConnectorOptions.encode&&(n=this._yConnectorOptions.encode(n)),this._room.broadcast(n),this.roomEmitter.emit("sent message","broadcast",e)})}isDisconnected(){return!1}_encodeMessage(e,t){const n=h(e);this._yConnectorOptions.sign?this._yConnectorOptions.sign(a.from(n),(e,r)=>{if(e)return t(e);const i=r.toString("base64");t(null,l({signature:i,payload:n}))}):t(null,l({payload:n}))}}e.extend("ipfs",t)}function h(e){return JSON.stringify(e)}e.exports=c,"undefined"!=typeof Y&&c(Y)},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1502)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t,n){"use strict";(function(t){const r=n(1504),i=n(6),o=n(1509),s=n(548),a=n(549),l=n(1511),u=n(550),c=n(1513),h=n(551),f={pollInterval:1e3};e.exports=((e,t,n)=>new p(e,t,n));class p extends i{constructor(e,t,n){if(super(),this._ipfs=e,this._topic=t,this._options=Object.assign({},s(f),s(n)),this._peers=[],this._connections={},this._handleDirectMessage=this._handleDirectMessage.bind(this),!this._ipfs.pubsub)throw new Error("This IPFS node does not have pubsub.");this._ipfs.isOnline()?this._start():this._ipfs.on("ready",this._start.bind(this)),this._ipfs.on("stop",this.leave.bind(this))}getPeers(){return this._peers.slice(0)}hasPeer(e){return this._peers.indexOf(e)>=0}leave(){return new Promise((e,t)=>{o.clearInterval(this._interval),Object.keys(this._connections).forEach(e=>{this._connections[e].stop()}),c.emitter.removeListener(this._topic,this._handleDirectMessage),this.once("stopped",()=>e()),this.emit("stopping")})}broadcast(e){let t=u(e);this._ipfs.pubsub.publish(this._topic,t,e=>{e&&this.emit("error",e)})}sendTo(e,n){let r=this._connections[e];r||(r=new l(e,this._ipfs,this),r.on("error",e=>this.emit("error",e)),this._connections[e]=r,r.once("disconnect",()=>{delete this._connections[e],this._peers=this._peers.filter(t=>t!==e),this.emit("peer left",e)}));const i=t.from([0]),o={to:e,from:this._ipfs._peerInfo.id.toB58String(),data:t.from(n).toString("hex"),seqno:i.toString("hex"),topicIDs:[this._topic],topicCIDs:[this._topic]};r.push(t.from(JSON.stringify(o)))}_start(){this._interval=o.setInterval(this._pollPeers.bind(this),this._options.pollInterval);const e=this._onMessage.bind(this);this._ipfs.pubsub.subscribe(this._topic,e,{},e=>{e?this.emit("error",e):this.emit("subscribed",this._topic)}),this.once("stopping",()=>{this._ipfs.pubsub.unsubscribe(this._topic,e,e=>{e?this.emit("error",e):this.emit("stopped")})}),h(this._ipfs).handle(a,c.handler),c.emitter.on(this._topic,this._handleDirectMessage)}_pollPeers(){this._ipfs.pubsub.peers(this._topic,(e,t)=>{if(e)return void this.emit("error",e);const n=t.sort();this._emitChanges(n)&&(this._peers=n)})}_emitChanges(e){const t=r(this._peers,e);return t.added.forEach(e=>this.emit("peer joined",e)),t.removed.forEach(e=>this.emit("peer left",e)),t.added.length>0||t.removed.length>0}_onMessage(e){this.emit("message",e)}_handleDirectMessage(e){if(e.to===this._ipfs._peerInfo.id.toB58String()){const t=Object.assign({},e);delete t.to,this.emit("message",t)}}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";const r=n(548),i=n(1505)("hyperdiff"),o=n(1508),s=e=>-1!==e;function a(){return{common:[],removed:[]}}function l(e,t,n){return n.every(n=>t[n]===e[n])}function u(e,t){return e.indexOf(t)}function c(e,t,n){return e.findIndex(function(e){return l(e,t,n)})}function h(e,t){return{first:e,second:r(t)}}function f(e,t){return t?c:u}function p(e,t,n){const r=n?[].concat(n):[],{first:a,second:l}=h(e,t),u=f(r,n);i("preconditions first=%j second=%j findIndex=%s",a,l,u.name);const c=a.reduce(function(e,t,n){const a=u(l,t,r),c=s(a)?"common":"removed";return e[c].push(t),o(l,a),i("index=%s value=%s collection=%s",n,t,c),e},{common:[],removed:[]});return c.added=l,i("added=%j removed=%j common%j",c.added,c.removed,c.common),c}e.exports=p},function(e,t,n){(function(r){function i(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function o(e){var n=this.useColors;if(e[0]=(n?"%c":"")+this.namespace+(n?" %c":" ")+e[0]+(n?"%c ":" ")+"+"+t.humanize(this.diff),n){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var i=0,o=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(i++,"%c"===e&&(o=i))}),e.splice(o,0,r)}}function s(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)}function a(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}}function l(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function u(){try{return window.localStorage}catch(e){}}t=e.exports=n(1506),t.log=s,t.formatArgs=o,t.save=a,t.load=l,t.useColors=i,t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:u(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(l())}).call(this,n(3))},function(e,t,n){function r(e){var n=0,r;for(r in e)n=(n<<5)-n+e.charCodeAt(r),n|=0;return t.colors[Math.abs(n)%t.colors.length]}function i(e){var n;function i(){if(i.enabled){var e=i,r=+new Date,o=r-(n||r);e.diff=o,e.prev=n,e.curr=r,n=r;for(var s=new Array(arguments.length),a=0;a<s.length;a++)s[a]=arguments[a];s[0]=t.coerce(s[0]),"string"!=typeof s[0]&&s.unshift("%O");var l=0;s[0]=s[0].replace(/%([a-zA-Z%])/g,function(n,r){if("%%"===n)return n;l++;var i=t.formatters[r];if("function"==typeof i){var o=s[l];n=i.call(e,o),s.splice(l,1),l--}return n}),t.formatArgs.call(e,s);var u=i.log||t.log||console.log.bind(console);u.apply(e,s)}}return i.namespace=e,i.enabled=t.enabled(e),i.useColors=t.useColors(),i.color=r(e),i.destroy=o,"function"==typeof t.init&&t.init(i),t.instances.push(i),i}function o(){var e=t.instances.indexOf(this);return-1!==e&&(t.instances.splice(e,1),!0)}function s(e){var n;t.save(e),t.names=[],t.skips=[];var r=("string"==typeof e?e:"").split(/[\s,]+/),i=r.length;for(n=0;n<i;n++)r[n]&&(e=r[n].replace(/\*/g,".*?"),"-"===e[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")));for(n=0;n<t.instances.length;n++){var o=t.instances[n];o.enabled=t.enabled(o.namespace)}}function a(){t.enable("")}function l(e){if("*"===e[e.length-1])return!0;var n,r;for(n=0,r=t.skips.length;n<r;n++)if(t.skips[n].test(e))return!1;for(n=0,r=t.names.length;n<r;n++)if(t.names[n].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}t=e.exports=i.debug=i.default=i,t.coerce=u,t.disable=a,t.enable=s,t.enabled=l,t.humanize=n(1507),t.instances=[],t.names=[],t.skips=[],t.formatters={}},function(e,t){var n=1e3,r=60*n,i=60*r,o=24*i,s=365.25*o;function a(e){if(e=String(e),!(e.length>100)){var t=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(e);if(t){var a=parseFloat(t[1]),l=(t[2]||"ms").toLowerCase();switch(l){case"years":case"year":case"yrs":case"yr":case"y":return a*s;case"days":case"day":case"d":return a*o;case"hours":case"hour":case"hrs":case"hr":case"h":return a*i;case"minutes":case"minute":case"mins":case"min":case"m":return a*r;case"seconds":case"second":case"secs":case"sec":case"s":return a*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return a;default:return}}}}function l(e){return e>=o?Math.round(e/o)+"d":e>=i?Math.round(e/i)+"h":e>=r?Math.round(e/r)+"m":e>=n?Math.round(e/n)+"s":e+"ms"}function u(e){return c(e,o,"day")||c(e,i,"hour")||c(e,r,"minute")||c(e,n,"second")||e+" ms"}function c(e,t,n){if(!(e<t))return e<1.5*t?Math.floor(e/t)+" "+n:Math.ceil(e/t)+" "+n+"s"}e.exports=function(e,t){t=t||{};var n=typeof e;if("string"===n&&e.length>0)return a(e);if("number"===n&&!1===isNaN(e))return t.long?u(e):l(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))}},function(e,t,n){(function(t){var n="Expected a function",r="__lodash_hash_undefined__",i=1/0,o=9007199254740991,s="[object Arguments]",a="[object Function]",l="[object GeneratorFunction]",u="[object Symbol]",c=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,h=/^\w*$/,f=/^\./,p=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,d=/[\\^$.*+?()[\]{}|]/g,m=/\\(\\)?/g,g=/^\[object .+?Constructor\]$/,y=/^(?:0|[1-9]\d*)$/,v="object"==typeof t&&t&&t.Object===Object&&t,b="object"==typeof self&&self&&self.Object===Object&&self,_=v||b||Function("return this")();function w(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function k(e,t){for(var n=-1,r=e?e.length:0,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function E(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function S(e,t){return null==e?void 0:e[t]}function x(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}var C=Array.prototype,A=Function.prototype,T=Object.prototype,I=_["__core-js_shared__"],j=(R=/[^.]+$/.exec(I&&I.keys&&I.keys.IE_PROTO||""),R?"Symbol(src)_1."+R:""),R,B=A.toString,O=T.hasOwnProperty,P=T.toString,N=RegExp("^"+B.call(O).replace(d,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),D=_.Symbol,M=T.propertyIsEnumerable,F=C.splice,L=D?D.isConcatSpreadable:void 0,U=Math.max,q=we(_,"Map"),z=we(Object,"create"),K=D?D.prototype:void 0,H=K?K.toString:void 0;function V(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function $(){this.__data__=z?z(null):{}}function W(e){return this.has(e)&&delete this.__data__[e]}function G(e){var t=this.__data__;if(z){var n=t[e];return n===r?void 0:n}return O.call(t,e)?t[e]:void 0}function Y(e){var t=this.__data__;return z?void 0!==t[e]:O.call(t,e)}function Z(e,t){var n=this.__data__;return n[e]=z&&void 0===t?r:t,this}function J(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Q(){this.__data__=[]}function X(e){var t=this.__data__,n=ue(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():F.call(t,n,1),!0}function ee(e){var t=this.__data__,n=ue(t,e);return n<0?void 0:t[n][1]}function te(e){return ue(this.__data__,e)>-1}function ne(e,t){var n=this.__data__,r=ue(n,e);return r<0?n.push([e,t]):n[r][1]=t,this}function re(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ie(){this.__data__={hash:new V,map:new(q||J),string:new V}}function oe(e){return _e(this,e).delete(e)}function se(e){return _e(this,e).get(e)}function ae(e){return _e(this,e).has(e)}function le(e,t){return _e(this,e).set(e,t),this}function ue(e,t){for(var n=e.length;n--;)if(Pe(e[n][0],t))return n;return-1}function ce(e,t){for(var n=-1,r=null==e,i=t.length,o=Array(i);++n<i;)o[n]=r?void 0:Ve(e,t[n]);return o}function he(e,t,n,r,i){var o=-1,s=e.length;for(n||(n=ke),i||(i=[]);++o<s;){var a=e[o];t>0&&n(a)?t>1?he(a,t-1,n,r,i):E(i,a):r||(i[i.length]=a)}return i}function fe(e,t){t=Se(t,e)?[t]:ve(t);for(var n=0,r=t.length;null!=e&&n<r;)e=e[Ie(t[n++])];return n&&n==r?e:void 0}function pe(e){if(!qe(e)||Ce(e))return!1;var t=Le(e)||x(e)?N:g;return t.test(je(e))}function de(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==o){var o=i;if(Ee(i))F.call(e,i,1);else if(Se(i,e))delete e[Ie(i)];else{var s=ve(i),a=Ae(e,s);null!=a&&delete a[Ie(Re(s))]}}}return e}function me(e,t){return t=U(void 0===t?e.length-1:t,0),function(){for(var n=arguments,r=-1,i=U(n.length-t,0),o=Array(i);++r<i;)o[r]=n[t+r];r=-1;for(var s=Array(t+1);++r<t;)s[r]=n[r];return s[t]=o,w(e,this,s)}}function ge(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),n=n>i?i:n,n<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=Array(i);++r<i;)o[r]=e[r+t];return o}function ye(e){if("string"==typeof e)return e;if(Ke(e))return H?H.call(e):"";var t=e+"";return"0"==t&&1/e==-i?"-0":t}function ve(e){return De(e)?e:Te(e)}function be(e,t){if(e!==t){var n=void 0!==e,r=null===e,i=e==e,o=Ke(e),s=void 0!==t,a=null===t,l=t==t,u=Ke(t);if(!a&&!u&&!o&&e>t||o&&s&&l&&!a&&!u||r&&s&&l||!n&&l||!i)return 1;if(!r&&!o&&!u&&e<t||u&&n&&i&&!r&&!o||a&&n&&i||!s&&i||!l)return-1}return 0}function _e(e,t){var n=e.__data__;return xe(t)?n["string"==typeof t?"string":"hash"]:n.map}function we(e,t){var n=S(e,t);return pe(n)?n:void 0}function ke(e){return De(e)||Ne(e)||!!(L&&e&&e[L])}function Ee(e,t){return t=null==t?o:t,!!t&&("number"==typeof e||y.test(e))&&e>-1&&e%1==0&&e<t}function Se(e,t){if(De(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Ke(e))||(h.test(e)||!c.test(e)||null!=t&&e in Object(t))}function xe(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}function Ce(e){return!!j&&j in e}function Ae(e,t){return 1==t.length?e:fe(e,ge(t,0,-1))}V.prototype.clear=$,V.prototype.delete=W,V.prototype.get=G,V.prototype.has=Y,V.prototype.set=Z,J.prototype.clear=Q,J.prototype.delete=X,J.prototype.get=ee,J.prototype.has=te,J.prototype.set=ne,re.prototype.clear=ie,re.prototype.delete=oe,re.prototype.get=se,re.prototype.has=ae,re.prototype.set=le;var Te=Oe(function(e){e=He(e);var t=[];return f.test(e)&&t.push(""),e.replace(p,function(e,n,r,i){t.push(r?i.replace(m,"$1"):n||e)}),t});function Ie(e){if("string"==typeof e||Ke(e))return e;var t=e+"";return"0"==t&&1/e==-i?"-0":t}function je(e){if(null!=e){try{return B.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Re(e){var t=e?e.length:0;return t?e[t-1]:void 0}var Be=me(function(e,t){t=he(t,1);var n=e?e.length:0,r=ce(e,t);return de(e,k(t,function(e){return Ee(e,n)?+e:e}).sort(be)),r});function Oe(e,t){if("function"!=typeof e||t&&"function"!=typeof t)throw new TypeError(n);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],o=r.cache;if(o.has(i))return o.get(i);var s=e.apply(this,n);return r.cache=o.set(i,s),s};return r.cache=new(Oe.Cache||re),r}function Pe(e,t){return e===t||e!=e&&t!=t}function Ne(e){return Fe(e)&&O.call(e,"callee")&&(!M.call(e,"callee")||P.call(e)==s)}Oe.Cache=re;var De=Array.isArray;function Me(e){return null!=e&&Ue(e.length)&&!Le(e)}function Fe(e){return ze(e)&&Me(e)}function Le(e){var t=qe(e)?P.call(e):"";return t==a||t==l}function Ue(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=o}function qe(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function ze(e){return!!e&&"object"==typeof e}function Ke(e){return"symbol"==typeof e||ze(e)&&P.call(e)==u}function He(e){return null==e?"":ye(e)}function Ve(e,t,n){var r=null==e?void 0:fe(e,t);return void 0===r?n:r}e.exports=Be}).call(this,n(8))},function(e,t,n){(function(e){var r=void 0!==e&&e||"undefined"!=typeof self&&self||window,i=Function.prototype.apply;function o(e,t){this._id=e,this._clearFn=t}t.setTimeout=function(){return new o(i.call(setTimeout,r,arguments),clearTimeout)},t.setInterval=function(){return new o(i.call(setInterval,r,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e&&e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(r,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function t(){e._onTimeout&&e._onTimeout()},t))},n(1510),t.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==e&&e.setImmediate||this&&this.setImmediate,t.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==e&&e.clearImmediate||this&&this.clearImmediate}).call(this,n(8))},function(e,t,n){(function(e,t){!function(e,n){"use strict";if(!e.setImmediate){var r=1,i={},o=!1,s=e.document,a,l=Object.getPrototypeOf&&Object.getPrototypeOf(e);l=l&&l.setTimeout?l:e,"[object process]"==={}.toString.call(e.process)?p():d()?m():e.MessageChannel?g():s&&"onreadystatechange"in s.createElement("script")?y():v(),l.setImmediate=u,l.clearImmediate=c}function u(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),n=0;n<t.length;n++)t[n]=arguments[n+1];var o={callback:e,args:t};return i[r]=o,a(r),r++}function c(e){delete i[e]}function h(e){var t=e.callback,r=e.args;switch(r.length){case 0:t();break;case 1:t(r[0]);break;case 2:t(r[0],r[1]);break;case 3:t(r[0],r[1],r[2]);break;default:t.apply(n,r)}}function f(e){if(o)setTimeout(f,0,e);else{var t=i[e];if(t){o=!0;try{h(t)}finally{c(e),o=!1}}}}function p(){a=function(e){t.nextTick(function(){f(e)})}}function d(){if(e.postMessage&&!e.importScripts){var t=!0,n=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=n,t}}function m(){var t="setImmediate$"+Math.random()+"$",n=function(n){n.source===e&&"string"==typeof n.data&&0===n.data.indexOf(t)&&f(+n.data.slice(t.length))};e.addEventListener?e.addEventListener("message",n,!1):e.attachEvent("onmessage",n),a=function(n){e.postMessage(t+n,"*")}}function g(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;f(t)},a=function(t){e.port2.postMessage(t)}}function y(){var e=s.documentElement;a=function(t){var n=s.createElement("script");n.onreadystatechange=function(){f(t),n.onreadystatechange=null,e.removeChild(n),n=null},e.appendChild(n)}}function v(){a=function(e){setTimeout(f,0,e)}}}("undefined"==typeof self?void 0===e?this:e:self)}).call(this,n(8),n(3))},function(e,t,n){"use strict";const r=n(6),i=n(19),o=n(63),s=n(549),a=n(550),l=n(1512),u=n(551);e.exports=class e extends r{constructor(e,t,n){super(),this._id=e,this._ipfs=t,this._room=n,this._connection=null,this._connecting=!1}push(e){this._connection?this._connection.push(a(e)):(this.once("connect",()=>this.push(e)),this._connecting||this._getConnection())}stop(){this._connection&&this._connection.end()}_getConnection(){this._connecting=!0,this._getPeerAddresses(this._id,(e,t)=>{e?this.emit("error",e):t.length?u(this._ipfs).dialProtocol(t[0],s,(e,t)=>{if(e)return void this.emit("disconnect");this._connecting=!1;const n=o();this._connection=n,i(n,t,i.onEnd(()=>{delete this._connection,this.emit("disconnect")})),this.emit("connect",n)}):this.emit("disconnect")})}_getPeerAddresses(e,t){this._ipfs.swarm.peers((n,r)=>{n?t(n):t(null,r.filter(t=>l(t.peer)===e).map(e=>e.peer))})}}},function(e,t,n){"use strict";e.exports=(e=>(e.id&&"function"==typeof e.id.toB58String&&(e=e.id),e.toB58String()))},function(e,t,n){"use strict";(function(r){const i=n(19),o=n(6),s=new o;function a(e,t){t.getPeerInfo((e,n)=>{if(e)return void console.log(e);const o=n.id.toB58String();i(t,i.map(e=>{let t;try{t=JSON.parse(e.toString())}catch(e){return void s.emit("warning",e.message)}if(o!==t.from)return void s.emit("warning","no peerid match "+t.from);const n=t.topicIDs;if(Array.isArray(n))return t.data=r.from(t.data,"hex"),t.seqno=r.from(t.seqno,"hex"),n.forEach(e=>{s.emit(e,t)}),t;s.emit("warning","no topic IDs")}),i.onEnd(()=>{}))})}t=e.exports={handler:a,emitter:s}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(t){e.exports=(e=>t.from(JSON.stringify(e)))}).call(this,n(0).Buffer)},function(e,t,n){"use strict";e.exports=(e=>{const t=e.toString();let n;try{n=JSON.parse(t)}catch(e){throw console.error("Failed parsing",t),e}return n})},function(e,t,n){"use strict";function r(e){return e?(e^16*Math.random()>>e/4).toString(16):([1e7]+-1e3+-4e3+-8e3+-1e11).replace(/[018]/g,r)}function i(e){e.requestModules(["memory"]).then(function(){class t{constructor(e,t){this.store=e.objectStore(t)}*find(e){return yield this.store.get(e)}*put(e){yield this.store.put(e)}*delete(e){yield this.store.delete(e)}*findWithLowerBound(e){return yield this.store.openCursor(IDBKeyRange.lowerBound(e))}*findWithUpperBound(e){return yield this.store.openCursor(IDBKeyRange.upperBound(e),"prev")}*findNext(e){return yield*this.findWithLowerBound([e[0],e[1]+1])}*findPrev(e){return yield*this.findWithUpperBound([e[0],e[1]-1])}*iterate(e,t,n,r){var i=null,o;for(null!=t&&null!=n?i=IDBKeyRange.bound(t,n):null!=t?i=IDBKeyRange.lowerBound(t):null!=n&&(i=IDBKeyRange.upperBound(n)),o=null!=i?this.store.openCursor(i):this.store.openCursor();null!=(yield o);)yield*r.call(e,o.result.value),o.result.continue()}*flush(){}}function n(e){class t extends e{constructor(){super(...arguments),this.buffer=[],this._copyTo=null}copyTo(e){return this._copyTo=e,this}*put(e,t){t||this.buffer.push(this._copyTo.put(e)),yield*super.put(e)}*delete(e){this.buffer.push(this._copyTo.delete(e)),yield*super.delete(e)}*flush(){yield*super.flush();for(var e=0;e<this.buffer.length;e++)yield*this.buffer[e];yield*this._copyTo.flush()}}return t}e.utils.createStoreClone=n;var i=e.utils.createSmallLookupBuffer(t);class o extends e.Transaction{constructor(e){super(e);var t=e.db.transaction(["OperationStore","StateStore","DeleteStore"],"readwrite");this.store=e,this.ss=new i(t,"StateStore"),this.os=new i(t,"OperationStore"),this.ds=new i(t,"DeleteStore")}}class s extends e.AbstractDatabase{constructor(t,n){if(null==n.gc&&(n.gc=!1),super(t,n),null==n&&(n={}),this.options=n,null==n.namespace){if(null==t.options.connector.room)throw new Error("IndexedDB: expect a string (options.namespace)! (you can also skip this step if your connector has a room property)");n.namespace=t.options.connector.room}null!=n.idbVersion?this.idbVersion=n.idbVersion:this.idbVersion=5;var i=this;this.requestTransaction(function*(){i.db=yield indexedDB.open(n.namespace,i.idbVersion)}),n.cleanStart&&("undefined"!=typeof localStorage&&delete localStorage[JSON.stringify(["Yjs_indexeddb",n.namespace])],this.requestTransaction(function*(){yield this.os.store.clear(),yield this.ds.store.clear(),yield this.ss.store.clear()})),this.whenUserIdSet(function(e){"undefined"!=typeof localStorage&&null==localStorage[JSON.stringify(["Yjs_indexeddb",n.namespace])]&&(localStorage[JSON.stringify(["Yjs_indexeddb",n.namespace])]=JSON.stringify([e,0]))}),this.requestTransaction(function*(){var e=null;if("undefined"!=typeof localStorage&&(e=localStorage[JSON.stringify(["Yjs_indexeddb",n.namespace])]),null!=e){if(i.setUserId(e),"undefined"!=typeof localStorage){var t=JSON.parse(e);t[1]=t[1]+1,localStorage[JSON.stringify(["Yjs_indexeddb",n.namespace])]=JSON.stringify(t)}}else setTimeout(function(){null==i.userId&&i.setUserId(r())},200)});var o=[];this.communicationObserver=function(t){o.push(t),1===o.length&&i.requestTransaction(function*(){for(var t=[],n=0;n<o.length;n++){var r=o[n];(null==r.parent||o.every(function(t){return!e.utils.compareIds(t.id,r.parent)}))&&t.push(r)}for(o=[],n=0;n<t.length;n++)yield*this.store.operationAdded(this,t[n],!0)})},e.utils.localCommunication.addObserver(this.options.namespace,this.communicationObserver)}*operationAdded(t,n,r){yield*super.operationAdded(t,n),r||e.utils.localCommunication.broadcast(this.options.namespace,n)}transact(e){var t=null!=this.db?new o(this):null,n=this,r=e.call(t);function i(s){var a=s.value;if(s.done)return e=n.getNextRequest(),void(null!=e&&(null==t&&null!=n.db&&(t=new o(n)),r=e.call(t),i(r.next())));a.constructor===IDBRequest?(a.onsuccess=function(){var e=a.result;null!=e&&e.constructor===IDBCursorWithValue&&(e=e.value),i(r.next(e))},a.onerror=function(e){r.throw(e)}):a.constructor===IDBCursor?(a.onsuccess=function(){i(r.next(null!=a.result?a.result.value:null))},a.onerror=function(e){r.throw(e)}):a.constructor===IDBOpenDBRequest?(a.onsuccess=function(e){var t=e.target.result;i(r.next(t))},a.onerror=function(){r.throw("Couldn't open IndexedDB database!")},a.onupgradeneeded=function(e){var t=e.target.result;"undefined"!=typeof localStorage&&delete localStorage[JSON.stringify(["Yjs_indexeddb",n.options.namespace])],t.objectStoreNames.contains("OperationStore")&&(t.deleteObjectStore("OperationStore"),t.deleteObjectStore("DeleteStore"),t.deleteObjectStore("StateStore")),t.createObjectStore("OperationStore",{keyPath:"id"}),t.createObjectStore("DeleteStore",{keyPath:"id"}),t.createObjectStore("StateStore",{keyPath:"id"})}):r.throw("You must not yield this type!")}i(r.next())}*destroy(){this.db.close()}deleteDB(){return e.utils.localCommunication.removeObserver(this.options.namespace,this.communicationObserver),indexedDB.deleteDatabase(this.options.namespace),Promise.resolve()}}null==e.utils.localCommunication&&(e.utils.localCommunication={observer:{},addObserver:function(e,t){var n=this.observer[e];null==n&&(n=[],this.observer[e]=n),n.push(t)},removeObserver:function(e,t){this.observer[e]=this.observer[e].filter(function(e){return t!==e})},broadcast:function(e,t){"undefined"!=typeof localStorage&&localStorage.setItem(JSON.stringify(["__YJS__",e]),JSON.stringify(t)),this.observer[e].map(function(e){e(t)})}},"undefined"!=typeof localStorage&&addEventListener("storage",function(t){var n;try{var r=JSON.parse(t.key);if("__YJS__"!==r[0])return;n=r[1]}catch(e){return}var i=e.utils.localCommunication.observer[n];null!=i&&i.map(function(e){e(JSON.parse(t.newValue))})})),e.extend("indexeddb",s)})}e.exports=i,"undefined"!=typeof Y&&i(Y)},function(e,t,n){(function(r){const i=n(1518),o=n(17),s=n(32),a=n(54),l=n(4)("dweb-transports:webtorrent"),u=n(77),c=n(111),h=n(94);let f={};class p extends c{constructor(e){super(e),this.webtorrent=void 0,this.options=e,this.name="WEBTORRENT",this.supportURLs=["magnet"],this.supportFunctions=["fetch","createReadStream","seed"],this.supportFeatures=["noCache"],this.status=c.STATUS_LOADED}p_webtorrentstart(){let e=this;return new Promise((e,t)=>{this.webtorrent=new i(this.options),this.webtorrent.once("ready",()=>{l("ready"),e()}),this.webtorrent.once("error",e=>t(e)),this.webtorrent.on("warning",e=>{console.warn("WebTorrent Torrent WARNING: "+e.message)})})}static setup0(e){let t=c.mergeoptions(f,e.webtorrent);l("setup0: options=%o",t);let n=new p(t);return h.addtransport(n),n}async p_setup1(e){try{this.status=c.STATUS_STARTING,e&&e(this),await this.p_webtorrentstart(),await this.p_status()}catch(e){console.error(this.name,"failed to connect",e.message),this.status=c.STATUS_FAILED}return e&&e(this),this}stop(e,t){this.webtorrent.destroy(n=>{this.status=c.STATUS_FAILED,e&&e(this),n?l("Webtorrent error during stopping %o",n):l("Webtorrent stopped"),t(n,this)})}async p_status(){return this.webtorrent&&this.webtorrent.ready?this.status=c.STATUS_CONNECTED:this.webtorrent?this.status=c.STATUS_STARTING:this.status=c.STATUS_FAILED,super.p_status()}webtorrentparseurl(e){if(!e)throw new u.CodingError("TransportWEBTORRENT.p_rawfetch: requires url");const t="string"==typeof e?e:e.href,n=t.indexOf("/");if(-1===n)throw new u.CodingError("TransportWEBTORRENT.p_rawfetch: invalid url - missing path component. Should look like magnet:xyzabc/path/to/file");const r=t.slice(0,n),i=t.slice(n+1);return{torrentId:r,path:i}}async p_webtorrentadd(e,t){return new Promise((n,r)=>{let i=this.webtorrent.get(e);i||(i=this.webtorrent.add(e,t),i.once("error",e=>{r(new u.TransportError("Torrent encountered a fatal error "+e.message))}),i.on("warning",e=>{console.warn("WebTorrent Torrent WARNING: "+e.message+" ("+i.name+")")})),i.ready?n(i):i.once("ready",()=>{n(i)})})}webtorrentfindfile(e,t){const n=e.name+"/"+t,r=e.files.find(e=>e.path===n);if(!r)throw new u.TransportError("Requested file ("+t+") not found within torrent ");return r}p_rawfetch(e){return new Promise((t,n)=>{const{torrentId:r,path:i}=this.webtorrentparseurl(e);this.p_webtorrentadd(r).then(e=>{e.deselect(0,e.pieces.length-1,!1);const r=this.webtorrentfindfile(e,i);r.getBuffer((r,i)=>{if(r)return n(new u.TransportError("Torrent encountered a fatal error "+r.message+" ("+e.name+")"));t(i)})}).catch(e=>n(e))})}seed({fileRelativePath:e,directoryPath:t,torrentRelativePath:n},r){if(n){const i=a.join(t,n);this.p_addTorrentFromTorrentFile(i,t).then(n=>{l("Added %s/%s to webtorrent",t,e),r(null)}).catch(n=>{n.message.includes("Cannot add duplicate torrent")?r(null):(l("addWebTorrent failed %s/%s",t,e),r(n))})}else r(null)}async _p_fileTorrentFromUrl(e){try{const{torrentId:t,path:n}=this.webtorrentparseurl(e),r=await this.p_webtorrentadd(t);r.deselect(0,r.pieces.length-1,!1);const i=this.webtorrentfindfile(r,n);return"undefined"!=typeof window&&(window.WEBTORRENT_TORRENT=r,window.WEBTORRENT_FILE=i,r.once("close",()=>{window.WEBTORRENT_TORRENT=null,window.WEBTORRENT_FILE=null})),i}catch(e){throw e}}async p_addTorrentFromTorrentFile(e,t){try{const n={path:t},r=this.webtorrent.get(e);if(r)r.rescanFiles();else{const t=await this.p_webtorrentadd(e,n);t.deselect(0,t.pieces.length-1,!1)}}catch(e){throw e}}async p_f_createReadStream(e,{wanturl:t=!1}={}){try{let n=await this._p_fileTorrentFromUrl(e),r=this;return t?e:function(e){return r.createReadStream(n,e)}}catch(e){throw e}}createReadStream(e,t){let n;l("reading from stream %s %o",e.name,t);try{n=new o.PassThrough;const r=e.createReadStream(t);return r.pipe(n),n}catch(e){l("createReadStream error %s",e),"function"==typeof n.destroy?n.destroy(e):n.emit("error",e)}}async p_createReadableStream(e,t){let n=await this._p_fileTorrentFromUrl(e);return new ReadableStream({start(r){l("start %s %o",e,t);const i=n.createReadStream(t);i.on("data",e=>{r.enqueue(e)}),i.on("end",()=>{r.close()})},cancel(n){throw new u.TransportError(`cancelled ${e}, ${t} ${n}`)}})}static async p_test(e){try{let n=await this.p_setup(e);console.log(n.name,"p_test setup",e,"complete");let i=await n.p_status();console.assert(i===c.STATUS_CONNECTED);let o="magnet:?xt=urn:btih:dd8255ecdc7ca55fb0bbf81323d87062db1f6d1c&dn=Big+Buck+Bunny&tr=udp%3A%2F%2Fexplodie.org%3A6969&tr=udp%3A%2F%2Ftracker.coppersurfer.tk%3A6969&tr=udp%3A%2F%2Ftracker.empire-js.us%3A1337&tr=udp%3A%2F%2Ftracker.leechers-paradise.org%3A6969&tr=udp%3A%2F%2Ftracker.opentrackr.org%3A1337&tr=wss%3A%2F%2Ftracker.btorrent.xyz&tr=wss%3A%2F%2Ftracker.fastcast.nz&tr=wss%3A%2F%2Ftracker.openwebtorrent.com&ws=https%3A%2F%2Fwebtorrent.io%2Ftorrents%2F&xs=https%3A%2F%2Fwebtorrent.io%2Ftorrents%2Fbig-buck-bunny.torrent/Big Buck Bunny.en.srt",s=await n.p_rawfetch(o);s=s.toString(),t(s);const a=await n.createReadStream(o),l=[];function t(e){let t="00:00:02,000 --\x3e 00:00:05,000";console.assert(-1!==e.indexOf(t),"Should fetch 'Big Buck Bunny.en.srt' from the torrent"),console.assert(e.length,129,"'Big Buck Bunny.en.srt' was "+e.length)}a.on("data",e=>{l.push(e)}),a.on("end",()=>{const e=r.concat(l).toString();t(e)})}catch(e){throw console.log("Exception thrown in",n.name,"p_test():",e.message),e}}}h._transportclasses.WEBTORRENT=p,t=e.exports=p}).call(this,n(0).Buffer)},function(e,t,n){(function(t,r){const{Buffer:i}=n(5),{EventEmitter:o}=n(6),s=n(552),a=n(1519),l=n(4)("webtorrent"),u=n(1545),c=n(1546),h=n(170),f=n(570),p=n(54),d=n(308),m=n(101),g=n(309),y=n(1557),v=n(1558),b=n(311).version,_=b.replace(/\d*./g,e=>`0${e%100}`.slice(-2)).slice(0,4),w=`-WW${_}-`;class k extends o{constructor(e={}){super(),"string"==typeof e.peerId?this.peerId=e.peerId:i.isBuffer(e.peerId)?this.peerId=e.peerId.toString("hex"):this.peerId=i.from(w+m(9).toString("base64")).toString("hex"),this.peerIdBuffer=i.from(this.peerId,"hex"),"string"==typeof e.nodeId?this.nodeId=e.nodeId:i.isBuffer(e.nodeId)?this.nodeId=e.nodeId.toString("hex"):this.nodeId=m(20).toString("hex"),this.nodeIdBuffer=i.from(this.nodeId,"hex"),this._debugId=this.peerId.toString("hex").substring(0,7),this.destroyed=!1,this.listening=!1,this.torrentPort=e.torrentPort||0,this.dhtPort=e.dhtPort||0,this.tracker=void 0!==e.tracker?e.tracker:{},this.torrents=[],this.maxConns=Number(e.maxConns)||55,this._debug("new webtorrent (peerId %s, nodeId %s, port %s)",this.peerId,this.nodeId,this.torrentPort),this.tracker&&("object"!=typeof this.tracker&&(this.tracker={}),e.rtcConfig&&(console.warn("WebTorrent: opts.rtcConfig is deprecated. Use opts.tracker.rtcConfig instead"),this.tracker.rtcConfig=e.rtcConfig),e.wrtc&&(console.warn("WebTorrent: opts.wrtc is deprecated. Use opts.tracker.wrtc instead"),this.tracker.wrtc=e.wrtc),t.WRTC&&!this.tracker.wrtc&&(this.tracker.wrtc=t.WRTC)),"function"==typeof y?this._tcpPool=new y(this):r.nextTick(()=>{this._onListening()}),this._downloadSpeed=g(),this._uploadSpeed=g(),!1!==e.dht&&"function"==typeof u?(this.dht=new u(Object.assign({},{nodeId:this.nodeId},e.dht)),this.dht.once("error",e=>{this._destroy(e)}),this.dht.once("listening",()=>{const e=this.dht.address();e&&(this.dhtPort=e.port)}),this.dht.setMaxListeners(0),this.dht.listen(this.dhtPort)):this.dht=!1,this.enableWebSeeds=!1!==e.webSeeds;const n=()=>{this.destroyed||(this.ready=!0,this.emit("ready"))};"function"==typeof c&&null!=e.blocklist?c(e.blocklist,{headers:{"user-agent":`WebTorrent/${b} (https://webtorrent.io)`}},(e,t)=>{if(e)return this.error(`Failed to load blocklist: ${e.message}`);this.blocked=t,n()}):r.nextTick(n)}get downloadSpeed(){return this._downloadSpeed()}get uploadSpeed(){return this._uploadSpeed()}get progress(){const e=this.torrents.filter(e=>1!==e.progress),t=e.reduce((e,t)=>e+t.downloaded,0),n=e.reduce((e,t)=>e+(t.length||0),0)||1;return t/n}get ratio(){const e=this.torrents.reduce((e,t)=>e+t.uploaded,0),t=this.torrents.reduce((e,t)=>e+t.received,0)||1;return e/t}get(e){if(e instanceof v){if(this.torrents.includes(e))return e}else{let t;try{t=f(e)}catch(e){}if(!t)return null;if(!t.infoHash)throw new Error("Invalid torrent identifier");for(const e of this.torrents)if(e.infoHash===t.infoHash)return e}return null}download(e,t,n){return console.warn("WebTorrent: client.download() is deprecated. Use client.add() instead"),this.add(e,t,n)}add(e,t={},n){if(this.destroyed)throw new Error("client is destroyed");"function"==typeof t&&([t,n]=[{},t]);const r=()=>{if(!this.destroyed)for(const e of this.torrents)if(e.infoHash===s.infoHash&&e!==s)return void s._destroy(new Error(`Cannot add duplicate torrent ${s.infoHash}`))},i=()=>{this.destroyed||("function"==typeof n&&n(s),this.emit("torrent",s))};function o(){s.removeListener("_infoHash",r),s.removeListener("ready",i),s.removeListener("close",o)}this._debug("add"),t=t?Object.assign({},t):{};const s=new v(e,this,t);return this.torrents.push(s),s.once("_infoHash",r),s.once("ready",i),s.once("close",o),s}seed(e,t,n){if(this.destroyed)throw new Error("client is destroyed");"function"==typeof t&&([t,n]=[{},t]),this._debug("seed"),t=t?Object.assign({},t):{},t.skipVerify=!0;const r="string"==typeof e;r&&(t.path=p.dirname(e)),t.createdBy||(t.createdBy=`WebTorrent/${_}`);const i=e=>{const t=[t=>{if(r)return t();e.load(u,t)}];this.dht&&t.push(t=>{e.once("dhtAnnounce",t)}),h(t,t=>{if(!this.destroyed)return t?e._destroy(t):void o(e)})},o=e=>{this._debug("on seed"),"function"==typeof n&&n(e),e.emit("seed"),this.emit("seed",e)},l=this.add(null,t,i);let u;return S(e)?e=Array.from(e):Array.isArray(e)||(e=[e]),h(e.map(e=>t=>{E(e)?s(e,t):t(null,e)}),(e,n)=>{if(!this.destroyed)return e?l._destroy(e):void a.parseInput(n,t,(e,r)=>{if(!this.destroyed){if(e)return l._destroy(e);u=r.map(e=>e.getStream),a(n,t,(e,t)=>{if(this.destroyed)return;if(e)return l._destroy(e);const n=this.get(t);n?l._destroy(new Error(`Cannot add duplicate torrent ${n.infoHash}`)):l._onTorrentId(t)})}})}),l}remove(e,t){this._debug("remove");const n=this.get(e);if(!n)throw new Error(`No torrent with id ${e}`);this._remove(e,t)}_remove(e,t){const n=this.get(e);n&&(this.torrents.splice(this.torrents.indexOf(n),1),n.destroy(t))}address(){return this.listening?this._tcpPool?this._tcpPool.server.address():{address:"0.0.0.0",family:"IPv4",port:0}:null}destroy(e){if(this.destroyed)throw new Error("client already destroyed");this._destroy(null,e)}_destroy(e,t){this._debug("client destroy"),this.destroyed=!0;const n=this.torrents.map(e=>t=>{e.destroy(t)});this._tcpPool&&n.push(e=>{this._tcpPool.destroy(e)}),this.dht&&n.push(e=>{this.dht.destroy(e)}),h(n,t),e&&this.emit("error",e),this.torrents=[],this._tcpPool=null,this.dht=null}_onListening(){if(this._debug("listening"),this.listening=!0,this._tcpPool){const e=this._tcpPool.server.address();e&&(this.torrentPort=e.port)}this.emit("listening")}_debug(){const e=[].slice.call(arguments);e[0]=`[${this._debugId}] ${e[0]}`,l(...e)}}function E(e){return"object"==typeof e&&null!=e&&"function"==typeof e.pipe}function S(e){return"undefined"!=typeof FileList&&e instanceof FileList}k.WEBRTC_SUPPORT=d.WEBRTC_SUPPORT,k.VERSION=b,e.exports=k}).call(this,n(8),n(3))},function(e,t,n){(function(t,r,i){const o=n(231),s=n(553),a=n(1528),l=n(54),u=n(1530),c=n(1536),h=n(16),f=n(1537),p=n(1538),d=n(564),m=n(26),g=n(170),y=n(171),v=n(17),b=[["udp://tracker.leechers-paradise.org:6969"],["udp://tracker.coppersurfer.tk:6969"],["udp://tracker.opentrackr.org:1337"],["udp://explodie.org:6969"],["udp://tracker.empire-js.us:1337"],["wss://tracker.btorrent.xyz"],["wss://tracker.openwebtorrent.com"],["wss://tracker.fastcast.nz"]];function _(e,t,n){"function"==typeof t&&([t,n]=[n,t]),t=t?Object.assign({},t):{},k(e,t,(e,r,i)=>{if(e)return n(e);t.singleFileTorrent=i,T(r,t,n)})}function w(e,t,n){"function"==typeof t&&([t,n]=[n,t]),t=t?Object.assign({},t):{},k(e,t,n)}function k(e,n,i){if(R(e)&&(e=Array.from(e)),Array.isArray(e)||(e=[e]),0===e.length)throw new Error("invalid input type");e.forEach(e=>{if(null==e)throw new Error(`invalid input type: ${e}`)}),e=e.map(e=>j(e)&&"string"==typeof e.path&&"function"==typeof h.stat?e.path:e),1!==e.length||"string"==typeof e[0]||e[0].name||(e[0].name=n.name);let o=null;e.forEach((t,n)=>{if("string"==typeof t)return;let r=t.fullPath||t.name;r||(r=`Unknown File ${n+1}`,t.unknownName=!0),t.path=r.split("/"),t.path[0]||t.path.shift(),t.path.length<2?o=null:0===n&&e.length>1?o=t.path[0]:t.path[0]!==o&&(o=null)}),e=e.filter(e=>{if("string"==typeof e)return!0;const t=e.path[e.path.length-1];return C(t)&&p.not(t)}),o&&e.forEach(e=>{const n=(t.isBuffer(e)||B(e))&&!e.path;"string"==typeof e||n||e.path.shift()}),!n.name&&o&&(n.name=o),n.name||e.some(e=>"string"==typeof e?(n.name=l.basename(e),!0):e.unknownName?void 0:(n.name=e.path[e.path.length-1],!0)),n.name||(n.name=`Unnamed Torrent ${Date.now()}`);const s=e.reduce((e,t)=>e+Number("string"==typeof t),0);let a=1===e.length;if(1===e.length&&"string"==typeof e[0]){if("function"!=typeof h.stat)throw new Error("filesystem paths do not work in the browser");f(e[0],(e,t)=>{if(e)return i(e);a=t,u()})}else r.nextTick(()=>{u()});function u(){g(e.map(e=>n=>{const r={};if(j(e))r.getStream=O(e),r.length=e.size;else if(t.isBuffer(e))r.getStream=P(e),r.length=e.length;else{if(!B(e)){if("string"==typeof e){if("function"!=typeof h.stat)throw new Error("filesystem paths do not work in the browser");const t=s>1||a;return void E(e,t,n)}throw new Error("invalid input type")}r.getStream=D(e,r),r.length=0}r.path=e.path,n(null,r)}),(e,t)=>{if(e)return i(e);t=c(t),i(null,t,a)})}}function E(e,t,n){x(e,S,(r,i)=>{if(r)return n(r);i=Array.isArray(i)?c(i):[i],e=l.normalize(e),t&&(e=e.slice(0,e.lastIndexOf(l.sep)+1)),e[e.length-1]!==l.sep&&(e+=l.sep),i.forEach(t=>{t.getStream=N(t.path),t.path=t.path.replace(e,"").split(l.sep)}),n(null,i)})}function S(e,t){t=m(t),h.stat(e,(n,r)=>{if(n)return t(n);const i={length:r.size,path:e};t(null,i)})}function x(e,t,n){h.stat(e,(r,i)=>{if(r)return n(r);i.isDirectory()?h.readdir(e,(r,i)=>{if(r)return n(r);g(i.filter(C).filter(p.not).map(n=>r=>{x(l.join(e,n),t,r)}),n)}):i.isFile()&&t(e,n)})}function C(e){return"."!==e[0]}function A(e,n,r){r=m(r);const i=[];let o=0;const a=e.map(e=>e.getStream);let l=0,u=0,c=!1;const h=new d(a),f=new s(n,{zeroPadding:!1});function p(e){o+=e.length;const t=u;y(e,e=>{i[t]=e,l-=1,_()}),l+=1,u+=1}function g(){c=!0,_()}function v(e){b(),r(e)}function b(){h.removeListener("error",v),f.removeListener("data",p),f.removeListener("end",g),f.removeListener("error",v)}function _(){c&&0===l&&(b(),r(null,t.from(i.join(""),"hex"),o))}h.on("error",v),h.pipe(f).on("data",p).on("end",g).on("error",v)}function T(t,n,r){let s=n.announceList;s||("string"==typeof n.announce?s=[[n.announce]]:Array.isArray(n.announce)&&(s=n.announce.map(e=>[e]))),s||(s=[]),i.WEBTORRENT_ANNOUNCE&&("string"==typeof i.WEBTORRENT_ANNOUNCE?s.push([[i.WEBTORRENT_ANNOUNCE]]):Array.isArray(i.WEBTORRENT_ANNOUNCE)&&(s=s.concat(i.WEBTORRENT_ANNOUNCE.map(e=>[e])))),void 0===n.announce&&void 0===n.announceList&&(s=s.concat(e.exports.announceList)),"string"==typeof n.urlList&&(n.urlList=[n.urlList]);const l={info:{name:n.name},"creation date":Math.ceil((Number(n.creationDate)||Date.now())/1e3),encoding:"UTF-8"};0!==s.length&&(l.announce=s[0][0],l["announce-list"]=s),void 0!==n.comment&&(l.comment=n.comment),void 0!==n.createdBy&&(l["created by"]=n.createdBy),void 0!==n.private&&(l.info.private=Number(n.private)),void 0!==n.sslCert&&(l.info["ssl-cert"]=n.sslCert),void 0!==n.urlList&&(l["url-list"]=n.urlList);const u=n.pieceLength||a(t.reduce(I,0));l.info["piece length"]=u,A(t,u,(e,i,s)=>{if(e)return r(e);l.info.pieces=i,t.forEach(e=>{delete e.getStream}),n.singleFileTorrent?l.info.length=s:l.info.files=t,r(null,o.encode(l))})}function I(e,t){return e+t.length}function j(e){return"undefined"!=typeof Blob&&e instanceof Blob}function R(e){return"undefined"!=typeof FileList&&e instanceof FileList}function B(e){return"object"==typeof e&&null!=e&&"function"==typeof e.pipe}function O(e){return()=>new u(e)}function P(e){return()=>{const t=new v.PassThrough;return t.end(e),t}}function N(e){return()=>h.createReadStream(e)}function D(e,t){return()=>{const n=new v.Transform;return n._transform=function(e,n,r){t.length+=e.length,this.push(e),r()},e.pipe(n),n}}e.exports=_,e.exports.parseInput=w,e.exports.announceList=b}).call(this,n(0).Buffer,n(3),n(8))},function(e,t,n){var r=n(5).Buffer;function i(e,t,n){var o=[],s=null;return i._encode(o,e),s=r.concat(o),i.bytes=s.length,r.isBuffer(t)?(s.copy(t,n),t):s}i.bytes=-1,i._floatConversionDetected=!1,i.getType=function(e){return r.isBuffer(e)?"buffer":Array.isArray(e)?"array":ArrayBuffer.isView(e)?"arraybufferview":e instanceof Number?"number":e instanceof Boolean?"boolean":e instanceof ArrayBuffer?"arraybuffer":typeof e},i._encode=function(e,t){if(null!=t)switch(i.getType(t)){case"buffer":i.buffer(e,t);break;case"object":i.dict(e,t);break;case"array":i.list(e,t);break;case"string":i.string(e,t);break;case"number":case"boolean":i.number(e,t);break;case"arraybufferview":i.buffer(e,r.from(t.buffer,t.byteOffset,t.byteLength));break;case"arraybuffer":i.buffer(e,r.from(t))}};var o=r.from("e"),s=r.from("d"),a=r.from("l");i.buffer=function(e,t){e.push(r.from(t.length+":"),t)},i.string=function(e,t){e.push(r.from(r.byteLength(t)+":"+t))},i.number=function(e,t){var n=2147483648,o=t/n<<0,s=t%n<<0,a=o*n+s;e.push(r.from("i"+a+"e")),a===t||i._floatConversionDetected||(i._floatConversionDetected=!0,console.warn('WARNING: Possible data corruption detected with value "'+t+'":','Bencoding only defines support for integers, value was converted to "'+a+'"'),console.trace())},i.dict=function(e,t){e.push(s);for(var n=0,r,a=Object.keys(t).sort(),l=a.length;n<l;n++)r=a[n],null!=t[r]&&(i.string(e,r),i._encode(e,t[r]));e.push(o)},i.list=function(e,t){var n=0,r=t.length;for(e.push(a);n<r;n++)null!=t[n]&&i._encode(e,t[n]);e.push(o)},e.exports=i},function(e,t,n){var r=n(5).Buffer;const i=105,o=58,s=100,a=108,l=101;function u(e,t,n){for(var r=0,i=1,o=t;o<n;o++){var s=e[o];if(s<58&&s>=48)r=10*r+(s-48);else if(o!==t||43!==s){if(o!==t||45!==s){if(46===s)break;throw new Error("not a number: buffer["+o+"] = "+s)}i=-1}}return r*i}function c(e,t,n,i){return null==e||0===e.length?null:("number"!=typeof t&&null==i&&(i=t,t=void 0),"number"!=typeof n&&null==i&&(i=n,n=void 0),c.position=0,c.encoding=i||null,c.data=r.isBuffer(e)?e.slice(t,n):r.from(e),c.bytes=c.data.length,c.next())}c.bytes=0,c.position=0,c.data=null,c.encoding=null,c.next=function(){switch(c.data[c.position]){case 100:return c.dictionary();case 108:return c.list();case 105:return c.integer();default:return c.buffer()}},c.find=function(e){for(var t=c.position,n=c.data.length,r=c.data;t<n;){if(r[t]===e)return t;t++}throw new Error('Invalid data: Missing delimiter "'+String.fromCharCode(e)+'" [0x'+e.toString(16)+"]")},c.dictionary=function(){c.position++;for(var e={};101!==c.data[c.position];)e[c.buffer()]=c.next();return c.position++,e},c.list=function(){c.position++;for(var e=[];101!==c.data[c.position];)e.push(c.next());return c.position++,e},c.integer=function(){var e=c.find(101),t=u(c.data,c.position+1,e);return c.position+=e+1-c.position,t},c.buffer=function(){var e=c.find(58),t=u(c.data,c.position,e),n=++e+t;return c.position=n,c.encoding?c.data.toString(c.encoding,e,n):c.data.slice(e,n)},e.exports=c},function(e,t,n){t=e.exports=n(554),t.Stream=t,t.Readable=t,t.Writable=n(557),t.Duplex=n(135),t.Transform=n(558),t.PassThrough=n(1526)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1525);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(558),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){e.exports=function(){for(var e=0;e<arguments.length;e++)if(void 0!==arguments[e])return arguments[e]}},function(e,t,n){for(var r=n(1529),i=Math.pow(2,10),o=13,s=[];o++<22;)s.push(Math.pow(2,o));e.exports=function(e){return r(e/i,s)}},function(e,t){var n=Math.abs;function r(e,t,r){for(var i,o,s,a=1/0,l=0,u=t.length-1;l<=u&&(i=l+(u-l>>1),s=t[i]-e,s<0?l=i+1:s>0&&(u=i-1),s=n(s),s<a&&(a=s,o=i),t[i]!==e););return r?o:t[o]}e.exports=r},function(e,t,n){var r=n(1531).Readable,i=n(1),o=/^.*\.(\w+)$/,s=n(502);function a(e,t){var n=this;if(!(this instanceof a))return new a(e,t);t=t||{},r.call(this,t),this._offset=0,this._ready=!1,this._file=e,this._size=e.size,this._chunkSize=t.chunkSize||Math.max(this._size/1e3,204800),this.reader=new FileReader,this._generateHeaderBlocks(e,t,function(e,t){if(e)return n.emit("error",e);Array.isArray(t)&&t.forEach(function(e){n.push(e)}),n._ready=!0,n.emit("_ready")})}i(a,r),e.exports=a,a.prototype._generateHeaderBlocks=function(e,t,n){n(null,[])},a.prototype._read=function(){if(this._ready){var e=this,t=this.reader,n=this._offset,r=this._offset+this._chunkSize;if(r>this._size&&(r=this._size),n===this._size)return this.destroy(),void this.push(null);t.onload=function(){e._offset=r,e.push(s(t.result))},t.onerror=function(){e.emit("error",t.error)},t.readAsArrayBuffer(this._file.slice(n,r))}else this.once("_ready",this._read.bind(this))},a.prototype.destroy=function(){if(this._file=null,this.reader){this.reader.onload=null,this.reader.onerror=null;try{this.reader.abort()}catch(e){}}this.reader=null}},function(e,t,n){t=e.exports=n(559),t.Stream=t,t.Readable=t,t.Writable=n(562),t.Duplex=n(136),t.Transform=n(563),t.PassThrough=n(1535)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1534);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(563),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){e.exports=function e(t,n){return n="number"==typeof n?n:1/0,n?r(t,1):Array.isArray(t)?t.map(function(e){return e}):t;function r(e,t){return e.reduce(function(e,i){return Array.isArray(i)&&t<n?e.concat(r(i,t+1)):e.concat(i)},[])}}},function(e,t,n){"use strict";var r=n(16);function i(e){return r.existsSync(e)&&r.statSync(e).isFile()}e.exports=function e(t,n){if(!n)return i(t);r.stat(t,function(e,t){return e?n(e):n(null,t.isFile())})},e.exports.sync=i},function(e,t,n){"use strict";t.regex=t.re=/^npm-debug\.log$|^\..*\.swp$|^\.DS_Store$|^\.AppleDouble$|^\.LSOverride$|^Icon\r$|^\._.*|^\.Spotlight-V100(?:$|\/)|\.Trashes|^__MACOSX$|~$|^Thumbs\.db$|^ehthumbs\.db$|^Desktop\.ini$|^@eaDir$/,t.is=(e=>t.re.test(e)),t.not=(e=>!t.is(e))},function(e,t,n){t=e.exports=n(565),t.Stream=t,t.Readable=t,t.Writable=n(568),t.Duplex=n(137),t.Transform=n(569),t.PassThrough=n(1543)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1542);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(569),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){!function t(n,r){e.exports=r()}("undefined"!=typeof self?self:this,function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function t(){return e.default}:function t(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=3)}([function(e,t,n){function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5),o=n(1),s=o.toHex,a=o.ceilHeapSize,l=n(6),u=function(e){for(e+=9;e%64>0;e+=1);return e},c=function(e,t){var n=new Uint8Array(e.buffer),r=t%4,i=t-r;switch(r){case 0:n[i+3]=0;case 1:n[i+2]=0;case 2:n[i+1]=0;case 3:n[i+0]=0}for(var o=1+(t>>2);o<e.length;o++)e[o]=0},h=function(e,t,n){e[t>>2]|=128<<24-(t%4<<3),e[14+(2+(t>>2)&-16)]=n/(1<<29)|0,e[15+(2+(t>>2)&-16)]=n<<3},f=function(e,t){var n=new Int32Array(e,t+320,5),r=new Int32Array(5),i=new DataView(r.buffer);return i.setInt32(0,n[0],!1),i.setInt32(4,n[1],!1),i.setInt32(8,n[2],!1),i.setInt32(12,n[3],!1),i.setInt32(16,n[4],!1),r},p=function(){function e(t){if(r(this,e),t=t||65536,t%64>0)throw new Error("Chunk size must be a multiple of 128 bit");this._offset=0,this._maxChunkLen=t,this._padMaxChunkLen=u(t),this._heap=new ArrayBuffer(a(this._padMaxChunkLen+320+20)),this._h32=new Int32Array(this._heap),this._h8=new Int8Array(this._heap),this._core=new i({Int32Array:Int32Array},{},this._heap)}return e.prototype._initState=function e(t,n){this._offset=0;var r=new Int32Array(t,n+320,5);r[0]=1732584193,r[1]=-271733879,r[2]=-1732584194,r[3]=271733878,r[4]=-1009589776},e.prototype._padChunk=function e(t,n){var r=u(t),i=new Int32Array(this._heap,0,r>>2);return c(i,t),h(i,t,n),r},e.prototype._write=function e(t,n,r,i){l(t,this._h8,this._h32,n,r,i||0)},e.prototype._coreCall=function e(t,n,r,i,o){var s=r;this._write(t,n,r),o&&(s=this._padChunk(r,i)),this._core.hash(s,this._padMaxChunkLen)},e.prototype.rawDigest=function e(t){var n=t.byteLength||t.length||t.size||0;this._initState(this._heap,this._padMaxChunkLen);var r=0,i=this._maxChunkLen;for(r=0;n>r+i;r+=i)this._coreCall(t,r,i,n,!1);return this._coreCall(t,r,n-r,n,!0),f(this._heap,this._padMaxChunkLen)},e.prototype.digest=function e(t){return s(this.rawDigest(t).buffer)},e.prototype.digestFromString=function e(t){return this.digest(t)},e.prototype.digestFromBuffer=function e(t){return this.digest(t)},e.prototype.digestFromArrayBuffer=function e(t){return this.digest(t)},e.prototype.resetState=function e(){return this._initState(this._heap,this._padMaxChunkLen),this},e.prototype.append=function e(t){var n=0,r=t.byteLength||t.length||t.size||0,i=this._offset%this._maxChunkLen,o=void 0;for(this._offset+=r;n<r;)o=Math.min(r-n,this._maxChunkLen-i),this._write(t,n,o,i),i+=o,n+=o,i===this._maxChunkLen&&(this._core.hash(this._maxChunkLen,this._padMaxChunkLen),i=0);return this},e.prototype.getState=function e(){var t=this._offset%this._maxChunkLen,n=void 0;if(t)n=this._heap.slice(0);else{var r=new Int32Array(this._heap,this._padMaxChunkLen+320,5);n=r.buffer.slice(r.byteOffset,r.byteOffset+r.byteLength)}return{offset:this._offset,heap:n}},e.prototype.setState=function e(t){if(this._offset=t.offset,20===t.heap.byteLength){var n=new Int32Array(this._heap,this._padMaxChunkLen+320,5);n.set(new Int32Array(t.heap))}else this._h32.set(new Int32Array(t.heap));return this},e.prototype.rawEnd=function e(){var t=this._offset,n=t%this._maxChunkLen,r=this._padChunk(n,t);this._core.hash(r,this._padMaxChunkLen);var i=f(this._heap,this._padMaxChunkLen);return this._initState(this._heap,this._padMaxChunkLen),i},e.prototype.end=function e(){return s(this.rawEnd().buffer)},e}();e.exports=p,e.exports._core=i},function(e,t){for(var n=new Array(256),r=0;r<256;r++)n[r]=(r<16?"0":"")+r.toString(16);e.exports.toHex=function(e){for(var t=new Uint8Array(e),r=new Array(e.byteLength),i=0;i<r.length;i++)r[i]=n[t[i]];return r.join("")},e.exports.ceilHeapSize=function(e){var t=0;if(e<=65536)return 65536;if(e<16777216)for(t=1;t<e;t<<=1);else for(t=16777216;t<e;t+=16777216);return t},e.exports.isDedicatedWorkerScope=function(e){var t="WorkerGlobalScope"in e&&e instanceof e.WorkerGlobalScope,n="SharedWorkerGlobalScope"in e&&e instanceof e.SharedWorkerGlobalScope,r="ServiceWorkerGlobalScope"in e&&e instanceof e.ServiceWorkerGlobalScope;return t&&!n&&!r}},function(e,t,n){e.exports=function(){var e=n(0),t=function(e,t,n){try{return n(null,e.digest(t))}catch(e){return n(e)}},r=function(e,t,n,i,o){var s=new self.FileReader;s.onloadend=function a(){if(s.error)return o(s.error);var l=s.result;t+=s.result.byteLength;try{e.append(l)}catch(e){return void o(e)}t<i.size?r(e,t,n,i,o):o(null,e.end())},s.readAsArrayBuffer(i.slice(t,t+n))},i=!0;return self.onmessage=function(n){if(i){var o=n.data.data,s=n.data.file,a=n.data.id;if(void 0!==a&&(s||o)){var l=n.data.blockSize||4194304,u=new e(l);u.resetState();var c=function(e,t){e?self.postMessage({id:a,error:e.name}):self.postMessage({id:a,hash:t})};o&&t(u,o,c),s&&r(u,0,l,s,c)}}},function(){i=!1}}},function(e,t,n){var r=n(4),i=n(0),o=n(7),s=n(2),a=n(1),l=a.isDedicatedWorkerScope,u="undefined"!=typeof self&&l(self);i.disableWorkerBehaviour=u?s():function(){},i.createWorker=function(){var e=r(2),t=e.terminate;return e.terminate=function(){URL.revokeObjectURL(e.objectURL),t.call(e)},e},i.createHash=o,e.exports=i},function(e,t,n){function r(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.r=function(e){Object.defineProperty(e,"__esModule",{value:!0})},n.n=function(e){var t=e&&e.__esModule?function t(){return e.default}:function t(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="/",n.oe=function(e){throw console.error(e),e};var r=n(n.s=ENTRY_MODULE);return r.default||r}var i="[\\.|\\-|\\+|\\w|/|@]+",o="\\((/\\*.*?\\*/)?s?.*?("+i+").*?\\)";function s(e){return(e+"").replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}function a(e,t,r){var a={};a[r]=[];var l=t.toString(),u=l.match(/^function\s?\(\w+,\s*\w+,\s*(\w+)\)/);if(!u)return a;for(var c=u[1],h=new RegExp("(\\\\n|\\W)"+s(c)+o,"g"),f;f=h.exec(l);)"dll-reference"!==f[3]&&a[r].push(f[3]);for(h=new RegExp("\\("+s(c)+'\\("(dll-reference\\s('+i+'))"\\)\\)'+o,"g");f=h.exec(l);)e[f[2]]||(a[r].push(f[1]),e[f[2]]=n(f[1]).m),a[f[2]]=a[f[2]]||[],a[f[2]].push(f[4]);return a}function l(e){var t=Object.keys(e);return t.reduce(function(t,n){return t||e[n].length>0},!1)}function u(e,t){for(var n={main:[t]},r={main:[]},i={main:{}};l(n);)for(var o=Object.keys(n),s=0;s<o.length;s++){var u=o[s],c=n[u],h=c.pop();if(i[u]=i[u]||{},!i[u][h]&&e[u][h]){i[u][h]=!0,r[u]=r[u]||[],r[u].push(h);for(var f=a(e,e[u][h],u),p=Object.keys(f),d=0;d<p.length;d++)n[p[d]]=n[p[d]]||[],n[p[d]]=n[p[d]].concat(f[p[d]])}}return r}e.exports=function(e,t){t=t||{};var i={main:n.m},o=t.all?{main:Object.keys(i)}:u(i,e),s="";Object.keys(o).filter(function(e){return"main"!==e}).forEach(function(e){for(var t=0;o[e][t];)t++;o[e].push(t),i[e][t]="(function(module, exports, __webpack_require__) { module.exports = __webpack_require__; })",s=s+"var "+e+" = ("+r.toString().replace("ENTRY_MODULE",JSON.stringify(t))+")({"+o[e].map(function(t){return JSON.stringify(t)+": "+i[e][t].toString()}).join(",")+"});\n"}),s=s+"("+r.toString().replace("ENTRY_MODULE",JSON.stringify(e))+")({"+o.main.map(function(e){return JSON.stringify(e)+": "+i.main[e].toString()}).join(",")+"})(self);";var a=new window.Blob([s],{type:"text/javascript"});if(t.bare)return a;var l=window.URL||window.webkitURL||window.mozURL||window.msURL,c=l.createObjectURL(a),h=new window.Worker(c);return h.objectURL=c,h}},function(e,t){e.exports=function e(t,n,r){"use asm";var i=new t.Int32Array(r);function o(e,t){e=e|0;t=t|0;var n=0,r=0,o=0,s=0,a=0,l=0,u=0,c=0,h=0,f=0,p=0,d=0,m=0,g=0;o=i[t+320>>2]|0;a=i[t+324>>2]|0;u=i[t+328>>2]|0;h=i[t+332>>2]|0;p=i[t+336>>2]|0;for(n=0;(n|0)<(e|0);n=n+64|0){s=o;l=a;c=u;f=h;d=p;for(r=0;(r|0)<64;r=r+4|0){g=i[n+r>>2]|0;m=((o<<5|o>>>27)+(a&u|~a&h)|0)+((g+p|0)+1518500249|0)|0;p=h;h=u;u=a<<30|a>>>2;a=o;o=m;i[e+r>>2]=g}for(r=e+64|0;(r|0)<(e+80|0);r=r+4|0){g=(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])<<1|(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])>>>31;m=((o<<5|o>>>27)+(a&u|~a&h)|0)+((g+p|0)+1518500249|0)|0;p=h;h=u;u=a<<30|a>>>2;a=o;o=m;i[r>>2]=g}for(r=e+80|0;(r|0)<(e+160|0);r=r+4|0){g=(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])<<1|(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])>>>31;m=((o<<5|o>>>27)+(a^u^h)|0)+((g+p|0)+1859775393|0)|0;p=h;h=u;u=a<<30|a>>>2;a=o;o=m;i[r>>2]=g}for(r=e+160|0;(r|0)<(e+240|0);r=r+4|0){g=(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])<<1|(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])>>>31;m=((o<<5|o>>>27)+(a&u|a&h|u&h)|0)+((g+p|0)-1894007588|0)|0;p=h;h=u;u=a<<30|a>>>2;a=o;o=m;i[r>>2]=g}for(r=e+240|0;(r|0)<(e+320|0);r=r+4|0){g=(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])<<1|(i[r-12>>2]^i[r-32>>2]^i[r-56>>2]^i[r-64>>2])>>>31;m=((o<<5|o>>>27)+(a^u^h)|0)+((g+p|0)-899497514|0)|0;p=h;h=u;u=a<<30|a>>>2;a=o;o=m;i[r>>2]=g}o=o+s|0;a=a+l|0;u=u+c|0;h=h+f|0;p=p+d|0}i[t+320>>2]=o;i[t+324>>2]=a;i[t+328>>2]=u;i[t+332>>2]=h;i[t+336>>2]=p}return{hash:o}}},function(e,t){var n=this,r=void 0;"undefined"!=typeof self&&void 0!==self.FileReaderSync&&(r=new self.FileReaderSync);var i=function(e,t,n,r,i,o){var s=void 0,a=o%4,l=(i+a)%4,u=i-l;switch(a){case 0:t[o]=e.charCodeAt(r+3);case 1:t[o+1-(a<<1)|0]=e.charCodeAt(r+2);case 2:t[o+2-(a<<1)|0]=e.charCodeAt(r+1);case 3:t[o+3-(a<<1)|0]=e.charCodeAt(r)}if(!(i<l+(4-a))){for(s=4-a;s<u;s=s+4|0)n[o+s>>2]=e.charCodeAt(r+s)<<24|e.charCodeAt(r+s+1)<<16|e.charCodeAt(r+s+2)<<8|e.charCodeAt(r+s+3);switch(l){case 3:t[o+u+1|0]=e.charCodeAt(r+u+2);case 2:t[o+u+2|0]=e.charCodeAt(r+u+1);case 1:t[o+u+3|0]=e.charCodeAt(r+u)}}},o=function(e,t,n,r,i,o){var s=void 0,a=o%4,l=(i+a)%4,u=i-l;switch(a){case 0:t[o]=e[r+3];case 1:t[o+1-(a<<1)|0]=e[r+2];case 2:t[o+2-(a<<1)|0]=e[r+1];case 3:t[o+3-(a<<1)|0]=e[r]}if(!(i<l+(4-a))){for(s=4-a;s<u;s=s+4|0)n[o+s>>2|0]=e[r+s]<<24|e[r+s+1]<<16|e[r+s+2]<<8|e[r+s+3];switch(l){case 3:t[o+u+1|0]=e[r+u+2];case 2:t[o+u+2|0]=e[r+u+1];case 1:t[o+u+3|0]=e[r+u]}}},s=function(e,t,n,i,o,s){var a=void 0,l=s%4,u=(o+l)%4,c=o-u,h=new Uint8Array(r.readAsArrayBuffer(e.slice(i,i+o)));switch(l){case 0:t[s]=h[3];case 1:t[s+1-(l<<1)|0]=h[2];case 2:t[s+2-(l<<1)|0]=h[1];case 3:t[s+3-(l<<1)|0]=h[0]}if(!(o<u+(4-l))){for(a=4-l;a<c;a=a+4|0)n[s+a>>2|0]=h[a]<<24|h[a+1]<<16|h[a+2]<<8|h[a+3];switch(u){case 3:t[s+c+1|0]=h[c+2];case 2:t[s+c+2|0]=h[c+1];case 1:t[s+c+3|0]=h[c]}}};e.exports=function(e,t,r,a,l,u){if("string"==typeof e)return i(e,t,r,a,l,u);if(e instanceof Array)return o(e,t,r,a,l,u);if(n&&n.Buffer&&n.Buffer.isBuffer(e))return o(e,t,r,a,l,u);if(e instanceof ArrayBuffer)return o(new Uint8Array(e),t,r,a,l,u);if(e.buffer instanceof ArrayBuffer)return o(new Uint8Array(e.buffer,e.byteOffset,e.byteLength),t,r,a,l,u);if(e instanceof Blob)return s(e,t,r,a,l,u);throw new Error("Unsupported data type.")}},function(e,t,n){function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(0),o=n(1),s=o.toHex,a=function(){function e(){r(this,e),this._rusha=new i,this._rusha.resetState()}return e.prototype.update=function e(t){return this._rusha.append(t),this},e.prototype.digest=function e(t){var e=this._rusha.rawEnd().buffer;if(!t)return e;if("hex"===t)return s(e);throw new Error("unsupported digest encoding")},e}();e.exports=function(){return new a}}])})},function(e,t){},function(e,t){},function(e,t,n){(function(t){e.exports=function e(n,r){if("undefined"==typeof Blob||!(n instanceof Blob))throw new Error("first argument must be a Blob");if("function"!=typeof r)throw new Error("second argument must be a function");var i=new FileReader;function o(e){i.removeEventListener("loadend",o,!1),e.error?r(e.error):r(null,t.from(i.result))}i.addEventListener("loadend",o,!1),i.readAsArrayBuffer(n)}}).call(this,n(0).Buffer)},function(e,t){},function(e,t,n){(function(t){e.exports=o,e.exports.decode=o,e.exports.encode=s;const r=n(1550),i=n(232);function o(e){const n={},o=e.split("magnet:?")[1],s=o&&o.length>=0?o.split("&"):[];let a;if(s.forEach(e=>{const t=e.split("=");if(2!==t.length)return;const r=t[0];let i=t[1];if("dn"===r&&(i=decodeURIComponent(i).replace(/\+/g," ")),"tr"!==r&&"xs"!==r&&"as"!==r&&"ws"!==r||(i=decodeURIComponent(i)),"kt"===r&&(i=decodeURIComponent(i).split("+")),"ix"===r&&(i=Number(i)),n[r])if(Array.isArray(n[r]))n[r].push(i);else{const e=n[r];n[r]=[e,i]}else n[r]=i}),n.xt){const e=Array.isArray(n.xt)?n.xt:[n.xt];e.forEach(e=>{if(a=e.match(/^urn:btih:(.{40})/))n.infoHash=a[1].toLowerCase();else if(a=e.match(/^urn:btih:(.{32})/)){const e=r.decode(a[1]);n.infoHash=t.from(e,"binary").toString("hex")}})}return n.infoHash&&(n.infoHashBuffer=t.from(n.infoHash,"hex")),n.dn&&(n.name=n.dn),n.kt&&(n.keywords=n.kt),"string"==typeof n.tr?n.announce=[n.tr]:Array.isArray(n.tr)?n.announce=n.tr:n.announce=[],n.urlList=[],("string"==typeof n.as||Array.isArray(n.as))&&(n.urlList=n.urlList.concat(n.as)),("string"==typeof n.ws||Array.isArray(n.ws))&&(n.urlList=n.urlList.concat(n.ws)),i(n.announce),i(n.urlList),n}function s(e){e=Object.assign({},e),e.infoHashBuffer&&(e.xt=`urn:btih:${e.infoHashBuffer.toString("hex")}`),e.infoHash&&(e.xt=`urn:btih:${e.infoHash}`),e.name&&(e.dn=e.name),e.keywords&&(e.kt=e.keywords),e.announce&&(e.tr=e.announce),e.urlList&&(e.ws=e.urlList,delete e.as);let t="magnet:?";return Object.keys(e).filter(e=>2===e.length).forEach((n,r)=>{const i=Array.isArray(e[n])?e[n]:[e[n]];i.forEach((e,i)=>{!(r>0||i>0)||"kt"===n&&0!==i||(t+="&"),"dn"===n&&(e=encodeURIComponent(e).replace(/%20/g,"+")),"tr"!==n&&"xs"!==n&&"as"!==n&&"ws"!==n||(e=encodeURIComponent(e)),"kt"===n&&(e=encodeURIComponent(e)),t+="kt"===n&&i>0?`+${e}`:`${n}=${e}`})}),t}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(1551);t.encode=r.encode,t.decode=r.decode},function(e,t,n){"use strict";(function(e){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZ234567",r=[255,255,26,27,28,29,30,31,255,255,255,255,255,255,255,255,255,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,255,255,255,255,255,255,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,255,255,255,255,255];function i(e){var t=Math.floor(e.length/5);return e.length%5==0?t:t+1}t.encode=function(t){e.isBuffer(t)||(t=new e(t));for(var r=0,o=0,s=0,a=0,l=new e(8*i(t));r<t.length;){var u=t[r];s>3?(a=u&255>>s,s=(s+5)%8,a=a<<s|(r+1<t.length?t[r+1]:0)>>8-s,r++):(a=u>>8-(s+5)&31,s=(s+5)%8,0===s&&r++),l[o]=n.charCodeAt(a),o++}for(r=o;r<l.length;r++)l[r]=61;return l},t.decode=function(t){var n=0,i=0,o,s=0;e.isBuffer(t)||(t=new e(t));for(var a=new e(Math.ceil(5*t.length/8)),l=0;l<t.length&&61!==t[l];l++){var u=t[l]-48;if(!(u<r.length))throw new Error("Invalid input - it is not base32 encoded string");i=r[u],n<=3?(n=(n+5)%8,0===n?(o|=i,a[s]=o,s++,o=0):o|=255&i<<8-n):(n=(n+5)%8,o|=255&i>>>n,a[s]=o,s++,o=255&i<<8-n)}return a.slice(0,s)}}).call(this,n(0).Buffer)},function(e,t,n){t=e.exports=n(571),t.Stream=t,t.Readable=t,t.Writable=n(574),t.Duplex=n(138),t.Transform=n(575),t.PassThrough=n(1556)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1555);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(575),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){},function(e,t,n){(function(t,r){const i=n(1559),o=n(233),s=n(1560),a=n(4)("webtorrent:torrent"),l=n(1566),u=n(6).EventEmitter,c=n(16),h=n(1585),f=n(307),p=n(1586),d=n(564),m=n(1587),g=n(1588),y=n(170),v=n(1589),b=n(570),_=n(54),w=n(1590),k=n(53),E=n(1591),S=n(171),x=n(309),C=n(232),A=n(1592),T=n(1595),I=n(1596),j=n(1597),R=n(1619),B=n(1628),O=n(1629),P=131072,N=3e4,D=5e3,M=3*w.BLOCK_LENGTH,F=.5,L=1,U=1e4,q=2,z=t.browser?1/0:2,K=[1e3,5e3,15e3],H=n(311).version,V=`WebTorrent/${H} (https://webtorrent.io)`;let $;try{$=_.join(c.statSync("/tmp")&&"/tmp","webtorrent")}catch(e){$=_.join("function"==typeof g.tmpdir?g.tmpdir():"/","webtorrent")}class W extends u{constructor(e,t,n){super(),this._debugId="unknown infohash",this.client=t,this.announce=n.announce,this.urlList=n.urlList,this.path=n.path,this.skipVerify=!!n.skipVerify,this._store=n.store||h,this._getAnnounceOpts=n.getAnnounceOpts,this.strategy=n.strategy||"sequential",this.maxWebConns=n.maxWebConns||4,this._rechokeNumSlots=!1===n.uploads||0===n.uploads?0:+n.uploads||10,this._rechokeOptimisticWire=null,this._rechokeOptimisticTime=0,this._rechokeIntervalId=null,this.ready=!1,this.destroyed=!1,this.paused=!1,this.done=!1,this.metadata=null,this.store=null,this.files=[],this.pieces=[],this._amInterested=!1,this._selections=[],this._critical=[],this.wires=[],this._queue=[],this._peers={},this._peersLength=0,this.received=0,this.uploaded=0,this._downloadSpeed=x(),this._uploadSpeed=x(),this._servers=[],this._xsRequests=[],this._fileModtimes=n.fileModtimes,null!==e&&this._onTorrentId(e),this._debug("new torrent")}get timeRemaining(){return this.done?0:0===this.downloadSpeed?1/0:(this.length-this.downloaded)/this.downloadSpeed*1e3}get downloaded(){if(!this.bitfield)return 0;let e=0;for(let t=0,n=this.pieces.length;t<n;++t)if(this.bitfield.get(t))e+=t===n-1?this.lastPieceLength:this.pieceLength;else{const n=this.pieces[t];e+=n.length-n.missing}return e}get downloadSpeed(){return this._downloadSpeed()}get uploadSpeed(){return this._uploadSpeed()}get progress(){return this.length?this.downloaded/this.length:0}get ratio(){return this.uploaded/(this.received||1)}get numPeers(){return this.wires.length}get torrentFileBlobURL(){if("undefined"==typeof window)throw new Error("browser-only property");return this.torrentFile?URL.createObjectURL(new Blob([this.torrentFile],{type:"application/x-bittorrent"})):null}get _numQueued(){return this._queue.length+(this._peersLength-this._numConns)}get _numConns(){let e=0;for(const t in this._peers)this._peers[t].connected&&(e+=1);return e}get swarm(){return console.warn("WebTorrent: `torrent.swarm` is deprecated. Use `torrent` directly instead."),this}_onTorrentId(e){if(this.destroyed)return;let n;try{n=b(e)}catch(e){}n?(this.infoHash=n.infoHash,this._debugId=n.infoHash.toString("hex").substring(0,7),t.nextTick(()=>{this.destroyed||this._onParsedTorrent(n)})):b.remote(e,(e,t)=>{if(!this.destroyed)return e?this._destroy(e):void this._onParsedTorrent(t)})}_onParsedTorrent(e){if(!this.destroyed){if(this._processParsedTorrent(e),!this.infoHash)return this._destroy(new Error("Malformed torrent data: No info hash"));this.path||(this.path=_.join($,this.infoHash)),this._rechokeIntervalId=setInterval(()=>{this._rechoke()},U),this._rechokeIntervalId.unref&&this._rechokeIntervalId.unref(),this.emit("_infoHash",this.infoHash),this.destroyed||(this.emit("infoHash",this.infoHash),this.destroyed||(this.client.listening?this._onListening():this.client.once("listening",()=>{this._onListening()})))}}_processParsedTorrent(e){this._debugId=e.infoHash.toString("hex").substring(0,7),this.announce&&(e.announce=e.announce.concat(this.announce)),this.client.tracker&&r.WEBTORRENT_ANNOUNCE&&!this.private&&(e.announce=e.announce.concat(r.WEBTORRENT_ANNOUNCE)),this.urlList&&(e.urlList=e.urlList.concat(this.urlList)),C(e.announce),C(e.urlList),Object.assign(this,e),this.magnetURI=b.toMagnetURI(e),this.torrentFile=b.toTorrentFile(e)}_onListening(){if(this.discovery||this.destroyed)return;let e=this.client.tracker;e&&(e=Object.assign({},this.client.tracker,{getAnnounceOpts:()=>{const e={uploaded:this.uploaded,downloaded:this.downloaded,left:Math.max(this.length-this.downloaded,0)};return this.client.tracker.getAnnounceOpts&&Object.assign(e,this.client.tracker.getAnnounceOpts()),this._getAnnounceOpts&&Object.assign(e,this._getAnnounceOpts()),e}})),this.discovery=new l({infoHash:this.infoHash,announce:this.announce,peerId:this.client.peerId,dht:!this.private&&this.client.dht,tracker:e,port:this.client.torrentPort,userAgent:V}),this.discovery.on("error",e=>{this._destroy(e)}),this.discovery.on("peer",e=>{"string"==typeof e&&this.done||this.addPeer(e)}),this.discovery.on("trackerAnnounce",()=>{this.emit("trackerAnnounce"),0===this.numPeers&&this.emit("noPeers","tracker")}),this.discovery.on("dhtAnnounce",()=>{this.emit("dhtAnnounce"),0===this.numPeers&&this.emit("noPeers","dht")}),this.discovery.on("warning",e=>{this.emit("warning",e)}),this.info?this._onMetadata(this):this.xs&&this._getMetadataFromServer()}_getMetadataFromServer(){const e=this,t=Array.isArray(this.xs)?this.xs:[this.xs],n=t.map(e=>t=>{r(e,t)});function r(t,n){if(0!==t.indexOf("http://")&&0!==t.indexOf("https://"))return e.emit("warning",new Error(`skipping non-http xs param: ${t}`)),n(null);const r={url:t,method:"GET",headers:{"user-agent":V}};let i;try{i=f.concat(r,o)}catch(r){return e.emit("warning",new Error(`skipping invalid url xs param: ${t}`)),n(null)}function o(r,i,o){if(e.destroyed)return n(null);if(e.metadata)return n(null);if(r)return e.emit("warning",new Error(`http error from xs param: ${t}`)),n(null);if(200!==i.statusCode)return e.emit("warning",new Error(`non-200 status code ${i.statusCode} from xs param: ${t}`)),n(null);let s;try{s=b(o)}catch(r){}return s?s.infoHash!==e.infoHash?(e.emit("warning",new Error(`got torrent file with incorrect info hash from xs param: ${t}`)),n(null)):(e._onMetadata(s),void n(null)):(e.emit("warning",new Error(`got invalid torrent file from xs param: ${t}`)),n(null))}e._xsRequests.push(i)}y(n)}_onMetadata(e){if(this.metadata||this.destroyed)return;let t;if(this._debug("got metadata"),this._xsRequests.forEach(e=>{e.abort()}),this._xsRequests=[],e&&e.infoHash)t=e;else try{t=b(e)}catch(e){return this._destroy(e)}if(this._processParsedTorrent(t),this.metadata=this.torrentFile,this.client.enableWebSeeds&&this.urlList.forEach(e=>{this.addWebSeed(e)}),this._rarityMap=new B(this),this.store=new p(new this._store(this.pieceLength,{torrent:{infoHash:this.infoHash},files:this.files.map(e=>({path:_.join(this.path,e.path),length:e.length,offset:e.offset})),length:this.length,name:this.infoHash})),this.files=this.files.map(e=>new j(this,e)),this.so){const e=I.parse(this.so);this.files.forEach((t,n)=>{e.includes(n)&&this.files[n].select(!0)})}else 0!==this.pieces.length&&this.select(0,this.pieces.length-1,!1);this._hashes=this.pieces,this.pieces=this.pieces.map((e,t)=>{const n=t===this.pieces.length-1?this.lastPieceLength:this.pieceLength;return new w(n)}),this._reservations=this.pieces.map(()=>[]),this.bitfield=new o(this.pieces.length),this.wires.forEach(e=>{e.ut_metadata&&e.ut_metadata.setMetadata(this.metadata),this._onWireWithMetadata(e)});const n=e=>{if(e)return this._destroy(e);this._debug("done verifying"),this._onStore()};this.skipVerify?(this._markAllVerified(),this._onStore()):(this._debug("verifying existing torrent data"),this._fileModtimes&&this._store===h?this.getFileModtimes((e,t)=>{if(e)return this._destroy(e);const r=this.files.map((e,n)=>t[n]===this._fileModtimes[n]).every(e=>e);r?(this._markAllVerified(),this._onStore()):this._verifyPieces(n)}):this._verifyPieces(n)),this.emit("metadata")}getFileModtimes(e){const t=[];v(this.files.map((e,n)=>r=>{c.stat(_.join(this.path,e.path),(e,i)=>{if(e&&"ENOENT"!==e.code)return r(e);t[n]=i&&i.mtime.getTime(),r(null)})}),z,n=>{this._debug("done getting file modtimes"),e(n,t)})}_verifyPieces(e){v(this.pieces.map((e,n)=>r=>this.destroyed?r(new Error("torrent is destroyed")):e?void this.store.get(n,(e,i)=>this.destroyed?r(new Error("torrent is destroyed")):e?t.nextTick(r,null):void S(i,e=>{if(this.destroyed)return r(new Error("torrent is destroyed"));if(e===this._hashes[n]){if(!this.pieces[n])return;this._debug("piece verified %s",n),this._markVerified(n)}else this._debug("piece invalid %s",n);r(null)})):r(null)),z,e)}rescanFiles(e){e||(e=J),this._verifyPieces(t=>{if(t)return e(t);this._checkDone(),e(null)})}_markAllVerified(){for(let e=0;e<this.pieces.length;e++)this._markVerified(e)}_markVerified(e){this.pieces[e]=null,this._reservations[e]=null,this.bitfield.set(e,!0)}_onStore(){this.destroyed||(this._debug("on store"),this.ready=!0,this.emit("ready"),this._checkDone(),this._updateSelections())}destroy(e){this._destroy(null,e)}_destroy(e,t){if(this.destroyed)return;this.destroyed=!0,this._debug("destroy"),this.client._remove(this),clearInterval(this._rechokeIntervalId),this._xsRequests.forEach(e=>{e.abort()}),this._rarityMap&&this._rarityMap.destroy();for(const e in this._peers)this.removePeer(e);this.files.forEach(e=>{e instanceof j&&e._destroy()});const n=this._servers.map(e=>t=>{e.destroy(t)});this.discovery&&n.push(e=>{this.discovery.destroy(e)}),this.store&&n.push(e=>{this.store.close(e)}),y(n,t),e&&(0===this.listenerCount("error")?this.client.emit("error",e):this.emit("error",e)),this.emit("close"),this.client=null,this.files=[],this.discovery=null,this.store=null,this._rarityMap=null,this._peers=null,this._servers=null,this._xsRequests=null}addPeer(e){if(this.destroyed)throw new Error("torrent is destroyed");if(!this.infoHash)throw new Error("addPeer() must not be called before the `infoHash` event");if(this.client.blocked){let t;if("string"==typeof e){let n;try{n=i(e)}catch(t){return this._debug("ignoring peer: invalid %s",e),this.emit("invalidPeer",e),!1}t=n[0]}else"string"==typeof e.remoteAddress&&(t=e.remoteAddress);if(t&&this.client.blocked.contains(t))return this._debug("ignoring peer: blocked %s",e),"string"!=typeof e&&e.destroy(),this.emit("blockedPeer",e),!1}const t=!!this._addPeer(e);return t?this.emit("peer",e):this.emit("invalidPeer",e),t}_addPeer(e){if(this.destroyed)return"string"!=typeof e&&e.destroy(),null;if("string"==typeof e&&!this._validAddr(e))return this._debug("ignoring peer: invalid %s",e),null;const t=e&&e.id||e;if(this._peers[t])return this._debug("ignoring peer: duplicate (%s)",t),"string"!=typeof e&&e.destroy(),null;if(this.paused)return this._debug("ignoring peer: torrent is paused"),"string"!=typeof e&&e.destroy(),null;let n;return this._debug("add peer %s",t),n="string"==typeof e?R.createTCPOutgoingPeer(e,this):R.createWebRTCPeer(e,this),this._peers[n.id]=n,this._peersLength+=1,"string"==typeof e&&(this._queue.push(n),this._drain()),n}addWebSeed(e){if(this.destroyed)throw new Error("torrent is destroyed");if(!/^https?:\/\/.+/.test(e))return this.emit("warning",new Error(`ignoring invalid web seed: ${e}`)),void this.emit("invalidPeer",e);if(this._peers[e])return this.emit("warning",new Error(`ignoring duplicate web seed: ${e}`)),void this.emit("invalidPeer",e);this._debug("add web seed %s",e);const t=R.createWebSeedPeer(e,this);this._peers[t.id]=t,this._peersLength+=1,this.emit("peer",e)}_addIncomingPeer(e){return this.destroyed?e.destroy(new Error("torrent is destroyed")):this.paused?e.destroy(new Error("torrent is paused")):(this._debug("add incoming peer %s",e.id),this._peers[e.id]=e,void(this._peersLength+=1))}removePeer(e){const t=e&&e.id||e;e=this._peers[t],e&&(this._debug("removePeer %s",t),delete this._peers[t],this._peersLength-=1,e.destroy(),this._drain())}select(e,t,n,r){if(this.destroyed)throw new Error("torrent is destroyed");if(e<0||t<e||this.pieces.length<=t)throw new Error("invalid selection ",e,":",t);n=Number(n)||0,this._debug("select %s-%s (priority %s)",e,t,n),this._selections.push({from:e,to:t,offset:0,priority:n,notify:r||J}),this._selections.sort((e,t)=>t.priority-e.priority),this._updateSelections()}deselect(e,t,n){if(this.destroyed)throw new Error("torrent is destroyed");n=Number(n)||0,this._debug("deselect %s-%s (priority %s)",e,t,n);for(let r=0;r<this._selections.length;++r){const i=this._selections[r];if(i.from===e&&i.to===t&&i.priority===n){this._selections.splice(r,1);break}}this._updateSelections()}critical(e,t){if(this.destroyed)throw new Error("torrent is destroyed");this._debug("critical %s-%s",e,t);for(let n=e;n<=t;++n)this._critical[n]=!0;this._updateSelections()}_onWire(e,n){if(this._debug("got wire %s (%s)",e._debugId,n||"Unknown"),e.on("download",e=>{this.destroyed||(this.received+=e,this._downloadSpeed(e),this.client._downloadSpeed(e),this.emit("download",e),this.client.emit("download",e))}),e.on("upload",e=>{this.destroyed||(this.uploaded+=e,this._uploadSpeed(e),this.client._uploadSpeed(e),this.emit("upload",e),this.client.emit("upload",e))}),this.wires.push(e),n){const t=i(n);e.remoteAddress=t[0],e.remotePort=t[1]}this.client.dht&&this.client.dht.listening&&e.on("port",t=>{if(!this.destroyed&&!this.client.dht.destroyed){if(!e.remoteAddress)return this._debug("ignoring PORT from peer with no address");if(0===t||t>65536)return this._debug("ignoring invalid PORT from peer");this._debug("port: %s (from %s)",t,n),this.client.dht.addNode({host:e.remoteAddress,port:t})}}),e.on("timeout",()=>{this._debug("wire timeout (%s)",n),e.destroy()}),e.setTimeout(N,!0),e.setKeepAlive(!0),e.use(A(this.metadata)),e.ut_metadata.on("warning",e=>{this._debug("ut_metadata warning: %s",e.message)}),this.metadata||(e.ut_metadata.on("metadata",e=>{this._debug("got metadata via ut_metadata"),this._onMetadata(e)}),e.ut_metadata.fetch()),"function"!=typeof T||this.private||(e.use(T()),e.ut_pex.on("peer",e=>{this.done||(this._debug("ut_pex: got peer: %s (from %s)",e,n),this.addPeer(e))}),e.ut_pex.on("dropped",e=>{const t=this._peers[e];t&&!t.connected&&(this._debug("ut_pex: dropped peer: %s (from %s)",e,n),this.removePeer(e))}),e.once("close",()=>{e.ut_pex.reset()})),this.emit("wire",e,n),this.metadata&&t.nextTick(()=>{this._onWireWithMetadata(e)})}_onWireWithMetadata(e){let t=null;const n=()=>{this.destroyed||e.destroyed||(this._numQueued>2*(this._numConns-this.numPeers)&&e.amInterested?e.destroy():(t=setTimeout(n,D),t.unref&&t.unref()))};let r;const i=()=>{if(e.peerPieces.buffer.length===this.bitfield.buffer.length){for(r=0;r<this.pieces.length;++r)if(!e.peerPieces.get(r))return;e.isSeeder=!0,e.choke()}};e.on("bitfield",()=>{i(),this._update()}),e.on("have",()=>{i(),this._update()}),e.once("interested",()=>{e.unchoke()}),e.once("close",()=>{clearTimeout(t)}),e.on("choke",()=>{clearTimeout(t),t=setTimeout(n,D),t.unref&&t.unref()}),e.on("unchoke",()=>{clearTimeout(t),this._update()}),e.on("request",(t,n,r,i)=>{if(r>P)return e.destroy();this.pieces[t]||this.store.get(t,{offset:n,length:r},i)}),e.bitfield(this.bitfield),e.uninterested(),e.peerExtensions.dht&&this.client.dht&&this.client.dht.listening&&e.port(this.client.dht.address().port),"webSeed"!==e.type&&(t=setTimeout(n,D),t.unref&&t.unref()),e.isSeeder=!1,i()}_updateSelections(){this.ready&&!this.destroyed&&(t.nextTick(()=>{this._gcSelections()}),this._updateInterest(),this._update())}_gcSelections(){for(let e=0;e<this._selections.length;++e){const t=this._selections[e],n=t.offset;for(;this.bitfield.get(t.from+t.offset)&&t.from+t.offset<t.to;)t.offset+=1;n!==t.offset&&t.notify(),t.to===t.from+t.offset&&(this.bitfield.get(t.from+t.offset)&&(this._selections.splice(e,1),e-=1,t.notify(),this._updateInterest()))}this._selections.length||this.emit("idle")}_updateInterest(){const e=this._amInterested;this._amInterested=!!this._selections.length,this.wires.forEach(e=>{let t=!1;for(let n=0;n<this.pieces.length;++n)if(this.pieces[n]&&e.peerPieces.get(n)){t=!0;break}t?e.interested():e.uninterested()}),e!==this._amInterested&&(this._amInterested?this.emit("interested"):this.emit("uninterested"))}_update(){if(this.destroyed)return;const e=E(this.wires);let t;for(;t=e();)this._updateWireWrapper(t)}_updateWireWrapper(e){const t=this;"undefined"!=typeof window&&"function"==typeof window.requestIdleCallback?window.requestIdleCallback(function(){t._updateWire(e)}):t._updateWire(e)}_updateWire(e){const t=this;if(e.peerChoking)return;if(!e.downloaded)return o();const n=G(e,F);if(e.requests.length>=n)return;const r=G(e,L);function i(t,n,r,i){return o=>o>=t&&o<=n&&!(o in r)&&e.peerPieces.get(o)&&(!i||i(o))}function o(){if(e.requests.length)return;let n=t._selections.length;for(;n--;){const r=t._selections[n];let o;if("rarest"===t.strategy){const n=r.from+r.offset,s=r.to,a=s-n+1,l={};let u=0;const c=i(n,s,l);for(;u<a&&(o=t._rarityMap.getRarestPiece(c),!(o<0));){if(t._request(e,o,!1))return;l[o]=!0,u+=1}}else for(o=r.to;o>=r.from+r.offset;--o)if(e.peerPieces.get(o)&&t._request(e,o,!1))return}}function s(){const n=e.downloadSpeed()||1;if(n>M)return()=>!0;const r=Math.max(1,e.requests.length)*w.BLOCK_LENGTH/n;let i=10,o=0;return e=>{if(!i||t.bitfield.get(e))return!0;let s=t.pieces[e].missing;for(;o<t.wires.length;o++){const a=t.wires[o],l=a.downloadSpeed();if(!(l<M)&&(!(l<=n)&&a.peerPieces.get(e)&&!((s-=l*r)>0)))return i--,!1}return!0}}function a(e){let n=e;for(let r=e;r<t._selections.length&&t._selections[r].priority;r++)n=r;const r=t._selections[e];t._selections[e]=t._selections[n],t._selections[n]=r}function l(n){if(e.requests.length>=r)return!0;const o=s();for(let s=0;s<t._selections.length;s++){const l=t._selections[s];let u;if("rarest"===t.strategy){const c=l.from+l.offset,h=l.to,f=h-c+1,p={};let d=0;const m=i(c,h,p,o);for(;d<f&&(u=t._rarityMap.getRarestPiece(m),!(u<0));){for(;t._request(e,u,t._critical[u]||n););if(!(e.requests.length<r))return l.priority&&a(s),!0;p[u]=!0,d++}}else for(u=l.from+l.offset;u<=l.to;u++)if(e.peerPieces.get(u)&&o(u)){for(;t._request(e,u,t._critical[u]||n););if(!(e.requests.length<r))return l.priority&&a(s),!0}}return!1}l(!1)||l(!0)}_rechoke(){if(!this.ready)return;this._rechokeOptimisticTime>0?this._rechokeOptimisticTime-=1:this._rechokeOptimisticWire=null;const e=[];this.wires.forEach(t=>{t.isSeeder||t===this._rechokeOptimisticWire||e.push({wire:t,downloadSpeed:t.downloadSpeed(),uploadSpeed:t.uploadSpeed(),salt:Math.random(),isChoked:!0})}),e.sort(r);let t=0,n=0;for(;n<e.length&&t<this._rechokeNumSlots;++n)e[n].isChoked=!1,e[n].wire.peerInterested&&(t+=1);if(!this._rechokeOptimisticWire&&n<e.length&&this._rechokeNumSlots){const t=e.slice(n).filter(e=>e.wire.peerInterested),r=t[Z(t.length)];r&&(r.isChoked=!1,this._rechokeOptimisticWire=r.wire,this._rechokeOptimisticTime=q)}function r(e,t){return e.downloadSpeed!==t.downloadSpeed?t.downloadSpeed-e.downloadSpeed:e.uploadSpeed!==t.uploadSpeed?t.uploadSpeed-e.uploadSpeed:e.wire.amChoking!==t.wire.amChoking?e.wire.amChoking?1:-1:e.salt-t.salt}e.forEach(e=>{e.wire.amChoking!==e.isChoked&&(e.isChoked?e.wire.choke():e.wire.unchoke())})}_hotswap(e,t){const n=e.downloadSpeed();if(n<w.BLOCK_LENGTH)return!1;if(!this._reservations[t])return!1;const r=this._reservations[t];if(!r)return!1;let i=1/0,o,s;for(s=0;s<r.length;s++){const t=r[s];if(!t||t===e)continue;const a=t.downloadSpeed();a>=M||(2*a>n||a>i||(o=t,i=a))}if(!o)return!1;for(s=0;s<r.length;s++)r[s]===o&&(r[s]=null);for(s=0;s<o.requests.length;s++){const e=o.requests[s];e.piece===t&&this.pieces[t].cancel(e.offset/w.BLOCK_LENGTH|0)}return this.emit("hotswap",o,e,t),!0}_request(e,n,r){const i=this,o=e.requests.length,s="webSeed"===e.type;if(i.bitfield.get(n))return!1;const a=s?Math.min(Y(e,L,i.pieceLength),i.maxWebConns):G(e,L);if(o>=a)return!1;const l=i.pieces[n];let u=s?l.reserveRemaining():l.reserve();if(-1===u&&r&&i._hotswap(e,n)&&(u=s?l.reserveRemaining():l.reserve()),-1===u)return!1;let c=i._reservations[n];c||(c=i._reservations[n]=[]);let h=c.indexOf(null);-1===h&&(h=c.length),c[h]=e;const f=l.chunkOffset(u),p=s?l.chunkLengthRemaining(u):l.chunkLength(u);function d(){t.nextTick(()=>{i._update()})}return e.request(n,f,p,function t(r,o){if(i.destroyed)return;if(!i.ready)return i.once("ready",()=>{t(r,o)});if(c[h]===e&&(c[h]=null),l!==i.pieces[n])return d();if(r)return i._debug("error getting piece %s (offset: %s length: %s) from %s: %s",n,f,p,`${e.remoteAddress}:${e.remotePort}`,r.message),s?l.cancelRemaining(u):l.cancel(u),void d();if(i._debug("got piece %s (offset: %s length: %s) from %s",n,f,p,`${e.remoteAddress}:${e.remotePort}`),!l.set(u,o,e))return d();const a=l.flush();S(a,e=>{if(!i.destroyed){if(e===i._hashes[n]){if(!i.pieces[n])return;i._debug("piece verified %s",n),i.pieces[n]=null,i._reservations[n]=null,i.bitfield.set(n,!0),i.store.put(n,a),i.wires.forEach(e=>{e.have(n)}),i._checkDone()&&!i.destroyed&&i.discovery.complete()}else i.pieces[n]=new w(l.length),i.emit("warning",new Error(`Piece ${n} failed verification`));d()}})}),!0}_checkDone(){if(this.destroyed)return;this.files.forEach(e=>{if(!e.done){for(let t=e._startPiece;t<=e._endPiece;++t)if(!this.bitfield.get(t))return;e.done=!0,e.emit("done"),this._debug(`file done: ${e.name}`)}});let e=!0;for(let t=0;t<this._selections.length;t++){const n=this._selections[t];for(let t=n.from;t<=n.to;t++)if(!this.bitfield.get(t)){e=!1;break}if(!e)break}return!this.done&&e&&(this.done=!0,this._debug(`torrent done: ${this.infoHash}`),this.emit("done")),this._gcSelections(),e}load(e,t){if(this.destroyed)throw new Error("torrent is destroyed");if(!this.ready)return this.once("ready",()=>{this.load(e,t)});Array.isArray(e)||(e=[e]),t||(t=J);const n=new d(e),r=new s(this.store,this.pieceLength);k(n,r,e=>{if(e)return t(e);this._markAllVerified(),this._checkDone(),t(null)})}createServer(e){if("function"!=typeof O)throw new Error("node.js-only method");if(this.destroyed)throw new Error("torrent is destroyed");const t=new O(this,e);return this._servers.push(t),t}pause(){this.destroyed||(this._debug("pause"),this.paused=!0)}resume(){this.destroyed||(this._debug("resume"),this.paused=!1,this._drain())}_debug(){const e=[].slice.call(arguments);e[0]=`[${this.client._debugId}] [${this._debugId}] ${e[0]}`,a(...e)}_drain(){if(this._debug("_drain numConns %s maxConns %s",this._numConns,this.client.maxConns),"function"!=typeof m.connect||this.destroyed||this.paused||this._numConns>=this.client.maxConns)return;this._debug("drain (%s queued, %s/%s peers)",this._numQueued,this.numPeers,this.client.maxConns);const e=this._queue.shift();if(!e)return;this._debug("tcp connect attempt to %s",e.addr);const t=i(e.addr),n={host:t[0],port:t[1]},r=e.conn=m.connect(n);r.once("connect",()=>{e.onConnect()}),r.once("error",t=>{e.destroy(t)}),e.startConnectTimeout(),r.on("close",()=>{if(this.destroyed)return;if(e.retries>=K.length)return void this._debug("conn %s closed: will not re-add (max %s attempts)",e.addr,K.length);const t=K[e.retries];this._debug("conn %s closed: will re-add to queue in %sms (attempt %s)",e.addr,t,e.retries+1);const n=setTimeout(()=>{const t=this._addPeer(e.addr);t&&(t.retries=e.retries+1)},t);n.unref&&n.unref()})}_validAddr(e){let t;try{t=i(e)}catch(e){return!1}const n=t[0],r=t[1];return r>0&&r<65535&&!("127.0.0.1"===n&&r===this.client.torrentPort)}}function G(e,t){return 2+Math.ceil(t*e.downloadSpeed()/w.BLOCK_LENGTH)}function Y(e,t,n){return 1+Math.ceil(t*e.downloadSpeed()/n)}function Z(e){return Math.random()*e|0}function J(){}e.exports=W}).call(this,n(3),n(8))},function(e,t){const n=/^\[?([^\]]+)\]?:(\d+)$/;let r={},i=0;e.exports=function t(o){if(1e5===i&&e.exports.reset(),!r[o]){const e=n.exec(o);if(!e)throw new Error(`invalid addr: ${o}`);r[o]=[e[1],Number(e[2])],i+=1}return r[o]},e.exports.reset=function e(){r={},i=0}},function(e,t,n){const r=n(553),i=n(1561);class o extends i.Writable{constructor(e,t,n={}){if(super(n),!e||!e.put||!e.get)throw new Error("First argument must be an abstract-chunk-store compliant store");if(t=Number(t),!t)throw new Error("Second argument must be a chunk length");this._blockstream=new r(t,{zeroPadding:!1});let i=0;const o=t=>{this.destroyed||(e.put(i,t),i+=1)};this._blockstream.on("data",o).on("error",e=>{this.destroy(e)}),this.on("finish",()=>this._blockstream.end())}_write(e,t,n){this._blockstream.write(e,t,n)}destroy(e){this.destroyed||(this.destroyed=!0,e&&this.emit("error",e),this.emit("close"))}}e.exports=o},function(e,t,n){t=e.exports=n(576),t.Stream=t,t.Readable=t,t.Writable=n(579),t.Duplex=n(139),t.Transform=n(580),t.PassThrough=n(1565)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1564);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(580),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){(function(t){const r=n(1567)("torrent-discovery"),i=n(1569),o=n(6).EventEmitter,s=n(170),a=n(1570);class l extends o{constructor(e){if(super(),!e.peerId)throw new Error("Option `peerId` is required");if(!e.infoHash)throw new Error("Option `infoHash` is required");if(!t.browser&&!e.port)throw new Error("Option `port` is required");this.peerId="string"==typeof e.peerId?e.peerId:e.peerId.toString("hex"),this.infoHash="string"==typeof e.infoHash?e.infoHash.toLowerCase():e.infoHash.toString("hex"),this._port=e.port,this._userAgent=e.userAgent,this.destroyed=!1,this._announce=e.announce||[],this._intervalMs=e.intervalMs||9e5,this._trackerOpts=null,this._dhtAnnouncing=!1,this._dhtTimeout=!1,this._internalDHT=!1,this._onWarning=(e=>{this.emit("warning",e)}),this._onError=(e=>{this.emit("error",e)}),this._onDHTPeer=((e,t)=>{t.toString("hex")===this.infoHash&&this.emit("peer",`${e.host}:${e.port}`,"dht")}),this._onTrackerPeer=(e=>{this.emit("peer",e,"tracker")}),this._onTrackerAnnounce=(()=>{this.emit("trackerAnnounce")});const n=(e,t)=>{const n=new i(t);return n.on("warning",this._onWarning),n.on("error",this._onError),n.listen(e),this._internalDHT=!0,n};!1===e.tracker?this.tracker=null:e.tracker&&"object"==typeof e.tracker?(this._trackerOpts=Object.assign({},e.tracker),this.tracker=this._createTracker()):this.tracker=this._createTracker(),!1===e.dht||"function"!=typeof i?this.dht=null:e.dht&&"function"==typeof e.dht.addNode?this.dht=e.dht:e.dht&&"object"==typeof e.dht?this.dht=n(e.dhtPort,e.dht):this.dht=n(e.dhtPort),this.dht&&(this.dht.on("peer",this._onDHTPeer),this._dhtAnnounce())}updatePort(e){e!==this._port&&(this._port=e,this.dht&&this._dhtAnnounce(),this.tracker&&(this.tracker.stop(),this.tracker.destroy(()=>{this.tracker=this._createTracker()})))}complete(e){this.tracker&&this.tracker.complete(e)}destroy(e){if(this.destroyed)return;this.destroyed=!0,clearTimeout(this._dhtTimeout);const t=[];this.tracker&&(this.tracker.stop(),this.tracker.removeListener("warning",this._onWarning),this.tracker.removeListener("error",this._onError),this.tracker.removeListener("peer",this._onTrackerPeer),this.tracker.removeListener("update",this._onTrackerAnnounce),t.push(e=>{this.tracker.destroy(e)})),this.dht&&this.dht.removeListener("peer",this._onDHTPeer),this._internalDHT&&(this.dht.removeListener("warning",this._onWarning),this.dht.removeListener("error",this._onError),t.push(e=>{this.dht.destroy(e)})),s(t,e),this.dht=null,this.tracker=null,this._announce=null}_createTracker(){const e=Object.assign({},this._trackerOpts,{infoHash:this.infoHash,announce:this._announce,peerId:this.peerId,port:this._port,userAgent:this._userAgent}),t=new a(e);return t.on("warning",this._onWarning),t.on("error",this._onError),t.on("peer",this._onTrackerPeer),t.on("update",this._onTrackerAnnounce),t.setInterval(this._intervalMs),t.start(),t}_dhtAnnounce(){this._dhtAnnouncing||(r("dht announce"),this._dhtAnnouncing=!0,clearTimeout(this._dhtTimeout),this.dht.announce(this.infoHash,this._port,e=>{this._dhtAnnouncing=!1,r("dht announce complete"),e&&this.emit("warning",e),this.emit("dhtAnnounce"),this.destroyed||(this._dhtTimeout=setTimeout(()=>{this._dhtAnnounce()},this._intervalMs+Math.floor(Math.random()*this._intervalMs/5)),this._dhtTimeout.unref&&this._dhtTimeout.unref())}))}}e.exports=l}).call(this,n(3))},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1568)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t){},function(e,t,n){(function(t){const{Buffer:r}=n(5),i=n(4)("bittorrent-tracker:client"),o=n(6),s=n(26),a=n(170),l=n(308),u=n(232),c=n(32),h=n(581),f=n(1572),p=n(1573),d=n(1574);class m extends o{constructor(e={}){if(super(),!e.peerId)throw new Error("Option `peerId` is required");if(!e.infoHash)throw new Error("Option `infoHash` is required");if(!e.announce)throw new Error("Option `announce` is required");if(!t.browser&&!e.port)throw new Error("Option `port` is required");this.peerId="string"==typeof e.peerId?e.peerId:e.peerId.toString("hex"),this._peerIdBuffer=r.from(this.peerId,"hex"),this._peerIdBinary=this._peerIdBuffer.toString("binary"),this.infoHash="string"==typeof e.infoHash?e.infoHash.toLowerCase():e.infoHash.toString("hex"),this._infoHashBuffer=r.from(this.infoHash,"hex"),this._infoHashBinary=this._infoHashBuffer.toString("binary"),i("new client %s",this.infoHash),this.destroyed=!1,this._port=e.port,this._getAnnounceOpts=e.getAnnounceOpts,this._rtcConfig=e.rtcConfig,this._userAgent=e.userAgent,this._wrtc="function"==typeof e.wrtc?e.wrtc():e.wrtc;let n="string"==typeof e.announce?[e.announce]:null==e.announce?[]:e.announce;n=n.map(e=>(e=e.toString(),"/"===e[e.length-1]&&(e=e.substring(0,e.length-1)),e)),n=u(n);const o=!1!==this._wrtc&&(!!this._wrtc||l.WEBRTC_SUPPORT),s=e=>{t.nextTick(()=>{this.emit("warning",e)})};this._trackers=n.map(e=>{const t=c.parse(e),n=t.port;if(n<0||n>65535)return s(new Error(`Invalid tracker port: ${e}`)),null;const r=t.protocol;return"http:"!==r&&"https:"!==r||"function"!=typeof f?"udp:"===r&&"function"==typeof p?new p(this,e):"ws:"!==r&&"wss:"!==r||!o?(s(new Error(`Unsupported tracker protocol: ${e}`)),null):"ws:"===r&&"undefined"!=typeof window&&"https:"===window.location.protocol?(s(new Error(`Unsupported tracker protocol: ${e}`)),null):new d(this,e):new f(this,e)}).filter(Boolean)}start(e){i("send `start`"),e=this._defaultAnnounceOpts(e),e.event="started",this._announce(e),this._trackers.forEach(e=>{e.setInterval()})}stop(e){i("send `stop`"),e=this._defaultAnnounceOpts(e),e.event="stopped",this._announce(e)}complete(e){i("send `complete`"),e||(e={}),e=this._defaultAnnounceOpts(e),e.event="completed",this._announce(e)}update(e){i("send `update`"),e=this._defaultAnnounceOpts(e),e.event&&delete e.event,this._announce(e)}_announce(e){this._trackers.forEach(t=>{t.announce(e)})}scrape(e){i("send `scrape`"),e||(e={}),this._trackers.forEach(t=>{t.scrape(e)})}setInterval(e){i("setInterval %d",e),this._trackers.forEach(t=>{t.setInterval(e)})}destroy(e){if(this.destroyed)return;this.destroyed=!0,i("destroy");const t=this._trackers.map(e=>t=>{e.destroy(t)});a(t,e),this._trackers=[],this._getAnnounceOpts=null}_defaultAnnounceOpts(e={}){return null==e.numwant&&(e.numwant=h.DEFAULT_ANNOUNCE_PEERS),null==e.uploaded&&(e.uploaded=0),null==e.downloaded&&(e.downloaded=0),this._getAnnounceOpts&&(e=Object.assign({},e,this._getAnnounceOpts())),e}}m.scrape=((e,t)=>{if(t=s(t),!e.infoHash)throw new Error("Option `infoHash` is required");if(!e.announce)throw new Error("Option `announce` is required");const n=Object.assign({},e,{infoHash:Array.isArray(e.infoHash)?e.infoHash[0]:e.infoHash,peerId:r.from("01234567890123456789"),port:6881}),i=new m(n);i.once("error",t),i.once("warning",t);let o=Array.isArray(e.infoHash)?e.infoHash.length:1;const a={};return i.on("scrape",e=>{if(o-=1,a[e.infoHash]=e,0===o){i.destroy();const e=Object.keys(a);1===e.length?t(null,a[e[0]]):t(null,a)}}),e.infoHash=Array.isArray(e.infoHash)?e.infoHash.map(e=>r.from(e,"hex")):r.from(e.infoHash,"hex"),i.scrape({infoHash:e.infoHash}),i}),e.exports=m}).call(this,n(3))},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){const r=n(4)("bittorrent-tracker:websocket-tracker"),i=n(308),o=n(101),s=n(1575),a=n(581),l=n(1584),u={},c=1e4,h=18e5,f=12e4,p=5e4;class d extends l{constructor(e,t,n){super(e,t),r("new websocket tracker %s",t),this.peers={},this.socket=null,this.reconnecting=!1,this.retries=0,this.reconnectTimer=null,this.expectingResponse=!1,this._openSocket()}announce(e){if(this.destroyed||this.reconnecting)return;if(!this.socket.connected)return void this.socket.once("connect",()=>{this.announce(e)});const t=Object.assign({},e,{action:"announce",info_hash:this.client._infoHashBinary,peer_id:this.client._peerIdBinary});if(this._trackerId&&(t.trackerid=this._trackerId),"stopped"===e.event||"completed"===e.event)this._send(t);else{const n=Math.min(e.numwant,10);this._generateOffers(n,e=>{t.numwant=n,t.offers=e,this._send(t)})}}scrape(e){if(this.destroyed||this.reconnecting)return;if(!this.socket.connected)return void this.socket.once("connect",()=>{this.scrape(e)});const t=Array.isArray(e.infoHash)&&e.infoHash.length>0?e.infoHash.map(e=>e.toString("binary")):e.infoHash&&e.infoHash.toString("binary")||this.client._infoHashBinary,n={action:"scrape",info_hash:t};this._send(n)}destroy(e=m){if(this.destroyed)return e(null);this.destroyed=!0,clearInterval(this.interval),clearTimeout(this.reconnectTimer);for(const e in this.peers){const t=this.peers[e];clearTimeout(t.trackerTimeout),t.destroy()}if(this.peers=null,this.socket&&(this.socket.removeListener("connect",this._onSocketConnectBound),this.socket.removeListener("data",this._onSocketDataBound),this.socket.removeListener("close",this._onSocketCloseBound),this.socket.removeListener("error",this._onSocketErrorBound),this.socket=null),this._onSocketConnectBound=null,this._onSocketErrorBound=null,this._onSocketDataBound=null,this._onSocketCloseBound=null,u[this.announceUrl]&&(u[this.announceUrl].consumers-=1),u[this.announceUrl].consumers>0)return e();let t=u[this.announceUrl];if(delete u[this.announceUrl],t.on("error",m),t.once("close",e),!this.expectingResponse)return r();var n=setTimeout(r,a.DESTROY_TIMEOUT);function r(){n&&(clearTimeout(n),n=null),t.removeListener("data",r),t.destroy(),t=null}t.once("data",r)}_openSocket(){this.destroyed=!1,this.peers||(this.peers={}),this._onSocketConnectBound=(()=>{this._onSocketConnect()}),this._onSocketErrorBound=(e=>{this._onSocketError(e)}),this._onSocketDataBound=(e=>{this._onSocketData(e)}),this._onSocketCloseBound=(()=>{this._onSocketClose()}),this.socket=u[this.announceUrl],this.socket?u[this.announceUrl].consumers+=1:(this.socket=u[this.announceUrl]=new s(this.announceUrl),this.socket.consumers=1,this.socket.once("connect",this._onSocketConnectBound)),this.socket.on("data",this._onSocketDataBound),this.socket.once("close",this._onSocketCloseBound),this.socket.once("error",this._onSocketErrorBound)}_onSocketConnect(){this.destroyed||this.reconnecting&&(this.reconnecting=!1,this.retries=0,this.announce(this.client._defaultAnnounceOpts()))}_onSocketData(e){if(!this.destroyed){this.expectingResponse=!1;try{e=JSON.parse(e)}catch(e){return void this.client.emit("warning",new Error("Invalid tracker response"))}"announce"===e.action?this._onAnnounceResponse(e):"scrape"===e.action?this._onScrapeResponse(e):this._onSocketError(new Error(`invalid action in WS response: ${e.action}`))}}_onAnnounceResponse(e){if(e.info_hash!==this.client._infoHashBinary)return void r("ignoring websocket data from %s for %s (looking for %s: reused socket)",this.announceUrl,a.binaryToHex(e.info_hash),this.client.infoHash);if(e.peer_id&&e.peer_id===this.client._peerIdBinary)return;r("received %s from %s for %s",JSON.stringify(e),this.announceUrl,this.client.infoHash);const t=e["failure reason"];if(t)return this.client.emit("warning",new Error(t));const n=e["warning message"];n&&this.client.emit("warning",new Error(n));const i=e.interval||e["min interval"];i&&this.setInterval(1e3*i);const o=e["tracker id"];if(o&&(this._trackerId=o),null!=e.complete){const t=Object.assign({},e,{announce:this.announceUrl,infoHash:a.binaryToHex(e.info_hash)});this.client.emit("update",t)}let s;if(e.offer&&e.peer_id&&(r("creating peer (from remote offer)"),s=this._createPeer(),s.id=a.binaryToHex(e.peer_id),s.once("signal",t=>{const n={action:"announce",info_hash:this.client._infoHashBinary,peer_id:this.client._peerIdBinary,to_peer_id:e.peer_id,answer:t,offer_id:e.offer_id};this._trackerId&&(n.trackerid=this._trackerId),this._send(n)}),s.signal(e.offer),this.client.emit("peer",s)),e.answer&&e.peer_id){const t=a.binaryToHex(e.offer_id);s=this.peers[t],s?(s.id=a.binaryToHex(e.peer_id),s.signal(e.answer),this.client.emit("peer",s),clearTimeout(s.trackerTimeout),s.trackerTimeout=null,delete this.peers[t]):r(`got unexpected answer: ${JSON.stringify(e.answer)}`)}}_onScrapeResponse(e){e=e.files||{};const t=Object.keys(e);0!==t.length?t.forEach(t=>{const n=Object.assign(e[t],{announce:this.announceUrl,infoHash:a.binaryToHex(t)});this.client.emit("scrape",n)}):this.client.emit("warning",new Error("invalid scrape response"))}_onSocketClose(){this.destroyed||(this.destroy(),this._startReconnectTimer())}_onSocketError(e){this.destroyed||(this.destroy(),this.client.emit("warning",e),this._startReconnectTimer())}_startReconnectTimer(){const e=Math.floor(Math.random()*f)+Math.min(Math.pow(2,this.retries)*c,h);this.reconnecting=!0,clearTimeout(this.reconnectTimer),this.reconnectTimer=setTimeout(()=>{this.retries++,this._openSocket()},e),this.reconnectTimer.unref&&this.reconnectTimer.unref(),r("reconnecting socket in %s ms",e)}_send(e){if(this.destroyed)return;this.expectingResponse=!0;const t=JSON.stringify(e);r("send %s",t),this.socket.send(t)}_generateOffers(e,t){const n=this,i=[];r("generating %s offers",e);for(let t=0;t<e;++t)s();function s(){const e=o(20).toString("hex");r("creating peer (from _generateOffers)");const t=n.peers[e]=n._createPeer({initiator:!0});t.once("signal",t=>{i.push({offer:t,offer_id:a.hexToBinary(e)}),l()}),t.trackerTimeout=setTimeout(()=>{r("tracker timeout: destroying peer"),t.trackerTimeout=null,delete n.peers[e],t.destroy()},p),t.trackerTimeout.unref&&t.trackerTimeout.unref()}function l(){i.length===e&&(r("generated %s offers",e),t(i))}l()}_createPeer(e){const t=this;e=Object.assign({trickle:!1,config:t.client._rtcConfig,wrtc:t.client._wrtc},e);const n=new i(e);return n.once("error",r),n.once("connect",o),n;function r(e){t.client.emit("warning",new Error(`Connection error: ${e.message}`)),n.destroy()}function o(){n.removeListener("error",r),n.removeListener("connect",o)}}}function m(){}d.prototype.DEFAULT_ANNOUNCE_INTERVAL=3e4,d._socketPool=u,e.exports=d},function(e,t,n){(function(t,r){e.exports=h;var i=n(1576)("simple-websocket"),o=n(1),s=n(101),a=n(1578),l=n(1583),u="function"!=typeof l?WebSocket:l,c=65536;function h(e){var n=this;if(!(n instanceof h))return new h(e);if(e||(e={}),"string"==typeof e&&(e={url:e}),null==e.url&&null==e.socket)throw new Error("Missing required `url` or `socket` option");if(null!=e.url&&null!=e.socket)throw new Error("Must specify either `url` or `socket` option, not both");if(n._id=s(4).toString("hex").slice(0,7),n._debug("new websocket: %o",e),e=Object.assign({allowHalfOpen:!1},e),a.Duplex.call(n,e),n.connected=!1,n.destroyed=!1,n._chunk=null,n._cb=null,n._interval=null,e.socket)n.url=e.socket.url,n._ws=e.socket;else{n.url=e.url;try{n._ws="function"==typeof l?new u(e.url,e):new u(e.url)}catch(e){return void t.nextTick(function(){n.destroy(e)})}}n._ws.binaryType="arraybuffer",n._ws.onopen=function(){n._onOpen()},n._ws.onmessage=function(e){n._onMessage(e)},n._ws.onclose=function(){n._onClose()},n._ws.onerror=function(){n.destroy(new Error("connection error to "+n.url))},n._onFinishBound=function(){n._onFinish()},n.once("finish",n._onFinishBound)}o(h,a.Duplex),h.WEBSOCKET_SUPPORT=!!u,h.prototype.send=function(e){this._ws.send(e)},h.prototype.destroy=function(e){this._destroy(e,function(){})},h.prototype._destroy=function(e,t){var n=this;if(!this.destroyed){if(this._debug("destroy (error: %s)",e&&(e.message||e)),this.readable=this.writable=!1,this._readableState.ended||this.push(null),this._writableState.finished||this.end(),this.connected=!1,this.destroyed=!0,clearInterval(this._interval),this._interval=null,this._chunk=null,this._cb=null,this._onFinishBound&&this.removeListener("finish",this._onFinishBound),this._onFinishBound=null,this._ws){var r=this._ws,i=function(){r.onclose=null};if(r.readyState===u.CLOSED)i();else try{r.onclose=i,r.close()}catch(e){i()}r.onopen=null,r.onmessage=null,r.onerror=function(){}}if(this._ws=null,e){if("undefined"!=typeof DOMException&&e instanceof DOMException){var o=e.code;e=new Error(e.message),e.code=o}this.emit("error",e)}this.emit("close"),t()}},h.prototype._read=function(){},h.prototype._write=function(e,t,n){if(this.destroyed)return n(new Error("cannot write after socket is destroyed"));if(this.connected){try{this.send(e)}catch(e){return this.destroy(e)}"function"!=typeof l&&this._ws.bufferedAmount>65536?(this._debug("start backpressure: bufferedAmount %d",this._ws.bufferedAmount),this._cb=n):n(null)}else this._debug("write before connect"),this._chunk=e,this._cb=n},h.prototype._onFinish=function(){var e=this;function t(){setTimeout(function(){e.destroy()},1e3)}e.destroyed||(e.connected?t():e.once("connect",t))},h.prototype._onMessage=function(e){if(!this.destroyed){var t=e.data;t instanceof ArrayBuffer&&(t=r.from(t)),this.push(t)}},h.prototype._onOpen=function(){var e=this;if(!e.connected&&!e.destroyed){if(e.connected=!0,e._chunk){try{e.send(e._chunk)}catch(t){return e.destroy(t)}e._chunk=null,e._debug('sent chunk from "write before connect"');var t=e._cb;e._cb=null,t(null)}"function"!=typeof l&&(e._interval=setInterval(function(){e._onInterval()},150),e._interval.unref&&e._interval.unref()),e._debug("connect"),e.emit("connect")}},h.prototype._onInterval=function(){if(this._cb&&this._ws&&!(this._ws.bufferedAmount>65536)){this._debug("ending backpressure: bufferedAmount %d",this._ws.bufferedAmount);var e=this._cb;this._cb=null,e(null)}},h.prototype._onClose=function(){this.destroyed||(this._debug("on close"),this.destroy())},h.prototype._debug=function(){var e=[].slice.call(arguments);e[0]="["+this._id+"] "+e[0],i.apply(null,e)}}).call(this,n(3),n(0).Buffer)},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1577)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t,n){t=e.exports=n(582),t.Stream=t,t.Readable=t,t.Writable=n(585),t.Duplex=n(140),t.Transform=n(586),t.PassThrough=n(1582)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1581);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(586),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){},function(e,t,n){const r=n(6);class i extends r{constructor(e,t){super(),this.client=e,this.announceUrl=t,this.interval=null,this.destroyed=!1}setInterval(e){null==e&&(e=this.DEFAULT_ANNOUNCE_INTERVAL),clearInterval(this.interval),e&&(this.interval=setInterval(()=>{this.announce(this.client._defaultAnnounceOpts())},e),this.interval.unref&&this.interval.unref())}}e.exports=i},function(e,t,n){(function(t){function n(e,t){if(!(this instanceof n))return new n(e,t);if(t||(t={}),this.chunkLength=Number(e),!this.chunkLength)throw new Error("First argument must be a chunk length");this.chunks=[],this.closed=!1,this.length=Number(t.length)||1/0,this.length!==1/0&&(this.lastChunkLength=this.length%this.chunkLength||this.chunkLength,this.lastChunkIndex=Math.ceil(this.length/this.chunkLength)-1)}function r(e,n,r){t.nextTick(function(){e&&e(n,r)})}e.exports=n,n.prototype.put=function(e,t,n){if(this.closed)return r(n,new Error("Storage is closed"));var i=e===this.lastChunkIndex;return i&&t.length!==this.lastChunkLength?r(n,new Error("Last chunk length must be "+this.lastChunkLength)):i||t.length===this.chunkLength?(this.chunks[e]=t,void r(n,null)):r(n,new Error("Chunk length must be "+this.chunkLength))},n.prototype.get=function(e,t,n){if("function"==typeof t)return this.get(e,null,t);if(this.closed)return r(n,new Error("Storage is closed"));var i=this.chunks[e];if(!i){var o=new Error("Chunk not found");return o.notFound=!0,r(n,o)}if(!t)return r(n,null,i);var s=t.offset||0,a=t.length||i.length-s;r(n,null,i.slice(s,a+s))},n.prototype.close=n.prototype.destroy=function(e){if(this.closed)return r(e,new Error("Storage is closed"));this.closed=!0,this.chunks=null,r(e,null)}}).call(this,n(3))},function(e,t,n){(function(t){class n{constructor(e){if(this.store=e,this.chunkLength=e.chunkLength,!this.store||!this.store.get||!this.store.put)throw new Error("First argument must be abstract-chunk-store compliant");this.mem=[]}put(e,t,n){this.mem[e]=t,this.store.put(e,t,t=>{this.mem[e]=null,n&&n(t)})}get(e,t,n){if("function"==typeof t)return this.get(e,null,t);const i=t&&t.offset||0,o=t&&t.length&&i+t.length,s=this.mem[e];if(s)return r(n,null,t?s.slice(i,o):s);this.store.get(e,t,n)}close(e){this.store.close(e)}destroy(e){this.store.destroy(e)}}function r(e,n,r){t.nextTick(()=>{e&&e(n,r)})}e.exports=n}).call(this,n(3))},function(e,t){},function(e,t){},function(e,t,n){(function(t){function n(e,n,r){if("number"!=typeof n)throw new Error("second argument must be a Number");var i,o,s,a,l,u=!0;function c(e){function n(){r&&r(e,i),r=null}u?t.nextTick(n):n()}function h(t,n,r){if(i[t]=r,n&&(l=!0),0==--s||n)c(n);else if(!l&&f<o){var u;a?(u=a[f],f+=1,e[u](function(e,t){h(u,e,t)})):(u=f,f+=1,e[u](function(e,t){h(u,e,t)}))}}Array.isArray(e)?(i=[],s=o=e.length):(a=Object.keys(e),i={},s=o=a.length);var f=n;s?a?a.some(function(t,r){if(e[t](function(e,n){h(t,e,n)}),r===n-1)return!0}):e.some(function(e,t){if(e(function(e,n){h(t,e,n)}),t===n-1)return!0}):c(null),u=!1}e.exports=n}).call(this,n(3))},function(e,t,n){(function(t){const n=16384;class r{constructor(e){this.length=e,this.missing=e,this.sources=null,this._chunks=Math.ceil(e/n),this._remainder=e%n||n,this._buffered=0,this._buffer=null,this._cancellations=null,this._reservations=0,this._flushed=!1}chunkLength(e){return e===this._chunks-1?this._remainder:n}chunkLengthRemaining(e){return this.length-e*n}chunkOffset(e){return e*n}reserve(){return this.init()?this._cancellations.length?this._cancellations.pop():this._reservations<this._chunks?this._reservations++:-1:-1}reserveRemaining(){if(!this.init())return-1;if(this._reservations<this._chunks){const e=this._reservations;return this._reservations=this._chunks,e}return-1}cancel(e){this.init()&&this._cancellations.push(e)}cancelRemaining(e){this.init()&&(this._reservations=e)}get(e){return this.init()?this._buffer[e]:null}set(e,t,r){if(!this.init())return!1;const i=t.length,o=Math.ceil(i/n);for(let i=0;i<o;i++)if(!this._buffer[e+i]){const o=i*n,s=t.slice(o,o+n);this._buffered++,this._buffer[e+i]=s,this.missing-=s.length,this.sources.includes(r)||this.sources.push(r)}return this._buffered===this._chunks}flush(){if(!this._buffer||this._chunks!==this._buffered)return null;const e=t.concat(this._buffer,this.length);return this._buffer=null,this._cancellations=null,this.sources=null,this._flushed=!0,e}init(){return!this._flushed&&(!!this._buffer||(this._buffer=new Array(this._chunks),this._cancellations=[],this.sources=[],!0))}}Object.defineProperty(r,"BLOCK_LENGTH",{value:n}),e.exports=r}).call(this,n(0).Buffer)},function(e,t){var n=function(e){var t=0;return function(){if(t===e.length)return null;var n=e.length-t,r=Math.random()*n|0,i=e[t+r],o=e[t];return e[t]=i,e[t+r]=o,t++,i}};e.exports=n},function(e,t,n){(function(t){const{EventEmitter:r}=n(6),i=n(231),o=n(233),s=n(1593)("ut_metadata"),a=n(171),l=1e7,u=1e3,c=16384;e.exports=(e=>{class n extends r{constructor(n){super(),this._wire=n,this._fetching=!1,this._metadataComplete=!1,this._metadataSize=null,this._remainingRejects=null,this._bitfield=new o(0,{grow:u}),t.isBuffer(e)&&this.setMetadata(e)}onHandshake(e,t,n){this._infoHash=e}onExtendedHandshake(e){return e.m&&e.m.ut_metadata?e.metadata_size?"number"!=typeof e.metadata_size||l<e.metadata_size||e.metadata_size<=0?this.emit("warning",new Error("Peer gave invalid metadata size")):(this._metadataSize=e.metadata_size,this._numPieces=Math.ceil(this._metadataSize/c),this._remainingRejects=2*this._numPieces,void(this._fetching&&this._requestPieces())):this.emit("warning",new Error("Peer does not have metadata")):this.emit("warning",new Error("Peer does not support ut_metadata"))}onMessage(e){let t,n;try{const r=e.toString(),o=r.indexOf("ee")+2;t=i.decode(r.substring(0,o)),n=e.slice(o)}catch(e){return}switch(t.msg_type){case 0:this._onRequest(t.piece);break;case 1:this._onData(t.piece,n,t.total_size);break;case 2:this._onReject(t.piece)}}fetch(){this._metadataComplete||(this._fetching=!0,this._metadataSize&&this._requestPieces())}cancel(){this._fetching=!1}setMetadata(e){if(this._metadataComplete)return!0;s("set metadata");try{const t=i.decode(e).info;t&&(e=i.encode(t))}catch(e){}return(!this._infoHash||this._infoHash===a.sync(e))&&(this.cancel(),this.metadata=e,this._metadataComplete=!0,this._metadataSize=this.metadata.length,this._wire.extendedHandshake.metadata_size=this._metadataSize,this.emit("metadata",i.encode({info:i.decode(this.metadata)})),!0)}_send(e,n){let r=i.encode(e);t.isBuffer(n)&&(r=t.concat([r,n])),this._wire.extended("ut_metadata",r)}_request(e){this._send({msg_type:0,piece:e})}_data(e,t,n){const r={msg_type:1,piece:e};"number"==typeof n&&(r.total_size=n),this._send(r,t)}_reject(e){this._send({msg_type:2,piece:e})}_onRequest(e){if(!this._metadataComplete)return void this._reject(e);const t=e*c;let n=t+c;n>this._metadataSize&&(n=this._metadataSize);const r=this.metadata.slice(t,n);this._data(e,r,this._metadataSize)}_onData(e,t,n){t.length>c||(t.copy(this.metadata,e*c),this._bitfield.set(e),this._checkDone())}_onReject(e){this._remainingRejects>0&&this._fetching?(this._request(e),this._remainingRejects-=1):this.emit("warning",new Error('Peer sent "reject" too much'))}_requestPieces(){this.metadata=t.alloc(this._metadataSize);for(let e=0;e<this._numPieces;e++)this._request(e)}_checkDone(){let e=!0;for(let t=0;t<this._numPieces;t++)if(!this._bitfield.get(t)){e=!1;break}if(!e)return;const t=this.setMetadata(this.metadata);t||this._failedMetadata()}_failedMetadata(){this._bitfield=new o(0,{grow:u}),this._remainingRejects-=this._numPieces,this._remainingRejects>0?this._requestPieces():this.emit("warning",new Error("Peer sent invalid metadata"))}}return n.prototype.name="ut_metadata",n})}).call(this,n(0).Buffer)},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1594)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t){},function(e,t){function n(e){if(/^-?\d+$/.test(e))return parseInt(e,10);var t;if(t=e.match(/^(-?\d+)(-|\.\.\.?|\u2025|\u2026|\u22EF)(-?\d+)$/)){var n=t[1],r=t[2],i=t[3];if(n&&i){n=parseInt(n),i=parseInt(i);var o=[],s=n<i?1:-1;"-"!=r&&".."!=r&&"‥"!=r||(i+=s);for(var a=n;a!=i;a+=s)o.push(a);return o}}return[]}e.exports.parse=function(e){var t=e.split(","),r=t.map(function(e){return n(e)});return 0===r.length?[]:1===r.length?Array.isArray(r[0])?r[0]:r:r.reduce(function(e,t){return Array.isArray(e)||(e=[e]),Array.isArray(t)||(t=[t]),e.concat(t)})}},function(e,t,n){(function(t){const{EventEmitter:r}=n(6),{PassThrough:i}=n(17),o=n(212),s=n(54),a=n(1598),l=n(589),u=n(588),c=n(1617),h=n(1618);class f extends r{constructor(e,t){super(),this._torrent=e,this._destroyed=!1,this.name=t.name,this.path=t.path,this.length=t.length,this.offset=t.offset,this.done=!1;const n=t.offset,r=n+t.length-1;this._startPiece=n/this._torrent.pieceLength|0,this._endPiece=r/this._torrent.pieceLength|0,0===this.length&&(this.done=!0,this.emit("done"))}get downloaded(){if(!this._torrent.bitfield)return 0;const{pieces:e,bitfield:t,pieceLength:n}=this._torrent,{_startPiece:r,_endPiece:i}=this,o=e[r];let s=t.get(r)?n-this.offset%n:Math.max(o.length-o.missing-this.offset,0);for(let o=r+1;o<=i;++o)if(t.get(o))s+=n;else{const t=e[o];s+=t.length-t.missing}return Math.min(s,this.length)}get progress(){return this.length?this.downloaded/this.length:0}select(e){0!==this.length&&this._torrent.select(this._startPiece,this._endPiece,e)}deselect(){0!==this.length&&this._torrent.deselect(this._startPiece,this._endPiece,!1)}createReadStream(e){if(0===this.length){const e=new i;return t.nextTick(()=>{e.end()}),e}const n=new h(this,e);return this._torrent.select(n._startPiece,n._endPiece,!0,()=>{n._notify()}),o(n,()=>{this._destroyed||this._torrent.destroyed||this._torrent.deselect(n._startPiece,n._endPiece,!0)}),n}getBuffer(e){c(this.createReadStream(),this.length,e)}getBlob(e){if("undefined"==typeof window)throw new Error("browser-only method");l(this.createReadStream(),this._getMimeType(),e)}getBlobURL(e){if("undefined"==typeof window)throw new Error("browser-only method");u(this.createReadStream(),this._getMimeType(),e)}appendTo(e,t,n){if("undefined"==typeof window)throw new Error("browser-only method");a.append(this,e,t,n)}renderTo(e,t,n){if("undefined"==typeof window)throw new Error("browser-only method");a.render(this,e,t,n)}_getMimeType(){return a.mime[s.extname(this.name).toLowerCase()]}_destroy(){this._destroyed=!0,this._torrent=null}}e.exports=f}).call(this,n(3))},function(e,t,n){t.render=v,t.append=b,t.mime=n(1599);var r=n(1600)("render-media"),i=n(1602),o=n(587),s=n(54),a=n(588),l=n(1603),u=[".m4a",".m4v",".mp4"],c=[".m4v",".mkv",".mp4",".webm"],h=[".m4a",".mp3"],f=[].concat(c,h),p=[".aac",".oga",".ogg",".wav",".flac"],d=[".bmp",".gif",".jpeg",".jpg",".png",".svg"],m=[".css",".html",".js",".md",".pdf",".txt"],g=2e8,y="undefined"!=typeof window&&window.MediaSource;function v(e,t,n,r){"function"==typeof n&&(r=n,n={}),n||(n={}),r||(r=function(){}),k(e),S(n),"string"==typeof t&&(t=document.querySelector(t)),_(e,function(n){if(t.nodeName!==n.toUpperCase()){var r=s.extname(e.name).toLowerCase();throw new Error('Cannot render "'+r+'" inside a "'+t.nodeName.toLowerCase()+'" element, expected "'+n+'"')}return t},n,r)}function b(e,t,n,r){if("function"==typeof n&&(r=n,n={}),n||(n={}),r||(r=function(){}),k(e),S(n),"string"==typeof t&&(t=document.querySelector(t)),t&&("VIDEO"===t.nodeName||"AUDIO"===t.nodeName))throw new Error("Invalid video/audio node argument. Argument must be root element that video/audio tag will be appended to.");function i(e){return"video"===e||"audio"===e?o(e):s(e)}function o(e){var r=s(e);return n.autoplay&&(r.autoplay=!0),n.muted&&(r.muted=!0),n.controls&&(r.controls=!0),t.appendChild(r),r}function s(e){var n=document.createElement(e);return t.appendChild(n),n}function a(e,t){e&&t&&t.remove(),r(e,t)}_(e,i,n,a)}function _(e,t,n,a){var h=s.extname(e.name).toLowerCase(),g=0,v;function b(){var i=c.indexOf(h)>=0?"video":"audio";function s(){r("Use `videostream` package for "+e.name),m(),v.addEventListener("error",p),v.addEventListener("loadstart",k),v.addEventListener("canplay",S),l(e,v)}function a(){r("Use MediaSource API for "+e.name),m(),v.addEventListener("error",d),v.addEventListener("loadstart",k),v.addEventListener("canplay",S);var t=new o(v),n=t.createWriteStream(E(e.name));e.createReadStream().pipe(n),g&&(v.currentTime=g)}function f(){r("Use Blob URL for "+e.name),m(),v.addEventListener("error",T),v.addEventListener("loadstart",k),v.addEventListener("canplay",S),w(e,function(e,t){if(e)return T(e);v.src=t,g&&(v.currentTime=g)})}function p(e){r("videostream error: fallback to MediaSource API: %o",e.message||e),v.removeEventListener("error",p),v.removeEventListener("canplay",S),a()}function d(t){if(r("MediaSource API error: fallback to Blob URL: %o",t.message||t),"number"==typeof e.length&&e.length>n.maxBlobLength)return r("File length too large for Blob URL approach: %d (max: %d)",e.length,n.maxBlobLength),T(new Error("File length too large for Blob URL approach: "+e.length+" (max: "+n.maxBlobLength+")"));v.removeEventListener("error",d),v.removeEventListener("canplay",S),f()}function m(){v||(v=t(i),v.addEventListener("progress",function(){g=v.currentTime}))}y?u.indexOf(h)>=0?s():a():f()}function _(){v=t("audio"),w(e,function(e,t){if(e)return T(e);v.addEventListener("error",T),v.addEventListener("loadstart",k),v.addEventListener("canplay",S),v.src=t})}function k(){v.removeEventListener("loadstart",k),n.autoplay&&v.play()}function S(){v.removeEventListener("canplay",S),a(null,v)}function x(){v=t("img"),w(e,function(t,n){if(t)return T(t);v.src=n,v.alt=e.name,a(null,v)})}function C(){w(e,function(e,n){if(e)return T(e);".pdf"!==h?(v=t("iframe"),v.sandbox="allow-forms allow-scripts",v.src=n):(v=t("object"),v.setAttribute("typemustmatch",!0),v.setAttribute("type","application/pdf"),v.setAttribute("data",n)),a(null,v)})}function A(){r('Unknown file extension "%s" - will attempt to render into iframe',h);var t="";function n(){i(t)?(r('File extension "%s" appears ascii, so will render.',h),C()):(r('File extension "%s" appears non-ascii, will not render.',h),a(new Error('Unsupported file type "'+h+'": Cannot append to DOM')))}e.createReadStream({start:0,end:1e3}).setEncoding("utf8").on("data",function(e){t+=e}).on("end",n).on("error",a)}function T(t){t.message='Error rendering file "'+e.name+'": '+t.message,r(t.message),a(t)}f.indexOf(h)>=0?b():p.indexOf(h)>=0?_():d.indexOf(h)>=0?x():m.indexOf(h)>=0?C():A()}function w(e,n){var r=s.extname(e.name).toLowerCase();a(e.createReadStream(),t.mime[r],n)}function k(e){if(null==e)throw new Error("file cannot be null or undefined");if("string"!=typeof e.name)throw new Error("missing or invalid file.name property");if("function"!=typeof e.createReadStream)throw new Error("missing or invalid file.createReadStream property")}function E(e){var t=s.extname(e).toLowerCase();return{".m4a":'audio/mp4; codecs="mp4a.40.5"',".m4v":'video/mp4; codecs="avc1.640029, mp4a.40.5"',".mkv":'video/webm; codecs="avc1.640029, mp4a.40.5"',".mp3":"audio/mpeg",".mp4":'video/mp4; codecs="avc1.640029, mp4a.40.5"',".webm":'video/webm; codecs="vorbis, vp8"'}[t]}function S(e){null==e.autoplay&&(e.autoplay=!1),null==e.muted&&(e.muted=!1),null==e.controls&&(e.controls=!0),null==e.maxBlobLength&&(e.maxBlobLength=g)}},function(e){e.exports={".3gp":"video/3gpp",".aac":"audio/aac",".aif":"audio/x-aiff",".aiff":"audio/x-aiff",".atom":"application/atom+xml",".avi":"video/x-msvideo",".bmp":"image/bmp",".bz2":"application/x-bzip2",".conf":"text/plain",".css":"text/css",".csv":"text/plain",".diff":"text/x-diff",".doc":"application/msword",".flv":"video/x-flv",".gif":"image/gif",".gz":"application/x-gzip",".htm":"text/html",".html":"text/html",".ico":"image/vnd.microsoft.icon",".ics":"text/calendar",".iso":"application/octet-stream",".jar":"application/java-archive",".jpeg":"image/jpeg",".jpg":"image/jpeg",".js":"application/javascript",".json":"application/json",".less":"text/css",".log":"text/plain",".m3u":"audio/x-mpegurl",".m4a":"audio/mp4",".m4v":"video/mp4",".manifest":"text/cache-manifest",".markdown":"text/x-markdown",".mathml":"application/mathml+xml",".md":"text/x-markdown",".mid":"audio/midi",".midi":"audio/midi",".mov":"video/quicktime",".mp3":"audio/mpeg",".mp4":"video/mp4",".mp4v":"video/mp4",".mpeg":"video/mpeg",".mpg":"video/mpeg",".odp":"application/vnd.oasis.opendocument.presentation",".ods":"application/vnd.oasis.opendocument.spreadsheet",".odt":"application/vnd.oasis.opendocument.text",".oga":"audio/ogg",".ogg":"application/ogg",".pdf":"application/pdf",".png":"image/png",".pps":"application/vnd.ms-powerpoint",".ppt":"application/vnd.ms-powerpoint",".ps":"application/postscript",".psd":"image/vnd.adobe.photoshop",".qt":"video/quicktime",".rar":"application/x-rar-compressed",".rdf":"application/rdf+xml",".rss":"application/rss+xml",".rtf":"application/rtf",".svg":"image/svg+xml",".svgz":"image/svg+xml",".swf":"application/x-shockwave-flash",".tar":"application/x-tar",".tbz":"application/x-bzip-compressed-tar",".text":"text/plain",".tif":"image/tiff",".tiff":"image/tiff",".torrent":"application/x-bittorrent",".ttf":"application/x-font-ttf",".txt":"text/plain",".wav":"audio/wav",".webm":"video/webm",".wma":"audio/x-ms-wma",".wmv":"video/x-ms-wmv",".xls":"application/vnd.ms-excel",".xml":"application/xml",".yaml":"text/yaml",".yml":"text/yaml",".zip":"application/zip"}},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1601)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t){var n=127;e.exports=function e(t){for(var n=0,r=t.length;n<r;++n)if(t.charCodeAt(n)>127)return!1;return!0}},function(e,t,n){var r=n(587),i=n(53),o=n(1604);function s(e,t,n){var i=this;if(!(this instanceof s))return new s(e,t,n);n=n||{},i.detailedError=null,i._elem=t,i._elemWrapper=new r(t),i._waitingFired=!1,i._trackMeta=null,i._file=e,i._tracks=null,"none"!==i._elem.preload&&i._createMuxer(),i._onError=function(e){i.detailedError=i._elemWrapper.detailedError,i.destroy()},i._onWaiting=function(){i._waitingFired=!0,i._muxer?i._tracks&&i._pump():i._createMuxer()},i._elem.autoplay&&(i._elem.preload="auto"),i._elem.addEventListener("waiting",i._onWaiting),i._elem.addEventListener("error",i._onError)}e.exports=s,s.prototype._createMuxer=function(){var e=this;e._muxer=new o(e._file),e._muxer.on("ready",function(t){e._tracks=t.map(function(t){var n=e._elemWrapper.createWriteStream(t.mime);n.on("error",function(t){e._elemWrapper.error(t)});var r={muxed:null,mediaSource:n,initFlushed:!1,onInitFlushed:null};return n.write(t.init,function(e){r.initFlushed=!0,r.onInitFlushed&&r.onInitFlushed(e)}),r}),(e._waitingFired||"auto"===e._elem.preload)&&e._pump()}),e._muxer.on("error",function(t){e._elemWrapper.error(t)})},s.prototype._pump=function(){var e=this,t=e._muxer.seek(e._elem.currentTime,!e._tracks);e._tracks.forEach(function(n,r){var o=function(){n.muxed&&(n.muxed.destroy(),n.mediaSource=e._elemWrapper.createWriteStream(n.mediaSource),n.mediaSource.on("error",function(t){e._elemWrapper.error(t)})),n.muxed=t[r],i(n.muxed,n.mediaSource)};n.initFlushed?o():n.onInitFlushed=function(t){t?e._elemWrapper.error(t):o()}})},s.prototype.destroy=function(){var e=this;this.destroyed||(this.destroyed=!0,this._elem.removeEventListener("waiting",this._onWaiting),this._elem.removeEventListener("error",this._onError),this._tracks&&this._tracks.forEach(function(e){e.muxed&&e.muxed.destroy()}),this._elem.src="")}},function(e,t,n){(function(t){var r=n(1605),i=n(6).EventEmitter,o=n(1),s=n(1606),a=n(234),l=n(1616);function u(e){var t=this;i.call(this),this._tracks=[],this._fragmentSequence=1,this._file=e,this._decoder=null,this._findMoov(0)}function c(e,t){var n=this;this._entries=e,this._countName=t||"count",this._index=0,this._offset=0,this.value=this._entries[0]}function h(){return{version:0,flags:0,entries:[]}}e.exports=u,o(u,i),u.prototype._findMoov=function(e){var t=this;t._decoder&&t._decoder.destroy(),t._decoder=s.decode();var n=t._file.createReadStream({start:e});n.pipe(t._decoder),t._decoder.once("box",function(r){"moov"===r.type?t._decoder.decode(function(e){n.destroy();try{t._processMoov(e)}catch(e){e.message="Cannot parse mp4 file: "+e.message,t.emit("error",e)}}):(n.destroy(),t._findMoov(e+r.length))})},c.prototype.inc=function(){var e=this;this._offset++,this._offset>=this._entries[this._index][this._countName]&&(this._index++,this._offset=0),this.value=this._entries[this._index]},u.prototype._processMoov=function(e){var n=this,r=e.traks;this._tracks=[],this._hasVideo=!1,this._hasAudio=!1;for(var i=0;i<r.length;i++){var o=r[i],s=o.mdia.minf.stbl,l=s.stsd.entries[0],u=o.mdia.hdlr.handlerType,h,f;if("vide"===u&&"avc1"===l.type){if(this._hasVideo)continue;this._hasVideo=!0,h="avc1",l.avcC&&(h+="."+l.avcC.mimeCodec),f='video/mp4; codecs="'+h+'"'}else{if("soun"!==u||"mp4a"!==l.type)continue;if(this._hasAudio)continue;this._hasAudio=!0,h="mp4a",l.esds&&l.esds.mimeCodec&&(h+="."+l.esds.mimeCodec),f='audio/mp4; codecs="'+h+'"'}var p=[],d=0,m=0,g=0,y=0,v=0,b=0,_=new c(s.stts.entries),w=null;s.ctts&&(w=new c(s.ctts.entries));for(var k=0;;){var E=s.stsc.entries[v],S=s.stsz.entries[d],x=_.value.duration,C=w?w.value.compositionOffset:0,A=!0;s.stss&&(A=s.stss.entries[k]===d+1);var T=s.stco||s.co64;if(p.push({size:S,duration:x,dts:b,presentationOffset:C,sync:A,offset:y+T.entries[g]}),d++,d>=s.stsz.entries.length)break;if(m++,y+=S,m>=E.samplesPerChunk){m=0,y=0,g++;var I=s.stsc.entries[v+1];I&&g+1>=I.firstChunk&&v++}b+=x,_.inc(),w&&w.inc(),A&&k++}o.mdia.mdhd.duration=0,o.tkhd.duration=0;var j=E.sampleDescriptionId,R={type:"moov",mvhd:e.mvhd,traks:[{tkhd:o.tkhd,mdia:{mdhd:o.mdia.mdhd,hdlr:o.mdia.hdlr,elng:o.mdia.elng,minf:{vmhd:o.mdia.minf.vmhd,smhd:o.mdia.minf.smhd,dinf:o.mdia.minf.dinf,stbl:{stsd:s.stsd,stts:{version:0,flags:0,entries:[]},ctts:{version:0,flags:0,entries:[]},stsc:{version:0,flags:0,entries:[]},stsz:{version:0,flags:0,entries:[]},stco:{version:0,flags:0,entries:[]},stss:{version:0,flags:0,entries:[]}}}}}],mvex:{mehd:{fragmentDuration:e.mvhd.duration},trexs:[{trackId:o.tkhd.trackId,defaultSampleDescriptionIndex:j,defaultSampleDuration:0,defaultSampleSize:0,defaultSampleFlags:0}]}};this._tracks.push({trackId:o.tkhd.trackId,timeScale:o.mdia.mdhd.timeScale,samples:p,currSample:null,currTime:null,moov:R,mime:f})}if(0!==this._tracks.length){e.mvhd.duration=0,this._ftyp={type:"ftyp",brand:"iso5",brandVersion:0,compatibleBrands:["iso5"]};var B=a.encode(this._ftyp),O=this._tracks.map(function(e){var n=a.encode(e.moov);return{mime:e.mime,init:t.concat([B,n])}});this.emit("ready",O)}else this.emit("error",new Error("no playable tracks"))},u.prototype.seek=function(e){var t=this;if(!t._tracks)throw new Error("Not ready yet; wait for 'ready' event");t._fileStream&&(t._fileStream.destroy(),t._fileStream=null);var n=-1;if(t._tracks.map(function(r,i){r.outStream&&r.outStream.destroy(),r.inStream&&(r.inStream.destroy(),r.inStream=null);var o=r.outStream=s.encode(),a=t._generateFragment(i,e);if(!a)return o.finalize();function l(e){o.destroyed||o.box(e.moof,function(n){if(n)return t.emit("error",n);if(!o.destroyed){var s=r.inStream.slice(e.ranges);s.pipe(o.mediaData(e.length,function(e){if(e)return t.emit("error",e);if(!o.destroyed){var n=t._generateFragment(i);if(!n)return o.finalize();l(n)}}))}})}(-1===n||a.ranges[0].start<n)&&(n=a.ranges[0].start),l(a)}),n>=0){var r=t._fileStream=t._file.createReadStream({start:n});t._tracks.forEach(function(e){e.inStream=new l(n,{highWaterMark:1e7}),r.pipe(e.inStream)})}return t._tracks.map(function(e){return e.outStream})},u.prototype._findSampleBefore=function(e,t){var n=this,i=this._tracks[e],o=Math.floor(i.timeScale*t),s=r(i.samples,o,function(e,t){var n=e.dts+e.presentationOffset;return n-t});for(-1===s?s=0:s<0&&(s=-s-2);!i.samples[s].sync;)s--;return s};var f=1;u.prototype._generateFragment=function(e,t){var n=this,r=this._tracks[e],i;if(i=void 0!==t?this._findSampleBefore(e,t):r.currSample,i>=r.samples.length)return null;for(var o=r.samples[i].dts,s=0,a=[],l=i;l<r.samples.length;l++){var u=r.samples[l];if(u.sync&&u.dts-o>=1*r.timeScale)break;s+=u.size;var c=a.length-1;c<0||a[c].end!==u.offset?a.push({start:u.offset,end:u.offset+u.size}):a[c].end+=u.size}return r.currSample=l,{moof:this._generateMoof(e,i,l),ranges:a,length:s}},u.prototype._generateMoof=function(e,t,n){for(var r=this,i=this._tracks[e],o=[],s=0,l=t;l<n;l++){var u=i.samples[l];u.presentationOffset<0&&(s=1),o.push({sampleDuration:u.duration,sampleSize:u.size,sampleFlags:u.sync?33554432:16842752,sampleCompositionTimeOffset:u.presentationOffset})}var c={type:"moof",mfhd:{sequenceNumber:this._fragmentSequence++},trafs:[{tfhd:{flags:131072,trackId:i.trackId},tfdt:{baseMediaDecodeTime:i.samples[t].dts},trun:{flags:3841,dataOffset:8,entries:o,version:s}}]};return c.trafs[0].trun.dataOffset+=a.encodingLength(c),c}}).call(this,n(0).Buffer)},function(e,t){e.exports=function(e,t,n,r,i){var o,s;if(void 0===r)r=0;else if(r|=0,r<0||r>=e.length)throw new RangeError("invalid lower bound");if(void 0===i)i=e.length-1;else if(i|=0,i<r||i>=e.length)throw new RangeError("invalid upper bound");for(;r<=i;)if(o=r+(i-r>>1),s=+n(e[o],t,o,e),s<0)r=o+1;else{if(!(s>0))return o;i=o-1}return~r}},function(e,t,n){t.decode=n(1607),t.encode=n(1615)},function(e,t,n){(function(t){var r=n(590),i=n(1),o=n(1612),s=n(234),a=n(105),l=a(0);function u(){if(!(this instanceof u))return new u;r.Writable.call(this),this.destroyed=!1,this._pending=0,this._missing=0,this._buf=null,this._str=null,this._cb=null,this._ondrain=null,this._writeBuffer=null,this._writeCb=null,this._ondrain=null,this._kick()}function c(e){this._parent=e,this.destroyed=!1,r.PassThrough.call(this)}e.exports=u,i(u,r.Writable),u.prototype.destroy=function(e){this.destroyed||(this.destroyed=!0,e&&this.emit("error",e),this.emit("close"))},u.prototype._write=function(e,t,n){if(!this.destroyed){for(var r=!this._str||!this._str._writableState.needDrain;e.length&&!this.destroyed;){if(!this._missing)return this._writeBuffer=e,void(this._writeCb=n);var i=e.length<this._missing?e.length:this._missing;if(this._buf?e.copy(this._buf,this._buf.length-this._missing):this._str&&(r=this._str.write(i===e.length?e:e.slice(0,i))),this._missing-=i,!this._missing){var o=this._buf,s=this._cb,a=this._str;this._buf=this._cb=this._str=this._ondrain=null,r=!0,a&&a.end(),s&&s(o)}e=i===e.length?l:e.slice(i)}if(this._pending&&!this._missing)return this._writeBuffer=e,void(this._writeCb=n);r?n():this._ondrain(n)}},u.prototype._buffer=function(e,t){this._missing=e,this._buf=a(e),this._cb=t},u.prototype._stream=function(e,t){var n=this;return this._missing=e,this._str=new c(this),this._ondrain=o(this._str,"drain"),this._pending++,this._str.on("end",function(){n._pending--,n._kick()}),this._cb=t,this._str},u.prototype._readBox=function(){var e=this;function n(r,i){e._buffer(r,function(r){i=i?t.concat([i,r]):r;var o=s.readHeaders(i);"number"==typeof o?n(o-i.length,i):(e._pending++,e._headers=o,e.emit("box",o))})}n(8)},u.prototype.stream=function(){var e=this;if(!this._headers)throw new Error("this function can only be called once after 'box' is emitted");var t=this._headers;return this._headers=null,this._stream(t.contentLen,null)},u.prototype.decode=function(e){var t=this;if(!t._headers)throw new Error("this function can only be called once after 'box' is emitted");var n=t._headers;t._headers=null,t._buffer(n.contentLen,function(r){var i=s.decodeWithoutHeaders(n,r);e(i),t._pending--,t._kick()})},u.prototype.ignore=function(){var e=this;if(!e._headers)throw new Error("this function can only be called once after 'box' is emitted");var t=e._headers;e._headers=null,this._missing=t.contentLen,this._cb=function(){e._pending--,e._kick()}},u.prototype._kick=function(){if(!this._pending&&(this._buf||this._str||this._readBox(),this._writeBuffer)){var e=this._writeCb,t=this._writeBuffer;this._writeBuffer=null,this._writeCb=null,this._write(t,null,e)}},i(c,r.PassThrough),c.prototype.destroy=function(e){this.destroyed||(this.destroyed=!0,this._parent.destroy(e),e&&this.emit("error",e),this.emit("close"))}}).call(this,n(0).Buffer)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1610);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(595),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t){function n(e,t){var n=null;return e.on(t,function(e){if(n){var t=n;n=null,t(e)}}),function(e){n=e}}e.exports=n},function(e,t,n){var r=n(234),i=n(1614),o=n(105),s=n(310),a=n(596),l=20828448e5;t.fullBoxes={};var u=["mvhd","tkhd","mdhd","vmhd","smhd","stsd","esds","stsz","stco","co64","stss","stts","ctts","stsc","dref","elst","hdlr","mehd","trex","mfhd","tfhd","tfdt","trun"];function c(e,t,n){for(var r=t;r<n;r++)e[r]=0}function h(e,t,n){t.writeUInt32BE(Math.floor((e.getTime()+l)/1e3),n)}function f(e,t,n){t.writeUIntBE(Math.floor((e.getTime()+l)/1e3),n,6)}function p(e,t,n){t.writeUInt16BE(Math.floor(e)%65536,n),t.writeUInt16BE(Math.floor(256*e*256)%65536,n+2)}function d(e,t,n){t[n]=Math.floor(e)%256,t[n+1]=Math.floor(256*e)%256}function m(e,t,n){e||(e=[0,0,0,0,0,0,0,0,0]);for(var r=0;r<e.length;r++)p(e[r],t,n+4*r)}function g(e,t,n){var r=s(e,"utf8");r.copy(t,n),t[n+r.length]=0}function y(e){for(var t=new Array(e.length/4),n=0;n<t.length;n++)t[n]=_(e,4*n);return t}function v(e,t){return new Date(1e3*e.readUIntBE(t,6)-l)}function b(e,t){return new Date(1e3*e.readUInt32BE(t)-l)}function _(e,t){return e.readUInt16BE(t)+e.readUInt16BE(t+2)/65536}function w(e,t){return e[t]+e[t+1]/256}function k(e,t,n){var r;for(r=0;r<n&&0!==e[t+r];r++);return e.toString("utf8",t,t+r)}u.forEach(function(e){t.fullBoxes[e]=!0}),t.ftyp={},t.ftyp.encode=function(e,n,r){n=n?n.slice(r):o(t.ftyp.encodingLength(e));var i=e.compatibleBrands||[];n.write(e.brand,0,4,"ascii"),n.writeUInt32BE(e.brandVersion,4);for(var s=0;s<i.length;s++)n.write(i[s],8+4*s,4,"ascii");return t.ftyp.encode.bytes=8+4*i.length,n},t.ftyp.decode=function(e,t){e=e.slice(t);for(var n=e.toString("ascii",0,4),r=e.readUInt32BE(4),i=[],o=8;o<e.length;o+=4)i.push(e.toString("ascii",o,o+4));return{brand:n,brandVersion:r,compatibleBrands:i}},t.ftyp.encodingLength=function(e){return 8+4*(e.compatibleBrands||[]).length},t.mvhd={},t.mvhd.encode=function(e,n,r){return n=n?n.slice(r):o(96),h(e.ctime||new Date,n,0),h(e.mtime||new Date,n,4),n.writeUInt32BE(e.timeScale||0,8),n.writeUInt32BE(e.duration||0,12),p(e.preferredRate||0,n,16),d(e.preferredVolume||0,n,20),c(n,22,32),m(e.matrix,n,32),n.writeUInt32BE(e.previewTime||0,68),n.writeUInt32BE(e.previewDuration||0,72),n.writeUInt32BE(e.posterTime||0,76),n.writeUInt32BE(e.selectionTime||0,80),n.writeUInt32BE(e.selectionDuration||0,84),n.writeUInt32BE(e.currentTime||0,88),n.writeUInt32BE(e.nextTrackId||0,92),t.mvhd.encode.bytes=96,n},t.mvhd.decode=function(e,t){return e=e.slice(t),{ctime:b(e,0),mtime:b(e,4),timeScale:e.readUInt32BE(8),duration:e.readUInt32BE(12),preferredRate:_(e,16),preferredVolume:w(e,20),matrix:y(e.slice(32,68)),previewTime:e.readUInt32BE(68),previewDuration:e.readUInt32BE(72),posterTime:e.readUInt32BE(76),selectionTime:e.readUInt32BE(80),selectionDuration:e.readUInt32BE(84),currentTime:e.readUInt32BE(88),nextTrackId:e.readUInt32BE(92)}},t.mvhd.encodingLength=function(e){return 96},t.tkhd={},t.tkhd.encode=function(e,n,r){return n=n?n.slice(r):o(80),h(e.ctime||new Date,n,0),h(e.mtime||new Date,n,4),n.writeUInt32BE(e.trackId||0,8),c(n,12,16),n.writeUInt32BE(e.duration||0,16),c(n,20,28),n.writeUInt16BE(e.layer||0,28),n.writeUInt16BE(e.alternateGroup||0,30),n.writeUInt16BE(e.volume||0,32),m(e.matrix,n,36),n.writeUInt32BE(e.trackWidth||0,72),n.writeUInt32BE(e.trackHeight||0,76),t.tkhd.encode.bytes=80,n},t.tkhd.decode=function(e,t){return e=e.slice(t),{ctime:b(e,0),mtime:b(e,4),trackId:e.readUInt32BE(8),duration:e.readUInt32BE(16),layer:e.readUInt16BE(28),alternateGroup:e.readUInt16BE(30),volume:e.readUInt16BE(32),matrix:y(e.slice(36,72)),trackWidth:e.readUInt32BE(72),trackHeight:e.readUInt32BE(76)}},t.tkhd.encodingLength=function(e){return 80},t.mdhd={},t.mdhd.encode=function(e,n,r){return 1===e.version?(n=n?n.slice(r):o(32),f(e.ctime||new Date,n,0),f(e.mtime||new Date,n,8),n.writeUInt32BE(e.timeScale||0,16),n.writeUIntBE(e.duration||0,20,6),n.writeUInt16BE(e.language||0,28),n.writeUInt16BE(e.quality||0,30),t.mdhd.encode.bytes=32,n):(n=n?n.slice(r):o(20),h(e.ctime||new Date,n,0),h(e.mtime||new Date,n,4),n.writeUInt32BE(e.timeScale||0,8),n.writeUInt32BE(e.duration||0,12),n.writeUInt16BE(e.language||0,16),n.writeUInt16BE(e.quality||0,18),t.mdhd.encode.bytes=20,n)},t.mdhd.decode=function(e,t,n){e=e.slice(t);var r=n-t!=20;return r?{ctime:v(e,0),mtime:v(e,8),timeScale:e.readUInt32BE(16),duration:e.readUIntBE(20,6),language:e.readUInt16BE(28),quality:e.readUInt16BE(30)}:{ctime:b(e,0),mtime:b(e,4),timeScale:e.readUInt32BE(8),duration:e.readUInt32BE(12),language:e.readUInt16BE(16),quality:e.readUInt16BE(18)}},t.mdhd.encodingLength=function(e){return 1===e.version?32:20},t.vmhd={},t.vmhd.encode=function(e,n,r){n=n?n.slice(r):o(8),n.writeUInt16BE(e.graphicsMode||0,0);var i=e.opcolor||[0,0,0];return n.writeUInt16BE(i[0],2),n.writeUInt16BE(i[1],4),n.writeUInt16BE(i[2],6),t.vmhd.encode.bytes=8,n},t.vmhd.decode=function(e,t){return e=e.slice(t),{graphicsMode:e.readUInt16BE(0),opcolor:[e.readUInt16BE(2),e.readUInt16BE(4),e.readUInt16BE(6)]}},t.vmhd.encodingLength=function(e){return 8},t.smhd={},t.smhd.encode=function(e,n,r){return n=n?n.slice(r):o(4),n.writeUInt16BE(e.balance||0,0),c(n,2,4),t.smhd.encode.bytes=4,n},t.smhd.decode=function(e,t){return e=e.slice(t),{balance:e.readUInt16BE(0)}},t.smhd.encodingLength=function(e){return 4},t.stsd={},t.stsd.encode=function(e,n,i){n=n?n.slice(i):o(t.stsd.encodingLength(e));var s=e.entries||[];n.writeUInt32BE(s.length,0);for(var a=4,l=0;l<s.length;l++){var u=s[l];r.encode(u,n,a),a+=r.encode.bytes}return t.stsd.encode.bytes=a,n},t.stsd.decode=function(e,t,n){e=e.slice(t);for(var i=e.readUInt32BE(0),o=new Array(i),s=4,a=0;a<i;a++){var l=r.decode(e,s,n);o[a]=l,s+=l.length}return{entries:o}},t.stsd.encodingLength=function(e){var t=4;if(!e.entries)return t;for(var n=0;n<e.entries.length;n++)t+=r.encodingLength(e.entries[n]);return t},t.avc1=t.VisualSampleEntry={},t.VisualSampleEntry.encode=function(e,n,i){n=n?n.slice(i):o(t.VisualSampleEntry.encodingLength(e)),c(n,0,6),n.writeUInt16BE(e.dataReferenceIndex||0,6),c(n,8,24),n.writeUInt16BE(e.width||0,24),n.writeUInt16BE(e.height||0,26),n.writeUInt32BE(e.hResolution||4718592,28),n.writeUInt32BE(e.vResolution||4718592,32),c(n,36,40),n.writeUInt16BE(e.frameCount||1,40);var s=e.compressorName||"",a=Math.min(s.length,31);n.writeUInt8(a,42),n.write(s,43,a,"utf8"),n.writeUInt16BE(e.depth||24,74),n.writeInt16BE(-1,76);var l=78,u=e.children||[];u.forEach(function(e){r.encode(e,n,l),l+=r.encode.bytes}),t.VisualSampleEntry.encode.bytes=l},t.VisualSampleEntry.decode=function(e,t,n){e=e.slice(t);for(var i=n-t,o=Math.min(e.readUInt8(42),31),s={dataReferenceIndex:e.readUInt16BE(6),width:e.readUInt16BE(24),height:e.readUInt16BE(26),hResolution:e.readUInt32BE(28),vResolution:e.readUInt32BE(32),frameCount:e.readUInt16BE(40),compressorName:e.toString("utf8",43,43+o),depth:e.readUInt16BE(74),children:[]},a=78;i-a>=8;){var l=r.decode(e,a,i);s.children.push(l),s[l.type]=l,a+=l.length}return s},t.VisualSampleEntry.encodingLength=function(e){var t=78,n=e.children||[];return n.forEach(function(e){t+=r.encodingLength(e)}),t},t.avcC={},t.avcC.encode=function(e,n,r){n=n?n.slice(r):o(e.buffer.length),e.buffer.copy(n),t.avcC.encode.bytes=e.buffer.length},t.avcC.decode=function(e,t,n){return e=e.slice(t,n),{mimeCodec:e.toString("hex",1,4),buffer:s(e)}},t.avcC.encodingLength=function(e){return e.buffer.length},t.mp4a=t.AudioSampleEntry={},t.AudioSampleEntry.encode=function(e,n,i){n=n?n.slice(i):o(t.AudioSampleEntry.encodingLength(e)),c(n,0,6),n.writeUInt16BE(e.dataReferenceIndex||0,6),c(n,8,16),n.writeUInt16BE(e.channelCount||2,16),n.writeUInt16BE(e.sampleSize||16,18),c(n,20,24),n.writeUInt32BE(e.sampleRate||0,24);var s=28,a=e.children||[];a.forEach(function(e){r.encode(e,n,s),s+=r.encode.bytes}),t.AudioSampleEntry.encode.bytes=s},t.AudioSampleEntry.decode=function(e,t,n){e=e.slice(t,n);for(var i=n-t,o={dataReferenceIndex:e.readUInt16BE(6),channelCount:e.readUInt16BE(16),sampleSize:e.readUInt16BE(18),sampleRate:e.readUInt32BE(24),children:[]},s=28;i-s>=8;){var a=r.decode(e,s,i);o.children.push(a),o[a.type]=a,s+=a.length}return o},t.AudioSampleEntry.encodingLength=function(e){var t=28,n=e.children||[];return n.forEach(function(e){t+=r.encodingLength(e)}),t},t.esds={},t.esds.encode=function(e,n,r){n=n?n.slice(r):o(e.buffer.length),e.buffer.copy(n,0),t.esds.encode.bytes=e.buffer.length},t.esds.decode=function(e,t,n){e=e.slice(t,n);var r=i.Descriptor.decode(e,0,e.length),o="ESDescriptor"===r.tagName?r:{},a=o.DecoderConfigDescriptor||{},l=a.oti||0,u=a.DecoderSpecificInfo,c=u?(248&u.buffer.readUInt8(0))>>3:0,h=null;return l&&(h=l.toString(16),c&&(h+="."+c)),{mimeCodec:h,buffer:s(e.slice(0))}},t.esds.encodingLength=function(e){return e.buffer.length},t.stsz={},t.stsz.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.stsz.encodingLength(e)),n.writeUInt32BE(0,0),n.writeUInt32BE(i.length,4);for(var s=0;s<i.length;s++)n.writeUInt32BE(i[s],4*s+8);return t.stsz.encode.bytes=8+4*i.length,n},t.stsz.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=e.readUInt32BE(4),i=new Array(r),o=0;o<r;o++)i[o]=0===n?e.readUInt32BE(4*o+8):n;return{entries:i}},t.stsz.encodingLength=function(e){return 8+4*e.entries.length},t.stss=t.stco={},t.stco.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.stco.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++)n.writeUInt32BE(i[s],4*s+4);return t.stco.encode.bytes=4+4*i.length,n},t.stco.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++)r[i]=e.readUInt32BE(4*i+4);return{entries:r}},t.stco.encodingLength=function(e){return 4+4*e.entries.length},t.co64={},t.co64.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.co64.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++)a.encode(i[s],n,8*s+4);return t.co64.encode.bytes=4+8*i.length,n},t.co64.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++)r[i]=a.decode(e,8*i+4);return{entries:r}},t.co64.encodingLength=function(e){return 4+8*e.entries.length},t.stts={},t.stts.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.stts.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++){var a=8*s+4;n.writeUInt32BE(i[s].count||0,a),n.writeUInt32BE(i[s].duration||0,a+4)}return t.stts.encode.bytes=4+8*e.entries.length,n},t.stts.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++){var o=8*i+4;r[i]={count:e.readUInt32BE(o),duration:e.readUInt32BE(o+4)}}return{entries:r}},t.stts.encodingLength=function(e){return 4+8*e.entries.length},t.ctts={},t.ctts.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.ctts.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++){var a=8*s+4;n.writeUInt32BE(i[s].count||0,a),n.writeUInt32BE(i[s].compositionOffset||0,a+4)}return t.ctts.encode.bytes=4+8*i.length,n},t.ctts.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++){var o=8*i+4;r[i]={count:e.readUInt32BE(o),compositionOffset:e.readInt32BE(o+4)}}return{entries:r}},t.ctts.encodingLength=function(e){return 4+8*e.entries.length},t.stsc={},t.stsc.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.stsc.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++){var a=12*s+4;n.writeUInt32BE(i[s].firstChunk||0,a),n.writeUInt32BE(i[s].samplesPerChunk||0,a+4),n.writeUInt32BE(i[s].sampleDescriptionId||0,a+8)}return t.stsc.encode.bytes=4+12*i.length,n},t.stsc.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++){var o=12*i+4;r[i]={firstChunk:e.readUInt32BE(o),samplesPerChunk:e.readUInt32BE(o+4),sampleDescriptionId:e.readUInt32BE(o+8)}}return{entries:r}},t.stsc.encodingLength=function(e){return 4+12*e.entries.length},t.dref={},t.dref.encode=function(e,n,r){n=n?n.slice(r):o(t.dref.encodingLength(e));var i=e.entries||[];n.writeUInt32BE(i.length,0);for(var s=4,a=0;a<i.length;a++){var l=i[a],u=(l.buf?l.buf.length:0)+4+4;n.writeUInt32BE(u,s),s+=4,n.write(l.type,s,4,"ascii"),s+=4,l.buf&&(l.buf.copy(n,s),s+=l.buf.length)}return t.dref.encode.bytes=s,n},t.dref.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=4,o=0;o<n;o++){var s=e.readUInt32BE(i),a=e.toString("ascii",i+4,i+8),l=e.slice(i+8,i+s);i+=s,r[o]={type:a,buf:l}}return{entries:r}},t.dref.encodingLength=function(e){var t=4;if(!e.entries)return t;for(var n=0;n<e.entries.length;n++){var r=e.entries[n].buf;t+=(r?r.length:0)+4+4}return t},t.elst={},t.elst.encode=function(e,n,r){var i=e.entries||[];n=n?n.slice(r):o(t.elst.encodingLength(e)),n.writeUInt32BE(i.length,0);for(var s=0;s<i.length;s++){var a=12*s+4;n.writeUInt32BE(i[s].trackDuration||0,a),n.writeUInt32BE(i[s].mediaTime||0,a+4),p(i[s].mediaRate||0,n,a+8)}return t.elst.encode.bytes=4+12*i.length,n},t.elst.decode=function(e,t){e=e.slice(t);for(var n=e.readUInt32BE(0),r=new Array(n),i=0;i<n;i++){var o=12*i+4;r[i]={trackDuration:e.readUInt32BE(o),mediaTime:e.readInt32BE(o+4),mediaRate:_(e,o+8)}}return{entries:r}},t.elst.encodingLength=function(e){return 4+12*e.entries.length},t.hdlr={},t.hdlr.encode=function(e,n,r){n=n?n.slice(r):o(t.hdlr.encodingLength(e));var i=21+(e.name||"").length;return n.fill(0,0,i),n.write(e.handlerType||"",4,4,"ascii"),g(e.name||"",n,20),t.hdlr.encode.bytes=i,n},t.hdlr.decode=function(e,t,n){return e=e.slice(t),{handlerType:e.toString("ascii",4,8),name:k(e,20,n)}},t.hdlr.encodingLength=function(e){return 21+(e.name||"").length},t.mehd={},t.mehd.encode=function(e,n,r){return n=n?n.slice(r):o(4),n.writeUInt32BE(e.fragmentDuration||0,0),t.mehd.encode.bytes=4,n},t.mehd.decode=function(e,t){return e=e.slice(t),{fragmentDuration:e.readUInt32BE(0)}},t.mehd.encodingLength=function(e){return 4},t.trex={},t.trex.encode=function(e,n,r){return n=n?n.slice(r):o(20),n.writeUInt32BE(e.trackId||0,0),n.writeUInt32BE(e.defaultSampleDescriptionIndex||0,4),n.writeUInt32BE(e.defaultSampleDuration||0,8),n.writeUInt32BE(e.defaultSampleSize||0,12),n.writeUInt32BE(e.defaultSampleFlags||0,16),t.trex.encode.bytes=20,n},t.trex.decode=function(e,t){return e=e.slice(t),{trackId:e.readUInt32BE(0),defaultSampleDescriptionIndex:e.readUInt32BE(4),defaultSampleDuration:e.readUInt32BE(8),defaultSampleSize:e.readUInt32BE(12),defaultSampleFlags:e.readUInt32BE(16)}},t.trex.encodingLength=function(e){return 20},t.mfhd={},t.mfhd.encode=function(e,n,r){return n=n?n.slice(r):o(4),n.writeUInt32BE(e.sequenceNumber||0,0),t.mfhd.encode.bytes=4,n},t.mfhd.decode=function(e,t){return{sequenceNumber:e.readUInt32BE(0)}},t.mfhd.encodingLength=function(e){return 4},t.tfhd={},t.tfhd.encode=function(e,n,r){return n=n?n.slice(r):o(4),n.writeUInt32BE(e.trackId,0),t.tfhd.encode.bytes=4,n},t.tfhd.decode=function(e,t){},t.tfhd.encodingLength=function(e){return 4},t.tfdt={},t.tfdt.encode=function(e,n,r){return n=n?n.slice(r):o(4),n.writeUInt32BE(e.baseMediaDecodeTime||0,0),t.tfdt.encode.bytes=4,n},t.tfdt.decode=function(e,t){},t.tfdt.encodingLength=function(e){return 4},t.trun={},t.trun.encode=function(e,n,r){n=n?n.slice(r):o(8+16*e.entries.length),n.writeUInt32BE(e.entries.length,0),n.writeInt32BE(e.dataOffset,4);for(var i=8,s=0;s<e.entries.length;s++){var a=e.entries[s];n.writeUInt32BE(a.sampleDuration,i),i+=4,n.writeUInt32BE(a.sampleSize,i),i+=4,n.writeUInt32BE(a.sampleFlags,i),i+=4,0===(e.version||0)?n.writeUInt32BE(a.sampleCompositionTimeOffset,i):n.writeInt32BE(a.sampleCompositionTimeOffset,i),i+=4}t.trun.encode.bytes=i},t.trun.decode=function(e,t){},t.trun.encodingLength=function(e){return 8+16*e.entries.length},t.mdat={},t.mdat.encode=function(e,n,r){e.buffer?(e.buffer.copy(n,r),t.mdat.encode.bytes=e.buffer.length):t.mdat.encode.bytes=t.mdat.encodingLength(e)},t.mdat.decode=function(e,t,n){return{buffer:s(e.slice(t,n))}},t.mdat.encodingLength=function(e){return e.buffer?e.buffer.length:e.contentLength}},function(e,t,n){var r=n(310),i={3:"ESDescriptor",4:"DecoderConfigDescriptor",5:"DecoderSpecificInfo",6:"SLConfigDescriptor"};t.Descriptor={},t.Descriptor.decode=function(e,n,o){var s=e.readUInt8(n),a=n+1,l,u=0,c;do{l=e.readUInt8(a++),u=u<<7|127&l}while(128&l);var h=i[s];return c=t[h]?t[h].decode(e,a,o):{buffer:r(e.slice(a,a+u))},c.tag=s,c.tagName=h,c.length=a-n+u,c.contentsLen=u,c},t.DescriptorArray={},t.DescriptorArray.decode=function(e,n,r){for(var o=n,s={};o+2<=r;){var a=t.Descriptor.decode(e,o,r);o+=a.length;var l=i[a.tag]||"Descriptor"+a.tag;s[l]=a}return s},t.ESDescriptor={},t.ESDescriptor.decode=function(e,n,r){var i=e.readUInt8(n+2),o=n+3;if(128&i&&(o+=2),64&i){var s=e.readUInt8(o);o+=s+1}return 32&i&&(o+=2),t.DescriptorArray.decode(e,o,r)},t.DecoderConfigDescriptor={},t.DecoderConfigDescriptor.decode=function(e,n,r){var i=e.readUInt8(n),o=t.DescriptorArray.decode(e,n+13,r);return o.oti=i,o}},function(e,t,n){(function(t){var r=n(590),i=n(1),o=n(234),s=n(105);function a(){}function l(){if(!(this instanceof l))return new l;r.Readable.call(this),this.destroyed=!1,this._reading=!1,this._stream=null,this._drain=null,this._want=!1,this._onreadable=t,this._onend=n;var e=this;function t(){e._want&&(e._want=!1,e._read())}function n(){e._stream=null}}function u(e){this._parent=e,this.destroyed=!1,r.PassThrough.call(this)}e.exports=l,i(l,r.Readable),l.prototype.mediaData=l.prototype.mdat=function(e,t){var n=new u(this);return this.box({type:"mdat",contentLength:e,encodeBufferLen:8,stream:n},t),n},l.prototype.box=function(e,n){if(n||(n=a),this.destroyed)return n(new Error("Encoder is destroyed"));var r;if(e.encodeBufferLen&&(r=s(e.encodeBufferLen)),e.stream)e.buffer=null,r=o.encode(e,r),this.push(r),this._stream=e.stream,this._stream.on("readable",this._onreadable),this._stream.on("end",this._onend),this._stream.on("end",n),this._forward();else{r=o.encode(e,r);var i=this.push(r);if(i)return t.nextTick(n);this._drain=n}},l.prototype.destroy=function(e){if(!this.destroyed){if(this.destroyed=!0,this._stream&&this._stream.destroy&&this._stream.destroy(),this._stream=null,this._drain){var t=this._drain;this._drain=null,t(e)}e&&this.emit("error",e),this.emit("close")}},l.prototype.finalize=function(){this.push(null)},l.prototype._forward=function(){if(this._stream)for(;!this.destroyed;){var e=this._stream.read();if(!e)return void(this._want=!!this._stream);if(!this.push(e))return}},l.prototype._read=function(){if(!this._reading&&!this.destroyed){if(this._reading=!0,this._stream&&this._forward(),this._drain){var e=this._drain;this._drain=null,e()}this._reading=!1}},i(u,r.PassThrough),u.prototype.destroy=function(e){this.destroyed||(this.destroyed=!0,this._parent.destroy(e),e&&this.emit("error",e),this.emit("close"))}}).call(this,n(3))},function(e,t,n){const{Writable:r,PassThrough:i}=n(17);class o extends r{constructor(e,t={}){super(t),this.destroyed=!1,this._queue=[],this._position=e||0,this._cb=null,this._buffer=null,this._out=null}_write(e,t,n){let r=!0;for(;;){if(this.destroyed)return;if(0===this._queue.length)return this._buffer=e,void(this._cb=n);this._buffer=null;var i=this._queue[0];const t=Math.max(i.start-this._position,0),o=i.end-this._position;if(t>=e.length)return this._position+=e.length,n(null);let s;if(o>e.length){this._position+=e.length,s=0===t?e:e.slice(t),r=i.stream.write(s)&&r;break}this._position+=o,s=0===t&&o===e.length?e:e.slice(t,o),r=i.stream.write(s)&&r,i.last&&i.stream.end(),e=e.slice(o),this._queue.shift()}r?n(null):i.stream.once("drain",n.bind(null,null))}slice(e){if(this.destroyed)return null;Array.isArray(e)||(e=[e]);const t=new i;return e.forEach((n,r)=>{this._queue.push({start:n.start,end:n.end,stream:t,last:r===e.length-1})}),this._buffer&&this._write(this._buffer,null,this._cb),t}destroy(e){this.destroyed||(this.destroyed=!0,e&&this.emit("error",e))}}e.exports=o},function(e,t,n){(function(t){var r=n(26);e.exports=function e(n,i,o){o=r(o);var s=t.alloc(i),a=0;n.on("data",function(e){e.copy(s,a),a+=e.length}).on("end",function(){o(null,s)}).on("error",o)}}).call(this,n(0).Buffer)},function(e,t,n){const r=n(4)("webtorrent:file-stream"),i=n(17);class o extends i.Readable{constructor(e,t){super(t),this.destroyed=!1,this._torrent=e._torrent;const n=t&&t.start||0,r=t&&t.end&&t.end<e.length?t.end:e.length-1,i=e._torrent.pieceLength;this._startPiece=(n+e.offset)/i|0,this._endPiece=(r+e.offset)/i|0,this._piece=this._startPiece,this._offset=n+e.offset-this._startPiece*i,this._missing=r-n+1,this._reading=!1,this._notifying=!1,this._criticalLength=Math.min(1048576/i|0,2)}_read(){this._reading||(this._reading=!0,this._notify())}_notify(){if(!this._reading||0===this._missing)return;if(!this._torrent.bitfield.get(this._piece))return this._torrent.critical(this._piece,this._piece+this._criticalLength);if(this._notifying)return;if(this._notifying=!0,this._torrent.destroyed)return this._destroy(new Error("Torrent removed"));const e=this._piece;this._torrent.store.get(e,(t,n)=>{if(this._notifying=!1,!this.destroyed){if(t)return this._destroy(t);r("read %s (length %s) (err %s)",e,n.length,t&&t.message),this._offset&&(n=n.slice(this._offset),this._offset=0),this._missing<n.length&&(n=n.slice(0,this._missing)),this._missing-=n.length,r("pushing buffer of length %s",n.length),this._reading=!1,this.push(n),0===this._missing&&this.push(null)}}),this._piece+=1}destroy(e){this._destroy(null,e)}_destroy(e,t){this.destroyed||(this.destroyed=!0,this._torrent.destroyed||this._torrent.deselect(this._startPiece,this._endPiece,!0),e&&this.emit("error",e),this.emit("close"),t&&t())}}e.exports=o},function(e,t,n){const r=n(597),i=n(4)("webtorrent:peer"),o=n(598),s=n(1627),a=5e3,l=25e3,u=25e3;t.createWebRTCPeer=((e,t)=>{const n=new c(e.id,"webrtc");return n.conn=e,n.swarm=t,n.conn.connected?n.onConnect():(n.conn.once("connect",()=>{n.onConnect()}),n.conn.once("error",e=>{n.destroy(e)}),n.startConnectTimeout()),n}),t.createTCPIncomingPeer=(e=>{const t=`${e.remoteAddress}:${e.remotePort}`,n=new c(t,"tcpIncoming");return n.conn=e,n.addr=t,n.onConnect(),n}),t.createTCPOutgoingPeer=((e,t)=>{const n=new c(e,"tcpOutgoing");return n.addr=e,n.swarm=t,n}),t.createWebSeedPeer=((e,t)=>{const n=new c(e,"webSeed");return n.swarm=t,n.conn=new s(e,t),n.onConnect(),n});class c{constructor(e,t){this.id=e,this.type=t,i("new %s Peer %s",t,e),this.addr=null,this.conn=null,this.swarm=null,this.wire=null,this.connected=!1,this.destroyed=!1,this.timeout=null,this.retries=0,this.sentHandshake=!1}onConnect(){if(this.destroyed)return;this.connected=!0,i("Peer %s connected",this.id),clearTimeout(this.connectTimeout);const e=this.conn;e.once("end",()=>{this.destroy()}),e.once("close",()=>{this.destroy()}),e.once("finish",()=>{this.destroy()}),e.once("error",e=>{this.destroy(e)});const t=this.wire=new o;t.type=this.type,t.once("end",()=>{this.destroy()}),t.once("close",()=>{this.destroy()}),t.once("finish",()=>{this.destroy()}),t.once("error",e=>{this.destroy(e)}),t.once("handshake",(e,t)=>{this.onHandshake(e,t)}),this.startHandshakeTimeout(),e.pipe(t).pipe(e),this.swarm&&!this.sentHandshake&&this.handshake()}onHandshake(e,t){if(!this.swarm)return;if(this.destroyed)return;if(this.swarm.destroyed)return this.destroy(new Error("swarm already destroyed"));if(e!==this.swarm.infoHash)return this.destroy(new Error("unexpected handshake info hash for this swarm"));if(t===this.swarm.peerId)return this.destroy(new Error("refusing to connect to ourselves"));i("Peer %s got handshake %s",this.id,e),clearTimeout(this.handshakeTimeout),this.retries=0;let n=this.addr;!n&&this.conn.remoteAddress&&this.conn.remotePort&&(n=`${this.conn.remoteAddress}:${this.conn.remotePort}`),this.swarm._onWire(this.wire,n),this.swarm&&!this.swarm.destroyed&&(this.sentHandshake||this.handshake())}handshake(){const e={dht:!this.swarm.private&&!!this.swarm.client.dht};this.wire.handshake(this.swarm.infoHash,this.swarm.client.peerId,e),this.sentHandshake=!0}startConnectTimeout(){clearTimeout(this.connectTimeout),this.connectTimeout=setTimeout(()=>{this.destroy(new Error("connect timeout"))},"webrtc"===this.type?l:a),this.connectTimeout.unref&&this.connectTimeout.unref()}startHandshakeTimeout(){clearTimeout(this.handshakeTimeout),this.handshakeTimeout=setTimeout(()=>{this.destroy(new Error("handshake timeout"))},u),this.handshakeTimeout.unref&&this.handshakeTimeout.unref()}destroy(e){if(this.destroyed)return;this.destroyed=!0,this.connected=!1,i("destroy %s (error: %s)",this.id,e&&(e.message||e)),clearTimeout(this.connectTimeout),clearTimeout(this.handshakeTimeout);const t=this.swarm,n=this.conn,o=this.wire;this.swarm=null,this.conn=null,this.wire=null,t&&o&&r(t.wires,t.wires.indexOf(o)),n&&(n.on("error",()=>{}),n.destroy()),o&&o.destroy(),t&&t.removePeer(this.id)}}},function(e,t,n){"use strict";(function(r){function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function e(t){return typeof t}:function e(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(e)}function o(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type&&!window.process.__nwjs)||("undefined"==typeof navigator||!navigator.userAgent||!navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))&&("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))}function s(t){if(t[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+t[0]+(this.useColors?"%c ":" ")+"+"+e.exports.humanize(this.diff),this.useColors){var n="color: "+this.color;t.splice(1,0,n,"color: inherit");var r=0,i=0;t[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(r++,"%c"===e&&(i=r))}),t.splice(i,0,n)}}function a(){var e;return"object"===("undefined"==typeof console?"undefined":i(console))&&console.log&&(e=console).log.apply(e,arguments)}function l(e){try{e?t.storage.setItem("debug",e):t.storage.removeItem("debug")}catch(e){}}function u(){var e;try{e=t.storage.getItem("debug")}catch(e){}return!e&&void 0!==r&&"env"in r&&(e=r.env.DEBUG),e}function c(){try{return localStorage}catch(e){}}t.log=a,t.formatArgs=s,t.save=l,t.load=u,t.useColors=o,t.storage=c(),t.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"],e.exports=n(1621)(t);var h=e.exports.formatters;h.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}}}).call(this,n(3))},function(e,t,n){"use strict";function r(e){function t(e){for(var t=0,n=0;n<e.length;n++)t=(t<<5)-t+e.charCodeAt(n),t|=0;return r.colors[Math.abs(t)%r.colors.length]}function r(e){var n;function s(){if(s.enabled){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];var o=s,a=Number(new Date),l=a-(n||a);o.diff=l,o.prev=n,o.curr=a,n=a,t[0]=r.coerce(t[0]),"string"!=typeof t[0]&&t.unshift("%O");var u=0;t[0]=t[0].replace(/%([a-zA-Z%])/g,function(e,n){if("%%"===e)return e;u++;var i=r.formatters[n];if("function"==typeof i){var s=t[u];e=i.call(o,s),t.splice(u,1),u--}return e}),r.formatArgs.call(o,t);var c=o.log||r.log;c.apply(o,t)}}return s.namespace=e,s.enabled=r.enabled(e),s.useColors=r.useColors(),s.color=t(e),s.destroy=i,s.extend=o,"function"==typeof r.init&&r.init(s),r.instances.push(s),s}function i(){var e=r.instances.indexOf(this);return-1!==e&&(r.instances.splice(e,1),!0)}function o(e,t){return r(this.namespace+(void 0===t?":":t)+e)}function s(e){var t;r.save(e),r.names=[],r.skips=[];var n=("string"==typeof e?e:"").split(/[\s,]+/),i=n.length;for(t=0;t<i;t++)n[t]&&(e=n[t].replace(/\*/g,".*?"),"-"===e[0]?r.skips.push(new RegExp("^"+e.substr(1)+"$")):r.names.push(new RegExp("^"+e+"$")));for(t=0;t<r.instances.length;t++){var o=r.instances[t];o.enabled=r.enabled(o.namespace)}}function a(){r.enable("")}function l(e){if("*"===e[e.length-1])return!0;var t,n;for(t=0,n=r.skips.length;t<n;t++)if(r.skips[t].test(e))return!1;for(t=0,n=r.names.length;t<n;t++)if(r.names[t].test(e))return!0;return!1}function u(e){return e instanceof Error?e.stack||e.message:e}return r.debug=r,r.default=r,r.coerce=u,r.disable=a,r.enable=s,r.enabled=l,r.humanize=n(78),Object.keys(e).forEach(function(t){r[t]=e[t]}),r.instances=[],r.names=[],r.skips=[],r.formatters={},r.selectColor=t,r.enable(r.load()),r}e.exports=r},function(e,t,n){t=e.exports=n(599),t.Stream=t,t.Readable=t,t.Writable=n(602),t.Duplex=n(142),t.Transform=n(603),t.PassThrough=n(1626)},function(e,t){},function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=n(5).Buffer,o=n(1625);function s(e,t,n){e.copy(t,n)}e.exports=function(){function e(){r(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function e(t){var n={data:t,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},e.prototype.unshift=function e(t){var n={data:t,next:this.head};0===this.length&&(this.tail=n),this.head=n,++this.length},e.prototype.shift=function e(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},e.prototype.clear=function e(){this.head=this.tail=null,this.length=0},e.prototype.join=function e(t){if(0===this.length)return"";for(var n=this.head,r=""+n.data;n=n.next;)r+=t+n.data;return r},e.prototype.concat=function e(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var n=i.allocUnsafe(t>>>0),r=this.head,o=0;r;)s(r.data,n,o),o+=r.data.length,r=r.next;return n},e}(),o&&o.inspect&&o.inspect.custom&&(e.exports.prototype[o.inspect.custom]=function(){var e=o.inspect({length:this.length});return this.constructor.name+" "+e})},function(e,t){},function(e,t,n){"use strict";e.exports=o;var r=n(603),i=n(7);function o(e){if(!(this instanceof o))return new o(e);r.call(this,e)}i.inherits=n(1),i.inherits(o,r),o.prototype._transform=function(e,t,n){n(null,e)}},function(e,t,n){const r=n(233),i=n(5).Buffer,o=n(4)("webtorrent:webconn"),s=n(307),a=n(171),l=n(598),u=n(311).version;class c extends l{constructor(e,t){super(),this.url=e,this.webPeerId=a.sync(e),this._torrent=t,this._init()}_init(){this.setKeepAlive(!0),this.once("handshake",(e,t)=>{if(this.destroyed)return;this.handshake(e,this.webPeerId);const n=this._torrent.pieces.length,i=new r(n);for(let e=0;e<=n;e++)i.set(e,!0);this.bitfield(i)}),this.once("interested",()=>{o("interested"),this.unchoke()}),this.on("uninterested",()=>{o("uninterested")}),this.on("choke",()=>{o("choke")}),this.on("unchoke",()=>{o("unchoke")}),this.on("bitfield",()=>{o("bitfield")}),this.on("request",(e,t,n,r)=>{o("request pieceIndex=%d offset=%d length=%d",e,t,n),this.httpRequest(e,t,n,r)})}httpRequest(e,t,n,r){const a=e*this._torrent.pieceLength,l=a+t,c=l+n-1,h=this._torrent.files;let f;if(h.length<=1)f=[{url:this.url,start:l,end:c}];else{const e=h.filter(e=>e.offset<=c&&e.offset+e.length>l);if(e.length<1)return r(new Error("Could not find file corresponnding to web seed range request"));f=e.map(e=>{const t=e.offset+e.length-1,n=this.url+("/"===this.url[this.url.length-1]?"":"/")+e.path;return{url:n,fileOffsetInRange:Math.max(e.offset-l,0),start:Math.max(l-e.offset,0),end:Math.min(t,c-e.offset)}})}let p=0,d=!1,m;f.length>1&&(m=i.alloc(n)),f.forEach(i=>{const a=i.url,l=i.start,c=i.end;o("Requesting url=%s pieceIndex=%d offset=%d length=%d start=%d end=%d",a,e,t,n,l,c);const h={url:a,method:"GET",headers:{"user-agent":`WebTorrent/${u} (https://webtorrent.io)`,range:`bytes=${l}-${c}`}};function g(e,t){if(e.statusCode<200||e.statusCode>=300)return d=!0,r(new Error(`Unexpected HTTP status code ${e.statusCode}`));o("Got data of length %d",t.length),1===f.length?r(null,t):(t.copy(m,i.fileOffsetInRange),++p===f.length&&r(null,m))}s.concat(h,(e,t,n)=>{if(!d)return e?"undefined"==typeof window||a.startsWith(`${window.location.origin}/`)?(d=!0,r(e)):s.head(a,(t,n)=>{if(!d){if(t)return d=!0,r(t);if(n.statusCode<200||n.statusCode>=300)return d=!0,r(new Error(`Unexpected HTTP status code ${n.statusCode}`));if(n.url===a)return d=!0,r(e);h.url=n.url,s.concat(h,(e,t,n)=>{if(!d)return e?(d=!0,r(e)):void g(t,n)})}}):void g(t,n)})})}destroy(){super.destroy(),this._torrent=null}}e.exports=c},function(e,t){class n{constructor(e){this._torrent=e,this._numPieces=e.pieces.length,this._pieces=new Array(this._numPieces),this._onWire=(e=>{this.recalculate(),this._initWire(e)}),this._onWireHave=(e=>{this._pieces[e]+=1}),this._onWireBitfield=(()=>{this.recalculate()}),this._torrent.wires.forEach(e=>{this._initWire(e)}),this._torrent.on("wire",this._onWire),this.recalculate()}getRarestPiece(e){let t=[],n=1/0;for(let r=0;r<this._numPieces;++r){if(e&&!e(r))continue;const i=this._pieces[r];i===n?t.push(r):i<n&&(t=[r],n=i)}return t.length?t[Math.random()*t.length|0]:-1}destroy(){this._torrent.removeListener("wire",this._onWire),this._torrent.wires.forEach(e=>{this._cleanupWireEvents(e)}),this._torrent=null,this._pieces=null,this._onWire=null,this._onWireHave=null,this._onWireBitfield=null}_initWire(e){e._onClose=(()=>{this._cleanupWireEvents(e);for(let t=0;t<this._numPieces;++t)this._pieces[t]-=e.peerPieces.get(t)}),e.on("have",this._onWireHave),e.on("bitfield",this._onWireBitfield),e.once("close",e._onClose)}recalculate(){this._pieces.fill(0);for(const e of this._torrent.wires)for(let t=0;t<this._numPieces;++t)this._pieces[t]+=e.peerPieces.get(t)}_cleanupWireEvents(e){e.removeListener("have",this._onWireHave),e.removeListener("bitfield",this._onWireBitfield),e._onClose&&e.removeListener("close",e._onClose),e._onClose=null}}e.exports=n},function(e,t){},function(e,t,n){var r;const i=n(32);r="undefined"==typeof window?n(604).FS:n(604).WOLK;const o=n(184),s=n(4)("dweb-transports:wolk"),a=n(77),l=n(111),u=n(94),c=n(146);let h={wolk_addr:"https://cloud.wolk.com"};class f extends l{constructor(e){super(e),this.options=e,this.wolk=void 0,this.name="WOLK",this.supportURLs=["wolk"],this.supportFunctions=["fetch","connection","get","set"],this.supportFeatures=[],this.status=l.STATUS_LOADED}connection(e){s("connection call");var t=new r;return t}static setup0(e){let t=l.mergeoptions(h,e.wolk);s("setup options=%o",t);let n=new f(t);return n.wolk=new r,n.wolk.setProvider(n.options.wolk_addr),u.addtransport(n),n}async p_setup1(e){await this.wolk.init().then(async()=>{if(void 0==this.wolk.ecdsaKey||null==this.wolk.ecdsaKey){var e="user"+Math.floor(1e3*Math.random()+1);return s("createAccount because ecdsaKey null"),await this.wolk.createAccount(e).then(t=>{s("Account Created: ["+e+"] hash: "+t+" KEY: "+this.wolk.ecdsaKey)}).catch(e=>{throw new Error("Error Creating Account: "+e)})}}).catch(e=>{throw new Error("Error Initializing Wolk: "+e)});try{this.status=l.STATUS_STARTING,e&&e(this),await this.p_status()}catch(e){this.status=l.STATUS_FAILED}return e&&e(this),this}async p_status(){return this.wolk.getLatestBlockNumber().then(e=>(e>=0?(s("STATUS: connected? [1] = BN: %s",e),this.status=l.STATUS_CONNECTED):(s("STATUS: connected? [0] = BN: %s",e),this.status=l.STATUS_FAILED),this.status)).catch(e=>{console.error("Error getting bn: "+e)})}async p_rawstore(e){console.assert(e,"TransportWOLK.p_rawstore: requires chunkdata")}parseWolkUrl(e){var e=i.parse(e);if("wolk:"!=e.protocol)throw new a.TransportError("WOLK Error encountered retrieving val: url ("+e.href+") is not a valid WOLK url | protocol = "+e.protocol);let t=e.host;var n=e.path.split("/");let r=n[1],o=e.path.substring(r.length+2);var s="key";"wolk"==t&&"chunk"==r&&(s="chunk");let l=e.query;return{owner:t,bucket:r,path:o,urltype:s,query:l}}async p_rawfetch(e){var t=this.parseWolkUrl(e),n="";if("key"==t.urltype)return s("Checking Wolk NoSQL for: %s",e),this.wolk.getKey(t.owner,t.bucket,t.path,"latest").then(function(e){return e}).catch(e=>{throw new Error("ERROR: p_rawfetch - "+e)})}async p_newdatabase(e){}async p_newtable(e,t){}async p_set(e,t,n){var r=this.parseWolkUrl(e);if("string"==typeof t)return this.wolk.setKey(r.owner,r.bucket,t,o(n)).then(e=>e).catch(e=>{throw new Error("TransportWOLK - Error setting key value pair: "+e)});console.assert(!Array.isArray(t),"TransportWOLK - shouldnt be passsing an array as the keyvalues")}async p_get(e,t){var n=this.parseWolkUrl(e);if(s("Getting url: %s",JSON.stringify(n)),Array.isArray(t))throw new a.ToBeImplementedError("p_get(url, [keys]) isn't supported - because of ambiguity better to explicitly loop on set of keys");return this.wolk.getKey(n.owner,n.bucket,t,"latest").then(e=>e).catch(e=>{throw new a.TransportError("Error encountered getting keyvalues: "+e)})}async p_delete(e,t){var n=this.parseWolkUrl(e);if("string"==typeof t)return this.wolk.deleteKey(n.owner,n.bucket,t).then(e=>e).catch(e=>{throw new a.TransportError("Error deleting key(s): "+e)});t.map(e=>{this.wolk.deleteKey(n.owner,n.bucket,e)})}async p_keys(e){var t=this.parseWolkUrl(e);return this.listCollection(t.owner,t.bucket,{})}async p_getall(e){}}u._transportclasses.WOLK=f,t=e.exports=f},function(e,t,n){"use strict";(function(t){const r=n(605),i=n(1743),o=n(1752),s=n(54),a=n(1754),l=n(16),u=n(1777),c=n(1780),h="default",f="public.key",p="private.key",d="id_rsa.pub",m="id_rsa",g="friends.key",y="personal.key",v="wolk",b="chunk",_="buckets",w=160,k=1,E=2,S=3,x=4,C=5,A=6,T=7,I=8,j=9,R=0,B=1,O=2,P=1e6,N="Put",D="Get",M="Delete",F="Query",L="Scan",U=1,q=1;class z{constructor(){this.provider="https://cloud.wolk.com",this.keyDir="~/.wolk/keys",this.developerTrustLevel=U,this.userTrustLevel=q,this.setWolkTrustLevel()}async init(){return await this.loadDefaultAccount().then(e=>e).catch(e=>{throw console.log("WOLK: loadAccount error: "+e),e})}setKeyDir(e){this.keyDir=e}setProvider(e){this.provider=e}setDeveloperTrustLevel(e){this.developerTrustLevel=e}setUserTrustLevel(e){this.userTrustLevel=e}setWolkTrustLevel(){this.userTrustLevel>this.developerTrustLevel?this.wolkTrustLevel=this.userTrustLevel:this.wolkTrustLevel=this.developerTrustLevel}loadDefaultAccount(){let e=s.join(this.keyDir,h);if(l.existsSync(e)){let t=l.readFileSync(e,"utf8");return this.loadAccount(t).then(()=>t).catch(e=>{throw new c(0,"Unable to load defaultAccount ["+t+"]")})}throw new c(0,"No Default Account found: please create one")}async setDefaultAccount(e){e=e.toLowerCase();let t=s.join(this.keyDir,h);return await H(t,e,"utf8").then(()=>(this.defaultAccount=e,new Promise(function(t,n){t(e)})))}async createAccount(e,t){e=e.toLowerCase();let n=s.join(this.keyDir,e);if(l.existsSync(n))return console.log("Account Already Exists Setting as DEFAULT:",n),await this.setDefaultAccount(e).then(()=>this.loadDefaultAccount().then(()=>this.loadAccount(e).then(()=>"accountexistslocally").catch(t=>{console.error("[fs:createAccount] Error - loadAccount: "+e+" | "+t)})));{console.log("Creating necessary key files locally"),l.mkdirSync(n,{recursive:!0},e=>{if(e)throw e});let r=await a.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:2048,publicExponent:new Uint8Array([1,0,1]),hash:{name:"SHA-256"}},!0,["sign","verify"]),i=await a.subtle.generateKey({name:"ECDSA",namedCurve:"P-256"},!0,["sign","verify"]),o=await a.subtle.generateKey({name:"AES-CTR",length:256},!0,["encrypt","decrypt"]),u=await a.subtle.generateKey({name:"AES-CTR",length:256},!0,["encrypt","decrypt"]);this.rsaKey=r.privateKey,this.ecdsaKey=i.privateKey,this.friendsKey=o,this.personalKey=u;let v=await a.subtle.exportKey("jwk",r.publicKey),b=await a.subtle.exportKey("jwk",r.privateKey),_=await a.subtle.exportKey("jwk",i.publicKey),w=await a.subtle.exportKey("jwk",i.privateKey),k=await a.subtle.exportKey("jwk",o),E=await a.subtle.exportKey("jwk",u);return this.ecdsaPublicKey=JSON.stringify(_),this.ecdsaPrivateKey=JSON.stringify(w),this.rsaPrivateKey=JSON.stringify(b),this.rsaPublicKey=JSON.stringify(v),this.friendsExportKey=JSON.stringify(k),this.personalExportKey=JSON.stringify(E),H(s.join(n,m),this.rsaPrivateKey,"utf8").then(()=>H(s.join(n,d),this.rsaPublicKey,"utf8")).then(()=>H(s.join(n,f),this.ecdsaPublicKey,"utf8")).then(()=>H(s.join(n,p),this.ecdsaPrivateKey,"utf8")).then(()=>H(s.join(n,g),this.friendsExportKey,"utf8")).then(()=>H(s.join(n,y),this.personalExportKey,"utf8")).then(()=>{if(void 0==this.defaultAccount){this.defaultAccount=e;let t=s.join(this.keyDir,h);return H(t,e,"utf8")}return new Promise((e,t)=>{e("")})}).then(async()=>await this.loadDefaultAccount(e).then(async()=>{let n=await this.setName(e,JSON.stringify(v),t);return n})).catch(e=>{throw new c(0,"ERROR: createAccount "+e)})}}loadAccount(e){e=e.toLowerCase();let t=s.join(this.keyDir,e);return l.existsSync(t)||console.log("no such directory:",t),this.ecdsaPublicKey=l.readFileSync(s.join(t,f),"utf8"),this.ecdsaPrivateKey=l.readFileSync(s.join(t,p),"utf8"),this.rsaPrivateKey=l.readFileSync(s.join(t,m),"utf8"),this.rsaPublicKey=l.readFileSync(s.join(t,d),"utf8"),this.friendsExportKey=l.readFileSync(s.join(t,g),"utf8"),this.personalExportKey=l.readFileSync(s.join(t,y),"utf8"),a.subtle.importKey("jwk",JSON.parse(this.ecdsaPrivateKey),{name:"ECDSA",namedCurve:"P-256"},!1,["sign"]).then((e,t)=>{this.ecdsaKey={},this.ecdsaKey.privateKey=e}).catch(e=>{})}setName(e,n,r){return e=e.toLowerCase(),this.post(e,{name:e,rsaPublicKey:t.from(n).toString("base64")},{},r)}determineProofValue(){let e=Math.random();return e<=this.wolkTrustLevel?1:0}getBlock(e,t){return this.get($("wolk","block",e.toString(10)),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getNode(e,t){return this.get($("wolk","node",e.toString(10)),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getPeers(e,t){return this.get($("wolk","info"),{Proof:this.determineProofValue()},t).then(e=>("string"==typeof e&&(e=JSON.parse(e)),e.peers)).catch(e=>{throw e})}getPendingTxCount(e,t){return this.get($("wolk","info"),{Proof:this.determineProofValue()},t).then(e=>("string"==typeof e&&(e=JSON.parse(e)),e.pendingTxCount)).catch(e=>{throw e})}updateNode(e,t,n){return this.patch($("wolk","node",e.toString(10)),t,{},n)}getName(e,t){return e=e.toLowerCase(),this.get($("wolk","name",e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getAccount(e,t){return e=e.toLowerCase(),this.get($("wolk","account",e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getLatestBlockNumber(e){return this.get($("wolk","block","latest"),{Proof:this.determineProofValue()},e).catch(e=>{throw e})}getBalance(e,t){return e=e.toLowerCase(),this.getAccount(e).then(e=>{var t=JSON.parse(e);return t.balance}).catch(e=>{throw e})}getTransaction(e,t){return this.get($("wolk","tx",e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}transfer(e,t,n){return this.post($("wolk","transfer"),{recipient:e,amount:t},{},n)}createBucket(e,t,n,r){var i=K(t,R,n);return this.post($(e,t),JSON.stringify(i),{},r)}createCollection(e,t,n,r){var i=K(t,B,n);return this.post($(e,t),JSON.stringify(i),{},r)}listCollections(e,t){return this.get(e,{Proof:this.determineProofValue()},t).catch(e=>{throw e})}listCollection(e,t,n){return this.get($(e,t),{Proof:this.determineProofValue()},n).catch(e=>{throw e})}deleteCollection(e,t,n){return this.delete($(e,t),{},n)}scanCollection(e,t,n,r){return this.get($(e,t),{Proof:this.determineProofValue()},r).catch(e=>{throw e})}setKey(e,t,n,r,i,o){return this.put($(e,t,n),r,{WaitForTx:i},o)}getKey(e,t,n,r,i){return this.get($(e,t,n),{Proof:this.determineProofValue()},i).catch(e=>{throw e})}getChunk(e,t,n){return this.get($(v,b,e),{Proof:this.determineProofValue()},n).catch(e=>{throw e})}deleteKey(e,t,n,r){return this.delete($(e,t,n),{},r)}createDatabase(e,t,n,r){return this.post($(e,t),JSON.stringify({name:t,bucketType:O,requesterPays:0,encryption:"none"}),n,{},r)}listDatabases(e,t){return this.get($(e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}deleteDatabase(e,t,n){return this.delete($(e,collection),{},n)}executeSQL(e,t,n,r,i){return this.post($(e,t,n),n,r,i)}async get(e,t,n){return this.wrequest("GET",e,null,t,n)}async post(e,t,n,r){return this.wrequest("POST",e,t,n,r)}async put(e,t,n,r){return this.wrequest("PUT",e,t,n,r)}async patch(e,t,n,r){return this.wrequest("PATCH",e,t,n,r)}async delete(e,t,n){return this.wrequest("DELETE",e,null,t,n)}sleep(e){return new Promise(t=>setTimeout(t,e))}computeHash(e){return t.from(this.toByteArray(u(t.from(e))))}toByteArray(e){for(var t=[];e.length>=2;)t.push(parseInt(e.substring(0,2),16)),e=e.substring(2,e.length);return t}async waitForTx(e,t){let n=!1,r=0;for(;!n;)if(this.getTransaction(e,function(e,r,i){if(e);else try{let e=JSON.parse(r);if(void 0!=e.BlockNumber)return n=!0,t(null,e)}catch(e){}}),await this.sleep(500),r++>15)return n=!0,t(new Error("timeout, tx not included"),null)}async wrequest(e,t,n,r,i){let o=this;return"function"==typeof i?this.wreq(e,t,n,r,i):new Promise((i,s)=>o.wreq(e,t,n,r,function(e,t){e?s(e):i(t)}))}async wreq(e,n,r,s,l){let u=e+"/"+n;"POST"!=e&&"PATCH"!=e||("object"==typeof r&&(r=JSON.stringify(r)),null!=r&&(u+=r));let h=t.from(u).toString("utf8"),f=this;var p={method:e,url:this.provider+"/"+n,headers:{Requester:this.ecdsaPublicKey,Msg:u},body:r,resolveWithFullResponse:!0};for(var d in s)p.headers[d]=s[d];var m="",g="",y;return void 0!=this.ecdsaKey&&(y=await a.subtle.sign({name:"ECDSA",hash:{name:"SHA-256"}},this.ecdsaKey.privateKey,h).catch(function(e){console.error("ERR: crypto.subtle.sign "+e)}),p.headers.Sig=V(y)),i(p).then(e=>"200"==e.statusCode?(void 0!=e.headers.proof&&void 0!=e.headers["proof-type"]&&(m=e.headers.proof,g=e.headers["proof-type"]),e.body):(console.log("ERROR: StatusCode ",e.statusCode,JSON.stringify(e.status),JSON.stringify(e.statusText)),l(new c(e.statusCode,e.body),null))).then(function(e){if(1!=p.headers.Proof)return l(null,e);if(console.log("Checking Proof"),m.length>0)return ee(n,s,m,g,e).then(t=>{if(t)return l(null,e);{let t=412;return l(new c(t,"unverified proof"),e)}});{let e=412;return l(new c(e,"proof requested but not returned by wolk provider: ["+this.provider+"]"),null)}}).catch(o.StatusCodeError,function(e){var t=new c(e.statusCode,e.error);return l(t,null)}).catch(e=>{let t=503;return l(new c(503,e),null)})}}function K(e,t,n){var r={name:e,bucketType:t};return void 0!=n&&(r.requesterPays=0,r.encryption="none",r.shimURL=n.shimURL),r}function H(e,t,n){return new Promise(function(r,i){l.writeFile(e,t,n,function(e){e?i(e):r(t)})})}function V(e){return Array.prototype.map.call(new Uint8Array(e),e=>("00"+e.toString(16)).slice(-2)).join("")}function $(...e){return e.map((e,t)=>0===t?e.trim().replace(/[\/]*$/g,""):e.trim().replace(/(^[\/]*|[\/]*$)/g,"")).filter(e=>e.length).join("/")}function W(e){return a.subtle.digest({name:"SHA-256"},e).catch(e=>{console.error("[fs.js:ComputeHash] error calling crypto.subtle.digest => "+e)})}function G(e){if(!e)return new Uint8Array;"0"==e[0]&&"x"==e[1]&&(e=e.substr(2,e.length-2));for(var t=[],n=0,r=e.length;n<r;n+=2)t.push(parseInt(e.substr(n,2),16));return new Uint8Array(t)}function Y(e,t){let n=t%8,r=19-(t>>3),i=(1<<n&e[r])>0;return i}function Z(e,t){if(e.byteLength!=t.byteLength)return!1;for(var n=new Int8Array(e),r=new Int8Array(t),i=0;i!=e.byteLength;i++)if(n[i]!=r[i])return!1;return!0}function J(e){let t=[];for(var n=0;n<e.Proof.length;n++)t.push(G(e.Proof[n]));let r={SMTTreeDepth:160,Key:G(e.Key),Proof:t,ProofBits:G(e.ProofBits)};return r}async function Q(e){var t=new Array;t[0]=new Uint8Array(await W(new Uint8Array(0)));for(var n=1;n<e;n++)t[n]=await W(Uint8Array.of(...new Uint8Array(t[n-1]),...new Uint8Array(t[n-1])));return t}async function X(e,t,n,r,i){var o=await Q(160);let s=n,a=e.ProofBits,l=0;for(var u,c=0;c<e.SMTTreeDepth;c++)if(Y(a,c)){var h=e.Proof[l];s=Y(t,c)?await W(Uint8Array.of(...h,...new Uint8Array(s))):await W(Uint8Array.of(...new Uint8Array(s),...h)),l++}else s=Y(t,c)?await W(Uint8Array.of(...new Uint8Array(o[c]),...new Uint8Array(s))):await W(Uint8Array.of(...new Uint8Array(s),...new Uint8Array(o[c])));let f=V(s),p=V(r);return f==p?(i>1&&console.log("SUCCESS","merkleRootComputed",f),!0):(console.log("checkSMTProof FAIL-merkleRoot MISMATCH",f),!1)}function ee(e,t,n,r,i){if(void 0==t.Proof)return!0;switch(r){case"SMT":let t=JSON.parse(n);return te(t,0);case"NoSQLScan":case"NoSQL":let o=JSON.parse(n);return ne(r,o,e,0,i,0)}return!1}async function te(e,t){let n=J(e.Proof);return await X(n,G(e.KeyHash),G(e.TxHash),G(e.MerkleRoot),t)}async function ne(e,t,n,r,i,o){let s=ae(n);if(t.Collection!=s.collection)return console.log("Collection Mismatch",t.Collection,s.collection),!1;let a=await Q(160);if("NoSQLScan"==e){if(void 0!=t.ScanProofs){console.log("NoSQLScan with ScanProofs");for(var l=0;l<t.ScanProofs.length;l++){let e=t.ScanProofs[l],n=J(e.KeyProof);if(0==t.Collection.length){let r=await X(n,n.Key,G(e.TxHash),G(t.SystemMerkleRoot),a,o);if(!r)return!1}else{let r=X(n,n.Key,G(e.TxHash),G(t.CollectionMerkleRoot),a,o);if(!r)return!1}}}else if(0==t.Collection.length){if("0x44a00e7ae0499c6e377b95709f3851843976ea6c2a86eff46adfe15608d22005"!==t.SystemChunkHash)return!1;let e=J(t.SystemProof),n=X(e,e.Key,G(t.SystemChunkHash),G(t.KeyMerkleRoot),a,o);if(!n)return!1;console.log("NoSQLScan SUCCESS","ch",t.SystemChunkHash,"mr",t.KeyMerkleRoot)}else if("0x44a00e7ae0499c6e377b95709f3851843976ea6c2a86eff46adfe15608d22005"!==t.CollectionChunkHash)return!1;return console.log("NoSQLScan Proof Verified"),!0}if(t.Key!=s.path)return console.log(t),console.log("Key Mismatch: [",t.Key,"] key: [",s.path,"]"),!1;let u=J(t.KeyProof),c=await re(s.path);if(!Z(c,u.Key))return console.log("Key Mismatch",u.Key,"keyHash",c,"path",s.path),!1;let h=G(t.TxHash),f=G(t.CollectionMerkleRoot),p=await X(u,c,h,f,a,o);if(!p)return console.log("KeyProof Verification FAILED"),!1;if(console.log("KeyProofCheck: ",p),void 0==t.Tx)return console.log("Tx not supplied"),!1;let d=G(t.Tx.txhash),m=s.owner,g=G(t.Tx.signer),y=J(t.CollectionProof),v=await oe(m,s.collection);if(!Z(y.Key,v))return console.log("Collection Mismatch",y.Key,"collHash",v),!1;let b=G(t.CollectionChunkHash),_=G(t.KeyMerkleRoot),w=await X(y,v,b,_,a,o);if(!w)return console.log("CollectionProof Verification FAILED",y),!1;console.log("CollectionProof Verified");let k=J(t.SystemProof),E=await re(m);if(!Z(k.Key,E))return console.log("System Mismatch"),!1;let S=G(t.SystemChunkHash),x=await X(k,E,S,_,a,o);return x?(console.log("SystemProof Verified"),!0):(console.log("SystemProof FAILED"),!1)}async function re(e){return new Uint8Array(await W(ie(e))).subarray(0,20)}function ie(e){var t=encodeURIComponent(e),n=t.replace(/%([0-9A-F]{2})/g,function(e,t){return String.fromCharCode("0x"+t)}),r=new Uint8Array(n.length);return Array.prototype.forEach.call(n,function(e,t){r[t]=e.charCodeAt(0)}),r}async function oe(e,t){let n=await W(Uint8Array.of(...ie(e),...ie(t)));return new Uint8Array(n.slice(0,20))}function se(e){}function ae(e){let t=e.split("/");var n="",r="",i="",o={owner:"",collection:"",path:""};return t.length>0&&(o.owner=t.shift()),t.length>0&&(o.collection=t.shift()),t.length>0&&(o.path=t.join("/")),o}"undefined"!=typeof window&&void 0===window.WOLK&&(window.WOLK=z),e.exports=z}).call(this,n(0).Buffer)},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(16),i=n(32).parse,o=n(14),s=n(607),a=n(609).Store,l=n(1634).MemoryCookieStore,u=n(611).pathMatch,c=n(1635).version,h;try{h=n(179)}catch(e){console.warn("tough-cookie: can't load punycode; won't use punycode for domain normalization")}var f=/^[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]+$/,p=/[\x00-\x1F]/,d=["\n","\r","\0"],m=/[\x20-\x3A\x3C-\x7E]+/,g=/[\x09\x20-\x2F\x3B-\x40\x5B-\x60\x7B-\x7E]/,y={jan:0,feb:1,mar:2,apr:3,may:4,jun:5,jul:6,aug:7,sep:8,oct:9,nov:10,dec:11},v=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],b=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],_=2147483647e3,w=0;function k(e,t,n,r){for(var i=0;i<e.length;){var o=e.charCodeAt(i);if(o<=47||o>=58)break;i++}return i<t||i>n?null:r||i==e.length?parseInt(e.substr(0,i),10):null}function E(e){var t=e.split(":"),n=[0,0,0];if(3!==t.length)return null;for(var r=0;r<3;r++){var i=2==r,o=k(t[r],1,2,i);if(null===o)return null;n[r]=o}return n}function S(e){e=String(e).substr(0,3).toLowerCase();var t=y[e];return t>=0?t:null}function x(e){if(e){var t=e.split(g);if(t){for(var n=null,r=null,i=null,o=null,s=null,a=null,l=0;l<t.length;l++){var u=t[l].trim(),c;if(u.length)null===i&&(c=E(u),c)?(n=c[0],r=c[1],i=c[2]):null!==o||(c=k(u,1,2,!0),null===c)?null!==s||(c=S(u),null===c)?null===a&&(c=k(u,2,4,!0),null!==c&&(a=c,a>=70&&a<=99?a+=1900:a>=0&&a<=69&&(a+=2e3))):s=c:o=c}if(!(null===o||null===s||null===a||null===i||o<1||o>31||a<1601||n>23||r>59||i>59))return new Date(Date.UTC(a,s,o,n,r,i))}}}function C(e){var t=e.getUTCDate();t=t>=10?t:"0"+t;var n=e.getUTCHours();n=n>=10?n:"0"+n;var r=e.getUTCMinutes();r=r>=10?r:"0"+r;var i=e.getUTCSeconds();return i=i>=10?i:"0"+i,b[e.getUTCDay()]+", "+t+" "+v[e.getUTCMonth()]+" "+e.getUTCFullYear()+" "+n+":"+r+":"+i+" GMT"}function A(e){return null==e?null:(e=e.trim().replace(/^\./,""),h&&/[^\u0001-\u007f]/.test(e)&&(e=h.toASCII(e)),e.toLowerCase())}function T(e,t,n){if(null==e||null==t)return null;if(!1!==n&&(e=A(e),t=A(t)),e==t)return!0;if(r.isIP(e))return!1;var i=e.indexOf(t);return!(i<=0)&&(e.length===t.length+i&&"."===e.substr(i-1,1))}function I(e){if(!e||"/"!==e.substr(0,1))return"/";if("/"===e)return e;var t=e.lastIndexOf("/");return 0===t?"/":e.slice(0,t)}function j(e){for(var t=0;t<d.length;t++){var n=e.indexOf(d[t]);-1!==n&&(e=e.substr(0,n))}return e}function R(e,t){e=j(e);var n=e.indexOf("="),r,i;if(t)0===n&&(e=e.substr(1),n=e.indexOf("="));else if(n<=0)return;if(n<=0?(r="",i=e.trim()):(r=e.substr(0,n).trim(),i=e.substr(n+1).trim()),!p.test(r)&&!p.test(i)){var o=new F;return o.key=r,o.value=i,o}}function B(e,t){t&&"object"==typeof t||(t={}),e=e.trim();var n=e.indexOf(";"),r=-1===n?e:e.substr(0,n),i=R(r,!!t.loose);if(i){if(-1===n)return i;var o=e.slice(n+1).trim();if(0===o.length)return i;for(var s=o.split(";");s.length;){var a=s.shift().trim();if(0!==a.length){var l=a.indexOf("="),u,c;switch(-1===l?(u=a,c=null):(u=a.substr(0,l),c=a.substr(l+1)),u=u.trim().toLowerCase(),c&&(c=c.trim()),u){case"expires":if(c){var h=x(c);h&&(i.expires=h)}break;case"max-age":if(c&&/^-?[0-9]+$/.test(c)){var f=parseInt(c,10);i.setMaxAge(f)}break;case"domain":if(c){var p=c.trim().replace(/^\./,"");p&&(i.domain=p.toLowerCase())}break;case"path":i.path=c&&"/"===c[0]?c:null;break;case"secure":i.secure=!0;break;case"httponly":i.httpOnly=!0;break;default:i.extensions=i.extensions||[],i.extensions.push(a)}}}return i}}function O(e){var t;try{t=JSON.parse(e)}catch(e){return e}return t}function P(e){if(!e)return null;var t;if("string"==typeof e){if(t=O(e),t instanceof Error)return null}else t=e;for(var n=new F,r=0;r<F.serializableProperties.length;r++){var i=F.serializableProperties[r];void 0!==t[i]&&t[i]!==F.prototype[i]&&("expires"===i||"creation"===i||"lastAccessed"===i?null===t[i]?n[i]=null:n[i]="Infinity"==t[i]?"Infinity":new Date(t[i]):n[i]=t[i])}return n}function N(e,t){var n=0,r=e.path?e.path.length:0,i=t.path?t.path.length:0;if(n=i-r,0!==n)return n;var o=e.creation?e.creation.getTime():_,s=t.creation?t.creation.getTime():_;return n=o-s,0!==n?n:(n=e.creationIndex-t.creationIndex,n)}function D(e){if("/"===e)return["/"];e.lastIndexOf("/")===e.length-1&&(e=e.substr(0,e.length-1));for(var t=[e];e.length>1;){var n=e.lastIndexOf("/");if(0===n)break;e=e.substr(0,n),t.push(e)}return t.push("/"),t}function M(e){if(e instanceof Object)return e;try{e=decodeURI(e)}catch(e){}return i(e)}function F(e){e=e||{},Object.keys(e).forEach(function(t){F.prototype.hasOwnProperty(t)&&F.prototype[t]!==e[t]&&"_"!==t.substr(0,1)&&(this[t]=e[t])},this),this.creation=this.creation||new Date,Object.defineProperty(this,"creationIndex",{configurable:!1,enumerable:!1,writable:!0,value:++F.cookiesCreated})}function L(e,t){"boolean"==typeof t?t={rejectPublicSuffixes:t}:null==t&&(t={}),null!=t.rejectPublicSuffixes&&(this.rejectPublicSuffixes=t.rejectPublicSuffixes),null!=t.looseMode&&(this.enableLooseMode=t.looseMode),e||(e=new l),this.store=e}F.cookiesCreated=0,F.parse=B,F.fromJSON=P,F.prototype.key="",F.prototype.value="",F.prototype.expires="Infinity",F.prototype.maxAge=null,F.prototype.domain=null,F.prototype.path=null,F.prototype.secure=!1,F.prototype.httpOnly=!1,F.prototype.extensions=null,F.prototype.hostOnly=null,F.prototype.pathIsDefault=null,F.prototype.creation=null,F.prototype.lastAccessed=null,Object.defineProperty(F.prototype,"creationIndex",{configurable:!0,enumerable:!1,writable:!0,value:0}),F.serializableProperties=Object.keys(F.prototype).filter(function(e){return!(F.prototype[e]instanceof Function||"creationIndex"===e||"_"===e.substr(0,1))}),F.prototype.inspect=function e(){var t=Date.now();return'Cookie="'+this.toString()+"; hostOnly="+(null!=this.hostOnly?this.hostOnly:"?")+"; aAge="+(this.lastAccessed?t-this.lastAccessed.getTime()+"ms":"?")+"; cAge="+(this.creation?t-this.creation.getTime()+"ms":"?")+'"'},o.inspect.custom&&(F.prototype[o.inspect.custom]=F.prototype.inspect),F.prototype.toJSON=function(){for(var e={},t=F.serializableProperties,n=0;n<t.length;n++){var r=t[n];this[r]!==F.prototype[r]&&("expires"===r||"creation"===r||"lastAccessed"===r?null===this[r]?e[r]=null:e[r]="Infinity"==this[r]?"Infinity":this[r].toISOString():"maxAge"===r?null!==this[r]&&(e[r]=this[r]==1/0||this[r]==-1/0?this[r].toString():this[r]):this[r]!==F.prototype[r]&&(e[r]=this[r]))}return e},F.prototype.clone=function(){return P(this.toJSON())},F.prototype.validate=function e(){if(!f.test(this.value))return!1;if(!(this.expires==1/0||this.expires instanceof Date||x(this.expires)))return!1;if(null!=this.maxAge&&this.maxAge<=0)return!1;if(null!=this.path&&!m.test(this.path))return!1;var t=this.cdomain();if(t){if(t.match(/\.$/))return!1;var n=s.getPublicSuffix(t);if(null==n)return!1}return!0},F.prototype.setExpires=function e(t){t instanceof Date?this.expires=t:this.expires=x(t)||"Infinity"},F.prototype.setMaxAge=function e(t){this.maxAge=t===1/0||t===-1/0?t.toString():t},F.prototype.cookieString=function e(){var t=this.value;return null==t&&(t=""),""===this.key?t:this.key+"="+t},F.prototype.toString=function e(){var t=this.cookieString();return this.expires!=1/0&&(this.expires instanceof Date?t+="; Expires="+C(this.expires):t+="; Expires="+this.expires),null!=this.maxAge&&this.maxAge!=1/0&&(t+="; Max-Age="+this.maxAge),this.domain&&!this.hostOnly&&(t+="; Domain="+this.domain),this.path&&(t+="; Path="+this.path),this.secure&&(t+="; Secure"),this.httpOnly&&(t+="; HttpOnly"),this.extensions&&this.extensions.forEach(function(e){t+="; "+e}),t},F.prototype.TTL=function e(t){if(null!=this.maxAge)return this.maxAge<=0?0:1e3*this.maxAge;var n=this.expires;return n!=1/0?(n instanceof Date||(n=x(n)||1/0),n==1/0?1/0:n.getTime()-(t||Date.now())):1/0},F.prototype.expiryTime=function e(t){if(null!=this.maxAge){var n=t||this.creation||new Date,r=this.maxAge<=0?-1/0:1e3*this.maxAge;return n.getTime()+r}return this.expires==1/0?1/0:this.expires.getTime()},F.prototype.expiryDate=function e(t){var n=this.expiryTime(t);return n==1/0?new Date(_):n==-1/0?new Date(0):new Date(n)},F.prototype.isPersistent=function e(){return null!=this.maxAge||this.expires!=1/0},F.prototype.cdomain=F.prototype.canonicalizedDomain=function e(){return null==this.domain?null:A(this.domain)},L.prototype.store=null,L.prototype.rejectPublicSuffixes=!0,L.prototype.enableLooseMode=!1;var U=[];function q(e){return function(){if(!this.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");var t=Array.prototype.slice.call(arguments),n,r;if(t.push(function e(t,i){n=t,r=i}),this[e].apply(this,t),n)throw n;return r}}U.push("setCookie"),L.prototype.setCookie=function(e,t,n,r){var i,o=M(t);n instanceof Function&&(r=n,n={});var a=A(o.hostname),l=this.enableLooseMode;if(null!=n.loose&&(l=n.loose),e instanceof F||(e=F.parse(e,{loose:l})),!e)return i=new Error("Cookie failed to parse"),r(n.ignoreError?null:i);var u=n.now||new Date;if(this.rejectPublicSuffixes&&e.domain){var c=s.getPublicSuffix(e.cdomain());if(null==c)return i=new Error("Cookie has domain set to a public suffix"),r(n.ignoreError?null:i)}if(e.domain){if(!T(a,e.cdomain(),!1))return i=new Error("Cookie not in this host's domain. Cookie:"+e.cdomain()+" Request:"+a),r(n.ignoreError?null:i);null==e.hostOnly&&(e.hostOnly=!1)}else e.hostOnly=!0,e.domain=a;if(e.path&&"/"===e.path[0]||(e.path=I(o.pathname),e.pathIsDefault=!0),!1===n.http&&e.httpOnly)return i=new Error("Cookie is HttpOnly and this isn't an HTTP API"),r(n.ignoreError?null:i);var h=this.store;function f(t,i){if(t)return r(t);var o=function(t){if(t)return r(t);r(null,e)};if(i){if(!1===n.http&&i.httpOnly)return t=new Error("old Cookie is HttpOnly and this isn't an HTTP API"),r(n.ignoreError?null:t);e.creation=i.creation,e.creationIndex=i.creationIndex,e.lastAccessed=u,h.updateCookie(i,e,o)}else e.creation=e.lastAccessed=u,h.putCookie(e,o)}h.updateCookie||(h.updateCookie=function(e,t,n){this.putCookie(t,n)}),h.findCookie(e.domain,e.path,e.key,f)},U.push("getCookies"),L.prototype.getCookies=function(e,t,n){var r=M(e);t instanceof Function&&(n=t,t={});var i=A(r.hostname),o=r.pathname||"/",s=t.secure;null!=s||!r.protocol||"https:"!=r.protocol&&"wss:"!=r.protocol||(s=!0);var a=t.http;null==a&&(a=!0);var l=t.now||Date.now(),c=!1!==t.expire,h=!!t.allPaths,f=this.store;function p(e){if(e.hostOnly){if(e.domain!=i)return!1}else if(!T(i,e.domain,!1))return!1;return!(!h&&!u(o,e.path))&&(!(e.secure&&!s)&&(!(e.httpOnly&&!a)&&(!(c&&e.expiryTime()<=l)||(f.removeCookie(e.domain,e.path,e.key,function(){}),!1))))}f.findCookies(i,h?null:o,function(e,r){if(e)return n(e);r=r.filter(p),!1!==t.sort&&(r=r.sort(N));var i=new Date;r.forEach(function(e){e.lastAccessed=i}),n(null,r)})},U.push("getCookieString"),L.prototype.getCookieString=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop(),n=function(e,n){e?t(e):t(null,n.sort(N).map(function(e){return e.cookieString()}).join("; "))};e.push(n),this.getCookies.apply(this,e)},U.push("getSetCookieStrings"),L.prototype.getSetCookieStrings=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop(),n=function(e,n){e?t(e):t(null,n.map(function(e){return e.toString()}))};e.push(n),this.getCookies.apply(this,e)},U.push("serialize"),L.prototype.serialize=function(e){var t=this.store.constructor.name;"Object"===t&&(t=null);var n={version:"tough-cookie@"+c,storeType:t,rejectPublicSuffixes:!!this.rejectPublicSuffixes,cookies:[]};if(!this.store.getAllCookies||"function"!=typeof this.store.getAllCookies)return e(new Error("store does not support getAllCookies and cannot be serialized"));this.store.getAllCookies(function(t,r){return t?e(t):(n.cookies=r.map(function(e){return e=e instanceof F?e.toJSON():e,delete e.creationIndex,e}),e(null,n))})},L.prototype.toJSON=function(){return this.serializeSync()},U.push("_importCookies"),L.prototype._importCookies=function(e,t){var n=this,r=e.cookies;if(!r||!Array.isArray(r))return t(new Error("serialized jar has no cookies array"));function i(e){if(e)return t(e);if(!r.length)return t(e,n);var o;try{o=P(r.shift())}catch(e){return t(e)}if(null===o)return i(null);n.store.putCookie(o,i)}r=r.slice(),i()},L.deserialize=function(e,t,n){var r;if(3!==arguments.length&&(n=t,t=null),"string"==typeof e){if(r=O(e),r instanceof Error)return n(r)}else r=e;var i=new L(t,r.rejectPublicSuffixes);i._importCookies(r,function(e){if(e)return n(e);n(null,i)})},L.deserializeSync=function(e,t){var n="string"==typeof e?JSON.parse(e):e,r=new L(t,n.rejectPublicSuffixes);if(!r.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");return r._importCookiesSync(n),r},L.fromJSON=L.deserializeSync,U.push("clone"),L.prototype.clone=function(e,t){1===arguments.length&&(t=e,e=null),this.serialize(function(n,r){if(n)return t(n);L.deserialize(e,r,t)})},U.forEach(function(e){L.prototype[e+"Sync"]=q(e)}),t.CookieJar=L,t.Cookie=F,t.Store=a,t.MemoryCookieStore=l,t.parseDate=x,t.formatDate=C,t.parse=B,t.fromJSON=P,t.domainMatch=T,t.defaultPath=I,t.pathMatch=u,t.getPublicSuffix=s.getPublicSuffix,t.cookieCompare=N,t.permuteDomain=n(610).permuteDomain,t.permutePath=D,t.canonicalDomain=A},function(e){e.exports=["ac","com.ac","edu.ac","gov.ac","net.ac","mil.ac","org.ac","ad","nom.ad","ae","co.ae","net.ae","org.ae","sch.ae","ac.ae","gov.ae","mil.ae","aero","accident-investigation.aero","accident-prevention.aero","aerobatic.aero","aeroclub.aero","aerodrome.aero","agents.aero","aircraft.aero","airline.aero","airport.aero","air-surveillance.aero","airtraffic.aero","air-traffic-control.aero","ambulance.aero","amusement.aero","association.aero","author.aero","ballooning.aero","broker.aero","caa.aero","cargo.aero","catering.aero","certification.aero","championship.aero","charter.aero","civilaviation.aero","club.aero","conference.aero","consultant.aero","consulting.aero","control.aero","council.aero","crew.aero","design.aero","dgca.aero","educator.aero","emergency.aero","engine.aero","engineer.aero","entertainment.aero","equipment.aero","exchange.aero","express.aero","federation.aero","flight.aero","freight.aero","fuel.aero","gliding.aero","government.aero","groundhandling.aero","group.aero","hanggliding.aero","homebuilt.aero","insurance.aero","journal.aero","journalist.aero","leasing.aero","logistics.aero","magazine.aero","maintenance.aero","media.aero","microlight.aero","modelling.aero","navigation.aero","parachuting.aero","paragliding.aero","passenger-association.aero","pilot.aero","press.aero","production.aero","recreation.aero","repbody.aero","res.aero","research.aero","rotorcraft.aero","safety.aero","scientist.aero","services.aero","show.aero","skydiving.aero","software.aero","student.aero","trader.aero","trading.aero","trainer.aero","union.aero","workinggroup.aero","works.aero","af","gov.af","com.af","org.af","net.af","edu.af","ag","com.ag","org.ag","net.ag","co.ag","nom.ag","ai","off.ai","com.ai","net.ai","org.ai","al","com.al","edu.al","gov.al","mil.al","net.al","org.al","am","co.am","com.am","commune.am","net.am","org.am","ao","ed.ao","gv.ao","og.ao","co.ao","pb.ao","it.ao","aq","ar","com.ar","edu.ar","gob.ar","gov.ar","int.ar","mil.ar","musica.ar","net.ar","org.ar","tur.ar","arpa","e164.arpa","in-addr.arpa","ip6.arpa","iris.arpa","uri.arpa","urn.arpa","as","gov.as","asia","at","ac.at","co.at","gv.at","or.at","au","com.au","net.au","org.au","edu.au","gov.au","asn.au","id.au","info.au","conf.au","oz.au","act.au","nsw.au","nt.au","qld.au","sa.au","tas.au","vic.au","wa.au","act.edu.au","nsw.edu.au","nt.edu.au","qld.edu.au","sa.edu.au","tas.edu.au","vic.edu.au","wa.edu.au","qld.gov.au","sa.gov.au","tas.gov.au","vic.gov.au","wa.gov.au","aw","com.aw","ax","az","com.az","net.az","int.az","gov.az","org.az","edu.az","info.az","pp.az","mil.az","name.az","pro.az","biz.az","ba","com.ba","edu.ba","gov.ba","mil.ba","net.ba","org.ba","bb","biz.bb","co.bb","com.bb","edu.bb","gov.bb","info.bb","net.bb","org.bb","store.bb","tv.bb","*.bd","be","ac.be","bf","gov.bf","bg","a.bg","b.bg","c.bg","d.bg","e.bg","f.bg","g.bg","h.bg","i.bg","j.bg","k.bg","l.bg","m.bg","n.bg","o.bg","p.bg","q.bg","r.bg","s.bg","t.bg","u.bg","v.bg","w.bg","x.bg","y.bg","z.bg","0.bg","1.bg","2.bg","3.bg","4.bg","5.bg","6.bg","7.bg","8.bg","9.bg","bh","com.bh","edu.bh","net.bh","org.bh","gov.bh","bi","co.bi","com.bi","edu.bi","or.bi","org.bi","biz","bj","asso.bj","barreau.bj","gouv.bj","bm","com.bm","edu.bm","gov.bm","net.bm","org.bm","bn","com.bn","edu.bn","gov.bn","net.bn","org.bn","bo","com.bo","edu.bo","gob.bo","int.bo","org.bo","net.bo","mil.bo","tv.bo","web.bo","academia.bo","agro.bo","arte.bo","blog.bo","bolivia.bo","ciencia.bo","cooperativa.bo","democracia.bo","deporte.bo","ecologia.bo","economia.bo","empresa.bo","indigena.bo","industria.bo","info.bo","medicina.bo","movimiento.bo","musica.bo","natural.bo","nombre.bo","noticias.bo","patria.bo","politica.bo","profesional.bo","plurinacional.bo","pueblo.bo","revista.bo","salud.bo","tecnologia.bo","tksat.bo","transporte.bo","wiki.bo","br","9guacu.br","abc.br","adm.br","adv.br","agr.br","aju.br","am.br","anani.br","aparecida.br","arq.br","art.br","ato.br","b.br","barueri.br","belem.br","bhz.br","bio.br","blog.br","bmd.br","boavista.br","bsb.br","campinagrande.br","campinas.br","caxias.br","cim.br","cng.br","cnt.br","com.br","contagem.br","coop.br","cri.br","cuiaba.br","curitiba.br","def.br","ecn.br","eco.br","edu.br","emp.br","eng.br","esp.br","etc.br","eti.br","far.br","feira.br","flog.br","floripa.br","fm.br","fnd.br","fortal.br","fot.br","foz.br","fst.br","g12.br","ggf.br","goiania.br","gov.br","ac.gov.br","al.gov.br","am.gov.br","ap.gov.br","ba.gov.br","ce.gov.br","df.gov.br","es.gov.br","go.gov.br","ma.gov.br","mg.gov.br","ms.gov.br","mt.gov.br","pa.gov.br","pb.gov.br","pe.gov.br","pi.gov.br","pr.gov.br","rj.gov.br","rn.gov.br","ro.gov.br","rr.gov.br","rs.gov.br","sc.gov.br","se.gov.br","sp.gov.br","to.gov.br","gru.br","imb.br","ind.br","inf.br","jab.br","jampa.br","jdf.br","joinville.br","jor.br","jus.br","leg.br","lel.br","londrina.br","macapa.br","maceio.br","manaus.br","maringa.br","mat.br","med.br","mil.br","morena.br","mp.br","mus.br","natal.br","net.br","niteroi.br","*.nom.br","not.br","ntr.br","odo.br","ong.br","org.br","osasco.br","palmas.br","poa.br","ppg.br","pro.br","psc.br","psi.br","pvh.br","qsl.br","radio.br","rec.br","recife.br","ribeirao.br","rio.br","riobranco.br","riopreto.br","salvador.br","sampa.br","santamaria.br","santoandre.br","saobernardo.br","saogonca.br","sjc.br","slg.br","slz.br","sorocaba.br","srv.br","taxi.br","tc.br","teo.br","the.br","tmp.br","trd.br","tur.br","tv.br","udi.br","vet.br","vix.br","vlog.br","wiki.br","zlg.br","bs","com.bs","net.bs","org.bs","edu.bs","gov.bs","bt","com.bt","edu.bt","gov.bt","net.bt","org.bt","bv","bw","co.bw","org.bw","by","gov.by","mil.by","com.by","of.by","bz","com.bz","net.bz","org.bz","edu.bz","gov.bz","ca","ab.ca","bc.ca","mb.ca","nb.ca","nf.ca","nl.ca","ns.ca","nt.ca","nu.ca","on.ca","pe.ca","qc.ca","sk.ca","yk.ca","gc.ca","cat","cc","cd","gov.cd","cf","cg","ch","ci","org.ci","or.ci","com.ci","co.ci","edu.ci","ed.ci","ac.ci","net.ci","go.ci","asso.ci","aéroport.ci","int.ci","presse.ci","md.ci","gouv.ci","*.ck","!www.ck","cl","gov.cl","gob.cl","co.cl","mil.cl","cm","co.cm","com.cm","gov.cm","net.cm","cn","ac.cn","com.cn","edu.cn","gov.cn","net.cn","org.cn","mil.cn","公司.cn","网络.cn","網絡.cn","ah.cn","bj.cn","cq.cn","fj.cn","gd.cn","gs.cn","gz.cn","gx.cn","ha.cn","hb.cn","he.cn","hi.cn","hl.cn","hn.cn","jl.cn","js.cn","jx.cn","ln.cn","nm.cn","nx.cn","qh.cn","sc.cn","sd.cn","sh.cn","sn.cn","sx.cn","tj.cn","xj.cn","xz.cn","yn.cn","zj.cn","hk.cn","mo.cn","tw.cn","co","arts.co","com.co","edu.co","firm.co","gov.co","info.co","int.co","mil.co","net.co","nom.co","org.co","rec.co","web.co","com","coop","cr","ac.cr","co.cr","ed.cr","fi.cr","go.cr","or.cr","sa.cr","cu","com.cu","edu.cu","org.cu","net.cu","gov.cu","inf.cu","cv","cw","com.cw","edu.cw","net.cw","org.cw","cx","gov.cx","cy","ac.cy","biz.cy","com.cy","ekloges.cy","gov.cy","ltd.cy","name.cy","net.cy","org.cy","parliament.cy","press.cy","pro.cy","tm.cy","cz","de","dj","dk","dm","com.dm","net.dm","org.dm","edu.dm","gov.dm","do","art.do","com.do","edu.do","gob.do","gov.do","mil.do","net.do","org.do","sld.do","web.do","dz","com.dz","org.dz","net.dz","gov.dz","edu.dz","asso.dz","pol.dz","art.dz","ec","com.ec","info.ec","net.ec","fin.ec","k12.ec","med.ec","pro.ec","org.ec","edu.ec","gov.ec","gob.ec","mil.ec","edu","ee","edu.ee","gov.ee","riik.ee","lib.ee","med.ee","com.ee","pri.ee","aip.ee","org.ee","fie.ee","eg","com.eg","edu.eg","eun.eg","gov.eg","mil.eg","name.eg","net.eg","org.eg","sci.eg","*.er","es","com.es","nom.es","org.es","gob.es","edu.es","et","com.et","gov.et","org.et","edu.et","biz.et","name.et","info.et","net.et","eu","fi","aland.fi","*.fj","*.fk","fm","fo","fr","asso.fr","com.fr","gouv.fr","nom.fr","prd.fr","tm.fr","aeroport.fr","avocat.fr","avoues.fr","cci.fr","chambagri.fr","chirurgiens-dentistes.fr","experts-comptables.fr","geometre-expert.fr","greta.fr","huissier-justice.fr","medecin.fr","notaires.fr","pharmacien.fr","port.fr","veterinaire.fr","ga","gb","gd","ge","com.ge","edu.ge","gov.ge","org.ge","mil.ge","net.ge","pvt.ge","gf","gg","co.gg","net.gg","org.gg","gh","com.gh","edu.gh","gov.gh","org.gh","mil.gh","gi","com.gi","ltd.gi","gov.gi","mod.gi","edu.gi","org.gi","gl","co.gl","com.gl","edu.gl","net.gl","org.gl","gm","gn","ac.gn","com.gn","edu.gn","gov.gn","org.gn","net.gn","gov","gp","com.gp","net.gp","mobi.gp","edu.gp","org.gp","asso.gp","gq","gr","com.gr","edu.gr","net.gr","org.gr","gov.gr","gs","gt","com.gt","edu.gt","gob.gt","ind.gt","mil.gt","net.gt","org.gt","gu","com.gu","edu.gu","gov.gu","guam.gu","info.gu","net.gu","org.gu","web.gu","gw","gy","co.gy","com.gy","edu.gy","gov.gy","net.gy","org.gy","hk","com.hk","edu.hk","gov.hk","idv.hk","net.hk","org.hk","公司.hk","教育.hk","敎育.hk","政府.hk","個人.hk","个人.hk","箇人.hk","網络.hk","网络.hk","组織.hk","網絡.hk","网絡.hk","组织.hk","組織.hk","組织.hk","hm","hn","com.hn","edu.hn","org.hn","net.hn","mil.hn","gob.hn","hr","iz.hr","from.hr","name.hr","com.hr","ht","com.ht","shop.ht","firm.ht","info.ht","adult.ht","net.ht","pro.ht","org.ht","med.ht","art.ht","coop.ht","pol.ht","asso.ht","edu.ht","rel.ht","gouv.ht","perso.ht","hu","co.hu","info.hu","org.hu","priv.hu","sport.hu","tm.hu","2000.hu","agrar.hu","bolt.hu","casino.hu","city.hu","erotica.hu","erotika.hu","film.hu","forum.hu","games.hu","hotel.hu","ingatlan.hu","jogasz.hu","konyvelo.hu","lakas.hu","media.hu","news.hu","reklam.hu","sex.hu","shop.hu","suli.hu","szex.hu","tozsde.hu","utazas.hu","video.hu","id","ac.id","biz.id","co.id","desa.id","go.id","mil.id","my.id","net.id","or.id","ponpes.id","sch.id","web.id","ie","gov.ie","il","ac.il","co.il","gov.il","idf.il","k12.il","muni.il","net.il","org.il","im","ac.im","co.im","com.im","ltd.co.im","net.im","org.im","plc.co.im","tt.im","tv.im","in","co.in","firm.in","net.in","org.in","gen.in","ind.in","nic.in","ac.in","edu.in","res.in","gov.in","mil.in","info","int","eu.int","io","com.io","iq","gov.iq","edu.iq","mil.iq","com.iq","org.iq","net.iq","ir","ac.ir","co.ir","gov.ir","id.ir","net.ir","org.ir","sch.ir","ایران.ir","ايران.ir","is","net.is","com.is","edu.is","gov.is","org.is","int.is","it","gov.it","edu.it","abr.it","abruzzo.it","aosta-valley.it","aostavalley.it","bas.it","basilicata.it","cal.it","calabria.it","cam.it","campania.it","emilia-romagna.it","emiliaromagna.it","emr.it","friuli-v-giulia.it","friuli-ve-giulia.it","friuli-vegiulia.it","friuli-venezia-giulia.it","friuli-veneziagiulia.it","friuli-vgiulia.it","friuliv-giulia.it","friulive-giulia.it","friulivegiulia.it","friulivenezia-giulia.it","friuliveneziagiulia.it","friulivgiulia.it","fvg.it","laz.it","lazio.it","lig.it","liguria.it","lom.it","lombardia.it","lombardy.it","lucania.it","mar.it","marche.it","mol.it","molise.it","piedmont.it","piemonte.it","pmn.it","pug.it","puglia.it","sar.it","sardegna.it","sardinia.it","sic.it","sicilia.it","sicily.it","taa.it","tos.it","toscana.it","trentin-sud-tirol.it","trentin-süd-tirol.it","trentin-sudtirol.it","trentin-südtirol.it","trentin-sued-tirol.it","trentin-suedtirol.it","trentino-a-adige.it","trentino-aadige.it","trentino-alto-adige.it","trentino-altoadige.it","trentino-s-tirol.it","trentino-stirol.it","trentino-sud-tirol.it","trentino-süd-tirol.it","trentino-sudtirol.it","trentino-südtirol.it","trentino-sued-tirol.it","trentino-suedtirol.it","trentino.it","trentinoa-adige.it","trentinoaadige.it","trentinoalto-adige.it","trentinoaltoadige.it","trentinos-tirol.it","trentinostirol.it","trentinosud-tirol.it","trentinosüd-tirol.it","trentinosudtirol.it","trentinosüdtirol.it","trentinosued-tirol.it","trentinosuedtirol.it","trentinsud-tirol.it","trentinsüd-tirol.it","trentinsudtirol.it","trentinsüdtirol.it","trentinsued-tirol.it","trentinsuedtirol.it","tuscany.it","umb.it","umbria.it","val-d-aosta.it","val-daosta.it","vald-aosta.it","valdaosta.it","valle-aosta.it","valle-d-aosta.it","valle-daosta.it","valleaosta.it","valled-aosta.it","valledaosta.it","vallee-aoste.it","vallée-aoste.it","vallee-d-aoste.it","vallée-d-aoste.it","valleeaoste.it","valléeaoste.it","valleedaoste.it","valléedaoste.it","vao.it","vda.it","ven.it","veneto.it","ag.it","agrigento.it","al.it","alessandria.it","alto-adige.it","altoadige.it","an.it","ancona.it","andria-barletta-trani.it","andria-trani-barletta.it","andriabarlettatrani.it","andriatranibarletta.it","ao.it","aosta.it","aoste.it","ap.it","aq.it","aquila.it","ar.it","arezzo.it","ascoli-piceno.it","ascolipiceno.it","asti.it","at.it","av.it","avellino.it","ba.it","balsan-sudtirol.it","balsan-südtirol.it","balsan-suedtirol.it","balsan.it","bari.it","barletta-trani-andria.it","barlettatraniandria.it","belluno.it","benevento.it","bergamo.it","bg.it","bi.it","biella.it","bl.it","bn.it","bo.it","bologna.it","bolzano-altoadige.it","bolzano.it","bozen-sudtirol.it","bozen-südtirol.it","bozen-suedtirol.it","bozen.it","br.it","brescia.it","brindisi.it","bs.it","bt.it","bulsan-sudtirol.it","bulsan-südtirol.it","bulsan-suedtirol.it","bulsan.it","bz.it","ca.it","cagliari.it","caltanissetta.it","campidano-medio.it","campidanomedio.it","campobasso.it","carbonia-iglesias.it","carboniaiglesias.it","carrara-massa.it","carraramassa.it","caserta.it","catania.it","catanzaro.it","cb.it","ce.it","cesena-forli.it","cesena-forlì.it","cesenaforli.it","cesenaforlì.it","ch.it","chieti.it","ci.it","cl.it","cn.it","co.it","como.it","cosenza.it","cr.it","cremona.it","crotone.it","cs.it","ct.it","cuneo.it","cz.it","dell-ogliastra.it","dellogliastra.it","en.it","enna.it","fc.it","fe.it","fermo.it","ferrara.it","fg.it","fi.it","firenze.it","florence.it","fm.it","foggia.it","forli-cesena.it","forlì-cesena.it","forlicesena.it","forlìcesena.it","fr.it","frosinone.it","ge.it","genoa.it","genova.it","go.it","gorizia.it","gr.it","grosseto.it","iglesias-carbonia.it","iglesiascarbonia.it","im.it","imperia.it","is.it","isernia.it","kr.it","la-spezia.it","laquila.it","laspezia.it","latina.it","lc.it","le.it","lecce.it","lecco.it","li.it","livorno.it","lo.it","lodi.it","lt.it","lu.it","lucca.it","macerata.it","mantova.it","massa-carrara.it","massacarrara.it","matera.it","mb.it","mc.it","me.it","medio-campidano.it","mediocampidano.it","messina.it","mi.it","milan.it","milano.it","mn.it","mo.it","modena.it","monza-brianza.it","monza-e-della-brianza.it","monza.it","monzabrianza.it","monzaebrianza.it","monzaedellabrianza.it","ms.it","mt.it","na.it","naples.it","napoli.it","no.it","novara.it","nu.it","nuoro.it","og.it","ogliastra.it","olbia-tempio.it","olbiatempio.it","or.it","oristano.it","ot.it","pa.it","padova.it","padua.it","palermo.it","parma.it","pavia.it","pc.it","pd.it","pe.it","perugia.it","pesaro-urbino.it","pesarourbino.it","pescara.it","pg.it","pi.it","piacenza.it","pisa.it","pistoia.it","pn.it","po.it","pordenone.it","potenza.it","pr.it","prato.it","pt.it","pu.it","pv.it","pz.it","ra.it","ragusa.it","ravenna.it","rc.it","re.it","reggio-calabria.it","reggio-emilia.it","reggiocalabria.it","reggioemilia.it","rg.it","ri.it","rieti.it","rimini.it","rm.it","rn.it","ro.it","roma.it","rome.it","rovigo.it","sa.it","salerno.it","sassari.it","savona.it","si.it","siena.it","siracusa.it","so.it","sondrio.it","sp.it","sr.it","ss.it","suedtirol.it","südtirol.it","sv.it","ta.it","taranto.it","te.it","tempio-olbia.it","tempioolbia.it","teramo.it","terni.it","tn.it","to.it","torino.it","tp.it","tr.it","trani-andria-barletta.it","trani-barletta-andria.it","traniandriabarletta.it","tranibarlettaandria.it","trapani.it","trento.it","treviso.it","trieste.it","ts.it","turin.it","tv.it","ud.it","udine.it","urbino-pesaro.it","urbinopesaro.it","va.it","varese.it","vb.it","vc.it","ve.it","venezia.it","venice.it","verbania.it","vercelli.it","verona.it","vi.it","vibo-valentia.it","vibovalentia.it","vicenza.it","viterbo.it","vr.it","vs.it","vt.it","vv.it","je","co.je","net.je","org.je","*.jm","jo","com.jo","org.jo","net.jo","edu.jo","sch.jo","gov.jo","mil.jo","name.jo","jobs","jp","ac.jp","ad.jp","co.jp","ed.jp","go.jp","gr.jp","lg.jp","ne.jp","or.jp","aichi.jp","akita.jp","aomori.jp","chiba.jp","ehime.jp","fukui.jp","fukuoka.jp","fukushima.jp","gifu.jp","gunma.jp","hiroshima.jp","hokkaido.jp","hyogo.jp","ibaraki.jp","ishikawa.jp","iwate.jp","kagawa.jp","kagoshima.jp","kanagawa.jp","kochi.jp","kumamoto.jp","kyoto.jp","mie.jp","miyagi.jp","miyazaki.jp","nagano.jp","nagasaki.jp","nara.jp","niigata.jp","oita.jp","okayama.jp","okinawa.jp","osaka.jp","saga.jp","saitama.jp","shiga.jp","shimane.jp","shizuoka.jp","tochigi.jp","tokushima.jp","tokyo.jp","tottori.jp","toyama.jp","wakayama.jp","yamagata.jp","yamaguchi.jp","yamanashi.jp","栃木.jp","愛知.jp","愛媛.jp","兵庫.jp","熊本.jp","茨城.jp","北海道.jp","千葉.jp","和歌山.jp","長崎.jp","長野.jp","新潟.jp","青森.jp","静岡.jp","東京.jp","石川.jp","埼玉.jp","三重.jp","京都.jp","佐賀.jp","大分.jp","大阪.jp","奈良.jp","宮城.jp","宮崎.jp","富山.jp","山口.jp","山形.jp","山梨.jp","岩手.jp","岐阜.jp","岡山.jp","島根.jp","広島.jp","徳島.jp","沖縄.jp","滋賀.jp","神奈川.jp","福井.jp","福岡.jp","福島.jp","秋田.jp","群馬.jp","香川.jp","高知.jp","鳥取.jp","鹿児島.jp","*.kawasaki.jp","*.kitakyushu.jp","*.kobe.jp","*.nagoya.jp","*.sapporo.jp","*.sendai.jp","*.yokohama.jp","!city.kawasaki.jp","!city.kitakyushu.jp","!city.kobe.jp","!city.nagoya.jp","!city.sapporo.jp","!city.sendai.jp","!city.yokohama.jp","aisai.aichi.jp","ama.aichi.jp","anjo.aichi.jp","asuke.aichi.jp","chiryu.aichi.jp","chita.aichi.jp","fuso.aichi.jp","gamagori.aichi.jp","handa.aichi.jp","hazu.aichi.jp","hekinan.aichi.jp","higashiura.aichi.jp","ichinomiya.aichi.jp","inazawa.aichi.jp","inuyama.aichi.jp","isshiki.aichi.jp","iwakura.aichi.jp","kanie.aichi.jp","kariya.aichi.jp","kasugai.aichi.jp","kira.aichi.jp","kiyosu.aichi.jp","komaki.aichi.jp","konan.aichi.jp","kota.aichi.jp","mihama.aichi.jp","miyoshi.aichi.jp","nishio.aichi.jp","nisshin.aichi.jp","obu.aichi.jp","oguchi.aichi.jp","oharu.aichi.jp","okazaki.aichi.jp","owariasahi.aichi.jp","seto.aichi.jp","shikatsu.aichi.jp","shinshiro.aichi.jp","shitara.aichi.jp","tahara.aichi.jp","takahama.aichi.jp","tobishima.aichi.jp","toei.aichi.jp","togo.aichi.jp","tokai.aichi.jp","tokoname.aichi.jp","toyoake.aichi.jp","toyohashi.aichi.jp","toyokawa.aichi.jp","toyone.aichi.jp","toyota.aichi.jp","tsushima.aichi.jp","yatomi.aichi.jp","akita.akita.jp","daisen.akita.jp","fujisato.akita.jp","gojome.akita.jp","hachirogata.akita.jp","happou.akita.jp","higashinaruse.akita.jp","honjo.akita.jp","honjyo.akita.jp","ikawa.akita.jp","kamikoani.akita.jp","kamioka.akita.jp","katagami.akita.jp","kazuno.akita.jp","kitaakita.akita.jp","kosaka.akita.jp","kyowa.akita.jp","misato.akita.jp","mitane.akita.jp","moriyoshi.akita.jp","nikaho.akita.jp","noshiro.akita.jp","odate.akita.jp","oga.akita.jp","ogata.akita.jp","semboku.akita.jp","yokote.akita.jp","yurihonjo.akita.jp","aomori.aomori.jp","gonohe.aomori.jp","hachinohe.aomori.jp","hashikami.aomori.jp","hiranai.aomori.jp","hirosaki.aomori.jp","itayanagi.aomori.jp","kuroishi.aomori.jp","misawa.aomori.jp","mutsu.aomori.jp","nakadomari.aomori.jp","noheji.aomori.jp","oirase.aomori.jp","owani.aomori.jp","rokunohe.aomori.jp","sannohe.aomori.jp","shichinohe.aomori.jp","shingo.aomori.jp","takko.aomori.jp","towada.aomori.jp","tsugaru.aomori.jp","tsuruta.aomori.jp","abiko.chiba.jp","asahi.chiba.jp","chonan.chiba.jp","chosei.chiba.jp","choshi.chiba.jp","chuo.chiba.jp","funabashi.chiba.jp","futtsu.chiba.jp","hanamigawa.chiba.jp","ichihara.chiba.jp","ichikawa.chiba.jp","ichinomiya.chiba.jp","inzai.chiba.jp","isumi.chiba.jp","kamagaya.chiba.jp","kamogawa.chiba.jp","kashiwa.chiba.jp","katori.chiba.jp","katsuura.chiba.jp","kimitsu.chiba.jp","kisarazu.chiba.jp","kozaki.chiba.jp","kujukuri.chiba.jp","kyonan.chiba.jp","matsudo.chiba.jp","midori.chiba.jp","mihama.chiba.jp","minamiboso.chiba.jp","mobara.chiba.jp","mutsuzawa.chiba.jp","nagara.chiba.jp","nagareyama.chiba.jp","narashino.chiba.jp","narita.chiba.jp","noda.chiba.jp","oamishirasato.chiba.jp","omigawa.chiba.jp","onjuku.chiba.jp","otaki.chiba.jp","sakae.chiba.jp","sakura.chiba.jp","shimofusa.chiba.jp","shirako.chiba.jp","shiroi.chiba.jp","shisui.chiba.jp","sodegaura.chiba.jp","sosa.chiba.jp","tako.chiba.jp","tateyama.chiba.jp","togane.chiba.jp","tohnosho.chiba.jp","tomisato.chiba.jp","urayasu.chiba.jp","yachimata.chiba.jp","yachiyo.chiba.jp","yokaichiba.chiba.jp","yokoshibahikari.chiba.jp","yotsukaido.chiba.jp","ainan.ehime.jp","honai.ehime.jp","ikata.ehime.jp","imabari.ehime.jp","iyo.ehime.jp","kamijima.ehime.jp","kihoku.ehime.jp","kumakogen.ehime.jp","masaki.ehime.jp","matsuno.ehime.jp","matsuyama.ehime.jp","namikata.ehime.jp","niihama.ehime.jp","ozu.ehime.jp","saijo.ehime.jp","seiyo.ehime.jp","shikokuchuo.ehime.jp","tobe.ehime.jp","toon.ehime.jp","uchiko.ehime.jp","uwajima.ehime.jp","yawatahama.ehime.jp","echizen.fukui.jp","eiheiji.fukui.jp","fukui.fukui.jp","ikeda.fukui.jp","katsuyama.fukui.jp","mihama.fukui.jp","minamiechizen.fukui.jp","obama.fukui.jp","ohi.fukui.jp","ono.fukui.jp","sabae.fukui.jp","sakai.fukui.jp","takahama.fukui.jp","tsuruga.fukui.jp","wakasa.fukui.jp","ashiya.fukuoka.jp","buzen.fukuoka.jp","chikugo.fukuoka.jp","chikuho.fukuoka.jp","chikujo.fukuoka.jp","chikushino.fukuoka.jp","chikuzen.fukuoka.jp","chuo.fukuoka.jp","dazaifu.fukuoka.jp","fukuchi.fukuoka.jp","hakata.fukuoka.jp","higashi.fukuoka.jp","hirokawa.fukuoka.jp","hisayama.fukuoka.jp","iizuka.fukuoka.jp","inatsuki.fukuoka.jp","kaho.fukuoka.jp","kasuga.fukuoka.jp","kasuya.fukuoka.jp","kawara.fukuoka.jp","keisen.fukuoka.jp","koga.fukuoka.jp","kurate.fukuoka.jp","kurogi.fukuoka.jp","kurume.fukuoka.jp","minami.fukuoka.jp","miyako.fukuoka.jp","miyama.fukuoka.jp","miyawaka.fukuoka.jp","mizumaki.fukuoka.jp","munakata.fukuoka.jp","nakagawa.fukuoka.jp","nakama.fukuoka.jp","nishi.fukuoka.jp","nogata.fukuoka.jp","ogori.fukuoka.jp","okagaki.fukuoka.jp","okawa.fukuoka.jp","oki.fukuoka.jp","omuta.fukuoka.jp","onga.fukuoka.jp","onojo.fukuoka.jp","oto.fukuoka.jp","saigawa.fukuoka.jp","sasaguri.fukuoka.jp","shingu.fukuoka.jp","shinyoshitomi.fukuoka.jp","shonai.fukuoka.jp","soeda.fukuoka.jp","sue.fukuoka.jp","tachiarai.fukuoka.jp","tagawa.fukuoka.jp","takata.fukuoka.jp","toho.fukuoka.jp","toyotsu.fukuoka.jp","tsuiki.fukuoka.jp","ukiha.fukuoka.jp","umi.fukuoka.jp","usui.fukuoka.jp","yamada.fukuoka.jp","yame.fukuoka.jp","yanagawa.fukuoka.jp","yukuhashi.fukuoka.jp","aizubange.fukushima.jp","aizumisato.fukushima.jp","aizuwakamatsu.fukushima.jp","asakawa.fukushima.jp","bandai.fukushima.jp","date.fukushima.jp","fukushima.fukushima.jp","furudono.fukushima.jp","futaba.fukushima.jp","hanawa.fukushima.jp","higashi.fukushima.jp","hirata.fukushima.jp","hirono.fukushima.jp","iitate.fukushima.jp","inawashiro.fukushima.jp","ishikawa.fukushima.jp","iwaki.fukushima.jp","izumizaki.fukushima.jp","kagamiishi.fukushima.jp","kaneyama.fukushima.jp","kawamata.fukushima.jp","kitakata.fukushima.jp","kitashiobara.fukushima.jp","koori.fukushima.jp","koriyama.fukushima.jp","kunimi.fukushima.jp","miharu.fukushima.jp","mishima.fukushima.jp","namie.fukushima.jp","nango.fukushima.jp","nishiaizu.fukushima.jp","nishigo.fukushima.jp","okuma.fukushima.jp","omotego.fukushima.jp","ono.fukushima.jp","otama.fukushima.jp","samegawa.fukushima.jp","shimogo.fukushima.jp","shirakawa.fukushima.jp","showa.fukushima.jp","soma.fukushima.jp","sukagawa.fukushima.jp","taishin.fukushima.jp","tamakawa.fukushima.jp","tanagura.fukushima.jp","tenei.fukushima.jp","yabuki.fukushima.jp","yamato.fukushima.jp","yamatsuri.fukushima.jp","yanaizu.fukushima.jp","yugawa.fukushima.jp","anpachi.gifu.jp","ena.gifu.jp","gifu.gifu.jp","ginan.gifu.jp","godo.gifu.jp","gujo.gifu.jp","hashima.gifu.jp","hichiso.gifu.jp","hida.gifu.jp","higashishirakawa.gifu.jp","ibigawa.gifu.jp","ikeda.gifu.jp","kakamigahara.gifu.jp","kani.gifu.jp","kasahara.gifu.jp","kasamatsu.gifu.jp","kawaue.gifu.jp","kitagata.gifu.jp","mino.gifu.jp","minokamo.gifu.jp","mitake.gifu.jp","mizunami.gifu.jp","motosu.gifu.jp","nakatsugawa.gifu.jp","ogaki.gifu.jp","sakahogi.gifu.jp","seki.gifu.jp","sekigahara.gifu.jp","shirakawa.gifu.jp","tajimi.gifu.jp","takayama.gifu.jp","tarui.gifu.jp","toki.gifu.jp","tomika.gifu.jp","wanouchi.gifu.jp","yamagata.gifu.jp","yaotsu.gifu.jp","yoro.gifu.jp","annaka.gunma.jp","chiyoda.gunma.jp","fujioka.gunma.jp","higashiagatsuma.gunma.jp","isesaki.gunma.jp","itakura.gunma.jp","kanna.gunma.jp","kanra.gunma.jp","katashina.gunma.jp","kawaba.gunma.jp","kiryu.gunma.jp","kusatsu.gunma.jp","maebashi.gunma.jp","meiwa.gunma.jp","midori.gunma.jp","minakami.gunma.jp","naganohara.gunma.jp","nakanojo.gunma.jp","nanmoku.gunma.jp","numata.gunma.jp","oizumi.gunma.jp","ora.gunma.jp","ota.gunma.jp","shibukawa.gunma.jp","shimonita.gunma.jp","shinto.gunma.jp","showa.gunma.jp","takasaki.gunma.jp","takayama.gunma.jp","tamamura.gunma.jp","tatebayashi.gunma.jp","tomioka.gunma.jp","tsukiyono.gunma.jp","tsumagoi.gunma.jp","ueno.gunma.jp","yoshioka.gunma.jp","asaminami.hiroshima.jp","daiwa.hiroshima.jp","etajima.hiroshima.jp","fuchu.hiroshima.jp","fukuyama.hiroshima.jp","hatsukaichi.hiroshima.jp","higashihiroshima.hiroshima.jp","hongo.hiroshima.jp","jinsekikogen.hiroshima.jp","kaita.hiroshima.jp","kui.hiroshima.jp","kumano.hiroshima.jp","kure.hiroshima.jp","mihara.hiroshima.jp","miyoshi.hiroshima.jp","naka.hiroshima.jp","onomichi.hiroshima.jp","osakikamijima.hiroshima.jp","otake.hiroshima.jp","saka.hiroshima.jp","sera.hiroshima.jp","seranishi.hiroshima.jp","shinichi.hiroshima.jp","shobara.hiroshima.jp","takehara.hiroshima.jp","abashiri.hokkaido.jp","abira.hokkaido.jp","aibetsu.hokkaido.jp","akabira.hokkaido.jp","akkeshi.hokkaido.jp","asahikawa.hokkaido.jp","ashibetsu.hokkaido.jp","ashoro.hokkaido.jp","assabu.hokkaido.jp","atsuma.hokkaido.jp","bibai.hokkaido.jp","biei.hokkaido.jp","bifuka.hokkaido.jp","bihoro.hokkaido.jp","biratori.hokkaido.jp","chippubetsu.hokkaido.jp","chitose.hokkaido.jp","date.hokkaido.jp","ebetsu.hokkaido.jp","embetsu.hokkaido.jp","eniwa.hokkaido.jp","erimo.hokkaido.jp","esan.hokkaido.jp","esashi.hokkaido.jp","fukagawa.hokkaido.jp","fukushima.hokkaido.jp","furano.hokkaido.jp","furubira.hokkaido.jp","haboro.hokkaido.jp","hakodate.hokkaido.jp","hamatonbetsu.hokkaido.jp","hidaka.hokkaido.jp","higashikagura.hokkaido.jp","higashikawa.hokkaido.jp","hiroo.hokkaido.jp","hokuryu.hokkaido.jp","hokuto.hokkaido.jp","honbetsu.hokkaido.jp","horokanai.hokkaido.jp","horonobe.hokkaido.jp","ikeda.hokkaido.jp","imakane.hokkaido.jp","ishikari.hokkaido.jp","iwamizawa.hokkaido.jp","iwanai.hokkaido.jp","kamifurano.hokkaido.jp","kamikawa.hokkaido.jp","kamishihoro.hokkaido.jp","kamisunagawa.hokkaido.jp","kamoenai.hokkaido.jp","kayabe.hokkaido.jp","kembuchi.hokkaido.jp","kikonai.hokkaido.jp","kimobetsu.hokkaido.jp","kitahiroshima.hokkaido.jp","kitami.hokkaido.jp","kiyosato.hokkaido.jp","koshimizu.hokkaido.jp","kunneppu.hokkaido.jp","kuriyama.hokkaido.jp","kuromatsunai.hokkaido.jp","kushiro.hokkaido.jp","kutchan.hokkaido.jp","kyowa.hokkaido.jp","mashike.hokkaido.jp","matsumae.hokkaido.jp","mikasa.hokkaido.jp","minamifurano.hokkaido.jp","mombetsu.hokkaido.jp","moseushi.hokkaido.jp","mukawa.hokkaido.jp","muroran.hokkaido.jp","naie.hokkaido.jp","nakagawa.hokkaido.jp","nakasatsunai.hokkaido.jp","nakatombetsu.hokkaido.jp","nanae.hokkaido.jp","nanporo.hokkaido.jp","nayoro.hokkaido.jp","nemuro.hokkaido.jp","niikappu.hokkaido.jp","niki.hokkaido.jp","nishiokoppe.hokkaido.jp","noboribetsu.hokkaido.jp","numata.hokkaido.jp","obihiro.hokkaido.jp","obira.hokkaido.jp","oketo.hokkaido.jp","okoppe.hokkaido.jp","otaru.hokkaido.jp","otobe.hokkaido.jp","otofuke.hokkaido.jp","otoineppu.hokkaido.jp","oumu.hokkaido.jp","ozora.hokkaido.jp","pippu.hokkaido.jp","rankoshi.hokkaido.jp","rebun.hokkaido.jp","rikubetsu.hokkaido.jp","rishiri.hokkaido.jp","rishirifuji.hokkaido.jp","saroma.hokkaido.jp","sarufutsu.hokkaido.jp","shakotan.hokkaido.jp","shari.hokkaido.jp","shibecha.hokkaido.jp","shibetsu.hokkaido.jp","shikabe.hokkaido.jp","shikaoi.hokkaido.jp","shimamaki.hokkaido.jp","shimizu.hokkaido.jp","shimokawa.hokkaido.jp","shinshinotsu.hokkaido.jp","shintoku.hokkaido.jp","shiranuka.hokkaido.jp","shiraoi.hokkaido.jp","shiriuchi.hokkaido.jp","sobetsu.hokkaido.jp","sunagawa.hokkaido.jp","taiki.hokkaido.jp","takasu.hokkaido.jp","takikawa.hokkaido.jp","takinoue.hokkaido.jp","teshikaga.hokkaido.jp","tobetsu.hokkaido.jp","tohma.hokkaido.jp","tomakomai.hokkaido.jp","tomari.hokkaido.jp","toya.hokkaido.jp","toyako.hokkaido.jp","toyotomi.hokkaido.jp","toyoura.hokkaido.jp","tsubetsu.hokkaido.jp","tsukigata.hokkaido.jp","urakawa.hokkaido.jp","urausu.hokkaido.jp","uryu.hokkaido.jp","utashinai.hokkaido.jp","wakkanai.hokkaido.jp","wassamu.hokkaido.jp","yakumo.hokkaido.jp","yoichi.hokkaido.jp","aioi.hyogo.jp","akashi.hyogo.jp","ako.hyogo.jp","amagasaki.hyogo.jp","aogaki.hyogo.jp","asago.hyogo.jp","ashiya.hyogo.jp","awaji.hyogo.jp","fukusaki.hyogo.jp","goshiki.hyogo.jp","harima.hyogo.jp","himeji.hyogo.jp","ichikawa.hyogo.jp","inagawa.hyogo.jp","itami.hyogo.jp","kakogawa.hyogo.jp","kamigori.hyogo.jp","kamikawa.hyogo.jp","kasai.hyogo.jp","kasuga.hyogo.jp","kawanishi.hyogo.jp","miki.hyogo.jp","minamiawaji.hyogo.jp","nishinomiya.hyogo.jp","nishiwaki.hyogo.jp","ono.hyogo.jp","sanda.hyogo.jp","sannan.hyogo.jp","sasayama.hyogo.jp","sayo.hyogo.jp","shingu.hyogo.jp","shinonsen.hyogo.jp","shiso.hyogo.jp","sumoto.hyogo.jp","taishi.hyogo.jp","taka.hyogo.jp","takarazuka.hyogo.jp","takasago.hyogo.jp","takino.hyogo.jp","tamba.hyogo.jp","tatsuno.hyogo.jp","toyooka.hyogo.jp","yabu.hyogo.jp","yashiro.hyogo.jp","yoka.hyogo.jp","yokawa.hyogo.jp","ami.ibaraki.jp","asahi.ibaraki.jp","bando.ibaraki.jp","chikusei.ibaraki.jp","daigo.ibaraki.jp","fujishiro.ibaraki.jp","hitachi.ibaraki.jp","hitachinaka.ibaraki.jp","hitachiomiya.ibaraki.jp","hitachiota.ibaraki.jp","ibaraki.ibaraki.jp","ina.ibaraki.jp","inashiki.ibaraki.jp","itako.ibaraki.jp","iwama.ibaraki.jp","joso.ibaraki.jp","kamisu.ibaraki.jp","kasama.ibaraki.jp","kashima.ibaraki.jp","kasumigaura.ibaraki.jp","koga.ibaraki.jp","miho.ibaraki.jp","mito.ibaraki.jp","moriya.ibaraki.jp","naka.ibaraki.jp","namegata.ibaraki.jp","oarai.ibaraki.jp","ogawa.ibaraki.jp","omitama.ibaraki.jp","ryugasaki.ibaraki.jp","sakai.ibaraki.jp","sakuragawa.ibaraki.jp","shimodate.ibaraki.jp","shimotsuma.ibaraki.jp","shirosato.ibaraki.jp","sowa.ibaraki.jp","suifu.ibaraki.jp","takahagi.ibaraki.jp","tamatsukuri.ibaraki.jp","tokai.ibaraki.jp","tomobe.ibaraki.jp","tone.ibaraki.jp","toride.ibaraki.jp","tsuchiura.ibaraki.jp","tsukuba.ibaraki.jp","uchihara.ibaraki.jp","ushiku.ibaraki.jp","yachiyo.ibaraki.jp","yamagata.ibaraki.jp","yawara.ibaraki.jp","yuki.ibaraki.jp","anamizu.ishikawa.jp","hakui.ishikawa.jp","hakusan.ishikawa.jp","kaga.ishikawa.jp","kahoku.ishikawa.jp","kanazawa.ishikawa.jp","kawakita.ishikawa.jp","komatsu.ishikawa.jp","nakanoto.ishikawa.jp","nanao.ishikawa.jp","nomi.ishikawa.jp","nonoichi.ishikawa.jp","noto.ishikawa.jp","shika.ishikawa.jp","suzu.ishikawa.jp","tsubata.ishikawa.jp","tsurugi.ishikawa.jp","uchinada.ishikawa.jp","wajima.ishikawa.jp","fudai.iwate.jp","fujisawa.iwate.jp","hanamaki.iwate.jp","hiraizumi.iwate.jp","hirono.iwate.jp","ichinohe.iwate.jp","ichinoseki.iwate.jp","iwaizumi.iwate.jp","iwate.iwate.jp","joboji.iwate.jp","kamaishi.iwate.jp","kanegasaki.iwate.jp","karumai.iwate.jp","kawai.iwate.jp","kitakami.iwate.jp","kuji.iwate.jp","kunohe.iwate.jp","kuzumaki.iwate.jp","miyako.iwate.jp","mizusawa.iwate.jp","morioka.iwate.jp","ninohe.iwate.jp","noda.iwate.jp","ofunato.iwate.jp","oshu.iwate.jp","otsuchi.iwate.jp","rikuzentakata.iwate.jp","shiwa.iwate.jp","shizukuishi.iwate.jp","sumita.iwate.jp","tanohata.iwate.jp","tono.iwate.jp","yahaba.iwate.jp","yamada.iwate.jp","ayagawa.kagawa.jp","higashikagawa.kagawa.jp","kanonji.kagawa.jp","kotohira.kagawa.jp","manno.kagawa.jp","marugame.kagawa.jp","mitoyo.kagawa.jp","naoshima.kagawa.jp","sanuki.kagawa.jp","tadotsu.kagawa.jp","takamatsu.kagawa.jp","tonosho.kagawa.jp","uchinomi.kagawa.jp","utazu.kagawa.jp","zentsuji.kagawa.jp","akune.kagoshima.jp","amami.kagoshima.jp","hioki.kagoshima.jp","isa.kagoshima.jp","isen.kagoshima.jp","izumi.kagoshima.jp","kagoshima.kagoshima.jp","kanoya.kagoshima.jp","kawanabe.kagoshima.jp","kinko.kagoshima.jp","kouyama.kagoshima.jp","makurazaki.kagoshima.jp","matsumoto.kagoshima.jp","minamitane.kagoshima.jp","nakatane.kagoshima.jp","nishinoomote.kagoshima.jp","satsumasendai.kagoshima.jp","soo.kagoshima.jp","tarumizu.kagoshima.jp","yusui.kagoshima.jp","aikawa.kanagawa.jp","atsugi.kanagawa.jp","ayase.kanagawa.jp","chigasaki.kanagawa.jp","ebina.kanagawa.jp","fujisawa.kanagawa.jp","hadano.kanagawa.jp","hakone.kanagawa.jp","hiratsuka.kanagawa.jp","isehara.kanagawa.jp","kaisei.kanagawa.jp","kamakura.kanagawa.jp","kiyokawa.kanagawa.jp","matsuda.kanagawa.jp","minamiashigara.kanagawa.jp","miura.kanagawa.jp","nakai.kanagawa.jp","ninomiya.kanagawa.jp","odawara.kanagawa.jp","oi.kanagawa.jp","oiso.kanagawa.jp","sagamihara.kanagawa.jp","samukawa.kanagawa.jp","tsukui.kanagawa.jp","yamakita.kanagawa.jp","yamato.kanagawa.jp","yokosuka.kanagawa.jp","yugawara.kanagawa.jp","zama.kanagawa.jp","zushi.kanagawa.jp","aki.kochi.jp","geisei.kochi.jp","hidaka.kochi.jp","higashitsuno.kochi.jp","ino.kochi.jp","kagami.kochi.jp","kami.kochi.jp","kitagawa.kochi.jp","kochi.kochi.jp","mihara.kochi.jp","motoyama.kochi.jp","muroto.kochi.jp","nahari.kochi.jp","nakamura.kochi.jp","nankoku.kochi.jp","nishitosa.kochi.jp","niyodogawa.kochi.jp","ochi.kochi.jp","okawa.kochi.jp","otoyo.kochi.jp","otsuki.kochi.jp","sakawa.kochi.jp","sukumo.kochi.jp","susaki.kochi.jp","tosa.kochi.jp","tosashimizu.kochi.jp","toyo.kochi.jp","tsuno.kochi.jp","umaji.kochi.jp","yasuda.kochi.jp","yusuhara.kochi.jp","amakusa.kumamoto.jp","arao.kumamoto.jp","aso.kumamoto.jp","choyo.kumamoto.jp","gyokuto.kumamoto.jp","kamiamakusa.kumamoto.jp","kikuchi.kumamoto.jp","kumamoto.kumamoto.jp","mashiki.kumamoto.jp","mifune.kumamoto.jp","minamata.kumamoto.jp","minamioguni.kumamoto.jp","nagasu.kumamoto.jp","nishihara.kumamoto.jp","oguni.kumamoto.jp","ozu.kumamoto.jp","sumoto.kumamoto.jp","takamori.kumamoto.jp","uki.kumamoto.jp","uto.kumamoto.jp","yamaga.kumamoto.jp","yamato.kumamoto.jp","yatsushiro.kumamoto.jp","ayabe.kyoto.jp","fukuchiyama.kyoto.jp","higashiyama.kyoto.jp","ide.kyoto.jp","ine.kyoto.jp","joyo.kyoto.jp","kameoka.kyoto.jp","kamo.kyoto.jp","kita.kyoto.jp","kizu.kyoto.jp","kumiyama.kyoto.jp","kyotamba.kyoto.jp","kyotanabe.kyoto.jp","kyotango.kyoto.jp","maizuru.kyoto.jp","minami.kyoto.jp","minamiyamashiro.kyoto.jp","miyazu.kyoto.jp","muko.kyoto.jp","nagaokakyo.kyoto.jp","nakagyo.kyoto.jp","nantan.kyoto.jp","oyamazaki.kyoto.jp","sakyo.kyoto.jp","seika.kyoto.jp","tanabe.kyoto.jp","uji.kyoto.jp","ujitawara.kyoto.jp","wazuka.kyoto.jp","yamashina.kyoto.jp","yawata.kyoto.jp","asahi.mie.jp","inabe.mie.jp","ise.mie.jp","kameyama.mie.jp","kawagoe.mie.jp","kiho.mie.jp","kisosaki.mie.jp","kiwa.mie.jp","komono.mie.jp","kumano.mie.jp","kuwana.mie.jp","matsusaka.mie.jp","meiwa.mie.jp","mihama.mie.jp","minamiise.mie.jp","misugi.mie.jp","miyama.mie.jp","nabari.mie.jp","shima.mie.jp","suzuka.mie.jp","tado.mie.jp","taiki.mie.jp","taki.mie.jp","tamaki.mie.jp","toba.mie.jp","tsu.mie.jp","udono.mie.jp","ureshino.mie.jp","watarai.mie.jp","yokkaichi.mie.jp","furukawa.miyagi.jp","higashimatsushima.miyagi.jp","ishinomaki.miyagi.jp","iwanuma.miyagi.jp","kakuda.miyagi.jp","kami.miyagi.jp","kawasaki.miyagi.jp","marumori.miyagi.jp","matsushima.miyagi.jp","minamisanriku.miyagi.jp","misato.miyagi.jp","murata.miyagi.jp","natori.miyagi.jp","ogawara.miyagi.jp","ohira.miyagi.jp","onagawa.miyagi.jp","osaki.miyagi.jp","rifu.miyagi.jp","semine.miyagi.jp","shibata.miyagi.jp","shichikashuku.miyagi.jp","shikama.miyagi.jp","shiogama.miyagi.jp","shiroishi.miyagi.jp","tagajo.miyagi.jp","taiwa.miyagi.jp","tome.miyagi.jp","tomiya.miyagi.jp","wakuya.miyagi.jp","watari.miyagi.jp","yamamoto.miyagi.jp","zao.miyagi.jp","aya.miyazaki.jp","ebino.miyazaki.jp","gokase.miyazaki.jp","hyuga.miyazaki.jp","kadogawa.miyazaki.jp","kawaminami.miyazaki.jp","kijo.miyazaki.jp","kitagawa.miyazaki.jp","kitakata.miyazaki.jp","kitaura.miyazaki.jp","kobayashi.miyazaki.jp","kunitomi.miyazaki.jp","kushima.miyazaki.jp","mimata.miyazaki.jp","miyakonojo.miyazaki.jp","miyazaki.miyazaki.jp","morotsuka.miyazaki.jp","nichinan.miyazaki.jp","nishimera.miyazaki.jp","nobeoka.miyazaki.jp","saito.miyazaki.jp","shiiba.miyazaki.jp","shintomi.miyazaki.jp","takaharu.miyazaki.jp","takanabe.miyazaki.jp","takazaki.miyazaki.jp","tsuno.miyazaki.jp","achi.nagano.jp","agematsu.nagano.jp","anan.nagano.jp","aoki.nagano.jp","asahi.nagano.jp","azumino.nagano.jp","chikuhoku.nagano.jp","chikuma.nagano.jp","chino.nagano.jp","fujimi.nagano.jp","hakuba.nagano.jp","hara.nagano.jp","hiraya.nagano.jp","iida.nagano.jp","iijima.nagano.jp","iiyama.nagano.jp","iizuna.nagano.jp","ikeda.nagano.jp","ikusaka.nagano.jp","ina.nagano.jp","karuizawa.nagano.jp","kawakami.nagano.jp","kiso.nagano.jp","kisofukushima.nagano.jp","kitaaiki.nagano.jp","komagane.nagano.jp","komoro.nagano.jp","matsukawa.nagano.jp","matsumoto.nagano.jp","miasa.nagano.jp","minamiaiki.nagano.jp","minamimaki.nagano.jp","minamiminowa.nagano.jp","minowa.nagano.jp","miyada.nagano.jp","miyota.nagano.jp","mochizuki.nagano.jp","nagano.nagano.jp","nagawa.nagano.jp","nagiso.nagano.jp","nakagawa.nagano.jp","nakano.nagano.jp","nozawaonsen.nagano.jp","obuse.nagano.jp","ogawa.nagano.jp","okaya.nagano.jp","omachi.nagano.jp","omi.nagano.jp","ookuwa.nagano.jp","ooshika.nagano.jp","otaki.nagano.jp","otari.nagano.jp","sakae.nagano.jp","sakaki.nagano.jp","saku.nagano.jp","sakuho.nagano.jp","shimosuwa.nagano.jp","shinanomachi.nagano.jp","shiojiri.nagano.jp","suwa.nagano.jp","suzaka.nagano.jp","takagi.nagano.jp","takamori.nagano.jp","takayama.nagano.jp","tateshina.nagano.jp","tatsuno.nagano.jp","togakushi.nagano.jp","togura.nagano.jp","tomi.nagano.jp","ueda.nagano.jp","wada.nagano.jp","yamagata.nagano.jp","yamanouchi.nagano.jp","yasaka.nagano.jp","yasuoka.nagano.jp","chijiwa.nagasaki.jp","futsu.nagasaki.jp","goto.nagasaki.jp","hasami.nagasaki.jp","hirado.nagasaki.jp","iki.nagasaki.jp","isahaya.nagasaki.jp","kawatana.nagasaki.jp","kuchinotsu.nagasaki.jp","matsuura.nagasaki.jp","nagasaki.nagasaki.jp","obama.nagasaki.jp","omura.nagasaki.jp","oseto.nagasaki.jp","saikai.nagasaki.jp","sasebo.nagasaki.jp","seihi.nagasaki.jp","shimabara.nagasaki.jp","shinkamigoto.nagasaki.jp","togitsu.nagasaki.jp","tsushima.nagasaki.jp","unzen.nagasaki.jp","ando.nara.jp","gose.nara.jp","heguri.nara.jp","higashiyoshino.nara.jp","ikaruga.nara.jp","ikoma.nara.jp","kamikitayama.nara.jp","kanmaki.nara.jp","kashiba.nara.jp","kashihara.nara.jp","katsuragi.nara.jp","kawai.nara.jp","kawakami.nara.jp","kawanishi.nara.jp","koryo.nara.jp","kurotaki.nara.jp","mitsue.nara.jp","miyake.nara.jp","nara.nara.jp","nosegawa.nara.jp","oji.nara.jp","ouda.nara.jp","oyodo.nara.jp","sakurai.nara.jp","sango.nara.jp","shimoichi.nara.jp","shimokitayama.nara.jp","shinjo.nara.jp","soni.nara.jp","takatori.nara.jp","tawaramoto.nara.jp","tenkawa.nara.jp","tenri.nara.jp","uda.nara.jp","yamatokoriyama.nara.jp","yamatotakada.nara.jp","yamazoe.nara.jp","yoshino.nara.jp","aga.niigata.jp","agano.niigata.jp","gosen.niigata.jp","itoigawa.niigata.jp","izumozaki.niigata.jp","joetsu.niigata.jp","kamo.niigata.jp","kariwa.niigata.jp","kashiwazaki.niigata.jp","minamiuonuma.niigata.jp","mitsuke.niigata.jp","muika.niigata.jp","murakami.niigata.jp","myoko.niigata.jp","nagaoka.niigata.jp","niigata.niigata.jp","ojiya.niigata.jp","omi.niigata.jp","sado.niigata.jp","sanjo.niigata.jp","seiro.niigata.jp","seirou.niigata.jp","sekikawa.niigata.jp","shibata.niigata.jp","tagami.niigata.jp","tainai.niigata.jp","tochio.niigata.jp","tokamachi.niigata.jp","tsubame.niigata.jp","tsunan.niigata.jp","uonuma.niigata.jp","yahiko.niigata.jp","yoita.niigata.jp","yuzawa.niigata.jp","beppu.oita.jp","bungoono.oita.jp","bungotakada.oita.jp","hasama.oita.jp","hiji.oita.jp","himeshima.oita.jp","hita.oita.jp","kamitsue.oita.jp","kokonoe.oita.jp","kuju.oita.jp","kunisaki.oita.jp","kusu.oita.jp","oita.oita.jp","saiki.oita.jp","taketa.oita.jp","tsukumi.oita.jp","usa.oita.jp","usuki.oita.jp","yufu.oita.jp","akaiwa.okayama.jp","asakuchi.okayama.jp","bizen.okayama.jp","hayashima.okayama.jp","ibara.okayama.jp","kagamino.okayama.jp","kasaoka.okayama.jp","kibichuo.okayama.jp","kumenan.okayama.jp","kurashiki.okayama.jp","maniwa.okayama.jp","misaki.okayama.jp","nagi.okayama.jp","niimi.okayama.jp","nishiawakura.okayama.jp","okayama.okayama.jp","satosho.okayama.jp","setouchi.okayama.jp","shinjo.okayama.jp","shoo.okayama.jp","soja.okayama.jp","takahashi.okayama.jp","tamano.okayama.jp","tsuyama.okayama.jp","wake.okayama.jp","yakage.okayama.jp","aguni.okinawa.jp","ginowan.okinawa.jp","ginoza.okinawa.jp","gushikami.okinawa.jp","haebaru.okinawa.jp","higashi.okinawa.jp","hirara.okinawa.jp","iheya.okinawa.jp","ishigaki.okinawa.jp","ishikawa.okinawa.jp","itoman.okinawa.jp","izena.okinawa.jp","kadena.okinawa.jp","kin.okinawa.jp","kitadaito.okinawa.jp","kitanakagusuku.okinawa.jp","kumejima.okinawa.jp","kunigami.okinawa.jp","minamidaito.okinawa.jp","motobu.okinawa.jp","nago.okinawa.jp","naha.okinawa.jp","nakagusuku.okinawa.jp","nakijin.okinawa.jp","nanjo.okinawa.jp","nishihara.okinawa.jp","ogimi.okinawa.jp","okinawa.okinawa.jp","onna.okinawa.jp","shimoji.okinawa.jp","taketomi.okinawa.jp","tarama.okinawa.jp","tokashiki.okinawa.jp","tomigusuku.okinawa.jp","tonaki.okinawa.jp","urasoe.okinawa.jp","uruma.okinawa.jp","yaese.okinawa.jp","yomitan.okinawa.jp","yonabaru.okinawa.jp","yonaguni.okinawa.jp","zamami.okinawa.jp","abeno.osaka.jp","chihayaakasaka.osaka.jp","chuo.osaka.jp","daito.osaka.jp","fujiidera.osaka.jp","habikino.osaka.jp","hannan.osaka.jp","higashiosaka.osaka.jp","higashisumiyoshi.osaka.jp","higashiyodogawa.osaka.jp","hirakata.osaka.jp","ibaraki.osaka.jp","ikeda.osaka.jp","izumi.osaka.jp","izumiotsu.osaka.jp","izumisano.osaka.jp","kadoma.osaka.jp","kaizuka.osaka.jp","kanan.osaka.jp","kashiwara.osaka.jp","katano.osaka.jp","kawachinagano.osaka.jp","kishiwada.osaka.jp","kita.osaka.jp","kumatori.osaka.jp","matsubara.osaka.jp","minato.osaka.jp","minoh.osaka.jp","misaki.osaka.jp","moriguchi.osaka.jp","neyagawa.osaka.jp","nishi.osaka.jp","nose.osaka.jp","osakasayama.osaka.jp","sakai.osaka.jp","sayama.osaka.jp","sennan.osaka.jp","settsu.osaka.jp","shijonawate.osaka.jp","shimamoto.osaka.jp","suita.osaka.jp","tadaoka.osaka.jp","taishi.osaka.jp","tajiri.osaka.jp","takaishi.osaka.jp","takatsuki.osaka.jp","tondabayashi.osaka.jp","toyonaka.osaka.jp","toyono.osaka.jp","yao.osaka.jp","ariake.saga.jp","arita.saga.jp","fukudomi.saga.jp","genkai.saga.jp","hamatama.saga.jp","hizen.saga.jp","imari.saga.jp","kamimine.saga.jp","kanzaki.saga.jp","karatsu.saga.jp","kashima.saga.jp","kitagata.saga.jp","kitahata.saga.jp","kiyama.saga.jp","kouhoku.saga.jp","kyuragi.saga.jp","nishiarita.saga.jp","ogi.saga.jp","omachi.saga.jp","ouchi.saga.jp","saga.saga.jp","shiroishi.saga.jp","taku.saga.jp","tara.saga.jp","tosu.saga.jp","yoshinogari.saga.jp","arakawa.saitama.jp","asaka.saitama.jp","chichibu.saitama.jp","fujimi.saitama.jp","fujimino.saitama.jp","fukaya.saitama.jp","hanno.saitama.jp","hanyu.saitama.jp","hasuda.saitama.jp","hatogaya.saitama.jp","hatoyama.saitama.jp","hidaka.saitama.jp","higashichichibu.saitama.jp","higashimatsuyama.saitama.jp","honjo.saitama.jp","ina.saitama.jp","iruma.saitama.jp","iwatsuki.saitama.jp","kamiizumi.saitama.jp","kamikawa.saitama.jp","kamisato.saitama.jp","kasukabe.saitama.jp","kawagoe.saitama.jp","kawaguchi.saitama.jp","kawajima.saitama.jp","kazo.saitama.jp","kitamoto.saitama.jp","koshigaya.saitama.jp","kounosu.saitama.jp","kuki.saitama.jp","kumagaya.saitama.jp","matsubushi.saitama.jp","minano.saitama.jp","misato.saitama.jp","miyashiro.saitama.jp","miyoshi.saitama.jp","moroyama.saitama.jp","nagatoro.saitama.jp","namegawa.saitama.jp","niiza.saitama.jp","ogano.saitama.jp","ogawa.saitama.jp","ogose.saitama.jp","okegawa.saitama.jp","omiya.saitama.jp","otaki.saitama.jp","ranzan.saitama.jp","ryokami.saitama.jp","saitama.saitama.jp","sakado.saitama.jp","satte.saitama.jp","sayama.saitama.jp","shiki.saitama.jp","shiraoka.saitama.jp","soka.saitama.jp","sugito.saitama.jp","toda.saitama.jp","tokigawa.saitama.jp","tokorozawa.saitama.jp","tsurugashima.saitama.jp","urawa.saitama.jp","warabi.saitama.jp","yashio.saitama.jp","yokoze.saitama.jp","yono.saitama.jp","yorii.saitama.jp","yoshida.saitama.jp","yoshikawa.saitama.jp","yoshimi.saitama.jp","aisho.shiga.jp","gamo.shiga.jp","higashiomi.shiga.jp","hikone.shiga.jp","koka.shiga.jp","konan.shiga.jp","kosei.shiga.jp","koto.shiga.jp","kusatsu.shiga.jp","maibara.shiga.jp","moriyama.shiga.jp","nagahama.shiga.jp","nishiazai.shiga.jp","notogawa.shiga.jp","omihachiman.shiga.jp","otsu.shiga.jp","ritto.shiga.jp","ryuoh.shiga.jp","takashima.shiga.jp","takatsuki.shiga.jp","torahime.shiga.jp","toyosato.shiga.jp","yasu.shiga.jp","akagi.shimane.jp","ama.shimane.jp","gotsu.shimane.jp","hamada.shimane.jp","higashiizumo.shimane.jp","hikawa.shimane.jp","hikimi.shimane.jp","izumo.shimane.jp","kakinoki.shimane.jp","masuda.shimane.jp","matsue.shimane.jp","misato.shimane.jp","nishinoshima.shimane.jp","ohda.shimane.jp","okinoshima.shimane.jp","okuizumo.shimane.jp","shimane.shimane.jp","tamayu.shimane.jp","tsuwano.shimane.jp","unnan.shimane.jp","yakumo.shimane.jp","yasugi.shimane.jp","yatsuka.shimane.jp","arai.shizuoka.jp","atami.shizuoka.jp","fuji.shizuoka.jp","fujieda.shizuoka.jp","fujikawa.shizuoka.jp","fujinomiya.shizuoka.jp","fukuroi.shizuoka.jp","gotemba.shizuoka.jp","haibara.shizuoka.jp","hamamatsu.shizuoka.jp","higashiizu.shizuoka.jp","ito.shizuoka.jp","iwata.shizuoka.jp","izu.shizuoka.jp","izunokuni.shizuoka.jp","kakegawa.shizuoka.jp","kannami.shizuoka.jp","kawanehon.shizuoka.jp","kawazu.shizuoka.jp","kikugawa.shizuoka.jp","kosai.shizuoka.jp","makinohara.shizuoka.jp","matsuzaki.shizuoka.jp","minamiizu.shizuoka.jp","mishima.shizuoka.jp","morimachi.shizuoka.jp","nishiizu.shizuoka.jp","numazu.shizuoka.jp","omaezaki.shizuoka.jp","shimada.shizuoka.jp","shimizu.shizuoka.jp","shimoda.shizuoka.jp","shizuoka.shizuoka.jp","susono.shizuoka.jp","yaizu.shizuoka.jp","yoshida.shizuoka.jp","ashikaga.tochigi.jp","bato.tochigi.jp","haga.tochigi.jp","ichikai.tochigi.jp","iwafune.tochigi.jp","kaminokawa.tochigi.jp","kanuma.tochigi.jp","karasuyama.tochigi.jp","kuroiso.tochigi.jp","mashiko.tochigi.jp","mibu.tochigi.jp","moka.tochigi.jp","motegi.tochigi.jp","nasu.tochigi.jp","nasushiobara.tochigi.jp","nikko.tochigi.jp","nishikata.tochigi.jp","nogi.tochigi.jp","ohira.tochigi.jp","ohtawara.tochigi.jp","oyama.tochigi.jp","sakura.tochigi.jp","sano.tochigi.jp","shimotsuke.tochigi.jp","shioya.tochigi.jp","takanezawa.tochigi.jp","tochigi.tochigi.jp","tsuga.tochigi.jp","ujiie.tochigi.jp","utsunomiya.tochigi.jp","yaita.tochigi.jp","aizumi.tokushima.jp","anan.tokushima.jp","ichiba.tokushima.jp","itano.tokushima.jp","kainan.tokushima.jp","komatsushima.tokushima.jp","matsushige.tokushima.jp","mima.tokushima.jp","minami.tokushima.jp","miyoshi.tokushima.jp","mugi.tokushima.jp","nakagawa.tokushima.jp","naruto.tokushima.jp","sanagochi.tokushima.jp","shishikui.tokushima.jp","tokushima.tokushima.jp","wajiki.tokushima.jp","adachi.tokyo.jp","akiruno.tokyo.jp","akishima.tokyo.jp","aogashima.tokyo.jp","arakawa.tokyo.jp","bunkyo.tokyo.jp","chiyoda.tokyo.jp","chofu.tokyo.jp","chuo.tokyo.jp","edogawa.tokyo.jp","fuchu.tokyo.jp","fussa.tokyo.jp","hachijo.tokyo.jp","hachioji.tokyo.jp","hamura.tokyo.jp","higashikurume.tokyo.jp","higashimurayama.tokyo.jp","higashiyamato.tokyo.jp","hino.tokyo.jp","hinode.tokyo.jp","hinohara.tokyo.jp","inagi.tokyo.jp","itabashi.tokyo.jp","katsushika.tokyo.jp","kita.tokyo.jp","kiyose.tokyo.jp","kodaira.tokyo.jp","koganei.tokyo.jp","kokubunji.tokyo.jp","komae.tokyo.jp","koto.tokyo.jp","kouzushima.tokyo.jp","kunitachi.tokyo.jp","machida.tokyo.jp","meguro.tokyo.jp","minato.tokyo.jp","mitaka.tokyo.jp","mizuho.tokyo.jp","musashimurayama.tokyo.jp","musashino.tokyo.jp","nakano.tokyo.jp","nerima.tokyo.jp","ogasawara.tokyo.jp","okutama.tokyo.jp","ome.tokyo.jp","oshima.tokyo.jp","ota.tokyo.jp","setagaya.tokyo.jp","shibuya.tokyo.jp","shinagawa.tokyo.jp","shinjuku.tokyo.jp","suginami.tokyo.jp","sumida.tokyo.jp","tachikawa.tokyo.jp","taito.tokyo.jp","tama.tokyo.jp","toshima.tokyo.jp","chizu.tottori.jp","hino.tottori.jp","kawahara.tottori.jp","koge.tottori.jp","kotoura.tottori.jp","misasa.tottori.jp","nanbu.tottori.jp","nichinan.tottori.jp","sakaiminato.tottori.jp","tottori.tottori.jp","wakasa.tottori.jp","yazu.tottori.jp","yonago.tottori.jp","asahi.toyama.jp","fuchu.toyama.jp","fukumitsu.toyama.jp","funahashi.toyama.jp","himi.toyama.jp","imizu.toyama.jp","inami.toyama.jp","johana.toyama.jp","kamiichi.toyama.jp","kurobe.toyama.jp","nakaniikawa.toyama.jp","namerikawa.toyama.jp","nanto.toyama.jp","nyuzen.toyama.jp","oyabe.toyama.jp","taira.toyama.jp","takaoka.toyama.jp","tateyama.toyama.jp","toga.toyama.jp","tonami.toyama.jp","toyama.toyama.jp","unazuki.toyama.jp","uozu.toyama.jp","yamada.toyama.jp","arida.wakayama.jp","aridagawa.wakayama.jp","gobo.wakayama.jp","hashimoto.wakayama.jp","hidaka.wakayama.jp","hirogawa.wakayama.jp","inami.wakayama.jp","iwade.wakayama.jp","kainan.wakayama.jp","kamitonda.wakayama.jp","katsuragi.wakayama.jp","kimino.wakayama.jp","kinokawa.wakayama.jp","kitayama.wakayama.jp","koya.wakayama.jp","koza.wakayama.jp","kozagawa.wakayama.jp","kudoyama.wakayama.jp","kushimoto.wakayama.jp","mihama.wakayama.jp","misato.wakayama.jp","nachikatsuura.wakayama.jp","shingu.wakayama.jp","shirahama.wakayama.jp","taiji.wakayama.jp","tanabe.wakayama.jp","wakayama.wakayama.jp","yuasa.wakayama.jp","yura.wakayama.jp","asahi.yamagata.jp","funagata.yamagata.jp","higashine.yamagata.jp","iide.yamagata.jp","kahoku.yamagata.jp","kaminoyama.yamagata.jp","kaneyama.yamagata.jp","kawanishi.yamagata.jp","mamurogawa.yamagata.jp","mikawa.yamagata.jp","murayama.yamagata.jp","nagai.yamagata.jp","nakayama.yamagata.jp","nanyo.yamagata.jp","nishikawa.yamagata.jp","obanazawa.yamagata.jp","oe.yamagata.jp","oguni.yamagata.jp","ohkura.yamagata.jp","oishida.yamagata.jp","sagae.yamagata.jp","sakata.yamagata.jp","sakegawa.yamagata.jp","shinjo.yamagata.jp","shirataka.yamagata.jp","shonai.yamagata.jp","takahata.yamagata.jp","tendo.yamagata.jp","tozawa.yamagata.jp","tsuruoka.yamagata.jp","yamagata.yamagata.jp","yamanobe.yamagata.jp","yonezawa.yamagata.jp","yuza.yamagata.jp","abu.yamaguchi.jp","hagi.yamaguchi.jp","hikari.yamaguchi.jp","hofu.yamaguchi.jp","iwakuni.yamaguchi.jp","kudamatsu.yamaguchi.jp","mitou.yamaguchi.jp","nagato.yamaguchi.jp","oshima.yamaguchi.jp","shimonoseki.yamaguchi.jp","shunan.yamaguchi.jp","tabuse.yamaguchi.jp","tokuyama.yamaguchi.jp","toyota.yamaguchi.jp","ube.yamaguchi.jp","yuu.yamaguchi.jp","chuo.yamanashi.jp","doshi.yamanashi.jp","fuefuki.yamanashi.jp","fujikawa.yamanashi.jp","fujikawaguchiko.yamanashi.jp","fujiyoshida.yamanashi.jp","hayakawa.yamanashi.jp","hokuto.yamanashi.jp","ichikawamisato.yamanashi.jp","kai.yamanashi.jp","kofu.yamanashi.jp","koshu.yamanashi.jp","kosuge.yamanashi.jp","minami-alps.yamanashi.jp","minobu.yamanashi.jp","nakamichi.yamanashi.jp","nanbu.yamanashi.jp","narusawa.yamanashi.jp","nirasaki.yamanashi.jp","nishikatsura.yamanashi.jp","oshino.yamanashi.jp","otsuki.yamanashi.jp","showa.yamanashi.jp","tabayama.yamanashi.jp","tsuru.yamanashi.jp","uenohara.yamanashi.jp","yamanakako.yamanashi.jp","yamanashi.yamanashi.jp","ke","ac.ke","co.ke","go.ke","info.ke","me.ke","mobi.ke","ne.ke","or.ke","sc.ke","kg","org.kg","net.kg","com.kg","edu.kg","gov.kg","mil.kg","*.kh","ki","edu.ki","biz.ki","net.ki","org.ki","gov.ki","info.ki","com.ki","km","org.km","nom.km","gov.km","prd.km","tm.km","edu.km","mil.km","ass.km","com.km","coop.km","asso.km","presse.km","medecin.km","notaires.km","pharmaciens.km","veterinaire.km","gouv.km","kn","net.kn","org.kn","edu.kn","gov.kn","kp","com.kp","edu.kp","gov.kp","org.kp","rep.kp","tra.kp","kr","ac.kr","co.kr","es.kr","go.kr","hs.kr","kg.kr","mil.kr","ms.kr","ne.kr","or.kr","pe.kr","re.kr","sc.kr","busan.kr","chungbuk.kr","chungnam.kr","daegu.kr","daejeon.kr","gangwon.kr","gwangju.kr","gyeongbuk.kr","gyeonggi.kr","gyeongnam.kr","incheon.kr","jeju.kr","jeonbuk.kr","jeonnam.kr","seoul.kr","ulsan.kr","kw","com.kw","edu.kw","emb.kw","gov.kw","ind.kw","net.kw","org.kw","ky","edu.ky","gov.ky","com.ky","org.ky","net.ky","kz","org.kz","edu.kz","net.kz","gov.kz","mil.kz","com.kz","la","int.la","net.la","info.la","edu.la","gov.la","per.la","com.la","org.la","lb","com.lb","edu.lb","gov.lb","net.lb","org.lb","lc","com.lc","net.lc","co.lc","org.lc","edu.lc","gov.lc","li","lk","gov.lk","sch.lk","net.lk","int.lk","com.lk","org.lk","edu.lk","ngo.lk","soc.lk","web.lk","ltd.lk","assn.lk","grp.lk","hotel.lk","ac.lk","lr","com.lr","edu.lr","gov.lr","org.lr","net.lr","ls","ac.ls","biz.ls","co.ls","edu.ls","gov.ls","info.ls","net.ls","org.ls","sc.ls","lt","gov.lt","lu","lv","com.lv","edu.lv","gov.lv","org.lv","mil.lv","id.lv","net.lv","asn.lv","conf.lv","ly","com.ly","net.ly","gov.ly","plc.ly","edu.ly","sch.ly","med.ly","org.ly","id.ly","ma","co.ma","net.ma","gov.ma","org.ma","ac.ma","press.ma","mc","tm.mc","asso.mc","md","me","co.me","net.me","org.me","edu.me","ac.me","gov.me","its.me","priv.me","mg","org.mg","nom.mg","gov.mg","prd.mg","tm.mg","edu.mg","mil.mg","com.mg","co.mg","mh","mil","mk","com.mk","org.mk","net.mk","edu.mk","gov.mk","inf.mk","name.mk","ml","com.ml","edu.ml","gouv.ml","gov.ml","net.ml","org.ml","presse.ml","*.mm","mn","gov.mn","edu.mn","org.mn","mo","com.mo","net.mo","org.mo","edu.mo","gov.mo","mobi","mp","mq","mr","gov.mr","ms","com.ms","edu.ms","gov.ms","net.ms","org.ms","mt","com.mt","edu.mt","net.mt","org.mt","mu","com.mu","net.mu","org.mu","gov.mu","ac.mu","co.mu","or.mu","museum","academy.museum","agriculture.museum","air.museum","airguard.museum","alabama.museum","alaska.museum","amber.museum","ambulance.museum","american.museum","americana.museum","americanantiques.museum","americanart.museum","amsterdam.museum","and.museum","annefrank.museum","anthro.museum","anthropology.museum","antiques.museum","aquarium.museum","arboretum.museum","archaeological.museum","archaeology.museum","architecture.museum","art.museum","artanddesign.museum","artcenter.museum","artdeco.museum","arteducation.museum","artgallery.museum","arts.museum","artsandcrafts.museum","asmatart.museum","assassination.museum","assisi.museum","association.museum","astronomy.museum","atlanta.museum","austin.museum","australia.museum","automotive.museum","aviation.museum","axis.museum","badajoz.museum","baghdad.museum","bahn.museum","bale.museum","baltimore.museum","barcelona.museum","baseball.museum","basel.museum","baths.museum","bauern.museum","beauxarts.museum","beeldengeluid.museum","bellevue.museum","bergbau.museum","berkeley.museum","berlin.museum","bern.museum","bible.museum","bilbao.museum","bill.museum","birdart.museum","birthplace.museum","bonn.museum","boston.museum","botanical.museum","botanicalgarden.museum","botanicgarden.museum","botany.museum","brandywinevalley.museum","brasil.museum","bristol.museum","british.museum","britishcolumbia.museum","broadcast.museum","brunel.museum","brussel.museum","brussels.museum","bruxelles.museum","building.museum","burghof.museum","bus.museum","bushey.museum","cadaques.museum","california.museum","cambridge.museum","can.museum","canada.museum","capebreton.museum","carrier.museum","cartoonart.museum","casadelamoneda.museum","castle.museum","castres.museum","celtic.museum","center.museum","chattanooga.museum","cheltenham.museum","chesapeakebay.museum","chicago.museum","children.museum","childrens.museum","childrensgarden.museum","chiropractic.museum","chocolate.museum","christiansburg.museum","cincinnati.museum","cinema.museum","circus.museum","civilisation.museum","civilization.museum","civilwar.museum","clinton.museum","clock.museum","coal.museum","coastaldefence.museum","cody.museum","coldwar.museum","collection.museum","colonialwilliamsburg.museum","coloradoplateau.museum","columbia.museum","columbus.museum","communication.museum","communications.museum","community.museum","computer.museum","computerhistory.museum","comunicações.museum","contemporary.museum","contemporaryart.museum","convent.museum","copenhagen.museum","corporation.museum","correios-e-telecomunicações.museum","corvette.museum","costume.museum","countryestate.museum","county.museum","crafts.museum","cranbrook.museum","creation.museum","cultural.museum","culturalcenter.museum","culture.museum","cyber.museum","cymru.museum","dali.museum","dallas.museum","database.museum","ddr.museum","decorativearts.museum","delaware.museum","delmenhorst.museum","denmark.museum","depot.museum","design.museum","detroit.museum","dinosaur.museum","discovery.museum","dolls.museum","donostia.museum","durham.museum","eastafrica.museum","eastcoast.museum","education.museum","educational.museum","egyptian.museum","eisenbahn.museum","elburg.museum","elvendrell.museum","embroidery.museum","encyclopedic.museum","england.museum","entomology.museum","environment.museum","environmentalconservation.museum","epilepsy.museum","essex.museum","estate.museum","ethnology.museum","exeter.museum","exhibition.museum","family.museum","farm.museum","farmequipment.museum","farmers.museum","farmstead.museum","field.museum","figueres.museum","filatelia.museum","film.museum","fineart.museum","finearts.museum","finland.museum","flanders.museum","florida.museum","force.museum","fortmissoula.museum","fortworth.museum","foundation.museum","francaise.museum","frankfurt.museum","franziskaner.museum","freemasonry.museum","freiburg.museum","fribourg.museum","frog.museum","fundacio.museum","furniture.museum","gallery.museum","garden.museum","gateway.museum","geelvinck.museum","gemological.museum","geology.museum","georgia.museum","giessen.museum","glas.museum","glass.museum","gorge.museum","grandrapids.museum","graz.museum","guernsey.museum","halloffame.museum","hamburg.museum","handson.museum","harvestcelebration.museum","hawaii.museum","health.museum","heimatunduhren.museum","hellas.museum","helsinki.museum","hembygdsforbund.museum","heritage.museum","histoire.museum","historical.museum","historicalsociety.museum","historichouses.museum","historisch.museum","historisches.museum","history.museum","historyofscience.museum","horology.museum","house.museum","humanities.museum","illustration.museum","imageandsound.museum","indian.museum","indiana.museum","indianapolis.museum","indianmarket.museum","intelligence.museum","interactive.museum","iraq.museum","iron.museum","isleofman.museum","jamison.museum","jefferson.museum","jerusalem.museum","jewelry.museum","jewish.museum","jewishart.museum","jfk.museum","journalism.museum","judaica.museum","judygarland.museum","juedisches.museum","juif.museum","karate.museum","karikatur.museum","kids.museum","koebenhavn.museum","koeln.museum","kunst.museum","kunstsammlung.museum","kunstunddesign.museum","labor.museum","labour.museum","lajolla.museum","lancashire.museum","landes.museum","lans.museum","läns.museum","larsson.museum","lewismiller.museum","lincoln.museum","linz.museum","living.museum","livinghistory.museum","localhistory.museum","london.museum","losangeles.museum","louvre.museum","loyalist.museum","lucerne.museum","luxembourg.museum","luzern.museum","mad.museum","madrid.museum","mallorca.museum","manchester.museum","mansion.museum","mansions.museum","manx.museum","marburg.museum","maritime.museum","maritimo.museum","maryland.museum","marylhurst.museum","media.museum","medical.museum","medizinhistorisches.museum","meeres.museum","memorial.museum","mesaverde.museum","michigan.museum","midatlantic.museum","military.museum","mill.museum","miners.museum","mining.museum","minnesota.museum","missile.museum","missoula.museum","modern.museum","moma.museum","money.museum","monmouth.museum","monticello.museum","montreal.museum","moscow.museum","motorcycle.museum","muenchen.museum","muenster.museum","mulhouse.museum","muncie.museum","museet.museum","museumcenter.museum","museumvereniging.museum","music.museum","national.museum","nationalfirearms.museum","nationalheritage.museum","nativeamerican.museum","naturalhistory.museum","naturalhistorymuseum.museum","naturalsciences.museum","nature.museum","naturhistorisches.museum","natuurwetenschappen.museum","naumburg.museum","naval.museum","nebraska.museum","neues.museum","newhampshire.museum","newjersey.museum","newmexico.museum","newport.museum","newspaper.museum","newyork.museum","niepce.museum","norfolk.museum","north.museum","nrw.museum","nuernberg.museum","nuremberg.museum","nyc.museum","nyny.museum","oceanographic.museum","oceanographique.museum","omaha.museum","online.museum","ontario.museum","openair.museum","oregon.museum","oregontrail.museum","otago.museum","oxford.museum","pacific.museum","paderborn.museum","palace.museum","paleo.museum","palmsprings.museum","panama.museum","paris.museum","pasadena.museum","pharmacy.museum","philadelphia.museum","philadelphiaarea.museum","philately.museum","phoenix.museum","photography.museum","pilots.museum","pittsburgh.museum","planetarium.museum","plantation.museum","plants.museum","plaza.museum","portal.museum","portland.museum","portlligat.museum","posts-and-telecommunications.museum","preservation.museum","presidio.museum","press.museum","project.museum","public.museum","pubol.museum","quebec.museum","railroad.museum","railway.museum","research.museum","resistance.museum","riodejaneiro.museum","rochester.museum","rockart.museum","roma.museum","russia.museum","saintlouis.museum","salem.museum","salvadordali.museum","salzburg.museum","sandiego.museum","sanfrancisco.museum","santabarbara.museum","santacruz.museum","santafe.museum","saskatchewan.museum","satx.museum","savannahga.museum","schlesisches.museum","schoenbrunn.museum","schokoladen.museum","school.museum","schweiz.museum","science.museum","scienceandhistory.museum","scienceandindustry.museum","sciencecenter.museum","sciencecenters.museum","science-fiction.museum","sciencehistory.museum","sciences.museum","sciencesnaturelles.museum","scotland.museum","seaport.museum","settlement.museum","settlers.museum","shell.museum","sherbrooke.museum","sibenik.museum","silk.museum","ski.museum","skole.museum","society.museum","sologne.museum","soundandvision.museum","southcarolina.museum","southwest.museum","space.museum","spy.museum","square.museum","stadt.museum","stalbans.museum","starnberg.museum","state.museum","stateofdelaware.museum","station.museum","steam.museum","steiermark.museum","stjohn.museum","stockholm.museum","stpetersburg.museum","stuttgart.museum","suisse.museum","surgeonshall.museum","surrey.museum","svizzera.museum","sweden.museum","sydney.museum","tank.museum","tcm.museum","technology.museum","telekommunikation.museum","television.museum","texas.museum","textile.museum","theater.museum","time.museum","timekeeping.museum","topology.museum","torino.museum","touch.museum","town.museum","transport.museum","tree.museum","trolley.museum","trust.museum","trustee.museum","uhren.museum","ulm.museum","undersea.museum","university.museum","usa.museum","usantiques.museum","usarts.museum","uscountryestate.museum","usculture.museum","usdecorativearts.museum","usgarden.museum","ushistory.museum","ushuaia.museum","uslivinghistory.museum","utah.museum","uvic.museum","valley.museum","vantaa.museum","versailles.museum","viking.museum","village.museum","virginia.museum","virtual.museum","virtuel.museum","vlaanderen.museum","volkenkunde.museum","wales.museum","wallonie.museum","war.museum","washingtondc.museum","watchandclock.museum","watch-and-clock.museum","western.museum","westfalen.museum","whaling.museum","wildlife.museum","williamsburg.museum","windmill.museum","workshop.museum","york.museum","yorkshire.museum","yosemite.museum","youth.museum","zoological.museum","zoology.museum","ירושלים.museum","иком.museum","mv","aero.mv","biz.mv","com.mv","coop.mv","edu.mv","gov.mv","info.mv","int.mv","mil.mv","museum.mv","name.mv","net.mv","org.mv","pro.mv","mw","ac.mw","biz.mw","co.mw","com.mw","coop.mw","edu.mw","gov.mw","int.mw","museum.mw","net.mw","org.mw","mx","com.mx","org.mx","gob.mx","edu.mx","net.mx","my","com.my","net.my","org.my","gov.my","edu.my","mil.my","name.my","mz","ac.mz","adv.mz","co.mz","edu.mz","gov.mz","mil.mz","net.mz","org.mz","na","info.na","pro.na","name.na","school.na","or.na","dr.na","us.na","mx.na","ca.na","in.na","cc.na","tv.na","ws.na","mobi.na","co.na","com.na","org.na","name","nc","asso.nc","nom.nc","ne","net","nf","com.nf","net.nf","per.nf","rec.nf","web.nf","arts.nf","firm.nf","info.nf","other.nf","store.nf","ng","com.ng","edu.ng","gov.ng","i.ng","mil.ng","mobi.ng","name.ng","net.ng","org.ng","sch.ng","ni","ac.ni","biz.ni","co.ni","com.ni","edu.ni","gob.ni","in.ni","info.ni","int.ni","mil.ni","net.ni","nom.ni","org.ni","web.ni","nl","no","fhs.no","vgs.no","fylkesbibl.no","folkebibl.no","museum.no","idrett.no","priv.no","mil.no","stat.no","dep.no","kommune.no","herad.no","aa.no","ah.no","bu.no","fm.no","hl.no","hm.no","jan-mayen.no","mr.no","nl.no","nt.no","of.no","ol.no","oslo.no","rl.no","sf.no","st.no","svalbard.no","tm.no","tr.no","va.no","vf.no","gs.aa.no","gs.ah.no","gs.bu.no","gs.fm.no","gs.hl.no","gs.hm.no","gs.jan-mayen.no","gs.mr.no","gs.nl.no","gs.nt.no","gs.of.no","gs.ol.no","gs.oslo.no","gs.rl.no","gs.sf.no","gs.st.no","gs.svalbard.no","gs.tm.no","gs.tr.no","gs.va.no","gs.vf.no","akrehamn.no","åkrehamn.no","algard.no","ålgård.no","arna.no","brumunddal.no","bryne.no","bronnoysund.no","brønnøysund.no","drobak.no","drøbak.no","egersund.no","fetsund.no","floro.no","florø.no","fredrikstad.no","hokksund.no","honefoss.no","hønefoss.no","jessheim.no","jorpeland.no","jørpeland.no","kirkenes.no","kopervik.no","krokstadelva.no","langevag.no","langevåg.no","leirvik.no","mjondalen.no","mjøndalen.no","mo-i-rana.no","mosjoen.no","mosjøen.no","nesoddtangen.no","orkanger.no","osoyro.no","osøyro.no","raholt.no","råholt.no","sandnessjoen.no","sandnessjøen.no","skedsmokorset.no","slattum.no","spjelkavik.no","stathelle.no","stavern.no","stjordalshalsen.no","stjørdalshalsen.no","tananger.no","tranby.no","vossevangen.no","afjord.no","åfjord.no","agdenes.no","al.no","ål.no","alesund.no","ålesund.no","alstahaug.no","alta.no","áltá.no","alaheadju.no","álaheadju.no","alvdal.no","amli.no","åmli.no","amot.no","åmot.no","andebu.no","andoy.no","andøy.no","andasuolo.no","ardal.no","årdal.no","aremark.no","arendal.no","ås.no","aseral.no","åseral.no","asker.no","askim.no","askvoll.no","askoy.no","askøy.no","asnes.no","åsnes.no","audnedaln.no","aukra.no","aure.no","aurland.no","aurskog-holand.no","aurskog-høland.no","austevoll.no","austrheim.no","averoy.no","averøy.no","balestrand.no","ballangen.no","balat.no","bálát.no","balsfjord.no","bahccavuotna.no","báhccavuotna.no","bamble.no","bardu.no","beardu.no","beiarn.no","bajddar.no","bájddar.no","baidar.no","báidár.no","berg.no","bergen.no","berlevag.no","berlevåg.no","bearalvahki.no","bearalváhki.no","bindal.no","birkenes.no","bjarkoy.no","bjarkøy.no","bjerkreim.no","bjugn.no","bodo.no","bodø.no","badaddja.no","bådåddjå.no","budejju.no","bokn.no","bremanger.no","bronnoy.no","brønnøy.no","bygland.no","bykle.no","barum.no","bærum.no","bo.telemark.no","bø.telemark.no","bo.nordland.no","bø.nordland.no","bievat.no","bievát.no","bomlo.no","bømlo.no","batsfjord.no","båtsfjord.no","bahcavuotna.no","báhcavuotna.no","dovre.no","drammen.no","drangedal.no","dyroy.no","dyrøy.no","donna.no","dønna.no","eid.no","eidfjord.no","eidsberg.no","eidskog.no","eidsvoll.no","eigersund.no","elverum.no","enebakk.no","engerdal.no","etne.no","etnedal.no","evenes.no","evenassi.no","evenášši.no","evje-og-hornnes.no","farsund.no","fauske.no","fuossko.no","fuoisku.no","fedje.no","fet.no","finnoy.no","finnøy.no","fitjar.no","fjaler.no","fjell.no","flakstad.no","flatanger.no","flekkefjord.no","flesberg.no","flora.no","fla.no","flå.no","folldal.no","forsand.no","fosnes.no","frei.no","frogn.no","froland.no","frosta.no","frana.no","fræna.no","froya.no","frøya.no","fusa.no","fyresdal.no","forde.no","førde.no","gamvik.no","gangaviika.no","gáŋgaviika.no","gaular.no","gausdal.no","gildeskal.no","gildeskål.no","giske.no","gjemnes.no","gjerdrum.no","gjerstad.no","gjesdal.no","gjovik.no","gjøvik.no","gloppen.no","gol.no","gran.no","grane.no","granvin.no","gratangen.no","grimstad.no","grong.no","kraanghke.no","kråanghke.no","grue.no","gulen.no","hadsel.no","halden.no","halsa.no","hamar.no","hamaroy.no","habmer.no","hábmer.no","hapmir.no","hápmir.no","hammerfest.no","hammarfeasta.no","hámmárfeasta.no","haram.no","hareid.no","harstad.no","hasvik.no","aknoluokta.no","ákŋoluokta.no","hattfjelldal.no","aarborte.no","haugesund.no","hemne.no","hemnes.no","hemsedal.no","heroy.more-og-romsdal.no","herøy.møre-og-romsdal.no","heroy.nordland.no","herøy.nordland.no","hitra.no","hjartdal.no","hjelmeland.no","hobol.no","hobøl.no","hof.no","hol.no","hole.no","holmestrand.no","holtalen.no","holtålen.no","hornindal.no","horten.no","hurdal.no","hurum.no","hvaler.no","hyllestad.no","hagebostad.no","hægebostad.no","hoyanger.no","høyanger.no","hoylandet.no","høylandet.no","ha.no","hå.no","ibestad.no","inderoy.no","inderøy.no","iveland.no","jevnaker.no","jondal.no","jolster.no","jølster.no","karasjok.no","karasjohka.no","kárášjohka.no","karlsoy.no","galsa.no","gálsá.no","karmoy.no","karmøy.no","kautokeino.no","guovdageaidnu.no","klepp.no","klabu.no","klæbu.no","kongsberg.no","kongsvinger.no","kragero.no","kragerø.no","kristiansand.no","kristiansund.no","krodsherad.no","krødsherad.no","kvalsund.no","rahkkeravju.no","ráhkkerávju.no","kvam.no","kvinesdal.no","kvinnherad.no","kviteseid.no","kvitsoy.no","kvitsøy.no","kvafjord.no","kvæfjord.no","giehtavuoatna.no","kvanangen.no","kvænangen.no","navuotna.no","návuotna.no","kafjord.no","kåfjord.no","gaivuotna.no","gáivuotna.no","larvik.no","lavangen.no","lavagis.no","loabat.no","loabát.no","lebesby.no","davvesiida.no","leikanger.no","leirfjord.no","leka.no","leksvik.no","lenvik.no","leangaviika.no","leaŋgaviika.no","lesja.no","levanger.no","lier.no","lierne.no","lillehammer.no","lillesand.no","lindesnes.no","lindas.no","lindås.no","lom.no","loppa.no","lahppi.no","láhppi.no","lund.no","lunner.no","luroy.no","lurøy.no","luster.no","lyngdal.no","lyngen.no","ivgu.no","lardal.no","lerdal.no","lærdal.no","lodingen.no","lødingen.no","lorenskog.no","lørenskog.no","loten.no","løten.no","malvik.no","masoy.no","måsøy.no","muosat.no","muosát.no","mandal.no","marker.no","marnardal.no","masfjorden.no","meland.no","meldal.no","melhus.no","meloy.no","meløy.no","meraker.no","meråker.no","moareke.no","moåreke.no","midsund.no","midtre-gauldal.no","modalen.no","modum.no","molde.no","moskenes.no","moss.no","mosvik.no","malselv.no","målselv.no","malatvuopmi.no","málatvuopmi.no","namdalseid.no","aejrie.no","namsos.no","namsskogan.no","naamesjevuemie.no","nååmesjevuemie.no","laakesvuemie.no","nannestad.no","narvik.no","narviika.no","naustdal.no","nedre-eiker.no","nes.akershus.no","nes.buskerud.no","nesna.no","nesodden.no","nesseby.no","unjarga.no","unjárga.no","nesset.no","nissedal.no","nittedal.no","nord-aurdal.no","nord-fron.no","nord-odal.no","norddal.no","nordkapp.no","davvenjarga.no","davvenjárga.no","nordre-land.no","nordreisa.no","raisa.no","ráisa.no","nore-og-uvdal.no","notodden.no","naroy.no","nærøy.no","notteroy.no","nøtterøy.no","odda.no","oksnes.no","øksnes.no","oppdal.no","oppegard.no","oppegård.no","orkdal.no","orland.no","ørland.no","orskog.no","ørskog.no","orsta.no","ørsta.no","os.hedmark.no","os.hordaland.no","osen.no","osteroy.no","osterøy.no","ostre-toten.no","østre-toten.no","overhalla.no","ovre-eiker.no","øvre-eiker.no","oyer.no","øyer.no","oygarden.no","øygarden.no","oystre-slidre.no","øystre-slidre.no","porsanger.no","porsangu.no","porsáŋgu.no","porsgrunn.no","radoy.no","radøy.no","rakkestad.no","rana.no","ruovat.no","randaberg.no","rauma.no","rendalen.no","rennebu.no","rennesoy.no","rennesøy.no","rindal.no","ringebu.no","ringerike.no","ringsaker.no","rissa.no","risor.no","risør.no","roan.no","rollag.no","rygge.no","ralingen.no","rælingen.no","rodoy.no","rødøy.no","romskog.no","rømskog.no","roros.no","røros.no","rost.no","røst.no","royken.no","røyken.no","royrvik.no","røyrvik.no","rade.no","råde.no","salangen.no","siellak.no","saltdal.no","salat.no","sálát.no","sálat.no","samnanger.no","sande.more-og-romsdal.no","sande.møre-og-romsdal.no","sande.vestfold.no","sandefjord.no","sandnes.no","sandoy.no","sandøy.no","sarpsborg.no","sauda.no","sauherad.no","sel.no","selbu.no","selje.no","seljord.no","sigdal.no","siljan.no","sirdal.no","skaun.no","skedsmo.no","ski.no","skien.no","skiptvet.no","skjervoy.no","skjervøy.no","skierva.no","skiervá.no","skjak.no","skjåk.no","skodje.no","skanland.no","skånland.no","skanit.no","skánit.no","smola.no","smøla.no","snillfjord.no","snasa.no","snåsa.no","snoasa.no","snaase.no","snåase.no","sogndal.no","sokndal.no","sola.no","solund.no","songdalen.no","sortland.no","spydeberg.no","stange.no","stavanger.no","steigen.no","steinkjer.no","stjordal.no","stjørdal.no","stokke.no","stor-elvdal.no","stord.no","stordal.no","storfjord.no","omasvuotna.no","strand.no","stranda.no","stryn.no","sula.no","suldal.no","sund.no","sunndal.no","surnadal.no","sveio.no","svelvik.no","sykkylven.no","sogne.no","søgne.no","somna.no","sømna.no","sondre-land.no","søndre-land.no","sor-aurdal.no","sør-aurdal.no","sor-fron.no","sør-fron.no","sor-odal.no","sør-odal.no","sor-varanger.no","sør-varanger.no","matta-varjjat.no","mátta-várjjat.no","sorfold.no","sørfold.no","sorreisa.no","sørreisa.no","sorum.no","sørum.no","tana.no","deatnu.no","time.no","tingvoll.no","tinn.no","tjeldsund.no","dielddanuorri.no","tjome.no","tjøme.no","tokke.no","tolga.no","torsken.no","tranoy.no","tranøy.no","tromso.no","tromsø.no","tromsa.no","romsa.no","trondheim.no","troandin.no","trysil.no","trana.no","træna.no","trogstad.no","trøgstad.no","tvedestrand.no","tydal.no","tynset.no","tysfjord.no","divtasvuodna.no","divttasvuotna.no","tysnes.no","tysvar.no","tysvær.no","tonsberg.no","tønsberg.no","ullensaker.no","ullensvang.no","ulvik.no","utsira.no","vadso.no","vadsø.no","cahcesuolo.no","čáhcesuolo.no","vaksdal.no","valle.no","vang.no","vanylven.no","vardo.no","vardø.no","varggat.no","várggát.no","vefsn.no","vaapste.no","vega.no","vegarshei.no","vegårshei.no","vennesla.no","verdal.no","verran.no","vestby.no","vestnes.no","vestre-slidre.no","vestre-toten.no","vestvagoy.no","vestvågøy.no","vevelstad.no","vik.no","vikna.no","vindafjord.no","volda.no","voss.no","varoy.no","værøy.no","vagan.no","vågan.no","voagat.no","vagsoy.no","vågsøy.no","vaga.no","vågå.no","valer.ostfold.no","våler.østfold.no","valer.hedmark.no","våler.hedmark.no","*.np","nr","biz.nr","info.nr","gov.nr","edu.nr","org.nr","net.nr","com.nr","nu","nz","ac.nz","co.nz","cri.nz","geek.nz","gen.nz","govt.nz","health.nz","iwi.nz","kiwi.nz","maori.nz","mil.nz","māori.nz","net.nz","org.nz","parliament.nz","school.nz","om","co.om","com.om","edu.om","gov.om","med.om","museum.om","net.om","org.om","pro.om","onion","org","pa","ac.pa","gob.pa","com.pa","org.pa","sld.pa","edu.pa","net.pa","ing.pa","abo.pa","med.pa","nom.pa","pe","edu.pe","gob.pe","nom.pe","mil.pe","org.pe","com.pe","net.pe","pf","com.pf","org.pf","edu.pf","*.pg","ph","com.ph","net.ph","org.ph","gov.ph","edu.ph","ngo.ph","mil.ph","i.ph","pk","com.pk","net.pk","edu.pk","org.pk","fam.pk","biz.pk","web.pk","gov.pk","gob.pk","gok.pk","gon.pk","gop.pk","gos.pk","info.pk","pl","com.pl","net.pl","org.pl","aid.pl","agro.pl","atm.pl","auto.pl","biz.pl","edu.pl","gmina.pl","gsm.pl","info.pl","mail.pl","miasta.pl","media.pl","mil.pl","nieruchomosci.pl","nom.pl","pc.pl","powiat.pl","priv.pl","realestate.pl","rel.pl","sex.pl","shop.pl","sklep.pl","sos.pl","szkola.pl","targi.pl","tm.pl","tourism.pl","travel.pl","turystyka.pl","gov.pl","ap.gov.pl","ic.gov.pl","is.gov.pl","us.gov.pl","kmpsp.gov.pl","kppsp.gov.pl","kwpsp.gov.pl","psp.gov.pl","wskr.gov.pl","kwp.gov.pl","mw.gov.pl","ug.gov.pl","um.gov.pl","umig.gov.pl","ugim.gov.pl","upow.gov.pl","uw.gov.pl","starostwo.gov.pl","pa.gov.pl","po.gov.pl","psse.gov.pl","pup.gov.pl","rzgw.gov.pl","sa.gov.pl","so.gov.pl","sr.gov.pl","wsa.gov.pl","sko.gov.pl","uzs.gov.pl","wiih.gov.pl","winb.gov.pl","pinb.gov.pl","wios.gov.pl","witd.gov.pl","wzmiuw.gov.pl","piw.gov.pl","wiw.gov.pl","griw.gov.pl","wif.gov.pl","oum.gov.pl","sdn.gov.pl","zp.gov.pl","uppo.gov.pl","mup.gov.pl","wuoz.gov.pl","konsulat.gov.pl","oirm.gov.pl","augustow.pl","babia-gora.pl","bedzin.pl","beskidy.pl","bialowieza.pl","bialystok.pl","bielawa.pl","bieszczady.pl","boleslawiec.pl","bydgoszcz.pl","bytom.pl","cieszyn.pl","czeladz.pl","czest.pl","dlugoleka.pl","elblag.pl","elk.pl","glogow.pl","gniezno.pl","gorlice.pl","grajewo.pl","ilawa.pl","jaworzno.pl","jelenia-gora.pl","jgora.pl","kalisz.pl","kazimierz-dolny.pl","karpacz.pl","kartuzy.pl","kaszuby.pl","katowice.pl","kepno.pl","ketrzyn.pl","klodzko.pl","kobierzyce.pl","kolobrzeg.pl","konin.pl","konskowola.pl","kutno.pl","lapy.pl","lebork.pl","legnica.pl","lezajsk.pl","limanowa.pl","lomza.pl","lowicz.pl","lubin.pl","lukow.pl","malbork.pl","malopolska.pl","mazowsze.pl","mazury.pl","mielec.pl","mielno.pl","mragowo.pl","naklo.pl","nowaruda.pl","nysa.pl","olawa.pl","olecko.pl","olkusz.pl","olsztyn.pl","opoczno.pl","opole.pl","ostroda.pl","ostroleka.pl","ostrowiec.pl","ostrowwlkp.pl","pila.pl","pisz.pl","podhale.pl","podlasie.pl","polkowice.pl","pomorze.pl","pomorskie.pl","prochowice.pl","pruszkow.pl","przeworsk.pl","pulawy.pl","radom.pl","rawa-maz.pl","rybnik.pl","rzeszow.pl","sanok.pl","sejny.pl","slask.pl","slupsk.pl","sosnowiec.pl","stalowa-wola.pl","skoczow.pl","starachowice.pl","stargard.pl","suwalki.pl","swidnica.pl","swiebodzin.pl","swinoujscie.pl","szczecin.pl","szczytno.pl","tarnobrzeg.pl","tgory.pl","turek.pl","tychy.pl","ustka.pl","walbrzych.pl","warmia.pl","warszawa.pl","waw.pl","wegrow.pl","wielun.pl","wlocl.pl","wloclawek.pl","wodzislaw.pl","wolomin.pl","wroclaw.pl","zachpomor.pl","zagan.pl","zarow.pl","zgora.pl","zgorzelec.pl","pm","pn","gov.pn","co.pn","org.pn","edu.pn","net.pn","post","pr","com.pr","net.pr","org.pr","gov.pr","edu.pr","isla.pr","pro.pr","biz.pr","info.pr","name.pr","est.pr","prof.pr","ac.pr","pro","aaa.pro","aca.pro","acct.pro","avocat.pro","bar.pro","cpa.pro","eng.pro","jur.pro","law.pro","med.pro","recht.pro","ps","edu.ps","gov.ps","sec.ps","plo.ps","com.ps","org.ps","net.ps","pt","net.pt","gov.pt","org.pt","edu.pt","int.pt","publ.pt","com.pt","nome.pt","pw","co.pw","ne.pw","or.pw","ed.pw","go.pw","belau.pw","py","com.py","coop.py","edu.py","gov.py","mil.py","net.py","org.py","qa","com.qa","edu.qa","gov.qa","mil.qa","name.qa","net.qa","org.qa","sch.qa","re","asso.re","com.re","nom.re","ro","arts.ro","com.ro","firm.ro","info.ro","nom.ro","nt.ro","org.ro","rec.ro","store.ro","tm.ro","www.ro","rs","ac.rs","co.rs","edu.rs","gov.rs","in.rs","org.rs","ru","ac.ru","edu.ru","gov.ru","int.ru","mil.ru","test.ru","rw","ac.rw","co.rw","coop.rw","gov.rw","mil.rw","net.rw","org.rw","sa","com.sa","net.sa","org.sa","gov.sa","med.sa","pub.sa","edu.sa","sch.sa","sb","com.sb","edu.sb","gov.sb","net.sb","org.sb","sc","com.sc","gov.sc","net.sc","org.sc","edu.sc","sd","com.sd","net.sd","org.sd","edu.sd","med.sd","tv.sd","gov.sd","info.sd","se","a.se","ac.se","b.se","bd.se","brand.se","c.se","d.se","e.se","f.se","fh.se","fhsk.se","fhv.se","g.se","h.se","i.se","k.se","komforb.se","kommunalforbund.se","komvux.se","l.se","lanbib.se","m.se","n.se","naturbruksgymn.se","o.se","org.se","p.se","parti.se","pp.se","press.se","r.se","s.se","t.se","tm.se","u.se","w.se","x.se","y.se","z.se","sg","com.sg","net.sg","org.sg","gov.sg","edu.sg","per.sg","sh","com.sh","net.sh","gov.sh","org.sh","mil.sh","si","sj","sk","sl","com.sl","net.sl","edu.sl","gov.sl","org.sl","sm","sn","art.sn","com.sn","edu.sn","gouv.sn","org.sn","perso.sn","univ.sn","so","com.so","net.so","org.so","sr","st","co.st","com.st","consulado.st","edu.st","embaixada.st","gov.st","mil.st","net.st","org.st","principe.st","saotome.st","store.st","su","sv","com.sv","edu.sv","gob.sv","org.sv","red.sv","sx","gov.sx","sy","edu.sy","gov.sy","net.sy","mil.sy","com.sy","org.sy","sz","co.sz","ac.sz","org.sz","tc","td","tel","tf","tg","th","ac.th","co.th","go.th","in.th","mi.th","net.th","or.th","tj","ac.tj","biz.tj","co.tj","com.tj","edu.tj","go.tj","gov.tj","int.tj","mil.tj","name.tj","net.tj","nic.tj","org.tj","test.tj","web.tj","tk","tl","gov.tl","tm","com.tm","co.tm","org.tm","net.tm","nom.tm","gov.tm","mil.tm","edu.tm","tn","com.tn","ens.tn","fin.tn","gov.tn","ind.tn","intl.tn","nat.tn","net.tn","org.tn","info.tn","perso.tn","tourism.tn","edunet.tn","rnrt.tn","rns.tn","rnu.tn","mincom.tn","agrinet.tn","defense.tn","turen.tn","to","com.to","gov.to","net.to","org.to","edu.to","mil.to","tr","av.tr","bbs.tr","bel.tr","biz.tr","com.tr","dr.tr","edu.tr","gen.tr","gov.tr","info.tr","mil.tr","k12.tr","kep.tr","name.tr","net.tr","org.tr","pol.tr","tel.tr","tsk.tr","tv.tr","web.tr","nc.tr","gov.nc.tr","tt","co.tt","com.tt","org.tt","net.tt","biz.tt","info.tt","pro.tt","int.tt","coop.tt","jobs.tt","mobi.tt","travel.tt","museum.tt","aero.tt","name.tt","gov.tt","edu.tt","tv","tw","edu.tw","gov.tw","mil.tw","com.tw","net.tw","org.tw","idv.tw","game.tw","ebiz.tw","club.tw","網路.tw","組織.tw","商業.tw","tz","ac.tz","co.tz","go.tz","hotel.tz","info.tz","me.tz","mil.tz","mobi.tz","ne.tz","or.tz","sc.tz","tv.tz","ua","com.ua","edu.ua","gov.ua","in.ua","net.ua","org.ua","cherkassy.ua","cherkasy.ua","chernigov.ua","chernihiv.ua","chernivtsi.ua","chernovtsy.ua","ck.ua","cn.ua","cr.ua","crimea.ua","cv.ua","dn.ua","dnepropetrovsk.ua","dnipropetrovsk.ua","dominic.ua","donetsk.ua","dp.ua","if.ua","ivano-frankivsk.ua","kh.ua","kharkiv.ua","kharkov.ua","kherson.ua","khmelnitskiy.ua","khmelnytskyi.ua","kiev.ua","kirovograd.ua","km.ua","kr.ua","krym.ua","ks.ua","kv.ua","kyiv.ua","lg.ua","lt.ua","lugansk.ua","lutsk.ua","lv.ua","lviv.ua","mk.ua","mykolaiv.ua","nikolaev.ua","od.ua","odesa.ua","odessa.ua","pl.ua","poltava.ua","rivne.ua","rovno.ua","rv.ua","sb.ua","sebastopol.ua","sevastopol.ua","sm.ua","sumy.ua","te.ua","ternopil.ua","uz.ua","uzhgorod.ua","vinnica.ua","vinnytsia.ua","vn.ua","volyn.ua","yalta.ua","zaporizhzhe.ua","zaporizhzhia.ua","zhitomir.ua","zhytomyr.ua","zp.ua","zt.ua","ug","co.ug","or.ug","ac.ug","sc.ug","go.ug","ne.ug","com.ug","org.ug","uk","ac.uk","co.uk","gov.uk","ltd.uk","me.uk","net.uk","nhs.uk","org.uk","plc.uk","police.uk","*.sch.uk","us","dni.us","fed.us","isa.us","kids.us","nsn.us","ak.us","al.us","ar.us","as.us","az.us","ca.us","co.us","ct.us","dc.us","de.us","fl.us","ga.us","gu.us","hi.us","ia.us","id.us","il.us","in.us","ks.us","ky.us","la.us","ma.us","md.us","me.us","mi.us","mn.us","mo.us","ms.us","mt.us","nc.us","nd.us","ne.us","nh.us","nj.us","nm.us","nv.us","ny.us","oh.us","ok.us","or.us","pa.us","pr.us","ri.us","sc.us","sd.us","tn.us","tx.us","ut.us","vi.us","vt.us","va.us","wa.us","wi.us","wv.us","wy.us","k12.ak.us","k12.al.us","k12.ar.us","k12.as.us","k12.az.us","k12.ca.us","k12.co.us","k12.ct.us","k12.dc.us","k12.de.us","k12.fl.us","k12.ga.us","k12.gu.us","k12.ia.us","k12.id.us","k12.il.us","k12.in.us","k12.ks.us","k12.ky.us","k12.la.us","k12.ma.us","k12.md.us","k12.me.us","k12.mi.us","k12.mn.us","k12.mo.us","k12.ms.us","k12.mt.us","k12.nc.us","k12.ne.us","k12.nh.us","k12.nj.us","k12.nm.us","k12.nv.us","k12.ny.us","k12.oh.us","k12.ok.us","k12.or.us","k12.pa.us","k12.pr.us","k12.ri.us","k12.sc.us","k12.tn.us","k12.tx.us","k12.ut.us","k12.vi.us","k12.vt.us","k12.va.us","k12.wa.us","k12.wi.us","k12.wy.us","cc.ak.us","cc.al.us","cc.ar.us","cc.as.us","cc.az.us","cc.ca.us","cc.co.us","cc.ct.us","cc.dc.us","cc.de.us","cc.fl.us","cc.ga.us","cc.gu.us","cc.hi.us","cc.ia.us","cc.id.us","cc.il.us","cc.in.us","cc.ks.us","cc.ky.us","cc.la.us","cc.ma.us","cc.md.us","cc.me.us","cc.mi.us","cc.mn.us","cc.mo.us","cc.ms.us","cc.mt.us","cc.nc.us","cc.nd.us","cc.ne.us","cc.nh.us","cc.nj.us","cc.nm.us","cc.nv.us","cc.ny.us","cc.oh.us","cc.ok.us","cc.or.us","cc.pa.us","cc.pr.us","cc.ri.us","cc.sc.us","cc.sd.us","cc.tn.us","cc.tx.us","cc.ut.us","cc.vi.us","cc.vt.us","cc.va.us","cc.wa.us","cc.wi.us","cc.wv.us","cc.wy.us","lib.ak.us","lib.al.us","lib.ar.us","lib.as.us","lib.az.us","lib.ca.us","lib.co.us","lib.ct.us","lib.dc.us","lib.fl.us","lib.ga.us","lib.gu.us","lib.hi.us","lib.ia.us","lib.id.us","lib.il.us","lib.in.us","lib.ks.us","lib.ky.us","lib.la.us","lib.ma.us","lib.md.us","lib.me.us","lib.mi.us","lib.mn.us","lib.mo.us","lib.ms.us","lib.mt.us","lib.nc.us","lib.nd.us","lib.ne.us","lib.nh.us","lib.nj.us","lib.nm.us","lib.nv.us","lib.ny.us","lib.oh.us","lib.ok.us","lib.or.us","lib.pa.us","lib.pr.us","lib.ri.us","lib.sc.us","lib.sd.us","lib.tn.us","lib.tx.us","lib.ut.us","lib.vi.us","lib.vt.us","lib.va.us","lib.wa.us","lib.wi.us","lib.wy.us","pvt.k12.ma.us","chtr.k12.ma.us","paroch.k12.ma.us","ann-arbor.mi.us","cog.mi.us","dst.mi.us","eaton.mi.us","gen.mi.us","mus.mi.us","tec.mi.us","washtenaw.mi.us","uy","com.uy","edu.uy","gub.uy","mil.uy","net.uy","org.uy","uz","co.uz","com.uz","net.uz","org.uz","va","vc","com.vc","net.vc","org.vc","gov.vc","mil.vc","edu.vc","ve","arts.ve","co.ve","com.ve","e12.ve","edu.ve","firm.ve","gob.ve","gov.ve","info.ve","int.ve","mil.ve","net.ve","org.ve","rec.ve","store.ve","tec.ve","web.ve","vg","vi","co.vi","com.vi","k12.vi","net.vi","org.vi","vn","com.vn","net.vn","org.vn","edu.vn","gov.vn","int.vn","ac.vn","biz.vn","info.vn","name.vn","pro.vn","health.vn","vu","com.vu","edu.vu","net.vu","org.vu","wf","ws","com.ws","net.ws","org.ws","gov.ws","edu.ws","yt","امارات","հայ","বাংলা","бг","бел","中国","中國","الجزائر","مصر","ею","გე","ελ","香港","公司.香港","教育.香港","政府.香港","個人.香港","網絡.香港","組織.香港","ಭಾರತ","ଭାରତ","ভাৰত","भारतम्","भारोत","ڀارت","ഭാരതം","भारत","بارت","بھارت","భారత్","ભારત","ਭਾਰਤ","ভারত","இந்தியா","ایران","ايران","عراق","الاردن","한국","қаз","ලංකා","<22><><EFBFBD>லங்கை","المغرب","мкд","мон","澳門","澳门","مليسيا","عمان","پاکستان","پاكستان","فلسطين","срб","пр.срб","орг.срб","обр.срб","од.срб","упр.срб","ак.срб","рф","قطر","السعودية","السعودیة","السعودیۃ","السعوديه","سودان","新加坡","சிங்கப்பூர்","سورية","سوريا","ไทย","ศึกษา.ไทย","ธุรกิจ.ไทย","รัฐบาล.ไทย","ทหาร.ไทย","เน็ต.ไทย","องค์กร.ไทย","تونس","台灣","台湾","臺灣","укр","اليمن","xxx","*.ye","ac.za","agric.za","alt.za","co.za","edu.za","gov.za","grondar.za","law.za","mil.za","net.za","ngo.za","nis.za","nom.za","org.za","school.za","tm.za","web.za","zm","ac.zm","biz.zm","co.zm","com.zm","edu.zm","gov.zm","info.zm","mil.zm","net.zm","org.zm","sch.zm","zw","ac.zw","co.zw","gov.zw","mil.zw","org.zw","aaa","aarp","abarth","abb","abbott","abbvie","abc","able","abogado","abudhabi","academy","accenture","accountant","accountants","aco","actor","adac","ads","adult","aeg","aetna","afamilycompany","afl","africa","agakhan","agency","aig","aigo","airbus","airforce","airtel","akdn","alfaromeo","alibaba","alipay","allfinanz","allstate","ally","alsace","alstom","americanexpress","americanfamily","amex","amfam","amica","amsterdam","analytics","android","anquan","anz","aol","apartments","app","apple","aquarelle","arab","aramco","archi","army","art","arte","asda","associates","athleta","attorney","auction","audi","audible","audio","auspost","author","auto","autos","avianca","aws","axa","azure","baby","baidu","banamex","bananarepublic","band","bank","bar","barcelona","barclaycard","barclays","barefoot","bargains","baseball","basketball","bauhaus","bayern","bbc","bbt","bbva","bcg","bcn","beats","beauty","beer","bentley","berlin","best","bestbuy","bet","bharti","bible","bid","bike","bing","bingo","bio","black","blackfriday","blockbuster","blog","bloomberg","blue","bms","bmw","bnl","bnpparibas","boats","boehringer","bofa","bom","bond","boo","book","booking","bosch","bostik","boston","bot","boutique","box","bradesco","bridgestone","broadway","broker","brother","brussels","budapest","bugatti","build","builders","business","buy","buzz","bzh","cab","cafe","cal","call","calvinklein","cam","camera","camp","cancerresearch","canon","capetown","capital","capitalone","car","caravan","cards","care","career","careers","cars","cartier","casa","case","caseih","cash","casino","catering","catholic","cba","cbn","cbre","cbs","ceb","center","ceo","cern","cfa","cfd","chanel","channel","charity","chase","chat","cheap","chintai","christmas","chrome","chrysler","church","cipriani","circle","cisco","citadel","citi","citic","city","cityeats","claims","cleaning","click","clinic","clinique","clothing","cloud","club","clubmed","coach","codes","coffee","college","cologne","comcast","commbank","community","company","compare","computer","comsec","condos","construction","consulting","contact","contractors","cooking","cookingchannel","cool","corsica","country","coupon","coupons","courses","credit","creditcard","creditunion","cricket","crown","crs","cruise","cruises","csc","cuisinella","cymru","cyou","dabur","dad","dance","data","date","dating","datsun","day","dclk","dds","deal","dealer","deals","degree","delivery","dell","deloitte","delta","democrat","dental","dentist","desi","design","dev","dhl","diamonds","diet","digital","direct","directory","discount","discover","dish","diy","dnp","docs","doctor","dodge","dog","domains","dot","download","drive","dtv","dubai","duck","dunlop","duns","dupont","durban","dvag","dvr","earth","eat","eco","edeka","education","email","emerck","energy","engineer","engineering","enterprises","epson","equipment","ericsson","erni","esq","estate","esurance","etisalat","eurovision","eus","events","everbank","exchange","expert","exposed","express","extraspace","fage","fail","fairwinds","faith","family","fan","fans","farm","farmers","fashion","fast","fedex","feedback","ferrari","ferrero","fiat","fidelity","fido","film","final","finance","financial","fire","firestone","firmdale","fish","fishing","fit","fitness","flickr","flights","flir","florist","flowers","fly","foo","food","foodnetwork","football","ford","forex","forsale","forum","foundation","fox","free","fresenius","frl","frogans","frontdoor","frontier","ftr","fujitsu","fujixerox","fun","fund","furniture","futbol","fyi","gal","gallery","gallo","gallup","game","games","gap","garden","gbiz","gdn","gea","gent","genting","george","ggee","gift","gifts","gives","giving","glade","glass","gle","global","globo","gmail","gmbh","gmo","gmx","godaddy","gold","goldpoint","golf","goo","goodyear","goog","google","gop","got","grainger","graphics","gratis","green","gripe","grocery","group","guardian","gucci","guge","guide","guitars","guru","hair","hamburg","hangout","haus","hbo","hdfc","hdfcbank","health","healthcare","help","helsinki","here","hermes","hgtv","hiphop","hisamitsu","hitachi","hiv","hkt","hockey","holdings","holiday","homedepot","homegoods","homes","homesense","honda","honeywell","horse","hospital","host","hosting","hot","hoteles","hotels","hotmail","house","how","hsbc","hughes","hyatt","hyundai","ibm","icbc","ice","icu","ieee","ifm","ikano","imamat","imdb","immo","immobilien","inc","industries","infiniti","ing","ink","institute","insurance","insure","intel","international","intuit","investments","ipiranga","irish","iselect","ismaili","ist","istanbul","itau","itv","iveco","jaguar","java","jcb","jcp","jeep","jetzt","jewelry","jio","jll","jmp","jnj","joburg","jot","joy","jpmorgan","jprs","juegos","juniper","kaufen","kddi","kerryhotels","kerrylogistics","kerryproperties","kfh","kia","kim","kinder","kindle","kitchen","kiwi","koeln","komatsu","kosher","kpmg","kpn","krd","kred","kuokgroup","kyoto","lacaixa","ladbrokes","lamborghini","lamer","lancaster","lancia","lancome","land","landrover","lanxess","lasalle","lat","latino","latrobe","law","lawyer","lds","lease","leclerc","lefrak","legal","lego","lexus","lgbt","liaison","lidl","life","lifeinsurance","lifestyle","lighting","like","lilly","limited","limo","lincoln","linde","link","lipsy","live","living","lixil","llc","loan","loans","locker","locus","loft","lol","london","lotte","lotto","love","lpl","lplfinancial","ltd","ltda","lundbeck","lupin","luxe","luxury","macys","madrid","maif","maison","makeup","man","management","mango","map","market","marketing","markets","marriott","marshalls","maserati","mattel","mba","mckinsey","med","media","meet","melbourne","meme","memorial","men","menu","merckmsd","metlife","miami","microsoft","mini","mint","mit","mitsubishi","mlb","mls","mma","mobile","mobily","moda","moe","moi","mom","monash","money","monster","mopar","mormon","mortgage","moscow","moto","motorcycles","mov","movie","movistar","msd","mtn","mtr","mutual","nab","nadex","nagoya","nationwide","natura","navy","nba","nec","netbank","netflix","network","neustar","new","newholland","news","next","nextdirect","nexus","nfl","ngo","nhk","nico","nike","nikon","ninja","nissan","nissay","nokia","northwesternmutual","norton","now","nowruz","nowtv","nra","nrw","ntt","nyc","obi","observer","off","office","okinawa","olayan","olayangroup","oldnavy","ollo","omega","one","ong","onl","online","onyourside","ooo","open","oracle","orange","organic","origins","osaka","otsuka","ott","ovh","page","panasonic","paris","pars","partners","parts","party","passagens","pay","pccw","pet","pfizer","pharmacy","phd","philips","phone","photo","photography","photos","physio","piaget","pics","pictet","pictures","pid","pin","ping","pink","pioneer","pizza","place","play","playstation","plumbing","plus","pnc","pohl","poker","politie","porn","pramerica","praxi","press","prime","prod","productions","prof","progressive","promo","properties","property","protection","pru","prudential","pub","pwc","qpon","quebec","quest","qvc","racing","radio","raid","read","realestate","realtor","realty","recipes","red","redstone","redumbrella","rehab","reise","reisen","reit","reliance","ren","rent","rentals","repair","report","republican","rest","restaurant","review","reviews","rexroth","rich","richardli","ricoh","rightathome","ril","rio","rip","rmit","rocher","rocks","rodeo","rogers","room","rsvp","rugby","ruhr","run","rwe","ryukyu","saarland","safe","safety","sakura","sale","salon","samsclub","samsung","sandvik","sandvikcoromant","sanofi","sap","sarl","sas","save","saxo","sbi","sbs","sca","scb","schaeffler","schmidt","scholarships","school","schule","schwarz","science","scjohnson","scor","scot","search","seat","secure","security","seek","select","sener","services","ses","seven","sew","sex","sexy","sfr","shangrila","sharp","shaw","shell","shia","shiksha","shoes","shop","shopping","shouji","show","showtime","shriram","silk","sina","singles","site","ski","skin","sky","skype","sling","smart","smile","sncf","soccer","social","softbank","software","sohu","solar","solutions","song","sony","soy","space","sport","spot","spreadbetting","srl","srt","stada","staples","star","starhub","statebank","statefarm","stc","stcgroup","stockholm","storage","store","stream","studio","study","style","sucks","supplies","supply","support","surf","surgery","suzuki","swatch","swiftcover","swiss","sydney","symantec","systems","tab","taipei","talk","taobao","target","tatamotors","tatar","tattoo","tax","taxi","tci","tdk","team","tech","technology","telefonica","temasek","tennis","teva","thd","theater","theatre","tiaa","tickets","tienda","tiffany","tips","tires","tirol","tjmaxx","tjx","tkmaxx","tmall","today","tokyo","tools","top","toray","toshiba","total","tours","town","toyota","toys","trade","trading","training","travel","travelchannel","travelers","travelersinsurance","trust","trv","tube","tui","tunes","tushu","tvs","ubank","ubs","uconnect","unicom","university","uno","uol","ups","vacations","vana","vanguard","vegas","ventures","verisign","versicherung","vet","viajes","video","vig","viking","villas","vin","vip","virgin","visa","vision","vistaprint","viva","vivo","vlaanderen","vodka","volkswagen","volvo","vote","voting","voto","voyage","vuelos","wales","walmart","walter","wang","wanggou","warman","watch","watches","weather","weatherchannel","webcam","weber","website","wed","wedding","weibo","weir","whoswho","wien","wiki","williamhill","win","windows","wine","winners","wme","wolterskluwer","woodside","work","works","world","wow","wtc","wtf","xbox","xerox","xfinity","xihuan","xin","कॉम","セール","佛山","慈善","集团","在线","大众汽车","点看","คอม","八卦","موقع","公益","公司","香格里拉","网站","移动","我爱你","москва","католик","онлайн","сайт","联通","קום","时尚","微博","淡马锡","ファッション","орг","नेट","ストア","삼성","商标","商店","商城","дети","ポイント","新闻","工行","家電","كوم","中文网","中信","娱乐","谷歌","電訊盈科","购物","クラウド","通販","网店","संगठन","餐厅","网络","ком","诺基亚","食品","飞利浦","手表","手机","ارامكو","العليان","اتصالات","بازار","موبايلي","ابوظبي","كاثوليك","همراه","닷컴","政府","شبكة","بيتك","عرب","机构","组织机构","健康","招聘","рус","珠宝","大拿","みんな","グーグル","世界","書籍","网址","닷넷","コム","天主教","游戏","vermögensberater","vermögensberatung","企业","信息","嘉里大酒店","嘉里","广东","政务","xyz","yachts","yahoo","yamaxun","yandex","yodobashi","yoga","yokohama","you","youtube","yun","zappos","zara","zero","zip","zone","zuerich","cc.ua","inf.ua","ltd.ua","beep.pl","barsy.ca","*.compute.estate","*.alces.network","alwaysdata.net","cloudfront.net","*.compute.amazonaws.com","*.compute-1.amazonaws.com","*.compute.amazonaws.com.cn","us-east-1.amazonaws.com","cn-north-1.eb.amazonaws.com.cn","cn-northwest-1.eb.amazonaws.com.cn","elasticbeanstalk.com","ap-northeast-1.elasticbeanstalk.com","ap-northeast-2.elasticbeanstalk.com","ap-northeast-3.elasticbeanstalk.com","ap-south-1.elasticbeanstalk.com","ap-southeast-1.elasticbeanstalk.com","ap-southeast-2.elasticbeanstalk.com","ca-central-1.elasticbeanstalk.com","eu-central-1.elasticbeanstalk.com","eu-west-1.elasticbeanstalk.com","eu-west-2.elasticbeanstalk.com","eu-west-3.elasticbeanstalk.com","sa-east-1.elasticbeanstalk.com","us-east-1.elasticbeanstalk.com","us-east-2.elasticbeanstalk.com","us-gov-west-1.elasticbeanstalk.com","us-west-1.elasticbeanstalk.com","us-west-2.elasticbeanstalk.com","*.elb.amazonaws.com","*.elb.amazonaws.com.cn","s3.amazonaws.com","s3-ap-northeast-1.amazonaws.com","s3-ap-northeast-2.amazonaws.com","s3-ap-south-1.amazonaws.com","s3-ap-southeast-1.amazonaws.com","s3-ap-southeast-2.amazonaws.com","s3-ca-central-1.amazonaws.com","s3-eu-central-1.amazonaws.com","s3-eu-west-1.amazonaws.com","s3-eu-west-2.amazonaws.com","s3-eu-west-3.amazonaws.com","s3-external-1.amazonaws.com","s3-fips-us-gov-west-1.amazonaws.com","s3-sa-east-1.amazonaws.com","s3-us-gov-west-1.amazonaws.com","s3-us-east-2.amazonaws.com","s3-us-west-1.amazonaws.com","s3-us-west-2.amazonaws.com","s3.ap-northeast-2.amazonaws.com","s3.ap-south-1.amazonaws.com","s3.cn-north-1.amazonaws.com.cn","s3.ca-central-1.amazonaws.com","s3.eu-central-1.amazonaws.com","s3.eu-west-2.amazonaws.com","s3.eu-west-3.amazonaws.com","s3.us-east-2.amazonaws.com","s3.dualstack.ap-northeast-1.amazonaws.com","s3.dualstack.ap-northeast-2.amazonaws.com","s3.dualstack.ap-south-1.amazonaws.com","s3.dualstack.ap-southeast-1.amazonaws.com","s3.dualstack.ap-southeast-2.amazonaws.com","s3.dualstack.ca-central-1.amazonaws.com","s3.dualstack.eu-central-1.amazonaws.com","s3.dualstack.eu-west-1.amazonaws.com","s3.dualstack.eu-west-2.amazonaws.com","s3.dualstack.eu-west-3.amazonaws.com","s3.dualstack.sa-east-1.amazonaws.com","s3.dualstack.us-east-1.amazonaws.com","s3.dualstack.us-east-2.amazonaws.com","s3-website-us-east-1.amazonaws.com","s3-website-us-west-1.amazonaws.com","s3-website-us-west-2.amazonaws.com","s3-website-ap-northeast-1.amazonaws.com","s3-website-ap-southeast-1.amazonaws.com","s3-website-ap-southeast-2.amazonaws.com","s3-website-eu-west-1.amazonaws.com","s3-website-sa-east-1.amazonaws.com","s3-website.ap-northeast-2.amazonaws.com","s3-website.ap-south-1.amazonaws.com","s3-website.ca-central-1.amazonaws.com","s3-website.eu-central-1.amazonaws.com","s3-website.eu-west-2.amazonaws.com","s3-website.eu-west-3.amazonaws.com","s3-website.us-east-2.amazonaws.com","t3l3p0rt.net","tele.amune.org","apigee.io","on-aptible.com","user.party.eus","pimienta.org","poivron.org","potager.org","sweetpepper.org","myasustor.com","go-vip.co","go-vip.net","wpcomstaging.com","myfritz.net","*.awdev.ca","*.advisor.ws","b-data.io","backplaneapp.io","balena-devices.com","app.banzaicloud.io","betainabox.com","bnr.la","blackbaudcdn.net","boomla.net","boxfuse.io","square7.ch","bplaced.com","bplaced.de","square7.de","bplaced.net","square7.net","browsersafetymark.io","uk0.bigv.io","dh.bytemark.co.uk","vm.bytemark.co.uk","mycd.eu","carrd.co","crd.co","uwu.ai","ae.org","ar.com","br.com","cn.com","com.de","com.se","de.com","eu.com","gb.com","gb.net","hu.com","hu.net","jp.net","jpn.com","kr.com","mex.com","no.com","qc.com","ru.com","sa.com","se.net","uk.com","uk.net","us.com","uy.com","za.bz","za.com","africa.com","gr.com","in.net","us.org","co.com","c.la","certmgr.org","xenapponazure.com","discourse.group","virtueeldomein.nl","cleverapps.io","*.lcl.dev","*.stg.dev","c66.me","cloud66.ws","cloud66.zone","jdevcloud.com","wpdevcloud.com","cloudaccess.host","freesite.host","cloudaccess.net","cloudcontrolled.com","cloudcontrolapp.com","cloudera.site","workers.dev","wnext.app","co.ca","*.otap.co","co.cz","c.cdn77.org","cdn77-ssl.net","r.cdn77.net","rsc.cdn77.org","ssl.origin.cdn77-secure.org","cloudns.asia","cloudns.biz","cloudns.club","cloudns.cc","cloudns.eu","cloudns.in","cloudns.info","cloudns.org","cloudns.pro","cloudns.pw","cloudns.us","cloudeity.net","cnpy.gdn","co.nl","co.no","webhosting.be","hosting-cluster.nl","dyn.cosidns.de","dynamisches-dns.de","dnsupdater.de","internet-dns.de","l-o-g-i-n.de","dynamic-dns.info","feste-ip.net","knx-server.net","static-access.net","realm.cz","*.cryptonomic.net","cupcake.is","cyon.link","cyon.site","daplie.me","localhost.daplie.me","dattolocal.com","dattorelay.com","dattoweb.com","mydatto.com","dattolocal.net","mydatto.net","biz.dk","co.dk","firm.dk","reg.dk","store.dk","*.dapps.earth","*.bzz.dapps.earth","debian.net","dedyn.io","dnshome.de","online.th","shop.th","drayddns.com","dreamhosters.com","mydrobo.com","drud.io","drud.us","duckdns.org","dy.fi","tunk.org","dyndns-at-home.com","dyndns-at-work.com","dyndns-blog.com","dyndns-free.com","dyndns-home.com","dyndns-ip.com","dyndns-mail.com","dyndns-office.com","dyndns-pics.com","dyndns-remote.com","dyndns-server.com","dyndns-web.com","dyndns-wiki.com","dyndns-work.com","dyndns.biz","dyndns.info","dyndns.org","dyndns.tv","at-band-camp.net","ath.cx","barrel-of-knowledge.info","barrell-of-knowledge.info","better-than.tv","blogdns.com","blogdns.net","blogdns.org","blogsite.org","boldlygoingnowhere.org","broke-it.net","buyshouses.net","cechire.com","dnsalias.com","dnsalias.net","dnsalias.org","dnsdojo.com","dnsdojo.net","dnsdojo.org","does-it.net","doesntexist.com","doesntexist.org","dontexist.com","dontexist.net","dontexist.org","doomdns.com","doomdns.org","dvrdns.org","dyn-o-saur.com","dynalias.com","dynalias.net","dynalias.org","dynathome.net","dyndns.ws","endofinternet.net","endofinternet.org","endoftheinternet.org","est-a-la-maison.com","est-a-la-masion.com","est-le-patron.com","est-mon-blogueur.com","for-better.biz","for-more.biz","for-our.info","for-some.biz","for-the.biz","forgot.her.name","forgot.his.name","from-ak.com","from-al.com","from-ar.com","from-az.net","from-ca.com","from-co.net","from-ct.com","from-dc.com","from-de.com","from-fl.com","from-ga.com","from-hi.com","from-ia.com","from-id.com","from-il.com","from-in.com","from-ks.com","from-ky.com","from-la.net","from-ma.com","from-md.com","from-me.org","from-mi.com","from-mn.com","from-mo.com","from-ms.com","from-mt.com","from-nc.com","from-nd.com","from-ne.com","from-nh.com","from-nj.com","from-nm.com","from-nv.com","from-ny.net","from-oh.com","from-ok.com","from-or.com","from-pa.com","from-pr.com","from-ri.com","from-sc.com","from-sd.com","from-tn.com","from-tx.com","from-ut.com","from-va.com","from-vt.com","from-wa.com","from-wi.com","from-wv.com","from-wy.com","ftpaccess.cc","fuettertdasnetz.de","game-host.org","game-server.cc","getmyip.com","gets-it.net","go.dyndns.org","gotdns.com","gotdns.org","groks-the.info","groks-this.info","ham-radio-op.net","here-for-more.info","hobby-site.com","hobby-site.org","home.dyndns.org","homedns.org","homeftp.net","homeftp.org","homeip.net","homelinux.com","homelinux.net","homelinux.org","homeunix.com","homeunix.net","homeunix.org","iamallama.com","in-the-band.net","is-a-anarchist.com","is-a-blogger.com","is-a-bookkeeper.com","is-a-bruinsfan.org","is-a-bulls-fan.com","is-a-candidate.org","is-a-caterer.com","is-a-celticsfan.org","is-a-chef.com","is-a-chef.net","is-a-chef.org","is-a-conservative.com","is-a-cpa.com","is-a-cubicle-slave.com","is-a-democrat.com","is-a-designer.com","is-a-doctor.com","is-a-financialadvisor.com","is-a-geek.com","is-a-geek.net","is-a-geek.org","is-a-green.com","is-a-guru.com","is-a-hard-worker.com","is-a-hunter.com","is-a-knight.org","is-a-landscaper.com","is-a-lawyer.com","is-a-liberal.com","is-a-libertarian.com","is-a-linux-user.org","is-a-llama.com","is-a-musician.com","is-a-nascarfan.com","is-a-nurse.com","is-a-painter.com","is-a-patsfan.org","is-a-personaltrainer.com","is-a-photographer.com","is-a-player.com","is-a-republican.com","is-a-rockstar.com","is-a-socialist.com","is-a-soxfan.org","is-a-student.com","is-a-teacher.com","is-a-techie.com","is-a-therapist.com","is-an-accountant.com","is-an-actor.com","is-an-actress.com","is-an-anarchist.com","is-an-artist.com","is-an-engineer.com","is-an-entertainer.com","is-by.us","is-certified.com","is-found.org","is-gone.com","is-into-anime.com","is-into-cars.com","is-into-cartoons.com","is-into-games.com","is-leet.com","is-lost.org","is-not-certified.com","is-saved.org","is-slick.com","is-uberleet.com","is-very-bad.org","is-very-evil.org","is-very-good.org","is-very-nice.org","is-very-sweet.org","is-with-theband.com","isa-geek.com","isa-geek.net","isa-geek.org","isa-hockeynut.com","issmarterthanyou.com","isteingeek.de","istmein.de","kicks-ass.net","kicks-ass.org","knowsitall.info","land-4-sale.us","lebtimnetz.de","leitungsen.de","likes-pie.com","likescandy.com","merseine.nu","mine.nu","misconfused.org","mypets.ws","myphotos.cc","neat-url.com","office-on-the.net","on-the-web.tv","podzone.net","podzone.org","readmyblog.org","saves-the-whales.com","scrapper-site.net","scrapping.cc","selfip.biz","selfip.com","selfip.info","selfip.net","selfip.org","sells-for-less.com","sells-for-u.com","sells-it.net","sellsyourhome.org","servebbs.com","servebbs.net","servebbs.org","serveftp.net","serveftp.org","servegame.org","shacknet.nu","simple-url.com","space-to-rent.com","stuff-4-sale.org","stuff-4-sale.us","teaches-yoga.com","thruhere.net","traeumtgerade.de","webhop.biz","webhop.info","webhop.net","webhop.org","worse-than.tv","writesthisblog.com","ddnss.de","dyn.ddnss.de","dyndns.ddnss.de","dyndns1.de","dyn-ip24.de","home-webserver.de","dyn.home-webserver.de","myhome-server.de","ddnss.org","definima.net","definima.io","bci.dnstrace.pro","ddnsfree.com","ddnsgeek.com","giize.com","gleeze.com","kozow.com","loseyourip.com","ooguy.com","theworkpc.com","casacam.net","dynu.net","accesscam.org","camdvr.org","freeddns.org","mywire.org","webredirect.org","myddns.rocks","blogsite.xyz","dynv6.net","e4.cz","mytuleap.com","onred.one","staging.onred.one","enonic.io","customer.enonic.io","eu.org","al.eu.org","asso.eu.org","at.eu.org","au.eu.org","be.eu.org","bg.eu.org","ca.eu.org","cd.eu.org","ch.eu.org","cn.eu.org","cy.eu.org","cz.eu.org","de.eu.org","dk.eu.org","edu.eu.org","ee.eu.org","es.eu.org","fi.eu.org","fr.eu.org","gr.eu.org","hr.eu.org","hu.eu.org","ie.eu.org","il.eu.org","in.eu.org","int.eu.org","is.eu.org","it.eu.org","jp.eu.org","kr.eu.org","lt.eu.org","lu.eu.org","lv.eu.org","mc.eu.org","me.eu.org","mk.eu.org","mt.eu.org","my.eu.org","net.eu.org","ng.eu.org","nl.eu.org","no.eu.org","nz.eu.org","paris.eu.org","pl.eu.org","pt.eu.org","q-a.eu.org","ro.eu.org","ru.eu.org","se.eu.org","si.eu.org","sk.eu.org","tr.eu.org","uk.eu.org","us.eu.org","eu-1.evennode.com","eu-2.evennode.com","eu-3.evennode.com","eu-4.evennode.com","us-1.evennode.com","us-2.evennode.com","us-3.evennode.com","us-4.evennode.com","twmail.cc","twmail.net","twmail.org","mymailer.com.tw","url.tw","apps.fbsbx.com","ru.net","adygeya.ru","bashkiria.ru","bir.ru","cbg.ru","com.ru","dagestan.ru","grozny.ru","kalmykia.ru","kustanai.ru","marine.ru","mordovia.ru","msk.ru","mytis.ru","nalchik.ru","nov.ru","pyatigorsk.ru","spb.ru","vladikavkaz.ru","vladimir.ru","abkhazia.su","adygeya.su","aktyubinsk.su","arkhangelsk.su","armenia.su","ashgabad.su","azerbaijan.su","balashov.su","bashkiria.su","bryansk.su","bukhara.su","chimkent.su","dagestan.su","east-kazakhstan.su","exnet.su","georgia.su","grozny.su","ivanovo.su","jambyl.su","kalmykia.su","kaluga.su","karacol.su","karaganda.su","karelia.su","khakassia.su","krasnodar.su","kurgan.su","kustanai.su","lenug.su","mangyshlak.su","mordovia.su","msk.su","murmansk.su","nalchik.su","navoi.su","north-kazakhstan.su","nov.su","obninsk.su","penza.su","pokrovsk.su","sochi.su","spb.su","tashkent.su","termez.su","togliatti.su","troitsk.su","tselinograd.su","tula.su","tuva.su","vladikavkaz.su","vladimir.su","vologda.su","channelsdvr.net","fastly-terrarium.com","fastlylb.net","map.fastlylb.net","freetls.fastly.net","map.fastly.net","a.prod.fastly.net","global.prod.fastly.net","a.ssl.fastly.net","b.ssl.fastly.net","global.ssl.fastly.net","fastpanel.direct","fastvps-server.com","fhapp.xyz","fedorainfracloud.org","fedorapeople.org","cloud.fedoraproject.org","app.os.fedoraproject.org","app.os.stg.fedoraproject.org","mydobiss.com","filegear.me","filegear-au.me","filegear-de.me","filegear-gb.me","filegear-ie.me","filegear-jp.me","filegear-sg.me","firebaseapp.com","flynnhub.com","flynnhosting.net","freebox-os.com","freeboxos.com","fbx-os.fr","fbxos.fr","freebox-os.fr","freeboxos.fr","freedesktop.org","*.futurecms.at","*.ex.futurecms.at","*.in.futurecms.at","futurehosting.at","futuremailing.at","*.ex.ortsinfo.at","*.kunden.ortsinfo.at","*.statics.cloud","service.gov.uk","gehirn.ne.jp","usercontent.jp","lab.ms","github.io","githubusercontent.com","gitlab.io","glitch.me","cloudapps.digital","london.cloudapps.digital","homeoffice.gov.uk","ro.im","shop.ro","goip.de","run.app","a.run.app","web.app","*.0emm.com","appspot.com","blogspot.ae","blogspot.al","blogspot.am","blogspot.ba","blogspot.be","blogspot.bg","blogspot.bj","blogspot.ca","blogspot.cf","blogspot.ch","blogspot.cl","blogspot.co.at","blogspot.co.id","blogspot.co.il","blogspot.co.ke","blogspot.co.nz","blogspot.co.uk","blogspot.co.za","blogspot.com","blogspot.com.ar","blogspot.com.au","blogspot.com.br","blogspot.com.by","blogspot.com.co","blogspot.com.cy","blogspot.com.ee","blogspot.com.eg","blogspot.com.es","blogspot.com.mt","blogspot.com.ng","blogspot.com.tr","blogspot.com.uy","blogspot.cv","blogspot.cz","blogspot.de","blogspot.dk","blogspot.fi","blogspot.fr","blogspot.gr","blogspot.hk","blogspot.hr","blogspot.hu","blogspot.ie","blogspot.in","blogspot.is","blogspot.it","blogspot.jp","blogspot.kr","blogspot.li","blogspot.lt","blogspot.lu","blogspot.md","blogspot.mk","blogspot.mr","blogspot.mx","blogspot.my","blogspot.nl","blogspot.no","blogspot.pe","blogspot.pt","blogspot.qa","blogspot.re","blogspot.ro","blogspot.rs","blogspot.ru","blogspot.se","blogspot.sg","blogspot.si","blogspot.sk","blogspot.sn","blogspot.td","blogspot.tw","blogspot.ug","blogspot.vn","cloudfunctions.net","cloud.goog","codespot.com","googleapis.com","googlecode.com","pagespeedmobilizer.com","publishproxy.com","withgoogle.com","withyoutube.com","fin.ci","free.hr","caa.li","ua.rs","conf.se","hashbang.sh","hasura.app","hasura-app.io","hepforge.org","herokuapp.com","herokussl.com","myravendb.com","ravendb.community","ravendb.me","development.run","ravendb.run","bpl.biz","orx.biz","ng.city","ng.ink","biz.gl","col.ng","gen.ng","ltd.ng","sch.so","häkkinen.fi","*.moonscale.io","moonscale.net","iki.fi","dyn-berlin.de","in-berlin.de","in-brb.de","in-butter.de","in-dsl.de","in-dsl.net","in-dsl.org","in-vpn.de","in-vpn.net","in-vpn.org","biz.at","info.at","info.cx","ac.leg.br","al.leg.br","am.leg.br","ap.leg.br","ba.leg.br","ce.leg.br","df.leg.br","es.leg.br","go.leg.br","ma.leg.br","mg.leg.br","ms.leg.br","mt.leg.br","pa.leg.br","pb.leg.br","pe.leg.br","pi.leg.br","pr.leg.br","rj.leg.br","rn.leg.br","ro.leg.br","rr.leg.br","rs.leg.br","sc.leg.br","se.leg.br","sp.leg.br","to.leg.br","pixolino.com","ipifony.net","mein-iserv.de","test-iserv.de","iobb.net","myjino.ru","*.hosting.myjino.ru","*.landing.myjino.ru","*.spectrum.myjino.ru","*.vps.myjino.ru","*.triton.zone","*.cns.joyent.com","js.org","kaas.gg","khplay.nl","keymachine.de","kinghost.net","uni5.net","knightpoint.systems","co.krd","edu.krd","git-repos.de","lcube-server.de","svn-repos.de","leadpages.co","lpages.co","lpusercontent.com","co.business","co.education","co.events","co.financial","co.network","co.place","co.technology","app.lmpm.com","linkitools.space","linkyard.cloud","linkyard-cloud.ch","members.linode.com","nodebalancer.linode.com","we.bs","loginline.app","loginline.dev","loginline.io","loginline.services","loginline.site","krasnik.pl","leczna.pl","lubartow.pl","lublin.pl","poniatowa.pl","swidnik.pl","uklugs.org","glug.org.uk","lug.org.uk","lugs.org.uk","barsy.bg","barsy.co.uk","barsyonline.co.uk","barsycenter.com","barsyonline.com","barsy.club","barsy.de","barsy.eu","barsy.in","barsy.info","barsy.io","barsy.me","barsy.menu","barsy.mobi","barsy.net","barsy.online","barsy.org","barsy.pro","barsy.pub","barsy.shop","barsy.site","barsy.support","barsy.uk","*.magentosite.cloud","mayfirst.info","mayfirst.org","hb.cldmail.ru","miniserver.com","memset.net","cloud.metacentrum.cz","custom.metacentrum.cz","flt.cloud.muni.cz","usr.cloud.muni.cz","meteorapp.com","eu.meteorapp.com","co.pl","azurecontainer.io","azurewebsites.net","azure-mobile.net","cloudapp.net","mozilla-iot.org","bmoattachments.org","net.ru","org.ru","pp.ru","ui.nabu.casa","pony.club","of.fashion","on.fashion","of.football","in.london","of.london","for.men","and.mom","for.mom","for.one","for.sale","of.work","to.work","nctu.me","bitballoon.com","netlify.com","4u.com","ngrok.io","nh-serv.co.uk","nfshost.com","dnsking.ch","mypi.co","n4t.co","001www.com","ddnslive.com","myiphost.com","forumz.info","16-b.it","32-b.it","64-b.it","soundcast.me","tcp4.me","dnsup.net","hicam.net","now-dns.net","ownip.net","vpndns.net","dynserv.org","now-dns.org","x443.pw","now-dns.top","ntdll.top","freeddns.us","crafting.xyz","zapto.xyz","nsupdate.info","nerdpol.ovh","blogsyte.com","brasilia.me","cable-modem.org","ciscofreak.com","collegefan.org","couchpotatofries.org","damnserver.com","ddns.me","ditchyourip.com","dnsfor.me","dnsiskinky.com","dvrcam.info","dynns.com","eating-organic.net","fantasyleague.cc","geekgalaxy.com","golffan.us","health-carereform.com","homesecuritymac.com","homesecuritypc.com","hopto.me","ilovecollege.info","loginto.me","mlbfan.org","mmafan.biz","myactivedirectory.com","mydissent.net","myeffect.net","mymediapc.net","mypsx.net","mysecuritycamera.com","mysecuritycamera.net","mysecuritycamera.org","net-freaks.com","nflfan.org","nhlfan.net","no-ip.ca","no-ip.co.uk","no-ip.net","noip.us","onthewifi.com","pgafan.net","point2this.com","pointto.us","privatizehealthinsurance.net","quicksytes.com","read-books.org","securitytactics.com","serveexchange.com","servehumour.com","servep2p.com","servesarcasm.com","stufftoread.com","ufcfan.org","unusualperson.com","workisboring.com","3utilities.com","bounceme.net","ddns.net","ddnsking.com","gotdns.ch","hopto.org","myftp.biz","myftp.org","myvnc.com","no-ip.biz","no-ip.info","no-ip.org","noip.me","redirectme.net","servebeer.com","serveblog.net","servecounterstrike.com","serveftp.com","servegame.com","servehalflife.com","servehttp.com","serveirc.com","serveminecraft.net","servemp3.com","servepics.com","servequake.com","sytes.net","webhop.me","zapto.org","stage.nodeart.io","nodum.co","nodum.io","pcloud.host","nyc.mn","nom.ae","nom.af","nom.ai","nom.al","nym.by","nym.bz","nom.cl","nom.gd","nom.ge","nom.gl","nym.gr","nom.gt","nym.gy","nom.hn","nym.ie","nom.im","nom.ke","nym.kz","nym.la","nym.lc","nom.li","nym.li","nym.lt","nym.lu","nym.me","nom.mk","nym.mn","nym.mx","nom.nu","nym.nz","nym.pe","nym.pt","nom.pw","nom.qa","nym.ro","nom.rs","nom.si","nym.sk","nom.st","nym.su","nym.sx","nom.tj","nym.tw","nom.ug","nom.uy","nom.vc","nom.vg","cya.gg","cloudycluster.net","nid.io","opencraft.hosting","operaunite.com","outsystemscloud.com","ownprovider.com","own.pm","ox.rs","oy.lc","pgfog.com","pagefrontapp.com","art.pl","gliwice.pl","krakow.pl","poznan.pl","wroc.pl","zakopane.pl","pantheonsite.io","gotpantheon.com","mypep.link","on-web.fr","*.platform.sh","*.platformsh.site","dyn53.io","co.bn","xen.prgmr.com","priv.at","prvcy.page","*.dweb.link","protonet.io","chirurgiens-dentistes-en-france.fr","byen.site","instantcloud.cn","ras.ru","qa2.com","dev-myqnapcloud.com","alpha-myqnapcloud.com","myqnapcloud.com","*.quipelements.com","vapor.cloud","vaporcloud.io","rackmaze.com","rackmaze.net","*.on-rancher.cloud","*.on-rio.io","readthedocs.io","rhcloud.com","app.render.com","onrender.com","repl.co","repl.run","resindevice.io","devices.resinstaging.io","hzc.io","wellbeingzone.eu","ptplus.fit","wellbeingzone.co.uk","git-pages.rit.edu","sandcats.io","logoip.de","logoip.com","schokokeks.net","scrysec.com","firewall-gateway.com","firewall-gateway.de","my-gateway.de","my-router.de","spdns.de","spdns.eu","firewall-gateway.net","my-firewall.org","myfirewall.org","spdns.org","*.s5y.io","*.sensiosite.cloud","biz.ua","co.ua","pp.ua","shiftedit.io","myshopblocks.com","mo-siemens.io","1kapp.com","appchizi.com","applinzi.com","sinaapp.com","vipsinaapp.com","siteleaf.net","bounty-full.com","alpha.bounty-full.com","beta.bounty-full.com","stackhero-network.com","static.land","dev.static.land","sites.static.land","apps.lair.io","*.stolos.io","spacekit.io","customer.speedpartner.de","api.stdlib.com","storj.farm","utwente.io","soc.srcf.net","user.srcf.net","temp-dns.com","applicationcloud.io","scapp.io","syncloud.it","diskstation.me","dscloud.biz","dscloud.me","dscloud.mobi","dsmynas.com","dsmynas.net","dsmynas.org","familyds.com","familyds.net","familyds.org","i234.me","myds.me","synology.me","vpnplus.to","taifun-dns.de","gda.pl","gdansk.pl","gdynia.pl","med.pl","sopot.pl","edugit.org","telebit.app","telebit.io","*.telebit.xyz","gwiddle.co.uk","thingdustdata.com","cust.dev.thingdust.io","cust.disrec.thingdust.io","cust.prod.thingdust.io","cust.testing.thingdust.io","arvo.network","azimuth.network","bloxcms.com","townnews-staging.com","12hp.at","2ix.at","4lima.at","lima-city.at","12hp.ch","2ix.ch","4lima.ch","lima-city.ch","trafficplex.cloud","de.cool","12hp.de","2ix.de","4lima.de","lima-city.de","1337.pictures","clan.rip","lima-city.rocks","webspace.rocks","lima.zone","*.transurl.be","*.transurl.eu","*.transurl.nl","tuxfamily.org","dd-dns.de","diskstation.eu","diskstation.org","dray-dns.de","draydns.de","dyn-vpn.de","dynvpn.de","mein-vigor.de","my-vigor.de","my-wan.de","syno-ds.de","synology-diskstation.de","synology-ds.de","uber.space","*.uberspace.de","hk.com","hk.org","ltd.hk","inc.hk","virtualuser.de","virtual-user.de","lib.de.us","2038.io","router.management","v-info.info","voorloper.cloud","wafflecell.com","wedeploy.io","wedeploy.me","wedeploy.sh","remotewd.com","wmflabs.org","half.host","xnbay.com","u2.xnbay.com","u2-local.xnbay.com","cistron.nl","demon.nl","xs4all.space","official.academy","yolasite.com","ybo.faith","yombo.me","homelink.one","ybo.party","ybo.review","ybo.science","ybo.trade","nohost.me","noho.st","za.net","za.org","now.sh","bss.design","basicserver.io","virtualserver.io","site.builder.nu","enterprisecloud.nu","zone.id"]},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(609).Store,i=n(610).permuteDomain,o=n(611).pathMatch,s=n(14);function a(){r.call(this),this.idx={}}s.inherits(a,r),t.MemoryCookieStore=a,a.prototype.idx=null,a.prototype.synchronous=!0,a.prototype.inspect=function(){return"{ idx: "+s.inspect(this.idx,!1,2)+" }"},s.inspect.custom&&(a.prototype[s.inspect.custom]=a.prototype.inspect),a.prototype.findCookie=function(e,t,n,r){return this.idx[e]&&this.idx[e][t]?r(null,this.idx[e][t][n]||null):r(null,void 0)},a.prototype.findCookies=function(e,t,n){var r=[],s;if(!e)return n(null,[]);s=t?function e(n){Object.keys(n).forEach(function(e){if(o(t,e)){var i=n[e];for(var s in i)r.push(i[s])}})}:function e(t){for(var n in t){var i=t[n];for(var o in i)r.push(i[o])}};var a=i(e)||[e],l=this.idx;a.forEach(function(e){var t=l[e];t&&s(t)}),n(null,r)},a.prototype.putCookie=function(e,t){this.idx[e.domain]||(this.idx[e.domain]={}),this.idx[e.domain][e.path]||(this.idx[e.domain][e.path]={}),this.idx[e.domain][e.path][e.key]=e,t(null)},a.prototype.updateCookie=function(e,t,n){this.putCookie(t,n)},a.prototype.removeCookie=function(e,t,n,r){this.idx[e]&&this.idx[e][t]&&this.idx[e][t][n]&&delete this.idx[e][t][n],r(null)},a.prototype.removeCookies=function(e,t,n){return this.idx[e]&&(t?delete this.idx[e][t]:delete this.idx[e]),n(null)},a.prototype.getAllCookies=function(e){var t=[],n=this.idx,r=Object.keys(n);r.forEach(function(e){var r=Object.keys(n[e]);r.forEach(function(r){var i=Object.keys(n[e][r]);i.forEach(function(i){null!==i&&t.push(n[e][r][i])})})}),t.sort(function(e,t){return(e.creationIndex||0)-(t.creationIndex||0)}),e(null,t)}},function(e){e.exports={author:{name:"Jeremy Stashewsky",email:"jstash@gmail.com",website:"https://github.com/stash"},contributors:[{name:"Alexander Savin",website:"https://github.com/apsavin"},{name:"Ian Livingstone",website:"https://github.com/ianlivingstone"},{name:"Ivan Nikulin",website:"https://github.com/inikulin"},{name:"Lalit Kapoor",website:"https://github.com/lalitkapoor"},{name:"Sam Thompson",website:"https://github.com/sambthompson"},{name:"Sebastian Mayr",website:"https://github.com/Sebmaster"}],license:"BSD-3-Clause",name:"tough-cookie",description:"RFC6265 Cookies and Cookie Jar for node.js",keywords:["HTTP","cookie","cookies","set-cookie","cookiejar","jar","RFC6265","RFC2965"],version:"2.4.3",homepage:"https://github.com/salesforce/tough-cookie",repository:{type:"git",url:"git://github.com/salesforce/tough-cookie.git"},bugs:{url:"https://github.com/salesforce/tough-cookie/issues"},main:"./lib/cookie",files:["lib"],scripts:{test:"vows test/*_test.js",cover:"nyc --reporter=lcov --reporter=html vows test/*_test.js"},engines:{node:">=0.8"},devDependencies:{async:"^1.4.2",nyc:"^11.6.0","string.prototype.repeat":"^0.2.0",vows:"^0.8.1"},dependencies:{psl:"^1.1.24",punycode:"^1.4.1"}}},function(e,t,n){"use strict";(function(t){var r=n(131),i=n(169),o=n(32),s=n(14),a=n(62),l=n(1637),u=n(1647),c=n(1648),h=n(1650),f=n(1667),p=n(320),d=n(1670),m=n(1671),g=n(312),y=n(620),v=n(503).strict,b=n(313),_=n(606),w=n(1672),k=n(1673).Querystring,E=n(1676).Har,S=n(1732).Auth,x=n(1733).OAuth,C=n(1735),A=n(1736).Multipart,T=n(1739).Redirect,I=n(1740).Tunnel,j=n(1742),R=n(5).Buffer,B=b.safeStringify,O=b.isReadStream,P=b.toBase64,N=b.defer,D=b.copy,M=b.version,F=_.jar(),L={};function U(e,t){var n={};for(var r in t){var i=-1===e.indexOf(r);i&&(n[r]=t[r])}return n}function q(e,t){var n={};for(var r in t){var i=!(-1===e.indexOf(r)),o="function"==typeof t[r];i&&o||(n[r]=t[r])}return n}function z(){var e=this;return{uri:this.uri,method:this.method,headers:this.headers}}function K(){var e=this;return{statusCode:this.statusCode,body:this.body,headers:this.headers,request:z.call(this.request)}}function H(e){var t=this;e.har&&(this._har=new E(this),e=this._har.options(e)),a.Stream.call(this);var n=Object.keys(H.prototype),r=U(n,e);g(this,r),e=q(n,e),this.readable=!0,this.writable=!0,e.method&&(this.explicitMethod=!0),this._qs=new k(this),this._auth=new S(this),this._oauth=new x(this),this._multipart=new A(this),this._redirect=new T(this),this._tunnel=new I(this),this.init(e)}function V(){H.debug&&console.error("REQUEST %s",s.format.apply(s,arguments))}s.inherits(H,a.Stream),H.debug=t.env.NODE_DEBUG&&/\brequest\b/.test(t.env.NODE_DEBUG),H.prototype.debug=V,H.prototype.init=function(e){var t=this;for(var n in e||(e={}),t.headers=t.headers?D(t.headers):{},t.headers)void 0===t.headers[n]&&delete t.headers[n];if(p.httpify(t,t.headers),t.method||(t.method=e.method||"GET"),t.localAddress||(t.localAddress=e.localAddress),t._qs.init(e),V(e),t.pool||!1===t.pool||(t.pool=L),t.dests=t.dests||[],t.__isRequestRequest=!0,!t._callback&&t.callback&&(t._callback=t.callback,t.callback=function(){t._callbackCalled||(t._callbackCalled=!0,t._callback.apply(t,arguments))},t.on("error",t.callback.bind()),t.on("complete",t.callback.bind(t,null))),!t.uri&&t.url&&(t.uri=t.url,delete t.url),t.baseUrl){if("string"!=typeof t.baseUrl)return t.emit("error",new Error("options.baseUrl must be a string"));if("string"!=typeof t.uri)return t.emit("error",new Error("options.uri must be a string when using options.baseUrl"));if(0===t.uri.indexOf("//")||-1!==t.uri.indexOf("://"))return t.emit("error",new Error("options.uri must be a path when using options.baseUrl"));var s=t.baseUrl.lastIndexOf("/")===t.baseUrl.length-1,a=0===t.uri.indexOf("/");s&&a?t.uri=t.baseUrl+t.uri.slice(1):s||a?t.uri=t.baseUrl+t.uri:""===t.uri?t.uri=t.baseUrl:t.uri=t.baseUrl+"/"+t.uri,delete t.baseUrl}if(!t.uri)return t.emit("error",new Error("options.uri is a required argument"));if("string"==typeof t.uri&&(t.uri=o.parse(t.uri)),t.uri.href||(t.uri.href=o.format(t.uri)),"unix:"===t.uri.protocol)return t.emit("error",new Error("`unix://` URL scheme is no longer supported. Please use the format `http://unix:SOCKET:PATH`"));if("unix"===t.uri.host&&t.enableUnixSocket(),!1===t.strictSSL&&(t.rejectUnauthorized=!1),t.uri.pathname||(t.uri.pathname="/"),!(t.uri.host||t.uri.hostname&&t.uri.port||t.uri.isUnix)){var l=o.format(t.uri),u='Invalid URI "'+l+'"';return 0===Object.keys(e).length&&(u+=". This can be caused by a crappy redirection."),t.abort(),t.emit("error",new Error(u))}if(t.hasOwnProperty("proxy")||(t.proxy=w(t.uri)),t.tunnel=t._tunnel.isEnabled(),t.proxy&&t._tunnel.setup(e),t._redirect.onRequest(e),t.setHost=!1,!t.hasHeader("host")){var c=t.originalHostHeaderName||"host";t.setHeader(c,t.uri.host),t.uri.port&&("80"===t.uri.port&&"http:"===t.uri.protocol||"443"===t.uri.port&&"https:"===t.uri.protocol)&&t.setHeader(c,t.uri.hostname),t.setHost=!0}if(t.jar(t._jar||e.jar),t.uri.port||("http:"===t.uri.protocol?t.uri.port=80:"https:"===t.uri.protocol&&(t.uri.port=443)),t.proxy&&!t.tunnel?(t.port=t.proxy.port,t.host=t.proxy.hostname):(t.port=t.uri.port,t.host=t.uri.hostname),e.form&&t.form(e.form),e.formData){var h=e.formData,m=t.form(),g=function(e,t){t&&t.hasOwnProperty("value")&&t.hasOwnProperty("options")?m.append(e,t.value,t.options):m.append(e,t)};for(var b in h)if(h.hasOwnProperty(b)){var _=h[b];if(_ instanceof Array)for(var k=0;k<_.length;k++)g(b,_[k]);else g(b,_)}}if(e.qs&&t.qs(e.qs),t.uri.path?t.path=t.uri.path:t.path=t.uri.pathname+(t.uri.search||""),0===t.path.length&&(t.path="/"),e.aws&&t.aws(e.aws),e.hawk&&t.hawk(e.hawk),e.httpSignature&&t.httpSignature(e.httpSignature),e.auth&&(Object.prototype.hasOwnProperty.call(e.auth,"username")&&(e.auth.user=e.auth.username),Object.prototype.hasOwnProperty.call(e.auth,"password")&&(e.auth.pass=e.auth.password),t.auth(e.auth.user,e.auth.pass,e.auth.sendImmediately,e.auth.bearer)),t.gzip&&!t.hasHeader("accept-encoding")&&t.setHeader("accept-encoding","gzip, deflate"),t.uri.auth&&!t.hasHeader("authorization")){var E=t.uri.auth.split(":").map(function(e){return t._qs.unescape(e)});t.auth(E[0],E.slice(1).join(":"),!0)}if(!t.tunnel&&t.proxy&&t.proxy.auth&&!t.hasHeader("proxy-authorization")){var S=t.proxy.auth.split(":").map(function(e){return t._qs.unescape(e)}),x="Basic "+P(S.join(":"));t.setHeader("proxy-authorization",x)}function C(){var e;(v(t.body)&&(t.body=R.from(t.body)),t.hasHeader("content-length"))||(e="string"==typeof t.body?R.byteLength(t.body):Array.isArray(t.body)?t.body.reduce(function(e,t){return e+t.length},0):t.body.length,e?t.setHeader("content-length",e):t.emit("error",new Error("Argument error, options.body.")))}t.proxy&&!t.tunnel&&(t.path=t.uri.protocol+"//"+t.uri.host+t.path),e.json&&t.json(e.json),e.multipart&&t.multipart(e.multipart),e.time&&(t.timing=!0,t.elapsedTime=t.elapsedTime||0),t.body&&!y(t.body)&&C(),e.oauth?t.oauth(e.oauth):t._oauth.params&&t.hasHeader("authorization")&&t.oauth(t._oauth.params);var A=t.proxy&&!t.tunnel?t.proxy.protocol:t.uri.protocol,T={"http:":r,"https:":i},I=t.httpModules||{};if(t.httpModule=I[A]||T[A],!t.httpModule)return t.emit("error",new Error("Invalid protocol: "+A));if(e.ca&&(t.ca=e.ca),!t.agent)if(e.agentOptions&&(t.agentOptions=e.agentOptions),e.agentClass)t.agentClass=e.agentClass;else if(e.forever){var j=M();0===j.major&&j.minor<=10?t.agentClass="http:"===A?d:d.SSL:(t.agentClass=t.httpModule.Agent,t.agentOptions=t.agentOptions||{},t.agentOptions.keepAlive=!0)}else t.agentClass=t.httpModule.Agent;!1===t.pool?t.agent=!1:t.agent=t.agent||t.getNewAgent(),t.on("pipe",function(e){if(t.ntick&&t._started&&t.emit("error",new Error("You cannot pipe to this stream after the outbound request has started.")),t.src=e,O(e))t.hasHeader("content-type")||t.setHeader("content-type",f.lookup(e.path));else{if(e.headers)for(var n in e.headers)t.hasHeader(n)||t.setHeader(n,e.headers[n]);t._json&&!t.hasHeader("content-type")&&t.setHeader("content-type","application/json"),e.method&&!t.explicitMethod&&(t.method=e.method)}}),N(function(){if(!t._aborted){var e=function(){if(t._form&&(t._auth.hasAuth?t._auth.hasAuth&&t._auth.sentAuth&&t._form.pipe(t):t._form.pipe(t)),t._multipart&&t._multipart.chunked&&t._multipart.body.pipe(t),t.body)y(t.body)?t.body.pipe(t):(C(),Array.isArray(t.body)?t.body.forEach(function(e){t.write(e)}):t.write(t.body),t.end());else if(t.requestBodyStream)console.warn("options.requestBodyStream is deprecated, please pass the request object to stream.pipe."),t.requestBodyStream.pipe(t);else if(!t.src){if(t._auth.hasAuth&&!t._auth.sentAuth)return void t.end();"GET"!==t.method&&void 0!==t.method&&t.setHeader("content-length",0),t.end()}};t._form&&!t.hasHeader("content-length")?(t.setHeader(t._form.getHeaders(),!0),t._form.getLength(function(n,r){n||isNaN(r)||t.setHeader("content-length",r),e()})):e(),t.ntick=!0}})},H.prototype.getNewAgent=function(){var e=this,t=this.agentClass,n={};if(this.agentOptions)for(var r in this.agentOptions)n[r]=this.agentOptions[r];this.ca&&(n.ca=this.ca),this.ciphers&&(n.ciphers=this.ciphers),this.secureProtocol&&(n.secureProtocol=this.secureProtocol),this.secureOptions&&(n.secureOptions=this.secureOptions),void 0!==this.rejectUnauthorized&&(n.rejectUnauthorized=this.rejectUnauthorized),this.cert&&this.key&&(n.key=this.key,n.cert=this.cert),this.pfx&&(n.pfx=this.pfx),this.passphrase&&(n.passphrase=this.passphrase);var i="";t!==this.httpModule.Agent&&(i+=t.name);var s=this.proxy;"string"==typeof s&&(s=o.parse(s));var a=s&&"https:"===s.protocol||"https:"===this.uri.protocol;return a&&(n.ca&&(i&&(i+=":"),i+=n.ca),void 0!==n.rejectUnauthorized&&(i&&(i+=":"),i+=n.rejectUnauthorized),n.cert&&(i&&(i+=":"),i+=n.cert.toString("ascii")+n.key.toString("ascii")),n.pfx&&(i&&(i+=":"),i+=n.pfx.toString("ascii")),n.ciphers&&(i&&(i+=":"),i+=n.ciphers),n.secureProtocol&&(i&&(i+=":"),i+=n.secureProtocol),n.secureOptions&&(i&&(i+=":"),i+=n.secureOptions)),this.pool===L&&!i&&0===Object.keys(n).length&&this.httpModule.globalAgent?this.httpModule.globalAgent:(i=this.uri.protocol+i,this.pool[i]||(this.pool[i]=new t(n),this.pool.maxSockets&&(this.pool[i].maxSockets=this.pool.maxSockets)),this.pool[i])},H.prototype.start=function(){var e=this;if(e.timing)var t=(new Date).getTime(),n=j();if(!e._aborted){e._started=!0,e.method=e.method||"GET",e.href=e.uri.href,e.src&&e.src.stat&&e.src.stat.size&&!e.hasHeader("content-length")&&e.setHeader("content-length",e.src.stat.size),e._aws&&e.aws(e._aws,!0);var r=D(e),i;delete r.auth,V("make request",e.uri.href),delete r.timeout;try{e.req=e.httpModule.request(r)}catch(t){return void e.emit("error",t)}e.timing&&(e.startTime=t,e.startTimeNow=n,e.timings={}),e.timeout&&!e.timeoutTimer&&(e.timeout<0?i=0:"number"==typeof e.timeout&&isFinite(e.timeout)&&(i=e.timeout)),e.req.on("response",e.onRequestResponse.bind(e)),e.req.on("error",e.onRequestError.bind(e)),e.req.on("drain",function(){e.emit("drain")}),e.req.on("socket",function(t){var n=t._connecting||t.connecting;if(e.timing&&(e.timings.socket=j()-e.startTimeNow,n)){var r=function(){e.timings.lookup=j()-e.startTimeNow},o=function(){e.timings.connect=j()-e.startTimeNow};t.once("lookup",r),t.once("connect",o),e.req.once("error",function(){t.removeListener("lookup",r),t.removeListener("connect",o)})}var s=function(){e.req.setTimeout(i,function(){if(e.req){e.abort();var t=new Error("ESOCKETTIMEDOUT");t.code="ESOCKETTIMEDOUT",t.connect=!1,e.emit("error",t)}})};if(void 0!==i)if(n){var a=function(){t.removeListener("connect",a),clearTimeout(e.timeoutTimer),e.timeoutTimer=null,s()};t.on("connect",a),e.req.on("error",function(e){t.removeListener("connect",a)}),e.timeoutTimer=setTimeout(function(){t.removeListener("connect",a),e.abort();var n=new Error("ETIMEDOUT");n.code="ETIMEDOUT",n.connect=!0,e.emit("error",n)},i)}else s();e.emit("socket",t)}),e.emit("request",e.req)}},H.prototype.onRequestError=function(e){var t=this;if(!this._aborted){if(this.req&&this.req._reusedSocket&&"ECONNRESET"===e.code&&this.agent.addRequestNoreuse)return this.agent={addRequest:this.agent.addRequestNoreuse.bind(this.agent)},this.start(),void this.req.end();this.timeout&&this.timeoutTimer&&(clearTimeout(this.timeoutTimer),this.timeoutTimer=null),this.emit("error",e)}},H.prototype.onRequestResponse=function(e){var t=this;if(t.timing&&(t.timings.response=j()-t.startTimeNow),V("onRequestResponse",t.uri.href,e.statusCode,e.headers),e.on("end",function(){t.timing&&(t.timings.end=j()-t.startTimeNow,e.timingStart=t.startTime,t.timings.socket||(t.timings.socket=0),t.timings.lookup||(t.timings.lookup=t.timings.socket),t.timings.connect||(t.timings.connect=t.timings.lookup),t.timings.response||(t.timings.response=t.timings.connect),V("elapsed time",t.timings.end),t.elapsedTime+=Math.round(t.timings.end),e.elapsedTime=t.elapsedTime,e.timings=t.timings,e.timingPhases={wait:t.timings.socket,dns:t.timings.lookup-t.timings.socket,tcp:t.timings.connect-t.timings.lookup,firstByte:t.timings.response-t.timings.connect,download:t.timings.end-t.timings.response,total:t.timings.end}),V("response end",t.uri.href,e.statusCode,e.headers)}),t._aborted)return V("aborted",t.uri.href),void e.resume();if(t.response=e,e.request=t,e.toJSON=K,t.httpModule!==i||!t.strictSSL||e.hasOwnProperty("socket")&&e.socket.authorized){t.originalHost=t.getHeader("host"),t.originalHostHeaderName||(t.originalHostHeaderName=t.hasHeader("host")),t.setHost&&t.removeHeader("host"),t.timeout&&t.timeoutTimer&&(clearTimeout(t.timeoutTimer),t.timeoutTimer=null);var n=t._jar&&t._jar.setCookie?t._jar:F,r=function(e){try{n.setCookie(e,t.uri.href,{ignoreError:!0})}catch(e){t.emit("error",e)}};if(e.caseless=p(e.headers),e.caseless.has("set-cookie")&&!t._disableCookies){var o=e.caseless.has("set-cookie");Array.isArray(e.headers[o])?e.headers[o].forEach(r):r(e.headers[o])}if(!t._redirect.onResponse(e)){e.on("close",function(){t._ended||t.response.emit("end")}),e.once("end",function(){t._ended=!0});var s=function(e){return"HEAD"===t.method||e>=100&&e<200||204===e||304===e},a;if(t.gzip&&!s(e.statusCode)){var u=e.headers["content-encoding"]||"identity";u=u.trim().toLowerCase();var c={flush:l.Z_SYNC_FLUSH,finishFlush:l.Z_SYNC_FLUSH};"gzip"===u?(a=l.createGunzip(c),e.pipe(a)):"deflate"===u?(a=l.createInflate(c),e.pipe(a)):("identity"!==u&&V("ignoring unrecognized Content-Encoding "+u),a=e)}else a=e;t.encoding&&(0!==t.dests.length?console.error("Ignoring encoding parameter as this stream is being piped to another stream which makes the encoding option invalid."):a.setEncoding(t.encoding)),t._paused&&a.pause(),t.responseContent=a,t.emit("response",e),t.dests.forEach(function(e){t.pipeDest(e)}),a.on("data",function(n){t.timing&&!t.responseStarted&&(t.responseStartTime=(new Date).getTime(),e.responseStartTime=t.responseStartTime),t._destdata=!0,t.emit("data",n)}),a.once("end",function(e){t.emit("end",e)}),a.on("error",function(e){t.emit("error",e)}),a.on("close",function(){t.emit("close")}),t.callback?t.readResponseBody(e):t.on("end",function(){t._aborted?V("aborted",t.uri.href):t.emit("complete",e)}),V("finish init function",t.uri.href)}}else{V("strict ssl error",t.uri.href);var h=e.hasOwnProperty("socket")?e.socket.authorizationError:t.uri.href+" does not support SSL";t.emit("error",new Error("SSL Error: "+h))}},H.prototype.readResponseBody=function(e){var t=this;V("reading response's body");var n=[],r=0,i=[];t.on("data",function(e){R.isBuffer(e)?e.length&&(r+=e.length,n.push(e)):i.push(e)}),t.on("end",function(){if(V("end event",t.uri.href),t._aborted)return V("aborted",t.uri.href),n=[],void(r=0);if(r?(V("has body",t.uri.href,r),e.body=R.concat(n,r),null!==t.encoding&&(e.body=e.body.toString(t.encoding)),n=[],r=0):i.length&&("utf8"===t.encoding&&i[0].length>0&&"\ufeff"===i[0][0]&&(i[0]=i[0].substring(1)),e.body=i.join("")),t._json)try{e.body=JSON.parse(e.body,t._jsonReviver)}catch(e){V("invalid JSON received",t.uri.href)}V("emitting complete",t.uri.href),void 0!==e.body||t._json||(e.body=null===t.encoding?R.alloc(0):""),t.emit("complete",e,e.body)})},H.prototype.abort=function(){var e=this;this._aborted=!0,this.req?this.req.abort():this.response&&this.response.destroy(),this.emit("abort")},H.prototype.pipeDest=function(e){var t=this,n=this.response;if(e.headers&&!e.headersSent){if(n.caseless.has("content-type")){var r=n.caseless.has("content-type");e.setHeader?e.setHeader(r,n.headers[r]):e.headers[r]=n.headers[r]}if(n.caseless.has("content-length")){var i=n.caseless.has("content-length");e.setHeader?e.setHeader(i,n.headers[i]):e.headers[i]=n.headers[i]}}if(e.setHeader&&!e.headersSent){for(var o in n.headers)this.gzip&&"content-encoding"===o||e.setHeader(o,n.headers[o]);e.statusCode=n.statusCode}this.pipefilter&&this.pipefilter(n,e)},H.prototype.qs=function(e,t){var n=this,r;for(var i in r=!t&&this.uri.query?this._qs.parse(this.uri.query):{},e)r[i]=e[i];var s=this._qs.stringify(r);return""===s?this:(this.uri=o.parse(this.uri.href.split("?")[0]+"?"+s),this.url=this.uri,this.path=this.uri.path,"unix"===this.uri.host&&this.enableUnixSocket(),this)},H.prototype.form=function(e){var t=this;return e?(/^application\/x-www-form-urlencoded\b/.test(t.getHeader("content-type"))||t.setHeader("content-type","application/x-www-form-urlencoded"),t.body="string"==typeof e?t._qs.rfc3986(e.toString("utf8")):t._qs.stringify(e).toString("utf8"),t):(t._form=new m,t._form.on("error",function(e){e.message="form-data: "+e.message,t.emit("error",e),t.abort()}),t._form)},H.prototype.multipart=function(e){var t=this;return this._multipart.onRequest(e),this._multipart.chunked||(this.body=this._multipart.body),this},H.prototype.json=function(e){var t=this;return this.hasHeader("accept")||this.setHeader("accept","application/json"),"function"==typeof this.jsonReplacer&&(this._jsonReplacer=this.jsonReplacer),this._json=!0,"boolean"==typeof e?void 0!==this.body&&(/^application\/x-www-form-urlencoded\b/.test(this.getHeader("content-type"))?this.body=this._qs.rfc3986(this.body):this.body=B(this.body,this._jsonReplacer),this.hasHeader("content-type")||this.setHeader("content-type","application/json")):(this.body=B(e,this._jsonReplacer),this.hasHeader("content-type")||this.setHeader("content-type","application/json")),"function"==typeof this.jsonReviver&&(this._jsonReviver=this.jsonReviver),this},H.prototype.getHeader=function(e,t){var n=this,r,i,o;return t||(t=this.headers),Object.keys(t).forEach(function(n){n.length===e.length&&(i=new RegExp(e,"i"),o=n.match(i),o&&(r=t[n]))}),r},H.prototype.enableUnixSocket=function(){var e=this.uri.path.split(":"),t=e[0],n=e[1];this.socketPath=t,this.uri.pathname=n,this.uri.path=n,this.uri.host=t,this.uri.hostname=t,this.uri.isUnix=!0},H.prototype.auth=function(e,t,n,r){var i=this;return this._auth.onRequest(e,t,n,r),this},H.prototype.aws=function(e,t){var n=this;if(!t)return this._aws=e,this;if(4===e.sign_version||"4"===e.sign_version){var r={host:this.uri.host,path:this.uri.path,method:this.method,headers:this.headers,body:this.body};e.service&&(r.service=e.service);var i=c.sign(r,{accessKeyId:e.key,secretAccessKey:e.secret,sessionToken:e.session});this.setHeader("authorization",i.headers.Authorization),this.setHeader("x-amz-date",i.headers["X-Amz-Date"]),i.headers["X-Amz-Security-Token"]&&this.setHeader("x-amz-security-token",i.headers["X-Amz-Security-Token"])}else{var o=new Date;this.setHeader("date",o.toUTCString());var s={key:e.key,secret:e.secret,verb:this.method.toUpperCase(),date:o,contentType:this.getHeader("content-type")||"",md5:this.getHeader("content-md5")||"",amazonHeaders:u.canonicalizeHeaders(this.headers)},a=this.uri.path;e.bucket&&a?s.resource="/"+e.bucket+a:e.bucket&&!a?s.resource="/"+e.bucket:!e.bucket&&a?s.resource=a:e.bucket||a||(s.resource="/"),s.resource=u.canonicalizeResource(s.resource),this.setHeader("authorization",u.authorization(s))}return this},H.prototype.httpSignature=function(e){var t=this;return h.signRequest({getHeader:function(e){return t.getHeader(e,t.headers)},setHeader:function(e,n){t.setHeader(e,n)},method:t.method,path:t.path},e),V("httpSignature authorization",t.getHeader("authorization")),t},H.prototype.hawk=function(e){var t=this;this.setHeader("Authorization",C.header(this.uri,this.method,e))},H.prototype.oauth=function(e){var t=this;return this._oauth.onRequest(e),this},H.prototype.jar=function(e){var t=this,n;if(0===this._redirect.redirectsFollowed&&(this.originalCookieHeader=this.getHeader("cookie")),e){var r=e&&e.getCookieString?e:F,i=this.uri.href;r&&(n=r.getCookieString(i))}else n=!1,this._disableCookies=!0;return n&&n.length&&(this.originalCookieHeader?this.setHeader("cookie",this.originalCookieHeader+"; "+n):this.setHeader("cookie",n)),this._jar=e,this},H.prototype.pipe=function(e,t){var n=this;if(!this.response)return this.dests.push(e),a.Stream.prototype.pipe.call(this,e,t),e;if(this._destdata)this.emit("error",new Error("You cannot pipe after data has been emitted from the response."));else{if(!this._ended)return a.Stream.prototype.pipe.call(this,e,t),this.pipeDest(e),e;this.emit("error",new Error("You cannot pipe after the response has been ended."))}},H.prototype.write=function(){var e=this;if(!this._aborted)return this._started||this.start(),this.req?this.req.write.apply(this.req,arguments):void 0},H.prototype.end=function(e){var t=this;this._aborted||(e&&this.write(e),this._started||this.start(),this.req&&this.req.end())},H.prototype.pause=function(){var e=this;this.responseContent?this.responseContent.pause.apply(this.responseContent,arguments):this._paused=!0},H.prototype.resume=function(){var e=this;this.responseContent?this.responseContent.resume.apply(this.responseContent,arguments):this._paused=!1},H.prototype.destroy=function(){var e=this;this._ended?this.response&&this.response.destroy():this.end()},H.defaultProxyHeaderWhiteList=I.defaultProxyHeaderWhiteList.slice(),H.defaultProxyHeaderExclusiveList=I.defaultProxyHeaderExclusiveList.slice(),H.prototype.toJSON=z,e.exports=H}).call(this,n(3))},function(e,t,n){"use strict";(function(e){var r=n(0).Buffer,i=n(62).Transform,o=n(1638),s=n(14),a=n(24).ok,l=n(0).kMaxLength,u="Cannot create final Buffer. It would be larger than 0x"+l.toString(16)+" bytes";o.Z_MIN_WINDOWBITS=8,o.Z_MAX_WINDOWBITS=15,o.Z_DEFAULT_WINDOWBITS=15,o.Z_MIN_CHUNK=64,o.Z_MAX_CHUNK=1/0,o.Z_DEFAULT_CHUNK=16384,o.Z_MIN_MEMLEVEL=1,o.Z_MAX_MEMLEVEL=9,o.Z_DEFAULT_MEMLEVEL=8,o.Z_MIN_LEVEL=-1,o.Z_MAX_LEVEL=9,o.Z_DEFAULT_LEVEL=o.Z_DEFAULT_COMPRESSION;for(var c=Object.keys(o),h=0;h<c.length;h++){var f=c[h];f.match(/^Z/)&&Object.defineProperty(t,f,{enumerable:!0,value:o[f],writable:!1})}for(var p={Z_OK:o.Z_OK,Z_STREAM_END:o.Z_STREAM_END,Z_NEED_DICT:o.Z_NEED_DICT,Z_ERRNO:o.Z_ERRNO,Z_STREAM_ERROR:o.Z_STREAM_ERROR,Z_DATA_ERROR:o.Z_DATA_ERROR,Z_MEM_ERROR:o.Z_MEM_ERROR,Z_BUF_ERROR:o.Z_BUF_ERROR,Z_VERSION_ERROR:o.Z_VERSION_ERROR},d=Object.keys(p),m=0;m<d.length;m++){var g=d[m];p[p[g]]=g}function y(e,t,n){var i=[],o=0;function s(){for(var t;null!==(t=e.read());)i.push(t),o+=t.length;e.once("readable",s)}function a(t){e.removeListener("end",c),e.removeListener("readable",s),n(t)}function c(){var t,s=null;o>=l?s=new RangeError(u):t=r.concat(i,o),i=[],e.close(),n(s,t)}e.on("error",a),e.on("end",c),e.end(t),s()}function v(e,t){if("string"==typeof t&&(t=r.from(t)),!r.isBuffer(t))throw new TypeError("Not a string or buffer");var n=e._finishFlushFlag;return e._processChunk(t,n)}function b(e){if(!(this instanceof b))return new b(e);A.call(this,e,o.DEFLATE)}function _(e){if(!(this instanceof _))return new _(e);A.call(this,e,o.INFLATE)}function w(e){if(!(this instanceof w))return new w(e);A.call(this,e,o.GZIP)}function k(e){if(!(this instanceof k))return new k(e);A.call(this,e,o.GUNZIP)}function E(e){if(!(this instanceof E))return new E(e);A.call(this,e,o.DEFLATERAW)}function S(e){if(!(this instanceof S))return new S(e);A.call(this,e,o.INFLATERAW)}function x(e){if(!(this instanceof x))return new x(e);A.call(this,e,o.UNZIP)}function C(e){return e===o.Z_NO_FLUSH||e===o.Z_PARTIAL_FLUSH||e===o.Z_SYNC_FLUSH||e===o.Z_FULL_FLUSH||e===o.Z_FINISH||e===o.Z_BLOCK}function A(e,n){var s=this;if(this._opts=e=e||{},this._chunkSize=e.chunkSize||t.Z_DEFAULT_CHUNK,i.call(this,e),e.flush&&!C(e.flush))throw new Error("Invalid flush flag: "+e.flush);if(e.finishFlush&&!C(e.finishFlush))throw new Error("Invalid flush flag: "+e.finishFlush);if(this._flushFlag=e.flush||o.Z_NO_FLUSH,this._finishFlushFlag=void 0!==e.finishFlush?e.finishFlush:o.Z_FINISH,e.chunkSize&&(e.chunkSize<t.Z_MIN_CHUNK||e.chunkSize>t.Z_MAX_CHUNK))throw new Error("Invalid chunk size: "+e.chunkSize);if(e.windowBits&&(e.windowBits<t.Z_MIN_WINDOWBITS||e.windowBits>t.Z_MAX_WINDOWBITS))throw new Error("Invalid windowBits: "+e.windowBits);if(e.level&&(e.level<t.Z_MIN_LEVEL||e.level>t.Z_MAX_LEVEL))throw new Error("Invalid compression level: "+e.level);if(e.memLevel&&(e.memLevel<t.Z_MIN_MEMLEVEL||e.memLevel>t.Z_MAX_MEMLEVEL))throw new Error("Invalid memLevel: "+e.memLevel);if(e.strategy&&e.strategy!=t.Z_FILTERED&&e.strategy!=t.Z_HUFFMAN_ONLY&&e.strategy!=t.Z_RLE&&e.strategy!=t.Z_FIXED&&e.strategy!=t.Z_DEFAULT_STRATEGY)throw new Error("Invalid strategy: "+e.strategy);if(e.dictionary&&!r.isBuffer(e.dictionary))throw new Error("Invalid dictionary: it should be a Buffer instance");this._handle=new o.Zlib(n);var a=this;this._hadError=!1,this._handle.onerror=function(e,n){T(a),a._hadError=!0;var r=new Error(e);r.errno=n,r.code=t.codes[n],a.emit("error",r)};var l=t.Z_DEFAULT_COMPRESSION;"number"==typeof e.level&&(l=e.level);var u=t.Z_DEFAULT_STRATEGY;"number"==typeof e.strategy&&(u=e.strategy),this._handle.init(e.windowBits||t.Z_DEFAULT_WINDOWBITS,l,e.memLevel||t.Z_DEFAULT_MEMLEVEL,u,e.dictionary),this._buffer=r.allocUnsafe(this._chunkSize),this._offset=0,this._level=l,this._strategy=u,this.once("end",this.close),Object.defineProperty(this,"_closed",{get:function(){return!s._handle},configurable:!0,enumerable:!0})}function T(t,n){n&&e.nextTick(n),t._handle&&(t._handle.close(),t._handle=null)}function I(e){e.emit("close")}Object.defineProperty(t,"codes",{enumerable:!0,value:Object.freeze(p),writable:!1}),t.Deflate=b,t.Inflate=_,t.Gzip=w,t.Gunzip=k,t.DeflateRaw=E,t.InflateRaw=S,t.Unzip=x,t.createDeflate=function(e){return new b(e)},t.createInflate=function(e){return new _(e)},t.createDeflateRaw=function(e){return new E(e)},t.createInflateRaw=function(e){return new S(e)},t.createGzip=function(e){return new w(e)},t.createGunzip=function(e){return new k(e)},t.createUnzip=function(e){return new x(e)},t.deflate=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new b(t),e,n)},t.deflateSync=function(e,t){return v(new b(t),e)},t.gzip=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new w(t),e,n)},t.gzipSync=function(e,t){return v(new w(t),e)},t.deflateRaw=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new E(t),e,n)},t.deflateRawSync=function(e,t){return v(new E(t),e)},t.unzip=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new x(t),e,n)},t.unzipSync=function(e,t){return v(new x(t),e)},t.inflate=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new _(t),e,n)},t.inflateSync=function(e,t){return v(new _(t),e)},t.gunzip=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new k(t),e,n)},t.gunzipSync=function(e,t){return v(new k(t),e)},t.inflateRaw=function(e,t,n){return"function"==typeof t&&(n=t,t={}),y(new S(t),e,n)},t.inflateRawSync=function(e,t){return v(new S(t),e)},s.inherits(A,i),A.prototype.params=function(n,r,i){if(n<t.Z_MIN_LEVEL||n>t.Z_MAX_LEVEL)throw new RangeError("Invalid compression level: "+n);if(r!=t.Z_FILTERED&&r!=t.Z_HUFFMAN_ONLY&&r!=t.Z_RLE&&r!=t.Z_FIXED&&r!=t.Z_DEFAULT_STRATEGY)throw new TypeError("Invalid strategy: "+r);if(this._level!==n||this._strategy!==r){var s=this;this.flush(o.Z_SYNC_FLUSH,function(){a(s._handle,"zlib binding closed"),s._handle.params(n,r),s._hadError||(s._level=n,s._strategy=r,i&&i())})}else e.nextTick(i)},A.prototype.reset=function(){return a(this._handle,"zlib binding closed"),this._handle.reset()},A.prototype._flush=function(e){this._transform(r.alloc(0),"",e)},A.prototype.flush=function(t,n){var i=this,s=this._writableState;("function"==typeof t||void 0===t&&!n)&&(n=t,t=o.Z_FULL_FLUSH),s.ended?n&&e.nextTick(n):s.ending?n&&this.once("end",n):s.needDrain?n&&this.once("drain",function(){return i.flush(t,n)}):(this._flushFlag=t,this.write(r.alloc(0),"",n))},A.prototype.close=function(t){T(this,t),e.nextTick(I,this)},A.prototype._transform=function(e,t,n){var i,s=this._writableState,a=s.ending||s.ended,l=a&&(!e||s.length===e.length);return null===e||r.isBuffer(e)?this._handle?(l?i=this._finishFlushFlag:(i=this._flushFlag,e.length>=s.length&&(this._flushFlag=this._opts.flush||o.Z_NO_FLUSH)),void this._processChunk(e,i,n)):n(new Error("zlib binding closed")):n(new Error("invalid input"))},A.prototype._processChunk=function(e,t,n){var i=e&&e.length,o=this._chunkSize-this._offset,s=0,c=this,h="function"==typeof n;if(!h){var f=[],p=0,d;this.on("error",function(e){d=e}),a(this._handle,"zlib binding closed");do{var m=this._handle.writeSync(t,e,s,i,this._buffer,this._offset,o)}while(!this._hadError&&v(m[0],m[1]));if(this._hadError)throw d;if(p>=l)throw T(this),new RangeError(u);var g=r.concat(f,p);return T(this),g}a(this._handle,"zlib binding closed");var y=this._handle.write(t,e,s,i,this._buffer,this._offset,o);function v(l,u){if(this&&(this.buffer=null,this.callback=null),!c._hadError){var d=o-u;if(a(d>=0,"have should not go down"),d>0){var m=c._buffer.slice(c._offset,c._offset+d);c._offset+=d,h?c.push(m):(f.push(m),p+=m.length)}if((0===u||c._offset>=c._chunkSize)&&(o=c._chunkSize,c._offset=0,c._buffer=r.allocUnsafe(c._chunkSize)),0===u){if(s+=i-l,i=l,!h)return!0;var g=c._handle.write(t,e,s,i,c._buffer,c._offset,c._chunkSize);return g.callback=v,void(g.buffer=e)}if(!h)return!1;n()}}y.buffer=e,y.callback=v},s.inherits(b,A),s.inherits(_,A),s.inherits(w,A),s.inherits(k,A),s.inherits(E,A),s.inherits(S,A),s.inherits(x,A)}).call(this,n(3))},function(e,t,n){"use strict";(function(e,r){var i=n(24),o=n(1639),s=n(1640),a=n(1643),l=n(1646);for(var u in l)t[u]=l[u];t.NONE=0,t.DEFLATE=1,t.INFLATE=2,t.GZIP=3,t.GUNZIP=4,t.DEFLATERAW=5,t.INFLATERAW=6,t.UNZIP=7;var c=31,h=139;function f(e){if("number"!=typeof e||e<t.DEFLATE||e>t.UNZIP)throw new TypeError("Bad argument");this.dictionary=null,this.err=0,this.flush=0,this.init_done=!1,this.level=0,this.memLevel=0,this.mode=e,this.strategy=0,this.windowBits=0,this.write_in_progress=!1,this.pending_close=!1,this.gzip_id_bytes_read=0}f.prototype.close=function(){this.write_in_progress?this.pending_close=!0:(this.pending_close=!1,i(this.init_done,"close before init"),i(this.mode<=t.UNZIP),this.mode===t.DEFLATE||this.mode===t.GZIP||this.mode===t.DEFLATERAW?s.deflateEnd(this.strm):this.mode!==t.INFLATE&&this.mode!==t.GUNZIP&&this.mode!==t.INFLATERAW&&this.mode!==t.UNZIP||a.inflateEnd(this.strm),this.mode=t.NONE,this.dictionary=null)},f.prototype.write=function(e,t,n,r,i,o,s){return this._write(!0,e,t,n,r,i,o,s)},f.prototype.writeSync=function(e,t,n,r,i,o,s){return this._write(!1,e,t,n,r,i,o,s)},f.prototype._write=function(n,o,s,a,l,u,c,h){if(i.equal(arguments.length,8),i(this.init_done,"write before init"),i(this.mode!==t.NONE,"already finalized"),i.equal(!1,this.write_in_progress,"write already in progress"),i.equal(!1,this.pending_close,"close is pending"),this.write_in_progress=!0,i.equal(!1,void 0===o,"must provide flush value"),this.write_in_progress=!0,o!==t.Z_NO_FLUSH&&o!==t.Z_PARTIAL_FLUSH&&o!==t.Z_SYNC_FLUSH&&o!==t.Z_FULL_FLUSH&&o!==t.Z_FINISH&&o!==t.Z_BLOCK)throw new Error("Invalid flush value");if(null==s&&(s=e.alloc(0),l=0,a=0),this.strm.avail_in=l,this.strm.input=s,this.strm.next_in=a,this.strm.avail_out=h,this.strm.output=u,this.strm.next_out=c,this.flush=o,!n)return this._process(),this._checkError()?this._afterSync():void 0;var f=this;return r.nextTick(function(){f._process(),f._after()}),this},f.prototype._afterSync=function(){var e=this.strm.avail_out,t=this.strm.avail_in;return this.write_in_progress=!1,[t,e]},f.prototype._process=function(){var e=null;switch(this.mode){case t.DEFLATE:case t.GZIP:case t.DEFLATERAW:this.err=s.deflate(this.strm,this.flush);break;case t.UNZIP:switch(this.strm.avail_in>0&&(e=this.strm.next_in),this.gzip_id_bytes_read){case 0:if(null===e)break;if(31!==this.strm.input[e]){this.mode=t.INFLATE;break}if(this.gzip_id_bytes_read=1,e++,1===this.strm.avail_in)break;case 1:if(null===e)break;139===this.strm.input[e]?(this.gzip_id_bytes_read=2,this.mode=t.GUNZIP):this.mode=t.INFLATE;break;default:throw new Error("invalid number of gzip magic number bytes read")}case t.INFLATE:case t.GUNZIP:case t.INFLATERAW:for(this.err=a.inflate(this.strm,this.flush),this.err===t.Z_NEED_DICT&&this.dictionary&&(this.err=a.inflateSetDictionary(this.strm,this.dictionary),this.err===t.Z_OK?this.err=a.inflate(this.strm,this.flush):this.err===t.Z_DATA_ERROR&&(this.err=t.Z_NEED_DICT));this.strm.avail_in>0&&this.mode===t.GUNZIP&&this.err===t.Z_STREAM_END&&0!==this.strm.next_in[0];)this.reset(),this.err=a.inflate(this.strm,this.flush);break;default:throw new Error("Unknown mode "+this.mode)}},f.prototype._checkError=function(){switch(this.err){case t.Z_OK:case t.Z_BUF_ERROR:if(0!==this.strm.avail_out&&this.flush===t.Z_FINISH)return this._error("unexpected end of file"),!1;break;case t.Z_STREAM_END:break;case t.Z_NEED_DICT:return null==this.dictionary?this._error("Missing dictionary"):this._error("Bad dictionary"),!1;default:return this._error("Zlib error"),!1}return!0},f.prototype._after=function(){if(this._checkError()){var e=this.strm.avail_out,t=this.strm.avail_in;this.write_in_progress=!1,this.callback(t,e),this.pending_close&&this.close()}},f.prototype._error=function(e){this.strm.msg&&(e=this.strm.msg),this.onerror(e,this.err),this.write_in_progress=!1,this.pending_close&&this.close()},f.prototype.init=function(e,n,r,o,s){i(4===arguments.length||5===arguments.length,"init(windowBits, level, memLevel, strategy, [dictionary])"),i(e>=8&&e<=15,"invalid windowBits"),i(n>=-1&&n<=9,"invalid compression level"),i(r>=1&&r<=9,"invalid memlevel"),i(o===t.Z_FILTERED||o===t.Z_HUFFMAN_ONLY||o===t.Z_RLE||o===t.Z_FIXED||o===t.Z_DEFAULT_STRATEGY,"invalid strategy"),this._init(n,e,r,o,s),this._setDictionary()},f.prototype.params=function(){throw new Error("deflateParams Not supported")},f.prototype.reset=function(){this._reset(),this._setDictionary()},f.prototype._init=function(e,n,r,i,l){switch(this.level=e,this.windowBits=n,this.memLevel=r,this.strategy=i,this.flush=t.Z_NO_FLUSH,this.err=t.Z_OK,this.mode!==t.GZIP&&this.mode!==t.GUNZIP||(this.windowBits+=16),this.mode===t.UNZIP&&(this.windowBits+=32),this.mode!==t.DEFLATERAW&&this.mode!==t.INFLATERAW||(this.windowBits=-1*this.windowBits),this.strm=new o,this.mode){case t.DEFLATE:case t.GZIP:case t.DEFLATERAW:this.err=s.deflateInit2(this.strm,this.level,t.Z_DEFLATED,this.windowBits,this.memLevel,this.strategy);break;case t.INFLATE:case t.GUNZIP:case t.INFLATERAW:case t.UNZIP:this.err=a.inflateInit2(this.strm,this.windowBits);break;default:throw new Error("Unknown mode "+this.mode)}this.err!==t.Z_OK&&this._error("Init error"),this.dictionary=l,this.write_in_progress=!1,this.init_done=!0},f.prototype._setDictionary=function(){if(null!=this.dictionary){switch(this.err=t.Z_OK,this.mode){case t.DEFLATE:case t.DEFLATERAW:this.err=s.deflateSetDictionary(this.strm,this.dictionary)}this.err!==t.Z_OK&&this._error("Failed to set dictionary")}},f.prototype._reset=function(){switch(this.err=t.Z_OK,this.mode){case t.DEFLATE:case t.DEFLATERAW:case t.GZIP:this.err=s.deflateReset(this.strm);break;case t.INFLATE:case t.INFLATERAW:case t.GUNZIP:this.err=a.inflateReset(this.strm)}this.err!==t.Z_OK&&this._error("Failed to reset stream")},t.Zlib=f}).call(this,n(0).Buffer,n(3))},function(e,t,n){"use strict";function r(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}e.exports=r},function(e,t,n){"use strict";var r=n(235),i=n(1641),o=n(612),s=n(613),a=n(1642),l=0,u=1,c=3,h=4,f=5,p=0,d=1,m=-2,g=-3,y=-5,v=-1,b=1,_=2,w=3,k=4,E=0,S=2,x=8,C=9,A=15,T=8,I=29,j=256,R=286,B=30,O=19,P=2*R+1,N=15,D=3,M=258,F=M+D+1,L=32,U=42,q=69,z=73,K=91,H=103,V=113,$=666,W=1,G=2,Y=3,Z=4,J=3,Q;function X(e,t){return e.msg=a[t],t}function ee(e){return(e<<1)-(e>4?9:0)}function te(e){for(var t=e.length;--t>=0;)e[t]=0}function ne(e){var t=e.state,n=t.pending;n>e.avail_out&&(n=e.avail_out),0!==n&&(r.arraySet(e.output,t.pending_buf,t.pending_out,n,e.next_out),e.next_out+=n,t.pending_out+=n,e.total_out+=n,e.avail_out-=n,t.pending-=n,0===t.pending&&(t.pending_out=0))}function re(e,t){i._tr_flush_block(e,e.block_start>=0?e.block_start:-1,e.strstart-e.block_start,t),e.block_start=e.strstart,ne(e.strm)}function ie(e,t){e.pending_buf[e.pending++]=t}function oe(e,t){e.pending_buf[e.pending++]=t>>>8&255,e.pending_buf[e.pending++]=255&t}function se(e,t,n,i){var a=e.avail_in;return a>i&&(a=i),0===a?0:(e.avail_in-=a,r.arraySet(t,e.input,e.next_in,a,n),1===e.state.wrap?e.adler=o(e.adler,t,a,n):2===e.state.wrap&&(e.adler=s(e.adler,t,a,n)),e.next_in+=a,e.total_in+=a,a)}function ae(e,t){var n=e.max_chain_length,r=e.strstart,i,o,s=e.prev_length,a=e.nice_match,l=e.strstart>e.w_size-F?e.strstart-(e.w_size-F):0,u=e.window,c=e.w_mask,h=e.prev,f=e.strstart+M,p=u[r+s-1],d=u[r+s];e.prev_length>=e.good_match&&(n>>=2),a>e.lookahead&&(a=e.lookahead);do{if(i=t,u[i+s]===d&&u[i+s-1]===p&&u[i]===u[r]&&u[++i]===u[r+1]){r+=2,i++;do{}while(u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&u[++r]===u[++i]&&r<f);if(o=M-(f-r),r=f-M,o>s){if(e.match_start=t,s=o,o>=a)break;p=u[r+s-1],d=u[r+s]}}}while((t=h[t&c])>l&&0!=--n);return s<=e.lookahead?s:e.lookahead}function le(e){var t=e.w_size,n,i,o,s,a;do{if(s=e.window_size-e.lookahead-e.strstart,e.strstart>=t+(t-F)){r.arraySet(e.window,e.window,t,t,0),e.match_start-=t,e.strstart-=t,e.block_start-=t,i=e.hash_size,n=i;do{o=e.head[--n],e.head[n]=o>=t?o-t:0}while(--i);i=t,n=i;do{o=e.prev[--n],e.prev[n]=o>=t?o-t:0}while(--i);s+=t}if(0===e.strm.avail_in)break;if(i=se(e.strm,e.window,e.strstart+e.lookahead,s),e.lookahead+=i,e.lookahead+e.insert>=D)for(a=e.strstart-e.insert,e.ins_h=e.window[a],e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+1])&e.hash_mask;e.insert&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[a+D-1])&e.hash_mask,e.prev[a&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=a,a++,e.insert--,!(e.lookahead+e.insert<D)););}while(e.lookahead<F&&0!==e.strm.avail_in)}function ue(e,t){var n=65535;for(n>e.pending_buf_size-5&&(n=e.pending_buf_size-5);;){if(e.lookahead<=1){if(le(e),0===e.lookahead&&t===l)return W;if(0===e.lookahead)break}e.strstart+=e.lookahead,e.lookahead=0;var r=e.block_start+n;if((0===e.strstart||e.strstart>=r)&&(e.lookahead=e.strstart-r,e.strstart=r,re(e,!1),0===e.strm.avail_out))return W;if(e.strstart-e.block_start>=e.w_size-F&&(re(e,!1),0===e.strm.avail_out))return W}return e.insert=0,t===h?(re(e,!0),0===e.strm.avail_out?Y:Z):(e.strstart>e.block_start&&(re(e,!1),e.strm.avail_out),W)}function ce(e,t){for(var n,r;;){if(e.lookahead<F){if(le(e),e.lookahead<F&&t===l)return W;if(0===e.lookahead)break}if(n=0,e.lookahead>=D&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+D-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),0!==n&&e.strstart-n<=e.w_size-F&&(e.match_length=ae(e,n)),e.match_length>=D)if(r=i._tr_tally(e,e.strstart-e.match_start,e.match_length-D),e.lookahead-=e.match_length,e.match_length<=e.max_lazy_match&&e.lookahead>=D){e.match_length--;do{e.strstart++,e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+D-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart}while(0!=--e.match_length);e.strstart++}else e.strstart+=e.match_length,e.match_length=0,e.ins_h=e.window[e.strstart],e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+1])&e.hash_mask;else r=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++;if(r&&(re(e,!1),0===e.strm.avail_out))return W}return e.insert=e.strstart<D-1?e.strstart:D-1,t===h?(re(e,!0),0===e.strm.avail_out?Y:Z):e.last_lit&&(re(e,!1),0===e.strm.avail_out)?W:G}function he(e,t){for(var n,r,o;;){if(e.lookahead<F){if(le(e),e.lookahead<F&&t===l)return W;if(0===e.lookahead)break}if(n=0,e.lookahead>=D&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+D-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart),e.prev_length=e.match_length,e.prev_match=e.match_start,e.match_length=D-1,0!==n&&e.prev_length<e.max_lazy_match&&e.strstart-n<=e.w_size-F&&(e.match_length=ae(e,n),e.match_length<=5&&(e.strategy===b||e.match_length===D&&e.strstart-e.match_start>4096)&&(e.match_length=D-1)),e.prev_length>=D&&e.match_length<=e.prev_length){o=e.strstart+e.lookahead-D,r=i._tr_tally(e,e.strstart-1-e.prev_match,e.prev_length-D),e.lookahead-=e.prev_length-1,e.prev_length-=2;do{++e.strstart<=o&&(e.ins_h=(e.ins_h<<e.hash_shift^e.window[e.strstart+D-1])&e.hash_mask,n=e.prev[e.strstart&e.w_mask]=e.head[e.ins_h],e.head[e.ins_h]=e.strstart)}while(0!=--e.prev_length);if(e.match_available=0,e.match_length=D-1,e.strstart++,r&&(re(e,!1),0===e.strm.avail_out))return W}else if(e.match_available){if(r=i._tr_tally(e,0,e.window[e.strstart-1]),r&&re(e,!1),e.strstart++,e.lookahead--,0===e.strm.avail_out)return W}else e.match_available=1,e.strstart++,e.lookahead--}return e.match_available&&(r=i._tr_tally(e,0,e.window[e.strstart-1]),e.match_available=0),e.insert=e.strstart<D-1?e.strstart:D-1,t===h?(re(e,!0),0===e.strm.avail_out?Y:Z):e.last_lit&&(re(e,!1),0===e.strm.avail_out)?W:G}function fe(e,t){for(var n,r,o,s,a=e.window;;){if(e.lookahead<=M){if(le(e),e.lookahead<=M&&t===l)return W;if(0===e.lookahead)break}if(e.match_length=0,e.lookahead>=D&&e.strstart>0&&(o=e.strstart-1,r=a[o],r===a[++o]&&r===a[++o]&&r===a[++o])){s=e.strstart+M;do{}while(r===a[++o]&&r===a[++o]&&r===a[++o]&&r===a[++o]&&r===a[++o]&&r===a[++o]&&r===a[++o]&&r===a[++o]&&o<s);e.match_length=M-(s-o),e.match_length>e.lookahead&&(e.match_length=e.lookahead)}if(e.match_length>=D?(n=i._tr_tally(e,1,e.match_length-D),e.lookahead-=e.match_length,e.strstart+=e.match_length,e.match_length=0):(n=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++),n&&(re(e,!1),0===e.strm.avail_out))return W}return e.insert=0,t===h?(re(e,!0),0===e.strm.avail_out?Y:Z):e.last_lit&&(re(e,!1),0===e.strm.avail_out)?W:G}function pe(e,t){for(var n;;){if(0===e.lookahead&&(le(e),0===e.lookahead)){if(t===l)return W;break}if(e.match_length=0,n=i._tr_tally(e,0,e.window[e.strstart]),e.lookahead--,e.strstart++,n&&(re(e,!1),0===e.strm.avail_out))return W}return e.insert=0,t===h?(re(e,!0),0===e.strm.avail_out?Y:Z):e.last_lit&&(re(e,!1),0===e.strm.avail_out)?W:G}function de(e,t,n,r,i){this.good_length=e,this.max_lazy=t,this.nice_length=n,this.max_chain=r,this.func=i}function me(e){e.window_size=2*e.w_size,te(e.head),e.max_lazy_match=Q[e.level].max_lazy,e.good_match=Q[e.level].good_length,e.nice_match=Q[e.level].nice_length,e.max_chain_length=Q[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=D-1,e.match_available=0,e.ins_h=0}function ge(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=x,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new r.Buf16(2*P),this.dyn_dtree=new r.Buf16(2*(2*B+1)),this.bl_tree=new r.Buf16(2*(2*O+1)),te(this.dyn_ltree),te(this.dyn_dtree),te(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new r.Buf16(N+1),this.heap=new r.Buf16(2*R+1),te(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new r.Buf16(2*R+1),te(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function ye(e){var t;return e&&e.state?(e.total_in=e.total_out=0,e.data_type=S,t=e.state,t.pending=0,t.pending_out=0,t.wrap<0&&(t.wrap=-t.wrap),t.status=t.wrap?U:V,e.adler=2===t.wrap?0:1,t.last_flush=l,i._tr_init(t),p):X(e,m)}function ve(e){var t=ye(e);return t===p&&me(e.state),t}function be(e,t){return e&&e.state?2!==e.state.wrap?m:(e.state.gzhead=t,p):m}function _e(e,t,n,i,o,s){if(!e)return m;var a=1;if(t===v&&(t=6),i<0?(a=0,i=-i):i>15&&(a=2,i-=16),o<1||o>C||n!==x||i<8||i>15||t<0||t>9||s<0||s>k)return X(e,m);8===i&&(i=9);var l=new ge;return e.state=l,l.strm=e,l.wrap=a,l.gzhead=null,l.w_bits=i,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=o+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+D-1)/D),l.window=new r.Buf8(2*l.w_size),l.head=new r.Buf16(l.hash_size),l.prev=new r.Buf16(l.w_size),l.lit_bufsize=1<<o+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new r.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=t,l.strategy=s,l.method=n,ve(e)}function we(e,t){return _e(e,t,x,A,T,E)}function ke(e,t){var n,r,o,a;if(!e||!e.state||t>f||t<0)return e?X(e,m):m;if(r=e.state,!e.output||!e.input&&0!==e.avail_in||r.status===$&&t!==h)return X(e,0===e.avail_out?y:m);if(r.strm=e,n=r.last_flush,r.last_flush=t,r.status===U)if(2===r.wrap)e.adler=0,ie(r,31),ie(r,139),ie(r,8),r.gzhead?(ie(r,(r.gzhead.text?1:0)+(r.gzhead.hcrc?2:0)+(r.gzhead.extra?4:0)+(r.gzhead.name?8:0)+(r.gzhead.comment?16:0)),ie(r,255&r.gzhead.time),ie(r,r.gzhead.time>>8&255),ie(r,r.gzhead.time>>16&255),ie(r,r.gzhead.time>>24&255),ie(r,9===r.level?2:r.strategy>=_||r.level<2?4:0),ie(r,255&r.gzhead.os),r.gzhead.extra&&r.gzhead.extra.length&&(ie(r,255&r.gzhead.extra.length),ie(r,r.gzhead.extra.length>>8&255)),r.gzhead.hcrc&&(e.adler=s(e.adler,r.pending_buf,r.pending,0)),r.gzindex=0,r.status=q):(ie(r,0),ie(r,0),ie(r,0),ie(r,0),ie(r,0),ie(r,9===r.level?2:r.strategy>=_||r.level<2?4:0),ie(r,J),r.status=V);else{var g=x+(r.w_bits-8<<4)<<8,v=-1;v=r.strategy>=_||r.level<2?0:r.level<6?1:6===r.level?2:3,g|=v<<6,0!==r.strstart&&(g|=L),g+=31-g%31,r.status=V,oe(r,g),0!==r.strstart&&(oe(r,e.adler>>>16),oe(r,65535&e.adler)),e.adler=1}if(r.status===q)if(r.gzhead.extra){for(o=r.pending;r.gzindex<(65535&r.gzhead.extra.length)&&(r.pending!==r.pending_buf_size||(r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),ne(e),o=r.pending,r.pending!==r.pending_buf_size));)ie(r,255&r.gzhead.extra[r.gzindex]),r.gzindex++;r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),r.gzindex===r.gzhead.extra.length&&(r.gzindex=0,r.status=z)}else r.status=z;if(r.status===z)if(r.gzhead.name){o=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),ne(e),o=r.pending,r.pending===r.pending_buf_size)){a=1;break}a=r.gzindex<r.gzhead.name.length?255&r.gzhead.name.charCodeAt(r.gzindex++):0,ie(r,a)}while(0!==a);r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),0===a&&(r.gzindex=0,r.status=K)}else r.status=K;if(r.status===K)if(r.gzhead.comment){o=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),ne(e),o=r.pending,r.pending===r.pending_buf_size)){a=1;break}a=r.gzindex<r.gzhead.comment.length?255&r.gzhead.comment.charCodeAt(r.gzindex++):0,ie(r,a)}while(0!==a);r.gzhead.hcrc&&r.pending>o&&(e.adler=s(e.adler,r.pending_buf,r.pending-o,o)),0===a&&(r.status=H)}else r.status=H;if(r.status===H&&(r.gzhead.hcrc?(r.pending+2>r.pending_buf_size&&ne(e),r.pending+2<=r.pending_buf_size&&(ie(r,255&e.adler),ie(r,e.adler>>8&255),e.adler=0,r.status=V)):r.status=V),0!==r.pending){if(ne(e),0===e.avail_out)return r.last_flush=-1,p}else if(0===e.avail_in&&ee(t)<=ee(n)&&t!==h)return X(e,y);if(r.status===$&&0!==e.avail_in)return X(e,y);if(0!==e.avail_in||0!==r.lookahead||t!==l&&r.status!==$){var b=r.strategy===_?pe(r,t):r.strategy===w?fe(r,t):Q[r.level].func(r,t);if(b!==Y&&b!==Z||(r.status=$),b===W||b===Y)return 0===e.avail_out&&(r.last_flush=-1),p;if(b===G&&(t===u?i._tr_align(r):t!==f&&(i._tr_stored_block(r,0,0,!1),t===c&&(te(r.head),0===r.lookahead&&(r.strstart=0,r.block_start=0,r.insert=0))),ne(e),0===e.avail_out))return r.last_flush=-1,p}return t!==h?p:r.wrap<=0?d:(2===r.wrap?(ie(r,255&e.adler),ie(r,e.adler>>8&255),ie(r,e.adler>>16&255),ie(r,e.adler>>24&255),ie(r,255&e.total_in),ie(r,e.total_in>>8&255),ie(r,e.total_in>>16&255),ie(r,e.total_in>>24&255)):(oe(r,e.adler>>>16),oe(r,65535&e.adler)),ne(e),r.wrap>0&&(r.wrap=-r.wrap),0!==r.pending?p:d)}function Ee(e){var t;return e&&e.state?(t=e.state.status,t!==U&&t!==q&&t!==z&&t!==K&&t!==H&&t!==V&&t!==$?X(e,m):(e.state=null,t===V?X(e,g):p)):m}function Se(e,t){var n=t.length,i,s,a,l,u,c,h,f;if(!e||!e.state)return m;if(i=e.state,l=i.wrap,2===l||1===l&&i.status!==U||i.lookahead)return m;for(1===l&&(e.adler=o(e.adler,t,n,0)),i.wrap=0,n>=i.w_size&&(0===l&&(te(i.head),i.strstart=0,i.block_start=0,i.insert=0),f=new r.Buf8(i.w_size),r.arraySet(f,t,n-i.w_size,i.w_size,0),t=f,n=i.w_size),u=e.avail_in,c=e.next_in,h=e.input,e.avail_in=n,e.next_in=0,e.input=t,le(i);i.lookahead>=D;){s=i.strstart,a=i.lookahead-(D-1);do{i.ins_h=(i.ins_h<<i.hash_shift^i.window[s+D-1])&i.hash_mask,i.prev[s&i.w_mask]=i.head[i.ins_h],i.head[i.ins_h]=s,s++}while(--a);i.strstart=s,i.lookahead=D-1,le(i)}return i.strstart+=i.lookahead,i.block_start=i.strstart,i.insert=i.lookahead,i.lookahead=0,i.match_length=i.prev_length=D-1,i.match_available=0,e.next_in=c,e.input=h,e.avail_in=u,i.wrap=l,p}Q=[new de(0,0,0,0,ue),new de(4,4,8,4,ce),new de(4,5,16,8,ce),new de(4,6,32,32,ce),new de(4,4,16,16,he),new de(8,16,32,32,he),new de(8,16,128,128,he),new de(8,32,128,256,he),new de(32,128,258,1024,he),new de(32,258,258,4096,he)],t.deflateInit=we,t.deflateInit2=_e,t.deflateReset=ve,t.deflateResetKeep=ye,t.deflateSetHeader=be,t.deflate=ke,t.deflateEnd=Ee,t.deflateSetDictionary=Se,t.deflateInfo="pako deflate (from Nodeca project)"},function(e,t,n){"use strict";var r=n(235),i=4,o=0,s=1,a=2;function l(e){for(var t=e.length;--t>=0;)e[t]=0}var u=0,c=1,h=2,f=3,p=258,d=29,m=256,g=m+1+d,y=30,v=19,b=2*g+1,_=15,w=16,k=7,E=256,S=16,x=17,C=18,A=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],T=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],I=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],j=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],R=512,B=new Array(2*(g+2));l(B);var O=new Array(2*y);l(O);var P=new Array(512);l(P);var N=new Array(256);l(N);var D=new Array(d);l(D);var M=new Array(y),F,L,U;function q(e,t,n,r,i){this.static_tree=e,this.extra_bits=t,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=e&&e.length}function z(e,t){this.dyn_tree=e,this.max_code=0,this.stat_desc=t}function K(e){return e<256?P[e]:P[256+(e>>>7)]}function H(e,t){e.pending_buf[e.pending++]=255&t,e.pending_buf[e.pending++]=t>>>8&255}function V(e,t,n){e.bi_valid>w-n?(e.bi_buf|=t<<e.bi_valid&65535,H(e,e.bi_buf),e.bi_buf=t>>w-e.bi_valid,e.bi_valid+=n-w):(e.bi_buf|=t<<e.bi_valid&65535,e.bi_valid+=n)}function $(e,t,n){V(e,n[2*t],n[2*t+1])}function W(e,t){var n=0;do{n|=1&e,e>>>=1,n<<=1}while(--t>0);return n>>>1}function G(e){16===e.bi_valid?(H(e,e.bi_buf),e.bi_buf=0,e.bi_valid=0):e.bi_valid>=8&&(e.pending_buf[e.pending++]=255&e.bi_buf,e.bi_buf>>=8,e.bi_valid-=8)}function Y(e,t){var n=t.dyn_tree,r=t.max_code,i=t.stat_desc.static_tree,o=t.stat_desc.has_stree,s=t.stat_desc.extra_bits,a=t.stat_desc.extra_base,l=t.stat_desc.max_length,u,c,h,f,p,d,m=0;for(f=0;f<=_;f++)e.bl_count[f]=0;for(n[2*e.heap[e.heap_max]+1]=0,u=e.heap_max+1;u<b;u++)c=e.heap[u],f=n[2*n[2*c+1]+1]+1,f>l&&(f=l,m++),n[2*c+1]=f,c>r||(e.bl_count[f]++,p=0,c>=a&&(p=s[c-a]),d=n[2*c],e.opt_len+=d*(f+p),o&&(e.static_len+=d*(i[2*c+1]+p)));if(0!==m){do{for(f=l-1;0===e.bl_count[f];)f--;e.bl_count[f]--,e.bl_count[f+1]+=2,e.bl_count[l]--,m-=2}while(m>0);for(f=l;0!==f;f--)for(c=e.bl_count[f];0!==c;)h=e.heap[--u],h>r||(n[2*h+1]!==f&&(e.opt_len+=(f-n[2*h+1])*n[2*h],n[2*h+1]=f),c--)}}function Z(e,t,n){var r=new Array(_+1),i=0,o,s;for(o=1;o<=_;o++)r[o]=i=i+n[o-1]<<1;for(s=0;s<=t;s++){var a=e[2*s+1];0!==a&&(e[2*s]=W(r[a]++,a))}}function J(){var e,t,n,r,i,o=new Array(_+1);for(n=0,r=0;r<d-1;r++)for(D[r]=n,e=0;e<1<<A[r];e++)N[n++]=r;for(N[n-1]=r,i=0,r=0;r<16;r++)for(M[r]=i,e=0;e<1<<T[r];e++)P[i++]=r;for(i>>=7;r<y;r++)for(M[r]=i<<7,e=0;e<1<<T[r]-7;e++)P[256+i++]=r;for(t=0;t<=_;t++)o[t]=0;for(e=0;e<=143;)B[2*e+1]=8,e++,o[8]++;for(;e<=255;)B[2*e+1]=9,e++,o[9]++;for(;e<=279;)B[2*e+1]=7,e++,o[7]++;for(;e<=287;)B[2*e+1]=8,e++,o[8]++;for(Z(B,g+1,o),e=0;e<y;e++)O[2*e+1]=5,O[2*e]=W(e,5);F=new q(B,A,m+1,g,_),L=new q(O,T,0,y,_),U=new q(new Array(0),I,0,v,k)}function Q(e){var t;for(t=0;t<g;t++)e.dyn_ltree[2*t]=0;for(t=0;t<y;t++)e.dyn_dtree[2*t]=0;for(t=0;t<v;t++)e.bl_tree[2*t]=0;e.dyn_ltree[2*E]=1,e.opt_len=e.static_len=0,e.last_lit=e.matches=0}function X(e){e.bi_valid>8?H(e,e.bi_buf):e.bi_valid>0&&(e.pending_buf[e.pending++]=e.bi_buf),e.bi_buf=0,e.bi_valid=0}function ee(e,t,n,i){X(e),i&&(H(e,n),H(e,~n)),r.arraySet(e.pending_buf,e.window,t,n,e.pending),e.pending+=n}function te(e,t,n,r){var i=2*t,o=2*n;return e[i]<e[o]||e[i]===e[o]&&r[t]<=r[n]}function ne(e,t,n){for(var r=e.heap[n],i=n<<1;i<=e.heap_len&&(i<e.heap_len&&te(t,e.heap[i+1],e.heap[i],e.depth)&&i++,!te(t,r,e.heap[i],e.depth));)e.heap[n]=e.heap[i],n=i,i<<=1;e.heap[n]=r}function re(e,t,n){var r,i,o=0,s,a;if(0!==e.last_lit)do{r=e.pending_buf[e.d_buf+2*o]<<8|e.pending_buf[e.d_buf+2*o+1],i=e.pending_buf[e.l_buf+o],o++,0===r?$(e,i,t):(s=N[i],$(e,s+m+1,t),a=A[s],0!==a&&(i-=D[s],V(e,i,a)),r--,s=K(r),$(e,s,n),a=T[s],0!==a&&(r-=M[s],V(e,r,a)))}while(o<e.last_lit);$(e,E,t)}function ie(e,t){var n=t.dyn_tree,r=t.stat_desc.static_tree,i=t.stat_desc.has_stree,o=t.stat_desc.elems,s,a,l=-1,u;for(e.heap_len=0,e.heap_max=b,s=0;s<o;s++)0!==n[2*s]?(e.heap[++e.heap_len]=l=s,e.depth[s]=0):n[2*s+1]=0;for(;e.heap_len<2;)u=e.heap[++e.heap_len]=l<2?++l:0,n[2*u]=1,e.depth[u]=0,e.opt_len--,i&&(e.static_len-=r[2*u+1]);for(t.max_code=l,s=e.heap_len>>1;s>=1;s--)ne(e,n,s);u=o;do{s=e.heap[1],e.heap[1]=e.heap[e.heap_len--],ne(e,n,1),a=e.heap[1],e.heap[--e.heap_max]=s,e.heap[--e.heap_max]=a,n[2*u]=n[2*s]+n[2*a],e.depth[u]=(e.depth[s]>=e.depth[a]?e.depth[s]:e.depth[a])+1,n[2*s+1]=n[2*a+1]=u,e.heap[1]=u++,ne(e,n,1)}while(e.heap_len>=2);e.heap[--e.heap_max]=e.heap[1],Y(e,t),Z(n,l,e.bl_count)}function oe(e,t,n){var r,i=-1,o,s=t[1],a=0,l=7,u=4;for(0===s&&(l=138,u=3),t[2*(n+1)+1]=65535,r=0;r<=n;r++)o=s,s=t[2*(r+1)+1],++a<l&&o===s||(a<u?e.bl_tree[2*o]+=a:0!==o?(o!==i&&e.bl_tree[2*o]++,e.bl_tree[2*S]++):a<=10?e.bl_tree[2*x]++:e.bl_tree[2*C]++,a=0,i=o,0===s?(l=138,u=3):o===s?(l=6,u=3):(l=7,u=4))}function se(e,t,n){var r,i=-1,o,s=t[1],a=0,l=7,u=4;for(0===s&&(l=138,u=3),r=0;r<=n;r++)if(o=s,s=t[2*(r+1)+1],!(++a<l&&o===s)){if(a<u)do{$(e,o,e.bl_tree)}while(0!=--a);else 0!==o?(o!==i&&($(e,o,e.bl_tree),a--),$(e,S,e.bl_tree),V(e,a-3,2)):a<=10?($(e,x,e.bl_tree),V(e,a-3,3)):($(e,C,e.bl_tree),V(e,a-11,7));a=0,i=o,0===s?(l=138,u=3):o===s?(l=6,u=3):(l=7,u=4)}}function ae(e){var t;for(oe(e,e.dyn_ltree,e.l_desc.max_code),oe(e,e.dyn_dtree,e.d_desc.max_code),ie(e,e.bl_desc),t=v-1;t>=3&&0===e.bl_tree[2*j[t]+1];t--);return e.opt_len+=3*(t+1)+5+5+4,t}function le(e,t,n,r){var i;for(V(e,t-257,5),V(e,n-1,5),V(e,r-4,4),i=0;i<r;i++)V(e,e.bl_tree[2*j[i]+1],3);se(e,e.dyn_ltree,t-1),se(e,e.dyn_dtree,n-1)}function ue(e){var t=4093624447,n;for(n=0;n<=31;n++,t>>>=1)if(1&t&&0!==e.dyn_ltree[2*n])return o;if(0!==e.dyn_ltree[18]||0!==e.dyn_ltree[20]||0!==e.dyn_ltree[26])return s;for(n=32;n<m;n++)if(0!==e.dyn_ltree[2*n])return s;return o}l(M);var ce=!1;function he(e){ce||(J(),ce=!0),e.l_desc=new z(e.dyn_ltree,F),e.d_desc=new z(e.dyn_dtree,L),e.bl_desc=new z(e.bl_tree,U),e.bi_buf=0,e.bi_valid=0,Q(e)}function fe(e,t,n,r){V(e,(u<<1)+(r?1:0),3),ee(e,t,n,!0)}function pe(e){V(e,c<<1,3),$(e,E,B),G(e)}function de(e,t,n,r){var o,s,l=0;e.level>0?(e.strm.data_type===a&&(e.strm.data_type=ue(e)),ie(e,e.l_desc),ie(e,e.d_desc),l=ae(e),o=e.opt_len+3+7>>>3,s=e.static_len+3+7>>>3,s<=o&&(o=s)):o=s=n+5,n+4<=o&&-1!==t?fe(e,t,n,r):e.strategy===i||s===o?(V(e,(c<<1)+(r?1:0),3),re(e,B,O)):(V(e,(h<<1)+(r?1:0),3),le(e,e.l_desc.max_code+1,e.d_desc.max_code+1,l+1),re(e,e.dyn_ltree,e.dyn_dtree)),Q(e),r&&X(e)}function me(e,t,n){return e.pending_buf[e.d_buf+2*e.last_lit]=t>>>8&255,e.pending_buf[e.d_buf+2*e.last_lit+1]=255&t,e.pending_buf[e.l_buf+e.last_lit]=255&n,e.last_lit++,0===t?e.dyn_ltree[2*n]++:(e.matches++,t--,e.dyn_ltree[2*(N[n]+m+1)]++,e.dyn_dtree[2*K(t)]++),e.last_lit===e.lit_bufsize-1}t._tr_init=he,t._tr_stored_block=fe,t._tr_flush_block=de,t._tr_tally=me,t._tr_align=pe},function(e,t,n){"use strict";e.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},function(e,t,n){"use strict";var r=n(235),i=n(612),o=n(613),s=n(1644),a=n(1645),l=0,u=1,c=2,h=4,f=5,p=6,d=0,m=1,g=2,y=-2,v=-3,b=-4,_=-5,w=8,k=1,E=2,S=3,x=4,C=5,A=6,T=7,I=8,j=9,R=10,B=11,O=12,P=13,N=14,D=15,M=16,F=17,L=18,U=19,q=20,z=21,K=22,H=23,V=24,$=25,W=26,G=27,Y=28,Z=29,J=30,Q=31,X=32,ee=852,te=592,ne=15,re=15;function ie(e){return(e>>>24&255)+(e>>>8&65280)+((65280&e)<<8)+((255&e)<<24)}function oe(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new r.Buf16(320),this.work=new r.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function se(e){var t;return e&&e.state?(t=e.state,e.total_in=e.total_out=t.total=0,e.msg="",t.wrap&&(e.adler=1&t.wrap),t.mode=k,t.last=0,t.havedict=0,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new r.Buf32(ee),t.distcode=t.distdyn=new r.Buf32(te),t.sane=1,t.back=-1,d):y}function ae(e){var t;return e&&e.state?(t=e.state,t.wsize=0,t.whave=0,t.wnext=0,se(e)):y}function le(e,t){var n,r;return e&&e.state?(r=e.state,t<0?(n=0,t=-t):(n=1+(t>>4),t<48&&(t&=15)),t&&(t<8||t>15)?y:(null!==r.window&&r.wbits!==t&&(r.window=null),r.wrap=n,r.wbits=t,ae(e))):y}function ue(e,t){var n,r;return e?(r=new oe,e.state=r,r.window=null,n=le(e,t),n!==d&&(e.state=null),n):y}function ce(e){return ue(e,re)}var he=!0,fe,pe;function de(e){if(he){var t;for(fe=new r.Buf32(512),pe=new r.Buf32(32),t=0;t<144;)e.lens[t++]=8;for(;t<256;)e.lens[t++]=9;for(;t<280;)e.lens[t++]=7;for(;t<288;)e.lens[t++]=8;for(a(u,e.lens,0,288,fe,0,e.work,{bits:9}),t=0;t<32;)e.lens[t++]=5;a(c,e.lens,0,32,pe,0,e.work,{bits:5}),he=!1}e.lencode=fe,e.lenbits=9,e.distcode=pe,e.distbits=5}function me(e,t,n,i){var o,s=e.state;return null===s.window&&(s.wsize=1<<s.wbits,s.wnext=0,s.whave=0,s.window=new r.Buf8(s.wsize)),i>=s.wsize?(r.arraySet(s.window,t,n-s.wsize,s.wsize,0),s.wnext=0,s.whave=s.wsize):(o=s.wsize-s.wnext,o>i&&(o=i),r.arraySet(s.window,t,n-i,o,s.wnext),i-=o,i?(r.arraySet(s.window,t,n-i,i,0),s.wnext=i,s.whave=s.wsize):(s.wnext+=o,s.wnext===s.wsize&&(s.wnext=0),s.whave<s.wsize&&(s.whave+=o))),0}function ge(e,t){var n,ee,te,ne,re,oe,se,ae,le,ue,ce,he,fe,pe,ge=0,ye,ve,be,_e,we,ke,Ee,Se,xe=new r.Buf8(4),Ce,Ae,Te=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!e||!e.state||!e.output||!e.input&&0!==e.avail_in)return y;n=e.state,n.mode===O&&(n.mode=P),re=e.next_out,te=e.output,se=e.avail_out,ne=e.next_in,ee=e.input,oe=e.avail_in,ae=n.hold,le=n.bits,ue=oe,ce=se,Se=d;e:for(;;)switch(n.mode){case k:if(0===n.wrap){n.mode=P;break}for(;le<16;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(2&n.wrap&&35615===ae){n.check=0,xe[0]=255&ae,xe[1]=ae>>>8&255,n.check=o(n.check,xe,2,0),ae=0,le=0,n.mode=E;break}if(n.flags=0,n.head&&(n.head.done=!1),!(1&n.wrap)||(((255&ae)<<8)+(ae>>8))%31){e.msg="incorrect header check",n.mode=J;break}if((15&ae)!==w){e.msg="unknown compression method",n.mode=J;break}if(ae>>>=4,le-=4,Ee=8+(15&ae),0===n.wbits)n.wbits=Ee;else if(Ee>n.wbits){e.msg="invalid window size",n.mode=J;break}n.dmax=1<<Ee,e.adler=n.check=1,n.mode=512&ae?R:O,ae=0,le=0;break;case E:for(;le<16;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(n.flags=ae,(255&n.flags)!==w){e.msg="unknown compression method",n.mode=J;break}if(57344&n.flags){e.msg="unknown header flags set",n.mode=J;break}n.head&&(n.head.text=ae>>8&1),512&n.flags&&(xe[0]=255&ae,xe[1]=ae>>>8&255,n.check=o(n.check,xe,2,0)),ae=0,le=0,n.mode=S;case S:for(;le<32;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.head&&(n.head.time=ae),512&n.flags&&(xe[0]=255&ae,xe[1]=ae>>>8&255,xe[2]=ae>>>16&255,xe[3]=ae>>>24&255,n.check=o(n.check,xe,4,0)),ae=0,le=0,n.mode=x;case x:for(;le<16;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.head&&(n.head.xflags=255&ae,n.head.os=ae>>8),512&n.flags&&(xe[0]=255&ae,xe[1]=ae>>>8&255,n.check=o(n.check,xe,2,0)),ae=0,le=0,n.mode=C;case C:if(1024&n.flags){for(;le<16;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.length=ae,n.head&&(n.head.extra_len=ae),512&n.flags&&(xe[0]=255&ae,xe[1]=ae>>>8&255,n.check=o(n.check,xe,2,0)),ae=0,le=0}else n.head&&(n.head.extra=null);n.mode=A;case A:if(1024&n.flags&&(he=n.length,he>oe&&(he=oe),he&&(n.head&&(Ee=n.head.extra_len-n.length,n.head.extra||(n.head.extra=new Array(n.head.extra_len)),r.arraySet(n.head.extra,ee,ne,he,Ee)),512&n.flags&&(n.check=o(n.check,ee,he,ne)),oe-=he,ne+=he,n.length-=he),n.length))break e;n.length=0,n.mode=T;case T:if(2048&n.flags){if(0===oe)break e;he=0;do{Ee=ee[ne+he++],n.head&&Ee&&n.length<65536&&(n.head.name+=String.fromCharCode(Ee))}while(Ee&&he<oe);if(512&n.flags&&(n.check=o(n.check,ee,he,ne)),oe-=he,ne+=he,Ee)break e}else n.head&&(n.head.name=null);n.length=0,n.mode=I;case I:if(4096&n.flags){if(0===oe)break e;he=0;do{Ee=ee[ne+he++],n.head&&Ee&&n.length<65536&&(n.head.comment+=String.fromCharCode(Ee))}while(Ee&&he<oe);if(512&n.flags&&(n.check=o(n.check,ee,he,ne)),oe-=he,ne+=he,Ee)break e}else n.head&&(n.head.comment=null);n.mode=j;case j:if(512&n.flags){for(;le<16;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(ae!==(65535&n.check)){e.msg="header crc mismatch",n.mode=J;break}ae=0,le=0}n.head&&(n.head.hcrc=n.flags>>9&1,n.head.done=!0),e.adler=n.check=0,n.mode=O;break;case R:for(;le<32;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}e.adler=n.check=ie(ae),ae=0,le=0,n.mode=B;case B:if(0===n.havedict)return e.next_out=re,e.avail_out=se,e.next_in=ne,e.avail_in=oe,n.hold=ae,n.bits=le,g;e.adler=n.check=1,n.mode=O;case O:if(t===f||t===p)break e;case P:if(n.last){ae>>>=7&le,le-=7&le,n.mode=G;break}for(;le<3;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}switch(n.last=1&ae,ae>>>=1,le-=1,3&ae){case 0:n.mode=N;break;case 1:if(de(n),n.mode=q,t===p){ae>>>=2,le-=2;break e}break;case 2:n.mode=F;break;case 3:e.msg="invalid block type",n.mode=J}ae>>>=2,le-=2;break;case N:for(ae>>>=7&le,le-=7&le;le<32;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if((65535&ae)!=(ae>>>16^65535)){e.msg="invalid stored block lengths",n.mode=J;break}if(n.length=65535&ae,ae=0,le=0,n.mode=D,t===p)break e;case D:n.mode=M;case M:if(he=n.length,he){if(he>oe&&(he=oe),he>se&&(he=se),0===he)break e;r.arraySet(te,ee,ne,he,re),oe-=he,ne+=he,se-=he,re+=he,n.length-=he;break}n.mode=O;break;case F:for(;le<14;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(n.nlen=257+(31&ae),ae>>>=5,le-=5,n.ndist=1+(31&ae),ae>>>=5,le-=5,n.ncode=4+(15&ae),ae>>>=4,le-=4,n.nlen>286||n.ndist>30){e.msg="too many length or distance symbols",n.mode=J;break}n.have=0,n.mode=L;case L:for(;n.have<n.ncode;){for(;le<3;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.lens[Te[n.have++]]=7&ae,ae>>>=3,le-=3}for(;n.have<19;)n.lens[Te[n.have++]]=0;if(n.lencode=n.lendyn,n.lenbits=7,Ce={bits:n.lenbits},Se=a(l,n.lens,0,19,n.lencode,0,n.work,Ce),n.lenbits=Ce.bits,Se){e.msg="invalid code lengths set",n.mode=J;break}n.have=0,n.mode=U;case U:for(;n.have<n.nlen+n.ndist;){for(;ge=n.lencode[ae&(1<<n.lenbits)-1],ye=ge>>>24,ve=ge>>>16&255,be=65535&ge,!(ye<=le);){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(be<16)ae>>>=ye,le-=ye,n.lens[n.have++]=be;else{if(16===be){for(Ae=ye+2;le<Ae;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(ae>>>=ye,le-=ye,0===n.have){e.msg="invalid bit length repeat",n.mode=J;break}Ee=n.lens[n.have-1],he=3+(3&ae),ae>>>=2,le-=2}else if(17===be){for(Ae=ye+3;le<Ae;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}ae>>>=ye,le-=ye,Ee=0,he=3+(7&ae),ae>>>=3,le-=3}else{for(Ae=ye+7;le<Ae;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}ae>>>=ye,le-=ye,Ee=0,he=11+(127&ae),ae>>>=7,le-=7}if(n.have+he>n.nlen+n.ndist){e.msg="invalid bit length repeat",n.mode=J;break}for(;he--;)n.lens[n.have++]=Ee}}if(n.mode===J)break;if(0===n.lens[256]){e.msg="invalid code -- missing end-of-block",n.mode=J;break}if(n.lenbits=9,Ce={bits:n.lenbits},Se=a(u,n.lens,0,n.nlen,n.lencode,0,n.work,Ce),n.lenbits=Ce.bits,Se){e.msg="invalid literal/lengths set",n.mode=J;break}if(n.distbits=6,n.distcode=n.distdyn,Ce={bits:n.distbits},Se=a(c,n.lens,n.nlen,n.ndist,n.distcode,0,n.work,Ce),n.distbits=Ce.bits,Se){e.msg="invalid distances set",n.mode=J;break}if(n.mode=q,t===p)break e;case q:n.mode=z;case z:if(oe>=6&&se>=258){e.next_out=re,e.avail_out=se,e.next_in=ne,e.avail_in=oe,n.hold=ae,n.bits=le,s(e,ce),re=e.next_out,te=e.output,se=e.avail_out,ne=e.next_in,ee=e.input,oe=e.avail_in,ae=n.hold,le=n.bits,n.mode===O&&(n.back=-1);break}for(n.back=0;ge=n.lencode[ae&(1<<n.lenbits)-1],ye=ge>>>24,ve=ge>>>16&255,be=65535&ge,!(ye<=le);){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(ve&&0==(240&ve)){for(_e=ye,we=ve,ke=be;ge=n.lencode[ke+((ae&(1<<_e+we)-1)>>_e)],ye=ge>>>24,ve=ge>>>16&255,be=65535&ge,!(_e+ye<=le);){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}ae>>>=_e,le-=_e,n.back+=_e}if(ae>>>=ye,le-=ye,n.back+=ye,n.length=be,0===ve){n.mode=W;break}if(32&ve){n.back=-1,n.mode=O;break}if(64&ve){e.msg="invalid literal/length code",n.mode=J;break}n.extra=15&ve,n.mode=K;case K:if(n.extra){for(Ae=n.extra;le<Ae;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.length+=ae&(1<<n.extra)-1,ae>>>=n.extra,le-=n.extra,n.back+=n.extra}n.was=n.length,n.mode=H;case H:for(;ge=n.distcode[ae&(1<<n.distbits)-1],ye=ge>>>24,ve=ge>>>16&255,be=65535&ge,!(ye<=le);){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(0==(240&ve)){for(_e=ye,we=ve,ke=be;ge=n.distcode[ke+((ae&(1<<_e+we)-1)>>_e)],ye=ge>>>24,ve=ge>>>16&255,be=65535&ge,!(_e+ye<=le);){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}ae>>>=_e,le-=_e,n.back+=_e}if(ae>>>=ye,le-=ye,n.back+=ye,64&ve){e.msg="invalid distance code",n.mode=J;break}n.offset=be,n.extra=15&ve,n.mode=V;case V:if(n.extra){for(Ae=n.extra;le<Ae;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}n.offset+=ae&(1<<n.extra)-1,ae>>>=n.extra,le-=n.extra,n.back+=n.extra}if(n.offset>n.dmax){e.msg="invalid distance too far back",n.mode=J;break}n.mode=$;case $:if(0===se)break e;if(he=ce-se,n.offset>he){if(he=n.offset-he,he>n.whave&&n.sane){e.msg="invalid distance too far back",n.mode=J;break}he>n.wnext?(he-=n.wnext,fe=n.wsize-he):fe=n.wnext-he,he>n.length&&(he=n.length),pe=n.window}else pe=te,fe=re-n.offset,he=n.length;he>se&&(he=se),se-=he,n.length-=he;do{te[re++]=pe[fe++]}while(--he);0===n.length&&(n.mode=z);break;case W:if(0===se)break e;te[re++]=n.length,se--,n.mode=z;break;case G:if(n.wrap){for(;le<32;){if(0===oe)break e;oe--,ae|=ee[ne++]<<le,le+=8}if(ce-=se,e.total_out+=ce,n.total+=ce,ce&&(e.adler=n.check=n.flags?o(n.check,te,ce,re-ce):i(n.check,te,ce,re-ce)),ce=se,(n.flags?ae:ie(ae))!==n.check){e.msg="incorrect data check",n.mode=J;break}ae=0,le=0}n.mode=Y;case Y:if(n.wrap&&n.flags){for(;le<32;){if(0===oe)break e;oe--,ae+=ee[ne++]<<le,le+=8}if(ae!==(4294967295&n.total)){e.msg="incorrect length check",n.mode=J;break}ae=0,le=0}n.mode=Z;case Z:Se=m;break e;case J:Se=v;break e;case Q:return b;case X:default:return y}return e.next_out=re,e.avail_out=se,e.next_in=ne,e.avail_in=oe,n.hold=ae,n.bits=le,(n.wsize||ce!==e.avail_out&&n.mode<J&&(n.mode<G||t!==h))&&me(e,e.output,e.next_out,ce-e.avail_out)?(n.mode=Q,b):(ue-=e.avail_in,ce-=e.avail_out,e.total_in+=ue,e.total_out+=ce,n.total+=ce,n.wrap&&ce&&(e.adler=n.check=n.flags?o(n.check,te,ce,e.next_out-ce):i(n.check,te,ce,e.next_out-ce)),e.data_type=n.bits+(n.last?64:0)+(n.mode===O?128:0)+(n.mode===q||n.mode===D?256:0),(0===ue&&0===ce||t===h)&&Se===d&&(Se=_),Se)}function ye(e){if(!e||!e.state)return y;var t=e.state;return t.window&&(t.window=null),e.state=null,d}function ve(e,t){var n;return e&&e.state?(n=e.state,0==(2&n.wrap)?y:(n.head=t,t.done=!1,d)):y}function be(e,t){var n=t.length,r,o,s;return e&&e.state?(r=e.state,0!==r.wrap&&r.mode!==B?y:r.mode===B&&(o=1,o=i(o,t,n,0),o!==r.check)?v:(s=me(e,t,n,n),s?(r.mode=Q,b):(r.havedict=1,d))):y}t.inflateReset=ae,t.inflateReset2=le,t.inflateResetKeep=se,t.inflateInit=ce,t.inflateInit2=ue,t.inflate=ge,t.inflateEnd=ye,t.inflateGetHeader=ve,t.inflateSetDictionary=be,t.inflateInfo="pako inflate (from Nodeca project)"},function(e,t,n){"use strict";var r=30,i=12;e.exports=function e(t,n){var r,i,o,s,a,l,u,c,h,f,p,d,m,g,y,v,b,_,w,k,E,S,x,C,A;r=t.state,i=t.next_in,C=t.input,o=i+(t.avail_in-5),s=t.next_out,A=t.output,a=s-(n-t.avail_out),l=s+(t.avail_out-257),u=r.dmax,c=r.wsize,h=r.whave,f=r.wnext,p=r.window,d=r.hold,m=r.bits,g=r.lencode,y=r.distcode,v=(1<<r.lenbits)-1,b=(1<<r.distbits)-1;e:do{m<15&&(d+=C[i++]<<m,m+=8,d+=C[i++]<<m,m+=8),_=g[d&v];t:for(;;){if(w=_>>>24,d>>>=w,m-=w,w=_>>>16&255,0===w)A[s++]=65535&_;else{if(!(16&w)){if(0==(64&w)){_=g[(65535&_)+(d&(1<<w)-1)];continue t}if(32&w){r.mode=12;break e}t.msg="invalid literal/length code",r.mode=30;break e}k=65535&_,w&=15,w&&(m<w&&(d+=C[i++]<<m,m+=8),k+=d&(1<<w)-1,d>>>=w,m-=w),m<15&&(d+=C[i++]<<m,m+=8,d+=C[i++]<<m,m+=8),_=y[d&b];n:for(;;){if(w=_>>>24,d>>>=w,m-=w,w=_>>>16&255,!(16&w)){if(0==(64&w)){_=y[(65535&_)+(d&(1<<w)-1)];continue n}t.msg="invalid distance code",r.mode=30;break e}if(E=65535&_,w&=15,m<w&&(d+=C[i++]<<m,m+=8,m<w&&(d+=C[i++]<<m,m+=8)),E+=d&(1<<w)-1,E>u){t.msg="invalid distance too far back",r.mode=30;break e}if(d>>>=w,m-=w,w=s-a,E>w){if(w=E-w,w>h&&r.sane){t.msg="invalid distance too far back",r.mode=30;break e}if(S=0,x=p,0===f){if(S+=c-w,w<k){k-=w;do{A[s++]=p[S++]}while(--w);S=s-E,x=A}}else if(f<w){if(S+=c+f-w,w-=f,w<k){k-=w;do{A[s++]=p[S++]}while(--w);if(S=0,f<k){w=f,k-=w;do{A[s++]=p[S++]}while(--w);S=s-E,x=A}}}else if(S+=f-w,w<k){k-=w;do{A[s++]=p[S++]}while(--w);S=s-E,x=A}for(;k>2;)A[s++]=x[S++],A[s++]=x[S++],A[s++]=x[S++],k-=3;k&&(A[s++]=x[S++],k>1&&(A[s++]=x[S++]))}else{S=s-E;do{A[s++]=A[S++],A[s++]=A[S++],A[s++]=A[S++],k-=3}while(k>2);k&&(A[s++]=A[S++],k>1&&(A[s++]=A[S++]))}break}}break}}while(i<o&&s<l);k=m>>3,i-=k,m-=k<<3,d&=(1<<m)-1,t.next_in=i,t.next_out=s,t.avail_in=i<o?o-i+5:5-(i-o),t.avail_out=s<l?l-s+257:257-(s-l),r.hold=d,r.bits=m}},function(e,t,n){"use strict";var r=n(235),i=15,o=852,s=592,a=0,l=1,u=2,c=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],h=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],f=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],p=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];e.exports=function e(t,n,i,o,s,a,l,u){var d=u.bits,m=0,g=0,y=0,v=0,b=0,_=0,w=0,k=0,E=0,S=0,x,C,A,T,I,j=null,R=0,B,O=new r.Buf16(16),P=new r.Buf16(16),N=null,D=0,M,F,L;for(m=0;m<=15;m++)O[m]=0;for(g=0;g<o;g++)O[n[i+g]]++;for(b=d,v=15;v>=1&&0===O[v];v--);if(b>v&&(b=v),0===v)return s[a++]=20971520,s[a++]=20971520,u.bits=1,0;for(y=1;y<v&&0===O[y];y++);for(b<y&&(b=y),k=1,m=1;m<=15;m++)if(k<<=1,k-=O[m],k<0)return-1;if(k>0&&(0===t||1!==v))return-1;for(P[1]=0,m=1;m<15;m++)P[m+1]=P[m]+O[m];for(g=0;g<o;g++)0!==n[i+g]&&(l[P[n[i+g]]++]=g);if(0===t?(j=N=l,B=19):1===t?(j=c,R-=257,N=h,D-=257,B=256):(j=f,N=p,B=-1),S=0,g=0,m=y,I=a,_=b,w=0,A=-1,E=1<<b,T=E-1,1===t&&E>852||2===t&&E>592)return 1;for(;;){M=m-w,l[g]<B?(F=0,L=l[g]):l[g]>B?(F=N[D+l[g]],L=j[R+l[g]]):(F=96,L=0),x=1<<m-w,C=1<<_,y=C;do{C-=x,s[I+(S>>w)+C]=M<<24|F<<16|L|0}while(0!==C);for(x=1<<m-1;S&x;)x>>=1;if(0!==x?(S&=x-1,S+=x):S=0,g++,0==--O[m]){if(m===v)break;m=n[i+l[g]]}if(m>b&&(S&T)!==A){for(0===w&&(w=b),I+=y,_=m-w,k=1<<_;_+w<v&&(k-=O[_+w],!(k<=0));)_++,k<<=1;if(E+=1<<_,1===t&&E>852||2===t&&E>592)return 1;A=S&T,s[A]=b<<24|_<<16|I-a|0}}return 0!==S&&(s[I+S]=m-w<<24|64<<16|0),u.bits=b,0}},function(e,t,n){"use strict";e.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},function(e,t,n){
/*!
* Copyright 2010 LearnBoost <dev@learnboost.com>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
var r=n(16),i=n(32).parse,o=["acl","location","logging","notification","partNumber","policy","requestPayment","torrent","uploadId","uploads","versionId","versioning","versions","website"];function s(e){return"AWS "+e.key+":"+l(e)}function a(e){return r.createHmac("sha1",e.secret).update(e.message).digest("base64")}function l(e){return e.message=c(e),a(e)}function u(e){return e.message=h(e),a(e)}function c(e){var t=e.amazonHeaders||"";t&&(t+="\n");var n=[e.verb,e.md5,e.contentType,e.date?e.date.toUTCString():"",t+e.resource];return n.join("\n")}function h(e){return"GET\n\n\n"+e.date+"\n"+e.resource}function f(e){for(var t=[],n=Object.keys(e),r=0,i=n.length;r<i;++r){var o=n[r],s=e[o],o=o.toLowerCase();0===o.indexOf("x-amz")&&t.push(o+":"+s)}return t.sort().join("\n")}function p(e){var t=i(e,!0),n=t.pathname,r=[];return Object.keys(t.query).forEach(function(e){if(~o.indexOf(e)){var n=""==t.query[e]?"":"="+encodeURIComponent(t.query[e]);r.push(e+n)}}),n+(r.length?"?"+r.sort().join("&"):"")}e.exports=s,e.exports.authorization=s,e.exports.hmacSha1=a,e.exports.sign=l,e.exports.signQuery=u,e.exports.stringToSign=c,e.exports.queryStringToSign=h,e.exports.canonicalizeHeaders=f,e.exports.canonicalizeResource=p},function(e,t,n){(function(e){var r=t,i=n(32),o=n(145),s=n(16),a=n(1649),l=a(1e3);function u(e,t,n){return s.createHmac("sha256",e).update(t,"utf8").digest(n)}function c(e,t){return s.createHash("sha256").update(e,"utf8").digest(t)}function h(e){return e.replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}function f(e,t){"string"==typeof e&&(e=i.parse(e));var n=e.headers=e.headers||{},r=this.matchHost(e.hostname||e.host||n.Host||n.host);this.request=e,this.credentials=t||this.defaultCredentials(),this.service=e.service||r[0]||"",this.region=e.region||r[1]||"us-east-1","email"===this.service&&(this.service="ses"),!e.method&&e.body&&(e.method="POST"),n.Host||n.host||(n.Host=e.hostname||e.host||this.createHost(),e.port&&(n.Host+=":"+e.port)),e.hostname||e.host||(e.hostname=n.Host||n.host),this.isCodeCommitGit="codecommit"===this.service&&"GIT"===e.method}f.prototype.matchHost=function(e){var t=(e||"").match(/([^\.]+)\.(?:([^\.]*)\.)?amazonaws\.com(\.cn)?$/),n=(t||[]).slice(1,3);return"es"===n[1]&&(n=n.reverse()),n},f.prototype.isSingleRegion=function(){return["s3","sdb"].indexOf(this.service)>=0&&"us-east-1"===this.region||["cloudfront","ls","route53","iam","importexport","sts"].indexOf(this.service)>=0},f.prototype.createHost=function(){var e=this.isSingleRegion()?"":("s3"===this.service&&"us-east-1"!==this.region?"-":".")+this.region,t="ses"===this.service?"email":this.service;return t+e+".amazonaws.com"},f.prototype.prepareRequest=function(){this.parsePath();var t=this.request,n=t.headers,r;t.signQuery?(this.parsedPath.query=r=this.parsedPath.query||{},this.credentials.sessionToken&&(r["X-Amz-Security-Token"]=this.credentials.sessionToken),"s3"!==this.service||r["X-Amz-Expires"]||(r["X-Amz-Expires"]=86400),r["X-Amz-Date"]?this.datetime=r["X-Amz-Date"]:r["X-Amz-Date"]=this.getDateTime(),r["X-Amz-Algorithm"]="AWS4-HMAC-SHA256",r["X-Amz-Credential"]=this.credentials.accessKeyId+"/"+this.credentialString(),r["X-Amz-SignedHeaders"]=this.signedHeaders()):(t.doNotModifyHeaders||this.isCodeCommitGit||(!t.body||n["Content-Type"]||n["content-type"]||(n["Content-Type"]="application/x-www-form-urlencoded; charset=utf-8"),!t.body||n["Content-Length"]||n["content-length"]||(n["Content-Length"]=e.byteLength(t.body)),!this.credentials.sessionToken||n["X-Amz-Security-Token"]||n["x-amz-security-token"]||(n["X-Amz-Security-Token"]=this.credentials.sessionToken),"s3"!==this.service||n["X-Amz-Content-Sha256"]||n["x-amz-content-sha256"]||(n["X-Amz-Content-Sha256"]=c(this.request.body||"","hex")),n["X-Amz-Date"]||n["x-amz-date"]?this.datetime=n["X-Amz-Date"]||n["x-amz-date"]:n["X-Amz-Date"]=this.getDateTime()),delete n.Authorization,delete n.authorization)},f.prototype.sign=function(){return this.parsedPath||this.prepareRequest(),this.request.signQuery?this.parsedPath.query["X-Amz-Signature"]=this.signature():this.request.headers.Authorization=this.authHeader(),this.request.path=this.formatPath(),this.request},f.prototype.getDateTime=function(){if(!this.datetime){var e=this.request.headers,t=new Date(e.Date||e.date||new Date);this.datetime=t.toISOString().replace(/[:\-]|\.\d{3}/g,""),this.isCodeCommitGit&&(this.datetime=this.datetime.slice(0,-1))}return this.datetime},f.prototype.getDate=function(){return this.getDateTime().substr(0,8)},f.prototype.authHeader=function(){return["AWS4-HMAC-SHA256 Credential="+this.credentials.accessKeyId+"/"+this.credentialString(),"SignedHeaders="+this.signedHeaders(),"Signature="+this.signature()].join(", ")},f.prototype.signature=function(){var e=this.getDate(),t=[this.credentials.secretAccessKey,e,this.region,this.service].join(),n,r,i,o=l.get(t);return o||(n=u("AWS4"+this.credentials.secretAccessKey,e),r=u(n,this.region),i=u(r,this.service),o=u(i,"aws4_request"),l.set(t,o)),u(o,this.stringToSign(),"hex")},f.prototype.stringToSign=function(){return["AWS4-HMAC-SHA256",this.getDateTime(),this.credentialString(),c(this.canonicalString(),"hex")].join("\n")},f.prototype.canonicalString=function(){this.parsedPath||this.prepareRequest();var e=this.parsedPath.path,t=this.parsedPath.query,n=this.request.headers,r="",i="s3"!==this.service,s="s3"===this.service||this.request.doNotEncodePath,a="s3"===this.service,l="s3"===this.service,u;return u="s3"===this.service&&this.request.signQuery?"UNSIGNED-PAYLOAD":this.isCodeCommitGit?"":n["X-Amz-Content-Sha256"]||n["x-amz-content-sha256"]||c(this.request.body||"","hex"),t&&(r=h(o.stringify(Object.keys(t).sort().reduce(function(e,n){return n?(e[n]=Array.isArray(t[n])?l?t[n][0]:t[n].slice().sort():t[n],e):e},{})))),"/"!==e&&(i&&(e=e.replace(/\/{2,}/g,"/")),e=e.split("/").reduce(function(e,t){return i&&".."===t?e.pop():i&&"."===t||(s&&(t=decodeURIComponent(t)),e.push(h(encodeURIComponent(t)))),e},[]).join("/"),"/"!==e[0]&&(e="/"+e),a&&(e=e.replace(/%2F/g,"/"))),[this.request.method||"GET",e,r,this.canonicalHeaders()+"\n",this.signedHeaders(),u].join("\n")},f.prototype.canonicalHeaders=function(){var e=this.request.headers;function t(e){return e.toString().trim().replace(/\s+/g," ")}return Object.keys(e).sort(function(e,t){return e.toLowerCase()<t.toLowerCase()?-1:1}).map(function(n){return n.toLowerCase()+":"+t(e[n])}).join("\n")},f.prototype.signedHeaders=function(){return Object.keys(this.request.headers).map(function(e){return e.toLowerCase()}).sort().join(";")},f.prototype.credentialString=function(){return[this.getDate(),this.region,this.service,"aws4_request"].join("/")},f.prototype.defaultCredentials=function(){var e=process.env;return{accessKeyId:e.AWS_ACCESS_KEY_ID||e.AWS_ACCESS_KEY,secretAccessKey:e.AWS_SECRET_ACCESS_KEY||e.AWS_SECRET_KEY,sessionToken:e.AWS_SESSION_TOKEN}},f.prototype.parsePath=function(){var e=this.request.path||"/",t=e.indexOf("?"),n=null;t>=0&&(n=o.parse(e.slice(t+1)),e=e.slice(0,t)),/[^0-9A-Za-z!'()*\-._~%/]/.test(e)&&(e=e.split("/").map(function(e){return encodeURIComponent(decodeURIComponent(e))}).join("/")),this.parsedPath={path:e,query:n}},f.prototype.formatPath=function(){var e=this.parsedPath.path,t=this.parsedPath.query;return t?(null!=t[""]&&delete t[""],e+"?"+h(o.stringify(t))):e},r.RequestSigner=f,r.sign=function(e,t){return new f(e,t).sign()}}).call(this,n(0).Buffer)},function(e,t){function n(e){this.capacity=0|e,this.map=Object.create(null),this.list=new r}function r(){this.firstNode=null,this.lastNode=null}function i(e,t){this.key=e,this.val=t,this.prev=null,this.next=null}e.exports=function(e){return new n(e)},n.prototype.get=function(e){var t=this.map[e];if(null!=t)return this.used(t),t.val},n.prototype.set=function(e,t){var n=this.map[e];if(null!=n)n.val=t;else{if(this.capacity||this.prune(),!this.capacity)return!1;n=new i(e,t),this.map[e]=n,this.capacity--}return this.used(n),!0},n.prototype.used=function(e){this.list.moveToFront(e)},n.prototype.prune=function(){var e=this.list.pop();null!=e&&(delete this.map[e.key],this.capacity++)},r.prototype.moveToFront=function(e){this.firstNode!=e&&(this.remove(e),null==this.firstNode?(this.firstNode=e,this.lastNode=e,e.prev=null,e.next=null):(e.prev=null,e.next=this.firstNode,e.next.prev=e,this.firstNode=e))},r.prototype.pop=function(){var e=this.lastNode;return null!=e&&this.remove(e),e},r.prototype.remove=function(e){this.firstNode==e?this.firstNode=e.next:null!=e.prev&&(e.prev.next=e.next),this.lastNode==e?this.lastNode=e.prev:null!=e.next&&(e.next.prev=e.prev)}},function(e,t,n){var r=n(1651),i=n(1660),o=n(1666),s=n(236);e.exports={parse:r.parseRequest,parseRequest:r.parseRequest,sign:i.signRequest,signRequest:i.signRequest,createSigner:i.createSigner,isSigner:i.isSigner,sshKeyToPEM:s.sshKeyToPEM,sshKeyFingerprint:s.fingerprint,pemToRsaSSHKey:s.pemToRsaSSHKey,verify:o.verifySignature,verifySignature:o.verifySignature,verifyHMAC:o.verifyHMAC}},function(e,t,n){var r=n(25),i=n(14),o=n(236),s=o.HASH_ALGOS,a=o.PK_ALGOS,l=o.HttpSignatureError,u=o.InvalidAlgorithmError,c=o.validateAlgorithm,h=0,f=1,p=0,d=1,m=2,g=3;function y(e){l.call(this,e,y)}function v(e){l.call(this,e,v)}function b(e){l.call(this,e,b)}function _(e){l.call(this,e,_)}function w(e){l.call(this,e,w)}i.inherits(y,l),i.inherits(v,l),i.inherits(b,l),i.inherits(_,l),i.inherits(w,l),e.exports={parseRequest:function e(t,n){r.object(t,"request"),r.object(t.headers,"request.headers"),void 0===n&&(n={}),void 0===n.headers&&(n.headers=[t.headers["x-date"]?"x-date":"date"]),r.object(n,"options"),r.arrayOfString(n.headers,"options.headers"),r.optionalFinite(n.clockSkew,"options.clockSkew");var i=n.authorizationHeaderName||"authorization";if(!t.headers[i])throw new _("no "+i+" header present in the request");n.clockSkew=n.clockSkew||300;var o=0,s=h,a=p,l="",k="",E={scheme:"",params:{},signingString:""},S=t.headers[i],x;for(o=0;o<S.length;o++){var C=S.charAt(o);switch(Number(s)){case h:" "!==C?E.scheme+=C:s=f;break;case f:switch(Number(a)){case p:var A=C.charCodeAt(0);if(A>=65&&A<=90||A>=97&&A<=122)l+=C;else{if("="!==C)throw new v("bad param format");if(0===l.length)throw new v("bad param format");a=d}break;case d:if('"'!==C)throw new v("bad param format");k="",a=m;break;case m:'"'===C?(E.params[l]=k,a=g):k+=C;break;case g:if(","!==C)throw new v("bad param format");l="",a=p;break;default:throw new Error("Invalid substate")}break;default:throw new Error("Invalid substate")}}if(E.params.headers&&""!==E.params.headers?E.params.headers=E.params.headers.split(" "):t.headers["x-date"]?E.params.headers=["x-date"]:E.params.headers=["date"],!E.scheme||"Signature"!==E.scheme)throw new v('scheme was not "Signature"');if(!E.params.keyId)throw new v("keyId was not specified");if(!E.params.algorithm)throw new v("algorithm was not specified");if(!E.params.signature)throw new v("signature was not specified");E.params.algorithm=E.params.algorithm.toLowerCase();try{c(E.params.algorithm)}catch(e){throw e instanceof u?new b(E.params.algorithm+" is not supported"):e}for(o=0;o<E.params.headers.length;o++){var T=E.params.headers[o].toLowerCase();if(E.params.headers[o]=T,"request-line"===T){if(n.strict)throw new w("request-line is not a valid header with strict parsing enabled.");E.signingString+=t.method+" "+t.url+" HTTP/"+t.httpVersion}else if("(request-target)"===T)E.signingString+="(request-target): "+t.method.toLowerCase()+" "+t.url;else{var I=t.headers[T];if(void 0===I)throw new _(T+" was not in the request");E.signingString+=T+": "+I}o+1<E.params.headers.length&&(E.signingString+="\n")}if(t.headers.date||t.headers["x-date"]){x=t.headers["x-date"]?new Date(t.headers["x-date"]):new Date(t.headers.date);var j=new Date,R=Math.abs(j.getTime()-x.getTime());if(R>1e3*n.clockSkew)throw new y("clock skew of "+R/1e3+"s was greater than "+n.clockSkew+"s")}if(n.headers.forEach(function(e){if(E.params.headers.indexOf(e.toLowerCase())<0)throw new _(e+" was not a signed header")}),n.algorithms&&-1===n.algorithms.indexOf(E.params.algorithm))throw new b(E.params.algorithm+" is not a supported algorithm");return E.algorithm=E.params.algorithm.toUpperCase(),E.keyId=E.params.keyId,E}}},function(e,t,n){var r=n(315),i=n(316),o=n(1653),s=n(1654);for(var a in e.exports={Reader:o,Writer:s},i)i.hasOwnProperty(a)&&(e.exports[a]=i[a]);for(var l in r)r.hasOwnProperty(l)&&(e.exports[l]=r[l])},function(e,t,n){var r=n(24),i=n(29).Buffer,o=n(316),s=n(315),a=s.newInvalidAsn1Error;function l(e){if(!e||!i.isBuffer(e))throw new TypeError("data must be a node Buffer");this._buf=e,this._size=e.length,this._len=0,this._offset=0}Object.defineProperty(l.prototype,"length",{enumerable:!0,get:function(){return this._len}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){return this._offset}}),Object.defineProperty(l.prototype,"remain",{get:function(){return this._size-this._offset}}),Object.defineProperty(l.prototype,"buffer",{get:function(){return this._buf.slice(this._offset)}}),l.prototype.readByte=function(e){if(this._size-this._offset<1)return null;var t=255&this._buf[this._offset];return e||(this._offset+=1),t},l.prototype.peek=function(){return this.readByte(!0)},l.prototype.readLength=function(e){if(void 0===e&&(e=this._offset),e>=this._size)return null;var t=255&this._buf[e++];if(null===t)return null;if(128==(128&t)){if(t&=127,0===t)throw a("Indefinite length not supported");if(t>4)throw a("encoding too long");if(this._size-e<t)return null;this._len=0;for(var n=0;n<t;n++)this._len=(this._len<<8)+(255&this._buf[e++])}else this._len=t;return e},l.prototype.readSequence=function(e){var t=this.peek();if(null===t)return null;if(void 0!==e&&e!==t)throw a("Expected 0x"+e.toString(16)+": got 0x"+t.toString(16));var n=this.readLength(this._offset+1);return null===n?null:(this._offset=n,t)},l.prototype.readInt=function(){return this._readTag(o.Integer)},l.prototype.readBoolean=function(){return 0!==this._readTag(o.Boolean)},l.prototype.readEnumeration=function(){return this._readTag(o.Enumeration)},l.prototype.readString=function(e,t){e||(e=o.OctetString);var n=this.peek();if(null===n)return null;if(n!==e)throw a("Expected 0x"+e.toString(16)+": got 0x"+n.toString(16));var r=this.readLength(this._offset+1);if(null===r)return null;if(this.length>this._size-r)return null;if(this._offset=r,0===this.length)return t?i.alloc(0):"";var s=this._buf.slice(this._offset,this._offset+this.length);return this._offset+=this.length,t?s:s.toString("utf8")},l.prototype.readOID=function(e){e||(e=o.OID);var t=this.readString(e,!0);if(null===t)return null;for(var n=[],r=0,i=0;i<t.length;i++){var s=255&t[i];r<<=7,r+=127&s,0==(128&s)&&(n.push(r),r=0)}return r=n.shift(),n.unshift(r%40),n.unshift(r/40>>0),n.join(".")},l.prototype._readTag=function(e){r.ok(void 0!==e);var t=this.peek();if(null===t)return null;if(t!==e)throw a("Expected 0x"+e.toString(16)+": got 0x"+t.toString(16));var n=this.readLength(this._offset+1);if(null===n)return null;if(this.length>4)throw a("Integer too long: "+this.length);if(this.length>this._size-n)return null;this._offset=n;for(var i=this._buf[this._offset],o=0,s=0;s<this.length;s++)o<<=8,o|=255&this._buf[this._offset++];return 128==(128&i)&&4!==s&&(o-=1<<8*s),o>>0},e.exports=l},function(e,t,n){var r=n(24),i=n(29).Buffer,o=n(316),s=n(315),a=s.newInvalidAsn1Error,l={size:1024,growthFactor:8};function u(e,t){r.ok(e),r.equal(typeof e,"object"),r.ok(t),r.equal(typeof t,"object");var n=Object.getOwnPropertyNames(e);return n.forEach(function(n){if(!t[n]){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r)}}),t}function c(e){e=u(l,e||{}),this._buf=i.alloc(e.size||1024),this._size=this._buf.length,this._offset=0,this._options=e,this._seq=[]}Object.defineProperty(c.prototype,"buffer",{get:function(){if(this._seq.length)throw a(this._seq.length+" unended sequence(s)");return this._buf.slice(0,this._offset)}}),c.prototype.writeByte=function(e){if("number"!=typeof e)throw new TypeError("argument must be a Number");this._ensure(1),this._buf[this._offset++]=e},c.prototype.writeInt=function(e,t){if("number"!=typeof e)throw new TypeError("argument must be a Number");"number"!=typeof t&&(t=o.Integer);for(var n=4;(0==(4286578688&e)||-8388608==(4286578688&e))&&n>1;)n--,e<<=8;if(n>4)throw a("BER ints cannot be > 0xffffffff");for(this._ensure(2+n),this._buf[this._offset++]=t,this._buf[this._offset++]=n;n-- >0;)this._buf[this._offset++]=(4278190080&e)>>>24,e<<=8},c.prototype.writeNull=function(){this.writeByte(o.Null),this.writeByte(0)},c.prototype.writeEnumeration=function(e,t){if("number"!=typeof e)throw new TypeError("argument must be a Number");return"number"!=typeof t&&(t=o.Enumeration),this.writeInt(e,t)},c.prototype.writeBoolean=function(e,t){if("boolean"!=typeof e)throw new TypeError("argument must be a Boolean");"number"!=typeof t&&(t=o.Boolean),this._ensure(3),this._buf[this._offset++]=t,this._buf[this._offset++]=1,this._buf[this._offset++]=e?255:0},c.prototype.writeString=function(e,t){if("string"!=typeof e)throw new TypeError("argument must be a string (was: "+typeof e+")");"number"!=typeof t&&(t=o.OctetString);var n=i.byteLength(e);this.writeByte(t),this.writeLength(n),n&&(this._ensure(n),this._buf.write(e,this._offset),this._offset+=n)},c.prototype.writeBuffer=function(e,t){if("number"!=typeof t)throw new TypeError("tag must be a number");if(!i.isBuffer(e))throw new TypeError("argument must be a buffer");this.writeByte(t),this.writeLength(e.length),this._ensure(e.length),e.copy(this._buf,this._offset,0,e.length),this._offset+=e.length},c.prototype.writeStringArray=function(e){if(!e instanceof Array)throw new TypeError("argument must be an Array[String]");var t=this;e.forEach(function(e){t.writeString(e)})},c.prototype.writeOID=function(e,t){if("string"!=typeof e)throw new TypeError("argument must be a string");if("number"!=typeof t&&(t=o.OID),!/^([0-9]+\.){3,}[0-9]+$/.test(e))throw new Error("argument is not a valid OID string");function n(e,t){t<128?e.push(t):t<16384?(e.push(t>>>7|128),e.push(127&t)):t<2097152?(e.push(t>>>14|128),e.push(255&(t>>>7|128)),e.push(127&t)):t<268435456?(e.push(t>>>21|128),e.push(255&(t>>>14|128)),e.push(255&(t>>>7|128)),e.push(127&t)):(e.push(255&(t>>>28|128)),e.push(255&(t>>>21|128)),e.push(255&(t>>>14|128)),e.push(255&(t>>>7|128)),e.push(127&t))}var r=e.split("."),i=[];i.push(40*parseInt(r[0],10)+parseInt(r[1],10)),r.slice(2).forEach(function(e){n(i,parseInt(e,10))});var s=this;this._ensure(2+i.length),this.writeByte(t),this.writeLength(i.length),i.forEach(function(e){s.writeByte(e)})},c.prototype.writeLength=function(e){if("number"!=typeof e)throw new TypeError("argument must be a Number");if(this._ensure(4),e<=127)this._buf[this._offset++]=e;else if(e<=255)this._buf[this._offset++]=129,this._buf[this._offset++]=e;else if(e<=65535)this._buf[this._offset++]=130,this._buf[this._offset++]=e>>8,this._buf[this._offset++]=e;else{if(!(e<=16777215))throw a("Length too long (> 4 bytes)");this._buf[this._offset++]=131,this._buf[this._offset++]=e>>16,this._buf[this._offset++]=e>>8,this._buf[this._offset++]=e}},c.prototype.startSequence=function(e){"number"!=typeof e&&(e=o.Sequence|o.Constructor),this.writeByte(e),this._seq.push(this._offset),this._ensure(3),this._offset+=3},c.prototype.endSequence=function(){var e=this._seq.pop(),t=e+3,n=this._offset-t;if(n<=127)this._shift(t,n,-2),this._buf[e]=n;else if(n<=255)this._shift(t,n,-1),this._buf[e]=129,this._buf[e+1]=n;else if(n<=65535)this._buf[e]=130,this._buf[e+1]=n>>8,this._buf[e+2]=n;else{if(!(n<=16777215))throw a("Sequence too long");this._shift(t,n,1),this._buf[e]=131,this._buf[e+1]=n>>16,this._buf[e+2]=n>>8,this._buf[e+3]=n}},c.prototype._shift=function(e,t,n){r.ok(void 0!==e),r.ok(void 0!==t),r.ok(n),this._buf.copy(this._buf,e+n,e,e+t),this._offset+=n},c.prototype._ensure=function(e){if(r.ok(e),this._size-this._offset<e){var t=this._size*this._options.growthFactor;t-this._offset<e&&(t+=e);var n=i.alloc(t);this._buf.copy(n,0,0,this._offset),this._buf=n,this._size=t}},e.exports=c},function(e,t){},function(e,t,n){var r=n(16),i=n(173).BigInteger,o=n(237).ECPointFp,s=n(29).Buffer;function a(e,t){return e.length>=t?e:a("0"+e,t)}t.ECCurves=n(1657),t.ECKey=function(e,t,n){var o,l=e(),u=l.getN(),c=Math.floor(u.bitLength()/8);if(t)if(n){var e=l.getCurve();this.P=e.decodePointHex(t.toString("hex"))}else{if(t.length!=c)return!1;o=new i(t.toString("hex"),16)}else{var h=u.subtract(i.ONE),f=new i(r.randomBytes(u.bitLength()));o=f.mod(h).add(i.ONE),this.P=l.getG().multiply(o)}this.P&&(this.PublicKey=s.from(l.getCurve().encodeCompressedPointHex(this.P),"hex")),o&&(this.PrivateKey=s.from(a(o.toString(16),2*c),"hex"),this.deriveSharedSecret=function(e){if(!e||!e.P)return!1;var t=e.P.multiply(o);return s.from(a(t.getX().toBigInteger().toString(16),2*c),"hex")})}},function(e,t,n){var r=n(173).BigInteger,i=n(237).ECCurveFp;function o(e,t,n,r){this.curve=e,this.g=t,this.n=n,this.h=r}function s(){return this.curve}function a(){return this.g}function l(){return this.n}function u(){return this.h}function c(e){return new r(e,16)}function h(){var e=c("FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFF"),t=c("FFFFFFFDFFFFFFFFFFFFFFFFFFFFFFFC"),n=c("E87579C11079F43DD824993C2CEE5ED3"),s=c("FFFFFFFE0000000075A30D1B9038A115"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("04161FF7528B899B2D0C28607CA52C5B86CF5AC8395BAFEB13C02DA292DDED7A83");return new o(l,u,s,a)}function f(){var e=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73"),t=r.ZERO,n=c("7"),s=c("0100000000000000000001B8FA16DFAB9ACA16B6B3"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("043B4C382CE37AA192A4019E763036F4F5DD4D7EBB938CF935318FDCED6BC28286531733C3F03C4FEE");return new o(l,u,s,a)}function p(){var e=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFF"),t=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF7FFFFFFC"),n=c("1C97BEFC54BD7A8B65ACF89F81D4D4ADC565FA45"),s=c("0100000000000000000001F4C8F927AED3CA752257"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("044A96B5688EF573284664698968C38BB913CBFC8223A628553168947D59DCC912042351377AC5FB32");return new o(l,u,s,a)}function d(){var e=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37"),t=r.ZERO,n=c("3"),s=c("FFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("04DB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D");return new o(l,u,s,a)}function m(){var e=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFF"),t=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFC"),n=c("64210519E59C80E70FA7E9AB72243049FEB8DEECC146B9B1"),s=c("FFFFFFFFFFFFFFFFFFFFFFFF99DEF836146BC9B1B4D22831"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("04188DA80EB03090F67CBF20EB43A18800F4FF0AFD82FF101207192B95FFC8DA78631011ED6B24CDD573F977A11E794811");return new o(l,u,s,a)}function g(){var e=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF000000000000000000000001"),t=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFFFFFFFFFFFFFFFFFFFE"),n=c("B4050A850C04B3ABF54132565044B0B7D7BFD8BA270B39432355FFB4"),s=c("FFFFFFFFFFFFFFFFFFFFFFFFFFFF16A2E0B8F03E13DD29455C5C2A3D"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("04B70E0CBD6BB4BF7F321390B94A03C1D356C21122343280D6115C1D21BD376388B5F723FB4C22DFE6CD4375A05A07476444D5819985007E34");return new o(l,u,s,a)}function y(){var e=c("FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFF"),t=c("FFFFFFFF00000001000000000000000000000000FFFFFFFFFFFFFFFFFFFFFFFC"),n=c("5AC635D8AA3A93E7B3EBBD55769886BC651D06B0CC53B0F63BCE3C3E27D2604B"),s=c("FFFFFFFF00000000FFFFFFFFFFFFFFFFBCE6FAADA7179E84F3B9CAC2FC632551"),a=r.ONE,l=new i(e,t,n),u=l.decodePointHex("046B17D1F2E12C4247F8BCE6E563A440F277037D812DEB33A0F4A13945D898C2964FE342E2FE1A7F9B8EE7EB4A7C0F9E162BCE33576B315ECECBB6406837BF51F5");return new o(l,u,s,a)}function v(e){return"secp128r1"==e?h():"secp160k1"==e?f():"secp160r1"==e?p():"secp192k1"==e?d():"secp192r1"==e?m():"secp224r1"==e?g():"secp256r1"==e?y():null}o.prototype.getCurve=s,o.prototype.getG=a,o.prototype.getN=l,o.prototype.getH=u,e.exports={secp128r1:h,secp160k1:f,secp160r1:p,secp192k1:d,secp192r1:m,secp224r1:g,secp256r1:y}},function(e,t,n){e.exports={read:v,verify:m,sign:k,signAsync:E,write:S,fromBuffer:b,toBuffer:x};var r=n(25),i=n(175),o=n(16),s=n(29).Buffer,a=n(48),l=n(41),u=n(46),c=n(178),h=n(93),f=n(83),p=n(42),d=n(177);function m(e,t){return!1}var g={user:1,host:2};Object.keys(g).forEach(function(e){g[g[e]]=e});var y=/^ecdsa-sha2-([^@-]+)-cert-v01@openssh.com$/;function v(e,t){s.isBuffer(e)&&(e=e.toString("ascii"));var n=e.trim().split(/[ \t\n]+/g);if(n.length<2||n.length>3)throw new Error("Not a valid SSH certificate line");var r=n[0],i=n[1];return i=s.from(i,"base64"),b(i,r)}function b(e,t,n){var o=new i({buffer:e}),s=o.readString();if(void 0!==t&&s!==t)throw new Error("SSH certificate algorithm mismatch");void 0===t&&(t=s);var u={signatures:{}};u.signatures.openssh={},u.signatures.openssh.nonce=o.readBuffer();var m={},v=m.parts=[];m.type=C(t);for(var b=a.info[m.type].parts.length;v.length<b;)v.push(o.readPart());r.ok(v.length>=1,"key must have at least one part");var w=a.info[m.type];if("ecdsa"===m.type){var k=y.exec(t);r.ok(null!==k),r.strictEqual(k[1],v[0].data.toString())}for(var E=0;E<w.parts.length;++E)if(v[E].name=w.parts[E],"curve"!==v[E].name&&!1!==w.normalize){var S=v[E];S.data=p.mpNormalize(S.data)}u.subjectKey=new l(m),u.serial=o.readInt64();var x=g[o.readInt()];r.string(x,"valid cert type"),u.signatures.openssh.keyId=o.readString();for(var A=[],T=o.readBuffer(),I=new i({buffer:T});!I.atEnd();)A.push(I.readString());0===A.length&&(A=["*"]),u.subjects=A.map(function(e){if("user"===x)return c.forUser(e);if("host"===x)return c.forHost(e);throw new Error("Unknown identity type "+x)}),u.validFrom=_(o.readInt64()),u.validUntil=_(o.readInt64());for(var j=[],R=new i({buffer:o.readBuffer()}),B;!R.atEnd();)B={critical:!0},B.name=R.readString(),B.data=R.readBuffer(),j.push(B);for(R=new i({buffer:o.readBuffer()});!R.atEnd();)B={critical:!1},B.name=R.readString(),B.data=R.readBuffer(),j.push(B);u.signatures.openssh.exts=j,o.readBuffer();var O=o.readBuffer();u.issuerKey=h.read(O),u.issuer=c.forHost("**");var P=o.readBuffer();return u.signatures.openssh.signature=f.parse(P,u.issuerKey.type,"ssh"),void 0!==n&&(n.remainder=o.remainder(),n.consumed=o._offset),new d(u)}function _(e){var t=4294967296*e.readUInt32BE(0);t+=e.readUInt32BE(4);var n=new Date;return n.setTime(1e3*t),n.sourceInt64=e,n}function w(e){if(void 0!==e.sourceInt64)return e.sourceInt64;var t=Math.round(e.getTime()/1e3),n=Math.floor(t/4294967296),r=Math.floor(t%4294967296),i=s.alloc(8);return i.writeUInt32BE(n,0),i.writeUInt32BE(r,4),i}function k(e,t){void 0===e.signatures.openssh&&(e.signatures.openssh={});try{var n=x(e,!0)}catch(t){return delete e.signatures.openssh,!1}var r=e.signatures.openssh,i=void 0;"rsa"!==t.type&&"dsa"!==t.type||(i="sha1");var o=t.createSign(i);return o.write(n),r.signature=o.sign(),!0}function E(e,t,n){void 0===e.signatures.openssh&&(e.signatures.openssh={});try{var r=x(e,!0)}catch(t){return delete e.signatures.openssh,void n(t)}var i=e.signatures.openssh;t(r,function(e,t){if(e)n(e);else{try{t.toBuffer("ssh")}catch(e){return void n(e)}i.signature=t,n()}})}function S(e,t){void 0===t&&(t={});var n=x(e),r=A(e.subjectKey)+" "+n.toString("base64");return t.comment&&(r=r+" "+t.comment),r}function x(e,t){r.object(e.signatures.openssh,"signature for openssh format");var n=e.signatures.openssh;void 0===n.nonce&&(n.nonce=o.randomBytes(16));var l=new i({});l.writeString(A(e.subjectKey)),l.writeBuffer(n.nonce);var u=e.subjectKey,c=a.info[u.type];c.parts.forEach(function(e){l.writePart(u.part[e])}),l.writeInt64(e.serial);var f=e.subjects[0].type;r.notStrictEqual(f,"unknown"),e.subjects.forEach(function(e){r.strictEqual(e.type,f)}),f=g[f],l.writeInt(f),void 0===n.keyId&&(n.keyId=e.subjects[0].type+"_"+(e.subjects[0].uid||e.subjects[0].hostname)),l.writeString(n.keyId);var p=new i({});e.subjects.forEach(function(e){f===g.host?p.writeString(e.hostname):f===g.user&&p.writeString(e.uid)}),l.writeBuffer(p.toBuffer()),l.writeInt64(w(e.validFrom)),l.writeInt64(w(e.validUntil));var d=n.exts;void 0===d&&(d=[]);var m=new i({});return d.forEach(function(e){!0===e.critical&&(m.writeString(e.name),m.writeBuffer(e.data))}),l.writeBuffer(m.toBuffer()),m=new i({}),d.forEach(function(e){!0!==e.critical&&(m.writeString(e.name),m.writeBuffer(e.data))}),l.writeBuffer(m.toBuffer()),l.writeBuffer(s.alloc(0)),p=h.write(e.issuerKey),l.writeBuffer(p),t||l.writeBuffer(n.signature.toBuffer("ssh")),l.toBuffer()}function C(e){if("ssh-rsa-cert-v01@openssh.com"===e)return"rsa";if("ssh-dss-cert-v01@openssh.com"===e)return"dsa";if(e.match(y))return"ecdsa";if("ssh-ed25519-cert-v01@openssh.com"===e)return"ed25519";throw new Error("Unsupported cert type "+e)}function A(e){if("rsa"===e.type)return"ssh-rsa-cert-v01@openssh.com";if("dsa"===e.type)return"ssh-dss-cert-v01@openssh.com";if("ecdsa"===e.type)return"ecdsa-sha2-"+e.curve+"-cert-v01@openssh.com";if("ed25519"===e.type)return"ssh-ed25519-cert-v01@openssh.com";throw new Error("Unsupported key type "+e.type)}},function(e,t,n){var r=n(619);e.exports={read:m,verify:r.verify,sign:r.sign,write:g};var i=n(25),o=n(84),s=n(29).Buffer,a=n(48),l=n(42),u=n(41),c=n(46),h=n(92),f=n(178),p=n(83),d=n(177);function m(e,t){"string"!=typeof e&&(i.buffer(e,"buf"),e=e.toString("ascii"));for(var n=e.trim().split(/[\r\n]+/g),o,a=-1,l;!o&&a<n.length;)o=n[++a].match(/[-]+[ ]*BEGIN CERTIFICATE[ ]*[-]+/);i.ok(o,"invalid PEM header");for(var u=n.length;!l&&u>0;)l=n[--u].match(/[-]+[ ]*END CERTIFICATE[ ]*[-]+/);i.ok(l,"invalid PEM footer"),n=n.slice(a,u+1);for(var c={};n=n.slice(1),o=n[0].match(/^([A-Za-z0-9-]+): (.+)$/),o;)c[o[1].toLowerCase()]=o[2];return n=n.slice(0,-1).join(""),e=s.from(n,"base64"),r.read(e,t)}function g(e,t){var n=r.write(e,t),i="CERTIFICATE",o=n.toString("base64"),a=o.length+o.length/64+18+16+2*i.length+10,l=s.alloc(a),u=0;u+=l.write("-----BEGIN "+i+"-----\n",u);for(var c=0;c<o.length;){var h=c+64;h>o.length&&(h=o.length),u+=l.write(o.slice(c,h),u),l[u++]=10,c=h}return u+=l.write("-----END "+i+"-----\n",u),l.slice(0,u)}},function(e,t,n){(function(t){var r=n(25),i=n(16),o=n(131),s=n(14),a=n(314),l=n(1661),u=n(236),c=n(14).format,h=u.HASH_ALGOS,f=u.PK_ALGOS,p=u.InvalidAlgorithmError,d=u.HttpSignatureError,m=u.validateAlgorithm,g='Signature keyId="%s",algorithm="%s",headers="%s",signature="%s"';function y(e){d.call(this,e,y)}function v(e){d.call(this,e,v)}function b(e){r.object(e,"options");var n=[];if(void 0!==e.algorithm&&(r.string(e.algorithm,"options.algorithm"),n=m(e.algorithm)),this.rs_alg=n,void 0!==e.sign)r.func(e.sign,"options.sign"),this.rs_signFunc=e.sign;else if("hmac"===n[0]&&void 0!==e.key){if(r.string(e.keyId,"options.keyId"),this.rs_keyId=e.keyId,"string"!=typeof e.key&&!t.isBuffer(e.key))throw new TypeError("options.key for HMAC must be a string or Buffer");this.rs_signer=i.createHmac(n[1].toUpperCase(),e.key),this.rs_signer.sign=function(){var e=this.digest("base64");return{hashAlgorithm:n[1],toString:function(){return e}}}}else{if(void 0===e.key)throw new TypeError("options.sign (func) or options.key is required");var o=e.key;if(("string"==typeof o||t.isBuffer(o))&&(o=a.parsePrivateKey(o)),r.ok(a.PrivateKey.isPrivateKey(o,[1,2]),"options.key must be a sshpk.PrivateKey"),this.rs_key=o,r.string(e.keyId,"options.keyId"),this.rs_keyId=e.keyId,!f[o.type])throw new p(o.type.toUpperCase()+" type keys are not supported");if(void 0!==n[0]&&o.type!==n[0])throw new p("options.key must be a "+n[0].toUpperCase()+" key, was given a "+o.type.toUpperCase()+" key instead");this.rs_signer=o.createSign(n[1])}this.rs_headers=[],this.rs_lines=[]}s.inherits(y,d),s.inherits(v,d),b.prototype.writeHeader=function(e,t){if(r.string(e,"header"),e=e.toLowerCase(),r.string(t,"value"),this.rs_headers.push(e),this.rs_signFunc)this.rs_lines.push(e+": "+t);else{var n=e+": "+t;this.rs_headers.length>0&&(n="\n"+n),this.rs_signer.update(n)}return t},b.prototype.writeDateHeader=function(){return this.writeHeader("date",l.rfc1123(new Date))},b.prototype.writeTarget=function(e,t){r.string(e,"method"),r.string(t,"path"),e=e.toLowerCase(),this.writeHeader("(request-target)",e+" "+t)},b.prototype.sign=function(e){if(r.func(e,"callback"),this.rs_headers.length<1)throw new Error("At least one header must be signed");var t,n;if(this.rs_signFunc){var i=this.rs_lines.join("\n"),o=this;this.rs_signFunc(i,function(i,s){if(i)e(i);else{try{r.object(s,"signature"),r.string(s.keyId,"signature.keyId"),r.string(s.algorithm,"signature.algorithm"),r.string(s.signature,"signature.signature"),t=m(s.algorithm),n=c(g,s.keyId,s.algorithm,o.rs_headers.join(" "),s.signature)}catch(t){return void e(t)}e(null,n)}})}else{try{var s=this.rs_signer.sign()}catch(t){return void e(t)}t=(this.rs_alg[0]||this.rs_key.type)+"-"+s.hashAlgorithm;var a=s.toString();n=c(g,this.rs_keyId,t,this.rs_headers.join(" "),a),e(null,n)}},e.exports={isSigner:function(e){return"object"==typeof e&&e instanceof b},createSigner:function e(t){return new b(t)},signRequest:function e(n,o){r.object(n,"request"),r.object(o,"options"),r.optionalString(o.algorithm,"options.algorithm"),r.string(o.keyId,"options.keyId"),r.optionalArrayOfString(o.headers,"options.headers"),r.optionalString(o.httpVersion,"options.httpVersion"),n.getHeader("Date")||n.setHeader("Date",l.rfc1123(new Date)),o.headers||(o.headers=["date"]),o.httpVersion||(o.httpVersion="1.1");var s=[],u;o.algorithm&&(o.algorithm=o.algorithm.toLowerCase(),s=m(o.algorithm));var d="",b;for(u=0;u<o.headers.length;u++){if("string"!=typeof o.headers[u])throw new TypeError("options.headers must be an array of Strings");var _=o.headers[u].toLowerCase();if("request-line"===_){if(o.strict)throw new v("request-line is not a valid header with strict parsing enabled.");d+=n.method+" "+n.path+" HTTP/"+o.httpVersion}else if("(request-target)"===_)d+="(request-target): "+n.method.toLowerCase()+" "+n.path;else{var w=n.getHeader(_);if(void 0===w||""===w)throw new y(_+" was not in the request");d+=_+": "+w}u+1<o.headers.length&&(d+="\n")}if(n.hasOwnProperty("_stringToSign")&&(n._stringToSign=d),"hmac"===s[0]){if("string"!=typeof o.key&&!t.isBuffer(o.key))throw new TypeError("options.key must be a string or Buffer");var k=i.createHmac(s[1].toUpperCase(),o.key);k.update(d),b=k.digest("base64")}else{var E=o.key;if(("string"==typeof E||t.isBuffer(E))&&(E=a.parsePrivateKey(o.key)),r.ok(a.PrivateKey.isPrivateKey(E,[1,2]),"options.key must be a sshpk.PrivateKey"),!f[E.type])throw new p(E.type.toUpperCase()+" type keys are not supported");if(void 0!==s[0]&&E.type!==s[0])throw new p("options.key must be a "+s[0].toUpperCase()+" key, was given a "+E.type.toUpperCase()+" key instead");var S=E.createSign(s[1]);S.update(d);var x=S.sign();if(!h[x.hashAlgorithm])throw new p(x.hashAlgorithm.toUpperCase()+" is not a supported hash algorithm");o.algorithm=E.type+"-"+x.hashAlgorithm,b=x.toString(),r.notStrictEqual(b,"","empty signature produced")}var C=o.authorizationHeaderName||"Authorization";return n.setHeader(C,c(g,o.keyId,o.algorithm,o.headers.join(" "),b)),!0}}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(25),i=n(14),o=n(1662),s=n(1663),a=n(1665);function l(e){var t,n,r="__deepCopy";if(e&&e[r])throw new Error("attempted deep copy of cyclic object");if(e&&e.constructor==Object){for(n in t={},e[r]=!0,e)n!=r&&(t[n]=l(e[n]));return delete e[r],t}if(e&&e.constructor==Array){for(t=[],e[r]=!0,n=0;n<e.length;n++)t.push(l(e[n]));return delete e[r],t}return e}function u(e,t){if(typeof e!=typeof t)return!1;if(null===e||null===t||"object"!=typeof e)return e===t;if(e.constructor!=t.constructor)return!1;var n;for(n in e){if(!t.hasOwnProperty(n))return!1;if(!u(e[n],t[n]))return!1}for(n in t)if(!e.hasOwnProperty(n))return!1;return!0}function c(e){var t;for(t in e)return!1;return!0}function h(e,t){return r.equal(typeof t,"string"),Object.prototype.hasOwnProperty.call(e,t)}function f(e,t){for(var n in e)h(e,n)&&t(n,e[n])}function p(e,t){return r.equal(typeof t,"string"),d(e,t)}function d(e,t){if(null!==e&&"object"==typeof e){if(e.hasOwnProperty(t))return e[t];var n=t.indexOf(".");if(-1!=n){var r=t.substr(0,n);if(e.hasOwnProperty(r))return d(e[r],t.substr(n+1))}}}function m(e,t,n){g(e,t,[],n)}function g(e,t,n,i){var o,s;if(0===t)return o=n.slice(0),o.push(e),void i(o);for(s in r.ok(null!==e),r.equal(typeof e,"object"),r.equal(typeof t,"number"),r.ok(t>=0),e)o=n.slice(0),o.push(s),g(e[s],t-1,o,i)}function y(e,t){if(0===t)return[e];r.ok(null!==e),r.equal(typeof e,"object"),r.equal(typeof t,"number"),r.ok(t>=0);var n=[],i;for(i in e)y(e[i],t-1).forEach(function(e){n.push([i].concat(e))});return n}function v(e,t){return e.substr(0,t.length)==t}function b(e,t){return e.substr(e.length-t.length,t.length)==t}function _(e){return"number"==typeof e&&(e=new Date(e)),r.ok(e.constructor===Date),o.sprintf("%4d-%02d-%02dT%02d:%02d:%02d.%03dZ",e.getUTCFullYear(),e.getUTCMonth()+1,e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds(),e.getUTCMilliseconds())}t.deepCopy=l,t.deepEqual=u,t.isEmpty=c,t.hasKey=h,t.forEachKey=f,t.pluck=p,t.flattenObject=y,t.flattenIter=m,t.validateJsonObject=Y,t.validateJsonObjectJS=Y,t.randElt=Z,t.extraProperties=ie,t.mergeObjects=oe,t.startsWith=v,t.endsWith=b,t.parseInteger=V,t.iso8601=_,t.rfc1123=E,t.parseDateTime=S,t.hrtimediff=Q,t.hrtimeDiff=Q,t.hrtimeAccum=ne,t.hrtimeAdd=re,t.hrtimeNanosec=X,t.hrtimeMicrosec=ee,t.hrtimeMillisec=te;var w=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],k=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"];function E(e){return o.sprintf("%s, %02d %s %04d %02d:%02d:%02d GMT",k[e.getUTCDay()],e.getUTCDate(),w[e.getUTCMonth()],e.getUTCFullYear(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds())}function S(e){var t=+e;return isNaN(t)?new Date(e):new Date(t)}var x=Number.MAX_SAFE_INTEGER||9007199254740991,C=Number.MIN_SAFE_INTEGER||-9007199254740991,A={base:10,allowSign:!0,allowPrefix:!1,allowTrailing:!1,allowImprecise:!1,trimWhitespace:!1,leadingZeroIsOctal:!1},T=48,I=57,j=65,R=66,B=79,O=84,P=88,N=90,D=97,M=98,F=111,L=116,U=120,q=122,z=48,K=55,H=87;function V(e,t){r.string(e,"str"),r.optionalObject(t,"options");var n=!1,i=A,o;t&&(n=h(t,"base"),i=oe(i,t),r.number(i.base,"options.base"),r.ok(i.base>=2,"options.base >= 2"),r.ok(i.base<=36,"options.base <= 36"),r.bool(i.allowSign,"options.allowSign"),r.bool(i.allowPrefix,"options.allowPrefix"),r.bool(i.allowTrailing,"options.allowTrailing"),r.bool(i.allowImprecise,"options.allowImprecise"),r.bool(i.trimWhitespace,"options.trimWhitespace"),r.bool(i.leadingZeroIsOctal,"options.leadingZeroIsOctal"),i.leadingZeroIsOctal&&r.ok(!n,'"base" and "leadingZeroIsOctal" are mutually exclusive'));var s=-1,a=i.base,l,u=1,c=0,f=0,p=e.length;if(i.trimWhitespace)for(;f<p&&W(e.charCodeAt(f));)++f;for(i.allowSign&&("-"===e[f]?(f+=1,u=-1):"+"===e[f]&&(f+=1)),"0"===e[f]&&(i.allowPrefix&&(s=G(e.charCodeAt(f+1)),-1===s||n&&s!==a||(a=s,f+=2)),-1===s&&i.leadingZeroIsOctal&&(a=8)),l=f;f<p&&(o=$(e.charCodeAt(f)),-1!==o&&o<a);++f)c*=a,c+=o;if(l===f)return new Error("invalid number: "+JSON.stringify(e));if(i.trimWhitespace)for(;f<p&&W(e.charCodeAt(f));)++f;if(f<p&&!i.allowTrailing)return new Error("trailing characters after number: "+JSON.stringify(e.slice(f)));if(0===c)return 0;var d=c*u;return!i.allowImprecise&&(c>x||d<C)?new Error("number is outside of the supported range: "+JSON.stringify(e.slice(l,f))):d}function $(e){return e>=T&&e<=I?e-z:e>=j&&e<=N?e-K:e>=D&&e<=q?e-H:-1}function W(e){return 32===e||e>=9&&e<=13||160===e||5760===e||6158===e||e>=8192&&e<=8202||8232===e||8233===e||8239===e||8287===e||12288===e||65279===e}function G(e){return e===M||e===R?2:e===F||e===B?8:e===L||e===O?10:e===U||e===P?16:-1}function Y(e,t){var n=a.validate(t,e);if(0===n.errors.length)return null;var r=n.errors[0],i=r.property,o=r.message.toLowerCase(),l,u;-1!=(l=o.indexOf("the property "))&&-1!=(u=o.indexOf(" is not defined in the schema and the schema does not allow additional properties"))&&(l+="the property ".length,i=""===i?o.substr(l,u-l):i+"."+o.substr(l,u-l),o="unsupported property");var c=new s.VError('property "%s": %s',i,o);return c.jsv_details=r,c}function Z(e){return r.ok(Array.isArray(e)&&e.length>0,"randElt argument must be a non-empty array"),e[Math.floor(Math.random()*e.length)]}function J(e){r.ok(e[0]>=0&&e[1]>=0,"negative numbers not allowed in hrtimes"),r.ok(e[1]<1e9,"nanoseconds column overflow")}function Q(e,t){J(e),J(t),r.ok(e[0]>t[0]||e[0]==t[0]&&e[1]>=t[1],"negative differences not allowed");var n=[e[0]-t[0],0];return e[1]>=t[1]?n[1]=e[1]-t[1]:(n[0]--,n[1]=1e9-(t[1]-e[1])),n}function X(e){return J(e),Math.floor(1e9*e[0]+e[1])}function ee(e){return J(e),Math.floor(1e6*e[0]+e[1]/1e3)}function te(e){return J(e),Math.floor(1e3*e[0]+e[1]/1e6)}function ne(e,t){return J(e),J(t),e[1]+=t[1],e[1]>=1e9&&(e[0]++,e[1]-=1e9),e[0]+=t[0],e}function re(e,t){J(e);var n=[e[0],e[1]];return ne(n,t)}function ie(e,t){r.ok("object"==typeof e&&null!==e,"obj argument must be a non-null object"),r.ok(Array.isArray(t),"allowed argument must be an array of strings");for(var n=0;n<t.length;n++)r.ok("string"==typeof t[n],"allowed argument must be an array of strings");return Object.keys(e).filter(function(e){return-1===t.indexOf(e)})}function oe(e,t,n){var r,i;if(r={},n)for(i in n)r[i]=n[i];if(e)for(i in e)r[i]=e[i];if(t)for(i in t)r[i]=t[i];return r}},function(e,t,n){(function(e){var r=n(24),i=n(14);function o(e){var t=["([^%]*)","%","(['\\-+ #0]*?)","([1-9]\\d*)?","(\\.([1-9]\\d*))?","[lhjztL]*?","([diouxXfFeEgGaAcCsSp%jr])"].join(""),n=new RegExp(t),o=Array.prototype.slice.call(arguments,1),s,a,c,h,f,p,d,m,g,y="",v=1;for(r.equal("string",typeof e);null!==(g=n.exec(e));)if(y+=g[1],e=e.substring(g[0].length),s=g[2]||"",a=g[3]||0,c=g[4]||"",h=g[6],f=!1,d=!1,p=" ","%"!=h){if(0===o.length)throw new Error("too few args to sprintf");if(m=o.shift(),v++,s.match(/[\' #]/))throw new Error("unsupported flags: "+s);if(c.length>0)throw new Error("non-zero precision not supported");switch(s.match(/-/)&&(f=!0),s.match(/0/)&&(p="0"),s.match(/\+/)&&(d=!0),h){case"s":if(void 0===m||null===m)throw new Error("argument "+v+": attempted to print undefined or null as a string");y+=l(p,a,f,m.toString());break;case"d":m=Math.floor(m);case"f":d=d&&m>0?"+":"",y+=d+l(p,a,f,m.toString());break;case"x":y+=l(p,a,f,m.toString(16));break;case"j":0===a&&(a=10),y+=i.inspect(m,!1,a);break;case"r":y+=u(m);break;default:throw new Error("unsupported conversion: "+h)}}else y+="%";return y+=e,y}function s(){var t=Array.prototype.slice.call(arguments);t.unshift(e.stdout),a.apply(null,t)}function a(e){var t=Array.prototype.slice.call(arguments,1);return e.write(o.apply(this,t))}function l(e,t,n,r){for(var i=r;i.length<t;)n?i+=e:i=e+i;return i}function u(e){var t;if(!(e instanceof Error))throw new Error(o("invalid type for %%r: %j",e));if(t="EXCEPTION: "+e.constructor.name+": "+e.stack,e.cause&&"function"==typeof e.cause){var n=e.cause();n&&(t+="\nCaused by: "+u(n))}return t}t.sprintf=o,t.printf=s,t.fprintf=a}).call(this,n(3))},function(e,t,n){var r=n(25),i=n(14),o=n(1664),s=n(7).isError,a=o.sprintf;function l(e){var t,n,i,o,l;if(r.object(e,"args"),r.bool(e.strict,"args.strict"),r.array(e.argv,"args.argv"),t=e.argv,0===t.length)n={},i=[];else if(s(t[0]))n={cause:t[0]},i=t.slice(1);else if("object"==typeof t[0]){for(l in n={},t[0])n[l]=t[0][l];i=t.slice(1)}else r.string(t[0],"first argument to VError, SError, or WError constructor must be a string, object, or Error"),n={},i=t;return r.object(n),n.strict||e.strict||(i=i.map(function(e){return null===e?"null":void 0===e?"undefined":e})),o=0===i.length?"":a.apply(null,i),{options:n,shortmessage:o}}function u(){var e,t,n,i,o,a,c;if(e=Array.prototype.slice.call(arguments,0),!(this instanceof u))return t=Object.create(u.prototype),u.apply(t,arguments),t;if(n=l({argv:e,strict:!1}),n.options.name&&(r.string(n.options.name,'error\'s "name" must be a string'),this.name=n.options.name),this.jse_shortmsg=n.shortmessage,a=n.shortmessage,i=n.options.cause,i&&(r.ok(s(i),"cause is not an Error"),this.jse_cause=i,n.options.skipCauseMessage||(a+=": "+i.message)),this.jse_info={},n.options.info)for(c in n.options.info)this.jse_info[c]=n.options.info[c];return this.message=a,Error.call(this,a),Error.captureStackTrace&&(o=n.options.constructorOpt||this.constructor,Error.captureStackTrace(this,o)),this}function c(){var e,t,n,r;return e=Array.prototype.slice.call(arguments,0),this instanceof c?(n=l({argv:e,strict:!0}),r=n.options,u.call(this,r,"%s",n.shortmessage),this):(t=Object.create(c.prototype),c.apply(t,arguments),t)}function h(e){r.array(e,"list of errors"),r.ok(e.length>0,"must be at least one error"),this.ase_errors=e,u.call(this,{cause:e[0]},"first of %d error%s",e.length,1==e.length?"":"s")}function f(){var e,t,n,r;return e=Array.prototype.slice.call(arguments,0),this instanceof f?(n=l({argv:e,strict:!1}),r=n.options,r.skipCauseMessage=!0,u.call(this,r,"%s",n.shortmessage),this):(t=Object.create(f.prototype),f.apply(t,e),t)}e.exports=u,u.VError=u,u.SError=c,u.WError=f,u.MultiError=h,i.inherits(u,Error),u.prototype.name="VError",u.prototype.toString=function e(){var t=this.hasOwnProperty("name")&&this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(t+=": "+this.message),t},u.prototype.cause=function e(){var t=u.cause(this);return null===t?void 0:t},u.cause=function(e){return r.ok(s(e),"err must be an Error"),s(e.jse_cause)?e.jse_cause:null},u.info=function(e){var t,n,i;if(r.ok(s(e),"err must be an Error"),n=u.cause(e),t=null!==n?u.info(n):{},"object"==typeof e.jse_info&&null!==e.jse_info)for(i in e.jse_info)t[i]=e.jse_info[i];return t},u.findCauseByName=function(e,t){var n;for(r.ok(s(e),"err must be an Error"),r.string(t,"name"),r.ok(t.length>0,"name cannot be empty"),n=e;null!==n;n=u.cause(n))if(r.ok(s(n)),n.name==t)return n;return null},u.hasCauseWithName=function(e,t){return null!==u.findCauseByName(e,t)},u.fullStack=function(e){r.ok(s(e),"err must be an Error");var t=u.cause(e);return t?e.stack+"\ncaused by: "+u.fullStack(t):e.stack},u.errorFromList=function(e){return r.arrayOfObject(e,"errors"),0===e.length?null:(e.forEach(function(e){r.ok(s(e))}),1==e.length?e[0]:new h(e))},u.errorForEach=function(e,t){r.ok(s(e),"err must be an Error"),r.func(t,"func"),e instanceof h?e.errors().forEach(function e(n){t(n)}):t(e)},i.inherits(c,u),i.inherits(h,u),h.prototype.name="MultiError",h.prototype.errors=function e(){return this.ase_errors.slice(0)},i.inherits(f,u),f.prototype.name="WError",f.prototype.toString=function e(){var t=this.hasOwnProperty("name")&&this.name||this.constructor.name||this.constructor.prototype.name;return this.message&&(t+=": "+this.message),this.jse_cause&&this.jse_cause.message&&(t+="; caused by "+this.jse_cause.toString()),t},f.prototype.cause=function e(t){return s(t)&&(this.jse_cause=t),this.jse_cause}},function(e,t,n){(function(e){var r=n(24),i=n(14);function o(e){var t=["([^%]*)","%","(['\\-+ #0]*?)","([1-9]\\d*)?","(\\.([1-9]\\d*))?","[lhjztL]*?","([diouxXfFeEgGaAcCsSp%jr])"].join(""),n=new RegExp(t),o=Array.prototype.slice.call(arguments,1),a=e,l,h,f,p,d,m,g,y,v,b="",_=1,w=0,k,E;for(r.equal("string",typeof a,"first argument must be a format string");null!==(v=n.exec(a));)if(b+=v[1],a=a.substring(v[0].length),E=v[0].substring(v[1].length),k=w+v[1].length+1,w+=v[0].length,l=v[2]||"",h=v[3]||0,f=v[4]||"",p=v[6],d=!1,g=!1,m=" ","%"!=p){if(0===o.length)throw s(e,k,E,"has no matching argument (too few arguments passed)");if(y=o.shift(),_++,l.match(/[\' #]/))throw s(e,k,E,"uses unsupported flags");if(f.length>0)throw s(e,k,E,"uses non-zero precision (not supported)");switch(l.match(/-/)&&(d=!0),l.match(/0/)&&(m="0"),l.match(/\+/)&&(g=!0),p){case"s":if(void 0===y||null===y)throw s(e,k,E,"attempted to print undefined or null as a string (argument "+_+" to sprintf)");b+=u(m,h,d,y.toString());break;case"d":y=Math.floor(y);case"f":g=g&&y>0?"+":"",b+=g+u(m,h,d,y.toString());break;case"x":b+=u(m,h,d,y.toString(16));break;case"j":0===h&&(h=10),b+=i.inspect(y,!1,h);break;case"r":b+=c(y);break;default:throw s(e,k,E,"is not supported")}}else b+="%";return b+=a,b}function s(e,t,n,i){return r.equal(typeof e,"string"),r.equal(typeof n,"string"),r.equal(typeof t,"number"),r.equal(typeof i,"string"),new Error('format string "'+e+'": conversion specifier "'+n+'" at character '+t+" "+i)}function a(){var t=Array.prototype.slice.call(arguments);t.unshift(e.stdout),l.apply(null,t)}function l(e){var t=Array.prototype.slice.call(arguments,1);return e.write(o.apply(this,t))}function u(e,t,n,r){for(var i=r;i.length<t;)n?i+=e:i=e+i;return i}function c(e){var t;if(!(e instanceof Error))throw new Error(o("invalid type for %%r: %j",e));if(t="EXCEPTION: "+e.constructor.name+": "+e.stack,e.cause&&"function"==typeof e.cause){var n=e.cause();n&&(t+="\nCaused by: "+c(n))}return t}t.sprintf=o,t.printf=a,t.fprintf=l}).call(this,n(3))},function(e,t,n){var r,i,o,s;o=this,s=function(){var e=n;e.Integer={type:"integer"};var t={String:String,Boolean:Boolean,Number:Number,Object:Object,Array:Array,Date:Date};function n(e,t){return n(e,t,{changing:!1})}e.validate=n,e.checkPropertyChange=function(e,t,r){return n(e,t,{changing:r||"property"})};var n=e._validate=function(e,n,r){r||(r={});var i=r.changing;function o(e){return e.type||t[e.name]==e&&e.name.toLowerCase()}var s=[];function a(e,t,n,u){var c;function h(e){s.push({property:n,message:e})}if(n+=n?"number"==typeof u?"["+u+"]":void 0===u?"":"."+u:u,("object"!=typeof t||t instanceof Array)&&(n||"function"!=typeof t)&&(!t||!o(t)))return"function"==typeof t?e instanceof t||h("is not an instance of the class/constructor "+t.name):t&&h("Invalid schema/property definition "+t),null;function f(e,t){if(e){if(!("string"!=typeof e||"any"==e||("null"==e?null===t:typeof t==e)||t instanceof Array&&"array"==e||t instanceof Date&&"date"==e||"integer"==e&&t%1==0))return[{property:n,message:typeof t+" value found, but a "+e+" is required"}];if(e instanceof Array){for(var r=[],i=0;i<e.length&&(r=f(e[i],t)).length;i++);if(r.length)return r}else if("object"==typeof e){var o=s;s=[],a(t,e,n);var l=s;return s=o,l}}return[]}if(i&&t.readonly&&h("is a readonly field, it can not be changed"),t.extends&&a(e,t.extends,n,u),void 0===e)t.required&&h("is missing and it is required");else if(s=s.concat(f(o(t),e)),t.disallow&&!f(t.disallow,e).length&&h(" disallowed value was matched"),null!==e){if(e instanceof Array){if(t.items){var p=t.items instanceof Array,d=t.items;for(u=0,c=e.length;u<c;u+=1)p&&(d=t.items[u]),r.coerce&&(e[u]=r.coerce(e[u],d)),s.concat(a(e[u],d,n,u))}t.minItems&&e.length<t.minItems&&h("There must be a minimum of "+t.minItems+" in the array"),t.maxItems&&e.length>t.maxItems&&h("There must be a maximum of "+t.maxItems+" in the array")}else(t.properties||t.additionalProperties)&&s.concat(l(e,t.properties,n,t.additionalProperties));if(t.pattern&&"string"==typeof e&&!e.match(t.pattern)&&h("does not match the regex pattern "+t.pattern),t.maxLength&&"string"==typeof e&&e.length>t.maxLength&&h("may only be "+t.maxLength+" characters long"),t.minLength&&"string"==typeof e&&e.length<t.minLength&&h("must be at least "+t.minLength+" characters long"),void 0!==typeof t.minimum&&typeof e==typeof t.minimum&&t.minimum>e&&h("must have a minimum value of "+t.minimum),void 0!==typeof t.maximum&&typeof e==typeof t.maximum&&t.maximum<e&&h("must have a maximum value of "+t.maximum),t.enum){var m=t.enum,g;c=m.length;for(var y=0;y<c;y++)if(m[y]===e){g=1;break}g||h("does not have a value in the enumeration "+m.join(", "))}"number"==typeof t.maxDecimal&&e.toString().match(new RegExp("\\.[0-9]{"+(t.maxDecimal+1)+",}"))&&h("may only have "+t.maxDecimal+" digits of decimal places")}return null}function l(e,t,n,o){if("object"==typeof t)for(var l in("object"!=typeof e||e instanceof Array)&&s.push({property:n,message:"an object is required"}),t)if(t.hasOwnProperty(l)){var u=e[l];if(void 0===u&&r.existingOnly)continue;var c=t[l];void 0===u&&c.default&&(u=e[l]=c.default),r.coerce&&l in e&&(u=e[l]=r.coerce(u,c)),a(u,c,n,l)}for(l in e){if(e.hasOwnProperty(l)&&("_"!=l.charAt(0)||"_"!=l.charAt(1))&&t&&!t[l]&&!1===o){if(r.filter){delete e[l];continue}s.push({property:n,message:typeof u+"The property "+l+" is not defined in the schema and the schema does not allow additional properties"})}var h=t&&t[l]&&t[l].requires;!h||h in e||s.push({property:n,message:"the presence of the property "+l+" requires that "+h+" also be present"}),u=e[l],!o||t&&"object"==typeof t&&l in t||(r.coerce&&(u=e[l]=r.coerce(u,o)),a(u,o,n,l)),!i&&u&&u.$schema&&(s=s.concat(a(u,u.$schema,n,l)))}return s}return n&&a(e,n,"",i||""),!i&&e&&e.$schema&&a(e,e.$schema,"",""),{valid:!s.length,errors:s}};return e.mustBeValid=function(e){if(!e.valid)throw new TypeError(e.errors.map(function(e){return"for property "+e.property+": "+e.message}).join(", \n"))},e},r=[],i=function(){return s()}.apply(t,r),void 0===i||(e.exports=i)},function(e,t,n){(function(t){var r=n(25),i=n(16),o=n(314),s=n(236),a=s.HASH_ALGOS,l=s.PK_ALGOS,u=s.InvalidAlgorithmError,c=s.HttpSignatureError,h=s.validateAlgorithm;e.exports={verifySignature:function e(n,i){r.object(n,"parsedSignature"),("string"==typeof i||t.isBuffer(i))&&(i=o.parseKey(i)),r.ok(o.Key.isKey(i,[1,1]),"pubkey must be a sshpk.Key");var s=h(n.algorithm);if("hmac"===s[0]||s[0]!==i.type)return!1;var a=i.createVerify(s[1]);return a.update(n.signingString),a.verify(n.params.signature,"base64")},verifyHMAC:function e(n,o){r.object(n,"parsedHMAC"),r.string(o,"secret");var s=h(n.algorithm);if("hmac"!==s[0])return!1;var a=s[1].toUpperCase(),l=i.createHmac(a,o);l.update(n.signingString);var u=i.createHmac(a,o);u.update(l.digest()),u=u.digest();var c=i.createHmac(a,o);return c.update(new t(n.params.signature,"base64")),c=c.digest(),"string"==typeof u?u===c:t.isBuffer(u)&&!u.equals?u.toString("binary")===c.toString("binary"):u.equals(c)}}}).call(this,n(0).Buffer)},function(e,t,n){"use strict";
/*!
* mime-types
* Copyright(c) 2014 Jonathan Ong
* Copyright(c) 2015 Douglas Christopher Wilson
* MIT Licensed
*/var r=n(1668),i=n(54).extname,o=/^\s*([^;\s]*)(?:;|\s|$)/,s=/^text\//i;function a(e){if(!e||"string"!=typeof e)return!1;var t=o.exec(e),n=t&&r[t[1].toLowerCase()];return n&&n.charset?n.charset:!(!t||!s.test(t[1]))&&"UTF-8"}function l(e){if(!e||"string"!=typeof e)return!1;var n=-1===e.indexOf("/")?t.lookup(e):e;if(!n)return!1;if(-1===n.indexOf("charset")){var r=t.charset(n);r&&(n+="; charset="+r.toLowerCase())}return n}function u(e){if(!e||"string"!=typeof e)return!1;var n=o.exec(e),r=n&&t.extensions[n[1].toLowerCase()];return!(!r||!r.length)&&r[0]}function c(e){if(!e||"string"!=typeof e)return!1;var n=i("x."+e).toLowerCase().substr(1);return n&&t.types[n]||!1}function h(e,t){var n=["nginx","apache",void 0,"iana"];Object.keys(r).forEach(function i(o){var s=r[o],a=s.extensions;if(a&&a.length){e[o]=a;for(var l=0;l<a.length;l++){var u=a[l];if(t[u]){var c=n.indexOf(r[t[u]].source),h=n.indexOf(s.source);if("application/octet-stream"!==t[u]&&(c>h||c===h&&"application/"===t[u].substr(0,12)))continue}t[u]=o}}})}t.charset=a,t.charsets={lookup:a},t.contentType=l,t.extension=u,t.extensions=Object.create(null),t.lookup=c,t.types=Object.create(null),h(t.extensions,t.types)},function(e,t,n){
/*!
* mime-db
* Copyright(c) 2014 Jonathan Ong
* MIT Licensed
*/
e.exports=n(1669)},function(e){e.exports={"application/1d-interleaved-parityfec":{source:"iana"},"application/3gpdash-qoe-report+xml":{source:"iana",compressible:!0},"application/3gpp-ims+xml":{source:"iana",compressible:!0},"application/a2l":{source:"iana"},"application/activemessage":{source:"iana"},"application/activity+json":{source:"iana",compressible:!0},"application/alto-costmap+json":{source:"iana",compressible:!0},"application/alto-costmapfilter+json":{source:"iana",compressible:!0},"application/alto-directory+json":{source:"iana",compressible:!0},"application/alto-endpointcost+json":{source:"iana",compressible:!0},"application/alto-endpointcostparams+json":{source:"iana",compressible:!0},"application/alto-endpointprop+json":{source:"iana",compressible:!0},"application/alto-endpointpropparams+json":{source:"iana",compressible:!0},"application/alto-error+json":{source:"iana",compressible:!0},"application/alto-networkmap+json":{source:"iana",compressible:!0},"application/alto-networkmapfilter+json":{source:"iana",compressible:!0},"application/aml":{source:"iana"},"application/andrew-inset":{source:"iana",extensions:["ez"]},"application/applefile":{source:"iana"},"application/applixware":{source:"apache",extensions:["aw"]},"application/atf":{source:"iana"},"application/atfx":{source:"iana"},"application/atom+xml":{source:"iana",compressible:!0,extensions:["atom"]},"application/atomcat+xml":{source:"iana",compressible:!0,extensions:["atomcat"]},"application/atomdeleted+xml":{source:"iana",compressible:!0},"application/atomicmail":{source:"iana"},"application/atomsvc+xml":{source:"iana",compressible:!0,extensions:["atomsvc"]},"application/atsc-dwd+xml":{source:"iana",compressible:!0},"application/atsc-held+xml":{source:"iana",compressible:!0},"application/atsc-rsat+xml":{source:"iana",compressible:!0},"application/atxml":{source:"iana"},"application/auth-policy+xml":{source:"iana",compressible:!0},"application/bacnet-xdd+zip":{source:"iana",compressible:!1},"application/batch-smtp":{source:"iana"},"application/bdoc":{compressible:!1,extensions:["bdoc"]},"application/beep+xml":{source:"iana",compressible:!0},"application/calendar+json":{source:"iana",compressible:!0},"application/calendar+xml":{source:"iana",compressible:!0},"application/call-completion":{source:"iana"},"application/cals-1840":{source:"iana"},"application/cbor":{source:"iana"},"application/cccex":{source:"iana"},"application/ccmp+xml":{source:"iana",compressible:!0},"application/ccxml+xml":{source:"iana",compressible:!0,extensions:["ccxml"]},"application/cdfx+xml":{source:"iana",compressible:!0},"application/cdmi-capability":{source:"iana",extensions:["cdmia"]},"application/cdmi-container":{source:"iana",extensions:["cdmic"]},"application/cdmi-domain":{source:"iana",extensions:["cdmid"]},"application/cdmi-object":{source:"iana",extensions:["cdmio"]},"application/cdmi-queue":{source:"iana",extensions:["cdmiq"]},"application/cdni":{source:"iana"},"application/cea":{source:"iana"},"application/cea-2018+xml":{source:"iana",compressible:!0},"application/cellml+xml":{source:"iana",compressible:!0},"application/cfw":{source:"iana"},"application/clue_info+xml":{source:"iana",compressible:!0},"application/cms":{source:"iana"},"application/cnrp+xml":{source:"iana",compressible:!0},"application/coap-group+json":{source:"iana",compressible:!0},"application/coap-payload":{source:"iana"},"application/commonground":{source:"iana"},"application/conference-info+xml":{source:"iana",compressible:!0},"application/cose":{source:"iana"},"application/cose-key":{source:"iana"},"application/cose-key-set":{source:"iana"},"application/cpl+xml":{source:"iana",compressible:!0},"application/csrattrs":{source:"iana"},"application/csta+xml":{source:"iana",compressible:!0},"application/cstadata+xml":{source:"iana",compressible:!0},"application/csvm+json":{source:"iana",compressible:!0},"application/cu-seeme":{source:"apache",extensions:["cu"]},"application/cwt":{source:"iana"},"application/cybercash":{source:"iana"},"application/dart":{compressible:!0},"application/dash+xml":{source:"iana",compressible:!0,extensions:["mpd"]},"application/dashdelta":{source:"iana"},"application/davmount+xml":{source:"iana",compressible:!0,extensions:["davmount"]},"application/dca-rft":{source:"iana"},"application/dcd":{source:"iana"},"application/dec-dx":{source:"iana"},"application/dialog-info+xml":{source:"iana",compressible:!0},"application/dicom":{source:"iana"},"application/dicom+json":{source:"iana",compressible:!0},"application/dicom+xml":{source:"iana",compressible:!0},"application/dii":{source:"iana"},"application/dit":{source:"iana"},"application/dns":{source:"iana"},"application/dns+json":{source:"iana",compressible:!0},"application/dns-message":{source:"iana"},"application/docbook+xml":{source:"apache",compressible:!0,extensions:["dbk"]},"application/dskpp+xml":{source:"iana",compressible:!0},"application/dssc+der":{source:"iana",extensions:["dssc"]},"application/dssc+xml":{source:"iana",compressible:!0,extensions:["xdssc"]},"application/dvcs":{source:"iana"},"application/ecmascript":{source:"iana",compressible:!0,extensions:["ecma","es"]},"application/edi-consent":{source:"iana"},"application/edi-x12":{source:"iana",compressible:!1},"application/edifact":{source:"iana",compressible:!1},"application/efi":{source:"iana"},"application/emergencycalldata.comment+xml":{source:"iana",compressible:!0},"application/emergencycalldata.control+xml":{source:"iana",compressible:!0},"application/emergencycalldata.deviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.ecall.msd":{source:"iana"},"application/emergencycalldata.providerinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.serviceinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.subscriberinfo+xml":{source:"iana",compressible:!0},"application/emergencycalldata.veds+xml":{source:"iana",compressible:!0},"application/emma+xml":{source:"iana",compressible:!0,extensions:["emma"]},"application/emotionml+xml":{source:"iana",compressible:!0},"application/encaprtp":{source:"iana"},"application/epp+xml":{source:"iana",compressible:!0},"application/epub+zip":{source:"iana",compressible:!1,extensions:["epub"]},"application/eshop":{source:"iana"},"application/exi":{source:"iana",extensions:["exi"]},"application/expect-ct-report+json":{source:"iana",compressible:!0},"application/fastinfoset":{source:"iana"},"application/fastsoap":{source:"iana"},"application/fdt+xml":{source:"iana",compressible:!0},"application/fhir+json":{source:"iana",compressible:!0},"application/fhir+xml":{source:"iana",compressible:!0},"application/fido.trusted-apps+json":{compressible:!0},"application/fits":{source:"iana"},"application/font-sfnt":{source:"iana"},"application/font-tdpfr":{source:"iana",extensions:["pfr"]},"application/font-woff":{source:"iana",compressible:!1},"application/framework-attributes+xml":{source:"iana",compressible:!0},"application/geo+json":{source:"iana",compressible:!0,extensions:["geojson"]},"application/geo+json-seq":{source:"iana"},"application/geopackage+sqlite3":{source:"iana"},"application/geoxacml+xml":{source:"iana",compressible:!0},"application/gltf-buffer":{source:"iana"},"application/gml+xml":{source:"iana",compressible:!0,extensions:["gml"]},"application/gpx+xml":{source:"apache",compressible:!0,extensions:["gpx"]},"application/gxf":{source:"apache",extensions:["gxf"]},"application/gzip":{source:"iana",compressible:!1,extensions:["gz"]},"application/h224":{source:"iana"},"application/held+xml":{source:"iana",compressible:!0},"application/hjson":{extensions:["hjson"]},"application/http":{source:"iana"},"application/hyperstudio":{source:"iana",extensions:["stk"]},"application/ibe-key-request+xml":{source:"iana",compressible:!0},"application/ibe-pkg-reply+xml":{source:"iana",compressible:!0},"application/ibe-pp-data":{source:"iana"},"application/iges":{source:"iana"},"application/im-iscomposing+xml":{source:"iana",compressible:!0},"application/index":{source:"iana"},"application/index.cmd":{source:"iana"},"application/index.obj":{source:"iana"},"application/index.response":{source:"iana"},"application/index.vnd":{source:"iana"},"application/inkml+xml":{source:"iana",compressible:!0,extensions:["ink","inkml"]},"application/iotp":{source:"iana"},"application/ipfix":{source:"iana",extensions:["ipfix"]},"application/ipp":{source:"iana"},"application/isup":{source:"iana"},"application/its+xml":{source:"iana",compressible:!0},"application/java-archive":{source:"apache",compressible:!1,extensions:["jar","war","ear"]},"application/java-serialized-object":{source:"apache",compressible:!1,extensions:["ser"]},"application/java-vm":{source:"apache",compressible:!1,extensions:["class"]},"application/javascript":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["js","mjs"]},"application/jf2feed+json":{source:"iana",compressible:!0},"application/jose":{source:"iana"},"application/jose+json":{source:"iana",compressible:!0},"application/jrd+json":{source:"iana",compressible:!0},"application/json":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["json","map"]},"application/json-patch+json":{source:"iana",compressible:!0},"application/json-seq":{source:"iana"},"application/json5":{extensions:["json5"]},"application/jsonml+json":{source:"apache",compressible:!0,extensions:["jsonml"]},"application/jwk+json":{source:"iana",compressible:!0},"application/jwk-set+json":{source:"iana",compressible:!0},"application/jwt":{source:"iana"},"application/kpml-request+xml":{source:"iana",compressible:!0},"application/kpml-response+xml":{source:"iana",compressible:!0},"application/ld+json":{source:"iana",compressible:!0,extensions:["jsonld"]},"application/lgr+xml":{source:"iana",compressible:!0},"application/link-format":{source:"iana"},"application/load-control+xml":{source:"iana",compressible:!0},"application/lost+xml":{source:"iana",compressible:!0,extensions:["lostxml"]},"application/lostsync+xml":{source:"iana",compressible:!0},"application/lxf":{source:"iana"},"application/mac-binhex40":{source:"iana",extensions:["hqx"]},"application/mac-compactpro":{source:"apache",extensions:["cpt"]},"application/macwriteii":{source:"iana"},"application/mads+xml":{source:"iana",compressible:!0,extensions:["mads"]},"application/manifest+json":{charset:"UTF-8",compressible:!0,extensions:["webmanifest"]},"application/marc":{source:"iana",extensions:["mrc"]},"application/marcxml+xml":{source:"iana",compressible:!0,extensions:["mrcx"]},"application/mathematica":{source:"iana",extensions:["ma","nb","mb"]},"application/mathml+xml":{source:"iana",compressible:!0,extensions:["mathml"]},"application/mathml-content+xml":{source:"iana",compressible:!0},"application/mathml-presentation+xml":{source:"iana",compressible:!0},"application/mbms-associated-procedure-description+xml":{source:"iana",compressible:!0},"application/mbms-deregister+xml":{source:"iana",compressible:!0},"application/mbms-envelope+xml":{source:"iana",compressible:!0},"application/mbms-msk+xml":{source:"iana",compressible:!0},"application/mbms-msk-response+xml":{source:"iana",compressible:!0},"application/mbms-protection-description+xml":{source:"iana",compressible:!0},"application/mbms-reception-report+xml":{source:"iana",compressible:!0},"application/mbms-register+xml":{source:"iana",compressible:!0},"application/mbms-register-response+xml":{source:"iana",compressible:!0},"application/mbms-schedule+xml":{source:"iana",compressible:!0},"application/mbms-user-service-description+xml":{source:"iana",compressible:!0},"application/mbox":{source:"iana",extensions:["mbox"]},"application/media-policy-dataset+xml":{source:"iana",compressible:!0},"application/media_control+xml":{source:"iana",compressible:!0},"application/mediaservercontrol+xml":{source:"iana",compressible:!0,extensions:["mscml"]},"application/merge-patch+json":{source:"iana",compressible:!0},"application/metalink+xml":{source:"apache",compressible:!0,extensions:["metalink"]},"application/metalink4+xml":{source:"iana",compressible:!0,extensions:["meta4"]},"application/mets+xml":{source:"iana",compressible:!0,extensions:["mets"]},"application/mf4":{source:"iana"},"application/mikey":{source:"iana"},"application/mmt-aei+xml":{source:"iana",compressible:!0},"application/mmt-usd+xml":{source:"iana",compressible:!0},"application/mods+xml":{source:"iana",compressible:!0,extensions:["mods"]},"application/moss-keys":{source:"iana"},"application/moss-signature":{source:"iana"},"application/mosskey-data":{source:"iana"},"application/mosskey-request":{source:"iana"},"application/mp21":{source:"iana",extensions:["m21","mp21"]},"application/mp4":{source:"iana",extensions:["mp4s","m4p"]},"application/mpeg4-generic":{source:"iana"},"application/mpeg4-iod":{source:"iana"},"application/mpeg4-iod-xmt":{source:"iana"},"application/mrb-consumer+xml":{source:"iana",compressible:!0},"application/mrb-publish+xml":{source:"iana",compressible:!0},"application/msc-ivr+xml":{source:"iana",compressible:!0},"application/msc-mixer+xml":{source:"iana",compressible:!0},"application/msword":{source:"iana",compressible:!1,extensions:["doc","dot"]},"application/mud+json":{source:"iana",compressible:!0},"application/mxf":{source:"iana",extensions:["mxf"]},"application/n-quads":{source:"iana",extensions:["nq"]},"application/n-triples":{source:"iana",extensions:["nt"]},"application/nasdata":{source:"iana"},"application/news-checkgroups":{source:"iana"},"application/news-groupinfo":{source:"iana"},"application/news-transmission":{source:"iana"},"application/nlsml+xml":{source:"iana",compressible:!0},"application/node":{source:"iana"},"application/nss":{source:"iana"},"application/ocsp-request":{source:"iana"},"application/ocsp-response":{source:"iana"},"application/octet-stream":{source:"iana",compressible:!1,extensions:["bin","dms","lrf","mar","so","dist","distz","pkg","bpk","dump","elc","deploy","exe","dll","deb","dmg","iso","img","msi","msp","msm","buffer"]},"application/oda":{source:"iana",extensions:["oda"]},"application/odm+xml":{source:"iana",compressible:!0},"application/odx":{source:"iana"},"application/oebps-package+xml":{source:"iana",compressible:!0,extensions:["opf"]},"application/ogg":{source:"iana",compressible:!1,extensions:["ogx"]},"application/omdoc+xml":{source:"apache",compressible:!0,extensions:["omdoc"]},"application/onenote":{source:"apache",extensions:["onetoc","onetoc2","onetmp","onepkg"]},"application/oscore":{source:"iana"},"application/oxps":{source:"iana",extensions:["oxps"]},"application/p2p-overlay+xml":{source:"iana",compressible:!0},"application/parityfec":{source:"iana"},"application/passport":{source:"iana"},"application/patch-ops-error+xml":{source:"iana",compressible:!0,extensions:["xer"]},"application/pdf":{source:"iana",compressible:!1,extensions:["pdf"]},"application/pdx":{source:"iana"},"application/pem-certificate-chain":{source:"iana"},"application/pgp-encrypted":{source:"iana",compressible:!1,extensions:["pgp"]},"application/pgp-keys":{source:"iana"},"application/pgp-signature":{source:"iana",extensions:["asc","sig"]},"application/pics-rules":{source:"apache",extensions:["prf"]},"application/pidf+xml":{source:"iana",compressible:!0},"application/pidf-diff+xml":{source:"iana",compressible:!0},"application/pkcs10":{source:"iana",extensions:["p10"]},"application/pkcs12":{source:"iana"},"application/pkcs7-mime":{source:"iana",extensions:["p7m","p7c"]},"application/pkcs7-signature":{source:"iana",extensions:["p7s"]},"application/pkcs8":{source:"iana",extensions:["p8"]},"application/pkcs8-encrypted":{source:"iana"},"application/pkix-attr-cert":{source:"iana",extensions:["ac"]},"application/pkix-cert":{source:"iana",extensions:["cer"]},"application/pkix-crl":{source:"iana",extensions:["crl"]},"application/pkix-pkipath":{source:"iana",extensions:["pkipath"]},"application/pkixcmp":{source:"iana",extensions:["pki"]},"application/pls+xml":{source:"iana",compressible:!0,extensions:["pls"]},"application/poc-settings+xml":{source:"iana",compressible:!0},"application/postscript":{source:"iana",compressible:!0,extensions:["ai","eps","ps"]},"application/ppsp-tracker+json":{source:"iana",compressible:!0},"application/problem+json":{source:"iana",compressible:!0},"application/problem+xml":{source:"iana",compressible:!0},"application/provenance+xml":{source:"iana",compressible:!0},"application/prs.alvestrand.titrax-sheet":{source:"iana"},"application/prs.cww":{source:"iana",extensions:["cww"]},"application/prs.hpub+zip":{source:"iana",compressible:!1},"application/prs.nprend":{source:"iana"},"application/prs.plucker":{source:"iana"},"application/prs.rdf-xml-crypt":{source:"iana"},"application/prs.xsf+xml":{source:"iana",compressible:!0},"application/pskc+xml":{source:"iana",compressible:!0,extensions:["pskcxml"]},"application/qsig":{source:"iana"},"application/raml+yaml":{compressible:!0,extensions:["raml"]},"application/raptorfec":{source:"iana"},"application/rdap+json":{source:"iana",compressible:!0},"application/rdf+xml":{source:"iana",compressible:!0,extensions:["rdf","owl"]},"application/reginfo+xml":{source:"iana",compressible:!0,extensions:["rif"]},"application/relax-ng-compact-syntax":{source:"iana",extensions:["rnc"]},"application/remote-printing":{source:"iana"},"application/reputon+json":{source:"iana",compressible:!0},"application/resource-lists+xml":{source:"iana",compressible:!0,extensions:["rl"]},"application/resource-lists-diff+xml":{source:"iana",compressible:!0,extensions:["rld"]},"application/rfc+xml":{source:"iana",compressible:!0},"application/riscos":{source:"iana"},"application/rlmi+xml":{source:"iana",compressible:!0},"application/rls-services+xml":{source:"iana",compressible:!0,extensions:["rs"]},"application/route-apd+xml":{source:"iana",compressible:!0},"application/route-s-tsid+xml":{source:"iana",compressible:!0},"application/route-usd+xml":{source:"iana",compressible:!0},"application/rpki-ghostbusters":{source:"iana",extensions:["gbr"]},"application/rpki-manifest":{source:"iana",extensions:["mft"]},"application/rpki-publication":{source:"iana"},"application/rpki-roa":{source:"iana",extensions:["roa"]},"application/rpki-updown":{source:"iana"},"application/rsd+xml":{source:"apache",compressible:!0,extensions:["rsd"]},"application/rss+xml":{source:"apache",compressible:!0,extensions:["rss"]},"application/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"application/rtploopback":{source:"iana"},"application/rtx":{source:"iana"},"application/samlassertion+xml":{source:"iana",compressible:!0},"application/samlmetadata+xml":{source:"iana",compressible:!0},"application/sbml+xml":{source:"iana",compressible:!0,extensions:["sbml"]},"application/scaip+xml":{source:"iana",compressible:!0},"application/scim+json":{source:"iana",compressible:!0},"application/scvp-cv-request":{source:"iana",extensions:["scq"]},"application/scvp-cv-response":{source:"iana",extensions:["scs"]},"application/scvp-vp-request":{source:"iana",extensions:["spq"]},"application/scvp-vp-response":{source:"iana",extensions:["spp"]},"application/sdp":{source:"iana",extensions:["sdp"]},"application/secevent+jwt":{source:"iana"},"application/senml+cbor":{source:"iana"},"application/senml+json":{source:"iana",compressible:!0},"application/senml+xml":{source:"iana",compressible:!0},"application/senml-exi":{source:"iana"},"application/sensml+cbor":{source:"iana"},"application/sensml+json":{source:"iana",compressible:!0},"application/sensml+xml":{source:"iana",compressible:!0},"application/sensml-exi":{source:"iana"},"application/sep+xml":{source:"iana",compressible:!0},"application/sep-exi":{source:"iana"},"application/session-info":{source:"iana"},"application/set-payment":{source:"iana"},"application/set-payment-initiation":{source:"iana",extensions:["setpay"]},"application/set-registration":{source:"iana"},"application/set-registration-initiation":{source:"iana",extensions:["setreg"]},"application/sgml":{source:"iana"},"application/sgml-open-catalog":{source:"iana"},"application/shf+xml":{source:"iana",compressible:!0,extensions:["shf"]},"application/sieve":{source:"iana",extensions:["siv","sieve"]},"application/simple-filter+xml":{source:"iana",compressible:!0},"application/simple-message-summary":{source:"iana"},"application/simplesymbolcontainer":{source:"iana"},"application/slate":{source:"iana"},"application/smil":{source:"iana"},"application/smil+xml":{source:"iana",compressible:!0,extensions:["smi","smil"]},"application/smpte336m":{source:"iana"},"application/soap+fastinfoset":{source:"iana"},"application/soap+xml":{source:"iana",compressible:!0},"application/sparql-query":{source:"iana",extensions:["rq"]},"application/sparql-results+xml":{source:"iana",compressible:!0,extensions:["srx"]},"application/spirits-event+xml":{source:"iana",compressible:!0},"application/sql":{source:"iana"},"application/srgs":{source:"iana",extensions:["gram"]},"application/srgs+xml":{source:"iana",compressible:!0,extensions:["grxml"]},"application/sru+xml":{source:"iana",compressible:!0,extensions:["sru"]},"application/ssdl+xml":{source:"apache",compressible:!0,extensions:["ssdl"]},"application/ssml+xml":{source:"iana",compressible:!0,extensions:["ssml"]},"application/stix+json":{source:"iana",compressible:!0},"application/tamp-apex-update":{source:"iana"},"application/tamp-apex-update-confirm":{source:"iana"},"application/tamp-community-update":{source:"iana"},"application/tamp-community-update-confirm":{source:"iana"},"application/tamp-error":{source:"iana"},"application/tamp-sequence-adjust":{source:"iana"},"application/tamp-sequence-adjust-confirm":{source:"iana"},"application/tamp-status-query":{source:"iana"},"application/tamp-status-response":{source:"iana"},"application/tamp-update":{source:"iana"},"application/tamp-update-confirm":{source:"iana"},"application/tar":{compressible:!0},"application/taxii+json":{source:"iana",compressible:!0},"application/tei+xml":{source:"iana",compressible:!0,extensions:["tei","teicorpus"]},"application/tetra_isi":{source:"iana"},"application/thraud+xml":{source:"iana",compressible:!0,extensions:["tfi"]},"application/timestamp-query":{source:"iana"},"application/timestamp-reply":{source:"iana"},"application/timestamped-data":{source:"iana",extensions:["tsd"]},"application/tlsrpt+gzip":{source:"iana"},"application/tlsrpt+json":{source:"iana",compressible:!0},"application/tnauthlist":{source:"iana"},"application/trickle-ice-sdpfrag":{source:"iana"},"application/trig":{source:"iana"},"application/ttml+xml":{source:"iana",compressible:!0},"application/tve-trigger":{source:"iana"},"application/tzif":{source:"iana"},"application/tzif-leap":{source:"iana"},"application/ulpfec":{source:"iana"},"application/urc-grpsheet+xml":{source:"iana",compressible:!0},"application/urc-ressheet+xml":{source:"iana",compressible:!0},"application/urc-targetdesc+xml":{source:"iana",compressible:!0},"application/urc-uisocketdesc+xml":{source:"iana",compressible:!0},"application/vcard+json":{source:"iana",compressible:!0},"application/vcard+xml":{source:"iana",compressible:!0},"application/vemmi":{source:"iana"},"application/vividence.scriptfile":{source:"apache"},"application/vnd.1000minds.decision-model+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-prose+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-prose-pc3ch+xml":{source:"iana",compressible:!0},"application/vnd.3gpp-v2x-local-service-information":{source:"iana"},"application/vnd.3gpp.access-transfer-events+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.bsf+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.gmop+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mc-signalling-ear":{source:"iana"},"application/vnd.3gpp.mcdata-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-payload":{source:"iana"},"application/vnd.3gpp.mcdata-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-signalling":{source:"iana"},"application/vnd.3gpp.mcdata-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcdata-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-floor-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-signed+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-ue-init-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcptt-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-command+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-affiliation-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-location-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-mbms-usage-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-service-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-transmission-request+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-ue-config+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mcvideo-user-profile+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.mid-call+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.pic-bw-large":{source:"iana",extensions:["plb"]},"application/vnd.3gpp.pic-bw-small":{source:"iana",extensions:["psb"]},"application/vnd.3gpp.pic-bw-var":{source:"iana",extensions:["pvb"]},"application/vnd.3gpp.sms":{source:"iana"},"application/vnd.3gpp.sms+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-ext+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.srvcc-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.state-and-event-info+xml":{source:"iana",compressible:!0},"application/vnd.3gpp.ussd+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.bcmcsinfo+xml":{source:"iana",compressible:!0},"application/vnd.3gpp2.sms":{source:"iana"},"application/vnd.3gpp2.tcap":{source:"iana",extensions:["tcap"]},"application/vnd.3lightssoftware.imagescal":{source:"iana"},"application/vnd.3m.post-it-notes":{source:"iana",extensions:["pwn"]},"application/vnd.accpac.simply.aso":{source:"iana",extensions:["aso"]},"application/vnd.accpac.simply.imp":{source:"iana",extensions:["imp"]},"application/vnd.acucobol":{source:"iana",extensions:["acu"]},"application/vnd.acucorp":{source:"iana",extensions:["atc","acutc"]},"application/vnd.adobe.air-application-installer-package+zip":{source:"apache",compressible:!1,extensions:["air"]},"application/vnd.adobe.flash.movie":{source:"iana"},"application/vnd.adobe.formscentral.fcdt":{source:"iana",extensions:["fcdt"]},"application/vnd.adobe.fxp":{source:"iana",extensions:["fxp","fxpl"]},"application/vnd.adobe.partial-upload":{source:"iana"},"application/vnd.adobe.xdp+xml":{source:"iana",compressible:!0,extensions:["xdp"]},"application/vnd.adobe.xfdf":{source:"iana",extensions:["xfdf"]},"application/vnd.aether.imp":{source:"iana"},"application/vnd.afpc.afplinedata":{source:"iana"},"application/vnd.afpc.modca":{source:"iana"},"application/vnd.ah-barcode":{source:"iana"},"application/vnd.ahead.space":{source:"iana",extensions:["ahead"]},"application/vnd.airzip.filesecure.azf":{source:"iana",extensions:["azf"]},"application/vnd.airzip.filesecure.azs":{source:"iana",extensions:["azs"]},"application/vnd.amadeus+json":{source:"iana",compressible:!0},"application/vnd.amazon.ebook":{source:"apache",extensions:["azw"]},"application/vnd.amazon.mobi8-ebook":{source:"iana"},"application/vnd.americandynamics.acc":{source:"iana",extensions:["acc"]},"application/vnd.amiga.ami":{source:"iana",extensions:["ami"]},"application/vnd.amundsen.maze+xml":{source:"iana",compressible:!0},"application/vnd.android.package-archive":{source:"apache",compressible:!1,extensions:["apk"]},"application/vnd.anki":{source:"iana"},"application/vnd.anser-web-certificate-issue-initiation":{source:"iana",extensions:["cii"]},"application/vnd.anser-web-funds-transfer-initiation":{source:"apache",extensions:["fti"]},"application/vnd.antix.game-component":{source:"iana",extensions:["atx"]},"application/vnd.apache.thrift.binary":{source:"iana"},"application/vnd.apache.thrift.compact":{source:"iana"},"application/vnd.apache.thrift.json":{source:"iana"},"application/vnd.api+json":{source:"iana",compressible:!0},"application/vnd.apothekende.reservation+json":{source:"iana",compressible:!0},"application/vnd.apple.installer+xml":{source:"iana",compressible:!0,extensions:["mpkg"]},"application/vnd.apple.keynote":{source:"iana",extensions:["keynote"]},"application/vnd.apple.mpegurl":{source:"iana",extensions:["m3u8"]},"application/vnd.apple.numbers":{source:"iana",extensions:["numbers"]},"application/vnd.apple.pages":{source:"iana",extensions:["pages"]},"application/vnd.apple.pkpass":{compressible:!1,extensions:["pkpass"]},"application/vnd.arastra.swi":{source:"iana"},"application/vnd.aristanetworks.swi":{source:"iana",extensions:["swi"]},"application/vnd.artisan+json":{source:"iana",compressible:!0},"application/vnd.artsquare":{source:"iana"},"application/vnd.astraea-software.iota":{source:"iana",extensions:["iota"]},"application/vnd.audiograph":{source:"iana",extensions:["aep"]},"application/vnd.autopackage":{source:"iana"},"application/vnd.avalon+json":{source:"iana",compressible:!0},"application/vnd.avistar+xml":{source:"iana",compressible:!0},"application/vnd.balsamiq.bmml+xml":{source:"iana",compressible:!0},"application/vnd.balsamiq.bmpr":{source:"iana"},"application/vnd.banana-accounting":{source:"iana"},"application/vnd.bbf.usp.msg":{source:"iana"},"application/vnd.bbf.usp.msg+json":{source:"iana",compressible:!0},"application/vnd.bekitzur-stech+json":{source:"iana",compressible:!0},"application/vnd.bint.med-content":{source:"iana"},"application/vnd.biopax.rdf+xml":{source:"iana",compressible:!0},"application/vnd.blink-idb-value-wrapper":{source:"iana"},"application/vnd.blueice.multipass":{source:"iana",extensions:["mpm"]},"application/vnd.bluetooth.ep.oob":{source:"iana"},"application/vnd.bluetooth.le.oob":{source:"iana"},"application/vnd.bmi":{source:"iana",extensions:["bmi"]},"application/vnd.businessobjects":{source:"iana",extensions:["rep"]},"application/vnd.byu.uapi+json":{source:"iana",compressible:!0},"application/vnd.cab-jscript":{source:"iana"},"application/vnd.canon-cpdl":{source:"iana"},"application/vnd.canon-lips":{source:"iana"},"application/vnd.capasystems-pg+json":{source:"iana",compressible:!0},"application/vnd.cendio.thinlinc.clientconf":{source:"iana"},"application/vnd.century-systems.tcp_stream":{source:"iana"},"application/vnd.chemdraw+xml":{source:"iana",compressible:!0,extensions:["cdxml"]},"application/vnd.chess-pgn":{source:"iana"},"application/vnd.chipnuts.karaoke-mmd":{source:"iana",extensions:["mmd"]},"application/vnd.cinderella":{source:"iana",extensions:["cdy"]},"application/vnd.cirpack.isdn-ext":{source:"iana"},"application/vnd.citationstyles.style+xml":{source:"iana",compressible:!0,extensions:["csl"]},"application/vnd.claymore":{source:"iana",extensions:["cla"]},"application/vnd.cloanto.rp9":{source:"iana",extensions:["rp9"]},"application/vnd.clonk.c4group":{source:"iana",extensions:["c4g","c4d","c4f","c4p","c4u"]},"application/vnd.cluetrust.cartomobile-config":{source:"iana",extensions:["c11amc"]},"application/vnd.cluetrust.cartomobile-config-pkg":{source:"iana",extensions:["c11amz"]},"application/vnd.coffeescript":{source:"iana"},"application/vnd.collabio.xodocuments.document":{source:"iana"},"application/vnd.collabio.xodocuments.document-template":{source:"iana"},"application/vnd.collabio.xodocuments.presentation":{source:"iana"},"application/vnd.collabio.xodocuments.presentation-template":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet":{source:"iana"},"application/vnd.collabio.xodocuments.spreadsheet-template":{source:"iana"},"application/vnd.collection+json":{source:"iana",compressible:!0},"application/vnd.collection.doc+json":{source:"iana",compressible:!0},"application/vnd.collection.next+json":{source:"iana",compressible:!0},"application/vnd.comicbook+zip":{source:"iana",compressible:!1},"application/vnd.comicbook-rar":{source:"iana"},"application/vnd.commerce-battelle":{source:"iana"},"application/vnd.commonspace":{source:"iana",extensions:["csp"]},"application/vnd.contact.cmsg":{source:"iana",extensions:["cdbcmsg"]},"application/vnd.coreos.ignition+json":{source:"iana",compressible:!0},"application/vnd.cosmocaller":{source:"iana",extensions:["cmc"]},"application/vnd.crick.clicker":{source:"iana",extensions:["clkx"]},"application/vnd.crick.clicker.keyboard":{source:"iana",extensions:["clkk"]},"application/vnd.crick.clicker.palette":{source:"iana",extensions:["clkp"]},"application/vnd.crick.clicker.template":{source:"iana",extensions:["clkt"]},"application/vnd.crick.clicker.wordbank":{source:"iana",extensions:["clkw"]},"application/vnd.criticaltools.wbs+xml":{source:"iana",compressible:!0,extensions:["wbs"]},"application/vnd.ctc-posml":{source:"iana",extensions:["pml"]},"application/vnd.ctct.ws+xml":{source:"iana",compressible:!0},"application/vnd.cups-pdf":{source:"iana"},"application/vnd.cups-postscript":{source:"iana"},"application/vnd.cups-ppd":{source:"iana",extensions:["ppd"]},"application/vnd.cups-raster":{source:"iana"},"application/vnd.cups-raw":{source:"iana"},"application/vnd.curl":{source:"iana"},"application/vnd.curl.car":{source:"apache",extensions:["car"]},"application/vnd.curl.pcurl":{source:"apache",extensions:["pcurl"]},"application/vnd.cyan.dean.root+xml":{source:"iana",compressible:!0},"application/vnd.cybank":{source:"iana"},"application/vnd.d2l.coursepackage1p0+zip":{source:"iana",compressible:!1},"application/vnd.dart":{source:"iana",compressible:!0,extensions:["dart"]},"application/vnd.data-vision.rdz":{source:"iana",extensions:["rdz"]},"application/vnd.datapackage+json":{source:"iana",compressible:!0},"application/vnd.dataresource+json":{source:"iana",compressible:!0},"application/vnd.debian.binary-package":{source:"iana"},"application/vnd.dece.data":{source:"iana",extensions:["uvf","uvvf","uvd","uvvd"]},"application/vnd.dece.ttml+xml":{source:"iana",compressible:!0,extensions:["uvt","uvvt"]},"application/vnd.dece.unspecified":{source:"iana",extensions:["uvx","uvvx"]},"application/vnd.dece.zip":{source:"iana",extensions:["uvz","uvvz"]},"application/vnd.denovo.fcselayout-link":{source:"iana",extensions:["fe_launch"]},"application/vnd.desmume.movie":{source:"iana"},"application/vnd.dir-bi.plate-dl-nosuffix":{source:"iana"},"application/vnd.dm.delegation+xml":{source:"iana",compressible:!0},"application/vnd.dna":{source:"iana",extensions:["dna"]},"application/vnd.document+json":{source:"iana",compressible:!0},"application/vnd.dolby.mlp":{source:"apache",extensions:["mlp"]},"application/vnd.dolby.mobile.1":{source:"iana"},"application/vnd.dolby.mobile.2":{source:"iana"},"application/vnd.doremir.scorecloud-binary-document":{source:"iana"},"application/vnd.dpgraph":{source:"iana",extensions:["dpg"]},"application/vnd.dreamfactory":{source:"iana",extensions:["dfac"]},"application/vnd.drive+json":{source:"iana",compressible:!0},"application/vnd.ds-keypoint":{source:"apache",extensions:["kpxx"]},"application/vnd.dtg.local":{source:"iana"},"application/vnd.dtg.local.flash":{source:"iana"},"application/vnd.dtg.local.html":{source:"iana"},"application/vnd.dvb.ait":{source:"iana",extensions:["ait"]},"application/vnd.dvb.dvbj":{source:"iana"},"application/vnd.dvb.esgcontainer":{source:"iana"},"application/vnd.dvb.ipdcdftnotifaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess":{source:"iana"},"application/vnd.dvb.ipdcesgaccess2":{source:"iana"},"application/vnd.dvb.ipdcesgpdd":{source:"iana"},"application/vnd.dvb.ipdcroaming":{source:"iana"},"application/vnd.dvb.iptv.alfec-base":{source:"iana"},"application/vnd.dvb.iptv.alfec-enhancement":{source:"iana"},"application/vnd.dvb.notif-aggregate-root+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-container+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-generic+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-msglist+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-request+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-ia-registration-response+xml":{source:"iana",compressible:!0},"application/vnd.dvb.notif-init+xml":{source:"iana",compressible:!0},"application/vnd.dvb.pfr":{source:"iana"},"application/vnd.dvb.service":{source:"iana",extensions:["svc"]},"application/vnd.dxr":{source:"iana"},"application/vnd.dynageo":{source:"iana",extensions:["geo"]},"application/vnd.dzr":{source:"iana"},"application/vnd.easykaraoke.cdgdownload":{source:"iana"},"application/vnd.ecdis-update":{source:"iana"},"application/vnd.ecip.rlp":{source:"iana"},"application/vnd.ecowin.chart":{source:"iana",extensions:["mag"]},"application/vnd.ecowin.filerequest":{source:"iana"},"application/vnd.ecowin.fileupdate":{source:"iana"},"application/vnd.ecowin.series":{source:"iana"},"application/vnd.ecowin.seriesrequest":{source:"iana"},"application/vnd.ecowin.seriesupdate":{source:"iana"},"application/vnd.efi.img":{source:"iana"},"application/vnd.efi.iso":{source:"iana"},"application/vnd.emclient.accessrequest+xml":{source:"iana",compressible:!0},"application/vnd.enliven":{source:"iana",extensions:["nml"]},"application/vnd.enphase.envoy":{source:"iana"},"application/vnd.eprints.data+xml":{source:"iana",compressible:!0},"application/vnd.epson.esf":{source:"iana",extensions:["esf"]},"application/vnd.epson.msf":{source:"iana",extensions:["msf"]},"application/vnd.epson.quickanime":{source:"iana",extensions:["qam"]},"application/vnd.epson.salt":{source:"iana",extensions:["slt"]},"application/vnd.epson.ssf":{source:"iana",extensions:["ssf"]},"application/vnd.ericsson.quickcall":{source:"iana"},"application/vnd.espass-espass+zip":{source:"iana",compressible:!1},"application/vnd.eszigno3+xml":{source:"iana",compressible:!0,extensions:["es3","et3"]},"application/vnd.etsi.aoc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.asic-e+zip":{source:"iana",compressible:!1},"application/vnd.etsi.asic-s+zip":{source:"iana",compressible:!1},"application/vnd.etsi.cug+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvcommand+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-bc+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-cod+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsad-npvr+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvservice+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvsync+xml":{source:"iana",compressible:!0},"application/vnd.etsi.iptvueprofile+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mcid+xml":{source:"iana",compressible:!0},"application/vnd.etsi.mheg5":{source:"iana"},"application/vnd.etsi.overload-control-policy-dataset+xml":{source:"iana",compressible:!0},"application/vnd.etsi.pstn+xml":{source:"iana",compressible:!0},"application/vnd.etsi.sci+xml":{source:"iana",compressible:!0},"application/vnd.etsi.simservs+xml":{source:"iana",compressible:!0},"application/vnd.etsi.timestamp-token":{source:"iana"},"application/vnd.etsi.tsl+xml":{source:"iana",compressible:!0},"application/vnd.etsi.tsl.der":{source:"iana"},"application/vnd.eudora.data":{source:"iana"},"application/vnd.evolv.ecig.profile":{source:"iana"},"application/vnd.evolv.ecig.settings":{source:"iana"},"application/vnd.evolv.ecig.theme":{source:"iana"},"application/vnd.exstream-empower+zip":{source:"iana",compressible:!1},"application/vnd.exstream-package":{source:"iana"},"application/vnd.ezpix-album":{source:"iana",extensions:["ez2"]},"application/vnd.ezpix-package":{source:"iana",extensions:["ez3"]},"application/vnd.f-secure.mobile":{source:"iana"},"application/vnd.fastcopy-disk-image":{source:"iana"},"application/vnd.fdf":{source:"iana",extensions:["fdf"]},"application/vnd.fdsn.mseed":{source:"iana",extensions:["mseed"]},"application/vnd.fdsn.seed":{source:"iana",extensions:["seed","dataless"]},"application/vnd.ffsns":{source:"iana"},"application/vnd.filmit.zfc":{source:"iana"},"application/vnd.fints":{source:"iana"},"application/vnd.firemonkeys.cloudcell":{source:"iana"},"application/vnd.flographit":{source:"iana",extensions:["gph"]},"application/vnd.fluxtime.clip":{source:"iana",extensions:["ftc"]},"application/vnd.font-fontforge-sfd":{source:"iana"},"application/vnd.framemaker":{source:"iana",extensions:["fm","frame","maker","book"]},"application/vnd.frogans.fnc":{source:"iana",extensions:["fnc"]},"application/vnd.frogans.ltf":{source:"iana",extensions:["ltf"]},"application/vnd.fsc.weblaunch":{source:"iana",extensions:["fsc"]},"application/vnd.fujitsu.oasys":{source:"iana",extensions:["oas"]},"application/vnd.fujitsu.oasys2":{source:"iana",extensions:["oa2"]},"application/vnd.fujitsu.oasys3":{source:"iana",extensions:["oa3"]},"application/vnd.fujitsu.oasysgp":{source:"iana",extensions:["fg5"]},"application/vnd.fujitsu.oasysprs":{source:"iana",extensions:["bh2"]},"application/vnd.fujixerox.art-ex":{source:"iana"},"application/vnd.fujixerox.art4":{source:"iana"},"application/vnd.fujixerox.ddd":{source:"iana",extensions:["ddd"]},"application/vnd.fujixerox.docuworks":{source:"iana",extensions:["xdw"]},"application/vnd.fujixerox.docuworks.binder":{source:"iana",extensions:["xbd"]},"application/vnd.fujixerox.docuworks.container":{source:"iana"},"application/vnd.fujixerox.hbpl":{source:"iana"},"application/vnd.fut-misnet":{source:"iana"},"application/vnd.futoin+cbor":{source:"iana"},"application/vnd.futoin+json":{source:"iana",compressible:!0},"application/vnd.fuzzysheet":{source:"iana",extensions:["fzs"]},"application/vnd.genomatix.tuxedo":{source:"iana",extensions:["txd"]},"application/vnd.geo+json":{source:"iana",compressible:!0},"application/vnd.geocube+xml":{source:"iana",compressible:!0},"application/vnd.geogebra.file":{source:"iana",extensions:["ggb"]},"application/vnd.geogebra.tool":{source:"iana",extensions:["ggt"]},"application/vnd.geometry-explorer":{source:"iana",extensions:["gex","gre"]},"application/vnd.geonext":{source:"iana",extensions:["gxt"]},"application/vnd.geoplan":{source:"iana",extensions:["g2w"]},"application/vnd.geospace":{source:"iana",extensions:["g3w"]},"application/vnd.gerber":{source:"iana"},"application/vnd.globalplatform.card-content-mgt":{source:"iana"},"application/vnd.globalplatform.card-content-mgt-response":{source:"iana"},"application/vnd.gmx":{source:"iana",extensions:["gmx"]},"application/vnd.google-apps.document":{compressible:!1,extensions:["gdoc"]},"application/vnd.google-apps.presentation":{compressible:!1,extensions:["gslides"]},"application/vnd.google-apps.spreadsheet":{compressible:!1,extensions:["gsheet"]},"application/vnd.google-earth.kml+xml":{source:"iana",compressible:!0,extensions:["kml"]},"application/vnd.google-earth.kmz":{source:"iana",compressible:!1,extensions:["kmz"]},"application/vnd.gov.sk.e-form+xml":{source:"iana",compressible:!0},"application/vnd.gov.sk.e-form+zip":{source:"iana",compressible:!1},"application/vnd.gov.sk.xmldatacontainer+xml":{source:"iana",compressible:!0},"application/vnd.grafeq":{source:"iana",extensions:["gqf","gqs"]},"application/vnd.gridmp":{source:"iana"},"application/vnd.groove-account":{source:"iana",extensions:["gac"]},"application/vnd.groove-help":{source:"iana",extensions:["ghf"]},"application/vnd.groove-identity-message":{source:"iana",extensions:["gim"]},"application/vnd.groove-injector":{source:"iana",extensions:["grv"]},"application/vnd.groove-tool-message":{source:"iana",extensions:["gtm"]},"application/vnd.groove-tool-template":{source:"iana",extensions:["tpl"]},"application/vnd.groove-vcard":{source:"iana",extensions:["vcg"]},"application/vnd.hal+json":{source:"iana",compressible:!0},"application/vnd.hal+xml":{source:"iana",compressible:!0,extensions:["hal"]},"application/vnd.handheld-entertainment+xml":{source:"iana",compressible:!0,extensions:["zmm"]},"application/vnd.hbci":{source:"iana",extensions:["hbci"]},"application/vnd.hc+json":{source:"iana",compressible:!0},"application/vnd.hcl-bireports":{source:"iana"},"application/vnd.hdt":{source:"iana"},"application/vnd.heroku+json":{source:"iana",compressible:!0},"application/vnd.hhe.lesson-player":{source:"iana",extensions:["les"]},"application/vnd.hp-hpgl":{source:"iana",extensions:["hpgl"]},"application/vnd.hp-hpid":{source:"iana",extensions:["hpid"]},"application/vnd.hp-hps":{source:"iana",extensions:["hps"]},"application/vnd.hp-jlyt":{source:"iana",extensions:["jlt"]},"application/vnd.hp-pcl":{source:"iana",extensions:["pcl"]},"application/vnd.hp-pclxl":{source:"iana",extensions:["pclxl"]},"application/vnd.httphone":{source:"iana"},"application/vnd.hydrostatix.sof-data":{source:"iana",extensions:["sfd-hdstx"]},"application/vnd.hyper+json":{source:"iana",compressible:!0},"application/vnd.hyper-item+json":{source:"iana",compressible:!0},"application/vnd.hyperdrive+json":{source:"iana",compressible:!0},"application/vnd.hzn-3d-crossword":{source:"iana"},"application/vnd.ibm.afplinedata":{source:"iana"},"application/vnd.ibm.electronic-media":{source:"iana"},"application/vnd.ibm.minipay":{source:"iana",extensions:["mpy"]},"application/vnd.ibm.modcap":{source:"iana",extensions:["afp","listafp","list3820"]},"application/vnd.ibm.rights-management":{source:"iana",extensions:["irm"]},"application/vnd.ibm.secure-container":{source:"iana",extensions:["sc"]},"application/vnd.iccprofile":{source:"iana",extensions:["icc","icm"]},"application/vnd.ieee.1905":{source:"iana"},"application/vnd.igloader":{source:"iana",extensions:["igl"]},"application/vnd.imagemeter.folder+zip":{source:"iana",compressible:!1},"application/vnd.imagemeter.image+zip":{source:"iana",compressible:!1},"application/vnd.immervision-ivp":{source:"iana",extensions:["ivp"]},"application/vnd.immervision-ivu":{source:"iana",extensions:["ivu"]},"application/vnd.ims.imsccv1p1":{source:"iana"},"application/vnd.ims.imsccv1p2":{source:"iana"},"application/vnd.ims.imsccv1p3":{source:"iana"},"application/vnd.ims.lis.v2.result+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolconsumerprofile+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolproxy.id+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings+json":{source:"iana",compressible:!0},"application/vnd.ims.lti.v2.toolsettings.simple+json":{source:"iana",compressible:!0},"application/vnd.informedcontrol.rms+xml":{source:"iana",compressible:!0},"application/vnd.informix-visionary":{source:"iana"},"application/vnd.infotech.project":{source:"iana"},"application/vnd.infotech.project+xml":{source:"iana",compressible:!0},"application/vnd.innopath.wamp.notification":{source:"iana"},"application/vnd.insors.igm":{source:"iana",extensions:["igm"]},"application/vnd.intercon.formnet":{source:"iana",extensions:["xpw","xpx"]},"application/vnd.intergeo":{source:"iana",extensions:["i2g"]},"application/vnd.intertrust.digibox":{source:"iana"},"application/vnd.intertrust.nncp":{source:"iana"},"application/vnd.intu.qbo":{source:"iana",extensions:["qbo"]},"application/vnd.intu.qfx":{source:"iana",extensions:["qfx"]},"application/vnd.iptc.g2.catalogitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.conceptitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.knowledgeitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.newsmessage+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.packageitem+xml":{source:"iana",compressible:!0},"application/vnd.iptc.g2.planningitem+xml":{source:"iana",compressible:!0},"application/vnd.ipunplugged.rcprofile":{source:"iana",extensions:["rcprofile"]},"application/vnd.irepository.package+xml":{source:"iana",compressible:!0,extensions:["irp"]},"application/vnd.is-xpr":{source:"iana",extensions:["xpr"]},"application/vnd.isac.fcs":{source:"iana",extensions:["fcs"]},"application/vnd.jam":{source:"iana",extensions:["jam"]},"application/vnd.japannet-directory-service":{source:"iana"},"application/vnd.japannet-jpnstore-wakeup":{source:"iana"},"application/vnd.japannet-payment-wakeup":{source:"iana"},"application/vnd.japannet-registration":{source:"iana"},"application/vnd.japannet-registration-wakeup":{source:"iana"},"application/vnd.japannet-setstore-wakeup":{source:"iana"},"application/vnd.japannet-verification":{source:"iana"},"application/vnd.japannet-verification-wakeup":{source:"iana"},"application/vnd.jcp.javame.midlet-rms":{source:"iana",extensions:["rms"]},"application/vnd.jisp":{source:"iana",extensions:["jisp"]},"application/vnd.joost.joda-archive":{source:"iana",extensions:["joda"]},"application/vnd.jsk.isdn-ngn":{source:"iana"},"application/vnd.kahootz":{source:"iana",extensions:["ktz","ktr"]},"application/vnd.kde.karbon":{source:"iana",extensions:["karbon"]},"application/vnd.kde.kchart":{source:"iana",extensions:["chrt"]},"application/vnd.kde.kformula":{source:"iana",extensions:["kfo"]},"application/vnd.kde.kivio":{source:"iana",extensions:["flw"]},"application/vnd.kde.kontour":{source:"iana",extensions:["kon"]},"application/vnd.kde.kpresenter":{source:"iana",extensions:["kpr","kpt"]},"application/vnd.kde.kspread":{source:"iana",extensions:["ksp"]},"application/vnd.kde.kword":{source:"iana",extensions:["kwd","kwt"]},"application/vnd.kenameaapp":{source:"iana",extensions:["htke"]},"application/vnd.kidspiration":{source:"iana",extensions:["kia"]},"application/vnd.kinar":{source:"iana",extensions:["kne","knp"]},"application/vnd.koan":{source:"iana",extensions:["skp","skd","skt","skm"]},"application/vnd.kodak-descriptor":{source:"iana",extensions:["sse"]},"application/vnd.las.las+json":{source:"iana",compressible:!0},"application/vnd.las.las+xml":{source:"iana",compressible:!0,extensions:["lasxml"]},"application/vnd.leap+json":{source:"iana",compressible:!0},"application/vnd.liberty-request+xml":{source:"iana",compressible:!0},"application/vnd.llamagraphics.life-balance.desktop":{source:"iana",extensions:["lbd"]},"application/vnd.llamagraphics.life-balance.exchange+xml":{source:"iana",compressible:!0,extensions:["lbe"]},"application/vnd.lotus-1-2-3":{source:"iana",extensions:["123"]},"application/vnd.lotus-approach":{source:"iana",extensions:["apr"]},"application/vnd.lotus-freelance":{source:"iana",extensions:["pre"]},"application/vnd.lotus-notes":{source:"iana",extensions:["nsf"]},"application/vnd.lotus-organizer":{source:"iana",extensions:["org"]},"application/vnd.lotus-screencam":{source:"iana",extensions:["scm"]},"application/vnd.lotus-wordpro":{source:"iana",extensions:["lwp"]},"application/vnd.macports.portpkg":{source:"iana",extensions:["portpkg"]},"application/vnd.mapbox-vector-tile":{source:"iana"},"application/vnd.marlin.drm.actiontoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.conftoken+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.license+xml":{source:"iana",compressible:!0},"application/vnd.marlin.drm.mdcf":{source:"iana"},"application/vnd.mason+json":{source:"iana",compressible:!0},"application/vnd.maxmind.maxmind-db":{source:"iana"},"application/vnd.mcd":{source:"iana",extensions:["mcd"]},"application/vnd.medcalcdata":{source:"iana",extensions:["mc1"]},"application/vnd.mediastation.cdkey":{source:"iana",extensions:["cdkey"]},"application/vnd.meridian-slingshot":{source:"iana"},"application/vnd.mfer":{source:"iana",extensions:["mwf"]},"application/vnd.mfmp":{source:"iana",extensions:["mfm"]},"application/vnd.micro+json":{source:"iana",compressible:!0},"application/vnd.micrografx.flo":{source:"iana",extensions:["flo"]},"application/vnd.micrografx.igx":{source:"iana",extensions:["igx"]},"application/vnd.microsoft.portable-executable":{source:"iana"},"application/vnd.microsoft.windows.thumbnail-cache":{source:"iana"},"application/vnd.miele+json":{source:"iana",compressible:!0},"application/vnd.mif":{source:"iana",extensions:["mif"]},"application/vnd.minisoft-hp3000-save":{source:"iana"},"application/vnd.mitsubishi.misty-guard.trustweb":{source:"iana"},"application/vnd.mobius.daf":{source:"iana",extensions:["daf"]},"application/vnd.mobius.dis":{source:"iana",extensions:["dis"]},"application/vnd.mobius.mbk":{source:"iana",extensions:["mbk"]},"application/vnd.mobius.mqy":{source:"iana",extensions:["mqy"]},"application/vnd.mobius.msl":{source:"iana",extensions:["msl"]},"application/vnd.mobius.plc":{source:"iana",extensions:["plc"]},"application/vnd.mobius.txf":{source:"iana",extensions:["txf"]},"application/vnd.mophun.application":{source:"iana",extensions:["mpn"]},"application/vnd.mophun.certificate":{source:"iana",extensions:["mpc"]},"application/vnd.motorola.flexsuite":{source:"iana"},"application/vnd.motorola.flexsuite.adsi":{source:"iana"},"application/vnd.motorola.flexsuite.fis":{source:"iana"},"application/vnd.motorola.flexsuite.gotap":{source:"iana"},"application/vnd.motorola.flexsuite.kmr":{source:"iana"},"application/vnd.motorola.flexsuite.ttc":{source:"iana"},"application/vnd.motorola.flexsuite.wem":{source:"iana"},"application/vnd.motorola.iprm":{source:"iana"},"application/vnd.mozilla.xul+xml":{source:"iana",compressible:!0,extensions:["xul"]},"application/vnd.ms-3mfdocument":{source:"iana"},"application/vnd.ms-artgalry":{source:"iana",extensions:["cil"]},"application/vnd.ms-asf":{source:"iana"},"application/vnd.ms-cab-compressed":{source:"iana",extensions:["cab"]},"application/vnd.ms-color.iccprofile":{source:"apache"},"application/vnd.ms-excel":{source:"iana",compressible:!1,extensions:["xls","xlm","xla","xlc","xlt","xlw"]},"application/vnd.ms-excel.addin.macroenabled.12":{source:"iana",extensions:["xlam"]},"application/vnd.ms-excel.sheet.binary.macroenabled.12":{source:"iana",extensions:["xlsb"]},"application/vnd.ms-excel.sheet.macroenabled.12":{source:"iana",extensions:["xlsm"]},"application/vnd.ms-excel.template.macroenabled.12":{source:"iana",extensions:["xltm"]},"application/vnd.ms-fontobject":{source:"iana",compressible:!0,extensions:["eot"]},"application/vnd.ms-htmlhelp":{source:"iana",extensions:["chm"]},"application/vnd.ms-ims":{source:"iana",extensions:["ims"]},"application/vnd.ms-lrm":{source:"iana",extensions:["lrm"]},"application/vnd.ms-office.activex+xml":{source:"iana",compressible:!0},"application/vnd.ms-officetheme":{source:"iana",extensions:["thmx"]},"application/vnd.ms-opentype":{source:"apache",compressible:!0},"application/vnd.ms-outlook":{compressible:!1,extensions:["msg"]},"application/vnd.ms-package.obfuscated-opentype":{source:"apache"},"application/vnd.ms-pki.seccat":{source:"apache",extensions:["cat"]},"application/vnd.ms-pki.stl":{source:"apache",extensions:["stl"]},"application/vnd.ms-playready.initiator+xml":{source:"iana",compressible:!0},"application/vnd.ms-powerpoint":{source:"iana",compressible:!1,extensions:["ppt","pps","pot"]},"application/vnd.ms-powerpoint.addin.macroenabled.12":{source:"iana",extensions:["ppam"]},"application/vnd.ms-powerpoint.presentation.macroenabled.12":{source:"iana",extensions:["pptm"]},"application/vnd.ms-powerpoint.slide.macroenabled.12":{source:"iana",extensions:["sldm"]},"application/vnd.ms-powerpoint.slideshow.macroenabled.12":{source:"iana",extensions:["ppsm"]},"application/vnd.ms-powerpoint.template.macroenabled.12":{source:"iana",extensions:["potm"]},"application/vnd.ms-printdevicecapabilities+xml":{source:"iana",compressible:!0},"application/vnd.ms-printing.printticket+xml":{source:"apache",compressible:!0},"application/vnd.ms-printschematicket+xml":{source:"iana",compressible:!0},"application/vnd.ms-project":{source:"iana",extensions:["mpp","mpt"]},"application/vnd.ms-tnef":{source:"iana"},"application/vnd.ms-windows.devicepairing":{source:"iana"},"application/vnd.ms-windows.nwprinting.oob":{source:"iana"},"application/vnd.ms-windows.printerpairing":{source:"iana"},"application/vnd.ms-windows.wsd.oob":{source:"iana"},"application/vnd.ms-wmdrm.lic-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.lic-resp":{source:"iana"},"application/vnd.ms-wmdrm.meter-chlg-req":{source:"iana"},"application/vnd.ms-wmdrm.meter-resp":{source:"iana"},"application/vnd.ms-word.document.macroenabled.12":{source:"iana",extensions:["docm"]},"application/vnd.ms-word.template.macroenabled.12":{source:"iana",extensions:["dotm"]},"application/vnd.ms-works":{source:"iana",extensions:["wps","wks","wcm","wdb"]},"application/vnd.ms-wpl":{source:"iana",extensions:["wpl"]},"application/vnd.ms-xpsdocument":{source:"iana",compressible:!1,extensions:["xps"]},"application/vnd.msa-disk-image":{source:"iana"},"application/vnd.mseq":{source:"iana",extensions:["mseq"]},"application/vnd.msign":{source:"iana"},"application/vnd.multiad.creator":{source:"iana"},"application/vnd.multiad.creator.cif":{source:"iana"},"application/vnd.music-niff":{source:"iana"},"application/vnd.musician":{source:"iana",extensions:["mus"]},"application/vnd.muvee.style":{source:"iana",extensions:["msty"]},"application/vnd.mynfc":{source:"iana",extensions:["taglet"]},"application/vnd.ncd.control":{source:"iana"},"application/vnd.ncd.reference":{source:"iana"},"application/vnd.nearst.inv+json":{source:"iana",compressible:!0},"application/vnd.nervana":{source:"iana"},"application/vnd.netfpx":{source:"iana"},"application/vnd.neurolanguage.nlu":{source:"iana",extensions:["nlu"]},"application/vnd.nimn":{source:"iana"},"application/vnd.nintendo.nitro.rom":{source:"iana"},"application/vnd.nintendo.snes.rom":{source:"iana"},"application/vnd.nitf":{source:"iana",extensions:["ntf","nitf"]},"application/vnd.noblenet-directory":{source:"iana",extensions:["nnd"]},"application/vnd.noblenet-sealer":{source:"iana",extensions:["nns"]},"application/vnd.noblenet-web":{source:"iana",extensions:["nnw"]},"application/vnd.nokia.catalogs":{source:"iana"},"application/vnd.nokia.conml+wbxml":{source:"iana"},"application/vnd.nokia.conml+xml":{source:"iana",compressible:!0},"application/vnd.nokia.iptv.config+xml":{source:"iana",compressible:!0},"application/vnd.nokia.isds-radio-presets":{source:"iana"},"application/vnd.nokia.landmark+wbxml":{source:"iana"},"application/vnd.nokia.landmark+xml":{source:"iana",compressible:!0},"application/vnd.nokia.landmarkcollection+xml":{source:"iana",compressible:!0},"application/vnd.nokia.n-gage.ac+xml":{source:"iana",compressible:!0},"application/vnd.nokia.n-gage.data":{source:"iana",extensions:["ngdat"]},"application/vnd.nokia.n-gage.symbian.install":{source:"iana",extensions:["n-gage"]},"application/vnd.nokia.ncd":{source:"iana"},"application/vnd.nokia.pcd+wbxml":{source:"iana"},"application/vnd.nokia.pcd+xml":{source:"iana",compressible:!0},"application/vnd.nokia.radio-preset":{source:"iana",extensions:["rpst"]},"application/vnd.nokia.radio-presets":{source:"iana",extensions:["rpss"]},"application/vnd.novadigm.edm":{source:"iana",extensions:["edm"]},"application/vnd.novadigm.edx":{source:"iana",extensions:["edx"]},"application/vnd.novadigm.ext":{source:"iana",extensions:["ext"]},"application/vnd.ntt-local.content-share":{source:"iana"},"application/vnd.ntt-local.file-transfer":{source:"iana"},"application/vnd.ntt-local.ogw_remote-access":{source:"iana"},"application/vnd.ntt-local.sip-ta_remote":{source:"iana"},"application/vnd.ntt-local.sip-ta_tcp_stream":{source:"iana"},"application/vnd.oasis.opendocument.chart":{source:"iana",extensions:["odc"]},"application/vnd.oasis.opendocument.chart-template":{source:"iana",extensions:["otc"]},"application/vnd.oasis.opendocument.database":{source:"iana",extensions:["odb"]},"application/vnd.oasis.opendocument.formula":{source:"iana",extensions:["odf"]},"application/vnd.oasis.opendocument.formula-template":{source:"iana",extensions:["odft"]},"application/vnd.oasis.opendocument.graphics":{source:"iana",compressible:!1,extensions:["odg"]},"application/vnd.oasis.opendocument.graphics-template":{source:"iana",extensions:["otg"]},"application/vnd.oasis.opendocument.image":{source:"iana",extensions:["odi"]},"application/vnd.oasis.opendocument.image-template":{source:"iana",extensions:["oti"]},"application/vnd.oasis.opendocument.presentation":{source:"iana",compressible:!1,extensions:["odp"]},"application/vnd.oasis.opendocument.presentation-template":{source:"iana",extensions:["otp"]},"application/vnd.oasis.opendocument.spreadsheet":{source:"iana",compressible:!1,extensions:["ods"]},"application/vnd.oasis.opendocument.spreadsheet-template":{source:"iana",extensions:["ots"]},"application/vnd.oasis.opendocument.text":{source:"iana",compressible:!1,extensions:["odt"]},"application/vnd.oasis.opendocument.text-master":{source:"iana",extensions:["odm"]},"application/vnd.oasis.opendocument.text-template":{source:"iana",extensions:["ott"]},"application/vnd.oasis.opendocument.text-web":{source:"iana",extensions:["oth"]},"application/vnd.obn":{source:"iana"},"application/vnd.ocf+cbor":{source:"iana"},"application/vnd.oftn.l10n+json":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessdownload+xml":{source:"iana",compressible:!0},"application/vnd.oipf.contentaccessstreaming+xml":{source:"iana",compressible:!0},"application/vnd.oipf.cspg-hexbinary":{source:"iana"},"application/vnd.oipf.dae.svg+xml":{source:"iana",compressible:!0},"application/vnd.oipf.dae.xhtml+xml":{source:"iana",compressible:!0},"application/vnd.oipf.mippvcontrolmessage+xml":{source:"iana",compressible:!0},"application/vnd.oipf.pae.gem":{source:"iana"},"application/vnd.oipf.spdiscovery+xml":{source:"iana",compressible:!0},"application/vnd.oipf.spdlist+xml":{source:"iana",compressible:!0},"application/vnd.oipf.ueprofile+xml":{source:"iana",compressible:!0},"application/vnd.oipf.userprofile+xml":{source:"iana",compressible:!0},"application/vnd.olpc-sugar":{source:"iana",extensions:["xo"]},"application/vnd.oma-scws-config":{source:"iana"},"application/vnd.oma-scws-http-request":{source:"iana"},"application/vnd.oma-scws-http-response":{source:"iana"},"application/vnd.oma.bcast.associated-procedure-parameter+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.drm-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.imd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.ltkm":{source:"iana"},"application/vnd.oma.bcast.notification+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.provisioningtrigger":{source:"iana"},"application/vnd.oma.bcast.sgboot":{source:"iana"},"application/vnd.oma.bcast.sgdd+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sgdu":{source:"iana"},"application/vnd.oma.bcast.simple-symbol-container":{source:"iana"},"application/vnd.oma.bcast.smartcard-trigger+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.sprov+xml":{source:"iana",compressible:!0},"application/vnd.oma.bcast.stkm":{source:"iana"},"application/vnd.oma.cab-address-book+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-feature-handler+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-pcc+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-subs-invite+xml":{source:"iana",compressible:!0},"application/vnd.oma.cab-user-prefs+xml":{source:"iana",compressible:!0},"application/vnd.oma.dcd":{source:"iana"},"application/vnd.oma.dcdc":{source:"iana"},"application/vnd.oma.dd2+xml":{source:"iana",compressible:!0,extensions:["dd2"]},"application/vnd.oma.drm.risd+xml":{source:"iana",compressible:!0},"application/vnd.oma.group-usage-list+xml":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+json":{source:"iana",compressible:!0},"application/vnd.oma.lwm2m+tlv":{source:"iana"},"application/vnd.oma.pal+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.detailed-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.final-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.groups+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.invocation-descriptor+xml":{source:"iana",compressible:!0},"application/vnd.oma.poc.optimized-progress-report+xml":{source:"iana",compressible:!0},"application/vnd.oma.push":{source:"iana"},"application/vnd.oma.scidm.messages+xml":{source:"iana",compressible:!0},"application/vnd.oma.xcap-directory+xml":{source:"iana",compressible:!0},"application/vnd.omads-email+xml":{source:"iana",compressible:!0},"application/vnd.omads-file+xml":{source:"iana",compressible:!0},"application/vnd.omads-folder+xml":{source:"iana",compressible:!0},"application/vnd.omaloc-supl-init":{source:"iana"},"application/vnd.onepager":{source:"iana"},"application/vnd.onepagertamp":{source:"iana"},"application/vnd.onepagertamx":{source:"iana"},"application/vnd.onepagertat":{source:"iana"},"application/vnd.onepagertatp":{source:"iana"},"application/vnd.onepagertatx":{source:"iana"},"application/vnd.openblox.game+xml":{source:"iana",compressible:!0},"application/vnd.openblox.game-binary":{source:"iana"},"application/vnd.openeye.oeb":{source:"iana"},"application/vnd.openofficeorg.extension":{source:"apache",extensions:["oxt"]},"application/vnd.openstreetmap.data+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.custom-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.customxmlproperties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawing+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chart+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.chartshapes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramcolors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramdata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramlayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.drawingml.diagramstyle+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.extended-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.commentauthors+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.handoutmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesmaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.notesslide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presentation":{source:"iana",compressible:!1,extensions:["pptx"]},"application/vnd.openxmlformats-officedocument.presentationml.presentation.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.presprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slide":{source:"iana",extensions:["sldx"]},"application/vnd.openxmlformats-officedocument.presentationml.slide+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidelayout+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slidemaster+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideshow":{source:"iana",extensions:["ppsx"]},"application/vnd.openxmlformats-officedocument.presentationml.slideshow.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.slideupdateinfo+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tablestyles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.tags+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.template":{source:"iana",extensions:["potx"]},"application/vnd.openxmlformats-officedocument.presentationml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.presentationml.viewprops+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.calcchain+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.chartsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.connections+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.dialogsheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.externallink+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcachedefinition+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivotcacherecords+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.pivottable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.querytable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionheaders+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.revisionlog+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedstrings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{source:"iana",compressible:!1,extensions:["xlsx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheetmetadata+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.tablesinglecells+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.template":{source:"iana",extensions:["xltx"]},"application/vnd.openxmlformats-officedocument.spreadsheetml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.usernames+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.volatiledependencies+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.theme+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.themeoverride+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.vmldrawing":{source:"iana"},"application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{source:"iana",compressible:!1,extensions:["docx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.glossary+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.endnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.fonttable+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.footnotes+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.numbering+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.settings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.template":{source:"iana",extensions:["dotx"]},"application/vnd.openxmlformats-officedocument.wordprocessingml.template.main+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-officedocument.wordprocessingml.websettings+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.core-properties+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.digital-signature-xmlsignature+xml":{source:"iana",compressible:!0},"application/vnd.openxmlformats-package.relationships+xml":{source:"iana",compressible:!0},"application/vnd.oracle.resource+json":{source:"iana",compressible:!0},"application/vnd.orange.indata":{source:"iana"},"application/vnd.osa.netdeploy":{source:"iana"},"application/vnd.osgeo.mapguide.package":{source:"iana",extensions:["mgp"]},"application/vnd.osgi.bundle":{source:"iana"},"application/vnd.osgi.dp":{source:"iana",extensions:["dp"]},"application/vnd.osgi.subsystem":{source:"iana",extensions:["esa"]},"application/vnd.otps.ct-kip+xml":{source:"iana",compressible:!0},"application/vnd.oxli.countgraph":{source:"iana"},"application/vnd.pagerduty+json":{source:"iana",compressible:!0},"application/vnd.palm":{source:"iana",extensions:["pdb","pqa","oprc"]},"application/vnd.panoply":{source:"iana"},"application/vnd.paos.xml":{source:"iana"},"application/vnd.patentdive":{source:"iana"},"application/vnd.patientecommsdoc":{source:"iana"},"application/vnd.pawaafile":{source:"iana",extensions:["paw"]},"application/vnd.pcos":{source:"iana"},"application/vnd.pg.format":{source:"iana",extensions:["str"]},"application/vnd.pg.osasli":{source:"iana",extensions:["ei6"]},"application/vnd.piaccess.application-licence":{source:"iana"},"application/vnd.picsel":{source:"iana",extensions:["efif"]},"application/vnd.pmi.widget":{source:"iana",extensions:["wg"]},"application/vnd.poc.group-advertisement+xml":{source:"iana",compressible:!0},"application/vnd.pocketlearn":{source:"iana",extensions:["plf"]},"application/vnd.powerbuilder6":{source:"iana",extensions:["pbd"]},"application/vnd.powerbuilder6-s":{source:"iana"},"application/vnd.powerbuilder7":{source:"iana"},"application/vnd.powerbuilder7-s":{source:"iana"},"application/vnd.powerbuilder75":{source:"iana"},"application/vnd.powerbuilder75-s":{source:"iana"},"application/vnd.preminet":{source:"iana"},"application/vnd.previewsystems.box":{source:"iana",extensions:["box"]},"application/vnd.proteus.magazine":{source:"iana",extensions:["mgz"]},"application/vnd.psfs":{source:"iana"},"application/vnd.publishare-delta-tree":{source:"iana",extensions:["qps"]},"application/vnd.pvi.ptid1":{source:"iana",extensions:["ptid"]},"application/vnd.pwg-multiplexed":{source:"iana"},"application/vnd.pwg-xhtml-print+xml":{source:"iana",compressible:!0},"application/vnd.qualcomm.brew-app-res":{source:"iana"},"application/vnd.quarantainenet":{source:"iana"},"application/vnd.quark.quarkxpress":{source:"iana",extensions:["qxd","qxt","qwd","qwt","qxl","qxb"]},"application/vnd.quobject-quoxdocument":{source:"iana"},"application/vnd.radisys.moml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-conn+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-audit-stream+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-conf+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-base+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-detect+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-fax-sendrecv+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-group+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-speech+xml":{source:"iana",compressible:!0},"application/vnd.radisys.msml-dialog-transform+xml":{source:"iana",compressible:!0},"application/vnd.rainstor.data":{source:"iana"},"application/vnd.rapid":{source:"iana"},"application/vnd.rar":{source:"iana"},"application/vnd.realvnc.bed":{source:"iana",extensions:["bed"]},"application/vnd.recordare.musicxml":{source:"iana",extensions:["mxl"]},"application/vnd.recordare.musicxml+xml":{source:"iana",compressible:!0,extensions:["musicxml"]},"application/vnd.renlearn.rlprint":{source:"iana"},"application/vnd.restful+json":{source:"iana",compressible:!0},"application/vnd.rig.cryptonote":{source:"iana",extensions:["cryptonote"]},"application/vnd.rim.cod":{source:"apache",extensions:["cod"]},"application/vnd.rn-realmedia":{source:"apache",extensions:["rm"]},"application/vnd.rn-realmedia-vbr":{source:"apache",extensions:["rmvb"]},"application/vnd.route66.link66+xml":{source:"iana",compressible:!0,extensions:["link66"]},"application/vnd.rs-274x":{source:"iana"},"application/vnd.ruckus.download":{source:"iana"},"application/vnd.s3sms":{source:"iana"},"application/vnd.sailingtracker.track":{source:"iana",extensions:["st"]},"application/vnd.sbm.cid":{source:"iana"},"application/vnd.sbm.mid2":{source:"iana"},"application/vnd.scribus":{source:"iana"},"application/vnd.sealed.3df":{source:"iana"},"application/vnd.sealed.csf":{source:"iana"},"application/vnd.sealed.doc":{source:"iana"},"application/vnd.sealed.eml":{source:"iana"},"application/vnd.sealed.mht":{source:"iana"},"application/vnd.sealed.net":{source:"iana"},"application/vnd.sealed.ppt":{source:"iana"},"application/vnd.sealed.tiff":{source:"iana"},"application/vnd.sealed.xls":{source:"iana"},"application/vnd.sealedmedia.softseal.html":{source:"iana"},"application/vnd.sealedmedia.softseal.pdf":{source:"iana"},"application/vnd.seemail":{source:"iana",extensions:["see"]},"application/vnd.sema":{source:"iana",extensions:["sema"]},"application/vnd.semd":{source:"iana",extensions:["semd"]},"application/vnd.semf":{source:"iana",extensions:["semf"]},"application/vnd.shana.informed.formdata":{source:"iana",extensions:["ifm"]},"application/vnd.shana.informed.formtemplate":{source:"iana",extensions:["itp"]},"application/vnd.shana.informed.interchange":{source:"iana",extensions:["iif"]},"application/vnd.shana.informed.package":{source:"iana",extensions:["ipk"]},"application/vnd.shootproof+json":{source:"iana",compressible:!0},"application/vnd.sigrok.session":{source:"iana"},"application/vnd.simtech-mindmapper":{source:"iana",extensions:["twd","twds"]},"application/vnd.siren+json":{source:"iana",compressible:!0},"application/vnd.smaf":{source:"iana",extensions:["mmf"]},"application/vnd.smart.notebook":{source:"iana"},"application/vnd.smart.teacher":{source:"iana",extensions:["teacher"]},"application/vnd.software602.filler.form+xml":{source:"iana",compressible:!0},"application/vnd.software602.filler.form-xml-zip":{source:"iana"},"application/vnd.solent.sdkm+xml":{source:"iana",compressible:!0,extensions:["sdkm","sdkd"]},"application/vnd.spotfire.dxp":{source:"iana",extensions:["dxp"]},"application/vnd.spotfire.sfs":{source:"iana",extensions:["sfs"]},"application/vnd.sqlite3":{source:"iana"},"application/vnd.sss-cod":{source:"iana"},"application/vnd.sss-dtf":{source:"iana"},"application/vnd.sss-ntf":{source:"iana"},"application/vnd.stardivision.calc":{source:"apache",extensions:["sdc"]},"application/vnd.stardivision.draw":{source:"apache",extensions:["sda"]},"application/vnd.stardivision.impress":{source:"apache",extensions:["sdd"]},"application/vnd.stardivision.math":{source:"apache",extensions:["smf"]},"application/vnd.stardivision.writer":{source:"apache",extensions:["sdw","vor"]},"application/vnd.stardivision.writer-global":{source:"apache",extensions:["sgl"]},"application/vnd.stepmania.package":{source:"iana",extensions:["smzip"]},"application/vnd.stepmania.stepchart":{source:"iana",extensions:["sm"]},"application/vnd.street-stream":{source:"iana"},"application/vnd.sun.wadl+xml":{source:"iana",compressible:!0,extensions:["wadl"]},"application/vnd.sun.xml.calc":{source:"apache",extensions:["sxc"]},"application/vnd.sun.xml.calc.template":{source:"apache",extensions:["stc"]},"application/vnd.sun.xml.draw":{source:"apache",extensions:["sxd"]},"application/vnd.sun.xml.draw.template":{source:"apache",extensions:["std"]},"application/vnd.sun.xml.impress":{source:"apache",extensions:["sxi"]},"application/vnd.sun.xml.impress.template":{source:"apache",extensions:["sti"]},"application/vnd.sun.xml.math":{source:"apache",extensions:["sxm"]},"application/vnd.sun.xml.writer":{source:"apache",extensions:["sxw"]},"application/vnd.sun.xml.writer.global":{source:"apache",extensions:["sxg"]},"application/vnd.sun.xml.writer.template":{source:"apache",extensions:["stw"]},"application/vnd.sus-calendar":{source:"iana",extensions:["sus","susp"]},"application/vnd.svd":{source:"iana",extensions:["svd"]},"application/vnd.swiftview-ics":{source:"iana"},"application/vnd.symbian.install":{source:"apache",extensions:["sis","sisx"]},"application/vnd.syncml+xml":{source:"iana",compressible:!0,extensions:["xsm"]},"application/vnd.syncml.dm+wbxml":{source:"iana",extensions:["bdm"]},"application/vnd.syncml.dm+xml":{source:"iana",compressible:!0,extensions:["xdm"]},"application/vnd.syncml.dm.notification":{source:"iana"},"application/vnd.syncml.dmddf+wbxml":{source:"iana"},"application/vnd.syncml.dmddf+xml":{source:"iana",compressible:!0},"application/vnd.syncml.dmtnds+wbxml":{source:"iana"},"application/vnd.syncml.dmtnds+xml":{source:"iana",compressible:!0},"application/vnd.syncml.ds.notification":{source:"iana"},"application/vnd.tableschema+json":{source:"iana",compressible:!0},"application/vnd.tao.intent-module-archive":{source:"iana",extensions:["tao"]},"application/vnd.tcpdump.pcap":{source:"iana",extensions:["pcap","cap","dmp"]},"application/vnd.think-cell.ppttc+json":{source:"iana",compressible:!0},"application/vnd.tmd.mediaflex.api+xml":{source:"iana",compressible:!0},"application/vnd.tml":{source:"iana"},"application/vnd.tmobile-livetv":{source:"iana",extensions:["tmo"]},"application/vnd.tri.onesource":{source:"iana"},"application/vnd.trid.tpt":{source:"iana",extensions:["tpt"]},"application/vnd.triscape.mxs":{source:"iana",extensions:["mxs"]},"application/vnd.trueapp":{source:"iana",extensions:["tra"]},"application/vnd.truedoc":{source:"iana"},"application/vnd.ubisoft.webplayer":{source:"iana"},"application/vnd.ufdl":{source:"iana",extensions:["ufd","ufdl"]},"application/vnd.uiq.theme":{source:"iana",extensions:["utz"]},"application/vnd.umajin":{source:"iana",extensions:["umj"]},"application/vnd.unity":{source:"iana",extensions:["unityweb"]},"application/vnd.uoml+xml":{source:"iana",compressible:!0,extensions:["uoml"]},"application/vnd.uplanet.alert":{source:"iana"},"application/vnd.uplanet.alert-wbxml":{source:"iana"},"application/vnd.uplanet.bearer-choice":{source:"iana"},"application/vnd.uplanet.bearer-choice-wbxml":{source:"iana"},"application/vnd.uplanet.cacheop":{source:"iana"},"application/vnd.uplanet.cacheop-wbxml":{source:"iana"},"application/vnd.uplanet.channel":{source:"iana"},"application/vnd.uplanet.channel-wbxml":{source:"iana"},"application/vnd.uplanet.list":{source:"iana"},"application/vnd.uplanet.list-wbxml":{source:"iana"},"application/vnd.uplanet.listcmd":{source:"iana"},"application/vnd.uplanet.listcmd-wbxml":{source:"iana"},"application/vnd.uplanet.signal":{source:"iana"},"application/vnd.uri-map":{source:"iana"},"application/vnd.valve.source.material":{source:"iana"},"application/vnd.vcx":{source:"iana",extensions:["vcx"]},"application/vnd.vd-study":{source:"iana"},"application/vnd.vectorworks":{source:"iana"},"application/vnd.vel+json":{source:"iana",compressible:!0},"application/vnd.verimatrix.vcas":{source:"iana"},"application/vnd.veryant.thin":{source:"iana"},"application/vnd.vidsoft.vidconference":{source:"iana"},"application/vnd.visio":{source:"iana",extensions:["vsd","vst","vss","vsw"]},"application/vnd.visionary":{source:"iana",extensions:["vis"]},"application/vnd.vividence.scriptfile":{source:"iana"},"application/vnd.vsf":{source:"iana",extensions:["vsf"]},"application/vnd.wap.sic":{source:"iana"},"application/vnd.wap.slc":{source:"iana"},"application/vnd.wap.wbxml":{source:"iana",extensions:["wbxml"]},"application/vnd.wap.wmlc":{source:"iana",extensions:["wmlc"]},"application/vnd.wap.wmlscriptc":{source:"iana",extensions:["wmlsc"]},"application/vnd.webturbo":{source:"iana",extensions:["wtb"]},"application/vnd.wfa.p2p":{source:"iana"},"application/vnd.wfa.wsc":{source:"iana"},"application/vnd.windows.devicepairing":{source:"iana"},"application/vnd.wmc":{source:"iana"},"application/vnd.wmf.bootstrap":{source:"iana"},"application/vnd.wolfram.mathematica":{source:"iana"},"application/vnd.wolfram.mathematica.package":{source:"iana"},"application/vnd.wolfram.player":{source:"iana",extensions:["nbp"]},"application/vnd.wordperfect":{source:"iana",extensions:["wpd"]},"application/vnd.wqd":{source:"iana",extensions:["wqd"]},"application/vnd.wrq-hp3000-labelled":{source:"iana"},"application/vnd.wt.stf":{source:"iana",extensions:["stf"]},"application/vnd.wv.csp+wbxml":{source:"iana"},"application/vnd.wv.csp+xml":{source:"iana",compressible:!0},"application/vnd.wv.ssp+xml":{source:"iana",compressible:!0},"application/vnd.xacml+json":{source:"iana",compressible:!0},"application/vnd.xara":{source:"iana",extensions:["xar"]},"application/vnd.xfdl":{source:"iana",extensions:["xfdl"]},"application/vnd.xfdl.webform":{source:"iana"},"application/vnd.xmi+xml":{source:"iana",compressible:!0},"application/vnd.xmpie.cpkg":{source:"iana"},"application/vnd.xmpie.dpkg":{source:"iana"},"application/vnd.xmpie.plan":{source:"iana"},"application/vnd.xmpie.ppkg":{source:"iana"},"application/vnd.xmpie.xlim":{source:"iana"},"application/vnd.yamaha.hv-dic":{source:"iana",extensions:["hvd"]},"application/vnd.yamaha.hv-script":{source:"iana",extensions:["hvs"]},"application/vnd.yamaha.hv-voice":{source:"iana",extensions:["hvp"]},"application/vnd.yamaha.openscoreformat":{source:"iana",extensions:["osf"]},"application/vnd.yamaha.openscoreformat.osfpvg+xml":{source:"iana",compressible:!0,extensions:["osfpvg"]},"application/vnd.yamaha.remote-setup":{source:"iana"},"application/vnd.yamaha.smaf-audio":{source:"iana",extensions:["saf"]},"application/vnd.yamaha.smaf-phrase":{source:"iana",extensions:["spf"]},"application/vnd.yamaha.through-ngn":{source:"iana"},"application/vnd.yamaha.tunnel-udpencap":{source:"iana"},"application/vnd.yaoweme":{source:"iana"},"application/vnd.yellowriver-custom-menu":{source:"iana",extensions:["cmp"]},"application/vnd.youtube.yt":{source:"iana"},"application/vnd.zul":{source:"iana",extensions:["zir","zirz"]},"application/vnd.zzazz.deck+xml":{source:"iana",compressible:!0,extensions:["zaz"]},"application/voicexml+xml":{source:"iana",compressible:!0,extensions:["vxml"]},"application/voucher-cms+json":{source:"iana",compressible:!0},"application/vq-rtcpxr":{source:"iana"},"application/wasm":{compressible:!0,extensions:["wasm"]},"application/watcherinfo+xml":{source:"iana",compressible:!0},"application/webpush-options+json":{source:"iana",compressible:!0},"application/whoispp-query":{source:"iana"},"application/whoispp-response":{source:"iana"},"application/widget":{source:"iana",extensions:["wgt"]},"application/winhlp":{source:"apache",extensions:["hlp"]},"application/wita":{source:"iana"},"application/wordperfect5.1":{source:"iana"},"application/wsdl+xml":{source:"iana",compressible:!0,extensions:["wsdl"]},"application/wspolicy+xml":{source:"iana",compressible:!0,extensions:["wspolicy"]},"application/x-7z-compressed":{source:"apache",compressible:!1,extensions:["7z"]},"application/x-abiword":{source:"apache",extensions:["abw"]},"application/x-ace-compressed":{source:"apache",extensions:["ace"]},"application/x-amf":{source:"apache"},"application/x-apple-diskimage":{source:"apache",extensions:["dmg"]},"application/x-arj":{compressible:!1,extensions:["arj"]},"application/x-authorware-bin":{source:"apache",extensions:["aab","x32","u32","vox"]},"application/x-authorware-map":{source:"apache",extensions:["aam"]},"application/x-authorware-seg":{source:"apache",extensions:["aas"]},"application/x-bcpio":{source:"apache",extensions:["bcpio"]},"application/x-bdoc":{compressible:!1,extensions:["bdoc"]},"application/x-bittorrent":{source:"apache",extensions:["torrent"]},"application/x-blorb":{source:"apache",extensions:["blb","blorb"]},"application/x-bzip":{source:"apache",compressible:!1,extensions:["bz"]},"application/x-bzip2":{source:"apache",compressible:!1,extensions:["bz2","boz"]},"application/x-cbr":{source:"apache",extensions:["cbr","cba","cbt","cbz","cb7"]},"application/x-cdlink":{source:"apache",extensions:["vcd"]},"application/x-cfs-compressed":{source:"apache",extensions:["cfs"]},"application/x-chat":{source:"apache",extensions:["chat"]},"application/x-chess-pgn":{source:"apache",extensions:["pgn"]},"application/x-chrome-extension":{extensions:["crx"]},"application/x-cocoa":{source:"nginx",extensions:["cco"]},"application/x-compress":{source:"apache"},"application/x-conference":{source:"apache",extensions:["nsc"]},"application/x-cpio":{source:"apache",extensions:["cpio"]},"application/x-csh":{source:"apache",extensions:["csh"]},"application/x-deb":{compressible:!1},"application/x-debian-package":{source:"apache",extensions:["deb","udeb"]},"application/x-dgc-compressed":{source:"apache",extensions:["dgc"]},"application/x-director":{source:"apache",extensions:["dir","dcr","dxr","cst","cct","cxt","w3d","fgd","swa"]},"application/x-doom":{source:"apache",extensions:["wad"]},"application/x-dtbncx+xml":{source:"apache",compressible:!0,extensions:["ncx"]},"application/x-dtbook+xml":{source:"apache",compressible:!0,extensions:["dtb"]},"application/x-dtbresource+xml":{source:"apache",compressible:!0,extensions:["res"]},"application/x-dvi":{source:"apache",compressible:!1,extensions:["dvi"]},"application/x-envoy":{source:"apache",extensions:["evy"]},"application/x-eva":{source:"apache",extensions:["eva"]},"application/x-font-bdf":{source:"apache",extensions:["bdf"]},"application/x-font-dos":{source:"apache"},"application/x-font-framemaker":{source:"apache"},"application/x-font-ghostscript":{source:"apache",extensions:["gsf"]},"application/x-font-libgrx":{source:"apache"},"application/x-font-linux-psf":{source:"apache",extensions:["psf"]},"application/x-font-pcf":{source:"apache",extensions:["pcf"]},"application/x-font-snf":{source:"apache",extensions:["snf"]},"application/x-font-speedo":{source:"apache"},"application/x-font-sunos-news":{source:"apache"},"application/x-font-type1":{source:"apache",extensions:["pfa","pfb","pfm","afm"]},"application/x-font-vfont":{source:"apache"},"application/x-freearc":{source:"apache",extensions:["arc"]},"application/x-futuresplash":{source:"apache",extensions:["spl"]},"application/x-gca-compressed":{source:"apache",extensions:["gca"]},"application/x-glulx":{source:"apache",extensions:["ulx"]},"application/x-gnumeric":{source:"apache",extensions:["gnumeric"]},"application/x-gramps-xml":{source:"apache",extensions:["gramps"]},"application/x-gtar":{source:"apache",extensions:["gtar"]},"application/x-gzip":{source:"apache"},"application/x-hdf":{source:"apache",extensions:["hdf"]},"application/x-httpd-php":{compressible:!0,extensions:["php"]},"application/x-install-instructions":{source:"apache",extensions:["install"]},"application/x-iso9660-image":{source:"apache",extensions:["iso"]},"application/x-java-archive-diff":{source:"nginx",extensions:["jardiff"]},"application/x-java-jnlp-file":{source:"apache",compressible:!1,extensions:["jnlp"]},"application/x-javascript":{compressible:!0},"application/x-latex":{source:"apache",compressible:!1,extensions:["latex"]},"application/x-lua-bytecode":{extensions:["luac"]},"application/x-lzh-compressed":{source:"apache",extensions:["lzh","lha"]},"application/x-makeself":{source:"nginx",extensions:["run"]},"application/x-mie":{source:"apache",extensions:["mie"]},"application/x-mobipocket-ebook":{source:"apache",extensions:["prc","mobi"]},"application/x-mpegurl":{compressible:!1},"application/x-ms-application":{source:"apache",extensions:["application"]},"application/x-ms-shortcut":{source:"apache",extensions:["lnk"]},"application/x-ms-wmd":{source:"apache",extensions:["wmd"]},"application/x-ms-wmz":{source:"apache",extensions:["wmz"]},"application/x-ms-xbap":{source:"apache",extensions:["xbap"]},"application/x-msaccess":{source:"apache",extensions:["mdb"]},"application/x-msbinder":{source:"apache",extensions:["obd"]},"application/x-mscardfile":{source:"apache",extensions:["crd"]},"application/x-msclip":{source:"apache",extensions:["clp"]},"application/x-msdos-program":{extensions:["exe"]},"application/x-msdownload":{source:"apache",extensions:["exe","dll","com","bat","msi"]},"application/x-msmediaview":{source:"apache",extensions:["mvb","m13","m14"]},"application/x-msmetafile":{source:"apache",extensions:["wmf","wmz","emf","emz"]},"application/x-msmoney":{source:"apache",extensions:["mny"]},"application/x-mspublisher":{source:"apache",extensions:["pub"]},"application/x-msschedule":{source:"apache",extensions:["scd"]},"application/x-msterminal":{source:"apache",extensions:["trm"]},"application/x-mswrite":{source:"apache",extensions:["wri"]},"application/x-netcdf":{source:"apache",extensions:["nc","cdf"]},"application/x-ns-proxy-autoconfig":{compressible:!0,extensions:["pac"]},"application/x-nzb":{source:"apache",extensions:["nzb"]},"application/x-perl":{source:"nginx",extensions:["pl","pm"]},"application/x-pilot":{source:"nginx",extensions:["prc","pdb"]},"application/x-pkcs12":{source:"apache",compressible:!1,extensions:["p12","pfx"]},"application/x-pkcs7-certificates":{source:"apache",extensions:["p7b","spc"]},"application/x-pkcs7-certreqresp":{source:"apache",extensions:["p7r"]},"application/x-rar-compressed":{source:"apache",compressible:!1,extensions:["rar"]},"application/x-redhat-package-manager":{source:"nginx",extensions:["rpm"]},"application/x-research-info-systems":{source:"apache",extensions:["ris"]},"application/x-sea":{source:"nginx",extensions:["sea"]},"application/x-sh":{source:"apache",compressible:!0,extensions:["sh"]},"application/x-shar":{source:"apache",extensions:["shar"]},"application/x-shockwave-flash":{source:"apache",compressible:!1,extensions:["swf"]},"application/x-silverlight-app":{source:"apache",extensions:["xap"]},"application/x-sql":{source:"apache",extensions:["sql"]},"application/x-stuffit":{source:"apache",compressible:!1,extensions:["sit"]},"application/x-stuffitx":{source:"apache",extensions:["sitx"]},"application/x-subrip":{source:"apache",extensions:["srt"]},"application/x-sv4cpio":{source:"apache",extensions:["sv4cpio"]},"application/x-sv4crc":{source:"apache",extensions:["sv4crc"]},"application/x-t3vm-image":{source:"apache",extensions:["t3"]},"application/x-tads":{source:"apache",extensions:["gam"]},"application/x-tar":{source:"apache",compressible:!0,extensions:["tar"]},"application/x-tcl":{source:"apache",extensions:["tcl","tk"]},"application/x-tex":{source:"apache",extensions:["tex"]},"application/x-tex-tfm":{source:"apache",extensions:["tfm"]},"application/x-texinfo":{source:"apache",extensions:["texinfo","texi"]},"application/x-tgif":{source:"apache",extensions:["obj"]},"application/x-ustar":{source:"apache",extensions:["ustar"]},"application/x-virtualbox-hdd":{compressible:!0,extensions:["hdd"]},"application/x-virtualbox-ova":{compressible:!0,extensions:["ova"]},"application/x-virtualbox-ovf":{compressible:!0,extensions:["ovf"]},"application/x-virtualbox-vbox":{compressible:!0,extensions:["vbox"]},"application/x-virtualbox-vbox-extpack":{compressible:!1,extensions:["vbox-extpack"]},"application/x-virtualbox-vdi":{compressible:!0,extensions:["vdi"]},"application/x-virtualbox-vhd":{compressible:!0,extensions:["vhd"]},"application/x-virtualbox-vmdk":{compressible:!0,extensions:["vmdk"]},"application/x-wais-source":{source:"apache",extensions:["src"]},"application/x-web-app-manifest+json":{compressible:!0,extensions:["webapp"]},"application/x-www-form-urlencoded":{source:"iana",compressible:!0},"application/x-x509-ca-cert":{source:"apache",extensions:["der","crt","pem"]},"application/x-xfig":{source:"apache",extensions:["fig"]},"application/x-xliff+xml":{source:"apache",compressible:!0,extensions:["xlf"]},"application/x-xpinstall":{source:"apache",compressible:!1,extensions:["xpi"]},"application/x-xz":{source:"apache",extensions:["xz"]},"application/x-zmachine":{source:"apache",extensions:["z1","z2","z3","z4","z5","z6","z7","z8"]},"application/x400-bp":{source:"iana"},"application/xacml+xml":{source:"iana",compressible:!0},"application/xaml+xml":{source:"apache",compressible:!0,extensions:["xaml"]},"application/xcap-att+xml":{source:"iana",compressible:!0},"application/xcap-caps+xml":{source:"iana",compressible:!0},"application/xcap-diff+xml":{source:"iana",compressible:!0,extensions:["xdf"]},"application/xcap-el+xml":{source:"iana",compressible:!0},"application/xcap-error+xml":{source:"iana",compressible:!0},"application/xcap-ns+xml":{source:"iana",compressible:!0},"application/xcon-conference-info+xml":{source:"iana",compressible:!0},"application/xcon-conference-info-diff+xml":{source:"iana",compressible:!0},"application/xenc+xml":{source:"iana",compressible:!0,extensions:["xenc"]},"application/xhtml+xml":{source:"iana",compressible:!0,extensions:["xhtml","xht"]},"application/xhtml-voice+xml":{source:"apache",compressible:!0},"application/xliff+xml":{source:"iana",compressible:!0},"application/xml":{source:"iana",compressible:!0,extensions:["xml","xsl","xsd","rng"]},"application/xml-dtd":{source:"iana",compressible:!0,extensions:["dtd"]},"application/xml-external-parsed-entity":{source:"iana"},"application/xml-patch+xml":{source:"iana",compressible:!0},"application/xmpp+xml":{source:"iana",compressible:!0},"application/xop+xml":{source:"iana",compressible:!0,extensions:["xop"]},"application/xproc+xml":{source:"apache",compressible:!0,extensions:["xpl"]},"application/xslt+xml":{source:"iana",compressible:!0,extensions:["xslt"]},"application/xspf+xml":{source:"apache",compressible:!0,extensions:["xspf"]},"application/xv+xml":{source:"iana",compressible:!0,extensions:["mxml","xhvml","xvml","xvm"]},"application/yang":{source:"iana",extensions:["yang"]},"application/yang-data+json":{source:"iana",compressible:!0},"application/yang-data+xml":{source:"iana",compressible:!0},"application/yang-patch+json":{source:"iana",compressible:!0},"application/yang-patch+xml":{source:"iana",compressible:!0},"application/yin+xml":{source:"iana",compressible:!0,extensions:["yin"]},"application/zip":{source:"iana",compressible:!1,extensions:["zip"]},"application/zlib":{source:"iana"},"application/zstd":{source:"iana"},"audio/1d-interleaved-parityfec":{source:"iana"},"audio/32kadpcm":{source:"iana"},"audio/3gpp":{source:"iana",compressible:!1,extensions:["3gpp"]},"audio/3gpp2":{source:"iana"},"audio/aac":{source:"iana"},"audio/ac3":{source:"iana"},"audio/adpcm":{source:"apache",extensions:["adp"]},"audio/amr":{source:"iana"},"audio/amr-wb":{source:"iana"},"audio/amr-wb+":{source:"iana"},"audio/aptx":{source:"iana"},"audio/asc":{source:"iana"},"audio/atrac-advanced-lossless":{source:"iana"},"audio/atrac-x":{source:"iana"},"audio/atrac3":{source:"iana"},"audio/basic":{source:"iana",compressible:!1,extensions:["au","snd"]},"audio/bv16":{source:"iana"},"audio/bv32":{source:"iana"},"audio/clearmode":{source:"iana"},"audio/cn":{source:"iana"},"audio/dat12":{source:"iana"},"audio/dls":{source:"iana"},"audio/dsr-es201108":{source:"iana"},"audio/dsr-es202050":{source:"iana"},"audio/dsr-es202211":{source:"iana"},"audio/dsr-es202212":{source:"iana"},"audio/dv":{source:"iana"},"audio/dvi4":{source:"iana"},"audio/eac3":{source:"iana"},"audio/encaprtp":{source:"iana"},"audio/evrc":{source:"iana"},"audio/evrc-qcp":{source:"iana"},"audio/evrc0":{source:"iana"},"audio/evrc1":{source:"iana"},"audio/evrcb":{source:"iana"},"audio/evrcb0":{source:"iana"},"audio/evrcb1":{source:"iana"},"audio/evrcnw":{source:"iana"},"audio/evrcnw0":{source:"iana"},"audio/evrcnw1":{source:"iana"},"audio/evrcwb":{source:"iana"},"audio/evrcwb0":{source:"iana"},"audio/evrcwb1":{source:"iana"},"audio/evs":{source:"iana"},"audio/fwdred":{source:"iana"},"audio/g711-0":{source:"iana"},"audio/g719":{source:"iana"},"audio/g722":{source:"iana"},"audio/g7221":{source:"iana"},"audio/g723":{source:"iana"},"audio/g726-16":{source:"iana"},"audio/g726-24":{source:"iana"},"audio/g726-32":{source:"iana"},"audio/g726-40":{source:"iana"},"audio/g728":{source:"iana"},"audio/g729":{source:"iana"},"audio/g7291":{source:"iana"},"audio/g729d":{source:"iana"},"audio/g729e":{source:"iana"},"audio/gsm":{source:"iana"},"audio/gsm-efr":{source:"iana"},"audio/gsm-hr-08":{source:"iana"},"audio/ilbc":{source:"iana"},"audio/ip-mr_v2.5":{source:"iana"},"audio/isac":{source:"apache"},"audio/l16":{source:"iana"},"audio/l20":{source:"iana"},"audio/l24":{source:"iana",compressible:!1},"audio/l8":{source:"iana"},"audio/lpc":{source:"iana"},"audio/melp":{source:"iana"},"audio/melp1200":{source:"iana"},"audio/melp2400":{source:"iana"},"audio/melp600":{source:"iana"},"audio/midi":{source:"apache",extensions:["mid","midi","kar","rmi"]},"audio/mobile-xmf":{source:"iana"},"audio/mp3":{compressible:!1,extensions:["mp3"]},"audio/mp4":{source:"iana",compressible:!1,extensions:["m4a","mp4a"]},"audio/mp4a-latm":{source:"iana"},"audio/mpa":{source:"iana"},"audio/mpa-robust":{source:"iana"},"audio/mpeg":{source:"iana",compressible:!1,extensions:["mpga","mp2","mp2a","mp3","m2a","m3a"]},"audio/mpeg4-generic":{source:"iana"},"audio/musepack":{source:"apache"},"audio/ogg":{source:"iana",compressible:!1,extensions:["oga","ogg","spx"]},"audio/opus":{source:"iana"},"audio/parityfec":{source:"iana"},"audio/pcma":{source:"iana"},"audio/pcma-wb":{source:"iana"},"audio/pcmu":{source:"iana"},"audio/pcmu-wb":{source:"iana"},"audio/prs.sid":{source:"iana"},"audio/qcelp":{source:"iana"},"audio/raptorfec":{source:"iana"},"audio/red":{source:"iana"},"audio/rtp-enc-aescm128":{source:"iana"},"audio/rtp-midi":{source:"iana"},"audio/rtploopback":{source:"iana"},"audio/rtx":{source:"iana"},"audio/s3m":{source:"apache",extensions:["s3m"]},"audio/silk":{source:"apache",extensions:["sil"]},"audio/smv":{source:"iana"},"audio/smv-qcp":{source:"iana"},"audio/smv0":{source:"iana"},"audio/sp-midi":{source:"iana"},"audio/speex":{source:"iana"},"audio/t140c":{source:"iana"},"audio/t38":{source:"iana"},"audio/telephone-event":{source:"iana"},"audio/tetra_acelp":{source:"iana"},"audio/tone":{source:"iana"},"audio/uemclip":{source:"iana"},"audio/ulpfec":{source:"iana"},"audio/usac":{source:"iana"},"audio/vdvi":{source:"iana"},"audio/vmr-wb":{source:"iana"},"audio/vnd.3gpp.iufp":{source:"iana"},"audio/vnd.4sb":{source:"iana"},"audio/vnd.audiokoz":{source:"iana"},"audio/vnd.celp":{source:"iana"},"audio/vnd.cisco.nse":{source:"iana"},"audio/vnd.cmles.radio-events":{source:"iana"},"audio/vnd.cns.anp1":{source:"iana"},"audio/vnd.cns.inf1":{source:"iana"},"audio/vnd.dece.audio":{source:"iana",extensions:["uva","uvva"]},"audio/vnd.digital-winds":{source:"iana",extensions:["eol"]},"audio/vnd.dlna.adts":{source:"iana"},"audio/vnd.dolby.heaac.1":{source:"iana"},"audio/vnd.dolby.heaac.2":{source:"iana"},"audio/vnd.dolby.mlp":{source:"iana"},"audio/vnd.dolby.mps":{source:"iana"},"audio/vnd.dolby.pl2":{source:"iana"},"audio/vnd.dolby.pl2x":{source:"iana"},"audio/vnd.dolby.pl2z":{source:"iana"},"audio/vnd.dolby.pulse.1":{source:"iana"},"audio/vnd.dra":{source:"iana",extensions:["dra"]},"audio/vnd.dts":{source:"iana",extensions:["dts"]},"audio/vnd.dts.hd":{source:"iana",extensions:["dtshd"]},"audio/vnd.dts.uhd":{source:"iana"},"audio/vnd.dvb.file":{source:"iana"},"audio/vnd.everad.plj":{source:"iana"},"audio/vnd.hns.audio":{source:"iana"},"audio/vnd.lucent.voice":{source:"iana",extensions:["lvp"]},"audio/vnd.ms-playready.media.pya":{source:"iana",extensions:["pya"]},"audio/vnd.nokia.mobile-xmf":{source:"iana"},"audio/vnd.nortel.vbk":{source:"iana"},"audio/vnd.nuera.ecelp4800":{source:"iana",extensions:["ecelp4800"]},"audio/vnd.nuera.ecelp7470":{source:"iana",extensions:["ecelp7470"]},"audio/vnd.nuera.ecelp9600":{source:"iana",extensions:["ecelp9600"]},"audio/vnd.octel.sbc":{source:"iana"},"audio/vnd.presonus.multitrack":{source:"iana"},"audio/vnd.qcelp":{source:"iana"},"audio/vnd.rhetorex.32kadpcm":{source:"iana"},"audio/vnd.rip":{source:"iana",extensions:["rip"]},"audio/vnd.rn-realaudio":{compressible:!1},"audio/vnd.sealedmedia.softseal.mpeg":{source:"iana"},"audio/vnd.vmx.cvsd":{source:"iana"},"audio/vnd.wave":{compressible:!1},"audio/vorbis":{source:"iana",compressible:!1},"audio/vorbis-config":{source:"iana"},"audio/wav":{compressible:!1,extensions:["wav"]},"audio/wave":{compressible:!1,extensions:["wav"]},"audio/webm":{source:"apache",compressible:!1,extensions:["weba"]},"audio/x-aac":{source:"apache",compressible:!1,extensions:["aac"]},"audio/x-aiff":{source:"apache",extensions:["aif","aiff","aifc"]},"audio/x-caf":{source:"apache",compressible:!1,extensions:["caf"]},"audio/x-flac":{source:"apache",extensions:["flac"]},"audio/x-m4a":{source:"nginx",extensions:["m4a"]},"audio/x-matroska":{source:"apache",extensions:["mka"]},"audio/x-mpegurl":{source:"apache",extensions:["m3u"]},"audio/x-ms-wax":{source:"apache",extensions:["wax"]},"audio/x-ms-wma":{source:"apache",extensions:["wma"]},"audio/x-pn-realaudio":{source:"apache",extensions:["ram","ra"]},"audio/x-pn-realaudio-plugin":{source:"apache",extensions:["rmp"]},"audio/x-realaudio":{source:"nginx",extensions:["ra"]},"audio/x-tta":{source:"apache"},"audio/x-wav":{source:"apache",extensions:["wav"]},"audio/xm":{source:"apache",extensions:["xm"]},"chemical/x-cdx":{source:"apache",extensions:["cdx"]},"chemical/x-cif":{source:"apache",extensions:["cif"]},"chemical/x-cmdf":{source:"apache",extensions:["cmdf"]},"chemical/x-cml":{source:"apache",extensions:["cml"]},"chemical/x-csml":{source:"apache",extensions:["csml"]},"chemical/x-pdb":{source:"apache"},"chemical/x-xyz":{source:"apache",extensions:["xyz"]},"font/collection":{source:"iana",extensions:["ttc"]},"font/otf":{source:"iana",compressible:!0,extensions:["otf"]},"font/sfnt":{source:"iana"},"font/ttf":{source:"iana",extensions:["ttf"]},"font/woff":{source:"iana",extensions:["woff"]},"font/woff2":{source:"iana",extensions:["woff2"]},"image/aces":{source:"iana",extensions:["exr"]},"image/apng":{compressible:!1,extensions:["apng"]},"image/avci":{source:"iana"},"image/avcs":{source:"iana"},"image/bmp":{source:"iana",compressible:!0,extensions:["bmp"]},"image/cgm":{source:"iana",extensions:["cgm"]},"image/dicom-rle":{source:"iana",extensions:["drle"]},"image/emf":{source:"iana",extensions:["emf"]},"image/fits":{source:"iana",extensions:["fits"]},"image/g3fax":{source:"iana",extensions:["g3"]},"image/gif":{source:"iana",compressible:!1,extensions:["gif"]},"image/heic":{source:"iana",extensions:["heic"]},"image/heic-sequence":{source:"iana",extensions:["heics"]},"image/heif":{source:"iana",extensions:["heif"]},"image/heif-sequence":{source:"iana",extensions:["heifs"]},"image/ief":{source:"iana",extensions:["ief"]},"image/jls":{source:"iana",extensions:["jls"]},"image/jp2":{source:"iana",compressible:!1,extensions:["jp2","jpg2"]},"image/jpeg":{source:"iana",compressible:!1,extensions:["jpeg","jpg","jpe"]},"image/jpm":{source:"iana",compressible:!1,extensions:["jpm"]},"image/jpx":{source:"iana",compressible:!1,extensions:["jpx","jpf"]},"image/jxr":{source:"iana",extensions:["jxr"]},"image/ktx":{source:"iana",extensions:["ktx"]},"image/naplps":{source:"iana"},"image/pjpeg":{compressible:!1},"image/png":{source:"iana",compressible:!1,extensions:["png"]},"image/prs.btif":{source:"iana",extensions:["btif"]},"image/prs.pti":{source:"iana",extensions:["pti"]},"image/pwg-raster":{source:"iana"},"image/sgi":{source:"apache",extensions:["sgi"]},"image/svg+xml":{source:"iana",compressible:!0,extensions:["svg","svgz"]},"image/t38":{source:"iana",extensions:["t38"]},"image/tiff":{source:"iana",compressible:!1,extensions:["tif","tiff"]},"image/tiff-fx":{source:"iana",extensions:["tfx"]},"image/vnd.adobe.photoshop":{source:"iana",compressible:!0,extensions:["psd"]},"image/vnd.airzip.accelerator.azv":{source:"iana",extensions:["azv"]},"image/vnd.cns.inf2":{source:"iana"},"image/vnd.dece.graphic":{source:"iana",extensions:["uvi","uvvi","uvg","uvvg"]},"image/vnd.djvu":{source:"iana",extensions:["djvu","djv"]},"image/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"image/vnd.dwg":{source:"iana",extensions:["dwg"]},"image/vnd.dxf":{source:"iana",extensions:["dxf"]},"image/vnd.fastbidsheet":{source:"iana",extensions:["fbs"]},"image/vnd.fpx":{source:"iana",extensions:["fpx"]},"image/vnd.fst":{source:"iana",extensions:["fst"]},"image/vnd.fujixerox.edmics-mmr":{source:"iana",extensions:["mmr"]},"image/vnd.fujixerox.edmics-rlc":{source:"iana",extensions:["rlc"]},"image/vnd.globalgraphics.pgb":{source:"iana"},"image/vnd.microsoft.icon":{source:"iana",extensions:["ico"]},"image/vnd.mix":{source:"iana"},"image/vnd.mozilla.apng":{source:"iana"},"image/vnd.ms-modi":{source:"iana",extensions:["mdi"]},"image/vnd.ms-photo":{source:"apache",extensions:["wdp"]},"image/vnd.net-fpx":{source:"iana",extensions:["npx"]},"image/vnd.radiance":{source:"iana"},"image/vnd.sealed.png":{source:"iana"},"image/vnd.sealedmedia.softseal.gif":{source:"iana"},"image/vnd.sealedmedia.softseal.jpg":{source:"iana"},"image/vnd.svf":{source:"iana"},"image/vnd.tencent.tap":{source:"iana",extensions:["tap"]},"image/vnd.valve.source.texture":{source:"iana",extensions:["vtf"]},"image/vnd.wap.wbmp":{source:"iana",extensions:["wbmp"]},"image/vnd.xiff":{source:"iana",extensions:["xif"]},"image/vnd.zbrush.pcx":{source:"iana",extensions:["pcx"]},"image/webp":{source:"apache",extensions:["webp"]},"image/wmf":{source:"iana",extensions:["wmf"]},"image/x-3ds":{source:"apache",extensions:["3ds"]},"image/x-cmu-raster":{source:"apache",extensions:["ras"]},"image/x-cmx":{source:"apache",extensions:["cmx"]},"image/x-freehand":{source:"apache",extensions:["fh","fhc","fh4","fh5","fh7"]},"image/x-icon":{source:"apache",compressible:!0,extensions:["ico"]},"image/x-jng":{source:"nginx",extensions:["jng"]},"image/x-mrsid-image":{source:"apache",extensions:["sid"]},"image/x-ms-bmp":{source:"nginx",compressible:!0,extensions:["bmp"]},"image/x-pcx":{source:"apache",extensions:["pcx"]},"image/x-pict":{source:"apache",extensions:["pic","pct"]},"image/x-portable-anymap":{source:"apache",extensions:["pnm"]},"image/x-portable-bitmap":{source:"apache",extensions:["pbm"]},"image/x-portable-graymap":{source:"apache",extensions:["pgm"]},"image/x-portable-pixmap":{source:"apache",extensions:["ppm"]},"image/x-rgb":{source:"apache",extensions:["rgb"]},"image/x-tga":{source:"apache",extensions:["tga"]},"image/x-xbitmap":{source:"apache",extensions:["xbm"]},"image/x-xcf":{compressible:!1},"image/x-xpixmap":{source:"apache",extensions:["xpm"]},"image/x-xwindowdump":{source:"apache",extensions:["xwd"]},"message/cpim":{source:"iana"},"message/delivery-status":{source:"iana"},"message/disposition-notification":{source:"iana",extensions:["disposition-notification"]},"message/external-body":{source:"iana"},"message/feedback-report":{source:"iana"},"message/global":{source:"iana",extensions:["u8msg"]},"message/global-delivery-status":{source:"iana",extensions:["u8dsn"]},"message/global-disposition-notification":{source:"iana",extensions:["u8mdn"]},"message/global-headers":{source:"iana",extensions:["u8hdr"]},"message/http":{source:"iana",compressible:!1},"message/imdn+xml":{source:"iana",compressible:!0},"message/news":{source:"iana"},"message/partial":{source:"iana",compressible:!1},"message/rfc822":{source:"iana",compressible:!0,extensions:["eml","mime"]},"message/s-http":{source:"iana"},"message/sip":{source:"iana"},"message/sipfrag":{source:"iana"},"message/tracking-status":{source:"iana"},"message/vnd.si.simp":{source:"iana"},"message/vnd.wfa.wsc":{source:"iana",extensions:["wsc"]},"model/3mf":{source:"iana",extensions:["3mf"]},"model/gltf+json":{source:"iana",compressible:!0,extensions:["gltf"]},"model/gltf-binary":{source:"iana",compressible:!0,extensions:["glb"]},"model/iges":{source:"iana",compressible:!1,extensions:["igs","iges"]},"model/mesh":{source:"iana",compressible:!1,extensions:["msh","mesh","silo"]},"model/stl":{source:"iana",extensions:["stl"]},"model/vnd.collada+xml":{source:"iana",compressible:!0,extensions:["dae"]},"model/vnd.dwf":{source:"iana",extensions:["dwf"]},"model/vnd.flatland.3dml":{source:"iana"},"model/vnd.gdl":{source:"iana",extensions:["gdl"]},"model/vnd.gs-gdl":{source:"apache"},"model/vnd.gs.gdl":{source:"iana"},"model/vnd.gtw":{source:"iana",extensions:["gtw"]},"model/vnd.moml+xml":{source:"iana",compressible:!0},"model/vnd.mts":{source:"iana",extensions:["mts"]},"model/vnd.opengex":{source:"iana",extensions:["ogex"]},"model/vnd.parasolid.transmit.binary":{source:"iana",extensions:["x_b"]},"model/vnd.parasolid.transmit.text":{source:"iana",extensions:["x_t"]},"model/vnd.rosette.annotated-data-model":{source:"iana"},"model/vnd.usdz+zip":{source:"iana",compressible:!1,extensions:["usdz"]},"model/vnd.valve.source.compiled-map":{source:"iana",extensions:["bsp"]},"model/vnd.vtu":{source:"iana",extensions:["vtu"]},"model/vrml":{source:"iana",compressible:!1,extensions:["wrl","vrml"]},"model/x3d+binary":{source:"apache",compressible:!1,extensions:["x3db","x3dbz"]},"model/x3d+fastinfoset":{source:"iana",extensions:["x3db"]},"model/x3d+vrml":{source:"apache",compressible:!1,extensions:["x3dv","x3dvz"]},"model/x3d+xml":{source:"iana",compressible:!0,extensions:["x3d","x3dz"]},"model/x3d-vrml":{source:"iana",extensions:["x3dv"]},"multipart/alternative":{source:"iana",compressible:!1},"multipart/appledouble":{source:"iana"},"multipart/byteranges":{source:"iana"},"multipart/digest":{source:"iana"},"multipart/encrypted":{source:"iana",compressible:!1},"multipart/form-data":{source:"iana",compressible:!1},"multipart/header-set":{source:"iana"},"multipart/mixed":{source:"iana",compressible:!1},"multipart/multilingual":{source:"iana"},"multipart/parallel":{source:"iana"},"multipart/related":{source:"iana",compressible:!1},"multipart/report":{source:"iana"},"multipart/signed":{source:"iana",compressible:!1},"multipart/vnd.bint.med-plus":{source:"iana"},"multipart/voice-message":{source:"iana"},"multipart/x-mixed-replace":{source:"iana"},"text/1d-interleaved-parityfec":{source:"iana"},"text/cache-manifest":{source:"iana",compressible:!0,extensions:["appcache","manifest"]},"text/calendar":{source:"iana",extensions:["ics","ifb"]},"text/calender":{compressible:!0},"text/cmd":{compressible:!0},"text/coffeescript":{extensions:["coffee","litcoffee"]},"text/css":{source:"iana",charset:"UTF-8",compressible:!0,extensions:["css"]},"text/csv":{source:"iana",compressible:!0,extensions:["csv"]},"text/csv-schema":{source:"iana"},"text/directory":{source:"iana"},"text/dns":{source:"iana"},"text/ecmascript":{source:"iana"},"text/encaprtp":{source:"iana"},"text/enriched":{source:"iana"},"text/fwdred":{source:"iana"},"text/grammar-ref-list":{source:"iana"},"text/html":{source:"iana",compressible:!0,extensions:["html","htm","shtml"]},"text/jade":{extensions:["jade"]},"text/javascript":{source:"iana",compressible:!0},"text/jcr-cnd":{source:"iana"},"text/jsx":{compressible:!0,extensions:["jsx"]},"text/less":{compressible:!0,extensions:["less"]},"text/markdown":{source:"iana",compressible:!0,extensions:["markdown","md"]},"text/mathml":{source:"nginx",extensions:["mml"]},"text/mdx":{compressible:!0,extensions:["mdx"]},"text/mizar":{source:"iana"},"text/n3":{source:"iana",compressible:!0,extensions:["n3"]},"text/parameters":{source:"iana"},"text/parityfec":{source:"iana"},"text/plain":{source:"iana",compressible:!0,extensions:["txt","text","conf","def","list","log","in","ini"]},"text/provenance-notation":{source:"iana"},"text/prs.fallenstein.rst":{source:"iana"},"text/prs.lines.tag":{source:"iana",extensions:["dsc"]},"text/prs.prop.logic":{source:"iana"},"text/raptorfec":{source:"iana"},"text/red":{source:"iana"},"text/rfc822-headers":{source:"iana"},"text/richtext":{source:"iana",compressible:!0,extensions:["rtx"]},"text/rtf":{source:"iana",compressible:!0,extensions:["rtf"]},"text/rtp-enc-aescm128":{source:"iana"},"text/rtploopback":{source:"iana"},"text/rtx":{source:"iana"},"text/sgml":{source:"iana",extensions:["sgml","sgm"]},"text/shex":{extensions:["shex"]},"text/slim":{extensions:["slim","slm"]},"text/strings":{source:"iana"},"text/stylus":{extensions:["stylus","styl"]},"text/t140":{source:"iana"},"text/tab-separated-values":{source:"iana",compressible:!0,extensions:["tsv"]},"text/troff":{source:"iana",extensions:["t","tr","roff","man","me","ms"]},"text/turtle":{source:"iana",charset:"UTF-8",extensions:["ttl"]},"text/ulpfec":{source:"iana"},"text/uri-list":{source:"iana",compressible:!0,extensions:["uri","uris","urls"]},"text/vcard":{source:"iana",compressible:!0,extensions:["vcard"]},"text/vnd.a":{source:"iana"},"text/vnd.abc":{source:"iana"},"text/vnd.ascii-art":{source:"iana"},"text/vnd.curl":{source:"iana",extensions:["curl"]},"text/vnd.curl.dcurl":{source:"apache",extensions:["dcurl"]},"text/vnd.curl.mcurl":{source:"apache",extensions:["mcurl"]},"text/vnd.curl.scurl":{source:"apache",extensions:["scurl"]},"text/vnd.debian.copyright":{source:"iana"},"text/vnd.dmclientscript":{source:"iana"},"text/vnd.dvb.subtitle":{source:"iana",extensions:["sub"]},"text/vnd.esmertec.theme-descriptor":{source:"iana"},"text/vnd.fly":{source:"iana",extensions:["fly"]},"text/vnd.fmi.flexstor":{source:"iana",extensions:["flx"]},"text/vnd.gml":{source:"iana"},"text/vnd.graphviz":{source:"iana",extensions:["gv"]},"text/vnd.hgl":{source:"iana"},"text/vnd.in3d.3dml":{source:"iana",extensions:["3dml"]},"text/vnd.in3d.spot":{source:"iana",extensions:["spot"]},"text/vnd.iptc.newsml":{source:"iana"},"text/vnd.iptc.nitf":{source:"iana"},"text/vnd.latex-z":{source:"iana"},"text/vnd.motorola.reflex":{source:"iana"},"text/vnd.ms-mediapackage":{source:"iana"},"text/vnd.net2phone.commcenter.command":{source:"iana"},"text/vnd.radisys.msml-basic-layout":{source:"iana"},"text/vnd.senx.warpscript":{source:"iana"},"text/vnd.si.uricatalogue":{source:"iana"},"text/vnd.sun.j2me.app-descriptor":{source:"iana",extensions:["jad"]},"text/vnd.trolltech.linguist":{source:"iana"},"text/vnd.wap.si":{source:"iana"},"text/vnd.wap.sl":{source:"iana"},"text/vnd.wap.wml":{source:"iana",extensions:["wml"]},"text/vnd.wap.wmlscript":{source:"iana",extensions:["wmls"]},"text/vtt":{charset:"UTF-8",compressible:!0,extensions:["vtt"]},"text/x-asm":{source:"apache",extensions:["s","asm"]},"text/x-c":{source:"apache",extensions:["c","cc","cxx","cpp","h","hh","dic"]},"text/x-component":{source:"nginx",extensions:["htc"]},"text/x-fortran":{source:"apache",extensions:["f","for","f77","f90"]},"text/x-gwt-rpc":{compressible:!0},"text/x-handlebars-template":{extensions:["hbs"]},"text/x-java-source":{source:"apache",extensions:["java"]},"text/x-jquery-tmpl":{compressible:!0},"text/x-lua":{extensions:["lua"]},"text/x-markdown":{compressible:!0,extensions:["mkd"]},"text/x-nfo":{source:"apache",extensions:["nfo"]},"text/x-opml":{source:"apache",extensions:["opml"]},"text/x-org":{compressible:!0,extensions:["org"]},"text/x-pascal":{source:"apache",extensions:["p","pas"]},"text/x-processing":{compressible:!0,extensions:["pde"]},"text/x-sass":{extensions:["sass"]},"text/x-scss":{extensions:["scss"]},"text/x-setext":{source:"apache",extensions:["etx"]},"text/x-sfv":{source:"apache",extensions:["sfv"]},"text/x-suse-ymp":{compressible:!0,extensions:["ymp"]},"text/x-uuencode":{source:"apache",extensions:["uu"]},"text/x-vcalendar":{source:"apache",extensions:["vcs"]},"text/x-vcard":{source:"apache",extensions:["vcf"]},"text/xml":{source:"iana",compressible:!0,extensions:["xml"]},"text/xml-external-parsed-entity":{source:"iana"},"text/yaml":{extensions:["yaml","yml"]},"video/1d-interleaved-parityfec":{source:"iana"},"video/3gpp":{source:"iana",extensions:["3gp","3gpp"]},"video/3gpp-tt":{source:"iana"},"video/3gpp2":{source:"iana",extensions:["3g2"]},"video/bmpeg":{source:"iana"},"video/bt656":{source:"iana"},"video/celb":{source:"iana"},"video/dv":{source:"iana"},"video/encaprtp":{source:"iana"},"video/h261":{source:"iana",extensions:["h261"]},"video/h263":{source:"iana",extensions:["h263"]},"video/h263-1998":{source:"iana"},"video/h263-2000":{source:"iana"},"video/h264":{source:"iana",extensions:["h264"]},"video/h264-rcdo":{source:"iana"},"video/h264-svc":{source:"iana"},"video/h265":{source:"iana"},"video/iso.segment":{source:"iana"},"video/jpeg":{source:"iana",extensions:["jpgv"]},"video/jpeg2000":{source:"iana"},"video/jpm":{source:"apache",extensions:["jpm","jpgm"]},"video/mj2":{source:"iana",extensions:["mj2","mjp2"]},"video/mp1s":{source:"iana"},"video/mp2p":{source:"iana"},"video/mp2t":{source:"iana",extensions:["ts"]},"video/mp4":{source:"iana",compressible:!1,extensions:["mp4","mp4v","mpg4"]},"video/mp4v-es":{source:"iana"},"video/mpeg":{source:"iana",compressible:!1,extensions:["mpeg","mpg","mpe","m1v","m2v"]},"video/mpeg4-generic":{source:"iana"},"video/mpv":{source:"iana"},"video/nv":{source:"iana"},"video/ogg":{source:"iana",compressible:!1,extensions:["ogv"]},"video/parityfec":{source:"iana"},"video/pointer":{source:"iana"},"video/quicktime":{source:"iana",compressible:!1,extensions:["qt","mov"]},"video/raptorfec":{source:"iana"},"video/raw":{source:"iana"},"video/rtp-enc-aescm128":{source:"iana"},"video/rtploopback":{source:"iana"},"video/rtx":{source:"iana"},"video/smpte291":{source:"iana"},"video/smpte292m":{source:"iana"},"video/ulpfec":{source:"iana"},"video/vc1":{source:"iana"},"video/vc2":{source:"iana"},"video/vnd.cctv":{source:"iana"},"video/vnd.dece.hd":{source:"iana",extensions:["uvh","uvvh"]},"video/vnd.dece.mobile":{source:"iana",extensions:["uvm","uvvm"]},"video/vnd.dece.mp4":{source:"iana"},"video/vnd.dece.pd":{source:"iana",extensions:["uvp","uvvp"]},"video/vnd.dece.sd":{source:"iana",extensions:["uvs","uvvs"]},"video/vnd.dece.video":{source:"iana",extensions:["uvv","uvvv"]},"video/vnd.directv.mpeg":{source:"iana"},"video/vnd.directv.mpeg-tts":{source:"iana"},"video/vnd.dlna.mpeg-tts":{source:"iana"},"video/vnd.dvb.file":{source:"iana",extensions:["dvb"]},"video/vnd.fvt":{source:"iana",extensions:["fvt"]},"video/vnd.hns.video":{source:"iana"},"video/vnd.iptvforum.1dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.1dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.2dparityfec-1010":{source:"iana"},"video/vnd.iptvforum.2dparityfec-2005":{source:"iana"},"video/vnd.iptvforum.ttsavc":{source:"iana"},"video/vnd.iptvforum.ttsmpeg2":{source:"iana"},"video/vnd.motorola.video":{source:"iana"},"video/vnd.motorola.videop":{source:"iana"},"video/vnd.mpegurl":{source:"iana",extensions:["mxu","m4u"]},"video/vnd.ms-playready.media.pyv":{source:"iana",extensions:["pyv"]},"video/vnd.nokia.interleaved-multimedia":{source:"iana"},"video/vnd.nokia.mp4vr":{source:"iana"},"video/vnd.nokia.videovoip":{source:"iana"},"video/vnd.objectvideo":{source:"iana"},"video/vnd.radgamettools.bink":{source:"iana"},"video/vnd.radgamettools.smacker":{source:"iana"},"video/vnd.sealed.mpeg1":{source:"iana"},"video/vnd.sealed.mpeg4":{source:"iana"},"video/vnd.sealed.swf":{source:"iana"},"video/vnd.sealedmedia.softseal.mov":{source:"iana"},"video/vnd.uvvu.mp4":{source:"iana",extensions:["uvu","uvvu"]},"video/vnd.vivo":{source:"iana",extensions:["viv"]},"video/vp8":{source:"iana"},"video/webm":{source:"apache",compressible:!1,extensions:["webm"]},"video/x-f4v":{source:"apache",extensions:["f4v"]},"video/x-fli":{source:"apache",extensions:["fli"]},"video/x-flv":{source:"apache",compressible:!1,extensions:["flv"]},"video/x-m4v":{source:"apache",extensions:["m4v"]},"video/x-matroska":{source:"apache",compressible:!1,extensions:["mkv","mk3d","mks"]},"video/x-mng":{source:"apache",extensions:["mng"]},"video/x-ms-asf":{source:"apache",extensions:["asf","asx"]},"video/x-ms-vob":{source:"apache",extensions:["vob"]},"video/x-ms-wm":{source:"apache",extensions:["wm"]},"video/x-ms-wmv":{source:"apache",compressible:!1,extensions:["wmv"]},"video/x-ms-wmx":{source:"apache",extensions:["wmx"]},"video/x-ms-wvx":{source:"apache",extensions:["wvx"]},"video/x-msvideo":{source:"apache",extensions:["avi"]},"video/x-sgi-movie":{source:"apache",extensions:["movie"]},"video/x-smv":{source:"apache",extensions:["smv"]},"x-conference/x-cooltalk":{source:"apache",extensions:["ice"]},"x-shader/x-fragment":{compressible:!0},"x-shader/x-vertex":{compressible:!0}}},function(e,t,n){e.exports=u,u.SSL=c;var r=n(14),i=n(131).Agent,o=n(16),s=n(16),a=n(169).Agent;function l(e,t){var n="";return n="string"==typeof e?e+":"+t:e.host+":"+e.port+":"+(e.localAddress?e.localAddress+":":":"),n}function u(e){var t=this;t.options=e||{},t.requests={},t.sockets={},t.freeSockets={},t.maxSockets=t.options.maxSockets||i.defaultMaxSockets,t.minSockets=t.options.minSockets||u.defaultMinSockets,t.on("free",function(e,n,r){var i=l(n,r);if(t.requests[i]&&t.requests[i].length)t.requests[i].shift().onSocket(e);else if(t.sockets[i].length<t.minSockets){t.freeSockets[i]||(t.freeSockets[i]=[]),t.freeSockets[i].push(e);var o=function(){e.destroy()};e._onIdleError=o,e.on("error",o)}else e.destroy()})}function c(e){u.call(this,e)}function h(e,t,n){return n="object"==typeof e?e:"object"==typeof t?t:"object"==typeof n?n:{},"number"==typeof e&&(n.port=e),"string"==typeof t&&(n.host=t),s.connect(n)}r.inherits(u,i),u.defaultMinSockets=5,u.prototype.createConnection=o.createConnection,u.prototype.addRequestNoreuse=i.prototype.addRequest,u.prototype.addRequest=function(e,t,n){var r=l(t,n);if("string"!=typeof t){var i=t;n=i.port,t=i.host}if(this.freeSockets[r]&&this.freeSockets[r].length>0&&!e.useChunkedEncodingByDefault){var o=this.freeSockets[r].pop();o.removeListener("error",o._onIdleError),delete o._onIdleError,e._reusedSocket=!0,e.onSocket(o)}else this.addRequestNoreuse(e,t,n)},u.prototype.removeSocket=function(e,t,n,r){if(this.sockets[t]){var i=this.sockets[t].indexOf(e);-1!==i&&this.sockets[t].splice(i,1)}else this.sockets[t]&&0===this.sockets[t].length&&(delete this.sockets[t],delete this.requests[t]);if(this.freeSockets[t]){var i=this.freeSockets[t].indexOf(e);-1!==i&&(this.freeSockets[t].splice(i,1),0===this.freeSockets[t].length&&delete this.freeSockets[t])}this.requests[t]&&this.requests[t].length&&this.createSocket(t,n,r).emit("free")},r.inherits(c,u),c.prototype.createConnection=h,c.prototype.addRequestNoreuse=a.prototype.addRequest},function(e,t){e.exports="object"==typeof self?self.FormData:window.FormData},function(e,t,n){"use strict";(function(t){function n(e){return e.replace(/^\.*/,".").toLowerCase()}function r(e){e=e.trim().toLowerCase();var t=e.split(":",2),r=n(t[0]),i=t[1],o=e.indexOf(":")>-1;return{hostname:r,port:i,hasPort:o}}function i(e,t){var i=e.port||("https:"===e.protocol?"443":"80"),o=n(e.hostname),s=t.split(",");return s.map(r).some(function(e){var t=o.indexOf(e.hostname),n=t>-1&&t===o.length-e.hostname.length;return e.hasPort?i===e.port&&n:n})}function o(e){var n=t.env.NO_PROXY||t.env.no_proxy||"";return"*"===n?null:""!==n&&i(e,n)?null:"http:"===e.protocol?t.env.HTTP_PROXY||t.env.http_proxy||null:"https:"===e.protocol&&(t.env.HTTPS_PROXY||t.env.https_proxy||t.env.HTTP_PROXY||t.env.http_proxy)||null}e.exports=o}).call(this,n(3))},function(e,t,n){"use strict";var r=n(621),i=n(145);function o(e){this.request=e,this.lib=null,this.useQuerystring=null,this.parseOptions=null,this.stringifyOptions=null}o.prototype.init=function(e){this.lib||(this.useQuerystring=e.useQuerystring,this.lib=this.useQuerystring?i:r,this.parseOptions=e.qsParseOptions||{},this.stringifyOptions=e.qsStringifyOptions||{})},o.prototype.stringify=function(e){return this.useQuerystring?this.rfc3986(this.lib.stringify(e,this.stringifyOptions.sep||null,this.stringifyOptions.eq||null,this.stringifyOptions)):this.lib.stringify(e,this.stringifyOptions)},o.prototype.parse=function(e){return this.useQuerystring?this.lib.parse(e,this.parseOptions.sep||null,this.parseOptions.eq||null,this.parseOptions):this.lib.parse(e,this.parseOptions)},o.prototype.rfc3986=function(e){return e.replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})},o.prototype.unescape=i.unescape,t.Querystring=o},function(e,t,n){"use strict";var r=n(622),i=n(623),o={brackets:function e(t){return t+"[]"},indices:function e(t,n){return t+"["+n+"]"},repeat:function e(t){return t}},s=Date.prototype.toISOString,a={delimiter:"&",encode:!0,encoder:r.encode,encodeValuesOnly:!1,serializeDate:function e(t){return s.call(t)},skipNulls:!1,strictNullHandling:!1},l=function e(t,n,i,o,s,l,u,c,h,f,p,d){var m=t;if("function"==typeof u)m=u(n,m);else if(m instanceof Date)m=f(m);else if(null===m){if(o)return l&&!d?l(n,a.encoder):n;m=""}if("string"==typeof m||"number"==typeof m||"boolean"==typeof m||r.isBuffer(m)){if(l){var g=d?n:l(n,a.encoder);return[p(g)+"="+p(l(m,a.encoder))]}return[p(n)+"="+p(String(m))]}var y=[],v;if(void 0===m)return y;if(Array.isArray(u))v=u;else{var b=Object.keys(m);v=c?b.sort(c):b}for(var _=0;_<v.length;++_){var w=v[_];s&&null===m[w]||(y=Array.isArray(m)?y.concat(e(m[w],i(n,w),i,o,s,l,u,c,h,f,p,d)):y.concat(e(m[w],n+(h?"."+w:"["+w+"]"),i,o,s,l,u,c,h,f,p,d)))}return y};e.exports=function(e,t){var n=e,s=t?r.assign({},t):{};if(null!==s.encoder&&void 0!==s.encoder&&"function"!=typeof s.encoder)throw new TypeError("Encoder has to be a function.");var u=void 0===s.delimiter?a.delimiter:s.delimiter,c="boolean"==typeof s.strictNullHandling?s.strictNullHandling:a.strictNullHandling,h="boolean"==typeof s.skipNulls?s.skipNulls:a.skipNulls,f="boolean"==typeof s.encode?s.encode:a.encode,p="function"==typeof s.encoder?s.encoder:a.encoder,d="function"==typeof s.sort?s.sort:null,m=void 0!==s.allowDots&&s.allowDots,g="function"==typeof s.serializeDate?s.serializeDate:a.serializeDate,y="boolean"==typeof s.encodeValuesOnly?s.encodeValuesOnly:a.encodeValuesOnly;if(void 0===s.format)s.format=i.default;else if(!Object.prototype.hasOwnProperty.call(i.formatters,s.format))throw new TypeError("Unknown format option provided.");var v=i.formatters[s.format],b,_;"function"==typeof s.filter?(_=s.filter,n=_("",n)):Array.isArray(s.filter)&&(_=s.filter,b=_);var w=[],k;if("object"!=typeof n||null===n)return"";k=s.arrayFormat in o?s.arrayFormat:"indices"in s?s.indices?"indices":"repeat":"indices";var E=o[k];b||(b=Object.keys(n)),d&&b.sort(d);for(var S=0;S<b.length;++S){var x=b[S];h&&null===n[x]||(w=w.concat(l(n[x],x,E,c,h,f?p:null,_,d,m,g,v,y)))}var C=w.join(u),A=!0===s.addQueryPrefix?"?":"";return C.length>0?A+C:""}},function(e,t,n){"use strict";var r=n(622),i=Object.prototype.hasOwnProperty,o={allowDots:!1,allowPrototypes:!1,arrayLimit:20,decoder:r.decode,delimiter:"&",depth:5,parameterLimit:1e3,plainObjects:!1,strictNullHandling:!1},s=function e(t,n){for(var r={},s=n.ignoreQueryPrefix?t.replace(/^\?/,""):t,a=n.parameterLimit===1/0?void 0:n.parameterLimit,l=s.split(n.delimiter,a),u=0;u<l.length;++u){var c=l[u],h=c.indexOf("]="),f=-1===h?c.indexOf("="):h+1,p,d;-1===f?(p=n.decoder(c,o.decoder),d=n.strictNullHandling?null:""):(p=n.decoder(c.slice(0,f),o.decoder),d=n.decoder(c.slice(f+1),o.decoder)),i.call(r,p)?r[p]=[].concat(r[p]).concat(d):r[p]=d}return r},a=function(e,t,n){for(var r=t,i=e.length-1;i>=0;--i){var o,s=e[i];if("[]"===s)o=[],o=o.concat(r);else{o=n.plainObjects?Object.create(null):{};var a="["===s.charAt(0)&&"]"===s.charAt(s.length-1)?s.slice(1,-1):s,l=parseInt(a,10);!isNaN(l)&&s!==a&&String(l)===a&&l>=0&&n.parseArrays&&l<=n.arrayLimit?(o=[],o[l]=r):o[a]=r}r=o}return r},l=function e(t,n,r){if(t){var o=r.allowDots?t.replace(/\.([^.[]+)/g,"[$1]"):t,s=/(\[[^[\]]*])/,l=/(\[[^[\]]*])/g,u=s.exec(o),c=u?o.slice(0,u.index):o,h=[];if(c){if(!r.plainObjects&&i.call(Object.prototype,c)&&!r.allowPrototypes)return;h.push(c)}for(var f=0;null!==(u=l.exec(o))&&f<r.depth;){if(f+=1,!r.plainObjects&&i.call(Object.prototype,u[1].slice(1,-1))&&!r.allowPrototypes)return;h.push(u[1])}return u&&h.push("["+o.slice(u.index)+"]"),a(h,n,r)}};e.exports=function(e,t){var n=t?r.assign({},t):{};if(null!==n.decoder&&void 0!==n.decoder&&"function"!=typeof n.decoder)throw new TypeError("Decoder has to be a function.");if(n.ignoreQueryPrefix=!0===n.ignoreQueryPrefix,n.delimiter="string"==typeof n.delimiter||r.isRegExp(n.delimiter)?n.delimiter:o.delimiter,n.depth="number"==typeof n.depth?n.depth:o.depth,n.arrayLimit="number"==typeof n.arrayLimit?n.arrayLimit:o.arrayLimit,n.parseArrays=!1!==n.parseArrays,n.decoder="function"==typeof n.decoder?n.decoder:o.decoder,n.allowDots="boolean"==typeof n.allowDots?n.allowDots:o.allowDots,n.plainObjects="boolean"==typeof n.plainObjects?n.plainObjects:o.plainObjects,n.allowPrototypes="boolean"==typeof n.allowPrototypes?n.allowPrototypes:o.allowPrototypes,n.parameterLimit="number"==typeof n.parameterLimit?n.parameterLimit:o.parameterLimit,n.strictNullHandling="boolean"==typeof n.strictNullHandling?n.strictNullHandling:o.strictNullHandling,""===e||null===e||void 0===e)return n.plainObjects?Object.create(null):{};for(var i="string"==typeof e?s(e,n):e,a=n.plainObjects?Object.create(null):{},u=Object.keys(i),c=0;c<u.length;++c){var h=u[c],f=l(h,i[h],n);a=r.merge(a,f,n)}return r.compact(a)}},function(e,t,n){"use strict";var r=n(16),i=n(145),o=n(1677),s=n(312);function a(e){this.request=e}a.prototype.reducer=function(e,t){if(void 0===e[t.name])return e[t.name]=t.value,e;var n=[e[t.name],t.value];return e[t.name]=n,e},a.prototype.prep=function(e){if(e.queryObj={},e.headersObj={},e.postData.jsonObj=!1,e.postData.paramsObj=!1,e.queryString&&e.queryString.length&&(e.queryObj=e.queryString.reduce(this.reducer,{})),e.headers&&e.headers.length&&(e.headersObj=e.headers.reduceRight(function(e,t){return e[t.name]=t.value,e},{})),e.cookies&&e.cookies.length){var t=e.cookies.map(function(e){return e.name+"="+e.value});t.length&&(e.headersObj.cookie=t.join("; "))}function n(t){return t.some(function(t){return 0===e.postData.mimeType.indexOf(t)})}if(n(["multipart/mixed","multipart/related","multipart/form-data","multipart/alternative"]))e.postData.mimeType="multipart/form-data";else if(n(["application/x-www-form-urlencoded"]))e.postData.params?(e.postData.paramsObj=e.postData.params.reduce(this.reducer,{}),e.postData.text=i.stringify(e.postData.paramsObj)):e.postData.text="";else if(n(["text/json","text/x-json","application/json","application/x-json"])&&(e.postData.mimeType="application/json",e.postData.text))try{e.postData.jsonObj=JSON.parse(e.postData.text)}catch(t){this.request.debug(t),e.postData.mimeType="text/plain"}return e},a.prototype.options=function(e){if(!e.har)return e;var t={};if(s(t,e.har),t.log&&t.log.entries&&(t=t.log.entries[0]),t.url=t.url||e.url||e.uri||e.baseUrl||"/",t.httpVersion=t.httpVersion||"HTTP/1.1",t.queryString=t.queryString||[],t.headers=t.headers||[],t.cookies=t.cookies||[],t.postData=t.postData||{},t.postData.mimeType=t.postData.mimeType||"application/octet-stream",t.bodySize=0,t.headersSize=0,t.postData.size=0,!o.request(t))return e;var n=this.prep(t);function i(e){return 0===n.postData.mimeType.indexOf(e)}return n.url&&(e.url=n.url),n.method&&(e.method=n.method),Object.keys(n.queryObj).length&&(e.qs=n.queryObj),Object.keys(n.headersObj).length&&(e.headers=n.headersObj),i("application/x-www-form-urlencoded")?e.form=n.postData.paramsObj:i("application/json")?n.postData.jsonObj&&(e.body=n.postData.jsonObj,e.json=!0):i("multipart/form-data")?(e.formData={},n.postData.params.forEach(function(t){var n={};t.fileName||t.fileName||t.contentType?(t.fileName&&!t.value?n.value=r.createReadStream(t.fileName):t.value&&(n.value=t.value),t.fileName&&(n.options={filename:t.fileName,contentType:t.contentType?t.contentType:null}),e.formData[t.name]=n):e.formData[t.name]=t.value})):n.postData.text&&(e.body=n.postData.text),e},t.Har=a},function(e,t,n){var r=n(1678),i=n(1711),o=n(1712),s;function a(){var e=new r({allErrors:!0});return e.addMetaSchema(n(1731)),e.addSchema(o),e}function l(e,t){t=t||{},s=s||a();var n=s.getSchema(e+".json");return new Promise(function(e,r){var o=n(t);o?e(t):r(new i(n.errors))})}t.afterRequest=function(e){return l("afterRequest",e)},t.beforeRequest=function(e){return l("beforeRequest",e)},t.browser=function(e){return l("browser",e)},t.cache=function(e){return l("cache",e)},t.content=function(e){return l("content",e)},t.cookie=function(e){return l("cookie",e)},t.creator=function(e){return l("creator",e)},t.entry=function(e){return l("entry",e)},t.har=function(e){return l("har",e)},t.header=function(e){return l("header",e)},t.log=function(e){return l("log",e)},t.page=function(e){return l("page",e)},t.pageTimings=function(e){return l("pageTimings",e)},t.postData=function(e){return l("postData",e)},t.query=function(e){return l("query",e)},t.request=function(e){return l("request",e)},t.response=function(e){return l("response",e)},t.timings=function(e){return l("timings",e)}},function(e,t,n){"use strict";var r=n(1679),i=n(321),o=n(1683),s=n(624),a=n(625),l=n(1684),u=n(1685),c=n(1706),h=n(143);e.exports=y,y.prototype.validate=v,y.prototype.compile=b,y.prototype.addSchema=_,y.prototype.addMetaSchema=w,y.prototype.validateSchema=k,y.prototype.getSchema=S,y.prototype.removeSchema=A,y.prototype.addFormat=D,y.prototype.errorsText=N,y.prototype._addSchema=I,y.prototype._compile=j,y.prototype.compileAsync=n(1707);var f=n(1708);y.prototype.addKeyword=f.add,y.prototype.getKeyword=f.get,y.prototype.removeKeyword=f.remove,y.prototype.validateKeyword=f.validate;var p=n(323);y.ValidationError=p.Validation,y.MissingRefError=p.MissingRef,y.$dataMetaSchema=c;var d="http://json-schema.org/draft-07/schema",m=["removeAdditional","useDefaults","coerceTypes","strictDefaults"],g=["/properties"];function y(e){if(!(this instanceof y))return new y(e);e=this._opts=h.copy(e)||{},z(this),this._schemas={},this._refs={},this._fragments={},this._formats=l(e.format),this._cache=e.cache||new o,this._loadingSchemas={},this._compilations=[],this.RULES=u(),this._getId=R(e),e.loopRequired=e.loopRequired||1/0,"property"==e.errorDataPath&&(e._errorDataPathProperty=!0),void 0===e.serialize&&(e.serialize=a),this._metaOpts=q(this),e.formats&&L(this),M(this),"object"==typeof e.meta&&this.addMetaSchema(e.meta),e.nullable&&this.addKeyword("nullable",{metaSchema:{type:"boolean"}}),F(this)}function v(e,t){var n;if("string"==typeof e){if(n=this.getSchema(e),!n)throw new Error('no schema with key or ref "'+e+'"')}else{var r=this._addSchema(e);n=r.validate||this._compile(r)}var i=n(t);return!0!==n.$async&&(this.errors=n.errors),i}function b(e,t){var n=this._addSchema(e,void 0,t);return n.validate||this._compile(n)}function _(e,t,n,r){if(Array.isArray(e)){for(var o=0;o<e.length;o++)this.addSchema(e[o],void 0,n,r);return this}var s=this._getId(e);if(void 0!==s&&"string"!=typeof s)throw new Error("schema id must be string");return t=i.normalizeId(t||s),U(this,t),this._schemas[t]=this._addSchema(e,n,r,!0),this}function w(e,t,n){return this.addSchema(e,t,n,!0),this}function k(e,t){var n=e.$schema;if(void 0!==n&&"string"!=typeof n)throw new Error("$schema must be a string");if(n=n||this._opts.defaultMeta||E(this),!n)return this.logger.warn("meta-schema not available"),this.errors=null,!0;var r=this.validate(n,e);if(!r&&t){var i="schema is invalid: "+this.errorsText();if("log"!=this._opts.validateSchema)throw new Error(i);this.logger.error(i)}return r}function E(e){var t=e._opts.meta;return e._opts.defaultMeta="object"==typeof t?e._getId(t)||t:e.getSchema(d)?d:void 0,e._opts.defaultMeta}function S(e){var t=C(this,e);switch(typeof t){case"object":return t.validate||this._compile(t);case"string":return this.getSchema(t);case"undefined":return x(this,e)}}function x(e,t){var n=i.schema.call(e,{schema:{}},t);if(n){var o=n.schema,a=n.root,l=n.baseId,u=r.call(e,o,a,void 0,l);return e._fragments[t]=new s({ref:t,fragment:!0,schema:o,root:a,baseId:l,validate:u}),u}}function C(e,t){return t=i.normalizeId(t),e._schemas[t]||e._refs[t]||e._fragments[t]}function A(e){if(e instanceof RegExp)return T(this,this._schemas,e),T(this,this._refs,e),this;switch(typeof e){case"undefined":return T(this,this._schemas),T(this,this._refs),this._cache.clear(),this;case"string":var t=C(this,e);return t&&this._cache.del(t.cacheKey),delete this._schemas[e],delete this._refs[e],this;case"object":var n=this._opts.serialize,r=n?n(e):e;this._cache.del(r);var o=this._getId(e);o&&(o=i.normalizeId(o),delete this._schemas[o],delete this._refs[o])}return this}function T(e,t,n){for(var r in t){var i=t[r];i.meta||n&&!n.test(r)||(e._cache.del(i.cacheKey),delete t[r])}}function I(e,t,n,r){if("object"!=typeof e&&"boolean"!=typeof e)throw new Error("schema should be object or boolean");var o=this._opts.serialize,a=o?o(e):e,l=this._cache.get(a);if(l)return l;r=r||!1!==this._opts.addUsedSchema;var u=i.normalizeId(this._getId(e));u&&r&&U(this,u);var c=!1!==this._opts.validateSchema&&!t,h;c&&!(h=u&&u==i.normalizeId(e.$schema))&&this.validateSchema(e,!0);var f=i.ids.call(this,e),p=new s({id:u,schema:e,localRefs:f,cacheKey:a,meta:n});return"#"!=u[0]&&r&&(this._refs[u]=p),this._cache.put(a,p),c&&h&&this.validateSchema(e,!0),p}function j(e,t){if(e.compiling)return e.validate=o,o.schema=e.schema,o.errors=null,o.root=t||o,!0===e.schema.$async&&(o.$async=!0),o;var n,i;e.compiling=!0,e.meta&&(n=this._opts,this._opts=this._metaOpts);try{i=r.call(this,e.schema,t,e.localRefs)}catch(t){throw delete e.validate,t}finally{e.compiling=!1,e.meta&&(this._opts=n)}return e.validate=i,e.refs=i.refs,e.refVal=i.refVal,e.root=i.root,i;function o(){var t=e.validate,n=t.apply(this,arguments);return o.errors=t.errors,n}}function R(e){switch(e.schemaId){case"auto":return P;case"id":return B;default:return O}}function B(e){return e.$id&&this.logger.warn("schema $id ignored",e.$id),e.id}function O(e){return e.id&&this.logger.warn("schema id ignored",e.id),e.$id}function P(e){if(e.$id&&e.id&&e.$id!=e.id)throw new Error("schema $id is different from id");return e.$id||e.id}function N(e,t){if(e=e||this.errors,!e)return"No errors";t=t||{};for(var n=void 0===t.separator?", ":t.separator,r=void 0===t.dataVar?"data":t.dataVar,i="",o=0;o<e.length;o++){var s=e[o];s&&(i+=r+s.dataPath+" "+s.message+n)}return i.slice(0,-n.length)}function D(e,t){return"string"==typeof t&&(t=new RegExp(t)),this._formats[e]=t,this}function M(e){var t;if(e._opts.$data&&(t=n(1710),e.addMetaSchema(t,t.$id,!0)),!1!==e._opts.meta){var r=n(631);e._opts.$data&&(r=c(r,g)),e.addMetaSchema(r,d,!0),e._refs["http://json-schema.org/schema"]=d}}function F(e){var t=e._opts.schemas;if(t)if(Array.isArray(t))e.addSchema(t);else for(var n in t)e.addSchema(t[n],n)}function L(e){for(var t in e._opts.formats){var n=e._opts.formats[t];e.addFormat(t,n)}}function U(e,t){if(e._schemas[t]||e._refs[t])throw new Error('schema with key or id "'+t+'" already exists')}function q(e){for(var t=h.copy(e._opts),n=0;n<m.length;n++)delete t[m[n]];return t}function z(e){var t=e._opts.logger;if(!1===t)e.logger={log:K,warn:K,error:K};else{if(void 0===t&&(t=console),!("object"==typeof t&&t.log&&t.warn&&t.error))throw new Error("logger must implement log, warn and error methods");e.logger=t}}function K(){}},function(e,t,n){"use strict";var r=n(321),i=n(143),o=n(323),s=n(625),a=n(626),l=i.ucs2length,u=n(322),c=o.Validation;function h(e,t,n,d){var _=this,w=this._opts,k=[void 0],E={},S=[],x={},C=[],A={},T=[];t=t||{schema:e,refVal:k,refs:E};var I=f.call(this,e,t,d),j=this._compilations[I.index];if(I.compiling)return j.callValidate=N;var R=this._formats,B=this.RULES;try{var O=D(e,t,n,d);j.validate=O;var P=j.callValidate;return P&&(P.schema=O.schema,P.errors=null,P.refs=O.refs,P.refVal=O.refVal,P.root=O.root,P.$async=O.$async,w.sourceCode&&(P.source=O.source)),O}finally{p.call(this,e,t,d)}function N(){var e=j.validate,t=e.apply(this,arguments);return N.errors=e.errors,t}function D(e,n,s,f){var p=!n||n&&n.schema==e;if(n.schema!=t.schema)return h.call(_,e,n,s,f);var d=!0===e.$async,x=a({isTop:!0,schema:e,isRoot:p,baseId:f,root:n,schemaPath:"",errSchemaPath:"#",errorPath:'""',MissingRefError:o.MissingRef,RULES:B,validate:a,util:i,resolve:r,resolveRef:M,usePattern:z,useDefault:K,useCustomRule:H,opts:w,formats:R,logger:_.logger,self:_}),A;x=b(k,y)+b(S,m)+b(C,g)+b(T,v)+x,w.processCode&&(x=w.processCode(x));try{var I=new Function("self","RULES","formats","root","refVal","defaults","customRules","equal","ucs2length","ValidationError",x);A=I(_,B,R,t,k,C,T,u,l,c),k[0]=A}catch(e){throw _.logger.error("Error compiling schema, function code:",x),e}return A.schema=e,A.errors=null,A.refs=E,A.refVal=k,A.root=p?A:n,d&&(A.$async=!0),!0===w.sourceCode&&(A.source={code:x,patterns:S,defaults:C}),A}function M(e,i,o){i=r.url(e,i);var s=E[i],a,l;if(void 0!==s)return a=k[s],l="refVal["+s+"]",q(a,l);if(!o&&t.refs){var u=t.refs[i];if(void 0!==u)return a=t.refVal[u],l=F(i,a),q(a,l)}l=F(i);var c=r.call(_,D,t,i);if(void 0===c){var f=n&&n[i];f&&(c=r.inlineRef(f,w.inlineRefs)?f:h.call(_,f,t,n,e))}if(void 0!==c)return U(i,c),q(c,l);L(i)}function F(e,t){var n=k.length;return k[n]=t,E[e]=n,"refVal"+n}function L(e){delete E[e]}function U(e,t){var n=E[e];k[n]=t}function q(e,t){return"object"==typeof e||"boolean"==typeof e?{code:t,schema:e,inline:!0}:{code:t,$async:e&&!!e.$async}}function z(e){var t=x[e];return void 0===t&&(t=x[e]=S.length,S[t]=e),"pattern"+t}function K(e){switch(typeof e){case"boolean":case"number":return""+e;case"string":return i.toQuotedString(e);case"object":if(null===e)return"null";var t=s(e),n=A[t];return void 0===n&&(n=A[t]=C.length,C[n]=e),"default"+n}}function H(e,t,n,r){if(!1!==_._opts.validateSchema){var i=e.definition.dependencies;if(i&&!i.every(function(e){return Object.prototype.hasOwnProperty.call(n,e)}))throw new Error("parent schema must have all required keywords: "+i.join(","));var o=e.definition.validateSchema;if(o){var s=o(t);if(!s){var a="keyword schema is invalid: "+_.errorsText(o.errors);if("log"!=_._opts.validateSchema)throw new Error(a);_.logger.error(a)}}}var l=e.definition.compile,u=e.definition.inline,c=e.definition.macro,h;if(l)h=l.call(_,t,n,r);else if(c)h=c.call(_,t,n,r),!1!==w.validateSchema&&_.validateSchema(h,!0);else if(u)h=u.call(_,r,e.keyword,t,n);else if(h=e.definition.validate,!h)return;if(void 0===h)throw new Error('custom keyword "'+e.keyword+'"failed to compile');var f=T.length;return T[f]=h,{code:"customRule"+f,validate:h}}}function f(e,t,n){var r=d.call(this,e,t,n);return r>=0?{index:r,compiling:!0}:(r=this._compilations.length,this._compilations[r]={schema:e,root:t,baseId:n},{index:r,compiling:!1})}function p(e,t,n){var r=d.call(this,e,t,n);r>=0&&this._compilations.splice(r,1)}function d(e,t,n){for(var r=0;r<this._compilations.length;r++){var i=this._compilations[r];if(i.schema==e&&i.root==t&&i.baseId==n)return r}return-1}function m(e,t){return"var pattern"+e+" = new RegExp("+i.toQuotedString(t[e])+");"}function g(e){return"var default"+e+" = defaults["+e+"];"}function y(e,t){return void 0===t[e]?"":"var refVal"+e+" = refVal["+e+"];"}function v(e){return"var customRule"+e+" = customRules["+e+"];"}function b(e,t){if(!e.length)return"";for(var n="",r=0;r<e.length;r++)n+=t(r,e);return n}e.exports=h},function(e,t,n){
/** @license URI.js v4.2.1 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js */var r,i;r=this,i=function(e){"use strict";function t(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(t.length>1){t[0]=t[0].slice(0,-1);for(var r=t.length-1,i=1;i<r;++i)t[i]=t[i].slice(1,-1);return t[r]=t[r].slice(1),t.join("")}return t[0]}function n(e){return"(?:"+e+")"}function r(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function i(e){return e.toUpperCase()}function o(e){return void 0!==e&&null!==e?e instanceof Array?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}function s(e,t){var n=e;if(t)for(var r in t)n[r]=t[r];return n}function a(e){var r="[A-Za-z]",i="[\\x0D]",o="[0-9]",s="[\\x22]",a=t("[0-9]","[A-Fa-f]"),l="[\\x0A]",u="[\\x20]",c=n(n("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+n("%[89A-Fa-f]"+a+"%"+a+a)+"|"+n("%"+a+a)),h="[\\:\\/\\?\\#\\[\\]\\@]",f="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",p=t(h,f),d=e?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",m=e?"[\\uE000-\\uF8FF]":"[]",g=t(r,"[0-9]","[\\-\\.\\_\\~]",d),y=n(r+t(r,"[0-9]","[\\+\\-\\.]")+"*"),v=n(n(c+"|"+t(g,f,"[\\:]"))+"*"),b=n(n("25[0-5]")+"|"+n("2[0-4][0-9]")+"|"+n("1[0-9][0-9]")+"|"+n("[1-9][0-9]")+"|[0-9]"),_=n(n("25[0-5]")+"|"+n("2[0-4][0-9]")+"|"+n("1[0-9][0-9]")+"|"+n("0?[1-9][0-9]")+"|0?0?[0-9]"),w=n(_+"\\."+_+"\\."+_+"\\."+_),k=n(a+"{1,4}"),E=n(n(k+"\\:"+k)+"|"+w),S=n(n(k+"\\:")+"{6}"+E),x=n("\\:\\:"+n(k+"\\:")+"{5}"+E),C=n(n(k)+"?\\:\\:"+n(k+"\\:")+"{4}"+E),A=n(n(n(k+"\\:")+"{0,1}"+k)+"?\\:\\:"+n(k+"\\:")+"{3}"+E),T=n(n(n(k+"\\:")+"{0,2}"+k)+"?\\:\\:"+n(k+"\\:")+"{2}"+E),I=n(n(n(k+"\\:")+"{0,3}"+k)+"?\\:\\:"+k+"\\:"+E),j=n(n(n(k+"\\:")+"{0,4}"+k)+"?\\:\\:"+E),R=n(n(n(k+"\\:")+"{0,5}"+k)+"?\\:\\:"+k),B=n(n(n(k+"\\:")+"{0,6}"+k)+"?\\:\\:"),O=n([S,x,C,A,T,I,j,R,B].join("|")),P=n(n(g+"|"+c)+"+"),N=n(O+"\\%25"+P),D=n(O+n("\\%25|\\%(?!"+a+"{2})")+P),M=n("[vV]"+a+"+\\."+t(g,f,"[\\:]")+"+"),F=n("\\["+n(D+"|"+O+"|"+M)+"\\]"),L=n(n(c+"|"+t(g,f))+"*"),U=n(F+"|"+w+"(?!"+L+")|"+L),q=n("[0-9]*"),z=n(n(v+"@")+"?"+U+n("\\:"+q)+"?"),K=n(c+"|"+t(g,f,"[\\:\\@]")),H=n(K+"*"),V=n(K+"+"),$=n(n(c+"|"+t(g,f,"[\\@]"))+"+"),W=n(n("\\/"+H)+"*"),G=n("\\/"+n(V+W)+"?"),Y=n($+W),Z=n(V+W),J="(?!"+K+")",Q=n(W+"|"+G+"|"+Y+"|"+Z+"|"+J),X=n(n(K+"|"+t("[\\/\\?]",m))+"*"),ee=n(n(K+"|[\\/\\?]")+"*"),te=n(n("\\/\\/"+z+W)+"|"+G+"|"+Z+"|"+J),ne=n(y+"\\:"+te+n("\\?"+X)+"?"+n("\\#"+ee)+"?"),re=n(n("\\/\\/"+z+W)+"|"+G+"|"+Y+"|"+J),ie=n(re+n("\\?"+X)+"?"+n("\\#"+ee)+"?"),oe=n(ne+"|"+ie),se=n(y+"\\:"+te+n("\\?"+X)+"?"),ae="^("+y+")\\:"+n(n("\\/\\/("+n("("+v+")@")+"?("+U+")"+n("\\:("+q+")")+"?)")+"?("+W+"|"+G+"|"+Z+"|"+J+")")+n("\\?("+X+")")+"?"+n("\\#("+ee+")")+"?$",le="^(){0}"+n(n("\\/\\/("+n("("+v+")@")+"?("+U+")"+n("\\:("+q+")")+"?)")+"?("+W+"|"+G+"|"+Y+"|"+J+")")+n("\\?("+X+")")+"?"+n("\\#("+ee+")")+"?$",ue="^("+y+")\\:"+n(n("\\/\\/("+n("("+v+")@")+"?("+U+")"+n("\\:("+q+")")+"?)")+"?("+W+"|"+G+"|"+Z+"|"+J+")")+n("\\?("+X+")")+"?$",ce="^"+n("\\#("+ee+")")+"?$",he="^"+n("("+v+")@")+"?("+U+")"+n("\\:("+q+")")+"?$";return{NOT_SCHEME:new RegExp(t("[^]",r,"[0-9]","[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(t("[^\\%\\:]",g,f),"g"),NOT_HOST:new RegExp(t("[^\\%\\[\\]\\:]",g,f),"g"),NOT_PATH:new RegExp(t("[^\\%\\/\\:\\@]",g,f),"g"),NOT_PATH_NOSCHEME:new RegExp(t("[^\\%\\/\\@]",g,f),"g"),NOT_QUERY:new RegExp(t("[^\\%]",g,f,"[\\:\\@\\/\\?]",m),"g"),NOT_FRAGMENT:new RegExp(t("[^\\%]",g,f,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(t("[^]",g,f),"g"),UNRESERVED:new RegExp(g,"g"),OTHER_CHARS:new RegExp(t("[^\\%]",g,p),"g"),PCT_ENCODED:new RegExp(c,"g"),IPV4ADDRESS:new RegExp("^("+w+")$"),IPV6ADDRESS:new RegExp("^\\[?("+O+")"+n(n("\\%25|\\%(?!"+a+"{2})")+"("+P+")")+"?\\]?$")}}var l=a(!1),u=a(!0),c=function(){function e(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var s=e[Symbol.iterator](),a;!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){i=!0,o=e}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}return function(t,n){if(Array.isArray(t))return t;if(Symbol.iterator in Object(t))return e(t,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),h=function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)},f=2147483647,p=36,d=1,m=26,g=38,y=700,v=72,b=128,_="-",w=/^xn--/,k=/[^\0-\x7E]/,E=/[\x2E\u3002\uFF0E\uFF61]/g,S={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},x=35,C=Math.floor,A=String.fromCharCode;function T(e){throw new RangeError(S[e])}function I(e,t){for(var n=[],r=e.length;r--;)n[r]=t(e[r]);return n}function j(e,t){var n=e.split("@"),r="";n.length>1&&(r=n[0]+"@",e=n[1]),e=e.replace(E,".");var i=e.split("."),o=I(i,t).join(".");return r+o}function R(e){for(var t=[],n=0,r=e.length;n<r;){var i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){var o=e.charCodeAt(n++);56320==(64512&o)?t.push(((1023&i)<<10)+(1023&o)+65536):(t.push(i),n--)}else t.push(i)}return t}var B=function e(t){return String.fromCodePoint.apply(String,h(t))},O=function e(t){return t-48<10?t-22:t-65<26?t-65:t-97<26?t-97:36},P=function e(t,n){return t+22+75*(t<26)-((0!=n)<<5)},N=function e(t,n,r){var i=0;for(t=r?C(t/700):t>>1,t+=C(t/n);t>455;i+=36)t=C(t/35);return C(i+36*t/(t+38))},D=function e(t){var n=[],r=t.length,i=0,o=128,s=72,a=t.lastIndexOf("-");a<0&&(a=0);for(var l=0;l<a;++l)t.charCodeAt(l)>=128&&T("not-basic"),n.push(t.charCodeAt(l));for(var u=a>0?a+1:0;u<r;){for(var c=i,h=1,p=36;;p+=36){u>=r&&T("invalid-input");var d=O(t.charCodeAt(u++));(d>=36||d>C((f-i)/h))&&T("overflow"),i+=d*h;var m=p<=s?1:p>=s+26?26:p-s;if(d<m)break;var g=36-m;h>C(f/g)&&T("overflow"),h*=g}var y=n.length+1;s=N(i-c,y,0==c),C(i/y)>f-o&&T("overflow"),o+=C(i/y),i%=y,n.splice(i++,0,o)}return String.fromCodePoint.apply(String,n)},M=function e(t){var n=[];t=R(t);var r=t.length,i=128,o=0,s=72,a=!0,l=!1,u=void 0;try{for(var c=t[Symbol.iterator](),h;!(a=(h=c.next()).done);a=!0){var p=h.value;p<128&&n.push(A(p))}}catch(e){l=!0,u=e}finally{try{!a&&c.return&&c.return()}finally{if(l)throw u}}var d=n.length,m=d;for(d&&n.push("-");m<r;){var g=f,y=!0,v=!1,b=void 0;try{for(var _=t[Symbol.iterator](),w;!(y=(w=_.next()).done);y=!0){var k=w.value;k>=i&&k<g&&(g=k)}}catch(e){v=!0,b=e}finally{try{!y&&_.return&&_.return()}finally{if(v)throw b}}var E=m+1;g-i>C((f-o)/E)&&T("overflow"),o+=(g-i)*E,i=g;var S=!0,x=!1,I=void 0;try{for(var j=t[Symbol.iterator](),B;!(S=(B=j.next()).done);S=!0){var O=B.value;if(O<i&&++o>f&&T("overflow"),O==i){for(var D=o,M=36;;M+=36){var F=M<=s?1:M>=s+26?26:M-s;if(D<F)break;var L=D-F,U=36-F;n.push(A(P(F+L%U,0))),D=C(L/U)}n.push(A(P(D,0))),s=N(o,E,m==d),o=0,++m}}}catch(e){x=!0,I=e}finally{try{!S&&j.return&&j.return()}finally{if(x)throw I}}++o,++i}return n.join("")},F=function e(t){return j(t,function(e){return w.test(e)?D(e.slice(4).toLowerCase()):e})},L=function e(t){return j(t,function(e){return k.test(e)?"xn--"+M(e):e})},U={version:"2.1.0",ucs2:{decode:R,encode:B},decode:D,encode:M,toASCII:L,toUnicode:F},q={};function z(e){var t=e.charCodeAt(0),n=void 0;return n=t<16?"%0"+t.toString(16).toUpperCase():t<128?"%"+t.toString(16).toUpperCase():t<2048?"%"+(t>>6|192).toString(16).toUpperCase()+"%"+(63&t|128).toString(16).toUpperCase():"%"+(t>>12|224).toString(16).toUpperCase()+"%"+(t>>6&63|128).toString(16).toUpperCase()+"%"+(63&t|128).toString(16).toUpperCase(),n}function K(e){for(var t="",n=0,r=e.length;n<r;){var i=parseInt(e.substr(n+1,2),16);if(i<128)t+=String.fromCharCode(i),n+=3;else if(i>=194&&i<224){if(r-n>=6){var o=parseInt(e.substr(n+4,2),16);t+=String.fromCharCode((31&i)<<6|63&o)}else t+=e.substr(n,6);n+=6}else if(i>=224){if(r-n>=9){var s=parseInt(e.substr(n+4,2),16),a=parseInt(e.substr(n+7,2),16);t+=String.fromCharCode((15&i)<<12|(63&s)<<6|63&a)}else t+=e.substr(n,9);n+=9}else t+=e.substr(n,3),n+=3}return t}function H(e,t){function n(e){var n=K(e);return n.match(t.UNRESERVED)?n:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,n).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,n).replace(t.NOT_USERINFO,z).replace(t.PCT_ENCODED,i)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,n).toLowerCase().replace(t.NOT_HOST,z).replace(t.PCT_ENCODED,i)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,n).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,z).replace(t.PCT_ENCODED,i)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,n).replace(t.NOT_QUERY,z).replace(t.PCT_ENCODED,i)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,n).replace(t.NOT_FRAGMENT,z).replace(t.PCT_ENCODED,i)),e}function V(e){return e.replace(/^0*(.*)/,"$1")||"0"}function $(e,t){var n=e.match(t.IPV4ADDRESS)||[],r=c(n,2),i=r[1];return i?i.split(".").map(V).join("."):e}function W(e,t){var n=e.match(t.IPV6ADDRESS)||[],r=c(n,3),i=r[1],o=r[2];if(i){for(var s=i.toLowerCase().split("::").reverse(),a=c(s,2),l=a[0],u=a[1],h=u?u.split(":").map(V):[],f=l.split(":").map(V),p=t.IPV4ADDRESS.test(f[f.length-1]),d=p?7:8,m=f.length-d,g=Array(d),y=0;y<d;++y)g[y]=h[y]||f[m+y]||"";p&&(g[d-1]=$(g[d-1],t));var v=g.reduce(function(e,t,n){if(!t||"0"===t){var r=e[e.length-1];r&&r.index+r.length===n?r.length++:e.push({index:n,length:1})}return e},[]),b=v.sort(function(e,t){return t.length-e.length})[0],_=void 0;if(b&&b.length>1){var w=g.slice(0,b.index),k=g.slice(b.index+b.length);_=w.join(":")+"::"+k.join(":")}else _=g.join(":");return o&&(_+="%"+o),_}return e}var G=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?(\[[^\/?#\]]+\]|[^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n|\r)*))?/i,Y=void 0==="".match(/(){0}/)[1];function Z(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n={},r=!1!==t.iri?u:l;"suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e);var i=e.match(G);if(i){Y?(n.scheme=i[1],n.userinfo=i[3],n.host=i[4],n.port=parseInt(i[5],10),n.path=i[6]||"",n.query=i[7],n.fragment=i[8],isNaN(n.port)&&(n.port=i[5])):(n.scheme=i[1]||void 0,n.userinfo=-1!==e.indexOf("@")?i[3]:void 0,n.host=-1!==e.indexOf("//")?i[4]:void 0,n.port=parseInt(i[5],10),n.path=i[6]||"",n.query=-1!==e.indexOf("?")?i[7]:void 0,n.fragment=-1!==e.indexOf("#")?i[8]:void 0,isNaN(n.port)&&(n.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?i[4]:void 0)),n.host&&(n.host=W($(n.host,r),r)),void 0!==n.scheme||void 0!==n.userinfo||void 0!==n.host||void 0!==n.port||n.path||void 0!==n.query?void 0===n.scheme?n.reference="relative":void 0===n.fragment?n.reference="absolute":n.reference="uri":n.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==n.reference&&(n.error=n.error||"URI is not a "+t.reference+" reference.");var o=q[(t.scheme||n.scheme||"").toLowerCase()];if(t.unicodeSupport||o&&o.unicodeSupport)H(n,r);else{if(n.host&&(t.domainHost||o&&o.domainHost))try{n.host=U.toASCII(n.host.replace(r.PCT_ENCODED,K).toLowerCase())}catch(e){n.error=n.error||"Host's domain name can not be converted to ASCII via punycode: "+e}H(n,l)}o&&o.parse&&o.parse(n,t)}else n.error=n.error||"URI can not be parsed.";return n}function J(e,t){var n=!1!==t.iri?u:l,r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(W($(String(e.host),n),n).replace(n.IPV6ADDRESS,function(e,t,n){return"["+t+(n?"%25"+n:"")+"]"})),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}var Q=/^\.\.?\//,X=/^\/\.(\/|$)/,ee=/^\/\.\.(\/|$)/,te=/^\/?(?:.|\n)*?(?=\/|$)/;function ne(e){for(var t=[];e.length;)if(e.match(Q))e=e.replace(Q,"");else if(e.match(X))e=e.replace(X,"/");else if(e.match(ee))e=e.replace(ee,"/"),t.pop();else if("."===e||".."===e)e="";else{var n=e.match(te);if(!n)throw new Error("Unexpected dot segment condition");var r=n[0];e=e.slice(r.length),t.push(r)}return t.join("")}function re(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.iri?u:l,r=[],i=q[(t.scheme||e.scheme||"").toLowerCase()];if(i&&i.serialize&&i.serialize(e,t),e.host)if(n.IPV6ADDRESS.test(e.host));else if(t.domainHost||i&&i.domainHost)try{e.host=t.iri?U.toUnicode(e.host):U.toASCII(e.host.replace(n.PCT_ENCODED,K).toLowerCase())}catch(n){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+n}H(e,n),"suffix"!==t.reference&&e.scheme&&(r.push(e.scheme),r.push(":"));var o=J(e,t);if(void 0!==o&&("suffix"!==t.reference&&r.push("//"),r.push(o),e.path&&"/"!==e.path.charAt(0)&&r.push("/")),void 0!==e.path){var s=e.path;t.absolutePath||i&&i.absolutePath||(s=ne(s)),void 0===o&&(s=s.replace(/^\/\//,"/%2F")),r.push(s)}return void 0!==e.query&&(r.push("?"),r.push(e.query)),void 0!==e.fragment&&(r.push("#"),r.push(e.fragment)),r.join("")}function ie(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments[3],i={};return r||(e=Z(re(e,n),n),t=Z(re(t,n),n)),n=n||{},!n.tolerant&&t.scheme?(i.scheme=t.scheme,i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=ne(t.path||""),i.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(i.userinfo=t.userinfo,i.host=t.host,i.port=t.port,i.path=ne(t.path||""),i.query=t.query):(t.path?("/"===t.path.charAt(0)?i.path=ne(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?i.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:i.path=t.path:i.path="/"+t.path,i.path=ne(i.path)),i.query=t.query):(i.path=e.path,void 0!==t.query?i.query=t.query:i.query=e.query),i.userinfo=e.userinfo,i.host=e.host,i.port=e.port),i.scheme=e.scheme),i.fragment=t.fragment,i}function oe(e,t,n){var r=s({scheme:"null"},n);return re(ie(Z(e,r),Z(t,r),r,!0),r)}function se(e,t){return"string"==typeof e?e=re(Z(e,t),t):"object"===r(e)&&(e=Z(re(e,t),t)),e}function ae(e,t,n){return"string"==typeof e?e=re(Z(e,n),n):"object"===r(e)&&(e=re(e,n)),"string"==typeof t?t=re(Z(t,n),n):"object"===r(t)&&(t=re(t,n)),e===t}function le(e,t){return e&&e.toString().replace(t&&t.iri?u.ESCAPE:l.ESCAPE,z)}function ue(e,t){return e&&e.toString().replace(t&&t.iri?u.PCT_ENCODED:l.PCT_ENCODED,K)}var ce={scheme:"http",domainHost:!0,parse:function e(t,n){return t.host||(t.error=t.error||"HTTP URIs must have a host."),t},serialize:function e(t,n){return t.port!==("https"!==String(t.scheme).toLowerCase()?80:443)&&""!==t.port||(t.port=void 0),t.path||(t.path="/"),t}},he={scheme:"https",domainHost:ce.domainHost,parse:ce.parse,serialize:ce.serialize},fe={},pe=!0,de="[A-Za-z0-9\\-\\.\\_\\~\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]",me="[0-9A-Fa-f]",ge=n(n("%[EFef][0-9A-Fa-f]%"+me+me+"%"+me+me)+"|"+n("%[89A-Fa-f][0-9A-Fa-f]%"+me+me)+"|"+n("%"+me+me)),ye="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",ve="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",be=t(ve,'[\\"\\\\]'),_e="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",we=new RegExp(de,"g"),ke=new RegExp(ge,"g"),Ee=new RegExp(t("[^]",ye,"[\\.]",'[\\"]',be),"g"),Se=new RegExp(t("[^]",de,_e),"g"),xe=Se;function Ce(e){var t=K(e);return t.match(we)?t:e}var Ae={scheme:"mailto",parse:function e(t,n){var r=t,i=r.to=r.path?r.path.split(","):[];if(r.path=void 0,r.query){for(var o=!1,s={},a=r.query.split("&"),l=0,u=a.length;l<u;++l){var c=a[l].split("=");switch(c[0]){case"to":for(var h=c[1].split(","),f=0,p=h.length;f<p;++f)i.push(h[f]);break;case"subject":r.subject=ue(c[1],n);break;case"body":r.body=ue(c[1],n);break;default:o=!0,s[ue(c[0],n)]=ue(c[1],n)}}o&&(r.headers=s)}r.query=void 0;for(var d=0,m=i.length;d<m;++d){var g=i[d].split("@");if(g[0]=ue(g[0]),n.unicodeSupport)g[1]=ue(g[1],n).toLowerCase();else try{g[1]=U.toASCII(ue(g[1],n).toLowerCase())}catch(e){r.error=r.error||"Email address's domain name can not be converted to ASCII via punycode: "+e}i[d]=g.join("@")}return r},serialize:function e(t,n){var r=t,s=o(t.to);if(s){for(var a=0,l=s.length;a<l;++a){var u=String(s[a]),c=u.lastIndexOf("@"),h=u.slice(0,c).replace(ke,Ce).replace(ke,i).replace(Ee,z),f=u.slice(c+1);try{f=n.iri?U.toUnicode(f):U.toASCII(ue(f,n).toLowerCase())}catch(e){r.error=r.error||"Email address's domain name can not be converted to "+(n.iri?"Unicode":"ASCII")+" via punycode: "+e}s[a]=h+"@"+f}r.path=s.join(",")}var p=t.headers=t.headers||{};t.subject&&(p.subject=t.subject),t.body&&(p.body=t.body);var d=[];for(var m in p)p[m]!==fe[m]&&d.push(m.replace(ke,Ce).replace(ke,i).replace(Se,z)+"="+p[m].replace(ke,Ce).replace(ke,i).replace(xe,z));return d.length&&(r.query=d.join("&")),r}},Te=/^([^\:]+)\:(.*)/,Ie={scheme:"urn",parse:function e(t,n){var r=t.path&&t.path.match(Te),i=t;if(r){var o=n.scheme||i.scheme||"urn",s=r[1].toLowerCase(),a=r[2],l=o+":"+(n.nid||s),u=q[l];i.nid=s,i.nss=a,i.path=void 0,u&&(i=u.parse(i,n))}else i.error=i.error||"URN can not be parsed.";return i},serialize:function e(t,n){var r=n.scheme||t.scheme||"urn",i=t.nid,o=r+":"+(n.nid||i),s=q[o];s&&(t=s.serialize(t,n));var a=t,l=t.nss;return a.path=(i||n.nid)+":"+l,a}},je=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/,Re={scheme:"urn:uuid",parse:function e(t,n){var r=t;return r.uuid=r.nss,r.nss=void 0,n.tolerant||r.uuid&&r.uuid.match(je)||(r.error=r.error||"UUID is not valid."),r},serialize:function e(t,n){var r=t;return r.nss=(t.uuid||"").toLowerCase(),r}};q[ce.scheme]=ce,q[he.scheme]=he,q[Ae.scheme]=Ae,q[Ie.scheme]=Ie,q[Re.scheme]=Re,e.SCHEMES=q,e.pctEncChar=z,e.pctDecChars=K,e.parse=Z,e.removeDotSegments=ne,e.serialize=re,e.resolveComponents=ie,e.resolve=oe,e.normalize=se,e.equal=ae,e.escapeComponent=le,e.unescapeComponent=ue,Object.defineProperty(e,"__esModule",{value:!0})},i(t)},function(e,t,n){"use strict";e.exports=function e(t){for(var n=0,r=t.length,i=0,o;i<r;)n++,o=t.charCodeAt(i++),o>=55296&&o<=56319&&i<r&&(o=t.charCodeAt(i),56320==(64512&o)&&i++);return n}},function(e,t,n){"use strict";var r=e.exports=function(e,t,n){"function"==typeof t&&(n=t,t={}),n=t.cb||n;var r="function"==typeof n?n:n.pre||function(){},o=n.post||function(){};i(t,r,o,e,"",e)};function i(e,t,n,s,a,l,u,c,h,f){if(s&&"object"==typeof s&&!Array.isArray(s)){for(var p in t(s,a,l,u,c,h,f),s){var d=s[p];if(Array.isArray(d)){if(p in r.arrayKeywords)for(var m=0;m<d.length;m++)i(e,t,n,d[m],a+"/"+p+"/"+m,l,a,p,s,m)}else if(p in r.propsKeywords){if(d&&"object"==typeof d)for(var g in d)i(e,t,n,d[g],a+"/"+p+"/"+o(g),l,a,p,s,g)}else(p in r.keywords||e.allKeys&&!(p in r.skipKeywords))&&i(e,t,n,d,a+"/"+p,l,a,p,s)}n(s,a,l,u,c,h,f)}}function o(e){return e.replace(/~/g,"~0").replace(/\//g,"~1")}r.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0},r.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},r.propsKeywords={definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},r.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0}},function(e,t,n){"use strict";var r=e.exports=function e(){this._cache={}};r.prototype.put=function e(t,n){this._cache[t]=n},r.prototype.get=function e(t){return this._cache[t]},r.prototype.del=function e(t){delete this._cache[t]},r.prototype.clear=function e(){this._cache={}}},function(e,t,n){"use strict";var r=n(143),i=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,o=[0,31,28,31,30,31,30,31,31,30,31,30,31],s=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d:\d\d)?$/i,a=/^[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*$/i,l=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,u=/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,c=/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,h=/^(?:(?:http[s\u017F]?|ftp):\/\/)(?:(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+(?::(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?@)?(?:(?!10(?:\.[0-9]{1,3}){3})(?!127(?:\.[0-9]{1,3}){3})(?!169\.254(?:\.[0-9]{1,3}){2})(?!192\.168(?:\.[0-9]{1,3}){2})(?!172\.(?:1[6-9]|2[0-9]|3[01])(?:\.[0-9]{1,3}){2})(?:[1-9][0-9]?|1[0-9][0-9]|2[01][0-9]|22[0-3])(?:\.(?:1?[0-9]{1,2}|2[0-4][0-9]|25[0-5])){2}(?:\.(?:[1-9][0-9]?|1[0-9][0-9]|2[0-4][0-9]|25[0-4]))|(?:(?:(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-?)*(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)(?:\.(?:(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+-?)*(?:[0-9KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])+)*(?:\.(?:(?:[KSa-z\xA1-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]){2,})))(?::[0-9]{2,5})?(?:\/(?:[\0-\x08\x0E-\x1F!-\x9F\xA1-\u167F\u1681-\u1FFF\u200B-\u2027\u202A-\u202E\u2030-\u205E\u2060-\u2FFF\u3001-\uD7FF\uE000-\uFEFE\uFF00-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF])*)?$/i,f=/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,p=/^(?:\/(?:[^~/]|~0|~1)*)*$/,d=/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,m=/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/;function g(e){return e="full"==e?"full":"fast",r.copy(g[e])}function y(e){return e%4==0&&(e%100!=0||e%400==0)}function v(e){var t=e.match(i);if(!t)return!1;var n=+t[1],r=+t[2],s=+t[3];return r>=1&&r<=12&&s>=1&&s<=(2==r&&y(n)?29:o[r])}function b(e,t){var n=e.match(s);if(!n)return!1;var r=n[1],i=n[2],o=n[3],a=n[5];return(r<=23&&i<=59&&o<=59||23==r&&59==i&&60==o)&&(!t||a)}e.exports=g,g.fast={date:/^\d\d\d\d-[0-1]\d-[0-3]\d$/,time:/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d:\d\d)?$/i,"date-time":/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d:\d\d)$/i,uri:/^(?:[a-z][a-z0-9+-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,"uri-template":c,url:h,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i,hostname:a,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:C,uuid:f,"json-pointer":p,"json-pointer-uri-fragment":d,"relative-json-pointer":m},g.full={date:v,time:b,"date-time":w,uri:S,"uri-reference":u,"uri-template":c,url:h,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:k,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^\s*(?:(?:(?:[0-9a-f]{1,4}:){7}(?:[0-9a-f]{1,4}|:))|(?:(?:[0-9a-f]{1,4}:){6}(?::[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){5}(?:(?:(?::[0-9a-f]{1,4}){1,2})|:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(?:(?:[0-9a-f]{1,4}:){4}(?:(?:(?::[0-9a-f]{1,4}){1,3})|(?:(?::[0-9a-f]{1,4})?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){3}(?:(?:(?::[0-9a-f]{1,4}){1,4})|(?:(?::[0-9a-f]{1,4}){0,2}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){2}(?:(?:(?::[0-9a-f]{1,4}){1,5})|(?:(?::[0-9a-f]{1,4}){0,3}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?:(?:[0-9a-f]{1,4}:){1}(?:(?:(?::[0-9a-f]{1,4}){1,6})|(?:(?::[0-9a-f]{1,4}){0,4}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(?::(?:(?:(?::[0-9a-f]{1,4}){1,7})|(?:(?::[0-9a-f]{1,4}){0,5}:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(?:\.(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(?:%.+)?\s*$/i,regex:C,uuid:f,"json-pointer":p,"json-pointer-uri-fragment":d,"relative-json-pointer":m};var _=/t|\s/i;function w(e){var t=e.split(_);return 2==t.length&&v(t[0])&&b(t[1],!0)}function k(e){return e.length<=255&&a.test(e)}var E=/\/|:/;function S(e){return E.test(e)&&l.test(e)}var x=/[^\\]\\Z/;function C(e){if(x.test(e))return!1;try{return new RegExp(e),!0}catch(e){return!1}}},function(e,t,n){"use strict";var r=n(1686),i=n(143).toHash;e.exports=function e(){var t=[{type:"number",rules:[{maximum:["exclusiveMaximum"]},{minimum:["exclusiveMinimum"]},"multipleOf","format"]},{type:"string",rules:["maxLength","minLength","pattern","format"]},{type:"array",rules:["maxItems","minItems","items","contains","uniqueItems"]},{type:"object",rules:["maxProperties","minProperties","required","dependencies","propertyNames",{properties:["additionalProperties","patternProperties"]}]},{rules:["$ref","const","enum","not","anyOf","oneOf","allOf","if"]}],n=["type","$comment"],o=["$schema","$id","id","$data","$async","title","description","default","definitions","examples","readOnly","writeOnly","contentMediaType","contentEncoding","additionalItems","then","else"],s=["number","integer","string","array","object","boolean","null"];return t.all=i(n),t.types=i(s),t.forEach(function(e){e.rules=e.rules.map(function(e){var i;if("object"==typeof e){var o=Object.keys(e)[0];i=e[o],e=o,i.forEach(function(e){n.push(e),t.all[e]=!0})}n.push(e);var s=t.all[e]={keyword:e,code:r[e],implements:i};return s}),t.all.$comment={keyword:"$comment",code:r.$comment},e.type&&(t.types[e.type]=e)}),t.keywords=i(n.concat(o)),t.custom={},t}},function(e,t,n){"use strict";e.exports={$ref:n(1687),allOf:n(1688),anyOf:n(1689),$comment:n(1690),const:n(1691),contains:n(1692),dependencies:n(1693),enum:n(1694),format:n(1695),if:n(1696),items:n(1697),maximum:n(627),minimum:n(627),maxItems:n(628),minItems:n(628),maxLength:n(629),minLength:n(629),maxProperties:n(630),minProperties:n(630),multipleOf:n(1698),not:n(1699),oneOf:n(1700),pattern:n(1701),properties:n(1702),propertyNames:n(1703),required:n(1704),uniqueItems:n(1705),validate:n(626)}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.errSchemaPath+"/"+n,u=!t.opts.allErrors,c="data"+(s||""),h="valid"+o,f,p;if("#"==a||"#/"==a)t.isRoot?(f=t.async,p="validate"):(f=!0===t.root.schema.$async,p="root.refVal[0]");else{var d=t.resolveRef(t.baseId,a,t.isRoot);if(void 0===d){var m=t.MissingRefError.message(t.baseId,a);if("fail"==t.opts.missingRefs){t.logger.error(m);var g=g||[];g.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '$ref' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(l)+" , params: { ref: '"+t.util.escapeQuotes(a)+"' } ",!1!==t.opts.messages&&(i+=" , message: 'can\\'t resolve reference "+t.util.escapeQuotes(a)+"' "),t.opts.verbose&&(i+=" , schema: "+t.util.toQuotedString(a)+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+c+" "),i+=" } "):i+=" {} ";var y=i;i=g.pop(),!t.compositeRule&&u?t.async?i+=" throw new ValidationError(["+y+"]); ":i+=" validate.errors = ["+y+"]; return false; ":i+=" var err = "+y+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u&&(i+=" if (false) { ")}else{if("ignore"!=t.opts.missingRefs)throw new t.MissingRefError(t.baseId,a,m);t.logger.warn(m),u&&(i+=" if (true) { ")}}else if(d.inline){var v=t.util.copy(t);v.level++;var b="valid"+v.level;v.schema=d.schema,v.schemaPath="",v.errSchemaPath=a;var _=t.validate(v).replace(/validate\.schema/g,d.code);i+=" "+_+" ",u&&(i+=" if ("+b+") { ")}else f=!0===d.$async||t.async&&!1!==d.$async,p=d.code}if(p){var g=g||[];g.push(i),i="",t.opts.passContext?i+=" "+p+".call(this, ":i+=" "+p+"( ",i+=" "+c+", (dataPath || '')",'""'!=t.errorPath&&(i+=" + "+t.errorPath);var w=s?"data"+(s-1||""):"parentData",k=s?t.dataPathArr[s]:"parentDataProperty";i+=" , "+w+" , "+k+", rootData) ";var E=i;if(i=g.pop(),f){if(!t.async)throw new Error("async schema referenced by sync schema");u&&(i+=" var "+h+"; "),i+=" try { await "+E+"; ",u&&(i+=" "+h+" = true; "),i+=" } catch (e) { if (!(e instanceof ValidationError)) throw e; if (vErrors === null) vErrors = e.errors; else vErrors = vErrors.concat(e.errors); errors = vErrors.length; ",u&&(i+=" "+h+" = false; "),i+=" } ",u&&(i+=" if ("+h+") { ")}else i+=" if (!"+E+") { if (vErrors === null) vErrors = "+p+".errors; else vErrors = vErrors.concat("+p+".errors); errors = vErrors.length; } ",u&&(i+=" else { ")}return i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.schema[n],s=t.schemaPath+t.util.getProperty(n),a=t.errSchemaPath+"/"+n,l=!t.opts.allErrors,u=t.util.copy(t),c="";u.level++;var h="valid"+u.level,f=u.baseId,p=!0,d=o;if(d)for(var m,g=-1,y=d.length-1;g<y;)m=d[g+=1],t.util.schemaHasRules(m,t.RULES.all)&&(p=!1,u.schema=m,u.schemaPath=s+"["+g+"]",u.errSchemaPath=a+"/"+g,i+=" "+t.validate(u)+" ",u.baseId=f,l&&(i+=" if ("+h+") { ",c+="}"));return l&&(i+=p?" if (true) { ":" "+c.slice(0,-1)+" "),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p="errs__"+o,d=t.util.copy(t),m="";d.level++;var g="valid"+d.level,y=a.every(function(e){return t.util.schemaHasRules(e,t.RULES.all)});if(y){var v=d.baseId;i+=" var "+p+" = errors; var "+f+" = false; ";var b=t.compositeRule;t.compositeRule=d.compositeRule=!0;var _=a;if(_)for(var w,k=-1,E=_.length-1;k<E;)w=_[k+=1],d.schema=w,d.schemaPath=l+"["+k+"]",d.errSchemaPath=u+"/"+k,i+=" "+t.validate(d)+" ",d.baseId=v,i+=" "+f+" = "+f+" || "+g+"; if (!"+f+") { ",m+="}";t.compositeRule=d.compositeRule=b,i+=" "+m+" if (!"+f+") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'anyOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: 'should match some schema in anyOf' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?i+=" throw new ValidationError(vErrors); ":i+=" validate.errors = vErrors; return false; "),i+=" } else { errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } ",t.opts.allErrors&&(i+=" } "),i=t.util.cleanUpCode(i)}else c&&(i+=" if (true) { ");return i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.schema[n],s=t.errSchemaPath+"/"+n,a=!t.opts.allErrors,l=t.util.toQuotedString(o);return!0===t.opts.$comment?i+=" console.log("+l+");":"function"==typeof t.opts.$comment&&(i+=" self._opts.$comment("+l+", "+t.util.toQuotedString(s)+", validate.root.schema);"),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a,p||(i+=" var schema"+o+" = validate.schema"+l+";"),i+="var "+f+" = equal("+h+", schema"+o+"); if (!"+f+") { ";var m=m||[];m.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'const' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { allowedValue: schema"+o+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be equal to constant' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var g=i;return i=m.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+g+"]); ":i+=" validate.errors = ["+g+"]; return false; ":i+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" }",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p="errs__"+o,d=t.util.copy(t),m="";d.level++;var g="valid"+d.level,y="i"+o,v=d.dataLevel=t.dataLevel+1,b="data"+v,_=t.baseId,w=t.util.schemaHasRules(a,t.RULES.all);if(i+="var "+p+" = errors;var "+f+";",w){var k=t.compositeRule;t.compositeRule=d.compositeRule=!0,d.schema=a,d.schemaPath=l,d.errSchemaPath=u,i+=" var "+g+" = false; for (var "+y+" = 0; "+y+" < "+h+".length; "+y+"++) { ",d.errorPath=t.util.getPathExpr(t.errorPath,y,t.opts.jsonPointers,!0);var E=h+"["+y+"]";d.dataPathArr[v]=y;var S=t.validate(d);d.baseId=_,t.util.varOccurences(S,b)<2?i+=" "+t.util.varReplace(S,b,E)+" ":i+=" var "+b+" = "+E+"; "+S+" ",i+=" if ("+g+") break; } ",t.compositeRule=d.compositeRule=k,i+=" if (!"+g+") {"}else i+=" if ("+h+".length == 0) {";var x=x||[];x.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'contains' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: 'should contain a valid item' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var C=i;return i=x.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+C+"]); ":i+=" validate.errors = ["+C+"]; return false; ":i+=" var err = "+C+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else { ",w&&(i+=" errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } "),t.opts.allErrors&&(i+=" } "),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="errs__"+o,p=t.util.copy(t),d="";p.level++;var m="valid"+p.level,g={},y={},v=t.opts.ownProperties;for(k in a){var b=a[k],_=Array.isArray(b)?y:g;_[k]=b}i+="var "+f+" = errors;";var w=t.errorPath;for(var k in i+="var missing"+o+";",y)if(_=y[k],_.length){if(i+=" if ( "+h+t.util.getProperty(k)+" !== undefined ",v&&(i+=" && Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(k)+"') "),c){i+=" && ( ";var E=_;if(E)for(var S,x=-1,C=E.length-1;x<C;){S=E[x+=1],x&&(i+=" || ");var A=t.util.getProperty(S),T=h+A;i+=" ( ( "+T+" === undefined ",v&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(S)+"') "),i+=") && (missing"+o+" = "+t.util.toQuotedString(t.opts.jsonPointers?S:A)+") ) "}i+=")) { ";var I="missing"+o,j="' + "+I+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.opts.jsonPointers?t.util.getPathExpr(w,I,!0):w+" + "+I);var R=R||[];R.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { property: '"+t.util.escapeQuotes(k)+"', missingProperty: '"+j+"', depsCount: "+_.length+", deps: '"+t.util.escapeQuotes(1==_.length?_[0]:_.join(", "))+"' } ",!1!==t.opts.messages&&(i+=" , message: 'should have ",1==_.length?i+="property "+t.util.escapeQuotes(_[0]):i+="properties "+t.util.escapeQuotes(_.join(", ")),i+=" when property "+t.util.escapeQuotes(k)+" is present' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var B=i;i=R.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+B+"]); ":i+=" validate.errors = ["+B+"]; return false; ":i+=" var err = "+B+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; "}else{i+=" ) { ";var O=_;if(O)for(var S,P=-1,N=O.length-1;P<N;){S=O[P+=1];var A=t.util.getProperty(S),j=t.util.escapeQuotes(S),T=h+A;t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath(w,S,t.opts.jsonPointers)),i+=" if ( "+T+" === undefined ",v&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(S)+"') "),i+=") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'dependencies' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { property: '"+t.util.escapeQuotes(k)+"', missingProperty: '"+j+"', depsCount: "+_.length+", deps: '"+t.util.escapeQuotes(1==_.length?_[0]:_.join(", "))+"' } ",!1!==t.opts.messages&&(i+=" , message: 'should have ",1==_.length?i+="property "+t.util.escapeQuotes(_[0]):i+="properties "+t.util.escapeQuotes(_.join(", ")),i+=" when property "+t.util.escapeQuotes(k)+" is present' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}i+=" } ",c&&(d+="}",i+=" else { ")}t.errorPath=w;var D=p.baseId;for(var k in g){var b=g[k];t.util.schemaHasRules(b,t.RULES.all)&&(i+=" "+m+" = true; if ( "+h+t.util.getProperty(k)+" !== undefined ",v&&(i+=" && Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(k)+"') "),i+=") { ",p.schema=b,p.schemaPath=l+t.util.getProperty(k),p.errSchemaPath=u+"/"+t.util.escapeFragment(k),i+=" "+t.validate(p)+" ",p.baseId=D,i+=" } ",c&&(i+=" if ("+m+") { ",d+="}"))}return c&&(i+=" "+d+" if ("+f+" == errors) {"),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="i"+o,g="schema"+o;p||(i+=" var "+g+" = validate.schema"+l+";"),i+="var "+f+";",p&&(i+=" if (schema"+o+" === undefined) "+f+" = true; else if (!Array.isArray(schema"+o+")) "+f+" = false; else {"),i+=f+" = false;for (var "+m+"=0; "+m+"<"+g+".length; "+m+"++) if (equal("+h+", "+g+"["+m+"])) { "+f+" = true; break; }",p&&(i+=" } "),i+=" if (!"+f+") { ";var y=y||[];y.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'enum' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { allowedValues: schema"+o+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be equal to one of the allowed values' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var v=i;return i=y.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+v+"]); ":i+=" validate.errors = ["+v+"]; return false; ":i+=" var err = "+v+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" }",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||"");if(!1===t.opts.format)return c&&(i+=" if (true) { "),i;var f=t.opts.$data&&a&&a.$data,p;f?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",p="schema"+o):p=a;var d=t.opts.unknownFormats,m=Array.isArray(d);if(f){var g="format"+o,y="isObject"+o,v="formatType"+o;i+=" var "+g+" = formats["+p+"]; var "+y+" = typeof "+g+" == 'object' && !("+g+" instanceof RegExp) && "+g+".validate; var "+v+" = "+y+" && "+g+".type || 'string'; if ("+y+") { ",t.async&&(i+=" var async"+o+" = "+g+".async; "),i+=" "+g+" = "+g+".validate; } if ( ",f&&(i+=" ("+p+" !== undefined && typeof "+p+" != 'string') || "),i+=" (","ignore"!=d&&(i+=" ("+p+" && !"+g+" ",m&&(i+=" && self._opts.unknownFormats.indexOf("+p+") == -1 "),i+=") || "),i+=" ("+g+" && "+v+" == '"+r+"' && !(typeof "+g+" == 'function' ? ",t.async?i+=" (async"+o+" ? await "+g+"("+h+") : "+g+"("+h+")) ":i+=" "+g+"("+h+") ",i+=" : "+g+".test("+h+"))))) {"}else{var g=t.formats[a];if(!g){if("ignore"==d)return t.logger.warn('unknown format "'+a+'" ignored in schema at path "'+t.errSchemaPath+'"'),c&&(i+=" if (true) { "),i;if(m&&d.indexOf(a)>=0)return c&&(i+=" if (true) { "),i;throw new Error('unknown format "'+a+'" is used in schema at path "'+t.errSchemaPath+'"')}var y="object"==typeof g&&!(g instanceof RegExp)&&g.validate,v=y&&g.type||"string";if(y){var b=!0===g.async;g=g.validate}if(v!=r)return c&&(i+=" if (true) { "),i;if(b){if(!t.async)throw new Error("async format in sync schema");var _="formats"+t.util.getProperty(a)+".validate";i+=" if (!(await "+_+"("+h+"))) { "}else{i+=" if (! ";var _="formats"+t.util.getProperty(a);y&&(_+=".validate"),i+="function"==typeof g?" "+_+"("+h+") ":" "+_+".test("+h+") ",i+=") { "}}var w=w||[];w.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'format' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { format: ",i+=f?""+p:""+t.util.toQuotedString(a),i+=" } ",!1!==t.opts.messages&&(i+=" , message: 'should match format \"",i+=f?"' + "+p+" + '":""+t.util.escapeQuotes(a),i+="\"' "),t.opts.verbose&&(i+=" , schema: ",i+=f?"validate.schema"+l:""+t.util.toQuotedString(a),i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var k=i;return i=w.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+k+"]); ":i+=" validate.errors = ["+k+"]; return false; ":i+=" var err = "+k+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p="errs__"+o,d=t.util.copy(t);d.level++;var m="valid"+d.level,g=t.schema.then,y=t.schema.else,v=void 0!==g&&t.util.schemaHasRules(g,t.RULES.all),b=void 0!==y&&t.util.schemaHasRules(y,t.RULES.all),_=d.baseId;if(v||b){var w;d.createErrors=!1,d.schema=a,d.schemaPath=l,d.errSchemaPath=u,i+=" var "+p+" = errors; var "+f+" = true; ";var k=t.compositeRule;t.compositeRule=d.compositeRule=!0,i+=" "+t.validate(d)+" ",d.baseId=_,d.createErrors=!0,i+=" errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; } ",t.compositeRule=d.compositeRule=k,v?(i+=" if ("+m+") { ",d.schema=t.schema.then,d.schemaPath=t.schemaPath+".then",d.errSchemaPath=t.errSchemaPath+"/then",i+=" "+t.validate(d)+" ",d.baseId=_,i+=" "+f+" = "+m+"; ",v&&b?(w="ifClause"+o,i+=" var "+w+" = 'then'; "):w="'then'",i+=" } ",b&&(i+=" else { ")):i+=" if (!"+m+") { ",b&&(d.schema=t.schema.else,d.schemaPath=t.schemaPath+".else",d.errSchemaPath=t.errSchemaPath+"/else",i+=" "+t.validate(d)+" ",d.baseId=_,i+=" "+f+" = "+m+"; ",v&&b?(w="ifClause"+o,i+=" var "+w+" = 'else'; "):w="'else'",i+=" } "),i+=" if (!"+f+") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'if' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { failingKeyword: "+w+" } ",!1!==t.opts.messages&&(i+=" , message: 'should match \"' + "+w+" + '\" schema' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?i+=" throw new ValidationError(vErrors); ":i+=" validate.errors = vErrors; return false; "),i+=" } ",c&&(i+=" else { "),i=t.util.cleanUpCode(i)}else c&&(i+=" if (true) { ");return i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p="errs__"+o,d=t.util.copy(t),m="";d.level++;var g="valid"+d.level,y="i"+o,v=d.dataLevel=t.dataLevel+1,b="data"+v,_=t.baseId;if(i+="var "+p+" = errors;var "+f+";",Array.isArray(a)){var w=t.schema.additionalItems;if(!1===w){i+=" "+f+" = "+h+".length <= "+a.length+"; ";var k=u;u=t.errSchemaPath+"/additionalItems",i+=" if (!"+f+") { ";var E=E||[];E.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'additionalItems' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { limit: "+a.length+" } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have more than "+a.length+" items' "),t.opts.verbose&&(i+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var S=i;i=E.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+S+"]); ":i+=" validate.errors = ["+S+"]; return false; ":i+=" var err = "+S+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",u=k,c&&(m+="}",i+=" else { ")}var x=a;if(x)for(var C,A=-1,T=x.length-1;A<T;)if(C=x[A+=1],t.util.schemaHasRules(C,t.RULES.all)){i+=" "+g+" = true; if ("+h+".length > "+A+") { ";var I=h+"["+A+"]";d.schema=C,d.schemaPath=l+"["+A+"]",d.errSchemaPath=u+"/"+A,d.errorPath=t.util.getPathExpr(t.errorPath,A,t.opts.jsonPointers,!0),d.dataPathArr[v]=A;var j=t.validate(d);d.baseId=_,t.util.varOccurences(j,b)<2?i+=" "+t.util.varReplace(j,b,I)+" ":i+=" var "+b+" = "+I+"; "+j+" ",i+=" } ",c&&(i+=" if ("+g+") { ",m+="}")}if("object"==typeof w&&t.util.schemaHasRules(w,t.RULES.all)){d.schema=w,d.schemaPath=t.schemaPath+".additionalItems",d.errSchemaPath=t.errSchemaPath+"/additionalItems",i+=" "+g+" = true; if ("+h+".length > "+a.length+") { for (var "+y+" = "+a.length+"; "+y+" < "+h+".length; "+y+"++) { ",d.errorPath=t.util.getPathExpr(t.errorPath,y,t.opts.jsonPointers,!0);var I=h+"["+y+"]";d.dataPathArr[v]=y;var j=t.validate(d);d.baseId=_,t.util.varOccurences(j,b)<2?i+=" "+t.util.varReplace(j,b,I)+" ":i+=" var "+b+" = "+I+"; "+j+" ",c&&(i+=" if (!"+g+") break; "),i+=" } } ",c&&(i+=" if ("+g+") { ",m+="}")}}else if(t.util.schemaHasRules(a,t.RULES.all)){d.schema=a,d.schemaPath=l,d.errSchemaPath=u,i+=" for (var "+y+" = 0; "+y+" < "+h+".length; "+y+"++) { ",d.errorPath=t.util.getPathExpr(t.errorPath,y,t.opts.jsonPointers,!0);var I=h+"["+y+"]";d.dataPathArr[v]=y;var j=t.validate(d);d.baseId=_,t.util.varOccurences(j,b)<2?i+=" "+t.util.varReplace(j,b,I)+" ":i+=" var "+b+" = "+I+"; "+j+" ",c&&(i+=" if (!"+g+") break; "),i+=" }"}return c&&(i+=" "+m+" if ("+p+" == errors) {"),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f=t.opts.$data&&a&&a.$data,p;f?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",p="schema"+o):p=a,i+="var division"+o+";if (",f&&(i+=" "+p+" !== undefined && ( typeof "+p+" != 'number' || "),i+=" (division"+o+" = "+h+" / "+p+", ",t.opts.multipleOfPrecision?i+=" Math.abs(Math.round(division"+o+") - division"+o+") > 1e-"+t.opts.multipleOfPrecision+" ":i+=" division"+o+" !== parseInt(division"+o+") ",i+=" ) ",f&&(i+=" ) "),i+=" ) { ";var d=d||[];d.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'multipleOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { multipleOf: "+p+" } ",!1!==t.opts.messages&&(i+=" , message: 'should be multiple of ",i+=f?"' + "+p:p+"'"),t.opts.verbose&&(i+=" , schema: ",i+=f?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var m=i;return i=d.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+m+"]); ":i+=" validate.errors = ["+m+"]; return false; ":i+=" var err = "+m+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="errs__"+o,p=t.util.copy(t);p.level++;var d="valid"+p.level;if(t.util.schemaHasRules(a,t.RULES.all)){p.schema=a,p.schemaPath=l,p.errSchemaPath=u,i+=" var "+f+" = errors; ";var m=t.compositeRule,g;t.compositeRule=p.compositeRule=!0,p.createErrors=!1,p.opts.allErrors&&(g=p.opts.allErrors,p.opts.allErrors=!1),i+=" "+t.validate(p)+" ",p.createErrors=!0,g&&(p.opts.allErrors=g),t.compositeRule=p.compositeRule=m,i+=" if ("+d+") { ";var y=y||[];y.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'not' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: 'should NOT be valid' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var v=i;i=y.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+v+"]); ":i+=" validate.errors = ["+v+"]; return false; ":i+=" var err = "+v+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else { errors = "+f+"; if (vErrors !== null) { if ("+f+") vErrors.length = "+f+"; else vErrors = null; } ",t.opts.allErrors&&(i+=" } ")}else i+=" var err = ",!1!==t.createErrors?(i+=" { keyword: 'not' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: {} ",!1!==t.opts.messages&&(i+=" , message: 'should NOT be valid' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",c&&(i+=" if (false) { ");return i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p="errs__"+o,d=t.util.copy(t),m="";d.level++;var g="valid"+d.level,y=d.baseId,v="prevValid"+o,b="passingSchemas"+o;i+="var "+p+" = errors , "+v+" = false , "+f+" = false , "+b+" = null; ";var _=t.compositeRule;t.compositeRule=d.compositeRule=!0;var w=a;if(w)for(var k,E=-1,S=w.length-1;E<S;)k=w[E+=1],t.util.schemaHasRules(k,t.RULES.all)?(d.schema=k,d.schemaPath=l+"["+E+"]",d.errSchemaPath=u+"/"+E,i+=" "+t.validate(d)+" ",d.baseId=y):i+=" var "+g+" = true; ",E&&(i+=" if ("+g+" && "+v+") { "+f+" = false; "+b+" = ["+b+", "+E+"]; } else { ",m+="}"),i+=" if ("+g+") { "+f+" = "+v+" = true; "+b+" = "+E+"; }";return t.compositeRule=d.compositeRule=_,i+=m+"if (!"+f+") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'oneOf' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { passingSchemas: "+b+" } ",!1!==t.opts.messages&&(i+=" , message: 'should match exactly one schema in oneOf' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?i+=" throw new ValidationError(vErrors); ":i+=" validate.errors = vErrors; return false; "),i+="} else { errors = "+p+"; if (vErrors !== null) { if ("+p+") vErrors.length = "+p+"; else vErrors = null; }",t.opts.allErrors&&(i+=" } "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f=t.opts.$data&&a&&a.$data,p;f?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",p="schema"+o):p=a;var d=f?"(new RegExp("+p+"))":t.usePattern(a);i+="if ( ",f&&(i+=" ("+p+" !== undefined && typeof "+p+" != 'string') || "),i+=" !"+d+".test("+h+") ) { ";var m=m||[];m.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'pattern' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { pattern: ",i+=f?""+p:""+t.util.toQuotedString(a),i+=" } ",!1!==t.opts.messages&&(i+=" , message: 'should match pattern \"",i+=f?"' + "+p+" + '":""+t.util.escapeQuotes(a),i+="\"' "),t.opts.verbose&&(i+=" , schema: ",i+=f?"validate.schema"+l:""+t.util.toQuotedString(a),i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var g=i;return i=m.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+g+"]); ":i+=" validate.errors = ["+g+"]; return false; ":i+=" var err = "+g+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+="} ",c&&(i+=" else { "),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="errs__"+o,p=t.util.copy(t),d="";p.level++;var m="valid"+p.level,g="key"+o,y="idx"+o,v=p.dataLevel=t.dataLevel+1,b="data"+v,_="dataProperties"+o,w=Object.keys(a||{}),k=t.schema.patternProperties||{},E=Object.keys(k),S=t.schema.additionalProperties,x=w.length||E.length,C=!1===S,A="object"==typeof S&&Object.keys(S).length,T=t.opts.removeAdditional,I=C||A||T,j=t.opts.ownProperties,R=t.baseId,B=t.schema.required;if(B&&(!t.opts.$data||!B.$data)&&B.length<t.opts.loopRequired)var O=t.util.toHash(B);if(i+="var "+f+" = errors;var "+m+" = true;",j&&(i+=" var "+_+" = undefined;"),I){if(i+=j?" "+_+" = "+_+" || Object.keys("+h+"); for (var "+y+"=0; "+y+"<"+_+".length; "+y+"++) { var "+g+" = "+_+"["+y+"]; ":" for (var "+g+" in "+h+") { ",x){if(i+=" var isAdditional"+o+" = !(false ",w.length)if(w.length>8)i+=" || validate.schema"+l+".hasOwnProperty("+g+") ";else{var P=w;if(P)for(var N,D=-1,M=P.length-1;D<M;)N=P[D+=1],i+=" || "+g+" == "+t.util.toQuotedString(N)+" "}if(E.length){var F=E;if(F)for(var L,U=-1,q=F.length-1;U<q;)L=F[U+=1],i+=" || "+t.usePattern(L)+".test("+g+") "}i+=" ); if (isAdditional"+o+") { "}if("all"==T)i+=" delete "+h+"["+g+"]; ";else{var z=t.errorPath,K="' + "+g+" + '";if(t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers)),C)if(T)i+=" delete "+h+"["+g+"]; ";else{i+=" "+m+" = false; ";var H=u;u=t.errSchemaPath+"/additionalProperties";var V=V||[];V.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'additionalProperties' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { additionalProperty: '"+K+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is an invalid additional property":i+="should NOT have additional properties",i+="' "),t.opts.verbose&&(i+=" , schema: false , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var $=i;i=V.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+$+"]); ":i+=" validate.errors = ["+$+"]; return false; ":i+=" var err = "+$+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u=H,c&&(i+=" break; ")}else if(A)if("failing"==T){i+=" var "+f+" = errors; ";var W=t.compositeRule;t.compositeRule=p.compositeRule=!0,p.schema=S,p.schemaPath=t.schemaPath+".additionalProperties",p.errSchemaPath=t.errSchemaPath+"/additionalProperties",p.errorPath=t.opts._errorDataPathProperty?t.errorPath:t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers);var G=h+"["+g+"]";p.dataPathArr[v]=g;var Y=t.validate(p);p.baseId=R,t.util.varOccurences(Y,b)<2?i+=" "+t.util.varReplace(Y,b,G)+" ":i+=" var "+b+" = "+G+"; "+Y+" ",i+=" if (!"+m+") { errors = "+f+"; if (validate.errors !== null) { if (errors) validate.errors.length = errors; else validate.errors = null; } delete "+h+"["+g+"]; } ",t.compositeRule=p.compositeRule=W}else{p.schema=S,p.schemaPath=t.schemaPath+".additionalProperties",p.errSchemaPath=t.errSchemaPath+"/additionalProperties",p.errorPath=t.opts._errorDataPathProperty?t.errorPath:t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers);var G=h+"["+g+"]";p.dataPathArr[v]=g;var Y=t.validate(p);p.baseId=R,t.util.varOccurences(Y,b)<2?i+=" "+t.util.varReplace(Y,b,G)+" ":i+=" var "+b+" = "+G+"; "+Y+" ",c&&(i+=" if (!"+m+") break; ")}t.errorPath=z}x&&(i+=" } "),i+=" } ",c&&(i+=" if ("+m+") { ",d+="}")}var Z=t.opts.useDefaults&&!t.compositeRule;if(w.length){var J=w;if(J)for(var N,Q=-1,X=J.length-1;Q<X;){N=J[Q+=1];var ee=a[N];if(t.util.schemaHasRules(ee,t.RULES.all)){var te=t.util.getProperty(N),G=h+te,ne=Z&&void 0!==ee.default;p.schema=ee,p.schemaPath=l+te,p.errSchemaPath=u+"/"+t.util.escapeFragment(N),p.errorPath=t.util.getPath(t.errorPath,N,t.opts.jsonPointers),p.dataPathArr[v]=t.util.toQuotedString(N);var Y=t.validate(p);if(p.baseId=R,t.util.varOccurences(Y,b)<2){Y=t.util.varReplace(Y,b,G);var re=G}else{var re=b;i+=" var "+b+" = "+G+"; "}if(ne)i+=" "+Y+" ";else{if(O&&O[N]){i+=" if ( "+re+" === undefined ",j&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(N)+"') "),i+=") { "+m+" = false; ";var z=t.errorPath,H=u,ie=t.util.escapeQuotes(N);t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath(z,N,t.opts.jsonPointers)),u=t.errSchemaPath+"/required";var V=V||[];V.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+ie+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+ie+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var $=i;i=V.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+$+"]); ":i+=" validate.errors = ["+$+"]; return false; ":i+=" var err = "+$+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",u=H,t.errorPath=z,i+=" } else { "}else c?(i+=" if ( "+re+" === undefined ",j&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(N)+"') "),i+=") { "+m+" = true; } else { "):(i+=" if ("+re+" !== undefined ",j&&(i+=" && Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(N)+"') "),i+=" ) { ");i+=" "+Y+" } "}}c&&(i+=" if ("+m+") { ",d+="}")}}if(E.length){var oe=E;if(oe)for(var L,se=-1,ae=oe.length-1;se<ae;){L=oe[se+=1];var ee=k[L];if(t.util.schemaHasRules(ee,t.RULES.all)){p.schema=ee,p.schemaPath=t.schemaPath+".patternProperties"+t.util.getProperty(L),p.errSchemaPath=t.errSchemaPath+"/patternProperties/"+t.util.escapeFragment(L),i+=j?" "+_+" = "+_+" || Object.keys("+h+"); for (var "+y+"=0; "+y+"<"+_+".length; "+y+"++) { var "+g+" = "+_+"["+y+"]; ":" for (var "+g+" in "+h+") { ",i+=" if ("+t.usePattern(L)+".test("+g+")) { ",p.errorPath=t.util.getPathExpr(t.errorPath,g,t.opts.jsonPointers);var G=h+"["+g+"]";p.dataPathArr[v]=g;var Y=t.validate(p);p.baseId=R,t.util.varOccurences(Y,b)<2?i+=" "+t.util.varReplace(Y,b,G)+" ":i+=" var "+b+" = "+G+"; "+Y+" ",c&&(i+=" if (!"+m+") break; "),i+=" } ",c&&(i+=" else "+m+" = true; "),i+=" } ",c&&(i+=" if ("+m+") { ",d+="}")}}}return c&&(i+=" "+d+" if ("+f+" == errors) {"),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="errs__"+o,p=t.util.copy(t),d="";p.level++;var m="valid"+p.level;if(i+="var "+f+" = errors;",t.util.schemaHasRules(a,t.RULES.all)){p.schema=a,p.schemaPath=l,p.errSchemaPath=u;var g="key"+o,y="idx"+o,v="i"+o,b="' + "+g+" + '",_=p.dataLevel=t.dataLevel+1,w="data"+_,k="dataProperties"+o,E=t.opts.ownProperties,S=t.baseId;E&&(i+=" var "+k+" = undefined; "),i+=E?" "+k+" = "+k+" || Object.keys("+h+"); for (var "+y+"=0; "+y+"<"+k+".length; "+y+"++) { var "+g+" = "+k+"["+y+"]; ":" for (var "+g+" in "+h+") { ",i+=" var startErrs"+o+" = errors; ";var x=g,C=t.compositeRule;t.compositeRule=p.compositeRule=!0;var A=t.validate(p);p.baseId=S,t.util.varOccurences(A,w)<2?i+=" "+t.util.varReplace(A,w,x)+" ":i+=" var "+w+" = "+x+"; "+A+" ",t.compositeRule=p.compositeRule=C,i+=" if (!"+m+") { for (var "+v+"=startErrs"+o+"; "+v+"<errors; "+v+"++) { vErrors["+v+"].propertyName = "+g+"; } var err = ",!1!==t.createErrors?(i+=" { keyword: 'propertyNames' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { propertyName: '"+b+"' } ",!1!==t.opts.messages&&(i+=" , message: 'property name \\'"+b+"\\' is invalid' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?i+=" throw new ValidationError(vErrors); ":i+=" validate.errors = vErrors; return false; "),c&&(i+=" break; "),i+=" } }"}return c&&(i+=" if ("+f+" == errors) {"),i=t.util.cleanUpCode(i),i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p=t.opts.$data&&a&&a.$data,d;p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a;var m="schema"+o;if(!p)if(a.length<t.opts.loopRequired&&t.schema.properties&&Object.keys(t.schema.properties).length){var g=[],y=a;if(y)for(var v,b=-1,_=y.length-1;b<_;){v=y[b+=1];var w=t.schema.properties[v];w&&t.util.schemaHasRules(w,t.RULES.all)||(g[g.length]=v)}}else var g=a;if(p||g.length){var k=t.errorPath,E=p||g.length>=t.opts.loopRequired,S=t.opts.ownProperties;if(c)if(i+=" var missing"+o+"; ",E){p||(i+=" var "+m+" = validate.schema"+l+"; ");var x="i"+o,C="schema"+o+"["+x+"]",A="' + "+C+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(k,C,t.opts.jsonPointers)),i+=" var "+f+" = true; ",p&&(i+=" if (schema"+o+" === undefined) "+f+" = true; else if (!Array.isArray(schema"+o+")) "+f+" = false; else {"),i+=" for (var "+x+" = 0; "+x+" < "+m+".length; "+x+"++) { "+f+" = "+h+"["+m+"["+x+"]] !== undefined ",S&&(i+=" && Object.prototype.hasOwnProperty.call("+h+", "+m+"["+x+"]) "),i+="; if (!"+f+") break; } ",p&&(i+=" } "),i+=" if (!"+f+") { ";var T=T||[];T.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+A+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+A+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var I=i;i=T.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+I+"]); ":i+=" validate.errors = ["+I+"]; return false; ":i+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else { "}else{i+=" if ( ";var j=g;if(j)for(var R,x=-1,B=j.length-1;x<B;){R=j[x+=1],x&&(i+=" || ");var O=t.util.getProperty(R),P=h+O;i+=" ( ( "+P+" === undefined ",S&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(R)+"') "),i+=") && (missing"+o+" = "+t.util.toQuotedString(t.opts.jsonPointers?R:O)+") ) "}i+=") { ";var C="missing"+o,A="' + "+C+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.opts.jsonPointers?t.util.getPathExpr(k,C,!0):k+" + "+C);var T=T||[];T.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+A+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+A+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var I=i;i=T.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+I+"]); ":i+=" validate.errors = ["+I+"]; return false; ":i+=" var err = "+I+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } else { "}else if(E){p||(i+=" var "+m+" = validate.schema"+l+"; ");var x="i"+o,C="schema"+o+"["+x+"]",A="' + "+C+" + '";t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPathExpr(k,C,t.opts.jsonPointers)),p&&(i+=" if ("+m+" && !Array.isArray("+m+")) { var err = ",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+A+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+A+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } else if ("+m+" !== undefined) { "),i+=" for (var "+x+" = 0; "+x+" < "+m+".length; "+x+"++) { if ("+h+"["+m+"["+x+"]] === undefined ",S&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", "+m+"["+x+"]) "),i+=") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+A+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+A+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } } ",p&&(i+=" } ")}else{var N=g;if(N)for(var R,D=-1,M=N.length-1;D<M;){R=N[D+=1];var O=t.util.getProperty(R),A=t.util.escapeQuotes(R),P=h+O;t.opts._errorDataPathProperty&&(t.errorPath=t.util.getPath(k,R,t.opts.jsonPointers)),i+=" if ( "+P+" === undefined ",S&&(i+=" || ! Object.prototype.hasOwnProperty.call("+h+", '"+t.util.escapeQuotes(R)+"') "),i+=") { var err = ",!1!==t.createErrors?(i+=" { keyword: 'required' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { missingProperty: '"+A+"' } ",!1!==t.opts.messages&&(i+=" , message: '",t.opts._errorDataPathProperty?i+="is a required property":i+="should have required property \\'"+A+"\\'",i+="' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; } "}}t.errorPath=k}else c&&(i+=" if (true) {");return i}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h="data"+(s||""),f="valid"+o,p=t.opts.$data&&a&&a.$data,d;if(p?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",d="schema"+o):d=a,(a||p)&&!1!==t.opts.uniqueItems){p&&(i+=" var "+f+"; if ("+d+" === false || "+d+" === undefined) "+f+" = true; else if (typeof "+d+" != 'boolean') "+f+" = false; else { "),i+=" var i = "+h+".length , "+f+" = true , j; if (i > 1) { ";var m=t.schema.items&&t.schema.items.type,g=Array.isArray(m);if(!m||"object"==m||"array"==m||g&&(m.indexOf("object")>=0||m.indexOf("array")>=0))i+=" outer: for (;i--;) { for (j = i; j--;) { if (equal("+h+"[i], "+h+"[j])) { "+f+" = false; break outer; } } } ";else{i+=" var itemIndices = {}, item; for (;i--;) { var item = "+h+"[i]; ";var y="checkDataType"+(g?"s":"");i+=" if ("+t.util[y](m,"item",!0)+") continue; ",g&&(i+=" if (typeof item == 'string') item = '\"' + item; "),i+=" if (typeof itemIndices[item] == 'number') { "+f+" = false; j = itemIndices[item]; break; } itemIndices[item] = i; } "}i+=" } ",p&&(i+=" } "),i+=" if (!"+f+") { ";var v=v||[];v.push(i),i="",!1!==t.createErrors?(i+=" { keyword: 'uniqueItems' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { i: i, j: j } ",!1!==t.opts.messages&&(i+=" , message: 'should NOT have duplicate items (items ## ' + j + ' and ' + i + ' are identical)' "),t.opts.verbose&&(i+=" , schema: ",i+=p?"validate.schema"+l:""+a,i+=" , parentSchema: validate.schema"+t.schemaPath+" , data: "+h+" "),i+=" } "):i+=" {} ";var b=i;i=v.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+b+"]); ":i+=" validate.errors = ["+b+"]; return false; ":i+=" var err = "+b+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",i+=" } ",c&&(i+=" else { ")}else c&&(i+=" if (true) { ");return i}},function(e,t,n){"use strict";var r=["multipleOf","maximum","exclusiveMaximum","minimum","exclusiveMinimum","maxLength","minLength","pattern","additionalItems","maxItems","minItems","uniqueItems","maxProperties","minProperties","required","additionalProperties","enum","format","const"];e.exports=function(e,t){for(var n=0;n<t.length;n++){e=JSON.parse(JSON.stringify(e));var i=t[n].split("/"),o=e,s;for(s=1;s<i.length;s++)o=o[i[s]];for(s=0;s<r.length;s++){var a=r[s],l=o[a];l&&(o[a]={anyOf:[l,{$ref:"https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/data.json#"}]})}}return e}},function(e,t,n){"use strict";var r=n(323).MissingRef;function i(e,t,n){var o=this;if("function"!=typeof this._opts.loadSchema)throw new Error("options.loadSchema should be a function");"function"==typeof t&&(n=t,t=void 0);var s=a(e).then(function(){var n=o._addSchema(e,void 0,t);return n.validate||l(n)});return n&&s.then(function(e){n(null,e)},n),s;function a(e){var t=e.$schema;return t&&!o.getSchema(t)?i.call(o,{$ref:t},!0):Promise.resolve()}function l(e){try{return o._compile(e)}catch(e){if(e instanceof r)return n(e);throw e}function n(n){var r=n.missingSchema;if(u(r))throw new Error("Schema "+r+" is loaded but "+n.missingRef+" cannot be resolved");var i=o._loadingSchemas[r];return i||(i=o._loadingSchemas[r]=o._opts.loadSchema(r),i.then(s,s)),i.then(function(e){if(!u(r))return a(e).then(function(){u(r)||o.addSchema(e,r,void 0,t)})}).then(function(){return l(e)});function s(){delete o._loadingSchemas[r]}function u(e){return o._refs[e]||o._schemas[e]}}}}e.exports=i},function(e,t,n){"use strict";var r=/^[a-z_$][a-z0-9_$-]*$/i,i=n(1709),o=n(631);e.exports={add:a,get:l,remove:u,validate:c};var s={definitions:{simpleTypes:o.definitions.simpleTypes},type:"object",dependencies:{schema:["validate"],$data:["validate"],statements:["inline"],valid:{not:{required:["macro"]}}},properties:{type:o.properties.type,schema:{type:"boolean"},statements:{type:"boolean"},dependencies:{type:"array",items:{type:"string"}},metaSchema:{type:"object"},modifying:{type:"boolean"},valid:{type:"boolean"},$data:{type:"boolean"},async:{type:"boolean"},errors:{anyOf:[{type:"boolean"},{const:"full"}]}}};function a(e,t){var n=this.RULES;if(n.keywords[e])throw new Error("Keyword "+e+" is already defined");if(!r.test(e))throw new Error("Keyword "+e+" is not a valid identifier");if(t){this.validateKeyword(t,!0);var o=t.type;if(Array.isArray(o))for(var s=0;s<o.length;s++)l(e,o[s],t);else l(e,o,t);var a=t.metaSchema;a&&(t.$data&&this._opts.$data&&(a={anyOf:[a,{$ref:"https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/data.json#"}]}),t.validateSchema=this.compile(a,!0))}function l(e,t,r){for(var o,s=0;s<n.length;s++){var a=n[s];if(a.type==t){o=a;break}}o||(o={type:t,rules:[]},n.push(o));var l={keyword:e,definition:r,custom:!0,code:i,implements:r.implements};o.rules.push(l),n.custom[e]=l}return n.keywords[e]=n.all[e]=!0,this}function l(e){var t=this.RULES.custom[e];return t?t.definition:this.RULES.keywords[e]||!1}function u(e){var t=this.RULES;delete t.keywords[e],delete t.all[e],delete t.custom[e];for(var n=0;n<t.length;n++)for(var r=t[n].rules,i=0;i<r.length;i++)if(r[i].keyword==e){r.splice(i,1);break}return this}function c(e,t){c.errors=null;var n=this._validateKeyword=this._validateKeyword||this.compile(s,!0);if(n(e))return!0;if(c.errors=n.errors,t)throw new Error("custom keyword definition is invalid: "+this.errorsText(n.errors));return!1}},function(e,t,n){"use strict";e.exports=function e(t,n,r){var i=" ",o=t.level,s=t.dataLevel,a=t.schema[n],l=t.schemaPath+t.util.getProperty(n),u=t.errSchemaPath+"/"+n,c=!t.opts.allErrors,h,f="data"+(s||""),p="valid"+o,d="errs__"+o,m=t.opts.$data&&a&&a.$data,g;m?(i+=" var schema"+o+" = "+t.util.getData(a.$data,s,t.dataPathArr)+"; ",g="schema"+o):g=a;var y=this,v="definition"+o,b=this.definition,_="",w,k,E,S,x;if(m&&b.$data){x="keywordValidate"+o;var C=b.validateSchema;i+=" var "+v+" = RULES.custom['"+n+"'].definition; var "+x+" = "+v+".validate;"}else{if(S=t.useCustomRule(this,a,t.schema,t),!S)return;g="validate.schema"+l,x=S.code,w=b.compile,k=b.inline,E=b.macro}var A=x+".errors",T="i"+o,I="ruleErr"+o,j=b.async;if(j&&!t.async)throw new Error("async keyword in sync schema");if(k||E||(i+=A+" = null;"),i+="var "+d+" = errors;var "+p+";",m&&b.$data&&(_+="}",i+=" if ("+g+" === undefined) { "+p+" = true; } else { ",C&&(_+="}",i+=" "+p+" = "+v+".validateSchema("+g+"); if ("+p+") { ")),k)b.statements?i+=" "+S.validate+" ":i+=" "+p+" = "+S.validate+"; ";else if(E){var R=t.util.copy(t),_="";R.level++;var B="valid"+R.level;R.schema=S.validate,R.schemaPath="";var O=t.compositeRule;t.compositeRule=R.compositeRule=!0;var P=t.validate(R).replace(/validate\.schema/g,x);t.compositeRule=R.compositeRule=O,i+=" "+P}else{var N=N||[];N.push(i),i="",i+=" "+x+".call( ",t.opts.passContext?i+="this":i+="self",w||!1===b.schema?i+=" , "+f+" ":i+=" , "+g+" , "+f+" , validate.schema"+t.schemaPath+" ",i+=" , (dataPath || '')",'""'!=t.errorPath&&(i+=" + "+t.errorPath);var D=s?"data"+(s-1||""):"parentData",M=s?t.dataPathArr[s]:"parentDataProperty";i+=" , "+D+" , "+M+" , rootData ) ";var F=i;i=N.pop(),!1===b.errors?(i+=" "+p+" = ",j&&(i+="await "),i+=F+"; "):j?(A="customErrors"+o,i+=" var "+A+" = null; try { "+p+" = await "+F+"; } catch (e) { "+p+" = false; if (e instanceof ValidationError) "+A+" = e.errors; else throw e; } "):i+=" "+A+" = null; "+p+" = "+F+"; "}if(b.modifying&&(i+=" if ("+D+") "+f+" = "+D+"["+M+"];"),i+=""+_,b.valid)c&&(i+=" if (true) { ");else{i+=" if ( ",void 0===b.valid?(i+=" !",i+=E?""+B:""+p):i+=" "+!b.valid+" ",i+=") { ",h=this.keyword;var N=N||[];N.push(i),i="";var N=N||[];N.push(i),i="",!1!==t.createErrors?(i+=" { keyword: '"+(h||"custom")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { keyword: '"+this.keyword+"' } ",!1!==t.opts.messages&&(i+=" , message: 'should pass \""+this.keyword+"\" keyword validation' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ";var L=i;i=N.pop(),!t.compositeRule&&c?t.async?i+=" throw new ValidationError(["+L+"]); ":i+=" validate.errors = ["+L+"]; return false; ":i+=" var err = "+L+"; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ";var U=i;i=N.pop(),k?b.errors?"full"!=b.errors&&(i+=" for (var "+T+"="+d+"; "+T+"<errors; "+T+"++) { var "+I+" = vErrors["+T+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+t.errorPath+"; if ("+I+".schemaPath === undefined) { "+I+'.schemaPath = "'+u+'"; } ',t.opts.verbose&&(i+=" "+I+".schema = "+g+"; "+I+".data = "+f+"; "),i+=" } "):!1===b.errors?i+=" "+U+" ":(i+=" if ("+d+" == errors) { "+U+" } else { for (var "+T+"="+d+"; "+T+"<errors; "+T+"++) { var "+I+" = vErrors["+T+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+t.errorPath+"; if ("+I+".schemaPath === undefined) { "+I+'.schemaPath = "'+u+'"; } ',t.opts.verbose&&(i+=" "+I+".schema = "+g+"; "+I+".data = "+f+"; "),i+=" } } "):E?(i+=" var err = ",!1!==t.createErrors?(i+=" { keyword: '"+(h||"custom")+"' , dataPath: (dataPath || '') + "+t.errorPath+" , schemaPath: "+t.util.toQuotedString(u)+" , params: { keyword: '"+this.keyword+"' } ",!1!==t.opts.messages&&(i+=" , message: 'should pass \""+this.keyword+"\" keyword validation' "),t.opts.verbose&&(i+=" , schema: validate.schema"+l+" , parentSchema: validate.schema"+t.schemaPath+" , data: "+f+" "),i+=" } "):i+=" {} ",i+="; if (vErrors === null) vErrors = [err]; else vErrors.push(err); errors++; ",!t.compositeRule&&c&&(t.async?i+=" throw new ValidationError(vErrors); ":i+=" validate.errors = vErrors; return false; ")):!1===b.errors?i+=" "+U+" ":(i+=" if (Array.isArray("+A+")) { if (vErrors === null) vErrors = "+A+"; else vErrors = vErrors.concat("+A+"); errors = vErrors.length; for (var "+T+"="+d+"; "+T+"<errors; "+T+"++) { var "+I+" = vErrors["+T+"]; if ("+I+".dataPath === undefined) "+I+".dataPath = (dataPath || '') + "+t.errorPath+"; "+I+'.schemaPath = "'+u+'"; ',t.opts.verbose&&(i+=" "+I+".schema = "+g+"; "+I+".data = "+f+"; "),i+=" } } else { "+U+" } "),i+=" } ",c&&(i+=" else { ")}return i}},function(e){e.exports={$schema:"http://json-schema.org/draft-07/schema#",$id:"https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/data.json#",description:"Meta-schema for $data reference (JSON Schema extension proposal)",type:"object",required:["$data"],properties:{$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties:!1}},function(e,t){function n(e){var t="validation failed";this.name="HARError",this.message=t,this.errors=e,"function"==typeof Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error(t).stack}n.prototype=Error.prototype,e.exports=n},function(e,t,n){"use strict";e.exports={afterRequest:n(1713),beforeRequest:n(1714),browser:n(1715),cache:n(1716),content:n(1717),cookie:n(1718),creator:n(1719),entry:n(1720),har:n(1721),header:n(1722),log:n(1723),page:n(1724),pageTimings:n(1725),postData:n(1726),query:n(1727),request:n(1728),response:n(1729),timings:n(1730)}},function(e){e.exports={$id:"afterRequest.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",optional:!0,required:["lastAccess","eTag","hitCount"],properties:{expires:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},lastAccess:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},eTag:{type:"string"},hitCount:{type:"integer"},comment:{type:"string"}}}},function(e){e.exports={$id:"beforeRequest.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",optional:!0,required:["lastAccess","eTag","hitCount"],properties:{expires:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},lastAccess:{type:"string",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))?"},eTag:{type:"string"},hitCount:{type:"integer"},comment:{type:"string"}}}},function(e){e.exports={$id:"browser.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["name","version"],properties:{name:{type:"string"},version:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"cache.json#",$schema:"http://json-schema.org/draft-06/schema#",properties:{beforeRequest:{oneOf:[{type:"null"},{$ref:"beforeRequest.json#"}]},afterRequest:{oneOf:[{type:"null"},{$ref:"afterRequest.json#"}]},comment:{type:"string"}}}},function(e){e.exports={$id:"content.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["size","mimeType"],properties:{size:{type:"integer"},compression:{type:"integer"},mimeType:{type:"string"},text:{type:"string"},encoding:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"cookie.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["name","value"],properties:{name:{type:"string"},value:{type:"string"},path:{type:"string"},domain:{type:"string"},expires:{type:["string","null"],format:"date-time"},httpOnly:{type:"boolean"},secure:{type:"boolean"},comment:{type:"string"}}}},function(e){e.exports={$id:"creator.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["name","version"],properties:{name:{type:"string"},version:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"entry.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",optional:!0,required:["startedDateTime","time","request","response","cache","timings"],properties:{pageref:{type:"string"},startedDateTime:{type:"string",format:"date-time",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))"},time:{type:"number",min:0},request:{$ref:"request.json#"},response:{$ref:"response.json#"},cache:{$ref:"cache.json#"},timings:{$ref:"timings.json#"},serverIPAddress:{type:"string",oneOf:[{format:"ipv4"},{format:"ipv6"}]},connection:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"har.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["log"],properties:{log:{$ref:"log.json#"}}}},function(e){e.exports={$id:"header.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["name","value"],properties:{name:{type:"string"},value:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"log.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["version","creator","entries"],properties:{version:{type:"string"},creator:{$ref:"creator.json#"},browser:{$ref:"browser.json#"},pages:{type:"array",items:{$ref:"page.json#"}},entries:{type:"array",items:{$ref:"entry.json#"}},comment:{type:"string"}}}},function(e){e.exports={$id:"page.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",optional:!0,required:["startedDateTime","id","title","pageTimings"],properties:{startedDateTime:{type:"string",format:"date-time",pattern:"^(\\d{4})(-)?(\\d\\d)(-)?(\\d\\d)(T)?(\\d\\d)(:)?(\\d\\d)(:)?(\\d\\d)(\\.\\d+)?(Z|([+-])(\\d\\d)(:)?(\\d\\d))"},id:{type:"string",unique:!0},title:{type:"string"},pageTimings:{$ref:"pageTimings.json#"},comment:{type:"string"}}}},function(e){e.exports={$id:"pageTimings.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",properties:{onContentLoad:{type:"number",min:-1},onLoad:{type:"number",min:-1},comment:{type:"string"}}}},function(e){e.exports={$id:"postData.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",optional:!0,required:["mimeType"],properties:{mimeType:{type:"string"},text:{type:"string"},params:{type:"array",required:["name"],properties:{name:{type:"string"},value:{type:"string"},fileName:{type:"string"},contentType:{type:"string"},comment:{type:"string"}}},comment:{type:"string"}}}},function(e){e.exports={$id:"query.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["name","value"],properties:{name:{type:"string"},value:{type:"string"},comment:{type:"string"}}}},function(e){e.exports={$id:"request.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["method","url","httpVersion","cookies","headers","queryString","headersSize","bodySize"],properties:{method:{type:"string"},url:{type:"string",format:"uri"},httpVersion:{type:"string"},cookies:{type:"array",items:{$ref:"cookie.json#"}},headers:{type:"array",items:{$ref:"header.json#"}},queryString:{type:"array",items:{$ref:"query.json#"}},postData:{$ref:"postData.json#"},headersSize:{type:"integer"},bodySize:{type:"integer"},comment:{type:"string"}}}},function(e){e.exports={$id:"response.json#",$schema:"http://json-schema.org/draft-06/schema#",type:"object",required:["status","statusText","httpVersion","cookies","headers","content","redirectURL","headersSize","bodySize"],properties:{status:{type:"integer"},statusText:{type:"string"},httpVersion:{type:"string"},cookies:{type:"array",items:{$ref:"cookie.json#"}},headers:{type:"array",items:{$ref:"header.json#"}},content:{$ref:"content.json#"},redirectURL:{type:"string"},headersSize:{type:"integer"},bodySize:{type:"integer"},comment:{type:"string"}}}},function(e){e.exports={$id:"timings.json#",$schema:"http://json-schema.org/draft-06/schema#",required:["send","wait","receive"],properties:{dns:{type:"number",min:-1},connect:{type:"number",min:-1},blocked:{type:"number",min:-1},send:{type:"number",min:-1},wait:{type:"number",min:-1},receive:{type:"number",min:-1},ssl:{type:"number",min:-1},comment:{type:"string"}}}},function(e){e.exports={$schema:"http://json-schema.org/draft-06/schema#",$id:"http://json-schema.org/draft-06/schema#",title:"Core schema meta-schema",definitions:{schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type:["object","boolean"],properties:{$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},title:{type:"string"},description:{type:"string"},default:{},examples:{type:"array",items:{}},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:{}},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:{},enum:{type:"array",minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},default:{}}},function(e,t,n){"use strict";var r=n(320),i=n(121),o=n(313),s=o.md5,a=o.toBase64;function l(e){this.request=e,this.hasAuth=!1,this.sentAuth=!1,this.bearerToken=null,this.user=null,this.pass=null}l.prototype.basic=function(e,t,n){var r=this;("string"!=typeof e||void 0!==t&&"string"!=typeof t)&&this.request.emit("error",new Error("auth() received invalid user or password")),this.user=e,this.pass=t,this.hasAuth=!0;var i=e+":"+(t||"");if(n||void 0===n){var o="Basic "+a(i);return this.sentAuth=!0,o}},l.prototype.bearer=function(e,t){var n=this;if(this.bearerToken=e,this.hasAuth=!0,t||void 0===t){"function"==typeof e&&(e=e());var r="Bearer "+(e||"");return this.sentAuth=!0,r}},l.prototype.digest=function(e,t,n){for(var r=this,o={},a=/([a-z0-9_-]+)=(?:"([^"]+)"|([a-z0-9_-]+))/gi;;){var l=a.exec(n);if(!l)break;o[l[1]]=l[2]||l[3]}var u=function(e,t,n,r,i,o){var a=s(t+":"+n+":"+r);return e&&"md5-sess"===e.toLowerCase()?s(a+":"+i+":"+o):a},c=/(^|,)\s*auth\s*($|,)/.test(o.qop)&&"auth",h=c&&"00000001",f=c&&i().replace(/-/g,""),p=u(o.algorithm,this.user,o.realm,this.pass,o.nonce,f),d=s(e+":"+t),m=s(c?p+":"+o.nonce+":"+h+":"+f+":"+c+":"+d:p+":"+o.nonce+":"+d),g={username:this.user,realm:o.realm,nonce:o.nonce,uri:t,qop:c,response:m,nc:h,cnonce:f,algorithm:o.algorithm,opaque:o.opaque};for(var y in n=[],g)g[y]&&("qop"===y||"nc"===y||"algorithm"===y?n.push(y+"="+g[y]):n.push(y+'="'+g[y]+'"'));return n="Digest "+n.join(", "),this.sentAuth=!0,n},l.prototype.onRequest=function(e,t,n,r){var i=this,o=this.request,s;void 0===r&&void 0===e?this.request.emit("error",new Error("no auth mechanism defined")):s=void 0!==r?this.bearer(r,n):this.basic(e,t,n),s&&o.setHeader("authorization",s)},l.prototype.onResponse=function(e){var t=this,n=this.request;if(!this.hasAuth||this.sentAuth)return null;var i=r(e.headers),o=i.get("www-authenticate"),s=o&&o.split(" ")[0].toLowerCase();switch(n.debug("reauth",s),s){case"basic":return this.basic(this.user,this.pass,!0);case"bearer":return this.bearer(this.bearerToken,!0);case"digest":return this.digest(n.method,n.path,o)}},t.Auth=l},function(e,t,n){"use strict";var r=n(32),i=n(621),o=n(320),s=n(121),a=n(1734),l=n(16),u=n(5).Buffer;function c(e){this.request=e,this.params=null}c.prototype.buildParams=function(e,t,n,r,i,o){var l={};for(var u in e)l["oauth_"+u]=e[u];l.oauth_version||(l.oauth_version="1.0"),l.oauth_timestamp||(l.oauth_timestamp=Math.floor(Date.now()/1e3).toString()),l.oauth_nonce||(l.oauth_nonce=s().replace(/-/g,"")),l.oauth_signature_method||(l.oauth_signature_method="HMAC-SHA1");var c=l.oauth_consumer_secret||l.oauth_private_key;delete l.oauth_consumer_secret,delete l.oauth_private_key;var h=l.oauth_token_secret;delete l.oauth_token_secret;var f=l.oauth_realm;delete l.oauth_realm,delete l.oauth_transport_method;var p=t.protocol+"//"+t.host+t.pathname,d=o.parse([].concat(r,i,o.stringify(l)).join("&"));return l.oauth_signature=a.sign(l.oauth_signature_method,n,p,d,c,h),f&&(l.realm=f),l},c.prototype.buildBodyHash=function(e,t){["HMAC-SHA1","RSA-SHA1"].indexOf(e.signature_method||"HMAC-SHA1")<0&&this.request.emit("error",new Error("oauth: "+e.signature_method+" signature_method not supported with body_hash signing."));var n=l.createHash("sha1");n.update(t||"");var r=n.digest("hex");return u.from(r,"hex").toString("base64")},c.prototype.concatParams=function(e,t,n){n=n||"";var r=Object.keys(e).filter(function(e){return"realm"!==e&&"oauth_signature"!==e}).sort();return e.realm&&r.splice(0,0,"realm"),r.push("oauth_signature"),r.map(function(t){return t+"="+n+a.rfc3986(e[t])+n}).join(t)},c.prototype.onRequest=function(e){var t=this;this.params=e;var n=this.request.uri||{},s=this.request.method||"",a=o(this.request.headers),l=this.request.body||"",u=this.request.qsLib||i,c,h,f=a.get("content-type")||"",p="application/x-www-form-urlencoded",d=e.transport_method||"header";f.slice(0,p.length)===p&&(f=p,c=l),n.query&&(h=n.query),"body"!==d||"POST"===s&&f===p||this.request.emit("error",new Error("oauth: transport_method of body requires POST and content-type "+p)),c||"boolean"!=typeof e.body_hash||(e.body_hash=this.buildBodyHash(e,this.request.body.toString()));var m=this.buildParams(e,n,s,h,c,u);switch(d){case"header":this.request.setHeader("Authorization","OAuth "+this.concatParams(m,",",'"'));break;case"query":var g=this.request.uri.href+=(h?"&":"?")+this.concatParams(m,"&");this.request.uri=r.parse(g),this.request.path=this.request.uri.path;break;case"body":this.request.body=(c?c+"&":"")+this.concatParams(m,"&");break;default:this.request.emit("error",new Error("oauth: transport_method invalid"))}},t.OAuth=c},function(e,t,n){var r=n(16);function i(e,t,n){return r.createHmac(n,e).update(t).digest("base64")}function o(e,t){return r.createSign("RSA-SHA1").update(t).sign(e,"base64")}function s(e){return encodeURIComponent(e).replace(/!/g,"%21").replace(/\*/g,"%2A").replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/'/g,"%27")}function a(e){var t,n,r=[];for(t in e)if(n=e[t],Array.isArray(n))for(var i=0;i<n.length;i++)r.push([t,n[i]]);else if("object"==typeof n)for(var o in n)r.push([t+"["+o+"]",n[o]]);else r.push([t,n]);return r}function l(e,t){return e>t?1:e<t?-1:0}function u(e,t,n){var r=a(n).map(function(e){return[s(e[0]),s(e[1]||"")]}).sort(function(e,t){return l(e[0],t[0])||l(e[1],t[1])}).map(function(e){return e.join("=")}).join("&"),i=[s(e?e.toUpperCase():"GET"),s(t),s(r)].join("&");return i}function c(e,t,n,r,o){var a=u(e,t,n),l=[r||"",o||""].map(s).join("&");return i(l,a,"sha1")}function h(e,t,n,r,o){var a=u(e,t,n),l=[r||"",o||""].map(s).join("&");return i(l,a,"sha256")}function f(e,t,n,r,i){var s=u(e,t,n),a=r||"";return o(a,s)}function p(e,t){var n=[e||"",t||""].map(s).join("&");return n}function d(e,t,n,r,i,o){var s,a=1;switch(e){case"RSA-SHA1":s=f;break;case"HMAC-SHA1":s=c;break;case"HMAC-SHA256":s=h;break;case"PLAINTEXT":s=p,a=4;break;default:throw new Error("Signature method not supported: "+e)}return s.apply(null,[].slice.call(arguments,a))}t.hmacsign=c,t.hmacsign256=h,t.rsasign=f,t.plaintext=p,t.sign=d,t.rfc3986=s,t.generateBase=u},function(e,t,n){"use strict";var r=n(16);function i(e){var t=6*(e+1),n=r.randomBytes(Math.ceil(t/8)),i=n.toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/=/g,"");return i.slice(0,e)}function o(e,t,n){var i=r.createHash(t);return i.update("hawk.1.payload\n"),i.update((n?n.split(";")[0].trim().toLowerCase():"")+"\n"),i.update(e||""),i.update("\n"),i.digest("base64")}t.calculateMac=function(e,t){var n="hawk.1.header\n"+t.ts+"\n"+t.nonce+"\n"+(t.method||"").toUpperCase()+"\n"+t.resource+"\n"+t.host.toLowerCase()+"\n"+t.port+"\n"+(t.hash||"")+"\n";t.ext&&(n+=t.ext.replace("\\","\\\\").replace("\n","\\n")),n+="\n",t.app&&(n=n+t.app+"\n"+(t.dlg||"")+"\n");var i=r.createHmac(e.algorithm,e.key).update(n),o=i.digest("base64");return o},t.header=function(e,n,r){var s=r.timestamp||Math.floor((Date.now()+(r.localtimeOffsetMsec||0))/1e3),a=r.credentials;if(!(a&&a.id&&a.key&&a.algorithm))return"";if(-1===["sha1","sha256"].indexOf(a.algorithm))return"";var l={ts:s,nonce:r.nonce||i(6),method:n,resource:e.pathname+(e.search||""),host:e.hostname,port:e.port||("http:"===e.protocol?80:443),hash:r.hash,ext:r.ext,app:r.app,dlg:r.dlg};l.hash||!r.payload&&""!==r.payload||(l.hash=o(r.payload,a.algorithm,r.contentType));var u=t.calculateMac(a,l),c=null!==l.ext&&void 0!==l.ext&&""!==l.ext,h='Hawk id="'+a.id+'", ts="'+l.ts+'", nonce="'+l.nonce+(l.hash?'", hash="'+l.hash:"")+(c?'", ext="'+l.ext.replace(/\\/g,"\\\\").replace(/"/g,'\\"'):"")+'", mac="'+u+'"';return l.app&&(h=h+', app="'+l.app+(l.dlg?'", dlg="'+l.dlg:"")+'"'),h}},function(e,t,n){"use strict";var r=n(121),i=n(1737),o=n(620),s=n(5).Buffer;function a(e){this.request=e,this.boundary=r(),this.chunked=!1,this.body=null}a.prototype.isChunked=function(e){var t=this,n=!1,r=e.data||e;return r.forEach||t.request.emit("error",new Error("Argument error, options.multipart.")),void 0!==e.chunked&&(n=e.chunked),"chunked"===t.request.getHeader("transfer-encoding")&&(n=!0),n||r.forEach(function(e){void 0===e.body&&t.request.emit("error",new Error("Body attribute missing in multipart.")),o(e.body)&&(n=!0)}),n},a.prototype.setHeaders=function(e){var t=this;e&&!this.request.hasHeader("transfer-encoding")&&this.request.setHeader("transfer-encoding","chunked");var n=this.request.getHeader("content-type");n&&-1!==n.indexOf("multipart")?-1!==n.indexOf("boundary")?this.boundary=n.replace(/.*boundary=([^\s;]+).*/,"$1"):this.request.setHeader("content-type",n+"; boundary="+this.boundary):this.request.setHeader("content-type","multipart/related; boundary="+this.boundary)},a.prototype.build=function(e,t){var n=this,r=t?new i:[];function o(e){return"number"==typeof e&&(e=e.toString()),t?r.append(e):r.push(s.from(e))}return n.request.preambleCRLF&&o("\r\n"),e.forEach(function(e){var t="--"+n.boundary+"\r\n";Object.keys(e).forEach(function(n){"body"!==n&&(t+=n+": "+e[n]+"\r\n")}),t+="\r\n",o(t),o(e.body),o("\r\n")}),o("--"+n.boundary+"--"),n.request.postambleCRLF&&o("\r\n"),r},a.prototype.onRequest=function(e){var t=this,n=this.isChunked(e),r=e.data||e;this.setHeaders(n),this.chunked=n,this.body=this.build(r,n)},t.Multipart=a},function(e,t,n){(function(t){var r=n(14),i=n(62).Stream,o=n(1738);function s(){this.writable=!1,this.readable=!0,this.dataSize=0,this.maxDataSize=2097152,this.pauseStreams=!0,this._released=!1,this._streams=[],this._currentStream=null,this._insideLoop=!1,this._pendingNext=!1}e.exports=s,r.inherits(s,i),s.create=function(e){var t=new this;for(var n in e=e||{},e)t[n]=e[n];return t},s.isStreamLike=function(e){return"function"!=typeof e&&"string"!=typeof e&&"boolean"!=typeof e&&"number"!=typeof e&&!t.isBuffer(e)},s.prototype.append=function(e){var t=s.isStreamLike(e);if(t){if(!(e instanceof o)){var n=o.create(e,{maxDataSize:1/0,pauseStream:this.pauseStreams});e.on("data",this._checkDataSize.bind(this)),e=n}this._handleErrors(e),this.pauseStreams&&e.pause()}return this._streams.push(e),this},s.prototype.pipe=function(e,t){return i.prototype.pipe.call(this,e,t),this.resume(),e},s.prototype._getNext=function(){if(this._currentStream=null,this._insideLoop)this._pendingNext=!0;else{this._insideLoop=!0;try{do{this._pendingNext=!1,this._realGetNext()}while(this._pendingNext)}finally{this._insideLoop=!1}}},s.prototype._realGetNext=function(){var e=this._streams.shift();if(void 0!==e)if("function"==typeof e){var t=e;t(function(e){var t=s.isStreamLike(e);t&&(e.on("data",this._checkDataSize.bind(this)),this._handleErrors(e)),this._pipeNext(e)}.bind(this))}else this._pipeNext(e);else this.end()},s.prototype._pipeNext=function(e){this._currentStream=e;var t=s.isStreamLike(e);if(t)return e.on("end",this._getNext.bind(this)),void e.pipe(this,{end:!1});var n=e;this.write(n),this._getNext()},s.prototype._handleErrors=function(e){var t=this;e.on("error",function(e){t._emitError(e)})},s.prototype.write=function(e){this.emit("data",e)},s.prototype.pause=function(){this.pauseStreams&&(this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.pause&&this._currentStream.pause(),this.emit("pause"))},s.prototype.resume=function(){this._released||(this._released=!0,this.writable=!0,this._getNext()),this.pauseStreams&&this._currentStream&&"function"==typeof this._currentStream.resume&&this._currentStream.resume(),this.emit("resume")},s.prototype.end=function(){this._reset(),this.emit("end")},s.prototype.destroy=function(){this._reset(),this.emit("close")},s.prototype._reset=function(){this.writable=!1,this._streams=[],this._currentStream=null},s.prototype._checkDataSize=function(){if(this._updateDataSize(),!(this.dataSize<=this.maxDataSize)){var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this._emitError(new Error(e))}},s.prototype._updateDataSize=function(){this.dataSize=0;var e=this;this._streams.forEach(function(t){t.dataSize&&(e.dataSize+=t.dataSize)}),this._currentStream&&this._currentStream.dataSize&&(this.dataSize+=this._currentStream.dataSize)},s.prototype._emitError=function(e){this._reset(),this.emit("error",e)}}).call(this,n(0).Buffer)},function(e,t,n){var r=n(62).Stream,i=n(14);function o(){this.source=null,this.dataSize=0,this.maxDataSize=1048576,this.pauseStream=!0,this._maxDataSizeExceeded=!1,this._released=!1,this._bufferedEvents=[]}e.exports=o,i.inherits(o,r),o.create=function(e,t){var n=new this;for(var r in t=t||{},t)n[r]=t[r];n.source=e;var i=e.emit;return e.emit=function(){return n._handleEmit(arguments),i.apply(e,arguments)},e.on("error",function(){}),n.pauseStream&&e.pause(),n},Object.defineProperty(o.prototype,"readable",{configurable:!0,enumerable:!0,get:function(){return this.source.readable}}),o.prototype.setEncoding=function(){return this.source.setEncoding.apply(this.source,arguments)},o.prototype.resume=function(){this._released||this.release(),this.source.resume()},o.prototype.pause=function(){this.source.pause()},o.prototype.release=function(){this._released=!0,this._bufferedEvents.forEach(function(e){this.emit.apply(this,e)}.bind(this)),this._bufferedEvents=[]},o.prototype.pipe=function(){var e=r.prototype.pipe.apply(this,arguments);return this.resume(),e},o.prototype._handleEmit=function(e){this._released?this.emit.apply(this,e):("data"===e[0]&&(this.dataSize+=e[1].length,this._checkIfMaxDataSizeExceeded()),this._bufferedEvents.push(e))},o.prototype._checkIfMaxDataSizeExceeded=function(){if(!(this._maxDataSizeExceeded||this.dataSize<=this.maxDataSize)){this._maxDataSizeExceeded=!0;var e="DelayedStream#maxDataSize of "+this.maxDataSize+" bytes exceeded.";this.emit("error",new Error(e))}}},function(e,t,n){"use strict";var r=n(32),i=/^https?:/;function o(e){this.request=e,this.followRedirect=!0,this.followRedirects=!0,this.followAllRedirects=!1,this.followOriginalHttpMethod=!1,this.allowRedirect=function(){return!0},this.maxRedirects=10,this.redirects=[],this.redirectsFollowed=0,this.removeRefererHeader=!1}o.prototype.onRequest=function(e){var t=this;void 0!==e.maxRedirects&&(this.maxRedirects=e.maxRedirects),"function"==typeof e.followRedirect&&(this.allowRedirect=e.followRedirect),void 0!==e.followRedirect&&(this.followRedirects=!!e.followRedirect),void 0!==e.followAllRedirects&&(this.followAllRedirects=e.followAllRedirects),(this.followRedirects||this.followAllRedirects)&&(this.redirects=this.redirects||[]),void 0!==e.removeRefererHeader&&(this.removeRefererHeader=e.removeRefererHeader),void 0!==e.followOriginalHttpMethod&&(this.followOriginalHttpMethod=e.followOriginalHttpMethod)},o.prototype.redirectTo=function(e){var t=this,n=this.request,r=null;if(e.statusCode>=300&&e.statusCode<400&&e.caseless.has("location")){var i=e.caseless.get("location");if(n.debug("redirect",i),this.followAllRedirects)r=i;else if(this.followRedirects)switch(n.method){case"PATCH":case"PUT":case"POST":case"DELETE":break;default:r=i}}else if(401===e.statusCode){var o=n._auth.onResponse(e);o&&(n.setHeader("authorization",o),r=n.uri)}return r},o.prototype.onResponse=function(e){var t=this,n=this.request,o=this.redirectTo(e);if(!o||!this.allowRedirect.call(n,e))return!1;if(n.debug("redirect to",o),e.resume&&e.resume(),this.redirectsFollowed>=this.maxRedirects)return n.emit("error",new Error("Exceeded maxRedirects. Probably stuck in a redirect loop "+n.uri.href)),!1;this.redirectsFollowed+=1,i.test(o)||(o=r.resolve(n.uri.href,o));var s=n.uri;return n.uri=r.parse(o),n.uri.protocol!==s.protocol&&delete n.agent,this.redirects.push({statusCode:e.statusCode,redirectUri:o}),this.followAllRedirects&&"HEAD"!==n.method&&401!==e.statusCode&&307!==e.statusCode&&(n.method=this.followOriginalHttpMethod?n.method:"GET"),delete n.src,delete n.req,delete n._started,401!==e.statusCode&&307!==e.statusCode&&(delete n.body,delete n._form,n.headers&&(n.removeHeader("host"),n.removeHeader("content-type"),n.removeHeader("content-length"),n.uri.hostname!==n.originalHost.split(":")[0]&&n.removeHeader("authorization"))),this.removeRefererHeader||n.setHeader("referer",s.href),n.emit("redirect"),n.init(),!0},t.Redirect=o},function(e,t,n){"use strict";var r=n(32),i=n(1741),o=["accept","accept-charset","accept-encoding","accept-language","accept-ranges","cache-control","content-encoding","content-language","content-location","content-md5","content-range","content-type","connection","date","expect","max-forwards","pragma","referer","te","user-agent","via"],s=["proxy-authorization"];function a(e){var t=e.port,n=e.protocol,r=e.hostname+":";return r+=t||("https:"===n?"443":"80"),r}function l(e,t){var n=t.reduce(function(e,t){return e[t.toLowerCase()]=!0,e},{});return Object.keys(e).filter(function(e){return n[e.toLowerCase()]}).reduce(function(t,n){return t[n]=e[n],t},{})}function u(e,t){var n=e.proxy,r={proxy:{host:n.hostname,port:+n.port,proxyAuth:n.auth,headers:t},headers:e.headers,ca:e.ca,cert:e.cert,key:e.key,passphrase:e.passphrase,pfx:e.pfx,ciphers:e.ciphers,rejectUnauthorized:e.rejectUnauthorized,secureOptions:e.secureOptions,secureProtocol:e.secureProtocol};return r}function c(e,t){var n="https:"===e.protocol?"https":"http",r="https:"===t.protocol?"Https":"Http";return[n,r].join("Over")}function h(e){var t=e.uri,n=e.proxy,r=c(t,n);return i[r]}function f(e){this.request=e,this.proxyHeaderWhiteList=o,this.proxyHeaderExclusiveList=[],void 0!==e.tunnel&&(this.tunnelOverride=e.tunnel)}f.prototype.isEnabled=function(){var e=this,t=this.request;return void 0!==this.tunnelOverride?this.tunnelOverride:"https:"===t.uri.protocol},f.prototype.setup=function(e){var t=this,n=this.request;if(e=e||{},"string"==typeof n.proxy&&(n.proxy=r.parse(n.proxy)),!n.proxy||!n.tunnel)return!1;e.proxyHeaderWhiteList&&(this.proxyHeaderWhiteList=e.proxyHeaderWhiteList),e.proxyHeaderExclusiveList&&(this.proxyHeaderExclusiveList=e.proxyHeaderExclusiveList);var i=this.proxyHeaderExclusiveList.concat(s),o=this.proxyHeaderWhiteList.concat(i),c=l(n.headers,o);c.host=a(n.uri),i.forEach(n.removeHeader,n);var f=h(n),p=u(n,c);return n.agent=f(p),!0},f.defaultProxyHeaderWhiteList=o,f.defaultProxyHeaderExclusiveList=s,t.Tunnel=f},function(e,t,n){"use strict";(function(e){var r=n(16),i=n(16),o=n(131),s=n(169),a=n(6),l=n(24),u=n(14),c=n(5).Buffer,h;function f(e){var t=new g(e);return t.request=o.request,t}function p(e){var t=new g(e);return t.request=o.request,t.createSocket=y,t.defaultPort=443,t}function d(e){var t=new g(e);return t.request=s.request,t}function m(e){var t=new g(e);return t.request=s.request,t.createSocket=y,t.defaultPort=443,t}function g(e){var t=this;t.options=e||{},t.proxyOptions=t.options.proxy||{},t.maxSockets=t.options.maxSockets||o.Agent.defaultMaxSockets,t.requests=[],t.sockets=[],t.on("free",function e(n,r,i){for(var o=0,s=t.requests.length;o<s;++o){var a=t.requests[o];if(a.host===r&&a.port===i)return t.requests.splice(o,1),void a.request.onSocket(n)}n.destroy(),t.removeSocket(n)})}function y(e,t){var n=this;g.prototype.createSocket.call(n,e,function(r){var o=i.connect(0,v({},n.options,{servername:e.host,socket:r}));n.sockets[n.sockets.indexOf(r)]=o,t(o)})}function v(e){for(var t=1,n=arguments.length;t<n;++t){var r=arguments[t];if("object"==typeof r)for(var i=Object.keys(r),o=0,s=i.length;o<s;++o){var a=i[o];void 0!==r[a]&&(e[a]=r[a])}}return e}t.httpOverHttp=f,t.httpsOverHttp=p,t.httpOverHttps=d,t.httpsOverHttps=m,u.inherits(g,a.EventEmitter),g.prototype.addRequest=function e(t,n){var r=this;"string"==typeof n&&(n={host:n,port:arguments[2],path:arguments[3]}),this.sockets.length>=this.maxSockets?this.requests.push({host:n.host,port:n.port,request:t}):this.createConnection({host:n.host,port:n.port,request:t})},g.prototype.createConnection=function e(t){var n=this;n.createSocket(t,function(e){function r(){n.emit("free",e,t.host,t.port)}function i(t){n.removeSocket(e),e.removeListener("free",r),e.removeListener("close",i),e.removeListener("agentRemove",i)}e.on("free",r),e.on("close",i),e.on("agentRemove",i),t.request.onSocket(e)})},g.prototype.createSocket=function t(n,r){var i=this,o={};i.sockets.push(o);var s=v({},i.proxyOptions,{method:"CONNECT",path:n.host+":"+n.port,agent:!1});s.proxyAuth&&(s.headers=s.headers||{},s.headers["Proxy-Authorization"]="Basic "+c.from(s.proxyAuth).toString("base64")),h("making CONNECT request");var a=i.request(s);function u(e){e.upgrade=!0}function f(t,n,r){e.nextTick(function(){p(t,n,r)})}function p(e,t,s){if(a.removeAllListeners(),t.removeAllListeners(),200===e.statusCode)l.equal(s.length,0),h("tunneling connection has established"),i.sockets[i.sockets.indexOf(o)]=t,r(t);else{h("tunneling socket could not be established, statusCode=%d",e.statusCode);var u=new Error("tunneling socket could not be established, statusCode="+e.statusCode);u.code="ECONNRESET",n.request.emit("error",u),i.removeSocket(o)}}function d(e){a.removeAllListeners(),h("tunneling socket could not be established, cause=%s\n",e.message,e.stack);var t=new Error("tunneling socket could not be established, cause="+e.message);t.code="ECONNRESET",n.request.emit("error",t),i.removeSocket(o)}a.useChunkedEncodingByDefault=!1,a.once("response",u),a.once("upgrade",f),a.once("connect",p),a.once("error",d),a.end()},g.prototype.removeSocket=function e(t){var n=this.sockets.indexOf(t);if(-1!==n){this.sockets.splice(n,1);var r=this.requests.shift();r&&this.createConnection(r)}},h=e.env.NODE_DEBUG&&/\btunnel\b/.test(e.env.NODE_DEBUG)?function(){var e=Array.prototype.slice.call(arguments);"string"==typeof e[0]?e[0]="TUNNEL: "+e[0]:e.unshift("TUNNEL:"),console.error.apply(console,e)}:function(){},t.debug=h}).call(this,n(3))},function(e,t,n){(function(t){(function(){var n,r,i,o,s,a;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:void 0!==t&&null!==t&&t.hrtime?(e.exports=function(){return(n()-s)/1e6},r=t.hrtime,n=function(){var e;return e=r(),1e9*e[0]+e[1]},o=n(),a=1e9*t.uptime(),s=o-a):Date.now?(e.exports=function(){return Date.now()-i},i=Date.now()):(e.exports=function(){return(new Date).getTime()-i},i=(new Date).getTime())}).call(this)}).call(this,n(3))},function(e,t,n){"use strict";(function(e){var t=n(1744).getNewLibraryCopy(),r=n(1745),i=n(1748);try{var o=i(n.c,function(){return n(605)},function(){n(1749)},e)}catch(e){var s=n(198).EOL;throw console.error(s+"###"+s+'### The "request" library is not installed automatically anymore.'+s+'### But is a dependency of "request-promise".'+s+"### Please install it with:"+s+"### npm install request --save"+s+"###"+s),e}t.config({cancellation:!0}),r({request:o,PromiseImpl:t,expose:["then","catch","finally","cancel","promise"],constructorMixin:function(e,t,n){var r=this;n(function(){r.abort()})}}),o.bindCLS=function e(){throw new Error("CLS support was dropped. To get it back read: https://github.com/request/request-promise/wiki/Getting-Back-Support-for-Continuation-Local-Storage")},e.exports=o}).call(this,n(85)(e))},function(e,t,n){(function(t,n){var r,i;r=function(){var e,r,i;return function e(t,n,r){function i(s,a){if(!n[s]){if(!t[s]){var l="function"==typeof _dereq_&&_dereq_;if(!a&&l)return l(s,!0);if(o)return o(s,!0);var u=new Error("Cannot find module '"+s+"'");throw u.code="MODULE_NOT_FOUND",u}var c=n[s]={exports:{}};t[s][0].call(c.exports,function(e){var n=t[s][1][e];return i(n||e)},c,c.exports,e,t,n,r)}return n[s].exports}for(var o="function"==typeof _dereq_&&_dereq_,s=0;s<r.length;s++)i(r[s]);return i}({1:[function(e,t,n){"use strict";t.exports=function(e){var t=e._SomePromiseArray;function n(e){var n=new t(e),r=n.promise();return n.setHowMany(1),n.setUnwrap(),n.init(),r}e.any=function(e){return n(e)},e.prototype.any=function(){return n(this)}}},{}],2:[function(e,n,r){"use strict";var i;try{throw new Error}catch(e){i=e}var o=e("./schedule"),s=e("./queue"),a=e("./util");function l(){this._customScheduler=!1,this._isTickUsed=!1,this._lateQueue=new s(16),this._normalQueue=new s(16),this._haveDrainedQueues=!1,this._trampolineEnabled=!0;var e=this;this.drainQueues=function(){e._drainQueues()},this._schedule=o}function u(e,t,n){this._lateQueue.push(e,t,n),this._queueTick()}function c(e,t,n){this._normalQueue.push(e,t,n),this._queueTick()}function h(e){this._normalQueue._pushOne(e),this._queueTick()}function f(e){for(;e.length()>0;)p(e)}function p(e){var t=e.shift();if("function"!=typeof t)t._settlePromises();else{var n=e.shift(),r=e.shift();t.call(n,r)}}l.prototype.setScheduler=function(e){var t=this._schedule;return this._schedule=e,this._customScheduler=!0,t},l.prototype.hasCustomScheduler=function(){return this._customScheduler},l.prototype.enableTrampoline=function(){this._trampolineEnabled=!0},l.prototype.disableTrampolineIfNecessary=function(){a.hasDevTools&&(this._trampolineEnabled=!1)},l.prototype.haveItemsQueued=function(){return this._isTickUsed||this._haveDrainedQueues},l.prototype.fatalError=function(e,n){n?(t.stderr.write("Fatal "+(e instanceof Error?e.stack:e)+"\n"),t.exit(2)):this.throwLater(e)},l.prototype.throwLater=function(e,t){if(1===arguments.length&&(t=e,e=function(){throw t}),"undefined"!=typeof setTimeout)setTimeout(function(){e(t)},0);else try{this._schedule(function(){e(t)})}catch(e){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")}},a.hasDevTools?(l.prototype.invokeLater=function(e,t,n){this._trampolineEnabled?u.call(this,e,t,n):this._schedule(function(){setTimeout(function(){e.call(t,n)},100)})},l.prototype.invoke=function(e,t,n){this._trampolineEnabled?c.call(this,e,t,n):this._schedule(function(){e.call(t,n)})},l.prototype.settlePromises=function(e){this._trampolineEnabled?h.call(this,e):this._schedule(function(){e._settlePromises()})}):(l.prototype.invokeLater=u,l.prototype.invoke=c,l.prototype.settlePromises=h),l.prototype._drainQueues=function(){f(this._normalQueue),this._reset(),this._haveDrainedQueues=!0,f(this._lateQueue)},l.prototype._queueTick=function(){this._isTickUsed||(this._isTickUsed=!0,this._schedule(this.drainQueues))},l.prototype._reset=function(){this._isTickUsed=!1},n.exports=l,n.exports.firstLineError=i},{"./queue":26,"./schedule":29,"./util":36}],3:[function(e,t,n){"use strict";t.exports=function(e,t,n,r){var i=!1,o=function(e,t){this._reject(t)},s=function(e,t){t.promiseRejectionQueued=!0,t.bindingPromise._then(o,o,null,this,e)},a=function(e,t){0==(50397184&this._bitField)&&this._resolveCallback(t.target)},l=function(e,t){t.promiseRejectionQueued||this._reject(e)};e.prototype.bind=function(o){i||(i=!0,e.prototype._propagateFrom=r.propagateFromFunction(),e.prototype._boundValue=r.boundValueFunction());var u=n(o),c=new e(t);c._propagateFrom(this,1);var h=this._target();if(c._setBoundTo(u),u instanceof e){var f={promiseRejectionQueued:!1,promise:c,target:h,bindingPromise:u};h._then(t,s,void 0,c,f),u._then(a,l,void 0,c,f),c._setOnCancel(u)}else c._resolveCallback(h);return c},e.prototype._setBoundTo=function(e){void 0!==e?(this._bitField=2097152|this._bitField,this._boundTo=e):this._bitField=-2097153&this._bitField},e.prototype._isBound=function(){return 2097152==(2097152&this._bitField)},e.bind=function(t,n){return e.resolve(n).bind(t)}}},{}],4:[function(e,t,n){"use strict";var r;function i(){try{Promise===o&&(Promise=r)}catch(e){}return o}"undefined"!=typeof Promise&&(r=Promise);var o=e("./promise")();o.noConflict=i,t.exports=o},{"./promise":22}],5:[function(e,t,n){"use strict";var r=Object.create;if(r){var i=r(null),o=r(null);i[" size"]=o[" size"]=0}t.exports=function(t){var n=e("./util"),r=n.canEvaluate,i=n.isIdentifier,o,s,a,l,u;function c(e,r){var i;if(null!=e&&(i=e[r]),"function"!=typeof i){var o="Object "+n.classString(e)+" has no method '"+n.toString(r)+"'";throw new t.TypeError(o)}return i}function h(e){var t=this.pop(),n=c(e,t);return n.apply(e,this)}function f(e){return e[this]}function p(e){var t=+this;return t<0&&(t=Math.max(0,t+e.length)),e[t]}t.prototype.call=function(e){var t=[].slice.call(arguments,1),n;return t.push(e),this._then(h,void 0,void 0,t,void 0)},t.prototype.get=function(e){var t="number"==typeof e,n;if(t)n=p;else if(r){var i=(void 0)(e);n=null!==i?i:f}else n=f;return this._then(n,void 0,void 0,e,void 0)}}},{"./util":36}],6:[function(e,t,n){"use strict";t.exports=function(t,n,r,i){var o=e("./util"),s=o.tryCatch,a=o.errorObj,l=t._async;t.prototype.break=t.prototype.cancel=function(){if(!i.cancellation())return this._warn("cancellation is disabled");for(var e=this,t=e;e._isCancellable();){if(!e._cancelBy(t)){t._isFollowing()?t._followee().cancel():t._cancelBranched();break}var n=e._cancellationParent;if(null==n||!n._isCancellable()){e._isFollowing()?e._followee().cancel():e._cancelBranched();break}e._isFollowing()&&e._followee().cancel(),e._setWillBeCancelled(),t=e,e=n}},t.prototype._branchHasCancelled=function(){this._branchesRemainingToCancel--},t.prototype._enoughBranchesHaveCancelled=function(){return void 0===this._branchesRemainingToCancel||this._branchesRemainingToCancel<=0},t.prototype._cancelBy=function(e){return e===this?(this._branchesRemainingToCancel=0,this._invokeOnCancel(),!0):(this._branchHasCancelled(),!!this._enoughBranchesHaveCancelled()&&(this._invokeOnCancel(),!0))},t.prototype._cancelBranched=function(){this._enoughBranchesHaveCancelled()&&this._cancel()},t.prototype._cancel=function(){this._isCancellable()&&(this._setCancelled(),l.invoke(this._cancelPromises,this,void 0))},t.prototype._cancelPromises=function(){this._length()>0&&this._settlePromises()},t.prototype._unsetOnCancel=function(){this._onCancelField=void 0},t.prototype._isCancellable=function(){return this.isPending()&&!this._isCancelled()},t.prototype.isCancellable=function(){return this.isPending()&&!this.isCancelled()},t.prototype._doInvokeOnCancel=function(e,t){if(o.isArray(e))for(var n=0;n<e.length;++n)this._doInvokeOnCancel(e[n],t);else if(void 0!==e)if("function"==typeof e){if(!t){var r=s(e).call(this._boundValue());r===a&&(this._attachExtraTrace(r.e),l.throwLater(r.e))}}else e._resultCancelled(this)},t.prototype._invokeOnCancel=function(){var e=this._onCancel();this._unsetOnCancel(),l.invoke(this._doInvokeOnCancel,this,e)},t.prototype._invokeInternalOnCancel=function(){this._isCancellable()&&(this._doInvokeOnCancel(this._onCancel(),!0),this._unsetOnCancel())},t.prototype._resultCancelled=function(){this.cancel()}}},{"./util":36}],7:[function(e,t,n){"use strict";t.exports=function(t){var n=e("./util"),r=e("./es5").keys,i=n.tryCatch,o=n.errorObj;function s(e,s,a){return function(l){var u=a._boundValue();e:for(var c=0;c<e.length;++c){var h=e[c];if(h===Error||null!=h&&h.prototype instanceof Error){if(l instanceof h)return i(s).call(u,l)}else if("function"==typeof h){var f=i(h).call(u,l);if(f===o)return f;if(f)return i(s).call(u,l)}else if(n.isObject(l)){for(var p=r(h),d=0;d<p.length;++d){var m=p[d];if(h[m]!=l[m])continue e}return i(s).call(u,l)}}return t}}return s}},{"./es5":13,"./util":36}],8:[function(e,t,n){"use strict";t.exports=function(e){var t=!1,n=[];function r(){this._trace=new r.CapturedTrace(o())}function i(){if(t)return new r}function o(){var e=n.length-1;if(e>=0)return n[e]}return e.prototype._promiseCreated=function(){},e.prototype._pushContext=function(){},e.prototype._popContext=function(){return null},e._peekContext=e.prototype._peekContext=function(){},r.prototype._pushContext=function(){void 0!==this._trace&&(this._trace._promiseCreated=null,n.push(this._trace))},r.prototype._popContext=function(){if(void 0!==this._trace){var e=n.pop(),t=e._promiseCreated;return e._promiseCreated=null,t}return null},r.CapturedTrace=null,r.create=i,r.deactivateLongStackTraces=function(){},r.activateLongStackTraces=function(){var n=e.prototype._pushContext,i=e.prototype._popContext,s=e._peekContext,a=e.prototype._peekContext,l=e.prototype._promiseCreated;r.deactivateLongStackTraces=function(){e.prototype._pushContext=n,e.prototype._popContext=i,e._peekContext=s,e.prototype._peekContext=a,e.prototype._promiseCreated=l,t=!1},t=!0,e.prototype._pushContext=r.prototype._pushContext,e.prototype._popContext=r.prototype._popContext,e._peekContext=e.prototype._peekContext=o,e.prototype._promiseCreated=function(){var e=this._peekContext();e&&null==e._promiseCreated&&(e._promiseCreated=this)}},r}},{}],9:[function(e,n,r){"use strict";n.exports=function(n,r){var i=n._getDomain,o=n._async,s=e("./errors").Warning,a=e("./util"),l=e("./es5"),u=a.canAttachTrace,c,h,f=/[\\\/]bluebird[\\\/]js[\\\/](release|debug|instrumented)/,p=/\((?:timers\.js):\d+:\d+\)/,d=/[\/<\(](.+?):(\d+):(\d+)\)?\s*$/,m=null,g=null,y=!1,v,b=!(0==a.env("BLUEBIRD_DEBUG")),_=!(0==a.env("BLUEBIRD_WARNINGS")||!b&&!a.env("BLUEBIRD_WARNINGS")),w=!(0==a.env("BLUEBIRD_LONG_STACK_TRACES")||!b&&!a.env("BLUEBIRD_LONG_STACK_TRACES")),k=0!=a.env("BLUEBIRD_W_FORGOTTEN_RETURN")&&(_||!!a.env("BLUEBIRD_W_FORGOTTEN_RETURN"));n.prototype.suppressUnhandledRejections=function(){var e=this._target();e._bitField=-1048577&e._bitField|524288},n.prototype._ensurePossibleRejectionHandled=function(){if(0==(524288&this._bitField)){this._setRejectionIsUnhandled();var e=this;setTimeout(function(){e._notifyUnhandledRejection()},1)}},n.prototype._notifyUnhandledRejectionIsHandled=function(){Q("rejectionHandled",c,void 0,this)},n.prototype._setReturnedNonUndefined=function(){this._bitField=268435456|this._bitField},n.prototype._returnedNonUndefined=function(){return 0!=(268435456&this._bitField)},n.prototype._notifyUnhandledRejection=function(){if(this._isRejectionUnhandled()){var e=this._settledValue();this._setUnhandledRejectionIsNotified(),Q("unhandledRejection",h,e,this)}},n.prototype._setUnhandledRejectionIsNotified=function(){this._bitField=262144|this._bitField},n.prototype._unsetUnhandledRejectionIsNotified=function(){this._bitField=-262145&this._bitField},n.prototype._isUnhandledRejectionNotified=function(){return(262144&this._bitField)>0},n.prototype._setRejectionIsUnhandled=function(){this._bitField=1048576|this._bitField},n.prototype._unsetRejectionIsUnhandled=function(){this._bitField=-1048577&this._bitField,this._isUnhandledRejectionNotified()&&(this._unsetUnhandledRejectionIsNotified(),this._notifyUnhandledRejectionIsHandled())},n.prototype._isRejectionUnhandled=function(){return(1048576&this._bitField)>0},n.prototype._warn=function(e,t,n){return H(e,t,n||this)},n.onPossiblyUnhandledRejection=function(e){var t=i();h="function"==typeof e?null===t?e:a.domainBind(t,e):void 0},n.onUnhandledRejectionHandled=function(e){var t=i();c="function"==typeof e?null===t?e:a.domainBind(t,e):void 0};var E=function(){};n.longStackTraces=function(){if(o.haveItemsQueued()&&!le.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");if(!le.longStackTraces&&te()){var e=n.prototype._captureStackTrace,t=n.prototype._attachExtraTrace,i=n.prototype._dereferenceTrace;le.longStackTraces=!0,E=function(){if(o.haveItemsQueued()&&!le.longStackTraces)throw new Error("cannot enable long stack traces after promises have been created\n\n See http://goo.gl/MqrFmX\n");n.prototype._captureStackTrace=e,n.prototype._attachExtraTrace=t,n.prototype._dereferenceTrace=i,r.deactivateLongStackTraces(),o.enableTrampoline(),le.longStackTraces=!1},n.prototype._captureStackTrace=L,n.prototype._attachExtraTrace=U,n.prototype._dereferenceTrace=q,r.activateLongStackTraces(),o.disableTrampolineIfNecessary()}},n.hasLongStackTraces=function(){return le.longStackTraces&&te()};var S=function(){try{if("function"==typeof CustomEvent){var e=new CustomEvent("CustomEvent");return a.global.dispatchEvent(e),function(e,t){var n={detail:t,cancelable:!0};l.defineProperty(n,"promise",{value:t.promise}),l.defineProperty(n,"reason",{value:t.reason});var r=new CustomEvent(e.toLowerCase(),n);return!a.global.dispatchEvent(r)}}if("function"==typeof Event){var e=new Event("CustomEvent");return a.global.dispatchEvent(e),function(e,t){var n=new Event(e.toLowerCase(),{cancelable:!0});return n.detail=t,l.defineProperty(n,"promise",{value:t.promise}),l.defineProperty(n,"reason",{value:t.reason}),!a.global.dispatchEvent(n)}}var e=document.createEvent("CustomEvent");return e.initCustomEvent("testingtheevent",!1,!0,{}),a.global.dispatchEvent(e),function(e,t){var n=document.createEvent("CustomEvent");return n.initCustomEvent(e.toLowerCase(),!1,!0,t),!a.global.dispatchEvent(n)}}catch(e){}return function(){return!1}}(),x=a.isNode?function(){return t.emit.apply(t,arguments)}:a.global?function(e){var t="on"+e.toLowerCase(),n=a.global[t];return!!n&&(n.apply(a.global,[].slice.call(arguments,1)),!0)}:function(){return!1};function C(e,t){return{promise:t}}var A={promiseCreated:C,promiseFulfilled:C,promiseRejected:C,promiseResolved:C,promiseCancelled:C,promiseChained:function(e,t,n){return{promise:t,child:n}},warning:function(e,t){return{warning:t}},unhandledRejection:function(e,t,n){return{reason:t,promise:n}},rejectionHandled:C},T=function(e){var t=!1;try{t=x.apply(null,arguments)}catch(e){o.throwLater(e),t=!0}var n=!1;try{n=S(e,A[e].apply(null,arguments))}catch(e){o.throwLater(e),n=!0}return n||t};function I(){return!1}function j(e,t,n){var r=this;try{e(t,n,function(e){if("function"!=typeof e)throw new TypeError("onCancel must be a function, got: "+a.toString(e));r._attachCancellationCallback(e)})}catch(e){return e}}function R(e){if(!this._isCancellable())return this;var t=this._onCancel();void 0!==t?a.isArray(t)?t.push(e):this._setOnCancel([t,e]):this._setOnCancel(e)}function B(){return this._onCancelField}function O(e){this._onCancelField=e}function P(){this._cancellationParent=void 0,this._onCancelField=void 0}function N(e,t){if(0!=(1&t)){this._cancellationParent=e;var n=e._branchesRemainingToCancel;void 0===n&&(n=0),e._branchesRemainingToCancel=n+1}0!=(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}function D(e,t){0!=(2&t)&&e._isBound()&&this._setBoundTo(e._boundTo)}n.config=function(e){if(e=Object(e),"longStackTraces"in e&&(e.longStackTraces?n.longStackTraces():!e.longStackTraces&&n.hasLongStackTraces()&&E()),"warnings"in e){var t=e.warnings;le.warnings=!!t,k=le.warnings,a.isObject(t)&&"wForgottenReturn"in t&&(k=!!t.wForgottenReturn)}if("cancellation"in e&&e.cancellation&&!le.cancellation){if(o.haveItemsQueued())throw new Error("cannot enable cancellation after promises are in use");n.prototype._clearCancellationData=P,n.prototype._propagateFrom=N,n.prototype._onCancel=B,n.prototype._setOnCancel=O,n.prototype._attachCancellationCallback=R,n.prototype._execute=j,M=N,le.cancellation=!0}return"monitoring"in e&&(e.monitoring&&!le.monitoring?(le.monitoring=!0,n.prototype._fireEvent=T):!e.monitoring&&le.monitoring&&(le.monitoring=!1,n.prototype._fireEvent=I)),n},n.prototype._fireEvent=I,n.prototype._execute=function(e,t,n){try{e(t,n)}catch(e){return e}},n.prototype._onCancel=function(){},n.prototype._setOnCancel=function(e){},n.prototype._attachCancellationCallback=function(e){},n.prototype._captureStackTrace=function(){},n.prototype._attachExtraTrace=function(){},n.prototype._dereferenceTrace=function(){},n.prototype._clearCancellationData=function(){},n.prototype._propagateFrom=function(e,t){};var M=D;function F(){var e=this._boundTo;return void 0!==e&&e instanceof n?e.isFulfilled()?e.value():void 0:e}function L(){this._trace=new se(this._peekContext())}function U(e,t){if(u(e)){var n=this._trace;if(void 0!==n&&t&&(n=n._parent),void 0!==n)n.attachExtraTrace(e);else if(!e.__stackCleaned__){var r=Z(e);a.notEnumerableProp(e,"stack",r.message+"\n"+r.stack.join("\n")),a.notEnumerableProp(e,"__stackCleaned__",!0)}}}function q(){this._trace=void 0}function z(e,t,n,r,i){if(void 0===e&&null!==t&&k){if(void 0!==i&&i._returnedNonUndefined())return;if(0==(65535&r._bitField))return;n&&(n+=" ");var o="",s="";if(t._trace){for(var a=t._trace.stack.split("\n"),l=G(a),u=l.length-1;u>=0;--u){var c=l[u];if(!p.test(c)){var h=c.match(d);h&&(o="at "+h[1]+":"+h[2]+":"+h[3]+" ");break}}if(l.length>0)for(var f=l[0],u=0;u<a.length;++u)if(a[u]===f){u>0&&(s="\n"+a[u-1]);break}}var m="a promise was created in a "+n+"handler "+o+"but was not returned from it, see http://goo.gl/rRqMUw"+s;r._warn(m,!0,t)}}function K(e,t){var n=e+" is deprecated and will be removed in a future version.";return t&&(n+=" Use "+t+" instead."),H(n)}function H(e,t,r){if(le.warnings){var i=new s(e),o;if(t)r._attachExtraTrace(i);else if(le.longStackTraces&&(o=n._peekContext()))o.attachExtraTrace(i);else{var a=Z(i);i.stack=a.message+"\n"+a.stack.join("\n")}T("warning",i)||J(i,"",!0)}}function V(e,t){for(var n=0;n<t.length-1;++n)t[n].push("From previous event:"),t[n]=t[n].join("\n");return n<t.length&&(t[n]=t[n].join("\n")),e+"\n"+t.join("\n")}function $(e){for(var t=0;t<e.length;++t)(0===e[t].length||t+1<e.length&&e[t][0]===e[t+1][0])&&(e.splice(t,1),t--)}function W(e){for(var t=e[0],n=1;n<e.length;++n){for(var r=e[n],i=t.length-1,o=t[i],s=-1,a=r.length-1;a>=0;--a)if(r[a]===o){s=a;break}for(var a=s;a>=0;--a){var l=r[a];if(t[i]!==l)break;t.pop(),i--}t=r}}function G(e){for(var t=[],n=0;n<e.length;++n){var r=e[n],i=" (No stack trace)"===r||m.test(r),o=i&&ne(r);i&&!o&&(y&&" "!==r.charAt(0)&&(r=" "+r),t.push(r))}return t}function Y(e){for(var t=e.stack.replace(/\s+$/g,"").split("\n"),n=0;n<t.length;++n){var r=t[n];if(" (No stack trace)"===r||m.test(r))break}return n>0&&"SyntaxError"!=e.name&&(t=t.slice(n)),t}function Z(e){var t=e.stack,n=e.toString();return t="string"==typeof t&&t.length>0?Y(e):[" (No stack trace)"],{message:n,stack:"SyntaxError"==e.name?t:G(t)}}function J(e,t,n){if("undefined"!=typeof console){var r;if(a.isObject(e)){var i=e.stack;r=t+g(i,e)}else r=t+String(e);"function"==typeof v?v(r,n):"function"!=typeof console.log&&"object"!=typeof console.log||console.log(r)}}function Q(e,t,n,r){var i=!1;try{"function"==typeof t&&(i=!0,"rejectionHandled"===e?t(r):t(n,r))}catch(e){o.throwLater(e)}"unhandledRejection"===e?T(e,n,r)||i||J(n,"Unhandled rejection "):T(e,r)}function X(e){var t;if("function"==typeof e)t="[function "+(e.name||"anonymous")+"]";else{t=e&&"function"==typeof e.toString?e.toString():a.toString(e);var n=/\[object [a-zA-Z0-9$_]+\]/;if(n.test(t))try{var r=JSON.stringify(e);t=r}catch(e){}0===t.length&&(t="(empty array)")}return"(<"+ee(t)+">, no stack trace)"}function ee(e){var t=41;return e.length<41?e:e.substr(0,38)+"..."}function te(){return"function"==typeof ae}var ne=function(){return!1},re=/[\/<\(]([^:\/]+):(\d+):(?:\d+)\)?\s*$/;function ie(e){var t=e.match(re);if(t)return{fileName:t[1],line:parseInt(t[2],10)}}function oe(e,t){if(te()){for(var n=(e.stack||"").split("\n"),r=(t.stack||"").split("\n"),i=-1,o=-1,s,a,l=0;l<n.length;++l){var u=ie(n[l]);if(u){s=u.fileName,i=u.line;break}}for(var l=0;l<r.length;++l){var u=ie(r[l]);if(u){a=u.fileName,o=u.line;break}}i<0||o<0||!s||!a||s!==a||i>=o||(ne=function(e){if(f.test(e))return!0;var t=ie(e);return!!(t&&t.fileName===s&&i<=t.line&&t.line<=o)})}}function se(e){this._parent=e,this._promisesCreated=0;var t=this._length=1+(void 0===e?0:e._length);ae(this,se),t>32&&this.uncycle()}a.inherits(se,Error),r.CapturedTrace=se,se.prototype.uncycle=function(){var e=this._length;if(!(e<2)){for(var t=[],n={},r=0,i=this;void 0!==i;++r)t.push(i),i=i._parent;e=this._length=r;for(var r=e-1;r>=0;--r){var o=t[r].stack;void 0===n[o]&&(n[o]=r)}for(var r=0;r<e;++r){var s=t[r].stack,a=n[s];if(void 0!==a&&a!==r){a>0&&(t[a-1]._parent=void 0,t[a-1]._length=1),t[r]._parent=void 0,t[r]._length=1;var l=r>0?t[r-1]:this;a<e-1?(l._parent=t[a+1],l._parent.uncycle(),l._length=l._parent._length+1):(l._parent=void 0,l._length=1);for(var u=l._length+1,c=r-2;c>=0;--c)t[c]._length=u,u++;return}}}},se.prototype.attachExtraTrace=function(e){if(!e.__stackCleaned__){this.uncycle();for(var t=Z(e),n=t.message,r=[t.stack],i=this;void 0!==i;)r.push(G(i.stack.split("\n"))),i=i._parent;W(r),$(r),a.notEnumerableProp(e,"stack",V(n,r)),a.notEnumerableProp(e,"__stackCleaned__",!0)}};var ae=function e(){var t=/^\s*at\s*/,n=function(e,t){return"string"==typeof e?e:void 0!==t.name&&void 0!==t.message?t.toString():X(t)};if("number"==typeof Error.stackTraceLimit&&"function"==typeof Error.captureStackTrace){Error.stackTraceLimit+=6,m=t,g=n;var r=Error.captureStackTrace;return ne=function(e){return f.test(e)},function(e,t){Error.stackTraceLimit+=6,r(e,t),Error.stackTraceLimit-=6}}var i=new Error,o;if("string"==typeof i.stack&&i.stack.split("\n")[0].indexOf("stackDetection@")>=0)return m=/@/,g=n,y=!0,function e(t){t.stack=(new Error).stack};try{throw new Error}catch(e){o="stack"in e}return"stack"in i||!o||"number"!=typeof Error.stackTraceLimit?(g=function(e,t){return"string"==typeof e?e:"object"!=typeof t&&"function"!=typeof t||void 0===t.name||void 0===t.message?X(t):t.toString()},null):(m=t,g=n,function e(t){Error.stackTraceLimit+=6;try{throw new Error}catch(e){t.stack=e.stack}Error.stackTraceLimit-=6})}([]);"undefined"!=typeof console&&void 0!==console.warn&&(v=function(e){console.warn(e)},a.isNode&&t.stderr.isTTY?v=function(e,t){var n=t?"":"";console.warn(n+e+"\n")}:a.isNode||"string"!=typeof(new Error).stack||(v=function(e,t){console.warn("%c"+e,t?"color: darkorange":"color: red")}));var le={warnings:_,longStackTraces:!1,cancellation:!1,monitoring:!1};return w&&n.longStackTraces(),{longStackTraces:function(){return le.longStackTraces},warnings:function(){return le.warnings},cancellation:function(){return le.cancellation},monitoring:function(){return le.monitoring},propagateFromFunction:function(){return M},boundValueFunction:function(){return F},checkForgottenReturns:z,setBounds:oe,warn:H,deprecated:K,CapturedTrace:se,fireDomEvent:S,fireGlobalEvent:x}}},{"./errors":12,"./es5":13,"./util":36}],10:[function(e,t,n){"use strict";t.exports=function(e){function t(){return this.value}function n(){throw this.reason}e.prototype.return=e.prototype.thenReturn=function(n){return n instanceof e&&n.suppressUnhandledRejections(),this._then(t,void 0,void 0,{value:n},void 0)},e.prototype.throw=e.prototype.thenThrow=function(e){return this._then(n,void 0,void 0,{reason:e},void 0)},e.prototype.catchThrow=function(e){if(arguments.length<=1)return this._then(void 0,n,void 0,{reason:e},void 0);var t=arguments[1],r=function(){throw t};return this.caught(e,r)},e.prototype.catchReturn=function(n){if(arguments.length<=1)return n instanceof e&&n.suppressUnhandledRejections(),this._then(void 0,t,void 0,{value:n},void 0);var r=arguments[1];r instanceof e&&r.suppressUnhandledRejections();var i=function(){return r};return this.caught(n,i)}}},{}],11:[function(e,t,n){"use strict";t.exports=function(e,t){var n=e.reduce,r=e.all;function i(){return r(this)}function o(e,r){return n(e,r,t,t)}e.prototype.each=function(e){return n(this,e,t,0)._then(i,void 0,void 0,this,void 0)},e.prototype.mapSeries=function(e){return n(this,e,t,t)},e.each=function(e,r){return n(e,r,t,0)._then(i,void 0,void 0,e,void 0)},e.mapSeries=o}},{}],12:[function(e,t,n){"use strict";var r=e("./es5"),i=r.freeze,o=e("./util"),s=o.inherits,a=o.notEnumerableProp,l,u;function c(e,t){function n(r){if(!(this instanceof n))return new n(r);a(this,"message","string"==typeof r?r:t),a(this,"name",e),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):Error.call(this)}return s(n,Error),n}var h=c("Warning","warning"),f=c("CancellationError","cancellation error"),p=c("TimeoutError","timeout error"),d=c("AggregateError","aggregate error");try{l=TypeError,u=RangeError}catch(e){l=c("TypeError","type error"),u=c("RangeError","range error")}for(var m="join pop push shift unshift slice filter forEach some every map indexOf lastIndexOf reduce reduceRight sort reverse".split(" "),g=0;g<m.length;++g)"function"==typeof Array.prototype[m[g]]&&(d.prototype[m[g]]=Array.prototype[m[g]]);r.defineProperty(d.prototype,"length",{value:0,configurable:!1,writable:!0,enumerable:!0}),d.prototype.isOperational=!0;var y=0;function v(e){if(!(this instanceof v))return new v(e);a(this,"name","OperationalError"),a(this,"message",e),this.cause=e,this.isOperational=!0,e instanceof Error?(a(this,"message",e.message),a(this,"stack",e.stack)):Error.captureStackTrace&&Error.captureStackTrace(this,this.constructor)}d.prototype.toString=function(){var e=Array(4*y+1).join(" "),t="\n"+e+"AggregateError of:\n";y++,e=Array(4*y+1).join(" ");for(var n=0;n<this.length;++n){for(var r=this[n]===this?"[Circular AggregateError]":this[n]+"",i=r.split("\n"),o=0;o<i.length;++o)i[o]=e+i[o];r=i.join("\n"),t+=r+"\n"}return y--,t},s(v,Error);var b=Error.__BluebirdErrorTypes__;b||(b=i({CancellationError:f,TimeoutError:p,OperationalError:v,RejectionError:v,AggregateError:d}),r.defineProperty(Error,"__BluebirdErrorTypes__",{value:b,writable:!1,enumerable:!1,configurable:!1})),t.exports={Error:Error,TypeError:l,RangeError:u,CancellationError:b.CancellationError,OperationalError:b.OperationalError,TimeoutError:b.TimeoutError,AggregateError:b.AggregateError,Warning:h}},{"./es5":13,"./util":36}],13:[function(e,t,n){var r=function(){"use strict";return void 0===this}();if(r)t.exports={freeze:Object.freeze,defineProperty:Object.defineProperty,getDescriptor:Object.getOwnPropertyDescriptor,keys:Object.keys,names:Object.getOwnPropertyNames,getPrototypeOf:Object.getPrototypeOf,isArray:Array.isArray,isES5:r,propertyIsWritable:function(e,t){var n=Object.getOwnPropertyDescriptor(e,t);return!(n&&!n.writable&&!n.set)}};else{var i={}.hasOwnProperty,o={}.toString,s={}.constructor.prototype,a=function(e){var t=[];for(var n in e)i.call(e,n)&&t.push(n);return t},l=function(e,t){return{value:e[t]}},u=function(e,t,n){return e[t]=n.value,e},c=function(e){return e},h=function(e){try{return Object(e).constructor.prototype}catch(e){return s}},f=function(e){try{return"[object Array]"===o.call(e)}catch(e){return!1}};t.exports={isArray:f,keys:a,names:a,defineProperty:u,getDescriptor:l,freeze:c,getPrototypeOf:h,isES5:r,propertyIsWritable:function(){return!0}}}},{}],14:[function(e,t,n){"use strict";t.exports=function(e,t){var n=e.map;e.prototype.filter=function(e,r){return n(this,e,r,t)},e.filter=function(e,r,i){return n(e,r,i,t)}}},{}],15:[function(e,t,n){"use strict";t.exports=function(t,n,r){var i=e("./util"),o=t.CancellationError,s=i.errorObj,a=e("./catch_filter")(r);function l(e,t,n){this.promise=e,this.type=t,this.handler=n,this.called=!1,this.cancelPromise=null}function u(e){this.finallyHandler=e}function c(e,t){return null!=e.cancelPromise&&(arguments.length>1?e.cancelPromise._reject(t):e.cancelPromise._cancel(),e.cancelPromise=null,!0)}function h(){return p.call(this,this.promise._target()._settledValue())}function f(e){if(!c(this,e))return s.e=e,s}function p(e){var i=this.promise,a=this.handler;if(!this.called){this.called=!0;var l=this.isFinallyHandler()?a.call(i._boundValue()):a.call(i._boundValue(),e);if(l===r)return l;if(void 0!==l){i._setReturnedNonUndefined();var p=n(l,i);if(p instanceof t){if(null!=this.cancelPromise){if(p._isCancelled()){var d=new o("late cancellation observer");return i._attachExtraTrace(d),s.e=d,s}p.isPending()&&p._attachCancellationCallback(new u(this))}return p._then(h,f,void 0,this,void 0)}}}return i.isRejected()?(c(this),s.e=e,s):(c(this),e)}return l.prototype.isFinallyHandler=function(){return 0===this.type},u.prototype._resultCancelled=function(){c(this.finallyHandler)},t.prototype._passThrough=function(e,t,n,r){return"function"!=typeof e?this.then():this._then(n,r,void 0,new l(this,t,e),void 0)},t.prototype.lastly=t.prototype.finally=function(e){return this._passThrough(e,0,p,p)},t.prototype.tap=function(e){return this._passThrough(e,1,p)},t.prototype.tapCatch=function(e){var n=arguments.length;if(1===n)return this._passThrough(e,1,void 0,p);var r=new Array(n-1),o=0,s;for(s=0;s<n-1;++s){var l=arguments[s];if(!i.isObject(l))return t.reject(new TypeError("tapCatch statement predicate: expecting an object but got "+i.classString(l)));r[o++]=l}r.length=o;var u=arguments[s];return this._passThrough(a(r,u,this),1,void 0,p)},l}},{"./catch_filter":7,"./util":36}],16:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){var a=e("./errors"),l=a.TypeError,u=e("./util"),c=u.errorObj,h=u.tryCatch,f=[];function p(e,n,r){for(var o=0;o<n.length;++o){r._pushContext();var s=h(n[o])(e);if(r._popContext(),s===c){r._pushContext();var a=t.reject(c.e);return r._popContext(),a}var l=i(s,r);if(l instanceof t)return l}return null}function d(e,n,i,o){if(s.cancellation()){var a=new t(r),l=this._finallyPromise=new t(r);this._promise=a.lastly(function(){return l}),a._captureStackTrace(),a._setOnCancel(this)}else{var u=this._promise=new t(r);u._captureStackTrace()}this._stack=o,this._generatorFunction=e,this._receiver=n,this._generator=void 0,this._yieldHandlers="function"==typeof i?[i].concat(f):f,this._yieldedPromise=null,this._cancellationPhase=!1}u.inherits(d,o),d.prototype._isResolved=function(){return null===this._promise},d.prototype._cleanup=function(){this._promise=this._generator=null,s.cancellation()&&null!==this._finallyPromise&&(this._finallyPromise._fulfill(),this._finallyPromise=null)},d.prototype._promiseCancelled=function(){if(!this._isResolved()){var e=void 0!==this._generator.return,n;if(e)this._promise._pushContext(),n=h(this._generator.return).call(this._generator,void 0),this._promise._popContext();else{var r=new t.CancellationError("generator .return() sentinel");t.coroutine.returnSentinel=r,this._promise._attachExtraTrace(r),this._promise._pushContext(),n=h(this._generator.throw).call(this._generator,r),this._promise._popContext()}this._cancellationPhase=!0,this._yieldedPromise=null,this._continue(n)}},d.prototype._promiseFulfilled=function(e){this._yieldedPromise=null,this._promise._pushContext();var t=h(this._generator.next).call(this._generator,e);this._promise._popContext(),this._continue(t)},d.prototype._promiseRejected=function(e){this._yieldedPromise=null,this._promise._attachExtraTrace(e),this._promise._pushContext();var t=h(this._generator.throw).call(this._generator,e);this._promise._popContext(),this._continue(t)},d.prototype._resultCancelled=function(){if(this._yieldedPromise instanceof t){var e=this._yieldedPromise;this._yieldedPromise=null,e.cancel()}},d.prototype.promise=function(){return this._promise},d.prototype._run=function(){this._generator=this._generatorFunction.call(this._receiver),this._receiver=this._generatorFunction=void 0,this._promiseFulfilled(void 0)},d.prototype._continue=function(e){var n=this._promise;if(e===c)return this._cleanup(),this._cancellationPhase?n.cancel():n._rejectCallback(e.e,!1);var r=e.value;if(!0===e.done)return this._cleanup(),this._cancellationPhase?n.cancel():n._resolveCallback(r);var o=i(r,this._promise);if(o instanceof t||(o=p(o,this._yieldHandlers,this._promise),null!==o)){o=o._target();var s=o._bitField;0==(50397184&s)?(this._yieldedPromise=o,o._proxy(this,null)):0!=(33554432&s)?t._async.invoke(this._promiseFulfilled,this,o._value()):0!=(16777216&s)?t._async.invoke(this._promiseRejected,this,o._reason()):this._promiseCancelled()}else this._promiseRejected(new l("A value %s was yielded that could not be treated as a promise\n\n See http://goo.gl/MqrFmX\n\n".replace("%s",String(r))+"From coroutine:\n"+this._stack.split("\n").slice(1,-7).join("\n")))},t.coroutine=function(e,t){if("function"!=typeof e)throw new l("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n");var n=Object(t).yieldHandler,r=d,i=(new Error).stack;return function(){var t=e.apply(this,arguments),o=new r(void 0,void 0,n,i),s=o.promise();return o._generator=t,o._promiseFulfilled(void 0),s}},t.coroutine.addYieldHandler=function(e){if("function"!=typeof e)throw new l("expecting a function but got "+u.classString(e));f.push(e)},t.spawn=function(e){if(s.deprecated("Promise.spawn()","Promise.coroutine()"),"function"!=typeof e)return n("generatorFunction must be a function\n\n See http://goo.gl/MqrFmX\n");var r=new d(e,this),i=r.promise();return r._run(t.spawn),i}}},{"./errors":12,"./util":36}],17:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){var a=e("./util"),l=a.canEvaluate,u=a.tryCatch,c=a.errorObj,h,f,p,d,m,g,y,v;t.join=function(){var e=arguments.length-1,t,r,i,o,s,a,l,u,c;e>0&&"function"==typeof arguments[e]&&(t=arguments[e]);var h=[].slice.call(arguments);t&&h.pop();var c=new n(h).promise();return void 0!==t?c.spread(t):c}}},{"./util":36}],18:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){var a=t._getDomain,l=e("./util"),u=l.tryCatch,c=l.errorObj,h=t._async;function f(e,t,n,r){this.constructor$(e),this._promise._captureStackTrace();var i=a();this._callback=null===i?t:l.domainBind(i,t),this._preservedValues=r===o?new Array(this.length()):null,this._limit=n,this._inFlight=0,this._queue=[],h.invoke(this._asyncInit,this,void 0)}function p(e,n,i,o){if("function"!=typeof n)return r("expecting a function but got "+l.classString(n));var s=0;if(void 0!==i){if("object"!=typeof i||null===i)return t.reject(new TypeError("options argument must be an object but it is "+l.classString(i)));if("number"!=typeof i.concurrency)return t.reject(new TypeError("'concurrency' must be a number but it is "+l.classString(i.concurrency)));s=i.concurrency}return s="number"==typeof s&&isFinite(s)&&s>=1?s:0,new f(e,n,s,o).promise()}l.inherits(f,n),f.prototype._asyncInit=function(){this._init$(void 0,-2)},f.prototype._init=function(){},f.prototype._promiseFulfilled=function(e,n){var r=this._values,o=this.length(),a=this._preservedValues,l=this._limit;if(n<0){if(n=-1*n-1,r[n]=e,l>=1&&(this._inFlight--,this._drainQueue(),this._isResolved()))return!0}else{if(l>=1&&this._inFlight>=l)return r[n]=e,this._queue.push(n),!1;null!==a&&(a[n]=e);var h=this._promise,f=this._callback,p=h._boundValue();h._pushContext();var d=u(f).call(p,e,n,o),m=h._popContext();if(s.checkForgottenReturns(d,m,null!==a?"Promise.filter":"Promise.map",h),d===c)return this._reject(d.e),!0;var g=i(d,this._promise);if(g instanceof t){g=g._target();var y=g._bitField;if(0==(50397184&y))return l>=1&&this._inFlight++,r[n]=g,g._proxy(this,-1*(n+1)),!1;if(0==(33554432&y))return 0!=(16777216&y)?(this._reject(g._reason()),!0):(this._cancel(),!0);d=g._value()}r[n]=d}var v=++this._totalResolved;return v>=o&&(null!==a?this._filter(r,a):this._resolve(r),!0)},f.prototype._drainQueue=function(){for(var e=this._queue,t=this._limit,n=this._values;e.length>0&&this._inFlight<t;){if(this._isResolved())return;var r=e.pop();this._promiseFulfilled(n[r],r)}},f.prototype._filter=function(e,t){for(var n=t.length,r=new Array(n),i=0,o=0;o<n;++o)e[o]&&(r[i++]=t[o]);r.length=i,this._resolve(r)},f.prototype.preservedValues=function(){return this._preservedValues},t.prototype.map=function(e,t){return p(this,e,t,null)},t.map=function(e,t,n,r){return p(e,t,n,r)}}},{"./util":36}],19:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o){var s=e("./util"),a=s.tryCatch;t.method=function(e){if("function"!=typeof e)throw new t.TypeError("expecting a function but got "+s.classString(e));return function(){var r=new t(n);r._captureStackTrace(),r._pushContext();var i=a(e).apply(this,arguments),s=r._popContext();return o.checkForgottenReturns(i,s,"Promise.method",r),r._resolveFromSyncValue(i),r}},t.attempt=t.try=function(e){if("function"!=typeof e)return i("expecting a function but got "+s.classString(e));var r=new t(n),l;if(r._captureStackTrace(),r._pushContext(),arguments.length>1){o.deprecated("calling Promise.try with more than 1 argument");var u=arguments[1],c=arguments[2];l=s.isArray(u)?a(e).apply(c,u):a(e).call(c,u)}else l=a(e)();var h=r._popContext();return o.checkForgottenReturns(l,h,"Promise.try",r),r._resolveFromSyncValue(l),r},t.prototype._resolveFromSyncValue=function(e){e===s.errorObj?this._rejectCallback(e.e,!1):this._resolveCallback(e,!0)}}},{"./util":36}],20:[function(e,t,n){"use strict";var r=e("./util"),i=r.maybeWrapAsError,o=e("./errors"),s=o.OperationalError,a=e("./es5");function l(e){return e instanceof Error&&a.getPrototypeOf(e)===Error.prototype}var u=/^(?:name|message|stack|cause)$/;function c(e){var t;if(l(e)){t=new s(e),t.name=e.name,t.message=e.message,t.stack=e.stack;for(var n=a.keys(e),i=0;i<n.length;++i){var o=n[i];u.test(o)||(t[o]=e[o])}return t}return r.markAsOriginatingFromRejection(e),e}function h(e,t){return function(n,r){if(null!==e){if(n){var o=c(i(n));e._attachExtraTrace(o),e._reject(o)}else if(t){var s=[].slice.call(arguments,1);e._fulfill(s)}else e._fulfill(r);e=null}}}t.exports=h},{"./errors":12,"./es5":13,"./util":36}],21:[function(e,t,n){"use strict";t.exports=function(t){var n=e("./util"),r=t._async,i=n.tryCatch,o=n.errorObj;function s(e,t){var s=this;if(!n.isArray(e))return a.call(this,e,t);var l=i(t).apply(this._boundValue(),[null].concat(e));l===o&&r.throwLater(l.e)}function a(e,t){var n=this,s=this._boundValue(),a=void 0===e?i(t).call(s,null):i(t).call(s,null,e);a===o&&r.throwLater(a.e)}function l(e,t){var n=this;if(!e){var s=new Error(e+"");s.cause=e,e=s}var a=i(t).call(this._boundValue(),e);a===o&&r.throwLater(a.e)}t.prototype.asCallback=t.prototype.nodeify=function(e,t){if("function"==typeof e){var n=a;void 0!==t&&Object(t).spread&&(n=s),this._then(n,l,void 0,this,e)}return this}}},{"./util":36}],22:[function(e,n,r){"use strict";n.exports=function(){var r=function(){return new d("circular promise resolution chain\n\n See http://goo.gl/MqrFmX\n")},i=function(){return new R.PromiseInspection(this._target())},o=function(e){return R.reject(new d(e))};function s(){}var a={},l=e("./util"),u;u=l.isNode?function(){var e=t.domain;return void 0===e&&(e=null),e}:function(){return null},l.notEnumerableProp(R,"_getDomain",u);var c=e("./es5"),h=e("./async"),f=new h;c.defineProperty(R,"_async",{value:f});var p=e("./errors"),d=R.TypeError=p.TypeError;R.RangeError=p.RangeError;var m=R.CancellationError=p.CancellationError;R.TimeoutError=p.TimeoutError,R.OperationalError=p.OperationalError,R.RejectionError=p.OperationalError,R.AggregateError=p.AggregateError;var g=function(){},y={},v={},b=e("./thenables")(R,g),_=e("./promise_array")(R,g,b,o,s),w=e("./context")(R),k=w.create,E=e("./debuggability")(R,w),S=E.CapturedTrace,x=e("./finally")(R,b,v),C=e("./catch_filter")(v),A=e("./nodeback"),T=l.errorObj,I=l.tryCatch;function j(e,t){if(null==e||e.constructor!==R)throw new d("the promise constructor cannot be invoked directly\n\n See http://goo.gl/MqrFmX\n");if("function"!=typeof t)throw new d("expecting a function but got "+l.classString(t))}function R(e){e!==g&&j(this,e),this._bitField=0,this._fulfillmentHandler0=void 0,this._rejectionHandler0=void 0,this._promise0=void 0,this._receiver0=void 0,this._resolveFromExecutor(e),this._promiseCreated(),this._fireEvent("promiseCreated",this)}function B(e){this.promise._resolveCallback(e)}function O(e){this.promise._rejectCallback(e,!1)}function P(e){var t=new R(g);t._fulfillmentHandler0=e,t._rejectionHandler0=e,t._promise0=e,t._receiver0=e}return R.prototype.toString=function(){return"[object Promise]"},R.prototype.caught=R.prototype.catch=function(e){var t=arguments.length;if(t>1){var n=new Array(t-1),r=0,i;for(i=0;i<t-1;++i){var s=arguments[i];if(!l.isObject(s))return o("Catch statement predicate: expecting an object but got "+l.classString(s));n[r++]=s}if(n.length=r,e=arguments[i],"function"!=typeof e)throw new d("The last argument to .catch() must be a function, got "+l.toString(e));return this.then(void 0,C(n,e,this))}return this.then(void 0,e)},R.prototype.reflect=function(){return this._then(i,i,void 0,this,void 0)},R.prototype.then=function(e,t){if(E.warnings()&&arguments.length>0&&"function"!=typeof e&&"function"!=typeof t){var n=".then() only accepts functions but was passed: "+l.classString(e);arguments.length>1&&(n+=", "+l.classString(t)),this._warn(n)}return this._then(e,t,void 0,void 0,void 0)},R.prototype.done=function(e,t){var n=this._then(e,t,void 0,void 0,void 0);n._setIsFinal()},R.prototype.spread=function(e){return"function"!=typeof e?o("expecting a function but got "+l.classString(e)):this.all()._then(e,void 0,void 0,y,void 0)},R.prototype.toJSON=function(){var e={isFulfilled:!1,isRejected:!1,fulfillmentValue:void 0,rejectionReason:void 0};return this.isFulfilled()?(e.fulfillmentValue=this.value(),e.isFulfilled=!0):this.isRejected()&&(e.rejectionReason=this.reason(),e.isRejected=!0),e},R.prototype.all=function(){return arguments.length>0&&this._warn(".all() was passed arguments but it does not take any"),new _(this).promise()},R.prototype.error=function(e){return this.caught(l.originatesFromRejection,e)},R.getNewLibraryCopy=n.exports,R.is=function(e){return e instanceof R},R.fromNode=R.fromCallback=function(e){var t=new R(g);t._captureStackTrace();var n=arguments.length>1&&!!Object(arguments[1]).multiArgs,r=I(e)(A(t,n));return r===T&&t._rejectCallback(r.e,!0),t._isFateSealed()||t._setAsyncGuaranteed(),t},R.all=function(e){return new _(e).promise()},R.cast=function(e){var t=b(e);return t instanceof R||(t=new R(g),t._captureStackTrace(),t._setFulfilled(),t._rejectionHandler0=e),t},R.resolve=R.fulfilled=R.cast,R.reject=R.rejected=function(e){var t=new R(g);return t._captureStackTrace(),t._rejectCallback(e,!0),t},R.setScheduler=function(e){if("function"!=typeof e)throw new d("expecting a function but got "+l.classString(e));return f.setScheduler(e)},R.prototype._then=function(e,t,n,r,i){var o=void 0!==i,s=o?i:new R(g),a=this._target(),c=a._bitField;o||(s._propagateFrom(this,3),s._captureStackTrace(),void 0===r&&0!=(2097152&this._bitField)&&(r=0!=(50397184&c)?this._boundValue():a===this?void 0:this._boundTo),this._fireEvent("promiseChained",this,s));var h=u();if(0!=(50397184&c)){var p,d,y=a._settlePromiseCtx;0!=(33554432&c)?(d=a._rejectionHandler0,p=e):0!=(16777216&c)?(d=a._fulfillmentHandler0,p=t,a._unsetRejectionIsUnhandled()):(y=a._settlePromiseLateCancellationObserver,d=new m("late cancellation observer"),a._attachExtraTrace(d),p=t),f.invoke(y,a,{handler:null===h?p:"function"==typeof p&&l.domainBind(h,p),promise:s,receiver:r,value:d})}else a._addCallbacks(e,t,s,r,h);return s},R.prototype._length=function(){return 65535&this._bitField},R.prototype._isFateSealed=function(){return 0!=(117506048&this._bitField)},R.prototype._isFollowing=function(){return 67108864==(67108864&this._bitField)},R.prototype._setLength=function(e){this._bitField=-65536&this._bitField|65535&e},R.prototype._setFulfilled=function(){this._bitField=33554432|this._bitField,this._fireEvent("promiseFulfilled",this)},R.prototype._setRejected=function(){this._bitField=16777216|this._bitField,this._fireEvent("promiseRejected",this)},R.prototype._setFollowing=function(){this._bitField=67108864|this._bitField,this._fireEvent("promiseResolved",this)},R.prototype._setIsFinal=function(){this._bitField=4194304|this._bitField},R.prototype._isFinal=function(){return(4194304&this._bitField)>0},R.prototype._unsetCancelled=function(){this._bitField=-65537&this._bitField},R.prototype._setCancelled=function(){this._bitField=65536|this._bitField,this._fireEvent("promiseCancelled",this)},R.prototype._setWillBeCancelled=function(){this._bitField=8388608|this._bitField},R.prototype._setAsyncGuaranteed=function(){f.hasCustomScheduler()||(this._bitField=134217728|this._bitField)},R.prototype._receiverAt=function(e){var t=0===e?this._receiver0:this[4*e-4+3];if(t!==a)return void 0===t&&this._isBound()?this._boundValue():t},R.prototype._promiseAt=function(e){return this[4*e-4+2]},R.prototype._fulfillmentHandlerAt=function(e){return this[4*e-4+0]},R.prototype._rejectionHandlerAt=function(e){return this[4*e-4+1]},R.prototype._boundValue=function(){},R.prototype._migrateCallback0=function(e){var t=e._bitField,n=e._fulfillmentHandler0,r=e._rejectionHandler0,i=e._promise0,o=e._receiverAt(0);void 0===o&&(o=a),this._addCallbacks(n,r,i,o,null)},R.prototype._migrateCallbackAt=function(e,t){var n=e._fulfillmentHandlerAt(t),r=e._rejectionHandlerAt(t),i=e._promiseAt(t),o=e._receiverAt(t);void 0===o&&(o=a),this._addCallbacks(n,r,i,o,null)},R.prototype._addCallbacks=function(e,t,n,r,i){var o=this._length();if(o>=65531&&(o=0,this._setLength(0)),0===o)this._promise0=n,this._receiver0=r,"function"==typeof e&&(this._fulfillmentHandler0=null===i?e:l.domainBind(i,e)),"function"==typeof t&&(this._rejectionHandler0=null===i?t:l.domainBind(i,t));else{var s=4*o-4;this[s+2]=n,this[s+3]=r,"function"==typeof e&&(this[s+0]=null===i?e:l.domainBind(i,e)),"function"==typeof t&&(this[s+1]=null===i?t:l.domainBind(i,t))}return this._setLength(o+1),o},R.prototype._proxy=function(e,t){this._addCallbacks(void 0,void 0,t,e,null)},R.prototype._resolveCallback=function(e,t){if(0==(117506048&this._bitField)){if(e===this)return this._rejectCallback(r(),!1);var n=b(e,this);if(!(n instanceof R))return this._fulfill(e);t&&this._propagateFrom(n,2);var i=n._target();if(i!==this){var o=i._bitField;if(0==(50397184&o)){var s=this._length();s>0&&i._migrateCallback0(this);for(var a=1;a<s;++a)i._migrateCallbackAt(this,a);this._setFollowing(),this._setLength(0),this._setFollowee(i)}else if(0!=(33554432&o))this._fulfill(i._value());else if(0!=(16777216&o))this._reject(i._reason());else{var l=new m("late cancellation observer");i._attachExtraTrace(l),this._reject(l)}}else this._reject(r())}},R.prototype._rejectCallback=function(e,t,n){var r=l.ensureErrorObject(e),i=r===e;if(!i&&!n&&E.warnings()){var o="a promise was rejected with a non-error: "+l.classString(e);this._warn(o,!0)}this._attachExtraTrace(r,!!t&&i),this._reject(e)},R.prototype._resolveFromExecutor=function(e){if(e!==g){var t=this;this._captureStackTrace(),this._pushContext();var n=!0,r=this._execute(e,function(e){t._resolveCallback(e)},function(e){t._rejectCallback(e,n)});n=!1,this._popContext(),void 0!==r&&t._rejectCallback(r,!0)}},R.prototype._settlePromiseFromHandler=function(e,t,n,r){var i=r._bitField;if(0==(65536&i)){var o;r._pushContext(),t===y?n&&"number"==typeof n.length?o=I(e).apply(this._boundValue(),n):(o=T,o.e=new d("cannot .spread() a non-array: "+l.classString(n))):o=I(e).call(t,n);var s=r._popContext();i=r._bitField,0==(65536&i)&&(o===v?r._reject(n):o===T?r._rejectCallback(o.e,!1):(E.checkForgottenReturns(o,s,"",r,this),r._resolveCallback(o)))}},R.prototype._target=function(){for(var e=this;e._isFollowing();)e=e._followee();return e},R.prototype._followee=function(){return this._rejectionHandler0},R.prototype._setFollowee=function(e){this._rejectionHandler0=e},R.prototype._settlePromise=function(e,t,n,r){var o=e instanceof R,a=this._bitField,l=0!=(134217728&a);0!=(65536&a)?(o&&e._invokeInternalOnCancel(),n instanceof x&&n.isFinallyHandler()?(n.cancelPromise=e,I(t).call(n,r)===T&&e._reject(T.e)):t===i?e._fulfill(i.call(n)):n instanceof s?n._promiseCancelled(e):o||e instanceof _?e._cancel():n.cancel()):"function"==typeof t?o?(l&&e._setAsyncGuaranteed(),this._settlePromiseFromHandler(t,n,r,e)):t.call(n,r,e):n instanceof s?n._isResolved()||(0!=(33554432&a)?n._promiseFulfilled(r,e):n._promiseRejected(r,e)):o&&(l&&e._setAsyncGuaranteed(),0!=(33554432&a)?e._fulfill(r):e._reject(r))},R.prototype._settlePromiseLateCancellationObserver=function(e){var t=e.handler,n=e.promise,r=e.receiver,i=e.value;"function"==typeof t?n instanceof R?this._settlePromiseFromHandler(t,r,i,n):t.call(r,i,n):n instanceof R&&n._reject(i)},R.prototype._settlePromiseCtx=function(e){this._settlePromise(e.promise,e.handler,e.receiver,e.value)},R.prototype._settlePromise0=function(e,t,n){var r=this._promise0,i=this._receiverAt(0);this._promise0=void 0,this._receiver0=void 0,this._settlePromise(r,e,i,t)},R.prototype._clearCallbackDataAtIndex=function(e){var t=4*e-4;this[t+2]=this[t+3]=this[t+0]=this[t+1]=void 0},R.prototype._fulfill=function(e){var t=this._bitField;if(!((117506048&t)>>>16)){if(e===this){var n=r();return this._attachExtraTrace(n),this._reject(n)}this._setFulfilled(),this._rejectionHandler0=e,(65535&t)>0&&(0!=(134217728&t)?this._settlePromises():f.settlePromises(this),this._dereferenceTrace())}},R.prototype._reject=function(e){var t=this._bitField;if(!((117506048&t)>>>16)){if(this._setRejected(),this._fulfillmentHandler0=e,this._isFinal())return f.fatalError(e,l.isNode);(65535&t)>0?f.settlePromises(this):this._ensurePossibleRejectionHandled()}},R.prototype._fulfillPromises=function(e,t){for(var n=1;n<e;n++){var r=this._fulfillmentHandlerAt(n),i=this._promiseAt(n),o=this._receiverAt(n);this._clearCallbackDataAtIndex(n),this._settlePromise(i,r,o,t)}},R.prototype._rejectPromises=function(e,t){for(var n=1;n<e;n++){var r=this._rejectionHandlerAt(n),i=this._promiseAt(n),o=this._receiverAt(n);this._clearCallbackDataAtIndex(n),this._settlePromise(i,r,o,t)}},R.prototype._settlePromises=function(){var e=this._bitField,t=65535&e;if(t>0){if(0!=(16842752&e)){var n=this._fulfillmentHandler0;this._settlePromise0(this._rejectionHandler0,n,e),this._rejectPromises(t,n)}else{var r=this._rejectionHandler0;this._settlePromise0(this._fulfillmentHandler0,r,e),this._fulfillPromises(t,r)}this._setLength(0)}this._clearCancellationData()},R.prototype._settledValue=function(){var e=this._bitField;return 0!=(33554432&e)?this._rejectionHandler0:0!=(16777216&e)?this._fulfillmentHandler0:void 0},"undefined"!=typeof Symbol&&Symbol.toStringTag&&c.defineProperty(R.prototype,Symbol.toStringTag,{get:function(){return"Object"}}),R.defer=R.pending=function(){E.deprecated("Promise.defer","new Promise");var e=new R(g);return{promise:e,resolve:B,reject:O}},l.notEnumerableProp(R,"_makeSelfResolutionError",r),e("./method")(R,g,b,o,E),e("./bind")(R,g,b,E),e("./cancel")(R,_,o,E),e("./direct_resolve")(R),e("./synchronous_inspection")(R),e("./join")(R,_,b,g,f,u),R.Promise=R,R.version="3.5.5",e("./call_get.js")(R),e("./generators.js")(R,o,g,b,s,E),e("./map.js")(R,_,o,b,g,E),e("./nodeify.js")(R),e("./promisify.js")(R,g),e("./props.js")(R,_,b,o),e("./race.js")(R,g,b,o),e("./reduce.js")(R,_,o,b,g,E),e("./settle.js")(R,_,E),e("./some.js")(R,_,o),e("./timers.js")(R,g,E),e("./using.js")(R,o,b,k,g,E),e("./any.js")(R),e("./each.js")(R,g),e("./filter.js")(R,g),l.toFastProperties(R),l.toFastProperties(R.prototype),P({a:1}),P({b:2}),P({c:3}),P(1),P(function(){}),P(void 0),P(!1),P(new R(g)),E.setBounds(h.firstLineError,l.lastLineError),R}},{"./any.js":1,"./async":2,"./bind":3,"./call_get.js":5,"./cancel":6,"./catch_filter":7,"./context":8,"./debuggability":9,"./direct_resolve":10,"./each.js":11,"./errors":12,"./es5":13,"./filter.js":14,"./finally":15,"./generators.js":16,"./join":17,"./map.js":18,"./method":19,"./nodeback":20,"./nodeify.js":21,"./promise_array":23,"./promisify.js":24,"./props.js":25,"./race.js":27,"./reduce.js":28,"./settle.js":30,"./some.js":31,"./synchronous_inspection":32,"./thenables":33,"./timers.js":34,"./using.js":35,"./util":36}],23:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o){var s=e("./util"),a=s.isArray;function l(e){switch(e){case-2:return[];case-3:return{};case-6:return new Map}}function u(e){var r=this._promise=new t(n);e instanceof t&&r._propagateFrom(e,3),r._setOnCancel(this),this._values=e,this._length=0,this._totalResolved=0,this._init(void 0,-2)}return s.inherits(u,o),u.prototype.length=function(){return this._length},u.prototype.promise=function(){return this._promise},u.prototype._init=function e(n,o){var a=r(this._values,this._promise);if(a instanceof t){a=a._target();var u=a._bitField;if(this._values=a,0==(50397184&u))return this._promise._setAsyncGuaranteed(),a._then(e,this._reject,void 0,this,o);if(0==(33554432&u))return 0!=(16777216&u)?this._reject(a._reason()):this._cancel();a=a._value()}if(a=s.asArray(a),null!==a)0!==a.length?this._iterate(a):-5===o?this._resolveEmptyArray():this._resolve(l(o));else{var c=i("expecting an array or an iterable object but got "+s.classString(a)).reason();this._promise._rejectCallback(c,!1)}},u.prototype._iterate=function(e){var n=this.getActualLength(e.length);this._length=n,this._values=this.shouldCopyValues()?new Array(n):this._values;for(var i=this._promise,o=!1,s=null,a=0;a<n;++a){var l=r(e[a],i);l instanceof t?(l=l._target(),s=l._bitField):s=null,o?null!==s&&l.suppressUnhandledRejections():null!==s?0==(50397184&s)?(l._proxy(this,a),this._values[a]=l):o=0!=(33554432&s)?this._promiseFulfilled(l._value(),a):0!=(16777216&s)?this._promiseRejected(l._reason(),a):this._promiseCancelled(a):o=this._promiseFulfilled(l,a)}o||i._setAsyncGuaranteed()},u.prototype._isResolved=function(){return null===this._values},u.prototype._resolve=function(e){this._values=null,this._promise._fulfill(e)},u.prototype._cancel=function(){!this._isResolved()&&this._promise._isCancellable()&&(this._values=null,this._promise._cancel())},u.prototype._reject=function(e){this._values=null,this._promise._rejectCallback(e,!1)},u.prototype._promiseFulfilled=function(e,t){this._values[t]=e;var n=++this._totalResolved;return n>=this._length&&(this._resolve(this._values),!0)},u.prototype._promiseCancelled=function(){return this._cancel(),!0},u.prototype._promiseRejected=function(e){return this._totalResolved++,this._reject(e),!0},u.prototype._resultCancelled=function(){if(!this._isResolved()){var e=this._values;if(this._cancel(),e instanceof t)e.cancel();else for(var n=0;n<e.length;++n)e[n]instanceof t&&e[n].cancel()}},u.prototype.shouldCopyValues=function(){return!0},u.prototype.getActualLength=function(e){return e},u}},{"./util":36}],24:[function(e,t,n){"use strict";t.exports=function(t,n){var r={},i=e("./util"),o=e("./nodeback"),s=i.withAppended,a=i.maybeWrapAsError,l=i.canEvaluate,u=e("./errors").TypeError,c="Async",h={__isPromisified__:!0},f=["arity","length","name","arguments","caller","callee","prototype","__isPromisified__"],p=new RegExp("^(?:"+f.join("|")+")$"),d=function(e){return i.isIdentifier(e)&&"_"!==e.charAt(0)&&"constructor"!==e};function m(e){return!p.test(e)}function g(e){try{return!0===e.__isPromisified__}catch(e){return!1}}function y(e,t,n){var r=i.getDataPropertyOrDefault(e,t+n,h);return!!r&&g(r)}function v(e,t,n){for(var r=0;r<e.length;r+=2){var i=e[r];if(n.test(i))for(var o=i.replace(n,""),s=0;s<e.length;s+=2)if(e[s]===o)throw new u("Cannot promisify an API that has normal methods with '%s'-suffix\n\n See http://goo.gl/MqrFmX\n".replace("%s",t))}}function b(e,t,n,r){for(var o=i.inheritedDataKeys(e),s=[],a=0;a<o.length;++a){var l=o[a],u=e[l],c=r===d||d(l,u,e);"function"!=typeof u||g(u)||y(e,l,t)||!r(l,u,e,c)||s.push(l,u)}return v(s,t,n),s}var _=function(e){return e.replace(/([$])/,"\\$")},w,k,E,S,x;function C(e,l,u,c,h,f){var p=function(){return this}(),d=e;function m(){var i=l;l===r&&(i=this);var u=new t(n);u._captureStackTrace();var c="string"==typeof d&&this!==p?this[d]:e,h=o(u,f);try{c.apply(i,s(arguments,h))}catch(e){u._rejectCallback(a(e),!0,!0)}return u._isFateSealed()||u._setAsyncGuaranteed(),u}return"string"==typeof d&&(e=c),i.notEnumerableProp(m,"__isPromisified__",!0),m}var A=l?void 0:C;function T(e,t,n,o,s){for(var a=new RegExp(_(t)+"$"),l=b(e,t,a,n),u=0,c=l.length;u<c;u+=2){var h=l[u],f=l[u+1],p=h+t;if(o===A)e[p]=A(h,r,h,f,t,s);else{var d=o(f,function(){return A(h,r,h,f,t,s)});i.notEnumerableProp(d,"__isPromisified__",!0),e[p]=d}}return i.toFastProperties(e),e}function I(e,t,n){return A(e,t,void 0,e,null,n)}t.promisify=function(e,t){if("function"!=typeof e)throw new u("expecting a function but got "+i.classString(e));if(g(e))return e;t=Object(t);var n=void 0===t.context?r:t.context,o=!!t.multiArgs,s=I(e,n,o);return i.copyDescriptors(e,s,m),s},t.promisifyAll=function(e,t){if("function"!=typeof e&&"object"!=typeof e)throw new u("the target of promisifyAll must be an object or a function\n\n See http://goo.gl/MqrFmX\n");t=Object(t);var n=!!t.multiArgs,r=t.suffix;"string"!=typeof r&&(r="Async");var o=t.filter;"function"!=typeof o&&(o=d);var s=t.promisifier;if("function"!=typeof s&&(s=A),!i.isIdentifier(r))throw new RangeError("suffix must be a valid identifier\n\n See http://goo.gl/MqrFmX\n");for(var a=i.inheritedDataKeys(e),l=0;l<a.length;++l){var c=e[a[l]];"constructor"!==a[l]&&i.isClass(c)&&(T(c.prototype,r,o,s,n),T(c,r,o,s,n))}return T(e,r,o,s,n)}}},{"./errors":12,"./nodeback":20,"./util":36}],25:[function(e,t,n){"use strict";t.exports=function(t,n,r,i){var o=e("./util"),s=o.isObject,a=e("./es5"),l;"function"==typeof Map&&(l=Map);var u=function(){var e=0,t=0;function n(n,r){this[e]=n,this[e+t]=r,e++}return function r(i){t=i.size,e=0;var o=new Array(2*i.size);return i.forEach(n,o),o}}(),c=function(e){for(var t=new l,n=e.length/2|0,r=0;r<n;++r){var i=e[n+r],o=e[r];t.set(i,o)}return t};function h(e){var t=!1,n;if(void 0!==l&&e instanceof l)n=u(e),t=!0;else{var r=a.keys(e),i=r.length;n=new Array(2*i);for(var o=0;o<i;++o){var s=r[o];n[o]=e[s],n[o+i]=s}}this.constructor$(n),this._isMap=t,this._init$(void 0,t?-6:-3)}function f(e){var n,o=r(e);return s(o)?(n=o instanceof t?o._then(t.props,void 0,void 0,void 0,void 0):new h(o).promise(),o instanceof t&&n._propagateFrom(o,2),n):i("cannot await properties of a non-object\n\n See http://goo.gl/MqrFmX\n")}o.inherits(h,n),h.prototype._init=function(){},h.prototype._promiseFulfilled=function(e,t){this._values[t]=e;var n=++this._totalResolved;if(n>=this._length){var r;if(this._isMap)r=c(this._values);else{r={};for(var i=this.length(),o=0,s=this.length();o<s;++o)r[this._values[o+i]]=this._values[o]}return this._resolve(r),!0}return!1},h.prototype.shouldCopyValues=function(){return!1},h.prototype.getActualLength=function(e){return e>>1},t.prototype.props=function(){return f(this)},t.props=function(e){return f(e)}}},{"./es5":13,"./util":36}],26:[function(e,t,n){"use strict";function r(e,t,n,r,i){for(var o=0;o<i;++o)n[o+r]=e[o+t],e[o+t]=void 0}function i(e){this._capacity=e,this._length=0,this._front=0}i.prototype._willBeOverCapacity=function(e){return this._capacity<e},i.prototype._pushOne=function(e){var t=this.length();this._checkCapacity(t+1);var n=this._front+t&this._capacity-1;this[n]=e,this._length=t+1},i.prototype.push=function(e,t,n){var r=this.length()+3;if(this._willBeOverCapacity(r))return this._pushOne(e),this._pushOne(t),void this._pushOne(n);var i=this._front+r-3;this._checkCapacity(r);var o=this._capacity-1;this[i+0&o]=e,this[i+1&o]=t,this[i+2&o]=n,this._length=r},i.prototype.shift=function(){var e=this._front,t=this[e];return this[e]=void 0,this._front=e+1&this._capacity-1,this._length--,t},i.prototype.length=function(){return this._length},i.prototype._checkCapacity=function(e){this._capacity<e&&this._resizeTo(this._capacity<<1)},i.prototype._resizeTo=function(e){var t=this._capacity;this._capacity=e;var n=this._front,i=this._length,o=n+i&t-1;r(this,0,this,t,o)},t.exports=i},{}],27:[function(e,t,n){"use strict";t.exports=function(t,n,r,i){var o=e("./util"),s=function(e){return e.then(function(t){return a(t,e)})};function a(e,a){var l=r(e);if(l instanceof t)return s(l);if(e=o.asArray(e),null===e)return i("expecting an array or an iterable object but got "+o.classString(e));var u=new t(n);void 0!==a&&u._propagateFrom(a,3);for(var c=u._fulfill,h=u._reject,f=0,p=e.length;f<p;++f){var d=e[f];(void 0!==d||f in e)&&t.cast(d)._then(c,h,void 0,u,null)}return u}t.race=function(e){return a(e,void 0)},t.prototype.race=function(){return a(this,void 0)}}},{"./util":36}],28:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){var a=t._getDomain,l=e("./util"),u=l.tryCatch;function c(e,n,r,i){this.constructor$(e);var s=a();this._fn=null===s?n:l.domainBind(s,n),void 0!==r&&(r=t.resolve(r),r._attachCancellationCallback(this)),this._initialValue=r,this._currentCancellable=null,this._eachValues=i===o?Array(this._length):0===i?null:void 0,this._promise._captureStackTrace(),this._init$(void 0,-5)}function h(e,t){this.isFulfilled()?t._resolve(e):t._reject(e)}function f(e,t,n,i){if("function"!=typeof t)return r("expecting a function but got "+l.classString(t));var o=new c(e,t,n,i);return o.promise()}function p(e){this.accum=e,this.array._gotAccum(e);var n=i(this.value,this.array._promise);return n instanceof t?(this.array._currentCancellable=n,n._then(d,void 0,void 0,this,void 0)):d.call(this,n)}function d(e){var n=this.array,r=n._promise,i=u(n._fn),o;r._pushContext(),o=void 0!==n._eachValues?i.call(r._boundValue(),e,this.index,this.length):i.call(r._boundValue(),this.accum,e,this.index,this.length),o instanceof t&&(n._currentCancellable=o);var a=r._popContext();return s.checkForgottenReturns(o,a,void 0!==n._eachValues?"Promise.each":"Promise.reduce",r),o}l.inherits(c,n),c.prototype._gotAccum=function(e){void 0!==this._eachValues&&null!==this._eachValues&&e!==o&&this._eachValues.push(e)},c.prototype._eachComplete=function(e){return null!==this._eachValues&&this._eachValues.push(e),this._eachValues},c.prototype._init=function(){},c.prototype._resolveEmptyArray=function(){this._resolve(void 0!==this._eachValues?this._eachValues:this._initialValue)},c.prototype.shouldCopyValues=function(){return!1},c.prototype._resolve=function(e){this._promise._resolveCallback(e),this._values=null},c.prototype._resultCancelled=function(e){if(e===this._initialValue)return this._cancel();this._isResolved()||(this._resultCancelled$(),this._currentCancellable instanceof t&&this._currentCancellable.cancel(),this._initialValue instanceof t&&this._initialValue.cancel())},c.prototype._iterate=function(e){var n,r;this._values=e;var i=e.length;if(void 0!==this._initialValue?(n=this._initialValue,r=0):(n=t.resolve(e[0]),r=1),this._currentCancellable=n,!n.isRejected())for(;r<i;++r){var o={accum:null,value:e[r],index:r,length:i,array:this};n=n._then(p,void 0,void 0,o,void 0)}void 0!==this._eachValues&&(n=n._then(this._eachComplete,void 0,void 0,this,void 0)),n._then(h,h,void 0,n,this)},t.prototype.reduce=function(e,t){return f(this,e,t,null)},t.reduce=function(e,t,n,r){return f(e,t,n,r)}}},{"./util":36}],29:[function(e,r,i){"use strict";var o=e("./util"),s,a=function(){throw new Error("No async scheduler available\n\n See http://goo.gl/MqrFmX\n")},l=o.getNativePromise();if(o.isNode&&"undefined"==typeof MutationObserver){var u=n.setImmediate,c=t.nextTick;s=o.isRecentNode?function(e){u.call(n,e)}:function(e){c.call(t,e)}}else if("function"==typeof l&&"function"==typeof l.resolve){var h=l.resolve();s=function(e){h.then(e)}}else s="undefined"!=typeof MutationObserver&&("undefined"==typeof window||!window.navigator||!window.navigator.standalone&&!window.cordova)&&"classList"in document.documentElement?function(){var e=document.createElement("div"),t={attributes:!0},n=!1,r=document.createElement("div"),i=new MutationObserver(function(){e.classList.toggle("foo"),n=!1});i.observe(r,t);var o=function(){n||(n=!0,r.classList.toggle("foo"))};return function n(r){var i=new MutationObserver(function(){i.disconnect(),r()});i.observe(e,t),o()}}():"undefined"!=typeof setImmediate?function(e){setImmediate(e)}:"undefined"!=typeof setTimeout?function(e){setTimeout(e,0)}:a;r.exports=s},{"./util":36}],30:[function(e,t,n){"use strict";t.exports=function(t,n,r){var i=t.PromiseInspection,o=e("./util");function s(e){this.constructor$(e)}o.inherits(s,n),s.prototype._promiseResolved=function(e,t){this._values[e]=t;var n=++this._totalResolved;return n>=this._length&&(this._resolve(this._values),!0)},s.prototype._promiseFulfilled=function(e,t){var n=new i;return n._bitField=33554432,n._settledValueField=e,this._promiseResolved(t,n)},s.prototype._promiseRejected=function(e,t){var n=new i;return n._bitField=16777216,n._settledValueField=e,this._promiseResolved(t,n)},t.settle=function(e){return r.deprecated(".settle()",".reflect()"),new s(e).promise()},t.prototype.settle=function(){return t.settle(this)}}},{"./util":36}],31:[function(e,t,n){"use strict";t.exports=function(t,n,r){var i=e("./util"),o=e("./errors").RangeError,s=e("./errors").AggregateError,a=i.isArray,l={};function u(e){this.constructor$(e),this._howMany=0,this._unwrap=!1,this._initialized=!1}function c(e,t){if((0|t)!==t||t<0)return r("expecting a positive integer\n\n See http://goo.gl/MqrFmX\n");var n=new u(e),i=n.promise();return n.setHowMany(t),n.init(),i}i.inherits(u,n),u.prototype._init=function(){if(this._initialized)if(0!==this._howMany){this._init$(void 0,-5);var e=a(this._values);!this._isResolved()&&e&&this._howMany>this._canPossiblyFulfill()&&this._reject(this._getRangeError(this.length()))}else this._resolve([])},u.prototype.init=function(){this._initialized=!0,this._init()},u.prototype.setUnwrap=function(){this._unwrap=!0},u.prototype.howMany=function(){return this._howMany},u.prototype.setHowMany=function(e){this._howMany=e},u.prototype._promiseFulfilled=function(e){return this._addFulfilled(e),this._fulfilled()===this.howMany()&&(this._values.length=this.howMany(),1===this.howMany()&&this._unwrap?this._resolve(this._values[0]):this._resolve(this._values),!0)},u.prototype._promiseRejected=function(e){return this._addRejected(e),this._checkOutcome()},u.prototype._promiseCancelled=function(){return this._values instanceof t||null==this._values?this._cancel():(this._addRejected(l),this._checkOutcome())},u.prototype._checkOutcome=function(){if(this.howMany()>this._canPossiblyFulfill()){for(var e=new s,t=this.length();t<this._values.length;++t)this._values[t]!==l&&e.push(this._values[t]);return e.length>0?this._reject(e):this._cancel(),!0}return!1},u.prototype._fulfilled=function(){return this._totalResolved},u.prototype._rejected=function(){return this._values.length-this.length()},u.prototype._addRejected=function(e){this._values.push(e)},u.prototype._addFulfilled=function(e){this._values[this._totalResolved++]=e},u.prototype._canPossiblyFulfill=function(){return this.length()-this._rejected()},u.prototype._getRangeError=function(e){var t="Input array must contain at least "+this._howMany+" items but contains only "+e+" items";return new o(t)},u.prototype._resolveEmptyArray=function(){this._reject(this._getRangeError(0))},t.some=function(e,t){return c(e,t)},t.prototype.some=function(e){return c(this,e)},t._SomePromiseArray=u}},{"./errors":12,"./util":36}],32:[function(e,t,n){"use strict";t.exports=function(e){function t(e){void 0!==e?(e=e._target(),this._bitField=e._bitField,this._settledValueField=e._isFateSealed()?e._settledValue():void 0):(this._bitField=0,this._settledValueField=void 0)}t.prototype._settledValue=function(){return this._settledValueField};var n=t.prototype.value=function(){if(!this.isFulfilled())throw new TypeError("cannot get fulfillment value of a non-fulfilled promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},r=t.prototype.error=t.prototype.reason=function(){if(!this.isRejected())throw new TypeError("cannot get rejection reason of a non-rejected promise\n\n See http://goo.gl/MqrFmX\n");return this._settledValue()},i=t.prototype.isFulfilled=function(){return 0!=(33554432&this._bitField)},o=t.prototype.isRejected=function(){return 0!=(16777216&this._bitField)},s=t.prototype.isPending=function(){return 0==(50397184&this._bitField)},a=t.prototype.isResolved=function(){return 0!=(50331648&this._bitField)};t.prototype.isCancelled=function(){return 0!=(8454144&this._bitField)},e.prototype.__isCancelled=function(){return 65536==(65536&this._bitField)},e.prototype._isCancelled=function(){return this._target().__isCancelled()},e.prototype.isCancelled=function(){return 0!=(8454144&this._target()._bitField)},e.prototype.isPending=function(){return s.call(this._target())},e.prototype.isRejected=function(){return o.call(this._target())},e.prototype.isFulfilled=function(){return i.call(this._target())},e.prototype.isResolved=function(){return a.call(this._target())},e.prototype.value=function(){return n.call(this._target())},e.prototype.reason=function(){var e=this._target();return e._unsetRejectionIsUnhandled(),r.call(e)},e.prototype._value=function(){return this._settledValue()},e.prototype._reason=function(){return this._unsetRejectionIsUnhandled(),this._settledValue()},e.PromiseInspection=t}},{}],33:[function(e,t,n){"use strict";t.exports=function(t,n){var r=e("./util"),i=r.errorObj,o=r.isObject;function s(e,r){if(o(e)){if(e instanceof t)return e;var s=l(e);if(s===i){r&&r._pushContext();var a=t.reject(s.e);return r&&r._popContext(),a}if("function"==typeof s){if(c(e)){var a=new t(n);return e._then(a._fulfill,a._reject,void 0,a,null),a}return h(e,s,r)}}return e}function a(e){return e.then}function l(e){try{return a(e)}catch(e){return i.e=e,i}}var u={}.hasOwnProperty;function c(e){try{return u.call(e,"_promise0")}catch(e){return!1}}function h(e,o,s){var a=new t(n),l=a;s&&s._pushContext(),a._captureStackTrace(),s&&s._popContext();var u=!0,c=r.tryCatch(o).call(e,h,f);function h(e){a&&(a._resolveCallback(e),a=null)}function f(e){a&&(a._rejectCallback(e,u,!0),a=null)}return u=!1,a&&c===i&&(a._rejectCallback(c.e,!0,!0),a=null),l}return s}},{"./util":36}],34:[function(e,t,n){"use strict";t.exports=function(t,n,r){var i=e("./util"),o=t.TimeoutError;function s(e){this.handle=e}s.prototype._resultCancelled=function(){clearTimeout(this.handle)};var a=function(e){return l(+this).thenReturn(e)},l=t.delay=function(e,i){var o,l;return void 0!==i?(o=t.resolve(i)._then(a,null,null,e,void 0),r.cancellation()&&i instanceof t&&o._setOnCancel(i)):(o=new t(n),l=setTimeout(function(){o._fulfill()},+e),r.cancellation()&&o._setOnCancel(new s(l)),o._captureStackTrace()),o._setAsyncGuaranteed(),o};t.prototype.delay=function(e){return l(e,this)};var u=function(e,t,n){var r;r="string"!=typeof t?t instanceof Error?t:new o("operation timed out"):new o(t),i.markAsOriginatingFromRejection(r),e._attachExtraTrace(r),e._reject(r),null!=n&&n.cancel()};function c(e){return clearTimeout(this.handle),e}function h(e){throw clearTimeout(this.handle),e}t.prototype.timeout=function(e,t){var n,i;e=+e;var o=new s(setTimeout(function e(){n.isPending()&&u(n,t,i)},e));return r.cancellation()?(i=this.then(),n=i._then(c,h,void 0,o,void 0),n._setOnCancel(o)):n=this._then(c,h,void 0,o,void 0),n}}},{"./util":36}],35:[function(e,t,n){"use strict";t.exports=function(t,n,r,i,o,s){var a=e("./util"),l=e("./errors").TypeError,u=e("./util").inherits,c=a.errorObj,h=a.tryCatch,f={};function p(e){setTimeout(function(){throw e},0)}function d(e){var t=r(e);return t!==e&&"function"==typeof e._isDisposable&&"function"==typeof e._getDisposer&&e._isDisposable()&&t._setDisposable(e._getDisposer()),t}function m(e,n){var i=0,s=e.length,a=new t(o);function l(){if(i>=s)return a._fulfill();var o=d(e[i++]);if(o instanceof t&&o._isDisposable()){try{o=r(o._getDisposer().tryDispose(n),e.promise)}catch(e){return p(e)}if(o instanceof t)return o._then(l,p,null,null,null)}l()}return l(),a}function g(e,t,n){this._data=e,this._promise=t,this._context=n}function y(e,t,n){this.constructor$(e,t,n)}function v(e){return g.isDisposer(e)?(this.resources[this.index]._setDisposable(e),e.promise()):e}function b(e){this.length=e,this.promise=null,this[e-1]=null}g.prototype.data=function(){return this._data},g.prototype.promise=function(){return this._promise},g.prototype.resource=function(){return this.promise().isFulfilled()?this.promise().value():f},g.prototype.tryDispose=function(e){var t=this.resource(),n=this._context;void 0!==n&&n._pushContext();var r=t!==f?this.doDispose(t,e):null;return void 0!==n&&n._popContext(),this._promise._unsetDisposable(),this._data=null,r},g.isDisposer=function(e){return null!=e&&"function"==typeof e.resource&&"function"==typeof e.tryDispose},u(y,g),y.prototype.doDispose=function(e,t){var n=this.data();return n.call(e,e,t)},b.prototype._resultCancelled=function(){for(var e=this.length,n=0;n<e;++n){var r=this[n];r instanceof t&&r.cancel()}},t.using=function(){var e=arguments.length;if(e<2)return n("you must pass at least 2 arguments to Promise.using");var i=arguments[e-1],o;if("function"!=typeof i)return n("expecting a function but got "+a.classString(i));var l=!0;2===e&&Array.isArray(arguments[0])?(o=arguments[0],e=o.length,l=!1):(o=arguments,e--);for(var u=new b(e),f=0;f<e;++f){var p=o[f];if(g.isDisposer(p)){var d=p;p=p.promise(),p._setDisposable(d)}else{var y=r(p);y instanceof t&&(p=y._then(v,null,null,{resources:u,index:f},void 0))}u[f]=p}for(var _=new Array(u.length),f=0;f<_.length;++f)_[f]=t.resolve(u[f]).reflect();var w=t.all(_).then(function(e){for(var t=0;t<e.length;++t){var n=e[t];if(n.isRejected())return c.e=n.error(),c;if(!n.isFulfilled())return void w.cancel();e[t]=n.value()}k._pushContext(),i=h(i);var r=l?i.apply(void 0,e):i(e),o=k._popContext();return s.checkForgottenReturns(r,o,"Promise.using",k),r}),k=w.lastly(function(){var e=new t.PromiseInspection(w);return m(u,e)});return u.promise=k,k._setOnCancel(u),k},t.prototype._setDisposable=function(e){this._bitField=131072|this._bitField,this._disposer=e},t.prototype._isDisposable=function(){return(131072&this._bitField)>0},t.prototype._getDisposer=function(){return this._disposer},t.prototype._unsetDisposable=function(){this._bitField=-131073&this._bitField,this._disposer=void 0},t.prototype.disposer=function(e){if("function"==typeof e)return new y(e,this,i());throw new l}}},{"./errors":12,"./util":36}],36:[function(e,r,i){"use strict";var o=e("./es5"),s="undefined"==typeof navigator,a={e:{}},l,u="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==n?n:void 0!==this?this:null;function c(){try{var e=l;return l=null,e.apply(this,arguments)}catch(e){return a.e=e,a}}function h(e){return l=e,c}var f=function(e,t){var n={}.hasOwnProperty;function r(){for(var r in this.constructor=e,this.constructor$=t,t.prototype)n.call(t.prototype,r)&&"$"!==r.charAt(r.length-1)&&(this[r+"$"]=t.prototype[r])}return r.prototype=t.prototype,e.prototype=new r,e.prototype};function p(e){return null==e||!0===e||!1===e||"string"==typeof e||"number"==typeof e}function d(e){return"function"==typeof e||"object"==typeof e&&null!==e}function m(e){return p(e)?new Error(A(e)):e}function g(e,t){var n=e.length,r=new Array(n+1),i;for(i=0;i<n;++i)r[i]=e[i];return r[i]=t,r}function y(e,t,n){if(!o.isES5)return{}.hasOwnProperty.call(e,t)?e[t]:void 0;var r=Object.getOwnPropertyDescriptor(e,t);return null!=r?null==r.get&&null==r.set?r.value:n:void 0}function v(e,t,n){if(p(e))return e;var r={value:n,configurable:!0,enumerable:!1,writable:!0};return o.defineProperty(e,t,r),e}function b(e){throw e}var _=function(){var e=[Array.prototype,Object.prototype,Function.prototype],t=function(t){for(var n=0;n<e.length;++n)if(e[n]===t)return!0;return!1};if(o.isES5){var n=Object.getOwnPropertyNames;return function(e){for(var r=[],i=Object.create(null);null!=e&&!t(e);){var s;try{s=n(e)}catch(e){return r}for(var a=0;a<s.length;++a){var l=s[a];if(!i[l]){i[l]=!0;var u=Object.getOwnPropertyDescriptor(e,l);null!=u&&null==u.get&&null==u.set&&r.push(l)}}e=o.getPrototypeOf(e)}return r}}var r={}.hasOwnProperty;return function(n){if(t(n))return[];var i=[];e:for(var o in n)if(r.call(n,o))i.push(o);else{for(var s=0;s<e.length;++s)if(r.call(e[s],o))continue e;i.push(o)}return i}}(),w=/this\s*\.\s*\S+\s*=/;function k(e){try{if("function"==typeof e){var t=o.names(e.prototype),n=o.isES5&&t.length>1,r=t.length>0&&!(1===t.length&&"constructor"===t[0]),i=w.test(e+"")&&o.names(e).length>0;if(n||r||i)return!0}return!1}catch(e){return!1}}function E(e){function t(){}t.prototype=e;var n=new t;function r(){return typeof n.foo}return r(),r(),e}var S=/^[a-z$_][a-z$_0-9]*$/i;function x(e){return S.test(e)}function C(e,t,n){for(var r=new Array(e),i=0;i<e;++i)r[i]=t+i+n;return r}function A(e){try{return e+""}catch(e){return"[no string representation]"}}function T(e){return e instanceof Error||null!==e&&"object"==typeof e&&"string"==typeof e.message&&"string"==typeof e.name}function I(e){try{v(e,"isOperational",!0)}catch(e){}}function j(e){return null!=e&&(e instanceof Error.__BluebirdErrorTypes__.OperationalError||!0===e.isOperational)}function R(e){return T(e)&&o.propertyIsWritable(e,"stack")}var B="stack"in new Error?function(e){return R(e)?e:new Error(A(e))}:function(e){if(R(e))return e;try{throw new Error(A(e))}catch(e){return e}};function O(e){return{}.toString.call(e)}function P(e,t,n){for(var r=o.names(e),i=0;i<r.length;++i){var s=r[i];if(n(s))try{o.defineProperty(t,s,o.getDescriptor(e,s))}catch(e){}}}var N=function(e){return o.isArray(e)?e:null};if("undefined"!=typeof Symbol&&Symbol.iterator){var D="function"==typeof Array.from?function(e){return Array.from(e)}:function(e){for(var t=[],n=e[Symbol.iterator](),r;!(r=n.next()).done;)t.push(r.value);return t};N=function(e){return o.isArray(e)?e:null!=e&&"function"==typeof e[Symbol.iterator]?D(e):null}}var M=void 0!==t&&"[object process]"===O(t).toLowerCase(),F=void 0!==t&&void 0!==t.env;function L(e){return F?t.env[e]:void 0}function U(){if("function"==typeof Promise)try{var e=new Promise(function(){});if("[object Promise]"==={}.toString.call(e))return Promise}catch(e){}}function q(e,t){return e.bind(t)}var z={isClass:k,isIdentifier:x,inheritedDataKeys:_,getDataPropertyOrDefault:y,thrower:b,isArray:o.isArray,asArray:N,notEnumerableProp:v,isPrimitive:p,isObject:d,isError:T,canEvaluate:s,errorObj:a,tryCatch:h,inherits:f,withAppended:g,maybeWrapAsError:m,toFastProperties:E,filledRange:C,toString:A,canAttachTrace:R,ensureErrorObject:B,originatesFromRejection:j,markAsOriginatingFromRejection:I,classString:O,copyDescriptors:P,hasDevTools:"undefined"!=typeof chrome&&chrome&&"function"==typeof chrome.loadTimes,isNode:M,hasEnvVariables:F,env:L,global:u,getNativePromise:U,domainBind:q},K;z.isRecentNode=z.isNode&&(t.versions&&t.versions.node?K=t.versions.node.split(".").map(Number):t.version&&(K=t.version.split(".").map(Number)),0===K[0]&&K[1]>10||K[0]>0),z.isNode&&z.toFastProperties(t);try{throw new Error}catch(e){z.lastLineError=e}r.exports=z},{"./es5":13}]},{},[4])(4)},e.exports=r(),"undefined"!=typeof window&&null!==window?window.P=window.Promise:"undefined"!=typeof self&&null!==self&&(self.P=self.Promise)}).call(this,n(3),n(8))},function(e,t,n){"use strict";var r=n(1746),i=n(65),o=n(148),s=n(87);e.exports=function(e){var t="Please verify options";if(!s(e))throw new TypeError(t);if(!o(e.request))throw new TypeError(t+".request");if(!i(e.expose)||0===e.expose.length)throw new TypeError(t+".expose");var n=r({PromiseImpl:e.PromiseImpl,constructorMixin:e.constructorMixin}),a=e.request.Request.prototype.init;e.request.Request.prototype.init=function e(t){return!s(t)||this._callback||this._rp_promise||n.init.call(this,t),a.apply(this,arguments)};for(var l=!1,u=0;u<e.expose.length;u+=1){var c=e.expose[u];n["promise"===c?"exposePromise":"exposePromiseMethod"](e.request.Request.prototype,null,"_rp_promise",c),"then"===c&&(l=!0)}if(!l)throw new Error('Please expose "then"')}},function(e,t,n){"use strict";var r=n(632),i=n(148),o=n(87),s=n(510),a=n(1747);e.exports=function(e){var t="Please verify options";if(!o(e))throw new TypeError(t);if(!i(e.PromiseImpl))throw new TypeError(t+".PromiseImpl");if(!a(e.constructorMixin)&&!i(e.constructorMixin))throw new TypeError(t+".PromiseImpl");var n=e.PromiseImpl,l=e.constructorMixin,u={init:function(e){var t=this;t._rp_promise=new n(function(e,n){t._rp_resolve=e,t._rp_reject=n,l&&l.apply(t,arguments)}),t._rp_callbackOrig=e.callback,e.callback=t.callback=function e(n,r,i){u.callback.call(t,n,r,i)},s(e.method)&&(e.method=e.method.toUpperCase()),e.transform=e.transform||u.defaultTransformations[e.method],t._rp_options=e,t._rp_options.simple=!1!==e.simple,t._rp_options.resolveWithFullResponse=!0===e.resolveWithFullResponse,t._rp_options.transform2xxOnly=!0===e.transform2xxOnly},defaultTransformations:{HEAD:function(e,t,n){return n?t:t.headers}},callback:function(e,t,o){var s=this,a=!1,l=null;if(i(s._rp_callbackOrig))try{s._rp_callbackOrig.apply(s,arguments)}catch(e){a=!0,l=e}var u=!e&&/^2/.test(""+t.statusCode);if(e?s._rp_reject(new r.RequestError(e,s._rp_options,t)):s._rp_options.simple&&!u?i(s._rp_options.transform)&&!1===s._rp_options.transform2xxOnly?new n(function(e){e(s._rp_options.transform(o,t,s._rp_options.resolveWithFullResponse))}).then(function(e){s._rp_reject(new r.StatusCodeError(t.statusCode,o,s._rp_options,e))}).catch(function(e){s._rp_reject(new r.TransformError(e,s._rp_options,t))}):s._rp_reject(new r.StatusCodeError(t.statusCode,o,s._rp_options,t)):i(s._rp_options.transform)&&(u||!1===s._rp_options.transform2xxOnly)?new n(function(e){e(s._rp_options.transform(o,t,s._rp_options.resolveWithFullResponse))}).then(function(e){s._rp_resolve(e)}).catch(function(e){s._rp_reject(new r.TransformError(e,s._rp_options,t))}):s._rp_options.resolveWithFullResponse?s._rp_resolve(t):s._rp_resolve(o),a)throw l},exposePromiseMethod:function(e,t,n,r,i){if(i=i||r,i in e)throw new Error('Unable to expose method "'+i+'"');e[i]=function e(){var i=t||this;return i[n][r].apply(i[n],arguments)}},exposePromise:function(e,t,n,r){if(r=r||"promise",r in e)throw new Error('Unable to expose method "'+r+'"');e[r]=function e(){var r=t||this;return r[n]}}};return u}},function(e,t){function n(e){return void 0===e}e.exports=n},function(e,t,n){"use strict";var r=/\.node$/;function i(e,t){for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t(n)}function o(e,t){return i(t,function(n){e[n]=t[n]}),e}function s(e){i(e,function(t){r.test(t)||delete e[t]})}e.exports=function(e,t,n,r){var a=o({},e);if(s(e),n){var l=!!r.children&&r.children.slice();n();var u=[];i(e,function(e){u.push(e)}),s(e),r.children&&(r.children=l);for(var c=0;c<u.length;c+=1)a[u[c]]&&(e[u[c]]=a[u[c]])}var h=t(),f=!!n&&o({},e);if(s(e),n)for(var p=0;p<u.length;p+=1)f[u[p]]&&(e[u[p]]=f[u[p]]);return o(e,a),h}},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(16),i=n(32).parse,o=n(14),s=n(633),a=n(634).Store,l=n(1750).MemoryCookieStore,u=n(636).pathMatch,c=n(1751),h;try{h=n(179)}catch(e){console.warn("tough-cookie: can't load punycode; won't use punycode for domain normalization")}var f=/^[\x21\x23-\x2B\x2D-\x3A\x3C-\x5B\x5D-\x7E]+$/,p=/[\x00-\x1F]/,d=["\n","\r","\0"],m=/[\x20-\x3A\x3C-\x7E]+/,g=/[\x09\x20-\x2F\x3B-\x40\x5B-\x60\x7B-\x7E]/,y={jan:0,feb:1,mar:2,apr:3,may:4,jun:5,jul:6,aug:7,sep:8,oct:9,nov:10,dec:11},v=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],b=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],_=2147483647e3,w=0;function k(e,t,n,r){for(var i=0;i<e.length;){var o=e.charCodeAt(i);if(o<=47||o>=58)break;i++}return i<t||i>n?null:r||i==e.length?parseInt(e.substr(0,i),10):null}function E(e){var t=e.split(":"),n=[0,0,0];if(3!==t.length)return null;for(var r=0;r<3;r++){var i=2==r,o=k(t[r],1,2,i);if(null===o)return null;n[r]=o}return n}function S(e){e=String(e).substr(0,3).toLowerCase();var t=y[e];return t>=0?t:null}function x(e){if(e){var t=e.split(g);if(t){for(var n=null,r=null,i=null,o=null,s=null,a=null,l=0;l<t.length;l++){var u=t[l].trim(),c;if(u.length)null===i&&(c=E(u),c)?(n=c[0],r=c[1],i=c[2]):null!==o||(c=k(u,1,2,!0),null===c)?null!==s||(c=S(u),null===c)?null===a&&(c=k(u,2,4,!0),null!==c&&(a=c,a>=70&&a<=99?a+=1900:a>=0&&a<=69&&(a+=2e3))):s=c:o=c}if(!(null===o||null===s||null===a||null===i||o<1||o>31||a<1601||n>23||r>59||i>59))return new Date(Date.UTC(a,s,o,n,r,i))}}}function C(e){var t=e.getUTCDate();t=t>=10?t:"0"+t;var n=e.getUTCHours();n=n>=10?n:"0"+n;var r=e.getUTCMinutes();r=r>=10?r:"0"+r;var i=e.getUTCSeconds();return i=i>=10?i:"0"+i,b[e.getUTCDay()]+", "+t+" "+v[e.getUTCMonth()]+" "+e.getUTCFullYear()+" "+n+":"+r+":"+i+" GMT"}function A(e){return null==e?null:(e=e.trim().replace(/^\./,""),h&&/[^\u0001-\u007f]/.test(e)&&(e=h.toASCII(e)),e.toLowerCase())}function T(e,t,n){if(null==e||null==t)return null;if(!1!==n&&(e=A(e),t=A(t)),e==t)return!0;if(r.isIP(e))return!1;var i=e.indexOf(t);return!(i<=0)&&(e.length===t.length+i&&"."===e.substr(i-1,1))}function I(e){if(!e||"/"!==e.substr(0,1))return"/";if("/"===e)return e;var t=e.lastIndexOf("/");return 0===t?"/":e.slice(0,t)}function j(e){for(var t=0;t<d.length;t++){var n=e.indexOf(d[t]);-1!==n&&(e=e.substr(0,n))}return e}function R(e,t){e=j(e);var n=e.indexOf("="),r,i;if(t)0===n&&(e=e.substr(1),n=e.indexOf("="));else if(n<=0)return;if(n<=0?(r="",i=e.trim()):(r=e.substr(0,n).trim(),i=e.substr(n+1).trim()),!p.test(r)&&!p.test(i)){var o=new F;return o.key=r,o.value=i,o}}function B(e,t){t&&"object"==typeof t||(t={}),e=e.trim();var n=e.indexOf(";"),r=-1===n?e:e.substr(0,n),i=R(r,!!t.loose);if(i){if(-1===n)return i;var o=e.slice(n+1).trim();if(0===o.length)return i;for(var s=o.split(";");s.length;){var a=s.shift().trim();if(0!==a.length){var l=a.indexOf("="),u,c;switch(-1===l?(u=a,c=null):(u=a.substr(0,l),c=a.substr(l+1)),u=u.trim().toLowerCase(),c&&(c=c.trim()),u){case"expires":if(c){var h=x(c);h&&(i.expires=h)}break;case"max-age":if(c&&/^-?[0-9]+$/.test(c)){var f=parseInt(c,10);i.setMaxAge(f)}break;case"domain":if(c){var p=c.trim().replace(/^\./,"");p&&(i.domain=p.toLowerCase())}break;case"path":i.path=c&&"/"===c[0]?c:null;break;case"secure":i.secure=!0;break;case"httponly":i.httpOnly=!0;break;default:i.extensions=i.extensions||[],i.extensions.push(a)}}}return i}}function O(e){var t;try{t=JSON.parse(e)}catch(e){return e}return t}function P(e){if(!e)return null;var t;if("string"==typeof e){if(t=O(e),t instanceof Error)return null}else t=e;for(var n=new F,r=0;r<F.serializableProperties.length;r++){var i=F.serializableProperties[r];void 0!==t[i]&&t[i]!==F.prototype[i]&&("expires"===i||"creation"===i||"lastAccessed"===i?null===t[i]?n[i]=null:n[i]="Infinity"==t[i]?"Infinity":new Date(t[i]):n[i]=t[i])}return n}function N(e,t){var n=0,r=e.path?e.path.length:0,i=t.path?t.path.length:0;if(n=i-r,0!==n)return n;var o=e.creation?e.creation.getTime():_,s=t.creation?t.creation.getTime():_;return n=o-s,0!==n?n:(n=e.creationIndex-t.creationIndex,n)}function D(e){if("/"===e)return["/"];e.lastIndexOf("/")===e.length-1&&(e=e.substr(0,e.length-1));for(var t=[e];e.length>1;){var n=e.lastIndexOf("/");if(0===n)break;e=e.substr(0,n),t.push(e)}return t.push("/"),t}function M(e){if(e instanceof Object)return e;try{e=decodeURI(e)}catch(e){}return i(e)}function F(e){e=e||{},Object.keys(e).forEach(function(t){F.prototype.hasOwnProperty(t)&&F.prototype[t]!==e[t]&&"_"!==t.substr(0,1)&&(this[t]=e[t])},this),this.creation=this.creation||new Date,Object.defineProperty(this,"creationIndex",{configurable:!1,enumerable:!1,writable:!0,value:++F.cookiesCreated})}function L(e,t){"boolean"==typeof t?t={rejectPublicSuffixes:t}:null==t&&(t={}),null!=t.rejectPublicSuffixes&&(this.rejectPublicSuffixes=t.rejectPublicSuffixes),null!=t.looseMode&&(this.enableLooseMode=t.looseMode),e||(e=new l),this.store=e}F.cookiesCreated=0,F.parse=B,F.fromJSON=P,F.prototype.key="",F.prototype.value="",F.prototype.expires="Infinity",F.prototype.maxAge=null,F.prototype.domain=null,F.prototype.path=null,F.prototype.secure=!1,F.prototype.httpOnly=!1,F.prototype.extensions=null,F.prototype.hostOnly=null,F.prototype.pathIsDefault=null,F.prototype.creation=null,F.prototype.lastAccessed=null,Object.defineProperty(F.prototype,"creationIndex",{configurable:!0,enumerable:!1,writable:!0,value:0}),F.serializableProperties=Object.keys(F.prototype).filter(function(e){return!(F.prototype[e]instanceof Function||"creationIndex"===e||"_"===e.substr(0,1))}),F.prototype.inspect=function e(){var t=Date.now();return'Cookie="'+this.toString()+"; hostOnly="+(null!=this.hostOnly?this.hostOnly:"?")+"; aAge="+(this.lastAccessed?t-this.lastAccessed.getTime()+"ms":"?")+"; cAge="+(this.creation?t-this.creation.getTime()+"ms":"?")+'"'},o.inspect.custom&&(F.prototype[o.inspect.custom]=F.prototype.inspect),F.prototype.toJSON=function(){for(var e={},t=F.serializableProperties,n=0;n<t.length;n++){var r=t[n];this[r]!==F.prototype[r]&&("expires"===r||"creation"===r||"lastAccessed"===r?null===this[r]?e[r]=null:e[r]="Infinity"==this[r]?"Infinity":this[r].toISOString():"maxAge"===r?null!==this[r]&&(e[r]=this[r]==1/0||this[r]==-1/0?this[r].toString():this[r]):this[r]!==F.prototype[r]&&(e[r]=this[r]))}return e},F.prototype.clone=function(){return P(this.toJSON())},F.prototype.validate=function e(){if(!f.test(this.value))return!1;if(!(this.expires==1/0||this.expires instanceof Date||x(this.expires)))return!1;if(null!=this.maxAge&&this.maxAge<=0)return!1;if(null!=this.path&&!m.test(this.path))return!1;var t=this.cdomain();if(t){if(t.match(/\.$/))return!1;var n=s.getPublicSuffix(t);if(null==n)return!1}return!0},F.prototype.setExpires=function e(t){t instanceof Date?this.expires=t:this.expires=x(t)||"Infinity"},F.prototype.setMaxAge=function e(t){this.maxAge=t===1/0||t===-1/0?t.toString():t},F.prototype.cookieString=function e(){var t=this.value;return null==t&&(t=""),""===this.key?t:this.key+"="+t},F.prototype.toString=function e(){var t=this.cookieString();return this.expires!=1/0&&(this.expires instanceof Date?t+="; Expires="+C(this.expires):t+="; Expires="+this.expires),null!=this.maxAge&&this.maxAge!=1/0&&(t+="; Max-Age="+this.maxAge),this.domain&&!this.hostOnly&&(t+="; Domain="+this.domain),this.path&&(t+="; Path="+this.path),this.secure&&(t+="; Secure"),this.httpOnly&&(t+="; HttpOnly"),this.extensions&&this.extensions.forEach(function(e){t+="; "+e}),t},F.prototype.TTL=function e(t){if(null!=this.maxAge)return this.maxAge<=0?0:1e3*this.maxAge;var n=this.expires;return n!=1/0?(n instanceof Date||(n=x(n)||1/0),n==1/0?1/0:n.getTime()-(t||Date.now())):1/0},F.prototype.expiryTime=function e(t){if(null!=this.maxAge){var n=t||this.creation||new Date,r=this.maxAge<=0?-1/0:1e3*this.maxAge;return n.getTime()+r}return this.expires==1/0?1/0:this.expires.getTime()},F.prototype.expiryDate=function e(t){var n=this.expiryTime(t);return n==1/0?new Date(_):n==-1/0?new Date(0):new Date(n)},F.prototype.isPersistent=function e(){return null!=this.maxAge||this.expires!=1/0},F.prototype.cdomain=F.prototype.canonicalizedDomain=function e(){return null==this.domain?null:A(this.domain)},L.prototype.store=null,L.prototype.rejectPublicSuffixes=!0,L.prototype.enableLooseMode=!1;var U=[];function q(e){return function(){if(!this.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");var t=Array.prototype.slice.call(arguments),n,r;if(t.push(function e(t,i){n=t,r=i}),this[e].apply(this,t),n)throw n;return r}}U.push("setCookie"),L.prototype.setCookie=function(e,t,n,r){var i,o=M(t);n instanceof Function&&(r=n,n={});var a=A(o.hostname),l=this.enableLooseMode;if(null!=n.loose&&(l=n.loose),e instanceof F||(e=F.parse(e,{loose:l})),!e)return i=new Error("Cookie failed to parse"),r(n.ignoreError?null:i);var u=n.now||new Date;if(this.rejectPublicSuffixes&&e.domain){var c=s.getPublicSuffix(e.cdomain());if(null==c)return i=new Error("Cookie has domain set to a public suffix"),r(n.ignoreError?null:i)}if(e.domain){if(!T(a,e.cdomain(),!1))return i=new Error("Cookie not in this host's domain. Cookie:"+e.cdomain()+" Request:"+a),r(n.ignoreError?null:i);null==e.hostOnly&&(e.hostOnly=!1)}else e.hostOnly=!0,e.domain=a;if(e.path&&"/"===e.path[0]||(e.path=I(o.pathname),e.pathIsDefault=!0),!1===n.http&&e.httpOnly)return i=new Error("Cookie is HttpOnly and this isn't an HTTP API"),r(n.ignoreError?null:i);var h=this.store;function f(t,i){if(t)return r(t);var o=function(t){if(t)return r(t);r(null,e)};if(i){if(!1===n.http&&i.httpOnly)return t=new Error("old Cookie is HttpOnly and this isn't an HTTP API"),r(n.ignoreError?null:t);e.creation=i.creation,e.creationIndex=i.creationIndex,e.lastAccessed=u,h.updateCookie(i,e,o)}else e.creation=e.lastAccessed=u,h.putCookie(e,o)}h.updateCookie||(h.updateCookie=function(e,t,n){this.putCookie(t,n)}),h.findCookie(e.domain,e.path,e.key,f)},U.push("getCookies"),L.prototype.getCookies=function(e,t,n){var r=M(e);t instanceof Function&&(n=t,t={});var i=A(r.hostname),o=r.pathname||"/",s=t.secure;null!=s||!r.protocol||"https:"!=r.protocol&&"wss:"!=r.protocol||(s=!0);var a=t.http;null==a&&(a=!0);var l=t.now||Date.now(),c=!1!==t.expire,h=!!t.allPaths,f=this.store;function p(e){if(e.hostOnly){if(e.domain!=i)return!1}else if(!T(i,e.domain,!1))return!1;return!(!h&&!u(o,e.path))&&(!(e.secure&&!s)&&(!(e.httpOnly&&!a)&&(!(c&&e.expiryTime()<=l)||(f.removeCookie(e.domain,e.path,e.key,function(){}),!1))))}f.findCookies(i,h?null:o,function(e,r){if(e)return n(e);r=r.filter(p),!1!==t.sort&&(r=r.sort(N));var i=new Date;r.forEach(function(e){e.lastAccessed=i}),n(null,r)})},U.push("getCookieString"),L.prototype.getCookieString=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop(),n=function(e,n){e?t(e):t(null,n.sort(N).map(function(e){return e.cookieString()}).join("; "))};e.push(n),this.getCookies.apply(this,e)},U.push("getSetCookieStrings"),L.prototype.getSetCookieStrings=function(){var e=Array.prototype.slice.call(arguments,0),t=e.pop(),n=function(e,n){e?t(e):t(null,n.map(function(e){return e.toString()}))};e.push(n),this.getCookies.apply(this,e)},U.push("serialize"),L.prototype.serialize=function(e){var t=this.store.constructor.name;"Object"===t&&(t=null);var n={version:"tough-cookie@"+c,storeType:t,rejectPublicSuffixes:!!this.rejectPublicSuffixes,cookies:[]};if(!this.store.getAllCookies||"function"!=typeof this.store.getAllCookies)return e(new Error("store does not support getAllCookies and cannot be serialized"));this.store.getAllCookies(function(t,r){return t?e(t):(n.cookies=r.map(function(e){return e=e instanceof F?e.toJSON():e,delete e.creationIndex,e}),e(null,n))})},L.prototype.toJSON=function(){return this.serializeSync()},U.push("_importCookies"),L.prototype._importCookies=function(e,t){var n=this,r=e.cookies;if(!r||!Array.isArray(r))return t(new Error("serialized jar has no cookies array"));function i(e){if(e)return t(e);if(!r.length)return t(e,n);var o;try{o=P(r.shift())}catch(e){return t(e)}if(null===o)return i(null);n.store.putCookie(o,i)}r=r.slice(),i()},L.deserialize=function(e,t,n){var r;if(3!==arguments.length&&(n=t,t=null),"string"==typeof e){if(r=O(e),r instanceof Error)return n(r)}else r=e;var i=new L(t,r.rejectPublicSuffixes);i._importCookies(r,function(e){if(e)return n(e);n(null,i)})},L.deserializeSync=function(e,t){var n="string"==typeof e?JSON.parse(e):e,r=new L(t,n.rejectPublicSuffixes);if(!r.store.synchronous)throw new Error("CookieJar store is not synchronous; use async API instead.");return r._importCookiesSync(n),r},L.fromJSON=L.deserializeSync,L.prototype.clone=function(e,t){1===arguments.length&&(t=e,e=null),this.serialize(function(n,r){if(n)return t(n);L.deserialize(r,e,t)})},U.push("removeAllCookies"),L.prototype.removeAllCookies=function(e){var t=this.store;if(t.removeAllCookies instanceof Function&&t.removeAllCookies!==a.prototype.removeAllCookies)return t.removeAllCookies(e);t.getAllCookies(function(n,r){if(n)return e(n);if(0===r.length)return e(null);var i=0,o=[];function s(t){if(t&&o.push(t),i++,i===r.length)return e(o.length?o[0]:null)}r.forEach(function(e){t.removeCookie(e.domain,e.path,e.key,s)})})},L.prototype._cloneSync=q("clone"),L.prototype.cloneSync=function(e){if(!e.synchronous)throw new Error("CookieJar clone destination store is not synchronous; use async API instead.");return this._cloneSync(e)},U.forEach(function(e){L.prototype[e+"Sync"]=q(e)}),t.version=c,t.CookieJar=L,t.Cookie=F,t.Store=a,t.MemoryCookieStore=l,t.parseDate=x,t.formatDate=C,t.parse=B,t.fromJSON=P,t.domainMatch=T,t.defaultPath=I,t.pathMatch=u,t.getPublicSuffix=s.getPublicSuffix,t.cookieCompare=N,t.permuteDomain=n(635).permuteDomain,t.permutePath=D,t.canonicalDomain=A},function(e,t,n){"use strict";
/*!
* Copyright (c) 2015, Salesforce.com, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of Salesforce.com nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/var r=n(634).Store,i=n(635).permuteDomain,o=n(636).pathMatch,s=n(14);function a(){r.call(this),this.idx={}}s.inherits(a,r),t.MemoryCookieStore=a,a.prototype.idx=null,a.prototype.synchronous=!0,a.prototype.inspect=function(){return"{ idx: "+s.inspect(this.idx,!1,2)+" }"},s.inspect.custom&&(a.prototype[s.inspect.custom]=a.prototype.inspect),a.prototype.findCookie=function(e,t,n,r){return this.idx[e]&&this.idx[e][t]?r(null,this.idx[e][t][n]||null):r(null,void 0)},a.prototype.findCookies=function(e,t,n){var r=[],s;if(!e)return n(null,[]);s=t?function e(n){Object.keys(n).forEach(function(e){if(o(t,e)){var i=n[e];for(var s in i)r.push(i[s])}})}:function e(t){for(var n in t){var i=t[n];for(var o in i)r.push(i[o])}};var a=i(e)||[e],l=this.idx;a.forEach(function(e){var t=l[e];t&&s(t)}),n(null,r)},a.prototype.putCookie=function(e,t){this.idx[e.domain]||(this.idx[e.domain]={}),this.idx[e.domain][e.path]||(this.idx[e.domain][e.path]={}),this.idx[e.domain][e.path][e.key]=e,t(null)},a.prototype.updateCookie=function(e,t,n){this.putCookie(t,n)},a.prototype.removeCookie=function(e,t,n,r){this.idx[e]&&this.idx[e][t]&&this.idx[e][t][n]&&delete this.idx[e][t][n],r(null)},a.prototype.removeCookies=function(e,t,n){return this.idx[e]&&(t?delete this.idx[e][t]:delete this.idx[e]),n(null)},a.prototype.removeAllCookies=function(e){return this.idx={},e(null)},a.prototype.getAllCookies=function(e){var t=[],n=this.idx,r=Object.keys(n);r.forEach(function(e){var r=Object.keys(n[e]);r.forEach(function(r){var i=Object.keys(n[e][r]);i.forEach(function(i){null!==i&&t.push(n[e][r][i])})})}),t.sort(function(e,t){return(e.creationIndex||0)-(t.creationIndex||0)}),e(null,t)}},function(e,t){e.exports="2.5.0"},function(e,t,n){"use strict";e.exports=n(1753)},function(e,t,n){"use strict";e.exports=n(632)},function(e,t,n){const r=n(1755);e.exports=new r},function(e,t,n){const r=n(16),i=n(1756),{QuotaExceededError:o,TypeMismatchError:s}=n(239),a=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array],l={Int8Array:"getInt8",Uint8Array:"getUint8",Int16Array:"getInt16",Uint16Array:"getUint16",Int32Array:"getInt32",Uint32Array:"getUint32"};class u{getRandomValues(e){if(!a.some(t=>e instanceof t))throw new s;let t=e.byteLength;if(t>65536)throw new o;let n=e.constructor,i=l[n.name],u=t*e.length,c=r.randomBytes(u),h=new Uint8Array(c),f=new DataView(h.buffer);for(let n=0;n<u;n+=t){let r=f[i](n),o=n/t;e[o]=r}return e}get subtle(){return new i}}e.exports=u},function(e,t,n){const r=n(1757),i=n(1758),o=n(1759),s=n(1760),a=n(1761),{InvalidAccessError:l,NotSupportedError:u}=n(239),{TextEncoder:c,TextDecoder:h}=n(1774);class f{encrypt(e,t,n){n=n.slice();let r=a.normalize("encrypt",e);return r instanceof Error?Promise.reject(r):new Promise((i,o)=>{if(r.name!==t.algorithm.name)throw new l("Algorithm does not match key");if(!t.usages.includes("encrypt"))throw new l('Key usages must include "encrypt"');let s=r.encrypt(e,t,n);i(s)})}decrypt(e,t,n){let r=a.normalize("decrypt",e);return r instanceof Error?Promise.reject(r):(n=n.slice(),new Promise((i,o)=>{if(r.name!==t.algorithm.name)throw new l("Algorithm does not match key");if(!t.usages.includes("decrypt"))throw new l('Key usages must include "decrypt"');let s=r.decrypt(e,t,n);i(s)}))}sign(e,t,n){n=n.slice();let r=a.normalize("sign",e);return r instanceof Error?Promise.reject(r):new Promise((e,i)=>{if(r.name!==t.algorithm.name)throw new l("Algorithm does not match key");if(!t.usages.includes("sign"))throw new l('Key usages must include "sign"');let o=r.sign(t,n);e(o)})}verify(e,t,n,r){n=n.slice();let i=a.normalize("verify",e);return i instanceof Error?Promise.reject(i):(r=r.slice(),new Promise((e,o)=>{if(i.name!==t.algorithm.name)throw new l("Algorithm does not match key");if(!t.usages.includes("verify"))throw new l('Key usages must include "verify"');let s=i.verify(t,n,r);e(s)}))}digest(e,t){t=t.slice();let n=a.normalize("digest",e);return n instanceof Error?Promise.reject(n):new Promise((r,i)=>{try{let o=n.digest(e,t);return r(o)}catch(e){return i(e)}})}generateKey(e,t,n){let o=a.normalize("generateKey",e);return o instanceof Error?Promise.reject(o):new Promise((s,a)=>{try{let l=o.generateKey(e,t,n);if(l instanceof r){let{type:e,usages:t}=l,n="secret"===e||"private"===e,r=!t||0===t.length;if(n&&r)throw new SyntaxError}if(l instanceof i){let{privateKey:{usages:e}}=l;if(!e||0===e.length)throw new SyntaxError}s(l)}catch(e){return a(e)}})}deriveKey(e,t,n,r,i){return new Promise}deriveBits(e,t,n){return new Promise}importKey(e,t,n,r,i){let l=a.normalize("importKey",n);return l instanceof Error?Promise.reject(l):new Promise((a,u)=>{if("raw"===e||"pkcs8"===e||"spki"===e){if(t instanceof o)throw new TypeError;t=t.slice()}if("jwk"===e&&(t=new o(t),!(t instanceof o)))throw new TypeError("key is not a JSON Web Key");try{let o=l.importKey(e,t,n,r,i);if(!("secret"!==o.type&&"private"!==o.type||o.usages&&0!==o.usages.length))throw new SyntaxError;o.extractable=r,o.usages=s.normalize(i),a(o)}catch(e){return u(e)}})}exportKey(e,t){return new Promise((n,r)=>{try{let i=a.exportKey;if(!i[t.algorithm.name])throw new u(t.algorithm.name);if(!1===t.extractable)throw new l("Key is not extractable");let o=t.algorithm.exportKey(e,t);n(o)}catch(e){return r(e)}})}wrapKey(e,t,n,r){let i=a.normalize("wrapKey",r);return i instanceof Error&&(i=a.normalize("encrypt",r)),i instanceof Error?Promise.reject(i):new Promise((o,s)=>{try{if(i.name!==n.algorithm.name)throw new l("NormalizedAlgorthm name must be same as wrappingKey algorithm name");if(!n.usages.includes("wrapKey"))throw new l('Wrapping key usages must include "wrapKey"');let h=a.exportKey;if(!h[t.algorithm.name])throw new u(t.algorithm.name);if(!1===t.extractable)throw new l("Key is not extractable");return this.exportKey(e,t).then(t=>{let o;if(["raw","pkcs8","spki"].includes(e))o=t;else if("jwk"===e){let e=JSON.stringify(t);o=(new c).encode(e)}return i.wrapKey?i.wrapKey(e,o,n,r):i.encrypt?i.encrypt(r,n,new Uint8Array(o)):s(new u(i.name))}).then(o)}catch(e){return s(e)}})}unwrapKey(e,t,n,r,i,o,s){let c=a.normalize("unwrapKey",r);if(c instanceof Error&&(c=a.normalize("decrypt",r)),c instanceof Error)return Promise.reject(c);let f=a.normalize("importKey",i);return f instanceof Error?Promise.reject(f):new Promise((a,p)=>{try{if(c.name!==n.algorithm.name)throw new l("NormalizedAlgorthm name must be same as unwrappingKey algorithm name");if(!n.usages.includes("unwrapKey"))throw new l('Unwrapping key usages must include "unwrapKey"');let d,m;if(c.unwrapKey)d=c.unwrapKey(e,t,n,r,i,o,s);else{if(!c.decrypt)return p(new u(c.name));d=c.decrypt(r,n,t)}["raw","pkcs8","spki"].includes(e)?m=d:"jwk"===e&&(m=JSON.parse((new h).decode(d)));let g=f.importKey(e,m,i,o,s);return a(g)}catch(e){return p(e)}})}}e.exports=f},function(e,t){class n{constructor({type:e,extractable:t,algorithm:n,usages:r,handle:i}){this.type=e,this.extractable=t,this.algorithm=n,this.usages=r,Object.defineProperties(this,{handle:{enumerable:!1,writeable:!1,value:i}})}clone({type:e,extractable:t,algorithm:r,usages:i,handle:o},s){return new n({type:e,extractable:t,algorithm:r,usages:i,handle:o})}}e.exports=n},function(e,t){class n{constructor({publicKey:e,privateKey:t}){this.publicKey=e,this.privateKey=t}}e.exports=n},function(e,t){class n{constructor(e){Object.assign(this,e)}}e.exports=n},function(e,t){class n extends Array{constructor(e){super(),e.forEach(e=>this.push(e))}normalize(e){let t=[];for(let n=0;n<this.length;n++){let r=this[n];e.includes(r)&&t.push(r)}return t}}e.exports=new n(["encrypt","decrypt","sign","verify","deriveBits","wrapKey","unwrapKey"])},function(e,t,n){const r=n(1762),i=new r;i.define("RSA-OAEP","encrypt","../algorithms/RSA-OAEP"),i.define("AES-CTR","encrypt","../algorithms/AES-CTR"),i.define("AES-CBC","encrypt","../algorithms/AES-CBC"),i.define("AES-GCM","encrypt","../algorithms/AES-GCM"),i.define("RSA-OAEP","decrypt","../algorithms/RSA-OAEP"),i.define("AES-CTR","decrypt","../algorithms/AES-CTR"),i.define("AES-CBC","decrypt","../algorithms/AES-CBC"),i.define("AES-GCM","decrypt","../algorithms/AES-GCM"),i.define("RSASSA-PKCS1-v1_5","sign","../algorithms/RSASSA-PKCS1-v1_5"),i.define("RSA-PSS","sign","../algorithms/RSA-PSS"),i.define("ECDSA","sign","../algorithms/ECDSA"),i.define("EDDSA","sign","../algorithms/EDDSA"),i.define("HMAC","sign","../algorithms/HMAC"),i.define("RSASSA-PKCS1-v1_5","verify","../algorithms/RSASSA-PKCS1-v1_5"),i.define("RSA-PSS","verify","../algorithms/RSA-PSS"),i.define("ECDSA","verify","../algorithms/ECDSA"),i.define("EDDSA","verify","../algorithms/EDDSA"),i.define("HMAC","verify","../algorithms/HMAC"),i.define("SHA-1","digest","../algorithms/SHA"),i.define("SHA-256","digest","../algorithms/SHA"),i.define("SHA-384","digest","../algorithms/SHA"),i.define("SHA-512","digest","../algorithms/SHA"),i.define("RSASSA-PKCS1-v1_5","generateKey","../algorithms/RSASSA-PKCS1-v1_5"),i.define("RSA-PSS","generateKey","../algorithms/RSA-PSS"),i.define("RSA-OAEP","generateKey","../algorithms/RSA-OAEP"),i.define("ECDSA","generateKey","../algorithms/ECDSA"),i.define("EDDSA","generateKey","../algorithms/EDDSA"),i.define("AES-CTR","generateKey","../algorithms/AES-CTR"),i.define("AES-CBC","generateKey","../algorithms/AES-CBC"),i.define("AES-GCM","generateKey","../algorithms/AES-GCM"),i.define("AES-KW","generateKey","../algorithms/AES-KW"),i.define("HMAC","generateKey","../algorithms/HMAC"),i.define("RSASSA-PKCS1-v1_5","importKey","../algorithms/RSASSA-PKCS1-v1_5"),i.define("RSA-PSS","importKey","../algorithms/RSA-PSS"),i.define("RSA-OAEP","importKey","../algorithms/RSA-OAEP"),i.define("ECDSA","importKey","../algorithms/ECDSA"),i.define("EDDSA","importKey","../algorithms/EDDSA"),i.define("AES-CTR","importKey","../algorithms/AES-CTR"),i.define("AES-CBC","importKey","../algorithms/AES-CBC"),i.define("AES-GCM","importKey","../algorithms/AES-GCM"),i.define("AES-KW","importKey","../algorithms/AES-KW"),i.define("HMAC","importKey","../algorithms/HMAC"),i.define("RSASSA-PKCS1-v1_5","exportKey","../algorithms/RSASSA-PKCS1-v1_5"),i.define("RSA-PSS","exportKey","../algorithms/RSA-PSS"),i.define("RSA-OAEP","exportKey","../algorithms/RSA-OAEP"),i.define("EDDSA","exportKey","../algorithms/EDDSA"),i.define("ECDSA","exportKey","../algorithms/ECDSA"),i.define("AES-CTR","exportKey","../algorithms/AES-CTR"),i.define("AES-CBC","exportKey","../algorithms/AES-CBC"),i.define("AES-GCM","exportKey","../algorithms/AES-GCM"),i.define("AES-KW","exportKey","../algorithms/AES-KW"),i.define("HMAC","exportKey","../algorithms/HMAC"),i.define("RSA-OAEP","wrapKey","../algorithms/RSA-OAEP"),i.define("AES-CTR","wrapKey","../algorithms/AES-CTR"),i.define("AES-CBC","wrapKey","../algorithms/AES-CBC"),i.define("AES-GCM","wrapKey","../algorithms/AES-GCM"),i.define("AES-KW","wrapKey","../algorithms/AES-KW"),i.define("RSA-OAEP","unwrapKey","../algorithms/RSA-OAEP"),i.define("AES-CTR","unwrapKey","../algorithms/AES-CTR"),i.define("AES-CBC","unwrapKey","../algorithms/AES-CBC"),i.define("AES-GCM","unwrapKey","../algorithms/AES-GCM"),i.define("AES-KW","unwrapKey","../algorithms/AES-KW"),e.exports=i},function(e,t,n){const r=n(1763),i=n(1764),o=n(1772),{NotSupportedError:s}=n(239),a=["encrypt","decrypt","sign","verify","deriveBits","digest","wrapKey","unwrapKey","generateKey","importKey","exportKey","getLength"];class l{constructor(){a.forEach(e=>{this[e]=new o})}static get operations(){return a}define(e,t,n){let r=this[t];r[e]=n}normalize(e,t){if("string"==typeof t)return this.normalize(e,new i({name:t}));if("object"==typeof t){let i=this[e],o;try{o=new r(t)}catch(e){return e}let a=o.name,l,u;if(a=i.getCaseInsensitive(a),void 0===a)return new s(t.name);try{l=n(1773)(i[a]),u=new l(t),u.name=a}catch(e){return e}let c=l.dictionaries;for(let e=0;e<c.length;e++){let t=c[e],n=t.members;for(let e in n){let t=n[e],r=u[e];try{if("BufferSource"===t&&void 0!==r&&(u[e]=r.slice()),"HashAlgorithmIdentifier"===t){let t=this.normalize("digest",r);if(t instanceof Error)return t;u[e]=t}"AlgorithmIdentifier"===t&&(u[e]=this.normalize(WTF,r))}catch(e){return e}}}return u}}}e.exports=l},function(e,t){class n{constructor(e){if("string"==typeof e)this.name=e;else if(Object.assign(this,e),"string"!=typeof this.name)throw new Error("Algorithm name must be a string")}}e.exports=n},function(e,t,n){const{NotSupportedError:r}=n(239);class i{constructor(e){if(Object.assign(this,e),void 0===this.name)throw new Error("KeyAlgorithm must have a name")}}e.exports=i},function(e,t){class n extends Error{constructor(e){super(e)}}e.exports=n},function(e,t){class n extends Error{constructor(e){super(e)}}e.exports=n},function(e,t,n){const r=n(324);class i extends r{constructor(e){super(),this.message=`${e} is not a supported key format`}}e.exports=i},function(e,t,n){const r=n(324);class i extends r{constructor(e,t){super(),this.message=`Currently '${e}' is not a supported format. Please use '${t}' in the interim.`}}e.exports=i},function(e,t){class n extends Error{constructor(e){super(e)}}e.exports=n},function(e,t){class n extends Error{constructor(e){super(e)}}e.exports=n},function(e,t){class n extends Error{constructor(e){super(e)}}e.exports=n},function(e,t){class n{constructor(e){Object.assign(this,e)}getCaseInsensitive(e){for(let t in this)if(t.match(new RegExp(`^${e}$`,"i")))return t}}e.exports=n},function(e,t){function n(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id=1773},function(e,t,n){var r=n(1775);e.exports={TextEncoder:r.TextEncoder,TextDecoder:r.TextDecoder}},function(e,t,n){!function(t){"use strict";function r(e,t,n){return t<=e&&e<=n}function i(e,t){return-1!==e.indexOf(t)}e.exports&&!t["encoding-indexes"]&&(t["encoding-indexes"]=n(1776)["encoding-indexes"]);var o=Math.floor;function s(e){if(void 0===e)return{};if(e===Object(e))return e;throw TypeError("Could not convert argument to dictionary")}function a(e){for(var t=String(e),n=t.length,r=0,i=[];r<n;){var o=t.charCodeAt(r);if(o<55296||o>57343)i.push(o);else if(56320<=o&&o<=57343)i.push(65533);else if(55296<=o&&o<=56319)if(r===n-1)i.push(65533);else{var s=t.charCodeAt(r+1);if(56320<=s&&s<=57343){var a=1023&o,l=1023&s;i.push(65536+(a<<10)+l),r+=1}else i.push(65533)}r+=1}return i}function l(e){for(var t="",n=0;n<e.length;++n){var r=e[n];r<=65535?t+=String.fromCharCode(r):(r-=65536,t+=String.fromCharCode(55296+(r>>10),56320+(1023&r)))}return t}function u(e){return 0<=e&&e<=127}var c=u,h=-1;function f(e){this.tokens=[].slice.call(e),this.tokens.reverse()}f.prototype={endOfStream:function(){return!this.tokens.length},read:function(){return this.tokens.length?this.tokens.pop():h},prepend:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.push(t.pop());else this.tokens.push(e)},push:function(e){if(Array.isArray(e))for(var t=e;t.length;)this.tokens.unshift(t.shift());else this.tokens.unshift(e)}};var p=-1;function d(e,t){if(e)throw TypeError("Decoder error");return t||65533}function m(e){throw TypeError("The code point "+e+" could not be encoded.")}function g(){}function y(){}function v(e){return e=String(e).trim().toLowerCase(),Object.prototype.hasOwnProperty.call(_,e)?_[e]:null}g.prototype={handler:function(e,t){}},y.prototype={handler:function(e,t){}};var b=[{encodings:[{labels:["unicode-1-1-utf-8","utf-8","utf8"],name:"UTF-8"}],heading:"The Encoding"},{encodings:[{labels:["866","cp866","csibm866","ibm866"],name:"IBM866"},{labels:["csisolatin2","iso-8859-2","iso-ir-101","iso8859-2","iso88592","iso_8859-2","iso_8859-2:1987","l2","latin2"],name:"ISO-8859-2"},{labels:["csisolatin3","iso-8859-3","iso-ir-109","iso8859-3","iso88593","iso_8859-3","iso_8859-3:1988","l3","latin3"],name:"ISO-8859-3"},{labels:["csisolatin4","iso-8859-4","iso-ir-110","iso8859-4","iso88594","iso_8859-4","iso_8859-4:1988","l4","latin4"],name:"ISO-8859-4"},{labels:["csisolatincyrillic","cyrillic","iso-8859-5","iso-ir-144","iso8859-5","iso88595","iso_8859-5","iso_8859-5:1988"],name:"ISO-8859-5"},{labels:["arabic","asmo-708","csiso88596e","csiso88596i","csisolatinarabic","ecma-114","iso-8859-6","iso-8859-6-e","iso-8859-6-i","iso-ir-127","iso8859-6","iso88596","iso_8859-6","iso_8859-6:1987"],name:"ISO-8859-6"},{labels:["csisolatingreek","ecma-118","elot_928","greek","greek8","iso-8859-7","iso-ir-126","iso8859-7","iso88597","iso_8859-7","iso_8859-7:1987","sun_eu_greek"],name:"ISO-8859-7"},{labels:["csiso88598e","csisolatinhebrew","hebrew","iso-8859-8","iso-8859-8-e","iso-ir-138","iso8859-8","iso88598","iso_8859-8","iso_8859-8:1988","visual"],name:"ISO-8859-8"},{labels:["csiso88598i","iso-8859-8-i","logical"],name:"ISO-8859-8-I"},{labels:["csisolatin6","iso-8859-10","iso-ir-157","iso8859-10","iso885910","l6","latin6"],name:"ISO-8859-10"},{labels:["iso-8859-13","iso8859-13","iso885913"],name:"ISO-8859-13"},{labels:["iso-8859-14","iso8859-14","iso885914"],name:"ISO-8859-14"},{labels:["csisolatin9","iso-8859-15","iso8859-15","iso885915","iso_8859-15","l9"],name:"ISO-8859-15"},{labels:["iso-8859-16"],name:"ISO-8859-16"},{labels:["cskoi8r","koi","koi8","koi8-r","koi8_r"],name:"KOI8-R"},{labels:["koi8-ru","koi8-u"],name:"KOI8-U"},{labels:["csmacintosh","mac","macintosh","x-mac-roman"],name:"macintosh"},{labels:["dos-874","iso-8859-11","iso8859-11","iso885911","tis-620","windows-874"],name:"windows-874"},{labels:["cp1250","windows-1250","x-cp1250"],name:"windows-1250"},{labels:["cp1251","windows-1251","x-cp1251"],name:"windows-1251"},{labels:["ansi_x3.4-1968","ascii","cp1252","cp819","csisolatin1","ibm819","iso-8859-1","iso-ir-100","iso8859-1","iso88591","iso_8859-1","iso_8859-1:1987","l1","latin1","us-ascii","windows-1252","x-cp1252"],name:"windows-1252"},{labels:["cp1253","windows-1253","x-cp1253"],name:"windows-1253"},{labels:["cp1254","csisolatin5","iso-8859-9","iso-ir-148","iso8859-9","iso88599","iso_8859-9","iso_8859-9:1989","l5","latin5","windows-1254","x-cp1254"],name:"windows-1254"},{labels:["cp1255","windows-1255","x-cp1255"],name:"windows-1255"},{labels:["cp1256","windows-1256","x-cp1256"],name:"windows-1256"},{labels:["cp1257","windows-1257","x-cp1257"],name:"windows-1257"},{labels:["cp1258","windows-1258","x-cp1258"],name:"windows-1258"},{labels:["x-mac-cyrillic","x-mac-ukrainian"],name:"x-mac-cyrillic"}],heading:"Legacy single-byte encodings"},{encodings:[{labels:["chinese","csgb2312","csiso58gb231280","gb2312","gb_2312","gb_2312-80","gbk","iso-ir-58","x-gbk"],name:"GBK"},{labels:["gb18030"],name:"gb18030"}],heading:"Legacy multi-byte Chinese (simplified) encodings"},{encodings:[{labels:["big5","big5-hkscs","cn-big5","csbig5","x-x-big5"],name:"Big5"}],heading:"Legacy multi-byte Chinese (traditional) encodings"},{encodings:[{labels:["cseucpkdfmtjapanese","euc-jp","x-euc-jp"],name:"EUC-JP"},{labels:["csiso2022jp","iso-2022-jp"],name:"ISO-2022-JP"},{labels:["csshiftjis","ms932","ms_kanji","shift-jis","shift_jis","sjis","windows-31j","x-sjis"],name:"Shift_JIS"}],heading:"Legacy multi-byte Japanese encodings"},{encodings:[{labels:["cseuckr","csksc56011987","euc-kr","iso-ir-149","korean","ks_c_5601-1987","ks_c_5601-1989","ksc5601","ksc_5601","windows-949"],name:"EUC-KR"}],heading:"Legacy multi-byte Korean encodings"},{encodings:[{labels:["csiso2022kr","hz-gb-2312","iso-2022-cn","iso-2022-cn-ext","iso-2022-kr"],name:"replacement"},{labels:["utf-16be"],name:"UTF-16BE"},{labels:["utf-16","utf-16le"],name:"UTF-16LE"},{labels:["x-user-defined"],name:"x-user-defined"}],heading:"Legacy miscellaneous encodings"}],_={};b.forEach(function(e){e.encodings.forEach(function(e){e.labels.forEach(function(t){_[t]=e})})});var w={},k={},E,S;function x(e,t){return t&&t[e]||null}function C(e,t){var n=t.indexOf(e);return-1===n?null:n}function A(e){if(!("encoding-indexes"in t))throw Error("Indexes missing. Did you forget to include encoding-indexes.js first?");return t["encoding-indexes"][e]}function T(e){if(e>39419&&e<189e3||e>1237575)return null;if(7457===e)return 59335;var t=0,n=0,r=A("gb18030-ranges"),i;for(i=0;i<r.length;++i){var o=r[i];if(!(o[0]<=e))break;t=o[0],n=o[1]}return n+e-t}function I(e){if(59335===e)return 7457;var t=0,n=0,r=A("gb18030-ranges"),i;for(i=0;i<r.length;++i){var o=r[i];if(!(o[1]<=e))break;t=o[1],n=o[0]}return n+e-t}function j(e){E=E||A("jis0208").map(function(e,t){return r(t,8272,8835)?null:e});var t=E;return t.indexOf(e)}function R(e){S=S||A("big5").map(function(e,t){return t<5024?null:e});var t=S;return 9552===e||9566===e||9569===e||9578===e||21313===e||21317===e?t.lastIndexOf(e):C(e,t)}var B="utf-8";function O(e,t){if(!(this instanceof O))throw TypeError("Called as a function. Did you forget 'new'?");e=void 0!==e?String(e):B,t=s(t),this._encoding=null,this._decoder=null,this._ignoreBOM=!1,this._BOMseen=!1,this._error_mode="replacement",this._do_not_flush=!1;var n=v(e);if(null===n||"replacement"===n.name)throw RangeError("Unknown encoding: "+e);if(!k[n.name])throw Error("Decoder not present. Did you forget to include encoding-indexes.js first?");var r=this;return r._encoding=n,Boolean(t.fatal)&&(r._error_mode="fatal"),Boolean(t.ignoreBOM)&&(r._ignoreBOM=!0),Object.defineProperty||(this.encoding=r._encoding.name.toLowerCase(),this.fatal="fatal"===r._error_mode,this.ignoreBOM=r._ignoreBOM),r}function P(e,n){if(!(this instanceof P))throw TypeError("Called as a function. Did you forget 'new'?");n=s(n),this._encoding=null,this._encoder=null,this._do_not_flush=!1,this._fatal=Boolean(n.fatal)?"fatal":"replacement";var r=this;if(Boolean(n.NONSTANDARD_allowLegacyEncoding)){e=void 0!==e?String(e):B;var i=v(e);if(null===i||"replacement"===i.name)throw RangeError("Unknown encoding: "+e);if(!w[i.name])throw Error("Encoder not present. Did you forget to include encoding-indexes.js first?");r._encoding=i}else r._encoding=v("utf-8"),void 0!==e&&"console"in t&&console.warn("TextEncoder constructor called with encoding label, which is ignored.");return Object.defineProperty||(this.encoding=r._encoding.name.toLowerCase()),r}function N(e){var t=e.fatal,n=0,i=0,o=0,s=128,a=191;this.handler=function(e,l){if(l===h&&0!==o)return o=0,d(t);if(l===h)return p;if(0===o){if(r(l,0,127))return l;if(r(l,194,223))o=1,n=31&l;else if(r(l,224,239))224===l&&(s=160),237===l&&(a=159),o=2,n=15&l;else{if(!r(l,240,244))return d(t);240===l&&(s=144),244===l&&(a=143),o=3,n=7&l}return null}if(!r(l,s,a))return n=o=i=0,s=128,a=191,e.prepend(l),d(t);if(s=128,a=191,n=n<<6|63&l,i+=1,i!==o)return null;var u=n;return n=o=i=0,u}}function D(e){var t=e.fatal;this.handler=function(e,t){if(t===h)return p;if(c(t))return t;var n,i;r(t,128,2047)?(n=1,i=192):r(t,2048,65535)?(n=2,i=224):r(t,65536,1114111)&&(n=3,i=240);for(var o=[(t>>6*n)+i];n>0;){var s=t>>6*(n-1);o.push(128|63&s),n-=1}return o}}function M(e,t){var n=t.fatal;this.handler=function(t,r){if(r===h)return p;if(u(r))return r;var i=e[r-128];return null===i?d(n):i}}function F(e,t){var n=t.fatal;this.handler=function(t,n){if(n===h)return p;if(c(n))return n;var r=C(n,e);return null===r&&m(n),r+128}}function L(e){var t=e.fatal,n=0,i=0,o=0;this.handler=function(e,s){if(s===h&&0===n&&0===i&&0===o)return p;var a;if(s!==h||0===n&&0===i&&0===o||(n=0,i=0,o=0,d(t)),0!==o){a=null,r(s,48,57)&&(a=T(10*(126*(10*(n-129)+i-48)+o-129)+s-48));var l=[i,o,s];return n=0,i=0,o=0,null===a?(e.prepend(l),d(t)):a}if(0!==i)return r(s,129,254)?(o=s,null):(e.prepend([i,s]),n=0,i=0,d(t));if(0!==n){if(r(s,48,57))return i=s,null;var c=n,f=null;n=0;var m=s<127?64:65;return(r(s,64,126)||r(s,128,254))&&(f=190*(c-129)+(s-m)),a=null===f?null:x(f,A("gb18030")),null===a&&u(s)&&e.prepend(s),null===a?d(t):a}return u(s)?s:128===s?8364:r(s,129,254)?(n=s,null):d(t)}}function U(e,t){var n=e.fatal;this.handler=function(e,n){if(n===h)return p;if(c(n))return n;if(58853===n)return m(n);if(t&&8364===n)return 128;var r=C(n,A("gb18030"));if(null!==r){var i=o(r/190)+129,s=r%190,a=s<63?64:65;return[i,s+a]}if(t)return m(n);r=I(n);var l=o(r/10/126/10);r-=10*l*126*10;var u=o(r/10/126);r-=10*u*126;var f=o(r/10),d=r-10*f;return[l+129,u+48,f+129,d+48]}}function q(e){var t=e.fatal,n=0;this.handler=function(e,i){if(i===h&&0!==n)return n=0,d(t);if(i===h&&0===n)return p;if(0!==n){var o=n,s=null;n=0;var a=i<127?64:98;switch((r(i,64,126)||r(i,161,254))&&(s=157*(o-129)+(i-a)),s){case 1133:return[202,772];case 1135:return[202,780];case 1164:return[234,772];case 1166:return[234,780]}var l=null===s?null:x(s,A("big5"));return null===l&&u(i)&&e.prepend(i),null===l?d(t):l}return u(i)?i:r(i,129,254)?(n=i,null):d(t)}}function z(e){var t=e.fatal;this.handler=function(e,t){if(t===h)return p;if(c(t))return t;var n=R(t);if(null===n)return m(t);var r=o(n/157)+129;if(r<161)return m(t);var i=n%157,s=i<63?64:98;return[r,i+s]}}function K(e){var t=e.fatal,n=!1,i=0;this.handler=function(e,o){if(o===h&&0!==i)return i=0,d(t);if(o===h&&0===i)return p;if(142===i&&r(o,161,223))return i=0,65216+o;if(143===i&&r(o,161,254))return n=!0,i=o,null;if(0!==i){var s=i;i=0;var a=null;return r(s,161,254)&&r(o,161,254)&&(a=x(94*(s-161)+(o-161),A(n?"jis0212":"jis0208"))),n=!1,r(o,161,254)||e.prepend(o),null===a?d(t):a}return u(o)?o:142===o||143===o||r(o,161,254)?(i=o,null):d(t)}}function H(e){var t=e.fatal;this.handler=function(e,t){if(t===h)return p;if(c(t))return t;if(165===t)return 92;if(8254===t)return 126;if(r(t,65377,65439))return[142,t-65377+161];8722===t&&(t=65293);var n=C(t,A("jis0208"));if(null===n)return m(t);var i=o(n/94)+161,s=n%94+161;return[i,s]}}function V(e){var t=e.fatal,n=0,i=1,o=2,s=3,a=4,l=5,u=6,c=n,f=n,m=0,g=!1;this.handler=function(e,y){switch(c){default:case n:return 27===y?(c=l,null):r(y,0,127)&&14!==y&&15!==y&&27!==y?(g=!1,y):y===h?p:(g=!1,d(t));case i:return 27===y?(c=l,null):92===y?(g=!1,165):126===y?(g=!1,8254):r(y,0,127)&&14!==y&&15!==y&&27!==y&&92!==y&&126!==y?(g=!1,y):y===h?p:(g=!1,d(t));case o:return 27===y?(c=l,null):r(y,33,95)?(g=!1,65344+y):y===h?p:(g=!1,d(t));case s:return 27===y?(c=l,null):r(y,33,126)?(g=!1,m=y,c=a,null):y===h?p:(g=!1,d(t));case a:if(27===y)return c=l,d(t);if(r(y,33,126)){c=s;var v=94*(m-33)+y-33,b=x(v,A("jis0208"));return null===b?d(t):b}return y===h?(c=s,e.prepend(y),d(t)):(c=s,d(t));case l:return 36===y||40===y?(m=y,c=u,null):(e.prepend(y),g=!1,c=f,d(t));case u:var _=m;m=0;var w=null;if(40===_&&66===y&&(w=n),40===_&&74===y&&(w=i),40===_&&73===y&&(w=o),36!==_||64!==y&&66!==y||(w=s),null!==w){c=c=w;var k=g;return g=!0,k?d(t):null}return e.prepend([_,y]),g=!1,c=f,d(t)}}}function $(e){var t=e.fatal,n=0,r=1,i=2,s=n;this.handler=function(e,t){if(t===h&&s!==n)return e.prepend(t),s=n,[27,40,66];if(t===h&&s===n)return p;if(!(s!==n&&s!==r||14!==t&&15!==t&&27!==t))return m(65533);if(s===n&&c(t))return t;if(s===r&&(c(t)&&92!==t&&126!==t||165==t||8254==t)){if(c(t))return t;if(165===t)return 92;if(8254===t)return 126}if(c(t)&&s!==n)return e.prepend(t),s=n,[27,40,66];if((165===t||8254===t)&&s!==r)return e.prepend(t),s=r,[27,40,74];8722===t&&(t=65293);var a=C(t,A("jis0208"));if(null===a)return m(t);if(s!==i)return e.prepend(t),s=i,[27,36,66];var l=o(a/94)+33,u=a%94+33;return[l,u]}}function W(e){var t=e.fatal,n=0;this.handler=function(e,i){if(i===h&&0!==n)return n=0,d(t);if(i===h&&0===n)return p;if(0!==n){var o=n,s=null;n=0;var a=i<127?64:65,l=o<160?129:193;if((r(i,64,126)||r(i,128,252))&&(s=188*(o-l)+i-a),r(s,8836,10715))return 48508+s;var c=null===s?null:x(s,A("jis0208"));return null===c&&u(i)&&e.prepend(i),null===c?d(t):c}return u(i)||128===i?i:r(i,161,223)?65216+i:r(i,129,159)||r(i,224,252)?(n=i,null):d(t)}}function G(e){var t=e.fatal;this.handler=function(e,t){if(t===h)return p;if(c(t)||128===t)return t;if(165===t)return 92;if(8254===t)return 126;if(r(t,65377,65439))return t-65377+161;8722===t&&(t=65293);var n=j(t);if(null===n)return m(t);var i=o(n/188),s=i<31?129:193,a=n%188,l=a<63?64:65;return[i+s,a+l]}}function Y(e){var t=e.fatal,n=0;this.handler=function(e,i){if(i===h&&0!==n)return n=0,d(t);if(i===h&&0===n)return p;if(0!==n){var o=n,s=null;n=0,r(i,65,254)&&(s=190*(o-129)+(i-65));var a=null===s?null:x(s,A("euc-kr"));return null===s&&u(i)&&e.prepend(i),null===a?d(t):a}return u(i)?i:r(i,129,254)?(n=i,null):d(t)}}function Z(e){var t=e.fatal;this.handler=function(e,t){if(t===h)return p;if(c(t))return t;var n=C(t,A("euc-kr"));if(null===n)return m(t);var r=o(n/190)+129,i=n%190+65;return[r,i]}}function J(e,t){var n=e>>8,r=255&e;return t?[n,r]:[r,n]}function Q(e,t){var n=t.fatal,i=null,o=null;this.handler=function(t,s){if(s===h&&(null!==i||null!==o))return d(n);if(s===h&&null===i&&null===o)return p;if(null===i)return i=s,null;var a;if(a=e?(i<<8)+s:(s<<8)+i,i=null,null!==o){var l=o;return o=null,r(a,56320,57343)?65536+1024*(l-55296)+(a-56320):(t.prepend(J(a,e)),d(n))}return r(a,55296,56319)?(o=a,null):r(a,56320,57343)?d(n):a}}function X(e,t){var n=t.fatal;this.handler=function(t,n){if(n===h)return p;if(r(n,0,65535))return J(n,e);var i=J(55296+(n-65536>>10),e),o=J(56320+(n-65536&1023),e);return i.concat(o)}}function ee(e){var t=e.fatal;this.handler=function(e,t){return t===h?p:u(t)?t:63360+t-128}}function te(e){var t=e.fatal;this.handler=function(e,t){return t===h?p:c(t)?t:r(t,63360,63487)?t-63360+128:m(t)}}Object.defineProperty&&(Object.defineProperty(O.prototype,"encoding",{get:function(){return this._encoding.name.toLowerCase()}}),Object.defineProperty(O.prototype,"fatal",{get:function(){return"fatal"===this._error_mode}}),Object.defineProperty(O.prototype,"ignoreBOM",{get:function(){return this._ignoreBOM}})),O.prototype.decode=function e(t,n){var r;r="object"==typeof t&&t instanceof ArrayBuffer?new Uint8Array(t):"object"==typeof t&&"buffer"in t&&t.buffer instanceof ArrayBuffer?new Uint8Array(t.buffer,t.byteOffset,t.byteLength):new Uint8Array(0),n=s(n),this._do_not_flush||(this._decoder=k[this._encoding.name]({fatal:"fatal"===this._error_mode}),this._BOMseen=!1),this._do_not_flush=Boolean(n.stream);for(var o=new f(r),a=[],u;;){var c=o.read();if(c===h)break;if(u=this._decoder.handler(o,c),u===p)break;null!==u&&(Array.isArray(u)?a.push.apply(a,u):a.push(u))}if(!this._do_not_flush){do{if(u=this._decoder.handler(o,o.read()),u===p)break;null!==u&&(Array.isArray(u)?a.push.apply(a,u):a.push(u))}while(!o.endOfStream());this._decoder=null}function d(e){return!i(["UTF-8","UTF-16LE","UTF-16BE"],this._encoding.name)||this._ignoreBOM||this._BOMseen||(e.length>0&&65279===e[0]?(this._BOMseen=!0,e.shift()):e.length>0&&(this._BOMseen=!0)),l(e)}return d.call(this,a)},Object.defineProperty&&Object.defineProperty(P.prototype,"encoding",{get:function(){return this._encoding.name.toLowerCase()}}),P.prototype.encode=function e(t,n){t=void 0===t?"":String(t),n=s(n),this._do_not_flush||(this._encoder=w[this._encoding.name]({fatal:"fatal"===this._fatal})),this._do_not_flush=Boolean(n.stream);for(var r=new f(a(t)),i=[],o;;){var l=r.read();if(l===h)break;if(o=this._encoder.handler(r,l),o===p)break;Array.isArray(o)?i.push.apply(i,o):i.push(o)}if(!this._do_not_flush){for(;o=this._encoder.handler(r,r.read()),o!==p;)Array.isArray(o)?i.push.apply(i,o):i.push(o);this._encoder=null}return new Uint8Array(i)},w["UTF-8"]=function(e){return new D(e)},k["UTF-8"]=function(e){return new N(e)},"encoding-indexes"in t&&b.forEach(function(e){"Legacy single-byte encodings"===e.heading&&e.encodings.forEach(function(e){var t=e.name,n=A(t.toLowerCase());k[t]=function(e){return new M(n,e)},w[t]=function(e){return new F(n,e)}})}),k.GBK=function(e){return new L(e)},w.GBK=function(e){return new U(e,!0)},w.gb18030=function(e){return new U(e)},k.gb18030=function(e){return new L(e)},w.Big5=function(e){return new z(e)},k.Big5=function(e){return new q(e)},w["EUC-JP"]=function(e){return new H(e)},k["EUC-JP"]=function(e){return new K(e)},w["ISO-2022-JP"]=function(e){return new $(e)},k["ISO-2022-JP"]=function(e){return new V(e)},w.Shift_JIS=function(e){return new G(e)},k.Shift_JIS=function(e){return new W(e)},w["EUC-KR"]=function(e){return new Z(e)},k["EUC-KR"]=function(e){return new Y(e)},w["UTF-16BE"]=function(e){return new X(!0,e)},k["UTF-16BE"]=function(e){return new Q(!0,e)},w["UTF-16LE"]=function(e){return new X(!1,e)},k["UTF-16LE"]=function(e){return new Q(!1,e)},w["x-user-defined"]=function(e){return new te(e)},k["x-user-defined"]=function(e){return new ee(e)},t.TextEncoder||(t.TextEncoder=P),t.TextDecoder||(t.TextDecoder=O),e.exports&&(e.exports={TextEncoder:t.TextEncoder,TextDecoder:t.TextDecoder,EncodingIndexes:t["encoding-indexes"]})}(this||{})},function(e,t,n){!function(t){"use strict";e.exports&&(e.exports=t),t["encoding-indexes"]={big5:[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,17392,19506,17923,17830,17784,160359,19831,17843,162993,19682,163013,15253,18230,18244,19527,19520,148159,144919,160594,159371,159954,19543,172881,18255,17882,19589,162924,19719,19108,18081,158499,29221,154196,137827,146950,147297,26189,22267,null,32149,22813,166841,15860,38708,162799,23515,138590,23204,13861,171696,23249,23479,23804,26478,34195,170309,29793,29853,14453,138579,145054,155681,16108,153822,15093,31484,40855,147809,166157,143850,133770,143966,17162,33924,40854,37935,18736,34323,22678,38730,37400,31184,31282,26208,27177,34973,29772,31685,26498,31276,21071,36934,13542,29636,155065,29894,40903,22451,18735,21580,16689,145038,22552,31346,162661,35727,18094,159368,16769,155033,31662,140476,40904,140481,140489,140492,40905,34052,144827,16564,40906,17633,175615,25281,28782,40907,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,12736,12737,12738,12739,12740,131340,12741,131281,131277,12742,12743,131275,139240,12744,131274,12745,12746,12747,12748,131342,12749,12750,256,193,461,192,274,201,282,200,332,211,465,210,null,7870,null,7872,202,257,225,462,224,593,275,233,283,232,299,237,464,236,333,243,466,242,363,250,468,249,470,472,474,476,252,null,7871,null,7873,234,609,9178,9179,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,172969,135493,null,25866,null,null,20029,28381,40270,37343,null,null,161589,25745,20250,20264,20392,20822,20852,20892,20964,21153,21160,21307,21326,21457,21464,22242,22768,22788,22791,22834,22836,23398,23454,23455,23706,24198,24635,25993,26622,26628,26725,27982,28860,30005,32420,32428,32442,32455,32463,32479,32518,32567,33402,33487,33647,35270,35774,35810,36710,36711,36718,29713,31996,32205,26950,31433,21031,null,null,null,null,37260,30904,37214,32956,null,36107,33014,133607,null,null,32927,40647,19661,40393,40460,19518,171510,159758,40458,172339,13761,null,28314,33342,29977,null,18705,39532,39567,40857,31111,164972,138698,132560,142054,20004,20097,20096,20103,20159,20203,20279,13388,20413,15944,20483,20616,13437,13459,13477,20870,22789,20955,20988,20997,20105,21113,21136,21287,13767,21417,13649,21424,13651,21442,21539,13677,13682,13953,21651,21667,21684,21689,21712,21743,21784,21795,21800,13720,21823,13733,13759,21975,13765,163204,21797,null,134210,134421,151851,21904,142534,14828,131905,36422,150968,169189,16467,164030,30586,142392,14900,18389,164189,158194,151018,25821,134524,135092,134357,135412,25741,36478,134806,134155,135012,142505,164438,148691,null,134470,170573,164073,18420,151207,142530,39602,14951,169460,16365,13574,152263,169940,161992,142660,40302,38933,null,17369,155813,25780,21731,142668,142282,135287,14843,135279,157402,157462,162208,25834,151634,134211,36456,139681,166732,132913,null,18443,131497,16378,22643,142733,null,148936,132348,155799,134988,134550,21881,16571,17338,null,19124,141926,135325,33194,39157,134556,25465,14846,141173,36288,22177,25724,15939,null,173569,134665,142031,142537,null,135368,145858,14738,14854,164507,13688,155209,139463,22098,134961,142514,169760,13500,27709,151099,null,null,161140,142987,139784,173659,167117,134778,134196,157724,32659,135375,141315,141625,13819,152035,134796,135053,134826,16275,134960,134471,135503,134732,null,134827,134057,134472,135360,135485,16377,140950,25650,135085,144372,161337,142286,134526,134527,142417,142421,14872,134808,135367,134958,173618,158544,167122,167321,167114,38314,21708,33476,21945,null,171715,39974,39606,161630,142830,28992,33133,33004,23580,157042,33076,14231,21343,164029,37302,134906,134671,134775,134907,13789,151019,13833,134358,22191,141237,135369,134672,134776,135288,135496,164359,136277,134777,151120,142756,23124,135197,135198,135413,135414,22428,134673,161428,164557,135093,134779,151934,14083,135094,135552,152280,172733,149978,137274,147831,164476,22681,21096,13850,153405,31666,23400,18432,19244,40743,18919,39967,39821,154484,143677,22011,13810,22153,20008,22786,138177,194680,38737,131206,20059,20155,13630,23587,24401,24516,14586,25164,25909,27514,27701,27706,28780,29227,20012,29357,149737,32594,31035,31993,32595,156266,13505,null,156491,32770,32896,157202,158033,21341,34916,35265,161970,35744,36125,38021,38264,38271,38376,167439,38886,39029,39118,39134,39267,17e4,40060,40479,40644,27503,63751,20023,131207,38429,25143,38050,null,20539,28158,171123,40870,15817,34959,147790,28791,23797,19232,152013,13657,154928,24866,166450,36775,37366,29073,26393,29626,144001,172295,15499,137600,19216,30948,29698,20910,165647,16393,27235,172730,16931,34319,133743,31274,170311,166634,38741,28749,21284,139390,37876,30425,166371,40871,30685,20131,20464,20668,20015,20247,40872,21556,32139,22674,22736,138678,24210,24217,24514,141074,25995,144377,26905,27203,146531,27903,null,29184,148741,29580,16091,150035,23317,29881,35715,154788,153237,31379,31724,31939,32364,33528,34199,40873,34960,40874,36537,40875,36815,34143,39392,37409,40876,167353,136255,16497,17058,23066,null,null,null,39016,26475,17014,22333,null,34262,149883,33471,160013,19585,159092,23931,158485,159678,40877,40878,23446,40879,26343,32347,28247,31178,15752,17603,143958,141206,17306,17718,null,23765,146202,35577,23672,15634,144721,23928,40882,29015,17752,147692,138787,19575,14712,13386,131492,158785,35532,20404,131641,22975,33132,38998,170234,24379,134047,null,139713,166253,16642,18107,168057,16135,40883,172469,16632,14294,18167,158790,16764,165554,160767,17773,14548,152730,17761,17691,19849,19579,19830,17898,16328,150287,13921,17630,17597,16877,23870,23880,23894,15868,14351,23972,23993,14368,14392,24130,24253,24357,24451,14600,14612,14655,14669,24791,24893,23781,14729,25015,25017,25039,14776,25132,25232,25317,25368,14840,22193,14851,25570,25595,25607,25690,14923,25792,23829,22049,40863,14999,25990,15037,26111,26195,15090,26258,15138,26390,15170,26532,26624,15192,26698,26756,15218,15217,15227,26889,26947,29276,26980,27039,27013,15292,27094,15325,27237,27252,27249,27266,15340,27289,15346,27307,27317,27348,27382,27521,27585,27626,27765,27818,15563,27906,27910,27942,28033,15599,28068,28081,28181,28184,28201,28294,166336,28347,28386,28378,40831,28392,28393,28452,28468,15686,147265,28545,28606,15722,15733,29111,23705,15754,28716,15761,28752,28756,28783,28799,28809,131877,17345,13809,134872,147159,22462,159443,28990,153568,13902,27042,166889,23412,31305,153825,169177,31333,31357,154028,31419,31408,31426,31427,29137,156813,16842,31450,31453,31466,16879,21682,154625,31499,31573,31529,152334,154878,31650,31599,33692,154548,158847,31696,33825,31634,31672,154912,15789,154725,33938,31738,31750,31797,154817,31812,31875,149634,31910,26237,148856,31945,31943,31974,31860,31987,31989,31950,32359,17693,159300,32093,159446,29837,32137,32171,28981,32179,32210,147543,155689,32228,15635,32245,137209,32229,164717,32285,155937,155994,32366,32402,17195,37996,32295,32576,32577,32583,31030,156368,39393,32663,156497,32675,136801,131176,17756,145254,17667,164666,32762,156809,32773,32776,32797,32808,32815,172167,158915,32827,32828,32865,141076,18825,157222,146915,157416,26405,32935,166472,33031,33050,22704,141046,27775,156824,151480,25831,136330,33304,137310,27219,150117,150165,17530,33321,133901,158290,146814,20473,136445,34018,33634,158474,149927,144688,137075,146936,33450,26907,194964,16859,34123,33488,33562,134678,137140,14017,143741,144730,33403,33506,33560,147083,159139,158469,158615,144846,15807,33565,21996,33669,17675,159141,33708,33729,33747,13438,159444,27223,34138,13462,159298,143087,33880,154596,33905,15827,17636,27303,33866,146613,31064,33960,158614,159351,159299,34014,33807,33681,17568,33939,34020,154769,16960,154816,17731,34100,23282,159385,17703,34163,17686,26559,34326,165413,165435,34241,159880,34306,136578,159949,194994,17770,34344,13896,137378,21495,160666,34430,34673,172280,34798,142375,34737,34778,34831,22113,34412,26710,17935,34885,34886,161248,146873,161252,34910,34972,18011,34996,34997,25537,35013,30583,161551,35207,35210,35238,35241,35239,35260,166437,35303,162084,162493,35484,30611,37374,35472,162393,31465,162618,147343,18195,162616,29052,35596,35615,152624,152933,35647,35660,35661,35497,150138,35728,35739,35503,136927,17941,34895,35995,163156,163215,195028,14117,163155,36054,163224,163261,36114,36099,137488,36059,28764,36113,150729,16080,36215,36265,163842,135188,149898,15228,164284,160012,31463,36525,36534,36547,37588,36633,36653,164709,164882,36773,37635,172703,133712,36787,18730,166366,165181,146875,24312,143970,36857,172052,165564,165121,140069,14720,159447,36919,165180,162494,36961,165228,165387,37032,165651,37060,165606,37038,37117,37223,15088,37289,37316,31916,166195,138889,37390,27807,37441,37474,153017,37561,166598,146587,166668,153051,134449,37676,37739,166625,166891,28815,23235,166626,166629,18789,37444,166892,166969,166911,37747,37979,36540,38277,38310,37926,38304,28662,17081,140922,165592,135804,146990,18911,27676,38523,38550,16748,38563,159445,25050,38582,30965,166624,38589,21452,18849,158904,131700,156688,168111,168165,150225,137493,144138,38705,34370,38710,18959,17725,17797,150249,28789,23361,38683,38748,168405,38743,23370,168427,38751,37925,20688,143543,143548,38793,38815,38833,38846,38848,38866,38880,152684,38894,29724,169011,38911,38901,168989,162170,19153,38964,38963,38987,39014,15118,160117,15697,132656,147804,153350,39114,39095,39112,39111,19199,159015,136915,21936,39137,39142,39148,37752,39225,150057,19314,170071,170245,39413,39436,39483,39440,39512,153381,14020,168113,170965,39648,39650,170757,39668,19470,39700,39725,165376,20532,39732,158120,14531,143485,39760,39744,171326,23109,137315,39822,148043,39938,39935,39948,171624,40404,171959,172434,172459,172257,172323,172511,40318,40323,172340,40462,26760,40388,139611,172435,172576,137531,172595,40249,172217,172724,40592,40597,40606,40610,19764,40618,40623,148324,40641,15200,14821,15645,20274,14270,166955,40706,40712,19350,37924,159138,40727,40726,40761,22175,22154,40773,39352,168075,38898,33919,40802,40809,31452,40846,29206,19390,149877,149947,29047,150008,148296,150097,29598,166874,137466,31135,166270,167478,37737,37875,166468,37612,37761,37835,166252,148665,29207,16107,30578,31299,28880,148595,148472,29054,137199,28835,137406,144793,16071,137349,152623,137208,14114,136955,137273,14049,137076,137425,155467,14115,136896,22363,150053,136190,135848,136134,136374,34051,145062,34051,33877,149908,160101,146993,152924,147195,159826,17652,145134,170397,159526,26617,14131,15381,15847,22636,137506,26640,16471,145215,147681,147595,147727,158753,21707,22174,157361,22162,135135,134056,134669,37830,166675,37788,20216,20779,14361,148534,20156,132197,131967,20299,20362,153169,23144,131499,132043,14745,131850,132116,13365,20265,131776,167603,131701,35546,131596,20120,20685,20749,20386,20227,150030,147082,20290,20526,20588,20609,20428,20453,20568,20732,20825,20827,20829,20830,28278,144789,147001,147135,28018,137348,147081,20904,20931,132576,17629,132259,132242,132241,36218,166556,132878,21081,21156,133235,21217,37742,18042,29068,148364,134176,149932,135396,27089,134685,29817,16094,29849,29716,29782,29592,19342,150204,147597,21456,13700,29199,147657,21940,131909,21709,134086,22301,37469,38644,37734,22493,22413,22399,13886,22731,23193,166470,136954,137071,136976,23084,22968,37519,23166,23247,23058,153926,137715,137313,148117,14069,27909,29763,23073,155267,23169,166871,132115,37856,29836,135939,28933,18802,37896,166395,37821,14240,23582,23710,24158,24136,137622,137596,146158,24269,23375,137475,137476,14081,137376,14045,136958,14035,33066,166471,138682,144498,166312,24332,24334,137511,137131,23147,137019,23364,34324,161277,34912,24702,141408,140843,24539,16056,140719,140734,168072,159603,25024,131134,131142,140827,24985,24984,24693,142491,142599,149204,168269,25713,149093,142186,14889,142114,144464,170218,142968,25399,173147,25782,25393,25553,149987,142695,25252,142497,25659,25963,26994,15348,143502,144045,149897,144043,21773,144096,137433,169023,26318,144009,143795,15072,16784,152964,166690,152975,136956,152923,152613,30958,143619,137258,143924,13412,143887,143746,148169,26254,159012,26219,19347,26160,161904,138731,26211,144082,144097,26142,153714,14545,145466,145340,15257,145314,144382,29904,15254,26511,149034,26806,26654,15300,27326,14435,145365,148615,27187,27218,27337,27397,137490,25873,26776,27212,15319,27258,27479,147392,146586,37792,37618,166890,166603,37513,163870,166364,37991,28069,28427,149996,28007,147327,15759,28164,147516,23101,28170,22599,27940,30786,28987,148250,148086,28913,29264,29319,29332,149391,149285,20857,150180,132587,29818,147192,144991,150090,149783,155617,16134,16049,150239,166947,147253,24743,16115,29900,29756,37767,29751,17567,159210,17745,30083,16227,150745,150790,16216,30037,30323,173510,15129,29800,166604,149931,149902,15099,15821,150094,16127,149957,149747,37370,22322,37698,166627,137316,20703,152097,152039,30584,143922,30478,30479,30587,149143,145281,14942,149744,29752,29851,16063,150202,150215,16584,150166,156078,37639,152961,30750,30861,30856,30930,29648,31065,161601,153315,16654,31131,33942,31141,27181,147194,31290,31220,16750,136934,16690,37429,31217,134476,149900,131737,146874,137070,13719,21867,13680,13994,131540,134157,31458,23129,141045,154287,154268,23053,131675,30960,23082,154566,31486,16889,31837,31853,16913,154547,155324,155302,31949,150009,137136,31886,31868,31918,27314,32220,32263,32211,32590,156257,155996,162632,32151,155266,17002,158581,133398,26582,131150,144847,22468,156690,156664,149858,32733,31527,133164,154345,154947,31500,155150,39398,34373,39523,27164,144447,14818,150007,157101,39455,157088,33920,160039,158929,17642,33079,17410,32966,33033,33090,157620,39107,158274,33378,33381,158289,33875,159143,34320,160283,23174,16767,137280,23339,137377,23268,137432,34464,195004,146831,34861,160802,23042,34926,20293,34951,35007,35046,35173,35149,153219,35156,161669,161668,166901,166873,166812,166393,16045,33955,18165,18127,14322,35389,35356,169032,24397,37419,148100,26068,28969,28868,137285,40301,35999,36073,163292,22938,30659,23024,17262,14036,36394,36519,150537,36656,36682,17140,27736,28603,140065,18587,28537,28299,137178,39913,14005,149807,37051,37015,21873,18694,37307,37892,166475,16482,166652,37927,166941,166971,34021,35371,38297,38311,38295,38294,167220,29765,16066,149759,150082,148458,16103,143909,38543,167655,167526,167525,16076,149997,150136,147438,29714,29803,16124,38721,168112,26695,18973,168083,153567,38749,37736,166281,166950,166703,156606,37562,23313,35689,18748,29689,147995,38811,38769,39224,134950,24001,166853,150194,38943,169178,37622,169431,37349,17600,166736,150119,166756,39132,166469,16128,37418,18725,33812,39227,39245,162566,15869,39323,19311,39338,39516,166757,153800,27279,39457,23294,39471,170225,19344,170312,39356,19389,19351,37757,22642,135938,22562,149944,136424,30788,141087,146872,26821,15741,37976,14631,24912,141185,141675,24839,40015,40019,40059,39989,39952,39807,39887,171565,39839,172533,172286,40225,19630,147716,40472,19632,40204,172468,172269,172275,170287,40357,33981,159250,159711,158594,34300,17715,159140,159364,159216,33824,34286,159232,145367,155748,31202,144796,144960,18733,149982,15714,37851,37566,37704,131775,30905,37495,37965,20452,13376,36964,152925,30781,30804,30902,30795,137047,143817,149825,13978,20338,28634,28633,28702,28702,21524,147893,22459,22771,22410,40214,22487,28980,13487,147884,29163,158784,151447,23336,137141,166473,24844,23246,23051,17084,148616,14124,19323,166396,37819,37816,137430,134941,33906,158912,136211,148218,142374,148417,22932,146871,157505,32168,155995,155812,149945,149899,166394,37605,29666,16105,29876,166755,137375,16097,150195,27352,29683,29691,16086,150078,150164,137177,150118,132007,136228,149989,29768,149782,28837,149878,37508,29670,37727,132350,37681,166606,166422,37766,166887,153045,18741,166530,29035,149827,134399,22180,132634,134123,134328,21762,31172,137210,32254,136898,150096,137298,17710,37889,14090,166592,149933,22960,137407,137347,160900,23201,14050,146779,14e3,37471,23161,166529,137314,37748,15565,133812,19094,14730,20724,15721,15692,136092,29045,17147,164376,28175,168164,17643,27991,163407,28775,27823,15574,147437,146989,28162,28428,15727,132085,30033,14012,13512,18048,16090,18545,22980,37486,18750,36673,166940,158656,22546,22472,14038,136274,28926,148322,150129,143331,135856,140221,26809,26983,136088,144613,162804,145119,166531,145366,144378,150687,27162,145069,158903,33854,17631,17614,159014,159057,158850,159710,28439,160009,33597,137018,33773,158848,159827,137179,22921,23170,137139,23137,23153,137477,147964,14125,23023,137020,14023,29070,37776,26266,148133,23150,23083,148115,27179,147193,161590,148571,148170,28957,148057,166369,20400,159016,23746,148686,163405,148413,27148,148054,135940,28838,28979,148457,15781,27871,194597,150095,32357,23019,23855,15859,24412,150109,137183,32164,33830,21637,146170,144128,131604,22398,133333,132633,16357,139166,172726,28675,168283,23920,29583,31955,166489,168992,20424,32743,29389,29456,162548,29496,29497,153334,29505,29512,16041,162584,36972,29173,149746,29665,33270,16074,30476,16081,27810,22269,29721,29726,29727,16098,16112,16116,16122,29907,16142,16211,30018,30061,30066,30093,16252,30152,30172,16320,30285,16343,30324,16348,30330,151388,29064,22051,35200,22633,16413,30531,16441,26465,16453,13787,30616,16490,16495,23646,30654,30667,22770,30744,28857,30748,16552,30777,30791,30801,30822,33864,152885,31027,26627,31026,16643,16649,31121,31129,36795,31238,36796,16743,31377,16818,31420,33401,16836,31439,31451,16847,20001,31586,31596,31611,31762,31771,16992,17018,31867,31900,17036,31928,17044,31981,36755,28864,134351,32207,32212,32208,32253,32686,32692,29343,17303,32800,32805,31545,32814,32817,32852,15820,22452,28832,32951,33001,17389,33036,29482,33038,33042,30048,33044,17409,15161,33110,33113,33114,17427,22586,33148,33156,17445,33171,17453,33189,22511,33217,33252,33364,17551,33446,33398,33482,33496,33535,17584,33623,38505,27018,33797,28917,33892,24803,33928,17668,33982,34017,34040,34064,34104,34130,17723,34159,34160,34272,17783,34418,34450,34482,34543,38469,34699,17926,17943,34990,35071,35108,35143,35217,162151,35369,35384,35476,35508,35921,36052,36082,36124,18328,22623,36291,18413,20206,36410,21976,22356,36465,22005,36528,18487,36558,36578,36580,36589,36594,36791,36801,36810,36812,36915,39364,18605,39136,37395,18718,37416,37464,37483,37553,37550,37567,37603,37611,37619,37620,37629,37699,37764,37805,18757,18769,40639,37911,21249,37917,37933,37950,18794,37972,38009,38189,38306,18855,38388,38451,18917,26528,18980,38720,18997,38834,38850,22100,19172,24808,39097,19225,39153,22596,39182,39193,20916,39196,39223,39234,39261,39266,19312,39365,19357,39484,39695,31363,39785,39809,39901,39921,39924,19565,39968,14191,138178,40265,39994,40702,22096,40339,40381,40384,40444,38134,36790,40571,40620,40625,40637,40646,38108,40674,40689,40696,31432,40772,131220,131767,132e3,26906,38083,22956,132311,22592,38081,14265,132565,132629,132726,136890,22359,29043,133826,133837,134079,21610,194619,134091,21662,134139,134203,134227,134245,134268,24807,134285,22138,134325,134365,134381,134511,134578,134600,26965,39983,34725,134660,134670,134871,135056,134957,134771,23584,135100,24075,135260,135247,135286,26398,135291,135304,135318,13895,135359,135379,135471,135483,21348,33965,135907,136053,135990,35713,136567,136729,137155,137159,20088,28859,137261,137578,137773,137797,138282,138352,138412,138952,25283,138965,139029,29080,26709,139333,27113,14024,139900,140247,140282,141098,141425,141647,33533,141671,141715,142037,35237,142056,36768,142094,38840,142143,38983,39613,142412,null,142472,142519,154600,142600,142610,142775,142741,142914,143220,143308,143411,143462,144159,144350,24497,26184,26303,162425,144743,144883,29185,149946,30679,144922,145174,32391,131910,22709,26382,26904,146087,161367,155618,146961,147129,161278,139418,18640,19128,147737,166554,148206,148237,147515,148276,148374,150085,132554,20946,132625,22943,138920,15294,146687,148484,148694,22408,149108,14747,149295,165352,170441,14178,139715,35678,166734,39382,149522,149755,150037,29193,150208,134264,22885,151205,151430,132985,36570,151596,21135,22335,29041,152217,152601,147274,150183,21948,152646,152686,158546,37332,13427,152895,161330,152926,18200,152930,152934,153543,149823,153693,20582,13563,144332,24798,153859,18300,166216,154286,154505,154630,138640,22433,29009,28598,155906,162834,36950,156082,151450,35682,156674,156746,23899,158711,36662,156804,137500,35562,150006,156808,147439,156946,19392,157119,157365,141083,37989,153569,24981,23079,194765,20411,22201,148769,157436,20074,149812,38486,28047,158909,13848,35191,157593,157806,156689,157790,29151,157895,31554,168128,133649,157990,37124,158009,31301,40432,158202,39462,158253,13919,156777,131105,31107,158260,158555,23852,144665,33743,158621,18128,158884,30011,34917,159150,22710,14108,140685,159819,160205,15444,160384,160389,37505,139642,160395,37680,160486,149968,27705,38047,160848,134904,34855,35061,141606,164979,137137,28344,150058,137248,14756,14009,23568,31203,17727,26294,171181,170148,35139,161740,161880,22230,16607,136714,14753,145199,164072,136133,29101,33638,162269,168360,23143,19639,159919,166315,162301,162314,162571,163174,147834,31555,31102,163849,28597,172767,27139,164632,21410,159239,37823,26678,38749,164207,163875,158133,136173,143919,163912,23941,166960,163971,22293,38947,166217,23979,149896,26046,27093,21458,150181,147329,15377,26422,163984,164084,164142,139169,164175,164233,164271,164378,164614,164655,164746,13770,164968,165546,18682,25574,166230,30728,37461,166328,17394,166375,17375,166376,166726,166868,23032,166921,36619,167877,168172,31569,168208,168252,15863,168286,150218,36816,29327,22155,169191,169449,169392,169400,169778,170193,170313,170346,170435,170536,170766,171354,171419,32415,171768,171811,19620,38215,172691,29090,172799,19857,36882,173515,19868,134300,36798,21953,36794,140464,36793,150163,17673,32383,28502,27313,20202,13540,166700,161949,14138,36480,137205,163876,166764,166809,162366,157359,15851,161365,146615,153141,153942,20122,155265,156248,22207,134765,36366,23405,147080,150686,25566,25296,137206,137339,25904,22061,154698,21530,152337,15814,171416,19581,22050,22046,32585,155352,22901,146752,34672,19996,135146,134473,145082,33047,40286,36120,30267,40005,30286,30649,37701,21554,33096,33527,22053,33074,33816,32957,21994,31074,22083,21526,134813,13774,22021,22001,26353,164578,13869,30004,22e3,21946,21655,21874,134209,134294,24272,151880,134774,142434,134818,40619,32090,21982,135285,25245,38765,21652,36045,29174,37238,25596,25529,25598,21865,142147,40050,143027,20890,13535,134567,20903,21581,21790,21779,30310,36397,157834,30129,32950,34820,34694,35015,33206,33820,135361,17644,29444,149254,23440,33547,157843,22139,141044,163119,147875,163187,159440,160438,37232,135641,37384,146684,173737,134828,134905,29286,138402,18254,151490,163833,135147,16634,40029,25887,142752,18675,149472,171388,135148,134666,24674,161187,135149,null,155720,135559,29091,32398,40272,19994,19972,13687,23309,27826,21351,13996,14812,21373,13989,149016,22682,150382,33325,21579,22442,154261,133497,null,14930,140389,29556,171692,19721,39917,146686,171824,19547,151465,169374,171998,33884,146870,160434,157619,145184,25390,32037,147191,146988,14890,36872,21196,15988,13946,17897,132238,30272,23280,134838,30842,163630,22695,16575,22140,39819,23924,30292,173108,40581,19681,30201,14331,24857,143578,148466,null,22109,135849,22439,149859,171526,21044,159918,13741,27722,40316,31830,39737,22494,137068,23635,25811,169168,156469,160100,34477,134440,159010,150242,134513,null,20990,139023,23950,38659,138705,40577,36940,31519,39682,23761,31651,25192,25397,39679,31695,39722,31870,39726,31810,31878,39957,31740,39689,40727,39963,149822,40794,21875,23491,20477,40600,20466,21088,15878,21201,22375,20566,22967,24082,38856,40363,36700,21609,38836,39232,38842,21292,24880,26924,21466,39946,40194,19515,38465,27008,20646,30022,137069,39386,21107,null,37209,38529,37212,null,37201,167575,25471,159011,27338,22033,37262,30074,25221,132092,29519,31856,154657,146685,null,149785,30422,39837,20010,134356,33726,34882,null,23626,27072,20717,22394,21023,24053,20174,27697,131570,20281,21660,21722,21146,36226,13822,24332,13811,null,27474,37244,40869,39831,38958,39092,39610,40616,40580,29050,31508,null,27642,34840,32632,null,22048,173642,36471,40787,null,36308,36431,40476,36353,25218,164733,36392,36469,31443,150135,31294,30936,27882,35431,30215,166490,40742,27854,34774,30147,172722,30803,194624,36108,29410,29553,35629,29442,29937,36075,150203,34351,24506,34976,17591,null,137275,159237,null,35454,140571,null,24829,30311,39639,40260,37742,39823,34805,null,34831,36087,29484,38689,39856,13782,29362,19463,31825,39242,155993,24921,19460,40598,24957,null,22367,24943,25254,25145,25294,14940,25058,21418,144373,25444,26626,13778,23895,166850,36826,167481,null,20697,138566,30982,21298,38456,134971,16485,null,30718,null,31938,155418,31962,31277,32870,32867,32077,29957,29938,35220,33306,26380,32866,160902,32859,29936,33027,30500,35209,157644,30035,159441,34729,34766,33224,34700,35401,36013,35651,30507,29944,34010,13877,27058,36262,null,35241,29800,28089,34753,147473,29927,15835,29046,24740,24988,15569,29026,24695,null,32625,166701,29264,24809,19326,21024,15384,146631,155351,161366,152881,137540,135934,170243,159196,159917,23745,156077,166415,145015,131310,157766,151310,17762,23327,156492,40784,40614,156267,12288,65292,12289,12290,65294,8231,65307,65306,65311,65281,65072,8230,8229,65104,65105,65106,183,65108,65109,65110,65111,65372,8211,65073,8212,65075,9588,65076,65103,65288,65289,65077,65078,65371,65373,65079,65080,12308,12309,65081,65082,12304,12305,65083,65084,12298,12299,65085,65086,12296,12297,65087,65088,12300,12301,65089,65090,12302,12303,65091,65092,65113,65114,65115,65116,65117,65118,8216,8217,8220,8221,12317,12318,8245,8242,65283,65286,65290,8251,167,12291,9675,9679,9651,9650,9678,9734,9733,9671,9670,9633,9632,9661,9660,12963,8453,175,65507,65343,717,65097,65098,65101,65102,65099,65100,65119,65120,65121,65291,65293,215,247,177,8730,65308,65310,65309,8806,8807,8800,8734,8786,8801,65122,65123,65124,65125,65126,65374,8745,8746,8869,8736,8735,8895,13266,13265,8747,8750,8757,8756,9792,9794,8853,8857,8593,8595,8592,8594,8598,8599,8601,8600,8741,8739,65295,65340,8725,65128,65284,65509,12306,65504,65505,65285,65312,8451,8457,65129,65130,65131,13269,13212,13213,13214,13262,13217,13198,13199,13252,176,20825,20827,20830,20829,20833,20835,21991,29929,31950,9601,9602,9603,9604,9605,9606,9607,9608,9615,9614,9613,9612,9611,9610,9609,9532,9524,9516,9508,9500,9620,9472,9474,9621,9484,9488,9492,9496,9581,9582,9584,9583,9552,9566,9578,9569,9698,9699,9701,9700,9585,9586,9587,65296,65297,65298,65299,65300,65301,65302,65303,65304,65305,8544,8545,8546,8547,8548,8549,8550,8551,8552,8553,12321,12322,12323,12324,12325,12326,12327,12328,12329,21313,21316,21317,65313,65314,65315,65316,65317,65318,65319,65320,65321,65322,65323,65324,65325,65326,65327,65328,65329,65330,65331,65332,65333,65334,65335,65336,65337,65338,65345,65346,65347,65348,65349,65350,65351,65352,65353,65354,65355,65356,65357,65358,65359,65360,65361,65362,65363,65364,65365,65366,65367,65368,65369,65370,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,931,932,933,934,935,936,937,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,963,964,965,966,967,968,969,12549,12550,12551,12552,12553,12554,12555,12556,12557,12558,12559,12560,12561,12562,12563,12564,12565,12566,12567,12568,12569,12570,12571,12572,12573,12574,12575,12576,12577,12578,12579,12580,12581,12582,12583,12584,12585,729,713,714,711,715,9216,9217,9218,9219,9220,9221,9222,9223,9224,9225,9226,9227,9228,9229,9230,9231,9232,9233,9234,9235,9236,9237,9238,9239,9240,9241,9242,9243,9244,9245,9246,9247,9249,8364,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,19968,20057,19969,19971,20035,20061,20102,20108,20154,20799,20837,20843,20960,20992,20993,21147,21269,21313,21340,21448,19977,19979,19976,19978,20011,20024,20961,20037,20040,20063,20062,20110,20129,20800,20995,21242,21315,21449,21475,22303,22763,22805,22823,22899,23376,23377,23379,23544,23567,23586,23608,23665,24029,24037,24049,24050,24051,24062,24178,24318,24331,24339,25165,19985,19984,19981,20013,20016,20025,20043,23609,20104,20113,20117,20114,20116,20130,20161,20160,20163,20166,20167,20173,20170,20171,20164,20803,20801,20839,20845,20846,20844,20887,20982,20998,20999,21e3,21243,21246,21247,21270,21305,21320,21319,21317,21342,21380,21451,21450,21453,22764,22825,22827,22826,22829,23380,23569,23588,23610,23663,24052,24187,24319,24340,24341,24515,25096,25142,25163,25166,25903,25991,26007,26020,26041,26085,26352,26376,26408,27424,27490,27513,27595,27604,27611,27663,27700,28779,29226,29238,29243,29255,29273,29275,29356,29579,19993,19990,19989,19988,19992,20027,20045,20047,20046,20197,20184,20180,20181,20182,20183,20195,20196,20185,20190,20805,20804,20873,20874,20908,20985,20986,20984,21002,21152,21151,21253,21254,21271,21277,20191,21322,21321,21345,21344,21359,21358,21435,21487,21476,21491,21484,21486,21481,21480,21500,21496,21493,21483,21478,21482,21490,21489,21488,21477,21485,21499,22235,22234,22806,22830,22833,22900,22902,23381,23427,23612,24040,24039,24038,24066,24067,24179,24188,24321,24344,24343,24517,25098,25171,25172,25170,25169,26021,26086,26414,26412,26410,26411,26413,27491,27597,27665,27664,27704,27713,27712,27710,29359,29572,29577,29916,29926,29976,29983,29992,29993,3e4,30001,30002,30003,30091,30333,30382,30399,30446,30683,30690,30707,31034,31166,31348,31435,19998,19999,20050,20051,20073,20121,20132,20134,20133,20223,20233,20249,20234,20245,20237,20240,20241,20239,20210,20214,20219,20208,20211,20221,20225,20235,20809,20807,20806,20808,20840,20849,20877,20912,21015,21009,21010,21006,21014,21155,21256,21281,21280,21360,21361,21513,21519,21516,21514,21520,21505,21515,21508,21521,21517,21512,21507,21518,21510,21522,22240,22238,22237,22323,22320,22312,22317,22316,22319,22313,22809,22810,22839,22840,22916,22904,22915,22909,22905,22914,22913,23383,23384,23431,23432,23429,23433,23546,23574,23673,24030,24070,24182,24180,24335,24347,24537,24534,25102,25100,25101,25104,25187,25179,25176,25910,26089,26088,26092,26093,26354,26355,26377,26429,26420,26417,26421,27425,27492,27515,27670,27741,27735,27737,27743,27744,27728,27733,27745,27739,27725,27726,28784,29279,29277,30334,31481,31859,31992,32566,32650,32701,32769,32771,32780,32786,32819,32895,32905,32907,32908,33251,33258,33267,33276,33292,33307,33311,33390,33394,33406,34411,34880,34892,34915,35199,38433,20018,20136,20301,20303,20295,20311,20318,20276,20315,20309,20272,20304,20305,20285,20282,20280,20291,20308,20284,20294,20323,20316,20320,20271,20302,20278,20313,20317,20296,20314,20812,20811,20813,20853,20918,20919,21029,21028,21033,21034,21032,21163,21161,21162,21164,21283,21363,21365,21533,21549,21534,21566,21542,21582,21543,21574,21571,21555,21576,21570,21531,21545,21578,21561,21563,21560,21550,21557,21558,21536,21564,21568,21553,21547,21535,21548,22250,22256,22244,22251,22346,22353,22336,22349,22343,22350,22334,22352,22351,22331,22767,22846,22941,22930,22952,22942,22947,22937,22934,22925,22948,22931,22922,22949,23389,23388,23386,23387,23436,23435,23439,23596,23616,23617,23615,23614,23696,23697,23700,23692,24043,24076,24207,24199,24202,24311,24324,24351,24420,24418,24439,24441,24536,24524,24535,24525,24561,24555,24568,24554,25106,25105,25220,25239,25238,25216,25206,25225,25197,25226,25212,25214,25209,25203,25234,25199,25240,25198,25237,25235,25233,25222,25913,25915,25912,26097,26356,26463,26446,26447,26448,26449,26460,26454,26462,26441,26438,26464,26451,26455,27493,27599,27714,27742,27801,27777,27784,27785,27781,27803,27754,27770,27792,27760,27788,27752,27798,27794,27773,27779,27762,27774,27764,27782,27766,27789,27796,27800,27778,28790,28796,28797,28792,29282,29281,29280,29380,29378,29590,29996,29995,30007,30008,30338,30447,30691,31169,31168,31167,31350,31995,32597,32918,32915,32925,32920,32923,32922,32946,33391,33426,33419,33421,35211,35282,35328,35895,35910,35925,35997,36196,36208,36275,36523,36554,36763,36784,36802,36806,36805,36804,24033,37009,37026,37034,37030,37027,37193,37318,37324,38450,38446,38449,38442,38444,20006,20054,20083,20107,20123,20126,20139,20140,20335,20381,20365,20339,20351,20332,20379,20363,20358,20355,20336,20341,20360,20329,20347,20374,20350,20367,20369,20346,20820,20818,20821,20841,20855,20854,20856,20925,20989,21051,21048,21047,21050,21040,21038,21046,21057,21182,21179,21330,21332,21331,21329,21350,21367,21368,21369,21462,21460,21463,21619,21621,21654,21624,21653,21632,21627,21623,21636,21650,21638,21628,21648,21617,21622,21644,21658,21602,21608,21643,21629,21646,22266,22403,22391,22378,22377,22369,22374,22372,22396,22812,22857,22855,22856,22852,22868,22974,22971,22996,22969,22958,22993,22982,22992,22989,22987,22995,22986,22959,22963,22994,22981,23391,23396,23395,23447,23450,23448,23452,23449,23451,23578,23624,23621,23622,23735,23713,23736,23721,23723,23729,23731,24088,24090,24086,24085,24091,24081,24184,24218,24215,24220,24213,24214,24310,24358,24359,24361,24448,24449,24447,24444,24541,24544,24573,24565,24575,24591,24596,24623,24629,24598,24618,24597,24609,24615,24617,24619,24603,25110,25109,25151,25150,25152,25215,25289,25292,25284,25279,25282,25273,25298,25307,25259,25299,25300,25291,25288,25256,25277,25276,25296,25305,25287,25293,25269,25306,25265,25304,25302,25303,25286,25260,25294,25918,26023,26044,26106,26132,26131,26124,26118,26114,26126,26112,26127,26133,26122,26119,26381,26379,26477,26507,26517,26481,26524,26483,26487,26503,26525,26519,26479,26480,26495,26505,26494,26512,26485,26522,26515,26492,26474,26482,27427,27494,27495,27519,27667,27675,27875,27880,27891,27825,27852,27877,27827,27837,27838,27836,27874,27819,27861,27859,27832,27844,27833,27841,27822,27863,27845,27889,27839,27835,27873,27867,27850,27820,27887,27868,27862,27872,28821,28814,28818,28810,28825,29228,29229,29240,29256,29287,29289,29376,29390,29401,29399,29392,29609,29608,29599,29611,29605,30013,30109,30105,30106,30340,30402,30450,30452,30693,30717,31038,31040,31041,31177,31176,31354,31353,31482,31998,32596,32652,32651,32773,32954,32933,32930,32945,32929,32939,32937,32948,32938,32943,33253,33278,33293,33459,33437,33433,33453,33469,33439,33465,33457,33452,33445,33455,33464,33443,33456,33470,33463,34382,34417,21021,34920,36555,36814,36820,36817,37045,37048,37041,37046,37319,37329,38263,38272,38428,38464,38463,38459,38468,38466,38585,38632,38738,38750,20127,20141,20142,20449,20405,20399,20415,20448,20433,20431,20445,20419,20406,20440,20447,20426,20439,20398,20432,20420,20418,20442,20430,20446,20407,20823,20882,20881,20896,21070,21059,21066,21069,21068,21067,21063,21191,21193,21187,21185,21261,21335,21371,21402,21467,21676,21696,21672,21710,21705,21688,21670,21683,21703,21698,21693,21674,21697,21700,21704,21679,21675,21681,21691,21673,21671,21695,22271,22402,22411,22432,22435,22434,22478,22446,22419,22869,22865,22863,22862,22864,23004,23e3,23039,23011,23016,23043,23013,23018,23002,23014,23041,23035,23401,23459,23462,23460,23458,23461,23553,23630,23631,23629,23627,23769,23762,24055,24093,24101,24095,24189,24224,24230,24314,24328,24365,24421,24456,24453,24458,24459,24455,24460,24457,24594,24605,24608,24613,24590,24616,24653,24688,24680,24674,24646,24643,24684,24683,24682,24676,25153,25308,25366,25353,25340,25325,25345,25326,25341,25351,25329,25335,25327,25324,25342,25332,25361,25346,25919,25925,26027,26045,26082,26149,26157,26144,26151,26159,26143,26152,26161,26148,26359,26623,26579,26609,26580,26576,26604,26550,26543,26613,26601,26607,26564,26577,26548,26586,26597,26552,26575,26590,26611,26544,26585,26594,26589,26578,27498,27523,27526,27573,27602,27607,27679,27849,27915,27954,27946,27969,27941,27916,27953,27934,27927,27963,27965,27966,27958,27931,27893,27961,27943,27960,27945,27950,27957,27918,27947,28843,28858,28851,28844,28847,28845,28856,28846,28836,29232,29298,29295,29300,29417,29408,29409,29623,29642,29627,29618,29645,29632,29619,29978,29997,30031,30028,30030,30027,30123,30116,30117,30114,30115,30328,30342,30343,30344,30408,30406,30403,30405,30465,30457,30456,30473,30475,30462,30460,30471,30684,30722,30740,30732,30733,31046,31049,31048,31047,31161,31162,31185,31186,31179,31359,31361,31487,31485,31869,32002,32005,32e3,32009,32007,32004,32006,32568,32654,32703,32772,32784,32781,32785,32822,32982,32997,32986,32963,32964,32972,32993,32987,32974,32990,32996,32989,33268,33314,33511,33539,33541,33507,33499,33510,33540,33509,33538,33545,33490,33495,33521,33537,33500,33492,33489,33502,33491,33503,33519,33542,34384,34425,34427,34426,34893,34923,35201,35284,35336,35330,35331,35998,36e3,36212,36211,36276,36557,36556,36848,36838,36834,36842,36837,36845,36843,36836,36840,37066,37070,37057,37059,37195,37194,37325,38274,38480,38475,38476,38477,38754,38761,38859,38893,38899,38913,39080,39131,39135,39318,39321,20056,20147,20492,20493,20515,20463,20518,20517,20472,20521,20502,20486,20540,20511,20506,20498,20497,20474,20480,20500,20520,20465,20513,20491,20505,20504,20467,20462,20525,20522,20478,20523,20489,20860,20900,20901,20898,20941,20940,20934,20939,21078,21084,21076,21083,21085,21290,21375,21407,21405,21471,21736,21776,21761,21815,21756,21733,21746,21766,21754,21780,21737,21741,21729,21769,21742,21738,21734,21799,21767,21757,21775,22275,22276,22466,22484,22475,22467,22537,22799,22871,22872,22874,23057,23064,23068,23071,23067,23059,23020,23072,23075,23081,23077,23052,23049,23403,23640,23472,23475,23478,23476,23470,23477,23481,23480,23556,23633,23637,23632,23789,23805,23803,23786,23784,23792,23798,23809,23796,24046,24109,24107,24235,24237,24231,24369,24466,24465,24464,24665,24675,24677,24656,24661,24685,24681,24687,24708,24735,24730,24717,24724,24716,24709,24726,25159,25331,25352,25343,25422,25406,25391,25429,25410,25414,25423,25417,25402,25424,25405,25386,25387,25384,25421,25420,25928,25929,26009,26049,26053,26178,26185,26191,26179,26194,26188,26181,26177,26360,26388,26389,26391,26657,26680,26696,26694,26707,26681,26690,26708,26665,26803,26647,26700,26705,26685,26612,26704,26688,26684,26691,26666,26693,26643,26648,26689,27530,27529,27575,27683,27687,27688,27686,27684,27888,28010,28053,28040,28039,28006,28024,28023,27993,28051,28012,28041,28014,27994,28020,28009,28044,28042,28025,28037,28005,28052,28874,28888,28900,28889,28872,28879,29241,29305,29436,29433,29437,29432,29431,29574,29677,29705,29678,29664,29674,29662,30036,30045,30044,30042,30041,30142,30149,30151,30130,30131,30141,30140,30137,30146,30136,30347,30384,30410,30413,30414,30505,30495,30496,30504,30697,30768,30759,30776,30749,30772,30775,30757,30765,30752,30751,30770,31061,31056,31072,31071,31062,31070,31069,31063,31066,31204,31203,31207,31199,31206,31209,31192,31364,31368,31449,31494,31505,31881,32033,32023,32011,32010,32032,32034,32020,32016,32021,32026,32028,32013,32025,32027,32570,32607,32660,32709,32705,32774,32792,32789,32793,32791,32829,32831,33009,33026,33008,33029,33005,33012,33030,33016,33011,33032,33021,33034,33020,33007,33261,33260,33280,33296,33322,33323,33320,33324,33467,33579,33618,33620,33610,33592,33616,33609,33589,33588,33615,33586,33593,33590,33559,33600,33585,33576,33603,34388,34442,34474,34451,34468,34473,34444,34467,34460,34928,34935,34945,34946,34941,34937,35352,35344,35342,35340,35349,35338,35351,35347,35350,35343,35345,35912,35962,35961,36001,36002,36215,36524,36562,36564,36559,36785,36865,36870,36855,36864,36858,36852,36867,36861,36869,36856,37013,37089,37085,37090,37202,37197,37196,37336,37341,37335,37340,37337,38275,38498,38499,38497,38491,38493,38500,38488,38494,38587,39138,39340,39592,39640,39717,39730,39740,20094,20602,20605,20572,20551,20547,20556,20570,20553,20581,20598,20558,20565,20597,20596,20599,20559,20495,20591,20589,20828,20885,20976,21098,21103,21202,21209,21208,21205,21264,21263,21273,21311,21312,21310,21443,26364,21830,21866,21862,21828,21854,21857,21827,21834,21809,21846,21839,21845,21807,21860,21816,21806,21852,21804,21859,21811,21825,21847,22280,22283,22281,22495,22533,22538,22534,22496,22500,22522,22530,22581,22519,22521,22816,22882,23094,23105,23113,23142,23146,23104,23100,23138,23130,23110,23114,23408,23495,23493,23492,23490,23487,23494,23561,23560,23559,23648,23644,23645,23815,23814,23822,23835,23830,23842,23825,23849,23828,23833,23844,23847,23831,24034,24120,24118,24115,24119,24247,24248,24246,24245,24254,24373,24375,24407,24428,24425,24427,24471,24473,24478,24472,24481,24480,24476,24703,24739,24713,24736,24744,24779,24756,24806,24765,24773,24763,24757,24796,24764,24792,24789,24774,24799,24760,24794,24775,25114,25115,25160,25504,25511,25458,25494,25506,25509,25463,25447,25496,25514,25457,25513,25481,25475,25499,25451,25512,25476,25480,25497,25505,25516,25490,25487,25472,25467,25449,25448,25466,25949,25942,25937,25945,25943,21855,25935,25944,25941,25940,26012,26011,26028,26063,26059,26060,26062,26205,26202,26212,26216,26214,26206,26361,21207,26395,26753,26799,26786,26771,26805,26751,26742,26801,26791,26775,26800,26755,26820,26797,26758,26757,26772,26781,26792,26783,26785,26754,27442,27578,27627,27628,27691,28046,28092,28147,28121,28082,28129,28108,28132,28155,28154,28165,28103,28107,28079,28113,28078,28126,28153,28088,28151,28149,28101,28114,28186,28085,28122,28139,28120,28138,28145,28142,28136,28102,28100,28074,28140,28095,28134,28921,28937,28938,28925,28911,29245,29309,29313,29468,29467,29462,29459,29465,29575,29701,29706,29699,29702,29694,29709,29920,29942,29943,29980,29986,30053,30054,30050,30064,30095,30164,30165,30133,30154,30157,30350,30420,30418,30427,30519,30526,30524,30518,30520,30522,30827,30787,30798,31077,31080,31085,31227,31378,31381,31520,31528,31515,31532,31526,31513,31518,31534,31890,31895,31893,32070,32067,32113,32046,32057,32060,32064,32048,32051,32068,32047,32066,32050,32049,32573,32670,32666,32716,32718,32722,32796,32842,32838,33071,33046,33059,33067,33065,33072,33060,33282,33333,33335,33334,33337,33678,33694,33688,33656,33698,33686,33725,33707,33682,33674,33683,33673,33696,33655,33659,33660,33670,33703,34389,24426,34503,34496,34486,34500,34485,34502,34507,34481,34479,34505,34899,34974,34952,34987,34962,34966,34957,34955,35219,35215,35370,35357,35363,35365,35377,35373,35359,35355,35362,35913,35930,36009,36012,36011,36008,36010,36007,36199,36198,36286,36282,36571,36575,36889,36877,36890,36887,36899,36895,36893,36880,36885,36894,36896,36879,36898,36886,36891,36884,37096,37101,37117,37207,37326,37365,37350,37347,37351,37357,37353,38281,38506,38517,38515,38520,38512,38516,38518,38519,38508,38592,38634,38633,31456,31455,38914,38915,39770,40165,40565,40575,40613,40635,20642,20621,20613,20633,20625,20608,20630,20632,20634,26368,20977,21106,21108,21109,21097,21214,21213,21211,21338,21413,21883,21888,21927,21884,21898,21917,21912,21890,21916,21930,21908,21895,21899,21891,21939,21934,21919,21822,21938,21914,21947,21932,21937,21886,21897,21931,21913,22285,22575,22570,22580,22564,22576,22577,22561,22557,22560,22777,22778,22880,23159,23194,23167,23186,23195,23207,23411,23409,23506,23500,23507,23504,23562,23563,23601,23884,23888,23860,23879,24061,24133,24125,24128,24131,24190,24266,24257,24258,24260,24380,24429,24489,24490,24488,24785,24801,24754,24758,24800,24860,24867,24826,24853,24816,24827,24820,24936,24817,24846,24822,24841,24832,24850,25119,25161,25507,25484,25551,25536,25577,25545,25542,25549,25554,25571,25552,25569,25558,25581,25582,25462,25588,25578,25563,25682,25562,25593,25950,25958,25954,25955,26001,26e3,26031,26222,26224,26228,26230,26223,26257,26234,26238,26231,26366,26367,26399,26397,26874,26837,26848,26840,26839,26885,26847,26869,26862,26855,26873,26834,26866,26851,26827,26829,26893,26898,26894,26825,26842,26990,26875,27454,27450,27453,27544,27542,27580,27631,27694,27695,27692,28207,28216,28244,28193,28210,28263,28234,28192,28197,28195,28187,28251,28248,28196,28246,28270,28205,28198,28271,28212,28237,28218,28204,28227,28189,28222,28363,28297,28185,28238,28259,28228,28274,28265,28255,28953,28954,28966,28976,28961,28982,29038,28956,29260,29316,29312,29494,29477,29492,29481,29754,29738,29747,29730,29733,29749,29750,29748,29743,29723,29734,29736,29989,29990,30059,30058,30178,30171,30179,30169,30168,30174,30176,30331,30332,30358,30355,30388,30428,30543,30701,30813,30828,30831,31245,31240,31243,31237,31232,31384,31383,31382,31461,31459,31561,31574,31558,31568,31570,31572,31565,31563,31567,31569,31903,31909,32094,32080,32104,32085,32043,32110,32114,32097,32102,32098,32112,32115,21892,32724,32725,32779,32850,32901,33109,33108,33099,33105,33102,33081,33094,33086,33100,33107,33140,33298,33308,33769,33795,33784,33805,33760,33733,33803,33729,33775,33777,33780,33879,33802,33776,33804,33740,33789,33778,33738,33848,33806,33796,33756,33799,33748,33759,34395,34527,34521,34541,34516,34523,34532,34512,34526,34903,35009,35010,34993,35203,35222,35387,35424,35413,35422,35388,35393,35412,35419,35408,35398,35380,35386,35382,35414,35937,35970,36015,36028,36019,36029,36033,36027,36032,36020,36023,36022,36031,36024,36234,36229,36225,36302,36317,36299,36314,36305,36300,36315,36294,36603,36600,36604,36764,36910,36917,36913,36920,36914,36918,37122,37109,37129,37118,37219,37221,37327,37396,37397,37411,37385,37406,37389,37392,37383,37393,38292,38287,38283,38289,38291,38290,38286,38538,38542,38539,38525,38533,38534,38541,38514,38532,38593,38597,38596,38598,38599,38639,38642,38860,38917,38918,38920,39143,39146,39151,39145,39154,39149,39342,39341,40643,40653,40657,20098,20653,20661,20658,20659,20677,20670,20652,20663,20667,20655,20679,21119,21111,21117,21215,21222,21220,21218,21219,21295,21983,21992,21971,21990,21966,21980,21959,21969,21987,21988,21999,21978,21985,21957,21958,21989,21961,22290,22291,22622,22609,22616,22615,22618,22612,22635,22604,22637,22602,22626,22610,22603,22887,23233,23241,23244,23230,23229,23228,23219,23234,23218,23913,23919,24140,24185,24265,24264,24338,24409,24492,24494,24858,24847,24904,24863,24819,24859,24825,24833,24840,24910,24908,24900,24909,24894,24884,24871,24845,24838,24887,25121,25122,25619,25662,25630,25642,25645,25661,25644,25615,25628,25620,25613,25654,25622,25623,25606,25964,26015,26032,26263,26249,26247,26248,26262,26244,26264,26253,26371,27028,26989,26970,26999,26976,26964,26997,26928,27010,26954,26984,26987,26974,26963,27001,27014,26973,26979,26971,27463,27506,27584,27583,27603,27645,28322,28335,28371,28342,28354,28304,28317,28359,28357,28325,28312,28348,28346,28331,28369,28310,28316,28356,28372,28330,28327,28340,29006,29017,29033,29028,29001,29031,29020,29036,29030,29004,29029,29022,28998,29032,29014,29242,29266,29495,29509,29503,29502,29807,29786,29781,29791,29790,29761,29759,29785,29787,29788,30070,30072,30208,30192,30209,30194,30193,30202,30207,30196,30195,30430,30431,30555,30571,30566,30558,30563,30585,30570,30572,30556,30565,30568,30562,30702,30862,30896,30871,30872,30860,30857,30844,30865,30867,30847,31098,31103,31105,33836,31165,31260,31258,31264,31252,31263,31262,31391,31392,31607,31680,31584,31598,31591,31921,31923,31925,32147,32121,32145,32129,32143,32091,32622,32617,32618,32626,32681,32680,32676,32854,32856,32902,32900,33137,33136,33144,33125,33134,33139,33131,33145,33146,33126,33285,33351,33922,33911,33853,33841,33909,33894,33899,33865,33900,33883,33852,33845,33889,33891,33897,33901,33862,34398,34396,34399,34553,34579,34568,34567,34560,34558,34555,34562,34563,34566,34570,34905,35039,35028,35033,35036,35032,35037,35041,35018,35029,35026,35228,35299,35435,35442,35443,35430,35433,35440,35463,35452,35427,35488,35441,35461,35437,35426,35438,35436,35449,35451,35390,35432,35938,35978,35977,36042,36039,36040,36036,36018,36035,36034,36037,36321,36319,36328,36335,36339,36346,36330,36324,36326,36530,36611,36617,36606,36618,36767,36786,36939,36938,36947,36930,36948,36924,36949,36944,36935,36943,36942,36941,36945,36926,36929,37138,37143,37228,37226,37225,37321,37431,37463,37432,37437,37440,37438,37467,37451,37476,37457,37428,37449,37453,37445,37433,37439,37466,38296,38552,38548,38549,38605,38603,38601,38602,38647,38651,38649,38646,38742,38772,38774,38928,38929,38931,38922,38930,38924,39164,39156,39165,39166,39347,39345,39348,39649,40169,40578,40718,40723,40736,20711,20718,20709,20694,20717,20698,20693,20687,20689,20721,20686,20713,20834,20979,21123,21122,21297,21421,22014,22016,22043,22039,22013,22036,22022,22025,22029,22030,22007,22038,22047,22024,22032,22006,22296,22294,22645,22654,22659,22675,22666,22649,22661,22653,22781,22821,22818,22820,22890,22889,23265,23270,23273,23255,23254,23256,23267,23413,23518,23527,23521,23525,23526,23528,23522,23524,23519,23565,23650,23940,23943,24155,24163,24149,24151,24148,24275,24278,24330,24390,24432,24505,24903,24895,24907,24951,24930,24931,24927,24922,24920,24949,25130,25735,25688,25684,25764,25720,25695,25722,25681,25703,25652,25709,25723,25970,26017,26071,26070,26274,26280,26269,27036,27048,27029,27073,27054,27091,27083,27035,27063,27067,27051,27060,27088,27085,27053,27084,27046,27075,27043,27465,27468,27699,28467,28436,28414,28435,28404,28457,28478,28448,28460,28431,28418,28450,28415,28399,28422,28465,28472,28466,28451,28437,28459,28463,28552,28458,28396,28417,28402,28364,28407,29076,29081,29053,29066,29060,29074,29246,29330,29334,29508,29520,29796,29795,29802,29808,29805,29956,30097,30247,30221,30219,30217,30227,30433,30435,30596,30589,30591,30561,30913,30879,30887,30899,30889,30883,31118,31119,31117,31278,31281,31402,31401,31469,31471,31649,31637,31627,31605,31639,31645,31636,31631,31672,31623,31620,31929,31933,31934,32187,32176,32156,32189,32190,32160,32202,32180,32178,32177,32186,32162,32191,32181,32184,32173,32210,32199,32172,32624,32736,32737,32735,32862,32858,32903,33104,33152,33167,33160,33162,33151,33154,33255,33274,33287,33300,33310,33355,33993,33983,33990,33988,33945,33950,33970,33948,33995,33976,33984,34003,33936,33980,34001,33994,34623,34588,34619,34594,34597,34612,34584,34645,34615,34601,35059,35074,35060,35065,35064,35069,35048,35098,35055,35494,35468,35486,35491,35469,35489,35475,35492,35498,35493,35496,35480,35473,35482,35495,35946,35981,35980,36051,36049,36050,36203,36249,36245,36348,36628,36626,36629,36627,36771,36960,36952,36956,36963,36953,36958,36962,36957,36955,37145,37144,37150,37237,37240,37239,37236,37496,37504,37509,37528,37526,37499,37523,37532,37544,37500,37521,38305,38312,38313,38307,38309,38308,38553,38556,38555,38604,38610,38656,38780,38789,38902,38935,38936,39087,39089,39171,39173,39180,39177,39361,39599,39600,39654,39745,39746,40180,40182,40179,40636,40763,40778,20740,20736,20731,20725,20729,20738,20744,20745,20741,20956,21127,21128,21129,21133,21130,21232,21426,22062,22075,22073,22066,22079,22068,22057,22099,22094,22103,22132,22070,22063,22064,22656,22687,22686,22707,22684,22702,22697,22694,22893,23305,23291,23307,23285,23308,23304,23534,23532,23529,23531,23652,23653,23965,23956,24162,24159,24161,24290,24282,24287,24285,24291,24288,24392,24433,24503,24501,24950,24935,24942,24925,24917,24962,24956,24944,24939,24958,24999,24976,25003,24974,25004,24986,24996,24980,25006,25134,25705,25711,25721,25758,25778,25736,25744,25776,25765,25747,25749,25769,25746,25774,25773,25771,25754,25772,25753,25762,25779,25973,25975,25976,26286,26283,26292,26289,27171,27167,27112,27137,27166,27161,27133,27169,27155,27146,27123,27138,27141,27117,27153,27472,27470,27556,27589,27590,28479,28540,28548,28497,28518,28500,28550,28525,28507,28536,28526,28558,28538,28528,28516,28567,28504,28373,28527,28512,28511,29087,29100,29105,29096,29270,29339,29518,29527,29801,29835,29827,29822,29824,30079,30240,30249,30239,30244,30246,30241,30242,30362,30394,30436,30606,30599,30604,30609,30603,30923,30917,30906,30922,30910,30933,30908,30928,31295,31292,31296,31293,31287,31291,31407,31406,31661,31665,31684,31668,31686,31687,31681,31648,31692,31946,32224,32244,32239,32251,32216,32236,32221,32232,32227,32218,32222,32233,32158,32217,32242,32249,32629,32631,32687,32745,32806,33179,33180,33181,33184,33178,33176,34071,34109,34074,34030,34092,34093,34067,34065,34083,34081,34068,34028,34085,34047,34054,34690,34676,34678,34656,34662,34680,34664,34649,34647,34636,34643,34907,34909,35088,35079,35090,35091,35093,35082,35516,35538,35527,35524,35477,35531,35576,35506,35529,35522,35519,35504,35542,35533,35510,35513,35547,35916,35918,35948,36064,36062,36070,36068,36076,36077,36066,36067,36060,36074,36065,36205,36255,36259,36395,36368,36381,36386,36367,36393,36383,36385,36382,36538,36637,36635,36639,36649,36646,36650,36636,36638,36645,36969,36974,36968,36973,36983,37168,37165,37159,37169,37255,37257,37259,37251,37573,37563,37559,37610,37548,37604,37569,37555,37564,37586,37575,37616,37554,38317,38321,38660,38662,38663,38665,38752,38797,38795,38799,38945,38955,38940,39091,39178,39187,39186,39192,39389,39376,39391,39387,39377,39381,39378,39385,39607,39662,39663,39719,39749,39748,39799,39791,40198,40201,40195,40617,40638,40654,22696,40786,20754,20760,20756,20752,20757,20864,20906,20957,21137,21139,21235,22105,22123,22137,22121,22116,22136,22122,22120,22117,22129,22127,22124,22114,22134,22721,22718,22727,22725,22894,23325,23348,23416,23536,23566,24394,25010,24977,25001,24970,25037,25014,25022,25034,25032,25136,25797,25793,25803,25787,25788,25818,25796,25799,25794,25805,25791,25810,25812,25790,25972,26310,26313,26297,26308,26311,26296,27197,27192,27194,27225,27243,27224,27193,27204,27234,27233,27211,27207,27189,27231,27208,27481,27511,27653,28610,28593,28577,28611,28580,28609,28583,28595,28608,28601,28598,28582,28576,28596,29118,29129,29136,29138,29128,29141,29113,29134,29145,29148,29123,29124,29544,29852,29859,29848,29855,29854,29922,29964,29965,30260,30264,30266,30439,30437,30624,30622,30623,30629,30952,30938,30956,30951,31142,31309,31310,31302,31308,31307,31418,31705,31761,31689,31716,31707,31713,31721,31718,31957,31958,32266,32273,32264,32283,32291,32286,32285,32265,32272,32633,32690,32752,32753,32750,32808,33203,33193,33192,33275,33288,33368,33369,34122,34137,34120,34152,34153,34115,34121,34157,34154,34142,34691,34719,34718,34722,34701,34913,35114,35122,35109,35115,35105,35242,35238,35558,35578,35563,35569,35584,35548,35559,35566,35582,35585,35586,35575,35565,35571,35574,35580,35947,35949,35987,36084,36420,36401,36404,36418,36409,36405,36667,36655,36664,36659,36776,36774,36981,36980,36984,36978,36988,36986,37172,37266,37664,37686,37624,37683,37679,37666,37628,37675,37636,37658,37648,37670,37665,37653,37678,37657,38331,38567,38568,38570,38613,38670,38673,38678,38669,38675,38671,38747,38748,38758,38808,38960,38968,38971,38967,38957,38969,38948,39184,39208,39198,39195,39201,39194,39405,39394,39409,39608,39612,39675,39661,39720,39825,40213,40227,40230,40232,40210,40219,40664,40660,40845,40860,20778,20767,20769,20786,21237,22158,22144,22160,22149,22151,22159,22741,22739,22737,22734,23344,23338,23332,23418,23607,23656,23996,23994,23997,23992,24171,24396,24509,25033,25026,25031,25062,25035,25138,25140,25806,25802,25816,25824,25840,25830,25836,25841,25826,25837,25986,25987,26329,26326,27264,27284,27268,27298,27292,27355,27299,27262,27287,27280,27296,27484,27566,27610,27656,28632,28657,28639,28640,28635,28644,28651,28655,28544,28652,28641,28649,28629,28654,28656,29159,29151,29166,29158,29157,29165,29164,29172,29152,29237,29254,29552,29554,29865,29872,29862,29864,30278,30274,30284,30442,30643,30634,30640,30636,30631,30637,30703,30967,30970,30964,30959,30977,31143,31146,31319,31423,31751,31757,31742,31735,31756,31712,31968,31964,31966,31970,31967,31961,31965,32302,32318,32326,32311,32306,32323,32299,32317,32305,32325,32321,32308,32313,32328,32309,32319,32303,32580,32755,32764,32881,32882,32880,32879,32883,33222,33219,33210,33218,33216,33215,33213,33225,33214,33256,33289,33393,34218,34180,34174,34204,34193,34196,34223,34203,34183,34216,34186,34407,34752,34769,34739,34770,34758,34731,34747,34746,34760,34763,35131,35126,35140,35128,35133,35244,35598,35607,35609,35611,35594,35616,35613,35588,35600,35905,35903,35955,36090,36093,36092,36088,36091,36264,36425,36427,36424,36426,36676,36670,36674,36677,36671,36991,36989,36996,36993,36994,36992,37177,37283,37278,37276,37709,37762,37672,37749,37706,37733,37707,37656,37758,37740,37723,37744,37722,37716,38346,38347,38348,38344,38342,38577,38584,38614,38684,38686,38816,38867,38982,39094,39221,39425,39423,39854,39851,39850,39853,40251,40255,40587,40655,40670,40668,40669,40667,40766,40779,21474,22165,22190,22745,22744,23352,24413,25059,25139,25844,25842,25854,25862,25850,25851,25847,26039,26332,26406,27315,27308,27331,27323,27320,27330,27310,27311,27487,27512,27567,28681,28683,28670,28678,28666,28689,28687,29179,29180,29182,29176,29559,29557,29863,29887,29973,30294,30296,30290,30653,30655,30651,30652,30990,31150,31329,31330,31328,31428,31429,31787,31783,31786,31774,31779,31777,31975,32340,32341,32350,32346,32353,32338,32345,32584,32761,32763,32887,32886,33229,33231,33290,34255,34217,34253,34256,34249,34224,34234,34233,34214,34799,34796,34802,34784,35206,35250,35316,35624,35641,35628,35627,35920,36101,36441,36451,36454,36452,36447,36437,36544,36681,36685,36999,36995,37e3,37291,37292,37328,37780,37770,37782,37794,37811,37806,37804,37808,37784,37786,37783,38356,38358,38352,38357,38626,38620,38617,38619,38622,38692,38819,38822,38829,38905,38989,38991,38988,38990,38995,39098,39230,39231,39229,39214,39333,39438,39617,39683,39686,39759,39758,39757,39882,39881,39933,39880,39872,40273,40285,40288,40672,40725,40748,20787,22181,22750,22751,22754,23541,40848,24300,25074,25079,25078,25077,25856,25871,26336,26333,27365,27357,27354,27347,28699,28703,28712,28698,28701,28693,28696,29190,29197,29272,29346,29560,29562,29885,29898,29923,30087,30086,30303,30305,30663,31001,31153,31339,31337,31806,31807,31800,31805,31799,31808,32363,32365,32377,32361,32362,32645,32371,32694,32697,32696,33240,34281,34269,34282,34261,34276,34277,34295,34811,34821,34829,34809,34814,35168,35167,35158,35166,35649,35676,35672,35657,35674,35662,35663,35654,35673,36104,36106,36476,36466,36487,36470,36460,36474,36468,36692,36686,36781,37002,37003,37297,37294,37857,37841,37855,37827,37832,37852,37853,37846,37858,37837,37848,37860,37847,37864,38364,38580,38627,38698,38695,38753,38876,38907,39006,39e3,39003,39100,39237,39241,39446,39449,39693,39912,39911,39894,39899,40329,40289,40306,40298,40300,40594,40599,40595,40628,21240,22184,22199,22198,22196,22204,22756,23360,23363,23421,23542,24009,25080,25082,25880,25876,25881,26342,26407,27372,28734,28720,28722,29200,29563,29903,30306,30309,31014,31018,31020,31019,31431,31478,31820,31811,31821,31983,31984,36782,32381,32380,32386,32588,32768,33242,33382,34299,34297,34321,34298,34310,34315,34311,34314,34836,34837,35172,35258,35320,35696,35692,35686,35695,35679,35691,36111,36109,36489,36481,36485,36482,37300,37323,37912,37891,37885,38369,38704,39108,39250,39249,39336,39467,39472,39479,39477,39955,39949,40569,40629,40680,40751,40799,40803,40801,20791,20792,22209,22208,22210,22804,23660,24013,25084,25086,25885,25884,26005,26345,27387,27396,27386,27570,28748,29211,29351,29910,29908,30313,30675,31824,32399,32396,32700,34327,34349,34330,34851,34850,34849,34847,35178,35180,35261,35700,35703,35709,36115,36490,36493,36491,36703,36783,37306,37934,37939,37941,37946,37944,37938,37931,38370,38712,38713,38706,38911,39015,39013,39255,39493,39491,39488,39486,39631,39764,39761,39981,39973,40367,40372,40386,40376,40605,40687,40729,40796,40806,40807,20796,20795,22216,22218,22217,23423,24020,24018,24398,25087,25892,27402,27489,28753,28760,29568,29924,30090,30318,30316,31155,31840,31839,32894,32893,33247,35186,35183,35324,35712,36118,36119,36497,36499,36705,37192,37956,37969,37970,38717,38718,38851,38849,39019,39253,39509,39501,39634,39706,40009,39985,39998,39995,40403,40407,40756,40812,40810,40852,22220,24022,25088,25891,25899,25898,26348,27408,29914,31434,31844,31843,31845,32403,32406,32404,33250,34360,34367,34865,35722,37008,37007,37987,37984,37988,38760,39023,39260,39514,39515,39511,39635,39636,39633,40020,40023,40022,40421,40607,40692,22225,22761,25900,28766,30321,30322,30679,32592,32648,34870,34873,34914,35731,35730,35734,33399,36123,37312,37994,38722,38728,38724,38854,39024,39519,39714,39768,40031,40441,40442,40572,40573,40711,40823,40818,24307,27414,28771,31852,31854,34875,35264,36513,37313,38002,38e3,39025,39262,39638,39715,40652,28772,30682,35738,38007,38857,39522,39525,32412,35740,36522,37317,38013,38014,38012,40055,40056,40695,35924,38015,40474,29224,39530,39729,40475,40478,31858,9312,9313,9314,9315,9316,9317,9318,9319,9320,9321,9332,9333,9334,9335,9336,9337,9338,9339,9340,9341,8560,8561,8562,8563,8564,8565,8566,8567,8568,8569,20022,20031,20101,20128,20866,20886,20907,21241,21304,21353,21430,22794,23424,24027,12083,24191,24308,24400,24417,25908,26080,30098,30326,36789,38582,168,710,12541,12542,12445,12446,12291,20189,12293,12294,12295,12540,65339,65341,10045,12353,12354,12355,12356,12357,12358,12359,12360,12361,12362,12363,12364,12365,12366,12367,12368,12369,12370,12371,12372,12373,12374,12375,12376,12377,12378,12379,12380,12381,12382,12383,12384,12385,12386,12387,12388,12389,12390,12391,12392,12393,12394,12395,12396,12397,12398,12399,12400,12401,12402,12403,12404,12405,12406,12407,12408,12409,12410,12411,12412,12413,12414,12415,12416,12417,12418,12419,12420,12421,12422,12423,12424,12425,12426,12427,12428,12429,12430,12431,12432,12433,12434,12435,12449,12450,12451,12452,12453,12454,12455,12456,12457,12458,12459,12460,12461,12462,12463,12464,12465,12466,12467,12468,12469,12470,12471,12472,12473,12474,12475,12476,12477,12478,12479,12480,12481,12482,12483,12484,12485,12486,12487,12488,12489,12490,12491,12492,12493,12494,12495,12496,12497,12498,12499,12500,12501,12502,12503,12504,12505,12506,12507,12508,12509,12510,12511,12512,12513,12514,12515,12516,12517,12518,12519,12520,12521,12522,12523,12524,12525,12526,12527,12528,12529,12530,12531,12532,12533,12534,1040,1041,1042,1043,1044,1045,1025,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1075,1076,1077,1105,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,8679,8632,8633,12751,131276,20058,131210,20994,17553,40880,20872,40881,161287,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,65506,65508,65287,65282,12849,8470,8481,12443,12444,11904,11908,11910,11911,11912,11914,11916,11917,11925,11932,11933,11941,11943,11946,11948,11950,11958,11964,11966,11974,11978,11980,11981,11983,11990,11991,11998,12003,null,null,null,643,592,603,596,629,339,248,331,650,618,20034,20060,20981,21274,21378,19975,19980,20039,20109,22231,64012,23662,24435,19983,20871,19982,20014,20115,20162,20169,20168,20888,21244,21356,21433,22304,22787,22828,23568,24063,26081,27571,27596,27668,29247,20017,20028,20200,20188,20201,20193,20189,20186,21004,21276,21324,22306,22307,22807,22831,23425,23428,23570,23611,23668,23667,24068,24192,24194,24521,25097,25168,27669,27702,27715,27711,27707,29358,29360,29578,31160,32906,38430,20238,20248,20268,20213,20244,20209,20224,20215,20232,20253,20226,20229,20258,20243,20228,20212,20242,20913,21011,21001,21008,21158,21282,21279,21325,21386,21511,22241,22239,22318,22314,22324,22844,22912,22908,22917,22907,22910,22903,22911,23382,23573,23589,23676,23674,23675,23678,24031,24181,24196,24322,24346,24436,24533,24532,24527,25180,25182,25188,25185,25190,25186,25177,25184,25178,25189,26095,26094,26430,26425,26424,26427,26426,26431,26428,26419,27672,27718,27730,27740,27727,27722,27732,27723,27724,28785,29278,29364,29365,29582,29994,30335,31349,32593,33400,33404,33408,33405,33407,34381,35198,37017,37015,37016,37019,37012,38434,38436,38432,38435,20310,20283,20322,20297,20307,20324,20286,20327,20306,20319,20289,20312,20269,20275,20287,20321,20879,20921,21020,21022,21025,21165,21166,21257,21347,21362,21390,21391,21552,21559,21546,21588,21573,21529,21532,21541,21528,21565,21583,21569,21544,21540,21575,22254,22247,22245,22337,22341,22348,22345,22347,22354,22790,22848,22950,22936,22944,22935,22926,22946,22928,22927,22951,22945,23438,23442,23592,23594,23693,23695,23688,23691,23689,23698,23690,23686,23699,23701,24032,24074,24078,24203,24201,24204,24200,24205,24325,24349,24440,24438,24530,24529,24528,24557,24552,24558,24563,24545,24548,24547,24570,24559,24567,24571,24576,24564,25146,25219,25228,25230,25231,25236,25223,25201,25211,25210,25200,25217,25224,25207,25213,25202,25204,25911,26096,26100,26099,26098,26101,26437,26439,26457,26453,26444,26440,26461,26445,26458,26443,27600,27673,27674,27768,27751,27755,27780,27787,27791,27761,27759,27753,27802,27757,27783,27797,27804,27750,27763,27749,27771,27790,28788,28794,29283,29375,29373,29379,29382,29377,29370,29381,29589,29591,29587,29588,29586,30010,30009,30100,30101,30337,31037,32820,32917,32921,32912,32914,32924,33424,33423,33413,33422,33425,33427,33418,33411,33412,35960,36809,36799,37023,37025,37029,37022,37031,37024,38448,38440,38447,38445,20019,20376,20348,20357,20349,20352,20359,20342,20340,20361,20356,20343,20300,20375,20330,20378,20345,20353,20344,20368,20380,20372,20382,20370,20354,20373,20331,20334,20894,20924,20926,21045,21042,21043,21062,21041,21180,21258,21259,21308,21394,21396,21639,21631,21633,21649,21634,21640,21611,21626,21630,21605,21612,21620,21606,21645,21615,21601,21600,21656,21603,21607,21604,22263,22265,22383,22386,22381,22379,22385,22384,22390,22400,22389,22395,22387,22388,22370,22376,22397,22796,22853,22965,22970,22991,22990,22962,22988,22977,22966,22972,22979,22998,22961,22973,22976,22984,22964,22983,23394,23397,23443,23445,23620,23623,23726,23716,23712,23733,23727,23720,23724,23711,23715,23725,23714,23722,23719,23709,23717,23734,23728,23718,24087,24084,24089,24360,24354,24355,24356,24404,24450,24446,24445,24542,24549,24621,24614,24601,24626,24587,24628,24586,24599,24627,24602,24606,24620,24610,24589,24592,24622,24595,24593,24588,24585,24604,25108,25149,25261,25268,25297,25278,25258,25270,25290,25262,25267,25263,25275,25257,25264,25272,25917,26024,26043,26121,26108,26116,26130,26120,26107,26115,26123,26125,26117,26109,26129,26128,26358,26378,26501,26476,26510,26514,26486,26491,26520,26502,26500,26484,26509,26508,26490,26527,26513,26521,26499,26493,26497,26488,26489,26516,27429,27520,27518,27614,27677,27795,27884,27883,27886,27865,27830,27860,27821,27879,27831,27856,27842,27834,27843,27846,27885,27890,27858,27869,27828,27786,27805,27776,27870,27840,27952,27853,27847,27824,27897,27855,27881,27857,28820,28824,28805,28819,28806,28804,28817,28822,28802,28826,28803,29290,29398,29387,29400,29385,29404,29394,29396,29402,29388,29393,29604,29601,29613,29606,29602,29600,29612,29597,29917,29928,30015,30016,30014,30092,30104,30383,30451,30449,30448,30453,30712,30716,30713,30715,30714,30711,31042,31039,31173,31352,31355,31483,31861,31997,32821,32911,32942,32931,32952,32949,32941,33312,33440,33472,33451,33434,33432,33435,33461,33447,33454,33468,33438,33466,33460,33448,33441,33449,33474,33444,33475,33462,33442,34416,34415,34413,34414,35926,36818,36811,36819,36813,36822,36821,36823,37042,37044,37039,37043,37040,38457,38461,38460,38458,38467,20429,20421,20435,20402,20425,20427,20417,20436,20444,20441,20411,20403,20443,20423,20438,20410,20416,20409,20460,21060,21065,21184,21186,21309,21372,21399,21398,21401,21400,21690,21665,21677,21669,21711,21699,33549,21687,21678,21718,21686,21701,21702,21664,21616,21692,21666,21694,21618,21726,21680,22453,22430,22431,22436,22412,22423,22429,22427,22420,22424,22415,22425,22437,22426,22421,22772,22797,22867,23009,23006,23022,23040,23025,23005,23034,23037,23036,23030,23012,23026,23031,23003,23017,23027,23029,23008,23038,23028,23021,23464,23628,23760,23768,23756,23767,23755,23771,23774,23770,23753,23751,23754,23766,23763,23764,23759,23752,23750,23758,23775,23800,24057,24097,24098,24099,24096,24100,24240,24228,24226,24219,24227,24229,24327,24366,24406,24454,24631,24633,24660,24690,24670,24645,24659,24647,24649,24667,24652,24640,24642,24671,24612,24644,24664,24678,24686,25154,25155,25295,25357,25355,25333,25358,25347,25323,25337,25359,25356,25336,25334,25344,25363,25364,25338,25365,25339,25328,25921,25923,26026,26047,26166,26145,26162,26165,26140,26150,26146,26163,26155,26170,26141,26164,26169,26158,26383,26384,26561,26610,26568,26554,26588,26555,26616,26584,26560,26551,26565,26603,26596,26591,26549,26573,26547,26615,26614,26606,26595,26562,26553,26574,26599,26608,26546,26620,26566,26605,26572,26542,26598,26587,26618,26569,26570,26563,26602,26571,27432,27522,27524,27574,27606,27608,27616,27680,27681,27944,27956,27949,27935,27964,27967,27922,27914,27866,27955,27908,27929,27962,27930,27921,27904,27933,27970,27905,27928,27959,27907,27919,27968,27911,27936,27948,27912,27938,27913,27920,28855,28831,28862,28849,28848,28833,28852,28853,28841,29249,29257,29258,29292,29296,29299,29294,29386,29412,29416,29419,29407,29418,29414,29411,29573,29644,29634,29640,29637,29625,29622,29621,29620,29675,29631,29639,29630,29635,29638,29624,29643,29932,29934,29998,30023,30024,30119,30122,30329,30404,30472,30467,30468,30469,30474,30455,30459,30458,30695,30696,30726,30737,30738,30725,30736,30735,30734,30729,30723,30739,31050,31052,31051,31045,31044,31189,31181,31183,31190,31182,31360,31358,31441,31488,31489,31866,31864,31865,31871,31872,31873,32003,32008,32001,32600,32657,32653,32702,32775,32782,32783,32788,32823,32984,32967,32992,32977,32968,32962,32976,32965,32995,32985,32988,32970,32981,32969,32975,32983,32998,32973,33279,33313,33428,33497,33534,33529,33543,33512,33536,33493,33594,33515,33494,33524,33516,33505,33522,33525,33548,33531,33526,33520,33514,33508,33504,33530,33523,33517,34423,34420,34428,34419,34881,34894,34919,34922,34921,35283,35332,35335,36210,36835,36833,36846,36832,37105,37053,37055,37077,37061,37054,37063,37067,37064,37332,37331,38484,38479,38481,38483,38474,38478,20510,20485,20487,20499,20514,20528,20507,20469,20468,20531,20535,20524,20470,20471,20503,20508,20512,20519,20533,20527,20529,20494,20826,20884,20883,20938,20932,20933,20936,20942,21089,21082,21074,21086,21087,21077,21090,21197,21262,21406,21798,21730,21783,21778,21735,21747,21732,21786,21759,21764,21768,21739,21777,21765,21745,21770,21755,21751,21752,21728,21774,21763,21771,22273,22274,22476,22578,22485,22482,22458,22470,22461,22460,22456,22454,22463,22471,22480,22457,22465,22798,22858,23065,23062,23085,23086,23061,23055,23063,23050,23070,23091,23404,23463,23469,23468,23555,23638,23636,23788,23807,23790,23793,23799,23808,23801,24105,24104,24232,24238,24234,24236,24371,24368,24423,24669,24666,24679,24641,24738,24712,24704,24722,24705,24733,24707,24725,24731,24727,24711,24732,24718,25113,25158,25330,25360,25430,25388,25412,25413,25398,25411,25572,25401,25419,25418,25404,25385,25409,25396,25432,25428,25433,25389,25415,25395,25434,25425,25400,25431,25408,25416,25930,25926,26054,26051,26052,26050,26186,26207,26183,26193,26386,26387,26655,26650,26697,26674,26675,26683,26699,26703,26646,26673,26652,26677,26667,26669,26671,26702,26692,26676,26653,26642,26644,26662,26664,26670,26701,26682,26661,26656,27436,27439,27437,27441,27444,27501,32898,27528,27622,27620,27624,27619,27618,27623,27685,28026,28003,28004,28022,27917,28001,28050,27992,28002,28013,28015,28049,28045,28143,28031,28038,27998,28007,28e3,28055,28016,28028,27999,28034,28056,27951,28008,28043,28030,28032,28036,27926,28035,28027,28029,28021,28048,28892,28883,28881,28893,28875,32569,28898,28887,28882,28894,28896,28884,28877,28869,28870,28871,28890,28878,28897,29250,29304,29303,29302,29440,29434,29428,29438,29430,29427,29435,29441,29651,29657,29669,29654,29628,29671,29667,29673,29660,29650,29659,29652,29661,29658,29655,29656,29672,29918,29919,29940,29941,29985,30043,30047,30128,30145,30139,30148,30144,30143,30134,30138,30346,30409,30493,30491,30480,30483,30482,30499,30481,30485,30489,30490,30498,30503,30755,30764,30754,30773,30767,30760,30766,30763,30753,30761,30771,30762,30769,31060,31067,31055,31068,31059,31058,31057,31211,31212,31200,31214,31213,31210,31196,31198,31197,31366,31369,31365,31371,31372,31370,31367,31448,31504,31492,31507,31493,31503,31496,31498,31502,31497,31506,31876,31889,31882,31884,31880,31885,31877,32030,32029,32017,32014,32024,32022,32019,32031,32018,32015,32012,32604,32609,32606,32608,32605,32603,32662,32658,32707,32706,32704,32790,32830,32825,33018,33010,33017,33013,33025,33019,33024,33281,33327,33317,33587,33581,33604,33561,33617,33573,33622,33599,33601,33574,33564,33570,33602,33614,33563,33578,33544,33596,33613,33558,33572,33568,33591,33583,33577,33607,33605,33612,33619,33566,33580,33611,33575,33608,34387,34386,34466,34472,34454,34445,34449,34462,34439,34455,34438,34443,34458,34437,34469,34457,34465,34471,34453,34456,34446,34461,34448,34452,34883,34884,34925,34933,34934,34930,34944,34929,34943,34927,34947,34942,34932,34940,35346,35911,35927,35963,36004,36003,36214,36216,36277,36279,36278,36561,36563,36862,36853,36866,36863,36859,36868,36860,36854,37078,37088,37081,37082,37091,37087,37093,37080,37083,37079,37084,37092,37200,37198,37199,37333,37346,37338,38492,38495,38588,39139,39647,39727,20095,20592,20586,20577,20574,20576,20563,20555,20573,20594,20552,20557,20545,20571,20554,20578,20501,20549,20575,20585,20587,20579,20580,20550,20544,20590,20595,20567,20561,20944,21099,21101,21100,21102,21206,21203,21293,21404,21877,21878,21820,21837,21840,21812,21802,21841,21858,21814,21813,21808,21842,21829,21772,21810,21861,21838,21817,21832,21805,21819,21824,21835,22282,22279,22523,22548,22498,22518,22492,22516,22528,22509,22525,22536,22520,22539,22515,22479,22535,22510,22499,22514,22501,22508,22497,22542,22524,22544,22503,22529,22540,22513,22505,22512,22541,22532,22876,23136,23128,23125,23143,23134,23096,23093,23149,23120,23135,23141,23148,23123,23140,23127,23107,23133,23122,23108,23131,23112,23182,23102,23117,23097,23116,23152,23145,23111,23121,23126,23106,23132,23410,23406,23489,23488,23641,23838,23819,23837,23834,23840,23820,23848,23821,23846,23845,23823,23856,23826,23843,23839,23854,24126,24116,24241,24244,24249,24242,24243,24374,24376,24475,24470,24479,24714,24720,24710,24766,24752,24762,24787,24788,24783,24804,24793,24797,24776,24753,24795,24759,24778,24767,24771,24781,24768,25394,25445,25482,25474,25469,25533,25502,25517,25501,25495,25515,25486,25455,25479,25488,25454,25519,25461,25500,25453,25518,25468,25508,25403,25503,25464,25477,25473,25489,25485,25456,25939,26061,26213,26209,26203,26201,26204,26210,26392,26745,26759,26768,26780,26733,26734,26798,26795,26966,26735,26787,26796,26793,26741,26740,26802,26767,26743,26770,26748,26731,26738,26794,26752,26737,26750,26779,26774,26763,26784,26761,26788,26744,26747,26769,26764,26762,26749,27446,27443,27447,27448,27537,27535,27533,27534,27532,27690,28096,28075,28084,28083,28276,28076,28137,28130,28087,28150,28116,28160,28104,28128,28127,28118,28094,28133,28124,28125,28123,28148,28106,28093,28141,28144,28090,28117,28098,28111,28105,28112,28146,28115,28157,28119,28109,28131,28091,28922,28941,28919,28951,28916,28940,28912,28932,28915,28944,28924,28927,28934,28947,28928,28920,28918,28939,28930,28942,29310,29307,29308,29311,29469,29463,29447,29457,29464,29450,29448,29439,29455,29470,29576,29686,29688,29685,29700,29697,29693,29703,29696,29690,29692,29695,29708,29707,29684,29704,30052,30051,30158,30162,30159,30155,30156,30161,30160,30351,30345,30419,30521,30511,30509,30513,30514,30516,30515,30525,30501,30523,30517,30792,30802,30793,30797,30794,30796,30758,30789,30800,31076,31079,31081,31082,31075,31083,31073,31163,31226,31224,31222,31223,31375,31380,31376,31541,31559,31540,31525,31536,31522,31524,31539,31512,31530,31517,31537,31531,31533,31535,31538,31544,31514,31523,31892,31896,31894,31907,32053,32061,32056,32054,32058,32069,32044,32041,32065,32071,32062,32063,32074,32059,32040,32611,32661,32668,32669,32667,32714,32715,32717,32720,32721,32711,32719,32713,32799,32798,32795,32839,32835,32840,33048,33061,33049,33051,33069,33055,33068,33054,33057,33045,33063,33053,33058,33297,33336,33331,33338,33332,33330,33396,33680,33699,33704,33677,33658,33651,33700,33652,33679,33665,33685,33689,33653,33684,33705,33661,33667,33676,33693,33691,33706,33675,33662,33701,33711,33672,33687,33712,33663,33702,33671,33710,33654,33690,34393,34390,34495,34487,34498,34497,34501,34490,34480,34504,34489,34483,34488,34508,34484,34491,34492,34499,34493,34494,34898,34953,34965,34984,34978,34986,34970,34961,34977,34975,34968,34983,34969,34971,34967,34980,34988,34956,34963,34958,35202,35286,35289,35285,35376,35367,35372,35358,35897,35899,35932,35933,35965,36005,36221,36219,36217,36284,36290,36281,36287,36289,36568,36574,36573,36572,36567,36576,36577,36900,36875,36881,36892,36876,36897,37103,37098,37104,37108,37106,37107,37076,37099,37100,37097,37206,37208,37210,37203,37205,37356,37364,37361,37363,37368,37348,37369,37354,37355,37367,37352,37358,38266,38278,38280,38524,38509,38507,38513,38511,38591,38762,38916,39141,39319,20635,20629,20628,20638,20619,20643,20611,20620,20622,20637,20584,20636,20626,20610,20615,20831,20948,21266,21265,21412,21415,21905,21928,21925,21933,21879,22085,21922,21907,21896,21903,21941,21889,21923,21906,21924,21885,21900,21926,21887,21909,21921,21902,22284,22569,22583,22553,22558,22567,22563,22568,22517,22600,22565,22556,22555,22579,22591,22582,22574,22585,22584,22573,22572,22587,22881,23215,23188,23199,23162,23202,23198,23160,23206,23164,23205,23212,23189,23214,23095,23172,23178,23191,23171,23179,23209,23163,23165,23180,23196,23183,23187,23197,23530,23501,23499,23508,23505,23498,23502,23564,23600,23863,23875,23915,23873,23883,23871,23861,23889,23886,23893,23859,23866,23890,23869,23857,23897,23874,23865,23881,23864,23868,23858,23862,23872,23877,24132,24129,24408,24486,24485,24491,24777,24761,24780,24802,24782,24772,24852,24818,24842,24854,24837,24821,24851,24824,24828,24830,24769,24835,24856,24861,24848,24831,24836,24843,25162,25492,25521,25520,25550,25573,25576,25583,25539,25757,25587,25546,25568,25590,25557,25586,25589,25697,25567,25534,25565,25564,25540,25560,25555,25538,25543,25548,25547,25544,25584,25559,25561,25906,25959,25962,25956,25948,25960,25957,25996,26013,26014,26030,26064,26066,26236,26220,26235,26240,26225,26233,26218,26226,26369,26892,26835,26884,26844,26922,26860,26858,26865,26895,26838,26871,26859,26852,26870,26899,26896,26867,26849,26887,26828,26888,26992,26804,26897,26863,26822,26900,26872,26832,26877,26876,26856,26891,26890,26903,26830,26824,26845,26846,26854,26868,26833,26886,26836,26857,26901,26917,26823,27449,27451,27455,27452,27540,27543,27545,27541,27581,27632,27634,27635,27696,28156,28230,28231,28191,28233,28296,28220,28221,28229,28258,28203,28223,28225,28253,28275,28188,28211,28235,28224,28241,28219,28163,28206,28254,28264,28252,28257,28209,28200,28256,28273,28267,28217,28194,28208,28243,28261,28199,28280,28260,28279,28245,28281,28242,28262,28213,28214,28250,28960,28958,28975,28923,28974,28977,28963,28965,28962,28978,28959,28968,28986,28955,29259,29274,29320,29321,29318,29317,29323,29458,29451,29488,29474,29489,29491,29479,29490,29485,29478,29475,29493,29452,29742,29740,29744,29739,29718,29722,29729,29741,29745,29732,29731,29725,29737,29728,29746,29947,29999,30063,30060,30183,30170,30177,30182,30173,30175,30180,30167,30357,30354,30426,30534,30535,30532,30541,30533,30538,30542,30539,30540,30686,30700,30816,30820,30821,30812,30829,30833,30826,30830,30832,30825,30824,30814,30818,31092,31091,31090,31088,31234,31242,31235,31244,31236,31385,31462,31460,31562,31547,31556,31560,31564,31566,31552,31576,31557,31906,31902,31912,31905,32088,32111,32099,32083,32086,32103,32106,32079,32109,32092,32107,32082,32084,32105,32081,32095,32078,32574,32575,32613,32614,32674,32672,32673,32727,32849,32847,32848,33022,32980,33091,33098,33106,33103,33095,33085,33101,33082,33254,33262,33271,33272,33273,33284,33340,33341,33343,33397,33595,33743,33785,33827,33728,33768,33810,33767,33764,33788,33782,33808,33734,33736,33771,33763,33727,33793,33757,33765,33752,33791,33761,33739,33742,33750,33781,33737,33801,33807,33758,33809,33798,33730,33779,33749,33786,33735,33745,33770,33811,33731,33772,33774,33732,33787,33751,33762,33819,33755,33790,34520,34530,34534,34515,34531,34522,34538,34525,34539,34524,34540,34537,34519,34536,34513,34888,34902,34901,35002,35031,35001,35e3,35008,35006,34998,35004,34999,35005,34994,35073,35017,35221,35224,35223,35293,35290,35291,35406,35405,35385,35417,35392,35415,35416,35396,35397,35410,35400,35409,35402,35404,35407,35935,35969,35968,36026,36030,36016,36025,36021,36228,36224,36233,36312,36307,36301,36295,36310,36316,36303,36309,36313,36296,36311,36293,36591,36599,36602,36601,36582,36590,36581,36597,36583,36584,36598,36587,36593,36588,36596,36585,36909,36916,36911,37126,37164,37124,37119,37116,37128,37113,37115,37121,37120,37127,37125,37123,37217,37220,37215,37218,37216,37377,37386,37413,37379,37402,37414,37391,37388,37376,37394,37375,37373,37382,37380,37415,37378,37404,37412,37401,37399,37381,37398,38267,38285,38284,38288,38535,38526,38536,38537,38531,38528,38594,38600,38595,38641,38640,38764,38768,38766,38919,39081,39147,40166,40697,20099,20100,20150,20669,20671,20678,20654,20676,20682,20660,20680,20674,20656,20673,20666,20657,20683,20681,20662,20664,20951,21114,21112,21115,21116,21955,21979,21964,21968,21963,21962,21981,21952,21972,21956,21993,21951,21970,21901,21967,21973,21986,21974,21960,22002,21965,21977,21954,22292,22611,22632,22628,22607,22605,22601,22639,22613,22606,22621,22617,22629,22619,22589,22627,22641,22780,23239,23236,23243,23226,23224,23217,23221,23216,23231,23240,23227,23238,23223,23232,23242,23220,23222,23245,23225,23184,23510,23512,23513,23583,23603,23921,23907,23882,23909,23922,23916,23902,23912,23911,23906,24048,24143,24142,24138,24141,24139,24261,24268,24262,24267,24263,24384,24495,24493,24823,24905,24906,24875,24901,24886,24882,24878,24902,24879,24911,24873,24896,25120,37224,25123,25125,25124,25541,25585,25579,25616,25618,25609,25632,25636,25651,25667,25631,25621,25624,25657,25655,25634,25635,25612,25638,25648,25640,25665,25653,25647,25610,25626,25664,25637,25639,25611,25575,25627,25646,25633,25614,25967,26002,26067,26246,26252,26261,26256,26251,26250,26265,26260,26232,26400,26982,26975,26936,26958,26978,26993,26943,26949,26986,26937,26946,26967,26969,27002,26952,26953,26933,26988,26931,26941,26981,26864,27e3,26932,26985,26944,26991,26948,26998,26968,26945,26996,26956,26939,26955,26935,26972,26959,26961,26930,26962,26927,27003,26940,27462,27461,27459,27458,27464,27457,27547,64013,27643,27644,27641,27639,27640,28315,28374,28360,28303,28352,28319,28307,28308,28320,28337,28345,28358,28370,28349,28353,28318,28361,28343,28336,28365,28326,28367,28338,28350,28355,28380,28376,28313,28306,28302,28301,28324,28321,28351,28339,28368,28362,28311,28334,28323,28999,29012,29010,29027,29024,28993,29021,29026,29042,29048,29034,29025,28994,29016,28995,29003,29040,29023,29008,29011,28996,29005,29018,29263,29325,29324,29329,29328,29326,29500,29506,29499,29498,29504,29514,29513,29764,29770,29771,29778,29777,29783,29760,29775,29776,29774,29762,29766,29773,29780,29921,29951,29950,29949,29981,30073,30071,27011,30191,30223,30211,30199,30206,30204,30201,30200,30224,30203,30198,30189,30197,30205,30361,30389,30429,30549,30559,30560,30546,30550,30554,30569,30567,30548,30553,30573,30688,30855,30874,30868,30863,30852,30869,30853,30854,30881,30851,30841,30873,30848,30870,30843,31100,31106,31101,31097,31249,31256,31257,31250,31255,31253,31266,31251,31259,31248,31395,31394,31390,31467,31590,31588,31597,31604,31593,31602,31589,31603,31601,31600,31585,31608,31606,31587,31922,31924,31919,32136,32134,32128,32141,32127,32133,32122,32142,32123,32131,32124,32140,32148,32132,32125,32146,32621,32619,32615,32616,32620,32678,32677,32679,32731,32732,32801,33124,33120,33143,33116,33129,33115,33122,33138,26401,33118,33142,33127,33135,33092,33121,33309,33353,33348,33344,33346,33349,34033,33855,33878,33910,33913,33935,33933,33893,33873,33856,33926,33895,33840,33869,33917,33882,33881,33908,33907,33885,34055,33886,33847,33850,33844,33914,33859,33912,33842,33861,33833,33753,33867,33839,33858,33837,33887,33904,33849,33870,33868,33874,33903,33989,33934,33851,33863,33846,33843,33896,33918,33860,33835,33888,33876,33902,33872,34571,34564,34551,34572,34554,34518,34549,34637,34552,34574,34569,34561,34550,34573,34565,35030,35019,35021,35022,35038,35035,35034,35020,35024,35205,35227,35295,35301,35300,35297,35296,35298,35292,35302,35446,35462,35455,35425,35391,35447,35458,35460,35445,35459,35457,35444,35450,35900,35915,35914,35941,35940,35942,35974,35972,35973,36044,36200,36201,36241,36236,36238,36239,36237,36243,36244,36240,36242,36336,36320,36332,36337,36334,36304,36329,36323,36322,36327,36338,36331,36340,36614,36607,36609,36608,36613,36615,36616,36610,36619,36946,36927,36932,36937,36925,37136,37133,37135,37137,37142,37140,37131,37134,37230,37231,37448,37458,37424,37434,37478,37427,37477,37470,37507,37422,37450,37446,37485,37484,37455,37472,37479,37487,37430,37473,37488,37425,37460,37475,37456,37490,37454,37459,37452,37462,37426,38303,38300,38302,38299,38546,38547,38545,38551,38606,38650,38653,38648,38645,38771,38775,38776,38770,38927,38925,38926,39084,39158,39161,39343,39346,39344,39349,39597,39595,39771,40170,40173,40167,40576,40701,20710,20692,20695,20712,20723,20699,20714,20701,20708,20691,20716,20720,20719,20707,20704,20952,21120,21121,21225,21227,21296,21420,22055,22037,22028,22034,22012,22031,22044,22017,22035,22018,22010,22045,22020,22015,22009,22665,22652,22672,22680,22662,22657,22655,22644,22667,22650,22663,22673,22670,22646,22658,22664,22651,22676,22671,22782,22891,23260,23278,23269,23253,23274,23258,23277,23275,23283,23266,23264,23259,23276,23262,23261,23257,23272,23263,23415,23520,23523,23651,23938,23936,23933,23942,23930,23937,23927,23946,23945,23944,23934,23932,23949,23929,23935,24152,24153,24147,24280,24273,24279,24270,24284,24277,24281,24274,24276,24388,24387,24431,24502,24876,24872,24897,24926,24945,24947,24914,24915,24946,24940,24960,24948,24916,24954,24923,24933,24891,24938,24929,24918,25129,25127,25131,25643,25677,25691,25693,25716,25718,25714,25715,25725,25717,25702,25766,25678,25730,25694,25692,25675,25683,25696,25680,25727,25663,25708,25707,25689,25701,25719,25971,26016,26273,26272,26271,26373,26372,26402,27057,27062,27081,27040,27086,27030,27056,27052,27068,27025,27033,27022,27047,27021,27049,27070,27055,27071,27076,27069,27044,27092,27065,27082,27034,27087,27059,27027,27050,27041,27038,27097,27031,27024,27074,27061,27045,27078,27466,27469,27467,27550,27551,27552,27587,27588,27646,28366,28405,28401,28419,28453,28408,28471,28411,28462,28425,28494,28441,28442,28455,28440,28475,28434,28397,28426,28470,28531,28409,28398,28461,28480,28464,28476,28469,28395,28423,28430,28483,28421,28413,28406,28473,28444,28412,28474,28447,28429,28446,28424,28449,29063,29072,29065,29056,29061,29058,29071,29051,29062,29057,29079,29252,29267,29335,29333,29331,29507,29517,29521,29516,29794,29811,29809,29813,29810,29799,29806,29952,29954,29955,30077,30096,30230,30216,30220,30229,30225,30218,30228,30392,30593,30588,30597,30594,30574,30592,30575,30590,30595,30898,30890,30900,30893,30888,30846,30891,30878,30885,30880,30892,30882,30884,31128,31114,31115,31126,31125,31124,31123,31127,31112,31122,31120,31275,31306,31280,31279,31272,31270,31400,31403,31404,31470,31624,31644,31626,31633,31632,31638,31629,31628,31643,31630,31621,31640,21124,31641,31652,31618,31931,31935,31932,31930,32167,32183,32194,32163,32170,32193,32192,32197,32157,32206,32196,32198,32203,32204,32175,32185,32150,32188,32159,32166,32174,32169,32161,32201,32627,32738,32739,32741,32734,32804,32861,32860,33161,33158,33155,33159,33165,33164,33163,33301,33943,33956,33953,33951,33978,33998,33986,33964,33966,33963,33977,33972,33985,33997,33962,33946,33969,34e3,33949,33959,33979,33954,33940,33991,33996,33947,33961,33967,33960,34006,33944,33974,33999,33952,34007,34004,34002,34011,33968,33937,34401,34611,34595,34600,34667,34624,34606,34590,34593,34585,34587,34627,34604,34625,34622,34630,34592,34610,34602,34605,34620,34578,34618,34609,34613,34626,34598,34599,34616,34596,34586,34608,34577,35063,35047,35057,35058,35066,35070,35054,35068,35062,35067,35056,35052,35051,35229,35233,35231,35230,35305,35307,35304,35499,35481,35467,35474,35471,35478,35901,35944,35945,36053,36047,36055,36246,36361,36354,36351,36365,36349,36362,36355,36359,36358,36357,36350,36352,36356,36624,36625,36622,36621,37155,37148,37152,37154,37151,37149,37146,37156,37153,37147,37242,37234,37241,37235,37541,37540,37494,37531,37498,37536,37524,37546,37517,37542,37530,37547,37497,37527,37503,37539,37614,37518,37506,37525,37538,37501,37512,37537,37514,37510,37516,37529,37543,37502,37511,37545,37533,37515,37421,38558,38561,38655,38744,38781,38778,38782,38787,38784,38786,38779,38788,38785,38783,38862,38861,38934,39085,39086,39170,39168,39175,39325,39324,39363,39353,39355,39354,39362,39357,39367,39601,39651,39655,39742,39743,39776,39777,39775,40177,40178,40181,40615,20735,20739,20784,20728,20742,20743,20726,20734,20747,20748,20733,20746,21131,21132,21233,21231,22088,22082,22092,22069,22081,22090,22089,22086,22104,22106,22080,22067,22077,22060,22078,22072,22058,22074,22298,22699,22685,22705,22688,22691,22703,22700,22693,22689,22783,23295,23284,23293,23287,23286,23299,23288,23298,23289,23297,23303,23301,23311,23655,23961,23959,23967,23954,23970,23955,23957,23968,23964,23969,23962,23966,24169,24157,24160,24156,32243,24283,24286,24289,24393,24498,24971,24963,24953,25009,25008,24994,24969,24987,24979,25007,25005,24991,24978,25002,24993,24973,24934,25011,25133,25710,25712,25750,25760,25733,25751,25756,25743,25739,25738,25740,25763,25759,25704,25777,25752,25974,25978,25977,25979,26034,26035,26293,26288,26281,26290,26295,26282,26287,27136,27142,27159,27109,27128,27157,27121,27108,27168,27135,27116,27106,27163,27165,27134,27175,27122,27118,27156,27127,27111,27200,27144,27110,27131,27149,27132,27115,27145,27140,27160,27173,27151,27126,27174,27143,27124,27158,27473,27557,27555,27554,27558,27649,27648,27647,27650,28481,28454,28542,28551,28614,28562,28557,28553,28556,28514,28495,28549,28506,28566,28534,28524,28546,28501,28530,28498,28496,28503,28564,28563,28509,28416,28513,28523,28541,28519,28560,28499,28555,28521,28543,28565,28515,28535,28522,28539,29106,29103,29083,29104,29088,29082,29097,29109,29085,29093,29086,29092,29089,29098,29084,29095,29107,29336,29338,29528,29522,29534,29535,29536,29533,29531,29537,29530,29529,29538,29831,29833,29834,29830,29825,29821,29829,29832,29820,29817,29960,29959,30078,30245,30238,30233,30237,30236,30243,30234,30248,30235,30364,30365,30366,30363,30605,30607,30601,30600,30925,30907,30927,30924,30929,30926,30932,30920,30915,30916,30921,31130,31137,31136,31132,31138,31131,27510,31289,31410,31412,31411,31671,31691,31678,31660,31694,31663,31673,31690,31669,31941,31944,31948,31947,32247,32219,32234,32231,32215,32225,32259,32250,32230,32246,32241,32240,32238,32223,32630,32684,32688,32685,32749,32747,32746,32748,32742,32744,32868,32871,33187,33183,33182,33173,33186,33177,33175,33302,33359,33363,33362,33360,33358,33361,34084,34107,34063,34048,34089,34062,34057,34061,34079,34058,34087,34076,34043,34091,34042,34056,34060,34036,34090,34034,34069,34039,34027,34035,34044,34066,34026,34025,34070,34046,34088,34077,34094,34050,34045,34078,34038,34097,34086,34023,34024,34032,34031,34041,34072,34080,34096,34059,34073,34095,34402,34646,34659,34660,34679,34785,34675,34648,34644,34651,34642,34657,34650,34641,34654,34669,34666,34640,34638,34655,34653,34671,34668,34682,34670,34652,34661,34639,34683,34677,34658,34663,34665,34906,35077,35084,35092,35083,35095,35096,35097,35078,35094,35089,35086,35081,35234,35236,35235,35309,35312,35308,35535,35526,35512,35539,35537,35540,35541,35515,35543,35518,35520,35525,35544,35523,35514,35517,35545,35902,35917,35983,36069,36063,36057,36072,36058,36061,36071,36256,36252,36257,36251,36384,36387,36389,36388,36398,36373,36379,36374,36369,36377,36390,36391,36372,36370,36376,36371,36380,36375,36378,36652,36644,36632,36634,36640,36643,36630,36631,36979,36976,36975,36967,36971,37167,37163,37161,37162,37170,37158,37166,37253,37254,37258,37249,37250,37252,37248,37584,37571,37572,37568,37593,37558,37583,37617,37599,37592,37609,37591,37597,37580,37615,37570,37608,37578,37576,37582,37606,37581,37589,37577,37600,37598,37607,37585,37587,37557,37601,37574,37556,38268,38316,38315,38318,38320,38564,38562,38611,38661,38664,38658,38746,38794,38798,38792,38864,38863,38942,38941,38950,38953,38952,38944,38939,38951,39090,39176,39162,39185,39188,39190,39191,39189,39388,39373,39375,39379,39380,39374,39369,39382,39384,39371,39383,39372,39603,39660,39659,39667,39666,39665,39750,39747,39783,39796,39793,39782,39798,39797,39792,39784,39780,39788,40188,40186,40189,40191,40183,40199,40192,40185,40187,40200,40197,40196,40579,40659,40719,40720,20764,20755,20759,20762,20753,20958,21300,21473,22128,22112,22126,22131,22118,22115,22125,22130,22110,22135,22300,22299,22728,22717,22729,22719,22714,22722,22716,22726,23319,23321,23323,23329,23316,23315,23312,23318,23336,23322,23328,23326,23535,23980,23985,23977,23975,23989,23984,23982,23978,23976,23986,23981,23983,23988,24167,24168,24166,24175,24297,24295,24294,24296,24293,24395,24508,24989,25e3,24982,25029,25012,25030,25025,25036,25018,25023,25016,24972,25815,25814,25808,25807,25801,25789,25737,25795,25819,25843,25817,25907,25983,25980,26018,26312,26302,26304,26314,26315,26319,26301,26299,26298,26316,26403,27188,27238,27209,27239,27186,27240,27198,27229,27245,27254,27227,27217,27176,27226,27195,27199,27201,27242,27236,27216,27215,27220,27247,27241,27232,27196,27230,27222,27221,27213,27214,27206,27477,27476,27478,27559,27562,27563,27592,27591,27652,27651,27654,28589,28619,28579,28615,28604,28622,28616,28510,28612,28605,28574,28618,28584,28676,28581,28590,28602,28588,28586,28623,28607,28600,28578,28617,28587,28621,28591,28594,28592,29125,29122,29119,29112,29142,29120,29121,29131,29140,29130,29127,29135,29117,29144,29116,29126,29146,29147,29341,29342,29545,29542,29543,29548,29541,29547,29546,29823,29850,29856,29844,29842,29845,29857,29963,30080,30255,30253,30257,30269,30259,30268,30261,30258,30256,30395,30438,30618,30621,30625,30620,30619,30626,30627,30613,30617,30615,30941,30953,30949,30954,30942,30947,30939,30945,30946,30957,30943,30944,31140,31300,31304,31303,31414,31416,31413,31409,31415,31710,31715,31719,31709,31701,31717,31706,31720,31737,31700,31722,31714,31708,31723,31704,31711,31954,31956,31959,31952,31953,32274,32289,32279,32268,32287,32288,32275,32270,32284,32277,32282,32290,32267,32271,32278,32269,32276,32293,32292,32579,32635,32636,32634,32689,32751,32810,32809,32876,33201,33190,33198,33209,33205,33195,33200,33196,33204,33202,33207,33191,33266,33365,33366,33367,34134,34117,34155,34125,34131,34145,34136,34112,34118,34148,34113,34146,34116,34129,34119,34147,34110,34139,34161,34126,34158,34165,34133,34151,34144,34188,34150,34141,34132,34149,34156,34403,34405,34404,34715,34703,34711,34707,34706,34696,34689,34710,34712,34681,34695,34723,34693,34704,34705,34717,34692,34708,34716,34714,34697,35102,35110,35120,35117,35118,35111,35121,35106,35113,35107,35119,35116,35103,35313,35552,35554,35570,35572,35573,35549,35604,35556,35551,35568,35528,35550,35553,35560,35583,35567,35579,35985,35986,35984,36085,36078,36081,36080,36083,36204,36206,36261,36263,36403,36414,36408,36416,36421,36406,36412,36413,36417,36400,36415,36541,36662,36654,36661,36658,36665,36663,36660,36982,36985,36987,36998,37114,37171,37173,37174,37267,37264,37265,37261,37263,37671,37662,37640,37663,37638,37647,37754,37688,37692,37659,37667,37650,37633,37702,37677,37646,37645,37579,37661,37626,37669,37651,37625,37623,37684,37634,37668,37631,37673,37689,37685,37674,37652,37644,37643,37630,37641,37632,37627,37654,38332,38349,38334,38329,38330,38326,38335,38325,38333,38569,38612,38667,38674,38672,38809,38807,38804,38896,38904,38965,38959,38962,39204,39199,39207,39209,39326,39406,39404,39397,39396,39408,39395,39402,39401,39399,39609,39615,39604,39611,39670,39674,39673,39671,39731,39808,39813,39815,39804,39806,39803,39810,39827,39826,39824,39802,39829,39805,39816,40229,40215,40224,40222,40212,40233,40221,40216,40226,40208,40217,40223,40584,40582,40583,40622,40621,40661,40662,40698,40722,40765,20774,20773,20770,20772,20768,20777,21236,22163,22156,22157,22150,22148,22147,22142,22146,22143,22145,22742,22740,22735,22738,23341,23333,23346,23331,23340,23335,23334,23343,23342,23419,23537,23538,23991,24172,24170,24510,24507,25027,25013,25020,25063,25056,25061,25060,25064,25054,25839,25833,25827,25835,25828,25832,25985,25984,26038,26074,26322,27277,27286,27265,27301,27273,27295,27291,27297,27294,27271,27283,27278,27285,27267,27304,27300,27281,27263,27302,27290,27269,27276,27282,27483,27565,27657,28620,28585,28660,28628,28643,28636,28653,28647,28646,28638,28658,28637,28642,28648,29153,29169,29160,29170,29156,29168,29154,29555,29550,29551,29847,29874,29867,29840,29866,29869,29873,29861,29871,29968,29969,29970,29967,30084,30275,30280,30281,30279,30372,30441,30645,30635,30642,30647,30646,30644,30641,30632,30704,30963,30973,30978,30971,30972,30962,30981,30969,30974,30980,31147,31144,31324,31323,31318,31320,31316,31322,31422,31424,31425,31749,31759,31730,31744,31743,31739,31758,31732,31755,31731,31746,31753,31747,31745,31736,31741,31750,31728,31729,31760,31754,31976,32301,32316,32322,32307,38984,32312,32298,32329,32320,32327,32297,32332,32304,32315,32310,32324,32314,32581,32639,32638,32637,32756,32754,32812,33211,33220,33228,33226,33221,33223,33212,33257,33371,33370,33372,34179,34176,34191,34215,34197,34208,34187,34211,34171,34212,34202,34206,34167,34172,34185,34209,34170,34168,34135,34190,34198,34182,34189,34201,34205,34177,34210,34178,34184,34181,34169,34166,34200,34192,34207,34408,34750,34730,34733,34757,34736,34732,34745,34741,34748,34734,34761,34755,34754,34764,34743,34735,34756,34762,34740,34742,34751,34744,34749,34782,34738,35125,35123,35132,35134,35137,35154,35127,35138,35245,35247,35246,35314,35315,35614,35608,35606,35601,35589,35595,35618,35599,35602,35605,35591,35597,35592,35590,35612,35603,35610,35919,35952,35954,35953,35951,35989,35988,36089,36207,36430,36429,36435,36432,36428,36423,36675,36672,36997,36990,37176,37274,37282,37275,37273,37279,37281,37277,37280,37793,37763,37807,37732,37718,37703,37756,37720,37724,37750,37705,37712,37713,37728,37741,37775,37708,37738,37753,37719,37717,37714,37711,37745,37751,37755,37729,37726,37731,37735,37760,37710,37721,38343,38336,38345,38339,38341,38327,38574,38576,38572,38688,38687,38680,38685,38681,38810,38817,38812,38814,38813,38869,38868,38897,38977,38980,38986,38985,38981,38979,39205,39211,39212,39210,39219,39218,39215,39213,39217,39216,39320,39331,39329,39426,39418,39412,39415,39417,39416,39414,39419,39421,39422,39420,39427,39614,39678,39677,39681,39676,39752,39834,39848,39838,39835,39846,39841,39845,39844,39814,39842,39840,39855,40243,40257,40295,40246,40238,40239,40241,40248,40240,40261,40258,40259,40254,40247,40256,40253,32757,40237,40586,40585,40589,40624,40648,40666,40699,40703,40740,40739,40738,40788,40864,20785,20781,20782,22168,22172,22167,22170,22173,22169,22896,23356,23657,23658,24e3,24173,24174,25048,25055,25069,25070,25073,25066,25072,25067,25046,25065,25855,25860,25853,25848,25857,25859,25852,26004,26075,26330,26331,26328,27333,27321,27325,27361,27334,27322,27318,27319,27335,27316,27309,27486,27593,27659,28679,28684,28685,28673,28677,28692,28686,28671,28672,28667,28710,28668,28663,28682,29185,29183,29177,29187,29181,29558,29880,29888,29877,29889,29886,29878,29883,29890,29972,29971,30300,30308,30297,30288,30291,30295,30298,30374,30397,30444,30658,30650,30975,30988,30995,30996,30985,30992,30994,30993,31149,31148,31327,31772,31785,31769,31776,31775,31789,31773,31782,31784,31778,31781,31792,32348,32336,32342,32355,32344,32354,32351,32337,32352,32343,32339,32693,32691,32759,32760,32885,33233,33234,33232,33375,33374,34228,34246,34240,34243,34242,34227,34229,34237,34247,34244,34239,34251,34254,34248,34245,34225,34230,34258,34340,34232,34231,34238,34409,34791,34790,34786,34779,34795,34794,34789,34783,34803,34788,34772,34780,34771,34797,34776,34787,34724,34775,34777,34817,34804,34792,34781,35155,35147,35151,35148,35142,35152,35153,35145,35626,35623,35619,35635,35632,35637,35655,35631,35644,35646,35633,35621,35639,35622,35638,35630,35620,35643,35645,35642,35906,35957,35993,35992,35991,36094,36100,36098,36096,36444,36450,36448,36439,36438,36446,36453,36455,36443,36442,36449,36445,36457,36436,36678,36679,36680,36683,37160,37178,37179,37182,37288,37285,37287,37295,37290,37813,37772,37778,37815,37787,37789,37769,37799,37774,37802,37790,37798,37781,37768,37785,37791,37773,37809,37777,37810,37796,37800,37812,37795,37797,38354,38355,38353,38579,38615,38618,24002,38623,38616,38621,38691,38690,38693,38828,38830,38824,38827,38820,38826,38818,38821,38871,38873,38870,38872,38906,38992,38993,38994,39096,39233,39228,39226,39439,39435,39433,39437,39428,39441,39434,39429,39431,39430,39616,39644,39688,39684,39685,39721,39733,39754,39756,39755,39879,39878,39875,39871,39873,39861,39864,39891,39862,39876,39865,39869,40284,40275,40271,40266,40283,40267,40281,40278,40268,40279,40274,40276,40287,40280,40282,40590,40588,40671,40705,40704,40726,40741,40747,40746,40745,40744,40780,40789,20788,20789,21142,21239,21428,22187,22189,22182,22183,22186,22188,22746,22749,22747,22802,23357,23358,23359,24003,24176,24511,25083,25863,25872,25869,25865,25868,25870,25988,26078,26077,26334,27367,27360,27340,27345,27353,27339,27359,27356,27344,27371,27343,27341,27358,27488,27568,27660,28697,28711,28704,28694,28715,28705,28706,28707,28713,28695,28708,28700,28714,29196,29194,29191,29186,29189,29349,29350,29348,29347,29345,29899,29893,29879,29891,29974,30304,30665,30666,30660,30705,31005,31003,31009,31004,30999,31006,31152,31335,31336,31795,31804,31801,31788,31803,31980,31978,32374,32373,32376,32368,32375,32367,32378,32370,32372,32360,32587,32586,32643,32646,32695,32765,32766,32888,33239,33237,33380,33377,33379,34283,34289,34285,34265,34273,34280,34266,34263,34284,34290,34296,34264,34271,34275,34268,34257,34288,34278,34287,34270,34274,34816,34810,34819,34806,34807,34825,34828,34827,34822,34812,34824,34815,34826,34818,35170,35162,35163,35159,35169,35164,35160,35165,35161,35208,35255,35254,35318,35664,35656,35658,35648,35667,35670,35668,35659,35669,35665,35650,35666,35671,35907,35959,35958,35994,36102,36103,36105,36268,36266,36269,36267,36461,36472,36467,36458,36463,36475,36546,36690,36689,36687,36688,36691,36788,37184,37183,37296,37293,37854,37831,37839,37826,37850,37840,37881,37868,37836,37849,37801,37862,37834,37844,37870,37859,37845,37828,37838,37824,37842,37863,38269,38362,38363,38625,38697,38699,38700,38696,38694,38835,38839,38838,38877,38878,38879,39004,39001,39005,38999,39103,39101,39099,39102,39240,39239,39235,39334,39335,39450,39445,39461,39453,39460,39451,39458,39456,39463,39459,39454,39452,39444,39618,39691,39690,39694,39692,39735,39914,39915,39904,39902,39908,39910,39906,39920,39892,39895,39916,39900,39897,39909,39893,39905,39898,40311,40321,40330,40324,40328,40305,40320,40312,40326,40331,40332,40317,40299,40308,40309,40304,40297,40325,40307,40315,40322,40303,40313,40319,40327,40296,40596,40593,40640,40700,40749,40768,40769,40781,40790,40791,40792,21303,22194,22197,22195,22755,23365,24006,24007,24302,24303,24512,24513,25081,25879,25878,25877,25875,26079,26344,26339,26340,27379,27376,27370,27368,27385,27377,27374,27375,28732,28725,28719,28727,28724,28721,28738,28728,28735,28730,28729,28736,28731,28723,28737,29203,29204,29352,29565,29564,29882,30379,30378,30398,30445,30668,30670,30671,30669,30706,31013,31011,31015,31016,31012,31017,31154,31342,31340,31341,31479,31817,31816,31818,31815,31813,31982,32379,32382,32385,32384,32698,32767,32889,33243,33241,33291,33384,33385,34338,34303,34305,34302,34331,34304,34294,34308,34313,34309,34316,34301,34841,34832,34833,34839,34835,34838,35171,35174,35257,35319,35680,35690,35677,35688,35683,35685,35687,35693,36270,36486,36488,36484,36697,36694,36695,36693,36696,36698,37005,37187,37185,37303,37301,37298,37299,37899,37907,37883,37920,37903,37908,37886,37909,37904,37928,37913,37901,37877,37888,37879,37895,37902,37910,37906,37882,37897,37880,37898,37887,37884,37900,37878,37905,37894,38366,38368,38367,38702,38703,38841,38843,38909,38910,39008,39010,39011,39007,39105,39106,39248,39246,39257,39244,39243,39251,39474,39476,39473,39468,39466,39478,39465,39470,39480,39469,39623,39626,39622,39696,39698,39697,39947,39944,39927,39941,39954,39928,4e4,39943,39950,39942,39959,39956,39945,40351,40345,40356,40349,40338,40344,40336,40347,40352,40340,40348,40362,40343,40353,40346,40354,40360,40350,40355,40383,40361,40342,40358,40359,40601,40603,40602,40677,40676,40679,40678,40752,40750,40795,40800,40798,40797,40793,40849,20794,20793,21144,21143,22211,22205,22206,23368,23367,24011,24015,24305,25085,25883,27394,27388,27395,27384,27392,28739,28740,28746,28744,28745,28741,28742,29213,29210,29209,29566,29975,30314,30672,31021,31025,31023,31828,31827,31986,32394,32391,32392,32395,32390,32397,32589,32699,32816,33245,34328,34346,34342,34335,34339,34332,34329,34343,34350,34337,34336,34345,34334,34341,34857,34845,34843,34848,34852,34844,34859,34890,35181,35177,35182,35179,35322,35705,35704,35653,35706,35707,36112,36116,36271,36494,36492,36702,36699,36701,37190,37188,37189,37305,37951,37947,37942,37929,37949,37948,37936,37945,37930,37943,37932,37952,37937,38373,38372,38371,38709,38714,38847,38881,39012,39113,39110,39104,39256,39254,39481,39485,39494,39492,39490,39489,39482,39487,39629,39701,39703,39704,39702,39738,39762,39979,39965,39964,39980,39971,39976,39977,39972,39969,40375,40374,40380,40385,40391,40394,40399,40382,40389,40387,40379,40373,40398,40377,40378,40364,40392,40369,40365,40396,40371,40397,40370,40570,40604,40683,40686,40685,40731,40728,40730,40753,40782,40805,40804,40850,20153,22214,22213,22219,22897,23371,23372,24021,24017,24306,25889,25888,25894,25890,27403,27400,27401,27661,28757,28758,28759,28754,29214,29215,29353,29567,29912,29909,29913,29911,30317,30381,31029,31156,31344,31345,31831,31836,31833,31835,31834,31988,31985,32401,32591,32647,33246,33387,34356,34357,34355,34348,34354,34358,34860,34856,34854,34858,34853,35185,35263,35262,35323,35710,35716,35714,35718,35717,35711,36117,36501,36500,36506,36498,36496,36502,36503,36704,36706,37191,37964,37968,37962,37963,37967,37959,37957,37960,37961,37958,38719,38883,39018,39017,39115,39252,39259,39502,39507,39508,39500,39503,39496,39498,39497,39506,39504,39632,39705,39723,39739,39766,39765,40006,40008,39999,40004,39993,39987,40001,39996,39991,39988,39986,39997,39990,40411,40402,40414,40410,40395,40400,40412,40401,40415,40425,40409,40408,40406,40437,40405,40413,40630,40688,40757,40755,40754,40770,40811,40853,40866,20797,21145,22760,22759,22898,23373,24024,34863,24399,25089,25091,25092,25897,25893,26006,26347,27409,27410,27407,27594,28763,28762,29218,29570,29569,29571,30320,30676,31847,31846,32405,33388,34362,34368,34361,34364,34353,34363,34366,34864,34866,34862,34867,35190,35188,35187,35326,35724,35726,35723,35720,35909,36121,36504,36708,36707,37308,37986,37973,37981,37975,37982,38852,38853,38912,39510,39513,39710,39711,39712,40018,40024,40016,40010,40013,40011,40021,40025,40012,40014,40443,40439,40431,40419,40427,40440,40420,40438,40417,40430,40422,40434,40432,40418,40428,40436,40435,40424,40429,40642,40656,40690,40691,40710,40732,40760,40759,40758,40771,40783,40817,40816,40814,40815,22227,22221,23374,23661,25901,26349,26350,27411,28767,28769,28765,28768,29219,29915,29925,30677,31032,31159,31158,31850,32407,32649,33389,34371,34872,34871,34869,34891,35732,35733,36510,36511,36512,36509,37310,37309,37314,37995,37992,37993,38629,38726,38723,38727,38855,38885,39518,39637,39769,40035,40039,40038,40034,40030,40032,40450,40446,40455,40451,40454,40453,40448,40449,40457,40447,40445,40452,40608,40734,40774,40820,40821,40822,22228,25902,26040,27416,27417,27415,27418,28770,29222,29354,30680,30681,31033,31849,31851,31990,32410,32408,32411,32409,33248,33249,34374,34375,34376,35193,35194,35196,35195,35327,35736,35737,36517,36516,36515,37998,37997,37999,38001,38003,38729,39026,39263,40040,40046,40045,40459,40461,40464,40463,40466,40465,40609,40693,40713,40775,40824,40827,40826,40825,22302,28774,31855,34876,36274,36518,37315,38004,38008,38006,38005,39520,40052,40051,40049,40053,40468,40467,40694,40714,40868,28776,28773,31991,34410,34878,34877,34879,35742,35996,36521,36553,38731,39027,39028,39116,39265,39339,39524,39526,39527,39716,40469,40471,40776,25095,27422,29223,34380,36520,38018,38016,38017,39529,39528,39726,40473,29225,34379,35743,38019,40057,40631,30325,39531,40058,40477,28777,28778,40612,40830,40777,40856,30849,37561,35023,22715,24658,31911,23290,9556,9574,9559,9568,9580,9571,9562,9577,9565,9554,9572,9557,9566,9578,9569,9560,9575,9563,9555,9573,9558,9567,9579,9570,9561,9576,9564,9553,9552,9581,9582,9584,9583,65517,132423,37595,132575,147397,34124,17077,29679,20917,13897,149826,166372,37700,137691,33518,146632,30780,26436,25311,149811,166314,131744,158643,135941,20395,140525,20488,159017,162436,144896,150193,140563,20521,131966,24484,131968,131911,28379,132127,20605,20737,13434,20750,39020,14147,33814,149924,132231,20832,144308,20842,134143,139516,131813,140592,132494,143923,137603,23426,34685,132531,146585,20914,20920,40244,20937,20943,20945,15580,20947,150182,20915,20962,21314,20973,33741,26942,145197,24443,21003,21030,21052,21173,21079,21140,21177,21189,31765,34114,21216,34317,158483,21253,166622,21833,28377,147328,133460,147436,21299,21316,134114,27851,136998,26651,29653,24650,16042,14540,136936,29149,17570,21357,21364,165547,21374,21375,136598,136723,30694,21395,166555,21408,21419,21422,29607,153458,16217,29596,21441,21445,27721,20041,22526,21465,15019,134031,21472,147435,142755,21494,134263,21523,28793,21803,26199,27995,21613,158547,134516,21853,21647,21668,18342,136973,134877,15796,134477,166332,140952,21831,19693,21551,29719,21894,21929,22021,137431,147514,17746,148533,26291,135348,22071,26317,144010,26276,26285,22093,22095,30961,22257,38791,21502,22272,22255,22253,166758,13859,135759,22342,147877,27758,28811,22338,14001,158846,22502,136214,22531,136276,148323,22566,150517,22620,22698,13665,22752,22748,135740,22779,23551,22339,172368,148088,37843,13729,22815,26790,14019,28249,136766,23076,21843,136850,34053,22985,134478,158849,159018,137180,23001,137211,137138,159142,28017,137256,136917,23033,159301,23211,23139,14054,149929,23159,14088,23190,29797,23251,159649,140628,15749,137489,14130,136888,24195,21200,23414,25992,23420,162318,16388,18525,131588,23509,24928,137780,154060,132517,23539,23453,19728,23557,138052,23571,29646,23572,138405,158504,23625,18653,23685,23785,23791,23947,138745,138807,23824,23832,23878,138916,23738,24023,33532,14381,149761,139337,139635,33415,14390,15298,24110,27274,24181,24186,148668,134355,21414,20151,24272,21416,137073,24073,24308,164994,24313,24315,14496,24316,26686,37915,24333,131521,194708,15070,18606,135994,24378,157832,140240,24408,140401,24419,38845,159342,24434,37696,166454,24487,23990,15711,152144,139114,159992,140904,37334,131742,166441,24625,26245,137335,14691,15815,13881,22416,141236,31089,15936,24734,24740,24755,149890,149903,162387,29860,20705,23200,24932,33828,24898,194726,159442,24961,20980,132694,24967,23466,147383,141407,25043,166813,170333,25040,14642,141696,141505,24611,24924,25886,25483,131352,25285,137072,25301,142861,25452,149983,14871,25656,25592,136078,137212,25744,28554,142902,38932,147596,153373,25825,25829,38011,14950,25658,14935,25933,28438,150056,150051,25989,25965,25951,143486,26037,149824,19255,26065,16600,137257,26080,26083,24543,144384,26136,143863,143864,26180,143780,143781,26187,134773,26215,152038,26227,26228,138813,143921,165364,143816,152339,30661,141559,39332,26370,148380,150049,15147,27130,145346,26462,26471,26466,147917,168173,26583,17641,26658,28240,37436,26625,144358,159136,26717,144495,27105,27147,166623,26995,26819,144845,26881,26880,15666,14849,144956,15232,26540,26977,166474,17148,26934,27032,15265,132041,33635,20624,27129,144985,139562,27205,145155,27293,15347,26545,27336,168348,15373,27421,133411,24798,27445,27508,141261,28341,146139,132021,137560,14144,21537,146266,27617,147196,27612,27703,140427,149745,158545,27738,33318,27769,146876,17605,146877,147876,149772,149760,146633,14053,15595,134450,39811,143865,140433,32655,26679,159013,159137,159211,28054,27996,28284,28420,149887,147589,159346,34099,159604,20935,27804,28189,33838,166689,28207,146991,29779,147330,31180,28239,23185,143435,28664,14093,28573,146992,28410,136343,147517,17749,37872,28484,28508,15694,28532,168304,15675,28575,147780,28627,147601,147797,147513,147440,147380,147775,20959,147798,147799,147776,156125,28747,28798,28839,28801,28876,28885,28886,28895,16644,15848,29108,29078,148087,28971,28997,23176,29002,29038,23708,148325,29007,37730,148161,28972,148570,150055,150050,29114,166888,28861,29198,37954,29205,22801,37955,29220,37697,153093,29230,29248,149876,26813,29269,29271,15957,143428,26637,28477,29314,29482,29483,149539,165931,18669,165892,29480,29486,29647,29610,134202,158254,29641,29769,147938,136935,150052,26147,14021,149943,149901,150011,29687,29717,26883,150054,29753,132547,16087,29788,141485,29792,167602,29767,29668,29814,33721,29804,14128,29812,37873,27180,29826,18771,150156,147807,150137,166799,23366,166915,137374,29896,137608,29966,29929,29982,167641,137803,23511,167596,37765,30029,30026,30055,30062,151426,16132,150803,30094,29789,30110,30132,30210,30252,30289,30287,30319,30326,156661,30352,33263,14328,157969,157966,30369,30373,30391,30412,159647,33890,151709,151933,138780,30494,30502,30528,25775,152096,30552,144044,30639,166244,166248,136897,30708,30729,136054,150034,26826,30895,30919,30931,38565,31022,153056,30935,31028,30897,161292,36792,34948,166699,155779,140828,31110,35072,26882,31104,153687,31133,162617,31036,31145,28202,160038,16040,31174,168205,31188],"euc-kr":[44034,44035,44037,44038,44043,44044,44045,44046,44047,44056,44062,44063,44065,44066,44067,44069,44070,44071,44072,44073,44074,44075,44078,44082,44083,44084,null,null,null,null,null,null,44085,44086,44087,44090,44091,44093,44094,44095,44097,44098,44099,44100,44101,44102,44103,44104,44105,44106,44108,44110,44111,44112,44113,44114,44115,44117,null,null,null,null,null,null,44118,44119,44121,44122,44123,44125,44126,44127,44128,44129,44130,44131,44132,44133,44134,44135,44136,44137,44138,44139,44140,44141,44142,44143,44146,44147,44149,44150,44153,44155,44156,44157,44158,44159,44162,44167,44168,44173,44174,44175,44177,44178,44179,44181,44182,44183,44184,44185,44186,44187,44190,44194,44195,44196,44197,44198,44199,44203,44205,44206,44209,44210,44211,44212,44213,44214,44215,44218,44222,44223,44224,44226,44227,44229,44230,44231,44233,44234,44235,44237,44238,44239,44240,44241,44242,44243,44244,44246,44248,44249,44250,44251,44252,44253,44254,44255,44258,44259,44261,44262,44265,44267,44269,44270,44274,44276,44279,44280,44281,44282,44283,44286,44287,44289,44290,44291,44293,44295,44296,44297,44298,44299,44302,44304,44306,44307,44308,44309,44310,44311,44313,44314,44315,44317,44318,44319,44321,44322,44323,44324,44325,44326,44327,44328,44330,44331,44334,44335,44336,44337,44338,44339,null,null,null,null,null,null,44342,44343,44345,44346,44347,44349,44350,44351,44352,44353,44354,44355,44358,44360,44362,44363,44364,44365,44366,44367,44369,44370,44371,44373,44374,44375,null,null,null,null,null,null,44377,44378,44379,44380,44381,44382,44383,44384,44386,44388,44389,44390,44391,44392,44393,44394,44395,44398,44399,44401,44402,44407,44408,44409,44410,44414,44416,44419,44420,44421,44422,44423,44426,44427,44429,44430,44431,44433,44434,44435,44436,44437,44438,44439,44440,44441,44442,44443,44446,44447,44448,44449,44450,44451,44453,44454,44455,44456,44457,44458,44459,44460,44461,44462,44463,44464,44465,44466,44467,44468,44469,44470,44472,44473,44474,44475,44476,44477,44478,44479,44482,44483,44485,44486,44487,44489,44490,44491,44492,44493,44494,44495,44498,44500,44501,44502,44503,44504,44505,44506,44507,44509,44510,44511,44513,44514,44515,44517,44518,44519,44520,44521,44522,44523,44524,44525,44526,44527,44528,44529,44530,44531,44532,44533,44534,44535,44538,44539,44541,44542,44546,44547,44548,44549,44550,44551,44554,44556,44558,44559,44560,44561,44562,44563,44565,44566,44567,44568,44569,44570,44571,44572,null,null,null,null,null,null,44573,44574,44575,44576,44577,44578,44579,44580,44581,44582,44583,44584,44585,44586,44587,44588,44589,44590,44591,44594,44595,44597,44598,44601,44603,44604,null,null,null,null,null,null,44605,44606,44607,44610,44612,44615,44616,44617,44619,44623,44625,44626,44627,44629,44631,44632,44633,44634,44635,44638,44642,44643,44644,44646,44647,44650,44651,44653,44654,44655,44657,44658,44659,44660,44661,44662,44663,44666,44670,44671,44672,44673,44674,44675,44678,44679,44680,44681,44682,44683,44685,44686,44687,44688,44689,44690,44691,44692,44693,44694,44695,44696,44697,44698,44699,44700,44701,44702,44703,44704,44705,44706,44707,44708,44709,44710,44711,44712,44713,44714,44715,44716,44717,44718,44719,44720,44721,44722,44723,44724,44725,44726,44727,44728,44729,44730,44731,44735,44737,44738,44739,44741,44742,44743,44744,44745,44746,44747,44750,44754,44755,44756,44757,44758,44759,44762,44763,44765,44766,44767,44768,44769,44770,44771,44772,44773,44774,44775,44777,44778,44780,44782,44783,44784,44785,44786,44787,44789,44790,44791,44793,44794,44795,44797,44798,44799,44800,44801,44802,44803,44804,44805,null,null,null,null,null,null,44806,44809,44810,44811,44812,44814,44815,44817,44818,44819,44820,44821,44822,44823,44824,44825,44826,44827,44828,44829,44830,44831,44832,44833,44834,44835,null,null,null,null,null,null,44836,44837,44838,44839,44840,44841,44842,44843,44846,44847,44849,44851,44853,44854,44855,44856,44857,44858,44859,44862,44864,44868,44869,44870,44871,44874,44875,44876,44877,44878,44879,44881,44882,44883,44884,44885,44886,44887,44888,44889,44890,44891,44894,44895,44896,44897,44898,44899,44902,44903,44904,44905,44906,44907,44908,44909,44910,44911,44912,44913,44914,44915,44916,44917,44918,44919,44920,44922,44923,44924,44925,44926,44927,44929,44930,44931,44933,44934,44935,44937,44938,44939,44940,44941,44942,44943,44946,44947,44948,44950,44951,44952,44953,44954,44955,44957,44958,44959,44960,44961,44962,44963,44964,44965,44966,44967,44968,44969,44970,44971,44972,44973,44974,44975,44976,44977,44978,44979,44980,44981,44982,44983,44986,44987,44989,44990,44991,44993,44994,44995,44996,44997,44998,45002,45004,45007,45008,45009,45010,45011,45013,45014,45015,45016,45017,45018,45019,45021,45022,45023,45024,45025,null,null,null,null,null,null,45026,45027,45028,45029,45030,45031,45034,45035,45036,45037,45038,45039,45042,45043,45045,45046,45047,45049,45050,45051,45052,45053,45054,45055,45058,45059,null,null,null,null,null,null,45061,45062,45063,45064,45065,45066,45067,45069,45070,45071,45073,45074,45075,45077,45078,45079,45080,45081,45082,45083,45086,45087,45088,45089,45090,45091,45092,45093,45094,45095,45097,45098,45099,45100,45101,45102,45103,45104,45105,45106,45107,45108,45109,45110,45111,45112,45113,45114,45115,45116,45117,45118,45119,45120,45121,45122,45123,45126,45127,45129,45131,45133,45135,45136,45137,45138,45142,45144,45146,45147,45148,45150,45151,45152,45153,45154,45155,45156,45157,45158,45159,45160,45161,45162,45163,45164,45165,45166,45167,45168,45169,45170,45171,45172,45173,45174,45175,45176,45177,45178,45179,45182,45183,45185,45186,45187,45189,45190,45191,45192,45193,45194,45195,45198,45200,45202,45203,45204,45205,45206,45207,45211,45213,45214,45219,45220,45221,45222,45223,45226,45232,45234,45238,45239,45241,45242,45243,45245,45246,45247,45248,45249,45250,45251,45254,45258,45259,45260,45261,45262,45263,45266,null,null,null,null,null,null,45267,45269,45270,45271,45273,45274,45275,45276,45277,45278,45279,45281,45282,45283,45284,45286,45287,45288,45289,45290,45291,45292,45293,45294,45295,45296,null,null,null,null,null,null,45297,45298,45299,45300,45301,45302,45303,45304,45305,45306,45307,45308,45309,45310,45311,45312,45313,45314,45315,45316,45317,45318,45319,45322,45325,45326,45327,45329,45332,45333,45334,45335,45338,45342,45343,45344,45345,45346,45350,45351,45353,45354,45355,45357,45358,45359,45360,45361,45362,45363,45366,45370,45371,45372,45373,45374,45375,45378,45379,45381,45382,45383,45385,45386,45387,45388,45389,45390,45391,45394,45395,45398,45399,45401,45402,45403,45405,45406,45407,45409,45410,45411,45412,45413,45414,45415,45416,45417,45418,45419,45420,45421,45422,45423,45424,45425,45426,45427,45428,45429,45430,45431,45434,45435,45437,45438,45439,45441,45443,45444,45445,45446,45447,45450,45452,45454,45455,45456,45457,45461,45462,45463,45465,45466,45467,45469,45470,45471,45472,45473,45474,45475,45476,45477,45478,45479,45481,45482,45483,45484,45485,45486,45487,45488,45489,45490,45491,45492,45493,45494,45495,45496,null,null,null,null,null,null,45497,45498,45499,45500,45501,45502,45503,45504,45505,45506,45507,45508,45509,45510,45511,45512,45513,45514,45515,45517,45518,45519,45521,45522,45523,45525,null,null,null,null,null,null,45526,45527,45528,45529,45530,45531,45534,45536,45537,45538,45539,45540,45541,45542,45543,45546,45547,45549,45550,45551,45553,45554,45555,45556,45557,45558,45559,45560,45562,45564,45566,45567,45568,45569,45570,45571,45574,45575,45577,45578,45581,45582,45583,45584,45585,45586,45587,45590,45592,45594,45595,45596,45597,45598,45599,45601,45602,45603,45604,45605,45606,45607,45608,45609,45610,45611,45612,45613,45614,45615,45616,45617,45618,45619,45621,45622,45623,45624,45625,45626,45627,45629,45630,45631,45632,45633,45634,45635,45636,45637,45638,45639,45640,45641,45642,45643,45644,45645,45646,45647,45648,45649,45650,45651,45652,45653,45654,45655,45657,45658,45659,45661,45662,45663,45665,45666,45667,45668,45669,45670,45671,45674,45675,45676,45677,45678,45679,45680,45681,45682,45683,45686,45687,45688,45689,45690,45691,45693,45694,45695,45696,45697,45698,45699,45702,45703,45704,45706,45707,45708,45709,45710,null,null,null,null,null,null,45711,45714,45715,45717,45718,45719,45723,45724,45725,45726,45727,45730,45732,45735,45736,45737,45739,45741,45742,45743,45745,45746,45747,45749,45750,45751,null,null,null,null,null,null,45752,45753,45754,45755,45756,45757,45758,45759,45760,45761,45762,45763,45764,45765,45766,45767,45770,45771,45773,45774,45775,45777,45779,45780,45781,45782,45783,45786,45788,45790,45791,45792,45793,45795,45799,45801,45802,45808,45809,45810,45814,45820,45821,45822,45826,45827,45829,45830,45831,45833,45834,45835,45836,45837,45838,45839,45842,45846,45847,45848,45849,45850,45851,45853,45854,45855,45856,45857,45858,45859,45860,45861,45862,45863,45864,45865,45866,45867,45868,45869,45870,45871,45872,45873,45874,45875,45876,45877,45878,45879,45880,45881,45882,45883,45884,45885,45886,45887,45888,45889,45890,45891,45892,45893,45894,45895,45896,45897,45898,45899,45900,45901,45902,45903,45904,45905,45906,45907,45911,45913,45914,45917,45920,45921,45922,45923,45926,45928,45930,45932,45933,45935,45938,45939,45941,45942,45943,45945,45946,45947,45948,45949,45950,45951,45954,45958,45959,45960,45961,45962,45963,45965,null,null,null,null,null,null,45966,45967,45969,45970,45971,45973,45974,45975,45976,45977,45978,45979,45980,45981,45982,45983,45986,45987,45988,45989,45990,45991,45993,45994,45995,45997,null,null,null,null,null,null,45998,45999,46e3,46001,46002,46003,46004,46005,46006,46007,46008,46009,46010,46011,46012,46013,46014,46015,46016,46017,46018,46019,46022,46023,46025,46026,46029,46031,46033,46034,46035,46038,46040,46042,46044,46046,46047,46049,46050,46051,46053,46054,46055,46057,46058,46059,46060,46061,46062,46063,46064,46065,46066,46067,46068,46069,46070,46071,46072,46073,46074,46075,46077,46078,46079,46080,46081,46082,46083,46084,46085,46086,46087,46088,46089,46090,46091,46092,46093,46094,46095,46097,46098,46099,46100,46101,46102,46103,46105,46106,46107,46109,46110,46111,46113,46114,46115,46116,46117,46118,46119,46122,46124,46125,46126,46127,46128,46129,46130,46131,46133,46134,46135,46136,46137,46138,46139,46140,46141,46142,46143,46144,46145,46146,46147,46148,46149,46150,46151,46152,46153,46154,46155,46156,46157,46158,46159,46162,46163,46165,46166,46167,46169,46170,46171,46172,46173,46174,46175,46178,46180,46182,null,null,null,null,null,null,46183,46184,46185,46186,46187,46189,46190,46191,46192,46193,46194,46195,46196,46197,46198,46199,46200,46201,46202,46203,46204,46205,46206,46207,46209,46210,null,null,null,null,null,null,46211,46212,46213,46214,46215,46217,46218,46219,46220,46221,46222,46223,46224,46225,46226,46227,46228,46229,46230,46231,46232,46233,46234,46235,46236,46238,46239,46240,46241,46242,46243,46245,46246,46247,46249,46250,46251,46253,46254,46255,46256,46257,46258,46259,46260,46262,46264,46266,46267,46268,46269,46270,46271,46273,46274,46275,46277,46278,46279,46281,46282,46283,46284,46285,46286,46287,46289,46290,46291,46292,46294,46295,46296,46297,46298,46299,46302,46303,46305,46306,46309,46311,46312,46313,46314,46315,46318,46320,46322,46323,46324,46325,46326,46327,46329,46330,46331,46332,46333,46334,46335,46336,46337,46338,46339,46340,46341,46342,46343,46344,46345,46346,46347,46348,46349,46350,46351,46352,46353,46354,46355,46358,46359,46361,46362,46365,46366,46367,46368,46369,46370,46371,46374,46379,46380,46381,46382,46383,46386,46387,46389,46390,46391,46393,46394,46395,46396,46397,46398,46399,46402,46406,null,null,null,null,null,null,46407,46408,46409,46410,46414,46415,46417,46418,46419,46421,46422,46423,46424,46425,46426,46427,46430,46434,46435,46436,46437,46438,46439,46440,46441,46442,null,null,null,null,null,null,46443,46444,46445,46446,46447,46448,46449,46450,46451,46452,46453,46454,46455,46456,46457,46458,46459,46460,46461,46462,46463,46464,46465,46466,46467,46468,46469,46470,46471,46472,46473,46474,46475,46476,46477,46478,46479,46480,46481,46482,46483,46484,46485,46486,46487,46488,46489,46490,46491,46492,46493,46494,46495,46498,46499,46501,46502,46503,46505,46508,46509,46510,46511,46514,46518,46519,46520,46521,46522,46526,46527,46529,46530,46531,46533,46534,46535,46536,46537,46538,46539,46542,46546,46547,46548,46549,46550,46551,46553,46554,46555,46556,46557,46558,46559,46560,46561,46562,46563,46564,46565,46566,46567,46568,46569,46570,46571,46573,46574,46575,46576,46577,46578,46579,46580,46581,46582,46583,46584,46585,46586,46587,46588,46589,46590,46591,46592,46593,46594,46595,46596,46597,46598,46599,46600,46601,46602,46603,46604,46605,46606,46607,46610,46611,46613,46614,46615,46617,46618,46619,46620,46621,null,null,null,null,null,null,46622,46623,46624,46625,46626,46627,46628,46630,46631,46632,46633,46634,46635,46637,46638,46639,46640,46641,46642,46643,46645,46646,46647,46648,46649,46650,null,null,null,null,null,null,46651,46652,46653,46654,46655,46656,46657,46658,46659,46660,46661,46662,46663,46665,46666,46667,46668,46669,46670,46671,46672,46673,46674,46675,46676,46677,46678,46679,46680,46681,46682,46683,46684,46685,46686,46687,46688,46689,46690,46691,46693,46694,46695,46697,46698,46699,46700,46701,46702,46703,46704,46705,46706,46707,46708,46709,46710,46711,46712,46713,46714,46715,46716,46717,46718,46719,46720,46721,46722,46723,46724,46725,46726,46727,46728,46729,46730,46731,46732,46733,46734,46735,46736,46737,46738,46739,46740,46741,46742,46743,46744,46745,46746,46747,46750,46751,46753,46754,46755,46757,46758,46759,46760,46761,46762,46765,46766,46767,46768,46770,46771,46772,46773,46774,46775,46776,46777,46778,46779,46780,46781,46782,46783,46784,46785,46786,46787,46788,46789,46790,46791,46792,46793,46794,46795,46796,46797,46798,46799,46800,46801,46802,46803,46805,46806,46807,46808,46809,46810,46811,46812,46813,null,null,null,null,null,null,46814,46815,46816,46817,46818,46819,46820,46821,46822,46823,46824,46825,46826,46827,46828,46829,46830,46831,46833,46834,46835,46837,46838,46839,46841,46842,null,null,null,null,null,null,46843,46844,46845,46846,46847,46850,46851,46852,46854,46855,46856,46857,46858,46859,46860,46861,46862,46863,46864,46865,46866,46867,46868,46869,46870,46871,46872,46873,46874,46875,46876,46877,46878,46879,46880,46881,46882,46883,46884,46885,46886,46887,46890,46891,46893,46894,46897,46898,46899,46900,46901,46902,46903,46906,46908,46909,46910,46911,46912,46913,46914,46915,46917,46918,46919,46921,46922,46923,46925,46926,46927,46928,46929,46930,46931,46934,46935,46936,46937,46938,46939,46940,46941,46942,46943,46945,46946,46947,46949,46950,46951,46953,46954,46955,46956,46957,46958,46959,46962,46964,46966,46967,46968,46969,46970,46971,46974,46975,46977,46978,46979,46981,46982,46983,46984,46985,46986,46987,46990,46995,46996,46997,47002,47003,47005,47006,47007,47009,47010,47011,47012,47013,47014,47015,47018,47022,47023,47024,47025,47026,47027,47030,47031,47033,47034,47035,47036,47037,47038,47039,47040,47041,null,null,null,null,null,null,47042,47043,47044,47045,47046,47048,47050,47051,47052,47053,47054,47055,47056,47057,47058,47059,47060,47061,47062,47063,47064,47065,47066,47067,47068,47069,null,null,null,null,null,null,47070,47071,47072,47073,47074,47075,47076,47077,47078,47079,47080,47081,47082,47083,47086,47087,47089,47090,47091,47093,47094,47095,47096,47097,47098,47099,47102,47106,47107,47108,47109,47110,47114,47115,47117,47118,47119,47121,47122,47123,47124,47125,47126,47127,47130,47132,47134,47135,47136,47137,47138,47139,47142,47143,47145,47146,47147,47149,47150,47151,47152,47153,47154,47155,47158,47162,47163,47164,47165,47166,47167,47169,47170,47171,47173,47174,47175,47176,47177,47178,47179,47180,47181,47182,47183,47184,47186,47188,47189,47190,47191,47192,47193,47194,47195,47198,47199,47201,47202,47203,47205,47206,47207,47208,47209,47210,47211,47214,47216,47218,47219,47220,47221,47222,47223,47225,47226,47227,47229,47230,47231,47232,47233,47234,47235,47236,47237,47238,47239,47240,47241,47242,47243,47244,47246,47247,47248,47249,47250,47251,47252,47253,47254,47255,47256,47257,47258,47259,47260,47261,47262,47263,null,null,null,null,null,null,47264,47265,47266,47267,47268,47269,47270,47271,47273,47274,47275,47276,47277,47278,47279,47281,47282,47283,47285,47286,47287,47289,47290,47291,47292,47293,null,null,null,null,null,null,47294,47295,47298,47300,47302,47303,47304,47305,47306,47307,47309,47310,47311,47313,47314,47315,47317,47318,47319,47320,47321,47322,47323,47324,47326,47328,47330,47331,47332,47333,47334,47335,47338,47339,47341,47342,47343,47345,47346,47347,47348,47349,47350,47351,47354,47356,47358,47359,47360,47361,47362,47363,47365,47366,47367,47368,47369,47370,47371,47372,47373,47374,47375,47376,47377,47378,47379,47380,47381,47382,47383,47385,47386,47387,47388,47389,47390,47391,47393,47394,47395,47396,47397,47398,47399,47400,47401,47402,47403,47404,47405,47406,47407,47408,47409,47410,47411,47412,47413,47414,47415,47416,47417,47418,47419,47422,47423,47425,47426,47427,47429,47430,47431,47432,47433,47434,47435,47437,47438,47440,47442,47443,47444,47445,47446,47447,47450,47451,47453,47454,47455,47457,47458,47459,47460,47461,47462,47463,47466,47468,47470,47471,47472,47473,47474,47475,47478,47479,47481,47482,47483,47485,null,null,null,null,null,null,47486,47487,47488,47489,47490,47491,47494,47496,47499,47500,47503,47504,47505,47506,47507,47508,47509,47510,47511,47512,47513,47514,47515,47516,47517,47518,null,null,null,null,null,null,47519,47520,47521,47522,47523,47524,47525,47526,47527,47528,47529,47530,47531,47534,47535,47537,47538,47539,47541,47542,47543,47544,47545,47546,47547,47550,47552,47554,47555,47556,47557,47558,47559,47562,47563,47565,47571,47572,47573,47574,47575,47578,47580,47583,47584,47586,47590,47591,47593,47594,47595,47597,47598,47599,47600,47601,47602,47603,47606,47611,47612,47613,47614,47615,47618,47619,47620,47621,47622,47623,47625,47626,47627,47628,47629,47630,47631,47632,47633,47634,47635,47636,47638,47639,47640,47641,47642,47643,47644,47645,47646,47647,47648,47649,47650,47651,47652,47653,47654,47655,47656,47657,47658,47659,47660,47661,47662,47663,47664,47665,47666,47667,47668,47669,47670,47671,47674,47675,47677,47678,47679,47681,47683,47684,47685,47686,47687,47690,47692,47695,47696,47697,47698,47702,47703,47705,47706,47707,47709,47710,47711,47712,47713,47714,47715,47718,47722,47723,47724,47725,47726,47727,null,null,null,null,null,null,47730,47731,47733,47734,47735,47737,47738,47739,47740,47741,47742,47743,47744,47745,47746,47750,47752,47753,47754,47755,47757,47758,47759,47760,47761,47762,null,null,null,null,null,null,47763,47764,47765,47766,47767,47768,47769,47770,47771,47772,47773,47774,47775,47776,47777,47778,47779,47780,47781,47782,47783,47786,47789,47790,47791,47793,47795,47796,47797,47798,47799,47802,47804,47806,47807,47808,47809,47810,47811,47813,47814,47815,47817,47818,47819,47820,47821,47822,47823,47824,47825,47826,47827,47828,47829,47830,47831,47834,47835,47836,47837,47838,47839,47840,47841,47842,47843,47844,47845,47846,47847,47848,47849,47850,47851,47852,47853,47854,47855,47856,47857,47858,47859,47860,47861,47862,47863,47864,47865,47866,47867,47869,47870,47871,47873,47874,47875,47877,47878,47879,47880,47881,47882,47883,47884,47886,47888,47890,47891,47892,47893,47894,47895,47897,47898,47899,47901,47902,47903,47905,47906,47907,47908,47909,47910,47911,47912,47914,47916,47917,47918,47919,47920,47921,47922,47923,47927,47929,47930,47935,47936,47937,47938,47939,47942,47944,47946,47947,47948,47950,47953,47954,null,null,null,null,null,null,47955,47957,47958,47959,47961,47962,47963,47964,47965,47966,47967,47968,47970,47972,47973,47974,47975,47976,47977,47978,47979,47981,47982,47983,47984,47985,null,null,null,null,null,null,47986,47987,47988,47989,47990,47991,47992,47993,47994,47995,47996,47997,47998,47999,48e3,48001,48002,48003,48004,48005,48006,48007,48009,48010,48011,48013,48014,48015,48017,48018,48019,48020,48021,48022,48023,48024,48025,48026,48027,48028,48029,48030,48031,48032,48033,48034,48035,48037,48038,48039,48041,48042,48043,48045,48046,48047,48048,48049,48050,48051,48053,48054,48056,48057,48058,48059,48060,48061,48062,48063,48065,48066,48067,48069,48070,48071,48073,48074,48075,48076,48077,48078,48079,48081,48082,48084,48085,48086,48087,48088,48089,48090,48091,48092,48093,48094,48095,48096,48097,48098,48099,48100,48101,48102,48103,48104,48105,48106,48107,48108,48109,48110,48111,48112,48113,48114,48115,48116,48117,48118,48119,48122,48123,48125,48126,48129,48131,48132,48133,48134,48135,48138,48142,48144,48146,48147,48153,48154,48160,48161,48162,48163,48166,48168,48170,48171,48172,48174,48175,48178,48179,48181,null,null,null,null,null,null,48182,48183,48185,48186,48187,48188,48189,48190,48191,48194,48198,48199,48200,48202,48203,48206,48207,48209,48210,48211,48212,48213,48214,48215,48216,48217,null,null,null,null,null,null,48218,48219,48220,48222,48223,48224,48225,48226,48227,48228,48229,48230,48231,48232,48233,48234,48235,48236,48237,48238,48239,48240,48241,48242,48243,48244,48245,48246,48247,48248,48249,48250,48251,48252,48253,48254,48255,48256,48257,48258,48259,48262,48263,48265,48266,48269,48271,48272,48273,48274,48275,48278,48280,48283,48284,48285,48286,48287,48290,48291,48293,48294,48297,48298,48299,48300,48301,48302,48303,48306,48310,48311,48312,48313,48314,48315,48318,48319,48321,48322,48323,48325,48326,48327,48328,48329,48330,48331,48332,48334,48338,48339,48340,48342,48343,48345,48346,48347,48349,48350,48351,48352,48353,48354,48355,48356,48357,48358,48359,48360,48361,48362,48363,48364,48365,48366,48367,48368,48369,48370,48371,48375,48377,48378,48379,48381,48382,48383,48384,48385,48386,48387,48390,48392,48394,48395,48396,48397,48398,48399,48401,48402,48403,48405,48406,48407,48408,48409,48410,48411,48412,48413,null,null,null,null,null,null,48414,48415,48416,48417,48418,48419,48421,48422,48423,48424,48425,48426,48427,48429,48430,48431,48432,48433,48434,48435,48436,48437,48438,48439,48440,48441,null,null,null,null,null,null,48442,48443,48444,48445,48446,48447,48449,48450,48451,48452,48453,48454,48455,48458,48459,48461,48462,48463,48465,48466,48467,48468,48469,48470,48471,48474,48475,48476,48477,48478,48479,48480,48481,48482,48483,48485,48486,48487,48489,48490,48491,48492,48493,48494,48495,48496,48497,48498,48499,48500,48501,48502,48503,48504,48505,48506,48507,48508,48509,48510,48511,48514,48515,48517,48518,48523,48524,48525,48526,48527,48530,48532,48534,48535,48536,48539,48541,48542,48543,48544,48545,48546,48547,48549,48550,48551,48552,48553,48554,48555,48556,48557,48558,48559,48561,48562,48563,48564,48565,48566,48567,48569,48570,48571,48572,48573,48574,48575,48576,48577,48578,48579,48580,48581,48582,48583,48584,48585,48586,48587,48588,48589,48590,48591,48592,48593,48594,48595,48598,48599,48601,48602,48603,48605,48606,48607,48608,48609,48610,48611,48612,48613,48614,48615,48616,48618,48619,48620,48621,48622,48623,48625,null,null,null,null,null,null,48626,48627,48629,48630,48631,48633,48634,48635,48636,48637,48638,48639,48641,48642,48644,48646,48647,48648,48649,48650,48651,48654,48655,48657,48658,48659,null,null,null,null,null,null,48661,48662,48663,48664,48665,48666,48667,48670,48672,48673,48674,48675,48676,48677,48678,48679,48680,48681,48682,48683,48684,48685,48686,48687,48688,48689,48690,48691,48692,48693,48694,48695,48696,48697,48698,48699,48700,48701,48702,48703,48704,48705,48706,48707,48710,48711,48713,48714,48715,48717,48719,48720,48721,48722,48723,48726,48728,48732,48733,48734,48735,48738,48739,48741,48742,48743,48745,48747,48748,48749,48750,48751,48754,48758,48759,48760,48761,48762,48766,48767,48769,48770,48771,48773,48774,48775,48776,48777,48778,48779,48782,48786,48787,48788,48789,48790,48791,48794,48795,48796,48797,48798,48799,48800,48801,48802,48803,48804,48805,48806,48807,48809,48810,48811,48812,48813,48814,48815,48816,48817,48818,48819,48820,48821,48822,48823,48824,48825,48826,48827,48828,48829,48830,48831,48832,48833,48834,48835,48836,48837,48838,48839,48840,48841,48842,48843,48844,48845,48846,48847,48850,48851,null,null,null,null,null,null,48853,48854,48857,48858,48859,48860,48861,48862,48863,48865,48866,48870,48871,48872,48873,48874,48875,48877,48878,48879,48880,48881,48882,48883,48884,48885,null,null,null,null,null,null,48886,48887,48888,48889,48890,48891,48892,48893,48894,48895,48896,48898,48899,48900,48901,48902,48903,48906,48907,48908,48909,48910,48911,48912,48913,48914,48915,48916,48917,48918,48919,48922,48926,48927,48928,48929,48930,48931,48932,48933,48934,48935,48936,48937,48938,48939,48940,48941,48942,48943,48944,48945,48946,48947,48948,48949,48950,48951,48952,48953,48954,48955,48956,48957,48958,48959,48962,48963,48965,48966,48967,48969,48970,48971,48972,48973,48974,48975,48978,48979,48980,48982,48983,48984,48985,48986,48987,48988,48989,48990,48991,48992,48993,48994,48995,48996,48997,48998,48999,49e3,49001,49002,49003,49004,49005,49006,49007,49008,49009,49010,49011,49012,49013,49014,49015,49016,49017,49018,49019,49020,49021,49022,49023,49024,49025,49026,49027,49028,49029,49030,49031,49032,49033,49034,49035,49036,49037,49038,49039,49040,49041,49042,49043,49045,49046,49047,49048,49049,49050,49051,49052,49053,null,null,null,null,null,null,49054,49055,49056,49057,49058,49059,49060,49061,49062,49063,49064,49065,49066,49067,49068,49069,49070,49071,49073,49074,49075,49076,49077,49078,49079,49080,null,null,null,null,null,null,49081,49082,49083,49084,49085,49086,49087,49088,49089,49090,49091,49092,49094,49095,49096,49097,49098,49099,49102,49103,49105,49106,49107,49109,49110,49111,49112,49113,49114,49115,49117,49118,49120,49122,49123,49124,49125,49126,49127,49128,49129,49130,49131,49132,49133,49134,49135,49136,49137,49138,49139,49140,49141,49142,49143,49144,49145,49146,49147,49148,49149,49150,49151,49152,49153,49154,49155,49156,49157,49158,49159,49160,49161,49162,49163,49164,49165,49166,49167,49168,49169,49170,49171,49172,49173,49174,49175,49176,49177,49178,49179,49180,49181,49182,49183,49184,49185,49186,49187,49188,49189,49190,49191,49192,49193,49194,49195,49196,49197,49198,49199,49200,49201,49202,49203,49204,49205,49206,49207,49208,49209,49210,49211,49213,49214,49215,49216,49217,49218,49219,49220,49221,49222,49223,49224,49225,49226,49227,49228,49229,49230,49231,49232,49234,49235,49236,49237,49238,49239,49241,49242,49243,null,null,null,null,null,null,49245,49246,49247,49249,49250,49251,49252,49253,49254,49255,49258,49259,49260,49261,49262,49263,49264,49265,49266,49267,49268,49269,49270,49271,49272,49273,null,null,null,null,null,null,49274,49275,49276,49277,49278,49279,49280,49281,49282,49283,49284,49285,49286,49287,49288,49289,49290,49291,49292,49293,49294,49295,49298,49299,49301,49302,49303,49305,49306,49307,49308,49309,49310,49311,49314,49316,49318,49319,49320,49321,49322,49323,49326,49329,49330,49335,49336,49337,49338,49339,49342,49346,49347,49348,49350,49351,49354,49355,49357,49358,49359,49361,49362,49363,49364,49365,49366,49367,49370,49374,49375,49376,49377,49378,49379,49382,49383,49385,49386,49387,49389,49390,49391,49392,49393,49394,49395,49398,49400,49402,49403,49404,49405,49406,49407,49409,49410,49411,49413,49414,49415,49417,49418,49419,49420,49421,49422,49423,49425,49426,49427,49428,49430,49431,49432,49433,49434,49435,49441,49442,49445,49448,49449,49450,49451,49454,49458,49459,49460,49461,49463,49466,49467,49469,49470,49471,49473,49474,49475,49476,49477,49478,49479,49482,49486,49487,49488,49489,49490,49491,49494,49495,null,null,null,null,null,null,49497,49498,49499,49501,49502,49503,49504,49505,49506,49507,49510,49514,49515,49516,49517,49518,49519,49521,49522,49523,49525,49526,49527,49529,49530,49531,null,null,null,null,null,null,49532,49533,49534,49535,49536,49537,49538,49539,49540,49542,49543,49544,49545,49546,49547,49551,49553,49554,49555,49557,49559,49560,49561,49562,49563,49566,49568,49570,49571,49572,49574,49575,49578,49579,49581,49582,49583,49585,49586,49587,49588,49589,49590,49591,49592,49593,49594,49595,49596,49598,49599,49600,49601,49602,49603,49605,49606,49607,49609,49610,49611,49613,49614,49615,49616,49617,49618,49619,49621,49622,49625,49626,49627,49628,49629,49630,49631,49633,49634,49635,49637,49638,49639,49641,49642,49643,49644,49645,49646,49647,49650,49652,49653,49654,49655,49656,49657,49658,49659,49662,49663,49665,49666,49667,49669,49670,49671,49672,49673,49674,49675,49678,49680,49682,49683,49684,49685,49686,49687,49690,49691,49693,49694,49697,49698,49699,49700,49701,49702,49703,49706,49708,49710,49712,49715,49717,49718,49719,49720,49721,49722,49723,49724,49725,49726,49727,49728,49729,49730,49731,49732,49733,null,null,null,null,null,null,49734,49735,49737,49738,49739,49740,49741,49742,49743,49746,49747,49749,49750,49751,49753,49754,49755,49756,49757,49758,49759,49761,49762,49763,49764,49766,null,null,null,null,null,null,49767,49768,49769,49770,49771,49774,49775,49777,49778,49779,49781,49782,49783,49784,49785,49786,49787,49790,49792,49794,49795,49796,49797,49798,49799,49802,49803,49804,49805,49806,49807,49809,49810,49811,49812,49813,49814,49815,49817,49818,49820,49822,49823,49824,49825,49826,49827,49830,49831,49833,49834,49835,49838,49839,49840,49841,49842,49843,49846,49848,49850,49851,49852,49853,49854,49855,49856,49857,49858,49859,49860,49861,49862,49863,49864,49865,49866,49867,49868,49869,49870,49871,49872,49873,49874,49875,49876,49877,49878,49879,49880,49881,49882,49883,49886,49887,49889,49890,49893,49894,49895,49896,49897,49898,49902,49904,49906,49907,49908,49909,49911,49914,49917,49918,49919,49921,49922,49923,49924,49925,49926,49927,49930,49931,49934,49935,49936,49937,49938,49942,49943,49945,49946,49947,49949,49950,49951,49952,49953,49954,49955,49958,49959,49962,49963,49964,49965,49966,49967,49968,49969,49970,null,null,null,null,null,null,49971,49972,49973,49974,49975,49976,49977,49978,49979,49980,49981,49982,49983,49984,49985,49986,49987,49988,49990,49991,49992,49993,49994,49995,49996,49997,null,null,null,null,null,null,49998,49999,5e4,50001,50002,50003,50004,50005,50006,50007,50008,50009,50010,50011,50012,50013,50014,50015,50016,50017,50018,50019,50020,50021,50022,50023,50026,50027,50029,50030,50031,50033,50035,50036,50037,50038,50039,50042,50043,50046,50047,50048,50049,50050,50051,50053,50054,50055,50057,50058,50059,50061,50062,50063,50064,50065,50066,50067,50068,50069,50070,50071,50072,50073,50074,50075,50076,50077,50078,50079,50080,50081,50082,50083,50084,50085,50086,50087,50088,50089,50090,50091,50092,50093,50094,50095,50096,50097,50098,50099,50100,50101,50102,50103,50104,50105,50106,50107,50108,50109,50110,50111,50113,50114,50115,50116,50117,50118,50119,50120,50121,50122,50123,50124,50125,50126,50127,50128,50129,50130,50131,50132,50133,50134,50135,50138,50139,50141,50142,50145,50147,50148,50149,50150,50151,50154,50155,50156,50158,50159,50160,50161,50162,50163,50166,50167,50169,50170,50171,50172,50173,50174,null,null,null,null,null,null,50175,50176,50177,50178,50179,50180,50181,50182,50183,50185,50186,50187,50188,50189,50190,50191,50193,50194,50195,50196,50197,50198,50199,50200,50201,50202,null,null,null,null,null,null,50203,50204,50205,50206,50207,50208,50209,50210,50211,50213,50214,50215,50216,50217,50218,50219,50221,50222,50223,50225,50226,50227,50229,50230,50231,50232,50233,50234,50235,50238,50239,50240,50241,50242,50243,50244,50245,50246,50247,50249,50250,50251,50252,50253,50254,50255,50256,50257,50258,50259,50260,50261,50262,50263,50264,50265,50266,50267,50268,50269,50270,50271,50272,50273,50274,50275,50278,50279,50281,50282,50283,50285,50286,50287,50288,50289,50290,50291,50294,50295,50296,50298,50299,50300,50301,50302,50303,50305,50306,50307,50308,50309,50310,50311,50312,50313,50314,50315,50316,50317,50318,50319,50320,50321,50322,50323,50325,50326,50327,50328,50329,50330,50331,50333,50334,50335,50336,50337,50338,50339,50340,50341,50342,50343,50344,50345,50346,50347,50348,50349,50350,50351,50352,50353,50354,50355,50356,50357,50358,50359,50361,50362,50363,50365,50366,50367,50368,50369,50370,50371,50372,50373,null,null,null,null,null,null,50374,50375,50376,50377,50378,50379,50380,50381,50382,50383,50384,50385,50386,50387,50388,50389,50390,50391,50392,50393,50394,50395,50396,50397,50398,50399,null,null,null,null,null,null,50400,50401,50402,50403,50404,50405,50406,50407,50408,50410,50411,50412,50413,50414,50415,50418,50419,50421,50422,50423,50425,50427,50428,50429,50430,50434,50435,50436,50437,50438,50439,50440,50441,50442,50443,50445,50446,50447,50449,50450,50451,50453,50454,50455,50456,50457,50458,50459,50461,50462,50463,50464,50465,50466,50467,50468,50469,50470,50471,50474,50475,50477,50478,50479,50481,50482,50483,50484,50485,50486,50487,50490,50492,50494,50495,50496,50497,50498,50499,50502,50503,50507,50511,50512,50513,50514,50518,50522,50523,50524,50527,50530,50531,50533,50534,50535,50537,50538,50539,50540,50541,50542,50543,50546,50550,50551,50552,50553,50554,50555,50558,50559,50561,50562,50563,50565,50566,50568,50569,50570,50571,50574,50576,50578,50579,50580,50582,50585,50586,50587,50589,50590,50591,50593,50594,50595,50596,50597,50598,50599,50600,50602,50603,50604,50605,50606,50607,50608,50609,50610,50611,50614,null,null,null,null,null,null,50615,50618,50623,50624,50625,50626,50627,50635,50637,50639,50642,50643,50645,50646,50647,50649,50650,50651,50652,50653,50654,50655,50658,50660,50662,50663,null,null,null,null,null,null,50664,50665,50666,50667,50671,50673,50674,50675,50677,50680,50681,50682,50683,50690,50691,50692,50697,50698,50699,50701,50702,50703,50705,50706,50707,50708,50709,50710,50711,50714,50717,50718,50719,50720,50721,50722,50723,50726,50727,50729,50730,50731,50735,50737,50738,50742,50744,50746,50748,50749,50750,50751,50754,50755,50757,50758,50759,50761,50762,50763,50764,50765,50766,50767,50770,50774,50775,50776,50777,50778,50779,50782,50783,50785,50786,50787,50788,50789,50790,50791,50792,50793,50794,50795,50797,50798,50800,50802,50803,50804,50805,50806,50807,50810,50811,50813,50814,50815,50817,50818,50819,50820,50821,50822,50823,50826,50828,50830,50831,50832,50833,50834,50835,50838,50839,50841,50842,50843,50845,50846,50847,50848,50849,50850,50851,50854,50856,50858,50859,50860,50861,50862,50863,50866,50867,50869,50870,50871,50875,50876,50877,50878,50879,50882,50884,50886,50887,50888,50889,50890,50891,50894,null,null,null,null,null,null,50895,50897,50898,50899,50901,50902,50903,50904,50905,50906,50907,50910,50911,50914,50915,50916,50917,50918,50919,50922,50923,50925,50926,50927,50929,50930,null,null,null,null,null,null,50931,50932,50933,50934,50935,50938,50939,50940,50942,50943,50944,50945,50946,50947,50950,50951,50953,50954,50955,50957,50958,50959,50960,50961,50962,50963,50966,50968,50970,50971,50972,50973,50974,50975,50978,50979,50981,50982,50983,50985,50986,50987,50988,50989,50990,50991,50994,50996,50998,51e3,51001,51002,51003,51006,51007,51009,51010,51011,51013,51014,51015,51016,51017,51019,51022,51024,51033,51034,51035,51037,51038,51039,51041,51042,51043,51044,51045,51046,51047,51049,51050,51052,51053,51054,51055,51056,51057,51058,51059,51062,51063,51065,51066,51067,51071,51072,51073,51074,51078,51083,51084,51085,51087,51090,51091,51093,51097,51099,51100,51101,51102,51103,51106,51111,51112,51113,51114,51115,51118,51119,51121,51122,51123,51125,51126,51127,51128,51129,51130,51131,51134,51138,51139,51140,51141,51142,51143,51146,51147,51149,51151,51153,51154,51155,51156,51157,51158,51159,51161,51162,51163,51164,null,null,null,null,null,null,51166,51167,51168,51169,51170,51171,51173,51174,51175,51177,51178,51179,51181,51182,51183,51184,51185,51186,51187,51188,51189,51190,51191,51192,51193,51194,null,null,null,null,null,null,51195,51196,51197,51198,51199,51202,51203,51205,51206,51207,51209,51211,51212,51213,51214,51215,51218,51220,51223,51224,51225,51226,51227,51230,51231,51233,51234,51235,51237,51238,51239,51240,51241,51242,51243,51246,51248,51250,51251,51252,51253,51254,51255,51257,51258,51259,51261,51262,51263,51265,51266,51267,51268,51269,51270,51271,51274,51275,51278,51279,51280,51281,51282,51283,51285,51286,51287,51288,51289,51290,51291,51292,51293,51294,51295,51296,51297,51298,51299,51300,51301,51302,51303,51304,51305,51306,51307,51308,51309,51310,51311,51314,51315,51317,51318,51319,51321,51323,51324,51325,51326,51327,51330,51332,51336,51337,51338,51342,51343,51344,51345,51346,51347,51349,51350,51351,51352,51353,51354,51355,51356,51358,51360,51362,51363,51364,51365,51366,51367,51369,51370,51371,51372,51373,51374,51375,51376,51377,51378,51379,51380,51381,51382,51383,51384,51385,51386,51387,51390,51391,51392,51393,null,null,null,null,null,null,51394,51395,51397,51398,51399,51401,51402,51403,51405,51406,51407,51408,51409,51410,51411,51414,51416,51418,51419,51420,51421,51422,51423,51426,51427,51429,null,null,null,null,null,null,51430,51431,51432,51433,51434,51435,51436,51437,51438,51439,51440,51441,51442,51443,51444,51446,51447,51448,51449,51450,51451,51454,51455,51457,51458,51459,51463,51464,51465,51466,51467,51470,12288,12289,12290,183,8229,8230,168,12291,173,8213,8741,65340,8764,8216,8217,8220,8221,12308,12309,12296,12297,12298,12299,12300,12301,12302,12303,12304,12305,177,215,247,8800,8804,8805,8734,8756,176,8242,8243,8451,8491,65504,65505,65509,9794,9792,8736,8869,8978,8706,8711,8801,8786,167,8251,9734,9733,9675,9679,9678,9671,9670,9633,9632,9651,9650,9661,9660,8594,8592,8593,8595,8596,12307,8810,8811,8730,8765,8733,8757,8747,8748,8712,8715,8838,8839,8834,8835,8746,8745,8743,8744,65506,51472,51474,51475,51476,51477,51478,51479,51481,51482,51483,51484,51485,51486,51487,51488,51489,51490,51491,51492,51493,51494,51495,51496,51497,51498,51499,null,null,null,null,null,null,51501,51502,51503,51504,51505,51506,51507,51509,51510,51511,51512,51513,51514,51515,51516,51517,51518,51519,51520,51521,51522,51523,51524,51525,51526,51527,null,null,null,null,null,null,51528,51529,51530,51531,51532,51533,51534,51535,51538,51539,51541,51542,51543,51545,51546,51547,51548,51549,51550,51551,51554,51556,51557,51558,51559,51560,51561,51562,51563,51565,51566,51567,8658,8660,8704,8707,180,65374,711,728,733,730,729,184,731,161,191,720,8750,8721,8719,164,8457,8240,9665,9664,9655,9654,9828,9824,9825,9829,9831,9827,8857,9672,9635,9680,9681,9618,9636,9637,9640,9639,9638,9641,9832,9743,9742,9756,9758,182,8224,8225,8597,8599,8601,8598,8600,9837,9833,9834,9836,12927,12828,8470,13255,8482,13250,13272,8481,8364,174,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,51569,51570,51571,51573,51574,51575,51576,51577,51578,51579,51581,51582,51583,51584,51585,51586,51587,51588,51589,51590,51591,51594,51595,51597,51598,51599,null,null,null,null,null,null,51601,51602,51603,51604,51605,51606,51607,51610,51612,51614,51615,51616,51617,51618,51619,51620,51621,51622,51623,51624,51625,51626,51627,51628,51629,51630,null,null,null,null,null,null,51631,51632,51633,51634,51635,51636,51637,51638,51639,51640,51641,51642,51643,51644,51645,51646,51647,51650,51651,51653,51654,51657,51659,51660,51661,51662,51663,51666,51668,51671,51672,51675,65281,65282,65283,65284,65285,65286,65287,65288,65289,65290,65291,65292,65293,65294,65295,65296,65297,65298,65299,65300,65301,65302,65303,65304,65305,65306,65307,65308,65309,65310,65311,65312,65313,65314,65315,65316,65317,65318,65319,65320,65321,65322,65323,65324,65325,65326,65327,65328,65329,65330,65331,65332,65333,65334,65335,65336,65337,65338,65339,65510,65341,65342,65343,65344,65345,65346,65347,65348,65349,65350,65351,65352,65353,65354,65355,65356,65357,65358,65359,65360,65361,65362,65363,65364,65365,65366,65367,65368,65369,65370,65371,65372,65373,65507,51678,51679,51681,51683,51685,51686,51688,51689,51690,51691,51694,51698,51699,51700,51701,51702,51703,51706,51707,51709,51710,51711,51713,51714,51715,51716,null,null,null,null,null,null,51717,51718,51719,51722,51726,51727,51728,51729,51730,51731,51733,51734,51735,51737,51738,51739,51740,51741,51742,51743,51744,51745,51746,51747,51748,51749,null,null,null,null,null,null,51750,51751,51752,51754,51755,51756,51757,51758,51759,51760,51761,51762,51763,51764,51765,51766,51767,51768,51769,51770,51771,51772,51773,51774,51775,51776,51777,51778,51779,51780,51781,51782,12593,12594,12595,12596,12597,12598,12599,12600,12601,12602,12603,12604,12605,12606,12607,12608,12609,12610,12611,12612,12613,12614,12615,12616,12617,12618,12619,12620,12621,12622,12623,12624,12625,12626,12627,12628,12629,12630,12631,12632,12633,12634,12635,12636,12637,12638,12639,12640,12641,12642,12643,12644,12645,12646,12647,12648,12649,12650,12651,12652,12653,12654,12655,12656,12657,12658,12659,12660,12661,12662,12663,12664,12665,12666,12667,12668,12669,12670,12671,12672,12673,12674,12675,12676,12677,12678,12679,12680,12681,12682,12683,12684,12685,12686,51783,51784,51785,51786,51787,51790,51791,51793,51794,51795,51797,51798,51799,51800,51801,51802,51803,51806,51810,51811,51812,51813,51814,51815,51817,51818,null,null,null,null,null,null,51819,51820,51821,51822,51823,51824,51825,51826,51827,51828,51829,51830,51831,51832,51833,51834,51835,51836,51838,51839,51840,51841,51842,51843,51845,51846,null,null,null,null,null,null,51847,51848,51849,51850,51851,51852,51853,51854,51855,51856,51857,51858,51859,51860,51861,51862,51863,51865,51866,51867,51868,51869,51870,51871,51872,51873,51874,51875,51876,51877,51878,51879,8560,8561,8562,8563,8564,8565,8566,8567,8568,8569,null,null,null,null,null,8544,8545,8546,8547,8548,8549,8550,8551,8552,8553,null,null,null,null,null,null,null,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,931,932,933,934,935,936,937,null,null,null,null,null,null,null,null,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,963,964,965,966,967,968,969,null,null,null,null,null,null,51880,51881,51882,51883,51884,51885,51886,51887,51888,51889,51890,51891,51892,51893,51894,51895,51896,51897,51898,51899,51902,51903,51905,51906,51907,51909,null,null,null,null,null,null,51910,51911,51912,51913,51914,51915,51918,51920,51922,51924,51925,51926,51927,51930,51931,51932,51933,51934,51935,51937,51938,51939,51940,51941,51942,51943,null,null,null,null,null,null,51944,51945,51946,51947,51949,51950,51951,51952,51953,51954,51955,51957,51958,51959,51960,51961,51962,51963,51964,51965,51966,51967,51968,51969,51970,51971,51972,51973,51974,51975,51977,51978,9472,9474,9484,9488,9496,9492,9500,9516,9508,9524,9532,9473,9475,9487,9491,9499,9495,9507,9523,9515,9531,9547,9504,9519,9512,9527,9535,9501,9520,9509,9528,9538,9490,9489,9498,9497,9494,9493,9486,9485,9502,9503,9505,9506,9510,9511,9513,9514,9517,9518,9521,9522,9525,9526,9529,9530,9533,9534,9536,9537,9539,9540,9541,9542,9543,9544,9545,9546,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,51979,51980,51981,51982,51983,51985,51986,51987,51989,51990,51991,51993,51994,51995,51996,51997,51998,51999,52002,52003,52004,52005,52006,52007,52008,52009,null,null,null,null,null,null,52010,52011,52012,52013,52014,52015,52016,52017,52018,52019,52020,52021,52022,52023,52024,52025,52026,52027,52028,52029,52030,52031,52032,52034,52035,52036,null,null,null,null,null,null,52037,52038,52039,52042,52043,52045,52046,52047,52049,52050,52051,52052,52053,52054,52055,52058,52059,52060,52062,52063,52064,52065,52066,52067,52069,52070,52071,52072,52073,52074,52075,52076,13205,13206,13207,8467,13208,13252,13219,13220,13221,13222,13209,13210,13211,13212,13213,13214,13215,13216,13217,13218,13258,13197,13198,13199,13263,13192,13193,13256,13223,13224,13232,13233,13234,13235,13236,13237,13238,13239,13240,13241,13184,13185,13186,13187,13188,13242,13243,13244,13245,13246,13247,13200,13201,13202,13203,13204,8486,13248,13249,13194,13195,13196,13270,13253,13229,13230,13231,13275,13225,13226,13227,13228,13277,13264,13267,13251,13257,13276,13254,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,52077,52078,52079,52080,52081,52082,52083,52084,52085,52086,52087,52090,52091,52092,52093,52094,52095,52096,52097,52098,52099,52100,52101,52102,52103,52104,null,null,null,null,null,null,52105,52106,52107,52108,52109,52110,52111,52112,52113,52114,52115,52116,52117,52118,52119,52120,52121,52122,52123,52125,52126,52127,52128,52129,52130,52131,null,null,null,null,null,null,52132,52133,52134,52135,52136,52137,52138,52139,52140,52141,52142,52143,52144,52145,52146,52147,52148,52149,52150,52151,52153,52154,52155,52156,52157,52158,52159,52160,52161,52162,52163,52164,198,208,170,294,null,306,null,319,321,216,338,186,222,358,330,null,12896,12897,12898,12899,12900,12901,12902,12903,12904,12905,12906,12907,12908,12909,12910,12911,12912,12913,12914,12915,12916,12917,12918,12919,12920,12921,12922,12923,9424,9425,9426,9427,9428,9429,9430,9431,9432,9433,9434,9435,9436,9437,9438,9439,9440,9441,9442,9443,9444,9445,9446,9447,9448,9449,9312,9313,9314,9315,9316,9317,9318,9319,9320,9321,9322,9323,9324,9325,9326,189,8531,8532,188,190,8539,8540,8541,8542,52165,52166,52167,52168,52169,52170,52171,52172,52173,52174,52175,52176,52177,52178,52179,52181,52182,52183,52184,52185,52186,52187,52188,52189,52190,52191,null,null,null,null,null,null,52192,52193,52194,52195,52197,52198,52200,52202,52203,52204,52205,52206,52207,52208,52209,52210,52211,52212,52213,52214,52215,52216,52217,52218,52219,52220,null,null,null,null,null,null,52221,52222,52223,52224,52225,52226,52227,52228,52229,52230,52231,52232,52233,52234,52235,52238,52239,52241,52242,52243,52245,52246,52247,52248,52249,52250,52251,52254,52255,52256,52259,52260,230,273,240,295,305,307,312,320,322,248,339,223,254,359,331,329,12800,12801,12802,12803,12804,12805,12806,12807,12808,12809,12810,12811,12812,12813,12814,12815,12816,12817,12818,12819,12820,12821,12822,12823,12824,12825,12826,12827,9372,9373,9374,9375,9376,9377,9378,9379,9380,9381,9382,9383,9384,9385,9386,9387,9388,9389,9390,9391,9392,9393,9394,9395,9396,9397,9332,9333,9334,9335,9336,9337,9338,9339,9340,9341,9342,9343,9344,9345,9346,185,178,179,8308,8319,8321,8322,8323,8324,52261,52262,52266,52267,52269,52271,52273,52274,52275,52276,52277,52278,52279,52282,52287,52288,52289,52290,52291,52294,52295,52297,52298,52299,52301,52302,null,null,null,null,null,null,52303,52304,52305,52306,52307,52310,52314,52315,52316,52317,52318,52319,52321,52322,52323,52325,52327,52329,52330,52331,52332,52333,52334,52335,52337,52338,null,null,null,null,null,null,52339,52340,52342,52343,52344,52345,52346,52347,52348,52349,52350,52351,52352,52353,52354,52355,52356,52357,52358,52359,52360,52361,52362,52363,52364,52365,52366,52367,52368,52369,52370,52371,12353,12354,12355,12356,12357,12358,12359,12360,12361,12362,12363,12364,12365,12366,12367,12368,12369,12370,12371,12372,12373,12374,12375,12376,12377,12378,12379,12380,12381,12382,12383,12384,12385,12386,12387,12388,12389,12390,12391,12392,12393,12394,12395,12396,12397,12398,12399,12400,12401,12402,12403,12404,12405,12406,12407,12408,12409,12410,12411,12412,12413,12414,12415,12416,12417,12418,12419,12420,12421,12422,12423,12424,12425,12426,12427,12428,12429,12430,12431,12432,12433,12434,12435,null,null,null,null,null,null,null,null,null,null,null,52372,52373,52374,52375,52378,52379,52381,52382,52383,52385,52386,52387,52388,52389,52390,52391,52394,52398,52399,52400,52401,52402,52403,52406,52407,52409,null,null,null,null,null,null,52410,52411,52413,52414,52415,52416,52417,52418,52419,52422,52424,52426,52427,52428,52429,52430,52431,52433,52434,52435,52437,52438,52439,52440,52441,52442,null,null,null,null,null,null,52443,52444,52445,52446,52447,52448,52449,52450,52451,52453,52454,52455,52456,52457,52458,52459,52461,52462,52463,52465,52466,52467,52468,52469,52470,52471,52472,52473,52474,52475,52476,52477,12449,12450,12451,12452,12453,12454,12455,12456,12457,12458,12459,12460,12461,12462,12463,12464,12465,12466,12467,12468,12469,12470,12471,12472,12473,12474,12475,12476,12477,12478,12479,12480,12481,12482,12483,12484,12485,12486,12487,12488,12489,12490,12491,12492,12493,12494,12495,12496,12497,12498,12499,12500,12501,12502,12503,12504,12505,12506,12507,12508,12509,12510,12511,12512,12513,12514,12515,12516,12517,12518,12519,12520,12521,12522,12523,12524,12525,12526,12527,12528,12529,12530,12531,12532,12533,12534,null,null,null,null,null,null,null,null,52478,52479,52480,52482,52483,52484,52485,52486,52487,52490,52491,52493,52494,52495,52497,52498,52499,52500,52501,52502,52503,52506,52508,52510,52511,52512,null,null,null,null,null,null,52513,52514,52515,52517,52518,52519,52521,52522,52523,52525,52526,52527,52528,52529,52530,52531,52532,52533,52534,52535,52536,52538,52539,52540,52541,52542,null,null,null,null,null,null,52543,52544,52545,52546,52547,52548,52549,52550,52551,52552,52553,52554,52555,52556,52557,52558,52559,52560,52561,52562,52563,52564,52565,52566,52567,52568,52569,52570,52571,52573,52574,52575,1040,1041,1042,1043,1044,1045,1025,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,1072,1073,1074,1075,1076,1077,1105,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,null,null,null,null,null,null,null,null,null,null,null,null,null,52577,52578,52579,52581,52582,52583,52584,52585,52586,52587,52590,52592,52594,52595,52596,52597,52598,52599,52601,52602,52603,52604,52605,52606,52607,52608,null,null,null,null,null,null,52609,52610,52611,52612,52613,52614,52615,52617,52618,52619,52620,52621,52622,52623,52624,52625,52626,52627,52630,52631,52633,52634,52635,52637,52638,52639,null,null,null,null,null,null,52640,52641,52642,52643,52646,52648,52650,52651,52652,52653,52654,52655,52657,52658,52659,52660,52661,52662,52663,52664,52665,52666,52667,52668,52669,52670,52671,52672,52673,52674,52675,52677,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,52678,52679,52680,52681,52682,52683,52685,52686,52687,52689,52690,52691,52692,52693,52694,52695,52696,52697,52698,52699,52700,52701,52702,52703,52704,52705,null,null,null,null,null,null,52706,52707,52708,52709,52710,52711,52713,52714,52715,52717,52718,52719,52721,52722,52723,52724,52725,52726,52727,52730,52732,52734,52735,52736,52737,52738,null,null,null,null,null,null,52739,52741,52742,52743,52745,52746,52747,52749,52750,52751,52752,52753,52754,52755,52757,52758,52759,52760,52762,52763,52764,52765,52766,52767,52770,52771,52773,52774,52775,52777,52778,52779,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,52780,52781,52782,52783,52786,52788,52790,52791,52792,52793,52794,52795,52796,52797,52798,52799,52800,52801,52802,52803,52804,52805,52806,52807,52808,52809,null,null,null,null,null,null,52810,52811,52812,52813,52814,52815,52816,52817,52818,52819,52820,52821,52822,52823,52826,52827,52829,52830,52834,52835,52836,52837,52838,52839,52842,52844,null,null,null,null,null,null,52846,52847,52848,52849,52850,52851,52854,52855,52857,52858,52859,52861,52862,52863,52864,52865,52866,52867,52870,52872,52874,52875,52876,52877,52878,52879,52882,52883,52885,52886,52887,52889,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,52890,52891,52892,52893,52894,52895,52898,52902,52903,52904,52905,52906,52907,52910,52911,52912,52913,52914,52915,52916,52917,52918,52919,52920,52921,52922,null,null,null,null,null,null,52923,52924,52925,52926,52927,52928,52930,52931,52932,52933,52934,52935,52936,52937,52938,52939,52940,52941,52942,52943,52944,52945,52946,52947,52948,52949,null,null,null,null,null,null,52950,52951,52952,52953,52954,52955,52956,52957,52958,52959,52960,52961,52962,52963,52966,52967,52969,52970,52973,52974,52975,52976,52977,52978,52979,52982,52986,52987,52988,52989,52990,52991,44032,44033,44036,44039,44040,44041,44042,44048,44049,44050,44051,44052,44053,44054,44055,44057,44058,44059,44060,44061,44064,44068,44076,44077,44079,44080,44081,44088,44089,44092,44096,44107,44109,44116,44120,44124,44144,44145,44148,44151,44152,44154,44160,44161,44163,44164,44165,44166,44169,44170,44171,44172,44176,44180,44188,44189,44191,44192,44193,44200,44201,44202,44204,44207,44208,44216,44217,44219,44220,44221,44225,44228,44232,44236,44245,44247,44256,44257,44260,44263,44264,44266,44268,44271,44272,44273,44275,44277,44278,44284,44285,44288,44292,44294,52994,52995,52997,52998,52999,53001,53002,53003,53004,53005,53006,53007,53010,53012,53014,53015,53016,53017,53018,53019,53021,53022,53023,53025,53026,53027,null,null,null,null,null,null,53029,53030,53031,53032,53033,53034,53035,53038,53042,53043,53044,53045,53046,53047,53049,53050,53051,53052,53053,53054,53055,53056,53057,53058,53059,53060,null,null,null,null,null,null,53061,53062,53063,53064,53065,53066,53067,53068,53069,53070,53071,53072,53073,53074,53075,53078,53079,53081,53082,53083,53085,53086,53087,53088,53089,53090,53091,53094,53096,53098,53099,53100,44300,44301,44303,44305,44312,44316,44320,44329,44332,44333,44340,44341,44344,44348,44356,44357,44359,44361,44368,44372,44376,44385,44387,44396,44397,44400,44403,44404,44405,44406,44411,44412,44413,44415,44417,44418,44424,44425,44428,44432,44444,44445,44452,44471,44480,44481,44484,44488,44496,44497,44499,44508,44512,44516,44536,44537,44540,44543,44544,44545,44552,44553,44555,44557,44564,44592,44593,44596,44599,44600,44602,44608,44609,44611,44613,44614,44618,44620,44621,44622,44624,44628,44630,44636,44637,44639,44640,44641,44645,44648,44649,44652,44656,44664,53101,53102,53103,53106,53107,53109,53110,53111,53113,53114,53115,53116,53117,53118,53119,53121,53122,53123,53124,53126,53127,53128,53129,53130,53131,53133,null,null,null,null,null,null,53134,53135,53136,53137,53138,53139,53140,53141,53142,53143,53144,53145,53146,53147,53148,53149,53150,53151,53152,53154,53155,53156,53157,53158,53159,53161,null,null,null,null,null,null,53162,53163,53164,53165,53166,53167,53169,53170,53171,53172,53173,53174,53175,53176,53177,53178,53179,53180,53181,53182,53183,53184,53185,53186,53187,53189,53190,53191,53192,53193,53194,53195,44665,44667,44668,44669,44676,44677,44684,44732,44733,44734,44736,44740,44748,44749,44751,44752,44753,44760,44761,44764,44776,44779,44781,44788,44792,44796,44807,44808,44813,44816,44844,44845,44848,44850,44852,44860,44861,44863,44865,44866,44867,44872,44873,44880,44892,44893,44900,44901,44921,44928,44932,44936,44944,44945,44949,44956,44984,44985,44988,44992,44999,45e3,45001,45003,45005,45006,45012,45020,45032,45033,45040,45041,45044,45048,45056,45057,45060,45068,45072,45076,45084,45085,45096,45124,45125,45128,45130,45132,45134,45139,45140,45141,45143,45145,53196,53197,53198,53199,53200,53201,53202,53203,53204,53205,53206,53207,53208,53209,53210,53211,53212,53213,53214,53215,53218,53219,53221,53222,53223,53225,null,null,null,null,null,null,53226,53227,53228,53229,53230,53231,53234,53236,53238,53239,53240,53241,53242,53243,53245,53246,53247,53249,53250,53251,53253,53254,53255,53256,53257,53258,null,null,null,null,null,null,53259,53260,53261,53262,53263,53264,53266,53267,53268,53269,53270,53271,53273,53274,53275,53276,53277,53278,53279,53280,53281,53282,53283,53284,53285,53286,53287,53288,53289,53290,53291,53292,45149,45180,45181,45184,45188,45196,45197,45199,45201,45208,45209,45210,45212,45215,45216,45217,45218,45224,45225,45227,45228,45229,45230,45231,45233,45235,45236,45237,45240,45244,45252,45253,45255,45256,45257,45264,45265,45268,45272,45280,45285,45320,45321,45323,45324,45328,45330,45331,45336,45337,45339,45340,45341,45347,45348,45349,45352,45356,45364,45365,45367,45368,45369,45376,45377,45380,45384,45392,45393,45396,45397,45400,45404,45408,45432,45433,45436,45440,45442,45448,45449,45451,45453,45458,45459,45460,45464,45468,45480,45516,45520,45524,45532,45533,53294,53295,53296,53297,53298,53299,53302,53303,53305,53306,53307,53309,53310,53311,53312,53313,53314,53315,53318,53320,53322,53323,53324,53325,53326,53327,null,null,null,null,null,null,53329,53330,53331,53333,53334,53335,53337,53338,53339,53340,53341,53342,53343,53345,53346,53347,53348,53349,53350,53351,53352,53353,53354,53355,53358,53359,null,null,null,null,null,null,53361,53362,53363,53365,53366,53367,53368,53369,53370,53371,53374,53375,53376,53378,53379,53380,53381,53382,53383,53384,53385,53386,53387,53388,53389,53390,53391,53392,53393,53394,53395,53396,45535,45544,45545,45548,45552,45561,45563,45565,45572,45573,45576,45579,45580,45588,45589,45591,45593,45600,45620,45628,45656,45660,45664,45672,45673,45684,45685,45692,45700,45701,45705,45712,45713,45716,45720,45721,45722,45728,45729,45731,45733,45734,45738,45740,45744,45748,45768,45769,45772,45776,45778,45784,45785,45787,45789,45794,45796,45797,45798,45800,45803,45804,45805,45806,45807,45811,45812,45813,45815,45816,45817,45818,45819,45823,45824,45825,45828,45832,45840,45841,45843,45844,45845,45852,45908,45909,45910,45912,45915,45916,45918,45919,45924,45925,53397,53398,53399,53400,53401,53402,53403,53404,53405,53406,53407,53408,53409,53410,53411,53414,53415,53417,53418,53419,53421,53422,53423,53424,53425,53426,null,null,null,null,null,null,53427,53430,53432,53434,53435,53436,53437,53438,53439,53442,53443,53445,53446,53447,53450,53451,53452,53453,53454,53455,53458,53462,53463,53464,53465,53466,null,null,null,null,null,null,53467,53470,53471,53473,53474,53475,53477,53478,53479,53480,53481,53482,53483,53486,53490,53491,53492,53493,53494,53495,53497,53498,53499,53500,53501,53502,53503,53504,53505,53506,53507,53508,45927,45929,45931,45934,45936,45937,45940,45944,45952,45953,45955,45956,45957,45964,45968,45972,45984,45985,45992,45996,46020,46021,46024,46027,46028,46030,46032,46036,46037,46039,46041,46043,46045,46048,46052,46056,46076,46096,46104,46108,46112,46120,46121,46123,46132,46160,46161,46164,46168,46176,46177,46179,46181,46188,46208,46216,46237,46244,46248,46252,46261,46263,46265,46272,46276,46280,46288,46293,46300,46301,46304,46307,46308,46310,46316,46317,46319,46321,46328,46356,46357,46360,46363,46364,46372,46373,46375,46376,46377,46378,46384,46385,46388,46392,53509,53510,53511,53512,53513,53514,53515,53516,53518,53519,53520,53521,53522,53523,53524,53525,53526,53527,53528,53529,53530,53531,53532,53533,53534,53535,null,null,null,null,null,null,53536,53537,53538,53539,53540,53541,53542,53543,53544,53545,53546,53547,53548,53549,53550,53551,53554,53555,53557,53558,53559,53561,53563,53564,53565,53566,null,null,null,null,null,null,53567,53570,53574,53575,53576,53577,53578,53579,53582,53583,53585,53586,53587,53589,53590,53591,53592,53593,53594,53595,53598,53600,53602,53603,53604,53605,53606,53607,53609,53610,53611,53613,46400,46401,46403,46404,46405,46411,46412,46413,46416,46420,46428,46429,46431,46432,46433,46496,46497,46500,46504,46506,46507,46512,46513,46515,46516,46517,46523,46524,46525,46528,46532,46540,46541,46543,46544,46545,46552,46572,46608,46609,46612,46616,46629,46636,46644,46664,46692,46696,46748,46749,46752,46756,46763,46764,46769,46804,46832,46836,46840,46848,46849,46853,46888,46889,46892,46895,46896,46904,46905,46907,46916,46920,46924,46932,46933,46944,46948,46952,46960,46961,46963,46965,46972,46973,46976,46980,46988,46989,46991,46992,46993,46994,46998,46999,53614,53615,53616,53617,53618,53619,53620,53621,53622,53623,53624,53625,53626,53627,53629,53630,53631,53632,53633,53634,53635,53637,53638,53639,53641,53642,null,null,null,null,null,null,53643,53644,53645,53646,53647,53648,53649,53650,53651,53652,53653,53654,53655,53656,53657,53658,53659,53660,53661,53662,53663,53666,53667,53669,53670,53671,null,null,null,null,null,null,53673,53674,53675,53676,53677,53678,53679,53682,53684,53686,53687,53688,53689,53691,53693,53694,53695,53697,53698,53699,53700,53701,53702,53703,53704,53705,53706,53707,53708,53709,53710,53711,47e3,47001,47004,47008,47016,47017,47019,47020,47021,47028,47029,47032,47047,47049,47084,47085,47088,47092,47100,47101,47103,47104,47105,47111,47112,47113,47116,47120,47128,47129,47131,47133,47140,47141,47144,47148,47156,47157,47159,47160,47161,47168,47172,47185,47187,47196,47197,47200,47204,47212,47213,47215,47217,47224,47228,47245,47272,47280,47284,47288,47296,47297,47299,47301,47308,47312,47316,47325,47327,47329,47336,47337,47340,47344,47352,47353,47355,47357,47364,47384,47392,47420,47421,47424,47428,47436,47439,47441,47448,47449,47452,47456,47464,47465,53712,53713,53714,53715,53716,53717,53718,53719,53721,53722,53723,53724,53725,53726,53727,53728,53729,53730,53731,53732,53733,53734,53735,53736,53737,53738,null,null,null,null,null,null,53739,53740,53741,53742,53743,53744,53745,53746,53747,53749,53750,53751,53753,53754,53755,53756,53757,53758,53759,53760,53761,53762,53763,53764,53765,53766,null,null,null,null,null,null,53768,53770,53771,53772,53773,53774,53775,53777,53778,53779,53780,53781,53782,53783,53784,53785,53786,53787,53788,53789,53790,53791,53792,53793,53794,53795,53796,53797,53798,53799,53800,53801,47467,47469,47476,47477,47480,47484,47492,47493,47495,47497,47498,47501,47502,47532,47533,47536,47540,47548,47549,47551,47553,47560,47561,47564,47566,47567,47568,47569,47570,47576,47577,47579,47581,47582,47585,47587,47588,47589,47592,47596,47604,47605,47607,47608,47609,47610,47616,47617,47624,47637,47672,47673,47676,47680,47682,47688,47689,47691,47693,47694,47699,47700,47701,47704,47708,47716,47717,47719,47720,47721,47728,47729,47732,47736,47747,47748,47749,47751,47756,47784,47785,47787,47788,47792,47794,47800,47801,47803,47805,47812,47816,47832,47833,47868,53802,53803,53806,53807,53809,53810,53811,53813,53814,53815,53816,53817,53818,53819,53822,53824,53826,53827,53828,53829,53830,53831,53833,53834,53835,53836,null,null,null,null,null,null,53837,53838,53839,53840,53841,53842,53843,53844,53845,53846,53847,53848,53849,53850,53851,53853,53854,53855,53856,53857,53858,53859,53861,53862,53863,53864,null,null,null,null,null,null,53865,53866,53867,53868,53869,53870,53871,53872,53873,53874,53875,53876,53877,53878,53879,53880,53881,53882,53883,53884,53885,53886,53887,53890,53891,53893,53894,53895,53897,53898,53899,53900,47872,47876,47885,47887,47889,47896,47900,47904,47913,47915,47924,47925,47926,47928,47931,47932,47933,47934,47940,47941,47943,47945,47949,47951,47952,47956,47960,47969,47971,47980,48008,48012,48016,48036,48040,48044,48052,48055,48064,48068,48072,48080,48083,48120,48121,48124,48127,48128,48130,48136,48137,48139,48140,48141,48143,48145,48148,48149,48150,48151,48152,48155,48156,48157,48158,48159,48164,48165,48167,48169,48173,48176,48177,48180,48184,48192,48193,48195,48196,48197,48201,48204,48205,48208,48221,48260,48261,48264,48267,48268,48270,48276,48277,48279,53901,53902,53903,53906,53907,53908,53910,53911,53912,53913,53914,53915,53917,53918,53919,53921,53922,53923,53925,53926,53927,53928,53929,53930,53931,53933,null,null,null,null,null,null,53934,53935,53936,53938,53939,53940,53941,53942,53943,53946,53947,53949,53950,53953,53955,53956,53957,53958,53959,53962,53964,53965,53966,53967,53968,53969,null,null,null,null,null,null,53970,53971,53973,53974,53975,53977,53978,53979,53981,53982,53983,53984,53985,53986,53987,53990,53991,53992,53993,53994,53995,53996,53997,53998,53999,54002,54003,54005,54006,54007,54009,54010,48281,48282,48288,48289,48292,48295,48296,48304,48305,48307,48308,48309,48316,48317,48320,48324,48333,48335,48336,48337,48341,48344,48348,48372,48373,48374,48376,48380,48388,48389,48391,48393,48400,48404,48420,48428,48448,48456,48457,48460,48464,48472,48473,48484,48488,48512,48513,48516,48519,48520,48521,48522,48528,48529,48531,48533,48537,48538,48540,48548,48560,48568,48596,48597,48600,48604,48617,48624,48628,48632,48640,48643,48645,48652,48653,48656,48660,48668,48669,48671,48708,48709,48712,48716,48718,48724,48725,48727,48729,48730,48731,48736,48737,48740,54011,54012,54013,54014,54015,54018,54020,54022,54023,54024,54025,54026,54027,54031,54033,54034,54035,54037,54039,54040,54041,54042,54043,54046,54050,54051,null,null,null,null,null,null,54052,54054,54055,54058,54059,54061,54062,54063,54065,54066,54067,54068,54069,54070,54071,54074,54078,54079,54080,54081,54082,54083,54086,54087,54088,54089,null,null,null,null,null,null,54090,54091,54092,54093,54094,54095,54096,54097,54098,54099,54100,54101,54102,54103,54104,54105,54106,54107,54108,54109,54110,54111,54112,54113,54114,54115,54116,54117,54118,54119,54120,54121,48744,48746,48752,48753,48755,48756,48757,48763,48764,48765,48768,48772,48780,48781,48783,48784,48785,48792,48793,48808,48848,48849,48852,48855,48856,48864,48867,48868,48869,48876,48897,48904,48905,48920,48921,48923,48924,48925,48960,48961,48964,48968,48976,48977,48981,49044,49072,49093,49100,49101,49104,49108,49116,49119,49121,49212,49233,49240,49244,49248,49256,49257,49296,49297,49300,49304,49312,49313,49315,49317,49324,49325,49327,49328,49331,49332,49333,49334,49340,49341,49343,49344,49345,49349,49352,49353,49356,49360,49368,49369,49371,49372,49373,49380,54122,54123,54124,54125,54126,54127,54128,54129,54130,54131,54132,54133,54134,54135,54136,54137,54138,54139,54142,54143,54145,54146,54147,54149,54150,54151,null,null,null,null,null,null,54152,54153,54154,54155,54158,54162,54163,54164,54165,54166,54167,54170,54171,54173,54174,54175,54177,54178,54179,54180,54181,54182,54183,54186,54188,54190,null,null,null,null,null,null,54191,54192,54193,54194,54195,54197,54198,54199,54201,54202,54203,54205,54206,54207,54208,54209,54210,54211,54214,54215,54218,54219,54220,54221,54222,54223,54225,54226,54227,54228,54229,54230,49381,49384,49388,49396,49397,49399,49401,49408,49412,49416,49424,49429,49436,49437,49438,49439,49440,49443,49444,49446,49447,49452,49453,49455,49456,49457,49462,49464,49465,49468,49472,49480,49481,49483,49484,49485,49492,49493,49496,49500,49508,49509,49511,49512,49513,49520,49524,49528,49541,49548,49549,49550,49552,49556,49558,49564,49565,49567,49569,49573,49576,49577,49580,49584,49597,49604,49608,49612,49620,49623,49624,49632,49636,49640,49648,49649,49651,49660,49661,49664,49668,49676,49677,49679,49681,49688,49689,49692,49695,49696,49704,49705,49707,49709,54231,54233,54234,54235,54236,54237,54238,54239,54240,54242,54244,54245,54246,54247,54248,54249,54250,54251,54254,54255,54257,54258,54259,54261,54262,54263,null,null,null,null,null,null,54264,54265,54266,54267,54270,54272,54274,54275,54276,54277,54278,54279,54281,54282,54283,54284,54285,54286,54287,54288,54289,54290,54291,54292,54293,54294,null,null,null,null,null,null,54295,54296,54297,54298,54299,54300,54302,54303,54304,54305,54306,54307,54308,54309,54310,54311,54312,54313,54314,54315,54316,54317,54318,54319,54320,54321,54322,54323,54324,54325,54326,54327,49711,49713,49714,49716,49736,49744,49745,49748,49752,49760,49765,49772,49773,49776,49780,49788,49789,49791,49793,49800,49801,49808,49816,49819,49821,49828,49829,49832,49836,49837,49844,49845,49847,49849,49884,49885,49888,49891,49892,49899,49900,49901,49903,49905,49910,49912,49913,49915,49916,49920,49928,49929,49932,49933,49939,49940,49941,49944,49948,49956,49957,49960,49961,49989,50024,50025,50028,50032,50034,50040,50041,50044,50045,50052,50056,50060,50112,50136,50137,50140,50143,50144,50146,50152,50153,50157,50164,50165,50168,50184,50192,50212,50220,50224,54328,54329,54330,54331,54332,54333,54334,54335,54337,54338,54339,54341,54342,54343,54344,54345,54346,54347,54348,54349,54350,54351,54352,54353,54354,54355,null,null,null,null,null,null,54356,54357,54358,54359,54360,54361,54362,54363,54365,54366,54367,54369,54370,54371,54373,54374,54375,54376,54377,54378,54379,54380,54382,54384,54385,54386,null,null,null,null,null,null,54387,54388,54389,54390,54391,54394,54395,54397,54398,54401,54403,54404,54405,54406,54407,54410,54412,54414,54415,54416,54417,54418,54419,54421,54422,54423,54424,54425,54426,54427,54428,54429,50228,50236,50237,50248,50276,50277,50280,50284,50292,50293,50297,50304,50324,50332,50360,50364,50409,50416,50417,50420,50424,50426,50431,50432,50433,50444,50448,50452,50460,50472,50473,50476,50480,50488,50489,50491,50493,50500,50501,50504,50505,50506,50508,50509,50510,50515,50516,50517,50519,50520,50521,50525,50526,50528,50529,50532,50536,50544,50545,50547,50548,50549,50556,50557,50560,50564,50567,50572,50573,50575,50577,50581,50583,50584,50588,50592,50601,50612,50613,50616,50617,50619,50620,50621,50622,50628,50629,50630,50631,50632,50633,50634,50636,50638,54430,54431,54432,54433,54434,54435,54436,54437,54438,54439,54440,54442,54443,54444,54445,54446,54447,54448,54449,54450,54451,54452,54453,54454,54455,54456,null,null,null,null,null,null,54457,54458,54459,54460,54461,54462,54463,54464,54465,54466,54467,54468,54469,54470,54471,54472,54473,54474,54475,54477,54478,54479,54481,54482,54483,54485,null,null,null,null,null,null,54486,54487,54488,54489,54490,54491,54493,54494,54496,54497,54498,54499,54500,54501,54502,54503,54505,54506,54507,54509,54510,54511,54513,54514,54515,54516,54517,54518,54519,54521,54522,54524,50640,50641,50644,50648,50656,50657,50659,50661,50668,50669,50670,50672,50676,50678,50679,50684,50685,50686,50687,50688,50689,50693,50694,50695,50696,50700,50704,50712,50713,50715,50716,50724,50725,50728,50732,50733,50734,50736,50739,50740,50741,50743,50745,50747,50752,50753,50756,50760,50768,50769,50771,50772,50773,50780,50781,50784,50796,50799,50801,50808,50809,50812,50816,50824,50825,50827,50829,50836,50837,50840,50844,50852,50853,50855,50857,50864,50865,50868,50872,50873,50874,50880,50881,50883,50885,50892,50893,50896,50900,50908,50909,50912,50913,50920,54526,54527,54528,54529,54530,54531,54533,54534,54535,54537,54538,54539,54541,54542,54543,54544,54545,54546,54547,54550,54552,54553,54554,54555,54556,54557,null,null,null,null,null,null,54558,54559,54560,54561,54562,54563,54564,54565,54566,54567,54568,54569,54570,54571,54572,54573,54574,54575,54576,54577,54578,54579,54580,54581,54582,54583,null,null,null,null,null,null,54584,54585,54586,54587,54590,54591,54593,54594,54595,54597,54598,54599,54600,54601,54602,54603,54606,54608,54610,54611,54612,54613,54614,54615,54618,54619,54621,54622,54623,54625,54626,54627,50921,50924,50928,50936,50937,50941,50948,50949,50952,50956,50964,50965,50967,50969,50976,50977,50980,50984,50992,50993,50995,50997,50999,51004,51005,51008,51012,51018,51020,51021,51023,51025,51026,51027,51028,51029,51030,51031,51032,51036,51040,51048,51051,51060,51061,51064,51068,51069,51070,51075,51076,51077,51079,51080,51081,51082,51086,51088,51089,51092,51094,51095,51096,51098,51104,51105,51107,51108,51109,51110,51116,51117,51120,51124,51132,51133,51135,51136,51137,51144,51145,51148,51150,51152,51160,51165,51172,51176,51180,51200,51201,51204,51208,51210,54628,54630,54631,54634,54636,54638,54639,54640,54641,54642,54643,54646,54647,54649,54650,54651,54653,54654,54655,54656,54657,54658,54659,54662,54666,54667,null,null,null,null,null,null,54668,54669,54670,54671,54673,54674,54675,54676,54677,54678,54679,54680,54681,54682,54683,54684,54685,54686,54687,54688,54689,54690,54691,54692,54694,54695,null,null,null,null,null,null,54696,54697,54698,54699,54700,54701,54702,54703,54704,54705,54706,54707,54708,54709,54710,54711,54712,54713,54714,54715,54716,54717,54718,54719,54720,54721,54722,54723,54724,54725,54726,54727,51216,51217,51219,51221,51222,51228,51229,51232,51236,51244,51245,51247,51249,51256,51260,51264,51272,51273,51276,51277,51284,51312,51313,51316,51320,51322,51328,51329,51331,51333,51334,51335,51339,51340,51341,51348,51357,51359,51361,51368,51388,51389,51396,51400,51404,51412,51413,51415,51417,51424,51425,51428,51445,51452,51453,51456,51460,51461,51462,51468,51469,51471,51473,51480,51500,51508,51536,51537,51540,51544,51552,51553,51555,51564,51568,51572,51580,51592,51593,51596,51600,51608,51609,51611,51613,51648,51649,51652,51655,51656,51658,51664,51665,51667,54730,54731,54733,54734,54735,54737,54739,54740,54741,54742,54743,54746,54748,54750,54751,54752,54753,54754,54755,54758,54759,54761,54762,54763,54765,54766,null,null,null,null,null,null,54767,54768,54769,54770,54771,54774,54776,54778,54779,54780,54781,54782,54783,54786,54787,54789,54790,54791,54793,54794,54795,54796,54797,54798,54799,54802,null,null,null,null,null,null,54806,54807,54808,54809,54810,54811,54813,54814,54815,54817,54818,54819,54821,54822,54823,54824,54825,54826,54827,54828,54830,54831,54832,54833,54834,54835,54836,54837,54838,54839,54842,54843,51669,51670,51673,51674,51676,51677,51680,51682,51684,51687,51692,51693,51695,51696,51697,51704,51705,51708,51712,51720,51721,51723,51724,51725,51732,51736,51753,51788,51789,51792,51796,51804,51805,51807,51808,51809,51816,51837,51844,51864,51900,51901,51904,51908,51916,51917,51919,51921,51923,51928,51929,51936,51948,51956,51976,51984,51988,51992,52e3,52001,52033,52040,52041,52044,52048,52056,52057,52061,52068,52088,52089,52124,52152,52180,52196,52199,52201,52236,52237,52240,52244,52252,52253,52257,52258,52263,52264,52265,52268,52270,52272,52280,52281,52283,54845,54846,54847,54849,54850,54851,54852,54854,54855,54858,54860,54862,54863,54864,54866,54867,54870,54871,54873,54874,54875,54877,54878,54879,54880,54881,null,null,null,null,null,null,54882,54883,54884,54885,54886,54888,54890,54891,54892,54893,54894,54895,54898,54899,54901,54902,54903,54904,54905,54906,54907,54908,54909,54910,54911,54912,null,null,null,null,null,null,54913,54914,54916,54918,54919,54920,54921,54922,54923,54926,54927,54929,54930,54931,54933,54934,54935,54936,54937,54938,54939,54940,54942,54944,54946,54947,54948,54949,54950,54951,54953,54954,52284,52285,52286,52292,52293,52296,52300,52308,52309,52311,52312,52313,52320,52324,52326,52328,52336,52341,52376,52377,52380,52384,52392,52393,52395,52396,52397,52404,52405,52408,52412,52420,52421,52423,52425,52432,52436,52452,52460,52464,52481,52488,52489,52492,52496,52504,52505,52507,52509,52516,52520,52524,52537,52572,52576,52580,52588,52589,52591,52593,52600,52616,52628,52629,52632,52636,52644,52645,52647,52649,52656,52676,52684,52688,52712,52716,52720,52728,52729,52731,52733,52740,52744,52748,52756,52761,52768,52769,52772,52776,52784,52785,52787,52789,54955,54957,54958,54959,54961,54962,54963,54964,54965,54966,54967,54968,54970,54972,54973,54974,54975,54976,54977,54978,54979,54982,54983,54985,54986,54987,null,null,null,null,null,null,54989,54990,54991,54992,54994,54995,54997,54998,55e3,55002,55003,55004,55005,55006,55007,55009,55010,55011,55013,55014,55015,55017,55018,55019,55020,55021,null,null,null,null,null,null,55022,55023,55025,55026,55027,55028,55030,55031,55032,55033,55034,55035,55038,55039,55041,55042,55043,55045,55046,55047,55048,55049,55050,55051,55052,55053,55054,55055,55056,55058,55059,55060,52824,52825,52828,52831,52832,52833,52840,52841,52843,52845,52852,52853,52856,52860,52868,52869,52871,52873,52880,52881,52884,52888,52896,52897,52899,52900,52901,52908,52909,52929,52964,52965,52968,52971,52972,52980,52981,52983,52984,52985,52992,52993,52996,53e3,53008,53009,53011,53013,53020,53024,53028,53036,53037,53039,53040,53041,53048,53076,53077,53080,53084,53092,53093,53095,53097,53104,53105,53108,53112,53120,53125,53132,53153,53160,53168,53188,53216,53217,53220,53224,53232,53233,53235,53237,53244,53248,53252,53265,53272,53293,53300,53301,53304,53308,55061,55062,55063,55066,55067,55069,55070,55071,55073,55074,55075,55076,55077,55078,55079,55082,55084,55086,55087,55088,55089,55090,55091,55094,55095,55097,null,null,null,null,null,null,55098,55099,55101,55102,55103,55104,55105,55106,55107,55109,55110,55112,55114,55115,55116,55117,55118,55119,55122,55123,55125,55130,55131,55132,55133,55134,null,null,null,null,null,null,55135,55138,55140,55142,55143,55144,55146,55147,55149,55150,55151,55153,55154,55155,55157,55158,55159,55160,55161,55162,55163,55166,55167,55168,55170,55171,55172,55173,55174,55175,55178,55179,53316,53317,53319,53321,53328,53332,53336,53344,53356,53357,53360,53364,53372,53373,53377,53412,53413,53416,53420,53428,53429,53431,53433,53440,53441,53444,53448,53449,53456,53457,53459,53460,53461,53468,53469,53472,53476,53484,53485,53487,53488,53489,53496,53517,53552,53553,53556,53560,53562,53568,53569,53571,53572,53573,53580,53581,53584,53588,53596,53597,53599,53601,53608,53612,53628,53636,53640,53664,53665,53668,53672,53680,53681,53683,53685,53690,53692,53696,53720,53748,53752,53767,53769,53776,53804,53805,53808,53812,53820,53821,53823,53825,53832,53852,55181,55182,55183,55185,55186,55187,55188,55189,55190,55191,55194,55196,55198,55199,55200,55201,55202,55203,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,53860,53888,53889,53892,53896,53904,53905,53909,53916,53920,53924,53932,53937,53944,53945,53948,53951,53952,53954,53960,53961,53963,53972,53976,53980,53988,53989,54e3,54001,54004,54008,54016,54017,54019,54021,54028,54029,54030,54032,54036,54038,54044,54045,54047,54048,54049,54053,54056,54057,54060,54064,54072,54073,54075,54076,54077,54084,54085,54140,54141,54144,54148,54156,54157,54159,54160,54161,54168,54169,54172,54176,54184,54185,54187,54189,54196,54200,54204,54212,54213,54216,54217,54224,54232,54241,54243,54252,54253,54256,54260,54268,54269,54271,54273,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,54280,54301,54336,54340,54364,54368,54372,54381,54383,54392,54393,54396,54399,54400,54402,54408,54409,54411,54413,54420,54441,54476,54480,54484,54492,54495,54504,54508,54512,54520,54523,54525,54532,54536,54540,54548,54549,54551,54588,54589,54592,54596,54604,54605,54607,54609,54616,54617,54620,54624,54629,54632,54633,54635,54637,54644,54645,54648,54652,54660,54661,54663,54664,54665,54672,54693,54728,54729,54732,54736,54738,54744,54745,54747,54749,54756,54757,54760,54764,54772,54773,54775,54777,54784,54785,54788,54792,54800,54801,54803,54804,54805,54812,54816,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,54820,54829,54840,54841,54844,54848,54853,54856,54857,54859,54861,54865,54868,54869,54872,54876,54887,54889,54896,54897,54900,54915,54917,54924,54925,54928,54932,54941,54943,54945,54952,54956,54960,54969,54971,54980,54981,54984,54988,54993,54996,54999,55001,55008,55012,55016,55024,55029,55036,55037,55040,55044,55057,55064,55065,55068,55072,55080,55081,55083,55085,55092,55093,55096,55100,55108,55111,55113,55120,55121,55124,55126,55127,55128,55129,55136,55137,55139,55141,55145,55148,55152,55156,55164,55165,55169,55176,55177,55180,55184,55192,55193,55195,55197,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,20285,20339,20551,20729,21152,21487,21621,21733,22025,23233,23478,26247,26550,26551,26607,27468,29634,30146,31292,33499,33540,34903,34952,35382,36040,36303,36603,36838,39381,21051,21364,21508,24682,24932,27580,29647,33050,35258,35282,38307,20355,21002,22718,22904,23014,24178,24185,25031,25536,26438,26604,26751,28567,30286,30475,30965,31240,31487,31777,32925,33390,33393,35563,38291,20075,21917,26359,28212,30883,31469,33883,35088,34638,38824,21208,22350,22570,23884,24863,25022,25121,25954,26577,27204,28187,29976,30131,30435,30640,32058,37039,37969,37970,40853,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,21283,23724,30002,32987,37440,38296,21083,22536,23004,23713,23831,24247,24378,24394,24951,27743,30074,30086,31968,32115,32177,32652,33108,33313,34193,35137,35611,37628,38477,40007,20171,20215,20491,20977,22607,24887,24894,24936,25913,27114,28433,30117,30342,30422,31623,33445,33995,63744,37799,38283,21888,23458,22353,63745,31923,32697,37301,20520,21435,23621,24040,25298,25454,25818,25831,28192,28844,31067,36317,36382,63746,36989,37445,37624,20094,20214,20581,24062,24314,24838,26967,33137,34388,36423,37749,39467,20062,20625,26480,26688,20745,21133,21138,27298,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,30652,37392,40660,21163,24623,36850,20552,25001,25581,25802,26684,27268,28608,33160,35233,38548,22533,29309,29356,29956,32121,32365,32937,35211,35700,36963,40273,25225,27770,28500,32080,32570,35363,20860,24906,31645,35609,37463,37772,20140,20435,20510,20670,20742,21185,21197,21375,22384,22659,24218,24465,24950,25004,25806,25964,26223,26299,26356,26775,28039,28805,28913,29855,29861,29898,30169,30828,30956,31455,31478,32069,32147,32789,32831,33051,33686,35686,36629,36885,37857,38915,38968,39514,39912,20418,21843,22586,22865,23395,23622,24760,25106,26690,26800,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,26856,28330,30028,30328,30926,31293,31995,32363,32380,35336,35489,35903,38542,40388,21476,21481,21578,21617,22266,22993,23396,23611,24235,25335,25911,25925,25970,26272,26543,27073,27837,30204,30352,30590,31295,32660,32771,32929,33167,33510,33533,33776,34241,34865,34996,35493,63747,36764,37678,38599,39015,39640,40723,21741,26011,26354,26767,31296,35895,40288,22256,22372,23825,26118,26801,26829,28414,29736,34974,39908,27752,63748,39592,20379,20844,20849,21151,23380,24037,24656,24685,25329,25511,25915,29657,31354,34467,36002,38799,20018,23521,25096,26524,29916,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,31185,33747,35463,35506,36328,36942,37707,38982,24275,27112,34303,37101,63749,20896,23448,23532,24931,26874,27454,28748,29743,29912,31649,32592,33733,35264,36011,38364,39208,21038,24669,25324,36866,20362,20809,21281,22745,24291,26336,27960,28826,29378,29654,31568,33009,37979,21350,25499,32619,20054,20608,22602,22750,24618,24871,25296,27088,39745,23439,32024,32945,36703,20132,20689,21676,21932,23308,23968,24039,25898,25934,26657,27211,29409,30350,30703,32094,32761,33184,34126,34527,36611,36686,37066,39171,39509,39851,19992,20037,20061,20167,20465,20855,21246,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,21312,21475,21477,21646,22036,22389,22434,23495,23943,24272,25084,25304,25937,26552,26601,27083,27472,27590,27628,27714,28317,28792,29399,29590,29699,30655,30697,31350,32127,32777,33276,33285,33290,33503,34914,35635,36092,36544,36881,37041,37476,37558,39378,39493,40169,40407,40860,22283,23616,33738,38816,38827,40628,21531,31384,32676,35033,36557,37089,22528,23624,25496,31391,23470,24339,31353,31406,33422,36524,20518,21048,21240,21367,22280,25331,25458,27402,28099,30519,21413,29527,34152,36470,38357,26426,27331,28528,35437,36556,39243,63750,26231,27512,36020,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,39740,63751,21483,22317,22862,25542,27131,29674,30789,31418,31429,31998,33909,35215,36211,36917,38312,21243,22343,30023,31584,33740,37406,63752,27224,20811,21067,21127,25119,26840,26997,38553,20677,21156,21220,25027,26020,26681,27135,29822,31563,33465,33771,35250,35641,36817,39241,63753,20170,22935,25810,26129,27278,29748,31105,31165,33449,34942,34943,35167,63754,37670,20235,21450,24613,25201,27762,32026,32102,20120,20834,30684,32943,20225,20238,20854,20864,21980,22120,22331,22522,22524,22804,22855,22931,23492,23696,23822,24049,24190,24524,25216,26071,26083,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,26398,26399,26462,26827,26820,27231,27450,27683,27773,27778,28103,29592,29734,29738,29826,29859,30072,30079,30849,30959,31041,31047,31048,31098,31637,32e3,32186,32648,32774,32813,32908,35352,35663,35912,36215,37665,37668,39138,39249,39438,39439,39525,40594,32202,20342,21513,25326,26708,37329,21931,20794,63755,63756,23068,25062,63757,25295,25343,63758,63759,63760,63761,63762,63763,37027,63764,63765,63766,63767,63768,35582,63769,63770,63771,63772,26262,63773,29014,63774,63775,38627,63776,25423,25466,21335,63777,26511,26976,28275,63778,30007,63779,63780,63781,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,32013,63782,63783,34930,22218,23064,63784,63785,63786,63787,63788,20035,63789,20839,22856,26608,32784,63790,22899,24180,25754,31178,24565,24684,25288,25467,23527,23511,21162,63791,22900,24361,24594,63792,63793,63794,29785,63795,63796,63797,63798,63799,63800,39377,63801,63802,63803,63804,63805,63806,63807,63808,63809,63810,63811,28611,63812,63813,33215,36786,24817,63814,63815,33126,63816,63817,23615,63818,63819,63820,63821,63822,63823,63824,63825,23273,35365,26491,32016,63826,63827,63828,63829,63830,63831,33021,63832,63833,23612,27877,21311,28346,22810,33590,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,20025,20150,20294,21934,22296,22727,24406,26039,26086,27264,27573,28237,30701,31471,31774,32222,34507,34962,37170,37723,25787,28606,29562,30136,36948,21846,22349,25018,25812,26311,28129,28251,28525,28601,30192,32835,33213,34113,35203,35527,35674,37663,27795,30035,31572,36367,36957,21776,22530,22616,24162,25095,25758,26848,30070,31958,34739,40680,20195,22408,22382,22823,23565,23729,24118,24453,25140,25825,29619,33274,34955,36024,38538,40667,23429,24503,24755,20498,20992,21040,22294,22581,22615,23566,23648,23798,23947,24230,24466,24764,25361,25481,25623,26691,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,26873,27330,28120,28193,28372,28644,29182,30428,30585,31153,31291,33796,35241,36077,36339,36424,36867,36884,36947,37117,37709,38518,38876,27602,28678,29272,29346,29544,30563,31167,31716,32411,35712,22697,24775,25958,26109,26302,27788,28958,29129,35930,38931,20077,31361,20189,20908,20941,21205,21516,24999,26481,26704,26847,27934,28540,30140,30643,31461,33012,33891,37509,20828,26007,26460,26515,30168,31431,33651,63834,35910,36887,38957,23663,33216,33434,36929,36975,37389,24471,23965,27225,29128,30331,31561,34276,35588,37159,39472,21895,25078,63835,30313,32645,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,34367,34746,35064,37007,63836,27931,28889,29662,32097,33853,63837,37226,39409,63838,20098,21365,27396,27410,28734,29211,34349,40478,21068,36771,23888,25829,25900,27414,28651,31811,32412,34253,35172,35261,25289,33240,34847,24266,26391,28010,29436,29701,29807,34690,37086,20358,23821,24480,33802,20919,25504,30053,20142,20486,20841,20937,26753,27153,31918,31921,31975,33391,35538,36635,37327,20406,20791,21237,21570,24300,24942,25150,26053,27354,28670,31018,34268,34851,38317,39522,39530,40599,40654,21147,26310,27511,28701,31019,36706,38722,24976,25088,25891,28451,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,29001,29833,32244,32879,34030,36646,36899,37706,20925,21015,21155,27916,28872,35010,24265,25986,27566,28610,31806,29557,20196,20278,22265,63839,23738,23994,24604,29618,31533,32666,32718,32838,36894,37428,38646,38728,38936,40801,20363,28583,31150,37300,38583,21214,63840,25736,25796,27347,28510,28696,29200,30439,32769,34310,34396,36335,36613,38706,39791,40442,40565,30860,31103,32160,33737,37636,40575,40595,35542,22751,24324,26407,28711,29903,31840,32894,20769,28712,29282,30922,36034,36058,36084,38647,20102,20698,23534,24278,26009,29134,30274,30637,32842,34044,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,36988,39719,40845,22744,23105,23650,27155,28122,28431,30267,32047,32311,34078,35128,37860,38475,21129,26066,26611,27060,27969,28316,28687,29705,29792,30041,30244,30827,35628,39006,20845,25134,38520,20374,20523,23833,28138,32184,36650,24459,24900,26647,63841,38534,21202,32907,20956,20940,26974,31260,32190,33777,38517,20442,21033,21400,21519,21774,23653,24743,26446,26792,28012,29313,29432,29702,29827,63842,30178,31852,32633,32696,33673,35023,35041,37324,37328,38626,39881,21533,28542,29136,29848,34298,36522,38563,40023,40607,26519,28107,29747,33256,38678,30764,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,31435,31520,31890,25705,29802,30194,30908,30952,39340,39764,40635,23518,24149,28448,33180,33707,37e3,19975,21325,23081,24018,24398,24930,25405,26217,26364,28415,28459,28771,30622,33836,34067,34875,36627,39237,39995,21788,25273,26411,27819,33545,35178,38778,20129,22916,24536,24537,26395,32178,32596,33426,33579,33725,36638,37017,22475,22969,23186,23504,26151,26522,26757,27599,29028,32629,36023,36067,36993,39749,33032,35978,38476,39488,40613,23391,27667,29467,30450,30431,33804,20906,35219,20813,20885,21193,26825,27796,30468,30496,32191,32236,38754,40629,28357,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,34065,20901,21517,21629,26126,26269,26919,28319,30399,30609,33559,33986,34719,37225,37528,40180,34946,20398,20882,21215,22982,24125,24917,25720,25721,26286,26576,27169,27597,27611,29279,29281,29761,30520,30683,32791,33468,33541,35584,35624,35980,26408,27792,29287,30446,30566,31302,40361,27519,27794,22818,26406,33945,21359,22675,22937,24287,25551,26164,26483,28218,29483,31447,33495,37672,21209,24043,25006,25035,25098,25287,25771,26080,26969,27494,27595,28961,29687,30045,32326,33310,33538,34154,35491,36031,38695,40289,22696,40664,20497,21006,21563,21839,25991,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,27766,32010,32011,32862,34442,38272,38639,21247,27797,29289,21619,23194,23614,23883,24396,24494,26410,26806,26979,28220,28228,30473,31859,32654,34183,35598,36855,38753,40692,23735,24758,24845,25003,25935,26107,26108,27665,27887,29599,29641,32225,38292,23494,34588,35600,21085,21338,25293,25615,25778,26420,27192,27850,29632,29854,31636,31893,32283,33162,33334,34180,36843,38649,39361,20276,21322,21453,21467,25292,25644,25856,26001,27075,27886,28504,29677,30036,30242,30436,30460,30928,30971,31020,32070,33324,34784,36820,38930,39151,21187,25300,25765,28196,28497,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,30332,36299,37297,37474,39662,39747,20515,20621,22346,22952,23592,24135,24439,25151,25918,26041,26049,26121,26507,27036,28354,30917,32033,32938,33152,33323,33459,33953,34444,35370,35607,37030,38450,40848,20493,20467,63843,22521,24472,25308,25490,26479,28227,28953,30403,32972,32986,35060,35061,35097,36064,36649,37197,38506,20271,20336,24091,26575,26658,30333,30334,39748,24161,27146,29033,29140,30058,63844,32321,34115,34281,39132,20240,31567,32624,38309,20961,24070,26805,27710,27726,27867,29359,31684,33539,27861,29754,20731,21128,22721,25816,27287,29863,30294,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,30887,34327,38370,38713,63845,21342,24321,35722,36776,36783,37002,21029,30629,40009,40712,19993,20482,20853,23643,24183,26142,26170,26564,26821,28851,29953,30149,31177,31453,36647,39200,39432,20445,22561,22577,23542,26222,27493,27921,28282,28541,29668,29995,33769,35036,35091,35676,36628,20239,20693,21264,21340,23443,24489,26381,31119,33145,33583,34068,35079,35206,36665,36667,39333,39954,26412,20086,20472,22857,23553,23791,23792,25447,26834,28925,29090,29739,32299,34028,34562,36898,37586,40179,19981,20184,20463,20613,21078,21103,21542,21648,22496,22827,23142,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,23386,23413,23500,24220,63846,25206,25975,26023,28014,28325,29238,31526,31807,32566,33104,33105,33178,33344,33433,33705,35331,36e3,36070,36091,36212,36282,37096,37340,38428,38468,39385,40167,21271,20998,21545,22132,22707,22868,22894,24575,24996,25198,26128,27774,28954,30406,31881,31966,32027,33452,36033,38640,63847,20315,24343,24447,25282,23849,26379,26842,30844,32323,40300,19989,20633,21269,21290,21329,22915,23138,24199,24754,24970,25161,25209,26e3,26503,27047,27604,27606,27607,27608,27832,63848,29749,30202,30738,30865,31189,31192,31875,32203,32737,32933,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,33086,33218,33778,34586,35048,35513,35692,36027,37145,38750,39131,40763,22188,23338,24428,25996,27315,27567,27996,28657,28693,29277,29613,36007,36051,38971,24977,27703,32856,39425,20045,20107,20123,20181,20282,20284,20351,20447,20735,21490,21496,21766,21987,22235,22763,22882,23057,23531,23546,23556,24051,24107,24473,24605,25448,26012,26031,26614,26619,26797,27515,27801,27863,28195,28681,29509,30722,31038,31040,31072,31169,31721,32023,32114,32902,33293,33678,34001,34503,35039,35408,35422,35613,36060,36198,36781,37034,39164,39391,40605,21066,63849,26388,63850,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,20632,21034,23665,25955,27733,29642,29987,30109,31639,33948,37240,38704,20087,25746,27578,29022,34217,19977,63851,26441,26862,28183,33439,34072,34923,25591,28545,37394,39087,19978,20663,20687,20767,21830,21930,22039,23360,23577,23776,24120,24202,24224,24258,24819,26705,27233,28248,29245,29248,29376,30456,31077,31665,32724,35059,35316,35443,35937,36062,38684,22622,29885,36093,21959,63852,31329,32034,33394,29298,29983,29989,63853,31513,22661,22779,23996,24207,24246,24464,24661,25234,25471,25933,26257,26329,26360,26646,26866,29312,29790,31598,32110,32214,32626,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,32997,33298,34223,35199,35475,36893,37604,40653,40736,22805,22893,24109,24796,26132,26227,26512,27728,28101,28511,30707,30889,33990,37323,37675,20185,20682,20808,21892,23307,23459,25159,25982,26059,28210,29053,29697,29764,29831,29887,30316,31146,32218,32341,32680,33146,33203,33337,34330,34796,35445,36323,36984,37521,37925,39245,39854,21352,23633,26964,27844,27945,28203,33292,34203,35131,35373,35498,38634,40807,21089,26297,27570,32406,34814,36109,38275,38493,25885,28041,29166,63854,22478,22995,23468,24615,24826,25104,26143,26207,29481,29689,30427,30465,31596,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,32854,32882,33125,35488,37266,19990,21218,27506,27927,31237,31545,32048,63855,36016,21484,22063,22609,23477,23567,23569,24034,25152,25475,25620,26157,26803,27836,28040,28335,28703,28836,29138,29990,30095,30094,30233,31505,31712,31787,32032,32057,34092,34157,34311,35380,36877,36961,37045,37559,38902,39479,20439,23660,26463,28049,31903,32396,35606,36118,36895,23403,24061,25613,33984,36956,39137,29575,23435,24730,26494,28126,35359,35494,36865,38924,21047,63856,28753,30862,37782,34928,37335,20462,21463,22013,22234,22402,22781,23234,23432,23723,23744,24101,24833,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,25101,25163,25480,25628,25910,25976,27193,27530,27700,27929,28465,29159,29417,29560,29703,29874,30246,30561,31168,31319,31466,31929,32143,32172,32353,32670,33065,33585,33936,34010,34282,34966,35504,35728,36664,36930,36995,37228,37526,37561,38539,38567,38568,38614,38656,38920,39318,39635,39706,21460,22654,22809,23408,23487,28113,28506,29087,29729,29881,32901,33789,24033,24455,24490,24642,26092,26642,26991,27219,27529,27957,28147,29667,30462,30636,31565,32020,33059,33308,33600,34036,34147,35426,35524,37255,37662,38918,39348,25100,34899,36848,37477,23815,23847,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,23913,29791,33181,34664,28629,25342,32722,35126,35186,19998,20056,20711,21213,21319,25215,26119,32361,34821,38494,20365,21273,22070,22987,23204,23608,23630,23629,24066,24337,24643,26045,26159,26178,26558,26612,29468,30690,31034,32709,33940,33997,35222,35430,35433,35553,35925,35962,22516,23508,24335,24687,25325,26893,27542,28252,29060,31698,34645,35672,36606,39135,39166,20280,20353,20449,21627,23072,23480,24892,26032,26216,29180,30003,31070,32051,33102,33251,33688,34218,34254,34563,35338,36523,36763,63857,36805,22833,23460,23526,24713,23529,23563,24515,27777,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,63858,28145,28683,29978,33455,35574,20160,21313,63859,38617,27663,20126,20420,20818,21854,23077,23784,25105,29273,33469,33706,34558,34905,35357,38463,38597,39187,40201,40285,22538,23731,23997,24132,24801,24853,25569,27138,28197,37122,37716,38990,39952,40823,23433,23736,25353,26191,26696,30524,38593,38797,38996,39839,26017,35585,36555,38332,21813,23721,24022,24245,26263,30284,33780,38343,22739,25276,29390,40232,20208,22830,24591,26171,27523,31207,40230,21395,21696,22467,23830,24859,26326,28079,30861,33406,38552,38724,21380,25212,25494,28082,32266,33099,38989,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,27387,32588,40367,40474,20063,20539,20918,22812,24825,25590,26928,29242,32822,63860,37326,24369,63861,63862,32004,33509,33903,33979,34277,36493,63863,20335,63864,63865,22756,23363,24665,25562,25880,25965,26264,63866,26954,27171,27915,28673,29036,30162,30221,31155,31344,63867,32650,63868,35140,63869,35731,37312,38525,63870,39178,22276,24481,26044,28417,30208,31142,35486,39341,39770,40812,20740,25014,25233,27277,33222,20547,22576,24422,28937,35328,35578,23420,34326,20474,20796,22196,22852,25513,28153,23978,26989,20870,20104,20313,63871,63872,63873,22914,63874,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,63875,27487,27741,63876,29877,30998,63877,33287,33349,33593,36671,36701,63878,39192,63879,63880,63881,20134,63882,22495,24441,26131,63883,63884,30123,32377,35695,63885,36870,39515,22181,22567,23032,23071,23476,63886,24310,63887,63888,25424,25403,63889,26941,27783,27839,28046,28051,28149,28436,63890,28895,28982,29017,63891,29123,29141,63892,30799,30831,63893,31605,32227,63894,32303,63895,34893,36575,63896,63897,63898,37467,63899,40182,63900,63901,63902,24709,28037,63903,29105,63904,63905,38321,21421,63906,63907,63908,26579,63909,28814,28976,29744,33398,33490,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,63910,38331,39653,40573,26308,63911,29121,33865,63912,63913,22603,63914,63915,23992,24433,63916,26144,26254,27001,27054,27704,27891,28214,28481,28634,28699,28719,29008,29151,29552,63917,29787,63918,29908,30408,31310,32403,63919,63920,33521,35424,36814,63921,37704,63922,38681,63923,63924,20034,20522,63925,21e3,21473,26355,27757,28618,29450,30591,31330,33454,34269,34306,63926,35028,35427,35709,35947,63927,37555,63928,38675,38928,20116,20237,20425,20658,21320,21566,21555,21978,22626,22714,22887,23067,23524,24735,63929,25034,25942,26111,26212,26791,27738,28595,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,28879,29100,29522,31613,34568,35492,39986,40711,23627,27779,29508,29577,37434,28331,29797,30239,31337,32277,34314,20800,22725,25793,29934,29973,30320,32705,37013,38605,39252,28198,29926,31401,31402,33253,34521,34680,35355,23113,23436,23451,26785,26880,28003,29609,29715,29740,30871,32233,32747,33048,33109,33694,35916,38446,38929,26352,24448,26106,26505,27754,29579,20525,23043,27498,30702,22806,23916,24013,29477,30031,63930,63931,20709,20985,22575,22829,22934,23002,23525,63932,63933,23970,25303,25622,25747,25854,63934,26332,63935,27208,63936,29183,29796,63937,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,31368,31407,32327,32350,32768,33136,63938,34799,35201,35616,36953,63939,36992,39250,24958,27442,28020,32287,35109,36785,20433,20653,20887,21191,22471,22665,23481,24248,24898,27029,28044,28263,28342,29076,29794,29992,29996,32883,33592,33993,36362,37780,37854,63940,20110,20305,20598,20778,21448,21451,21491,23431,23507,23588,24858,24962,26100,29275,29591,29760,30402,31056,31121,31161,32006,32701,33419,34261,34398,36802,36935,37109,37354,38533,38632,38633,21206,24423,26093,26161,26671,29020,31286,37057,38922,20113,63941,27218,27550,28560,29065,32792,33464,34131,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,36939,38549,38642,38907,34074,39729,20112,29066,38596,20803,21407,21729,22291,22290,22435,23195,23236,23491,24616,24895,25588,27781,27961,28274,28304,29232,29503,29783,33489,34945,36677,36960,63942,38498,39e3,40219,26376,36234,37470,20301,20553,20702,21361,22285,22996,23041,23561,24944,26256,28205,29234,29771,32239,32963,33806,33894,34111,34655,34907,35096,35586,36949,38859,39759,20083,20369,20754,20842,63943,21807,21929,23418,23461,24188,24189,24254,24736,24799,24840,24841,25540,25912,26377,63944,26580,26586,63945,26977,26978,27833,27943,63946,28216,63947,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,28641,29494,29495,63948,29788,30001,63949,30290,63950,63951,32173,33278,33848,35029,35480,35547,35565,36400,36418,36938,36926,36986,37193,37321,37742,63952,63953,22537,63954,27603,32905,32946,63955,63956,20801,22891,23609,63957,63958,28516,29607,32996,36103,63959,37399,38287,63960,63961,63962,63963,32895,25102,28700,32104,34701,63964,22432,24681,24903,27575,35518,37504,38577,20057,21535,28139,34093,38512,38899,39150,25558,27875,37009,20957,25033,33210,40441,20381,20506,20736,23452,24847,25087,25836,26885,27589,30097,30691,32681,33380,34191,34811,34915,35516,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,35696,37291,20108,20197,20234,63965,63966,22839,23016,63967,24050,24347,24411,24609,63968,63969,63970,63971,29246,29669,63972,30064,30157,63973,31227,63974,32780,32819,32900,33505,33617,63975,63976,36029,36019,36999,63977,63978,39156,39180,63979,63980,28727,30410,32714,32716,32764,35610,20154,20161,20995,21360,63981,21693,22240,23035,23493,24341,24525,28270,63982,63983,32106,33589,63984,34451,35469,63985,38765,38775,63986,63987,19968,20314,20350,22777,26085,28322,36920,37808,39353,20219,22764,22922,23001,24641,63988,63989,31252,63990,33615,36035,20837,21316,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,63991,63992,63993,20173,21097,23381,33471,20180,21050,21672,22985,23039,23376,23383,23388,24675,24904,28363,28825,29038,29574,29943,30133,30913,32043,32773,33258,33576,34071,34249,35566,36039,38604,20316,21242,22204,26027,26152,28796,28856,29237,32189,33421,37196,38592,40306,23409,26855,27544,28538,30430,23697,26283,28507,31668,31786,34870,38620,19976,20183,21280,22580,22715,22767,22892,23559,24115,24196,24373,25484,26290,26454,27167,27299,27404,28479,29254,63994,29520,29835,31456,31911,33144,33247,33255,33674,33900,34083,34196,34255,35037,36115,37292,38263,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,38556,20877,21705,22312,23472,25165,26448,26685,26771,28221,28371,28797,32289,35009,36001,36617,40779,40782,29229,31631,35533,37658,20295,20302,20786,21632,22992,24213,25269,26485,26990,27159,27822,28186,29401,29482,30141,31672,32053,33511,33785,33879,34295,35419,36015,36487,36889,37048,38606,40799,21219,21514,23265,23490,25688,25973,28404,29380,63995,30340,31309,31515,31821,32318,32735,33659,35627,36042,36196,36321,36447,36842,36857,36969,37841,20291,20346,20659,20840,20856,21069,21098,22625,22652,22880,23560,23637,24283,24731,25136,26643,27583,27656,28593,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,29006,29728,3e4,30008,30033,30322,31564,31627,31661,31686,32399,35438,36670,36681,37439,37523,37666,37931,38651,39002,39019,39198,20999,25130,25240,27993,30308,31434,31680,32118,21344,23742,24215,28472,28857,31896,38673,39822,40670,25509,25722,34678,19969,20117,20141,20572,20597,21576,22979,23450,24128,24237,24311,24449,24773,25402,25919,25972,26060,26230,26232,26622,26984,27273,27491,27712,28096,28136,28191,28254,28702,28833,29582,29693,30010,30555,30855,31118,31243,31357,31934,32142,33351,35330,35562,35998,37165,37194,37336,37478,37580,37664,38662,38742,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,38748,38914,40718,21046,21137,21884,22564,24093,24351,24716,25552,26799,28639,31085,31532,33229,34234,35069,35576,36420,37261,38500,38555,38717,38988,40778,20430,20806,20939,21161,22066,24340,24427,25514,25805,26089,26177,26362,26361,26397,26781,26839,27133,28437,28526,29031,29157,29226,29866,30522,31062,31066,31199,31264,31381,31895,31967,32068,32368,32903,34299,34468,35412,35519,36249,36481,36896,36973,37347,38459,38613,40165,26063,31751,36275,37827,23384,23562,21330,25305,29469,20519,23447,24478,24752,24939,26837,28121,29742,31278,32066,32156,32305,33131,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,36394,36405,37758,37912,20304,22352,24038,24231,25387,32618,20027,20303,20367,20570,23005,32964,21610,21608,22014,22863,23449,24030,24282,26205,26417,26609,26666,27880,27954,28234,28557,28855,29664,30087,31820,32002,32044,32162,33311,34523,35387,35461,36208,36490,36659,36913,37198,37202,37956,39376,31481,31909,20426,20737,20934,22472,23535,23803,26201,27197,27994,28310,28652,28940,30063,31459,34850,36897,36981,38603,39423,33537,20013,20210,34886,37325,21373,27355,26987,27713,33914,22686,24974,26366,25327,28893,29969,30151,32338,33976,35657,36104,20043,21482,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,21675,22320,22336,24535,25345,25351,25711,25903,26088,26234,26525,26547,27490,27744,27802,28460,30693,30757,31049,31063,32025,32930,33026,33267,33437,33463,34584,35468,63996,36100,36286,36978,30452,31257,31287,32340,32887,21767,21972,22645,25391,25634,26185,26187,26733,27035,27524,27941,28337,29645,29800,29857,30043,30137,30433,30494,30603,31206,32265,32285,33275,34095,34967,35386,36049,36587,36784,36914,37805,38499,38515,38663,20356,21489,23018,23241,24089,26702,29894,30142,31209,31378,33187,34541,36074,36300,36845,26015,26389,63997,22519,28503,32221,36655,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,37878,38598,24501,25074,28548,19988,20376,20511,21449,21983,23919,24046,27425,27492,30923,31642,63998,36425,36554,36974,25417,25662,30528,31364,37679,38015,40810,25776,28591,29158,29864,29914,31428,31762,32386,31922,32408,35738,36106,38013,39184,39244,21049,23519,25830,26413,32046,20717,21443,22649,24920,24921,25082,26028,31449,35730,35734,20489,20513,21109,21809,23100,24288,24432,24884,25950,26124,26166,26274,27085,28356,28466,29462,30241,31379,33081,33369,33750,33980,20661,22512,23488,23528,24425,25505,30758,32181,33756,34081,37319,37365,20874,26613,31574,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,36012,20932,22971,24765,34389,20508,63999,21076,23610,24957,25114,25299,25842,26021,28364,30240,33034,36448,38495,38587,20191,21315,21912,22825,24029,25797,27849,28154,29588,31359,33307,34214,36068,36368,36983,37351,38369,38433,38854,20984,21746,21894,24505,25764,28552,32180,36639,36685,37941,20681,23574,27838,28155,29979,30651,31805,31844,35449,35522,22558,22974,24086,25463,29266,30090,30571,35548,36028,36626,24307,26228,28152,32893,33729,35531,38737,39894,64e3,21059,26367,28053,28399,32224,35558,36910,36958,39636,21021,21119,21736,24980,25220,25307,26786,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,26898,26970,27189,28818,28966,30813,30977,30990,31186,31245,32918,33400,33493,33609,34121,35970,36229,37218,37259,37294,20419,22225,29165,30679,34560,35320,23544,24534,26449,37032,21474,22618,23541,24740,24961,25696,32317,32880,34085,37507,25774,20652,23828,26368,22684,25277,25512,26894,27e3,27166,28267,30394,31179,33467,33833,35535,36264,36861,37138,37195,37276,37648,37656,37786,38619,39478,39949,19985,30044,31069,31482,31569,31689,32302,33988,36441,36468,36600,36880,26149,26943,29763,20986,26414,40668,20805,24544,27798,34802,34909,34935,24756,33205,33795,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,36101,21462,21561,22068,23094,23601,28810,32736,32858,33030,33261,36259,37257,39519,40434,20596,20164,21408,24827,28204,23652,20360,20516,21988,23769,24159,24677,26772,27835,28100,29118,30164,30196,30305,31258,31305,32199,32251,32622,33268,34473,36636,38601,39347,40786,21063,21189,39149,35242,19971,26578,28422,20405,23522,26517,27784,28024,29723,30759,37341,37756,34756,31204,31281,24555,20182,21668,21822,22702,22949,24816,25171,25302,26422,26965,33333,38464,39345,39389,20524,21331,21828,22396,64001,25176,64002,25826,26219,26589,28609,28655,29730,29752,35351,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,37944,21585,22022,22374,24392,24986,27470,28760,28845,32187,35477,22890,33067,25506,30472,32829,36010,22612,25645,27067,23445,24081,28271,64003,34153,20812,21488,22826,24608,24907,27526,27760,27888,31518,32974,33492,36294,37040,39089,64004,25799,28580,25745,25860,20814,21520,22303,35342,24927,26742,64005,30171,31570,32113,36890,22534,27084,33151,35114,36864,38969,20600,22871,22956,25237,36879,39722,24925,29305,38358,22369,23110,24052,25226,25773,25850,26487,27874,27966,29228,29750,30772,32631,33453,36315,38935,21028,22338,26495,29256,29923,36009,36774,37393,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,38442,20843,21485,25420,20329,21764,24726,25943,27803,28031,29260,29437,31255,35207,35997,24429,28558,28921,33192,24846,20415,20559,25153,29255,31687,32232,32745,36941,38829,39449,36022,22378,24179,26544,33805,35413,21536,23318,24163,24290,24330,25987,32954,34109,38281,38491,20296,21253,21261,21263,21638,21754,22275,24067,24598,25243,25265,25429,64006,27873,28006,30129,30770,32990,33071,33502,33889,33970,34957,35090,36875,37610,39165,39825,24133,26292,26333,28689,29190,64007,20469,21117,24426,24915,26451,27161,28418,29922,31080,34920,35961,39111,39108,39491,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,21697,31263,26963,35575,35914,39080,39342,24444,25259,30130,30382,34987,36991,38466,21305,24380,24517,27852,29644,30050,30091,31558,33534,39325,20047,36924,19979,20309,21414,22799,24264,26160,27827,29781,33655,34662,36032,36944,38686,39957,22737,23416,34384,35604,40372,23506,24680,24717,26097,27735,28450,28579,28698,32597,32752,38289,38290,38480,38867,21106,36676,20989,21547,21688,21859,21898,27323,28085,32216,33382,37532,38519,40569,21512,21704,30418,34532,38308,38356,38492,20130,20233,23022,23270,24055,24658,25239,26477,26689,27782,28207,32568,32923,33322,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,64008,64009,38917,20133,20565,21683,22419,22874,23401,23475,25032,26999,28023,28707,34809,35299,35442,35559,36994,39405,39608,21182,26680,20502,24184,26447,33607,34892,20139,21521,22190,29670,37141,38911,39177,39255,39321,22099,22687,34395,35377,25010,27382,29563,36562,27463,38570,39511,22869,29184,36203,38761,20436,23796,24358,25080,26203,27883,28843,29572,29625,29694,30505,30541,32067,32098,32291,33335,34898,64010,36066,37449,39023,23377,31348,34880,38913,23244,20448,21332,22846,23805,25406,28025,29433,33029,33031,33698,37583,38960,20136,20804,21009,22411,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,24418,27842,28366,28677,28752,28847,29074,29673,29801,33610,34722,34913,36872,37026,37795,39336,20846,24407,24800,24935,26291,34137,36426,37295,38795,20046,20114,21628,22741,22778,22909,23733,24359,25142,25160,26122,26215,27627,28009,28111,28246,28408,28564,28640,28649,28765,29392,29733,29786,29920,30355,31068,31946,32286,32993,33446,33899,33983,34382,34399,34676,35703,35946,37804,38912,39013,24785,25110,37239,23130,26127,28151,28222,29759,39746,24573,24794,31503,21700,24344,27742,27859,27946,28888,32005,34425,35340,40251,21270,21644,23301,27194,28779,30069,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,31117,31166,33457,33775,35441,35649,36008,38772,64011,25844,25899,30906,30907,31339,20024,21914,22864,23462,24187,24739,25563,27489,26213,26707,28185,29029,29872,32008,36996,39529,39973,27963,28369,29502,35905,38346,20976,24140,24488,24653,24822,24880,24908,26179,26180,27045,27841,28255,28361,28514,29004,29852,30343,31681,31783,33618,34647,36945,38541,40643,21295,22238,24315,24458,24674,24724,25079,26214,26371,27292,28142,28590,28784,29546,32362,33214,33588,34516,35496,36036,21123,29554,23446,27243,37892,21742,22150,23389,25928,25989,26313,26783,28045,28102,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,29243,32948,37237,39501,20399,20505,21402,21518,21564,21897,21957,24127,24460,26429,29030,29661,36869,21211,21235,22628,22734,28932,29071,29179,34224,35347,26248,34216,21927,26244,29002,33841,21321,21913,27585,24409,24509,25582,26249,28999,35569,36637,40638,20241,25658,28875,30054,34407,24676,35662,40440,20807,20982,21256,27958,33016,40657,26133,27427,28824,30165,21507,23673,32007,35350,27424,27453,27462,21560,24688,27965,32725,33288,20694,20958,21916,22123,22221,23020,23305,24076,24985,24984,25137,26206,26342,29081,29113,29114,29351,31143,31232,32690,35440,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],gb18030:[19970,19972,19973,19974,19983,19986,19991,19999,2e4,20001,20003,20006,20009,20014,20015,20017,20019,20021,20023,20028,20032,20033,20034,20036,20038,20042,20049,20053,20055,20058,20059,20066,20067,20068,20069,20071,20072,20074,20075,20076,20077,20078,20079,20082,20084,20085,20086,20087,20088,20089,20090,20091,20092,20093,20095,20096,20097,20098,20099,20100,20101,20103,20106,20112,20118,20119,20121,20124,20125,20126,20131,20138,20143,20144,20145,20148,20150,20151,20152,20153,20156,20157,20158,20168,20172,20175,20176,20178,20186,20187,20188,20192,20194,20198,20199,20201,20205,20206,20207,20209,20212,20216,20217,20218,20220,20222,20224,20226,20227,20228,20229,20230,20231,20232,20235,20236,20242,20243,20244,20245,20246,20252,20253,20257,20259,20264,20265,20268,20269,20270,20273,20275,20277,20279,20281,20283,20286,20287,20288,20289,20290,20292,20293,20295,20296,20297,20298,20299,20300,20306,20308,20310,20321,20322,20326,20328,20330,20331,20333,20334,20337,20338,20341,20343,20344,20345,20346,20349,20352,20353,20354,20357,20358,20359,20362,20364,20366,20368,20370,20371,20373,20374,20376,20377,20378,20380,20382,20383,20385,20386,20388,20395,20397,20400,20401,20402,20403,20404,20406,20407,20408,20409,20410,20411,20412,20413,20414,20416,20417,20418,20422,20423,20424,20425,20427,20428,20429,20434,20435,20436,20437,20438,20441,20443,20448,20450,20452,20453,20455,20459,20460,20464,20466,20468,20469,20470,20471,20473,20475,20476,20477,20479,20480,20481,20482,20483,20484,20485,20486,20487,20488,20489,20490,20491,20494,20496,20497,20499,20501,20502,20503,20507,20509,20510,20512,20514,20515,20516,20519,20523,20527,20528,20529,20530,20531,20532,20533,20534,20535,20536,20537,20539,20541,20543,20544,20545,20546,20548,20549,20550,20553,20554,20555,20557,20560,20561,20562,20563,20564,20566,20567,20568,20569,20571,20573,20574,20575,20576,20577,20578,20579,20580,20582,20583,20584,20585,20586,20587,20589,20590,20591,20592,20593,20594,20595,20596,20597,20600,20601,20602,20604,20605,20609,20610,20611,20612,20614,20615,20617,20618,20619,20620,20622,20623,20624,20625,20626,20627,20628,20629,20630,20631,20632,20633,20634,20635,20636,20637,20638,20639,20640,20641,20642,20644,20646,20650,20651,20653,20654,20655,20656,20657,20659,20660,20661,20662,20663,20664,20665,20668,20669,20670,20671,20672,20673,20674,20675,20676,20677,20678,20679,20680,20681,20682,20683,20684,20685,20686,20688,20689,20690,20691,20692,20693,20695,20696,20697,20699,20700,20701,20702,20703,20704,20705,20706,20707,20708,20709,20712,20713,20714,20715,20719,20720,20721,20722,20724,20726,20727,20728,20729,20730,20732,20733,20734,20735,20736,20737,20738,20739,20740,20741,20744,20745,20746,20748,20749,20750,20751,20752,20753,20755,20756,20757,20758,20759,20760,20761,20762,20763,20764,20765,20766,20767,20768,20770,20771,20772,20773,20774,20775,20776,20777,20778,20779,20780,20781,20782,20783,20784,20785,20786,20787,20788,20789,20790,20791,20792,20793,20794,20795,20796,20797,20798,20802,20807,20810,20812,20814,20815,20816,20818,20819,20823,20824,20825,20827,20829,20830,20831,20832,20833,20835,20836,20838,20839,20841,20842,20847,20850,20858,20862,20863,20867,20868,20870,20871,20874,20875,20878,20879,20880,20881,20883,20884,20888,20890,20893,20894,20895,20897,20899,20902,20903,20904,20905,20906,20909,20910,20916,20920,20921,20922,20926,20927,20929,20930,20931,20933,20936,20938,20941,20942,20944,20946,20947,20948,20949,20950,20951,20952,20953,20954,20956,20958,20959,20962,20963,20965,20966,20967,20968,20969,20970,20972,20974,20977,20978,20980,20983,20990,20996,20997,21001,21003,21004,21007,21008,21011,21012,21013,21020,21022,21023,21025,21026,21027,21029,21030,21031,21034,21036,21039,21041,21042,21044,21045,21052,21054,21060,21061,21062,21063,21064,21065,21067,21070,21071,21074,21075,21077,21079,21080,21081,21082,21083,21085,21087,21088,21090,21091,21092,21094,21096,21099,21100,21101,21102,21104,21105,21107,21108,21109,21110,21111,21112,21113,21114,21115,21116,21118,21120,21123,21124,21125,21126,21127,21129,21130,21131,21132,21133,21134,21135,21137,21138,21140,21141,21142,21143,21144,21145,21146,21148,21156,21157,21158,21159,21166,21167,21168,21172,21173,21174,21175,21176,21177,21178,21179,21180,21181,21184,21185,21186,21188,21189,21190,21192,21194,21196,21197,21198,21199,21201,21203,21204,21205,21207,21209,21210,21211,21212,21213,21214,21216,21217,21218,21219,21221,21222,21223,21224,21225,21226,21227,21228,21229,21230,21231,21233,21234,21235,21236,21237,21238,21239,21240,21243,21244,21245,21249,21250,21251,21252,21255,21257,21258,21259,21260,21262,21265,21266,21267,21268,21272,21275,21276,21278,21279,21282,21284,21285,21287,21288,21289,21291,21292,21293,21295,21296,21297,21298,21299,21300,21301,21302,21303,21304,21308,21309,21312,21314,21316,21318,21323,21324,21325,21328,21332,21336,21337,21339,21341,21349,21352,21354,21356,21357,21362,21366,21369,21371,21372,21373,21374,21376,21377,21379,21383,21384,21386,21390,21391,21392,21393,21394,21395,21396,21398,21399,21401,21403,21404,21406,21408,21409,21412,21415,21418,21419,21420,21421,21423,21424,21425,21426,21427,21428,21429,21431,21432,21433,21434,21436,21437,21438,21440,21443,21444,21445,21446,21447,21454,21455,21456,21458,21459,21461,21466,21468,21469,21470,21473,21474,21479,21492,21498,21502,21503,21504,21506,21509,21511,21515,21524,21528,21529,21530,21532,21538,21540,21541,21546,21552,21555,21558,21559,21562,21565,21567,21569,21570,21572,21573,21575,21577,21580,21581,21582,21583,21585,21594,21597,21598,21599,21600,21601,21603,21605,21607,21609,21610,21611,21612,21613,21614,21615,21616,21620,21625,21626,21630,21631,21633,21635,21637,21639,21640,21641,21642,21645,21649,21651,21655,21656,21660,21662,21663,21664,21665,21666,21669,21678,21680,21682,21685,21686,21687,21689,21690,21692,21694,21699,21701,21706,21707,21718,21720,21723,21728,21729,21730,21731,21732,21739,21740,21743,21744,21745,21748,21749,21750,21751,21752,21753,21755,21758,21760,21762,21763,21764,21765,21768,21770,21771,21772,21773,21774,21778,21779,21781,21782,21783,21784,21785,21786,21788,21789,21790,21791,21793,21797,21798,21800,21801,21803,21805,21810,21812,21813,21814,21816,21817,21818,21819,21821,21824,21826,21829,21831,21832,21835,21836,21837,21838,21839,21841,21842,21843,21844,21847,21848,21849,21850,21851,21853,21854,21855,21856,21858,21859,21864,21865,21867,21871,21872,21873,21874,21875,21876,21881,21882,21885,21887,21893,21894,21900,21901,21902,21904,21906,21907,21909,21910,21911,21914,21915,21918,21920,21921,21922,21923,21924,21925,21926,21928,21929,21930,21931,21932,21933,21934,21935,21936,21938,21940,21942,21944,21946,21948,21951,21952,21953,21954,21955,21958,21959,21960,21962,21963,21966,21967,21968,21973,21975,21976,21977,21978,21979,21982,21984,21986,21991,21993,21997,21998,22e3,22001,22004,22006,22008,22009,22010,22011,22012,22015,22018,22019,22020,22021,22022,22023,22026,22027,22029,22032,22033,22034,22035,22036,22037,22038,22039,22041,22042,22044,22045,22048,22049,22050,22053,22054,22056,22057,22058,22059,22062,22063,22064,22067,22069,22071,22072,22074,22076,22077,22078,22080,22081,22082,22083,22084,22085,22086,22087,22088,22089,22090,22091,22095,22096,22097,22098,22099,22101,22102,22106,22107,22109,22110,22111,22112,22113,22115,22117,22118,22119,22125,22126,22127,22128,22130,22131,22132,22133,22135,22136,22137,22138,22141,22142,22143,22144,22145,22146,22147,22148,22151,22152,22153,22154,22155,22156,22157,22160,22161,22162,22164,22165,22166,22167,22168,22169,22170,22171,22172,22173,22174,22175,22176,22177,22178,22180,22181,22182,22183,22184,22185,22186,22187,22188,22189,22190,22192,22193,22194,22195,22196,22197,22198,22200,22201,22202,22203,22205,22206,22207,22208,22209,22210,22211,22212,22213,22214,22215,22216,22217,22219,22220,22221,22222,22223,22224,22225,22226,22227,22229,22230,22232,22233,22236,22243,22245,22246,22247,22248,22249,22250,22252,22254,22255,22258,22259,22262,22263,22264,22267,22268,22272,22273,22274,22277,22279,22283,22284,22285,22286,22287,22288,22289,22290,22291,22292,22293,22294,22295,22296,22297,22298,22299,22301,22302,22304,22305,22306,22308,22309,22310,22311,22315,22321,22322,22324,22325,22326,22327,22328,22332,22333,22335,22337,22339,22340,22341,22342,22344,22345,22347,22354,22355,22356,22357,22358,22360,22361,22370,22371,22373,22375,22380,22382,22384,22385,22386,22388,22389,22392,22393,22394,22397,22398,22399,22400,22401,22407,22408,22409,22410,22413,22414,22415,22416,22417,22420,22421,22422,22423,22424,22425,22426,22428,22429,22430,22431,22437,22440,22442,22444,22447,22448,22449,22451,22453,22454,22455,22457,22458,22459,22460,22461,22462,22463,22464,22465,22468,22469,22470,22471,22472,22473,22474,22476,22477,22480,22481,22483,22486,22487,22491,22492,22494,22497,22498,22499,22501,22502,22503,22504,22505,22506,22507,22508,22510,22512,22513,22514,22515,22517,22518,22519,22523,22524,22526,22527,22529,22531,22532,22533,22536,22537,22538,22540,22542,22543,22544,22546,22547,22548,22550,22551,22552,22554,22555,22556,22557,22559,22562,22563,22565,22566,22567,22568,22569,22571,22572,22573,22574,22575,22577,22578,22579,22580,22582,22583,22584,22585,22586,22587,22588,22589,22590,22591,22592,22593,22594,22595,22597,22598,22599,22600,22601,22602,22603,22606,22607,22608,22610,22611,22613,22614,22615,22617,22618,22619,22620,22621,22623,22624,22625,22626,22627,22628,22630,22631,22632,22633,22634,22637,22638,22639,22640,22641,22642,22643,22644,22645,22646,22647,22648,22649,22650,22651,22652,22653,22655,22658,22660,22662,22663,22664,22666,22667,22668,22669,22670,22671,22672,22673,22676,22677,22678,22679,22680,22683,22684,22685,22688,22689,22690,22691,22692,22693,22694,22695,22698,22699,22700,22701,22702,22703,22704,22705,22706,22707,22708,22709,22710,22711,22712,22713,22714,22715,22717,22718,22719,22720,22722,22723,22724,22726,22727,22728,22729,22730,22731,22732,22733,22734,22735,22736,22738,22739,22740,22742,22743,22744,22745,22746,22747,22748,22749,22750,22751,22752,22753,22754,22755,22757,22758,22759,22760,22761,22762,22765,22767,22769,22770,22772,22773,22775,22776,22778,22779,22780,22781,22782,22783,22784,22785,22787,22789,22790,22792,22793,22794,22795,22796,22798,22800,22801,22802,22803,22807,22808,22811,22813,22814,22816,22817,22818,22819,22822,22824,22828,22832,22834,22835,22837,22838,22843,22845,22846,22847,22848,22851,22853,22854,22858,22860,22861,22864,22866,22867,22873,22875,22876,22877,22878,22879,22881,22883,22884,22886,22887,22888,22889,22890,22891,22892,22893,22894,22895,22896,22897,22898,22901,22903,22906,22907,22908,22910,22911,22912,22917,22921,22923,22924,22926,22927,22928,22929,22932,22933,22936,22938,22939,22940,22941,22943,22944,22945,22946,22950,22951,22956,22957,22960,22961,22963,22964,22965,22966,22967,22968,22970,22972,22973,22975,22976,22977,22978,22979,22980,22981,22983,22984,22985,22988,22989,22990,22991,22997,22998,23001,23003,23006,23007,23008,23009,23010,23012,23014,23015,23017,23018,23019,23021,23022,23023,23024,23025,23026,23027,23028,23029,23030,23031,23032,23034,23036,23037,23038,23040,23042,23050,23051,23053,23054,23055,23056,23058,23060,23061,23062,23063,23065,23066,23067,23069,23070,23073,23074,23076,23078,23079,23080,23082,23083,23084,23085,23086,23087,23088,23091,23093,23095,23096,23097,23098,23099,23101,23102,23103,23105,23106,23107,23108,23109,23111,23112,23115,23116,23117,23118,23119,23120,23121,23122,23123,23124,23126,23127,23128,23129,23131,23132,23133,23134,23135,23136,23137,23139,23140,23141,23142,23144,23145,23147,23148,23149,23150,23151,23152,23153,23154,23155,23160,23161,23163,23164,23165,23166,23168,23169,23170,23171,23172,23173,23174,23175,23176,23177,23178,23179,23180,23181,23182,23183,23184,23185,23187,23188,23189,23190,23191,23192,23193,23196,23197,23198,23199,23200,23201,23202,23203,23204,23205,23206,23207,23208,23209,23211,23212,23213,23214,23215,23216,23217,23220,23222,23223,23225,23226,23227,23228,23229,23231,23232,23235,23236,23237,23238,23239,23240,23242,23243,23245,23246,23247,23248,23249,23251,23253,23255,23257,23258,23259,23261,23262,23263,23266,23268,23269,23271,23272,23274,23276,23277,23278,23279,23280,23282,23283,23284,23285,23286,23287,23288,23289,23290,23291,23292,23293,23294,23295,23296,23297,23298,23299,23300,23301,23302,23303,23304,23306,23307,23308,23309,23310,23311,23312,23313,23314,23315,23316,23317,23320,23321,23322,23323,23324,23325,23326,23327,23328,23329,23330,23331,23332,23333,23334,23335,23336,23337,23338,23339,23340,23341,23342,23343,23344,23345,23347,23349,23350,23352,23353,23354,23355,23356,23357,23358,23359,23361,23362,23363,23364,23365,23366,23367,23368,23369,23370,23371,23372,23373,23374,23375,23378,23382,23390,23392,23393,23399,23400,23403,23405,23406,23407,23410,23412,23414,23415,23416,23417,23419,23420,23422,23423,23426,23430,23434,23437,23438,23440,23441,23442,23444,23446,23455,23463,23464,23465,23468,23469,23470,23471,23473,23474,23479,23482,23483,23484,23488,23489,23491,23496,23497,23498,23499,23501,23502,23503,23505,23508,23509,23510,23511,23512,23513,23514,23515,23516,23520,23522,23523,23526,23527,23529,23530,23531,23532,23533,23535,23537,23538,23539,23540,23541,23542,23543,23549,23550,23552,23554,23555,23557,23559,23560,23563,23564,23565,23566,23568,23570,23571,23575,23577,23579,23582,23583,23584,23585,23587,23590,23592,23593,23594,23595,23597,23598,23599,23600,23602,23603,23605,23606,23607,23619,23620,23622,23623,23628,23629,23634,23635,23636,23638,23639,23640,23642,23643,23644,23645,23647,23650,23652,23655,23656,23657,23658,23659,23660,23661,23664,23666,23667,23668,23669,23670,23671,23672,23675,23676,23677,23678,23680,23683,23684,23685,23686,23687,23689,23690,23691,23694,23695,23698,23699,23701,23709,23710,23711,23712,23713,23716,23717,23718,23719,23720,23722,23726,23727,23728,23730,23732,23734,23737,23738,23739,23740,23742,23744,23746,23747,23749,23750,23751,23752,23753,23754,23756,23757,23758,23759,23760,23761,23763,23764,23765,23766,23767,23768,23770,23771,23772,23773,23774,23775,23776,23778,23779,23783,23785,23787,23788,23790,23791,23793,23794,23795,23796,23797,23798,23799,23800,23801,23802,23804,23805,23806,23807,23808,23809,23812,23813,23816,23817,23818,23819,23820,23821,23823,23824,23825,23826,23827,23829,23831,23832,23833,23834,23836,23837,23839,23840,23841,23842,23843,23845,23848,23850,23851,23852,23855,23856,23857,23858,23859,23861,23862,23863,23864,23865,23866,23867,23868,23871,23872,23873,23874,23875,23876,23877,23878,23880,23881,23885,23886,23887,23888,23889,23890,23891,23892,23893,23894,23895,23897,23898,23900,23902,23903,23904,23905,23906,23907,23908,23909,23910,23911,23912,23914,23917,23918,23920,23921,23922,23923,23925,23926,23927,23928,23929,23930,23931,23932,23933,23934,23935,23936,23937,23939,23940,23941,23942,23943,23944,23945,23946,23947,23948,23949,23950,23951,23952,23953,23954,23955,23956,23957,23958,23959,23960,23962,23963,23964,23966,23967,23968,23969,23970,23971,23972,23973,23974,23975,23976,23977,23978,23979,23980,23981,23982,23983,23984,23985,23986,23987,23988,23989,23990,23992,23993,23994,23995,23996,23997,23998,23999,24e3,24001,24002,24003,24004,24006,24007,24008,24009,24010,24011,24012,24014,24015,24016,24017,24018,24019,24020,24021,24022,24023,24024,24025,24026,24028,24031,24032,24035,24036,24042,24044,24045,24048,24053,24054,24056,24057,24058,24059,24060,24063,24064,24068,24071,24073,24074,24075,24077,24078,24082,24083,24087,24094,24095,24096,24097,24098,24099,24100,24101,24104,24105,24106,24107,24108,24111,24112,24114,24115,24116,24117,24118,24121,24122,24126,24127,24128,24129,24131,24134,24135,24136,24137,24138,24139,24141,24142,24143,24144,24145,24146,24147,24150,24151,24152,24153,24154,24156,24157,24159,24160,24163,24164,24165,24166,24167,24168,24169,24170,24171,24172,24173,24174,24175,24176,24177,24181,24183,24185,24190,24193,24194,24195,24197,24200,24201,24204,24205,24206,24210,24216,24219,24221,24225,24226,24227,24228,24232,24233,24234,24235,24236,24238,24239,24240,24241,24242,24244,24250,24251,24252,24253,24255,24256,24257,24258,24259,24260,24261,24262,24263,24264,24267,24268,24269,24270,24271,24272,24276,24277,24279,24280,24281,24282,24284,24285,24286,24287,24288,24289,24290,24291,24292,24293,24294,24295,24297,24299,24300,24301,24302,24303,24304,24305,24306,24307,24309,24312,24313,24315,24316,24317,24325,24326,24327,24329,24332,24333,24334,24336,24338,24340,24342,24345,24346,24348,24349,24350,24353,24354,24355,24356,24360,24363,24364,24366,24368,24370,24371,24372,24373,24374,24375,24376,24379,24381,24382,24383,24385,24386,24387,24388,24389,24390,24391,24392,24393,24394,24395,24396,24397,24398,24399,24401,24404,24409,24410,24411,24412,24414,24415,24416,24419,24421,24423,24424,24427,24430,24431,24434,24436,24437,24438,24440,24442,24445,24446,24447,24451,24454,24461,24462,24463,24465,24467,24468,24470,24474,24475,24477,24478,24479,24480,24482,24483,24484,24485,24486,24487,24489,24491,24492,24495,24496,24497,24498,24499,24500,24502,24504,24505,24506,24507,24510,24511,24512,24513,24514,24519,24520,24522,24523,24526,24531,24532,24533,24538,24539,24540,24542,24543,24546,24547,24549,24550,24552,24553,24556,24559,24560,24562,24563,24564,24566,24567,24569,24570,24572,24583,24584,24585,24587,24588,24592,24593,24595,24599,24600,24602,24606,24607,24610,24611,24612,24620,24621,24622,24624,24625,24626,24627,24628,24630,24631,24632,24633,24634,24637,24638,24640,24644,24645,24646,24647,24648,24649,24650,24652,24654,24655,24657,24659,24660,24662,24663,24664,24667,24668,24670,24671,24672,24673,24677,24678,24686,24689,24690,24692,24693,24695,24702,24704,24705,24706,24709,24710,24711,24712,24714,24715,24718,24719,24720,24721,24723,24725,24727,24728,24729,24732,24734,24737,24738,24740,24741,24743,24745,24746,24750,24752,24755,24757,24758,24759,24761,24762,24765,24766,24767,24768,24769,24770,24771,24772,24775,24776,24777,24780,24781,24782,24783,24784,24786,24787,24788,24790,24791,24793,24795,24798,24801,24802,24803,24804,24805,24810,24817,24818,24821,24823,24824,24827,24828,24829,24830,24831,24834,24835,24836,24837,24839,24842,24843,24844,24848,24849,24850,24851,24852,24854,24855,24856,24857,24859,24860,24861,24862,24865,24866,24869,24872,24873,24874,24876,24877,24878,24879,24880,24881,24882,24883,24884,24885,24886,24887,24888,24889,24890,24891,24892,24893,24894,24896,24897,24898,24899,24900,24901,24902,24903,24905,24907,24909,24911,24912,24914,24915,24916,24918,24919,24920,24921,24922,24923,24924,24926,24927,24928,24929,24931,24932,24933,24934,24937,24938,24939,24940,24941,24942,24943,24945,24946,24947,24948,24950,24952,24953,24954,24955,24956,24957,24958,24959,24960,24961,24962,24963,24964,24965,24966,24967,24968,24969,24970,24972,24973,24975,24976,24977,24978,24979,24981,24982,24983,24984,24985,24986,24987,24988,24990,24991,24992,24993,24994,24995,24996,24997,24998,25002,25003,25005,25006,25007,25008,25009,25010,25011,25012,25013,25014,25016,25017,25018,25019,25020,25021,25023,25024,25025,25027,25028,25029,25030,25031,25033,25036,25037,25038,25039,25040,25043,25045,25046,25047,25048,25049,25050,25051,25052,25053,25054,25055,25056,25057,25058,25059,25060,25061,25063,25064,25065,25066,25067,25068,25069,25070,25071,25072,25073,25074,25075,25076,25078,25079,25080,25081,25082,25083,25084,25085,25086,25088,25089,25090,25091,25092,25093,25095,25097,25107,25108,25113,25116,25117,25118,25120,25123,25126,25127,25128,25129,25131,25133,25135,25136,25137,25138,25141,25142,25144,25145,25146,25147,25148,25154,25156,25157,25158,25162,25167,25168,25173,25174,25175,25177,25178,25180,25181,25182,25183,25184,25185,25186,25188,25189,25192,25201,25202,25204,25205,25207,25208,25210,25211,25213,25217,25218,25219,25221,25222,25223,25224,25227,25228,25229,25230,25231,25232,25236,25241,25244,25245,25246,25251,25254,25255,25257,25258,25261,25262,25263,25264,25266,25267,25268,25270,25271,25272,25274,25278,25280,25281,25283,25291,25295,25297,25301,25309,25310,25312,25313,25316,25322,25323,25328,25330,25333,25336,25337,25338,25339,25344,25347,25348,25349,25350,25354,25355,25356,25357,25359,25360,25362,25363,25364,25365,25367,25368,25369,25372,25382,25383,25385,25388,25389,25390,25392,25393,25395,25396,25397,25398,25399,25400,25403,25404,25406,25407,25408,25409,25412,25415,25416,25418,25425,25426,25427,25428,25430,25431,25432,25433,25434,25435,25436,25437,25440,25444,25445,25446,25448,25450,25451,25452,25455,25456,25458,25459,25460,25461,25464,25465,25468,25469,25470,25471,25473,25475,25476,25477,25478,25483,25485,25489,25491,25492,25493,25495,25497,25498,25499,25500,25501,25502,25503,25505,25508,25510,25515,25519,25521,25522,25525,25526,25529,25531,25533,25535,25536,25537,25538,25539,25541,25543,25544,25546,25547,25548,25553,25555,25556,25557,25559,25560,25561,25562,25563,25564,25565,25567,25570,25572,25573,25574,25575,25576,25579,25580,25582,25583,25584,25585,25587,25589,25591,25593,25594,25595,25596,25598,25603,25604,25606,25607,25608,25609,25610,25613,25614,25617,25618,25621,25622,25623,25624,25625,25626,25629,25631,25634,25635,25636,25637,25639,25640,25641,25643,25646,25647,25648,25649,25650,25651,25653,25654,25655,25656,25657,25659,25660,25662,25664,25666,25667,25673,25675,25676,25677,25678,25679,25680,25681,25683,25685,25686,25687,25689,25690,25691,25692,25693,25695,25696,25697,25698,25699,25700,25701,25702,25704,25706,25707,25708,25710,25711,25712,25713,25714,25715,25716,25717,25718,25719,25723,25724,25725,25726,25727,25728,25729,25731,25734,25736,25737,25738,25739,25740,25741,25742,25743,25744,25747,25748,25751,25752,25754,25755,25756,25757,25759,25760,25761,25762,25763,25765,25766,25767,25768,25770,25771,25775,25777,25778,25779,25780,25782,25785,25787,25789,25790,25791,25793,25795,25796,25798,25799,25800,25801,25802,25803,25804,25807,25809,25811,25812,25813,25814,25817,25818,25819,25820,25821,25823,25824,25825,25827,25829,25831,25832,25833,25834,25835,25836,25837,25838,25839,25840,25841,25842,25843,25844,25845,25846,25847,25848,25849,25850,25851,25852,25853,25854,25855,25857,25858,25859,25860,25861,25862,25863,25864,25866,25867,25868,25869,25870,25871,25872,25873,25875,25876,25877,25878,25879,25881,25882,25883,25884,25885,25886,25887,25888,25889,25890,25891,25892,25894,25895,25896,25897,25898,25900,25901,25904,25905,25906,25907,25911,25914,25916,25917,25920,25921,25922,25923,25924,25926,25927,25930,25931,25933,25934,25936,25938,25939,25940,25943,25944,25946,25948,25951,25952,25953,25956,25957,25959,25960,25961,25962,25965,25966,25967,25969,25971,25973,25974,25976,25977,25978,25979,25980,25981,25982,25983,25984,25985,25986,25987,25988,25989,25990,25992,25993,25994,25997,25998,25999,26002,26004,26005,26006,26008,26010,26013,26014,26016,26018,26019,26022,26024,26026,26028,26030,26033,26034,26035,26036,26037,26038,26039,26040,26042,26043,26046,26047,26048,26050,26055,26056,26057,26058,26061,26064,26065,26067,26068,26069,26072,26073,26074,26075,26076,26077,26078,26079,26081,26083,26084,26090,26091,26098,26099,26100,26101,26104,26105,26107,26108,26109,26110,26111,26113,26116,26117,26119,26120,26121,26123,26125,26128,26129,26130,26134,26135,26136,26138,26139,26140,26142,26145,26146,26147,26148,26150,26153,26154,26155,26156,26158,26160,26162,26163,26167,26168,26169,26170,26171,26173,26175,26176,26178,26180,26181,26182,26183,26184,26185,26186,26189,26190,26192,26193,26200,26201,26203,26204,26205,26206,26208,26210,26211,26213,26215,26217,26218,26219,26220,26221,26225,26226,26227,26229,26232,26233,26235,26236,26237,26239,26240,26241,26243,26245,26246,26248,26249,26250,26251,26253,26254,26255,26256,26258,26259,26260,26261,26264,26265,26266,26267,26268,26270,26271,26272,26273,26274,26275,26276,26277,26278,26281,26282,26283,26284,26285,26287,26288,26289,26290,26291,26293,26294,26295,26296,26298,26299,26300,26301,26303,26304,26305,26306,26307,26308,26309,26310,26311,26312,26313,26314,26315,26316,26317,26318,26319,26320,26321,26322,26323,26324,26325,26326,26327,26328,26330,26334,26335,26336,26337,26338,26339,26340,26341,26343,26344,26346,26347,26348,26349,26350,26351,26353,26357,26358,26360,26362,26363,26365,26369,26370,26371,26372,26373,26374,26375,26380,26382,26383,26385,26386,26387,26390,26392,26393,26394,26396,26398,26400,26401,26402,26403,26404,26405,26407,26409,26414,26416,26418,26419,26422,26423,26424,26425,26427,26428,26430,26431,26433,26436,26437,26439,26442,26443,26445,26450,26452,26453,26455,26456,26457,26458,26459,26461,26466,26467,26468,26470,26471,26475,26476,26478,26481,26484,26486,26488,26489,26490,26491,26493,26496,26498,26499,26501,26502,26504,26506,26508,26509,26510,26511,26513,26514,26515,26516,26518,26521,26523,26527,26528,26529,26532,26534,26537,26540,26542,26545,26546,26548,26553,26554,26555,26556,26557,26558,26559,26560,26562,26565,26566,26567,26568,26569,26570,26571,26572,26573,26574,26581,26582,26583,26587,26591,26593,26595,26596,26598,26599,26600,26602,26603,26605,26606,26610,26613,26614,26615,26616,26617,26618,26619,26620,26622,26625,26626,26627,26628,26630,26637,26640,26642,26644,26645,26648,26649,26650,26651,26652,26654,26655,26656,26658,26659,26660,26661,26662,26663,26664,26667,26668,26669,26670,26671,26672,26673,26676,26677,26678,26682,26683,26687,26695,26699,26701,26703,26706,26710,26711,26712,26713,26714,26715,26716,26717,26718,26719,26730,26732,26733,26734,26735,26736,26737,26738,26739,26741,26744,26745,26746,26747,26748,26749,26750,26751,26752,26754,26756,26759,26760,26761,26762,26763,26764,26765,26766,26768,26769,26770,26772,26773,26774,26776,26777,26778,26779,26780,26781,26782,26783,26784,26785,26787,26788,26789,26793,26794,26795,26796,26798,26801,26802,26804,26806,26807,26808,26809,26810,26811,26812,26813,26814,26815,26817,26819,26820,26821,26822,26823,26824,26826,26828,26830,26831,26832,26833,26835,26836,26838,26839,26841,26843,26844,26845,26846,26847,26849,26850,26852,26853,26854,26855,26856,26857,26858,26859,26860,26861,26863,26866,26867,26868,26870,26871,26872,26875,26877,26878,26879,26880,26882,26883,26884,26886,26887,26888,26889,26890,26892,26895,26897,26899,26900,26901,26902,26903,26904,26905,26906,26907,26908,26909,26910,26913,26914,26915,26917,26918,26919,26920,26921,26922,26923,26924,26926,26927,26929,26930,26931,26933,26934,26935,26936,26938,26939,26940,26942,26944,26945,26947,26948,26949,26950,26951,26952,26953,26954,26955,26956,26957,26958,26959,26960,26961,26962,26963,26965,26966,26968,26969,26971,26972,26975,26977,26978,26980,26981,26983,26984,26985,26986,26988,26989,26991,26992,26994,26995,26996,26997,26998,27002,27003,27005,27006,27007,27009,27011,27013,27018,27019,27020,27022,27023,27024,27025,27026,27027,27030,27031,27033,27034,27037,27038,27039,27040,27041,27042,27043,27044,27045,27046,27049,27050,27052,27054,27055,27056,27058,27059,27061,27062,27064,27065,27066,27068,27069,27070,27071,27072,27074,27075,27076,27077,27078,27079,27080,27081,27083,27085,27087,27089,27090,27091,27093,27094,27095,27096,27097,27098,27100,27101,27102,27105,27106,27107,27108,27109,27110,27111,27112,27113,27114,27115,27116,27118,27119,27120,27121,27123,27124,27125,27126,27127,27128,27129,27130,27131,27132,27134,27136,27137,27138,27139,27140,27141,27142,27143,27144,27145,27147,27148,27149,27150,27151,27152,27153,27154,27155,27156,27157,27158,27161,27162,27163,27164,27165,27166,27168,27170,27171,27172,27173,27174,27175,27177,27179,27180,27181,27182,27184,27186,27187,27188,27190,27191,27192,27193,27194,27195,27196,27199,27200,27201,27202,27203,27205,27206,27208,27209,27210,27211,27212,27213,27214,27215,27217,27218,27219,27220,27221,27222,27223,27226,27228,27229,27230,27231,27232,27234,27235,27236,27238,27239,27240,27241,27242,27243,27244,27245,27246,27247,27248,27250,27251,27252,27253,27254,27255,27256,27258,27259,27261,27262,27263,27265,27266,27267,27269,27270,27271,27272,27273,27274,27275,27276,27277,27279,27282,27283,27284,27285,27286,27288,27289,27290,27291,27292,27293,27294,27295,27297,27298,27299,27300,27301,27302,27303,27304,27306,27309,27310,27311,27312,27313,27314,27315,27316,27317,27318,27319,27320,27321,27322,27323,27324,27325,27326,27327,27328,27329,27330,27331,27332,27333,27334,27335,27336,27337,27338,27339,27340,27341,27342,27343,27344,27345,27346,27347,27348,27349,27350,27351,27352,27353,27354,27355,27356,27357,27358,27359,27360,27361,27362,27363,27364,27365,27366,27367,27368,27369,27370,27371,27372,27373,27374,27375,27376,27377,27378,27379,27380,27381,27382,27383,27384,27385,27386,27387,27388,27389,27390,27391,27392,27393,27394,27395,27396,27397,27398,27399,27400,27401,27402,27403,27404,27405,27406,27407,27408,27409,27410,27411,27412,27413,27414,27415,27416,27417,27418,27419,27420,27421,27422,27423,27429,27430,27432,27433,27434,27435,27436,27437,27438,27439,27440,27441,27443,27444,27445,27446,27448,27451,27452,27453,27455,27456,27457,27458,27460,27461,27464,27466,27467,27469,27470,27471,27472,27473,27474,27475,27476,27477,27478,27479,27480,27482,27483,27484,27485,27486,27487,27488,27489,27496,27497,27499,27500,27501,27502,27503,27504,27505,27506,27507,27508,27509,27510,27511,27512,27514,27517,27518,27519,27520,27525,27528,27532,27534,27535,27536,27537,27540,27541,27543,27544,27545,27548,27549,27550,27551,27552,27554,27555,27556,27557,27558,27559,27560,27561,27563,27564,27565,27566,27567,27568,27569,27570,27574,27576,27577,27578,27579,27580,27581,27582,27584,27587,27588,27590,27591,27592,27593,27594,27596,27598,27600,27601,27608,27610,27612,27613,27614,27615,27616,27618,27619,27620,27621,27622,27623,27624,27625,27628,27629,27630,27632,27633,27634,27636,27638,27639,27640,27642,27643,27644,27646,27647,27648,27649,27650,27651,27652,27656,27657,27658,27659,27660,27662,27666,27671,27676,27677,27678,27680,27683,27685,27691,27692,27693,27697,27699,27702,27703,27705,27706,27707,27708,27710,27711,27715,27716,27717,27720,27723,27724,27725,27726,27727,27729,27730,27731,27734,27736,27737,27738,27746,27747,27749,27750,27751,27755,27756,27757,27758,27759,27761,27763,27765,27767,27768,27770,27771,27772,27775,27776,27780,27783,27786,27787,27789,27790,27793,27794,27797,27798,27799,27800,27802,27804,27805,27806,27808,27810,27816,27820,27823,27824,27828,27829,27830,27831,27834,27840,27841,27842,27843,27846,27847,27848,27851,27853,27854,27855,27857,27858,27864,27865,27866,27868,27869,27871,27876,27878,27879,27881,27884,27885,27890,27892,27897,27903,27904,27906,27907,27909,27910,27912,27913,27914,27917,27919,27920,27921,27923,27924,27925,27926,27928,27932,27933,27935,27936,27937,27938,27939,27940,27942,27944,27945,27948,27949,27951,27952,27956,27958,27959,27960,27962,27967,27968,27970,27972,27977,27980,27984,27989,27990,27991,27992,27995,27997,27999,28001,28002,28004,28005,28007,28008,28011,28012,28013,28016,28017,28018,28019,28021,28022,28025,28026,28027,28029,28030,28031,28032,28033,28035,28036,28038,28039,28042,28043,28045,28047,28048,28050,28054,28055,28056,28057,28058,28060,28066,28069,28076,28077,28080,28081,28083,28084,28086,28087,28089,28090,28091,28092,28093,28094,28097,28098,28099,28104,28105,28106,28109,28110,28111,28112,28114,28115,28116,28117,28119,28122,28123,28124,28127,28130,28131,28133,28135,28136,28137,28138,28141,28143,28144,28146,28148,28149,28150,28152,28154,28157,28158,28159,28160,28161,28162,28163,28164,28166,28167,28168,28169,28171,28175,28178,28179,28181,28184,28185,28187,28188,28190,28191,28194,28198,28199,28200,28202,28204,28206,28208,28209,28211,28213,28214,28215,28217,28219,28220,28221,28222,28223,28224,28225,28226,28229,28230,28231,28232,28233,28234,28235,28236,28239,28240,28241,28242,28245,28247,28249,28250,28252,28253,28254,28256,28257,28258,28259,28260,28261,28262,28263,28264,28265,28266,28268,28269,28271,28272,28273,28274,28275,28276,28277,28278,28279,28280,28281,28282,28283,28284,28285,28288,28289,28290,28292,28295,28296,28298,28299,28300,28301,28302,28305,28306,28307,28308,28309,28310,28311,28313,28314,28315,28317,28318,28320,28321,28323,28324,28326,28328,28329,28331,28332,28333,28334,28336,28339,28341,28344,28345,28348,28350,28351,28352,28355,28356,28357,28358,28360,28361,28362,28364,28365,28366,28368,28370,28374,28376,28377,28379,28380,28381,28387,28391,28394,28395,28396,28397,28398,28399,28400,28401,28402,28403,28405,28406,28407,28408,28410,28411,28412,28413,28414,28415,28416,28417,28419,28420,28421,28423,28424,28426,28427,28428,28429,28430,28432,28433,28434,28438,28439,28440,28441,28442,28443,28444,28445,28446,28447,28449,28450,28451,28453,28454,28455,28456,28460,28462,28464,28466,28468,28469,28471,28472,28473,28474,28475,28476,28477,28479,28480,28481,28482,28483,28484,28485,28488,28489,28490,28492,28494,28495,28496,28497,28498,28499,28500,28501,28502,28503,28505,28506,28507,28509,28511,28512,28513,28515,28516,28517,28519,28520,28521,28522,28523,28524,28527,28528,28529,28531,28533,28534,28535,28537,28539,28541,28542,28543,28544,28545,28546,28547,28549,28550,28551,28554,28555,28559,28560,28561,28562,28563,28564,28565,28566,28567,28568,28569,28570,28571,28573,28574,28575,28576,28578,28579,28580,28581,28582,28584,28585,28586,28587,28588,28589,28590,28591,28592,28593,28594,28596,28597,28599,28600,28602,28603,28604,28605,28606,28607,28609,28611,28612,28613,28614,28615,28616,28618,28619,28620,28621,28622,28623,28624,28627,28628,28629,28630,28631,28632,28633,28634,28635,28636,28637,28639,28642,28643,28644,28645,28646,28647,28648,28649,28650,28651,28652,28653,28656,28657,28658,28659,28660,28661,28662,28663,28664,28665,28666,28667,28668,28669,28670,28671,28672,28673,28674,28675,28676,28677,28678,28679,28680,28681,28682,28683,28684,28685,28686,28687,28688,28690,28691,28692,28693,28694,28695,28696,28697,28700,28701,28702,28703,28704,28705,28706,28708,28709,28710,28711,28712,28713,28714,28715,28716,28717,28718,28719,28720,28721,28722,28723,28724,28726,28727,28728,28730,28731,28732,28733,28734,28735,28736,28737,28738,28739,28740,28741,28742,28743,28744,28745,28746,28747,28749,28750,28752,28753,28754,28755,28756,28757,28758,28759,28760,28761,28762,28763,28764,28765,28767,28768,28769,28770,28771,28772,28773,28774,28775,28776,28777,28778,28782,28785,28786,28787,28788,28791,28793,28794,28795,28797,28801,28802,28803,28804,28806,28807,28808,28811,28812,28813,28815,28816,28817,28819,28823,28824,28826,28827,28830,28831,28832,28833,28834,28835,28836,28837,28838,28839,28840,28841,28842,28848,28850,28852,28853,28854,28858,28862,28863,28868,28869,28870,28871,28873,28875,28876,28877,28878,28879,28880,28881,28882,28883,28884,28885,28886,28887,28890,28892,28893,28894,28896,28897,28898,28899,28901,28906,28910,28912,28913,28914,28915,28916,28917,28918,28920,28922,28923,28924,28926,28927,28928,28929,28930,28931,28932,28933,28934,28935,28936,28939,28940,28941,28942,28943,28945,28946,28948,28951,28955,28956,28957,28958,28959,28960,28961,28962,28963,28964,28965,28967,28968,28969,28970,28971,28972,28973,28974,28978,28979,28980,28981,28983,28984,28985,28986,28987,28988,28989,28990,28991,28992,28993,28994,28995,28996,28998,28999,29e3,29001,29003,29005,29007,29008,29009,29010,29011,29012,29013,29014,29015,29016,29017,29018,29019,29021,29023,29024,29025,29026,29027,29029,29033,29034,29035,29036,29037,29039,29040,29041,29044,29045,29046,29047,29049,29051,29052,29054,29055,29056,29057,29058,29059,29061,29062,29063,29064,29065,29067,29068,29069,29070,29072,29073,29074,29075,29077,29078,29079,29082,29083,29084,29085,29086,29089,29090,29091,29092,29093,29094,29095,29097,29098,29099,29101,29102,29103,29104,29105,29106,29108,29110,29111,29112,29114,29115,29116,29117,29118,29119,29120,29121,29122,29124,29125,29126,29127,29128,29129,29130,29131,29132,29133,29135,29136,29137,29138,29139,29142,29143,29144,29145,29146,29147,29148,29149,29150,29151,29153,29154,29155,29156,29158,29160,29161,29162,29163,29164,29165,29167,29168,29169,29170,29171,29172,29173,29174,29175,29176,29178,29179,29180,29181,29182,29183,29184,29185,29186,29187,29188,29189,29191,29192,29193,29194,29195,29196,29197,29198,29199,29200,29201,29202,29203,29204,29205,29206,29207,29208,29209,29210,29211,29212,29214,29215,29216,29217,29218,29219,29220,29221,29222,29223,29225,29227,29229,29230,29231,29234,29235,29236,29242,29244,29246,29248,29249,29250,29251,29252,29253,29254,29257,29258,29259,29262,29263,29264,29265,29267,29268,29269,29271,29272,29274,29276,29278,29280,29283,29284,29285,29288,29290,29291,29292,29293,29296,29297,29299,29300,29302,29303,29304,29307,29308,29309,29314,29315,29317,29318,29319,29320,29321,29324,29326,29328,29329,29331,29332,29333,29334,29335,29336,29337,29338,29339,29340,29341,29342,29344,29345,29346,29347,29348,29349,29350,29351,29352,29353,29354,29355,29358,29361,29362,29363,29365,29370,29371,29372,29373,29374,29375,29376,29381,29382,29383,29385,29386,29387,29388,29391,29393,29395,29396,29397,29398,29400,29402,29403,58566,58567,58568,58569,58570,58571,58572,58573,58574,58575,58576,58577,58578,58579,58580,58581,58582,58583,58584,58585,58586,58587,58588,58589,58590,58591,58592,58593,58594,58595,58596,58597,58598,58599,58600,58601,58602,58603,58604,58605,58606,58607,58608,58609,58610,58611,58612,58613,58614,58615,58616,58617,58618,58619,58620,58621,58622,58623,58624,58625,58626,58627,58628,58629,58630,58631,58632,58633,58634,58635,58636,58637,58638,58639,58640,58641,58642,58643,58644,58645,58646,58647,58648,58649,58650,58651,58652,58653,58654,58655,58656,58657,58658,58659,58660,58661,12288,12289,12290,183,713,711,168,12291,12293,8212,65374,8214,8230,8216,8217,8220,8221,12308,12309,12296,12297,12298,12299,12300,12301,12302,12303,12310,12311,12304,12305,177,215,247,8758,8743,8744,8721,8719,8746,8745,8712,8759,8730,8869,8741,8736,8978,8857,8747,8750,8801,8780,8776,8765,8733,8800,8814,8815,8804,8805,8734,8757,8756,9794,9792,176,8242,8243,8451,65284,164,65504,65505,8240,167,8470,9734,9733,9675,9679,9678,9671,9670,9633,9632,9651,9650,8251,8594,8592,8593,8595,12307,58662,58663,58664,58665,58666,58667,58668,58669,58670,58671,58672,58673,58674,58675,58676,58677,58678,58679,58680,58681,58682,58683,58684,58685,58686,58687,58688,58689,58690,58691,58692,58693,58694,58695,58696,58697,58698,58699,58700,58701,58702,58703,58704,58705,58706,58707,58708,58709,58710,58711,58712,58713,58714,58715,58716,58717,58718,58719,58720,58721,58722,58723,58724,58725,58726,58727,58728,58729,58730,58731,58732,58733,58734,58735,58736,58737,58738,58739,58740,58741,58742,58743,58744,58745,58746,58747,58748,58749,58750,58751,58752,58753,58754,58755,58756,58757,8560,8561,8562,8563,8564,8565,8566,8567,8568,8569,59238,59239,59240,59241,59242,59243,9352,9353,9354,9355,9356,9357,9358,9359,9360,9361,9362,9363,9364,9365,9366,9367,9368,9369,9370,9371,9332,9333,9334,9335,9336,9337,9338,9339,9340,9341,9342,9343,9344,9345,9346,9347,9348,9349,9350,9351,9312,9313,9314,9315,9316,9317,9318,9319,9320,9321,8364,59245,12832,12833,12834,12835,12836,12837,12838,12839,12840,12841,59246,59247,8544,8545,8546,8547,8548,8549,8550,8551,8552,8553,8554,8555,59248,59249,58758,58759,58760,58761,58762,58763,58764,58765,58766,58767,58768,58769,58770,58771,58772,58773,58774,58775,58776,58777,58778,58779,58780,58781,58782,58783,58784,58785,58786,58787,58788,58789,58790,58791,58792,58793,58794,58795,58796,58797,58798,58799,58800,58801,58802,58803,58804,58805,58806,58807,58808,58809,58810,58811,58812,58813,58814,58815,58816,58817,58818,58819,58820,58821,58822,58823,58824,58825,58826,58827,58828,58829,58830,58831,58832,58833,58834,58835,58836,58837,58838,58839,58840,58841,58842,58843,58844,58845,58846,58847,58848,58849,58850,58851,58852,12288,65281,65282,65283,65509,65285,65286,65287,65288,65289,65290,65291,65292,65293,65294,65295,65296,65297,65298,65299,65300,65301,65302,65303,65304,65305,65306,65307,65308,65309,65310,65311,65312,65313,65314,65315,65316,65317,65318,65319,65320,65321,65322,65323,65324,65325,65326,65327,65328,65329,65330,65331,65332,65333,65334,65335,65336,65337,65338,65339,65340,65341,65342,65343,65344,65345,65346,65347,65348,65349,65350,65351,65352,65353,65354,65355,65356,65357,65358,65359,65360,65361,65362,65363,65364,65365,65366,65367,65368,65369,65370,65371,65372,65373,65507,58854,58855,58856,58857,58858,58859,58860,58861,58862,58863,58864,58865,58866,58867,58868,58869,58870,58871,58872,58873,58874,58875,58876,58877,58878,58879,58880,58881,58882,58883,58884,58885,58886,58887,58888,58889,58890,58891,58892,58893,58894,58895,58896,58897,58898,58899,58900,58901,58902,58903,58904,58905,58906,58907,58908,58909,58910,58911,58912,58913,58914,58915,58916,58917,58918,58919,58920,58921,58922,58923,58924,58925,58926,58927,58928,58929,58930,58931,58932,58933,58934,58935,58936,58937,58938,58939,58940,58941,58942,58943,58944,58945,58946,58947,58948,58949,12353,12354,12355,12356,12357,12358,12359,12360,12361,12362,12363,12364,12365,12366,12367,12368,12369,12370,12371,12372,12373,12374,12375,12376,12377,12378,12379,12380,12381,12382,12383,12384,12385,12386,12387,12388,12389,12390,12391,12392,12393,12394,12395,12396,12397,12398,12399,12400,12401,12402,12403,12404,12405,12406,12407,12408,12409,12410,12411,12412,12413,12414,12415,12416,12417,12418,12419,12420,12421,12422,12423,12424,12425,12426,12427,12428,12429,12430,12431,12432,12433,12434,12435,59250,59251,59252,59253,59254,59255,59256,59257,59258,59259,59260,58950,58951,58952,58953,58954,58955,58956,58957,58958,58959,58960,58961,58962,58963,58964,58965,58966,58967,58968,58969,58970,58971,58972,58973,58974,58975,58976,58977,58978,58979,58980,58981,58982,58983,58984,58985,58986,58987,58988,58989,58990,58991,58992,58993,58994,58995,58996,58997,58998,58999,59e3,59001,59002,59003,59004,59005,59006,59007,59008,59009,59010,59011,59012,59013,59014,59015,59016,59017,59018,59019,59020,59021,59022,59023,59024,59025,59026,59027,59028,59029,59030,59031,59032,59033,59034,59035,59036,59037,59038,59039,59040,59041,59042,59043,59044,59045,12449,12450,12451,12452,12453,12454,12455,12456,12457,12458,12459,12460,12461,12462,12463,12464,12465,12466,12467,12468,12469,12470,12471,12472,12473,12474,12475,12476,12477,12478,12479,12480,12481,12482,12483,12484,12485,12486,12487,12488,12489,12490,12491,12492,12493,12494,12495,12496,12497,12498,12499,12500,12501,12502,12503,12504,12505,12506,12507,12508,12509,12510,12511,12512,12513,12514,12515,12516,12517,12518,12519,12520,12521,12522,12523,12524,12525,12526,12527,12528,12529,12530,12531,12532,12533,12534,59261,59262,59263,59264,59265,59266,59267,59268,59046,59047,59048,59049,59050,59051,59052,59053,59054,59055,59056,59057,59058,59059,59060,59061,59062,59063,59064,59065,59066,59067,59068,59069,59070,59071,59072,59073,59074,59075,59076,59077,59078,59079,59080,59081,59082,59083,59084,59085,59086,59087,59088,59089,59090,59091,59092,59093,59094,59095,59096,59097,59098,59099,59100,59101,59102,59103,59104,59105,59106,59107,59108,59109,59110,59111,59112,59113,59114,59115,59116,59117,59118,59119,59120,59121,59122,59123,59124,59125,59126,59127,59128,59129,59130,59131,59132,59133,59134,59135,59136,59137,59138,59139,59140,59141,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,931,932,933,934,935,936,937,59269,59270,59271,59272,59273,59274,59275,59276,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,963,964,965,966,967,968,969,59277,59278,59279,59280,59281,59282,59283,65077,65078,65081,65082,65087,65088,65085,65086,65089,65090,65091,65092,59284,59285,65083,65084,65079,65080,65073,59286,65075,65076,59287,59288,59289,59290,59291,59292,59293,59294,59295,59142,59143,59144,59145,59146,59147,59148,59149,59150,59151,59152,59153,59154,59155,59156,59157,59158,59159,59160,59161,59162,59163,59164,59165,59166,59167,59168,59169,59170,59171,59172,59173,59174,59175,59176,59177,59178,59179,59180,59181,59182,59183,59184,59185,59186,59187,59188,59189,59190,59191,59192,59193,59194,59195,59196,59197,59198,59199,59200,59201,59202,59203,59204,59205,59206,59207,59208,59209,59210,59211,59212,59213,59214,59215,59216,59217,59218,59219,59220,59221,59222,59223,59224,59225,59226,59227,59228,59229,59230,59231,59232,59233,59234,59235,59236,59237,1040,1041,1042,1043,1044,1045,1025,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,59296,59297,59298,59299,59300,59301,59302,59303,59304,59305,59306,59307,59308,59309,59310,1072,1073,1074,1075,1076,1077,1105,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,59311,59312,59313,59314,59315,59316,59317,59318,59319,59320,59321,59322,59323,714,715,729,8211,8213,8229,8245,8453,8457,8598,8599,8600,8601,8725,8735,8739,8786,8806,8807,8895,9552,9553,9554,9555,9556,9557,9558,9559,9560,9561,9562,9563,9564,9565,9566,9567,9568,9569,9570,9571,9572,9573,9574,9575,9576,9577,9578,9579,9580,9581,9582,9583,9584,9585,9586,9587,9601,9602,9603,9604,9605,9606,9607,9608,9609,9610,9611,9612,9613,9614,9615,9619,9620,9621,9660,9661,9698,9699,9700,9701,9737,8853,12306,12317,12318,59324,59325,59326,59327,59328,59329,59330,59331,59332,59333,59334,257,225,462,224,275,233,283,232,299,237,464,236,333,243,466,242,363,250,468,249,470,472,474,476,252,234,593,7743,324,328,505,609,59337,59338,59339,59340,12549,12550,12551,12552,12553,12554,12555,12556,12557,12558,12559,12560,12561,12562,12563,12564,12565,12566,12567,12568,12569,12570,12571,12572,12573,12574,12575,12576,12577,12578,12579,12580,12581,12582,12583,12584,12585,59341,59342,59343,59344,59345,59346,59347,59348,59349,59350,59351,59352,59353,59354,59355,59356,59357,59358,59359,59360,59361,12321,12322,12323,12324,12325,12326,12327,12328,12329,12963,13198,13199,13212,13213,13214,13217,13252,13262,13265,13266,13269,65072,65506,65508,59362,8481,12849,59363,8208,59364,59365,59366,12540,12443,12444,12541,12542,12294,12445,12446,65097,65098,65099,65100,65101,65102,65103,65104,65105,65106,65108,65109,65110,65111,65113,65114,65115,65116,65117,65118,65119,65120,65121,65122,65123,65124,65125,65126,65128,65129,65130,65131,12350,12272,12273,12274,12275,12276,12277,12278,12279,12280,12281,12282,12283,12295,59380,59381,59382,59383,59384,59385,59386,59387,59388,59389,59390,59391,59392,9472,9473,9474,9475,9476,9477,9478,9479,9480,9481,9482,9483,9484,9485,9486,9487,9488,9489,9490,9491,9492,9493,9494,9495,9496,9497,9498,9499,9500,9501,9502,9503,9504,9505,9506,9507,9508,9509,9510,9511,9512,9513,9514,9515,9516,9517,9518,9519,9520,9521,9522,9523,9524,9525,9526,9527,9528,9529,9530,9531,9532,9533,9534,9535,9536,9537,9538,9539,9540,9541,9542,9543,9544,9545,9546,9547,59393,59394,59395,59396,59397,59398,59399,59400,59401,59402,59403,59404,59405,59406,59407,29404,29405,29407,29410,29411,29412,29413,29414,29415,29418,29419,29429,29430,29433,29437,29438,29439,29440,29442,29444,29445,29446,29447,29448,29449,29451,29452,29453,29455,29456,29457,29458,29460,29464,29465,29466,29471,29472,29475,29476,29478,29479,29480,29485,29487,29488,29490,29491,29493,29494,29498,29499,29500,29501,29504,29505,29506,29507,29508,29509,29510,29511,29512,29513,29514,29515,29516,29518,29519,29521,29523,29524,29525,29526,29528,29529,29530,29531,29532,29533,29534,29535,29537,29538,29539,29540,29541,29542,29543,29544,29545,29546,29547,29550,29552,29553,57344,57345,57346,57347,57348,57349,57350,57351,57352,57353,57354,57355,57356,57357,57358,57359,57360,57361,57362,57363,57364,57365,57366,57367,57368,57369,57370,57371,57372,57373,57374,57375,57376,57377,57378,57379,57380,57381,57382,57383,57384,57385,57386,57387,57388,57389,57390,57391,57392,57393,57394,57395,57396,57397,57398,57399,57400,57401,57402,57403,57404,57405,57406,57407,57408,57409,57410,57411,57412,57413,57414,57415,57416,57417,57418,57419,57420,57421,57422,57423,57424,57425,57426,57427,57428,57429,57430,57431,57432,57433,57434,57435,57436,57437,29554,29555,29556,29557,29558,29559,29560,29561,29562,29563,29564,29565,29567,29568,29569,29570,29571,29573,29574,29576,29578,29580,29581,29583,29584,29586,29587,29588,29589,29591,29592,29593,29594,29596,29597,29598,29600,29601,29603,29604,29605,29606,29607,29608,29610,29612,29613,29617,29620,29621,29622,29624,29625,29628,29629,29630,29631,29633,29635,29636,29637,29638,29639,29643,29644,29646,29650,29651,29652,29653,29654,29655,29656,29658,29659,29660,29661,29663,29665,29666,29667,29668,29670,29672,29674,29675,29676,29678,29679,29680,29681,29683,29684,29685,29686,29687,57438,57439,57440,57441,57442,57443,57444,57445,57446,57447,57448,57449,57450,57451,57452,57453,57454,57455,57456,57457,57458,57459,57460,57461,57462,57463,57464,57465,57466,57467,57468,57469,57470,57471,57472,57473,57474,57475,57476,57477,57478,57479,57480,57481,57482,57483,57484,57485,57486,57487,57488,57489,57490,57491,57492,57493,57494,57495,57496,57497,57498,57499,57500,57501,57502,57503,57504,57505,57506,57507,57508,57509,57510,57511,57512,57513,57514,57515,57516,57517,57518,57519,57520,57521,57522,57523,57524,57525,57526,57527,57528,57529,57530,57531,29688,29689,29690,29691,29692,29693,29694,29695,29696,29697,29698,29700,29703,29704,29707,29708,29709,29710,29713,29714,29715,29716,29717,29718,29719,29720,29721,29724,29725,29726,29727,29728,29729,29731,29732,29735,29737,29739,29741,29743,29745,29746,29751,29752,29753,29754,29755,29757,29758,29759,29760,29762,29763,29764,29765,29766,29767,29768,29769,29770,29771,29772,29773,29774,29775,29776,29777,29778,29779,29780,29782,29784,29789,29792,29793,29794,29795,29796,29797,29798,29799,29800,29801,29802,29803,29804,29806,29807,29809,29810,29811,29812,29813,29816,29817,29818,57532,57533,57534,57535,57536,57537,57538,57539,57540,57541,57542,57543,57544,57545,57546,57547,57548,57549,57550,57551,57552,57553,57554,57555,57556,57557,57558,57559,57560,57561,57562,57563,57564,57565,57566,57567,57568,57569,57570,57571,57572,57573,57574,57575,57576,57577,57578,57579,57580,57581,57582,57583,57584,57585,57586,57587,57588,57589,57590,57591,57592,57593,57594,57595,57596,57597,57598,57599,57600,57601,57602,57603,57604,57605,57606,57607,57608,57609,57610,57611,57612,57613,57614,57615,57616,57617,57618,57619,57620,57621,57622,57623,57624,57625,29819,29820,29821,29823,29826,29828,29829,29830,29832,29833,29834,29836,29837,29839,29841,29842,29843,29844,29845,29846,29847,29848,29849,29850,29851,29853,29855,29856,29857,29858,29859,29860,29861,29862,29866,29867,29868,29869,29870,29871,29872,29873,29874,29875,29876,29877,29878,29879,29880,29881,29883,29884,29885,29886,29887,29888,29889,29890,29891,29892,29893,29894,29895,29896,29897,29898,29899,29900,29901,29902,29903,29904,29905,29907,29908,29909,29910,29911,29912,29913,29914,29915,29917,29919,29921,29925,29927,29928,29929,29930,29931,29932,29933,29936,29937,29938,57626,57627,57628,57629,57630,57631,57632,57633,57634,57635,57636,57637,57638,57639,57640,57641,57642,57643,57644,57645,57646,57647,57648,57649,57650,57651,57652,57653,57654,57655,57656,57657,57658,57659,57660,57661,57662,57663,57664,57665,57666,57667,57668,57669,57670,57671,57672,57673,57674,57675,57676,57677,57678,57679,57680,57681,57682,57683,57684,57685,57686,57687,57688,57689,57690,57691,57692,57693,57694,57695,57696,57697,57698,57699,57700,57701,57702,57703,57704,57705,57706,57707,57708,57709,57710,57711,57712,57713,57714,57715,57716,57717,57718,57719,29939,29941,29944,29945,29946,29947,29948,29949,29950,29952,29953,29954,29955,29957,29958,29959,29960,29961,29962,29963,29964,29966,29968,29970,29972,29973,29974,29975,29979,29981,29982,29984,29985,29986,29987,29988,29990,29991,29994,29998,30004,30006,30009,30012,30013,30015,30017,30018,30019,30020,30022,30023,30025,30026,30029,30032,30033,30034,30035,30037,30038,30039,30040,30045,30046,30047,30048,30049,30050,30051,30052,30055,30056,30057,30059,30060,30061,30062,30063,30064,30065,30067,30069,30070,30071,30074,30075,30076,30077,30078,30080,30081,30082,30084,30085,30087,57720,57721,57722,57723,57724,57725,57726,57727,57728,57729,57730,57731,57732,57733,57734,57735,57736,57737,57738,57739,57740,57741,57742,57743,57744,57745,57746,57747,57748,57749,57750,57751,57752,57753,57754,57755,57756,57757,57758,57759,57760,57761,57762,57763,57764,57765,57766,57767,57768,57769,57770,57771,57772,57773,57774,57775,57776,57777,57778,57779,57780,57781,57782,57783,57784,57785,57786,57787,57788,57789,57790,57791,57792,57793,57794,57795,57796,57797,57798,57799,57800,57801,57802,57803,57804,57805,57806,57807,57808,57809,57810,57811,57812,57813,30088,30089,30090,30092,30093,30094,30096,30099,30101,30104,30107,30108,30110,30114,30118,30119,30120,30121,30122,30125,30134,30135,30138,30139,30143,30144,30145,30150,30155,30156,30158,30159,30160,30161,30163,30167,30169,30170,30172,30173,30175,30176,30177,30181,30185,30188,30189,30190,30191,30194,30195,30197,30198,30199,30200,30202,30203,30205,30206,30210,30212,30214,30215,30216,30217,30219,30221,30222,30223,30225,30226,30227,30228,30230,30234,30236,30237,30238,30241,30243,30247,30248,30252,30254,30255,30257,30258,30262,30263,30265,30266,30267,30269,30273,30274,30276,57814,57815,57816,57817,57818,57819,57820,57821,57822,57823,57824,57825,57826,57827,57828,57829,57830,57831,57832,57833,57834,57835,57836,57837,57838,57839,57840,57841,57842,57843,57844,57845,57846,57847,57848,57849,57850,57851,57852,57853,57854,57855,57856,57857,57858,57859,57860,57861,57862,57863,57864,57865,57866,57867,57868,57869,57870,57871,57872,57873,57874,57875,57876,57877,57878,57879,57880,57881,57882,57883,57884,57885,57886,57887,57888,57889,57890,57891,57892,57893,57894,57895,57896,57897,57898,57899,57900,57901,57902,57903,57904,57905,57906,57907,30277,30278,30279,30280,30281,30282,30283,30286,30287,30288,30289,30290,30291,30293,30295,30296,30297,30298,30299,30301,30303,30304,30305,30306,30308,30309,30310,30311,30312,30313,30314,30316,30317,30318,30320,30321,30322,30323,30324,30325,30326,30327,30329,30330,30332,30335,30336,30337,30339,30341,30345,30346,30348,30349,30351,30352,30354,30356,30357,30359,30360,30362,30363,30364,30365,30366,30367,30368,30369,30370,30371,30373,30374,30375,30376,30377,30378,30379,30380,30381,30383,30384,30387,30389,30390,30391,30392,30393,30394,30395,30396,30397,30398,30400,30401,30403,21834,38463,22467,25384,21710,21769,21696,30353,30284,34108,30702,33406,30861,29233,38552,38797,27688,23433,20474,25353,26263,23736,33018,26696,32942,26114,30414,20985,25942,29100,32753,34948,20658,22885,25034,28595,33453,25420,25170,21485,21543,31494,20843,30116,24052,25300,36299,38774,25226,32793,22365,38712,32610,29240,30333,26575,30334,25670,20336,36133,25308,31255,26001,29677,25644,25203,33324,39041,26495,29256,25198,25292,20276,29923,21322,21150,32458,37030,24110,26758,27036,33152,32465,26834,30917,34444,38225,20621,35876,33502,32990,21253,35090,21093,30404,30407,30409,30411,30412,30419,30421,30425,30426,30428,30429,30430,30432,30433,30434,30435,30436,30438,30439,30440,30441,30442,30443,30444,30445,30448,30451,30453,30454,30455,30458,30459,30461,30463,30464,30466,30467,30469,30470,30474,30476,30478,30479,30480,30481,30482,30483,30484,30485,30486,30487,30488,30491,30492,30493,30494,30497,30499,30500,30501,30503,30506,30507,30508,30510,30512,30513,30514,30515,30516,30521,30523,30525,30526,30527,30530,30532,30533,30534,30536,30537,30538,30539,30540,30541,30542,30543,30546,30547,30548,30549,30550,30551,30552,30553,30556,34180,38649,20445,22561,39281,23453,25265,25253,26292,35961,40077,29190,26479,30865,24754,21329,21271,36744,32972,36125,38049,20493,29384,22791,24811,28953,34987,22868,33519,26412,31528,23849,32503,29997,27893,36454,36856,36924,40763,27604,37145,31508,24444,30887,34006,34109,27605,27609,27606,24065,24199,30201,38381,25949,24330,24517,36767,22721,33218,36991,38491,38829,36793,32534,36140,25153,20415,21464,21342,36776,36777,36779,36941,26631,24426,33176,34920,40150,24971,21035,30250,24428,25996,28626,28392,23486,25672,20853,20912,26564,19993,31177,39292,28851,30557,30558,30559,30560,30564,30567,30569,30570,30573,30574,30575,30576,30577,30578,30579,30580,30581,30582,30583,30584,30586,30587,30588,30593,30594,30595,30598,30599,30600,30601,30602,30603,30607,30608,30611,30612,30613,30614,30615,30616,30617,30618,30619,30620,30621,30622,30625,30627,30628,30630,30632,30635,30637,30638,30639,30641,30642,30644,30646,30647,30648,30649,30650,30652,30654,30656,30657,30658,30659,30660,30661,30662,30663,30664,30665,30666,30667,30668,30670,30671,30672,30673,30674,30675,30676,30677,30678,30680,30681,30682,30685,30686,30687,30688,30689,30692,30149,24182,29627,33760,25773,25320,38069,27874,21338,21187,25615,38082,31636,20271,24091,33334,33046,33162,28196,27850,39539,25429,21340,21754,34917,22496,19981,24067,27493,31807,37096,24598,25830,29468,35009,26448,25165,36130,30572,36393,37319,24425,33756,34081,39184,21442,34453,27531,24813,24808,28799,33485,33329,20179,27815,34255,25805,31961,27133,26361,33609,21397,31574,20391,20876,27979,23618,36461,25554,21449,33580,33590,26597,30900,25661,23519,23700,24046,35815,25286,26612,35962,25600,25530,34633,39307,35863,32544,38130,20135,38416,39076,26124,29462,30694,30696,30698,30703,30704,30705,30706,30708,30709,30711,30713,30714,30715,30716,30723,30724,30725,30726,30727,30728,30730,30731,30734,30735,30736,30739,30741,30745,30747,30750,30752,30753,30754,30756,30760,30762,30763,30766,30767,30769,30770,30771,30773,30774,30781,30783,30785,30786,30787,30788,30790,30792,30793,30794,30795,30797,30799,30801,30803,30804,30808,30809,30810,30811,30812,30814,30815,30816,30817,30818,30819,30820,30821,30822,30823,30824,30825,30831,30832,30833,30834,30835,30836,30837,30838,30840,30841,30842,30843,30845,30846,30847,30848,30849,30850,30851,22330,23581,24120,38271,20607,32928,21378,25950,30021,21809,20513,36229,25220,38046,26397,22066,28526,24034,21557,28818,36710,25199,25764,25507,24443,28552,37108,33251,36784,23576,26216,24561,27785,38472,36225,34924,25745,31216,22478,27225,25104,21576,20056,31243,24809,28548,35802,25215,36894,39563,31204,21507,30196,25345,21273,27744,36831,24347,39536,32827,40831,20360,23610,36196,32709,26021,28861,20805,20914,34411,23815,23456,25277,37228,30068,36364,31264,24833,31609,20167,32504,30597,19985,33261,21021,20986,27249,21416,36487,38148,38607,28353,38500,26970,30852,30853,30854,30856,30858,30859,30863,30864,30866,30868,30869,30870,30873,30877,30878,30880,30882,30884,30886,30888,30889,30890,30891,30892,30893,30894,30895,30901,30902,30903,30904,30906,30907,30908,30909,30911,30912,30914,30915,30916,30918,30919,30920,30924,30925,30926,30927,30929,30930,30931,30934,30935,30936,30938,30939,30940,30941,30942,30943,30944,30945,30946,30947,30948,30949,30950,30951,30953,30954,30955,30957,30958,30959,30960,30961,30963,30965,30966,30968,30969,30971,30972,30973,30974,30975,30976,30978,30979,30980,30982,30983,30984,30985,30986,30987,30988,30784,20648,30679,25616,35302,22788,25571,24029,31359,26941,20256,33337,21912,20018,30126,31383,24162,24202,38383,21019,21561,28810,25462,38180,22402,26149,26943,37255,21767,28147,32431,34850,25139,32496,30133,33576,30913,38604,36766,24904,29943,35789,27492,21050,36176,27425,32874,33905,22257,21254,20174,19995,20945,31895,37259,31751,20419,36479,31713,31388,25703,23828,20652,33030,30209,31929,28140,32736,26449,23384,23544,30923,25774,25619,25514,25387,38169,25645,36798,31572,30249,25171,22823,21574,27513,20643,25140,24102,27526,20195,36151,34955,24453,36910,30989,30990,30991,30992,30993,30994,30996,30997,30998,30999,31e3,31001,31002,31003,31004,31005,31007,31008,31009,31010,31011,31013,31014,31015,31016,31017,31018,31019,31020,31021,31022,31023,31024,31025,31026,31027,31029,31030,31031,31032,31033,31037,31039,31042,31043,31044,31045,31047,31050,31051,31052,31053,31054,31055,31056,31057,31058,31060,31061,31064,31065,31073,31075,31076,31078,31081,31082,31083,31084,31086,31088,31089,31090,31091,31092,31093,31094,31097,31099,31100,31101,31102,31103,31106,31107,31110,31111,31112,31113,31115,31116,31117,31118,31120,31121,31122,24608,32829,25285,20025,21333,37112,25528,32966,26086,27694,20294,24814,28129,35806,24377,34507,24403,25377,20826,33633,26723,20992,25443,36424,20498,23707,31095,23548,21040,31291,24764,36947,30423,24503,24471,30340,36460,28783,30331,31561,30634,20979,37011,22564,20302,28404,36842,25932,31515,29380,28068,32735,23265,25269,24213,22320,33922,31532,24093,24351,36882,32532,39072,25474,28359,30872,28857,20856,38747,22443,30005,20291,30008,24215,24806,22880,28096,27583,30857,21500,38613,20939,20993,25481,21514,38035,35843,36300,29241,30879,34678,36845,35853,21472,31123,31124,31125,31126,31127,31128,31129,31131,31132,31133,31134,31135,31136,31137,31138,31139,31140,31141,31142,31144,31145,31146,31147,31148,31149,31150,31151,31152,31153,31154,31156,31157,31158,31159,31160,31164,31167,31170,31172,31173,31175,31176,31178,31180,31182,31183,31184,31187,31188,31190,31191,31193,31194,31195,31196,31197,31198,31200,31201,31202,31205,31208,31210,31212,31214,31217,31218,31219,31220,31221,31222,31223,31225,31226,31228,31230,31231,31233,31236,31237,31239,31240,31241,31242,31244,31247,31248,31249,31250,31251,31253,31254,31256,31257,31259,31260,19969,30447,21486,38025,39030,40718,38189,23450,35746,20002,19996,20908,33891,25026,21160,26635,20375,24683,20923,27934,20828,25238,26007,38497,35910,36887,30168,37117,30563,27602,29322,29420,35835,22581,30585,36172,26460,38208,32922,24230,28193,22930,31471,30701,38203,27573,26029,32526,22534,20817,38431,23545,22697,21544,36466,25958,39039,22244,38045,30462,36929,25479,21702,22810,22842,22427,36530,26421,36346,33333,21057,24816,22549,34558,23784,40517,20420,39069,35769,23077,24694,21380,25212,36943,37122,39295,24681,32780,20799,32819,23572,39285,27953,20108,31261,31263,31265,31266,31268,31269,31270,31271,31272,31273,31274,31275,31276,31277,31278,31279,31280,31281,31282,31284,31285,31286,31288,31290,31294,31296,31297,31298,31299,31300,31301,31303,31304,31305,31306,31307,31308,31309,31310,31311,31312,31314,31315,31316,31317,31318,31320,31321,31322,31323,31324,31325,31326,31327,31328,31329,31330,31331,31332,31333,31334,31335,31336,31337,31338,31339,31340,31341,31342,31343,31345,31346,31347,31349,31355,31356,31357,31358,31362,31365,31367,31369,31370,31371,31372,31374,31375,31376,31379,31380,31385,31386,31387,31390,31393,31394,36144,21457,32602,31567,20240,20047,38400,27861,29648,34281,24070,30058,32763,27146,30718,38034,32321,20961,28902,21453,36820,33539,36137,29359,39277,27867,22346,33459,26041,32938,25151,38450,22952,20223,35775,32442,25918,33778,38750,21857,39134,32933,21290,35837,21536,32954,24223,27832,36153,33452,37210,21545,27675,20998,32439,22367,28954,27774,31881,22859,20221,24575,24868,31914,20016,23553,26539,34562,23792,38155,39118,30127,28925,36898,20911,32541,35773,22857,20964,20315,21542,22827,25975,32932,23413,25206,25282,36752,24133,27679,31526,20239,20440,26381,31395,31396,31399,31401,31402,31403,31406,31407,31408,31409,31410,31412,31413,31414,31415,31416,31417,31418,31419,31420,31421,31422,31424,31425,31426,31427,31428,31429,31430,31431,31432,31433,31434,31436,31437,31438,31439,31440,31441,31442,31443,31444,31445,31447,31448,31450,31451,31452,31453,31457,31458,31460,31463,31464,31465,31466,31467,31468,31470,31472,31473,31474,31475,31476,31477,31478,31479,31480,31483,31484,31486,31488,31489,31490,31493,31495,31497,31500,31501,31502,31504,31506,31507,31510,31511,31512,31514,31516,31517,31519,31521,31522,31523,31527,31529,31533,28014,28074,31119,34993,24343,29995,25242,36741,20463,37340,26023,33071,33105,24220,33104,36212,21103,35206,36171,22797,20613,20184,38428,29238,33145,36127,23500,35747,38468,22919,32538,21648,22134,22030,35813,25913,27010,38041,30422,28297,24178,29976,26438,26577,31487,32925,36214,24863,31174,25954,36195,20872,21018,38050,32568,32923,32434,23703,28207,26464,31705,30347,39640,33167,32660,31957,25630,38224,31295,21578,21733,27468,25601,25096,40509,33011,30105,21106,38761,33883,26684,34532,38401,38548,38124,20010,21508,32473,26681,36319,32789,26356,24218,32697,31535,31536,31538,31540,31541,31542,31543,31545,31547,31549,31551,31552,31553,31554,31555,31556,31558,31560,31562,31565,31566,31571,31573,31575,31577,31580,31582,31583,31585,31587,31588,31589,31590,31591,31592,31593,31594,31595,31596,31597,31599,31600,31603,31604,31606,31608,31610,31612,31613,31615,31617,31618,31619,31620,31622,31623,31624,31625,31626,31627,31628,31630,31631,31633,31634,31635,31638,31640,31641,31642,31643,31646,31647,31648,31651,31652,31653,31662,31663,31664,31666,31667,31669,31670,31671,31673,31674,31675,31676,31677,31678,31679,31680,31682,31683,31684,22466,32831,26775,24037,25915,21151,24685,40858,20379,36524,20844,23467,24339,24041,27742,25329,36129,20849,38057,21246,27807,33503,29399,22434,26500,36141,22815,36764,33735,21653,31629,20272,27837,23396,22993,40723,21476,34506,39592,35895,32929,25925,39038,22266,38599,21038,29916,21072,23521,25346,35074,20054,25296,24618,26874,20851,23448,20896,35266,31649,39302,32592,24815,28748,36143,20809,24191,36891,29808,35268,22317,30789,24402,40863,38394,36712,39740,35809,30328,26690,26588,36330,36149,21053,36746,28378,26829,38149,37101,22269,26524,35065,36807,21704,31685,31688,31689,31690,31691,31693,31694,31695,31696,31698,31700,31701,31702,31703,31704,31707,31708,31710,31711,31712,31714,31715,31716,31719,31720,31721,31723,31724,31725,31727,31728,31730,31731,31732,31733,31734,31736,31737,31738,31739,31741,31743,31744,31745,31746,31747,31748,31749,31750,31752,31753,31754,31757,31758,31760,31761,31762,31763,31764,31765,31767,31768,31769,31770,31771,31772,31773,31774,31776,31777,31778,31779,31780,31781,31784,31785,31787,31788,31789,31790,31791,31792,31793,31794,31795,31796,31797,31798,31799,31801,31802,31803,31804,31805,31806,31810,39608,23401,28023,27686,20133,23475,39559,37219,25e3,37039,38889,21547,28085,23506,20989,21898,32597,32752,25788,25421,26097,25022,24717,28938,27735,27721,22831,26477,33322,22741,22158,35946,27627,37085,22909,32791,21495,28009,21621,21917,33655,33743,26680,31166,21644,20309,21512,30418,35977,38402,27827,28088,36203,35088,40548,36154,22079,40657,30165,24456,29408,24680,21756,20136,27178,34913,24658,36720,21700,28888,34425,40511,27946,23439,24344,32418,21897,20399,29492,21564,21402,20505,21518,21628,20046,24573,29786,22774,33899,32993,34676,29392,31946,28246,31811,31812,31813,31814,31815,31816,31817,31818,31819,31820,31822,31823,31824,31825,31826,31827,31828,31829,31830,31831,31832,31833,31834,31835,31836,31837,31838,31839,31840,31841,31842,31843,31844,31845,31846,31847,31848,31849,31850,31851,31852,31853,31854,31855,31856,31857,31858,31861,31862,31863,31864,31865,31866,31870,31871,31872,31873,31874,31875,31876,31877,31878,31879,31880,31882,31883,31884,31885,31886,31887,31888,31891,31892,31894,31897,31898,31899,31904,31905,31907,31910,31911,31912,31913,31915,31916,31917,31919,31920,31924,31925,31926,31927,31928,31930,31931,24359,34382,21804,25252,20114,27818,25143,33457,21719,21326,29502,28369,30011,21010,21270,35805,27088,24458,24576,28142,22351,27426,29615,26707,36824,32531,25442,24739,21796,30186,35938,28949,28067,23462,24187,33618,24908,40644,30970,34647,31783,30343,20976,24822,29004,26179,24140,24653,35854,28784,25381,36745,24509,24674,34516,22238,27585,24724,24935,21321,24800,26214,36159,31229,20250,28905,27719,35763,35826,32472,33636,26127,23130,39746,27985,28151,35905,27963,20249,28779,33719,25110,24785,38669,36135,31096,20987,22334,22522,26426,30072,31293,31215,31637,31935,31936,31938,31939,31940,31942,31945,31947,31950,31951,31952,31953,31954,31955,31956,31960,31962,31963,31965,31966,31969,31970,31971,31972,31973,31974,31975,31977,31978,31979,31980,31981,31982,31984,31985,31986,31987,31988,31989,31990,31991,31993,31994,31996,31997,31998,31999,32e3,32001,32002,32003,32004,32005,32006,32007,32008,32009,32011,32012,32013,32014,32015,32016,32017,32018,32019,32020,32021,32022,32023,32024,32025,32026,32027,32028,32029,32030,32031,32033,32035,32036,32037,32038,32040,32041,32042,32044,32045,32046,32048,32049,32050,32051,32052,32053,32054,32908,39269,36857,28608,35749,40481,23020,32489,32521,21513,26497,26840,36753,31821,38598,21450,24613,30142,27762,21363,23241,32423,25380,20960,33034,24049,34015,25216,20864,23395,20238,31085,21058,24760,27982,23492,23490,35745,35760,26082,24524,38469,22931,32487,32426,22025,26551,22841,20339,23478,21152,33626,39050,36158,30002,38078,20551,31292,20215,26550,39550,23233,27516,30417,22362,23574,31546,38388,29006,20860,32937,33392,22904,32516,33575,26816,26604,30897,30839,25315,25441,31616,20461,21098,20943,33616,27099,37492,36341,36145,35265,38190,31661,20214,32055,32056,32057,32058,32059,32060,32061,32062,32063,32064,32065,32066,32067,32068,32069,32070,32071,32072,32073,32074,32075,32076,32077,32078,32079,32080,32081,32082,32083,32084,32085,32086,32087,32088,32089,32090,32091,32092,32093,32094,32095,32096,32097,32098,32099,32100,32101,32102,32103,32104,32105,32106,32107,32108,32109,32111,32112,32113,32114,32115,32116,32117,32118,32120,32121,32122,32123,32124,32125,32126,32127,32128,32129,32130,32131,32132,32133,32134,32135,32136,32137,32138,32139,32140,32141,32142,32143,32144,32145,32146,32147,32148,32149,32150,32151,32152,20581,33328,21073,39279,28176,28293,28071,24314,20725,23004,23558,27974,27743,30086,33931,26728,22870,35762,21280,37233,38477,34121,26898,30977,28966,33014,20132,37066,27975,39556,23047,22204,25605,38128,30699,20389,33050,29409,35282,39290,32564,32478,21119,25945,37237,36735,36739,21483,31382,25581,25509,30342,31224,34903,38454,25130,21163,33410,26708,26480,25463,30571,31469,27905,32467,35299,22992,25106,34249,33445,30028,20511,20171,30117,35819,23626,24062,31563,26020,37329,20170,27941,35167,32039,38182,20165,35880,36827,38771,26187,31105,36817,28908,28024,32153,32154,32155,32156,32157,32158,32159,32160,32161,32162,32163,32164,32165,32167,32168,32169,32170,32171,32172,32173,32175,32176,32177,32178,32179,32180,32181,32182,32183,32184,32185,32186,32187,32188,32189,32190,32191,32192,32193,32194,32195,32196,32197,32198,32199,32200,32201,32202,32203,32204,32205,32206,32207,32208,32209,32210,32211,32212,32213,32214,32215,32216,32217,32218,32219,32220,32221,32222,32223,32224,32225,32226,32227,32228,32229,32230,32231,32232,32233,32234,32235,32236,32237,32238,32239,32240,32241,32242,32243,32244,32245,32246,32247,32248,32249,32250,23613,21170,33606,20834,33550,30555,26230,40120,20140,24778,31934,31923,32463,20117,35686,26223,39048,38745,22659,25964,38236,24452,30153,38742,31455,31454,20928,28847,31384,25578,31350,32416,29590,38893,20037,28792,20061,37202,21417,25937,26087,33276,33285,21646,23601,30106,38816,25304,29401,30141,23621,39545,33738,23616,21632,30697,20030,27822,32858,25298,25454,24040,20855,36317,36382,38191,20465,21477,24807,28844,21095,25424,40515,23071,20518,30519,21367,32482,25733,25899,25225,25496,20500,29237,35273,20915,35776,32477,22343,33740,38055,20891,21531,23803,32251,32252,32253,32254,32255,32256,32257,32258,32259,32260,32261,32262,32263,32264,32265,32266,32267,32268,32269,32270,32271,32272,32273,32274,32275,32276,32277,32278,32279,32280,32281,32282,32283,32284,32285,32286,32287,32288,32289,32290,32291,32292,32293,32294,32295,32296,32297,32298,32299,32300,32301,32302,32303,32304,32305,32306,32307,32308,32309,32310,32311,32312,32313,32314,32316,32317,32318,32319,32320,32322,32323,32324,32325,32326,32328,32329,32330,32331,32332,32333,32334,32335,32336,32337,32338,32339,32340,32341,32342,32343,32344,32345,32346,32347,32348,32349,20426,31459,27994,37089,39567,21888,21654,21345,21679,24320,25577,26999,20975,24936,21002,22570,21208,22350,30733,30475,24247,24951,31968,25179,25239,20130,28821,32771,25335,28900,38752,22391,33499,26607,26869,30933,39063,31185,22771,21683,21487,28212,20811,21051,23458,35838,32943,21827,22438,24691,22353,21549,31354,24656,23380,25511,25248,21475,25187,23495,26543,21741,31391,33510,37239,24211,35044,22840,22446,25358,36328,33007,22359,31607,20393,24555,23485,27454,21281,31568,29378,26694,30719,30518,26103,20917,20111,30420,23743,31397,33909,22862,39745,20608,32350,32351,32352,32353,32354,32355,32356,32357,32358,32359,32360,32361,32362,32363,32364,32365,32366,32367,32368,32369,32370,32371,32372,32373,32374,32375,32376,32377,32378,32379,32380,32381,32382,32383,32384,32385,32387,32388,32389,32390,32391,32392,32393,32394,32395,32396,32397,32398,32399,32400,32401,32402,32403,32404,32405,32406,32407,32408,32409,32410,32412,32413,32414,32430,32436,32443,32444,32470,32484,32492,32505,32522,32528,32542,32567,32569,32571,32572,32573,32574,32575,32576,32577,32579,32582,32583,32584,32585,32586,32587,32588,32589,32590,32591,32594,32595,39304,24871,28291,22372,26118,25414,22256,25324,25193,24275,38420,22403,25289,21895,34593,33098,36771,21862,33713,26469,36182,34013,23146,26639,25318,31726,38417,20848,28572,35888,25597,35272,25042,32518,28866,28389,29701,27028,29436,24266,37070,26391,28010,25438,21171,29282,32769,20332,23013,37226,28889,28061,21202,20048,38647,38253,34174,30922,32047,20769,22418,25794,32907,31867,27882,26865,26974,20919,21400,26792,29313,40654,31729,29432,31163,28435,29702,26446,37324,40100,31036,33673,33620,21519,26647,20029,21385,21169,30782,21382,21033,20616,20363,20432,32598,32601,32603,32604,32605,32606,32608,32611,32612,32613,32614,32615,32619,32620,32621,32623,32624,32627,32629,32630,32631,32632,32634,32635,32636,32637,32639,32640,32642,32643,32644,32645,32646,32647,32648,32649,32651,32653,32655,32656,32657,32658,32659,32661,32662,32663,32664,32665,32667,32668,32672,32674,32675,32677,32678,32680,32681,32682,32683,32684,32685,32686,32689,32691,32692,32693,32694,32695,32698,32699,32702,32704,32706,32707,32708,32710,32711,32712,32713,32715,32717,32719,32720,32721,32722,32723,32726,32727,32729,32730,32731,32732,32733,32734,32738,32739,30178,31435,31890,27813,38582,21147,29827,21737,20457,32852,33714,36830,38256,24265,24604,28063,24088,25947,33080,38142,24651,28860,32451,31918,20937,26753,31921,33391,20004,36742,37327,26238,20142,35845,25769,32842,20698,30103,29134,23525,36797,28518,20102,25730,38243,24278,26009,21015,35010,28872,21155,29454,29747,26519,30967,38678,20020,37051,40158,28107,20955,36161,21533,25294,29618,33777,38646,40836,38083,20278,32666,20940,28789,38517,23725,39046,21478,20196,28316,29705,27060,30827,39311,30041,21016,30244,27969,26611,20845,40857,32843,21657,31548,31423,32740,32743,32744,32746,32747,32748,32749,32751,32754,32756,32757,32758,32759,32760,32761,32762,32765,32766,32767,32770,32775,32776,32777,32778,32782,32783,32785,32787,32794,32795,32797,32798,32799,32801,32803,32804,32811,32812,32813,32814,32815,32816,32818,32820,32825,32826,32828,32830,32832,32833,32836,32837,32839,32840,32841,32846,32847,32848,32849,32851,32853,32854,32855,32857,32859,32860,32861,32862,32863,32864,32865,32866,32867,32868,32869,32870,32871,32872,32875,32876,32877,32878,32879,32880,32882,32883,32884,32885,32886,32887,32888,32889,32890,32891,32892,32893,38534,22404,25314,38471,27004,23044,25602,31699,28431,38475,33446,21346,39045,24208,28809,25523,21348,34383,40065,40595,30860,38706,36335,36162,40575,28510,31108,24405,38470,25134,39540,21525,38109,20387,26053,23653,23649,32533,34385,27695,24459,29575,28388,32511,23782,25371,23402,28390,21365,20081,25504,30053,25249,36718,20262,20177,27814,32438,35770,33821,34746,32599,36923,38179,31657,39585,35064,33853,27931,39558,32476,22920,40635,29595,30721,34434,39532,39554,22043,21527,22475,20080,40614,21334,36808,33033,30610,39314,34542,28385,34067,26364,24930,28459,32894,32897,32898,32901,32904,32906,32909,32910,32911,32912,32913,32914,32916,32917,32919,32921,32926,32931,32934,32935,32936,32940,32944,32947,32949,32950,32952,32953,32955,32965,32967,32968,32969,32970,32971,32975,32976,32977,32978,32979,32980,32981,32984,32991,32992,32994,32995,32998,33006,33013,33015,33017,33019,33022,33023,33024,33025,33027,33028,33029,33031,33032,33035,33036,33045,33047,33049,33051,33052,33053,33055,33056,33057,33058,33059,33060,33061,33062,33063,33064,33065,33066,33067,33069,33070,33072,33075,33076,33077,33079,33081,33082,33083,33084,33085,33087,35881,33426,33579,30450,27667,24537,33725,29483,33541,38170,27611,30683,38086,21359,33538,20882,24125,35980,36152,20040,29611,26522,26757,37238,38665,29028,27809,30473,23186,38209,27599,32654,26151,23504,22969,23194,38376,38391,20204,33804,33945,27308,30431,38192,29467,26790,23391,30511,37274,38753,31964,36855,35868,24357,31859,31192,35269,27852,34588,23494,24130,26825,30496,32501,20885,20813,21193,23081,32517,38754,33495,25551,30596,34256,31186,28218,24217,22937,34065,28781,27665,25279,30399,25935,24751,38397,26126,34719,40483,38125,21517,21629,35884,25720,33088,33089,33090,33091,33092,33093,33095,33097,33101,33102,33103,33106,33110,33111,33112,33115,33116,33117,33118,33119,33121,33122,33123,33124,33126,33128,33130,33131,33132,33135,33138,33139,33141,33142,33143,33144,33153,33155,33156,33157,33158,33159,33161,33163,33164,33165,33166,33168,33170,33171,33172,33173,33174,33175,33177,33178,33182,33183,33184,33185,33186,33188,33189,33191,33193,33195,33196,33197,33198,33199,33200,33201,33202,33204,33205,33206,33207,33208,33209,33212,33213,33214,33215,33220,33221,33223,33224,33225,33227,33229,33230,33231,33232,33233,33234,33235,25721,34321,27169,33180,30952,25705,39764,25273,26411,33707,22696,40664,27819,28448,23518,38476,35851,29279,26576,25287,29281,20137,22982,27597,22675,26286,24149,21215,24917,26408,30446,30566,29287,31302,25343,21738,21584,38048,37027,23068,32435,27670,20035,22902,32784,22856,21335,30007,38590,22218,25376,33041,24700,38393,28118,21602,39297,20869,23273,33021,22958,38675,20522,27877,23612,25311,20320,21311,33147,36870,28346,34091,25288,24180,30910,25781,25467,24565,23064,37247,40479,23615,25423,32834,23421,21870,38218,38221,28037,24744,26592,29406,20957,23425,33236,33237,33238,33239,33240,33241,33242,33243,33244,33245,33246,33247,33248,33249,33250,33252,33253,33254,33256,33257,33259,33262,33263,33264,33265,33266,33269,33270,33271,33272,33273,33274,33277,33279,33283,33287,33288,33289,33290,33291,33294,33295,33297,33299,33301,33302,33303,33304,33305,33306,33309,33312,33316,33317,33318,33319,33321,33326,33330,33338,33340,33341,33343,33344,33345,33346,33347,33349,33350,33352,33354,33356,33357,33358,33360,33361,33362,33363,33364,33365,33366,33367,33369,33371,33372,33373,33374,33376,33377,33378,33379,33380,33381,33382,33383,33385,25319,27870,29275,25197,38062,32445,33043,27987,20892,24324,22900,21162,24594,22899,26262,34384,30111,25386,25062,31983,35834,21734,27431,40485,27572,34261,21589,20598,27812,21866,36276,29228,24085,24597,29750,25293,25490,29260,24472,28227,27966,25856,28504,30424,30928,30460,30036,21028,21467,20051,24222,26049,32810,32982,25243,21638,21032,28846,34957,36305,27873,21624,32986,22521,35060,36180,38506,37197,20329,27803,21943,30406,30768,25256,28921,28558,24429,34028,26842,30844,31735,33192,26379,40527,25447,30896,22383,30738,38713,25209,25259,21128,29749,27607,33386,33387,33388,33389,33393,33397,33398,33399,33400,33403,33404,33408,33409,33411,33413,33414,33415,33417,33420,33424,33427,33428,33429,33430,33434,33435,33438,33440,33442,33443,33447,33458,33461,33462,33466,33467,33468,33471,33472,33474,33475,33477,33478,33481,33488,33494,33497,33498,33501,33506,33511,33512,33513,33514,33516,33517,33518,33520,33522,33523,33525,33526,33528,33530,33532,33533,33534,33535,33536,33546,33547,33549,33552,33554,33555,33558,33560,33561,33565,33566,33567,33568,33569,33570,33571,33572,33573,33574,33577,33578,33582,33584,33586,33591,33595,33597,21860,33086,30130,30382,21305,30174,20731,23617,35692,31687,20559,29255,39575,39128,28418,29922,31080,25735,30629,25340,39057,36139,21697,32856,20050,22378,33529,33805,24179,20973,29942,35780,23631,22369,27900,39047,23110,30772,39748,36843,31893,21078,25169,38138,20166,33670,33889,33769,33970,22484,26420,22275,26222,28006,35889,26333,28689,26399,27450,26646,25114,22971,19971,20932,28422,26578,27791,20854,26827,22855,27495,30054,23822,33040,40784,26071,31048,31041,39569,36215,23682,20062,20225,21551,22865,30732,22120,27668,36804,24323,27773,27875,35755,25488,33598,33599,33601,33602,33604,33605,33608,33610,33611,33612,33613,33614,33619,33621,33622,33623,33624,33625,33629,33634,33648,33649,33650,33651,33652,33653,33654,33657,33658,33662,33663,33664,33665,33666,33667,33668,33671,33672,33674,33675,33676,33677,33679,33680,33681,33684,33685,33686,33687,33689,33690,33693,33695,33697,33698,33699,33700,33701,33702,33703,33708,33709,33710,33711,33717,33723,33726,33727,33730,33731,33732,33734,33736,33737,33739,33741,33742,33744,33745,33746,33747,33749,33751,33753,33754,33755,33758,33762,33763,33764,33766,33767,33768,33771,33772,33773,24688,27965,29301,25190,38030,38085,21315,36801,31614,20191,35878,20094,40660,38065,38067,21069,28508,36963,27973,35892,22545,23884,27424,27465,26538,21595,33108,32652,22681,34103,24378,25250,27207,38201,25970,24708,26725,30631,20052,20392,24039,38808,25772,32728,23789,20431,31373,20999,33540,19988,24623,31363,38054,20405,20146,31206,29748,21220,33465,25810,31165,23517,27777,38738,36731,27682,20542,21375,28165,25806,26228,27696,24773,39031,35831,24198,29756,31351,31179,19992,37041,29699,27714,22234,37195,27845,36235,21306,34502,26354,36527,23624,39537,28192,33774,33775,33779,33780,33781,33782,33783,33786,33787,33788,33790,33791,33792,33794,33797,33799,33800,33801,33802,33808,33810,33811,33812,33813,33814,33815,33817,33818,33819,33822,33823,33824,33825,33826,33827,33833,33834,33835,33836,33837,33838,33839,33840,33842,33843,33844,33845,33846,33847,33849,33850,33851,33854,33855,33856,33857,33858,33859,33860,33861,33863,33864,33865,33866,33867,33868,33869,33870,33871,33872,33874,33875,33876,33877,33878,33880,33885,33886,33887,33888,33890,33892,33893,33894,33895,33896,33898,33902,33903,33904,33906,33908,33911,33913,33915,33916,21462,23094,40843,36259,21435,22280,39079,26435,37275,27849,20840,30154,25331,29356,21048,21149,32570,28820,30264,21364,40522,27063,30830,38592,35033,32676,28982,29123,20873,26579,29924,22756,25880,22199,35753,39286,25200,32469,24825,28909,22764,20161,20154,24525,38887,20219,35748,20995,22922,32427,25172,20173,26085,25102,33592,33993,33635,34701,29076,28342,23481,32466,20887,25545,26580,32905,33593,34837,20754,23418,22914,36785,20083,27741,20837,35109,36719,38446,34122,29790,38160,38384,28070,33509,24369,25746,27922,33832,33134,40131,22622,36187,19977,21441,33917,33918,33919,33920,33921,33923,33924,33925,33926,33930,33933,33935,33936,33937,33938,33939,33940,33941,33942,33944,33946,33947,33949,33950,33951,33952,33954,33955,33956,33957,33958,33959,33960,33961,33962,33963,33964,33965,33966,33968,33969,33971,33973,33974,33975,33979,33980,33982,33984,33986,33987,33989,33990,33991,33992,33995,33996,33998,33999,34002,34004,34005,34007,34008,34009,34010,34011,34012,34014,34017,34018,34020,34023,34024,34025,34026,34027,34029,34030,34031,34033,34034,34035,34036,34037,34038,34039,34040,34041,34042,34043,34045,34046,34048,34049,34050,20254,25955,26705,21971,20007,25620,39578,25195,23234,29791,33394,28073,26862,20711,33678,30722,26432,21049,27801,32433,20667,21861,29022,31579,26194,29642,33515,26441,23665,21024,29053,34923,38378,38485,25797,36193,33203,21892,27733,25159,32558,22674,20260,21830,36175,26188,19978,23578,35059,26786,25422,31245,28903,33421,21242,38902,23569,21736,37045,32461,22882,36170,34503,33292,33293,36198,25668,23556,24913,28041,31038,35774,30775,30003,21627,20280,36523,28145,23072,32453,31070,27784,23457,23158,29978,32958,24910,28183,22768,29983,29989,29298,21319,32499,34051,34052,34053,34054,34055,34056,34057,34058,34059,34061,34062,34063,34064,34066,34068,34069,34070,34072,34073,34075,34076,34077,34078,34080,34082,34083,34084,34085,34086,34087,34088,34089,34090,34093,34094,34095,34096,34097,34098,34099,34100,34101,34102,34110,34111,34112,34113,34114,34116,34117,34118,34119,34123,34124,34125,34126,34127,34128,34129,34130,34131,34132,34133,34135,34136,34138,34139,34140,34141,34143,34144,34145,34146,34147,34149,34150,34151,34153,34154,34155,34156,34157,34158,34159,34160,34161,34163,34165,34166,34167,34168,34172,34173,34175,34176,34177,30465,30427,21097,32988,22307,24072,22833,29422,26045,28287,35799,23608,34417,21313,30707,25342,26102,20160,39135,34432,23454,35782,21490,30690,20351,23630,39542,22987,24335,31034,22763,19990,26623,20107,25325,35475,36893,21183,26159,21980,22124,36866,20181,20365,37322,39280,27663,24066,24643,23460,35270,35797,25910,25163,39318,23432,23551,25480,21806,21463,30246,20861,34092,26530,26803,27530,25234,36755,21460,33298,28113,30095,20070,36174,23408,29087,34223,26257,26329,32626,34560,40653,40736,23646,26415,36848,26641,26463,25101,31446,22661,24246,25968,28465,34178,34179,34182,34184,34185,34186,34187,34188,34189,34190,34192,34193,34194,34195,34196,34197,34198,34199,34200,34201,34202,34205,34206,34207,34208,34209,34210,34211,34213,34214,34215,34217,34219,34220,34221,34225,34226,34227,34228,34229,34230,34232,34234,34235,34236,34237,34238,34239,34240,34242,34243,34244,34245,34246,34247,34248,34250,34251,34252,34253,34254,34257,34258,34260,34262,34263,34264,34265,34266,34267,34269,34270,34271,34272,34273,34274,34275,34277,34278,34279,34280,34282,34283,34284,34285,34286,34287,34288,34289,34290,34291,34292,34293,34294,34295,34296,24661,21047,32781,25684,34928,29993,24069,26643,25332,38684,21452,29245,35841,27700,30561,31246,21550,30636,39034,33308,35828,30805,26388,28865,26031,25749,22070,24605,31169,21496,19997,27515,32902,23546,21987,22235,20282,20284,39282,24051,26494,32824,24578,39042,36865,23435,35772,35829,25628,33368,25822,22013,33487,37221,20439,32032,36895,31903,20723,22609,28335,23487,35785,32899,37240,33948,31639,34429,38539,38543,32485,39635,30862,23681,31319,36930,38567,31071,23385,25439,31499,34001,26797,21766,32553,29712,32034,38145,25152,22604,20182,23427,22905,22612,34297,34298,34300,34301,34302,34304,34305,34306,34307,34308,34310,34311,34312,34313,34314,34315,34316,34317,34318,34319,34320,34322,34323,34324,34325,34327,34328,34329,34330,34331,34332,34333,34334,34335,34336,34337,34338,34339,34340,34341,34342,34344,34346,34347,34348,34349,34350,34351,34352,34353,34354,34355,34356,34357,34358,34359,34361,34362,34363,34365,34366,34367,34368,34369,34370,34371,34372,34373,34374,34375,34376,34377,34378,34379,34380,34386,34387,34389,34390,34391,34392,34393,34395,34396,34397,34399,34400,34401,34403,34404,34405,34406,34407,34408,34409,34410,29549,25374,36427,36367,32974,33492,25260,21488,27888,37214,22826,24577,27760,22349,25674,36138,30251,28393,22363,27264,30192,28525,35885,35848,22374,27631,34962,30899,25506,21497,28845,27748,22616,25642,22530,26848,33179,21776,31958,20504,36538,28108,36255,28907,25487,28059,28372,32486,33796,26691,36867,28120,38518,35752,22871,29305,34276,33150,30140,35466,26799,21076,36386,38161,25552,39064,36420,21884,20307,26367,22159,24789,28053,21059,23625,22825,28155,22635,3e4,29980,24684,33300,33094,25361,26465,36834,30522,36339,36148,38081,24086,21381,21548,28867,34413,34415,34416,34418,34419,34420,34421,34422,34423,34424,34435,34436,34437,34438,34439,34440,34441,34446,34447,34448,34449,34450,34452,34454,34455,34456,34457,34458,34459,34462,34463,34464,34465,34466,34469,34470,34475,34477,34478,34482,34483,34487,34488,34489,34491,34492,34493,34494,34495,34497,34498,34499,34501,34504,34508,34509,34514,34515,34517,34518,34519,34522,34524,34525,34528,34529,34530,34531,34533,34534,34535,34536,34538,34539,34540,34543,34549,34550,34551,34554,34555,34556,34557,34559,34561,34564,34565,34566,34571,34572,34574,34575,34576,34577,34580,34582,27712,24311,20572,20141,24237,25402,33351,36890,26704,37230,30643,21516,38108,24420,31461,26742,25413,31570,32479,30171,20599,25237,22836,36879,20984,31171,31361,22270,24466,36884,28034,23648,22303,21520,20820,28237,22242,25512,39059,33151,34581,35114,36864,21534,23663,33216,25302,25176,33073,40501,38464,39534,39548,26925,22949,25299,21822,25366,21703,34521,27964,23043,29926,34972,27498,22806,35916,24367,28286,29609,39037,20024,28919,23436,30871,25405,26202,30358,24779,23451,23113,19975,33109,27754,29579,20129,26505,32593,24448,26106,26395,24536,22916,23041,34585,34587,34589,34591,34592,34596,34598,34599,34600,34602,34603,34604,34605,34607,34608,34610,34611,34613,34614,34616,34617,34618,34620,34621,34624,34625,34626,34627,34628,34629,34630,34634,34635,34637,34639,34640,34641,34642,34644,34645,34646,34648,34650,34651,34652,34653,34654,34655,34657,34658,34662,34663,34664,34665,34666,34667,34668,34669,34671,34673,34674,34675,34677,34679,34680,34681,34682,34687,34688,34689,34692,34694,34695,34697,34698,34700,34702,34703,34704,34705,34706,34708,34709,34710,34712,34713,34714,34715,34716,34717,34718,34720,34721,34722,34723,34724,24013,24494,21361,38886,36829,26693,22260,21807,24799,20026,28493,32500,33479,33806,22996,20255,20266,23614,32428,26410,34074,21619,30031,32963,21890,39759,20301,28205,35859,23561,24944,21355,30239,28201,34442,25991,38395,32441,21563,31283,32010,38382,21985,32705,29934,25373,34583,28065,31389,25105,26017,21351,25569,27779,24043,21596,38056,20044,27745,35820,23627,26080,33436,26791,21566,21556,27595,27494,20116,25410,21320,33310,20237,20398,22366,25098,38654,26212,29289,21247,21153,24735,35823,26132,29081,26512,35199,30802,30717,26224,22075,21560,38177,29306,34725,34726,34727,34729,34730,34734,34736,34737,34738,34740,34742,34743,34744,34745,34747,34748,34750,34751,34753,34754,34755,34756,34757,34759,34760,34761,34764,34765,34766,34767,34768,34772,34773,34774,34775,34776,34777,34778,34780,34781,34782,34783,34785,34786,34787,34788,34790,34791,34792,34793,34795,34796,34797,34799,34800,34801,34802,34803,34804,34805,34806,34807,34808,34810,34811,34812,34813,34815,34816,34817,34818,34820,34821,34822,34823,34824,34825,34827,34828,34829,34830,34831,34832,34833,34834,34836,34839,34840,34841,34842,34844,34845,34846,34847,34848,34851,31232,24687,24076,24713,33181,22805,24796,29060,28911,28330,27728,29312,27268,34989,24109,20064,23219,21916,38115,27927,31995,38553,25103,32454,30606,34430,21283,38686,36758,26247,23777,20384,29421,19979,21414,22799,21523,25472,38184,20808,20185,40092,32420,21688,36132,34900,33335,38386,28046,24358,23244,26174,38505,29616,29486,21439,33146,39301,32673,23466,38519,38480,32447,30456,21410,38262,39321,31665,35140,28248,20065,32724,31077,35814,24819,21709,20139,39033,24055,27233,20687,21521,35937,33831,30813,38660,21066,21742,22179,38144,28040,23477,28102,26195,34852,34853,34854,34855,34856,34857,34858,34859,34860,34861,34862,34863,34864,34865,34867,34868,34869,34870,34871,34872,34874,34875,34877,34878,34879,34881,34882,34883,34886,34887,34888,34889,34890,34891,34894,34895,34896,34897,34898,34899,34901,34902,34904,34906,34907,34908,34909,34910,34911,34912,34918,34919,34922,34925,34927,34929,34931,34932,34933,34934,34936,34937,34938,34939,34940,34944,34947,34950,34951,34953,34954,34956,34958,34959,34960,34961,34963,34964,34965,34967,34968,34969,34970,34971,34973,34974,34975,34976,34977,34979,34981,34982,34983,34984,34985,34986,23567,23389,26657,32918,21880,31505,25928,26964,20123,27463,34638,38795,21327,25375,25658,37034,26012,32961,35856,20889,26800,21368,34809,25032,27844,27899,35874,23633,34218,33455,38156,27427,36763,26032,24571,24515,20449,34885,26143,33125,29481,24826,20852,21009,22411,24418,37026,34892,37266,24184,26447,24615,22995,20804,20982,33016,21256,27769,38596,29066,20241,20462,32670,26429,21957,38152,31168,34966,32483,22687,25100,38656,34394,22040,39035,24464,35768,33988,37207,21465,26093,24207,30044,24676,32110,23167,32490,32493,36713,21927,23459,24748,26059,29572,34988,34990,34991,34992,34994,34995,34996,34997,34998,35e3,35001,35002,35003,35005,35006,35007,35008,35011,35012,35015,35016,35018,35019,35020,35021,35023,35024,35025,35027,35030,35031,35034,35035,35036,35037,35038,35040,35041,35046,35047,35049,35050,35051,35052,35053,35054,35055,35058,35061,35062,35063,35066,35067,35069,35071,35072,35073,35075,35076,35077,35078,35079,35080,35081,35083,35084,35085,35086,35087,35089,35092,35093,35094,35095,35096,35100,35101,35102,35103,35104,35106,35107,35108,35110,35111,35112,35113,35116,35117,35118,35119,35121,35122,35123,35125,35127,36873,30307,30505,32474,38772,34203,23398,31348,38634,34880,21195,29071,24490,26092,35810,23547,39535,24033,27529,27739,35757,35759,36874,36805,21387,25276,40486,40493,21568,20011,33469,29273,34460,23830,34905,28079,38597,21713,20122,35766,28937,21693,38409,28895,28153,30416,20005,30740,34578,23721,24310,35328,39068,38414,28814,27839,22852,25513,30524,34893,28436,33395,22576,29141,21388,30746,38593,21761,24422,28976,23476,35866,39564,27523,22830,40495,31207,26472,25196,20335,30113,32650,27915,38451,27687,20208,30162,20859,26679,28478,36992,33136,22934,29814,35128,35129,35130,35131,35132,35133,35134,35135,35136,35138,35139,35141,35142,35143,35144,35145,35146,35147,35148,35149,35150,35151,35152,35153,35154,35155,35156,35157,35158,35159,35160,35161,35162,35163,35164,35165,35168,35169,35170,35171,35172,35173,35175,35176,35177,35178,35179,35180,35181,35182,35183,35184,35185,35186,35187,35188,35189,35190,35191,35192,35193,35194,35196,35197,35198,35200,35202,35204,35205,35207,35208,35209,35210,35211,35212,35213,35214,35215,35216,35217,35218,35219,35220,35221,35222,35223,35224,35225,35226,35227,35228,35229,35230,35231,35232,35233,25671,23591,36965,31377,35875,23002,21676,33280,33647,35201,32768,26928,22094,32822,29239,37326,20918,20063,39029,25494,19994,21494,26355,33099,22812,28082,19968,22777,21307,25558,38129,20381,20234,34915,39056,22839,36951,31227,20202,33008,30097,27778,23452,23016,24413,26885,34433,20506,24050,20057,30691,20197,33402,25233,26131,37009,23673,20159,24441,33222,36920,32900,30123,20134,35028,24847,27589,24518,20041,30410,28322,35811,35758,35850,35793,24322,32764,32716,32462,33589,33643,22240,27575,38899,38452,23035,21535,38134,28139,23493,39278,23609,24341,38544,35234,35235,35236,35237,35238,35239,35240,35241,35242,35243,35244,35245,35246,35247,35248,35249,35250,35251,35252,35253,35254,35255,35256,35257,35258,35259,35260,35261,35262,35263,35264,35267,35277,35283,35284,35285,35287,35288,35289,35291,35293,35295,35296,35297,35298,35300,35303,35304,35305,35306,35308,35309,35310,35312,35313,35314,35316,35317,35318,35319,35320,35321,35322,35323,35324,35325,35326,35327,35329,35330,35331,35332,35333,35334,35336,35337,35338,35339,35340,35341,35342,35343,35344,35345,35346,35347,35348,35349,35350,35351,35352,35353,35354,35355,35356,35357,21360,33521,27185,23156,40560,24212,32552,33721,33828,33829,33639,34631,36814,36194,30408,24433,39062,30828,26144,21727,25317,20323,33219,30152,24248,38605,36362,34553,21647,27891,28044,27704,24703,21191,29992,24189,20248,24736,24551,23588,30001,37038,38080,29369,27833,28216,37193,26377,21451,21491,20305,37321,35825,21448,24188,36802,28132,20110,30402,27014,34398,24858,33286,20313,20446,36926,40060,24841,28189,28180,38533,20104,23089,38632,19982,23679,31161,23431,35821,32701,29577,22495,33419,37057,21505,36935,21947,23786,24481,24840,27442,29425,32946,35465,35358,35359,35360,35361,35362,35363,35364,35365,35366,35367,35368,35369,35370,35371,35372,35373,35374,35375,35376,35377,35378,35379,35380,35381,35382,35383,35384,35385,35386,35387,35388,35389,35391,35392,35393,35394,35395,35396,35397,35398,35399,35401,35402,35403,35404,35405,35406,35407,35408,35409,35410,35411,35412,35413,35414,35415,35416,35417,35418,35419,35420,35421,35422,35423,35424,35425,35426,35427,35428,35429,35430,35431,35432,35433,35434,35435,35436,35437,35438,35439,35440,35441,35442,35443,35444,35445,35446,35447,35448,35450,35451,35452,35453,35454,35455,35456,28020,23507,35029,39044,35947,39533,40499,28170,20900,20803,22435,34945,21407,25588,36757,22253,21592,22278,29503,28304,32536,36828,33489,24895,24616,38498,26352,32422,36234,36291,38053,23731,31908,26376,24742,38405,32792,20113,37095,21248,38504,20801,36816,34164,37213,26197,38901,23381,21277,30776,26434,26685,21705,28798,23472,36733,20877,22312,21681,25874,26242,36190,36163,33039,33900,36973,31967,20991,34299,26531,26089,28577,34468,36481,22122,36896,30338,28790,29157,36131,25321,21017,27901,36156,24590,22686,24974,26366,36192,25166,21939,28195,26413,36711,35457,35458,35459,35460,35461,35462,35463,35464,35467,35468,35469,35470,35471,35472,35473,35474,35476,35477,35478,35479,35480,35481,35482,35483,35484,35485,35486,35487,35488,35489,35490,35491,35492,35493,35494,35495,35496,35497,35498,35499,35500,35501,35502,35503,35504,35505,35506,35507,35508,35509,35510,35511,35512,35513,35514,35515,35516,35517,35518,35519,35520,35521,35522,35523,35524,35525,35526,35527,35528,35529,35530,35531,35532,35533,35534,35535,35536,35537,35538,35539,35540,35541,35542,35543,35544,35545,35546,35547,35548,35549,35550,35551,35552,35553,35554,35555,38113,38392,30504,26629,27048,21643,20045,28856,35784,25688,25995,23429,31364,20538,23528,30651,27617,35449,31896,27838,30415,26025,36759,23853,23637,34360,26632,21344,25112,31449,28251,32509,27167,31456,24432,28467,24352,25484,28072,26454,19976,24080,36134,20183,32960,30260,38556,25307,26157,25214,27836,36213,29031,32617,20806,32903,21484,36974,25240,21746,34544,36761,32773,38167,34071,36825,27993,29645,26015,30495,29956,30759,33275,36126,38024,20390,26517,30137,35786,38663,25391,38215,38453,33976,25379,30529,24449,29424,20105,24596,25972,25327,27491,25919,35556,35557,35558,35559,35560,35561,35562,35563,35564,35565,35566,35567,35568,35569,35570,35571,35572,35573,35574,35575,35576,35577,35578,35579,35580,35581,35582,35583,35584,35585,35586,35587,35588,35589,35590,35592,35593,35594,35595,35596,35597,35598,35599,35600,35601,35602,35603,35604,35605,35606,35607,35608,35609,35610,35611,35612,35613,35614,35615,35616,35617,35618,35619,35620,35621,35623,35624,35625,35626,35627,35628,35629,35630,35631,35632,35633,35634,35635,35636,35637,35638,35639,35640,35641,35642,35643,35644,35645,35646,35647,35648,35649,35650,35651,35652,35653,24103,30151,37073,35777,33437,26525,25903,21553,34584,30693,32930,33026,27713,20043,32455,32844,30452,26893,27542,25191,20540,20356,22336,25351,27490,36286,21482,26088,32440,24535,25370,25527,33267,33268,32622,24092,23769,21046,26234,31209,31258,36136,28825,30164,28382,27835,31378,20013,30405,24544,38047,34935,32456,31181,32959,37325,20210,20247,33311,21608,24030,27954,35788,31909,36724,32920,24090,21650,30385,23449,26172,39588,29664,26666,34523,26417,29482,35832,35803,36880,31481,28891,29038,25284,30633,22065,20027,33879,26609,21161,34496,36142,38136,31569,35654,35655,35656,35657,35658,35659,35660,35661,35662,35663,35664,35665,35666,35667,35668,35669,35670,35671,35672,35673,35674,35675,35676,35677,35678,35679,35680,35681,35682,35683,35684,35685,35687,35688,35689,35690,35691,35693,35694,35695,35696,35697,35698,35699,35700,35701,35702,35703,35704,35705,35706,35707,35708,35709,35710,35711,35712,35713,35714,35715,35716,35717,35718,35719,35720,35721,35722,35723,35724,35725,35726,35727,35728,35729,35730,35731,35732,35733,35734,35735,35736,35737,35738,35739,35740,35741,35742,35743,35756,35761,35771,35783,35792,35818,35849,35870,20303,27880,31069,39547,25235,29226,25341,19987,30742,36716,25776,36186,31686,26729,24196,35013,22918,25758,22766,29366,26894,38181,36861,36184,22368,32512,35846,20934,25417,25305,21331,26700,29730,33537,37196,21828,30528,28796,27978,20857,21672,36164,23039,28363,28100,23388,32043,20180,31869,28371,23376,33258,28173,23383,39683,26837,36394,23447,32508,24635,32437,37049,36208,22863,25549,31199,36275,21330,26063,31062,35781,38459,32452,38075,32386,22068,37257,26368,32618,23562,36981,26152,24038,20304,26590,20570,20316,22352,24231,59408,59409,59410,59411,59412,35896,35897,35898,35899,35900,35901,35902,35903,35904,35906,35907,35908,35909,35912,35914,35915,35917,35918,35919,35920,35921,35922,35923,35924,35926,35927,35928,35929,35931,35932,35933,35934,35935,35936,35939,35940,35941,35942,35943,35944,35945,35948,35949,35950,35951,35952,35953,35954,35956,35957,35958,35959,35963,35964,35965,35966,35967,35968,35969,35971,35972,35974,35975,35976,35979,35981,35982,35983,35984,35985,35986,35987,35989,35990,35991,35993,35994,35995,35996,35997,35998,35999,36e3,36001,36002,36003,36004,36005,36006,36007,36008,36009,36010,36011,36012,36013,20109,19980,20800,19984,24319,21317,19989,20120,19998,39730,23404,22121,20008,31162,20031,21269,20039,22829,29243,21358,27664,22239,32996,39319,27603,30590,40727,20022,20127,40720,20060,20073,20115,33416,23387,21868,22031,20164,21389,21405,21411,21413,21422,38757,36189,21274,21493,21286,21294,21310,36188,21350,21347,20994,21e3,21006,21037,21043,21055,21056,21068,21086,21089,21084,33967,21117,21122,21121,21136,21139,20866,32596,20155,20163,20169,20162,20200,20193,20203,20190,20251,20211,20258,20324,20213,20261,20263,20233,20267,20318,20327,25912,20314,20317,36014,36015,36016,36017,36018,36019,36020,36021,36022,36023,36024,36025,36026,36027,36028,36029,36030,36031,36032,36033,36034,36035,36036,36037,36038,36039,36040,36041,36042,36043,36044,36045,36046,36047,36048,36049,36050,36051,36052,36053,36054,36055,36056,36057,36058,36059,36060,36061,36062,36063,36064,36065,36066,36067,36068,36069,36070,36071,36072,36073,36074,36075,36076,36077,36078,36079,36080,36081,36082,36083,36084,36085,36086,36087,36088,36089,36090,36091,36092,36093,36094,36095,36096,36097,36098,36099,36100,36101,36102,36103,36104,36105,36106,36107,36108,36109,20319,20311,20274,20285,20342,20340,20369,20361,20355,20367,20350,20347,20394,20348,20396,20372,20454,20456,20458,20421,20442,20451,20444,20433,20447,20472,20521,20556,20467,20524,20495,20526,20525,20478,20508,20492,20517,20520,20606,20547,20565,20552,20558,20588,20603,20645,20647,20649,20666,20694,20742,20717,20716,20710,20718,20743,20747,20189,27709,20312,20325,20430,40864,27718,31860,20846,24061,40649,39320,20865,22804,21241,21261,35335,21264,20971,22809,20821,20128,20822,20147,34926,34980,20149,33044,35026,31104,23348,34819,32696,20907,20913,20925,20924,36110,36111,36112,36113,36114,36115,36116,36117,36118,36119,36120,36121,36122,36123,36124,36128,36177,36178,36183,36191,36197,36200,36201,36202,36204,36206,36207,36209,36210,36216,36217,36218,36219,36220,36221,36222,36223,36224,36226,36227,36230,36231,36232,36233,36236,36237,36238,36239,36240,36242,36243,36245,36246,36247,36248,36249,36250,36251,36252,36253,36254,36256,36257,36258,36260,36261,36262,36263,36264,36265,36266,36267,36268,36269,36270,36271,36272,36274,36278,36279,36281,36283,36285,36288,36289,36290,36293,36295,36296,36297,36298,36301,36304,36306,36307,36308,20935,20886,20898,20901,35744,35750,35751,35754,35764,35765,35767,35778,35779,35787,35791,35790,35794,35795,35796,35798,35800,35801,35804,35807,35808,35812,35816,35817,35822,35824,35827,35830,35833,35836,35839,35840,35842,35844,35847,35852,35855,35857,35858,35860,35861,35862,35865,35867,35864,35869,35871,35872,35873,35877,35879,35882,35883,35886,35887,35890,35891,35893,35894,21353,21370,38429,38434,38433,38449,38442,38461,38460,38466,38473,38484,38495,38503,38508,38514,38516,38536,38541,38551,38576,37015,37019,37021,37017,37036,37025,37044,37043,37046,37050,36309,36312,36313,36316,36320,36321,36322,36325,36326,36327,36329,36333,36334,36336,36337,36338,36340,36342,36348,36350,36351,36352,36353,36354,36355,36356,36358,36359,36360,36363,36365,36366,36368,36369,36370,36371,36373,36374,36375,36376,36377,36378,36379,36380,36384,36385,36388,36389,36390,36391,36392,36395,36397,36400,36402,36403,36404,36406,36407,36408,36411,36412,36414,36415,36419,36421,36422,36428,36429,36430,36431,36432,36435,36436,36437,36438,36439,36440,36442,36443,36444,36445,36446,36447,36448,36449,36450,36451,36452,36453,36455,36456,36458,36459,36462,36465,37048,37040,37071,37061,37054,37072,37060,37063,37075,37094,37090,37084,37079,37083,37099,37103,37118,37124,37154,37150,37155,37169,37167,37177,37187,37190,21005,22850,21154,21164,21165,21182,21759,21200,21206,21232,21471,29166,30669,24308,20981,20988,39727,21430,24321,30042,24047,22348,22441,22433,22654,22716,22725,22737,22313,22316,22314,22323,22329,22318,22319,22364,22331,22338,22377,22405,22379,22406,22396,22395,22376,22381,22390,22387,22445,22436,22412,22450,22479,22439,22452,22419,22432,22485,22488,22490,22489,22482,22456,22516,22511,22520,22500,22493,36467,36469,36471,36472,36473,36474,36475,36477,36478,36480,36482,36483,36484,36486,36488,36489,36490,36491,36492,36493,36494,36497,36498,36499,36501,36502,36503,36504,36505,36506,36507,36509,36511,36512,36513,36514,36515,36516,36517,36518,36519,36520,36521,36522,36525,36526,36528,36529,36531,36532,36533,36534,36535,36536,36537,36539,36540,36541,36542,36543,36544,36545,36546,36547,36548,36549,36550,36551,36552,36553,36554,36555,36556,36557,36559,36560,36561,36562,36563,36564,36565,36566,36567,36568,36569,36570,36571,36572,36573,36574,36575,36576,36577,36578,36579,36580,22539,22541,22525,22509,22528,22558,22553,22596,22560,22629,22636,22657,22665,22682,22656,39336,40729,25087,33401,33405,33407,33423,33418,33448,33412,33422,33425,33431,33433,33451,33464,33470,33456,33480,33482,33507,33432,33463,33454,33483,33484,33473,33449,33460,33441,33450,33439,33476,33486,33444,33505,33545,33527,33508,33551,33543,33500,33524,33490,33496,33548,33531,33491,33553,33562,33542,33556,33557,33504,33493,33564,33617,33627,33628,33544,33682,33596,33588,33585,33691,33630,33583,33615,33607,33603,33631,33600,33559,33632,33581,33594,33587,33638,33637,36581,36582,36583,36584,36585,36586,36587,36588,36589,36590,36591,36592,36593,36594,36595,36596,36597,36598,36599,36600,36601,36602,36603,36604,36605,36606,36607,36608,36609,36610,36611,36612,36613,36614,36615,36616,36617,36618,36619,36620,36621,36622,36623,36624,36625,36626,36627,36628,36629,36630,36631,36632,36633,36634,36635,36636,36637,36638,36639,36640,36641,36642,36643,36644,36645,36646,36647,36648,36649,36650,36651,36652,36653,36654,36655,36656,36657,36658,36659,36660,36661,36662,36663,36664,36665,36666,36667,36668,36669,36670,36671,36672,36673,36674,36675,36676,33640,33563,33641,33644,33642,33645,33646,33712,33656,33715,33716,33696,33706,33683,33692,33669,33660,33718,33705,33661,33720,33659,33688,33694,33704,33722,33724,33729,33793,33765,33752,22535,33816,33803,33757,33789,33750,33820,33848,33809,33798,33748,33759,33807,33795,33784,33785,33770,33733,33728,33830,33776,33761,33884,33873,33882,33881,33907,33927,33928,33914,33929,33912,33852,33862,33897,33910,33932,33934,33841,33901,33985,33997,34e3,34022,33981,34003,33994,33983,33978,34016,33953,33977,33972,33943,34021,34019,34060,29965,34104,34032,34105,34079,34106,36677,36678,36679,36680,36681,36682,36683,36684,36685,36686,36687,36688,36689,36690,36691,36692,36693,36694,36695,36696,36697,36698,36699,36700,36701,36702,36703,36704,36705,36706,36707,36708,36709,36714,36736,36748,36754,36765,36768,36769,36770,36772,36773,36774,36775,36778,36780,36781,36782,36783,36786,36787,36788,36789,36791,36792,36794,36795,36796,36799,36800,36803,36806,36809,36810,36811,36812,36813,36815,36818,36822,36823,36826,36832,36833,36835,36839,36844,36847,36849,36850,36852,36853,36854,36858,36859,36860,36862,36863,36871,36872,36876,36878,36883,36885,36888,34134,34107,34047,34044,34137,34120,34152,34148,34142,34170,30626,34115,34162,34171,34212,34216,34183,34191,34169,34222,34204,34181,34233,34231,34224,34259,34241,34268,34303,34343,34309,34345,34326,34364,24318,24328,22844,22849,32823,22869,22874,22872,21263,23586,23589,23596,23604,25164,25194,25247,25275,25290,25306,25303,25326,25378,25334,25401,25419,25411,25517,25590,25457,25466,25486,25524,25453,25516,25482,25449,25518,25532,25586,25592,25568,25599,25540,25566,25550,25682,25542,25534,25669,25665,25611,25627,25632,25612,25638,25633,25694,25732,25709,25750,36889,36892,36899,36900,36901,36903,36904,36905,36906,36907,36908,36912,36913,36914,36915,36916,36919,36921,36922,36925,36927,36928,36931,36933,36934,36936,36937,36938,36939,36940,36942,36948,36949,36950,36953,36954,36956,36957,36958,36959,36960,36961,36964,36966,36967,36969,36970,36971,36972,36975,36976,36977,36978,36979,36982,36983,36984,36985,36986,36987,36988,36990,36993,36996,36997,36998,36999,37001,37002,37004,37005,37006,37007,37008,37010,37012,37014,37016,37018,37020,37022,37023,37024,37028,37029,37031,37032,37033,37035,37037,37042,37047,37052,37053,37055,37056,25722,25783,25784,25753,25786,25792,25808,25815,25828,25826,25865,25893,25902,24331,24530,29977,24337,21343,21489,21501,21481,21480,21499,21522,21526,21510,21579,21586,21587,21588,21590,21571,21537,21591,21593,21539,21554,21634,21652,21623,21617,21604,21658,21659,21636,21622,21606,21661,21712,21677,21698,21684,21714,21671,21670,21715,21716,21618,21667,21717,21691,21695,21708,21721,21722,21724,21673,21674,21668,21725,21711,21726,21787,21735,21792,21757,21780,21747,21794,21795,21775,21777,21799,21802,21863,21903,21941,21833,21869,21825,21845,21823,21840,21820,37058,37059,37062,37064,37065,37067,37068,37069,37074,37076,37077,37078,37080,37081,37082,37086,37087,37088,37091,37092,37093,37097,37098,37100,37102,37104,37105,37106,37107,37109,37110,37111,37113,37114,37115,37116,37119,37120,37121,37123,37125,37126,37127,37128,37129,37130,37131,37132,37133,37134,37135,37136,37137,37138,37139,37140,37141,37142,37143,37144,37146,37147,37148,37149,37151,37152,37153,37156,37157,37158,37159,37160,37161,37162,37163,37164,37165,37166,37168,37170,37171,37172,37173,37174,37175,37176,37178,37179,37180,37181,37182,37183,37184,37185,37186,37188,21815,21846,21877,21878,21879,21811,21808,21852,21899,21970,21891,21937,21945,21896,21889,21919,21886,21974,21905,21883,21983,21949,21950,21908,21913,21994,22007,21961,22047,21969,21995,21996,21972,21990,21981,21956,21999,21989,22002,22003,21964,21965,21992,22005,21988,36756,22046,22024,22028,22017,22052,22051,22014,22016,22055,22061,22104,22073,22103,22060,22093,22114,22105,22108,22092,22100,22150,22116,22129,22123,22139,22140,22149,22163,22191,22228,22231,22237,22241,22261,22251,22265,22271,22276,22282,22281,22300,24079,24089,24084,24081,24113,24123,24124,37189,37191,37192,37201,37203,37204,37205,37206,37208,37209,37211,37212,37215,37216,37222,37223,37224,37227,37229,37235,37242,37243,37244,37248,37249,37250,37251,37252,37254,37256,37258,37262,37263,37267,37268,37269,37270,37271,37272,37273,37276,37277,37278,37279,37280,37281,37284,37285,37286,37287,37288,37289,37291,37292,37296,37297,37298,37299,37302,37303,37304,37305,37307,37308,37309,37310,37311,37312,37313,37314,37315,37316,37317,37318,37320,37323,37328,37330,37331,37332,37333,37334,37335,37336,37337,37338,37339,37341,37342,37343,37344,37345,37346,37347,37348,37349,24119,24132,24148,24155,24158,24161,23692,23674,23693,23696,23702,23688,23704,23705,23697,23706,23708,23733,23714,23741,23724,23723,23729,23715,23745,23735,23748,23762,23780,23755,23781,23810,23811,23847,23846,23854,23844,23838,23814,23835,23896,23870,23860,23869,23916,23899,23919,23901,23915,23883,23882,23913,23924,23938,23961,23965,35955,23991,24005,24435,24439,24450,24455,24457,24460,24469,24473,24476,24488,24493,24501,24508,34914,24417,29357,29360,29364,29367,29368,29379,29377,29390,29389,29394,29416,29423,29417,29426,29428,29431,29441,29427,29443,29434,37350,37351,37352,37353,37354,37355,37356,37357,37358,37359,37360,37361,37362,37363,37364,37365,37366,37367,37368,37369,37370,37371,37372,37373,37374,37375,37376,37377,37378,37379,37380,37381,37382,37383,37384,37385,37386,37387,37388,37389,37390,37391,37392,37393,37394,37395,37396,37397,37398,37399,37400,37401,37402,37403,37404,37405,37406,37407,37408,37409,37410,37411,37412,37413,37414,37415,37416,37417,37418,37419,37420,37421,37422,37423,37424,37425,37426,37427,37428,37429,37430,37431,37432,37433,37434,37435,37436,37437,37438,37439,37440,37441,37442,37443,37444,37445,29435,29463,29459,29473,29450,29470,29469,29461,29474,29497,29477,29484,29496,29489,29520,29517,29527,29536,29548,29551,29566,33307,22821,39143,22820,22786,39267,39271,39272,39273,39274,39275,39276,39284,39287,39293,39296,39300,39303,39306,39309,39312,39313,39315,39316,39317,24192,24209,24203,24214,24229,24224,24249,24245,24254,24243,36179,24274,24273,24283,24296,24298,33210,24516,24521,24534,24527,24579,24558,24580,24545,24548,24574,24581,24582,24554,24557,24568,24601,24629,24614,24603,24591,24589,24617,24619,24586,24639,24609,24696,24697,24699,24698,24642,37446,37447,37448,37449,37450,37451,37452,37453,37454,37455,37456,37457,37458,37459,37460,37461,37462,37463,37464,37465,37466,37467,37468,37469,37470,37471,37472,37473,37474,37475,37476,37477,37478,37479,37480,37481,37482,37483,37484,37485,37486,37487,37488,37489,37490,37491,37493,37494,37495,37496,37497,37498,37499,37500,37501,37502,37503,37504,37505,37506,37507,37508,37509,37510,37511,37512,37513,37514,37515,37516,37517,37519,37520,37521,37522,37523,37524,37525,37526,37527,37528,37529,37530,37531,37532,37533,37534,37535,37536,37537,37538,37539,37540,37541,37542,37543,24682,24701,24726,24730,24749,24733,24707,24722,24716,24731,24812,24763,24753,24797,24792,24774,24794,24756,24864,24870,24853,24867,24820,24832,24846,24875,24906,24949,25004,24980,24999,25015,25044,25077,24541,38579,38377,38379,38385,38387,38389,38390,38396,38398,38403,38404,38406,38408,38410,38411,38412,38413,38415,38418,38421,38422,38423,38425,38426,20012,29247,25109,27701,27732,27740,27722,27811,27781,27792,27796,27788,27752,27753,27764,27766,27782,27817,27856,27860,27821,27895,27896,27889,27863,27826,27872,27862,27898,27883,27886,27825,27859,27887,27902,37544,37545,37546,37547,37548,37549,37551,37552,37553,37554,37555,37556,37557,37558,37559,37560,37561,37562,37563,37564,37565,37566,37567,37568,37569,37570,37571,37572,37573,37574,37575,37577,37578,37579,37580,37581,37582,37583,37584,37585,37586,37587,37588,37589,37590,37591,37592,37593,37594,37595,37596,37597,37598,37599,37600,37601,37602,37603,37604,37605,37606,37607,37608,37609,37610,37611,37612,37613,37614,37615,37616,37617,37618,37619,37620,37621,37622,37623,37624,37625,37626,37627,37628,37629,37630,37631,37632,37633,37634,37635,37636,37637,37638,37639,37640,37641,27961,27943,27916,27971,27976,27911,27908,27929,27918,27947,27981,27950,27957,27930,27983,27986,27988,27955,28049,28015,28062,28064,27998,28051,28052,27996,28e3,28028,28003,28186,28103,28101,28126,28174,28095,28128,28177,28134,28125,28121,28182,28075,28172,28078,28203,28270,28238,28267,28338,28255,28294,28243,28244,28210,28197,28228,28383,28337,28312,28384,28461,28386,28325,28327,28349,28347,28343,28375,28340,28367,28303,28354,28319,28514,28486,28487,28452,28437,28409,28463,28470,28491,28532,28458,28425,28457,28553,28557,28556,28536,28530,28540,28538,28625,37642,37643,37644,37645,37646,37647,37648,37649,37650,37651,37652,37653,37654,37655,37656,37657,37658,37659,37660,37661,37662,37663,37664,37665,37666,37667,37668,37669,37670,37671,37672,37673,37674,37675,37676,37677,37678,37679,37680,37681,37682,37683,37684,37685,37686,37687,37688,37689,37690,37691,37692,37693,37695,37696,37697,37698,37699,37700,37701,37702,37703,37704,37705,37706,37707,37708,37709,37710,37711,37712,37713,37714,37715,37716,37717,37718,37719,37720,37721,37722,37723,37724,37725,37726,37727,37728,37729,37730,37731,37732,37733,37734,37735,37736,37737,37739,28617,28583,28601,28598,28610,28641,28654,28638,28640,28655,28698,28707,28699,28729,28725,28751,28766,23424,23428,23445,23443,23461,23480,29999,39582,25652,23524,23534,35120,23536,36423,35591,36790,36819,36821,36837,36846,36836,36841,36838,36851,36840,36869,36868,36875,36902,36881,36877,36886,36897,36917,36918,36909,36911,36932,36945,36946,36944,36968,36952,36962,36955,26297,36980,36989,36994,37e3,36995,37003,24400,24407,24406,24408,23611,21675,23632,23641,23409,23651,23654,32700,24362,24361,24365,33396,24380,39739,23662,22913,22915,22925,22953,22954,22947,37740,37741,37742,37743,37744,37745,37746,37747,37748,37749,37750,37751,37752,37753,37754,37755,37756,37757,37758,37759,37760,37761,37762,37763,37764,37765,37766,37767,37768,37769,37770,37771,37772,37773,37774,37776,37777,37778,37779,37780,37781,37782,37783,37784,37785,37786,37787,37788,37789,37790,37791,37792,37793,37794,37795,37796,37797,37798,37799,37800,37801,37802,37803,37804,37805,37806,37807,37808,37809,37810,37811,37812,37813,37814,37815,37816,37817,37818,37819,37820,37821,37822,37823,37824,37825,37826,37827,37828,37829,37830,37831,37832,37833,37835,37836,37837,22935,22986,22955,22942,22948,22994,22962,22959,22999,22974,23045,23046,23005,23048,23011,23e3,23033,23052,23049,23090,23092,23057,23075,23059,23104,23143,23114,23125,23100,23138,23157,33004,23210,23195,23159,23162,23230,23275,23218,23250,23252,23224,23264,23267,23281,23254,23270,23256,23260,23305,23319,23318,23346,23351,23360,23573,23580,23386,23397,23411,23377,23379,23394,39541,39543,39544,39546,39551,39549,39552,39553,39557,39560,39562,39568,39570,39571,39574,39576,39579,39580,39581,39583,39584,39586,39587,39589,39591,32415,32417,32419,32421,32424,32425,37838,37839,37840,37841,37842,37843,37844,37845,37847,37848,37849,37850,37851,37852,37853,37854,37855,37856,37857,37858,37859,37860,37861,37862,37863,37864,37865,37866,37867,37868,37869,37870,37871,37872,37873,37874,37875,37876,37877,37878,37879,37880,37881,37882,37883,37884,37885,37886,37887,37888,37889,37890,37891,37892,37893,37894,37895,37896,37897,37898,37899,37900,37901,37902,37903,37904,37905,37906,37907,37908,37909,37910,37911,37912,37913,37914,37915,37916,37917,37918,37919,37920,37921,37922,37923,37924,37925,37926,37927,37928,37929,37930,37931,37932,37933,37934,32429,32432,32446,32448,32449,32450,32457,32459,32460,32464,32468,32471,32475,32480,32481,32488,32491,32494,32495,32497,32498,32525,32502,32506,32507,32510,32513,32514,32515,32519,32520,32523,32524,32527,32529,32530,32535,32537,32540,32539,32543,32545,32546,32547,32548,32549,32550,32551,32554,32555,32556,32557,32559,32560,32561,32562,32563,32565,24186,30079,24027,30014,37013,29582,29585,29614,29602,29599,29647,29634,29649,29623,29619,29632,29641,29640,29669,29657,39036,29706,29673,29671,29662,29626,29682,29711,29738,29787,29734,29733,29736,29744,29742,29740,37935,37936,37937,37938,37939,37940,37941,37942,37943,37944,37945,37946,37947,37948,37949,37951,37952,37953,37954,37955,37956,37957,37958,37959,37960,37961,37962,37963,37964,37965,37966,37967,37968,37969,37970,37971,37972,37973,37974,37975,37976,37977,37978,37979,37980,37981,37982,37983,37984,37985,37986,37987,37988,37989,37990,37991,37992,37993,37994,37996,37997,37998,37999,38e3,38001,38002,38003,38004,38005,38006,38007,38008,38009,38010,38011,38012,38013,38014,38015,38016,38017,38018,38019,38020,38033,38038,38040,38087,38095,38099,38100,38106,38118,38139,38172,38176,29723,29722,29761,29788,29783,29781,29785,29815,29805,29822,29852,29838,29824,29825,29831,29835,29854,29864,29865,29840,29863,29906,29882,38890,38891,38892,26444,26451,26462,26440,26473,26533,26503,26474,26483,26520,26535,26485,26536,26526,26541,26507,26487,26492,26608,26633,26584,26634,26601,26544,26636,26585,26549,26586,26547,26589,26624,26563,26552,26594,26638,26561,26621,26674,26675,26720,26721,26702,26722,26692,26724,26755,26653,26709,26726,26689,26727,26688,26686,26698,26697,26665,26805,26767,26740,26743,26771,26731,26818,26990,26876,26911,26912,26873,38183,38195,38205,38211,38216,38219,38229,38234,38240,38254,38260,38261,38263,38264,38265,38266,38267,38268,38269,38270,38272,38273,38274,38275,38276,38277,38278,38279,38280,38281,38282,38283,38284,38285,38286,38287,38288,38289,38290,38291,38292,38293,38294,38295,38296,38297,38298,38299,38300,38301,38302,38303,38304,38305,38306,38307,38308,38309,38310,38311,38312,38313,38314,38315,38316,38317,38318,38319,38320,38321,38322,38323,38324,38325,38326,38327,38328,38329,38330,38331,38332,38333,38334,38335,38336,38337,38338,38339,38340,38341,38342,38343,38344,38345,38346,38347,26916,26864,26891,26881,26967,26851,26896,26993,26937,26976,26946,26973,27012,26987,27008,27032,27e3,26932,27084,27015,27016,27086,27017,26982,26979,27001,27035,27047,27067,27051,27053,27092,27057,27073,27082,27103,27029,27104,27021,27135,27183,27117,27159,27160,27237,27122,27204,27198,27296,27216,27227,27189,27278,27257,27197,27176,27224,27260,27281,27280,27305,27287,27307,29495,29522,27521,27522,27527,27524,27538,27539,27533,27546,27547,27553,27562,36715,36717,36721,36722,36723,36725,36726,36728,36727,36729,36730,36732,36734,36737,36738,36740,36743,36747,38348,38349,38350,38351,38352,38353,38354,38355,38356,38357,38358,38359,38360,38361,38362,38363,38364,38365,38366,38367,38368,38369,38370,38371,38372,38373,38374,38375,38380,38399,38407,38419,38424,38427,38430,38432,38435,38436,38437,38438,38439,38440,38441,38443,38444,38445,38447,38448,38455,38456,38457,38458,38462,38465,38467,38474,38478,38479,38481,38482,38483,38486,38487,38488,38489,38490,38492,38493,38494,38496,38499,38501,38502,38507,38509,38510,38511,38512,38513,38515,38520,38521,38522,38523,38524,38525,38526,38527,38528,38529,38530,38531,38532,38535,38537,38538,36749,36750,36751,36760,36762,36558,25099,25111,25115,25119,25122,25121,25125,25124,25132,33255,29935,29940,29951,29967,29969,29971,25908,26094,26095,26096,26122,26137,26482,26115,26133,26112,28805,26359,26141,26164,26161,26166,26165,32774,26207,26196,26177,26191,26198,26209,26199,26231,26244,26252,26279,26269,26302,26331,26332,26342,26345,36146,36147,36150,36155,36157,36160,36165,36166,36168,36169,36167,36173,36181,36185,35271,35274,35275,35276,35278,35279,35280,35281,29294,29343,29277,29286,29295,29310,29311,29316,29323,29325,29327,29330,25352,25394,25520,38540,38542,38545,38546,38547,38549,38550,38554,38555,38557,38558,38559,38560,38561,38562,38563,38564,38565,38566,38568,38569,38570,38571,38572,38573,38574,38575,38577,38578,38580,38581,38583,38584,38586,38587,38591,38594,38595,38600,38602,38603,38608,38609,38611,38612,38614,38615,38616,38617,38618,38619,38620,38621,38622,38623,38625,38626,38627,38628,38629,38630,38631,38635,38636,38637,38638,38640,38641,38642,38644,38645,38648,38650,38651,38652,38653,38655,38658,38659,38661,38666,38667,38668,38672,38673,38674,38676,38677,38679,38680,38681,38682,38683,38685,38687,38688,25663,25816,32772,27626,27635,27645,27637,27641,27653,27655,27654,27661,27669,27672,27673,27674,27681,27689,27684,27690,27698,25909,25941,25963,29261,29266,29270,29232,34402,21014,32927,32924,32915,32956,26378,32957,32945,32939,32941,32948,32951,32999,33e3,33001,33002,32987,32962,32964,32985,32973,32983,26384,32989,33003,33009,33012,33005,33037,33038,33010,33020,26389,33042,35930,33078,33054,33068,33048,33074,33096,33100,33107,33140,33113,33114,33137,33120,33129,33148,33149,33133,33127,22605,23221,33160,33154,33169,28373,33187,33194,33228,26406,33226,33211,38689,38690,38691,38692,38693,38694,38695,38696,38697,38699,38700,38702,38703,38705,38707,38708,38709,38710,38711,38714,38715,38716,38717,38719,38720,38721,38722,38723,38724,38725,38726,38727,38728,38729,38730,38731,38732,38733,38734,38735,38736,38737,38740,38741,38743,38744,38746,38748,38749,38751,38755,38756,38758,38759,38760,38762,38763,38764,38765,38766,38767,38768,38769,38770,38773,38775,38776,38777,38778,38779,38781,38782,38783,38784,38785,38786,38787,38788,38790,38791,38792,38793,38794,38796,38798,38799,38800,38803,38805,38806,38807,38809,38810,38811,38812,38813,33217,33190,27428,27447,27449,27459,27462,27481,39121,39122,39123,39125,39129,39130,27571,24384,27586,35315,26e3,40785,26003,26044,26054,26052,26051,26060,26062,26066,26070,28800,28828,28822,28829,28859,28864,28855,28843,28849,28904,28874,28944,28947,28950,28975,28977,29043,29020,29032,28997,29042,29002,29048,29050,29080,29107,29109,29096,29088,29152,29140,29159,29177,29213,29224,28780,28952,29030,29113,25150,25149,25155,25160,25161,31035,31040,31046,31049,31067,31068,31059,31066,31074,31063,31072,31087,31079,31098,31109,31114,31130,31143,31155,24529,24528,38814,38815,38817,38818,38820,38821,38822,38823,38824,38825,38826,38828,38830,38832,38833,38835,38837,38838,38839,38840,38841,38842,38843,38844,38845,38846,38847,38848,38849,38850,38851,38852,38853,38854,38855,38856,38857,38858,38859,38860,38861,38862,38863,38864,38865,38866,38867,38868,38869,38870,38871,38872,38873,38874,38875,38876,38877,38878,38879,38880,38881,38882,38883,38884,38885,38888,38894,38895,38896,38897,38898,38900,38903,38904,38905,38906,38907,38908,38909,38910,38911,38912,38913,38914,38915,38916,38917,38918,38919,38920,38921,38922,38923,38924,38925,38926,24636,24669,24666,24679,24641,24665,24675,24747,24838,24845,24925,25001,24989,25035,25041,25094,32896,32895,27795,27894,28156,30710,30712,30720,30729,30743,30744,30737,26027,30765,30748,30749,30777,30778,30779,30751,30780,30757,30764,30755,30761,30798,30829,30806,30807,30758,30800,30791,30796,30826,30875,30867,30874,30855,30876,30881,30883,30898,30905,30885,30932,30937,30921,30956,30962,30981,30964,30995,31012,31006,31028,40859,40697,40699,40700,30449,30468,30477,30457,30471,30472,30490,30498,30489,30509,30502,30517,30520,30544,30545,30535,30531,30554,30568,38927,38928,38929,38930,38931,38932,38933,38934,38935,38936,38937,38938,38939,38940,38941,38942,38943,38944,38945,38946,38947,38948,38949,38950,38951,38952,38953,38954,38955,38956,38957,38958,38959,38960,38961,38962,38963,38964,38965,38966,38967,38968,38969,38970,38971,38972,38973,38974,38975,38976,38977,38978,38979,38980,38981,38982,38983,38984,38985,38986,38987,38988,38989,38990,38991,38992,38993,38994,38995,38996,38997,38998,38999,39e3,39001,39002,39003,39004,39005,39006,39007,39008,39009,39010,39011,39012,39013,39014,39015,39016,39017,39018,39019,39020,39021,39022,30562,30565,30591,30605,30589,30592,30604,30609,30623,30624,30640,30645,30653,30010,30016,30030,30027,30024,30043,30066,30073,30083,32600,32609,32607,35400,32616,32628,32625,32633,32641,32638,30413,30437,34866,38021,38022,38023,38027,38026,38028,38029,38031,38032,38036,38039,38037,38042,38043,38044,38051,38052,38059,38058,38061,38060,38063,38064,38066,38068,38070,38071,38072,38073,38074,38076,38077,38079,38084,38088,38089,38090,38091,38092,38093,38094,38096,38097,38098,38101,38102,38103,38105,38104,38107,38110,38111,38112,38114,38116,38117,38119,38120,38122,39023,39024,39025,39026,39027,39028,39051,39054,39058,39061,39065,39075,39080,39081,39082,39083,39084,39085,39086,39087,39088,39089,39090,39091,39092,39093,39094,39095,39096,39097,39098,39099,39100,39101,39102,39103,39104,39105,39106,39107,39108,39109,39110,39111,39112,39113,39114,39115,39116,39117,39119,39120,39124,39126,39127,39131,39132,39133,39136,39137,39138,39139,39140,39141,39142,39145,39146,39147,39148,39149,39150,39151,39152,39153,39154,39155,39156,39157,39158,39159,39160,39161,39162,39163,39164,39165,39166,39167,39168,39169,39170,39171,39172,39173,39174,39175,38121,38123,38126,38127,38131,38132,38133,38135,38137,38140,38141,38143,38147,38146,38150,38151,38153,38154,38157,38158,38159,38162,38163,38164,38165,38166,38168,38171,38173,38174,38175,38178,38186,38187,38185,38188,38193,38194,38196,38198,38199,38200,38204,38206,38207,38210,38197,38212,38213,38214,38217,38220,38222,38223,38226,38227,38228,38230,38231,38232,38233,38235,38238,38239,38237,38241,38242,38244,38245,38246,38247,38248,38249,38250,38251,38252,38255,38257,38258,38259,38202,30695,30700,38601,31189,31213,31203,31211,31238,23879,31235,31234,31262,31252,39176,39177,39178,39179,39180,39182,39183,39185,39186,39187,39188,39189,39190,39191,39192,39193,39194,39195,39196,39197,39198,39199,39200,39201,39202,39203,39204,39205,39206,39207,39208,39209,39210,39211,39212,39213,39215,39216,39217,39218,39219,39220,39221,39222,39223,39224,39225,39226,39227,39228,39229,39230,39231,39232,39233,39234,39235,39236,39237,39238,39239,39240,39241,39242,39243,39244,39245,39246,39247,39248,39249,39250,39251,39254,39255,39256,39257,39258,39259,39260,39261,39262,39263,39264,39265,39266,39268,39270,39283,39288,39289,39291,39294,39298,39299,39305,31289,31287,31313,40655,39333,31344,30344,30350,30355,30361,30372,29918,29920,29996,40480,40482,40488,40489,40490,40491,40492,40498,40497,40502,40504,40503,40505,40506,40510,40513,40514,40516,40518,40519,40520,40521,40523,40524,40526,40529,40533,40535,40538,40539,40540,40542,40547,40550,40551,40552,40553,40554,40555,40556,40561,40557,40563,30098,30100,30102,30112,30109,30124,30115,30131,30132,30136,30148,30129,30128,30147,30146,30166,30157,30179,30184,30182,30180,30187,30183,30211,30193,30204,30207,30224,30208,30213,30220,30231,30218,30245,30232,30229,30233,39308,39310,39322,39323,39324,39325,39326,39327,39328,39329,39330,39331,39332,39334,39335,39337,39338,39339,39340,39341,39342,39343,39344,39345,39346,39347,39348,39349,39350,39351,39352,39353,39354,39355,39356,39357,39358,39359,39360,39361,39362,39363,39364,39365,39366,39367,39368,39369,39370,39371,39372,39373,39374,39375,39376,39377,39378,39379,39380,39381,39382,39383,39384,39385,39386,39387,39388,39389,39390,39391,39392,39393,39394,39395,39396,39397,39398,39399,39400,39401,39402,39403,39404,39405,39406,39407,39408,39409,39410,39411,39412,39413,39414,39415,39416,39417,30235,30268,30242,30240,30272,30253,30256,30271,30261,30275,30270,30259,30285,30302,30292,30300,30294,30315,30319,32714,31462,31352,31353,31360,31366,31368,31381,31398,31392,31404,31400,31405,31411,34916,34921,34930,34941,34943,34946,34978,35014,34999,35004,35017,35042,35022,35043,35045,35057,35098,35068,35048,35070,35056,35105,35097,35091,35099,35082,35124,35115,35126,35137,35174,35195,30091,32997,30386,30388,30684,32786,32788,32790,32796,32800,32802,32805,32806,32807,32809,32808,32817,32779,32821,32835,32838,32845,32850,32873,32881,35203,39032,39040,39043,39418,39419,39420,39421,39422,39423,39424,39425,39426,39427,39428,39429,39430,39431,39432,39433,39434,39435,39436,39437,39438,39439,39440,39441,39442,39443,39444,39445,39446,39447,39448,39449,39450,39451,39452,39453,39454,39455,39456,39457,39458,39459,39460,39461,39462,39463,39464,39465,39466,39467,39468,39469,39470,39471,39472,39473,39474,39475,39476,39477,39478,39479,39480,39481,39482,39483,39484,39485,39486,39487,39488,39489,39490,39491,39492,39493,39494,39495,39496,39497,39498,39499,39500,39501,39502,39503,39504,39505,39506,39507,39508,39509,39510,39511,39512,39513,39049,39052,39053,39055,39060,39066,39067,39070,39071,39073,39074,39077,39078,34381,34388,34412,34414,34431,34426,34428,34427,34472,34445,34443,34476,34461,34471,34467,34474,34451,34473,34486,34500,34485,34510,34480,34490,34481,34479,34505,34511,34484,34537,34545,34546,34541,34547,34512,34579,34526,34548,34527,34520,34513,34563,34567,34552,34568,34570,34573,34569,34595,34619,34590,34597,34606,34586,34622,34632,34612,34609,34601,34615,34623,34690,34594,34685,34686,34683,34656,34672,34636,34670,34699,34643,34659,34684,34660,34649,34661,34707,34735,34728,34770,39514,39515,39516,39517,39518,39519,39520,39521,39522,39523,39524,39525,39526,39527,39528,39529,39530,39531,39538,39555,39561,39565,39566,39572,39573,39577,39590,39593,39594,39595,39596,39597,39598,39599,39602,39603,39604,39605,39609,39611,39613,39614,39615,39619,39620,39622,39623,39624,39625,39626,39629,39630,39631,39632,39634,39636,39637,39638,39639,39641,39642,39643,39644,39645,39646,39648,39650,39651,39652,39653,39655,39656,39657,39658,39660,39662,39664,39665,39666,39667,39668,39669,39670,39671,39672,39674,39676,39677,39678,39679,39680,39681,39682,39684,39685,39686,34758,34696,34693,34733,34711,34691,34731,34789,34732,34741,34739,34763,34771,34749,34769,34752,34762,34779,34794,34784,34798,34838,34835,34814,34826,34843,34849,34873,34876,32566,32578,32580,32581,33296,31482,31485,31496,31491,31492,31509,31498,31531,31503,31559,31544,31530,31513,31534,31537,31520,31525,31524,31539,31550,31518,31576,31578,31557,31605,31564,31581,31584,31598,31611,31586,31602,31601,31632,31654,31655,31672,31660,31645,31656,31621,31658,31644,31650,31659,31668,31697,31681,31692,31709,31706,31717,31718,31722,31756,31742,31740,31759,31766,31755,39687,39689,39690,39691,39692,39693,39694,39696,39697,39698,39700,39701,39702,39703,39704,39705,39706,39707,39708,39709,39710,39712,39713,39714,39716,39717,39718,39719,39720,39721,39722,39723,39724,39725,39726,39728,39729,39731,39732,39733,39734,39735,39736,39737,39738,39741,39742,39743,39744,39750,39754,39755,39756,39758,39760,39762,39763,39765,39766,39767,39768,39769,39770,39771,39772,39773,39774,39775,39776,39777,39778,39779,39780,39781,39782,39783,39784,39785,39786,39787,39788,39789,39790,39791,39792,39793,39794,39795,39796,39797,39798,39799,39800,39801,39802,39803,31775,31786,31782,31800,31809,31808,33278,33281,33282,33284,33260,34884,33313,33314,33315,33325,33327,33320,33323,33336,33339,33331,33332,33342,33348,33353,33355,33359,33370,33375,33384,34942,34949,34952,35032,35039,35166,32669,32671,32679,32687,32688,32690,31868,25929,31889,31901,31900,31902,31906,31922,31932,31933,31937,31943,31948,31949,31944,31941,31959,31976,33390,26280,32703,32718,32725,32741,32737,32742,32745,32750,32755,31992,32119,32166,32174,32327,32411,40632,40628,36211,36228,36244,36241,36273,36199,36205,35911,35913,37194,37200,37198,37199,37220,39804,39805,39806,39807,39808,39809,39810,39811,39812,39813,39814,39815,39816,39817,39818,39819,39820,39821,39822,39823,39824,39825,39826,39827,39828,39829,39830,39831,39832,39833,39834,39835,39836,39837,39838,39839,39840,39841,39842,39843,39844,39845,39846,39847,39848,39849,39850,39851,39852,39853,39854,39855,39856,39857,39858,39859,39860,39861,39862,39863,39864,39865,39866,39867,39868,39869,39870,39871,39872,39873,39874,39875,39876,39877,39878,39879,39880,39881,39882,39883,39884,39885,39886,39887,39888,39889,39890,39891,39892,39893,39894,39895,39896,39897,39898,39899,37218,37217,37232,37225,37231,37245,37246,37234,37236,37241,37260,37253,37264,37261,37265,37282,37283,37290,37293,37294,37295,37301,37300,37306,35925,40574,36280,36331,36357,36441,36457,36277,36287,36284,36282,36292,36310,36311,36314,36318,36302,36303,36315,36294,36332,36343,36344,36323,36345,36347,36324,36361,36349,36372,36381,36383,36396,36398,36387,36399,36410,36416,36409,36405,36413,36401,36425,36417,36418,36433,36434,36426,36464,36470,36476,36463,36468,36485,36495,36500,36496,36508,36510,35960,35970,35978,35973,35992,35988,26011,35286,35294,35290,35292,39900,39901,39902,39903,39904,39905,39906,39907,39908,39909,39910,39911,39912,39913,39914,39915,39916,39917,39918,39919,39920,39921,39922,39923,39924,39925,39926,39927,39928,39929,39930,39931,39932,39933,39934,39935,39936,39937,39938,39939,39940,39941,39942,39943,39944,39945,39946,39947,39948,39949,39950,39951,39952,39953,39954,39955,39956,39957,39958,39959,39960,39961,39962,39963,39964,39965,39966,39967,39968,39969,39970,39971,39972,39973,39974,39975,39976,39977,39978,39979,39980,39981,39982,39983,39984,39985,39986,39987,39988,39989,39990,39991,39992,39993,39994,39995,35301,35307,35311,35390,35622,38739,38633,38643,38639,38662,38657,38664,38671,38670,38698,38701,38704,38718,40832,40835,40837,40838,40839,40840,40841,40842,40844,40702,40715,40717,38585,38588,38589,38606,38610,30655,38624,37518,37550,37576,37694,37738,37834,37775,37950,37995,40063,40066,40069,40070,40071,40072,31267,40075,40078,40080,40081,40082,40084,40085,40090,40091,40094,40095,40096,40097,40098,40099,40101,40102,40103,40104,40105,40107,40109,40110,40112,40113,40114,40115,40116,40117,40118,40119,40122,40123,40124,40125,40132,40133,40134,40135,40138,40139,39996,39997,39998,39999,4e4,40001,40002,40003,40004,40005,40006,40007,40008,40009,40010,40011,40012,40013,40014,40015,40016,40017,40018,40019,40020,40021,40022,40023,40024,40025,40026,40027,40028,40029,40030,40031,40032,40033,40034,40035,40036,40037,40038,40039,40040,40041,40042,40043,40044,40045,40046,40047,40048,40049,40050,40051,40052,40053,40054,40055,40056,40057,40058,40059,40061,40062,40064,40067,40068,40073,40074,40076,40079,40083,40086,40087,40088,40089,40093,40106,40108,40111,40121,40126,40127,40128,40129,40130,40136,40137,40145,40146,40154,40155,40160,40161,40140,40141,40142,40143,40144,40147,40148,40149,40151,40152,40153,40156,40157,40159,40162,38780,38789,38801,38802,38804,38831,38827,38819,38834,38836,39601,39600,39607,40536,39606,39610,39612,39617,39616,39621,39618,39627,39628,39633,39749,39747,39751,39753,39752,39757,39761,39144,39181,39214,39253,39252,39647,39649,39654,39663,39659,39675,39661,39673,39688,39695,39699,39711,39715,40637,40638,32315,40578,40583,40584,40587,40594,37846,40605,40607,40667,40668,40669,40672,40671,40674,40681,40679,40677,40682,40687,40738,40748,40751,40761,40759,40765,40766,40772,40163,40164,40165,40166,40167,40168,40169,40170,40171,40172,40173,40174,40175,40176,40177,40178,40179,40180,40181,40182,40183,40184,40185,40186,40187,40188,40189,40190,40191,40192,40193,40194,40195,40196,40197,40198,40199,40200,40201,40202,40203,40204,40205,40206,40207,40208,40209,40210,40211,40212,40213,40214,40215,40216,40217,40218,40219,40220,40221,40222,40223,40224,40225,40226,40227,40228,40229,40230,40231,40232,40233,40234,40235,40236,40237,40238,40239,40240,40241,40242,40243,40244,40245,40246,40247,40248,40249,40250,40251,40252,40253,40254,40255,40256,40257,40258,57908,57909,57910,57911,57912,57913,57914,57915,57916,57917,57918,57919,57920,57921,57922,57923,57924,57925,57926,57927,57928,57929,57930,57931,57932,57933,57934,57935,57936,57937,57938,57939,57940,57941,57942,57943,57944,57945,57946,57947,57948,57949,57950,57951,57952,57953,57954,57955,57956,57957,57958,57959,57960,57961,57962,57963,57964,57965,57966,57967,57968,57969,57970,57971,57972,57973,57974,57975,57976,57977,57978,57979,57980,57981,57982,57983,57984,57985,57986,57987,57988,57989,57990,57991,57992,57993,57994,57995,57996,57997,57998,57999,58e3,58001,40259,40260,40261,40262,40263,40264,40265,40266,40267,40268,40269,40270,40271,40272,40273,40274,40275,40276,40277,40278,40279,40280,40281,40282,40283,40284,40285,40286,40287,40288,40289,40290,40291,40292,40293,40294,40295,40296,40297,40298,40299,40300,40301,40302,40303,40304,40305,40306,40307,40308,40309,40310,40311,40312,40313,40314,40315,40316,40317,40318,40319,40320,40321,40322,40323,40324,40325,40326,40327,40328,40329,40330,40331,40332,40333,40334,40335,40336,40337,40338,40339,40340,40341,40342,40343,40344,40345,40346,40347,40348,40349,40350,40351,40352,40353,40354,58002,58003,58004,58005,58006,58007,58008,58009,58010,58011,58012,58013,58014,58015,58016,58017,58018,58019,58020,58021,58022,58023,58024,58025,58026,58027,58028,58029,58030,58031,58032,58033,58034,58035,58036,58037,58038,58039,58040,58041,58042,58043,58044,58045,58046,58047,58048,58049,58050,58051,58052,58053,58054,58055,58056,58057,58058,58059,58060,58061,58062,58063,58064,58065,58066,58067,58068,58069,58070,58071,58072,58073,58074,58075,58076,58077,58078,58079,58080,58081,58082,58083,58084,58085,58086,58087,58088,58089,58090,58091,58092,58093,58094,58095,40355,40356,40357,40358,40359,40360,40361,40362,40363,40364,40365,40366,40367,40368,40369,40370,40371,40372,40373,40374,40375,40376,40377,40378,40379,40380,40381,40382,40383,40384,40385,40386,40387,40388,40389,40390,40391,40392,40393,40394,40395,40396,40397,40398,40399,40400,40401,40402,40403,40404,40405,40406,40407,40408,40409,40410,40411,40412,40413,40414,40415,40416,40417,40418,40419,40420,40421,40422,40423,40424,40425,40426,40427,40428,40429,40430,40431,40432,40433,40434,40435,40436,40437,40438,40439,40440,40441,40442,40443,40444,40445,40446,40447,40448,40449,40450,58096,58097,58098,58099,58100,58101,58102,58103,58104,58105,58106,58107,58108,58109,58110,58111,58112,58113,58114,58115,58116,58117,58118,58119,58120,58121,58122,58123,58124,58125,58126,58127,58128,58129,58130,58131,58132,58133,58134,58135,58136,58137,58138,58139,58140,58141,58142,58143,58144,58145,58146,58147,58148,58149,58150,58151,58152,58153,58154,58155,58156,58157,58158,58159,58160,58161,58162,58163,58164,58165,58166,58167,58168,58169,58170,58171,58172,58173,58174,58175,58176,58177,58178,58179,58180,58181,58182,58183,58184,58185,58186,58187,58188,58189,40451,40452,40453,40454,40455,40456,40457,40458,40459,40460,40461,40462,40463,40464,40465,40466,40467,40468,40469,40470,40471,40472,40473,40474,40475,40476,40477,40478,40484,40487,40494,40496,40500,40507,40508,40512,40525,40528,40530,40531,40532,40534,40537,40541,40543,40544,40545,40546,40549,40558,40559,40562,40564,40565,40566,40567,40568,40569,40570,40571,40572,40573,40576,40577,40579,40580,40581,40582,40585,40586,40588,40589,40590,40591,40592,40593,40596,40597,40598,40599,40600,40601,40602,40603,40604,40606,40608,40609,40610,40611,40612,40613,40615,40616,40617,40618,58190,58191,58192,58193,58194,58195,58196,58197,58198,58199,58200,58201,58202,58203,58204,58205,58206,58207,58208,58209,58210,58211,58212,58213,58214,58215,58216,58217,58218,58219,58220,58221,58222,58223,58224,58225,58226,58227,58228,58229,58230,58231,58232,58233,58234,58235,58236,58237,58238,58239,58240,58241,58242,58243,58244,58245,58246,58247,58248,58249,58250,58251,58252,58253,58254,58255,58256,58257,58258,58259,58260,58261,58262,58263,58264,58265,58266,58267,58268,58269,58270,58271,58272,58273,58274,58275,58276,58277,58278,58279,58280,58281,58282,58283,40619,40620,40621,40622,40623,40624,40625,40626,40627,40629,40630,40631,40633,40634,40636,40639,40640,40641,40642,40643,40645,40646,40647,40648,40650,40651,40652,40656,40658,40659,40661,40662,40663,40665,40666,40670,40673,40675,40676,40678,40680,40683,40684,40685,40686,40688,40689,40690,40691,40692,40693,40694,40695,40696,40698,40701,40703,40704,40705,40706,40707,40708,40709,40710,40711,40712,40713,40714,40716,40719,40721,40722,40724,40725,40726,40728,40730,40731,40732,40733,40734,40735,40737,40739,40740,40741,40742,40743,40744,40745,40746,40747,40749,40750,40752,40753,58284,58285,58286,58287,58288,58289,58290,58291,58292,58293,58294,58295,58296,58297,58298,58299,58300,58301,58302,58303,58304,58305,58306,58307,58308,58309,58310,58311,58312,58313,58314,58315,58316,58317,58318,58319,58320,58321,58322,58323,58324,58325,58326,58327,58328,58329,58330,58331,58332,58333,58334,58335,58336,58337,58338,58339,58340,58341,58342,58343,58344,58345,58346,58347,58348,58349,58350,58351,58352,58353,58354,58355,58356,58357,58358,58359,58360,58361,58362,58363,58364,58365,58366,58367,58368,58369,58370,58371,58372,58373,58374,58375,58376,58377,40754,40755,40756,40757,40758,40760,40762,40764,40767,40768,40769,40770,40771,40773,40774,40775,40776,40777,40778,40779,40780,40781,40782,40783,40786,40787,40788,40789,40790,40791,40792,40793,40794,40795,40796,40797,40798,40799,40800,40801,40802,40803,40804,40805,40806,40807,40808,40809,40810,40811,40812,40813,40814,40815,40816,40817,40818,40819,40820,40821,40822,40823,40824,40825,40826,40827,40828,40829,40830,40833,40834,40845,40846,40847,40848,40849,40850,40851,40852,40853,40854,40855,40856,40860,40861,40862,40865,40866,40867,40868,40869,63788,63865,63893,63975,63985,58378,58379,58380,58381,58382,58383,58384,58385,58386,58387,58388,58389,58390,58391,58392,58393,58394,58395,58396,58397,58398,58399,58400,58401,58402,58403,58404,58405,58406,58407,58408,58409,58410,58411,58412,58413,58414,58415,58416,58417,58418,58419,58420,58421,58422,58423,58424,58425,58426,58427,58428,58429,58430,58431,58432,58433,58434,58435,58436,58437,58438,58439,58440,58441,58442,58443,58444,58445,58446,58447,58448,58449,58450,58451,58452,58453,58454,58455,58456,58457,58458,58459,58460,58461,58462,58463,58464,58465,58466,58467,58468,58469,58470,58471,64012,64013,64014,64015,64017,64019,64020,64024,64031,64032,64033,64035,64036,64039,64040,64041,11905,59414,59415,59416,11908,13427,13383,11912,11915,59422,13726,13850,13838,11916,11927,14702,14616,59430,14799,14815,14963,14800,59435,59436,15182,15470,15584,11943,59441,59442,11946,16470,16735,11950,17207,11955,11958,11959,59451,17329,17324,11963,17373,17622,18017,17996,59459,18211,18217,18300,18317,11978,18759,18810,18813,18818,18819,18821,18822,18847,18843,18871,18870,59476,59477,19619,19615,19616,19617,19575,19618,19731,19732,19733,19734,19735,19736,19737,19886,59492,58472,58473,58474,58475,58476,58477,58478,58479,58480,58481,58482,58483,58484,58485,58486,58487,58488,58489,58490,58491,58492,58493,58494,58495,58496,58497,58498,58499,58500,58501,58502,58503,58504,58505,58506,58507,58508,58509,58510,58511,58512,58513,58514,58515,58516,58517,58518,58519,58520,58521,58522,58523,58524,58525,58526,58527,58528,58529,58530,58531,58532,58533,58534,58535,58536,58537,58538,58539,58540,58541,58542,58543,58544,58545,58546,58547,58548,58549,58550,58551,58552,58553,58554,58555,58556,58557,58558,58559,58560,58561,58562,58563,58564,58565],"gb18030-ranges":[[0,128],[36,165],[38,169],[45,178],[50,184],[81,216],[89,226],[95,235],[96,238],[100,244],[103,248],[104,251],[105,253],[109,258],[126,276],[133,284],[148,300],[172,325],[175,329],[179,334],[208,364],[306,463],[307,465],[308,467],[309,469],[310,471],[311,473],[312,475],[313,477],[341,506],[428,594],[443,610],[544,712],[545,716],[558,730],[741,930],[742,938],[749,962],[750,970],[805,1026],[819,1104],[820,1106],[7922,8209],[7924,8215],[7925,8218],[7927,8222],[7934,8231],[7943,8241],[7944,8244],[7945,8246],[7950,8252],[8062,8365],[8148,8452],[8149,8454],[8152,8458],[8164,8471],[8174,8482],[8236,8556],[8240,8570],[8262,8596],[8264,8602],[8374,8713],[8380,8720],[8381,8722],[8384,8726],[8388,8731],[8390,8737],[8392,8740],[8393,8742],[8394,8748],[8396,8751],[8401,8760],[8406,8766],[8416,8777],[8419,8781],[8424,8787],[8437,8802],[8439,8808],[8445,8816],[8482,8854],[8485,8858],[8496,8870],[8521,8896],[8603,8979],[8936,9322],[8946,9372],[9046,9548],[9050,9588],[9063,9616],[9066,9622],[9076,9634],[9092,9652],[9100,9662],[9108,9672],[9111,9676],[9113,9680],[9131,9702],[9162,9735],[9164,9738],[9218,9793],[9219,9795],[11329,11906],[11331,11909],[11334,11913],[11336,11917],[11346,11928],[11361,11944],[11363,11947],[11366,11951],[11370,11956],[11372,11960],[11375,11964],[11389,11979],[11682,12284],[11686,12292],[11687,12312],[11692,12319],[11694,12330],[11714,12351],[11716,12436],[11723,12447],[11725,12535],[11730,12543],[11736,12586],[11982,12842],[11989,12850],[12102,12964],[12336,13200],[12348,13215],[12350,13218],[12384,13253],[12393,13263],[12395,13267],[12397,13270],[12510,13384],[12553,13428],[12851,13727],[12962,13839],[12973,13851],[13738,14617],[13823,14703],[13919,14801],[13933,14816],[14080,14964],[14298,15183],[14585,15471],[14698,15585],[15583,16471],[15847,16736],[16318,17208],[16434,17325],[16438,17330],[16481,17374],[16729,17623],[17102,17997],[17122,18018],[17315,18212],[17320,18218],[17402,18301],[17418,18318],[17859,18760],[17909,18811],[17911,18814],[17915,18820],[17916,18823],[17936,18844],[17939,18848],[17961,18872],[18664,19576],[18703,19620],[18814,19738],[18962,19887],[19043,40870],[33469,59244],[33470,59336],[33471,59367],[33484,59413],[33485,59417],[33490,59423],[33497,59431],[33501,59437],[33505,59443],[33513,59452],[33520,59460],[33536,59478],[33550,59493],[37845,63789],[37921,63866],[37948,63894],[38029,63976],[38038,63986],[38064,64016],[38065,64018],[38066,64021],[38069,64025],[38075,64034],[38076,64037],[38078,64042],[39108,65074],[39109,65093],[39113,65107],[39114,65112],[39115,65127],[39116,65132],[39265,65375],[39394,65510],[189e3,65536]],jis0208:[12288,12289,12290,65292,65294,12539,65306,65307,65311,65281,12443,12444,180,65344,168,65342,65507,65343,12541,12542,12445,12446,12291,20189,12293,12294,12295,12540,8213,8208,65295,65340,65374,8741,65372,8230,8229,8216,8217,8220,8221,65288,65289,12308,12309,65339,65341,65371,65373,12296,12297,12298,12299,12300,12301,12302,12303,12304,12305,65291,65293,177,215,247,65309,8800,65308,65310,8806,8807,8734,8756,9794,9792,176,8242,8243,8451,65509,65284,65504,65505,65285,65283,65286,65290,65312,167,9734,9733,9675,9679,9678,9671,9670,9633,9632,9651,9650,9661,9660,8251,12306,8594,8592,8593,8595,12307,null,null,null,null,null,null,null,null,null,null,null,8712,8715,8838,8839,8834,8835,8746,8745,null,null,null,null,null,null,null,null,8743,8744,65506,8658,8660,8704,8707,null,null,null,null,null,null,null,null,null,null,null,8736,8869,8978,8706,8711,8801,8786,8810,8811,8730,8765,8733,8757,8747,8748,null,null,null,null,null,null,null,8491,8240,9839,9837,9834,8224,8225,182,null,null,null,null,9711,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,65296,65297,65298,65299,65300,65301,65302,65303,65304,65305,null,null,null,null,null,null,null,65313,65314,65315,65316,65317,65318,65319,65320,65321,65322,65323,65324,65325,65326,65327,65328,65329,65330,65331,65332,65333,65334,65335,65336,65337,65338,null,null,null,null,null,null,65345,65346,65347,65348,65349,65350,65351,65352,65353,65354,65355,65356,65357,65358,65359,65360,65361,65362,65363,65364,65365,65366,65367,65368,65369,65370,null,null,null,null,12353,12354,12355,12356,12357,12358,12359,12360,12361,12362,12363,12364,12365,12366,12367,12368,12369,12370,12371,12372,12373,12374,12375,12376,12377,12378,12379,12380,12381,12382,12383,12384,12385,12386,12387,12388,12389,12390,12391,12392,12393,12394,12395,12396,12397,12398,12399,12400,12401,12402,12403,12404,12405,12406,12407,12408,12409,12410,12411,12412,12413,12414,12415,12416,12417,12418,12419,12420,12421,12422,12423,12424,12425,12426,12427,12428,12429,12430,12431,12432,12433,12434,12435,null,null,null,null,null,null,null,null,null,null,null,12449,12450,12451,12452,12453,12454,12455,12456,12457,12458,12459,12460,12461,12462,12463,12464,12465,12466,12467,12468,12469,12470,12471,12472,12473,12474,12475,12476,12477,12478,12479,12480,12481,12482,12483,12484,12485,12486,12487,12488,12489,12490,12491,12492,12493,12494,12495,12496,12497,12498,12499,12500,12501,12502,12503,12504,12505,12506,12507,12508,12509,12510,12511,12512,12513,12514,12515,12516,12517,12518,12519,12520,12521,12522,12523,12524,12525,12526,12527,12528,12529,12530,12531,12532,12533,12534,null,null,null,null,null,null,null,null,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,931,932,933,934,935,936,937,null,null,null,null,null,null,null,null,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,963,964,965,966,967,968,969,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,1040,1041,1042,1043,1044,1045,1025,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,1072,1073,1074,1075,1076,1077,1105,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,null,null,null,null,null,null,null,null,null,null,null,null,null,9472,9474,9484,9488,9496,9492,9500,9516,9508,9524,9532,9473,9475,9487,9491,9499,9495,9507,9523,9515,9531,9547,9504,9519,9512,9527,9535,9501,9520,9509,9528,9538,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,9312,9313,9314,9315,9316,9317,9318,9319,9320,9321,9322,9323,9324,9325,9326,9327,9328,9329,9330,9331,8544,8545,8546,8547,8548,8549,8550,8551,8552,8553,null,13129,13076,13090,13133,13080,13095,13059,13110,13137,13143,13069,13094,13091,13099,13130,13115,13212,13213,13214,13198,13199,13252,13217,null,null,null,null,null,null,null,null,13179,12317,12319,8470,13261,8481,12964,12965,12966,12967,12968,12849,12850,12857,13182,13181,13180,8786,8801,8747,8750,8721,8730,8869,8736,8735,8895,8757,8745,8746,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,20124,21782,23043,38463,21696,24859,25384,23030,36898,33909,33564,31312,24746,25569,28197,26093,33894,33446,39925,26771,22311,26017,25201,23451,22992,34427,39156,32098,32190,39822,25110,31903,34999,23433,24245,25353,26263,26696,38343,38797,26447,20197,20234,20301,20381,20553,22258,22839,22996,23041,23561,24799,24847,24944,26131,26885,28858,30031,30064,31227,32173,32239,32963,33806,34915,35586,36949,36986,21307,20117,20133,22495,32946,37057,30959,19968,22769,28322,36920,31282,33576,33419,39983,20801,21360,21693,21729,22240,23035,24341,39154,28139,32996,34093,38498,38512,38560,38907,21515,21491,23431,28879,32701,36802,38632,21359,40284,31418,19985,30867,33276,28198,22040,21764,27421,34074,39995,23013,21417,28006,29916,38287,22082,20113,36939,38642,33615,39180,21473,21942,23344,24433,26144,26355,26628,27704,27891,27945,29787,30408,31310,38964,33521,34907,35424,37613,28082,30123,30410,39365,24742,35585,36234,38322,27022,21421,20870,22290,22576,22852,23476,24310,24616,25513,25588,27839,28436,28814,28948,29017,29141,29503,32257,33398,33489,34199,36960,37467,40219,22633,26044,27738,29989,20985,22830,22885,24448,24540,25276,26106,27178,27431,27572,29579,32705,35158,40236,40206,40644,23713,27798,33659,20740,23627,25014,33222,26742,29281,20057,20474,21368,24681,28201,31311,38899,19979,21270,20206,20309,20285,20385,20339,21152,21487,22025,22799,23233,23478,23521,31185,26247,26524,26550,27468,27827,28779,29634,31117,31166,31292,31623,33457,33499,33540,33655,33775,33747,34662,35506,22057,36008,36838,36942,38686,34442,20420,23784,25105,29273,30011,33253,33469,34558,36032,38597,39187,39381,20171,20250,35299,22238,22602,22730,24315,24555,24618,24724,24674,25040,25106,25296,25913,39745,26214,26800,28023,28784,30028,30342,32117,33445,34809,38283,38542,35997,20977,21182,22806,21683,23475,23830,24936,27010,28079,30861,33995,34903,35442,37799,39608,28012,39336,34521,22435,26623,34510,37390,21123,22151,21508,24275,25313,25785,26684,26680,27579,29554,30906,31339,35226,35282,36203,36611,37101,38307,38548,38761,23398,23731,27005,38989,38990,25499,31520,27179,27263,26806,39949,28511,21106,21917,24688,25324,27963,28167,28369,33883,35088,36676,19988,39993,21494,26907,27194,38788,26666,20828,31427,33970,37340,37772,22107,40232,26658,33541,33841,31909,21e3,33477,29926,20094,20355,20896,23506,21002,21208,21223,24059,21914,22570,23014,23436,23448,23515,24178,24185,24739,24863,24931,25022,25563,25954,26577,26707,26874,27454,27475,27735,28450,28567,28485,29872,29976,30435,30475,31487,31649,31777,32233,32566,32752,32925,33382,33694,35251,35532,36011,36996,37969,38291,38289,38306,38501,38867,39208,33304,20024,21547,23736,24012,29609,30284,30524,23721,32747,36107,38593,38929,38996,39e3,20225,20238,21361,21916,22120,22522,22855,23305,23492,23696,24076,24190,24524,25582,26426,26071,26082,26399,26827,26820,27231,24112,27589,27671,27773,30079,31048,23395,31232,32e3,24509,35215,35352,36020,36215,36556,36637,39138,39438,39740,20096,20605,20736,22931,23452,25135,25216,25836,27450,29344,30097,31047,32681,34811,35516,35696,25516,33738,38816,21513,21507,21931,26708,27224,35440,30759,26485,40653,21364,23458,33050,34384,36870,19992,20037,20167,20241,21450,21560,23470,24339,24613,25937,26429,27714,27762,27875,28792,29699,31350,31406,31496,32026,31998,32102,26087,29275,21435,23621,24040,25298,25312,25369,28192,34394,35377,36317,37624,28417,31142,39770,20136,20139,20140,20379,20384,20689,20807,31478,20849,20982,21332,21281,21375,21483,21932,22659,23777,24375,24394,24623,24656,24685,25375,25945,27211,27841,29378,29421,30703,33016,33029,33288,34126,37111,37857,38911,39255,39514,20208,20957,23597,26241,26989,23616,26354,26997,29577,26704,31873,20677,21220,22343,24062,37670,26020,27427,27453,29748,31105,31165,31563,32202,33465,33740,34943,35167,35641,36817,37329,21535,37504,20061,20534,21477,21306,29399,29590,30697,33510,36527,39366,39368,39378,20855,24858,34398,21936,31354,20598,23507,36935,38533,20018,27355,37351,23633,23624,25496,31391,27795,38772,36705,31402,29066,38536,31874,26647,32368,26705,37740,21234,21531,34219,35347,32676,36557,37089,21350,34952,31041,20418,20670,21009,20804,21843,22317,29674,22411,22865,24418,24452,24693,24950,24935,25001,25522,25658,25964,26223,26690,28179,30054,31293,31995,32076,32153,32331,32619,33550,33610,34509,35336,35427,35686,36605,38938,40335,33464,36814,39912,21127,25119,25731,28608,38553,26689,20625,27424,27770,28500,31348,32080,34880,35363,26376,20214,20537,20518,20581,20860,21048,21091,21927,22287,22533,23244,24314,25010,25080,25331,25458,26908,27177,29309,29356,29486,30740,30831,32121,30476,32937,35211,35609,36066,36562,36963,37749,38522,38997,39443,40568,20803,21407,21427,24187,24358,28187,28304,29572,29694,32067,33335,35328,35578,38480,20046,20491,21476,21628,22266,22993,23396,24049,24235,24359,25144,25925,26543,28246,29392,31946,34996,32929,32993,33776,34382,35463,36328,37431,38599,39015,40723,20116,20114,20237,21320,21577,21566,23087,24460,24481,24735,26791,27278,29786,30849,35486,35492,35703,37264,20062,39881,20132,20348,20399,20505,20502,20809,20844,21151,21177,21246,21402,21475,21521,21518,21897,22353,22434,22909,23380,23389,23439,24037,24039,24055,24184,24195,24218,24247,24344,24658,24908,25239,25304,25511,25915,26114,26179,26356,26477,26657,26775,27083,27743,27946,28009,28207,28317,30002,30343,30828,31295,31968,32005,32024,32094,32177,32789,32771,32943,32945,33108,33167,33322,33618,34892,34913,35611,36002,36092,37066,37237,37489,30783,37628,38308,38477,38917,39321,39640,40251,21083,21163,21495,21512,22741,25335,28640,35946,36703,40633,20811,21051,21578,22269,31296,37239,40288,40658,29508,28425,33136,29969,24573,24794,39592,29403,36796,27492,38915,20170,22256,22372,22718,23130,24680,25031,26127,26118,26681,26801,28151,30165,32058,33390,39746,20123,20304,21449,21766,23919,24038,24046,26619,27801,29811,30722,35408,37782,35039,22352,24231,25387,20661,20652,20877,26368,21705,22622,22971,23472,24425,25165,25505,26685,27507,28168,28797,37319,29312,30741,30758,31085,25998,32048,33756,35009,36617,38555,21092,22312,26448,32618,36001,20916,22338,38442,22586,27018,32948,21682,23822,22524,30869,40442,20316,21066,21643,25662,26152,26388,26613,31364,31574,32034,37679,26716,39853,31545,21273,20874,21047,23519,25334,25774,25830,26413,27578,34217,38609,30352,39894,25420,37638,39851,30399,26194,19977,20632,21442,23665,24808,25746,25955,26719,29158,29642,29987,31639,32386,34453,35715,36059,37240,39184,26028,26283,27531,20181,20180,20282,20351,21050,21496,21490,21987,22235,22763,22987,22985,23039,23376,23629,24066,24107,24535,24605,25351,25903,23388,26031,26045,26088,26525,27490,27515,27663,29509,31049,31169,31992,32025,32043,32930,33026,33267,35222,35422,35433,35430,35468,35566,36039,36060,38604,39164,27503,20107,20284,20365,20816,23383,23546,24904,25345,26178,27425,28363,27835,29246,29885,30164,30913,31034,32780,32819,33258,33940,36766,27728,40575,24335,35672,40235,31482,36600,23437,38635,19971,21489,22519,22833,23241,23460,24713,28287,28422,30142,36074,23455,34048,31712,20594,26612,33437,23649,34122,32286,33294,20889,23556,25448,36198,26012,29038,31038,32023,32773,35613,36554,36974,34503,37034,20511,21242,23610,26451,28796,29237,37196,37320,37675,33509,23490,24369,24825,20027,21462,23432,25163,26417,27530,29417,29664,31278,33131,36259,37202,39318,20754,21463,21610,23551,25480,27193,32172,38656,22234,21454,21608,23447,23601,24030,20462,24833,25342,27954,31168,31179,32066,32333,32722,33261,33311,33936,34886,35186,35728,36468,36655,36913,37195,37228,38598,37276,20160,20303,20805,21313,24467,25102,26580,27713,28171,29539,32294,37325,37507,21460,22809,23487,28113,31069,32302,31899,22654,29087,20986,34899,36848,20426,23803,26149,30636,31459,33308,39423,20934,24490,26092,26991,27529,28147,28310,28516,30462,32020,24033,36981,37255,38918,20966,21021,25152,26257,26329,28186,24246,32210,32626,26360,34223,34295,35576,21161,21465,22899,24207,24464,24661,37604,38500,20663,20767,21213,21280,21319,21484,21736,21830,21809,22039,22888,22974,23100,23477,23558,23567,23569,23578,24196,24202,24288,24432,25215,25220,25307,25484,25463,26119,26124,26157,26230,26494,26786,27167,27189,27836,28040,28169,28248,28988,28966,29031,30151,30465,30813,30977,31077,31216,31456,31505,31911,32057,32918,33750,33931,34121,34909,35059,35359,35388,35412,35443,35937,36062,37284,37478,37758,37912,38556,38808,19978,19976,19998,20055,20887,21104,22478,22580,22732,23330,24120,24773,25854,26465,26454,27972,29366,30067,31331,33976,35698,37304,37664,22065,22516,39166,25325,26893,27542,29165,32340,32887,33394,35302,39135,34645,36785,23611,20280,20449,20405,21767,23072,23517,23529,24515,24910,25391,26032,26187,26862,27035,28024,28145,30003,30137,30495,31070,31206,32051,33251,33455,34218,35242,35386,36523,36763,36914,37341,38663,20154,20161,20995,22645,22764,23563,29978,23613,33102,35338,36805,38499,38765,31525,35535,38920,37218,22259,21416,36887,21561,22402,24101,25512,27700,28810,30561,31883,32736,34928,36930,37204,37648,37656,38543,29790,39620,23815,23913,25968,26530,36264,38619,25454,26441,26905,33733,38935,38592,35070,28548,25722,23544,19990,28716,30045,26159,20932,21046,21218,22995,24449,24615,25104,25919,25972,26143,26228,26866,26646,27491,28165,29298,29983,30427,31934,32854,22768,35069,35199,35488,35475,35531,36893,37266,38738,38745,25993,31246,33030,38587,24109,24796,25114,26021,26132,26512,30707,31309,31821,32318,33034,36012,36196,36321,36447,30889,20999,25305,25509,25666,25240,35373,31363,31680,35500,38634,32118,33292,34633,20185,20808,21315,21344,23459,23554,23574,24029,25126,25159,25776,26643,26676,27849,27973,27927,26579,28508,29006,29053,26059,31359,31661,32218,32330,32680,33146,33307,33337,34214,35438,36046,36341,36984,36983,37549,37521,38275,39854,21069,21892,28472,28982,20840,31109,32341,33203,31950,22092,22609,23720,25514,26366,26365,26970,29401,30095,30094,30990,31062,31199,31895,32032,32068,34311,35380,38459,36961,40736,20711,21109,21452,21474,20489,21930,22766,22863,29245,23435,23652,21277,24803,24819,25436,25475,25407,25531,25805,26089,26361,24035,27085,27133,28437,29157,20105,30185,30456,31379,31967,32207,32156,32865,33609,33624,33900,33980,34299,35013,36208,36865,36973,37783,38684,39442,20687,22679,24974,33235,34101,36104,36896,20419,20596,21063,21363,24687,25417,26463,28204,36275,36895,20439,23646,36042,26063,32154,21330,34966,20854,25539,23384,23403,23562,25613,26449,36956,20182,22810,22826,27760,35409,21822,22549,22949,24816,25171,26561,33333,26965,38464,39364,39464,20307,22534,23550,32784,23729,24111,24453,24608,24907,25140,26367,27888,28382,32974,33151,33492,34955,36024,36864,36910,38538,40667,39899,20195,21488,22823,31532,37261,38988,40441,28381,28711,21331,21828,23429,25176,25246,25299,27810,28655,29730,35351,37944,28609,35582,33592,20967,34552,21482,21481,20294,36948,36784,22890,33073,24061,31466,36799,26842,35895,29432,40008,27197,35504,20025,21336,22022,22374,25285,25506,26086,27470,28129,28251,28845,30701,31471,31658,32187,32829,32966,34507,35477,37723,22243,22727,24382,26029,26262,27264,27573,30007,35527,20516,30693,22320,24347,24677,26234,27744,30196,31258,32622,33268,34584,36933,39347,31689,30044,31481,31569,33988,36880,31209,31378,33590,23265,30528,20013,20210,23449,24544,25277,26172,26609,27880,34411,34935,35387,37198,37619,39376,27159,28710,29482,33511,33879,36015,19969,20806,20939,21899,23541,24086,24115,24193,24340,24373,24427,24500,25074,25361,26274,26397,28526,29266,30010,30522,32884,33081,33144,34678,35519,35548,36229,36339,37530,38263,38914,40165,21189,25431,30452,26389,27784,29645,36035,37806,38515,27941,22684,26894,27084,36861,37786,30171,36890,22618,26626,25524,27131,20291,28460,26584,36795,34086,32180,37716,26943,28528,22378,22775,23340,32044,29226,21514,37347,40372,20141,20302,20572,20597,21059,35998,21576,22564,23450,24093,24213,24237,24311,24351,24716,25269,25402,25552,26799,27712,30855,31118,31243,32224,33351,35330,35558,36420,36883,37048,37165,37336,40718,27877,25688,25826,25973,28404,30340,31515,36969,37841,28346,21746,24505,25764,36685,36845,37444,20856,22635,22825,23637,24215,28155,32399,29980,36028,36578,39003,28857,20253,27583,28593,3e4,38651,20814,21520,22581,22615,22956,23648,24466,26007,26460,28193,30331,33759,36077,36884,37117,37709,30757,30778,21162,24230,22303,22900,24594,20498,20826,20908,20941,20992,21776,22612,22616,22871,23445,23798,23947,24764,25237,25645,26481,26691,26812,26847,30423,28120,28271,28059,28783,29128,24403,30168,31095,31561,31572,31570,31958,32113,21040,33891,34153,34276,35342,35588,35910,36367,36867,36879,37913,38518,38957,39472,38360,20685,21205,21516,22530,23566,24999,25758,27934,30643,31461,33012,33796,36947,37509,23776,40199,21311,24471,24499,28060,29305,30563,31167,31716,27602,29420,35501,26627,27233,20984,31361,26932,23626,40182,33515,23493,37193,28702,22136,23663,24775,25958,27788,35930,36929,38931,21585,26311,37389,22856,37027,20869,20045,20970,34201,35598,28760,25466,37707,26978,39348,32260,30071,21335,26976,36575,38627,27741,20108,23612,24336,36841,21250,36049,32905,34425,24319,26085,20083,20837,22914,23615,38894,20219,22922,24525,35469,28641,31152,31074,23527,33905,29483,29105,24180,24565,25467,25754,29123,31896,20035,24316,20043,22492,22178,24745,28611,32013,33021,33075,33215,36786,35223,34468,24052,25226,25773,35207,26487,27874,27966,29750,30772,23110,32629,33453,39340,20467,24259,25309,25490,25943,26479,30403,29260,32972,32954,36649,37197,20493,22521,23186,26757,26995,29028,29437,36023,22770,36064,38506,36889,34687,31204,30695,33833,20271,21093,21338,25293,26575,27850,30333,31636,31893,33334,34180,36843,26333,28448,29190,32283,33707,39361,40614,20989,31665,30834,31672,32903,31560,27368,24161,32908,30033,30048,20843,37474,28300,30330,37271,39658,20240,32624,25244,31567,38309,40169,22138,22617,34532,38588,20276,21028,21322,21453,21467,24070,25644,26001,26495,27710,27726,29256,29359,29677,30036,32321,33324,34281,36009,31684,37318,29033,38930,39151,25405,26217,30058,30436,30928,34115,34542,21290,21329,21542,22915,24199,24444,24754,25161,25209,25259,26e3,27604,27852,30130,30382,30865,31192,32203,32631,32933,34987,35513,36027,36991,38750,39131,27147,31800,20633,23614,24494,26503,27608,29749,30473,32654,40763,26570,31255,21305,30091,39661,24422,33181,33777,32920,24380,24517,30050,31558,36924,26727,23019,23195,32016,30334,35628,20469,24426,27161,27703,28418,29922,31080,34920,35413,35961,24287,25551,30149,31186,33495,37672,37618,33948,34541,39981,21697,24428,25996,27996,28693,36007,36051,38971,25935,29942,19981,20184,22496,22827,23142,23500,20904,24067,24220,24598,25206,25975,26023,26222,28014,29238,31526,33104,33178,33433,35676,36e3,36070,36212,38428,38468,20398,25771,27494,33310,33889,34154,37096,23553,26963,39080,33914,34135,20239,21103,24489,24133,26381,31119,33145,35079,35206,28149,24343,25173,27832,20175,29289,39826,20998,21563,22132,22707,24996,25198,28954,22894,31881,31966,32027,38640,25991,32862,19993,20341,20853,22592,24163,24179,24330,26564,20006,34109,38281,38491,31859,38913,20731,22721,30294,30887,21029,30629,34065,31622,20559,22793,29255,31687,32232,36794,36820,36941,20415,21193,23081,24321,38829,20445,33303,37610,22275,25429,27497,29995,35036,36628,31298,21215,22675,24917,25098,26286,27597,31807,33769,20515,20472,21253,21574,22577,22857,23453,23792,23791,23849,24214,25265,25447,25918,26041,26379,27861,27873,28921,30770,32299,32990,33459,33804,34028,34562,35090,35370,35914,37030,37586,39165,40179,40300,20047,20129,20621,21078,22346,22952,24125,24536,24537,25151,26292,26395,26576,26834,20882,32033,32938,33192,35584,35980,36031,37502,38450,21536,38956,21271,20693,21340,22696,25778,26420,29287,30566,31302,37350,21187,27809,27526,22528,24140,22868,26412,32763,20961,30406,25705,30952,39764,40635,22475,22969,26151,26522,27598,21737,27097,24149,33180,26517,39850,26622,40018,26717,20134,20451,21448,25273,26411,27819,36804,20397,32365,40639,19975,24930,28288,28459,34067,21619,26410,39749,24051,31637,23724,23494,34588,28234,34001,31252,33032,22937,31885,27665,30496,21209,22818,28961,29279,30683,38695,40289,26891,23167,23064,20901,21517,21629,26126,30431,36855,37528,40180,23018,29277,28357,20813,26825,32191,32236,38754,40634,25720,27169,33538,22916,23391,27611,29467,30450,32178,32791,33945,20786,26408,40665,30446,26466,21247,39173,23588,25147,31870,36016,21839,24758,32011,38272,21249,20063,20918,22812,29242,32822,37326,24357,30690,21380,24441,32004,34220,35379,36493,38742,26611,34222,37971,24841,24840,27833,30290,35565,36664,21807,20305,20778,21191,21451,23461,24189,24736,24962,25558,26377,26586,28263,28044,29494,29495,30001,31056,35029,35480,36938,37009,37109,38596,34701,22805,20104,20313,19982,35465,36671,38928,20653,24188,22934,23481,24248,25562,25594,25793,26332,26954,27096,27915,28342,29076,29992,31407,32650,32768,33865,33993,35201,35617,36362,36965,38525,39178,24958,25233,27442,27779,28020,32716,32764,28096,32645,34746,35064,26469,33713,38972,38647,27931,32097,33853,37226,20081,21365,23888,27396,28651,34253,34349,35239,21033,21519,23653,26446,26792,29702,29827,30178,35023,35041,37324,38626,38520,24459,29575,31435,33870,25504,30053,21129,27969,28316,29705,30041,30827,31890,38534,31452,40845,20406,24942,26053,34396,20102,20142,20698,20001,20940,23534,26009,26753,28092,29471,30274,30637,31260,31975,33391,35538,36988,37327,38517,38936,21147,32209,20523,21400,26519,28107,29136,29747,33256,36650,38563,40023,40607,29792,22593,28057,32047,39006,20196,20278,20363,20919,21169,23994,24604,29618,31036,33491,37428,38583,38646,38666,40599,40802,26278,27508,21015,21155,28872,35010,24265,24651,24976,28451,29001,31806,32244,32879,34030,36899,37676,21570,39791,27347,28809,36034,36335,38706,21172,23105,24266,24324,26391,27004,27028,28010,28431,29282,29436,31725,32769,32894,34635,37070,20845,40595,31108,32907,37682,35542,20525,21644,35441,27498,36036,33031,24785,26528,40434,20121,20120,39952,35435,34241,34152,26880,28286,30871,33109,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,24332,19984,19989,20010,20017,20022,20028,20031,20034,20054,20056,20098,20101,35947,20106,33298,24333,20110,20126,20127,20128,20130,20144,20147,20150,20174,20173,20164,20166,20162,20183,20190,20205,20191,20215,20233,20314,20272,20315,20317,20311,20295,20342,20360,20367,20376,20347,20329,20336,20369,20335,20358,20374,20760,20436,20447,20430,20440,20443,20433,20442,20432,20452,20453,20506,20520,20500,20522,20517,20485,20252,20470,20513,20521,20524,20478,20463,20497,20486,20547,20551,26371,20565,20560,20552,20570,20566,20588,20600,20608,20634,20613,20660,20658,20681,20682,20659,20674,20694,20702,20709,20717,20707,20718,20729,20725,20745,20737,20738,20758,20757,20756,20762,20769,20794,20791,20796,20795,20799,20800,20818,20812,20820,20834,31480,20841,20842,20846,20864,20866,22232,20876,20873,20879,20881,20883,20885,20886,20900,20902,20898,20905,20906,20907,20915,20913,20914,20912,20917,20925,20933,20937,20955,20960,34389,20969,20973,20976,20981,20990,20996,21003,21012,21006,21031,21034,21038,21043,21049,21071,21060,21067,21068,21086,21076,21098,21108,21097,21107,21119,21117,21133,21140,21138,21105,21128,21137,36776,36775,21164,21165,21180,21173,21185,21197,21207,21214,21219,21222,39149,21216,21235,21237,21240,21241,21254,21256,30008,21261,21264,21263,21269,21274,21283,21295,21297,21299,21304,21312,21318,21317,19991,21321,21325,20950,21342,21353,21358,22808,21371,21367,21378,21398,21408,21414,21413,21422,21424,21430,21443,31762,38617,21471,26364,29166,21486,21480,21485,21498,21505,21565,21568,21548,21549,21564,21550,21558,21545,21533,21582,21647,21621,21646,21599,21617,21623,21616,21650,21627,21632,21622,21636,21648,21638,21703,21666,21688,21669,21676,21700,21704,21672,21675,21698,21668,21694,21692,21720,21733,21734,21775,21780,21757,21742,21741,21754,21730,21817,21824,21859,21836,21806,21852,21829,21846,21847,21816,21811,21853,21913,21888,21679,21898,21919,21883,21886,21912,21918,21934,21884,21891,21929,21895,21928,21978,21957,21983,21956,21980,21988,21972,22036,22007,22038,22014,22013,22043,22009,22094,22096,29151,22068,22070,22066,22072,22123,22116,22063,22124,22122,22150,22144,22154,22176,22164,22159,22181,22190,22198,22196,22210,22204,22209,22211,22208,22216,22222,22225,22227,22231,22254,22265,22272,22271,22276,22281,22280,22283,22285,22291,22296,22294,21959,22300,22310,22327,22328,22350,22331,22336,22351,22377,22464,22408,22369,22399,22409,22419,22432,22451,22436,22442,22448,22467,22470,22484,22482,22483,22538,22486,22499,22539,22553,22557,22642,22561,22626,22603,22640,27584,22610,22589,22649,22661,22713,22687,22699,22714,22750,22715,22712,22702,22725,22739,22737,22743,22745,22744,22757,22748,22756,22751,22767,22778,22777,22779,22780,22781,22786,22794,22800,22811,26790,22821,22828,22829,22834,22840,22846,31442,22869,22864,22862,22874,22872,22882,22880,22887,22892,22889,22904,22913,22941,20318,20395,22947,22962,22982,23016,23004,22925,23001,23002,23077,23071,23057,23068,23049,23066,23104,23148,23113,23093,23094,23138,23146,23194,23228,23230,23243,23234,23229,23267,23255,23270,23273,23254,23290,23291,23308,23307,23318,23346,23248,23338,23350,23358,23363,23365,23360,23377,23381,23386,23387,23397,23401,23408,23411,23413,23416,25992,23418,23424,23427,23462,23480,23491,23495,23497,23508,23504,23524,23526,23522,23518,23525,23531,23536,23542,23539,23557,23559,23560,23565,23571,23584,23586,23592,23608,23609,23617,23622,23630,23635,23632,23631,23409,23660,23662,20066,23670,23673,23692,23697,23700,22939,23723,23739,23734,23740,23735,23749,23742,23751,23769,23785,23805,23802,23789,23948,23786,23819,23829,23831,23900,23839,23835,23825,23828,23842,23834,23833,23832,23884,23890,23886,23883,23916,23923,23926,23943,23940,23938,23970,23965,23980,23982,23997,23952,23991,23996,24009,24013,24019,24018,24022,24027,24043,24050,24053,24075,24090,24089,24081,24091,24118,24119,24132,24131,24128,24142,24151,24148,24159,24162,24164,24135,24181,24182,24186,40636,24191,24224,24257,24258,24264,24272,24271,24278,24291,24285,24282,24283,24290,24289,24296,24297,24300,24305,24307,24304,24308,24312,24318,24323,24329,24413,24412,24331,24337,24342,24361,24365,24376,24385,24392,24396,24398,24367,24401,24406,24407,24409,24417,24429,24435,24439,24451,24450,24447,24458,24456,24465,24455,24478,24473,24472,24480,24488,24493,24508,24534,24571,24548,24568,24561,24541,24755,24575,24609,24672,24601,24592,24617,24590,24625,24603,24597,24619,24614,24591,24634,24666,24641,24682,24695,24671,24650,24646,24653,24675,24643,24676,24642,24684,24683,24665,24705,24717,24807,24707,24730,24708,24731,24726,24727,24722,24743,24715,24801,24760,24800,24787,24756,24560,24765,24774,24757,24792,24909,24853,24838,24822,24823,24832,24820,24826,24835,24865,24827,24817,24845,24846,24903,24894,24872,24871,24906,24895,24892,24876,24884,24893,24898,24900,24947,24951,24920,24921,24922,24939,24948,24943,24933,24945,24927,24925,24915,24949,24985,24982,24967,25004,24980,24986,24970,24977,25003,25006,25036,25034,25033,25079,25032,25027,25030,25018,25035,32633,25037,25062,25059,25078,25082,25076,25087,25085,25084,25086,25088,25096,25097,25101,25100,25108,25115,25118,25121,25130,25134,25136,25138,25139,25153,25166,25182,25187,25179,25184,25192,25212,25218,25225,25214,25234,25235,25238,25300,25219,25236,25303,25297,25275,25295,25343,25286,25812,25288,25308,25292,25290,25282,25287,25243,25289,25356,25326,25329,25383,25346,25352,25327,25333,25424,25406,25421,25628,25423,25494,25486,25472,25515,25462,25507,25487,25481,25503,25525,25451,25449,25534,25577,25536,25542,25571,25545,25554,25590,25540,25622,25652,25606,25619,25638,25654,25885,25623,25640,25615,25703,25711,25718,25678,25898,25749,25747,25765,25769,25736,25788,25818,25810,25797,25799,25787,25816,25794,25841,25831,33289,25824,25825,25260,25827,25839,25900,25846,25844,25842,25850,25856,25853,25880,25884,25861,25892,25891,25899,25908,25909,25911,25910,25912,30027,25928,25942,25941,25933,25944,25950,25949,25970,25976,25986,25987,35722,26011,26015,26027,26039,26051,26054,26049,26052,26060,26066,26075,26073,26080,26081,26097,26482,26122,26115,26107,26483,26165,26166,26164,26140,26191,26180,26185,26177,26206,26205,26212,26215,26216,26207,26210,26224,26243,26248,26254,26249,26244,26264,26269,26305,26297,26313,26302,26300,26308,26296,26326,26330,26336,26175,26342,26345,26352,26357,26359,26383,26390,26398,26406,26407,38712,26414,26431,26422,26433,26424,26423,26438,26462,26464,26457,26467,26468,26505,26480,26537,26492,26474,26508,26507,26534,26529,26501,26551,26607,26548,26604,26547,26601,26552,26596,26590,26589,26594,26606,26553,26574,26566,26599,27292,26654,26694,26665,26688,26701,26674,26702,26803,26667,26713,26723,26743,26751,26783,26767,26797,26772,26781,26779,26755,27310,26809,26740,26805,26784,26810,26895,26765,26750,26881,26826,26888,26840,26914,26918,26849,26892,26829,26836,26855,26837,26934,26898,26884,26839,26851,26917,26873,26848,26863,26920,26922,26906,26915,26913,26822,27001,26999,26972,27e3,26987,26964,27006,26990,26937,26996,26941,26969,26928,26977,26974,26973,27009,26986,27058,27054,27088,27071,27073,27091,27070,27086,23528,27082,27101,27067,27075,27047,27182,27025,27040,27036,27029,27060,27102,27112,27138,27163,27135,27402,27129,27122,27111,27141,27057,27166,27117,27156,27115,27146,27154,27329,27171,27155,27204,27148,27250,27190,27256,27207,27234,27225,27238,27208,27192,27170,27280,27277,27296,27268,27298,27299,27287,34327,27323,27331,27330,27320,27315,27308,27358,27345,27359,27306,27354,27370,27387,27397,34326,27386,27410,27414,39729,27423,27448,27447,30428,27449,39150,27463,27459,27465,27472,27481,27476,27483,27487,27489,27512,27513,27519,27520,27524,27523,27533,27544,27541,27550,27556,27562,27563,27567,27570,27569,27571,27575,27580,27590,27595,27603,27615,27628,27627,27635,27631,40638,27656,27667,27668,27675,27684,27683,27742,27733,27746,27754,27778,27789,27802,27777,27803,27774,27752,27763,27794,27792,27844,27889,27859,27837,27863,27845,27869,27822,27825,27838,27834,27867,27887,27865,27882,27935,34893,27958,27947,27965,27960,27929,27957,27955,27922,27916,28003,28051,28004,27994,28025,27993,28046,28053,28644,28037,28153,28181,28170,28085,28103,28134,28088,28102,28140,28126,28108,28136,28114,28101,28154,28121,28132,28117,28138,28142,28205,28270,28206,28185,28274,28255,28222,28195,28267,28203,28278,28237,28191,28227,28218,28238,28196,28415,28189,28216,28290,28330,28312,28361,28343,28371,28349,28335,28356,28338,28372,28373,28303,28325,28354,28319,28481,28433,28748,28396,28408,28414,28479,28402,28465,28399,28466,28364,28478,28435,28407,28550,28538,28536,28545,28544,28527,28507,28659,28525,28546,28540,28504,28558,28561,28610,28518,28595,28579,28577,28580,28601,28614,28586,28639,28629,28652,28628,28632,28657,28654,28635,28681,28683,28666,28689,28673,28687,28670,28699,28698,28532,28701,28696,28703,28720,28734,28722,28753,28771,28825,28818,28847,28913,28844,28856,28851,28846,28895,28875,28893,28889,28937,28925,28956,28953,29029,29013,29064,29030,29026,29004,29014,29036,29071,29179,29060,29077,29096,29100,29143,29113,29118,29138,29129,29140,29134,29152,29164,29159,29173,29180,29177,29183,29197,29200,29211,29224,29229,29228,29232,29234,29243,29244,29247,29248,29254,29259,29272,29300,29310,29314,29313,29319,29330,29334,29346,29351,29369,29362,29379,29382,29380,29390,29394,29410,29408,29409,29433,29431,20495,29463,29450,29468,29462,29469,29492,29487,29481,29477,29502,29518,29519,40664,29527,29546,29544,29552,29560,29557,29563,29562,29640,29619,29646,29627,29632,29669,29678,29662,29858,29701,29807,29733,29688,29746,29754,29781,29759,29791,29785,29761,29788,29801,29808,29795,29802,29814,29822,29835,29854,29863,29898,29903,29908,29681,29920,29923,29927,29929,29934,29938,29936,29937,29944,29943,29956,29955,29957,29964,29966,29965,29973,29971,29982,29990,29996,30012,30020,30029,30026,30025,30043,30022,30042,30057,30052,30055,30059,30061,30072,30070,30086,30087,30068,30090,30089,30082,30100,30106,30109,30117,30115,30146,30131,30147,30133,30141,30136,30140,30129,30157,30154,30162,30169,30179,30174,30206,30207,30204,30209,30192,30202,30194,30195,30219,30221,30217,30239,30247,30240,30241,30242,30244,30260,30256,30267,30279,30280,30278,30300,30296,30305,30306,30312,30313,30314,30311,30316,30320,30322,30326,30328,30332,30336,30339,30344,30347,30350,30358,30355,30361,30362,30384,30388,30392,30393,30394,30402,30413,30422,30418,30430,30433,30437,30439,30442,34351,30459,30472,30471,30468,30505,30500,30494,30501,30502,30491,30519,30520,30535,30554,30568,30571,30555,30565,30591,30590,30585,30606,30603,30609,30624,30622,30640,30646,30649,30655,30652,30653,30651,30663,30669,30679,30682,30684,30691,30702,30716,30732,30738,31014,30752,31018,30789,30862,30836,30854,30844,30874,30860,30883,30901,30890,30895,30929,30918,30923,30932,30910,30908,30917,30922,30956,30951,30938,30973,30964,30983,30994,30993,31001,31020,31019,31040,31072,31063,31071,31066,31061,31059,31098,31103,31114,31133,31143,40779,31146,31150,31155,31161,31162,31177,31189,31207,31212,31201,31203,31240,31245,31256,31257,31264,31263,31104,31281,31291,31294,31287,31299,31319,31305,31329,31330,31337,40861,31344,31353,31357,31368,31383,31381,31384,31382,31401,31432,31408,31414,31429,31428,31423,36995,31431,31434,31437,31439,31445,31443,31449,31450,31453,31457,31458,31462,31469,31472,31490,31503,31498,31494,31539,31512,31513,31518,31541,31528,31542,31568,31610,31492,31565,31499,31564,31557,31605,31589,31604,31591,31600,31601,31596,31598,31645,31640,31647,31629,31644,31642,31627,31634,31631,31581,31641,31691,31681,31692,31695,31668,31686,31709,31721,31761,31764,31718,31717,31840,31744,31751,31763,31731,31735,31767,31757,31734,31779,31783,31786,31775,31799,31787,31805,31820,31811,31828,31823,31808,31824,31832,31839,31844,31830,31845,31852,31861,31875,31888,31908,31917,31906,31915,31905,31912,31923,31922,31921,31918,31929,31933,31936,31941,31938,31960,31954,31964,31970,39739,31983,31986,31988,31990,31994,32006,32002,32028,32021,32010,32069,32075,32046,32050,32063,32053,32070,32115,32086,32078,32114,32104,32110,32079,32099,32147,32137,32091,32143,32125,32155,32186,32174,32163,32181,32199,32189,32171,32317,32162,32175,32220,32184,32159,32176,32216,32221,32228,32222,32251,32242,32225,32261,32266,32291,32289,32274,32305,32287,32265,32267,32290,32326,32358,32315,32309,32313,32323,32311,32306,32314,32359,32349,32342,32350,32345,32346,32377,32362,32361,32380,32379,32387,32213,32381,36782,32383,32392,32393,32396,32402,32400,32403,32404,32406,32398,32411,32412,32568,32570,32581,32588,32589,32590,32592,32593,32597,32596,32600,32607,32608,32616,32617,32615,32632,32642,32646,32643,32648,32647,32652,32660,32670,32669,32666,32675,32687,32690,32697,32686,32694,32696,35697,32709,32710,32714,32725,32724,32737,32742,32745,32755,32761,39132,32774,32772,32779,32786,32792,32793,32796,32801,32808,32831,32827,32842,32838,32850,32856,32858,32863,32866,32872,32883,32882,32880,32886,32889,32893,32895,32900,32902,32901,32923,32915,32922,32941,20880,32940,32987,32997,32985,32989,32964,32986,32982,33033,33007,33009,33051,33065,33059,33071,33099,38539,33094,33086,33107,33105,33020,33137,33134,33125,33126,33140,33155,33160,33162,33152,33154,33184,33173,33188,33187,33119,33171,33193,33200,33205,33214,33208,33213,33216,33218,33210,33225,33229,33233,33241,33240,33224,33242,33247,33248,33255,33274,33275,33278,33281,33282,33285,33287,33290,33293,33296,33302,33321,33323,33336,33331,33344,33369,33368,33373,33370,33375,33380,33378,33384,33386,33387,33326,33393,33399,33400,33406,33421,33426,33451,33439,33467,33452,33505,33507,33503,33490,33524,33523,33530,33683,33539,33531,33529,33502,33542,33500,33545,33497,33589,33588,33558,33586,33585,33600,33593,33616,33605,33583,33579,33559,33560,33669,33690,33706,33695,33698,33686,33571,33678,33671,33674,33660,33717,33651,33653,33696,33673,33704,33780,33811,33771,33742,33789,33795,33752,33803,33729,33783,33799,33760,33778,33805,33826,33824,33725,33848,34054,33787,33901,33834,33852,34138,33924,33911,33899,33965,33902,33922,33897,33862,33836,33903,33913,33845,33994,33890,33977,33983,33951,34009,33997,33979,34010,34e3,33985,33990,34006,33953,34081,34047,34036,34071,34072,34092,34079,34069,34068,34044,34112,34147,34136,34120,34113,34306,34123,34133,34176,34212,34184,34193,34186,34216,34157,34196,34203,34282,34183,34204,34167,34174,34192,34249,34234,34255,34233,34256,34261,34269,34277,34268,34297,34314,34323,34315,34302,34298,34310,34338,34330,34352,34367,34381,20053,34388,34399,34407,34417,34451,34467,34473,34474,34443,34444,34486,34479,34500,34502,34480,34505,34851,34475,34516,34526,34537,34540,34527,34523,34543,34578,34566,34568,34560,34563,34555,34577,34569,34573,34553,34570,34612,34623,34615,34619,34597,34601,34586,34656,34655,34680,34636,34638,34676,34647,34664,34670,34649,34643,34659,34666,34821,34722,34719,34690,34735,34763,34749,34752,34768,38614,34731,34756,34739,34759,34758,34747,34799,34802,34784,34831,34829,34814,34806,34807,34830,34770,34833,34838,34837,34850,34849,34865,34870,34873,34855,34875,34884,34882,34898,34905,34910,34914,34923,34945,34942,34974,34933,34941,34997,34930,34946,34967,34962,34990,34969,34978,34957,34980,34992,35007,34993,35011,35012,35028,35032,35033,35037,35065,35074,35068,35060,35048,35058,35076,35084,35082,35091,35139,35102,35109,35114,35115,35137,35140,35131,35126,35128,35148,35101,35168,35166,35174,35172,35181,35178,35183,35188,35191,35198,35203,35208,35210,35219,35224,35233,35241,35238,35244,35247,35250,35258,35261,35263,35264,35290,35292,35293,35303,35316,35320,35331,35350,35344,35340,35355,35357,35365,35382,35393,35419,35410,35398,35400,35452,35437,35436,35426,35461,35458,35460,35496,35489,35473,35493,35494,35482,35491,35524,35533,35522,35546,35563,35571,35559,35556,35569,35604,35552,35554,35575,35550,35547,35596,35591,35610,35553,35606,35600,35607,35616,35635,38827,35622,35627,35646,35624,35649,35660,35663,35662,35657,35670,35675,35674,35691,35679,35692,35695,35700,35709,35712,35724,35726,35730,35731,35734,35737,35738,35898,35905,35903,35912,35916,35918,35920,35925,35938,35948,35960,35962,35970,35977,35973,35978,35981,35982,35988,35964,35992,25117,36013,36010,36029,36018,36019,36014,36022,36040,36033,36068,36067,36058,36093,36090,36091,36100,36101,36106,36103,36111,36109,36112,40782,36115,36045,36116,36118,36199,36205,36209,36211,36225,36249,36290,36286,36282,36303,36314,36310,36300,36315,36299,36330,36331,36319,36323,36348,36360,36361,36351,36381,36382,36368,36383,36418,36405,36400,36404,36426,36423,36425,36428,36432,36424,36441,36452,36448,36394,36451,36437,36470,36466,36476,36481,36487,36485,36484,36491,36490,36499,36497,36500,36505,36522,36513,36524,36528,36550,36529,36542,36549,36552,36555,36571,36579,36604,36603,36587,36606,36618,36613,36629,36626,36633,36627,36636,36639,36635,36620,36646,36659,36667,36665,36677,36674,36670,36684,36681,36678,36686,36695,36700,36706,36707,36708,36764,36767,36771,36781,36783,36791,36826,36837,36834,36842,36847,36999,36852,36869,36857,36858,36881,36885,36897,36877,36894,36886,36875,36903,36918,36917,36921,36856,36943,36944,36945,36946,36878,36937,36926,36950,36952,36958,36968,36975,36982,38568,36978,36994,36989,36993,36992,37002,37001,37007,37032,37039,37041,37045,37090,37092,25160,37083,37122,37138,37145,37170,37168,37194,37206,37208,37219,37221,37225,37235,37234,37259,37257,37250,37282,37291,37295,37290,37301,37300,37306,37312,37313,37321,37323,37328,37334,37343,37345,37339,37372,37365,37366,37406,37375,37396,37420,37397,37393,37470,37463,37445,37449,37476,37448,37525,37439,37451,37456,37532,37526,37523,37531,37466,37583,37561,37559,37609,37647,37626,37700,37678,37657,37666,37658,37667,37690,37685,37691,37724,37728,37756,37742,37718,37808,37804,37805,37780,37817,37846,37847,37864,37861,37848,37827,37853,37840,37832,37860,37914,37908,37907,37891,37895,37904,37942,37931,37941,37921,37946,37953,37970,37956,37979,37984,37986,37982,37994,37417,38e3,38005,38007,38013,37978,38012,38014,38017,38015,38274,38279,38282,38292,38294,38296,38297,38304,38312,38311,38317,38332,38331,38329,38334,38346,28662,38339,38349,38348,38357,38356,38358,38364,38369,38373,38370,38433,38440,38446,38447,38466,38476,38479,38475,38519,38492,38494,38493,38495,38502,38514,38508,38541,38552,38549,38551,38570,38567,38577,38578,38576,38580,38582,38584,38585,38606,38603,38601,38605,35149,38620,38669,38613,38649,38660,38662,38664,38675,38670,38673,38671,38678,38681,38692,38698,38704,38713,38717,38718,38724,38726,38728,38722,38729,38748,38752,38756,38758,38760,21202,38763,38769,38777,38789,38780,38785,38778,38790,38795,38799,38800,38812,38824,38822,38819,38835,38836,38851,38854,38856,38859,38876,38893,40783,38898,31455,38902,38901,38927,38924,38968,38948,38945,38967,38973,38982,38991,38987,39019,39023,39024,39025,39028,39027,39082,39087,39089,39094,39108,39107,39110,39145,39147,39171,39177,39186,39188,39192,39201,39197,39198,39204,39200,39212,39214,39229,39230,39234,39241,39237,39248,39243,39249,39250,39244,39253,39319,39320,39333,39341,39342,39356,39391,39387,39389,39384,39377,39405,39406,39409,39410,39419,39416,39425,39439,39429,39394,39449,39467,39479,39493,39490,39488,39491,39486,39509,39501,39515,39511,39519,39522,39525,39524,39529,39531,39530,39597,39600,39612,39616,39631,39633,39635,39636,39646,39647,39650,39651,39654,39663,39659,39662,39668,39665,39671,39675,39686,39704,39706,39711,39714,39715,39717,39719,39720,39721,39722,39726,39727,39730,39748,39747,39759,39757,39758,39761,39768,39796,39827,39811,39825,39830,39831,39839,39840,39848,39860,39872,39882,39865,39878,39887,39889,39890,39907,39906,39908,39892,39905,39994,39922,39921,39920,39957,39956,39945,39955,39948,39942,39944,39954,39946,39940,39982,39963,39973,39972,39969,39984,40007,39986,40006,39998,40026,40032,40039,40054,40056,40167,40172,40176,40201,40200,40171,40195,40198,40234,40230,40367,40227,40223,40260,40213,40210,40257,40255,40254,40262,40264,40285,40286,40292,40273,40272,40281,40306,40329,40327,40363,40303,40314,40346,40356,40361,40370,40388,40385,40379,40376,40378,40390,40399,40386,40409,40403,40440,40422,40429,40431,40445,40474,40475,40478,40565,40569,40573,40577,40584,40587,40588,40594,40597,40593,40605,40613,40617,40632,40618,40621,38753,40652,40654,40655,40656,40660,40668,40670,40669,40672,40677,40680,40687,40692,40694,40695,40697,40699,40700,40701,40711,40712,30391,40725,40737,40748,40766,40778,40786,40788,40803,40799,40800,40801,40806,40807,40812,40810,40823,40818,40822,40853,40860,40864,22575,27079,36953,29796,20956,29081,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,32394,35100,37704,37512,34012,20425,28859,26161,26824,37625,26363,24389,20008,20193,20220,20224,20227,20281,20310,20370,20362,20378,20372,20429,20544,20514,20479,20510,20550,20592,20546,20628,20724,20696,20810,20836,20893,20926,20972,21013,21148,21158,21184,21211,21248,21255,21284,21362,21395,21426,21469,64014,21660,21642,21673,21759,21894,22361,22373,22444,22472,22471,64015,64016,22686,22706,22795,22867,22875,22877,22883,22948,22970,23382,23488,29999,23512,23532,23582,23718,23738,23797,23847,23891,64017,23874,23917,23992,23993,24016,24353,24372,24423,24503,24542,24669,24709,24714,24798,24789,24864,24818,24849,24887,24880,24984,25107,25254,25589,25696,25757,25806,25934,26112,26133,26171,26121,26158,26142,26148,26213,26199,26201,64018,26227,26265,26272,26290,26303,26362,26382,63785,26470,26555,26706,26560,26625,26692,26831,64019,26984,64020,27032,27106,27184,27243,27206,27251,27262,27362,27364,27606,27711,27740,27782,27759,27866,27908,28039,28015,28054,28076,28111,28152,28146,28156,28217,28252,28199,28220,28351,28552,28597,28661,28677,28679,28712,28805,28843,28943,28932,29020,28998,28999,64021,29121,29182,29361,29374,29476,64022,29559,29629,29641,29654,29667,29650,29703,29685,29734,29738,29737,29742,29794,29833,29855,29953,30063,30338,30364,30366,30363,30374,64023,30534,21167,30753,30798,30820,30842,31024,64024,64025,64026,31124,64027,31131,31441,31463,64028,31467,31646,64029,32072,32092,32183,32160,32214,32338,32583,32673,64030,33537,33634,33663,33735,33782,33864,33972,34131,34137,34155,64031,34224,64032,64033,34823,35061,35346,35383,35449,35495,35518,35551,64034,35574,35667,35711,36080,36084,36114,36214,64035,36559,64036,64037,36967,37086,64038,37141,37159,37338,37335,37342,37357,37358,37348,37349,37382,37392,37386,37434,37440,37436,37454,37465,37457,37433,37479,37543,37495,37496,37607,37591,37593,37584,64039,37589,37600,37587,37669,37665,37627,64040,37662,37631,37661,37634,37744,37719,37796,37830,37854,37880,37937,37957,37960,38290,63964,64041,38557,38575,38707,38715,38723,38733,38735,38737,38741,38999,39013,64042,64043,39207,64044,39326,39502,39641,39644,39797,39794,39823,39857,39867,39936,40304,40299,64045,40473,40657,null,null,8560,8561,8562,8563,8564,8565,8566,8567,8568,8569,65506,65508,65287,65282,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,8560,8561,8562,8563,8564,8565,8566,8567,8568,8569,8544,8545,8546,8547,8548,8549,8550,8551,8552,8553,65506,65508,65287,65282,12849,8470,8481,8757,32394,35100,37704,37512,34012,20425,28859,26161,26824,37625,26363,24389,20008,20193,20220,20224,20227,20281,20310,20370,20362,20378,20372,20429,20544,20514,20479,20510,20550,20592,20546,20628,20724,20696,20810,20836,20893,20926,20972,21013,21148,21158,21184,21211,21248,21255,21284,21362,21395,21426,21469,64014,21660,21642,21673,21759,21894,22361,22373,22444,22472,22471,64015,64016,22686,22706,22795,22867,22875,22877,22883,22948,22970,23382,23488,29999,23512,23532,23582,23718,23738,23797,23847,23891,64017,23874,23917,23992,23993,24016,24353,24372,24423,24503,24542,24669,24709,24714,24798,24789,24864,24818,24849,24887,24880,24984,25107,25254,25589,25696,25757,25806,25934,26112,26133,26171,26121,26158,26142,26148,26213,26199,26201,64018,26227,26265,26272,26290,26303,26362,26382,63785,26470,26555,26706,26560,26625,26692,26831,64019,26984,64020,27032,27106,27184,27243,27206,27251,27262,27362,27364,27606,27711,27740,27782,27759,27866,27908,28039,28015,28054,28076,28111,28152,28146,28156,28217,28252,28199,28220,28351,28552,28597,28661,28677,28679,28712,28805,28843,28943,28932,29020,28998,28999,64021,29121,29182,29361,29374,29476,64022,29559,29629,29641,29654,29667,29650,29703,29685,29734,29738,29737,29742,29794,29833,29855,29953,30063,30338,30364,30366,30363,30374,64023,30534,21167,30753,30798,30820,30842,31024,64024,64025,64026,31124,64027,31131,31441,31463,64028,31467,31646,64029,32072,32092,32183,32160,32214,32338,32583,32673,64030,33537,33634,33663,33735,33782,33864,33972,34131,34137,34155,64031,34224,64032,64033,34823,35061,35346,35383,35449,35495,35518,35551,64034,35574,35667,35711,36080,36084,36114,36214,64035,36559,64036,64037,36967,37086,64038,37141,37159,37338,37335,37342,37357,37358,37348,37349,37382,37392,37386,37434,37440,37436,37454,37465,37457,37433,37479,37543,37495,37496,37607,37591,37593,37584,64039,37589,37600,37587,37669,37665,37627,64040,37662,37631,37661,37634,37744,37719,37796,37830,37854,37880,37937,37957,37960,38290,63964,64041,38557,38575,38707,38715,38723,38733,38735,38737,38741,38999,39013,64042,64043,39207,64044,39326,39502,39641,39644,39797,39794,39823,39857,39867,39936,40304,40299,64045,40473,40657,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],jis0212:[null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,728,711,184,729,733,175,731,730,65374,900,901,null,null,null,null,null,null,null,null,161,166,191,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,186,170,169,174,8482,164,8470,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,902,904,905,906,938,null,908,null,910,939,null,911,null,null,null,null,940,941,942,943,970,912,972,962,973,971,944,974,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,1026,1027,1028,1029,1030,1031,1032,1033,1034,1035,1036,1038,1039,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,1106,1107,1108,1109,1110,1111,1112,1113,1114,1115,1116,1118,1119,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,198,272,null,294,null,306,null,321,319,null,330,216,338,null,358,222,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,230,273,240,295,305,307,312,322,320,329,331,248,339,223,359,254,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,193,192,196,194,258,461,256,260,197,195,262,264,268,199,266,270,201,200,203,202,282,278,274,280,null,284,286,290,288,292,205,204,207,206,463,304,298,302,296,308,310,313,317,315,323,327,325,209,211,210,214,212,465,336,332,213,340,344,342,346,348,352,350,356,354,218,217,220,219,364,467,368,362,370,366,360,471,475,473,469,372,221,376,374,377,381,379,null,null,null,null,null,null,null,225,224,228,226,259,462,257,261,229,227,263,265,269,231,267,271,233,232,235,234,283,279,275,281,501,285,287,null,289,293,237,236,239,238,464,null,299,303,297,309,311,314,318,316,324,328,326,241,243,242,246,244,466,337,333,245,341,345,343,347,349,353,351,357,355,250,249,252,251,365,468,369,363,371,367,361,472,476,474,470,373,253,255,375,378,382,380,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,19970,19972,19973,19980,19986,19999,20003,20004,20008,20011,20014,20015,20016,20021,20032,20033,20036,20039,20049,20058,20060,20067,20072,20073,20084,20085,20089,20095,20109,20118,20119,20125,20143,20153,20163,20176,20186,20187,20192,20193,20194,20200,20207,20209,20211,20213,20221,20222,20223,20224,20226,20227,20232,20235,20236,20242,20245,20246,20247,20249,20270,20273,20320,20275,20277,20279,20281,20283,20286,20288,20290,20296,20297,20299,20300,20306,20308,20310,20312,20319,20323,20330,20332,20334,20337,20343,20344,20345,20346,20349,20350,20353,20354,20356,20357,20361,20362,20364,20366,20368,20370,20371,20372,20375,20377,20378,20382,20383,20402,20407,20409,20411,20412,20413,20414,20416,20417,20421,20422,20424,20425,20427,20428,20429,20431,20434,20444,20448,20450,20464,20466,20476,20477,20479,20480,20481,20484,20487,20490,20492,20494,20496,20499,20503,20504,20507,20508,20509,20510,20514,20519,20526,20528,20530,20531,20533,20544,20545,20546,20549,20550,20554,20556,20558,20561,20562,20563,20567,20569,20575,20576,20578,20579,20582,20583,20586,20589,20592,20593,20539,20609,20611,20612,20614,20618,20622,20623,20624,20626,20627,20628,20630,20635,20636,20638,20639,20640,20641,20642,20650,20655,20656,20665,20666,20669,20672,20675,20676,20679,20684,20686,20688,20691,20692,20696,20700,20701,20703,20706,20708,20710,20712,20713,20719,20721,20726,20730,20734,20739,20742,20743,20744,20747,20748,20749,20750,20722,20752,20759,20761,20763,20764,20765,20766,20771,20775,20776,20780,20781,20783,20785,20787,20788,20789,20792,20793,20802,20810,20815,20819,20821,20823,20824,20831,20836,20838,20862,20867,20868,20875,20878,20888,20893,20897,20899,20909,20920,20922,20924,20926,20927,20930,20936,20943,20945,20946,20947,20949,20952,20958,20962,20965,20974,20978,20979,20980,20983,20993,20994,20997,21010,21011,21013,21014,21016,21026,21032,21041,21042,21045,21052,21061,21065,21077,21079,21080,21082,21084,21087,21088,21089,21094,21102,21111,21112,21113,21120,21122,21125,21130,21132,21139,21141,21142,21143,21144,21146,21148,21156,21157,21158,21159,21167,21168,21174,21175,21176,21178,21179,21181,21184,21188,21190,21192,21196,21199,21201,21204,21206,21211,21212,21217,21221,21224,21225,21226,21228,21232,21233,21236,21238,21239,21248,21251,21258,21259,21260,21265,21267,21272,21275,21276,21278,21279,21285,21287,21288,21289,21291,21292,21293,21296,21298,21301,21308,21309,21310,21314,21324,21323,21337,21339,21345,21347,21349,21356,21357,21362,21369,21374,21379,21383,21384,21390,21395,21396,21401,21405,21409,21412,21418,21419,21423,21426,21428,21429,21431,21432,21434,21437,21440,21445,21455,21458,21459,21461,21466,21469,21470,21472,21478,21479,21493,21506,21523,21530,21537,21543,21544,21546,21551,21553,21556,21557,21571,21572,21575,21581,21583,21598,21602,21604,21606,21607,21609,21611,21613,21614,21620,21631,21633,21635,21637,21640,21641,21645,21649,21653,21654,21660,21663,21665,21670,21671,21673,21674,21677,21678,21681,21687,21689,21690,21691,21695,21702,21706,21709,21710,21728,21738,21740,21743,21750,21756,21758,21759,21760,21761,21765,21768,21769,21772,21773,21774,21781,21802,21803,21810,21813,21814,21819,21820,21821,21825,21831,21833,21834,21837,21840,21841,21848,21850,21851,21854,21856,21857,21860,21862,21887,21889,21890,21894,21896,21902,21903,21905,21906,21907,21908,21911,21923,21924,21933,21938,21951,21953,21955,21958,21961,21963,21964,21966,21969,21970,21971,21975,21976,21979,21982,21986,21993,22006,22015,22021,22024,22026,22029,22030,22031,22032,22033,22034,22041,22060,22064,22067,22069,22071,22073,22075,22076,22077,22079,22080,22081,22083,22084,22086,22089,22091,22093,22095,22100,22110,22112,22113,22114,22115,22118,22121,22125,22127,22129,22130,22133,22148,22149,22152,22155,22156,22165,22169,22170,22173,22174,22175,22182,22183,22184,22185,22187,22188,22189,22193,22195,22199,22206,22213,22217,22218,22219,22223,22224,22220,22221,22233,22236,22237,22239,22241,22244,22245,22246,22247,22248,22257,22251,22253,22262,22263,22273,22274,22279,22282,22284,22289,22293,22298,22299,22301,22304,22306,22307,22308,22309,22313,22314,22316,22318,22319,22323,22324,22333,22334,22335,22341,22342,22348,22349,22354,22370,22373,22375,22376,22379,22381,22382,22383,22384,22385,22387,22388,22389,22391,22393,22394,22395,22396,22398,22401,22403,22412,22420,22423,22425,22426,22428,22429,22430,22431,22433,22421,22439,22440,22441,22444,22456,22461,22471,22472,22476,22479,22485,22493,22494,22500,22502,22503,22505,22509,22512,22517,22518,22520,22525,22526,22527,22531,22532,22536,22537,22497,22540,22541,22555,22558,22559,22560,22566,22567,22573,22578,22585,22591,22601,22604,22605,22607,22608,22613,22623,22625,22628,22631,22632,22648,22652,22655,22656,22657,22663,22664,22665,22666,22668,22669,22671,22672,22676,22678,22685,22688,22689,22690,22694,22697,22705,22706,22724,22716,22722,22728,22733,22734,22736,22738,22740,22742,22746,22749,22753,22754,22761,22771,22789,22790,22795,22796,22802,22803,22804,34369,22813,22817,22819,22820,22824,22831,22832,22835,22837,22838,22847,22851,22854,22866,22867,22873,22875,22877,22878,22879,22881,22883,22891,22893,22895,22898,22901,22902,22905,22907,22908,22923,22924,22926,22930,22933,22935,22943,22948,22951,22957,22958,22959,22960,22963,22967,22970,22972,22977,22979,22980,22984,22986,22989,22994,23005,23006,23007,23011,23012,23015,23022,23023,23025,23026,23028,23031,23040,23044,23052,23053,23054,23058,23059,23070,23075,23076,23079,23080,23082,23085,23088,23108,23109,23111,23112,23116,23120,23125,23134,23139,23141,23143,23149,23159,23162,23163,23166,23179,23184,23187,23190,23193,23196,23198,23199,23200,23202,23207,23212,23217,23218,23219,23221,23224,23226,23227,23231,23236,23238,23240,23247,23258,23260,23264,23269,23274,23278,23285,23286,23293,23296,23297,23304,23319,23348,23321,23323,23325,23329,23333,23341,23352,23361,23371,23372,23378,23382,23390,23400,23406,23407,23420,23421,23422,23423,23425,23428,23430,23434,23438,23440,23441,23443,23444,23446,23464,23465,23468,23469,23471,23473,23474,23479,23482,23484,23488,23489,23501,23503,23510,23511,23512,23513,23514,23520,23535,23537,23540,23549,23564,23575,23582,23583,23587,23590,23593,23595,23596,23598,23600,23602,23605,23606,23641,23642,23644,23650,23651,23655,23656,23657,23661,23664,23668,23669,23674,23675,23676,23677,23687,23688,23690,23695,23698,23709,23711,23712,23714,23715,23718,23722,23730,23732,23733,23738,23753,23755,23762,23773,23767,23790,23793,23794,23796,23809,23814,23821,23826,23851,23843,23844,23846,23847,23857,23860,23865,23869,23871,23874,23875,23878,23880,23893,23889,23897,23882,23903,23904,23905,23906,23908,23914,23917,23920,23929,23930,23934,23935,23937,23939,23944,23946,23954,23955,23956,23957,23961,23963,23967,23968,23975,23979,23984,23988,23992,23993,24003,24007,24011,24016,24014,24024,24025,24032,24036,24041,24056,24057,24064,24071,24077,24082,24084,24085,24088,24095,24096,24110,24104,24114,24117,24126,24139,24144,24137,24145,24150,24152,24155,24156,24158,24168,24170,24171,24172,24173,24174,24176,24192,24203,24206,24226,24228,24229,24232,24234,24236,24241,24243,24253,24254,24255,24262,24268,24267,24270,24273,24274,24276,24277,24284,24286,24293,24299,24322,24326,24327,24328,24334,24345,24348,24349,24353,24354,24355,24356,24360,24363,24364,24366,24368,24372,24374,24379,24381,24383,24384,24388,24389,24391,24397,24400,24404,24408,24411,24416,24419,24420,24423,24431,24434,24436,24437,24440,24442,24445,24446,24457,24461,24463,24470,24476,24477,24482,24487,24491,24484,24492,24495,24496,24497,24504,24516,24519,24520,24521,24523,24528,24529,24530,24531,24532,24542,24545,24546,24552,24553,24554,24556,24557,24558,24559,24562,24563,24566,24570,24572,24583,24586,24589,24595,24596,24599,24600,24602,24607,24612,24621,24627,24629,24640,24647,24648,24649,24652,24657,24660,24662,24663,24669,24673,24679,24689,24702,24703,24706,24710,24712,24714,24718,24721,24723,24725,24728,24733,24734,24738,24740,24741,24744,24752,24753,24759,24763,24766,24770,24772,24776,24777,24778,24779,24782,24783,24788,24789,24793,24795,24797,24798,24802,24805,24818,24821,24824,24828,24829,24834,24839,24842,24844,24848,24849,24850,24851,24852,24854,24855,24857,24860,24862,24866,24874,24875,24880,24881,24885,24886,24887,24889,24897,24901,24902,24905,24926,24928,24940,24946,24952,24955,24956,24959,24960,24961,24963,24964,24971,24973,24978,24979,24983,24984,24988,24989,24991,24992,24997,25e3,25002,25005,25016,25017,25020,25024,25025,25026,25038,25039,25045,25052,25053,25054,25055,25057,25058,25063,25065,25061,25068,25069,25071,25089,25091,25092,25095,25107,25109,25116,25120,25122,25123,25127,25129,25131,25145,25149,25154,25155,25156,25158,25164,25168,25169,25170,25172,25174,25178,25180,25188,25197,25199,25203,25210,25213,25229,25230,25231,25232,25254,25256,25267,25270,25271,25274,25278,25279,25284,25294,25301,25302,25306,25322,25330,25332,25340,25341,25347,25348,25354,25355,25357,25360,25363,25366,25368,25385,25386,25389,25397,25398,25401,25404,25409,25410,25411,25412,25414,25418,25419,25422,25426,25427,25428,25432,25435,25445,25446,25452,25453,25457,25460,25461,25464,25468,25469,25471,25474,25476,25479,25482,25488,25492,25493,25497,25498,25502,25508,25510,25517,25518,25519,25533,25537,25541,25544,25550,25553,25555,25556,25557,25564,25568,25573,25578,25580,25586,25587,25589,25592,25593,25609,25610,25616,25618,25620,25624,25630,25632,25634,25636,25637,25641,25642,25647,25648,25653,25661,25663,25675,25679,25681,25682,25683,25684,25690,25691,25692,25693,25695,25696,25697,25699,25709,25715,25716,25723,25725,25733,25735,25743,25744,25745,25752,25753,25755,25757,25759,25761,25763,25766,25768,25772,25779,25789,25790,25791,25796,25801,25802,25803,25804,25806,25808,25809,25813,25815,25828,25829,25833,25834,25837,25840,25845,25847,25851,25855,25857,25860,25864,25865,25866,25871,25875,25876,25878,25881,25883,25886,25887,25890,25894,25897,25902,25905,25914,25916,25917,25923,25927,25929,25936,25938,25940,25951,25952,25959,25963,25978,25981,25985,25989,25994,26002,26005,26008,26013,26016,26019,26022,26030,26034,26035,26036,26047,26050,26056,26057,26062,26064,26068,26070,26072,26079,26096,26098,26100,26101,26105,26110,26111,26112,26116,26120,26121,26125,26129,26130,26133,26134,26141,26142,26145,26146,26147,26148,26150,26153,26154,26155,26156,26158,26160,26161,26163,26169,26167,26176,26181,26182,26186,26188,26193,26190,26199,26200,26201,26203,26204,26208,26209,26363,26218,26219,26220,26238,26227,26229,26239,26231,26232,26233,26235,26240,26236,26251,26252,26253,26256,26258,26265,26266,26267,26268,26271,26272,26276,26285,26289,26290,26293,26299,26303,26304,26306,26307,26312,26316,26318,26319,26324,26331,26335,26344,26347,26348,26350,26362,26373,26375,26382,26387,26393,26396,26400,26402,26419,26430,26437,26439,26440,26444,26452,26453,26461,26470,26476,26478,26484,26486,26491,26497,26500,26510,26511,26513,26515,26518,26520,26521,26523,26544,26545,26546,26549,26555,26556,26557,26617,26560,26562,26563,26565,26568,26569,26578,26583,26585,26588,26593,26598,26608,26610,26614,26615,26706,26644,26649,26653,26655,26664,26663,26668,26669,26671,26672,26673,26675,26683,26687,26692,26693,26698,26700,26709,26711,26712,26715,26731,26734,26735,26736,26737,26738,26741,26745,26746,26747,26748,26754,26756,26758,26760,26774,26776,26778,26780,26785,26787,26789,26793,26794,26798,26802,26811,26821,26824,26828,26831,26832,26833,26835,26838,26841,26844,26845,26853,26856,26858,26859,26860,26861,26864,26865,26869,26870,26875,26876,26877,26886,26889,26890,26896,26897,26899,26902,26903,26929,26931,26933,26936,26939,26946,26949,26953,26958,26967,26971,26979,26980,26981,26982,26984,26985,26988,26992,26993,26994,27002,27003,27007,27008,27021,27026,27030,27032,27041,27045,27046,27048,27051,27053,27055,27063,27064,27066,27068,27077,27080,27089,27094,27095,27106,27109,27118,27119,27121,27123,27125,27134,27136,27137,27139,27151,27153,27157,27162,27165,27168,27172,27176,27184,27186,27188,27191,27195,27198,27199,27205,27206,27209,27210,27214,27216,27217,27218,27221,27222,27227,27236,27239,27242,27249,27251,27262,27265,27267,27270,27271,27273,27275,27281,27291,27293,27294,27295,27301,27307,27311,27312,27313,27316,27325,27326,27327,27334,27337,27336,27340,27344,27348,27349,27350,27356,27357,27364,27367,27372,27376,27377,27378,27388,27389,27394,27395,27398,27399,27401,27407,27408,27409,27415,27419,27422,27428,27432,27435,27436,27439,27445,27446,27451,27455,27462,27466,27469,27474,27478,27480,27485,27488,27495,27499,27502,27504,27509,27517,27518,27522,27525,27543,27547,27551,27552,27554,27555,27560,27561,27564,27565,27566,27568,27576,27577,27581,27582,27587,27588,27593,27596,27606,27610,27617,27619,27622,27623,27630,27633,27639,27641,27647,27650,27652,27653,27657,27661,27662,27664,27666,27673,27679,27686,27687,27688,27692,27694,27699,27701,27702,27706,27707,27711,27722,27723,27725,27727,27730,27732,27737,27739,27740,27755,27757,27759,27764,27766,27768,27769,27771,27781,27782,27783,27785,27796,27797,27799,27800,27804,27807,27824,27826,27828,27842,27846,27853,27855,27856,27857,27858,27860,27862,27866,27868,27872,27879,27881,27883,27884,27886,27890,27892,27908,27911,27914,27918,27919,27921,27923,27930,27942,27943,27944,27751,27950,27951,27953,27961,27964,27967,27991,27998,27999,28001,28005,28007,28015,28016,28028,28034,28039,28049,28050,28052,28054,28055,28056,28074,28076,28084,28087,28089,28093,28095,28100,28104,28106,28110,28111,28118,28123,28125,28127,28128,28130,28133,28137,28143,28144,28148,28150,28156,28160,28164,28190,28194,28199,28210,28214,28217,28219,28220,28228,28229,28232,28233,28235,28239,28241,28242,28243,28244,28247,28252,28253,28254,28258,28259,28264,28275,28283,28285,28301,28307,28313,28320,28327,28333,28334,28337,28339,28347,28351,28352,28353,28355,28359,28360,28362,28365,28366,28367,28395,28397,28398,28409,28411,28413,28420,28424,28426,28428,28429,28438,28440,28442,28443,28454,28457,28458,28463,28464,28467,28470,28475,28476,28461,28495,28497,28498,28499,28503,28505,28506,28509,28510,28513,28514,28520,28524,28541,28542,28547,28551,28552,28555,28556,28557,28560,28562,28563,28564,28566,28570,28575,28576,28581,28582,28583,28584,28590,28591,28592,28597,28598,28604,28613,28615,28616,28618,28634,28638,28648,28649,28656,28661,28665,28668,28669,28672,28677,28678,28679,28685,28695,28704,28707,28719,28724,28727,28729,28732,28739,28740,28744,28745,28746,28747,28756,28757,28765,28766,28750,28772,28773,28780,28782,28789,28790,28798,28801,28805,28806,28820,28821,28822,28823,28824,28827,28836,28843,28848,28849,28852,28855,28874,28881,28883,28884,28885,28886,28888,28892,28900,28922,28931,28932,28933,28934,28935,28939,28940,28943,28958,28960,28971,28973,28975,28976,28977,28984,28993,28997,28998,28999,29002,29003,29008,29010,29015,29018,29020,29022,29024,29032,29049,29056,29061,29063,29068,29074,29082,29083,29088,29090,29103,29104,29106,29107,29114,29119,29120,29121,29124,29131,29132,29139,29142,29145,29146,29148,29176,29182,29184,29191,29192,29193,29203,29207,29210,29213,29215,29220,29227,29231,29236,29240,29241,29249,29250,29251,29253,29262,29263,29264,29267,29269,29270,29274,29276,29278,29280,29283,29288,29291,29294,29295,29297,29303,29304,29307,29308,29311,29316,29321,29325,29326,29331,29339,29352,29357,29358,29361,29364,29374,29377,29383,29385,29388,29397,29398,29400,29407,29413,29427,29428,29434,29435,29438,29442,29444,29445,29447,29451,29453,29458,29459,29464,29465,29470,29474,29476,29479,29480,29484,29489,29490,29493,29498,29499,29501,29507,29517,29520,29522,29526,29528,29533,29534,29535,29536,29542,29543,29545,29547,29548,29550,29551,29553,29559,29561,29564,29568,29569,29571,29573,29574,29582,29584,29587,29589,29591,29592,29596,29598,29599,29600,29602,29605,29606,29610,29611,29613,29621,29623,29625,29628,29629,29631,29637,29638,29641,29643,29644,29647,29650,29651,29654,29657,29661,29665,29667,29670,29671,29673,29684,29685,29687,29689,29690,29691,29693,29695,29696,29697,29700,29703,29706,29713,29722,29723,29732,29734,29736,29737,29738,29739,29740,29741,29742,29743,29744,29745,29753,29760,29763,29764,29766,29767,29771,29773,29777,29778,29783,29789,29794,29798,29799,29800,29803,29805,29806,29809,29810,29824,29825,29829,29830,29831,29833,29839,29840,29841,29842,29848,29849,29850,29852,29855,29856,29857,29859,29862,29864,29865,29866,29867,29870,29871,29873,29874,29877,29881,29883,29887,29896,29897,29900,29904,29907,29912,29914,29915,29918,29919,29924,29928,29930,29931,29935,29940,29946,29947,29948,29951,29958,29970,29974,29975,29984,29985,29988,29991,29993,29994,29999,30006,30009,30013,30014,30015,30016,30019,30023,30024,30030,30032,30034,30039,30046,30047,30049,30063,30065,30073,30074,30075,30076,30077,30078,30081,30085,30096,30098,30099,30101,30105,30108,30114,30116,30132,30138,30143,30144,30145,30148,30150,30156,30158,30159,30167,30172,30175,30176,30177,30180,30183,30188,30190,30191,30193,30201,30208,30210,30211,30212,30215,30216,30218,30220,30223,30226,30227,30229,30230,30233,30235,30236,30237,30238,30243,30245,30246,30249,30253,30258,30259,30261,30264,30265,30266,30268,30282,30272,30273,30275,30276,30277,30281,30283,30293,30297,30303,30308,30309,30317,30318,30319,30321,30324,30337,30341,30348,30349,30357,30363,30364,30365,30367,30368,30370,30371,30372,30373,30374,30375,30376,30378,30381,30397,30401,30405,30409,30411,30412,30414,30420,30425,30432,30438,30440,30444,30448,30449,30454,30457,30460,30464,30470,30474,30478,30482,30484,30485,30487,30489,30490,30492,30498,30504,30509,30510,30511,30516,30517,30518,30521,30525,30526,30530,30533,30534,30538,30541,30542,30543,30546,30550,30551,30556,30558,30559,30560,30562,30564,30567,30570,30572,30576,30578,30579,30580,30586,30589,30592,30596,30604,30605,30612,30613,30614,30618,30623,30626,30631,30634,30638,30639,30641,30645,30654,30659,30665,30673,30674,30677,30681,30686,30687,30688,30692,30694,30698,30700,30704,30705,30708,30712,30715,30725,30726,30729,30733,30734,30737,30749,30753,30754,30755,30765,30766,30768,30773,30775,30787,30788,30791,30792,30796,30798,30802,30812,30814,30816,30817,30819,30820,30824,30826,30830,30842,30846,30858,30863,30868,30872,30881,30877,30878,30879,30884,30888,30892,30893,30896,30897,30898,30899,30907,30909,30911,30919,30920,30921,30924,30926,30930,30931,30933,30934,30948,30939,30943,30944,30945,30950,30954,30962,30963,30976,30966,30967,30970,30971,30975,30982,30988,30992,31002,31004,31006,31007,31008,31013,31015,31017,31021,31025,31028,31029,31035,31037,31039,31044,31045,31046,31050,31051,31055,31057,31060,31064,31067,31068,31079,31081,31083,31090,31097,31099,31100,31102,31115,31116,31121,31123,31124,31125,31126,31128,31131,31132,31137,31144,31145,31147,31151,31153,31156,31160,31163,31170,31172,31175,31176,31178,31183,31188,31190,31194,31197,31198,31200,31202,31205,31210,31211,31213,31217,31224,31228,31234,31235,31239,31241,31242,31244,31249,31253,31259,31262,31265,31271,31275,31277,31279,31280,31284,31285,31288,31289,31290,31300,31301,31303,31304,31308,31317,31318,31321,31324,31325,31327,31328,31333,31335,31338,31341,31349,31352,31358,31360,31362,31365,31366,31370,31371,31376,31377,31380,31390,31392,31395,31404,31411,31413,31417,31419,31420,31430,31433,31436,31438,31441,31451,31464,31465,31467,31468,31473,31476,31483,31485,31486,31495,31508,31519,31523,31527,31529,31530,31531,31533,31534,31535,31536,31537,31540,31549,31551,31552,31553,31559,31566,31573,31584,31588,31590,31593,31594,31597,31599,31602,31603,31607,31620,31625,31630,31632,31633,31638,31643,31646,31648,31653,31660,31663,31664,31666,31669,31670,31674,31675,31676,31677,31682,31685,31688,31690,31700,31702,31703,31705,31706,31707,31720,31722,31730,31732,31733,31736,31737,31738,31740,31742,31745,31746,31747,31748,31750,31753,31755,31756,31758,31759,31769,31771,31776,31781,31782,31784,31788,31793,31795,31796,31798,31801,31802,31814,31818,31829,31825,31826,31827,31833,31834,31835,31836,31837,31838,31841,31843,31847,31849,31853,31854,31856,31858,31865,31868,31869,31878,31879,31887,31892,31902,31904,31910,31920,31926,31927,31930,31931,31932,31935,31940,31943,31944,31945,31949,31951,31955,31956,31957,31959,31961,31962,31965,31974,31977,31979,31989,32003,32007,32008,32009,32015,32017,32018,32019,32022,32029,32030,32035,32038,32042,32045,32049,32060,32061,32062,32064,32065,32071,32072,32077,32081,32083,32087,32089,32090,32092,32093,32101,32103,32106,32112,32120,32122,32123,32127,32129,32130,32131,32133,32134,32136,32139,32140,32141,32145,32150,32151,32157,32158,32166,32167,32170,32179,32182,32183,32185,32194,32195,32196,32197,32198,32204,32205,32206,32215,32217,32256,32226,32229,32230,32234,32235,32237,32241,32245,32246,32249,32250,32264,32272,32273,32277,32279,32284,32285,32288,32295,32296,32300,32301,32303,32307,32310,32319,32324,32325,32327,32334,32336,32338,32344,32351,32353,32354,32357,32363,32366,32367,32371,32376,32382,32385,32390,32391,32394,32397,32401,32405,32408,32410,32413,32414,32572,32571,32573,32574,32575,32579,32580,32583,32591,32594,32595,32603,32604,32605,32609,32611,32612,32613,32614,32621,32625,32637,32638,32639,32640,32651,32653,32655,32656,32657,32662,32663,32668,32673,32674,32678,32682,32685,32692,32700,32703,32704,32707,32712,32718,32719,32731,32735,32739,32741,32744,32748,32750,32751,32754,32762,32765,32766,32767,32775,32776,32778,32781,32782,32783,32785,32787,32788,32790,32797,32798,32799,32800,32804,32806,32812,32814,32816,32820,32821,32823,32825,32826,32828,32830,32832,32836,32864,32868,32870,32877,32881,32885,32897,32904,32910,32924,32926,32934,32935,32939,32952,32953,32968,32973,32975,32978,32980,32981,32983,32984,32992,33005,33006,33008,33010,33011,33014,33017,33018,33022,33027,33035,33046,33047,33048,33052,33054,33056,33060,33063,33068,33072,33077,33082,33084,33093,33095,33098,33100,33106,33111,33120,33121,33127,33128,33129,33133,33135,33143,33153,33168,33156,33157,33158,33163,33166,33174,33176,33179,33182,33186,33198,33202,33204,33211,33227,33219,33221,33226,33230,33231,33237,33239,33243,33245,33246,33249,33252,33259,33260,33264,33265,33266,33269,33270,33272,33273,33277,33279,33280,33283,33295,33299,33300,33305,33306,33309,33313,33314,33320,33330,33332,33338,33347,33348,33349,33350,33355,33358,33359,33361,33366,33372,33376,33379,33383,33389,33396,33403,33405,33407,33408,33409,33411,33412,33415,33417,33418,33422,33425,33428,33430,33432,33434,33435,33440,33441,33443,33444,33447,33448,33449,33450,33454,33456,33458,33460,33463,33466,33468,33470,33471,33478,33488,33493,33498,33504,33506,33508,33512,33514,33517,33519,33526,33527,33533,33534,33536,33537,33543,33544,33546,33547,33620,33563,33565,33566,33567,33569,33570,33580,33581,33582,33584,33587,33591,33594,33596,33597,33602,33603,33604,33607,33613,33614,33617,33621,33622,33623,33648,33656,33661,33663,33664,33666,33668,33670,33677,33682,33684,33685,33688,33689,33691,33692,33693,33702,33703,33705,33708,33726,33727,33728,33735,33737,33743,33744,33745,33748,33757,33619,33768,33770,33782,33784,33785,33788,33793,33798,33802,33807,33809,33813,33817,33709,33839,33849,33861,33863,33864,33866,33869,33871,33873,33874,33878,33880,33881,33882,33884,33888,33892,33893,33895,33898,33904,33907,33908,33910,33912,33916,33917,33921,33925,33938,33939,33941,33950,33958,33960,33961,33962,33967,33969,33972,33978,33981,33982,33984,33986,33991,33992,33996,33999,34003,34012,34023,34026,34031,34032,34033,34034,34039,34098,34042,34043,34045,34050,34051,34055,34060,34062,34064,34076,34078,34082,34083,34084,34085,34087,34090,34091,34095,34099,34100,34102,34111,34118,34127,34128,34129,34130,34131,34134,34137,34140,34141,34142,34143,34144,34145,34146,34148,34155,34159,34169,34170,34171,34173,34175,34177,34181,34182,34185,34187,34188,34191,34195,34200,34205,34207,34208,34210,34213,34215,34228,34230,34231,34232,34236,34237,34238,34239,34242,34247,34250,34251,34254,34221,34264,34266,34271,34272,34278,34280,34285,34291,34294,34300,34303,34304,34308,34309,34317,34318,34320,34321,34322,34328,34329,34331,34334,34337,34343,34345,34358,34360,34362,34364,34365,34368,34370,34374,34386,34387,34390,34391,34392,34393,34397,34400,34401,34402,34403,34404,34409,34412,34415,34421,34422,34423,34426,34445,34449,34454,34456,34458,34460,34465,34470,34471,34472,34477,34481,34483,34484,34485,34487,34488,34489,34495,34496,34497,34499,34501,34513,34514,34517,34519,34522,34524,34528,34531,34533,34535,34440,34554,34556,34557,34564,34565,34567,34571,34574,34575,34576,34579,34580,34585,34590,34591,34593,34595,34600,34606,34607,34609,34610,34617,34618,34620,34621,34622,34624,34627,34629,34637,34648,34653,34657,34660,34661,34671,34673,34674,34683,34691,34692,34693,34694,34695,34696,34697,34699,34700,34704,34707,34709,34711,34712,34713,34718,34720,34723,34727,34732,34733,34734,34737,34741,34750,34751,34753,34760,34761,34762,34766,34773,34774,34777,34778,34780,34783,34786,34787,34788,34794,34795,34797,34801,34803,34808,34810,34815,34817,34819,34822,34825,34826,34827,34832,34841,34834,34835,34836,34840,34842,34843,34844,34846,34847,34856,34861,34862,34864,34866,34869,34874,34876,34881,34883,34885,34888,34889,34890,34891,34894,34897,34901,34902,34904,34906,34908,34911,34912,34916,34921,34929,34937,34939,34944,34968,34970,34971,34972,34975,34976,34984,34986,35002,35005,35006,35008,35018,35019,35020,35021,35022,35025,35026,35027,35035,35038,35047,35055,35056,35057,35061,35063,35073,35078,35085,35086,35087,35093,35094,35096,35097,35098,35100,35104,35110,35111,35112,35120,35121,35122,35125,35129,35130,35134,35136,35138,35141,35142,35145,35151,35154,35159,35162,35163,35164,35169,35170,35171,35179,35182,35184,35187,35189,35194,35195,35196,35197,35209,35213,35216,35220,35221,35227,35228,35231,35232,35237,35248,35252,35253,35254,35255,35260,35284,35285,35286,35287,35288,35301,35305,35307,35309,35313,35315,35318,35321,35325,35327,35332,35333,35335,35343,35345,35346,35348,35349,35358,35360,35362,35364,35366,35371,35372,35375,35381,35383,35389,35390,35392,35395,35397,35399,35401,35405,35406,35411,35414,35415,35416,35420,35421,35425,35429,35431,35445,35446,35447,35449,35450,35451,35454,35455,35456,35459,35462,35467,35471,35472,35474,35478,35479,35481,35487,35495,35497,35502,35503,35507,35510,35511,35515,35518,35523,35526,35528,35529,35530,35537,35539,35540,35541,35543,35549,35551,35564,35568,35572,35573,35574,35580,35583,35589,35590,35595,35601,35612,35614,35615,35594,35629,35632,35639,35644,35650,35651,35652,35653,35654,35656,35666,35667,35668,35673,35661,35678,35683,35693,35702,35704,35705,35708,35710,35713,35716,35717,35723,35725,35727,35732,35733,35740,35742,35743,35896,35897,35901,35902,35909,35911,35913,35915,35919,35921,35923,35924,35927,35928,35931,35933,35929,35939,35940,35942,35944,35945,35949,35955,35957,35958,35963,35966,35974,35975,35979,35984,35986,35987,35993,35995,35996,36004,36025,36026,36037,36038,36041,36043,36047,36054,36053,36057,36061,36065,36072,36076,36079,36080,36082,36085,36087,36088,36094,36095,36097,36099,36105,36114,36119,36123,36197,36201,36204,36206,36223,36226,36228,36232,36237,36240,36241,36245,36254,36255,36256,36262,36267,36268,36271,36274,36277,36279,36281,36283,36288,36293,36294,36295,36296,36298,36302,36305,36308,36309,36311,36313,36324,36325,36327,36332,36336,36284,36337,36338,36340,36349,36353,36356,36357,36358,36363,36369,36372,36374,36384,36385,36386,36387,36390,36391,36401,36403,36406,36407,36408,36409,36413,36416,36417,36427,36429,36430,36431,36436,36443,36444,36445,36446,36449,36450,36457,36460,36461,36463,36464,36465,36473,36474,36475,36482,36483,36489,36496,36498,36501,36506,36507,36509,36510,36514,36519,36521,36525,36526,36531,36533,36538,36539,36544,36545,36547,36548,36551,36559,36561,36564,36572,36584,36590,36592,36593,36599,36601,36602,36589,36608,36610,36615,36616,36623,36624,36630,36631,36632,36638,36640,36641,36643,36645,36647,36648,36652,36653,36654,36660,36661,36662,36663,36666,36672,36673,36675,36679,36687,36689,36690,36691,36692,36693,36696,36701,36702,36709,36765,36768,36769,36772,36773,36774,36789,36790,36792,36798,36800,36801,36806,36810,36811,36813,36816,36818,36819,36821,36832,36835,36836,36840,36846,36849,36853,36854,36859,36862,36866,36868,36872,36876,36888,36891,36904,36905,36911,36906,36908,36909,36915,36916,36919,36927,36931,36932,36940,36955,36957,36962,36966,36967,36972,36976,36980,36985,36997,37e3,37003,37004,37006,37008,37013,37015,37016,37017,37019,37024,37025,37026,37029,37040,37042,37043,37044,37046,37053,37068,37054,37059,37060,37061,37063,37064,37077,37079,37080,37081,37084,37085,37087,37093,37074,37110,37099,37103,37104,37108,37118,37119,37120,37124,37125,37126,37128,37133,37136,37140,37142,37143,37144,37146,37148,37150,37152,37157,37154,37155,37159,37161,37166,37167,37169,37172,37174,37175,37177,37178,37180,37181,37187,37191,37192,37199,37203,37207,37209,37210,37211,37217,37220,37223,37229,37236,37241,37242,37243,37249,37251,37253,37254,37258,37262,37265,37267,37268,37269,37272,37278,37281,37286,37288,37292,37293,37294,37296,37297,37298,37299,37302,37307,37308,37309,37311,37314,37315,37317,37331,37332,37335,37337,37338,37342,37348,37349,37353,37354,37356,37357,37358,37359,37360,37361,37367,37369,37371,37373,37376,37377,37380,37381,37382,37383,37385,37386,37388,37392,37394,37395,37398,37400,37404,37405,37411,37412,37413,37414,37416,37422,37423,37424,37427,37429,37430,37432,37433,37434,37436,37438,37440,37442,37443,37446,37447,37450,37453,37454,37455,37457,37464,37465,37468,37469,37472,37473,37477,37479,37480,37481,37486,37487,37488,37493,37494,37495,37496,37497,37499,37500,37501,37503,37512,37513,37514,37517,37518,37522,37527,37529,37535,37536,37540,37541,37543,37544,37547,37551,37554,37558,37560,37562,37563,37564,37565,37567,37568,37569,37570,37571,37573,37574,37575,37576,37579,37580,37581,37582,37584,37587,37589,37591,37592,37593,37596,37597,37599,37600,37601,37603,37605,37607,37608,37612,37614,37616,37625,37627,37631,37632,37634,37640,37645,37649,37652,37653,37660,37661,37662,37663,37665,37668,37669,37671,37673,37674,37683,37684,37686,37687,37703,37704,37705,37712,37713,37714,37717,37719,37720,37722,37726,37732,37733,37735,37737,37738,37741,37743,37744,37745,37747,37748,37750,37754,37757,37759,37760,37761,37762,37768,37770,37771,37773,37775,37778,37781,37784,37787,37790,37793,37795,37796,37798,37800,37803,37812,37813,37814,37818,37801,37825,37828,37829,37830,37831,37833,37834,37835,37836,37837,37843,37849,37852,37854,37855,37858,37862,37863,37881,37879,37880,37882,37883,37885,37889,37890,37892,37896,37897,37901,37902,37903,37909,37910,37911,37919,37934,37935,37937,37938,37939,37940,37947,37951,37949,37955,37957,37960,37962,37964,37973,37977,37980,37983,37985,37987,37992,37995,37997,37998,37999,38001,38002,38020,38019,38264,38265,38270,38276,38280,38284,38285,38286,38301,38302,38303,38305,38310,38313,38315,38316,38324,38326,38330,38333,38335,38342,38344,38345,38347,38352,38353,38354,38355,38361,38362,38365,38366,38367,38368,38372,38374,38429,38430,38434,38436,38437,38438,38444,38449,38451,38455,38456,38457,38458,38460,38461,38465,38482,38484,38486,38487,38488,38497,38510,38516,38523,38524,38526,38527,38529,38530,38531,38532,38537,38545,38550,38554,38557,38559,38564,38565,38566,38569,38574,38575,38579,38586,38602,38610,23986,38616,38618,38621,38622,38623,38633,38639,38641,38650,38658,38659,38661,38665,38682,38683,38685,38689,38690,38691,38696,38705,38707,38721,38723,38730,38734,38735,38741,38743,38744,38746,38747,38755,38759,38762,38766,38771,38774,38775,38776,38779,38781,38783,38784,38793,38805,38806,38807,38809,38810,38814,38815,38818,38828,38830,38833,38834,38837,38838,38840,38841,38842,38844,38846,38847,38849,38852,38853,38855,38857,38858,38860,38861,38862,38864,38865,38868,38871,38872,38873,38877,38878,38880,38875,38881,38884,38895,38897,38900,38903,38904,38906,38919,38922,38937,38925,38926,38932,38934,38940,38942,38944,38947,38950,38955,38958,38959,38960,38962,38963,38965,38949,38974,38980,38983,38986,38993,38994,38995,38998,38999,39001,39002,39010,39011,39013,39014,39018,39020,39083,39085,39086,39088,39092,39095,39096,39098,39099,39103,39106,39109,39112,39116,39137,39139,39141,39142,39143,39146,39155,39158,39170,39175,39176,39185,39189,39190,39191,39194,39195,39196,39199,39202,39206,39207,39211,39217,39218,39219,39220,39221,39225,39226,39227,39228,39232,39233,39238,39239,39240,39245,39246,39252,39256,39257,39259,39260,39262,39263,39264,39323,39325,39327,39334,39344,39345,39346,39349,39353,39354,39357,39359,39363,39369,39379,39380,39385,39386,39388,39390,39399,39402,39403,39404,39408,39412,39413,39417,39421,39422,39426,39427,39428,39435,39436,39440,39441,39446,39454,39456,39458,39459,39460,39463,39469,39470,39475,39477,39478,39480,39495,39489,39492,39498,39499,39500,39502,39505,39508,39510,39517,39594,39596,39598,39599,39602,39604,39605,39606,39609,39611,39614,39615,39617,39619,39622,39624,39630,39632,39634,39637,39638,39639,39643,39644,39648,39652,39653,39655,39657,39660,39666,39667,39669,39673,39674,39677,39679,39680,39681,39682,39683,39684,39685,39688,39689,39691,39692,39693,39694,39696,39698,39702,39705,39707,39708,39712,39718,39723,39725,39731,39732,39733,39735,39737,39738,39741,39752,39755,39756,39765,39766,39767,39771,39774,39777,39779,39781,39782,39784,39786,39787,39788,39789,39790,39795,39797,39799,39800,39801,39807,39808,39812,39813,39814,39815,39817,39818,39819,39821,39823,39824,39828,39834,39837,39838,39846,39847,39849,39852,39856,39857,39858,39863,39864,39867,39868,39870,39871,39873,39879,39880,39886,39888,39895,39896,39901,39903,39909,39911,39914,39915,39919,39923,39927,39928,39929,39930,39933,39935,39936,39938,39947,39951,39953,39958,39960,39961,39962,39964,39966,39970,39971,39974,39975,39976,39977,39978,39985,39989,39990,39991,39997,40001,40003,40004,40005,40009,40010,40014,40015,40016,40019,40020,40022,40024,40027,40029,40030,40031,40035,40041,40042,40028,40043,40040,40046,40048,40050,40053,40055,40059,40166,40178,40183,40185,40203,40194,40209,40215,40216,40220,40221,40222,40239,40240,40242,40243,40244,40250,40252,40261,40253,40258,40259,40263,40266,40275,40276,40287,40291,40290,40293,40297,40298,40299,40304,40310,40311,40315,40316,40318,40323,40324,40326,40330,40333,40334,40338,40339,40341,40342,40343,40344,40353,40362,40364,40366,40369,40373,40377,40380,40383,40387,40391,40393,40394,40404,40405,40406,40407,40410,40414,40415,40416,40421,40423,40425,40427,40430,40432,40435,40436,40446,40458,40450,40455,40462,40464,40465,40466,40469,40470,40473,40476,40477,40570,40571,40572,40576,40578,40579,40580,40581,40583,40590,40591,40598,40600,40603,40606,40612,40616,40620,40622,40623,40624,40627,40628,40629,40646,40648,40651,40661,40671,40676,40679,40684,40685,40686,40688,40689,40690,40693,40696,40703,40706,40707,40713,40719,40720,40721,40722,40724,40726,40727,40729,40730,40731,40735,40738,40742,40746,40747,40751,40753,40754,40756,40759,40761,40762,40764,40765,40767,40769,40771,40772,40773,40774,40775,40787,40789,40790,40791,40792,40794,40797,40798,40808,40809,40813,40814,40815,40816,40817,40819,40821,40826,40829,40847,40848,40849,40850,40852,40854,40855,40862,40865,40866,40867,40869,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null],ibm866:[1040,1041,1042,1043,1044,1045,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,9617,9618,9619,9474,9508,9569,9570,9558,9557,9571,9553,9559,9565,9564,9563,9488,9492,9524,9516,9500,9472,9532,9566,9567,9562,9556,9577,9574,9568,9552,9580,9575,9576,9572,9573,9561,9560,9554,9555,9579,9578,9496,9484,9608,9604,9612,9616,9600,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,1025,1105,1028,1108,1031,1111,1038,1118,176,8729,183,8730,8470,164,9632,160],"iso-8859-2":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,260,728,321,164,317,346,167,168,352,350,356,377,173,381,379,176,261,731,322,180,318,347,711,184,353,351,357,378,733,382,380,340,193,194,258,196,313,262,199,268,201,280,203,282,205,206,270,272,323,327,211,212,336,214,215,344,366,218,368,220,221,354,223,341,225,226,259,228,314,263,231,269,233,281,235,283,237,238,271,273,324,328,243,244,337,246,247,345,367,250,369,252,253,355,729],"iso-8859-3":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,294,728,163,164,null,292,167,168,304,350,286,308,173,null,379,176,295,178,179,180,181,293,183,184,305,351,287,309,189,null,380,192,193,194,null,196,266,264,199,200,201,202,203,204,205,206,207,null,209,210,211,212,288,214,215,284,217,218,219,220,364,348,223,224,225,226,null,228,267,265,231,232,233,234,235,236,237,238,239,null,241,242,243,244,289,246,247,285,249,250,251,252,365,349,729],"iso-8859-4":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,260,312,342,164,296,315,167,168,352,274,290,358,173,381,175,176,261,731,343,180,297,316,711,184,353,275,291,359,330,382,331,256,193,194,195,196,197,198,302,268,201,280,203,278,205,206,298,272,325,332,310,212,213,214,215,216,370,218,219,220,360,362,223,257,225,226,227,228,229,230,303,269,233,281,235,279,237,238,299,273,326,333,311,244,245,246,247,248,371,250,251,252,361,363,729],"iso-8859-5":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,1025,1026,1027,1028,1029,1030,1031,1032,1033,1034,1035,1036,173,1038,1039,1040,1041,1042,1043,1044,1045,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103,8470,1105,1106,1107,1108,1109,1110,1111,1112,1113,1114,1115,1116,167,1118,1119],"iso-8859-6":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,null,null,null,164,null,null,null,null,null,null,null,1548,173,null,null,null,null,null,null,null,null,null,null,null,null,null,1563,null,null,null,1567,null,1569,1570,1571,1572,1573,1574,1575,1576,1577,1578,1579,1580,1581,1582,1583,1584,1585,1586,1587,1588,1589,1590,1591,1592,1593,1594,null,null,null,null,null,1600,1601,1602,1603,1604,1605,1606,1607,1608,1609,1610,1611,1612,1613,1614,1615,1616,1617,1618,null,null,null,null,null,null,null,null,null,null,null,null,null],"iso-8859-7":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,8216,8217,163,8364,8367,166,167,168,169,890,171,172,173,null,8213,176,177,178,179,900,901,902,183,904,905,906,187,908,189,910,911,912,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,null,931,932,933,934,935,936,937,938,939,940,941,942,943,944,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,962,963,964,965,966,967,968,969,970,971,972,973,974,null],"iso-8859-8":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,null,162,163,164,165,166,167,168,169,215,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,247,187,188,189,190,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,null,8215,1488,1489,1490,1491,1492,1493,1494,1495,1496,1497,1498,1499,1500,1501,1502,1503,1504,1505,1506,1507,1508,1509,1510,1511,1512,1513,1514,null,null,8206,8207,null],"iso-8859-10":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,260,274,290,298,296,310,167,315,272,352,358,381,173,362,330,176,261,275,291,299,297,311,183,316,273,353,359,382,8213,363,331,256,193,194,195,196,197,198,302,268,201,280,203,278,205,206,207,208,325,332,211,212,213,214,360,216,370,218,219,220,221,222,223,257,225,226,227,228,229,230,303,269,233,281,235,279,237,238,239,240,326,333,243,244,245,246,361,248,371,250,251,252,253,254,312],"iso-8859-13":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,8221,162,163,164,8222,166,167,216,169,342,171,172,173,174,198,176,177,178,179,8220,181,182,183,248,185,343,187,188,189,190,230,260,302,256,262,196,197,280,274,268,201,377,278,290,310,298,315,352,323,325,211,332,213,214,215,370,321,346,362,220,379,381,223,261,303,257,263,228,229,281,275,269,233,378,279,291,311,299,316,353,324,326,243,333,245,246,247,371,322,347,363,252,380,382,8217],"iso-8859-14":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,7682,7683,163,266,267,7690,167,7808,169,7810,7691,7922,173,174,376,7710,7711,288,289,7744,7745,182,7766,7809,7767,7811,7776,7923,7812,7813,7777,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,372,209,210,211,212,213,214,7786,216,217,218,219,220,221,374,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,373,241,242,243,244,245,246,7787,248,249,250,251,252,253,375,255],"iso-8859-15":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,8364,165,352,167,353,169,170,171,172,173,174,175,176,177,178,179,381,181,182,183,382,185,186,187,338,339,376,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255],"iso-8859-16":[128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146,147,148,149,150,151,152,153,154,155,156,157,158,159,160,260,261,321,8364,8222,352,167,353,169,536,171,377,173,378,379,176,177,268,322,381,8221,182,183,382,269,537,187,338,339,376,380,192,193,194,258,196,262,198,199,200,201,202,203,204,205,206,207,272,323,210,211,212,336,214,346,368,217,218,219,220,280,538,223,224,225,226,259,228,263,230,231,232,233,234,235,236,237,238,239,273,324,242,243,244,337,246,347,369,249,250,251,252,281,539,255],"koi8-r":[9472,9474,9484,9488,9492,9496,9500,9508,9516,9524,9532,9600,9604,9608,9612,9616,9617,9618,9619,8992,9632,8729,8730,8776,8804,8805,160,8993,176,178,183,247,9552,9553,9554,1105,9555,9556,9557,9558,9559,9560,9561,9562,9563,9564,9565,9566,9567,9568,9569,1025,9570,9571,9572,9573,9574,9575,9576,9577,9578,9579,9580,169,1102,1072,1073,1094,1076,1077,1092,1075,1093,1080,1081,1082,1083,1084,1085,1086,1087,1103,1088,1089,1090,1091,1078,1074,1100,1099,1079,1096,1101,1097,1095,1098,1070,1040,1041,1062,1044,1045,1060,1043,1061,1048,1049,1050,1051,1052,1053,1054,1055,1071,1056,1057,1058,1059,1046,1042,1068,1067,1047,1064,1069,1065,1063,1066],"koi8-u":[9472,9474,9484,9488,9492,9496,9500,9508,9516,9524,9532,9600,9604,9608,9612,9616,9617,9618,9619,8992,9632,8729,8730,8776,8804,8805,160,8993,176,178,183,247,9552,9553,9554,1105,1108,9556,1110,1111,9559,9560,9561,9562,9563,1169,1118,9566,9567,9568,9569,1025,1028,9571,1030,1031,9574,9575,9576,9577,9578,1168,1038,169,1102,1072,1073,1094,1076,1077,1092,1075,1093,1080,1081,1082,1083,1084,1085,1086,1087,1103,1088,1089,1090,1091,1078,1074,1100,1099,1079,1096,1101,1097,1095,1098,1070,1040,1041,1062,1044,1045,1060,1043,1061,1048,1049,1050,1051,1052,1053,1054,1055,1071,1056,1057,1058,1059,1046,1042,1068,1067,1047,1064,1069,1065,1063,1066],macintosh:[196,197,199,201,209,214,220,225,224,226,228,227,229,231,233,232,234,235,237,236,238,239,241,243,242,244,246,245,250,249,251,252,8224,176,162,163,167,8226,182,223,174,169,8482,180,168,8800,198,216,8734,177,8804,8805,165,181,8706,8721,8719,960,8747,170,186,937,230,248,191,161,172,8730,402,8776,8710,171,187,8230,160,192,195,213,338,339,8211,8212,8220,8221,8216,8217,247,9674,255,376,8260,8364,8249,8250,64257,64258,8225,183,8218,8222,8240,194,202,193,203,200,205,206,207,204,211,212,63743,210,218,219,217,305,710,732,175,728,729,730,184,733,731,711],"windows-874":[8364,129,130,131,132,8230,134,135,136,137,138,139,140,141,142,143,144,8216,8217,8220,8221,8226,8211,8212,152,153,154,155,156,157,158,159,160,3585,3586,3587,3588,3589,3590,3591,3592,3593,3594,3595,3596,3597,3598,3599,3600,3601,3602,3603,3604,3605,3606,3607,3608,3609,3610,3611,3612,3613,3614,3615,3616,3617,3618,3619,3620,3621,3622,3623,3624,3625,3626,3627,3628,3629,3630,3631,3632,3633,3634,3635,3636,3637,3638,3639,3640,3641,3642,null,null,null,null,3647,3648,3649,3650,3651,3652,3653,3654,3655,3656,3657,3658,3659,3660,3661,3662,3663,3664,3665,3666,3667,3668,3669,3670,3671,3672,3673,3674,3675,null,null,null,null],"windows-1250":[8364,129,8218,131,8222,8230,8224,8225,136,8240,352,8249,346,356,381,377,144,8216,8217,8220,8221,8226,8211,8212,152,8482,353,8250,347,357,382,378,160,711,728,321,164,260,166,167,168,169,350,171,172,173,174,379,176,177,731,322,180,181,182,183,184,261,351,187,317,733,318,380,340,193,194,258,196,313,262,199,268,201,280,203,282,205,206,270,272,323,327,211,212,336,214,215,344,366,218,368,220,221,354,223,341,225,226,259,228,314,263,231,269,233,281,235,283,237,238,271,273,324,328,243,244,337,246,247,345,367,250,369,252,253,355,729],"windows-1251":[1026,1027,8218,1107,8222,8230,8224,8225,8364,8240,1033,8249,1034,1036,1035,1039,1106,8216,8217,8220,8221,8226,8211,8212,152,8482,1113,8250,1114,1116,1115,1119,160,1038,1118,1032,164,1168,166,167,1025,169,1028,171,172,173,174,1031,176,177,1030,1110,1169,181,182,183,1105,8470,1108,187,1112,1029,1109,1111,1040,1041,1042,1043,1044,1045,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,1072,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,1103],"windows-1252":[8364,129,8218,402,8222,8230,8224,8225,710,8240,352,8249,338,141,381,143,144,8216,8217,8220,8221,8226,8211,8212,732,8482,353,8250,339,157,382,376,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,208,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,240,241,242,243,244,245,246,247,248,249,250,251,252,253,254,255],"windows-1253":[8364,129,8218,402,8222,8230,8224,8225,136,8240,138,8249,140,141,142,143,144,8216,8217,8220,8221,8226,8211,8212,152,8482,154,8250,156,157,158,159,160,901,902,163,164,165,166,167,168,169,null,171,172,173,174,8213,176,177,178,179,900,181,182,183,904,905,906,187,908,189,910,911,912,913,914,915,916,917,918,919,920,921,922,923,924,925,926,927,928,929,null,931,932,933,934,935,936,937,938,939,940,941,942,943,944,945,946,947,948,949,950,951,952,953,954,955,956,957,958,959,960,961,962,963,964,965,966,967,968,969,970,971,972,973,974,null],"windows-1254":[8364,129,8218,402,8222,8230,8224,8225,710,8240,352,8249,338,141,142,143,144,8216,8217,8220,8221,8226,8211,8212,732,8482,353,8250,339,157,158,376,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205,206,207,286,209,210,211,212,213,214,215,216,217,218,219,220,304,350,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,287,241,242,243,244,245,246,247,248,249,250,251,252,305,351,255],"windows-1255":[8364,129,8218,402,8222,8230,8224,8225,710,8240,138,8249,140,141,142,143,144,8216,8217,8220,8221,8226,8211,8212,732,8482,154,8250,156,157,158,159,160,161,162,163,8362,165,166,167,168,169,215,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,247,187,188,189,190,191,1456,1457,1458,1459,1460,1461,1462,1463,1464,1465,1466,1467,1468,1469,1470,1471,1472,1473,1474,1475,1520,1521,1522,1523,1524,null,null,null,null,null,null,null,1488,1489,1490,1491,1492,1493,1494,1495,1496,1497,1498,1499,1500,1501,1502,1503,1504,1505,1506,1507,1508,1509,1510,1511,1512,1513,1514,null,null,8206,8207,null],"windows-1256":[8364,1662,8218,402,8222,8230,8224,8225,710,8240,1657,8249,338,1670,1688,1672,1711,8216,8217,8220,8221,8226,8211,8212,1705,8482,1681,8250,339,8204,8205,1722,160,1548,162,163,164,165,166,167,168,169,1726,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,1563,187,188,189,190,1567,1729,1569,1570,1571,1572,1573,1574,1575,1576,1577,1578,1579,1580,1581,1582,1583,1584,1585,1586,1587,1588,1589,1590,215,1591,1592,1593,1594,1600,1601,1602,1603,224,1604,226,1605,1606,1607,1608,231,232,233,234,235,1609,1610,238,239,1611,1612,1613,1614,244,1615,1616,247,1617,249,1618,251,252,8206,8207,1746],"windows-1257":[8364,129,8218,131,8222,8230,8224,8225,136,8240,138,8249,140,168,711,184,144,8216,8217,8220,8221,8226,8211,8212,152,8482,154,8250,156,175,731,159,160,null,162,163,164,null,166,167,216,169,342,171,172,173,174,198,176,177,178,179,180,181,182,183,248,185,343,187,188,189,190,230,260,302,256,262,196,197,280,274,268,201,377,278,290,310,298,315,352,323,325,211,332,213,214,215,370,321,346,362,220,379,381,223,261,303,257,263,228,229,281,275,269,233,378,279,291,311,299,316,353,324,326,243,333,245,246,247,371,322,347,363,252,380,382,729],"windows-1258":[8364,129,8218,402,8222,8230,8224,8225,710,8240,138,8249,338,141,142,143,144,8216,8217,8220,8221,8226,8211,8212,732,8482,154,8250,339,157,158,376,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,258,196,197,198,199,200,201,202,203,768,205,206,207,272,209,777,211,212,416,214,215,216,217,218,219,220,431,771,223,224,225,226,259,228,229,230,231,232,233,234,235,769,237,238,239,273,241,803,243,244,417,246,247,248,249,250,251,252,432,8363,255],"x-mac-cyrillic":[1040,1041,1042,1043,1044,1045,1046,1047,1048,1049,1050,1051,1052,1053,1054,1055,1056,1057,1058,1059,1060,1061,1062,1063,1064,1065,1066,1067,1068,1069,1070,1071,8224,176,1168,163,167,8226,182,1030,174,169,8482,1026,1106,8800,1027,1107,8734,177,8804,8805,1110,181,1169,1032,1028,1108,1031,1111,1033,1113,1034,1114,1112,1029,172,8730,402,8776,8710,171,187,8230,160,1035,1115,1036,1116,1109,8211,8212,8220,8221,8216,8217,247,8222,1038,1118,1039,1119,8470,1025,1105,1103,1072,1073,1074,1075,1076,1077,1078,1079,1080,1081,1082,1083,1084,1085,1086,1087,1088,1089,1090,1091,1092,1093,1094,1095,1096,1097,1098,1099,1100,1101,1102,8364]}}(this||{})},function(e,t,n){!function(t){"use strict";var r={};e.exports?(r.bytesToHex=n(1778).bytesToHex,r.convertString=n(1779),e.exports=u):(r.bytesToHex=t.convertHex.bytesToHex,r.convertString=t.convertString,t.sha256=u);var i=[];!function(){function e(e){for(var t=Math.sqrt(e),n=2;n<=t;n++)if(!(e%n))return!1;return!0}function t(e){return 4294967296*(e-(0|e))|0}for(var n=2,r=0;r<64;)e(n)&&(i[r]=t(Math.pow(n,1/3)),r++),n++}();var o=function(e){for(var t=[],n=0,r=0;n<e.length;n++,r+=8)t[r>>>5]|=e[n]<<24-r%32;return t},s=function(e){for(var t=[],n=0;n<32*e.length;n+=8)t.push(e[n>>>5]>>>24-n%32&255);return t},a=[],l=function(e,t,n){for(var r=e[0],o=e[1],s=e[2],l=e[3],u=e[4],c=e[5],h=e[6],f=e[7],p=0;p<64;p++){if(p<16)a[p]=0|t[n+p];else{var d=a[p-15],m=(d<<25|d>>>7)^(d<<14|d>>>18)^d>>>3,g=a[p-2],y=(g<<15|g>>>17)^(g<<13|g>>>19)^g>>>10;a[p]=m+a[p-7]+y+a[p-16]}var v=u&c^~u&h,b=r&o^r&s^o&s,_=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),w=(u<<26|u>>>6)^(u<<21|u>>>11)^(u<<7|u>>>25),k=f+w+v+i[p]+a[p],E=_+b;f=h,h=c,c=u,u=l+k|0,l=s,s=o,o=r,r=k+E|0}e[0]=e[0]+r|0,e[1]=e[1]+o|0,e[2]=e[2]+s|0,e[3]=e[3]+l|0,e[4]=e[4]+u|0,e[5]=e[5]+c|0,e[6]=e[6]+h|0,e[7]=e[7]+f|0};function u(e,t){e.constructor===String&&(e=r.convertString.UTF8.stringToBytes(e));var n=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],i=o(e),a=8*e.length;i[a>>5]|=128<<24-a%32,i[15+(a+64>>9<<4)]=a;for(var u=0;u<i.length;u+=16)l(n,i,u);var c=s(n);return t&&t.asBytes?c:t&&t.asString?r.convertString.bytesToString(c):r.bytesToHex(c)}u.x2=function(e,t){return u(u(e,{asBytes:!0}),t)}}(this)},function(e,t,n){!function(t){"use strict";var n={bytesToHex:function(e){return r(e)},hexToBytes:function(e){if(e.length%2==1)throw new Error("hexToBytes can't have a string with an odd number of characters.");return 0===e.indexOf("0x")&&(e=e.slice(2)),e.match(/../g).map(function(e){return parseInt(e,16)})}};function r(e){return e.map(function(e){return i(e.toString(16),2)}).join("")}function i(e,t){return e.length>t?e:Array(t-e.length+1).join("0")+e}e.exports?e.exports=n:t.convertHex=n}(this)},function(e,t,n){!function(t){"use strict";var n={bytesToString:function(e){return e.map(function(e){return String.fromCharCode(e)}).join("")},stringToBytes:function(e){return e.split("").map(function(e){return e.charCodeAt(0)})}};n.UTF8={bytesToString:function(e){return decodeURIComponent(escape(n.bytesToString(e)))},stringToBytes:function(e){return n.stringToBytes(unescape(encodeURIComponent(e)))}},e.exports?e.exports=n:t.convertString=n}(this)},function(e,t){class n extends Error{constructor(e="200",...t){super(...t),Error.captureStackTrace&&Error.captureStackTrace(this,n),this.statusCode=e,this.date=new Date}}e.exports=n},function(e,t,n){const r=n(1782),i=0,o=1,s=2,a=0,l=0;class u{constructor(){this.provider="https://cloud.wolk.com",this.developerTrustLevel=a,this.userTrustLevel=l,this.setWolkTrustLevel()}async init(){return this.dbPromise=r.openDb("names",1,e=>{e.createObjectStore("names",{keyPath:"name"})}),await this.dbPromise.then(async e=>await this.loadAccounts()).catch(e=>{throw console.log("WOLK: loadAccount error: "+e),new Error("Error loading accounts: "+e)})}setProvider(e){this.provider=e}setDeveloperTrustLevel(e){this.developerTrustLevel=e}setUserTrustLevel(e){this.userTrustLevel=e}setWolkTrustLevel(){this.userTrustLevel>this.developerTrustLevel?this.wolkTrustLevel=this.userTrustLevel:this.wolkTrustLevel=this.developerTrustLevel}determineProofValue(){let e=Math.random();return e<=this.wolkTrustLevel?1:0}loadAccounts(e){var t=this,n=null;return this.dbPromise.then(e=>e.transaction(["names"],"readonly").objectStore("names").getAll()).then(e=>{if(e.length>0){let r=e[e.length-1];console.log("WOLK: last Account",r);var n=r.ecdsaPrivateKey;return"object"==typeof r.ecdsaPrivateKey||(n=JSON.parse(r.ecdsaPrivateKey)),window.crypto.subtle.importKey("jwk",n,{name:"ECDSA",namedCurve:"P-256"},!1,["sign"]).then(function(e){t.ecdsaKey={},t.ecdsaKey.privateKey=e,t.ecdsaPublicKey=r.ecdsaPublicKey,console.log("WOLK: loadAccounts",e);var n=r.rsaPrivateKey;return"object"==typeof r.rsaPrivateKey||(n=JSON.parse(r.rsaPrivateKey)),window.crypto.subtle.importKey("jwk",n,{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}},!1,["sign"]).then(function(e){t.rsaKey=e,console.log("Loaded")}).catch(function(e){console.error(e)})}).catch(function(e){console.error(e)})}console.log("# of Accounts",e.length)}).catch(e=>{console.log(e)})}async createAccount(e,t){let n=this;e=e.toLowerCase(),console.log("createAccount",e),await window.crypto.subtle.generateKey({name:"RSASSA-PKCS1-v1_5",modulusLength:2048,publicExponent:new Uint8Array([1,0,1]),hash:{name:"SHA-256"}},!0,["sign","verify"]).then(r=>{var i={};return window.crypto.subtle.exportKey("jwk",r.privateKey).then(function(e){return i.rsaPrivateKey=e,window.crypto.subtle.exportKey("jwk",r.publicKey)}).then(function(e){return i.rsaPrivateKey=e,window.crypto.subtle.generateKey({name:"ECDSA",namedCurve:"P-256"},!0,["sign","verify"])}).then(function(r){return window.crypto.subtle.exportKey("jwk",r.privateKey).then(function(e){return i.ecdsaPrivateKey=e,window.crypto.subtle.exportKey("jwk",r.publicKey)}).then(function(o){return i.ecdsaPublicKey=o,i.name=e,console.log(i),n.dbPromise.then(e=>e.transaction(["names"],"readwrite").objectStore("names").put(i)).then(()=>(n.ecdsaPublicKey=JSON.stringify(i.ecdsaPublicKey),n.ecdsaPrivateKey=i.ecdsaPrivateKey,n.ecdsaKey=r,n.setName(e,JSON.stringify(i.rsaPublicKey),t))).catch(e=>{i={},console.error("ERROR sending name: "+e)})}).catch(e=>{i={},console.error("ERROR setting up keys: "+e)})}).catch(e=>{i={},console.err("ERROR parsing ecdsaKey: "+e)})}).catch(e=>{account={},console.err("ERROR generating account: "+e)})}setName(e,t,n){return this.post(e,{name:e,rsaPublicKey:btoa(t)},{},n)}getBlock(e,t){return this.get(joinPath("wolk","block",e.toString(10)),{},t).catch(e=>{throw e})}getNode(e,t){return this.get(joinPath("wolk","node",e.toString(10)),{},t).catch(e=>{throw e})}updateNode(e,t,n){return this.patch(joinPath("wolk","node",e.toString(10)),t,{},n).catch(e=>{throw e})}getPeers(e,t){return this.get(joinPath("wolk","info"),{},t).catch(e=>{throw e})}getName(e,t){return this.get(joinPath("wolk","name",e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getAccount(e,t){return this.get(joinPath("wolk","account",e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}getLatestBlockNumber(e){return this.get(joinPath("wolk","block","latest"),{},e).catch(e=>{throw e})}getTransaction(e,t){return this.get(joinPath("wolk","tx",e),{},t).catch(e=>{throw e})}transfer(e,t,n){return this.post(joinPath("wolk","transfer"),{recipient:e,amount:t},{},n)}createCollection(e,t,n){return this.post(joinPath(e,t),JSON.stringify({name:t,bucketType:o,requesterPays:0,encryption:"none"}),{},n)}listCollections(e,t){return this.get(e,{Proof:this.determineProofValue()},t).catch(e=>{throw e})}listCollection(e,t,n){return this.get(joinPath(e,t),{Proof:this.determineProofValue()},n)}deleteCollection(e,t,n){return this.delete(joinPath(e,t),{},n)}scanCollection(e,t,n,r){return this.get(joinPath(e,t),{Proof:this.determineProofValue()},r).catch(e=>{throw e})}setKey(e,t,n,r,i){return this.put(joinPath(e,t,n),r,{},i)}getKey(e,t,n,r,i){return this.get(joinPath(e,t,n),{Proof:this.determineProofValue()},i).catch(e=>{throw e})}deleteKey(e,t,n,r){return this.delete(joinPath(e,t,n),{},r)}createDatabase(e,t,n,r){return this.post(joinPath(e,t),JSON.stringify({name:t,bucketType:s,requesterPays:0,encryption:"none"}),n,{},r)}listDatabases(e,t){return this.get(joinPath(e),{Proof:this.determineProofValue()},t).catch(e=>{throw e})}deleteDatabase(e,t,n){return this.delete(joinPath(e,collection),{},n)}executeSQL(e,t,n,r,i){return this.post(joinPath(e,t,n),n,r,i)}async get(e,t,n){return this.wrequest("GET",e,null,t,n)}async post(e,t,n,r){return this.wrequest("POST",e,t,n,r)}async put(e,t,n,r){return this.wrequest("PUT",e,t,n,r)}async patch(e,t,n,r){return this.wrequest("PATCH",e,t,n,r)}async delete(e,t,n){return this.wrequest("DELETE",e,null,t,n)}sleep(e){return new Promise(t=>setTimeout(t,e))}async waitForTx(e,t){let n=!1,r=0;for(;!n;)if(this.getTransaction(e,function(e,r,i){if(e);else try{let e=JSON.parse(r);if(void 0!=e.BlockNumber)return n=!0,t(null,e)}catch(e){}}),await this.sleep(500),r++>15)return n=!0,t(new Error("timeout, tx not included"),null)}async wrequest(e,t,n,r,i){let o=new TextEncoder("utf-8"),s=e+"/"+t;"POST"!=e&&"PATCH"!=e||("object"==typeof n&&(n=JSON.stringify(n)),null!=n&&(s+=n));let a=o.encode(s),l=this;var u={method:e,headers:{Requester:l.ecdsaPublicKey,Msg:s},body:n};if("function"!=typeof i)return console.log("WOLK: Promise route"),window.crypto.subtle.sign({name:"ECDSA",hash:{name:"SHA-256"}},this.ecdsaKey.privateKey,a).then(function(e){u.headers.Sig=c(e);var n=l.provider+"/"+t;return fetch(n,u).then(function(e){if(e.ok)return e.text();throw console.log("ERROR:",e.status,e.statusText),new Error(e)}).then(function(e){let t=!0;return e}).catch(function(e){throw console.log(e),e})}).catch(function(e){throw console.error(e),e});window.crypto.subtle.sign({name:"ECDSA",hash:{name:"SHA-256"}},this.ecdsaKey.privateKey,a).then(function(e){u.headers.Sig=c(e);var n=l.provider+"/"+t;fetch(n,u).then(function(e){return e.ok?e.text():(console.log("ERROR:",e.status,e.statusText),i(new Error(e.text()),null,!1))}).then(function(e){let t=!0;return i(null,e,!0)}).catch(function(e){console.log(e),i(e,null,!1)})}).catch(function(e){console.error(e),i(e,null,!1)})}}function c(e){return Array.prototype.map.call(new Uint8Array(e),e=>("00"+e.toString(16)).slice(-2)).join("")}function h(e,t){return e+t}joinPath=((...e)=>e.map((e,t)=>0===t?e.trim().replace(/[\/]*$/g,""):e.trim().replace(/(^[\/]*|[\/]*$)/g,"")).filter(e=>e.length).join("/")),"undefined"!=typeof window&&void 0===window.WOLK&&(window.WOLK=u),e.exports=u},function(e,t,n){var r,i;r=this,i=function(e){"use strict";function t(e){return Array.prototype.slice.call(e)}function n(e){return new Promise(function(t,n){e.onsuccess=function(){t(e.result)},e.onerror=function(){n(e.error)}})}function r(e,t,r){var i,o=new Promise(function(o,s){i=e[t].apply(e,r),n(i).then(o,s)});return o.request=i,o}function i(e,t,n){var i=r(e,t,n);return i.then(function(e){if(e)return new c(e,i.request)})}function o(e,t,n){n.forEach(function(n){Object.defineProperty(e.prototype,n,{get:function(){return this[t][n]},set:function(e){this[t][n]=e}})})}function s(e,t,n,i){i.forEach(function(i){i in n.prototype&&(e.prototype[i]=function(){return r(this[t],i,arguments)})})}function a(e,t,n,r){r.forEach(function(r){r in n.prototype&&(e.prototype[r]=function(){return this[t][r].apply(this[t],arguments)})})}function l(e,t,n,r){r.forEach(function(r){r in n.prototype&&(e.prototype[r]=function(){return i(this[t],r,arguments)})})}function u(e){this._index=e}function c(e,t){this._cursor=e,this._request=t}function h(e){this._store=e}function f(e){this._tx=e,this.complete=new Promise(function(t,n){e.oncomplete=function(){t()},e.onerror=function(){n(e.error)},e.onabort=function(){n(e.error)}})}function p(e,t,n){this._db=e,this.oldVersion=t,this.transaction=new f(n)}function d(e){this._db=e}function m(e,t,n){var i=r(indexedDB,"open",[e,t]),o=i.request;return o&&(o.onupgradeneeded=function(e){n&&n(new p(o.result,e.oldVersion,o.transaction))}),i.then(function(e){return new d(e)})}function g(e){return r(indexedDB,"deleteDatabase",[e])}o(u,"_index",["name","keyPath","multiEntry","unique"]),s(u,"_index",IDBIndex,["get","getKey","getAll","getAllKeys","count"]),l(u,"_index",IDBIndex,["openCursor","openKeyCursor"]),o(c,"_cursor",["direction","key","primaryKey","value"]),s(c,"_cursor",IDBCursor,["update","delete"]),["advance","continue","continuePrimaryKey"].forEach(function(e){e in IDBCursor.prototype&&(c.prototype[e]=function(){var t=this,r=arguments;return Promise.resolve().then(function(){return t._cursor[e].apply(t._cursor,r),n(t._request).then(function(e){if(e)return new c(e,t._request)})})})}),h.prototype.createIndex=function(){return new u(this._store.createIndex.apply(this._store,arguments))},h.prototype.index=function(){return new u(this._store.index.apply(this._store,arguments))},o(h,"_store",["name","keyPath","indexNames","autoIncrement"]),s(h,"_store",IDBObjectStore,["put","add","delete","clear","get","getAll","getKey","getAllKeys","count"]),l(h,"_store",IDBObjectStore,["openCursor","openKeyCursor"]),a(h,"_store",IDBObjectStore,["deleteIndex"]),f.prototype.objectStore=function(){return new h(this._tx.objectStore.apply(this._tx,arguments))},o(f,"_tx",["objectStoreNames","mode"]),a(f,"_tx",IDBTransaction,["abort"]),p.prototype.createObjectStore=function(){return new h(this._db.createObjectStore.apply(this._db,arguments))},o(p,"_db",["name","version","objectStoreNames"]),a(p,"_db",IDBDatabase,["deleteObjectStore","close"]),d.prototype.transaction=function(){return new f(this._db.transaction.apply(this._db,arguments))},o(d,"_db",["name","version","objectStoreNames"]),a(d,"_db",IDBDatabase,["close"]),["openCursor","openKeyCursor"].forEach(function(e){[h,u].forEach(function(n){e in n.prototype&&(n.prototype[e.replace("open","iterate")]=function(){var n=t(arguments),r=n[n.length-1],i=this._store||this._index,o=i[e].apply(i,n.slice(0,-1));o.onsuccess=function(){r(o.result)}})})}),[u,h].forEach(function(e){e.prototype.getAll||(e.prototype.getAll=function(e,t){var n=this,r=[];return new Promise(function(i){n.iterateCursor(e,function(e){e?(r.push(e.value),void 0===t||r.length!=t?e.continue():i(r)):i(r)})})})}),e.openDb=m,e.deleteDb=g,Object.defineProperty(e,"__esModule",{value:!0})},i(t)},function(e,t,n){(function(r){const i=n(32);r.env.GUN_ENV="false";const o=n(144);n(1785),n(637),n(638),n(1786),n(1788);const s=n(4)("dweb-transports:gun"),a=n(184),l=n(77),u=n(111),c=n(94),h=n(146);let f={peers:["https://dweb.me:4246/gun"],localStorage:!1};class p extends u{constructor(e){super(e),this.options=e,this.gun=void 0,this.name="GUN",this.supportURLs=["gun"],this.supportFunctions=["fetch","connection","get","set","getall","keys","newdatabase","newtable","monitor","add","list","listmonitor","newlisturls"],this.supportFeatures=[],this.status=u.STATUS_LOADED}connection(e){e=i.parse(e);let t=e.pathname.split("/");return t.shift(),t.shift(),s("path=",t),this.gun.path(t)}static setup0(e){let t=u.mergeoptions(f,e.gun);s("options %o",t);let n=new p(t);return n.gun=new o(n.options),c.addtransport(n),n}async p_setup1(e){try{this.status=u.STATUS_STARTING,e&&e(this),await this.p_status()}catch(e){console.error(this.name,"failed to start",e),this.status=u.STATUS_FAILED}return e&&e(this),this}async p_status(){return this.status=u.STATUS_CONNECTED,this.status}async p_rawfetch(e){e=i.parse(e);let t=this.connection(e),n=await this._p_once(t);if(!n)throw new l.TransportError("GUN unable to retrieve: "+e.href);let r="string"==typeof n?JSON.parse(n):n;if(r.metadata&&r.metadata.thumbnaillinks&&r.metadata.thumbnaillinks.find(e=>e.includes("ipfs/zb2")))throw new l.TransportError("GUN retrieving legacy data at: "+e.href);return r}async p_rawlist(e){try{let t=this.connection(e),n=await this._p_once(t),r=n?Object.keys(n).filter(e=>"_"!==e).sort().map(e=>n[e]):[];return s("p_rawlist found",...h.consolearr(r)),r}catch(e){throw e}}listmonitor(e,t,{current:n=!1}={}){let r=this.connection(e);n?r.map().on((e,n)=>t("set",n,JSON.parse(e))):r.once(e=>{this.monitored=e?Object.keys(e):[],r.map().on((e,n)=>{this.monitored.includes(n)||"_"===n||(this.monitored.push(n),t(JSON.parse(e)))})})}async p_rawadd(e,t){console.assert(e&&t.urls.length&&t.signature&&t.signedby.length,"TransportGUN.p_rawadd args",e,t),this.connection(e).set(a(t.preflight(Object.assign({},t))))}async p_newlisturls(e){let t=await this._p_newgun(e);return[t,t]}async _p_newgun(e){return e.hasOwnProperty("keypair")&&(e=e.keypair.signingexport()),`gun:/gun/${encodeURIComponent(e)}`}async p_newdatabase(e){let t=await this._p_newgun(e);return{publicurl:t,privateurl:t}}async p_newtable(e,t){if(!e)throw new l.CodingError("p_newtable currently requires a pubkey");let n=await this.p_newdatabase(e);return{privateurl:`${n.privateurl}/${t}`,publicurl:`${n.publicurl}/${t}`}}async p_set(e,t,n){let r=this.connection(e);"string"==typeof t?r.path(t).put(a(n)):(console.assert(!Array.isArray(t),"TransportGUN - shouldnt be passsing an array as the keyvalues"),r.put(Object.keys(t).reduce(function(e,n){return e[n]=a(t[n]),e},{})))}async p_get(e,t){let n=this.connection(e);if(Array.isArray(t))throw new l.ToBeImplementedError("p_get(url, [keys]) isn't supported - because of ambiguity better to explicitly loop on set of keys or use getall and filter");{let e=await this._p_once(n.get(t));return"string"==typeof e?JSON.parse(e):e}}async p_delete(e,t){let n=this.connection(e);"string"==typeof t?n.path(t).put(null):t.map(e=>n.path(e).put(null))}_p_once(e){return new Promise(t=>e.once(t,{wait:2e3}))}async p_keys(e){let t=await this._p_once(this.connection(e));return Object.keys(t).filter(e=>"_"!==e&&null!==t[e])}async p_getall(e){let t=await this._p_once(this.connection(e));return Object.keys(t).filter(e=>"_"!==e&&null!==t[e]).reduce(function(e,n){return e[n]=JSON.parse(t[n]),e},{})}async monitor(e,t,{current:n=!1}={}){let r=this.connection(e);n?r.map().on((e,n)=>t("set",n,JSON.parse(e))):r.once(e=>{this.monitored=Object.assign({},e),r.map().on((e,n)=>{e!==this.monitored[n]&&"_"!==n&&(this.monitored[n]=e,t("set",n,JSON.parse(e)))})})}static async p_test(){s("p_test");try{let e=this.setup0({});await e.p_setup1(),await e.p_setup2(),e.p_test_kvt("gun:/gun/NACL")}catch(e){throw console.warn("Exception thrown in TransportGUN.test:",e.message),e}}static async demo_bugs(){let e=new o;e.get("foo").get("bar").put("baz"),console.log("Expect {bar: 'baz'} but get {_:..., bar: 'baz'}"),e.get("foo").once(e=>console.log(e)),e.get("zip").get("bar").set("alice"),console.log("Expect {12345: 'alice'} but get {_:..., 12345: 'alice'}"),e.get("foo").once(e=>console.log(e))}}c._transportclasses.GUN=p,t=e.exports=p}).call(this,n(3))},function(e,t){function n(e){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}n.keys=function(){return[]},n.resolve=n,e.exports=n,n.id=1784},function(e,t,n){var r="undefined"!=typeof window?window.Gun:n(144);r.chain.path=function(e,t){var n=this,r=this,i;if("string"==typeof e){if(i=e.split(t||"."),1===i.length)return r=this.get(e),r;e=i}if(e instanceof Array){if(e.length>1){r=this;for(var o=0,s=e.length;o<s;o++)r=r.get(e[o])}else r=this.get(e[0]);return r}return e||0==e?(r=this.get(""+e),r):this}},function(e,t,n){var r="undefined"!=typeof window?window.Gun:n(144);r.on("create",function(e){r.TESTING&&(e.opt.file="radatatest"),this.to.next(e);var t=e.opt,i;if(!1!==t.radisk){var o=r.window&&r.window.Radisk||n(638),s=o.Radix;t.store=t.store||!r.window&&n(1787)(t);var a=o(t),l=String.fromCharCode(27);e.on("put",function(n){this.to.next(n);var s=n["#"]||r.text.random(3),u=!n["@"],h=u?0:i;if(!n.rad||u){var f=+new Date;r.graph.is(n.put,null,function(e,t,n,s){u&&++h,e=o.encode(e,null,l)+">"+o.encode(r.state.is(n,t),null,l),a(s+l+t,e,u?p:i)})}function p(n,r){if(h--,!p.err)if(p.err=n){try{t.store.stats.put.err=n}catch(e){}e.on("in",{"@":s,err:n})}else if(!h){try{t.store.stats.put.time[c%50]=+new Date-f,++c,t.store.stats.put.count++}catch(e){}e.on("in",{"@":s,ok:1})}}}),e.on("get",function(n){this.to.next(n);var c=n["#"],h=n.get,f=n.get["#"],p=n.get["."]||"",d={},m,g,y,v,b;"string"==typeof f?y=f:f&&(i!==(v=f["*"])&&(d.limit=b=1),i!==f[">"]&&(d.start=f[">"]),i!==f["<"]&&(d.end=f["<"]),y=b?""+v:v||f["="],b=null),y&&!d.limit&&("string"==typeof p?y=y+l+(d.atom=p):p&&(i!==p[">"]&&(d.start=p[">"],d.limit=1),i!==p["<"]&&(d.end=p["<"],d.limit=1),i!==(v=p["*"])&&(d.limit=b=1),y&&(y=y+l+(b?""+(v||""):v||(d.atom=p["="]||""))))),((v=h["%"])||d.limit)&&(d.limit=v<=(d.pack||1e5)?v:1),(p["-"]||(f||{})["-"])&&(d.reverse=!0);var _=+new Date;function w(e,t,n,i){if(e){t=(y+t).split(l);var s=t.slice(0,1)[0];t=t.slice(-1)[0],d.count=(d.count||0)+e.length,v=e.lastIndexOf(">");var a=o.decode(e.slice(v+1),null,l);return e=o.decode(e.slice(0,v),null,l),(m=m||{})[s]=r.state.ify(m[s],t,a,e,s),!!(d.limit&&d.limit<=d.count)||void 0}}a(y||"",function(n,r,o){try{t.store.stats.get.time[u%50]=+new Date-_,++u,t.store.stats.get.count++,n&&(t.store.stats.get.err=n)}catch(e){}r&&("string"!=typeof r&&(o.atom?r=i:s.map(r,w)),!m&&r&&w(r,"")),e.on("in",{"@":c,put:m,err:n||i,rad:s})},d)}),t.store.stats={get:{time:{},count:0},put:{time:{},count:0}};var u=0,c=0}})},function(e,t,n){function r(e){e=e||{},e.log=e.log||console.log,e.file=String(e.file||"radata");var t=n(16),i,o=function e(){};if(r[e.file])return console.log("Warning: reusing same fs store and options as 1st."),r[e.file];function s(e,n,r){t.rename(e,n,function(i){if(i)if("EXDEV"===i.code){var o=t.createReadStream(e),s=t.createWriteStream(n);o.on("error",r),s.on("error",r),o.on("close",function(){t.unlink(e,r)}),o.pipe(s)}else r(i);else r()})}return r[e.file]=o,o.put=function(n,r,i){var o=Math.random().toString(36).slice(-3),a=e.file+"-"+n+"-"+o+".tmp";t.writeFile(a,r,function(t,r){if(t)return i(t);s(a,e.file+"/"+n,i)})},o.get=function(n,r){t.readFile(e.file+"/"+n,function(t,n){if(t){if("ENOENT"===(t.code||"").toUpperCase())return r(null);e.log("ERROR:",t)}r(t,n)})},t.existsSync(e.file)||t.mkdirSync(e.file),o}e.exports=r},function(e,t,n){!function(){function t(e){e=e||{},e.file=String(e.file||"radata"),e.chunk=e.chunk||1048576;var n=null,r;try{e.indexedDB=e.indexedDB||indexedDB}catch(e){}try{if(!e.indexedDB||"file:"==location.protocol){var i={},o={};return i.put=function(e,t,n){o[e]=t,n(null,1)},i.get=function(e,t){t(null,o[e]||r)},console.log("Warning: No indexedDB exists to persist data to!"),i}}catch(e){}var i=function e(){};return t[e.file]?(console.log("Warning: reusing same IndexedDB store and options as 1st."),t[e.file]):(t[e.file]=i,i.start=function(){var t=indexedDB.open(e.file,1);t.onupgradeneeded=function(t){t.target.result.createObjectStore(e.file)},t.onsuccess=function(){n=t.result},t.onerror=function(e){console.log(e||1)}},i.start(),i.put=function(t,r,o){if(n){var s=n.transaction([e.file],"readwrite"),a=s.objectStore(e.file),l=a.put(r,""+t);l.onsuccess=a.onsuccess=s.onsuccess=function(){o(null,1)},l.onabort=a.onabort=s.onabort=function(e){o(e||"put.tx.abort")},l.onerror=a.onerror=s.onerror=function(e){o(e||"put.tx.error")}}else setTimeout(function(){i.put(t,r,o)},1)},i.get=function(t,r){if(n){var o=n.transaction([e.file],"readonly"),s=o.objectStore(e.file),a=s.get(""+t);a.onsuccess=function(){r(null,a.result)},a.onabort=function(e){r(e||4)},a.onerror=function(e){r(e||5)}}else setTimeout(function(){i.get(t,r)},9)},setInterval(function(){n&&n.close(),n=null,i.start()},15e3),i)}if("undefined"!=typeof window)(t.window=window).RindexedDB=t;else try{e.exports=t}catch(e){}try{var r=t.window.Gun||n(144);r.on("create",function(e){this.to.next(e),e.opt.store=e.opt.store||t(e.opt)})}catch(e){}}()}]);