Skip to content

Instantly share code, notes, and snippets.

@petarjs
Last active August 7, 2018 17:08
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save petarjs/49946cbf278a922a3948378c8464d7da to your computer and use it in GitHub Desktop.
Save petarjs/49946cbf278a922a3948378c8464d7da to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Page Title</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<h1>Listen to events</h1>
<p>Open the console yo</p>
<script src="./web3.min.js"></script>
<script>
const $ = document.querySelector.bind(document)
document.body.onload = () => {
web3 = new Web3(new Web3.providers.WebsocketProvider('ws://178.128.179.75:8546'))
const address = '0xD1F827037d9EfEDA8e2118d2Df089aF08B04F8A9'
const abi = [{"constant":true,"inputs":[],"name":"owner","outputs":[{"name":"","type":"address"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"newOwner","type":"address"}],"name":"transferOwnership","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"inputs":[{"name":"REWTokenAddress","type":"address"}],"payable":false,"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"name":"creator","type":"address"},{"indexed":false,"name":"publicKey","type":"string"},{"indexed":false,"name":"title","type":"string"},{"indexed":false,"name":"surveyJsonHash","type":"string"},{"indexed":false,"name":"rewardPerSurvey","type":"uint256"}],"name":"LogSurveyAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"creator","type":"address"},{"indexed":false,"name":"publicKey","type":"string"},{"indexed":false,"name":"title","type":"string"},{"indexed":false,"name":"surveyJsonHash","type":"string"},{"indexed":false,"name":"rewardPerSurvey","type":"uint256"}],"name":"LogSurveyFunded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"creator","type":"address"},{"indexed":false,"name":"publicKey","type":"string"},{"indexed":false,"name":"title","type":"string"},{"indexed":false,"name":"surveyJsonHash","type":"string"},{"indexed":false,"name":"rewardPerSurvey","type":"uint256"}],"name":"LogSurveyStarted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"creator","type":"address"},{"indexed":false,"name":"publicKey","type":"string"},{"indexed":false,"name":"title","type":"string"},{"indexed":false,"name":"surveyJsonHash","type":"string"},{"indexed":false,"name":"rewardPerSurvey","type":"uint256"}],"name":"LogSurveyCompleted","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"user","type":"address"},{"indexed":false,"name":"surveyJsonHash","type":"string"},{"indexed":false,"name":"title","type":"string"},{"indexed":false,"name":"rewardPerSurvey","type":"uint256"}],"name":"LogSurveyAnswered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"brandAddress","type":"address"},{"indexed":false,"name":"name","type":"string"},{"indexed":false,"name":"logo","type":"string"},{"indexed":false,"name":"metaHashJson","type":"string"}],"name":"LogBrandAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"productAddress","type":"address"},{"indexed":true,"name":"brandAddress","type":"address"},{"indexed":false,"name":"name","type":"string"},{"indexed":false,"name":"image","type":"string"},{"indexed":false,"name":"metaHashJson","type":"string"}],"name":"LogProductAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"name":"reviewAddress","type":"address"},{"indexed":true,"name":"authorAddress","type":"address"},{"indexed":true,"name":"productAddress","type":"address"}],"name":"LogReviewAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"name":"previousOwner","type":"address"},{"indexed":true,"name":"newOwner","type":"address"}],"name":"OwnershipTransferred","type":"event"},{"constant":false,"inputs":[{"name":"publicKey","type":"string"},{"name":"title","type":"string"},{"name":"surveyJsonHash","type":"string"},{"name":"rewardPerSurvey","type":"uint256"}],"name":"createSurvey","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"surveyJsonHash","type":"string"},{"name":"amount","type":"uint256"}],"name":"fundSurvey","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"surveyJsonHash","type":"string"}],"name":"startSurvey","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"surveyJsonHash","type":"string"}],"name":"completeSurvey","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"surveyJsonHash","type":"string"}],"name":"getFunds","outputs":[{"name":"","type":"uint256"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":true,"inputs":[{"name":"surveyJsonHash","type":"string"}],"name":"getSurveyStatus","outputs":[{"name":"","type":"uint8"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"surveyJsonHash","type":"string"},{"name":"answersJsonHash","type":"string"}],"name":"answerSurvey","outputs":[{"components":[{"name":"answersJsonHash","type":"string"}],"name":"","type":"tuple"}],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":true,"inputs":[{"name":"surveyJsonHash","type":"string"},{"name":"user","type":"address"}],"name":"isSurveyAnsweredBy","outputs":[{"name":"","type":"bool"}],"payable":false,"stateMutability":"view","type":"function"},{"constant":false,"inputs":[{"name":"brandAddress","type":"address"},{"name":"name","type":"string"},{"name":"logo","type":"string"},{"name":"metaJsonHash","type":"string"}],"name":"createBrand","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"productAddress","type":"address"},{"name":"brandAddress","type":"address"},{"name":"name","type":"string"},{"name":"image","type":"string"},{"name":"metaJsonHash","type":"string"}],"name":"createProduct","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"},{"constant":false,"inputs":[{"name":"reviewAddress","type":"address"},{"name":"authorAddress","type":"address"},{"name":"productAddress","type":"address"},{"name":"score","type":"uint256"},{"name":"metaJsonHash","type":"string"}],"name":"createReview","outputs":[],"payable":false,"stateMutability":"nonpayable","type":"function"}]
let contract = new web3.eth.Contract(abi, address)
contract
.getPastEvents('LogSurveyAnswered', {
filter: {},
fromBlock: 0, toBlock: 'latest'
}, (error, events) => {
console.log('LogSurveyAnswered past events', events)
})
contract
.getPastEvents('allEvents', {
filter: {},
fromBlock: 0, toBlock: 'latest'
}, (error, events) => {
console.log('All past events', events)
})
contract
.events.allEvents({
filter: {},
fromBlock: 0, toBlock: 'latest'
}, (error, events) => {
console.log('All events, live', events)
})
}
</script>
</body>
</html>
"use strict";var _typeof2="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof="function"==typeof Symbol&&"symbol"===_typeof2(Symbol.iterator)?function(e){return void 0===e?"undefined":_typeof2(e)}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":void 0===e?"undefined":_typeof2(e)};!function(e){if("object"===("undefined"==typeof exports?"undefined":_typeof(exports))&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).Web3=e()}}(function(){var define,module,exports;return function o(s,a,u){function f(t,e){if(!a[t]){if(!s[t]){var r="function"==typeof require&&require;if(!e&&r)return r(t,!0);if(c)return c(t,!0);var n=new Error("Cannot find module '"+t+"'");throw n.code="MODULE_NOT_FOUND",n}var i=a[t]={exports:{}};s[t][0].call(i.exports,function(e){return f(s[t][1][e]||e)},i,i.exports,o,s,a,u)}return a[t].exports}for(var c="function"==typeof require&&require,e=0;e<u.length;e++)f(u[e]);return f}({1:[function(e,t,r){var n=r;n.bignum=e("bn.js"),n.define=e("./asn1/api").define,n.base=e("./asn1/base"),n.constants=e("./asn1/constants"),n.decoders=e("./asn1/decoders"),n.encoders=e("./asn1/encoders")},{"./asn1/api":2,"./asn1/base":4,"./asn1/constants":8,"./asn1/decoders":10,"./asn1/encoders":13,"bn.js":"BN"}],2:[function(e,t,r){var n=e("../asn1"),i=e("inherits");function o(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}r.define=function(e,t){return new o(e,t)},o.prototype._createNamed=function(t){var r;try{r=e("vm").runInThisContext("(function "+this.name+"(entity) {\n this._initNamed(entity);\n})")}catch(e){r=function(e){this._initNamed(e)}}return i(r,t),r.prototype._initNamed=function(e){t.call(this,e)},new r(this)},o.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(n.decoders[e])),this.decoders[e]},o.prototype.decode=function(e,t,r){return this._getDecoder(t).decode(e,r)},o.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(n.encoders[e])),this.encoders[e]},o.prototype.encode=function(e,t,r){return this._getEncoder(t).encode(e,r)}},{"../asn1":1,inherits:103,vm:169}],3:[function(e,t,r){var n=e("inherits"),i=e("../base").Reporter,o=e("buffer").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 e instanceof a||(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: "+(void 0===e?"undefined":_typeof(e)));this.value=e,this.length=e.length}}n(s,i),(r.DecoderBuffer=s).prototype.save=function(){return{offset:this.offset,reporter:i.prototype.save.call(this)}},s.prototype.restore=function(e){var t=new s(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,i.prototype.restore.call(this,e.reporter),t},s.prototype.isEmpty=function(){return this.offset===this.length},s.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},s.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var r=new s(this.base);return r._reporterState=this._reporterState,r.offset=this.offset,r.length=this.offset+e,this.offset+=e,r},s.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},(r.EncoderBuffer=a).prototype.join=function(t,r){return t||(t=new o(this.length)),r||(r=0),0===this.length||(Array.isArray(this.value)?this.value.forEach(function(e){e.join(t,r),r+=e.length}):("number"==typeof this.value?t[r]=this.value:"string"==typeof this.value?t.write(this.value,r):o.isBuffer(this.value)&&this.value.copy(t,r),r+=this.length)),t}},{"../base":4,buffer:48,inherits:103}],4:[function(e,t,r){var n=r;n.Reporter=e("./reporter").Reporter,n.DecoderBuffer=e("./buffer").DecoderBuffer,n.EncoderBuffer=e("./buffer").EncoderBuffer,n.Node=e("./node")},{"./buffer":3,"./node":5,"./reporter":6}],5:[function(e,t,r){var c=e("../base").Reporter,n=e("../base").EncoderBuffer,l=e("../base").DecoderBuffer,i=e("minimalistic-assert"),o=["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"],s=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(o);function a(e,t){var r={};(this._baseState=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())}t.exports=a;var u=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];a.prototype.clone=function(){var t=this._baseState,r={};u.forEach(function(e){r[e]=t[e]});var e=new this.constructor(r.parent);return e._baseState=r,e},a.prototype._wrap=function(){var r=this._baseState;s.forEach(function(t){this[t]=function(){var e=new this.constructor(this);return r.children.push(e),e[t].apply(e,arguments)}},this)},a.prototype._init=function(e){var t=this._baseState;i(null===t.parent),e.call(this),t.children=t.children.filter(function(e){return e._baseState.parent===this},this),i.equal(t.children.length,1,"Root node can have only one child")},a.prototype._useArgs=function(e){var t=this._baseState,r=e.filter(function(e){return e instanceof this.constructor},this);e=e.filter(function(e){return!(e instanceof this.constructor)},this),0!==r.length&&(i(null===t.children),(t.children=r).forEach(function(e){e._baseState.parent=this},this)),0!==e.length&&(i(null===t.args),t.args=e,t.reverseArgs=e.map(function(r){if("object"!==(void 0===r?"undefined":_typeof(r))||r.constructor!==Object)return r;var n={};return Object.keys(r).forEach(function(e){e==(0|e)&&(e|=0);var t=r[e];n[t]=e}),n}))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach(function(t){a.prototype[t]=function(){var e=this._baseState;throw new Error(t+" not implemented for encoding: "+e.enc)}}),o.forEach(function(r){a.prototype[r]=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return i(null===e.tag),e.tag=r,this._useArgs(t),this}}),a.prototype.use=function(e){i(e);var t=this._baseState;return i(null===t.use),t.use=e,this},a.prototype.optional=function(){return this._baseState.optional=!0,this},a.prototype.def=function(e){var t=this._baseState;return i(null===t.default),t.default=e,t.optional=!0,this},a.prototype.explicit=function(e){var t=this._baseState;return i(null===t.explicit&&null===t.implicit),t.explicit=e,this},a.prototype.implicit=function(e){var t=this._baseState;return i(null===t.explicit&&null===t.implicit),t.implicit=e,this},a.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},a.prototype.key=function(e){var t=this._baseState;return i(null===t.key),t.key=e,this},a.prototype.any=function(){return this._baseState.any=!0,this},a.prototype.choice=function(t){var e=this._baseState;return i(null===e.choice),e.choice=t,this._useArgs(Object.keys(t).map(function(e){return t[e]})),this},a.prototype.contains=function(e){var t=this._baseState;return i(null===t.use),t.contains=e,this},a.prototype._decode=function(t,r){var e=this._baseState;if(null===e.parent)return t.wrapResult(e.children[0]._decode(t,r));var n,i=e.default,o=!0,s=null;if(null!==e.key&&(s=t.enterKey(e.key)),e.optional){var a=null;if(null!==e.explicit?a=e.explicit:null!==e.implicit?a=e.implicit:null!==e.tag&&(a=e.tag),null!==a||e.any){if(o=this._peekTag(t,a,e.any),t.isError(o))return o}else{var u=t.save();try{null===e.choice?this._decodeGeneric(e.tag,t,r):this._decodeChoice(t,r),o=!0}catch(e){o=!1}t.restore(u)}}if(e.obj&&o&&(n=t.enterObject()),o){if(null!==e.explicit){var f=this._decodeTag(t,e.explicit);if(t.isError(f))return f;t=f}var c=t.offset;if(null===e.use&&null===e.choice){if(e.any)u=t.save();var h=this._decodeTag(t,null!==e.implicit?e.implicit:e.tag,e.any);if(t.isError(h))return h;e.any?i=t.raw(u):t=h}if(r&&r.track&&null!==e.tag&&r.track(t.path(),c,t.length,"tagged"),r&&r.track&&null!==e.tag&&r.track(t.path(),t.offset,t.length,"content"),i=e.any?i:null===e.choice?this._decodeGeneric(e.tag,t,r):this._decodeChoice(t,r),t.isError(i))return i;if(e.any||null!==e.choice||null===e.children||e.children.forEach(function(e){e._decode(t,r)}),e.contains&&("octstr"===e.tag||"bitstr"===e.tag)){var d=new l(i);i=this._getUse(e.contains,t._reporterState.obj)._decode(d,r)}}return e.obj&&o&&(i=t.leaveObject(n)),null===e.key||null===i&&!0!==o?null!==s&&t.exitKey(s):t.leaveKey(s,e.key,i),i},a.prototype._decodeGeneric=function(e,t,r){var n=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,n.args[0],r):/str$/.test(e)?this._decodeStr(t,e,r):"objid"===e&&n.args?this._decodeObjid(t,n.args[0],n.args[1],r):"objid"===e?this._decodeObjid(t,null,null,r):"gentime"===e||"utctime"===e?this._decodeTime(t,e,r):"null_"===e?this._decodeNull(t,r):"bool"===e?this._decodeBool(t,r):"objDesc"===e?this._decodeStr(t,e,r):"int"===e||"enum"===e?this._decodeInt(t,n.args&&n.args[0],r):null!==n.use?this._getUse(n.use,t._reporterState.obj)._decode(t,r):t.error("unknown tag: "+e)},a.prototype._getUse=function(e,t){var r=this._baseState;return r.useDecoder=this._use(e,t),i(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},a.prototype._decodeChoice=function(i,o){var s=this._baseState,a=null,u=!1;return Object.keys(s.choice).some(function(e){var t=i.save(),r=s.choice[e];try{var n=r._decode(i,o);if(i.isError(n))return!1;a={type:e,value:n},u=!0}catch(e){return i.restore(t),!1}return!0},this),u?a:i.error("Choice not matched")},a.prototype._createEncoderBuffer=function(e){return new n(e,this.reporter)},a.prototype._encode=function(e,t,r){var n=this._baseState;if(null===n.default||n.default!==e){var i=this._encodeValue(e,t,r);if(void 0!==i&&!this._skipDefault(i,t,r))return i}},a.prototype._encodeValue=function(n,i,e){var t=this._baseState;if(null===t.parent)return t.children[0]._encode(n,i||new c);var r=null;if(this.reporter=i,t.optional&&void 0===n){if(null===t.default)return;n=t.default}var o=null,s=!1;if(t.any)r=this._createEncoderBuffer(n);else if(t.choice)r=this._encodeChoice(n,i);else if(t.contains)o=this._getUse(t.contains,e)._encode(n,i),s=!0;else if(t.children)o=t.children.map(function(e){if("null_"===e._baseState.tag)return e._encode(null,i,n);if(null===e._baseState.key)return i.error("Child should have a key");var t=i.enterKey(e._baseState.key);if("object"!==(void 0===n?"undefined":_typeof(n)))return i.error("Child expected, but input is not object");var r=e._encode(n[e._baseState.key],i,n);return i.leaveKey(t),r},this).filter(function(e){return e}),o=this._createEncoderBuffer(o);else if("seqof"===t.tag||"setof"===t.tag){if(!t.args||1!==t.args.length)return i.error("Too many args for : "+t.tag);if(!Array.isArray(n))return i.error("seqof/setof, but data is not Array");var a=this.clone();a._baseState.implicit=null,o=this._createEncoderBuffer(n.map(function(e){var t=this._baseState;return this._getUse(t.args[0],n)._encode(e,i)},a))}else null!==t.use?r=this._getUse(t.use,e)._encode(n,i):(o=this._encodePrimitive(t.tag,n),s=!0);if(!t.any&&null===t.choice){var u=null!==t.implicit?t.implicit:t.tag,f=null===t.implicit?"universal":"context";null===u?null===t.use&&i.error("Tag could be omitted only for .use()"):null===t.use&&(r=this._encodeComposite(u,s,f,o))}return null!==t.explicit&&(r=this._encodeComposite(t.explicit,!1,"context",r)),r},a.prototype._encodeChoice=function(e,t){var r=this._baseState,n=r.choice[e.type];return n||i(!1,e.type+" not found in "+JSON.stringify(Object.keys(r.choice))),n._encode(e.value,t)},a.prototype._encodePrimitive=function(e,t){var r=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&r.args)return this._encodeObjid(t,r.reverseArgs[0],r.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,r.args&&r.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},a.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},a.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(e)}},{"../base":4,"minimalistic-assert":108}],6:[function(e,t,r){var n=e("inherits");function i(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function o(e,t){this.path=e,this.rethrow(t)}(r.Reporter=i).prototype.isError=function(e){return e instanceof o},i.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},i.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},i.prototype.enterKey=function(e){return this._reporterState.path.push(e)},i.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},i.prototype.leaveKey=function(e,t,r){var n=this._reporterState;this.exitKey(e),null!==n.obj&&(n.obj[t]=r)},i.prototype.path=function(){return this._reporterState.path.join("/")},i.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},i.prototype.leaveObject=function(e){var t=this._reporterState,r=t.obj;return t.obj=e,r},i.prototype.error=function(e){var t,r=this._reporterState,n=e instanceof o;if(t=n?e:new o(r.path.map(function(e){return"["+JSON.stringify(e)+"]"}).join(""),e.message||e,e.stack),!r.options.partial)throw t;return n||r.errors.push(t),t},i.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},n(o,Error),o.prototype.rethrow=function(e){if(this.message=e+" 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}},{inherits:103}],7:[function(e,t,r){var n=e("../constants");r.tagClass={0:"universal",1:"application",2:"context",3:"private"},r.tagClassByName=n._reverse(r.tagClass),r.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"},r.tagByName=n._reverse(r.tag)},{"../constants":8}],8:[function(e,t,r){var n=r;n._reverse=function(r){var n={};return Object.keys(r).forEach(function(e){(0|e)==e&&(e|=0);var t=r[e];n[t]=e}),n},n.der=e("./der")},{"./der":7}],9:[function(e,t,r){var n=e("inherits"),i=e("../../asn1"),o=i.base,s=i.bignum,a=i.constants.der;function u(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new f,this.tree._init(e.body)}function f(e){o.Node.call(this,"der",e)}function c(e,t){var r=e.readUInt8(t);if(e.isError(r))return r;var n=a.tagClass[r>>6],i=0==(32&r);if(31==(31&r)){var o=r;for(r=0;128==(128&o);){if(o=e.readUInt8(t),e.isError(o))return o;r<<=7,r|=127&o}}else r&=31;return{cls:n,primitive:i,tag:r,tagStr:a.tag[r]}}function h(e,t,r){var n=e.readUInt8(r);if(e.isError(n))return n;if(!t&&128===n)return null;if(0==(128&n))return n;var i=127&n;if(4<i)return e.error("length octect is too long");for(var o=n=0;o<i;o++){n<<=8;var s=e.readUInt8(r);if(e.isError(s))return s;n|=s}return n}(t.exports=u).prototype.decode=function(e,t){return e instanceof o.DecoderBuffer||(e=new o.DecoderBuffer(e,t)),this.tree._decode(e,t)},n(f,o.Node),f.prototype._peekTag=function(e,t,r){if(e.isEmpty())return!1;var n=e.save(),i=c(e,'Failed to peek tag: "'+t+'"');return e.isError(i)?i:(e.restore(n),i.tag===t||i.tagStr===t||i.tagStr+"of"===t||r)},f.prototype._decodeTag=function(e,t,r){var n=c(e,'Failed to decode tag of "'+t+'"');if(e.isError(n))return n;var i=h(e,n.primitive,'Failed to get length of "'+t+'"');if(e.isError(i))return i;if(!r&&n.tag!==t&&n.tagStr!==t&&n.tagStr+"of"!==t)return e.error('Failed to match tag: "'+t+'"');if(n.primitive||null!==i)return e.skip(i,'Failed to match body of: "'+t+'"');var o=e.save(),s=this._skipUntilEnd(e,'Failed to skip indefinite length body: "'+this.tag+'"');return e.isError(s)?s:(i=e.offset-o.offset,e.restore(o),e.skip(i,'Failed to match body of: "'+t+'"'))},f.prototype._skipUntilEnd=function(e,t){for(;;){var r=c(e,t);if(e.isError(r))return r;var n,i=h(e,r.primitive,t);if(e.isError(i))return i;if(n=r.primitive||null!==i?e.skip(i):this._skipUntilEnd(e,t),e.isError(n))return n;if("end"===r.tagStr)break}},f.prototype._decodeList=function(e,t,r,n){for(var i=[];!e.isEmpty();){var o=this._peekTag(e,"end");if(e.isError(o))return o;var s=r.decode(e,"der",n);if(e.isError(s)&&o)break;i.push(s)}return i},f.prototype._decodeStr=function(e,t){if("bitstr"===t){var r=e.readUInt8();return e.isError(r)?r:{unused:r,data:e.raw()}}if("bmpstr"===t){var n=e.raw();if(n.length%2==1)return e.error("Decoding of string type: bmpstr length mismatch");for(var i="",o=0;o<n.length/2;o++)i+=String.fromCharCode(n.readUInt16BE(2*o));return i}if("numstr"===t){var s=e.raw().toString("ascii");return this._isNumstr(s)?s:e.error("Decoding of string type: numstr unsupported characters")}if("octstr"===t)return e.raw();if("objDesc"===t)return e.raw();if("printstr"===t){var a=e.raw().toString("ascii");return this._isPrintstr(a)?a:e.error("Decoding of string type: printstr unsupported characters")}return/str$/.test(t)?e.raw().toString():e.error("Decoding of string type: "+t+" unsupported")},f.prototype._decodeObjid=function(e,t,r){for(var n,i=[],o=0;!e.isEmpty();){var s=e.readUInt8();o<<=7,o|=127&s,0==(128&s)&&(i.push(o),o=0)}128&s&&i.push(o);var a=i[0]/40|0,u=i[0]%40;if(n=r?i:[a,u].concat(i.slice(1)),t){var f=t[n.join(" ")];void 0===f&&(f=t[n.join(".")]),void 0!==f&&(n=f)}return n},f.prototype._decodeTime=function(e,t){var r=e.raw().toString();if("gentime"===t)var n=0|r.slice(0,4),i=0|r.slice(4,6),o=0|r.slice(6,8),s=0|r.slice(8,10),a=0|r.slice(10,12),u=0|r.slice(12,14);else{if("utctime"!==t)return e.error("Decoding "+t+" time is not supported yet");n=0|r.slice(0,2),i=0|r.slice(2,4),o=0|r.slice(4,6),s=0|r.slice(6,8),a=0|r.slice(8,10),u=0|r.slice(10,12);n=n<70?2e3+n:1900+n}return Date.UTC(n,i-1,o,s,a,u,0)},f.prototype._decodeNull=function(e){return null},f.prototype._decodeBool=function(e){var t=e.readUInt8();return e.isError(t)?t:0!==t},f.prototype._decodeInt=function(e,t){var r=e.raw(),n=new s(r);return t&&(n=t[n.toString(10)]||n),n},f.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getDecoder("der").tree}},{"../../asn1":1,inherits:103}],10:[function(e,t,r){var n=r;n.der=e("./der"),n.pem=e("./pem")},{"./der":9,"./pem":11}],11:[function(e,t,r){var n=e("inherits"),h=e("buffer").Buffer,d=e("./der");function i(e){d.call(this,e),this.enc="pem"}n(i,d),(t.exports=i).prototype.decode=function(e,t){for(var r=e.toString().split(/[\r\n]+/g),n=t.label.toUpperCase(),i=/^-----(BEGIN|END) ([^-]+)-----$/,o=-1,s=-1,a=0;a<r.length;a++){var u=r[a].match(i);if(null!==u&&u[2]===n){if(-1!==o){if("END"!==u[1])break;s=a;break}if("BEGIN"!==u[1])break;o=a}}if(-1===o||-1===s)throw new Error("PEM section not found for: "+n);var f=r.slice(o+1,s).join("");f.replace(/[^a-z0-9\+\/=]+/gi,"");var c=new h(f,"base64");return d.prototype.decode.call(this,c,t)}},{"./der":9,buffer:48,inherits:103}],12:[function(e,t,r){var n=e("inherits"),f=e("buffer").Buffer,i=e("../../asn1"),o=i.base,c=i.constants.der;function s(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new a,this.tree._init(e.body)}function a(e){o.Node.call(this,"der",e)}function u(e){return e<10?"0"+e:e}(t.exports=s).prototype.encode=function(e,t){return this.tree._encode(e,t).join()},n(a,o.Node),a.prototype._encodeComposite=function(e,t,r,n){var i,o=function(e,t,r,n){var i;"seqof"===e?e="seq":"setof"===e&&(e="set");if(c.tagByName.hasOwnProperty(e))i=c.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return n.error("Unknown tag: "+e);i=e}if(31<=i)return n.error("Multi-octet tag encoding unsupported");t||(i|=32);return i|=c.tagClassByName[r||"universal"]<<6}(e,t,r,this.reporter);if(n.length<128)return(i=new f(2))[0]=o,i[1]=n.length,this._createEncoderBuffer([i,n]);for(var s=1,a=n.length;256<=a;a>>=8)s++;(i=new f(2+s))[0]=o,i[1]=128|s;a=1+s;for(var u=n.length;0<u;a--,u>>=8)i[a]=255&u;return this._createEncoderBuffer([i,n])},a.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var r=new f(2*e.length),n=0;n<e.length;n++)r.writeUInt16BE(e.charCodeAt(n),2*n);return this._createEncoderBuffer(r)}return"numstr"===t?this._isNumstr(e)?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: numstr supports only digits and space"):"printstr"===t?this._isPrintstr(e)?this._createEncoderBuffer(e):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(t)?this._createEncoderBuffer(e):"objDesc"===t?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: "+t+" unsupported")},a.prototype._encodeObjid=function(e,t,r){if("string"==typeof e){if(!t)return this.reporter.error("string objid given, but no values map found");if(!t.hasOwnProperty(e))return this.reporter.error("objid not found in values map");e=t[e].split(/[\s\.]+/g);for(var n=0;n<e.length;n++)e[n]|=0}else if(Array.isArray(e)){e=e.slice();for(n=0;n<e.length;n++)e[n]|=0}if(!Array.isArray(e))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(e));if(!r){if(40<=e[1])return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}var i=0;for(n=0;n<e.length;n++){var o=e[n];for(i++;128<=o;o>>=7)i++}var s=new f(i),a=s.length-1;for(n=e.length-1;0<=n;n--){o=e[n];for(s[a--]=127&o;0<(o>>=7);)s[a--]=128|127&o}return this._createEncoderBuffer(s)},a.prototype._encodeTime=function(e,t){var r,n=new Date(e);return"gentime"===t?r=[u(n.getFullYear()),u(n.getUTCMonth()+1),u(n.getUTCDate()),u(n.getUTCHours()),u(n.getUTCMinutes()),u(n.getUTCSeconds()),"Z"].join(""):"utctime"===t?r=[u(n.getFullYear()%100),u(n.getUTCMonth()+1),u(n.getUTCDate()),u(n.getUTCHours()),u(n.getUTCMinutes()),u(n.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(r,"octstr")},a.prototype._encodeNull=function(){return this._createEncoderBuffer("")},a.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!f.isBuffer(e)){var r=e.toArray();!e.sign&&128&r[0]&&r.unshift(0),e=new f(r)}if(f.isBuffer(e)){var n=e.length;0===e.length&&n++;var i=new f(n);return e.copy(i),0===e.length&&(i[0]=0),this._createEncoderBuffer(i)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);n=1;for(var o=e;256<=o;o>>=8)n++;for(o=(i=new Array(n)).length-1;0<=o;o--)i[o]=255&e,e>>=8;return 128&i[0]&&i.unshift(0),this._createEncoderBuffer(new f(i))},a.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},a.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},a.prototype._skipDefault=function(e,t,r){var n,i=this._baseState;if(null===i.default)return!1;var o=e.join();if(void 0===i.defaultBuffer&&(i.defaultBuffer=this._encodeValue(i.default,t,r).join()),o.length!==i.defaultBuffer.length)return!1;for(n=0;n<o.length;n++)if(o[n]!==i.defaultBuffer[n])return!1;return!0}},{"../../asn1":1,buffer:48,inherits:103}],13:[function(e,t,r){var n=r;n.der=e("./der"),n.pem=e("./pem")},{"./der":12,"./pem":14}],14:[function(e,t,r){var n=e("inherits"),o=e("./der");function i(e){o.call(this,e),this.enc="pem"}n(i,o),(t.exports=i).prototype.encode=function(e,t){for(var r=o.prototype.encode.call(this,e).toString("base64"),n=["-----BEGIN "+t.label+"-----"],i=0;i<r.length;i+=64)n.push(r.slice(i,i+64));return n.push("-----END "+t.label+"-----"),n.join("\n")}},{"./der":12,inherits:103}],15:[function(e,t,r){r.byteLength=function(e){var t=l(e),r=t[0],n=t[1];return 3*(r+n)/4-n},r.toByteArray=function(e){for(var t,r=l(e),n=r[0],i=r[1],o=new d((f=n,c=i,3*(f+c)/4-c)),s=0,a=0<i?n-4:n,u=0;u<a;u+=4)t=h[e.charCodeAt(u)]<<18|h[e.charCodeAt(u+1)]<<12|h[e.charCodeAt(u+2)]<<6|h[e.charCodeAt(u+3)],o[s++]=t>>16&255,o[s++]=t>>8&255,o[s++]=255&t;var f,c;2===i&&(t=h[e.charCodeAt(u)]<<2|h[e.charCodeAt(u+1)]>>4,o[s++]=255&t);1===i&&(t=h[e.charCodeAt(u)]<<10|h[e.charCodeAt(u+1)]<<4|h[e.charCodeAt(u+2)]>>2,o[s++]=t>>8&255,o[s++]=255&t);return o},r.fromByteArray=function(e){for(var t,r=e.length,n=r%3,i=[],o=0,s=r-n;o<s;o+=16383)i.push(u(e,o,s<o+16383?s:o+16383));1===n?(t=e[r-1],i.push(a[t>>2]+a[t<<4&63]+"==")):2===n&&(t=(e[r-2]<<8)+e[r-1],i.push(a[t>>10]+a[t>>4&63]+a[t<<2&63]+"="));return i.join("")};for(var a=[],h=[],d="undefined"!=typeof Uint8Array?Uint8Array:Array,n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",i=0,o=n.length;i<o;++i)a[i]=n[i],h[n.charCodeAt(i)]=i;function l(e){var t=e.length;if(0<t%4)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");return-1===r&&(r=t),[r,r===t?0:4-r%4]}function u(e,t,r){for(var n,i,o=[],s=t;s<r;s+=3)n=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),o.push(a[(i=n)>>18&63]+a[i>>12&63]+a[i>>6&63]+a[63&i]);return o.join("")}h["-".charCodeAt(0)]=62,h["_".charCodeAt(0)]=63},{}],16:[function(e,t,r){var n;function i(e){this.rand=e}if(t.exports=function(e){return n||(n=new i(null)),n.generate(e)},(t.exports.Rand=i).prototype.generate=function(e){return this._rand(e)},i.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),r=0;r<t.length;r++)t[r]=this.rand.getByte();return t},"object"===("undefined"==typeof self?"undefined":_typeof(self)))self.crypto&&self.crypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.crypto.getRandomValues(t),t}:self.msCrypto&&self.msCrypto.getRandomValues?i.prototype._rand=function(e){var t=new Uint8Array(e);return self.msCrypto.getRandomValues(t),t}:"object"===("undefined"==typeof window?"undefined":_typeof(window))&&(i.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var o=e("crypto");if("function"!=typeof o.randomBytes)throw new Error("Not supported");i.prototype._rand=function(e){return o.randomBytes(e)}}catch(e){}},{crypto:17}],17:[function(e,t,r){},{}],18:[function(e,t,r){var i=e("safe-buffer").Buffer;function o(e){i.isBuffer(e)||(e=i.from(e));for(var t=e.length/4|0,r=new Array(t),n=0;n<t;n++)r[n]=e.readUInt32BE(4*n);return r}function n(e){for(;0<e.length;e++)e[0]=0}function s(e,t,r,n,i){for(var o,s,a,u,f=r[0],c=r[1],h=r[2],d=r[3],l=e[0]^t[0],p=e[1]^t[1],b=e[2]^t[2],m=e[3]^t[3],y=4,v=1;v<i;v++)o=f[l>>>24]^c[p>>>16&255]^h[b>>>8&255]^d[255&m]^t[y++],s=f[p>>>24]^c[b>>>16&255]^h[m>>>8&255]^d[255&l]^t[y++],a=f[b>>>24]^c[m>>>16&255]^h[l>>>8&255]^d[255&p]^t[y++],u=f[m>>>24]^c[l>>>16&255]^h[p>>>8&255]^d[255&b]^t[y++],l=o,p=s,b=a,m=u;return o=(n[l>>>24]<<24|n[p>>>16&255]<<16|n[b>>>8&255]<<8|n[255&m])^t[y++],s=(n[p>>>24]<<24|n[b>>>16&255]<<16|n[m>>>8&255]<<8|n[255&l])^t[y++],a=(n[b>>>24]<<24|n[m>>>16&255]<<16|n[l>>>8&255]<<8|n[255&p])^t[y++],u=(n[m>>>24]<<24|n[l>>>16&255]<<16|n[p>>>8&255]<<8|n[255&b])^t[y++],[o>>>=0,s>>>=0,a>>>=0,u>>>=0]}var h=[0,1,2,4,8,16,32,64,128,27,54],d=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var r=[],n=[],i=[[],[],[],[]],o=[[],[],[],[]],s=0,a=0,u=0;u<256;++u){var f=a^a<<1^a<<2^a<<3^a<<4;f=f>>>8^255&f^99;var c=e[n[r[s]=f]=s],h=e[c],d=e[h],l=257*e[f]^16843008*f;i[0][s]=l<<24|l>>>8,i[1][s]=l<<16|l>>>16,i[2][s]=l<<8|l>>>24,i[3][s]=l,l=16843009*d^65537*h^257*c^16843008*s,o[0][f]=l<<24|l>>>8,o[1][f]=l<<16|l>>>16,o[2][f]=l<<8|l>>>24,o[3][f]=l,0===s?s=a=1:(s=c^e[e[e[d^c]]],a^=e[e[a]])}return{SBOX:r,INV_SBOX:n,SUB_MIX:i,INV_SUB_MIX:o}}();function a(e){this._key=o(e),this._reset()}a.blockSize=16,a.keySize=32,a.prototype.blockSize=a.blockSize,a.prototype.keySize=a.keySize,a.prototype._reset=function(){for(var e=this._key,t=e.length,r=t+6,n=4*(r+1),i=[],o=0;o<t;o++)i[o]=e[o];for(o=t;o<n;o++){var s=i[o-1];o%t==0?(s=s<<8|s>>>24,s=d.SBOX[s>>>24]<<24|d.SBOX[s>>>16&255]<<16|d.SBOX[s>>>8&255]<<8|d.SBOX[255&s],s^=h[o/t|0]<<24):6<t&&o%t==4&&(s=d.SBOX[s>>>24]<<24|d.SBOX[s>>>16&255]<<16|d.SBOX[s>>>8&255]<<8|d.SBOX[255&s]),i[o]=i[o-t]^s}for(var a=[],u=0;u<n;u++){var f=n-u,c=i[f-(u%4?0:4)];a[u]=u<4||f<=4?c:d.INV_SUB_MIX[0][d.SBOX[c>>>24]]^d.INV_SUB_MIX[1][d.SBOX[c>>>16&255]]^d.INV_SUB_MIX[2][d.SBOX[c>>>8&255]]^d.INV_SUB_MIX[3][d.SBOX[255&c]]}this._nRounds=r,this._keySchedule=i,this._invKeySchedule=a},a.prototype.encryptBlockRaw=function(e){return s(e=o(e),this._keySchedule,d.SUB_MIX,d.SBOX,this._nRounds)},a.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),r=i.allocUnsafe(16);return r.writeUInt32BE(t[0],0),r.writeUInt32BE(t[1],4),r.writeUInt32BE(t[2],8),r.writeUInt32BE(t[3],12),r},a.prototype.decryptBlock=function(e){var t=(e=o(e))[1];e[1]=e[3],e[3]=t;var r=s(e,this._invKeySchedule,d.INV_SUB_MIX,d.INV_SBOX,this._nRounds),n=i.allocUnsafe(16);return n.writeUInt32BE(r[0],0),n.writeUInt32BE(r[3],4),n.writeUInt32BE(r[2],8),n.writeUInt32BE(r[1],12),n},a.prototype.scrub=function(){n(this._keySchedule),n(this._invKeySchedule),n(this._key)},t.exports.AES=a},{"safe-buffer":149}],19:[function(e,t,r){var s=e("./aes"),f=e("safe-buffer").Buffer,a=e("cipher-base"),n=e("inherits"),c=e("./ghash"),i=e("buffer-xor"),h=e("./incr32");function o(e,t,r,n){a.call(this);var i=f.alloc(4,0);this._cipher=new s.AES(t);var o=this._cipher.encryptBlock(i);this._ghash=new c(o),r=function(e,t,r){if(12===t.length)return e._finID=f.concat([t,f.from([0,0,0,1])]),f.concat([t,f.from([0,0,0,2])]);var n=new c(r),i=t.length,o=i%16;n.update(t),o&&(o=16-o,n.update(f.alloc(o,0))),n.update(f.alloc(8,0));var s=8*i,a=f.alloc(8);a.writeUIntBE(s,0,8),n.update(a),e._finID=n.state;var u=f.from(e._finID);return h(u),u}(this,r,o),this._prev=f.from(r),this._cache=f.allocUnsafe(0),this._secCache=f.allocUnsafe(0),this._decrypt=n,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}n(o,a),o.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=f.alloc(t,0),this._ghash.update(t))}this._called=!0;var r=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(r),this._len+=e.length,r},o.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=i(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var r=0;e.length!==t.length&&r++;for(var n=Math.min(e.length,t.length),i=0;i<n;++i)r+=e[i]^t[i];return r}(e,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=e,this._cipher.scrub()},o.prototype.getAuthTag=function(){if(this._decrypt||!f.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},o.prototype.setAuthTag=function(e){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=e},o.prototype.setAAD=function(e){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(e),this._alen+=e.length},t.exports=o},{"./aes":18,"./ghash":23,"./incr32":24,"buffer-xor":47,"cipher-base":50,inherits:103,"safe-buffer":149}],20:[function(e,t,r){var n=e("./encrypter"),i=e("./decrypter"),o=e("./modes/list.json");r.createCipher=r.Cipher=n.createCipher,r.createCipheriv=r.Cipheriv=n.createCipheriv,r.createDecipher=r.Decipher=i.createDecipher,r.createDecipheriv=r.Decipheriv=i.createDecipheriv,r.listCiphers=r.getCiphers=function(){return Object.keys(o)}},{"./decrypter":21,"./encrypter":22,"./modes/list.json":32}],21:[function(e,t,r){var i=e("./authCipher"),o=e("safe-buffer").Buffer,s=e("./modes"),a=e("./streamCipher"),n=e("cipher-base"),u=e("./aes"),f=e("evp_bytestokey");function c(e,t,r){n.call(this),this._cache=new h,this._last=void 0,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var n=s[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=o.from(r)),"GCM"!==n.mode&&r.length!==n.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=o.from(t)),t.length!==n.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===n.type?new a(n.module,t,r,!0):"auth"===n.type?new i(n.module,t,r,!0):new c(n.module,t,r)}e("inherits")(c,n),c.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return o.concat(n)},c.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||16<t)throw new Error("unable to decrypt data");var r=-1;for(;++r<t;)if(e[r+(16-t)]!==t)throw new Error("unable to decrypt data");if(16===t)return;return e.slice(0,16-t)}(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},c.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(e){var t;if(e){if(16<this.cache.length)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(16<=this.cache.length)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},h.prototype.flush=function(){if(this.cache.length)return this.cache},r.createDecipher=function(e,t){var r=s[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=f(t,!1,r.key,r.iv);return d(e,n.key,n.iv)},r.createDecipheriv=d},{"./aes":18,"./authCipher":19,"./modes":31,"./streamCipher":34,"cipher-base":50,evp_bytestokey:85,inherits:103,"safe-buffer":149}],22:[function(e,t,r){var i=e("./modes"),o=e("./authCipher"),s=e("safe-buffer").Buffer,a=e("./streamCipher"),n=e("cipher-base"),u=e("./aes"),f=e("evp_bytestokey");function c(e,t,r){n.call(this),this._cache=new d,this._cipher=new u.AES(t),this._prev=s.from(r),this._mode=e,this._autopadding=!0}e("inherits")(c,n),c.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get();)r=this._mode.encrypt(this,t),n.push(r);return s.concat(n)};var h=s.alloc(16,16);function d(){this.cache=s.allocUnsafe(0)}function l(e,t,r){var n=i[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=s.from(t)),t.length!==n.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof r&&(r=s.from(r)),"GCM"!==n.mode&&r.length!==n.iv)throw new TypeError("invalid iv length "+r.length);return"stream"===n.type?new a(n.module,t,r):"auth"===n.type?new o(n.module,t,r):new c(n.module,t,r)}c.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(h))throw this._cipher.scrub(),new Error("data not multiple of block length")},c.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},d.prototype.add=function(e){this.cache=s.concat([this.cache,e])},d.prototype.get=function(){if(15<this.cache.length){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},d.prototype.flush=function(){for(var e=16-this.cache.length,t=s.allocUnsafe(e),r=-1;++r<e;)t.writeUInt8(e,r);return s.concat([this.cache,t])},r.createCipheriv=l,r.createCipher=function(e,t){var r=i[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=f(t,!1,r.key,r.iv);return l(e,n.key,n.iv)}},{"./aes":18,"./authCipher":19,"./modes":31,"./streamCipher":34,"cipher-base":50,evp_bytestokey:85,inherits:103,"safe-buffer":149}],23:[function(e,t,r){var n=e("safe-buffer").Buffer,i=n.alloc(16,0);function s(e){var t=n.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 o(e){this.h=e,this.state=n.alloc(16,0),this.cache=n.allocUnsafe(0)}o.prototype.ghash=function(e){for(var t=-1;++t<e.length;)this.state[t]^=e[t];this._multiply()},o.prototype._multiply=function(){for(var e,t,r,n=[(e=this.h).readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)],i=[0,0,0,0],o=-1;++o<128;){for(0!=(this.state[~~(o/8)]&1<<7-o%8)&&(i[0]^=n[0],i[1]^=n[1],i[2]^=n[2],i[3]^=n[3]),r=0!=(1&n[3]),t=3;0<t;t--)n[t]=n[t]>>>1|(1&n[t-1])<<31;n[0]=n[0]>>>1,r&&(n[0]=n[0]^225<<24)}this.state=s(i)},o.prototype.update=function(e){var t;for(this.cache=n.concat([this.cache,e]);16<=this.cache.length;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},o.prototype.final=function(e,t){return this.cache.length&&this.ghash(n.concat([this.cache,i],16)),this.ghash(s([0,e,0,t])),this.state},t.exports=o},{"safe-buffer":149}],24:[function(e,t,r){t.exports=function(e){for(var t,r=e.length;r--;){if(255!==(t=e.readUInt8(r))){t++,e.writeUInt8(t,r);break}e.writeUInt8(0,r)}}},{}],25:[function(e,t,r){var i=e("buffer-xor");r.encrypt=function(e,t){var r=i(t,e._prev);return e._prev=e._cipher.encryptBlock(r),e._prev},r.decrypt=function(e,t){var r=e._prev;e._prev=t;var n=e._cipher.decryptBlock(t);return i(n,r)}},{"buffer-xor":47}],26:[function(e,t,r){var o=e("safe-buffer").Buffer,s=e("buffer-xor");function a(e,t,r){var n=t.length,i=s(t,e._cache);return e._cache=e._cache.slice(n),e._prev=o.concat([e._prev,r?t:i]),i}r.encrypt=function(e,t,r){for(var n,i=o.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=o.allocUnsafe(0)),!(e._cache.length<=t.length)){i=o.concat([i,a(e,t,r)]);break}n=e._cache.length,i=o.concat([i,a(e,t.slice(0,n),r)]),t=t.slice(n)}return i}},{"buffer-xor":47,"safe-buffer":149}],27:[function(e,t,r){var s=e("safe-buffer").Buffer;function a(e,t,r){for(var n,i,o=-1,s=0;++o<8;)n=t&1<<7-o?128:0,s+=(128&(i=e._cipher.encryptBlock(e._prev)[0]^n))>>o%8,e._prev=u(e._prev,r?n:i);return s}function u(e,t){var r=e.length,n=-1,i=s.allocUnsafe(e.length);for(e=s.concat([e,s.from([t])]);++n<r;)i[n]=e[n]<<1|e[n+1]>>7;return i}r.encrypt=function(e,t,r){for(var n=t.length,i=s.allocUnsafe(n),o=-1;++o<n;)i[o]=a(e,t[o],r);return i}},{"safe-buffer":149}],28:[function(e,t,r){var c=e("safe-buffer").Buffer;r.encrypt=function(e,t,r){for(var n,i,o,s,a=t.length,u=c.allocUnsafe(a),f=-1;++f<a;)u[f]=(n=e,i=t[f],o=r,void 0,s=n._cipher.encryptBlock(n._prev)[0]^i,n._prev=c.concat([n._prev.slice(1),c.from([o?i:s])]),s);return u}},{"safe-buffer":149}],29:[function(e,t,r){var c=e("buffer-xor"),h=e("safe-buffer").Buffer,d=e("../incr32");r.encrypt=function(e,t){var r,n,i=Math.ceil(t.length/16),o=e._cache.length;e._cache=h.concat([e._cache,h.allocUnsafe(16*i)]);for(var s=0;s<i;s++){var a=(void 0,n=(r=e)._cipher.encryptBlockRaw(r._prev),d(r._prev),n),u=o+16*s;e._cache.writeUInt32BE(a[0],u+0),e._cache.writeUInt32BE(a[1],u+4),e._cache.writeUInt32BE(a[2],u+8),e._cache.writeUInt32BE(a[3],u+12)}var f=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),c(t,f)}},{"../incr32":24,"buffer-xor":47,"safe-buffer":149}],30:[function(e,t,r){r.encrypt=function(e,t){return e._cipher.encryptBlock(t)},r.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},{}],31:[function(e,t,r){var n={ECB:e("./ecb"),CBC:e("./cbc"),CFB:e("./cfb"),CFB8:e("./cfb8"),CFB1:e("./cfb1"),OFB:e("./ofb"),CTR:e("./ctr"),GCM:e("./ctr")},i=e("./list.json");for(var o in i)i[o].module=n[i[o].mode];t.exports=i},{"./cbc":25,"./cfb":26,"./cfb1":27,"./cfb8":28,"./ctr":29,"./ecb":30,"./list.json":32,"./ofb":33}],32:[function(e,t,r){t.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"}}},{}],33:[function(e,t,r){(function(i){var o=e("buffer-xor");r.encrypt=function(e,t){for(;e._cache.length<t.length;)e._cache=i.concat([e._cache,(r=e,r._prev=r._cipher.encryptBlock(r._prev),r._prev)]);var r,n=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),o(t,n)}}).call(this,e("buffer").Buffer)},{buffer:48,"buffer-xor":47}],34:[function(e,t,r){var i=e("./aes"),o=e("safe-buffer").Buffer,s=e("cipher-base");function n(e,t,r,n){s.call(this),this._cipher=new i.AES(t),this._prev=o.from(r),this._cache=o.allocUnsafe(0),this._secCache=o.allocUnsafe(0),this._decrypt=n,this._mode=e}e("inherits")(n,s),n.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},n.prototype._final=function(){this._cipher.scrub()},t.exports=n},{"./aes":18,"cipher-base":50,inherits:103,"safe-buffer":149}],35:[function(e,t,r){var n=e("browserify-des"),i=e("browserify-aes/browser"),o=e("browserify-aes/modes"),s=e("browserify-des/modes"),a=e("evp_bytestokey");function u(e,t,r){if(e=e.toLowerCase(),o[e])return i.createCipheriv(e,t,r);if(s[e])return new n({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function f(e,t,r){if(e=e.toLowerCase(),o[e])return i.createDecipheriv(e,t,r);if(s[e])return new n({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}r.createCipher=r.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,n=s[e].iv}var i=a(t,!1,r,n);return u(e,i.key,i.iv)},r.createCipheriv=r.Cipheriv=u,r.createDecipher=r.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),o[e])r=o[e].key,n=o[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,n=s[e].iv}var i=a(t,!1,r,n);return f(e,i.key,i.iv)},r.createDecipheriv=r.Decipheriv=f,r.listCiphers=r.getCiphers=function(){return Object.keys(s).concat(i.getCiphers())}},{"browserify-aes/browser":20,"browserify-aes/modes":31,"browserify-des":36,"browserify-des/modes":37,evp_bytestokey:85}],36:[function(e,t,r){var s=e("cipher-base"),n=e("des.js"),i=e("inherits"),a=e("safe-buffer").Buffer,u={"des-ede3-cbc":n.CBC.instantiate(n.EDE),"des-ede3":n.EDE,"des-ede-cbc":n.CBC.instantiate(n.EDE),"des-ede":n.EDE,"des-cbc":n.CBC.instantiate(n.DES),"des-ecb":n.DES};function o(e){s.call(this);var t,r=e.mode.toLowerCase(),n=u[r];t=e.decrypt?"decrypt":"encrypt";var i=e.key;a.isBuffer(i)||(i=a.from(i)),"des-ede"!==r&&"des-ede-cbc"!==r||(i=a.concat([i,i.slice(0,8)]));var o=e.iv;a.isBuffer(o)||(o=a.from(o)),this._des=n.create({key:i,iv:o,type:t})}u.des=u["des-cbc"],u.des3=u["des-ede3-cbc"],i(t.exports=o,s),o.prototype._update=function(e){return a.from(this._des.update(e))},o.prototype._final=function(){return a.from(this._des.final())}},{"cipher-base":50,"des.js":58,inherits:103,"safe-buffer":149}],37:[function(e,t,r){r["des-ecb"]={key:8,iv:0},r["des-cbc"]=r.des={key:8,iv:8},r["des-ede3-cbc"]=r.des3={key:24,iv:8},r["des-ede3"]={key:24,iv:0},r["des-ede-cbc"]={key:16,iv:8},r["des-ede"]={key:16,iv:0}},{}],38:[function(t,r,e){(function(b){var m=t("bn.js"),n=t("randombytes");function e(e,t){var r,n,i={blinder:(n=y(r=t)).toRed(m.mont(r.modulus)).redPow(new m(r.publicExponent)).fromRed(),unblinder:n.invm(r.modulus)},o=t.modulus.byteLength(),s=(m.mont(t.modulus),new m(e).mul(i.blinder).umod(t.modulus)),a=s.toRed(m.mont(t.prime1)),u=s.toRed(m.mont(t.prime2)),f=t.coefficient,c=t.prime1,h=t.prime2,d=a.redPow(t.exponent1),l=u.redPow(t.exponent2);d=d.fromRed(),l=l.fromRed();var p=d.isub(l).imul(f).umod(c);return p.imul(h),l.iadd(p),new b(l.imul(i.unblinder).umod(t.modulus).toArray(!1,o))}function y(e){for(var t=e.modulus.byteLength(),r=new m(n(t));0<=r.cmp(e.modulus)||!r.umod(e.prime1)||!r.umod(e.prime2);)r=new m(n(t));return r}(r.exports=e).getr=y}).call(this,t("buffer").Buffer)},{"bn.js":"BN",buffer:48,randombytes:133}],39:[function(e,t,r){t.exports=e("./browser/algorithms.json")},{"./browser/algorithms.json":40}],40:[function(e,t,r){t.exports={sha224WithRSAEncryption:{sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption:{sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption:{sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption:{sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:{sign:"ecdsa",hash:"sha256",id:""},sha224:{sign:"ecdsa",hash:"sha224",id:""},sha384:{sign:"ecdsa",hash:"sha384",id:""},sha512:{sign:"ecdsa",hash:"sha512",id:""},"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA:{sign:"dsa",hash:"sha1",id:""},"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA:{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption:{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}}},{}],41:[function(e,t,r){t.exports={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}},{}],42:[function(h,d,e){(function(i){var r=h("create-hash"),n=h("stream"),e=h("inherits"),o=h("./sign"),s=h("./verify"),a=h("./algorithms.json");function t(e){n.Writable.call(this);var t=a[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=r(t.hash),this._tag=t.id,this._signType=t.sign}function u(e){n.Writable.call(this);var t=a[e];if(!t)throw new Error("Unknown message digest");this._hash=r(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){return new t(e)}function c(e){return new u(e)}Object.keys(a).forEach(function(e){a[e].id=new i(a[e].id,"hex"),a[e.toLowerCase()]=a[e]}),e(t,n.Writable),t.prototype._write=function(e,t,r){this._hash.update(e),r()},t.prototype.update=function(e,t){return"string"==typeof e&&(e=new i(e,t)),this._hash.update(e),this},t.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=o(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},e(u,n.Writable),u.prototype._write=function(e,t,r){this._hash.update(e),r()},u.prototype.update=function(e,t){return"string"==typeof e&&(e=new i(e,t)),this._hash.update(e),this},u.prototype.verify=function(e,t,r){"string"==typeof t&&(t=new i(t,r)),this.end();var n=this._hash.digest();return s(t,n,e,this._signType,this._tag)},d.exports={Sign:f,Verify:c,createSign:f,createVerify:c}}).call(this,h("buffer").Buffer)},{"./algorithms.json":40,"./sign":43,"./verify":44,buffer:48,"create-hash":53,inherits:103,stream:158}],43:[function(e,t,r){(function(b){var f=e("create-hmac"),c=e("browserify-rsa"),h=e("elliptic").ec,m=e("bn.js"),d=e("parse-asn1"),l=e("./curves.json");function y(e,t,r,n){if((e=new b(e.toArray())).length<t.byteLength()){var i=new b(t.byteLength()-e.length);i.fill(0),e=b.concat([i,e])}var o=r.length,s=function(e,t){e=(e=v(e,t)).mod(t);var r=new b(e.toArray());if(r.length<t.byteLength()){var n=new b(t.byteLength()-r.length);n.fill(0),r=b.concat([n,r])}return r}(r,t),a=new b(o);a.fill(1);var u=new b(o);return u.fill(0),u=f(n,u).update(a).update(new b([0])).update(e).update(s).digest(),a=f(n,u).update(a).digest(),{k:u=f(n,u).update(a).update(new b([1])).update(e).update(s).digest(),v:a=f(n,u).update(a).digest()}}function v(e,t){var r=new m(e),n=(e.length<<3)-t.bitLength();return 0<n&&r.ishrn(n),r}function g(e,t,r){var n,i;do{for(n=new b(0);8*n.length<e.bitLength();)t.v=f(r,t.k).update(t.v).digest(),n=b.concat([n,t.v]);i=v(n,e),t.k=f(r,t.k).update(t.v).update(new b([0])).digest(),t.v=f(r,t.k).update(t.v).digest()}while(-1!==i.cmp(e));return i}t.exports=function(e,t,r,n,i){var o=d(t);if(o.curve){if("ecdsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");return function(e,t){var r=l[t.curve.join(".")];if(!r)throw new Error("unknown curve "+t.curve.join("."));var n=new h(r).keyFromPrivate(t.privateKey).sign(e);return new b(n.toDER())}(e,o)}if("dsa"===o.type){if("dsa"!==n)throw new Error("wrong private key type");return function(e,t,r){for(var n,i,o,s,a=t.params.priv_key,u=t.params.p,f=t.params.q,c=t.params.g,h=new m(0),d=v(e,f).mod(f),l=!1,p=y(a,f,e,r);!1===l;)n=g(f,p,r),i=n,o=u,s=f,h=c.toRed(m.mont(o)).redPow(i).fromRed().mod(s),0===(l=n.invm(f).imul(d.add(a.mul(h))).mod(f)).cmpn(0)&&(l=!1,h=new m(0));return function(e,t){e=e.toArray(),t=t.toArray(),128&e[0]&&(e=[0].concat(e)),128&t[0]&&(t=[0].concat(t));var r=[48,e.length+t.length+4,2,e.length];return r=r.concat(e,[2,t.length],t),new b(r)}(h,l)}(e,o,r)}if("rsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");e=b.concat([i,e]);for(var s=o.modulus.byteLength(),a=[0,1];e.length+a.length+1<s;)a.push(255);a.push(0);for(var u=-1;++u<e.length;)a.push(e[u]);return c(a,o)},t.exports.getKey=y,t.exports.makeKey=g}).call(this,e("buffer").Buffer)},{"./curves.json":41,"bn.js":"BN","browserify-rsa":38,buffer:48,"create-hmac":55,elliptic:68,"parse-asn1":115}],44:[function(e,t,r){(function(d){var l=e("bn.js"),p=e("elliptic").ec,b=e("parse-asn1"),m=e("./curves.json");function y(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}t.exports=function(e,t,r,n,i){var o=b(r);if("ec"===o.type){if("ecdsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong public key type");return function(e,t,r){var n=m[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new p(n),o=r.data.subjectPrivateKey.data;return i.verify(t,e,o)}(e,t,o)}if("dsa"===o.type){if("dsa"!==n)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,i=r.data.q,o=r.data.g,s=r.data.pub_key,a=b.signature.decode(e,"der"),u=a.s,f=a.r;y(u,i),y(f,i);var c=l.mont(n),h=u.invm(i);return 0===o.toRed(c).redPow(new l(t).mul(h).mod(i)).fromRed().mul(s.toRed(c).redPow(f.mul(h).mod(i)).fromRed()).mod(n).mod(i).cmp(f)}(e,t,o)}if("rsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong public key type");t=d.concat([i,t]);for(var s=o.modulus.byteLength(),a=[1],u=0;t.length+a.length+2<s;)a.push(255),u++;a.push(0);for(var f=-1;++f<t.length;)a.push(t[f]);a=new d(a);var c=l.mont(o.modulus);e=(e=new l(e).toRed(c)).redPow(new l(o.publicExponent)),e=new d(e.fromRed().toArray());var h=u<8?1:0;for(s=Math.min(e.length,a.length),e.length!==a.length&&(h=1),f=-1;++f<s;)h|=e[f]^a[f];return 0===h}}).call(this,e("buffer").Buffer)},{"./curves.json":41,"bn.js":"BN",buffer:48,elliptic:68,"parse-asn1":115}],45:[function(e,t,r){arguments[4][17][0].apply(r,arguments)},{dup:17}],46:[function(e,t,r){var n=e("safe-buffer").Buffer,i=n.isEncoding||function(e){switch((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){var t;switch(this.encoding=function(e){var t=function(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}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=f,t=4;break;case"utf8":this.fillLast=a,t=4;break;case"base64":this.text=c,this.end=h,t=3;break;default:return this.write=d,void(this.end=l)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:-1}function a(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�".repeat(r);if(1<e.lastNeed&&1<t.length){if(128!=(192&t[1]))return e.lastNeed=1,"�".repeat(r+1);if(2<e.lastNeed&&2<t.length&&128!=(192&t[2]))return e.lastNeed=2,"�".repeat(r+2)}}(this,e,t);return void 0!==r?r: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 u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(55296<=n&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function f(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function c(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?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-r))}function h(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function d(e){return e.toString(this.encoding)}function l(e){return e&&e.length?this.write(e):""}(r.StringDecoder=o).prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},o.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�".repeat(this.lastTotal-this.lastNeed):t},o.prototype.text=function(e,t){var r=function(e,t,r){var n=t.length-1;if(n<r)return 0;var i=s(t[n]);if(0<=i)return 0<i&&(e.lastNeed=i-1),i;if(--n<r)return 0;if(0<=(i=s(t[n])))return 0<i&&(e.lastNeed=i-2),i;if(--n<r)return 0;if(0<=(i=s(t[n])))return 0<i&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.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}},{"safe-buffer":149}],47:[function(e,t,r){(function(o){t.exports=function(e,t){for(var r=Math.min(e.length,t.length),n=new o(r),i=0;i<r;++i)n[i]=e[i]^t[i];return n}}).call(this,e("buffer").Buffer)},{buffer:48}],48:[function(e,t,r){var n=e("base64-js"),o=e("ieee754");r.Buffer=h,r.SlowBuffer=function(e){+e!=e&&(e=0);return h.alloc(+e)},r.INSPECT_MAX_BYTES=50;var i=2147483647;function s(e){if(i<e)throw new RangeError("Invalid typed array length");var t=new Uint8Array(e);return t.__proto__=h.prototype,t}function h(e,t,r){if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(e)}return a(e,t,r)}function a(e,t,r){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return N(e)||e&&N(e.buffer)?function(e,t,r){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(r||0))throw new RangeError('"length" is outside of buffer bounds');var n;n=void 0===t&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,t):new Uint8Array(e,t,r);return n.__proto__=h.prototype,n}(e,t,r):"string"==typeof e?function(e,t){"string"==typeof t&&""!==t||(t="utf8");if(!h.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var r=0|l(e,t),n=s(r),i=n.write(e,t);i!==r&&(n=n.slice(0,i));return n}(e,t):function(e){if(h.isBuffer(e)){var t=0|d(e.length),r=s(t);return 0===r.length||e.copy(r,0,0,t),r}if(e){if(ArrayBuffer.isView(e)||"length"in e)return"number"!=typeof e.length||L(e.length)?s(0):c(e);if("Buffer"===e.type&&Array.isArray(e.data))return c(e.data)}throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object.")}(e)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e){return u(e),s(e<0?0:0|d(e))}function c(e){for(var t=e.length<0?0:0|d(e.length),r=s(t),n=0;n<t;n+=1)r[n]=255&e[n];return r}function d(e){if(i<=e)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return 0|e}function l(e,t){if(h.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||N(e))return e.byteLength;"string"!=typeof e&&(e=""+e);var r=e.length;if(0===r)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return P(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return R(e).length;default:if(n)return P(e).length;t=(""+t).toLowerCase(),n=!0}}function p(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function b(e,t,r,n,i){if(0===e.length)return-1;if("string"==typeof r?(n=r,r=0):2147483647<r?r=2147483647:r<-2147483648&&(r=-2147483648),L(r=+r)&&(r=i?0:e.length-1),r<0&&(r=e.length+r),r>=e.length){if(i)return-1;r=e.length-1}else if(r<0){if(!i)return-1;r=0}if("string"==typeof t&&(t=h.from(t,n)),h.isBuffer(t))return 0===t.length?-1:m(e,t,r,n,i);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):m(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function m(e,t,r,n,i){var o,s=1,a=e.length,u=t.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(e.length<2||t.length<2)return-1;a/=s=2,u/=2,r/=2}function f(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(i){var c=-1;for(o=r;o<a;o++)if(f(e,o)===f(t,-1===c?0:o-c)){if(-1===c&&(c=o),o-c+1===u)return c*s}else-1!==c&&(o-=o-c),c=-1}else for(a<r+u&&(r=a-u),o=r;0<=o;o--){for(var h=!0,d=0;d<u;d++)if(f(e,o+d)!==f(t,d)){h=!1;break}if(h)return o}return-1}function y(e,t,r,n){r=Number(r)||0;var i=e.length-r;n?i<(n=Number(n))&&(n=i):n=i;var o=t.length;o/2<n&&(n=o/2);for(var s=0;s<n;++s){var a=parseInt(t.substr(2*s,2),16);if(L(a))return s;e[r+s]=a}return s}function v(e,t,r,n){return O(function(e){for(var t=[],r=0;r<e.length;++r)t.push(255&e.charCodeAt(r));return t}(t),e,r,n)}function g(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function w(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i<r;){var o,s,a,u,f=e[i],c=null,h=239<f?4:223<f?3:191<f?2:1;if(i+h<=r)switch(h){case 1:f<128&&(c=f);break;case 2:128==(192&(o=e[i+1]))&&127<(u=(31&f)<<6|63&o)&&(c=u);break;case 3:o=e[i+1],s=e[i+2],128==(192&o)&&128==(192&s)&&2047<(u=(15&f)<<12|(63&o)<<6|63&s)&&(u<55296||57343<u)&&(c=u);break;case 4:o=e[i+1],s=e[i+2],a=e[i+3],128==(192&o)&&128==(192&s)&&128==(192&a)&&65535<(u=(15&f)<<18|(63&o)<<12|(63&s)<<6|63&a)&&u<1114112&&(c=u)}null===c?(c=65533,h=1):65535<c&&(c-=65536,n.push(c>>>10&1023|55296),c=56320|1023&c),n.push(c),i+=h}return function(e){var t=e.length;if(t<=_)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n<t;)r+=String.fromCharCode.apply(String,e.slice(n,n+=_));return r}(n)}r.kMaxLength=i,(h.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()}catch(e){return!1}}())||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(h.prototype,"parent",{get:function(){if(this instanceof h)return this.buffer}}),Object.defineProperty(h.prototype,"offset",{get:function(){if(this instanceof h)return this.byteOffset}}),"undefined"!=typeof Symbol&&Symbol.species&&h[Symbol.species]===h&&Object.defineProperty(h,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),h.poolSize=8192,h.from=function(e,t,r){return a(e,t,r)},h.prototype.__proto__=Uint8Array.prototype,h.__proto__=Uint8Array,h.alloc=function(e,t,r){return i=t,o=r,u(n=e),n<=0?s(n):void 0!==i?"string"==typeof o?s(n).fill(i,o):s(n).fill(i):s(n);var n,i,o},h.allocUnsafe=function(e){return f(e)},h.allocUnsafeSlow=function(e){return f(e)},h.isBuffer=function(e){return null!=e&&!0===e._isBuffer},h.compare=function(e,t){if(!h.isBuffer(e)||!h.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0},h.isEncoding=function(e){switch(String(e).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}},h.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return h.alloc(0);var r;if(void 0===t)for(r=t=0;r<e.length;++r)t+=e[r].length;var n=h.allocUnsafe(t),i=0;for(r=0;r<e.length;++r){var o=e[r];if(ArrayBuffer.isView(o)&&(o=h.from(o)),!h.isBuffer(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(n,i),i+=o.length}return n},h.byteLength=l,h.prototype._isBuffer=!0,h.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)p(this,t,t+1);return this},h.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)p(this,t,t+3),p(this,t+1,t+2);return this},h.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)p(this,t,t+7),p(this,t+1,t+6),p(this,t+2,t+5),p(this,t+3,t+4);return this},h.prototype.toLocaleString=h.prototype.toString=function(){var e=this.length;return 0===e?"":0===arguments.length?w(this,0,e):function(e,t,r){var n=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return k(this,t,r);case"utf8":case"utf-8":return w(this,t,r);case"ascii":return M(this,t,r);case"latin1":case"binary":return x(this,t,r);case"base64":return g(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return S(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}.apply(this,arguments)},h.prototype.equals=function(e){if(!h.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===h.compare(this,e)},h.prototype.inspect=function(){var e="",t=r.INSPECT_MAX_BYTES;return 0<this.length&&(e=this.toString("hex",0,t).match(/.{2}/g).join(" "),this.length>t&&(e+=" ... ")),"<Buffer "+e+">"},h.prototype.compare=function(e,t,r,n,i){if(!h.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===r&&(r=e?e.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),t<0||r>e.length||n<0||i>this.length)throw new RangeError("out of range index");if(i<=n&&r<=t)return 0;if(i<=n)return-1;if(r<=t)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(n>>>=0),s=(r>>>=0)-(t>>>=0),a=Math.min(o,s),u=this.slice(n,i),f=e.slice(t,r),c=0;c<a;++c)if(u[c]!==f[c]){o=u[c],s=f[c];break}return o<s?-1:s<o?1:0},h.prototype.includes=function(e,t,r){return-1!==this.indexOf(e,t,r)},h.prototype.indexOf=function(e,t,r){return b(this,e,t,r,!0)},h.prototype.lastIndexOf=function(e,t,r){return b(this,e,t,r,!1)},h.prototype.write=function(e,t,r,n){if(void 0===t)n="utf8",r=this.length,t=0;else if(void 0===r&&"string"==typeof t)n=t,r=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(r)?(r>>>=0,void 0===n&&(n="utf8")):(n=r,r=void 0)}var i=this.length-t;if((void 0===r||i<r)&&(r=i),0<e.length&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o,s,a,u,f,c,h,d,l,p=!1;;)switch(n){case"hex":return y(this,e,t,r);case"utf8":case"utf-8":return d=t,l=r,O(P(e,(h=this).length-d),h,d,l);case"ascii":return v(this,e,t,r);case"latin1":case"binary":return v(this,e,t,r);case"base64":return u=this,f=t,c=r,O(R(e),u,f,c);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return s=t,a=r,O(function(e,t){for(var r,n,i,o=[],s=0;s<e.length&&!((t-=2)<0);++s)r=e.charCodeAt(s),n=r>>8,i=r%256,o.push(i),o.push(n);return o}(e,(o=this).length-s),o,s,a);default:if(p)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),p=!0}},h.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var _=4096;function M(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(127&e[i]);return n}function x(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;i<r;++i)n+=String.fromCharCode(e[i]);return n}function k(e,t,r){var n=e.length;(!t||t<0)&&(t=0),(!r||r<0||n<r)&&(r=n);for(var i="",o=t;o<r;++o)i+=C(e[o]);return i}function S(e,t,r){for(var n=e.slice(t,r),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function E(e,t,r){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(r<e+t)throw new RangeError("Trying to access beyond buffer length")}function A(e,t,r,n,i,o){if(!h.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(i<t||t<o)throw new RangeError('"value" argument is out of bounds');if(r+n>e.length)throw new RangeError("Index out of range")}function j(e,t,r,n,i,o){if(r+n>e.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function I(e,t,r,n,i){return t=+t,r>>>=0,i||j(e,0,r,4),o.write(e,t,r,n,23,4),r+4}function B(e,t,r,n,i){return t=+t,r>>>=0,i||j(e,0,r,8),o.write(e,t,r,n,52,8),r+8}h.prototype.slice=function(e,t){var r=this.length;(e=~~e)<0?(e+=r)<0&&(e=0):r<e&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):r<t&&(t=r),t<e&&(t=e);var n=this.subarray(e,t);return n.__proto__=h.prototype,n},h.prototype.readUIntLE=function(e,t,r){e>>>=0,t>>>=0,r||E(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return n},h.prototype.readUIntBE=function(e,t,r){e>>>=0,t>>>=0,r||E(e,t,this.length);for(var n=this[e+--t],i=1;0<t&&(i*=256);)n+=this[e+--t]*i;return n},h.prototype.readUInt8=function(e,t){return e>>>=0,t||E(e,1,this.length),this[e]},h.prototype.readUInt16LE=function(e,t){return e>>>=0,t||E(e,2,this.length),this[e]|this[e+1]<<8},h.prototype.readUInt16BE=function(e,t){return e>>>=0,t||E(e,2,this.length),this[e]<<8|this[e+1]},h.prototype.readUInt32LE=function(e,t){return e>>>=0,t||E(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},h.prototype.readUInt32BE=function(e,t){return e>>>=0,t||E(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},h.prototype.readIntLE=function(e,t,r){e>>>=0,t>>>=0,r||E(e,t,this.length);for(var n=this[e],i=1,o=0;++o<t&&(i*=256);)n+=this[e+o]*i;return(i*=128)<=n&&(n-=Math.pow(2,8*t)),n},h.prototype.readIntBE=function(e,t,r){e>>>=0,t>>>=0,r||E(e,t,this.length);for(var n=t,i=1,o=this[e+--n];0<n&&(i*=256);)o+=this[e+--n]*i;return(i*=128)<=o&&(o-=Math.pow(2,8*t)),o},h.prototype.readInt8=function(e,t){return e>>>=0,t||E(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},h.prototype.readInt16LE=function(e,t){e>>>=0,t||E(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},h.prototype.readInt16BE=function(e,t){e>>>=0,t||E(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},h.prototype.readInt32LE=function(e,t){return e>>>=0,t||E(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},h.prototype.readInt32BE=function(e,t){return e>>>=0,t||E(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},h.prototype.readFloatLE=function(e,t){return e>>>=0,t||E(e,4,this.length),o.read(this,e,!0,23,4)},h.prototype.readFloatBE=function(e,t){return e>>>=0,t||E(e,4,this.length),o.read(this,e,!1,23,4)},h.prototype.readDoubleLE=function(e,t){return e>>>=0,t||E(e,8,this.length),o.read(this,e,!0,52,8)},h.prototype.readDoubleBE=function(e,t){return e>>>=0,t||E(e,8,this.length),o.read(this,e,!1,52,8)},h.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t>>>=0,r>>>=0,n)||A(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o<r&&(i*=256);)this[t+o]=e/i&255;return t+r},h.prototype.writeUIntBE=function(e,t,r,n){(e=+e,t>>>=0,r>>>=0,n)||A(this,e,t,r,Math.pow(2,8*r)-1,0);var i=r-1,o=1;for(this[t+i]=255&e;0<=--i&&(o*=256);)this[t+i]=e/o&255;return t+r},h.prototype.writeUInt8=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,1,255,0),this[t]=255&e,t+1},h.prototype.writeUInt16LE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},h.prototype.writeUInt16BE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},h.prototype.writeUInt32LE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},h.prototype.writeUInt32BE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},h.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t>>>=0,!n){var i=Math.pow(2,8*r-1);A(this,e,t,r,i-1,-i)}var o=0,s=1,a=0;for(this[t]=255&e;++o<r&&(s*=256);)e<0&&0===a&&0!==this[t+o-1]&&(a=1),this[t+o]=(e/s>>0)-a&255;return t+r},h.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t>>>=0,!n){var i=Math.pow(2,8*r-1);A(this,e,t,r,i-1,-i)}var o=r-1,s=1,a=0;for(this[t+o]=255&e;0<=--o&&(s*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/s>>0)-a&255;return t+r},h.prototype.writeInt8=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},h.prototype.writeInt16LE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},h.prototype.writeInt16BE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},h.prototype.writeInt32LE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},h.prototype.writeInt32BE=function(e,t,r){return e=+e,t>>>=0,r||A(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},h.prototype.writeFloatLE=function(e,t,r){return I(this,e,t,!0,r)},h.prototype.writeFloatBE=function(e,t,r){return I(this,e,t,!1,r)},h.prototype.writeDoubleLE=function(e,t,r){return B(this,e,t,!0,r)},h.prototype.writeDoubleBE=function(e,t,r){return B(this,e,t,!1,r)},h.prototype.copy=function(e,t,r,n){if(!h.isBuffer(e))throw new TypeError("argument should be a Buffer");if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),0<n&&n<r&&(n=r),n===r)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(r<0||r>=this.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var i=n-r;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,r,n);else if(this===e&&r<t&&t<n)for(var o=i-1;0<=o;--o)e[o+t]=this[o+r];else Uint8Array.prototype.set.call(e,this.subarray(r,n),t);return i},h.prototype.fill=function(e,t,r,n){if("string"==typeof e){if("string"==typeof t?(n=t,t=0,r=this.length):"string"==typeof r&&(n=r,r=this.length),void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!h.isEncoding(n))throw new TypeError("Unknown encoding: "+n);if(1===e.length){var i=e.charCodeAt(0);("utf8"===n&&i<128||"latin1"===n)&&(e=i)}}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<r)throw new RangeError("Out of range index");if(r<=t)return this;var o;if(t>>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"==typeof e)for(o=t;o<r;++o)this[o]=e;else{var s=h.isBuffer(e)?e:new h(e,n),a=s.length;if(0===a)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(o=0;o<r-t;++o)this[o+t]=s[o%a]}return this};var T=/[^+/0-9A-Za-z-_]/g;function C(e){return e<16?"0"+e.toString(16):e.toString(16)}function P(e,t){var r;t=t||1/0;for(var n=e.length,i=null,o=[],s=0;s<n;++s){if(55295<(r=e.charCodeAt(s))&&r<57344){if(!i){if(56319<r){-1<(t-=3)&&o.push(239,191,189);continue}if(s+1===n){-1<(t-=3)&&o.push(239,191,189);continue}i=r;continue}if(r<56320){-1<(t-=3)&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&-1<(t-=3)&&o.push(239,191,189);if(i=null,r<128){if((t-=1)<0)break;o.push(r)}else if(r<2048){if((t-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((t-=3)<0)break;o.push(r>>12|224,r>>6&63|128,63&r|128)}else{if(!(r<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function R(e){return n.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(T,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function O(e,t,r,n){for(var i=0;i<n&&!(i+r>=t.length||i>=e.length);++i)t[i+r]=e[i];return i}function N(e){return e instanceof ArrayBuffer||null!=e&&null!=e.constructor&&"ArrayBuffer"===e.constructor.name&&"number"==typeof e.byteLength}function L(e){return e!=e}},{"base64-js":15,ieee754:101}],49:[function(e,t,r){t.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"}},{}],50:[function(e,t,r){var i=e("safe-buffer").Buffer,n=e("stream").Transform,o=e("string_decoder").StringDecoder;function s(e){n.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}e("inherits")(s,n),s.prototype.update=function(e,t,r){"string"==typeof e&&(e=i.from(e,t));var n=this._update(e);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)},s.prototype.setAutoPadding=function(){},s.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},s.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},s.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},s.prototype._transform=function(e,t,r){var n;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){n=e}finally{r(n)}},s.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},s.prototype._finalOrDigest=function(e){var t=this.__final()||i.alloc(0);return e&&(t=this._toString(t,e,!0)),t},s.prototype._toString=function(e,t,r){if(this._decoder||(this._decoder=new o(t),this._encoding=t),this._encoding!==t)throw new Error("can't switch encodings");var n=this._decoder.write(e);return r&&(n+=this._decoder.end()),n},t.exports=s},{inherits:103,"safe-buffer":149,stream:158,string_decoder:46}],51:[function(e,t,r){(function(e){function t(e){return Object.prototype.toString.call(e)}r.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===t(e)},r.isBoolean=function(e){return"boolean"==typeof e},r.isNull=function(e){return null===e},r.isNullOrUndefined=function(e){return null==e},r.isNumber=function(e){return"number"==typeof e},r.isString=function(e){return"string"==typeof e},r.isSymbol=function(e){return"symbol"===(void 0===e?"undefined":_typeof(e))},r.isUndefined=function(e){return void 0===e},r.isRegExp=function(e){return"[object RegExp]"===t(e)},r.isObject=function(e){return"object"===(void 0===e?"undefined":_typeof(e))&&null!==e},r.isDate=function(e){return"[object Date]"===t(e)},r.isError=function(e){return"[object Error]"===t(e)||e instanceof Error},r.isFunction=function(e){return"function"==typeof e},r.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"===(void 0===e?"undefined":_typeof(e))||void 0===e},r.isBuffer=e.isBuffer}).call(this,{isBuffer:e("../../is-buffer/index.js")})},{"../../is-buffer/index.js":104}],52:[function(e,a,t){(function(o){var t=e("elliptic"),n=e("bn.js");a.exports=function(e){return new i(e)};var r={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function i(e){this.curveType=r[e],this.curveType||(this.curveType={name:e}),this.curve=new t.ec(this.curveType.name),this.keys=void 0}function s(e,t,r){Array.isArray(e)||(e=e.toArray());var n=new o(e);if(r&&n.length<r){var i=new o(r-n.length);i.fill(0),n=o.concat([i,n])}return t?n.toString(t):n}r.p224=r.secp224r1,r.p256=r.secp256r1=r.prime256v1,r.p192=r.secp192r1=r.prime192v1,r.p384=r.secp384r1,r.p521=r.secp521r1,i.prototype.generateKeys=function(e,t){return this.keys=this.curve.genKeyPair(),this.getPublicKey(e,t)},i.prototype.computeSecret=function(e,t,r){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),s(this.curve.keyFromPublic(e).getPublic().mul(this.keys.getPrivate()).getX(),r,this.curveType.byteLength)},i.prototype.getPublicKey=function(e,t){var r=this.keys.getPublic("compressed"===t,!0);return"hybrid"===t&&(r[r.length-1]%2?r[0]=7:r[0]=6),s(r,e)},i.prototype.getPrivateKey=function(e){return s(this.keys.getPrivate(),e)},i.prototype.setPublicKey=function(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this.keys._importPublic(e),this},i.prototype.setPrivateKey=function(e,t){t=t||"utf8",o.isBuffer(e)||(e=new o(e,t));var r=new n(e);return r=r.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(r),this}}).call(this,e("buffer").Buffer)},{"bn.js":"BN",buffer:48,elliptic:68}],53:[function(e,t,r){var n=e("inherits"),i=e("md5.js"),o=e("ripemd160"),s=e("sha.js"),a=e("cipher-base");function u(e){a.call(this,"digest"),this._hash=e}n(u,a),u.prototype._update=function(e){this._hash.update(e)},u.prototype._final=function(){return this._hash.digest()},t.exports=function(e){return"md5"===(e=e.toLowerCase())?new i:"rmd160"===e||"ripemd160"===e?new o:new u(s(e))}},{"cipher-base":50,inherits:103,"md5.js":106,ripemd160:148,"sha.js":151}],54:[function(e,t,r){var n=e("md5.js");t.exports=function(e){return(new n).update(e).digest()}},{"md5.js":106}],55:[function(e,t,r){var n=e("inherits"),i=e("./legacy"),s=e("cipher-base"),a=e("safe-buffer").Buffer,o=e("create-hash/md5"),u=e("ripemd160"),f=e("sha.js"),c=a.alloc(128);function h(e,t){s.call(this,"digest"),"string"==typeof t&&(t=a.from(t));var r="sha512"===e||"sha384"===e?128:64;(this._alg=e,(this._key=t).length>r)?t=("rmd160"===e?new u:f(e)).update(t).digest():t.length<r&&(t=a.concat([t,c],r));for(var n=this._ipad=a.allocUnsafe(r),i=this._opad=a.allocUnsafe(r),o=0;o<r;o++)n[o]=54^t[o],i[o]=92^t[o];this._hash="rmd160"===e?new u:f(e),this._hash.update(n)}n(h,s),h.prototype._update=function(e){this._hash.update(e)},h.prototype._final=function(){var e=this._hash.digest();return("rmd160"===this._alg?new u:f(this._alg)).update(this._opad).update(e).digest()},t.exports=function(e,t){return"rmd160"===(e=e.toLowerCase())||"ripemd160"===e?new h("rmd160",t):"md5"===e?new i(o,t):new h(e,t)}},{"./legacy":56,"cipher-base":50,"create-hash/md5":54,inherits:103,ripemd160:148,"safe-buffer":149,"sha.js":151}],56:[function(e,t,r){var n=e("inherits"),o=e("safe-buffer").Buffer,s=e("cipher-base"),a=o.alloc(128);function i(e,t){s.call(this,"digest"),"string"==typeof t&&(t=o.from(t)),this._alg=e,64<(this._key=t).length?t=e(t):t.length<64&&(t=o.concat([t,a],64));for(var r=this._ipad=o.allocUnsafe(64),n=this._opad=o.allocUnsafe(64),i=0;i<64;i++)r[i]=54^t[i],n[i]=92^t[i];this._hash=[r]}n(i,s),i.prototype._update=function(e){this._hash.push(e)},i.prototype._final=function(){var e=this._alg(o.concat(this._hash));return this._alg(o.concat([this._opad,e]))},t.exports=i},{"cipher-base":50,inherits:103,"safe-buffer":149}],57:[function(e,t,r){r.randomBytes=r.rng=r.pseudoRandomBytes=r.prng=e("randombytes"),r.createHash=r.Hash=e("create-hash"),r.createHmac=r.Hmac=e("create-hmac");var n=e("browserify-sign/algos"),i=Object.keys(n),o=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(i);r.getHashes=function(){return o};var s=e("pbkdf2");r.pbkdf2=s.pbkdf2,r.pbkdf2Sync=s.pbkdf2Sync;var a=e("browserify-cipher");r.Cipher=a.Cipher,r.createCipher=a.createCipher,r.Cipheriv=a.Cipheriv,r.createCipheriv=a.createCipheriv,r.Decipher=a.Decipher,r.createDecipher=a.createDecipher,r.Decipheriv=a.Decipheriv,r.createDecipheriv=a.createDecipheriv,r.getCiphers=a.getCiphers,r.listCiphers=a.listCiphers;var u=e("diffie-hellman");r.DiffieHellmanGroup=u.DiffieHellmanGroup,r.createDiffieHellmanGroup=u.createDiffieHellmanGroup,r.getDiffieHellman=u.getDiffieHellman,r.createDiffieHellman=u.createDiffieHellman,r.DiffieHellman=u.DiffieHellman;var f=e("browserify-sign");r.createSign=f.createSign,r.Sign=f.Sign,r.createVerify=f.createVerify,r.Verify=f.Verify,r.createECDH=e("create-ecdh");var c=e("public-encrypt");r.publicEncrypt=c.publicEncrypt,r.privateEncrypt=c.privateEncrypt,r.publicDecrypt=c.publicDecrypt,r.privateDecrypt=c.privateDecrypt;var h=e("randomfill");r.randomFill=h.randomFill,r.randomFillSync=h.randomFillSync,r.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join("\n"))},r.constants={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,ALPN_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}},{"browserify-cipher":35,"browserify-sign":42,"browserify-sign/algos":39,"create-ecdh":52,"create-hash":53,"create-hmac":55,"diffie-hellman":64,pbkdf2:116,"public-encrypt":123,randombytes:133,randomfill:134}],58:[function(e,t,r){r.utils=e("./des/utils"),r.Cipher=e("./des/cipher"),r.DES=e("./des/des"),r.CBC=e("./des/cbc"),r.EDE=e("./des/ede")},{"./des/cbc":59,"./des/cipher":60,"./des/des":61,"./des/ede":62,"./des/utils":63}],59:[function(e,t,r){var n=e("minimalistic-assert"),o=e("inherits"),s={};function i(e){n.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t<this.iv.length;t++)this.iv[t]=e[t]}r.instantiate=function(t){function r(e){t.call(this,e),this._cbcInit()}o(r,t);for(var e=Object.keys(s),n=0;n<e.length;n++){var i=e[n];r.prototype[i]=s[i]}return r.create=function(e){return new r(e)},r},s._cbcInit=function(){var e=new i(this.options.iv);this._cbcState=e},s._update=function(e,t,r,n){var i=this._cbcState,o=this.constructor.super_.prototype,s=i.iv;if("encrypt"===this.type){for(var a=0;a<this.blockSize;a++)s[a]^=e[t+a];o._update.call(this,s,0,r,n);for(a=0;a<this.blockSize;a++)s[a]=r[n+a]}else{o._update.call(this,e,t,r,n);for(a=0;a<this.blockSize;a++)r[n+a]^=s[a];for(a=0;a<this.blockSize;a++)s[a]=e[t+a]}}},{inherits:103,"minimalistic-assert":108}],60:[function(e,t,r){var n=e("minimalistic-assert");function i(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}(t.exports=i).prototype._init=function(){},i.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},i.prototype._buffer=function(e,t){for(var r=Math.min(this.buffer.length-this.bufferOff,e.length-t),n=0;n<r;n++)this.buffer[this.bufferOff+n]=e[t+n];return this.bufferOff+=r,r},i.prototype._flushBuffer=function(e,t){return this._update(this.buffer,0,e,t),this.bufferOff=0,this.blockSize},i.prototype._updateEncrypt=function(e){var t=0,r=0,n=(this.bufferOff+e.length)/this.blockSize|0,i=new Array(n*this.blockSize);0!==this.bufferOff&&(t+=this._buffer(e,t),this.bufferOff===this.buffer.length&&(r+=this._flushBuffer(i,r)));for(var o=e.length-(e.length-t)%this.blockSize;t<o;t+=this.blockSize)this._update(e,t,i,r),r+=this.blockSize;for(;t<e.length;t++,this.bufferOff++)this.buffer[this.bufferOff]=e[t];return i},i.prototype._updateDecrypt=function(e){for(var t=0,r=0,n=Math.ceil((this.bufferOff+e.length)/this.blockSize)-1,i=new Array(n*this.blockSize);0<n;n--)t+=this._buffer(e,t),r+=this._flushBuffer(i,r);return t+=this._buffer(e,t),i},i.prototype.final=function(e){var t,r;return e&&(t=this.update(e)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(r):r},i.prototype._pad=function(e,t){if(0===t)return!1;for(;t<e.length;)e[t++]=0;return!0},i.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var e=new Array(this.blockSize);return this._update(this.buffer,0,e,0),e},i.prototype._unpad=function(e){return e},i.prototype._finalDecrypt=function(){n.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var e=new Array(this.blockSize);return this._flushBuffer(e,0),this._unpad(e)}},{"minimalistic-assert":108}],61:[function(e,t,r){var s=e("minimalistic-assert"),n=e("inherits"),i=e("../des"),d=i.utils,o=i.Cipher;function a(){this.tmp=new Array(2),this.keys=null}function u(e){o.call(this,e);var t=new a;this._desState=t,this.deriveKeys(t,e.key)}n(u,o),(t.exports=u).create=function(e){return new u(e)};var f=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];u.prototype.deriveKeys=function(e,t){e.keys=new Array(32),s.equal(t.length,this.blockSize,"Invalid key length");var r=d.readUInt32BE(t,0),n=d.readUInt32BE(t,4);d.pc1(r,n,e.tmp,0),r=e.tmp[0],n=e.tmp[1];for(var i=0;i<e.keys.length;i+=2){var o=f[i>>>1];r=d.r28shl(r,o),n=d.r28shl(n,o),d.pc2(r,n,e.keys,i)}},u.prototype._update=function(e,t,r,n){var i=this._desState,o=d.readUInt32BE(e,t),s=d.readUInt32BE(e,t+4);d.ip(o,s,i.tmp,0),o=i.tmp[0],s=i.tmp[1],"encrypt"===this.type?this._encrypt(i,o,s,i.tmp,0):this._decrypt(i,o,s,i.tmp,0),o=i.tmp[0],s=i.tmp[1],d.writeUInt32BE(r,o,n),d.writeUInt32BE(r,s,n+4)},u.prototype._pad=function(e,t){for(var r=e.length-t,n=t;n<e.length;n++)e[n]=r;return!0},u.prototype._unpad=function(e){for(var t=e[e.length-1],r=e.length-t;r<e.length;r++)s.equal(e[r],t);return e.slice(0,e.length-t)},u.prototype._encrypt=function(e,t,r,n,i){for(var o=t,s=r,a=0;a<e.keys.length;a+=2){var u=e.keys[a],f=e.keys[a+1];d.expand(s,e.tmp,0),u^=e.tmp[0],f^=e.tmp[1];var c=d.substitute(u,f),h=s;s=(o^d.permute(c))>>>0,o=h}d.rip(s,o,n,i)},u.prototype._decrypt=function(e,t,r,n,i){for(var o=r,s=t,a=e.keys.length-2;0<=a;a-=2){var u=e.keys[a],f=e.keys[a+1];d.expand(o,e.tmp,0),u^=e.tmp[0],f^=e.tmp[1];var c=d.substitute(u,f),h=o;o=(s^d.permute(c))>>>0,s=h}d.rip(o,s,n,i)}},{"../des":58,inherits:103,"minimalistic-assert":108}],62:[function(e,t,r){var o=e("minimalistic-assert"),n=e("inherits"),i=e("../des"),s=i.Cipher,a=i.DES;function u(e,t){o.equal(t.length,24,"Invalid key length");var r=t.slice(0,8),n=t.slice(8,16),i=t.slice(16,24);this.ciphers="encrypt"===e?[a.create({type:"encrypt",key:r}),a.create({type:"decrypt",key:n}),a.create({type:"encrypt",key:i})]:[a.create({type:"decrypt",key:i}),a.create({type:"encrypt",key:n}),a.create({type:"decrypt",key:r})]}function f(e){s.call(this,e);var t=new u(this.type,this.options.key);this._edeState=t}n(f,s),(t.exports=f).create=function(e){return new f(e)},f.prototype._update=function(e,t,r,n){var i=this._edeState;i.ciphers[0]._update(e,t,r,n),i.ciphers[1]._update(r,n,r,n),i.ciphers[2]._update(r,n,r,n)},f.prototype._pad=a.prototype._pad,f.prototype._unpad=a.prototype._unpad},{"../des":58,inherits:103,"minimalistic-assert":108}],63:[function(e,t,r){r.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},r.writeUInt32BE=function(e,t,r){e[0+r]=t>>>24,e[1+r]=t>>>16&255,e[2+r]=t>>>8&255,e[3+r]=255&t},r.ip=function(e,t,r,n){for(var i=0,o=0,s=6;0<=s;s-=2){for(var a=0;a<=24;a+=8)i<<=1,i|=t>>>a+s&1;for(a=0;a<=24;a+=8)i<<=1,i|=e>>>a+s&1}for(s=6;0<=s;s-=2){for(a=1;a<=25;a+=8)o<<=1,o|=t>>>a+s&1;for(a=1;a<=25;a+=8)o<<=1,o|=e>>>a+s&1}r[n+0]=i>>>0,r[n+1]=o>>>0},r.rip=function(e,t,r,n){for(var i=0,o=0,s=0;s<4;s++)for(var a=24;0<=a;a-=8)i<<=1,i|=t>>>a+s&1,i<<=1,i|=e>>>a+s&1;for(s=4;s<8;s++)for(a=24;0<=a;a-=8)o<<=1,o|=t>>>a+s&1,o<<=1,o|=e>>>a+s&1;r[n+0]=i>>>0,r[n+1]=o>>>0},r.pc1=function(e,t,r,n){for(var i=0,o=0,s=7;5<=s;s--){for(var a=0;a<=24;a+=8)i<<=1,i|=t>>a+s&1;for(a=0;a<=24;a+=8)i<<=1,i|=e>>a+s&1}for(a=0;a<=24;a+=8)i<<=1,i|=t>>a+s&1;for(s=1;s<=3;s++){for(a=0;a<=24;a+=8)o<<=1,o|=t>>a+s&1;for(a=0;a<=24;a+=8)o<<=1,o|=e>>a+s&1}for(a=0;a<=24;a+=8)o<<=1,o|=e>>a+s&1;r[n+0]=i>>>0,r[n+1]=o>>>0},r.r28shl=function(e,t){return e<<t&268435455|e>>>28-t};var u=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];r.pc2=function(e,t,r,n){for(var i=0,o=0,s=u.length>>>1,a=0;a<s;a++)i<<=1,i|=e>>>u[a]&1;for(a=s;a<u.length;a++)o<<=1,o|=t>>>u[a]&1;r[n+0]=i>>>0,r[n+1]=o>>>0},r.expand=function(e,t,r){var n=0,i=0;n=(1&e)<<5|e>>>27;for(var o=23;15<=o;o-=4)n<<=6,n|=e>>>o&63;for(o=11;3<=o;o-=4)i|=e>>>o&63,i<<=6;i|=(31&e)<<1|e>>>31,t[r+0]=n>>>0,t[r+1]=i>>>0};var i=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];r.substitute=function(e,t){for(var r=0,n=0;n<4;n++){r<<=4,r|=i[64*n+(e>>>18-6*n&63)]}for(n=0;n<4;n++){r<<=4,r|=i[256+64*n+(t>>>18-6*n&63)]}return r>>>0};var n=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];r.permute=function(e){for(var t=0,r=0;r<n.length;r++)t<<=1,t|=e>>>n[r]&1;return t>>>0},r.padSplit=function(e,t,r){for(var n=e.toString(2);n.length<t;)n="0"+n;for(var i=[],o=0;o<t;o+=r)i.push(n.slice(o,o+r));return i.join(" ")}},{}],64:[function(e,t,r){(function(o){var s=e("./lib/generatePrime"),n=e("./lib/primes.json"),a=e("./lib/dh");var u={binary:!0,hex:!0,base64:!0};r.DiffieHellmanGroup=r.createDiffieHellmanGroup=r.getDiffieHellman=function(e){var t=new o(n[e].prime,"hex"),r=new o(n[e].gen,"hex");return new a(t,r)},r.createDiffieHellman=r.DiffieHellman=function e(t,r,n,i){return o.isBuffer(r)||void 0===u[r]?e(t,"binary",r,n):(r=r||"binary",i=i||"binary",n=n||new o([2]),o.isBuffer(n)||(n=new o(n,i)),"number"==typeof t?new a(s(t,n),n,!0):(o.isBuffer(t)||(t=new o(t,r)),new a(t,n,!0)))}}).call(this,e("buffer").Buffer)},{"./lib/dh":65,"./lib/generatePrime":66,"./lib/primes.json":67,buffer:48}],65:[function(b,m,e){(function(o){var s=b("bn.js"),a=new(b("miller-rabin")),u=new s(24),f=new s(11),c=new s(10),h=new s(3),d=new s(7),l=b("./generatePrime"),e=b("randombytes");function n(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this._pub=new s(e),this}function i(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this._priv=new s(e),this}m.exports=t;var p={};function t(e,t,r){this.setGenerator(t),this.__prime=new s(e),this._prime=s.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=n,this.setPrivateKey=i):this._primeCode=8}function r(e,t){var r=new o(e.toArray());return t?r.toString(t):r}Object.defineProperty(t.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in p)return p[n];var i,o=0;if(e.isEven()||!l.simpleSieve||!l.fermatTest(e)||!a.test(e))return o+=1,o+="02"===r||"05"===r?8:4,p[n]=o;switch(a.test(e.shrn(1))||(o+=2),r){case"02":e.mod(u).cmp(f)&&(o+=8);break;case"05":(i=e.mod(c)).cmp(h)&&i.cmp(d)&&(o+=8);break;default:o+=4}return p[n]=o}(this.__prime,this.__gen)),this._primeCode}}),t.prototype.generateKeys=function(){return this._priv||(this._priv=new s(e(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},t.prototype.computeSecret=function(e){var t=(e=(e=new s(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new o(t.toArray()),n=this.getPrime();if(r.length<n.length){var i=new o(n.length-r.length);i.fill(0),r=o.concat([i,r])}return r},t.prototype.getPublicKey=function(e){return r(this._pub,e)},t.prototype.getPrivateKey=function(e){return r(this._priv,e)},t.prototype.getPrime=function(e){return r(this.__prime,e)},t.prototype.getGenerator=function(e){return r(this._gen,e)},t.prototype.setGenerator=function(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this.__gen=e,this._gen=new s(e),this}}).call(this,b("buffer").Buffer)},{"./generatePrime":66,"bn.js":"BN",buffer:48,"miller-rabin":107,randombytes:133}],66:[function(e,t,r){var i=e("randombytes");(t.exports=n).simpleSieve=m,n.fermatTest=y;var o=e("bn.js"),s=new o(24),a=new(e("miller-rabin")),u=new o(1),f=new o(2),c=new o(5),h=(new o(16),new o(8),new o(10)),d=new o(3),l=(new o(7),new o(11)),p=new o(4),b=(new o(12),null);function m(e){for(var t=function(){if(null!==b)return b;var e=[];e[0]=2;for(var t=1,r=3;r<1048576;r+=2){for(var n=Math.ceil(Math.sqrt(r)),i=0;i<t&&e[i]<=n&&r%e[i]!=0;i++);t!==i&&e[i]<=n||(e[t++]=r)}return b=e}(),r=0;r<t.length;r++)if(0===e.modn(t[r]))return 0===e.cmpn(t[r]);return!0}function y(e){var t=o.mont(e);return 0===f.toRed(t).redPow(e.subn(1)).fromRed().cmpn(1)}function n(e,t){if(e<16)return new o(2===t||5===t?[140,123]:[140,39]);var r,n;for(t=new o(t);;){for(r=new o(i(Math.ceil(e/8)));r.bitLength()>e;)r.ishrn(1);if(r.isEven()&&r.iadd(u),r.testn(1)||r.iadd(f),t.cmp(f)){if(!t.cmp(c))for(;r.mod(h).cmp(d);)r.iadd(p)}else for(;r.mod(s).cmp(l);)r.iadd(p);if(m(n=r.shrn(1))&&m(r)&&y(n)&&y(r)&&a.test(n)&&a.test(r))return r}}},{"bn.js":"BN","miller-rabin":107,randombytes:133}],67:[function(e,t,r){t.exports={modp1:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}},{}],68:[function(e,t,r){var n=r;n.version=e("../package.json").version,n.utils=e("./elliptic/utils"),n.rand=e("brorand"),n.curve=e("./elliptic/curve"),n.curves=e("./elliptic/curves"),n.ec=e("./elliptic/ec"),n.eddsa=e("./elliptic/eddsa")},{"../package.json":83,"./elliptic/curve":71,"./elliptic/curves":74,"./elliptic/ec":75,"./elliptic/eddsa":78,"./elliptic/utils":82,brorand:16}],69:[function(e,t,r){var n=e("bn.js"),i=e("../../elliptic").utils,S=i.getNAF,E=i.getJSF,h=i.assert;function o(e,t){this.type=e,this.p=new n(t.p,16),this.red=t.prime?n.red(t.prime):n.mont(this.p),this.zero=new n(0).toRed(this.red),this.one=new n(1).toRed(this.red),this.two=new n(2).toRed(this.red),this.n=t.n&&new n(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4);var r=this.n&&this.p.div(this.n);!r||0<r.cmpn(100)?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function s(e,t){this.curve=e,this.type=t,this.precomputed=null}(t.exports=o).prototype.point=function(){throw new Error("Not implemented")},o.prototype.validate=function(){throw new Error("Not implemented")},o.prototype._fixedNafMul=function(e,t){h(e.precomputed);var r=e._getDoubles(),n=S(t,1),i=(1<<r.step+1)-(r.step%2==0?2:1);i/=3;for(var o=[],s=0;s<n.length;s+=r.step){var a=0;for(t=s+r.step-1;s<=t;t--)a=(a<<1)+n[t];o.push(a)}for(var u=this.jpoint(null,null,null),f=this.jpoint(null,null,null),c=i;0<c;c--){for(s=0;s<o.length;s++){(a=o[s])===c?f=f.mixedAdd(r.points[s]):a===-c&&(f=f.mixedAdd(r.points[s].neg()))}u=u.add(f)}return u.toP()},o.prototype._wnafMul=function(e,t){var r=4,n=e._getNAFPoints(r);r=n.wnd;for(var i=n.points,o=S(t,r),s=this.jpoint(null,null,null),a=o.length-1;0<=a;a--){for(t=0;0<=a&&0===o[a];a--)t++;if(0<=a&&t++,s=s.dblp(t),a<0)break;var u=o[a];h(0!==u),s="affine"===e.type?0<u?s.mixedAdd(i[u-1>>1]):s.mixedAdd(i[-u-1>>1].neg()):0<u?s.add(i[u-1>>1]):s.add(i[-u-1>>1].neg())}return"affine"===e.type?s.toP():s},o.prototype._wnafMulAdd=function(e,t,r,n,i){for(var o=this._wnafT1,s=this._wnafT2,a=this._wnafT3,u=0,f=0;f<n;f++){var c=(x=t[f])._getNAFPoints(e);o[f]=c.wnd,s[f]=c.points}for(f=n-1;1<=f;f-=2){var h=f-1,d=f;if(1===o[h]&&1===o[d]){var l=[t[h],null,null,t[d]];0===t[h].y.cmp(t[d].y)?(l[1]=t[h].add(t[d]),l[2]=t[h].toJ().mixedAdd(t[d].neg())):0===t[h].y.cmp(t[d].y.redNeg())?(l[1]=t[h].toJ().mixedAdd(t[d]),l[2]=t[h].add(t[d].neg())):(l[1]=t[h].toJ().mixedAdd(t[d]),l[2]=t[h].toJ().mixedAdd(t[d].neg()));var p=[-3,-1,-5,-7,0,7,5,1,3],b=E(r[h],r[d]);u=Math.max(b[0].length,u),a[h]=new Array(u),a[d]=new Array(u);for(var m=0;m<u;m++){var y=0|b[0][m],v=0|b[1][m];a[h][m]=p[3*(y+1)+(v+1)],a[d][m]=0,s[h]=l}}else a[h]=S(r[h],o[h]),a[d]=S(r[d],o[d]),u=Math.max(a[h].length,u),u=Math.max(a[d].length,u)}var g=this.jpoint(null,null,null),w=this._wnafT4;for(f=u;0<=f;f--){for(var _=0;0<=f;){var M=!0;for(m=0;m<n;m++)w[m]=0|a[m][f],0!==w[m]&&(M=!1);if(!M)break;_++,f--}if(0<=f&&_++,g=g.dblp(_),f<0)break;for(m=0;m<n;m++){var x,k=w[m];0!==k&&(0<k?x=s[m][k-1>>1]:k<0&&(x=s[m][-k-1>>1].neg()),g="affine"===x.type?g.mixedAdd(x):g.add(x))}}for(f=0;f<n;f++)s[f]=null;return i?g:g.toP()},(o.BasePoint=s).prototype.eq=function(){throw new Error("Not implemented")},s.prototype.validate=function(){return this.curve.validate(this)},o.prototype.decodePoint=function(e,t){e=i.toArray(e,t);var r=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1==2*r)return 6===e[0]?h(e[e.length-1]%2==0):7===e[0]&&h(e[e.length-1]%2==1),this.point(e.slice(1,1+r),e.slice(1+r,1+2*r));if((2===e[0]||3===e[0])&&e.length-1===r)return this.pointFromX(e.slice(1,1+r),3===e[0]);throw new Error("Unknown point format")},s.prototype.encodeCompressed=function(e){return this.encode(e,!0)},s.prototype._encode=function(e){var t=this.curve.p.byteLength(),r=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(r):[4].concat(r,this.getY().toArray("be",t))},s.prototype.encode=function(e,t){return i.encode(this._encode(t),e)},s.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},s.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},s.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],n=this,i=0;i<t;i+=e){for(var o=0;o<e;o++)n=n.dbl();r.push(n)}return{step:e,points:r}},s.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],r=(1<<e)-1,n=1===r?null:this.dbl(),i=1;i<r;i++)t[i]=t[i-1].add(n);return{wnd:e,points:t}},s.prototype._getBeta=function(){return null},s.prototype.dblp=function(e){for(var t=this,r=0;r<e;r++)t=t.dbl();return t}},{"../../elliptic":68,"bn.js":"BN"}],70:[function(e,t,r){var n=e("../curve"),i=e("../../elliptic"),u=e("bn.js"),o=e("inherits"),s=n.base,a=i.utils.assert;function f(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,s.call(this,"edwards",e),this.a=new u(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new u(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new u(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),a(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,r,n,i){s.BasePoint.call(this,e,"projective"),null===t&&null===r&&null===n?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new u(t,16),this.y=new u(r,16),this.z=n?new u(n,16):this.curve.one,this.t=i&&new u(i,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}o(f,s),(t.exports=f).prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},f.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},f.prototype.jpoint=function(e,t,r,n){return this.point(e,t,r,n)},f.prototype.pointFromX=function(e,t){(e=new u(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=this.c2.redSub(this.a.redMul(r)),i=this.one.redSub(this.c2.redMul(this.d).redMul(r)),o=n.redMul(i.redInvm()),s=o.redSqrt();if(0!==s.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");var a=s.fromRed().isOdd();return(t&&!a||!t&&a)&&(s=s.redNeg()),this.point(e,s)},f.prototype.pointFromY=function(e,t){(e=new u(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr(),n=r.redSub(this.one),i=r.redMul(this.d).redAdd(this.one),o=n.redMul(i.redInvm());if(0===o.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var s=o.redSqrt();if(0!==s.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");return s.isOdd()!==t&&(s=s.redNeg()),this.point(s,e)},f.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),r=e.y.redSqr(),n=t.redMul(this.a).redAdd(r),i=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(r)));return 0===n.cmp(i)},o(c,s.BasePoint),f.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},f.prototype.point=function(e,t,r,n){return new c(this,e,t,r,n)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&0===this.y.cmp(this.z)},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var n=this.curve._mulA(e),i=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),o=n.redAdd(t),s=o.redSub(r),a=n.redSub(t),u=i.redMul(s),f=o.redMul(a),c=i.redMul(a),h=s.redMul(o);return this.curve.point(u,f,h,c)},c.prototype._projDbl=function(){var e,t,r,n=this.x.redAdd(this.y).redSqr(),i=this.x.redSqr(),o=this.y.redSqr();if(this.curve.twisted){var s=(f=this.curve._mulA(i)).redAdd(o);if(this.zOne)e=n.redSub(i).redSub(o).redMul(s.redSub(this.curve.two)),t=s.redMul(f.redSub(o)),r=s.redSqr().redSub(s).redSub(s);else{var a=this.z.redSqr(),u=s.redSub(a).redISub(a);e=n.redSub(i).redISub(o).redMul(u),t=s.redMul(f.redSub(o)),r=s.redMul(u)}}else{var f=i.redAdd(o);a=this.curve._mulC(this.c.redMul(this.z)).redSqr(),u=f.redSub(a).redSub(a);e=this.curve._mulC(n.redISub(f)).redMul(u),t=this.curve._mulC(f).redMul(i.redISub(o)),r=f.redMul(u)}return this.curve.point(e,t,r)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),r=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),n=this.t.redMul(this.curve.dd).redMul(e.t),i=this.z.redMul(e.z.redAdd(e.z)),o=r.redSub(t),s=i.redSub(n),a=i.redAdd(n),u=r.redAdd(t),f=o.redMul(s),c=a.redMul(u),h=o.redMul(u),d=s.redMul(a);return this.curve.point(f,c,d,h)},c.prototype._projAdd=function(e){var t,r,n=this.z.redMul(e.z),i=n.redSqr(),o=this.x.redMul(e.x),s=this.y.redMul(e.y),a=this.curve.d.redMul(o).redMul(s),u=i.redSub(a),f=i.redAdd(a),c=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(o).redISub(s),h=n.redMul(u).redMul(c);return this.curve.twisted?(t=n.redMul(f).redMul(s.redSub(this.curve._mulA(o))),r=u.redMul(f)):(t=n.redMul(f).redMul(s.redSub(o)),r=this.curve._mulC(u).redMul(f)),this.curve.point(h,t,r)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!1)},c.prototype.jmulAdd=function(e,t,r){return this.curve._wnafMulAdd(1,[this,t],[e,r],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),0<=r.cmp(this.curve.p))return!1;if(t.redIAdd(n),0===this.x.cmp(t))return!0}return!1},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},{"../../elliptic":68,"../curve":71,"bn.js":"BN",inherits:103}],71:[function(e,t,r){var n=r;n.base=e("./base"),n.short=e("./short"),n.mont=e("./mont"),n.edwards=e("./edwards")},{"./base":69,"./edwards":70,"./mont":72,"./short":73}],72:[function(e,t,r){var n=e("../curve"),i=e("bn.js"),o=e("inherits"),s=n.base,a=e("../../elliptic").utils;function u(e){s.call(this,"mont",e),this.a=new i(e.a,16).toRed(this.red),this.b=new i(e.b,16).toRed(this.red),this.i4=new i(4).toRed(this.red).redInvm(),this.two=new i(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function f(e,t,r){s.BasePoint.call(this,e,"projective"),null===t&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new i(t,16),this.z=new i(r,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}o(u,s),(t.exports=u).prototype.validate=function(e){var t=e.normalize().x,r=t.redSqr(),n=r.redMul(t).redAdd(r.redMul(this.a)).redAdd(t);return 0===n.redSqrt().redSqr().cmp(n)},o(f,s.BasePoint),u.prototype.decodePoint=function(e,t){return this.point(a.toArray(e,t),1)},u.prototype.point=function(e,t){return new f(this,e,t)},u.prototype.pointFromJSON=function(e){return f.fromJSON(this,e)},f.prototype.precompute=function(){},f.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},f.fromJSON=function(e,t){return new f(e,t[0],t[1]||e.one)},f.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},f.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},f.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),r=e.redSub(t),n=e.redMul(t),i=r.redMul(t.redAdd(this.curve.a24.redMul(r)));return this.curve.point(n,i)},f.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},f.prototype.diffAdd=function(e,t){var r=this.x.redAdd(this.z),n=this.x.redSub(this.z),i=e.x.redAdd(e.z),o=e.x.redSub(e.z).redMul(r),s=i.redMul(n),a=t.z.redMul(o.redAdd(s).redSqr()),u=t.x.redMul(o.redISub(s).redSqr());return this.curve.point(a,u)},f.prototype.mul=function(e){for(var t=e.clone(),r=this,n=this.curve.point(null,null),i=[];0!==t.cmpn(0);t.iushrn(1))i.push(t.andln(1));for(var o=i.length-1;0<=o;o--)0===i[o]?(r=r.diffAdd(n,this),n=n.dbl()):(n=r.diffAdd(n,this),r=r.dbl());return n},f.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},f.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},f.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},f.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},f.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},{"../../elliptic":68,"../curve":71,"bn.js":"BN",inherits:103}],73:[function(e,t,r){var n=e("../curve"),i=e("../../elliptic"),_=e("bn.js"),o=e("inherits"),s=n.base,a=i.utils.assert;function u(e){s.call(this,"short",e),this.a=new _(e.a,16).toRed(this.red),this.b=new _(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function f(e,t,r,n){s.BasePoint.call(this,e,"affine"),null===t&&null===r?(this.x=null,this.y=null,this.inf=!0):(this.x=new _(t,16),this.y=new _(r,16),n&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function c(e,t,r,n){s.BasePoint.call(this,e,"jacobian"),null===t&&null===r&&null===n?(this.x=this.curve.one,this.y=this.curve.one,this.z=new _(0)):(this.x=new _(t,16),this.y=new _(r,16),this.z=new _(n,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}o(u,s),(t.exports=u).prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,r;if(e.beta)t=new _(e.beta,16).toRed(this.red);else{var n=this._getEndoRoots(this.p);t=(t=n[0].cmp(n[1])<0?n[0]:n[1]).toRed(this.red)}if(e.lambda)r=new _(e.lambda,16);else{var i=this._getEndoRoots(this.n);0===this.g.mul(i[0]).x.cmp(this.g.x.redMul(t))?r=i[0]:(r=i[1],a(0===this.g.mul(r).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:r,basis:e.basis?e.basis.map(function(e){return{a:new _(e.a,16),b:new _(e.b,16)}}):this._getEndoBasis(r)}}},u.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:_.mont(e),r=new _(2).toRed(t).redInvm(),n=r.redNeg(),i=new _(3).toRed(t).redNeg().redSqrt().redMul(r);return[n.redAdd(i).fromRed(),n.redSub(i).fromRed()]},u.prototype._getEndoBasis=function(e){for(var t,r,n,i,o,s,a,u,f,c=this.n.ushrn(Math.floor(this.n.bitLength()/2)),h=e,d=this.n.clone(),l=new _(1),p=new _(0),b=new _(0),m=new _(1),y=0;0!==h.cmpn(0);){var v=d.div(h);u=d.sub(v.mul(h)),f=b.sub(v.mul(l));var g=m.sub(v.mul(p));if(!n&&u.cmp(c)<0)t=a.neg(),r=l,n=u.neg(),i=f;else if(n&&2==++y)break;d=h,h=a=u,b=l,l=f,m=p,p=g}o=u.neg(),s=f;var w=n.sqr().add(i.sqr());return 0<=o.sqr().add(s.sqr()).cmp(w)&&(o=t,s=r),n.negative&&(n=n.neg(),i=i.neg()),o.negative&&(o=o.neg(),s=s.neg()),[{a:n,b:i},{a:o,b:s}]},u.prototype._endoSplit=function(e){var t=this.endo.basis,r=t[0],n=t[1],i=n.b.mul(e).divRound(this.n),o=r.b.neg().mul(e).divRound(this.n),s=i.mul(r.a),a=o.mul(n.a),u=i.mul(r.b),f=o.mul(n.b);return{k1:e.sub(s).sub(a),k2:u.add(f).neg()}},u.prototype.pointFromX=function(e,t){(e=new _(e,16)).red||(e=e.toRed(this.red));var r=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),n=r.redSqrt();if(0!==n.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var i=n.fromRed().isOdd();return(t&&!i||!t&&i)&&(n=n.redNeg()),this.point(e,n)},u.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,r=e.y,n=this.a.redMul(t),i=t.redSqr().redMul(t).redIAdd(n).redIAdd(this.b);return 0===r.redSqr().redISub(i).cmpn(0)},u.prototype._endoWnafMulAdd=function(e,t,r){for(var n=this._endoWnafT1,i=this._endoWnafT2,o=0;o<e.length;o++){var s=this._endoSplit(t[o]),a=e[o],u=a._getBeta();s.k1.negative&&(s.k1.ineg(),a=a.neg(!0)),s.k2.negative&&(s.k2.ineg(),u=u.neg(!0)),n[2*o]=a,n[2*o+1]=u,i[2*o]=s.k1,i[2*o+1]=s.k2}for(var f=this._wnafMulAdd(1,n,i,2*o,r),c=0;c<2*o;c++)n[c]=null,i[c]=null;return f},o(f,s.BasePoint),u.prototype.point=function(e,t,r){return new f(this,e,t,r)},u.prototype.pointFromJSON=function(e,t){return f.fromJSON(this,e,t)},f.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var r=this.curve,n=function(e){return r.point(e.x.redMul(r.endo.beta),e.y)};(e.beta=t).precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(n)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(n)}}}return t}},f.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},f.fromJSON=function(t,e,r){"string"==typeof e&&(e=JSON.parse(e));var n=t.point(e[0],e[1],r);if(!e[2])return n;function i(e){return t.point(e[0],e[1],r)}var o=e[2];return n.precomputed={beta:null,doubles:o.doubles&&{step:o.doubles.step,points:[n].concat(o.doubles.points.map(i))},naf:o.naf&&{wnd:o.naf.wnd,points:[n].concat(o.naf.points.map(i))}},n},f.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},f.prototype.isInfinity=function(){return this.inf},f.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var r=t.redSqr().redISub(this.x).redISub(e.x),n=t.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,n)},f.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,r=this.x.redSqr(),n=e.redInvm(),i=r.redAdd(r).redIAdd(r).redIAdd(t).redMul(n),o=i.redSqr().redISub(this.x.redAdd(this.x)),s=i.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,s)},f.prototype.getX=function(){return this.x.fromRed()},f.prototype.getY=function(){return this.y.fromRed()},f.prototype.mul=function(e){return e=new _(e,16),this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},f.prototype.mulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i):this.curve._wnafMulAdd(1,n,i,2)},f.prototype.jmulAdd=function(e,t,r){var n=[this,t],i=[e,r];return this.curve.endo?this.curve._endoWnafMulAdd(n,i,!0):this.curve._wnafMulAdd(1,n,i,2,!0)},f.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},f.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var r=this.precomputed,n=function(e){return e.neg()};t.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(n)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(n)}}}return t},f.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(c,s.BasePoint),u.prototype.jpoint=function(e,t,r){return new c(this,e,t,r)},c.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),r=this.x.redMul(t),n=this.y.redMul(t).redMul(e);return this.curve.point(r,n)},c.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},c.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),r=this.z.redSqr(),n=this.x.redMul(t),i=e.x.redMul(r),o=this.y.redMul(t.redMul(e.z)),s=e.y.redMul(r.redMul(this.z)),a=n.redSub(i),u=o.redSub(s);if(0===a.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var f=a.redSqr(),c=f.redMul(a),h=n.redMul(f),d=u.redSqr().redIAdd(c).redISub(h).redISub(h),l=u.redMul(h.redISub(d)).redISub(o.redMul(c)),p=this.z.redMul(e.z).redMul(a);return this.curve.jpoint(d,l,p)},c.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),r=this.x,n=e.x.redMul(t),i=this.y,o=e.y.redMul(t).redMul(this.z),s=r.redSub(n),a=i.redSub(o);if(0===s.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=s.redSqr(),f=u.redMul(s),c=r.redMul(u),h=a.redSqr().redIAdd(f).redISub(c).redISub(c),d=a.redMul(c.redISub(h)).redISub(i.redMul(f)),l=this.z.redMul(s);return this.curve.jpoint(h,d,l)},c.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var t=this,r=0;r<e;r++)t=t.dbl();return t}var n=this.curve.a,i=this.curve.tinv,o=this.x,s=this.y,a=this.z,u=a.redSqr().redSqr(),f=s.redAdd(s);for(r=0;r<e;r++){var c=o.redSqr(),h=f.redSqr(),d=h.redSqr(),l=c.redAdd(c).redIAdd(c).redIAdd(n.redMul(u)),p=o.redMul(h),b=l.redSqr().redISub(p.redAdd(p)),m=p.redISub(b),y=l.redMul(m);y=y.redIAdd(y).redISub(d);var v=f.redMul(a);r+1<e&&(u=u.redMul(d)),o=b,a=v,f=y}return this.curve.jpoint(o,f.redMul(i),a)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},c.prototype._zeroDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),o=i.redSqr(),s=this.x.redAdd(i).redSqr().redISub(n).redISub(o);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n),u=a.redSqr().redISub(s).redISub(s),f=o.redIAdd(o);f=(f=f.redIAdd(f)).redIAdd(f),e=u,t=a.redMul(s.redISub(u)).redISub(f),r=this.y.redAdd(this.y)}else{var c=this.x.redSqr(),h=this.y.redSqr(),d=h.redSqr(),l=this.x.redAdd(h).redSqr().redISub(c).redISub(d);l=l.redIAdd(l);var p=c.redAdd(c).redIAdd(c),b=p.redSqr(),m=d.redIAdd(d);m=(m=m.redIAdd(m)).redIAdd(m),e=b.redISub(l).redISub(l),t=p.redMul(l.redISub(e)).redISub(m),r=(r=this.y.redMul(this.z)).redIAdd(r)}return this.curve.jpoint(e,t,r)},c.prototype._threeDbl=function(){var e,t,r;if(this.zOne){var n=this.x.redSqr(),i=this.y.redSqr(),o=i.redSqr(),s=this.x.redAdd(i).redSqr().redISub(n).redISub(o);s=s.redIAdd(s);var a=n.redAdd(n).redIAdd(n).redIAdd(this.curve.a),u=a.redSqr().redISub(s).redISub(s);e=u;var f=o.redIAdd(o);f=(f=f.redIAdd(f)).redIAdd(f),t=a.redMul(s.redISub(u)).redISub(f),r=this.y.redAdd(this.y)}else{var c=this.z.redSqr(),h=this.y.redSqr(),d=this.x.redMul(h),l=this.x.redSub(c).redMul(this.x.redAdd(c));l=l.redAdd(l).redIAdd(l);var p=d.redIAdd(d),b=(p=p.redIAdd(p)).redAdd(p);e=l.redSqr().redISub(b),r=this.y.redAdd(this.z).redSqr().redISub(h).redISub(c);var m=h.redSqr();m=(m=(m=m.redIAdd(m)).redIAdd(m)).redIAdd(m),t=l.redMul(p.redISub(e)).redISub(m)}return this.curve.jpoint(e,t,r)},c.prototype._dbl=function(){var e=this.curve.a,t=this.x,r=this.y,n=this.z,i=n.redSqr().redSqr(),o=t.redSqr(),s=r.redSqr(),a=o.redAdd(o).redIAdd(o).redIAdd(e.redMul(i)),u=t.redAdd(t),f=(u=u.redIAdd(u)).redMul(s),c=a.redSqr().redISub(f.redAdd(f)),h=f.redISub(c),d=s.redSqr();d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var l=a.redMul(h).redISub(d),p=r.redAdd(r).redMul(n);return this.curve.jpoint(c,l,p)},c.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),r=this.z.redSqr(),n=t.redSqr(),i=e.redAdd(e).redIAdd(e),o=i.redSqr(),s=this.x.redAdd(t).redSqr().redISub(e).redISub(n),a=(s=(s=(s=s.redIAdd(s)).redAdd(s).redIAdd(s)).redISub(o)).redSqr(),u=n.redIAdd(n);u=(u=(u=u.redIAdd(u)).redIAdd(u)).redIAdd(u);var f=i.redIAdd(s).redSqr().redISub(o).redISub(a).redISub(u),c=t.redMul(f);c=(c=c.redIAdd(c)).redIAdd(c);var h=this.x.redMul(a).redISub(c);h=(h=h.redIAdd(h)).redIAdd(h);var d=this.y.redMul(f.redMul(u.redISub(f)).redISub(s.redMul(a)));d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var l=this.z.redAdd(s).redSqr().redISub(r).redISub(a);return this.curve.jpoint(h,d,l)},c.prototype.mul=function(e,t){return e=new _(e,t),this.curve._wnafMul(this,e)},c.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),r=e.z.redSqr();if(0!==this.x.redMul(r).redISub(e.x.redMul(t)).cmpn(0))return!1;var n=t.redMul(this.z),i=r.redMul(e.z);return 0===this.y.redMul(i).redISub(e.y.redMul(n)).cmpn(0)},c.prototype.eqXToP=function(e){var t=this.z.redSqr(),r=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(r))return!0;for(var n=e.clone(),i=this.curve.redN.redMul(t);;){if(n.iadd(this.curve.n),0<=n.cmp(this.curve.p))return!1;if(r.redIAdd(i),0===this.x.cmp(r))return!0}return!1},c.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},c.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},{"../../elliptic":68,"../curve":71,"bn.js":"BN",inherits:103}],74:[function(e,t,r){var n,i=r,o=e("hash.js"),s=e("../elliptic"),a=s.utils.assert;function u(e){"short"===e.type?this.curve=new s.curve.short(e):"edwards"===e.type?this.curve=new s.curve.edwards(e):this.curve=new s.curve.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function f(t,r){Object.defineProperty(i,t,{configurable:!0,enumerable:!0,get:function(){var e=new u(r);return Object.defineProperty(i,t,{configurable:!0,enumerable:!0,value:e}),e}})}i.PresetCurve=u,f("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:o.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),f("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:o.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),f("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:o.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),f("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:o.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),f("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:o.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),f("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["9"]}),f("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:o.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{n=e("./precomputed/secp256k1")}catch(e){n=void 0}f("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:o.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",n]})},{"../elliptic":68,"./precomputed/secp256k1":81,"hash.js":87}],75:[function(e,t,r){var m=e("bn.js"),y=e("hmac-drbg"),o=e("../../elliptic"),l=o.utils.assert,n=e("./key"),v=e("./signature");function i(e){if(!(this instanceof i))return new i(e);"string"==typeof e&&(l(o.curves.hasOwnProperty(e),"Unknown curve "+e),e=o.curves[e]),e instanceof o.curves.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}(t.exports=i).prototype.keyPair=function(e){return new n(this,e)},i.prototype.keyFromPrivate=function(e,t){return n.fromPrivate(this,e,t)},i.prototype.keyFromPublic=function(e,t){return n.fromPublic(this,e,t)},i.prototype.genKeyPair=function(e){e||(e={});for(var t=new y({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||o.rand(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),r=this.n.byteLength(),n=this.n.sub(new m(2));;){var i=new m(t.generate(r));if(!(0<i.cmp(n)))return i.iaddn(1),this.keyFromPrivate(i)}},i.prototype._truncateToN=function(e,t){var r=8*e.byteLength()-this.n.bitLength();return 0<r&&(e=e.ushrn(r)),!t&&0<=e.cmp(this.n)?e.sub(this.n):e},i.prototype.sign=function(e,t,r,n){"object"===(void 0===r?"undefined":_typeof(r))&&(n=r,r=null),n||(n={}),t=this.keyFromPrivate(t,r),e=this._truncateToN(new m(e,16));for(var i=this.n.byteLength(),o=t.getPrivate().toArray("be",i),s=e.toArray("be",i),a=new y({hash:this.hash,entropy:o,nonce:s,pers:n.pers,persEnc:n.persEnc||"utf8"}),u=this.n.sub(new m(1)),f=0;;f++){var c=n.k?n.k(f):new m(a.generate(this.n.byteLength()));if(!((c=this._truncateToN(c,!0)).cmpn(1)<=0||0<=c.cmp(u))){var h=this.g.mul(c);if(!h.isInfinity()){var d=h.getX(),l=d.umod(this.n);if(0!==l.cmpn(0)){var p=c.invm(this.n).mul(l.mul(t.getPrivate()).iadd(e));if(0!==(p=p.umod(this.n)).cmpn(0)){var b=(h.getY().isOdd()?1:0)|(0!==d.cmp(l)?2:0);return n.canonical&&0<p.cmp(this.nh)&&(p=this.n.sub(p),b^=1),new v({r:l,s:p,recoveryParam:b})}}}}}},i.prototype.verify=function(e,t,r,n){e=this._truncateToN(new m(e,16)),r=this.keyFromPublic(r,n);var i=(t=new v(t,"hex")).r,o=t.s;if(i.cmpn(1)<0||0<=i.cmp(this.n))return!1;if(o.cmpn(1)<0||0<=o.cmp(this.n))return!1;var s,a=o.invm(this.n),u=a.mul(e).umod(this.n),f=a.mul(i).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(u,r.getPublic(),f)).isInfinity()&&s.eqXToP(i):!(s=this.g.mulAdd(u,r.getPublic(),f)).isInfinity()&&0===s.getX().umod(this.n).cmp(i)},i.prototype.recoverPubKey=function(e,t,r,n){l((3&r)===r,"The recovery param is more than two bits"),t=new v(t,n);var i=this.n,o=new m(e),s=t.r,a=t.s,u=1&r,f=r>>1;if(0<=s.cmp(this.curve.p.umod(this.curve.n))&&f)throw new Error("Unable to find sencond key candinate");s=f?this.curve.pointFromX(s.add(this.curve.n),u):this.curve.pointFromX(s,u);var c=t.r.invm(i),h=i.sub(o).mul(c).umod(i),d=a.mul(c).umod(i);return this.g.mulAdd(h,s,d)},i.prototype.getKeyRecoveryParam=function(e,t,r,n){if(null!==(t=new v(t,n)).recoveryParam)return t.recoveryParam;for(var i=0;i<4;i++){var o;try{o=this.recoverPubKey(e,t,i)}catch(e){continue}if(o.eq(r))return i}throw new Error("Unable to find valid recovery factor")}},{"../../elliptic":68,"./key":76,"./signature":77,"bn.js":"BN","hmac-drbg":99}],76:[function(e,t,r){var n=e("bn.js"),i=e("../../elliptic").utils.assert;function o(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}(t.exports=o).fromPublic=function(e,t,r){return t instanceof o?t:new o(e,{pub:t,pubEnc:r})},o.fromPrivate=function(e,t,r){return t instanceof o?t:new o(e,{priv:t,privEnc:r})},o.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},o.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},o.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},o.prototype._importPrivate=function(e,t){this.priv=new n(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},o.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?i(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||i(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},o.prototype.derive=function(e){return e.mul(this.priv).getX()},o.prototype.sign=function(e,t,r){return this.ec.sign(e,this,t,r)},o.prototype.verify=function(e,t){return this.ec.verify(e,t,this)},o.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}},{"../../elliptic":68,"bn.js":"BN"}],77:[function(e,t,r){var a=e("bn.js"),u=e("../../elliptic").utils,n=u.assert;function i(e,t){if(e instanceof i)return e;this._importDER(e,t)||(n(e.r&&e.s,"Signature without r or s"),this.r=new a(e.r,16),this.s=new a(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function f(){this.place=0}function c(e,t){var r=e[t.place++];if(!(128&r))return r;for(var n=15&r,i=0,o=0,s=t.place;o<n;o++,s++)i<<=8,i|=e[s];return t.place=s,i}function s(e){for(var t=0,r=e.length-1;!e[t]&&!(128&e[t+1])&&t<r;)t++;return 0===t?e:e.slice(t)}function h(e,t){if(t<128)e.push(t);else{var r=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|r);--r;)e.push(t>>>(r<<3)&255);e.push(t)}}(t.exports=i).prototype._importDER=function(e,t){e=u.toArray(e,t);var r=new f;if(48!==e[r.place++])return!1;if(c(e,r)+r.place!==e.length)return!1;if(2!==e[r.place++])return!1;var n=c(e,r),i=e.slice(r.place,n+r.place);if(r.place+=n,2!==e[r.place++])return!1;var o=c(e,r);if(e.length!==o+r.place)return!1;var s=e.slice(r.place,o+r.place);return 0===i[0]&&128&i[1]&&(i=i.slice(1)),0===s[0]&&128&s[1]&&(s=s.slice(1)),this.r=new a(i),this.s=new a(s),!(this.recoveryParam=null)},i.prototype.toDER=function(e){var t=this.r.toArray(),r=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&r[0]&&(r=[0].concat(r)),t=s(t),r=s(r);!(r[0]||128&r[1]);)r=r.slice(1);var n=[2];h(n,t.length),(n=n.concat(t)).push(2),h(n,r.length);var i=n.concat(r),o=[48];return h(o,i.length),o=o.concat(i),u.encode(o,e)}},{"../../elliptic":68,"bn.js":"BN"}],78:[function(e,t,r){var n=e("hash.js"),i=e("../../elliptic"),o=i.utils,s=o.assert,u=o.parseBytes,a=e("./key"),f=e("./signature");function c(e){if(s("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof c))return new c(e);e=i.curves[e].curve;this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=n.sha512}(t.exports=c).prototype.sign=function(e,t){e=u(e);var r=this.keyFromSecret(t),n=this.hashInt(r.messagePrefix(),e),i=this.g.mul(n),o=this.encodePoint(i),s=this.hashInt(o,r.pubBytes(),e).mul(r.priv()),a=n.add(s).umod(this.curve.n);return this.makeSignature({R:i,S:a,Rencoded:o})},c.prototype.verify=function(e,t,r){e=u(e),t=this.makeSignature(t);var n=this.keyFromPublic(r),i=this.hashInt(t.Rencoded(),n.pubBytes(),e),o=this.g.mul(t.S());return t.R().add(n.pub().mul(i)).eq(o)},c.prototype.hashInt=function(){for(var e=this.hash(),t=0;t<arguments.length;t++)e.update(arguments[t]);return o.intFromLE(e.digest()).umod(this.curve.n)},c.prototype.keyFromPublic=function(e){return a.fromPublic(this,e)},c.prototype.keyFromSecret=function(e){return a.fromSecret(this,e)},c.prototype.makeSignature=function(e){return e instanceof f?e:new f(this,e)},c.prototype.encodePoint=function(e){var t=e.getY().toArray("le",this.encodingLength);return t[this.encodingLength-1]|=e.getX().isOdd()?128:0,t},c.prototype.decodePoint=function(e){var t=(e=o.parseBytes(e)).length-1,r=e.slice(0,t).concat(-129&e[t]),n=0!=(128&e[t]),i=o.intFromLE(r);return this.curve.pointFromY(i,n)},c.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},c.prototype.decodeInt=function(e){return o.intFromLE(e)},c.prototype.isPoint=function(e){return e instanceof this.pointClass}},{"../../elliptic":68,"./key":79,"./signature":80,"hash.js":87}],79:[function(e,t,r){var n=e("../../elliptic").utils,i=n.assert,o=n.parseBytes,s=n.cachedProperty;function a(e,t){this.eddsa=e,this._secret=o(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=o(t.pub)}a.fromPublic=function(e,t){return t instanceof a?t:new a(e,{pub:t})},a.fromSecret=function(e,t){return t instanceof a?t:new a(e,{secret:t})},a.prototype.secret=function(){return this._secret},s(a,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),s(a,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),s(a,"privBytes",function(){var e=this.eddsa,t=this.hash(),r=e.encodingLength-1,n=t.slice(0,e.encodingLength);return n[0]&=248,n[r]&=127,n[r]|=64,n}),s(a,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),s(a,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),s(a,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),a.prototype.sign=function(e){return i(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},a.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},a.prototype.getSecret=function(e){return i(this._secret,"KeyPair is public only"),n.encode(this.secret(),e)},a.prototype.getPublic=function(e){return n.encode(this.pubBytes(),e)},t.exports=a},{"../../elliptic":68}],80:[function(e,t,r){var n=e("bn.js"),i=e("../../elliptic").utils,o=i.assert,s=i.cachedProperty,a=i.parseBytes;function u(e,t){this.eddsa=e,"object"!==(void 0===t?"undefined":_typeof(t))&&(t=a(t)),Array.isArray(t)&&(t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),o(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof n&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}s(u,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),s(u,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),s(u,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),s(u,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),u.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},u.prototype.toHex=function(){return i.encode(this.toBytes(),"hex").toUpperCase()},t.exports=u},{"../../elliptic":68,"bn.js":"BN"}],81:[function(e,t,r){t.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},{}],82:[function(e,t,r){var n=r,i=e("bn.js"),o=e("minimalistic-assert"),s=e("minimalistic-crypto-utils");n.assert=o,n.toArray=s.toArray,n.zero2=s.zero2,n.toHex=s.toHex,n.encode=s.encode,n.getNAF=function(e,t){for(var r=[],n=1<<t+1,i=e.clone();0<=i.cmpn(1);){var o;if(i.isOdd()){var s=i.andln(n-1);o=(n>>1)-1<s?(n>>1)-s:s,i.isubn(o)}else o=0;r.push(o);for(var a=0!==i.cmpn(0)&&0===i.andln(n-1)?t+1:1,u=1;u<a;u++)r.push(0);i.iushrn(a)}return r},n.getJSF=function(e,t){var r=[[],[]];e=e.clone(),t=t.clone();for(var n=0,i=0;0<e.cmpn(-n)||0<t.cmpn(-i);){var o,s,a,u=e.andln(3)+n&3,f=t.andln(3)+i&3;3===u&&(u=-1),3===f&&(f=-1),o=0==(1&u)?0:3!=(a=e.andln(7)+n&7)&&5!==a||2!==f?u:-u,r[0].push(o),s=0==(1&f)?0:3!=(a=t.andln(7)+i&7)&&5!==a||2!==u?f:-f,r[1].push(s),2*n===o+1&&(n=1-n),2*i===s+1&&(i=1-i),e.iushrn(1),t.iushrn(1)}return r},n.cachedProperty=function(e,t,r){var n="_"+t;e.prototype[t]=function(){return void 0!==this[n]?this[n]:this[n]=r.call(this)}},n.parseBytes=function(e){return"string"==typeof e?n.toArray(e,"hex"):e},n.intFromLE=function(e){return new i(e,"hex","le")}},{"bn.js":"BN","minimalistic-assert":108,"minimalistic-crypto-utils":109}],83:[function(e,t,r){t.exports={_from:"elliptic@^6.0.0",_id:"elliptic@6.4.0",_inBundle:!1,_integrity:"sha1-ysmvh2LIWDYYcAPI3+GT5eLq5d8=",_location:"/elliptic",_phantomChildren:{},_requested:{type:"range",registry:!0,raw:"elliptic@^6.0.0",name:"elliptic",escapedName:"elliptic",rawSpec:"^6.0.0",saveSpec:null,fetchSpec:"^6.0.0"},_requiredBy:["/browserify-sign","/create-ecdh"],_resolved:"https://registry.npmjs.org/elliptic/-/elliptic-6.4.0.tgz",_shasum:"cac9af8762c85836187003c8dfe193e5e2eae5df",_spec:"elliptic@^6.0.0",_where:"/Users/frozeman/Sites/_ethereum/web3/node_modules/browserify-sign",author:{name:"Fedor Indutny",email:"fedor@indutny.com"},bugs:{url:"https://github.com/indutny/elliptic/issues"},bundleDependencies:!1,dependencies:{"bn.js":"^4.4.0",brorand:"^1.0.1","hash.js":"^1.0.0","hmac-drbg":"^1.0.0",inherits:"^2.0.1","minimalistic-assert":"^1.0.0","minimalistic-crypto-utils":"^1.0.0"},deprecated:!1,description:"EC cryptography",devDependencies:{brfs:"^1.4.3",coveralls:"^2.11.3",grunt:"^0.4.5","grunt-browserify":"^5.0.0","grunt-cli":"^1.2.0","grunt-contrib-connect":"^1.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^1.0.1","grunt-mocha-istanbul":"^3.0.1","grunt-saucelabs":"^8.6.2",istanbul:"^0.4.2",jscs:"^2.9.0",jshint:"^2.6.0",mocha:"^2.1.0"},files:["lib"],homepage:"https://github.com/indutny/elliptic",keywords:["EC","Elliptic","curve","Cryptography"],license:"MIT",main:"lib/elliptic.js",name:"elliptic",repository:{type:"git",url:"git+ssh://git@github.com/indutny/elliptic.git"},scripts:{jscs:"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js",jshint:"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js",lint:"npm run jscs && npm run jshint",test:"npm run lint && npm run unit",unit:"istanbul test _mocha --reporter=spec test/index.js",version:"grunt dist && git add dist/"},version:"6.4.0"}},{}],84:[function(e,t,r){function n(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0}function u(e){return"function"==typeof e}function f(e){return"object"===(void 0===e?"undefined":_typeof(e))&&null!==e}function c(e){return void 0===e}((t.exports=n).EventEmitter=n).prototype._events=void 0,n.prototype._maxListeners=void 0,n.defaultMaxListeners=10,n.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},n.prototype.emit=function(e){var t,r,n,i,o,s;if(this._events||(this._events={}),"error"===e&&(!this._events.error||f(this._events.error)&&!this._events.error.length)){if((t=arguments[1])instanceof Error)throw t;var a=new Error('Uncaught, unspecified "error" event. ('+t+")");throw a.context=t,a}if(c(r=this._events[e]))return!1;if(u(r))switch(arguments.length){case 1:r.call(this);break;case 2:r.call(this,arguments[1]);break;case 3:r.call(this,arguments[1],arguments[2]);break;default:i=Array.prototype.slice.call(arguments,1),r.apply(this,i)}else if(f(r))for(i=Array.prototype.slice.call(arguments,1),n=(s=r.slice()).length,o=0;o<n;o++)s[o].apply(this,i);return!0},n.prototype.on=n.prototype.addListener=function(e,t){var r;if(!u(t))throw TypeError("listener must be a function");return this._events||(this._events={}),this._events.newListener&&this.emit("newListener",e,u(t.listener)?t.listener:t),this._events[e]?f(this._events[e])?this._events[e].push(t):this._events[e]=[this._events[e],t]:this._events[e]=t,f(this._events[e])&&!this._events[e].warned&&(r=c(this._maxListeners)?n.defaultMaxListeners:this._maxListeners)&&0<r&&this._events[e].length>r&&(this._events[e].warned=!0,console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),"function"==typeof console.trace&&console.trace()),this},n.prototype.once=function(e,t){if(!u(t))throw TypeError("listener must be a function");var r=!1;function n(){this.removeListener(e,n),r||(r=!0,t.apply(this,arguments))}return n.listener=t,this.on(e,n),this},n.prototype.removeListener=function(e,t){var r,n,i,o;if(!u(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(i=(r=this._events[e]).length,n=-1,r===t||u(r.listener)&&r.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(f(r)){for(o=i;0<o--;)if(r[o]===t||r[o].listener&&r[o].listener===t){n=o;break}if(n<0)return this;1===r.length?(r.length=0,delete this._events[e]):r.splice(n,1),this._events.removeListener&&this.emit("removeListener",e,t)}return this},n.prototype.removeAllListeners=function(e){var t,r;if(!this._events)return this;if(!this._events.removeListener)return 0===arguments.length?this._events={}:this._events[e]&&delete this._events[e],this;if(0===arguments.length){for(t in this._events)"removeListener"!==t&&this.removeAllListeners(t);return this.removeAllListeners("removeListener"),this._events={},this}if(u(r=this._events[e]))this.removeListener(e,r);else if(r)for(;r.length;)this.removeListener(e,r[r.length-1]);return delete this._events[e],this},n.prototype.listeners=function(e){return this._events&&this._events[e]?u(this._events[e])?[this._events[e]]:this._events[e].slice():[]},n.prototype.listenerCount=function(e){if(this._events){var t=this._events[e];if(u(t))return 1;if(t)return t.length}return 0},n.listenerCount=function(e,t){return e.listenerCount(t)}},{}],85:[function(e,t,r){var l=e("safe-buffer").Buffer,p=e("md5.js");t.exports=function(e,t,r,n){if(l.isBuffer(e)||(e=l.from(e,"binary")),t&&(l.isBuffer(t)||(t=l.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var i=r/8,o=l.alloc(i),s=l.alloc(n||0),a=l.alloc(0);0<i||0<n;){var u=new p;u.update(a),u.update(e),t&&u.update(t),a=u.digest();var f=0;if(0<i){var c=o.length-i;f=Math.min(i,a.length),a.copy(o,c,0,f),i-=f}if(f<a.length&&0<n){var h=s.length-n,d=Math.min(n,a.length-f);a.copy(s,h,f,f+d),n-=d}}return a.fill(0),{key:o,iv:s}}},{"md5.js":106,"safe-buffer":149}],86:[function(e,t,r){var a=e("safe-buffer").Buffer,n=e("stream").Transform;function i(e){n.call(this),this._block=a.allocUnsafe(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}e("inherits")(i,n),i.prototype._transform=function(e,t,r){var n=null;try{this.update(e,t)}catch(e){n=e}r(n)},i.prototype._flush=function(e){var t=null;try{this.push(this.digest())}catch(e){t=e}e(t)},i.prototype.update=function(e,t){if(function(e,t){if(!a.isBuffer(e)&&"string"!=typeof e)throw new TypeError(t+" must be a string or a buffer")}(e,"Data"),this._finalized)throw new Error("Digest already called");a.isBuffer(e)||(e=a.from(e,t));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var i=this._blockOffset;i<this._blockSize;)r[i++]=e[n++];this._update(),this._blockOffset=0}for(;n<e.length;)r[this._blockOffset++]=e[n++];for(var o=0,s=8*e.length;0<s;++o)this._length[o]+=s,0<(s=this._length[o]/4294967296|0)&&(this._length[o]-=4294967296*s);return this},i.prototype._update=function(){throw new Error("_update is not implemented")},i.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);for(var r=this._blockOffset=0;r<4;++r)this._length[r]=0;return t},i.prototype._digest=function(){throw new Error("_digest is not implemented")},t.exports=i},{inherits:103,"safe-buffer":149,stream:158}],87:[function(e,t,r){var n=r;n.utils=e("./hash/utils"),n.common=e("./hash/common"),n.sha=e("./hash/sha"),n.ripemd=e("./hash/ripemd"),n.hmac=e("./hash/hmac"),n.sha1=n.sha.sha1,n.sha256=n.sha.sha256,n.sha224=n.sha.sha224,n.sha384=n.sha.sha384,n.sha512=n.sha.sha512,n.ripemd160=n.ripemd.ripemd160},{"./hash/common":88,"./hash/hmac":89,"./hash/ripemd":90,"./hash/sha":91,"./hash/utils":98}],88:[function(e,t,r){var i=e("./utils"),n=e("minimalistic-assert");function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}(r.BlockHash=o).prototype.update=function(e,t){if(e=i.toArray(e,t),this.pending?this.pending=this.pending.concat(e):this.pending=e,this.pendingTotal+=e.length,this.pending.length>=this._delta8){var r=(e=this.pending).length%this._delta8;this.pending=e.slice(e.length-r,e.length),0===this.pending.length&&(this.pending=null),e=i.join32(e,0,e.length-r,this.endian);for(var n=0;n<e.length;n+=this._delta32)this._update(e,n,n+this._delta32)}return this},o.prototype.digest=function(e){return this.update(this._pad()),n(null===this.pending),this._digest(e)},o.prototype._pad=function(){var e=this.pendingTotal,t=this._delta8,r=t-(e+this.padLength)%t,n=new Array(r+this.padLength);n[0]=128;for(var i=1;i<r;i++)n[i]=0;if(e<<=3,"big"===this.endian){for(var o=8;o<this.padLength;o++)n[i++]=0;n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=e>>>24&255,n[i++]=e>>>16&255,n[i++]=e>>>8&255,n[i++]=255&e}else for(n[i++]=255&e,n[i++]=e>>>8&255,n[i++]=e>>>16&255,n[i++]=e>>>24&255,n[i++]=0,n[i++]=0,n[i++]=0,n[i++]=0,o=8;o<this.padLength;o++)n[i++]=0;return n}},{"./utils":98,"minimalistic-assert":108}],89:[function(e,t,r){var n=e("./utils"),i=e("minimalistic-assert");function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);this.Hash=e,this.blockSize=e.blockSize/8,this.outSize=e.outSize/8,this.inner=null,this.outer=null,this._init(n.toArray(t,r))}(t.exports=o).prototype._init=function(e){e.length>this.blockSize&&(e=(new this.Hash).update(e).digest()),i(e.length<=this.blockSize);for(var t=e.length;t<this.blockSize;t++)e.push(0);for(t=0;t<e.length;t++)e[t]^=54;for(this.inner=(new this.Hash).update(e),t=0;t<e.length;t++)e[t]^=106;this.outer=(new this.Hash).update(e)},o.prototype.update=function(e,t){return this.inner.update(e,t),this},o.prototype.digest=function(e){return this.outer.update(this.inner.digest()),this.outer.digest(e)}},{"./utils":98,"minimalistic-assert":108}],90:[function(e,t,r){var n=e("./utils"),i=e("./common"),p=n.rotl32,b=n.sum32,m=n.sum32_3,y=n.sum32_4,o=i.BlockHash;function s(){if(!(this instanceof s))return new s;o.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function v(e,t,r,n){return e<=15?t^r^n:e<=31?t&r|~t&n:e<=47?(t|~r)^n:e<=63?t&n|r&~n:t^(r|~n)}function g(e){return e<=15?0:e<=31?1518500249:e<=47?1859775393:e<=63?2400959708:2840853838}function w(e){return e<=15?1352829926:e<=31?1548603684:e<=47?1836072691:e<=63?2053994217:0}n.inherits(s,o),(r.ripemd160=s).blockSize=512,s.outSize=160,s.hmacStrength=192,s.padLength=64,s.prototype._update=function(e,t){for(var r=this.h[0],n=this.h[1],i=this.h[2],o=this.h[3],s=this.h[4],a=r,u=n,f=i,c=o,h=s,d=0;d<80;d++){var l=b(p(y(r,v(d,n,i,o),e[_[d]+t],g(d)),x[d]),s);r=s,s=o,o=p(i,10),i=n,n=l,l=b(p(y(a,v(79-d,u,f,c),e[M[d]+t],w(d)),k[d]),h),a=h,h=c,c=p(f,10),f=u,u=l}l=m(this.h[1],i,c),this.h[1]=m(this.h[2],o,h),this.h[2]=m(this.h[3],s,a),this.h[3]=m(this.h[4],r,u),this.h[4]=m(this.h[0],n,f),this.h[0]=l},s.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"little"):n.split32(this.h,"little")};var _=[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],M=[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],x=[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],k=[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]},{"./common":88,"./utils":98}],91:[function(e,t,r){r.sha1=e("./sha/1"),r.sha224=e("./sha/224"),r.sha256=e("./sha/256"),r.sha384=e("./sha/384"),r.sha512=e("./sha/512")},{"./sha/1":92,"./sha/224":93,"./sha/256":94,"./sha/384":95,"./sha/512":96}],92:[function(e,t,r){var n=e("../utils"),i=e("../common"),o=e("./common"),h=n.rotl32,d=n.sum32,l=n.sum32_5,p=o.ft_1,s=i.BlockHash,b=[1518500249,1859775393,2400959708,3395469782];function a(){if(!(this instanceof a))return new a;s.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}n.inherits(a,s),(t.exports=a).blockSize=512,a.outSize=160,a.hmacStrength=80,a.padLength=64,a.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=h(r[n-3]^r[n-8]^r[n-14]^r[n-16],1);var i=this.h[0],o=this.h[1],s=this.h[2],a=this.h[3],u=this.h[4];for(n=0;n<r.length;n++){var f=~~(n/20),c=l(h(i,5),p(f,o,s,a),u,r[n],b[f]);u=a,a=s,s=h(o,30),o=i,i=c}this.h[0]=d(this.h[0],i),this.h[1]=d(this.h[1],o),this.h[2]=d(this.h[2],s),this.h[3]=d(this.h[3],a),this.h[4]=d(this.h[4],u)},a.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},{"../common":88,"../utils":98,"./common":97}],93:[function(e,t,r){var n=e("../utils"),i=e("./256");function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}n.inherits(o,i),(t.exports=o).blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,7),"big"):n.split32(this.h.slice(0,7),"big")}},{"../utils":98,"./256":94}],94:[function(e,t,r){var n=e("../utils"),i=e("../common"),o=e("./common"),p=e("minimalistic-assert"),b=n.sum32,m=n.sum32_4,y=n.sum32_5,v=o.ch32,g=o.maj32,w=o.s0_256,_=o.s1_256,M=o.g0_256,x=o.g1_256,s=i.BlockHash,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];function u(){if(!(this instanceof u))return new u;s.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=a,this.W=new Array(64)}n.inherits(u,s),(t.exports=u).blockSize=512,u.outSize=256,u.hmacStrength=192,u.padLength=64,u.prototype._update=function(e,t){for(var r=this.W,n=0;n<16;n++)r[n]=e[t+n];for(;n<r.length;n++)r[n]=m(x(r[n-2]),r[n-7],M(r[n-15]),r[n-16]);var i=this.h[0],o=this.h[1],s=this.h[2],a=this.h[3],u=this.h[4],f=this.h[5],c=this.h[6],h=this.h[7];for(p(this.k.length===r.length),n=0;n<r.length;n++){var d=y(h,_(u),v(u,f,c),this.k[n],r[n]),l=b(w(i),g(i,o,s));h=c,c=f,f=u,u=b(a,d),a=s,s=o,o=i,i=b(d,l)}this.h[0]=b(this.h[0],i),this.h[1]=b(this.h[1],o),this.h[2]=b(this.h[2],s),this.h[3]=b(this.h[3],a),this.h[4]=b(this.h[4],u),this.h[5]=b(this.h[5],f),this.h[6]=b(this.h[6],c),this.h[7]=b(this.h[7],h)},u.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},{"../common":88,"../utils":98,"./common":97,"minimalistic-assert":108}],95:[function(e,t,r){var n=e("../utils"),i=e("./512");function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}n.inherits(o,i),(t.exports=o).blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h.slice(0,12),"big"):n.split32(this.h.slice(0,12),"big")}},{"../utils":98,"./512":96}],96:[function(e,t,r){var n=e("../utils"),i=e("../common"),R=e("minimalistic-assert"),o=n.rotr64_hi,s=n.rotr64_lo,a=n.shr64_hi,u=n.shr64_lo,O=n.sum64,N=n.sum64_hi,L=n.sum64_lo,d=n.sum64_4_hi,l=n.sum64_4_lo,q=n.sum64_5_hi,D=n.sum64_5_lo,f=i.BlockHash,c=[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 h(){if(!(this instanceof h))return new h;f.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=c,this.W=new Array(160)}function F(e,t,r,n,i){var o=e&r^~e&i;return o<0&&(o+=4294967296),o}function U(e,t,r,n,i,o){var s=t&n^~t&o;return s<0&&(s+=4294967296),s}function H(e,t,r,n,i){var o=e&r^e&i^r&i;return o<0&&(o+=4294967296),o}function z(e,t,r,n,i,o){var s=t&n^t&o^n&o;return s<0&&(s+=4294967296),s}function K(e,t){var r=o(e,t,28)^o(t,e,2)^o(t,e,7);return r<0&&(r+=4294967296),r}function W(e,t){var r=s(e,t,28)^s(t,e,2)^s(t,e,7);return r<0&&(r+=4294967296),r}function V(e,t){var r=o(e,t,14)^o(e,t,18)^o(t,e,9);return r<0&&(r+=4294967296),r}function X(e,t){var r=s(e,t,14)^s(e,t,18)^s(t,e,9);return r<0&&(r+=4294967296),r}function p(e,t){var r=o(e,t,1)^o(e,t,8)^a(e,t,7);return r<0&&(r+=4294967296),r}function b(e,t){var r=s(e,t,1)^s(e,t,8)^u(e,t,7);return r<0&&(r+=4294967296),r}function m(e,t){var r=o(e,t,19)^o(t,e,29)^a(e,t,6);return r<0&&(r+=4294967296),r}function y(e,t){var r=s(e,t,19)^s(t,e,29)^u(e,t,6);return r<0&&(r+=4294967296),r}n.inherits(h,f),(t.exports=h).blockSize=1024,h.outSize=512,h.hmacStrength=192,h.padLength=128,h.prototype._prepareBlock=function(e,t){for(var r=this.W,n=0;n<32;n++)r[n]=e[t+n];for(;n<r.length;n+=2){var i=m(r[n-4],r[n-3]),o=y(r[n-4],r[n-3]),s=r[n-14],a=r[n-13],u=p(r[n-30],r[n-29]),f=b(r[n-30],r[n-29]),c=r[n-32],h=r[n-31];r[n]=d(i,o,s,a,u,f,c,h),r[n+1]=l(i,o,s,a,u,f,c,h)}},h.prototype._update=function(e,t){this._prepareBlock(e,t);var r=this.W,n=this.h[0],i=this.h[1],o=this.h[2],s=this.h[3],a=this.h[4],u=this.h[5],f=this.h[6],c=this.h[7],h=this.h[8],d=this.h[9],l=this.h[10],p=this.h[11],b=this.h[12],m=this.h[13],y=this.h[14],v=this.h[15];R(this.k.length===r.length);for(var g=0;g<r.length;g+=2){var w=y,_=v,M=V(h,d),x=X(h,d),k=F(h,d,l,p,b),S=U(h,d,l,p,b,m),E=this.k[g],A=this.k[g+1],j=r[g],I=r[g+1],B=q(w,_,M,x,k,S,E,A,j,I),T=D(w,_,M,x,k,S,E,A,j,I);w=K(n,i),_=W(n,i),M=H(n,i,o,s,a),x=z(n,i,o,s,a,u);var C=N(w,_,M,x),P=L(w,_,M,x);y=b,v=m,b=l,m=p,l=h,p=d,h=N(f,c,B,T),d=L(c,c,B,T),f=a,c=u,a=o,u=s,o=n,s=i,n=N(B,T,C,P),i=L(B,T,C,P)}O(this.h,0,n,i),O(this.h,2,o,s),O(this.h,4,a,u),O(this.h,6,f,c),O(this.h,8,h,d),O(this.h,10,l,p),O(this.h,12,b,m),O(this.h,14,y,v)},h.prototype._digest=function(e){return"hex"===e?n.toHex32(this.h,"big"):n.split32(this.h,"big")}},{"../common":88,"../utils":98,"minimalistic-assert":108}],97:[function(e,t,r){var n=e("../utils").rotr32;function i(e,t,r){return e&t^~e&r}function o(e,t,r){return e&t^e&r^t&r}function s(e,t,r){return e^t^r}r.ft_1=function(e,t,r,n){return 0===e?i(t,r,n):1===e||3===e?s(t,r,n):2===e?o(t,r,n):void 0},r.ch32=i,r.maj32=o,r.p32=s,r.s0_256=function(e){return n(e,2)^n(e,13)^n(e,22)},r.s1_256=function(e){return n(e,6)^n(e,11)^n(e,25)},r.g0_256=function(e){return n(e,7)^n(e,18)^e>>>3},r.g1_256=function(e){return n(e,17)^n(e,19)^e>>>10}},{"../utils":98}],98:[function(e,t,r){var f=e("minimalistic-assert"),n=e("inherits");function o(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function i(e){return 1===e.length?"0"+e:e}function s(e){return 7===e.length?"0"+e:6===e.length?"00"+e:5===e.length?"000"+e:4===e.length?"0000"+e:3===e.length?"00000"+e:2===e.length?"000000"+e:1===e.length?"0000000"+e:e}r.inherits=n,r.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"==typeof e)if(t){if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16))}else for(var n=0;n<e.length;n++){var i=e.charCodeAt(n),o=i>>8,s=255&i;o?r.push(o,s):r.push(s)}else for(n=0;n<e.length;n++)r[n]=0|e[n];return r},r.toHex=function(e){for(var t="",r=0;r<e.length;r++)t+=i(e[r].toString(16));return t},r.htonl=o,r.toHex32=function(e,t){for(var r="",n=0;n<e.length;n++){var i=e[n];"little"===t&&(i=o(i)),r+=s(i.toString(16))}return r},r.zero2=i,r.zero8=s,r.join32=function(e,t,r,n){var i=r-t;f(i%4==0);for(var o=new Array(i/4),s=0,a=t;s<o.length;s++,a+=4){var u;u="big"===n?e[a]<<24|e[a+1]<<16|e[a+2]<<8|e[a+3]:e[a+3]<<24|e[a+2]<<16|e[a+1]<<8|e[a],o[s]=u>>>0}return o},r.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n<e.length;n++,i+=4){var o=e[n];"big"===t?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},r.rotr32=function(e,t){return e>>>t|e<<32-t},r.rotl32=function(e,t){return e<<t|e>>>32-t},r.sum32=function(e,t){return e+t>>>0},r.sum32_3=function(e,t,r){return e+t+r>>>0},r.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},r.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},r.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,s=(o<n?1:0)+r+i;e[t]=s>>>0,e[t+1]=o},r.sum64_hi=function(e,t,r,n){return(t+n>>>0<t?1:0)+e+r>>>0},r.sum64_lo=function(e,t,r,n){return t+n>>>0},r.sum64_4_hi=function(e,t,r,n,i,o,s,a){var u=0,f=t;return u+=(f=f+n>>>0)<t?1:0,u+=(f=f+o>>>0)<o?1:0,e+r+i+s+(u+=(f=f+a>>>0)<a?1:0)>>>0},r.sum64_4_lo=function(e,t,r,n,i,o,s,a){return t+n+o+a>>>0},r.sum64_5_hi=function(e,t,r,n,i,o,s,a,u,f){var c=0,h=t;return c+=(h=h+n>>>0)<t?1:0,c+=(h=h+o>>>0)<o?1:0,c+=(h=h+a>>>0)<a?1:0,e+r+i+s+u+(c+=(h=h+f>>>0)<f?1:0)>>>0},r.sum64_5_lo=function(e,t,r,n,i,o,s,a,u,f){return t+n+o+a+f>>>0},r.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},r.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},r.shr64_hi=function(e,t,r){return e>>>r},r.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},{inherits:103,"minimalistic-assert":108}],99:[function(e,t,r){var n=e("hash.js"),s=e("minimalistic-crypto-utils"),i=e("minimalistic-assert");function o(e){if(!(this instanceof o))return new o(e);this.hash=e.hash,this.predResist=!!e.predResist,this.outLen=this.hash.outSize,this.minEntropy=e.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var t=s.toArray(e.entropy,e.entropyEnc||"hex"),r=s.toArray(e.nonce,e.nonceEnc||"hex"),n=s.toArray(e.pers,e.persEnc||"hex");i(t.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(t,r,n)}(t.exports=o).prototype._init=function(e,t,r){var n=e.concat(t).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var i=0;i<this.V.length;i++)this.K[i]=0,this.V[i]=1;this._update(n),this._reseed=1,this.reseedInterval=281474976710656},o.prototype._hmac=function(){return new n.hmac(this.hash,this.K)},o.prototype._update=function(e){var t=this._hmac().update(this.V).update([0]);e&&(t=t.update(e)),this.K=t.digest(),this.V=this._hmac().update(this.V).digest(),e&&(this.K=this._hmac().update(this.V).update([1]).update(e).digest(),this.V=this._hmac().update(this.V).digest())},o.prototype.reseed=function(e,t,r,n){"string"!=typeof t&&(n=r,r=t,t=null),e=s.toArray(e,t),r=s.toArray(r,n),i(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(e.concat(r||[])),this._reseed=1},o.prototype.generate=function(e,t,r,n){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!=typeof t&&(n=r,r=t,t=null),r&&(r=s.toArray(r,n||"hex"),this._update(r));for(var i=[];i.length<e;)this.V=this._hmac().update(this.V).digest(),i=i.concat(this.V);var o=i.slice(0,e);return this._update(r),this._reseed++,s.encode(o,t)}},{"hash.js":87,"minimalistic-assert":108,"minimalistic-crypto-utils":109}],100:[function(e,t,r){var n=e("http"),i=e("url"),o=t.exports;for(var s in n)n.hasOwnProperty(s)&&(o[s]=n[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),n.request.call(this,e,t)},o.get=function(e,t){return e=a(e),n.get.call(this,e,t)}},{http:159,url:166}],101:[function(e,t,r){r.read=function(e,t,r,n,i){var o,s,a=8*i-n-1,u=(1<<a)-1,f=u>>1,c=-7,h=r?i-1:0,d=r?-1:1,l=e[t+h];for(h+=d,o=l&(1<<-c)-1,l>>=-c,c+=a;0<c;o=256*o+e[t+h],h+=d,c-=8);for(s=o&(1<<-c)-1,o>>=-c,c+=n;0<c;s=256*s+e[t+h],h+=d,c-=8);if(0===o)o=1-f;else{if(o===u)return s?NaN:1/0*(l?-1:1);s+=Math.pow(2,n),o-=f}return(l?-1:1)*s*Math.pow(2,o-n)},r.write=function(e,t,r,n,i,o){var s,a,u,f=8*o-i-1,c=(1<<f)-1,h=c>>1,d=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,l=n?0:o-1,p=n?1:-1,b=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*(u=Math.pow(2,-s))<1&&(s--,u*=2),2<=(t+=1<=s+h?d/u:d*Math.pow(2,1-h))*u&&(s++,u/=2),c<=s+h?(a=0,s=c):1<=s+h?(a=(t*u-1)*Math.pow(2,i),s+=h):(a=t*Math.pow(2,h-1)*Math.pow(2,i),s=0));8<=i;e[r+l]=255&a,l+=p,a/=256,i-=8);for(s=s<<i|a,f+=i;0<f;e[r+l]=255&s,l+=p,s/=256,f-=8);e[r+l-p]|=128*b}},{}],102:[function(e,t,r){var n=[].indexOf;t.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}},{}],103:[function(e,t,r){"function"==typeof Object.create?t.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}},{}],104:[function(e,t,r){function n(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}t.exports=function(e){return null!=e&&(n(e)||"function"==typeof(t=e).readFloatLE&&"function"==typeof t.slice&&n(t.slice(0,0))||!!e._isBuffer);var t}},{}],105:[function(e,t,r){var n={}.toString;t.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},{}],106:[function(i,o,e){(function(t){var e=i("inherits"),r=i("hash-base"),s=new Array(16);function n(){r.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function a(e,t){return e<<t|e>>>32-t}function u(e,t,r,n,i,o,s){return a(e+(t&r|~t&n)+i+o|0,s)+t|0}function f(e,t,r,n,i,o,s){return a(e+(t&n|r&~n)+i+o|0,s)+t|0}function c(e,t,r,n,i,o,s){return a(e+(t^r^n)+i+o|0,s)+t|0}function h(e,t,r,n,i,o,s){return a(e+(r^(t|~n))+i+o|0,s)+t|0}e(n,r),n.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;n=h(n=h(n=h(n=h(n=c(n=c(n=c(n=c(n=f(n=f(n=f(n=f(n=u(n=u(n=u(n=u(n,i=u(i,o=u(o,r=u(r,n,i,o,e[0],3614090360,7),n,i,e[1],3905402710,12),r,n,e[2],606105819,17),o,r,e[3],3250441966,22),i=u(i,o=u(o,r=u(r,n,i,o,e[4],4118548399,7),n,i,e[5],1200080426,12),r,n,e[6],2821735955,17),o,r,e[7],4249261313,22),i=u(i,o=u(o,r=u(r,n,i,o,e[8],1770035416,7),n,i,e[9],2336552879,12),r,n,e[10],4294925233,17),o,r,e[11],2304563134,22),i=u(i,o=u(o,r=u(r,n,i,o,e[12],1804603682,7),n,i,e[13],4254626195,12),r,n,e[14],2792965006,17),o,r,e[15],1236535329,22),i=f(i,o=f(o,r=f(r,n,i,o,e[1],4129170786,5),n,i,e[6],3225465664,9),r,n,e[11],643717713,14),o,r,e[0],3921069994,20),i=f(i,o=f(o,r=f(r,n,i,o,e[5],3593408605,5),n,i,e[10],38016083,9),r,n,e[15],3634488961,14),o,r,e[4],3889429448,20),i=f(i,o=f(o,r=f(r,n,i,o,e[9],568446438,5),n,i,e[14],3275163606,9),r,n,e[3],4107603335,14),o,r,e[8],1163531501,20),i=f(i,o=f(o,r=f(r,n,i,o,e[13],2850285829,5),n,i,e[2],4243563512,9),r,n,e[7],1735328473,14),o,r,e[12],2368359562,20),i=c(i,o=c(o,r=c(r,n,i,o,e[5],4294588738,4),n,i,e[8],2272392833,11),r,n,e[11],1839030562,16),o,r,e[14],4259657740,23),i=c(i,o=c(o,r=c(r,n,i,o,e[1],2763975236,4),n,i,e[4],1272893353,11),r,n,e[7],4139469664,16),o,r,e[10],3200236656,23),i=c(i,o=c(o,r=c(r,n,i,o,e[13],681279174,4),n,i,e[0],3936430074,11),r,n,e[3],3572445317,16),o,r,e[6],76029189,23),i=c(i,o=c(o,r=c(r,n,i,o,e[9],3654602809,4),n,i,e[12],3873151461,11),r,n,e[15],530742520,16),o,r,e[2],3299628645,23),i=h(i,o=h(o,r=h(r,n,i,o,e[0],4096336452,6),n,i,e[7],1126891415,10),r,n,e[14],2878612391,15),o,r,e[5],4237533241,21),i=h(i,o=h(o,r=h(r,n,i,o,e[12],1700485571,6),n,i,e[3],2399980690,10),r,n,e[10],4293915773,15),o,r,e[1],2240044497,21),i=h(i,o=h(o,r=h(r,n,i,o,e[8],1873313359,6),n,i,e[15],4264355552,10),r,n,e[6],2734768916,15),o,r,e[13],1309151649,21),i=h(i,o=h(o,r=h(r,n,i,o,e[4],4149444226,6),n,i,e[11],3174756917,10),r,n,e[2],718787259,15),o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},n.prototype._digest=function(){this._block[this._blockOffset++]=128,56<this._blockOffset&&(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=new t(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},o.exports=n}).call(this,i("buffer").Buffer)},{buffer:48,"hash-base":86,inherits:103}],107:[function(e,t,r){var l=e("bn.js"),n=e("brorand");function i(e){this.rand=e||new n.Rand}(t.exports=i).create=function(e){return new i(e)},i.prototype._randbelow=function(e){var t=e.bitLength(),r=Math.ceil(t/8);do{var n=new l(this.rand.generate(r))}while(0<=n.cmp(e));return n},i.prototype._randrange=function(e,t){var r=t.sub(e);return e.add(this._randbelow(r))},i.prototype.test=function(e,t,r){var n=e.bitLength(),i=l.mont(e),o=new l(1).toRed(i);t||(t=Math.max(1,n/48|0));for(var s=e.subn(1),a=0;!s.testn(a);a++);for(var u=e.shrn(a),f=s.toRed(i);0<t;t--){var c=this._randrange(new l(2),s);r&&r(c);var h=c.toRed(i).redPow(u);if(0!==h.cmp(o)&&0!==h.cmp(f)){for(var d=1;d<a;d++){if(0===(h=h.redSqr()).cmp(o))return!1;if(0===h.cmp(f))break}if(d===a)return!1}}return!0},i.prototype.getDivisor=function(e,t){var r=e.bitLength(),n=l.mont(e),i=new l(1).toRed(n);t||(t=Math.max(1,r/48|0));for(var o=e.subn(1),s=0;!o.testn(s);s++);for(var a=e.shrn(s),u=o.toRed(n);0<t;t--){var f=this._randrange(new l(2),o),c=e.gcd(f);if(0!==c.cmpn(1))return c;var h=f.toRed(n).redPow(a);if(0!==h.cmp(i)&&0!==h.cmp(u)){for(var d=1;d<s;d++){if(0===(h=h.redSqr()).cmp(i))return h.fromRed().subn(1).gcd(e);if(0===h.cmp(u))break}if(d===s)return(h=h.redSqr()).fromRed().subn(1).gcd(e)}}return!1}},{"bn.js":"BN",brorand:16}],108:[function(e,t,r){function n(e,t){if(!e)throw new Error(t||"Assertion failed")}(t.exports=n).equal=function(e,t,r){if(e!=t)throw new Error(r||"Assertion failed: "+e+" != "+t)}},{}],109:[function(e,t,r){var n=r;function i(e){return 1===e.length?"0"+e:e}function o(e){for(var t="",r=0;r<e.length;r++)t+=i(e[r].toString(16));return t}n.toArray=function(e,t){if(Array.isArray(e))return e.slice();if(!e)return[];var r=[];if("string"!=typeof e){for(var n=0;n<e.length;n++)r[n]=0|e[n];return r}if("hex"===t)for((e=e.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(e="0"+e),n=0;n<e.length;n+=2)r.push(parseInt(e[n]+e[n+1],16));else for(n=0;n<e.length;n++){var i=e.charCodeAt(n),o=i>>8,s=255&i;o?r.push(o,s):r.push(s)}return r},n.zero2=i,n.toHex=o,n.encode=function(e,t){return"hex"===t?o(e):e}},{}],110:[function(e,t,r){r.endianness=function(){return"LE"},r.hostname=function(){return"undefined"!=typeof location?location.hostname:""},r.loadavg=function(){return[]},r.uptime=function(){return 0},r.freemem=function(){return Number.MAX_VALUE},r.totalmem=function(){return Number.MAX_VALUE},r.cpus=function(){return[]},r.type=function(){return"Browser"},r.release=function(){return"undefined"!=typeof navigator?navigator.appVersion:""},r.networkInterfaces=r.getNetworkInterfaces=function(){return{}},r.arch=function(){return"javascript"},r.platform=function(){return"browser"},r.tmpdir=r.tmpDir=function(){return"/tmp"},r.EOL="\n",r.homedir=function(){return"/"}},{}],111:[function(e,t,r){t.exports={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}},{}],112:[function(e,t,r){var n=e("asn1.js");r.certificate=e("./certificate");var i=n.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())});r.RSAPrivateKey=i;var o=n.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});r.RSAPublicKey=o;var s=n.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(a),this.key("subjectPublicKey").bitstr())});r.PublicKey=s;var a=n.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),u=n.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(a),this.key("subjectPrivateKey").octstr())});r.PrivateKey=u;var f=n.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});r.EncryptedPrivateKey=f;var c=n.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});r.DSAPrivateKey=c,r.DSAparam=n.define("DSAparam",function(){this.int()});var h=n.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(d),this.key("publicKey").optional().explicit(1).bitstr())});r.ECPrivateKey=h;var d=n.define("ECParameters",function(){this.choice({namedCurve:this.objid()})});r.signature=n.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})},{"./certificate":113,"asn1.js":1}],113:[function(e,t,r){var n=e("asn1.js"),i=n.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),o=n.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),s=n.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional())}),a=n.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(s),this.key("subjectPublicKey").bitstr())}),u=n.define("RelativeDistinguishedName",function(){this.setof(o)}),f=n.define("RDNSequence",function(){this.seqof(u)}),c=n.define("Name",function(){this.choice({rdnSequence:this.use(f)})}),h=n.define("Validity",function(){this.seq().obj(this.key("notBefore").use(i),this.key("notAfter").use(i))}),d=n.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),l=n.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int(),this.key("serialNumber").int(),this.key("signature").use(s),this.key("issuer").use(c),this.key("validity").use(h),this.key("subject").use(c),this.key("subjectPublicKeyInfo").use(a),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(d).optional())}),p=n.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(l),this.key("signatureAlgorithm").use(s),this.key("signatureValue").bitstr())});t.exports=p},{"asn1.js":1}],114:[function(e,t,r){(function(d){var l=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r\+\/\=]+)[\n\r]+/m,p=/^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----/m,b=/^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----([0-9A-z\n\r\+\/\=]+)-----END \1-----$/m,m=e("evp_bytestokey"),y=e("browserify-aes");t.exports=function(e,t){var r,n=e.toString(),i=n.match(l);if(i){var o="aes"+i[1],s=new d(i[2],"hex"),a=new d(i[3].replace(/[\r\n]/g,""),"base64"),u=m(t,s.slice(0,8),parseInt(i[1],10)).key,f=[],c=y.createDecipheriv(o,u,s);f.push(c.update(a)),f.push(c.final()),r=d.concat(f)}else{var h=n.match(b);r=new d(h[2].replace(/[\r\n]/g,""),"base64")}return{tag:n.match(p)[1],data:r}}}).call(this,e("buffer").Buffer)},{"browserify-aes":20,buffer:48,evp_bytestokey:85}],115:[function(t,r,e){(function(v){var g=t("./asn1"),w=t("./aesid.json"),_=t("./fixProc"),M=t("browserify-aes"),x=t("pbkdf2");function e(e){var t;"object"!==(void 0===e?"undefined":_typeof(e))||v.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=new v(e));var r,n,i,o,s,a,u,f,c,h,d,l,p,b=_(e,t),m=b.tag,y=b.data;switch(m){case"CERTIFICATE":n=g.certificate.decode(y,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(n||(n=g.PublicKey.decode(y,"der")),r=n.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return g.RSAPublicKey.decode(n.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return n.subjectPrivateKey=n.subjectPublicKey,{type:"ec",data:n};case"1.2.840.10040.4.1":return n.algorithm.params.pub_key=g.DSAparam.decode(n.subjectPublicKey.data,"der"),{type:"dsa",data:n.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+m);case"ENCRYPTED PRIVATE KEY":y=g.EncryptedPrivateKey.decode(y,"der"),o=t,s=(i=y).algorithm.decrypt.kde.kdeparams.salt,a=parseInt(i.algorithm.decrypt.kde.kdeparams.iters.toString(),10),u=w[i.algorithm.decrypt.cipher.algo.join(".")],f=i.algorithm.decrypt.cipher.iv,c=i.subjectPrivateKey,h=parseInt(u.split("-")[1],10)/8,d=x.pbkdf2Sync(o,s,a,h),l=M.createDecipheriv(u,d,f),(p=[]).push(l.update(c)),p.push(l.final()),y=v.concat(p);case"PRIVATE KEY":switch(r=(n=g.PrivateKey.decode(y,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return g.RSAPrivateKey.decode(n.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:n.algorithm.curve,privateKey:g.ECPrivateKey.decode(n.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return n.algorithm.params.priv_key=g.DSAparam.decode(n.subjectPrivateKey,"der"),{type:"dsa",params:n.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+m);case"RSA PUBLIC KEY":return g.RSAPublicKey.decode(y,"der");case"RSA PRIVATE KEY":return g.RSAPrivateKey.decode(y,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:g.DSAPrivateKey.decode(y,"der")};case"EC PRIVATE KEY":return{curve:(y=g.ECPrivateKey.decode(y,"der")).parameters.value,privateKey:y.privateKey};default:throw new Error("unknown key type "+m)}}(r.exports=e).signature=g.signature}).call(this,t("buffer").Buffer)},{"./aesid.json":111,"./asn1":112,"./fixProc":114,"browserify-aes":20,buffer:48,pbkdf2:116}],116:[function(e,t,r){r.pbkdf2=e("./lib/async"),r.pbkdf2Sync=e("./lib/sync")},{"./lib/async":117,"./lib/sync":120}],117:[function(e,t,r){(function(f,c){var h,d=e("./precondition"),l=e("./default-encoding"),p=e("./sync"),b=e("safe-buffer").Buffer,m=c.crypto&&c.crypto.subtle,y={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},v=[];function g(e,t,r,n,i){return m.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then(function(e){return m.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)}).then(function(e){return b.from(e)})}t.exports=function(t,r,n,i,o,s){"function"==typeof o&&(s=o,o=void 0);var e,a,u=y[(o=o||"sha1").toLowerCase()];if(!u||"function"!=typeof c.Promise)return f.nextTick(function(){var e;try{e=p(t,r,n,i,o)}catch(e){return s(e)}s(null,e)});if(d(t,r,n,i),"function"!=typeof s)throw new Error("No callback provided to pbkdf2");b.isBuffer(t)||(t=b.from(t,l)),b.isBuffer(r)||(r=b.from(r,l)),e=function(e){if(c.process&&!c.process.browser)return Promise.resolve(!1);if(!m||!m.importKey||!m.deriveBits)return Promise.resolve(!1);if(void 0!==v[e])return v[e];var t=g(h=h||b.alloc(8),h,10,128,e).then(function(){return!0}).catch(function(){return!1});return v[e]=t}(u).then(function(e){return e?g(t,r,n,i,u):p(t,r,n,i,o)}),a=s,e.then(function(e){f.nextTick(function(){a(null,e)})},function(e){f.nextTick(function(){a(e)})})}}).call(this,e("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./default-encoding":118,"./precondition":119,"./sync":120,_process:122,"safe-buffer":149}],118:[function(e,r,t){(function(e){var t;e.browser?t="utf-8":t=6<=parseInt(e.version.split(".")[0].slice(1),10)?"utf-8":"binary";r.exports=t}).call(this,e("_process"))},{_process:122}],119:[function(e,t,r){(function(r){var i=Math.pow(2,30)-1;function o(e,t){if("string"!=typeof e&&!r.isBuffer(e))throw new TypeError(t+" must be a buffer or string")}t.exports=function(e,t,r,n){if(o(e,"Password"),o(t,"Salt"),"number"!=typeof r)throw new TypeError("Iterations not a number");if(r<0)throw new TypeError("Bad iterations");if("number"!=typeof n)throw new TypeError("Key length not a number");if(n<0||i<n||n!=n)throw new TypeError("Bad key length")}}).call(this,{isBuffer:e("../../is-buffer/index.js")})},{"../../is-buffer/index.js":104}],120:[function(e,t,r){var c=e("create-hash/md5"),h=e("ripemd160"),d=e("sha.js"),m=e("./precondition"),y=e("./default-encoding"),v=e("safe-buffer").Buffer,l=v.alloc(128),g={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function w(e,t,r){var n,i="rmd160"===(n=e)||"ripemd160"===n?h:"md5"===n?c:function(e){return d(n).update(e).digest()},o="sha512"===e||"sha384"===e?128:64;t.length>o?t=i(t):t.length<o&&(t=v.concat([t,l],o));for(var s=v.allocUnsafe(o+g[e]),a=v.allocUnsafe(o+g[e]),u=0;u<o;u++)s[u]=54^t[u],a[u]=92^t[u];var f=v.allocUnsafe(o+r+4);s.copy(f,0,0,o),this.ipad1=f,this.ipad2=s,this.opad=a,this.alg=e,this.blocksize=o,this.hash=i,this.size=g[e]}w.prototype.run=function(e,t){return e.copy(t,this.blocksize),this.hash(t).copy(this.opad,this.blocksize),this.hash(this.opad)},t.exports=function(e,t,r,n,i){m(e,t,r,n),v.isBuffer(e)||(e=v.from(e,y)),v.isBuffer(t)||(t=v.from(t,y));var o=new w(i=i||"sha1",e,t.length),s=v.allocUnsafe(n),a=v.allocUnsafe(t.length+4);t.copy(a,0,0,t.length);for(var u=0,f=g[i],c=Math.ceil(n/f),h=1;h<=c;h++){a.writeUInt32BE(h,t.length);for(var d=o.run(a,o.ipad1),l=d,p=1;p<r;p++){l=o.run(l,o.ipad2);for(var b=0;b<f;b++)d[b]^=l[b]}d.copy(s,u),u+=f}return s}},{"./default-encoding":118,"./precondition":119,"create-hash/md5":54,ripemd160:148,"safe-buffer":149,"sha.js":151}],121:[function(e,t,r){(function(a){!a.version||0===a.version.indexOf("v0.")||0===a.version.indexOf("v1.")&&0!==a.version.indexOf("v1.8.")?t.exports={nextTick:function(e,t,r,n){if("function"!=typeof e)throw new TypeError('"callback" argument must be a function');var i,o,s=arguments.length;switch(s){case 0:case 1:return a.nextTick(e);case 2:return a.nextTick(function(){e.call(null,t)});case 3:return a.nextTick(function(){e.call(null,t,r)});case 4:return a.nextTick(function(){e.call(null,t,r,n)});default:for(i=new Array(s-1),o=0;o<i.length;)i[o++]=arguments[o];return a.nextTick(function(){e.apply(null,i)})}}}:t.exports=a}).call(this,e("_process"))},{_process:122}],122:[function(e,t,r){var n,i,o=t.exports={};function s(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===s||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:s}catch(e){n=s}try{i="function"==typeof clearTimeout?clearTimeout:a}catch(e){i=a}}();var f,c=[],h=!1,d=-1;function l(){h&&f&&(h=!1,f.length?c=f.concat(c):d=-1,c.length&&p())}function p(){if(!h){var e=u(l);h=!0;for(var t=c.length;t;){for(f=c,c=[];++d<t;)f&&f[d].run();d=-1,t=c.length}f=null,h=!1,function(t){if(i===clearTimeout)return clearTimeout(t);if((i===a||!i)&&clearTimeout)return i=clearTimeout,clearTimeout(t);try{i(t)}catch(e){try{return i.call(null,t)}catch(e){return i.call(this,t)}}}(e)}}function b(e,t){this.fun=e,this.array=t}function m(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(1<arguments.length)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new b(e,t)),1!==c.length||h||u(p)},b.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=m,o.addListener=m,o.once=m,o.off=m,o.removeListener=m,o.removeAllListeners=m,o.emit=m,o.prependListener=m,o.prependOnceListener=m,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},{}],123:[function(e,t,r){r.publicEncrypt=e("./publicEncrypt"),r.privateDecrypt=e("./privateDecrypt"),r.privateEncrypt=function(e,t){return r.publicEncrypt(e,t,!0)},r.publicDecrypt=function(e,t){return r.privateDecrypt(e,t,!0)}},{"./privateDecrypt":125,"./publicEncrypt":126}],124:[function(e,t,r){(function(o){var s=e("create-hash");function a(e){var t=new o(4);return t.writeUInt32BE(e,0),t}t.exports=function(e,t){for(var r,n=new o(""),i=0;n.length<t;)r=a(i++),n=o.concat([n,s("sha1").update(e).update(r).digest()]);return n.slice(0,t)}}).call(this,e("buffer").Buffer)},{buffer:48,"create-hash":53}],125:[function(e,t,r){(function(c){var u=e("parse-asn1"),h=e("./mgf"),d=e("./xor"),f=e("bn.js"),l=e("browserify-rsa"),p=e("create-hash"),b=e("./withPublic");t.exports=function(e,t,r){var n;n=e.padding?e.padding:r?1:4;var i,o=u(e),s=o.modulus.byteLength();if(t.length>s||0<=new f(t).cmp(o.modulus))throw new Error("decryption error");i=r?b(new f(t),o):l(t,o);var a=new c(s-i.length);if(a.fill(0),i=c.concat([a,i],s),4===n)return function(e,t){e.modulus;var r=e.modulus.byteLength(),n=(t.length,p("sha1").update(new c("")).digest()),i=n.length;if(0!==t[0])throw new Error("decryption error");var o=t.slice(1,i+1),s=t.slice(i+1),a=d(o,h(s,i)),u=d(s,h(a,r-i-1));if(function(e,t){e=new c(e),t=new c(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));var i=-1;for(;++i<n;)r+=e[i]^t[i];return r}(n,u.slice(0,i)))throw new Error("decryption error");var f=i;for(;0===u[f];)f++;if(1!==u[f++])throw new Error("decryption error");return u.slice(f)}(o,i);if(1===n)return function(e,t,r){var n=t.slice(0,2),i=2,o=0;for(;0!==t[i++];)if(i>=t.length){o++;break}var s=t.slice(2,i-1);t.slice(i-1,i);("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++;s.length<8&&o++;if(o)throw new Error("decryption error");return t.slice(i)}(0,i,r);if(3===n)return i;throw new Error("unknown padding")}}).call(this,e("buffer").Buffer)},{"./mgf":124,"./withPublic":127,"./xor":128,"bn.js":"BN","browserify-rsa":38,buffer:48,"create-hash":53,"parse-asn1":115}],126:[function(e,t,r){(function(d){var s=e("parse-asn1"),l=e("randombytes"),p=e("create-hash"),b=e("./mgf"),m=e("./xor"),y=e("bn.js"),a=e("./withPublic"),u=e("browserify-rsa");t.exports=function(e,t,r){var n;n=e.padding?e.padding:r?1:4;var i,o=s(e);if(4===n)i=function(e,t){var r=e.modulus.byteLength(),n=t.length,i=p("sha1").update(new d("")).digest(),o=i.length,s=2*o;if(r-s-2<n)throw new Error("message too long");var a=new d(r-n-s-2);a.fill(0);var u=r-o-1,f=l(o),c=m(d.concat([i,a,new d([1]),t],u),b(f,u)),h=m(f,b(c,o));return new y(d.concat([new d([0]),h,c],r))}(o,t);else if(1===n)i=function(e,t,r){var n,i=t.length,o=e.modulus.byteLength();if(o-11<i)throw new Error("message too long");r?(n=new d(o-i-3)).fill(255):n=function(e,t){var r,n=new d(e),i=0,o=l(2*e),s=0;for(;i<e;)s===o.length&&(o=l(2*e),s=0),(r=o[s++])&&(n[i++]=r);return n}(o-i-3);return new y(d.concat([new d([0,r?1:2]),n,new d([0]),t],o))}(o,t,r);else{if(3!==n)throw new Error("unknown padding");if(0<=(i=new y(t)).cmp(o.modulus))throw new Error("data too long for modulus")}return r?u(i,o):a(i,o)}}).call(this,e("buffer").Buffer)},{"./mgf":124,"./withPublic":127,"./xor":128,"bn.js":"BN","browserify-rsa":38,buffer:48,"create-hash":53,"parse-asn1":115,randombytes:133}],127:[function(e,t,r){(function(r){var n=e("bn.js");t.exports=function(e,t){return new r(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}}).call(this,e("buffer").Buffer)},{"bn.js":"BN",buffer:48}],128:[function(e,t,r){t.exports=function(e,t){for(var r=e.length,n=-1;++n<r;)e[n]^=t[n];return e}},{}],129:[function(e,C,P){(function(T){!function(e){var t="object"==(void 0===P?"undefined":_typeof(P))&&P&&!P.nodeType&&P,r="object"==(void 0===C?"undefined":_typeof(C))&&C&&!C.nodeType&&C,n="object"==(void 0===T?"undefined":_typeof(T))&&T;n.global!==n&&n.window!==n&&n.self!==n||(e=n);var i,o,y=2147483647,v=36,g=1,w=26,s=38,a=700,_=72,M=128,x="-",u=/^xn--/,f=/[^\x20-\x7E]/,c=/[\x2E\u3002\uFF0E\uFF61]/g,h={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},d=v-g,k=Math.floor,S=String.fromCharCode;function E(e){throw new RangeError(h[e])}function l(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function p(e,t){var r=e.split("@"),n="";return 1<r.length&&(n=r[0]+"@",e=r[1]),n+l((e=e.replace(c,".")).split("."),t).join(".")}function A(e){for(var t,r,n=[],i=0,o=e.length;i<o;)55296<=(t=e.charCodeAt(i++))&&t<=56319&&i<o?56320==(64512&(r=e.charCodeAt(i++)))?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),i--):n.push(t);return n}function j(e){return l(e,function(e){var t="";return 65535<e&&(t+=S((e-=65536)>>>10&1023|55296),e=56320|1023&e),t+=S(e)}).join("")}function I(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function B(e,t,r){var n=0;for(e=r?k(e/a):e>>1,e+=k(e/t);d*w>>1<e;n+=v)e=k(e/d);return k(n+(d+1)*e/(e+s))}function b(e){var t,r,n,i,o,s,a,u,f,c,h,d=[],l=e.length,p=0,b=M,m=_;for((r=e.lastIndexOf(x))<0&&(r=0),n=0;n<r;++n)128<=e.charCodeAt(n)&&E("not-basic"),d.push(e.charCodeAt(n));for(i=0<r?r+1:0;i<l;){for(o=p,s=1,a=v;l<=i&&E("invalid-input"),h=e.charCodeAt(i++),(v<=(u=h-48<10?h-22:h-65<26?h-65:h-97<26?h-97:v)||u>k((y-p)/s))&&E("overflow"),p+=u*s,!(u<(f=a<=m?g:m+w<=a?w:a-m));a+=v)s>k(y/(c=v-f))&&E("overflow"),s*=c;m=B(p-o,t=d.length+1,0==o),k(p/t)>y-b&&E("overflow"),b+=k(p/t),p%=t,d.splice(p++,0,b)}return j(d)}function m(e){var t,r,n,i,o,s,a,u,f,c,h,d,l,p,b,m=[];for(d=(e=A(e)).length,t=M,o=_,s=r=0;s<d;++s)(h=e[s])<128&&m.push(S(h));for(n=i=m.length,i&&m.push(x);n<d;){for(a=y,s=0;s<d;++s)t<=(h=e[s])&&h<a&&(a=h);for(a-t>k((y-r)/(l=n+1))&&E("overflow"),r+=(a-t)*l,t=a,s=0;s<d;++s)if((h=e[s])<t&&++r>y&&E("overflow"),h==t){for(u=r,f=v;!(u<(c=f<=o?g:o+w<=f?w:f-o));f+=v)b=u-c,p=v-c,m.push(S(I(c+b%p,0))),u=k(b/p);m.push(S(I(u,0))),o=B(r,l,n==i),r=0,++n}++r,++t}return m.join("")}if(i={version:"1.4.1",ucs2:{decode:A,encode:j},decode:b,encode:m,toASCII:function(e){return p(e,function(e){return f.test(e)?"xn--"+m(e):e})},toUnicode:function(e){return p(e,function(e){return u.test(e)?b(e.slice(4).toLowerCase()):e})}},"function"==typeof define&&"object"==_typeof(define.amd)&&define.amd)define("punycode",function(){return i});else if(t&&r)if(C.exports==t)r.exports=i;else for(o in i)i.hasOwnProperty(o)&&(t[o]=i[o]);else e.punycode=i}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],130:[function(e,t,r){t.exports=function(e,t,r,n){t=t||"&",r=r||"=";var i={};if("string"!=typeof e||0===e.length)return i;var o=/\+/g;e=e.split(t);var s=1e3;n&&"number"==typeof n.maxKeys&&(s=n.maxKeys);var a,u,f=e.length;0<s&&s<f&&(f=s);for(var c=0;c<f;++c){var h,d,l,p,b=e[c].replace(o,"%20"),m=b.indexOf(r);0<=m?(h=b.substr(0,m),d=b.substr(m+1)):(h=b,d=""),l=decodeURIComponent(h),p=decodeURIComponent(d),a=i,u=l,Object.prototype.hasOwnProperty.call(a,u)?y(i[l])?i[l].push(p):i[l]=[i[l],p]:i[l]=p}return i};var y=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],131:[function(e,t,r){var o=function(e){switch(void 0===e?"undefined":_typeof(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(r,n,i,e){return n=n||"&",i=i||"=",null===r&&(r=void 0),"object"===(void 0===r?"undefined":_typeof(r))?a(u(r),function(e){var t=encodeURIComponent(o(e))+i;return s(r[e])?a(r[e],function(e){return t+encodeURIComponent(o(e))}).join(n):t+encodeURIComponent(o(r[e]))}).join(n):e?encodeURIComponent(o(e))+i+encodeURIComponent(o(r)):""};var s=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)};function a(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var u=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],132:[function(e,t,r){r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":130,"./encode":131}],133:[function(e,t,r){(function(i,o){var s=e("safe-buffer").Buffer,a=o.crypto||o.msCrypto;a&&a.getRandomValues?t.exports=function(e,t){if(65536<e)throw new Error("requested too many random bytes");var r=new o.Uint8Array(e);0<e&&a.getRandomValues(r);var n=s.from(r.buffer);if("function"==typeof t)return i.nextTick(function(){t(null,n)});return n}:t.exports=function(){throw new Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}}).call(this,e("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:122,"safe-buffer":149}],134:[function(r,e,l){(function(s,i){function e(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var t=r("safe-buffer"),a=r("randombytes"),o=t.Buffer,n=t.kMaxLength,u=i.crypto||i.msCrypto,f=Math.pow(2,32)-1;function c(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(f<e||e<0)throw new TypeError("offset must be a uint32");if(n<e||t<e)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(f<e||e<0)throw new TypeError("size must be a uint32");if(r<e+t||n<e)throw new RangeError("buffer too small")}function d(r,n,e,i){if(s.browser){var t=r.buffer,o=new Uint8Array(t,n,e);return u.getRandomValues(o),i?void s.nextTick(function(){i(null,r)}):r}if(!i)return a(e).copy(r,n),r;a(e,function(e,t){if(e)return i(e);t.copy(r,n),i(null,r)})}u&&u.getRandomValues||!s.browser?(l.randomFill=function(e,t,r,n){if(!(o.isBuffer(e)||e instanceof i.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)n=t,t=0,r=e.length;else if("function"==typeof r)n=r,r=e.length-t;else if("function"!=typeof n)throw new TypeError('"cb" argument must be a function');return c(t,e.length),h(r,t,e.length),d(e,t,r,n)},l.randomFillSync=function(e,t,r){void 0===t&&(t=0);if(!(o.isBuffer(e)||e instanceof i.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');c(t,e.length),void 0===r&&(r=e.length-t);return h(r,t,e.length),d(e,t,r)}):(l.randomFill=e,l.randomFillSync=e)}).call(this,r("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:122,randombytes:133,"safe-buffer":149}],135:[function(e,t,r){t.exports=e("./lib/_stream_duplex.js")},{"./lib/_stream_duplex.js":136}],136:[function(e,t,r){var n=e("process-nextick-args"),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};t.exports=h;var o=e("core-util-is");o.inherits=e("inherits");var s=e("./_stream_readable"),a=e("./_stream_writable");o.inherits(h,s);for(var u=i(a.prototype),f=0;f<u.length;f++){var c=u[f];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",d)}function d(){this.allowHalfOpen||this._writableState.ended||n.nextTick(l,this)}function l(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(),n.nextTick(t,e)}},{"./_stream_readable":138,"./_stream_writable":140,"core-util-is":51,inherits:103,"process-nextick-args":121}],137:[function(e,t,r){t.exports=o;var n=e("./_stream_transform"),i=e("core-util-is");function o(e){if(!(this instanceof o))return new o(e);n.call(this,e)}i.inherits=e("inherits"),i.inherits(o,n),o.prototype._transform=function(e,t,r){r(null,e)}},{"./_stream_transform":139,"core-util-is":51,inherits:103}],138:[function(P,R,e){(function(m,e){var y=P("process-nextick-args");R.exports=d;var s,v=P("isarray");d.ReadableState=o;P("events").EventEmitter;var g=function(e,t){return e.listeners(t).length},i=P("./internal/streams/stream"),f=P("safe-buffer").Buffer,c=e.Uint8Array||function(){};var t=P("core-util-is");t.inherits=P("inherits");var r=P("util"),w=void 0;w=r&&r.debuglog?r.debuglog("stream"):function(){};var a,u=P("./internal/streams/BufferList"),n=P("./internal/streams/destroy");t.inherits(d,i);var h=["error","close","destroy","pause","resume"];function o(e,t){e=e||{};var r=t instanceof(s=s||P("./_stream_duplex"));this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var n=e.highWaterMark,i=e.readableHighWaterMark,o=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:r&&(i||0===i)?i:o,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new u,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&&(a||(a=P("string_decoder/").StringDecoder),this.decoder=new a(e.encoding),this.encoding=e.encoding)}function d(e){if(s=s||P("./_stream_duplex"),!(this instanceof d))return new d(e);this._readableState=new o(e,this),this.readable=!0,e&&("function"==typeof e.read&&(this._read=e.read),"function"==typeof e.destroy&&(this._destroy=e.destroy)),i.call(this)}function l(e,t,r,n,i){var o,s,a,u=e._readableState;null===t?(u.reading=!1,function(e,t){if(t.ended)return;if(t.decoder){var r=t.decoder.end();r&&r.length&&(t.buffer.push(r),t.length+=t.objectMode?1:r.length)}t.ended=!0,M(e)}(e,u)):(i||(o=function(e,t){var r;n=t,f.isBuffer(n)||n instanceof c||"string"==typeof t||void 0===t||e.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var n;return r}(u,t)),o?e.emit("error",o):u.objectMode||t&&0<t.length?("string"==typeof t||u.objectMode||Object.getPrototypeOf(t)===f.prototype||(s=t,t=f.from(s)),n?u.endEmitted?e.emit("error",new Error("stream.unshift() after end event")):p(e,u,t,!0):u.ended?e.emit("error",new Error("stream.push() after EOF")):(u.reading=!1,u.decoder&&!r?(t=u.decoder.write(t),u.objectMode||0!==t.length?p(e,u,t,!1):k(e,u)):p(e,u,t,!1))):n||(u.reading=!1));return!(a=u).ended&&(a.needReadable||a.length<a.highWaterMark||0===a.length)}function p(e,t,r,n){t.flowing&&0===t.length&&!t.sync?(e.emit("data",r),e.read(0)):(t.length+=t.objectMode?1:r.length,n?t.buffer.unshift(r):t.buffer.push(r),t.needReadable&&M(e)),k(e,t)}Object.defineProperty(d.prototype,"destroyed",{get:function(){return void 0!==this._readableState&&this._readableState.destroyed},set:function(e){this._readableState&&(this._readableState.destroyed=e)}}),d.prototype.destroy=n.destroy,d.prototype._undestroy=n.undestroy,d.prototype._destroy=function(e,t){this.push(null),t(e)},d.prototype.push=function(e,t){var r,n=this._readableState;return n.objectMode?r=!0:"string"==typeof e&&((t=t||n.defaultEncoding)!==n.encoding&&(e=f.from(e,t),t=""),r=!0),l(this,e,t,!1,r)},d.prototype.unshift=function(e){return l(this,e,null,!0,!1)},d.prototype.isPaused=function(){return!1===this._readableState.flowing},d.prototype.setEncoding=function(e){return a||(a=P("string_decoder/").StringDecoder),this._readableState.decoder=new a(e),this._readableState.encoding=e,this};var b=8388608;function _(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=(b<=(r=e)?r=b:(r--,r|=r>>>1,r|=r>>>2,r|=r>>>4,r|=r>>>8,r|=r>>>16,r++),r)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0));var r}function M(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(w("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?y.nextTick(x,e):x(e))}function x(e){w("emit readable"),e.emit("readable"),j(e)}function k(e,t){t.readingMore||(t.readingMore=!0,y.nextTick(S,e,t))}function S(e,t){for(var r=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(w("maybeReadMore read 0"),e.read(0),r!==t.length);)r=t.length;t.readingMore=!1}function E(e){w("readable nexttick read 0"),e.read(0)}function A(e,t){t.reading||(w("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),j(e),t.flowing&&!t.reading&&e.read(0)}function j(e){var t=e._readableState;for(w("flow",t.flowing);t.flowing&&null!==e.read(););}function I(e,t){return 0===t.length?null:(t.objectMode?r=t.buffer.shift():!e||e>=t.length?(r=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):r=function(e,t,r){var n;e<t.head.data.length?(n=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):n=e===t.head.data.length?t.shift():r?function(e,t){var r=t.head,n=1,i=r.data;e-=i.length;for(;r=r.next;){var o=r.data,s=e>o.length?o.length:e;if(s===o.length?i+=o:i+=o.slice(0,e),0===(e-=s)){s===o.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r).data=o.slice(s);break}++n}return t.length-=n,i}(e,t):function(e,t){var r=f.allocUnsafe(e),n=t.head,i=1;n.data.copy(r),e-=n.data.length;for(;n=n.next;){var o=n.data,s=e>o.length?o.length:e;if(o.copy(r,r.length-e,0,s),0===(e-=s)){s===o.length?(++i,n.next?t.head=n.next:t.head=t.tail=null):(t.head=n).data=o.slice(s);break}++i}return t.length-=i,r}(e,t);return n}(e,t.buffer,t.decoder),r);var r}function B(e){var t=e._readableState;if(0<t.length)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,y.nextTick(T,t,e))}function T(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function C(e,t){for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r;return-1}d.prototype.read=function(e){w("read",e),e=parseInt(e,10);var t=this._readableState,r=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return w("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?B(this):M(this),null;if(0===(e=_(e,t))&&t.ended)return 0===t.length&&B(this),null;var n,i=t.needReadable;return w("need readable",i),(0===t.length||t.length-e<t.highWaterMark)&&w("length less than watermark",i=!0),t.ended||t.reading?w("reading or ended",i=!1):i&&(w("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=_(r,t))),null===(n=0<e?I(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),r!==e&&t.ended&&B(this)),null!==n&&this.emit("data",n),n},d.prototype._read=function(e){this.emit("error",new Error("_read() is not implemented"))},d.prototype.pipe=function(r,e){var n=this,i=this._readableState;switch(i.pipesCount){case 0:i.pipes=r;break;case 1:i.pipes=[i.pipes,r];break;default:i.pipes.push(r)}i.pipesCount+=1,w("pipe count=%d opts=%j",i.pipesCount,e);var t=(!e||!1!==e.end)&&r!==m.stdout&&r!==m.stderr?s:b;function o(e,t){w("onunpipe"),e===n&&t&&!1===t.hasUnpiped&&(t.hasUnpiped=!0,w("cleanup"),r.removeListener("close",l),r.removeListener("finish",p),r.removeListener("drain",u),r.removeListener("error",d),r.removeListener("unpipe",o),n.removeListener("end",s),n.removeListener("end",b),n.removeListener("data",h),f=!0,!i.awaitDrain||r._writableState&&!r._writableState.needDrain||u())}function s(){w("onend"),r.end()}i.endEmitted?y.nextTick(t):n.once("end",t),r.on("unpipe",o);var a,u=(a=n,function(){var e=a._readableState;w("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&g(a,"data")&&(e.flowing=!0,j(a))});r.on("drain",u);var f=!1;var c=!1;function h(e){w("ondata"),(c=!1)!==r.write(e)||c||((1===i.pipesCount&&i.pipes===r||1<i.pipesCount&&-1!==C(i.pipes,r))&&!f&&(w("false write response, pause",n._readableState.awaitDrain),n._readableState.awaitDrain++,c=!0),n.pause())}function d(e){w("onerror",e),b(),r.removeListener("error",d),0===g(r,"error")&&r.emit("error",e)}function l(){r.removeListener("finish",p),b()}function p(){w("onfinish"),r.removeListener("close",l),b()}function b(){w("unpipe"),n.unpipe(r)}return n.on("data",h),function(e,t,r){if("function"==typeof e.prependListener)return e.prependListener(t,r);e._events&&e._events[t]?v(e._events[t])?e._events[t].unshift(r):e._events[t]=[r,e._events[t]]:e.on(t,r)}(r,"error",d),r.once("close",l),r.once("finish",p),r.emit("pipe",n),i.flowing||(w("pipe resume"),n.resume()),r},d.prototype.unpipe=function(e){var t=this._readableState,r={hasUnpiped:!1};if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this,r)),this;if(!e){var n=t.pipes,i=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var o=0;o<i;o++)n[o].emit("unpipe",this,r);return this}var s=C(t.pipes,e);return-1===s||(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this,r)),this},d.prototype.addListener=d.prototype.on=function(e,t){var r=i.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var n=this._readableState;n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.emittedReadable=!1,n.reading?n.length&&M(this):y.nextTick(E,this))}return r},d.prototype.resume=function(){var e,t,r=this._readableState;return r.flowing||(w("resume"),r.flowing=!0,e=this,(t=r).resumeScheduled||(t.resumeScheduled=!0,y.nextTick(A,e,t))),this},d.prototype.pause=function(){return w("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(w("pause"),this._readableState.flowing=!1,this.emit("pause")),this},d.prototype.wrap=function(t){var r=this,n=this._readableState,i=!1;for(var e in t.on("end",function(){if(w("wrapped end"),n.decoder&&!n.ended){var e=n.decoder.end();e&&e.length&&r.push(e)}r.push(null)}),t.on("data",function(e){(w("wrapped data"),n.decoder&&(e=n.decoder.write(e)),n.objectMode&&null==e)||(n.objectMode||e&&e.length)&&(r.push(e)||(i=!0,t.pause()))}),t)void 0===this[e]&&"function"==typeof t[e]&&(this[e]=function(e){return function(){return t[e].apply(t,arguments)}}(e));for(var o=0;o<h.length;o++)t.on(h[o],this.emit.bind(this,h[o]));return this._read=function(e){w("wrapped _read",e),i&&(i=!1,t.resume())},this},Object.defineProperty(d.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),d._fromList=I}).call(this,P("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./_stream_duplex":136,"./internal/streams/BufferList":141,"./internal/streams/destroy":142,"./internal/streams/stream":143,_process:122,"core-util-is":51,events:84,inherits:103,isarray:105,"process-nextick-args":121,"safe-buffer":149,"string_decoder/":163,util:17}],139:[function(e,t,r){t.exports=o;var n=e("./_stream_duplex"),i=e("core-util-is");function o(e){if(!(this instanceof o))return new o(e);n.call(this,e),this._transformState={afterTransform:function(e,t){var r=this._transformState;r.transforming=!1;var n=r.writecb;if(!n)return this.emit("error",new Error("write callback called multiple times"));r.writechunk=null,(r.writecb=null)!=t&&this.push(t),n(e);var i=this._readableState;i.reading=!1,(i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}.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",s)}function s(){var r=this;"function"==typeof this._flush?this._flush(function(e,t){a(r,e,t)}):a(this,null,null)}function a(e,t,r){if(t)return e.emit("error",t);if(null!=r&&e.push(r),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=e("inherits"),i.inherits(o,n),o.prototype.push=function(e,t){return this._transformState.needTransform=!1,n.prototype.push.call(this,e,t)},o.prototype._transform=function(e,t,r){throw new Error("_transform() is not implemented")},o.prototype._write=function(e,t,r){var n=this._transformState;if(n.writecb=r,n.writechunk=e,n.writeencoding=t,!n.transforming){var i=this._readableState;(n.needTransform||i.needReadable||i.length<i.highWaterMark)&&this._read(i.highWaterMark)}},o.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},o.prototype._destroy=function(e,t){var r=this;n.prototype._destroy.call(this,e,function(e){t(e),r.emit("close")})}},{"./_stream_duplex":136,"core-util-is":51,inherits:103}],140:[function(x,k,e){(function(e,t,r){var y=x("process-nextick-args");function h(e){var t=this;this.next=null,this.entry=null,this.finish=function(){!function(e,t,r){var n=e.entry;e.entry=null;for(;n;){var i=n.callback;t.pendingcb--,i(r),n=n.next}t.corkedRequestsFree?t.corkedRequestsFree.next=e:t.corkedRequestsFree=e}(t,e)}}k.exports=c;var a,d=!e.browser&&-1<["v0.10","v0.9."].indexOf(e.version.slice(0,5))?r:y.nextTick;c.WritableState=f;var n=x("core-util-is");n.inherits=x("inherits");var i={deprecate:x("util-deprecate")},o=x("./internal/streams/stream"),v=x("safe-buffer").Buffer,g=t.Uint8Array||function(){};var s,u=x("./internal/streams/destroy");function w(){}function f(e,t){a=a||x("./_stream_duplex"),e=e||{};var r=t instanceof a;this.objectMode=!!e.objectMode,r&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var n=e.highWaterMark,i=e.writableHighWaterMark,o=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:r&&(i||0===i)?i:o,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1;var s=(this.destroyed=!1)===e.decodeStrings;this.decodeStrings=!s,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var r=e._writableState,n=r.sync,i=r.writecb;if(h=r,h.writing=!1,h.writecb=null,h.length-=h.writelen,h.writelen=0,t)s=e,a=r,u=n,f=t,c=i,--a.pendingcb,u?(y.nextTick(c,f),y.nextTick(M,s,a),s._writableState.errorEmitted=!0,s.emit("error",f)):(c(f),s._writableState.errorEmitted=!0,s.emit("error",f),M(s,a));else{var o=b(r);o||r.corked||r.bufferProcessing||!r.bufferedRequest||p(e,r),n?d(l,e,r,o,i):l(e,r,o,i)}var s,a,u,f,c;var h}(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 h(this)}function c(e){if(a=a||x("./_stream_duplex"),!(s.call(c,this)||this instanceof a))return new c(e);this._writableState=new f(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)),o.call(this)}function _(e,t,r,n,i,o,s){t.writelen=n,t.writecb=s,t.writing=!0,t.sync=!0,r?e._writev(i,t.onwrite):e._write(i,o,t.onwrite),t.sync=!1}function l(e,t,r,n){var i,o;r||(i=e,0===(o=t).length&&o.needDrain&&(o.needDrain=!1,i.emit("drain"))),t.pendingcb--,n(),M(e,t)}function p(e,t){t.bufferProcessing=!0;var r=t.bufferedRequest;if(e._writev&&r&&r.next){var n=t.bufferedRequestCount,i=new Array(n),o=t.corkedRequestsFree;o.entry=r;for(var s=0,a=!0;r;)(i[s]=r).isBuf||(a=!1),r=r.next,s+=1;i.allBuffers=a,_(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 h(t),t.bufferedRequestCount=0}else{for(;r;){var u=r.chunk,f=r.encoding,c=r.callback;if(_(e,t,!1,t.objectMode?1:u.length,u,f,c),r=r.next,t.bufferedRequestCount--,t.writing)break}null===r&&(t.lastBufferedRequest=null)}t.bufferedRequest=r,t.bufferProcessing=!1}function b(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function m(t,r){t._final(function(e){r.pendingcb--,e&&t.emit("error",e),r.prefinished=!0,t.emit("prefinish"),M(t,r)})}function M(e,t){var r,n,i=b(t);return i&&(r=e,(n=t).prefinished||n.finalCalled||("function"==typeof r._final?(n.pendingcb++,n.finalCalled=!0,y.nextTick(m,r,n)):(n.prefinished=!0,r.emit("prefinish"))),0===t.pendingcb&&(t.finished=!0,e.emit("finish"))),i}n.inherits(c,o),f.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},function(){try{Object.defineProperty(f.prototype,"buffer",{get:i.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]?(s=Function.prototype[Symbol.hasInstance],Object.defineProperty(c,Symbol.hasInstance,{value:function(e){return!!s.call(this,e)||this===c&&(e&&e._writableState instanceof f)}})):s=function(e){return e instanceof this},c.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},c.prototype.write=function(e,t,r){var n,i,o,s,a,u,f,c,h,d,l,p=this._writableState,b=!1,m=!p.objectMode&&(n=e,v.isBuffer(n)||n instanceof g);return m&&!v.isBuffer(e)&&(i=e,e=v.from(i)),"function"==typeof t&&(r=t,t=null),m?t="buffer":t||(t=p.defaultEncoding),"function"!=typeof r&&(r=w),p.ended?(h=this,d=r,l=new Error("write after end"),h.emit("error",l),y.nextTick(d,l)):(m||(o=this,s=p,u=r,c=!(f=!0),null===(a=e)?c=new TypeError("May not write null values to stream"):"string"==typeof a||void 0===a||s.objectMode||(c=new TypeError("Invalid non-string/buffer chunk")),c&&(o.emit("error",c),y.nextTick(u,c),f=!1),f))&&(p.pendingcb++,b=function(e,t,r,n,i,o){if(!r){var s=function(e,t,r){e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=v.from(t,r));return t}(t,n,i);n!==s&&(r=!0,i="buffer",n=s)}var a=t.objectMode?1:n.length;t.length+=a;var u=t.length<t.highWaterMark;u||(t.needDrain=!0);if(t.writing||t.corked){var f=t.lastBufferedRequest;t.lastBufferedRequest={chunk:n,encoding:i,isBuf:r,callback:o,next:null},f?f.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else _(e,t,!1,a,n,i,o);return u}(this,p,m,e,t,r)),b},c.prototype.cork=function(){this._writableState.corked++},c.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||p(this,e))},c.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(-1<["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},Object.defineProperty(c.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),c.prototype._write=function(e,t,r){r(new Error("_write() is not implemented"))},c.prototype._writev=null,c.prototype.end=function(e,t,r){var n=this._writableState;"function"==typeof e?(r=e,t=e=null):"function"==typeof t&&(r=t,t=null),null!=e&&this.write(e,t),n.corked&&(n.corked=1,this.uncork()),n.ending||n.finished||function(e,t,r){t.ending=!0,M(e,t),r&&(t.finished?y.nextTick(r):e.once("finish",r));t.ended=!0,e.writable=!1}(this,n,r)},Object.defineProperty(c.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(e){this._writableState&&(this._writableState.destroyed=e)}}),c.prototype.destroy=u.destroy,c.prototype._undestroy=u.undestroy,c.prototype._destroy=function(e,t){this.end(),t(e)}}).call(this,x("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},x("timers").setImmediate)},{"./_stream_duplex":136,"./internal/streams/destroy":142,"./internal/streams/stream":143,_process:122,"core-util-is":51,inherits:103,"process-nextick-args":121,"safe-buffer":149,timers:164,"util-deprecate":168}],141:[function(e,t,r){var a=e("safe-buffer").Buffer,n=e("util");t.exports=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.head=null,this.tail=null,this.length=0}return e.prototype.push=function(e){var t={data:e,next:null};0<this.length?this.tail.next=t:this.head=t,this.tail=t,++this.length},e.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},e.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},e.prototype.clear=function(){this.head=this.tail=null,this.length=0},e.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,r=""+t.data;t=t.next;)r+=e+t.data;return r},e.prototype.concat=function(e){if(0===this.length)return a.alloc(0);if(1===this.length)return this.head.data;for(var t,r,n,i=a.allocUnsafe(e>>>0),o=this.head,s=0;o;)t=o.data,r=i,n=s,t.copy(r,n),s+=o.data.length,o=o.next;return i},e}(),n&&n.inspect&&n.inspect.custom&&(t.exports.prototype[n.inspect.custom]=function(){var e=n.inspect({length:this.length});return this.constructor.name+" "+e})},{"safe-buffer":149,util:17}],142:[function(e,t,r){var o=e("process-nextick-args");function s(e,t){e.emit("error",t)}t.exports={destroy:function(e,t){var r=this,n=this._readableState&&this._readableState.destroyed,i=this._writableState&&this._writableState.destroyed;return n||i?t?t(e):!e||this._writableState&&this._writableState.errorEmitted||o.nextTick(s,this,e):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(e||null,function(e){!t&&e?(o.nextTick(s,r,e),r._writableState&&(r._writableState.errorEmitted=!0)):t&&t(e)})),this},undestroy:function(){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)}}},{"process-nextick-args":121}],143:[function(e,t,r){t.exports=e("events").EventEmitter},{events:84}],144:[function(e,t,r){t.exports=e("./readable").PassThrough},{"./readable":145}],145:[function(e,t,r){(((r=t.exports=e("./lib/_stream_readable.js")).Stream=r).Readable=r).Writable=e("./lib/_stream_writable.js"),r.Duplex=e("./lib/_stream_duplex.js"),r.Transform=e("./lib/_stream_transform.js"),r.PassThrough=e("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":136,"./lib/_stream_passthrough.js":137,"./lib/_stream_readable.js":138,"./lib/_stream_transform.js":139,"./lib/_stream_writable.js":140}],146:[function(e,t,r){t.exports=e("./readable").Transform},{"./readable":145}],147:[function(e,t,r){t.exports=e("./lib/_stream_writable.js")},{"./lib/_stream_writable.js":140}],148:[function(e,t,r){var n=e("buffer").Buffer,i=e("inherits"),o=e("hash-base"),m=new Array(16),y=[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],v=[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],g=[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],w=[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],_=[0,1518500249,1859775393,2400959708,2840853838],M=[1352829926,1548603684,1836072691,2053994217,0];function s(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function x(e,t){return e<<t|e>>>32-t}function k(e,t,r,n,i,o,s,a){return x(e+(t^r^n)+o+s|0,a)+i|0}function S(e,t,r,n,i,o,s,a){return x(e+(t&r|~t&n)+o+s|0,a)+i|0}function E(e,t,r,n,i,o,s,a){return x(e+((t|~r)^n)+o+s|0,a)+i|0}function A(e,t,r,n,i,o,s,a){return x(e+(t&n|r&~n)+o+s|0,a)+i|0}function j(e,t,r,n,i,o,s,a){return x(e+(t^(r|~n))+o+s|0,a)+i|0}i(s,o),s.prototype._update=function(){for(var e=m,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);for(var r=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,s=0|this._e,a=0|this._a,u=0|this._b,f=0|this._c,c=0|this._d,h=0|this._e,d=0;d<80;d+=1){var l,p;d<16?(l=k(r,n,i,o,s,e[y[d]],_[0],g[d]),p=j(a,u,f,c,h,e[v[d]],M[0],w[d])):d<32?(l=S(r,n,i,o,s,e[y[d]],_[1],g[d]),p=A(a,u,f,c,h,e[v[d]],M[1],w[d])):d<48?(l=E(r,n,i,o,s,e[y[d]],_[2],g[d]),p=E(a,u,f,c,h,e[v[d]],M[2],w[d])):d<64?(l=A(r,n,i,o,s,e[y[d]],_[3],g[d]),p=S(a,u,f,c,h,e[v[d]],M[3],w[d])):(l=j(r,n,i,o,s,e[y[d]],_[4],g[d]),p=k(a,u,f,c,h,e[v[d]],M[4],w[d])),r=s,s=o,o=x(i,10),i=n,n=l,a=h,h=c,c=x(f,10),f=u,u=p}var b=this._b+i+c|0;this._b=this._c+o+h|0,this._c=this._d+s+a|0,this._d=this._e+r+u|0,this._e=this._a+n+f|0,this._a=b},s.prototype._digest=function(){this._block[this._blockOffset++]=128,56<this._blockOffset&&(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=n.alloc?n.alloc(20):new n(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},t.exports=s},{buffer:48,"hash-base":86,inherits:103}],149:[function(e,t,r){var n=e("buffer"),i=n.Buffer;function o(e,t){for(var r in e)t[r]=e[r]}function s(e,t,r){return i(e,t,r)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?t.exports=n:(o(n,r),r.Buffer=s),o(i,s),s.from=function(e,t,r){if("number"==typeof e)throw new TypeError("Argument must not be a number");return i(e,t,r)},s.alloc=function(e,t,r){if("number"!=typeof e)throw new TypeError("Argument must be a number");var n=i(e);return void 0!==t?"string"==typeof r?n.fill(t,r):n.fill(t):n.fill(0),n},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 n.SlowBuffer(e)}},{buffer:48}],150:[function(e,t,r){var c=e("safe-buffer").Buffer;function n(e,t){this._block=c.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}n.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=c.from(e,t));for(var r=this._block,n=this._blockSize,i=e.length,o=this._len,s=0;s<i;){for(var a=o%n,u=Math.min(i-s,n-a),f=0;f<u;f++)r[a+f]=e[s+f];s+=u,(o+=u)%n==0&&this._update(r)}return this._len+=i,this},n.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 r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=(4294967295&r)>>>0,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},{"safe-buffer":149}],151:[function(e,t,r){(r=t.exports=function(e){e=e.toLowerCase();var t=r[e];if(!t)throw new Error(e+" is not supported (we accept pull requests)");return new t}).sha=e("./sha"),r.sha1=e("./sha1"),r.sha224=e("./sha224"),r.sha256=e("./sha256"),r.sha384=e("./sha384"),r.sha512=e("./sha512")},{"./sha":152,"./sha1":153,"./sha224":154,"./sha256":155,"./sha384":156,"./sha512":157}],152:[function(e,t,r){var n=e("inherits"),i=e("./hash"),o=e("safe-buffer").Buffer,y=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function a(){this.init(),this._w=s,i.call(this,64,56)}n(a,i),a.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},a.prototype._update=function(e){for(var t,r,n,i,o,s,a=this._w,u=0|this._a,f=0|this._b,c=0|this._c,h=0|this._d,d=0|this._e,l=0;l<16;++l)a[l]=e.readInt32BE(4*l);for(;l<80;++l)a[l]=a[l-3]^a[l-8]^a[l-14]^a[l-16];for(var p=0;p<80;++p){var b=~~(p/20),m=0|((s=u)<<5|s>>>27)+(n=f,i=c,o=h,0===(r=b)?n&i|~n&o:2===r?n&i|n&o|i&o:n^i^o)+d+a[p]+y[b];d=h,h=c,c=(t=f)<<30|t>>>2,f=u,u=m}this._a=u+this._a|0,this._b=f+this._b|0,this._c=c+this._c|0,this._d=h+this._d|0,this._e=d+this._e|0},a.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},t.exports=a},{"./hash":150,inherits:103,"safe-buffer":149}],153:[function(e,t,r){var n=e("inherits"),i=e("./hash"),o=e("safe-buffer").Buffer,v=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function a(){this.init(),this._w=s,i.call(this,64,56)}n(a,i),a.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},a.prototype._update=function(e){for(var t,r,n,i,o,s,a,u=this._w,f=0|this._a,c=0|this._b,h=0|this._c,d=0|this._d,l=0|this._e,p=0;p<16;++p)u[p]=e.readInt32BE(4*p);for(;p<80;++p)u[p]=(t=u[p-3]^u[p-8]^u[p-14]^u[p-16])<<1|t>>>31;for(var b=0;b<80;++b){var m=~~(b/20),y=0|((a=f)<<5|a>>>27)+(i=c,o=h,s=d,0===(n=m)?i&o|~i&s:2===n?i&o|i&s|o&s:i^o^s)+l+u[b]+v[m];l=d,d=h,h=(r=c)<<30|r>>>2,c=f,f=y}this._a=f+this._a|0,this._b=c+this._b|0,this._c=h+this._c|0,this._d=d+this._d|0,this._e=l+this._e|0},a.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},t.exports=a},{"./hash":150,inherits:103,"safe-buffer":149}],154:[function(e,t,r){var n=e("inherits"),i=e("./sha256"),o=e("./hash"),s=e("safe-buffer").Buffer,a=new Array(64);function u(){this.init(),this._w=a,o.call(this,64,56)}n(u,i),u.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},u.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},t.exports=u},{"./hash":150,"./sha256":155,inherits:103,"safe-buffer":149}],155:[function(e,t,r){var n=e("inherits"),i=e("./hash"),o=e("safe-buffer").Buffer,_=[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=new Array(64);function a(){this.init(),this._w=s,i.call(this,64,56)}n(a,i),a.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},a.prototype._update=function(e){for(var t,r,n,i,o,s,a,u=this._w,f=0|this._a,c=0|this._b,h=0|this._c,d=0|this._d,l=0|this._e,p=0|this._f,b=0|this._g,m=0|this._h,y=0;y<16;++y)u[y]=e.readInt32BE(4*y);for(;y<64;++y)u[y]=0|(((r=u[y-2])>>>17|r<<15)^(r>>>19|r<<13)^r>>>10)+u[y-7]+(((t=u[y-15])>>>7|t<<25)^(t>>>18|t<<14)^t>>>3)+u[y-16];for(var v=0;v<64;++v){var g=m+(((a=l)>>>6|a<<26)^(a>>>11|a<<21)^(a>>>25|a<<7))+((s=b)^l&(p^s))+_[v]+u[v]|0,w=0|(((o=f)>>>2|o<<30)^(o>>>13|o<<19)^(o>>>22|o<<10))+((n=f)&(i=c)|h&(n|i));m=b,b=p,p=l,l=d+g|0,d=h,h=c,c=f,f=g+w|0}this._a=f+this._a|0,this._b=c+this._b|0,this._c=h+this._c|0,this._d=d+this._d|0,this._e=l+this._e|0,this._f=p+this._f|0,this._g=b+this._g|0,this._h=m+this._h|0},a.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},t.exports=a},{"./hash":150,inherits:103,"safe-buffer":149}],156:[function(e,t,r){var n=e("inherits"),i=e("./sha512"),o=e("./hash"),s=e("safe-buffer").Buffer,a=new Array(160);function u(){this.init(),this._w=a,o.call(this,128,112)}n(u,i),u.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},u.prototype._hash=function(){var n=s.allocUnsafe(48);function e(e,t,r){n.writeInt32BE(e,r),n.writeInt32BE(t,r+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),n},t.exports=u},{"./hash":150,"./sha512":157,inherits:103,"safe-buffer":149}],157:[function(e,t,r){var n=e("inherits"),i=e("./hash"),o=e("safe-buffer").Buffer,ee=[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],s=new Array(160);function a(){this.init(),this._w=s,i.call(this,128,112)}function te(e,t,r){return r^e&(t^r)}function re(e,t,r){return e&t|r&(e|t)}function ne(e,t){return(e>>>28|t<<4)^(t>>>2|e<<30)^(t>>>7|e<<25)}function ie(e,t){return(e>>>14|t<<18)^(e>>>18|t<<14)^(t>>>9|e<<23)}function oe(e,t){return e>>>0<t>>>0?1:0}n(a,i),a.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},a.prototype._update=function(e){for(var t,r,n,i,o,s,a,u,f=this._w,c=0|this._ah,h=0|this._bh,d=0|this._ch,l=0|this._dh,p=0|this._eh,b=0|this._fh,m=0|this._gh,y=0|this._hh,v=0|this._al,g=0|this._bl,w=0|this._cl,_=0|this._dl,M=0|this._el,x=0|this._fl,k=0|this._gl,S=0|this._hl,E=0;E<32;E+=2)f[E]=e.readInt32BE(4*E),f[E+1]=e.readInt32BE(4*E+4);for(;E<160;E+=2){var A=f[E-30],j=f[E-30+1],I=((a=A)>>>1|(u=j)<<31)^(a>>>8|u<<24)^a>>>7,B=((o=j)>>>1|(s=A)<<31)^(o>>>8|s<<24)^(o>>>7|s<<25);A=f[E-4],j=f[E-4+1];var T=((n=A)>>>19|(i=j)<<13)^(i>>>29|n<<3)^n>>>6,C=((t=j)>>>19|(r=A)<<13)^(r>>>29|t<<3)^(t>>>6|r<<26),P=f[E-14],R=f[E-14+1],O=f[E-32],N=f[E-32+1],L=B+R|0,q=I+P+oe(L,B)|0;q=(q=q+T+oe(L=L+C|0,C)|0)+O+oe(L=L+N|0,N)|0,f[E]=q,f[E+1]=L}for(var D=0;D<160;D+=2){q=f[D],L=f[D+1];var F=re(c,h,d),U=re(v,g,w),H=ne(c,v),z=ne(v,c),K=ie(p,M),W=ie(M,p),V=ee[D],X=ee[D+1],G=te(p,b,m),J=te(M,x,k),Z=S+W|0,$=y+K+oe(Z,S)|0;$=($=($=$+G+oe(Z=Z+J|0,J)|0)+V+oe(Z=Z+X|0,X)|0)+q+oe(Z=Z+L|0,L)|0;var Y=z+U|0,Q=H+F+oe(Y,z)|0;y=m,S=k,m=b,k=x,b=p,x=M,p=l+$+oe(M=_+Z|0,_)|0,l=d,_=w,d=h,w=g,h=c,g=v,c=$+Q+oe(v=Z+Y|0,Z)|0}this._al=this._al+v|0,this._bl=this._bl+g|0,this._cl=this._cl+w|0,this._dl=this._dl+_|0,this._el=this._el+M|0,this._fl=this._fl+x|0,this._gl=this._gl+k|0,this._hl=this._hl+S|0,this._ah=this._ah+c+oe(this._al,v)|0,this._bh=this._bh+h+oe(this._bl,g)|0,this._ch=this._ch+d+oe(this._cl,w)|0,this._dh=this._dh+l+oe(this._dl,_)|0,this._eh=this._eh+p+oe(this._el,M)|0,this._fh=this._fh+b+oe(this._fl,x)|0,this._gh=this._gh+m+oe(this._gl,k)|0,this._hh=this._hh+y+oe(this._hl,S)|0},a.prototype._hash=function(){var n=o.allocUnsafe(64);function e(e,t,r){n.writeInt32BE(e,r),n.writeInt32BE(t,r+4)}return e(this._ah,this._al,0),e(this._bh,this._bl,8),e(this._ch,this._cl,16),e(this._dh,this._dl,24),e(this._eh,this._el,32),e(this._fh,this._fl,40),e(this._gh,this._gl,48),e(this._hh,this._hl,56),n},t.exports=a},{"./hash":150,inherits:103,"safe-buffer":149}],158:[function(e,t,r){t.exports=n;var c=e("events").EventEmitter;function n(){c.call(this)}e("inherits")(n,c),n.Readable=e("readable-stream/readable.js"),n.Writable=e("readable-stream/writable.js"),n.Duplex=e("readable-stream/duplex.js"),n.Transform=e("readable-stream/transform.js"),n.PassThrough=e("readable-stream/passthrough.js"),(n.Stream=n).prototype.pipe=function(t,e){var r=this;function n(e){t.writable&&!1===t.write(e)&&r.pause&&r.pause()}function i(){r.readable&&r.resume&&r.resume()}r.on("data",n),t.on("drain",i),t._isStdio||e&&!1===e.end||(r.on("end",s),r.on("close",a));var o=!1;function s(){o||(o=!0,t.end())}function a(){o||(o=!0,"function"==typeof t.destroy&&t.destroy())}function u(e){if(f(),0===c.listenerCount(this,"error"))throw e}function f(){r.removeListener("data",n),t.removeListener("drain",i),r.removeListener("end",s),r.removeListener("close",a),r.removeListener("error",u),t.removeListener("error",u),r.removeListener("end",f),r.removeListener("close",f),t.removeListener("close",f)}return r.on("error",u),t.on("error",u),r.on("end",f),r.on("close",f),t.on("close",f),t.emit("pipe",r),t}},{events:84,inherits:103,"readable-stream/duplex.js":135,"readable-stream/passthrough.js":144,"readable-stream/readable.js":145,"readable-stream/transform.js":146,"readable-stream/writable.js":147}],159:[function(r,e,i){(function(u){var f=r("./lib/request"),e=r("./lib/response"),c=r("xtend"),t=r("builtin-status-codes"),h=r("url"),n=i;n.request=function(e,t){e="string"==typeof e?h.parse(e):c(e);var r=-1===u.location.protocol.search(/^https?:$/)?"http:":"",n=e.protocol||r,i=e.hostname||e.host,o=e.port,s=e.path||"/";i&&-1!==i.indexOf(":")&&(i="["+i+"]"),e.url=(i?n+"//"+i:"")+(o?":"+o:"")+s,e.method=(e.method||"GET").toUpperCase(),e.headers=e.headers||{};var a=new f(e);return t&&a.on("response",t),a},n.get=function(e,t){var r=n.request(e,t);return r.end(),r},n.ClientRequest=f,n.IncomingMessage=e.IncomingMessage,n.Agent=function(){},n.Agent.defaultMaxSockets=4,n.globalAgent=new n.Agent,n.STATUS_CODES=t,n.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,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./lib/request":161,"./lib/response":162,"builtin-status-codes":49,url:166,xtend:170}],160:[function(e,t,a){(function(e){a.fetch=s(e.fetch)&&s(e.ReadableStream),a.writableStream=s(e.WritableStream),a.abortController=s(e.AbortController),a.blobConstructor=!1;try{new Blob([new ArrayBuffer(1)]),a.blobConstructor=!0}catch(e){}var t;function r(){if(void 0!==t)return t;if(e.XMLHttpRequest){t=new e.XMLHttpRequest;try{t.open("GET",e.XDomainRequest?"/":"https://example.com")}catch(e){t=null}}else t=null;return t}function n(e){var t=r();if(!t)return!1;try{return t.responseType=e,t.responseType===e}catch(e){}return!1}var i=void 0!==e.ArrayBuffer,o=i&&s(e.ArrayBuffer.prototype.slice);function s(e){return"function"==typeof e}a.arraybuffer=a.fetch||i&&n("arraybuffer"),a.msstream=!a.fetch&&o&&n("ms-stream"),a.mozchunkedarraybuffer=!a.fetch&&i&&n("moz-chunked-arraybuffer"),a.overrideMimeType=a.fetch||!!r()&&s(r().overrideMimeType),a.vbArray=s(e.VBArray),t=null}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],161:[function(o,a,e){(function(u,f,c){var h=o("./capability"),e=o("inherits"),t=o("./response"),s=o("readable-stream"),d=o("to-arraybuffer"),r=t.IncomingMessage,l=t.readyStates;var n=a.exports=function(t){var e,r=this;s.Writable.call(r),r._opts=t,r._body=[],r._headers={},t.auth&&r.setHeader("Authorization","Basic "+new c(t.auth).toString("base64")),Object.keys(t.headers).forEach(function(e){r.setHeader(e,t.headers[e])});var n,i,o=!0;if("disable-fetch"===t.mode||"requestTimeout"in t&&!h.abortController)e=!(o=!1);else if("prefer-streaming"===t.mode)e=!1;else if("allow-wrong-content-type"===t.mode)e=!h.overrideMimeType;else{if(t.mode&&"default"!==t.mode&&"prefer-fast"!==t.mode)throw new Error("Invalid value for opts.mode");e=!0}r._mode=(n=e,i=o,h.fetch&&i?"fetch":h.mozchunkedarraybuffer?"moz-chunked-arraybuffer":h.msstream?"ms-stream":h.arraybuffer&&n?"arraybuffer":h.vbArray&&n?"text:vbarray":"text"),r._fetchTimer=null,r.on("finish",function(){r._onFinish()})};e(n,s.Writable),n.prototype.setHeader=function(e,t){var r=e.toLowerCase();-1===i.indexOf(r)&&(this._headers[r]={name:e,value:t})},n.prototype.getHeader=function(e){var t=this._headers[e.toLowerCase()];return t?t.value:null},n.prototype.removeHeader=function(e){delete this._headers[e.toLowerCase()]},n.prototype._onFinish=function(){var t=this;if(!t._destroyed){var e=t._opts,n=t._headers,r=null;"GET"!==e.method&&"HEAD"!==e.method&&(r=h.arraybuffer?d(c.concat(t._body)):h.blobConstructor?new f.Blob(t._body.map(function(e){return d(e)}),{type:(n["content-type"]||{}).value||""}):c.concat(t._body).toString());var i=[];if(Object.keys(n).forEach(function(e){var t=n[e].name,r=n[e].value;Array.isArray(r)?r.forEach(function(e){i.push([t,e])}):i.push([t,r])}),"fetch"===t._mode){var o=null;if(h.abortController){var s=new AbortController;o=s.signal,t._fetchAbortController=s,"requestTimeout"in e&&0!==e.requestTimeout&&(t._fetchTimer=f.setTimeout(function(){t.emit("requestTimeout"),t._fetchAbortController&&t._fetchAbortController.abort()},e.requestTimeout))}f.fetch(t._opts.url,{method:t._opts.method,headers:i,body:r||void 0,mode:"cors",credentials:e.withCredentials?"include":"same-origin",signal:o}).then(function(e){t._fetchResponse=e,t._connect()},function(e){f.clearTimeout(t._fetchTimer),t._destroyed||t.emit("error",e)})}else{var a=t._xhr=new f.XMLHttpRequest;try{a.open(t._opts.method,t._opts.url,!0)}catch(e){return void u.nextTick(function(){t.emit("error",e)})}"responseType"in a&&(a.responseType=t._mode.split(":")[0]),"withCredentials"in a&&(a.withCredentials=!!e.withCredentials),"text"===t._mode&&"overrideMimeType"in a&&a.overrideMimeType("text/plain; charset=x-user-defined"),"requestTimeout"in e&&(a.timeout=e.requestTimeout,a.ontimeout=function(){t.emit("requestTimeout")}),i.forEach(function(e){a.setRequestHeader(e[0],e[1])}),t._response=null,a.onreadystatechange=function(){switch(a.readyState){case l.LOADING:case l.DONE:t._onXHRProgress()}},"moz-chunked-arraybuffer"===t._mode&&(a.onprogress=function(){t._onXHRProgress()}),a.onerror=function(){t._destroyed||t.emit("error",new Error("XHR error"))};try{a.send(r)}catch(e){return void u.nextTick(function(){t.emit("error",e)})}}}},n.prototype._onXHRProgress=function(){(function(e){try{var t=e.status;return null!==t&&0!==t}catch(e){return!1}})(this._xhr)&&!this._destroyed&&(this._response||this._connect(),this._response._onXHRProgress())},n.prototype._connect=function(){var t=this;t._destroyed||(t._response=new r(t._xhr,t._fetchResponse,t._mode,t._fetchTimer),t._response.on("error",function(e){t.emit("error",e)}),t.emit("response",t._response))},n.prototype._write=function(e,t,r){this._body.push(e),r()},n.prototype.abort=n.prototype.destroy=function(){this._destroyed=!0,f.clearTimeout(this._fetchTimer),this._response&&(this._response._destroyed=!0),this._xhr?this._xhr.abort():this._fetchAbortController&&this._fetchAbortController.abort()},n.prototype.end=function(e,t,r){"function"==typeof e&&(r=e,e=void 0),s.Writable.prototype.end.call(this,e,t,r)},n.prototype.flushHeaders=function(){},n.prototype.setTimeout=function(){},n.prototype.setNoDelay=function(){},n.prototype.setSocketKeepAlive=function(){};var i=["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,o("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},o("buffer").Buffer)},{"./capability":160,"./response":162,_process:122,buffer:48,inherits:103,"readable-stream":145,"to-arraybuffer":165}],162:[function(r,e,n){(function(f,c,h){var d=r("./capability"),e=r("inherits"),l=r("readable-stream"),a=n.readyStates={UNSENT:0,OPENED:1,HEADERS_RECEIVED:2,LOADING:3,DONE:4},t=n.IncomingMessage=function(e,t,r,n){var i=this;if(l.Readable.call(i),i._mode=r,i.headers={},i.rawHeaders=[],i.trailers={},i.rawTrailers=[],i.on("end",function(){f.nextTick(function(){i.emit("close")})}),"fetch"===r){if(i._fetchResponse=t,i.url=t.url,i.statusCode=t.status,i.statusMessage=t.statusText,t.headers.forEach(function(e,t){i.headers[t.toLowerCase()]=e,i.rawHeaders.push(t,e)}),d.writableStream){var o=new WritableStream({write:function(r){return new Promise(function(e,t){i._destroyed?t():i.push(new h(r))?e():i._resumeFetch=e})},close:function(){c.clearTimeout(n),i._destroyed||i.push(null)},abort:function(e){i._destroyed||i.emit("error",e)}});try{return void t.body.pipeTo(o).catch(function(e){c.clearTimeout(n),i._destroyed||i.emit("error",e)})}catch(e){}}var s=t.body.getReader();!function t(){s.read().then(function(e){if(!i._destroyed){if(e.done)return c.clearTimeout(n),void i.push(null);i.push(new h(e.value)),t()}}).catch(function(e){c.clearTimeout(n),i._destroyed||i.emit("error",e)})}()}else{if(i._xhr=e,i._pos=0,i.url=e.responseURL,i.statusCode=e.status,i.statusMessage=e.statusText,e.getAllResponseHeaders().split(/\r?\n/).forEach(function(e){var t=e.match(/^([^:]+):\s*(.*)/);if(t){var r=t[1].toLowerCase();"set-cookie"===r?(void 0===i.headers[r]&&(i.headers[r]=[]),i.headers[r].push(t[2])):void 0!==i.headers[r]?i.headers[r]+=", "+t[2]:i.headers[r]=t[2],i.rawHeaders.push(t[1],t[2])}}),i._charset="x-user-defined",!d.overrideMimeType){var a=i.rawHeaders["mime-type"];if(a){var u=a.match(/;\s*charset=([^;])(;|$)/);u&&(i._charset=u[1].toLowerCase())}i._charset||(i._charset="utf-8")}}};e(t,l.Readable),t.prototype._read=function(){var e=this._resumeFetch;e&&(this._resumeFetch=null,e())},t.prototype._onXHRProgress=function(){var t=this,e=t._xhr,r=null;switch(t._mode){case"text:vbarray":if(e.readyState!==a.DONE)break;try{r=new c.VBArray(e.responseBody).toArray()}catch(e){}if(null!==r){t.push(new h(r));break}case"text":try{r=e.responseText}catch(e){t._mode="text:vbarray";break}if(r.length>t._pos){var n=r.substr(t._pos);if("x-user-defined"===t._charset){for(var i=new h(n.length),o=0;o<n.length;o++)i[o]=255&n.charCodeAt(o);t.push(i)}else t.push(n,t._charset);t._pos=r.length}break;case"arraybuffer":if(e.readyState!==a.DONE||!e.response)break;r=e.response,t.push(new h(new Uint8Array(r)));break;case"moz-chunked-arraybuffer":if(r=e.response,e.readyState!==a.LOADING||!r)break;t.push(new h(new Uint8Array(r)));break;case"ms-stream":if(r=e.response,e.readyState!==a.LOADING)break;var s=new c.MSStreamReader;s.onprogress=function(){s.result.byteLength>t._pos&&(t.push(new h(new Uint8Array(s.result.slice(t._pos)))),t._pos=s.result.byteLength)},s.onload=function(){t.push(null)},s.readAsArrayBuffer(r)}t._xhr.readyState===a.DONE&&"ms-stream"!==t._mode&&t.push(null)}}).call(this,r("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},r("buffer").Buffer)},{"./capability":160,_process:122,buffer:48,inherits:103,"readable-stream":145}],163:[function(e,t,r){var n=e("safe-buffer").Buffer,i=n.isEncoding||function(e){switch((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){var t;switch(this.encoding=function(e){var t=function(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}}(e);if("string"!=typeof t&&(n.isEncoding===i||!i(e)))throw new Error("Unknown encoding: "+e);return t||e}(e),this.encoding){case"utf16le":this.text=u,this.end=f,t=4;break;case"utf8":this.fillLast=a,t=4;break;case"base64":this.text=c,this.end=h,t=3;break;default:return this.write=d,void(this.end=l)}this.lastNeed=0,this.lastTotal=0,this.lastChar=n.allocUnsafe(t)}function s(e){return e<=127?0:e>>5==6?2:e>>4==14?3:e>>3==30?4:e>>6==2?-1:-2}function a(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!=(192&t[0]))return e.lastNeed=0,"�";if(1<e.lastNeed&&1<t.length){if(128!=(192&t[1]))return e.lastNeed=1,"�";if(2<e.lastNeed&&2<t.length&&128!=(192&t[2]))return e.lastNeed=2,"�"}}(this,e);return void 0!==r?r: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 u(e,t){if((e.length-t)%2==0){var r=e.toString("utf16le",t);if(r){var n=r.charCodeAt(r.length-1);if(55296<=n&&n<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=e[e.length-2],this.lastChar[1]=e[e.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=e[e.length-1],e.toString("utf16le",t,e.length-1)}function f(e){var t=e&&e.length?this.write(e):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return t+this.lastChar.toString("utf16le",0,r)}return t}function c(e,t){var r=(e.length-t)%3;return 0===r?e.toString("base64",t):(this.lastNeed=3-r,this.lastTotal=3,1===r?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-r))}function h(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function d(e){return e.toString(this.encoding)}function l(e){return e&&e.length?this.write(e):""}(r.StringDecoder=o).prototype.write=function(e){if(0===e.length)return"";var t,r;if(this.lastNeed){if(void 0===(t=this.fillLast(e)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r<e.length?t?t+this.text(e,r):this.text(e,r):t||""},o.prototype.end=function(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+"�":t},o.prototype.text=function(e,t){var r=function(e,t,r){var n=t.length-1;if(n<r)return 0;var i=s(t[n]);if(0<=i)return 0<i&&(e.lastNeed=i-1),i;if(--n<r||-2===i)return 0;if(0<=(i=s(t[n])))return 0<i&&(e.lastNeed=i-2),i;if(--n<r||-2===i)return 0;if(0<=(i=s(t[n])))return 0<i&&(2===i?i=0:e.lastNeed=i-3),i;return 0}(this,e,t);if(!this.lastNeed)return e.toString("utf8",t);this.lastTotal=r;var n=e.length-(r-this.lastNeed);return e.copy(this.lastChar,0,n),e.toString("utf8",t,n)},o.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}},{"safe-buffer":149}],164:[function(u,e,f){(function(e,t){var n=u("process/browser.js").nextTick,r=Function.prototype.apply,i=Array.prototype.slice,o={},s=0;function a(e,t){this._id=e,this._clearFn=t}f.setTimeout=function(){return new a(r.call(setTimeout,window,arguments),clearTimeout)},f.setInterval=function(){return new a(r.call(setInterval,window,arguments),clearInterval)},f.clearTimeout=f.clearInterval=function(e){e.close()},a.prototype.unref=a.prototype.ref=function(){},a.prototype.close=function(){this._clearFn.call(window,this._id)},f.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},f.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},f._unrefActive=f.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;0<=t&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},f.setImmediate="function"==typeof e?e:function(e){var t=s++,r=!(arguments.length<2)&&i.call(arguments,1);return o[t]=!0,n(function(){o[t]&&(r?e.apply(null,r):e.call(null),f.clearImmediate(t))}),t},f.clearImmediate="function"==typeof t?t:function(e){delete o[e]}}).call(this,u("timers").setImmediate,u("timers").clearImmediate)},{"process/browser.js":122,timers:164}],165:[function(e,t,r){var i=e("buffer").Buffer;t.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(i.isBuffer(e)){for(var t=new Uint8Array(e.length),r=e.length,n=0;n<r;n++)t[n]=e[n];return t.buffer}throw new Error("Argument must be a Buffer")}},{buffer:48}],166:[function(e,t,r){var P=e("punycode"),R=e("./util");function A(){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}r.parse=o,r.resolve=function(e,t){return o(e,!1,!0).resolve(t)},r.resolveObject=function(e,t){return e?o(e,!1,!0).resolveObject(t):t},r.format=function(e){R.isString(e)&&(e=o(e));return e instanceof A?e.format():A.prototype.format.call(e)},r.Url=A;var O=/^([a-z0-9.+-]+:)/i,n=/:[0-9]*$/,N=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,i=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),L=["'"].concat(i),q=["%","/","?",";","#"].concat(L),D=["/","?","#"],F=/^[+a-z0-9A-Z_-]{0,63}$/,U=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,H={javascript:!0,"javascript:":!0},z={javascript:!0,"javascript:":!0},K={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},W=e("querystring");function o(e,t,r){if(e&&R.isObject(e)&&e instanceof A)return e;var n=new A;return n.parse(e,t,r),n}A.prototype.parse=function(e,t,r){if(!R.isString(e))throw new TypeError("Parameter 'url' must be a string, not "+(void 0===e?"undefined":_typeof(e)));var n=e.indexOf("?"),i=-1!==n&&n<e.indexOf("#")?"?":"#",o=e.split(i);o[0]=o[0].replace(/\\/g,"/");var s=e=o.join(i);if(s=s.trim(),!r&&1===e.split("#").length){var a=N.exec(s);if(a)return this.path=s,this.href=s,this.pathname=a[1],a[2]?(this.search=a[2],this.query=t?W.parse(this.search.substr(1)):this.search.substr(1)):t&&(this.search="",this.query={}),this}var u=O.exec(s);if(u){var f=(u=u[0]).toLowerCase();this.protocol=f,s=s.substr(u.length)}if(r||u||s.match(/^\/\/[^@\/]+@[^@\/]+/)){var c="//"===s.substr(0,2);!c||u&&z[u]||(s=s.substr(2),this.slashes=!0)}if(!z[u]&&(c||u&&!K[u])){for(var h,d,l=-1,p=0;p<D.length;p++){-1!==(b=s.indexOf(D[p]))&&(-1===l||b<l)&&(l=b)}-1!==(d=-1===l?s.lastIndexOf("@"):s.lastIndexOf("@",l))&&(h=s.slice(0,d),s=s.slice(d+1),this.auth=decodeURIComponent(h)),l=-1;for(p=0;p<q.length;p++){var b;-1!==(b=s.indexOf(q[p]))&&(-1===l||b<l)&&(l=b)}-1===l&&(l=s.length),this.host=s.slice(0,l),s=s.slice(l),this.parseHost(),this.hostname=this.hostname||"";var m="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!m)for(var y=this.hostname.split(/\./),v=(p=0,y.length);p<v;p++){var g=y[p];if(g&&!g.match(F)){for(var w="",_=0,M=g.length;_<M;_++)127<g.charCodeAt(_)?w+="x":w+=g[_];if(!w.match(F)){var x=y.slice(0,p),k=y.slice(p+1),S=g.match(U);S&&(x.push(S[1]),k.unshift(S[2])),k.length&&(s="/"+k.join(".")+s),this.hostname=x.join(".");break}}}255<this.hostname.length?this.hostname="":this.hostname=this.hostname.toLowerCase(),m||(this.hostname=P.toASCII(this.hostname));var E=this.port?":"+this.port:"",A=this.hostname||"";this.host=A+E,this.href+=this.host,m&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==s[0]&&(s="/"+s))}if(!H[f])for(p=0,v=L.length;p<v;p++){var j=L[p];if(-1!==s.indexOf(j)){var I=encodeURIComponent(j);I===j&&(I=escape(j)),s=s.split(j).join(I)}}var B=s.indexOf("#");-1!==B&&(this.hash=s.substr(B),s=s.slice(0,B));var T=s.indexOf("?");if(-1!==T?(this.search=s.substr(T),this.query=s.substr(T+1),t&&(this.query=W.parse(this.query)),s=s.slice(0,T)):t&&(this.search="",this.query={}),s&&(this.pathname=s),K[f]&&this.hostname&&!this.pathname&&(this.pathname="/"),this.pathname||this.search){E=this.pathname||"";var C=this.search||"";this.path=E+C}return this.href=this.format(),this},A.prototype.format=function(){var e=this.auth||"";e&&(e=(e=encodeURIComponent(e)).replace(/%3A/i,":"),e+="@");var t=this.protocol||"",r=this.pathname||"",n=this.hash||"",i=!1,o="";this.host?i=e+this.host:this.hostname&&(i=e+(-1===this.hostname.indexOf(":")?this.hostname:"["+this.hostname+"]"),this.port&&(i+=":"+this.port)),this.query&&R.isObject(this.query)&&Object.keys(this.query).length&&(o=W.stringify(this.query));var s=this.search||o&&"?"+o||"";return t&&":"!==t.substr(-1)&&(t+=":"),this.slashes||(!t||K[t])&&!1!==i?(i="//"+(i||""),r&&"/"!==r.charAt(0)&&(r="/"+r)):i||(i=""),n&&"#"!==n.charAt(0)&&(n="#"+n),s&&"?"!==s.charAt(0)&&(s="?"+s),t+i+(r=r.replace(/[?#]/g,function(e){return encodeURIComponent(e)}))+(s=s.replace("#","%23"))+n},A.prototype.resolve=function(e){return this.resolveObject(o(e,!1,!0)).format()},A.prototype.resolveObject=function(e){if(R.isString(e)){var t=new A;t.parse(e,!1,!0),e=t}for(var r=new A,n=Object.keys(this),i=0;i<n.length;i++){var o=n[i];r[o]=this[o]}if(r.hash=e.hash,""===e.href)return r.href=r.format(),r;if(e.slashes&&!e.protocol){for(var s=Object.keys(e),a=0;a<s.length;a++){var u=s[a];"protocol"!==u&&(r[u]=e[u])}return K[r.protocol]&&r.hostname&&!r.pathname&&(r.path=r.pathname="/"),r.href=r.format(),r}if(e.protocol&&e.protocol!==r.protocol){if(!K[e.protocol]){for(var f=Object.keys(e),c=0;c<f.length;c++){var h=f[c];r[h]=e[h]}return r.href=r.format(),r}if(r.protocol=e.protocol,e.host||z[e.protocol])r.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(""),r.pathname=d.join("/")}if(r.search=e.search,r.query=e.query,r.host=e.host||"",r.auth=e.auth,r.hostname=e.hostname||e.host,r.port=e.port,r.pathname||r.search){var l=r.pathname||"",p=r.search||"";r.path=l+p}return r.slashes=r.slashes||e.slashes,r.href=r.format(),r}var b=r.pathname&&"/"===r.pathname.charAt(0),m=e.host||e.pathname&&"/"===e.pathname.charAt(0),y=m||b||r.host&&e.pathname,v=y,g=r.pathname&&r.pathname.split("/")||[],w=(d=e.pathname&&e.pathname.split("/")||[],r.protocol&&!K[r.protocol]);if(w&&(r.hostname="",r.port=null,r.host&&(""===g[0]?g[0]=r.host:g.unshift(r.host)),r.host="",e.protocol&&(e.hostname=null,e.port=null,e.host&&(""===d[0]?d[0]=e.host:d.unshift(e.host)),e.host=null),y=y&&(""===d[0]||""===g[0])),m)r.host=e.host||""===e.host?e.host:r.host,r.hostname=e.hostname||""===e.hostname?e.hostname:r.hostname,r.search=e.search,r.query=e.query,g=d;else if(d.length)g||(g=[]),g.pop(),g=g.concat(d),r.search=e.search,r.query=e.query;else if(!R.isNullOrUndefined(e.search)){if(w)r.hostname=r.host=g.shift(),(S=!!(r.host&&0<r.host.indexOf("@"))&&r.host.split("@"))&&(r.auth=S.shift(),r.host=r.hostname=S.shift());return r.search=e.search,r.query=e.query,R.isNull(r.pathname)&&R.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!g.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var _=g.slice(-1)[0],M=(r.host||e.host||1<g.length)&&("."===_||".."===_)||""===_,x=0,k=g.length;0<=k;k--)"."===(_=g[k])?g.splice(k,1):".."===_?(g.splice(k,1),x++):x&&(g.splice(k,1),x--);if(!y&&!v)for(;x--;x)g.unshift("..");!y||""===g[0]||g[0]&&"/"===g[0].charAt(0)||g.unshift(""),M&&"/"!==g.join("/").substr(-1)&&g.push("");var S,E=""===g[0]||g[0]&&"/"===g[0].charAt(0);w&&(r.hostname=r.host=E?"":g.length?g.shift():"",(S=!!(r.host&&0<r.host.indexOf("@"))&&r.host.split("@"))&&(r.auth=S.shift(),r.host=r.hostname=S.shift()));return(y=y||r.host&&g.length)&&!E&&g.unshift(""),g.length?r.pathname=g.join("/"):(r.pathname=null,r.path=null),R.isNull(r.pathname)&&R.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=e.auth||r.auth,r.slashes=r.slashes||e.slashes,r.href=r.format(),r},A.prototype.parseHost=function(){var e=this.host,t=n.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)}},{"./util":167,punycode:129,querystring:132}],167:[function(e,t,r){t.exports={isString:function(e){return"string"==typeof e},isObject:function(e){return"object"===(void 0===e?"undefined":_typeof(e))&&null!==e},isNull:function(e){return null===e},isNullOrUndefined:function(e){return null==e}}},{}],168:[function(e,t,r){(function(r){function n(e){try{if(!r.localStorage)return!1}catch(e){return!1}var t=r.localStorage[e];return null!=t&&"true"===String(t).toLowerCase()}t.exports=function(e,t){if(n("noDeprecation"))return e;var r=!1;return function(){if(!r){if(n("throwDeprecation"))throw new Error(t);n("traceDeprecation")?console.trace(t):console.warn(t),r=!0}return e.apply(this,arguments)}}}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],169:[function(require,module,exports){var indexOf=require("indexof"),Object_keys=function(e){if(Object.keys)return Object.keys(e);var t=[];for(var r in e)t.push(r);return t},forEach=function(e,t){if(e.forEach)return e.forEach(t);for(var r=0;r<e.length;r++)t(e[r],r,e)},defineProp=function(){try{return Object.defineProperty({},"_",{}),function(e,t,r){Object.defineProperty(e,t,{writable:!0,enumerable:!1,configurable:!0,value:r})}}catch(e){return function(e,t,r){e[t]=r}}}(),globals=["Array","Boolean","Date","Error","EvalError","Function","Infinity","JSON","Math","NaN","Number","Object","RangeError","ReferenceError","RegExp","String","SyntaxError","TypeError","URIError","decodeURI","decodeURIComponent","encodeURI","encodeURIComponent","escape","eval","isFinite","isNaN","parseFloat","parseInt","undefined","unescape"];function Context(){}Context.prototype={};var Script=exports.Script=function(e){if(!(this instanceof Script))return new Script(e);this.code=e};Script.prototype.runInContext=function(t){if(!(t instanceof Context))throw new TypeError("needs a 'context' argument.");var e=document.createElement("iframe");e.style||(e.style={}),e.style.display="none",document.body.appendChild(e);var r=e.contentWindow,n=r.eval,i=r.execScript;!n&&i&&(i.call(r,"null"),n=r.eval),forEach(Object_keys(t),function(e){r[e]=t[e]}),forEach(globals,function(e){t[e]&&(r[e]=t[e])});var o=Object_keys(r),s=n.call(r,this.code);return forEach(Object_keys(r),function(e){(e in t||-1===indexOf(o,e))&&(t[e]=r[e])}),forEach(globals,function(e){e in t||defineProp(t,e,r[e])}),document.body.removeChild(e),s},Script.prototype.runInThisContext=function(){return eval(this.code)},Script.prototype.runInNewContext=function(t){var r=Script.createContext(t),e=this.runInContext(r);return forEach(Object_keys(r),function(e){t[e]=r[e]}),e},forEach(Object_keys(Script.prototype),function(r){exports[r]=Script[r]=function(e){var t=Script(e);return t[r].apply(t,[].slice.call(arguments,1))}}),exports.createScript=function(e){return exports.Script(e)},exports.createContext=Script.createContext=function(t){var r=new Context;return"object"===(void 0===t?"undefined":_typeof(t))&&forEach(Object_keys(t),function(e){r[e]=t[e]}),r}},{indexof:102}],170:[function(e,t,r){t.exports=function(){for(var e={},t=0;t<arguments.length;t++){var r=arguments[t];for(var n in r)i.call(r,n)&&(e[n]=r[n])}return e};var i=Object.prototype.hasOwnProperty},{}],171:[function(e,t,r){var n="%[a-f0-9]{2}",i=new RegExp(n,"gi"),a=new RegExp("("+n+")+","gi");function o(e,t){try{return decodeURIComponent(e.join(""))}catch(e){}if(1===e.length)return e;t=t||1;var r=e.slice(0,t),n=e.slice(t);return Array.prototype.concat.call([],o(r),o(n))}function u(t){try{return decodeURIComponent(t)}catch(e){for(var r=t.match(i),n=1;n<r.length;n++)r=(t=o(r,n).join("")).match(i);return t}}t.exports=function(t){if("string"!=typeof t)throw new TypeError("Expected `encodedURI` to be of type `string`, got `"+(void 0===t?"undefined":_typeof(t))+"`");try{return t=t.replace(/\+/g," "),decodeURIComponent(t)}catch(e){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},r=a.exec(e);r;){try{t[r[0]]=decodeURIComponent(r[0])}catch(e){var n=u(r[0]);n!==r[0]&&(t[r[0]]=n)}r=a.exec(e)}t["%C2"]="�";for(var i=Object.keys(t),o=0;o<i.length;o++){var s=i[o];e=e.replace(new RegExp(s,"g"),t[s])}return e}(t)}}},{}],172:[function(e,t,r){var n=function(e,t){for(var r=[],n=0;n<e;++n)r.push(t(n));return r};t.exports={generate:n,replicate:function(e,t){return n(e,function(){return t})},concat:function(e,t){return e.concat(t)},flatten:function(e){for(var t=[],r=0,n=e.length;r<n;++r)for(var i=0,o=e[r].length;i<o;++i)t.push(e[r][i]);return t},chunksOf:function(e,t){for(var r=[],n=0,i=t.length;n<i;n+=e)r.push(t.slice(n,n+e));return r}}},{}],173:[function(i,e,t){i("./array.js");var o=function(e,t){return parseInt(e.slice(2*t+2,2*t+4),16)},s=function(e){return(e.length-2)/2},r=function(e){for(var t=[],r=2,n=e.length;r<n;r+=2)t.push(parseInt(e.slice(r,r+2),16));return t},n=function(e){for(var t="0x",r=0,n=e.length;r<n;++r){var i=e[r];t+=(i<16?"0":"")+i.toString(16)}return t};e.exports={random:function(e){var t=void 0;if("undefined"!=typeof window&&window.crypto&&window.crypto.getRandomValues)t=window.crypto.getRandomValues(new Uint8Array(e));else{if(void 0===i)throw"Safe random numbers not available.";t=i("crypto").randomBytes(e)}for(var r="0x",n=0;n<e;++n)r+=("00"+t[n].toString(16)).slice(-2);return r},length:s,concat:function(e,t){return e.concat(t.slice(2))},flatten:function(e){return"0x"+e.reduce(function(e,t){return e+t.slice(2)},"")},slice:function(e,t,r){return"0x"+r.slice(2*e+2,2*t+2)},reverse:function(e){for(var t="0x",r=0,n=s(e);r<n;++r)t+=e.slice(2*(n-r),2*(n-r+1));return t},pad:function e(t,r){return r.length===2*t+2?r:e(t,"0x0"+r.slice(2))},padRight:function e(t,r){return r.length===2*t+2?r:e(t,r+"0")},fromAscii:function(e){for(var t="0x",r=0;r<e.length;++r)t+=("00"+e.charCodeAt(r).toString(16)).slice(-2);return t},toAscii:function(e){for(var t="",r=2;r<e.length;r+=2)t+=String.fromCharCode(parseInt(e.slice(r,r+2),16));return t},fromString:function(e){for(var t=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},r="0x",n=0;n!=e.length;n++){var i=e.charCodeAt(n);if(i<128)r+=t(i);else{if(i<2048)r+=t(i>>6|192);else{if(55295<i&&i<56320){if(++n==e.length)return null;var o=e.charCodeAt(n);if(o<56320||57343<o)return null;r+=t((i=65536+((1023&i)<<10)+(1023&o))>>18|240),r+=t(i>>12&63|128)}else r+=t(i>>12|224);r+=t(i>>6&63|128)}r+=t(63&i|128)}}return r},toString:function(e){for(var t="",r=0,n=s(e);r<n;){var i=o(e,r++);if(127<i){if(191<i&&i<224){if(n<=r)return null;i=(31&i)<<6|63&o(e,r)}else if(223<i&&i<240){if(n<=r+1)return null;i=(15&i)<<12|(63&o(e,r))<<6|63&o(e,++r)}else{if(!(239<i&&i<248))return null;if(n<=r+2)return null;i=(7&i)<<18|(63&o(e,r))<<12|(63&o(e,++r))<<6|63&o(e,++r)}++r}if(i<=65535)t+=String.fromCharCode(i);else{if(!(i<=1114111))return null;i-=65536,t+=String.fromCharCode(i>>10|55296),t+=String.fromCharCode(1023&i|56320)}}return t},fromNumber:function(e){var t=e.toString(16);return t.length%2==0?"0x"+t:"0x0"+t},toNumber:function(e){return parseInt(e.slice(2),16)},fromNat:function(e){return"0x0"===e?"0x":e.length%2==0?e:"0x0"+e.slice(2)},toNat:function(e){return"0"===e[2]?"0x"+e.slice(3):e},fromArray:n,toArray:r,fromUint8Array:function(e){return n([].slice.call(e,0))},toUint8Array:function(e){return new Uint8Array(r(e))}}},{"./array.js":172}],174:[function(e,t,r){var p="0123456789abcdef".split(""),b=[1,256,65536,16777216],m=[0,8,16,24],ce=[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],y=function(e){var t,r,n,i,o,s,a,u,f,c,h,d,l,p,b,m,y,v,g,w,_,M,x,k,S,E,A,j,I,B,T,C,P,R,O,N,L,q,D,F,U,H,z,K,W,V,X,G,J,Z,$,Y,Q,ee,te,re,ne,ie,oe,se,ae,ue,fe;for(n=0;n<48;n+=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],u=e[4]^e[14]^e[24]^e[34]^e[44],f=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],t=(d=e[8]^e[18]^e[28]^e[38]^e[48])^(s<<1|a>>>31),r=(l=e[9]^e[19]^e[29]^e[39]^e[49])^(a<<1|s>>>31),e[0]^=t,e[1]^=r,e[10]^=t,e[11]^=r,e[20]^=t,e[21]^=r,e[30]^=t,e[31]^=r,e[40]^=t,e[41]^=r,t=i^(u<<1|f>>>31),r=o^(f<<1|u>>>31),e[2]^=t,e[3]^=r,e[12]^=t,e[13]^=r,e[22]^=t,e[23]^=r,e[32]^=t,e[33]^=r,e[42]^=t,e[43]^=r,t=s^(c<<1|h>>>31),r=a^(h<<1|c>>>31),e[4]^=t,e[5]^=r,e[14]^=t,e[15]^=r,e[24]^=t,e[25]^=r,e[34]^=t,e[35]^=r,e[44]^=t,e[45]^=r,t=u^(d<<1|l>>>31),r=f^(l<<1|d>>>31),e[6]^=t,e[7]^=r,e[16]^=t,e[17]^=r,e[26]^=t,e[27]^=r,e[36]^=t,e[37]^=r,e[46]^=t,e[47]^=r,t=c^(i<<1|o>>>31),r=h^(o<<1|i>>>31),e[8]^=t,e[9]^=r,e[18]^=t,e[19]^=r,e[28]^=t,e[29]^=r,e[38]^=t,e[39]^=r,e[48]^=t,e[49]^=r,p=e[0],b=e[1],V=e[11]<<4|e[10]>>>28,X=e[10]<<4|e[11]>>>28,j=e[20]<<3|e[21]>>>29,I=e[21]<<3|e[20]>>>29,se=e[31]<<9|e[30]>>>23,ae=e[30]<<9|e[31]>>>23,H=e[40]<<18|e[41]>>>14,z=e[41]<<18|e[40]>>>14,R=e[2]<<1|e[3]>>>31,O=e[3]<<1|e[2]>>>31,m=e[13]<<12|e[12]>>>20,y=e[12]<<12|e[13]>>>20,G=e[22]<<10|e[23]>>>22,J=e[23]<<10|e[22]>>>22,B=e[33]<<13|e[32]>>>19,T=e[32]<<13|e[33]>>>19,ue=e[42]<<2|e[43]>>>30,fe=e[43]<<2|e[42]>>>30,ee=e[5]<<30|e[4]>>>2,te=e[4]<<30|e[5]>>>2,N=e[14]<<6|e[15]>>>26,L=e[15]<<6|e[14]>>>26,v=e[25]<<11|e[24]>>>21,g=e[24]<<11|e[25]>>>21,Z=e[34]<<15|e[35]>>>17,$=e[35]<<15|e[34]>>>17,C=e[45]<<29|e[44]>>>3,P=e[44]<<29|e[45]>>>3,k=e[6]<<28|e[7]>>>4,S=e[7]<<28|e[6]>>>4,re=e[17]<<23|e[16]>>>9,ne=e[16]<<23|e[17]>>>9,q=e[26]<<25|e[27]>>>7,D=e[27]<<25|e[26]>>>7,w=e[36]<<21|e[37]>>>11,_=e[37]<<21|e[36]>>>11,Y=e[47]<<24|e[46]>>>8,Q=e[46]<<24|e[47]>>>8,K=e[8]<<27|e[9]>>>5,W=e[9]<<27|e[8]>>>5,E=e[18]<<20|e[19]>>>12,A=e[19]<<20|e[18]>>>12,ie=e[29]<<7|e[28]>>>25,oe=e[28]<<7|e[29]>>>25,F=e[38]<<8|e[39]>>>24,U=e[39]<<8|e[38]>>>24,M=e[48]<<14|e[49]>>>18,x=e[49]<<14|e[48]>>>18,e[0]=p^~m&v,e[1]=b^~y&g,e[10]=k^~E&j,e[11]=S^~A&I,e[20]=R^~N&q,e[21]=O^~L&D,e[30]=K^~V&G,e[31]=W^~X&J,e[40]=ee^~re&ie,e[41]=te^~ne&oe,e[2]=m^~v&w,e[3]=y^~g&_,e[12]=E^~j&B,e[13]=A^~I&T,e[22]=N^~q&F,e[23]=L^~D&U,e[32]=V^~G&Z,e[33]=X^~J&$,e[42]=re^~ie&se,e[43]=ne^~oe&ae,e[4]=v^~w&M,e[5]=g^~_&x,e[14]=j^~B&C,e[15]=I^~T&P,e[24]=q^~F&H,e[25]=D^~U&z,e[34]=G^~Z&Y,e[35]=J^~$&Q,e[44]=ie^~se&ue,e[45]=oe^~ae&fe,e[6]=w^~M&p,e[7]=_^~x&b,e[16]=B^~C&k,e[17]=T^~P&S,e[26]=F^~H&R,e[27]=U^~z&O,e[36]=Z^~Y&K,e[37]=$^~Q&W,e[46]=se^~ue&ee,e[47]=ae^~fe&te,e[8]=M^~p&m,e[9]=x^~b&y,e[18]=C^~k&E,e[19]=P^~S&A,e[28]=H^~R&N,e[29]=z^~O&L,e[38]=Y^~K&V,e[39]=Q^~W&X,e[48]=ue^~ee&re,e[49]=fe^~te&ne,e[0]^=ce[n],e[1]^=ce[n+1]},n=function(s){return function(e){var t,r,n;if("0x"===e.slice(0,2)){t=[];for(var i=2,o=e.length;i<o;i+=2)t.push(parseInt(e.slice(i,i+2),16))}else t=e;return function(e,t){for(var r,n=t.length,i=e.blocks,o=e.blockCount<<2,s=e.blockCount,a=e.outputBlocks,u=e.s,f=0;f<n;){if(e.reset)for(e.reset=!1,i[0]=e.block,d=1;d<s+1;++d)i[d]=0;if("string"!=typeof t)for(d=e.start;f<n&&d<o;++f)i[d>>2]|=t[f]<<m[3&d++];else for(d=e.start;f<n&&d<o;++f)(r=t.charCodeAt(f))<128?i[d>>2]|=r<<m[3&d++]:(r<2048?i[d>>2]|=(192|r>>6)<<m[3&d++]:(r<55296||57344<=r?i[d>>2]|=(224|r>>12)<<m[3&d++]:(r=65536+((1023&r)<<10|1023&t.charCodeAt(++f)),i[d>>2]|=(240|r>>18)<<m[3&d++],i[d>>2]|=(128|r>>12&63)<<m[3&d++]),i[d>>2]|=(128|r>>6&63)<<m[3&d++]),i[d>>2]|=(128|63&r)<<m[3&d++]);if(o<=(e.lastByteIndex=d)){for(e.start=d-o,e.block=i[s],d=0;d<s;++d)u[d]^=i[d];y(u),e.reset=!0}else e.start=d}if(i[(d=e.lastByteIndex)>>2]|=b[3&d],e.lastByteIndex===o)for(i[0]=i[s],d=1;d<s+1;++d)i[d]=0;for(i[s-1]|=2147483648,d=0;d<s;++d)u[d]^=i[d];y(u);for(var c,h="",d=0,l=0;l<a;){for(d=0;d<s&&l<a;++d,++l)c=u[d],h+=p[c>>4&15]+p[15&c]+p[c>>12&15]+p[c>>8&15]+p[c>>20&15]+p[c>>16&15]+p[c>>28&15]+p[c>>24&15];l%s==0&&(y(u),d=0)}return"0x"+h}({blocks:[],reset:!0,block:0,start:0,blockCount:1600-((r=s)<<1)>>5,outputBlocks:r>>5,s:(n=[0,0,0,0,0,0,0,0,0,0],[].concat(n,n,n,n,n))},t)}};t.exports={keccak256:n(256),keccak512:n(512),keccak256s:n(256),keccak512s:n(512)}},{}],175:[function(e,t,r){var n=e("is-function");t.exports=function(e,t,r){if(!n(t))throw new TypeError("iterator must be a function");arguments.length<3&&(r=this);"[object Array]"===i.call(e)?function(e,t,r){for(var n=0,i=e.length;n<i;n++)o.call(e,n)&&t.call(r,e[n],n,e)}(e,t,r):"string"==typeof e?function(e,t,r){for(var n=0,i=e.length;n<i;n++)t.call(r,e.charAt(n),n,e)}(e,t,r):function(e,t,r){for(var n in e)o.call(e,n)&&t.call(r,e[n],n,e)}(e,t,r)};var i=Object.prototype.toString,o=Object.prototype.hasOwnProperty},{"is-function":177}],176:[function(e,r,t){(function(e){var t;t="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},r.exports=t}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],177:[function(e,t,r){t.exports=function(e){var t=n.call(e);return"[object Function]"===t||"function"==typeof e&&"[object RegExp]"!==t||"undefined"!=typeof window&&(e===window.setTimeout||e===window.alert||e===window.confirm||e===window.prompt)};var n=Object.prototype.toString},{}],178:[function(e,t,r){var u=Object.getOwnPropertySymbols,f=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable;t.exports=function(){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={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach(function(e){n[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var r,n,i=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),o=1;o<arguments.length;o++){for(var s in r=Object(arguments[o]))f.call(r,s)&&(i[s]=r[s]);if(u){n=u(r);for(var a=0;a<n.length;a++)c.call(r,n[a])&&(i[n[a]]=r[n[a]])}}return i}},{}],179:[function(e,t,r){var s=e("trim"),n=e("for-each");t.exports=function(e){if(!e)return{};var o={};return n(s(e).split("\n"),function(e){var t,r=e.indexOf(":"),n=s(e.slice(0,r)).toLowerCase(),i=s(e.slice(r+1));void 0===o[n]?o[n]=i:(t=o[n],"[object Array]"===Object.prototype.toString.call(t)?o[n].push(i):o[n]=[o[n],i])}),o}},{"for-each":175,trim:186}],180:[function(e,t,r){var n=e("strict-uri-encode"),s=e("object-assign"),a=e("decode-uri-component");function u(e,t){return t.encode?t.strict?n(e):encodeURIComponent(e):e}function i(e){var t=e.indexOf("?");return-1===t?"":e.slice(t+1)}function o(e,t){var i=function(e){var n;switch(e.arrayFormat){case"index":return function(e,t,r){n=/\[(\d*)\]$/.exec(e),e=e.replace(/\[\d*\]$/,""),n?(void 0===r[e]&&(r[e]={}),r[e][n[1]]=t):r[e]=t};case"bracket":return function(e,t,r){n=/(\[\])$/.exec(e),e=e.replace(/\[\]$/,""),n?void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=[t]:r[e]=t};default:return function(e,t,r){void 0!==r[e]?r[e]=[].concat(r[e],t):r[e]=t}}}(t=s({arrayFormat:"none"},t)),o=Object.create(null);return"string"!=typeof e?o:(e=e.trim().replace(/^[?#&]/,""))?(e.split("&").forEach(function(e){var t=e.replace(/\+/g," ").split("="),r=t.shift(),n=0<t.length?t.join("="):void 0;n=void 0===n?null:a(n),i(a(r),n,o)}),Object.keys(o).sort().reduce(function(e,t){var r=o[t];return Boolean(r)&&"object"===(void 0===r?"undefined":_typeof(r))&&!Array.isArray(r)?e[t]=function e(t){return Array.isArray(t)?t.sort():"object"===(void 0===t?"undefined":_typeof(t))?e(Object.keys(t)).sort(function(e,t){return Number(e)-Number(t)}).map(function(e){return t[e]}):t}(r):e[t]=r,e},Object.create(null))):o}r.extract=i,r.parse=o,r.stringify=function(n,i){!1===(i=s({encode:!0,strict:!0,arrayFormat:"none"},i)).sort&&(i.sort=function(){});var o=function(n){switch(n.arrayFormat){case"index":return function(e,t,r){return null===t?[u(e,n),"[",r,"]"].join(""):[u(e,n),"[",u(r,n),"]=",u(t,n)].join("")};case"bracket":return function(e,t){return null===t?u(e,n):[u(e,n),"[]=",u(t,n)].join("")};default:return function(e,t){return null===t?u(e,n):[u(e,n),"=",u(t,n)].join("")}}}(i);return n?Object.keys(n).sort(i.sort).map(function(t){var e=n[t];if(void 0===e)return"";if(null===e)return u(t,i);if(Array.isArray(e)){var r=[];return e.slice().forEach(function(e){void 0!==e&&r.push(o(t,e,r.length))}),r.join("&")}return u(t,i)+"="+u(e,i)}).filter(function(e){return 0<e.length}).join("&"):""},r.parseUrl=function(e,t){return{url:e.split("?")[0]||"",query:o(i(e),t)}}},{"decode-uri-component":171,"object-assign":178,"strict-uri-encode":181}],181:[function(e,t,r){t.exports=function(e){return encodeURIComponent(e).replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}},{}],182:[function(e,t,r){var n=function(){throw"This swarm.js function isn't available on the browser."},i={readFile:n},o={download:n,safeDownloadArchived:n,directoryTree:n},s={platform:n,arch:n},a={join:n,slice:n},u={spawn:n},f={lookup:n},c=e("xhr-request-promise"),h=e("eth-lib/lib/bytes"),d=e("./swarm-hash.js"),l=e("./pick.js"),p=e("./swarm");t.exports=p({fsp:i,files:o,os:s,path:a,child_process:u,defaultArchives:{},mimetype:f,request:c,downloadUrl:null,bytes:h,hash:d,pick:l})},{"./pick.js":183,"./swarm":185,"./swarm-hash.js":184,"eth-lib/lib/bytes":173,"xhr-request-promise":189}],183:[function(e,t,r){var n=function(f){return function(){return new Promise(function(u,e){var t=function(e){var o={},s=e.target.files.length,a=0;[].map.call(e.target.files,function(i){var e=new FileReader;e.onload=function(e){var t=new Uint8Array(e.target.result);if("directory"===f){var r=i.webkitRelativePath;o[r.slice(r.indexOf("/")+1)]={type:"text/plain",data:t},++a===s&&u(o)}else if("file"===f){var n=i.webkitRelativePath;u({type:mimetype.lookup(n),data:t})}else u(t)},e.readAsArrayBuffer(i)})},r=void 0;"directory"===f?((r=document.createElement("input")).addEventListener("change",t),r.type="file",r.webkitdirectory=!0,r.mozdirectory=!0,r.msdirectory=!0,r.odirectory=!0,r.directory=!0):((r=document.createElement("input")).addEventListener("change",t),r.type="file");var n=document.createEvent("MouseEvents");n.initEvent("click",!0,!1),r.dispatchEvent(n)})}};t.exports={data:n("data"),file:n("file"),directory:n("directory")}},{}],184:[function(e,t,r){var i=e("eth-lib/lib/hash").keccak256,a=e("eth-lib/lib/bytes"),u=function(e,t){var r=a.reverse(a.pad(6,a.fromNumber(e))),n=a.flatten([r,"0x0000",t]);return i(n).slice(2)};t.exports=function e(t){"string"==typeof t&&"0x"!==t.slice(0,2)?t=a.fromString(t):"string"!=typeof t&&void 0!==t.length&&(t=a.fromUint8Array(t));var r=a.length(t);if(r<=4096)return u(r,t);for(var n=4096;128*n<r;)n*=128;for(var i=[],o=0;o<r;o+=n){var s=n<r-o?n:r-o;i.push(e(a.slice(t,o,o+s)))}return u(r,a.flatten(i))}},{"eth-lib/lib/bytes":173,"eth-lib/lib/hash":174}],185:[function(e,t,r){t.exports=function(e){var o=e.fsp,a=e.files,u=e.os,s=e.path,p=e.child_process,f=e.mimetype,c=e.defaultArchives,h=e.request,d=e.downloadUrl,t=e.bytes,n=e.hash,i=e.pick,l=function(i){return function(e){for(var t={},r=0,n=i.length;r<n;++r)t[i[r]]=e[r];return t}},b=function(t){return function(e){return t+"/bzzr:/"+e}},m=function(t){return function(e){return h(b(t)(e),{responseType:"arraybuffer"}).then(function(e){var r,t=new Uint8Array(e);if(r=t,function(e){if(r.length!==e.length)return!1;var t=0;for(r.length;t<r;++t)if(r[t]!==e[t])return!1;return!0}([52,48,52,32,112,97,103,101,32,110,111,116,32,102,111,117,110,100,10]))throw"Error 404.";return t})}},y=function(r){return function(e){return function a(e){return function(s){return function(o){var t=function(e){return void 0===e.path?Promise.resolve():"application/bzz-manifest+json"===e.contentType?a(e.hash)(s+e.path)(o):Promise.resolve((i=s+e.path,r={type:(n=e).contentType,hash:n.hash},(t=o)[i]=r,t));var t,r,n,i};return m(r)(e).then(function(e){return JSON.parse(N(e)).entries}).then(function(e){return Promise.all(e.map(t))}).then(function(){return o})}}}(e)("")({})}},v=function(t){return function(e){return y(t)(e).then(function(t){return l(Object.keys(t))(Object.keys(t).map(function(e){return t[e].hash}))})}},g=function(o){return function(e){return y(o)(e).then(function(t){var r=Object.keys(t),e=r.map(function(e){return t[e].hash}),n=r.map(function(e){return t[e].type}),i=e.map(m(o));return Promise.all(i).then(function(e){return l(r)(e.map(function(e,t){return{type:n[t],data:e}}))})})}},w=function(r){return function(t){return function(e){return a.download(b(r)(t))(e)}}},_=function(o){return function(e){return function(i){return v(o)(e).then(function(e){var t=[];for(var r in e)if(0<r.length){var n=s.join(i,r);t.push(w(o)(e[r])(n))}return Promise.all(t).then(function(){return i})})}}},M=function(t){return function(e){return h(t+"/bzzr:/",{body:"string"==typeof e?L(e):e,method:"POST"})}},x=function(u){return function(a){return function(s){return function(o){return function t(r){var e="/"===s[0]?s:"/"+s,n=u+"/bzz:/"+a+e,i={method:"PUT",headers:{"Content-Type":o.type},body:o.data};return h(n,i).then(function(e){if(-1!==e.indexOf("error"))throw e;return e}).catch(function(e){return 0<r&&t(r-1)})}(3)}}}},k=function(t){return function(e){return S(t)({"":e})}},r=function(r){return function(t){return o.readFile(t).then(function(e){return k(r)({type:f.lookup(t),data:e})})}},S=function(i){return function(n){return M(i)("{}").then(function(e){return Object.keys(n).reduce(function(e,t){return e.then((r=t,function(e){return x(i)(e)(r)(n[r])}));var r},Promise.resolve(e))})}},E=function(t){return function(e){return o.readFile(e).then(M(t))}},A=function(e){return function(t){return function(i){return a.directoryTree(i).then(function(n){return Promise.all(n.map(function(e){return o.readFile(e)})).then(function(e){var t=n.map(function(e){return e.slice(i.length)}),r=n.map(function(e){return f.lookup(e)||"text/plain"});return l(t)(e.map(function(e,t){return{type:r[t],data:e}}))})}).then(function(e){return i=t?{"":e[t]}:{},function(e){var t={};for(var r in i)t[r]=i[r];for(var n in e)t[n]=e[n];return t}(e);var i}).then(S(e))}}},j=function(t){return function(e){if("data"===e.pick)return i.data().then(M(t));if("file"===e.pick)return i.file().then(k(t));if("directory"===e.pick)return i.directory().then(S(t));if(e.path)switch(e.kind){case"data":return E(t)(e.path);case"file":return r(t)(e.path);case"directory":return A(t)(e.defaultFile)(e.path)}else{if(e.length||"string"==typeof e)return M(t)(e);if(e instanceof Object)return S(t)(e)}return Promise.reject(new Error("Bad arguments"))}},I=function(n){return function(r){return function(t){return R(n)(r).then(function(e){return e?t?_(n)(r)(t):g(n)(r):t?w(n)(r)(t):m(n)(r)})}}},B=function(e,t){var r=u.platform().replace("win32","windows")+"-"+("x64"===u.arch()?"amd64":"386"),n=(t||c)[r],i=d+n.archive+".tar.gz",o=n.archiveMD5,s=n.binaryMD5;return a.safeDownloadArchived(i)(o)(s)(e)},T=function(l){return new Promise(function(t,e){var r=p.spawn,n=function(t){return function(e){return-1!==(""+e).indexOf(t)}},i=l.account,o=l.password,s=l.dataDir,a=l.ensApi,u=l.privateKey,f=0,c=r(l.binPath,["--bzzaccount",i||u,"--datadir",s,"--ens-api",a]),h=function(e){0===f&&n("Passphrase")(e)?setTimeout(function(){f=1,c.stdin.write(o+"\n")},500):n("Swarm http proxy started")(e)&&(f=2,clearTimeout(d),t(c))};c.stdout.on("data",h),c.stderr.on("data",h);var d=setTimeout(function(){return e(new Error("Couldn't start swarm process."))},2e4)})},C=function(n){return new Promise(function(e,t){n.stderr.removeAllListeners("data"),n.stdout.removeAllListeners("data"),n.stdin.removeAllListeners("error"),n.removeAllListeners("error"),n.removeAllListeners("exit"),n.kill("SIGINT");var r=setTimeout(function(){return n.kill("SIGKILL")},8e3);n.once("close",function(){clearTimeout(r),e()})})},P=function(e){return M(e)("test").then(function(e){return"c9a99c7d326dcc6316f32fe2625b311f6dc49a175e6877681ded93137d3569e7"===e}).catch(function(){return!1})},R=function(t){return function(e){return m(t)(e).then(function(e){try{return!!JSON.parse(N(e)).entries}catch(e){return!1}})}},O=function(s){return function(e,t,r,n,i){var o;return void 0!==e&&(o=s(e)),void 0!==t&&(o=s(t)),void 0!==r&&(o=s(r)),void 0!==n&&(o=s(n)),void 0!==i&&(o=s(i)),o}},N=function(e){return t.toString(t.fromUint8Array(e))},L=function(e){return t.toUint8Array(t.fromString(e))},q=function(r){return{download:function(e,t){return I(r)(e)(t)},downloadData:O(m(r)),downloadDataToDisk:O(w(r)),downloadDirectory:O(g(r)),downloadDirectoryToDisk:O(_(r)),downloadEntries:O(y(r)),downloadRoutes:O(v(r)),isAvailable:function(){return P(r)},upload:function(e){return j(r)(e)},uploadData:O(M(r)),uploadFile:O(k(r)),uploadFileFromDisk:O(k(r)),uploadDataFromDisk:O(E(r)),uploadDirectory:O(S(r)),uploadDirectoryFromDisk:O(A(r)),uploadToManifest:O(x(r)),pick:i,hash:n,fromString:L,toString:N}};return{at:q,local:function(r){return function(t){return P("http://localhost:8500").then(function(e){return e?t(q("http://localhost:8500")).then(function(){}):B(r.binPath,r.archives).onData(function(e){return(r.onProgress||function(){})(e.length)}).then(function(){return T(r)}).then(function(e){return t(q("http://localhost:8500")).then(function(){return e})}).then(C)})}},download:I,downloadBinary:B,downloadData:m,downloadDataToDisk:w,downloadDirectory:g,downloadDirectoryToDisk:_,downloadEntries:y,downloadRoutes:v,isAvailable:P,startProcess:T,stopProcess:C,upload:j,uploadData:M,uploadDataFromDisk:E,uploadFile:k,uploadFileFromDisk:r,uploadDirectory:S,uploadDirectoryFromDisk:A,uploadToManifest:x,pick:i,hash:n,fromString:L,toString:N}}},{}],186:[function(e,t,r){(r=t.exports=function(e){return e.replace(/^\s*|\s*$/g,"")}).left=function(e){return e.replace(/^\s*/,"")},r.right=function(e){return e.replace(/\s*$/,"")}},{}],187:[function(e,U,H){(function(){var e=this,t=e._,n=Array.prototype,s=Object.prototype,r=Function.prototype,i=n.push,u=n.slice,d=s.toString,o=s.hasOwnProperty,a=Array.isArray,f=Object.keys,c=r.bind,h=Object.create,l=function(){},p=function e(t){return t instanceof e?t:this instanceof e?void(this._wrapped=t):new e(t)};void 0!==H?(void 0!==U&&U.exports&&(H=U.exports=p),H._=p):e._=p,p.VERSION="1.8.3";var b=function(i,o,e){if(void 0===o)return i;switch(null==e?3:e){case 1:return function(e){return i.call(o,e)};case 2:return function(e,t){return i.call(o,e,t)};case 3:return function(e,t,r){return i.call(o,e,t,r)};case 4:return function(e,t,r,n){return i.call(o,e,t,r,n)}}return function(){return i.apply(o,arguments)}},m=function(e,t,r){return null==e?p.identity:p.isFunction(e)?b(e,t,r):p.isObject(e)?p.matcher(e):p.property(e)};p.iteratee=function(e,t){return m(e,t,1/0)};var y=function(u,f){return function(e){var t=arguments.length;if(t<2||null==e)return e;for(var r=1;r<t;r++)for(var n=arguments[r],i=u(n),o=i.length,s=0;s<o;s++){var a=i[s];f&&void 0!==e[a]||(e[a]=n[a])}return e}},v=function(e){if(!p.isObject(e))return{};if(h)return h(e);l.prototype=e;var t=new l;return l.prototype=null,t},g=function(t){return function(e){return null==e?void 0:e[t]}},w=Math.pow(2,53)-1,_=g("length"),M=function(e){var t=_(e);return"number"==typeof t&&0<=t&&t<=w};function x(a){return function(e,t,r,n){t=b(t,n,4);var i=!M(e)&&p.keys(e),o=(i||e).length,s=0<a?0:o-1;return arguments.length<3&&(r=e[i?i[s]:s],s+=a),function(e,t,r,n,i,o){for(;0<=i&&i<o;i+=a){var s=n?n[i]:i;r=t(r,e[s],s,e)}return r}(e,t,r,i,s,o)}}p.each=p.forEach=function(e,t,r){var n,i;if(t=b(t,r),M(e))for(n=0,i=e.length;n<i;n++)t(e[n],n,e);else{var o=p.keys(e);for(n=0,i=o.length;n<i;n++)t(e[o[n]],o[n],e)}return e},p.map=p.collect=function(e,t,r){t=m(t,r);for(var n=!M(e)&&p.keys(e),i=(n||e).length,o=Array(i),s=0;s<i;s++){var a=n?n[s]:s;o[s]=t(e[a],a,e)}return o},p.reduce=p.foldl=p.inject=x(1),p.reduceRight=p.foldr=x(-1),p.find=p.detect=function(e,t,r){var n;if(void 0!==(n=M(e)?p.findIndex(e,t,r):p.findKey(e,t,r))&&-1!==n)return e[n]},p.filter=p.select=function(e,n,t){var i=[];return n=m(n,t),p.each(e,function(e,t,r){n(e,t,r)&&i.push(e)}),i},p.reject=function(e,t,r){return p.filter(e,p.negate(m(t)),r)},p.every=p.all=function(e,t,r){t=m(t,r);for(var n=!M(e)&&p.keys(e),i=(n||e).length,o=0;o<i;o++){var s=n?n[o]:o;if(!t(e[s],s,e))return!1}return!0},p.some=p.any=function(e,t,r){t=m(t,r);for(var n=!M(e)&&p.keys(e),i=(n||e).length,o=0;o<i;o++){var s=n?n[o]:o;if(t(e[s],s,e))return!0}return!1},p.contains=p.includes=p.include=function(e,t,r,n){return M(e)||(e=p.values(e)),("number"!=typeof r||n)&&(r=0),0<=p.indexOf(e,t,r)},p.invoke=function(e,r){var n=u.call(arguments,2),i=p.isFunction(r);return p.map(e,function(e){var t=i?r:e[r];return null==t?t:t.apply(e,n)})},p.pluck=function(e,t){return p.map(e,p.property(t))},p.where=function(e,t){return p.filter(e,p.matcher(t))},p.findWhere=function(e,t){return p.find(e,p.matcher(t))},p.max=function(e,n,t){var r,i,o=-1/0,s=-1/0;if(null==n&&null!=e)for(var a=0,u=(e=M(e)?e:p.values(e)).length;a<u;a++)r=e[a],o<r&&(o=r);else n=m(n,t),p.each(e,function(e,t,r){i=n(e,t,r),(s<i||i===-1/0&&o===-1/0)&&(o=e,s=i)});return o},p.min=function(e,n,t){var r,i,o=1/0,s=1/0;if(null==n&&null!=e)for(var a=0,u=(e=M(e)?e:p.values(e)).length;a<u;a++)(r=e[a])<o&&(o=r);else n=m(n,t),p.each(e,function(e,t,r){((i=n(e,t,r))<s||i===1/0&&o===1/0)&&(o=e,s=i)});return o},p.shuffle=function(e){for(var t,r=M(e)?e:p.values(e),n=r.length,i=Array(n),o=0;o<n;o++)(t=p.random(0,o))!==o&&(i[o]=i[t]),i[t]=r[o];return i},p.sample=function(e,t,r){return null==t||r?(M(e)||(e=p.values(e)),e[p.random(e.length-1)]):p.shuffle(e).slice(0,Math.max(0,t))},p.sortBy=function(e,n,t){return n=m(n,t),p.pluck(p.map(e,function(e,t,r){return{value:e,index:t,criteria:n(e,t,r)}}).sort(function(e,t){var r=e.criteria,n=t.criteria;if(r!==n){if(n<r||void 0===r)return 1;if(r<n||void 0===n)return-1}return e.index-t.index}),"value")};var k=function(s){return function(n,i,e){var o={};return i=m(i,e),p.each(n,function(e,t){var r=i(e,t,n);s(o,e,r)}),o}};p.groupBy=k(function(e,t,r){p.has(e,r)?e[r].push(t):e[r]=[t]}),p.indexBy=k(function(e,t,r){e[r]=t}),p.countBy=k(function(e,t,r){p.has(e,r)?e[r]++:e[r]=1}),p.toArray=function(e){return e?p.isArray(e)?u.call(e):M(e)?p.map(e,p.identity):p.values(e):[]},p.size=function(e){return null==e?0:M(e)?e.length:p.keys(e).length},p.partition=function(e,n,t){n=m(n,t);var i=[],o=[];return p.each(e,function(e,t,r){(n(e,t,r)?i:o).push(e)}),[i,o]},p.first=p.head=p.take=function(e,t,r){if(null!=e)return null==t||r?e[0]:p.initial(e,e.length-t)},p.initial=function(e,t,r){return u.call(e,0,Math.max(0,e.length-(null==t||r?1:t)))},p.last=function(e,t,r){if(null!=e)return null==t||r?e[e.length-1]:p.rest(e,Math.max(0,e.length-t))},p.rest=p.tail=p.drop=function(e,t,r){return u.call(e,null==t||r?1:t)},p.compact=function(e){return p.filter(e,p.identity)};var S=function e(t,r,n,i){for(var o=[],s=0,a=i||0,u=_(t);a<u;a++){var f=t[a];if(M(f)&&(p.isArray(f)||p.isArguments(f))){r||(f=e(f,r,n));var c=0,h=f.length;for(o.length+=h;c<h;)o[s++]=f[c++]}else n||(o[s++]=f)}return o};function E(o){return function(e,t,r){t=m(t,r);for(var n=_(e),i=0<o?0:n-1;0<=i&&i<n;i+=o)if(t(e[i],i,e))return i;return-1}}function A(o,s,a){return function(e,t,r){var n=0,i=_(e);if("number"==typeof r)0<o?n=0<=r?r:Math.max(r+i,n):i=0<=r?Math.min(r+1,i):r+i+1;else if(a&&r&&i)return e[r=a(e,t)]===t?r:-1;if(t!=t)return 0<=(r=s(u.call(e,n,i),p.isNaN))?r+n:-1;for(r=0<o?n:i-1;0<=r&&r<i;r+=o)if(e[r]===t)return r;return-1}}p.flatten=function(e,t){return S(e,t,!1)},p.without=function(e){return p.difference(e,u.call(arguments,1))},p.uniq=p.unique=function(e,t,r,n){p.isBoolean(t)||(n=r,r=t,t=!1),null!=r&&(r=m(r,n));for(var i=[],o=[],s=0,a=_(e);s<a;s++){var u=e[s],f=r?r(u,s,e):u;t?(s&&o===f||i.push(u),o=f):r?p.contains(o,f)||(o.push(f),i.push(u)):p.contains(i,u)||i.push(u)}return i},p.union=function(){return p.uniq(S(arguments,!0,!0))},p.intersection=function(e){for(var t=[],r=arguments.length,n=0,i=_(e);n<i;n++){var o=e[n];if(!p.contains(t,o)){for(var s=1;s<r&&p.contains(arguments[s],o);s++);s===r&&t.push(o)}}return t},p.difference=function(e){var t=S(arguments,!0,!0,1);return p.filter(e,function(e){return!p.contains(t,e)})},p.zip=function(){return p.unzip(arguments)},p.unzip=function(e){for(var t=e&&p.max(e,_).length||0,r=Array(t),n=0;n<t;n++)r[n]=p.pluck(e,n);return r},p.object=function(e,t){for(var r={},n=0,i=_(e);n<i;n++)t?r[e[n]]=t[n]:r[e[n][0]]=e[n][1];return r},p.findIndex=E(1),p.findLastIndex=E(-1),p.sortedIndex=function(e,t,r,n){for(var i=(r=m(r,n,1))(t),o=0,s=_(e);o<s;){var a=Math.floor((o+s)/2);r(e[a])<i?o=a+1:s=a}return o},p.indexOf=A(1,p.findIndex,p.sortedIndex),p.lastIndexOf=A(-1,p.findLastIndex),p.range=function(e,t,r){null==t&&(t=e||0,e=0),r=r||1;for(var n=Math.max(Math.ceil((t-e)/r),0),i=Array(n),o=0;o<n;o++,e+=r)i[o]=e;return i};var j=function(e,t,r,n,i){if(!(n instanceof t))return e.apply(r,i);var o=v(e.prototype),s=e.apply(o,i);return p.isObject(s)?s:o};p.bind=function(t,r){if(c&&t.bind===c)return c.apply(t,u.call(arguments,1));if(!p.isFunction(t))throw new TypeError("Bind must be called on a function");var n=u.call(arguments,2);return function e(){return j(t,e,r,this,n.concat(u.call(arguments)))}},p.partial=function(o){var s=u.call(arguments,1);return function e(){for(var t=0,r=s.length,n=Array(r),i=0;i<r;i++)n[i]=s[i]===p?arguments[t++]:s[i];for(;t<arguments.length;)n.push(arguments[t++]);return j(o,e,this,this,n)}},p.bindAll=function(e){var t,r,n=arguments.length;if(n<=1)throw new Error("bindAll must be passed function names");for(t=1;t<n;t++)e[r=arguments[t]]=p.bind(e[r],e);return e},p.memoize=function(i,o){var e=function e(t){var r=e.cache,n=""+(o?o.apply(this,arguments):t);return p.has(r,n)||(r[n]=i.apply(this,arguments)),r[n]};return e.cache={},e},p.delay=function(e,t){var r=u.call(arguments,2);return setTimeout(function(){return e.apply(null,r)},t)},p.defer=p.partial(p.delay,p,1),p.throttle=function(r,n,i){var o,s,a,u=null,f=0;i||(i={});var c=function(){f=!1===i.leading?0:p.now(),u=null,a=r.apply(o,s),u||(o=s=null)};return function(){var e=p.now();f||!1!==i.leading||(f=e);var t=n-(e-f);return o=this,s=arguments,t<=0||n<t?(u&&(clearTimeout(u),u=null),f=e,a=r.apply(o,s),u||(o=s=null)):u||!1===i.trailing||(u=setTimeout(c,t)),a}},p.debounce=function(r,n,i){var o,s,a,u,f,t=function e(){var t=p.now()-u;t<n&&0<=t?o=setTimeout(e,n-t):(o=null,i||(f=r.apply(a,s),o||(a=s=null)))};return function(){a=this,s=arguments,u=p.now();var e=i&&!o;return o||(o=setTimeout(t,n)),e&&(f=r.apply(a,s),a=s=null),f}},p.wrap=function(e,t){return p.partial(t,e)},p.negate=function(e){return function(){return!e.apply(this,arguments)}},p.compose=function(){var r=arguments,n=r.length-1;return function(){for(var e=n,t=r[n].apply(this,arguments);e--;)t=r[e].call(this,t);return t}},p.after=function(e,t){return function(){if(--e<1)return t.apply(this,arguments)}},p.before=function(e,t){var r;return function(){return 0<--e&&(r=t.apply(this,arguments)),e<=1&&(t=null),r}},p.once=p.partial(p.before,2);var I=!{toString:null}.propertyIsEnumerable("toString"),B=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];function T(e,t){var r=B.length,n=e.constructor,i=p.isFunction(n)&&n.prototype||s,o="constructor";for(p.has(e,o)&&!p.contains(t,o)&&t.push(o);r--;)(o=B[r])in e&&e[o]!==i[o]&&!p.contains(t,o)&&t.push(o)}p.keys=function(e){if(!p.isObject(e))return[];if(f)return f(e);var t=[];for(var r in e)p.has(e,r)&&t.push(r);return I&&T(e,t),t},p.allKeys=function(e){if(!p.isObject(e))return[];var t=[];for(var r in e)t.push(r);return I&&T(e,t),t},p.values=function(e){for(var t=p.keys(e),r=t.length,n=Array(r),i=0;i<r;i++)n[i]=e[t[i]];return n},p.mapObject=function(e,t,r){t=m(t,r);for(var n,i=p.keys(e),o=i.length,s={},a=0;a<o;a++)s[n=i[a]]=t(e[n],n,e);return s},p.pairs=function(e){for(var t=p.keys(e),r=t.length,n=Array(r),i=0;i<r;i++)n[i]=[t[i],e[t[i]]];return n},p.invert=function(e){for(var t={},r=p.keys(e),n=0,i=r.length;n<i;n++)t[e[r[n]]]=r[n];return t},p.functions=p.methods=function(e){var t=[];for(var r in e)p.isFunction(e[r])&&t.push(r);return t.sort()},p.extend=y(p.allKeys),p.extendOwn=p.assign=y(p.keys),p.findKey=function(e,t,r){t=m(t,r);for(var n,i=p.keys(e),o=0,s=i.length;o<s;o++)if(t(e[n=i[o]],n,e))return n},p.pick=function(e,t,r){var n,i,o={},s=e;if(null==s)return o;p.isFunction(t)?(i=p.allKeys(s),n=b(t,r)):(i=S(arguments,!1,!1,1),n=function(e,t,r){return t in r},s=Object(s));for(var a=0,u=i.length;a<u;a++){var f=i[a],c=s[f];n(c,f,s)&&(o[f]=c)}return o},p.omit=function(e,t,r){if(p.isFunction(t))t=p.negate(t);else{var n=p.map(S(arguments,!1,!1,1),String);t=function(e,t){return!p.contains(n,t)}}return p.pick(e,t,r)},p.defaults=y(p.allKeys,!0),p.create=function(e,t){var r=v(e);return t&&p.extendOwn(r,t),r},p.clone=function(e){return p.isObject(e)?p.isArray(e)?e.slice():p.extend({},e):e},p.tap=function(e,t){return t(e),e},p.isMatch=function(e,t){var r=p.keys(t),n=r.length;if(null==e)return!n;for(var i=Object(e),o=0;o<n;o++){var s=r[o];if(t[s]!==i[s]||!(s in i))return!1}return!0};p.isEqual=function(e,t){return function e(t,r,n,i){if(t===r)return 0!==t||1/t==1/r;if(null==t||null==r)return t===r;t instanceof p&&(t=t._wrapped),r instanceof p&&(r=r._wrapped);var o=d.call(t);if(o!==d.call(r))return!1;switch(o){case"[object RegExp]":case"[object String]":return""+t==""+r;case"[object Number]":return+t!=+t?+r!=+r:0==+t?1/+t==1/r:+t==+r;case"[object Date]":case"[object Boolean]":return+t==+r}var s="[object Array]"===o;if(!s){if("object"!=(void 0===t?"undefined":_typeof(t))||"object"!=(void 0===r?"undefined":_typeof(r)))return!1;var a=t.constructor,u=r.constructor;if(a!==u&&!(p.isFunction(a)&&a instanceof a&&p.isFunction(u)&&u instanceof u)&&"constructor"in t&&"constructor"in r)return!1}i=i||[];for(var f=(n=n||[]).length;f--;)if(n[f]===t)return i[f]===r;if(n.push(t),i.push(r),s){if((f=t.length)!==r.length)return!1;for(;f--;)if(!e(t[f],r[f],n,i))return!1}else{var c,h=p.keys(t);if(f=h.length,p.keys(r).length!==f)return!1;for(;f--;)if(c=h[f],!p.has(r,c)||!e(t[c],r[c],n,i))return!1}return n.pop(),i.pop(),!0}(e,t)},p.isEmpty=function(e){return null==e||(M(e)&&(p.isArray(e)||p.isString(e)||p.isArguments(e))?0===e.length:0===p.keys(e).length)},p.isElement=function(e){return!(!e||1!==e.nodeType)},p.isArray=a||function(e){return"[object Array]"===d.call(e)},p.isObject=function(e){var t=void 0===e?"undefined":_typeof(e);return"function"===t||"object"===t&&!!e},p.each(["Arguments","Function","String","Number","Date","RegExp","Error"],function(t){p["is"+t]=function(e){return d.call(e)==="[object "+t+"]"}}),p.isArguments(arguments)||(p.isArguments=function(e){return p.has(e,"callee")}),"function"!=typeof/./&&"object"!=("undefined"==typeof Int8Array?"undefined":_typeof(Int8Array))&&(p.isFunction=function(e){return"function"==typeof e||!1}),p.isFinite=function(e){return isFinite(e)&&!isNaN(parseFloat(e))},p.isNaN=function(e){return p.isNumber(e)&&e!==+e},p.isBoolean=function(e){return!0===e||!1===e||"[object Boolean]"===d.call(e)},p.isNull=function(e){return null===e},p.isUndefined=function(e){return void 0===e},p.has=function(e,t){return null!=e&&o.call(e,t)},p.noConflict=function(){return e._=t,this},p.identity=function(e){return e},p.constant=function(e){return function(){return e}},p.noop=function(){},p.property=g,p.propertyOf=function(t){return null==t?function(){}:function(e){return t[e]}},p.matcher=p.matches=function(t){return t=p.extendOwn({},t),function(e){return p.isMatch(e,t)}},p.times=function(e,t,r){var n=Array(Math.max(0,e));t=b(t,r,1);for(var i=0;i<e;i++)n[i]=t(i);return n},p.random=function(e,t){return null==t&&(t=e,e=0),e+Math.floor(Math.random()*(t-e+1))},p.now=Date.now||function(){return(new Date).getTime()};var C={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;"},P=p.invert(C),R=function(t){var r=function(e){return t[e]},e="(?:"+p.keys(t).join("|")+")",n=RegExp(e),i=RegExp(e,"g");return function(e){return e=null==e?"":""+e,n.test(e)?e.replace(i,r):e}};p.escape=R(C),p.unescape=R(P),p.result=function(e,t,r){var n=null==e?void 0:e[t];return void 0===n&&(n=r),p.isFunction(n)?n.call(e):n};var O=0;p.uniqueId=function(e){var t=++O+"";return e?e+t:t},p.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var N=/(.)^/,L={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},q=/\\|'|\r|\n|\u2028|\u2029/g,D=function(e){return"\\"+L[e]};p.template=function(o,e,t){!e&&t&&(e=t),e=p.defaults({},e,p.templateSettings);var r=RegExp([(e.escape||N).source,(e.interpolate||N).source,(e.evaluate||N).source].join("|")+"|$","g"),s=0,a="__p+='";o.replace(r,function(e,t,r,n,i){return a+=o.slice(s,i).replace(q,D),s=i+e.length,t?a+="'+\n((__t=("+t+"))==null?'':_.escape(__t))+\n'":r?a+="'+\n((__t=("+r+"))==null?'':__t)+\n'":n&&(a+="';\n"+n+"\n__p+='"),e}),a+="';\n",e.variable||(a="with(obj||{}){\n"+a+"}\n"),a="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+a+"return __p;\n";try{var n=new Function(e.variable||"obj","_",a)}catch(e){throw e.source=a,e}var i=function(e){return n.call(this,e,p)},u=e.variable||"obj";return i.source="function("+u+"){\n"+a+"}",i},p.chain=function(e){var t=p(e);return t._chain=!0,t};var F=function(e,t){return e._chain?p(t).chain():t};p.mixin=function(r){p.each(p.functions(r),function(e){var t=p[e]=r[e];p.prototype[e]=function(){var e=[this._wrapped];return i.apply(e,arguments),F(this,t.apply(p,e))}})},p.mixin(p),p.each(["pop","push","reverse","shift","sort","splice","unshift"],function(t){var r=n[t];p.prototype[t]=function(){var e=this._wrapped;return r.apply(e,arguments),"shift"!==t&&"splice"!==t||0!==e.length||delete e[0],F(this,e)}}),p.each(["concat","join","slice"],function(e){var t=n[e];p.prototype[e]=function(){return F(this,t.apply(this._wrapped,arguments))}}),p.prototype.value=function(){return this._wrapped},p.prototype.valueOf=p.prototype.toJSON=p.prototype.value,p.prototype.toString=function(){return""+this._wrapped},"function"==typeof define&&define.amd&&define("underscore",[],function(){return p})}).call(this)},{}],188:[function(e,t,r){t.exports=function(e,t){if(t){t=(t=t.trim().replace(/^(\?|#|&)/,""))?"?"+t:t;var r=e.split(/[\?\#]/),n=r[0];t&&/\:\/\/[^\/]*$/.test(n)&&(n+="/");var i=e.match(/(\#.*)$/);e=n+t,i&&(e+=i[0])}return e}},{}],189:[function(e,t,r){var i=e("xhr-request");t.exports=function(e,t){return new Promise(function(r,n){i(e,t,function(e,t){e?n(e):r(t)})})}},{"xhr-request":190}],190:[function(e,t,r){var a=e("query-string"),u=e("url-set-query"),f=e("object-assign"),c=e("./lib/ensure-header.js"),h=e("./lib/request.js"),d="application/json",l=function(){};t.exports=function(e,t,r){if(!e||"string"!=typeof e)throw new TypeError("must specify a URL");"function"==typeof t&&(r=t,t={});if(r&&"function"!=typeof r)throw new TypeError("expected cb to be undefined or a function");r=r||l;var n=(t=t||{}).json?"json":"text",i=(t=f({responseType:n},t)).headers||{},o=(t.method||"GET").toUpperCase(),s=t.query;s&&("string"!=typeof s&&(s=a.stringify(s)),e=u(e,s));"json"===t.responseType&&c(i,"Accept",d);t.json&&"GET"!==o&&"HEAD"!==o&&(c(i,"Content-Type",d),t.body=JSON.stringify(t.body));return t.method=o,t.url=e,t.headers=i,delete t.query,delete t.json,h(t,r)}},{"./lib/ensure-header.js":191,"./lib/request.js":193,"object-assign":178,"query-string":180,"url-set-query":188}],191:[function(e,t,r){t.exports=function(e,t,r){var n=t.toLowerCase();e[t]||e[n]||(e[t]=r)}},{}],192:[function(e,t,r){t.exports=function(e,t){return t?{statusCode:t.statusCode,headers:t.headers,method:e.method,url:e.url,rawRequest:t.rawRequest?t.rawRequest:t}:null}},{}],193:[function(e,t,r){var n=e("xhr"),a=e("./normalize-response"),u=function(){};t.exports=function(i,o){delete i.uri;var s=!1;"json"===i.responseType&&(i.responseType="text",s=!0);var t=n(i,function(t,e,r){if(s&&!t)try{var n=e.rawRequest.responseText;r=JSON.parse(n)}catch(e){t=e}e=a(i,e),o(t,t?null:r,e),o=u}),r=t.onabort;return t.onabort=function(){var e=r.apply(t,Array.prototype.slice.call(arguments));return o(new Error("XHR Aborted")),o=u,e},t}},{"./normalize-response":192,xhr:194}],194:[function(e,t,r){var n=e("global/window"),i=e("is-function"),m=e("parse-headers"),o=e("xtend");function s(e,t,r){var n=e;return i(t)?(r=t,"string"==typeof e&&(n={uri:e})):n=o(t,{uri:e}),n.callback=r,n}function y(e,t,r){return a(t=s(e,t,r))}function a(n){if(void 0===n.callback)throw new Error("callback argument missing");var i=!1,o=function(e,t,r){i||(i=!0,n.callback(e,t,r))};function t(e){return clearTimeout(u),e instanceof Error||(e=new Error(""+(e||"Unknown XMLHttpRequest Error"))),e.statusCode=0,o(e,b)}function e(){if(!s){var e;clearTimeout(u),e=n.useXDR&&void 0===a.status?200:1223===a.status?204:a.status;var t=b,r=null;return 0!==e?(t={body:function(){var e=void 0;if(e=a.response?a.response:a.responseText||function(e){try{if("document"===e.responseType)return e.responseXML;var t=e.responseXML&&"parsererror"===e.responseXML.documentElement.nodeName;if(""===e.responseType&&!t)return e.responseXML}catch(e){}return null}(a),p)try{e=JSON.parse(e)}catch(e){}return e}(),statusCode:e,method:c,headers:{},url:f,rawRequest:a},a.getAllResponseHeaders&&(t.headers=m(a.getAllResponseHeaders()))):r=new Error("Internal XMLHttpRequest Error"),o(r,t,t.body)}}var r,s,a=n.xhr||null;a||(a=n.cors||n.useXDR?new y.XDomainRequest:new y.XMLHttpRequest);var u,f=a.url=n.uri||n.url,c=a.method=n.method||"GET",h=n.body||n.data,d=a.headers=n.headers||{},l=!!n.sync,p=!1,b={body:void 0,headers:{},statusCode:0,method:c,url:f,rawRequest:a};if("json"in n&&!1!==n.json&&(p=!0,d.accept||d.Accept||(d.Accept="application/json"),"GET"!==c&&"HEAD"!==c&&(d["content-type"]||d["Content-Type"]||(d["Content-Type"]="application/json"),h=JSON.stringify(!0===n.json?h:n.json))),a.onreadystatechange=function(){4===a.readyState&&setTimeout(e,0)},a.onload=e,a.onerror=t,a.onprogress=function(){},a.onabort=function(){s=!0},a.ontimeout=t,a.open(c,f,!l,n.username,n.password),l||(a.withCredentials=!!n.withCredentials),!l&&0<n.timeout&&(u=setTimeout(function(){if(!s){s=!0,a.abort("timeout");var e=new Error("XMLHttpRequest timeout");e.code="ETIMEDOUT",t(e)}},n.timeout)),a.setRequestHeader)for(r in d)d.hasOwnProperty(r)&&a.setRequestHeader(r,d[r]);else if(n.headers&&!function(e){for(var t in e)if(e.hasOwnProperty(t))return!1;return!0}(n.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in n&&(a.responseType=n.responseType),"beforeSend"in n&&"function"==typeof n.beforeSend&&n.beforeSend(a),a.send(h||null),a}(t.exports=y).XMLHttpRequest=n.XMLHttpRequest||function(){},y.XDomainRequest="withCredentials"in new y.XMLHttpRequest?y.XMLHttpRequest:n.XDomainRequest,function(e,t){for(var r=0;r<e.length;r++)t(e[r])}(["get","put","post","patch","head","delete"],function(n){y["delete"===n?"del":n]=function(e,t,r){return(t=s(e,t,r)).method=n.toUpperCase(),a(t)}})},{"global/window":176,"is-function":177,"parse-headers":179,xtend:195}],195:[function(e,t,r){arguments[4][170][0].apply(r,arguments)},{dup:170}],196:[function(e,t,r){var n=e("underscore"),i=e("swarm-js"),o=function e(t){this.givenProvider=e.givenProvider,t&&t._requestManager&&(t=t.currentProvider),"undefined"!=typeof document&&(this.pick=i.pick),this.setProvider(t)};o.givenProvider=null,"undefined"!=typeof ethereumProvider&&ethereumProvider.bzz&&(o.givenProvider=ethereumProvider.bzz),o.prototype.setProvider=function(e){if(n.isObject(e)&&n.isString(e.bzz)&&(e=e.bzz),!n.isString(e)){this.currentProvider=null;var t=new Error("No provider set, please set one using bzz.setProvider().");return!(this.download=this.upload=this.isAvailable=function(){throw t})}return this.currentProvider=e,this.download=i.at(e).download,this.upload=i.at(e).upload,this.isAvailable=i.at(e).isAvailable,!0},t.exports=o},{"swarm-js":182,underscore:187}],197:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],198:[function(e,t,r){t.exports={ErrorResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:JSON.stringify(e);return new Error("Returned error: "+t)},InvalidNumberOfParams:function(e,t,r){return new Error('Invalid number of parameters for "'+r+'". Got '+e+" expected "+t+"!")},InvalidConnection:function(e){return new Error("CONNECTION ERROR: Couldn't connect to node "+e+".")},InvalidProvider:function(){return new Error("Provider not set or invalid")},InvalidResponse:function(e){var t=e&&e.error&&e.error.message?e.error.message:"Invalid JSON RPC response: "+JSON.stringify(e);return new Error(t)},ConnectionTimeout:function(e){return new Error("CONNECTION TIMEOUT: timeout of "+e+" ms achived")}}},{}],199:[function(e,t,r){var n=e("underscore"),i=e("web3-utils"),o=e("web3-eth-iban"),s=function(e){return i.toBN(e).toString(10)},a=function(e){var t;if(void 0!==e)return"latest"===(t=e)||"pending"===t||"earliest"===t?e:i.isHexStrict(e)?n.isString(e)?e.toLowerCase():e:i.numberToHex(e)},u=function(t){if(t.to&&(t.to=h(t.to)),t.data&&t.input)throw new Error('You can\'t have "data" and "input" as properties of transactions at the same time, please use either "data" or "input" instead.');if(!t.data&&t.input&&(t.data=t.input,delete t.input),t.data&&!i.isHex(t.data))throw new Error("The data field must be HEX encoded data.");return(t.gas||t.gasLimit)&&(t.gas=t.gas||t.gasLimit),["gasPrice","gas","value","nonce"].filter(function(e){return void 0!==t[e]}).forEach(function(e){t[e]=i.numberToHex(t[e])}),t},f=function(e){return null!==e.blockNumber&&(e.blockNumber=i.hexToNumber(e.blockNumber)),null!==e.transactionIndex&&(e.transactionIndex=i.hexToNumber(e.transactionIndex)),e.nonce=i.hexToNumber(e.nonce),e.gas=i.hexToNumber(e.gas),e.gasPrice=s(e.gasPrice),e.value=s(e.value),e.to&&i.isAddress(e.to)?e.to=i.toChecksumAddress(e.to):e.to=null,e.from&&(e.from=i.toChecksumAddress(e.from)),e},c=function(e){if("string"==typeof e.blockHash&&"string"==typeof e.transactionHash&&"string"==typeof e.logIndex){var t=i.sha3(e.blockHash.replace("0x","")+e.transactionHash.replace("0x","")+e.logIndex.replace("0x",""));e.id="log_"+t.replace("0x","").substr(0,8)}else e.id||(e.id=null);return null!==e.blockNumber&&(e.blockNumber=i.hexToNumber(e.blockNumber)),null!==e.transactionIndex&&(e.transactionIndex=i.hexToNumber(e.transactionIndex)),null!==e.logIndex&&(e.logIndex=i.hexToNumber(e.logIndex)),e.address&&(e.address=i.toChecksumAddress(e.address)),e},h=function(e){var t=new o(e);if(t.isValid()&&t.isDirect())return t.toAddress().toLowerCase();if(i.isAddress(e))return"0x"+e.toLowerCase().replace("0x","");throw new Error('Provided address "'+e+"\" is invalid, the capitalization checksum test failed, or its an indrect IBAN address which can't be converted.")};t.exports={inputDefaultBlockNumberFormatter:function(e){return this&&null==e?this.defaultBlock:"genesis"===e||"earliest"===e?"0x0":a(e)},inputBlockNumberFormatter:a,inputCallFormatter:function(e){var t=(e=u(e)).from||(this?this.defaultAccount:null);return t&&(e.from=h(t)),e},inputTransactionFormatter:function(e){if(e=u(e),!n.isNumber(e.from)&&!n.isObject(e.from)){if(e.from=e.from||(this?this.defaultAccount:null),!e.from&&!n.isNumber(e.from))throw new Error('The send transactions "from" field must be defined!');e.from=h(e.from)}return e},inputAddressFormatter:h,inputPostFormatter:function(e){return e.ttl&&(e.ttl=i.numberToHex(e.ttl)),e.workToProve&&(e.workToProve=i.numberToHex(e.workToProve)),e.priority&&(e.priority=i.numberToHex(e.priority)),n.isArray(e.topics)||(e.topics=e.topics?[e.topics]:[]),e.topics=e.topics.map(function(e){return 0===e.indexOf("0x")?e:i.fromUtf8(e)}),e},inputLogFormatter:function(e){var t=function(e){return null==e?null:0===(e=String(e)).indexOf("0x")?e:i.fromUtf8(e)};return e.topics=e.topics||[],e.topics=e.topics.map(function(e){return n.isArray(e)?e.map(t):t(e)}),t=null,e.address&&(e.address=n.isArray(e.address)?e.address.map(function(e){return h(e)}):h(e.address)),e},inputSignFormatter:function(e){return i.isHexStrict(e)?e:i.utf8ToHex(e)},outputBigNumberFormatter:s,outputTransactionFormatter:f,outputTransactionReceiptFormatter:function(e){if("object"!==(void 0===e?"undefined":_typeof(e)))throw new Error("Received receipt is invalid: "+e);return null!==e.blockNumber&&(e.blockNumber=i.hexToNumber(e.blockNumber)),null!==e.transactionIndex&&(e.transactionIndex=i.hexToNumber(e.transactionIndex)),e.cumulativeGasUsed=i.hexToNumber(e.cumulativeGasUsed),e.gasUsed=i.hexToNumber(e.gasUsed),n.isArray(e.logs)&&(e.logs=e.logs.map(c)),e.contractAddress&&(e.contractAddress=i.toChecksumAddress(e.contractAddress)),void 0!==e.status&&(e.status=Boolean(parseInt(e.status))),e},outputBlockFormatter:function(e){return e.gasLimit=i.hexToNumber(e.gasLimit),e.gasUsed=i.hexToNumber(e.gasUsed),e.size=i.hexToNumber(e.size),e.timestamp=i.hexToNumber(e.timestamp),null!==e.number&&(e.number=i.hexToNumber(e.number)),e.difficulty&&(e.difficulty=s(e.difficulty)),e.totalDifficulty&&(e.totalDifficulty=s(e.totalDifficulty)),n.isArray(e.transactions)&&e.transactions.forEach(function(e){if(!n.isString(e))return f(e)}),e.miner&&(e.miner=i.toChecksumAddress(e.miner)),e},outputLogFormatter:c,outputPostFormatter:function(e){return e.expiry=i.hexToNumber(e.expiry),e.sent=i.hexToNumber(e.sent),e.ttl=i.hexToNumber(e.ttl),e.workProved=i.hexToNumber(e.workProved),e.topics||(e.topics=[]),e.topics=e.topics.map(function(e){return i.toUtf8(e)}),e},outputSyncingFormatter:function(e){return e.startingBlock=i.hexToNumber(e.startingBlock),e.currentBlock=i.hexToNumber(e.currentBlock),e.highestBlock=i.hexToNumber(e.highestBlock),e.knownStates&&(e.knownStates=i.hexToNumber(e.knownStates),e.pulledStates=i.hexToNumber(e.pulledStates)),e}}},{underscore:197,"web3-eth-iban":377,"web3-utils":408}],200:[function(e,t,r){var n=e("./errors"),i=e("./formatters");t.exports={errors:n,formatters:i}},{"./errors":198,"./formatters":199}],201:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],202:[function(e,t,r){var y=e("underscore"),n=e("web3-core-helpers").errors,i=e("web3-core-helpers").formatters,v=e("web3-utils"),g=e("web3-core-promievent"),w=e("web3-core-subscriptions").subscriptions,_=function(e){if(!e.call||!e.name)throw new Error('When creating a method you need to provide at least the "name" and "call" property.');this.name=e.name,this.call=e.call,this.params=e.params||0,this.inputFormatter=e.inputFormatter,this.outputFormatter=e.outputFormatter,this.transformPayload=e.transformPayload,this.extraFormatters=e.extraFormatters,this.requestManager=e.requestManager,this.accounts=e.accounts,this.defaultBlock=e.defaultBlock||"latest",this.defaultAccount=e.defaultAccount||null};_.prototype.setRequestManager=function(e,t){this.requestManager=e,t&&(this.accounts=t)},_.prototype.createFunction=function(e,t){var r=this.buildCall();return r.call=this.call,this.setRequestManager(e||this.requestManager,t||this.accounts),r},_.prototype.attachToObject=function(e){var t=this.buildCall();t.call=this.call;var r=this.name.split(".");1<r.length?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},_.prototype.getCall=function(e){return y.isFunction(this.call)?this.call(e):this.call},_.prototype.extractCallback=function(e){if(y.isFunction(e[e.length-1]))return e.pop()},_.prototype.validateArgs=function(e){if(e.length!==this.params)throw n.InvalidNumberOfParams(e.length,this.params,this.name)},_.prototype.formatInput=function(r){var n=this;return this.inputFormatter?this.inputFormatter.map(function(e,t){return e?e.call(n,r[t]):r[t]}):r},_.prototype.formatOutput=function(e){var t=this;return y.isArray(e)?e.map(function(e){return t.outputFormatter&&e?t.outputFormatter(e):e}):this.outputFormatter&&e?this.outputFormatter(e):e},_.prototype.toPayload=function(e){var t=this.getCall(e),r=this.extractCallback(e),n=this.formatInput(e);this.validateArgs(n);var i={method:t,params:n,callback:r};return this.transformPayload&&(i=this.transformPayload(i)),i},_.prototype._confirmTransaction=function(o,s,e){var a=this,u=!1,f=!0,c=0,h=0,d=null,l="",p=y.isObject(e.params[0])&&e.params[0].gas?e.params[0].gas:null,b=y.isObject(e.params[0])&&e.params[0].data&&e.params[0].from&&!e.params[0].to,t=[new _({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:i.outputTransactionReceiptFormatter}),new _({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[i.inputAddressFormatter,i.inputDefaultBlockNumberFormatter]}),new w({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:i.outputBlockFormatter}}})],m={};y.each(t,function(e){e.attachToObject(m),e.requestManager=a.requestManager});var r=function(t,e,r,n,i){if(!r)return i||(i={unsubscribe:function(){clearInterval(d)}}),(t?g.resolve(t):m.getTransactionReceipt(s)).catch(function(e){i.unsubscribe(),u=!0,v._fireError({message:"Failed to check for transaction receipt:",data:e},o.eventEmitter,o.reject)}).then(function(e){if(!e||!e.blockHash)throw new Error("Receipt missing or blockHash null");return a.extraFormatters&&a.extraFormatters.receiptFormatter&&(e=a.extraFormatters.receiptFormatter(e)),0<o.eventEmitter.listeners("confirmation").length&&(void 0!==t&&0===h||o.eventEmitter.emit("confirmation",h,e),f=!1,25===++h&&(i.unsubscribe(),o.eventEmitter.removeAllListeners())),e}).then(function(r){if(b&&!u){if(!r.contractAddress)return f&&(i.unsubscribe(),u=!0),void v._fireError(new Error("The transaction receipt didn't contain a contract address."),o.eventEmitter,o.reject);m.getCode(r.contractAddress,function(e,t){t&&(2<t.length?(o.eventEmitter.emit("receipt",r),a.extraFormatters&&a.extraFormatters.contractDeployFormatter?o.resolve(a.extraFormatters.contractDeployFormatter(r)):o.resolve(r),f&&o.eventEmitter.removeAllListeners()):v._fireError(new Error("The contract code couldn't be stored, please check your gas limit."),o.eventEmitter,o.reject),f&&i.unsubscribe(),u=!0)})}return r}).then(function(e){b||u||(e.outOfGas||p&&p===e.gasUsed||!0!==e.status&&"0x1"!==e.status&&void 0!==e.status?(e&&(l=JSON.stringify(e,null,2)),!1===e.status||"0x0"===e.status?v._fireError(new Error("Transaction has been reverted by the EVM:\n"+l),o.eventEmitter,o.reject):v._fireError(new Error("Transaction ran out of gas. Please provide more gas:\n"+l),o.eventEmitter,o.reject)):(o.eventEmitter.emit("receipt",e),o.resolve(e),f&&o.eventEmitter.removeAllListeners()),f&&i.unsubscribe(),u=!0)}).catch(function(){c++,e?750<=c-1&&(i.unsubscribe(),u=!0,v._fireError(new Error("Transaction was not mined within750 seconds, please make sure your transaction was properly sent. Be aware that it might still be mined!"),o.eventEmitter,o.reject)):50<=c-1&&(i.unsubscribe(),u=!0,v._fireError(new Error("Transaction was not mined within 50 blocks, please make sure your transaction was properly sent. Be aware that it might still be mined!"),o.eventEmitter,o.reject))});i.unsubscribe(),u=!0,v._fireError({message:"Failed to subscribe to new newBlockHeaders to confirm the transaction receipts.",data:r},o.eventEmitter,o.reject)},n=function(e){y.isFunction(this.requestManager.provider.on)?m.subscribe("newBlockHeaders",r.bind(null,e,!1)):d=setInterval(r.bind(null,e,!0),1e3)}.bind(this);m.getTransactionReceipt(s).then(function(e){e&&e.blockHash?(0<o.eventEmitter.listeners("confirmation").length&&n(e),r(e,!1)):u||n()}).catch(function(){u||n()})};var f=function(e,t){return y.isNumber(e)?t.wallet[e]:y.isObject(e)&&e.address&&e.privateKey?e:t.wallet[e.toLowerCase()]};_.prototype.buildCall=function(){var i=this,o="eth_sendTransaction"===i.call||"eth_sendRawTransaction"===i.call,e=function(){var s=g(!o),r=i.toPayload(Array.prototype.slice.call(arguments)),a=function(t,e){try{e=i.formatOutput(e)}catch(e){t=e}if(e instanceof Error&&(t=e),t)return t.error&&(t=t.error),v._fireError(t,s.eventEmitter,s.reject,r.callback);r.callback&&r.callback(null,e),o?(s.eventEmitter.emit("transactionHash",e),i._confirmTransaction(s,e,r)):t||s.resolve(e)},u=function(e){var t=y.extend({},r,{method:"eth_sendRawTransaction",params:[e.rawTransaction]});i.requestManager.send(t,a)},n=function(e,t){var r;if(t&&t.accounts&&t.accounts.wallet&&t.accounts.wallet.length)if("eth_sendTransaction"===e.method){var n=e.params[0];if((r=f(y.isObject(n)?n.from:null,t.accounts))&&r.privateKey)return t.accounts.signTransaction(y.omit(n,"from"),r.privateKey).then(u)}else if("eth_sign"===e.method){var i=e.params[1];if((r=f(e.params[0],t.accounts))&&r.privateKey){var o=t.accounts.sign(i,r.privateKey);return e.callback&&e.callback(null,o.signature),void s.resolve(o.signature)}}return t.requestManager.send(e,a)};o&&y.isObject(r.params[0])&&!r.params[0].gasPrice?new _({name:"getGasPrice",call:"eth_gasPrice",params:0}).createFunction(i.requestManager)(function(e,t){t&&(r.params[0].gasPrice=t),n(r,i)}):n(r,i);return s.eventEmitter};return e.method=i,e.request=this.request.bind(this),e},_.prototype.request=function(){var e=this.toPayload(Array.prototype.slice.call(arguments));return e.format=this.formatOutput.bind(this),e},t.exports=_},{underscore:201,"web3-core-helpers":200,"web3-core-promievent":207,"web3-core-subscriptions":215,"web3-utils":408}],203:[function(e,t,r){t.exports=e("./register")().Promise},{"./register":205}],204:[function(e,t,r){var o="@@any-promise/REGISTRATION",s=null;t.exports=function(n,i){return function(e,t){e=e||null;var r=!1!==(t=t||{}).global;if(null===s&&r&&(s=n[o]||null),null!==s&&null!==e&&s.implementation!==e)throw new Error('any-promise already defined as "'+s.implementation+'". You can only register an implementation before the first call to require("any-promise") and an implementation cannot be changed');return null===s&&(s=null!==e&&void 0!==t.Promise?{Promise:t.Promise,implementation:e}:i(e),r&&(n[o]=s)),s}}},{}],205:[function(e,t,r){t.exports=e("./loader")(window,function(){if(void 0===window.Promise)throw new Error("any-promise browser requires a polyfill or explicit registration e.g: require('any-promise/register/bluebird')");return{Promise:window.Promise,implementation:"window.Promise"}})},{"./loader":204}],206:[function(e,t,r){var l="function"!=typeof Object.create&&"~";function o(e,t,r){this.fn=e,this.context=t,this.once=r||!1}function n(){}n.prototype._events=void 0,n.prototype.listeners=function(e,t){var r=l?l+e:e,n=this._events&&this._events[r];if(t)return!!n;if(!n)return[];if(n.fn)return[n.fn];for(var i=0,o=n.length,s=new Array(o);i<o;i++)s[i]=n[i].fn;return s},n.prototype.emit=function(e,t,r,n,i,o){var s=l?l+e:e;if(!this._events||!this._events[s])return!1;var a,u,f=this._events[s],c=arguments.length;if("function"==typeof f.fn){switch(f.once&&this.removeListener(e,f.fn,void 0,!0),c){case 1:return f.fn.call(f.context),!0;case 2:return f.fn.call(f.context,t),!0;case 3:return f.fn.call(f.context,t,r),!0;case 4:return f.fn.call(f.context,t,r,n),!0;case 5:return f.fn.call(f.context,t,r,n,i),!0;case 6:return f.fn.call(f.context,t,r,n,i,o),!0}for(u=1,a=new Array(c-1);u<c;u++)a[u-1]=arguments[u];f.fn.apply(f.context,a)}else{var h,d=f.length;for(u=0;u<d;u++)switch(f[u].once&&this.removeListener(e,f[u].fn,void 0,!0),c){case 1:f[u].fn.call(f[u].context);break;case 2:f[u].fn.call(f[u].context,t);break;case 3:f[u].fn.call(f[u].context,t,r);break;default:if(!a)for(h=1,a=new Array(c-1);h<c;h++)a[h-1]=arguments[h];f[u].fn.apply(f[u].context,a)}}return!0},n.prototype.on=function(e,t,r){var n=new o(t,r||this),i=l?l+e:e;return this._events||(this._events=l?{}:Object.create(null)),this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],n]:this._events[i].push(n):this._events[i]=n,this},n.prototype.once=function(e,t,r){var n=new o(t,r||this,!0),i=l?l+e:e;return this._events||(this._events=l?{}:Object.create(null)),this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],n]:this._events[i].push(n):this._events[i]=n,this},n.prototype.removeListener=function(e,t,r,n){var i=l?l+e:e;if(!this._events||!this._events[i])return this;var o=this._events[i],s=[];if(t)if(o.fn)(o.fn!==t||n&&!o.once||r&&o.context!==r)&&s.push(o);else for(var a=0,u=o.length;a<u;a++)(o[a].fn!==t||n&&!o[a].once||r&&o[a].context!==r)&&s.push(o[a]);return s.length?this._events[i]=1===s.length?s[0]:s:delete this._events[i],this},n.prototype.removeAllListeners=function(e){return this._events&&(e?delete this._events[l?l+e:e]:this._events=l?{}:Object.create(null)),this},n.prototype.off=n.prototype.removeListener,n.prototype.addListener=n.prototype.on,n.prototype.setMaxListeners=function(){return this},n.prefixed=l,void 0!==t&&(t.exports=n)},{}],207:[function(e,t,r){var o=e("eventemitter3"),s=e("any-promise"),n=function(e){var t,r,n=new s(function(){t=arguments[0],r=arguments[1]});if(e)return{resolve:t,reject:r,eventEmitter:n};var i=new o;return n._events=i._events,n.emit=i.emit,n.on=i.on,n.once=i.once,n.off=i.off,n.listeners=i.listeners,n.addListener=i.addListener,n.removeListener=i.removeListener,n.removeAllListeners=i.removeAllListeners,{resolve:t,reject:r,eventEmitter:n}};n.resolve=function(e){var t=n(!0);return t.resolve(e),t.eventEmitter},t.exports=n},{"any-promise":203,eventemitter3:206}],208:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],209:[function(e,t,r){var i=e("./jsonrpc"),o=e("web3-core-helpers").errors,n=function(e){this.requestManager=e,this.requests=[]};n.prototype.add=function(e){this.requests.push(e)},n.prototype.execute=function(){var n=this.requests;this.requestManager.sendBatch(n,function(e,r){r=r||[],n.map(function(e,t){return r[t]||{}}).forEach(function(e,t){if(n[t].callback){if(e&&e.error)return n[t].callback(o.ErrorResponse(e));if(!i.isValidResponse(e))return n[t].callback(o.InvalidResponse(e));try{n[t].callback(null,n[t].format?n[t].format(e.result):e.result)}catch(e){n[t].callback(e)}}})})},t.exports=n},{"./jsonrpc":212,"web3-core-helpers":200}],210:[function(e,t,r){var n=null,i=Function("return this")();void 0!==i.ethereumProvider?n=i.ethereumProvider:void 0!==i.web3&&i.web3.currentProvider&&(i.web3.currentProvider.sendAsync&&(i.web3.currentProvider.send=i.web3.currentProvider.sendAsync,delete i.web3.currentProvider.sendAsync),!i.web3.currentProvider.on&&i.web3.currentProvider.connection&&"ipcProviderWrapper"===i.web3.currentProvider.connection.constructor.name&&(i.web3.currentProvider.on=function(e,r){if("function"!=typeof r)throw new Error("The second parameter callback must be a function.");switch(e){case"data":this.connection.on("data",function(t){var e="";t=t.toString();try{e=JSON.parse(t)}catch(e){return r(new Error("Couldn't parse response data"+t))}e.id||-1===e.method.indexOf("_subscription")||r(null,e)});break;default:this.connection.on(e,r)}}),n=i.web3.currentProvider),t.exports=n},{}],211:[function(e,t,r){var n=e("underscore"),i=e("web3-core-helpers").errors,o=e("./jsonrpc.js"),s=e("./batch.js"),a=e("./givenProvider.js"),u=function e(t){this.provider=null,this.providers=e.providers,this.setProvider(t),this.subscriptions={}};u.givenProvider=a,u.providers={WebsocketProvider:e("web3-providers-ws"),HttpProvider:e("web3-providers-http"),IpcProvider:e("web3-providers-ipc")},u.prototype.setProvider=function(e,t){var r=this;if(e&&"string"==typeof e&&this.providers)if(/^http(s)?:\/\//i.test(e))e=new this.providers.HttpProvider(e);else if(/^ws(s)?:\/\//i.test(e))e=new this.providers.WebsocketProvider(e);else if(e&&"object"===(void 0===t?"undefined":_typeof(t))&&"function"==typeof t.connect)e=new this.providers.IpcProvider(e,t);else if(e)throw new Error("Can't autodetect provider for \""+e+'"');this.provider&&this.provider.connected&&this.clearSubscriptions(),this.provider=e||null,this.provider&&this.provider.on&&this.provider.on("data",function(e,t){(e=e||t).method&&r.subscriptions[e.params.subscription]&&r.subscriptions[e.params.subscription].callback&&r.subscriptions[e.params.subscription].callback(null,e.params.result)})},u.prototype.send=function(e,r){if(r=r||function(){},!this.provider)return r(i.InvalidProvider());var n=o.toPayload(e.method,e.params);this.provider[this.provider.sendAsync?"sendAsync":"send"](n,function(e,t){return t&&t.id&&n.id!==t.id?r(new Error('Wrong response id "'+t.id+'" (expected: "'+n.id+'") in '+JSON.stringify(n))):e?r(e):t&&t.error?r(i.ErrorResponse(t)):o.isValidResponse(t)?void r(null,t.result):r(i.InvalidResponse(t))})},u.prototype.sendBatch=function(e,r){if(!this.provider)return r(i.InvalidProvider());var t=o.toBatchPayload(e);this.provider[this.provider.sendAsync?"sendAsync":"send"](t,function(e,t){return e?r(e):n.isArray(t)?void r(null,t):r(i.InvalidResponse(t))})},u.prototype.addSubscription=function(e,t,r,n){if(!this.provider.on)throw new Error("The provider doesn't support subscriptions: "+this.provider.constructor.name);this.subscriptions[e]={callback:n,type:r,name:t}},u.prototype.removeSubscription=function(e,t){this.subscriptions[e]&&(this.send({method:this.subscriptions[e].type+"_unsubscribe",params:[e]},t),delete this.subscriptions[e])},u.prototype.clearSubscriptions=function(t){var r=this;Object.keys(this.subscriptions).forEach(function(e){t&&"syncing"===r.subscriptions[e].name||r.removeSubscription(e)}),this.provider.reset&&this.provider.reset()},t.exports={Manager:u,BatchManager:s}},{"./batch.js":209,"./givenProvider.js":210,"./jsonrpc.js":212,underscore:208,"web3-core-helpers":200,"web3-providers-http":390,"web3-providers-ipc":393,"web3-providers-ws":395}],212:[function(e,t,r){var n={messageId:0,toPayload:function(e,t){if(!e)throw new Error('JSONRPC method should be specified for params: "'+JSON.stringify(t)+'"!');return n.messageId++,{jsonrpc:"2.0",id:n.messageId,method:e,params:t||[]}},isValidResponse:function(e){return Array.isArray(e)?e.every(t):t(e);function t(e){return!(!e||e.error||"2.0"!==e.jsonrpc||"number"!=typeof e.id&&"string"!=typeof e.id||void 0===e.result)}},toBatchPayload:function(e){return e.map(function(e){return n.toPayload(e.method,e.params)})}};t.exports=n},{}],213:[function(e,t,r){arguments[4][206][0].apply(r,arguments)},{dup:206}],214:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],215:[function(e,t,r){var n=e("./subscription.js"),i=function(e){this.name=e.name,this.type=e.type,this.subscriptions=e.subscriptions||{},this.requestManager=null};i.prototype.setRequestManager=function(e){this.requestManager=e},i.prototype.attachToObject=function(e){var t=this.buildCall();t.call=this.call;var r=this.name.split(".");1<r.length?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},i.prototype.buildCall=function(){var t=this;return function(){t.subscriptions[arguments[0]]||console.warn("Subscription "+JSON.stringify(arguments[0])+" doesn't exist. Subscribing anyway.");var e=new n({subscription:t.subscriptions[arguments[0]],requestManager:t.requestManager,type:t.type});return e.subscribe.apply(e,arguments)}},t.exports={subscriptions:i,subscription:n}},{"./subscription.js":216}],216:[function(e,t,r){var o=e("underscore"),n=e("web3-core-helpers").errors,i=e("eventemitter3");function s(e){i.call(this),this.id=null,this.callback=null,this.arguments=null,this._reconnectIntervalId=null,this.options={subscription:e.subscription,type:e.type,requestManager:e.requestManager}}((s.prototype=Object.create(i.prototype)).constructor=s).prototype._extractCallback=function(e){if(o.isFunction(e[e.length-1]))return e.pop()},s.prototype._validateArgs=function(e){var t=this.options.subscription;if(t||(t={}),t.params||(t.params=0),e.length!==t.params)throw n.InvalidNumberOfParams(e.length,t.params+1,e[0])},s.prototype._formatInput=function(r){var e=this.options.subscription;return e&&e.inputFormatter?e.inputFormatter.map(function(e,t){return e?e(r[t]):r[t]}):r},s.prototype._formatOutput=function(e){var t=this.options.subscription;return t&&t.outputFormatter&&e?t.outputFormatter(e):e},s.prototype._toPayload=function(e){var t=[];if(this.callback=this._extractCallback(e),this.subscriptionMethod||(this.subscriptionMethod=e.shift(),this.options.subscription.subscriptionName&&(this.subscriptionMethod=this.options.subscription.subscriptionName)),this.arguments||(this.arguments=this._formatInput(e),this._validateArgs(this.arguments),e=[]),t.push(this.subscriptionMethod),t=t.concat(this.arguments),e.length)throw new Error("Only a callback is allowed as parameter on an already instantiated subscription.");return{method:this.options.type+"_subscribe",params:t}},s.prototype.unsubscribe=function(e){this.options.requestManager.removeSubscription(this.id,e),this.id=null,this.removeAllListeners(),clearInterval(this._reconnectIntervalId)},s.prototype.subscribe=function(){var r=this,e=Array.prototype.slice.call(arguments),n=this._toPayload(e);if(!n)return this;if(!this.options.requestManager.provider){var t=new Error("No provider set.");return this.callback(t,null,this),this.emit("error",t),this}if(!this.options.requestManager.provider.on){var i=new Error("The current provider doesn't support subscriptions: "+this.options.requestManager.provider.constructor.name);return this.callback(i,null,this),this.emit("error",i),this}return this.id&&this.unsubscribe(),this.options.params=n.params[1],"logs"===n.params[0]&&o.isObject(n.params[1])&&n.params[1].hasOwnProperty("fromBlock")&&isFinite(n.params[1].fromBlock)&&this.options.requestManager.send({method:"eth_getLogs",params:[n.params[1]]},function(e,t){e?(r.callback(e,null,r),r.emit("error",e)):t.forEach(function(e){var t=r._formatOutput(e);r.callback(null,t,r),r.emit("data",t)})}),"object"===_typeof(n.params[1])&&delete n.params[1].fromBlock,this.options.requestManager.send(n,function(e,t){!e&&t?(r.id=t,r.options.requestManager.addSubscription(r.id,n.params[0],r.options.type,function(e,t){e?(r.options.requestManager.removeSubscription(r.id),r.options.requestManager.provider.once&&(r._reconnectIntervalId=setInterval(function(){r.options.requestManager.provider.reconnect&&r.options.requestManager.provider.reconnect()},500),r.options.requestManager.provider.once("connect",function(){clearInterval(r._reconnectIntervalId),r.subscribe(r.callback)})),r.emit("error",e),o.isFunction(r.callback)&&r.callback(e,null,r)):(o.isArray(t)||(t=[t]),t.forEach(function(e){var t=r._formatOutput(e);if(o.isFunction(r.options.subscription.subscriptionHandler))return r.options.subscription.subscriptionHandler.call(r,t);r.emit("data",t),o.isFunction(r.callback)&&r.callback(null,t,r)}))})):(o.isFunction(r.callback)&&r.callback(e,null,r),r.emit("error",e))}),this},t.exports=s},{eventemitter3:213,underscore:214,"web3-core-helpers":200}],217:[function(e,t,r){var n=e("web3-core-helpers").formatters,i=e("web3-core-method"),o=e("web3-utils");t.exports=function(r){var e=function(e){var t;return e.property?(r[e.property]||(r[e.property]={}),t=r[e.property]):t=r,e.methods&&e.methods.forEach(function(e){e instanceof i||(e=new i(e)),e.attachToObject(t),e.setRequestManager(r._requestManager)}),r};return e.formatters=n,e.utils=o,e.Method=i,e}},{"web3-core-helpers":200,"web3-core-method":202,"web3-utils":408}],218:[function(e,t,r){var n=e("web3-core-requestmanager"),i=e("./extend.js");t.exports={packageInit:function(r,e){if(e=Array.prototype.slice.call(e),!r)throw new Error('You need to instantiate using the "new" keyword.');Object.defineProperty(r,"currentProvider",{get:function(){return r._provider},set:function(e){return r.setProvider(e)},enumerable:!0,configurable:!0}),e[0]&&e[0]._requestManager?r._requestManager=new n.Manager(e[0].currentProvider):(r._requestManager=new n.Manager,r._requestManager.setProvider(e[0],e[1])),r.givenProvider=n.Manager.givenProvider,r.providers=n.Manager.providers,r._provider=r._requestManager.provider,r.setProvider||(r.setProvider=function(e,t){return r._requestManager.setProvider(e,t),r._provider=r._requestManager.provider,!0}),r.BatchRequest=n.BatchManager.bind(null,r._requestManager),r.extend=i(r)},addProviders:function(e){e.givenProvider=n.Manager.givenProvider,e.providers=n.Manager.providers}}},{"./extend.js":217,"web3-core-requestmanager":211}],219:[function(x,e,t){!function(e,t){function m(e,t){if(!e)throw new Error(t||"Assertion failed")}function r(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function y(e,t,r){if(y.isBN(e))return e;this.negative=0,this.words=null,this.length=0,(this.red=null)!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var n;"object"===(void 0===e?"undefined":_typeof(e))?e.exports=y:t.BN=y,(y.BN=y).wordSize=26;try{n=x("buffer").Buffer}catch(e){}function s(e,t,r){for(var n=0,i=Math.min(e.length,r),o=t;o<i;o++){var s=e.charCodeAt(o)-48;n<<=4,n|=49<=s&&s<=54?s-49+10:17<=s&&s<=22?s-17+10:15&s}return n}function h(e,t,r,n){for(var i=0,o=Math.min(e.length,r),s=t;s<o;s++){var a=e.charCodeAt(s)-48;i*=n,i+=49<=a?a-49+10:17<=a?a-17+10:a}return i}y.isBN=function(e){return e instanceof y||null!==e&&"object"===(void 0===e?"undefined":_typeof(e))&&e.constructor.wordSize===y.wordSize&&Array.isArray(e.words)},y.max=function(e,t){return 0<e.cmp(t)?e:t},y.min=function(e,t){return e.cmp(t)<0?e:t},y.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"===(void 0===e?"undefined":_typeof(e)))return this._initArray(e,t,r);"hex"===t&&(t=16),m(t===(0|t)&&2<=t&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&n++,16===t?this._parseHex(e,n):this._parseBase(e,t,n),"-"===e[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),t,r)},y.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(m(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},y.prototype._initArray=function(e,t,r){if(m("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var i,o,s=0;if("be"===r)for(n=e.length-1,i=0;0<=n;n-=3)o=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[i]|=o<<s&67108863,this.words[i+1]=o>>>26-s&67108863,26<=(s+=24)&&(s-=26,i++);else if("le"===r)for(i=n=0;n<e.length;n+=3)o=e[n]|e[n+1]<<8|e[n+2]<<16,this.words[i]|=o<<s&67108863,this.words[i+1]=o>>>26-s&67108863,26<=(s+=24)&&(s-=26,i++);return this.strip()},y.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var n,i,o=0;for(r=e.length-6,n=0;t<=r;r-=6)i=s(e,r,r+6),this.words[n]|=i<<o&67108863,this.words[n+1]|=i>>>26-o&4194303,26<=(o+=24)&&(o-=26,n++);r+6!==t&&(i=s(e,t,r+6),this.words[n]|=i<<o&67108863,this.words[n+1]|=i>>>26-o&4194303),this.strip()},y.prototype._parseBase=function(e,t,r){this.words=[0];for(var n=0,i=this.length=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,s=o%n,a=Math.min(o,o-s)+r,u=0,f=r;f<a;f+=n)u=h(e,f,f+n,t),this.imuln(i),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(0!==s){var c=1;for(u=h(e,f,e.length,t),f=0;f<s;f++)c*=t;this.imuln(c),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}},y.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},y.prototype.clone=function(){var e=new y(null);return this.copy(e),e},y.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},y.prototype.strip=function(){for(;1<this.length&&0===this.words[this.length-1];)this.length--;return this._normSign()},y.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},y.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var d=["","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"],l=[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],p=[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 i(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;n=(r.length=n)-1|0;var i=0|e.words[0],o=0|t.words[0],s=i*o,a=67108863&s,u=s/67108864|0;r.words[0]=a;for(var f=1;f<n;f++){for(var c=u>>>26,h=67108863&u,d=Math.min(f,t.length-1),l=Math.max(0,f-e.length+1);l<=d;l++){var p=f-l|0;c+=(s=(i=0|e.words[p])*(o=0|t.words[l])+h)/67108864|0,h=67108863&s}r.words[f]=0|h,u=0|c}return 0!==u?r.words[f]=0|u:r.length--,r.strip()}y.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,i=0,o=0;o<this.length;o++){var s=this.words[o],a=(16777215&(s<<n|i)).toString(16);r=0!==(i=s>>>24-n&16777215)||o!==this.length-1?d[6-a.length]+a+r:a+r,26<=(n+=2)&&(n-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&2<=e&&e<=36){var u=l[e],f=p[e];r="";var c=this.clone();for(c.negative=0;!c.isZero();){var h=c.modn(f).toString(e);r=(c=c.idivn(f)).isZero()?h+r:d[u-h.length]+h+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}m(!1,"Base should be between 2 and 36")},y.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:2<this.length&&m(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},y.prototype.toJSON=function(){return this.toString(16)},y.prototype.toBuffer=function(e,t){return m(void 0!==n),this.toArrayLike(n,e,t)},y.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},y.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),i=r||Math.max(1,n);m(n<=i,"byte array longer than desired length"),m(0<i,"Requested array length <= 0"),this.strip();var o,s,a="le"===t,u=new e(i),f=this.clone();if(a){for(s=0;!f.isZero();s++)o=f.andln(255),f.iushrn(8),u[s]=o;for(;s<i;s++)u[s]=0}else{for(s=0;s<i-n;s++)u[s]=0;for(s=0;!f.isZero();s++)o=f.andln(255),f.iushrn(8),u[i-s-1]=o}return u},y.prototype._countBits=Math.clz32?function(e){return 32-Math.clz32(e)}:function(e){var t=e,r=0;return 4096<=t&&(r+=13,t>>>=13),64<=t&&(r+=7,t>>>=7),8<=t&&(r+=4,t>>>=4),2<=t&&(r+=2,t>>>=2),r+t},y.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},y.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},y.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},y.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},y.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},y.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},y.prototype.isNeg=function(){return 0!==this.negative},y.prototype.neg=function(){return this.clone().ineg()},y.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},y.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this.strip()},y.prototype.ior=function(e){return m(0==(this.negative|e.negative)),this.iuor(e)},y.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},y.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},y.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this.strip()},y.prototype.iand=function(e){return m(0==(this.negative|e.negative)),this.iuand(e)},y.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},y.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},y.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this.strip()},y.prototype.ixor=function(e){return m(0==(this.negative|e.negative)),this.iuxor(e)},y.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},y.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},y.prototype.inotn=function(e){m("number"==typeof e&&0<=e);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),0<r&&t--;for(var n=0;n<t;n++)this.words[n]=67108863&~this.words[n];return 0<r&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},y.prototype.notn=function(e){return this.clone().inotn(e)},y.prototype.setn=function(e,t){m("number"==typeof e&&0<=e);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<<n:this.words[r]&~(1<<n),this.strip()},y.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o<n.length;o++)t=(0|r.words[o])+(0|n.words[o])+i,this.words[o]=67108863&t,i=t>>>26;for(;0!==i&&o<r.length;o++)t=(0|r.words[o])+i,this.words[o]=67108863&t,i=t>>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this},y.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},y.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;0<i?(r=this,n=e):(r=e,n=this);for(var o=0,s=0;s<n.length;s++)o=(t=(0|r.words[s])-(0|n.words[s])+o)>>26,this.words[s]=67108863&t;for(;0!==o&&s<r.length;s++)o=(t=(0|r.words[s])+o)>>26,this.words[s]=67108863&t;if(0===o&&s<r.length&&r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this.length=Math.max(this.length,s),r!==this&&(this.negative=1),this.strip()},y.prototype.sub=function(e){return this.clone().isub(e)};var o=function(e,t,r){var n,i,o,s=e.words,a=t.words,u=r.words,f=0,c=0|s[0],h=8191&c,d=c>>>13,l=0|s[1],p=8191&l,b=l>>>13,m=0|s[2],y=8191&m,v=m>>>13,g=0|s[3],w=8191&g,_=g>>>13,M=0|s[4],x=8191&M,k=M>>>13,S=0|s[5],E=8191&S,A=S>>>13,j=0|s[6],I=8191&j,B=j>>>13,T=0|s[7],C=8191&T,P=T>>>13,R=0|s[8],O=8191&R,N=R>>>13,L=0|s[9],q=8191&L,D=L>>>13,F=0|a[0],U=8191&F,H=F>>>13,z=0|a[1],K=8191&z,W=z>>>13,V=0|a[2],X=8191&V,G=V>>>13,J=0|a[3],Z=8191&J,$=J>>>13,Y=0|a[4],Q=8191&Y,ee=Y>>>13,te=0|a[5],re=8191&te,ne=te>>>13,ie=0|a[6],oe=8191&ie,se=ie>>>13,ae=0|a[7],ue=8191&ae,fe=ae>>>13,ce=0|a[8],he=8191&ce,de=ce>>>13,le=0|a[9],pe=8191&le,be=le>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(h,U))|0)+((8191&(i=(i=Math.imul(h,H))+Math.imul(d,U)|0))<<13)|0;f=((o=Math.imul(d,H))+(i>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(p,U),i=(i=Math.imul(p,H))+Math.imul(b,U)|0,o=Math.imul(b,H);var ye=(f+(n=n+Math.imul(h,K)|0)|0)+((8191&(i=(i=i+Math.imul(h,W)|0)+Math.imul(d,K)|0))<<13)|0;f=((o=o+Math.imul(d,W)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,U),i=(i=Math.imul(y,H))+Math.imul(v,U)|0,o=Math.imul(v,H),n=n+Math.imul(p,K)|0,i=(i=i+Math.imul(p,W)|0)+Math.imul(b,K)|0,o=o+Math.imul(b,W)|0;var ve=(f+(n=n+Math.imul(h,X)|0)|0)+((8191&(i=(i=i+Math.imul(h,G)|0)+Math.imul(d,X)|0))<<13)|0;f=((o=o+Math.imul(d,G)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(w,U),i=(i=Math.imul(w,H))+Math.imul(_,U)|0,o=Math.imul(_,H),n=n+Math.imul(y,K)|0,i=(i=i+Math.imul(y,W)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,W)|0,n=n+Math.imul(p,X)|0,i=(i=i+Math.imul(p,G)|0)+Math.imul(b,X)|0,o=o+Math.imul(b,G)|0;var ge=(f+(n=n+Math.imul(h,Z)|0)|0)+((8191&(i=(i=i+Math.imul(h,$)|0)+Math.imul(d,Z)|0))<<13)|0;f=((o=o+Math.imul(d,$)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(x,U),i=(i=Math.imul(x,H))+Math.imul(k,U)|0,o=Math.imul(k,H),n=n+Math.imul(w,K)|0,i=(i=i+Math.imul(w,W)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,W)|0,n=n+Math.imul(y,X)|0,i=(i=i+Math.imul(y,G)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,G)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,$)|0)+Math.imul(b,Z)|0,o=o+Math.imul(b,$)|0;var we=(f+(n=n+Math.imul(h,Q)|0)|0)+((8191&(i=(i=i+Math.imul(h,ee)|0)+Math.imul(d,Q)|0))<<13)|0;f=((o=o+Math.imul(d,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(E,U),i=(i=Math.imul(E,H))+Math.imul(A,U)|0,o=Math.imul(A,H),n=n+Math.imul(x,K)|0,i=(i=i+Math.imul(x,W)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,W)|0,n=n+Math.imul(w,X)|0,i=(i=i+Math.imul(w,G)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,G)|0,n=n+Math.imul(y,Z)|0,i=(i=i+Math.imul(y,$)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,$)|0,n=n+Math.imul(p,Q)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(b,Q)|0,o=o+Math.imul(b,ee)|0;var _e=(f+(n=n+Math.imul(h,re)|0)|0)+((8191&(i=(i=i+Math.imul(h,ne)|0)+Math.imul(d,re)|0))<<13)|0;f=((o=o+Math.imul(d,ne)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(I,U),i=(i=Math.imul(I,H))+Math.imul(B,U)|0,o=Math.imul(B,H),n=n+Math.imul(E,K)|0,i=(i=i+Math.imul(E,W)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,W)|0,n=n+Math.imul(x,X)|0,i=(i=i+Math.imul(x,G)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,G)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,$)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,$)|0,n=n+Math.imul(y,Q)|0,i=(i=i+Math.imul(y,ee)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0;var Me=(f+(n=n+Math.imul(h,oe)|0)|0)+((8191&(i=(i=i+Math.imul(h,se)|0)+Math.imul(d,oe)|0))<<13)|0;f=((o=o+Math.imul(d,se)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(C,U),i=(i=Math.imul(C,H))+Math.imul(P,U)|0,o=Math.imul(P,H),n=n+Math.imul(I,K)|0,i=(i=i+Math.imul(I,W)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,W)|0,n=n+Math.imul(E,X)|0,i=(i=i+Math.imul(E,G)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,G)|0,n=n+Math.imul(x,Z)|0,i=(i=i+Math.imul(x,$)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,$)|0,n=n+Math.imul(w,Q)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,ee)|0,n=n+Math.imul(y,re)|0,i=(i=i+Math.imul(y,ne)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,se)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,se)|0;var xe=(f+(n=n+Math.imul(h,ue)|0)|0)+((8191&(i=(i=i+Math.imul(h,fe)|0)+Math.imul(d,ue)|0))<<13)|0;f=((o=o+Math.imul(d,fe)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(O,U),i=(i=Math.imul(O,H))+Math.imul(N,U)|0,o=Math.imul(N,H),n=n+Math.imul(C,K)|0,i=(i=i+Math.imul(C,W)|0)+Math.imul(P,K)|0,o=o+Math.imul(P,W)|0,n=n+Math.imul(I,X)|0,i=(i=i+Math.imul(I,G)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,G)|0,n=n+Math.imul(E,Z)|0,i=(i=i+Math.imul(E,$)|0)+Math.imul(A,Z)|0,o=o+Math.imul(A,$)|0,n=n+Math.imul(x,Q)|0,i=(i=i+Math.imul(x,ee)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ne)|0,n=n+Math.imul(y,oe)|0,i=(i=i+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,fe)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,fe)|0;var ke=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(i=(i=i+Math.imul(h,de)|0)+Math.imul(d,he)|0))<<13)|0;f=((o=o+Math.imul(d,de)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(q,U),i=(i=Math.imul(q,H))+Math.imul(D,U)|0,o=Math.imul(D,H),n=n+Math.imul(O,K)|0,i=(i=i+Math.imul(O,W)|0)+Math.imul(N,K)|0,o=o+Math.imul(N,W)|0,n=n+Math.imul(C,X)|0,i=(i=i+Math.imul(C,G)|0)+Math.imul(P,X)|0,o=o+Math.imul(P,G)|0,n=n+Math.imul(I,Z)|0,i=(i=i+Math.imul(I,$)|0)+Math.imul(B,Z)|0,o=o+Math.imul(B,$)|0,n=n+Math.imul(E,Q)|0,i=(i=i+Math.imul(E,ee)|0)+Math.imul(A,Q)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(x,re)|0,i=(i=i+Math.imul(x,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,n=n+Math.imul(y,ue)|0,i=(i=i+Math.imul(y,fe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,fe)|0,n=n+Math.imul(p,he)|0,i=(i=i+Math.imul(p,de)|0)+Math.imul(b,he)|0,o=o+Math.imul(b,de)|0;var Se=(f+(n=n+Math.imul(h,pe)|0)|0)+((8191&(i=(i=i+Math.imul(h,be)|0)+Math.imul(d,pe)|0))<<13)|0;f=((o=o+Math.imul(d,be)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(q,K),i=(i=Math.imul(q,W))+Math.imul(D,K)|0,o=Math.imul(D,W),n=n+Math.imul(O,X)|0,i=(i=i+Math.imul(O,G)|0)+Math.imul(N,X)|0,o=o+Math.imul(N,G)|0,n=n+Math.imul(C,Z)|0,i=(i=i+Math.imul(C,$)|0)+Math.imul(P,Z)|0,o=o+Math.imul(P,$)|0,n=n+Math.imul(I,Q)|0,i=(i=i+Math.imul(I,ee)|0)+Math.imul(B,Q)|0,o=o+Math.imul(B,ee)|0,n=n+Math.imul(E,re)|0,i=(i=i+Math.imul(E,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(x,oe)|0,i=(i=i+Math.imul(x,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,fe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,fe)|0,n=n+Math.imul(y,he)|0,i=(i=i+Math.imul(y,de)|0)+Math.imul(v,he)|0,o=o+Math.imul(v,de)|0;var Ee=(f+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,be)|0)+Math.imul(b,pe)|0))<<13)|0;f=((o=o+Math.imul(b,be)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(q,X),i=(i=Math.imul(q,G))+Math.imul(D,X)|0,o=Math.imul(D,G),n=n+Math.imul(O,Z)|0,i=(i=i+Math.imul(O,$)|0)+Math.imul(N,Z)|0,o=o+Math.imul(N,$)|0,n=n+Math.imul(C,Q)|0,i=(i=i+Math.imul(C,ee)|0)+Math.imul(P,Q)|0,o=o+Math.imul(P,ee)|0,n=n+Math.imul(I,re)|0,i=(i=i+Math.imul(I,ne)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ne)|0,n=n+Math.imul(E,oe)|0,i=(i=i+Math.imul(E,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,n=n+Math.imul(x,ue)|0,i=(i=i+Math.imul(x,fe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,fe)|0,n=n+Math.imul(w,he)|0,i=(i=i+Math.imul(w,de)|0)+Math.imul(_,he)|0,o=o+Math.imul(_,de)|0;var Ae=(f+(n=n+Math.imul(y,pe)|0)|0)+((8191&(i=(i=i+Math.imul(y,be)|0)+Math.imul(v,pe)|0))<<13)|0;f=((o=o+Math.imul(v,be)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(q,Z),i=(i=Math.imul(q,$))+Math.imul(D,Z)|0,o=Math.imul(D,$),n=n+Math.imul(O,Q)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(N,Q)|0,o=o+Math.imul(N,ee)|0,n=n+Math.imul(C,re)|0,i=(i=i+Math.imul(C,ne)|0)+Math.imul(P,re)|0,o=o+Math.imul(P,ne)|0,n=n+Math.imul(I,oe)|0,i=(i=i+Math.imul(I,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,n=n+Math.imul(E,ue)|0,i=(i=i+Math.imul(E,fe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,fe)|0,n=n+Math.imul(x,he)|0,i=(i=i+Math.imul(x,de)|0)+Math.imul(k,he)|0,o=o+Math.imul(k,de)|0;var je=(f+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,be)|0)+Math.imul(_,pe)|0))<<13)|0;f=((o=o+Math.imul(_,be)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(q,Q),i=(i=Math.imul(q,ee))+Math.imul(D,Q)|0,o=Math.imul(D,ee),n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(N,re)|0,o=o+Math.imul(N,ne)|0,n=n+Math.imul(C,oe)|0,i=(i=i+Math.imul(C,se)|0)+Math.imul(P,oe)|0,o=o+Math.imul(P,se)|0,n=n+Math.imul(I,ue)|0,i=(i=i+Math.imul(I,fe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,fe)|0,n=n+Math.imul(E,he)|0,i=(i=i+Math.imul(E,de)|0)+Math.imul(A,he)|0,o=o+Math.imul(A,de)|0;var Ie=(f+(n=n+Math.imul(x,pe)|0)|0)+((8191&(i=(i=i+Math.imul(x,be)|0)+Math.imul(k,pe)|0))<<13)|0;f=((o=o+Math.imul(k,be)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(q,re),i=(i=Math.imul(q,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(O,oe)|0,i=(i=i+Math.imul(O,se)|0)+Math.imul(N,oe)|0,o=o+Math.imul(N,se)|0,n=n+Math.imul(C,ue)|0,i=(i=i+Math.imul(C,fe)|0)+Math.imul(P,ue)|0,o=o+Math.imul(P,fe)|0,n=n+Math.imul(I,he)|0,i=(i=i+Math.imul(I,de)|0)+Math.imul(B,he)|0,o=o+Math.imul(B,de)|0;var Be=(f+(n=n+Math.imul(E,pe)|0)|0)+((8191&(i=(i=i+Math.imul(E,be)|0)+Math.imul(A,pe)|0))<<13)|0;f=((o=o+Math.imul(A,be)|0)+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,n=Math.imul(q,oe),i=(i=Math.imul(q,se))+Math.imul(D,oe)|0,o=Math.imul(D,se),n=n+Math.imul(O,ue)|0,i=(i=i+Math.imul(O,fe)|0)+Math.imul(N,ue)|0,o=o+Math.imul(N,fe)|0,n=n+Math.imul(C,he)|0,i=(i=i+Math.imul(C,de)|0)+Math.imul(P,he)|0,o=o+Math.imul(P,de)|0;var Te=(f+(n=n+Math.imul(I,pe)|0)|0)+((8191&(i=(i=i+Math.imul(I,be)|0)+Math.imul(B,pe)|0))<<13)|0;f=((o=o+Math.imul(B,be)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(q,ue),i=(i=Math.imul(q,fe))+Math.imul(D,ue)|0,o=Math.imul(D,fe),n=n+Math.imul(O,he)|0,i=(i=i+Math.imul(O,de)|0)+Math.imul(N,he)|0,o=o+Math.imul(N,de)|0;var Ce=(f+(n=n+Math.imul(C,pe)|0)|0)+((8191&(i=(i=i+Math.imul(C,be)|0)+Math.imul(P,pe)|0))<<13)|0;f=((o=o+Math.imul(P,be)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(q,he),i=(i=Math.imul(q,de))+Math.imul(D,he)|0,o=Math.imul(D,de);var Pe=(f+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,be)|0)+Math.imul(N,pe)|0))<<13)|0;f=((o=o+Math.imul(N,be)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863;var Re=(f+(n=Math.imul(q,pe))|0)+((8191&(i=(i=Math.imul(q,be))+Math.imul(D,pe)|0))<<13)|0;return f=((o=Math.imul(D,be))+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,u[0]=me,u[1]=ye,u[2]=ve,u[3]=ge,u[4]=we,u[5]=_e,u[6]=Me,u[7]=xe,u[8]=ke,u[9]=Se,u[10]=Ee,u[11]=Ae,u[12]=je,u[13]=Ie,u[14]=Be,u[15]=Te,u[16]=Ce,u[17]=Pe,u[18]=Re,0!==f&&(u[19]=f,r.length++),r};function a(e,t,r){return(new u).mulp(e,t,r)}function u(e,t){this.x=e,this.y=t}Math.imul||(o=i),y.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?o(this,e,t):r<63?i(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o<r.length-1;o++){var s=i;i=0;for(var a=67108863&n,u=Math.min(o,t.length-1),f=Math.max(0,o-e.length+1);f<=u;f++){var c=o-f,h=(0|e.words[c])*(0|t.words[f]),d=67108863&h;a=67108863&(d=d+a|0),i+=(s=(s=s+(h/67108864|0)|0)+(d>>>26)|0)>>>26,s&=67108863}r.words[o]=a,n=s,s=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):a(this,e,t)},u.prototype.makeRBT=function(e){for(var t=new Array(e),r=y.prototype._countBits(e)-1,n=0;n<e;n++)t[n]=this.revBin(n,r,e);return t},u.prototype.revBin=function(e,t,r){if(0===e||e===r-1)return e;for(var n=0,i=0;i<t;i++)n|=(1&e)<<t-i-1,e>>=1;return n},u.prototype.permute=function(e,t,r,n,i,o){for(var s=0;s<o;s++)n[s]=t[e[s]],i[s]=r[e[s]]},u.prototype.transform=function(e,t,r,n,i,o){this.permute(o,e,t,r,n,i);for(var s=1;s<i;s<<=1)for(var a=s<<1,u=Math.cos(2*Math.PI/a),f=Math.sin(2*Math.PI/a),c=0;c<i;c+=a)for(var h=u,d=f,l=0;l<s;l++){var p=r[c+l],b=n[c+l],m=r[c+l+s],y=n[c+l+s],v=h*m-d*y;y=h*y+d*m,m=v,r[c+l]=p+m,n[c+l]=b+y,r[c+l+s]=p-m,n[c+l+s]=b-y,l!==a&&(v=u*h-f*d,d=u*d+f*h,h=v)}},u.prototype.guessLen13b=function(e,t){var r=1|Math.max(t,e),n=1&r,i=0;for(r=r/2|0;r;r>>>=1)i++;return 1<<i+1+n},u.prototype.conjugate=function(e,t,r){if(!(r<=1))for(var n=0;n<r/2;n++){var i=e[n];e[n]=e[r-n-1],e[r-n-1]=i,i=t[n],t[n]=-t[r-n-1],t[r-n-1]=-i}},u.prototype.normalize13b=function(e,t){for(var r=0,n=0;n<t/2;n++){var i=8192*Math.round(e[2*n+1]/t)+Math.round(e[2*n]/t)+r;e[n]=67108863&i,r=i<67108864?0:i/67108864|0}return e},u.prototype.convert13b=function(e,t,r,n){for(var i=0,o=0;o<t;o++)i+=0|e[o],r[2*o]=8191&i,i>>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o<n;++o)r[o]=0;m(0===i),m(0==(-8192&i))},u.prototype.stub=function(e){for(var t=new Array(e),r=0;r<e;r++)t[r]=0;return t},u.prototype.mulp=function(e,t,r){var n=2*this.guessLen13b(e.length,t.length),i=this.makeRBT(n),o=this.stub(n),s=new Array(n),a=new Array(n),u=new Array(n),f=new Array(n),c=new Array(n),h=new Array(n),d=r.words;d.length=n,this.convert13b(e.words,e.length,s,n),this.convert13b(t.words,t.length,f,n),this.transform(s,o,a,u,n,i),this.transform(f,o,c,h,n,i);for(var l=0;l<n;l++){var p=a[l]*c[l]-u[l]*h[l];u[l]=a[l]*h[l]+u[l]*c[l],a[l]=p}return this.conjugate(a,u,n),this.transform(a,u,d,o,n,i),this.conjugate(d,o,n),this.normalize13b(d,n),r.negative=e.negative^t.negative,r.length=e.length+t.length,r.strip()},y.prototype.mul=function(e){var t=new y(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},y.prototype.mulf=function(e){var t=new y(null);return t.words=new Array(this.length+e.length),a(this,e,t)},y.prototype.imul=function(e){return this.clone().mulTo(e,this)},y.prototype.imuln=function(e){m("number"==typeof e),m(e<67108864);for(var t=0,r=0;r<this.length;r++){var n=(0|this.words[r])*e,i=(67108863&n)+(67108863&t);t>>=26,t+=n/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},y.prototype.muln=function(e){return this.clone().imuln(e)},y.prototype.sqr=function(){return this.mul(this)},y.prototype.isqr=function(){return this.imul(this.clone())},y.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,i=r%26;t[r]=(e.words[n]&1<<i)>>>i}return t}(e);if(0===t.length)return new y(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},y.prototype.iushln=function(e){m("number"==typeof e&&0<=e);var t,r=e%26,n=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t<this.length;t++){var s=this.words[t]&i,a=(0|this.words[t])-s<<r;this.words[t]=a|o,o=s>>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==n){for(t=this.length-1;0<=t;t--)this.words[t+n]=this.words[t];for(t=0;t<n;t++)this.words[t]=0;this.length+=n}return this.strip()},y.prototype.ishln=function(e){return m(0===this.negative),this.iushln(e)},y.prototype.iushrn=function(e,t,r){var n;m("number"==typeof e&&0<=e),n=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),s=67108863^67108863>>>i<<i,a=r;if(n-=o,n=Math.max(0,n),a){for(var u=0;u<o;u++)a.words[u]=this.words[u];a.length=o}if(0===o);else if(this.length>o)for(this.length-=o,u=0;u<this.length;u++)this.words[u]=this.words[u+o];else this.words[0]=0,this.length=1;var f=0;for(u=this.length-1;0<=u&&(0!==f||n<=u);u--){var c=0|this.words[u];this.words[u]=f<<26-i|c>>>i,f=c&s}return a&&0!==f&&(a.words[a.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},y.prototype.ishrn=function(e,t,r){return m(0===this.negative),this.iushrn(e,t,r)},y.prototype.shln=function(e){return this.clone().ishln(e)},y.prototype.ushln=function(e){return this.clone().iushln(e)},y.prototype.shrn=function(e){return this.clone().ishrn(e)},y.prototype.ushrn=function(e){return this.clone().iushrn(e)},y.prototype.testn=function(e){m("number"==typeof e&&0<=e);var t=e%26,r=(e-t)/26,n=1<<t;return!(this.length<=r)&&!!(this.words[r]&n)},y.prototype.imaskn=function(e){m("number"==typeof e&&0<=e);var t=e%26,r=(e-t)/26;if(m(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<<t;this.words[this.length-1]&=n}return this.strip()},y.prototype.maskn=function(e){return this.clone().imaskn(e)},y.prototype.iaddn=function(e){return m("number"==typeof e),m(e<67108864),e<0?this.isubn(-e):0!==this.negative?(1===this.length&&(0|this.words[0])<e?(this.words[0]=e-(0|this.words[0]),this.negative=0):(this.negative=0,this.isubn(e),this.negative=1),this):this._iaddn(e)},y.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&67108864<=this.words[t];t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},y.prototype.isubn=function(e){if(m("number"==typeof e),m(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this.strip()},y.prototype.addn=function(e){return this.clone().iaddn(e)},y.prototype.subn=function(e){return this.clone().isubn(e)},y.prototype.iabs=function(){return this.negative=0,this},y.prototype.abs=function(){return this.clone().iabs()},y.prototype._ishlnsubmul=function(e,t,r){var n,i,o=e.length+r;this._expand(o);var s=0;for(n=0;n<e.length;n++){i=(0|this.words[n+r])+s;var a=(0|e.words[n])*t;s=((i-=67108863&a)>>26)-(a/67108864|0),this.words[n+r]=67108863&i}for(;n<this.length-r;n++)s=(i=(0|this.words[n+r])+s)>>26,this.words[n+r]=67108863&i;if(0===s)return this.strip();for(m(-1===s),n=s=0;n<this.length;n++)s=(i=-(0|this.words[n])+s)>>26,this.words[n]=67108863&i;return this.negative=1,this.strip()},y.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,o=0|i.words[i.length-1];0!==(r=26-this._countBits(o))&&(i=i.ushln(r),n.iushln(r),o=0|i.words[i.length-1]);var s,a=n.length-i.length;if("mod"!==t){(s=new y(null)).length=a+1,s.words=new Array(s.length);for(var u=0;u<s.length;u++)s.words[u]=0}var f=n.clone()._ishlnsubmul(i,1,a);0===f.negative&&(n=f,s&&(s.words[a]=1));for(var c=a-1;0<=c;c--){var h=67108864*(0|n.words[i.length+c])+(0|n.words[i.length+c-1]);for(h=Math.min(h/o|0,67108863),n._ishlnsubmul(i,h,c);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,c),n.isZero()||(n.negative^=1);s&&(s.words[c]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},y.prototype.divmod=function(e,t,r){return m(!e.isZero()),this.isZero()?{div:new y(0),mod:new y(0)}:0!==this.negative&&0===e.negative?(o=this.neg().divmod(e,t),"mod"!==t&&(n=o.div.neg()),"div"!==t&&(i=o.mod.neg(),r&&0!==i.negative&&i.iadd(e)),{div:n,mod:i}):0===this.negative&&0!==e.negative?(o=this.divmod(e.neg(),t),"mod"!==t&&(n=o.div.neg()),{div:n,mod:o.mod}):0!=(this.negative&e.negative)?(o=this.neg().divmod(e.neg(),t),"div"!==t&&(i=o.mod.neg(),r&&0!==i.negative&&i.isub(e)),{div:o.div,mod:i}):e.length>this.length||this.cmp(e)<0?{div:new y(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new y(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new y(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,i,o},y.prototype.div=function(e){return this.divmod(e,"div",!1).div},y.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},y.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},y.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},y.prototype.modn=function(e){m(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;0<=n;n--)r=(t*r+(0|this.words[n]))%e;return r},y.prototype.idivn=function(e){m(e<=67108863);for(var t=0,r=this.length-1;0<=r;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},y.prototype.divn=function(e){return this.clone().idivn(e)},y.prototype.egcd=function(e){m(0===e.negative),m(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new y(1),i=new y(0),o=new y(0),s=new y(1),a=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++a;for(var u=r.clone(),f=t.clone();!t.isZero();){for(var c=0,h=1;0==(t.words[0]&h)&&c<26;++c,h<<=1);if(0<c)for(t.iushrn(c);0<c--;)(n.isOdd()||i.isOdd())&&(n.iadd(u),i.isub(f)),n.iushrn(1),i.iushrn(1);for(var d=0,l=1;0==(r.words[0]&l)&&d<26;++d,l<<=1);if(0<d)for(r.iushrn(d);0<d--;)(o.isOdd()||s.isOdd())&&(o.iadd(u),s.isub(f)),o.iushrn(1),s.iushrn(1);0<=t.cmp(r)?(t.isub(r),n.isub(o),i.isub(s)):(r.isub(t),o.isub(n),s.isub(i))}return{a:o,b:s,gcd:r.iushln(a)}},y.prototype._invmp=function(e){m(0===e.negative),m(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,i=new y(1),o=new y(0),s=r.clone();0<t.cmpn(1)&&0<r.cmpn(1);){for(var a=0,u=1;0==(t.words[0]&u)&&a<26;++a,u<<=1);if(0<a)for(t.iushrn(a);0<a--;)i.isOdd()&&i.iadd(s),i.iushrn(1);for(var f=0,c=1;0==(r.words[0]&c)&&f<26;++f,c<<=1);if(0<f)for(r.iushrn(f);0<f--;)o.isOdd()&&o.iadd(s),o.iushrn(1);0<=t.cmp(r)?(t.isub(r),i.isub(o)):(r.isub(t),o.isub(i))}return(n=0===t.cmpn(1)?i:o).cmpn(0)<0&&n.iadd(e),n},y.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0;for(var n=r.negative=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},y.prototype.invm=function(e){return this.egcd(e).a.umod(e)},y.prototype.isEven=function(){return 0==(1&this.words[0])},y.prototype.isOdd=function(){return 1==(1&this.words[0])},y.prototype.andln=function(e){return this.words[0]&e},y.prototype.bincn=function(e){m("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<<t;if(this.length<=r)return this._expand(r+1),this.words[r]|=n,this;for(var i=n,o=r;0!==i&&o<this.length;o++){var s=0|this.words[o];i=(s+=i)>>>26,s&=67108863,this.words[o]=s}return 0!==i&&(this.words[o]=i,this.length++),this},y.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},y.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),1<this.length)t=1;else{r&&(e=-e),m(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:n<e?-1:1}return 0!==this.negative?0|-t:t},y.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},y.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;0<=r;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){n<i?t=-1:i<n&&(t=1);break}}return t},y.prototype.gtn=function(e){return 1===this.cmpn(e)},y.prototype.gt=function(e){return 1===this.cmp(e)},y.prototype.gten=function(e){return 0<=this.cmpn(e)},y.prototype.gte=function(e){return 0<=this.cmp(e)},y.prototype.ltn=function(e){return-1===this.cmpn(e)},y.prototype.lt=function(e){return-1===this.cmp(e)},y.prototype.lten=function(e){return this.cmpn(e)<=0},y.prototype.lte=function(e){return this.cmp(e)<=0},y.prototype.eqn=function(e){return 0===this.cmpn(e)},y.prototype.eq=function(e){return 0===this.cmp(e)},y.red=function(e){return new _(e)},y.prototype.toRed=function(e){return m(!this.red,"Already a number in reduction context"),m(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},y.prototype.fromRed=function(){return m(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},y.prototype._forceRed=function(e){return this.red=e,this},y.prototype.forceRed=function(e){return m(!this.red,"Already a number in reduction context"),this._forceRed(e)},y.prototype.redAdd=function(e){return m(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},y.prototype.redIAdd=function(e){return m(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},y.prototype.redSub=function(e){return m(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},y.prototype.redISub=function(e){return m(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},y.prototype.redShl=function(e){return m(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},y.prototype.redMul=function(e){return m(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},y.prototype.redIMul=function(e){return m(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},y.prototype.redSqr=function(){return m(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},y.prototype.redISqr=function(){return m(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},y.prototype.redSqrt=function(){return m(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},y.prototype.redInvm=function(){return m(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},y.prototype.redNeg=function(){return m(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},y.prototype.redPow=function(e){return m(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var f={k256:null,p224:null,p192:null,p25519:null};function c(e,t){this.name=e,this.p=new y(t,16),this.n=this.p.bitLength(),this.k=new y(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){c.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function v(){c.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function g(){c.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function w(){c.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"==typeof e){var t=y._prime(e);this.m=t.p,this.prime=t}else m(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new y(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)}c.prototype._tmp=function(){var e=new y(null);return e.words=new Array(Math.ceil(this.n/13)),e},c.prototype.ireduce=function(e){for(var t,r=e;this.split(r,this.tmp),(t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength())>this.n;);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):0<n?r.isub(this.p):r.strip(),r},c.prototype.split=function(e,t){e.iushrn(this.n,0,t)},c.prototype.imulK=function(e){return e.imul(this.k)},r(b,c),b.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n<r;n++)t.words[n]=e.words[n];if(t.length=r,e.length<=9)return e.words[0]=0,void(e.length=1);var i=e.words[9];for(t.words[t.length++]=4194303&i,n=10;n<e.length;n++){var o=0|e.words[n];e.words[n-10]=(4194303&o)<<4|i>>>22,i=o}i>>>=22,0===(e.words[n-10]=i)&&10<e.length?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},r(v,c),r(g,c),r(w,c),w.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,i=67108863&n;n>>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},y._prime=function(e){if(f[e])return f[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new v;else if("p192"===e)t=new g;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new w}return f[e]=t},_.prototype._verify1=function(e){m(0===e.negative,"red works only with positives"),m(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){m(0==(e.negative|t.negative),"red works only with positives"),m(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return 0<=r.cmp(this.m)&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return 0<=r.cmp(this.m)&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(m(t%2==1),3===t){var r=this.m.add(new y(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),i=0;!n.isZero()&&0===n.andln(1);)i++,n.iushrn(1);m(!n.isZero());var o=new y(1).toRed(this),s=o.redNeg(),a=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new y(2*u*u).toRed(this);0!==this.pow(u,a).cmp(s);)u.redIAdd(s);for(var f=this.pow(u,n),c=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),d=i;0!==h.cmp(o);){for(var l=h,p=0;0!==l.cmp(o);p++)l=l.redSqr();m(p<d);var b=this.pow(f,new y(1).iushln(d-p-1));c=c.redMul(b),f=b.redSqr(),h=h.redMul(f),d=p}return c},_.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},_.prototype.pow=function(e,t){if(t.isZero())return new y(1);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new y(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],o=0,s=0,a=t.bitLength()%26;for(0===a&&(a=26),n=t.length-1;0<=n;n--){for(var u=t.words[n],f=a-1;0<=f;f--){var c=u>>f&1;i!==r[0]&&(i=this.sqr(i)),0!==c||0!==o?(o<<=1,o|=c,(4===++s||0===n&&0===f)&&(i=this.mul(i,r[o]),o=s=0)):s=0}a=26}return i},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},y.mont=function(e){return new M(e)},r(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return 0<=i.cmp(this.m)?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new y(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return 0<=i.cmp(this.m)?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(void 0===e||e,this)},{}],220:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],221:[function(e,t,r){var i=e("underscore"),o=e("web3-utils"),s=e("bn.js"),a=e("./param"),u=function(e){return i.isNumber(e)&&(e=Math.trunc(e)),new a(o.toTwosComplement(e).replace("0x",""))};t.exports={formatInputInt:u,formatInputBytes:function(e){if(!o.isHexStrict(e))throw new Error('Given parameter is not bytes: "'+e+'"');var t=e.replace(/^0x/i,"");if(t.length%2!=0)throw new Error('Given parameter bytes has an invalid length: "'+e+'"');if(64<t.length)throw new Error('Given parameter bytes is too long: "'+e+'"');var r=Math.floor((t.length+63)/64);return t=o.padRight(t,64*r),new a(t)},formatInputDynamicBytes:function(e){if(!o.isHexStrict(e))throw new Error('Given parameter is not bytes: "'+e+'"');var t=e.replace(/^0x/i,"");if(t.length%2!=0)throw new Error('Given parameter bytes has an invalid length: "'+e+'"');var r=t.length/2,n=Math.floor((t.length+63)/64);return t=o.padRight(t,64*n),new a(u(r).value+t)},formatInputString:function(e){if(!i.isString(e))throw new Error("Given parameter is not a valid string: "+e);var t=o.utf8ToHex(e).replace(/^0x/i,""),r=t.length/2,n=Math.floor((t.length+63)/64);return t=o.padRight(t,64*n),new a(u(r).value+t)},formatInputBool:function(e){return new a("000000000000000000000000000000000000000000000000000000000000000"+(e?"1":"0"))},formatOutputInt:function(e){var t=e.staticPart();if(!t&&!e.rawValue)throw new Error("Couldn't decode "+name+" from ABI: 0x"+e.rawValue);return"1"===new s(t.substr(0,1),16).toString(2).substr(0,1)?new s(t,16).fromTwos(256).toString(10):new s(t,16).toString(10)},formatOutputUInt:function(e,t){var r=e.staticPart();if(!r&&!e.rawValue)throw new Error("Couldn't decode "+t+" from ABI: 0x"+e.rawValue);return new s(r,16).toString(10)},formatOutputBool:function(e,t){var r=e.staticPart();if(!r&&!e.rawValue)throw new Error("Couldn't decode "+t+" from ABI: 0x"+e.rawValue);return"0000000000000000000000000000000000000000000000000000000000000001"===r},formatOutputBytes:function(e,t){var r=t.match(/^bytes([0-9]*)/),n=parseInt(r[1]);if(e.staticPart().slice(0,2*n).length!==2*n)throw new Error("Couldn't decode "+t+" from ABI: 0x"+e.rawValue+" The size doesn't match.");return"0x"+e.staticPart().slice(0,2*n)},formatOutputDynamicBytes:function(e,t){var r=e.dynamicPart().slice(0,64);if(!r)throw new Error("Couldn't decode "+t+" from ABI: 0x"+e.rawValue);var n=2*new s(r,16).toNumber();return"0x"+e.dynamicPart().substr(64,n)},formatOutputString:function(e){var t=e.dynamicPart().slice(0,64);if(!t)throw new Error("ERROR: The returned value is not a convertible string:"+t);var r=2*new s(t,16).toNumber();return r?o.hexToUtf8("0x"+e.dynamicPart().substr(64,r).replace(/^0x/i,"")):""},formatOutputAddress:function(e,t){var r=e.staticPart();if(!r)throw new Error("Couldn't decode "+t+" from ABI: 0x"+e.rawValue);return o.toChecksumAddress("0x"+r.slice(r.length-40,r.length))},toTwosComplement:o.toTwosComplement}},{"./param":223,"bn.js":219,underscore:220,"web3-utils":408}],222:[function(e,t,r){var c=e("underscore"),n=e("web3-utils"),d=e("./formatters"),i=e("./types/address"),o=e("./types/bool"),s=e("./types/int"),a=e("./types/uint"),u=e("./types/dynamicbytes"),f=e("./types/string"),h=e("./types/bytes"),l=function(e,t){return e.isDynamicType(t)||e.isDynamicArray(t)};function p(){}var b=function(e){this._types=e};b.prototype._requireType=function(t){var e=this._types.filter(function(e){return e.isType(t)})[0];if(!e)throw Error("Invalid solidity type: "+t);return e},b.prototype._getOffsets=function(r,n){for(var e=n.map(function(e,t){return e.staticPartLength(r[t])}),t=1;t<e.length;t++)e[t]+=e[t-1];return e.map(function(e,t){return e-n[t].staticPartLength(r[t])})},b.prototype._getSolidityTypes=function(e){var t=this;return e.map(function(e){return t._requireType(e)})},b.prototype._encodeMultiWithOffset=function(n,i,o,s){var a="",u=this;return n.forEach(function(e,t){if(l(i[t],n[t])){a+=d.formatInputInt(s).encode();var r=u._encodeWithOffset(n[t],i[t],o[t],s);s+=r.length/2}else a+=u._encodeWithOffset(n[t],i[t],o[t],s)}),n.forEach(function(e,t){if(l(i[t],n[t])){var r=u._encodeWithOffset(n[t],i[t],o[t],s);s+=r.length/2,a+=r}}),a},b.prototype._encodeWithOffset=function(e,r,n,i){var o,s,a,u,f,c,h=this;return r.isDynamicArray(e)?(u=r.nestedName(e),f=r.staticPartLength(u),c=n[0],function(){var e=2;if(r.isDynamicArray(u))for(var t=1;t<n.length;t++)e+=+n[t-1][0]||0,c+=d.formatInputInt(i+t*f+32*e).encode()}(),function(){for(var e=0;e<n.length-1;e++){var t=c/2;c+=h._encodeWithOffset(u,r,n[e+1],i+t)}}(),c):r.isStaticArray(e)?(o=r.nestedName(e),s=r.staticPartLength(o),a="",r.isDynamicArray(o)&&function(){for(var e=0,t=0;t<n.length;t++)e+=+(n[t-1]||[])[0]||0,a+=d.formatInputInt(i+t*s+32*e).encode()}(),function(){for(var e=0;e<n.length;e++){var t=a/2;a+=h._encodeWithOffset(o,r,n[e],i+t)}}(),a):n},b.prototype.encodeFunctionSignature=function(e){return c.isObject(e)&&(e=n._jsonInterfaceMethodToString(e)),n.sha3(e).slice(0,10)},b.prototype.encodeEventSignature=function(e){return c.isObject(e)&&(e=n._jsonInterfaceMethodToString(e)),n.sha3(e)},b.prototype.encodeParameter=function(e,t){return this.encodeParameters([e],[t])},b.prototype.encodeParameters=function(o,r){c.isObject(o)&&o.inputs&&(o=c.map(o.inputs,function(e){return e.type}));var s=this._getSolidityTypes(o),e=s.map(function(e,t){return e.encode(r[t],o[t])}),t=s.reduce(function(e,t,r){var n=t.staticPartLength(o[r]),i=32*Math.floor((n+31)/32);return e+(l(s[r],o[r])?32:i)},0);return"0x"+this._encodeMultiWithOffset(o,s,e,t)},b.prototype.encodeFunctionCall=function(e,t){return this.encodeFunctionSignature(e)+this.encodeParameters(e,t).replace("0x","")},b.prototype.decodeParameter=function(e,t){if(!c.isString(e))throw new Error("Given parameter type is not a string: "+e);return this.decodeParameters([{type:e}],t)[0]},b.prototype.decodeParameters=function(e,n){var t=c.isArray(e)&&c.isString(e[0]),i=t?e:[];t||e.forEach(function(e){i.push(e.type)});var o=this._getSolidityTypes(i),s=this._getOffsets(i,o),a=new p,u=a.__length__=0;return e.forEach(function(e,t){var r=o[u].decode(n.replace(/^0x/i,""),s[u],i[u],u);r="0x"===r?null:r,a[t]=r,c.isObject(e)&&e.name&&(a[e.name]=r),a.__length__++,u++}),a},b.prototype.decodeLog=function(e,t,r){t=t||"";var n=[],i=[];e.forEach(function(e,t){e.indexed?i[t]=e:n[t]=e});var o=t.slice(2),s=c.isArray(r)?r.map(function(e){return e.slice(2)}).join(""):r,a=this.decodeParameters(n,o),u=this.decodeParameters(i,s),f=new p;return f.__length__=0,e.forEach(function(e,t){f[t]="string"===e.type?"":null,a[t]&&(f[t]=a[t]),u[t]&&(f[t]=u[t]),e.name&&(f[e.name]=f[t]),f.__length__++}),f};var m=new b([new i,new o,new s,new a,new u,new h,new f]);t.exports=m},{"./formatters":221,"./types/address":225,"./types/bool":226,"./types/bytes":227,"./types/dynamicbytes":228,"./types/int":229,"./types/string":230,"./types/uint":231,underscore:220,"web3-utils":408}],223:[function(e,t,r){var n=e("./formatters.js"),i=function(e,t,r){this.value=e||"",this.offset=t,this.rawValue=r};i.prototype.dynamicPartLength=function(){return this.dynamicPart().length/2},i.prototype.withOffset=function(e){return new i(this.value,e)},i.prototype.combine=function(e){return new i(this.value+e.value)},i.prototype.isDynamic=function(){return void 0!==this.offset},i.prototype.offsetAsBytes=function(){return this.isDynamic()?n.toTwosComplement(this.offset).replace("0x",""):""},i.prototype.staticPart=function(){return this.isDynamic()?this.offsetAsBytes():this.value},i.prototype.dynamicPart=function(){return this.isDynamic()?this.value:""},i.prototype.encode=function(){return this.staticPart()+this.dynamicPart()},i.encodeList=function(e){var r=32*e.length,t=e.map(function(e){if(!e.isDynamic())return e;var t=r;return r+=e.dynamicPartLength(),e.withOffset(t)});return t.reduce(function(e,t){return e+t.dynamicPart()},t.reduce(function(e,t){return e+t.staticPart()},""))},t.exports=i},{"./formatters.js":221}],224:[function(e,t,r){var n=e("./formatters"),s=e("./param"),i=function(e){this._inputFormatter=e.inputFormatter,this._outputFormatter=e.outputFormatter};i.prototype.isType=function(e){throw"This method should be overwritten for type "+e},i.prototype.staticPartLength=function(e){return(this.nestedTypes(e)||["[1]"]).map(function(e){return parseInt(e.slice(1,-1),10)||1}).reduce(function(e,t){return e*t},32)},i.prototype.isDynamicArray=function(e){var t=this.nestedTypes(e);return!!t&&!t[t.length-1].match(/[0-9]{1,}/g)},i.prototype.isStaticArray=function(e){var t=this.nestedTypes(e);return!!t&&!!t[t.length-1].match(/[0-9]{1,}/g)},i.prototype.staticArrayLength=function(e){var t=this.nestedTypes(e);return t?parseInt(t[t.length-1].match(/[0-9]{1,}/g)||1):1},i.prototype.nestedName=function(e){var t=this.nestedTypes(e);return t?e.substr(0,e.length-t[t.length-1].length):e},i.prototype.isDynamicType=function(){return!1},i.prototype.nestedTypes=function(e){return e.match(/(\[[0-9]*\])/g)},i.prototype.encode=function(i,o){var e,t,r,s=this;return this.isDynamicArray(o)?(e=i.length,t=s.nestedName(o),(r=[]).push(n.formatInputInt(e).encode()),i.forEach(function(e){r.push(s.encode(e,t))}),r):this.isStaticArray(o)?function(){for(var e=s.staticArrayLength(o),t=s.nestedName(o),r=[],n=0;n<e;n++)r.push(s.encode(i[n],t));return r}():this._inputFormatter(i,o).encode()},i.prototype.decode=function(u,f,c){var e,t,r,n,h=this;if(this.isDynamicArray(c))return function(){for(var e=parseInt("0x"+u.substr(2*f,64)),t=parseInt("0x"+u.substr(2*e,64)),r=e+32,n=h.nestedName(c),i=h.staticPartLength(n),o=32*Math.floor((i+31)/32),s=[],a=0;a<t*o;a+=o)s.push(h.decode(u,r+a,n));return s}();if(this.isStaticArray(c))return function(){for(var e=h.staticArrayLength(c),t=f,r=h.nestedName(c),n=h.staticPartLength(r),i=32*Math.floor((n+31)/32),o=[],s=0;s<e*i;s+=i)o.push(h.decode(u,t+s,r));return o}();if(this.isDynamicType(c))return e=parseInt("0x"+u.substr(2*f,64)),t=parseInt("0x"+u.substr(2*e,64)),r=Math.floor((t+31)/32),n=new s(u.substr(2*e,64*(1+r)),0,u),h._outputFormatter(n,c);var i=this.staticPartLength(c),o=new s(u.substr(2*f,2*i),void 0,u);return this._outputFormatter(o,c)},t.exports=i},{"./formatters":221,"./param":223}],225:[function(e,t,r){var n=e("../formatters"),i=e("web3-core-helpers").formatters,o=e("../type"),s=function(){this._inputFormatter=function(){var e=Array.prototype.slice.call(arguments);return e[0]=e[0]&&"0x0"!==e[0]?i.inputAddressFormatter(e[0]):"",n.formatInputInt.apply(this,e)},this._outputFormatter=n.formatOutputAddress};((s.prototype=new o({})).constructor=s).prototype.isType=function(e){return!!e.match(/address(\[([0-9]*)\])?/)},t.exports=s},{"../formatters":221,"../type":224,"web3-core-helpers":200}],226:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputBool,this._outputFormatter=n.formatOutputBool};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^bool(\[([0-9]*)\])*$/)},t.exports=o},{"../formatters":221,"../type":224}],227:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputBytes,this._outputFormatter=n.formatOutputBytes};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^bytes([0-9]{1,})(\[([0-9]*)\])*$/)},t.exports=o},{"../formatters":221,"../type":224}],228:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputDynamicBytes,this._outputFormatter=n.formatOutputDynamicBytes};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^bytes(\[([0-9]*)\])*$/)},o.prototype.isDynamicType=function(){return!0},t.exports=o},{"../formatters":221,"../type":224}],229:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputInt,this._outputFormatter=n.formatOutputInt};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^int([0-9]*)?(\[([0-9]*)\])*$/)},t.exports=o},{"../formatters":221,"../type":224}],230:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputString,this._outputFormatter=n.formatOutputString};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^string(\[([0-9]*)\])*$/)},o.prototype.isDynamicType=function(){return!0},t.exports=o},{"../formatters":221,"../type":224}],231:[function(e,t,r){var n=e("../formatters"),i=e("../type"),o=function(){this._inputFormatter=n.formatInputInt,this._outputFormatter=n.formatOutputUInt};((o.prototype=new i({})).constructor=o).prototype.isType=function(e){return!!e.match(/^uint([0-9]*)?(\[([0-9]*)\])*$/)},t.exports=o},{"../formatters":221,"../type":224}],232:[function(e,t,r){arguments[4][203][0].apply(r,arguments)},{"./register":234,dup:203}],233:[function(e,t,r){arguments[4][204][0].apply(r,arguments)},{dup:204}],234:[function(e,t,r){arguments[4][205][0].apply(r,arguments)},{"./loader":233,dup:205}],235:[function(e,t,r){arguments[4][1][0].apply(r,arguments)},{"./asn1/api":236,"./asn1/base":238,"./asn1/constants":242,"./asn1/decoders":244,"./asn1/encoders":247,"bn.js":249,dup:1}],236:[function(e,t,r){arguments[4][2][0].apply(r,arguments)},{"../asn1":235,dup:2,inherits:334,vm:169}],237:[function(e,t,r){arguments[4][3][0].apply(r,arguments)},{"../base":238,buffer:48,dup:3,inherits:334}],238:[function(e,t,r){arguments[4][4][0].apply(r,arguments)},{"./buffer":237,"./node":239,"./reporter":240,dup:4}],239:[function(e,t,r){arguments[4][5][0].apply(r,arguments)},{"../base":238,dup:5,"minimalistic-assert":338}],240:[function(e,t,r){arguments[4][6][0].apply(r,arguments)},{dup:6,inherits:334}],241:[function(e,t,r){arguments[4][7][0].apply(r,arguments)},{"../constants":242,dup:7}],242:[function(e,t,r){arguments[4][8][0].apply(r,arguments)},{"./der":241,dup:8}],243:[function(e,t,r){arguments[4][9][0].apply(r,arguments)},{"../../asn1":235,dup:9,inherits:334}],244:[function(e,t,r){arguments[4][10][0].apply(r,arguments)},{"./der":243,"./pem":245,dup:10}],245:[function(e,t,r){arguments[4][11][0].apply(r,arguments)},{"./der":243,buffer:48,dup:11,inherits:334}],246:[function(e,t,r){arguments[4][12][0].apply(r,arguments)},{"../../asn1":235,buffer:48,dup:12,inherits:334}],247:[function(e,t,r){arguments[4][13][0].apply(r,arguments)},{"./der":246,"./pem":248,dup:13}],248:[function(e,t,r){arguments[4][14][0].apply(r,arguments)},{"./der":246,dup:14,inherits:334}],249:[function(x,e,t){!function(e,t){function m(e,t){if(!e)throw new Error(t||"Assertion failed")}function r(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function y(e,t,r){if(y.isBN(e))return e;this.negative=0,this.words=null,this.length=0,(this.red=null)!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var n;"object"===(void 0===e?"undefined":_typeof(e))?e.exports=y:t.BN=y,(y.BN=y).wordSize=26;try{n=x("buffer").Buffer}catch(e){}function s(e,t,r){for(var n=0,i=Math.min(e.length,r),o=t;o<i;o++){var s=e.charCodeAt(o)-48;n<<=4,n|=49<=s&&s<=54?s-49+10:17<=s&&s<=22?s-17+10:15&s}return n}function h(e,t,r,n){for(var i=0,o=Math.min(e.length,r),s=t;s<o;s++){var a=e.charCodeAt(s)-48;i*=n,i+=49<=a?a-49+10:17<=a?a-17+10:a}return i}y.isBN=function(e){return e instanceof y||null!==e&&"object"===(void 0===e?"undefined":_typeof(e))&&e.constructor.wordSize===y.wordSize&&Array.isArray(e.words)},y.max=function(e,t){return 0<e.cmp(t)?e:t},y.min=function(e,t){return e.cmp(t)<0?e:t},y.prototype._init=function(e,t,r){if("number"==typeof e)return this._initNumber(e,t,r);if("object"===(void 0===e?"undefined":_typeof(e)))return this._initArray(e,t,r);"hex"===t&&(t=16),m(t===(0|t)&&2<=t&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&n++,16===t?this._parseHex(e,n):this._parseBase(e,t,n),"-"===e[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),t,r)},y.prototype._initNumber=function(e,t,r){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(m(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},y.prototype._initArray=function(e,t,r){if(m("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var i,o,s=0;if("be"===r)for(n=e.length-1,i=0;0<=n;n-=3)o=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[i]|=o<<s&67108863,this.words[i+1]=o>>>26-s&67108863,26<=(s+=24)&&(s-=26,i++);else if("le"===r)for(i=n=0;n<e.length;n+=3)o=e[n]|e[n+1]<<8|e[n+2]<<16,this.words[i]|=o<<s&67108863,this.words[i+1]=o>>>26-s&67108863,26<=(s+=24)&&(s-=26,i++);return this.strip()},y.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var n,i,o=0;for(r=e.length-6,n=0;t<=r;r-=6)i=s(e,r,r+6),this.words[n]|=i<<o&67108863,this.words[n+1]|=i>>>26-o&4194303,26<=(o+=24)&&(o-=26,n++);r+6!==t&&(i=s(e,t,r+6),this.words[n]|=i<<o&67108863,this.words[n+1]|=i>>>26-o&4194303),this.strip()},y.prototype._parseBase=function(e,t,r){this.words=[0];for(var n=0,i=this.length=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,s=o%n,a=Math.min(o,o-s)+r,u=0,f=r;f<a;f+=n)u=h(e,f,f+n,t),this.imuln(i),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(0!==s){var c=1;for(u=h(e,f,e.length,t),f=0;f<s;f++)c*=t;this.imuln(c),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}},y.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},y.prototype.clone=function(){var e=new y(null);return this.copy(e),e},y.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},y.prototype.strip=function(){for(;1<this.length&&0===this.words[this.length-1];)this.length--;return this._normSign()},y.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},y.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var d=["","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"],l=[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],p=[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 i(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;n=(r.length=n)-1|0;var i=0|e.words[0],o=0|t.words[0],s=i*o,a=67108863&s,u=s/67108864|0;r.words[0]=a;for(var f=1;f<n;f++){for(var c=u>>>26,h=67108863&u,d=Math.min(f,t.length-1),l=Math.max(0,f-e.length+1);l<=d;l++){var p=f-l|0;c+=(s=(i=0|e.words[p])*(o=0|t.words[l])+h)/67108864|0,h=67108863&s}r.words[f]=0|h,u=0|c}return 0!==u?r.words[f]=0|u:r.length--,r.strip()}y.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var n=0,i=0,o=0;o<this.length;o++){var s=this.words[o],a=(16777215&(s<<n|i)).toString(16);r=0!==(i=s>>>24-n&16777215)||o!==this.length-1?d[6-a.length]+a+r:a+r,26<=(n+=2)&&(n-=26,o--)}for(0!==i&&(r=i.toString(16)+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&2<=e&&e<=36){var u=l[e],f=p[e];r="";var c=this.clone();for(c.negative=0;!c.isZero();){var h=c.modn(f).toString(e);r=(c=c.idivn(f)).isZero()?h+r:d[u-h.length]+h+r}for(this.isZero()&&(r="0"+r);r.length%t!=0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}m(!1,"Base should be between 2 and 36")},y.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:2<this.length&&m(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},y.prototype.toJSON=function(){return this.toString(16)},y.prototype.toBuffer=function(e,t){return m(void 0!==n),this.toArrayLike(n,e,t)},y.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},y.prototype.toArrayLike=function(e,t,r){var n=this.byteLength(),i=r||Math.max(1,n);m(n<=i,"byte array longer than desired length"),m(0<i,"Requested array length <= 0"),this.strip();var o,s,a="le"===t,u=new e(i),f=this.clone();if(a){for(s=0;!f.isZero();s++)o=f.andln(255),f.iushrn(8),u[s]=o;for(;s<i;s++)u[s]=0}else{for(s=0;s<i-n;s++)u[s]=0;for(s=0;!f.isZero();s++)o=f.andln(255),f.iushrn(8),u[i-s-1]=o}return u},y.prototype._countBits=Math.clz32?function(e){return 32-Math.clz32(e)}:function(e){var t=e,r=0;return 4096<=t&&(r+=13,t>>>=13),64<=t&&(r+=7,t>>>=7),8<=t&&(r+=4,t>>>=4),2<=t&&(r+=2,t>>>=2),r+t},y.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,r=0;return 0==(8191&t)&&(r+=13,t>>>=13),0==(127&t)&&(r+=7,t>>>=7),0==(15&t)&&(r+=4,t>>>=4),0==(3&t)&&(r+=2,t>>>=2),0==(1&t)&&r++,r},y.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},y.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var r=this._zeroBits(this.words[t]);if(e+=r,26!==r)break}return e},y.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},y.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},y.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},y.prototype.isNeg=function(){return 0!==this.negative},y.prototype.neg=function(){return this.clone().ineg()},y.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},y.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this.strip()},y.prototype.ior=function(e){return m(0==(this.negative|e.negative)),this.iuor(e)},y.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},y.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},y.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;r<t.length;r++)this.words[r]=this.words[r]&e.words[r];return this.length=t.length,this.strip()},y.prototype.iand=function(e){return m(0==(this.negative|e.negative)),this.iuand(e)},y.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},y.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},y.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;n<r.length;n++)this.words[n]=t.words[n]^r.words[n];if(this!==t)for(;n<t.length;n++)this.words[n]=t.words[n];return this.length=t.length,this.strip()},y.prototype.ixor=function(e){return m(0==(this.negative|e.negative)),this.iuxor(e)},y.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},y.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},y.prototype.inotn=function(e){m("number"==typeof e&&0<=e);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),0<r&&t--;for(var n=0;n<t;n++)this.words[n]=67108863&~this.words[n];return 0<r&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},y.prototype.notn=function(e){return this.clone().inotn(e)},y.prototype.setn=function(e,t){m("number"==typeof e&&0<=e);var r=e/26|0,n=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<<n:this.words[r]&~(1<<n),this.strip()},y.prototype.iadd=function(e){var t,r,n;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o<n.length;o++)t=(0|r.words[o])+(0|n.words[o])+i,this.words[o]=67108863&t,i=t>>>26;for(;0!==i&&o<r.length;o++)t=(0|r.words[o])+i,this.words[o]=67108863&t,i=t>>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;o<r.length;o++)this.words[o]=r.words[o];return this},y.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},y.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var r,n,i=this.cmp(e);if(0===i)return this.negative=0,this.length=1,this.words[0]=0,this;0<i?(r=this,n=e):(r=e,n=this);for(var o=0,s=0;s<n.length;s++)o=(t=(0|r.words[s])-(0|n.words[s])+o)>>26,this.words[s]=67108863&t;for(;0!==o&&s<r.length;s++)o=(t=(0|r.words[s])+o)>>26,this.words[s]=67108863&t;if(0===o&&s<r.length&&r!==this)for(;s<r.length;s++)this.words[s]=r.words[s];return this.length=Math.max(this.length,s),r!==this&&(this.negative=1),this.strip()},y.prototype.sub=function(e){return this.clone().isub(e)};var o=function(e,t,r){var n,i,o,s=e.words,a=t.words,u=r.words,f=0,c=0|s[0],h=8191&c,d=c>>>13,l=0|s[1],p=8191&l,b=l>>>13,m=0|s[2],y=8191&m,v=m>>>13,g=0|s[3],w=8191&g,_=g>>>13,M=0|s[4],x=8191&M,k=M>>>13,S=0|s[5],E=8191&S,A=S>>>13,j=0|s[6],I=8191&j,B=j>>>13,T=0|s[7],C=8191&T,P=T>>>13,R=0|s[8],O=8191&R,N=R>>>13,L=0|s[9],q=8191&L,D=L>>>13,F=0|a[0],U=8191&F,H=F>>>13,z=0|a[1],K=8191&z,W=z>>>13,V=0|a[2],X=8191&V,G=V>>>13,J=0|a[3],Z=8191&J,$=J>>>13,Y=0|a[4],Q=8191&Y,ee=Y>>>13,te=0|a[5],re=8191&te,ne=te>>>13,ie=0|a[6],oe=8191&ie,se=ie>>>13,ae=0|a[7],ue=8191&ae,fe=ae>>>13,ce=0|a[8],he=8191&ce,de=ce>>>13,le=0|a[9],pe=8191&le,be=le>>>13;r.negative=e.negative^t.negative,r.length=19;var me=(f+(n=Math.imul(h,U))|0)+((8191&(i=(i=Math.imul(h,H))+Math.imul(d,U)|0))<<13)|0;f=((o=Math.imul(d,H))+(i>>>13)|0)+(me>>>26)|0,me&=67108863,n=Math.imul(p,U),i=(i=Math.imul(p,H))+Math.imul(b,U)|0,o=Math.imul(b,H);var ye=(f+(n=n+Math.imul(h,K)|0)|0)+((8191&(i=(i=i+Math.imul(h,W)|0)+Math.imul(d,K)|0))<<13)|0;f=((o=o+Math.imul(d,W)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(y,U),i=(i=Math.imul(y,H))+Math.imul(v,U)|0,o=Math.imul(v,H),n=n+Math.imul(p,K)|0,i=(i=i+Math.imul(p,W)|0)+Math.imul(b,K)|0,o=o+Math.imul(b,W)|0;var ve=(f+(n=n+Math.imul(h,X)|0)|0)+((8191&(i=(i=i+Math.imul(h,G)|0)+Math.imul(d,X)|0))<<13)|0;f=((o=o+Math.imul(d,G)|0)+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(w,U),i=(i=Math.imul(w,H))+Math.imul(_,U)|0,o=Math.imul(_,H),n=n+Math.imul(y,K)|0,i=(i=i+Math.imul(y,W)|0)+Math.imul(v,K)|0,o=o+Math.imul(v,W)|0,n=n+Math.imul(p,X)|0,i=(i=i+Math.imul(p,G)|0)+Math.imul(b,X)|0,o=o+Math.imul(b,G)|0;var ge=(f+(n=n+Math.imul(h,Z)|0)|0)+((8191&(i=(i=i+Math.imul(h,$)|0)+Math.imul(d,Z)|0))<<13)|0;f=((o=o+Math.imul(d,$)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(x,U),i=(i=Math.imul(x,H))+Math.imul(k,U)|0,o=Math.imul(k,H),n=n+Math.imul(w,K)|0,i=(i=i+Math.imul(w,W)|0)+Math.imul(_,K)|0,o=o+Math.imul(_,W)|0,n=n+Math.imul(y,X)|0,i=(i=i+Math.imul(y,G)|0)+Math.imul(v,X)|0,o=o+Math.imul(v,G)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,$)|0)+Math.imul(b,Z)|0,o=o+Math.imul(b,$)|0;var we=(f+(n=n+Math.imul(h,Q)|0)|0)+((8191&(i=(i=i+Math.imul(h,ee)|0)+Math.imul(d,Q)|0))<<13)|0;f=((o=o+Math.imul(d,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(E,U),i=(i=Math.imul(E,H))+Math.imul(A,U)|0,o=Math.imul(A,H),n=n+Math.imul(x,K)|0,i=(i=i+Math.imul(x,W)|0)+Math.imul(k,K)|0,o=o+Math.imul(k,W)|0,n=n+Math.imul(w,X)|0,i=(i=i+Math.imul(w,G)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,G)|0,n=n+Math.imul(y,Z)|0,i=(i=i+Math.imul(y,$)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,$)|0,n=n+Math.imul(p,Q)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(b,Q)|0,o=o+Math.imul(b,ee)|0;var _e=(f+(n=n+Math.imul(h,re)|0)|0)+((8191&(i=(i=i+Math.imul(h,ne)|0)+Math.imul(d,re)|0))<<13)|0;f=((o=o+Math.imul(d,ne)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(I,U),i=(i=Math.imul(I,H))+Math.imul(B,U)|0,o=Math.imul(B,H),n=n+Math.imul(E,K)|0,i=(i=i+Math.imul(E,W)|0)+Math.imul(A,K)|0,o=o+Math.imul(A,W)|0,n=n+Math.imul(x,X)|0,i=(i=i+Math.imul(x,G)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,G)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,$)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,$)|0,n=n+Math.imul(y,Q)|0,i=(i=i+Math.imul(y,ee)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(b,re)|0,o=o+Math.imul(b,ne)|0;var Me=(f+(n=n+Math.imul(h,oe)|0)|0)+((8191&(i=(i=i+Math.imul(h,se)|0)+Math.imul(d,oe)|0))<<13)|0;f=((o=o+Math.imul(d,se)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(C,U),i=(i=Math.imul(C,H))+Math.imul(P,U)|0,o=Math.imul(P,H),n=n+Math.imul(I,K)|0,i=(i=i+Math.imul(I,W)|0)+Math.imul(B,K)|0,o=o+Math.imul(B,W)|0,n=n+Math.imul(E,X)|0,i=(i=i+Math.imul(E,G)|0)+Math.imul(A,X)|0,o=o+Math.imul(A,G)|0,n=n+Math.imul(x,Z)|0,i=(i=i+Math.imul(x,$)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,$)|0,n=n+Math.imul(w,Q)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,ee)|0,n=n+Math.imul(y,re)|0,i=(i=i+Math.imul(y,ne)|0)+Math.imul(v,re)|0,o=o+Math.imul(v,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,se)|0)+Math.imul(b,oe)|0,o=o+Math.imul(b,se)|0;var xe=(f+(n=n+Math.imul(h,ue)|0)|0)+((8191&(i=(i=i+Math.imul(h,fe)|0)+Math.imul(d,ue)|0))<<13)|0;f=((o=o+Math.imul(d,fe)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(O,U),i=(i=Math.imul(O,H))+Math.imul(N,U)|0,o=Math.imul(N,H),n=n+Math.imul(C,K)|0,i=(i=i+Math.imul(C,W)|0)+Math.imul(P,K)|0,o=o+Math.imul(P,W)|0,n=n+Math.imul(I,X)|0,i=(i=i+Math.imul(I,G)|0)+Math.imul(B,X)|0,o=o+Math.imul(B,G)|0,n=n+Math.imul(E,Z)|0,i=(i=i+Math.imul(E,$)|0)+Math.imul(A,Z)|0,o=o+Math.imul(A,$)|0,n=n+Math.imul(x,Q)|0,i=(i=i+Math.imul(x,ee)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(w,re)|0,i=(i=i+Math.imul(w,ne)|0)+Math.imul(_,re)|0,o=o+Math.imul(_,ne)|0,n=n+Math.imul(y,oe)|0,i=(i=i+Math.imul(y,se)|0)+Math.imul(v,oe)|0,o=o+Math.imul(v,se)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,fe)|0)+Math.imul(b,ue)|0,o=o+Math.imul(b,fe)|0;var ke=(f+(n=n+Math.imul(h,he)|0)|0)+((8191&(i=(i=i+Math.imul(h,de)|0)+Math.imul(d,he)|0))<<13)|0;f=((o=o+Math.imul(d,de)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(q,U),i=(i=Math.imul(q,H))+Math.imul(D,U)|0,o=Math.imul(D,H),n=n+Math.imul(O,K)|0,i=(i=i+Math.imul(O,W)|0)+Math.imul(N,K)|0,o=o+Math.imul(N,W)|0,n=n+Math.imul(C,X)|0,i=(i=i+Math.imul(C,G)|0)+Math.imul(P,X)|0,o=o+Math.imul(P,G)|0,n=n+Math.imul(I,Z)|0,i=(i=i+Math.imul(I,$)|0)+Math.imul(B,Z)|0,o=o+Math.imul(B,$)|0,n=n+Math.imul(E,Q)|0,i=(i=i+Math.imul(E,ee)|0)+Math.imul(A,Q)|0,o=o+Math.imul(A,ee)|0,n=n+Math.imul(x,re)|0,i=(i=i+Math.imul(x,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,se)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,se)|0,n=n+Math.imul(y,ue)|0,i=(i=i+Math.imul(y,fe)|0)+Math.imul(v,ue)|0,o=o+Math.imul(v,fe)|0,n=n+Math.imul(p,he)|0,i=(i=i+Math.imul(p,de)|0)+Math.imul(b,he)|0,o=o+Math.imul(b,de)|0;var Se=(f+(n=n+Math.imul(h,pe)|0)|0)+((8191&(i=(i=i+Math.imul(h,be)|0)+Math.imul(d,pe)|0))<<13)|0;f=((o=o+Math.imul(d,be)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(q,K),i=(i=Math.imul(q,W))+Math.imul(D,K)|0,o=Math.imul(D,W),n=n+Math.imul(O,X)|0,i=(i=i+Math.imul(O,G)|0)+Math.imul(N,X)|0,o=o+Math.imul(N,G)|0,n=n+Math.imul(C,Z)|0,i=(i=i+Math.imul(C,$)|0)+Math.imul(P,Z)|0,o=o+Math.imul(P,$)|0,n=n+Math.imul(I,Q)|0,i=(i=i+Math.imul(I,ee)|0)+Math.imul(B,Q)|0,o=o+Math.imul(B,ee)|0,n=n+Math.imul(E,re)|0,i=(i=i+Math.imul(E,ne)|0)+Math.imul(A,re)|0,o=o+Math.imul(A,ne)|0,n=n+Math.imul(x,oe)|0,i=(i=i+Math.imul(x,se)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,se)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,fe)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,fe)|0,n=n+Math.imul(y,he)|0,i=(i=i+Math.imul(y,de)|0)+Math.imul(v,he)|0,o=o+Math.imul(v,de)|0;var Ee=(f+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,be)|0)+Math.imul(b,pe)|0))<<13)|0;f=((o=o+Math.imul(b,be)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(q,X),i=(i=Math.imul(q,G))+Math.imul(D,X)|0,o=Math.imul(D,G),n=n+Math.imul(O,Z)|0,i=(i=i+Math.imul(O,$)|0)+Math.imul(N,Z)|0,o=o+Math.imul(N,$)|0,n=n+Math.imul(C,Q)|0,i=(i=i+Math.imul(C,ee)|0)+Math.imul(P,Q)|0,o=o+Math.imul(P,ee)|0,n=n+Math.imul(I,re)|0,i=(i=i+Math.imul(I,ne)|0)+Math.imul(B,re)|0,o=o+Math.imul(B,ne)|0,n=n+Math.imul(E,oe)|0,i=(i=i+Math.imul(E,se)|0)+Math.imul(A,oe)|0,o=o+Math.imul(A,se)|0,n=n+Math.imul(x,ue)|0,i=(i=i+Math.imul(x,fe)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,fe)|0,n=n+Math.imul(w,he)|0,i=(i=i+Math.imul(w,de)|0)+Math.imul(_,he)|0,o=o+Math.imul(_,de)|0;var Ae=(f+(n=n+Math.imul(y,pe)|0)|0)+((8191&(i=(i=i+Math.imul(y,be)|0)+Math.imul(v,pe)|0))<<13)|0;f=((o=o+Math.imul(v,be)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(q,Z),i=(i=Math.imul(q,$))+Math.imul(D,Z)|0,o=Math.imul(D,$),n=n+Math.imul(O,Q)|0,i=(i=i+Math.imul(O,ee)|0)+Math.imul(N,Q)|0,o=o+Math.imul(N,ee)|0,n=n+Math.imul(C,re)|0,i=(i=i+Math.imul(C,ne)|0)+Math.imul(P,re)|0,o=o+Math.imul(P,ne)|0,n=n+Math.imul(I,oe)|0,i=(i=i+Math.imul(I,se)|0)+Math.imul(B,oe)|0,o=o+Math.imul(B,se)|0,n=n+Math.imul(E,ue)|0,i=(i=i+Math.imul(E,fe)|0)+Math.imul(A,ue)|0,o=o+Math.imul(A,fe)|0,n=n+Math.imul(x,he)|0,i=(i=i+Math.imul(x,de)|0)+Math.imul(k,he)|0,o=o+Math.imul(k,de)|0;var je=(f+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,be)|0)+Math.imul(_,pe)|0))<<13)|0;f=((o=o+Math.imul(_,be)|0)+(i>>>13)|0)+(je>>>26)|0,je&=67108863,n=Math.imul(q,Q),i=(i=Math.imul(q,ee))+Math.imul(D,Q)|0,o=Math.imul(D,ee),n=n+Math.imul(O,re)|0,i=(i=i+Math.imul(O,ne)|0)+Math.imul(N,re)|0,o=o+Math.imul(N,ne)|0,n=n+Math.imul(C,oe)|0,i=(i=i+Math.imul(C,se)|0)+Math.imul(P,oe)|0,o=o+Math.imul(P,se)|0,n=n+Math.imul(I,ue)|0,i=(i=i+Math.imul(I,fe)|0)+Math.imul(B,ue)|0,o=o+Math.imul(B,fe)|0,n=n+Math.imul(E,he)|0,i=(i=i+Math.imul(E,de)|0)+Math.imul(A,he)|0,o=o+Math.imul(A,de)|0;var Ie=(f+(n=n+Math.imul(x,pe)|0)|0)+((8191&(i=(i=i+Math.imul(x,be)|0)+Math.imul(k,pe)|0))<<13)|0;f=((o=o+Math.imul(k,be)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(q,re),i=(i=Math.imul(q,ne))+Math.imul(D,re)|0,o=Math.imul(D,ne),n=n+Math.imul(O,oe)|0,i=(i=i+Math.imul(O,se)|0)+Math.imul(N,oe)|0,o=o+Math.imul(N,se)|0,n=n+Math.imul(C,ue)|0,i=(i=i+Math.imul(C,fe)|0)+Math.imul(P,ue)|0,o=o+Math.imul(P,fe)|0,n=n+Math.imul(I,he)|0,i=(i=i+Math.imul(I,de)|0)+Math.imul(B,he)|0,o=o+Math.imul(B,de)|0;var Be=(f+(n=n+Math.imul(E,pe)|0)|0)+((8191&(i=(i=i+Math.imul(E,be)|0)+Math.imul(A,pe)|0))<<13)|0;f=((o=o+Math.imul(A,be)|0)+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,n=Math.imul(q,oe),i=(i=Math.imul(q,se))+Math.imul(D,oe)|0,o=Math.imul(D,se),n=n+Math.imul(O,ue)|0,i=(i=i+Math.imul(O,fe)|0)+Math.imul(N,ue)|0,o=o+Math.imul(N,fe)|0,n=n+Math.imul(C,he)|0,i=(i=i+Math.imul(C,de)|0)+Math.imul(P,he)|0,o=o+Math.imul(P,de)|0;var Te=(f+(n=n+Math.imul(I,pe)|0)|0)+((8191&(i=(i=i+Math.imul(I,be)|0)+Math.imul(B,pe)|0))<<13)|0;f=((o=o+Math.imul(B,be)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(q,ue),i=(i=Math.imul(q,fe))+Math.imul(D,ue)|0,o=Math.imul(D,fe),n=n+Math.imul(O,he)|0,i=(i=i+Math.imul(O,de)|0)+Math.imul(N,he)|0,o=o+Math.imul(N,de)|0;var Ce=(f+(n=n+Math.imul(C,pe)|0)|0)+((8191&(i=(i=i+Math.imul(C,be)|0)+Math.imul(P,pe)|0))<<13)|0;f=((o=o+Math.imul(P,be)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(q,he),i=(i=Math.imul(q,de))+Math.imul(D,he)|0,o=Math.imul(D,de);var Pe=(f+(n=n+Math.imul(O,pe)|0)|0)+((8191&(i=(i=i+Math.imul(O,be)|0)+Math.imul(N,pe)|0))<<13)|0;f=((o=o+Math.imul(N,be)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863;var Re=(f+(n=Math.imul(q,pe))|0)+((8191&(i=(i=Math.imul(q,be))+Math.imul(D,pe)|0))<<13)|0;return f=((o=Math.imul(D,be))+(i>>>13)|0)+(Re>>>26)|0,Re&=67108863,u[0]=me,u[1]=ye,u[2]=ve,u[3]=ge,u[4]=we,u[5]=_e,u[6]=Me,u[7]=xe,u[8]=ke,u[9]=Se,u[10]=Ee,u[11]=Ae,u[12]=je,u[13]=Ie,u[14]=Be,u[15]=Te,u[16]=Ce,u[17]=Pe,u[18]=Re,0!==f&&(u[19]=f,r.length++),r};function a(e,t,r){return(new u).mulp(e,t,r)}function u(e,t){this.x=e,this.y=t}Math.imul||(o=i),y.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?o(this,e,t):r<63?i(this,e,t):r<1024?function(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o<r.length-1;o++){var s=i;i=0;for(var a=67108863&n,u=Math.min(o,t.length-1),f=Math.max(0,o-e.length+1);f<=u;f++){var c=o-f,h=(0|e.words[c])*(0|t.words[f]),d=67108863&h;a=67108863&(d=d+a|0),i+=(s=(s=s+(h/67108864|0)|0)+(d>>>26)|0)>>>26,s&=67108863}r.words[o]=a,n=s,s=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):a(this,e,t)},u.prototype.makeRBT=function(e){for(var t=new Array(e),r=y.prototype._countBits(e)-1,n=0;n<e;n++)t[n]=this.revBin(n,r,e);return t},u.prototype.revBin=function(e,t,r){if(0===e||e===r-1)return e;for(var n=0,i=0;i<t;i++)n|=(1&e)<<t-i-1,e>>=1;return n},u.prototype.permute=function(e,t,r,n,i,o){for(var s=0;s<o;s++)n[s]=t[e[s]],i[s]=r[e[s]]},u.prototype.transform=function(e,t,r,n,i,o){this.permute(o,e,t,r,n,i);for(var s=1;s<i;s<<=1)for(var a=s<<1,u=Math.cos(2*Math.PI/a),f=Math.sin(2*Math.PI/a),c=0;c<i;c+=a)for(var h=u,d=f,l=0;l<s;l++){var p=r[c+l],b=n[c+l],m=r[c+l+s],y=n[c+l+s],v=h*m-d*y;y=h*y+d*m,m=v,r[c+l]=p+m,n[c+l]=b+y,r[c+l+s]=p-m,n[c+l+s]=b-y,l!==a&&(v=u*h-f*d,d=u*d+f*h,h=v)}},u.prototype.guessLen13b=function(e,t){var r=1|Math.max(t,e),n=1&r,i=0;for(r=r/2|0;r;r>>>=1)i++;return 1<<i+1+n},u.prototype.conjugate=function(e,t,r){if(!(r<=1))for(var n=0;n<r/2;n++){var i=e[n];e[n]=e[r-n-1],e[r-n-1]=i,i=t[n],t[n]=-t[r-n-1],t[r-n-1]=-i}},u.prototype.normalize13b=function(e,t){for(var r=0,n=0;n<t/2;n++){var i=8192*Math.round(e[2*n+1]/t)+Math.round(e[2*n]/t)+r;e[n]=67108863&i,r=i<67108864?0:i/67108864|0}return e},u.prototype.convert13b=function(e,t,r,n){for(var i=0,o=0;o<t;o++)i+=0|e[o],r[2*o]=8191&i,i>>>=13,r[2*o+1]=8191&i,i>>>=13;for(o=2*t;o<n;++o)r[o]=0;m(0===i),m(0==(-8192&i))},u.prototype.stub=function(e){for(var t=new Array(e),r=0;r<e;r++)t[r]=0;return t},u.prototype.mulp=function(e,t,r){var n=2*this.guessLen13b(e.length,t.length),i=this.makeRBT(n),o=this.stub(n),s=new Array(n),a=new Array(n),u=new Array(n),f=new Array(n),c=new Array(n),h=new Array(n),d=r.words;d.length=n,this.convert13b(e.words,e.length,s,n),this.convert13b(t.words,t.length,f,n),this.transform(s,o,a,u,n,i),this.transform(f,o,c,h,n,i);for(var l=0;l<n;l++){var p=a[l]*c[l]-u[l]*h[l];u[l]=a[l]*h[l]+u[l]*c[l],a[l]=p}return this.conjugate(a,u,n),this.transform(a,u,d,o,n,i),this.conjugate(d,o,n),this.normalize13b(d,n),r.negative=e.negative^t.negative,r.length=e.length+t.length,r.strip()},y.prototype.mul=function(e){var t=new y(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},y.prototype.mulf=function(e){var t=new y(null);return t.words=new Array(this.length+e.length),a(this,e,t)},y.prototype.imul=function(e){return this.clone().mulTo(e,this)},y.prototype.imuln=function(e){m("number"==typeof e),m(e<67108864);for(var t=0,r=0;r<this.length;r++){var n=(0|this.words[r])*e,i=(67108863&n)+(67108863&t);t>>=26,t+=n/67108864|0,t+=i>>>26,this.words[r]=67108863&i}return 0!==t&&(this.words[r]=t,this.length++),this},y.prototype.muln=function(e){return this.clone().imuln(e)},y.prototype.sqr=function(){return this.mul(this)},y.prototype.isqr=function(){return this.imul(this.clone())},y.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r<t.length;r++){var n=r/26|0,i=r%26;t[r]=(e.words[n]&1<<i)>>>i}return t}(e);if(0===t.length)return new y(1);for(var r=this,n=0;n<t.length&&0===t[n];n++,r=r.sqr());if(++n<t.length)for(var i=r.sqr();n<t.length;n++,i=i.sqr())0!==t[n]&&(r=r.mul(i));return r},y.prototype.iushln=function(e){m("number"==typeof e&&0<=e);var t,r=e%26,n=(e-r)/26,i=67108863>>>26-r<<26-r;if(0!==r){var o=0;for(t=0;t<this.length;t++){var s=this.words[t]&i,a=(0|this.words[t])-s<<r;this.words[t]=a|o,o=s>>>26-r}o&&(this.words[t]=o,this.length++)}if(0!==n){for(t=this.length-1;0<=t;t--)this.words[t+n]=this.words[t];for(t=0;t<n;t++)this.words[t]=0;this.length+=n}return this.strip()},y.prototype.ishln=function(e){return m(0===this.negative),this.iushln(e)},y.prototype.iushrn=function(e,t,r){var n;m("number"==typeof e&&0<=e),n=t?(t-t%26)/26:0;var i=e%26,o=Math.min((e-i)/26,this.length),s=67108863^67108863>>>i<<i,a=r;if(n-=o,n=Math.max(0,n),a){for(var u=0;u<o;u++)a.words[u]=this.words[u];a.length=o}if(0===o);else if(this.length>o)for(this.length-=o,u=0;u<this.length;u++)this.words[u]=this.words[u+o];else this.words[0]=0,this.length=1;var f=0;for(u=this.length-1;0<=u&&(0!==f||n<=u);u--){var c=0|this.words[u];this.words[u]=f<<26-i|c>>>i,f=c&s}return a&&0!==f&&(a.words[a.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},y.prototype.ishrn=function(e,t,r){return m(0===this.negative),this.iushrn(e,t,r)},y.prototype.shln=function(e){return this.clone().ishln(e)},y.prototype.ushln=function(e){return this.clone().iushln(e)},y.prototype.shrn=function(e){return this.clone().ishrn(e)},y.prototype.ushrn=function(e){return this.clone().iushrn(e)},y.prototype.testn=function(e){m("number"==typeof e&&0<=e);var t=e%26,r=(e-t)/26,n=1<<t;return!(this.length<=r)&&!!(this.words[r]&n)},y.prototype.imaskn=function(e){m("number"==typeof e&&0<=e);var t=e%26,r=(e-t)/26;if(m(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==t&&r++,this.length=Math.min(r,this.length),0!==t){var n=67108863^67108863>>>t<<t;this.words[this.length-1]&=n}return this.strip()},y.prototype.maskn=function(e){return this.clone().imaskn(e)},y.prototype.iaddn=function(e){return m("number"==typeof e),m(e<67108864),e<0?this.isubn(-e):0!==this.negative?(1===this.length&&(0|this.words[0])<e?(this.words[0]=e-(0|this.words[0]),this.negative=0):(this.negative=0,this.isubn(e),this.negative=1),this):this._iaddn(e)},y.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&67108864<=this.words[t];t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},y.prototype.isubn=function(e){if(m("number"==typeof e),m(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this.strip()},y.prototype.addn=function(e){return this.clone().iaddn(e)},y.prototype.subn=function(e){return this.clone().isubn(e)},y.prototype.iabs=function(){return this.negative=0,this},y.prototype.abs=function(){return this.clone().iabs()},y.prototype._ishlnsubmul=function(e,t,r){var n,i,o=e.length+r;this._expand(o);var s=0;for(n=0;n<e.length;n++){i=(0|this.words[n+r])+s;var a=(0|e.words[n])*t;s=((i-=67108863&a)>>26)-(a/67108864|0),this.words[n+r]=67108863&i}for(;n<this.length-r;n++)s=(i=(0|this.words[n+r])+s)>>26,this.words[n+r]=67108863&i;if(0===s)return this.strip();for(m(-1===s),n=s=0;n<this.length;n++)s=(i=-(0|this.words[n])+s)>>26,this.words[n]=67108863&i;return this.negative=1,this.strip()},y.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,o=0|i.words[i.length-1];0!==(r=26-this._countBits(o))&&(i=i.ushln(r),n.iushln(r),o=0|i.words[i.length-1]);var s,a=n.length-i.length;if("mod"!==t){(s=new y(null)).length=a+1,s.words=new Array(s.length);for(var u=0;u<s.length;u++)s.words[u]=0}var f=n.clone()._ishlnsubmul(i,1,a);0===f.negative&&(n=f,s&&(s.words[a]=1));for(var c=a-1;0<=c;c--){var h=67108864*(0|n.words[i.length+c])+(0|n.words[i.length+c-1]);for(h=Math.min(h/o|0,67108863),n._ishlnsubmul(i,h,c);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,c),n.isZero()||(n.negative^=1);s&&(s.words[c]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},y.prototype.divmod=function(e,t,r){return m(!e.isZero()),this.isZero()?{div:new y(0),mod:new y(0)}:0!==this.negative&&0===e.negative?(o=this.neg().divmod(e,t),"mod"!==t&&(n=o.div.neg()),"div"!==t&&(i=o.mod.neg(),r&&0!==i.negative&&i.iadd(e)),{div:n,mod:i}):0===this.negative&&0!==e.negative?(o=this.divmod(e.neg(),t),"mod"!==t&&(n=o.div.neg()),{div:n,mod:o.mod}):0!=(this.negative&e.negative)?(o=this.neg().divmod(e.neg(),t),"div"!==t&&(i=o.mod.neg(),r&&0!==i.negative&&i.isub(e)),{div:o.div,mod:i}):e.length>this.length||this.cmp(e)<0?{div:new y(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new y(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new y(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,i,o},y.prototype.div=function(e){return this.divmod(e,"div",!1).div},y.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},y.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},y.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var r=0!==t.div.negative?t.mod.isub(e):t.mod,n=e.ushrn(1),i=e.andln(1),o=r.cmp(n);return o<0||1===i&&0===o?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},y.prototype.modn=function(e){m(e<=67108863);for(var t=(1<<26)%e,r=0,n=this.length-1;0<=n;n--)r=(t*r+(0|this.words[n]))%e;return r},y.prototype.idivn=function(e){m(e<=67108863);for(var t=0,r=this.length-1;0<=r;r--){var n=(0|this.words[r])+67108864*t;this.words[r]=n/e|0,t=n%e}return this.strip()},y.prototype.divn=function(e){return this.clone().idivn(e)},y.prototype.egcd=function(e){m(0===e.negative),m(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new y(1),i=new y(0),o=new y(0),s=new y(1),a=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++a;for(var u=r.clone(),f=t.clone();!t.isZero();){for(var c=0,h=1;0==(t.words[0]&h)&&c<26;++c,h<<=1);if(0<c)for(t.iushrn(c);0<c--;)(n.isOdd()||i.isOdd())&&(n.iadd(u),i.isub(f)),n.iushrn(1),i.iushrn(1);for(var d=0,l=1;0==(r.words[0]&l)&&d<26;++d,l<<=1);if(0<d)for(r.iushrn(d);0<d--;)(o.isOdd()||s.isOdd())&&(o.iadd(u),s.isub(f)),o.iushrn(1),s.iushrn(1);0<=t.cmp(r)?(t.isub(r),n.isub(o),i.isub(s)):(r.isub(t),o.isub(n),s.isub(i))}return{a:o,b:s,gcd:r.iushln(a)}},y.prototype._invmp=function(e){m(0===e.negative),m(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,i=new y(1),o=new y(0),s=r.clone();0<t.cmpn(1)&&0<r.cmpn(1);){for(var a=0,u=1;0==(t.words[0]&u)&&a<26;++a,u<<=1);if(0<a)for(t.iushrn(a);0<a--;)i.isOdd()&&i.iadd(s),i.iushrn(1);for(var f=0,c=1;0==(r.words[0]&c)&&f<26;++f,c<<=1);if(0<f)for(r.iushrn(f);0<f--;)o.isOdd()&&o.iadd(s),o.iushrn(1);0<=t.cmp(r)?(t.isub(r),i.isub(o)):(r.isub(t),o.isub(i))}return(n=0===t.cmpn(1)?i:o).cmpn(0)<0&&n.iadd(e),n},y.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),r=e.clone();t.negative=0;for(var n=r.negative=0;t.isEven()&&r.isEven();n++)t.iushrn(1),r.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;r.isEven();)r.iushrn(1);var i=t.cmp(r);if(i<0){var o=t;t=r,r=o}else if(0===i||0===r.cmpn(1))break;t.isub(r)}return r.iushln(n)},y.prototype.invm=function(e){return this.egcd(e).a.umod(e)},y.prototype.isEven=function(){return 0==(1&this.words[0])},y.prototype.isOdd=function(){return 1==(1&this.words[0])},y.prototype.andln=function(e){return this.words[0]&e},y.prototype.bincn=function(e){m("number"==typeof e);var t=e%26,r=(e-t)/26,n=1<<t;if(this.length<=r)return this._expand(r+1),this.words[r]|=n,this;for(var i=n,o=r;0!==i&&o<this.length;o++){var s=0|this.words[o];i=(s+=i)>>>26,s&=67108863,this.words[o]=s}return 0!==i&&(this.words[o]=i,this.length++),this},y.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},y.prototype.cmpn=function(e){var t,r=e<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),1<this.length)t=1;else{r&&(e=-e),m(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:n<e?-1:1}return 0!==this.negative?0|-t:t},y.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},y.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,r=this.length-1;0<=r;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){n<i?t=-1:i<n&&(t=1);break}}return t},y.prototype.gtn=function(e){return 1===this.cmpn(e)},y.prototype.gt=function(e){return 1===this.cmp(e)},y.prototype.gten=function(e){return 0<=this.cmpn(e)},y.prototype.gte=function(e){return 0<=this.cmp(e)},y.prototype.ltn=function(e){return-1===this.cmpn(e)},y.prototype.lt=function(e){return-1===this.cmp(e)},y.prototype.lten=function(e){return this.cmpn(e)<=0},y.prototype.lte=function(e){return this.cmp(e)<=0},y.prototype.eqn=function(e){return 0===this.cmpn(e)},y.prototype.eq=function(e){return 0===this.cmp(e)},y.red=function(e){return new _(e)},y.prototype.toRed=function(e){return m(!this.red,"Already a number in reduction context"),m(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},y.prototype.fromRed=function(){return m(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},y.prototype._forceRed=function(e){return this.red=e,this},y.prototype.forceRed=function(e){return m(!this.red,"Already a number in reduction context"),this._forceRed(e)},y.prototype.redAdd=function(e){return m(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},y.prototype.redIAdd=function(e){return m(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},y.prototype.redSub=function(e){return m(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},y.prototype.redISub=function(e){return m(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},y.prototype.redShl=function(e){return m(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},y.prototype.redMul=function(e){return m(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},y.prototype.redIMul=function(e){return m(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},y.prototype.redSqr=function(){return m(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},y.prototype.redISqr=function(){return m(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},y.prototype.redSqrt=function(){return m(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},y.prototype.redInvm=function(){return m(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},y.prototype.redNeg=function(){return m(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},y.prototype.redPow=function(e){return m(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var f={k256:null,p224:null,p192:null,p25519:null};function c(e,t){this.name=e,this.p=new y(t,16),this.n=this.p.bitLength(),this.k=new y(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){c.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function v(){c.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function g(){c.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function w(){c.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function _(e){if("string"==typeof e){var t=y._prime(e);this.m=t.p,this.prime=t}else m(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){_.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new y(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)}c.prototype._tmp=function(){var e=new y(null);return e.words=new Array(Math.ceil(this.n/13)),e},c.prototype.ireduce=function(e){for(var t,r=e;this.split(r,this.tmp),(t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength())>this.n;);var n=t<this.n?-1:r.ucmp(this.p);return 0===n?(r.words[0]=0,r.length=1):0<n?r.isub(this.p):r.strip(),r},c.prototype.split=function(e,t){e.iushrn(this.n,0,t)},c.prototype.imulK=function(e){return e.imul(this.k)},r(b,c),b.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n<r;n++)t.words[n]=e.words[n];if(t.length=r,e.length<=9)return e.words[0]=0,void(e.length=1);var i=e.words[9];for(t.words[t.length++]=4194303&i,n=10;n<e.length;n++){var o=0|e.words[n];e.words[n-10]=(4194303&o)<<4|i>>>22,i=o}i>>>=22,0===(e.words[n-10]=i)&&10<e.length?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,r=0;r<e.length;r++){var n=0|e.words[r];t+=977*n,e.words[r]=67108863&t,t=64*n+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},r(v,c),r(g,c),r(w,c),w.prototype.imulK=function(e){for(var t=0,r=0;r<e.length;r++){var n=19*(0|e.words[r])+t,i=67108863&n;n>>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},y._prime=function(e){if(f[e])return f[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new v;else if("p192"===e)t=new g;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new w}return f[e]=t},_.prototype._verify1=function(e){m(0===e.negative,"red works only with positives"),m(e.red,"red works only with red numbers")},_.prototype._verify2=function(e,t){m(0==(e.negative|t.negative),"red works only with positives"),m(e.red&&e.red===t.red,"red works only with red numbers")},_.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},_.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},_.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return 0<=r.cmp(this.m)&&r.isub(this.m),r._forceRed(this)},_.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return 0<=r.cmp(this.m)&&r.isub(this.m),r},_.prototype.sub=function(e,t){this._verify2(e,t);var r=e.sub(t);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},_.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},_.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},_.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},_.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},_.prototype.isqr=function(e){return this.imul(e,e.clone())},_.prototype.sqr=function(e){return this.mul(e,e)},_.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(m(t%2==1),3===t){var r=this.m.add(new y(1)).iushrn(2);return this.pow(e,r)}for(var n=this.m.subn(1),i=0;!n.isZero()&&0===n.andln(1);)i++,n.iushrn(1);m(!n.isZero());var o=new y(1).toRed(this),s=o.redNeg(),a=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new y(2*u*u).toRed(this);0!==this.pow(u,a).cmp(s);)u.redIAdd(s);for(var f=this.pow(u,n),c=this.pow(e,n.addn(1).iushrn(1)),h=this.pow(e,n),d=i;0!==h.cmp(o);){for(var l=h,p=0;0!==l.cmp(o);p++)l=l.redSqr();m(p<d);var b=this.pow(f,new y(1).iushln(d-p-1));c=c.redMul(b),f=b.redSqr(),h=h.redMul(f),d=p}return c},_.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},_.prototype.pow=function(e,t){if(t.isZero())return new y(1).toRed(this);if(0===t.cmpn(1))return e.clone();var r=new Array(16);r[0]=new y(1).toRed(this),r[1]=e;for(var n=2;n<r.length;n++)r[n]=this.mul(r[n-1],e);var i=r[0],o=0,s=0,a=t.bitLength()%26;for(0===a&&(a=26),n=t.length-1;0<=n;n--){for(var u=t.words[n],f=a-1;0<=f;f--){var c=u>>f&1;i!==r[0]&&(i=this.sqr(i)),0!==c||0!==o?(o<<=1,o|=c,(4===++s||0===n&&0===f)&&(i=this.mul(i,r[o]),o=s=0)):s=0}a=26}return i},_.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},_.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},y.mont=function(e){return new M(e)},r(M,_),M.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},M.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},M.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var r=e.imul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return 0<=i.cmp(this.m)?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},M.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new y(0)._forceRed(this);var r=e.mul(t),n=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),i=r.isub(n).iushrn(this.shift),o=i;return 0<=i.cmp(this.m)?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(void 0===e||e,this)},{buffer:17}],250:[function(e,t,r){arguments[4][16][0].apply(r,arguments)},{crypto:17,dup:16}],251:[function(e,t,r){arguments[4][18][0].apply(r,arguments)},{dup:18,"safe-buffer":359}],252:[function(e,t,r){arguments[4][19][0].apply(r,arguments)},{"./aes":251,"./ghash":256,"./incr32":257,"buffer-xor":278,"cipher-base":279,dup:19,inherits:334,"safe-buffer":359}],253:[function(e,t,r){arguments[4][20][0].apply(r,arguments)},{"./decrypter":254,"./encrypter":255,"./modes/list.json":265,dup:20}],254:[function(e,t,r){var i=e("./authCipher"),o=e("safe-buffer").Buffer,s=e("./modes"),a=e("./streamCipher"),n=e("cipher-base"),u=e("./aes"),f=e("evp_bytestokey");function c(e,t,r){n.call(this),this._cache=new h,this._last=void 0,this._cipher=new u.AES(t),this._prev=o.from(r),this._mode=e,this._autopadding=!0}function h(){this.cache=o.allocUnsafe(0)}function d(e,t,r){var n=s[e.toLowerCase()];if(!n)throw new TypeError("invalid suite type");if("string"==typeof r&&(r=o.from(r)),"GCM"!==n.mode&&r.length!==n.iv)throw new TypeError("invalid iv length "+r.length);if("string"==typeof t&&(t=o.from(t)),t.length!==n.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===n.type?new a(n.module,t,r,!0):"auth"===n.type?new i(n.module,t,r,!0):new c(n.module,t,r)}e("inherits")(c,n),c.prototype._update=function(e){var t,r;this._cache.add(e);for(var n=[];t=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,t),n.push(r);return o.concat(n)},c.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15],r=-1;for(;++r<t;)if(e[r+(16-t)]!==t)throw new Error("unable to decrypt data");if(16===t)return;return e.slice(0,16-t)}(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},c.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=o.concat([this.cache,e])},h.prototype.get=function(e){var t;if(e){if(16<this.cache.length)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(16<=this.cache.length)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},h.prototype.flush=function(){if(this.cache.length)return this.cache},r.createDecipher=function(e,t){var r=s[e.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var n=f(t,!1,r.key,r.iv);return d(e,n.key,n.iv)},r.createDecipheriv=d},{"./aes":251,"./authCipher":252,"./modes":264,"./streamCipher":267,"cipher-base":279,evp_bytestokey:319,inherits:334,"safe-buffer":359}],255:[function(e,t,r){arguments[4][22][0].apply(r,arguments)},{"./aes":251,"./authCipher":252,"./modes":264,"./streamCipher":267,"cipher-base":279,dup:22,evp_bytestokey:319,inherits:334,"safe-buffer":359}],256:[function(e,t,r){arguments[4][23][0].apply(r,arguments)},{dup:23,"safe-buffer":359}],257:[function(e,t,r){arguments[4][24][0].apply(r,arguments)},{dup:24}],258:[function(e,t,r){arguments[4][25][0].apply(r,arguments)},{"buffer-xor":278,dup:25}],259:[function(e,t,r){arguments[4][26][0].apply(r,arguments)},{"buffer-xor":278,dup:26,"safe-buffer":359}],260:[function(e,t,r){arguments[4][27][0].apply(r,arguments)},{dup:27,"safe-buffer":359}],261:[function(e,t,r){arguments[4][28][0].apply(r,arguments)},{dup:28,"safe-buffer":359}],262:[function(e,t,r){arguments[4][29][0].apply(r,arguments)},{"../incr32":257,"buffer-xor":278,dup:29,"safe-buffer":359}],263:[function(e,t,r){arguments[4][30][0].apply(r,arguments)},{dup:30}],264:[function(e,t,r){arguments[4][31][0].apply(r,arguments)},{"./cbc":258,"./cfb":259,"./cfb1":260,"./cfb8":261,"./ctr":262,"./ecb":263,"./list.json":265,"./ofb":266,dup:31}],265:[function(e,t,r){arguments[4][32][0].apply(r,arguments)},{dup:32}],266:[function(e,t,r){(function(i){var o=e("buffer-xor");r.encrypt=function(e,t){for(;e._cache.length<t.length;)e._cache=i.concat([e._cache,(r=e,r._prev=r._cipher.encryptBlock(r._prev),r._prev)]);var r,n=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),o(t,n)}}).call(this,e("buffer").Buffer)},{buffer:48,"buffer-xor":278}],267:[function(e,t,r){arguments[4][34][0].apply(r,arguments)},{"./aes":251,"cipher-base":279,dup:34,inherits:334,"safe-buffer":359}],268:[function(e,t,r){var o=e("evp_bytestokey"),n=e("browserify-aes/browser"),i=e("browserify-des"),s=e("browserify-des/modes"),a=e("browserify-aes/modes");function u(e,t,r){if(e=e.toLowerCase(),a[e])return n.createCipheriv(e,t,r);if(s[e])return new i({key:t,iv:r,mode:e});throw new TypeError("invalid suite type")}function f(e,t,r){if(e=e.toLowerCase(),a[e])return n.createDecipheriv(e,t,r);if(s[e])return new i({key:t,iv:r,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}r.createCipher=r.Cipher=function(e,t){var r,n;if(e=e.toLowerCase(),a[e])r=a[e].key,n=a[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,n=s[e].iv}var i=o(t,!1,r,n);return u(e,i.key,i.iv)},r.createCipheriv=r.Cipheriv=u,r.createDecipher=r.Decipher=function(e,t){var r,n;if(e=e.toLowerCase(),a[e])r=a[e].key,n=a[e].iv;else{if(!s[e])throw new TypeError("invalid suite type");r=8*s[e].key,n=s[e].iv}var i=o(t,!1,r,n);return f(e,i.key,i.iv)},r.createDecipheriv=r.Decipheriv=f,r.listCiphers=r.getCiphers=function(){return Object.keys(s).concat(n.getCiphers())}},{"browserify-aes/browser":253,"browserify-aes/modes":264,"browserify-des":269,"browserify-des/modes":270,evp_bytestokey:319}],269:[function(n,i,e){(function(s){var a=n("cipher-base"),e=n("des.js"),t=n("inherits"),u={"des-ede3-cbc":e.CBC.instantiate(e.EDE),"des-ede3":e.EDE,"des-ede-cbc":e.CBC.instantiate(e.EDE),"des-ede":e.EDE,"des-cbc":e.CBC.instantiate(e.DES),"des-ecb":e.DES};function r(e){a.call(this);var t,r=e.mode.toLowerCase(),n=u[r];t=e.decrypt?"decrypt":"encrypt";var i=e.key;"des-ede"!==r&&"des-ede-cbc"!==r||(i=s.concat([i,i.slice(0,8)]));var o=e.iv;this._des=n.create({key:i,iv:o,type:t})}u.des=u["des-cbc"],u.des3=u["des-ede3-cbc"],t(i.exports=r,a),r.prototype._update=function(e){return new s(this._des.update(e))},r.prototype._final=function(){return new s(this._des.final())}}).call(this,n("buffer").Buffer)},{buffer:48,"cipher-base":279,"des.js":287,inherits:334}],270:[function(e,t,r){arguments[4][37][0].apply(r,arguments)},{dup:37}],271:[function(t,r,e){(function(b){var m=t("bn.js"),n=t("randombytes");function e(e,t){var r,n,i={blinder:(n=y(r=t)).toRed(m.mont(r.modulus)).redPow(new m(r.publicExponent)).fromRed(),unblinder:n.invm(r.modulus)},o=t.modulus.byteLength(),s=(m.mont(t.modulus),new m(e).mul(i.blinder).umod(t.modulus)),a=s.toRed(m.mont(t.prime1)),u=s.toRed(m.mont(t.prime2)),f=t.coefficient,c=t.prime1,h=t.prime2,d=a.redPow(t.exponent1),l=u.redPow(t.exponent2);d=d.fromRed(),l=l.fromRed();var p=d.isub(l).imul(f).umod(c);return p.imul(h),l.iadd(p),new b(l.imul(i.unblinder).umod(t.modulus).toArray(!1,o))}function y(e){for(var t=e.modulus.byteLength(),r=new m(n(t));0<=r.cmp(e.modulus)||!r.umod(e.prime1)||!r.umod(e.prime2);)r=new m(n(t));return r}(r.exports=e).getr=y}).call(this,t("buffer").Buffer)},{"bn.js":249,buffer:48,randombytes:356}],272:[function(e,t,r){arguments[4][39][0].apply(r,arguments)},{"./browser/algorithms.json":273,dup:39}],273:[function(e,t,r){arguments[4][40][0].apply(r,arguments)},{dup:40}],274:[function(e,t,r){arguments[4][41][0].apply(r,arguments)},{dup:41}],275:[function(h,d,e){(function(i){var r=h("create-hash"),n=h("stream"),e=h("inherits"),o=h("./sign"),s=h("./verify"),a=h("./algorithms.json");function t(e){n.Writable.call(this);var t=a[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=r(t.hash),this._tag=t.id,this._signType=t.sign}function u(e){n.Writable.call(this);var t=a[e];if(!t)throw new Error("Unknown message digest");this._hash=r(t.hash),this._tag=t.id,this._signType=t.sign}function f(e){return new t(e)}function c(e){return new u(e)}Object.keys(a).forEach(function(e){a[e].id=new i(a[e].id,"hex"),a[e.toLowerCase()]=a[e]}),e(t,n.Writable),t.prototype._write=function(e,t,r){this._hash.update(e),r()},t.prototype.update=function(e,t){return"string"==typeof e&&(e=new i(e,t)),this._hash.update(e),this},t.prototype.sign=function(e,t){this.end();var r=this._hash.digest(),n=o(r,e,this._hashType,this._signType,this._tag);return t?n.toString(t):n},e(u,n.Writable),u.prototype._write=function(e,t,r){this._hash.update(e),r()},u.prototype.update=function(e,t){return"string"==typeof e&&(e=new i(e,t)),this._hash.update(e),this},u.prototype.verify=function(e,t,r){"string"==typeof t&&(t=new i(t,r)),this.end();var n=this._hash.digest();return s(t,n,e,this._signType,this._tag)},d.exports={Sign:f,Verify:c,createSign:f,createVerify:c}}).call(this,h("buffer").Buffer)},{"./algorithms.json":273,"./sign":276,"./verify":277,buffer:48,"create-hash":281,inherits:334,stream:158}],276:[function(e,t,r){(function(b){var f=e("create-hmac"),c=e("browserify-rsa"),h=e("elliptic").ec,m=e("bn.js"),d=e("parse-asn1"),l=e("./curves.json");function y(e,t,r,n){if((e=new b(e.toArray())).length<t.byteLength()){var i=new b(t.byteLength()-e.length);i.fill(0),e=b.concat([i,e])}var o=r.length,s=function(e,t){e=(e=v(e,t)).mod(t);var r=new b(e.toArray());if(r.length<t.byteLength()){var n=new b(t.byteLength()-r.length);n.fill(0),r=b.concat([n,r])}return r}(r,t),a=new b(o);a.fill(1);var u=new b(o);return u.fill(0),u=f(n,u).update(a).update(new b([0])).update(e).update(s).digest(),a=f(n,u).update(a).digest(),{k:u=f(n,u).update(a).update(new b([1])).update(e).update(s).digest(),v:a=f(n,u).update(a).digest()}}function v(e,t){var r=new m(e),n=(e.length<<3)-t.bitLength();return 0<n&&r.ishrn(n),r}function g(e,t,r){var n,i;do{for(n=new b(0);8*n.length<e.bitLength();)t.v=f(r,t.k).update(t.v).digest(),n=b.concat([n,t.v]);i=v(n,e),t.k=f(r,t.k).update(t.v).update(new b([0])).digest(),t.v=f(r,t.k).update(t.v).digest()}while(-1!==i.cmp(e));return i}t.exports=function(e,t,r,n,i){var o=d(t);if(o.curve){if("ecdsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");return function(e,t){var r=l[t.curve.join(".")];if(!r)throw new Error("unknown curve "+t.curve.join("."));var n=new h(r).keyFromPrivate(t.privateKey).sign(e);return new b(n.toDER())}(e,o)}if("dsa"===o.type){if("dsa"!==n)throw new Error("wrong private key type");return function(e,t,r){for(var n,i,o,s,a=t.params.priv_key,u=t.params.p,f=t.params.q,c=t.params.g,h=new m(0),d=v(e,f).mod(f),l=!1,p=y(a,f,e,r);!1===l;)n=g(f,p,r),i=n,o=u,s=f,h=c.toRed(m.mont(o)).redPow(i).fromRed().mod(s),0===(l=n.invm(f).imul(d.add(a.mul(h))).mod(f)).cmpn(0)&&(l=!1,h=new m(0));return function(e,t){e=e.toArray(),t=t.toArray(),128&e[0]&&(e=[0].concat(e)),128&t[0]&&(t=[0].concat(t));var r=[48,e.length+t.length+4,2,e.length];return r=r.concat(e,[2,t.length],t),new b(r)}(h,l)}(e,o,r)}if("rsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");e=b.concat([i,e]);for(var s=o.modulus.byteLength(),a=[0,1];e.length+a.length+1<s;)a.push(255);a.push(0);for(var u=-1;++u<e.length;)a.push(e[u]);return c(a,o)},t.exports.getKey=y,t.exports.makeKey=g}).call(this,e("buffer").Buffer)},{"./curves.json":274,"bn.js":249,"browserify-rsa":271,buffer:48,"create-hmac":284,elliptic:297,"parse-asn1":344}],277:[function(e,t,r){(function(d){var l=e("bn.js"),p=e("elliptic").ec,b=e("parse-asn1"),m=e("./curves.json");function y(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=t)throw new Error("invalid sig")}t.exports=function(e,t,r,n,i){var o=b(r);if("ec"===o.type){if("ecdsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong public key type");return function(e,t,r){var n=m[r.data.algorithm.curve.join(".")];if(!n)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var i=new p(n),o=r.data.subjectPrivateKey.data;return i.verify(t,e,o)}(e,t,o)}if("dsa"===o.type){if("dsa"!==n)throw new Error("wrong public key type");return function(e,t,r){var n=r.data.p,i=r.data.q,o=r.data.g,s=r.data.pub_key,a=b.signature.decode(e,"der"),u=a.s,f=a.r;y(u,i),y(f,i);var c=l.mont(n),h=u.invm(i);return 0===o.toRed(c).redPow(new l(t).mul(h).mod(i)).fromRed().mul(s.toRed(c).redPow(f.mul(h).mod(i)).fromRed()).mod(n).mod(i).cmp(f)}(e,t,o)}if("rsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong public key type");t=d.concat([i,t]);for(var s=o.modulus.byteLength(),a=[1],u=0;t.length+a.length+2<s;)a.push(255),u++;a.push(0);for(var f=-1;++f<t.length;)a.push(t[f]);a=new d(a);var c=l.mont(o.modulus);e=(e=new l(e).toRed(c)).redPow(new l(o.publicExponent)),e=new d(e.fromRed().toArray());var h=u<8?1:0;for(s=Math.min(e.length,a.length),e.length!==a.length&&(h=1),f=-1;++f<s;)h|=e[f]^a[f];return 0===h}}).call(this,e("buffer").Buffer)},{"./curves.json":274,"bn.js":249,buffer:48,elliptic:297,"parse-asn1":344}],278:[function(e,t,r){(function(o){t.exports=function(e,t){for(var r=Math.min(e.length,t.length),n=new o(r),i=0;i<r;++i)n[i]=e[i]^t[i];return n}}).call(this,e("buffer").Buffer)},{buffer:48}],279:[function(e,t,r){arguments[4][50][0].apply(r,arguments)},{dup:50,inherits:334,"safe-buffer":359,stream:158,string_decoder:46}],280:[function(e,a,t){(function(o){var t=e("elliptic"),n=e("bn.js");a.exports=function(e){return new i(e)};var r={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function i(e){this.curveType=r[e],this.curveType||(this.curveType={name:e}),this.curve=new t.ec(this.curveType.name),this.keys=void 0}function s(e,t,r){Array.isArray(e)||(e=e.toArray());var n=new o(e);if(r&&n.length<r){var i=new o(r-n.length);i.fill(0),n=o.concat([i,n])}return t?n.toString(t):n}r.p224=r.secp224r1,r.p256=r.secp256r1=r.prime256v1,r.p192=r.secp192r1=r.prime192v1,r.p384=r.secp384r1,r.p521=r.secp521r1,i.prototype.generateKeys=function(e,t){return this.keys=this.curve.genKeyPair(),this.getPublicKey(e,t)},i.prototype.computeSecret=function(e,t,r){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),s(this.curve.keyFromPublic(e).getPublic().mul(this.keys.getPrivate()).getX(),r,this.curveType.byteLength)},i.prototype.getPublicKey=function(e,t){var r=this.keys.getPublic("compressed"===t,!0);return"hybrid"===t&&(r[r.length-1]%2?r[0]=7:r[0]=6),s(r,e)},i.prototype.getPrivateKey=function(e){return s(this.keys.getPrivate(),e)},i.prototype.setPublicKey=function(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this.keys._importPublic(e),this},i.prototype.setPrivateKey=function(e,t){t=t||"utf8",o.isBuffer(e)||(e=new o(e,t));var r=new n(e);return r=r.toString(16),this.keys._importPrivate(r),this}}).call(this,e("buffer").Buffer)},{"bn.js":249,buffer:48,elliptic:297}],281:[function(u,f,e){(function(r){var e=u("inherits"),t=u("./md5"),n=u("ripemd160"),i=u("sha.js"),o=u("cipher-base");function s(e){o.call(this,"digest"),this._hash=e,this.buffers=[]}function a(e){o.call(this,"digest"),this._hash=e}e(s,o),s.prototype._update=function(e){this.buffers.push(e)},s.prototype._final=function(){var e=r.concat(this.buffers),t=this._hash(e);return this.buffers=null,t},e(a,o),a.prototype._update=function(e){this._hash.update(e)},a.prototype._final=function(){return this._hash.digest()},f.exports=function(e){return"md5"===(e=e.toLowerCase())?new s(t):new a("rmd160"===e||"ripemd160"===e?new n:i(e))}}).call(this,u("buffer").Buffer)},{"./md5":283,buffer:48,"cipher-base":279,inherits:334,ripemd160:358,"sha.js":363}],282:[function(e,t,r){(function(o){var s=new o(4);s.fill(0);t.exports=function(e,t){var r=t(function(e){if(e.length%4!=0){var t=e.length+(4-e.length%4);e=o.concat([e,s],t)}for(var r=new Array(e.length>>>2),n=0,i=0;n<e.length;n+=4,i++)r[i]=e.readInt32LE(n);return r}(e),8*e.length);e=new o(16);for(var n=0;n<r.length;n++)e.writeInt32LE(r[n],n<<2,!0);return e}}).call(this,e("buffer").Buffer)},{buffer:48}],283:[function(e,t,r){var n=e("./make-hash");function i(e,t){e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;for(var r=1732584193,n=-271733879,i=-1732584194,o=271733878,s=0;s<e.length;s+=16){var a=r,u=n,f=i,c=o;n=p(n=p(n=p(n=p(n=l(n=l(n=l(n=l(n=d(n=d(n=d(n=d(n=h(n=h(n=h(n=h(n,i=h(i,o=h(o,r=h(r,n,i,o,e[s+0],7,-680876936),n,i,e[s+1],12,-389564586),r,n,e[s+2],17,606105819),o,r,e[s+3],22,-1044525330),i=h(i,o=h(o,r=h(r,n,i,o,e[s+4],7,-176418897),n,i,e[s+5],12,1200080426),r,n,e[s+6],17,-1473231341),o,r,e[s+7],22,-45705983),i=h(i,o=h(o,r=h(r,n,i,o,e[s+8],7,1770035416),n,i,e[s+9],12,-1958414417),r,n,e[s+10],17,-42063),o,r,e[s+11],22,-1990404162),i=h(i,o=h(o,r=h(r,n,i,o,e[s+12],7,1804603682),n,i,e[s+13],12,-40341101),r,n,e[s+14],17,-1502002290),o,r,e[s+15],22,1236535329),i=d(i,o=d(o,r=d(r,n,i,o,e[s+1],5,-165796510),n,i,e[s+6],9,-1069501632),r,n,e[s+11],14,643717713),o,r,e[s+0],20,-373897302),i=d(i,o=d(o,r=d(r,n,i,o,e[s+5],5,-701558691),n,i,e[s+10],9,38016083),r,n,e[s+15],14,-660478335),o,r,e[s+4],20,-405537848),i=d(i,o=d(o,r=d(r,n,i,o,e[s+9],5,568446438),n,i,e[s+14],9,-1019803690),r,n,e[s+3],14,-187363961),o,r,e[s+8],20,1163531501),i=d(i,o=d(o,r=d(r,n,i,o,e[s+13],5,-1444681467),n,i,e[s+2],9,-51403784),r,n,e[s+7],14,1735328473),o,r,e[s+12],20,-1926607734),i=l(i,o=l(o,r=l(r,n,i,o,e[s+5],4,-378558),n,i,e[s+8],11,-2022574463),r,n,e[s+11],16,1839030562),o,r,e[s+14],23,-35309556),i=l(i,o=l(o,r=l(r,n,i,o,e[s+1],4,-1530992060),n,i,e[s+4],11,1272893353),r,n,e[s+7],16,-155497632),o,r,e[s+10],23,-1094730640),i=l(i,o=l(o,r=l(r,n,i,o,e[s+13],4,681279174),n,i,e[s+0],11,-358537222),r,n,e[s+3],16,-722521979),o,r,e[s+6],23,76029189),i=l(i,o=l(o,r=l(r,n,i,o,e[s+9],4,-640364487),n,i,e[s+12],11,-421815835),r,n,e[s+15],16,530742520),o,r,e[s+2],23,-995338651),i=p(i,o=p(o,r=p(r,n,i,o,e[s+0],6,-198630844),n,i,e[s+7],10,1126891415),r,n,e[s+14],15,-1416354905),o,r,e[s+5],21,-57434055),i=p(i,o=p(o,r=p(r,n,i,o,e[s+12],6,1700485571),n,i,e[s+3],10,-1894986606),r,n,e[s+10],15,-1051523),o,r,e[s+1],21,-2054922799),i=p(i,o=p(o,r=p(r,n,i,o,e[s+8],6,1873313359),n,i,e[s+15],10,-30611744),r,n,e[s+6],15,-1560198380),o,r,e[s+13],21,1309151649),i=p(i,o=p(o,r=p(r,n,i,o,e[s+4],6,-145523070),n,i,e[s+11],10,-1120210379),r,n,e[s+2],15,718787259),o,r,e[s+9],21,-343485551),r=b(r,a),n=b(n,u),i=b(i,f),o=b(o,c)}return[r,n,i,o]}function a(e,t,r,n,i,o){return b((s=b(b(t,e),b(n,o)))<<(a=i)|s>>>32-a,r);var s,a}function h(e,t,r,n,i,o,s){return a(t&r|~t&n,e,t,i,o,s)}function d(e,t,r,n,i,o,s){return a(t&n|r&~n,e,t,i,o,s)}function l(e,t,r,n,i,o,s){return a(t^r^n,e,t,i,o,s)}function p(e,t,r,n,i,o,s){return a(r^(t|~n),e,t,i,o,s)}function b(e,t){var r=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(r>>16)<<16|65535&r}t.exports=function(e){return n(e,i)}},{"./make-hash":282}],284:[function(e,t,r){arguments[4][55][0].apply(r,arguments)},{"./legacy":285,"cipher-base":279,"create-hash/md5":283,dup:55,inherits:334,ripemd160:358,"safe-buffer":359,"sha.js":363}],285:[function(e,t,r){arguments[4][56][0].apply(r,arguments)},{"cipher-base":279,dup:56,inherits:334,"safe-buffer":359}],286:[function(e,t,r){arguments[4][57][0].apply(r,arguments)},{"browserify-cipher":268,"browserify-sign":275,"browserify-sign/algos":272,"create-ecdh":280,"create-hash":281,"create-hmac":284,"diffie-hellman":293,dup:57,pbkdf2:345,"public-encrypt":350,randombytes:356,randomfill:357}],287:[function(e,t,r){arguments[4][58][0].apply(r,arguments)},{"./des/cbc":288,"./des/cipher":289,"./des/des":290,"./des/ede":291,"./des/utils":292,dup:58}],288:[function(e,t,r){arguments[4][59][0].apply(r,arguments)},{dup:59,inherits:334,"minimalistic-assert":338}],289:[function(e,t,r){arguments[4][60][0].apply(r,arguments)},{dup:60,"minimalistic-assert":338}],290:[function(e,t,r){arguments[4][61][0].apply(r,arguments)},{"../des":287,dup:61,inherits:334,"minimalistic-assert":338}],291:[function(e,t,r){arguments[4][62][0].apply(r,arguments)},{"../des":287,dup:62,inherits:334,"minimalistic-assert":338}],292:[function(e,t,r){arguments[4][63][0].apply(r,arguments)},{dup:63}],293:[function(e,t,r){(function(o){var s=e("./lib/generatePrime"),n=e("./lib/primes.json"),a=e("./lib/dh");var u={binary:!0,hex:!0,base64:!0};r.DiffieHellmanGroup=r.createDiffieHellmanGroup=r.getDiffieHellman=function(e){var t=new o(n[e].prime,"hex"),r=new o(n[e].gen,"hex");return new a(t,r)},r.createDiffieHellman=r.DiffieHellman=function e(t,r,n,i){return o.isBuffer(r)||void 0===u[r]?e(t,"binary",r,n):(r=r||"binary",i=i||"binary",n=n||new o([2]),o.isBuffer(n)||(n=new o(n,i)),"number"==typeof t?new a(s(t,n),n,!0):(o.isBuffer(t)||(t=new o(t,r)),new a(t,n,!0)))}}).call(this,e("buffer").Buffer)},{"./lib/dh":294,"./lib/generatePrime":295,"./lib/primes.json":296,buffer:48}],294:[function(b,m,e){(function(o){var s=b("bn.js"),a=new(b("miller-rabin")),u=new s(24),f=new s(11),c=new s(10),h=new s(3),d=new s(7),l=b("./generatePrime"),e=b("randombytes");function n(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this._pub=new s(e),this}function i(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this._priv=new s(e),this}m.exports=t;var p={};function t(e,t,r){this.setGenerator(t),this.__prime=new s(e),this._prime=s.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=n,this.setPrivateKey=i):this._primeCode=8}function r(e,t){var r=new o(e.toArray());return t?r.toString(t):r}Object.defineProperty(t.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var r=t.toString("hex"),n=[r,e.toString(16)].join("_");if(n in p)return p[n];var i,o=0;if(e.isEven()||!l.simpleSieve||!l.fermatTest(e)||!a.test(e))return o+=1,o+="02"===r||"05"===r?8:4,p[n]=o;switch(a.test(e.shrn(1))||(o+=2),r){case"02":e.mod(u).cmp(f)&&(o+=8);break;case"05":(i=e.mod(c)).cmp(h)&&i.cmp(d)&&(o+=8);break;default:o+=4}return p[n]=o}(this.__prime,this.__gen)),this._primeCode}}),t.prototype.generateKeys=function(){return this._priv||(this._priv=new s(e(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},t.prototype.computeSecret=function(e){var t=(e=(e=new s(e)).toRed(this._prime)).redPow(this._priv).fromRed(),r=new o(t.toArray()),n=this.getPrime();if(r.length<n.length){var i=new o(n.length-r.length);i.fill(0),r=o.concat([i,r])}return r},t.prototype.getPublicKey=function(e){return r(this._pub,e)},t.prototype.getPrivateKey=function(e){return r(this._priv,e)},t.prototype.getPrime=function(e){return r(this.__prime,e)},t.prototype.getGenerator=function(e){return r(this._gen,e)},t.prototype.setGenerator=function(e,t){return t=t||"utf8",o.isBuffer(e)||(e=new o(e,t)),this.__gen=e,this._gen=new s(e),this}}).call(this,b("buffer").Buffer)},{"./generatePrime":295,"bn.js":249,buffer:48,"miller-rabin":337,randombytes:356}],295:[function(e,t,r){arguments[4][66][0].apply(r,arguments)},{"bn.js":249,dup:66,"miller-rabin":337,randombytes:356}],296:[function(e,t,r){arguments[4][67][0].apply(r,arguments)},{dup:67}],297:[function(e,t,r){arguments[4][68][0].apply(r,arguments)},{"../package.json":312,"./elliptic/curve":300,"./elliptic/curves":303,"./elliptic/ec":304,"./elliptic/eddsa":307,"./elliptic/utils":311,brorand:250,dup:68}],298:[function(e,t,r){arguments[4][69][0].apply(r,arguments)},{"../../elliptic":297,"bn.js":249,dup:69}],299:[function(e,t,r){arguments[4][70][0].apply(r,arguments)},{"../../elliptic":297,"../curve":300,"bn.js":249,dup:70,inherits:334}],300:[function(e,t,r){arguments[4][71][0].apply(r,arguments)},{"./base":298,"./edwards":299,"./mont":301,"./short":302,dup:71}],301:[function(e,t,r){arguments[4][72][0].apply(r,arguments)},{"../../elliptic":297,"../curve":300,"bn.js":249,dup:72,inherits:334}],302:[function(e,t,r){arguments[4][73][0].apply(r,arguments)},{"../../elliptic":297,"../curve":300,"bn.js":249,dup:73,inherits:334}],303:[function(e,t,r){arguments[4][74][0].apply(r,arguments)},{"../elliptic":297,"./precomputed/secp256k1":310,dup:74,"hash.js":321}],304:[function(e,t,r){arguments[4][75][0].apply(r,arguments)},{"../../elliptic":297,"./key":305,"./signature":306,"bn.js":249,dup:75,"hmac-drbg":333}],305:[function(e,t,r){arguments[4][76][0].apply(r,arguments)},{"../../elliptic":297,"bn.js":249,dup:76}],306:[function(e,t,r){arguments[4][77][0].apply(r,arguments)},{"../../elliptic":297,"bn.js":249,dup:77}],307:[function(e,t,r){arguments[4][78][0].apply(r,arguments)},{"../../elliptic":297,"./key":308,"./signature":309,dup:78,"hash.js":321}],308:[function(e,t,r){arguments[4][79][0].apply(r,arguments)},{"../../elliptic":297,dup:79}],309:[function(e,t,r){arguments[4][80][0].apply(r,arguments)},{"../../elliptic":297,"bn.js":249,dup:80}],310:[function(e,t,r){arguments[4][81][0].apply(r,arguments)},{dup:81}],311:[function(e,t,r){arguments[4][82][0].apply(r,arguments)},{"bn.js":249,dup:82,"minimalistic-assert":338,"minimalistic-crypto-utils":339}],312:[function(e,t,r){t.exports={_args:[["elliptic@6.4.0","/Users/frozeman/Sites/_ethereum/web3/packages/web3-eth-accounts"]],_from:"elliptic@6.4.0",_id:"elliptic@6.4.0",_inBundle:!1,_integrity:"sha1-ysmvh2LIWDYYcAPI3+GT5eLq5d8=",_location:"/elliptic",_phantomChildren:{},_requested:{type:"version",registry:!0,raw:"elliptic@6.4.0",name:"elliptic",escapedName:"elliptic",rawSpec:"6.4.0",saveSpec:null,fetchSpec:"6.4.0"},_requiredBy:["/browserify-sign","/create-ecdh","/eth-lib"],_resolved:"https://registry.npmjs.org/elliptic/-/elliptic-6.4.0.tgz",_spec:"6.4.0",_where:"/Users/frozeman/Sites/_ethereum/web3/packages/web3-eth-accounts",author:{name:"Fedor Indutny",email:"fedor@indutny.com"},bugs:{url:"https://github.com/indutny/elliptic/issues"},dependencies:{"bn.js":"^4.4.0",brorand:"^1.0.1","hash.js":"^1.0.0","hmac-drbg":"^1.0.0",inherits:"^2.0.1","minimalistic-assert":"^1.0.0","minimalistic-crypto-utils":"^1.0.0"},description:"EC cryptography",devDependencies:{brfs:"^1.4.3",coveralls:"^2.11.3",grunt:"^0.4.5","grunt-browserify":"^5.0.0","grunt-cli":"^1.2.0","grunt-contrib-connect":"^1.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^1.0.1","grunt-mocha-istanbul":"^3.0.1","grunt-saucelabs":"^8.6.2",istanbul:"^0.4.2",jscs:"^2.9.0",jshint:"^2.6.0",mocha:"^2.1.0"},files:["lib"],homepage:"https://github.com/indutny/elliptic",keywords:["EC","Elliptic","curve","Cryptography"],license:"MIT",main:"lib/elliptic.js",name:"elliptic",repository:{type:"git",url:"git+ssh://git@github.com/indutny/elliptic.git"},scripts:{jscs:"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js",jshint:"jscs benchmarks/*.js lib/*.js lib/**/*.js lib/**/**/*.js test/index.js",lint:"npm run jscs && npm run jshint",test:"npm run lint && npm run unit",unit:"istanbul test _mocha --reporter=spec test/index.js",version:"grunt dist && git add dist/"},version:"6.4.0"}},{}],313:[function(b,m,e){(function(s){var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],n=!0,i=!1,o=void 0;try{for(var s,a=e[Symbol.iterator]();!(n=(s=a.next()).done)&&(r.push(s.value),!t||r.length!==t);n=!0);}catch(e){i=!0,o=e}finally{try{!n&&a.return&&a.return()}finally{if(i)throw o}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},a=b("./bytes"),i=b("./nat"),e=b("elliptic"),u=(b("./rlp"),new e.ec("secp256k1")),t=b("./hash"),f=t.keccak256,c=t.keccak256s,h=function(e){for(var t=c(e.slice(2)),r="0x",n=0;n<40;n++)r+=7<parseInt(t[n+2],16)?e[n+2].toUpperCase():e[n+2];return r},d=function(e){var t=new s(e.slice(2),"hex"),r="0x"+u.keyFromPrivate(t).getPublic(!1,"hex").slice(2),n=f(r);return{address:h("0x"+n.slice(-40)),privateKey:e}},l=function(e){var t=o(e,3),r=t[0],n=a.pad(32,t[1]),i=a.pad(32,t[2]);return a.flatten([n,i,r])},p=function(e){return[a.slice(64,a.length(e),e),a.slice(0,32,e),a.slice(32,64,e)]},r=function(n){return function(e,t){var r=u.keyFromPrivate(new s(t.slice(2),"hex")).sign(new s(e.slice(2),"hex"),{canonical:!0});return l([i.fromString(a.fromNumber(n+r.recoveryParam)),a.pad(32,a.fromNat("0x"+r.r.toString(16))),a.pad(32,a.fromNat("0x"+r.s.toString(16)))])}},n=r(27);m.exports={create:function(e){var t=f(a.concat(a.random(32),e||a.random(32))),r=a.concat(a.concat(a.random(32),t),a.random(32)),n=f(r);return d(n)},toChecksum:h,fromPrivate:d,sign:n,makeSigner:r,recover:function(e,t){var r=p(t),n={v:a.toNumber(r[0]),r:r[1].slice(2),s:r[2].slice(2)},i="0x"+u.recoverPubKey(new s(e.slice(2),"hex"),n,n.v<2?n.v:1-n.v%2).encode("hex",!1).slice(2),o=f(i);return h("0x"+o.slice(-40))},encodeSignature:l,decodeSignature:p}}).call(this,b("buffer").Buffer)},{"./bytes":315,"./hash":316,"./nat":317,"./rlp":318,buffer:48,elliptic:297}],314:[function(e,t,r){arguments[4][172][0].apply(r,arguments)},{dup:172}],315:[function(e,t,r){arguments[4][173][0].apply(r,arguments)},{"./array.js":314,dup:173}],316:[function(e,t,r){arguments[4][174][0].apply(r,arguments)},{dup:174}],317:[function(e,t,r){var n=e("bn.js"),i=e("./bytes"),o=function(e){return new n(e.slice(2),16)},s=function(e){var t="0x"+("0x"===e.slice(0,2)?new n(e.slice(2),16):new n(e,10)).toString("hex");return"0x0"===t?"0x":t},a=function(e){return"string"==typeof e?/^0x/.test(e)?e:"0x"+e:"0x"+new n(e).toString("hex")},u=function(e){return o(e).toNumber()},f=function(r){return function(e,t){return"0x"+o(e)[r](o(t)).toString("hex")}},c=f("add"),h=f("mul"),d=f("div"),l=f("sub");t.exports={toString:function(e){return o(e).toString(10)},fromString:s,toNumber:u,fromNumber:a,toEther:function(e){return u(d(e,s("10000000000")))/1e8},fromEther:function(e){return h(a(Math.floor(1e8*e)),s("10000000000"))},toUint256:function(e){return i.pad(32,e)},add:c,mul:h,div:d,sub:l}},{"./bytes":315,"bn.js":249}],318:[function(e,t,r){t.exports={encode:function(e){var r=function(e){return(t=e.toString(16)).length%2==0?t:"0"+t;var t},i=function(e,t){return e<56?r(t+e):r(t+r(e).length/2+55)+r(e)};return"0x"+function e(t){if("string"==typeof t){var r=t.slice(2);return(2!=r.length||"80"<=r?i(r.length/2,128):"")+r}var n=t.map(e).join("");return i(n.length/2,192)+n}(e)},decode:function(t){var r=2,n=function(){if(r>=t.length)throw"";var e=t.slice(r,r+2);return e<"80"?(r+=2,"0x"+e):e<"c0"?o():s()},i=function(){var e=parseInt(t.slice(r,r+=2),16)%64;return e<56?e:parseInt(t.slice(r,r+=2*(e-55)),16)},o=function(){var e=i();return"0x"+t.slice(r,r+=2*e)},s=function(){for(var e=2*i()+r,t=[];r<e;)t.push(n());return t};try{return n()}catch(e){return[]}}}},{}],319:[function(e,t,r){arguments[4][85][0].apply(r,arguments)},{dup:85,"md5.js":335,"safe-buffer":359}],320:[function(r,n,e){(function(a){var t=r("stream").Transform;function e(e){t.call(this),this._block=new a(e),this._blockSize=e,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r("inherits")(e,t),e.prototype._transform=function(e,t,r){var n=null;try{"buffer"!==t&&(e=new a(e,t)),this.update(e)}catch(e){n=e}r(n)},e.prototype._flush=function(e){var t=null;try{this.push(this._digest())}catch(e){t=e}e(t)},e.prototype.update=function(e,t){if(!a.isBuffer(e)&&"string"!=typeof e)throw new TypeError("Data must be a string or a buffer");if(this._finalized)throw new Error("Digest already called");a.isBuffer(e)||(e=new a(e,t||"binary"));for(var r=this._block,n=0;this._blockOffset+e.length-n>=this._blockSize;){for(var i=this._blockOffset;i<this._blockSize;)r[i++]=e[n++];this._update(),this._blockOffset=0}for(;n<e.length;)r[this._blockOffset++]=e[n++];for(var o=0,s=8*e.length;0<s;++o)this._length[o]+=s,0<(s=this._length[o]/4294967296|0)&&(this._length[o]-=4294967296*s);return this},e.prototype._update=function(e){throw new Error("_update is not implemented")},e.prototype.digest=function(e){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var t=this._digest();return void 0!==e&&(t=t.toString(e)),t},e.prototype._digest=function(){throw new Error("_digest is not implemented")},n.exports=e}).call(this,r("buffer").Buffer)},{buffer:48,inherits:334,stream:158}],321:[function(e,t,r){arguments[4][87][0].apply(r,arguments)},{"./hash/common":322,"./hash/hmac":323,"./hash/ripemd":324,"./hash/sha":325,"./hash/utils":332,dup:87}],322:[function(e,t,r){arguments[4][88][0].apply(r,arguments)},{"./utils":332,dup:88,"minimalistic-assert":338}],323:[function(e,t,r){arguments[4][89][0].apply(r,arguments)},{"./utils":332,dup:89,"minimalistic-assert":338}],324:[function(e,t,r){arguments[4][90][0].apply(r,arguments)},{"./common":322,"./utils":332,dup:90}],325:[function(e,t,r){arguments[4][91][0].apply(r,arguments)},{"./sha/1":326,"./sha/224":327,"./sha/256":328,"./sha/384":329,"./sha/512":330,dup:91}],326:[function(e,t,r){arguments[4][92][0].apply(r,arguments)},{"../common":322,"../utils":332,"./common":331,dup:92}],327:[function(e,t,r){arguments[4][93][0].apply(r,arguments)},{"../utils":332,"./256":328,dup:93}],328:[function(e,t,r){arguments[4][94][0].apply(r,arguments)},{"../common":322,"../utils":332,"./common":331,dup:94,"minimalistic-assert":338}],329:[function(e,t,r){arguments[4][95][0].apply(r,arguments)},{"../utils":332,"./512":330,dup:95}],330:[function(e,t,r){arguments[4][96][0].apply(r,arguments)},{"../common":322,"../utils":332,dup:96,"minimalistic-assert":338}],331:[function(e,t,r){arguments[4][97][0].apply(r,arguments)},{"../utils":332,dup:97}],332:[function(e,t,r){arguments[4][98][0].apply(r,arguments)},{dup:98,inherits:334,"minimalistic-assert":338}],333:[function(e,t,r){arguments[4][99][0].apply(r,arguments)},{dup:99,"hash.js":321,"minimalistic-assert":338,"minimalistic-crypto-utils":339}],334:[function(e,t,r){arguments[4][103][0].apply(r,arguments)},{dup:103}],335:[function(i,o,e){(function(t){var e=i("inherits"),r=i("hash-base"),s=new Array(16);function n(){r.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function a(e,t){return e<<t|e>>>32-t}function u(e,t,r,n,i,o,s){return a(e+(t&r|~t&n)+i+o|0,s)+t|0}function f(e,t,r,n,i,o,s){return a(e+(t&n|r&~n)+i+o|0,s)+t|0}function c(e,t,r,n,i,o,s){return a(e+(t^r^n)+i+o|0,s)+t|0}function h(e,t,r,n,i,o,s){return a(e+(r^(t|~n))+i+o|0,s)+t|0}e(n,r),n.prototype._update=function(){for(var e=s,t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d;n=h(n=h(n=h(n=h(n=c(n=c(n=c(n=c(n=f(n=f(n=f(n=f(n=u(n=u(n=u(n=u(n,i=u(i,o=u(o,r=u(r,n,i,o,e[0],3614090360,7),n,i,e[1],3905402710,12),r,n,e[2],606105819,17),o,r,e[3],3250441966,22),i=u(i,o=u(o,r=u(r,n,i,o,e[4],4118548399,7),n,i,e[5],1200080426,12),r,n,e[6],2821735955,17),o,r,e[7],4249261313,22),i=u(i,o=u(o,r=u(r,n,i,o,e[8],1770035416,7),n,i,e[9],2336552879,12),r,n,e[10],4294925233,17),o,r,e[11],2304563134,22),i=u(i,o=u(o,r=u(r,n,i,o,e[12],1804603682,7),n,i,e[13],4254626195,12),r,n,e[14],2792965006,17),o,r,e[15],1236535329,22),i=f(i,o=f(o,r=f(r,n,i,o,e[1],4129170786,5),n,i,e[6],3225465664,9),r,n,e[11],643717713,14),o,r,e[0],3921069994,20),i=f(i,o=f(o,r=f(r,n,i,o,e[5],3593408605,5),n,i,e[10],38016083,9),r,n,e[15],3634488961,14),o,r,e[4],3889429448,20),i=f(i,o=f(o,r=f(r,n,i,o,e[9],568446438,5),n,i,e[14],3275163606,9),r,n,e[3],4107603335,14),o,r,e[8],1163531501,20),i=f(i,o=f(o,r=f(r,n,i,o,e[13],2850285829,5),n,i,e[2],4243563512,9),r,n,e[7],1735328473,14),o,r,e[12],2368359562,20),i=c(i,o=c(o,r=c(r,n,i,o,e[5],4294588738,4),n,i,e[8],2272392833,11),r,n,e[11],1839030562,16),o,r,e[14],4259657740,23),i=c(i,o=c(o,r=c(r,n,i,o,e[1],2763975236,4),n,i,e[4],1272893353,11),r,n,e[7],4139469664,16),o,r,e[10],3200236656,23),i=c(i,o=c(o,r=c(r,n,i,o,e[13],681279174,4),n,i,e[0],3936430074,11),r,n,e[3],3572445317,16),o,r,e[6],76029189,23),i=c(i,o=c(o,r=c(r,n,i,o,e[9],3654602809,4),n,i,e[12],3873151461,11),r,n,e[15],530742520,16),o,r,e[2],3299628645,23),i=h(i,o=h(o,r=h(r,n,i,o,e[0],4096336452,6),n,i,e[7],1126891415,10),r,n,e[14],2878612391,15),o,r,e[5],4237533241,21),i=h(i,o=h(o,r=h(r,n,i,o,e[12],1700485571,6),n,i,e[3],2399980690,10),r,n,e[10],4293915773,15),o,r,e[1],2240044497,21),i=h(i,o=h(o,r=h(r,n,i,o,e[8],1873313359,6),n,i,e[15],4264355552,10),r,n,e[6],2734768916,15),o,r,e[13],1309151649,21),i=h(i,o=h(o,r=h(r,n,i,o,e[4],4149444226,6),n,i,e[11],3174756917,10),r,n,e[2],718787259,15),o,r,e[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+n|0,this._c=this._c+i|0,this._d=this._d+o|0},n.prototype._digest=function(){this._block[this._blockOffset++]=128,56<this._blockOffset&&(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=new t(16);return e.writeInt32LE(this._a,0),e.writeInt32LE(this._b,4),e.writeInt32LE(this._c,8),e.writeInt32LE(this._d,12),e},o.exports=n}).call(this,i("buffer").Buffer)},{buffer:48,"hash-base":336,inherits:334}],336:[function(e,t,r){arguments[4][86][0].apply(r,arguments)},{dup:86,inherits:334,"safe-buffer":359,stream:158}],337:[function(e,t,r){arguments[4][107][0].apply(r,arguments)},{"bn.js":249,brorand:250,dup:107}],338:[function(e,t,r){arguments[4][108][0].apply(r,arguments)},{dup:108}],339:[function(e,t,r){arguments[4][109][0].apply(r,arguments)},{dup:109}],340:[function(e,t,r){arguments[4][111][0].apply(r,arguments)},{dup:111}],341:[function(e,t,r){arguments[4][112][0].apply(r,arguments)},{"./certificate":342,"asn1.js":235,dup:112}],342:[function(e,t,r){arguments[4][113][0].apply(r,arguments)},{"asn1.js":235,dup:113}],343:[function(e,t,r){(function(d){var l=/Proc-Type: 4,ENCRYPTED\n\r?DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)\n\r?\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?/m,p=/^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n/m,b=/^-----BEGIN ((?:.* KEY)|CERTIFICATE)-----\n\r?([0-9A-z\n\r\+\/\=]+)\n\r?-----END \1-----$/m,m=e("evp_bytestokey"),y=e("browserify-aes");t.exports=function(e,t){var r,n=e.toString(),i=n.match(l);if(i){var o="aes"+i[1],s=new d(i[2],"hex"),a=new d(i[3].replace(/\r?\n/g,""),"base64"),u=m(t,s.slice(0,8),parseInt(i[1],10)).key,f=[],c=y.createDecipheriv(o,u,s);f.push(c.update(a)),f.push(c.final()),r=d.concat(f)}else{var h=n.match(b);r=new d(h[2].replace(/\r?\n/g,""),"base64")}return{tag:n.match(p)[1],data:r}}}).call(this,e("buffer").Buffer)},{"browserify-aes":253,buffer:48,evp_bytestokey:319}],344:[function(t,r,e){(function(v){var g=t("./asn1"),w=t("./aesid.json"),_=t("./fixProc"),M=t("browserify-aes"),x=t("pbkdf2");function e(e){var t;"object"!==(void 0===e?"undefined":_typeof(e))||v.isBuffer(e)||(t=e.passphrase,e=e.key),"string"==typeof e&&(e=new v(e));var r,n,i,o,s,a,u,f,c,h,d,l,p,b=_(e,t),m=b.tag,y=b.data;switch(m){case"CERTIFICATE":n=g.certificate.decode(y,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(n||(n=g.PublicKey.decode(y,"der")),r=n.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return g.RSAPublicKey.decode(n.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return n.subjectPrivateKey=n.subjectPublicKey,{type:"ec",data:n};case"1.2.840.10040.4.1":return n.algorithm.params.pub_key=g.DSAparam.decode(n.subjectPublicKey.data,"der"),{type:"dsa",data:n.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+m);case"ENCRYPTED PRIVATE KEY":y=g.EncryptedPrivateKey.decode(y,"der"),o=t,s=(i=y).algorithm.decrypt.kde.kdeparams.salt,a=parseInt(i.algorithm.decrypt.kde.kdeparams.iters.toString(),10),u=w[i.algorithm.decrypt.cipher.algo.join(".")],f=i.algorithm.decrypt.cipher.iv,c=i.subjectPrivateKey,h=parseInt(u.split("-")[1],10)/8,d=x.pbkdf2Sync(o,s,a,h),l=M.createDecipheriv(u,d,f),(p=[]).push(l.update(c)),p.push(l.final()),y=v.concat(p);case"PRIVATE KEY":switch(r=(n=g.PrivateKey.decode(y,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return g.RSAPrivateKey.decode(n.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:n.algorithm.curve,privateKey:g.ECPrivateKey.decode(n.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return n.algorithm.params.priv_key=g.DSAparam.decode(n.subjectPrivateKey,"der"),{type:"dsa",params:n.algorithm.params};default:throw new Error("unknown key id "+r)}throw new Error("unknown key type "+m);case"RSA PUBLIC KEY":return g.RSAPublicKey.decode(y,"der");case"RSA PRIVATE KEY":return g.RSAPrivateKey.decode(y,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:g.DSAPrivateKey.decode(y,"der")};case"EC PRIVATE KEY":return{curve:(y=g.ECPrivateKey.decode(y,"der")).parameters.value,privateKey:y.privateKey};default:throw new Error("unknown key type "+m)}}(r.exports=e).signature=g.signature}).call(this,t("buffer").Buffer)},{"./aesid.json":340,"./asn1":341,"./fixProc":343,"browserify-aes":253,buffer:48,pbkdf2:345}],345:[function(e,t,r){r.pbkdf2=e("./lib/async"),r.pbkdf2Sync=e("./lib/sync")},{"./lib/async":346,"./lib/sync":349}],346:[function(e,t,r){(function(f,c){var h,d=e("./precondition"),l=e("./default-encoding"),p=e("./sync"),b=e("safe-buffer").Buffer,m=c.crypto&&c.crypto.subtle,y={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},v=[];function g(e,t,r,n,i){return m.importKey("raw",e,{name:"PBKDF2"},!1,["deriveBits"]).then(function(e){return m.deriveBits({name:"PBKDF2",salt:t,iterations:r,hash:{name:i}},e,n<<3)}).then(function(e){return b.from(e)})}t.exports=function(t,r,n,i,o,s){if(b.isBuffer(t)||(t=b.from(t,l)),b.isBuffer(r)||(r=b.from(r,l)),d(n,i),"function"==typeof o&&(s=o,o=void 0),"function"!=typeof s)throw new Error("No callback provided to pbkdf2");var e,a,u=y[(o=o||"sha1").toLowerCase()];if(!u||"function"!=typeof c.Promise)return f.nextTick(function(){var e;try{e=p(t,r,n,i,o)}catch(e){return s(e)}s(null,e)});e=function(e){if(c.process&&!c.process.browser)return Promise.resolve(!1);if(!m||!m.importKey||!m.deriveBits)return Promise.resolve(!1);if(void 0!==v[e])return v[e];var t=g(h=h||b.alloc(8),h,10,128,e).then(function(){return!0}).catch(function(){return!1});return v[e]=t}(u).then(function(e){return e?g(t,r,n,i,u):p(t,r,n,i,o)}),a=s,e.then(function(e){f.nextTick(function(){a(null,e)})},function(e){f.nextTick(function(){a(e)})})}}).call(this,e("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{"./default-encoding":347,"./precondition":348,"./sync":349,_process:122,"safe-buffer":359}],347:[function(e,r,t){(function(e){var t;e.browser?t="utf-8":t=6<=parseInt(e.version.split(".")[0].slice(1),10)?"utf-8":"binary";r.exports=t}).call(this,e("_process"))},{_process:122}],348:[function(e,t,r){var n=Math.pow(2,30)-1;t.exports=function(e,t){if("number"!=typeof e)throw new TypeError("Iterations not a number");if(e<0)throw new TypeError("Bad iterations");if("number"!=typeof t)throw new TypeError("Key length not a number");if(t<0||n<t||t!=t)throw new TypeError("Bad key length")}},{}],349:[function(e,t,r){var c=e("create-hash/md5"),h=e("ripemd160"),d=e("sha.js"),m=e("./precondition"),y=e("./default-encoding"),v=e("safe-buffer").Buffer,l=v.alloc(128),g={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function w(e,t,r){var n,i="rmd160"===(n=e)||"ripemd160"===n?h:"md5"===n?c:function(e){return d(n).update(e).digest()},o="sha512"===e||"sha384"===e?128:64;t.length>o?t=i(t):t.length<o&&(t=v.concat([t,l],o));for(var s=v.allocUnsafe(o+g[e]),a=v.allocUnsafe(o+g[e]),u=0;u<o;u++)s[u]=54^t[u],a[u]=92^t[u];var f=v.allocUnsafe(o+r+4);s.copy(f,0,0,o),this.ipad1=f,this.ipad2=s,this.opad=a,this.alg=e,this.blocksize=o,this.hash=i,this.size=g[e]}w.prototype.run=function(e,t){return e.copy(t,this.blocksize),this.hash(t).copy(this.opad,this.blocksize),this.hash(this.opad)},t.exports=function(e,t,r,n,i){v.isBuffer(e)||(e=v.from(e,y)),v.isBuffer(t)||(t=v.from(t,y)),m(r,n);var o=new w(i=i||"sha1",e,t.length),s=v.allocUnsafe(n),a=v.allocUnsafe(t.length+4);t.copy(a,0,0,t.length);for(var u=0,f=g[i],c=Math.ceil(n/f),h=1;h<=c;h++){a.writeUInt32BE(h,t.length);for(var d=o.run(a,o.ipad1),l=d,p=1;p<r;p++){l=o.run(l,o.ipad2);for(var b=0;b<f;b++)d[b]^=l[b]}d.copy(s,u),u+=f}return s}},{"./default-encoding":347,"./precondition":348,"create-hash/md5":283,ripemd160:358,"safe-buffer":359,"sha.js":363}],350:[function(e,t,r){arguments[4][123][0].apply(r,arguments)},{"./privateDecrypt":352,"./publicEncrypt":353,dup:123}],351:[function(e,t,r){(function(o){var s=e("create-hash");function a(e){var t=new o(4);return t.writeUInt32BE(e,0),t}t.exports=function(e,t){for(var r,n=new o(""),i=0;n.length<t;)r=a(i++),n=o.concat([n,s("sha1").update(e).update(r).digest()]);return n.slice(0,t)}}).call(this,e("buffer").Buffer)},{buffer:48,"create-hash":281}],352:[function(e,t,r){(function(c){var u=e("parse-asn1"),h=e("./mgf"),d=e("./xor"),f=e("bn.js"),l=e("browserify-rsa"),p=e("create-hash"),b=e("./withPublic");t.exports=function(e,t,r){var n;n=e.padding?e.padding:r?1:4;var i,o=u(e),s=o.modulus.byteLength();if(t.length>s||0<=new f(t).cmp(o.modulus))throw new Error("decryption error");i=r?b(new f(t),o):l(t,o);var a=new c(s-i.length);if(a.fill(0),i=c.concat([a,i],s),4===n)return function(e,t){e.modulus;var r=e.modulus.byteLength(),n=(t.length,p("sha1").update(new c("")).digest()),i=n.length;if(0!==t[0])throw new Error("decryption error");var o=t.slice(1,i+1),s=t.slice(i+1),a=d(o,h(s,i)),u=d(s,h(a,r-i-1));if(function(e,t){e=new c(e),t=new c(t);var r=0,n=e.length;e.length!==t.length&&(r++,n=Math.min(e.length,t.length));var i=-1;for(;++i<n;)r+=e[i]^t[i];return r}(n,u.slice(0,i)))throw new Error("decryption error");var f=i;for(;0===u[f];)f++;if(1!==u[f++])throw new Error("decryption error");return u.slice(f)}(o,i);if(1===n)return function(e,t,r){var n=t.slice(0,2),i=2,o=0;for(;0!==t[i++];)if(i>=t.length){o++;break}var s=t.slice(2,i-1);t.slice(i-1,i);("0002"!==n.toString("hex")&&!r||"0001"!==n.toString("hex")&&r)&&o++;s.length<8&&o++;if(o)throw new Error("decryption error");return t.slice(i)}(0,i,r);if(3===n)return i;throw new Error("unknown padding")}}).call(this,e("buffer").Buffer)},{"./mgf":351,"./withPublic":354,"./xor":355,"bn.js":249,"browserify-rsa":271,buffer:48,"create-hash":281,"parse-asn1":344}],353:[function(e,t,r){(function(d){var s=e("parse-asn1"),l=e("randombytes"),p=e("create-hash"),b=e("./mgf"),m=e("./xor"),y=e("bn.js"),a=e("./withPublic"),u=e("browserify-rsa");t.exports=function(e,t,r){var n;n=e.padding?e.padding:r?1:4;var i,o=s(e);if(4===n)i=function(e,t){var r=e.modulus.byteLength(),n=t.length,i=p("sha1").update(new d("")).digest(),o=i.length,s=2*o;if(r-s-2<n)throw new Error("message too long");var a=new d(r-n-s-2);a.fill(0);var u=r-o-1,f=l(o),c=m(d.concat([i,a,new d([1]),t],u),b(f,u)),h=m(f,b(c,o));return new y(d.concat([new d([0]),h,c],r))}(o,t);else if(1===n)i=function(e,t,r){var n,i=t.length,o=e.modulus.byteLength();if(o-11<i)throw new Error("message too long");r?(n=new d(o-i-3)).fill(255):n=function(e,t){var r,n=new d(e),i=0,o=l(2*e),s=0;for(;i<e;)s===o.length&&(o=l(2*e),s=0),(r=o[s++])&&(n[i++]=r);return n}(o-i-3);return new y(d.concat([new d([0,r?1:2]),n,new d([0]),t],o))}(o,t,r);else{if(3!==n)throw new Error("unknown padding");if(0<=(i=new y(t)).cmp(o.modulus))throw new Error("data too long for modulus")}return r?u(i,o):a(i,o)}}).call(this,e("buffer").Buffer)},{"./mgf":351,"./withPublic":354,"./xor":355,"bn.js":249,"browserify-rsa":271,buffer:48,"create-hash":281,"parse-asn1":344,randombytes:356}],354:[function(e,t,r){(function(r){var n=e("bn.js");t.exports=function(e,t){return new r(e.toRed(n.mont(t.modulus)).redPow(new n(t.publicExponent)).fromRed().toArray())}}).call(this,e("buffer").Buffer)},{"bn.js":249,buffer:48}],355:[function(e,t,r){arguments[4][128][0].apply(r,arguments)},{dup:128}],356:[function(e,t,r){(function(i,o){var s=e("safe-buffer").Buffer,a=o.crypto||o.msCrypto;a&&a.getRandomValues?t.exports=function(e,t){if(65536<e)throw new Error("requested too many random bytes");var r=new o.Uint8Array(e);0<e&&a.getRandomValues(r);var n=s.from(r.buffer);if("function"==typeof t)return i.nextTick(function(){t(null,n)});return n}:t.exports=function(){throw new Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}}).call(this,e("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:122,"safe-buffer":359}],357:[function(r,e,l){(function(s,i){function e(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var t=r("safe-buffer"),a=r("randombytes"),o=t.Buffer,n=t.kMaxLength,u=i.crypto||i.msCrypto,f=Math.pow(2,32)-1;function c(e,t){if("number"!=typeof e||e!=e)throw new TypeError("offset must be a number");if(f<e||e<0)throw new TypeError("offset must be a uint32");if(n<e||t<e)throw new RangeError("offset out of range")}function h(e,t,r){if("number"!=typeof e||e!=e)throw new TypeError("size must be a number");if(f<e||e<0)throw new TypeError("size must be a uint32");if(r<e+t||n<e)throw new RangeError("buffer too small")}function d(r,n,e,i){if(s.browser){var t=r.buffer,o=new Uint8Array(t,n,e);return u.getRandomValues(o),i?void s.nextTick(function(){i(null,r)}):r}if(!i)return a(e).copy(r,n),r;a(e,function(e,t){if(e)return i(e);t.copy(r,n),i(null,r)})}u&&u.getRandomValues||!s.browser?(l.randomFill=function(e,t,r,n){if(!(o.isBuffer(e)||e instanceof i.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof t)n=t,t=0,r=e.length;else if("function"==typeof r)n=r,r=e.length-t;else if("function"!=typeof n)throw new TypeError('"cb" argument must be a function');return c(t,e.length),h(r,t,e.length),d(e,t,r,n)},l.randomFillSync=function(e,t,r){void 0===t&&(t=0);if(!(o.isBuffer(e)||e instanceof i.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');c(t,e.length),void 0===r&&(r=e.length-t);return h(r,t,e.length),d(e,t,r)}):(l.randomFill=e,l.randomFillSync=e)}).call(this,r("_process"),"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{_process:122,randombytes:356,"safe-buffer":359}],358:[function(i,o,e){(function(t){var e=i("inherits"),r=i("hash-base");function n(){r.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function l(e,t){return e<<t|e>>>32-t}function p(e,t,r,n,i,o,s,a){return l(e+(t^r^n)+o+s|0,a)+i|0}function b(e,t,r,n,i,o,s,a){return l(e+(t&r|~t&n)+o+s|0,a)+i|0}function m(e,t,r,n,i,o,s,a){return l(e+((t|~r)^n)+o+s|0,a)+i|0}function y(e,t,r,n,i,o,s,a){return l(e+(t&n|r&~n)+o+s|0,a)+i|0}function v(e,t,r,n,i,o,s,a){return l(e+(t^(r|~n))+o+s|0,a)+i|0}e(n,r),n.prototype._update=function(){for(var e=new Array(16),t=0;t<16;++t)e[t]=this._block.readInt32LE(4*t);var r=this._a,n=this._b,i=this._c,o=this._d,s=this._e;s=p(s,r=p(r,n,i,o,s,e[0],0,11),n,i=l(i,10),o,e[1],0,14),n=p(n=l(n,10),i=p(i,o=p(o,s,r,n,i,e[2],0,15),s,r=l(r,10),n,e[3],0,12),o,s=l(s,10),r,e[4],0,5),o=p(o=l(o,10),s=p(s,r=p(r,n,i,o,s,e[5],0,8),n,i=l(i,10),o,e[6],0,7),r,n=l(n,10),i,e[7],0,9),r=p(r=l(r,10),n=p(n,i=p(i,o,s,r,n,e[8],0,11),o,s=l(s,10),r,e[9],0,13),i,o=l(o,10),s,e[10],0,14),i=p(i=l(i,10),o=p(o,s=p(s,r,n,i,o,e[11],0,15),r,n=l(n,10),i,e[12],0,6),s,r=l(r,10),n,e[13],0,7),s=b(s=l(s,10),r=p(r,n=p(n,i,o,s,r,e[14],0,9),i,o=l(o,10),s,e[15],0,8),n,i=l(i,10),o,e[7],1518500249,7),n=b(n=l(n,10),i=b(i,o=b(o,s,r,n,i,e[4],1518500249,6),s,r=l(r,10),n,e[13],1518500249,8),o,s=l(s,10),r,e[1],1518500249,13),o=b(o=l(o,10),s=b(s,r=b(r,n,i,o,s,e[10],1518500249,11),n,i=l(i,10),o,e[6],1518500249,9),r,n=l(n,10),i,e[15],1518500249,7),r=b(r=l(r,10),n=b(n,i=b(i,o,s,r,n,e[3],1518500249,15),o,s=l(s,10),r,e[12],1518500249,7),i,o=l(o,10),s,e[0],1518500249,12),i=b(i=l(i,10),o=b(o,s=b(s,r,n,i,o,e[9],1518500249,15),r,n=l(n,10),i,e[5],1518500249,9),s,r=l(r,10),n,e[2],1518500249,11),s=b(s=l(s,10),r=b(r,n=b(n,i,o,s,r,e[14],1518500249,7),i,o=l(o,10),s,e[11],1518500249,13),n,i=l(i,10),o,e[8],1518500249,12),n=m(n=l(n,10),i=m(i,o=m(o,s,r,n,i,e[3],1859775393,11),s,r=l(r,10),n,e[10],1859775393,13),o,s=l(s,10),r,e[14],1859775393,6),o=m(o=l(o,10),s=m(s,r=m(r,n,i,o,s,e[4],1859775393,7),n,i=l(i,10),o,e[9],1859775393,14),r,n=l(n,10),i,e[15],1859775393,9),r=m(r=l(r,10),n=m(n,i=m(i,o,s,r,n,e[8],1859775393,13),o,s=l(s,10),r,e[1],1859775393,15),i,o=l(o,10),s,e[2],1859775393,14),i=m(i=l(i,10),o=m(o,s=m(s,r,n,i,o,e[7],1859775393,8),r,n=l(n,10),i,e[0],1859775393,13),s,r=l(r,10),n,e[6],1859775393,6),s=m(s=l(s,10),r=m(r,n=m(n,i,o,s,r,e[13],1859775393,5),i,o=l(o,10),s,e[11],1859775393,12),n,i=l(i,10),o,e[5],1859775393,7),n=y(n=l(n,10),i=y(i,o=m(o,s,r,n,i,e[12],1859775393,5),s,r=l(r,10),n,e[1],2400959708,11),o,s=l(s,10),r,e[9],2400959708,12),o=y(o=l(o,10),s=y(s,r=y(r,n,i,o,s,e[11],2400959708,14),n,i=l(i,10),o,e[10],2400959708,15),r,n=l(n,10),i,e[0],2400959708,14),r=y(r=l(r,10),n=y(n,i=y(i,o,s,r,n,e[8],2400959708,15),o,s=l(s,10),r,e[12],2400959708,9),i,o=l(o,10),s,e[4],2400959708,8),i=y(i=l(i,10),o=y(o,s=y(s,r,n,i,o,e[13],2400959708,9),r,n=l(n,10),i,e[3],2400959708,14),s,r=l(r,10),n,e[7],2400959708,5),s=y(s=l(s,10),r=y(r,n=y(n,i,o,s,r,e[15],2400959708,6),i,o=l(o,10),s,e[14],2400959708,8),n,i=l(i,10),o,e[5],2400959708,6),n=v(n=l(n,10),i=y(i,o=y(o,s,r,n,i,e[6],2400959708,5),s,r=l(r,10),n,e[2],2400959708,12),o,s=l(s,10),r,e[4],2840853838,9),o=v(o=l(o,10),s=v(s,r=v(r,n,i,o,s,e[0],2840853838,15),n,i=l(i,10),o,e[5],2840853838,5),r,n=l(n,10),i,e[9],2840853838,11),r=v(r=l(r,10),n=v(n,i=v(i,o,s,r,n,e[7],2840853838,6),o,s=l(s,10),r,e[12],2840853838,8),i,o=l(o,10),s,e[2],2840853838,13),i=v(i=l(i,10),o=v(o,s=v(s,r,n,i,o,e[10],2840853838,12),r,n=l(n,10),i,e[14],2840853838,5),s,r=l(r,10),n,e[1],2840853838,12),s=v(s=l(s,10),r=v(r,n=v(n,i,o,s,r,e[3],2840853838,13),i,o=l(o,10),s,e[8],2840853838,14),n,i=l(i,10),o,e[11],2840853838,11),n=v(n=l(n,10),i=v(i,o=v(o,s,r,n,i,e[6],2840853838,8),s,r=l(r,10),n,e[15],2840853838,5),o,s=l(s,10),r,e[13],2840853838,6),o=l(o,10);var a=this._a,u=this._b,f=this._c,c=this._d,h=this._e;h=v(h,a=v(a,u,f,c,h,e[5],1352829926,8),u,f=l(f,10),c,e[14],1352829926,9),u=v(u=l(u,10),f=v(f,c=v(c,h,a,u,f,e[7],1352829926,9),h,a=l(a,10),u,e[0],1352829926,11),c,h=l(h,10),a,e[9],1352829926,13),c=v(c=l(c,10),h=v(h,a=v(a,u,f,c,h,e[2],1352829926,15),u,f=l(f,10),c,e[11],1352829926,15),a,u=l(u,10),f,e[4],1352829926,5),a=v(a=l(a,10),u=v(u,f=v(f,c,h,a,u,e[13],1352829926,7),c,h=l(h,10),a,e[6],1352829926,7),f,c=l(c,10),h,e[15],1352829926,8),f=v(f=l(f,10),c=v(c,h=v(h,a,u,f,c,e[8],1352829926,11),a,u=l(u,10),f,e[1],1352829926,14),h,a=l(a,10),u,e[10],1352829926,14),h=y(h=l(h,10),a=v(a,u=v(u,f,c,h,a,e[3],1352829926,12),f,c=l(c,10),h,e[12],1352829926,6),u,f=l(f,10),c,e[6],1548603684,9),u=y(u=l(u,10),f=y(f,c=y(c,h,a,u,f,e[11],1548603684,13),h,a=l(a,10),u,e[3],1548603684,15),c,h=l(h,10),a,e[7],1548603684,7),c=y(c=l(c,10),h=y(h,a=y(a,u,f,c,h,e[0],1548603684,12),u,f=l(f,10),c,e[13],1548603684,8),a,u=l(u,10),f,e[5],1548603684,9),a=y(a=l(a,10),u=y(u,f=y(f,c,h,a,u,e[10],1548603684,11),c,h=l(h,10),a,e[14],1548603684,7),f,c=l(c,10),h,e[15],1548603684,7),f=y(f=l(f,10),c=y(c,h=y(h,a,u,f,c,e[8],1548603684,12),a,u=l(u,10),f,e[12],1548603684,7),h,a=l(a,10),u,e[4],1548603684,6),h=y(h=l(h,10),a=y(a,u=y(u,f,c,h,a,e[9],1548603684,15),f,c=l(c,10),h,e[1],1548603684,13),u,f=l(f,10),c,e[2],1548603684,11),u=m(u=l(u,10),f=m(f,c=m(c,h,a,u,f,e[15],1836072691,9),h,a=l(a,10),u,e[5],1836072691,7),c,h=l(h,10),a,e[1],1836072691,15),c=m(c=l(c,10),h=m(h,a=m(a,u,f,c,h,e[3],1836072691,11),u,f=l(f,10),c,e[7],1836072691,8),a,u=l(u,10),f,e[14],1836072691,6),a=m(a=l(a,10),u=m(u,f=m(f,c,h,a,u,e[6],1836072691,6),c,h=l(h,10),a,e[9],1836072691,14),f,c=l(c,10),h,e[11],1836072691,12),f=m(f=l(f,10),c=m(c,h=m(h,a,u,f,c,e[8],1836072691,13),a,u=l(u,10),f,e[12],1836072691,5),h,a=l(a,10),u,e[2],1836072691,14),h=m(h=l(h,10),a=m(a,u=m(u,f,c,h,a,e[10],1836072691,13),f,c=l(c,10),h,e[0],1836072691,13),u,f=l(f,10),c,e[4],1836072691,7),u=b(u=l(u,10),f=b(f,c=m(c,h,a,u,f,e[13],1836072691,5),h,a=l(a,10),u,e[8],2053994217,15),c,h=l(h,10),a,e[6],2053994217,5),c=b(c=l(c,10),h=b(h,a=b(a,u,f,c,h,e[4],2053994217,8),u,f=l(f,10),c,e[1],2053994217,11),a,u=l(u,10),f,e[3],2053994217,14),a=b(a=l(a,10),u=b(u,f=b(f,c,h,a,u,e[11],2053994217,14),c,h=l(h,10),a,e[15],2053994217,6),f,c=l(c,10),h,e[0],2053994217,14),f=b(f=l(f,10),c=b(c,h=b(h,a,u,f,c,e[5],2053994217,6),a,u=l(u,10),f,e[12],2053994217,9),h,a=l(a,10),u,e[2],2053994217,12),h=b(h=l(h,10),a=b(a,u=b(u,f,c,h,a,e[13],2053994217,9),f,c=l(c,10),h,e[9],2053994217,12),u,f=l(f,10),c,e[7],2053994217,5),u=p(u=l(u,10),f=b(f,c=b(c,h,a,u,f,e[10],2053994217,15),h,a=l(a,10),u,e[14],2053994217,8),c,h=l(h,10),a,e[12],0,8),c=p(c=l(c,10),h=p(h,a=p(a,u,f,c,h,e[15],0,5),u,f=l(f,10),c,e[10],0,12),a,u=l(u,10),f,e[4],0,9),a=p(a=l(a,10),u=p(u,f=p(f,c,h,a,u,e[1],0,12),c,h=l(h,10),a,e[5],0,5),f,c=l(c,10),h,e[8],0,14),f=p(f=l(f,10),c=p(c,h=p(h,a,u,f,c,e[7],0,6),a,u=l(u,10),f,e[6],0,8),h,a=l(a,10),u,e[2],0,13),h=p(h=l(h,10),a=p(a,u=p(u,f,c,h,a,e[13],0,6),f,c=l(c,10),h,e[14],0,5),u,f=l(f,10),c,e[0],0,15),u=p(u=l(u,10),f=p(f,c=p(c,h,a,u,f,e[3],0,13),h,a=l(a,10),u,e[9],0,11),c,h=l(h,10),a,e[11],0,11),c=l(c,10);var d=this._b+i+c|0;this._b=this._c+o+h|0,this._c=this._d+s+a|0,this._d=this._e+r+u|0,this._e=this._a+n+f|0,this._a=d},n.prototype._digest=function(){this._block[this._blockOffset++]=128,56<this._blockOffset&&(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=new t(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},o.exports=n}).call(this,i("buffer").Buffer)},{buffer:48,"hash-base":320,inherits:334}],359:[function(e,t,r){arguments[4][149][0].apply(r,arguments)},{buffer:48,dup:149}],360:[function(e,t,r){t.exports=e("scryptsy")},{scryptsy:361}],361:[function(e,t,r){(function(M){var x=e("pbkdf2").pbkdf2Sync;function k(e,t,r,n,i){if(M.isBuffer(e)&&M.isBuffer(r))e.copy(r,n,t,t+i);else for(;i--;)r[n++]=e[t++]}t.exports=function(e,t,r,n,i,o,s){if(0===r||0!=(r&r-1))throw Error("N must be > 0 and a power of 2");if(2147483647/128/n<r)throw Error("Parameter N is too large");if(2147483647/128/i<n)throw Error("Parameter r is too large");var f,a=new M(256*n),u=new M(128*n*r),c=new Int32Array(16),h=new Int32Array(16),d=new M(64),l=x(e,t,1,128*i*n,"sha256");if(s){var p=i*r*2,b=0;f=function(){++b%1e3==0&&s({current:b,total:p,percent:b/p*100})}}for(var m=0;m<i;m++)y(l,128*m*n,n,r,u,a);return x(e,l,1,o,"sha256");function y(e,t,r,n,i,o){var s,a=128*r;for(e.copy(o,0,t,t+a),s=0;s<n;s++)o.copy(i,s*a,0,0+a),v(o,0,a,r),f&&f();for(s=0;s<n;s++){var u=0+64*(2*r-1);_(i,(o.readUInt32LE(u)&n-1)*a,o,0,a),v(o,0,a,r),f&&f()}o.copy(e,t,0,0+a)}function v(e,t,r,n){var i;for(k(e,t+64*(2*n-1),d,0,64),i=0;i<2*n;i++)_(e,64*i,d,0,64),w(d),k(d,0,e,r+64*i,64);for(i=0;i<n;i++)k(e,r+2*i*64,e,t+64*i,64);for(i=0;i<n;i++)k(e,r+64*(2*i+1),e,t+64*(i+n),64)}function g(e,t){return e<<t|e>>>32-t}function w(e){var t;for(t=0;t<16;t++)c[t]=(255&e[4*t+0])<<0,c[t]|=(255&e[4*t+1])<<8,c[t]|=(255&e[4*t+2])<<16,c[t]|=(255&e[4*t+3])<<24;for(k(c,0,h,0,16),t=8;0<t;t-=2)h[4]^=g(h[0]+h[12],7),h[8]^=g(h[4]+h[0],9),h[12]^=g(h[8]+h[4],13),h[0]^=g(h[12]+h[8],18),h[9]^=g(h[5]+h[1],7),h[13]^=g(h[9]+h[5],9),h[1]^=g(h[13]+h[9],13),h[5]^=g(h[1]+h[13],18),h[14]^=g(h[10]+h[6],7),h[2]^=g(h[14]+h[10],9),h[6]^=g(h[2]+h[14],13),h[10]^=g(h[6]+h[2],18),h[3]^=g(h[15]+h[11],7),h[7]^=g(h[3]+h[15],9),h[11]^=g(h[7]+h[3],13),h[15]^=g(h[11]+h[7],18),h[1]^=g(h[0]+h[3],7),h[2]^=g(h[1]+h[0],9),h[3]^=g(h[2]+h[1],13),h[0]^=g(h[3]+h[2],18),h[6]^=g(h[5]+h[4],7),h[7]^=g(h[6]+h[5],9),h[4]^=g(h[7]+h[6],13),h[5]^=g(h[4]+h[7],18),h[11]^=g(h[10]+h[9],7),h[8]^=g(h[11]+h[10],9),h[9]^=g(h[8]+h[11],13),h[10]^=g(h[9]+h[8],18),h[12]^=g(h[15]+h[14],7),h[13]^=g(h[12]+h[15],9),h[14]^=g(h[13]+h[12],13),h[15]^=g(h[14]+h[13],18);for(t=0;t<16;++t)c[t]=h[t]+c[t];for(t=0;t<16;t++){var r=4*t;e[r+0]=c[t]>>0&255,e[r+1]=c[t]>>8&255,e[r+2]=c[t]>>16&255,e[r+3]=c[t]>>24&255}}function _(e,t,r,n,i){for(var o=0;o<i;o++)r[n+o]^=e[t+o]}}}).call(this,e("buffer").Buffer)},{buffer:48,pbkdf2:345}],362:[function(e,t,r){var c=e("safe-buffer").Buffer;function n(e,t){this._block=c.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}n.prototype.update=function(e,t){"string"==typeof e&&(t=t||"utf8",e=c.from(e,t));for(var r=this._block,n=this._blockSize,i=e.length,o=this._len,s=0;s<i;){for(var a=o%n,u=Math.min(i-s,n-a),f=0;f<u;f++)r[a+f]=e[s+f];s+=u,(o+=u)%n==0&&this._update(r)}return this._len+=i,this},n.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 r=8*this._len;if(r<=4294967295)this._block.writeUInt32BE(r,this._blockSize-4);else{var n=4294967295&r,i=(r-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return e?o.toString(e):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},{"safe-buffer":359}],363:[function(e,t,r){arguments[4][151][0].apply(r,arguments)},{"./sha":364,"./sha1":365,"./sha224":366,"./sha256":367,"./sha384":368,"./sha512":369,dup:151}],364:[function(e,t,r){arguments[4][152][0].apply(r,arguments)},{"./hash":362,dup:152,inherits:334,"safe-buffer":359}],365:[function(e,t,r){arguments[4][153][0].apply(r,arguments)},{"./hash":362,dup:153,inherits:334,"safe-buffer":359}],366:[function(e,t,r){arguments[4][154][0].apply(r,arguments)},{"./hash":362,"./sha256":367,dup:154,inherits:334,"safe-buffer":359}],367:[function(e,t,r){arguments[4][155][0].apply(r,arguments)},{"./hash":362,dup:155,inherits:334,"safe-buffer":359}],368:[function(e,t,r){arguments[4][156][0].apply(r,arguments)},{"./hash":362,"./sha512":369,dup:156,inherits:334,"safe-buffer":359}],369:[function(e,t,r){arguments[4][157][0].apply(r,arguments)},{"./hash":362,dup:157,inherits:334,"safe-buffer":359}],370:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],371:[function(e,i,t){(function(e){var t;if(e.crypto&&crypto.getRandomValues){var r=new Uint8Array(16);t=function(){return crypto.getRandomValues(r),r}}if(!t){var n=new Array(16);t=function(){for(var e,t=0;t<16;t++)0==(3&t)&&(e=4294967296*Math.random()),n[t]=e>>>((3&t)<<3)&255;return n}}i.exports=t}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],372:[function(e,t,r){for(var s=e("./rng"),i=[],o={},n=0;n<256;n++)i[n]=(n+256).toString(16).substr(1),o[i[n]]=n;function l(e,t){var r=t||0,n=i;return n[e[r++]]+n[e[r++]]+n[e[r++]]+n[e[r++]]+"-"+n[e[r++]]+n[e[r++]]+"-"+n[e[r++]]+n[e[r++]]+"-"+n[e[r++]]+n[e[r++]]+"-"+n[e[r++]]+n[e[r++]]+n[e[r++]]+n[e[r++]]+n[e[r++]]+n[e[r++]]}var a=s(),p=[1|a[0],a[1],a[2],a[3],a[4],a[5]],b=16383&(a[6]<<8|a[7]),m=0,y=0;function u(e,t,r){var n=t&&r||0;"string"==typeof e&&(t="binary"==e?new Array(16):null,e=null);var i=(e=e||{}).random||(e.rng||s)();if(i[6]=15&i[6]|64,i[8]=63&i[8]|128,t)for(var o=0;o<16;o++)t[n+o]=i[o];return t||l(i)}var f=u;f.v1=function(e,t,r){var n=t&&r||0,i=t||[],o=void 0!==(e=e||{}).clockseq?e.clockseq:b,s=void 0!==e.msecs?e.msecs:(new Date).getTime(),a=void 0!==e.nsecs?e.nsecs:y+1,u=s-m+(a-y)/1e4;if(u<0&&void 0===e.clockseq&&(o=o+1&16383),(u<0||m<s)&&void 0===e.nsecs&&(a=0),1e4<=a)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");m=s,b=o;var f=(1e4*(268435455&(s+=122192928e5))+(y=a))%4294967296;i[n++]=f>>>24&255,i[n++]=f>>>16&255,i[n++]=f>>>8&255,i[n++]=255&f;var c=s/4294967296*1e4&268435455;i[n++]=c>>>8&255,i[n++]=255&c,i[n++]=c>>>24&15|16,i[n++]=c>>>16&255,i[n++]=o>>>8|128,i[n++]=255&o;for(var h=e.node||p,d=0;d<6;d++)i[n+d]=h[d];return t||l(i)},f.v4=u,f.parse=function(e,t,r){var n=t&&r||0,i=0;for(t=t||[],e.toLowerCase().replace(/[0-9a-f]{2}/g,function(e){i<16&&(t[n+i++]=o[e])});i<16;)t[n+i++]=0;return t},f.unparse=l,t.exports=f},{"./rng":371}],373:[function(s,a,e){(function(e,d){var l=s("underscore"),r=s("web3-core"),n=s("web3-core-method"),p=s("any-promise"),b=s("eth-lib/lib/account"),m=s("eth-lib/lib/hash"),y=s("eth-lib/lib/rlp"),v=s("eth-lib/lib/nat"),g=s("eth-lib/lib/bytes"),w=s(void 0===e?"crypto-browserify":"crypto"),_=s("scrypt.js"),M=s("uuid"),x=s("web3-utils"),k=s("web3-core-helpers"),i=function(e){return l.isUndefined(e)||l.isNull(e)},S=function(e){for(;e&&e.startsWith("0x0");)e="0x"+e.slice(3);return e},E=function(e){return e.length%2==1&&(e=e.replace("0x","0x0")),e},t=function(){var t=this;r.packageInit(this,arguments),delete this.BatchRequest,delete this.extend;var e=[new n({name:"getId",call:"net_version",params:0,outputFormatter:x.hexToNumber}),new n({name:"getGasPrice",call:"eth_gasPrice",params:0}),new n({name:"getTransactionCount",call:"eth_getTransactionCount",params:2,inputFormatter:[function(e){if(x.isAddress(e))return e;throw new Error("Address "+e+' is not a valid address to get the "transactionCount".')},function(){return"latest"}]})];this._ethereumCall={},l.each(e,function(e){e.attachToObject(t._ethereumCall),e.setRequestManager(t._requestManager)}),this.wallet=new o(this)};function o(e){this._accounts=e,this.length=0,this.defaultKeyName="web3js_wallet"}t.prototype._addAccountFunctions=function(r){var n=this;return r.signTransaction=function(e,t){return n.signTransaction(e,r.privateKey,t)},r.sign=function(e){return n.sign(e,r.privateKey)},r.encrypt=function(e,t){return n.encrypt(r.privateKey,e,t)},r},t.prototype.create=function(e){return this._addAccountFunctions(b.create(e||x.randomHex(32)))},t.prototype.privateKeyToAccount=function(e){return this._addAccountFunctions(b.fromPrivate(e))},t.prototype.signTransaction=function(t,u,f){var c,h=!1;if(f=f||function(){},!t)return h=new Error("No transaction object given!"),f(h),p.reject(h);function r(e){if(e.gas||e.gasLimit||(h=new Error('"gas" is missing')),(e.nonce<0||e.gas<0||e.gasPrice<0||e.chainId<0)&&(h=new Error("Gas, gasPrice, nonce or chainId is lower than 0")),h)return f(h),p.reject(new Error('"gas" is missing'));try{var t=e=k.formatters.inputCallFormatter(e);t.to=e.to||"0x",t.data=e.data||"0x",t.value=e.value||"0x",t.chainId=x.numberToHex(e.chainId);var r=y.encode([g.fromNat(t.nonce),g.fromNat(t.gasPrice),g.fromNat(t.gas),t.to.toLowerCase(),g.fromNat(t.value),t.data,g.fromNat(t.chainId||"0x1"),"0x","0x"]),n=m.keccak256(r),i=b.makeSigner(2*v.toNumber(t.chainId||"0x1")+35)(m.keccak256(r),u),o=y.decode(r).slice(0,6).concat(b.decodeSignature(i));o[6]=E(S(o[6])),o[7]=E(S(o[7])),o[8]=E(S(o[8]));var s=y.encode(o),a=y.decode(s);c={messageHash:n,v:S(a[6]),r:S(a[7]),s:S(a[8]),rawTransaction:s}}catch(e){return f(e),p.reject(e)}return f(null,c),c}return void 0!==t.nonce&&void 0!==t.chainId&&void 0!==t.gasPrice?p.resolve(r(t)):p.all([i(t.chainId)?this._ethereumCall.getId():t.chainId,i(t.gasPrice)?this._ethereumCall.getGasPrice():t.gasPrice,i(t.nonce)?this._ethereumCall.getTransactionCount(this.privateKeyToAccount(u).address):t.nonce]).then(function(e){if(i(e[0])||i(e[1])||i(e[2]))throw new Error('One of the values "chainId", "gasPrice", or "nonce" couldn\'t be fetched: '+JSON.stringify(e));return r(l.extend(t,{chainId:e[0],gasPrice:e[1],nonce:e[2]}))})},t.prototype.recoverTransaction=function(e){var t=y.decode(e),r=b.encodeSignature(t.slice(6,9)),n=g.toNumber(t[6]),i=n<35?[]:[g.fromNumber(n-35>>1),"0x","0x"],o=t.slice(0,6).concat(i),s=y.encode(o);return b.recover(m.keccak256(s),r)},t.prototype.hashMessage=function(e){var t=x.isHexStrict(e)?x.hexToBytes(e):e,r=d.from(t),n="Ethereum Signed Message:\n"+t.length,i=d.from(n),o=d.concat([i,r]);return m.keccak256s(o)},t.prototype.sign=function(e,t){var r=this.hashMessage(e),n=b.sign(r,t),i=b.decodeSignature(n);return{message:e,messageHash:r,v:i[0],r:i[1],s:i[2],signature:n}},t.prototype.recover=function(e,t,r){var n=[].slice.apply(arguments);return l.isObject(e)?this.recover(e.messageHash,b.encodeSignature([e.v,e.r,e.s]),!0):(r||(e=this.hashMessage(e)),4<=n.length?(r=n.slice(-1)[0],r=!!l.isBoolean(r)&&!!r,this.recover(e,b.encodeSignature(n.slice(1,4)),r)):b.recover(e,t))},t.prototype.decrypt=function(e,t,r){if(!l.isString(t))throw new Error("No password given.");var n,i,o=l.isObject(e)?e:JSON.parse(r?e.toLowerCase():e);if(3!==o.version)throw new Error("Not a valid V3 wallet");if("scrypt"===o.crypto.kdf)i=o.crypto.kdfparams,n=_(new d(t),new d(i.salt,"hex"),i.n,i.r,i.p,i.dklen);else{if("pbkdf2"!==o.crypto.kdf)throw new Error("Unsupported key derivation scheme");if("hmac-sha256"!==(i=o.crypto.kdfparams).prf)throw new Error("Unsupported parameters to PBKDF2");n=w.pbkdf2Sync(new d(t),new d(i.salt,"hex"),i.c,i.dklen,"sha256")}var s=new d(o.crypto.ciphertext,"hex");if(x.sha3(d.concat([n.slice(16,32),s])).replace("0x","")!==o.crypto.mac)throw new Error("Key derivation failed - possibly wrong password");var a=w.createDecipheriv(o.crypto.cipher,n.slice(0,16),new d(o.crypto.cipherparams.iv,"hex")),u="0x"+d.concat([a.update(s),a.final()]).toString("hex");return this.privateKeyToAccount(u)},t.prototype.encrypt=function(e,t,r){var n,i=this.privateKeyToAccount(e),o=(r=r||{}).salt||w.randomBytes(32),s=r.iv||w.randomBytes(16),a=r.kdf||"scrypt",u={dklen:r.dklen||32,salt:o.toString("hex")};if("pbkdf2"===a)u.c=r.c||262144,u.prf="hmac-sha256",n=w.pbkdf2Sync(new d(t),o,u.c,u.dklen,"sha256");else{if("scrypt"!==a)throw new Error("Unsupported kdf");u.n=r.n||8192,u.r=r.r||8,u.p=r.p||1,n=_(new d(t),o,u.n,u.r,u.p,u.dklen)}var f=w.createCipheriv(r.cipher||"aes-128-ctr",n.slice(0,16),s);if(!f)throw new Error("Unsupported cipher");var c=d.concat([f.update(new d(i.privateKey.replace("0x",""),"hex")),f.final()]),h=x.sha3(d.concat([n.slice(16,32),new d(c,"hex")])).replace("0x","");return{version:3,id:M.v4({random:r.uuid||w.randomBytes(16)}),address:i.address.toLowerCase().replace("0x",""),crypto:{ciphertext:c.toString("hex"),cipherparams:{iv:s.toString("hex")},cipher:r.cipher||"aes-128-ctr",kdf:a,kdfparams:u,mac:h.toString("hex")}}},o.prototype._findSafeIndex=function(e){return e=e||0,l.has(this,e)?this._findSafeIndex(e+1):e},o.prototype._currentIndexes=function(){return Object.keys(this).map(function(e){return parseInt(e)}).filter(function(e){return e<9e20})},o.prototype.create=function(e,t){for(var r=0;r<e;++r)this.add(this._accounts.create(t).privateKey);return this},o.prototype.add=function(e){return l.isString(e)&&(e=this._accounts.privateKeyToAccount(e)),this[e.address]?this[e.address]:((e=this._accounts.privateKeyToAccount(e.privateKey)).index=this._findSafeIndex(),this[e.index]=e,this[e.address]=e,this[e.address.toLowerCase()]=e,this.length++,e)},o.prototype.remove=function(e){var t=this[e];return!(!t||!t.address)&&(this[t.address].privateKey=null,delete this[t.address],this[t.address.toLowerCase()].privateKey=null,delete this[t.address.toLowerCase()],this[t.index].privateKey=null,delete this[t.index],this.length--,!0)},o.prototype.clear=function(){var t=this;return this._currentIndexes().forEach(function(e){t.remove(e)}),this},o.prototype.encrypt=function(t,r){var n=this;return this._currentIndexes().map(function(e){return n[e].encrypt(t,r)})},o.prototype.decrypt=function(e,r){var n=this;return e.forEach(function(e){var t=n._accounts.decrypt(e,r);if(!t)throw new Error("Couldn't decrypt accounts. Password wrong?");n.add(t)}),this},o.prototype.save=function(e,t){return localStorage.setItem(t||this.defaultKeyName,JSON.stringify(this.encrypt(e))),!0},o.prototype.load=function(e,t){var r=localStorage.getItem(t||this.defaultKeyName);if(r)try{r=JSON.parse(r)}catch(e){}return this.decrypt(r||[],e)},"undefined"==typeof localStorage&&(delete o.prototype.save,delete o.prototype.load),a.exports=t}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},s("buffer").Buffer)},{"any-promise":232,buffer:48,crypto:57,"crypto-browserify":286,"eth-lib/lib/account":313,"eth-lib/lib/bytes":315,"eth-lib/lib/hash":316,"eth-lib/lib/nat":317,"eth-lib/lib/rlp":318,"scrypt.js":360,underscore:370,uuid:372,"web3-core":218,"web3-core-helpers":200,"web3-core-method":202,"web3-utils":408}],374:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],375:[function(e,t,r){var f=e("underscore"),c=e("web3-core"),s=e("web3-core-method"),h=e("web3-utils"),n=e("web3-core-subscriptions").subscription,d=e("web3-core-helpers").formatters,i=e("web3-core-helpers").errors,a=e("web3-core-promievent"),l=e("web3-eth-abi"),o=function e(t,r,n){var o=this,i=Array.prototype.slice.call(arguments);if(!(this instanceof e))throw new Error('Please use the "new" keyword to instantiate a web3.eth.contract() object!');if(c.packageInit(this,[this.constructor.currentProvider]),this.clearSubscriptions=this._requestManager.clearSubscriptions,!t||!Array.isArray(t))throw new Error("You must provide the json interface of the contract when instantiating a contract object.");this.options={};var s=i[i.length-1];f.isObject(s)&&!f.isArray(s)&&(n=s,this.options=f.extend(this.options,this._getOrSetDefaultOptions(n)),f.isObject(r)&&(r=null)),Object.defineProperty(this.options,"address",{set:function(e){e&&(o._address=h.toChecksumAddress(d.inputAddressFormatter(e)))},get:function(){return o._address},enumerable:!0}),Object.defineProperty(this.options,"jsonInterface",{set:function(e){return o.methods={},o.events={},o._jsonInterface=e.map(function(e){var t,r;if(e.constant="view"===e.stateMutability||"pure"===e.stateMutability||e.constant,e.payable="payable"===e.stateMutability||e.payable,e.name&&(r=h._jsonInterfaceMethodToString(e)),"function"===e.type){if(e.signature=l.encodeFunctionSignature(r),t=o._createTxObject.bind({method:e,parent:o}),o.methods[e.name]){var n=o._createTxObject.bind({method:e,parent:o,nextMethod:o.methods[e.name]});o.methods[e.name]=n}else o.methods[e.name]=t;o.methods[e.signature]=t,o.methods[r]=t}else if("event"===e.type){e.signature=l.encodeEventSignature(r);var i=o._on.bind(o,e.signature);o.events[e.name]&&"bound "!==o.events[e.name].name||(o.events[e.name]=i),o.events[e.signature]=i,o.events[r]=i}return e}),o.events.allEvents=o._on.bind(o,"allevents"),o._jsonInterface},get:function(){return o._jsonInterface},enumerable:!0});var a=this.constructor.defaultAccount,u=this.constructor.defaultBlock||"latest";Object.defineProperty(this,"defaultAccount",{get:function(){return a},set:function(e){return e&&(a=h.toChecksumAddress(d.inputAddressFormatter(e))),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return u},set:function(e){return u=e},enumerable:!0}),this.methods={},this.events={},this._address=null,this._jsonInterface=[],this.options.address=r,this.options.jsonInterface=t};o.setProvider=function(e,t){c.packageInit(this,[e]),this._ethAccounts=t},o.prototype._getCallback=function(e){if(e&&f.isFunction(e[e.length-1]))return e.pop()},o.prototype._checkListener=function(e,t){if(t===e)throw new Error('The event "'+e+"\" is a reserved event name, you can't use it.")},o.prototype._getOrSetDefaultOptions=function(e){var t=e.gasPrice?String(e.gasPrice):null,r=e.from?h.toChecksumAddress(d.inputAddressFormatter(e.from)):null;return e.data=e.data||this.options.data,e.from=r||this.options.from,e.gasPrice=t||this.options.gasPrice,e.gas=e.gas||e.gasLimit||this.options.gas,delete e.gasLimit,e},o.prototype._encodeEventABI=function(e,t){var r=(t=t||{}).filter||{},n={};if(["fromBlock","toBlock"].filter(function(e){return void 0!==t[e]}).forEach(function(e){n[e]=d.inputBlockNumberFormatter(t[e])}),f.isArray(t.topics))n.topics=t.topics;else{if(n.topics=[],e&&!e.anonymous&&"ALLEVENTS"!==e.name&&n.topics.push(e.signature),"ALLEVENTS"!==e.name){var i=e.inputs.filter(function(e){return!0===e.indexed}).map(function(t){var e=r[t.name];return e?f.isArray(e)?e.map(function(e){return l.encodeParameter(t.type,e)}):l.encodeParameter(t.type,e):null});n.topics=n.topics.concat(i)}n.topics.length||delete n.topics}return this.options.address&&(n.address=this.options.address.toLowerCase()),n},o.prototype._decodeEventABI=function(t){var e=this;t.data=t.data||"",t.topics=t.topics||[];var r=d.outputLogFormatter(t);"ALLEVENTS"===e.name&&(e=e.jsonInterface.find(function(e){return e.signature===t.topics[0]})||{anonymous:!0}),e.inputs=e.inputs||[];var n=e.anonymous?t.topics:t.topics.slice(1);return r.returnValues=l.decodeLog(e.inputs,t.data,n),delete r.returnValues.__length__,r.event=e.name,r.signature=e.anonymous||!t.topics[0]?null:t.topics[0],r.raw={data:r.data,topics:r.topics},delete r.data,delete r.topics,r},o.prototype._encodeMethodABI=function(){var t=this._method.signature,r=this.arguments||[],n=!1,e=this._parent.options.jsonInterface.filter(function(e){return"constructor"===t&&e.type===t||(e.signature===t||e.signature===t.replace("0x","")||e.name===t)&&"function"===e.type}).map(function(e){var t=f.isArray(e.inputs)?e.inputs.length:0;if(t!==r.length)throw new Error("The number of arguments is not matching the methods required number. You need to pass "+t+" arguments.");return"function"===e.type&&(n=e.signature),f.isArray(e.inputs)?e.inputs.map(function(e){return e.type}):[]}).map(function(e){return l.encodeParameters(e,r).replace("0x","")})[0]||"";if("constructor"===t){if(!this._deployData)throw new Error("The contract has no contract data option set. This is necessary to append the constructor parameters.");return this._deployData+e}var i=n?n+e:e;if(i)return i;throw new Error("Couldn't find a matching contract method named \""+this._method.name+'".')},o.prototype._decodeMethodReturn=function(e,t){if(!t)return null;t=2<=t.length?t.slice(2):t;var r=l.decodeParameters(e,t);return 1===r.__length__?r[0]:(delete r.__length__,r)},o.prototype.deploy=function(e,t){if((e=e||{}).arguments=e.arguments||[],!(e=this._getOrSetDefaultOptions(e)).data)return h._fireError(new Error('No "data" specified in neither the given options, nor the default options.'),null,null,t);var r=f.find(this.options.jsonInterface,function(e){return"constructor"===e.type})||{};return r.signature="constructor",this._createTxObject.apply({method:r,parent:this,deployData:e.data,_ethAccounts:this.constructor._ethAccounts},e.arguments)},o.prototype._generateEventOptions=function(){var e=Array.prototype.slice.call(arguments),t=this._getCallback(e),r=f.isObject(e[e.length-1])?e.pop():{},n=f.isString(e[0])?e[0]:"allevents";if(!(n="allevents"===n.toLowerCase()?{name:"ALLEVENTS",jsonInterface:this.options.jsonInterface}:this.options.jsonInterface.find(function(e){return"event"===e.type&&(e.name===n||e.signature==="0x"+n.replace("0x",""))})))throw new Error('Event "'+n.name+"\" doesn't exist in this contract.");if(!h.isAddress(this.options.address))throw new Error("This contract object doesn't have address set yet, please set an address first.");return{params:this._encodeEventABI(n,r),event:n,callback:t}},o.prototype.clone=function(){return new this.constructor(this.options.jsonInterface,this.options.address,this.options)},o.prototype.once=function(e,t,n){var r=Array.prototype.slice.call(arguments);if(!(n=this._getCallback(r)))throw new Error("Once requires a callback as the second parameter.");t&&delete t.fromBlock,this._on(e,t,function(e,t,r){r.unsubscribe(),f.isFunction(n)&&n(e,t,r)})},o.prototype._on=function(){var e=this._generateEventOptions.apply(this,arguments);this._checkListener("newListener",e.event.name,e.callback),this._checkListener("removeListener",e.event.name,e.callback);var t=new n({subscription:{params:1,inputFormatter:[d.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event),subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),f.isFunction(this.callback)&&this.callback(null,e,this)}},type:"eth",requestManager:this._requestManager});return t.subscribe("logs",e.params,e.callback||function(){}),t},o.prototype.getPastEvents=function(){var e=this._generateEventOptions.apply(this,arguments),t=new s({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[d.inputLogFormatter],outputFormatter:this._decodeEventABI.bind(e.event)});t.setRequestManager(this._requestManager);var r=t.buildCall();return t=null,r(e.params,e.callback)},o.prototype._createTxObject=function(){var e=Array.prototype.slice.call(arguments),t={};if("function"===this.method.type&&(t.call=this.parent._executeMethod.bind(t,"call"),t.call.request=this.parent._executeMethod.bind(t,"call",!0)),t.send=this.parent._executeMethod.bind(t,"send"),t.send.request=this.parent._executeMethod.bind(t,"send",!0),t.encodeABI=this.parent._encodeMethodABI.bind(t),t.estimateGas=this.parent._executeMethod.bind(t,"estimate"),e&&this.method.inputs&&e.length!==this.method.inputs.length){if(this.nextMethod)return this.nextMethod.apply(null,e);throw i.InvalidNumberOfParams(e.length,this.method.inputs.length,this.method.name)}return t.arguments=e||[],t._method=this.method,t._parent=this.parent,t._ethAccounts=this.parent.constructor._ethAccounts||this._ethAccounts,this.deployData&&(t._deployData=this.deployData),t},o.prototype._processExecuteArguments=function(e,t){var r={};if(r.type=e.shift(),r.callback=this._parent._getCallback(e),"call"===r.type&&!0!==e[e.length-1]&&(f.isString(e[e.length-1])||isFinite(e[e.length-1]))&&(r.defaultBlock=e.pop()),r.options=f.isObject(e[e.length-1])?e.pop():{},r.generateRequest=!0===e[e.length-1]&&e.pop(),r.options=this._parent._getOrSetDefaultOptions(r.options),r.options.data=this.encodeABI(),!this._deployData&&!h.isAddress(this._parent.options.address))throw new Error("This contract object doesn't have address set yet, please set an address first.");return this._deployData||(r.options.to=this._parent.options.address),r.options.data?r:h._fireError(new Error("Couldn't find a matching contract method, or the number of parameters is wrong."),t.eventEmitter,t.reject,r.callback)},o.prototype._executeMethod=function(){var n=this,e=this._parent._processExecuteArguments.call(this,Array.prototype.slice.call(arguments),t),t=a("send"!==e.type),r=n.constructor._ethAccounts||n._ethAccounts;if(e.generateRequest){var i={params:[d.inputCallFormatter.call(this._parent,e.options)],callback:e.callback};return"call"===e.type?(i.params.push(d.inputDefaultBlockNumberFormatter.call(this._parent,e.defaultBlock)),i.method="eth_call",i.format=this._parent._decodeMethodReturn.bind(null,this._method.outputs)):i.method="eth_sendTransaction",i}switch(e.type){case"estimate":return new s({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[d.inputCallFormatter],outputFormatter:h.hexToNumber,requestManager:n._parent._requestManager,accounts:r,defaultAccount:n._parent.defaultAccount,defaultBlock:n._parent.defaultBlock}).createFunction()(e.options,e.callback);case"call":return new s({name:"call",call:"eth_call",params:2,inputFormatter:[d.inputCallFormatter,d.inputDefaultBlockNumberFormatter],outputFormatter:function(e){return n._parent._decodeMethodReturn(n._method.outputs,e)},requestManager:n._parent._requestManager,accounts:r,defaultAccount:n._parent.defaultAccount,defaultBlock:n._parent.defaultBlock}).createFunction()(e.options,e.defaultBlock,e.callback);case"send":if(!h.isAddress(e.options.from))return h._fireError(new Error('No "from" address specified in neither the given options, nor the default options.'),t.eventEmitter,t.reject,e.callback);if(f.isBoolean(this._method.payable)&&!this._method.payable&&e.options.value&&0<e.options.value)return h._fireError(new Error("Can not send value to non-payable contract method or constructor"),t.eventEmitter,t.reject,e.callback);var o={receiptFormatter:function(t){if(f.isArray(t.logs)){var e=f.map(t.logs,function(e){return n._parent._decodeEventABI.call({name:"ALLEVENTS",jsonInterface:n._parent.options.jsonInterface},e)});t.events={};var r=0;e.forEach(function(e){e.event?t.events[e.event]?Array.isArray(t.events[e.event])?t.events[e.event].push(e):t.events[e.event]=[t.events[e.event],e]:t.events[e.event]=e:(t.events[r]=e,r++)}),delete t.logs}return t},contractDeployFormatter:function(e){var t=n._parent.clone();return t.options.address=e.contractAddress,t}};return new s({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[d.inputTransactionFormatter],requestManager:n._parent._requestManager,accounts:n.constructor._ethAccounts||n._ethAccounts,defaultAccount:n._parent.defaultAccount,defaultBlock:n._parent.defaultBlock,extraFormatters:o}).createFunction()(e.options,e.callback)}},t.exports=o},{underscore:374,"web3-core":218,"web3-core-helpers":200,"web3-core-method":202,"web3-core-promievent":207,"web3-core-subscriptions":215,"web3-eth-abi":222,"web3-utils":408}],376:[function(e,t,r){arguments[4][219][0].apply(r,arguments)},{dup:219}],377:[function(e,t,r){var n=e("web3-utils"),i=e("bn.js"),o=function(e){var r="A".charCodeAt(0),n="Z".charCodeAt(0);return(e=(e=e.toUpperCase()).substr(4)+e.substr(0,4)).split("").map(function(e){var t=e.charCodeAt(0);return r<=t&&t<=n?t-r+10:e}).join("")},s=function(e){for(var t,r=e;2<r.length;)t=r.slice(0,9),r=parseInt(t,10)%97+r.slice(t.length);return parseInt(r,10)%97},a=function(e){this._iban=e};a.toAddress=function(e){if(!(e=new a(e)).isDirect())throw new Error("IBAN is indirect and can't be converted");return e.toAddress()},a.toIban=function(e){return a.fromAddress(e).toString()},a.fromAddress=function(e){if(!n.isAddress(e))throw new Error("Provided address is not a valid address: "+e);e=e.replace("0x","").replace("0X","");var t=function(e,t){for(var r=e;r.length<2*t;)r="0"+r;return r}(new i(e,16).toString(36),15);return a.fromBban(t.toUpperCase())},a.fromBban=function(e){var t=("0"+(98-s(o("XE00"+e)))).slice(-2);return new a("XE"+t+e)},a.createIndirect=function(e){return a.fromBban("ETH"+e.institution+e.identifier)},a.isValid=function(e){return new a(e).isValid()},a.prototype.isValid=function(){return/^XE[0-9]{2}(ETH[0-9A-Z]{13}|[0-9A-Z]{30,31})$/.test(this._iban)&&1===s(o(this._iban))},a.prototype.isDirect=function(){return 34===this._iban.length||35===this._iban.length},a.prototype.isIndirect=function(){return 20===this._iban.length},a.prototype.checksum=function(){return this._iban.substr(2,2)},a.prototype.institution=function(){return this.isIndirect()?this._iban.substr(7,4):""},a.prototype.client=function(){return this.isIndirect()?this._iban.substr(11):""},a.prototype.toAddress=function(){if(this.isDirect()){var e=this._iban.substr(4),t=new i(e,36);return n.toChecksumAddress(t.toString(16,20))}return""},a.prototype.toString=function(){return this._iban},t.exports=a},{"bn.js":376,"web3-utils":408}],378:[function(e,t,r){var o=e("web3-core"),s=e("web3-core-method"),a=e("web3-utils"),u=e("web3-net"),f=e("web3-core-helpers").formatters,n=function(){var t=this;o.packageInit(this,arguments),this.net=new u(this.currentProvider);var r=null,n="latest";Object.defineProperty(this,"defaultAccount",{get:function(){return r},set:function(e){return e&&(r=a.toChecksumAddress(f.inputAddressFormatter(e))),i.forEach(function(e){e.defaultAccount=r}),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return n},set:function(e){return n=e,i.forEach(function(e){e.defaultBlock=n}),e},enumerable:!0});var i=[new s({name:"getAccounts",call:"personal_listAccounts",params:0,outputFormatter:a.toChecksumAddress}),new s({name:"newAccount",call:"personal_newAccount",params:1,inputFormatter:[null],outputFormatter:a.toChecksumAddress}),new s({name:"unlockAccount",call:"personal_unlockAccount",params:3,inputFormatter:[f.inputAddressFormatter,null,null]}),new s({name:"lockAccount",call:"personal_lockAccount",params:1,inputFormatter:[f.inputAddressFormatter]}),new s({name:"importRawKey",call:"personal_importRawKey",params:2}),new s({name:"sendTransaction",call:"personal_sendTransaction",params:2,inputFormatter:[f.inputTransactionFormatter,null]}),new s({name:"signTransaction",call:"personal_signTransaction",params:2,inputFormatter:[f.inputTransactionFormatter,null]}),new s({name:"sign",call:"personal_sign",params:3,inputFormatter:[f.inputSignFormatter,f.inputAddressFormatter,null]}),new s({name:"ecRecover",call:"personal_ecRecover",params:2,inputFormatter:[f.inputSignFormatter,null]})];i.forEach(function(e){e.attachToObject(t),e.setRequestManager(t._requestManager),e.defaultBlock=t.defaultBlock,e.defaultAccount=t.defaultAccount})};o.addProviders(n),t.exports=n},{"web3-core":218,"web3-core-helpers":200,"web3-core-method":202,"web3-net":382,"web3-utils":408}],379:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],380:[function(e,t,r){var i=e("underscore");t.exports=function(r){var n,t=this;return this.net.getId().then(function(e){return n=e,t.getBlock(0)}).then(function(e){var t="private";return"0xd4e56740f876aef8c010b86a40d5f56745a118d0906a34e69aec8c0db1cb8fa3"===e.hash&&1===n&&(t="main"),"0cd786a2425d16f152c658316c423e6ce1181e15c3295826d7c9904cba9ce303"===e.hash&&2===n&&(t="morden"),"0x41941023680923e0fe4d74a34bdac8141f2540e3ae90623718e47d66d1ca4a2d"===e.hash&&3===n&&(t="ropsten"),"0x6341fd3daf94b748c72ced5a5b26028f2474f5f00d824504e4fa37a75767e177"===e.hash&&4===n&&(t="rinkeby"),"0xa3c565fc15c7478862d50ccd6561e3c06b24cc509bf388941c25ea985ce32cb9"===e.hash&&42===n&&(t="kovan"),i.isFunction(r)&&r(null,t),t}).catch(function(e){if(!i.isFunction(r))throw e;r(e)})}},{underscore:379}],381:[function(e,t,r){var a=e("underscore"),u=e("web3-core"),n=e("web3-core-helpers"),f=e("web3-core-subscriptions").subscriptions,c=e("web3-core-method"),h=e("web3-utils"),d=e("web3-net"),l=e("web3-eth-personal"),p=e("web3-eth-contract"),b=e("web3-eth-iban"),m=e("web3-eth-accounts"),y=e("web3-eth-abi"),v=e("./getNetworkType.js"),g=n.formatters,w=function(e){return a.isString(e[0])&&0===e[0].indexOf("0x")?"eth_getBlockByHash":"eth_getBlockByNumber"},_=function(e){return a.isString(e[0])&&0===e[0].indexOf("0x")?"eth_getTransactionByBlockHashAndIndex":"eth_getTransactionByBlockNumberAndIndex"},M=function(e){return a.isString(e[0])&&0===e[0].indexOf("0x")?"eth_getUncleByBlockHashAndIndex":"eth_getUncleByBlockNumberAndIndex"},x=function(e){return a.isString(e[0])&&0===e[0].indexOf("0x")?"eth_getBlockTransactionCountByHash":"eth_getBlockTransactionCountByNumber"},k=function(e){return a.isString(e[0])&&0===e[0].indexOf("0x")?"eth_getUncleCountByBlockHash":"eth_getUncleCountByBlockNumber"},i=function(){var t=this;u.packageInit(this,arguments);var e=this.setProvider;this.setProvider=function(){e.apply(t,arguments),t.net.setProvider.apply(t,arguments),t.personal.setProvider.apply(t,arguments),t.accounts.setProvider.apply(t,arguments),t.Contract.setProvider(t.currentProvider,t.accounts)};var r=null,n="latest";Object.defineProperty(this,"defaultAccount",{get:function(){return r},set:function(e){return e&&(r=h.toChecksumAddress(g.inputAddressFormatter(e))),t.Contract.defaultAccount=r,t.personal.defaultAccount=r,s.forEach(function(e){e.defaultAccount=r}),e},enumerable:!0}),Object.defineProperty(this,"defaultBlock",{get:function(){return n},set:function(e){return n=e,t.Contract.defaultBlock=n,t.personal.defaultBlock=n,s.forEach(function(e){e.defaultBlock=n}),e},enumerable:!0}),this.clearSubscriptions=t._requestManager.clearSubscriptions,this.net=new d(this.currentProvider),this.net.getNetworkType=v.bind(this),this.accounts=new m(this.currentProvider),this.personal=new l(this.currentProvider),this.personal.defaultAccount=this.defaultAccount;var i=this,o=function(){p.apply(this,arguments);var e=this,t=i.setProvider;i.setProvider=function(){t.apply(i,arguments),u.packageInit(e,[i.currentProvider])}};o.setProvider=function(){p.setProvider.apply(this,arguments)},(o.prototype=Object.create(p.prototype)).constructor=o,this.Contract=o,this.Contract.defaultAccount=this.defaultAccount,this.Contract.defaultBlock=this.defaultBlock,this.Contract.setProvider(this.currentProvider,this.accounts),this.Iban=b,this.abi=y;var s=[new c({name:"getNodeInfo",call:"web3_clientVersion"}),new c({name:"getProtocolVersion",call:"eth_protocolVersion",params:0}),new c({name:"getCoinbase",call:"eth_coinbase",params:0}),new c({name:"isMining",call:"eth_mining",params:0}),new c({name:"getHashrate",call:"eth_hashrate",params:0,outputFormatter:h.hexToNumber}),new c({name:"isSyncing",call:"eth_syncing",params:0,outputFormatter:g.outputSyncingFormatter}),new c({name:"getGasPrice",call:"eth_gasPrice",params:0,outputFormatter:g.outputBigNumberFormatter}),new c({name:"getAccounts",call:"eth_accounts",params:0,outputFormatter:h.toChecksumAddress}),new c({name:"getBlockNumber",call:"eth_blockNumber",params:0,outputFormatter:h.hexToNumber}),new c({name:"getBalance",call:"eth_getBalance",params:2,inputFormatter:[g.inputAddressFormatter,g.inputDefaultBlockNumberFormatter],outputFormatter:g.outputBigNumberFormatter}),new c({name:"getStorageAt",call:"eth_getStorageAt",params:3,inputFormatter:[g.inputAddressFormatter,h.numberToHex,g.inputDefaultBlockNumberFormatter]}),new c({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[g.inputAddressFormatter,g.inputDefaultBlockNumberFormatter]}),new c({name:"getBlock",call:w,params:2,inputFormatter:[g.inputBlockNumberFormatter,function(e){return!!e}],outputFormatter:g.outputBlockFormatter}),new c({name:"getUncle",call:M,params:2,inputFormatter:[g.inputBlockNumberFormatter,h.numberToHex],outputFormatter:g.outputBlockFormatter}),new c({name:"getBlockTransactionCount",call:x,params:1,inputFormatter:[g.inputBlockNumberFormatter],outputFormatter:h.hexToNumber}),new c({name:"getBlockUncleCount",call:k,params:1,inputFormatter:[g.inputBlockNumberFormatter],outputFormatter:h.hexToNumber}),new c({name:"getTransaction",call:"eth_getTransactionByHash",params:1,inputFormatter:[null],outputFormatter:g.outputTransactionFormatter}),new c({name:"getTransactionFromBlock",call:_,params:2,inputFormatter:[g.inputBlockNumberFormatter,h.numberToHex],outputFormatter:g.outputTransactionFormatter}),new c({name:"getTransactionReceipt",call:"eth_getTransactionReceipt",params:1,inputFormatter:[null],outputFormatter:g.outputTransactionReceiptFormatter}),new c({name:"getTransactionCount",call:"eth_getTransactionCount",params:2,inputFormatter:[g.inputAddressFormatter,g.inputDefaultBlockNumberFormatter],outputFormatter:h.hexToNumber}),new c({name:"sendSignedTransaction",call:"eth_sendRawTransaction",params:1,inputFormatter:[null]}),new c({name:"signTransaction",call:"eth_signTransaction",params:1,inputFormatter:[g.inputTransactionFormatter]}),new c({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[g.inputTransactionFormatter]}),new c({name:"sign",call:"eth_sign",params:2,inputFormatter:[g.inputSignFormatter,g.inputAddressFormatter],transformPayload:function(e){return e.params.reverse(),e}}),new c({name:"call",call:"eth_call",params:2,inputFormatter:[g.inputCallFormatter,g.inputDefaultBlockNumberFormatter]}),new c({name:"estimateGas",call:"eth_estimateGas",params:1,inputFormatter:[g.inputCallFormatter],outputFormatter:h.hexToNumber}),new c({name:"getCompilers",call:"eth_getCompilers",params:0}),new c({name:"compile.solidity",call:"eth_compileSolidity",params:1}),new c({name:"compile.lll",call:"eth_compileLLL",params:1}),new c({name:"compile.serpent",call:"eth_compileSerpent",params:1}),new c({name:"submitWork",call:"eth_submitWork",params:3}),new c({name:"getWork",call:"eth_getWork",params:0}),new c({name:"getPastLogs",call:"eth_getLogs",params:1,inputFormatter:[g.inputLogFormatter],outputFormatter:g.outputLogFormatter}),new f({name:"subscribe",type:"eth",subscriptions:{newBlockHeaders:{subscriptionName:"newHeads",params:0,outputFormatter:g.outputBlockFormatter},pendingTransactions:{subscriptionName:"newPendingTransactions",params:0},logs:{params:1,inputFormatter:[g.inputLogFormatter],outputFormatter:g.outputLogFormatter,subscriptionHandler:function(e){e.removed?this.emit("changed",e):this.emit("data",e),a.isFunction(this.callback)&&this.callback(null,e,this)}},syncing:{params:0,outputFormatter:g.outputSyncingFormatter,subscriptionHandler:function(e){var t=this;!0!==this._isSyncing?(this._isSyncing=!0,this.emit("changed",t._isSyncing),a.isFunction(this.callback)&&this.callback(null,t._isSyncing,this),setTimeout(function(){t.emit("data",e),a.isFunction(t.callback)&&t.callback(null,e,t)},0)):(this.emit("data",e),a.isFunction(t.callback)&&this.callback(null,e,this),clearTimeout(this._isSyncingTimeout),this._isSyncingTimeout=setTimeout(function(){e.currentBlock>e.highestBlock-200&&(t._isSyncing=!1,t.emit("changed",t._isSyncing),a.isFunction(t.callback)&&t.callback(null,t._isSyncing,t))},500))}}}})];s.forEach(function(e){e.attachToObject(t),e.setRequestManager(t._requestManager,t.accounts),e.defaultBlock=t.defaultBlock,e.defaultAccount=t.defaultAccount})};u.addProviders(i),t.exports=i},{"./getNetworkType.js":380,underscore:379,"web3-core":218,"web3-core-helpers":200,"web3-core-method":202,"web3-core-subscriptions":215,"web3-eth-abi":222,"web3-eth-accounts":373,"web3-eth-contract":375,"web3-eth-iban":377,"web3-eth-personal":378,"web3-net":382,"web3-utils":408}],382:[function(e,t,r){var n=e("web3-core"),i=e("web3-core-method"),o=e("web3-utils"),s=function(){var t=this;n.packageInit(this,arguments),[new i({name:"getId",call:"net_version",params:0,outputFormatter:o.hexToNumber}),new i({name:"isListening",call:"net_listening",params:0}),new i({name:"getPeerCount",call:"net_peerCount",params:0,outputFormatter:o.hexToNumber})].forEach(function(e){e.attachToObject(t),e.setRequestManager(t._requestManager)})};n.addProviders(s),t.exports=s},{"web3-core":218,"web3-core-method":202,"web3-utils":408}],383:[function(e,t,r){!function(){function i(e,t,r,n){return this instanceof i?(this.domain=e||void 0,this.path=t||"/",this.secure=!!r,this.script=!!n,this):new i(e,t,r,n)}function u(e,t,r){return e instanceof u?e:this instanceof u?(this.name=null,this.value=null,this.expiration_date=1/0,this.path=String(r||"/"),this.explicit_path=!1,this.domain=t||null,this.explicit_domain=!1,this.secure=!1,this.noscript=!1,e&&this.parse(e,t,r),this):new u(e,t,r)}i.All=Object.freeze(Object.create(null)),r.CookieAccessInfo=i,(r.Cookie=u).prototype.toString=function(){var e=[this.name+"="+this.value];return this.expiration_date!==1/0&&e.push("expires="+new Date(this.expiration_date).toGMTString()),this.domain&&e.push("domain="+this.domain),this.path&&e.push("path="+this.path),this.secure&&e.push("secure"),this.noscript&&e.push("httponly"),e.join("; ")},u.prototype.toValueString=function(){return this.name+"="+this.value};var s=/[:](?=\s*[a-zA-Z0-9_\-]+\s*[=])/g;function e(){var o,s;return this instanceof e?(o=Object.create(null),this.setCookie=function(e,t,r){var n,i;if(n=(e=new u(e,t,r)).expiration_date<=Date.now(),void 0!==o[e.name]){for(s=o[e.name],i=0;i<s.length;i+=1)if(s[i].collidesWith(e))return n?(s.splice(i,1),0===s.length&&delete o[e.name],!1):s[i]=e;return!n&&(s.push(e),e)}return!n&&(o[e.name]=[e],o[e.name])},this.getCookie=function(e,t){var r,n;if(s=o[e])for(n=0;n<s.length;n+=1)if((r=s[n]).expiration_date<=Date.now())0===s.length&&delete o[r.name];else if(r.matches(t))return r},this.getCookies=function(e){var t,r,n=[];for(t in o)(r=this.getCookie(t,e))&&n.push(r);return n.toString=function(){return n.join(":")},n.toValueString=function(){return n.map(function(e){return e.toValueString()}).join(";")},n},this):new e}u.prototype.parse=function(e,t,r){if(this instanceof u){var n,i=e.split(";").filter(function(e){return!!e}),o=i[0].match(/([^=]+)=([\s\S]*)/);if(!o)return void console.warn("Invalid cookie header encountered. Header: '"+e+"'");var s=o[1],a=o[2];if("string"!=typeof s||0===s.length||"string"!=typeof a)return void console.warn("Unable to extract values from cookie header. Cookie: '"+e+"'");for(this.name=s,this.value=a,n=1;n<i.length;n+=1)switch(s=(o=i[n].match(/([^=]+)(?:=([\s\S]*))?/))[1].trim().toLowerCase(),a=o[2],s){case"httponly":this.noscript=!0;break;case"expires":this.expiration_date=a?Number(Date.parse(a)):1/0;break;case"path":this.path=a?a.trim():"",this.explicit_path=!0;break;case"domain":this.domain=a?a.trim():"",this.explicit_domain=!!this.domain;break;case"secure":this.secure=!0}return this.explicit_path||(this.path=r||"/"),this.explicit_domain||(this.domain=t),this}return(new u).parse(e,t,r)},u.prototype.matches=function(e){return e===i.All||!(this.noscript&&e.script||this.secure&&!e.secure||!this.collidesWith(e))},u.prototype.collidesWith=function(e){if(this.path&&!e.path||this.domain&&!e.domain)return!1;if(this.path&&0!==e.path.indexOf(this.path))return!1;if(this.explicit_path&&0!==e.path.indexOf(this.path))return!1;var t=e.domain&&e.domain.replace(/^[\.]/,""),r=this.domain&&this.domain.replace(/^[\.]/,"");if(r===t)return!0;if(r){if(!this.explicit_domain)return!1;var n=t.indexOf(r);return-1!==n&&n===t.length-r.length}return!0},(r.CookieJar=e).prototype.setCookies=function(e,t,r){var n,i,o=[];for(e=(e=Array.isArray(e)?e:e.split(s)).map(function(e){return new u(e,t,r)}),n=0;n<e.length;n+=1)i=e[n],this.setCookie(i,t,r)&&o.push(i);return o}}()},{}],384:[function(e,t,r){var n,i=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(r,"__esModule",{value:!0});var o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t}(Error);r.SecurityError=o;var s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t}(Error);r.InvalidStateError=s;var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t}(Error);r.NetworkError=a;var u=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t}(Error);r.SyntaxError=u},{}],385:[function(e,t,r){Object.defineProperty(r,"__esModule",{value:!0}),function(e){for(var t in e)r.hasOwnProperty(t)||(r[t]=e[t])}(e("./xml-http-request"));var n=e("./xml-http-request-event-target");r.XMLHttpRequestEventTarget=n.XMLHttpRequestEventTarget},{"./xml-http-request":389,"./xml-http-request-event-target":387}],386:[function(e,t,r){Object.defineProperty(r,"__esModule",{value:!0});var n=function(e){this.type=e,this.bubbles=!1,this.cancelable=!1,this.loaded=0,this.lengthComputable=!1,this.total=0};r.ProgressEvent=n},{}],387:[function(e,t,r){Object.defineProperty(r,"__esModule",{value:!0});var n=function(){function e(){this.listeners={}}return e.prototype.addEventListener=function(e,t){e=e.toLowerCase(),this.listeners[e]=this.listeners[e]||[],this.listeners[e].push(t.handleEvent||t)},e.prototype.removeEventListener=function(e,t){if(e=e.toLowerCase(),this.listeners[e]){var r=this.listeners[e].indexOf(t.handleEvent||t);r<0||this.listeners[e].splice(r,1)}},e.prototype.dispatchEvent=function(e){var t=e.type.toLowerCase();if((e.target=this).listeners[t])for(var r=0,n=this.listeners[t];r<n.length;r++){n[r].call(this,e)}var i=this["on"+t];return i&&i.call(this,e),!0},e}();r.XMLHttpRequestEventTarget=n},{}],388:[function(t,e,i){(function(o){var n,r=this&&this.__extends||(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])},function(e,t){function r(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)});Object.defineProperty(i,"__esModule",{value:!0});var e=function(t){function e(){var e=t.call(this)||this;return e._contentType=null,e._body=null,e._reset(),e}return r(e,t),e.prototype._reset=function(){this._contentType=null,this._body=null},e.prototype._setData=function(e){if(null!=e)if("string"==typeof e)0!==e.length&&(this._contentType="text/plain;charset=UTF-8"),this._body=new o(e,"utf-8");else if(o.isBuffer(e))this._body=e;else if(e instanceof ArrayBuffer){for(var t=new o(e.byteLength),r=new Uint8Array(e),n=0;n<e.byteLength;n++)t[n]=r[n];this._body=t}else{if(!(e.buffer&&e.buffer instanceof ArrayBuffer))throw new Error("Unsupported send() data "+e);t=new o(e.byteLength);var i=e.byteOffset;for(r=new Uint8Array(e.buffer),n=0;n<e.byteLength;n++)t[n]=r[n+i];this._body=t}},e.prototype._finalizeHeaders=function(e,t){this._contentType&&!t["content-type"]&&(e["Content-Type"]=this._contentType),this._body&&(e["Content-Length"]=this._body.length.toString())},e.prototype._startUpload=function(e){this._body&&e.write(this._body),e.end()},e}(t("./xml-http-request-event-target").XMLHttpRequestEventTarget);i.XMLHttpRequestUpload=e}).call(this,t("buffer").Buffer)},{"./xml-http-request-event-target":387,buffer:48}],389:[function(b,e,m){(function(n,i){var o,e=this&&this.__extends||(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])},function(e,t){function r(){this.constructor=e}o(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),t=this&&this.__assign||Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e};Object.defineProperty(m,"__esModule",{value:!0});var a=b("http"),u=b("https"),f=b("os"),c=b("url"),h=b("./progress-event"),d=b("./errors"),r=b("./xml-http-request-event-target"),l=b("./xml-http-request-upload"),p=b("cookiejar"),s=function(r){function s(e){void 0===e&&(e={});var t=r.call(this)||this;return t.UNSENT=s.UNSENT,t.OPENED=s.OPENED,t.HEADERS_RECEIVED=s.HEADERS_RECEIVED,t.LOADING=s.LOADING,t.DONE=s.DONE,t.onreadystatechange=null,t.readyState=s.UNSENT,t.response=null,t.responseText="",t.responseType="",t.status=0,t.statusText="",t.timeout=0,t.upload=new l.XMLHttpRequestUpload,t.responseUrl="",t.withCredentials=!1,t._method=null,t._url=null,t._sync=!1,t._headers={},t._loweredHeaders={},t._mimeOverride=null,t._request=null,t._response=null,t._responseParts=null,t._responseHeaders=null,t._aborting=null,t._error=null,t._loadedBytes=0,t._totalBytes=0,t._lengthComputable=!1,t._restrictedMethods={CONNECT:!0,TRACE:!0,TRACK:!0},t._restrictedHeaders={"accept-charset":!0,"accept-encoding":!0,"access-control-request-headers":!0,"access-control-request-method":!0,connection:!0,"content-length":!0,cookie:!0,cookie2:!0,date:!0,dnt:!0,expect:!0,host:!0,"keep-alive":!0,origin:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,via:!0},t._privateHeaders={"set-cookie":!0,"set-cookie2":!0},t._userAgent="Mozilla/5.0 ("+f.type()+" "+f.arch()+") node.js/"+n.versions.node+" v8/"+n.versions.v8,t._anonymous=e.anon||!1,t}return e(s,r),s.prototype.open=function(e,t,r,n,i){if(void 0===r&&(r=!0),e=e.toUpperCase(),this._restrictedMethods[e])throw new s.SecurityError("HTTP method "+e+" is not allowed in XHR");var o=this._parseUrl(t,n,i);this.readyState===s.HEADERS_RECEIVED||this.readyState,this._method=e,this._url=o,this._sync=!r,this._headers={},this._loweredHeaders={},this._mimeOverride=null,this._setReadyState(s.OPENED),this._request=null,this._response=null,this.status=0,this.statusText="",this._responseParts=[],this._responseHeaders=null,this._loadedBytes=0,this._totalBytes=0,this._lengthComputable=!1},s.prototype.setRequestHeader=function(e,t){if(this.readyState!==s.OPENED)throw new s.InvalidStateError("XHR readyState must be OPENED");var r=e.toLowerCase();this._restrictedHeaders[r]||/^sec-/.test(r)||/^proxy-/.test(r)?console.warn('Refused to set unsafe header "'+e+'"'):(t=t.toString(),null!=this._loweredHeaders[r]?(e=this._loweredHeaders[r],this._headers[e]=this._headers[e]+", "+t):(this._loweredHeaders[r]=e,this._headers[e]=t))},s.prototype.send=function(e){if(this.readyState!==s.OPENED)throw new s.InvalidStateError("XHR readyState must be OPENED");if(this._request)throw new s.InvalidStateError("send() already called");switch(this._url.protocol){case"file:":return this._sendFile(e);case"http:":case"https:":return this._sendHttp(e);default:throw new s.NetworkError("Unsupported protocol "+this._url.protocol)}},s.prototype.abort=function(){null!=this._request&&(this._request.abort(),this._setError(),this._dispatchProgress("abort"),this._dispatchProgress("loadend"))},s.prototype.getResponseHeader=function(e){if(null==this._responseHeaders||null==e)return null;var t=e.toLowerCase();return this._responseHeaders.hasOwnProperty(t)?this._responseHeaders[e.toLowerCase()]:null},s.prototype.getAllResponseHeaders=function(){var t=this;return null==this._responseHeaders?"":Object.keys(this._responseHeaders).map(function(e){return e+": "+t._responseHeaders[e]}).join("\r\n")},s.prototype.overrideMimeType=function(e){if(this.readyState===s.LOADING||this.readyState===s.DONE)throw new s.InvalidStateError("overrideMimeType() not allowed in LOADING or DONE");this._mimeOverride=e.toLowerCase()},s.prototype.nodejsSet=function(e){if(this.nodejsHttpAgent=e.httpAgent||this.nodejsHttpAgent,this.nodejsHttpsAgent=e.httpsAgent||this.nodejsHttpsAgent,e.hasOwnProperty("baseUrl")){if(null!=e.baseUrl)if(!c.parse(e.baseUrl,!1,!0).protocol)throw new s.SyntaxError("baseUrl must be an absolute URL");this.nodejsBaseUrl=e.baseUrl}},s.nodejsSet=function(e){s.prototype.nodejsSet(e)},s.prototype._setReadyState=function(e){this.readyState=e,this.dispatchEvent(new h.ProgressEvent("readystatechange"))},s.prototype._sendFile=function(e){throw new Error("Protocol file: not implemented")},s.prototype._sendHttp=function(e){if(this._sync)throw new Error("Synchronous XHR processing not implemented");!e||"GET"!==this._method&&"HEAD"!==this._method?e=e||"":(console.warn("Discarding entity body for "+this._method+" requests"),e=null),this.upload._setData(e),this._finalizeHeaders(),this._sendHxxpRequest()},s.prototype._sendHxxpRequest=function(){var t=this;if(this.withCredentials){var e=s.cookieJar.getCookies(p.CookieAccessInfo(this._url.hostname,this._url.pathname,"https:"===this._url.protocol)).toValueString();this._headers.cookie=this._headers.cookie2=e}var r="http:"===this._url.protocol?[a,this.nodejsHttpAgent]:[u,this.nodejsHttpsAgent],n=r[0],i=r[1],o=n.request.bind(n)({hostname:this._url.hostname,port:+this._url.port,path:this._url.path,auth:this._url.auth,method:this._method,headers:this._headers,agent:i});this._request=o,this.timeout&&o.setTimeout(this.timeout,function(){return t._onHttpTimeout(o)}),o.on("response",function(e){return t._onHttpResponse(o,e)}),o.on("error",function(e){return t._onHttpRequestError(o,e)}),this.upload._startUpload(o),this._request===o&&this._dispatchProgress("loadstart")},s.prototype._finalizeHeaders=function(){this._headers=t({},this._headers,{Connection:"keep-alive",Host:this._url.host,"User-Agent":this._userAgent},this._anonymous?{Referer:"about:blank"}:{}),this.upload._finalizeHeaders(this._headers,this._loweredHeaders)},s.prototype._onHttpResponse=function(e,t){var r=this;if(this._request===e){if(this.withCredentials&&(t.headers["set-cookie"]||t.headers["set-cookie2"])&&s.cookieJar.setCookies(t.headers["set-cookie"]||t.headers["set-cookie2"]),0<=[301,302,303,307,308].indexOf(t.statusCode))return this._url=this._parseUrl(t.headers.location),this._method="GET",this._loweredHeaders["content-type"]&&(delete this._headers[this._loweredHeaders["content-type"]],delete this._loweredHeaders["content-type"]),null!=this._headers["Content-Type"]&&delete this._headers["Content-Type"],delete this._headers["Content-Length"],this.upload._reset(),this._finalizeHeaders(),void this._sendHxxpRequest();this._response=t,this._response.on("data",function(e){return r._onHttpResponseData(t,e)}),this._response.on("end",function(){return r._onHttpResponseEnd(t)}),this._response.on("close",function(){return r._onHttpResponseClose(t)}),this.responseUrl=this._url.href.split("#")[0],this.status=t.statusCode,this.statusText=a.STATUS_CODES[this.status],this._parseResponseHeaders(t);var n=this._responseHeaders["content-length"]||"";this._totalBytes=+n,this._lengthComputable=!!n,this._setReadyState(s.HEADERS_RECEIVED)}},s.prototype._onHttpResponseData=function(e,t){this._response===e&&(this._responseParts.push(new i(t)),this._loadedBytes+=t.length,this.readyState!==s.LOADING&&this._setReadyState(s.LOADING),this._dispatchProgress("progress"))},s.prototype._onHttpResponseEnd=function(e){this._response===e&&(this._parseResponse(),this._request=null,this._response=null,this._setReadyState(s.DONE),this._dispatchProgress("load"),this._dispatchProgress("loadend"))},s.prototype._onHttpResponseClose=function(e){if(this._response===e){var t=this._request;this._setError(),t.abort(),this._setReadyState(s.DONE),this._dispatchProgress("error"),this._dispatchProgress("loadend")}},s.prototype._onHttpTimeout=function(e){this._request===e&&(this._setError(),e.abort(),this._setReadyState(s.DONE),this._dispatchProgress("timeout"),this._dispatchProgress("loadend"))},s.prototype._onHttpRequestError=function(e,t){this._request===e&&(this._setError(),e.abort(),this._setReadyState(s.DONE),this._dispatchProgress("error"),this._dispatchProgress("loadend"))},s.prototype._dispatchProgress=function(e){var t=new s.ProgressEvent(e);t.lengthComputable=this._lengthComputable,t.loaded=this._loadedBytes,t.total=this._totalBytes,this.dispatchEvent(t)},s.prototype._setError=function(){this._request=null,this._response=null,this._responseHeaders=null,this._responseParts=null},s.prototype._parseUrl=function(e,t,r){var n=null==this.nodejsBaseUrl?e:c.resolve(this.nodejsBaseUrl,e),i=c.parse(n,!1,!0);i.hash=null;var o=(i.auth||"").split(":"),s=o[0],a=o[1];return(s||a||t||r)&&(i.auth=(t||s||"")+":"+(r||a||"")),i},s.prototype._parseResponseHeaders=function(e){for(var t in this._responseHeaders={},e.headers){var r=t.toLowerCase();this._privateHeaders[r]||(this._responseHeaders[r]=e.headers[t])}null!=this._mimeOverride&&(this._responseHeaders["content-type"]=this._mimeOverride)},s.prototype._parseResponse=function(){var t=i.concat(this._responseParts);switch(this._responseParts=null,this.responseType){case"json":this.responseText=null;try{this.response=JSON.parse(t.toString("utf-8"))}catch(e){this.response=null}return;case"buffer":return this.responseText=null,void(this.response=t);case"arraybuffer":this.responseText=null;for(var e=new ArrayBuffer(t.length),r=new Uint8Array(e),n=0;n<t.length;n++)r[n]=t[n];return void(this.response=e);case"text":default:try{this.responseText=t.toString(this._parseResponseEncoding())}catch(e){this.responseText=t.toString("binary")}this.response=this.responseText}},s.prototype._parseResponseEncoding=function(){return/;\s*charset=(.*)$/.exec(this._responseHeaders["content-type"]||"")[1]||"utf-8"},s.ProgressEvent=h.ProgressEvent,s.InvalidStateError=d.InvalidStateError,s.NetworkError=d.NetworkError,s.SecurityError=d.SecurityError,s.SyntaxError=d.SyntaxError,s.XMLHttpRequestUpload=l.XMLHttpRequestUpload,s.UNSENT=0,s.OPENED=1,s.HEADERS_RECEIVED=2,s.LOADING=3,s.DONE=4,s.cookieJar=p.CookieJar(),s}(r.XMLHttpRequestEventTarget);(m.XMLHttpRequest=s).prototype.nodejsHttpAgent=a.globalAgent,s.prototype.nodejsHttpsAgent=u.globalAgent,s.prototype.nodejsBaseUrl=null}).call(this,b("_process"),b("buffer").Buffer)},{"./errors":384,"./progress-event":386,"./xml-http-request-event-target":387,"./xml-http-request-upload":388,_process:122,buffer:48,cookiejar:383,http:159,https:100,os:110,url:166}],390:[function(e,t,r){var o=e("web3-core-helpers").errors,n=e("xhr2-cookies").XMLHttpRequest,i=function(e,t){t=t||{},this.host=e||"http://localhost:8545",this.timeout=t.timeout||0,this.headers=t.headers,this.connected=!1};i.prototype._prepareRequest=function(){var t=new n;return t.open("POST",this.host,!0),t.setRequestHeader("Content-Type","application/json"),t.timeout=this.timeout&&1!==this.timeout?this.timeout:0,t.withCredentials=!0,this.headers&&this.headers.forEach(function(e){t.setRequestHeader(e.name,e.value)}),t},i.prototype.send=function(e,r){var n=this,i=this._prepareRequest();i.onreadystatechange=function(){if(4===i.readyState&&1!==i.timeout){var e=i.responseText,t=null;try{e=JSON.parse(e)}catch(e){t=o.InvalidResponse(i.responseText)}n.connected=!0,r(t,e)}},i.ontimeout=function(){n.connected=!1,r(o.ConnectionTimeout(this.timeout))};try{i.send(JSON.stringify(e))}catch(e){this.connected=!1,r(o.InvalidConnection(this.host))}},t.exports=i},{"web3-core-helpers":200,"xhr2-cookies":385}],391:[function(e,ve,ge){!function(p,r,h,G,u,J){var b=l(function(r,n){var i=n.length;return l(function(e){for(var t=0;t<e.length;t++)n[i+t]=e[t];return n.length=i+e.length,r.apply(this,n)})});l(function(e){var t=I(e);function r(e,t){return[d(e,t)]}return l(function(e){return T(r,e,t)[0]})});function m(e,t){return function(){return e.call(this,t.apply(this,arguments))}}function n(t){return function(e){return e[t]}}var y=l(function(n){return l(function(e){for(var t,r=0;r<M(n);r++)if(t=d(e,n[r]))return t})});function d(e,t){return t.apply(J,e)}function l(t){var r=t.length-1,n=h.prototype.slice;if(0==r)return function(){return t.call(this,n.call(arguments))};if(1==r)return function(){return t.call(this,arguments[0],n.call(arguments,1))};var i=h(t.length);return function(){for(var e=0;e<r;e++)i[e]=arguments[e];return i[r]=n.call(arguments,r),t.apply(this,i)}}function v(t,r){return function(e){return t(e)&&r(e)}}function g(){}function w(){return!0}function _(e,t){return t&&t.constructor===e}var M=n("length"),x=b(_,String);function k(e){return e!==J}function S(e,t){return t instanceof r&&function e(t,r){return!r||t(A(r))&&e(t,j(r))}(function(e){return e in t},e)}function E(e,t){return[e,t]}var i=null,A=n(0),j=n(1);function I(e){return C(e.reduce((r=E,function(e,t){return r(t,e)}),i));var r}var B=l(I);function a(e){return T(function(e,t){return e.unshift(t),e},[],e)}function f(e,t){return t?E(e(A(t)),f(e,j(t))):i}function T(e,t,r){return r?e(T(e,t,j(r)),A(r)):t}function c(e,n,t){return function e(t,r){return t?n(A(t))?(r(A(t)),j(t)):E(A(t),e(j(t),r)):i}(e,t||g)}function C(e){return function e(t,r){return t?e(j(t),E(A(t),r)):r}(e,i)}function s(e){var o,s,a,u=e(fe).emit,f=e(ce).emit,c=e(he).emit,t=e(re).emit,h=65536,d=/[\\"\n]/g,r=0,l=r++,p=r++,b=r++,m=r++,y=r++,v=r++,g=r++,w=r++,_=r++,M=r++,x=r++,k=r++,S=r++,E=r++,A=r++,j=r++,I=r++,B=r++,T=r++,C=r++,P=h,R=J,O="",N=!1,L=!1,q=l,D=[],F=null,U=0,H=0,z=0,K=0,W=1;function V(e){R!==J&&(f(R),c(),R=J),o=G(e+"\nLn: "+W+"\nCol: "+K+"\nChr: "+s),t(de(J,J,o))}function X(e){return"\r"==e||"\n"==e||" "==e||"\t"==e}e(se).on(function(e){if(o)return;if(L)return V("Cannot write after close");var t=0;s=e[0];for(;s&&(a=s,s=e[t++]);)switch(z++,"\n"==s?(W++,K=0):K++,q){case l:if("{"===s)q=b;else if("["===s)q=y;else if(!X(s))return V("Non-whitespace before {[.");continue;case w:case b:if(X(s))continue;if(q===w)D.push(_);else{if("}"===s){f({}),c(),q=D.pop()||p;continue}D.push(m)}if('"'!==s)return V('Malformed object key should start with " ');q=g;continue;case _:case m:if(X(s))continue;if(":"===s)q===m?(D.push(m),R!==J&&(f({}),u(R),R=J),H++):R!==J&&(u(R),R=J),q=p;else if("}"===s)R!==J&&(f(R),c(),R=J),c(),H--,q=D.pop()||p;else{if(","!==s)return V("Bad object");q===m&&D.push(m),R!==J&&(f(R),c(),R=J),q=w}continue;case y:case p:if(X(s))continue;if(q===y){if(f([]),H++,q=p,"]"===s){c(),H--,q=D.pop()||p;continue}D.push(v)}if('"'===s)q=g;else if("{"===s)q=b;else if("["===s)q=y;else if("t"===s)q=M;else if("f"===s)q=S;else if("n"===s)q=I;else if("-"===s)O+=s;else if("0"===s)O+=s,q=20;else{if(-1==="123456789".indexOf(s))return V("Bad value");O+=s,q=20}continue;case v:if(","===s)D.push(v),R!==J&&(f(R),c(),R=J),q=p;else{if("]"!==s){if(X(s))continue;return V("Bad array")}R!==J&&(f(R),c(),R=J),c(),H--,q=D.pop()||p}continue;case g:R===J&&(R="");var r=t-1;e:for(;;){for(;0<U;)if(F+=s,s=e.charAt(t++),4===U?(R+=String.fromCharCode(parseInt(F,16)),U=0,r=t-1):U++,!s)break e;if('"'===s&&!N){q=D.pop()||p,R+=e.substring(r,t-1);break}if(!("\\"!==s||N||(N=!0,R+=e.substring(r,t-1),s=e.charAt(t++))))break;if(N){if(N=!1,"n"===s?R+="\n":"r"===s?R+="\r":"t"===s?R+="\t":"f"===s?R+="\f":"b"===s?R+="\b":"u"===s?(U=1,F=""):R+=s,s=e.charAt(t++),r=t-1,s)continue;break}d.lastIndex=t;var n=d.exec(e);if(!n){t=e.length+1,R+=e.substring(r,t-1);break}if(t=n.index+1,!(s=e.charAt(n.index))){R+=e.substring(r,t-1);break}}continue;case M:if(!s)continue;if("r"!==s)return V("Invalid true started with t"+s);q=x;continue;case x:if(!s)continue;if("u"!==s)return V("Invalid true started with tr"+s);q=k;continue;case k:if(!s)continue;if("e"!==s)return V("Invalid true started with tru"+s);f(!0),c(),q=D.pop()||p;continue;case S:if(!s)continue;if("a"!==s)return V("Invalid false started with f"+s);q=E;continue;case E:if(!s)continue;if("l"!==s)return V("Invalid false started with fa"+s);q=A;continue;case A:if(!s)continue;if("s"!==s)return V("Invalid false started with fal"+s);q=j;continue;case j:if(!s)continue;if("e"!==s)return V("Invalid false started with fals"+s);f(!1),c(),q=D.pop()||p;continue;case I:if(!s)continue;if("u"!==s)return V("Invalid null started with n"+s);q=B;continue;case B:if(!s)continue;if("l"!==s)return V("Invalid null started with nu"+s);q=T;continue;case T:if(!s)continue;if("l"!==s)return V("Invalid null started with nul"+s);f(null),c(),q=D.pop()||p;continue;case C:if("."!==s)return V("Leading zero not followed by .");O+=s,q=20;continue;case 20:if(-1!=="0123456789".indexOf(s))O+=s;else if("."===s){if(-1!==O.indexOf("."))return V("Invalid number has two dots");O+=s}else if("e"===s||"E"===s){if(-1!==O.indexOf("e")||-1!==O.indexOf("E"))return V("Invalid number has two exponential");O+=s}else if("+"===s||"-"===s){if("e"!==a&&"E"!==a)return V("Invalid symbol in number");O+=s}else O&&(f(parseFloat(O)),c(),O=""),t--,q=D.pop()||p;continue;default:return V("Unknown state: "+q)}P<=z&&(i=0,R!==J&&R.length>h&&(V("Max buffer length exceeded: textNode"),i=Math.max(i,R.length)),O.length>h&&(V("Max buffer length exceeded: numberNode"),i=Math.max(i,O.length)),P=h-i+z);var i}),e(ae).on(function(){if(q==l)return f({}),c(),void(L=!0);q===p&&0===H||V("Unexpected end");R!==J&&(f(R),c(),R=J);L=!0})}var e,t,o,P,R,O,N,L,q,D,F,U=(e=l(function(e){return e.unshift(/^/),(t=RegExp(e.map(n("source")).join(""))).exec.bind(t);var t}),P=e(t=/(\$?)/,/([\w-_]+|\*)/,o=/(?:{([\w ]*?)})?/),R=e(t,/\["([^"]+)"\]/,o),O=e(t,/\[(\d+|\*)\]/,o),N=e(t,/()/,/{([\w ]*?)}/),L=e(/\.\./),q=e(/\./),D=e(t,/!/),F=e(/$/),function(e){return e(y(P,R,O,N),L,q,D,F)});function H(e,t){return{key:e,node:t}}var z=n("key"),K=n("node"),W={};function V(e){var i=e(Y).emit,t=e(Q).emit,u=e(ie).emit,r=e(ne).emit;function f(e,t,r){K(A(e))[t]=r}function c(e,t,r){e&&f(e,t,r);var n=E(H(t,r),e);return i(n),n}var n={};return n[ce]=function(e,t){if(!e)return u(t),c(e,W,t);var r,n,i,o=(n=t,i=K(A(r=e)),_(h,i)?c(r,M(i),n):r),s=j(o),a=z(A(o));return f(s,a,t),E(H(a,t),s)},n[he]=function(e){return t(e),j(e)||r(K(A(e)))},n[fe]=c,n}var X=U(function(e,t,r,n,i){var o=m(z,A),s=m(K,A);function a(e,t){return!!t[1]?v(e,A):e}function u(e){if(e==w)return w;return v(function(e){return o(e)!=W},m(e,j))}function f(){return function(e){return o(e)==W}}function c(e,t,r,n,i){var o,s=e(r);if(s){var a=(o=s,T(function(e,t){return t(e,o)},n,t));return i(r.substr(M(s[0])),a)}}function h(e,t){return b(c,e,t)}var d=y(h(e,B(a,function(e,t){var r=t[3];return r?v(m(b(S,I(r.split(/\W+/))),s),e):e},function(e,t){var r=t[2];return v(r&&"*"!=r?function(e){return o(e)==r}:w,e)},u)),h(t,B(function(e){if(e==w)return w;var t=f(),r=e,n=u(function(e){return i(e)}),i=y(t,r,n);return i})),h(r,B()),h(n,B(a,f)),h(i,B(function(r){return function(e){var t=r(e);return!0===t?A(e):t}})),function(e){throw G('"'+e+'" could not be tokenised')});function l(e,t){return t}function p(e,t){return d(e,t,e?p:l)}return function(t){try{return p(t,w)}catch(e){throw G('Could not compile "'+t+'" because '+e.message)}}});function Z(n,i,r){var o,s;function a(t){return function(e){return e.id==t}}return{on:function(e,t){var r={listener:e,id:t||e};return i&&i.emit(n,e,r.id),o=E(r,o),s=E(e,s),this},emit:function(){!function e(t,r){t&&(A(t).apply(null,r),e(j(t),r))}(s,arguments)},un:function(e){var t;o=c(o,a(e),function(e){t=e}),t&&(s=c(s,function(e){return e==t.listener}),r&&r.emit(n,t.listener,t.id))},listeners:function(){return s},hasListener:function(e){return k(function e(t,r){return r&&(t(A(r))?A(r):e(t,j(r)))}(e?a(e):w,o))}}}var $=1,Y=$++,Q=$++,ee=$++,te=$++,re="fail",ne=$++,ie=$++,oe="start",se="data",ae="end",ue=$++,fe=$++,ce=$++,he=$++;function de(e,t,r){try{var n=u.parse(t)}catch(e){}return{statusCode:e,body:t,jsonBody:n,thrown:r}}function le(n,i){var o={node:n(Q),path:n(Y)};function s(t,r,o){var s=n(t).emit;r.on(function(e){var t,r,n,i=o(e);!1!==i&&(t=s,r=K(i),n=C(e),t(r,a(j(f(z,n))),a(f(K,n))))},t),n("removeListener").on(function(e){e==t&&(n(e).listeners()||r.un(t))})}n("newListener").on(function(e){var t=/(node|path):(.*)/.exec(e);if(t){var r=o[t[1]];r.hasListener(e)||s(e,r,i(t[2]))}})}function pe(o,e){var i,s=/^(node|path):./,a=o(ne),u=o(te).emit,f=o(ee).emit,t=l(function(e,t){if(i[e])d(t,i[e]);else{var r=o(e),n=t[0];s.test(e)?c(r,n):r.on(n)}return i});function c(t,e,r){r=r||e;var n=h(e);return t.on(function(){var e=!1;i.forget=function(){e=!0},d(arguments,n),delete i.forget,e&&t.un(r)},r),i}function h(e){return function(){try{return e.apply(i,arguments)}catch(e){setTimeout(function(){throw e})}}}function n(e,t,r){var n,i;"node"==e?(i=r,n=function(){var e=i.apply(this,arguments);k(e)&&(e==ye.drop?u():f(e))}):n=r,c(o(e+":"+t),n,r)}function r(e,t,r){return x(t)?n(e,t,r):function(e,t){for(var r in t)n(e,r,t[r])}(e,t),i}return o(ie).on(function(e){var t;i.root=(t=e,function(){return t})}),o(oe).on(function(e,t){i.header=function(e){return e?t[e]:t}}),i={on:t,addListener:t,removeListener:function(e,t,r){if("done"==e)a.un(t);else if("node"==e||"path"==e)o.un(e+":"+t,r);else{var n=t;o(e).un(n)}return i},emit:o.emit,node:b(r,"node"),path:b(r,"path"),done:b(c,a),start:b(function(e,t){return o(e).on(h(t),t),i},oe),fail:o(re).on,abort:o(ue).emit,header:g,root:g,source:e}}function be(e,t,r,n,i){var o=function(){var t={},r=i("newListener"),n=i("removeListener");function i(e){return t[e]=Z(e,r,n)}function o(e){return t[e]||i(e)}return["emit","on","un"].forEach(function(r){o[r]=l(function(e,t){d(t,o(e)[r])})}),o}();return t&&function(t,n,e,r,i,o,s){var a,u=t(se).emit,f=t(re).emit,c=0,h=!0;function d(){var e=n.responseText,t=e.substr(c);t&&u(t),c=M(e)}t(ue).on(function(){n.onreadystatechange=null,n.abort()}),"onprogress"in n&&(n.onprogress=d),n.onreadystatechange=function(){function e(){try{h&&t(oe).emit(n.status,(e=n.getAllResponseHeaders(),r={},e&&e.split("\r\n").forEach(function(e){var t=e.indexOf(": ");r[e.substring(0,t)]=e.substring(t+2)}),r)),h=!1}catch(e){}var e,r}switch(n.readyState){case 2:case 3:return e();case 4:e(),2==String(n.status)[0]?(d(),t(ae).emit()):f(de(n.status,n.responseText))}};try{for(var l in n.open(e,r,!0),o)n.setRequestHeader(l,o[l]);(function(t,e){function r(e){return e.port||{"http:":80,"https:":443}[e.protocol||t.protocol]}return!!(e.protocol&&e.protocol!=t.protocol||e.host&&e.host!=t.host||e.host&&r(e)!=r(t))})(p.location,{protocol:(a=/(\w+:)?(?:\/\/)([\w.-]+)?(?::(\d+))?\/?/.exec(r)||[])[1]||"",host:a[2]||"",port:a[3]||""})||n.setRequestHeader("X-Requested-With","XMLHttpRequest"),n.withCredentials=s,n.send(i)}catch(e){p.setTimeout(b(f,de(J,J,e)),0)}}(o,new XMLHttpRequest,e,t,r,n,i),s(o),function(t,r){var i,n={};function e(t){return function(e){i=t(i,e)}}for(var o in r)t(o).on(e(r[o]),n);t(ee).on(function(e){var t=A(i),r=z(t),n=j(i);n&&(K(A(n))[r]=e)}),t(te).on(function(){var e=A(i),t=z(e),r=j(i);r&&delete K(A(r))[t]}),t(ue).on(function(){for(var e in r)t(e).un(n)})}(o,V(o)),le(o,X),pe(o,t)}function me(e,t,r,n,i,o,s){return i=i?u.parse(u.stringify(i)):{},n?x(n)||(n=u.stringify(n),i["Content-Type"]=i["Content-Type"]||"application/json"):n=null,e(r||"GET",(a=t,!1===s&&(-1==a.indexOf("?")?a+="?":a+="&",a+="_="+(new Date).getTime()),a),n,i,o||!1);var a}function ye(e){var t=B("resume","pause","pipe"),r=b(S,t);return e?r(e)||x(e)?me(be,e):me(be,e.url,e.method,e.body,e.headers,e.withCredentials,e.cached):be()}ye.drop=function(){return ye.drop},"function"==typeof define&&define.amd?define("oboe",[],function(){return ye}):"object"===(void 0===ge?"undefined":_typeof(ge))?ve.exports=ye:p.oboe=ye}(function(){try{return window}catch(e){return self}}(),Object,Array,Error,JSON)},{}],392:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],393:[function(e,t,r){var i=e("underscore"),o=e("web3-core-helpers").errors,s=e("oboe"),n=function(e,t){var n=this;this.responseCallbacks={},this.notificationCallbacks=[],this.path=e,this.connected=!1,this.connection=t.connect({path:this.path}),this.addDefaultEvents();var r=function(t){var r=null;i.isArray(t)?t.forEach(function(e){n.responseCallbacks[e.id]&&(r=e.id)}):r=t.id,r||-1===t.method.indexOf("_subscription")?n.responseCallbacks[r]&&(n.responseCallbacks[r](null,t),delete n.responseCallbacks[r]):n.notificationCallbacks.forEach(function(e){i.isFunction(e)&&e(t)})};"Socket"===t.constructor.name?s(this.connection).done(r):this.connection.on("data",function(e){n._parseResponse(e.toString()).forEach(r)})};n.prototype.addDefaultEvents=function(){var e=this;this.connection.on("connect",function(){e.connected=!0}),this.connection.on("close",function(){e.connected=!1}),this.connection.on("error",function(){e._timeout()}),this.connection.on("end",function(){e._timeout()}),this.connection.on("timeout",function(){e._timeout()})},n.prototype._parseResponse=function(e){var r=this,n=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach(function(t){r.lastChunk&&(t=r.lastChunk+t);var e=null;try{e=JSON.parse(t)}catch(e){return r.lastChunk=t,clearTimeout(r.lastChunkTimeout),void(r.lastChunkTimeout=setTimeout(function(){throw r._timeout(),o.InvalidResponse(t)},15e3))}clearTimeout(r.lastChunkTimeout),r.lastChunk=null,e&&n.push(e)}),n},n.prototype._addResponseCallback=function(e,t){var r=e.id||e[0].id,n=e.method||e[0].method;this.responseCallbacks[r]=t,this.responseCallbacks[r].method=n},n.prototype._timeout=function(){for(var e in this.responseCallbacks)this.responseCallbacks.hasOwnProperty(e)&&(this.responseCallbacks[e](o.InvalidConnection("on IPC")),delete this.responseCallbacks[e])},n.prototype.reconnect=function(){this.connection.connect({path:this.path})},n.prototype.send=function(e,t){this.connection.writable||this.connection.connect({path:this.path}),this.connection.write(JSON.stringify(e)),this._addResponseCallback(e,t)},n.prototype.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");switch(e){case"data":this.notificationCallbacks.push(t);break;default:this.connection.on(e,t)}},n.prototype.once=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");this.connection.once(e,t)},n.prototype.removeListener=function(e,r){var n=this;switch(e){case"data":this.notificationCallbacks.forEach(function(e,t){e===r&&n.notificationCallbacks.splice(t,1)});break;default:this.connection.removeListener(e,r)}},n.prototype.removeAllListeners=function(e){switch(e){case"data":this.notificationCallbacks=[];break;default:this.connection.removeAllListeners(e)}},n.prototype.reset=function(){this._timeout(),this.notificationCallbacks=[],this.connection.removeAllListeners("error"),this.connection.removeAllListeners("end"),this.connection.removeAllListeners("timeout"),this.addDefaultEvents()},t.exports=n},{oboe:391,underscore:392,"web3-core-helpers":200}],394:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],395:[function(i,c,e){(function(t){var s=i("underscore"),o=i("web3-core-helpers").errors,a=null,u=null,f=null;if("undefined"!=typeof window&&void 0!==window.WebSocket)a=window.WebSocket,u=btoa,f=function(e){return new URL(e)};else{a=i("websocket").w3cwebsocket,u=function(e){return t(e).toString("base64")};var e=i("url");if(e.URL){var r=e.URL;f=function(e){return new r(e)}}else f=i("url").parse}var n=function(e,t){var n=this;this.responseCallbacks={},this.notificationCallbacks=[],t=t||{},this._customTimeout=t.timeout;var r=f(e),i=t.headers||{},o=t.protocol||void 0;r.username&&r.password&&(i.authorization="Basic "+u(r.username+":"+r.password)),this.connection=new a(e,o,void 0,i),this.addDefaultEvents(),this.connection.onmessage=function(e){var t="string"==typeof e.data?e.data:"";n._parseResponse(t).forEach(function(t){var r=null;s.isArray(t)?t.forEach(function(e){n.responseCallbacks[e.id]&&(r=e.id)}):r=t.id,r||-1===t.method.indexOf("_subscription")?n.responseCallbacks[r]&&(n.responseCallbacks[r](null,t),delete n.responseCallbacks[r]):n.notificationCallbacks.forEach(function(e){s.isFunction(e)&&e(t)})})},Object.defineProperty(this,"connected",{get:function(){return this.connection&&this.connection.readyState===this.connection.OPEN},enumerable:!0})};n.prototype.addDefaultEvents=function(){var e=this;this.connection.onerror=function(){e._timeout()},this.connection.onclose=function(){e._timeout(),e.reset()}},n.prototype._parseResponse=function(e){var r=this,n=[];return e.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach(function(t){r.lastChunk&&(t=r.lastChunk+t);var e=null;try{e=JSON.parse(t)}catch(e){return r.lastChunk=t,clearTimeout(r.lastChunkTimeout),void(r.lastChunkTimeout=setTimeout(function(){throw r._timeout(),o.InvalidResponse(t)},15e3))}clearTimeout(r.lastChunkTimeout),r.lastChunk=null,e&&n.push(e)}),n},n.prototype._addResponseCallback=function(e,t){var r=e.id||e[0].id,n=e.method||e[0].method;this.responseCallbacks[r]=t,this.responseCallbacks[r].method=n;var i=this;this._customTimeout&&setTimeout(function(){i.responseCallbacks[r]&&(i.responseCallbacks[r](o.ConnectionTimeout(i._customTimeout)),delete i.responseCallbacks[r])},this._customTimeout)},n.prototype._timeout=function(){for(var e in this.responseCallbacks)this.responseCallbacks.hasOwnProperty(e)&&(this.responseCallbacks[e](o.InvalidConnection("on WS")),delete this.responseCallbacks[e])},n.prototype.send=function(e,t){var r=this;if(this.connection.readyState!==this.connection.CONNECTING){if(this.connection.readyState!==this.connection.OPEN)return console.error("connection not open on send()"),"function"==typeof this.connection.onerror?this.connection.onerror(new Error("connection not open")):console.error("no error callback"),void t(new Error("connection not open"));this.connection.send(JSON.stringify(e)),this._addResponseCallback(e,t)}else setTimeout(function(){r.send(e,t)},10)},n.prototype.on=function(e,t){if("function"!=typeof t)throw new Error("The second parameter callback must be a function.");switch(e){case"data":this.notificationCallbacks.push(t);break;case"connect":this.connection.onopen=t;break;case"end":this.connection.onclose=t;break;case"error":this.connection.onerror=t}},n.prototype.removeListener=function(e,r){var n=this;switch(e){case"data":this.notificationCallbacks.forEach(function(e,t){e===r&&n.notificationCallbacks.splice(t,1)})}},n.prototype.removeAllListeners=function(e){switch(e){case"data":this.notificationCallbacks=[];break;case"connect":this.connection.onopen=null;break;case"end":this.connection.onclose=null;break;case"error":this.connection.onerror=null}},n.prototype.reset=function(){this._timeout(),this.notificationCallbacks=[],this.addDefaultEvents()},c.exports=n}).call(this,i("buffer").Buffer)},{buffer:48,underscore:394,url:166,"web3-core-helpers":200,websocket:45}],396:[function(e,t,r){var n=e("web3-core"),i=e("web3-core-subscriptions").subscriptions,o=e("web3-core-method"),s=e("web3-net"),a=function(){var t=this;n.packageInit(this,arguments);var e=this.setProvider;this.setProvider=function(){e.apply(t,arguments),t.net.setProvider.apply(t,arguments)},this.clearSubscriptions=t._requestManager.clearSubscriptions,this.net=new s(this.currentProvider),[new i({name:"subscribe",type:"shh",subscriptions:{messages:{params:1}}}),new o({name:"getVersion",call:"shh_version",params:0}),new o({name:"getInfo",call:"shh_info",params:0}),new o({name:"setMaxMessageSize",call:"shh_setMaxMessageSize",params:1}),new o({name:"setMinPoW",call:"shh_setMinPoW",params:1}),new o({name:"markTrustedPeer",call:"shh_markTrustedPeer",params:1}),new o({name:"newKeyPair",call:"shh_newKeyPair",params:0}),new o({name:"addPrivateKey",call:"shh_addPrivateKey",params:1}),new o({name:"deleteKeyPair",call:"shh_deleteKeyPair",params:1}),new o({name:"hasKeyPair",call:"shh_hasKeyPair",params:1}),new o({name:"getPublicKey",call:"shh_getPublicKey",params:1}),new o({name:"getPrivateKey",call:"shh_getPrivateKey",params:1}),new o({name:"newSymKey",call:"shh_newSymKey",params:0}),new o({name:"addSymKey",call:"shh_addSymKey",params:1}),new o({name:"generateSymKeyFromPassword",call:"shh_generateSymKeyFromPassword",params:1}),new o({name:"hasSymKey",call:"shh_hasSymKey",params:1}),new o({name:"getSymKey",call:"shh_getSymKey",params:1}),new o({name:"deleteSymKey",call:"shh_deleteSymKey",params:1}),new o({name:"newMessageFilter",call:"shh_newMessageFilter",params:1}),new o({name:"getFilterMessages",call:"shh_getFilterMessages",params:1}),new o({name:"deleteMessageFilter",call:"shh_deleteMessageFilter",params:1}),new o({name:"post",call:"shh_post",params:1,inputFormatter:[null]})].forEach(function(e){e.attachToObject(t),e.setRequestManager(t._requestManager)})};n.addProviders(a),t.exports=a},{"web3-core":218,"web3-core-method":202,"web3-core-subscriptions":215,"web3-net":382}],397:[function(e,t,r){arguments[4][219][0].apply(r,arguments)},{dup:219}],398:[function(e,t,r){arguments[4][174][0].apply(r,arguments)},{dup:174}],399:[function(e,t,r){var c=e("bn.js"),h=e("number-to-bn"),d=new c(0),l=new c(-1),p={noether:"0",wei:"1",kwei:"1000",Kwei:"1000",babbage:"1000",femtoether:"1000",mwei:"1000000",Mwei:"1000000",lovelace:"1000000",picoether:"1000000",gwei:"1000000000",Gwei:"1000000000",shannon:"1000000000",nanoether:"1000000000",nano:"1000000000",szabo:"1000000000000",microether:"1000000000000",micro:"1000000000000",finney:"1000000000000000",milliether:"1000000000000000",milli:"1000000000000000",ether:"1000000000000000000",kether:"1000000000000000000000",grand:"1000000000000000000000",mether:"1000000000000000000000000",gether:"1000000000000000000000000000",tether:"1000000000000000000000000000000"};function b(e){var t=e?e.toLowerCase():"ether",r=p[t];if("string"!=typeof r)throw new Error("[ethjs-unit] the unit provided "+e+" doesn't exists, please use the one of the following units "+JSON.stringify(p,null,2));return new c(r,10)}function m(e){if("string"==typeof e){if(!e.match(/^-?[0-9.]+$/))throw new Error("while converting number to string, invalid number value '"+e+"', should be a number matching (^-?[0-9.]+).");return e}if("number"==typeof e)return String(e);if("object"===(void 0===e?"undefined":_typeof(e))&&e.toString&&(e.toTwos||e.dividedToIntegerBy))return e.toPrecision?String(e.toPrecision()):e.toString(10);throw new Error("while converting number to string, invalid number value '"+e+"' type "+(void 0===e?"undefined":_typeof(e))+".")}t.exports={unitMap:p,numberToString:m,getValueOfUnit:b,fromWei:function(e,t,r){var n=h(e),i=n.lt(d),o=b(t),s=p[t].length-1||1,a=r||{};i&&(n=n.mul(l));for(var u=n.mod(o).toString(10);u.length<s;)u="0"+u;a.pad||(u=u.match(/^([0-9]*[1-9]|0)(0*)/)[1]);var f=n.div(o).toString(10);a.commify&&(f=f.replace(/\B(?=(\d{3})+(?!\d))/g,","));var c=f+("0"==u?"":"."+u);return i&&(c="-"+c),c},toWei:function(e,t){var r=m(e),n=b(t),i=p[t].length-1||1,o="-"===r.substring(0,1);if(o&&(r=r.substring(1)),"."===r)throw new Error("[ethjs-unit] while converting number "+e+" to wei, invalid value");var s=r.split(".");if(2<s.length)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal points");var a=s[0],u=s[1];if(a||(a="0"),u||(u="0"),u.length>i)throw new Error("[ethjs-unit] while converting number "+e+" to wei, too many decimal places");for(;u.length<i;)u+="0";a=new c(a),u=new c(u);var f=a.mul(n).add(u);return o&&(f=f.mul(l)),new c(f.toString(10),10)}}},{"bn.js":397,"number-to-bn":401}],400:[function(e,t,r){t.exports=function(e){if("string"!=typeof e)throw new Error("[is-hex-prefixed] value must be type 'string', is currently type "+(void 0===e?"undefined":_typeof(e))+", while checking isHexPrefixed.");return"0x"===e.slice(0,2)}},{}],401:[function(e,t,r){var o=e("bn.js"),s=e("strip-hex-prefix");t.exports=function(e){if("string"==typeof e||"number"==typeof e){var t=new o(1),r=String(e).toLowerCase().trim(),n="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),i=s(r);if("-"===i.substr(0,1)&&(i=s(i.slice(1)),t=new o(-1,10)),!(i=""===i?"0":i).match(/^-?[0-9]+$/)&&i.match(/^[0-9A-Fa-f]+$/)||i.match(/^[a-fA-F]+$/)||!0===n&&i.match(/^[0-9A-Fa-f]+$/))return new o(i,16).mul(t);if((i.match(/^-?[0-9]+$/)||""===i)&&!1===n)return new o(i,10).mul(t)}else if("object"===(void 0===e?"undefined":_typeof(e))&&e.toString&&!e.pop&&!e.push&&e.toString(10).match(/^-?[0-9]+$/)&&(e.mul||e.dividedToIntegerBy))return new o(e.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(e)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},{"bn.js":397,"strip-hex-prefix":405}],402:[function(e,t,r){t.exports=window.crypto},{}],403:[function(e,t,r){t.exports=e("crypto")},{crypto:402}],404:[function(u,e,t){e.exports=function(e,r){var t=u("./crypto.js"),n="function"==typeof r;if(65536<e){if(!n)throw new Error("Requested too many random bytes.");r(new Error("Requested too many random bytes."))}if(void 0!==t&&t.randomBytes){if(!n)return"0x"+t.randomBytes(e).toString("hex");t.randomBytes(e,function(e,t){e?r(a):r(null,"0x"+t.toString("hex"))})}else{var i;if(void 0!==t?i=t:"undefined"!=typeof msCrypto&&(i=msCrypto),i&&i.getRandomValues){var o=i.getRandomValues(new Uint8Array(e)),s="0x"+Array.from(o).map(function(e){return e.toString(16)}).join("");if(!n)return s;r(null,s)}else{var a=new Error('No "crypto" object available. This Browser doesn\'t support generating secure random bytes.');if(!n)throw a;r(a)}}}},{"./crypto.js":403}],405:[function(e,t,r){var n=e("is-hex-prefixed");t.exports=function(e){return"string"!=typeof e?e:n(e)?e.slice(2):e}},{"is-hex-prefixed":400}],406:[function(e,t,r){arguments[4][187][0].apply(r,arguments)},{dup:187}],407:[function(e,v,g){(function(y){!function(e){var t="object"==(void 0===g?"undefined":_typeof(g))&&g,r="object"==(void 0===v?"undefined":_typeof(v))&&v&&v.exports==t&&v,n="object"==(void 0===y?"undefined":_typeof(y))&&y;n.global!==n&&n.window!==n||(e=n);var i,o,s,a=String.fromCharCode;function u(e){for(var t,r,n=[],i=0,o=e.length;i<o;)55296<=(t=e.charCodeAt(i++))&&t<=56319&&i<o?56320==(64512&(r=e.charCodeAt(i++)))?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),i--):n.push(t);return n}function f(e){if(55296<=e&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}function c(e,t){return a(e>>t&63|128)}function h(e){if(0==(4294967168&e))return a(e);var t="";return 0==(4294965248&e)?t=a(e>>6&31|192):0==(4294901760&e)?(f(e),t=a(e>>12&15|224),t+=c(e,6)):0==(4292870144&e)&&(t=a(e>>18&7|240),t+=c(e,12),t+=c(e,6)),t+=a(63&e|128)}function d(){if(o<=s)throw Error("Invalid byte index");var e=255&i[s];if(s++,128==(192&e))return 63&e;throw Error("Invalid continuation byte")}function l(){var e,t;if(o<s)throw Error("Invalid byte index");if(s==o)return!1;if(e=255&i[s],s++,0==(128&e))return e;if(192==(224&e)){if(128<=(t=(31&e)<<6|d()))return t;throw Error("Invalid continuation byte")}if(224==(240&e)){if(2048<=(t=(15&e)<<12|d()<<6|d()))return f(t),t;throw Error("Invalid continuation byte")}if(240==(248&e)&&65536<=(t=(15&e)<<18|d()<<12|d()<<6|d())&&t<=1114111)return t;throw Error("Invalid UTF-8 detected")}var p={version:"2.0.0",encode:function(e){for(var t=u(e),r=t.length,n=-1,i="";++n<r;)i+=h(t[n]);return i},decode:function(e){i=u(e),o=i.length,s=0;for(var t,r=[];!1!==(t=l());)r.push(t);return function(e){for(var t,r=e.length,n=-1,i="";++n<r;)65535<(t=e[n])&&(i+=a((t-=65536)>>>10&1023|55296),t=56320|1023&t),i+=a(t);return i}(r)}};if("function"==typeof define&&"object"==_typeof(define.amd)&&define.amd)define(function(){return p});else if(t&&!t.nodeType)if(r)r.exports=p;else{var b={}.hasOwnProperty;for(var m in p)b.call(p,m)&&(t[m]=p[m])}else e.utf8=p}(this)}).call(this,"undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],408:[function(e,t,r){var i=e("underscore"),n=e("ethjs-unit"),o=e("./utils.js"),s=e("./soliditySha3.js"),a=e("randomhex"),u=function(e){if(!o.isHexStrict(e))throw new Error("The parameter must be a valid HEX string.");var t="",r=0,n=e.length;for("0x"===e.substring(0,2)&&(r=2);r<n;r+=2){var i=parseInt(e.substr(r,2),16);t+=String.fromCharCode(i)}return t},f=function(e){if(!e)return"0x00";for(var t="",r=0;r<e.length;r++){var n=e.charCodeAt(r).toString(16);t+=n.length<2?"0"+n:n}return"0x"+t},c=function(e){if(e=e?e.toLowerCase():"ether",!n.unitMap[e])throw new Error('This unit "'+e+"\" doesn't exist, please use the one of the following units"+JSON.stringify(n.unitMap,null,2));return e};t.exports={_fireError:function(e,t,r,n){return!i.isObject(e)||e instanceof Error||!e.data||((i.isObject(e.data)||i.isArray(e.data))&&(e.data=JSON.stringify(e.data,null,2)),e=e.message+"\n"+e.data),i.isString(e)&&(e=new Error(e)),i.isFunction(n)&&n(e),i.isFunction(r)&&((t&&i.isFunction(t.listeners)&&t.listeners("error").length||i.isFunction(n))&&t.catch(function(){}),setTimeout(function(){r(e)},1)),t&&i.isFunction(t.emit)&&setTimeout(function(){t.emit("error",e),t.removeAllListeners()},1),t},_jsonInterfaceMethodToString:function(e){if(i.isObject(e)&&e.name&&-1!==e.name.indexOf("("))return e.name;var t=e.inputs.map(function(e){return e.type}).join(",");return e.name+"("+t+")"},randomHex:a,_:i,BN:o.BN,isBN:o.isBN,isBigNumber:o.isBigNumber,isHex:o.isHex,isHexStrict:o.isHexStrict,sha3:o.sha3,keccak256:o.sha3,soliditySha3:s,isAddress:o.isAddress,checkAddressChecksum:o.checkAddressChecksum,toChecksumAddress:function(e){if(void 0===e)return"";if(!/^(0x)?[0-9a-f]{40}$/i.test(e))throw new Error('Given address "'+e+'" is not a valid Ethereum address.');e=e.toLowerCase().replace(/^0x/i,"");for(var t=o.sha3(e).replace(/^0x/i,""),r="0x",n=0;n<e.length;n++)7<parseInt(t[n],16)?r+=e[n].toUpperCase():r+=e[n];return r},toHex:o.toHex,toBN:o.toBN,bytesToHex:o.bytesToHex,hexToBytes:o.hexToBytes,hexToNumberString:o.hexToNumberString,hexToNumber:o.hexToNumber,toDecimal:o.hexToNumber,numberToHex:o.numberToHex,fromDecimal:o.numberToHex,hexToUtf8:o.hexToUtf8,hexToString:o.hexToUtf8,toUtf8:o.hexToUtf8,utf8ToHex:o.utf8ToHex,stringToHex:o.utf8ToHex,fromUtf8:o.utf8ToHex,hexToAscii:u,toAscii:u,asciiToHex:f,fromAscii:f,unitMap:n.unitMap,toWei:function(e,t){if(t=c(t),!o.isBN(e)&&!i.isString(e))throw new Error("Please pass numbers as strings or BigNumber objects to avoid precision errors.");return o.isBN(e)?n.toWei(e,t):n.toWei(e,t).toString(10)},fromWei:function(e,t){if(t=c(t),!o.isBN(e)&&!i.isString(e))throw new Error("Please pass numbers as strings or BigNumber objects to avoid precision errors.");return o.isBN(e)?n.fromWei(e,t):n.fromWei(e,t).toString(10)},padLeft:o.leftPad,leftPad:o.leftPad,padRight:o.rightPad,rightPad:o.rightPad,toTwosComplement:o.toTwosComplement}},{"./soliditySha3.js":409,"./utils.js":410,"ethjs-unit":399,randomhex:404,underscore:406}],409:[function(e,t,r){var o=e("underscore"),a=e("bn.js"),u=e("./utils.js"),f=function(e){var t=void 0===e?"undefined":_typeof(e);if("string"===t)return u.isHexStrict(e)?new a(e.replace(/0x/i,""),16):new a(e,10);if("number"===t)return new a(e);if(u.isBigNumber(e))return new a(e.toString(10));if(u.isBN(e))return e;throw new Error(e+" is not a number")},s=function(e,t,r){var n,i,o,s;if("bytes"===(e=(o=e).startsWith("int[")?"int256"+o.slice(3):"int"===o?"int256":o.startsWith("uint[")?"uint256"+o.slice(4):"uint"===o?"uint256":o.startsWith("fixed[")?"fixed128x128"+o.slice(5):"fixed"===o?"fixed128x128":o.startsWith("ufixed[")?"ufixed128x128"+o.slice(6):"ufixed"===o?"ufixed128x128":o)){if(t.replace(/^0x/i,"").length%2!=0)throw new Error("Invalid bytes characters "+t.length);return t}if("string"===e)return u.utf8ToHex(t);if("bool"===e)return t?"01":"00";if(e.startsWith("address")){if(n=r?64:40,!u.isAddress(t))throw new Error(t+" is not a valid address, or the checksum is invalid.");return u.leftPad(t.toLowerCase(),n)}if(n=(s=/^\D+(\d+).*$/.exec(e))?parseInt(s[1],10):null,e.startsWith("bytes")){if(!n)throw new Error("bytes[] not yet supported in solidity");if(r&&(n=32),n<1||32<n||n<t.replace(/^0x/i,"").length/2)throw new Error("Invalid bytes"+n+" for "+t);return u.rightPad(t,2*n)}if(e.startsWith("uint")){if(n%8||n<8||256<n)throw new Error("Invalid uint"+n+" size");if((i=f(t)).bitLength()>n)throw new Error("Supplied uint exceeds width: "+n+" vs "+i.bitLength());if(i.lt(new a(0)))throw new Error("Supplied uint "+i.toString()+" is negative");return n?u.leftPad(i.toString("hex"),n/8*2):i}if(e.startsWith("int")){if(n%8||n<8||256<n)throw new Error("Invalid int"+n+" size");if((i=f(t)).bitLength()>n)throw new Error("Supplied int exceeds width: "+n+" vs "+i.bitLength());return i.lt(new a(0))?i.toTwos(n).toString("hex"):n?u.leftPad(i.toString("hex"),n/8*2):i}throw new Error("Unsupported or invalid type: "+e)},n=function(e){if(o.isArray(e))throw new Error("Autodetection of array types is not supported.");var t,r,n,i="";if(o.isObject(e)&&(e.hasOwnProperty("v")||e.hasOwnProperty("t")||e.hasOwnProperty("value")||e.hasOwnProperty("type"))?(t=e.hasOwnProperty("t")?e.t:e.type,i=e.hasOwnProperty("v")?e.v:e.value):(t=u.toHex(e,!0),i=u.toHex(e),t.startsWith("int")||t.startsWith("uint")||(t="bytes")),!t.startsWith("int")&&!t.startsWith("uint")||"string"!=typeof i||/^(-)?0x/i.test(i)||(i=new a(i)),o.isArray(i)){if(n=/^\D+\d*\[(\d+)\]$/.exec(t),(r=n?parseInt(n[1],10):null)&&i.length!==r)throw new Error(t+" is not matching the given array "+JSON.stringify(i));r=i.length}return o.isArray(i)?i.map(function(e){return s(t,e,r).toString("hex").replace("0x","")}).join(""):s(t,i,r).toString("hex").replace("0x","")};t.exports=function(){var e=Array.prototype.slice.call(arguments),t=o.map(e,n);return u.sha3("0x"+t.join(""))}},{"./utils.js":410,"bn.js":397,underscore:406}],410:[function(e,t,r){var n=e("underscore"),i=e("bn.js"),o=e("number-to-bn"),s=e("utf8"),a=e("eth-lib/lib/hash"),u=function(e){return e instanceof i||e&&e.constructor&&"BN"===e.constructor.name},f=function(e){return e&&e.constructor&&"BigNumber"===e.constructor.name},c=function(t){try{return o.apply(null,arguments)}catch(e){throw new Error(e+' Given value: "'+t+'"')}},h=function(e){return!!/^(0x)?[0-9a-f]{40}$/i.test(e)&&(!(!/^(0x|0X)?[0-9a-f]{40}$/.test(e)&&!/^(0x|0X)?[0-9A-F]{40}$/.test(e))||d(e))},d=function(e){e=e.replace(/^0x/i,"");for(var t=y(e.toLowerCase()).replace(/^0x/i,""),r=0;r<40;r++)if(7<parseInt(t[r],16)&&e[r].toUpperCase()!==e[r]||parseInt(t[r],16)<=7&&e[r].toLowerCase()!==e[r])return!1;return!0},l=function(e){var t="";e=(e=(e=(e=(e=s.encode(e)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r<e.length;r++){var n=e.charCodeAt(r).toString(16);t+=n.length<2?"0"+n:n}return"0x"+t},p=function(e){if(n.isNull(e)||n.isUndefined(e))return e;if(!isFinite(e)&&!m(e))throw new Error('Given input "'+e+'" is not a number.');var t=c(e),r=t.toString(16);return t.lt(new i(0))?"-0x"+r.substr(1):"0x"+r},b=function(e){if(e=e.toString(16),!m(e))throw new Error('Given value "'+e+'" is not a valid hex string.');e=e.replace(/^0x/i,"");for(var t=[],r=0;r<e.length;r+=2)t.push(parseInt(e.substr(r,2),16));return t},m=function(e){return(n.isString(e)||n.isNumber(e))&&/^(-)?0x[0-9a-f]*$/i.test(e)},y=function(e){m(e)&&/^0x/i.test(e.toString())&&(e=b(e));var t=a.keccak256(e);return"0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470"===t?null:t};y._Hash=a,t.exports={BN:i,isBN:u,isBigNumber:f,toBN:c,isAddress:h,isBloom:function(e){return!(!/^(0x)?[0-9a-f]{512}$/i.test(e)||!/^(0x)?[0-9a-f]{512}$/.test(e)&&!/^(0x)?[0-9A-F]{512}$/.test(e))},isTopic:function(e){return!(!/^(0x)?[0-9a-f]{64}$/i.test(e)||!/^(0x)?[0-9a-f]{64}$/.test(e)&&!/^(0x)?[0-9A-F]{64}$/.test(e))},checkAddressChecksum:d,utf8ToHex:l,hexToUtf8:function(e){if(!m(e))throw new Error('The parameter "'+e+'" must be a valid HEX string.');for(var t="",r=0,n=(e=(e=(e=(e=(e=e.replace(/^0x/i,"")).replace(/^(?:00)*/,"")).split("").reverse().join("")).replace(/^(?:00)*/,"")).split("").reverse().join("")).length,i=0;i<n;i+=2)r=parseInt(e.substr(i,2),16),t+=String.fromCharCode(r);return s.decode(t)},hexToNumber:function(e){return e?c(e).toNumber():e},hexToNumberString:function(e){return e?c(e).toString(10):e},numberToHex:p,toHex:function(e,t){if(h(e))return t?"address":"0x"+e.toLowerCase().replace(/^0x/i,"");if(n.isBoolean(e))return t?"bool":e?"0x01":"0x00";if(n.isObject(e)&&!f(e)&&!u(e))return t?"string":l(JSON.stringify(e));if(n.isString(e)){if(0===e.indexOf("-0x")||0===e.indexOf("-0X"))return t?"int256":p(e);if(0===e.indexOf("0x")||0===e.indexOf("0X"))return t?"bytes":e;if(!isFinite(e))return t?"string":l(e)}return t?e<0?"int256":"uint256":p(e)},hexToBytes:b,bytesToHex:function(e){for(var t=[],r=0;r<e.length;r++)t.push((e[r]>>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x"+t.join("")},isHex:function(e){return(n.isString(e)||n.isNumber(e))&&/^(-0x|0x)?[0-9a-f]*$/i.test(e)},isHexStrict:m,leftPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=0<=t-(e=e.toString(16).replace(/^0x/i,"")).length+1?t-e.length+1:0;return(n?"0x":"")+new Array(i).join(r||"0")+e},rightPad:function(e,t,r){var n=/^0x/i.test(e)||"number"==typeof e,i=0<=t-(e=e.toString(16).replace(/^0x/i,"")).length+1?t-e.length+1:0;return(n?"0x":"")+e+new Array(i).join(r||"0")},toTwosComplement:function(e){return"0x"+c(e).toTwos(256).toString(16,64)},sha3:y}},{"bn.js":397,"eth-lib/lib/hash":398,"number-to-bn":401,underscore:406,utf8:407}],411:[function(e,t,r){t.exports={name:"web3",namespace:"ethereum",version:"1.0.0-beta.35",description:"Ethereum JavaScript API",repository:"https://github.com/ethereum/web3.js/tree/master/packages/web3",license:"LGPL-3.0",main:"src/index.js",types:"index.d.ts",bugs:{url:"https://github.com/ethereum/web3.js/issues"},keywords:["Ethereum","JavaScript","API"],author:"ethereum.org",authors:[{name:"Fabian Vogelsteller",email:"fabian@ethereum.org",homepage:"http://frozeman.de"},{name:"Marek Kotewicz",email:"marek@parity.io",url:"https://github.com/debris"},{name:"Marian Oancea",url:"https://github.com/cubedro"},{name:"Gav Wood",email:"g@parity.io",homepage:"http://gavwood.com"},{name:"Jeffery Wilcke",email:"jeffrey.wilcke@ethereum.org",url:"https://github.com/obscuren"}],dependencies:{"web3-bzz":"1.0.0-beta.35","web3-core":"1.0.0-beta.35","web3-eth":"1.0.0-beta.35","web3-eth-personal":"1.0.0-beta.35","web3-net":"1.0.0-beta.35","web3-shh":"1.0.0-beta.35","web3-utils":"1.0.0-beta.35"}}},{}],BN:[function(e,t,r){arguments[4][249][0].apply(r,arguments)},{buffer:17,dup:249}],Web3:[function(e,t,r){var i=e("../package.json").version,o=e("web3-core"),s=e("web3-eth"),n=e("web3-net"),a=e("web3-eth-personal"),u=e("web3-shh"),f=e("web3-bzz"),c=e("web3-utils"),h=function(){var r=this;o.packageInit(this,arguments),this.version=i,this.utils=c,this.eth=new s(this),this.shh=new u(this),this.bzz=new f(this);var n=this.setProvider;this.setProvider=function(e,t){return n.apply(r,arguments),this.eth.setProvider(e,t),this.shh.setProvider(e,t),this.bzz.setProvider(e),!0}};h.version=i,h.utils=c,h.modules={Eth:s,Net:n,Personal:a,Shh:u,Bzz:f},o.addProviders(h),t.exports=h},{"../package.json":411,"web3-bzz":196,"web3-core":218,"web3-eth":381,"web3-eth-personal":378,"web3-net":382,"web3-shh":396,"web3-utils":408}]},{},["Web3"])("Web3")});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment