diff --git a/docs/asset-manifest.json b/docs/asset-manifest.json index 1ded351..e06e0f8 100644 --- a/docs/asset-manifest.json +++ b/docs/asset-manifest.json @@ -1,15 +1,15 @@ { "files": { - "main.css": "./static/css/main.5ed7d0b8.chunk.css", - "main.js": "./static/js/main.8315af75.chunk.js", + "main.css": "./static/css/main.8cf1853d.chunk.css", + "main.js": "./static/js/main.7258aa44.chunk.js", "runtime~main.js": "./static/js/runtime~main.ca7cb530.js", - "static/css/2.d11a7e4e.chunk.css": "./static/css/2.d11a7e4e.chunk.css", - "static/js/2.0eda3dfb.chunk.js": "./static/js/2.0eda3dfb.chunk.js", + "static/css/2.d6e5dedb.chunk.css": "./static/css/2.d6e5dedb.chunk.css", + "static/js/2.6c1f724b.chunk.js": "./static/js/2.6c1f724b.chunk.js", "index.html": "./index.html", - "precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js": "./precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js", + "precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js": "./precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js", "service-worker.js": "./service-worker.js", - "static/js/0.93946bfa.chunk.worker.js": "./static/js/0.93946bfa.chunk.worker.js", - "static/js/1.c35c4076.chunk.worker.js": "./static/js/1.c35c4076.chunk.worker.js", + "static/js/0.25e92e06.chunk.worker.js": "./static/js/0.25e92e06.chunk.worker.js", + "static/js/1.8958a83b.chunk.worker.js": "./static/js/1.8958a83b.chunk.worker.js", "static/media/EUSDT.png": "./static/media/EUSDT.0a5458ff.png", "static/media/EWBTC.png": "./static/media/EWBTC.9091f9fa.png", "static/media/EWETH.png": "./static/media/EWETH.f4891222.png", diff --git a/docs/index.html b/docs/index.html index 19a6032..cc0522b 100644 --- a/docs/index.html +++ b/docs/index.html @@ -1 +1 @@ -SERO Popup
\ No newline at end of file +SERO Popup
\ No newline at end of file diff --git a/docs/manifest.json b/docs/manifest.json index 6da1dc4..8bd89fb 100755 --- a/docs/manifest.json +++ b/docs/manifest.json @@ -3,8 +3,8 @@ "id" : "cash.sero.popup.community", /*应用的标识*/ "name" : "SERO Popup Community", /*应用名称,程序桌面图标名称*/ "version" : { - "name" : "1.4.9", /*应用版本名称*/ - "code" : 186 + "name" : "1.5.0", /*应用版本名称*/ + "code" : 187 }, "description" : "", /*应用描述信息*/ diff --git a/docs/precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js b/docs/precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js similarity index 67% rename from docs/precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js rename to docs/precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js index c19322f..bde8945 100644 --- a/docs/precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js +++ b/docs/precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js @@ -1,31 +1,31 @@ self.__precacheManifest = (self.__precacheManifest || []).concat([ { - "revision": "ba3b3e3f384943787e811c62eccec887", + "revision": "e8410b8abc4e6c874746074f1ef35bf9", "url": "./index.html" }, { - "revision": "c3ee6c87dbc3923ae3f0", - "url": "./static/css/2.d11a7e4e.chunk.css" + "revision": "2034190b1d0b9d39afd6", + "url": "./static/css/2.d6e5dedb.chunk.css" }, { - "revision": "2a51e5c61ebd858a0783", - "url": "./static/css/main.5ed7d0b8.chunk.css" + "revision": "788340c49a67ce0d6048", + "url": "./static/css/main.8cf1853d.chunk.css" }, { - "revision": "53077675cd7234567164f167c460753a", - "url": "./static/js/0.93946bfa.chunk.worker.js" + "revision": "b21ec4b5908979b4be371cfeace388a5", + "url": "./static/js/0.25e92e06.chunk.worker.js" }, { - "revision": "9abfbe313e2fa0cf9c83a1d9fe44130d", - "url": "./static/js/1.c35c4076.chunk.worker.js" + "revision": "53077675cd7234567164f167c460753a", + "url": "./static/js/1.8958a83b.chunk.worker.js" }, { - "revision": "c3ee6c87dbc3923ae3f0", - "url": "./static/js/2.0eda3dfb.chunk.js" + "revision": "2034190b1d0b9d39afd6", + "url": "./static/js/2.6c1f724b.chunk.js" }, { - "revision": "2a51e5c61ebd858a0783", - "url": "./static/js/main.8315af75.chunk.js" + "revision": "788340c49a67ce0d6048", + "url": "./static/js/main.7258aa44.chunk.js" }, { "revision": "f8219e59cd933c2cdcd1", diff --git a/docs/service-worker.js b/docs/service-worker.js index 7d8d82b..5b42eec 100644 --- a/docs/service-worker.js +++ b/docs/service-worker.js @@ -14,7 +14,7 @@ importScripts("https://storage.googleapis.com/workbox-cdn/releases/4.3.1/workbox-sw.js"); importScripts( - "./precache-manifest.44dc60c9a1c8704985ff2b50bfda71ad.js" + "./precache-manifest.c322e6b0812dcfeebef3ebf4ff2d41b0.js" ); self.addEventListener('message', (event) => { diff --git a/docs/static/css/2.d11a7e4e.chunk.css b/docs/static/css/2.d11a7e4e.chunk.css deleted file mode 100644 index 67ff27c..0000000 --- a/docs/static/css/2.d11a7e4e.chunk.css +++ /dev/null @@ -1,2 +0,0 @@ - -/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,footer,header,nav,section{display:block}h1{font-size:2em;margin:.67em 0}figcaption,figure,main{display:block}figure{margin:1em 40px}hr{box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent;-webkit-text-decoration-skip:objects}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:inherit;font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}dfn{font-style:italic}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}audio,video{display:inline-block}audio:not([controls]){display:none;height:0}img{border-style:none}svg:not(:root){overflow:hidden}button,input,optgroup,select,textarea{font-family:sans-serif;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{display:inline-block;vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details,menu{display:block}summary{display:list-item}canvas{display:inline-block}[hidden],template{display:none}.am-fade-appear,.am-fade-enter{opacity:0}.am-fade-appear,.am-fade-enter,.am-fade-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-fade-appear.am-fade-appear-active,.am-fade-enter.am-fade-enter-active{-webkit-animation-name:amFadeIn;animation-name:amFadeIn;-webkit-animation-play-state:running;animation-play-state:running}.am-fade-leave.am-fade-leave-active{-webkit-animation-name:amFadeOut;animation-name:amFadeOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amFadeIn{0%{opacity:0}to{opacity:1}}@keyframes amFadeIn{0%{opacity:0}to{opacity:1}}@-webkit-keyframes amFadeOut{0%{opacity:1}to{opacity:0}}@keyframes amFadeOut{0%{opacity:1}to{opacity:0}}.am-slide-up-appear,.am-slide-up-enter{-webkit-transform:translateY(100%);transform:translateY(100%)}.am-slide-up-appear,.am-slide-up-enter,.am-slide-up-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-slide-up-appear.am-slide-up-appear-active,.am-slide-up-enter.am-slide-up-enter-active{-webkit-animation-name:amSlideUpIn;animation-name:amSlideUpIn;-webkit-animation-play-state:running;animation-play-state:running}.am-slide-up-leave.am-slide-up-leave-active{-webkit-animation-name:amSlideUpOut;animation-name:amSlideUpOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amSlideUpIn{0%{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@keyframes amSlideUpIn{0%{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@-webkit-keyframes amSlideUpOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes amSlideUpOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}.am.am-zoom-enter,.am.am-zoom-leave{display:block}.am-zoom-appear,.am-zoom-enter{opacity:0;-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-timing-function:cubic-bezier(.18,.89,.32,1.28);animation-timing-function:cubic-bezier(.18,.89,.32,1.28);-webkit-animation-play-state:paused;animation-play-state:paused}.am-zoom-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-timing-function:cubic-bezier(.6,-.3,.74,.05);animation-timing-function:cubic-bezier(.6,-.3,.74,.05);-webkit-animation-play-state:paused;animation-play-state:paused}.am-zoom-appear.am-zoom-appear-active,.am-zoom-enter.am-zoom-enter-active{-webkit-animation-name:amZoomIn;animation-name:amZoomIn;-webkit-animation-play-state:running;animation-play-state:running}.am-zoom-leave.am-zoom-leave-active{-webkit-animation-name:amZoomOut;animation-name:amZoomOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amZoomIn{0%{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}to{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}}@keyframes amZoomIn{0%{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}to{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}}@-webkit-keyframes amZoomOut{0%{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}}@keyframes amZoomOut{0%{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}}.am-slide-down-appear,.am-slide-down-enter{-webkit-transform:translateY(-100%);transform:translateY(-100%)}.am-slide-down-appear,.am-slide-down-enter,.am-slide-down-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-slide-down-appear.am-slide-down-appear-active,.am-slide-down-enter.am-slide-down-enter-active{-webkit-animation-name:amSlideDownIn;animation-name:amSlideDownIn;-webkit-animation-play-state:running;animation-play-state:running}.am-slide-down-leave.am-slide-down-leave-active{-webkit-animation-name:amSlideDownOut;animation-name:amSlideDownOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amSlideDownIn{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@keyframes amSlideDownIn{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@-webkit-keyframes amSlideDownOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes amSlideDownOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}*,:after,:before{-webkit-tap-highlight-color:rgba(0,0,0,0)}body{background-color:#f5f5f9;font-size:14px}[contenteditable]{-webkit-user-select:auto!important}:focus,a{outline:none}a{background:transparent;text-decoration:none}.am-whitespace.am-whitespace-xs{height:3px}.am-whitespace.am-whitespace-sm{height:6px}.am-whitespace.am-whitespace-md{height:9px}.am-whitespace.am-whitespace-lg{height:15px}.am-whitespace.am-whitespace-xl{height:21px}.am-card{min-height:96px;padding-bottom:6px;display:flex;flex-direction:column;background-color:#fff}.am-card:not(.am-card-full){border:1px solid #ddd;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card:not(.am-card-full){position:relative;border:none}html:not([data-scale]) .am-card:not(.am-card-full):before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-card.am-card-full{position:relative;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card.am-card-full{border-top:none}html:not([data-scale]) .am-card.am-card-full:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card.am-card-full:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card.am-card-full{border-bottom:none}html:not([data-scale]) .am-card.am-card-full:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card.am-card-full:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-card-header{display:flex;align-items:center;font-size:17px;padding:9px 15px}.am-card-header-content{flex:1 1;text-align:left;color:#000;display:flex;align-items:center}.am-card-header-content img{margin-right:5px}.am-card-header-extra{flex:1 1;text-align:right;font-size:17px;color:#888}.am-card-body{position:relative;border-top:1px solid #ddd;padding:15px 15px 6px;font-size:15px;color:#333;min-height:40px;flex:1 1}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card-body{border-top:none}html:not([data-scale]) .am-card-body:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card-body:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-card-footer{font-size:14px;color:#888;padding:0 15px;display:flex}.am-card-footer-content{flex:1 1}.am-card-footer-extra{flex:1 1;text-align:right}.am-navbar{display:flex;align-items:center;height:45px;background-color:#108ee9;color:#fff}.am-navbar-left,.am-navbar-right,.am-navbar-title{flex:1 1;height:100%;display:flex;align-items:center}.am-navbar-left{padding-left:15px;font-size:16px}.am-navbar-left-icon{margin-right:5px;display:inherit}.am-navbar-title{justify-content:center;font-size:18px;white-space:nowrap}.am-navbar-right{justify-content:flex-end;font-size:16px;margin-right:15px}.am-navbar-light{background-color:#fff;color:#108ee9}.am-navbar-light .am-navbar-title{color:#000}.am-swipe{overflow:hidden;position:relative}.am-swipe-content{position:relative;background-color:#fff}.am-swipe-cover{position:absolute;z-index:2;background:transparent;height:100%;width:100%;top:0;display:none}.am-swipe .am-swipe-actions,.am-swipe .am-swipe-content{-webkit-transition:all .25s;transition:all .25s}.am-swipe-swiping .am-swipe-actions,.am-swipe-swiping .am-swipe-content{-webkit-transition:none;transition:none}.am-swipe-swiping .am-list-item-active{background-color:#fff}.am-swipe-actions{position:absolute;top:0;bottom:0;display:flex;overflow:hidden;white-space:nowrap}.am-swipe-actions-left{left:0}.am-swipe-actions-right{right:0}.am-swipe-btn{display:flex;align-items:center;justify-content:center;overflow:hidden}.am-swipe-btn-text{padding:0 8px}.am-badge{position:relative;display:inline-block;line-height:1;vertical-align:middle}.am-badge-text{text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;position:absolute;top:-6px;height:18px;line-height:18px;min-width:9px;border-radius:12px;padding:0 5px;text-align:center;font-size:12px;color:#fff;background-color:#ff5b05;white-space:nowrap;-webkit-transform:translateX(-45%);transform:translateX(-45%);-webkit-transform-origin:-10% center;transform-origin:-10% center;z-index:10;font-family:Helvetica Neue,Helvetica,PingFang SC,Hiragino Sans GB,Microsoft YaHei,"\5FAE\8F6F\96C5\9ED1",SimSun,sans-serif}.am-badge-text a{color:#fff}.am-badge-text p{margin:0;padding:0}.am-badge-hot .am-badge-text{background-color:#f96268}.am-badge-dot{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%);-webkit-transform-origin:0 center;transform-origin:0 center;top:-4px;height:8px;width:8px;border-radius:100%;background:#ff5b05;z-index:10}.am-badge-dot-large{height:16px;width:16px}.am-badge-not-a-wrapper .am-badge-dot,.am-badge-not-a-wrapper .am-badge-text{top:auto;display:block;position:relative;-webkit-transform:translateX(0);transform:translateX(0)}.am-badge-corner{width:80px;padding:8px;position:absolute;right:-32px;top:8px;background-color:#ff5b05;color:#fff;white-space:nowrap;-webkit-transform:rotate(45deg);transform:rotate(45deg);text-align:center;font-size:15px}.am-badge-corner-wrapper{overflow:hidden}.am-icon{fill:currentColor;background-size:cover;width:22px;height:22px}.am-icon-xxs{width:15px;height:15px}.am-icon-xs{width:18px;height:18px}.am-icon-sm{width:21px;height:21px}.am-icon-md{width:22px;height:22px}.am-icon-lg{width:36px;height:36px}.am-icon-loading{-webkit-animation:cirle-anim 1s linear infinite;animation:cirle-anim 1s linear infinite}@-webkit-keyframes cirle-anim{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes cirle-anim{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.am-button{display:block;outline:0 none;-webkit-appearance:none;box-sizing:border-box;padding:0;text-align:center;font-size:18px;height:47px;line-height:47px;overflow:hidden;text-overflow:ellipsis;word-break:break-word;white-space:nowrap;color:#000;background-color:#fff;border:1px solid #ddd;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button{position:relative;border:none}html:not([data-scale]) .am-button:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-borderfix:before{-webkit-transform:scale(.49)!important;transform:scale(.49)!important}.am-button.am-button-active{background-color:#ddd}.am-button.am-button-disabled{color:rgba(0,0,0,.3);opacity:.6}.am-button-primary{color:#fff;background-color:#108ee9;border:1px solid #108ee9;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-primary{position:relative;border:none}html:not([data-scale]) .am-button-primary:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-primary.am-button-active{color:hsla(0,0%,100%,.3);background-color:#0e80d2}.am-button-primary.am-button-disabled{color:hsla(0,0%,100%,.6);opacity:.4}.am-button-ghost{color:#108ee9;background-color:transparent;border:1px solid #108ee9;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost{position:relative;border:none}html:not([data-scale]) .am-button-ghost:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-ghost.am-button-active{color:rgba(16,142,233,.6);background-color:transparent;border:1px solid rgba(16,142,233,.6);border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost.am-button-active{position:relative;border:none}html:not([data-scale]) .am-button-ghost.am-button-active:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid rgba(16,142,233,.6);border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-ghost.am-button-disabled{color:rgba(0,0,0,.1);border:1px solid rgba(0,0,0,.1);border-radius:5px;opacity:1}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost.am-button-disabled{position:relative;border:none}html:not([data-scale]) .am-button-ghost.am-button-disabled:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid rgba(0,0,0,.1);border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-warning{color:#fff;background-color:#e94f4f}.am-button-warning.am-button-active{color:hsla(0,0%,100%,.3);background-color:#d24747}.am-button-warning.am-button-disabled{color:hsla(0,0%,100%,.6);opacity:.4}.am-button-inline{display:inline-block;padding:0 15px}.am-button-inline.am-button-icon{display:inline-flex}.am-button-small{font-size:13px;height:30px;line-height:30px;padding:0 15px}.am-button-icon{display:flex;align-items:center;justify-content:center}.am-button>.am-button-icon{margin-right:.5em}.am-toast{position:fixed;width:100%;z-index:1999;font-size:14px;text-align:center}.am-toast>span{max-width:50%}.am-toast.am-toast-mask{height:100%;display:flex;justify-content:center;align-items:center;left:0;top:0}.am-toast.am-toast-mask,.am-toast.am-toast-nomask{-webkit-transform:translateZ(1px);transform:translateZ(1px)}.am-toast.am-toast-nomask{position:fixed;max-width:50%;width:auto;left:50%;top:50%}.am-toast.am-toast-nomask .am-toast-notice{-webkit-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%)}.am-toast-notice-content .am-toast-text{min-width:60px;border-radius:3px;color:#fff;background-color:rgba(58,58,58,.9);line-height:1.5;padding:9px 15px}.am-toast-notice-content .am-toast-text.am-toast-text-icon{border-radius:5px;padding:15px}.am-toast-notice-content .am-toast-text.am-toast-text-icon .am-toast-text-info{margin-top:6px}.am-modal{position:relative}.am-modal:not(.am-modal-transparent):not(.am-modal-popup){width:100%;height:100%}.am-modal-mask{position:fixed;top:0;right:0;left:0;bottom:0;height:100%;z-index:999;background-color:rgba(0,0,0,.4)}.am-modal-mask-hidden{display:none}.am-modal-wrap{position:fixed;overflow:auto;top:0;right:0;bottom:0;left:0;height:100%;z-index:999;-webkit-overflow-scrolling:touch;outline:0;display:flex;align-items:center;justify-content:center;-webkit-transform:translateZ(1px);transform:translateZ(1px)}.am-modal-wrap-popup{display:block}.am-modal-transparent{width:270px}.am-modal-transparent .am-modal-content{border-radius:7px;padding-top:15px}.am-modal-transparent .am-modal-content .am-modal-body{padding:0 15px 15px}.am-modal-popup{position:fixed;left:0;width:100%}.am-modal-popup-slide-down{top:0}.am-modal-popup-slide-up{bottom:0}.am-modal-popup .am-modal-content{padding-bottom:env(safe-area-inset-bottom)}.am-modal-title{margin:0;font-size:18px;line-height:1;color:#000;text-align:center}.am-modal-header{padding:6px 15px 15px}.am-modal-content{position:relative;background-color:#fff;border:0;background-clip:padding-box;text-align:center;height:100%;overflow:hidden}.am-modal-close{border:0;padding:0;background-color:transparent;outline:none;position:absolute;right:15px;z-index:999;height:21px;width:21px}.am-modal-close-x{display:inline-block;width:15px;height:15px;background-repeat:no-repeat;background-size:cover;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='30' height='30' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23888' fill-rule='evenodd'%3E%3Cpath d='M1.414 0l28.284 28.284-1.414 1.414L0 1.414z'/%3E%3Cpath d='M28.284 0L0 28.284l1.414 1.414L29.698 1.414z'/%3E%3C/g%3E%3C/svg%3E")}.am-modal-body{font-size:15px;color:#888;height:100%;line-height:1.5;overflow:auto}.am-modal-button-group-h{position:relative;border-top:1px solid #ddd;display:flex}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-h{border-top:none}html:not([data-scale]) .am-modal-button-group-h:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-h:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-button-group-h .am-modal-button{-webkit-touch-callout:none;flex:1 1;box-sizing:border-box;text-align:center;text-decoration:none;outline:none;color:#108ee9;font-size:18px;height:50px;line-height:50px;display:block;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-modal-button-group-h .am-modal-button:first-child{color:#000}.am-modal-button-group-h .am-modal-button:last-child{position:relative;border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child{border-left:none}html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-modal-button-group-v .am-modal-button{-webkit-touch-callout:none;position:relative;border-top:1px solid #ddd;box-sizing:border-box;text-align:center;text-decoration:none;outline:none;color:#108ee9;font-size:18px;height:50px;line-height:50px;display:block;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-v .am-modal-button{border-top:none}html:not([data-scale]) .am-modal-button-group-v .am-modal-button:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-v .am-modal-button:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-button-active{background-color:#ddd}.am-modal-input-container{margin-top:9px;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-input-container{position:relative;border:none}html:not([data-scale]) .am-modal-input-container:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-modal-input{height:36px;line-height:1}.am-modal-input:nth-child(2){position:relative;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-input:nth-child(2){border-top:none}html:not([data-scale]) .am-modal-input:nth-child(2):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-input:nth-child(2):before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-input input{position:relative;border:0;width:98%;height:34px;top:1PX;box-sizing:border-box;margin:0}.am-modal-input input::-webkit-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::-moz-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::-ms-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input:-ms-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content{border-radius:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-header{padding:9px 24px 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-header .am-modal-title{text-align:left;font-size:21px;color:#000}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body{color:#000;text-align:left;padding:0 24px 15px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container{border:0;border-bottom:1px solid #ddd}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:before{display:none!important}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container{border-bottom:none}html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container .am-modal-input:first-child{border-top:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container .am-modal-input:first-child:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer{padding-bottom:12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h{overflow:hidden;border-top:0;justify-content:flex-end;padding:0 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button{flex:initial;margin-left:3px;padding:0 15px;height:48px;box-sizing:border-box}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:first-child{color:#777}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:last-child{border-left:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:last-child:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal{display:flex;justify-content:flex-end;overflow:hidden;padding:0 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal .am-modal-button{border-top:0;padding:0 15px;margin-left:3px;height:48px;box-sizing:border-box}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal .am-modal-button:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-operation .am-modal-button{text-align:start;padding-left:15px}.am-modal.am-modal-operation .am-modal-content{border-radius:7px;height:auto;padding-top:0}.am-modal.am-modal-operation .am-modal-content .am-modal-body{padding:0!important}.am-modal.am-modal-operation .am-modal-content .am-modal-button{color:#000;text-align:left;padding-left:15px}.am-modal-alert-content,.am-modal-propmt-content{zoom:1;overflow:hidden}.am-list-header{padding:15px 15px 9px;font-size:14px;color:#888;width:100%;box-sizing:border-box}.am-list-footer{padding:9px 15px 15px;font-size:14px;color:#888}.am-list-body{position:relative;background-color:#fff;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body{border-top:none}html:not([data-scale]) .am-list-body:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body{border-bottom:none}html:not([data-scale]) .am-list-body:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-body div:not(:last-child) .am-list-line{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line{border-bottom:none}html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-item{position:relative;display:flex;padding-left:15px;min-height:44px;background-color:#fff;vertical-align:middle;overflow:hidden;-webkit-transition:background-color .2s;transition:background-color .2s;align-items:center}.am-list-item .am-list-ripple{position:absolute;background:transparent;display:inline-block;overflow:hidden;will-change:box-shadow,transform;-webkit-transition:background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1),-webkit-box-shadow .2s cubic-bezier(.4,0,1,1);-webkit-transition:box-shadow .2s cubic-bezier(.4,0,1,1),background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1);transition:box-shadow .2s cubic-bezier(.4,0,1,1),background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1);outline:none;cursor:pointer;border-radius:100%;-webkit-transform:scale(0);transform:scale(0)}.am-list-item .am-list-ripple.am-list-ripple-animate{background-color:hsla(0,0%,62%,.2);-webkit-animation:ripple 1s linear;animation:ripple 1s linear}.am-list-item.am-list-item-top .am-list-line{align-items:flex-start}.am-list-item.am-list-item-top .am-list-line .am-list-arrow{margin-top:2px}.am-list-item.am-list-item-middle .am-list-line{align-items:center}.am-list-item.am-list-item-bottom .am-list-line{align-items:flex-end}.am-list-item.am-list-item-error .am-list-line .am-list-extra,.am-list-item.am-list-item-error .am-list-line .am-list-extra .am-list-brief{color:#f50}.am-list-item.am-list-item-active{background-color:#ddd}.am-list-item.am-list-item-disabled .am-list-line .am-list-content,.am-list-item.am-list-item-disabled .am-list-line .am-list-extra{color:#bbb}.am-list-item img{width:22px;height:22px;vertical-align:middle}.am-list-item .am-list-thumb:first-child{margin-right:15px}.am-list-item .am-list-thumb:last-child{margin-left:8px}.am-list-item .am-list-line{position:relative;display:flex;flex:1 1;align-self:stretch;padding-right:15px;overflow:hidden}.am-list-item .am-list-line .am-list-content{flex:1 1;color:#000;font-size:17px;text-align:left}.am-list-item .am-list-line .am-list-content,.am-list-item .am-list-line .am-list-extra{line-height:1.5;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding-top:7px;padding-bottom:7px}.am-list-item .am-list-line .am-list-extra{flex-basis:36%;color:#888;font-size:16px;text-align:right}.am-list-item .am-list-line .am-list-brief,.am-list-item .am-list-line .am-list-title{width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-list-item .am-list-line .am-list-brief{color:#888;font-size:15px;line-height:1.5;margin-top:6px}.am-list-item .am-list-line .am-list-arrow{display:block;width:15px;height:15px;margin-left:8px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='16' height='26' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 0L0 2l11.5 11L0 24l2 2 14-13z' fill='%23C7C7CC' fill-rule='evenodd'/%3E%3C/svg%3E");background-size:contain;background-repeat:no-repeat;background-position:50% 50%;visibility:hidden}.am-list-item .am-list-line .am-list-arrow-horizontal{visibility:visible}.am-list-item .am-list-line .am-list-arrow-vertical{visibility:visible;-webkit-transform:rotate(90deg);transform:rotate(90deg)}.am-list-item .am-list-line .am-list-arrow-vertical-up{visibility:visible;-webkit-transform:rotate(270deg);transform:rotate(270deg)}.am-list-item .am-list-line-multiple{padding:12.5px 15px 12.5px 0}.am-list-item .am-list-line-multiple .am-list-content,.am-list-item .am-list-line-multiple .am-list-extra{padding-top:0;padding-bottom:0}.am-list-item .am-list-line-wrap .am-list-content,.am-list-item .am-list-line-wrap .am-list-extra{white-space:normal}.am-list-item select{position:relative;display:block;width:100%;height:100%;padding:0;border:0;font-size:17px;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent}@-webkit-keyframes ripple{to{opacity:0;-webkit-transform:scale(2.5);transform:scale(2.5)}}@keyframes ripple{to{opacity:0;-webkit-transform:scale(2.5);transform:scale(2.5)}}.am-tabs{display:flex;flex:1 1;position:relative;overflow:hidden;height:100%;width:100%}.am-tabs,.am-tabs *{box-sizing:border-box}.am-tabs-content-wrap{display:flex;flex:1 1;width:100%;height:100%;min-height:0}.am-tabs-content-wrap-animated{-webkit-transition:left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);will-change:transform,left,top}.am-tabs-pane-wrap{width:100%;flex-shrink:0;overflow-y:auto}.am-tabs-tab-bar-wrap{flex-shrink:0}.am-tabs-horizontal .am-tabs-pane-wrap-active{height:auto}.am-tabs-horizontal .am-tabs-pane-wrap-inactive{height:0;overflow:visible}.am-tabs-vertical .am-tabs-content-wrap{flex-direction:column}.am-tabs-vertical .am-tabs-pane-wrap,.am-tabs-vertical .am-tabs-tab-bar-wrap{height:100%}.am-tabs-vertical .am-tabs-pane-wrap-active{overflow:auto}.am-tabs-vertical .am-tabs-pane-wrap-inactive{overflow:hidden}.am-tabs-bottom,.am-tabs-top{flex-direction:column}.am-tabs-left,.am-tabs-right{flex-direction:row}.am-tabs-default-bar{position:relative;display:flex;flex-shrink:0;flex-direction:row;width:100%;height:100%;overflow:visible;z-index:1}.am-tabs-default-bar-tab{position:relative;display:flex;flex-shrink:0;justify-content:center;align-items:center;font-size:15px;height:43.5px;line-height:43.5px}.am-tabs-default-bar-tab .am-badge .am-badge-text{top:-13px;-webkit-transform:translateX(-5px);transform:translateX(-5px)}.am-tabs-default-bar-tab .am-badge .am-badge-dot{top:-6px;-webkit-transform:translateX(0);transform:translateX(0)}.am-tabs-default-bar-tab-active{color:#108ee9}.am-tabs-default-bar-underline{position:absolute;border:1px solid #108ee9;-webkit-transform:translateZ(0);transform:translateZ(0)}.am-tabs-default-bar-animated .am-tabs-default-bar-content{-webkit-transition:-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);will-change:transform}.am-tabs-default-bar-animated .am-tabs-default-bar-underline{-webkit-transition:top .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),color .3s cubic-bezier(.35,0,.25,1),width .3s cubic-bezier(.35,0,.25,1);transition:top .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),color .3s cubic-bezier(.35,0,.25,1),width .3s cubic-bezier(.35,0,.25,1);will-change:top,left,width,color}.am-tabs-default-bar-bottom,.am-tabs-default-bar-top{flex-direction:row}.am-tabs-default-bar-bottom .am-tabs-default-bar-content,.am-tabs-default-bar-top .am-tabs-default-bar-content{display:flex;width:100%;flex-direction:row}.am-tabs-default-bar-bottom .am-tabs-default-bar-prevpage,.am-tabs-default-bar-top .am-tabs-default-bar-prevpage{pointer-events:none;position:absolute;top:0;display:block;width:59px;height:100%;content:" ";z-index:999;left:0;background:-webkit-gradient(linear,left top,right top,from(#fff),to(hsla(0,0%,100%,0)));background:linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.am-tabs-default-bar-bottom .am-tabs-default-bar-nextpage,.am-tabs-default-bar-top .am-tabs-default-bar-nextpage{pointer-events:none;position:absolute;top:0;display:block;width:59px;height:100%;content:" ";z-index:999;right:0;background:-webkit-gradient(linear,left top,right top,from(hsla(0,0%,100%,0)),to(#fff));background:linear-gradient(90deg,hsla(0,0%,100%,0),#fff)}.am-tabs-default-bar-bottom .am-tabs-default-bar-tab,.am-tabs-default-bar-top .am-tabs-default-bar-tab{padding:8px 0}.am-tabs-default-bar-bottom .am-tabs-default-bar-underline,.am-tabs-default-bar-top .am-tabs-default-bar-underline{bottom:0}.am-tabs-default-bar-top .am-tabs-default-bar-tab{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab{border-bottom:none}html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tabs-default-bar-bottom .am-tabs-default-bar-tab{border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab{border-top:none}html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tabs-default-bar-left,.am-tabs-default-bar-right{flex-direction:column}.am-tabs-default-bar-left .am-tabs-default-bar-content,.am-tabs-default-bar-right .am-tabs-default-bar-content{display:flex;height:100%;flex-direction:column}.am-tabs-default-bar-left .am-tabs-default-bar-tab,.am-tabs-default-bar-right .am-tabs-default-bar-tab{padding:0 8px}.am-tabs-default-bar-left .am-tabs-default-bar-underline{right:0}.am-tabs-default-bar-left .am-tabs-default-bar-tab{border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab{border-right:none}html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab:after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-tabs-default-bar-right .am-tabs-default-bar-underline{left:0}.am-tabs-default-bar-right .am-tabs-default-bar-tab{border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab{border-left:none}html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-tab-bar{height:100%;overflow:hidden}.am-tab-bar-bar{position:relative;box-sizing:border-box;height:50px;border-top:1px solid #ddd;width:100%;display:flex;-webkit-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:height bottom;transition-property:height bottom;z-index:100;justify-content:space-around;align-items:center;bottom:0}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tab-bar-bar{border-top:none}html:not([data-scale]) .am-tab-bar-bar:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tab-bar-bar:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tab-bar-bar-hidden-top{bottom:50px;height:0}.am-tab-bar-bar-hidden-bottom{bottom:-50px;height:0}.am-tab-bar-bar .am-tab-bar-tab{flex:1 1;display:flex;justify-content:center;align-items:center;flex-direction:column;text-align:center;width:100%}.am-tab-bar-bar .am-tab-bar-tab-image{width:22px;height:22px;vertical-align:middle}.am-tab-bar-bar .am-tab-bar-tab-title{font-size:10px;margin:3px 0 0;line-height:1;text-align:center}.am-tab-bar-bar .am-tab-bar-tab-icon{display:flex;justify-content:center}.am-tab-bar-bar .am-tab-bar-tab-icon .tab-badge :last-child,.am-tab-bar-bar .am-tab-bar-tab-icon .tab-dot :last-child{margin-top:4px;left:22px}.am-tab-bar-item{height:100%}.am-wingblank{margin-left:8px;margin-right:8px}.am-wingblank.am-wingblank-sm{margin-left:5px;margin-right:5px}.am-wingblank.am-wingblank-md{margin-left:8px;margin-right:8px}.am-wingblank.am-wingblank-lg{margin-left:15px;margin-right:15px}.am-list-item .am-input-control .fake-input-container{height:30px;line-height:30px;position:relative}.am-list-item .am-input-control .fake-input-container .fake-input{position:absolute;top:0;left:0;width:100%;height:100%;margin-right:5px;-webkit-text-decoration:rtl;text-decoration:rtl;text-align:right;color:#000;font-size:17px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-list-item .am-input-control .fake-input-container .fake-input.fake-input-disabled{color:#bbb}.am-list-item .am-input-control .fake-input-container .fake-input.focus{-webkit-transition:color .2s;transition:color .2s}.am-list-item .am-input-control .fake-input-container .fake-input.focus:after{content:"";position:absolute;right:0;top:10%;height:80%;border-right:1.5px solid #108ee9;-webkit-animation:keyboard-cursor 1s step-start infinite;animation:keyboard-cursor 1s step-start infinite}.am-list-item .am-input-control .fake-input-container .fake-input-placeholder{position:absolute;top:0;left:0;width:100%;height:100%;color:#bbb;text-align:right}.am-list-item .am-input-control .fake-input-container-left .fake-input{text-align:left}.am-list-item .am-input-control .fake-input-container-left .fake-input.focus:after{position:relative}.am-list-item .am-input-control .fake-input-container-left .fake-input-placeholder{text-align:left}.am-number-keyboard-wrapper{position:fixed;bottom:0;left:0;right:0;width:100%;z-index:10000;font-family:PingFang SC;background-color:#f6f6f7;-webkit-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:-webkit-transform display;transition-property:-webkit-transform display;transition-property:transform display;transition-property:transform display,-webkit-transform display;-webkit-transform:translateZ(0);transform:translateZ(0);padding-bottom:env(safe-area-inset-bottom)}.am-number-keyboard-wrapper.am-number-keyboard-wrapper-hide{bottom:-500px}.am-number-keyboard-wrapper table{width:100%;padding:0;margin:0;border-collapse:collapse;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table{border-top:none}html:not([data-scale]) .am-number-keyboard-wrapper table:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr{width:100%;padding:0;margin:0}.am-number-keyboard-wrapper table tr .am-number-keyboard-item{width:25%;padding:0;margin:0;height:50px;text-align:center;font-size:25.5px;color:#2a2b2c;position:relative}.am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-left:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-left:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-bottom:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.am-number-keyboard-item-active{background-color:#ddd}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm{color:#fff;font-size:21px;background-color:#108ee9;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm{border-bottom:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm.am-number-keyboard-item-active{background-color:#0e80d2}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm.am-number-keyboard-item-disabled{background-color:#0e80d2;color:hsla(0,0%,100%,.45)}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-delete{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg version='1' xmlns='http://www.w3.org/2000/svg' width='204' height='148' viewBox='0 0 153 111'%3E%3Cpath d='M46.9 4.7c-2.5 2.6-14.1 15.5-25.8 28.6L-.1 57l25.6 27 25.7 27.1 47.4-.3 47.4-.3 3.2-3.3 3.3-3.2V7l-3.3-3.2L146 .5 98.7.2 51.5-.1l-4.6 4.8zm97.9 3.5c1.7 1.7 1.7 92.9 0 94.6-.9.9-12.6 1.2-46.3 1.2H53.4L31.2 80.4 9 56.9l5.1-5.7c2.8-3.1 12.8-14.4 22.2-24.9L53.5 7h45c33.8 0 45.4.3 46.3 1.2z'/%3E%3Cpath d='M69.5 31c-1.9 2.1-1.7 2.2 9.3 13.3L90 55.5 78.8 66.7 67.5 78l2.3 2.2 2.2 2.3 11.3-11.3L94.5 60l11.2 11.2L117 82.5l2.2-2.3 2.3-2.2-11.3-11.3L99 55.5l11.2-11.2L121.5 33l-2.3-2.2-2.2-2.3-11.3 11.3L94.5 51l-11-11c-6-6-11.2-11-11.6-11-.3 0-1.4.9-2.4 2z'/%3E%3C/svg%3E");background-size:25.5px 18.5px;background-position:50% 50%;background-repeat:no-repeat}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-hide{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg version='1' xmlns='http://www.w3.org/2000/svg' width='260' height='188' viewBox='0 0 195 141'%3E%3Cpath d='M0 57v57h195V0H0v57zm183 0v45H12V12h171v45z'/%3E%3Cpath d='M21 31.5V39h15V24H21v7.5zm27 0V39h15V24H48v7.5zm27 0V39h15V24H75v7.5zm27 0V39h15V24h-15v7.5zm27 0V39h15V24h-15v7.5zm27 0V39h15V24h-15v7.5zm-120 24V63h15V48H36v7.5zm27 0V63h15V48H63v7.5zm27 0V63h15V48H90v7.5zm27 0V63h15V48h-15v7.5zm27 0V63h15V48h-15v7.5zm-117 24V87h15V72H27v7.5zm21 0V87h96V72H48v7.5zm102 0V87h15V72h-15v7.5zm-69 45c0 .8.7 1.5 1.5 1.5s1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5c0-1.3-2.5-1.5-16.5-1.5s-16.5.2-16.5 1.5z'/%3E%3C/svg%3E");background-size:32.5px 23.5px;background-position:50% 50%;background-repeat:no-repeat}.am-number-keyboard-wrapper table tr .am-number-keyboard-item-disabled{color:#bbb}@-webkit-keyframes keyboard-cursor{0%{opacity:1}50%{opacity:0}to{opacity:1}}@keyframes keyboard-cursor{0%{opacity:1}50%{opacity:0}to{opacity:1}}.am-list-item.am-input-item{height:44px;padding-left:15px}.am-list-item:not(:last-child) .am-list-line{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line{border-bottom:none}html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-item .am-input-label{color:#000;font-size:17px;margin-left:0;margin-right:5px;text-align:left;white-space:nowrap;overflow:hidden;padding:2px 0}.am-list-item .am-input-label.am-input-label-2{width:34px}.am-list-item .am-input-label.am-input-label-3{width:51px}.am-list-item .am-input-label.am-input-label-4{width:68px}.am-list-item .am-input-label.am-input-label-5{width:85px}.am-list-item .am-input-label.am-input-label-6{width:102px}.am-list-item .am-input-label.am-input-label-7{width:119px}.am-list-item .am-input-control{font-size:17px;flex:1 1}.am-list-item .am-input-control input{color:#000;font-size:17px;-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;padding:2px 0;border:0;background-color:transparent;line-height:1;box-sizing:border-box}.am-list-item .am-input-control input::-webkit-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::-moz-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::-ms-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input:-ms-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input:disabled{color:#bbb;background-color:#fff}.am-list-item .am-input-clear{display:none;width:21px;height:21px;border-radius:50%;overflow:hidden;font-style:normal;color:#fff;background-color:#ccc;background-repeat:no-repeat;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg fill='%23fff' viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3Cpath d='M0 0h24v24H0z' fill='none'/%3E%3C/svg%3E");background-size:21px auto;background-position:2px 2px}.am-list-item .am-input-clear-active{background-color:#108ee9}.am-list-item.am-input-focus .am-input-clear{display:block}.am-list-item .am-input-extra{flex:initial;min-width:0;max-height:21px;overflow:hidden;padding-right:0;line-height:1;color:#888;font-size:15px;margin-left:5px}.am-list-item.am-input-error .am-input-control input{color:#f50}.am-list-item.am-input-error .am-input-error-extra{height:21px;width:21px;margin-left:6px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='18' height='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9 1.266a7.69 7.69 0 015.469 2.264c.71.71 1.269 1.538 1.657 2.459.404.954.608 1.967.608 3.011a7.69 7.69 0 01-2.264 5.469 7.694 7.694 0 01-2.459 1.657A7.675 7.675 0 019 16.734a7.69 7.69 0 01-5.469-2.264 7.694 7.694 0 01-1.657-2.459A7.675 7.675 0 011.266 9 7.69 7.69 0 013.53 3.531a7.694 7.694 0 012.459-1.657A7.675 7.675 0 019 1.266zM9 0a9 9 0 00-9 9 9 9 0 009 9 9 9 0 009-9 9 9 0 00-9-9zm0 11.25a.703.703 0 01-.703-.703V4.06a.703.703 0 111.406 0v6.486A.703.703 0 019 11.25zm-.791 1.916a.791.791 0 111.582 0 .791.791 0 01-1.582 0z' fill='%23F50' fill-rule='evenodd'/%3E%3C/svg%3E");background-size:21px auto}.am-list-item.am-input-disabled .am-input-label{color:#bbb}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.am-tag{display:inline-block;position:relative;font-size:14px;text-align:center;padding:0 15px;height:25px;line-height:25px;box-sizing:border-box}.am-tag.am-tag-small{height:15px;line-height:15px;padding:0 5px;font-size:10px}.am-tag-normal{background-color:#fff;color:#888;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-normal{position:relative;border:none}html:not([data-scale]) .am-tag-normal:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-active{background-color:#fff;color:#108ee9;border:1px solid #108ee9;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-active{position:relative;border:none}html:not([data-scale]) .am-tag-active:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-disabled{color:#bbb;background-color:#ddd;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-disabled{position:relative;border:none}html:not([data-scale]) .am-tag-disabled:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-close{position:absolute;top:-9px;left:-10px;color:#bbb}.am-tag-close-active{color:#888}.am-tag-close .am-icon{background-color:#fff;border-radius:9px}.am-notice-bar{background-color:#fefcec;height:36px;overflow:hidden;font-size:14px;line-height:36px;color:#f76a24;display:flex}.am-notice-bar-content{flex:1 1;width:100%;margin:auto 15px;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-notice-bar-icon{margin-left:15px;display:flex;align-items:center}.am-notice-bar-icon .am-notice-bar-trips{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='38' height='33' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill-rule='evenodd'%3E%3Cpath d='M17.838 28.8c-.564-.468-1.192-.983-1.836-1.496-4.244-3.385-5.294-3.67-6.006-3.67-.014 0-.027.005-.04.005-.015 0-.028-.005-.042-.005H3.562c-.734 0-.903-.203-.903-.928V10.085c0-.49.058-.8.66-.8h5.782c.693 0 1.758-.28 6.4-3.628.828-.597 1.637-1.197 2.336-1.723V28.8zM19.682.19a1.36 1.36 0 00-1.417.157c-.02.016-1.983 1.552-4.152 3.125C10.34 6.21 9.243 6.664 9.02 6.737H3.676c-.027 0-.053.003-.08.004H1.183c-.608 0-1.1.486-1.1 1.085V25.14c0 .598.492 1.084 1.1 1.084h8.71c.22.08 1.257.55 4.605 3.24 1.947 1.562 3.694 3.088 3.712 3.103a1.362 1.362 0 001.44.217c.48-.213.79-.684.79-1.204V1.38c0-.506-.294-.968-.758-1.19z' mask='url(%23mask-2)'/%3E%3Cpath d='M31.42 16.475c0-3.363-1.854-6.297-4.606-7.876-.125-.066-.42-.192-.625-.192a1.1 1.1 0 00-1.108 1.09c0 .404.22.764.55.952 2.128 1.19 3.565 3.442 3.565 6.025 0 2.627-1.486 4.913-3.677 6.087-.318.19-.53.54-.53.934 0 .602.496 1.09 1.107 1.09.26.002.568-.15.568-.15 2.835-1.556 4.754-4.538 4.754-7.96' mask='url(%23mask-4)'/%3E%3Cpath d='M30.14 3.057c-.205-.122-.41-.22-.658-.22-.608 0-1.1.485-1.1 1.084 0 .433.26.78.627.977 4.043 2.323 6.762 6.636 6.762 11.578 0 4.938-2.716 9.248-6.755 11.572-.354.19-.66.55-.66.993 0 .6.494 1.084 1.102 1.084.243 0 .438-.092.65-.213 4.692-2.695 7.848-7.7 7.848-13.435 0-5.723-3.142-10.718-7.817-13.418' mask='url(%23mask-6)'/%3E%3C/g%3E%3C/svg%3E")}.am-notice-bar-icon+div{margin-left:5px}.am-notice-bar-operation{display:flex;align-items:center;padding-right:8px}.am-flexbox{text-align:left;overflow:hidden;display:flex;align-items:center}.am-flexbox.am-flexbox-dir-row{flex-direction:row}.am-flexbox.am-flexbox-dir-row-reverse{flex-direction:row-reverse}.am-flexbox.am-flexbox-dir-column{flex-direction:column}.am-flexbox.am-flexbox-dir-column .am-flexbox-item{margin-left:0}.am-flexbox.am-flexbox-dir-column-reverse{flex-direction:column-reverse}.am-flexbox.am-flexbox-dir-column-reverse .am-flexbox-item{margin-left:0}.am-flexbox.am-flexbox-nowrap{flex-wrap:nowrap}.am-flexbox.am-flexbox-wrap{flex-wrap:wrap}.am-flexbox.am-flexbox-wrap-reverse{flex-wrap:wrap-reverse}.am-flexbox.am-flexbox-justify-start{justify-content:flex-start}.am-flexbox.am-flexbox-justify-end{justify-content:flex-end}.am-flexbox.am-flexbox-justify-center{justify-content:center}.am-flexbox.am-flexbox-justify-between{justify-content:space-between}.am-flexbox.am-flexbox-justify-around{justify-content:space-around}.am-flexbox.am-flexbox-align-start{align-items:flex-start}.am-flexbox.am-flexbox-align-end{align-items:flex-end}.am-flexbox.am-flexbox-align-center{align-items:center}.am-flexbox.am-flexbox-align-stretch{align-items:stretch}.am-flexbox.am-flexbox-align-baseline{align-items:baseline}.am-flexbox.am-flexbox-align-content-start{align-content:flex-start}.am-flexbox.am-flexbox-align-content-end{align-content:flex-end}.am-flexbox.am-flexbox-align-content-center{align-content:center}.am-flexbox.am-flexbox-align-content-between{align-content:space-between}.am-flexbox.am-flexbox-align-content-around{align-content:space-around}.am-flexbox.am-flexbox-align-content-stretch{align-content:stretch}.am-flexbox .am-flexbox-item{box-sizing:border-box;flex:1 1;margin-left:8px;min-width:10px}.am-flexbox .am-flexbox-item:first-child{margin-left:0}.am-carousel{position:relative}.am-carousel-wrap{font-size:18px;color:#000;background:none;text-align:center;zoom:1;width:100%}.am-carousel-wrap-dot{display:inline-block;zoom:1}.am-carousel-wrap-dot>span{display:block;width:8px;height:8px;margin:0 3px;border-radius:50%;background:#ccc}.am-carousel-wrap-dot-active>span{background:#888}.am-grid .am-flexbox{background:#fff}.am-grid .am-flexbox .am-flexbox-item{margin-left:0}.am-grid .am-flexbox .am-flexbox-item.am-grid-item{position:relative}.am-grid .am-flexbox .am-flexbox-item.am-grid-item-active .am-grid-item-content{background-color:#ddd}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content{text-align:center;width:100%;height:100%;padding:15px 0}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content{display:flex;flex-direction:column;justify-content:center;align-items:center}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content .am-grid-icon{max-width:100%}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content .am-grid-text{margin-top:9px;font-size:12px;color:#000;text-align:center}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content.column-num-3 .am-grid-text{font-size:16px}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content.column-num-2 .am-grid-text{margin-top:15px;font-size:18px}.am-grid.am-grid-line{position:relative}.am-grid.am-grid-line:not(.am-grid-carousel){border-top:1px solid #ddd;border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel){border-top:none}html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel){border-right:none}html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line .am-flexbox{position:relative;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox{border-bottom:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-grid.am-grid-line .am-flexbox .am-flexbox-item{position:relative}.am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child{border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child{border-left:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child){border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child){border-right:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child):after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-top:1px solid #ddd;border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-top:none}html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-right:none}html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid .am-carousel .am-carousel-wrap-dot>span{background:#dcdee3}.am-grid .am-carousel .am-carousel-wrap-dot-active>span{background:#0ae}.am-grid.am-grid-square .am-grid-item:before{display:block;content:" ";padding-bottom:100%}.am-grid.am-grid-square .am-grid-item .am-grid-item-content{position:absolute;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.am-grid.am-grid-square .am-grid-item .am-grid-item-inner-content{height:100%}.am-grid.am-grid-square .am-grid-item .am-grid-item-inner-content .am-grid-icon{margin-top:9px;width:28%!important}.am-search{display:flex;align-items:center;height:44px;padding:0 8px;background-color:#efeff4}.am-search,.am-search-input{position:relative;overflow:hidden}.am-search-input{flex:1 1;width:100%;height:28px;background-color:#fff;background-clip:padding-box;border-radius:3px}.am-search-input .am-search-synthetic-ph,.am-search-input input[type=search]{position:absolute;top:0;left:0}.am-search-input .am-search-synthetic-ph{box-sizing:content-box;z-index:1;height:28px;line-height:28px;width:100%;-webkit-transition:width .3s;transition:width .3s;display:block;text-align:center}.am-search-input .am-search-synthetic-ph-icon{display:inline-block;margin-right:5px;width:15px;height:15px;overflow:hidden;vertical-align:-2.5px;background-repeat:no-repeat;background-size:15px auto;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='38' height='36' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M29.05 25.23a15.81 15.81 0 003.004-9.294c0-8.8-7.17-15.934-16.017-15.934C7.192.002.02 7.136.02 15.936c0 8.802 7.172 15.937 16.017 15.937a16 16 0 0010.772-4.143l8.873 8.232 2.296-2.45-8.927-8.282zM16.2 28.933c-7.19 0-13.04-5.788-13.04-12.903 0-7.113 5.85-12.904 13.04-12.904 7.19 0 12.9 5.79 12.9 12.904 0 7.115-5.71 12.903-12.9 12.903z' fill='%23bbb' fill-rule='evenodd'/%3E%3C/svg%3E")}.am-search-input .am-search-synthetic-ph-placeholder{color:#bbb;font-size:15px}.am-search-input input[type=search]{z-index:2;opacity:0;width:100%;text-align:left;display:block;color:#000;height:28px;font-size:15px;background-color:transparent;border:0}.am-search-input input[type=search]::-webkit-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-moz-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-ms-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]:-ms-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-webkit-search-cancel-button{-webkit-appearance:none}.am-search-input .am-search-clear{box-sizing:content-box;position:absolute;display:none;z-index:3;width:15px;height:15px;padding:6.5px;border-radius:50%;top:0;right:0;background-color:transparent;background-position:50%;background-repeat:no-repeat;background-size:15px 15px;-webkit-transition:all .3s;transition:all .3s;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Ccircle cx='14' cy='14' r='14' fill='%23ccc'/%3E%3Cpath stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M8 8l12 12'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M20 8L8 20'/%3E%3C/svg%3E")}.am-search-input .am-search-clear-active{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Ccircle cx='14' cy='14' r='14' fill='%23108ee9'/%3E%3Cpath stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M8 8l12 12'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M20 8L8 20'/%3E%3C/svg%3E")}.am-search-input .am-search-clear-show{display:block}.am-search-cancel{flex:none;opacity:0;padding-left:8px;height:44px;line-height:44px;font-size:16px;color:#108ee9;text-align:right}.am-search-cancel-anim{-webkit-transition:margin-right .3s,opacity .3s;transition:margin-right .3s,opacity .3s;-webkit-transition-delay:.1s;transition-delay:.1s}.am-search-cancel-show{opacity:1}.am-search.am-search-start .am-search-input input[type=search]{opacity:1;padding:0 28px 0 35px}.am-search.am-search-start .am-search-input input[type=search]::-webkit-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::-moz-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::-ms-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]:-ms-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::placeholder{color:transparent}.am-search.am-search-start .am-search-input .am-search-synthetic-ph{padding-left:15px;width:auto}.am-checkbox{position:relative;display:inline-block;vertical-align:middle;width:21px;height:21px}.am-checkbox-inner{position:absolute;right:0;width:21px;height:21px;border:1px solid #ccc;border-radius:50%;-webkit-transform:rotate(0deg);transform:rotate(0deg);box-sizing:border-box}.am-checkbox-inner:after{position:absolute;display:none;top:1.5px;right:6px;z-index:999;width:5px;height:11px;border-style:solid;border-width:0 1px 1px 0;content:"\0020";-webkit-transform:rotate(45deg);transform:rotate(45deg)}.am-checkbox-input{position:absolute;top:0;left:0;opacity:0;width:100%;height:100%;z-index:2;border:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.am-checkbox.am-checkbox-checked .am-checkbox-inner{border-color:#108ee9;background:#108ee9}.am-checkbox.am-checkbox-checked .am-checkbox-inner:after{display:block;border-color:#fff}.am-checkbox.am-checkbox-disabled{opacity:.3}.am-checkbox.am-checkbox-disabled.am-checkbox-checked .am-checkbox-inner{border-color:#888;background:none}.am-checkbox.am-checkbox-disabled.am-checkbox-checked .am-checkbox-inner:after{border-color:#888}.am-list .am-list-item.am-checkbox-item .am-list-thumb{width:21px;height:21px}.am-list .am-list-item.am-checkbox-item .am-list-thumb .am-checkbox{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;height:44px}.am-list .am-list-item.am-checkbox-item .am-list-thumb .am-checkbox-inner{left:15px;top:12px}.am-list .am-list-item.am-checkbox-item.am-checkbox-item-disabled .am-list-content{color:#bbb}.am-checkbox-agree{position:relative;display:flex;align-items:stretch;margin-left:15px;padding-top:9px;padding-bottom:9px}.am-checkbox-agree .am-checkbox{position:absolute;left:0;top:0;width:30px;height:100%}.am-checkbox-agree .am-checkbox-inner{left:0;top:12px}.am-checkbox-agree .am-checkbox-agree-label{display:inline-block;font-size:15px;color:#000;line-height:1.5;margin-left:30px;margin-top:1PX}.am-list .am-list-item.am-textarea-item{display:flex;align-items:flex-start;box-sizing:border-box;min-height:44px;padding-left:15px;padding-right:15px;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list .am-list-item.am-textarea-item{border-bottom:none}html:not([data-scale]) .am-list .am-list-item.am-textarea-item:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list .am-list-item.am-textarea-item:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line{align-items:center}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-label{align-self:center}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-control{padding-top:0;padding-bottom:0}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-control textarea{line-height:25.5px}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-clear,.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line.am-textarea-error .am-textarea-error-extra{margin-top:0}.am-textarea-label{align-self:flex-start;color:#000;text-align:left;min-height:44px;font-size:17px;line-height:44px;margin-left:0;margin-right:5px;white-space:nowrap;overflow:hidden}.am-textarea-label.am-textarea-label-2{width:34px}.am-textarea-label.am-textarea-label-3{width:51px}.am-textarea-label.am-textarea-label-4{width:68px}.am-textarea-label.am-textarea-label-5{width:85px}.am-textarea-label.am-textarea-label-6{width:102px}.am-textarea-label.am-textarea-label-7{width:119px}.am-textarea-control{flex:1 1;padding-top:10px;padding-bottom:9px}.am-textarea-control textarea{color:#000;font-size:17px;line-height:25.5px;-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;padding:0;border:0;background-color:transparent;overflow:visible;display:block;resize:none;word-break:break-word;word-wrap:break-word}.am-textarea-control textarea::-webkit-input-placeholder{color:#bbb}.am-textarea-control textarea::-moz-placeholder{color:#bbb}.am-textarea-control textarea::-ms-input-placeholder{color:#bbb}.am-textarea-control textarea:-ms-input-placeholder{color:#bbb}.am-textarea-control textarea::placeholder{color:#bbb}.am-textarea-control textarea:disabled{color:#bbb;background-color:#fff}.am-textarea-clear{display:none;width:21px;height:21px;margin-top:12px;border-radius:50%;overflow:hidden;font-style:normal;color:#fff;background-color:#ccc;background-repeat:no-repeat;background-size:21px auto;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg fill='%23fff' width='24' height='24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3Cpath d='M0 0h24v24H0z' fill='none'/%3E%3C/svg%3E")}.am-textarea-clear-active{background-color:#108ee9}.am-textarea-focus .am-textarea-clear{display:block}.am-textarea-has-count{padding-bottom:14px}.am-textarea-count{position:absolute;bottom:6px;right:5px;color:#bbb;font-size:14px}.am-textarea-count span{color:#000}.am-textarea-error .am-textarea-control textarea{color:#f50}.am-textarea-error .am-textarea-error-extra{margin-top:12px;width:21px;height:21px;margin-left:8px;background-size:21px 21px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='18' height='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9 1.266a7.69 7.69 0 015.469 2.264c.71.71 1.269 1.538 1.657 2.459.404.954.608 1.967.608 3.011a7.69 7.69 0 01-2.264 5.469 7.694 7.694 0 01-2.459 1.657A7.675 7.675 0 019 16.734a7.69 7.69 0 01-5.469-2.264 7.694 7.694 0 01-1.657-2.459A7.675 7.675 0 011.266 9 7.69 7.69 0 013.53 3.531a7.694 7.694 0 012.459-1.657A7.675 7.675 0 019 1.266zM9 0a9 9 0 00-9 9 9 9 0 009 9 9 9 0 009-9 9 9 0 00-9-9zm0 11.25a.703.703 0 01-.703-.703V4.06a.703.703 0 111.406 0v6.486A.703.703 0 019 11.25zm-.791 1.916a.791.791 0 111.582 0 .791.791 0 01-1.582 0z' fill='%23F50' fill-rule='evenodd'/%3E%3C/svg%3E")}.am-textarea-disabled .am-textarea-label{color:#bbb}.am-list-body .am-list-item:last-child{border-bottom:0}.am-list-body .am-list-item:last-child:after{display:none!important}.am-pull-to-refresh-content{-webkit-transform-origin:left top 0;transform-origin:left top 0}.am-pull-to-refresh-content-wrapper{overflow:hidden}.am-pull-to-refresh-transition{-webkit-transition:-webkit-transform .3s;transition:-webkit-transform .3s;transition:transform .3s;transition:transform .3s,-webkit-transform .3s}.am-pull-to-refresh-indicator{color:grey;text-align:center;height:25px}.am-pull-to-refresh-down .am-pull-to-refresh-indicator{margin-top:-25px}.am-pull-to-refresh-up .am-pull-to-refresh-indicator{margin-bottom:-25px}.am-action-sheet-wrap{overflow:auto;-webkit-overflow-scrolling:touch;outline:0}.am-action-sheet-mask,.am-action-sheet-wrap{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1000}.am-action-sheet-mask{background-color:rgba(0,0,0,.4);height:100%}.am-action-sheet-close,.am-action-sheet-mask-hidden{display:none}.am-action-sheet{position:fixed;left:0;bottom:0;width:100%;background-color:#fff;padding-bottom:env(safe-area-inset-bottom)}.am-action-sheet.am-action-sheet-share{background-color:#f2f2f2}.am-action-sheet-message,.am-action-sheet-title{margin:15px auto;padding:0 15px;text-align:center}.am-action-sheet-title{font-size:17px}.am-action-sheet-message{color:#888;font-size:14px}.am-action-sheet-button-list{text-align:center;color:#000}.am-action-sheet-button-list-item{font-size:18px;padding:0 8px;margin:0;position:relative;height:50px;line-height:50px;box-sizing:border-box;white-space:nowrap;text-overflow:ellipsis;overflow-x:hidden;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list-item{border-top:none}html:not([data-scale]) .am-action-sheet-button-list-item:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list-item:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-button-list-item.am-action-sheet-button-list-item-active{background-color:#ddd}.am-action-sheet-button-list-badge{display:flex;align-items:center;justify-content:center}.am-action-sheet-button-list-badge .am-badge{margin-left:8px;flex-shrink:0}.am-action-sheet-button-list-item-content{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.am-action-sheet-button-list .am-action-sheet-cancel-button{padding-top:6px;position:relative}.am-action-sheet-button-list .am-action-sheet-cancel-button-mask{position:absolute;top:0;left:0;width:100%;height:6px;background-color:#e7e7ed;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask{border-top:none}html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask{border-bottom:none}html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-button-list .am-action-sheet-destructive-button{color:#f4333c}.am-action-sheet-share-list{display:flex;position:relative;border-top:1px solid #ddd;padding:21px 0 21px 15px;overflow-y:scroll;-webkit-overflow-scrolling:touch}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-share-list{border-top:none}html:not([data-scale]) .am-action-sheet-share-list:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-share-list:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-share-list-item{flex:none;margin:0 12px 0 0}.am-action-sheet-share-list-item-icon{margin-bottom:9px;width:60px;height:60px;background-color:#fff;border-radius:3px;display:flex;justify-content:center;align-items:center}.am-action-sheet-share-list-item-title{color:#888;font-size:10px;text-align:center}.am-action-sheet-share-cancel-button{height:50px;line-height:50px;text-align:center;background-color:#fff;color:#000;font-size:18px;position:relative;border-top:1px solid #ddd;box-sizing:border-box}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-share-cancel-button{border-top:none}html:not([data-scale]) .am-action-sheet-share-cancel-button:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-share-cancel-button:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-share-cancel-button.am-action-sheet-share-cancel-button-active{background-color:#ddd}.am-result{position:relative;text-align:center;width:100%;padding-top:30px;padding-bottom:21px;background-color:#fff;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-result{border-bottom:none}html:not([data-scale]) .am-result:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-result:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-result .am-result-pic{width:60px;height:60px;margin:0 auto;line-height:60px;background-size:60px 60px}.am-result .am-result-message,.am-result .am-result-title{font-size:21px;color:#000;padding-left:15px;padding-right:15px}.am-result .am-result-title{margin-top:15px;line-height:1}.am-result .am-result-message{margin-top:9px;line-height:1.5;font-size:16px;color:#888}.am-result .am-result-button{padding:0 15px;margin-top:15px} \ No newline at end of file diff --git a/docs/static/css/2.d6e5dedb.chunk.css b/docs/static/css/2.d6e5dedb.chunk.css new file mode 100644 index 0000000..43627ce --- /dev/null +++ b/docs/static/css/2.d6e5dedb.chunk.css @@ -0,0 +1,2 @@ + +/*! normalize.css v7.0.0 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,footer,header,nav,section{display:block}h1{font-size:2em;margin:.67em 0}figcaption,figure,main{display:block}figure{margin:1em 40px}hr{box-sizing:content-box;height:0;overflow:visible}pre{font-family:monospace,monospace;font-size:1em}a{background-color:transparent;-webkit-text-decoration-skip:objects}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}b,strong{font-weight:inherit;font-weight:bolder}code,kbd,samp{font-family:monospace,monospace;font-size:1em}dfn{font-style:italic}mark{background-color:#ff0;color:#000}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}audio,video{display:inline-block}audio:not([controls]){display:none;height:0}img{border-style:none}svg:not(:root){overflow:hidden}button,input,optgroup,select,textarea{font-family:sans-serif;font-size:100%;line-height:1.15;margin:0}button,input{overflow:visible}button,select{text-transform:none}[type=reset],[type=submit],button,html [type=button]{-webkit-appearance:button}[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner,button::-moz-focus-inner{border-style:none;padding:0}[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring,button:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{display:inline-block;vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-cancel-button,[type=search]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}details,menu{display:block}summary{display:list-item}canvas{display:inline-block}[hidden],template{display:none}.am-fade-appear,.am-fade-enter{opacity:0}.am-fade-appear,.am-fade-enter,.am-fade-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-fade-appear.am-fade-appear-active,.am-fade-enter.am-fade-enter-active{-webkit-animation-name:amFadeIn;animation-name:amFadeIn;-webkit-animation-play-state:running;animation-play-state:running}.am-fade-leave.am-fade-leave-active{-webkit-animation-name:amFadeOut;animation-name:amFadeOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amFadeIn{0%{opacity:0}to{opacity:1}}@keyframes amFadeIn{0%{opacity:0}to{opacity:1}}@-webkit-keyframes amFadeOut{0%{opacity:1}to{opacity:0}}@keyframes amFadeOut{0%{opacity:1}to{opacity:0}}.am-slide-up-appear,.am-slide-up-enter{-webkit-transform:translateY(100%);transform:translateY(100%)}.am-slide-up-appear,.am-slide-up-enter,.am-slide-up-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-slide-up-appear.am-slide-up-appear-active,.am-slide-up-enter.am-slide-up-enter-active{-webkit-animation-name:amSlideUpIn;animation-name:amSlideUpIn;-webkit-animation-play-state:running;animation-play-state:running}.am-slide-up-leave.am-slide-up-leave-active{-webkit-animation-name:amSlideUpOut;animation-name:amSlideUpOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amSlideUpIn{0%{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@keyframes amSlideUpIn{0%{-webkit-transform:translateY(100%);transform:translateY(100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@-webkit-keyframes amSlideUpOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}@keyframes amSlideUpOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(100%);transform:translateY(100%)}}.am.am-zoom-enter,.am.am-zoom-leave{display:block}.am-zoom-appear,.am-zoom-enter{opacity:0;-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-timing-function:cubic-bezier(.18,.89,.32,1.28);animation-timing-function:cubic-bezier(.18,.89,.32,1.28);-webkit-animation-play-state:paused;animation-play-state:paused}.am-zoom-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-timing-function:cubic-bezier(.6,-.3,.74,.05);animation-timing-function:cubic-bezier(.6,-.3,.74,.05);-webkit-animation-play-state:paused;animation-play-state:paused}.am-zoom-appear.am-zoom-appear-active,.am-zoom-enter.am-zoom-enter-active{-webkit-animation-name:amZoomIn;animation-name:amZoomIn;-webkit-animation-play-state:running;animation-play-state:running}.am-zoom-leave.am-zoom-leave-active{-webkit-animation-name:amZoomOut;animation-name:amZoomOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amZoomIn{0%{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}to{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}}@keyframes amZoomIn{0%{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}to{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}}@-webkit-keyframes amZoomOut{0%{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}}@keyframes amZoomOut{0%{opacity:1;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(1);transform:scale(1)}to{opacity:0;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scale(0);transform:scale(0)}}.am-slide-down-appear,.am-slide-down-enter{-webkit-transform:translateY(-100%);transform:translateY(-100%)}.am-slide-down-appear,.am-slide-down-enter,.am-slide-down-leave{-webkit-animation-duration:.2s;animation-duration:.2s;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-timing-function:cubic-bezier(.55,0,.55,.2);animation-timing-function:cubic-bezier(.55,0,.55,.2);-webkit-animation-play-state:paused;animation-play-state:paused}.am-slide-down-appear.am-slide-down-appear-active,.am-slide-down-enter.am-slide-down-enter-active{-webkit-animation-name:amSlideDownIn;animation-name:amSlideDownIn;-webkit-animation-play-state:running;animation-play-state:running}.am-slide-down-leave.am-slide-down-leave-active{-webkit-animation-name:amSlideDownOut;animation-name:amSlideDownOut;-webkit-animation-play-state:running;animation-play-state:running}@-webkit-keyframes amSlideDownIn{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@keyframes amSlideDownIn{0%{-webkit-transform:translateY(-100%);transform:translateY(-100%)}to{-webkit-transform:translate(0);transform:translate(0)}}@-webkit-keyframes amSlideDownOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}@keyframes amSlideDownOut{0%{-webkit-transform:translate(0);transform:translate(0)}to{-webkit-transform:translateY(-100%);transform:translateY(-100%)}}*,:after,:before{-webkit-tap-highlight-color:rgba(0,0,0,0)}body{background-color:#f5f5f9;font-size:14px}[contenteditable]{-webkit-user-select:auto!important}:focus,a{outline:none}a{background:transparent;text-decoration:none}.am-whitespace.am-whitespace-xs{height:3px}.am-whitespace.am-whitespace-sm{height:6px}.am-whitespace.am-whitespace-md{height:9px}.am-whitespace.am-whitespace-lg{height:15px}.am-whitespace.am-whitespace-xl{height:21px}.am-progress-outer{background-color:#ddd;display:block}.am-progress-fixed-outer{position:fixed;width:100%;top:0;left:0;z-index:2000}.am-progress-hide-outer{background-color:transparent}.am-progress-bar{border:2px solid #108ee9;-webkit-transition:all .3s linear 0s;transition:all .3s linear 0s}.am-card{min-height:96px;padding-bottom:6px;display:flex;flex-direction:column;background-color:#fff}.am-card:not(.am-card-full){border:1px solid #ddd;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card:not(.am-card-full){position:relative;border:none}html:not([data-scale]) .am-card:not(.am-card-full):before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-card.am-card-full{position:relative;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card.am-card-full{border-top:none}html:not([data-scale]) .am-card.am-card-full:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card.am-card-full:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card.am-card-full{border-bottom:none}html:not([data-scale]) .am-card.am-card-full:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card.am-card-full:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-card-header{display:flex;align-items:center;font-size:17px;padding:9px 15px}.am-card-header-content{flex:1 1;text-align:left;color:#000;display:flex;align-items:center}.am-card-header-content img{margin-right:5px}.am-card-header-extra{flex:1 1;text-align:right;font-size:17px;color:#888}.am-card-body{position:relative;border-top:1px solid #ddd;padding:15px 15px 6px;font-size:15px;color:#333;min-height:40px;flex:1 1}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-card-body{border-top:none}html:not([data-scale]) .am-card-body:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-card-body:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-card-footer{font-size:14px;color:#888;padding:0 15px;display:flex}.am-card-footer-content{flex:1 1}.am-card-footer-extra{flex:1 1;text-align:right}.am-navbar{display:flex;align-items:center;height:45px;background-color:#108ee9;color:#fff}.am-navbar-left,.am-navbar-right,.am-navbar-title{flex:1 1;height:100%;display:flex;align-items:center}.am-navbar-left{padding-left:15px;font-size:16px}.am-navbar-left-icon{margin-right:5px;display:inherit}.am-navbar-title{justify-content:center;font-size:18px;white-space:nowrap}.am-navbar-right{justify-content:flex-end;font-size:16px;margin-right:15px}.am-navbar-light{background-color:#fff;color:#108ee9}.am-navbar-light .am-navbar-title{color:#000}.am-swipe{overflow:hidden;position:relative}.am-swipe-content{position:relative;background-color:#fff}.am-swipe-cover{position:absolute;z-index:2;background:transparent;height:100%;width:100%;top:0;display:none}.am-swipe .am-swipe-actions,.am-swipe .am-swipe-content{-webkit-transition:all .25s;transition:all .25s}.am-swipe-swiping .am-swipe-actions,.am-swipe-swiping .am-swipe-content{-webkit-transition:none;transition:none}.am-swipe-swiping .am-list-item-active{background-color:#fff}.am-swipe-actions{position:absolute;top:0;bottom:0;display:flex;overflow:hidden;white-space:nowrap}.am-swipe-actions-left{left:0}.am-swipe-actions-right{right:0}.am-swipe-btn{display:flex;align-items:center;justify-content:center;overflow:hidden}.am-swipe-btn-text{padding:0 8px}.am-badge{position:relative;display:inline-block;line-height:1;vertical-align:middle}.am-badge-text{text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;position:absolute;top:-6px;height:18px;line-height:18px;min-width:9px;border-radius:12px;padding:0 5px;text-align:center;font-size:12px;color:#fff;background-color:#ff5b05;white-space:nowrap;-webkit-transform:translateX(-45%);transform:translateX(-45%);-webkit-transform-origin:-10% center;transform-origin:-10% center;z-index:10;font-family:Helvetica Neue,Helvetica,PingFang SC,Hiragino Sans GB,Microsoft YaHei,"\5FAE\8F6F\96C5\9ED1",SimSun,sans-serif}.am-badge-text a{color:#fff}.am-badge-text p{margin:0;padding:0}.am-badge-hot .am-badge-text{background-color:#f96268}.am-badge-dot{position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%);-webkit-transform-origin:0 center;transform-origin:0 center;top:-4px;height:8px;width:8px;border-radius:100%;background:#ff5b05;z-index:10}.am-badge-dot-large{height:16px;width:16px}.am-badge-not-a-wrapper .am-badge-dot,.am-badge-not-a-wrapper .am-badge-text{top:auto;display:block;position:relative;-webkit-transform:translateX(0);transform:translateX(0)}.am-badge-corner{width:80px;padding:8px;position:absolute;right:-32px;top:8px;background-color:#ff5b05;color:#fff;white-space:nowrap;-webkit-transform:rotate(45deg);transform:rotate(45deg);text-align:center;font-size:15px}.am-badge-corner-wrapper{overflow:hidden}.am-icon{fill:currentColor;background-size:cover;width:22px;height:22px}.am-icon-xxs{width:15px;height:15px}.am-icon-xs{width:18px;height:18px}.am-icon-sm{width:21px;height:21px}.am-icon-md{width:22px;height:22px}.am-icon-lg{width:36px;height:36px}.am-icon-loading{-webkit-animation:cirle-anim 1s linear infinite;animation:cirle-anim 1s linear infinite}@-webkit-keyframes cirle-anim{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}@keyframes cirle-anim{to{-webkit-transform:rotate(1turn);transform:rotate(1turn)}}.am-button{display:block;outline:0 none;-webkit-appearance:none;box-sizing:border-box;padding:0;text-align:center;font-size:18px;height:47px;line-height:47px;overflow:hidden;text-overflow:ellipsis;word-break:break-word;white-space:nowrap;color:#000;background-color:#fff;border:1px solid #ddd;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button{position:relative;border:none}html:not([data-scale]) .am-button:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-borderfix:before{-webkit-transform:scale(.49)!important;transform:scale(.49)!important}.am-button.am-button-active{background-color:#ddd}.am-button.am-button-disabled{color:rgba(0,0,0,.3);opacity:.6}.am-button-primary{color:#fff;background-color:#108ee9;border:1px solid #108ee9;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-primary{position:relative;border:none}html:not([data-scale]) .am-button-primary:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-primary.am-button-active{color:hsla(0,0%,100%,.3);background-color:#0e80d2}.am-button-primary.am-button-disabled{color:hsla(0,0%,100%,.6);opacity:.4}.am-button-ghost{color:#108ee9;background-color:transparent;border:1px solid #108ee9;border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost{position:relative;border:none}html:not([data-scale]) .am-button-ghost:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-ghost.am-button-active{color:rgba(16,142,233,.6);background-color:transparent;border:1px solid rgba(16,142,233,.6);border-radius:5px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost.am-button-active{position:relative;border:none}html:not([data-scale]) .am-button-ghost.am-button-active:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid rgba(16,142,233,.6);border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-ghost.am-button-disabled{color:rgba(0,0,0,.1);border:1px solid rgba(0,0,0,.1);border-radius:5px;opacity:1}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-button-ghost.am-button-disabled{position:relative;border:none}html:not([data-scale]) .am-button-ghost.am-button-disabled:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid rgba(0,0,0,.1);border-radius:10px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-button-warning{color:#fff;background-color:#e94f4f}.am-button-warning.am-button-active{color:hsla(0,0%,100%,.3);background-color:#d24747}.am-button-warning.am-button-disabled{color:hsla(0,0%,100%,.6);opacity:.4}.am-button-inline{display:inline-block;padding:0 15px}.am-button-inline.am-button-icon{display:inline-flex}.am-button-small{font-size:13px;height:30px;line-height:30px;padding:0 15px}.am-button-icon{display:flex;align-items:center;justify-content:center}.am-button>.am-button-icon{margin-right:.5em}.am-modal{position:relative}.am-modal:not(.am-modal-transparent):not(.am-modal-popup){width:100%;height:100%}.am-modal-mask{position:fixed;top:0;right:0;left:0;bottom:0;height:100%;z-index:999;background-color:rgba(0,0,0,.4)}.am-modal-mask-hidden{display:none}.am-modal-wrap{position:fixed;overflow:auto;top:0;right:0;bottom:0;left:0;height:100%;z-index:999;-webkit-overflow-scrolling:touch;outline:0;display:flex;align-items:center;justify-content:center;-webkit-transform:translateZ(1px);transform:translateZ(1px)}.am-modal-wrap-popup{display:block}.am-modal-transparent{width:270px}.am-modal-transparent .am-modal-content{border-radius:7px;padding-top:15px}.am-modal-transparent .am-modal-content .am-modal-body{padding:0 15px 15px}.am-modal-popup{position:fixed;left:0;width:100%}.am-modal-popup-slide-down{top:0}.am-modal-popup-slide-up{bottom:0}.am-modal-popup .am-modal-content{padding-bottom:env(safe-area-inset-bottom)}.am-modal-title{margin:0;font-size:18px;line-height:1;color:#000;text-align:center}.am-modal-header{padding:6px 15px 15px}.am-modal-content{position:relative;background-color:#fff;border:0;background-clip:padding-box;text-align:center;height:100%;overflow:hidden}.am-modal-close{border:0;padding:0;background-color:transparent;outline:none;position:absolute;right:15px;z-index:999;height:21px;width:21px}.am-modal-close-x{display:inline-block;width:15px;height:15px;background-repeat:no-repeat;background-size:cover;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='30' height='30' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23888' fill-rule='evenodd'%3E%3Cpath d='M1.414 0l28.284 28.284-1.414 1.414L0 1.414z'/%3E%3Cpath d='M28.284 0L0 28.284l1.414 1.414L29.698 1.414z'/%3E%3C/g%3E%3C/svg%3E")}.am-modal-body{font-size:15px;color:#888;height:100%;line-height:1.5;overflow:auto}.am-modal-button-group-h{position:relative;border-top:1px solid #ddd;display:flex}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-h{border-top:none}html:not([data-scale]) .am-modal-button-group-h:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-h:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-button-group-h .am-modal-button{-webkit-touch-callout:none;flex:1 1;box-sizing:border-box;text-align:center;text-decoration:none;outline:none;color:#108ee9;font-size:18px;height:50px;line-height:50px;display:block;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-modal-button-group-h .am-modal-button:first-child{color:#000}.am-modal-button-group-h .am-modal-button:last-child{position:relative;border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child{border-left:none}html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-h .am-modal-button:last-child:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-modal-button-group-v .am-modal-button{-webkit-touch-callout:none;position:relative;border-top:1px solid #ddd;box-sizing:border-box;text-align:center;text-decoration:none;outline:none;color:#108ee9;font-size:18px;height:50px;line-height:50px;display:block;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-button-group-v .am-modal-button{border-top:none}html:not([data-scale]) .am-modal-button-group-v .am-modal-button:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-button-group-v .am-modal-button:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-button-active{background-color:#ddd}.am-modal-input-container{margin-top:9px;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-input-container{position:relative;border:none}html:not([data-scale]) .am-modal-input-container:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-modal-input{height:36px;line-height:1}.am-modal-input:nth-child(2){position:relative;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal-input:nth-child(2){border-top:none}html:not([data-scale]) .am-modal-input:nth-child(2):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal-input:nth-child(2):before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal-input input{position:relative;border:0;width:98%;height:34px;top:1PX;box-sizing:border-box;margin:0}.am-modal-input input::-webkit-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::-moz-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::-ms-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input:-ms-input-placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal-input input::placeholder{font-size:14px;color:#ccc;padding-left:8px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content{border-radius:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-header{padding:9px 24px 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-header .am-modal-title{text-align:left;font-size:21px;color:#000}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body{color:#000;text-align:left;padding:0 24px 15px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container{border:0;border-bottom:1px solid #ddd}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:before{display:none!important}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container{border-bottom:none}html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container .am-modal-input:first-child{border-top:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-body .am-modal-input-container .am-modal-input:first-child:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer{padding-bottom:12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h{overflow:hidden;border-top:0;justify-content:flex-end;padding:0 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button{flex:initial;margin-left:3px;padding:0 15px;height:48px;box-sizing:border-box}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:first-child{color:#777}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:last-child{border-left:0}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-h .am-modal-button:last-child:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal{display:flex;justify-content:flex-end;overflow:hidden;padding:0 12px}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal .am-modal-button{border-top:0;padding:0 15px;margin-left:3px;height:48px;box-sizing:border-box}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-v.am-modal-button-group-normal .am-modal-button:before{display:none!important}.am-modal.am-modal-transparent.am-modal-android .am-modal-content .am-modal-footer .am-modal-button-group-operation .am-modal-button{text-align:start;padding-left:15px}.am-modal.am-modal-operation .am-modal-content{border-radius:7px;height:auto;padding-top:0}.am-modal.am-modal-operation .am-modal-content .am-modal-body{padding:0!important}.am-modal.am-modal-operation .am-modal-content .am-modal-button{color:#000;text-align:left;padding-left:15px}.am-modal-alert-content,.am-modal-propmt-content{zoom:1;overflow:hidden}.am-toast{position:fixed;width:100%;z-index:1999;font-size:14px;text-align:center}.am-toast>span{max-width:50%}.am-toast.am-toast-mask{height:100%;display:flex;justify-content:center;align-items:center;left:0;top:0}.am-toast.am-toast-mask,.am-toast.am-toast-nomask{-webkit-transform:translateZ(1px);transform:translateZ(1px)}.am-toast.am-toast-nomask{position:fixed;max-width:50%;width:auto;left:50%;top:50%}.am-toast.am-toast-nomask .am-toast-notice{-webkit-transform:translateX(-50%) translateY(-50%);transform:translateX(-50%) translateY(-50%)}.am-toast-notice-content .am-toast-text{min-width:60px;border-radius:3px;color:#fff;background-color:rgba(58,58,58,.9);line-height:1.5;padding:9px 15px}.am-toast-notice-content .am-toast-text.am-toast-text-icon{border-radius:5px;padding:15px}.am-toast-notice-content .am-toast-text.am-toast-text-icon .am-toast-text-info{margin-top:6px}.am-list-header{padding:15px 15px 9px;font-size:14px;color:#888;width:100%;box-sizing:border-box}.am-list-footer{padding:9px 15px 15px;font-size:14px;color:#888}.am-list-body{position:relative;background-color:#fff;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body{border-top:none}html:not([data-scale]) .am-list-body:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body{border-bottom:none}html:not([data-scale]) .am-list-body:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-body div:not(:last-child) .am-list-line{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line{border-bottom:none}html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-body div:not(:last-child) .am-list-line:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-item{position:relative;display:flex;padding-left:15px;min-height:44px;background-color:#fff;vertical-align:middle;overflow:hidden;-webkit-transition:background-color .2s;transition:background-color .2s;align-items:center}.am-list-item .am-list-ripple{position:absolute;background:transparent;display:inline-block;overflow:hidden;will-change:box-shadow,transform;-webkit-transition:background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1),-webkit-box-shadow .2s cubic-bezier(.4,0,1,1);-webkit-transition:box-shadow .2s cubic-bezier(.4,0,1,1),background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1);transition:box-shadow .2s cubic-bezier(.4,0,1,1),background-color .2s cubic-bezier(.4,0,.2,1),color .2s cubic-bezier(.4,0,.2,1);outline:none;cursor:pointer;border-radius:100%;-webkit-transform:scale(0);transform:scale(0)}.am-list-item .am-list-ripple.am-list-ripple-animate{background-color:hsla(0,0%,62%,.2);-webkit-animation:ripple 1s linear;animation:ripple 1s linear}.am-list-item.am-list-item-top .am-list-line{align-items:flex-start}.am-list-item.am-list-item-top .am-list-line .am-list-arrow{margin-top:2px}.am-list-item.am-list-item-middle .am-list-line{align-items:center}.am-list-item.am-list-item-bottom .am-list-line{align-items:flex-end}.am-list-item.am-list-item-error .am-list-line .am-list-extra,.am-list-item.am-list-item-error .am-list-line .am-list-extra .am-list-brief{color:#f50}.am-list-item.am-list-item-active{background-color:#ddd}.am-list-item.am-list-item-disabled .am-list-line .am-list-content,.am-list-item.am-list-item-disabled .am-list-line .am-list-extra{color:#bbb}.am-list-item img{width:22px;height:22px;vertical-align:middle}.am-list-item .am-list-thumb:first-child{margin-right:15px}.am-list-item .am-list-thumb:last-child{margin-left:8px}.am-list-item .am-list-line{position:relative;display:flex;flex:1 1;align-self:stretch;padding-right:15px;overflow:hidden}.am-list-item .am-list-line .am-list-content{flex:1 1;color:#000;font-size:17px;text-align:left}.am-list-item .am-list-line .am-list-content,.am-list-item .am-list-line .am-list-extra{line-height:1.5;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;padding-top:7px;padding-bottom:7px}.am-list-item .am-list-line .am-list-extra{flex-basis:36%;color:#888;font-size:16px;text-align:right}.am-list-item .am-list-line .am-list-brief,.am-list-item .am-list-line .am-list-title{width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-list-item .am-list-line .am-list-brief{color:#888;font-size:15px;line-height:1.5;margin-top:6px}.am-list-item .am-list-line .am-list-arrow{display:block;width:15px;height:15px;margin-left:8px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='16' height='26' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 0L0 2l11.5 11L0 24l2 2 14-13z' fill='%23C7C7CC' fill-rule='evenodd'/%3E%3C/svg%3E");background-size:contain;background-repeat:no-repeat;background-position:50% 50%;visibility:hidden}.am-list-item .am-list-line .am-list-arrow-horizontal{visibility:visible}.am-list-item .am-list-line .am-list-arrow-vertical{visibility:visible;-webkit-transform:rotate(90deg);transform:rotate(90deg)}.am-list-item .am-list-line .am-list-arrow-vertical-up{visibility:visible;-webkit-transform:rotate(270deg);transform:rotate(270deg)}.am-list-item .am-list-line-multiple{padding:12.5px 15px 12.5px 0}.am-list-item .am-list-line-multiple .am-list-content,.am-list-item .am-list-line-multiple .am-list-extra{padding-top:0;padding-bottom:0}.am-list-item .am-list-line-wrap .am-list-content,.am-list-item .am-list-line-wrap .am-list-extra{white-space:normal}.am-list-item select{position:relative;display:block;width:100%;height:100%;padding:0;border:0;font-size:17px;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:transparent}@-webkit-keyframes ripple{to{opacity:0;-webkit-transform:scale(2.5);transform:scale(2.5)}}@keyframes ripple{to{opacity:0;-webkit-transform:scale(2.5);transform:scale(2.5)}}.am-tabs{display:flex;flex:1 1;position:relative;overflow:hidden;height:100%;width:100%}.am-tabs,.am-tabs *{box-sizing:border-box}.am-tabs-content-wrap{display:flex;flex:1 1;width:100%;height:100%;min-height:0}.am-tabs-content-wrap-animated{-webkit-transition:left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),top .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);will-change:transform,left,top}.am-tabs-pane-wrap{width:100%;flex-shrink:0;overflow-y:auto}.am-tabs-tab-bar-wrap{flex-shrink:0}.am-tabs-horizontal .am-tabs-pane-wrap-active{height:auto}.am-tabs-horizontal .am-tabs-pane-wrap-inactive{height:0;overflow:visible}.am-tabs-vertical .am-tabs-content-wrap{flex-direction:column}.am-tabs-vertical .am-tabs-pane-wrap,.am-tabs-vertical .am-tabs-tab-bar-wrap{height:100%}.am-tabs-vertical .am-tabs-pane-wrap-active{overflow:auto}.am-tabs-vertical .am-tabs-pane-wrap-inactive{overflow:hidden}.am-tabs-bottom,.am-tabs-top{flex-direction:column}.am-tabs-left,.am-tabs-right{flex-direction:row}.am-tabs-default-bar{position:relative;display:flex;flex-shrink:0;flex-direction:row;width:100%;height:100%;overflow:visible;z-index:1}.am-tabs-default-bar-tab{position:relative;display:flex;flex-shrink:0;justify-content:center;align-items:center;font-size:15px;height:43.5px;line-height:43.5px}.am-tabs-default-bar-tab .am-badge .am-badge-text{top:-13px;-webkit-transform:translateX(-5px);transform:translateX(-5px)}.am-tabs-default-bar-tab .am-badge .am-badge-dot{top:-6px;-webkit-transform:translateX(0);transform:translateX(0)}.am-tabs-default-bar-tab-active{color:#108ee9}.am-tabs-default-bar-underline{position:absolute;border:1px solid #108ee9;-webkit-transform:translateZ(0);transform:translateZ(0)}.am-tabs-default-bar-animated .am-tabs-default-bar-content{-webkit-transition:-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:-webkit-transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1);transition:transform .3s cubic-bezier(.35,0,.25,1),-webkit-transform .3s cubic-bezier(.35,0,.25,1);will-change:transform}.am-tabs-default-bar-animated .am-tabs-default-bar-underline{-webkit-transition:top .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),color .3s cubic-bezier(.35,0,.25,1),width .3s cubic-bezier(.35,0,.25,1);transition:top .3s cubic-bezier(.35,0,.25,1),left .3s cubic-bezier(.35,0,.25,1),color .3s cubic-bezier(.35,0,.25,1),width .3s cubic-bezier(.35,0,.25,1);will-change:top,left,width,color}.am-tabs-default-bar-bottom,.am-tabs-default-bar-top{flex-direction:row}.am-tabs-default-bar-bottom .am-tabs-default-bar-content,.am-tabs-default-bar-top .am-tabs-default-bar-content{display:flex;width:100%;flex-direction:row}.am-tabs-default-bar-bottom .am-tabs-default-bar-prevpage,.am-tabs-default-bar-top .am-tabs-default-bar-prevpage{pointer-events:none;position:absolute;top:0;display:block;width:59px;height:100%;content:" ";z-index:999;left:0;background:-webkit-gradient(linear,left top,right top,from(#fff),to(hsla(0,0%,100%,0)));background:linear-gradient(90deg,#fff,hsla(0,0%,100%,0))}.am-tabs-default-bar-bottom .am-tabs-default-bar-nextpage,.am-tabs-default-bar-top .am-tabs-default-bar-nextpage{pointer-events:none;position:absolute;top:0;display:block;width:59px;height:100%;content:" ";z-index:999;right:0;background:-webkit-gradient(linear,left top,right top,from(hsla(0,0%,100%,0)),to(#fff));background:linear-gradient(90deg,hsla(0,0%,100%,0),#fff)}.am-tabs-default-bar-bottom .am-tabs-default-bar-tab,.am-tabs-default-bar-top .am-tabs-default-bar-tab{padding:8px 0}.am-tabs-default-bar-bottom .am-tabs-default-bar-underline,.am-tabs-default-bar-top .am-tabs-default-bar-underline{bottom:0}.am-tabs-default-bar-top .am-tabs-default-bar-tab{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab{border-bottom:none}html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-top .am-tabs-default-bar-tab:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tabs-default-bar-bottom .am-tabs-default-bar-tab{border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab{border-top:none}html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-bottom .am-tabs-default-bar-tab:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tabs-default-bar-left,.am-tabs-default-bar-right{flex-direction:column}.am-tabs-default-bar-left .am-tabs-default-bar-content,.am-tabs-default-bar-right .am-tabs-default-bar-content{display:flex;height:100%;flex-direction:column}.am-tabs-default-bar-left .am-tabs-default-bar-tab,.am-tabs-default-bar-right .am-tabs-default-bar-tab{padding:0 8px}.am-tabs-default-bar-left .am-tabs-default-bar-underline{right:0}.am-tabs-default-bar-left .am-tabs-default-bar-tab{border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab{border-right:none}html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-left .am-tabs-default-bar-tab:after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-tabs-default-bar-right .am-tabs-default-bar-underline{left:0}.am-tabs-default-bar-right .am-tabs-default-bar-tab{border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab{border-left:none}html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tabs-default-bar-right .am-tabs-default-bar-tab:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-tab-bar{height:100%;overflow:hidden}.am-tab-bar-bar{position:relative;box-sizing:border-box;height:50px;border-top:1px solid #ddd;width:100%;display:flex;-webkit-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:height bottom;transition-property:height bottom;z-index:100;justify-content:space-around;align-items:center;bottom:0}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tab-bar-bar{border-top:none}html:not([data-scale]) .am-tab-bar-bar:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-tab-bar-bar:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-tab-bar-bar-hidden-top{bottom:50px;height:0}.am-tab-bar-bar-hidden-bottom{bottom:-50px;height:0}.am-tab-bar-bar .am-tab-bar-tab{flex:1 1;display:flex;justify-content:center;align-items:center;flex-direction:column;text-align:center;width:100%}.am-tab-bar-bar .am-tab-bar-tab-image{width:22px;height:22px;vertical-align:middle}.am-tab-bar-bar .am-tab-bar-tab-title{font-size:10px;margin:3px 0 0;line-height:1;text-align:center}.am-tab-bar-bar .am-tab-bar-tab-icon{display:flex;justify-content:center}.am-tab-bar-bar .am-tab-bar-tab-icon .tab-badge :last-child,.am-tab-bar-bar .am-tab-bar-tab-icon .tab-dot :last-child{margin-top:4px;left:22px}.am-tab-bar-item{height:100%}.am-wingblank{margin-left:8px;margin-right:8px}.am-wingblank.am-wingblank-sm{margin-left:5px;margin-right:5px}.am-wingblank.am-wingblank-md{margin-left:8px;margin-right:8px}.am-wingblank.am-wingblank-lg{margin-left:15px;margin-right:15px}.am-list-item .am-input-control .fake-input-container{height:30px;line-height:30px;position:relative}.am-list-item .am-input-control .fake-input-container .fake-input{position:absolute;top:0;left:0;width:100%;height:100%;margin-right:5px;-webkit-text-decoration:rtl;text-decoration:rtl;text-align:right;color:#000;font-size:17px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-list-item .am-input-control .fake-input-container .fake-input.fake-input-disabled{color:#bbb}.am-list-item .am-input-control .fake-input-container .fake-input.focus{-webkit-transition:color .2s;transition:color .2s}.am-list-item .am-input-control .fake-input-container .fake-input.focus:after{content:"";position:absolute;right:0;top:10%;height:80%;border-right:1.5px solid #108ee9;-webkit-animation:keyboard-cursor 1s step-start infinite;animation:keyboard-cursor 1s step-start infinite}.am-list-item .am-input-control .fake-input-container .fake-input-placeholder{position:absolute;top:0;left:0;width:100%;height:100%;color:#bbb;text-align:right}.am-list-item .am-input-control .fake-input-container-left .fake-input{text-align:left}.am-list-item .am-input-control .fake-input-container-left .fake-input.focus:after{position:relative}.am-list-item .am-input-control .fake-input-container-left .fake-input-placeholder{text-align:left}.am-number-keyboard-wrapper{position:fixed;bottom:0;left:0;right:0;width:100%;z-index:10000;font-family:PingFang SC;background-color:#f6f6f7;-webkit-transition-duration:.2s;transition-duration:.2s;-webkit-transition-property:-webkit-transform display;transition-property:-webkit-transform display;transition-property:transform display;transition-property:transform display,-webkit-transform display;-webkit-transform:translateZ(0);transform:translateZ(0);padding-bottom:env(safe-area-inset-bottom)}.am-number-keyboard-wrapper.am-number-keyboard-wrapper-hide{bottom:-500px}.am-number-keyboard-wrapper table{width:100%;padding:0;margin:0;border-collapse:collapse;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table{border-top:none}html:not([data-scale]) .am-number-keyboard-wrapper table:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr{width:100%;padding:0;margin:0}.am-number-keyboard-wrapper table tr .am-number-keyboard-item{width:25%;padding:0;margin:0;height:50px;text-align:center;font-size:25.5px;color:#2a2b2c;position:relative}.am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-left:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-left:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm){border-bottom:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item:not(.keyboard-confirm):after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.am-number-keyboard-item-active{background-color:#ddd}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm{color:#fff;font-size:21px;background-color:#108ee9;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm{border-bottom:none}html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm.am-number-keyboard-item-active{background-color:#0e80d2}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-confirm.am-number-keyboard-item-disabled{background-color:#0e80d2;color:hsla(0,0%,100%,.45)}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-delete{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg version='1' xmlns='http://www.w3.org/2000/svg' width='204' height='148' viewBox='0 0 153 111'%3E%3Cpath d='M46.9 4.7c-2.5 2.6-14.1 15.5-25.8 28.6L-.1 57l25.6 27 25.7 27.1 47.4-.3 47.4-.3 3.2-3.3 3.3-3.2V7l-3.3-3.2L146 .5 98.7.2 51.5-.1l-4.6 4.8zm97.9 3.5c1.7 1.7 1.7 92.9 0 94.6-.9.9-12.6 1.2-46.3 1.2H53.4L31.2 80.4 9 56.9l5.1-5.7c2.8-3.1 12.8-14.4 22.2-24.9L53.5 7h45c33.8 0 45.4.3 46.3 1.2z'/%3E%3Cpath d='M69.5 31c-1.9 2.1-1.7 2.2 9.3 13.3L90 55.5 78.8 66.7 67.5 78l2.3 2.2 2.2 2.3 11.3-11.3L94.5 60l11.2 11.2L117 82.5l2.2-2.3 2.3-2.2-11.3-11.3L99 55.5l11.2-11.2L121.5 33l-2.3-2.2-2.2-2.3-11.3 11.3L94.5 51l-11-11c-6-6-11.2-11-11.6-11-.3 0-1.4.9-2.4 2z'/%3E%3C/svg%3E");background-size:25.5px 18.5px;background-position:50% 50%;background-repeat:no-repeat}.am-number-keyboard-wrapper table tr .am-number-keyboard-item.keyboard-hide{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg version='1' xmlns='http://www.w3.org/2000/svg' width='260' height='188' viewBox='0 0 195 141'%3E%3Cpath d='M0 57v57h195V0H0v57zm183 0v45H12V12h171v45z'/%3E%3Cpath d='M21 31.5V39h15V24H21v7.5zm27 0V39h15V24H48v7.5zm27 0V39h15V24H75v7.5zm27 0V39h15V24h-15v7.5zm27 0V39h15V24h-15v7.5zm27 0V39h15V24h-15v7.5zm-120 24V63h15V48H36v7.5zm27 0V63h15V48H63v7.5zm27 0V63h15V48H90v7.5zm27 0V63h15V48h-15v7.5zm27 0V63h15V48h-15v7.5zm-117 24V87h15V72H27v7.5zm21 0V87h96V72H48v7.5zm102 0V87h15V72h-15v7.5zm-69 45c0 .8.7 1.5 1.5 1.5s1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5.7 1.5 1.5.7 1.5 1.5 1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5.7-1.5 1.5-1.5 1.5-.7 1.5-1.5c0-1.3-2.5-1.5-16.5-1.5s-16.5.2-16.5 1.5z'/%3E%3C/svg%3E");background-size:32.5px 23.5px;background-position:50% 50%;background-repeat:no-repeat}.am-number-keyboard-wrapper table tr .am-number-keyboard-item-disabled{color:#bbb}@-webkit-keyframes keyboard-cursor{0%{opacity:1}50%{opacity:0}to{opacity:1}}@keyframes keyboard-cursor{0%{opacity:1}50%{opacity:0}to{opacity:1}}.am-list-item.am-input-item{height:44px;padding-left:15px}.am-list-item:not(:last-child) .am-list-line{border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line{border-bottom:none}html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list-item:not(:last-child) .am-list-line:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list-item .am-input-label{color:#000;font-size:17px;margin-left:0;margin-right:5px;text-align:left;white-space:nowrap;overflow:hidden;padding:2px 0}.am-list-item .am-input-label.am-input-label-2{width:34px}.am-list-item .am-input-label.am-input-label-3{width:51px}.am-list-item .am-input-label.am-input-label-4{width:68px}.am-list-item .am-input-label.am-input-label-5{width:85px}.am-list-item .am-input-label.am-input-label-6{width:102px}.am-list-item .am-input-label.am-input-label-7{width:119px}.am-list-item .am-input-control{font-size:17px;flex:1 1}.am-list-item .am-input-control input{color:#000;font-size:17px;-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;padding:2px 0;border:0;background-color:transparent;line-height:1;box-sizing:border-box}.am-list-item .am-input-control input::-webkit-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::-moz-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::-ms-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input:-ms-input-placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input::placeholder{color:#bbb;line-height:1.2}.am-list-item .am-input-control input:disabled{color:#bbb;background-color:#fff}.am-list-item .am-input-clear{display:none;width:21px;height:21px;border-radius:50%;overflow:hidden;font-style:normal;color:#fff;background-color:#ccc;background-repeat:no-repeat;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg fill='%23fff' viewBox='0 0 30 30' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3Cpath d='M0 0h24v24H0z' fill='none'/%3E%3C/svg%3E");background-size:21px auto;background-position:2px 2px}.am-list-item .am-input-clear-active{background-color:#108ee9}.am-list-item.am-input-focus .am-input-clear{display:block}.am-list-item .am-input-extra{flex:initial;min-width:0;max-height:21px;overflow:hidden;padding-right:0;line-height:1;color:#888;font-size:15px;margin-left:5px}.am-list-item.am-input-error .am-input-control input{color:#f50}.am-list-item.am-input-error .am-input-error-extra{height:21px;width:21px;margin-left:6px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='18' height='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9 1.266a7.69 7.69 0 015.469 2.264c.71.71 1.269 1.538 1.657 2.459.404.954.608 1.967.608 3.011a7.69 7.69 0 01-2.264 5.469 7.694 7.694 0 01-2.459 1.657A7.675 7.675 0 019 16.734a7.69 7.69 0 01-5.469-2.264 7.694 7.694 0 01-1.657-2.459A7.675 7.675 0 011.266 9 7.69 7.69 0 013.53 3.531a7.694 7.694 0 012.459-1.657A7.675 7.675 0 019 1.266zM9 0a9 9 0 00-9 9 9 9 0 009 9 9 9 0 009-9 9 9 0 00-9-9zm0 11.25a.703.703 0 01-.703-.703V4.06a.703.703 0 111.406 0v6.486A.703.703 0 019 11.25zm-.791 1.916a.791.791 0 111.582 0 .791.791 0 01-1.582 0z' fill='%23F50' fill-rule='evenodd'/%3E%3C/svg%3E");background-size:21px auto}.am-list-item.am-input-disabled .am-input-label{color:#bbb}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.am-tag{display:inline-block;position:relative;font-size:14px;text-align:center;padding:0 15px;height:25px;line-height:25px;box-sizing:border-box}.am-tag.am-tag-small{height:15px;line-height:15px;padding:0 5px;font-size:10px}.am-tag-normal{background-color:#fff;color:#888;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-normal{position:relative;border:none}html:not([data-scale]) .am-tag-normal:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-active{background-color:#fff;color:#108ee9;border:1px solid #108ee9;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-active{position:relative;border:none}html:not([data-scale]) .am-tag-active:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #108ee9;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-disabled{color:#bbb;background-color:#ddd;border:1px solid #ddd;border-radius:3px}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-tag-disabled{position:relative;border:none}html:not([data-scale]) .am-tag-disabled:before{content:"";position:absolute;left:0;top:0;width:200%;height:200%;border:1px solid #ddd;border-radius:6px;-webkit-transform-origin:0 0;transform-origin:0 0;-webkit-transform:scale(.5);transform:scale(.5);box-sizing:border-box;pointer-events:none}}.am-tag-close{position:absolute;top:-9px;left:-10px;color:#bbb}.am-tag-close-active{color:#888}.am-tag-close .am-icon{background-color:#fff;border-radius:9px}.am-notice-bar{background-color:#fefcec;height:36px;overflow:hidden;font-size:14px;line-height:36px;color:#f76a24;display:flex}.am-notice-bar-content{flex:1 1;width:100%;margin:auto 15px;width:auto;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.am-notice-bar-icon{margin-left:15px;display:flex;align-items:center}.am-notice-bar-icon .am-notice-bar-trips{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='38' height='33' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill-rule='evenodd'%3E%3Cpath d='M17.838 28.8c-.564-.468-1.192-.983-1.836-1.496-4.244-3.385-5.294-3.67-6.006-3.67-.014 0-.027.005-.04.005-.015 0-.028-.005-.042-.005H3.562c-.734 0-.903-.203-.903-.928V10.085c0-.49.058-.8.66-.8h5.782c.693 0 1.758-.28 6.4-3.628.828-.597 1.637-1.197 2.336-1.723V28.8zM19.682.19a1.36 1.36 0 00-1.417.157c-.02.016-1.983 1.552-4.152 3.125C10.34 6.21 9.243 6.664 9.02 6.737H3.676c-.027 0-.053.003-.08.004H1.183c-.608 0-1.1.486-1.1 1.085V25.14c0 .598.492 1.084 1.1 1.084h8.71c.22.08 1.257.55 4.605 3.24 1.947 1.562 3.694 3.088 3.712 3.103a1.362 1.362 0 001.44.217c.48-.213.79-.684.79-1.204V1.38c0-.506-.294-.968-.758-1.19z' mask='url(%23mask-2)'/%3E%3Cpath d='M31.42 16.475c0-3.363-1.854-6.297-4.606-7.876-.125-.066-.42-.192-.625-.192a1.1 1.1 0 00-1.108 1.09c0 .404.22.764.55.952 2.128 1.19 3.565 3.442 3.565 6.025 0 2.627-1.486 4.913-3.677 6.087-.318.19-.53.54-.53.934 0 .602.496 1.09 1.107 1.09.26.002.568-.15.568-.15 2.835-1.556 4.754-4.538 4.754-7.96' mask='url(%23mask-4)'/%3E%3Cpath d='M30.14 3.057c-.205-.122-.41-.22-.658-.22-.608 0-1.1.485-1.1 1.084 0 .433.26.78.627.977 4.043 2.323 6.762 6.636 6.762 11.578 0 4.938-2.716 9.248-6.755 11.572-.354.19-.66.55-.66.993 0 .6.494 1.084 1.102 1.084.243 0 .438-.092.65-.213 4.692-2.695 7.848-7.7 7.848-13.435 0-5.723-3.142-10.718-7.817-13.418' mask='url(%23mask-6)'/%3E%3C/g%3E%3C/svg%3E")}.am-notice-bar-icon+div{margin-left:5px}.am-notice-bar-operation{display:flex;align-items:center;padding-right:8px}.am-flexbox{text-align:left;overflow:hidden;display:flex;align-items:center}.am-flexbox.am-flexbox-dir-row{flex-direction:row}.am-flexbox.am-flexbox-dir-row-reverse{flex-direction:row-reverse}.am-flexbox.am-flexbox-dir-column{flex-direction:column}.am-flexbox.am-flexbox-dir-column .am-flexbox-item{margin-left:0}.am-flexbox.am-flexbox-dir-column-reverse{flex-direction:column-reverse}.am-flexbox.am-flexbox-dir-column-reverse .am-flexbox-item{margin-left:0}.am-flexbox.am-flexbox-nowrap{flex-wrap:nowrap}.am-flexbox.am-flexbox-wrap{flex-wrap:wrap}.am-flexbox.am-flexbox-wrap-reverse{flex-wrap:wrap-reverse}.am-flexbox.am-flexbox-justify-start{justify-content:flex-start}.am-flexbox.am-flexbox-justify-end{justify-content:flex-end}.am-flexbox.am-flexbox-justify-center{justify-content:center}.am-flexbox.am-flexbox-justify-between{justify-content:space-between}.am-flexbox.am-flexbox-justify-around{justify-content:space-around}.am-flexbox.am-flexbox-align-start{align-items:flex-start}.am-flexbox.am-flexbox-align-end{align-items:flex-end}.am-flexbox.am-flexbox-align-center{align-items:center}.am-flexbox.am-flexbox-align-stretch{align-items:stretch}.am-flexbox.am-flexbox-align-baseline{align-items:baseline}.am-flexbox.am-flexbox-align-content-start{align-content:flex-start}.am-flexbox.am-flexbox-align-content-end{align-content:flex-end}.am-flexbox.am-flexbox-align-content-center{align-content:center}.am-flexbox.am-flexbox-align-content-between{align-content:space-between}.am-flexbox.am-flexbox-align-content-around{align-content:space-around}.am-flexbox.am-flexbox-align-content-stretch{align-content:stretch}.am-flexbox .am-flexbox-item{box-sizing:border-box;flex:1 1;margin-left:8px;min-width:10px}.am-flexbox .am-flexbox-item:first-child{margin-left:0}.am-carousel{position:relative}.am-carousel-wrap{font-size:18px;color:#000;background:none;text-align:center;zoom:1;width:100%}.am-carousel-wrap-dot{display:inline-block;zoom:1}.am-carousel-wrap-dot>span{display:block;width:8px;height:8px;margin:0 3px;border-radius:50%;background:#ccc}.am-carousel-wrap-dot-active>span{background:#888}.am-grid .am-flexbox{background:#fff}.am-grid .am-flexbox .am-flexbox-item{margin-left:0}.am-grid .am-flexbox .am-flexbox-item.am-grid-item{position:relative}.am-grid .am-flexbox .am-flexbox-item.am-grid-item-active .am-grid-item-content{background-color:#ddd}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content{text-align:center;width:100%;height:100%;padding:15px 0}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content{display:flex;flex-direction:column;justify-content:center;align-items:center}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content .am-grid-icon{max-width:100%}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content .am-grid-text{margin-top:9px;font-size:12px;color:#000;text-align:center}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content.column-num-3 .am-grid-text{font-size:16px}.am-grid .am-flexbox .am-flexbox-item .am-grid-item-content .am-grid-item-inner-content.column-num-2 .am-grid-text{margin-top:15px;font-size:18px}.am-grid.am-grid-line{position:relative}.am-grid.am-grid-line:not(.am-grid-carousel){border-top:1px solid #ddd;border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel){border-top:none}html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel){border-right:none}html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line:not(.am-grid-carousel):after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line .am-flexbox{position:relative;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox{border-bottom:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-grid.am-grid-line .am-flexbox .am-flexbox-item{position:relative}.am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child{border-left:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child{border-left:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:1PX;height:100%;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:first-child:before{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child){border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child){border-right:none}html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child):after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line .am-flexbox .am-flexbox-item:not(:last-child):after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-top:1px solid #ddd;border-right:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-top:none}html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page{border-right:none}html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:0;bottom:auto;left:auto;width:1PX;height:100%;background:#ddd;-webkit-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scaleX(.5);transform:scaleX(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-grid.am-grid-line.am-grid-carousel .am-grid-carousel-page:after{-webkit-transform:scaleX(.33);transform:scaleX(.33)}}.am-grid .am-carousel .am-carousel-wrap-dot>span{background:#dcdee3}.am-grid .am-carousel .am-carousel-wrap-dot-active>span{background:#0ae}.am-grid.am-grid-square .am-grid-item:before{display:block;content:" ";padding-bottom:100%}.am-grid.am-grid-square .am-grid-item .am-grid-item-content{position:absolute;top:50%;-webkit-transform:translateY(-50%);transform:translateY(-50%)}.am-grid.am-grid-square .am-grid-item .am-grid-item-inner-content{height:100%}.am-grid.am-grid-square .am-grid-item .am-grid-item-inner-content .am-grid-icon{margin-top:9px;width:28%!important}.am-search{display:flex;align-items:center;height:44px;padding:0 8px;background-color:#efeff4}.am-search,.am-search-input{position:relative;overflow:hidden}.am-search-input{flex:1 1;width:100%;height:28px;background-color:#fff;background-clip:padding-box;border-radius:3px}.am-search-input .am-search-synthetic-ph,.am-search-input input[type=search]{position:absolute;top:0;left:0}.am-search-input .am-search-synthetic-ph{box-sizing:content-box;z-index:1;height:28px;line-height:28px;width:100%;-webkit-transition:width .3s;transition:width .3s;display:block;text-align:center}.am-search-input .am-search-synthetic-ph-icon{display:inline-block;margin-right:5px;width:15px;height:15px;overflow:hidden;vertical-align:-2.5px;background-repeat:no-repeat;background-size:15px auto;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='38' height='36' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M29.05 25.23a15.81 15.81 0 003.004-9.294c0-8.8-7.17-15.934-16.017-15.934C7.192.002.02 7.136.02 15.936c0 8.802 7.172 15.937 16.017 15.937a16 16 0 0010.772-4.143l8.873 8.232 2.296-2.45-8.927-8.282zM16.2 28.933c-7.19 0-13.04-5.788-13.04-12.903 0-7.113 5.85-12.904 13.04-12.904 7.19 0 12.9 5.79 12.9 12.904 0 7.115-5.71 12.903-12.9 12.903z' fill='%23bbb' fill-rule='evenodd'/%3E%3C/svg%3E")}.am-search-input .am-search-synthetic-ph-placeholder{color:#bbb;font-size:15px}.am-search-input input[type=search]{z-index:2;opacity:0;width:100%;text-align:left;display:block;color:#000;height:28px;font-size:15px;background-color:transparent;border:0}.am-search-input input[type=search]::-webkit-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-moz-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-ms-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]:-ms-input-placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::placeholder{background:none;text-align:left;color:transparent}.am-search-input input[type=search]::-webkit-search-cancel-button{-webkit-appearance:none}.am-search-input .am-search-clear{box-sizing:content-box;position:absolute;display:none;z-index:3;width:15px;height:15px;padding:6.5px;border-radius:50%;top:0;right:0;background-color:transparent;background-position:50%;background-repeat:no-repeat;background-size:15px 15px;-webkit-transition:all .3s;transition:all .3s;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Ccircle cx='14' cy='14' r='14' fill='%23ccc'/%3E%3Cpath stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M8 8l12 12'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M20 8L8 20'/%3E%3C/svg%3E")}.am-search-input .am-search-clear-active{background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 28 28'%3E%3Ccircle cx='14' cy='14' r='14' fill='%23108ee9'/%3E%3Cpath stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M8 8l12 12'/%3E%3Cpath fill='none' stroke='%23fff' stroke-width='2' stroke-miterlimit='10' d='M20 8L8 20'/%3E%3C/svg%3E")}.am-search-input .am-search-clear-show{display:block}.am-search-cancel{flex:none;opacity:0;padding-left:8px;height:44px;line-height:44px;font-size:16px;color:#108ee9;text-align:right}.am-search-cancel-anim{-webkit-transition:margin-right .3s,opacity .3s;transition:margin-right .3s,opacity .3s;-webkit-transition-delay:.1s;transition-delay:.1s}.am-search-cancel-show{opacity:1}.am-search.am-search-start .am-search-input input[type=search]{opacity:1;padding:0 28px 0 35px}.am-search.am-search-start .am-search-input input[type=search]::-webkit-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::-moz-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::-ms-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]:-ms-input-placeholder{color:transparent}.am-search.am-search-start .am-search-input input[type=search]::placeholder{color:transparent}.am-search.am-search-start .am-search-input .am-search-synthetic-ph{padding-left:15px;width:auto}.am-checkbox{position:relative;display:inline-block;vertical-align:middle;width:21px;height:21px}.am-checkbox-inner{position:absolute;right:0;width:21px;height:21px;border:1px solid #ccc;border-radius:50%;-webkit-transform:rotate(0deg);transform:rotate(0deg);box-sizing:border-box}.am-checkbox-inner:after{position:absolute;display:none;top:1.5px;right:6px;z-index:999;width:5px;height:11px;border-style:solid;border-width:0 1px 1px 0;content:"\0020";-webkit-transform:rotate(45deg);transform:rotate(45deg)}.am-checkbox-input{position:absolute;top:0;left:0;opacity:0;width:100%;height:100%;z-index:2;border:0;-webkit-appearance:none;-moz-appearance:none;appearance:none}.am-checkbox.am-checkbox-checked .am-checkbox-inner{border-color:#108ee9;background:#108ee9}.am-checkbox.am-checkbox-checked .am-checkbox-inner:after{display:block;border-color:#fff}.am-checkbox.am-checkbox-disabled{opacity:.3}.am-checkbox.am-checkbox-disabled.am-checkbox-checked .am-checkbox-inner{border-color:#888;background:none}.am-checkbox.am-checkbox-disabled.am-checkbox-checked .am-checkbox-inner:after{border-color:#888}.am-list .am-list-item.am-checkbox-item .am-list-thumb{width:21px;height:21px}.am-list .am-list-item.am-checkbox-item .am-list-thumb .am-checkbox{position:absolute;top:0;left:0;right:0;bottom:0;width:100%;height:44px}.am-list .am-list-item.am-checkbox-item .am-list-thumb .am-checkbox-inner{left:15px;top:12px}.am-list .am-list-item.am-checkbox-item.am-checkbox-item-disabled .am-list-content{color:#bbb}.am-checkbox-agree{position:relative;display:flex;align-items:stretch;margin-left:15px;padding-top:9px;padding-bottom:9px}.am-checkbox-agree .am-checkbox{position:absolute;left:0;top:0;width:30px;height:100%}.am-checkbox-agree .am-checkbox-inner{left:0;top:12px}.am-checkbox-agree .am-checkbox-agree-label{display:inline-block;font-size:15px;color:#000;line-height:1.5;margin-left:30px;margin-top:1PX}.am-list .am-list-item.am-textarea-item{display:flex;align-items:flex-start;box-sizing:border-box;min-height:44px;padding-left:15px;padding-right:15px;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-list .am-list-item.am-textarea-item{border-bottom:none}html:not([data-scale]) .am-list .am-list-item.am-textarea-item:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-list .am-list-item.am-textarea-item:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line{align-items:center}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-label{align-self:center}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-control{padding-top:0;padding-bottom:0}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-control textarea{line-height:25.5px}.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line .am-textarea-clear,.am-list .am-list-item.am-textarea-item.am-textarea-item-single-line.am-textarea-error .am-textarea-error-extra{margin-top:0}.am-textarea-label{align-self:flex-start;color:#000;text-align:left;min-height:44px;font-size:17px;line-height:44px;margin-left:0;margin-right:5px;white-space:nowrap;overflow:hidden}.am-textarea-label.am-textarea-label-2{width:34px}.am-textarea-label.am-textarea-label-3{width:51px}.am-textarea-label.am-textarea-label-4{width:68px}.am-textarea-label.am-textarea-label-5{width:85px}.am-textarea-label.am-textarea-label-6{width:102px}.am-textarea-label.am-textarea-label-7{width:119px}.am-textarea-control{flex:1 1;padding-top:10px;padding-bottom:9px}.am-textarea-control textarea{color:#000;font-size:17px;line-height:25.5px;-webkit-appearance:none;-moz-appearance:none;appearance:none;width:100%;padding:0;border:0;background-color:transparent;overflow:visible;display:block;resize:none;word-break:break-word;word-wrap:break-word}.am-textarea-control textarea::-webkit-input-placeholder{color:#bbb}.am-textarea-control textarea::-moz-placeholder{color:#bbb}.am-textarea-control textarea::-ms-input-placeholder{color:#bbb}.am-textarea-control textarea:-ms-input-placeholder{color:#bbb}.am-textarea-control textarea::placeholder{color:#bbb}.am-textarea-control textarea:disabled{color:#bbb;background-color:#fff}.am-textarea-clear{display:none;width:21px;height:21px;margin-top:12px;border-radius:50%;overflow:hidden;font-style:normal;color:#fff;background-color:#ccc;background-repeat:no-repeat;background-size:21px auto;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg fill='%23fff' width='24' height='24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3Cpath d='M0 0h24v24H0z' fill='none'/%3E%3C/svg%3E")}.am-textarea-clear-active{background-color:#108ee9}.am-textarea-focus .am-textarea-clear{display:block}.am-textarea-has-count{padding-bottom:14px}.am-textarea-count{position:absolute;bottom:6px;right:5px;color:#bbb;font-size:14px}.am-textarea-count span{color:#000}.am-textarea-error .am-textarea-control textarea{color:#f50}.am-textarea-error .am-textarea-error-extra{margin-top:12px;width:21px;height:21px;margin-left:8px;background-size:21px 21px;background-image:url("data:image/svg+xml;charset=utf-8,%3Csvg width='18' height='18' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9 1.266a7.69 7.69 0 015.469 2.264c.71.71 1.269 1.538 1.657 2.459.404.954.608 1.967.608 3.011a7.69 7.69 0 01-2.264 5.469 7.694 7.694 0 01-2.459 1.657A7.675 7.675 0 019 16.734a7.69 7.69 0 01-5.469-2.264 7.694 7.694 0 01-1.657-2.459A7.675 7.675 0 011.266 9 7.69 7.69 0 013.53 3.531a7.694 7.694 0 012.459-1.657A7.675 7.675 0 019 1.266zM9 0a9 9 0 00-9 9 9 9 0 009 9 9 9 0 009-9 9 9 0 00-9-9zm0 11.25a.703.703 0 01-.703-.703V4.06a.703.703 0 111.406 0v6.486A.703.703 0 019 11.25zm-.791 1.916a.791.791 0 111.582 0 .791.791 0 01-1.582 0z' fill='%23F50' fill-rule='evenodd'/%3E%3C/svg%3E")}.am-textarea-disabled .am-textarea-label{color:#bbb}.am-list-body .am-list-item:last-child{border-bottom:0}.am-list-body .am-list-item:last-child:after{display:none!important}.am-pull-to-refresh-content{-webkit-transform-origin:left top 0;transform-origin:left top 0}.am-pull-to-refresh-content-wrapper{overflow:hidden}.am-pull-to-refresh-transition{-webkit-transition:-webkit-transform .3s;transition:-webkit-transform .3s;transition:transform .3s;transition:transform .3s,-webkit-transform .3s}.am-pull-to-refresh-indicator{color:grey;text-align:center;height:25px}.am-pull-to-refresh-down .am-pull-to-refresh-indicator{margin-top:-25px}.am-pull-to-refresh-up .am-pull-to-refresh-indicator{margin-bottom:-25px}.am-action-sheet-wrap{overflow:auto;-webkit-overflow-scrolling:touch;outline:0}.am-action-sheet-mask,.am-action-sheet-wrap{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1000}.am-action-sheet-mask{background-color:rgba(0,0,0,.4);height:100%}.am-action-sheet-close,.am-action-sheet-mask-hidden{display:none}.am-action-sheet{position:fixed;left:0;bottom:0;width:100%;background-color:#fff;padding-bottom:env(safe-area-inset-bottom)}.am-action-sheet.am-action-sheet-share{background-color:#f2f2f2}.am-action-sheet-message,.am-action-sheet-title{margin:15px auto;padding:0 15px;text-align:center}.am-action-sheet-title{font-size:17px}.am-action-sheet-message{color:#888;font-size:14px}.am-action-sheet-button-list{text-align:center;color:#000}.am-action-sheet-button-list-item{font-size:18px;padding:0 8px;margin:0;position:relative;height:50px;line-height:50px;box-sizing:border-box;white-space:nowrap;text-overflow:ellipsis;overflow-x:hidden;border-top:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list-item{border-top:none}html:not([data-scale]) .am-action-sheet-button-list-item:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list-item:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-button-list-item.am-action-sheet-button-list-item-active{background-color:#ddd}.am-action-sheet-button-list-badge{display:flex;align-items:center;justify-content:center}.am-action-sheet-button-list-badge .am-badge{margin-left:8px;flex-shrink:0}.am-action-sheet-button-list-item-content{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.am-action-sheet-button-list .am-action-sheet-cancel-button{padding-top:6px;position:relative}.am-action-sheet-button-list .am-action-sheet-cancel-button-mask{position:absolute;top:0;left:0;width:100%;height:6px;background-color:#e7e7ed;border-top:1px solid #ddd;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask{border-top:none}html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask{border-bottom:none}html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-button-list .am-action-sheet-cancel-button-mask:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-button-list .am-action-sheet-destructive-button{color:#f4333c}.am-action-sheet-share-list{display:flex;position:relative;border-top:1px solid #ddd;padding:21px 0 21px 15px;overflow-y:scroll;-webkit-overflow-scrolling:touch}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-share-list{border-top:none}html:not([data-scale]) .am-action-sheet-share-list:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-share-list:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-share-list-item{flex:none;margin:0 12px 0 0}.am-action-sheet-share-list-item-icon{margin-bottom:9px;width:60px;height:60px;background-color:#fff;border-radius:3px;display:flex;justify-content:center;align-items:center}.am-action-sheet-share-list-item-title{color:#888;font-size:10px;text-align:center}.am-action-sheet-share-cancel-button{height:50px;line-height:50px;text-align:center;background-color:#fff;color:#000;font-size:18px;position:relative;border-top:1px solid #ddd;box-sizing:border-box}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-action-sheet-share-cancel-button{border-top:none}html:not([data-scale]) .am-action-sheet-share-cancel-button:before{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:0;right:auto;bottom:auto;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 50%;transform-origin:50% 50%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-action-sheet-share-cancel-button:before{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-action-sheet-share-cancel-button.am-action-sheet-share-cancel-button-active{background-color:#ddd}.am-result{position:relative;text-align:center;width:100%;padding-top:30px;padding-bottom:21px;background-color:#fff;border-bottom:1px solid #ddd}@media (-webkit-min-device-pixel-ratio:2),(min-resolution:2dppx){html:not([data-scale]) .am-result{border-bottom:none}html:not([data-scale]) .am-result:after{content:"";position:absolute;background-color:#ddd;display:block;z-index:1;top:auto;right:auto;bottom:0;left:0;width:100%;height:1PX;-webkit-transform-origin:50% 100%;transform-origin:50% 100%;-webkit-transform:scaleY(.5);transform:scaleY(.5)}}@media (-webkit-min-device-pixel-ratio:2) and (-webkit-min-device-pixel-ratio:3),(min-resolution:2dppx) and (min-resolution:3dppx){html:not([data-scale]) .am-result:after{-webkit-transform:scaleY(.33);transform:scaleY(.33)}}.am-result .am-result-pic{width:60px;height:60px;margin:0 auto;line-height:60px;background-size:60px 60px}.am-result .am-result-message,.am-result .am-result-title{font-size:21px;color:#000;padding-left:15px;padding-right:15px}.am-result .am-result-title{margin-top:15px;line-height:1}.am-result .am-result-message{margin-top:9px;line-height:1.5;font-size:16px;color:#888}.am-result .am-result-button{padding:0 15px;margin-top:15px} \ No newline at end of file diff --git a/docs/static/css/main.5ed7d0b8.chunk.css b/docs/static/css/main.5ed7d0b8.chunk.css deleted file mode 100644 index 540e917..0000000 --- a/docs/static/css/main.5ed7d0b8.chunk.css +++ /dev/null @@ -1 +0,0 @@ -.layout-top{z-index:9999}.am-card{background:#139abf}.tabbar{bottom:0;background:#f5f5f9}.layout-top,.tabbar{position:fixed;width:100%;z-index:999}.layout-top{top:0}.am-card-body div,.am-card-header-content,.am-card-header-extra{color:#f9f9f9}.am-card-footer{color:#f9f9f9;font-weight:700;font-size:32px}.am-card-footer-content{flex:0 1}.am-card-body{position:unset;border-top:unset;padding:0 15px 6px}.home-list-item-money{color:#888;font-size:12px}.home-list-item-number{color:#000;font-size:16px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.am-list-item{background:#fdfdfd!important}.home-list-item-name{font-size:18px;overflow-wrap:break-word;overflow:hidden;text-overflow:ellipsis;color:#64727e}.am-list-item .am-list-line .am-list-extra{flex-basis:50%}.home-list-title{background:#fdfdfd;width:100%;color:#000;font-size:17px;font-weight:700;border-bottom:1px solid #ddd;padding:0 0 10px}.currency-icon-border{border:1px solid #ddd;border-radius:25px;padding:2px}.icon-pkr{width:16px;position:relative;top:4px;margin-right:5px}.icon-select-account-setting{position:relative;float:right;bottom:4px}.show-info{margin-top:18px;display:flex;align-items:center}.show-info .progress{margin-right:5px;width:100%}.btn-bottom{position:fixed;width:100%;bottom:0}.am-tag,.btn-bottom a{margin:5px}.am-tag{display:inline-block;position:relative;font-size:14px!important;text-align:center;height:25px!important;line-height:25px!important;box-sizing:border-box;padding:0 5px!important}.am-tag-normal{background-color:#c7c9f3!important;color:#5d5d5d!important}.tag-div{border-top:1px solid #e4e0e0;border-bottom:1px solid #e4e0e0;padding:10px 0;min-height:30px;margin:0 0 20px}.am-tag-disabled{color:#5d5d5d!important;background-color:#c7c9f3!important;border:1px solid #ddd;border-radius:3px;letter-spacing:1px}.am-tag-active,.customer-tag{background-color:#c7c9f3!important;color:#5d5d5d!important;border:1px solid #ddd!important;border-radius:3px}html:not([data-scale]) .am-tag-active:before{border:1px solid #ddd!important}.my-address{width:50%;float:left;padding:5px 0;font-size:16px;color:#333}.sub-title{color:#333;font-weight:800;font-size:15px;padding:15px 0 9px 15px}.sub-title2{float:right;text-align:right;margin-right:15px;color:#7f7d7d}.not-square-grid .am-grid-icon{width:40px;height:60px}.space-carousel{padding:16px;background:#fdfdfd;overflow:hidden}.dapp-icon{border:1px solid #ddd;border-radius:10px;padding:5px 5px 3px;background:#fcfcfc;box-shadow:1px 1px 9px #ddd}.passwordInput{border:1px solid #ddd;border-radius:5px}.h5-iframe{position:absolute;top:0;left:0;right:0;bottom:0;margin:45px 0 0;padding:0;width:100%;z-index:100}.dapp-img{width:48px;height:48px}.popup-list{white-space:normal!important;font-size:16px}.popup-list a{color:#108ee9}.browser-right{border-radius:15px;padding:5px 10px 1px;width:60px}.browser-right div:first-child{float:left;width:30px}.browser-right div:nth-child(3){float:right}.ant-divider-vertical.ant-divider-dashed{border-width:0 0 0 1px}.ant-divider-dashed{background:none;border:dashed #f0f0f0;border-width:1px 0 0}.ant-divider,.ant-divider-vertical{position:relative;top:-.06em;display:inline-block;width:1px;height:.9em;margin:0 8px;vertical-align:middle}.ant-divider{box-sizing:border-box;margin:0;padding:0;color:rgba(0,0,0,.65);font-size:14px;font-variant:tabular-nums;line-height:1.5715;list-style:none;font-feature-settings:"tnum","tnum","tnum";background:#f0f0f0}.card-img{top:-60px;right:45px}.card-icon,.card-img{position:relative;float:right}.card-icon{top:-16px;color:#f3e2c8}.list-address{overflow-wrap:break-word;color:#333;margin-top:6px;font-size:13px}.address-add-iconscan{position:relative;float:right;bottom:122px;color:#333;right:10px}.bottom-p{text-align:center;font-size:17px;height:60px}.bottom-p,.income-span{color:#24bdd2}.payout-span{color:#198fea}.bottom-button-div{position:fixed;width:100%;bottom:0;background:#fdfdfd;padding:5px}.bottom-button-div-left{width:30%;float:left;margin-left:10px}.bottom-button-div-right{width:60%;float:right;margin-right:15px;padding:0 2px}.bottom-button-div-receive{background:#24bdd2;color:#fff;font-size:14px}.bottom-button-div-transfer{background:#198fea;color:#fff;font-size:14px}.transfer-nav-header{position:fixed;width:100%;top:0;z-index:1}.transfer-detail{height:600px;border-radius:15px;background:#f7f7f7;color:#333;filter:progid:DXImageTransform.Microsoft.Shadow(color=#ddd,direction=120,strength=4);box-shadow:2px 2px 10px #ddd}.transfer-detail-bg{background:-webkit-gradient(linear,left top,left bottom,from(#198fea),to(#f7f7f7));background:linear-gradient(180deg,#198fea,#f7f7f7)}.transfer-detail-nav{background:-webkit-gradient(linear,left top,left bottom,from(#0061b8),to(#198fea));background:linear-gradient(180deg,#0061b8,#198fea)}.transfer-detail-indiv0{border-bottom:1px dashed #ddd;height:20%;margin:0 15px 25px;text-align:center}.transfer-detail-indiv0-icon{color:#32a14a;position:relative;top:10px}.transfer-detail-indiv0-span{color:#888;position:relative;bottom:10px;font-size:12px}.transfer-detail-indiv1{border-bottom:1px dashed #ddd;height:55%;margin:0 15px 25px}.transfer-detail-flex-content{flex-basis:80%}.transfer-detail-copy-icon{color:#cac4c4;width:14px;height:14px}.transfer-detail-p{text-align:center}.coin{min-height:120px;background:#fdfdfd;font-size:14px}.coin .title{height:30px;line-height:3;padding:0 15px}.coin .title .left{width:20%;float:left;text-align:left}.coin .title .right{width:80%;float:right;text-align:right;color:#008cec}.coin .content{height:70px}.address{min-height:135px;background:#fdfdfd;font-size:14px;overflow:hidden}.address .title{height:30px;line-height:3;padding:0 15px}.address .title .left{width:50%;float:left;text-align:left}.address .title .right{width:50%;float:right;text-align:right;color:#008cec}.address .content{float:left;width:100%}.fee{padding:15px 0;background:#fdfdfd;font-size:14px;overflow:hidden;clear:both}.fee .title{height:30px;line-height:1.8;padding:0 15px}.fee .title .left{width:20%;float:left;text-align:left}.fee .title .right{width:80%;float:left;text-align:left;color:#008cec}.fee .content{height:70px;float:left;width:100%}.transfer-receive-header{background:#1a92bb;height:60px;border-top-right-radius:8px;border-top-left-radius:8px;text-align:center;color:#f7f7f7;padding:40px 0 30px}.transfer-receive-body{background:#fff;border-bottom-left-radius:8px;border-bottom-right-radius:8px;text-align:center;padding:0 45px}.transfer-receive-icon{text-align:center;background-color:#f7f7f7;border-radius:5px;width:45px;height:45px;position:absolute;left:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);padding:3px}.transfer-receive-border{padding:30px 15px 0}.transfer-receive-header-hash{overflow-wrap:break-word;padding:5px 15px 20px;font-size:12px}.transfer-result-hash{overflow-wrap:break-word;font-size:15px;color:#333;font-weight:800;background:#f7f7f7;text-align:center;padding:15px}.transfer-bottom-button{position:fixed;bottom:0;width:97%;padding:5px}.am-tabs-default-bar .am-tabs-default-bar-animated .am-tabs-default-bar-top{background-color:#f7f7f7!important}.transfer-address{float:right;bottom:152px;position:relative;color:#008cec}.my-header{background-color:#f7f7f7;width:100%;text-align:center}#log{background:#000;color:#f7f7f7;padding:10px 15px;min-height:100%;height:auto;width:93%;white-space:nowrap;word-break:break-all;text-overflow:ellipsis}#log small{color:coral}.log span:first-child{color:#2efdfe;font-size:12px}.log span:nth-child(2){color:#f7f7f7;width:95%;white-space:normal;word-break:break-all;font-size:12px}.tdpy-bg{background:#fdfdfd;height:auto;padding:10px}.tdpy-span{color:#4e555b;font-weight:400}.tdpy-card{border-radius:5px;background:#f7f7f7;padding:1px}.tdp-remark{position:fixed;width:100%;bottom:0;text-align:center;padding:0 0 5px}.tdp-remark h3{color:#4e555b}.tdp-remark p{color:#8f8f8f;font-size:10px}.dataWr{word-wrap:break-word;word-break:normal;white-space:normal;height:90px;overflow-y:scroll;background:#f8f9fa;line-height:1;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace!important;font-size:.8125rem;font-weight:400;line-height:1.5;color:#1e2022;background-clip:padding-box;border:1px solid #d5dae2;border-radius:.25rem;-webkit-transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}.resultIcon{color:#32a14a;position:relative;top:10px;width:48px;height:48px}html{touch-action:none}.am-button-primary{background-color:#4e73df}.am-navbar-left{padding-left:15px;font-size:16px;color:#333}.am-navbar-light{background-color:#f7f7f7;color:#333}.am-tab-bar-bar{border-top:unset!important}.icon-avatar{border:1px solid #ddd;border-radius:5px;background:#fff;margin-right:5px;padding:3px}.icon-qrcode{width:14px;position:relative;top:5px;left:10px}.am-modal-transparent{width:82%!important} \ No newline at end of file diff --git a/docs/static/css/main.8cf1853d.chunk.css b/docs/static/css/main.8cf1853d.chunk.css new file mode 100644 index 0000000..0b57557 --- /dev/null +++ b/docs/static/css/main.8cf1853d.chunk.css @@ -0,0 +1 @@ +.layout-top{z-index:9999}.am-card{background:#139abf}.tabbar{bottom:0;background:#f5f5f9}.layout-top,.tabbar{position:fixed;width:100%;z-index:999}.layout-top{top:0}.am-card-body div,.am-card-header-content,.am-card-header-extra{color:#f9f9f9}.am-card-footer{color:#f9f9f9;font-weight:700;font-size:32px}.am-card-footer-content{flex:0 1}.am-card-body{position:unset;border-top:unset;padding:0 15px 6px}.home-list-item-money{color:#888;font-size:12px}.home-list-item-number{color:#000;font-size:16px;text-overflow:ellipsis;overflow:hidden;white-space:nowrap}.am-list-item{background:#fdfdfd!important}.home-list-item-name{font-size:18px;overflow-wrap:break-word;overflow:hidden;text-overflow:ellipsis;color:#64727e}.am-list-item .am-list-line .am-list-extra{flex-basis:50%}.home-list-title{background:#fdfdfd;width:100%;color:#000;font-size:17px;font-weight:700;border-bottom:1px solid #ddd;padding:0 0 10px}.currency-icon-border{border:1px solid #ddd;border-radius:25px;padding:2px}.icon-pkr{width:16px;position:relative;top:4px;margin-right:5px}.icon-select-account-setting{position:relative;float:right;bottom:4px}.sync-progress{top:auto!important}.show-info{margin-top:18px;display:flex;align-items:center}.show-info .progress{margin-right:5px;width:100%}.btn-bottom{position:fixed;width:100%;bottom:0}.am-tag,.btn-bottom a{margin:5px}.am-tag{display:inline-block;position:relative;font-size:14px!important;text-align:center;height:25px!important;line-height:25px!important;box-sizing:border-box;padding:0 5px!important}.am-tag-normal{background-color:#c7c9f3!important;color:#5d5d5d!important}.tag-div{border-top:1px solid #e4e0e0;border-bottom:1px solid #e4e0e0;padding:10px 0;min-height:30px;margin:0 0 20px}.am-tag-disabled{color:#5d5d5d!important;background-color:#c7c9f3!important;border:1px solid #ddd;border-radius:3px;letter-spacing:1px}.am-tag-active,.customer-tag{background-color:#c7c9f3!important;color:#5d5d5d!important;border:1px solid #ddd!important;border-radius:3px}html:not([data-scale]) .am-tag-active:before{border:1px solid #ddd!important}.my-address{width:50%;float:left;padding:5px 0;font-size:16px;color:#333}.sub-title{color:#333;font-weight:800;font-size:15px;padding:15px 0 9px 15px}.sub-title2{float:right;text-align:right;margin-right:15px;color:#7f7d7d}.not-square-grid .am-grid-icon{width:40px;height:60px}.space-carousel{padding:16px;background:#fdfdfd;overflow:hidden}.dapp-icon{border:1px solid #ddd;border-radius:10px;padding:5px 5px 3px;background:#fcfcfc;box-shadow:1px 1px 9px #ddd}.passwordInput{border:1px solid #ddd;border-radius:5px}.h5-iframe{position:absolute;top:0;left:0;right:0;bottom:0;margin:45px 0 0;padding:0;width:100%;z-index:100}.dapp-img{width:48px;height:48px}.popup-list{white-space:normal!important;font-size:16px}.popup-list a{color:#108ee9}.browser-right{border-radius:15px;padding:5px 10px 1px;width:60px}.browser-right div:first-child{float:left;width:30px}.browser-right div:nth-child(3){float:right}.ant-divider-vertical.ant-divider-dashed{border-width:0 0 0 1px}.ant-divider-dashed{background:none;border:dashed #f0f0f0;border-width:1px 0 0}.ant-divider,.ant-divider-vertical{position:relative;top:-.06em;display:inline-block;width:1px;height:.9em;margin:0 8px;vertical-align:middle}.ant-divider{box-sizing:border-box;margin:0;padding:0;color:rgba(0,0,0,.65);font-size:14px;font-variant:tabular-nums;line-height:1.5715;list-style:none;font-feature-settings:"tnum","tnum","tnum";background:#f0f0f0}.card-img{top:-60px;right:45px}.card-icon,.card-img{position:relative;float:right}.card-icon{top:-16px;color:#f3e2c8}.list-address{overflow-wrap:break-word;color:#333;margin-top:6px;font-size:13px}.address-add-iconscan{position:relative;float:right;bottom:122px;color:#333;right:10px}.bottom-p{text-align:center;font-size:17px;height:60px}.bottom-p,.income-span{color:#24bdd2}.payout-span{color:#198fea}.bottom-button-div{position:fixed;width:100%;bottom:0;background:#fdfdfd;padding:5px}.bottom-button-div-left{width:30%;float:left;margin-left:10px}.bottom-button-div-right{width:60%;float:right;margin-right:15px;padding:0 2px}.bottom-button-div-receive{background:#24bdd2;color:#fff;font-size:14px}.bottom-button-div-transfer{background:#198fea;color:#fff;font-size:14px}.transfer-nav-header{position:fixed;width:100%;top:0;z-index:1}.transfer-detail{height:600px;border-radius:15px;background:#f7f7f7;color:#333;filter:progid:DXImageTransform.Microsoft.Shadow(color=#ddd,direction=120,strength=4);box-shadow:2px 2px 10px #ddd}.transfer-detail-bg{background:-webkit-gradient(linear,left top,left bottom,from(#198fea),to(#f7f7f7));background:linear-gradient(180deg,#198fea,#f7f7f7)}.transfer-detail-nav{background:-webkit-gradient(linear,left top,left bottom,from(#0061b8),to(#198fea));background:linear-gradient(180deg,#0061b8,#198fea)}.transfer-detail-indiv0{border-bottom:1px dashed #ddd;height:20%;margin:0 15px 25px;text-align:center}.transfer-detail-indiv0-icon{color:#32a14a;position:relative;top:10px}.transfer-detail-indiv0-span{color:#888;position:relative;bottom:10px;font-size:12px}.transfer-detail-indiv1{border-bottom:1px dashed #ddd;height:55%;margin:0 15px 25px}.transfer-detail-flex-content{flex-basis:80%}.transfer-detail-copy-icon{color:#cac4c4;width:14px;height:14px}.transfer-detail-p{text-align:center}.coin{min-height:120px;background:#fdfdfd;font-size:14px}.coin .title{height:30px;line-height:3;padding:0 15px}.coin .title .left{width:20%;float:left;text-align:left}.coin .title .right{width:80%;float:right;text-align:right;color:#008cec}.coin .content{height:70px}.address{min-height:135px;background:#fdfdfd;font-size:14px;overflow:hidden}.address .title{height:30px;line-height:3;padding:0 15px}.address .title .left{width:50%;float:left;text-align:left}.address .title .right{width:50%;float:right;text-align:right;color:#008cec}.address .content{float:left;width:100%}.fee{padding:15px 0;background:#fdfdfd;font-size:14px;overflow:hidden;clear:both}.fee .title{height:30px;line-height:1.8;padding:0 15px}.fee .title .left{width:20%;float:left;text-align:left}.fee .title .right{width:80%;float:left;text-align:left;color:#008cec}.fee .content{height:70px;float:left;width:100%}.transfer-receive-header{background:#1a92bb;height:60px;border-top-right-radius:8px;border-top-left-radius:8px;text-align:center;color:#f7f7f7;padding:40px 0 30px}.transfer-receive-body{background:#fff;border-bottom-left-radius:8px;border-bottom-right-radius:8px;text-align:center;padding:0 45px}.transfer-receive-icon{text-align:center;background-color:#f7f7f7;border-radius:5px;width:45px;height:45px;position:absolute;left:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%);padding:3px}.transfer-receive-border{padding:30px 15px 0}.transfer-receive-header-hash{overflow-wrap:break-word;padding:5px 15px 20px;font-size:12px}.transfer-result-hash{overflow-wrap:break-word;font-size:15px;color:#333;font-weight:800;background:#f7f7f7;text-align:center;padding:15px}.transfer-bottom-button{position:fixed;bottom:0;width:97%;padding:5px}.am-tabs-default-bar .am-tabs-default-bar-animated .am-tabs-default-bar-top{background-color:#f7f7f7!important}.transfer-address{float:right;bottom:152px;position:relative;color:#008cec}.my-header{background-color:#f7f7f7;width:100%;text-align:center}#log{background:#000;color:#f7f7f7;padding:10px 15px;min-height:100%;height:auto;width:93%;white-space:nowrap;word-break:break-all;text-overflow:ellipsis}#log small{color:coral}.log span:first-child{color:#2efdfe;font-size:12px}.log span:nth-child(2){color:#f7f7f7;width:95%;white-space:normal;word-break:break-all;font-size:12px}.tdpy-bg{background:#fdfdfd;height:auto;padding:10px}.tdpy-span{color:#4e555b;font-weight:400}.tdpy-card{border-radius:5px;background:#f7f7f7;padding:1px}.tdp-remark{position:fixed;width:100%;bottom:0;text-align:center;padding:0 0 5px}.tdp-remark h3{color:#4e555b}.tdp-remark p{color:#8f8f8f;font-size:10px}.dataWr{word-wrap:break-word;word-break:normal;white-space:normal;height:90px;overflow-y:scroll;background:#f8f9fa;line-height:1;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace!important;font-size:.8125rem;font-weight:400;line-height:1.5;color:#1e2022;background-clip:padding-box;border:1px solid #d5dae2;border-radius:.25rem;-webkit-transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out;transition:border-color .15s ease-in-out,box-shadow .15s ease-in-out}.resultIcon{color:#32a14a;position:relative;top:10px;width:48px;height:48px}html{touch-action:none}.am-button-primary{background-color:#4e73df}.am-navbar-left{padding-left:15px;font-size:16px;color:#333}.am-navbar-light{background-color:#f7f7f7;color:#333}.am-tab-bar-bar{border-top:unset!important}.icon-avatar{border:1px solid #ddd;border-radius:5px;background:#fff;margin-right:5px;padding:3px}.icon-qrcode{width:14px;position:relative;top:5px;left:10px}.am-modal-transparent{width:82%!important} \ No newline at end of file diff --git a/docs/static/js/0.25e92e06.chunk.worker.js b/docs/static/js/0.25e92e06.chunk.worker.js new file mode 100644 index 0000000..345fbf1 --- /dev/null +++ b/docs/static/js/0.25e92e06.chunk.worker.js @@ -0,0 +1 @@ +!function(t){var e={};function r(i){if(e[i])return e[i].exports;var n=e[i]={i:i,l:!1,exports:{}};return t[i].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.m=t,r.c=e,r.d=function(t,e,i){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},r.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)r.d(i,n,function(e){return t[e]}.bind(null,n));return i},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="./",r(r.s=145)}([function(t,e,r){"use strict";(function(t){var i=r(149),n=r(150),o=r(68);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(t,e){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|t}function p(t,e){if(u.isBuffer(t))return t.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!==typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var i=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return U(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return F(t).length;default:if(i)return U(t).length;e=(""+e).toLowerCase(),i=!0}}function m(t,e,r){var i=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return C(this,e,r);case"utf8":case"utf-8":return E(this,e,r);case"ascii":return x(this,e,r);case"latin1":case"binary":return B(this,e,r);case"base64":return S(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,e,r);default:if(i)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),i=!0}}function g(t,e,r){var i=t[e];t[e]=t[r],t[r]=i}function b(t,e,r,i,n){if(0===t.length)return-1;if("string"===typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=n?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(n)return-1;r=t.length-1}else if(r<0){if(!n)return-1;r=0}if("string"===typeof e&&(e=u.from(e,i)),u.isBuffer(e))return 0===e.length?-1:v(t,e,r,i,n);if("number"===typeof e)return e&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):v(t,[e],r,i,n);throw new TypeError("val must be string, number or Buffer")}function v(t,e,r,i,n){var o,a=1,s=t.length,u=e.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(t.length<2||e.length<2)return-1;a=2,s/=2,u/=2,r/=2}function h(t,e){return 1===a?t[e]:t.readUInt16BE(e*a)}if(n){var f=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){for(var c=!0,l=0;ln&&(i=n):i=n;var o=e.length;if(o%2!==0)throw new TypeError("Invalid hex string");i>o/2&&(i=o/2);for(var a=0;a>8,n=r%256,o.push(n),o.push(i);return o}(e,t.length-r),t,r,i)}function S(t,e,r){return 0===e&&r===t.length?i.fromByteArray(t):i.fromByteArray(t.slice(e,r))}function E(t,e,r){r=Math.min(t.length,r);for(var i=[],n=e;n239?4:h>223?3:h>191?2:1;if(n+c<=r)switch(c){case 1:h<128&&(f=h);break;case 2:128===(192&(o=t[n+1]))&&(u=(31&h)<<6|63&o)>127&&(f=u);break;case 3:o=t[n+1],a=t[n+2],128===(192&o)&&128===(192&a)&&(u=(15&h)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(f=u);break;case 4:o=t[n+1],a=t[n+2],s=t[n+3],128===(192&o)&&128===(192&a)&&128===(192&s)&&(u=(15&h)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(f=u)}null===f?(f=65533,c=1):f>65535&&(f-=65536,i.push(f>>>10&1023|55296),f=56320|1023&f),i.push(f),n+=c}return function(t){var e=t.length;if(e<=k)return String.fromCharCode.apply(String,t);var r="",i=0;for(;i0&&(t=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(t+=" ... ")),""},u.prototype.compare=function(t,e,r,i,n){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),e<0||r>t.length||i<0||n>this.length)throw new RangeError("out of range index");if(i>=n&&e>=r)return 0;if(i>=n)return-1;if(e>=r)return 1;if(this===t)return 0;for(var o=(n>>>=0)-(i>>>=0),a=(r>>>=0)-(e>>>=0),s=Math.min(o,a),h=this.slice(i,n),f=t.slice(e,r),c=0;cn)&&(r=n),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var o=!1;;)switch(i){case"hex":return y(this,t,e,r);case"utf8":case"utf-8":return w(this,t,e,r);case"ascii":return _(this,t,e,r);case"latin1":case"binary":return M(this,t,e,r);case"base64":return A(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var k=4096;function x(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;ni)&&(r=i);for(var n="",o=e;or)throw new RangeError("Trying to access beyond buffer length")}function R(t,e,r,i,n,o){if(!u.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>n||et.length)throw new RangeError("Index out of range")}function O(t,e,r,i){e<0&&(e=65535+e+1);for(var n=0,o=Math.min(t.length-r,2);n>>8*(i?n:1-n)}function j(t,e,r,i){e<0&&(e=4294967295+e+1);for(var n=0,o=Math.min(t.length-r,4);n>>8*(i?n:3-n)&255}function D(t,e,r,i,n,o){if(r+i>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function N(t,e,r,i,o){return o||D(t,0,r,4),n.write(t,e,r,i,23,4),r+4}function z(t,e,r,i,o){return o||D(t,0,r,8),n.write(t,e,r,i,52,8),r+8}u.prototype.slice=function(t,e){var r,i=this.length;if((t=~~t)<0?(t+=i)<0&&(t=0):t>i&&(t=i),(e=void 0===e?i:~~e)<0?(e+=i)<0&&(e=0):e>i&&(e=i),e0&&(n*=256);)i+=this[t+--e]*n;return i},u.prototype.readUInt8=function(t,e){return e||P(t,1,this.length),this[t]},u.prototype.readUInt16LE=function(t,e){return e||P(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUInt16BE=function(t,e){return e||P(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUInt32LE=function(t,e){return e||P(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUInt32BE=function(t,e){return e||P(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readIntLE=function(t,e,r){t|=0,e|=0,r||P(t,e,this.length);for(var i=this[t],n=1,o=0;++o=(n*=128)&&(i-=Math.pow(2,8*e)),i},u.prototype.readIntBE=function(t,e,r){t|=0,e|=0,r||P(t,e,this.length);for(var i=e,n=1,o=this[t+--i];i>0&&(n*=256);)o+=this[t+--i]*n;return o>=(n*=128)&&(o-=Math.pow(2,8*e)),o},u.prototype.readInt8=function(t,e){return e||P(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function(t,e){e||P(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(t,e){e||P(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(t,e){return e||P(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,e){return e||P(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readFloatLE=function(t,e){return e||P(t,4,this.length),n.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,e){return e||P(t,4,this.length),n.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,e){return e||P(t,8,this.length),n.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,e){return e||P(t,8,this.length),n.read(this,t,!1,52,8)},u.prototype.writeUIntLE=function(t,e,r,i){(t=+t,e|=0,r|=0,i)||R(this,t,e,r,Math.pow(2,8*r)-1,0);var n=1,o=0;for(this[e]=255&t;++o=0&&(o*=256);)this[e+n]=t/o&255;return e+r},u.prototype.writeUInt8=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,1,255,0),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},u.prototype.writeUInt16LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):O(this,t,e,!0),e+2},u.prototype.writeUInt16BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):O(this,t,e,!1),e+2},u.prototype.writeUInt32LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):j(this,t,e,!0),e+4},u.prototype.writeUInt32BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):j(this,t,e,!1),e+4},u.prototype.writeIntLE=function(t,e,r,i){if(t=+t,e|=0,!i){var n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}var o=0,a=1,s=0;for(this[e]=255&t;++o>0)-s&255;return e+r},u.prototype.writeIntBE=function(t,e,r,i){if(t=+t,e|=0,!i){var n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}var o=r-1,a=1,s=0;for(this[e+o]=255&t;--o>=0&&(a*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+r},u.prototype.writeInt8=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,1,127,-128),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},u.prototype.writeInt16LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):O(this,t,e,!0),e+2},u.prototype.writeInt16BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):O(this,t,e,!1),e+2},u.prototype.writeInt32LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):j(this,t,e,!0),e+4},u.prototype.writeInt32BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):j(this,t,e,!1),e+4},u.prototype.writeFloatLE=function(t,e,r){return N(this,t,e,!0,r)},u.prototype.writeFloatBE=function(t,e,r){return N(this,t,e,!1,r)},u.prototype.writeDoubleLE=function(t,e,r){return z(this,t,e,!0,r)},u.prototype.writeDoubleBE=function(t,e,r){return z(this,t,e,!1,r)},u.prototype.copy=function(t,e,r,i){if(r||(r=0),i||0===i||(i=this.length),e>=t.length&&(e=t.length),e||(e=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-e=0;--n)t[n+e]=this[n+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(n=0;n>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"===typeof t)for(o=e;o55295&&r<57344){if(!n){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(a+1===i){(e-=3)>-1&&o.push(239,191,189);continue}n=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),n=r;continue}r=65536+(n-55296<<10|r-56320)}else n&&(e-=3)>-1&&o.push(239,191,189);if(n=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=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((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function F(t){return i.toByteArray(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(K,"")).length<2)return"";for(;t.length%4!==0;)t+="=";return t}(t))}function L(t,e,r,i){for(var n=0;n=e.length||n>=t.length);++n)e[n+r]=t[n];return n}}).call(this,r(10))},function(t,e){"function"===typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},function(t,e,r){var i=r(0),n=i.Buffer;function o(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=i:(o(i,e),e.Buffer=a),o(n,a),a.from=function(t,e,r){if("number"===typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},a.alloc=function(t,e,r){if("number"!==typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"===typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},a.allocUnsafe=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return n(t)},a.allocUnsafeSlow=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return i.SlowBuffer(t)}},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(19),n=r(152)("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),o=r(69),a=r(154),s=r(155),u=r(157),h=r(158),f=r(164),c=r(4);function l(e){var r;if(e instanceof t)r=e;else if(g(e))r=t.from(o(e),"hex");else{if(!m(e))return e;r=n.decode(e)}return n.encode(r)}function d(t,e,r){return o(t)+new Array(e-o(t).length+1).join(r||"0")}function p(t,e,r){return new Array(e-o(t).length+1).join(r||"0")+o(t)}function m(t){return/^[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{80,}$/i.test(t)}function g(t){return 0==t.indexOf("0x")&&(t=t.slice(2)),t.length%2==0&&/^(-)?[0-9a-f]*$/i.test(t)}function b(t){var e="";t=(t=(t=(t=(t=a.encode(t)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r>>4).toString(16)),e.push((15&t[r]).toString(16));return"0x"+e.join("")},hexToBytes:function(e){var r=t.from(o(e),"hex");return new Uint8Array(r)},utf8ToHex:b,bs58ToHex:function(t){return"0x"+n.decode(t).toString("hex")},bytesToBase58:function(t){return n.encode(t.buffer)},padLeft:p,padRight:d,bufferToHex:function(t){return"0x"+t.toString("hex")},cyToHex:function(t){return"0x"+p(b(t.toUpperCase()),64,"0")},hexToBN:function(t){return w(o(t))},hexToCy:y,toBN:w,isNotNull:function(t){return!u(t)&&void 0!==t},toBuffer:_,bufferToBN:function(t){return new i(t,"le")},isEmptyBuffer:function(e,r){return void 0===r&&(r=32),0==e.length||0==t.alloc(r).compare(e)},bufferToBs58:function(t){return n.encode(t)},addrToString:l};e.default=M}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(e){function i(t,e){if(t===e)return 0;for(var r=t.length,i=e.length,n=0,o=Math.min(r,i);n=0;h--)if(f[h]!==c[h])return!1;for(h=f.length-1;h>=0;h--)if(u=f[h],!v(t[u],e[u],r,i))return!1;return!0}(t,e,r,a))}return r?t===e:t==e}function y(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function w(t,e){if(!t||!e)return!1;if("[object RegExp]"==Object.prototype.toString.call(e))return e.test(t);try{if(t instanceof e)return!0}catch(r){}return!Error.isPrototypeOf(e)&&!0===e.call({},t)}function _(t,e,r,i){var n;if("function"!==typeof e)throw new TypeError('"block" argument must be a function');"string"===typeof r&&(i=r,r=null),n=function(t){var e;try{t()}catch(r){e=r}return e}(e),i=(r&&r.name?" ("+r.name+").":".")+(i?" "+i:"."),t&&!n&&g(n,r,"Missing expected exception"+i);var a="string"===typeof i,s=!t&&n&&!r;if((!t&&o.isError(n)&&a&&w(n,r)||s)&&g(n,r,"Got unwanted exception"+i),t&&n&&r&&!w(n,r)||!t&&n)throw n}c.AssertionError=function(t){this.name="AssertionError",this.actual=t.actual,this.expected=t.expected,this.operator=t.operator,t.message?(this.message=t.message,this.generatedMessage=!1):(this.message=function(t){return p(m(t.actual),128)+" "+t.operator+" "+p(m(t.expected),128)}(this),this.generatedMessage=!0);var e=t.stackStartFunction||g;if(Error.captureStackTrace)Error.captureStackTrace(this,e);else{var r=new Error;if(r.stack){var i=r.stack,n=d(e),o=i.indexOf("\n"+n);if(o>=0){var a=i.indexOf("\n",o+1);i=i.substring(a+1)}this.stack=i}}},o.inherits(c.AssertionError,Error),c.fail=g,c.ok=b,c.equal=function(t,e,r){t!=e&&g(t,e,r,"==",c.equal)},c.notEqual=function(t,e,r){t==e&&g(t,e,r,"!=",c.notEqual)},c.deepEqual=function(t,e,r){v(t,e,!1)||g(t,e,r,"deepEqual",c.deepEqual)},c.deepStrictEqual=function(t,e,r){v(t,e,!0)||g(t,e,r,"deepStrictEqual",c.deepStrictEqual)},c.notDeepEqual=function(t,e,r){v(t,e,!1)&&g(t,e,r,"notDeepEqual",c.notDeepEqual)},c.notDeepStrictEqual=function t(e,r,i){v(e,r,!0)&&g(e,r,i,"notDeepStrictEqual",t)},c.strictEqual=function(t,e,r){t!==e&&g(t,e,r,"===",c.strictEqual)},c.notStrictEqual=function(t,e,r){t===e&&g(t,e,r,"!==",c.notStrictEqual)},c.throws=function(t,e,r){_(!0,t,e,r)},c.doesNotThrow=function(t,e,r){_(!1,t,e,r)},c.ifError=function(t){if(t)throw t};var M=Object.keys||function(t){var e=[];for(var r in t)a.call(t,r)&&e.push(r);return e}}).call(this,r(10))},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(224).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):r.strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(19),n=r(47),o=r(3),a=r(48),s=function(){function e(t){if(t instanceof e)this.n=t.n;else if(t instanceof i){var r=t;r.red?this.n=r:this.n=r.toRed(e.red)}else this.n=new i(t,"le").toRed(e.red)}return e.toFQ=function(t){return t instanceof e?t:new e(t)},e.prototype.add=function(t){return new e(this.n.redAdd(e.toFQ(t).n))},e.prototype.mul=function(t){return new e(this.n.redMul(e.toFQ(t).n))},e.prototype.sub=function(t){return new e(this.n.redSub(e.toFQ(t).n))},e.prototype.div=function(t){return new e(this.n.redMul(e.toFQ(t).n.redInvm()))},e.prototype.squared=function(){return new e(this.n.redSqr())},e.prototype.sqrt=function(){try{var t=this.n.redSqrt();return t?new e(t):void 0}catch(t){return}},e.prototype.pow=function(t){return new e(this.n.redPow(new i(t)))},e.prototype.nega=function(){return new e(this.n.redNeg())},e.prototype.inverse=function(){return new e(this.n.redInvm())},e.prototype.isOdd=function(){return this.n.fromRed().isOdd()},e.prototype.isZero=function(){return this.n.fromRed().isZero()},e.prototype.toBuffer=function(){return this.n.fromRed().toArrayLike(t,"le",32)},e.prototype.toBN=function(){return this.n.fromRed()},e.prototype.equal=function(t){return this.n.eq(t.n)},e.prototype.toString=function(t){return this.n.fromRed().toString(t)},e.red=i.mont(n.default.FQ_MODULUS),e.ONE=new e(1),e.ZERO=new e(0),e}();e.FQ=s;var u=function(){function e(t){if(t instanceof e)this.n=t.n;else if(t instanceof i){var r=t;r.red?this.n=r:this.n=r.toRed(e.red)}else this.n="number"==typeof t?new i(t).toRed(e.red):new i(t,"le").toRed(e.red)}return e.toFR=function(t){return t instanceof e?t:new e(t)},e.prototype.add=function(t){return new e(this.n.redAdd(e.toFR(t).n))},e.prototype.mul=function(t){return new e(this.n.redMul(e.toFR(t).n))},e.prototype.sub=function(t){return new e(this.n.redSub(e.toFR(t).n))},e.prototype.div=function(t){return new e(this.n.redMul(e.toFR(t).n.redInvm()))},e.prototype.squared=function(){return new e(this.n.redSqr())},e.prototype.sqrt=function(){try{var t=this.n.redSqrt();return t?new e(t):void 0}catch(t){return}},e.prototype.pow=function(t){return new e(this.n.redPow(new i(t)))},e.prototype.nega=function(){return new e(this.n.redNeg())},e.prototype.inverse=function(){return new e(this.n.redInvm())},e.prototype.isOdd=function(){return this.n.fromRed().isOdd()},e.prototype.isZero=function(){return this.n.fromRed().isZero()},e.prototype.toBuffer=function(){return this.n.fromRed().toArrayLike(t,"le",32)},e.prototype.toBN=function(){return this.n.fromRed()},e.prototype.equal=function(t){return this.n.eq(t.n)},e.prototype.toString=function(t){return this.n.fromRed().toString(t)},e.red=i.mont(n.default.FR_MODULUS),e.ONE=new e(1),e.ZERO=new e(0),e}();function h(t){if(t instanceof u)return t;var e=o.toBuffer(t);return new u(e)}e.FR=u,e.newFR=h,e.randomFR=function(){return h(a.randomBytes(32))}}).call(this,r(0).Buffer)},function(t,e,r){var i=r(0),n=i.Buffer;function o(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=i:(o(i,e),e.Buffer=a),a.prototype=Object.create(n.prototype),o(n,a),a.from=function(t,e,r){if("number"===typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},a.alloc=function(t,e,r){if("number"!==typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"===typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},a.allocUnsafe=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return n(t)},a.allocUnsafeSlow=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return i.SlowBuffer(t)}},function(t,e){var r,i,n=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(r===setTimeout)return setTimeout(t,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(t,0);try{return r(t,0)}catch(e){try{return r.call(null,t,0)}catch(e){return r.call(this,t,0)}}}!function(){try{r="function"===typeof setTimeout?setTimeout:o}catch(t){r=o}try{i="function"===typeof clearTimeout?clearTimeout:a}catch(t){i=a}}();var u,h=[],f=!1,c=-1;function l(){f&&u&&(f=!1,u.length?h=u.concat(h):c=-1,h.length&&d())}function d(){if(!f){var t=s(l);f=!0;for(var e=h.length;e;){for(u=h,h=[];++c1)for(var r=1;r>7&1,u=t.from(n);u[31]&=-129;var h=new i.FQ(u),f=h.mul(h),c=e.ECC_D.mul(f),l=f.sub(i.FQ.ONE).mul(c.sub(e.ECC_A).inverse()).sqrt();if(l){var d=l;return l.isOdd()!==(0!=s)&&(d=i.FQ.ZERO.sub(l)),new e(d,h)}},e.ECC_A=new i.FQ(n.default.ECC_A),e.ECC_D=new i.FQ(n.default.ECC_D),e.ZERO=new e(i.FQ.ZERO,i.FQ.ONE),e}(),u=function(){function t(t,e,r){this.x=new i.FQ(t),this.y=new i.FQ(e),this.z=new i.FQ(r)}return t.prototype.toOriPoint=function(){var t=this.z.inverse();return new s(this.x.mul(t),this.y.mul(t))},t.prototype.add=function(e){var r=this.x,n=this.y,o=this.z,a=e.x,u=e.y,h=e.z,f=r.mul(a),c=n.mul(u),l=s.ECC_D.mul(f).mul(c);if(o.equal(i.FQ.ONE)&&h.equal(i.FQ.ONE))return new t(i.FQ.ONE.sub(l).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),i.FQ.ONE.add(l).mul(c.sub(s.ECC_A.mul(f))),i.FQ.ONE.sub(l.squared()));if(h.equal(i.FQ.ONE)){var d=(m=o.squared()).sub(l),p=m.add(l);return new t(o.mul(d).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),o.mul(p).mul(c.sub(s.ECC_A.mul(f))),d.mul(p))}var m,g=o.mul(h);return d=(m=g.squared()).sub(l),p=m.add(l),new t(g.mul(d).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),g.mul(p).mul(c.sub(s.ECC_A.mul(f))),d.mul(p))},t.prototype.double=function(){var e=this.x.add(this.y).squared(),r=this.x.squared(),n=this.y.squared(),o=s.ECC_A.mul(r),a=o.add(n);if(this.z.equal(i.FQ.ONE))return new t(e.sub(r).sub(n).mul(a.sub(2)),a.mul(o.sub(n)),a.squared().sub(a.mul(2)));var u=this.z.squared(),h=a.sub(u.mul(2));return new t(e.sub(r).sub(n).mul(h),a.mul(o.sub(n)),a.mul(h))},t.prototype.mult=function(e){for(var r=e.toBN(),i=this,n=t.ZERO;!r.isZero()&&(r.testn(0)&&(n=n.add(i)),!(r=r.shrn(1)).isZero());)i=i.double();return n},t.prototype.isValid=function(){var t=this.x.mul(this.x),e=this.y.mul(this.y),r=this.z.mul(this.z),i=s.ECC_A.mul(t),n=r.mul(r),o=s.ECC_D.mul(t).mul(e),a=r.mul(i.add(e)),u=n.add(o);return!!a.equal(u)},t.prototype.isEqualTo=function(t){return!(!this.x.mul(t.z).equal(this.z.mul(t.x))||!this.y.mul(t.z).equal(this.z.mul(t.y)))},t.prototype.isZero=function(){return this.isEqualTo(s.ZERO.toPoint())},t.prototype.toBuffer=function(){return this.toOriPoint().toBuffer()},t.prototype.toHex=function(){return this.toBuffer().reverse().toString("hex")},t.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},t.bufferTo=function(t){var e=s.bufferTo(t);return e?e.toPoint():void 0},t.ZERO=new t(new i.FQ(0),new i.FQ(1),new i.FQ(1)),t}();e.Point=u,e.newPoint=function(t){return t instanceof u?t:u.bufferTo(t)}}).call(this,r(0).Buffer)},function(t,e){function r(t,e){if(!t)throw new Error(e||"Assertion failed")}t.exports=r,r.equal=function(t,e,r){if(t!=e)throw new Error(r||"Assertion failed: "+t+" != "+e)}},function(t,e,r){"use strict";var i=e,n=r(5),o=r(13),a=r(103);i.assert=o,i.toArray=a.toArray,i.zero2=a.zero2,i.toHex=a.toHex,i.encode=a.encode,i.getNAF=function(t,e){for(var r=[],i=1<=0;){var o;if(n.isOdd()){var a=n.andln(i-1);o=a>(i>>1)-1?(i>>1)-a:a,n.isubn(o)}else o=0;r.push(o);for(var s=0!==n.cmpn(0)&&0===n.andln(i-1)?e+1:1,u=1;u0||e.cmpn(-n)>0;){var o,a,s,u=t.andln(3)+i&3,h=e.andln(3)+n&3;if(3===u&&(u=-1),3===h&&(h=-1),0===(1&u))o=0;else o=3!==(s=t.andln(7)+i&7)&&5!==s||2!==h?u:-u;if(r[0].push(o),0===(1&h))a=0;else a=3!==(s=e.andln(7)+n&7)&&5!==s||2!==u?h:-h;r[1].push(a),2*i===o+1&&(i=1-i),2*n===a+1&&(n=1-n),t.iushrn(1),e.iushrn(1)}return r},i.cachedProperty=function(t,e,r){var i="_"+e;t.prototype[e]=function(){return void 0!==this[i]?this[i]:this[i]=r.call(this)}},i.parseBytes=function(t){return"string"===typeof t?i.toArray(t,"hex"):t},i.intFromLE=function(t){return new n(t,"hex","le")}},function(t,e,r){"use strict";var i=r(13),n=r(1);function o(t,e){return 55296===(64512&t.charCodeAt(e))&&(!(e<0||e+1>=t.length)&&56320===(64512&t.charCodeAt(e+1)))}function a(t){return(t>>>24|t>>>8&65280|t<<8&16711680|(255&t)<<24)>>>0}function s(t){return 1===t.length?"0"+t:t}function u(t){return 7===t.length?"0"+t:6===t.length?"00"+t:5===t.length?"000"+t:4===t.length?"0000"+t:3===t.length?"00000"+t:2===t.length?"000000"+t:1===t.length?"0000000"+t:t}e.inherits=n,e.toArray=function(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if("string"===typeof t)if(e){if("hex"===e)for((t=t.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(t="0"+t),n=0;n>6|192,r[i++]=63&a|128):o(t,n)?(a=65536+((1023&a)<<10)+(1023&t.charCodeAt(++n)),r[i++]=a>>18|240,r[i++]=a>>12&63|128,r[i++]=a>>6&63|128,r[i++]=63&a|128):(r[i++]=a>>12|224,r[i++]=a>>6&63|128,r[i++]=63&a|128)}else for(n=0;n>>0}return a},e.split32=function(t,e){for(var r=new Array(4*t.length),i=0,n=0;i>>24,r[n+1]=o>>>16&255,r[n+2]=o>>>8&255,r[n+3]=255&o):(r[n+3]=o>>>24,r[n+2]=o>>>16&255,r[n+1]=o>>>8&255,r[n]=255&o)}return r},e.rotr32=function(t,e){return t>>>e|t<<32-e},e.rotl32=function(t,e){return t<>>32-e},e.sum32=function(t,e){return t+e>>>0},e.sum32_3=function(t,e,r){return t+e+r>>>0},e.sum32_4=function(t,e,r,i){return t+e+r+i>>>0},e.sum32_5=function(t,e,r,i,n){return t+e+r+i+n>>>0},e.sum64=function(t,e,r,i){var n=t[e],o=i+t[e+1]>>>0,a=(o>>0,t[e+1]=o},e.sum64_hi=function(t,e,r,i){return(e+i>>>0>>0},e.sum64_lo=function(t,e,r,i){return e+i>>>0},e.sum64_4_hi=function(t,e,r,i,n,o,a,s){var u=0,h=e;return u+=(h=h+i>>>0)>>0)>>0)>>0},e.sum64_4_lo=function(t,e,r,i,n,o,a,s){return e+i+o+s>>>0},e.sum64_5_hi=function(t,e,r,i,n,o,a,s,u,h){var f=0,c=e;return f+=(c=c+i>>>0)>>0)>>0)>>0)>>0},e.sum64_5_lo=function(t,e,r,i,n,o,a,s,u,h){return e+i+o+s+h>>>0},e.rotr64_hi=function(t,e,r){return(e<<32-r|t>>>r)>>>0},e.rotr64_lo=function(t,e,r){return(t<<32-r|e>>>r)>>>0},e.shr64_hi=function(t,e,r){return t>>>r},e.shr64_lo=function(t,e,r){return(t<<32-r|e>>>r)>>>0}},function(t,e,r){var i=r(2).Buffer,n=r(22).Transform,o=r(23).StringDecoder;function a(t){n.call(this),this.hashMode="string"===typeof t,this.hashMode?this[t]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(1)(a,n),a.prototype.update=function(t,e,r){"string"===typeof t&&(t=i.from(t,e));var n=this._update(t);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(t,e,r){var i;try{this.hashMode?this._update(t):this.push(this._update(t))}catch(n){i=n}finally{r(i)}},a.prototype._flush=function(t){var e;try{this.push(this.__final())}catch(r){e=r}t(e)},a.prototype._finalOrDigest=function(t){var e=this.__final()||i.alloc(0);return t&&(e=this._toString(e,t,!0)),e},a.prototype._toString=function(t,e,r){if(this._decoder||(this._decoder=new o(e),this._encoding=e),this._encoding!==e)throw new Error("can't switch encodings");var i=this._decoder.write(t);return r&&(i+=this._decoder.end()),i},t.exports=a},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(267);e.blake2b=function(e,r){var n=t.alloc(16,0);n.fill(e,0,e.length);var o=i(32,null,null,n).update(r).digest("binary");return t.from(o)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(117),n=r(270),o=r(3),a=r(4);e.accountBase=new i.Group("$SROKEYSGEN",1,256,4),e.crBase=new i.Group("SZK$ASSET$CR",1,256,4),e.rootBase=new i.Group("SZK$ROOTCM",10,128,4),e.genTknBase=function(e){e=o.toBuffer(e),a(32==e.length);var r=t.alloc(64,0);r.set(e,0);var i=n.findPoint("SZK$TKN",r);if(!i)throw new Error("find point error");return i},e.genTktBase=function(e,r){e=o.toBuffer(e),r=o.toBuffer(r),a(32==e.length),a(32==r.length);var i=t.concat([e,r]),s=n.findPoint("SZK$TKT",i);if(!s)throw new Error("find point error");return s}}).call(this,r(0).Buffer)},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(151).Buffer}catch(k){}function s(t,e,r){for(var n=0,o=Math.min(t.length,r),a=0,s=e;s=49&&h<=54?h-49+10:h>=17&&h<=22?h-17+10:h,a|=u}return i(!(240&a),"Invalid character in "+t),n}function u(t,e,r,n){for(var o=0,a=0,s=Math.min(t.length,r),u=e;u=49?h-49+10:h>=17?h-17+10:h,i(h>=0&&a"}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this._strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this._strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for?o.prototype[Symbol.for("nodejs.util.inspect.custom")]=f:o.prototype.inspect=f;var c=["","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],d=[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];o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?c[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var h=l[t],f=d[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modrn(f).toString(t);r=(p=p.idivn(f)).isZero()?m+r:c[h-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(t,e){return this.toArrayLike(a,t,e)}),o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)};function p(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r._strip()}o.prototype.toArrayLike=function(t,e,r){this._strip();var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0");var a=function(t,e){return t.allocUnsafe?t.allocUnsafe(e):new t(e)}(t,o);return this["_toArrayLike"+("le"===e?"LE":"BE")](a,n),a},o.prototype._toArrayLikeLE=function(t,e){for(var r=0,i=0,n=0,o=0;n>8&255),r>16&255),6===o?(r>24&255),i=0,o=0):(i=a>>>24,o+=2)}if(r=0&&(t[r--]=a>>8&255),r>=0&&(t[r--]=a>>16&255),6===o?(r>=0&&(t[r--]=a>>24&255),i=0,o=0):(i=a>>>24,o+=2)}if(r>=0)for(t[r--]=i;r>=0;)t[r--]=0},Math.clz32?o.prototype._countBits=function(t){return 32-Math.clz32(t)}:o.prototype._countBits=function(t){var e=t,r=0;return e>=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this._strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function g(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r._strip()}function b(t,e,r){return g(t,e,r)}function v(t,e){this.x=t,this.y=e}Math.imul||(m=p),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?m(this,t,e):r<63?p(this,t,e):r<1024?g(this,t,e):b(this,t,e)},v.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},v.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[n]=67108863&a}return 0!==r&&(this.words[n]=r,this.length++),e?this.ineg():this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n&1}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this._strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s._strip(),i._strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modrn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modrn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modrn=function(t){var e=t<0;e&&(t=-t),i(t<=67108863);for(var r=(1<<26)%t,n=0,o=this.length-1;o>=0;o--)n=(r*n+(0|this.words[o]))%t;return e?-n:n},o.prototype.modn=function(t){return this.modrn(t)},o.prototype.idivn=function(t){var e=t<0;e&&(t=-t),i(t<=67108863);for(var r=0,n=this.length-1;n>=0;n--){var o=(0|this.words[n])+67108864*r;this.words[n]=o/t|0,r=o%t}return this._strip(),e?this.ineg():this},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new S(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var y={k256:null,p224:null,p192:null,p25519:null};function w(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function _(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function M(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function I(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function E(t){S.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}w.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},w.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(t,e){t.iushrn(this.n,0,e)},w.prototype.imulK=function(t){return t.imul(this.k)},n(_,w),_.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},_.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(y[t])return y[t];var e;if("k256"===t)e=new _;else if("p224"===t)e=new M;else if("p192"===t)e=new A;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new I}return y[t]=e,e},S.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},S.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},S.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):(h(t,t.umod(this.m)._forceRed(this)),t)},S.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},S.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},S.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},S.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},S.prototype.isqr=function(t){return this.imul(t,t.clone())},S.prototype.sqr=function(t){return this.mul(t,t)},S.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},S.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},S.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new E(t)},n(E,S),E.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},E.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},E.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e,r){"use strict";var i=r(38),n=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};t.exports=c;var o=r(32);o.inherits=r(1);var a=r(83),s=r(51);o.inherits(c,a);for(var u=n(s.prototype),h=0;ho)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(t);if(t>0)if(t>n)for(var u=0;u>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function s(t){var e=this.lastTotal-this.lastNeed,r=function(t,e,r){if(128!==(192&e[0]))return t.lastNeed=0,"\ufffd";if(t.lastNeed>1&&e.length>1){if(128!==(192&e[1]))return t.lastNeed=1,"\ufffd";if(t.lastNeed>2&&e.length>2&&128!==(192&e[2]))return t.lastNeed=2,"\ufffd"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function u(t,e){if((t.length-e)%2===0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function h(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function f(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function c(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function l(t){return t.toString(this.encoding)}function d(t){return t&&t.length?this.write(t):""}e.StringDecoder=o,o.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return n>0&&(t.lastNeed=n-1),n;if(--i=0)return n>0&&(t.lastNeed=n-2),n;if(--i=0)return n>0&&(2===n?n=0:t.lastNeed=n-3),n;return 0}(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)},o.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length}},function(t,e,r){var i=r(2).Buffer;function n(t,e){this._block=i.alloc(t),this._finalSize=e,this._blockSize=t,this._len=0}n.prototype.update=function(t,e){"string"===typeof t&&(e=e||"utf8",t=i.from(t,e));for(var r=this._block,n=this._blockSize,o=t.length,a=this._len,s=0;s=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 i=(4294967295&r)>>>0,n=(r-i)/4294967296;this._block.writeUInt32BE(n,this._blockSize-8),this._block.writeUInt32BE(i,this._blockSize-4)}this._update(this._block);var o=this._hash();return t?o.toString(t):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(62),o=r(18),a=r(4),s=r(3),u=r(3);function h(t){t[t.length-1]|=64}function f(e){var r=t.from(e);return r[e.length-1]&=-65,r}function c(t){return 0!=(64&t[t.length-1])}e.SetFlag=h,e.ClearFlag=f,e.IsFlagSet=c;var l=function(){function e(t,e){this.ZPK=i.newPoint(t),this.VPK=i.newPoint(e)}return e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.ZPK.toBuffer(),0),e.fill(this.VPK.toBuffer(),32),h(e),e},e.prototype.toHex=function(){return"0x"+this.toBuffer().toString("hex")},e.prototype.toString=function(){return u.default.bufferToBs58(this.toBuffer())},e}();function d(t){if(t instanceof l)return t;var e=f(s.toBuffer(t));a(64==e.length);var r=i.Point.bufferTo(e.slice(0,32));if(r){var n=i.Point.bufferTo(e.slice(32));if(n)return new l(r,n)}}e.PK=l,e.newPK=d,e.tk2PK=function(t){t=n.newTK(t);var e=o.accountBase.mult(t.vsk);return new l(t.ZPK,e)},e.isPKValid=function(t){var e=s.toBuffer(t);return!!c(e)&&!!d(e)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i={};function n(t,e,r){r||(r=Error);var n=function(t){var r,i;function n(r,i,n){return t.call(this,function(t,r,i){return"string"===typeof e?e:e(t,r,i)}(r,i,n))||this}return i=t,(r=n).prototype=Object.create(i.prototype),r.prototype.constructor=r,r.__proto__=i,n}(r);n.prototype.name=r.name,n.prototype.code=t,i[t]=n}function o(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map((function(t){return String(t)})),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:2===r?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}return"of ".concat(e," ").concat(String(t))}n("ERR_INVALID_OPT_VALUE",(function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'}),TypeError),n("ERR_INVALID_ARG_TYPE",(function(t,e,r){var i,n,a,s;if("string"===typeof e&&(n="not ",e.substr(!a||a<0?0:+a,n.length)===n)?(i="must not be",e=e.replace(/^not /,"")):i="must be",function(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}(t," argument"))s="The ".concat(t," ").concat(i," ").concat(o(e,"type"));else{var u=function(t,e,r){return"number"!==typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(u," ").concat(i," ").concat(o(e,"type"))}return s+=". Received type ".concat(typeof r)}),TypeError),n("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),n("ERR_METHOD_NOT_IMPLEMENTED",(function(t){return"The "+t+" method is not implemented"})),n("ERR_STREAM_PREMATURE_CLOSE","Premature close"),n("ERR_STREAM_DESTROYED",(function(t){return"Cannot call "+t+" after a stream was destroyed"})),n("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),n("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),n("ERR_STREAM_WRITE_AFTER_END","write after end"),n("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),n("ERR_UNKNOWN_ENCODING",(function(t){return"Unknown encoding: "+t}),TypeError),n("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),t.exports.codes=i},function(t,e,r){"use strict";(function(e){var i=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};t.exports=h;var n=r(130),o=r(134);r(9)(h,n);for(var a=i(o.prototype),s=0;s=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 i=(4294967295&r)>>>0,n=(r-i)/4294967296;this._block.writeUInt32BE(n,this._blockSize-8),this._block.writeUInt32BE(i,this._blockSize-4)}this._update(this._block);var o=this._hash();return t?o.toString(t):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,r){"use strict";var i=r(1),n=r(49),o=r(52),a=r(53),s=r(16);function u(t){s.call(this,"digest"),this._hash=t}i(u,s),u.prototype._update=function(t){this._hash.update(t)},u.prototype._final=function(){return this._hash.digest()},t.exports=function(t){return"md5"===(t=t.toLowerCase())?new n:"rmd160"===t||"ripemd160"===t?new o:new u(a(t))}},function(t,e,r){"use strict";var i,n="object"===typeof Reflect?Reflect:null,o=n&&"function"===typeof n.apply?n.apply:function(t,e,r){return Function.prototype.apply.call(t,e,r)};i=n&&"function"===typeof n.ownKeys?n.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var a=Number.isNaN||function(t){return t!==t};function s(){s.init.call(this)}t.exports=s,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var u=10;function h(t){return void 0===t._maxListeners?s.defaultMaxListeners:t._maxListeners}function f(t,e,r,i){var n,o,a,s;if("function"!==typeof r)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof r);if(void 0===(o=t._events)?(o=t._events=Object.create(null),t._eventsCount=0):(void 0!==o.newListener&&(t.emit("newListener",e,r.listener?r.listener:r),o=t._events),a=o[e]),void 0===a)a=o[e]=r,++t._eventsCount;else if("function"===typeof a?a=o[e]=i?[r,a]:[a,r]:i?a.unshift(r):a.push(r),(n=h(t))>0&&a.length>n&&!a.warned){a.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=t,u.type=e,u.count=a.length,s=u,console&&console.warn&&console.warn(s)}return t}function c(){for(var t=[],e=0;e0&&(a=e[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var u=n[t];if(void 0===u)return!1;if("function"===typeof u)o(u,this,e);else{var h=u.length,f=m(u,h);for(r=0;r=0;o--)if(r[o]===e||r[o].listener===e){a=r[o].listener,n=o;break}if(n<0)return this;0===n?r.shift():function(t,e){for(;e+1=0;i--)this.removeListener(t,e[i]);return this},s.prototype.listeners=function(t){return d(this,t,!0)},s.prototype.rawListeners=function(t){return d(this,t,!1)},s.listenerCount=function(t,e){return"function"===typeof t.listenerCount?t.listenerCount(e):p.call(t,e)},s.prototype.listenerCount=p,s.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]}},function(t,e,r){(function(t){function r(t){return Object.prototype.toString.call(t)}e.isArray=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===r(t)},e.isBoolean=function(t){return"boolean"===typeof t},e.isNull=function(t){return null===t},e.isNullOrUndefined=function(t){return null==t},e.isNumber=function(t){return"number"===typeof t},e.isString=function(t){return"string"===typeof t},e.isSymbol=function(t){return"symbol"===typeof t},e.isUndefined=function(t){return void 0===t},e.isRegExp=function(t){return"[object RegExp]"===r(t)},e.isObject=function(t){return"object"===typeof t&&null!==t},e.isDate=function(t){return"[object Date]"===r(t)},e.isError=function(t){return"[object Error]"===r(t)||t instanceof Error},e.isFunction=function(t){return"function"===typeof t},e.isPrimitive=function(t){return null===t||"boolean"===typeof t||"number"===typeof t||"string"===typeof t||"symbol"===typeof t||"undefined"===typeof t},e.isBuffer=t.isBuffer}).call(this,r(0).Buffer)},function(t,e,r){(function(e){t.exports=function(t,r){for(var i=Math.min(t.length,r.length),n=new e(i),o=0;o=this._delta8){var r=(t=this.pending).length%this._delta8;this.pending=t.slice(t.length-r,t.length),0===this.pending.length&&(this.pending=null),t=i.join32(t,0,t.length-r,this.endian);for(var n=0;n>>24&255,i[n++]=t>>>16&255,i[n++]=t>>>8&255,i[n++]=255&t}else for(i[n++]=255&t,i[n++]=t>>>8&255,i[n++]=t>>>16&255,i[n++]=t>>>24&255,i[n++]=0,i[n++]=0,i[n++]=0,i[n++]=0,o=8;o>>24]^f[p>>>16&255]^c[m>>>8&255]^l[255&g]^e[b++],a=h[p>>>24]^f[m>>>16&255]^c[g>>>8&255]^l[255&d]^e[b++],s=h[m>>>24]^f[g>>>16&255]^c[d>>>8&255]^l[255&p]^e[b++],u=h[g>>>24]^f[d>>>16&255]^c[p>>>8&255]^l[255&m]^e[b++],d=o,p=a,m=s,g=u;return o=(i[d>>>24]<<24|i[p>>>16&255]<<16|i[m>>>8&255]<<8|i[255&g])^e[b++],a=(i[p>>>24]<<24|i[m>>>16&255]<<16|i[g>>>8&255]<<8|i[255&d])^e[b++],s=(i[m>>>24]<<24|i[g>>>16&255]<<16|i[d>>>8&255]<<8|i[255&p])^e[b++],u=(i[g>>>24]<<24|i[d>>>16&255]<<16|i[p>>>8&255]<<8|i[255&m])^e[b++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var t=new Array(256),e=0;e<256;e++)t[e]=e<128?e<<1:e<<1^283;for(var r=[],i=[],n=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var h=s^s<<1^s<<2^s<<3^s<<4;h=h>>>8^255&h^99,r[a]=h,i[h]=a;var f=t[a],c=t[f],l=t[c],d=257*t[h]^16843008*h;n[0][a]=d<<24|d>>>8,n[1][a]=d<<16|d>>>16,n[2][a]=d<<8|d>>>24,n[3][a]=d,d=16843009*l^65537*c^257*f^16843008*a,o[0][h]=d<<24|d>>>8,o[1][h]=d<<16|d>>>16,o[2][h]=d<<8|d>>>24,o[3][h]=d,0===a?a=s=1:(a=f^t[t[t[l^f]]],s^=t[t[s]])}return{SBOX:r,INV_SBOX:i,SUB_MIX:n,INV_SUB_MIX:o}}();function h(t){this._key=n(t),this._reset()}h.blockSize=16,h.keySize=32,h.prototype.blockSize=h.blockSize,h.prototype.keySize=h.keySize,h.prototype._reset=function(){for(var t=this._key,e=t.length,r=e+6,i=4*(r+1),n=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/e|0]<<24):e>6&&o%e===4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),n[o]=n[o-e]^a}for(var h=[],f=0;f>>24]]^u.INV_SUB_MIX[1][u.SBOX[l>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[l>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&l]]}this._nRounds=r,this._keySchedule=n,this._invKeySchedule=h},h.prototype.encryptBlockRaw=function(t){return a(t=n(t),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},h.prototype.encryptBlock=function(t){var e=this.encryptBlockRaw(t),r=i.allocUnsafe(16);return r.writeUInt32BE(e[0],0),r.writeUInt32BE(e[1],4),r.writeUInt32BE(e[2],8),r.writeUInt32BE(e[3],12),r},h.prototype.decryptBlock=function(t){var e=(t=n(t))[1];t[1]=t[3],t[3]=e;var r=a(t,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=i.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},h.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},t.exports.AES=h},function(t,e,r){var i=r(2).Buffer,n=r(49);t.exports=function(t,e,r,o){if(i.isBuffer(t)||(t=i.from(t,"binary")),e&&(i.isBuffer(e)||(e=i.from(e,"binary")),8!==e.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=i.alloc(a),u=i.alloc(o||0),h=i.alloc(0);a>0||o>0;){var f=new n;f.update(h),f.update(t),e&&f.update(e),h=f.digest();var c=0;if(a>0){var l=s.length-a;c=Math.min(a,h.length),h.copy(s,l,0,c),a-=c}if(c0){var d=u.length-o,p=Math.min(o,h.length-c);h.copy(u,d,c,c+p),o-=p}}return h.fill(0),{key:s,iv:u}}},function(t,e,r){"use strict";var i=r(5),n=r(14),o=n.getNAF,a=n.getJSF,s=n.assert;function u(t,e){this.type=t,this.p=new i(e.p,16),this.red=e.prime?i.red(e.prime):i.mont(this.p),this.zero=new i(0).toRed(this.red),this.one=new i(1).toRed(this.red),this.two=new i(2).toRed(this.red),this.n=e.n&&new i(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.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||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function h(t,e){this.curve=t,this.type=e,this.precomputed=null}t.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(t,e){s(t.precomputed);var r=t._getDoubles(),i=o(e,1),n=(1<=u;e--)h=(h<<1)+i[e];a.push(h)}for(var f=this.jpoint(null,null,null),c=this.jpoint(null,null,null),l=n;l>0;l--){for(u=0;u=0;h--){for(e=0;h>=0&&0===a[h];h--)e++;if(h>=0&&e++,u=u.dblp(e),h<0)break;var f=a[h];s(0!==f),u="affine"===t.type?f>0?u.mixedAdd(n[f-1>>1]):u.mixedAdd(n[-f-1>>1].neg()):f>0?u.add(n[f-1>>1]):u.add(n[-f-1>>1].neg())}return"affine"===t.type?u.toP():u},u.prototype._wnafMulAdd=function(t,e,r,i,n){for(var s=this._wnafT1,u=this._wnafT2,h=this._wnafT3,f=0,c=0;c=1;c-=2){var d=c-1,p=c;if(1===s[d]&&1===s[p]){var m=[e[d],null,null,e[p]];0===e[d].y.cmp(e[p].y)?(m[1]=e[d].add(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg())):0===e[d].y.cmp(e[p].y.redNeg())?(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].add(e[p].neg())):(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],b=a(r[d],r[p]);f=Math.max(b[0].length,f),h[d]=new Array(f),h[p]=new Array(f);for(var v=0;v=0;c--){for(var A=0;c>=0;){var I=!0;for(v=0;v=0&&A++,_=_.dblp(A),c<0)break;for(v=0;v0?S=u[v][E-1>>1]:E<0&&(S=u[v][-E-1>>1].neg()),_="affine"===S.type?_.mixedAdd(S):_.add(S))}}for(c=0;c=Math.ceil((t.bitLength()+1)/e.step)},h.prototype._getDoubles=function(t,e){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],i=this,n=0;no)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(t);if(t>0)if(t>n)for(var u=0;u>>32-e}function h(t,e,r,i,n,o,a){return u(t+(e&r|~e&i)+n+o|0,a)+e|0}function f(t,e,r,i,n,o,a){return u(t+(e&i|r&~i)+n+o|0,a)+e|0}function c(t,e,r,i,n,o,a){return u(t+(e^r^i)+n+o|0,a)+e|0}function l(t,e,r,i,n,o,a){return u(t+(r^(e|~i))+n+o|0,a)+e|0}i(s,n),s.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);var r=this._a,i=this._b,n=this._c,o=this._d;r=h(r,i,n,o,t[0],3614090360,7),o=h(o,r,i,n,t[1],3905402710,12),n=h(n,o,r,i,t[2],606105819,17),i=h(i,n,o,r,t[3],3250441966,22),r=h(r,i,n,o,t[4],4118548399,7),o=h(o,r,i,n,t[5],1200080426,12),n=h(n,o,r,i,t[6],2821735955,17),i=h(i,n,o,r,t[7],4249261313,22),r=h(r,i,n,o,t[8],1770035416,7),o=h(o,r,i,n,t[9],2336552879,12),n=h(n,o,r,i,t[10],4294925233,17),i=h(i,n,o,r,t[11],2304563134,22),r=h(r,i,n,o,t[12],1804603682,7),o=h(o,r,i,n,t[13],4254626195,12),n=h(n,o,r,i,t[14],2792965006,17),r=f(r,i=h(i,n,o,r,t[15],1236535329,22),n,o,t[1],4129170786,5),o=f(o,r,i,n,t[6],3225465664,9),n=f(n,o,r,i,t[11],643717713,14),i=f(i,n,o,r,t[0],3921069994,20),r=f(r,i,n,o,t[5],3593408605,5),o=f(o,r,i,n,t[10],38016083,9),n=f(n,o,r,i,t[15],3634488961,14),i=f(i,n,o,r,t[4],3889429448,20),r=f(r,i,n,o,t[9],568446438,5),o=f(o,r,i,n,t[14],3275163606,9),n=f(n,o,r,i,t[3],4107603335,14),i=f(i,n,o,r,t[8],1163531501,20),r=f(r,i,n,o,t[13],2850285829,5),o=f(o,r,i,n,t[2],4243563512,9),n=f(n,o,r,i,t[7],1735328473,14),r=c(r,i=f(i,n,o,r,t[12],2368359562,20),n,o,t[5],4294588738,4),o=c(o,r,i,n,t[8],2272392833,11),n=c(n,o,r,i,t[11],1839030562,16),i=c(i,n,o,r,t[14],4259657740,23),r=c(r,i,n,o,t[1],2763975236,4),o=c(o,r,i,n,t[4],1272893353,11),n=c(n,o,r,i,t[7],4139469664,16),i=c(i,n,o,r,t[10],3200236656,23),r=c(r,i,n,o,t[13],681279174,4),o=c(o,r,i,n,t[0],3936430074,11),n=c(n,o,r,i,t[3],3572445317,16),i=c(i,n,o,r,t[6],76029189,23),r=c(r,i,n,o,t[9],3654602809,4),o=c(o,r,i,n,t[12],3873151461,11),n=c(n,o,r,i,t[15],530742520,16),r=l(r,i=c(i,n,o,r,t[2],3299628645,23),n,o,t[0],4096336452,6),o=l(o,r,i,n,t[7],1126891415,10),n=l(n,o,r,i,t[14],2878612391,15),i=l(i,n,o,r,t[5],4237533241,21),r=l(r,i,n,o,t[12],1700485571,6),o=l(o,r,i,n,t[3],2399980690,10),n=l(n,o,r,i,t[10],4293915773,15),i=l(i,n,o,r,t[1],2240044497,21),r=l(r,i,n,o,t[8],1873313359,6),o=l(o,r,i,n,t[15],4264355552,10),n=l(n,o,r,i,t[6],2734768916,15),i=l(i,n,o,r,t[13],1309151649,21),r=l(r,i,n,o,t[4],4149444226,6),o=l(o,r,i,n,t[11],3174756917,10),n=l(n,o,r,i,t[2],718787259,15),i=l(i,n,o,r,t[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+i|0,this._c=this._c+n|0,this._d=this._d+o|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=o.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t},t.exports=s},function(t,e,r){(e=t.exports=r(83)).Stream=e,e.Readable=e,e.Writable=r(51),e.Duplex=r(20),e.Transform=r(86),e.PassThrough=r(194)},function(t,e,r){"use strict";(function(e,i,n){var o=r(38);function a(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var i=t.entry;t.entry=null;for(;i;){var n=i.callback;e.pendingcb--,n(r),i=i.next}e.corkedRequestsFree?e.corkedRequestsFree.next=t:e.corkedRequestsFree=t}(e,t)}}t.exports=v;var s,u=!e.browser&&["v0.10","v0.9."].indexOf(e.version.slice(0,5))>-1?i:o.nextTick;v.WritableState=b;var h=r(32);h.inherits=r(1);var f={deprecate:r(192)},c=r(84),l=r(2).Buffer,d=n.Uint8Array||function(){};var p,m=r(85);function g(){}function b(t,e){s=s||r(20),t=t||{};var i=e instanceof s;this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.writableObjectMode);var n=t.highWaterMark,h=t.writableHighWaterMark,f=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:i&&(h||0===h)?h:f,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===t.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,e){var r=t._writableState,i=r.sync,n=r.writecb;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(r),e)!function(t,e,r,i,n){--e.pendingcb,r?(o.nextTick(n,i),o.nextTick(I,t,e),t._writableState.errorEmitted=!0,t.emit("error",i)):(n(i),t._writableState.errorEmitted=!0,t.emit("error",i),I(t,e))}(t,r,i,e,n);else{var a=M(r);a||r.corked||r.bufferProcessing||!r.bufferedRequest||_(t,r),i?u(w,t,r,a,n):w(t,r,a,n)}}(e,t)},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 a(this)}function v(t){if(s=s||r(20),!p.call(v,this)&&!(this instanceof s))return new v(t);this._writableState=new b(t,this),this.writable=!0,t&&("function"===typeof t.write&&(this._write=t.write),"function"===typeof t.writev&&(this._writev=t.writev),"function"===typeof t.destroy&&(this._destroy=t.destroy),"function"===typeof t.final&&(this._final=t.final)),c.call(this)}function y(t,e,r,i,n,o,a){e.writelen=i,e.writecb=a,e.writing=!0,e.sync=!0,r?t._writev(n,e.onwrite):t._write(n,o,e.onwrite),e.sync=!1}function w(t,e,r,i){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,i(),I(t,e)}function _(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var i=e.bufferedRequestCount,n=new Array(i),o=e.corkedRequestsFree;o.entry=r;for(var s=0,u=!0;r;)n[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;n.allBuffers=u,y(t,e,!0,e.length,n,"",o.finish),e.pendingcb++,e.lastBufferedRequest=null,o.next?(e.corkedRequestsFree=o.next,o.next=null):e.corkedRequestsFree=new a(e),e.bufferedRequestCount=0}else{for(;r;){var h=r.chunk,f=r.encoding,c=r.callback;if(y(t,e,!1,e.objectMode?1:h.length,h,f,c),r=r.next,e.bufferedRequestCount--,e.writing)break}null===r&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}function M(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function A(t,e){t._final((function(r){e.pendingcb--,r&&t.emit("error",r),e.prefinished=!0,t.emit("prefinish"),I(t,e)}))}function I(t,e){var r=M(e);return r&&(!function(t,e){e.prefinished||e.finalCalled||("function"===typeof t._final?(e.pendingcb++,e.finalCalled=!0,o.nextTick(A,t,e)):(e.prefinished=!0,t.emit("prefinish")))}(t,e),0===e.pendingcb&&(e.finished=!0,t.emit("finish"))),r}h.inherits(v,c),b.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(b.prototype,"buffer",{get:f.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(p=Function.prototype[Symbol.hasInstance],Object.defineProperty(v,Symbol.hasInstance,{value:function(t){return!!p.call(this,t)||this===v&&(t&&t._writableState instanceof b)}})):p=function(t){return t instanceof this},v.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},v.prototype.write=function(t,e,r){var i,n=this._writableState,a=!1,s=!n.objectMode&&(i=t,l.isBuffer(i)||i instanceof d);return s&&!l.isBuffer(t)&&(t=function(t){return l.from(t)}(t)),"function"===typeof e&&(r=e,e=null),s?e="buffer":e||(e=n.defaultEncoding),"function"!==typeof r&&(r=g),n.ended?function(t,e){var r=new Error("write after end");t.emit("error",r),o.nextTick(e,r)}(this,r):(s||function(t,e,r,i){var n=!0,a=!1;return null===r?a=new TypeError("May not write null values to stream"):"string"===typeof r||void 0===r||e.objectMode||(a=new TypeError("Invalid non-string/buffer chunk")),a&&(t.emit("error",a),o.nextTick(i,a),n=!1),n}(this,n,t,r))&&(n.pendingcb++,a=function(t,e,r,i,n,o){if(!r){var a=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!==typeof e||(e=l.from(e,r));return e}(e,i,n);i!==a&&(r=!0,n="buffer",i=a)}var s=e.objectMode?1:i.length;e.length+=s;var u=e.length-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(v.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),v.prototype._write=function(t,e,r){r(new Error("_write() is not implemented"))},v.prototype._writev=null,v.prototype.end=function(t,e,r){var i=this._writableState;"function"===typeof t?(r=t,t=null,e=null):"function"===typeof e&&(r=e,e=null),null!==t&&void 0!==t&&this.write(t,e),i.corked&&(i.corked=1,this.uncork()),i.ending||i.finished||function(t,e,r){e.ending=!0,I(t,e),r&&(e.finished?o.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,i,r)},Object.defineProperty(v.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),v.prototype.destroy=m.destroy,v.prototype._undestroy=m.undestroy,v.prototype._destroy=function(t,e){this.end(),e(t)}}).call(this,r(8),r(190).setImmediate,r(10))},function(t,e,r){"use strict";var i=r(0).Buffer,n=r(1),o=r(82),a=new Array(16),s=[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],u=[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],h=[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],f=[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],c=[0,1518500249,1859775393,2400959708,2840853838],l=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(t,e){return t<>>32-e}function m(t,e,r,i,n,o,a,s){return p(t+(e^r^i)+o+a|0,s)+n|0}function g(t,e,r,i,n,o,a,s){return p(t+(e&r|~e&i)+o+a|0,s)+n|0}function b(t,e,r,i,n,o,a,s){return p(t+((e|~r)^i)+o+a|0,s)+n|0}function v(t,e,r,i,n,o,a,s){return p(t+(e&i|r&~i)+o+a|0,s)+n|0}function y(t,e,r,i,n,o,a,s){return p(t+(e^(r|~i))+o+a|0,s)+n|0}n(d,o),d.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);for(var r=0|this._a,i=0|this._b,n=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,_=0|this._b,M=0|this._c,A=0|this._d,I=0|this._e,S=0;S<80;S+=1){var E,k;S<16?(E=m(r,i,n,o,d,t[s[S]],c[0],h[S]),k=y(w,_,M,A,I,t[u[S]],l[0],f[S])):S<32?(E=g(r,i,n,o,d,t[s[S]],c[1],h[S]),k=v(w,_,M,A,I,t[u[S]],l[1],f[S])):S<48?(E=b(r,i,n,o,d,t[s[S]],c[2],h[S]),k=b(w,_,M,A,I,t[u[S]],l[2],f[S])):S<64?(E=v(r,i,n,o,d,t[s[S]],c[3],h[S]),k=g(w,_,M,A,I,t[u[S]],l[3],f[S])):(E=y(r,i,n,o,d,t[s[S]],c[4],h[S]),k=m(w,_,M,A,I,t[u[S]],l[4],f[S])),r=d,d=o,o=p(n,10),n=i,i=E,w=I,I=A,A=p(M,10),M=_,_=k}var x=this._b+n+A|0;this._b=this._c+o+I|0,this._c=this._d+d+w|0,this._d=this._e+r+_|0,this._e=this._a+i+M|0,this._a=x},d.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=i.alloc?i.alloc(20):new i(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t},t.exports=d},function(t,e,r){(e=t.exports=function(t){t=t.toLowerCase();var r=e[t];if(!r)throw new Error(t+" is not supported (we accept pull requests)");return new r}).sha=r(199),e.sha1=r(200),e.sha224=r(201),e.sha256=r(87),e.sha384=r(202),e.sha512=r(88)},function(t,e,r){"use strict";e.utils=r(208),e.Cipher=r(209),e.DES=r(210),e.CBC=r(211),e.EDE=r(212)},function(t,e,r){var i=r(213),n=r(221),o=r(98);e.createCipher=e.Cipher=i.createCipher,e.createCipheriv=e.Cipheriv=i.createCipheriv,e.createDecipher=e.Decipher=n.createDecipher,e.createDecipheriv=e.Decipheriv=n.createDecipheriv,e.listCiphers=e.getCiphers=function(){return Object.keys(o)}},function(t,e,r){var i={ECB:r(214),CBC:r(215),CFB:r(216),CFB8:r(217),CFB1:r(218),OFB:r(219),CTR:r(96),GCM:r(96)},n=r(98);for(var o in n)n[o].module=i[n[o].mode];t.exports=n},function(t,e,r){var i;function n(t){this.rand=t}if(t.exports=function(t){return i||(i=new n(null)),i.generate(t)},t.exports.Rand=n,n.prototype.generate=function(t){return this._rand(t)},n.prototype._rand=function(t){if(this.rand.getBytes)return this.rand.getBytes(t);for(var e=new Uint8Array(t),r=0;r=0||!r.umod(t.prime1)||!r.umod(t.prime2);)r=new i(n(e));return r}t.exports=o,o.getr=a}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=e;i.version=r(230).version,i.utils=r(14),i.rand=r(57),i.curve=r(104),i.curves=r(60),i.ec=r(241),i.eddsa=r(245)},function(t,e,r){"use strict";var i,n=e,o=r(61),a=r(104),s=r(14).assert;function u(t){"short"===t.type?this.curve=new a.short(t):"edwards"===t.type?this.curve=new a.edwards(t):this.curve=new a.mont(t),this.g=this.curve.g,this.n=this.curve.n,this.hash=t.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function h(t,e){Object.defineProperty(n,t,{configurable:!0,enumerable:!0,get:function(){var r=new u(e);return Object.defineProperty(n,t,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=u,h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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{i=r(240)}catch(f){i=void 0}h("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",i]})},function(t,e,r){var i=e;i.utils=r(15),i.common=r(34),i.sha=r(234),i.ripemd=r(238),i.hmac=r(239),i.sha1=i.sha.sha1,i.sha256=i.sha.sha256,i.sha224=i.sha.sha224,i.sha384=i.sha.sha384,i.sha512=i.sha.sha512,i.ripemd160=i.ripemd.ripemd160},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(17),n=r(6),o=r(12),a=r(18),s=r(3),u=r(4),h=r(25),f=function(){function e(t,e){this.zsk=n.newFR(t),this.vsk=n.newFR(e)}return e.prototype.isValid=function(){return!this.zsk.isZero()&&!this.vsk.isZero()},e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.zsk.toBuffer(),0),e.fill(this.vsk.toBuffer(),32),h.SetFlag(e),e},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function c(t){if(t instanceof f)return t;var e=s.toBuffer(t);return 64>>=8,t[e+1]=r,r>>>=8,t[e+2]=r,r>>>=8,t[e+3]=r},t.ROTATE=function(t,e){return t<>>32-e},t}(),i=t.alloc(16,0);i.fill(0),e.default=function(e,n){var o=new r(n,i,0),a=t.alloc(e.length);return o.encrypt(a,e),a}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(6),o=r(18),a=r(17),s=r(120),u=r(63),h=r(44),f=r(3),c=r(4),l=r(66);e.fetchKey=function(e,r){e=l.newTK(e),r=t.from(f.toBuffer(r)),c(32==r.length),64&r[31]&&(r[31]&=-65);var n=i.newPoint(r);if(n){var o=n.mult(e.vsk);return a.blake2b("CZERO.KEYS.KDF",o.toBuffer())}},e.genPKrKey=function(t,e){t=h.newPKr(t),e=n.newFR(e);var r=t.ZPK.mult(e),i=t.VPK.mult(e),o=r.toBuffer(),s=a.blake2b("CZERO.KEYS.KDF",i.toBuffer());return o[31]|=64,{key:s,rpk:o}},e.signByPKr=function(t,e,r){if(e=f.toBuffer(e),t=l.newSK(t),r=h.newPKr(r),c(32==e.length),e&&0!=e.length&&t.isValid()&&r.isValid()){var i=r.BASE.add(o.accountBase.points.get(0));return u.sign(e,t.vsk.mul(t.zsk),i)}},e.verifyByPKr=function(t,e,r){if(t=f.toBuffer(t),e=f.toBuffer(e),r=h.newPKr(r),c(32==t.length),!t||0==t.length||!e||0==e.length||!r.isValid())return!1;var i=r.BASE.add(o.accountBase.points.get(0));return u.verify(t,e,r.VPK,i)},e.genNil=function(t,e){if(t=l.newSK(t),e=i.newPoint(e),t.isValid()&&e.isValid())return e.mult(t.vsk.mul(t.zsk))},e.signNil=function(t,e,r,n){if(t=f.toBuffer(t),e=l.newSK(e),r=h.newPKr(r),n=i.newPoint(n),c(32==t.length),t&&0!=t.length&&e.isValid()&&r.isValid()&&n.isValid()){var a=r.BASE.add(o.accountBase.points.get(0));return s.sign(t,e.vsk.mul(e.zsk),a,n)}},e.verifyNil=function(t,e,r,n,a){if(t=f.toBuffer(t),e=f.toBuffer(e),r=i.newPoint(r),n=h.newPKr(n),a=i.newPoint(a),c(32==t.length),c(96==e.length),!(t&&0!=t.length&&e&&0!=e.length&&n.isValid()&&a.isValid()))return!1;var u=n.BASE.add(o.accountBase.points.get(0));return s.verify(t,e,n.VPK,r,u,a)},e.genTrace=function(t,e){if(t=l.newTK(t),e=i.newPoint(e),t.isValid()&&e.isValid())return e.mult(t.vsk)},e.isMyPKr=function(t,e){if(t=l.newTK(t),e=h.newPKr(e),!t.isValid()||!e.isValid())return!1;var r=e.ZPK.add(t.ZPK.mult(n.FR.ONE.nega())).mult(t.vsk),i=e.VPK.add(t.ZPK.mult(t.vsk.mul(n.FR.ONE.nega())));return r.isEqualTo(i)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(17),n=r(6),o=r(12),a=r(18),s=r(3),u=r(4),h=function(){function e(t,e){this.zsk=n.newFR(t),this.vsk=n.newFR(e)}return e.prototype.isValid=function(){return!this.zsk.isZero()&&!this.vsk.isZero()},e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.zsk.toBuffer(),0),e.fill(this.vsk.toBuffer(),32),e},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function f(t){if(t instanceof h)return t;var e=s.toBuffer(t);return 64=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};i.forEach(["delete","get","head"],(function(t){s.headers[t]={}})),i.forEach(["post","put","patch"],(function(t){s.headers[t]=i.merge(o)})),t.exports=s}).call(this,r(8))},function(t,e,r){"use strict";var i=r(11),n=r(176),o=r(74),a=r(178),s=r(179),u=r(78);t.exports=function(t){return new Promise((function(e,h){var f=t.data,c=t.headers;i.isFormData(f)&&delete c["Content-Type"];var l=new XMLHttpRequest;if(t.auth){var d=t.auth.username||"",p=t.auth.password||"";c.Authorization="Basic "+btoa(d+":"+p)}if(l.open(t.method.toUpperCase(),o(t.url,t.params,t.paramsSerializer),!0),l.timeout=t.timeout,l.onreadystatechange=function(){if(l&&4===l.readyState&&(0!==l.status||l.responseURL&&0===l.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in l?a(l.getAllResponseHeaders()):null,i={data:t.responseType&&"text"!==t.responseType?l.response:l.responseText,status:l.status,statusText:l.statusText,headers:r,config:t,request:l};n(e,h,i),l=null}},l.onabort=function(){l&&(h(u("Request aborted",t,"ECONNABORTED",l)),l=null)},l.onerror=function(){h(u("Network Error",t,null,l)),l=null},l.ontimeout=function(){h(u("timeout of "+t.timeout+"ms exceeded",t,"ECONNABORTED",l)),l=null},i.isStandardBrowserEnv()){var m=r(180),g=(t.withCredentials||s(t.url))&&t.xsrfCookieName?m.read(t.xsrfCookieName):void 0;g&&(c[t.xsrfHeaderName]=g)}if("setRequestHeader"in l&&i.forEach(c,(function(t,e){"undefined"===typeof f&&"content-type"===e.toLowerCase()?delete c[e]:l.setRequestHeader(e,t)})),t.withCredentials&&(l.withCredentials=!0),t.responseType)try{l.responseType=t.responseType}catch(b){if("json"!==t.responseType)throw b}"function"===typeof t.onDownloadProgress&&l.addEventListener("progress",t.onDownloadProgress),"function"===typeof t.onUploadProgress&&l.upload&&l.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){l&&(l.abort(),h(t),l=null)})),void 0===f&&(f=null),l.send(f)}))}},function(t,e,r){"use strict";var i=r(177);t.exports=function(t,e,r,n,o){var a=new Error(t);return i(a,e,r,n,o)}},function(t,e,r){"use strict";var i=r(11);t.exports=function(t,e){e=e||{};var r={};return i.forEach(["url","method","params","data"],(function(t){"undefined"!==typeof e[t]&&(r[t]=e[t])})),i.forEach(["headers","auth","proxy"],(function(n){i.isObject(e[n])?r[n]=i.deepMerge(t[n],e[n]):"undefined"!==typeof e[n]?r[n]=e[n]:i.isObject(t[n])?r[n]=i.deepMerge(t[n]):"undefined"!==typeof t[n]&&(r[n]=t[n])})),i.forEach(["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"],(function(i){"undefined"!==typeof e[i]?r[i]=e[i]:"undefined"!==typeof t[i]&&(r[i]=t[i])})),r}},function(t,e,r){"use strict";function i(t){this.message=t}i.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},i.prototype.__CANCEL__=!0,t.exports=i},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(3),n=r(46),o=r(37),a=r(65),s=r(273),u=r(275),h=r(122),f=r(44);e.decOut=function(t,e){var r=new Array;return e.forEach((function(e){var o,s={},u=!1;s.Nils=new Array;var h=e.State.OS;if(h.Out_O)s.Asset=l(h.Out_O.Asset),s.Memo=h.Out_O.Memo,s.Nils.push(e.Root),s.Nils.push(i.toString(a.genTrace(t,h.RootCM))),o=h.Out_O.Addr;else if(h.Out_Z)null!==(c=d(i.toString(a.fetchKey(t,h.Out_Z.RPK)),h.Out_Z.EInfo,h.Out_Z.PKr,h.Out_Z.OutCM))&&(s.Asset=c.Asset,s.Memo=c.Memo,s.Nils.push(i.toString(a.genTrace(t,h.RootCM))),o=h.Out_Z.PKr,u=!0);else if(h.Out_P){var f=i.toString(n.genNil(t,h.RootCM,h.Out_P.PKr));s.Asset=l(h.Out_P.Asset),s.Memo=h.Out_P.Memo,s.Nils.push(f),o=h.Out_P.PKr}else{if(!h.Out_C)throw new Error("invalid out type");var c;null!==(c=p(i.toString(n.fetchRPKKey(h.Out_C.PKr,t,h.Out_C.RPK)),h.Out_C.EInfo,h.Out_C.AssetCM))&&(s.Asset=c.Asset,s.Memo=c.Memo,s.Nils.push(i.toString(n.genNil(t,h.RootCM,h.Out_C.PKr))),o=h.Out_C.PKr,u=!0)}if(o){var m={};m.Root=e.Root,m.State=e.State,m.Pkr=i.default.addrToString(o),m.Asset=s.Asset,m.Num=e.State.Num,m.Memo=s.Memo,m.Nils=s.Nils,m.IsZ=u,m.TxHash=e.State.TxHash,r.push(m)}})),r};var c=t.alloc(32,0);function l(e){var r={};return e instanceof o.Asset?(0!=t.compare(e.tkn_currency,c)&&(r.Tkn={Currency:i.toString(e.tkn_currency),Value:i.default.bufferToBN(e.tkn_value.toBuffer()).toString()}),0!=t.compare(e.tkt_value,c)&&(r.Tkt={Category:i.toString(e.tkt_category),Value:i.toString(e.tkt_value)})):(e.Tkn&&0!==t.compare(i.toBuffer(e.Tkn.Currency),c)&&(r.Tkn={Currency:e.Tkn.Currency,Value:i.default.toBN(e.Tkn.Value).toString(10)}),e.Tkt&&0!=t.compare(i.toBuffer(e.Tkt.Value),c)&&(r.Tkt={Category:e.Tkt.Category,Value:e.Tkt.Value})),r}function d(t,e,r,n){t=i.toBuffer(t),e=i.toBuffer(e),r=f.newPKr(r),n=i.toBuffer(n);var o=u.decEInfo(e,t,!0),a=s.genOutCm(o.asset,o.memo,o.rsk,r);return a?0!=a.toBuffer().compare(n)?null:{Asset:l(o.asset),Memo:i.toString(o.memo),Nils:new Array}:null}function p(t,e,r){t=i.toBuffer(t),e=i.toBuffer(e),r=i.toBuffer(r);var n=h.decEInfo(t,e),a=i.toString(n.ar);return 0!=o.genAssetCM(n.asset,a).toBuffer().compare(r)?null:{Asset:l(n.asset),Memo:i.toString(n.memo),Nils:new Array}}e.confirmOutZ=d,e.confirmOutC=p}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=r(2).Buffer,n=r(22).Transform;function o(t){n.call(this),this._block=i.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(1)(o,n),o.prototype._transform=function(t,e,r){var i=null;try{this.update(t,e)}catch(n){i=n}r(i)},o.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(r){e=r}t(e)},o.prototype.update=function(t,e){if(function(t,e){if(!i.isBuffer(t)&&"string"!==typeof t)throw new TypeError(e+" must be a string or a buffer")}(t,"Data"),this._finalized)throw new Error("Digest already called");i.isBuffer(t)||(t=i.from(t,e));for(var r=this._block,n=0;this._blockOffset+t.length-n>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();void 0!==t&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return e},o.prototype._digest=function(){throw new Error("_digest is not implemented")},t.exports=o},function(t,e,r){"use strict";(function(e,i){var n=r(38);t.exports=y;var o,a=r(68);y.ReadableState=v;r(31).EventEmitter;var s=function(t,e){return t.listeners(e).length},u=r(84),h=r(2).Buffer,f=e.Uint8Array||function(){};var c=r(32);c.inherits=r(1);var l=r(187),d=void 0;d=l&&l.debuglog?l.debuglog("stream"):function(){};var p,m=r(188),g=r(85);c.inherits(y,u);var b=["error","close","destroy","pause","resume"];function v(t,e){t=t||{};var i=e instanceof(o=o||r(20));this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.readableObjectMode);var n=t.highWaterMark,a=t.readableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:i&&(a||0===a)?a:s,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new m,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=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(p||(p=r(23).StringDecoder),this.decoder=new p(t.encoding),this.encoding=t.encoding)}function y(t){if(o=o||r(20),!(this instanceof y))return new y(t);this._readableState=new v(t,this),this.readable=!0,t&&("function"===typeof t.read&&(this._read=t.read),"function"===typeof t.destroy&&(this._destroy=t.destroy)),u.call(this)}function w(t,e,r,i,n){var o,a=t._readableState;null===e?(a.reading=!1,function(t,e){if(e.ended)return;if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,I(t)}(t,a)):(n||(o=function(t,e){var r;i=e,h.isBuffer(i)||i instanceof f||"string"===typeof e||void 0===e||t.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var i;return r}(a,e)),o?t.emit("error",o):a.objectMode||e&&e.length>0?("string"===typeof e||a.objectMode||Object.getPrototypeOf(e)===h.prototype||(e=function(t){return h.from(t)}(e)),i?a.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):_(t,a,e,!0):a.ended?t.emit("error",new Error("stream.push() after EOF")):(a.reading=!1,a.decoder&&!r?(e=a.decoder.write(e),a.objectMode||0!==e.length?_(t,a,e,!1):E(t,a)):_(t,a,e,!1))):i||(a.reading=!1));return function(t){return!t.ended&&(t.needReadable||t.lengthe.highWaterMark&&(e.highWaterMark=function(t){return t>=M?t=M:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function I(t){var e=t._readableState;e.needReadable=!1,e.emittedReadable||(d("emitReadable",e.flowing),e.emittedReadable=!0,e.sync?n.nextTick(S,t):S(t))}function S(t){d("emit readable"),t.emit("readable"),C(t)}function E(t,e){e.readingMore||(e.readingMore=!0,n.nextTick(k,t,e))}function k(t,e){for(var r=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):r=function(t,e,r){var i;to.length?o.length:t;if(a===o.length?n+=o:n+=o.slice(0,t),0===(t-=a)){a===o.length?(++i,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(a));break}++i}return e.length-=i,n}(t,e):function(t,e){var r=h.allocUnsafe(t),i=e.head,n=1;i.data.copy(r),t-=i.data.length;for(;i=i.next;){var o=i.data,a=t>o.length?o.length:t;if(o.copy(r,r.length-t,0,a),0===(t-=a)){a===o.length?(++n,i.next?e.head=i.next:e.head=e.tail=null):(e.head=i,i.data=o.slice(a));break}++n}return e.length-=n,r}(t,e);return i}(t,e.buffer,e.decoder),r);var r}function P(t){var e=t._readableState;if(e.length>0)throw new Error('"endReadable()" called on non-empty stream');e.endEmitted||(e.ended=!0,n.nextTick(R,e,t))}function R(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function O(t,e){for(var r=0,i=t.length;r=e.highWaterMark||e.ended))return d("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?P(this):I(this),null;if(0===(t=A(t,e))&&e.ended)return 0===e.length&&P(this),null;var i,n=e.needReadable;return d("need readable",n),(0===e.length||e.length-t0?T(t,e):null)?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&P(this)),null!==i&&this.emit("data",i),i},y.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},y.prototype.pipe=function(t,e){var r=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=t;break;case 1:o.pipes=[o.pipes,t];break;default:o.pipes.push(t)}o.pipesCount+=1,d("pipe count=%d opts=%j",o.pipesCount,e);var u=(!e||!1!==e.end)&&t!==i.stdout&&t!==i.stderr?f:y;function h(e,i){d("onunpipe"),e===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,d("cleanup"),t.removeListener("close",b),t.removeListener("finish",v),t.removeListener("drain",c),t.removeListener("error",g),t.removeListener("unpipe",h),r.removeListener("end",f),r.removeListener("end",y),r.removeListener("data",m),l=!0,!o.awaitDrain||t._writableState&&!t._writableState.needDrain||c())}function f(){d("onend"),t.end()}o.endEmitted?n.nextTick(u):r.once("end",u),t.on("unpipe",h);var c=function(t){return function(){var e=t._readableState;d("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&s(t,"data")&&(e.flowing=!0,C(t))}}(r);t.on("drain",c);var l=!1;var p=!1;function m(e){d("ondata"),p=!1,!1!==t.write(e)||p||((1===o.pipesCount&&o.pipes===t||o.pipesCount>1&&-1!==O(o.pipes,t))&&!l&&(d("false write response, pause",r._readableState.awaitDrain),r._readableState.awaitDrain++,p=!0),r.pause())}function g(e){d("onerror",e),y(),t.removeListener("error",g),0===s(t,"error")&&t.emit("error",e)}function b(){t.removeListener("finish",v),y()}function v(){d("onfinish"),t.removeListener("close",b),y()}function y(){d("unpipe"),r.unpipe(t)}return r.on("data",m),function(t,e,r){if("function"===typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?a(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",g),t.once("close",b),t.once("finish",v),t.emit("pipe",r),o.flowing||(d("pipe resume"),r.resume()),t},y.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function l(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function d(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}i(u,n),u.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},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,g=0|this._h,b=0;b<16;++b)r[b]=t.readInt32BE(4*b);for(;b<64;++b)r[b]=0|(((e=r[b-2])>>>17|e<<15)^(e>>>19|e<<13)^e>>>10)+r[b-7]+d(r[b-15])+r[b-16];for(var v=0;v<64;++v){var y=g+l(u)+h(u,p,m)+a[v]+r[v]|0,w=c(i)+f(i,n,o)|0;g=m,m=p,p=u,u=s+y|0,s=o,o=n,n=i,i=y+w|0}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},u.prototype._hash=function(){var t=o.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},t.exports=u},function(t,e,r){var i=r(1),n=r(24),o=r(2).Buffer,a=[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 u(){this.init(),this._w=s,n.call(this,128,112)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function l(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function d(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function p(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function m(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function g(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function b(t,e){return t>>>0>>0?1:0}i(u,n),u.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},u.prototype._update=function(t){for(var e=this._w,r=0|this._ah,i=0|this._bh,n=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,v=0|this._gh,y=0|this._hh,w=0|this._al,_=0|this._bl,M=0|this._cl,A=0|this._dl,I=0|this._el,S=0|this._fl,E=0|this._gl,k=0|this._hl,x=0;x<32;x+=2)e[x]=t.readInt32BE(4*x),e[x+1]=t.readInt32BE(4*x+4);for(;x<160;x+=2){var B=e[x-30],C=e[x-30+1],T=d(B,C),P=p(C,B),R=m(B=e[x-4],C=e[x-4+1]),O=g(C,B),j=e[x-14],D=e[x-14+1],N=e[x-32],z=e[x-32+1],K=P+D|0,q=T+j+b(K,P)|0;q=(q=q+R+b(K=K+O|0,O)|0)+N+b(K=K+z|0,z)|0,e[x]=q,e[x+1]=K}for(var U=0;U<160;U+=2){q=e[U],K=e[U+1];var F=f(r,i,n),L=f(w,_,M),Q=c(r,w),H=c(w,r),V=l(s,I),Z=l(I,s),G=a[U],Y=a[U+1],W=h(s,u,v),J=h(I,S,E),X=k+Z|0,$=y+V+b(X,k)|0;$=($=($=$+W+b(X=X+J|0,J)|0)+G+b(X=X+Y|0,Y)|0)+q+b(X=X+K|0,K)|0;var tt=H+L|0,et=Q+F+b(tt,H)|0;y=v,k=E,v=u,E=S,u=s,S=I,s=o+$+b(I=A+X|0,A)|0,o=n,A=M,n=i,M=_,i=r,_=w,r=$+et+b(w=X+tt|0,X)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+M|0,this._dl=this._dl+A|0,this._el=this._el+I|0,this._fl=this._fl+S|0,this._gl=this._gl+E|0,this._hl=this._hl+k|0,this._ah=this._ah+r+b(this._al,w)|0,this._bh=this._bh+i+b(this._bl,_)|0,this._ch=this._ch+n+b(this._cl,M)|0,this._dh=this._dh+o+b(this._dl,A)|0,this._eh=this._eh+s+b(this._el,I)|0,this._fh=this._fh+u+b(this._fl,S)|0,this._gh=this._gh+v+b(this._gl,E)|0,this._hh=this._hh+y+b(this._hl,k)|0},u.prototype._hash=function(){var t=o.allocUnsafe(64);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){"use strict";var i=r(1),n=r(203),o=r(16),a=r(2).Buffer,s=r(90),u=r(52),h=r(53),f=a.alloc(128);function c(t,e){o.call(this,"digest"),"string"===typeof e&&(e=a.from(e));var r="sha512"===t||"sha384"===t?128:64;(this._alg=t,this._key=e,e.length>r)?e=("rmd160"===t?new u:h(t)).update(e).digest():e.lengthr||o!==o)throw new TypeError("Bad key length")}}).call(this,r(0).Buffer)},function(t,e,r){(function(e){var r;e.browser?r="utf-8":r=parseInt(e.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary";t.exports=r}).call(this,r(8))},function(t,e,r){var i=r(90),n=r(52),o=r(53),a=r(93),s=r(94),u=r(2).Buffer,h=u.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function c(t,e,r){var a=function(t){return"rmd160"===t||"ripemd160"===t?function(t){return(new n).update(t).digest()}:"md5"===t?i:function(e){return o(t).update(e).digest()}}(t),s="sha512"===t||"sha384"===t?128:64;e.length>s?e=a(e):e.lengtht;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),e.cmp(u)){if(!e.cmp(h))for(;r.mod(f).cmp(c);)r.iadd(d)}else for(;r.mod(o).cmp(l);)r.iadd(d);if(g(p=r.shrn(1))&&g(r)&&b(p)&&b(r)&&a.test(p)&&a.test(r))return r}}},function(t,e,r){var i=r(5),n=r(57);function o(t){this.rand=t||new n.Rand}t.exports=o,o.create=function(t){return new o(t)},o.prototype._randbelow=function(t){var e=t.bitLength(),r=Math.ceil(e/8);do{var n=new i(this.rand.generate(r))}while(n.cmp(t)>=0);return n},o.prototype._randrange=function(t,e){var r=e.sub(t);return t.add(this._randbelow(r))},o.prototype.test=function(t,e,r){var n=t.bitLength(),o=i.mont(t),a=new i(1).toRed(o);e||(e=Math.max(1,n/48|0));for(var s=t.subn(1),u=0;!s.testn(u);u++);for(var h=t.shrn(u),f=s.toRed(o);e>0;e--){var c=this._randrange(new i(2),s);r&&r(c);var l=c.toRed(o).redPow(h);if(0!==l.cmp(a)&&0!==l.cmp(f)){for(var d=1;d0;e--){var f=this._randrange(new i(2),a),c=t.gcd(f);if(0!==c.cmpn(1))return c;var l=f.toRed(n).redPow(u);if(0!==l.cmp(o)&&0!==l.cmp(h)){for(var d=1;d>8,a=255&n;o?r.push(o,a):r.push(a)}return r},i.zero2=n,i.toHex=o,i.encode=function(t,e){return"hex"===e?o(t):t}},function(t,e,r){"use strict";var i=e;i.base=r(41),i.short=r(231),i.mont=r(232),i.edwards=r(233)},function(t,e,r){"use strict";var i=r(15).rotr32;function n(t,e,r){return t&e^~t&r}function o(t,e,r){return t&e^t&r^e&r}function a(t,e,r){return t^e^r}e.ft_1=function(t,e,r,i){return 0===t?n(e,r,i):1===t||3===t?a(e,r,i):2===t?o(e,r,i):void 0},e.ch32=n,e.maj32=o,e.p32=a,e.s0_256=function(t){return i(t,2)^i(t,13)^i(t,22)},e.s1_256=function(t){return i(t,6)^i(t,11)^i(t,25)},e.g0_256=function(t){return i(t,7)^i(t,18)^t>>>3},e.g1_256=function(t){return i(t,17)^i(t,19)^t>>>10}},function(t,e,r){"use strict";var i=r(15),n=r(34),o=r(105),a=r(13),s=i.sum32,u=i.sum32_4,h=i.sum32_5,f=o.ch32,c=o.maj32,l=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,g=n.BlockHash,b=[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 v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=b,this.W=new Array(64)}i.inherits(v,g),t.exports=v,v.blockSize=512,v.outSize=256,v.hmacStrength=192,v.padLength=64,v.prototype._update=function(t,e){for(var r=this.W,i=0;i<16;i++)r[i]=t[e+i];for(;i>6],n=0===(32&r);if(31===(31&r)){var o=r;for(r=0;128===(128&o);){if(o=t.readUInt8(e),t.isError(o))return o;r<<=7,r|=127&o}}else r&=31;return{cls:i,primitive:n,tag:r,tagStr:s.tag[r]}}function c(t,e,r){var i=t.readUInt8(r);if(t.isError(i))return i;if(!e&&128===i)return null;if(0===(128&i))return i;var n=127&i;if(n>4)return t.error("length octect is too long");i=0;for(var o=0;o=31)return i.error("Multi-octet tag encoding unsupported");e||(n|=32);return n|=s.tagClassByName[r||"universal"]<<6}(t,e,r,this.reporter);if(i.length<128)return(o=new n(2))[0]=a,o[1]=i.length,this._createEncoderBuffer([o,i]);for(var u=1,h=i.length;h>=256;h>>=8)u++;(o=new n(2+u))[0]=a,o[1]=128|u;h=1+u;for(var f=i.length;f>0;h--,f>>=8)o[h]=255&f;return this._createEncoderBuffer([o,i])},h.prototype._encodeStr=function(t,e){if("bitstr"===e)return this._createEncoderBuffer([0|t.unused,t.data]);if("bmpstr"===e){for(var r=new n(2*t.length),i=0;i=40)return this.reporter.error("Second objid identifier OOB");t.splice(0,2,40*t[0]+t[1])}var o=0;for(i=0;i=128;a>>=7)o++}var s=new n(o),u=s.length-1;for(i=t.length-1;i>=0;i--){a=t[i];for(s[u--]=127&a;(a>>=7)>0;)s[u--]=128|127&a}return this._createEncoderBuffer(s)},h.prototype._encodeTime=function(t,e){var r,i=new Date(t);return"gentime"===e?r=[f(i.getFullYear()),f(i.getUTCMonth()+1),f(i.getUTCDate()),f(i.getUTCHours()),f(i.getUTCMinutes()),f(i.getUTCSeconds()),"Z"].join(""):"utctime"===e?r=[f(i.getFullYear()%100),f(i.getUTCMonth()+1),f(i.getUTCDate()),f(i.getUTCHours()),f(i.getUTCMinutes()),f(i.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+e+" time is not supported yet"),this._encodeStr(r,"octstr")},h.prototype._encodeNull=function(){return this._createEncoderBuffer("")},h.prototype._encodeInt=function(t,e){if("string"===typeof t){if(!e)return this.reporter.error("String int or enum given, but no values map");if(!e.hasOwnProperty(t))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(t));t=e[t]}if("number"!==typeof t&&!n.isBuffer(t)){var r=t.toArray();!t.sign&&128&r[0]&&r.unshift(0),t=new n(r)}if(n.isBuffer(t)){var i=t.length;0===t.length&&i++;var o=new n(i);return t.copy(o),0===t.length&&(o[0]=0),this._createEncoderBuffer(o)}if(t<128)return this._createEncoderBuffer(t);if(t<256)return this._createEncoderBuffer([0,t]);i=1;for(var a=t;a>=256;a>>=8)i++;for(a=(o=new Array(i)).length-1;a>=0;a--)o[a]=255&t,t>>=8;return 128&o[0]&&o.unshift(0),this._createEncoderBuffer(new n(o))},h.prototype._encodeBool=function(t){return this._createEncoderBuffer(t?255:0)},h.prototype._use=function(t,e){return"function"===typeof t&&(t=t(e)),t._getEncoder("der").tree},h.prototype._skipDefault=function(t,e,r){var i,n=this._baseState;if(null===n.default)return!1;var o=t.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,e,r).join()),o.length!==n.defaultBuffer.length)return!1;for(i=0;ithis.SegNum*this.SegBitsNum&&s(!1,"bigBuffer.length > SegNum * SegBitsNum");for(var i=Math.ceil(this.SegBitsNum/this.Bits),a=Math.ceil(r.bitsLength()/this.SegBitsNum),h=u.Point.ZERO,f=0;f=s),this.bitsLen=n,this.rightBits=r%8,this.buf=t.from(e.slice(Math.floor(r/8),Math.floor((a-1)/8)+1)),this.buf[this.buf.length-1]&=o.get(a%8)}return e.prototype.toBigNumber=function(){return new n(this.buf,"le").shrn(this.rightBits)},e.prototype.bitsLength=function(){return this.bitsLen},e.from=function(t,r,i){return new e(t.buf,r+t.rightBits,i)},e}();e.BitBuffer=a}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(6),o=r(4),a=r(17),s=r(43);function u(t){return a.blake2b("SZK$DSAN$HASH2",t)}function h(t){return new s(t)}e.sign=function(e,r,i,o){var s=t.concat([h(32),r.toBuffer(),e]),f=new n.FR(function(t){return a.blake2b("SZK$DSAN$HASH1",t)}(s)),c=i.mult(f);if(c&&!c.isZero()&&c.isValid()){var l=o.mult(f);if(l&&!l.isZero()&&l.isValid()){var d=i.mult(r);if(d&&!d.isZero()&&d.isValid()){var p=o.mult(r);if(p&&!p.isZero()&&p.isValid()){var m=t.concat([c.toBuffer(),l.toBuffer(),d.toBuffer(),p.toBuffer(),e]),g=new n.FR(u(m)),b=f.add(r.mul(g));return t.concat([b.toBuffer(),c.toBuffer(),l.toBuffer()])}}}}},e.verify=function(e,r,a,s,h,f){if(o(96==r.length,"sign.length != 96"),!a||a.isZero()||!a.isValid())return!1;if(!s||s.isZero()||!s.isValid())return!1;var c=new n.FR(r.slice(0,32)),l=i.Point.bufferTo(r.slice(32,64)),d=i.Point.bufferTo(r.slice(64,96));if(!c||c.isZero())return!1;if(!l||l.isZero()||!l.isValid())return!1;if(!d||d.isZero()||!d.isValid())return!1;var p=h.mult(c);if(!p||p.isZero()||!p.isValid())return!1;var m=f.mult(c);if(!m||m.isZero()||!m.isValid())return!1;var g=t.concat([l.toBuffer(),d.toBuffer(),a.toBuffer(),s.toBuffer(),e]),b=new n.FR(u(g)),v=a.mult(b),y=l.add(v);if(!p.isEqualTo(y))return!1;var w=s.mult(b),_=d.add(w);return!!m.isEqualTo(_)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(3),o=r(4),a=r(66),s=function(){function e(t,e){this.ZPK=i.newPoint(t),this.VPK=i.newPoint(e)}return e.prototype.toBuffer=function(){return t.concat([this.ZPK.toBuffer(),this.VPK.toBuffer()])},e.prototype.toString=function(){return n.default.bufferToBs58(this.toBuffer())},e}();e.PK=s,e.newPK=function(t){if(t instanceof s)return t;var e=n.toBuffer(t);o(64==e.length);var r=i.Point.bufferTo(e.slice(0,32)),a=i.Point.bufferTo(e.slice(32,64));return new s(r,a)},e.tk2PK=function(t){var e=(t=a.newTK(t)).ZPK,r=t.ZPK.mult(t.vsk);return new s(e,r)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(37),n=r(6),o=r(3),a=r(64),s=r(4),u=function(){function e(t,e,r){this.asset=i.newAsset(t),this.memo=o.toBuffer(e),this.ar=n.newFR(r)}return e.prototype.isValid=function(){return!!this.asset.isValid()&&!this.ar.isZero()},e.prototype.toBuffer=function(){return t.concat([this.asset.toBuffer(),this.memo,this.ar.toBuffer()])},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function h(t){if(t instanceof u)return t;var e=o.toBuffer(t);s(224==e.length);var r=0,a=128,h=i.newAsset(e.slice(r,r+a));r+=a,a=64;var f=e.slice(r,r+a);r+=a,a=32;var c=n.newFR(e.slice(r,r+a));return new u(h,f,c)}e.Info=u,e.newInfo=h,e.encInfo=function(t,e){t=o.toBuffer(t);var r=(e=h(e)).toBuffer();return a.default(r,t)},e.decEInfo=function(t,e){return t=o.toBuffer(t),e=o.toBuffer(e),h(a.default(e,t))}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(48),n=r(43),o=r(276),a=r(293),s=r(296),u=r(142),h=r(3),f=r(6),c=r(45),l=function(){function t(t,e){if(this.version=2,void 0!==t){void 0===e&&(e=g());var r=h.toBuffer(e);this.keystore=p(r,t,2);var i=c.seed2Sk(r,2),n=c.sk2Tk(i);return this.tk=n,this.pk=c.tk2PK(n),this.version=2,this}}return t.prototype.fromKeystore=function(t){var e="object"==typeof t?t:JSON.parse(t);this.keystore=e,this.tk=e.tk,this.version=this.keystore.version;var r=h.toBuffer(this.tk);if(h.isNewVersion(r)){if(2!==this.version)throw new Error("keystore version not match tk")}else if(1!==this.version)throw new Error("keystore version not match tk");var i=c.tk2PK(this.tk);return this.pk=i,this},t.prototype.fromMnemonic=function(t,e){var r=t.split(" "),i=1;if(25===r.length){if("v2"!==r[0])throw new Error("invalid mnemoic!");i=2,t=r.slice(1).join(" ")}if(s.validateMnemonic(t)){var n=s.mnemonicToEntropy(t),o=h.toBuffer(n);this.keystore=p(o,e,i);var a=c.seed2Sk(o,i),u=c.sk2Tk(a);return this.tk=u,this.pk=this.keystore.address,this.version=i,this}throw new Error("invald mnemonic!")},t.prototype.fromTk=function(t){var e=h.toBuffer(t),r=1;return h.isNewVersion(e)&&(r=2),this.tk=t,this.pk=c.tk2PK(e),this.keystore=function(t,e){var r=c.tk2PK(t);return{version:e,id:a({random:n(16)}),address:r,tk:t.toString(),at:0}}(this.tk,r),this.version=r,this},t.prototype.getSk=function(t){if(this.keystore.crypto){var e=d(this.keystore,t);return c.seed2Sk(e,this.keystore.version)}return""},t.prototype.getTk=function(){return this.tk.toString()},t.prototype.getPk=function(){return this.pk},t.prototype.getVersion=function(){return this.version},t.prototype.getKeystore=function(){return this.keystore},t.prototype.exportMnemonic=function(t){var e=d(this.keystore,t),r=this.keystore.version,i=s.entropyToMnemonic(e);return 2===r&&(i="v2 "+i),i},t}();function d(e,r){var n,a,s="object"==typeof e?e:JSON.parse(e);if("scrypt"!==s.crypto.kdf)throw new Error("Unsupported key derivation scheme");a=s.crypto.kdfparams,n=o(t.from(r),h.toBuffer(a.salt),a.n,a.r,a.p,a.dklen);var f=t.from(s.crypto.ciphertext,"hex");if(u(t.concat([n.slice(16,32),f])).toString("hex")!==s.crypto.mac)throw new Error("Key derivation failed - possibly wrong passphrase");return m(i.createDecipheriv(s.crypto.cipher,n.slice(0,16),t.from(s.crypto.cipherparams.iv,"hex")),f)}function p(e,r,s){if(!function(t){return null!=t}(e))throw new Error("This is a public key only wallet");var f={cipher:"aes-128-ctr",kdf:"scrypt",salt:n(32),iv:n(16),uuid:n(16),dklen:32,c:262144,n:262144,r:8,p:1},l=function(t){return{dklen:t.dklen,salt:t.salt.toString("hex"),n:t.n,r:t.r,p:t.p}}(f),d=o(t.from(r),h.toBuffer(l.salt),l.n,l.r,l.p,l.dklen),p=i.createCipheriv(f.cipher,d.slice(0,16),f.iv);if(!p)throw new Error("Unsupported cipher");var g=m(p,e),b=u(t.concat([d.slice(16,32),t.from(g)])),v=c.seed2Sk(e,s),y=c.sk2Tk(v),w=c.tk2PK(y);return l.salt=l.salt,{version:s,id:a({random:f.uuid}),address:w,tk:y.toString(),crypto:{ciphertext:g.toString("hex"),cipherparams:{iv:f.iv.toString("hex")},cipher:f.cipher,kdf:f.kdf,kdfparams:l,mac:b.toString("hex")},at:0}}function m(e,r){return t.concat([e.update(r),e.final()])}function g(){return f.randomFR().toBuffer().toString("hex")}e.default=l,e.createPkrHash=function(e,r,i){if(2!==i&&1!==i)throw new Error("ivalid version");e=h.toBuffer(e);var n=h.toBN(r).toArrayLike(t,"be");if(8r||e!==e)throw new TypeError("Bad key length")}},function(t,e,r){(function(e){var r;if(e.browser)r="utf-8";else if(e.version){r=parseInt(e.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else r="utf-8";t.exports=r}).call(this,r(8))},function(t,e,r){var i=r(279),n=r(136),o=r(137),a=r(7).Buffer,s=r(125),u=r(126),h=r(140),f=a.alloc(128),c={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function l(t,e,r){var s=function(t){return"rmd160"===t||"ripemd160"===t?function(t){return(new n).update(t).digest()}:"md5"===t?i:function(e){return o(t).update(e).digest()}}(t),u="sha512"===t||"sha384"===t?128:64;e.length>u?e=s(e):e.length>>32-e}function h(t,e,r,i,n,o,a){return u(t+(e&r|~e&i)+n+o|0,a)+e|0}function f(t,e,r,i,n,o,a){return u(t+(e&i|r&~i)+n+o|0,a)+e|0}function c(t,e,r,i,n,o,a){return u(t+(e^r^i)+n+o|0,a)+e|0}function l(t,e,r,i,n,o,a){return u(t+(r^(e|~i))+n+o|0,a)+e|0}i(s,n),s.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);var r=this._a,i=this._b,n=this._c,o=this._d;r=h(r,i,n,o,t[0],3614090360,7),o=h(o,r,i,n,t[1],3905402710,12),n=h(n,o,r,i,t[2],606105819,17),i=h(i,n,o,r,t[3],3250441966,22),r=h(r,i,n,o,t[4],4118548399,7),o=h(o,r,i,n,t[5],1200080426,12),n=h(n,o,r,i,t[6],2821735955,17),i=h(i,n,o,r,t[7],4249261313,22),r=h(r,i,n,o,t[8],1770035416,7),o=h(o,r,i,n,t[9],2336552879,12),n=h(n,o,r,i,t[10],4294925233,17),i=h(i,n,o,r,t[11],2304563134,22),r=h(r,i,n,o,t[12],1804603682,7),o=h(o,r,i,n,t[13],4254626195,12),n=h(n,o,r,i,t[14],2792965006,17),r=f(r,i=h(i,n,o,r,t[15],1236535329,22),n,o,t[1],4129170786,5),o=f(o,r,i,n,t[6],3225465664,9),n=f(n,o,r,i,t[11],643717713,14),i=f(i,n,o,r,t[0],3921069994,20),r=f(r,i,n,o,t[5],3593408605,5),o=f(o,r,i,n,t[10],38016083,9),n=f(n,o,r,i,t[15],3634488961,14),i=f(i,n,o,r,t[4],3889429448,20),r=f(r,i,n,o,t[9],568446438,5),o=f(o,r,i,n,t[14],3275163606,9),n=f(n,o,r,i,t[3],4107603335,14),i=f(i,n,o,r,t[8],1163531501,20),r=f(r,i,n,o,t[13],2850285829,5),o=f(o,r,i,n,t[2],4243563512,9),n=f(n,o,r,i,t[7],1735328473,14),r=c(r,i=f(i,n,o,r,t[12],2368359562,20),n,o,t[5],4294588738,4),o=c(o,r,i,n,t[8],2272392833,11),n=c(n,o,r,i,t[11],1839030562,16),i=c(i,n,o,r,t[14],4259657740,23),r=c(r,i,n,o,t[1],2763975236,4),o=c(o,r,i,n,t[4],1272893353,11),n=c(n,o,r,i,t[7],4139469664,16),i=c(i,n,o,r,t[10],3200236656,23),r=c(r,i,n,o,t[13],681279174,4),o=c(o,r,i,n,t[0],3936430074,11),n=c(n,o,r,i,t[3],3572445317,16),i=c(i,n,o,r,t[6],76029189,23),r=c(r,i,n,o,t[9],3654602809,4),o=c(o,r,i,n,t[12],3873151461,11),n=c(n,o,r,i,t[15],530742520,16),r=l(r,i=c(i,n,o,r,t[2],3299628645,23),n,o,t[0],4096336452,6),o=l(o,r,i,n,t[7],1126891415,10),n=l(n,o,r,i,t[14],2878612391,15),i=l(i,n,o,r,t[5],4237533241,21),r=l(r,i,n,o,t[12],1700485571,6),o=l(o,r,i,n,t[3],2399980690,10),n=l(n,o,r,i,t[10],4293915773,15),i=l(i,n,o,r,t[1],2240044497,21),r=l(r,i,n,o,t[8],1873313359,6),o=l(o,r,i,n,t[15],4264355552,10),n=l(n,o,r,i,t[6],2734768916,15),i=l(i,n,o,r,t[13],1309151649,21),r=l(r,i,n,o,t[4],4149444226,6),o=l(o,r,i,n,t[11],3174756917,10),n=l(n,o,r,i,t[2],718787259,15),i=l(i,n,o,r,t[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+i|0,this._c=this._c+n|0,this._d=this._d+o|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=o.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t},t.exports=s},function(t,e,r){"use strict";var i=r(7).Buffer,n=r(280).Transform;function o(t){n.call(this),this._block=i.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(9)(o,n),o.prototype._transform=function(t,e,r){var i=null;try{this.update(t,e)}catch(n){i=n}r(i)},o.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(r){e=r}t(e)},o.prototype.update=function(t,e){if(function(t,e){if(!i.isBuffer(t)&&"string"!==typeof t)throw new TypeError(e+" must be a string or a buffer")}(t,"Data"),this._finalized)throw new Error("Digest already called");i.isBuffer(t)||(t=i.from(t,e));for(var r=this._block,n=0;this._blockOffset+t.length-n>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();void 0!==t&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return e},o.prototype._digest=function(){throw new Error("_digest is not implemented")},t.exports=o},function(t,e,r){"use strict";(function(e,i){var n;t.exports=S,S.ReadableState=I;r(31).EventEmitter;var o=function(t,e){return t.listeners(e).length},a=r(131),s=r(0).Buffer,u=e.Uint8Array||function(){};var h,f=r(281);h=f&&f.debuglog?f.debuglog("stream"):function(){};var c,l,d,p=r(282),m=r(132),g=r(133).getHighWaterMark,b=r(26).codes,v=b.ERR_INVALID_ARG_TYPE,y=b.ERR_STREAM_PUSH_AFTER_EOF,w=b.ERR_METHOD_NOT_IMPLEMENTED,_=b.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(9)(S,a);var M=m.errorOrDestroy,A=["error","close","destroy","pause","resume"];function I(t,e,i){n=n||r(27),t=t||{},"boolean"!==typeof i&&(i=e instanceof n),this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=g(this,t,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==t.emitClose,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(c||(c=r(23).StringDecoder),this.decoder=new c(t.encoding),this.encoding=t.encoding)}function S(t){if(n=n||r(27),!(this instanceof S))return new S(t);var e=this instanceof n;this._readableState=new I(t,this,e),this.readable=!0,t&&("function"===typeof t.read&&(this._read=t.read),"function"===typeof t.destroy&&(this._destroy=t.destroy)),a.call(this)}function E(t,e,r,i,n){h("readableAddChunk",e);var o,a=t._readableState;if(null===e)a.reading=!1,function(t,e){if(h("onEofChunk"),e.ended)return;if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?C(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,T(t)))}(t,a);else if(n||(o=function(t,e){var r;i=e,s.isBuffer(i)||i instanceof u||"string"===typeof e||void 0===e||t.objectMode||(r=new v("chunk",["string","Buffer","Uint8Array"],e));var i;return r}(a,e)),o)M(t,o);else if(a.objectMode||e&&e.length>0)if("string"===typeof e||a.objectMode||Object.getPrototypeOf(e)===s.prototype||(e=function(t){return s.from(t)}(e)),i)a.endEmitted?M(t,new _):k(t,a,e,!0);else if(a.ended)M(t,new y);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!r?(e=a.decoder.write(e),a.objectMode||0!==e.length?k(t,a,e,!1):P(t,a)):k(t,a,e,!1)}else i||(a.reading=!1,P(t,a));return!a.ended&&(a.lengthe.highWaterMark&&(e.highWaterMark=function(t){return t>=x?t=x:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function C(t){var e=t._readableState;h("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(h("emitReadable",e.flowing),e.emittedReadable=!0,i.nextTick(T,t))}function T(t){var e=t._readableState;h("emitReadable_",e.destroyed,e.length,e.ended),e.destroyed||!e.length&&!e.ended||(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,N(t)}function P(t,e){e.readingMore||(e.readingMore=!0,i.nextTick(R,t,e))}function R(t,e){for(;!e.reading&&!e.ended&&(e.length0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function j(t){h("readable nexttick read 0"),t.read(0)}function D(t,e){h("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),N(t),e.flowing&&!e.reading&&t.read(0)}function N(t){var e=t._readableState;for(h("flow",e.flowing);e.flowing&&null!==t.read(););}function z(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r);var r}function K(t){var e=t._readableState;h("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,i.nextTick(q,e,t))}function q(t,e){if(h("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function U(t,e){for(var r=0,i=t.length;r=e.highWaterMark:e.length>0)||e.ended))return h("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?K(this):C(this),null;if(0===(t=B(t,e))&&e.ended)return 0===e.length&&K(this),null;var i,n=e.needReadable;return h("need readable",n),(0===e.length||e.length-t0?z(t,e):null)?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&K(this)),null!==i&&this.emit("data",i),i},S.prototype._read=function(t){M(this,new w("_read()"))},S.prototype.pipe=function(t,e){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=t;break;case 1:n.pipes=[n.pipes,t];break;default:n.pipes.push(t)}n.pipesCount+=1,h("pipe count=%d opts=%j",n.pipesCount,e);var a=(!e||!1!==e.end)&&t!==i.stdout&&t!==i.stderr?u:g;function s(e,i){h("onunpipe"),e===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,h("cleanup"),t.removeListener("close",p),t.removeListener("finish",m),t.removeListener("drain",f),t.removeListener("error",d),t.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",g),r.removeListener("data",l),c=!0,!n.awaitDrain||t._writableState&&!t._writableState.needDrain||f())}function u(){h("onend"),t.end()}n.endEmitted?i.nextTick(a):r.once("end",a),t.on("unpipe",s);var f=function(t){return function(){var e=t._readableState;h("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&o(t,"data")&&(e.flowing=!0,N(t))}}(r);t.on("drain",f);var c=!1;function l(e){h("ondata");var i=t.write(e);h("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===t||n.pipesCount>1&&-1!==U(n.pipes,t))&&!c&&(h("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function d(e){h("onerror",e),g(),t.removeListener("error",d),0===o(t,"error")&&M(t,e)}function p(){t.removeListener("finish",m),g()}function m(){h("onfinish"),t.removeListener("close",p),g()}function g(){h("unpipe"),r.unpipe(t)}return r.on("data",l),function(t,e,r){if("function"===typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",d),t.once("close",p),t.once("finish",m),t.emit("pipe",r),n.flowing||(h("pipe resume"),r.resume()),t},S.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===t&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,h("on readable",n.length,n.reading),n.length?C(this):n.reading||i.nextTick(j,this))),r},S.prototype.addListener=S.prototype.on,S.prototype.removeListener=function(t,e){var r=a.prototype.removeListener.call(this,t,e);return"readable"===t&&i.nextTick(O,this),r},S.prototype.removeAllListeners=function(t){var e=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==t&&void 0!==t||i.nextTick(O,this),e},S.prototype.resume=function(){var t=this._readableState;return t.flowing||(h("resume"),t.flowing=!t.readableListening,function(t,e){e.resumeScheduled||(e.resumeScheduled=!0,i.nextTick(D,t,e))}(this,t)),t.paused=!1,this},S.prototype.pause=function(){return h("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(h("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},S.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;for(var n in t.on("end",(function(){if(h("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)})),t.on("data",(function(n){(h("wrapped data"),r.decoder&&(n=r.decoder.write(n)),!r.objectMode||null!==n&&void 0!==n)&&((r.objectMode||n&&n.length)&&(e.push(n)||(i=!0,t.pause())))})),t)void 0===this[n]&&"function"===typeof t[n]&&(this[n]=function(e){return function(){return t[e].apply(t,arguments)}}(n));for(var o=0;o-1))throw new _(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(S.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(S.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),S.prototype._write=function(t,e,r){r(new m("_write()"))},S.prototype._writev=null,S.prototype.end=function(t,e,r){var n=this._writableState;return"function"===typeof t?(r=t,t=null,e=null):"function"===typeof e&&(r=e,e=null),null!==t&&void 0!==t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||function(t,e,r){e.ending=!0,T(t,e),r&&(e.finished?i.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,n,r),this},Object.defineProperty(S.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(S.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),S.prototype.destroy=c.destroy,S.prototype._undestroy=c.undestroy,S.prototype._destroy=function(t,e){e(t)}}).call(this,r(10),r(8))},function(t,e,r){"use strict";t.exports=f;var i=r(26).codes,n=i.ERR_METHOD_NOT_IMPLEMENTED,o=i.ERR_MULTIPLE_CALLBACK,a=i.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=i.ERR_TRANSFORM_WITH_LENGTH_0,u=r(27);function h(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(null===i)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length>>32-e}function m(t,e,r,i,n,o,a,s){return p(t+(e^r^i)+o+a|0,s)+n|0}function g(t,e,r,i,n,o,a,s){return p(t+(e&r|~e&i)+o+a|0,s)+n|0}function b(t,e,r,i,n,o,a,s){return p(t+((e|~r)^i)+o+a|0,s)+n|0}function v(t,e,r,i,n,o,a,s){return p(t+(e&i|r&~i)+o+a|0,s)+n|0}function y(t,e,r,i,n,o,a,s){return p(t+(e^(r|~i))+o+a|0,s)+n|0}n(d,o),d.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);for(var r=0|this._a,i=0|this._b,n=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,_=0|this._b,M=0|this._c,A=0|this._d,I=0|this._e,S=0;S<80;S+=1){var E,k;S<16?(E=m(r,i,n,o,d,t[s[S]],c[0],h[S]),k=y(w,_,M,A,I,t[u[S]],l[0],f[S])):S<32?(E=g(r,i,n,o,d,t[s[S]],c[1],h[S]),k=v(w,_,M,A,I,t[u[S]],l[1],f[S])):S<48?(E=b(r,i,n,o,d,t[s[S]],c[2],h[S]),k=b(w,_,M,A,I,t[u[S]],l[2],f[S])):S<64?(E=v(r,i,n,o,d,t[s[S]],c[3],h[S]),k=g(w,_,M,A,I,t[u[S]],l[3],f[S])):(E=y(r,i,n,o,d,t[s[S]],c[4],h[S]),k=m(w,_,M,A,I,t[u[S]],l[4],f[S])),r=d,d=o,o=p(n,10),n=i,i=E,w=I,I=A,A=p(M,10),M=_,_=k}var x=this._b+n+A|0;this._b=this._c+o+I|0,this._c=this._d+d+w|0,this._d=this._e+r+_|0,this._e=this._a+i+M|0,this._a=x},d.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=i.alloc?i.alloc(20):new i(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t},t.exports=d},function(t,e,r){(e=t.exports=function(t){t=t.toLowerCase();var r=e[t];if(!r)throw new Error(t+" is not supported (we accept pull requests)");return new r}).sha=r(289),e.sha1=r(290),e.sha224=r(291),e.sha256=r(138),e.sha384=r(292),e.sha512=r(139)},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],s=new Array(64);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t){return(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function l(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function d(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}i(u,n),u.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},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,g=0|this._h,b=0;b<16;++b)r[b]=t.readInt32BE(4*b);for(;b<64;++b)r[b]=0|(((e=r[b-2])>>>17|e<<15)^(e>>>19|e<<13)^e>>>10)+r[b-7]+d(r[b-15])+r[b-16];for(var v=0;v<64;++v){var y=g+l(u)+h(u,p,m)+a[v]+r[v]|0,w=c(i)+f(i,n,o)|0;g=m,m=p,p=u,u=s+y|0,s=o,o=n,n=i,i=y+w|0}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},u.prototype._hash=function(){var t=o.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},t.exports=u},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[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 u(){this.init(),this._w=s,n.call(this,128,112)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function l(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function d(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function p(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function m(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function g(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function b(t,e){return t>>>0>>0?1:0}i(u,n),u.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},u.prototype._update=function(t){for(var e=this._w,r=0|this._ah,i=0|this._bh,n=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,v=0|this._gh,y=0|this._hh,w=0|this._al,_=0|this._bl,M=0|this._cl,A=0|this._dl,I=0|this._el,S=0|this._fl,E=0|this._gl,k=0|this._hl,x=0;x<32;x+=2)e[x]=t.readInt32BE(4*x),e[x+1]=t.readInt32BE(4*x+4);for(;x<160;x+=2){var B=e[x-30],C=e[x-30+1],T=d(B,C),P=p(C,B),R=m(B=e[x-4],C=e[x-4+1]),O=g(C,B),j=e[x-14],D=e[x-14+1],N=e[x-32],z=e[x-32+1],K=P+D|0,q=T+j+b(K,P)|0;q=(q=q+R+b(K=K+O|0,O)|0)+N+b(K=K+z|0,z)|0,e[x]=q,e[x+1]=K}for(var U=0;U<160;U+=2){q=e[U],K=e[U+1];var F=f(r,i,n),L=f(w,_,M),Q=c(r,w),H=c(w,r),V=l(s,I),Z=l(I,s),G=a[U],Y=a[U+1],W=h(s,u,v),J=h(I,S,E),X=k+Z|0,$=y+V+b(X,k)|0;$=($=($=$+W+b(X=X+J|0,J)|0)+G+b(X=X+Y|0,Y)|0)+q+b(X=X+K|0,K)|0;var tt=H+L|0,et=Q+F+b(tt,H)|0;y=v,k=E,v=u,E=S,u=s,S=I,s=o+$+b(I=A+X|0,A)|0,o=n,A=M,n=i,M=_,i=r,_=w,r=$+et+b(w=X+tt|0,X)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+M|0,this._dl=this._dl+A|0,this._el=this._el+I|0,this._fl=this._fl+S|0,this._gl=this._gl+E|0,this._hl=this._hl+k|0,this._ah=this._ah+r+b(this._al,w)|0,this._bh=this._bh+i+b(this._bl,_)|0,this._ch=this._ch+n+b(this._cl,M)|0,this._dh=this._dh+o+b(this._dl,A)|0,this._eh=this._eh+s+b(this._el,I)|0,this._fh=this._fh+u+b(this._fl,S)|0,this._gh=this._gh+v+b(this._gl,E)|0,this._hh=this._hh+y+b(this._hl,k)|0},u.prototype._hash=function(){var t=o.allocUnsafe(64);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){var i=r(7).Buffer;t.exports=function(t,e,r){if(i.isBuffer(t))return t;if("string"===typeof t)return i.from(t,e);if(ArrayBuffer.isView(t))return i.from(t.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i,n={};e.wordlists=n,e._default=i;try{e._default=i=r(303),n.chinese_simplified=i}catch(o){}try{e._default=i=r(304),n.chinese_traditional=i}catch(o){}try{e._default=i=r(305),n.korean=i}catch(o){}try{e._default=i=r(306),n.french=i}catch(o){}try{e._default=i=r(307),n.italian=i}catch(o){}try{e._default=i=r(308),n.spanish=i}catch(o){}try{e._default=i=r(309),n.japanese=i,n.JA=i}catch(o){}try{e._default=i=r(310),n.english=i,n.EN=i}catch(o){}},function(t,e,r){"use strict";(function(e){var i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n=r(311),o=r(317);function a(t){var e=t;if("string"!==typeof e)throw new Error("while padding to even, value must be string, is currently "+("undefined"===typeof e?"undefined":i(e))+", while padToEven.");return e.length%2&&(e="0"+e),e}t.exports=function(t){return t=function(t){if(!e.isBuffer(t))if(Array.isArray(t))t=e.from(t);else if("string"===typeof t)t=function(t,e){if("string"!==typeof t||!t.match(/^0x[0-9A-Fa-f]*$/))return!1;if(e&&t.length!==2+2*e)return!1;return!0}(t)?e.from(a(function(t){if("string"!==typeof t)return t;return function(t){if("string"!==typeof t)throw new Error("value must be type 'string', is currently type "+("undefined"===typeof t?"undefined":i(t))+", while checking isHexPrefixed.");return"0x"===t.slice(0,2)}(t)?t.slice(2):t}(t)),"hex"):e.from(t);else if("number"===typeof t)t=function(t){var r=function(t){return"0x"+t.toString(16)}(t);return e.from(a(r.slice(2)),"hex")}(t);else if(null===t||void 0===t)t=e.allocUnsafe(0);else if(o.isBN(t))t=t.toArrayLike(e);else{if(!t.toArray)throw new Error("invalid type");t=e.from(t.toArray())}return t}(t),n("keccak256").update(t).digest()}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r=r||Promise)((function(n,o){function a(t){try{u(i.next(t))}catch(t){o(t)}}function s(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):((e=t.value)instanceof r?e:new r((function(t){t(e)}))).then(a,s)}u((i=i.apply(t,e||[])).next())}))},n=this&&this.__generator||function(t,e){var r,i,n,o,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,i&&(n=2&o[0]?i.return:o[0]?i.throw||((n=i.return)&&n.call(i),0):i.next)&&!(n=n.call(i,o[1])).done)return n;switch(i=0,n&&(o=[2&o[0],n.value]),o[0]){case 0:case 1:n=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(n=0<(n=a.trys).length&&n[n.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!n||o[1]>n[0]&&o[1]n[0]&&o[1]>>> ",l,d),[4,e.findRoots(t.From,a.default.hexToCy(l),d)]);case 4:return p=n.sent(),console.log("result >>>> ",p),p&&(p.remain.isNeg()||p.remain.isZero())?(o.push.apply(o,p.utxos),[3,3]):[2,new Promise((function(t,e){e("no enough unlocked utxos")}))];case 5:return[2,new Promise((function(t){t(o)}))]}}))}))},e.buildTxParam=function(e,r){return i(this,void 0,void 0,(function(){var i,o,u,f,c,l,d,p,m,g,b,v,y;return n(this,(function(n){switch(n.label){case 0:return i=new Array,r.Utxos.forEach((function(t){i.push(t.Root)})),[4,e.getAnchor(i)];case 1:if(null===(o=n.sent()))throw new Error("can not find Anchor by root");if(u=new Array,f=0,c=new h(!1,r.Fee),r.Utxos.forEach((function(e,r){if(null===e.State)throw new Error("can not find out by root");c.AddIn(e.Asset),u.push({SKr:a.toString(t.alloc(96)),Out:{Root:e.Root,State:e.State},Witness:o[r]}),a.default.isNotNull(e.State.OS.Out_O)&&f++})),2500 2500");for(l=new Array,r.Receptions.forEach((function(e){c.AddOut(e.Asset),l.push({PKr:a.toHex(e.Addr),Asset:e.Asset,Memo:a.toString(t.alloc(64))})})),null!==r.Cmds&&null!==(d=new s(r.Cmds).OutAsset())&&c.AddOut(d),p=c.GetTknList(),m=c.GetTktList(),g=Math.max(p.length,m.length),b=0;bn[0]&&a[1]>> ",r.value[0],!1),m.set(r.value[0],!1)),r=e.next();console.error("======= fetchHandler error>>> ",t),z("Fetch Error:","string"==typeof t?t:t.message)})),w=(new Date).getTime()}t(),_=setInterval((function(){t()}),M)}(),t.data="success",R(t)},healthyCheck:function(t){var e=!1;w&&(e=(new Date).getTime()-w<6e4);var r=t.data;d.get(r).selectId(a.tables.syncInfo.name,1).then((function(i){t.data={health:e,latestSyncTime:w,isSyncing:m.get(r),latestBlock:i.CurrentBlock,currentBlock:b.get(r),pkrIndex:i.PkrIndex,startBlock:v.get(r),checkNilPercent:y.get(r)},R(t)})).catch((function(i){t.data={health:e,latestSyncTime:w,isSyncing:m.get(r),latestBlock:0,pkrIndex:1,currentBlock:0,startBlock:0,checkNilPercent:0},R(t)}))},initAccount:function(t){var e,r,i,n=t.data;n&&d&&!d.get(n)&&(e=1,s.isNewVersion(s.default.toBuffer(n))&&(e=2),r=f.createPkrHash(n,1,e),a.dbConfig.databaseName="popup_"+n,i=new o.PopDB(a.dbConfig),d.set(n,i),i.select(a.tables.syncInfo.name,{TK:n}).then((function(e){var o;e&&0!==e.length?(b.set(n,e[0].CurrentBlock),v.set(n,e[0].CurrentBlock)):(o={TK:n,PkrIndex:1,CurrentBlock:0,LastCombineBlock:0,UseHashPKr:!1,MainPKr:r,PKr:r},i.insert(a.tables.syncInfo.name,o).then((function(e){t.data="success"})).catch((function(e){console.log(e),t.error=e.message})),b.set(n,0),v.set(n,0)),y.set(n,0),R(t)})).catch((function(e){var o={TK:n,PkrIndex:1,CurrentBlock:0,LastCombineBlock:0,UseHashPKr:!1,MainPKr:r,PKr:r};i.insert(a.tables.syncInfo.name,o).then((function(e){t.data="success"})).catch((function(e){console.log(e),t.error=e.message})),b.set(n,0),v.set(n,0),R(t)})))},clearData:function(t){(function(t){return i(this,void 0,void 0,(function(){function e(e){return i(this,void 0,void 0,(function(){var r;return n(this,(function(i){switch(i.label){case 0:return[4,e.selectId(a.tables.syncInfo.name,1)];case 1:return r=i.sent(),!0!==m.get(r.TK)?[3,3]:[4,new Promise((function(t,e){e("Data synchronization ...")}))];case 2:return i.sent(),[3,15];case 3:return m.set(t,!0),p.delete(t),r.CurrentBlock=0,r.PKr=r.MainPKr,r.PkrIndex=1,r.UseHashPKr=!1,[4,e.update(a.tables.syncInfo.name,r)];case 4:return i.sent(),[4,e.clearTable(a.tables.utxo.name)];case 5:return i.sent(),[4,e.clearTable(a.tables.txBase.name)];case 6:return i.sent(),[4,e.clearTable(a.tables.assets.name)];case 7:return i.sent(),[4,e.clearTable(a.tables.assetUtxo.name)];case 8:return i.sent(),[4,e.clearTable(a.tables.tx.name)];case 9:return i.sent(),[4,e.clearTable(a.tables.nils.name)];case 10:return i.sent(),[4,e.clearTable(a.tables.txCurrency.name)];case 11:return i.sent(),[4,e.clearTable(a.tables.utxoTkt.name)];case 12:return i.sent(),[4,e.clearTable(a.tables.tickets.name)];case 13:return i.sent(),b.set(t,0),v.set(t,0),[4,new Promise((function(t){t("Clear Data Success !")}))];case 14:i.sent(),i.label=15;case 15:return[2]}}))}))}var r,o;return n(this,(function(i){switch(i.label){case 0:return t?[4,e(d.get(t))]:[3,2];case 1:return i.sent(),[3,5];case 2:r=d.entries(),o=r.next(),i.label=3;case 3:return o.done?[3,5]:[4,e(o.value[1])];case 4:return i.sent(),o=r.next(),[3,3];case 5:return[2]}}))}))})(t.data).then((function(e){console.log("data>>> ",e),m.clear(),t.data="Success",R(t)})).catch((function(e){console.log("data e>>> ",e),m.clear(),t.error=e,R(t)}))},findUtxos:function(t,e,r){},balanceOf:function(t){var e=t.data;function r(){d.get(e).selectAll(a.tables.assets.name).then((function(r){var i=new Map;r&&0> ",t)})).catch((function(t){console.error(t)})),u(c.Hash))}))]}}))}))})(e).then((function(e){console.log("_commitTx hash:",e),t.data=e,R(t)})).catch((function(e){console.error("_commitTx err:",e),t.error=e,R(t)}))}catch(e){t.error=e.message,R(t)}},getSeroPrice:function(t){var e=t.data;u.default.get("https://data.gateio.co/api2/1/ticker/"+e).then((function(e){var r;e&&e.data&&(r=e.data,t.data=r,R(t))})).catch((function(t){}))},getPendingAndConfirming:function(t){return i(this,void 0,void 0,(function(){var e;return n(this,(function(r){return e=t.data,g.has(e)?t.data=g.get(e):t.data=[],R(t),[2]}))}))}};function E(t){return i(this,void 0,void 0,(function(){var e,r,i,o,u,f,c,l,d,p,m,g,b,v,y;return n(this,(function(n){switch(n.label){case 0:return[4,t.selectAll(a.tables.utxo.name)];case 1:if(!((e=n.sent())&&0>",c.utxos.length),h=!0),[4,D(c,e.TK,t)];case 3:return n.sent(),c.useHashPKr&&(r.UseHashPKr=!0),!0!==c.again?[3,5]:(r.PkrIndex=r.PkrIndex+1,l=1,s.isNewVersion(s.default.toBuffer(e.TK))&&(l=2),r.PKr=f.createPkrHash(e.TK,r.PkrIndex,l),o=c.lastBlockNumber,u=r.PkrIndex,r.CurrentBlock=c.lastBlockNumber,[4,t.update(a.tables.syncInfo.name,r)]);case 4:return n.sent(),[3,6];case 5:return c.lastBlockNumber,r.CurrentBlock=c.lastBlockNumber,[3,7];case 6:return[3,1];case 7:return[4,t.update(a.tables.syncInfo.name,r)];case 8:return n.sent(),[4,F(e.TK)];case 9:return d=n.sent(),!0!==h&&!0!==d?[3,11]:[4,E(t)];case 10:n.sent(),n.label=11;case 11:return y.set(e.TK,0),[4,L(e.TK)];case 12:return n.sent(),[2]}}))}))}function D(t,e,r){return i(this,void 0,void 0,(function(){var i,o,s,u,h,f,c,l,d,p,m;return n(this,(function(n){switch(n.label){case 0:if(!(t.utxos&&0> ",{Root:l.Root,Value:s.Asset.Tkt.Value,Category:s.Asset.Tkt.Category}),[4,r.update(a.tables.tickets.name,{Root:l.Root,Value:s.Asset.Tkt.Value,Category:s.Asset.Tkt.Category})];case 9:n.sent(),n.label=10;case 10:return i++,[3,1];case 11:if(!(t.txInfos&&0n[0]&&a[1]n[0]&&a[1]0?a-4:a;for(r=0;r>16&255,u[f++]=e>>8&255,u[f++]=255&e;2===s&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,u[f++]=255&e);1===s&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,u[f++]=e>>8&255,u[f++]=255&e);return u},e.fromByteArray=function(t){for(var e,r=t.length,n=r%3,o=[],a=0,s=r-n;as?s:a+16383));1===n?(e=t[r-1],o.push(i[e>>2]+i[e<<4&63]+"==")):2===n&&(e=(t[r-2]<<8)+t[r-1],o.push(i[e>>10]+i[e>>4&63]+i[e<<2&63]+"="));return o.join("")};for(var i=[],n=[],o="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function f(t,e,r){for(var n,o,a=[],s=e;s>18&63]+i[o>>12&63]+i[o>>6&63]+i[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},function(t,e){e.read=function(t,e,r,i,n){var o,a,s=8*n-i-1,u=(1<>1,f=-7,c=r?n-1:0,l=r?-1:1,d=t[e+c];for(c+=l,o=d&(1<<-f)-1,d>>=-f,f+=s;f>0;o=256*o+t[e+c],c+=l,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=i;f>0;a=256*a+t[e+c],c+=l,f-=8);if(0===o)o=1-h;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,i),o-=h}return(d?-1:1)*a*Math.pow(2,o-i)},e.write=function(t,e,r,i,n,o){var a,s,u,h=8*o-n-1,f=(1<>1,l=23===n?Math.pow(2,-24)-Math.pow(2,-77):0,d=i?0:o-1,p=i?1:-1,m=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=f):(a=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-a))<1&&(a--,u*=2),(e+=a+c>=1?l/u:l*Math.pow(2,1-c))*u>=2&&(a++,u/=2),a+c>=f?(s=0,a=f):a+c>=1?(s=(e*u-1)*Math.pow(2,n),a+=c):(s=e*Math.pow(2,c-1)*Math.pow(2,n),a=0));n>=8;t[r+d]=255&s,d+=p,s/=256,n-=8);for(a=a<0;t[r+d]=255&a,d+=p,a/=256,h-=8);t[r+d-p]|=128*m}},function(t,e){},function(t,e,r){"use strict";var i=r(7).Buffer;t.exports=function(t){if(t.length>=255)throw new TypeError("Alphabet too long");var e=new Uint8Array(256);e.fill(255);for(var r=0;r>>0,f=new Uint8Array(h);t[r];){var c=e[t.charCodeAt(r)];if(255===c)return;for(var l=0,d=h-1;(0!==c||l>>0,f[d]=c%256>>>0,c=c/256>>>0;if(0!==c)throw new Error("Non-zero carry");o=l,r++}if(" "!==t[r]){for(var p=h-o;p!==h&&0===f[p];)p++;var m=i.allocUnsafe(n+(h-p));m.fill(0,0,n);for(var g=n;p!==h;)m[g++]=f[p++];return m}}}return{encode:function(e){if(!i.isBuffer(e))throw new TypeError("Expected Buffer");if(0===e.length)return"";for(var r=0,n=0,o=0,u=e.length;o!==u&&0===e[o];)o++,r++;for(var f=(u-o)*h+1>>>0,c=new Uint8Array(f);o!==u;){for(var l=e[o],d=0,p=f-1;(0!==l||d>>0,c[p]=l%a>>>0,l=l/a>>>0;if(0!==l)throw new Error("Non-zero carry");n=d,o++}for(var m=f-n;m!==f&&0===c[m];)m++;for(var g=s.repeat(r);m=55296&&e<=56319&&n=55296&&t<=57343)throw Error("Lone surrogate U+"+t.toString(16).toUpperCase()+" is not a scalar value")}function s(t,e){return n(t>>e&63|128)}function u(t){if(0==(4294967168&t))return n(t);var e="";return 0==(4294965248&t)?e=n(t>>6&31|192):0==(4294901760&t)?(a(t),e=n(t>>12&15|224),e+=s(t,6)):0==(4292870144&t)&&(e=n(t>>18&7|240),e+=s(t,12),e+=s(t,6)),e+=n(63&t|128)}function h(){if(i>=r)throw Error("Invalid byte index");var t=255&e[i];if(i++,128==(192&t))return 63&t;throw Error("Invalid continuation byte")}function f(){var t,n;if(i>r)throw Error("Invalid byte index");if(i==r)return!1;if(t=255&e[i],i++,0==(128&t))return t;if(192==(224&t)){if((n=(31&t)<<6|h())>=128)return n;throw Error("Invalid continuation byte")}if(224==(240&t)){if((n=(15&t)<<12|h()<<6|h())>=2048)return a(n),n;throw Error("Invalid continuation byte")}if(240==(248&t)&&(n=(7&t)<<18|h()<<12|h()<<6|h())>=65536&&n<=1114111)return n;throw Error("Invalid UTF-8 detected")}t.version="3.0.0",t.encode=function(t){for(var e=o(t),r=e.length,i=-1,n="";++i65535&&(o+=n((e-=65536)>>>10&1023|55296),e=56320|1023&e),o+=n(e);return o}(s)}}(e)},function(t,e,r){var i=r(156),n=r(69);t.exports=function(t){if("string"===typeof t||"number"===typeof t){var e=new i(1),r=String(t).toLowerCase().trim(),o="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),a=n(r);if("-"===a.substr(0,1)&&(a=n(a.slice(1)),e=new i(-1,10)),!(a=""===a?"0":a).match(/^-?[0-9]+$/)&&a.match(/^[0-9A-Fa-f]+$/)||a.match(/^[a-fA-F]+$/)||!0===o&&a.match(/^[0-9A-Fa-f]+$/))return new i(a,16).mul(e);if((a.match(/^-?[0-9]+$/)||""===a)&&!1===o)return new i(a,10).mul(e)}else if("object"===typeof t&&t.toString&&!t.pop&&!t.push&&t.toString(10).match(/^-?[0-9]+$/)&&(t.mul||t.dividedToIntegerBy))return new i(t.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(t)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(0).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):r.strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){t.exports=function(t){return null===t}},function(t,e,r){var i=r(70),n=r(163),o=r(72),a="[object String]";t.exports=function(t){return"string"==typeof t||!n(t)&&o(t)&&i(t)==a}},function(t,e,r){var i=r(160),n="object"==typeof self&&self&&self.Object===Object&&self,o=i||n||Function("return this")();t.exports=o},function(t,e,r){(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.exports=r}).call(this,r(10))},function(t,e,r){var i=r(71),n=Object.prototype,o=n.hasOwnProperty,a=n.toString,s=i?i.toStringTag:void 0;t.exports=function(t){var e=o.call(t,s),r=t[s];try{t[s]=void 0;var i=!0}catch(u){}var n=a.call(t);return i&&(e?t[s]=r:delete t[s]),n}},function(t,e){var r=Object.prototype.toString;t.exports=function(t){return r.call(t)}},function(t,e){var r=Array.isArray;t.exports=r},function(t,e,r){var i=r(70),n=r(72),o="[object Number]";t.exports=function(t){return"number"==typeof t||n(t)&&i(t)==o}},function(t,e,r){(function(t){var i=Object.getOwnPropertyDescriptors||function(t){for(var e=Object.keys(t),r={},i=0;i=o)return t;switch(t){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch(e){return"[Circular]"}default:return t}})),u=i[r];r=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),p(r)?i.showHidden=r:r&&e._extend(i,r),v(i.showHidden)&&(i.showHidden=!1),v(i.depth)&&(i.depth=2),v(i.colors)&&(i.colors=!1),v(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=u),f(i,t,i.depth)}function u(t,e){var r=s.styles[e];return r?"\x1b["+s.colors[r][0]+"m"+t+"\x1b["+s.colors[r][1]+"m":t}function h(t,e){return t}function f(t,r,i){if(t.customInspect&&r&&A(r.inspect)&&r.inspect!==e.inspect&&(!r.constructor||r.constructor.prototype!==r)){var n=r.inspect(i,t);return b(n)||(n=f(t,n,i)),n}var o=function(t,e){if(v(e))return t.stylize("undefined","undefined");if(b(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}if(g(e))return t.stylize(""+e,"number");if(p(e))return t.stylize(""+e,"boolean");if(m(e))return t.stylize("null","null")}(t,r);if(o)return o;var a=Object.keys(r),s=function(t){var e={};return t.forEach((function(t,r){e[t]=!0})),e}(a);if(t.showHidden&&(a=Object.getOwnPropertyNames(r)),M(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return c(r);if(0===a.length){if(A(r)){var u=r.name?": "+r.name:"";return t.stylize("[Function"+u+"]","special")}if(y(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(_(r))return t.stylize(Date.prototype.toString.call(r),"date");if(M(r))return c(r)}var h,w="",I=!1,S=["{","}"];(d(r)&&(I=!0,S=["[","]"]),A(r))&&(w=" [Function"+(r.name?": "+r.name:"")+"]");return y(r)&&(w=" "+RegExp.prototype.toString.call(r)),_(r)&&(w=" "+Date.prototype.toUTCString.call(r)),M(r)&&(w=" "+c(r)),0!==a.length||I&&0!=r.length?i<0?y(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),h=I?function(t,e,r,i,n){for(var o=[],a=0,s=e.length;a=0&&0,t+e.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return r[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+r[1];return r[0]+e+" "+t.join(", ")+" "+r[1]}(h,w,S)):S[0]+w+S[1]}function c(t){return"["+Error.prototype.toString.call(t)+"]"}function l(t,e,r,i,n,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(e,n)||{value:e[n]}).get?s=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(s=t.stylize("[Setter]","special")),x(i,n)||(a="["+n+"]"),s||(t.seen.indexOf(u.value)<0?(s=m(r)?f(t,u.value,null):f(t,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(t){return" "+t})).join("\n").substr(2):"\n"+s.split("\n").map((function(t){return" "+t})).join("\n")):s=t.stylize("[Circular]","special")),v(a)){if(o&&n.match(/^\d+$/))return s;(a=JSON.stringify(""+n)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=t.stylize(a,"string"))}return a+": "+s}function d(t){return Array.isArray(t)}function p(t){return"boolean"===typeof t}function m(t){return null===t}function g(t){return"number"===typeof t}function b(t){return"string"===typeof t}function v(t){return void 0===t}function y(t){return w(t)&&"[object RegExp]"===I(t)}function w(t){return"object"===typeof t&&null!==t}function _(t){return w(t)&&"[object Date]"===I(t)}function M(t){return w(t)&&("[object Error]"===I(t)||t instanceof Error)}function A(t){return"function"===typeof t}function I(t){return Object.prototype.toString.call(t)}function S(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(r){if(v(o)&&(o=Object({NODE_ENV:"production",PUBLIC_URL:"."}).NODE_DEBUG||""),r=r.toUpperCase(),!a[r])if(new RegExp("\\b"+r+"\\b","i").test(o)){var i=t.pid;a[r]=function(){var t=e.format.apply(e,arguments);console.error("%s %d: %s",r,i,t)}}else a[r]=function(){};return a[r]},e.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.isArray=d,e.isBoolean=p,e.isNull=m,e.isNullOrUndefined=function(t){return null==t},e.isNumber=g,e.isString=b,e.isSymbol=function(t){return"symbol"===typeof t},e.isUndefined=v,e.isRegExp=y,e.isObject=w,e.isDate=_,e.isError=M,e.isFunction=A,e.isPrimitive=function(t){return null===t||"boolean"===typeof t||"number"===typeof t||"string"===typeof t||"symbol"===typeof t||"undefined"===typeof t},e.isBuffer=r(166);var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function k(){var t=new Date,e=[S(t.getHours()),S(t.getMinutes()),S(t.getSeconds())].join(":");return[t.getDate(),E[t.getMonth()],e].join(" ")}function x(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){console.log("%s - %s",k(),e.format.apply(e,arguments))},e.inherits=r(167),e._extend=function(t,e){if(!e||!w(e))return t;for(var r=Object.keys(e),i=r.length;i--;)t[r[i]]=e[r[i]];return t};var B="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function C(t,e){if(!t){var r=new Error("Promise was rejected with a falsy value");r.reason=t,t=r}return e(t)}e.promisify=function(t){if("function"!==typeof t)throw new TypeError('The "original" argument must be of type Function');if(B&&t[B]){var e;if("function"!==typeof(e=t[B]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,B,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,r,i=new Promise((function(t,i){e=t,r=i})),n=[],o=0;o=0)return;a[e]="set-cookie"===e?(a[e]?a[e]:[]).concat([r]):a[e]?a[e]+", "+r:r}})),a):a}},function(t,e,r){"use strict";var i=r(11);t.exports=i.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function n(t){var i=t;return e&&(r.setAttribute("href",i),i=r.href),r.setAttribute("href",i),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return t=n(window.location.href),function(e){var r=i.isString(e)?n(e):e;return r.protocol===t.protocol&&r.host===t.host}}():function(){return!0}},function(t,e,r){"use strict";var i=r(11);t.exports=i.isStandardBrowserEnv()?{write:function(t,e,r,n,o,a){var s=[];s.push(t+"="+encodeURIComponent(e)),i.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),i.isString(n)&&s.push("path="+n),i.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(t,e,r){"use strict";t.exports=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}},function(t,e,r){"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},function(t,e,r){"use strict";var i=r(80);function n(t){if("function"!==typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var r=this;t((function(t){r.reason||(r.reason=new i(t),e(r.reason))}))}n.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},n.source=function(){var t;return{token:new n((function(e){t=e})),cancel:t}},t.exports=n},function(t,e,r){"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},function(t,e,r){var i;!function(n){"use strict";var o,a=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,s=Math.ceil,u=Math.floor,h="[BigNumber Error] ",f=h+"Number primitive has more than 15 significant digits: ",c=1e14,l=14,d=9007199254740991,p=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],m=1e7,g=1e9;function b(t){var e=0|t;return t>0||t===e?e:e-1}function v(t){for(var e,r,i=1,n=t.length,o=t[0]+"";ih^r?1:-1;for(s=(u=n.length)<(h=o.length)?u:h,a=0;ao[a]^r?1:-1;return u==h?0:u>h^r?1:-1}function w(t,e,r,i){if(tr||t!==u(t))throw Error(h+(i||"Argument")+("number"==typeof t?tr?" out of range: ":" not an integer: ":" not a primitive number: ")+String(t))}function _(t){var e=t.c.length-1;return b(t.e/l)==e&&t.c[e]%2!=0}function M(t,e){return(t.length>1?t.charAt(0)+"."+t.slice(1):t)+(e<0?"e":"e+")+e}function A(t,e,r){var i,n;if(e<0){for(n=r+".";++e;n+=r);t=n+t}else if(++e>(i=t.length)){for(n=r,e-=i;--e;n+=r);t+=n}else eC?b.c=b.e=null:t.e=10;c/=10,h++);return void(h>C?b.c=b.e=null:(b.e=h,b.c=[t]))}g=String(t)}else{if(!a.test(g=String(t)))return n(b,g,p);b.s=45==g.charCodeAt(0)?(g=g.slice(1),-1):1}(h=g.indexOf("."))>-1&&(g=g.replace(".","")),(c=g.search(/e/i))>0?(h<0&&(h=c),h+=+g.slice(c+1),g=g.substring(0,c)):h<0&&(h=g.length)}else{if(w(e,2,j.length,"Base"),10==e)return q(b=new D(t),S+b.e+1,E);if(g=String(t),p="number"==typeof t){if(0*t!=0)return n(b,g,p,e);if(b.s=1/t<0?(g=g.slice(1),-1):1,D.DEBUG&&g.replace(/^0\.0*|\./,"").length>15)throw Error(f+t)}else b.s=45===g.charCodeAt(0)?(g=g.slice(1),-1):1;for(r=j.slice(0,e),h=c=0,m=g.length;ch){h=m;continue}}else if(!s&&(g==g.toUpperCase()&&(g=g.toLowerCase())||g==g.toLowerCase()&&(g=g.toUpperCase()))){s=!0,c=-1,h=0;continue}return n(b,String(t),p,e)}p=!1,(h=(g=i(g,e,10,b.s)).indexOf("."))>-1?g=g.replace(".",""):h=g.length}for(c=0;48===g.charCodeAt(c);c++);for(m=g.length;48===g.charCodeAt(--m););if(g=g.slice(c,++m)){if(m-=c,p&&D.DEBUG&&m>15&&(t>d||t!==u(t)))throw Error(f+b.s*t);if((h=h-c-1)>C)b.c=b.e=null;else if(h=x)?M(u,a):A(u,a,"0");else if(o=(t=q(new D(t),e,r)).e,s=(u=v(t.c)).length,1==i||2==i&&(e<=o||o<=k)){for(;ss){if(--e>0)for(u+=".";e--;u+="0");}else if((e+=o-s)>0)for(o+1==s&&(u+=".");e--;u+="0");return t.s<0&&n?"-"+u:u}function z(t,e){for(var r,i=1,n=new D(t[0]);i=10;n/=10,i++);return(r=i+r*l-1)>C?t.c=t.e=null:r=10;h/=10,n++);if((o=e-n)<0)o+=l,a=e,m=(f=g[d=0])/b[n-a-1]%10|0;else if((d=s((o+1)/l))>=g.length){if(!i)break t;for(;g.length<=d;g.push(0));f=m=0,n=1,a=(o%=l)-l+1}else{for(f=h=g[d],n=1;h>=10;h/=10,n++);m=(a=(o%=l)-l+n)<0?0:f/b[n-a-1]%10|0}if(i=i||e<0||null!=g[d+1]||(a<0?f:f%b[n-a-1]),i=r<4?(m||i)&&(0==r||r==(t.s<0?3:2)):m>5||5==m&&(4==r||i||6==r&&(o>0?a>0?f/b[n-a]:0:g[d-1])%10&1||r==(t.s<0?8:7)),e<1||!g[0])return g.length=0,i?(e-=t.e+1,g[0]=b[(l-e%l)%l],t.e=-e||0):g[0]=t.e=0,t;if(0==o?(g.length=d,h=1,d--):(g.length=d+1,h=b[l-o],g[d]=a>0?u(f/b[n-a]%b[a])*h:0),i)for(;;){if(0==d){for(o=1,a=g[0];a>=10;a/=10,o++);for(a=g[0]+=h,h=1;a>=10;a/=10,h++);o!=h&&(t.e++,g[0]==c&&(g[0]=1));break}if(g[d]+=h,g[d]!=c)break;g[d--]=0,h=1}for(o=g.length;0===g[--o];g.pop());}t.e>C?t.c=t.e=null:t.e=x?M(e,r):A(e,r,"0"),t.s<0?"-"+e:e)}return D.clone=t,D.ROUND_UP=0,D.ROUND_DOWN=1,D.ROUND_CEIL=2,D.ROUND_FLOOR=3,D.ROUND_HALF_UP=4,D.ROUND_HALF_DOWN=5,D.ROUND_HALF_EVEN=6,D.ROUND_HALF_CEIL=7,D.ROUND_HALF_FLOOR=8,D.EUCLID=9,D.config=D.set=function(t){var e,r;if(null!=t){if("object"!=typeof t)throw Error(h+"Object expected: "+t);if(t.hasOwnProperty(e="DECIMAL_PLACES")&&(w(r=t[e],0,g,e),S=r),t.hasOwnProperty(e="ROUNDING_MODE")&&(w(r=t[e],0,8,e),E=r),t.hasOwnProperty(e="EXPONENTIAL_AT")&&((r=t[e])&&r.pop?(w(r[0],-g,0,e),w(r[1],0,g,e),k=r[0],x=r[1]):(w(r,-g,g,e),k=-(x=r<0?-r:r))),t.hasOwnProperty(e="RANGE"))if((r=t[e])&&r.pop)w(r[0],-g,-1,e),w(r[1],1,g,e),B=r[0],C=r[1];else{if(w(r,-g,g,e),!r)throw Error(h+e+" cannot be zero: "+r);B=-(C=r<0?-r:r)}if(t.hasOwnProperty(e="CRYPTO")){if((r=t[e])!==!!r)throw Error(h+e+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw T=!r,Error(h+"crypto unavailable");T=r}else T=r}if(t.hasOwnProperty(e="MODULO_MODE")&&(w(r=t[e],0,9,e),P=r),t.hasOwnProperty(e="POW_PRECISION")&&(w(r=t[e],0,g,e),R=r),t.hasOwnProperty(e="FORMAT")){if("object"!=typeof(r=t[e]))throw Error(h+e+" not an object: "+r);O=r}if(t.hasOwnProperty(e="ALPHABET")){if("string"!=typeof(r=t[e])||/^.$|[+-.\s]|(.).*\1/.test(r))throw Error(h+e+" invalid: "+r);j=r}}return{DECIMAL_PLACES:S,ROUNDING_MODE:E,EXPONENTIAL_AT:[k,x],RANGE:[B,C],CRYPTO:T,MODULO_MODE:P,POW_PRECISION:R,FORMAT:O,ALPHABET:j}},D.isBigNumber=function(t){if(!t||!0!==t._isBigNumber)return!1;if(!D.DEBUG)return!0;var e,r,i=t.c,n=t.e,o=t.s;t:if("[object Array]"=={}.toString.call(i)){if((1===o||-1===o)&&n>=-g&&n<=g&&n===u(n)){if(0===i[0]){if(0===n&&1===i.length)return!0;break t}if((e=(n+1)%l)<1&&(e+=l),String(i[0]).length==e){for(e=0;e=c||r!==u(r))break t;if(0!==r)return!0}}}else if(null===i&&null===n&&(null===o||1===o||-1===o))return!0;throw Error(h+"Invalid BigNumber: "+t)},D.maximum=D.max=function(){return z(arguments,o.lt)},D.minimum=D.min=function(){return z(arguments,o.gt)},D.random=function(){var t=9007199254740992*Math.random()&2097151?function(){return u(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(e){var r,i,n,o,a,f=0,c=[],d=new D(I);if(null==e?e=S:w(e,0,g),o=s(e/l),T)if(crypto.getRandomValues){for(r=crypto.getRandomValues(new Uint32Array(o*=2));f>>11))>=9e15?(i=crypto.getRandomValues(new Uint32Array(2)),r[f]=i[0],r[f+1]=i[1]):(c.push(a%1e14),f+=2);f=o/2}else{if(!crypto.randomBytes)throw T=!1,Error(h+"crypto unavailable");for(r=crypto.randomBytes(o*=7);f=9e15?crypto.randomBytes(7).copy(r,f):(c.push(a%1e14),f+=7);f=o/7}if(!T)for(;f=10;a/=10,f++);fr-1&&(null==a[n+1]&&(a[n+1]=0),a[n+1]+=a[n]/r|0,a[n]%=r)}return a.reverse()}return function(e,i,n,o,a){var s,u,h,f,c,l,d,p,m=e.indexOf("."),g=S,b=E;for(m>=0&&(f=R,R=0,e=e.replace(".",""),l=(p=new D(i)).pow(e.length-m),R=f,p.c=t(A(v(l.c),l.e,"0"),10,n,"0123456789"),p.e=p.c.length),h=f=(d=t(e,i,n,a?(s=j,"0123456789"):(s="0123456789",j))).length;0==d[--f];d.pop());if(!d[0])return s.charAt(0);if(m<0?--h:(l.c=d,l.e=h,l.s=o,d=(l=r(l,p,g,b,n)).c,c=l.r,h=l.e),m=d[u=h+g+1],f=n/2,c=c||u<0||null!=d[u+1],c=b<4?(null!=m||c)&&(0==b||b==(l.s<0?3:2)):m>f||m==f&&(4==b||c||6==b&&1&d[u-1]||b==(l.s<0?8:7)),u<1||!d[0])e=c?A(s.charAt(1),-g,s.charAt(0)):s.charAt(0);else{if(d.length=u,c)for(--n;++d[--u]>n;)d[u]=0,u||(++h,d=[1].concat(d));for(f=d.length;!d[--f];);for(m=0,e="";m<=f;e+=s.charAt(d[m++]));e=A(e,h,s.charAt(0))}return e}}(),r=function(){function t(t,e,r){var i,n,o,a,s=0,u=t.length,h=e%m,f=e/m|0;for(t=t.slice();u--;)s=((n=h*(o=t[u]%m)+(i=f*o+(a=t[u]/m|0)*h)%m*m+s)/r|0)+(i/m|0)+f*a,t[u]=n%r;return s&&(t=[s].concat(t)),t}function e(t,e,r,i){var n,o;if(r!=i)o=r>i?1:-1;else for(n=o=0;ne[n]?1:-1;break}return o}function r(t,e,r,i){for(var n=0;r--;)t[r]-=n,n=t[r]1;t.splice(0,1));}return function(i,n,o,a,s){var h,f,d,p,m,g,v,y,w,_,M,A,I,S,E,k,x,B=i.s==n.s?1:-1,C=i.c,T=n.c;if(!C||!C[0]||!T||!T[0])return new D(i.s&&n.s&&(C?!T||C[0]!=T[0]:T)?C&&0==C[0]||!T?0*B:B/0:NaN);for(w=(y=new D(B)).c=[],B=o+(f=i.e-n.e)+1,s||(s=c,f=b(i.e/l)-b(n.e/l),B=B/l|0),d=0;T[d]==(C[d]||0);d++);if(T[d]>(C[d]||0)&&f--,B<0)w.push(1),p=!0;else{for(S=C.length,k=T.length,d=0,B+=2,(m=u(s/(T[0]+1)))>1&&(T=t(T,m,s),C=t(C,m,s),k=T.length,S=C.length),I=k,M=(_=C.slice(0,k)).length;M=s/2&&E++;do{if(m=0,(h=e(T,_,k,M))<0){if(A=_[0],k!=M&&(A=A*s+(_[1]||0)),(m=u(A/E))>1)for(m>=s&&(m=s-1),v=(g=t(T,m,s)).length,M=_.length;1==e(g,_,v,M);)m--,r(g,k=10;B/=10,d++);q(y,o+(y.e=d+f*l-1)+1,a,p)}else y.e=f,y.r=+p;return y}}(),n=function(){var t=/^(-?)0([xbo])(?=\w[\w.]*$)/i,e=/^([^.]+)\.$/,r=/^\.([^.]+)$/,i=/^-?(Infinity|NaN)$/,n=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(o,a,s,u){var f,c=s?a:a.replace(n,"");if(i.test(c))o.s=isNaN(c)?null:c<0?-1:1;else{if(!s&&(c=c.replace(t,(function(t,e,r){return f="x"==(r=r.toLowerCase())?16:"b"==r?2:8,u&&u!=f?t:e})),u&&(f=u,c=c.replace(e,"$1").replace(r,"0.$1")),a!=c))return new D(c,f);if(D.DEBUG)throw Error(h+"Not a"+(u?" base "+u:"")+" number: "+a);o.s=null}o.c=o.e=null}}(),o.absoluteValue=o.abs=function(){var t=new D(this);return t.s<0&&(t.s=1),t},o.comparedTo=function(t,e){return y(this,new D(t,e))},o.decimalPlaces=o.dp=function(t,e){var r,i,n,o=this;if(null!=t)return w(t,0,g),null==e?e=E:w(e,0,8),q(new D(o),t+o.e+1,e);if(!(r=o.c))return null;if(i=((n=r.length-1)-b(this.e/l))*l,n=r[n])for(;n%10==0;n/=10,i--);return i<0&&(i=0),i},o.dividedBy=o.div=function(t,e){return r(this,new D(t,e),S,E)},o.dividedToIntegerBy=o.idiv=function(t,e){return r(this,new D(t,e),0,1)},o.exponentiatedBy=o.pow=function(t,e){var r,i,n,o,a,f,c,d,p=this;if((t=new D(t)).c&&!t.isInteger())throw Error(h+"Exponent not an integer: "+U(t));if(null!=e&&(e=new D(e)),a=t.e>14,!p.c||!p.c[0]||1==p.c[0]&&!p.e&&1==p.c.length||!t.c||!t.c[0])return d=new D(Math.pow(+U(p),a?2-_(t):+U(t))),e?d.mod(e):d;if(f=t.s<0,e){if(e.c?!e.c[0]:!e.s)return new D(NaN);(i=!f&&p.isInteger()&&e.isInteger())&&(p=p.mod(e))}else{if(t.e>9&&(p.e>0||p.e<-1||(0==p.e?p.c[0]>1||a&&p.c[1]>=24e7:p.c[0]<8e13||a&&p.c[0]<=9999975e7)))return o=p.s<0&&_(t)?-0:0,p.e>-1&&(o=1/o),new D(f?1/o:o);R&&(o=s(R/l+2))}for(a?(r=new D(.5),f&&(t.s=1),c=_(t)):c=(n=Math.abs(+U(t)))%2,d=new D(I);;){if(c){if(!(d=d.times(p)).c)break;o?d.c.length>o&&(d.c.length=o):i&&(d=d.mod(e))}if(n){if(0===(n=u(n/2)))break;c=n%2}else if(q(t=t.times(r),t.e+1,1),t.e>14)c=_(t);else{if(0===(n=+U(t)))break;c=n%2}p=p.times(p),o?p.c&&p.c.length>o&&(p.c.length=o):i&&(p=p.mod(e))}return i?d:(f&&(d=I.div(d)),e?d.mod(e):o?q(d,R,E,void 0):d)},o.integerValue=function(t){var e=new D(this);return null==t?t=E:w(t,0,8),q(e,e.e+1,t)},o.isEqualTo=o.eq=function(t,e){return 0===y(this,new D(t,e))},o.isFinite=function(){return!!this.c},o.isGreaterThan=o.gt=function(t,e){return y(this,new D(t,e))>0},o.isGreaterThanOrEqualTo=o.gte=function(t,e){return 1===(e=y(this,new D(t,e)))||0===e},o.isInteger=function(){return!!this.c&&b(this.e/l)>this.c.length-2},o.isLessThan=o.lt=function(t,e){return y(this,new D(t,e))<0},o.isLessThanOrEqualTo=o.lte=function(t,e){return-1===(e=y(this,new D(t,e)))||0===e},o.isNaN=function(){return!this.s},o.isNegative=function(){return this.s<0},o.isPositive=function(){return this.s>0},o.isZero=function(){return!!this.c&&0==this.c[0]},o.minus=function(t,e){var r,i,n,o,a=this,s=a.s;if(e=(t=new D(t,e)).s,!s||!e)return new D(NaN);if(s!=e)return t.s=-e,a.plus(t);var u=a.e/l,h=t.e/l,f=a.c,d=t.c;if(!u||!h){if(!f||!d)return f?(t.s=-e,t):new D(d?a:NaN);if(!f[0]||!d[0])return d[0]?(t.s=-e,t):new D(f[0]?a:3==E?-0:0)}if(u=b(u),h=b(h),f=f.slice(),s=u-h){for((o=s<0)?(s=-s,n=f):(h=u,n=d),n.reverse(),e=s;e--;n.push(0));n.reverse()}else for(i=(o=(s=f.length)<(e=d.length))?s:e,s=e=0;e0)for(;e--;f[r++]=0);for(e=c-1;i>s;){if(f[--i]=0;){for(r=0,p=A[n]%w,g=A[n]/w|0,o=n+(a=u);o>n;)r=((h=p*(h=M[--a]%w)+(s=g*h+(f=M[a]/w|0)*p)%w*w+v[o]+r)/y|0)+(s/w|0)+g*f,v[o--]=h%y;v[o]=r}return r?++i:v.splice(0,1),K(t,v,i)},o.negated=function(){var t=new D(this);return t.s=-t.s||null,t},o.plus=function(t,e){var r,i=this,n=i.s;if(e=(t=new D(t,e)).s,!n||!e)return new D(NaN);if(n!=e)return t.s=-e,i.minus(t);var o=i.e/l,a=t.e/l,s=i.c,u=t.c;if(!o||!a){if(!s||!u)return new D(n/0);if(!s[0]||!u[0])return u[0]?t:new D(s[0]?i:0*n)}if(o=b(o),a=b(a),s=s.slice(),n=o-a){for(n>0?(a=o,r=u):(n=-n,r=s),r.reverse();n--;r.push(0));r.reverse()}for((n=s.length)-(e=u.length)<0&&(r=u,u=s,s=r,e=n),n=0;e;)n=(s[--e]=s[e]+u[e]+n)/c|0,s[e]=c===s[e]?0:s[e]%c;return n&&(s=[n].concat(s),++a),K(t,s,a)},o.precision=o.sd=function(t,e){var r,i,n,o=this;if(null!=t&&t!==!!t)return w(t,1,g),null==e?e=E:w(e,0,8),q(new D(o),t,e);if(!(r=o.c))return null;if(i=(n=r.length-1)*l+1,n=r[n]){for(;n%10==0;n/=10,i--);for(n=r[0];n>=10;n/=10,i++);}return t&&o.e+1>i&&(i=o.e+1),i},o.shiftedBy=function(t){return w(t,-d,d),this.times("1e"+t)},o.squareRoot=o.sqrt=function(){var t,e,i,n,o,a=this,s=a.c,u=a.s,h=a.e,f=S+4,c=new D("0.5");if(1!==u||!s||!s[0])return new D(!u||u<0&&(!s||s[0])?NaN:s?a:1/0);if(0==(u=Math.sqrt(+U(a)))||u==1/0?(((e=v(s)).length+h)%2==0&&(e+="0"),u=Math.sqrt(+e),h=b((h+1)/2)-(h<0||h%2),i=new D(e=u==1/0?"1e"+h:(e=u.toExponential()).slice(0,e.indexOf("e")+1)+h)):i=new D(u+""),i.c[0])for((u=(h=i.e)+f)<3&&(u=0);;)if(o=i,i=c.times(o.plus(r(a,o,f,1))),v(o.c).slice(0,u)===(e=v(i.c)).slice(0,u)){if(i.e0&&m>0){for(o=m%s||s,c=p.substr(0,o);o0&&(c+=f+p.slice(o)),d&&(c="-"+c)}i=l?c+(r.decimalSeparator||"")+((u=+r.fractionGroupSize)?l.replace(new RegExp("\\d{"+u+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):l):c}return(r.prefix||"")+i+(r.suffix||"")},o.toFraction=function(t){var e,i,n,o,a,s,u,f,c,d,m,g,b=this,y=b.c;if(null!=t&&(!(u=new D(t)).isInteger()&&(u.c||1!==u.s)||u.lt(I)))throw Error(h+"Argument "+(u.isInteger()?"out of range: ":"not an integer: ")+U(u));if(!y)return new D(b);for(e=new D(I),c=i=new D(I),n=f=new D(I),g=v(y),a=e.e=g.length-b.e-1,e.c[0]=p[(s=a%l)<0?l+s:s],t=!t||u.comparedTo(e)>0?a>0?e:c:u,s=C,C=1/0,u=new D(g),f.c[0]=0;d=r(u,e,0,1),1!=(o=i.plus(d.times(n))).comparedTo(t);)i=n,n=o,c=f.plus(d.times(o=c)),f=o,e=u.minus(d.times(o=e)),u=o;return o=r(t.minus(i),n,0,1),f=f.plus(o.times(c)),i=i.plus(o.times(n)),f.s=c.s=b.s,m=r(c,n,a*=2,E).minus(b).abs().comparedTo(r(f,i,a,E).minus(b).abs())<1?[c,n]:[f,i],C=s,m},o.toNumber=function(){return+U(this)},o.toPrecision=function(t,e){return null!=t&&w(t,1,g),N(this,t,e,2)},o.toString=function(t){var e,r=this,n=r.s,o=r.e;return null===o?n?(e="Infinity",n<0&&(e="-"+e)):e="NaN":(null==t?e=o<=k||o>=x?M(v(r.c),o):A(v(r.c),o,"0"):10===t?e=A(v((r=q(new D(r),S+o+1,E)).c),r.e,"0"):(w(t,2,j.length,"Base"),e=i(A(v(r.c),o,"0"),10,t,n,!0)),n<0&&r.c[0]&&(e="-"+e)),e},o.valueOf=o.toJSON=function(){return U(this)},o._isBigNumber=!0,null!=e&&D.set(e),D}()).default=o.BigNumber=o,void 0===(i=function(){return o}.call(e,r,e,t))||(t.exports=i)}()},function(t,e,r){"use strict";var i=r(81).decOut,n=r(123),o=r(3),a=r(3),s=a.hexToCy,u=a.isNewVersion,h=r(45),f=r(143),c=f.genTxParam,l=f.signTx,d=r(324),p=d.Asset,m=d.Token,g=d.Witness,b=d.ZPkg,v=r(144),y=v.selectUtxos,w=v.buildTxParam,_=v.PreTxParam,M=v.utxo,A=r(123),I=A.createPkrHash,S=A.createOldPkrHash,E={account:h,Wallet:n,decOut:i,genSeed:A.genSeed,createPkrHash:I,createOldPkrHash:S,selectUtxos:y,buildTxParam:w,entropyToMnemonic:A.entropyToMnemonic,PreTxParam:_,utxo:M,genTxParam:c,signTx:l,Asset:p,Token:m,Witness:g,ZPkg:b,hexToCy:s,isNewVersion:u,utils:o};t.exports=E},function(t,e){},function(t,e,r){"use strict";var i=r(2).Buffer,n=r(189);t.exports=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}return t.prototype.push=function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length},t.prototype.unshift=function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},t.prototype.shift=function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.prototype.clear=function(){this.head=this.tail=null,this.length=0},t.prototype.join=function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r},t.prototype.concat=function(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var e,r,n,o=i.allocUnsafe(t>>>0),a=this.head,s=0;a;)e=a.data,r=o,n=s,e.copy(r,n),s+=a.data.length,a=a.next;return o},t}(),n&&n.inspect&&n.inspect.custom&&(t.exports.prototype[n.inspect.custom]=function(){var t=n.inspect({length:this.length});return this.constructor.name+" "+t})},function(t,e){},function(t,e,r){(function(t){var i="undefined"!==typeof t&&t||"undefined"!==typeof self&&self||window,n=Function.prototype.apply;function o(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new o(n.call(setTimeout,i,arguments),clearTimeout)},e.setInterval=function(){return new o(n.call(setInterval,i,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(i,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},r(191),e.setImmediate="undefined"!==typeof self&&self.setImmediate||"undefined"!==typeof t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!==typeof self&&self.clearImmediate||"undefined"!==typeof t&&t.clearImmediate||this&&this.clearImmediate}).call(this,r(10))},function(t,e,r){(function(t,e){!function(t,r){"use strict";if(!t.setImmediate){var i,n=1,o={},a=!1,s=t.document,u=Object.getPrototypeOf&&Object.getPrototypeOf(t);u=u&&u.setTimeout?u:t,"[object process]"==={}.toString.call(t.process)?i=function(t){e.nextTick((function(){f(t)}))}:function(){if(t.postMessage&&!t.importScripts){var e=!0,r=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=r,e}}()?function(){var e="setImmediate$"+Math.random()+"$",r=function(r){r.source===t&&"string"===typeof r.data&&0===r.data.indexOf(e)&&f(+r.data.slice(e.length))};t.addEventListener?t.addEventListener("message",r,!1):t.attachEvent("onmessage",r),i=function(r){t.postMessage(e+r,"*")}}():t.MessageChannel?function(){var t=new MessageChannel;t.port1.onmessage=function(t){f(t.data)},i=function(e){t.port2.postMessage(e)}}():s&&"onreadystatechange"in s.createElement("script")?function(){var t=s.documentElement;i=function(e){var r=s.createElement("script");r.onreadystatechange=function(){f(e),r.onreadystatechange=null,t.removeChild(r),r=null},t.appendChild(r)}}():i=function(t){setTimeout(f,0,t)},u.setImmediate=function(t){"function"!==typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),r=0;r>>2}function f(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,c=0;c<16;++c)r[c]=t.readInt32BE(4*c);for(;c<80;++c)r[c]=r[c-3]^r[c-8]^r[c-14]^r[c-16];for(var l=0;l<80;++l){var d=~~(l/20),p=0|((e=i)<<5|e>>>27)+f(d,n,o,s)+u+r[l]+a[d];u=s,s=o,o=h(n),n=i,i=p}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(1),n=r(24),o=r(2).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<5|t>>>27}function f(t){return t<<30|t>>>2}function c(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,l=0;l<16;++l)r[l]=t.readInt32BE(4*l);for(;l<80;++l)r[l]=(e=r[l-3]^r[l-8]^r[l-14]^r[l-16])<<1|e>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=h(i)+c(p,n,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=f(n),n=i,i=m}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(1),n=r(87),o=r(24),a=r(2).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}i(u,n),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 t=a.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t},t.exports=u},function(t,e,r){var i=r(1),n=r(88),o=r(24),a=r(2).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}i(u,n),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 t=a.allocUnsafe(48);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){"use strict";var i=r(1),n=r(2).Buffer,o=r(16),a=n.alloc(128),s=64;function u(t,e){o.call(this,"digest"),"string"===typeof e&&(e=n.from(e)),this._alg=t,this._key=e,e.length>s?e=t(e):e.length>>0},e.writeUInt32BE=function(t,e,r){t[0+r]=e>>>24,t[1+r]=e>>>16&255,t[2+r]=e>>>8&255,t[3+r]=255&e},e.ip=function(t,e,r,i){for(var n=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)n<<=1,n|=e>>>s+a&1;for(s=0;s<=24;s+=8)n<<=1,n|=t>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1}r[i+0]=n>>>0,r[i+1]=o>>>0},e.rip=function(t,e,r,i){for(var n=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)n<<=1,n|=e>>>s+a&1,n<<=1,n|=t>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=e>>>s+a&1,o<<=1,o|=t>>>s+a&1;r[i+0]=n>>>0,r[i+1]=o>>>0},e.pc1=function(t,e,r,i){for(var n=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)n<<=1,n|=e>>s+a&1;for(s=0;s<=24;s+=8)n<<=1,n|=t>>s+a&1}for(s=0;s<=24;s+=8)n<<=1,n|=e>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;r[i+0]=n>>>0,r[i+1]=o>>>0},e.r28shl=function(t,e){return t<>>28-e};var i=[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];e.pc2=function(t,e,r,n){for(var o=0,a=0,s=i.length>>>1,u=0;u>>i[u]&1;for(u=s;u>>i[u]&1;r[n+0]=o>>>0,r[n+1]=a>>>0},e.expand=function(t,e,r){var i=0,n=0;i=(1&t)<<5|t>>>27;for(var o=23;o>=15;o-=4)i<<=6,i|=t>>>o&63;for(o=11;o>=3;o-=4)n|=t>>>o&63,n<<=6;n|=(31&t)<<1|t>>>31,e[r+0]=i>>>0,e[r+1]=n>>>0};var n=[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];e.substitute=function(t,e){for(var r=0,i=0;i<4;i++){r<<=4,r|=n[64*i+(t>>>18-6*i&63)]}for(i=0;i<4;i++){r<<=4,r|=n[256+64*i+(e>>>18-6*i&63)]}return r>>>0};var o=[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];e.permute=function(t){for(var e=0,r=0;r>>o[r]&1;return e>>>0},e.padSplit=function(t,e,r){for(var i=t.toString(2);i.length0;i--)e+=this._buffer(t,e),r+=this._flushBuffer(n,r);return e+=this._buffer(t,e),n},n.prototype.final=function(t){var e,r;return t&&(e=this.update(t)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),e?e.concat(r):r},n.prototype._pad=function(t,e){if(0===e)return!1;for(;e>>1];r=a.r28shl(r,s),n=a.r28shl(n,s),a.pc2(r,n,t.keys,o)}},h.prototype._update=function(t,e,r,i){var n=this._desState,o=a.readUInt32BE(t,e),s=a.readUInt32BE(t,e+4);a.ip(o,s,n.tmp,0),o=n.tmp[0],s=n.tmp[1],"encrypt"===this.type?this._encrypt(n,o,s,n.tmp,0):this._decrypt(n,o,s,n.tmp,0),o=n.tmp[0],s=n.tmp[1],a.writeUInt32BE(r,o,i),a.writeUInt32BE(r,s,i+4)},h.prototype._pad=function(t,e){for(var r=t.length-e,i=e;i>>0,o=l}a.rip(s,o,i,n)},h.prototype._decrypt=function(t,e,r,i,n){for(var o=r,s=e,u=t.keys.length-2;u>=0;u-=2){var h=t.keys[u],f=t.keys[u+1];a.expand(o,t.tmp,0),h^=t.tmp[0],f^=t.tmp[1];var c=a.substitute(h,f),l=o;o=(s^a.permute(c))>>>0,s=l}a.rip(o,s,i,n)}},function(t,e,r){"use strict";var i=r(13),n=r(1),o={};function a(t){i.equal(t.length,8,"Invalid IV length"),this.iv=new Array(8);for(var e=0;e15){var t=this.cache.slice(0,16);return this.cache=this.cache.slice(16),t}return null},l.prototype.flush=function(){for(var t=16-this.cache.length,e=o.allocUnsafe(t),r=-1;++r>a%8,t._prev=o(t._prev,r?i:n);return s}function o(t,e){var r=t.length,n=-1,o=i.allocUnsafe(t.length);for(t=i.concat([t,i.from([e])]);++n>7;return o}e.encrypt=function(t,e,r){for(var o=e.length,a=i.allocUnsafe(o),s=-1;++s>>0,0),e.writeUInt32BE(t[1]>>>0,4),e.writeUInt32BE(t[2]>>>0,8),e.writeUInt32BE(t[3]>>>0,12),e}function a(t){this.h=t,this.state=i.alloc(16,0),this.cache=i.allocUnsafe(0)}a.prototype.ghash=function(t){for(var e=-1;++e0;e--)i[e]=i[e]>>>1|(1&i[e-1])<<31;i[0]=i[0]>>>1,r&&(i[0]=i[0]^225<<24)}this.state=o(n)},a.prototype.update=function(t){var e;for(this.cache=i.concat([this.cache,t]);this.cache.length>=16;)e=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(e)},a.prototype.final=function(t,e){return this.cache.length&&this.ghash(i.concat([this.cache,n],16)),this.ghash(o([0,t,0,e])),this.state},t.exports=a},function(t,e,r){var i=r(99),n=r(2).Buffer,o=r(56),a=r(100),s=r(16),u=r(39),h=r(40);function f(t,e,r){s.call(this),this._cache=new c,this._last=void 0,this._cipher=new u.AES(e),this._prev=n.from(r),this._mode=t,this._autopadding=!0}function c(){this.cache=n.allocUnsafe(0)}function l(t,e,r){var s=o[t.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"===typeof r&&(r=n.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"===typeof e&&(e=n.from(e)),e.length!==s.key/8)throw new TypeError("invalid key length "+e.length);return"stream"===s.type?new a(s.module,e,r,!0):"auth"===s.type?new i(s.module,e,r,!0):new f(s.module,e,r)}r(1)(f,s),f.prototype._update=function(t){var e,r;this._cache.add(t);for(var i=[];e=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,e),i.push(r);return n.concat(i)},f.prototype._final=function(){var t=this._cache.flush();if(this._autopadding)return function(t){var e=t[15];if(e<1||e>16)throw new Error("unable to decrypt data");var r=-1;for(;++r16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e}else if(this.cache.length>=16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e;return null},c.prototype.flush=function(){if(this.cache.length)return this.cache},e.createDecipher=function(t,e){var r=o[t.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var i=h(e,!1,r.key,r.iv);return l(t,i.key,i.iv)},e.createDecipheriv=l},function(t,e){e["des-ecb"]={key:8,iv:0},e["des-cbc"]=e.des={key:8,iv:8},e["des-ede3-cbc"]=e.des3={key:24,iv:8},e["des-ede3"]={key:24,iv:0},e["des-ede-cbc"]={key:16,iv:8},e["des-ede"]={key:16,iv:0}},function(t,e,r){(function(t){var i=r(101),n=r(226),o=r(227);var a={binary:!0,hex:!0,base64:!0};e.DiffieHellmanGroup=e.createDiffieHellmanGroup=e.getDiffieHellman=function(e){var r=new t(n[e].prime,"hex"),i=new t(n[e].gen,"hex");return new o(r,i)},e.createDiffieHellman=e.DiffieHellman=function e(r,n,s,u){return t.isBuffer(n)||void 0===a[n]?e(r,"binary",n,s):(n=n||"binary",u=u||"binary",s=s||new t([2]),t.isBuffer(s)||(s=new t(s,u)),"number"===typeof r?new o(i(r,s),s,!0):(t.isBuffer(r)||(r=new t(r,n)),new o(r,s,!0)))}}).call(this,r(0).Buffer)},function(t,e){},function(t,e){},function(t){t.exports=JSON.parse('{"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"}}')},function(t,e,r){(function(e){var i=r(5),n=new(r(102)),o=new i(24),a=new i(11),s=new i(10),u=new i(3),h=new i(7),f=r(101),c=r(21);function l(t,r){return r=r||"utf8",e.isBuffer(t)||(t=new e(t,r)),this._pub=new i(t),this}function d(t,r){return r=r||"utf8",e.isBuffer(t)||(t=new e(t,r)),this._priv=new i(t),this}t.exports=m;var p={};function m(t,e,r){this.setGenerator(e),this.__prime=new i(t),this._prime=i.mont(this.__prime),this._primeLen=t.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=l,this.setPrivateKey=d):this._primeCode=8}function g(t,r){var i=new e(t.toArray());return r?i.toString(r):i}Object.defineProperty(m.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!==typeof this._primeCode&&(this._primeCode=function(t,e){var r=e.toString("hex"),i=[r,t.toString(16)].join("_");if(i in p)return p[i];var c,l=0;if(t.isEven()||!f.simpleSieve||!f.fermatTest(t)||!n.test(t))return l+=1,l+="02"===r||"05"===r?8:4,p[i]=l,l;switch(n.test(t.shrn(1))||(l+=2),r){case"02":t.mod(o).cmp(a)&&(l+=8);break;case"05":(c=t.mod(s)).cmp(u)&&c.cmp(h)&&(l+=8);break;default:l+=4}return p[i]=l,l}(this.__prime,this.__gen)),this._primeCode}}),m.prototype.generateKeys=function(){return this._priv||(this._priv=new i(c(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},m.prototype.computeSecret=function(t){var r=(t=(t=new i(t)).toRed(this._prime)).redPow(this._priv).fromRed(),n=new e(r.toArray()),o=this.getPrime();if(n.length0&&r.ishrn(i),r}function c(t,r,n){var o,a;do{for(o=new e(0);8*o.length=0&&(a=e,s=r),i.negative&&(i=i.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:i,b:o},{a:a,b:s}]},u.prototype._endoSplit=function(t){var e=this.endo.basis,r=e[0],i=e[1],n=i.b.mul(t).divRound(this.n),o=r.b.neg().mul(t).divRound(this.n),a=n.mul(r.a),s=o.mul(i.a),u=n.mul(r.b),h=o.mul(i.b);return{k1:t.sub(a).sub(s),k2:u.add(h).neg()}},u.prototype.pointFromX=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr().redMul(t).redIAdd(t.redMul(this.a)).redIAdd(this.b),i=r.redSqrt();if(0!==i.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=i.fromRed().isOdd();return(e&&!o||!e&&o)&&(i=i.redNeg()),this.point(t,i)},u.prototype.validate=function(t){if(t.inf)return!0;var e=t.x,r=t.y,i=this.a.redMul(e),n=e.redSqr().redMul(e).redIAdd(i).redIAdd(this.b);return 0===r.redSqr().redISub(n).cmpn(0)},u.prototype._endoWnafMulAdd=function(t,e,r){for(var i=this._endoWnafT1,n=this._endoWnafT2,o=0;o":""},h.prototype.isInfinity=function(){return this.inf},h.prototype.add=function(t){if(this.inf)return t;if(t.inf)return this;if(this.eq(t))return this.dbl();if(this.neg().eq(t))return this.curve.point(null,null);if(0===this.x.cmp(t.x))return this.curve.point(null,null);var e=this.y.redSub(t.y);0!==e.cmpn(0)&&(e=e.redMul(this.x.redSub(t.x).redInvm()));var r=e.redSqr().redISub(this.x).redISub(t.x),i=e.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,i)},h.prototype.dbl=function(){if(this.inf)return this;var t=this.y.redAdd(this.y);if(0===t.cmpn(0))return this.curve.point(null,null);var e=this.curve.a,r=this.x.redSqr(),i=t.redInvm(),n=r.redAdd(r).redIAdd(r).redIAdd(e).redMul(i),o=n.redSqr().redISub(this.x.redAdd(this.x)),a=n.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},h.prototype.getX=function(){return this.x.fromRed()},h.prototype.getY=function(){return this.y.fromRed()},h.prototype.mul=function(t){return t=new n(t,16),this.isInfinity()?this:this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve.endo?this.curve._endoWnafMulAdd([this],[t]):this.curve._wnafMul(this,t)},h.prototype.mulAdd=function(t,e,r){var i=[this,e],n=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n):this.curve._wnafMulAdd(1,i,n,2)},h.prototype.jmulAdd=function(t,e,r){var i=[this,e],n=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n,!0):this.curve._wnafMulAdd(1,i,n,2,!0)},h.prototype.eq=function(t){return this===t||this.inf===t.inf&&(this.inf||0===this.x.cmp(t.x)&&0===this.y.cmp(t.y))},h.prototype.neg=function(t){if(this.inf)return this;var e=this.curve.point(this.x,this.y.redNeg());if(t&&this.precomputed){var r=this.precomputed,i=function(t){return t.neg()};e.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(i)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(i)}}}return e},h.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(f,a.BasePoint),u.prototype.jpoint=function(t,e,r){return new f(this,t,e,r)},f.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var t=this.z.redInvm(),e=t.redSqr(),r=this.x.redMul(e),i=this.y.redMul(e).redMul(t);return this.curve.point(r,i)},f.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},f.prototype.add=function(t){if(this.isInfinity())return t;if(t.isInfinity())return this;var e=t.z.redSqr(),r=this.z.redSqr(),i=this.x.redMul(e),n=t.x.redMul(r),o=this.y.redMul(e.redMul(t.z)),a=t.y.redMul(r.redMul(this.z)),s=i.redSub(n),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var h=s.redSqr(),f=h.redMul(s),c=i.redMul(h),l=u.redSqr().redIAdd(f).redISub(c).redISub(c),d=u.redMul(c.redISub(l)).redISub(o.redMul(f)),p=this.z.redMul(t.z).redMul(s);return this.curve.jpoint(l,d,p)},f.prototype.mixedAdd=function(t){if(this.isInfinity())return t.toJ();if(t.isInfinity())return this;var e=this.z.redSqr(),r=this.x,i=t.x.redMul(e),n=this.y,o=t.y.redMul(e).redMul(this.z),a=r.redSub(i),s=n.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),h=u.redMul(a),f=r.redMul(u),c=s.redSqr().redIAdd(h).redISub(f).redISub(f),l=s.redMul(f.redISub(c)).redISub(n.redMul(h)),d=this.z.redMul(a);return this.curve.jpoint(c,l,d)},f.prototype.dblp=function(t){if(0===t)return this;if(this.isInfinity())return this;if(!t)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var e=this,r=0;r=0)return!1;if(r.redIAdd(n),0===this.x.cmp(r))return!0}},f.prototype.inspect=function(){return this.isInfinity()?"":""},f.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},function(t,e,r){"use strict";var i=r(5),n=r(1),o=r(41),a=r(14);function s(t){o.call(this,"mont",t),this.a=new i(t.a,16).toRed(this.red),this.b=new i(t.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 u(t,e,r){o.BasePoint.call(this,t,"projective"),null===e&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new i(e,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)))}n(s,o),t.exports=s,s.prototype.validate=function(t){var e=t.normalize().x,r=e.redSqr(),i=r.redMul(e).redAdd(r.redMul(this.a)).redAdd(e);return 0===i.redSqrt().redSqr().cmp(i)},n(u,o.BasePoint),s.prototype.decodePoint=function(t,e){return this.point(a.toArray(t,e),1)},s.prototype.point=function(t,e){return new u(this,t,e)},s.prototype.pointFromJSON=function(t){return u.fromJSON(this,t)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(t,e){return new u(t,e[0],e[1]||t.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var t=this.x.redAdd(this.z).redSqr(),e=this.x.redSub(this.z).redSqr(),r=t.redSub(e),i=t.redMul(e),n=r.redMul(e.redAdd(this.curve.a24.redMul(r)));return this.curve.point(i,n)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(t,e){var r=this.x.redAdd(this.z),i=this.x.redSub(this.z),n=t.x.redAdd(t.z),o=t.x.redSub(t.z).redMul(r),a=n.redMul(i),s=e.z.redMul(o.redAdd(a).redSqr()),u=e.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(t){for(var e=t.clone(),r=this,i=this.curve.point(null,null),n=[];0!==e.cmpn(0);e.iushrn(1))n.push(e.andln(1));for(var o=n.length-1;o>=0;o--)0===n[o]?(r=r.diffAdd(i,this),i=i.dbl()):(i=r.diffAdd(i,this),r=r.dbl());return i},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(t){return 0===this.getX().cmp(t.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},function(t,e,r){"use strict";var i=r(14),n=r(5),o=r(1),a=r(41),s=i.assert;function u(t){this.twisted=1!==(0|t.a),this.mOneA=this.twisted&&-1===(0|t.a),this.extended=this.mOneA,a.call(this,"edwards",t),this.a=new n(t.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new n(t.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new n(t.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1===(0|t.c)}function h(t,e,r,i,o){a.BasePoint.call(this,t,"projective"),null===e&&null===r&&null===i?(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 n(e,16),this.y=new n(r,16),this.z=i?new n(i,16):this.curve.one,this.t=o&&new n(o,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(u,a),t.exports=u,u.prototype._mulA=function(t){return this.mOneA?t.redNeg():this.a.redMul(t)},u.prototype._mulC=function(t){return this.oneC?t:this.c.redMul(t)},u.prototype.jpoint=function(t,e,r,i){return this.point(t,e,r,i)},u.prototype.pointFromX=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr(),i=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=i.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(e&&!u||!e&&u)&&(s=s.redNeg()),this.point(t,s)},u.prototype.pointFromY=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr(),i=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=i.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(e)throw new Error("invalid point");return this.point(this.zero,t)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==e&&(s=s.redNeg()),this.point(s,t)},u.prototype.validate=function(t){if(t.isInfinity())return!0;t.normalize();var e=t.x.redSqr(),r=t.y.redSqr(),i=e.redMul(this.a).redAdd(r),n=this.c2.redMul(this.one.redAdd(this.d.redMul(e).redMul(r)));return 0===i.cmp(n)},o(h,a.BasePoint),u.prototype.pointFromJSON=function(t){return h.fromJSON(this,t)},u.prototype.point=function(t,e,r,i){return new h(this,t,e,r,i)},h.fromJSON=function(t,e){return new h(t,e[0],e[1],e[2])},h.prototype.inspect=function(){return this.isInfinity()?"":""},h.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},h.prototype._extDbl=function(){var t=this.x.redSqr(),e=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var i=this.curve._mulA(t),n=this.x.redAdd(this.y).redSqr().redISub(t).redISub(e),o=i.redAdd(e),a=o.redSub(r),s=i.redSub(e),u=n.redMul(a),h=o.redMul(s),f=n.redMul(s),c=a.redMul(o);return this.curve.point(u,h,c,f)},h.prototype._projDbl=function(){var t,e,r,i=this.x.redAdd(this.y).redSqr(),n=this.x.redSqr(),o=this.y.redSqr();if(this.curve.twisted){var a=(h=this.curve._mulA(n)).redAdd(o);if(this.zOne)t=i.redSub(n).redSub(o).redMul(a.redSub(this.curve.two)),e=a.redMul(h.redSub(o)),r=a.redSqr().redSub(a).redSub(a);else{var s=this.z.redSqr(),u=a.redSub(s).redISub(s);t=i.redSub(n).redISub(o).redMul(u),e=a.redMul(h.redSub(o)),r=a.redMul(u)}}else{var h=n.redAdd(o);s=this.curve._mulC(this.z).redSqr(),u=h.redSub(s).redSub(s);t=this.curve._mulC(i.redISub(h)).redMul(u),e=this.curve._mulC(h).redMul(n.redISub(o)),r=h.redMul(u)}return this.curve.point(t,e,r)},h.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},h.prototype._extAdd=function(t){var e=this.y.redSub(this.x).redMul(t.y.redSub(t.x)),r=this.y.redAdd(this.x).redMul(t.y.redAdd(t.x)),i=this.t.redMul(this.curve.dd).redMul(t.t),n=this.z.redMul(t.z.redAdd(t.z)),o=r.redSub(e),a=n.redSub(i),s=n.redAdd(i),u=r.redAdd(e),h=o.redMul(a),f=s.redMul(u),c=o.redMul(u),l=a.redMul(s);return this.curve.point(h,f,l,c)},h.prototype._projAdd=function(t){var e,r,i=this.z.redMul(t.z),n=i.redSqr(),o=this.x.redMul(t.x),a=this.y.redMul(t.y),s=this.curve.d.redMul(o).redMul(a),u=n.redSub(s),h=n.redAdd(s),f=this.x.redAdd(this.y).redMul(t.x.redAdd(t.y)).redISub(o).redISub(a),c=i.redMul(u).redMul(f);return this.curve.twisted?(e=i.redMul(h).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(h)):(e=i.redMul(h).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(h)),this.curve.point(c,e,r)},h.prototype.add=function(t){return this.isInfinity()?t:t.isInfinity()?this:this.curve.extended?this._extAdd(t):this._projAdd(t)},h.prototype.mul=function(t){return this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve._wnafMul(this,t)},h.prototype.mulAdd=function(t,e,r){return this.curve._wnafMulAdd(1,[this,e],[t,r],2,!1)},h.prototype.jmulAdd=function(t,e,r){return this.curve._wnafMulAdd(1,[this,e],[t,r],2,!0)},h.prototype.normalize=function(){if(this.zOne)return this;var t=this.z.redInvm();return this.x=this.x.redMul(t),this.y=this.y.redMul(t),this.t&&(this.t=this.t.redMul(t)),this.z=this.curve.one,this.zOne=!0,this},h.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},h.prototype.getX=function(){return this.normalize(),this.x.fromRed()},h.prototype.getY=function(){return this.normalize(),this.y.fromRed()},h.prototype.eq=function(t){return this===t||0===this.getX().cmp(t.getX())&&0===this.getY().cmp(t.getY())},h.prototype.eqXToP=function(t){var e=t.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(e))return!0;for(var r=t.clone(),i=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(e.redIAdd(i),0===this.x.cmp(e))return!0}},h.prototype.toP=h.prototype.normalize,h.prototype.mixedAdd=h.prototype.add},function(t,e,r){"use strict";e.sha1=r(235),e.sha224=r(236),e.sha256=r(106),e.sha384=r(237),e.sha512=r(107)},function(t,e,r){"use strict";var i=r(15),n=r(34),o=r(105),a=i.rotl32,s=i.sum32,u=i.sum32_5,h=o.ft_1,f=n.BlockHash,c=[1518500249,1859775393,2400959708,3395469782];function l(){if(!(this instanceof l))return new l;f.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}i.inherits(l,f),t.exports=l,l.blockSize=512,l.outSize=160,l.hmacStrength=80,l.padLength=64,l.prototype._update=function(t,e){for(var r=this.W,i=0;i<16;i++)r[i]=t[e+i];for(;ithis.blockSize&&(t=(new this.Hash).update(t).digest()),n(t.length<=this.blockSize);for(var e=t.length;e0))return a.iaddn(1),this.keyFromPrivate(a)}},c.prototype._truncateToN=function(t,e){var r=8*t.byteLength()-this.n.bitLength();return r>0&&(t=t.ushrn(r)),!e&&t.cmp(this.n)>=0?t.sub(this.n):t},c.prototype.sign=function(t,e,r,o){"object"===typeof r&&(o=r,r=null),o||(o={}),e=this.keyFromPrivate(e,r),t=this._truncateToN(new i(t,16));for(var a=this.n.byteLength(),s=e.getPrivate().toArray("be",a),u=t.toArray("be",a),h=new n({hash:this.hash,entropy:s,nonce:u,pers:o.pers,persEnc:o.persEnc||"utf8"}),c=this.n.sub(new i(1)),l=0;;l++){var d=o.k?o.k(l):new i(h.generate(this.n.byteLength()));if(!((d=this._truncateToN(d,!0)).cmpn(1)<=0||d.cmp(c)>=0)){var p=this.g.mul(d);if(!p.isInfinity()){var m=p.getX(),g=m.umod(this.n);if(0!==g.cmpn(0)){var b=d.invm(this.n).mul(g.mul(e.getPrivate()).iadd(t));if(0!==(b=b.umod(this.n)).cmpn(0)){var v=(p.getY().isOdd()?1:0)|(0!==m.cmp(g)?2:0);return o.canonical&&b.cmp(this.nh)>0&&(b=this.n.sub(b),v^=1),new f({r:g,s:b,recoveryParam:v})}}}}}},c.prototype.verify=function(t,e,r,n){t=this._truncateToN(new i(t,16)),r=this.keyFromPublic(r,n);var o=(e=new f(e,"hex")).r,a=e.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),h=u.mul(t).umod(this.n),c=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(h,r.getPublic(),c)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(h,r.getPublic(),c)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},c.prototype.recoverPubKey=function(t,e,r,n){u((3&r)===r,"The recovery param is more than two bits"),e=new f(e,n);var o=this.n,a=new i(t),s=e.r,h=e.s,c=1&r,l=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&l)throw new Error("Unable to find sencond key candinate");s=l?this.curve.pointFromX(s.add(this.curve.n),c):this.curve.pointFromX(s,c);var d=e.r.invm(o),p=o.sub(a).mul(d).umod(o),m=h.mul(d).umod(o);return this.g.mulAdd(p,s,m)},c.prototype.getKeyRecoveryParam=function(t,e,r,i){if(null!==(e=new f(e,i)).recoveryParam)return e.recoveryParam;for(var n=0;n<4;n++){var o;try{o=this.recoverPubKey(t,e,n)}catch(t){continue}if(o.eq(r))return n}throw new Error("Unable to find valid recovery factor")}},function(t,e,r){"use strict";var i=r(61),n=r(103),o=r(13);function a(t){if(!(this instanceof a))return new a(t);this.hash=t.hash,this.predResist=!!t.predResist,this.outLen=this.hash.outSize,this.minEntropy=t.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var e=n.toArray(t.entropy,t.entropyEnc||"hex"),r=n.toArray(t.nonce,t.nonceEnc||"hex"),i=n.toArray(t.pers,t.persEnc||"hex");o(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,i)}t.exports=a,a.prototype._init=function(t,e,r){var i=t.concat(e).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var n=0;n=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(t.concat(r||[])),this._reseed=1},a.prototype.generate=function(t,e,r,i){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof e&&(i=r,r=e,e=null),r&&(r=n.toArray(r,i||"hex"),this._update(r));for(var o=[];o.length"}},function(t,e,r){"use strict";var i=r(5),n=r(14),o=n.assert;function a(t,e){if(t instanceof a)return t;this._importDER(t,e)||(o(t.r&&t.s,"Signature without r or s"),this.r=new i(t.r,16),this.s=new i(t.s,16),void 0===t.recoveryParam?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}function s(){this.place=0}function u(t,e){var r=t[e.place++];if(!(128&r))return r;for(var i=15&r,n=0,o=0,a=e.place;o>>3);for(t.push(128|r);--r;)t.push(e>>>(r<<3)&255);t.push(e)}}t.exports=a,a.prototype._importDER=function(t,e){t=n.toArray(t,e);var r=new s;if(48!==t[r.place++])return!1;if(u(t,r)+r.place!==t.length)return!1;if(2!==t[r.place++])return!1;var o=u(t,r),a=t.slice(r.place,o+r.place);if(r.place+=o,2!==t[r.place++])return!1;var h=u(t,r);if(t.length!==h+r.place)return!1;var f=t.slice(r.place,h+r.place);return 0===a[0]&&128&a[1]&&(a=a.slice(1)),0===f[0]&&128&f[1]&&(f=f.slice(1)),this.r=new i(a),this.s=new i(f),this.recoveryParam=null,!0},a.prototype.toDER=function(t){var e=this.r.toArray(),r=this.s.toArray();for(128&e[0]&&(e=[0].concat(e)),128&r[0]&&(r=[0].concat(r)),e=h(e),r=h(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var i=[2];f(i,e.length),(i=i.concat(e)).push(2),f(i,r.length);var o=i.concat(r),a=[48];return f(a,o.length),a=a.concat(o),n.encode(a,t)}},function(t,e,r){"use strict";var i=r(61),n=r(60),o=r(14),a=o.assert,s=o.parseBytes,u=r(246),h=r(247);function f(t){if(a("ed25519"===t,"only tested with ed25519 so far"),!(this instanceof f))return new f(t);t=n[t].curve;this.curve=t,this.g=t.g,this.g.precompute(t.n.bitLength()+1),this.pointClass=t.point().constructor,this.encodingLength=Math.ceil(t.n.bitLength()/8),this.hash=i.sha512}t.exports=f,f.prototype.sign=function(t,e){t=s(t);var r=this.keyFromSecret(e),i=this.hashInt(r.messagePrefix(),t),n=this.g.mul(i),o=this.encodePoint(n),a=this.hashInt(o,r.pubBytes(),t).mul(r.priv()),u=i.add(a).umod(this.curve.n);return this.makeSignature({R:n,S:u,Rencoded:o})},f.prototype.verify=function(t,e,r){t=s(t),e=this.makeSignature(e);var i=this.keyFromPublic(r),n=this.hashInt(e.Rencoded(),i.pubBytes(),t),o=this.g.mul(e.S());return e.R().add(i.pub().mul(n)).eq(o)},f.prototype.hashInt=function(){for(var t=this.hash(),e=0;e=e)throw new Error("invalid sig")}t.exports=function(t,r,u,h,f){var c=o(u);if("ec"===c.type){if("ecdsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong public key type");return function(t,e,r){var i=a[r.data.algorithm.curve.join(".")];if(!i)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var o=new n(i),s=r.data.subjectPrivateKey.data;return o.verify(e,t,s)}(t,r,c)}if("dsa"===c.type){if("dsa"!==h)throw new Error("wrong public key type");return function(t,e,r){var n=r.data.p,a=r.data.q,u=r.data.g,h=r.data.pub_key,f=o.signature.decode(t,"der"),c=f.s,l=f.r;s(c,a),s(l,a);var d=i.mont(n),p=c.invm(a);return 0===u.toRed(d).redPow(new i(e).mul(p).mod(a)).fromRed().mul(h.toRed(d).redPow(l.mul(p).mod(a)).fromRed()).mod(n).mod(a).cmp(l)}(t,r,c)}if("rsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong public key type");r=e.concat([f,r]);for(var l=c.modulus.byteLength(),d=[1],p=0;r.length+d.length+2r-l-2)throw new Error("message too long");var d=c.alloc(r-i-l-2),p=r-f-1,m=n(f),g=s(c.concat([h,d,c.alloc(1,1),e],p),a(m,p)),b=s(m,a(g,f));return new u(c.concat([c.alloc(1),b,g],r))}(p,e);else if(1===l)d=function(t,e,r){var i,o=e.length,a=t.modulus.byteLength();if(o>a-11)throw new Error("message too long");i=r?c.alloc(a-o-3,255):function(t){var e,r=c.allocUnsafe(t),i=0,o=n(2*t),a=0;for(;i=0)throw new Error("data too long for modulus")}return r?f(d,p):h(d,p)}},function(t,e,r){var i=r(42),n=r(113),o=r(114),a=r(5),s=r(58),u=r(30),h=r(115),f=r(2).Buffer;t.exports=function(t,e,r){var c;c=t.padding?t.padding:r?1:4;var l,d=i(t),p=d.modulus.byteLength();if(e.length>p||new a(e).cmp(d.modulus)>=0)throw new Error("decryption error");l=r?h(new a(e),d):s(e,d);var m=f.alloc(p-l.length);if(l=f.concat([m,l],p),4===c)return function(t,e){var r=t.modulus.byteLength(),i=u("sha1").update(f.alloc(0)).digest(),a=i.length;if(0!==e[0])throw new Error("decryption error");var s=e.slice(1,a+1),h=e.slice(a+1),c=o(s,n(h,a)),l=o(h,n(c,r-a-1));if(function(t,e){t=f.from(t),e=f.from(e);var r=0,i=t.length;t.length!==e.length&&(r++,i=Math.min(t.length,e.length));var n=-1;for(;++n=e.length){o++;break}var a=e.slice(2,n-1);("0002"!==i.toString("hex")&&!r||"0001"!==i.toString("hex")&&r)&&o++;a.length<8&&o++;if(o)throw new Error("decryption error");return e.slice(n)}(0,l,r);if(3===c)return l;throw new Error("unknown padding")}},function(t,e,r){"use strict";(function(t,i){function n(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(2),a=r(21),s=o.Buffer,u=o.kMaxLength,h=t.crypto||t.msCrypto,f=Math.pow(2,32)-1;function c(t,e){if("number"!==typeof t||t!==t)throw new TypeError("offset must be a number");if(t>f||t<0)throw new TypeError("offset must be a uint32");if(t>u||t>e)throw new RangeError("offset out of range")}function l(t,e,r){if("number"!==typeof t||t!==t)throw new TypeError("size must be a number");if(t>f||t<0)throw new TypeError("size must be a uint32");if(t+e>r||t>u)throw new RangeError("buffer too small")}function d(t,e,r,n){if(i.browser){var o=t.buffer,s=new Uint8Array(o,e,r);return h.getRandomValues(s),n?void i.nextTick((function(){n(null,t)})):t}if(!n)return a(r).copy(t,e),t;a(r,(function(r,i){if(r)return n(r);i.copy(t,e),n(null,t)}))}h&&h.getRandomValues||!i.browser?(e.randomFill=function(e,r,i,n){if(!s.isBuffer(e)&&!(e instanceof t.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"===typeof r)n=r,r=0,i=e.length;else if("function"===typeof i)n=i,i=e.length-r;else if("function"!==typeof n)throw new TypeError('"cb" argument must be a function');return c(r,e.length),l(i,r,e.length),d(e,r,i,n)},e.randomFillSync=function(e,r,i){"undefined"===typeof r&&(r=0);if(!s.isBuffer(e)&&!(e instanceof t.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');c(r,e.length),void 0===i&&(i=e.length-r);return l(i,r,e.length),d(e,r,i)}):(e.randomFill=n,e.randomFillSync=n)}).call(this,r(10),r(8))},function(t,e,r){var i=r(116),n=r(268);function o(t,e,r){var i=t[e]+t[r],n=t[e+1]+t[r+1];i>=4294967296&&n++,t[e]=i,t[e+1]=n}function a(t,e,r,i){var n=t[e]+r;r<0&&(n+=4294967296);var o=t[e+1]+i;n>=4294967296&&o++,t[e]=n,t[e+1]=o}function s(t,e){return t[e]^t[e+1]<<8^t[e+2]<<16^t[e+3]<<24}function u(t,e,r,i,n,s){var u=l[n],h=l[n+1],f=l[s],d=l[s+1];o(c,t,e),a(c,t,u,h);var p=c[i]^c[t],m=c[i+1]^c[t+1];c[i]=m,c[i+1]=p,o(c,r,i),p=c[e]^c[r],m=c[e+1]^c[r+1],c[e]=p>>>24^m<<8,c[e+1]=m>>>24^p<<8,o(c,t,e),a(c,t,f,d),p=c[i]^c[t],m=c[i+1]^c[t+1],c[i]=p>>>16^m<<16,c[i+1]=m>>>16^p<<16,o(c,r,i),p=c[e]^c[r],m=c[e+1]^c[r+1],c[e]=m>>>31^p<<1,c[e+1]=p>>>31^m<<1}var h=new Uint32Array([4089235720,1779033703,2227873595,3144134277,4271175723,1013904242,1595750129,2773480762,2917565137,1359893119,725511199,2600822924,4215389547,528734635,327033209,1541459225]),f=new Uint8Array([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3,11,8,12,0,5,2,15,13,10,14,3,6,7,1,9,4,7,9,3,1,13,12,11,14,2,6,5,10,4,0,15,8,9,0,5,7,2,4,10,15,14,1,11,12,6,8,3,13,2,12,6,10,0,11,8,3,4,13,7,5,15,14,1,9,12,5,1,15,14,13,4,10,0,7,6,3,9,2,8,11,13,11,7,14,12,1,3,9,5,0,15,4,8,6,2,10,6,15,14,9,11,3,0,8,12,2,13,7,1,4,10,5,10,2,8,4,7,6,1,5,15,11,9,14,3,12,13,0,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3].map((function(t){return 2*t}))),c=new Uint32Array(32),l=new Uint32Array(32);function d(t,e){var r=0;for(r=0;r<16;r++)c[r]=t.h[r],c[r+16]=h[r];for(c[24]=c[24]^t.t,c[25]=c[25]^t.t/4294967296,e&&(c[28]=~c[28],c[29]=~c[29]),r=0;r<32;r++)l[r]=s(t.b,4*r);for(r=0;r<12;r++)u(0,8,16,24,f[16*r+0],f[16*r+1]),u(2,10,18,26,f[16*r+2],f[16*r+3]),u(4,12,20,28,f[16*r+4],f[16*r+5]),u(6,14,22,30,f[16*r+6],f[16*r+7]),u(0,10,20,30,f[16*r+8],f[16*r+9]),u(2,12,22,24,f[16*r+10],f[16*r+11]),u(4,14,16,26,f[16*r+12],f[16*r+13]),u(6,8,18,28,f[16*r+14],f[16*r+15]);for(r=0;r<16;r++)t.h[r]=t.h[r]^c[r]^c[r+16]}var p=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);function m(t,e,r,i){p.fill(0),this.b=new Uint8Array(128),this.h=new Uint32Array(16),this.t=0,this.c=0,this.outlen=t,p[0]=t,e&&(p[1]=e.length),p[2]=1,p[3]=1,r&&p.set(r,32),i&&p.set(i,48);for(var n=0;n<16;n++)this.h[n]=h[n]^s(p,4*n);e&&(g(this,e),this.c=128)}function g(t,e){for(var r=0;r=this.outlen,"out must have at least outlen bytes of space"),function(t,e){t.t+=t.c;for(;t.c<128;)t.b[t.c++]=0;d(t,!0);for(var r=0;r>2]>>8*(3&r)}(this,e),"hex"===t?function(t){for(var e="",r=0;r=y,"outlen must be at least "+y+", was given "+t),i(t<=w,"outlen must be at most "+w+", was given "+t),null!=e&&i(e.length>=_,"key must be at least "+_+", was given "+e.length),null!=e&&i(e.length<=M,"key must be at most "+M+", was given "+e.length),null!=r&&i(r.length===A,"salt must be exactly "+A+", was given "+r.length),null!=n&&i(n.length===I,"personal must be exactly "+I+", was given "+n.length)),new v(t,e,r,n)},t.exports.ready=function(t){n.ready((function(){t()}))},t.exports.WASM_SUPPORTED=n.SUPPORTED,t.exports.WASM_LOADED=!1;var y=t.exports.BYTES_MIN=16,w=t.exports.BYTES_MAX=64,_=(t.exports.BYTES=32,t.exports.KEYBYTES_MIN=16),M=t.exports.KEYBYTES_MAX=64,A=(t.exports.KEYBYTES=32,t.exports.SALTBYTES=16),I=t.exports.PERSONALBYTES=16;n.ready((function(e){e||(t.exports.WASM_LOADED=!0,v=n)}))},function(t,e,r){var i=r(116),n=r(269)(),o=64,a=[];t.exports=d;var s=t.exports.BYTES_MIN=16,u=t.exports.BYTES_MAX=64,h=(t.exports.BYTES=32,t.exports.KEYBYTES_MIN=16),f=t.exports.KEYBYTES_MAX=64,c=(t.exports.KEYBYTES=32,t.exports.SALTBYTES=16),l=t.exports.PERSONALBYTES=16;function d(t,e,r,p,m){if(!(this instanceof d))return new d(t,e,r,p,m);if(!n||!n.exports)throw new Error("WASM not loaded. Wait for Blake2b.ready(cb)");t||(t=32),!0!==m&&(i(t>=s,"digestLength must be at least "+s+", was given "+t),i(t<=u,"digestLength must be at most "+u+", was given "+t),null!=e&&i(e.length>=h,"key must be at least "+h+", was given "+e.length),null!=e&&i(e.length<=f,"key must be at least "+f+", was given "+e.length),null!=r&&i(r.length===c,"salt must be exactly "+c+", was given "+r.length),null!=p&&i(p.length===l,"personal must be exactly "+l+", was given "+p.length)),a.length||(a.push(o),o+=216),this.digestLength=t,this.finalized=!1,this.pointer=a.pop(),n.memory.fill(0,0,64),n.memory[0]=this.digestLength,n.memory[1]=e?e.length:0,n.memory[2]=1,n.memory[3]=1,r&&n.memory.set(r,32),p&&n.memory.set(p,48),this.pointer+216>n.memory.length&&n.realloc(this.pointer+216),n.exports.blake2b_init(this.pointer,this.digestLength),e&&(this.update(e),n.memory.fill(0,o,o+e.length),n.memory[this.pointer+200]=128)}function p(){}function m(t){return t<16?"0"+t.toString(16):t.toString(16)}d.prototype.update=function(t){return i(!1===this.finalized,"Hash instance finalized"),i(t,"input must be TypedArray or Buffer"),o+t.length>n.memory.length&&n.realloc(o+t.length),n.memory.set(t,o),n.exports.blake2b_update(this.pointer,o,o+t.length),this},d.prototype.digest=function(t){if(i(!1===this.finalized,"Hash instance finalized"),this.finalized=!0,a.push(this.pointer),n.exports.blake2b_final(this.pointer),!t||"binary"===t)return n.memory.slice(this.pointer+128,this.pointer+128+this.digestLength);if("hex"===t)return function(t,e,r){for(var i="",n=0;n=this.digestLength,"input must be TypedArray or Buffer");for(var e=0;et)throw new Error("bad digestLength");var f,c,l;this.digestLength=u;var d=0;if(a(h))d=(f=h).length;else if("object"===typeof h)!function(t){for(var e in t)switch(e){case"key":case"personalization":case"salt":if(!a(t[e]))throw new TypeError(e+" must be a Uint8Array or an Array of bytes");break;default:throw new Error("unexpected key in config: "+e)}}(h),d=(f=h.key)?f.length:0,l=h.salt,c=h.personalization;else if(h)throw new Error("unexpected key or config type");if(d>r)throw new Error("key is too long");if(l&&l.length!==n)throw new Error("salt must be "+n+" bytes");if(c&&c.length!==i)throw new Error("personalization must be "+i+" bytes");this.isFinished=!1,this.h=new Uint32Array(o);var p=new Uint8Array([255&u,d,1,1]);if(this.h[0]^=s(p,0),l&&(this.h[4]^=s(l,0),this.h[5]^=s(l,4)),c&&(this.h[6]^=s(c,0),this.h[7]^=s(c,4)),this.x=new Uint8Array(e),this.nx=0,this.t0=0,this.t1=0,this.f0=0,this.f1=0,d>0){for(var m=0;m>>0&&(this.t0=0,this.t1++);var e=this.h[0],r=this.h[1],i=this.h[2],n=this.h[3],a=this.h[4],s=this.h[5],u=this.h[6],h=this.h[7],f=o[0],c=o[1],l=o[2],d=o[3],p=o[4]^this.t0,m=o[5]^this.t1,g=o[6]^this.f0,b=o[7]^this.f1,v=this.x,y=255&v[0]|(255&v[1])<<8|(255&v[2])<<16|(255&v[3])<<24,w=255&v[4]|(255&v[5])<<8|(255&v[6])<<16|(255&v[7])<<24,_=255&v[8]|(255&v[9])<<8|(255&v[10])<<16|(255&v[11])<<24,M=255&v[12]|(255&v[13])<<8|(255&v[14])<<16|(255&v[15])<<24,A=255&v[16]|(255&v[17])<<8|(255&v[18])<<16|(255&v[19])<<24,I=255&v[20]|(255&v[21])<<8|(255&v[22])<<16|(255&v[23])<<24,S=255&v[24]|(255&v[25])<<8|(255&v[26])<<16|(255&v[27])<<24,E=255&v[28]|(255&v[29])<<8|(255&v[30])<<16|(255&v[31])<<24,k=255&v[32]|(255&v[33])<<8|(255&v[34])<<16|(255&v[35])<<24,x=255&v[36]|(255&v[37])<<8|(255&v[38])<<16|(255&v[39])<<24,B=255&v[40]|(255&v[41])<<8|(255&v[42])<<16|(255&v[43])<<24,C=255&v[44]|(255&v[45])<<8|(255&v[46])<<16|(255&v[47])<<24,T=255&v[48]|(255&v[49])<<8|(255&v[50])<<16|(255&v[51])<<24,P=255&v[52]|(255&v[53])<<8|(255&v[54])<<16|(255&v[55])<<24,R=255&v[56]|(255&v[57])<<8|(255&v[58])<<16|(255&v[59])<<24,O=255&v[60]|(255&v[61])<<8|(255&v[62])<<16|(255&v[63])<<24;a=(a^=f=f+(p=(p^=e=(e=e+y|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+_|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+A|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+S|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+I|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+E|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+M|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+w|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+k|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+B|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+T|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+R|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+P|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+O|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+C|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+x|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+R|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+A|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+x|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+P|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+O|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+S|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+k|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+B|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+w|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+y|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+C|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+I|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+E|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+M|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+_|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+T|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+C|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+T|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+I|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+O|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+_|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+P|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+y|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+k|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+B|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+M|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+E|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+x|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+w|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+A|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+S|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+R|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+E|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+M|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+P|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+C|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+T|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+R|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+w|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+x|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+_|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+I|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+A|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+O|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+y|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+k|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+B|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+S|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+x|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+I|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+_|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+B|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+A|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+O|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+E|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+y|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+R|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+C|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+S|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+M|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+k|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+P|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+T|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+w|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+_|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+S|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+y|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+k|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+C|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+M|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+B|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+T|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+A|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+E|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+O|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+w|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+R|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+x|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+I|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+P|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+T|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+w|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+R|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+A|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+P|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+B|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+O|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+I|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+y|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+S|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+x|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+k|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+_|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+C|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+M|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+E|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+P|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+E|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+T|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+M|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+w|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+x|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+R|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+C|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+I|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+O|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+k|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+_|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+S|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+B|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+A|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+y|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+S|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+R|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+C|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+y|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+M|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+k|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+x|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+O|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+T|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+P|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+w|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+B|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+A|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+I|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+E|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+_|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+B|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+k|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+E|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+w|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+S|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+I|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+A|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+_|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+O|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+x|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+M|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+P|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+T|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+y|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+R|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+C|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,this.h[0]^=e^f,this.h[1]^=r^c,this.h[2]^=i^l,this.h[3]^=n^d,this.h[4]^=a^p,this.h[5]^=s^m,this.h[6]^=u^g,this.h[7]^=h^b},u.prototype.update=function(t,e,r){if("string"===typeof t)throw new TypeError("update() accepts Uint8Array or an Array of bytes");if(this.isFinished)throw new Error("update() after calling digest()");if("undefined"===typeof e&&(e=0),"undefined"===typeof r&&(r=t.length-e),0===r)return this;var i,n=64-this.nx;if(r>n){for(i=0;i64;){for(i=0;i<64;i++)this.x[i]=t[e+i];this.processBlock(64),e+=64,r-=64,this.nx=0}for(i=0;i>>0&255,e[4*t+1]=r>>>8&255,e[4*t+2]=r>>>16&255,e[4*t+3]=r>>>24&255}return this.result=new Uint8Array(e.subarray(0,this.digestLength)),this.isFinished=!0,this.result},u.prototype.hexDigest=function(){for(var t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],e=[],r=this.digest(),i=0;i>4&15]),e.push(t[15&r[i]]);return e.join("")},u.digestLength=t,u.blockLength=e,u.keyLength=r,u.saltLength=n,u.personalizationLength=i,u}();t.exports&&(t.exports=i)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(274),n=r(119),o=r(3),a=r(44),s=r(4),u=r(37),h=r(6);e.genOutCm=function(e,r,f,c){if(e=u.newAsset(e),r=o.toBuffer(r),f=h.newFR(f),c=a.newPKr(c),s(64==r.length),e.isValid()&&c.isValid()){var l=i.genAssetCurrency(e.tkn_currency).mult(e.tkn_value);o.default.isEmptyBuffer(e.tkt_value,32)||(l=l.add(i.genAssetTkt(e.tkt_category,e.tkt_value)));var d=t.concat([l.toBuffer(),r,c.VPK.toBuffer(),c.BASE.toBuffer(),f.toBuffer()]);return s(192==d.length,"blob.length != 192,"),i.outCmBase.mult(new n.BitBuffer(d))}}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(117),n=r(118),o=r(17),a=r(3),s=r(4);e.outCmBase=new i.Group("$SROOUTCMGEN",8,192,4),e.genAssetTkt=function(e,r){e=a.toBuffer(e),r=a.toBuffer(r),s(32==e.length),s(32==r.length);var i=t.concat([e,r]),u=n.findPoint("$SROASSETTK",o.blake2b("$SROASSETTK.H",i));if(!u)throw new Error("find point error");return u},e.genAssetCurrency=function(t){t=a.toBuffer(t),s(32==t.length);var e=n.findPoint("$SROASSETCY",t);if(!e)throw new Error("find point error");return e}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(37),n=r(6),o=r(64),a=r(3),s=r(4),u=function(){function e(t,e,r){this.asset=i.newAsset(t),this.rsk=n.newFR(e),this.memo=a.toBuffer(r)}return e.prototype.isValid=function(){return!!this.asset.isValid()&&!this.rsk.isZero()},e.prototype.toBuffer=function(){return t.concat([this.asset.toBuffer(),this.rsk.toBuffer(),this.memo])},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function h(e){if(e instanceof u)return e;var r=a.toBuffer(e);return s(224==r.length),new u(i.newAsset(r.slice(0,128)),new n.FR(r.slice(128,160)),t.from(r.slice(160,224)))}e.Info=u,e.newInfo=h,e.encInfo=function(t,e){t=a.toBuffer(t),e=h(e),s(32==t.length);var r=e.toBuffer();return o.default(r,t)},e.decEInfo=function(t,e,r){return s(r,"flag must true"),t=a.toBuffer(t),e=a.toBuffer(e),s(224==t.length),s(32==e.length),h(o.default(t,e))}}).call(this,r(0).Buffer)},function(t,e,r){t.exports=r(277)},function(t,e,r){(function(e){var i=r(124).pbkdf2Sync,n=2147483647;function o(t,r,i,n,o){if(e.isBuffer(t)&&e.isBuffer(i))t.copy(i,n,r,r+o);else for(;o--;)i[n++]=t[r++]}t.exports=function(t,r,a,s,u,h,f){if(0===a||0!==(a&a-1))throw Error("N must be > 0 and a power of 2");if(a>n/128/s)throw Error("Parameter N is too large");if(s>n/128/u)throw Error("Parameter r is too large");var c,l=new e(256*s),d=new e(128*s*a),p=new Int32Array(16),m=new Int32Array(16),g=new e(64),b=i(t,r,1,128*u*s,"sha256");if(f){var v=u*a*2,y=0;c=function(){++y%1e3===0&&f({current:y,total:v,percent:y/v*100})}}for(var w=0;w>>32-e}function I(t){var e;for(e=0;e<16;e++)p[e]=(255&t[4*e+0])<<0,p[e]|=(255&t[4*e+1])<<8,p[e]|=(255&t[4*e+2])<<16,p[e]|=(255&t[4*e+3])<<24;for(o(p,0,m,0,16),e=8;e>0;e-=2)m[4]^=A(m[0]+m[12],7),m[8]^=A(m[4]+m[0],9),m[12]^=A(m[8]+m[4],13),m[0]^=A(m[12]+m[8],18),m[9]^=A(m[5]+m[1],7),m[13]^=A(m[9]+m[5],9),m[1]^=A(m[13]+m[9],13),m[5]^=A(m[1]+m[13],18),m[14]^=A(m[10]+m[6],7),m[2]^=A(m[14]+m[10],9),m[6]^=A(m[2]+m[14],13),m[10]^=A(m[6]+m[2],18),m[3]^=A(m[15]+m[11],7),m[7]^=A(m[3]+m[15],9),m[11]^=A(m[7]+m[3],13),m[15]^=A(m[11]+m[7],18),m[1]^=A(m[0]+m[3],7),m[2]^=A(m[1]+m[0],9),m[3]^=A(m[2]+m[1],13),m[0]^=A(m[3]+m[2],18),m[6]^=A(m[5]+m[4],7),m[7]^=A(m[6]+m[5],9),m[4]^=A(m[7]+m[6],13),m[5]^=A(m[4]+m[7],18),m[11]^=A(m[10]+m[9],7),m[8]^=A(m[11]+m[10],9),m[9]^=A(m[8]+m[11],13),m[10]^=A(m[9]+m[8],18),m[12]^=A(m[15]+m[14],7),m[13]^=A(m[12]+m[15],9),m[14]^=A(m[13]+m[12],13),m[15]^=A(m[14]+m[13],18);for(e=0;e<16;++e)p[e]=m[e]+p[e];for(e=0;e<16;e++){var r=4*e;t[r+0]=p[e]>>0&255,t[r+1]=p[e]>>8&255,t[r+2]=p[e]>>16&255,t[r+3]=p[e]>>24&255}}function S(t,e,r,i,n){for(var o=0;o0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return a.alloc(0);for(var e,r,i,n=a.allocUnsafe(t>>>0),o=this.head,s=0;o;)e=o.data,r=n,i=s,a.prototype.copy.call(e,r,i),s+=o.data.length,o=o.next;return n}},{key:"consume",value:function(t,e){var r;return tn.length?n.length:t;if(o===n.length?i+=n:i+=n.slice(0,t),0===(t-=o)){o===n.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=n.slice(o));break}++r}return this.length-=r,i}},{key:"_getBuffer",value:function(t){var e=a.allocUnsafe(t),r=this.head,i=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var n=r.data,o=t>n.length?n.length:t;if(n.copy(e,e.length-t,0,o),0===(t-=o)){o===n.length?(++i,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=n.slice(o));break}++i}return this.length-=i,e}},{key:u,value:function(t,e){return s(this,function(t){for(var e=1;e0,(function(t){f||(f=t),t&&l.forEach(u),o||(l.forEach(u),c(f))}))}));return e.reduce(h)}},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<30|t>>>2}function f(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,c=0;c<16;++c)r[c]=t.readInt32BE(4*c);for(;c<80;++c)r[c]=r[c-3]^r[c-8]^r[c-14]^r[c-16];for(var l=0;l<80;++l){var d=~~(l/20),p=0|((e=i)<<5|e>>>27)+f(d,n,o,s)+u+r[l]+a[d];u=s,s=o,o=h(n),n=i,i=p}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<5|t>>>27}function f(t){return t<<30|t>>>2}function c(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,l=0;l<16;++l)r[l]=t.readInt32BE(4*l);for(;l<80;++l)r[l]=(e=r[l-3]^r[l-8]^r[l-14]^r[l-16])<<1|e>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=h(i)+c(p,n,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=f(n),n=i,i=m}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(9),n=r(138),o=r(28),a=r(7).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}i(u,n),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 t=a.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t},t.exports=u},function(t,e,r){var i=r(9),n=r(139),o=r(28),a=r(7).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}i(u,n),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 t=a.allocUnsafe(48);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){var i=r(294),n=r(295);t.exports=function(t,e,r){var o=e&&r||0;"string"==typeof t&&(e="binary"===t?new Array(16):null,t=null);var a=(t=t||{}).random||(t.rng||i)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,e)for(var s=0;s<16;++s)e[o+s]=a[s];return e||n(a)}},function(t,e){var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(r){var i=new Uint8Array(16);t.exports=function(){return r(i),i}}else{var n=new Array(16);t.exports=function(){for(var t,e=0;e<16;e++)0===(3&e)&&(t=4294967296*Math.random()),n[e]=t>>>((3&e)<<3)&255;return n}}},function(t,e){for(var r=[],i=0;i<256;++i)r[i]=(i+256).toString(16).substr(1);t.exports=function(t,e){var i=e||0,n=r;return[n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]]].join("")}},function(t,e,r){"use strict";(function(t){var i=r(297);Object.defineProperty(e,"__esModule",{value:!0});var n=r(301),o=r(124),a=r(43),s=r(141),u=s._default,h="Invalid mnemonic",f="Invalid entropy",c="Invalid mnemonic checksum",l="A wordlist is required but a default could not be found.\nPlease explicitly pass a 2048 word array explicitly.";function d(t,e,r){for(;t.length32)throw new Error(f);if(m.length%4!==0)throw new Error(f);var b=t.from(m);if(g(b)!==s)throw new Error(c);return b.toString("hex")}function y(e,r){if(t.isBuffer(e)||(e=t.from(e,"hex")),!(r=r||u))throw new Error(l);if(e.length<16)throw new TypeError(f);if(e.length>32)throw new TypeError(f);if(e.length%4!==0)throw new TypeError(f);var n=(m(i(e))+g(e)).match(/(.{1,11})/g).map((function(t){var e=p(t);return r[e]}));return"\u3042\u3044\u3053\u304f\u3057\u3093"===r[0]?n.join("\u3000"):n.join(" ")}e.mnemonicToSeedSync=function(e,r){var i=t.from((e||"").normalize("NFKD"),"utf8"),n=t.from(b((r||"").normalize("NFKD")),"utf8");return o.pbkdf2Sync(i,n,2048,64,"sha512")},e.mnemonicToSeed=function(e,r){return new Promise((function(i,n){try{var a=t.from((e||"").normalize("NFKD"),"utf8"),s=t.from(b((r||"").normalize("NFKD")),"utf8");o.pbkdf2(a,s,2048,64,"sha512",(function(t,e){return t?n(t):i(e)}))}catch(u){return n(u)}}))},e.mnemonicToEntropy=v,e.entropyToMnemonic=y,e.generateMnemonic=function(t,e,r){if((t=t||128)%32!==0)throw new TypeError(f);return y((e=e||a)(t/8),r)},e.validateMnemonic=function(t,e){try{v(t,e)}catch(r){return!1}return!0},e.setDefaultWordlist=function(t){var e=s.wordlists[t];if(!e)throw new Error('Could not find wordlist for language "'+t+'"');u=e},e.getDefaultWordlist=function(){if(!u)throw new Error("No Default Wordlist set");return Object.keys(s.wordlists).filter((function(t){return"JA"!==t&&"EN"!==t&&s.wordlists[t].every((function(t,e){return t===u[e]}))}))[0]};var w=r(141);e.wordlists=w.wordlists}).call(this,r(0).Buffer)},function(t,e,r){var i=r(298),n=r(299),o=r(300);t.exports=function(t){return i(t)||n(t)||o()}},function(t,e){t.exports=function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e>>this.count%4*8&255,this.count+=1,this.count===this.blockSize&&(n.p1600(this.state),this.count=0);return e},o.prototype.copy=function(t){for(var e=0;e<50;++e)t.state[e]=this.state[e];t.blockSize=this.blockSize,t.count=this.count,t.squeezing=this.squeezing},t.exports=o},function(t,e,r){"use strict";var i=[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];e.p1600=function(t){for(var e=0;e<24;++e){var r=t[0]^t[10]^t[20]^t[30]^t[40],n=t[1]^t[11]^t[21]^t[31]^t[41],o=t[2]^t[12]^t[22]^t[32]^t[42],a=t[3]^t[13]^t[23]^t[33]^t[43],s=t[4]^t[14]^t[24]^t[34]^t[44],u=t[5]^t[15]^t[25]^t[35]^t[45],h=t[6]^t[16]^t[26]^t[36]^t[46],f=t[7]^t[17]^t[27]^t[37]^t[47],c=t[8]^t[18]^t[28]^t[38]^t[48],l=t[9]^t[19]^t[29]^t[39]^t[49],d=c^(o<<1|a>>>31),p=l^(a<<1|o>>>31),m=t[0]^d,g=t[1]^p,b=t[10]^d,v=t[11]^p,y=t[20]^d,w=t[21]^p,_=t[30]^d,M=t[31]^p,A=t[40]^d,I=t[41]^p;d=r^(s<<1|u>>>31),p=n^(u<<1|s>>>31);var S=t[2]^d,E=t[3]^p,k=t[12]^d,x=t[13]^p,B=t[22]^d,C=t[23]^p,T=t[32]^d,P=t[33]^p,R=t[42]^d,O=t[43]^p;d=o^(h<<1|f>>>31),p=a^(f<<1|h>>>31);var j=t[4]^d,D=t[5]^p,N=t[14]^d,z=t[15]^p,K=t[24]^d,q=t[25]^p,U=t[34]^d,F=t[35]^p,L=t[44]^d,Q=t[45]^p;d=s^(c<<1|l>>>31),p=u^(l<<1|c>>>31);var H=t[6]^d,V=t[7]^p,Z=t[16]^d,G=t[17]^p,Y=t[26]^d,W=t[27]^p,J=t[36]^d,X=t[37]^p,$=t[46]^d,tt=t[47]^p;d=h^(r<<1|n>>>31),p=f^(n<<1|r>>>31);var et=t[8]^d,rt=t[9]^p,it=t[18]^d,nt=t[19]^p,ot=t[28]^d,at=t[29]^p,st=t[38]^d,ut=t[39]^p,ht=t[48]^d,ft=t[49]^p,ct=m,lt=g,dt=v<<4|b>>>28,pt=b<<4|v>>>28,mt=y<<3|w>>>29,gt=w<<3|y>>>29,bt=M<<9|_>>>23,vt=_<<9|M>>>23,yt=A<<18|I>>>14,wt=I<<18|A>>>14,_t=S<<1|E>>>31,Mt=E<<1|S>>>31,At=x<<12|k>>>20,It=k<<12|x>>>20,St=B<<10|C>>>22,Et=C<<10|B>>>22,kt=P<<13|T>>>19,xt=T<<13|P>>>19,Bt=R<<2|O>>>30,Ct=O<<2|R>>>30,Tt=D<<30|j>>>2,Pt=j<<30|D>>>2,Rt=N<<6|z>>>26,Ot=z<<6|N>>>26,jt=q<<11|K>>>21,Dt=K<<11|q>>>21,Nt=U<<15|F>>>17,zt=F<<15|U>>>17,Kt=Q<<29|L>>>3,qt=L<<29|Q>>>3,Ut=H<<28|V>>>4,Ft=V<<28|H>>>4,Lt=G<<23|Z>>>9,Qt=Z<<23|G>>>9,Ht=Y<<25|W>>>7,Vt=W<<25|Y>>>7,Zt=J<<21|X>>>11,Gt=X<<21|J>>>11,Yt=tt<<24|$>>>8,Wt=$<<24|tt>>>8,Jt=et<<27|rt>>>5,Xt=rt<<27|et>>>5,$t=it<<20|nt>>>12,te=nt<<20|it>>>12,ee=at<<7|ot>>>25,re=ot<<7|at>>>25,ie=st<<8|ut>>>24,ne=ut<<8|st>>>24,oe=ht<<14|ft>>>18,ae=ft<<14|ht>>>18;t[0]=ct^~At&jt,t[1]=lt^~It&Dt,t[10]=Ut^~$t&mt,t[11]=Ft^~te>,t[20]=_t^~Rt&Ht,t[21]=Mt^~Ot&Vt,t[30]=Jt^~dt&St,t[31]=Xt^~pt&Et,t[40]=Tt^~Lt&ee,t[41]=Pt^~Qt&re,t[2]=At^~jt&Zt,t[3]=It^~Dt&Gt,t[12]=$t^~mt&kt,t[13]=te^~gt&xt,t[22]=Rt^~Ht&ie,t[23]=Ot^~Vt&ne,t[32]=dt^~St&Nt,t[33]=pt^~Et&zt,t[42]=Lt^~ee&bt,t[43]=Qt^~re&vt,t[4]=jt^~Zt&oe,t[5]=Dt^~Gt&ae,t[14]=mt^~kt&Kt,t[15]=gt^~xt&qt,t[24]=Ht^~ie&yt,t[25]=Vt^~ne&wt,t[34]=St^~Nt&Yt,t[35]=Et^~zt&Wt,t[44]=ee^~bt&Bt,t[45]=re^~vt&Ct,t[6]=Zt^~oe&ct,t[7]=Gt^~ae<,t[16]=kt^~Kt&Ut,t[17]=xt^~qt&Ft,t[26]=ie^~yt&_t,t[27]=ne^~wt&Mt,t[36]=Nt^~Yt&Jt,t[37]=zt^~Wt&Xt,t[46]=bt^~Bt&Tt,t[47]=vt^~Ct&Pt,t[8]=oe^~ct&At,t[9]=ae^~lt&It,t[18]=Kt^~Ut&$t,t[19]=qt^~Ft&te,t[28]=yt^~_t&Rt,t[29]=wt^~Mt&Ot,t[38]=Yt^~Jt&dt,t[39]=Wt^~Xt&pt,t[48]=Bt^~Tt&Lt,t[49]=Ct^~Pt&Qt,t[0]^=i[2*e],t[1]^=i[2*e+1]}}},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(318).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(46),n=r(25),o=r(65),a=r(3),s=r(3),u=r(320),h=r(37),f=r(81),c=r(122),l=r(6),d=r(19),p=r(45),m=r(142),g=r(321),b=function(){this.hash=t.alloc(32),this.param=new u.Params},v=function(e){this.p0_ins=new Array,this.p_ins=new Array,this.c_ins=new Array,this.c_outs=new Array,this.p_outs=new Array,this.keys=new Array,this.balance_desc=new b,this.s={Desc_O:{},Desc_Z:{},Desc_Pkg:{},Desc_Cmd:{},Tx1:{Ins_P:new Array,Ins_P0:new Array,Ins_C:new Array,Outs_C:new Array,Outs_P:new Array},Bcr:a.toHex(t.alloc(32,0)),Bsign:a.toHex(t.alloc(64,0))},this.param=e};function y(e){var r=t.alloc(32,0),i=t.alloc(32,0),n=t.alloc(32,0),o=t.alloc(32,0);return e.Tkn&&(e.Tkn.Currency&&(r=e.Tkn.Currency),e.Tkn.Value&&(i=a.default.toBN(e.Tkn.Value).toArrayLike(t,"le",32))),e.Tkt&&(e.Tkt.Category&&(n=e.Tkt.Category),e.Tkt.Value&&(o=e.Tkt.Value)),new h.Asset(r,i,n,o)}function w(e){var r=[s.toBuffer(e.Ehash),s.toBuffer(e.From),M(e.Fee)];return r.push(function(e){var r=new Array;return e.Ins&&e.Ins.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Anchor),s.toBuffer(e.Nil),s.toBuffer(e.Trace),s.toBuffer(e.AssetCM),s.toBuffer(m(e.Proof))]))}(e))})),e.Outs&&e.Outs.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.AssetCM),s.toBuffer(e.OutCM),s.toBuffer(e.EInfo),s.toBuffer(e.PKr),s.toBuffer(m(e.Proof))]))}(e))})),m(t.concat(r))}(e.Desc_Z)),r.push(function(e){var r=new Array;return e.Ins&&e.Ins.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Root),s.toBuffer(e.Nil),s.toBuffer(e.Sign)]))}(e))})),e.Outs&&e.Outs.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Addr),A(e.Asset),s.toBuffer(e.Memo)]))}(e))})),m(t.concat(r))}(e.Desc_O)),0r.length)throw new Error("invalid rlp: total length is larger than the data");if(0===(s=r.slice(o,c)).length)throw new Error("invalid rlp, List has a invalid length");for(;s.length;)u=e(s),h.push(u.data),s=u.remainder;return{data:h,remainder:r.slice(c)}}(u(e));if(r)return i;if(0!==i.remainder.length)throw new Error("invalid remainder");return i.data},e.getLength=function(e){if(!e||0===e.length)return t.from([]);var r=u(e),i=r[0];if(i<=127)return r.length;if(i<=183)return i-127;if(i<=191)return i-182;if(i<=247)return i-191;var o=i-246;return o+n(r.slice(1,o).toString("hex"),16)}}).call(this,r(0).Buffer)},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(323).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0})}]); \ No newline at end of file diff --git a/docs/static/js/0.93946bfa.chunk.worker.js b/docs/static/js/1.8958a83b.chunk.worker.js similarity index 100% rename from docs/static/js/0.93946bfa.chunk.worker.js rename to docs/static/js/1.8958a83b.chunk.worker.js diff --git a/docs/static/js/1.c35c4076.chunk.worker.js b/docs/static/js/1.c35c4076.chunk.worker.js deleted file mode 100644 index 6622856..0000000 --- a/docs/static/js/1.c35c4076.chunk.worker.js +++ /dev/null @@ -1 +0,0 @@ -!function(t){var e={};function r(i){if(e[i])return e[i].exports;var n=e[i]={i:i,l:!1,exports:{}};return t[i].call(n.exports,n,n.exports,r),n.l=!0,n.exports}r.m=t,r.c=e,r.d=function(t,e,i){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},r.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)r.d(i,n,function(e){return t[e]}.bind(null,n));return i},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="./",r(r.s=145)}([function(t,e,r){"use strict";(function(t){var i=r(149),n=r(150),o=r(68);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(t,e){if(a()=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|t}function p(t,e){if(u.isBuffer(t))return t.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!==typeof t&&(t=""+t);var r=t.length;if(0===r)return 0;for(var i=!1;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":case void 0:return U(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return F(t).length;default:if(i)return U(t).length;e=(""+e).toLowerCase(),i=!0}}function m(t,e,r){var i=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===r||r>this.length)&&(r=this.length),r<=0)return"";if((r>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return C(this,e,r);case"utf8":case"utf-8":return E(this,e,r);case"ascii":return x(this,e,r);case"latin1":case"binary":return B(this,e,r);case"base64":return S(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,e,r);default:if(i)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),i=!0}}function g(t,e,r){var i=t[e];t[e]=t[r],t[r]=i}function b(t,e,r,i,n){if(0===t.length)return-1;if("string"===typeof r?(i=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(r)&&(r=n?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(n)return-1;r=t.length-1}else if(r<0){if(!n)return-1;r=0}if("string"===typeof e&&(e=u.from(e,i)),u.isBuffer(e))return 0===e.length?-1:v(t,e,r,i,n);if("number"===typeof e)return e&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):v(t,[e],r,i,n);throw new TypeError("val must be string, number or Buffer")}function v(t,e,r,i,n){var o,a=1,s=t.length,u=e.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(t.length<2||e.length<2)return-1;a=2,s/=2,u/=2,r/=2}function h(t,e){return 1===a?t[e]:t.readUInt16BE(e*a)}if(n){var f=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){for(var c=!0,l=0;ln&&(i=n):i=n;var o=e.length;if(o%2!==0)throw new TypeError("Invalid hex string");i>o/2&&(i=o/2);for(var a=0;a>8,n=r%256,o.push(n),o.push(i);return o}(e,t.length-r),t,r,i)}function S(t,e,r){return 0===e&&r===t.length?i.fromByteArray(t):i.fromByteArray(t.slice(e,r))}function E(t,e,r){r=Math.min(t.length,r);for(var i=[],n=e;n239?4:h>223?3:h>191?2:1;if(n+c<=r)switch(c){case 1:h<128&&(f=h);break;case 2:128===(192&(o=t[n+1]))&&(u=(31&h)<<6|63&o)>127&&(f=u);break;case 3:o=t[n+1],a=t[n+2],128===(192&o)&&128===(192&a)&&(u=(15&h)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(f=u);break;case 4:o=t[n+1],a=t[n+2],s=t[n+3],128===(192&o)&&128===(192&a)&&128===(192&s)&&(u=(15&h)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(f=u)}null===f?(f=65533,c=1):f>65535&&(f-=65536,i.push(f>>>10&1023|55296),f=56320|1023&f),i.push(f),n+=c}return function(t){var e=t.length;if(e<=k)return String.fromCharCode.apply(String,t);var r="",i=0;for(;i0&&(t=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(t+=" ... ")),""},u.prototype.compare=function(t,e,r,i,n){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===r&&(r=t?t.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),e<0||r>t.length||i<0||n>this.length)throw new RangeError("out of range index");if(i>=n&&e>=r)return 0;if(i>=n)return-1;if(e>=r)return 1;if(this===t)return 0;for(var o=(n>>>=0)-(i>>>=0),a=(r>>>=0)-(e>>>=0),s=Math.min(o,a),h=this.slice(i,n),f=t.slice(e,r),c=0;cn)&&(r=n),t.length>0&&(r<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var o=!1;;)switch(i){case"hex":return y(this,t,e,r);case"utf8":case"utf-8":return w(this,t,e,r);case"ascii":return _(this,t,e,r);case"latin1":case"binary":return M(this,t,e,r);case"base64":return A(this,t,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,e,r);default:if(o)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var k=4096;function x(t,e,r){var i="";r=Math.min(t.length,r);for(var n=e;ni)&&(r=i);for(var n="",o=e;or)throw new RangeError("Trying to access beyond buffer length")}function R(t,e,r,i,n,o){if(!u.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>n||et.length)throw new RangeError("Index out of range")}function O(t,e,r,i){e<0&&(e=65535+e+1);for(var n=0,o=Math.min(t.length-r,2);n>>8*(i?n:1-n)}function j(t,e,r,i){e<0&&(e=4294967295+e+1);for(var n=0,o=Math.min(t.length-r,4);n>>8*(i?n:3-n)&255}function D(t,e,r,i,n,o){if(r+i>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function N(t,e,r,i,o){return o||D(t,0,r,4),n.write(t,e,r,i,23,4),r+4}function z(t,e,r,i,o){return o||D(t,0,r,8),n.write(t,e,r,i,52,8),r+8}u.prototype.slice=function(t,e){var r,i=this.length;if((t=~~t)<0?(t+=i)<0&&(t=0):t>i&&(t=i),(e=void 0===e?i:~~e)<0?(e+=i)<0&&(e=0):e>i&&(e=i),e0&&(n*=256);)i+=this[t+--e]*n;return i},u.prototype.readUInt8=function(t,e){return e||P(t,1,this.length),this[t]},u.prototype.readUInt16LE=function(t,e){return e||P(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUInt16BE=function(t,e){return e||P(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUInt32LE=function(t,e){return e||P(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUInt32BE=function(t,e){return e||P(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readIntLE=function(t,e,r){t|=0,e|=0,r||P(t,e,this.length);for(var i=this[t],n=1,o=0;++o=(n*=128)&&(i-=Math.pow(2,8*e)),i},u.prototype.readIntBE=function(t,e,r){t|=0,e|=0,r||P(t,e,this.length);for(var i=e,n=1,o=this[t+--i];i>0&&(n*=256);)o+=this[t+--i]*n;return o>=(n*=128)&&(o-=Math.pow(2,8*e)),o},u.prototype.readInt8=function(t,e){return e||P(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function(t,e){e||P(t,2,this.length);var r=this[t]|this[t+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(t,e){e||P(t,2,this.length);var r=this[t+1]|this[t]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(t,e){return e||P(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,e){return e||P(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readFloatLE=function(t,e){return e||P(t,4,this.length),n.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,e){return e||P(t,4,this.length),n.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,e){return e||P(t,8,this.length),n.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,e){return e||P(t,8,this.length),n.read(this,t,!1,52,8)},u.prototype.writeUIntLE=function(t,e,r,i){(t=+t,e|=0,r|=0,i)||R(this,t,e,r,Math.pow(2,8*r)-1,0);var n=1,o=0;for(this[e]=255&t;++o=0&&(o*=256);)this[e+n]=t/o&255;return e+r},u.prototype.writeUInt8=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,1,255,0),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},u.prototype.writeUInt16LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):O(this,t,e,!0),e+2},u.prototype.writeUInt16BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):O(this,t,e,!1),e+2},u.prototype.writeUInt32LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):j(this,t,e,!0),e+4},u.prototype.writeUInt32BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):j(this,t,e,!1),e+4},u.prototype.writeIntLE=function(t,e,r,i){if(t=+t,e|=0,!i){var n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}var o=0,a=1,s=0;for(this[e]=255&t;++o>0)-s&255;return e+r},u.prototype.writeIntBE=function(t,e,r,i){if(t=+t,e|=0,!i){var n=Math.pow(2,8*r-1);R(this,t,e,r,n-1,-n)}var o=r-1,a=1,s=0;for(this[e+o]=255&t;--o>=0&&(a*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+r},u.prototype.writeInt8=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,1,127,-128),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},u.prototype.writeInt16LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):O(this,t,e,!0),e+2},u.prototype.writeInt16BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):O(this,t,e,!1),e+2},u.prototype.writeInt32LE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):j(this,t,e,!0),e+4},u.prototype.writeInt32BE=function(t,e,r){return t=+t,e|=0,r||R(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),u.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):j(this,t,e,!1),e+4},u.prototype.writeFloatLE=function(t,e,r){return N(this,t,e,!0,r)},u.prototype.writeFloatBE=function(t,e,r){return N(this,t,e,!1,r)},u.prototype.writeDoubleLE=function(t,e,r){return z(this,t,e,!0,r)},u.prototype.writeDoubleBE=function(t,e,r){return z(this,t,e,!1,r)},u.prototype.copy=function(t,e,r,i){if(r||(r=0),i||0===i||(i=this.length),e>=t.length&&(e=t.length),e||(e=0),i>0&&i=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),t.length-e=0;--n)t[n+e]=this[n+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(n=0;n>>=0,r=void 0===r?this.length:r>>>0,t||(t=0),"number"===typeof t)for(o=e;o55295&&r<57344){if(!n){if(r>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(a+1===i){(e-=3)>-1&&o.push(239,191,189);continue}n=r;continue}if(r<56320){(e-=3)>-1&&o.push(239,191,189),n=r;continue}r=65536+(n-55296<<10|r-56320)}else n&&(e-=3)>-1&&o.push(239,191,189);if(n=null,r<128){if((e-=1)<0)break;o.push(r)}else if(r<2048){if((e-=2)<0)break;o.push(r>>6|192,63&r|128)}else if(r<65536){if((e-=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((e-=4)<0)break;o.push(r>>18|240,r>>12&63|128,r>>6&63|128,63&r|128)}}return o}function F(t){return i.toByteArray(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(K,"")).length<2)return"";for(;t.length%4!==0;)t+="=";return t}(t))}function L(t,e,r,i){for(var n=0;n=e.length||n>=t.length);++n)e[n+r]=t[n];return n}}).call(this,r(10))},function(t,e){"function"===typeof Object.create?t.exports=function(t,e){e&&(t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}))}:t.exports=function(t,e){if(e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}}},function(t,e,r){var i=r(0),n=i.Buffer;function o(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=i:(o(i,e),e.Buffer=a),o(n,a),a.from=function(t,e,r){if("number"===typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},a.alloc=function(t,e,r){if("number"!==typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"===typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},a.allocUnsafe=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return n(t)},a.allocUnsafeSlow=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return i.SlowBuffer(t)}},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(19),n=r(152)("123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz"),o=r(69),a=r(154),s=r(155),u=r(157),h=r(158),f=r(164),c=r(4);function l(e){var r;if(e instanceof t)r=e;else if(g(e))r=t.from(o(e),"hex");else{if(!m(e))return e;r=n.decode(e)}return n.encode(r)}function d(t,e,r){return o(t)+new Array(e-o(t).length+1).join(r||"0")}function p(t,e,r){return new Array(e-o(t).length+1).join(r||"0")+o(t)}function m(t){return/^[123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{80,}$/i.test(t)}function g(t){return 0==t.indexOf("0x")&&(t=t.slice(2)),t.length%2==0&&/^(-)?[0-9a-f]*$/i.test(t)}function b(t){var e="";t=(t=(t=(t=(t=a.encode(t)).replace(/^(?:\u0000)*/,"")).split("").reverse().join("")).replace(/^(?:\u0000)*/,"")).split("").reverse().join("");for(var r=0;r>>4).toString(16)),e.push((15&t[r]).toString(16));return"0x"+e.join("")},hexToBytes:function(e){var r=t.from(o(e),"hex");return new Uint8Array(r)},utf8ToHex:b,bs58ToHex:function(t){return"0x"+n.decode(t).toString("hex")},bytesToBase58:function(t){return n.encode(t.buffer)},padLeft:p,padRight:d,bufferToHex:function(t){return"0x"+t.toString("hex")},cyToHex:function(t){return"0x"+p(b(t.toUpperCase()),64,"0")},hexToBN:function(t){return w(o(t))},hexToCy:y,toBN:w,isNotNull:function(t){return!u(t)&&void 0!==t},toBuffer:_,bufferToBN:function(t){return new i(t,"le")},isEmptyBuffer:function(e,r){return void 0===r&&(r=32),0==e.length||0==t.alloc(r).compare(e)},bufferToBs58:function(t){return n.encode(t)},addrToString:l};e.default=M}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(e){function i(t,e){if(t===e)return 0;for(var r=t.length,i=e.length,n=0,o=Math.min(r,i);n=0;h--)if(f[h]!==c[h])return!1;for(h=f.length-1;h>=0;h--)if(u=f[h],!v(t[u],e[u],r,i))return!1;return!0}(t,e,r,a))}return r?t===e:t==e}function y(t){return"[object Arguments]"==Object.prototype.toString.call(t)}function w(t,e){if(!t||!e)return!1;if("[object RegExp]"==Object.prototype.toString.call(e))return e.test(t);try{if(t instanceof e)return!0}catch(r){}return!Error.isPrototypeOf(e)&&!0===e.call({},t)}function _(t,e,r,i){var n;if("function"!==typeof e)throw new TypeError('"block" argument must be a function');"string"===typeof r&&(i=r,r=null),n=function(t){var e;try{t()}catch(r){e=r}return e}(e),i=(r&&r.name?" ("+r.name+").":".")+(i?" "+i:"."),t&&!n&&g(n,r,"Missing expected exception"+i);var a="string"===typeof i,s=!t&&n&&!r;if((!t&&o.isError(n)&&a&&w(n,r)||s)&&g(n,r,"Got unwanted exception"+i),t&&n&&r&&!w(n,r)||!t&&n)throw n}c.AssertionError=function(t){this.name="AssertionError",this.actual=t.actual,this.expected=t.expected,this.operator=t.operator,t.message?(this.message=t.message,this.generatedMessage=!1):(this.message=function(t){return p(m(t.actual),128)+" "+t.operator+" "+p(m(t.expected),128)}(this),this.generatedMessage=!0);var e=t.stackStartFunction||g;if(Error.captureStackTrace)Error.captureStackTrace(this,e);else{var r=new Error;if(r.stack){var i=r.stack,n=d(e),o=i.indexOf("\n"+n);if(o>=0){var a=i.indexOf("\n",o+1);i=i.substring(a+1)}this.stack=i}}},o.inherits(c.AssertionError,Error),c.fail=g,c.ok=b,c.equal=function(t,e,r){t!=e&&g(t,e,r,"==",c.equal)},c.notEqual=function(t,e,r){t==e&&g(t,e,r,"!=",c.notEqual)},c.deepEqual=function(t,e,r){v(t,e,!1)||g(t,e,r,"deepEqual",c.deepEqual)},c.deepStrictEqual=function(t,e,r){v(t,e,!0)||g(t,e,r,"deepStrictEqual",c.deepStrictEqual)},c.notDeepEqual=function(t,e,r){v(t,e,!1)&&g(t,e,r,"notDeepEqual",c.notDeepEqual)},c.notDeepStrictEqual=function t(e,r,i){v(e,r,!0)&&g(e,r,i,"notDeepStrictEqual",t)},c.strictEqual=function(t,e,r){t!==e&&g(t,e,r,"===",c.strictEqual)},c.notStrictEqual=function(t,e,r){t===e&&g(t,e,r,"!==",c.notStrictEqual)},c.throws=function(t,e,r){_(!0,t,e,r)},c.doesNotThrow=function(t,e,r){_(!1,t,e,r)},c.ifError=function(t){if(t)throw t};var M=Object.keys||function(t){var e=[];for(var r in t)a.call(t,r)&&e.push(r);return e}}).call(this,r(10))},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(224).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):r.strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(19),n=r(47),o=r(3),a=r(48),s=function(){function e(t){if(t instanceof e)this.n=t.n;else if(t instanceof i){var r=t;r.red?this.n=r:this.n=r.toRed(e.red)}else this.n=new i(t,"le").toRed(e.red)}return e.toFQ=function(t){return t instanceof e?t:new e(t)},e.prototype.add=function(t){return new e(this.n.redAdd(e.toFQ(t).n))},e.prototype.mul=function(t){return new e(this.n.redMul(e.toFQ(t).n))},e.prototype.sub=function(t){return new e(this.n.redSub(e.toFQ(t).n))},e.prototype.div=function(t){return new e(this.n.redMul(e.toFQ(t).n.redInvm()))},e.prototype.squared=function(){return new e(this.n.redSqr())},e.prototype.sqrt=function(){try{var t=this.n.redSqrt();return t?new e(t):void 0}catch(t){return}},e.prototype.pow=function(t){return new e(this.n.redPow(new i(t)))},e.prototype.nega=function(){return new e(this.n.redNeg())},e.prototype.inverse=function(){return new e(this.n.redInvm())},e.prototype.isOdd=function(){return this.n.fromRed().isOdd()},e.prototype.isZero=function(){return this.n.fromRed().isZero()},e.prototype.toBuffer=function(){return this.n.fromRed().toArrayLike(t,"le",32)},e.prototype.toBN=function(){return this.n.fromRed()},e.prototype.equal=function(t){return this.n.eq(t.n)},e.prototype.toString=function(t){return this.n.fromRed().toString(t)},e.red=i.mont(n.default.FQ_MODULUS),e.ONE=new e(1),e.ZERO=new e(0),e}();e.FQ=s;var u=function(){function e(t){if(t instanceof e)this.n=t.n;else if(t instanceof i){var r=t;r.red?this.n=r:this.n=r.toRed(e.red)}else this.n="number"==typeof t?new i(t).toRed(e.red):new i(t,"le").toRed(e.red)}return e.toFR=function(t){return t instanceof e?t:new e(t)},e.prototype.add=function(t){return new e(this.n.redAdd(e.toFR(t).n))},e.prototype.mul=function(t){return new e(this.n.redMul(e.toFR(t).n))},e.prototype.sub=function(t){return new e(this.n.redSub(e.toFR(t).n))},e.prototype.div=function(t){return new e(this.n.redMul(e.toFR(t).n.redInvm()))},e.prototype.squared=function(){return new e(this.n.redSqr())},e.prototype.sqrt=function(){try{var t=this.n.redSqrt();return t?new e(t):void 0}catch(t){return}},e.prototype.pow=function(t){return new e(this.n.redPow(new i(t)))},e.prototype.nega=function(){return new e(this.n.redNeg())},e.prototype.inverse=function(){return new e(this.n.redInvm())},e.prototype.isOdd=function(){return this.n.fromRed().isOdd()},e.prototype.isZero=function(){return this.n.fromRed().isZero()},e.prototype.toBuffer=function(){return this.n.fromRed().toArrayLike(t,"le",32)},e.prototype.toBN=function(){return this.n.fromRed()},e.prototype.equal=function(t){return this.n.eq(t.n)},e.prototype.toString=function(t){return this.n.fromRed().toString(t)},e.red=i.mont(n.default.FR_MODULUS),e.ONE=new e(1),e.ZERO=new e(0),e}();function h(t){if(t instanceof u)return t;var e=o.toBuffer(t);return new u(e)}e.FR=u,e.newFR=h,e.randomFR=function(){return h(a.randomBytes(32))}}).call(this,r(0).Buffer)},function(t,e,r){var i=r(0),n=i.Buffer;function o(t,e){for(var r in t)e[r]=t[r]}function a(t,e,r){return n(t,e,r)}n.from&&n.alloc&&n.allocUnsafe&&n.allocUnsafeSlow?t.exports=i:(o(i,e),e.Buffer=a),a.prototype=Object.create(n.prototype),o(n,a),a.from=function(t,e,r){if("number"===typeof t)throw new TypeError("Argument must not be a number");return n(t,e,r)},a.alloc=function(t,e,r){if("number"!==typeof t)throw new TypeError("Argument must be a number");var i=n(t);return void 0!==e?"string"===typeof r?i.fill(e,r):i.fill(e):i.fill(0),i},a.allocUnsafe=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return n(t)},a.allocUnsafeSlow=function(t){if("number"!==typeof t)throw new TypeError("Argument must be a number");return i.SlowBuffer(t)}},function(t,e){var r,i,n=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(t){if(r===setTimeout)return setTimeout(t,0);if((r===o||!r)&&setTimeout)return r=setTimeout,setTimeout(t,0);try{return r(t,0)}catch(e){try{return r.call(null,t,0)}catch(e){return r.call(this,t,0)}}}!function(){try{r="function"===typeof setTimeout?setTimeout:o}catch(t){r=o}try{i="function"===typeof clearTimeout?clearTimeout:a}catch(t){i=a}}();var u,h=[],f=!1,c=-1;function l(){f&&u&&(f=!1,u.length?h=u.concat(h):c=-1,h.length&&d())}function d(){if(!f){var t=s(l);f=!0;for(var e=h.length;e;){for(u=h,h=[];++c1)for(var r=1;r>7&1,u=t.from(n);u[31]&=-129;var h=new i.FQ(u),f=h.mul(h),c=e.ECC_D.mul(f),l=f.sub(i.FQ.ONE).mul(c.sub(e.ECC_A).inverse()).sqrt();if(l){var d=l;return l.isOdd()!==(0!=s)&&(d=i.FQ.ZERO.sub(l)),new e(d,h)}},e.ECC_A=new i.FQ(n.default.ECC_A),e.ECC_D=new i.FQ(n.default.ECC_D),e.ZERO=new e(i.FQ.ZERO,i.FQ.ONE),e}(),u=function(){function t(t,e,r){this.x=new i.FQ(t),this.y=new i.FQ(e),this.z=new i.FQ(r)}return t.prototype.toOriPoint=function(){var t=this.z.inverse();return new s(this.x.mul(t),this.y.mul(t))},t.prototype.add=function(e){var r=this.x,n=this.y,o=this.z,a=e.x,u=e.y,h=e.z,f=r.mul(a),c=n.mul(u),l=s.ECC_D.mul(f).mul(c);if(o.equal(i.FQ.ONE)&&h.equal(i.FQ.ONE))return new t(i.FQ.ONE.sub(l).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),i.FQ.ONE.add(l).mul(c.sub(s.ECC_A.mul(f))),i.FQ.ONE.sub(l.squared()));if(h.equal(i.FQ.ONE)){var d=(m=o.squared()).sub(l),p=m.add(l);return new t(o.mul(d).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),o.mul(p).mul(c.sub(s.ECC_A.mul(f))),d.mul(p))}var m,g=o.mul(h);return d=(m=g.squared()).sub(l),p=m.add(l),new t(g.mul(d).mul(r.add(n).mul(a.add(u)).sub(f).sub(c)),g.mul(p).mul(c.sub(s.ECC_A.mul(f))),d.mul(p))},t.prototype.double=function(){var e=this.x.add(this.y).squared(),r=this.x.squared(),n=this.y.squared(),o=s.ECC_A.mul(r),a=o.add(n);if(this.z.equal(i.FQ.ONE))return new t(e.sub(r).sub(n).mul(a.sub(2)),a.mul(o.sub(n)),a.squared().sub(a.mul(2)));var u=this.z.squared(),h=a.sub(u.mul(2));return new t(e.sub(r).sub(n).mul(h),a.mul(o.sub(n)),a.mul(h))},t.prototype.mult=function(e){for(var r=e.toBN(),i=this,n=t.ZERO;!r.isZero()&&(r.testn(0)&&(n=n.add(i)),!(r=r.shrn(1)).isZero());)i=i.double();return n},t.prototype.isValid=function(){var t=this.x.mul(this.x),e=this.y.mul(this.y),r=this.z.mul(this.z),i=s.ECC_A.mul(t),n=r.mul(r),o=s.ECC_D.mul(t).mul(e),a=r.mul(i.add(e)),u=n.add(o);return!!a.equal(u)},t.prototype.isEqualTo=function(t){return!(!this.x.mul(t.z).equal(this.z.mul(t.x))||!this.y.mul(t.z).equal(this.z.mul(t.y)))},t.prototype.isZero=function(){return this.isEqualTo(s.ZERO.toPoint())},t.prototype.toBuffer=function(){return this.toOriPoint().toBuffer()},t.prototype.toHex=function(){return this.toBuffer().reverse().toString("hex")},t.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},t.bufferTo=function(t){var e=s.bufferTo(t);return e?e.toPoint():void 0},t.ZERO=new t(new i.FQ(0),new i.FQ(1),new i.FQ(1)),t}();e.Point=u,e.newPoint=function(t){return t instanceof u?t:u.bufferTo(t)}}).call(this,r(0).Buffer)},function(t,e){function r(t,e){if(!t)throw new Error(e||"Assertion failed")}t.exports=r,r.equal=function(t,e,r){if(t!=e)throw new Error(r||"Assertion failed: "+t+" != "+e)}},function(t,e,r){"use strict";var i=e,n=r(5),o=r(13),a=r(103);i.assert=o,i.toArray=a.toArray,i.zero2=a.zero2,i.toHex=a.toHex,i.encode=a.encode,i.getNAF=function(t,e){for(var r=[],i=1<=0;){var o;if(n.isOdd()){var a=n.andln(i-1);o=a>(i>>1)-1?(i>>1)-a:a,n.isubn(o)}else o=0;r.push(o);for(var s=0!==n.cmpn(0)&&0===n.andln(i-1)?e+1:1,u=1;u0||e.cmpn(-n)>0;){var o,a,s,u=t.andln(3)+i&3,h=e.andln(3)+n&3;if(3===u&&(u=-1),3===h&&(h=-1),0===(1&u))o=0;else o=3!==(s=t.andln(7)+i&7)&&5!==s||2!==h?u:-u;if(r[0].push(o),0===(1&h))a=0;else a=3!==(s=e.andln(7)+n&7)&&5!==s||2!==u?h:-h;r[1].push(a),2*i===o+1&&(i=1-i),2*n===a+1&&(n=1-n),t.iushrn(1),e.iushrn(1)}return r},i.cachedProperty=function(t,e,r){var i="_"+e;t.prototype[e]=function(){return void 0!==this[i]?this[i]:this[i]=r.call(this)}},i.parseBytes=function(t){return"string"===typeof t?i.toArray(t,"hex"):t},i.intFromLE=function(t){return new n(t,"hex","le")}},function(t,e,r){"use strict";var i=r(13),n=r(1);function o(t,e){return 55296===(64512&t.charCodeAt(e))&&(!(e<0||e+1>=t.length)&&56320===(64512&t.charCodeAt(e+1)))}function a(t){return(t>>>24|t>>>8&65280|t<<8&16711680|(255&t)<<24)>>>0}function s(t){return 1===t.length?"0"+t:t}function u(t){return 7===t.length?"0"+t:6===t.length?"00"+t:5===t.length?"000"+t:4===t.length?"0000"+t:3===t.length?"00000"+t:2===t.length?"000000"+t:1===t.length?"0000000"+t:t}e.inherits=n,e.toArray=function(t,e){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if("string"===typeof t)if(e){if("hex"===e)for((t=t.replace(/[^a-z0-9]+/gi,"")).length%2!==0&&(t="0"+t),n=0;n>6|192,r[i++]=63&a|128):o(t,n)?(a=65536+((1023&a)<<10)+(1023&t.charCodeAt(++n)),r[i++]=a>>18|240,r[i++]=a>>12&63|128,r[i++]=a>>6&63|128,r[i++]=63&a|128):(r[i++]=a>>12|224,r[i++]=a>>6&63|128,r[i++]=63&a|128)}else for(n=0;n>>0}return a},e.split32=function(t,e){for(var r=new Array(4*t.length),i=0,n=0;i>>24,r[n+1]=o>>>16&255,r[n+2]=o>>>8&255,r[n+3]=255&o):(r[n+3]=o>>>24,r[n+2]=o>>>16&255,r[n+1]=o>>>8&255,r[n]=255&o)}return r},e.rotr32=function(t,e){return t>>>e|t<<32-e},e.rotl32=function(t,e){return t<>>32-e},e.sum32=function(t,e){return t+e>>>0},e.sum32_3=function(t,e,r){return t+e+r>>>0},e.sum32_4=function(t,e,r,i){return t+e+r+i>>>0},e.sum32_5=function(t,e,r,i,n){return t+e+r+i+n>>>0},e.sum64=function(t,e,r,i){var n=t[e],o=i+t[e+1]>>>0,a=(o>>0,t[e+1]=o},e.sum64_hi=function(t,e,r,i){return(e+i>>>0>>0},e.sum64_lo=function(t,e,r,i){return e+i>>>0},e.sum64_4_hi=function(t,e,r,i,n,o,a,s){var u=0,h=e;return u+=(h=h+i>>>0)>>0)>>0)>>0},e.sum64_4_lo=function(t,e,r,i,n,o,a,s){return e+i+o+s>>>0},e.sum64_5_hi=function(t,e,r,i,n,o,a,s,u,h){var f=0,c=e;return f+=(c=c+i>>>0)>>0)>>0)>>0)>>0},e.sum64_5_lo=function(t,e,r,i,n,o,a,s,u,h){return e+i+o+s+h>>>0},e.rotr64_hi=function(t,e,r){return(e<<32-r|t>>>r)>>>0},e.rotr64_lo=function(t,e,r){return(t<<32-r|e>>>r)>>>0},e.shr64_hi=function(t,e,r){return t>>>r},e.shr64_lo=function(t,e,r){return(t<<32-r|e>>>r)>>>0}},function(t,e,r){var i=r(2).Buffer,n=r(22).Transform,o=r(23).StringDecoder;function a(t){n.call(this),this.hashMode="string"===typeof t,this.hashMode?this[t]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}r(1)(a,n),a.prototype.update=function(t,e,r){"string"===typeof t&&(t=i.from(t,e));var n=this._update(t);return this.hashMode?this:(r&&(n=this._toString(n,r)),n)},a.prototype.setAutoPadding=function(){},a.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},a.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},a.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},a.prototype._transform=function(t,e,r){var i;try{this.hashMode?this._update(t):this.push(this._update(t))}catch(n){i=n}finally{r(i)}},a.prototype._flush=function(t){var e;try{this.push(this.__final())}catch(r){e=r}t(e)},a.prototype._finalOrDigest=function(t){var e=this.__final()||i.alloc(0);return t&&(e=this._toString(e,t,!0)),e},a.prototype._toString=function(t,e,r){if(this._decoder||(this._decoder=new o(e),this._encoding=e),this._encoding!==e)throw new Error("can't switch encodings");var i=this._decoder.write(t);return r&&(i+=this._decoder.end()),i},t.exports=a},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(267);e.blake2b=function(e,r){var n=t.alloc(16,0);n.fill(e,0,e.length);var o=i(32,null,null,n).update(r).digest("binary");return t.from(o)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(117),n=r(270),o=r(3),a=r(4);e.accountBase=new i.Group("$SROKEYSGEN",1,256,4),e.crBase=new i.Group("SZK$ASSET$CR",1,256,4),e.rootBase=new i.Group("SZK$ROOTCM",10,128,4),e.genTknBase=function(e){e=o.toBuffer(e),a(32==e.length);var r=t.alloc(64,0);r.set(e,0);var i=n.findPoint("SZK$TKN",r);if(!i)throw new Error("find point error");return i},e.genTktBase=function(e,r){e=o.toBuffer(e),r=o.toBuffer(r),a(32==e.length),a(32==r.length);var i=t.concat([e,r]),s=n.findPoint("SZK$TKT",i);if(!s)throw new Error("find point error");return s}}).call(this,r(0).Buffer)},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(151).Buffer}catch(k){}function s(t,e,r){for(var n=0,o=Math.min(t.length,r),a=0,s=e;s=49&&h<=54?h-49+10:h>=17&&h<=22?h-17+10:h,a|=u}return i(!(240&a),"Invalid character in "+t),n}function u(t,e,r,n){for(var o=0,a=0,s=Math.min(t.length,r),u=e;u=49?h-49+10:h>=17?h-17+10:h,i(h>=0&&a"}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this._strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this._strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for?o.prototype[Symbol.for("nodejs.util.inspect.custom")]=f:o.prototype.inspect=f;var c=["","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],d=[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];o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?c[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var h=l[t],f=d[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modrn(f).toString(t);r=(p=p.idivn(f)).isZero()?m+r:c[h-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(t,e){return this.toArrayLike(a,t,e)}),o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)};function p(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r._strip()}o.prototype.toArrayLike=function(t,e,r){this._strip();var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0");var a=function(t,e){return t.allocUnsafe?t.allocUnsafe(e):new t(e)}(t,o);return this["_toArrayLike"+("le"===e?"LE":"BE")](a,n),a},o.prototype._toArrayLikeLE=function(t,e){for(var r=0,i=0,n=0,o=0;n>8&255),r>16&255),6===o?(r>24&255),i=0,o=0):(i=a>>>24,o+=2)}if(r=0&&(t[r--]=a>>8&255),r>=0&&(t[r--]=a>>16&255),6===o?(r>=0&&(t[r--]=a>>24&255),i=0,o=0):(i=a>>>24,o+=2)}if(r>=0)for(t[r--]=i;r>=0;)t[r--]=0},Math.clz32?o.prototype._countBits=function(t){return 32-Math.clz32(t)}:o.prototype._countBits=function(t){var e=t,r=0;return e>=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this._strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function g(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r._strip()}function b(t,e,r){return g(t,e,r)}function v(t,e){this.x=t,this.y=e}Math.imul||(m=p),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?m(this,t,e):r<63?p(this,t,e):r<1024?g(this,t,e):b(this,t,e)},v.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},v.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[n]=67108863&a}return 0!==r&&(this.words[n]=r,this.length++),e?this.ineg():this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n&1}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this._strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s._strip(),i._strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modrn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modrn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modrn=function(t){var e=t<0;e&&(t=-t),i(t<=67108863);for(var r=(1<<26)%t,n=0,o=this.length-1;o>=0;o--)n=(r*n+(0|this.words[o]))%t;return e?-n:n},o.prototype.modn=function(t){return this.modrn(t)},o.prototype.idivn=function(t){var e=t<0;e&&(t=-t),i(t<=67108863);for(var r=0,n=this.length-1;n>=0;n--){var o=(0|this.words[n])+67108864*r;this.words[n]=o/t|0,r=o%t}return this._strip(),e?this.ineg():this},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this._strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new S(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var y={k256:null,p224:null,p192:null,p25519:null};function w(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function _(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function M(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function I(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function S(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function E(t){S.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}w.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},w.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(t,e){t.iushrn(this.n,0,e)},w.prototype.imulK=function(t){return t.imul(this.k)},n(_,w),_.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},_.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(y[t])return y[t];var e;if("k256"===t)e=new _;else if("p224"===t)e=new M;else if("p192"===t)e=new A;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new I}return y[t]=e,e},S.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},S.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},S.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):(h(t,t.umod(this.m)._forceRed(this)),t)},S.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},S.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},S.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},S.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},S.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},S.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},S.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},S.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},S.prototype.isqr=function(t){return this.imul(t,t.clone())},S.prototype.sqr=function(t){return this.mul(t,t)},S.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},S.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},S.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new E(t)},n(E,S),E.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},E.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},E.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},E.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},E.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e,r){"use strict";var i=r(38),n=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};t.exports=c;var o=r(32);o.inherits=r(1);var a=r(83),s=r(51);o.inherits(c,a);for(var u=n(s.prototype),h=0;ho)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(t);if(t>0)if(t>n)for(var u=0;u>5===6?2:t>>4===14?3:t>>3===30?4:t>>6===2?-1:-2}function s(t){var e=this.lastTotal-this.lastNeed,r=function(t,e,r){if(128!==(192&e[0]))return t.lastNeed=0,"\ufffd";if(t.lastNeed>1&&e.length>1){if(128!==(192&e[1]))return t.lastNeed=1,"\ufffd";if(t.lastNeed>2&&e.length>2&&128!==(192&e[2]))return t.lastNeed=2,"\ufffd"}}(this,t);return void 0!==r?r:this.lastNeed<=t.length?(t.copy(this.lastChar,e,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(t.copy(this.lastChar,e,0,t.length),void(this.lastNeed-=t.length))}function u(t,e){if((t.length-e)%2===0){var r=t.toString("utf16le",e);if(r){var i=r.charCodeAt(r.length-1);if(i>=55296&&i<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1],r.slice(0,-1)}return r}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=t[t.length-1],t.toString("utf16le",e,t.length-1)}function h(t){var e=t&&t.length?this.write(t):"";if(this.lastNeed){var r=this.lastTotal-this.lastNeed;return e+this.lastChar.toString("utf16le",0,r)}return e}function f(t,e){var r=(t.length-e)%3;return 0===r?t.toString("base64",e):(this.lastNeed=3-r,this.lastTotal=3,1===r?this.lastChar[0]=t[t.length-1]:(this.lastChar[0]=t[t.length-2],this.lastChar[1]=t[t.length-1]),t.toString("base64",e,t.length-r))}function c(t){var e=t&&t.length?this.write(t):"";return this.lastNeed?e+this.lastChar.toString("base64",0,3-this.lastNeed):e}function l(t){return t.toString(this.encoding)}function d(t){return t&&t.length?this.write(t):""}e.StringDecoder=o,o.prototype.write=function(t){if(0===t.length)return"";var e,r;if(this.lastNeed){if(void 0===(e=this.fillLast(t)))return"";r=this.lastNeed,this.lastNeed=0}else r=0;return r=0)return n>0&&(t.lastNeed=n-1),n;if(--i=0)return n>0&&(t.lastNeed=n-2),n;if(--i=0)return n>0&&(2===n?n=0:t.lastNeed=n-3),n;return 0}(this,t,e);if(!this.lastNeed)return t.toString("utf8",e);this.lastTotal=r;var i=t.length-(r-this.lastNeed);return t.copy(this.lastChar,0,i),t.toString("utf8",e,i)},o.prototype.fillLast=function(t){if(this.lastNeed<=t.length)return t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);t.copy(this.lastChar,this.lastTotal-this.lastNeed,0,t.length),this.lastNeed-=t.length}},function(t,e,r){var i=r(2).Buffer;function n(t,e){this._block=i.alloc(t),this._finalSize=e,this._blockSize=t,this._len=0}n.prototype.update=function(t,e){"string"===typeof t&&(e=e||"utf8",t=i.from(t,e));for(var r=this._block,n=this._blockSize,o=t.length,a=this._len,s=0;s=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 i=(4294967295&r)>>>0,n=(r-i)/4294967296;this._block.writeUInt32BE(n,this._blockSize-8),this._block.writeUInt32BE(i,this._blockSize-4)}this._update(this._block);var o=this._hash();return t?o.toString(t):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(62),o=r(18),a=r(4),s=r(3),u=r(3);function h(t){t[t.length-1]|=64}function f(e){var r=t.from(e);return r[e.length-1]&=-65,r}function c(t){return 0!=(64&t[t.length-1])}e.SetFlag=h,e.ClearFlag=f,e.IsFlagSet=c;var l=function(){function e(t,e){this.ZPK=i.newPoint(t),this.VPK=i.newPoint(e)}return e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.ZPK.toBuffer(),0),e.fill(this.VPK.toBuffer(),32),h(e),e},e.prototype.toHex=function(){return"0x"+this.toBuffer().toString("hex")},e.prototype.toString=function(){return u.default.bufferToBs58(this.toBuffer())},e}();function d(t){if(t instanceof l)return t;var e=f(s.toBuffer(t));a(64==e.length);var r=i.Point.bufferTo(e.slice(0,32));if(r){var n=i.Point.bufferTo(e.slice(32));if(n)return new l(r,n)}}e.PK=l,e.newPK=d,e.tk2PK=function(t){t=n.newTK(t);var e=o.accountBase.mult(t.vsk);return new l(t.ZPK,e)},e.isPKValid=function(t){var e=s.toBuffer(t);return!!c(e)&&!!d(e)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i={};function n(t,e,r){r||(r=Error);var n=function(t){var r,i;function n(r,i,n){return t.call(this,function(t,r,i){return"string"===typeof e?e:e(t,r,i)}(r,i,n))||this}return i=t,(r=n).prototype=Object.create(i.prototype),r.prototype.constructor=r,r.__proto__=i,n}(r);n.prototype.name=r.name,n.prototype.code=t,i[t]=n}function o(t,e){if(Array.isArray(t)){var r=t.length;return t=t.map((function(t){return String(t)})),r>2?"one of ".concat(e," ").concat(t.slice(0,r-1).join(", "),", or ")+t[r-1]:2===r?"one of ".concat(e," ").concat(t[0]," or ").concat(t[1]):"of ".concat(e," ").concat(t[0])}return"of ".concat(e," ").concat(String(t))}n("ERR_INVALID_OPT_VALUE",(function(t,e){return'The value "'+e+'" is invalid for option "'+t+'"'}),TypeError),n("ERR_INVALID_ARG_TYPE",(function(t,e,r){var i,n,a,s;if("string"===typeof e&&(n="not ",e.substr(!a||a<0?0:+a,n.length)===n)?(i="must not be",e=e.replace(/^not /,"")):i="must be",function(t,e,r){return(void 0===r||r>t.length)&&(r=t.length),t.substring(r-e.length,r)===e}(t," argument"))s="The ".concat(t," ").concat(i," ").concat(o(e,"type"));else{var u=function(t,e,r){return"number"!==typeof r&&(r=0),!(r+e.length>t.length)&&-1!==t.indexOf(e,r)}(t,".")?"property":"argument";s='The "'.concat(t,'" ').concat(u," ").concat(i," ").concat(o(e,"type"))}return s+=". Received type ".concat(typeof r)}),TypeError),n("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),n("ERR_METHOD_NOT_IMPLEMENTED",(function(t){return"The "+t+" method is not implemented"})),n("ERR_STREAM_PREMATURE_CLOSE","Premature close"),n("ERR_STREAM_DESTROYED",(function(t){return"Cannot call "+t+" after a stream was destroyed"})),n("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),n("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),n("ERR_STREAM_WRITE_AFTER_END","write after end"),n("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),n("ERR_UNKNOWN_ENCODING",(function(t){return"Unknown encoding: "+t}),TypeError),n("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),t.exports.codes=i},function(t,e,r){"use strict";(function(e){var i=Object.keys||function(t){var e=[];for(var r in t)e.push(r);return e};t.exports=h;var n=r(130),o=r(134);r(9)(h,n);for(var a=i(o.prototype),s=0;s=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 i=(4294967295&r)>>>0,n=(r-i)/4294967296;this._block.writeUInt32BE(n,this._blockSize-8),this._block.writeUInt32BE(i,this._blockSize-4)}this._update(this._block);var o=this._hash();return t?o.toString(t):o},n.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=n},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e,r){"use strict";var i=r(1),n=r(49),o=r(52),a=r(53),s=r(16);function u(t){s.call(this,"digest"),this._hash=t}i(u,s),u.prototype._update=function(t){this._hash.update(t)},u.prototype._final=function(){return this._hash.digest()},t.exports=function(t){return"md5"===(t=t.toLowerCase())?new n:"rmd160"===t||"ripemd160"===t?new o:new u(a(t))}},function(t,e,r){"use strict";var i,n="object"===typeof Reflect?Reflect:null,o=n&&"function"===typeof n.apply?n.apply:function(t,e,r){return Function.prototype.apply.call(t,e,r)};i=n&&"function"===typeof n.ownKeys?n.ownKeys:Object.getOwnPropertySymbols?function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:function(t){return Object.getOwnPropertyNames(t)};var a=Number.isNaN||function(t){return t!==t};function s(){s.init.call(this)}t.exports=s,s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var u=10;function h(t){return void 0===t._maxListeners?s.defaultMaxListeners:t._maxListeners}function f(t,e,r,i){var n,o,a,s;if("function"!==typeof r)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof r);if(void 0===(o=t._events)?(o=t._events=Object.create(null),t._eventsCount=0):(void 0!==o.newListener&&(t.emit("newListener",e,r.listener?r.listener:r),o=t._events),a=o[e]),void 0===a)a=o[e]=r,++t._eventsCount;else if("function"===typeof a?a=o[e]=i?[r,a]:[a,r]:i?a.unshift(r):a.push(r),(n=h(t))>0&&a.length>n&&!a.warned){a.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+a.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=t,u.type=e,u.count=a.length,s=u,console&&console.warn&&console.warn(s)}return t}function c(){for(var t=[],e=0;e0&&(a=e[0]),a instanceof Error)throw a;var s=new Error("Unhandled error."+(a?" ("+a.message+")":""));throw s.context=a,s}var u=n[t];if(void 0===u)return!1;if("function"===typeof u)o(u,this,e);else{var h=u.length,f=m(u,h);for(r=0;r=0;o--)if(r[o]===e||r[o].listener===e){a=r[o].listener,n=o;break}if(n<0)return this;0===n?r.shift():function(t,e){for(;e+1=0;i--)this.removeListener(t,e[i]);return this},s.prototype.listeners=function(t){return d(this,t,!0)},s.prototype.rawListeners=function(t){return d(this,t,!1)},s.listenerCount=function(t,e){return"function"===typeof t.listenerCount?t.listenerCount(e):p.call(t,e)},s.prototype.listenerCount=p,s.prototype.eventNames=function(){return this._eventsCount>0?i(this._events):[]}},function(t,e,r){(function(t){function r(t){return Object.prototype.toString.call(t)}e.isArray=function(t){return Array.isArray?Array.isArray(t):"[object Array]"===r(t)},e.isBoolean=function(t){return"boolean"===typeof t},e.isNull=function(t){return null===t},e.isNullOrUndefined=function(t){return null==t},e.isNumber=function(t){return"number"===typeof t},e.isString=function(t){return"string"===typeof t},e.isSymbol=function(t){return"symbol"===typeof t},e.isUndefined=function(t){return void 0===t},e.isRegExp=function(t){return"[object RegExp]"===r(t)},e.isObject=function(t){return"object"===typeof t&&null!==t},e.isDate=function(t){return"[object Date]"===r(t)},e.isError=function(t){return"[object Error]"===r(t)||t instanceof Error},e.isFunction=function(t){return"function"===typeof t},e.isPrimitive=function(t){return null===t||"boolean"===typeof t||"number"===typeof t||"string"===typeof t||"symbol"===typeof t||"undefined"===typeof t},e.isBuffer=t.isBuffer}).call(this,r(0).Buffer)},function(t,e,r){(function(e){t.exports=function(t,r){for(var i=Math.min(t.length,r.length),n=new e(i),o=0;o=this._delta8){var r=(t=this.pending).length%this._delta8;this.pending=t.slice(t.length-r,t.length),0===this.pending.length&&(this.pending=null),t=i.join32(t,0,t.length-r,this.endian);for(var n=0;n>>24&255,i[n++]=t>>>16&255,i[n++]=t>>>8&255,i[n++]=255&t}else for(i[n++]=255&t,i[n++]=t>>>8&255,i[n++]=t>>>16&255,i[n++]=t>>>24&255,i[n++]=0,i[n++]=0,i[n++]=0,i[n++]=0,o=8;o>>24]^f[p>>>16&255]^c[m>>>8&255]^l[255&g]^e[b++],a=h[p>>>24]^f[m>>>16&255]^c[g>>>8&255]^l[255&d]^e[b++],s=h[m>>>24]^f[g>>>16&255]^c[d>>>8&255]^l[255&p]^e[b++],u=h[g>>>24]^f[d>>>16&255]^c[p>>>8&255]^l[255&m]^e[b++],d=o,p=a,m=s,g=u;return o=(i[d>>>24]<<24|i[p>>>16&255]<<16|i[m>>>8&255]<<8|i[255&g])^e[b++],a=(i[p>>>24]<<24|i[m>>>16&255]<<16|i[g>>>8&255]<<8|i[255&d])^e[b++],s=(i[m>>>24]<<24|i[g>>>16&255]<<16|i[d>>>8&255]<<8|i[255&p])^e[b++],u=(i[g>>>24]<<24|i[d>>>16&255]<<16|i[p>>>8&255]<<8|i[255&m])^e[b++],[o>>>=0,a>>>=0,s>>>=0,u>>>=0]}var s=[0,1,2,4,8,16,32,64,128,27,54],u=function(){for(var t=new Array(256),e=0;e<256;e++)t[e]=e<128?e<<1:e<<1^283;for(var r=[],i=[],n=[[],[],[],[]],o=[[],[],[],[]],a=0,s=0,u=0;u<256;++u){var h=s^s<<1^s<<2^s<<3^s<<4;h=h>>>8^255&h^99,r[a]=h,i[h]=a;var f=t[a],c=t[f],l=t[c],d=257*t[h]^16843008*h;n[0][a]=d<<24|d>>>8,n[1][a]=d<<16|d>>>16,n[2][a]=d<<8|d>>>24,n[3][a]=d,d=16843009*l^65537*c^257*f^16843008*a,o[0][h]=d<<24|d>>>8,o[1][h]=d<<16|d>>>16,o[2][h]=d<<8|d>>>24,o[3][h]=d,0===a?a=s=1:(a=f^t[t[t[l^f]]],s^=t[t[s]])}return{SBOX:r,INV_SBOX:i,SUB_MIX:n,INV_SUB_MIX:o}}();function h(t){this._key=n(t),this._reset()}h.blockSize=16,h.keySize=32,h.prototype.blockSize=h.blockSize,h.prototype.keySize=h.keySize,h.prototype._reset=function(){for(var t=this._key,e=t.length,r=e+6,i=4*(r+1),n=[],o=0;o>>24,a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a],a^=s[o/e|0]<<24):e>6&&o%e===4&&(a=u.SBOX[a>>>24]<<24|u.SBOX[a>>>16&255]<<16|u.SBOX[a>>>8&255]<<8|u.SBOX[255&a]),n[o]=n[o-e]^a}for(var h=[],f=0;f>>24]]^u.INV_SUB_MIX[1][u.SBOX[l>>>16&255]]^u.INV_SUB_MIX[2][u.SBOX[l>>>8&255]]^u.INV_SUB_MIX[3][u.SBOX[255&l]]}this._nRounds=r,this._keySchedule=n,this._invKeySchedule=h},h.prototype.encryptBlockRaw=function(t){return a(t=n(t),this._keySchedule,u.SUB_MIX,u.SBOX,this._nRounds)},h.prototype.encryptBlock=function(t){var e=this.encryptBlockRaw(t),r=i.allocUnsafe(16);return r.writeUInt32BE(e[0],0),r.writeUInt32BE(e[1],4),r.writeUInt32BE(e[2],8),r.writeUInt32BE(e[3],12),r},h.prototype.decryptBlock=function(t){var e=(t=n(t))[1];t[1]=t[3],t[3]=e;var r=a(t,this._invKeySchedule,u.INV_SUB_MIX,u.INV_SBOX,this._nRounds),o=i.allocUnsafe(16);return o.writeUInt32BE(r[0],0),o.writeUInt32BE(r[3],4),o.writeUInt32BE(r[2],8),o.writeUInt32BE(r[1],12),o},h.prototype.scrub=function(){o(this._keySchedule),o(this._invKeySchedule),o(this._key)},t.exports.AES=h},function(t,e,r){var i=r(2).Buffer,n=r(49);t.exports=function(t,e,r,o){if(i.isBuffer(t)||(t=i.from(t,"binary")),e&&(i.isBuffer(e)||(e=i.from(e,"binary")),8!==e.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var a=r/8,s=i.alloc(a),u=i.alloc(o||0),h=i.alloc(0);a>0||o>0;){var f=new n;f.update(h),f.update(t),e&&f.update(e),h=f.digest();var c=0;if(a>0){var l=s.length-a;c=Math.min(a,h.length),h.copy(s,l,0,c),a-=c}if(c0){var d=u.length-o,p=Math.min(o,h.length-c);h.copy(u,d,c,c+p),o-=p}}return h.fill(0),{key:s,iv:u}}},function(t,e,r){"use strict";var i=r(5),n=r(14),o=n.getNAF,a=n.getJSF,s=n.assert;function u(t,e){this.type=t,this.p=new i(e.p,16),this.red=e.prime?i.red(e.prime):i.mont(this.p),this.zero=new i(0).toRed(this.red),this.one=new i(1).toRed(this.red),this.two=new i(2).toRed(this.red),this.n=e.n&&new i(e.n,16),this.g=e.g&&this.pointFromJSON(e.g,e.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||r.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function h(t,e){this.curve=t,this.type=e,this.precomputed=null}t.exports=u,u.prototype.point=function(){throw new Error("Not implemented")},u.prototype.validate=function(){throw new Error("Not implemented")},u.prototype._fixedNafMul=function(t,e){s(t.precomputed);var r=t._getDoubles(),i=o(e,1),n=(1<=u;e--)h=(h<<1)+i[e];a.push(h)}for(var f=this.jpoint(null,null,null),c=this.jpoint(null,null,null),l=n;l>0;l--){for(u=0;u=0;h--){for(e=0;h>=0&&0===a[h];h--)e++;if(h>=0&&e++,u=u.dblp(e),h<0)break;var f=a[h];s(0!==f),u="affine"===t.type?f>0?u.mixedAdd(n[f-1>>1]):u.mixedAdd(n[-f-1>>1].neg()):f>0?u.add(n[f-1>>1]):u.add(n[-f-1>>1].neg())}return"affine"===t.type?u.toP():u},u.prototype._wnafMulAdd=function(t,e,r,i,n){for(var s=this._wnafT1,u=this._wnafT2,h=this._wnafT3,f=0,c=0;c=1;c-=2){var d=c-1,p=c;if(1===s[d]&&1===s[p]){var m=[e[d],null,null,e[p]];0===e[d].y.cmp(e[p].y)?(m[1]=e[d].add(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg())):0===e[d].y.cmp(e[p].y.redNeg())?(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].add(e[p].neg())):(m[1]=e[d].toJ().mixedAdd(e[p]),m[2]=e[d].toJ().mixedAdd(e[p].neg()));var g=[-3,-1,-5,-7,0,7,5,1,3],b=a(r[d],r[p]);f=Math.max(b[0].length,f),h[d]=new Array(f),h[p]=new Array(f);for(var v=0;v=0;c--){for(var A=0;c>=0;){var I=!0;for(v=0;v=0&&A++,_=_.dblp(A),c<0)break;for(v=0;v0?S=u[v][E-1>>1]:E<0&&(S=u[v][-E-1>>1].neg()),_="affine"===S.type?_.mixedAdd(S):_.add(S))}}for(c=0;c=Math.ceil((t.bitLength()+1)/e.step)},h.prototype._getDoubles=function(t,e){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var r=[this],i=this,n=0;no)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(t);if(t>0)if(t>n)for(var u=0;u>>32-e}function h(t,e,r,i,n,o,a){return u(t+(e&r|~e&i)+n+o|0,a)+e|0}function f(t,e,r,i,n,o,a){return u(t+(e&i|r&~i)+n+o|0,a)+e|0}function c(t,e,r,i,n,o,a){return u(t+(e^r^i)+n+o|0,a)+e|0}function l(t,e,r,i,n,o,a){return u(t+(r^(e|~i))+n+o|0,a)+e|0}i(s,n),s.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);var r=this._a,i=this._b,n=this._c,o=this._d;r=h(r,i,n,o,t[0],3614090360,7),o=h(o,r,i,n,t[1],3905402710,12),n=h(n,o,r,i,t[2],606105819,17),i=h(i,n,o,r,t[3],3250441966,22),r=h(r,i,n,o,t[4],4118548399,7),o=h(o,r,i,n,t[5],1200080426,12),n=h(n,o,r,i,t[6],2821735955,17),i=h(i,n,o,r,t[7],4249261313,22),r=h(r,i,n,o,t[8],1770035416,7),o=h(o,r,i,n,t[9],2336552879,12),n=h(n,o,r,i,t[10],4294925233,17),i=h(i,n,o,r,t[11],2304563134,22),r=h(r,i,n,o,t[12],1804603682,7),o=h(o,r,i,n,t[13],4254626195,12),n=h(n,o,r,i,t[14],2792965006,17),r=f(r,i=h(i,n,o,r,t[15],1236535329,22),n,o,t[1],4129170786,5),o=f(o,r,i,n,t[6],3225465664,9),n=f(n,o,r,i,t[11],643717713,14),i=f(i,n,o,r,t[0],3921069994,20),r=f(r,i,n,o,t[5],3593408605,5),o=f(o,r,i,n,t[10],38016083,9),n=f(n,o,r,i,t[15],3634488961,14),i=f(i,n,o,r,t[4],3889429448,20),r=f(r,i,n,o,t[9],568446438,5),o=f(o,r,i,n,t[14],3275163606,9),n=f(n,o,r,i,t[3],4107603335,14),i=f(i,n,o,r,t[8],1163531501,20),r=f(r,i,n,o,t[13],2850285829,5),o=f(o,r,i,n,t[2],4243563512,9),n=f(n,o,r,i,t[7],1735328473,14),r=c(r,i=f(i,n,o,r,t[12],2368359562,20),n,o,t[5],4294588738,4),o=c(o,r,i,n,t[8],2272392833,11),n=c(n,o,r,i,t[11],1839030562,16),i=c(i,n,o,r,t[14],4259657740,23),r=c(r,i,n,o,t[1],2763975236,4),o=c(o,r,i,n,t[4],1272893353,11),n=c(n,o,r,i,t[7],4139469664,16),i=c(i,n,o,r,t[10],3200236656,23),r=c(r,i,n,o,t[13],681279174,4),o=c(o,r,i,n,t[0],3936430074,11),n=c(n,o,r,i,t[3],3572445317,16),i=c(i,n,o,r,t[6],76029189,23),r=c(r,i,n,o,t[9],3654602809,4),o=c(o,r,i,n,t[12],3873151461,11),n=c(n,o,r,i,t[15],530742520,16),r=l(r,i=c(i,n,o,r,t[2],3299628645,23),n,o,t[0],4096336452,6),o=l(o,r,i,n,t[7],1126891415,10),n=l(n,o,r,i,t[14],2878612391,15),i=l(i,n,o,r,t[5],4237533241,21),r=l(r,i,n,o,t[12],1700485571,6),o=l(o,r,i,n,t[3],2399980690,10),n=l(n,o,r,i,t[10],4293915773,15),i=l(i,n,o,r,t[1],2240044497,21),r=l(r,i,n,o,t[8],1873313359,6),o=l(o,r,i,n,t[15],4264355552,10),n=l(n,o,r,i,t[6],2734768916,15),i=l(i,n,o,r,t[13],1309151649,21),r=l(r,i,n,o,t[4],4149444226,6),o=l(o,r,i,n,t[11],3174756917,10),n=l(n,o,r,i,t[2],718787259,15),i=l(i,n,o,r,t[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+i|0,this._c=this._c+n|0,this._d=this._d+o|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=o.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t},t.exports=s},function(t,e,r){(e=t.exports=r(83)).Stream=e,e.Readable=e,e.Writable=r(51),e.Duplex=r(20),e.Transform=r(86),e.PassThrough=r(194)},function(t,e,r){"use strict";(function(e,i,n){var o=r(38);function a(t){var e=this;this.next=null,this.entry=null,this.finish=function(){!function(t,e,r){var i=t.entry;t.entry=null;for(;i;){var n=i.callback;e.pendingcb--,n(r),i=i.next}e.corkedRequestsFree?e.corkedRequestsFree.next=t:e.corkedRequestsFree=t}(e,t)}}t.exports=v;var s,u=!e.browser&&["v0.10","v0.9."].indexOf(e.version.slice(0,5))>-1?i:o.nextTick;v.WritableState=b;var h=r(32);h.inherits=r(1);var f={deprecate:r(192)},c=r(84),l=r(2).Buffer,d=n.Uint8Array||function(){};var p,m=r(85);function g(){}function b(t,e){s=s||r(20),t=t||{};var i=e instanceof s;this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.writableObjectMode);var n=t.highWaterMark,h=t.writableHighWaterMark,f=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:i&&(h||0===h)?h:f,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var c=!1===t.decodeStrings;this.decodeStrings=!c,this.defaultEncoding=t.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(t){!function(t,e){var r=t._writableState,i=r.sync,n=r.writecb;if(function(t){t.writing=!1,t.writecb=null,t.length-=t.writelen,t.writelen=0}(r),e)!function(t,e,r,i,n){--e.pendingcb,r?(o.nextTick(n,i),o.nextTick(I,t,e),t._writableState.errorEmitted=!0,t.emit("error",i)):(n(i),t._writableState.errorEmitted=!0,t.emit("error",i),I(t,e))}(t,r,i,e,n);else{var a=M(r);a||r.corked||r.bufferProcessing||!r.bufferedRequest||_(t,r),i?u(w,t,r,a,n):w(t,r,a,n)}}(e,t)},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 a(this)}function v(t){if(s=s||r(20),!p.call(v,this)&&!(this instanceof s))return new v(t);this._writableState=new b(t,this),this.writable=!0,t&&("function"===typeof t.write&&(this._write=t.write),"function"===typeof t.writev&&(this._writev=t.writev),"function"===typeof t.destroy&&(this._destroy=t.destroy),"function"===typeof t.final&&(this._final=t.final)),c.call(this)}function y(t,e,r,i,n,o,a){e.writelen=i,e.writecb=a,e.writing=!0,e.sync=!0,r?t._writev(n,e.onwrite):t._write(n,o,e.onwrite),e.sync=!1}function w(t,e,r,i){r||function(t,e){0===e.length&&e.needDrain&&(e.needDrain=!1,t.emit("drain"))}(t,e),e.pendingcb--,i(),I(t,e)}function _(t,e){e.bufferProcessing=!0;var r=e.bufferedRequest;if(t._writev&&r&&r.next){var i=e.bufferedRequestCount,n=new Array(i),o=e.corkedRequestsFree;o.entry=r;for(var s=0,u=!0;r;)n[s]=r,r.isBuf||(u=!1),r=r.next,s+=1;n.allBuffers=u,y(t,e,!0,e.length,n,"",o.finish),e.pendingcb++,e.lastBufferedRequest=null,o.next?(e.corkedRequestsFree=o.next,o.next=null):e.corkedRequestsFree=new a(e),e.bufferedRequestCount=0}else{for(;r;){var h=r.chunk,f=r.encoding,c=r.callback;if(y(t,e,!1,e.objectMode?1:h.length,h,f,c),r=r.next,e.bufferedRequestCount--,e.writing)break}null===r&&(e.lastBufferedRequest=null)}e.bufferedRequest=r,e.bufferProcessing=!1}function M(t){return t.ending&&0===t.length&&null===t.bufferedRequest&&!t.finished&&!t.writing}function A(t,e){t._final((function(r){e.pendingcb--,r&&t.emit("error",r),e.prefinished=!0,t.emit("prefinish"),I(t,e)}))}function I(t,e){var r=M(e);return r&&(!function(t,e){e.prefinished||e.finalCalled||("function"===typeof t._final?(e.pendingcb++,e.finalCalled=!0,o.nextTick(A,t,e)):(e.prefinished=!0,t.emit("prefinish")))}(t,e),0===e.pendingcb&&(e.finished=!0,t.emit("finish"))),r}h.inherits(v,c),b.prototype.getBuffer=function(){for(var t=this.bufferedRequest,e=[];t;)e.push(t),t=t.next;return e},function(){try{Object.defineProperty(b.prototype,"buffer",{get:f.deprecate((function(){return this.getBuffer()}),"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch(t){}}(),"function"===typeof Symbol&&Symbol.hasInstance&&"function"===typeof Function.prototype[Symbol.hasInstance]?(p=Function.prototype[Symbol.hasInstance],Object.defineProperty(v,Symbol.hasInstance,{value:function(t){return!!p.call(this,t)||this===v&&(t&&t._writableState instanceof b)}})):p=function(t){return t instanceof this},v.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},v.prototype.write=function(t,e,r){var i,n=this._writableState,a=!1,s=!n.objectMode&&(i=t,l.isBuffer(i)||i instanceof d);return s&&!l.isBuffer(t)&&(t=function(t){return l.from(t)}(t)),"function"===typeof e&&(r=e,e=null),s?e="buffer":e||(e=n.defaultEncoding),"function"!==typeof r&&(r=g),n.ended?function(t,e){var r=new Error("write after end");t.emit("error",r),o.nextTick(e,r)}(this,r):(s||function(t,e,r,i){var n=!0,a=!1;return null===r?a=new TypeError("May not write null values to stream"):"string"===typeof r||void 0===r||e.objectMode||(a=new TypeError("Invalid non-string/buffer chunk")),a&&(t.emit("error",a),o.nextTick(i,a),n=!1),n}(this,n,t,r))&&(n.pendingcb++,a=function(t,e,r,i,n,o){if(!r){var a=function(t,e,r){t.objectMode||!1===t.decodeStrings||"string"!==typeof e||(e=l.from(e,r));return e}(e,i,n);i!==a&&(r=!0,n="buffer",i=a)}var s=e.objectMode?1:i.length;e.length+=s;var u=e.length-1))throw new TypeError("Unknown encoding: "+t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(v.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),v.prototype._write=function(t,e,r){r(new Error("_write() is not implemented"))},v.prototype._writev=null,v.prototype.end=function(t,e,r){var i=this._writableState;"function"===typeof t?(r=t,t=null,e=null):"function"===typeof e&&(r=e,e=null),null!==t&&void 0!==t&&this.write(t,e),i.corked&&(i.corked=1,this.uncork()),i.ending||i.finished||function(t,e,r){e.ending=!0,I(t,e),r&&(e.finished?o.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,i,r)},Object.defineProperty(v.prototype,"destroyed",{get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),v.prototype.destroy=m.destroy,v.prototype._undestroy=m.undestroy,v.prototype._destroy=function(t,e){this.end(),e(t)}}).call(this,r(8),r(190).setImmediate,r(10))},function(t,e,r){"use strict";var i=r(0).Buffer,n=r(1),o=r(82),a=new Array(16),s=[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],u=[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],h=[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],f=[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],c=[0,1518500249,1859775393,2400959708,2840853838],l=[1352829926,1548603684,1836072691,2053994217,0];function d(){o.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(t,e){return t<>>32-e}function m(t,e,r,i,n,o,a,s){return p(t+(e^r^i)+o+a|0,s)+n|0}function g(t,e,r,i,n,o,a,s){return p(t+(e&r|~e&i)+o+a|0,s)+n|0}function b(t,e,r,i,n,o,a,s){return p(t+((e|~r)^i)+o+a|0,s)+n|0}function v(t,e,r,i,n,o,a,s){return p(t+(e&i|r&~i)+o+a|0,s)+n|0}function y(t,e,r,i,n,o,a,s){return p(t+(e^(r|~i))+o+a|0,s)+n|0}n(d,o),d.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);for(var r=0|this._a,i=0|this._b,n=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,_=0|this._b,M=0|this._c,A=0|this._d,I=0|this._e,S=0;S<80;S+=1){var E,k;S<16?(E=m(r,i,n,o,d,t[s[S]],c[0],h[S]),k=y(w,_,M,A,I,t[u[S]],l[0],f[S])):S<32?(E=g(r,i,n,o,d,t[s[S]],c[1],h[S]),k=v(w,_,M,A,I,t[u[S]],l[1],f[S])):S<48?(E=b(r,i,n,o,d,t[s[S]],c[2],h[S]),k=b(w,_,M,A,I,t[u[S]],l[2],f[S])):S<64?(E=v(r,i,n,o,d,t[s[S]],c[3],h[S]),k=g(w,_,M,A,I,t[u[S]],l[3],f[S])):(E=y(r,i,n,o,d,t[s[S]],c[4],h[S]),k=m(w,_,M,A,I,t[u[S]],l[4],f[S])),r=d,d=o,o=p(n,10),n=i,i=E,w=I,I=A,A=p(M,10),M=_,_=k}var x=this._b+n+A|0;this._b=this._c+o+I|0,this._c=this._d+d+w|0,this._d=this._e+r+_|0,this._e=this._a+i+M|0,this._a=x},d.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=i.alloc?i.alloc(20):new i(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t},t.exports=d},function(t,e,r){(e=t.exports=function(t){t=t.toLowerCase();var r=e[t];if(!r)throw new Error(t+" is not supported (we accept pull requests)");return new r}).sha=r(199),e.sha1=r(200),e.sha224=r(201),e.sha256=r(87),e.sha384=r(202),e.sha512=r(88)},function(t,e,r){"use strict";e.utils=r(208),e.Cipher=r(209),e.DES=r(210),e.CBC=r(211),e.EDE=r(212)},function(t,e,r){var i=r(213),n=r(221),o=r(98);e.createCipher=e.Cipher=i.createCipher,e.createCipheriv=e.Cipheriv=i.createCipheriv,e.createDecipher=e.Decipher=n.createDecipher,e.createDecipheriv=e.Decipheriv=n.createDecipheriv,e.listCiphers=e.getCiphers=function(){return Object.keys(o)}},function(t,e,r){var i={ECB:r(214),CBC:r(215),CFB:r(216),CFB8:r(217),CFB1:r(218),OFB:r(219),CTR:r(96),GCM:r(96)},n=r(98);for(var o in n)n[o].module=i[n[o].mode];t.exports=n},function(t,e,r){var i;function n(t){this.rand=t}if(t.exports=function(t){return i||(i=new n(null)),i.generate(t)},t.exports.Rand=n,n.prototype.generate=function(t){return this._rand(t)},n.prototype._rand=function(t){if(this.rand.getBytes)return this.rand.getBytes(t);for(var e=new Uint8Array(t),r=0;r=0||!r.umod(t.prime1)||!r.umod(t.prime2);)r=new i(n(e));return r}t.exports=o,o.getr=a}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=e;i.version=r(230).version,i.utils=r(14),i.rand=r(57),i.curve=r(104),i.curves=r(60),i.ec=r(241),i.eddsa=r(245)},function(t,e,r){"use strict";var i,n=e,o=r(61),a=r(104),s=r(14).assert;function u(t){"short"===t.type?this.curve=new a.short(t):"edwards"===t.type?this.curve=new a.edwards(t):this.curve=new a.mont(t),this.g=this.curve.g,this.n=this.curve.n,this.hash=t.hash,s(this.g.validate(),"Invalid curve"),s(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function h(t,e){Object.defineProperty(n,t,{configurable:!0,enumerable:!0,get:function(){var r=new u(e);return Object.defineProperty(n,t,{configurable:!0,enumerable:!0,value:r}),r}})}n.PresetCurve=u,h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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"]}),h("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{i=r(240)}catch(f){i=void 0}h("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",i]})},function(t,e,r){var i=e;i.utils=r(15),i.common=r(34),i.sha=r(234),i.ripemd=r(238),i.hmac=r(239),i.sha1=i.sha.sha1,i.sha256=i.sha.sha256,i.sha224=i.sha.sha224,i.sha384=i.sha.sha384,i.sha512=i.sha.sha512,i.ripemd160=i.ripemd.ripemd160},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(17),n=r(6),o=r(12),a=r(18),s=r(3),u=r(4),h=r(25),f=function(){function e(t,e){this.zsk=n.newFR(t),this.vsk=n.newFR(e)}return e.prototype.isValid=function(){return!this.zsk.isZero()&&!this.vsk.isZero()},e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.zsk.toBuffer(),0),e.fill(this.vsk.toBuffer(),32),h.SetFlag(e),e},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function c(t){if(t instanceof f)return t;var e=s.toBuffer(t);return 64>>=8,t[e+1]=r,r>>>=8,t[e+2]=r,r>>>=8,t[e+3]=r},t.ROTATE=function(t,e){return t<>>32-e},t}(),i=t.alloc(16,0);i.fill(0),e.default=function(e,n){var o=new r(n,i,0),a=t.alloc(e.length);return o.encrypt(a,e),a}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(6),o=r(18),a=r(17),s=r(120),u=r(63),h=r(44),f=r(3),c=r(4),l=r(66);e.fetchKey=function(e,r){e=l.newTK(e),r=t.from(f.toBuffer(r)),c(32==r.length),64&r[31]&&(r[31]&=-65);var n=i.newPoint(r);if(n){var o=n.mult(e.vsk);return a.blake2b("CZERO.KEYS.KDF",o.toBuffer())}},e.genPKrKey=function(t,e){t=h.newPKr(t),e=n.newFR(e);var r=t.ZPK.mult(e),i=t.VPK.mult(e),o=r.toBuffer(),s=a.blake2b("CZERO.KEYS.KDF",i.toBuffer());return o[31]|=64,{key:s,rpk:o}},e.signByPKr=function(t,e,r){if(e=f.toBuffer(e),t=l.newSK(t),r=h.newPKr(r),c(32==e.length),e&&0!=e.length&&t.isValid()&&r.isValid()){var i=r.BASE.add(o.accountBase.points.get(0));return u.sign(e,t.vsk.mul(t.zsk),i)}},e.verifyByPKr=function(t,e,r){if(t=f.toBuffer(t),e=f.toBuffer(e),r=h.newPKr(r),c(32==t.length),!t||0==t.length||!e||0==e.length||!r.isValid())return!1;var i=r.BASE.add(o.accountBase.points.get(0));return u.verify(t,e,r.VPK,i)},e.genNil=function(t,e){if(t=l.newSK(t),e=i.newPoint(e),t.isValid()&&e.isValid())return e.mult(t.vsk.mul(t.zsk))},e.signNil=function(t,e,r,n){if(t=f.toBuffer(t),e=l.newSK(e),r=h.newPKr(r),n=i.newPoint(n),c(32==t.length),t&&0!=t.length&&e.isValid()&&r.isValid()&&n.isValid()){var a=r.BASE.add(o.accountBase.points.get(0));return s.sign(t,e.vsk.mul(e.zsk),a,n)}},e.verifyNil=function(t,e,r,n,a){if(t=f.toBuffer(t),e=f.toBuffer(e),r=i.newPoint(r),n=h.newPKr(n),a=i.newPoint(a),c(32==t.length),c(96==e.length),!(t&&0!=t.length&&e&&0!=e.length&&n.isValid()&&a.isValid()))return!1;var u=n.BASE.add(o.accountBase.points.get(0));return s.verify(t,e,n.VPK,r,u,a)},e.genTrace=function(t,e){if(t=l.newTK(t),e=i.newPoint(e),t.isValid()&&e.isValid())return e.mult(t.vsk)},e.isMyPKr=function(t,e){if(t=l.newTK(t),e=h.newPKr(e),!t.isValid()||!e.isValid())return!1;var r=e.ZPK.add(t.ZPK.mult(n.FR.ONE.nega())).mult(t.vsk),i=e.VPK.add(t.ZPK.mult(t.vsk.mul(n.FR.ONE.nega())));return r.isEqualTo(i)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(17),n=r(6),o=r(12),a=r(18),s=r(3),u=r(4),h=function(){function e(t,e){this.zsk=n.newFR(t),this.vsk=n.newFR(e)}return e.prototype.isValid=function(){return!this.zsk.isZero()&&!this.vsk.isZero()},e.prototype.toBuffer=function(){var e=t.alloc(64);return e.fill(this.zsk.toBuffer(),0),e.fill(this.vsk.toBuffer(),32),e},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function f(t){if(t instanceof h)return t;var e=s.toBuffer(t);return 64=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};i.forEach(["delete","get","head"],(function(t){s.headers[t]={}})),i.forEach(["post","put","patch"],(function(t){s.headers[t]=i.merge(o)})),t.exports=s}).call(this,r(8))},function(t,e,r){"use strict";var i=r(11),n=r(176),o=r(74),a=r(178),s=r(179),u=r(78);t.exports=function(t){return new Promise((function(e,h){var f=t.data,c=t.headers;i.isFormData(f)&&delete c["Content-Type"];var l=new XMLHttpRequest;if(t.auth){var d=t.auth.username||"",p=t.auth.password||"";c.Authorization="Basic "+btoa(d+":"+p)}if(l.open(t.method.toUpperCase(),o(t.url,t.params,t.paramsSerializer),!0),l.timeout=t.timeout,l.onreadystatechange=function(){if(l&&4===l.readyState&&(0!==l.status||l.responseURL&&0===l.responseURL.indexOf("file:"))){var r="getAllResponseHeaders"in l?a(l.getAllResponseHeaders()):null,i={data:t.responseType&&"text"!==t.responseType?l.response:l.responseText,status:l.status,statusText:l.statusText,headers:r,config:t,request:l};n(e,h,i),l=null}},l.onabort=function(){l&&(h(u("Request aborted",t,"ECONNABORTED",l)),l=null)},l.onerror=function(){h(u("Network Error",t,null,l)),l=null},l.ontimeout=function(){h(u("timeout of "+t.timeout+"ms exceeded",t,"ECONNABORTED",l)),l=null},i.isStandardBrowserEnv()){var m=r(180),g=(t.withCredentials||s(t.url))&&t.xsrfCookieName?m.read(t.xsrfCookieName):void 0;g&&(c[t.xsrfHeaderName]=g)}if("setRequestHeader"in l&&i.forEach(c,(function(t,e){"undefined"===typeof f&&"content-type"===e.toLowerCase()?delete c[e]:l.setRequestHeader(e,t)})),t.withCredentials&&(l.withCredentials=!0),t.responseType)try{l.responseType=t.responseType}catch(b){if("json"!==t.responseType)throw b}"function"===typeof t.onDownloadProgress&&l.addEventListener("progress",t.onDownloadProgress),"function"===typeof t.onUploadProgress&&l.upload&&l.upload.addEventListener("progress",t.onUploadProgress),t.cancelToken&&t.cancelToken.promise.then((function(t){l&&(l.abort(),h(t),l=null)})),void 0===f&&(f=null),l.send(f)}))}},function(t,e,r){"use strict";var i=r(177);t.exports=function(t,e,r,n,o){var a=new Error(t);return i(a,e,r,n,o)}},function(t,e,r){"use strict";var i=r(11);t.exports=function(t,e){e=e||{};var r={};return i.forEach(["url","method","params","data"],(function(t){"undefined"!==typeof e[t]&&(r[t]=e[t])})),i.forEach(["headers","auth","proxy"],(function(n){i.isObject(e[n])?r[n]=i.deepMerge(t[n],e[n]):"undefined"!==typeof e[n]?r[n]=e[n]:i.isObject(t[n])?r[n]=i.deepMerge(t[n]):"undefined"!==typeof t[n]&&(r[n]=t[n])})),i.forEach(["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","maxContentLength","validateStatus","maxRedirects","httpAgent","httpsAgent","cancelToken","socketPath"],(function(i){"undefined"!==typeof e[i]?r[i]=e[i]:"undefined"!==typeof t[i]&&(r[i]=t[i])})),r}},function(t,e,r){"use strict";function i(t){this.message=t}i.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},i.prototype.__CANCEL__=!0,t.exports=i},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(3),n=r(46),o=r(37),a=r(65),s=r(273),u=r(275),h=r(122),f=r(44);e.decOut=function(t,e){var r=new Array;return e.forEach((function(e){var o,s={},u=!1;s.Nils=new Array;var h=e.State.OS;if(h.Out_O)s.Asset=l(h.Out_O.Asset),s.Memo=h.Out_O.Memo,s.Nils.push(e.Root),s.Nils.push(i.toString(a.genTrace(t,h.RootCM))),o=h.Out_O.Addr;else if(h.Out_Z)null!==(c=d(i.toString(a.fetchKey(t,h.Out_Z.RPK)),h.Out_Z.EInfo,h.Out_Z.PKr,h.Out_Z.OutCM))&&(s.Asset=c.Asset,s.Memo=c.Memo,s.Nils.push(i.toString(a.genTrace(t,h.RootCM))),o=h.Out_Z.PKr,u=!0);else if(h.Out_P){var f=i.toString(n.genNil(t,h.RootCM,h.Out_P.PKr));s.Asset=l(h.Out_P.Asset),s.Memo=h.Out_P.Memo,s.Nils.push(f),o=h.Out_P.PKr}else{if(!h.Out_C)throw new Error("invalid out type");var c;null!==(c=p(i.toString(n.fetchRPKKey(h.Out_C.PKr,t,h.Out_C.RPK)),h.Out_C.EInfo,h.Out_C.AssetCM))&&(s.Asset=c.Asset,s.Memo=c.Memo,s.Nils.push(i.toString(n.genNil(t,h.RootCM,h.Out_C.PKr))),o=h.Out_C.PKr,u=!0)}if(o){var m={};m.Root=e.Root,m.State=e.State,m.Pkr=i.default.addrToString(o),m.Asset=s.Asset,m.Num=e.State.Num,m.Memo=s.Memo,m.Nils=s.Nils,m.IsZ=u,m.TxHash=e.State.TxHash,r.push(m)}})),r};var c=t.alloc(32,0);function l(e){var r={};return e instanceof o.Asset?(0!=t.compare(e.tkn_currency,c)&&(r.Tkn={Currency:i.toString(e.tkn_currency),Value:i.default.bufferToBN(e.tkn_value.toBuffer()).toString()}),0!=t.compare(e.tkt_value,c)&&(r.Tkt={Category:i.toString(e.tkt_category),Value:i.toString(e.tkt_value)})):(e.Tkn&&0!==t.compare(i.toBuffer(e.Tkn.Currency),c)&&(r.Tkn={Currency:e.Tkn.Currency,Value:i.default.toBN(e.Tkn.Value).toString(10)}),e.Tkt&&0!=t.compare(i.toBuffer(e.Tkt.Value),c)&&(r.Tkt={Category:e.Tkt.Category,Value:e.Tkt.Value})),r}function d(t,e,r,n){t=i.toBuffer(t),e=i.toBuffer(e),r=f.newPKr(r),n=i.toBuffer(n);var o=u.decEInfo(e,t,!0),a=s.genOutCm(o.asset,o.memo,o.rsk,r);return a?0!=a.toBuffer().compare(n)?null:{Asset:l(o.asset),Memo:i.toString(o.memo),Nils:new Array}:null}function p(t,e,r){t=i.toBuffer(t),e=i.toBuffer(e),r=i.toBuffer(r);var n=h.decEInfo(t,e),a=i.toString(n.ar);return 0!=o.genAssetCM(n.asset,a).toBuffer().compare(r)?null:{Asset:l(n.asset),Memo:i.toString(n.memo),Nils:new Array}}e.confirmOutZ=d,e.confirmOutC=p}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=r(2).Buffer,n=r(22).Transform;function o(t){n.call(this),this._block=i.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(1)(o,n),o.prototype._transform=function(t,e,r){var i=null;try{this.update(t,e)}catch(n){i=n}r(i)},o.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(r){e=r}t(e)},o.prototype.update=function(t,e){if(function(t,e){if(!i.isBuffer(t)&&"string"!==typeof t)throw new TypeError(e+" must be a string or a buffer")}(t,"Data"),this._finalized)throw new Error("Digest already called");i.isBuffer(t)||(t=i.from(t,e));for(var r=this._block,n=0;this._blockOffset+t.length-n>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();void 0!==t&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return e},o.prototype._digest=function(){throw new Error("_digest is not implemented")},t.exports=o},function(t,e,r){"use strict";(function(e,i){var n=r(38);t.exports=y;var o,a=r(68);y.ReadableState=v;r(31).EventEmitter;var s=function(t,e){return t.listeners(e).length},u=r(84),h=r(2).Buffer,f=e.Uint8Array||function(){};var c=r(32);c.inherits=r(1);var l=r(187),d=void 0;d=l&&l.debuglog?l.debuglog("stream"):function(){};var p,m=r(188),g=r(85);c.inherits(y,u);var b=["error","close","destroy","pause","resume"];function v(t,e){t=t||{};var i=e instanceof(o=o||r(20));this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.readableObjectMode);var n=t.highWaterMark,a=t.readableHighWaterMark,s=this.objectMode?16:16384;this.highWaterMark=n||0===n?n:i&&(a||0===a)?a:s,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new m,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=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(p||(p=r(23).StringDecoder),this.decoder=new p(t.encoding),this.encoding=t.encoding)}function y(t){if(o=o||r(20),!(this instanceof y))return new y(t);this._readableState=new v(t,this),this.readable=!0,t&&("function"===typeof t.read&&(this._read=t.read),"function"===typeof t.destroy&&(this._destroy=t.destroy)),u.call(this)}function w(t,e,r,i,n){var o,a=t._readableState;null===e?(a.reading=!1,function(t,e){if(e.ended)return;if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,I(t)}(t,a)):(n||(o=function(t,e){var r;i=e,h.isBuffer(i)||i instanceof f||"string"===typeof e||void 0===e||t.objectMode||(r=new TypeError("Invalid non-string/buffer chunk"));var i;return r}(a,e)),o?t.emit("error",o):a.objectMode||e&&e.length>0?("string"===typeof e||a.objectMode||Object.getPrototypeOf(e)===h.prototype||(e=function(t){return h.from(t)}(e)),i?a.endEmitted?t.emit("error",new Error("stream.unshift() after end event")):_(t,a,e,!0):a.ended?t.emit("error",new Error("stream.push() after EOF")):(a.reading=!1,a.decoder&&!r?(e=a.decoder.write(e),a.objectMode||0!==e.length?_(t,a,e,!1):E(t,a)):_(t,a,e,!1))):i||(a.reading=!1));return function(t){return!t.ended&&(t.needReadable||t.lengthe.highWaterMark&&(e.highWaterMark=function(t){return t>=M?t=M:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function I(t){var e=t._readableState;e.needReadable=!1,e.emittedReadable||(d("emitReadable",e.flowing),e.emittedReadable=!0,e.sync?n.nextTick(S,t):S(t))}function S(t){d("emit readable"),t.emit("readable"),C(t)}function E(t,e){e.readingMore||(e.readingMore=!0,n.nextTick(k,t,e))}function k(t,e){for(var r=e.length;!e.reading&&!e.flowing&&!e.ended&&e.length=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.head.data:e.buffer.concat(e.length),e.buffer.clear()):r=function(t,e,r){var i;to.length?o.length:t;if(a===o.length?n+=o:n+=o.slice(0,t),0===(t-=a)){a===o.length?(++i,r.next?e.head=r.next:e.head=e.tail=null):(e.head=r,r.data=o.slice(a));break}++i}return e.length-=i,n}(t,e):function(t,e){var r=h.allocUnsafe(t),i=e.head,n=1;i.data.copy(r),t-=i.data.length;for(;i=i.next;){var o=i.data,a=t>o.length?o.length:t;if(o.copy(r,r.length-t,0,a),0===(t-=a)){a===o.length?(++n,i.next?e.head=i.next:e.head=e.tail=null):(e.head=i,i.data=o.slice(a));break}++n}return e.length-=n,r}(t,e);return i}(t,e.buffer,e.decoder),r);var r}function P(t){var e=t._readableState;if(e.length>0)throw new Error('"endReadable()" called on non-empty stream');e.endEmitted||(e.ended=!0,n.nextTick(R,e,t))}function R(t,e){t.endEmitted||0!==t.length||(t.endEmitted=!0,e.readable=!1,e.emit("end"))}function O(t,e){for(var r=0,i=t.length;r=e.highWaterMark||e.ended))return d("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?P(this):I(this),null;if(0===(t=A(t,e))&&e.ended)return 0===e.length&&P(this),null;var i,n=e.needReadable;return d("need readable",n),(0===e.length||e.length-t0?T(t,e):null)?(e.needReadable=!0,t=0):e.length-=t,0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&P(this)),null!==i&&this.emit("data",i),i},y.prototype._read=function(t){this.emit("error",new Error("_read() is not implemented"))},y.prototype.pipe=function(t,e){var r=this,o=this._readableState;switch(o.pipesCount){case 0:o.pipes=t;break;case 1:o.pipes=[o.pipes,t];break;default:o.pipes.push(t)}o.pipesCount+=1,d("pipe count=%d opts=%j",o.pipesCount,e);var u=(!e||!1!==e.end)&&t!==i.stdout&&t!==i.stderr?f:y;function h(e,i){d("onunpipe"),e===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,d("cleanup"),t.removeListener("close",b),t.removeListener("finish",v),t.removeListener("drain",c),t.removeListener("error",g),t.removeListener("unpipe",h),r.removeListener("end",f),r.removeListener("end",y),r.removeListener("data",m),l=!0,!o.awaitDrain||t._writableState&&!t._writableState.needDrain||c())}function f(){d("onend"),t.end()}o.endEmitted?n.nextTick(u):r.once("end",u),t.on("unpipe",h);var c=function(t){return function(){var e=t._readableState;d("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&s(t,"data")&&(e.flowing=!0,C(t))}}(r);t.on("drain",c);var l=!1;var p=!1;function m(e){d("ondata"),p=!1,!1!==t.write(e)||p||((1===o.pipesCount&&o.pipes===t||o.pipesCount>1&&-1!==O(o.pipes,t))&&!l&&(d("false write response, pause",r._readableState.awaitDrain),r._readableState.awaitDrain++,p=!0),r.pause())}function g(e){d("onerror",e),y(),t.removeListener("error",g),0===s(t,"error")&&t.emit("error",e)}function b(){t.removeListener("finish",v),y()}function v(){d("onfinish"),t.removeListener("close",b),y()}function y(){d("unpipe"),r.unpipe(t)}return r.on("data",m),function(t,e,r){if("function"===typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?a(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",g),t.once("close",b),t.once("finish",v),t.emit("pipe",r),o.flowing||(d("pipe resume"),r.resume()),t},y.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function l(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function d(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}i(u,n),u.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},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,g=0|this._h,b=0;b<16;++b)r[b]=t.readInt32BE(4*b);for(;b<64;++b)r[b]=0|(((e=r[b-2])>>>17|e<<15)^(e>>>19|e<<13)^e>>>10)+r[b-7]+d(r[b-15])+r[b-16];for(var v=0;v<64;++v){var y=g+l(u)+h(u,p,m)+a[v]+r[v]|0,w=c(i)+f(i,n,o)|0;g=m,m=p,p=u,u=s+y|0,s=o,o=n,n=i,i=y+w|0}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},u.prototype._hash=function(){var t=o.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},t.exports=u},function(t,e,r){var i=r(1),n=r(24),o=r(2).Buffer,a=[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 u(){this.init(),this._w=s,n.call(this,128,112)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function l(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function d(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function p(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function m(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function g(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function b(t,e){return t>>>0>>0?1:0}i(u,n),u.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},u.prototype._update=function(t){for(var e=this._w,r=0|this._ah,i=0|this._bh,n=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,v=0|this._gh,y=0|this._hh,w=0|this._al,_=0|this._bl,M=0|this._cl,A=0|this._dl,I=0|this._el,S=0|this._fl,E=0|this._gl,k=0|this._hl,x=0;x<32;x+=2)e[x]=t.readInt32BE(4*x),e[x+1]=t.readInt32BE(4*x+4);for(;x<160;x+=2){var B=e[x-30],C=e[x-30+1],T=d(B,C),P=p(C,B),R=m(B=e[x-4],C=e[x-4+1]),O=g(C,B),j=e[x-14],D=e[x-14+1],N=e[x-32],z=e[x-32+1],K=P+D|0,q=T+j+b(K,P)|0;q=(q=q+R+b(K=K+O|0,O)|0)+N+b(K=K+z|0,z)|0,e[x]=q,e[x+1]=K}for(var U=0;U<160;U+=2){q=e[U],K=e[U+1];var F=f(r,i,n),L=f(w,_,M),Q=c(r,w),H=c(w,r),V=l(s,I),Z=l(I,s),G=a[U],Y=a[U+1],W=h(s,u,v),J=h(I,S,E),X=k+Z|0,$=y+V+b(X,k)|0;$=($=($=$+W+b(X=X+J|0,J)|0)+G+b(X=X+Y|0,Y)|0)+q+b(X=X+K|0,K)|0;var tt=H+L|0,et=Q+F+b(tt,H)|0;y=v,k=E,v=u,E=S,u=s,S=I,s=o+$+b(I=A+X|0,A)|0,o=n,A=M,n=i,M=_,i=r,_=w,r=$+et+b(w=X+tt|0,X)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+M|0,this._dl=this._dl+A|0,this._el=this._el+I|0,this._fl=this._fl+S|0,this._gl=this._gl+E|0,this._hl=this._hl+k|0,this._ah=this._ah+r+b(this._al,w)|0,this._bh=this._bh+i+b(this._bl,_)|0,this._ch=this._ch+n+b(this._cl,M)|0,this._dh=this._dh+o+b(this._dl,A)|0,this._eh=this._eh+s+b(this._el,I)|0,this._fh=this._fh+u+b(this._fl,S)|0,this._gh=this._gh+v+b(this._gl,E)|0,this._hh=this._hh+y+b(this._hl,k)|0},u.prototype._hash=function(){var t=o.allocUnsafe(64);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){"use strict";var i=r(1),n=r(203),o=r(16),a=r(2).Buffer,s=r(90),u=r(52),h=r(53),f=a.alloc(128);function c(t,e){o.call(this,"digest"),"string"===typeof e&&(e=a.from(e));var r="sha512"===t||"sha384"===t?128:64;(this._alg=t,this._key=e,e.length>r)?e=("rmd160"===t?new u:h(t)).update(e).digest():e.lengthr||o!==o)throw new TypeError("Bad key length")}}).call(this,r(0).Buffer)},function(t,e,r){(function(e){var r;e.browser?r="utf-8":r=parseInt(e.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary";t.exports=r}).call(this,r(8))},function(t,e,r){var i=r(90),n=r(52),o=r(53),a=r(93),s=r(94),u=r(2).Buffer,h=u.alloc(128),f={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function c(t,e,r){var a=function(t){return"rmd160"===t||"ripemd160"===t?function(t){return(new n).update(t).digest()}:"md5"===t?i:function(e){return o(t).update(e).digest()}}(t),s="sha512"===t||"sha384"===t?128:64;e.length>s?e=a(e):e.lengtht;)r.ishrn(1);if(r.isEven()&&r.iadd(s),r.testn(1)||r.iadd(u),e.cmp(u)){if(!e.cmp(h))for(;r.mod(f).cmp(c);)r.iadd(d)}else for(;r.mod(o).cmp(l);)r.iadd(d);if(g(p=r.shrn(1))&&g(r)&&b(p)&&b(r)&&a.test(p)&&a.test(r))return r}}},function(t,e,r){var i=r(5),n=r(57);function o(t){this.rand=t||new n.Rand}t.exports=o,o.create=function(t){return new o(t)},o.prototype._randbelow=function(t){var e=t.bitLength(),r=Math.ceil(e/8);do{var n=new i(this.rand.generate(r))}while(n.cmp(t)>=0);return n},o.prototype._randrange=function(t,e){var r=e.sub(t);return t.add(this._randbelow(r))},o.prototype.test=function(t,e,r){var n=t.bitLength(),o=i.mont(t),a=new i(1).toRed(o);e||(e=Math.max(1,n/48|0));for(var s=t.subn(1),u=0;!s.testn(u);u++);for(var h=t.shrn(u),f=s.toRed(o);e>0;e--){var c=this._randrange(new i(2),s);r&&r(c);var l=c.toRed(o).redPow(h);if(0!==l.cmp(a)&&0!==l.cmp(f)){for(var d=1;d0;e--){var f=this._randrange(new i(2),a),c=t.gcd(f);if(0!==c.cmpn(1))return c;var l=f.toRed(n).redPow(u);if(0!==l.cmp(o)&&0!==l.cmp(h)){for(var d=1;d>8,a=255&n;o?r.push(o,a):r.push(a)}return r},i.zero2=n,i.toHex=o,i.encode=function(t,e){return"hex"===e?o(t):t}},function(t,e,r){"use strict";var i=e;i.base=r(41),i.short=r(231),i.mont=r(232),i.edwards=r(233)},function(t,e,r){"use strict";var i=r(15).rotr32;function n(t,e,r){return t&e^~t&r}function o(t,e,r){return t&e^t&r^e&r}function a(t,e,r){return t^e^r}e.ft_1=function(t,e,r,i){return 0===t?n(e,r,i):1===t||3===t?a(e,r,i):2===t?o(e,r,i):void 0},e.ch32=n,e.maj32=o,e.p32=a,e.s0_256=function(t){return i(t,2)^i(t,13)^i(t,22)},e.s1_256=function(t){return i(t,6)^i(t,11)^i(t,25)},e.g0_256=function(t){return i(t,7)^i(t,18)^t>>>3},e.g1_256=function(t){return i(t,17)^i(t,19)^t>>>10}},function(t,e,r){"use strict";var i=r(15),n=r(34),o=r(105),a=r(13),s=i.sum32,u=i.sum32_4,h=i.sum32_5,f=o.ch32,c=o.maj32,l=o.s0_256,d=o.s1_256,p=o.g0_256,m=o.g1_256,g=n.BlockHash,b=[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 v(){if(!(this instanceof v))return new v;g.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=b,this.W=new Array(64)}i.inherits(v,g),t.exports=v,v.blockSize=512,v.outSize=256,v.hmacStrength=192,v.padLength=64,v.prototype._update=function(t,e){for(var r=this.W,i=0;i<16;i++)r[i]=t[e+i];for(;i>6],n=0===(32&r);if(31===(31&r)){var o=r;for(r=0;128===(128&o);){if(o=t.readUInt8(e),t.isError(o))return o;r<<=7,r|=127&o}}else r&=31;return{cls:i,primitive:n,tag:r,tagStr:s.tag[r]}}function c(t,e,r){var i=t.readUInt8(r);if(t.isError(i))return i;if(!e&&128===i)return null;if(0===(128&i))return i;var n=127&i;if(n>4)return t.error("length octect is too long");i=0;for(var o=0;o=31)return i.error("Multi-octet tag encoding unsupported");e||(n|=32);return n|=s.tagClassByName[r||"universal"]<<6}(t,e,r,this.reporter);if(i.length<128)return(o=new n(2))[0]=a,o[1]=i.length,this._createEncoderBuffer([o,i]);for(var u=1,h=i.length;h>=256;h>>=8)u++;(o=new n(2+u))[0]=a,o[1]=128|u;h=1+u;for(var f=i.length;f>0;h--,f>>=8)o[h]=255&f;return this._createEncoderBuffer([o,i])},h.prototype._encodeStr=function(t,e){if("bitstr"===e)return this._createEncoderBuffer([0|t.unused,t.data]);if("bmpstr"===e){for(var r=new n(2*t.length),i=0;i=40)return this.reporter.error("Second objid identifier OOB");t.splice(0,2,40*t[0]+t[1])}var o=0;for(i=0;i=128;a>>=7)o++}var s=new n(o),u=s.length-1;for(i=t.length-1;i>=0;i--){a=t[i];for(s[u--]=127&a;(a>>=7)>0;)s[u--]=128|127&a}return this._createEncoderBuffer(s)},h.prototype._encodeTime=function(t,e){var r,i=new Date(t);return"gentime"===e?r=[f(i.getFullYear()),f(i.getUTCMonth()+1),f(i.getUTCDate()),f(i.getUTCHours()),f(i.getUTCMinutes()),f(i.getUTCSeconds()),"Z"].join(""):"utctime"===e?r=[f(i.getFullYear()%100),f(i.getUTCMonth()+1),f(i.getUTCDate()),f(i.getUTCHours()),f(i.getUTCMinutes()),f(i.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+e+" time is not supported yet"),this._encodeStr(r,"octstr")},h.prototype._encodeNull=function(){return this._createEncoderBuffer("")},h.prototype._encodeInt=function(t,e){if("string"===typeof t){if(!e)return this.reporter.error("String int or enum given, but no values map");if(!e.hasOwnProperty(t))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(t));t=e[t]}if("number"!==typeof t&&!n.isBuffer(t)){var r=t.toArray();!t.sign&&128&r[0]&&r.unshift(0),t=new n(r)}if(n.isBuffer(t)){var i=t.length;0===t.length&&i++;var o=new n(i);return t.copy(o),0===t.length&&(o[0]=0),this._createEncoderBuffer(o)}if(t<128)return this._createEncoderBuffer(t);if(t<256)return this._createEncoderBuffer([0,t]);i=1;for(var a=t;a>=256;a>>=8)i++;for(a=(o=new Array(i)).length-1;a>=0;a--)o[a]=255&t,t>>=8;return 128&o[0]&&o.unshift(0),this._createEncoderBuffer(new n(o))},h.prototype._encodeBool=function(t){return this._createEncoderBuffer(t?255:0)},h.prototype._use=function(t,e){return"function"===typeof t&&(t=t(e)),t._getEncoder("der").tree},h.prototype._skipDefault=function(t,e,r){var i,n=this._baseState;if(null===n.default)return!1;var o=t.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,e,r).join()),o.length!==n.defaultBuffer.length)return!1;for(i=0;ithis.SegNum*this.SegBitsNum&&s(!1,"bigBuffer.length > SegNum * SegBitsNum");for(var i=Math.ceil(this.SegBitsNum/this.Bits),a=Math.ceil(r.bitsLength()/this.SegBitsNum),h=u.Point.ZERO,f=0;f=s),this.bitsLen=n,this.rightBits=r%8,this.buf=t.from(e.slice(Math.floor(r/8),Math.floor((a-1)/8)+1)),this.buf[this.buf.length-1]&=o.get(a%8)}return e.prototype.toBigNumber=function(){return new n(this.buf,"le").shrn(this.rightBits)},e.prototype.bitsLength=function(){return this.bitsLen},e.from=function(t,r,i){return new e(t.buf,r+t.rightBits,i)},e}();e.BitBuffer=a}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(6),o=r(4),a=r(17),s=r(43);function u(t){return a.blake2b("SZK$DSAN$HASH2",t)}function h(t){return new s(t)}e.sign=function(e,r,i,o){var s=t.concat([h(32),r.toBuffer(),e]),f=new n.FR(function(t){return a.blake2b("SZK$DSAN$HASH1",t)}(s)),c=i.mult(f);if(c&&!c.isZero()&&c.isValid()){var l=o.mult(f);if(l&&!l.isZero()&&l.isValid()){var d=i.mult(r);if(d&&!d.isZero()&&d.isValid()){var p=o.mult(r);if(p&&!p.isZero()&&p.isValid()){var m=t.concat([c.toBuffer(),l.toBuffer(),d.toBuffer(),p.toBuffer(),e]),g=new n.FR(u(m)),b=f.add(r.mul(g));return t.concat([b.toBuffer(),c.toBuffer(),l.toBuffer()])}}}}},e.verify=function(e,r,a,s,h,f){if(o(96==r.length,"sign.length != 96"),!a||a.isZero()||!a.isValid())return!1;if(!s||s.isZero()||!s.isValid())return!1;var c=new n.FR(r.slice(0,32)),l=i.Point.bufferTo(r.slice(32,64)),d=i.Point.bufferTo(r.slice(64,96));if(!c||c.isZero())return!1;if(!l||l.isZero()||!l.isValid())return!1;if(!d||d.isZero()||!d.isValid())return!1;var p=h.mult(c);if(!p||p.isZero()||!p.isValid())return!1;var m=f.mult(c);if(!m||m.isZero()||!m.isValid())return!1;var g=t.concat([l.toBuffer(),d.toBuffer(),a.toBuffer(),s.toBuffer(),e]),b=new n.FR(u(g)),v=a.mult(b),y=l.add(v);if(!p.isEqualTo(y))return!1;var w=s.mult(b),_=d.add(w);return!!m.isEqualTo(_)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),n=r(3),o=r(4),a=r(66),s=function(){function e(t,e){this.ZPK=i.newPoint(t),this.VPK=i.newPoint(e)}return e.prototype.toBuffer=function(){return t.concat([this.ZPK.toBuffer(),this.VPK.toBuffer()])},e.prototype.toString=function(){return n.default.bufferToBs58(this.toBuffer())},e}();e.PK=s,e.newPK=function(t){if(t instanceof s)return t;var e=n.toBuffer(t);o(64==e.length);var r=i.Point.bufferTo(e.slice(0,32)),a=i.Point.bufferTo(e.slice(32,64));return new s(r,a)},e.tk2PK=function(t){var e=(t=a.newTK(t)).ZPK,r=t.ZPK.mult(t.vsk);return new s(e,r)}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(37),n=r(6),o=r(3),a=r(64),s=r(4),u=function(){function e(t,e,r){this.asset=i.newAsset(t),this.memo=o.toBuffer(e),this.ar=n.newFR(r)}return e.prototype.isValid=function(){return!!this.asset.isValid()&&!this.ar.isZero()},e.prototype.toBuffer=function(){return t.concat([this.asset.toBuffer(),this.memo,this.ar.toBuffer()])},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function h(t){if(t instanceof u)return t;var e=o.toBuffer(t);s(224==e.length);var r=0,a=128,h=i.newAsset(e.slice(r,r+a));r+=a,a=64;var f=e.slice(r,r+a);r+=a,a=32;var c=n.newFR(e.slice(r,r+a));return new u(h,f,c)}e.Info=u,e.newInfo=h,e.encInfo=function(t,e){t=o.toBuffer(t);var r=(e=h(e)).toBuffer();return a.default(r,t)},e.decEInfo=function(t,e){return t=o.toBuffer(t),e=o.toBuffer(e),h(a.default(e,t))}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(48),n=r(43),o=r(276),a=r(293),s=r(296),u=r(142),h=r(3),f=r(6),c=r(45),l=function(){function t(t,e){if(this.version=2,void 0!==t){void 0===e&&(e=g());var r=h.toBuffer(e);this.keystore=p(r,t,2);var i=c.seed2Sk(r,2),n=c.sk2Tk(i);return this.tk=n,this.pk=c.tk2PK(n),this.version=2,this}}return t.prototype.fromKeystore=function(t){var e="object"==typeof t?t:JSON.parse(t);this.keystore=e,this.tk=e.tk,this.version=this.keystore.version;var r=h.toBuffer(this.tk);if(h.isNewVersion(r)){if(2!==this.version)throw new Error("keystore version not match tk")}else if(1!==this.version)throw new Error("keystore version not match tk");var i=c.tk2PK(this.tk);return this.pk=i,this},t.prototype.fromMnemonic=function(t,e){var r=t.split(" "),i=1;if(25===r.length){if("v2"!==r[0])throw new Error("invalid mnemoic!");i=2,t=r.slice(1).join(" ")}if(s.validateMnemonic(t)){var n=s.mnemonicToEntropy(t),o=h.toBuffer(n);this.keystore=p(o,e,i);var a=c.seed2Sk(o,i),u=c.sk2Tk(a);return this.tk=u,this.pk=this.keystore.address,this.version=i,this}throw new Error("invald mnemonic!")},t.prototype.fromTk=function(t){var e=h.toBuffer(t),r=1;return h.isNewVersion(e)&&(r=2),this.tk=t,this.pk=c.tk2PK(e),this.keystore=function(t,e){var r=c.tk2PK(t);return{version:e,id:a({random:n(16)}),address:r,tk:t.toString(),at:0}}(this.tk,r),this.version=r,this},t.prototype.getSk=function(t){if(this.keystore.crypto){var e=d(this.keystore,t);return c.seed2Sk(e,this.keystore.version)}return""},t.prototype.getTk=function(){return this.tk.toString()},t.prototype.getPk=function(){return this.pk},t.prototype.getVersion=function(){return this.version},t.prototype.getKeystore=function(){return this.keystore},t.prototype.exportMnemonic=function(t){var e=d(this.keystore,t),r=this.keystore.version,i=s.entropyToMnemonic(e);return 2===r&&(i="v2 "+i),i},t}();function d(e,r){var n,a,s="object"==typeof e?e:JSON.parse(e);if("scrypt"!==s.crypto.kdf)throw new Error("Unsupported key derivation scheme");a=s.crypto.kdfparams,n=o(t.from(r),h.toBuffer(a.salt),a.n,a.r,a.p,a.dklen);var f=t.from(s.crypto.ciphertext,"hex");if(u(t.concat([n.slice(16,32),f])).toString("hex")!==s.crypto.mac)throw new Error("Key derivation failed - possibly wrong passphrase");return m(i.createDecipheriv(s.crypto.cipher,n.slice(0,16),t.from(s.crypto.cipherparams.iv,"hex")),f)}function p(e,r,s){if(!function(t){return null!=t}(e))throw new Error("This is a public key only wallet");var f={cipher:"aes-128-ctr",kdf:"scrypt",salt:n(32),iv:n(16),uuid:n(16),dklen:32,c:262144,n:262144,r:8,p:1},l=function(t){return{dklen:t.dklen,salt:t.salt.toString("hex"),n:t.n,r:t.r,p:t.p}}(f),d=o(t.from(r),h.toBuffer(l.salt),l.n,l.r,l.p,l.dklen),p=i.createCipheriv(f.cipher,d.slice(0,16),f.iv);if(!p)throw new Error("Unsupported cipher");var g=m(p,e),b=u(t.concat([d.slice(16,32),t.from(g)])),v=c.seed2Sk(e,s),y=c.sk2Tk(v),w=c.tk2PK(y);return l.salt=l.salt,{version:s,id:a({random:f.uuid}),address:w,tk:y.toString(),crypto:{ciphertext:g.toString("hex"),cipherparams:{iv:f.iv.toString("hex")},cipher:f.cipher,kdf:f.kdf,kdfparams:l,mac:b.toString("hex")},at:0}}function m(e,r){return t.concat([e.update(r),e.final()])}function g(){return f.randomFR().toBuffer().toString("hex")}e.default=l,e.createPkrHash=function(e,r,i){if(2!==i&&1!==i)throw new Error("ivalid version");e=h.toBuffer(e);var n=h.toBN(r).toArrayLike(t,"be");if(8r||e!==e)throw new TypeError("Bad key length")}},function(t,e,r){(function(e){var r;if(e.browser)r="utf-8";else if(e.version){r=parseInt(e.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary"}else r="utf-8";t.exports=r}).call(this,r(8))},function(t,e,r){var i=r(279),n=r(136),o=r(137),a=r(7).Buffer,s=r(125),u=r(126),h=r(140),f=a.alloc(128),c={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function l(t,e,r){var s=function(t){return"rmd160"===t||"ripemd160"===t?function(t){return(new n).update(t).digest()}:"md5"===t?i:function(e){return o(t).update(e).digest()}}(t),u="sha512"===t||"sha384"===t?128:64;e.length>u?e=s(e):e.length>>32-e}function h(t,e,r,i,n,o,a){return u(t+(e&r|~e&i)+n+o|0,a)+e|0}function f(t,e,r,i,n,o,a){return u(t+(e&i|r&~i)+n+o|0,a)+e|0}function c(t,e,r,i,n,o,a){return u(t+(e^r^i)+n+o|0,a)+e|0}function l(t,e,r,i,n,o,a){return u(t+(r^(e|~i))+n+o|0,a)+e|0}i(s,n),s.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);var r=this._a,i=this._b,n=this._c,o=this._d;r=h(r,i,n,o,t[0],3614090360,7),o=h(o,r,i,n,t[1],3905402710,12),n=h(n,o,r,i,t[2],606105819,17),i=h(i,n,o,r,t[3],3250441966,22),r=h(r,i,n,o,t[4],4118548399,7),o=h(o,r,i,n,t[5],1200080426,12),n=h(n,o,r,i,t[6],2821735955,17),i=h(i,n,o,r,t[7],4249261313,22),r=h(r,i,n,o,t[8],1770035416,7),o=h(o,r,i,n,t[9],2336552879,12),n=h(n,o,r,i,t[10],4294925233,17),i=h(i,n,o,r,t[11],2304563134,22),r=h(r,i,n,o,t[12],1804603682,7),o=h(o,r,i,n,t[13],4254626195,12),n=h(n,o,r,i,t[14],2792965006,17),r=f(r,i=h(i,n,o,r,t[15],1236535329,22),n,o,t[1],4129170786,5),o=f(o,r,i,n,t[6],3225465664,9),n=f(n,o,r,i,t[11],643717713,14),i=f(i,n,o,r,t[0],3921069994,20),r=f(r,i,n,o,t[5],3593408605,5),o=f(o,r,i,n,t[10],38016083,9),n=f(n,o,r,i,t[15],3634488961,14),i=f(i,n,o,r,t[4],3889429448,20),r=f(r,i,n,o,t[9],568446438,5),o=f(o,r,i,n,t[14],3275163606,9),n=f(n,o,r,i,t[3],4107603335,14),i=f(i,n,o,r,t[8],1163531501,20),r=f(r,i,n,o,t[13],2850285829,5),o=f(o,r,i,n,t[2],4243563512,9),n=f(n,o,r,i,t[7],1735328473,14),r=c(r,i=f(i,n,o,r,t[12],2368359562,20),n,o,t[5],4294588738,4),o=c(o,r,i,n,t[8],2272392833,11),n=c(n,o,r,i,t[11],1839030562,16),i=c(i,n,o,r,t[14],4259657740,23),r=c(r,i,n,o,t[1],2763975236,4),o=c(o,r,i,n,t[4],1272893353,11),n=c(n,o,r,i,t[7],4139469664,16),i=c(i,n,o,r,t[10],3200236656,23),r=c(r,i,n,o,t[13],681279174,4),o=c(o,r,i,n,t[0],3936430074,11),n=c(n,o,r,i,t[3],3572445317,16),i=c(i,n,o,r,t[6],76029189,23),r=c(r,i,n,o,t[9],3654602809,4),o=c(o,r,i,n,t[12],3873151461,11),n=c(n,o,r,i,t[15],530742520,16),r=l(r,i=c(i,n,o,r,t[2],3299628645,23),n,o,t[0],4096336452,6),o=l(o,r,i,n,t[7],1126891415,10),n=l(n,o,r,i,t[14],2878612391,15),i=l(i,n,o,r,t[5],4237533241,21),r=l(r,i,n,o,t[12],1700485571,6),o=l(o,r,i,n,t[3],2399980690,10),n=l(n,o,r,i,t[10],4293915773,15),i=l(i,n,o,r,t[1],2240044497,21),r=l(r,i,n,o,t[8],1873313359,6),o=l(o,r,i,n,t[15],4264355552,10),n=l(n,o,r,i,t[6],2734768916,15),i=l(i,n,o,r,t[13],1309151649,21),r=l(r,i,n,o,t[4],4149444226,6),o=l(o,r,i,n,t[11],3174756917,10),n=l(n,o,r,i,t[2],718787259,15),i=l(i,n,o,r,t[9],3951481745,21),this._a=this._a+r|0,this._b=this._b+i|0,this._c=this._c+n|0,this._d=this._d+o|0},s.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=o.allocUnsafe(16);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t},t.exports=s},function(t,e,r){"use strict";var i=r(7).Buffer,n=r(280).Transform;function o(t){n.call(this),this._block=i.allocUnsafe(t),this._blockSize=t,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}r(9)(o,n),o.prototype._transform=function(t,e,r){var i=null;try{this.update(t,e)}catch(n){i=n}r(i)},o.prototype._flush=function(t){var e=null;try{this.push(this.digest())}catch(r){e=r}t(e)},o.prototype.update=function(t,e){if(function(t,e){if(!i.isBuffer(t)&&"string"!==typeof t)throw new TypeError(e+" must be a string or a buffer")}(t,"Data"),this._finalized)throw new Error("Digest already called");i.isBuffer(t)||(t=i.from(t,e));for(var r=this._block,n=0;this._blockOffset+t.length-n>=this._blockSize;){for(var o=this._blockOffset;o0;++a)this._length[a]+=s,(s=this._length[a]/4294967296|0)>0&&(this._length[a]-=4294967296*s);return this},o.prototype._update=function(){throw new Error("_update is not implemented")},o.prototype.digest=function(t){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var e=this._digest();void 0!==t&&(e=e.toString(t)),this._block.fill(0),this._blockOffset=0;for(var r=0;r<4;++r)this._length[r]=0;return e},o.prototype._digest=function(){throw new Error("_digest is not implemented")},t.exports=o},function(t,e,r){"use strict";(function(e,i){var n;t.exports=S,S.ReadableState=I;r(31).EventEmitter;var o=function(t,e){return t.listeners(e).length},a=r(131),s=r(0).Buffer,u=e.Uint8Array||function(){};var h,f=r(281);h=f&&f.debuglog?f.debuglog("stream"):function(){};var c,l,d,p=r(282),m=r(132),g=r(133).getHighWaterMark,b=r(26).codes,v=b.ERR_INVALID_ARG_TYPE,y=b.ERR_STREAM_PUSH_AFTER_EOF,w=b.ERR_METHOD_NOT_IMPLEMENTED,_=b.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;r(9)(S,a);var M=m.errorOrDestroy,A=["error","close","destroy","pause","resume"];function I(t,e,i){n=n||r(27),t=t||{},"boolean"!==typeof i&&(i=e instanceof n),this.objectMode=!!t.objectMode,i&&(this.objectMode=this.objectMode||!!t.readableObjectMode),this.highWaterMark=g(this,t,"readableHighWaterMark",i),this.buffer=new p,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=!1!==t.emitClose,this.autoDestroy=!!t.autoDestroy,this.destroyed=!1,this.defaultEncoding=t.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,t.encoding&&(c||(c=r(23).StringDecoder),this.decoder=new c(t.encoding),this.encoding=t.encoding)}function S(t){if(n=n||r(27),!(this instanceof S))return new S(t);var e=this instanceof n;this._readableState=new I(t,this,e),this.readable=!0,t&&("function"===typeof t.read&&(this._read=t.read),"function"===typeof t.destroy&&(this._destroy=t.destroy)),a.call(this)}function E(t,e,r,i,n){h("readableAddChunk",e);var o,a=t._readableState;if(null===e)a.reading=!1,function(t,e){if(h("onEofChunk"),e.ended)return;if(e.decoder){var r=e.decoder.end();r&&r.length&&(e.buffer.push(r),e.length+=e.objectMode?1:r.length)}e.ended=!0,e.sync?C(t):(e.needReadable=!1,e.emittedReadable||(e.emittedReadable=!0,T(t)))}(t,a);else if(n||(o=function(t,e){var r;i=e,s.isBuffer(i)||i instanceof u||"string"===typeof e||void 0===e||t.objectMode||(r=new v("chunk",["string","Buffer","Uint8Array"],e));var i;return r}(a,e)),o)M(t,o);else if(a.objectMode||e&&e.length>0)if("string"===typeof e||a.objectMode||Object.getPrototypeOf(e)===s.prototype||(e=function(t){return s.from(t)}(e)),i)a.endEmitted?M(t,new _):k(t,a,e,!0);else if(a.ended)M(t,new y);else{if(a.destroyed)return!1;a.reading=!1,a.decoder&&!r?(e=a.decoder.write(e),a.objectMode||0!==e.length?k(t,a,e,!1):P(t,a)):k(t,a,e,!1)}else i||(a.reading=!1,P(t,a));return!a.ended&&(a.lengthe.highWaterMark&&(e.highWaterMark=function(t){return t>=x?t=x:(t--,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,t|=t>>>16,t++),t}(t)),t<=e.length?t:e.ended?e.length:(e.needReadable=!0,0))}function C(t){var e=t._readableState;h("emitReadable",e.needReadable,e.emittedReadable),e.needReadable=!1,e.emittedReadable||(h("emitReadable",e.flowing),e.emittedReadable=!0,i.nextTick(T,t))}function T(t){var e=t._readableState;h("emitReadable_",e.destroyed,e.length,e.ended),e.destroyed||!e.length&&!e.ended||(t.emit("readable"),e.emittedReadable=!1),e.needReadable=!e.flowing&&!e.ended&&e.length<=e.highWaterMark,N(t)}function P(t,e){e.readingMore||(e.readingMore=!0,i.nextTick(R,t,e))}function R(t,e){for(;!e.reading&&!e.ended&&(e.length0,e.resumeScheduled&&!e.paused?e.flowing=!0:t.listenerCount("data")>0&&t.resume()}function j(t){h("readable nexttick read 0"),t.read(0)}function D(t,e){h("resume",e.reading),e.reading||t.read(0),e.resumeScheduled=!1,t.emit("resume"),N(t),e.flowing&&!e.reading&&t.read(0)}function N(t){var e=t._readableState;for(h("flow",e.flowing);e.flowing&&null!==t.read(););}function z(t,e){return 0===e.length?null:(e.objectMode?r=e.buffer.shift():!t||t>=e.length?(r=e.decoder?e.buffer.join(""):1===e.buffer.length?e.buffer.first():e.buffer.concat(e.length),e.buffer.clear()):r=e.buffer.consume(t,e.decoder),r);var r}function K(t){var e=t._readableState;h("endReadable",e.endEmitted),e.endEmitted||(e.ended=!0,i.nextTick(q,e,t))}function q(t,e){if(h("endReadableNT",t.endEmitted,t.length),!t.endEmitted&&0===t.length&&(t.endEmitted=!0,e.readable=!1,e.emit("end"),t.autoDestroy)){var r=e._writableState;(!r||r.autoDestroy&&r.finished)&&e.destroy()}}function U(t,e){for(var r=0,i=t.length;r=e.highWaterMark:e.length>0)||e.ended))return h("read: emitReadable",e.length,e.ended),0===e.length&&e.ended?K(this):C(this),null;if(0===(t=B(t,e))&&e.ended)return 0===e.length&&K(this),null;var i,n=e.needReadable;return h("need readable",n),(0===e.length||e.length-t0?z(t,e):null)?(e.needReadable=e.length<=e.highWaterMark,t=0):(e.length-=t,e.awaitDrain=0),0===e.length&&(e.ended||(e.needReadable=!0),r!==t&&e.ended&&K(this)),null!==i&&this.emit("data",i),i},S.prototype._read=function(t){M(this,new w("_read()"))},S.prototype.pipe=function(t,e){var r=this,n=this._readableState;switch(n.pipesCount){case 0:n.pipes=t;break;case 1:n.pipes=[n.pipes,t];break;default:n.pipes.push(t)}n.pipesCount+=1,h("pipe count=%d opts=%j",n.pipesCount,e);var a=(!e||!1!==e.end)&&t!==i.stdout&&t!==i.stderr?u:g;function s(e,i){h("onunpipe"),e===r&&i&&!1===i.hasUnpiped&&(i.hasUnpiped=!0,h("cleanup"),t.removeListener("close",p),t.removeListener("finish",m),t.removeListener("drain",f),t.removeListener("error",d),t.removeListener("unpipe",s),r.removeListener("end",u),r.removeListener("end",g),r.removeListener("data",l),c=!0,!n.awaitDrain||t._writableState&&!t._writableState.needDrain||f())}function u(){h("onend"),t.end()}n.endEmitted?i.nextTick(a):r.once("end",a),t.on("unpipe",s);var f=function(t){return function(){var e=t._readableState;h("pipeOnDrain",e.awaitDrain),e.awaitDrain&&e.awaitDrain--,0===e.awaitDrain&&o(t,"data")&&(e.flowing=!0,N(t))}}(r);t.on("drain",f);var c=!1;function l(e){h("ondata");var i=t.write(e);h("dest.write",i),!1===i&&((1===n.pipesCount&&n.pipes===t||n.pipesCount>1&&-1!==U(n.pipes,t))&&!c&&(h("false write response, pause",n.awaitDrain),n.awaitDrain++),r.pause())}function d(e){h("onerror",e),g(),t.removeListener("error",d),0===o(t,"error")&&M(t,e)}function p(){t.removeListener("finish",m),g()}function m(){h("onfinish"),t.removeListener("close",p),g()}function g(){h("unpipe"),r.unpipe(t)}return r.on("data",l),function(t,e,r){if("function"===typeof t.prependListener)return t.prependListener(e,r);t._events&&t._events[e]?Array.isArray(t._events[e])?t._events[e].unshift(r):t._events[e]=[r,t._events[e]]:t.on(e,r)}(t,"error",d),t.once("close",p),t.once("finish",m),t.emit("pipe",r),n.flowing||(h("pipe resume"),r.resume()),t},S.prototype.unpipe=function(t){var e=this._readableState,r={hasUnpiped:!1};if(0===e.pipesCount)return this;if(1===e.pipesCount)return t&&t!==e.pipes?this:(t||(t=e.pipes),e.pipes=null,e.pipesCount=0,e.flowing=!1,t&&t.emit("unpipe",this,r),this);if(!t){var i=e.pipes,n=e.pipesCount;e.pipes=null,e.pipesCount=0,e.flowing=!1;for(var o=0;o0,!1!==n.flowing&&this.resume()):"readable"===t&&(n.endEmitted||n.readableListening||(n.readableListening=n.needReadable=!0,n.flowing=!1,n.emittedReadable=!1,h("on readable",n.length,n.reading),n.length?C(this):n.reading||i.nextTick(j,this))),r},S.prototype.addListener=S.prototype.on,S.prototype.removeListener=function(t,e){var r=a.prototype.removeListener.call(this,t,e);return"readable"===t&&i.nextTick(O,this),r},S.prototype.removeAllListeners=function(t){var e=a.prototype.removeAllListeners.apply(this,arguments);return"readable"!==t&&void 0!==t||i.nextTick(O,this),e},S.prototype.resume=function(){var t=this._readableState;return t.flowing||(h("resume"),t.flowing=!t.readableListening,function(t,e){e.resumeScheduled||(e.resumeScheduled=!0,i.nextTick(D,t,e))}(this,t)),t.paused=!1,this},S.prototype.pause=function(){return h("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(h("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},S.prototype.wrap=function(t){var e=this,r=this._readableState,i=!1;for(var n in t.on("end",(function(){if(h("wrapped end"),r.decoder&&!r.ended){var t=r.decoder.end();t&&t.length&&e.push(t)}e.push(null)})),t.on("data",(function(n){(h("wrapped data"),r.decoder&&(n=r.decoder.write(n)),!r.objectMode||null!==n&&void 0!==n)&&((r.objectMode||n&&n.length)&&(e.push(n)||(i=!0,t.pause())))})),t)void 0===this[n]&&"function"===typeof t[n]&&(this[n]=function(e){return function(){return t[e].apply(t,arguments)}}(n));for(var o=0;o-1))throw new _(t);return this._writableState.defaultEncoding=t,this},Object.defineProperty(S.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(S.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),S.prototype._write=function(t,e,r){r(new m("_write()"))},S.prototype._writev=null,S.prototype.end=function(t,e,r){var n=this._writableState;return"function"===typeof t?(r=t,t=null,e=null):"function"===typeof e&&(r=e,e=null),null!==t&&void 0!==t&&this.write(t,e),n.corked&&(n.corked=1,this.uncork()),n.ending||function(t,e,r){e.ending=!0,T(t,e),r&&(e.finished?i.nextTick(r):t.once("finish",r));e.ended=!0,t.writable=!1}(this,n,r),this},Object.defineProperty(S.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(S.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(t){this._writableState&&(this._writableState.destroyed=t)}}),S.prototype.destroy=c.destroy,S.prototype._undestroy=c.undestroy,S.prototype._destroy=function(t,e){e(t)}}).call(this,r(10),r(8))},function(t,e,r){"use strict";t.exports=f;var i=r(26).codes,n=i.ERR_METHOD_NOT_IMPLEMENTED,o=i.ERR_MULTIPLE_CALLBACK,a=i.ERR_TRANSFORM_ALREADY_TRANSFORMING,s=i.ERR_TRANSFORM_WITH_LENGTH_0,u=r(27);function h(t,e){var r=this._transformState;r.transforming=!1;var i=r.writecb;if(null===i)return this.emit("error",new o);r.writechunk=null,r.writecb=null,null!=e&&this.push(e),i(t);var n=this._readableState;n.reading=!1,(n.needReadable||n.length>>32-e}function m(t,e,r,i,n,o,a,s){return p(t+(e^r^i)+o+a|0,s)+n|0}function g(t,e,r,i,n,o,a,s){return p(t+(e&r|~e&i)+o+a|0,s)+n|0}function b(t,e,r,i,n,o,a,s){return p(t+((e|~r)^i)+o+a|0,s)+n|0}function v(t,e,r,i,n,o,a,s){return p(t+(e&i|r&~i)+o+a|0,s)+n|0}function y(t,e,r,i,n,o,a,s){return p(t+(e^(r|~i))+o+a|0,s)+n|0}n(d,o),d.prototype._update=function(){for(var t=a,e=0;e<16;++e)t[e]=this._block.readInt32LE(4*e);for(var r=0|this._a,i=0|this._b,n=0|this._c,o=0|this._d,d=0|this._e,w=0|this._a,_=0|this._b,M=0|this._c,A=0|this._d,I=0|this._e,S=0;S<80;S+=1){var E,k;S<16?(E=m(r,i,n,o,d,t[s[S]],c[0],h[S]),k=y(w,_,M,A,I,t[u[S]],l[0],f[S])):S<32?(E=g(r,i,n,o,d,t[s[S]],c[1],h[S]),k=v(w,_,M,A,I,t[u[S]],l[1],f[S])):S<48?(E=b(r,i,n,o,d,t[s[S]],c[2],h[S]),k=b(w,_,M,A,I,t[u[S]],l[2],f[S])):S<64?(E=v(r,i,n,o,d,t[s[S]],c[3],h[S]),k=g(w,_,M,A,I,t[u[S]],l[3],f[S])):(E=y(r,i,n,o,d,t[s[S]],c[4],h[S]),k=m(w,_,M,A,I,t[u[S]],l[4],f[S])),r=d,d=o,o=p(n,10),n=i,i=E,w=I,I=A,A=p(M,10),M=_,_=k}var x=this._b+n+A|0;this._b=this._c+o+I|0,this._c=this._d+d+w|0,this._d=this._e+r+_|0,this._e=this._a+i+M|0,this._a=x},d.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var t=i.alloc?i.alloc(20):new i(20);return t.writeInt32LE(this._a,0),t.writeInt32LE(this._b,4),t.writeInt32LE(this._c,8),t.writeInt32LE(this._d,12),t.writeInt32LE(this._e,16),t},t.exports=d},function(t,e,r){(e=t.exports=function(t){t=t.toLowerCase();var r=e[t];if(!r)throw new Error(t+" is not supported (we accept pull requests)");return new r}).sha=r(289),e.sha1=r(290),e.sha224=r(291),e.sha256=r(138),e.sha384=r(292),e.sha512=r(139)},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],s=new Array(64);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t){return(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function l(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function d(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}i(u,n),u.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},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,p=0|this._f,m=0|this._g,g=0|this._h,b=0;b<16;++b)r[b]=t.readInt32BE(4*b);for(;b<64;++b)r[b]=0|(((e=r[b-2])>>>17|e<<15)^(e>>>19|e<<13)^e>>>10)+r[b-7]+d(r[b-15])+r[b-16];for(var v=0;v<64;++v){var y=g+l(u)+h(u,p,m)+a[v]+r[v]|0,w=c(i)+f(i,n,o)|0;g=m,m=p,p=u,u=s+y|0,s=o,o=n,n=i,i=y+w|0}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0,this._f=p+this._f|0,this._g=m+this._g|0,this._h=g+this._h|0},u.prototype._hash=function(){var t=o.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},t.exports=u},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[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 u(){this.init(),this._w=s,n.call(this,128,112)}function h(t,e,r){return r^t&(e^r)}function f(t,e,r){return t&e|r&(t|e)}function c(t,e){return(t>>>28|e<<4)^(e>>>2|t<<30)^(e>>>7|t<<25)}function l(t,e){return(t>>>14|e<<18)^(t>>>18|e<<14)^(e>>>9|t<<23)}function d(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^t>>>7}function p(t,e){return(t>>>1|e<<31)^(t>>>8|e<<24)^(t>>>7|e<<25)}function m(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^t>>>6}function g(t,e){return(t>>>19|e<<13)^(e>>>29|t<<3)^(t>>>6|e<<26)}function b(t,e){return t>>>0>>0?1:0}i(u,n),u.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},u.prototype._update=function(t){for(var e=this._w,r=0|this._ah,i=0|this._bh,n=0|this._ch,o=0|this._dh,s=0|this._eh,u=0|this._fh,v=0|this._gh,y=0|this._hh,w=0|this._al,_=0|this._bl,M=0|this._cl,A=0|this._dl,I=0|this._el,S=0|this._fl,E=0|this._gl,k=0|this._hl,x=0;x<32;x+=2)e[x]=t.readInt32BE(4*x),e[x+1]=t.readInt32BE(4*x+4);for(;x<160;x+=2){var B=e[x-30],C=e[x-30+1],T=d(B,C),P=p(C,B),R=m(B=e[x-4],C=e[x-4+1]),O=g(C,B),j=e[x-14],D=e[x-14+1],N=e[x-32],z=e[x-32+1],K=P+D|0,q=T+j+b(K,P)|0;q=(q=q+R+b(K=K+O|0,O)|0)+N+b(K=K+z|0,z)|0,e[x]=q,e[x+1]=K}for(var U=0;U<160;U+=2){q=e[U],K=e[U+1];var F=f(r,i,n),L=f(w,_,M),Q=c(r,w),H=c(w,r),V=l(s,I),Z=l(I,s),G=a[U],Y=a[U+1],W=h(s,u,v),J=h(I,S,E),X=k+Z|0,$=y+V+b(X,k)|0;$=($=($=$+W+b(X=X+J|0,J)|0)+G+b(X=X+Y|0,Y)|0)+q+b(X=X+K|0,K)|0;var tt=H+L|0,et=Q+F+b(tt,H)|0;y=v,k=E,v=u,E=S,u=s,S=I,s=o+$+b(I=A+X|0,A)|0,o=n,A=M,n=i,M=_,i=r,_=w,r=$+et+b(w=X+tt|0,X)|0}this._al=this._al+w|0,this._bl=this._bl+_|0,this._cl=this._cl+M|0,this._dl=this._dl+A|0,this._el=this._el+I|0,this._fl=this._fl+S|0,this._gl=this._gl+E|0,this._hl=this._hl+k|0,this._ah=this._ah+r+b(this._al,w)|0,this._bh=this._bh+i+b(this._bl,_)|0,this._ch=this._ch+n+b(this._cl,M)|0,this._dh=this._dh+o+b(this._dl,A)|0,this._eh=this._eh+s+b(this._el,I)|0,this._fh=this._fh+u+b(this._fl,S)|0,this._gh=this._gh+v+b(this._gl,E)|0,this._hh=this._hh+y+b(this._hl,k)|0},u.prototype._hash=function(){var t=o.allocUnsafe(64);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){var i=r(7).Buffer;t.exports=function(t,e,r){if(i.isBuffer(t))return t;if("string"===typeof t)return i.from(t,e);if(ArrayBuffer.isView(t))return i.from(t.buffer);throw new TypeError(r+" must be a string, a Buffer, a typed array or a DataView")}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i,n={};e.wordlists=n,e._default=i;try{e._default=i=r(303),n.chinese_simplified=i}catch(o){}try{e._default=i=r(304),n.chinese_traditional=i}catch(o){}try{e._default=i=r(305),n.korean=i}catch(o){}try{e._default=i=r(306),n.french=i}catch(o){}try{e._default=i=r(307),n.italian=i}catch(o){}try{e._default=i=r(308),n.spanish=i}catch(o){}try{e._default=i=r(309),n.japanese=i,n.JA=i}catch(o){}try{e._default=i=r(310),n.english=i,n.EN=i}catch(o){}},function(t,e,r){"use strict";(function(e){var i="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n=r(311),o=r(317);function a(t){var e=t;if("string"!==typeof e)throw new Error("while padding to even, value must be string, is currently "+("undefined"===typeof e?"undefined":i(e))+", while padToEven.");return e.length%2&&(e="0"+e),e}t.exports=function(t){return t=function(t){if(!e.isBuffer(t))if(Array.isArray(t))t=e.from(t);else if("string"===typeof t)t=function(t,e){if("string"!==typeof t||!t.match(/^0x[0-9A-Fa-f]*$/))return!1;if(e&&t.length!==2+2*e)return!1;return!0}(t)?e.from(a(function(t){if("string"!==typeof t)return t;return function(t){if("string"!==typeof t)throw new Error("value must be type 'string', is currently type "+("undefined"===typeof t?"undefined":i(t))+", while checking isHexPrefixed.");return"0x"===t.slice(0,2)}(t)?t.slice(2):t}(t)),"hex"):e.from(t);else if("number"===typeof t)t=function(t){var r=function(t){return"0x"+t.toString(16)}(t);return e.from(a(r.slice(2)),"hex")}(t);else if(null===t||void 0===t)t=e.allocUnsafe(0);else if(o.isBN(t))t=t.toArrayLike(e);else{if(!t.toArray)throw new Error("invalid type");t=e.from(t.toArray())}return t}(t),n("keccak256").update(t).digest()}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";var i=this&&this.__awaiter||function(t,e,r,i){return new(r=r||Promise)((function(n,o){function a(t){try{u(i.next(t))}catch(t){o(t)}}function s(t){try{u(i.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?n(t.value):((e=t.value)instanceof r?e:new r((function(t){t(e)}))).then(a,s)}u((i=i.apply(t,e||[])).next())}))},n=this&&this.__generator||function(t,e){var r,i,n,o,a={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function s(o){return function(s){return function(o){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,i&&(n=2&o[0]?i.return:o[0]?i.throw||((n=i.return)&&n.call(i),0):i.next)&&!(n=n.call(i,o[1])).done)return n;switch(i=0,n&&(o=[2&o[0],n.value]),o[0]){case 0:case 1:n=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,i=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(n=0<(n=a.trys).length&&n[n.length-1])&&(6===o[0]||2===o[0])){a=0;continue}if(3===o[0]&&(!n||o[1]>n[0]&&o[1]n[0]&&o[1]>>> ",l,d),[4,e.findRoots(t.From,a.default.hexToCy(l),d)]);case 4:return p=n.sent(),console.log("result >>>> ",p),p&&(p.remain.isNeg()||p.remain.isZero())?(o.push.apply(o,p.utxos),[3,3]):[2,new Promise((function(t,e){e("no enough unlocked utxos")}))];case 5:return[2,new Promise((function(t){t(o)}))]}}))}))},e.buildTxParam=function(e,r){return i(this,void 0,void 0,(function(){var i,o,u,f,c,l,d,p,m,g,b,v,y;return n(this,(function(n){switch(n.label){case 0:return i=new Array,r.Utxos.forEach((function(t){i.push(t.Root)})),[4,e.getAnchor(i)];case 1:if(null===(o=n.sent()))throw new Error("can not find Anchor by root");if(u=new Array,f=0,c=new h(!1,r.Fee),r.Utxos.forEach((function(e,r){if(null===e.State)throw new Error("can not find out by root");c.AddIn(e.Asset),u.push({SKr:a.toString(t.alloc(96)),Out:{Root:e.Root,State:e.State},Witness:o[r]}),a.default.isNotNull(e.State.OS.Out_O)&&f++})),2500 2500");for(l=new Array,r.Receptions.forEach((function(e){c.AddOut(e.Asset),l.push({PKr:a.toHex(e.Addr),Asset:e.Asset,Memo:a.toString(t.alloc(64))})})),null!==r.Cmds&&null!==(d=new s(r.Cmds).OutAsset())&&c.AddOut(d),p=c.GetTknList(),m=c.GetTktList(),g=Math.max(p.length,m.length),b=0;bn[0]&&a[1]>> ",r.value[0],!1),m.set(r.value[0],!1)),r=e.next();console.error("======= fetchHandler error>>> ",t),j("Fetch Error:","string"==typeof t?t:t.message)})),b=(new Date).getTime()}t(),v=setInterval((function(){t()}),y)}(),t.data="success",C(t)},healthyCheck:function(t){var e=!1;b&&(e=(new Date).getTime()-b<6e4);var r=t.data;d.get(r).selectId(a.tables.syncInfo.name,1).then((function(i){t.data={health:e,latestSyncTime:b,isSyncing:m.get(r),latestBlock:i.CurrentBlock,pkrIndex:i.PkrIndex},C(t)})).catch((function(i){t.data={health:e,latestSyncTime:b,isSyncing:m.get(r),latestBlock:0,pkrIndex:1},C(t)}))},initAccount:function(t){var e,r,i,n=t.data;n&&d&&!d.get(n)&&(e=1,s.isNewVersion(s.default.toBuffer(n))&&(e=2),r=f.createPkrHash(n,1,e),a.dbConfig.databaseName="popup_"+n,i=new o.PopDB(a.dbConfig),d.set(n,i),i.select(a.tables.syncInfo.name,{TK:n}).then((function(e){var o;e&&0!==e.length||(o={TK:n,PkrIndex:1,CurrentBlock:0,LastCombineBlock:0,UseHashPKr:!1,MainPKr:r,PKr:r},i.insert(a.tables.syncInfo.name,o).then((function(e){t.data="success"})).catch((function(e){console.log(e),t.error=e.message}))),C(t)})).catch((function(e){var o={TK:n,PkrIndex:1,CurrentBlock:0,LastCombineBlock:0,UseHashPKr:!1,MainPKr:r,PKr:r};i.insert(a.tables.syncInfo.name,o).then((function(e){t.data="success"})).catch((function(e){console.log(e),t.error=e.message})),C(t)})))},clearData:function(t){(function(t){return i(this,void 0,void 0,(function(){function e(e){return i(this,void 0,void 0,(function(){var r;return n(this,(function(i){switch(i.label){case 0:return[4,e.selectId(a.tables.syncInfo.name,1)];case 1:return r=i.sent(),!0!==m.get(r.TK)?[3,3]:[4,new Promise((function(t,e){e("Data synchronization ...")}))];case 2:return i.sent(),[3,15];case 3:return m.set(t,!0),p.delete(t),r.CurrentBlock=0,r.PKr=r.MainPKr,r.PkrIndex=1,r.UseHashPKr=!1,[4,e.update(a.tables.syncInfo.name,r)];case 4:return i.sent(),[4,e.clearTable(a.tables.utxo.name)];case 5:return i.sent(),[4,e.clearTable(a.tables.txBase.name)];case 6:return i.sent(),[4,e.clearTable(a.tables.assets.name)];case 7:return i.sent(),[4,e.clearTable(a.tables.assetUtxo.name)];case 8:return i.sent(),[4,e.clearTable(a.tables.tx.name)];case 9:return i.sent(),[4,e.clearTable(a.tables.nils.name)];case 10:return i.sent(),[4,e.clearTable(a.tables.txCurrency.name)];case 11:return i.sent(),[4,e.clearTable(a.tables.utxoTkt.name)];case 12:return i.sent(),[4,e.clearTable(a.tables.tickets.name)];case 13:return i.sent(),[4,new Promise((function(t){t("Clear Data Success !")}))];case 14:i.sent(),i.label=15;case 15:return[2]}}))}))}var r,o;return n(this,(function(i){switch(i.label){case 0:return t?[4,e(d.get(t))]:[3,2];case 1:return i.sent(),[3,5];case 2:r=d.entries(),o=r.next(),i.label=3;case 3:return o.done?[3,5]:[4,e(o.value[1])];case 4:return i.sent(),o=r.next(),[3,3];case 5:return[2]}}))}))})(t.data).then((function(e){console.log("data>>> ",e),m.clear(),t.data="Success",C(t)})).catch((function(e){console.log("data e>>> ",e),m.clear(),t.error=e,C(t)}))},findUtxos:function(t,e,r){},balanceOf:function(t){var e=t.data;function r(){d.get(e).selectAll(a.tables.assets.name).then((function(r){var i=new Map;r&&0>>> ",u),[4,l.genTxParam(u,new k,new x)];case 4:return(f=m.sent()).Ins&&1e3>>> ",f),f.Z=!1,[4,D("sero_commitTx",[c=l.signTx(t.SK,f)])]);case 5:return p=m.sent(),[2,new Promise((function(u,l){var m;p.data.error?l(p.data.error.message):((m=t).From=o.PKr,t.Data&&(m.From=o.MainPKr),function(t,e,r,o){return i(this,void 0,void 0,(function(){var i,u,f,c;return n(this,(function(n){switch(n.label){case 0:return i={TK:t,TxHash:e.Hash,Num_TxHash:"99999999999_"+e.Hash,BlockHash:"",From:r.From,Gas:new h.default(r.Gas,16).toNumber(),GasPrice:new h.default(r.GasPrice,16).toNumber(),GasUsed:new h.default(r.Gas,16).toNumber(),Num:99999999999,Time:Math.floor((new Date).getTime()/1e3),To:r.To,State:"pending"},[4,o.update(a.tables.tx.name,i)];case 1:return n.sent(),u={Tkn:{Currency:s.default.cyToHex(r.Cy),Value:new h.default(r.Value).toString(10)}},f={TxHash:e.Hash,TxType:a.TxType.out,Root:e.Hash,TxHash_Root_TxType:[e.Hash,e.Hash,a.TxType.out].join("_"),Num_TxHash:[i.Num,e.Hash].join("_"),Asset:u},[4,o.update(a.tables.txBase.name,f)];case 2:return n.sent(),c={Num:i.Num,TxHash:i.TxHash,Currency:r.Cy,id:[U(i.Num.toString()),i.TxHash,r.Cy].join("_")},[4,d.get(t).update(a.tables.txCurrency.name,c)];case 3:return n.sent(),[2]}}))}))}(e,c,m,r).then().catch((function(t){console.error(t)})),function(t,e){return i(this,void 0,void 0,(function(){var r,i,o,s,u,h;return n(this,(function(n){switch(n.label){case 0:r=0,i=t,n.label=1;case 1:return r> ",t)})).catch((function(t){console.error(t)})),u(c.Hash))}))]}}))}))})(e).then((function(e){console.log("_commitTx hash:",e),t.data=e,C(t)})).catch((function(e){console.error("_commitTx err:",e),t.error=e,C(t)}))}catch(e){t.error=e.message,C(t)}},getSeroPrice:function(t){var e=t.data;u.default.get("https://data.gateio.co/api2/1/ticker/"+e).then((function(e){var r;e&&e.data&&(r=e.data,t.data=r,C(t))})).catch((function(t){}))},getPendingAndConfirming:function(t){return i(this,void 0,void 0,(function(){var e;return n(this,(function(r){return e=t.data,g.has(e)?t.data=g.get(e):t.data=[],C(t),[2]}))}))}};function A(t){return i(this,void 0,void 0,(function(){var e,r,i,o,u,f,c,l,d,p,m,g,b,v,y;return n(this,(function(n){switch(n.label){case 0:return[4,t.selectAll(a.tables.utxo.name)];case 1:if(!((e=n.sent())&&0>",c.utxos.length),h=!0),[4,R(c,e.TK,t)];case 3:return n.sent(),c.useHashPKr&&(r.UseHashPKr=!0),!0!==c.again?[3,5]:(r.PkrIndex=r.PkrIndex+1,l=1,s.isNewVersion(s.default.toBuffer(e.TK))&&(l=2),r.PKr=f.createPkrHash(e.TK,r.PkrIndex,l),o=c.lastBlockNumber,u=r.PkrIndex,r.CurrentBlock=c.lastBlockNumber,[4,t.update(a.tables.syncInfo.name,r)]);case 4:return n.sent(),[3,6];case 5:return c.lastBlockNumber,r.CurrentBlock=c.lastBlockNumber,[3,7];case 6:return[3,1];case 7:return[4,t.update(a.tables.syncInfo.name,r)];case 8:return n.sent(),[4,K(e.TK)];case 9:return d=n.sent(),console.log("_checkNil>> ",d,h),!0!==h&&!0!==d?[3,11]:[4,A(t)];case 10:n.sent(),n.label=11;case 11:return[4,q(e.TK)];case 12:return n.sent(),[2]}}))}))}function R(t,e,r){return i(this,void 0,void 0,(function(){var i,o,s,u,h,f,c,l,d,p,m;return n(this,(function(n){switch(n.label){case 0:if(!(t.utxos&&0> ",{Root:l.Root,Value:s.Asset.Tkt.Value,Category:s.Asset.Tkt.Category}),[4,r.update(a.tables.tickets.name,{Root:l.Root,Value:s.Asset.Tkt.Value,Category:s.Asset.Tkt.Category})];case 9:n.sent(),n.label=10;case 10:return i++,[3,1];case 11:if(!(t.txInfos&&0n[0]&&a[1]n[0]&&a[1]0?a-4:a;for(r=0;r>16&255,u[f++]=e>>8&255,u[f++]=255&e;2===s&&(e=n[t.charCodeAt(r)]<<2|n[t.charCodeAt(r+1)]>>4,u[f++]=255&e);1===s&&(e=n[t.charCodeAt(r)]<<10|n[t.charCodeAt(r+1)]<<4|n[t.charCodeAt(r+2)]>>2,u[f++]=e>>8&255,u[f++]=255&e);return u},e.fromByteArray=function(t){for(var e,r=t.length,n=r%3,o=[],a=0,s=r-n;as?s:a+16383));1===n?(e=t[r-1],o.push(i[e>>2]+i[e<<4&63]+"==")):2===n&&(e=(t[r-2]<<8)+t[r-1],o.push(i[e>>10]+i[e>>4&63]+i[e<<2&63]+"="));return o.join("")};for(var i=[],n=[],o="undefined"!==typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=a.length;s0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");return-1===r&&(r=e),[r,r===e?0:4-r%4]}function f(t,e,r){for(var n,o,a=[],s=e;s>18&63]+i[o>>12&63]+i[o>>6&63]+i[63&o]);return a.join("")}n["-".charCodeAt(0)]=62,n["_".charCodeAt(0)]=63},function(t,e){e.read=function(t,e,r,i,n){var o,a,s=8*n-i-1,u=(1<>1,f=-7,c=r?n-1:0,l=r?-1:1,d=t[e+c];for(c+=l,o=d&(1<<-f)-1,d>>=-f,f+=s;f>0;o=256*o+t[e+c],c+=l,f-=8);for(a=o&(1<<-f)-1,o>>=-f,f+=i;f>0;a=256*a+t[e+c],c+=l,f-=8);if(0===o)o=1-h;else{if(o===u)return a?NaN:1/0*(d?-1:1);a+=Math.pow(2,i),o-=h}return(d?-1:1)*a*Math.pow(2,o-i)},e.write=function(t,e,r,i,n,o){var a,s,u,h=8*o-n-1,f=(1<>1,l=23===n?Math.pow(2,-24)-Math.pow(2,-77):0,d=i?0:o-1,p=i?1:-1,m=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=f):(a=Math.floor(Math.log(e)/Math.LN2),e*(u=Math.pow(2,-a))<1&&(a--,u*=2),(e+=a+c>=1?l/u:l*Math.pow(2,1-c))*u>=2&&(a++,u/=2),a+c>=f?(s=0,a=f):a+c>=1?(s=(e*u-1)*Math.pow(2,n),a+=c):(s=e*Math.pow(2,c-1)*Math.pow(2,n),a=0));n>=8;t[r+d]=255&s,d+=p,s/=256,n-=8);for(a=a<0;t[r+d]=255&a,d+=p,a/=256,h-=8);t[r+d-p]|=128*m}},function(t,e){},function(t,e,r){"use strict";var i=r(7).Buffer;t.exports=function(t){if(t.length>=255)throw new TypeError("Alphabet too long");var e=new Uint8Array(256);e.fill(255);for(var r=0;r>>0,f=new Uint8Array(h);t[r];){var c=e[t.charCodeAt(r)];if(255===c)return;for(var l=0,d=h-1;(0!==c||l>>0,f[d]=c%256>>>0,c=c/256>>>0;if(0!==c)throw new Error("Non-zero carry");o=l,r++}if(" "!==t[r]){for(var p=h-o;p!==h&&0===f[p];)p++;var m=i.allocUnsafe(n+(h-p));m.fill(0,0,n);for(var g=n;p!==h;)m[g++]=f[p++];return m}}}return{encode:function(e){if(!i.isBuffer(e))throw new TypeError("Expected Buffer");if(0===e.length)return"";for(var r=0,n=0,o=0,u=e.length;o!==u&&0===e[o];)o++,r++;for(var f=(u-o)*h+1>>>0,c=new Uint8Array(f);o!==u;){for(var l=e[o],d=0,p=f-1;(0!==l||d>>0,c[p]=l%a>>>0,l=l/a>>>0;if(0!==l)throw new Error("Non-zero carry");n=d,o++}for(var m=f-n;m!==f&&0===c[m];)m++;for(var g=s.repeat(r);m=55296&&e<=56319&&n=55296&&t<=57343)throw Error("Lone surrogate U+"+t.toString(16).toUpperCase()+" is not a scalar value")}function s(t,e){return n(t>>e&63|128)}function u(t){if(0==(4294967168&t))return n(t);var e="";return 0==(4294965248&t)?e=n(t>>6&31|192):0==(4294901760&t)?(a(t),e=n(t>>12&15|224),e+=s(t,6)):0==(4292870144&t)&&(e=n(t>>18&7|240),e+=s(t,12),e+=s(t,6)),e+=n(63&t|128)}function h(){if(i>=r)throw Error("Invalid byte index");var t=255&e[i];if(i++,128==(192&t))return 63&t;throw Error("Invalid continuation byte")}function f(){var t,n;if(i>r)throw Error("Invalid byte index");if(i==r)return!1;if(t=255&e[i],i++,0==(128&t))return t;if(192==(224&t)){if((n=(31&t)<<6|h())>=128)return n;throw Error("Invalid continuation byte")}if(224==(240&t)){if((n=(15&t)<<12|h()<<6|h())>=2048)return a(n),n;throw Error("Invalid continuation byte")}if(240==(248&t)&&(n=(7&t)<<18|h()<<12|h()<<6|h())>=65536&&n<=1114111)return n;throw Error("Invalid UTF-8 detected")}t.version="3.0.0",t.encode=function(t){for(var e=o(t),r=e.length,i=-1,n="";++i65535&&(o+=n((e-=65536)>>>10&1023|55296),e=56320|1023&e),o+=n(e);return o}(s)}}(e)},function(t,e,r){var i=r(156),n=r(69);t.exports=function(t){if("string"===typeof t||"number"===typeof t){var e=new i(1),r=String(t).toLowerCase().trim(),o="0x"===r.substr(0,2)||"-0x"===r.substr(0,3),a=n(r);if("-"===a.substr(0,1)&&(a=n(a.slice(1)),e=new i(-1,10)),!(a=""===a?"0":a).match(/^-?[0-9]+$/)&&a.match(/^[0-9A-Fa-f]+$/)||a.match(/^[a-fA-F]+$/)||!0===o&&a.match(/^[0-9A-Fa-f]+$/))return new i(a,16).mul(e);if((a.match(/^-?[0-9]+$/)||""===a)&&!1===o)return new i(a,10).mul(e)}else if("object"===typeof t&&t.toString&&!t.pop&&!t.push&&t.toString(10).match(/^-?[0-9]+$/)&&(t.mul||t.dividedToIntegerBy))return new i(t.toString(10),10);throw new Error("[number-to-bn] while converting number "+JSON.stringify(t)+" to BN.js instance, error: invalid number value. Value must be an integer, hex string, BN or BigNumber instance. Note, decimals are not supported.")}},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(0).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):r.strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){t.exports=function(t){return null===t}},function(t,e,r){var i=r(70),n=r(163),o=r(72),a="[object String]";t.exports=function(t){return"string"==typeof t||!n(t)&&o(t)&&i(t)==a}},function(t,e,r){var i=r(160),n="object"==typeof self&&self&&self.Object===Object&&self,o=i||n||Function("return this")();t.exports=o},function(t,e,r){(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.exports=r}).call(this,r(10))},function(t,e,r){var i=r(71),n=Object.prototype,o=n.hasOwnProperty,a=n.toString,s=i?i.toStringTag:void 0;t.exports=function(t){var e=o.call(t,s),r=t[s];try{t[s]=void 0;var i=!0}catch(u){}var n=a.call(t);return i&&(e?t[s]=r:delete t[s]),n}},function(t,e){var r=Object.prototype.toString;t.exports=function(t){return r.call(t)}},function(t,e){var r=Array.isArray;t.exports=r},function(t,e,r){var i=r(70),n=r(72),o="[object Number]";t.exports=function(t){return"number"==typeof t||n(t)&&i(t)==o}},function(t,e,r){(function(t){var i=Object.getOwnPropertyDescriptors||function(t){for(var e=Object.keys(t),r={},i=0;i=o)return t;switch(t){case"%s":return String(i[r++]);case"%d":return Number(i[r++]);case"%j":try{return JSON.stringify(i[r++])}catch(e){return"[Circular]"}default:return t}})),u=i[r];r=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),p(r)?i.showHidden=r:r&&e._extend(i,r),v(i.showHidden)&&(i.showHidden=!1),v(i.depth)&&(i.depth=2),v(i.colors)&&(i.colors=!1),v(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=u),f(i,t,i.depth)}function u(t,e){var r=s.styles[e];return r?"\x1b["+s.colors[r][0]+"m"+t+"\x1b["+s.colors[r][1]+"m":t}function h(t,e){return t}function f(t,r,i){if(t.customInspect&&r&&A(r.inspect)&&r.inspect!==e.inspect&&(!r.constructor||r.constructor.prototype!==r)){var n=r.inspect(i,t);return b(n)||(n=f(t,n,i)),n}var o=function(t,e){if(v(e))return t.stylize("undefined","undefined");if(b(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}if(g(e))return t.stylize(""+e,"number");if(p(e))return t.stylize(""+e,"boolean");if(m(e))return t.stylize("null","null")}(t,r);if(o)return o;var a=Object.keys(r),s=function(t){var e={};return t.forEach((function(t,r){e[t]=!0})),e}(a);if(t.showHidden&&(a=Object.getOwnPropertyNames(r)),M(r)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return c(r);if(0===a.length){if(A(r)){var u=r.name?": "+r.name:"";return t.stylize("[Function"+u+"]","special")}if(y(r))return t.stylize(RegExp.prototype.toString.call(r),"regexp");if(_(r))return t.stylize(Date.prototype.toString.call(r),"date");if(M(r))return c(r)}var h,w="",I=!1,S=["{","}"];(d(r)&&(I=!0,S=["[","]"]),A(r))&&(w=" [Function"+(r.name?": "+r.name:"")+"]");return y(r)&&(w=" "+RegExp.prototype.toString.call(r)),_(r)&&(w=" "+Date.prototype.toUTCString.call(r)),M(r)&&(w=" "+c(r)),0!==a.length||I&&0!=r.length?i<0?y(r)?t.stylize(RegExp.prototype.toString.call(r),"regexp"):t.stylize("[Object]","special"):(t.seen.push(r),h=I?function(t,e,r,i,n){for(var o=[],a=0,s=e.length;a=0&&0,t+e.replace(/\u001b\[\d\d?m/g,"").length+1}),0)>60)return r[0]+(""===e?"":e+"\n ")+" "+t.join(",\n ")+" "+r[1];return r[0]+e+" "+t.join(", ")+" "+r[1]}(h,w,S)):S[0]+w+S[1]}function c(t){return"["+Error.prototype.toString.call(t)+"]"}function l(t,e,r,i,n,o){var a,s,u;if((u=Object.getOwnPropertyDescriptor(e,n)||{value:e[n]}).get?s=u.set?t.stylize("[Getter/Setter]","special"):t.stylize("[Getter]","special"):u.set&&(s=t.stylize("[Setter]","special")),x(i,n)||(a="["+n+"]"),s||(t.seen.indexOf(u.value)<0?(s=m(r)?f(t,u.value,null):f(t,u.value,r-1)).indexOf("\n")>-1&&(s=o?s.split("\n").map((function(t){return" "+t})).join("\n").substr(2):"\n"+s.split("\n").map((function(t){return" "+t})).join("\n")):s=t.stylize("[Circular]","special")),v(a)){if(o&&n.match(/^\d+$/))return s;(a=JSON.stringify(""+n)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(a=a.substr(1,a.length-2),a=t.stylize(a,"name")):(a=a.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),a=t.stylize(a,"string"))}return a+": "+s}function d(t){return Array.isArray(t)}function p(t){return"boolean"===typeof t}function m(t){return null===t}function g(t){return"number"===typeof t}function b(t){return"string"===typeof t}function v(t){return void 0===t}function y(t){return w(t)&&"[object RegExp]"===I(t)}function w(t){return"object"===typeof t&&null!==t}function _(t){return w(t)&&"[object Date]"===I(t)}function M(t){return w(t)&&("[object Error]"===I(t)||t instanceof Error)}function A(t){return"function"===typeof t}function I(t){return Object.prototype.toString.call(t)}function S(t){return t<10?"0"+t.toString(10):t.toString(10)}e.debuglog=function(r){if(v(o)&&(o=Object({NODE_ENV:"production",PUBLIC_URL:"."}).NODE_DEBUG||""),r=r.toUpperCase(),!a[r])if(new RegExp("\\b"+r+"\\b","i").test(o)){var i=t.pid;a[r]=function(){var t=e.format.apply(e,arguments);console.error("%s %d: %s",r,i,t)}}else a[r]=function(){};return a[r]},e.inspect=s,s.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},s.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},e.isArray=d,e.isBoolean=p,e.isNull=m,e.isNullOrUndefined=function(t){return null==t},e.isNumber=g,e.isString=b,e.isSymbol=function(t){return"symbol"===typeof t},e.isUndefined=v,e.isRegExp=y,e.isObject=w,e.isDate=_,e.isError=M,e.isFunction=A,e.isPrimitive=function(t){return null===t||"boolean"===typeof t||"number"===typeof t||"string"===typeof t||"symbol"===typeof t||"undefined"===typeof t},e.isBuffer=r(166);var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function k(){var t=new Date,e=[S(t.getHours()),S(t.getMinutes()),S(t.getSeconds())].join(":");return[t.getDate(),E[t.getMonth()],e].join(" ")}function x(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.log=function(){console.log("%s - %s",k(),e.format.apply(e,arguments))},e.inherits=r(167),e._extend=function(t,e){if(!e||!w(e))return t;for(var r=Object.keys(e),i=r.length;i--;)t[r[i]]=e[r[i]];return t};var B="undefined"!==typeof Symbol?Symbol("util.promisify.custom"):void 0;function C(t,e){if(!t){var r=new Error("Promise was rejected with a falsy value");r.reason=t,t=r}return e(t)}e.promisify=function(t){if("function"!==typeof t)throw new TypeError('The "original" argument must be of type Function');if(B&&t[B]){var e;if("function"!==typeof(e=t[B]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(e,B,{value:e,enumerable:!1,writable:!1,configurable:!0}),e}function e(){for(var e,r,i=new Promise((function(t,i){e=t,r=i})),n=[],o=0;o=0)return;a[e]="set-cookie"===e?(a[e]?a[e]:[]).concat([r]):a[e]?a[e]+", "+r:r}})),a):a}},function(t,e,r){"use strict";var i=r(11);t.exports=i.isStandardBrowserEnv()?function(){var t,e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");function n(t){var i=t;return e&&(r.setAttribute("href",i),i=r.href),r.setAttribute("href",i),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:"/"===r.pathname.charAt(0)?r.pathname:"/"+r.pathname}}return t=n(window.location.href),function(e){var r=i.isString(e)?n(e):e;return r.protocol===t.protocol&&r.host===t.host}}():function(){return!0}},function(t,e,r){"use strict";var i=r(11);t.exports=i.isStandardBrowserEnv()?{write:function(t,e,r,n,o,a){var s=[];s.push(t+"="+encodeURIComponent(e)),i.isNumber(r)&&s.push("expires="+new Date(r).toGMTString()),i.isString(n)&&s.push("path="+n),i.isString(o)&&s.push("domain="+o),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(t){var e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove:function(t){this.write(t,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}},function(t,e,r){"use strict";t.exports=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}},function(t,e,r){"use strict";t.exports=function(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}},function(t,e,r){"use strict";var i=r(80);function n(t){if("function"!==typeof t)throw new TypeError("executor must be a function.");var e;this.promise=new Promise((function(t){e=t}));var r=this;t((function(t){r.reason||(r.reason=new i(t),e(r.reason))}))}n.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},n.source=function(){var t;return{token:new n((function(e){t=e})),cancel:t}},t.exports=n},function(t,e,r){"use strict";t.exports=function(t){return function(e){return t.apply(null,e)}}},function(t,e,r){var i;!function(n){"use strict";var o,a=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,s=Math.ceil,u=Math.floor,h="[BigNumber Error] ",f=h+"Number primitive has more than 15 significant digits: ",c=1e14,l=14,d=9007199254740991,p=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],m=1e7,g=1e9;function b(t){var e=0|t;return t>0||t===e?e:e-1}function v(t){for(var e,r,i=1,n=t.length,o=t[0]+"";ih^r?1:-1;for(s=(u=n.length)<(h=o.length)?u:h,a=0;ao[a]^r?1:-1;return u==h?0:u>h^r?1:-1}function w(t,e,r,i){if(tr||t!==u(t))throw Error(h+(i||"Argument")+("number"==typeof t?tr?" out of range: ":" not an integer: ":" not a primitive number: ")+String(t))}function _(t){var e=t.c.length-1;return b(t.e/l)==e&&t.c[e]%2!=0}function M(t,e){return(t.length>1?t.charAt(0)+"."+t.slice(1):t)+(e<0?"e":"e+")+e}function A(t,e,r){var i,n;if(e<0){for(n=r+".";++e;n+=r);t=n+t}else if(++e>(i=t.length)){for(n=r,e-=i;--e;n+=r);t+=n}else eC?b.c=b.e=null:t.e=10;c/=10,h++);return void(h>C?b.c=b.e=null:(b.e=h,b.c=[t]))}g=String(t)}else{if(!a.test(g=String(t)))return n(b,g,p);b.s=45==g.charCodeAt(0)?(g=g.slice(1),-1):1}(h=g.indexOf("."))>-1&&(g=g.replace(".","")),(c=g.search(/e/i))>0?(h<0&&(h=c),h+=+g.slice(c+1),g=g.substring(0,c)):h<0&&(h=g.length)}else{if(w(e,2,j.length,"Base"),10==e)return q(b=new D(t),S+b.e+1,E);if(g=String(t),p="number"==typeof t){if(0*t!=0)return n(b,g,p,e);if(b.s=1/t<0?(g=g.slice(1),-1):1,D.DEBUG&&g.replace(/^0\.0*|\./,"").length>15)throw Error(f+t)}else b.s=45===g.charCodeAt(0)?(g=g.slice(1),-1):1;for(r=j.slice(0,e),h=c=0,m=g.length;ch){h=m;continue}}else if(!s&&(g==g.toUpperCase()&&(g=g.toLowerCase())||g==g.toLowerCase()&&(g=g.toUpperCase()))){s=!0,c=-1,h=0;continue}return n(b,String(t),p,e)}p=!1,(h=(g=i(g,e,10,b.s)).indexOf("."))>-1?g=g.replace(".",""):h=g.length}for(c=0;48===g.charCodeAt(c);c++);for(m=g.length;48===g.charCodeAt(--m););if(g=g.slice(c,++m)){if(m-=c,p&&D.DEBUG&&m>15&&(t>d||t!==u(t)))throw Error(f+b.s*t);if((h=h-c-1)>C)b.c=b.e=null;else if(h=x)?M(u,a):A(u,a,"0");else if(o=(t=q(new D(t),e,r)).e,s=(u=v(t.c)).length,1==i||2==i&&(e<=o||o<=k)){for(;ss){if(--e>0)for(u+=".";e--;u+="0");}else if((e+=o-s)>0)for(o+1==s&&(u+=".");e--;u+="0");return t.s<0&&n?"-"+u:u}function z(t,e){for(var r,i=1,n=new D(t[0]);i=10;n/=10,i++);return(r=i+r*l-1)>C?t.c=t.e=null:r=10;h/=10,n++);if((o=e-n)<0)o+=l,a=e,m=(f=g[d=0])/b[n-a-1]%10|0;else if((d=s((o+1)/l))>=g.length){if(!i)break t;for(;g.length<=d;g.push(0));f=m=0,n=1,a=(o%=l)-l+1}else{for(f=h=g[d],n=1;h>=10;h/=10,n++);m=(a=(o%=l)-l+n)<0?0:f/b[n-a-1]%10|0}if(i=i||e<0||null!=g[d+1]||(a<0?f:f%b[n-a-1]),i=r<4?(m||i)&&(0==r||r==(t.s<0?3:2)):m>5||5==m&&(4==r||i||6==r&&(o>0?a>0?f/b[n-a]:0:g[d-1])%10&1||r==(t.s<0?8:7)),e<1||!g[0])return g.length=0,i?(e-=t.e+1,g[0]=b[(l-e%l)%l],t.e=-e||0):g[0]=t.e=0,t;if(0==o?(g.length=d,h=1,d--):(g.length=d+1,h=b[l-o],g[d]=a>0?u(f/b[n-a]%b[a])*h:0),i)for(;;){if(0==d){for(o=1,a=g[0];a>=10;a/=10,o++);for(a=g[0]+=h,h=1;a>=10;a/=10,h++);o!=h&&(t.e++,g[0]==c&&(g[0]=1));break}if(g[d]+=h,g[d]!=c)break;g[d--]=0,h=1}for(o=g.length;0===g[--o];g.pop());}t.e>C?t.c=t.e=null:t.e=x?M(e,r):A(e,r,"0"),t.s<0?"-"+e:e)}return D.clone=t,D.ROUND_UP=0,D.ROUND_DOWN=1,D.ROUND_CEIL=2,D.ROUND_FLOOR=3,D.ROUND_HALF_UP=4,D.ROUND_HALF_DOWN=5,D.ROUND_HALF_EVEN=6,D.ROUND_HALF_CEIL=7,D.ROUND_HALF_FLOOR=8,D.EUCLID=9,D.config=D.set=function(t){var e,r;if(null!=t){if("object"!=typeof t)throw Error(h+"Object expected: "+t);if(t.hasOwnProperty(e="DECIMAL_PLACES")&&(w(r=t[e],0,g,e),S=r),t.hasOwnProperty(e="ROUNDING_MODE")&&(w(r=t[e],0,8,e),E=r),t.hasOwnProperty(e="EXPONENTIAL_AT")&&((r=t[e])&&r.pop?(w(r[0],-g,0,e),w(r[1],0,g,e),k=r[0],x=r[1]):(w(r,-g,g,e),k=-(x=r<0?-r:r))),t.hasOwnProperty(e="RANGE"))if((r=t[e])&&r.pop)w(r[0],-g,-1,e),w(r[1],1,g,e),B=r[0],C=r[1];else{if(w(r,-g,g,e),!r)throw Error(h+e+" cannot be zero: "+r);B=-(C=r<0?-r:r)}if(t.hasOwnProperty(e="CRYPTO")){if((r=t[e])!==!!r)throw Error(h+e+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw T=!r,Error(h+"crypto unavailable");T=r}else T=r}if(t.hasOwnProperty(e="MODULO_MODE")&&(w(r=t[e],0,9,e),P=r),t.hasOwnProperty(e="POW_PRECISION")&&(w(r=t[e],0,g,e),R=r),t.hasOwnProperty(e="FORMAT")){if("object"!=typeof(r=t[e]))throw Error(h+e+" not an object: "+r);O=r}if(t.hasOwnProperty(e="ALPHABET")){if("string"!=typeof(r=t[e])||/^.$|[+-.\s]|(.).*\1/.test(r))throw Error(h+e+" invalid: "+r);j=r}}return{DECIMAL_PLACES:S,ROUNDING_MODE:E,EXPONENTIAL_AT:[k,x],RANGE:[B,C],CRYPTO:T,MODULO_MODE:P,POW_PRECISION:R,FORMAT:O,ALPHABET:j}},D.isBigNumber=function(t){if(!t||!0!==t._isBigNumber)return!1;if(!D.DEBUG)return!0;var e,r,i=t.c,n=t.e,o=t.s;t:if("[object Array]"=={}.toString.call(i)){if((1===o||-1===o)&&n>=-g&&n<=g&&n===u(n)){if(0===i[0]){if(0===n&&1===i.length)return!0;break t}if((e=(n+1)%l)<1&&(e+=l),String(i[0]).length==e){for(e=0;e=c||r!==u(r))break t;if(0!==r)return!0}}}else if(null===i&&null===n&&(null===o||1===o||-1===o))return!0;throw Error(h+"Invalid BigNumber: "+t)},D.maximum=D.max=function(){return z(arguments,o.lt)},D.minimum=D.min=function(){return z(arguments,o.gt)},D.random=function(){var t=9007199254740992*Math.random()&2097151?function(){return u(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(e){var r,i,n,o,a,f=0,c=[],d=new D(I);if(null==e?e=S:w(e,0,g),o=s(e/l),T)if(crypto.getRandomValues){for(r=crypto.getRandomValues(new Uint32Array(o*=2));f>>11))>=9e15?(i=crypto.getRandomValues(new Uint32Array(2)),r[f]=i[0],r[f+1]=i[1]):(c.push(a%1e14),f+=2);f=o/2}else{if(!crypto.randomBytes)throw T=!1,Error(h+"crypto unavailable");for(r=crypto.randomBytes(o*=7);f=9e15?crypto.randomBytes(7).copy(r,f):(c.push(a%1e14),f+=7);f=o/7}if(!T)for(;f=10;a/=10,f++);fr-1&&(null==a[n+1]&&(a[n+1]=0),a[n+1]+=a[n]/r|0,a[n]%=r)}return a.reverse()}return function(e,i,n,o,a){var s,u,h,f,c,l,d,p,m=e.indexOf("."),g=S,b=E;for(m>=0&&(f=R,R=0,e=e.replace(".",""),l=(p=new D(i)).pow(e.length-m),R=f,p.c=t(A(v(l.c),l.e,"0"),10,n,"0123456789"),p.e=p.c.length),h=f=(d=t(e,i,n,a?(s=j,"0123456789"):(s="0123456789",j))).length;0==d[--f];d.pop());if(!d[0])return s.charAt(0);if(m<0?--h:(l.c=d,l.e=h,l.s=o,d=(l=r(l,p,g,b,n)).c,c=l.r,h=l.e),m=d[u=h+g+1],f=n/2,c=c||u<0||null!=d[u+1],c=b<4?(null!=m||c)&&(0==b||b==(l.s<0?3:2)):m>f||m==f&&(4==b||c||6==b&&1&d[u-1]||b==(l.s<0?8:7)),u<1||!d[0])e=c?A(s.charAt(1),-g,s.charAt(0)):s.charAt(0);else{if(d.length=u,c)for(--n;++d[--u]>n;)d[u]=0,u||(++h,d=[1].concat(d));for(f=d.length;!d[--f];);for(m=0,e="";m<=f;e+=s.charAt(d[m++]));e=A(e,h,s.charAt(0))}return e}}(),r=function(){function t(t,e,r){var i,n,o,a,s=0,u=t.length,h=e%m,f=e/m|0;for(t=t.slice();u--;)s=((n=h*(o=t[u]%m)+(i=f*o+(a=t[u]/m|0)*h)%m*m+s)/r|0)+(i/m|0)+f*a,t[u]=n%r;return s&&(t=[s].concat(t)),t}function e(t,e,r,i){var n,o;if(r!=i)o=r>i?1:-1;else for(n=o=0;ne[n]?1:-1;break}return o}function r(t,e,r,i){for(var n=0;r--;)t[r]-=n,n=t[r]1;t.splice(0,1));}return function(i,n,o,a,s){var h,f,d,p,m,g,v,y,w,_,M,A,I,S,E,k,x,B=i.s==n.s?1:-1,C=i.c,T=n.c;if(!C||!C[0]||!T||!T[0])return new D(i.s&&n.s&&(C?!T||C[0]!=T[0]:T)?C&&0==C[0]||!T?0*B:B/0:NaN);for(w=(y=new D(B)).c=[],B=o+(f=i.e-n.e)+1,s||(s=c,f=b(i.e/l)-b(n.e/l),B=B/l|0),d=0;T[d]==(C[d]||0);d++);if(T[d]>(C[d]||0)&&f--,B<0)w.push(1),p=!0;else{for(S=C.length,k=T.length,d=0,B+=2,(m=u(s/(T[0]+1)))>1&&(T=t(T,m,s),C=t(C,m,s),k=T.length,S=C.length),I=k,M=(_=C.slice(0,k)).length;M=s/2&&E++;do{if(m=0,(h=e(T,_,k,M))<0){if(A=_[0],k!=M&&(A=A*s+(_[1]||0)),(m=u(A/E))>1)for(m>=s&&(m=s-1),v=(g=t(T,m,s)).length,M=_.length;1==e(g,_,v,M);)m--,r(g,k=10;B/=10,d++);q(y,o+(y.e=d+f*l-1)+1,a,p)}else y.e=f,y.r=+p;return y}}(),n=function(){var t=/^(-?)0([xbo])(?=\w[\w.]*$)/i,e=/^([^.]+)\.$/,r=/^\.([^.]+)$/,i=/^-?(Infinity|NaN)$/,n=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(o,a,s,u){var f,c=s?a:a.replace(n,"");if(i.test(c))o.s=isNaN(c)?null:c<0?-1:1;else{if(!s&&(c=c.replace(t,(function(t,e,r){return f="x"==(r=r.toLowerCase())?16:"b"==r?2:8,u&&u!=f?t:e})),u&&(f=u,c=c.replace(e,"$1").replace(r,"0.$1")),a!=c))return new D(c,f);if(D.DEBUG)throw Error(h+"Not a"+(u?" base "+u:"")+" number: "+a);o.s=null}o.c=o.e=null}}(),o.absoluteValue=o.abs=function(){var t=new D(this);return t.s<0&&(t.s=1),t},o.comparedTo=function(t,e){return y(this,new D(t,e))},o.decimalPlaces=o.dp=function(t,e){var r,i,n,o=this;if(null!=t)return w(t,0,g),null==e?e=E:w(e,0,8),q(new D(o),t+o.e+1,e);if(!(r=o.c))return null;if(i=((n=r.length-1)-b(this.e/l))*l,n=r[n])for(;n%10==0;n/=10,i--);return i<0&&(i=0),i},o.dividedBy=o.div=function(t,e){return r(this,new D(t,e),S,E)},o.dividedToIntegerBy=o.idiv=function(t,e){return r(this,new D(t,e),0,1)},o.exponentiatedBy=o.pow=function(t,e){var r,i,n,o,a,f,c,d,p=this;if((t=new D(t)).c&&!t.isInteger())throw Error(h+"Exponent not an integer: "+U(t));if(null!=e&&(e=new D(e)),a=t.e>14,!p.c||!p.c[0]||1==p.c[0]&&!p.e&&1==p.c.length||!t.c||!t.c[0])return d=new D(Math.pow(+U(p),a?2-_(t):+U(t))),e?d.mod(e):d;if(f=t.s<0,e){if(e.c?!e.c[0]:!e.s)return new D(NaN);(i=!f&&p.isInteger()&&e.isInteger())&&(p=p.mod(e))}else{if(t.e>9&&(p.e>0||p.e<-1||(0==p.e?p.c[0]>1||a&&p.c[1]>=24e7:p.c[0]<8e13||a&&p.c[0]<=9999975e7)))return o=p.s<0&&_(t)?-0:0,p.e>-1&&(o=1/o),new D(f?1/o:o);R&&(o=s(R/l+2))}for(a?(r=new D(.5),f&&(t.s=1),c=_(t)):c=(n=Math.abs(+U(t)))%2,d=new D(I);;){if(c){if(!(d=d.times(p)).c)break;o?d.c.length>o&&(d.c.length=o):i&&(d=d.mod(e))}if(n){if(0===(n=u(n/2)))break;c=n%2}else if(q(t=t.times(r),t.e+1,1),t.e>14)c=_(t);else{if(0===(n=+U(t)))break;c=n%2}p=p.times(p),o?p.c&&p.c.length>o&&(p.c.length=o):i&&(p=p.mod(e))}return i?d:(f&&(d=I.div(d)),e?d.mod(e):o?q(d,R,E,void 0):d)},o.integerValue=function(t){var e=new D(this);return null==t?t=E:w(t,0,8),q(e,e.e+1,t)},o.isEqualTo=o.eq=function(t,e){return 0===y(this,new D(t,e))},o.isFinite=function(){return!!this.c},o.isGreaterThan=o.gt=function(t,e){return y(this,new D(t,e))>0},o.isGreaterThanOrEqualTo=o.gte=function(t,e){return 1===(e=y(this,new D(t,e)))||0===e},o.isInteger=function(){return!!this.c&&b(this.e/l)>this.c.length-2},o.isLessThan=o.lt=function(t,e){return y(this,new D(t,e))<0},o.isLessThanOrEqualTo=o.lte=function(t,e){return-1===(e=y(this,new D(t,e)))||0===e},o.isNaN=function(){return!this.s},o.isNegative=function(){return this.s<0},o.isPositive=function(){return this.s>0},o.isZero=function(){return!!this.c&&0==this.c[0]},o.minus=function(t,e){var r,i,n,o,a=this,s=a.s;if(e=(t=new D(t,e)).s,!s||!e)return new D(NaN);if(s!=e)return t.s=-e,a.plus(t);var u=a.e/l,h=t.e/l,f=a.c,d=t.c;if(!u||!h){if(!f||!d)return f?(t.s=-e,t):new D(d?a:NaN);if(!f[0]||!d[0])return d[0]?(t.s=-e,t):new D(f[0]?a:3==E?-0:0)}if(u=b(u),h=b(h),f=f.slice(),s=u-h){for((o=s<0)?(s=-s,n=f):(h=u,n=d),n.reverse(),e=s;e--;n.push(0));n.reverse()}else for(i=(o=(s=f.length)<(e=d.length))?s:e,s=e=0;e0)for(;e--;f[r++]=0);for(e=c-1;i>s;){if(f[--i]=0;){for(r=0,p=A[n]%w,g=A[n]/w|0,o=n+(a=u);o>n;)r=((h=p*(h=M[--a]%w)+(s=g*h+(f=M[a]/w|0)*p)%w*w+v[o]+r)/y|0)+(s/w|0)+g*f,v[o--]=h%y;v[o]=r}return r?++i:v.splice(0,1),K(t,v,i)},o.negated=function(){var t=new D(this);return t.s=-t.s||null,t},o.plus=function(t,e){var r,i=this,n=i.s;if(e=(t=new D(t,e)).s,!n||!e)return new D(NaN);if(n!=e)return t.s=-e,i.minus(t);var o=i.e/l,a=t.e/l,s=i.c,u=t.c;if(!o||!a){if(!s||!u)return new D(n/0);if(!s[0]||!u[0])return u[0]?t:new D(s[0]?i:0*n)}if(o=b(o),a=b(a),s=s.slice(),n=o-a){for(n>0?(a=o,r=u):(n=-n,r=s),r.reverse();n--;r.push(0));r.reverse()}for((n=s.length)-(e=u.length)<0&&(r=u,u=s,s=r,e=n),n=0;e;)n=(s[--e]=s[e]+u[e]+n)/c|0,s[e]=c===s[e]?0:s[e]%c;return n&&(s=[n].concat(s),++a),K(t,s,a)},o.precision=o.sd=function(t,e){var r,i,n,o=this;if(null!=t&&t!==!!t)return w(t,1,g),null==e?e=E:w(e,0,8),q(new D(o),t,e);if(!(r=o.c))return null;if(i=(n=r.length-1)*l+1,n=r[n]){for(;n%10==0;n/=10,i--);for(n=r[0];n>=10;n/=10,i++);}return t&&o.e+1>i&&(i=o.e+1),i},o.shiftedBy=function(t){return w(t,-d,d),this.times("1e"+t)},o.squareRoot=o.sqrt=function(){var t,e,i,n,o,a=this,s=a.c,u=a.s,h=a.e,f=S+4,c=new D("0.5");if(1!==u||!s||!s[0])return new D(!u||u<0&&(!s||s[0])?NaN:s?a:1/0);if(0==(u=Math.sqrt(+U(a)))||u==1/0?(((e=v(s)).length+h)%2==0&&(e+="0"),u=Math.sqrt(+e),h=b((h+1)/2)-(h<0||h%2),i=new D(e=u==1/0?"1e"+h:(e=u.toExponential()).slice(0,e.indexOf("e")+1)+h)):i=new D(u+""),i.c[0])for((u=(h=i.e)+f)<3&&(u=0);;)if(o=i,i=c.times(o.plus(r(a,o,f,1))),v(o.c).slice(0,u)===(e=v(i.c)).slice(0,u)){if(i.e0&&m>0){for(o=m%s||s,c=p.substr(0,o);o0&&(c+=f+p.slice(o)),d&&(c="-"+c)}i=l?c+(r.decimalSeparator||"")+((u=+r.fractionGroupSize)?l.replace(new RegExp("\\d{"+u+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):l):c}return(r.prefix||"")+i+(r.suffix||"")},o.toFraction=function(t){var e,i,n,o,a,s,u,f,c,d,m,g,b=this,y=b.c;if(null!=t&&(!(u=new D(t)).isInteger()&&(u.c||1!==u.s)||u.lt(I)))throw Error(h+"Argument "+(u.isInteger()?"out of range: ":"not an integer: ")+U(u));if(!y)return new D(b);for(e=new D(I),c=i=new D(I),n=f=new D(I),g=v(y),a=e.e=g.length-b.e-1,e.c[0]=p[(s=a%l)<0?l+s:s],t=!t||u.comparedTo(e)>0?a>0?e:c:u,s=C,C=1/0,u=new D(g),f.c[0]=0;d=r(u,e,0,1),1!=(o=i.plus(d.times(n))).comparedTo(t);)i=n,n=o,c=f.plus(d.times(o=c)),f=o,e=u.minus(d.times(o=e)),u=o;return o=r(t.minus(i),n,0,1),f=f.plus(o.times(c)),i=i.plus(o.times(n)),f.s=c.s=b.s,m=r(c,n,a*=2,E).minus(b).abs().comparedTo(r(f,i,a,E).minus(b).abs())<1?[c,n]:[f,i],C=s,m},o.toNumber=function(){return+U(this)},o.toPrecision=function(t,e){return null!=t&&w(t,1,g),N(this,t,e,2)},o.toString=function(t){var e,r=this,n=r.s,o=r.e;return null===o?n?(e="Infinity",n<0&&(e="-"+e)):e="NaN":(null==t?e=o<=k||o>=x?M(v(r.c),o):A(v(r.c),o,"0"):10===t?e=A(v((r=q(new D(r),S+o+1,E)).c),r.e,"0"):(w(t,2,j.length,"Base"),e=i(A(v(r.c),o,"0"),10,t,n,!0)),n<0&&r.c[0]&&(e="-"+e)),e},o.valueOf=o.toJSON=function(){return U(this)},o._isBigNumber=!0,null!=e&&D.set(e),D}()).default=o.BigNumber=o,void 0===(i=function(){return o}.call(e,r,e,t))||(t.exports=i)}()},function(t,e,r){"use strict";var i=r(81).decOut,n=r(123),o=r(3),a=r(3),s=a.hexToCy,u=a.isNewVersion,h=r(45),f=r(143),c=f.genTxParam,l=f.signTx,d=r(324),p=d.Asset,m=d.Token,g=d.Witness,b=d.ZPkg,v=r(144),y=v.selectUtxos,w=v.buildTxParam,_=v.PreTxParam,M=v.utxo,A=r(123),I=A.createPkrHash,S=A.createOldPkrHash,E={account:h,Wallet:n,decOut:i,genSeed:A.genSeed,createPkrHash:I,createOldPkrHash:S,selectUtxos:y,buildTxParam:w,entropyToMnemonic:A.entropyToMnemonic,PreTxParam:_,utxo:M,genTxParam:c,signTx:l,Asset:p,Token:m,Witness:g,ZPkg:b,hexToCy:s,isNewVersion:u,utils:o};t.exports=E},function(t,e){},function(t,e,r){"use strict";var i=r(2).Buffer,n=r(189);t.exports=function(){function t(){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.head=null,this.tail=null,this.length=0}return t.prototype.push=function(t){var e={data:t,next:null};this.length>0?this.tail.next=e:this.head=e,this.tail=e,++this.length},t.prototype.unshift=function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length},t.prototype.shift=function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}},t.prototype.clear=function(){this.head=this.tail=null,this.length=0},t.prototype.join=function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r},t.prototype.concat=function(t){if(0===this.length)return i.alloc(0);if(1===this.length)return this.head.data;for(var e,r,n,o=i.allocUnsafe(t>>>0),a=this.head,s=0;a;)e=a.data,r=o,n=s,e.copy(r,n),s+=a.data.length,a=a.next;return o},t}(),n&&n.inspect&&n.inspect.custom&&(t.exports.prototype[n.inspect.custom]=function(){var t=n.inspect({length:this.length});return this.constructor.name+" "+t})},function(t,e){},function(t,e,r){(function(t){var i="undefined"!==typeof t&&t||"undefined"!==typeof self&&self||window,n=Function.prototype.apply;function o(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new o(n.call(setTimeout,i,arguments),clearTimeout)},e.setInterval=function(){return new o(n.call(setInterval,i,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(i,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},r(191),e.setImmediate="undefined"!==typeof self&&self.setImmediate||"undefined"!==typeof t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!==typeof self&&self.clearImmediate||"undefined"!==typeof t&&t.clearImmediate||this&&this.clearImmediate}).call(this,r(10))},function(t,e,r){(function(t,e){!function(t,r){"use strict";if(!t.setImmediate){var i,n=1,o={},a=!1,s=t.document,u=Object.getPrototypeOf&&Object.getPrototypeOf(t);u=u&&u.setTimeout?u:t,"[object process]"==={}.toString.call(t.process)?i=function(t){e.nextTick((function(){f(t)}))}:function(){if(t.postMessage&&!t.importScripts){var e=!0,r=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=r,e}}()?function(){var e="setImmediate$"+Math.random()+"$",r=function(r){r.source===t&&"string"===typeof r.data&&0===r.data.indexOf(e)&&f(+r.data.slice(e.length))};t.addEventListener?t.addEventListener("message",r,!1):t.attachEvent("onmessage",r),i=function(r){t.postMessage(e+r,"*")}}():t.MessageChannel?function(){var t=new MessageChannel;t.port1.onmessage=function(t){f(t.data)},i=function(e){t.port2.postMessage(e)}}():s&&"onreadystatechange"in s.createElement("script")?function(){var t=s.documentElement;i=function(e){var r=s.createElement("script");r.onreadystatechange=function(){f(e),r.onreadystatechange=null,t.removeChild(r),r=null},t.appendChild(r)}}():i=function(t){setTimeout(f,0,t)},u.setImmediate=function(t){"function"!==typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),r=0;r>>2}function f(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,c=0;c<16;++c)r[c]=t.readInt32BE(4*c);for(;c<80;++c)r[c]=r[c-3]^r[c-8]^r[c-14]^r[c-16];for(var l=0;l<80;++l){var d=~~(l/20),p=0|((e=i)<<5|e>>>27)+f(d,n,o,s)+u+r[l]+a[d];u=s,s=o,o=h(n),n=i,i=p}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(1),n=r(24),o=r(2).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<5|t>>>27}function f(t){return t<<30|t>>>2}function c(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,l=0;l<16;++l)r[l]=t.readInt32BE(4*l);for(;l<80;++l)r[l]=(e=r[l-3]^r[l-8]^r[l-14]^r[l-16])<<1|e>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=h(i)+c(p,n,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=f(n),n=i,i=m}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(1),n=r(87),o=r(24),a=r(2).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}i(u,n),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 t=a.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t},t.exports=u},function(t,e,r){var i=r(1),n=r(88),o=r(24),a=r(2).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}i(u,n),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 t=a.allocUnsafe(48);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){"use strict";var i=r(1),n=r(2).Buffer,o=r(16),a=n.alloc(128),s=64;function u(t,e){o.call(this,"digest"),"string"===typeof e&&(e=n.from(e)),this._alg=t,this._key=e,e.length>s?e=t(e):e.length>>0},e.writeUInt32BE=function(t,e,r){t[0+r]=e>>>24,t[1+r]=e>>>16&255,t[2+r]=e>>>8&255,t[3+r]=255&e},e.ip=function(t,e,r,i){for(var n=0,o=0,a=6;a>=0;a-=2){for(var s=0;s<=24;s+=8)n<<=1,n|=e>>>s+a&1;for(s=0;s<=24;s+=8)n<<=1,n|=t>>>s+a&1}for(a=6;a>=0;a-=2){for(s=1;s<=25;s+=8)o<<=1,o|=e>>>s+a&1;for(s=1;s<=25;s+=8)o<<=1,o|=t>>>s+a&1}r[i+0]=n>>>0,r[i+1]=o>>>0},e.rip=function(t,e,r,i){for(var n=0,o=0,a=0;a<4;a++)for(var s=24;s>=0;s-=8)n<<=1,n|=e>>>s+a&1,n<<=1,n|=t>>>s+a&1;for(a=4;a<8;a++)for(s=24;s>=0;s-=8)o<<=1,o|=e>>>s+a&1,o<<=1,o|=t>>>s+a&1;r[i+0]=n>>>0,r[i+1]=o>>>0},e.pc1=function(t,e,r,i){for(var n=0,o=0,a=7;a>=5;a--){for(var s=0;s<=24;s+=8)n<<=1,n|=e>>s+a&1;for(s=0;s<=24;s+=8)n<<=1,n|=t>>s+a&1}for(s=0;s<=24;s+=8)n<<=1,n|=e>>s+a&1;for(a=1;a<=3;a++){for(s=0;s<=24;s+=8)o<<=1,o|=e>>s+a&1;for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1}for(s=0;s<=24;s+=8)o<<=1,o|=t>>s+a&1;r[i+0]=n>>>0,r[i+1]=o>>>0},e.r28shl=function(t,e){return t<>>28-e};var i=[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];e.pc2=function(t,e,r,n){for(var o=0,a=0,s=i.length>>>1,u=0;u>>i[u]&1;for(u=s;u>>i[u]&1;r[n+0]=o>>>0,r[n+1]=a>>>0},e.expand=function(t,e,r){var i=0,n=0;i=(1&t)<<5|t>>>27;for(var o=23;o>=15;o-=4)i<<=6,i|=t>>>o&63;for(o=11;o>=3;o-=4)n|=t>>>o&63,n<<=6;n|=(31&t)<<1|t>>>31,e[r+0]=i>>>0,e[r+1]=n>>>0};var n=[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];e.substitute=function(t,e){for(var r=0,i=0;i<4;i++){r<<=4,r|=n[64*i+(t>>>18-6*i&63)]}for(i=0;i<4;i++){r<<=4,r|=n[256+64*i+(e>>>18-6*i&63)]}return r>>>0};var o=[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];e.permute=function(t){for(var e=0,r=0;r>>o[r]&1;return e>>>0},e.padSplit=function(t,e,r){for(var i=t.toString(2);i.length0;i--)e+=this._buffer(t,e),r+=this._flushBuffer(n,r);return e+=this._buffer(t,e),n},n.prototype.final=function(t){var e,r;return t&&(e=this.update(t)),r="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),e?e.concat(r):r},n.prototype._pad=function(t,e){if(0===e)return!1;for(;e>>1];r=a.r28shl(r,s),n=a.r28shl(n,s),a.pc2(r,n,t.keys,o)}},h.prototype._update=function(t,e,r,i){var n=this._desState,o=a.readUInt32BE(t,e),s=a.readUInt32BE(t,e+4);a.ip(o,s,n.tmp,0),o=n.tmp[0],s=n.tmp[1],"encrypt"===this.type?this._encrypt(n,o,s,n.tmp,0):this._decrypt(n,o,s,n.tmp,0),o=n.tmp[0],s=n.tmp[1],a.writeUInt32BE(r,o,i),a.writeUInt32BE(r,s,i+4)},h.prototype._pad=function(t,e){for(var r=t.length-e,i=e;i>>0,o=l}a.rip(s,o,i,n)},h.prototype._decrypt=function(t,e,r,i,n){for(var o=r,s=e,u=t.keys.length-2;u>=0;u-=2){var h=t.keys[u],f=t.keys[u+1];a.expand(o,t.tmp,0),h^=t.tmp[0],f^=t.tmp[1];var c=a.substitute(h,f),l=o;o=(s^a.permute(c))>>>0,s=l}a.rip(o,s,i,n)}},function(t,e,r){"use strict";var i=r(13),n=r(1),o={};function a(t){i.equal(t.length,8,"Invalid IV length"),this.iv=new Array(8);for(var e=0;e15){var t=this.cache.slice(0,16);return this.cache=this.cache.slice(16),t}return null},l.prototype.flush=function(){for(var t=16-this.cache.length,e=o.allocUnsafe(t),r=-1;++r>a%8,t._prev=o(t._prev,r?i:n);return s}function o(t,e){var r=t.length,n=-1,o=i.allocUnsafe(t.length);for(t=i.concat([t,i.from([e])]);++n>7;return o}e.encrypt=function(t,e,r){for(var o=e.length,a=i.allocUnsafe(o),s=-1;++s>>0,0),e.writeUInt32BE(t[1]>>>0,4),e.writeUInt32BE(t[2]>>>0,8),e.writeUInt32BE(t[3]>>>0,12),e}function a(t){this.h=t,this.state=i.alloc(16,0),this.cache=i.allocUnsafe(0)}a.prototype.ghash=function(t){for(var e=-1;++e0;e--)i[e]=i[e]>>>1|(1&i[e-1])<<31;i[0]=i[0]>>>1,r&&(i[0]=i[0]^225<<24)}this.state=o(n)},a.prototype.update=function(t){var e;for(this.cache=i.concat([this.cache,t]);this.cache.length>=16;)e=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(e)},a.prototype.final=function(t,e){return this.cache.length&&this.ghash(i.concat([this.cache,n],16)),this.ghash(o([0,t,0,e])),this.state},t.exports=a},function(t,e,r){var i=r(99),n=r(2).Buffer,o=r(56),a=r(100),s=r(16),u=r(39),h=r(40);function f(t,e,r){s.call(this),this._cache=new c,this._last=void 0,this._cipher=new u.AES(e),this._prev=n.from(r),this._mode=t,this._autopadding=!0}function c(){this.cache=n.allocUnsafe(0)}function l(t,e,r){var s=o[t.toLowerCase()];if(!s)throw new TypeError("invalid suite type");if("string"===typeof r&&(r=n.from(r)),"GCM"!==s.mode&&r.length!==s.iv)throw new TypeError("invalid iv length "+r.length);if("string"===typeof e&&(e=n.from(e)),e.length!==s.key/8)throw new TypeError("invalid key length "+e.length);return"stream"===s.type?new a(s.module,e,r,!0):"auth"===s.type?new i(s.module,e,r,!0):new f(s.module,e,r)}r(1)(f,s),f.prototype._update=function(t){var e,r;this._cache.add(t);for(var i=[];e=this._cache.get(this._autopadding);)r=this._mode.decrypt(this,e),i.push(r);return n.concat(i)},f.prototype._final=function(){var t=this._cache.flush();if(this._autopadding)return function(t){var e=t[15];if(e<1||e>16)throw new Error("unable to decrypt data");var r=-1;for(;++r16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e}else if(this.cache.length>=16)return e=this.cache.slice(0,16),this.cache=this.cache.slice(16),e;return null},c.prototype.flush=function(){if(this.cache.length)return this.cache},e.createDecipher=function(t,e){var r=o[t.toLowerCase()];if(!r)throw new TypeError("invalid suite type");var i=h(e,!1,r.key,r.iv);return l(t,i.key,i.iv)},e.createDecipheriv=l},function(t,e){e["des-ecb"]={key:8,iv:0},e["des-cbc"]=e.des={key:8,iv:8},e["des-ede3-cbc"]=e.des3={key:24,iv:8},e["des-ede3"]={key:24,iv:0},e["des-ede-cbc"]={key:16,iv:8},e["des-ede"]={key:16,iv:0}},function(t,e,r){(function(t){var i=r(101),n=r(226),o=r(227);var a={binary:!0,hex:!0,base64:!0};e.DiffieHellmanGroup=e.createDiffieHellmanGroup=e.getDiffieHellman=function(e){var r=new t(n[e].prime,"hex"),i=new t(n[e].gen,"hex");return new o(r,i)},e.createDiffieHellman=e.DiffieHellman=function e(r,n,s,u){return t.isBuffer(n)||void 0===a[n]?e(r,"binary",n,s):(n=n||"binary",u=u||"binary",s=s||new t([2]),t.isBuffer(s)||(s=new t(s,u)),"number"===typeof r?new o(i(r,s),s,!0):(t.isBuffer(r)||(r=new t(r,n)),new o(r,s,!0)))}}).call(this,r(0).Buffer)},function(t,e){},function(t,e){},function(t){t.exports=JSON.parse('{"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"}}')},function(t,e,r){(function(e){var i=r(5),n=new(r(102)),o=new i(24),a=new i(11),s=new i(10),u=new i(3),h=new i(7),f=r(101),c=r(21);function l(t,r){return r=r||"utf8",e.isBuffer(t)||(t=new e(t,r)),this._pub=new i(t),this}function d(t,r){return r=r||"utf8",e.isBuffer(t)||(t=new e(t,r)),this._priv=new i(t),this}t.exports=m;var p={};function m(t,e,r){this.setGenerator(e),this.__prime=new i(t),this._prime=i.mont(this.__prime),this._primeLen=t.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,r?(this.setPublicKey=l,this.setPrivateKey=d):this._primeCode=8}function g(t,r){var i=new e(t.toArray());return r?i.toString(r):i}Object.defineProperty(m.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!==typeof this._primeCode&&(this._primeCode=function(t,e){var r=e.toString("hex"),i=[r,t.toString(16)].join("_");if(i in p)return p[i];var c,l=0;if(t.isEven()||!f.simpleSieve||!f.fermatTest(t)||!n.test(t))return l+=1,l+="02"===r||"05"===r?8:4,p[i]=l,l;switch(n.test(t.shrn(1))||(l+=2),r){case"02":t.mod(o).cmp(a)&&(l+=8);break;case"05":(c=t.mod(s)).cmp(u)&&c.cmp(h)&&(l+=8);break;default:l+=4}return p[i]=l,l}(this.__prime,this.__gen)),this._primeCode}}),m.prototype.generateKeys=function(){return this._priv||(this._priv=new i(c(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},m.prototype.computeSecret=function(t){var r=(t=(t=new i(t)).toRed(this._prime)).redPow(this._priv).fromRed(),n=new e(r.toArray()),o=this.getPrime();if(n.length0&&r.ishrn(i),r}function c(t,r,n){var o,a;do{for(o=new e(0);8*o.length=0&&(a=e,s=r),i.negative&&(i=i.neg(),o=o.neg()),a.negative&&(a=a.neg(),s=s.neg()),[{a:i,b:o},{a:a,b:s}]},u.prototype._endoSplit=function(t){var e=this.endo.basis,r=e[0],i=e[1],n=i.b.mul(t).divRound(this.n),o=r.b.neg().mul(t).divRound(this.n),a=n.mul(r.a),s=o.mul(i.a),u=n.mul(r.b),h=o.mul(i.b);return{k1:t.sub(a).sub(s),k2:u.add(h).neg()}},u.prototype.pointFromX=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr().redMul(t).redIAdd(t.redMul(this.a)).redIAdd(this.b),i=r.redSqrt();if(0!==i.redSqr().redSub(r).cmp(this.zero))throw new Error("invalid point");var o=i.fromRed().isOdd();return(e&&!o||!e&&o)&&(i=i.redNeg()),this.point(t,i)},u.prototype.validate=function(t){if(t.inf)return!0;var e=t.x,r=t.y,i=this.a.redMul(e),n=e.redSqr().redMul(e).redIAdd(i).redIAdd(this.b);return 0===r.redSqr().redISub(n).cmpn(0)},u.prototype._endoWnafMulAdd=function(t,e,r){for(var i=this._endoWnafT1,n=this._endoWnafT2,o=0;o":""},h.prototype.isInfinity=function(){return this.inf},h.prototype.add=function(t){if(this.inf)return t;if(t.inf)return this;if(this.eq(t))return this.dbl();if(this.neg().eq(t))return this.curve.point(null,null);if(0===this.x.cmp(t.x))return this.curve.point(null,null);var e=this.y.redSub(t.y);0!==e.cmpn(0)&&(e=e.redMul(this.x.redSub(t.x).redInvm()));var r=e.redSqr().redISub(this.x).redISub(t.x),i=e.redMul(this.x.redSub(r)).redISub(this.y);return this.curve.point(r,i)},h.prototype.dbl=function(){if(this.inf)return this;var t=this.y.redAdd(this.y);if(0===t.cmpn(0))return this.curve.point(null,null);var e=this.curve.a,r=this.x.redSqr(),i=t.redInvm(),n=r.redAdd(r).redIAdd(r).redIAdd(e).redMul(i),o=n.redSqr().redISub(this.x.redAdd(this.x)),a=n.redMul(this.x.redSub(o)).redISub(this.y);return this.curve.point(o,a)},h.prototype.getX=function(){return this.x.fromRed()},h.prototype.getY=function(){return this.y.fromRed()},h.prototype.mul=function(t){return t=new n(t,16),this.isInfinity()?this:this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve.endo?this.curve._endoWnafMulAdd([this],[t]):this.curve._wnafMul(this,t)},h.prototype.mulAdd=function(t,e,r){var i=[this,e],n=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n):this.curve._wnafMulAdd(1,i,n,2)},h.prototype.jmulAdd=function(t,e,r){var i=[this,e],n=[t,r];return this.curve.endo?this.curve._endoWnafMulAdd(i,n,!0):this.curve._wnafMulAdd(1,i,n,2,!0)},h.prototype.eq=function(t){return this===t||this.inf===t.inf&&(this.inf||0===this.x.cmp(t.x)&&0===this.y.cmp(t.y))},h.prototype.neg=function(t){if(this.inf)return this;var e=this.curve.point(this.x,this.y.redNeg());if(t&&this.precomputed){var r=this.precomputed,i=function(t){return t.neg()};e.precomputed={naf:r.naf&&{wnd:r.naf.wnd,points:r.naf.points.map(i)},doubles:r.doubles&&{step:r.doubles.step,points:r.doubles.points.map(i)}}}return e},h.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},o(f,a.BasePoint),u.prototype.jpoint=function(t,e,r){return new f(this,t,e,r)},f.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var t=this.z.redInvm(),e=t.redSqr(),r=this.x.redMul(e),i=this.y.redMul(e).redMul(t);return this.curve.point(r,i)},f.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},f.prototype.add=function(t){if(this.isInfinity())return t;if(t.isInfinity())return this;var e=t.z.redSqr(),r=this.z.redSqr(),i=this.x.redMul(e),n=t.x.redMul(r),o=this.y.redMul(e.redMul(t.z)),a=t.y.redMul(r.redMul(this.z)),s=i.redSub(n),u=o.redSub(a);if(0===s.cmpn(0))return 0!==u.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var h=s.redSqr(),f=h.redMul(s),c=i.redMul(h),l=u.redSqr().redIAdd(f).redISub(c).redISub(c),d=u.redMul(c.redISub(l)).redISub(o.redMul(f)),p=this.z.redMul(t.z).redMul(s);return this.curve.jpoint(l,d,p)},f.prototype.mixedAdd=function(t){if(this.isInfinity())return t.toJ();if(t.isInfinity())return this;var e=this.z.redSqr(),r=this.x,i=t.x.redMul(e),n=this.y,o=t.y.redMul(e).redMul(this.z),a=r.redSub(i),s=n.redSub(o);if(0===a.cmpn(0))return 0!==s.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var u=a.redSqr(),h=u.redMul(a),f=r.redMul(u),c=s.redSqr().redIAdd(h).redISub(f).redISub(f),l=s.redMul(f.redISub(c)).redISub(n.redMul(h)),d=this.z.redMul(a);return this.curve.jpoint(c,l,d)},f.prototype.dblp=function(t){if(0===t)return this;if(this.isInfinity())return this;if(!t)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var e=this,r=0;r=0)return!1;if(r.redIAdd(n),0===this.x.cmp(r))return!0}},f.prototype.inspect=function(){return this.isInfinity()?"":""},f.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},function(t,e,r){"use strict";var i=r(5),n=r(1),o=r(41),a=r(14);function s(t){o.call(this,"mont",t),this.a=new i(t.a,16).toRed(this.red),this.b=new i(t.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 u(t,e,r){o.BasePoint.call(this,t,"projective"),null===e&&null===r?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new i(e,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)))}n(s,o),t.exports=s,s.prototype.validate=function(t){var e=t.normalize().x,r=e.redSqr(),i=r.redMul(e).redAdd(r.redMul(this.a)).redAdd(e);return 0===i.redSqrt().redSqr().cmp(i)},n(u,o.BasePoint),s.prototype.decodePoint=function(t,e){return this.point(a.toArray(t,e),1)},s.prototype.point=function(t,e){return new u(this,t,e)},s.prototype.pointFromJSON=function(t){return u.fromJSON(this,t)},u.prototype.precompute=function(){},u.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},u.fromJSON=function(t,e){return new u(t,e[0],e[1]||t.one)},u.prototype.inspect=function(){return this.isInfinity()?"":""},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},u.prototype.dbl=function(){var t=this.x.redAdd(this.z).redSqr(),e=this.x.redSub(this.z).redSqr(),r=t.redSub(e),i=t.redMul(e),n=r.redMul(e.redAdd(this.curve.a24.redMul(r)));return this.curve.point(i,n)},u.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.diffAdd=function(t,e){var r=this.x.redAdd(this.z),i=this.x.redSub(this.z),n=t.x.redAdd(t.z),o=t.x.redSub(t.z).redMul(r),a=n.redMul(i),s=e.z.redMul(o.redAdd(a).redSqr()),u=e.x.redMul(o.redISub(a).redSqr());return this.curve.point(s,u)},u.prototype.mul=function(t){for(var e=t.clone(),r=this,i=this.curve.point(null,null),n=[];0!==e.cmpn(0);e.iushrn(1))n.push(e.andln(1));for(var o=n.length-1;o>=0;o--)0===n[o]?(r=r.diffAdd(i,this),i=i.dbl()):(i=r.diffAdd(i,this),r=r.dbl());return i},u.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},u.prototype.eq=function(t){return 0===this.getX().cmp(t.getX())},u.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},u.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},function(t,e,r){"use strict";var i=r(14),n=r(5),o=r(1),a=r(41),s=i.assert;function u(t){this.twisted=1!==(0|t.a),this.mOneA=this.twisted&&-1===(0|t.a),this.extended=this.mOneA,a.call(this,"edwards",t),this.a=new n(t.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new n(t.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new n(t.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),s(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1===(0|t.c)}function h(t,e,r,i,o){a.BasePoint.call(this,t,"projective"),null===e&&null===r&&null===i?(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 n(e,16),this.y=new n(r,16),this.z=i?new n(i,16):this.curve.one,this.t=o&&new n(o,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(u,a),t.exports=u,u.prototype._mulA=function(t){return this.mOneA?t.redNeg():this.a.redMul(t)},u.prototype._mulC=function(t){return this.oneC?t:this.c.redMul(t)},u.prototype.jpoint=function(t,e,r,i){return this.point(t,e,r,i)},u.prototype.pointFromX=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr(),i=this.c2.redSub(this.a.redMul(r)),o=this.one.redSub(this.c2.redMul(this.d).redMul(r)),a=i.redMul(o.redInvm()),s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");var u=s.fromRed().isOdd();return(e&&!u||!e&&u)&&(s=s.redNeg()),this.point(t,s)},u.prototype.pointFromY=function(t,e){(t=new n(t,16)).red||(t=t.toRed(this.red));var r=t.redSqr(),i=r.redSub(this.c2),o=r.redMul(this.d).redMul(this.c2).redSub(this.a),a=i.redMul(o.redInvm());if(0===a.cmp(this.zero)){if(e)throw new Error("invalid point");return this.point(this.zero,t)}var s=a.redSqrt();if(0!==s.redSqr().redSub(a).cmp(this.zero))throw new Error("invalid point");return s.fromRed().isOdd()!==e&&(s=s.redNeg()),this.point(s,t)},u.prototype.validate=function(t){if(t.isInfinity())return!0;t.normalize();var e=t.x.redSqr(),r=t.y.redSqr(),i=e.redMul(this.a).redAdd(r),n=this.c2.redMul(this.one.redAdd(this.d.redMul(e).redMul(r)));return 0===i.cmp(n)},o(h,a.BasePoint),u.prototype.pointFromJSON=function(t){return h.fromJSON(this,t)},u.prototype.point=function(t,e,r,i){return new h(this,t,e,r,i)},h.fromJSON=function(t,e){return new h(t,e[0],e[1],e[2])},h.prototype.inspect=function(){return this.isInfinity()?"":""},h.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},h.prototype._extDbl=function(){var t=this.x.redSqr(),e=this.y.redSqr(),r=this.z.redSqr();r=r.redIAdd(r);var i=this.curve._mulA(t),n=this.x.redAdd(this.y).redSqr().redISub(t).redISub(e),o=i.redAdd(e),a=o.redSub(r),s=i.redSub(e),u=n.redMul(a),h=o.redMul(s),f=n.redMul(s),c=a.redMul(o);return this.curve.point(u,h,c,f)},h.prototype._projDbl=function(){var t,e,r,i=this.x.redAdd(this.y).redSqr(),n=this.x.redSqr(),o=this.y.redSqr();if(this.curve.twisted){var a=(h=this.curve._mulA(n)).redAdd(o);if(this.zOne)t=i.redSub(n).redSub(o).redMul(a.redSub(this.curve.two)),e=a.redMul(h.redSub(o)),r=a.redSqr().redSub(a).redSub(a);else{var s=this.z.redSqr(),u=a.redSub(s).redISub(s);t=i.redSub(n).redISub(o).redMul(u),e=a.redMul(h.redSub(o)),r=a.redMul(u)}}else{var h=n.redAdd(o);s=this.curve._mulC(this.z).redSqr(),u=h.redSub(s).redSub(s);t=this.curve._mulC(i.redISub(h)).redMul(u),e=this.curve._mulC(h).redMul(n.redISub(o)),r=h.redMul(u)}return this.curve.point(t,e,r)},h.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},h.prototype._extAdd=function(t){var e=this.y.redSub(this.x).redMul(t.y.redSub(t.x)),r=this.y.redAdd(this.x).redMul(t.y.redAdd(t.x)),i=this.t.redMul(this.curve.dd).redMul(t.t),n=this.z.redMul(t.z.redAdd(t.z)),o=r.redSub(e),a=n.redSub(i),s=n.redAdd(i),u=r.redAdd(e),h=o.redMul(a),f=s.redMul(u),c=o.redMul(u),l=a.redMul(s);return this.curve.point(h,f,l,c)},h.prototype._projAdd=function(t){var e,r,i=this.z.redMul(t.z),n=i.redSqr(),o=this.x.redMul(t.x),a=this.y.redMul(t.y),s=this.curve.d.redMul(o).redMul(a),u=n.redSub(s),h=n.redAdd(s),f=this.x.redAdd(this.y).redMul(t.x.redAdd(t.y)).redISub(o).redISub(a),c=i.redMul(u).redMul(f);return this.curve.twisted?(e=i.redMul(h).redMul(a.redSub(this.curve._mulA(o))),r=u.redMul(h)):(e=i.redMul(h).redMul(a.redSub(o)),r=this.curve._mulC(u).redMul(h)),this.curve.point(c,e,r)},h.prototype.add=function(t){return this.isInfinity()?t:t.isInfinity()?this:this.curve.extended?this._extAdd(t):this._projAdd(t)},h.prototype.mul=function(t){return this._hasDoubles(t)?this.curve._fixedNafMul(this,t):this.curve._wnafMul(this,t)},h.prototype.mulAdd=function(t,e,r){return this.curve._wnafMulAdd(1,[this,e],[t,r],2,!1)},h.prototype.jmulAdd=function(t,e,r){return this.curve._wnafMulAdd(1,[this,e],[t,r],2,!0)},h.prototype.normalize=function(){if(this.zOne)return this;var t=this.z.redInvm();return this.x=this.x.redMul(t),this.y=this.y.redMul(t),this.t&&(this.t=this.t.redMul(t)),this.z=this.curve.one,this.zOne=!0,this},h.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},h.prototype.getX=function(){return this.normalize(),this.x.fromRed()},h.prototype.getY=function(){return this.normalize(),this.y.fromRed()},h.prototype.eq=function(t){return this===t||0===this.getX().cmp(t.getX())&&0===this.getY().cmp(t.getY())},h.prototype.eqXToP=function(t){var e=t.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(e))return!0;for(var r=t.clone(),i=this.curve.redN.redMul(this.z);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(e.redIAdd(i),0===this.x.cmp(e))return!0}},h.prototype.toP=h.prototype.normalize,h.prototype.mixedAdd=h.prototype.add},function(t,e,r){"use strict";e.sha1=r(235),e.sha224=r(236),e.sha256=r(106),e.sha384=r(237),e.sha512=r(107)},function(t,e,r){"use strict";var i=r(15),n=r(34),o=r(105),a=i.rotl32,s=i.sum32,u=i.sum32_5,h=o.ft_1,f=n.BlockHash,c=[1518500249,1859775393,2400959708,3395469782];function l(){if(!(this instanceof l))return new l;f.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}i.inherits(l,f),t.exports=l,l.blockSize=512,l.outSize=160,l.hmacStrength=80,l.padLength=64,l.prototype._update=function(t,e){for(var r=this.W,i=0;i<16;i++)r[i]=t[e+i];for(;ithis.blockSize&&(t=(new this.Hash).update(t).digest()),n(t.length<=this.blockSize);for(var e=t.length;e0))return a.iaddn(1),this.keyFromPrivate(a)}},c.prototype._truncateToN=function(t,e){var r=8*t.byteLength()-this.n.bitLength();return r>0&&(t=t.ushrn(r)),!e&&t.cmp(this.n)>=0?t.sub(this.n):t},c.prototype.sign=function(t,e,r,o){"object"===typeof r&&(o=r,r=null),o||(o={}),e=this.keyFromPrivate(e,r),t=this._truncateToN(new i(t,16));for(var a=this.n.byteLength(),s=e.getPrivate().toArray("be",a),u=t.toArray("be",a),h=new n({hash:this.hash,entropy:s,nonce:u,pers:o.pers,persEnc:o.persEnc||"utf8"}),c=this.n.sub(new i(1)),l=0;;l++){var d=o.k?o.k(l):new i(h.generate(this.n.byteLength()));if(!((d=this._truncateToN(d,!0)).cmpn(1)<=0||d.cmp(c)>=0)){var p=this.g.mul(d);if(!p.isInfinity()){var m=p.getX(),g=m.umod(this.n);if(0!==g.cmpn(0)){var b=d.invm(this.n).mul(g.mul(e.getPrivate()).iadd(t));if(0!==(b=b.umod(this.n)).cmpn(0)){var v=(p.getY().isOdd()?1:0)|(0!==m.cmp(g)?2:0);return o.canonical&&b.cmp(this.nh)>0&&(b=this.n.sub(b),v^=1),new f({r:g,s:b,recoveryParam:v})}}}}}},c.prototype.verify=function(t,e,r,n){t=this._truncateToN(new i(t,16)),r=this.keyFromPublic(r,n);var o=(e=new f(e,"hex")).r,a=e.s;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;if(a.cmpn(1)<0||a.cmp(this.n)>=0)return!1;var s,u=a.invm(this.n),h=u.mul(t).umod(this.n),c=u.mul(o).umod(this.n);return this.curve._maxwellTrick?!(s=this.g.jmulAdd(h,r.getPublic(),c)).isInfinity()&&s.eqXToP(o):!(s=this.g.mulAdd(h,r.getPublic(),c)).isInfinity()&&0===s.getX().umod(this.n).cmp(o)},c.prototype.recoverPubKey=function(t,e,r,n){u((3&r)===r,"The recovery param is more than two bits"),e=new f(e,n);var o=this.n,a=new i(t),s=e.r,h=e.s,c=1&r,l=r>>1;if(s.cmp(this.curve.p.umod(this.curve.n))>=0&&l)throw new Error("Unable to find sencond key candinate");s=l?this.curve.pointFromX(s.add(this.curve.n),c):this.curve.pointFromX(s,c);var d=e.r.invm(o),p=o.sub(a).mul(d).umod(o),m=h.mul(d).umod(o);return this.g.mulAdd(p,s,m)},c.prototype.getKeyRecoveryParam=function(t,e,r,i){if(null!==(e=new f(e,i)).recoveryParam)return e.recoveryParam;for(var n=0;n<4;n++){var o;try{o=this.recoverPubKey(t,e,n)}catch(t){continue}if(o.eq(r))return n}throw new Error("Unable to find valid recovery factor")}},function(t,e,r){"use strict";var i=r(61),n=r(103),o=r(13);function a(t){if(!(this instanceof a))return new a(t);this.hash=t.hash,this.predResist=!!t.predResist,this.outLen=this.hash.outSize,this.minEntropy=t.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var e=n.toArray(t.entropy,t.entropyEnc||"hex"),r=n.toArray(t.nonce,t.nonceEnc||"hex"),i=n.toArray(t.pers,t.persEnc||"hex");o(e.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(e,r,i)}t.exports=a,a.prototype._init=function(t,e,r){var i=t.concat(e).concat(r);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var n=0;n=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(t.concat(r||[])),this._reseed=1},a.prototype.generate=function(t,e,r,i){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");"string"!==typeof e&&(i=r,r=e,e=null),r&&(r=n.toArray(r,i||"hex"),this._update(r));for(var o=[];o.length"}},function(t,e,r){"use strict";var i=r(5),n=r(14),o=n.assert;function a(t,e){if(t instanceof a)return t;this._importDER(t,e)||(o(t.r&&t.s,"Signature without r or s"),this.r=new i(t.r,16),this.s=new i(t.s,16),void 0===t.recoveryParam?this.recoveryParam=null:this.recoveryParam=t.recoveryParam)}function s(){this.place=0}function u(t,e){var r=t[e.place++];if(!(128&r))return r;for(var i=15&r,n=0,o=0,a=e.place;o>>3);for(t.push(128|r);--r;)t.push(e>>>(r<<3)&255);t.push(e)}}t.exports=a,a.prototype._importDER=function(t,e){t=n.toArray(t,e);var r=new s;if(48!==t[r.place++])return!1;if(u(t,r)+r.place!==t.length)return!1;if(2!==t[r.place++])return!1;var o=u(t,r),a=t.slice(r.place,o+r.place);if(r.place+=o,2!==t[r.place++])return!1;var h=u(t,r);if(t.length!==h+r.place)return!1;var f=t.slice(r.place,h+r.place);return 0===a[0]&&128&a[1]&&(a=a.slice(1)),0===f[0]&&128&f[1]&&(f=f.slice(1)),this.r=new i(a),this.s=new i(f),this.recoveryParam=null,!0},a.prototype.toDER=function(t){var e=this.r.toArray(),r=this.s.toArray();for(128&e[0]&&(e=[0].concat(e)),128&r[0]&&(r=[0].concat(r)),e=h(e),r=h(r);!r[0]&&!(128&r[1]);)r=r.slice(1);var i=[2];f(i,e.length),(i=i.concat(e)).push(2),f(i,r.length);var o=i.concat(r),a=[48];return f(a,o.length),a=a.concat(o),n.encode(a,t)}},function(t,e,r){"use strict";var i=r(61),n=r(60),o=r(14),a=o.assert,s=o.parseBytes,u=r(246),h=r(247);function f(t){if(a("ed25519"===t,"only tested with ed25519 so far"),!(this instanceof f))return new f(t);t=n[t].curve;this.curve=t,this.g=t.g,this.g.precompute(t.n.bitLength()+1),this.pointClass=t.point().constructor,this.encodingLength=Math.ceil(t.n.bitLength()/8),this.hash=i.sha512}t.exports=f,f.prototype.sign=function(t,e){t=s(t);var r=this.keyFromSecret(e),i=this.hashInt(r.messagePrefix(),t),n=this.g.mul(i),o=this.encodePoint(n),a=this.hashInt(o,r.pubBytes(),t).mul(r.priv()),u=i.add(a).umod(this.curve.n);return this.makeSignature({R:n,S:u,Rencoded:o})},f.prototype.verify=function(t,e,r){t=s(t),e=this.makeSignature(e);var i=this.keyFromPublic(r),n=this.hashInt(e.Rencoded(),i.pubBytes(),t),o=this.g.mul(e.S());return e.R().add(i.pub().mul(n)).eq(o)},f.prototype.hashInt=function(){for(var t=this.hash(),e=0;e=e)throw new Error("invalid sig")}t.exports=function(t,r,u,h,f){var c=o(u);if("ec"===c.type){if("ecdsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong public key type");return function(t,e,r){var i=a[r.data.algorithm.curve.join(".")];if(!i)throw new Error("unknown curve "+r.data.algorithm.curve.join("."));var o=new n(i),s=r.data.subjectPrivateKey.data;return o.verify(e,t,s)}(t,r,c)}if("dsa"===c.type){if("dsa"!==h)throw new Error("wrong public key type");return function(t,e,r){var n=r.data.p,a=r.data.q,u=r.data.g,h=r.data.pub_key,f=o.signature.decode(t,"der"),c=f.s,l=f.r;s(c,a),s(l,a);var d=i.mont(n),p=c.invm(a);return 0===u.toRed(d).redPow(new i(e).mul(p).mod(a)).fromRed().mul(h.toRed(d).redPow(l.mul(p).mod(a)).fromRed()).mod(n).mod(a).cmp(l)}(t,r,c)}if("rsa"!==h&&"ecdsa/rsa"!==h)throw new Error("wrong public key type");r=e.concat([f,r]);for(var l=c.modulus.byteLength(),d=[1],p=0;r.length+d.length+2r-l-2)throw new Error("message too long");var d=c.alloc(r-i-l-2),p=r-f-1,m=n(f),g=s(c.concat([h,d,c.alloc(1,1),e],p),a(m,p)),b=s(m,a(g,f));return new u(c.concat([c.alloc(1),b,g],r))}(p,e);else if(1===l)d=function(t,e,r){var i,o=e.length,a=t.modulus.byteLength();if(o>a-11)throw new Error("message too long");i=r?c.alloc(a-o-3,255):function(t){var e,r=c.allocUnsafe(t),i=0,o=n(2*t),a=0;for(;i=0)throw new Error("data too long for modulus")}return r?f(d,p):h(d,p)}},function(t,e,r){var i=r(42),n=r(113),o=r(114),a=r(5),s=r(58),u=r(30),h=r(115),f=r(2).Buffer;t.exports=function(t,e,r){var c;c=t.padding?t.padding:r?1:4;var l,d=i(t),p=d.modulus.byteLength();if(e.length>p||new a(e).cmp(d.modulus)>=0)throw new Error("decryption error");l=r?h(new a(e),d):s(e,d);var m=f.alloc(p-l.length);if(l=f.concat([m,l],p),4===c)return function(t,e){var r=t.modulus.byteLength(),i=u("sha1").update(f.alloc(0)).digest(),a=i.length;if(0!==e[0])throw new Error("decryption error");var s=e.slice(1,a+1),h=e.slice(a+1),c=o(s,n(h,a)),l=o(h,n(c,r-a-1));if(function(t,e){t=f.from(t),e=f.from(e);var r=0,i=t.length;t.length!==e.length&&(r++,i=Math.min(t.length,e.length));var n=-1;for(;++n=e.length){o++;break}var a=e.slice(2,n-1);("0002"!==i.toString("hex")&&!r||"0001"!==i.toString("hex")&&r)&&o++;a.length<8&&o++;if(o)throw new Error("decryption error");return e.slice(n)}(0,l,r);if(3===c)return l;throw new Error("unknown padding")}},function(t,e,r){"use strict";(function(t,i){function n(){throw new Error("secure random number generation not supported by this browser\nuse chrome, FireFox or Internet Explorer 11")}var o=r(2),a=r(21),s=o.Buffer,u=o.kMaxLength,h=t.crypto||t.msCrypto,f=Math.pow(2,32)-1;function c(t,e){if("number"!==typeof t||t!==t)throw new TypeError("offset must be a number");if(t>f||t<0)throw new TypeError("offset must be a uint32");if(t>u||t>e)throw new RangeError("offset out of range")}function l(t,e,r){if("number"!==typeof t||t!==t)throw new TypeError("size must be a number");if(t>f||t<0)throw new TypeError("size must be a uint32");if(t+e>r||t>u)throw new RangeError("buffer too small")}function d(t,e,r,n){if(i.browser){var o=t.buffer,s=new Uint8Array(o,e,r);return h.getRandomValues(s),n?void i.nextTick((function(){n(null,t)})):t}if(!n)return a(r).copy(t,e),t;a(r,(function(r,i){if(r)return n(r);i.copy(t,e),n(null,t)}))}h&&h.getRandomValues||!i.browser?(e.randomFill=function(e,r,i,n){if(!s.isBuffer(e)&&!(e instanceof t.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"===typeof r)n=r,r=0,i=e.length;else if("function"===typeof i)n=i,i=e.length-r;else if("function"!==typeof n)throw new TypeError('"cb" argument must be a function');return c(r,e.length),l(i,r,e.length),d(e,r,i,n)},e.randomFillSync=function(e,r,i){"undefined"===typeof r&&(r=0);if(!s.isBuffer(e)&&!(e instanceof t.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');c(r,e.length),void 0===i&&(i=e.length-r);return l(i,r,e.length),d(e,r,i)}):(e.randomFill=n,e.randomFillSync=n)}).call(this,r(10),r(8))},function(t,e,r){var i=r(116),n=r(268);function o(t,e,r){var i=t[e]+t[r],n=t[e+1]+t[r+1];i>=4294967296&&n++,t[e]=i,t[e+1]=n}function a(t,e,r,i){var n=t[e]+r;r<0&&(n+=4294967296);var o=t[e+1]+i;n>=4294967296&&o++,t[e]=n,t[e+1]=o}function s(t,e){return t[e]^t[e+1]<<8^t[e+2]<<16^t[e+3]<<24}function u(t,e,r,i,n,s){var u=l[n],h=l[n+1],f=l[s],d=l[s+1];o(c,t,e),a(c,t,u,h);var p=c[i]^c[t],m=c[i+1]^c[t+1];c[i]=m,c[i+1]=p,o(c,r,i),p=c[e]^c[r],m=c[e+1]^c[r+1],c[e]=p>>>24^m<<8,c[e+1]=m>>>24^p<<8,o(c,t,e),a(c,t,f,d),p=c[i]^c[t],m=c[i+1]^c[t+1],c[i]=p>>>16^m<<16,c[i+1]=m>>>16^p<<16,o(c,r,i),p=c[e]^c[r],m=c[e+1]^c[r+1],c[e]=m>>>31^p<<1,c[e+1]=p>>>31^m<<1}var h=new Uint32Array([4089235720,1779033703,2227873595,3144134277,4271175723,1013904242,1595750129,2773480762,2917565137,1359893119,725511199,2600822924,4215389547,528734635,327033209,1541459225]),f=new Uint8Array([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3,11,8,12,0,5,2,15,13,10,14,3,6,7,1,9,4,7,9,3,1,13,12,11,14,2,6,5,10,4,0,15,8,9,0,5,7,2,4,10,15,14,1,11,12,6,8,3,13,2,12,6,10,0,11,8,3,4,13,7,5,15,14,1,9,12,5,1,15,14,13,4,10,0,7,6,3,9,2,8,11,13,11,7,14,12,1,3,9,5,0,15,4,8,6,2,10,6,15,14,9,11,3,0,8,12,2,13,7,1,4,10,5,10,2,8,4,7,6,1,5,15,11,9,14,3,12,13,0,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,14,10,4,8,9,15,13,6,1,12,0,2,11,7,5,3].map((function(t){return 2*t}))),c=new Uint32Array(32),l=new Uint32Array(32);function d(t,e){var r=0;for(r=0;r<16;r++)c[r]=t.h[r],c[r+16]=h[r];for(c[24]=c[24]^t.t,c[25]=c[25]^t.t/4294967296,e&&(c[28]=~c[28],c[29]=~c[29]),r=0;r<32;r++)l[r]=s(t.b,4*r);for(r=0;r<12;r++)u(0,8,16,24,f[16*r+0],f[16*r+1]),u(2,10,18,26,f[16*r+2],f[16*r+3]),u(4,12,20,28,f[16*r+4],f[16*r+5]),u(6,14,22,30,f[16*r+6],f[16*r+7]),u(0,10,20,30,f[16*r+8],f[16*r+9]),u(2,12,22,24,f[16*r+10],f[16*r+11]),u(4,14,16,26,f[16*r+12],f[16*r+13]),u(6,8,18,28,f[16*r+14],f[16*r+15]);for(r=0;r<16;r++)t.h[r]=t.h[r]^c[r]^c[r+16]}var p=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);function m(t,e,r,i){p.fill(0),this.b=new Uint8Array(128),this.h=new Uint32Array(16),this.t=0,this.c=0,this.outlen=t,p[0]=t,e&&(p[1]=e.length),p[2]=1,p[3]=1,r&&p.set(r,32),i&&p.set(i,48);for(var n=0;n<16;n++)this.h[n]=h[n]^s(p,4*n);e&&(g(this,e),this.c=128)}function g(t,e){for(var r=0;r=this.outlen,"out must have at least outlen bytes of space"),function(t,e){t.t+=t.c;for(;t.c<128;)t.b[t.c++]=0;d(t,!0);for(var r=0;r>2]>>8*(3&r)}(this,e),"hex"===t?function(t){for(var e="",r=0;r=y,"outlen must be at least "+y+", was given "+t),i(t<=w,"outlen must be at most "+w+", was given "+t),null!=e&&i(e.length>=_,"key must be at least "+_+", was given "+e.length),null!=e&&i(e.length<=M,"key must be at most "+M+", was given "+e.length),null!=r&&i(r.length===A,"salt must be exactly "+A+", was given "+r.length),null!=n&&i(n.length===I,"personal must be exactly "+I+", was given "+n.length)),new v(t,e,r,n)},t.exports.ready=function(t){n.ready((function(){t()}))},t.exports.WASM_SUPPORTED=n.SUPPORTED,t.exports.WASM_LOADED=!1;var y=t.exports.BYTES_MIN=16,w=t.exports.BYTES_MAX=64,_=(t.exports.BYTES=32,t.exports.KEYBYTES_MIN=16),M=t.exports.KEYBYTES_MAX=64,A=(t.exports.KEYBYTES=32,t.exports.SALTBYTES=16),I=t.exports.PERSONALBYTES=16;n.ready((function(e){e||(t.exports.WASM_LOADED=!0,v=n)}))},function(t,e,r){var i=r(116),n=r(269)(),o=64,a=[];t.exports=d;var s=t.exports.BYTES_MIN=16,u=t.exports.BYTES_MAX=64,h=(t.exports.BYTES=32,t.exports.KEYBYTES_MIN=16),f=t.exports.KEYBYTES_MAX=64,c=(t.exports.KEYBYTES=32,t.exports.SALTBYTES=16),l=t.exports.PERSONALBYTES=16;function d(t,e,r,p,m){if(!(this instanceof d))return new d(t,e,r,p,m);if(!n||!n.exports)throw new Error("WASM not loaded. Wait for Blake2b.ready(cb)");t||(t=32),!0!==m&&(i(t>=s,"digestLength must be at least "+s+", was given "+t),i(t<=u,"digestLength must be at most "+u+", was given "+t),null!=e&&i(e.length>=h,"key must be at least "+h+", was given "+e.length),null!=e&&i(e.length<=f,"key must be at least "+f+", was given "+e.length),null!=r&&i(r.length===c,"salt must be exactly "+c+", was given "+r.length),null!=p&&i(p.length===l,"personal must be exactly "+l+", was given "+p.length)),a.length||(a.push(o),o+=216),this.digestLength=t,this.finalized=!1,this.pointer=a.pop(),n.memory.fill(0,0,64),n.memory[0]=this.digestLength,n.memory[1]=e?e.length:0,n.memory[2]=1,n.memory[3]=1,r&&n.memory.set(r,32),p&&n.memory.set(p,48),this.pointer+216>n.memory.length&&n.realloc(this.pointer+216),n.exports.blake2b_init(this.pointer,this.digestLength),e&&(this.update(e),n.memory.fill(0,o,o+e.length),n.memory[this.pointer+200]=128)}function p(){}function m(t){return t<16?"0"+t.toString(16):t.toString(16)}d.prototype.update=function(t){return i(!1===this.finalized,"Hash instance finalized"),i(t,"input must be TypedArray or Buffer"),o+t.length>n.memory.length&&n.realloc(o+t.length),n.memory.set(t,o),n.exports.blake2b_update(this.pointer,o,o+t.length),this},d.prototype.digest=function(t){if(i(!1===this.finalized,"Hash instance finalized"),this.finalized=!0,a.push(this.pointer),n.exports.blake2b_final(this.pointer),!t||"binary"===t)return n.memory.slice(this.pointer+128,this.pointer+128+this.digestLength);if("hex"===t)return function(t,e,r){for(var i="",n=0;n=this.digestLength,"input must be TypedArray or Buffer");for(var e=0;et)throw new Error("bad digestLength");var f,c,l;this.digestLength=u;var d=0;if(a(h))d=(f=h).length;else if("object"===typeof h)!function(t){for(var e in t)switch(e){case"key":case"personalization":case"salt":if(!a(t[e]))throw new TypeError(e+" must be a Uint8Array or an Array of bytes");break;default:throw new Error("unexpected key in config: "+e)}}(h),d=(f=h.key)?f.length:0,l=h.salt,c=h.personalization;else if(h)throw new Error("unexpected key or config type");if(d>r)throw new Error("key is too long");if(l&&l.length!==n)throw new Error("salt must be "+n+" bytes");if(c&&c.length!==i)throw new Error("personalization must be "+i+" bytes");this.isFinished=!1,this.h=new Uint32Array(o);var p=new Uint8Array([255&u,d,1,1]);if(this.h[0]^=s(p,0),l&&(this.h[4]^=s(l,0),this.h[5]^=s(l,4)),c&&(this.h[6]^=s(c,0),this.h[7]^=s(c,4)),this.x=new Uint8Array(e),this.nx=0,this.t0=0,this.t1=0,this.f0=0,this.f1=0,d>0){for(var m=0;m>>0&&(this.t0=0,this.t1++);var e=this.h[0],r=this.h[1],i=this.h[2],n=this.h[3],a=this.h[4],s=this.h[5],u=this.h[6],h=this.h[7],f=o[0],c=o[1],l=o[2],d=o[3],p=o[4]^this.t0,m=o[5]^this.t1,g=o[6]^this.f0,b=o[7]^this.f1,v=this.x,y=255&v[0]|(255&v[1])<<8|(255&v[2])<<16|(255&v[3])<<24,w=255&v[4]|(255&v[5])<<8|(255&v[6])<<16|(255&v[7])<<24,_=255&v[8]|(255&v[9])<<8|(255&v[10])<<16|(255&v[11])<<24,M=255&v[12]|(255&v[13])<<8|(255&v[14])<<16|(255&v[15])<<24,A=255&v[16]|(255&v[17])<<8|(255&v[18])<<16|(255&v[19])<<24,I=255&v[20]|(255&v[21])<<8|(255&v[22])<<16|(255&v[23])<<24,S=255&v[24]|(255&v[25])<<8|(255&v[26])<<16|(255&v[27])<<24,E=255&v[28]|(255&v[29])<<8|(255&v[30])<<16|(255&v[31])<<24,k=255&v[32]|(255&v[33])<<8|(255&v[34])<<16|(255&v[35])<<24,x=255&v[36]|(255&v[37])<<8|(255&v[38])<<16|(255&v[39])<<24,B=255&v[40]|(255&v[41])<<8|(255&v[42])<<16|(255&v[43])<<24,C=255&v[44]|(255&v[45])<<8|(255&v[46])<<16|(255&v[47])<<24,T=255&v[48]|(255&v[49])<<8|(255&v[50])<<16|(255&v[51])<<24,P=255&v[52]|(255&v[53])<<8|(255&v[54])<<16|(255&v[55])<<24,R=255&v[56]|(255&v[57])<<8|(255&v[58])<<16|(255&v[59])<<24,O=255&v[60]|(255&v[61])<<8|(255&v[62])<<16|(255&v[63])<<24;a=(a^=f=f+(p=(p^=e=(e=e+y|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+_|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+A|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+S|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+I|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+E|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+M|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+w|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+k|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+B|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+T|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+R|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+P|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+O|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+C|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+x|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+R|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+A|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+x|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+P|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+O|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+S|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+k|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+B|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+w|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+y|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+C|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+I|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+E|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+M|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+_|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+T|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+C|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+T|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+I|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+O|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+_|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+P|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+y|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+k|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+B|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+M|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+E|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+x|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+w|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+A|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+S|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+R|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+E|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+M|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+P|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+C|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+T|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+R|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+w|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+x|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+_|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+I|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+A|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+O|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+y|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+k|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+B|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+S|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+x|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+I|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+_|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+B|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+A|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+O|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+E|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+y|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+R|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+C|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+S|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+M|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+k|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+P|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+T|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+w|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+_|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+S|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+y|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+k|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+C|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+M|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+B|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+T|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+A|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+E|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+O|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+w|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+R|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+x|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+I|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+P|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+T|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+w|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+R|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+A|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+P|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+B|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+O|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+I|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+y|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+S|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+x|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+k|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+_|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+C|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+M|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+E|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+P|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+E|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+T|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+M|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+w|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+x|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+R|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+C|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+I|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+O|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+k|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+_|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+S|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+B|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+A|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+y|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+S|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+R|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+C|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+y|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+M|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+k|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+x|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+O|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+T|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+P|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+w|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+B|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+A|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+I|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+E|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+_|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+B|0)+a|0)<<16|p>>>16)|0)<<20|a>>>12,s=(s^=c=c+(m=(m^=r=(r=r+k|0)+s|0)<<16|m>>>16)|0)<<20|s>>>12,u=(u^=l=l+(g=(g^=i=(i=i+E|0)+u|0)<<16|g>>>16)|0)<<20|u>>>12,h=(h^=d=d+(b=(b^=n=(n=n+w|0)+h|0)<<16|b>>>16)|0)<<20|h>>>12,u=(u^=l=l+(g=(g^=i=(i=i+S|0)+u|0)<<24|g>>>8)|0)<<25|u>>>7,h=(h^=d=d+(b=(b^=n=(n=n+I|0)+h|0)<<24|b>>>8)|0)<<25|h>>>7,s=(s^=c=c+(m=(m^=r=(r=r+A|0)+s|0)<<24|m>>>8)|0)<<25|s>>>7,a=(a^=f=f+(p=(p^=e=(e=e+_|0)+a|0)<<24|p>>>8)|0)<<25|a>>>7,s=(s^=l=l+(b=(b^=e=(e=e+O|0)+s|0)<<16|b>>>16)|0)<<20|s>>>12,u=(u^=d=d+(p=(p^=r=(r=r+x|0)+u|0)<<16|p>>>16)|0)<<20|u>>>12,h=(h^=f=f+(m=(m^=i=(i=i+M|0)+h|0)<<16|m>>>16)|0)<<20|h>>>12,a=(a^=c=c+(g=(g^=n=(n=n+P|0)+a|0)<<16|g>>>16)|0)<<20|a>>>12,h=(h^=f=f+(m=(m^=i=(i=i+T|0)+h|0)<<24|m>>>8)|0)<<25|h>>>7,a=(a^=c=c+(g=(g^=n=(n=n+y|0)+a|0)<<24|g>>>8)|0)<<25|a>>>7,u=(u^=d=d+(p=(p^=r=(r=r+R|0)+u|0)<<24|p>>>8)|0)<<25|u>>>7,s=(s^=l=l+(b=(b^=e=(e=e+C|0)+s|0)<<24|b>>>8)|0)<<25|s>>>7,this.h[0]^=e^f,this.h[1]^=r^c,this.h[2]^=i^l,this.h[3]^=n^d,this.h[4]^=a^p,this.h[5]^=s^m,this.h[6]^=u^g,this.h[7]^=h^b},u.prototype.update=function(t,e,r){if("string"===typeof t)throw new TypeError("update() accepts Uint8Array or an Array of bytes");if(this.isFinished)throw new Error("update() after calling digest()");if("undefined"===typeof e&&(e=0),"undefined"===typeof r&&(r=t.length-e),0===r)return this;var i,n=64-this.nx;if(r>n){for(i=0;i64;){for(i=0;i<64;i++)this.x[i]=t[e+i];this.processBlock(64),e+=64,r-=64,this.nx=0}for(i=0;i>>0&255,e[4*t+1]=r>>>8&255,e[4*t+2]=r>>>16&255,e[4*t+3]=r>>>24&255}return this.result=new Uint8Array(e.subarray(0,this.digestLength)),this.isFinished=!0,this.result},u.prototype.hexDigest=function(){for(var t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],e=[],r=this.digest(),i=0;i>4&15]),e.push(t[15&r[i]]);return e.join("")},u.digestLength=t,u.blockLength=e,u.keyLength=r,u.saltLength=n,u.personalizationLength=i,u}();t.exports&&(t.exports=i)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(274),n=r(119),o=r(3),a=r(44),s=r(4),u=r(37),h=r(6);e.genOutCm=function(e,r,f,c){if(e=u.newAsset(e),r=o.toBuffer(r),f=h.newFR(f),c=a.newPKr(c),s(64==r.length),e.isValid()&&c.isValid()){var l=i.genAssetCurrency(e.tkn_currency).mult(e.tkn_value);o.default.isEmptyBuffer(e.tkt_value,32)||(l=l.add(i.genAssetTkt(e.tkt_category,e.tkt_value)));var d=t.concat([l.toBuffer(),r,c.VPK.toBuffer(),c.BASE.toBuffer(),f.toBuffer()]);return s(192==d.length,"blob.length != 192,"),i.outCmBase.mult(new n.BitBuffer(d))}}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(117),n=r(118),o=r(17),a=r(3),s=r(4);e.outCmBase=new i.Group("$SROOUTCMGEN",8,192,4),e.genAssetTkt=function(e,r){e=a.toBuffer(e),r=a.toBuffer(r),s(32==e.length),s(32==r.length);var i=t.concat([e,r]),u=n.findPoint("$SROASSETTK",o.blake2b("$SROASSETTK.H",i));if(!u)throw new Error("find point error");return u},e.genAssetCurrency=function(t){t=a.toBuffer(t),s(32==t.length);var e=n.findPoint("$SROASSETCY",t);if(!e)throw new Error("find point error");return e}}).call(this,r(0).Buffer)},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(37),n=r(6),o=r(64),a=r(3),s=r(4),u=function(){function e(t,e,r){this.asset=i.newAsset(t),this.rsk=n.newFR(e),this.memo=a.toBuffer(r)}return e.prototype.isValid=function(){return!!this.asset.isValid()&&!this.rsk.isZero()},e.prototype.toBuffer=function(){return t.concat([this.asset.toBuffer(),this.rsk.toBuffer(),this.memo])},e.prototype.toString=function(){return"0x"+this.toBuffer().toString("hex")},e}();function h(e){if(e instanceof u)return e;var r=a.toBuffer(e);return s(224==r.length),new u(i.newAsset(r.slice(0,128)),new n.FR(r.slice(128,160)),t.from(r.slice(160,224)))}e.Info=u,e.newInfo=h,e.encInfo=function(t,e){t=a.toBuffer(t),e=h(e),s(32==t.length);var r=e.toBuffer();return o.default(r,t)},e.decEInfo=function(t,e,r){return s(r,"flag must true"),t=a.toBuffer(t),e=a.toBuffer(e),s(224==t.length),s(32==e.length),h(o.default(t,e))}}).call(this,r(0).Buffer)},function(t,e,r){t.exports=r(277)},function(t,e,r){(function(e){var i=r(124).pbkdf2Sync,n=2147483647;function o(t,r,i,n,o){if(e.isBuffer(t)&&e.isBuffer(i))t.copy(i,n,r,r+o);else for(;o--;)i[n++]=t[r++]}t.exports=function(t,r,a,s,u,h,f){if(0===a||0!==(a&a-1))throw Error("N must be > 0 and a power of 2");if(a>n/128/s)throw Error("Parameter N is too large");if(s>n/128/u)throw Error("Parameter r is too large");var c,l=new e(256*s),d=new e(128*s*a),p=new Int32Array(16),m=new Int32Array(16),g=new e(64),b=i(t,r,1,128*u*s,"sha256");if(f){var v=u*a*2,y=0;c=function(){++y%1e3===0&&f({current:y,total:v,percent:y/v*100})}}for(var w=0;w>>32-e}function I(t){var e;for(e=0;e<16;e++)p[e]=(255&t[4*e+0])<<0,p[e]|=(255&t[4*e+1])<<8,p[e]|=(255&t[4*e+2])<<16,p[e]|=(255&t[4*e+3])<<24;for(o(p,0,m,0,16),e=8;e>0;e-=2)m[4]^=A(m[0]+m[12],7),m[8]^=A(m[4]+m[0],9),m[12]^=A(m[8]+m[4],13),m[0]^=A(m[12]+m[8],18),m[9]^=A(m[5]+m[1],7),m[13]^=A(m[9]+m[5],9),m[1]^=A(m[13]+m[9],13),m[5]^=A(m[1]+m[13],18),m[14]^=A(m[10]+m[6],7),m[2]^=A(m[14]+m[10],9),m[6]^=A(m[2]+m[14],13),m[10]^=A(m[6]+m[2],18),m[3]^=A(m[15]+m[11],7),m[7]^=A(m[3]+m[15],9),m[11]^=A(m[7]+m[3],13),m[15]^=A(m[11]+m[7],18),m[1]^=A(m[0]+m[3],7),m[2]^=A(m[1]+m[0],9),m[3]^=A(m[2]+m[1],13),m[0]^=A(m[3]+m[2],18),m[6]^=A(m[5]+m[4],7),m[7]^=A(m[6]+m[5],9),m[4]^=A(m[7]+m[6],13),m[5]^=A(m[4]+m[7],18),m[11]^=A(m[10]+m[9],7),m[8]^=A(m[11]+m[10],9),m[9]^=A(m[8]+m[11],13),m[10]^=A(m[9]+m[8],18),m[12]^=A(m[15]+m[14],7),m[13]^=A(m[12]+m[15],9),m[14]^=A(m[13]+m[12],13),m[15]^=A(m[14]+m[13],18);for(e=0;e<16;++e)p[e]=m[e]+p[e];for(e=0;e<16;e++){var r=4*e;t[r+0]=p[e]>>0&255,t[r+1]=p[e]>>8&255,t[r+2]=p[e]>>16&255,t[r+3]=p[e]>>24&255}}function S(t,e,r,i,n){for(var o=0;o0?this.tail.next=e:this.head=e,this.tail=e,++this.length}},{key:"unshift",value:function(t){var e={data:t,next:this.head};0===this.length&&(this.tail=e),this.head=e,++this.length}},{key:"shift",value:function(){if(0!==this.length){var t=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,t}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(t){if(0===this.length)return"";for(var e=this.head,r=""+e.data;e=e.next;)r+=t+e.data;return r}},{key:"concat",value:function(t){if(0===this.length)return a.alloc(0);for(var e,r,i,n=a.allocUnsafe(t>>>0),o=this.head,s=0;o;)e=o.data,r=n,i=s,a.prototype.copy.call(e,r,i),s+=o.data.length,o=o.next;return n}},{key:"consume",value:function(t,e){var r;return tn.length?n.length:t;if(o===n.length?i+=n:i+=n.slice(0,t),0===(t-=o)){o===n.length?(++r,e.next?this.head=e.next:this.head=this.tail=null):(this.head=e,e.data=n.slice(o));break}++r}return this.length-=r,i}},{key:"_getBuffer",value:function(t){var e=a.allocUnsafe(t),r=this.head,i=1;for(r.data.copy(e),t-=r.data.length;r=r.next;){var n=r.data,o=t>n.length?n.length:t;if(n.copy(e,e.length-t,0,o),0===(t-=o)){o===n.length?(++i,r.next?this.head=r.next:this.head=this.tail=null):(this.head=r,r.data=n.slice(o));break}++i}return this.length-=i,e}},{key:u,value:function(t,e){return s(this,function(t){for(var e=1;e0,(function(t){f||(f=t),t&&l.forEach(u),o||(l.forEach(u),c(f))}))}));return e.reduce(h)}},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<30|t>>>2}function f(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,c=0;c<16;++c)r[c]=t.readInt32BE(4*c);for(;c<80;++c)r[c]=r[c-3]^r[c-8]^r[c-14]^r[c-16];for(var l=0;l<80;++l){var d=~~(l/20),p=0|((e=i)<<5|e>>>27)+f(d,n,o,s)+u+r[l]+a[d];u=s,s=o,o=h(n),n=i,i=p}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(9),n=r(28),o=r(7).Buffer,a=[1518500249,1859775393,-1894007588,-899497514],s=new Array(80);function u(){this.init(),this._w=s,n.call(this,64,56)}function h(t){return t<<5|t>>>27}function f(t){return t<<30|t>>>2}function c(t,e,r,i){return 0===t?e&r|~e&i:2===t?e&r|e&i|r&i:e^r^i}i(u,n),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var e,r=this._w,i=0|this._a,n=0|this._b,o=0|this._c,s=0|this._d,u=0|this._e,l=0;l<16;++l)r[l]=t.readInt32BE(4*l);for(;l<80;++l)r[l]=(e=r[l-3]^r[l-8]^r[l-14]^r[l-16])<<1|e>>>31;for(var d=0;d<80;++d){var p=~~(d/20),m=h(i)+c(p,n,o,s)+u+r[d]+a[p]|0;u=s,s=o,o=f(n),n=i,i=m}this._a=i+this._a|0,this._b=n+this._b|0,this._c=o+this._c|0,this._d=s+this._d|0,this._e=u+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,e,r){var i=r(9),n=r(138),o=r(28),a=r(7).Buffer,s=new Array(64);function u(){this.init(),this._w=s,o.call(this,64,56)}i(u,n),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 t=a.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t},t.exports=u},function(t,e,r){var i=r(9),n=r(139),o=r(28),a=r(7).Buffer,s=new Array(160);function u(){this.init(),this._w=s,o.call(this,128,112)}i(u,n),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 t=a.allocUnsafe(48);function e(e,r,i){t.writeInt32BE(e,i),t.writeInt32BE(r,i+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),t},t.exports=u},function(t,e,r){var i=r(294),n=r(295);t.exports=function(t,e,r){var o=e&&r||0;"string"==typeof t&&(e="binary"===t?new Array(16):null,t=null);var a=(t=t||{}).random||(t.rng||i)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,e)for(var s=0;s<16;++s)e[o+s]=a[s];return e||n(a)}},function(t,e){var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(r){var i=new Uint8Array(16);t.exports=function(){return r(i),i}}else{var n=new Array(16);t.exports=function(){for(var t,e=0;e<16;e++)0===(3&e)&&(t=4294967296*Math.random()),n[e]=t>>>((3&e)<<3)&255;return n}}},function(t,e){for(var r=[],i=0;i<256;++i)r[i]=(i+256).toString(16).substr(1);t.exports=function(t,e){var i=e||0,n=r;return[n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],"-",n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]],n[t[i++]]].join("")}},function(t,e,r){"use strict";(function(t){var i=r(297);Object.defineProperty(e,"__esModule",{value:!0});var n=r(301),o=r(124),a=r(43),s=r(141),u=s._default,h="Invalid mnemonic",f="Invalid entropy",c="Invalid mnemonic checksum",l="A wordlist is required but a default could not be found.\nPlease explicitly pass a 2048 word array explicitly.";function d(t,e,r){for(;t.length32)throw new Error(f);if(m.length%4!==0)throw new Error(f);var b=t.from(m);if(g(b)!==s)throw new Error(c);return b.toString("hex")}function y(e,r){if(t.isBuffer(e)||(e=t.from(e,"hex")),!(r=r||u))throw new Error(l);if(e.length<16)throw new TypeError(f);if(e.length>32)throw new TypeError(f);if(e.length%4!==0)throw new TypeError(f);var n=(m(i(e))+g(e)).match(/(.{1,11})/g).map((function(t){var e=p(t);return r[e]}));return"\u3042\u3044\u3053\u304f\u3057\u3093"===r[0]?n.join("\u3000"):n.join(" ")}e.mnemonicToSeedSync=function(e,r){var i=t.from((e||"").normalize("NFKD"),"utf8"),n=t.from(b((r||"").normalize("NFKD")),"utf8");return o.pbkdf2Sync(i,n,2048,64,"sha512")},e.mnemonicToSeed=function(e,r){return new Promise((function(i,n){try{var a=t.from((e||"").normalize("NFKD"),"utf8"),s=t.from(b((r||"").normalize("NFKD")),"utf8");o.pbkdf2(a,s,2048,64,"sha512",(function(t,e){return t?n(t):i(e)}))}catch(u){return n(u)}}))},e.mnemonicToEntropy=v,e.entropyToMnemonic=y,e.generateMnemonic=function(t,e,r){if((t=t||128)%32!==0)throw new TypeError(f);return y((e=e||a)(t/8),r)},e.validateMnemonic=function(t,e){try{v(t,e)}catch(r){return!1}return!0},e.setDefaultWordlist=function(t){var e=s.wordlists[t];if(!e)throw new Error('Could not find wordlist for language "'+t+'"');u=e},e.getDefaultWordlist=function(){if(!u)throw new Error("No Default Wordlist set");return Object.keys(s.wordlists).filter((function(t){return"JA"!==t&&"EN"!==t&&s.wordlists[t].every((function(t,e){return t===u[e]}))}))[0]};var w=r(141);e.wordlists=w.wordlists}).call(this,r(0).Buffer)},function(t,e,r){var i=r(298),n=r(299),o=r(300);t.exports=function(t){return i(t)||n(t)||o()}},function(t,e){t.exports=function(t){if(Array.isArray(t)){for(var e=0,r=new Array(t.length);e>>this.count%4*8&255,this.count+=1,this.count===this.blockSize&&(n.p1600(this.state),this.count=0);return e},o.prototype.copy=function(t){for(var e=0;e<50;++e)t.state[e]=this.state[e];t.blockSize=this.blockSize,t.count=this.count,t.squeezing=this.squeezing},t.exports=o},function(t,e,r){"use strict";var i=[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];e.p1600=function(t){for(var e=0;e<24;++e){var r=t[0]^t[10]^t[20]^t[30]^t[40],n=t[1]^t[11]^t[21]^t[31]^t[41],o=t[2]^t[12]^t[22]^t[32]^t[42],a=t[3]^t[13]^t[23]^t[33]^t[43],s=t[4]^t[14]^t[24]^t[34]^t[44],u=t[5]^t[15]^t[25]^t[35]^t[45],h=t[6]^t[16]^t[26]^t[36]^t[46],f=t[7]^t[17]^t[27]^t[37]^t[47],c=t[8]^t[18]^t[28]^t[38]^t[48],l=t[9]^t[19]^t[29]^t[39]^t[49],d=c^(o<<1|a>>>31),p=l^(a<<1|o>>>31),m=t[0]^d,g=t[1]^p,b=t[10]^d,v=t[11]^p,y=t[20]^d,w=t[21]^p,_=t[30]^d,M=t[31]^p,A=t[40]^d,I=t[41]^p;d=r^(s<<1|u>>>31),p=n^(u<<1|s>>>31);var S=t[2]^d,E=t[3]^p,k=t[12]^d,x=t[13]^p,B=t[22]^d,C=t[23]^p,T=t[32]^d,P=t[33]^p,R=t[42]^d,O=t[43]^p;d=o^(h<<1|f>>>31),p=a^(f<<1|h>>>31);var j=t[4]^d,D=t[5]^p,N=t[14]^d,z=t[15]^p,K=t[24]^d,q=t[25]^p,U=t[34]^d,F=t[35]^p,L=t[44]^d,Q=t[45]^p;d=s^(c<<1|l>>>31),p=u^(l<<1|c>>>31);var H=t[6]^d,V=t[7]^p,Z=t[16]^d,G=t[17]^p,Y=t[26]^d,W=t[27]^p,J=t[36]^d,X=t[37]^p,$=t[46]^d,tt=t[47]^p;d=h^(r<<1|n>>>31),p=f^(n<<1|r>>>31);var et=t[8]^d,rt=t[9]^p,it=t[18]^d,nt=t[19]^p,ot=t[28]^d,at=t[29]^p,st=t[38]^d,ut=t[39]^p,ht=t[48]^d,ft=t[49]^p,ct=m,lt=g,dt=v<<4|b>>>28,pt=b<<4|v>>>28,mt=y<<3|w>>>29,gt=w<<3|y>>>29,bt=M<<9|_>>>23,vt=_<<9|M>>>23,yt=A<<18|I>>>14,wt=I<<18|A>>>14,_t=S<<1|E>>>31,Mt=E<<1|S>>>31,At=x<<12|k>>>20,It=k<<12|x>>>20,St=B<<10|C>>>22,Et=C<<10|B>>>22,kt=P<<13|T>>>19,xt=T<<13|P>>>19,Bt=R<<2|O>>>30,Ct=O<<2|R>>>30,Tt=D<<30|j>>>2,Pt=j<<30|D>>>2,Rt=N<<6|z>>>26,Ot=z<<6|N>>>26,jt=q<<11|K>>>21,Dt=K<<11|q>>>21,Nt=U<<15|F>>>17,zt=F<<15|U>>>17,Kt=Q<<29|L>>>3,qt=L<<29|Q>>>3,Ut=H<<28|V>>>4,Ft=V<<28|H>>>4,Lt=G<<23|Z>>>9,Qt=Z<<23|G>>>9,Ht=Y<<25|W>>>7,Vt=W<<25|Y>>>7,Zt=J<<21|X>>>11,Gt=X<<21|J>>>11,Yt=tt<<24|$>>>8,Wt=$<<24|tt>>>8,Jt=et<<27|rt>>>5,Xt=rt<<27|et>>>5,$t=it<<20|nt>>>12,te=nt<<20|it>>>12,ee=at<<7|ot>>>25,re=ot<<7|at>>>25,ie=st<<8|ut>>>24,ne=ut<<8|st>>>24,oe=ht<<14|ft>>>18,ae=ft<<14|ht>>>18;t[0]=ct^~At&jt,t[1]=lt^~It&Dt,t[10]=Ut^~$t&mt,t[11]=Ft^~te>,t[20]=_t^~Rt&Ht,t[21]=Mt^~Ot&Vt,t[30]=Jt^~dt&St,t[31]=Xt^~pt&Et,t[40]=Tt^~Lt&ee,t[41]=Pt^~Qt&re,t[2]=At^~jt&Zt,t[3]=It^~Dt&Gt,t[12]=$t^~mt&kt,t[13]=te^~gt&xt,t[22]=Rt^~Ht&ie,t[23]=Ot^~Vt&ne,t[32]=dt^~St&Nt,t[33]=pt^~Et&zt,t[42]=Lt^~ee&bt,t[43]=Qt^~re&vt,t[4]=jt^~Zt&oe,t[5]=Dt^~Gt&ae,t[14]=mt^~kt&Kt,t[15]=gt^~xt&qt,t[24]=Ht^~ie&yt,t[25]=Vt^~ne&wt,t[34]=St^~Nt&Yt,t[35]=Et^~zt&Wt,t[44]=ee^~bt&Bt,t[45]=re^~vt&Ct,t[6]=Zt^~oe&ct,t[7]=Gt^~ae<,t[16]=kt^~Kt&Ut,t[17]=xt^~qt&Ft,t[26]=ie^~yt&_t,t[27]=ne^~wt&Mt,t[36]=Nt^~Yt&Jt,t[37]=zt^~Wt&Xt,t[46]=bt^~Bt&Tt,t[47]=vt^~Ct&Pt,t[8]=oe^~ct&At,t[9]=ae^~lt&It,t[18]=Kt^~Ut&$t,t[19]=qt^~Ft&te,t[28]=yt^~_t&Rt,t[29]=wt^~Mt&Ot,t[38]=Yt^~Jt&dt,t[39]=Wt^~Xt&pt,t[48]=Bt^~Tt&Lt,t[49]=Ct^~Pt&Qt,t[0]^=i[2*e],t[1]^=i[2*e+1]}}},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(318).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){},function(t,e,r){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i=r(46),n=r(25),o=r(65),a=r(3),s=r(3),u=r(320),h=r(37),f=r(81),c=r(122),l=r(6),d=r(19),p=r(45),m=r(142),g=r(321),b=function(){this.hash=t.alloc(32),this.param=new u.Params},v=function(e){this.p0_ins=new Array,this.p_ins=new Array,this.c_ins=new Array,this.c_outs=new Array,this.p_outs=new Array,this.keys=new Array,this.balance_desc=new b,this.s={Desc_O:{},Desc_Z:{},Desc_Pkg:{},Desc_Cmd:{},Tx1:{Ins_P:new Array,Ins_P0:new Array,Ins_C:new Array,Outs_C:new Array,Outs_P:new Array},Bcr:a.toHex(t.alloc(32,0)),Bsign:a.toHex(t.alloc(64,0))},this.param=e};function y(e){var r=t.alloc(32,0),i=t.alloc(32,0),n=t.alloc(32,0),o=t.alloc(32,0);return e.Tkn&&(e.Tkn.Currency&&(r=e.Tkn.Currency),e.Tkn.Value&&(i=a.default.toBN(e.Tkn.Value).toArrayLike(t,"le",32))),e.Tkt&&(e.Tkt.Category&&(n=e.Tkt.Category),e.Tkt.Value&&(o=e.Tkt.Value)),new h.Asset(r,i,n,o)}function w(e){var r=[s.toBuffer(e.Ehash),s.toBuffer(e.From),M(e.Fee)];return r.push(function(e){var r=new Array;return e.Ins&&e.Ins.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Anchor),s.toBuffer(e.Nil),s.toBuffer(e.Trace),s.toBuffer(e.AssetCM),s.toBuffer(m(e.Proof))]))}(e))})),e.Outs&&e.Outs.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.AssetCM),s.toBuffer(e.OutCM),s.toBuffer(e.EInfo),s.toBuffer(e.PKr),s.toBuffer(m(e.Proof))]))}(e))})),m(t.concat(r))}(e.Desc_Z)),r.push(function(e){var r=new Array;return e.Ins&&e.Ins.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Root),s.toBuffer(e.Nil),s.toBuffer(e.Sign)]))}(e))})),e.Outs&&e.Outs.forEach((function(e){r.push(function(e){return m(t.concat([s.toBuffer(e.Addr),A(e.Asset),s.toBuffer(e.Memo)]))}(e))})),m(t.concat(r))}(e.Desc_O)),0r.length)throw new Error("invalid rlp: total length is larger than the data");if(0===(s=r.slice(o,c)).length)throw new Error("invalid rlp, List has a invalid length");for(;s.length;)u=e(s),h.push(u.data),s=u.remainder;return{data:h,remainder:r.slice(c)}}(u(e));if(r)return i;if(0!==i.remainder.length)throw new Error("invalid remainder");return i.data},e.getLength=function(e){if(!e||0===e.length)return t.from([]);var r=u(e),i=r[0];if(i<=127)return r.length;if(i<=183)return i-127;if(i<=191)return i-182;if(i<=247)return i-191;var o=i-246;return o+n(r.slice(1,o).toString("hex"),16)}}).call(this,r(0).Buffer)},function(t,e,r){(function(t){!function(t,e){"use strict";function i(t,e){if(!t)throw new Error(e||"Assertion failed")}function n(t,e){t.super_=e;var r=function(){};r.prototype=e.prototype,t.prototype=new r,t.prototype.constructor=t}function o(t,e,r){if(o.isBN(t))return t;this.negative=0,this.words=null,this.length=0,this.red=null,null!==t&&("le"!==e&&"be"!==e||(r=e,e=10),this._init(t||0,e||10,r||"be"))}var a;"object"===typeof t?t.exports=o:e.BN=o,o.BN=o,o.wordSize=26;try{a=r(323).Buffer}catch(I){}function s(t,e,r){for(var i=0,n=Math.min(t.length,r),o=e;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return i}function u(t,e,r,i){for(var n=0,o=Math.min(t.length,r),a=e;a=49?s-49+10:s>=17?s-17+10:s}return n}o.isBN=function(t){return t instanceof o||null!==t&&"object"===typeof t&&t.constructor.wordSize===o.wordSize&&Array.isArray(t.words)},o.max=function(t,e){return t.cmp(e)>0?t:e},o.min=function(t,e){return t.cmp(e)<0?t:e},o.prototype._init=function(t,e,r){if("number"===typeof t)return this._initNumber(t,e,r);if("object"===typeof t)return this._initArray(t,e,r);"hex"===e&&(e=16),i(e===(0|e)&&e>=2&&e<=36);var n=0;"-"===(t=t.toString().replace(/\s+/g,""))[0]&&n++,16===e?this._parseHex(t,n):this._parseBase(t,e,n),"-"===t[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initNumber=function(t,e,r){t<0&&(this.negative=1,t=-t),t<67108864?(this.words=[67108863&t],this.length=1):t<4503599627370496?(this.words=[67108863&t,t/67108864&67108863],this.length=2):(i(t<9007199254740992),this.words=[67108863&t,t/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),e,r)},o.prototype._initArray=function(t,e,r){if(i("number"===typeof t.length),t.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(t.length/3),this.words=new Array(this.length);for(var n=0;n=0;n-=3)a=t[n]|t[n-1]<<8|t[n-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(n=0,o=0;n>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(t,e){this.length=Math.ceil((t.length-e)/6),this.words=new Array(this.length);for(var r=0;r=e;r-=6)n=s(t,r,r+6),this.words[i]|=n<>>26-o&4194303,(o+=24)>=26&&(o-=26,i++);r+6!==e&&(n=s(t,e,r+6),this.words[i]|=n<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(t,e,r){this.words=[0],this.length=1;for(var i=0,n=1;n<=67108863;n*=e)i++;i--,n=n/e|0;for(var o=t.length-r,a=o%i,s=Math.min(o,o-a)+r,h=0,f=r;f1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var h=["","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"],f=[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],c=[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 l(t,e,r){r.negative=e.negative^t.negative;var i=t.length+e.length|0;r.length=i,i=i-1|0;var n=0|t.words[0],o=0|e.words[0],a=n*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var h=1;h>>26,c=67108863&u,l=Math.min(h,e.length-1),d=Math.max(0,h-t.length+1);d<=l;d++){var p=h-d|0;f+=(a=(n=0|t.words[p])*(o=0|e.words[d])+c)/67108864|0,c=67108863&a}r.words[h]=0|c,u=0|f}return 0!==u?r.words[h]=0|u:r.length--,r.strip()}o.prototype.toString=function(t,e){var r;if(e=0|e||1,16===(t=t||10)||"hex"===t){r="";for(var n=0,o=0,a=0;a>>24-n&16777215)||a!==this.length-1?h[6-u.length]+u+r:u+r,(n+=2)>=26&&(n-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(t===(0|t)&&t>=2&&t<=36){var l=f[t],d=c[t];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(t);r=(p=p.idivn(d)).isZero()?m+r:h[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%e!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}i(!1,"Base should be between 2 and 36")},o.prototype.toNumber=function(){var t=this.words[0];return 2===this.length?t+=67108864*this.words[1]:3===this.length&&1===this.words[2]?t+=4503599627370496+67108864*this.words[1]:this.length>2&&i(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-t:t},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(t,e){return i("undefined"!==typeof a),this.toArrayLike(a,t,e)},o.prototype.toArray=function(t,e){return this.toArrayLike(Array,t,e)},o.prototype.toArrayLike=function(t,e,r){var n=this.byteLength(),o=r||Math.max(1,n);i(n<=o,"byte array longer than desired length"),i(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===e,h=new t(o),f=this.clone();if(u){for(s=0;!f.isZero();s++)a=f.andln(255),f.iushrn(8),h[s]=a;for(;s=4096&&(r+=13,e>>>=13),e>=64&&(r+=7,e>>>=7),e>=8&&(r+=4,e>>>=4),e>=2&&(r+=2,e>>>=2),r+e},o.prototype._zeroBits=function(t){if(0===t)return 26;var e=t,r=0;return 0===(8191&e)&&(r+=13,e>>>=13),0===(127&e)&&(r+=7,e>>>=7),0===(15&e)&&(r+=4,e>>>=4),0===(3&e)&&(r+=2,e>>>=2),0===(1&e)&&r++,r},o.prototype.bitLength=function(){var t=this.words[this.length-1],e=this._countBits(t);return 26*(this.length-1)+e},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var t=0,e=0;et.length?this.clone().ior(t):t.clone().ior(this)},o.prototype.uor=function(t){return this.length>t.length?this.clone().iuor(t):t.clone().iuor(this)},o.prototype.iuand=function(t){var e;e=this.length>t.length?t:this;for(var r=0;rt.length?this.clone().iand(t):t.clone().iand(this)},o.prototype.uand=function(t){return this.length>t.length?this.clone().iuand(t):t.clone().iuand(this)},o.prototype.iuxor=function(t){var e,r;this.length>t.length?(e=this,r=t):(e=t,r=this);for(var i=0;it.length?this.clone().ixor(t):t.clone().ixor(this)},o.prototype.uxor=function(t){return this.length>t.length?this.clone().iuxor(t):t.clone().iuxor(this)},o.prototype.inotn=function(t){i("number"===typeof t&&t>=0);var e=0|Math.ceil(t/26),r=t%26;this._expand(e),r>0&&e--;for(var n=0;n0&&(this.words[n]=~this.words[n]&67108863>>26-r),this.strip()},o.prototype.notn=function(t){return this.clone().inotn(t)},o.prototype.setn=function(t,e){i("number"===typeof t&&t>=0);var r=t/26|0,n=t%26;return this._expand(r+1),this.words[r]=e?this.words[r]|1<t.length?(r=this,i=t):(r=t,i=this);for(var n=0,o=0;o>>26;for(;0!==n&&o>>26;if(this.length=r.length,0!==n)this.words[this.length]=n,this.length++;else if(r!==this)for(;ot.length?this.clone().iadd(t):t.clone().iadd(this)},o.prototype.isub=function(t){if(0!==t.negative){t.negative=0;var e=this.iadd(t);return t.negative=1,e._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(t),this.negative=1,this._normSign();var r,i,n=this.cmp(t);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(r=this,i=t):(r=t,i=this);for(var o=0,a=0;a>26,this.words[a]=67108863&e;for(;0!==o&&a>26,this.words[a]=67108863&e;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,g=0|a[2],b=8191&g,v=g>>>13,y=0|a[3],w=8191&y,_=y>>>13,M=0|a[4],A=8191&M,I=M>>>13,S=0|a[5],E=8191&S,k=S>>>13,x=0|a[6],B=8191&x,C=x>>>13,T=0|a[7],P=8191&T,R=T>>>13,O=0|a[8],j=8191&O,D=O>>>13,N=0|a[9],z=8191&N,K=N>>>13,q=0|s[0],U=8191&q,F=q>>>13,L=0|s[1],Q=8191&L,H=L>>>13,V=0|s[2],Z=8191&V,G=V>>>13,Y=0|s[3],W=8191&Y,J=Y>>>13,X=0|s[4],$=8191&X,tt=X>>>13,et=0|s[5],rt=8191&et,it=et>>>13,nt=0|s[6],ot=8191&nt,at=nt>>>13,st=0|s[7],ut=8191&st,ht=st>>>13,ft=0|s[8],ct=8191&ft,lt=ft>>>13,dt=0|s[9],pt=8191&dt,mt=dt>>>13;r.negative=t.negative^e.negative,r.length=19;var gt=(h+(i=Math.imul(c,U))|0)+((8191&(n=(n=Math.imul(c,F))+Math.imul(l,U)|0))<<13)|0;h=((o=Math.imul(l,F))+(n>>>13)|0)+(gt>>>26)|0,gt&=67108863,i=Math.imul(p,U),n=(n=Math.imul(p,F))+Math.imul(m,U)|0,o=Math.imul(m,F);var bt=(h+(i=i+Math.imul(c,Q)|0)|0)+((8191&(n=(n=n+Math.imul(c,H)|0)+Math.imul(l,Q)|0))<<13)|0;h=((o=o+Math.imul(l,H)|0)+(n>>>13)|0)+(bt>>>26)|0,bt&=67108863,i=Math.imul(b,U),n=(n=Math.imul(b,F))+Math.imul(v,U)|0,o=Math.imul(v,F),i=i+Math.imul(p,Q)|0,n=(n=n+Math.imul(p,H)|0)+Math.imul(m,Q)|0,o=o+Math.imul(m,H)|0;var vt=(h+(i=i+Math.imul(c,Z)|0)|0)+((8191&(n=(n=n+Math.imul(c,G)|0)+Math.imul(l,Z)|0))<<13)|0;h=((o=o+Math.imul(l,G)|0)+(n>>>13)|0)+(vt>>>26)|0,vt&=67108863,i=Math.imul(w,U),n=(n=Math.imul(w,F))+Math.imul(_,U)|0,o=Math.imul(_,F),i=i+Math.imul(b,Q)|0,n=(n=n+Math.imul(b,H)|0)+Math.imul(v,Q)|0,o=o+Math.imul(v,H)|0,i=i+Math.imul(p,Z)|0,n=(n=n+Math.imul(p,G)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,G)|0;var yt=(h+(i=i+Math.imul(c,W)|0)|0)+((8191&(n=(n=n+Math.imul(c,J)|0)+Math.imul(l,W)|0))<<13)|0;h=((o=o+Math.imul(l,J)|0)+(n>>>13)|0)+(yt>>>26)|0,yt&=67108863,i=Math.imul(A,U),n=(n=Math.imul(A,F))+Math.imul(I,U)|0,o=Math.imul(I,F),i=i+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,H)|0)+Math.imul(_,Q)|0,o=o+Math.imul(_,H)|0,i=i+Math.imul(b,Z)|0,n=(n=n+Math.imul(b,G)|0)+Math.imul(v,Z)|0,o=o+Math.imul(v,G)|0,i=i+Math.imul(p,W)|0,n=(n=n+Math.imul(p,J)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,J)|0;var wt=(h+(i=i+Math.imul(c,$)|0)|0)+((8191&(n=(n=n+Math.imul(c,tt)|0)+Math.imul(l,$)|0))<<13)|0;h=((o=o+Math.imul(l,tt)|0)+(n>>>13)|0)+(wt>>>26)|0,wt&=67108863,i=Math.imul(E,U),n=(n=Math.imul(E,F))+Math.imul(k,U)|0,o=Math.imul(k,F),i=i+Math.imul(A,Q)|0,n=(n=n+Math.imul(A,H)|0)+Math.imul(I,Q)|0,o=o+Math.imul(I,H)|0,i=i+Math.imul(w,Z)|0,n=(n=n+Math.imul(w,G)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,G)|0,i=i+Math.imul(b,W)|0,n=(n=n+Math.imul(b,J)|0)+Math.imul(v,W)|0,o=o+Math.imul(v,J)|0,i=i+Math.imul(p,$)|0,n=(n=n+Math.imul(p,tt)|0)+Math.imul(m,$)|0,o=o+Math.imul(m,tt)|0;var _t=(h+(i=i+Math.imul(c,rt)|0)|0)+((8191&(n=(n=n+Math.imul(c,it)|0)+Math.imul(l,rt)|0))<<13)|0;h=((o=o+Math.imul(l,it)|0)+(n>>>13)|0)+(_t>>>26)|0,_t&=67108863,i=Math.imul(B,U),n=(n=Math.imul(B,F))+Math.imul(C,U)|0,o=Math.imul(C,F),i=i+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,H)|0)+Math.imul(k,Q)|0,o=o+Math.imul(k,H)|0,i=i+Math.imul(A,Z)|0,n=(n=n+Math.imul(A,G)|0)+Math.imul(I,Z)|0,o=o+Math.imul(I,G)|0,i=i+Math.imul(w,W)|0,n=(n=n+Math.imul(w,J)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,J)|0,i=i+Math.imul(b,$)|0,n=(n=n+Math.imul(b,tt)|0)+Math.imul(v,$)|0,o=o+Math.imul(v,tt)|0,i=i+Math.imul(p,rt)|0,n=(n=n+Math.imul(p,it)|0)+Math.imul(m,rt)|0,o=o+Math.imul(m,it)|0;var Mt=(h+(i=i+Math.imul(c,ot)|0)|0)+((8191&(n=(n=n+Math.imul(c,at)|0)+Math.imul(l,ot)|0))<<13)|0;h=((o=o+Math.imul(l,at)|0)+(n>>>13)|0)+(Mt>>>26)|0,Mt&=67108863,i=Math.imul(P,U),n=(n=Math.imul(P,F))+Math.imul(R,U)|0,o=Math.imul(R,F),i=i+Math.imul(B,Q)|0,n=(n=n+Math.imul(B,H)|0)+Math.imul(C,Q)|0,o=o+Math.imul(C,H)|0,i=i+Math.imul(E,Z)|0,n=(n=n+Math.imul(E,G)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,G)|0,i=i+Math.imul(A,W)|0,n=(n=n+Math.imul(A,J)|0)+Math.imul(I,W)|0,o=o+Math.imul(I,J)|0,i=i+Math.imul(w,$)|0,n=(n=n+Math.imul(w,tt)|0)+Math.imul(_,$)|0,o=o+Math.imul(_,tt)|0,i=i+Math.imul(b,rt)|0,n=(n=n+Math.imul(b,it)|0)+Math.imul(v,rt)|0,o=o+Math.imul(v,it)|0,i=i+Math.imul(p,ot)|0,n=(n=n+Math.imul(p,at)|0)+Math.imul(m,ot)|0,o=o+Math.imul(m,at)|0;var At=(h+(i=i+Math.imul(c,ut)|0)|0)+((8191&(n=(n=n+Math.imul(c,ht)|0)+Math.imul(l,ut)|0))<<13)|0;h=((o=o+Math.imul(l,ht)|0)+(n>>>13)|0)+(At>>>26)|0,At&=67108863,i=Math.imul(j,U),n=(n=Math.imul(j,F))+Math.imul(D,U)|0,o=Math.imul(D,F),i=i+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,H)|0)+Math.imul(R,Q)|0,o=o+Math.imul(R,H)|0,i=i+Math.imul(B,Z)|0,n=(n=n+Math.imul(B,G)|0)+Math.imul(C,Z)|0,o=o+Math.imul(C,G)|0,i=i+Math.imul(E,W)|0,n=(n=n+Math.imul(E,J)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,J)|0,i=i+Math.imul(A,$)|0,n=(n=n+Math.imul(A,tt)|0)+Math.imul(I,$)|0,o=o+Math.imul(I,tt)|0,i=i+Math.imul(w,rt)|0,n=(n=n+Math.imul(w,it)|0)+Math.imul(_,rt)|0,o=o+Math.imul(_,it)|0,i=i+Math.imul(b,ot)|0,n=(n=n+Math.imul(b,at)|0)+Math.imul(v,ot)|0,o=o+Math.imul(v,at)|0,i=i+Math.imul(p,ut)|0,n=(n=n+Math.imul(p,ht)|0)+Math.imul(m,ut)|0,o=o+Math.imul(m,ht)|0;var It=(h+(i=i+Math.imul(c,ct)|0)|0)+((8191&(n=(n=n+Math.imul(c,lt)|0)+Math.imul(l,ct)|0))<<13)|0;h=((o=o+Math.imul(l,lt)|0)+(n>>>13)|0)+(It>>>26)|0,It&=67108863,i=Math.imul(z,U),n=(n=Math.imul(z,F))+Math.imul(K,U)|0,o=Math.imul(K,F),i=i+Math.imul(j,Q)|0,n=(n=n+Math.imul(j,H)|0)+Math.imul(D,Q)|0,o=o+Math.imul(D,H)|0,i=i+Math.imul(P,Z)|0,n=(n=n+Math.imul(P,G)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,G)|0,i=i+Math.imul(B,W)|0,n=(n=n+Math.imul(B,J)|0)+Math.imul(C,W)|0,o=o+Math.imul(C,J)|0,i=i+Math.imul(E,$)|0,n=(n=n+Math.imul(E,tt)|0)+Math.imul(k,$)|0,o=o+Math.imul(k,tt)|0,i=i+Math.imul(A,rt)|0,n=(n=n+Math.imul(A,it)|0)+Math.imul(I,rt)|0,o=o+Math.imul(I,it)|0,i=i+Math.imul(w,ot)|0,n=(n=n+Math.imul(w,at)|0)+Math.imul(_,ot)|0,o=o+Math.imul(_,at)|0,i=i+Math.imul(b,ut)|0,n=(n=n+Math.imul(b,ht)|0)+Math.imul(v,ut)|0,o=o+Math.imul(v,ht)|0,i=i+Math.imul(p,ct)|0,n=(n=n+Math.imul(p,lt)|0)+Math.imul(m,ct)|0,o=o+Math.imul(m,lt)|0;var St=(h+(i=i+Math.imul(c,pt)|0)|0)+((8191&(n=(n=n+Math.imul(c,mt)|0)+Math.imul(l,pt)|0))<<13)|0;h=((o=o+Math.imul(l,mt)|0)+(n>>>13)|0)+(St>>>26)|0,St&=67108863,i=Math.imul(z,Q),n=(n=Math.imul(z,H))+Math.imul(K,Q)|0,o=Math.imul(K,H),i=i+Math.imul(j,Z)|0,n=(n=n+Math.imul(j,G)|0)+Math.imul(D,Z)|0,o=o+Math.imul(D,G)|0,i=i+Math.imul(P,W)|0,n=(n=n+Math.imul(P,J)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,J)|0,i=i+Math.imul(B,$)|0,n=(n=n+Math.imul(B,tt)|0)+Math.imul(C,$)|0,o=o+Math.imul(C,tt)|0,i=i+Math.imul(E,rt)|0,n=(n=n+Math.imul(E,it)|0)+Math.imul(k,rt)|0,o=o+Math.imul(k,it)|0,i=i+Math.imul(A,ot)|0,n=(n=n+Math.imul(A,at)|0)+Math.imul(I,ot)|0,o=o+Math.imul(I,at)|0,i=i+Math.imul(w,ut)|0,n=(n=n+Math.imul(w,ht)|0)+Math.imul(_,ut)|0,o=o+Math.imul(_,ht)|0,i=i+Math.imul(b,ct)|0,n=(n=n+Math.imul(b,lt)|0)+Math.imul(v,ct)|0,o=o+Math.imul(v,lt)|0;var Et=(h+(i=i+Math.imul(p,pt)|0)|0)+((8191&(n=(n=n+Math.imul(p,mt)|0)+Math.imul(m,pt)|0))<<13)|0;h=((o=o+Math.imul(m,mt)|0)+(n>>>13)|0)+(Et>>>26)|0,Et&=67108863,i=Math.imul(z,Z),n=(n=Math.imul(z,G))+Math.imul(K,Z)|0,o=Math.imul(K,G),i=i+Math.imul(j,W)|0,n=(n=n+Math.imul(j,J)|0)+Math.imul(D,W)|0,o=o+Math.imul(D,J)|0,i=i+Math.imul(P,$)|0,n=(n=n+Math.imul(P,tt)|0)+Math.imul(R,$)|0,o=o+Math.imul(R,tt)|0,i=i+Math.imul(B,rt)|0,n=(n=n+Math.imul(B,it)|0)+Math.imul(C,rt)|0,o=o+Math.imul(C,it)|0,i=i+Math.imul(E,ot)|0,n=(n=n+Math.imul(E,at)|0)+Math.imul(k,ot)|0,o=o+Math.imul(k,at)|0,i=i+Math.imul(A,ut)|0,n=(n=n+Math.imul(A,ht)|0)+Math.imul(I,ut)|0,o=o+Math.imul(I,ht)|0,i=i+Math.imul(w,ct)|0,n=(n=n+Math.imul(w,lt)|0)+Math.imul(_,ct)|0,o=o+Math.imul(_,lt)|0;var kt=(h+(i=i+Math.imul(b,pt)|0)|0)+((8191&(n=(n=n+Math.imul(b,mt)|0)+Math.imul(v,pt)|0))<<13)|0;h=((o=o+Math.imul(v,mt)|0)+(n>>>13)|0)+(kt>>>26)|0,kt&=67108863,i=Math.imul(z,W),n=(n=Math.imul(z,J))+Math.imul(K,W)|0,o=Math.imul(K,J),i=i+Math.imul(j,$)|0,n=(n=n+Math.imul(j,tt)|0)+Math.imul(D,$)|0,o=o+Math.imul(D,tt)|0,i=i+Math.imul(P,rt)|0,n=(n=n+Math.imul(P,it)|0)+Math.imul(R,rt)|0,o=o+Math.imul(R,it)|0,i=i+Math.imul(B,ot)|0,n=(n=n+Math.imul(B,at)|0)+Math.imul(C,ot)|0,o=o+Math.imul(C,at)|0,i=i+Math.imul(E,ut)|0,n=(n=n+Math.imul(E,ht)|0)+Math.imul(k,ut)|0,o=o+Math.imul(k,ht)|0,i=i+Math.imul(A,ct)|0,n=(n=n+Math.imul(A,lt)|0)+Math.imul(I,ct)|0,o=o+Math.imul(I,lt)|0;var xt=(h+(i=i+Math.imul(w,pt)|0)|0)+((8191&(n=(n=n+Math.imul(w,mt)|0)+Math.imul(_,pt)|0))<<13)|0;h=((o=o+Math.imul(_,mt)|0)+(n>>>13)|0)+(xt>>>26)|0,xt&=67108863,i=Math.imul(z,$),n=(n=Math.imul(z,tt))+Math.imul(K,$)|0,o=Math.imul(K,tt),i=i+Math.imul(j,rt)|0,n=(n=n+Math.imul(j,it)|0)+Math.imul(D,rt)|0,o=o+Math.imul(D,it)|0,i=i+Math.imul(P,ot)|0,n=(n=n+Math.imul(P,at)|0)+Math.imul(R,ot)|0,o=o+Math.imul(R,at)|0,i=i+Math.imul(B,ut)|0,n=(n=n+Math.imul(B,ht)|0)+Math.imul(C,ut)|0,o=o+Math.imul(C,ht)|0,i=i+Math.imul(E,ct)|0,n=(n=n+Math.imul(E,lt)|0)+Math.imul(k,ct)|0,o=o+Math.imul(k,lt)|0;var Bt=(h+(i=i+Math.imul(A,pt)|0)|0)+((8191&(n=(n=n+Math.imul(A,mt)|0)+Math.imul(I,pt)|0))<<13)|0;h=((o=o+Math.imul(I,mt)|0)+(n>>>13)|0)+(Bt>>>26)|0,Bt&=67108863,i=Math.imul(z,rt),n=(n=Math.imul(z,it))+Math.imul(K,rt)|0,o=Math.imul(K,it),i=i+Math.imul(j,ot)|0,n=(n=n+Math.imul(j,at)|0)+Math.imul(D,ot)|0,o=o+Math.imul(D,at)|0,i=i+Math.imul(P,ut)|0,n=(n=n+Math.imul(P,ht)|0)+Math.imul(R,ut)|0,o=o+Math.imul(R,ht)|0,i=i+Math.imul(B,ct)|0,n=(n=n+Math.imul(B,lt)|0)+Math.imul(C,ct)|0,o=o+Math.imul(C,lt)|0;var Ct=(h+(i=i+Math.imul(E,pt)|0)|0)+((8191&(n=(n=n+Math.imul(E,mt)|0)+Math.imul(k,pt)|0))<<13)|0;h=((o=o+Math.imul(k,mt)|0)+(n>>>13)|0)+(Ct>>>26)|0,Ct&=67108863,i=Math.imul(z,ot),n=(n=Math.imul(z,at))+Math.imul(K,ot)|0,o=Math.imul(K,at),i=i+Math.imul(j,ut)|0,n=(n=n+Math.imul(j,ht)|0)+Math.imul(D,ut)|0,o=o+Math.imul(D,ht)|0,i=i+Math.imul(P,ct)|0,n=(n=n+Math.imul(P,lt)|0)+Math.imul(R,ct)|0,o=o+Math.imul(R,lt)|0;var Tt=(h+(i=i+Math.imul(B,pt)|0)|0)+((8191&(n=(n=n+Math.imul(B,mt)|0)+Math.imul(C,pt)|0))<<13)|0;h=((o=o+Math.imul(C,mt)|0)+(n>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,i=Math.imul(z,ut),n=(n=Math.imul(z,ht))+Math.imul(K,ut)|0,o=Math.imul(K,ht),i=i+Math.imul(j,ct)|0,n=(n=n+Math.imul(j,lt)|0)+Math.imul(D,ct)|0,o=o+Math.imul(D,lt)|0;var Pt=(h+(i=i+Math.imul(P,pt)|0)|0)+((8191&(n=(n=n+Math.imul(P,mt)|0)+Math.imul(R,pt)|0))<<13)|0;h=((o=o+Math.imul(R,mt)|0)+(n>>>13)|0)+(Pt>>>26)|0,Pt&=67108863,i=Math.imul(z,ct),n=(n=Math.imul(z,lt))+Math.imul(K,ct)|0,o=Math.imul(K,lt);var Rt=(h+(i=i+Math.imul(j,pt)|0)|0)+((8191&(n=(n=n+Math.imul(j,mt)|0)+Math.imul(D,pt)|0))<<13)|0;h=((o=o+Math.imul(D,mt)|0)+(n>>>13)|0)+(Rt>>>26)|0,Rt&=67108863;var Ot=(h+(i=Math.imul(z,pt))|0)+((8191&(n=(n=Math.imul(z,mt))+Math.imul(K,pt)|0))<<13)|0;return h=((o=Math.imul(K,mt))+(n>>>13)|0)+(Ot>>>26)|0,Ot&=67108863,u[0]=gt,u[1]=bt,u[2]=vt,u[3]=yt,u[4]=wt,u[5]=_t,u[6]=Mt,u[7]=At,u[8]=It,u[9]=St,u[10]=Et,u[11]=kt,u[12]=xt,u[13]=Bt,u[14]=Ct,u[15]=Tt,u[16]=Pt,u[17]=Rt,u[18]=Ot,0!==h&&(u[19]=h,r.length++),r};function p(t,e,r){return(new m).mulp(t,e,r)}function m(t,e){this.x=t,this.y=e}Math.imul||(d=l),o.prototype.mulTo=function(t,e){var r=this.length+t.length;return 10===this.length&&10===t.length?d(this,t,e):r<63?l(this,t,e):r<1024?function(t,e,r){r.negative=e.negative^t.negative,r.length=t.length+e.length;for(var i=0,n=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,i=a,a=n}return 0!==i?r.words[o]=i:r.length--,r.strip()}(this,t,e):p(this,t,e)},m.prototype.makeRBT=function(t){for(var e=new Array(t),r=o.prototype._countBits(t)-1,i=0;i>=1;return i},m.prototype.permute=function(t,e,r,i,n,o){for(var a=0;a>>=1)n++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*e;a>=26,e+=n/67108864|0,e+=o>>>26,this.words[r]=67108863&o}return 0!==e&&(this.words[r]=e,this.length++),this},o.prototype.muln=function(t){return this.clone().imuln(t)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(t){var e=function(t){for(var e=new Array(t.bitLength()),r=0;r>>n}return e}(t);if(0===e.length)return new o(1);for(var r=this,i=0;i=0);var e,r=t%26,n=(t-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(e=0;e>>26-r}a&&(this.words[e]=a,this.length++)}if(0!==n){for(e=this.length-1;e>=0;e--)this.words[e+n]=this.words[e];for(e=0;e=0),n=e?(e-e%26)/26:0;var o=t%26,a=Math.min((t-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,h=0;h=0&&(0!==f||h>=n);h--){var c=0|this.words[h];this.words[h]=f<<26-o|c>>>o,f=c&s}return u&&0!==f&&(u.words[u.length++]=f),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(t,e,r){return i(0===this.negative),this.iushrn(t,e,r)},o.prototype.shln=function(t){return this.clone().ishln(t)},o.prototype.ushln=function(t){return this.clone().iushln(t)},o.prototype.shrn=function(t){return this.clone().ishrn(t)},o.prototype.ushrn=function(t){return this.clone().iushrn(t)},o.prototype.testn=function(t){i("number"===typeof t&&t>=0);var e=t%26,r=(t-e)/26,n=1<=0);var e=t%26,r=(t-e)/26;if(i(0===this.negative,"imaskn works only with positive numbers"),this.length<=r)return this;if(0!==e&&r++,this.length=Math.min(r,this.length),0!==e){var n=67108863^67108863>>>e<=67108864;e++)this.words[e]-=67108864,e===this.length-1?this.words[e+1]=1:this.words[e+1]++;return this.length=Math.max(this.length,e+1),this},o.prototype.isubn=function(t){if(i("number"===typeof t),i(t<67108864),t<0)return this.iaddn(-t);if(0!==this.negative)return this.negative=0,this.iaddn(t),this.negative=1,this;if(this.words[0]-=t,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var e=0;e>26)-(u/67108864|0),this.words[n+r]=67108863&o}for(;n>26,this.words[n+r]=67108863&o;if(0===s)return this.strip();for(i(-1===s),s=0,n=0;n>26,this.words[n]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(t,e){var r=(this.length,t.length),i=this.clone(),n=t,a=0|n.words[n.length-1];0!==(r=26-this._countBits(a))&&(n=n.ushln(r),i.iushln(r),a=0|n.words[n.length-1]);var s,u=i.length-n.length;if("mod"!==e){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var h=0;h=0;c--){var l=67108864*(0|i.words[n.length+c])+(0|i.words[n.length+c-1]);for(l=Math.min(l/a|0,67108863),i._ishlnsubmul(n,l,c);0!==i.negative;)l--,i.negative=0,i._ishlnsubmul(n,1,c),i.isZero()||(i.negative^=1);s&&(s.words[c]=l)}return s&&s.strip(),i.strip(),"div"!==e&&0!==r&&i.iushrn(r),{div:s||null,mod:i}},o.prototype.divmod=function(t,e,r){return i(!t.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===t.negative?(s=this.neg().divmod(t,e),"mod"!==e&&(n=s.div.neg()),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(t)),{div:n,mod:a}):0===this.negative&&0!==t.negative?(s=this.divmod(t.neg(),e),"mod"!==e&&(n=s.div.neg()),{div:n,mod:s.mod}):0!==(this.negative&t.negative)?(s=this.neg().divmod(t.neg(),e),"div"!==e&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(t)),{div:s.div,mod:a}):t.length>this.length||this.cmp(t)<0?{div:new o(0),mod:this}:1===t.length?"div"===e?{div:this.divn(t.words[0]),mod:null}:"mod"===e?{div:null,mod:new o(this.modn(t.words[0]))}:{div:this.divn(t.words[0]),mod:new o(this.modn(t.words[0]))}:this._wordDiv(t,e);var n,a,s},o.prototype.div=function(t){return this.divmod(t,"div",!1).div},o.prototype.mod=function(t){return this.divmod(t,"mod",!1).mod},o.prototype.umod=function(t){return this.divmod(t,"mod",!0).mod},o.prototype.divRound=function(t){var e=this.divmod(t);if(e.mod.isZero())return e.div;var r=0!==e.div.negative?e.mod.isub(t):e.mod,i=t.ushrn(1),n=t.andln(1),o=r.cmp(i);return o<0||1===n&&0===o?e.div:0!==e.div.negative?e.div.isubn(1):e.div.iaddn(1)},o.prototype.modn=function(t){i(t<=67108863);for(var e=(1<<26)%t,r=0,n=this.length-1;n>=0;n--)r=(e*r+(0|this.words[n]))%t;return r},o.prototype.idivn=function(t){i(t<=67108863);for(var e=0,r=this.length-1;r>=0;r--){var n=(0|this.words[r])+67108864*e;this.words[r]=n/t|0,e=n%t}return this.strip()},o.prototype.divn=function(t){return this.clone().idivn(t)},o.prototype.egcd=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n=new o(1),a=new o(0),s=new o(0),u=new o(1),h=0;e.isEven()&&r.isEven();)e.iushrn(1),r.iushrn(1),++h;for(var f=r.clone(),c=e.clone();!e.isZero();){for(var l=0,d=1;0===(e.words[0]&d)&&l<26;++l,d<<=1);if(l>0)for(e.iushrn(l);l-- >0;)(n.isOdd()||a.isOdd())&&(n.iadd(f),a.isub(c)),n.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(f),u.isub(c)),s.iushrn(1),u.iushrn(1);e.cmp(r)>=0?(e.isub(r),n.isub(s),a.isub(u)):(r.isub(e),s.isub(n),u.isub(a))}return{a:s,b:u,gcd:r.iushln(h)}},o.prototype._invmp=function(t){i(0===t.negative),i(!t.isZero());var e=this,r=t.clone();e=0!==e.negative?e.umod(t):e.clone();for(var n,a=new o(1),s=new o(0),u=r.clone();e.cmpn(1)>0&&r.cmpn(1)>0;){for(var h=0,f=1;0===(e.words[0]&f)&&h<26;++h,f<<=1);if(h>0)for(e.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var c=0,l=1;0===(r.words[0]&l)&&c<26;++c,l<<=1);if(c>0)for(r.iushrn(c);c-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);e.cmp(r)>=0?(e.isub(r),a.isub(s)):(r.isub(e),s.isub(a))}return(n=0===e.cmpn(1)?a:s).cmpn(0)<0&&n.iadd(t),n},o.prototype.gcd=function(t){if(this.isZero())return t.abs();if(t.isZero())return this.abs();var e=this.clone(),r=t.clone();e.negative=0,r.negative=0;for(var i=0;e.isEven()&&r.isEven();i++)e.iushrn(1),r.iushrn(1);for(;;){for(;e.isEven();)e.iushrn(1);for(;r.isEven();)r.iushrn(1);var n=e.cmp(r);if(n<0){var o=e;e=r,r=o}else if(0===n||0===r.cmpn(1))break;e.isub(r)}return r.iushln(i)},o.prototype.invm=function(t){return this.egcd(t).a.umod(t)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(t){return this.words[0]&t},o.prototype.bincn=function(t){i("number"===typeof t);var e=t%26,r=(t-e)/26,n=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.prototype.cmpn=function(t){var e,r=t<0;if(0!==this.negative&&!r)return-1;if(0===this.negative&&r)return 1;if(this.strip(),this.length>1)e=1;else{r&&(t=-t),i(t<=67108863,"Number is too big");var n=0|this.words[0];e=n===t?0:nt.length)return 1;if(this.length=0;r--){var i=0|this.words[r],n=0|t.words[r];if(i!==n){in&&(e=1);break}}return e},o.prototype.gtn=function(t){return 1===this.cmpn(t)},o.prototype.gt=function(t){return 1===this.cmp(t)},o.prototype.gten=function(t){return this.cmpn(t)>=0},o.prototype.gte=function(t){return this.cmp(t)>=0},o.prototype.ltn=function(t){return-1===this.cmpn(t)},o.prototype.lt=function(t){return-1===this.cmp(t)},o.prototype.lten=function(t){return this.cmpn(t)<=0},o.prototype.lte=function(t){return this.cmp(t)<=0},o.prototype.eqn=function(t){return 0===this.cmpn(t)},o.prototype.eq=function(t){return 0===this.cmp(t)},o.red=function(t){return new M(t)},o.prototype.toRed=function(t){return i(!this.red,"Already a number in reduction context"),i(0===this.negative,"red works only with positives"),t.convertTo(this)._forceRed(t)},o.prototype.fromRed=function(){return i(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(t){return this.red=t,this},o.prototype.forceRed=function(t){return i(!this.red,"Already a number in reduction context"),this._forceRed(t)},o.prototype.redAdd=function(t){return i(this.red,"redAdd works only with red numbers"),this.red.add(this,t)},o.prototype.redIAdd=function(t){return i(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,t)},o.prototype.redSub=function(t){return i(this.red,"redSub works only with red numbers"),this.red.sub(this,t)},o.prototype.redISub=function(t){return i(this.red,"redISub works only with red numbers"),this.red.isub(this,t)},o.prototype.redShl=function(t){return i(this.red,"redShl works only with red numbers"),this.red.shl(this,t)},o.prototype.redMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.mul(this,t)},o.prototype.redIMul=function(t){return i(this.red,"redMul works only with red numbers"),this.red._verify2(this,t),this.red.imul(this,t)},o.prototype.redSqr=function(){return i(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return i(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return i(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return i(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return i(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(t){return i(this.red&&!t.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,t)};var g={k256:null,p224:null,p192:null,p25519:null};function b(t,e){this.name=t,this.p=new o(e,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function v(){b.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function y(){b.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){b.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){b.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(t){if("string"===typeof t){var e=o._prime(t);this.m=e.p,this.prime=e}else i(t.gtn(1),"modulus must be greater than 1"),this.m=t,this.prime=null}function A(t){M.call(this,t),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}b.prototype._tmp=function(){var t=new o(null);return t.words=new Array(Math.ceil(this.n/13)),t},b.prototype.ireduce=function(t){var e,r=t;do{this.split(r,this.tmp),e=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(e>this.n);var i=e0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},b.prototype.split=function(t,e){t.iushrn(this.n,0,e)},b.prototype.imulK=function(t){return t.imul(this.k)},n(v,b),v.prototype.split=function(t,e){for(var r=Math.min(t.length,9),i=0;i>>22,n=o}n>>>=22,t.words[i-10]=n,0===n&&t.length>10?t.length-=10:t.length-=9},v.prototype.imulK=function(t){t.words[t.length]=0,t.words[t.length+1]=0,t.length+=2;for(var e=0,r=0;r>>=26,t.words[r]=n,e=i}return 0!==e&&(t.words[t.length++]=e),t},o._prime=function(t){if(g[t])return g[t];var e;if("k256"===t)e=new v;else if("p224"===t)e=new y;else if("p192"===t)e=new w;else{if("p25519"!==t)throw new Error("Unknown prime "+t);e=new _}return g[t]=e,e},M.prototype._verify1=function(t){i(0===t.negative,"red works only with positives"),i(t.red,"red works only with red numbers")},M.prototype._verify2=function(t,e){i(0===(t.negative|e.negative),"red works only with positives"),i(t.red&&t.red===e.red,"red works only with red numbers")},M.prototype.imod=function(t){return this.prime?this.prime.ireduce(t)._forceRed(this):t.umod(this.m)._forceRed(this)},M.prototype.neg=function(t){return t.isZero()?t.clone():this.m.sub(t)._forceRed(this)},M.prototype.add=function(t,e){this._verify2(t,e);var r=t.add(e);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},M.prototype.iadd=function(t,e){this._verify2(t,e);var r=t.iadd(e);return r.cmp(this.m)>=0&&r.isub(this.m),r},M.prototype.sub=function(t,e){this._verify2(t,e);var r=t.sub(e);return r.cmpn(0)<0&&r.iadd(this.m),r._forceRed(this)},M.prototype.isub=function(t,e){this._verify2(t,e);var r=t.isub(e);return r.cmpn(0)<0&&r.iadd(this.m),r},M.prototype.shl=function(t,e){return this._verify1(t),this.imod(t.ushln(e))},M.prototype.imul=function(t,e){return this._verify2(t,e),this.imod(t.imul(e))},M.prototype.mul=function(t,e){return this._verify2(t,e),this.imod(t.mul(e))},M.prototype.isqr=function(t){return this.imul(t,t.clone())},M.prototype.sqr=function(t){return this.mul(t,t)},M.prototype.sqrt=function(t){if(t.isZero())return t.clone();var e=this.m.andln(3);if(i(e%2===1),3===e){var r=this.m.add(new o(1)).iushrn(2);return this.pow(t,r)}for(var n=this.m.subn(1),a=0;!n.isZero()&&0===n.andln(1);)a++,n.iushrn(1);i(!n.isZero());var s=new o(1).toRed(this),u=s.redNeg(),h=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new o(2*f*f).toRed(this);0!==this.pow(f,h).cmp(u);)f.redIAdd(u);for(var c=this.pow(f,n),l=this.pow(t,n.addn(1).iushrn(1)),d=this.pow(t,n),p=a;0!==d.cmp(s);){for(var m=d,g=0;0!==m.cmp(s);g++)m=m.redSqr();i(g=0;i--){for(var h=e.words[i],f=u-1;f>=0;f--){var c=h>>f&1;n!==r[0]&&(n=this.sqr(n)),0!==c||0!==a?(a<<=1,a|=c,(4===++s||0===i&&0===f)&&(n=this.mul(n,r[a]),s=0,a=0)):s=0}u=26}return n},M.prototype.convertTo=function(t){var e=t.umod(this.m);return e===t?e.clone():e},M.prototype.convertFrom=function(t){var e=t.clone();return e.red=null,e},o.mont=function(t){return new A(t)},n(A,M),A.prototype.convertTo=function(t){return this.imod(t.ushln(this.shift))},A.prototype.convertFrom=function(t){var e=this.imod(t.mul(this.rinv));return e.red=null,e},A.prototype.imul=function(t,e){if(t.isZero()||e.isZero())return t.words[0]=0,t.length=1,t;var r=t.imul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.mul=function(t,e){if(t.isZero()||e.isZero())return new o(0)._forceRed(this);var r=t.mul(e),i=r.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=r.isub(i).iushrn(this.shift),a=n;return n.cmp(this.m)>=0?a=n.isub(this.m):n.cmpn(0)<0&&(a=n.iadd(this.m)),a._forceRed(this)},A.prototype.invm=function(t){return this.imod(t._invmp(this.m).mul(this.r2))._forceRed(this)}}(t,this)}).call(this,r(29)(t))},function(t,e){},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0})}]); \ No newline at end of file diff --git a/docs/static/js/2.0eda3dfb.chunk.js b/docs/static/js/2.6c1f724b.chunk.js similarity index 50% rename from docs/static/js/2.0eda3dfb.chunk.js rename to docs/static/js/2.6c1f724b.chunk.js index 3169747..88c7b41 100644 --- a/docs/static/js/2.0eda3dfb.chunk.js +++ b/docs/static/js/2.6c1f724b.chunk.js @@ -1 +1 @@ -(window.webpackJsonppopup=window.webpackJsonppopup||[]).push([[2],[function(e,t,r){"use strict";e.exports=r(435)},,function(e,t,r){"use strict";t.__esModule=!0;var n,i=r(397),o=(n=i)&&n.__esModule?n:{default:n};t.default=o.default||function(e){for(var t=1;t2&&void 0!==arguments[2]?arguments[2]:l.duration,u=arguments[3],h=arguments.length>4&&void 0!==arguments[4]?arguments[4]:l.mask,d={info:"",success:"success",fail:"fail",offline:"dislike",loading:"loading"}[t];!function(e,t){var r;c&&(c.destroy(),c=null),a.default.newInstance({prefixCls:f,style:{},transitionName:"am-fade",className:(0,i.default)((r={},(0,n.default)(r,f+"-mask",e),(0,n.default)(r,f+"-nomask",!e),r))},(function(e){return t&&t(e)}))}(h,(function(t){c=t,t.notice({duration:r,style:{},content:d?o.createElement("div",{className:f+"-text "+f+"-text-icon",role:"alert","aria-live":"assertive"},o.createElement(s.default,{type:d,size:"lg"}),o.createElement("div",{className:f+"-text-info"},e)):o.createElement("div",{className:f+"-text",role:"alert","aria-live":"assertive"},o.createElement("div",null,e)),closable:!0,onClose:function(){u&&u(),t.destroy(),t=null,c=null}})}))}t.default={SHORT:3,LONG:8,show:function(e,t,r){return h(e,"info",t,(function(){}),r)},info:function(e,t,r,n){return h(e,"info",t,r,n)},success:function(e,t,r,n){return h(e,"success",t,r,n)},fail:function(e,t,r,n){return h(e,"fail",t,r,n)},offline:function(e,t,r,n){return h(e,"offline",t,r,n)},loading:function(e,t,r,n){return h(e,"loading",t,r,n)},hide:function(){c&&(c.destroy(),c=null)},config:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.duration,r=void 0===t?3:t,n=e.mask;l.duration=r,!1===n&&(l.mask=!1)}},e.exports=t.default},function(e,t,r){e.exports=r(450)},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";function n(e,t){for(var r=0;r0||e===t?t:t-1}function y(e){for(var t,r,n=1,i=e.length,o=e[0]+"";nl^r?1:-1;for(s=(u=i.length)<(l=o.length)?u:l,a=0;ao[a]^r?1:-1;return u==l?0:u>l^r?1:-1}function w(e,t,r,n){if(er||e!==u(e))throw Error(l+(n||"Argument")+("number"==typeof e?er?" out of range: ":" not an integer: ":" not a primitive number: ")+String(e))}function _(e){var t=e.c.length-1;return g(e.e/h)==t&&e.c[t]%2!=0}function C(e,t){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(t<0?"e":"e+")+t}function M(e,t,r){var n,i;if(t<0){for(i=r+".";++t;i+=r);e=i+e}else if(++t>(n=e.length)){for(i=r,t-=n;--t;i+=r);e+=i}else tO?g.c=g.e=null:e.e=10;f/=10,l++);return void(l>O?g.c=g.e=null:(g.e=l,g.c=[e]))}v=String(e)}else{if(!a.test(v=String(e)))return i(g,v,p);g.s=45==v.charCodeAt(0)?(v=v.slice(1),-1):1}(l=v.indexOf("."))>-1&&(v=v.replace(".","")),(f=v.search(/e/i))>0?(l<0&&(l=f),l+=+v.slice(f+1),v=v.substring(0,f)):l<0&&(l=v.length)}else{if(w(t,2,j.length,"Base"),10==t)return z(g=new R(e),E+g.e+1,S);if(v=String(e),p="number"==typeof e){if(0*e!=0)return i(g,v,p,t);if(g.s=1/e<0?(v=v.slice(1),-1):1,R.DEBUG&&v.replace(/^0\.0*|\./,"").length>15)throw Error(c+e)}else g.s=45===v.charCodeAt(0)?(v=v.slice(1),-1):1;for(r=j.slice(0,t),l=f=0,m=v.length;fl){l=m;continue}}else if(!s&&(v==v.toUpperCase()&&(v=v.toLowerCase())||v==v.toLowerCase()&&(v=v.toUpperCase()))){s=!0,f=-1,l=0;continue}return i(g,String(e),p,t)}p=!1,(l=(v=n(v,t,10,g.s)).indexOf("."))>-1?v=v.replace(".",""):l=v.length}for(f=0;48===v.charCodeAt(f);f++);for(m=v.length;48===v.charCodeAt(--m););if(v=v.slice(f,++m)){if(m-=f,p&&R.DEBUG&&m>15&&(e>d||e!==u(e)))throw Error(c+g.s*e);if((l=l-f-1)>O)g.c=g.e=null;else if(l=A)?C(u,a):M(u,a,"0");else if(o=(e=z(new R(e),t,r)).e,s=(u=y(e.c)).length,1==n||2==n&&(t<=o||o<=k)){for(;ss){if(--t>0)for(u+=".";t--;u+="0");}else if((t+=o-s)>0)for(o+1==s&&(u+=".");t--;u+="0");return e.s<0&&i?"-"+u:u}function F(e,t){for(var r,n=1,i=new R(e[0]);n=10;i/=10,n++);return(r=n+r*h-1)>O?e.c=e.e=null:r=10;l/=10,i++);if((o=t-i)<0)o+=h,a=t,m=(c=v[d=0])/g[i-a-1]%10|0;else if((d=s((o+1)/h))>=v.length){if(!n)break e;for(;v.length<=d;v.push(0));c=m=0,i=1,a=(o%=h)-h+1}else{for(c=l=v[d],i=1;l>=10;l/=10,i++);m=(a=(o%=h)-h+i)<0?0:c/g[i-a-1]%10|0}if(n=n||t<0||null!=v[d+1]||(a<0?c:c%g[i-a-1]),n=r<4?(m||n)&&(0==r||r==(e.s<0?3:2)):m>5||5==m&&(4==r||n||6==r&&(o>0?a>0?c/g[i-a]:0:v[d-1])%10&1||r==(e.s<0?8:7)),t<1||!v[0])return v.length=0,n?(t-=e.e+1,v[0]=g[(h-t%h)%h],e.e=-t||0):v[0]=e.e=0,e;if(0==o?(v.length=d,l=1,d--):(v.length=d+1,l=g[h-o],v[d]=a>0?u(c/g[i-a]%g[a])*l:0),n)for(;;){if(0==d){for(o=1,a=v[0];a>=10;a/=10,o++);for(a=v[0]+=l,l=1;a>=10;a/=10,l++);o!=l&&(e.e++,v[0]==f&&(v[0]=1));break}if(v[d]+=l,v[d]!=f)break;v[d--]=0,l=1}for(o=v.length;0===v[--o];v.pop());}e.e>O?e.c=e.e=null:e.e=A?C(t,r):M(t,r,"0"),e.s<0?"-"+t:t)}return R.clone=e,R.ROUND_UP=0,R.ROUND_DOWN=1,R.ROUND_CEIL=2,R.ROUND_FLOOR=3,R.ROUND_HALF_UP=4,R.ROUND_HALF_DOWN=5,R.ROUND_HALF_EVEN=6,R.ROUND_HALF_CEIL=7,R.ROUND_HALF_FLOOR=8,R.EUCLID=9,R.config=R.set=function(e){var t,r;if(null!=e){if("object"!=typeof e)throw Error(l+"Object expected: "+e);if(e.hasOwnProperty(t="DECIMAL_PLACES")&&(w(r=e[t],0,v,t),E=r),e.hasOwnProperty(t="ROUNDING_MODE")&&(w(r=e[t],0,8,t),S=r),e.hasOwnProperty(t="EXPONENTIAL_AT")&&((r=e[t])&&r.pop?(w(r[0],-v,0,t),w(r[1],0,v,t),k=r[0],A=r[1]):(w(r,-v,v,t),k=-(A=r<0?-r:r))),e.hasOwnProperty(t="RANGE"))if((r=e[t])&&r.pop)w(r[0],-v,-1,t),w(r[1],1,v,t),I=r[0],O=r[1];else{if(w(r,-v,v,t),!r)throw Error(l+t+" cannot be zero: "+r);I=-(O=r<0?-r:r)}if(e.hasOwnProperty(t="CRYPTO")){if((r=e[t])!==!!r)throw Error(l+t+" not true or false: "+r);if(r){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw P=!r,Error(l+"crypto unavailable");P=r}else P=r}if(e.hasOwnProperty(t="MODULO_MODE")&&(w(r=e[t],0,9,t),T=r),e.hasOwnProperty(t="POW_PRECISION")&&(w(r=e[t],0,v,t),N=r),e.hasOwnProperty(t="FORMAT")){if("object"!=typeof(r=e[t]))throw Error(l+t+" not an object: "+r);B=r}if(e.hasOwnProperty(t="ALPHABET")){if("string"!=typeof(r=e[t])||/^.$|[+-.\s]|(.).*\1/.test(r))throw Error(l+t+" invalid: "+r);j=r}}return{DECIMAL_PLACES:E,ROUNDING_MODE:S,EXPONENTIAL_AT:[k,A],RANGE:[I,O],CRYPTO:P,MODULO_MODE:T,POW_PRECISION:N,FORMAT:B,ALPHABET:j}},R.isBigNumber=function(e){if(!e||!0!==e._isBigNumber)return!1;if(!R.DEBUG)return!0;var t,r,n=e.c,i=e.e,o=e.s;e:if("[object Array]"=={}.toString.call(n)){if((1===o||-1===o)&&i>=-v&&i<=v&&i===u(i)){if(0===n[0]){if(0===i&&1===n.length)return!0;break e}if((t=(i+1)%h)<1&&(t+=h),String(n[0]).length==t){for(t=0;t=f||r!==u(r))break e;if(0!==r)return!0}}}else if(null===n&&null===i&&(null===o||1===o||-1===o))return!0;throw Error(l+"Invalid BigNumber: "+e)},R.maximum=R.max=function(){return F(arguments,o.lt)},R.minimum=R.min=function(){return F(arguments,o.gt)},R.random=function(){var e=9007199254740992*Math.random()&2097151?function(){return u(9007199254740992*Math.random())}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(t){var r,n,i,o,a,c=0,f=[],d=new R(x);if(null==t?t=E:w(t,0,v),o=s(t/h),P)if(crypto.getRandomValues){for(r=crypto.getRandomValues(new Uint32Array(o*=2));c>>11))>=9e15?(n=crypto.getRandomValues(new Uint32Array(2)),r[c]=n[0],r[c+1]=n[1]):(f.push(a%1e14),c+=2);c=o/2}else{if(!crypto.randomBytes)throw P=!1,Error(l+"crypto unavailable");for(r=crypto.randomBytes(o*=7);c=9e15?crypto.randomBytes(7).copy(r,c):(f.push(a%1e14),c+=7);c=o/7}if(!P)for(;c=10;a/=10,c++);cr-1&&(null==a[i+1]&&(a[i+1]=0),a[i+1]+=a[i]/r|0,a[i]%=r)}return a.reverse()}return function(t,n,i,o,a){var s,u,l,c,f,h,d,p,m=t.indexOf("."),v=E,g=S;for(m>=0&&(c=N,N=0,t=t.replace(".",""),h=(p=new R(n)).pow(t.length-m),N=c,p.c=e(M(y(h.c),h.e,"0"),10,i,"0123456789"),p.e=p.c.length),l=c=(d=e(t,n,i,a?(s=j,"0123456789"):(s="0123456789",j))).length;0==d[--c];d.pop());if(!d[0])return s.charAt(0);if(m<0?--l:(h.c=d,h.e=l,h.s=o,d=(h=r(h,p,v,g,i)).c,f=h.r,l=h.e),m=d[u=l+v+1],c=i/2,f=f||u<0||null!=d[u+1],f=g<4?(null!=m||f)&&(0==g||g==(h.s<0?3:2)):m>c||m==c&&(4==g||f||6==g&&1&d[u-1]||g==(h.s<0?8:7)),u<1||!d[0])t=f?M(s.charAt(1),-v,s.charAt(0)):s.charAt(0);else{if(d.length=u,f)for(--i;++d[--u]>i;)d[u]=0,u||(++l,d=[1].concat(d));for(c=d.length;!d[--c];);for(m=0,t="";m<=c;t+=s.charAt(d[m++]));t=M(t,l,s.charAt(0))}return t}}(),r=function(){function e(e,t,r){var n,i,o,a,s=0,u=e.length,l=t%m,c=t/m|0;for(e=e.slice();u--;)s=((i=l*(o=e[u]%m)+(n=c*o+(a=e[u]/m|0)*l)%m*m+s)/r|0)+(n/m|0)+c*a,e[u]=i%r;return s&&(e=[s].concat(e)),e}function t(e,t,r,n){var i,o;if(r!=n)o=r>n?1:-1;else for(i=o=0;it[i]?1:-1;break}return o}function r(e,t,r,n){for(var i=0;r--;)e[r]-=i,i=e[r]1;e.splice(0,1));}return function(n,i,o,a,s){var l,c,d,p,m,v,y,b,w,_,C,M,x,E,S,k,A,I=n.s==i.s?1:-1,O=n.c,P=i.c;if(!O||!O[0]||!P||!P[0])return new R(n.s&&i.s&&(O?!P||O[0]!=P[0]:P)?O&&0==O[0]||!P?0*I:I/0:NaN);for(w=(b=new R(I)).c=[],I=o+(c=n.e-i.e)+1,s||(s=f,c=g(n.e/h)-g(i.e/h),I=I/h|0),d=0;P[d]==(O[d]||0);d++);if(P[d]>(O[d]||0)&&c--,I<0)w.push(1),p=!0;else{for(E=O.length,k=P.length,d=0,I+=2,(m=u(s/(P[0]+1)))>1&&(P=e(P,m,s),O=e(O,m,s),k=P.length,E=O.length),x=k,C=(_=O.slice(0,k)).length;C=s/2&&S++;do{if(m=0,(l=t(P,_,k,C))<0){if(M=_[0],k!=C&&(M=M*s+(_[1]||0)),(m=u(M/S))>1)for(m>=s&&(m=s-1),y=(v=e(P,m,s)).length,C=_.length;1==t(v,_,y,C);)m--,r(v,k=10;I/=10,d++);z(b,o+(b.e=d+c*h-1)+1,a,p)}else b.e=c,b.r=+p;return b}}(),i=function(){var e=/^(-?)0([xbo])(?=\w[\w.]*$)/i,t=/^([^.]+)\.$/,r=/^\.([^.]+)$/,n=/^-?(Infinity|NaN)$/,i=/^\s*\+(?=[\w.])|^\s+|\s+$/g;return function(o,a,s,u){var c,f=s?a:a.replace(i,"");if(n.test(f))o.s=isNaN(f)?null:f<0?-1:1;else{if(!s&&(f=f.replace(e,(function(e,t,r){return c="x"==(r=r.toLowerCase())?16:"b"==r?2:8,u&&u!=c?e:t})),u&&(c=u,f=f.replace(t,"$1").replace(r,"0.$1")),a!=f))return new R(f,c);if(R.DEBUG)throw Error(l+"Not a"+(u?" base "+u:"")+" number: "+a);o.s=null}o.c=o.e=null}}(),o.absoluteValue=o.abs=function(){var e=new R(this);return e.s<0&&(e.s=1),e},o.comparedTo=function(e,t){return b(this,new R(e,t))},o.decimalPlaces=o.dp=function(e,t){var r,n,i,o=this;if(null!=e)return w(e,0,v),null==t?t=S:w(t,0,8),z(new R(o),e+o.e+1,t);if(!(r=o.c))return null;if(n=((i=r.length-1)-g(this.e/h))*h,i=r[i])for(;i%10==0;i/=10,n--);return n<0&&(n=0),n},o.dividedBy=o.div=function(e,t){return r(this,new R(e,t),E,S)},o.dividedToIntegerBy=o.idiv=function(e,t){return r(this,new R(e,t),0,1)},o.exponentiatedBy=o.pow=function(e,t){var r,n,i,o,a,c,f,d,p=this;if((e=new R(e)).c&&!e.isInteger())throw Error(l+"Exponent not an integer: "+U(e));if(null!=t&&(t=new R(t)),a=e.e>14,!p.c||!p.c[0]||1==p.c[0]&&!p.e&&1==p.c.length||!e.c||!e.c[0])return d=new R(Math.pow(+U(p),a?2-_(e):+U(e))),t?d.mod(t):d;if(c=e.s<0,t){if(t.c?!t.c[0]:!t.s)return new R(NaN);(n=!c&&p.isInteger()&&t.isInteger())&&(p=p.mod(t))}else{if(e.e>9&&(p.e>0||p.e<-1||(0==p.e?p.c[0]>1||a&&p.c[1]>=24e7:p.c[0]<8e13||a&&p.c[0]<=9999975e7)))return o=p.s<0&&_(e)?-0:0,p.e>-1&&(o=1/o),new R(c?1/o:o);N&&(o=s(N/h+2))}for(a?(r=new R(.5),c&&(e.s=1),f=_(e)):f=(i=Math.abs(+U(e)))%2,d=new R(x);;){if(f){if(!(d=d.times(p)).c)break;o?d.c.length>o&&(d.c.length=o):n&&(d=d.mod(t))}if(i){if(0===(i=u(i/2)))break;f=i%2}else if(z(e=e.times(r),e.e+1,1),e.e>14)f=_(e);else{if(0===(i=+U(e)))break;f=i%2}p=p.times(p),o?p.c&&p.c.length>o&&(p.c.length=o):n&&(p=p.mod(t))}return n?d:(c&&(d=x.div(d)),t?d.mod(t):o?z(d,N,S,void 0):d)},o.integerValue=function(e){var t=new R(this);return null==e?e=S:w(e,0,8),z(t,t.e+1,e)},o.isEqualTo=o.eq=function(e,t){return 0===b(this,new R(e,t))},o.isFinite=function(){return!!this.c},o.isGreaterThan=o.gt=function(e,t){return b(this,new R(e,t))>0},o.isGreaterThanOrEqualTo=o.gte=function(e,t){return 1===(t=b(this,new R(e,t)))||0===t},o.isInteger=function(){return!!this.c&&g(this.e/h)>this.c.length-2},o.isLessThan=o.lt=function(e,t){return b(this,new R(e,t))<0},o.isLessThanOrEqualTo=o.lte=function(e,t){return-1===(t=b(this,new R(e,t)))||0===t},o.isNaN=function(){return!this.s},o.isNegative=function(){return this.s<0},o.isPositive=function(){return this.s>0},o.isZero=function(){return!!this.c&&0==this.c[0]},o.minus=function(e,t){var r,n,i,o,a=this,s=a.s;if(t=(e=new R(e,t)).s,!s||!t)return new R(NaN);if(s!=t)return e.s=-t,a.plus(e);var u=a.e/h,l=e.e/h,c=a.c,d=e.c;if(!u||!l){if(!c||!d)return c?(e.s=-t,e):new R(d?a:NaN);if(!c[0]||!d[0])return d[0]?(e.s=-t,e):new R(c[0]?a:3==S?-0:0)}if(u=g(u),l=g(l),c=c.slice(),s=u-l){for((o=s<0)?(s=-s,i=c):(l=u,i=d),i.reverse(),t=s;t--;i.push(0));i.reverse()}else for(n=(o=(s=c.length)<(t=d.length))?s:t,s=t=0;t0)for(;t--;c[r++]=0);for(t=f-1;n>s;){if(c[--n]=0;){for(r=0,p=M[i]%w,v=M[i]/w|0,o=i+(a=u);o>i;)r=((l=p*(l=C[--a]%w)+(s=v*l+(c=C[a]/w|0)*p)%w*w+y[o]+r)/b|0)+(s/w|0)+v*c,y[o--]=l%b;y[o]=r}return r?++n:y.splice(0,1),L(e,y,n)},o.negated=function(){var e=new R(this);return e.s=-e.s||null,e},o.plus=function(e,t){var r,n=this,i=n.s;if(t=(e=new R(e,t)).s,!i||!t)return new R(NaN);if(i!=t)return e.s=-t,n.minus(e);var o=n.e/h,a=e.e/h,s=n.c,u=e.c;if(!o||!a){if(!s||!u)return new R(i/0);if(!s[0]||!u[0])return u[0]?e:new R(s[0]?n:0*i)}if(o=g(o),a=g(a),s=s.slice(),i=o-a){for(i>0?(a=o,r=u):(i=-i,r=s),r.reverse();i--;r.push(0));r.reverse()}for((i=s.length)-(t=u.length)<0&&(r=u,u=s,s=r,t=i),i=0;t;)i=(s[--t]=s[t]+u[t]+i)/f|0,s[t]=f===s[t]?0:s[t]%f;return i&&(s=[i].concat(s),++a),L(e,s,a)},o.precision=o.sd=function(e,t){var r,n,i,o=this;if(null!=e&&e!==!!e)return w(e,1,v),null==t?t=S:w(t,0,8),z(new R(o),e,t);if(!(r=o.c))return null;if(n=(i=r.length-1)*h+1,i=r[i]){for(;i%10==0;i/=10,n--);for(i=r[0];i>=10;i/=10,n++);}return e&&o.e+1>n&&(n=o.e+1),n},o.shiftedBy=function(e){return w(e,-d,d),this.times("1e"+e)},o.squareRoot=o.sqrt=function(){var e,t,n,i,o,a=this,s=a.c,u=a.s,l=a.e,c=E+4,f=new R("0.5");if(1!==u||!s||!s[0])return new R(!u||u<0&&(!s||s[0])?NaN:s?a:1/0);if(0==(u=Math.sqrt(+U(a)))||u==1/0?(((t=y(s)).length+l)%2==0&&(t+="0"),u=Math.sqrt(+t),l=g((l+1)/2)-(l<0||l%2),n=new R(t=u==1/0?"1e"+l:(t=u.toExponential()).slice(0,t.indexOf("e")+1)+l)):n=new R(u+""),n.c[0])for((u=(l=n.e)+c)<3&&(u=0);;)if(o=n,n=f.times(o.plus(r(a,o,c,1))),y(o.c).slice(0,u)===(t=y(n.c)).slice(0,u)){if(n.e0&&m>0){for(o=m%s||s,f=p.substr(0,o);o0&&(f+=c+p.slice(o)),d&&(f="-"+f)}n=h?f+(r.decimalSeparator||"")+((u=+r.fractionGroupSize)?h.replace(new RegExp("\\d{"+u+"}\\B","g"),"$&"+(r.fractionGroupSeparator||"")):h):f}return(r.prefix||"")+n+(r.suffix||"")},o.toFraction=function(e){var t,n,i,o,a,s,u,c,f,d,m,v,g=this,b=g.c;if(null!=e&&(!(u=new R(e)).isInteger()&&(u.c||1!==u.s)||u.lt(x)))throw Error(l+"Argument "+(u.isInteger()?"out of range: ":"not an integer: ")+U(u));if(!b)return new R(g);for(t=new R(x),f=n=new R(x),i=c=new R(x),v=y(b),a=t.e=v.length-g.e-1,t.c[0]=p[(s=a%h)<0?h+s:s],e=!e||u.comparedTo(t)>0?a>0?t:f:u,s=O,O=1/0,u=new R(v),c.c[0]=0;d=r(u,t,0,1),1!=(o=n.plus(d.times(i))).comparedTo(e);)n=i,i=o,f=c.plus(d.times(o=f)),c=o,t=u.minus(d.times(o=t)),u=o;return o=r(e.minus(n),i,0,1),c=c.plus(o.times(f)),n=n.plus(o.times(i)),c.s=f.s=g.s,m=r(f,i,a*=2,S).minus(g).abs().comparedTo(r(c,n,a,S).minus(g).abs())<1?[f,i]:[c,n],O=s,m},o.toNumber=function(){return+U(this)},o.toPrecision=function(e,t){return null!=e&&w(e,1,v),D(this,e,t,2)},o.toString=function(e){var t,r=this,i=r.s,o=r.e;return null===o?i?(t="Infinity",i<0&&(t="-"+t)):t="NaN":(null==e?t=o<=k||o>=A?C(y(r.c),o):M(y(r.c),o,"0"):10===e?t=M(y((r=z(new R(r),E+o+1,S)).c),r.e,"0"):(w(e,2,j.length,"Base"),t=n(M(y(r.c),o,"0"),10,e,i,!0)),i<0&&r.c[0]&&(t="-"+t)),t},o.valueOf=o.toJSON=function(){return U(this)},o._isBigNumber=!0,null!=t&&R.set(t),R}()).default=o.BigNumber=o,void 0===(n=function(){return o}.call(t,r,t,e))||(e.exports=n)}()},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=f(r(2)),i=f(r(3)),o=f(r(7)),a=f(r(4)),s=f(r(5)),u=f(r(9)),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(0)),c=f(r(460));function f(e){return e&&e.__esModule?e:{default:e}}var h=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function p(e,t){if(u.isBuffer(e))return e.length;if("undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!==typeof e&&(e=""+e);var 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 U(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*r;case"hex":return r>>>1;case"base64":return H(e).length;default:if(n)return U(e).length;t=(""+t).toLowerCase(),n=!0}}function m(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 O(this,t,r);case"utf8":case"utf-8":return S(this,t,r);case"ascii":return A(this,t,r);case"latin1":case"binary":return I(this,t,r);case"base64":return E(this,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,t,r);default:if(n)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),n=!0}}function v(e,t,r){var n=e[t];e[t]=e[r],e[r]=n}function g(e,t,r,n,i){if(0===e.length)return-1;if("string"===typeof r?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,isNaN(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=u.from(t,n)),u.isBuffer(t))return 0===t.length?-1:y(e,t,r,n,i);if("number"===typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"===typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(e,t,r):Uint8Array.prototype.lastIndexOf.call(e,t,r):y(e,[t],r,n,i);throw new TypeError("val must be string, number or Buffer")}function y(e,t,r,n,i){var o,a=1,s=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=2,s/=2,u/=2,r/=2}function l(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(i){var c=-1;for(o=r;os&&(r=s-u),o=r;o>=0;o--){for(var f=!0,h=0;hi&&(n=i):n=i;var o=t.length;if(o%2!==0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var a=0;a>8,i=r%256,o.push(i),o.push(n);return o}(t,e.length-r),e,r,n)}function E(e,t,r){return 0===t&&r===e.length?n.fromByteArray(e):n.fromByteArray(e.slice(t,r))}function S(e,t,r){r=Math.min(e.length,r);for(var n=[],i=t;i239?4:l>223?3:l>191?2:1;if(i+f<=r)switch(f){case 1:l<128&&(c=l);break;case 2:128===(192&(o=e[i+1]))&&(u=(31&l)<<6|63&o)>127&&(c=u);break;case 3:o=e[i+1],a=e[i+2],128===(192&o)&&128===(192&a)&&(u=(15&l)<<12|(63&o)<<6|63&a)>2047&&(u<55296||u>57343)&&(c=u);break;case 4:o=e[i+1],a=e[i+2],s=e[i+3],128===(192&o)&&128===(192&a)&&128===(192&s)&&(u=(15&l)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(c=u)}null===c?(c=65533,f=1):c>65535&&(c-=65536,n.push(c>>>10&1023|55296),c=56320|1023&c),n.push(c),i+=f}return function(e){var t=e.length;if(t<=k)return String.fromCharCode.apply(String,e);var r="",n=0;for(;n0&&(e=this.toString("hex",0,r).match(/.{2}/g).join(" "),this.length>r&&(e+=" ... ")),""},u.prototype.compare=function(e,t,r,n,i){if(!u.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(n>=i&&t>=r)return 0;if(n>=i)return-1;if(t>=r)return 1;if(this===e)return 0;for(var o=(i>>>=0)-(n>>>=0),a=(r>>>=0)-(t>>>=0),s=Math.min(o,a),l=this.slice(n,i),c=e.slice(t,r),f=0;fi)&&(r=i),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return b(this,e,t,r);case"utf8":case"utf-8":return w(this,e,t,r);case"ascii":return _(this,e,t,r);case"latin1":case"binary":return C(this,e,t,r);case"base64":return M(this,e,t,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return x(this,e,t,r);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var k=4096;function A(e,t,r){var n="";r=Math.min(e.length,r);for(var i=t;in)&&(r=n);for(var i="",o=t;or)throw new RangeError("Trying to access beyond buffer length")}function N(e,t,r,n,i,o){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw new RangeError("Index out of range")}function B(e,t,r,n){t<0&&(t=65535+t+1);for(var i=0,o=Math.min(e.length-r,2);i>>8*(n?i:1-i)}function j(e,t,r,n){t<0&&(t=4294967295+t+1);for(var i=0,o=Math.min(e.length-r,4);i>>8*(n?i:3-i)&255}function R(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 D(e,t,r,n,o){return o||R(e,0,r,4),i.write(e,t,r,n,23,4),r+4}function F(e,t,r,n,o){return o||R(e,0,r,8),i.write(e,t,r,n,52,8),r+8}u.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t0&&(i*=256);)n+=this[e+--t]*i;return n},u.prototype.readUInt8=function(e,t){return t||T(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||T(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||T(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||T(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||T(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,r){e|=0,t|=0,r||T(e,t,this.length);for(var n=this[e],i=1,o=0;++o=(i*=128)&&(n-=Math.pow(2,8*t)),n},u.prototype.readIntBE=function(e,t,r){e|=0,t|=0,r||T(e,t,this.length);for(var n=t,i=1,o=this[e+--n];n>0&&(i*=256);)o+=this[e+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},u.prototype.readInt8=function(e,t){return t||T(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||T(e,2,this.length);var r=this[e]|this[e+1]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt16BE=function(e,t){t||T(e,2,this.length);var r=this[e+1]|this[e]<<8;return 32768&r?4294901760|r:r},u.prototype.readInt32LE=function(e,t){return t||T(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||T(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||T(e,4,this.length),i.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||T(e,4,this.length),i.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||T(e,8,this.length),i.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||T(e,8,this.length),i.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,r,n){(e=+e,t|=0,r|=0,n)||N(this,e,t,r,Math.pow(2,8*r)-1,0);var i=1,o=0;for(this[t]=255&e;++o=0&&(o*=256);)this[t+i]=e/o&255;return t+r},u.prototype.writeUInt8=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):j(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):j(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);N(this,e,t,r,i-1,-i)}var o=0,a=1,s=0;for(this[t]=255&e;++o>0)-s&255;return t+r},u.prototype.writeIntBE=function(e,t,r,n){if(e=+e,t|=0,!n){var i=Math.pow(2,8*r-1);N(this,e,t,r,i-1,-i)}var o=r-1,a=1,s=0;for(this[t+o]=255&e;--o>=0&&(a*=256);)e<0&&0===s&&0!==this[t+o+1]&&(s=1),this[t+o]=(e/a>>0)-s&255;return t+r},u.prototype.writeInt8=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):B(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):B(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):j(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,r){return e=+e,t|=0,r||N(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):j(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,r){return D(this,e,t,!0,r)},u.prototype.writeFloatBE=function(e,t,r){return D(this,e,t,!1,r)},u.prototype.writeDoubleLE=function(e,t,r){return F(this,e,t,!0,r)},u.prototype.writeDoubleBE=function(e,t,r){return F(this,e,t,!1,r)},u.prototype.copy=function(e,t,r,n){if(r||(r=0),n||0===n||(n=this.length),t>=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--i)e[i+t]=this[i+r];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"===typeof e)for(o=t;o55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&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 H(e){return n.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(L,"")).length<2)return"";for(;e.length%4!==0;)e+="=";return e}(e))}function q(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}}).call(this,r(44))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=c(r(2)),i=c(r(3)),o=c(r(7)),a=c(r(4)),s=c(r(5)),u=c(r(9)),l=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(0));function c(e){return e&&e.__esModule?e:{default:e}}var f=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);i>>2]>>>24-o%4*8&255;t[n+o>>>2]|=a<<24-(n+o)%4*8}else for(o=0;o>>2]=r[o>>>2];return this.sigBytes+=i,this},clamp:function(){var t=this.words,r=this.sigBytes;t[r>>>2]&=4294967295<<32-r%4*8,t.length=e.ceil(r/4)},clone:function(){var e=o.clone.call(this);return e.words=this.words.slice(0),e},random:function(t){for(var r,n=[],i=function(t){t=t;var r=987654321,n=4294967295;return function(){var i=((r=36969*(65535&r)+(r>>16)&n)<<16)+(t=18e3*(65535&t)+(t>>16)&n)&n;return i/=4294967296,(i+=.5)*(e.random()>.5?1:-1)}},o=0;o>>2]>>>24-i%4*8&255;n.push((o>>>4).toString(16)),n.push((15&o).toString(16))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>3]|=parseInt(e.substr(n,2),16)<<24-n%8*4;return new a.init(r,t/2)}},l=s.Latin1={stringify:function(e){for(var t=e.words,r=e.sigBytes,n=[],i=0;i>>2]>>>24-i%4*8&255;n.push(String.fromCharCode(o))}return n.join("")},parse:function(e){for(var t=e.length,r=[],n=0;n>>2]|=(255&e.charCodeAt(n))<<24-n%4*8;return new a.init(r,t)}},c=s.Utf8={stringify:function(e){try{return decodeURIComponent(escape(l.stringify(e)))}catch(t){throw new Error("Malformed UTF-8 data")}},parse:function(e){return l.parse(unescape(encodeURIComponent(e)))}},f=i.BufferedBlockAlgorithm=o.extend({reset:function(){this._data=new a.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=c.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var r=this._data,n=r.words,i=r.sigBytes,o=this.blockSize,s=i/(4*o),u=(s=t?e.ceil(s):e.max((0|s)-this._minBufferSize,0))*o,l=e.min(4*u,i);if(u){for(var c=0;c=0;l--)if(c[l]!==f[l])return!1;for(l=c.length-1;l>=0;l--)if(u=c[l],!y(e[u],t[u],r,n))return!1;return!0}(e,t,r,a))}return r?e===t:e==t}function b(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function w(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(r){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function _(e,t,r,n){var i;if("function"!==typeof t)throw new TypeError('"block" argument must be a function');"string"===typeof r&&(n=r,r=null),i=function(e){var t;try{e()}catch(r){t=r}return t}(t),n=(r&&r.name?" ("+r.name+").":".")+(n?" "+n:"."),e&&!i&&v(i,r,"Missing expected exception"+n);var a="string"===typeof n,s=!e&&i&&!r;if((!e&&o.isError(i)&&a&&w(i,r)||s)&&v(i,r,"Got unwanted exception"+n),e&&i&&r&&!w(i,r)||!e&&i)throw i}f.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return p(m(e.actual),128)+" "+e.operator+" "+p(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var r=new Error;if(r.stack){var n=r.stack,i=d(t),o=n.indexOf("\n"+i);if(o>=0){var a=n.indexOf("\n",o+1);n=n.substring(a+1)}this.stack=n}}},o.inherits(f.AssertionError,Error),f.fail=v,f.ok=g,f.equal=function(e,t,r){e!=t&&v(e,t,r,"==",f.equal)},f.notEqual=function(e,t,r){e==t&&v(e,t,r,"!=",f.notEqual)},f.deepEqual=function(e,t,r){y(e,t,!1)||v(e,t,r,"deepEqual",f.deepEqual)},f.deepStrictEqual=function(e,t,r){y(e,t,!0)||v(e,t,r,"deepStrictEqual",f.deepStrictEqual)},f.notDeepEqual=function(e,t,r){y(e,t,!1)&&v(e,t,r,"notDeepEqual",f.notDeepEqual)},f.notDeepStrictEqual=function e(t,r,n){y(t,r,!0)&&v(t,r,n,"notDeepStrictEqual",e)},f.strictEqual=function(e,t,r){e!==t&&v(e,t,r,"===",f.strictEqual)},f.notStrictEqual=function(e,t,r){e===t&&v(e,t,r,"!==",f.notStrictEqual)},f.throws=function(e,t,r){_(!0,e,t,r)},f.doesNotThrow=function(e,t,r){_(!1,e,t,r)},f.ifError=function(e){if(e)throw e};var C=Object.keys||function(e){var t=[];for(var r in e)a.call(e,r)&&t.push(r);return t}}).call(this,r(44))},function(e,t,r){var n=r(807),i=r(147),o=(r(148),r(831)),a=r(361),s=n({noether:"0",ta:"1",kta:"1000",Kta:"1000",babbage:"1000",femtoether:"1000",mta:"1000000",Mta:"1000000",lovelace:"1000000",picoether:"1000000",gta:"1000000000",Gta:"1000000000",shannon:"1000000000",nanosero:"1000000000",nano:"1000000000",szabo:"1000000000000",microsero:"1000000000000",micro:"1000000000000",finney:"1000000000000000",millisero:"1000000000000000",milli:"1000000000000000",sero:"1000000000000000000",SERO:"1000000000000000000",ksero:"1000000000000000000000",gsero:"1000000000000000000000",msero:"1000000000000000000000000"},"gsero","1000000000000000000000000000"),u=function(e,t){e=o.encode(e);for(var r="",n=0;n>>4).toString(16)),t.push((15&e[r]).toString(16));return"0x"+t.join("")},f=function(e){return a.encode(e)},h=function(e){return a.decode(e)},d=function(e){e=(e=e.toString(16)).replace(/^0x/i,"");for(var t=[],r=0;r0&&(i=n.getRangeAt(0)),document.body.append(t),t.select(),t.selectionStart=0,t.selectionEnd=e.length;var o=!1;try{o=document.execCommand("copy")}catch(a){}return t.remove(),i&&(n.removeAllRanges(),n.addRange(i)),r&&r.focus(),o};e.exports=n,e.exports.default=n},,function(e,t,r){"use strict";r(37),r(441)},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(n){"object"===typeof window&&(r=window)}e.exports=r},function(e,t,r){(function(e){!function(e,t){"use strict";function n(e,t){if(!e)throw new Error(t||"Assertion failed")}function i(e,t){e.super_=t;var r=function(){};r.prototype=t.prototype,e.prototype=new r,e.prototype.constructor=e}function o(e,t,r){if(o.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(r=t,t=10),this._init(e||0,t||10,r||"be"))}var a;"object"===typeof e?e.exports=o:t.BN=o,o.BN=o,o.wordSize=26;try{a=r(519).Buffer}catch(x){}function s(e,t,r){for(var n=0,i=Math.min(e.length,r),o=t;o=49&&a<=54?a-49+10:a>=17&&a<=22?a-17+10:15&a}return n}function u(e,t,r,n){for(var i=0,o=Math.min(e.length,r),a=t;a=49?s-49+10:s>=17?s-17+10:s}return i}o.isBN=function(e){return e instanceof o||null!==e&&"object"===typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&i++,16===t?this._parseHex(e,i):this._parseBase(e,t,i),"-"===e[0]&&(this.negative=1),this.strip(),"le"===r&&this._initArray(this.toArray(),t,r)},o.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):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},o.prototype._initArray=function(e,t,r){if(n("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 i=0;i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this.strip()},o.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r=t;r-=6)i=s(e,r,r+6),this.words[n]|=i<>>26-o&4194303,(o+=24)>=26&&(o-=26,n++);r+6!==t&&(i=s(e,t,r+6),this.words[n]|=i<>>26-o&4194303),this.strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},o.prototype.inspect=function(){return(this.red?""};var l=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],c=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],f=[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 h(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var l=1;l>>26,f=67108863&u,h=Math.min(l,t.length-1),d=Math.max(0,l-e.length+1);d<=h;d++){var p=l-d|0;c+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[l]=0|f,u=0|c}return 0!==u?r.words[l]=0|u:r.length--,r.strip()}o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?l[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var h=c[e],d=f[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modn(d).toString(e);r=(p=p.idivn(d)).isZero()?m+r:l[h-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.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]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16)},o.prototype.toBuffer=function(e,t){return n("undefined"!==typeof a),this.toArrayLike(a,e,t)},o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},o.prototype.toArrayLike=function(e,t,r){var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0"),this.strip();var a,s,u="le"===t,l=new e(o),c=this.clone();if(u){for(s=0;!c.isZero();s++)a=c.andln(255),c.iushrn(8),l[s]=a;for(;s=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.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},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this.strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.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;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,v=0|a[2],g=8191&v,y=v>>>13,b=0|a[3],w=8191&b,_=b>>>13,C=0|a[4],M=8191&C,x=C>>>13,E=0|a[5],S=8191&E,k=E>>>13,A=0|a[6],I=8191&A,O=A>>>13,P=0|a[7],T=8191&P,N=P>>>13,B=0|a[8],j=8191&B,R=B>>>13,D=0|a[9],F=8191&D,L=D>>>13,z=0|s[0],U=8191&z,H=z>>>13,q=0|s[1],V=8191&q,Q=q>>>13,K=0|s[2],W=8191&K,Y=K>>>13,G=0|s[3],X=8191&G,$=G>>>13,J=0|s[4],Z=8191&J,ee=J>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,le=se>>>13,ce=0|s[8],fe=8191&ce,he=ce>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ve=(l+(n=Math.imul(f,U))|0)+((8191&(i=(i=Math.imul(f,H))+Math.imul(h,U)|0))<<13)|0;l=((o=Math.imul(h,H))+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(p,U),i=(i=Math.imul(p,H))+Math.imul(m,U)|0,o=Math.imul(m,H);var ge=(l+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,Q)|0)+Math.imul(h,V)|0))<<13)|0;l=((o=o+Math.imul(h,Q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,U),i=(i=Math.imul(g,H))+Math.imul(y,U)|0,o=Math.imul(y,H),n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,Q)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,Q)|0;var ye=(l+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Y)|0)+Math.imul(h,W)|0))<<13)|0;l=((o=o+Math.imul(h,Y)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(w,U),i=(i=Math.imul(w,H))+Math.imul(_,U)|0,o=Math.imul(_,H),n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,Q)|0)+Math.imul(y,V)|0,o=o+Math.imul(y,Q)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Y)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Y)|0;var be=(l+(n=n+Math.imul(f,X)|0)|0)+((8191&(i=(i=i+Math.imul(f,$)|0)+Math.imul(h,X)|0))<<13)|0;l=((o=o+Math.imul(h,$)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(M,U),i=(i=Math.imul(M,H))+Math.imul(x,U)|0,o=Math.imul(x,H),n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,Q)|0)+Math.imul(_,V)|0,o=o+Math.imul(_,Q)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Y)|0)+Math.imul(y,W)|0,o=o+Math.imul(y,Y)|0,n=n+Math.imul(p,X)|0,i=(i=i+Math.imul(p,$)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,$)|0;var we=(l+(n=n+Math.imul(f,Z)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,Z)|0))<<13)|0;l=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(S,U),i=(i=Math.imul(S,H))+Math.imul(k,U)|0,o=Math.imul(k,H),n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,Q)|0)+Math.imul(x,V)|0,o=o+Math.imul(x,Q)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Y)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,Y)|0,n=n+Math.imul(g,X)|0,i=(i=i+Math.imul(g,$)|0)+Math.imul(y,X)|0,o=o+Math.imul(y,$)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,ee)|0;var _e=(l+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;l=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(I,U),i=(i=Math.imul(I,H))+Math.imul(O,U)|0,o=Math.imul(O,H),n=n+Math.imul(S,V)|0,i=(i=i+Math.imul(S,Q)|0)+Math.imul(k,V)|0,o=o+Math.imul(k,Q)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Y)|0)+Math.imul(x,W)|0,o=o+Math.imul(x,Y)|0,n=n+Math.imul(w,X)|0,i=(i=i+Math.imul(w,$)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,$)|0,n=n+Math.imul(g,Z)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(y,Z)|0,o=o+Math.imul(y,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Ce=(l+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;l=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(T,U),i=(i=Math.imul(T,H))+Math.imul(N,U)|0,o=Math.imul(N,H),n=n+Math.imul(I,V)|0,i=(i=i+Math.imul(I,Q)|0)+Math.imul(O,V)|0,o=o+Math.imul(O,Q)|0,n=n+Math.imul(S,W)|0,i=(i=i+Math.imul(S,Y)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,Y)|0,n=n+Math.imul(M,X)|0,i=(i=i+Math.imul(M,$)|0)+Math.imul(x,X)|0,o=o+Math.imul(x,$)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(y,re)|0,o=o+Math.imul(y,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var Me=(l+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,le)|0)+Math.imul(h,ue)|0))<<13)|0;l=((o=o+Math.imul(h,le)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(j,U),i=(i=Math.imul(j,H))+Math.imul(R,U)|0,o=Math.imul(R,H),n=n+Math.imul(T,V)|0,i=(i=i+Math.imul(T,Q)|0)+Math.imul(N,V)|0,o=o+Math.imul(N,Q)|0,n=n+Math.imul(I,W)|0,i=(i=i+Math.imul(I,Y)|0)+Math.imul(O,W)|0,o=o+Math.imul(O,Y)|0,n=n+Math.imul(S,X)|0,i=(i=i+Math.imul(S,$)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,$)|0,n=n+Math.imul(M,Z)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(x,Z)|0,o=o+Math.imul(x,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(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(y,oe)|0,o=o+Math.imul(y,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,le)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,le)|0;var xe=(l+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;l=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,U),i=(i=Math.imul(F,H))+Math.imul(L,U)|0,o=Math.imul(L,H),n=n+Math.imul(j,V)|0,i=(i=i+Math.imul(j,Q)|0)+Math.imul(R,V)|0,o=o+Math.imul(R,Q)|0,n=n+Math.imul(T,W)|0,i=(i=i+Math.imul(T,Y)|0)+Math.imul(N,W)|0,o=o+Math.imul(N,Y)|0,n=n+Math.imul(I,X)|0,i=(i=i+Math.imul(I,$)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,$)|0,n=n+Math.imul(S,Z)|0,i=(i=i+Math.imul(S,ee)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(x,re)|0,o=o+Math.imul(x,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,le)|0)+Math.imul(y,ue)|0,o=o+Math.imul(y,le)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var Ee=(l+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;l=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,Q))+Math.imul(L,V)|0,o=Math.imul(L,Q),n=n+Math.imul(j,W)|0,i=(i=i+Math.imul(j,Y)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,Y)|0,n=n+Math.imul(T,X)|0,i=(i=i+Math.imul(T,$)|0)+Math.imul(N,X)|0,o=o+Math.imul(N,$)|0,n=n+Math.imul(I,Z)|0,i=(i=i+Math.imul(I,ee)|0)+Math.imul(O,Z)|0,o=o+Math.imul(O,ee)|0,n=n+Math.imul(S,re)|0,i=(i=i+Math.imul(S,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(x,oe)|0,o=o+Math.imul(x,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,le)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,le)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(y,fe)|0,o=o+Math.imul(y,he)|0;var Se=(l+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;l=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Y))+Math.imul(L,W)|0,o=Math.imul(L,Y),n=n+Math.imul(j,X)|0,i=(i=i+Math.imul(j,$)|0)+Math.imul(R,X)|0,o=o+Math.imul(R,$)|0,n=n+Math.imul(T,Z)|0,i=(i=i+Math.imul(T,ee)|0)+Math.imul(N,Z)|0,o=o+Math.imul(N,ee)|0,n=n+Math.imul(I,re)|0,i=(i=i+Math.imul(I,ne)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ne)|0,n=n+Math.imul(S,oe)|0,i=(i=i+Math.imul(S,ae)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,le)|0)+Math.imul(x,ue)|0,o=o+Math.imul(x,le)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(_,fe)|0,o=o+Math.imul(_,he)|0;var ke=(l+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(y,pe)|0))<<13)|0;l=((o=o+Math.imul(y,me)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(F,X),i=(i=Math.imul(F,$))+Math.imul(L,X)|0,o=Math.imul(L,$),n=n+Math.imul(j,Z)|0,i=(i=i+Math.imul(j,ee)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,i=(i=i+Math.imul(T,ne)|0)+Math.imul(N,re)|0,o=o+Math.imul(N,ne)|0,n=n+Math.imul(I,oe)|0,i=(i=i+Math.imul(I,ae)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,ae)|0,n=n+Math.imul(S,ue)|0,i=(i=i+Math.imul(S,le)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,le)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(x,fe)|0,o=o+Math.imul(x,he)|0;var Ae=(l+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(_,pe)|0))<<13)|0;l=((o=o+Math.imul(_,me)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Z),i=(i=Math.imul(F,ee))+Math.imul(L,Z)|0,o=Math.imul(L,ee),n=n+Math.imul(j,re)|0,i=(i=i+Math.imul(j,ne)|0)+Math.imul(R,re)|0,o=o+Math.imul(R,ne)|0,n=n+Math.imul(T,oe)|0,i=(i=i+Math.imul(T,ae)|0)+Math.imul(N,oe)|0,o=o+Math.imul(N,ae)|0,n=n+Math.imul(I,ue)|0,i=(i=i+Math.imul(I,le)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,le)|0,n=n+Math.imul(S,fe)|0,i=(i=i+Math.imul(S,he)|0)+Math.imul(k,fe)|0,o=o+Math.imul(k,he)|0;var Ie=(l+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(x,pe)|0))<<13)|0;l=((o=o+Math.imul(x,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(L,re)|0,o=Math.imul(L,ne),n=n+Math.imul(j,oe)|0,i=(i=i+Math.imul(j,ae)|0)+Math.imul(R,oe)|0,o=o+Math.imul(R,ae)|0,n=n+Math.imul(T,ue)|0,i=(i=i+Math.imul(T,le)|0)+Math.imul(N,ue)|0,o=o+Math.imul(N,le)|0,n=n+Math.imul(I,fe)|0,i=(i=i+Math.imul(I,he)|0)+Math.imul(O,fe)|0,o=o+Math.imul(O,he)|0;var Oe=(l+(n=n+Math.imul(S,pe)|0)|0)+((8191&(i=(i=i+Math.imul(S,me)|0)+Math.imul(k,pe)|0))<<13)|0;l=((o=o+Math.imul(k,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(L,oe)|0,o=Math.imul(L,ae),n=n+Math.imul(j,ue)|0,i=(i=i+Math.imul(j,le)|0)+Math.imul(R,ue)|0,o=o+Math.imul(R,le)|0,n=n+Math.imul(T,fe)|0,i=(i=i+Math.imul(T,he)|0)+Math.imul(N,fe)|0,o=o+Math.imul(N,he)|0;var Pe=(l+(n=n+Math.imul(I,pe)|0)|0)+((8191&(i=(i=i+Math.imul(I,me)|0)+Math.imul(O,pe)|0))<<13)|0;l=((o=o+Math.imul(O,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,le))+Math.imul(L,ue)|0,o=Math.imul(L,le),n=n+Math.imul(j,fe)|0,i=(i=i+Math.imul(j,he)|0)+Math.imul(R,fe)|0,o=o+Math.imul(R,he)|0;var Te=(l+(n=n+Math.imul(T,pe)|0)|0)+((8191&(i=(i=i+Math.imul(T,me)|0)+Math.imul(N,pe)|0))<<13)|0;l=((o=o+Math.imul(N,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(L,fe)|0,o=Math.imul(L,he);var Ne=(l+(n=n+Math.imul(j,pe)|0)|0)+((8191&(i=(i=i+Math.imul(j,me)|0)+Math.imul(R,pe)|0))<<13)|0;l=((o=o+Math.imul(R,me)|0)+(i>>>13)|0)+(Ne>>>26)|0,Ne&=67108863;var Be=(l+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(L,pe)|0))<<13)|0;return l=((o=Math.imul(L,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ve,u[1]=ge,u[2]=ye,u[3]=be,u[4]=we,u[5]=_e,u[6]=Ce,u[7]=Me,u[8]=xe,u[9]=Ee,u[10]=Se,u[11]=ke,u[12]=Ae,u[13]=Ie,u[14]=Oe,u[15]=Pe,u[16]=Te,u[17]=Ne,u[18]=Be,0!==l&&(u[19]=l,r.length++),r};function p(e,t,r){return(new m).mulp(e,t,r)}function m(e,t){this.x=e,this.y=t}Math.imul||(d=h),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?d(this,e,t):r<63?h(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>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r.strip()}(this,e,t):p(this,e,t)},m.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},m.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,t+=i/67108864|0,t+=o>>>26,this.words[r]=67108863&o}return 0!==t&&(this.words[r]=t,this.length++),this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,l=0;l=0&&(0!==c||l>=i);l--){var f=0|this.words[l];this.words[l]=c<<26-o|f>>>o,c=f&s}return u&&0!==c&&(u.words[u.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(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 i=67108863^67108863>>>t<=67108864;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},o.prototype.isubn=function(e){if(n("number"===typeof e),n(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>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this.strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this.strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var l=0;l=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s.strip(),n.strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!==(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.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)},o.prototype.modn=function(e){n(e<=67108863);for(var t=(1<<26)%e,r=0,i=this.length-1;i>=0;i--)r=(t*r+(0|this.words[i]))%e;return r},o.prototype.idivn=function(e){n(e<=67108863);for(var t=0,r=this.length-1;r>=0;r--){var i=(0|this.words[r])+67108864*t;this.words[r]=i/e|0,t=i%e}return this.strip()},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),l=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++l;for(var c=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0===(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(c),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(c),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(l)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var l=0,c=1;0===(t.words[0]&c)&&l<26;++l,c<<=1);if(l>0)for(t.iushrn(l);l-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0===(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.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,r.negative=0;for(var n=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)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.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(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new C(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function g(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function y(){g.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function b(){g.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function w(){g.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function _(){g.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function C(e){if("string"===typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function M(e){C.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}g.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},g.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):r.strip(),r},g.prototype.split=function(e,t){e.iushrn(this.n,0,t)},g.prototype.imulK=function(e){return e.imul(this.k)},i(y,g),y.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,i=o}i>>>=22,e.words[n-10]=i,0===i&&e.length>10?e.length-=10:e.length-=9},y.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>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new y;else if("p224"===e)t=new b;else if("p192"===e)t=new w;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new _}return v[e]=t,t},C.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},C.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},C.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},C.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},C.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},C.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},C.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)},C.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},C.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},C.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},C.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},C.prototype.isqr=function(e){return this.imul(e,e.clone())},C.prototype.sqr=function(e){return this.mul(e,e)},C.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),l=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,l).cmp(u);)c.redIAdd(u);for(var f=this.pow(c,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,v=0;0!==m.cmp(s);v++)m=m.redSqr();n(v=0;n--){for(var l=t.words[n],c=u-1;c>=0;c--){var f=l>>c&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===c)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},C.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},C.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new M(e)},i(M,C),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 i.cmp(this.m)>=0?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 o(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),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},M.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(111)(e))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=Object.assign||function(e){for(var t=1;t=a)return e;switch(e){case"%s":return String(t[n++]);case"%d":return Number(t[n++]);case"%j":try{return JSON.stringify(t[n++])}catch(r){return"[Circular]"}break;default:return e}})),u=t[n];n1)for(var r=1;r3&&l<8?u=u.substr(0,3)+" "+u.substr(3):l>=8&&(u=u.substr(0,3)+" "+u.substr(3,4)+" "+u.substr(7));break;case"number":u=n.replace(/\D/g,"")}r.handleOnChange(u,u!==n,(function(){switch(s){case"bankCard":case"phone":case"number":try{var e=r.calcPos(i,a,n,u,[" "],/\D/g);("phone"===s&&(4===e||9===e)||"bankCard"===s&&e>0&&e%5===0)&&(e-=1),t.selectionStart=t.selectionEnd=e}catch(c){console.warn("Set selection error:",c)}}}))},r.handleOnChange=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:b,i=r.props.onChange;"value"in r.props?r.setState({value:r.props.value}):r.setState({value:e}),i?t?setTimeout((function(){i(e),n()})):(i(e),n()):n()},r.onInputFocus=function(e){r.debounceTimeout&&(clearTimeout(r.debounceTimeout),r.debounceTimeout=null),r.setState({focus:!0}),r.props.onFocus&&r.props.onFocus(e)},r.onInputBlur=function(e){r.inputRef&&(r.debounceTimeout=window.setTimeout((function(){document.activeElement!==(r.inputRef&&r.inputRef.inputRef)&&r.setState({focus:!1})}),200)),r.props.onBlur&&(setTimeout((function(){document.body&&(document.body.scrollTop=document.body.scrollTop)}),100),r.props.onBlur(e))},r.clearInput=function(){"password"!==r.props.type&&r.props.updatePlaceholder&&r.setState({placeholder:r.props.value}),r.setState({value:""}),r.props.onChange&&r.props.onChange(""),r.focus()},r.focus=function(){r.inputRef&&r.inputRef.focus()},r.calcPos=function(e,t,r,n,i,o){var a=r.length-t.length,s=e;if(a>0){var u=r.substr(s-a,a).replace(o,"").length;s-=a-u;for(var l=0;u>0;)-1===i.indexOf(n.charAt(s-u+l))?u--:l++;s+=l}return s},r.state={placeholder:e.placeholder,value:w(e.value||e.defaultValue)},r}return(0,u.default)(t,e),(0,a.default)(t,[{key:"componentWillReceiveProps",value:function(e){"placeholder"in e&&!e.updatePlaceholder&&this.setState({placeholder:e.placeholder}),"value"in e&&this.setState({value:e.value})}},{key:"componentWillUnmount",value:function(){this.debounceTimeout&&(window.clearTimeout(this.debounceTimeout),this.debounceTimeout=null)}},{key:"render",value:function(){var e,t,o=this,a=(0,i.default)({},this.props);delete a.updatePlaceholder;var s=a.prefixCls,u=a.prefixListCls,c=a.editable,v=a.style,g=a.clear,b=a.children,_=a.error,C=a.className,M=a.extra,x=a.labelNumber,E=a.type,S=a.onExtraClick,k=a.onErrorClick,A=a.moneyKeyboardAlign,I=a.moneyKeyboardWrapProps,O=a.moneyKeyboardHeader,P=a.onVirtualKeyboardConfirm,T=a.autoAdjustHeight,N=a.disabledKeys,B=y(a,["prefixCls","prefixListCls","editable","style","clear","children","error","className","extra","labelNumber","type","onExtraClick","onErrorClick","moneyKeyboardAlign","moneyKeyboardWrapProps","moneyKeyboardHeader","onVirtualKeyboardConfirm","autoAdjustHeight","disabledKeys"]),j=B.name,R=B.disabled,D=B.maxLength,F=this.state.value,L=(0,d.getComponentLocale)(this.props,this.context,"InputItem",(function(){return r(680)})),z=L.confirmLabel,U=L.backspaceLabel,H=L.cancelKeyboardLabel,q=this.state,V=q.focus,Q=q.placeholder,K=(0,l.default)(u+"-item",s+"-item",u+"-item-middle",C,(e={},(0,n.default)(e,s+"-disabled",R),(0,n.default)(e,s+"-error",_),(0,n.default)(e,s+"-focus",V),(0,n.default)(e,s+"-android",V),e)),W=(0,l.default)(s+"-label",(t={},(0,n.default)(t,s+"-label-2",2===x),(0,n.default)(t,s+"-label-3",3===x),(0,n.default)(t,s+"-label-4",4===x),(0,n.default)(t,s+"-label-5",5===x),(0,n.default)(t,s+"-label-6",6===x),(0,n.default)(t,s+"-label-7",7===x),t)),Y=s+"-control",G="text";"bankCard"===E||"phone"===E?G="tel":"password"===E?G="password":"digit"===E?G="number":"text"!==E&&"number"!==E&&(G=E);var X=void 0;"number"===E&&(X={pattern:"[0-9]*"});var $=void 0;return"digit"===E&&($={className:"h5numInput"}),f.createElement("div",{className:K},f.createElement("div",{className:u+"-line"},b?f.createElement("div",{className:W},b):null,f.createElement("div",{className:Y},"money"===E?f.createElement(p.default,{value:w(F),type:E,ref:function(e){return o.inputRef=e},maxLength:D,placeholder:Q,onChange:this.onInputChange,onFocus:this.onInputFocus,onBlur:this.onInputBlur,onVirtualKeyboardConfirm:P,disabled:R,editable:c,prefixCls:s,style:v,confirmLabel:z,backspaceLabel:U,cancelKeyboardLabel:H,moneyKeyboardAlign:A,moneyKeyboardWrapProps:I,moneyKeyboardHeader:O,autoAdjustHeight:T,disabledKeys:N}):f.createElement(m.default,(0,i.default)({},X,B,$,{value:w(F),defaultValue:void 0,ref:function(e){return o.inputRef=e},style:v,type:G,maxLength:D,name:j,placeholder:Q,onChange:this.onInputChange,onFocus:this.onInputFocus,onBlur:this.onInputBlur,readOnly:!c,disabled:R}))),g&&c&&!R&&F&&(""+F).length>0?f.createElement(h.default,{activeClassName:s+"-clear-active"},f.createElement("div",{className:s+"-clear",onClick:this.clearInput})):null,_?f.createElement("div",{className:s+"-error-extra",onClick:k}):null,""!==M?f.createElement("div",{className:s+"-extra",onClick:S},M):null))}}]),t}(f.Component);_.defaultProps={prefixCls:"am-input",prefixListCls:"am-list",type:"text",editable:!0,disabled:!1,placeholder:"",clear:!1,onChange:b,onBlur:b,onFocus:b,extra:"",onExtraClick:b,error:!1,onErrorClick:b,onVirtualKeyboardConfirm:b,labelNumber:5,updatePlaceholder:!1,moneyKeyboardAlign:"right",moneyKeyboardWrapProps:{},moneyKeyboardHeader:null,disabledKeys:null},_.contextTypes={antLocale:c.object},t.default=_,e.exports=t.default},function(e,t,r){"use strict";r(37),r(32),r(453)},function(e,t,r){"use strict";r(37),r(459)},function(e,t,r){!function(t,n){var i;e.exports=(i=r(34),void(i.lib.Cipher||function(e){var t=i,r=t.lib,n=r.Base,o=r.WordArray,a=r.BufferedBlockAlgorithm,s=t.enc,u=(s.Utf8,s.Base64),l=t.algo.EvpKDF,c=r.Cipher=a.extend({cfg:n.extend(),createEncryptor:function(e,t){return this.create(this._ENC_XFORM_MODE,e,t)},createDecryptor:function(e,t){return this.create(this._DEC_XFORM_MODE,e,t)},init:function(e,t,r){this.cfg=this.cfg.extend(r),this._xformMode=e,this._key=t,this.reset()},reset:function(){a.reset.call(this),this._doReset()},process:function(e){return this._append(e),this._process()},finalize:function(e){return e&&this._append(e),this._doFinalize()},keySize:4,ivSize:4,_ENC_XFORM_MODE:1,_DEC_XFORM_MODE:2,_createHelper:function(){function e(e){return"string"==typeof e?b:g}return function(t){return{encrypt:function(r,n,i){return e(n).encrypt(t,r,n,i)},decrypt:function(r,n,i){return e(n).decrypt(t,r,n,i)}}}}()}),f=(r.StreamCipher=c.extend({_doFinalize:function(){return this._process(!0)},blockSize:1}),t.mode={}),h=r.BlockCipherMode=n.extend({createEncryptor:function(e,t){return this.Encryptor.create(e,t)},createDecryptor:function(e,t){return this.Decryptor.create(e,t)},init:function(e,t){this._cipher=e,this._iv=t}}),d=f.CBC=function(){var t=h.extend();function r(t,r,n){var i=this._iv;if(i){var o=i;this._iv=e}else o=this._prevBlock;for(var a=0;a>>2];e.sigBytes-=t}},m=(r.BlockCipher=c.extend({cfg:c.cfg.extend({mode:d,padding:p}),reset:function(){c.reset.call(this);var e=this.cfg,t=e.iv,r=e.mode;if(this._xformMode==this._ENC_XFORM_MODE)var n=r.createEncryptor;else n=r.createDecryptor,this._minBufferSize=1;this._mode=n.call(r,this,t&&t.words)},_doProcessBlock:function(e,t){this._mode.processBlock(e,t)},_doFinalize:function(){var e=this.cfg.padding;if(this._xformMode==this._ENC_XFORM_MODE){e.pad(this._data,this.blockSize);var t=this._process(!0)}else t=this._process(!0),e.unpad(t);return t},blockSize:4}),r.CipherParams=n.extend({init:function(e){this.mixIn(e)},toString:function(e){return(e||this.formatter).stringify(this)}})),v=(t.format={}).OpenSSL={stringify:function(e){var t=e.ciphertext,r=e.salt;if(r)var n=o.create([1398893684,1701076831]).concat(r).concat(t);else n=t;return n.toString(u)},parse:function(e){var t=u.parse(e),r=t.words;if(1398893684==r[0]&&1701076831==r[1]){var n=o.create(r.slice(2,4));r.splice(0,4),t.sigBytes-=16}return m.create({ciphertext:t,salt:n})}},g=r.SerializableCipher=n.extend({cfg:n.extend({format:v}),encrypt:function(e,t,r,n){n=this.cfg.extend(n);var i=e.createEncryptor(r,n),o=i.finalize(t),a=i.cfg;return m.create({ciphertext:o,key:r,iv:a.iv,algorithm:e,mode:a.mode,padding:a.padding,blockSize:e.blockSize,formatter:n.format})},decrypt:function(e,t,r,n){return n=this.cfg.extend(n),t=this._parse(t,n.format),e.createDecryptor(r,n).finalize(t.ciphertext)},_parse:function(e,t){return"string"==typeof e?t.parse(e,this):e}}),y=(t.kdf={}).OpenSSL={execute:function(e,t,r,n){n||(n=o.random(8));var i=l.create({keySize:t+r}).compute(e,n),a=o.create(i.words.slice(t),4*r);return i.sigBytes=4*t,m.create({key:i,iv:a,salt:n})}},b=r.PasswordBasedCipher=g.extend({cfg:g.cfg.extend({kdf:y}),encrypt:function(e,t,r,n){var i=(n=this.cfg.extend(n)).kdf.execute(r,e.keySize,e.ivSize);n.iv=i.iv;var o=g.encrypt.call(this,e,t,i.key,n);return o.mixIn(i),o},decrypt:function(e,t,r,n){n=this.cfg.extend(n),t=this._parse(t,n.format);var i=n.kdf.execute(r,e.keySize,e.ivSize,t.salt);return n.iv=i.iv,g.decrypt.call(this,e,t,i.key,n)}})}()))}()},function(e,t,r){"use strict";var n=r(50);function i(e){return"/"===e.charAt(0)}function o(e,t){for(var r=t,n=r+1,i=e.length;n=0;h--){var d=a[h];"."===d?o(a,h):".."===d?(o(a,h),f++):f&&(o(a,h),f--)}if(!l)for(;f--;f)a.unshift("..");!l||""===a[0]||a[0]&&i(a[0])||a.unshift("");var p=a.join("/");return r&&"/"!==p.substr(-1)&&(p+="/"),p};function s(e){return e.valueOf?e.valueOf():Object.prototype.valueOf.call(e)}var u=function e(t,r){if(t===r)return!0;if(null==t||null==r)return!1;if(Array.isArray(t))return Array.isArray(r)&&t.length===r.length&&t.every((function(t,n){return e(t,r[n])}));if("object"===typeof t||"object"===typeof r){var n=s(t),i=s(r);return n!==t||i!==r?e(n,i):Object.keys(Object.assign({},t,r)).every((function(n){return e(t[n],r[n])}))}return!1},l=r(64);function c(e){return"/"===e.charAt(0)?e:"/"+e}function f(e){return"/"===e.charAt(0)?e.substr(1):e}function h(e,t){return function(e,t){return 0===e.toLowerCase().indexOf(t.toLowerCase())&&-1!=="/?#".indexOf(e.charAt(t.length))}(e,t)?e.substr(t.length):e}function d(e){return"/"===e.charAt(e.length-1)?e.slice(0,-1):e}function p(e){var t=e.pathname,r=e.search,n=e.hash,i=t||"/";return r&&"?"!==r&&(i+="?"===r.charAt(0)?r:"?"+r),n&&"#"!==n&&(i+="#"===n.charAt(0)?n:"#"+n),i}function m(e,t,r,i){var o;"string"===typeof e?(o=function(e){var t=e||"/",r="",n="",i=t.indexOf("#");-1!==i&&(n=t.substr(i),t=t.substr(0,i));var o=t.indexOf("?");return-1!==o&&(r=t.substr(o),t=t.substr(0,o)),{pathname:t,search:"?"===r?"":r,hash:"#"===n?"":n}}(e)).state=t:(void 0===(o=Object(n.a)({},e)).pathname&&(o.pathname=""),o.search?"?"!==o.search.charAt(0)&&(o.search="?"+o.search):o.search="",o.hash?"#"!==o.hash.charAt(0)&&(o.hash="#"+o.hash):o.hash="",void 0!==t&&void 0===o.state&&(o.state=t));try{o.pathname=decodeURI(o.pathname)}catch(s){throw s instanceof URIError?new URIError('Pathname "'+o.pathname+'" could not be decoded. This is likely caused by an invalid percent-encoding.'):s}return r&&(o.key=r),i?o.pathname?"/"!==o.pathname.charAt(0)&&(o.pathname=a(o.pathname,i.pathname)):o.pathname=i.pathname:o.pathname||(o.pathname="/"),o}function v(e,t){return e.pathname===t.pathname&&e.search===t.search&&e.hash===t.hash&&e.key===t.key&&u(e.state,t.state)}function g(){var e=null;var t=[];return{setPrompt:function(t){return e=t,function(){e===t&&(e=null)}},confirmTransitionTo:function(t,r,n,i){if(null!=e){var o="function"===typeof e?e(t,r):e;"string"===typeof o?"function"===typeof n?n(o,i):i(!0):i(!1!==o)}else i(!0)},appendListener:function(e){var r=!0;function n(){r&&e.apply(void 0,arguments)}return t.push(n),function(){r=!1,t=t.filter((function(e){return e!==n}))}},notifyListeners:function(){for(var e=arguments.length,r=new Array(e),n=0;nt?r.splice(t,r.length-t,n):r.push(n),f({action:"PUSH",location:n,index:t,entries:r})}}))},replace:function(e,t){var n=m(e,t,h(),w.location);c.confirmTransitionTo(n,"REPLACE",r,(function(e){e&&(w.entries[w.index]=n,f({action:"REPLACE",location:n}))}))},go:b,goBack:function(){b(-1)},goForward:function(){b(1)},canGo:function(e){var t=w.index+e;return t>=0&&t=0||Object.prototype.hasOwnProperty.call(e,n)&&(r[n]=e[n]);return r}},function(e,t,r){"use strict";var n=r(2),i=r.n(n),o=r(8),a=r.n(o),s=r(3),u=r.n(s),l=r(7),c=r.n(l),f=r(4),h=r.n(f),d=r(5),p=r.n(d),m=r(0),v=r.n(m),g=r(6),y=r.n(g);function b(e){var t=[];return v.a.Children.forEach(e,(function(e){t.push(e)})),t}function w(e,t){var r=null;return e&&e.forEach((function(e){r||e&&e.key===t&&(r=e)})),r}function _(e,t,r){var n=null;return e&&e.forEach((function(e){if(e&&e.key===t&&e.props[r]){if(n)throw new Error("two child with same key for children");n=e}})),n}var C=r(21),M=r.n(C),x=r(153),E={isAppearSupported:function(e){return e.transitionName&&e.transitionAppear||e.animation.appear},isEnterSupported:function(e){return e.transitionName&&e.transitionEnter||e.animation.enter},isLeaveSupported:function(e){return e.transitionName&&e.transitionLeave||e.animation.leave},allowAppearCallback:function(e){return e.transitionAppear||e.animation.appear},allowEnterCallback:function(e){return e.transitionEnter||e.animation.enter},allowLeaveCallback:function(e){return e.transitionLeave||e.animation.leave}},S={enter:"transitionEnter",appear:"transitionAppear",leave:"transitionLeave"},k=function(e){function t(){return u()(this,t),h()(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return p()(t,e),c()(t,[{key:"componentWillUnmount",value:function(){this.stop()}},{key:"componentWillEnter",value:function(e){E.isEnterSupported(this.props)?this.transition("enter",e):e()}},{key:"componentWillAppear",value:function(e){E.isAppearSupported(this.props)?this.transition("appear",e):e()}},{key:"componentWillLeave",value:function(e){E.isLeaveSupported(this.props)?this.transition("leave",e):e()}},{key:"transition",value:function(e,t){var r=this,n=M.a.findDOMNode(this),i=this.props,o=i.transitionName,a="object"===typeof o;this.stop();var s=function(){r.stopper=null,t()};if((x.b||!i.animation[e])&&o&&i[S[e]]){var u=a?o[e]:o+"-"+e,l=u+"-active";a&&o[e+"Active"]&&(l=o[e+"Active"]),this.stopper=Object(x.a)(n,{name:u,active:l},s)}else this.stopper=i.animation[e](n,s)}},{key:"stop",value:function(){var e=this.stopper;e&&(this.stopper=null,e.stop())}},{key:"render",value:function(){return this.props.children}}]),t}(v.a.Component);k.propTypes={children:y.a.any,animation:y.a.any,transitionName:y.a.any};var A=k,I="rc_animate_"+Date.now();function O(e){var t=e.children;return v.a.isValidElement(t)&&!t.key?v.a.cloneElement(t,{key:I}):t}function P(){}var T=function(e){function t(e){u()(this,t);var r=h()(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return N.call(r),r.currentlyAnimatingKeys={},r.keysToEnter=[],r.keysToLeave=[],r.state={children:b(O(e))},r.childrenRefs={},r}return p()(t,e),c()(t,[{key:"componentDidMount",value:function(){var e=this,t=this.props.showProp,r=this.state.children;t&&(r=r.filter((function(e){return!!e.props[t]}))),r.forEach((function(t){t&&e.performAppear(t.key)}))}},{key:"componentWillReceiveProps",value:function(e){var t=this;this.nextProps=e;var r=b(O(e)),n=this.props;n.exclusive&&Object.keys(this.currentlyAnimatingKeys).forEach((function(e){t.stop(e)}));var i=n.showProp,o=this.currentlyAnimatingKeys,s=n.exclusive?b(O(n)):this.state.children,u=[];i?(s.forEach((function(e){var t=e&&w(r,e.key),n=void 0;(n=t&&t.props[i]||!e.props[i]?t:v.a.cloneElement(t||e,a()({},i,!0)))&&u.push(n)})),r.forEach((function(e){e&&w(s,e.key)||u.push(e)}))):u=function(e,t){var r=[],n={},i=[];return e.forEach((function(e){e&&w(t,e.key)?i.length&&(n[e.key]=i,i=[]):i.push(e)})),t.forEach((function(e){e&&Object.prototype.hasOwnProperty.call(n,e.key)&&(r=r.concat(n[e.key])),r.push(e)})),r=r.concat(i)}(s,r),this.setState({children:u}),r.forEach((function(e){var r=e&&e.key;if(!e||!o[r]){var n=e&&w(s,r);if(i){var a=e.props[i];if(n)!_(s,r,i)&&a&&t.keysToEnter.push(r);else a&&t.keysToEnter.push(r)}else n||t.keysToEnter.push(r)}})),s.forEach((function(e){var n=e&&e.key;if(!e||!o[n]){var a=e&&w(r,n);if(i){var s=e.props[i];if(a)!_(r,n,i)&&s&&t.keysToLeave.push(n);else s&&t.keysToLeave.push(n)}else a||t.keysToLeave.push(n)}}))}},{key:"componentDidUpdate",value:function(){var e=this.keysToEnter;this.keysToEnter=[],e.forEach(this.performEnter);var t=this.keysToLeave;this.keysToLeave=[],t.forEach(this.performLeave)}},{key:"isValidChildByKey",value:function(e,t){var r=this.props.showProp;return r?_(e,t,r):w(e,t)}},{key:"stop",value:function(e){delete this.currentlyAnimatingKeys[e];var t=this.childrenRefs[e];t&&t.stop()}},{key:"render",value:function(){var e=this,t=this.props;this.nextProps=t;var r=this.state.children,n=null;r&&(n=r.map((function(r){if(null===r||void 0===r)return r;if(!r.key)throw new Error("must set key for children");return v.a.createElement(A,{key:r.key,ref:function(t){e.childrenRefs[r.key]=t},animation:t.animation,transitionName:t.transitionName,transitionEnter:t.transitionEnter,transitionAppear:t.transitionAppear,transitionLeave:t.transitionLeave},r)})));var o=t.component;if(o){var a=t;return"string"===typeof o&&(a=i()({className:t.className,style:t.style},t.componentProps)),v.a.createElement(o,a,n)}return n[0]||null}}]),t}(v.a.Component);T.isAnimate=!0,T.propTypes={className:y.a.string,style:y.a.object,component:y.a.any,componentProps:y.a.object,animation:y.a.object,transitionName:y.a.oneOfType([y.a.string,y.a.object]),transitionEnter:y.a.bool,transitionAppear:y.a.bool,exclusive:y.a.bool,transitionLeave:y.a.bool,onEnd:y.a.func,onEnter:y.a.func,onLeave:y.a.func,onAppear:y.a.func,showProp:y.a.string,children:y.a.node},T.defaultProps={animation:{},component:"span",componentProps:{},transitionEnter:!0,transitionLeave:!0,transitionAppear:!1,onEnd:P,onEnter:P,onLeave:P,onAppear:P};var N=function(){var e=this;this.performEnter=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillEnter(e.handleDoneAdding.bind(e,t,"enter")))},this.performAppear=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillAppear(e.handleDoneAdding.bind(e,t,"appear")))},this.handleDoneAdding=function(t,r){var n=e.props;if(delete e.currentlyAnimatingKeys[t],!n.exclusive||n===e.nextProps){var i=b(O(n));e.isValidChildByKey(i,t)?"appear"===r?E.allowAppearCallback(n)&&(n.onAppear(t),n.onEnd(t,!0)):E.allowEnterCallback(n)&&(n.onEnter(t),n.onEnd(t,!0)):e.performLeave(t)}},this.performLeave=function(t){e.childrenRefs[t]&&(e.currentlyAnimatingKeys[t]=!0,e.childrenRefs[t].componentWillLeave(e.handleDoneLeaving.bind(e,t)))},this.handleDoneLeaving=function(t){var r=e.props;if(delete e.currentlyAnimatingKeys[t],!r.exclusive||r===e.nextProps){var n=b(O(r));if(e.isValidChildByKey(n,t))e.performEnter(t);else{var i=function(){E.allowLeaveCallback(r)&&(r.onLeave(t),r.onEnd(t,!1))};!function(e,t,r){var n=e.length===t.length;return n&&e.forEach((function(e,i){var o=t[i];e&&o&&(e&&!o||!e&&o?n=!1:e.key!==o.key?n=!1:r&&e.props[r]!==o.props[r]&&(n=!1))})),n}(e.state.children,n,r.showProp)?e.setState({children:n},i):i()}}}};t.a=T},function(e,t){var r=e.exports={version:"2.6.9"};"number"==typeof __e&&(__e=r)},,function(e,t,r){"use strict";var n=r(341),i=r(656),o=Object.prototype.toString;function a(e){return"[object Array]"===o.call(e)}function s(e){return null!==e&&"object"===typeof e}function u(e){return"[object Function]"===o.call(e)}function l(e,t){if(null!==e&&"undefined"!==typeof e)if("object"!==typeof e&&(e=[e]),a(e))for(var r=0,n=e.length;r=0;){var o;if(i.isOdd()){var a=i.andln(n-1);o=a>(n>>1)-1?(n>>1)-a:a,i.isubn(o)}else o=0;r.push(o);for(var s=0!==i.cmpn(0)&&0===i.andln(n-1)?t+1:1,u=1;u0||t.cmpn(-i)>0;){var o,a,s,u=e.andln(3)+n&3,l=t.andln(3)+i&3;if(3===u&&(u=-1),3===l&&(l=-1),0===(1&u))o=0;else o=3!==(s=e.andln(7)+n&7)&&5!==s||2!==l?u:-u;if(r[0].push(o),0===(1&l))a=0;else a=3!==(s=t.andln(7)+i&7)&&5!==s||2!==u?l:-l;r[1].push(a),2*n===o+1&&(n=1-n),2*i===a+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")}},function(e,t,r){"use strict";r(37),r(673)},function(e,t,r){"use strict";var n=r(59),i=r.n(n),o=r(8),a=r.n(o),s=r(2),u=r.n(s),l=r(70),c=r.n(l),f=r(0),h=r.n(f),d=r(377),p=r.n(d),m=r(378),v=r.n(m),g=r(245),y=r.n(g),b=r(185),w=r.n(b),_=r(65),C=r.n(_),M=r(177),x=r.n(M),E=r(3),S=r.n(E),k=r(7),A=r.n(k),I=function e(t){S()(this,e),u()(this,t)};function O(e){return e instanceof I}function P(e){return O(e)?e:new I(e)}var T=r(179),N=r.n(T);function B(e){return e}function j(e,t,r){var n={};return function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments[1],n=arguments[2],i=arguments[3],o=arguments[4];if(n(t,r))o(t,r);else if(void 0===r||null===r);else if(Array.isArray(r))r.forEach((function(r,a){return e(t+"["+a+"]",r,n,i,o)}));else{if("object"!==typeof r)return void y()(!1,i);Object.keys(r).forEach((function(a){var s=r[a];e(t+(t?".":"")+a,s,n,i,o)}))}}(void 0,e,t,r,(function(e,t){n[e]=t})),n}function R(e,t,r){var n=e.map((function(e){var t=u()({},e,{trigger:e.trigger||[]});return"string"===typeof t.trigger&&(t.trigger=[t.trigger]),t}));return t&&n.push({trigger:r?[].concat(r):[],rules:t}),n}function D(e){return e.filter((function(e){return!!e.rules&&e.rules.length})).map((function(e){return e.trigger})).reduce((function(e,t){return e.concat(t)}),[])}function F(e){if(!e||!e.target)return e;var t=e.target;return"checkbox"===t.type?t.checked:t.value}function L(e,t,r){var n=e,i=t,o=r;return void 0===r&&("function"===typeof n?(o=n,i={},n=void 0):Array.isArray(n)?"function"===typeof i?(o=i,i={}):i=i||{}:(o=i,i=n||{},n=void 0)),{names:n,options:i,callback:o}}function z(e){return 0===Object.keys(e).length}function U(e){return!!e&&e.some((function(e){return e.rules&&e.rules.length}))}function H(e,t){return 0===t.indexOf(e)&&-1!==[".","["].indexOf(t[e.length])}function q(e){return j(e,(function(e,t){return O(t)}),"You must wrap field data with `createFormField`.")}var V=function(){function e(t){S()(this,e),Q.call(this),this.fields=q(t),this.fieldsMeta={}}return A()(e,[{key:"updateFields",value:function(e){this.fields=q(e)}},{key:"flattenRegisteredFields",value:function(e){var t=this.getAllFieldsName();return j(e,(function(e){return t.indexOf(e)>=0}),"You cannot set a form field before rendering a field associated with the value.")}},{key:"setFields",value:function(e){var t=this,r=this.fieldsMeta,n=u()({},this.fields,e),i={};Object.keys(r).forEach((function(e){i[e]=t.getValueFromFields(e,n)})),Object.keys(i).forEach((function(e){var r=i[e],o=t.getFieldMeta(e);if(o&&o.normalize){var a=o.normalize(r,t.getValueFromFields(e,t.fields),i);a!==r&&(n[e]=u()({},n[e],{value:a}))}})),this.fields=n}},{key:"resetFields",value:function(e){var t=this.fields;return(e?this.getValidFieldsFullName(e):this.getAllFieldsName()).reduce((function(e,r){var n=t[r];return n&&"value"in n&&(e[r]={}),e}),{})}},{key:"setFieldMeta",value:function(e,t){this.fieldsMeta[e]=t}},{key:"setFieldsAsDirty",value:function(){var e=this;Object.keys(this.fields).forEach((function(t){var r=e.fields[t],n=e.fieldsMeta[t];r&&n&&U(n.validate)&&(e.fields[t]=u()({},r,{dirty:!0}))}))}},{key:"getFieldMeta",value:function(e){return this.fieldsMeta[e]=this.fieldsMeta[e]||{},this.fieldsMeta[e]}},{key:"getValueFromFields",value:function(e,t){var r=t[e];if(r&&"value"in r)return r.value;var n=this.getFieldMeta(e);return n&&n.initialValue}},{key:"getValidFieldsName",value:function(){var e=this,t=this.fieldsMeta;return t?Object.keys(t).filter((function(t){return!e.getFieldMeta(t).hidden})):[]}},{key:"getAllFieldsName",value:function(){var e=this.fieldsMeta;return e?Object.keys(e):[]}},{key:"getValidFieldsFullName",value:function(e){var t=Array.isArray(e)?e:[e];return this.getValidFieldsName().filter((function(e){return t.some((function(t){return e===t||(r=t,0===e.lastIndexOf(r,0)&&[".","["].indexOf(e[t.length])>=0);var r}))}))}},{key:"getFieldValuePropValue",value:function(e){var t=e.name,r=e.getValueProps,n=e.valuePropName,i=this.getField(t),o="value"in i?i.value:e.initialValue;return r?r(o):a()({},n,o)}},{key:"getField",value:function(e){return u()({},this.fields[e],{name:e})}},{key:"getNotCollectedFields",value:function(){var e=this;return this.getValidFieldsName().filter((function(t){return!e.fields[t]})).map((function(t){return{name:t,dirty:!1,value:e.getFieldMeta(t).initialValue}})).reduce((function(e,t){return C()(e,t.name,P(t))}),{})}},{key:"getNestedAllFields",value:function(){var e=this;return Object.keys(this.fields).reduce((function(t,r){return C()(t,r,P(e.fields[r]))}),this.getNotCollectedFields())}},{key:"getFieldMember",value:function(e,t){return this.getField(e)[t]}},{key:"getNestedFields",value:function(e,t){return(e||this.getValidFieldsName()).reduce((function(e,r){return C()(e,r,t(r))}),{})}},{key:"getNestedField",value:function(e,t){var r=this.getValidFieldsFullName(e);if(0===r.length||1===r.length&&r[0]===e)return t(e);var n="["===r[0][e.length],i=n?e.length:e.length+1;return r.reduce((function(e,r){return C()(e,r.slice(i),t(r))}),n?[]:{})}},{key:"isValidNestedFieldName",value:function(e){return this.getAllFieldsName().every((function(t){return!H(t,e)&&!H(e,t)}))}},{key:"clearField",value:function(e){delete this.fields[e],delete this.fieldsMeta[e]}}]),e}(),Q=function(){var e=this;this.setFieldsInitialValue=function(t){var r=e.flattenRegisteredFields(t),n=e.fieldsMeta;Object.keys(r).forEach((function(t){n[t]&&e.setFieldMeta(t,u()({},e.getFieldMeta(t),{initialValue:r[t]}))}))},this.getAllValues=function(){var t=e.fieldsMeta,r=e.fields;return Object.keys(t).reduce((function(t,n){return C()(t,n,e.getValueFromFields(n,r))}),{})},this.getFieldsValue=function(t){return e.getNestedFields(t,e.getFieldValue)},this.getFieldValue=function(t){var r=e.fields;return e.getNestedField(t,(function(t){return e.getValueFromFields(t,r)}))},this.getFieldsError=function(t){return e.getNestedFields(t,e.getFieldError)},this.getFieldError=function(t){return e.getNestedField(t,(function(t){return(r=e.getFieldMember(t,"errors"))?r.map((function(e){return e&&e.message?e.message:e})):r;var r}))},this.isFieldValidating=function(t){return e.getFieldMember(t,"validating")},this.isFieldsValidating=function(t){return(t||e.getValidFieldsName()).some((function(t){return e.isFieldValidating(t)}))},this.isFieldTouched=function(t){return e.getFieldMember(t,"touched")},this.isFieldsTouched=function(t){return(t||e.getValidFieldsName()).some((function(t){return e.isFieldTouched(t)}))}};var K="onChange";var W=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=e.validateMessages,n=e.onFieldsChange,o=e.onValuesChange,s=e.mapProps,l=void 0===s?B:s,f=e.mapPropsToFields,d=e.fieldNameProp,m=e.fieldMetaProp,g=e.fieldDataProp,y=e.formPropName,b=void 0===y?"form":y,_=e.name,M=e.withRef;return function(e){return function(e,t){return e.displayName="Form("+function(e){return e.displayName||e.name||"WrappedComponent"}(t)+")",e.WrappedComponent=t,N()(e,t)}(p()({displayName:"Form",mixins:t,getInitialState:function(){var e=this,t=f&&f(this.props);return this.fieldsStore=function(e){return new V(e)}(t||{}),this.instances={},this.cachedBind={},this.clearedFieldMetaCache={},this.renderFields={},this.domFields={},["getFieldsValue","getFieldValue","setFieldsInitialValue","getFieldsError","getFieldError","isFieldValidating","isFieldsValidating","isFieldsTouched","isFieldTouched"].forEach((function(t){e[t]=function(){var r;return(r=e.fieldsStore)[t].apply(r,arguments)}})),{submitting:!1}},componentDidMount:function(){this.cleanUpUselessFields()},componentWillReceiveProps:function(e){f&&this.fieldsStore.updateFields(f(e))},componentDidUpdate:function(){this.cleanUpUselessFields()},onCollectCommon:function(e,t,r){var n=this.fieldsStore.getFieldMeta(e);if(n[t])n[t].apply(n,c()(r));else if(n.originalProps&&n.originalProps[t]){var i;(i=n.originalProps)[t].apply(i,c()(r))}var s=n.getValueFromEvent?n.getValueFromEvent.apply(n,c()(r)):F.apply(void 0,c()(r));if(o&&s!==this.fieldsStore.getFieldValue(e)){var l=this.fieldsStore.getAllValues(),f={};l[e]=s,Object.keys(l).forEach((function(e){return C()(f,e,l[e])})),o(u()(a()({},b,this.getForm()),this.props),C()({},e,s),f)}var h=this.fieldsStore.getField(e);return{name:e,field:u()({},h,{value:s,touched:!0}),fieldMeta:n}},onCollect:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),i=2;i2?r-2:0),i=2;i1&&void 0!==arguments[1]?arguments[1]:{};if(!e)throw new Error("Must call `getFieldProps` with valid name string!");delete this.clearedFieldMetaCache[e];var n=u()({name:e,trigger:K,valuePropName:"value",validate:[]},r),i=n.rules,o=n.trigger,a=n.validateTrigger,s=void 0===a?o:a,l=n.validate,c=this.fieldsStore.getFieldMeta(e);"initialValue"in n&&(c.initialValue=n.initialValue);var f=u()({},this.fieldsStore.getFieldValuePropValue(n),{ref:this.getCacheBind(e,e+"__ref",this.saveRef)});d&&(f[d]=_?_+"_"+e:e);var h=R(l,i,s),p=D(h);p.forEach((function(r){f[r]||(f[r]=t.getCacheBind(e,r,t.onCollectValidate))})),o&&-1===p.indexOf(o)&&(f[o]=this.getCacheBind(e,o,this.onCollect));var v=u()({},c,n,{validate:h});return this.fieldsStore.setFieldMeta(e,v),m&&(f[m]=v),g&&(f[g]=this.fieldsStore.getField(e)),this.renderFields[e]=!0,f},getFieldInstance:function(e){return this.instances[e]},getRules:function(e,t){var r,n=e.validate.filter((function(e){return!t||e.trigger.indexOf(t)>=0})).map((function(e){return e.rules}));return r=n,Array.prototype.concat.apply([],r)},setFields:function(e,t){var r=this,i=this.fieldsStore.flattenRegisteredFields(e);if(this.fieldsStore.setFields(i),n){var o=Object.keys(i).reduce((function(e,t){return C()(e,t,r.fieldsStore.getField(t))}),{});n(u()(a()({},b,this.getForm()),this.props),o,this.fieldsStore.getNestedAllFields())}this.forceUpdate(t)},setFieldsValue:function(e,t){var r=this.fieldsStore.fieldsMeta,n=this.fieldsStore.flattenRegisteredFields(e),i=Object.keys(n).reduce((function(e,t){if(r[t]){var i=n[t];e[t]={value:i}}return e}),{});if(this.setFields(i,t),o){var s=this.fieldsStore.getAllValues();o(u()(a()({},b,this.getForm()),this.props),e,s)}},saveRef:function(e,t,r){if(!r){var n=this.fieldsStore.getFieldMeta(e);return n.preserve||(this.clearedFieldMetaCache[e]={field:this.fieldsStore.getField(e),meta:n},this.clearField(e)),void delete this.domFields[e]}this.domFields[e]=!0,this.recoverClearedField(e);var i=this.fieldsStore.getFieldMeta(e);if(i){var o=i.ref;if(o){if("string"===typeof o)throw new Error("can not set ref string for "+e);"function"===typeof o?o(r):Object.prototype.hasOwnProperty.call(o,"current")&&(o.current=r)}}this.instances[e]=r},cleanUpUselessFields:function(){var e=this,t=this.fieldsStore.getAllFieldsName().filter((function(t){var r=e.fieldsStore.getFieldMeta(t);return!e.renderFields[t]&&!e.domFields[t]&&!r.preserve}));t.length&&t.forEach(this.clearField),this.renderFields={}},clearField:function(e){this.fieldsStore.clearField(e),delete this.instances[e],delete this.cachedBind[e]},resetFields:function(e){var t=this,r=this.fieldsStore.resetFields(e);(Object.keys(r).length>0&&this.setFields(r),e)?(Array.isArray(e)?e:[e]).forEach((function(e){return delete t.clearedFieldMetaCache[e]})):this.clearedFieldMetaCache={}},recoverClearedField:function(e){this.clearedFieldMetaCache[e]&&(this.fieldsStore.setFields(a()({},e,this.clearedFieldMetaCache[e].field)),this.fieldsStore.setFieldMeta(e,this.clearedFieldMetaCache[e].meta),delete this.clearedFieldMetaCache[e])},validateFieldsInternal:function(e,t,n){var i=this,o=t.fieldNames,a=t.action,s=t.options,l=void 0===s?{}:s,c={},f={},h={},d={};if(e.forEach((function(e){var t=e.name;if(!0===l.force||!1!==e.dirty){var r=i.fieldsStore.getFieldMeta(t),n=u()({},e);n.errors=void 0,n.validating=!0,n.dirty=!0,c[t]=i.getRules(r,a),f[t]=n.value,h[t]=n}else e.errors&&C()(d,t,{errors:e.errors})})),this.setFields(h),Object.keys(f).forEach((function(e){f[e]=i.fieldsStore.getFieldValue(e)})),n&&z(h))n(z(d)?null:d,this.fieldsStore.getFieldsValue(o));else{var p=new v.a(c);r&&p.messages(r),p.validate(f,l,(function(e){var t=u()({},d);e&&e.length&&e.forEach((function(e){var r=e.field,n=r;Object.keys(c).some((function(e){var t=c[e]||[];if(e===r)return n=e,!0;if(t.every((function(e){return"array"!==e.type}))&&0!==r.indexOf(e))return!1;var i=r.slice(e.length+1);return!!/^\d+$/.test(i)&&(n=e,!0)}));var i=w()(t,n);("object"!==typeof i||Array.isArray(i))&&C()(t,n,{errors:[]}),w()(t,n.concat(".errors")).push(e)}));var r=[],a={};Object.keys(c).forEach((function(e){var n=w()(t,e),o=i.fieldsStore.getField(e);x()(o.value,f[e])?(o.errors=n&&n.errors,o.value=f[e],o.validating=!1,o.dirty=!1,a[e]=o):r.push({name:e})})),i.setFields(a),n&&(r.length&&r.forEach((function(e){var r=e.name,n=[{message:r+" need to revalidate",field:r}];C()(t,r,{expired:!0,errors:n})})),n(z(t)?null:t,i.fieldsStore.getFieldsValue(o)))}))}},validateFields:function(e,t,r){var n=this,i=new Promise((function(i,o){var a=L(e,t,r),s=a.names,u=a.options,l=L(e,t,r).callback;if(!l||"function"===typeof l){var c=l;l=function(e,t){c&&c(e,t),e?o({errors:e,values:t}):i(t)}}var f=s?n.fieldsStore.getValidFieldsFullName(s):n.fieldsStore.getValidFieldsName(),h=f.filter((function(e){return U(n.fieldsStore.getFieldMeta(e).validate)})).map((function(e){var t=n.fieldsStore.getField(e);return t.value=n.fieldsStore.getFieldValue(e),t}));h.length?("firstFields"in u||(u.firstFields=f.filter((function(e){return!!n.fieldsStore.getFieldMeta(e).validateFirst}))),n.validateFieldsInternal(h,{fieldNames:f,options:u},l)):l(null,n.fieldsStore.getFieldsValue(f))}));return i.catch((function(e){return console.error,e})),i},isSubmitting:function(){return this.state.submitting},submit:function(e){var t=this;this.setState({submitting:!0}),e((function(){t.setState({submitting:!1})}))},render:function(){var t=this.props,r=t.wrappedComponentRef,n=i()(t,["wrappedComponentRef"]),o=a()({},b,this.getForm());M?o.ref="wrappedComponent":r&&(o.ref=r);var s=l.call(this,u()({},o,n));return h.a.createElement(e,s)}}),e)}},Y={getForm:function(){return{getFieldsValue:this.fieldsStore.getFieldsValue,getFieldValue:this.fieldsStore.getFieldValue,getFieldInstance:this.getFieldInstance,setFieldsValue:this.setFieldsValue,setFields:this.setFields,setFieldsInitialValue:this.fieldsStore.setFieldsInitialValue,getFieldDecorator:this.getFieldDecorator,getFieldProps:this.getFieldProps,getFieldsError:this.fieldsStore.getFieldsError,getFieldError:this.fieldsStore.getFieldError,isFieldValidating:this.fieldsStore.isFieldValidating,isFieldsValidating:this.fieldsStore.isFieldsValidating,isFieldsTouched:this.fieldsStore.isFieldsTouched,isFieldTouched:this.fieldsStore.isFieldTouched,isSubmitting:this.isSubmitting,submit:this.submit,validateFields:this.validateFields,resetFields:this.resetFields}}};var G=function(e){return W(e,[Y])},X=r(6),$=r.n(X);$.a.shape({getFieldsValue:$.a.func,getFieldValue:$.a.func,getFieldInstance:$.a.func,setFieldsValue:$.a.func,setFields:$.a.func,setFieldsInitialValue:$.a.func,getFieldDecorator:$.a.func,getFieldProps:$.a.func,getFieldsError:$.a.func,getFieldError:$.a.func,isFieldValidating:$.a.func,isFieldsValidating:$.a.func,isFieldsTouched:$.a.func,isFieldTouched:$.a.func,isSubmitting:$.a.func,submit:$.a.func,validateFields:$.a.func,resetFields:$.a.func});r.d(t,"a",(function(){return G}))},function(e,t,r){"use strict";t.__esModule=!0;var n,i=r(681),o=(n=i)&&n.__esModule?n:{default:n};t.default=function(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t0&&this.props.rows>1,I=(0,l.default)(y,s+"-item",a+"-item",(e={},(0,i.default)(e,a+"-disabled",x),(0,i.default)(e,a+"-item-single-line",1===this.props.rows&&!C),(0,i.default)(e,a+"-error",g),(0,i.default)(e,a+"-focus",k),(0,i.default)(e,a+"-has-count",A),e)),O=(0,l.default)(a+"-label",(t={},(0,i.default)(t,a+"-label-2",2===w),(0,i.default)(t,a+"-label-3",3===w),(0,i.default)(t,a+"-label-4",4===w),(0,i.default)(t,a+"-label-5",5===w),(0,i.default)(t,a+"-label-6",6===w),(0,i.default)(t,a+"-label-7",7===w),t)),P=function(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").replace(v,"_").length}(S),T={};if(b>0)if(h.IS_IOS){var N=S?S.replace(v,"_"):"",B=N?N.split("_").length-1:0;T.maxLength=b+B-P+(S?S.length:0)}else T.maxLength=b-P+(S?S.length:0);return c.createElement("div",{className:I},_&&c.createElement("div",{className:O},_),c.createElement("div",{className:a+"-control"},c.createElement("textarea",(0,n.default)({ref:function(e){return r.textareaRef=e}},T,M,{value:S,onChange:this.onChange,onBlur:this.onBlur,onFocus:this.onFocus,readOnly:!u,style:d}))),m&&u&&S&&P>0&&c.createElement(f.default,{activeClassName:a+"-clear-active"},c.createElement("div",{className:a+"-clear",onClick:this.clearInput})),g&&c.createElement("div",{className:a+"-error-extra",onClick:this.onErrorClick}),A&&c.createElement("span",{className:a+"-count"},c.createElement("span",null,S?P:0),"/",b))}}]),t}(c.Component);t.default=g,g.defaultProps={prefixCls:"am-textarea",prefixListCls:"am-list",autoHeight:!1,editable:!0,disabled:!1,placeholder:"",clear:!1,rows:1,onChange:m,onBlur:m,onFocus:m,onErrorClick:m,error:!1,labelNumber:5},e.exports=t.default},function(e,t,r){var n=r(147),i=r(40),o=r(175),a=r(362),s=r(361),u=function(e){n.config(o.SERO_BIGNUMBER_ROUNDING_MODE);var t=i.padLeft(i.toTwosComplement(e).toString(16),64);return new a(t)},l=function(e){var t=e.staticPart()||"0";return function(e){return"1"===new n(e.substr(0,1),16).toString(2).substr(0,1)}(t)?new n(t,16).minus(new n("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16)).minus(1):new n(t,16)},c=function(e){var t=e.staticPart()||"0";return new n(t,16)};e.exports={formatInputInt:u,formatInputBytes:function(e){var t=i.toHex(e).substr(2),r=Math.floor((t.length+63)/64);return t=i.padRight(t,64*r),new a(t)},formatInputDynamicBytes:function(e){var t=i.toHex(e).substr(2),r=t.length/2,n=Math.floor((t.length+63)/64);return t=i.padRight(t,64*n),new a(u(r).value+t)},formatInputString:function(e){var t=i.fromUtf8(e).substr(2),r=t.length/2,n=Math.floor((t.length+63)/64);return t=i.padRight(t,64*n),new a(u(r).value+t)},formatInputBool:function(e){return new a("000000000000000000000000000000000000000000000000000000000000000"+(e?"1":"0"))},formatInputReal:function(e){return u(new n(e).times(new n(2).pow(128)))},formatInputAddress:function(e){var t=s.decode(e).slice(44),r=i.bytesToHex(t).substr(2);return r=i.padLeft(r,64),new a(r)},formatInputFullAddress:function(e){var t=s.decode(e);return i.bytesToHex(t).substr(2)},formtInputShortAddress:function(e){var t=e.substr(2);return t=i.padLeft(t,64),new a(t)},formatOutputInt:l,formatOutputUInt:c,formatOutputReal:function(e){return l(e).dividedBy(new n(2).pow(128))},formatOutputUReal:function(e){return c(e).dividedBy(new n(2).pow(128))},formatOutputBool:function(e){return"0000000000000000000000000000000000000000000000000000000000000001"===e.staticPart()},formatOutputBytes:function(e,t){var r=t.match(/^bytes([0-9]*)/),n=parseInt(r[1]);return"0x"+e.staticPart().slice(0,2*n)},formatOutputDynamicBytes:function(e){var t=2*new n(e.dynamicPart().slice(0,64),16).toNumber();return"0x"+e.dynamicPart().substr(64,t)},formatOutputString:function(e){var t=2*new n(e.dynamicPart().slice(0,64),16).toNumber();return i.toUtf8(e.dynamicPart().substr(64,t))},formatOutputAddress:function(e){var t=e.staticPart(),r=t.slice(t.length-128,t.length),n=i.hexToBytes(r);return i.bytesToBase58(n)}}},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=p(r(2)),i=p(r(8)),o=p(r(3)),a=p(r(7)),s=p(r(4)),u=p(r(5)),l=p(r(9)),c=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t.default=e,t}(r(0)),f=p(r(25)),h=p(r(144)),d=p(r(10));function p(e){return e&&e.__esModule?e:{default:e}}var m=function(e){function t(e){(0,o.default)(this,t);var r=(0,s.default)(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.onClick=function(){var e=r.props,t=e.disabled,n=e.onChange;if(!t){var i=r.state.selected;r.setState({selected:!i},(function(){n&&n(!i)}))}},r.onTagClose=function(){r.props.onClose&&r.props.onClose(),r.setState({closed:!0},r.props.afterClose)},r.state={selected:e.selected,closed:!1},r}return(0,u.default)(t,e),(0,a.default)(t,[{key:"componentWillReceiveProps",value:function(e){this.props.selected!==e.selected&&this.setState({selected:e.selected})}},{key:"render",value:function(){var e,t=this.props,r=t.children,o=t.className,a=t.prefixCls,s=t.disabled,u=t.closable,p=t.small,m=t.style,v=(0,l.default)(o,a,(e={},(0,i.default)(e,a+"-normal",!s&&(!this.state.selected||p||u)),(0,i.default)(e,a+"-small",p),(0,i.default)(e,a+"-active",this.state.selected&&!s&&!p&&!u),(0,i.default)(e,a+"-disabled",s),(0,i.default)(e,a+"-closable",u),e)),g=!u||s||p?null:c.createElement(f.default,{activeClassName:a+"-close-active"},c.createElement("div",{className:a+"-close",role:"button",onClick:this.onTagClose,"aria-label":"remove tag"},c.createElement(d.default,{type:"cross-circle",size:"xs","aria-hidden":"true"})));return this.state.closed?null:c.createElement("div",(0,n.default)({},(0,h.default)(this.props),{className:v,onClick:this.onClick,style:m}),c.createElement("div",{className:a+"-text"},r),g)}}]),t}(c.Component);t.default=m,m.defaultProps={prefixCls:"am-tag",disabled:!1,selected:!1,closable:!1,small:!1,onChange:function(){},onClose:function(){},afterClose:function(){}},e.exports=t.default},function(e,t,r){"use strict";e.exports=function(){}},function(e,t,r){var n=r(194)("wks"),i=r(157),o=r(85).Symbol,a="function"==typeof o;(e.exports=function(e){return n[e]||(n[e]=a&&o[e]||(a?o:i)("Symbol."+e))}).store=n},function(e,t,r){"use strict";r(37),r(455)},function(e,t,r){"use strict";var n=r(66),i=r(28);function o(e,t){return 55296===(64512&e.charCodeAt(t))&&(!(t<0||t+1>=e.length)&&56320===(64512&e.charCodeAt(t+1)))}function a(e){return(e>>>24|e>>>8&65280|e<<8&16711680|(255&e)<<24)>>>0}function s(e){return 1===e.length?"0"+e:e}function u(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}t.inherits=i,t.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),i=0;i>6|192,r[n++]=63&a|128):o(e,i)?(a=65536+((1023&a)<<10)+(1023&e.charCodeAt(++i)),r[n++]=a>>18|240,r[n++]=a>>12&63|128,r[n++]=a>>6&63|128,r[n++]=63&a|128):(r[n++]=a>>12|224,r[n++]=a>>6&63|128,r[n++]=63&a|128)}else for(i=0;i>>0}return a},t.split32=function(e,t){for(var r=new Array(4*e.length),n=0,i=0;n>>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},t.rotr32=function(e,t){return e>>>t|e<<32-t},t.rotl32=function(e,t){return e<>>32-t},t.sum32=function(e,t){return e+t>>>0},t.sum32_3=function(e,t,r){return e+t+r>>>0},t.sum32_4=function(e,t,r,n){return e+t+r+n>>>0},t.sum32_5=function(e,t,r,n,i){return e+t+r+n+i>>>0},t.sum64=function(e,t,r,n){var i=e[t],o=n+e[t+1]>>>0,a=(o>>0,e[t+1]=o},t.sum64_hi=function(e,t,r,n){return(t+n>>>0>>0},t.sum64_lo=function(e,t,r,n){return t+n>>>0},t.sum64_4_hi=function(e,t,r,n,i,o,a,s){var u=0,l=t;return u+=(l=l+n>>>0)>>0)>>0)>>0},t.sum64_4_lo=function(e,t,r,n,i,o,a,s){return t+n+o+s>>>0},t.sum64_5_hi=function(e,t,r,n,i,o,a,s,u,l){var c=0,f=t;return c+=(f=f+n>>>0)>>0)>>0)>>0)>>0},t.sum64_5_lo=function(e,t,r,n,i,o,a,s,u,l){return t+n+o+s+l>>>0},t.rotr64_hi=function(e,t,r){return(t<<32-r|e>>>r)>>>0},t.rotr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0},t.shr64_hi=function(e,t,r){return e>>>r},t.shr64_lo=function(e,t,r){return(e<<32-r|t>>>r)>>>0}},function(e,t,r){"use strict";var n=r(40),i=r(175),o=r(176),a=(r(274),function(e){if(void 0!==e)return function(e){return"latest"===e||"pending"===e||"earliest"===e}(e)?e:n.toHex(e)}),s=function(e){return e},u=function(e){return e.blockNumber&&(e.blockNumber=n.toDecimal(e.blockNumber)),e.transactionIndex&&(e.transactionIndex=n.toDecimal(e.transactionIndex)),e.logIndex&&(e.logIndex=n.toDecimal(e.logIndex)),e},l=function(e){var t=new o(e);if(t.isValid()&&t.isDirect())return"0x"+t.address();if(n.isStrictAddress(e))return e;throw new Error("invalid address")},c=function(e){if(n.paramAddress(e))return e;throw new Error("invalid address")};e.exports={inputDefaultBlockNumberFormatter:function(e){return void 0===e?i.defaultBlock:a(e)},inputBlockNumberFormatter:a,inputCallFormatter:function(e){return e.from=e.from||i.defaultAccount,e.from&&(e.from=c(e.from)),e.to&&(e.to=c(e.to)),["gasPrice","gas","value","nonce"].filter((function(t){return void 0!==e[t]})).forEach((function(t){e[t]=n.fromDecimal(e[t])})),e},inputTransactionFormatter:function(e){return e.from=e.from||i.defaultAccount,e.from=l(e.from),e.to&&(e.to=c(e.to)),["gasPrice","gas","value","nonce"].filter((function(t){return void 0!==e[t]})).forEach((function(t){e[t]=n.fromDecimal(e[t])})),e},inputRegistPoolFormatter:function(e){return e.from=e.from||i.defaultAccount,e.from=l(e.from),e.to&&(e.to=c(e.to)),["gasPrice","gas","value","fee"].filter((function(t){return void 0!==e[t]})).forEach((function(t){e[t]=n.fromDecimal(e[t])})),e},inputParamAddressFormatter:c,inputAddressFormatter:l,inputPostFormatter:function(e){return e.ttl=n.fromDecimal(e.ttl),e.workToProve=n.fromDecimal(e.workToProve),e.priority=n.fromDecimal(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:n.fromUtf8(e)})),e},outputBigNumberFormatter:function(e){return n.toBigNumber(e)},outputTransactionFormatter:s,outputTransactionReceiptFormatter:function(e){return null!==e.blockNumber&&(e.blockNumber=n.toDecimal(e.blockNumber)),null!==e.transactionIndex&&(e.transactionIndex=n.toDecimal(e.transactionIndex)),e.cumulativeGasUsed=n.toDecimal(e.cumulativeGasUsed),e.gasUsed=n.toDecimal(e.gasUsed),n.isArray(e.logs)&&(e.logs=e.logs.map((function(e){return u(e)}))),e},outputBlockFormatter:function(e){return e.gasLimit=n.toDecimal(e.gasLimit),e.gasUsed=n.toDecimal(e.gasUsed),e.size=n.toDecimal(e.size),e.timestamp=n.toDecimal(e.timestamp),null!==e.number&&(e.number=n.toDecimal(e.number)),e.difficulty=n.toBigNumber(e.difficulty),e.totalDifficulty=n.toBigNumber(e.totalDifficulty),n.isArray(e.transactions)&&e.transactions.forEach((function(e){if(!n.isString(e))return s(e)})),e},outputLogFormatter:u,outputPostFormatter:function(e){return e.expiry=n.toDecimal(e.expiry),e.sent=n.toDecimal(e.sent),e.ttl=n.toDecimal(e.ttl),e.workProved=n.toDecimal(e.workProved),e.topics||(e.topics=[]),e.topics=e.topics.map((function(e){return n.toAscii(e)})),e},outputSyncingFormatter:function(e){return e?(e.startingBlock=n.toDecimal(e.startingBlock),e.currentBlock=n.toDecimal(e.currentBlock),e.highestBlock=n.toDecimal(e.highestBlock),e.knownStates&&(e.knownStates=n.toDecimal(e.knownStates),e.pulledStates=n.toDecimal(e.pulledStates)),e):e},outputBalanceFormatter:function(e){if(e){if(e.hasOwnProperty("tkn"))if(e.tkn)for(var t in e.tkn)e.tkn[t]=n.toBigNumber(e.tkn[t]);else delete e.tkn;return e.hasOwnProperty("tkt")&&(e.tkt||delete e.tkt),e}},outputStakeShareFormatter:function(e){if(e)return e instanceof Array?(["missed","num","total","status","remaining","expired","fee","at","timestamp","lastPayTime","returnNum"].forEach((function(t){e.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))}))})),["profit","price","returnProfit"].forEach((function(t){e.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))}))):(["missed","num","total","status","remaining","expired","fee","at","timestamp","lastPayTime","returnNum"].forEach((function(t){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))})),["profit","price","returnProfit"].forEach((function(t){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))),e},outputStakePoolFormatter:function(e){if(e)return e instanceof Array?(["choicedNum","createAt","expireNum","fee","missedNum","shareNum","lastPayTime","wishVoteNum","timestamp"].forEach((function(t){e.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))}))})),["profit"].forEach((function(t){e.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))}))):(["choicedNum","createAt","expireNum","fee","missedNum","shareNum","lastPayTime","wishVoteNum","timestamp"].forEach((function(t){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))})),["profit"].forEach((function(t){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))),e},outputStakeInfoFormatter:function(e){if(e&&(e.pools||e.shares))return e.pools&&(["choicedNum","createAt","expireNum","fee","missedNum","shareNum","lastPayTime","wishVoteNum","timestamp","blockNumber"].forEach((function(t){e.pools.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))}))})),["profit"].forEach((function(t){e.pools.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))}))),e.shares&&(["missed","num","total","status","remaining","expired","fee","at","timestamp","lastPayTime","returnNum","blockNumber"].forEach((function(t){e.shares.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toDecimal(e[t]))}))})),["profit","price"].forEach((function(t){e.shares.forEach((function(e){e.hasOwnProperty(t)&&(e[t]=n.toBigNumber(e[t]))}))}))),e}}},function(e,t,r){"use strict";t.__esModule=!0;var n=a(r(406)),i=a(r(416)),o="function"===typeof i.default&&"symbol"===typeof n.default?function(e){return typeof e}:function(e){return e&&"function"===typeof i.default&&e.constructor===i.default&&e!==i.default.prototype?"symbol":typeof e};function a(e){return e&&e.__esModule?e:{default:e}}t.default="function"===typeof i.default&&"symbol"===o(n.default)?function(e){return"undefined"===typeof e?"undefined":o(e)}:function(e){return e&&"function"===typeof i.default&&e.constructor===i.default&&e!==i.default.prototype?"symbol":"undefined"===typeof e?"undefined":o(e)}},function(e,t,r){"use strict";function n(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}r.d(t,"a",(function(){return n}))},function(e,t,r){var n=r(72),i=r(362),o=(r(363),r(40),function(e){this._inputFormatter=e.inputFormatter,this._outputFormatter=e.outputFormatter});o.prototype.isType=function(e){throw"this method should be overrwritten for type "+e},o.prototype.staticPartLength=function(e){var t=this._outputLenght?this._outputLenght:32;return(this.nestedTypes(e)||["[1]"]).map((function(e){return parseInt(e.slice(1,-1),10)||1})).reduce((function(e,t){return e*t}),t)},o.prototype.isDynamicArray=function(e){var t=this.nestedTypes(e);return!!t&&!t[t.length-1].match(/[0-9]{1,}/g)},o.prototype.isStaticArray=function(e){var t=this.nestedTypes(e);return!!t&&!!t[t.length-1].match(/[0-9]{1,}/g)},o.prototype.staticArrayLength=function(e){var t=this.nestedTypes(e);return t?parseInt(t[t.length-1].match(/[0-9]{1,}/g)||1):1},o.prototype.nestedName=function(e){var t=this.nestedTypes(e);return t?e.substr(0,e.length-t[t.length-1].length):e},o.prototype.isDynamicType=function(){return!1},o.prototype.nestedTypes=function(e){return e.match(/(\[[0-9]*\])/g)},o.prototype.encode=function(e,t,r){var i=this;return this.isDynamicArray(t)?function(){var o=e.length,a=i.nestedName(t),s=[];return s.push(n.formatInputInt(o).encode()),e.forEach((function(e){s.push(i.encode(e,a,r))})),s}():this.isStaticArray(t)?function(){for(var n=i.staticArrayLength(t),o=i.nestedName(t),a=[],s=0;s=49&&l<=54?l-49+10:l>=17&&l<=22?l-17+10:l,a|=u}return n(!(240&a),"Invalid character in "+e),i}function u(e,t,r,i){for(var o=0,a=0,s=Math.min(e.length,r),u=t;u=49?l-49+10:l>=17?l-17+10:l,n(l>=0&&a"}o.isBN=function(e){return e instanceof o||null!==e&&"object"===typeof e&&e.constructor.wordSize===o.wordSize&&Array.isArray(e.words)},o.max=function(e,t){return e.cmp(t)>0?e:t},o.min=function(e,t){return e.cmp(t)<0?e:t},o.prototype._init=function(e,t,r){if("number"===typeof e)return this._initNumber(e,t,r);if("object"===typeof e)return this._initArray(e,t,r);"hex"===t&&(t=16),n(t===(0|t)&&t>=2&&t<=36);var i=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&i++,16===t?this._parseHex(e,i):this._parseBase(e,t,i),"-"===e[0]&&(this.negative=1),this._strip(),"le"===r&&this._initArray(this.toArray(),t,r)},o.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):(n(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===r&&this._initArray(this.toArray(),t,r)},o.prototype._initArray=function(e,t,r){if(n("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 i=0;i=0;i-=3)a=e[i]|e[i-1]<<8|e[i-2]<<16,this.words[o]|=a<>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);else if("le"===r)for(i=0,o=0;i>>26-s&67108863,(s+=24)>=26&&(s-=26,o++);return this._strip()},o.prototype._parseHex=function(e,t){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r=t;r-=6)i=s(e,r,r+6),this.words[n]|=i<>>26-o&4194303,(o+=24)>=26&&(o-=26,n++);r+6!==t&&(i=s(e,t,r+6),this.words[n]|=i<>>26-o&4194303),this._strip()},o.prototype._parseBase=function(e,t,r){this.words=[0],this.length=1;for(var n=0,i=1;i<=67108863;i*=t)n++;n--,i=i/t|0;for(var o=e.length-r,a=o%n,s=Math.min(o,o-a)+r,l=0,c=r;c1&&0===this.words[this.length-1];)this.length--;return this._normSign()},o.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!==typeof Symbol&&"function"===typeof Symbol.for?o.prototype[Symbol.for("nodejs.util.inspect.custom")]=c:o.prototype.inspect=c;var f=["","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"],h=[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],d=[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];o.prototype.toString=function(e,t){var r;if(t=0|t||1,16===(e=e||10)||"hex"===e){r="";for(var i=0,o=0,a=0;a>>24-i&16777215)||a!==this.length-1?f[6-u.length]+u+r:u+r,(i+=2)>=26&&(i-=26,a--)}for(0!==o&&(r=o.toString(16)+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}if(e===(0|e)&&e>=2&&e<=36){var l=h[e],c=d[e];r="";var p=this.clone();for(p.negative=0;!p.isZero();){var m=p.modrn(c).toString(e);r=(p=p.idivn(c)).isZero()?m+r:f[l-m.length]+m+r}for(this.isZero()&&(r="0"+r);r.length%t!==0;)r="0"+r;return 0!==this.negative&&(r="-"+r),r}n(!1,"Base should be between 2 and 36")},o.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]:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},o.prototype.toJSON=function(){return this.toString(16,2)},a&&(o.prototype.toBuffer=function(e,t){return this.toArrayLike(a,e,t)}),o.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)};function p(e,t,r){r.negative=t.negative^e.negative;var n=e.length+t.length|0;r.length=n,n=n-1|0;var i=0|e.words[0],o=0|t.words[0],a=i*o,s=67108863&a,u=a/67108864|0;r.words[0]=s;for(var l=1;l>>26,f=67108863&u,h=Math.min(l,t.length-1),d=Math.max(0,l-e.length+1);d<=h;d++){var p=l-d|0;c+=(a=(i=0|e.words[p])*(o=0|t.words[d])+f)/67108864|0,f=67108863&a}r.words[l]=0|f,u=0|c}return 0!==u?r.words[l]=0|u:r.length--,r._strip()}o.prototype.toArrayLike=function(e,t,r){this._strip();var i=this.byteLength(),o=r||Math.max(1,i);n(i<=o,"byte array longer than desired length"),n(o>0,"Requested array length <= 0");var a=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,o);return this["_toArrayLike"+("le"===t?"LE":"BE")](a,i),a},o.prototype._toArrayLikeLE=function(e,t){for(var r=0,n=0,i=0,o=0;i>8&255),r>16&255),6===o?(r>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r=0&&(e[r--]=a>>8&255),r>=0&&(e[r--]=a>>16&255),6===o?(r>=0&&(e[r--]=a>>24&255),n=0,o=0):(n=a>>>24,o+=2)}if(r>=0)for(e[r--]=n;r>=0;)e[r--]=0},Math.clz32?o.prototype._countBits=function(e){return 32-Math.clz32(e)}:o.prototype._countBits=function(e){var t=e,r=0;return t>=4096&&(r+=13,t>>>=13),t>=64&&(r+=7,t>>>=7),t>=8&&(r+=4,t>>>=4),t>=2&&(r+=2,t>>>=2),r+t},o.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},o.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},o.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;te.length?this.clone().ior(e):e.clone().ior(this)},o.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},o.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var r=0;re.length?this.clone().iand(e):e.clone().iand(this)},o.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},o.prototype.iuxor=function(e){var t,r;this.length>e.length?(t=this,r=e):(t=e,r=this);for(var n=0;ne.length?this.clone().ixor(e):e.clone().ixor(this)},o.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},o.prototype.inotn=function(e){n("number"===typeof e&&e>=0);var t=0|Math.ceil(e/26),r=e%26;this._expand(t),r>0&&t--;for(var i=0;i0&&(this.words[i]=~this.words[i]&67108863>>26-r),this._strip()},o.prototype.notn=function(e){return this.clone().inotn(e)},o.prototype.setn=function(e,t){n("number"===typeof e&&e>=0);var r=e/26|0,i=e%26;return this._expand(r+1),this.words[r]=t?this.words[r]|1<e.length?(r=this,n=e):(r=e,n=this);for(var i=0,o=0;o>>26;for(;0!==i&&o>>26;if(this.length=r.length,0!==i)this.words[this.length]=i,this.length++;else if(r!==this)for(;oe.length?this.clone().iadd(e):e.clone().iadd(this)},o.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;i>0?(r=this,n=e):(r=e,n=this);for(var o=0,a=0;a>26,this.words[a]=67108863&t;for(;0!==o&&a>26,this.words[a]=67108863&t;if(0===o&&a>>13,d=0|a[1],p=8191&d,m=d>>>13,v=0|a[2],g=8191&v,y=v>>>13,b=0|a[3],w=8191&b,_=b>>>13,C=0|a[4],M=8191&C,x=C>>>13,E=0|a[5],S=8191&E,k=E>>>13,A=0|a[6],I=8191&A,O=A>>>13,P=0|a[7],T=8191&P,N=P>>>13,B=0|a[8],j=8191&B,R=B>>>13,D=0|a[9],F=8191&D,L=D>>>13,z=0|s[0],U=8191&z,H=z>>>13,q=0|s[1],V=8191&q,Q=q>>>13,K=0|s[2],W=8191&K,Y=K>>>13,G=0|s[3],X=8191&G,$=G>>>13,J=0|s[4],Z=8191&J,ee=J>>>13,te=0|s[5],re=8191&te,ne=te>>>13,ie=0|s[6],oe=8191&ie,ae=ie>>>13,se=0|s[7],ue=8191&se,le=se>>>13,ce=0|s[8],fe=8191&ce,he=ce>>>13,de=0|s[9],pe=8191&de,me=de>>>13;r.negative=e.negative^t.negative,r.length=19;var ve=(l+(n=Math.imul(f,U))|0)+((8191&(i=(i=Math.imul(f,H))+Math.imul(h,U)|0))<<13)|0;l=((o=Math.imul(h,H))+(i>>>13)|0)+(ve>>>26)|0,ve&=67108863,n=Math.imul(p,U),i=(i=Math.imul(p,H))+Math.imul(m,U)|0,o=Math.imul(m,H);var ge=(l+(n=n+Math.imul(f,V)|0)|0)+((8191&(i=(i=i+Math.imul(f,Q)|0)+Math.imul(h,V)|0))<<13)|0;l=((o=o+Math.imul(h,Q)|0)+(i>>>13)|0)+(ge>>>26)|0,ge&=67108863,n=Math.imul(g,U),i=(i=Math.imul(g,H))+Math.imul(y,U)|0,o=Math.imul(y,H),n=n+Math.imul(p,V)|0,i=(i=i+Math.imul(p,Q)|0)+Math.imul(m,V)|0,o=o+Math.imul(m,Q)|0;var ye=(l+(n=n+Math.imul(f,W)|0)|0)+((8191&(i=(i=i+Math.imul(f,Y)|0)+Math.imul(h,W)|0))<<13)|0;l=((o=o+Math.imul(h,Y)|0)+(i>>>13)|0)+(ye>>>26)|0,ye&=67108863,n=Math.imul(w,U),i=(i=Math.imul(w,H))+Math.imul(_,U)|0,o=Math.imul(_,H),n=n+Math.imul(g,V)|0,i=(i=i+Math.imul(g,Q)|0)+Math.imul(y,V)|0,o=o+Math.imul(y,Q)|0,n=n+Math.imul(p,W)|0,i=(i=i+Math.imul(p,Y)|0)+Math.imul(m,W)|0,o=o+Math.imul(m,Y)|0;var be=(l+(n=n+Math.imul(f,X)|0)|0)+((8191&(i=(i=i+Math.imul(f,$)|0)+Math.imul(h,X)|0))<<13)|0;l=((o=o+Math.imul(h,$)|0)+(i>>>13)|0)+(be>>>26)|0,be&=67108863,n=Math.imul(M,U),i=(i=Math.imul(M,H))+Math.imul(x,U)|0,o=Math.imul(x,H),n=n+Math.imul(w,V)|0,i=(i=i+Math.imul(w,Q)|0)+Math.imul(_,V)|0,o=o+Math.imul(_,Q)|0,n=n+Math.imul(g,W)|0,i=(i=i+Math.imul(g,Y)|0)+Math.imul(y,W)|0,o=o+Math.imul(y,Y)|0,n=n+Math.imul(p,X)|0,i=(i=i+Math.imul(p,$)|0)+Math.imul(m,X)|0,o=o+Math.imul(m,$)|0;var we=(l+(n=n+Math.imul(f,Z)|0)|0)+((8191&(i=(i=i+Math.imul(f,ee)|0)+Math.imul(h,Z)|0))<<13)|0;l=((o=o+Math.imul(h,ee)|0)+(i>>>13)|0)+(we>>>26)|0,we&=67108863,n=Math.imul(S,U),i=(i=Math.imul(S,H))+Math.imul(k,U)|0,o=Math.imul(k,H),n=n+Math.imul(M,V)|0,i=(i=i+Math.imul(M,Q)|0)+Math.imul(x,V)|0,o=o+Math.imul(x,Q)|0,n=n+Math.imul(w,W)|0,i=(i=i+Math.imul(w,Y)|0)+Math.imul(_,W)|0,o=o+Math.imul(_,Y)|0,n=n+Math.imul(g,X)|0,i=(i=i+Math.imul(g,$)|0)+Math.imul(y,X)|0,o=o+Math.imul(y,$)|0,n=n+Math.imul(p,Z)|0,i=(i=i+Math.imul(p,ee)|0)+Math.imul(m,Z)|0,o=o+Math.imul(m,ee)|0;var _e=(l+(n=n+Math.imul(f,re)|0)|0)+((8191&(i=(i=i+Math.imul(f,ne)|0)+Math.imul(h,re)|0))<<13)|0;l=((o=o+Math.imul(h,ne)|0)+(i>>>13)|0)+(_e>>>26)|0,_e&=67108863,n=Math.imul(I,U),i=(i=Math.imul(I,H))+Math.imul(O,U)|0,o=Math.imul(O,H),n=n+Math.imul(S,V)|0,i=(i=i+Math.imul(S,Q)|0)+Math.imul(k,V)|0,o=o+Math.imul(k,Q)|0,n=n+Math.imul(M,W)|0,i=(i=i+Math.imul(M,Y)|0)+Math.imul(x,W)|0,o=o+Math.imul(x,Y)|0,n=n+Math.imul(w,X)|0,i=(i=i+Math.imul(w,$)|0)+Math.imul(_,X)|0,o=o+Math.imul(_,$)|0,n=n+Math.imul(g,Z)|0,i=(i=i+Math.imul(g,ee)|0)+Math.imul(y,Z)|0,o=o+Math.imul(y,ee)|0,n=n+Math.imul(p,re)|0,i=(i=i+Math.imul(p,ne)|0)+Math.imul(m,re)|0,o=o+Math.imul(m,ne)|0;var Ce=(l+(n=n+Math.imul(f,oe)|0)|0)+((8191&(i=(i=i+Math.imul(f,ae)|0)+Math.imul(h,oe)|0))<<13)|0;l=((o=o+Math.imul(h,ae)|0)+(i>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,n=Math.imul(T,U),i=(i=Math.imul(T,H))+Math.imul(N,U)|0,o=Math.imul(N,H),n=n+Math.imul(I,V)|0,i=(i=i+Math.imul(I,Q)|0)+Math.imul(O,V)|0,o=o+Math.imul(O,Q)|0,n=n+Math.imul(S,W)|0,i=(i=i+Math.imul(S,Y)|0)+Math.imul(k,W)|0,o=o+Math.imul(k,Y)|0,n=n+Math.imul(M,X)|0,i=(i=i+Math.imul(M,$)|0)+Math.imul(x,X)|0,o=o+Math.imul(x,$)|0,n=n+Math.imul(w,Z)|0,i=(i=i+Math.imul(w,ee)|0)+Math.imul(_,Z)|0,o=o+Math.imul(_,ee)|0,n=n+Math.imul(g,re)|0,i=(i=i+Math.imul(g,ne)|0)+Math.imul(y,re)|0,o=o+Math.imul(y,ne)|0,n=n+Math.imul(p,oe)|0,i=(i=i+Math.imul(p,ae)|0)+Math.imul(m,oe)|0,o=o+Math.imul(m,ae)|0;var Me=(l+(n=n+Math.imul(f,ue)|0)|0)+((8191&(i=(i=i+Math.imul(f,le)|0)+Math.imul(h,ue)|0))<<13)|0;l=((o=o+Math.imul(h,le)|0)+(i>>>13)|0)+(Me>>>26)|0,Me&=67108863,n=Math.imul(j,U),i=(i=Math.imul(j,H))+Math.imul(R,U)|0,o=Math.imul(R,H),n=n+Math.imul(T,V)|0,i=(i=i+Math.imul(T,Q)|0)+Math.imul(N,V)|0,o=o+Math.imul(N,Q)|0,n=n+Math.imul(I,W)|0,i=(i=i+Math.imul(I,Y)|0)+Math.imul(O,W)|0,o=o+Math.imul(O,Y)|0,n=n+Math.imul(S,X)|0,i=(i=i+Math.imul(S,$)|0)+Math.imul(k,X)|0,o=o+Math.imul(k,$)|0,n=n+Math.imul(M,Z)|0,i=(i=i+Math.imul(M,ee)|0)+Math.imul(x,Z)|0,o=o+Math.imul(x,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(g,oe)|0,i=(i=i+Math.imul(g,ae)|0)+Math.imul(y,oe)|0,o=o+Math.imul(y,ae)|0,n=n+Math.imul(p,ue)|0,i=(i=i+Math.imul(p,le)|0)+Math.imul(m,ue)|0,o=o+Math.imul(m,le)|0;var xe=(l+(n=n+Math.imul(f,fe)|0)|0)+((8191&(i=(i=i+Math.imul(f,he)|0)+Math.imul(h,fe)|0))<<13)|0;l=((o=o+Math.imul(h,he)|0)+(i>>>13)|0)+(xe>>>26)|0,xe&=67108863,n=Math.imul(F,U),i=(i=Math.imul(F,H))+Math.imul(L,U)|0,o=Math.imul(L,H),n=n+Math.imul(j,V)|0,i=(i=i+Math.imul(j,Q)|0)+Math.imul(R,V)|0,o=o+Math.imul(R,Q)|0,n=n+Math.imul(T,W)|0,i=(i=i+Math.imul(T,Y)|0)+Math.imul(N,W)|0,o=o+Math.imul(N,Y)|0,n=n+Math.imul(I,X)|0,i=(i=i+Math.imul(I,$)|0)+Math.imul(O,X)|0,o=o+Math.imul(O,$)|0,n=n+Math.imul(S,Z)|0,i=(i=i+Math.imul(S,ee)|0)+Math.imul(k,Z)|0,o=o+Math.imul(k,ee)|0,n=n+Math.imul(M,re)|0,i=(i=i+Math.imul(M,ne)|0)+Math.imul(x,re)|0,o=o+Math.imul(x,ne)|0,n=n+Math.imul(w,oe)|0,i=(i=i+Math.imul(w,ae)|0)+Math.imul(_,oe)|0,o=o+Math.imul(_,ae)|0,n=n+Math.imul(g,ue)|0,i=(i=i+Math.imul(g,le)|0)+Math.imul(y,ue)|0,o=o+Math.imul(y,le)|0,n=n+Math.imul(p,fe)|0,i=(i=i+Math.imul(p,he)|0)+Math.imul(m,fe)|0,o=o+Math.imul(m,he)|0;var Ee=(l+(n=n+Math.imul(f,pe)|0)|0)+((8191&(i=(i=i+Math.imul(f,me)|0)+Math.imul(h,pe)|0))<<13)|0;l=((o=o+Math.imul(h,me)|0)+(i>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,n=Math.imul(F,V),i=(i=Math.imul(F,Q))+Math.imul(L,V)|0,o=Math.imul(L,Q),n=n+Math.imul(j,W)|0,i=(i=i+Math.imul(j,Y)|0)+Math.imul(R,W)|0,o=o+Math.imul(R,Y)|0,n=n+Math.imul(T,X)|0,i=(i=i+Math.imul(T,$)|0)+Math.imul(N,X)|0,o=o+Math.imul(N,$)|0,n=n+Math.imul(I,Z)|0,i=(i=i+Math.imul(I,ee)|0)+Math.imul(O,Z)|0,o=o+Math.imul(O,ee)|0,n=n+Math.imul(S,re)|0,i=(i=i+Math.imul(S,ne)|0)+Math.imul(k,re)|0,o=o+Math.imul(k,ne)|0,n=n+Math.imul(M,oe)|0,i=(i=i+Math.imul(M,ae)|0)+Math.imul(x,oe)|0,o=o+Math.imul(x,ae)|0,n=n+Math.imul(w,ue)|0,i=(i=i+Math.imul(w,le)|0)+Math.imul(_,ue)|0,o=o+Math.imul(_,le)|0,n=n+Math.imul(g,fe)|0,i=(i=i+Math.imul(g,he)|0)+Math.imul(y,fe)|0,o=o+Math.imul(y,he)|0;var Se=(l+(n=n+Math.imul(p,pe)|0)|0)+((8191&(i=(i=i+Math.imul(p,me)|0)+Math.imul(m,pe)|0))<<13)|0;l=((o=o+Math.imul(m,me)|0)+(i>>>13)|0)+(Se>>>26)|0,Se&=67108863,n=Math.imul(F,W),i=(i=Math.imul(F,Y))+Math.imul(L,W)|0,o=Math.imul(L,Y),n=n+Math.imul(j,X)|0,i=(i=i+Math.imul(j,$)|0)+Math.imul(R,X)|0,o=o+Math.imul(R,$)|0,n=n+Math.imul(T,Z)|0,i=(i=i+Math.imul(T,ee)|0)+Math.imul(N,Z)|0,o=o+Math.imul(N,ee)|0,n=n+Math.imul(I,re)|0,i=(i=i+Math.imul(I,ne)|0)+Math.imul(O,re)|0,o=o+Math.imul(O,ne)|0,n=n+Math.imul(S,oe)|0,i=(i=i+Math.imul(S,ae)|0)+Math.imul(k,oe)|0,o=o+Math.imul(k,ae)|0,n=n+Math.imul(M,ue)|0,i=(i=i+Math.imul(M,le)|0)+Math.imul(x,ue)|0,o=o+Math.imul(x,le)|0,n=n+Math.imul(w,fe)|0,i=(i=i+Math.imul(w,he)|0)+Math.imul(_,fe)|0,o=o+Math.imul(_,he)|0;var ke=(l+(n=n+Math.imul(g,pe)|0)|0)+((8191&(i=(i=i+Math.imul(g,me)|0)+Math.imul(y,pe)|0))<<13)|0;l=((o=o+Math.imul(y,me)|0)+(i>>>13)|0)+(ke>>>26)|0,ke&=67108863,n=Math.imul(F,X),i=(i=Math.imul(F,$))+Math.imul(L,X)|0,o=Math.imul(L,$),n=n+Math.imul(j,Z)|0,i=(i=i+Math.imul(j,ee)|0)+Math.imul(R,Z)|0,o=o+Math.imul(R,ee)|0,n=n+Math.imul(T,re)|0,i=(i=i+Math.imul(T,ne)|0)+Math.imul(N,re)|0,o=o+Math.imul(N,ne)|0,n=n+Math.imul(I,oe)|0,i=(i=i+Math.imul(I,ae)|0)+Math.imul(O,oe)|0,o=o+Math.imul(O,ae)|0,n=n+Math.imul(S,ue)|0,i=(i=i+Math.imul(S,le)|0)+Math.imul(k,ue)|0,o=o+Math.imul(k,le)|0,n=n+Math.imul(M,fe)|0,i=(i=i+Math.imul(M,he)|0)+Math.imul(x,fe)|0,o=o+Math.imul(x,he)|0;var Ae=(l+(n=n+Math.imul(w,pe)|0)|0)+((8191&(i=(i=i+Math.imul(w,me)|0)+Math.imul(_,pe)|0))<<13)|0;l=((o=o+Math.imul(_,me)|0)+(i>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,n=Math.imul(F,Z),i=(i=Math.imul(F,ee))+Math.imul(L,Z)|0,o=Math.imul(L,ee),n=n+Math.imul(j,re)|0,i=(i=i+Math.imul(j,ne)|0)+Math.imul(R,re)|0,o=o+Math.imul(R,ne)|0,n=n+Math.imul(T,oe)|0,i=(i=i+Math.imul(T,ae)|0)+Math.imul(N,oe)|0,o=o+Math.imul(N,ae)|0,n=n+Math.imul(I,ue)|0,i=(i=i+Math.imul(I,le)|0)+Math.imul(O,ue)|0,o=o+Math.imul(O,le)|0,n=n+Math.imul(S,fe)|0,i=(i=i+Math.imul(S,he)|0)+Math.imul(k,fe)|0,o=o+Math.imul(k,he)|0;var Ie=(l+(n=n+Math.imul(M,pe)|0)|0)+((8191&(i=(i=i+Math.imul(M,me)|0)+Math.imul(x,pe)|0))<<13)|0;l=((o=o+Math.imul(x,me)|0)+(i>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,n=Math.imul(F,re),i=(i=Math.imul(F,ne))+Math.imul(L,re)|0,o=Math.imul(L,ne),n=n+Math.imul(j,oe)|0,i=(i=i+Math.imul(j,ae)|0)+Math.imul(R,oe)|0,o=o+Math.imul(R,ae)|0,n=n+Math.imul(T,ue)|0,i=(i=i+Math.imul(T,le)|0)+Math.imul(N,ue)|0,o=o+Math.imul(N,le)|0,n=n+Math.imul(I,fe)|0,i=(i=i+Math.imul(I,he)|0)+Math.imul(O,fe)|0,o=o+Math.imul(O,he)|0;var Oe=(l+(n=n+Math.imul(S,pe)|0)|0)+((8191&(i=(i=i+Math.imul(S,me)|0)+Math.imul(k,pe)|0))<<13)|0;l=((o=o+Math.imul(k,me)|0)+(i>>>13)|0)+(Oe>>>26)|0,Oe&=67108863,n=Math.imul(F,oe),i=(i=Math.imul(F,ae))+Math.imul(L,oe)|0,o=Math.imul(L,ae),n=n+Math.imul(j,ue)|0,i=(i=i+Math.imul(j,le)|0)+Math.imul(R,ue)|0,o=o+Math.imul(R,le)|0,n=n+Math.imul(T,fe)|0,i=(i=i+Math.imul(T,he)|0)+Math.imul(N,fe)|0,o=o+Math.imul(N,he)|0;var Pe=(l+(n=n+Math.imul(I,pe)|0)|0)+((8191&(i=(i=i+Math.imul(I,me)|0)+Math.imul(O,pe)|0))<<13)|0;l=((o=o+Math.imul(O,me)|0)+(i>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,n=Math.imul(F,ue),i=(i=Math.imul(F,le))+Math.imul(L,ue)|0,o=Math.imul(L,le),n=n+Math.imul(j,fe)|0,i=(i=i+Math.imul(j,he)|0)+Math.imul(R,fe)|0,o=o+Math.imul(R,he)|0;var Te=(l+(n=n+Math.imul(T,pe)|0)|0)+((8191&(i=(i=i+Math.imul(T,me)|0)+Math.imul(N,pe)|0))<<13)|0;l=((o=o+Math.imul(N,me)|0)+(i>>>13)|0)+(Te>>>26)|0,Te&=67108863,n=Math.imul(F,fe),i=(i=Math.imul(F,he))+Math.imul(L,fe)|0,o=Math.imul(L,he);var Ne=(l+(n=n+Math.imul(j,pe)|0)|0)+((8191&(i=(i=i+Math.imul(j,me)|0)+Math.imul(R,pe)|0))<<13)|0;l=((o=o+Math.imul(R,me)|0)+(i>>>13)|0)+(Ne>>>26)|0,Ne&=67108863;var Be=(l+(n=Math.imul(F,pe))|0)+((8191&(i=(i=Math.imul(F,me))+Math.imul(L,pe)|0))<<13)|0;return l=((o=Math.imul(L,me))+(i>>>13)|0)+(Be>>>26)|0,Be&=67108863,u[0]=ve,u[1]=ge,u[2]=ye,u[3]=be,u[4]=we,u[5]=_e,u[6]=Ce,u[7]=Me,u[8]=xe,u[9]=Ee,u[10]=Se,u[11]=ke,u[12]=Ae,u[13]=Ie,u[14]=Oe,u[15]=Pe,u[16]=Te,u[17]=Ne,u[18]=Be,0!==l&&(u[19]=l,r.length++),r};function v(e,t,r){r.negative=t.negative^e.negative,r.length=e.length+t.length;for(var n=0,i=0,o=0;o>>26)|0)>>>26,a&=67108863}r.words[o]=s,n=a,a=i}return 0!==n?r.words[o]=n:r.length--,r._strip()}function g(e,t,r){return v(e,t,r)}function y(e,t){this.x=e,this.y=t}Math.imul||(m=p),o.prototype.mulTo=function(e,t){var r=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):r<63?p(this,e,t):r<1024?v(this,e,t):g(this,e,t)},y.prototype.makeRBT=function(e){for(var t=new Array(e),r=o.prototype._countBits(e)-1,n=0;n>=1;return n},y.prototype.permute=function(e,t,r,n,i,o){for(var a=0;a>>=1)i++;return 1<>>=13,r[2*a+1]=8191&o,o>>>=13;for(a=2*t;a>=26,r+=o/67108864|0,r+=a>>>26,this.words[i]=67108863&a}return 0!==r&&(this.words[i]=r,this.length++),t?this.ineg():this},o.prototype.muln=function(e){return this.clone().imuln(e)},o.prototype.sqr=function(){return this.mul(this)},o.prototype.isqr=function(){return this.imul(this.clone())},o.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),r=0;r>>i&1}return t}(e);if(0===t.length)return new o(1);for(var r=this,n=0;n=0);var t,r=e%26,i=(e-r)/26,o=67108863>>>26-r<<26-r;if(0!==r){var a=0;for(t=0;t>>26-r}a&&(this.words[t]=a,this.length++)}if(0!==i){for(t=this.length-1;t>=0;t--)this.words[t+i]=this.words[t];for(t=0;t=0),i=t?(t-t%26)/26:0;var o=e%26,a=Math.min((e-o)/26,this.length),s=67108863^67108863>>>o<a)for(this.length-=a,l=0;l=0&&(0!==c||l>=i);l--){var f=0|this.words[l];this.words[l]=c<<26-o|f>>>o,c=f&s}return u&&0!==c&&(u.words[u.length++]=c),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},o.prototype.ishrn=function(e,t,r){return n(0===this.negative),this.iushrn(e,t,r)},o.prototype.shln=function(e){return this.clone().ishln(e)},o.prototype.ushln=function(e){return this.clone().iushln(e)},o.prototype.shrn=function(e){return this.clone().ishrn(e)},o.prototype.ushrn=function(e){return this.clone().iushrn(e)},o.prototype.testn=function(e){n("number"===typeof e&&e>=0);var t=e%26,r=(e-t)/26,i=1<=0);var t=e%26,r=(e-t)/26;if(n(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 i=67108863^67108863>>>t<=67108864;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},o.prototype.isubn=function(e){if(n("number"===typeof e),n(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>26)-(u/67108864|0),this.words[i+r]=67108863&o}for(;i>26,this.words[i+r]=67108863&o;if(0===s)return this._strip();for(n(-1===s),s=0,i=0;i>26,this.words[i]=67108863&o;return this.negative=1,this._strip()},o.prototype._wordDiv=function(e,t){var r=(this.length,e.length),n=this.clone(),i=e,a=0|i.words[i.length-1];0!==(r=26-this._countBits(a))&&(i=i.ushln(r),n.iushln(r),a=0|i.words[i.length-1]);var s,u=n.length-i.length;if("mod"!==t){(s=new o(null)).length=u+1,s.words=new Array(s.length);for(var l=0;l=0;f--){var h=67108864*(0|n.words[i.length+f])+(0|n.words[i.length+f-1]);for(h=Math.min(h/a|0,67108863),n._ishlnsubmul(i,h,f);0!==n.negative;)h--,n.negative=0,n._ishlnsubmul(i,1,f),n.isZero()||(n.negative^=1);s&&(s.words[f]=h)}return s&&s._strip(),n._strip(),"div"!==t&&0!==r&&n.iushrn(r),{div:s||null,mod:n}},o.prototype.divmod=function(e,t,r){return n(!e.isZero()),this.isZero()?{div:new o(0),mod:new o(0)}:0!==this.negative&&0===e.negative?(s=this.neg().divmod(e,t),"mod"!==t&&(i=s.div.neg()),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.iadd(e)),{div:i,mod:a}):0===this.negative&&0!==e.negative?(s=this.divmod(e.neg(),t),"mod"!==t&&(i=s.div.neg()),{div:i,mod:s.mod}):0!==(this.negative&e.negative)?(s=this.neg().divmod(e.neg(),t),"div"!==t&&(a=s.mod.neg(),r&&0!==a.negative&&a.isub(e)),{div:s.div,mod:a}):e.length>this.length||this.cmp(e)<0?{div:new o(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new o(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new o(this.modrn(e.words[0]))}:this._wordDiv(e,t);var i,a,s},o.prototype.div=function(e){return this.divmod(e,"div",!1).div},o.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},o.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},o.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)},o.prototype.modrn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=(1<<26)%e,i=0,o=this.length-1;o>=0;o--)i=(r*i+(0|this.words[o]))%e;return t?-i:i},o.prototype.modn=function(e){return this.modrn(e)},o.prototype.idivn=function(e){var t=e<0;t&&(e=-e),n(e<=67108863);for(var r=0,i=this.length-1;i>=0;i--){var o=(0|this.words[i])+67108864*r;this.words[i]=o/e|0,r=o%e}return this._strip(),t?this.ineg():this},o.prototype.divn=function(e){return this.clone().idivn(e)},o.prototype.egcd=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i=new o(1),a=new o(0),s=new o(0),u=new o(1),l=0;t.isEven()&&r.isEven();)t.iushrn(1),r.iushrn(1),++l;for(var c=r.clone(),f=t.clone();!t.isZero();){for(var h=0,d=1;0===(t.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(t.iushrn(h);h-- >0;)(i.isOdd()||a.isOdd())&&(i.iadd(c),a.isub(f)),i.iushrn(1),a.iushrn(1);for(var p=0,m=1;0===(r.words[0]&m)&&p<26;++p,m<<=1);if(p>0)for(r.iushrn(p);p-- >0;)(s.isOdd()||u.isOdd())&&(s.iadd(c),u.isub(f)),s.iushrn(1),u.iushrn(1);t.cmp(r)>=0?(t.isub(r),i.isub(s),a.isub(u)):(r.isub(t),s.isub(i),u.isub(a))}return{a:s,b:u,gcd:r.iushln(l)}},o.prototype._invmp=function(e){n(0===e.negative),n(!e.isZero());var t=this,r=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var i,a=new o(1),s=new o(0),u=r.clone();t.cmpn(1)>0&&r.cmpn(1)>0;){for(var l=0,c=1;0===(t.words[0]&c)&&l<26;++l,c<<=1);if(l>0)for(t.iushrn(l);l-- >0;)a.isOdd()&&a.iadd(u),a.iushrn(1);for(var f=0,h=1;0===(r.words[0]&h)&&f<26;++f,h<<=1);if(f>0)for(r.iushrn(f);f-- >0;)s.isOdd()&&s.iadd(u),s.iushrn(1);t.cmp(r)>=0?(t.isub(r),a.isub(s)):(r.isub(t),s.isub(a))}return(i=0===t.cmpn(1)?a:s).cmpn(0)<0&&i.iadd(e),i},o.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,r.negative=0;for(var n=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)},o.prototype.invm=function(e){return this.egcd(e).a.umod(e)},o.prototype.isEven=function(){return 0===(1&this.words[0])},o.prototype.isOdd=function(){return 1===(1&this.words[0])},o.prototype.andln=function(e){return this.words[0]&e},o.prototype.bincn=function(e){n("number"===typeof e);var t=e%26,r=(e-t)/26,i=1<>>26,s&=67108863,this.words[a]=s}return 0!==o&&(this.words[a]=o,this.length++),this},o.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},o.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(),this.length>1)t=1;else{r&&(e=-e),n(e<=67108863,"Number is too big");var i=0|this.words[0];t=i===e?0:ie.length)return 1;if(this.length=0;r--){var n=0|this.words[r],i=0|e.words[r];if(n!==i){ni&&(t=1);break}}return t},o.prototype.gtn=function(e){return 1===this.cmpn(e)},o.prototype.gt=function(e){return 1===this.cmp(e)},o.prototype.gten=function(e){return this.cmpn(e)>=0},o.prototype.gte=function(e){return this.cmp(e)>=0},o.prototype.ltn=function(e){return-1===this.cmpn(e)},o.prototype.lt=function(e){return-1===this.cmp(e)},o.prototype.lten=function(e){return this.cmpn(e)<=0},o.prototype.lte=function(e){return this.cmp(e)<=0},o.prototype.eqn=function(e){return 0===this.cmpn(e)},o.prototype.eq=function(e){return 0===this.cmp(e)},o.red=function(e){return new E(e)},o.prototype.toRed=function(e){return n(!this.red,"Already a number in reduction context"),n(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},o.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},o.prototype._forceRed=function(e){return this.red=e,this},o.prototype.forceRed=function(e){return n(!this.red,"Already a number in reduction context"),this._forceRed(e)},o.prototype.redAdd=function(e){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},o.prototype.redIAdd=function(e){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},o.prototype.redSub=function(e){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},o.prototype.redISub=function(e){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},o.prototype.redShl=function(e){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},o.prototype.redMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},o.prototype.redIMul=function(e){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},o.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},o.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},o.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},o.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},o.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},o.prototype.redPow=function(e){return n(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var b={k256:null,p224:null,p192:null,p25519:null};function w(e,t){this.name=e,this.p=new o(t,16),this.n=this.p.bitLength(),this.k=new o(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function _(){w.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function C(){w.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function M(){w.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function x(){w.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(e){if("string"===typeof e){var t=o._prime(e);this.m=t.p,this.prime=t}else n(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function S(e){E.call(this,e),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new o(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}w.prototype._tmp=function(){var e=new o(null);return e.words=new Array(Math.ceil(this.n/13)),e},w.prototype.ireduce=function(e){var t,r=e;do{this.split(r,this.tmp),t=(r=(r=this.imulK(r)).iadd(this.tmp)).bitLength()}while(t>this.n);var n=t0?r.isub(this.p):void 0!==r.strip?r.strip():r._strip(),r},w.prototype.split=function(e,t){e.iushrn(this.n,0,t)},w.prototype.imulK=function(e){return e.imul(this.k)},i(_,w),_.prototype.split=function(e,t){for(var r=Math.min(e.length,9),n=0;n>>22,i=o}i>>>=22,e.words[n-10]=i,0===i&&e.length>10?e.length-=10:e.length-=9},_.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>>=26,e.words[r]=i,t=n}return 0!==t&&(e.words[e.length++]=t),e},o._prime=function(e){if(b[e])return b[e];var t;if("k256"===e)t=new _;else if("p224"===e)t=new C;else if("p192"===e)t=new M;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new x}return b[e]=t,t},E.prototype._verify1=function(e){n(0===e.negative,"red works only with positives"),n(e.red,"red works only with red numbers")},E.prototype._verify2=function(e,t){n(0===(e.negative|t.negative),"red works only with positives"),n(e.red&&e.red===t.red,"red works only with red numbers")},E.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(l(e,e.umod(this.m)._forceRed(this)),e)},E.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},E.prototype.add=function(e,t){this._verify2(e,t);var r=e.add(t);return r.cmp(this.m)>=0&&r.isub(this.m),r._forceRed(this)},E.prototype.iadd=function(e,t){this._verify2(e,t);var r=e.iadd(t);return r.cmp(this.m)>=0&&r.isub(this.m),r},E.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)},E.prototype.isub=function(e,t){this._verify2(e,t);var r=e.isub(t);return r.cmpn(0)<0&&r.iadd(this.m),r},E.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},E.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},E.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},E.prototype.isqr=function(e){return this.imul(e,e.clone())},E.prototype.sqr=function(e){return this.mul(e,e)},E.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(n(t%2===1),3===t){var r=this.m.add(new o(1)).iushrn(2);return this.pow(e,r)}for(var i=this.m.subn(1),a=0;!i.isZero()&&0===i.andln(1);)a++,i.iushrn(1);n(!i.isZero());var s=new o(1).toRed(this),u=s.redNeg(),l=this.m.subn(1).iushrn(1),c=this.m.bitLength();for(c=new o(2*c*c).toRed(this);0!==this.pow(c,l).cmp(u);)c.redIAdd(u);for(var f=this.pow(c,i),h=this.pow(e,i.addn(1).iushrn(1)),d=this.pow(e,i),p=a;0!==d.cmp(s);){for(var m=d,v=0;0!==m.cmp(s);v++)m=m.redSqr();n(v=0;n--){for(var l=t.words[n],c=u-1;c>=0;c--){var f=l>>c&1;i!==r[0]&&(i=this.sqr(i)),0!==f||0!==a?(a<<=1,a|=f,(4===++s||0===n&&0===c)&&(i=this.mul(i,r[a]),s=0,a=0)):s=0}u=26}return i},E.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},E.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},o.mont=function(e){return new S(e)},i(S,E),S.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},S.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},S.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 i.cmp(this.m)>=0?o=i.isub(this.m):i.cmpn(0)<0&&(o=i.iadd(this.m)),o._forceRed(this)},S.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new o(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),a=i;return i.cmp(this.m)>=0?a=i.isub(this.m):i.cmpn(0)<0&&(a=i.iadd(this.m)),a._forceRed(this)},S.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e,this)}).call(this,r(111)(e))},function(e,t,r){"use strict";var n=r(161),i=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=f;var o=r(138);o.inherits=r(28);var a=r(276),s=r(208);o.inherits(f,a);for(var u=i(s.prototype),l=0;l40)throw new Error('"version" should be in range from 1 to 40');return 4*e+17},t.getSymbolTotalCodewords=function(e){return n[e]},t.getBCHDigit=function(e){for(var t=0;0!==e;)t++,e>>>=1;return t},t.setToSJISFunction=function(e){if("function"!==typeof e)throw new Error('"toSJISFunc" is not a valid function.');r=e},t.isKanjiModeEnabled=function(){return"undefined"!==typeof r},t.toSJIS=function(e){return r(e)}},function(e,t,r){var n=r(338),i=r(339);t.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},t.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},t.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},t.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},t.MIXED={bit:-1},t.getCharCountIndicator=function(e,t){if(!e.ccBits)throw new Error("Invalid mode: "+e);if(!n.isValid(t))throw new Error("Invalid version: "+t);return t>=1&&t<10?e.ccBits[0]:t<27?e.ccBits[1]:e.ccBits[2]},t.getBestModeForData=function(e){return i.testNumeric(e)?t.NUMERIC:i.testAlphanumeric(e)?t.ALPHANUMERIC:i.testKanji(e)?t.KANJI:t.BYTE},t.toString=function(e){if(e&&e.id)return e.id;throw new Error("Invalid mode")},t.isValid=function(e){return e&&e.bit&&e.ccBits},t.from=function(e,r){if(t.isValid(e))return e;try{return function(e){if("string"!==typeof e)throw new Error("Param is not a string");switch(e.toLowerCase()){case"numeric":return t.NUMERIC;case"alphanumeric":return t.ALPHANUMERIC;case"kanji":return t.KANJI;case"byte":return t.BYTE;default:throw new Error("Unknown mode: "+e)}}(e)}catch(n){return r}}},function(e,t){e.exports={InvalidNumberOfSolidityArgs:function(){return new Error("Invalid number of arguments to Solidity function")},InvalidNumberOfRPCParams:function(){return new Error("Invalid number of input parameters to RPC method")},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")}}},function(e,t,r){var n=r(40),i=r(101),o=function(e){this.name=e.name,this.call=e.call,this.params=e.params||0,this.inputFormatter=e.inputFormatter,this.outputFormatter=e.outputFormatter,this.requestManager=null};o.prototype.setRequestManager=function(e){this.requestManager=e},o.prototype.getCall=function(e){return n.isFunction(this.call)?this.call(e):this.call},o.prototype.extractCallback=function(e){if(n.isFunction(e[e.length-1]))return e.pop()},o.prototype.validateArgs=function(e){if(e.length!==this.params)throw i.InvalidNumberOfRPCParams()},o.prototype.formatInput=function(e){return this.inputFormatter?this.inputFormatter.map((function(t,r){return t?t(e[r]):e[r]})):e},o.prototype.formatOutput=function(e){return this.outputFormatter&&e?this.outputFormatter(e):e},o.prototype.toPayload=function(e){var t=this.getCall(e),r=this.extractCallback(e),n=this.formatInput(e);return this.validateArgs(n),{method:t,params:n,callback:r}},o.prototype.attachToObject=function(e){var t=this.buildCall();t.call=this.call;var r=this.name.split(".");r.length>1?(e[r[0]]=e[r[0]]||{},e[r[0]][r[1]]=t):e[r[0]]=t},o.prototype.buildCall=function(){var e=this,t=function(){var t=e.toPayload(Array.prototype.slice.call(arguments));return t.callback?e.requestManager.sendAsync(t,(function(r,n){t.callback(r,e.formatOutput(n))})):e.formatOutput(e.requestManager.send(t))};return t.request=this.request.bind(this),t},o.prototype.request=function(){var e=this.toPayload(Array.prototype.slice.call(arguments));return e.format=this.formatOutput.bind(this),e},e.exports=o},,function(e,t,r){"use strict";r.r(t);var n=r(2),i=r.n(n),o=r(8),a=r.n(o),s=r(59),u=r.n(s),l=r(3),c=r.n(l),f=r(7),h=r.n(f),d=r(4),p=r.n(d),m=r(5),v=r.n(m),g=r(0),y=r.n(g),b=r(6),w=r.n(b),_=r(380),C=r.n(_),M=r(9),x=r.n(M),E=function(e){function t(e){c()(this,t);var r=p()(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));S.call(r);var n="checked"in e?e.checked:e.defaultChecked;return r.state={checked:n},r}return v()(t,e),h()(t,[{key:"componentWillReceiveProps",value:function(e){"checked"in e&&this.setState({checked:e.checked})}},{key:"shouldComponentUpdate",value:function(){for(var e=arguments.length,t=Array(e),r=0;r=0||(i[r]=e[r]);return i}r.d(t,"a",(function(){return n}))},function(e,t,r){var n=r(86),i=r(133);e.exports=r(87)?function(e,t,r){return n.f(e,t,i(1,r))}:function(e,t,r){return e[t]=r,e}},function(e,t,r){var n=r(109);e.exports=function(e){if(!n(e))throw TypeError(e+" is not an object!");return e}},function(e,t){e.exports=function(e){return"object"===typeof e?null!==e:"function"===typeof e}},function(e,t){e.exports=function(e){try{return!!e()}catch(t){return!0}}},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,r){"use strict";(function(t,n){var i=65536,o=4294967295;var a=r(29).Buffer,s=t.crypto||t.msCrypto;s&&s.getRandomValues?e.exports=function(e,t){if(e>o)throw new RangeError("requested too many random bytes");var r=a.allocUnsafe(e);if(e>0)if(e>i)for(var u=0;u>5===6?2:e>>4===14?3:e>>3===30?4:e>>6===2?-1:-2}function s(e){var t=this.lastTotal-this.lastNeed,r=function(e,t,r){if(128!==(192&t[0]))return e.lastNeed=0,"\ufffd";if(e.lastNeed>1&&t.length>1){if(128!==(192&t[1]))return e.lastNeed=1,"\ufffd";if(e.lastNeed>2&&t.length>2&&128!==(192&t[2]))return e.lastNeed=2,"\ufffd"}}(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(n>=55296&&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 l(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 f(e){var t=e&&e.length?this.write(e):"";return this.lastNeed?t+this.lastChar.toString("base64",0,3-this.lastNeed):t}function h(e){return e.toString(this.encoding)}function d(e){return e&&e.length?this.write(e):""}t.StringDecoder=o,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=0)return i>0&&(e.lastNeed=i-1),i;if(--n=0)return i>0&&(e.lastNeed=i-2),i;if(--n=0)return i>0&&(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}},function(e,t,r){var n=r(29).Buffer;function i(e,t){this._block=n.alloc(e),this._finalSize=t,this._blockSize=e,this._len=0}i.prototype.update=function(e,t){"string"===typeof e&&(t=t||"utf8",e=n.from(e,t));for(var r=this._block,i=this._blockSize,o=e.length,a=this._len,s=0;s=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},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},,function(e,t,r){"use strict";var n={};function i(e,t,r){r||(r=Error);var i=function(e){var r,n;function i(r,n,i){return e.call(this,function(e,r,n){return"string"===typeof t?t:t(e,r,n)}(r,n,i))||this}return n=e,(r=i).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,i}(r);i.prototype.name=r.name,i.prototype.code=e,n[e]=i}function o(e,t){if(Array.isArray(e)){var r=e.length;return e=e.map((function(e){return String(e)})),r>2?"one of ".concat(t," ").concat(e.slice(0,r-1).join(", "),", or ")+e[r-1]:2===r?"one of ".concat(t," ").concat(e[0]," or ").concat(e[1]):"of ".concat(t," ").concat(e[0])}return"of ".concat(t," ").concat(String(e))}i("ERR_INVALID_OPT_VALUE",(function(e,t){return'The value "'+t+'" is invalid for option "'+e+'"'}),TypeError),i("ERR_INVALID_ARG_TYPE",(function(e,t,r){var n,i,a,s;if("string"===typeof t&&(i="not ",t.substr(!a||a<0?0:+a,i.length)===i)?(n="must not be",t=t.replace(/^not /,"")):n="must be",function(e,t,r){return(void 0===r||r>e.length)&&(r=e.length),e.substring(r-t.length,r)===t}(e," argument"))s="The ".concat(e," ").concat(n," ").concat(o(t,"type"));else{var u=function(e,t,r){return"number"!==typeof r&&(r=0),!(r+t.length>e.length)&&-1!==e.indexOf(t,r)}(e,".")?"property":"argument";s='The "'.concat(e,'" ').concat(u," ").concat(n," ").concat(o(t,"type"))}return s+=". Received type ".concat(typeof r)}),TypeError),i("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),i("ERR_METHOD_NOT_IMPLEMENTED",(function(e){return"The "+e+" method is not implemented"})),i("ERR_STREAM_PREMATURE_CLOSE","Premature close"),i("ERR_STREAM_DESTROYED",(function(e){return"Cannot call "+e+" after a stream was destroyed"})),i("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),i("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),i("ERR_STREAM_WRITE_AFTER_END","write after end"),i("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),i("ERR_UNKNOWN_ENCODING",(function(e){return"Unknown encoding: "+e}),TypeError),i("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),e.exports.codes=n},function(e,t,r){"use strict";(function(t){var n=Object.keys||function(e){var t=[];for(var r in e)t.push(r);return t};e.exports=l;var i=r(322),o=r(326);r(52)(l,i);for(var a=n(o.prototype),s=0;s=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},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},e.exports=i},function(e,t,r){"use strict";var n=r(226);o.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()}catch(t){return!1}}();var i=o.TYPED_ARRAY_SUPPORT?2147483647:1073741823;function o(e,t,r){return o.TYPED_ARRAY_SUPPORT||this instanceof o?"number"===typeof e?u(this,e):function(e,t,r,n){if("number"===typeof t)throw new TypeError('"value" argument must not be a number');if("undefined"!==typeof ArrayBuffer&&t instanceof ArrayBuffer)return function(e,t,r,n){if(r<0||t.byteLength=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return 0|e}function s(e,t){var r;return o.TYPED_ARRAY_SUPPORT?(r=new Uint8Array(t)).__proto__=o.prototype:(null===(r=e)&&(r=new o(t)),r.length=t),r}function u(e,t){var r=s(e,t<0?0:0|a(t));if(!o.TYPED_ARRAY_SUPPORT)for(var n=0;n55295&&r<57344){if(!i){if(r>56319){(t-=3)>-1&&o.push(239,191,189);continue}if(a+1===n){(t-=3)>-1&&o.push(239,191,189);continue}i=r;continue}if(r<56320){(t-=3)>-1&&o.push(239,191,189),i=r;continue}r=65536+(i-55296<<10|r-56320)}else i&&(t-=3)>-1&&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 f(e){return o.isBuffer(e)?e.length:"undefined"!==typeof ArrayBuffer&&"function"===typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer)?e.byteLength:("string"!==typeof e&&(e=""+e),0===e.length?0:c(e).length)}o.TYPED_ARRAY_SUPPORT&&(o.prototype.__proto__=Uint8Array.prototype,o.__proto__=Uint8Array,"undefined"!==typeof Symbol&&Symbol.species&&o[Symbol.species]===o&&Object.defineProperty(o,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1})),o.prototype.write=function(e,t,r){void 0===t?(r=this.length,t=0):void 0===r&&"string"===typeof t?(r=this.length,t=0):isFinite(t)&&(t|=0,isFinite(r)?r|=0:r=void 0);var n=this.length-t;if((void 0===r||r>n)&&(r=n),e.length>0&&(r<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");return function(e,t,r,n){return function(e,t,r,n){for(var i=0;i=t.length||i>=e.length);++i)t[i+r]=e[i];return i}(c(t,e.length-r),e,r,n)}(this,e,t,r)},o.prototype.slice=function(e,t){var r,n=this.length;if((e=~~e)<0?(e+=n)<0&&(e=0):e>n&&(e=n),(t=void 0===t?n:~~t)<0?(t+=n)<0&&(t=0):t>n&&(t=n),t=e.length&&(t=e.length),t||(t=0),n>0&&n=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),e.length-t=0;--i)e[i+t]=this[i+r];else if(a<1e3||!o.TYPED_ARRAY_SUPPORT)for(i=0;i>>=0,r=void 0===r?this.length:r>>>0,e||(e=0),"number"===typeof e)for(i=t;i>>2]>>>24-o%4*8&255)<<16|(t[o+1>>>2]>>>24-(o+1)%4*8&255)<<8|t[o+2>>>2]>>>24-(o+2)%4*8&255,s=0;s<4&&o+.75*s>>6*(3-s)&63));var u=n.charAt(64);if(u)for(;i.length%4;)i.push(u);return i.join("")},parse:function(e){var r=e.length,n=this._map,i=this._reverseMap;if(!i){i=this._reverseMap=[];for(var o=0;o>>6-a%4*2;i[o>>>2]|=(s|u)<<24-o%4*8,o++}return t.create(i,o)}(e,r,i)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}}(),i.enc.Base64)}()},function(e,t,r){!function(t,n){var i;e.exports=(i=r(34),function(e){var t=i,r=t.lib,n=r.WordArray,o=r.Hasher,a=t.algo,s=[];!function(){for(var t=0;t<64;t++)s[t]=4294967296*e.abs(e.sin(t+1))|0}();var u=a.MD5=o.extend({_doReset:function(){this._hash=new n.init([1732584193,4023233417,2562383102,271733878])},_doProcessBlock:function(e,t){for(var r=0;r<16;r++){var n=t+r,i=e[n];e[n]=16711935&(i<<8|i>>>24)|4278255360&(i<<24|i>>>8)}var o=this._hash.words,a=e[t+0],u=e[t+1],d=e[t+2],p=e[t+3],m=e[t+4],v=e[t+5],g=e[t+6],y=e[t+7],b=e[t+8],w=e[t+9],_=e[t+10],C=e[t+11],M=e[t+12],x=e[t+13],E=e[t+14],S=e[t+15],k=o[0],A=o[1],I=o[2],O=o[3];k=l(k,A,I,O,a,7,s[0]),O=l(O,k,A,I,u,12,s[1]),I=l(I,O,k,A,d,17,s[2]),A=l(A,I,O,k,p,22,s[3]),k=l(k,A,I,O,m,7,s[4]),O=l(O,k,A,I,v,12,s[5]),I=l(I,O,k,A,g,17,s[6]),A=l(A,I,O,k,y,22,s[7]),k=l(k,A,I,O,b,7,s[8]),O=l(O,k,A,I,w,12,s[9]),I=l(I,O,k,A,_,17,s[10]),A=l(A,I,O,k,C,22,s[11]),k=l(k,A,I,O,M,7,s[12]),O=l(O,k,A,I,x,12,s[13]),I=l(I,O,k,A,E,17,s[14]),k=c(k,A=l(A,I,O,k,S,22,s[15]),I,O,u,5,s[16]),O=c(O,k,A,I,g,9,s[17]),I=c(I,O,k,A,C,14,s[18]),A=c(A,I,O,k,a,20,s[19]),k=c(k,A,I,O,v,5,s[20]),O=c(O,k,A,I,_,9,s[21]),I=c(I,O,k,A,S,14,s[22]),A=c(A,I,O,k,m,20,s[23]),k=c(k,A,I,O,w,5,s[24]),O=c(O,k,A,I,E,9,s[25]),I=c(I,O,k,A,p,14,s[26]),A=c(A,I,O,k,b,20,s[27]),k=c(k,A,I,O,x,5,s[28]),O=c(O,k,A,I,d,9,s[29]),I=c(I,O,k,A,y,14,s[30]),k=f(k,A=c(A,I,O,k,M,20,s[31]),I,O,v,4,s[32]),O=f(O,k,A,I,b,11,s[33]),I=f(I,O,k,A,C,16,s[34]),A=f(A,I,O,k,E,23,s[35]),k=f(k,A,I,O,u,4,s[36]),O=f(O,k,A,I,m,11,s[37]),I=f(I,O,k,A,y,16,s[38]),A=f(A,I,O,k,_,23,s[39]),k=f(k,A,I,O,x,4,s[40]),O=f(O,k,A,I,a,11,s[41]),I=f(I,O,k,A,p,16,s[42]),A=f(A,I,O,k,g,23,s[43]),k=f(k,A,I,O,w,4,s[44]),O=f(O,k,A,I,M,11,s[45]),I=f(I,O,k,A,S,16,s[46]),k=h(k,A=f(A,I,O,k,d,23,s[47]),I,O,a,6,s[48]),O=h(O,k,A,I,y,10,s[49]),I=h(I,O,k,A,E,15,s[50]),A=h(A,I,O,k,v,21,s[51]),k=h(k,A,I,O,M,6,s[52]),O=h(O,k,A,I,p,10,s[53]),I=h(I,O,k,A,_,15,s[54]),A=h(A,I,O,k,u,21,s[55]),k=h(k,A,I,O,b,6,s[56]),O=h(O,k,A,I,S,10,s[57]),I=h(I,O,k,A,g,15,s[58]),A=h(A,I,O,k,x,21,s[59]),k=h(k,A,I,O,m,6,s[60]),O=h(O,k,A,I,C,10,s[61]),I=h(I,O,k,A,d,15,s[62]),A=h(A,I,O,k,w,21,s[63]),o[0]=o[0]+k|0,o[1]=o[1]+A|0,o[2]=o[2]+I|0,o[3]=o[3]+O|0},_doFinalize:function(){var t=this._data,r=t.words,n=8*this._nDataBytes,i=8*t.sigBytes;r[i>>>5]|=128<<24-i%32;var o=e.floor(n/4294967296),a=n;r[15+(i+64>>>9<<4)]=16711935&(o<<8|o>>>24)|4278255360&(o<<24|o>>>8),r[14+(i+64>>>9<<4)]=16711935&(a<<8|a>>>24)|4278255360&(a<<24|a>>>8),t.sigBytes=4*(r.length+1),this._process();for(var s=this._hash,u=s.words,l=0;l<4;l++){var c=u[l];u[l]=16711935&(c<<8|c>>>24)|4278255360&(c<<24|c>>>8)}return s},clone:function(){var e=o.clone.call(this);return e._hash=this._hash.clone(),e}});function l(e,t,r,n,i,o,a){var s=e+(t&r|~t&n)+i+a;return(s<>>32-o)+t}function c(e,t,r,n,i,o,a){var s=e+(t&n|r&~n)+i+a;return(s<>>32-o)+t}function f(e,t,r,n,i,o,a){var s=e+(t^r^n)+i+a;return(s<>>32-o)+t}function h(e,t,r,n,i,o,a){var s=e+(r^(t|~n))+i+a;return(s<>>32-o)+t}t.MD5=o._createHelper(u),t.HmacMD5=o._createHmacHelper(u)}(Math),i.MD5)}()},function(e,t,r){!function(t,n,i){var o;e.exports=(o=r(34),r(238),r(239),function(){var e=o,t=e.lib,r=t.Base,n=t.WordArray,i=e.algo,a=i.MD5,s=i.EvpKDF=r.extend({cfg:r.extend({keySize:4,hasher:a,iterations:1}),init:function(e){this.cfg=this.cfg.extend(e)},compute:function(e,t){for(var r=this.cfg,i=r.hasher.create(),o=n.create(),a=o.words,s=r.keySize,u=r.iterations;a.lengthd?d+"+":u,p&&(u="");var y=(0,l.default)((e={},(0,i.default)(e,a+"-dot",p),(0,i.default)(e,a+"-dot-large",p&&"large"===f),(0,i.default)(e,a+"-text",!p&&!m),(0,i.default)(e,a+"-corner",m),(0,i.default)(e,a+"-corner-large",m&&"large"===f),e)),b=(0,l.default)(a,o,(t={},(0,i.default)(t,a+"-not-a-wrapper",!s),(0,i.default)(t,a+"-corner-wrapper",m),(0,i.default)(t,a+"-hot",!!v),(0,i.default)(t,a+"-corner-wrapper-large",m&&"large"===f),t));return c.createElement("span",{className:b},s,(u||p)&&c.createElement("sup",(0,n.default)({className:y},g),u))}}]),t}(c.Component);t.default=d,d.defaultProps={prefixCls:"am-badge",size:"small",overflowCount:99,dot:!1,corner:!1},e.exports=t.default},function(e,t,r){var n=r(634),i=r(635),o=r(652),a=r(653);function s(e,t,r,o,a){var s=[].slice.call(arguments,1),u=s.length,l="function"===typeof s[u-1];if(!l&&!n())throw new Error("Callback required as last argument");if(!l){if(u<1)throw new Error("Too few arguments provided");return 1===u?(r=t,t=o=void 0):2!==u||t.getContext||(o=r,r=t,t=void 0),new Promise((function(n,a){try{var s=i.create(r,o);n(e(s,t,o))}catch(u){a(u)}}))}if(u<2)throw new Error("Too few arguments provided");2===u?(a=r,r=t,t=o=void 0):3===u&&(t.getContext&&"undefined"===typeof a?(a=o,o=void 0):(a=o,o=r,r=t,t=void 0));try{var c=i.create(r,o);a(null,e(c,t,o))}catch(f){a(f)}}t.create=i.create,t.toCanvas=s.bind(null,o.render),t.toDataURL=s.bind(null,o.renderToDataURL),t.toString=s.bind(null,(function(e,t,r){return a.render(e,r)}))},function(e,t,r){"use strict";var n=function(e){};e.exports=function(e,t,r,i,o,a,s,u){if(n(t),!e){var l;if(void 0===t)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[r,i,o,a,s,u],f=0;(l=new Error(t.replace(/%s/g,(function(){return c[f++]})))).name="Invariant Violation"}throw l.framesToPop=1,l}}},function(e,t,r){"use strict";var n=r(2),i=r.n(n),o=r(3),a=r.n(o),s=r(7),u=r.n(s),l=r(4),c=r.n(l),f=r(5),h=r.n(f),d=r(0),p=r.n(d),m=1,v=2,g=4,y=8,b=16,w=v|g,_=y|b,C=w|_,M={time:251},x={threshold:10,velocity:.3};function E(e,t){return Math.sqrt(e*e+t*t)}function S(e,t){var r=Math.atan2(t,e);return 180/(Math.PI/r)}function k(){return Date.now()}function A(e){if(!(e.length<2)){var t=e[0],r=t.x,n=t.y,i=e[1],o=i.x-r,a=i.y-n;return{x:o,y:a,z:E(o,a),angle:S(o,a)}}}function I(e,t){return e+t[0].toUpperCase()+t.slice(1)}function O(e){var t=void 0;switch(e){case m:break;case v:t="left";break;case g:t="right";break;case y:t="up";break;case b:t="down"}return t}var P={all:C,vertical:_,horizontal:w},T=function(e){function t(e){a()(this,t);var r=c()(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.state={},r.triggerEvent=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i2?n-2:0),o=2;o2?n-2:0),o=2;o2?n-2:0),o=2;o1&&r.triggerEvent("onPinchOut"),a<1&&r.triggerEvent("onPinchIn")),r.triggerCombineEvent.apply(r,[e,t].concat(i))},r.initPressTimer=function(){r.cleanPressTimer(),r.pressTimer=setTimeout((function(){r.setGestureState({press:!0}),r.triggerEvent("onPress")}),M.time)},r.cleanPressTimer=function(){r.pressTimer&&clearTimeout(r.pressTimer)},r.setGestureState=function(e){r.gesture||(r.gesture={}),r.gesture.touches&&(r.gesture.preTouches=r.gesture.touches),r.gesture=i()({},r.gesture,e)},r.getGestureState=function(){return r.gesture?i()({},r.gesture):r.gesture},r.cleanGestureState=function(){delete r.gesture},r.getTouches=function(e){return Array.prototype.slice.call(e.touches).map((function(e){return{x:e.screenX,y:e.screenY}}))},r.triggerUserCb=function(e,t){var n=I("onTouch",e);n in r.props&&r.props[n](t)},r._handleTouchStart=function(e){r.triggerUserCb("start",e),r.event=e,e.touches.length>1&&e.preventDefault(),r.initGestureStatus(e),r.initPressTimer(),r.checkIfMultiTouchStart()},r.initGestureStatus=function(e){r.cleanGestureState();var t=r.getTouches(e),n=k(),i=A(t);r.setGestureState({startTime:n,startTouches:t,startMutliFingerStatus:i,time:n,touches:t,mutliFingerStatus:i,srcEvent:r.event})},r.checkIfMultiTouchStart=function(){var e=r.props,t=e.enablePinch,n=e.enableRotate,i=r.gesture.touches;if(i.length>1&&(t||n)){if(t){var o=A(i);r.setGestureState({startMutliFingerStatus:o,pinch:!0,scale:1}),r.triggerCombineEvent("onPinch","start")}n&&(r.setGestureState({rotate:!0,rotation:0}),r.triggerCombineEvent("onRotate","start"))}},r._handleTouchMove=function(e){r.triggerUserCb("move",e),r.event=e,r.gesture&&(r.cleanPressTimer(),r.updateGestureStatus(e),r.checkIfSingleTouchMove(),r.checkIfMultiTouchMove())},r.checkIfMultiTouchMove=function(){var e=r.gesture,t=e.pinch,n=e.rotate,i=e.touches,o=e.startMutliFingerStatus,a=e.mutliFingerStatus;if(t||n){if(i.length<2)return r.setGestureState({pinch:!1,rotate:!1}),t&&r.triggerCombineEvent("onPinch","cancel"),void(n&&r.triggerCombineEvent("onRotate","cancel"));if(t){var s=a.z/o.z;r.setGestureState({scale:s}),r.triggerPinchEvent("onPinch","move")}if(n){var u=function(e,t){var r=e.angle;return t.angle-r}(o,a);r.setGestureState({rotation:u}),r.triggerCombineEvent("onRotate","move")}}},r.allowGesture=function(){return e=r.gesture.direction,!!(r.directionSetting&e);var e},r.checkIfSingleTouchMove=function(){var e=r.gesture,t=e.pan,n=e.touches,i=e.moveStatus,o=e.preTouches,a=e.availablePan,s=void 0===a||a;if(n.length>1)return r.setGestureState({pan:!1}),void(t&&r.triggerCombineEvent("onPan","cancel"));if(i&&s){var u=function(e,t){var r=e.x,n=e.y,i=t.x-r,o=t.y-n;return 0===i&&0===o?m:Math.abs(i)>=Math.abs(o)?i<0?v:g:o<0?y:b}(o[0],n[0]);r.setGestureState({direction:u});var l=O(u);if(!r.allowGesture())return void(t||r.setGestureState({availablePan:!1}));t?(r.triggerCombineEvent("onPan",l),r.triggerSubEvent("onPan","move")):(r.triggerCombineEvent("onPan","start"),r.setGestureState({pan:!0,availablePan:!0}))}},r.checkIfMultiTouchEnd=function(e){var t=r.gesture,n=t.pinch,i=t.rotate;n&&r.triggerCombineEvent("onPinch",e),i&&r.triggerCombineEvent("onRotate",e)},r.updateGestureStatus=function(e){var t=k();if(r.setGestureState({time:t}),e.touches&&e.touches.length){var n=r.gesture,i=n.startTime,o=n.startTouches,a=n.pinch,s=n.rotate,u=r.getTouches(e),l=function(e,t,r){var n=e[0],i=n.x,o=n.y,a=t[0],s=a.x-i,u=a.y-o,l=E(s,u);return{x:s,y:u,z:l,time:r,velocity:l/r,angle:S(s,u)}}(o,u,t-i),c=void 0;(a||s)&&(c=A(u)),r.setGestureState({touches:u,mutliFingerStatus:c,moveStatus:l})}},r._handleTouchEnd=function(e){r.triggerUserCb("end",e),r.event=e,r.gesture&&(r.cleanPressTimer(),r.updateGestureStatus(e),r.doSingleTouchEnd("end"),r.checkIfMultiTouchEnd("end"))},r._handleTouchCancel=function(e){r.triggerUserCb("cancel",e),r.event=e,r.gesture&&(r.cleanPressTimer(),r.updateGestureStatus(e),r.doSingleTouchEnd("cancel"),r.checkIfMultiTouchEnd("cancel"))},r.triggerAllowEvent=function(e,t){r.allowGesture()?r.triggerCombineEvent(e,t):r.triggerSubEvent(e,t)},r.doSingleTouchEnd=function(e){var t=r.gesture,n=t.moveStatus,i=t.pinch,o=t.rotate,a=t.press,s=t.pan,u=t.direction;if(!i&&!o){if(n){var l=function(e,t){return Math.abs(e)>=x.threshold&&Math.abs(t)>x.velocity}(n.z,n.velocity);if(r.setGestureState({swipe:l}),s&&r.triggerAllowEvent("onPan",e),l){var c=O(u);return void r.triggerAllowEvent("onSwipe",c)}}a?r.triggerEvent("onPressUp"):r.triggerEvent("onTap")}},r.getTouchAction=function(){var e=r.props,t=e.enablePinch,n=e.enableRotate,i=r.directionSetting;return t||n||i===C?"pan-x pan-y":i===_?"pan-x":i===w?"pan-y":"auto"},r.directionSetting=P[e.direction],r}return h()(t,e),u()(t,[{key:"componentWillUnmount",value:function(){this.cleanPressTimer()}},{key:"render",value:function(){var e=this.props.children,t=p.a.Children.only(e),r=this.getTouchAction(),n={onTouchStart:this._handleTouchStart,onTouchMove:this._handleTouchMove,onTouchCancel:this._handleTouchCancel,onTouchEnd:this._handleTouchEnd};return p.a.cloneElement(t,i()({},n,{style:i()({touchAction:r},t.props.style||{})}))}}]),t}(d.Component);t.a=T;T.defaultProps={enableRotate:!1,enablePinch:!1,direction:"all"}},function(e,t,r){"use strict";t.__esModule=!0;var n=o(r(626)),i=o(r(629));function o(e){return e&&e.__esModule?e:{default:e}}t.default=function e(t,r,o){null===t&&(t=Function.prototype);var a=(0,i.default)(t,r);if(void 0===a){var s=(0,n.default)(t);return null===s?void 0:e(s,r,o)}if("value"in a)return a.value;var u=a.get;return void 0!==u?u.call(o):void 0}},function(e,t,r){"use strict";function n(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}r.d(t,"a",(function(){return n}))},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r)){var n=Object.defineProperty&&Object.getOwnPropertyDescriptor?Object.getOwnPropertyDescriptor(e,r):{};n.get||n.set?Object.defineProperty(t,r,n):t[r]=e[r]}return t.default=e,t}(r(0)),i=a(r(9)),o=a(r(761));function a(e){return e&&e.__esModule?e:{default:e}}function s(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function u(){return(u=Object.assign||function(e){for(var t=1;t2&&void 0!==arguments[2]?arguments[2]:.3;e!==n&&(e=n,i&&!r.props.noAnimate&&s(r.contentRef.style,"cubic-bezier(0,0,0.2,1.15) ".concat(i,"s")),a(r.contentRef.style,"translate3d(0,".concat(-n,"px,0)")),setTimeout((function(){r.scrollingComplete(),r.contentRef&&s(r.contentRef.style,"")}),1e3*+i))},l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:30,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100,r=0,n=0,i=0,o={record:function(o){var a=+new Date;i=(o-n)/(a-r),a-r>=e&&(i=a-r<=t?i:0,n=o,r=a)},getVelocity:function(e){return e!==n&&o.record(e),i}};return o}(),c=function(){o=!1;var t=e,n=(r.props.children.length-1)*r.itemHeight,i=.3,a=4*l.getVelocity(t);a&&(t=40*a+t,i=.1*Math.abs(a)),t%r.itemHeight!==0&&(t=Math.round(t/r.itemHeight)*r.itemHeight),t<0?t=0:t>n&&(t=n),u(0,t,i<.3?.3:i),r.onScrollChange()},f=function(r){i||(o=!0,n=r,t=e)},h=function(s){!i&&o&&(e=t-s+n,l.record(e),r.onScrollChange(),a(r.contentRef.style,"translate3d(0,".concat(-e,"px,0)")))};return{touchstart:function(e){return f(e.touches[0].pageY)},mousedown:function(e){return f(e.pageY)},touchmove:function(e){e.preventDefault(),h(e.touches[0].pageY)},mousemove:function(e){e.preventDefault(),h(e.pageY)},touchend:function(){return c()},touchcancel:function(){return c()},mouseup:function(){return c()},getValue:function(){return e},scrollTo:u,setDisabled:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];i=e}}}(),r.scrollTo=function(e){r.scrollHanders.scrollTo(0,e)},r.scrollToWithoutAnimation=function(e){r.scrollHanders.scrollTo(0,e,0)},r.fireValueChange=function(e){e!==r.state.selectedValue&&("selectedValue"in r.props||r.setState({selectedValue:e}),r.props.onValueChange&&r.props.onValueChange(e))},r.onScrollChange=function(){var e=r.scrollHanders.getValue();if(e>=0){var t=n.Children.toArray(r.props.children),i=r.props.computeChildIndex(e,r.itemHeight,t.length);if(r.scrollValue!==i){r.scrollValue=i;var o=t[i];o&&r.props.onScrollChange?r.props.onScrollChange(o.props.value):!o&&console.warn&&console.warn("child not found",t,i)}}},r.scrollingComplete=function(){var e=r.scrollHanders.getValue();e>=0&&r.props.doScrollingComplete(e,r.itemHeight,r.fireValueChange)};var o=r.props,a=o.selectedValue,s=o.defaultSelectedValue;if(void 0!==a)i=a;else if(void 0!==s)i=s;else{var u=n.Children.toArray(r.props.children);i=u&&u[0]&&u[0].props.value}return r.state={selectedValue:i},r}var r,o,a;return function(e,t){if("function"!==typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&h(e,t)}(t,e),r=t,(o=[{key:"componentDidMount",value:function(){var e=this,t=this.contentRef,r=this.indicatorRef,n=this.maskRef,i=this.rootRef,o=i.getBoundingClientRect().height,a=this.itemHeight=r.getBoundingClientRect().height,s=Math.floor(o/a);s%2===0&&s--,s--,s/=2,t.style.padding="".concat(a*s,"px 0"),r.style.top="".concat(a*s,"px"),n.style.backgroundSize="100% ".concat(a*s,"px"),this.scrollHanders.setDisabled(this.props.disabled),this.props.select(this.state.selectedValue,this.itemHeight,this.scrollTo);var u=this.passiveSupported(),l=!!u&&{passive:!1},c=!!u&&{passive:!0};Object.keys(this.scrollHanders).forEach((function(t){if(0===t.indexOf("touch")||0===t.indexOf("mouse")){var r=t.indexOf("move")>=0?l:c;i.addEventListener(t,e.scrollHanders[t],r)}}))}},{key:"componentWillUnmount",value:function(){var e=this;Object.keys(this.scrollHanders).forEach((function(t){0!==t.indexOf("touch")&&0!==t.indexOf("mouse")||e.rootRef.removeEventListener(t,e.scrollHanders[t])}))}},{key:"passiveSupported",value:function(){var e=!1;try{var t=Object.defineProperty({},"passive",{get:function(){e=!0}});window.addEventListener("test",null,t)}catch(r){}return e}},{key:"componentWillReceiveProps",value:function(e){var t=this;"selectedValue"in e&&this.state.selectedValue!==e.selectedValue&&this.setState({selectedValue:e.selectedValue},(function(){t.props.select(e.selectedValue,t.itemHeight,e.noAnimate?t.scrollToWithoutAnimation:t.scrollTo)})),this.scrollHanders.setDisabled(e.disabled)}},{key:"shouldComponentUpdate",value:function(e,t){return this.state.selectedValue!==t.selectedValue||this.props.children!==e.children}},{key:"componentDidUpdate",value:function(){this.props.select(this.state.selectedValue,this.itemHeight,this.scrollToWithoutAnimation)}},{key:"getValue",value:function(){if("selectedValue"in this.props)return this.props.selectedValue;var e=n.Children.toArray(this.props.children);return e&&e[0]&&e[0].props.value}},{key:"render",value:function(){var e,t=this,r=this.props,o=r.prefixCls,a=r.itemStyle,l=r.indicatorStyle,c=r.indicatorClassName,f=void 0===c?"":c,h=r.children,d=this.state.selectedValue,p="".concat(o,"-item"),m="".concat(p," ").concat(o,"-item-selected"),v=function(e){var t=e.props,r=t.className,i=void 0===r?"":r,o=t.style,s=t.value;return n.createElement("div",{style:u({},a,o),className:"".concat(d===s?m:p," ").concat(i),key:s},e.children||e.props.children)},g=n.Children?n.Children.map(h,v):[].concat(h).map(v),y=(s(e={},r.className,!!r.className),s(e,o,!0),e);return n.createElement("div",{className:(0,i.default)(y),ref:function(e){return t.rootRef=e},style:this.props.style},n.createElement("div",{className:"".concat(o,"-mask"),ref:function(e){return t.maskRef=e}}),n.createElement("div",{className:"".concat(o,"-indicator ").concat(f),ref:function(e){return t.indicatorRef=e},style:l}),n.createElement("div",{className:"".concat(o,"-content"),ref:function(e){return t.contentRef=e}},g))}}])&&l(r.prototype,o),a&&l(r,a),t}(n.Component);d.defaultProps={prefixCls:"rmc-picker"};var p=(0,o.default)(d);t.default=p},,function(e,t,r){"use strict";var n=r(3),i=r.n(n),o=r(7),a=r.n(o),s=r(4),u=r.n(s),l=r(5),c=r.n(l),f=r(0),h=r.n(f),d=r(6),p=r.n(d),m=r(9),v=r.n(m),g=function(){function e(e,t){for(var r=0;r-1?t.splice(r,1):t.push(e)}this.setActiveKey(t)}},{key:"getItems",value:function(){var e=this,t=this.state.activeKey,r=this.props,n=r.prefixCls,i=r.accordion,o=r.destroyInactivePanel,a=[];return f.Children.forEach(this.props.children,(function(r,s){if(r){var u=r.key||String(s),l=r.props,c=l.header,f=l.headerClass,d=l.disabled,p=!1;p=i?t[0]===u:t.indexOf(u)>-1;var m={key:u,header:c,headerClass:f,isActive:p,prefixCls:n,destroyInactivePanel:o,openAnimation:e.state.openAnimation,accordion:i,children:r.props.children,onItemClick:d?null:function(){return e.onClickItem(u)}};a.push(h.a.cloneElement(r,m))}})),a}},{key:"setActiveKey",value:function(e){"activeKey"in this.props||this.setState({activeKey:e}),this.props.onChange(this.props.accordion?e[0]:e)}},{key:"render",value:function(){var e,t=this.props,r=t.prefixCls,n=t.className,i=t.style,o=t.accordion,a=v()((P(e={},r,!0),P(e,n,!!n),e));return h.a.createElement("div",{className:a,style:i,role:o?"tablist":null},this.getItems())}}]),t}(f.Component);N.propTypes={children:p.a.any,prefixCls:p.a.string,activeKey:p.a.oneOfType([p.a.string,p.a.arrayOf(p.a.string)]),defaultActiveKey:p.a.oneOfType([p.a.string,p.a.arrayOf(p.a.string)]),openAnimation:p.a.object,onChange:p.a.func,accordion:p.a.bool,className:p.a.string,style:p.a.object,destroyInactivePanel:p.a.bool},N.defaultProps={prefixCls:"rc-collapse",onChange:function(){},accordion:!1,destroyInactivePanel:!1},N.Panel=S;var B=N,j=N.Panel,R=function(e){function t(){return i()(this,t),u()(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return c()(t,e),a()(t,[{key:"render",value:function(){return f.createElement(B,this.props)}}]),t}(f.Component);R.Panel=j,R.defaultProps={prefixCls:"am-accordion"};var D=r(8),F=r.n(D),L=r(2),z=r.n(L),U=r(21),H=r.n(U),q=r(91),V=r(25),Q=function(e){return Object.keys(e).reduce((function(t,r){return"aria-"!==r.substr(0,5)&&"data-"!==r.substr(0,5)&&"role"!==r||(t[r]=e[r]),t}),{})},K=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"===typeof Object.getOwnPropertySymbols){var i=0;for(n=Object.getOwnPropertySymbols(e);iu?u+"+":a,l&&(a="");var p=v()((e={},F()(e,i+"-dot",l),F()(e,i+"-dot-large",l&&"large"===s),F()(e,i+"-text",!l&&!c),F()(e,i+"-corner",c),F()(e,i+"-corner-large",c&&"large"===s),e)),m=v()(i,n,(t={},F()(t,i+"-not-a-wrapper",!o),F()(t,i+"-corner-wrapper",c),F()(t,i+"-hot",!!h),F()(t,i+"-corner-wrapper-large",c&&"large"===s),t));return f.createElement("span",{className:m},o,(a||l)&&f.createElement("sup",z()({className:p},d),a))}}]),t}(f.Component),Y=W;W.defaultProps={prefixCls:"am-badge",size:"small",overflowCount:99,dot:!1,corner:!1};var G=function(e){function t(){return i()(this,t),u()(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return c()(t,e),a()(t,[{key:"render",value:function(){var e,t=this.props,r=t.prefixCls,n=t.className,i=t.animating,o=t.toast,a=t.size,s=t.text,u=v()(r,n,(e={},F()(e,r+"-lg","large"===a),F()(e,r+"-sm","small"===a),F()(e,r+"-toast",!!o),e)),l=v()(r+"-spinner",F()({},r+"-spinner-lg",!!o||"large"===a));return i?o?f.createElement("div",{className:u},s?f.createElement("div",{className:r+"-content"},f.createElement("span",{className:l,"aria-hidden":"true"}),f.createElement("span",{className:r+"-toast"},s)):f.createElement("div",{className:r+"-content"},f.createElement("span",{className:l,"aria-label":"Loading"}))):s?f.createElement("div",{className:u},f.createElement("span",{className:l,"aria-hidden":"true"}),f.createElement("span",{className:r+"-tip"},s)):f.createElement("div",{className:u},f.createElement("span",{className:l,"aria-label":"loading"})):null}}]),t}(f.Component);G.defaultProps={prefixCls:"am-activity-indicator",animating:!0,size:"small",panelColor:"rgba(34,34,34,0.6)",toast:!1};var X={check:'',"check-circle":'',"check-circle-o":'',cross:'',"cross-circle":'',"cross-circle-o":'',left:'',right:'',down:'',up:'',loading:'',search:'',ellipsis:'',"ellipsis-circle":'',"exclamation-circle":'',"info-circle":'',"question-circle":'',voice:'',plus:'',minus:'',dislike:'',fail:'',success:''},$=function(){if(document){var e=document.getElementById("__ANTD_MOBILE_SVG_SPRITE_NODE__"),t=document.body;e||t.insertAdjacentHTML("afterbegin",function(){var e=Object.keys(X).map((function(e){return""})).join("");return'\n