| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737 | (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);throw new Error("Cannot find module '"+o+"'")}var f=n[o]={exports:{}};t[o][0].call(f.exports,function(e){var n=t[o][1][e];return s(n?n:e)},f,f.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){(function (global){!function(e){if("object"==typeof exports)module.exports=e();else if("function"==typeof define&&define.amd)define(e);else{var t;"undefined"!=typeof window?t=window:"undefined"!=typeof global?t=global:"undefined"!=typeof self&&(t=self),t.objectHash=e()}}(function(){return function e(t,n,r){function o(u,a){if(!n[u]){if(!t[u]){var f="function"==typeof require&&require;if(!a&&f)return f(u,!0);if(i)return i(u,!0);throw new Error("Cannot find module '"+u+"'")}var s=n[u]={exports:{}};t[u][0].call(s.exports,function(e){var n=t[u][1][e];return o(n?n:e)},s,s.exports,e,t,n,r)}return n[u].exports}for(var i="function"==typeof require&&require,u=0;u<r.length;u++)o(r[u]);return o}({1:[function(e,t,n){(function(r,o,i,u,a,f,s,c,l){"use strict";function d(e,t){return t=h(e,t),g(e,t)}function h(e,t){if(t=t||{},t.algorithm=t.algorithm||"sha1",t.encoding=t.encoding||"hex",t.excludeValues=!!t.excludeValues,t.algorithm=t.algorithm.toLowerCase(),t.encoding=t.encoding.toLowerCase(),t.ignoreUnknown=t.ignoreUnknown===!0,t.respectType=t.respectType!==!1,t.respectFunctionNames=t.respectFunctionNames!==!1,t.respectFunctionProperties=t.respectFunctionProperties!==!1,t.unorderedArrays=t.unorderedArrays===!0,t.unorderedSets=t.unorderedSets!==!1,t.unorderedObjects=t.unorderedObjects!==!1,t.replacer=t.replacer||void 0,t.excludeKeys=t.excludeKeys||void 0,"undefined"==typeof e)throw new Error("Object argument required.");for(var n=0;n<v.length;++n)v[n].toLowerCase()===t.algorithm.toLowerCase()&&(t.algorithm=v[n]);if(v.indexOf(t.algorithm)===-1)throw new Error('Algorithm "'+t.algorithm+'"  not supported. supported values: '+v.join(", "));if(m.indexOf(t.encoding)===-1&&"passthrough"!==t.algorithm)throw new Error('Encoding "'+t.encoding+'"  not supported. supported values: '+m.join(", "));return t}function p(e){if("function"!=typeof e)return!1;var t=/^function\s+\w*\s*\(\s*\)\s*{\s+\[native code\]\s+}$/i;return null!=t.exec(Function.prototype.toString.call(e))}function g(e,t){var n;n="passthrough"!==t.algorithm?b.createHash(t.algorithm):new w,"undefined"==typeof n.write&&(n.write=n.update,n.end=n.update);var r=y(t,n);if(r.dispatch(e),n.update||n.end(""),n.digest)return n.digest("buffer"===t.encoding?void 0:t.encoding);var o=n.read();return"buffer"===t.encoding?o:o.toString(t.encoding)}function y(e,t,n){n=n||[];var r=function(e){return t.update?t.update(e,"utf8"):t.write(e,"utf8")};return{dispatch:function(t){e.replacer&&(t=e.replacer(t));var n=typeof t;return null===t&&(n="null"),this["_"+n](t)},_object:function(t){var o=/\[object (.*)\]/i,u=Object.prototype.toString.call(t),a=o.exec(u);a=a?a[1]:"unknown:["+u+"]",a=a.toLowerCase();var f=null;if((f=n.indexOf(t))>=0)return this.dispatch("[CIRCULAR:"+f+"]");if(n.push(t),"undefined"!=typeof i&&i.isBuffer&&i.isBuffer(t))return r("buffer:"),r(t);if("object"===a||"function"===a){var s=Object.keys(t);e.unorderedObjects&&(s=s.sort()),e.respectType===!1||p(t)||s.splice(0,0,"prototype","__proto__","constructor"),e.excludeKeys&&(s=s.filter(function(t){return!e.excludeKeys(t)})),r("object:"+s.length+":");var c=this;return s.forEach(function(n){c.dispatch(n),r(":"),e.excludeValues||c.dispatch(t[n]),r(",")})}if(!this["_"+a]){if(e.ignoreUnknown)return r("["+a+"]");throw new Error('Unknown object type "'+a+'"')}this["_"+a](t)},_array:function(t,o){o="undefined"!=typeof o?o:e.unorderedArrays!==!1;var i=this;if(r("array:"+t.length+":"),!o||t.length<=1)return t.forEach(function(e){return i.dispatch(e)});var u=[],a=t.map(function(t){var r=new w,o=n.slice(),i=y(e,r,o);return i.dispatch(t),u=u.concat(o.slice(n.length)),r.read().toString()});return n=n.concat(u),a.sort(),this._array(a,!1)},_date:function(e){return r("date:"+e.toJSON())},_symbol:function(e){return r("symbol:"+e.toString())},_error:function(e){return r("error:"+e.toString())},_boolean:function(e){return r("bool:"+e.toString())},_string:function(e){r("string:"+e.length+":"),r(e.toString())},_function:function(t){r("fn:"),p(t)?this.dispatch("[native]"):this.dispatch(t.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(t.name)),e.respectFunctionProperties&&this._object(t)},_number:function(e){return r("number:"+e.toString())},_xml:function(e){return r("xml:"+e.toString())},_null:function(){return r("Null")},_undefined:function(){return r("Undefined")},_regexp:function(e){return r("regex:"+e.toString())},_uint8array:function(e){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint8clampedarray:function(e){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(e))},_int8array:function(e){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint16array:function(e){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_int16array:function(e){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_uint32array:function(e){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_int32array:function(e){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_float32array:function(e){return r("float32array:"),this.dispatch(Array.prototype.slice.call(e))},_float64array:function(e){return r("float64array:"),this.dispatch(Array.prototype.slice.call(e))},_arraybuffer:function(e){return r("arraybuffer:"),this.dispatch(new Uint8Array(e))},_url:function(e){return r("url:"+e.toString(),"utf8")},_map:function(t){r("map:");var n=Array.from(t);return this._array(n,e.unorderedSets!==!1)},_set:function(t){r("set:");var n=Array.from(t);return this._array(n,e.unorderedSets!==!1)},_blob:function(){if(e.ignoreUnknown)return r("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return r("domwindow")},_process:function(){return r("process")},_timer:function(){return r("timer")},_pipe:function(){return r("pipe")},_tcp:function(){return r("tcp")},_udp:function(){return r("udp")},_tty:function(){return r("tty")},_statwatcher:function(){return r("statwatcher")},_securecontext:function(){return r("securecontext")},_connection:function(){return r("connection")},_zlib:function(){return r("zlib")},_context:function(){return r("context")},_nodescript:function(){return r("nodescript")},_httpparser:function(){return r("httpparser")},_dataview:function(){return r("dataview")},_signal:function(){return r("signal")},_fsevent:function(){return r("fsevent")},_tlswrap:function(){return r("tlswrap")}}}function w(){return{buf:"",write:function(e){this.buf+=e},end:function(e){this.buf+=e},read:function(){return this.buf}}}var b=e("crypto");n=t.exports=d,n.sha1=function(e){return d(e)},n.keys=function(e){return d(e,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},n.MD5=function(e){return d(e,{algorithm:"md5",encoding:"hex"})},n.keysMD5=function(e){return d(e,{algorithm:"md5",encoding:"hex",excludeValues:!0})};var v=b.getHashes?b.getHashes().slice():["sha1","md5"];v.push("passthrough");var m=["buffer","hex","binary","base64"];n.writeToStream=function(e,t,n){return"undefined"==typeof n&&(n=t,t={}),t=h(e,t),y(t,n).dispatch(e)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_e8180ef5.js","/")},{buffer:3,crypto:5,lYpoI2:10}],2:[function(e,t,n){(function(e,t,r,o,i,u,a,f,s){var c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(e){"use strict";function t(e){var t=e.charCodeAt(0);return t===i||t===l?62:t===u||t===d?63:t<a?-1:t<a+10?t-a+26+26:t<s+26?t-s:t<f+26?t-f+26:void 0}function n(e){function n(e){s[l++]=e}var r,i,u,a,f,s;if(e.length%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var c=e.length;f="="===e.charAt(c-2)?2:"="===e.charAt(c-1)?1:0,s=new o(3*e.length/4-f),u=f>0?e.length-4:e.length;var l=0;for(r=0,i=0;r<u;r+=4,i+=3)a=t(e.charAt(r))<<18|t(e.charAt(r+1))<<12|t(e.charAt(r+2))<<6|t(e.charAt(r+3)),n((16711680&a)>>16),n((65280&a)>>8),n(255&a);return 2===f?(a=t(e.charAt(r))<<2|t(e.charAt(r+1))>>4,n(255&a)):1===f&&(a=t(e.charAt(r))<<10|t(e.charAt(r+1))<<4|t(e.charAt(r+2))>>2,n(a>>8&255),n(255&a)),s}function r(e){function t(e){return c.charAt(e)}function n(e){return t(e>>18&63)+t(e>>12&63)+t(e>>6&63)+t(63&e)}var r,o,i,u=e.length%3,a="";for(r=0,i=e.length-u;r<i;r+=3)o=(e[r]<<16)+(e[r+1]<<8)+e[r+2],a+=n(o);switch(u){case 1:o=e[e.length-1],a+=t(o>>2),a+=t(o<<4&63),a+="==";break;case 2:o=(e[e.length-2]<<8)+e[e.length-1],a+=t(o>>10),a+=t(o>>4&63),a+=t(o<<2&63),a+="="}return a}var o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="+".charCodeAt(0),u="/".charCodeAt(0),a="0".charCodeAt(0),f="a".charCodeAt(0),s="A".charCodeAt(0),l="-".charCodeAt(0),d="_".charCodeAt(0);e.toByteArray=n,e.fromByteArray=r}("undefined"==typeof n?this.base64js={}:n)}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:10}],3:[function(e,t,n){(function(t,r,o,i,u,a,f,s,c){function o(e,t,n){if(!(this instanceof o))return new o(e,t,n);var r=typeof e;if("base64"===t&&"string"===r)for(e=N(e);e.length%4!==0;)e+="=";var i;if("number"===r)i=F(e);else if("string"===r)i=o.byteLength(e,t);else{if("object"!==r)throw new Error("First argument needs to be a number, array or string.");i=F(e.length)}var u;o._useTypedArrays?u=o._augment(new Uint8Array(i)):(u=this,u.length=i,u._isBuffer=!0);var a;if(o._useTypedArrays&&"number"==typeof e.byteLength)u._set(e);else if(O(e))for(a=0;a<i;a++)o.isBuffer(e)?u[a]=e.readUInt8(a):u[a]=e[a];else if("string"===r)u.write(e,0,t);else if("number"===r&&!o._useTypedArrays&&!n)for(a=0;a<i;a++)u[a]=0;return u}function l(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r),r>i&&(r=i)):r=i;var u=t.length;$(u%2===0,"Invalid hex string"),r>u/2&&(r=u/2);for(var a=0;a<r;a++){var f=parseInt(t.substr(2*a,2),16);$(!isNaN(f),"Invalid hex string"),e[n+a]=f}return o._charsWritten=2*a,a}function d(e,t,n,r){var i=o._charsWritten=W(V(t),e,n,r);return i}function h(e,t,n,r){var i=o._charsWritten=W(q(t),e,n,r);return i}function p(e,t,n,r){return h(e,t,n,r)}function g(e,t,n,r){var i=o._charsWritten=W(R(t),e,n,r);return i}function y(e,t,n,r){var i=o._charsWritten=W(P(t),e,n,r);return i}function w(e,t,n){return 0===t&&n===e.length?G.fromByteArray(e):G.fromByteArray(e.slice(t,n))}function b(e,t,n){var r="",o="";n=Math.min(e.length,n);for(var i=t;i<n;i++)e[i]<=127?(r+=J(o)+String.fromCharCode(e[i]),o=""):o+="%"+e[i].toString(16);return r+J(o)}function v(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;o++)r+=String.fromCharCode(e[o]);return r}function m(e,t,n){return v(e,t,n)}function _(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;i++)o+=H(e[i]);return o}function E(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function I(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return n?(i=e[t],t+1<o&&(i|=e[t+1]<<8)):(i=e[t]<<8,t+1<o&&(i|=e[t+1])),i}}function A(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return n?(t+2<o&&(i=e[t+2]<<16),t+1<o&&(i|=e[t+1]<<8),i|=e[t],t+3<o&&(i+=e[t+3]<<24>>>0)):(t+1<o&&(i=e[t+1]<<16),t+2<o&&(i|=e[t+2]<<8),t+3<o&&(i|=e[t+3]),i+=e[t]<<24>>>0),i}}function B(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=I(e,t,n,!0),u=32768&i;return u?(65535-i+1)*-1:i}}function L(e,t,n,r){r||($("boolean"==typeof n,"missing or invalid endian"),$(void 0!==t&&null!==t,"missing offset"),$(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=A(e,t,n,!0),u=2147483648&i;return u?(4294967295-i+1)*-1:i}}function U(e,t,n,r){return r||($("boolean"==typeof n,"missing or invalid endian"),$(t+3<e.length,"Trying to read beyond buffer length")),Q.read(e,t,n,23,4)}function x(e,t,n,r){return r||($("boolean"==typeof n,"missing or invalid endian"),$(t+7<e.length,"Trying to read beyond buffer length")),Q.read(e,t,n,52,8)}function S(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+1<e.length,"trying to write beyond buffer length"),K(t,65535));var i=e.length;if(!(n>=i))for(var u=0,a=Math.min(i-n,2);u<a;u++)e[n+u]=(t&255<<8*(r?u:1-u))>>>8*(r?u:1-u)}function j(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"trying to write beyond buffer length"),K(t,4294967295));var i=e.length;if(!(n>=i))for(var u=0,a=Math.min(i-n,4);u<a;u++)e[n+u]=t>>>8*(r?u:3-u)&255}function C(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+1<e.length,"Trying to write beyond buffer length"),z(t,32767,-32768));var i=e.length;n>=i||(t>=0?S(e,t,n,r,o):S(e,65535+t+1,n,r,o))}function k(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"Trying to write beyond buffer length"),z(t,2147483647,-2147483648));var i=e.length;n>=i||(t>=0?j(e,t,n,r,o):j(e,4294967295+t+1,n,r,o))}function T(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+3<e.length,"Trying to write beyond buffer length"),X(t,3.4028234663852886e38,-3.4028234663852886e38));var i=e.length;n>=i||Q.write(e,t,n,r,23,4)}function M(e,t,n,r,o){o||($(void 0!==t&&null!==t,"missing value"),$("boolean"==typeof r,"missing or invalid endian"),$(void 0!==n&&null!==n,"missing offset"),$(n+7<e.length,"Trying to write beyond buffer length"),X(t,1.7976931348623157e308,-1.7976931348623157e308));var i=e.length;n>=i||Q.write(e,t,n,r,52,8)}function N(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Y(e,t,n){return"number"!=typeof e?n:(e=~~e,e>=t?t:e>=0?e:(e+=t,e>=0?e:0))}function F(e){return e=~~Math.ceil(+e),e<0?0:e}function D(e){return(Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)})(e)}function O(e){return D(e)||o.isBuffer(e)||e&&"object"==typeof e&&"number"==typeof e.length}function H(e){return e<16?"0"+e.toString(16):e.toString(16)}function V(e){for(var t=[],n=0;n<e.length;n++){var r=e.charCodeAt(n);if(r<=127)t.push(e.charCodeAt(n));else{var o=n;r>=55296&&r<=57343&&n++;for(var i=encodeURIComponent(e.slice(o,n+1)).substr(1).split("%"),u=0;u<i.length;u++)t.push(parseInt(i[u],16))}}return t}function q(e){for(var t=[],n=0;n<e.length;n++)t.push(255&e.charCodeAt(n));return t}function P(e){for(var t,n,r,o=[],i=0;i<e.length;i++)t=e.charCodeAt(i),n=t>>8,r=t%256,o.push(r),o.push(n);return o}function R(e){return G.toByteArray(e)}function W(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);o++)t[o+n]=e[o];return o}function J(e){try{return decodeURIComponent(e)}catch(t){return String.fromCharCode(65533)}}function K(e,t){$("number"==typeof e,"cannot write a non-number as a number"),$(e>=0,"specified a negative value for writing an unsigned value"),$(e<=t,"value is larger than maximum value for type"),$(Math.floor(e)===e,"value has a fractional component")}function z(e,t,n){$("number"==typeof e,"cannot write a non-number as a number"),$(e<=t,"value larger than maximum allowed value"),$(e>=n,"value smaller than minimum allowed value"),$(Math.floor(e)===e,"value has a fractional component")}function X(e,t,n){$("number"==typeof e,"cannot write a non-number as a number"),$(e<=t,"value larger than maximum allowed value"),$(e>=n,"value smaller than minimum allowed value")}function $(e,t){if(!e)throw new Error(t||"Failed assertion")}var G=e("base64-js"),Q=e("ieee754");n.Buffer=o,n.SlowBuffer=o,n.INSPECT_MAX_BYTES=50,o.poolSize=8192,o._useTypedArrays=function(){try{var e=new ArrayBuffer(0),t=new Uint8Array(e);return t.foo=function(){return 42},42===t.foo()&&"function"==typeof t.subarray}catch(n){return!1}}(),o.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.isBuffer=function(e){return!(null===e||void 0===e||!e._isBuffer)},o.byteLength=function(e,t){var n;switch(e+="",t||"utf8"){case"hex":n=e.length/2;break;case"utf8":case"utf-8":n=V(e).length;break;case"ascii":case"binary":case"raw":n=e.length;break;case"base64":n=R(e).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":n=2*e.length;break;default:throw new Error("Unknown encoding")}return n},o.concat=function(e,t){if($(D(e),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===e.length)return new o(0);if(1===e.length)return e[0];var n;if("number"!=typeof t)for(t=0,n=0;n<e.length;n++)t+=e[n].length;var r=new o(t),i=0;for(n=0;n<e.length;n++){var u=e[n];u.copy(r,i),i+=u.length}return r},o.prototype.write=function(e,t,n,r){if(isFinite(t))isFinite(n)||(r=n,n=void 0);else{var o=r;r=t,t=n,n=o}t=Number(t)||0;var i=this.length-t;n?(n=Number(n),n>i&&(n=i)):n=i,r=String(r||"utf8").toLowerCase();var u;switch(r){case"hex":u=l(this,e,t,n);break;case"utf8":case"utf-8":u=d(this,e,t,n);break;case"ascii":u=h(this,e,t,n);break;case"binary":u=p(this,e,t,n);break;case"base64":u=g(this,e,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":u=y(this,e,t,n);break;default:throw new Error("Unknown encoding")}return u},o.prototype.toString=function(e,t,n){var r=this;if(e=String(e||"utf8").toLowerCase(),t=Number(t)||0,n=void 0!==n?Number(n):n=r.length,n===t)return"";var o;switch(e){case"hex":o=_(r,t,n);break;case"utf8":case"utf-8":o=b(r,t,n);break;case"ascii":o=v(r,t,n);break;case"binary":o=m(r,t,n);break;case"base64":o=w(r,t,n);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":o=E(r,t,n);break;default:throw new Error("Unknown encoding")}return o},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.copy=function(e,t,n,r){var i=this;if(n||(n=0),r||0===r||(r=this.length),t||(t=0),r!==n&&0!==e.length&&0!==i.length){$(r>=n,"sourceEnd < sourceStart"),$(t>=0&&t<e.length,"targetStart out of bounds"),$(n>=0&&n<i.length,"sourceStart out of bounds"),$(r>=0&&r<=i.length,"sourceEnd out of bounds"),r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var u=r-n;if(u<100||!o._useTypedArrays)for(var a=0;a<u;a++)e[a+t]=this[a+n];else e._set(this.subarray(n,n+u),t)}},o.prototype.slice=function(e,t){var n=this.length;if(e=Y(e,n,0),t=Y(t,n,n),o._useTypedArrays)return o._augment(this.subarray(e,t));for(var r=t-e,i=new o(r,(void 0),(!0)),u=0;u<r;u++)i[u]=this[u+e];return i},o.prototype.get=function(e){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(e)},o.prototype.set=function(e,t){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(e,t)},o.prototype.readUInt8=function(e,t){if(t||($(void 0!==e&&null!==e,"missing offset"),$(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length))return this[e]},o.prototype.readUInt16LE=function(e,t){return I(this,e,!0,t)},o.prototype.readUInt16BE=function(e,t){return I(this,e,!1,t)},o.prototype.readUInt32LE=function(e,t){return A(this,e,!0,t)},o.prototype.readUInt32BE=function(e,t){return A(this,e,!1,t)},o.prototype.readInt8=function(e,t){if(t||($(void 0!==e&&null!==e,"missing offset"),$(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length)){var n=128&this[e];return n?(255-this[e]+1)*-1:this[e]}},o.prototype.readInt16LE=function(e,t){return B(this,e,!0,t)},o.prototype.readInt16BE=function(e,t){return B(this,e,!1,t)},o.prototype.readInt32LE=function(e,t){return L(this,e,!0,t)},o.prototype.readInt32BE=function(e,t){return L(this,e,!1,t)},o.prototype.readFloatLE=function(e,t){return U(this,e,!0,t)},o.prototype.readFloatBE=function(e,t){return U(this,e,!1,t)},o.prototype.readDoubleLE=function(e,t){return x(this,e,!0,t)},o.prototype.readDoubleBE=function(e,t){return x(this,e,!1,t)},o.prototype.writeUInt8=function(e,t,n){n||($(void 0!==e&&null!==e,"missing value"),$(void 0!==t&&null!==t,"missing offset"),$(t<this.length,"trying to write beyond buffer length"),K(e,255)),t>=this.length||(this[t]=e)},o.prototype.writeUInt16LE=function(e,t,n){S(this,e,t,!0,n)},o.prototype.writeUInt16BE=function(e,t,n){S(this,e,t,!1,n)},o.prototype.writeUInt32LE=function(e,t,n){j(this,e,t,!0,n)},o.prototype.writeUInt32BE=function(e,t,n){j(this,e,t,!1,n)},o.prototype.writeInt8=function(e,t,n){n||($(void 0!==e&&null!==e,"missing value"),$(void 0!==t&&null!==t,"missing offset"),$(t<this.length,"Trying to write beyond buffer length"),z(e,127,-128)),t>=this.length||(e>=0?this.writeUInt8(e,t,n):this.writeUInt8(255+e+1,t,n))},o.prototype.writeInt16LE=function(e,t,n){C(this,e,t,!0,n)},o.prototype.writeInt16BE=function(e,t,n){C(this,e,t,!1,n)},o.prototype.writeInt32LE=function(e,t,n){k(this,e,t,!0,n)},o.prototype.writeInt32BE=function(e,t,n){k(this,e,t,!1,n)},o.prototype.writeFloatLE=function(e,t,n){T(this,e,t,!0,n)},o.prototype.writeFloatBE=function(e,t,n){T(this,e,t,!1,n)},o.prototype.writeDoubleLE=function(e,t,n){M(this,e,t,!0,n)},o.prototype.writeDoubleBE=function(e,t,n){M(this,e,t,!1,n)},o.prototype.fill=function(e,t,n){if(e||(e=0),t||(t=0),n||(n=this.length),"string"==typeof e&&(e=e.charCodeAt(0)),$("number"==typeof e&&!isNaN(e),"value is not a number"),$(n>=t,"end < start"),n!==t&&0!==this.length){$(t>=0&&t<this.length,"start out of bounds"),$(n>=0&&n<=this.length,"end out of bounds");for(var r=t;r<n;r++)this[r]=e}},o.prototype.inspect=function(){for(var e=[],t=this.length,r=0;r<t;r++)if(e[r]=H(this[r]),r===n.INSPECT_MAX_BYTES){e[r+1]="...";break}return"<Buffer "+e.join(" ")+">"},o.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(o._useTypedArrays)return new o(this).buffer;for(var e=new Uint8Array(this.length),t=0,n=e.length;t<n;t+=1)e[t]=this[t];return e.buffer}throw new Error("Buffer.toArrayBuffer not supported in this browser")};var Z=o.prototype;o._augment=function(e){return e._isBuffer=!0,e._get=e.get,e._set=e.set,e.get=Z.get,e.set=Z.set,e.write=Z.write,e.toString=Z.toString,e.toLocaleString=Z.toString,e.toJSON=Z.toJSON,e.copy=Z.copy,e.slice=Z.slice,e.readUInt8=Z.readUInt8,e.readUInt16LE=Z.readUInt16LE,e.readUInt16BE=Z.readUInt16BE,e.readUInt32LE=Z.readUInt32LE,e.readUInt32BE=Z.readUInt32BE,e.readInt8=Z.readInt8,e.readInt16LE=Z.readInt16LE,e.readInt16BE=Z.readInt16BE,e.readInt32LE=Z.readInt32LE,e.readInt32BE=Z.readInt32BE,e.readFloatLE=Z.readFloatLE,e.readFloatBE=Z.readFloatBE,e.readDoubleLE=Z.readDoubleLE,e.readDoubleBE=Z.readDoubleBE,e.writeUInt8=Z.writeUInt8,e.writeUInt16LE=Z.writeUInt16LE,e.writeUInt16BE=Z.writeUInt16BE,e.writeUInt32LE=Z.writeUInt32LE,e.writeUInt32BE=Z.writeUInt32BE,e.writeInt8=Z.writeInt8,e.writeInt16LE=Z.writeInt16LE,e.writeInt16BE=Z.writeInt16BE,e.writeInt32LE=Z.writeInt32LE,e.writeInt32BE=Z.writeInt32BE,e.writeFloatLE=Z.writeFloatLE,e.writeFloatBE=Z.writeFloatBE,e.writeDoubleLE=Z.writeDoubleLE,e.writeDoubleBE=Z.writeDoubleBE,e.fill=Z.fill,e.inspect=Z.inspect,e.toArrayBuffer=Z.toArrayBuffer,e}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:11,lYpoI2:10}],4:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){if(e.length%p!==0){var n=e.length+(p-e.length%p);e=o.concat([e,g],n)}for(var r=[],i=t?e.readInt32BE:e.readInt32LE,u=0;u<e.length;u+=p)r.push(i.call(e,u));return r}function d(e,t,n){for(var r=new o(t),i=n?r.writeInt32BE:r.writeInt32LE,u=0;u<e.length;u++)i.call(r,e[u],4*u,!0);return r}function h(e,t,n,r){o.isBuffer(e)||(e=new o(e));var i=t(l(e,r),e.length*y);return d(i,n,r)}var o=e("buffer").Buffer,p=4,g=new o(p);g.fill(0);var y=8;t.exports={hash:h}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/helpers.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],5:[function(e,t,n){(function(t,r,o,i,u,a,f,s,c){function l(e,t,n){o.isBuffer(t)||(t=new o(t)),o.isBuffer(n)||(n=new o(n)),t.length>m?t=e(t):t.length<m&&(t=o.concat([t,_],m));for(var r=new o(m),i=new o(m),u=0;u<m;u++)r[u]=54^t[u],i[u]=92^t[u];var a=e(o.concat([r,n]));return e(o.concat([i,a]))}function d(e,t){e=e||"sha1";var n=v[e],r=[],i=0;return n||h("algorithm:",e,"is not yet supported"),{update:function(e){return o.isBuffer(e)||(e=new o(e)),r.push(e),i+=e.length,this},digest:function(e){var i=o.concat(r),u=t?l(n,t,i):n(i);return r=null,e?u.toString(e):u}}}function h(){var e=[].slice.call(arguments).join(" ");throw new Error([e,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}function p(e,t){for(var n in e)t(e[n],n)}var o=e("buffer").Buffer,g=e("./sha"),y=e("./sha256"),w=e("./rng"),b=e("./md5"),v={sha1:g,sha256:y,md5:b},m=64,_=new o(m);_.fill(0),n.createHash=function(e){return d(e)},n.createHmac=function(e,t){return d(e,t)},n.randomBytes=function(e,t){if(!t||!t.call)return new o(w(e));try{t.call(this,void 0,new o(w(e)))}catch(n){t(n)}},p(["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],function(e){n[e]=function(){h("sorry,",e,"is not implemented yet")}})}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/index.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./md5":6,"./rng":7,"./sha":8,"./sha256":9,buffer:3,lYpoI2:10}],6:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){e[t>>5]|=128<<t%32,e[(t+64>>>9<<4)+14]=t;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,u=0;u<e.length;u+=16){var a=n,f=r,s=o,c=i;n=h(n,r,o,i,e[u+0],7,-680876936),i=h(i,n,r,o,e[u+1],12,-389564586),o=h(o,i,n,r,e[u+2],17,606105819),r=h(r,o,i,n,e[u+3],22,-1044525330),n=h(n,r,o,i,e[u+4],7,-176418897),i=h(i,n,r,o,e[u+5],12,1200080426),o=h(o,i,n,r,e[u+6],17,-1473231341),r=h(r,o,i,n,e[u+7],22,-45705983),n=h(n,r,o,i,e[u+8],7,1770035416),i=h(i,n,r,o,e[u+9],12,-1958414417),o=h(o,i,n,r,e[u+10],17,-42063),r=h(r,o,i,n,e[u+11],22,-1990404162),n=h(n,r,o,i,e[u+12],7,1804603682),i=h(i,n,r,o,e[u+13],12,-40341101),o=h(o,i,n,r,e[u+14],17,-1502002290),r=h(r,o,i,n,e[u+15],22,1236535329),n=p(n,r,o,i,e[u+1],5,-165796510),i=p(i,n,r,o,e[u+6],9,-1069501632),o=p(o,i,n,r,e[u+11],14,643717713),r=p(r,o,i,n,e[u+0],20,-373897302),n=p(n,r,o,i,e[u+5],5,-701558691),i=p(i,n,r,o,e[u+10],9,38016083),o=p(o,i,n,r,e[u+15],14,-660478335),r=p(r,o,i,n,e[u+4],20,-405537848),n=p(n,r,o,i,e[u+9],5,568446438),i=p(i,n,r,o,e[u+14],9,-1019803690),o=p(o,i,n,r,e[u+3],14,-187363961),r=p(r,o,i,n,e[u+8],20,1163531501),n=p(n,r,o,i,e[u+13],5,-1444681467),i=p(i,n,r,o,e[u+2],9,-51403784),o=p(o,i,n,r,e[u+7],14,1735328473),r=p(r,o,i,n,e[u+12],20,-1926607734),n=g(n,r,o,i,e[u+5],4,-378558),i=g(i,n,r,o,e[u+8],11,-2022574463),o=g(o,i,n,r,e[u+11],16,1839030562),r=g(r,o,i,n,e[u+14],23,-35309556),n=g(n,r,o,i,e[u+1],4,-1530992060),i=g(i,n,r,o,e[u+4],11,1272893353),o=g(o,i,n,r,e[u+7],16,-155497632),r=g(r,o,i,n,e[u+10],23,-1094730640),n=g(n,r,o,i,e[u+13],4,681279174),i=g(i,n,r,o,e[u+0],11,-358537222),o=g(o,i,n,r,e[u+3],16,-722521979),r=g(r,o,i,n,e[u+6],23,76029189),n=g(n,r,o,i,e[u+9],4,-640364487),i=g(i,n,r,o,e[u+12],11,-421815835),o=g(o,i,n,r,e[u+15],16,530742520),r=g(r,o,i,n,e[u+2],23,-995338651),n=y(n,r,o,i,e[u+0],6,-198630844),i=y(i,n,r,o,e[u+7],10,1126891415),o=y(o,i,n,r,e[u+14],15,-1416354905),r=y(r,o,i,n,e[u+5],21,-57434055),n=y(n,r,o,i,e[u+12],6,1700485571),i=y(i,n,r,o,e[u+3],10,-1894986606),o=y(o,i,n,r,e[u+10],15,-1051523),r=y(r,o,i,n,e[u+1],21,-2054922799),n=y(n,r,o,i,e[u+8],6,1873313359),i=y(i,n,r,o,e[u+15],10,-30611744),o=y(o,i,n,r,e[u+6],15,-1560198380),r=y(r,o,i,n,e[u+13],21,1309151649),n=y(n,r,o,i,e[u+4],6,-145523070),i=y(i,n,r,o,e[u+11],10,-1120210379),o=y(o,i,n,r,e[u+2],15,718787259),r=y(r,o,i,n,e[u+9],21,-343485551),n=w(n,a),r=w(r,f),o=w(o,s),i=w(i,c)}return Array(n,r,o,i)}function d(e,t,n,r,o,i){return w(b(w(w(t,e),w(r,i)),o),n)}function h(e,t,n,r,o,i,u){return d(t&n|~t&r,e,t,o,i,u)}function p(e,t,n,r,o,i,u){return d(t&r|n&~r,e,t,o,i,u)}function g(e,t,n,r,o,i,u){return d(t^n^r,e,t,o,i,u)}function y(e,t,n,r,o,i,u){return d(n^(t|~r),e,t,o,i,u)}function w(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n}function b(e,t){return e<<t|e>>>32-t}var v=e("./helpers");t.exports=function(e){return v.hash(e,l,16)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],7:[function(e,t,n){(function(e,n,r,o,i,u,a,f,s){!function(){var e,n,r=this;e=function(e){for(var t,t,n=new Array(e),r=0;r<e;r++)0==(3&r)&&(t=4294967296*Math.random()),n[r]=t>>>((3&r)<<3)&255;return n},r.crypto&&crypto.getRandomValues&&(n=function(e){var t=new Uint8Array(e);return crypto.getRandomValues(t),t}),t.exports=n||e}()}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],8:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){function l(e,t){e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var n=Array(80),r=1732584193,o=-271733879,i=-1732584194,u=271733878,a=-1009589776,f=0;f<e.length;f+=16){for(var s=r,c=o,l=i,y=u,w=a,b=0;b<80;b++){b<16?n[b]=e[f+b]:n[b]=g(n[b-3]^n[b-8]^n[b-14]^n[b-16],1);var v=p(p(g(r,5),d(b,o,i,u)),p(p(a,n[b]),h(b)));a=u,u=i,i=g(o,30),o=r,r=v}r=p(r,s),o=p(o,c),i=p(i,l),u=p(u,y),a=p(a,w)}return Array(r,o,i,u,a)}function d(e,t,n,r){return e<20?t&n|~t&r:e<40?t^n^r:e<60?t&n|t&r|n&r:t^n^r}function h(e){return e<20?1518500249:e<40?1859775393:e<60?-1894007588:-899497514}function p(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n}function g(e,t){return e<<t|e>>>32-t}var y=e("./helpers");t.exports=function(e){return y.hash(e,l,20,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],9:[function(e,t,n){(function(n,r,o,i,u,a,f,s,c){var l=e("./helpers"),d=function(e,t){var n=(65535&e)+(65535&t),r=(e>>16)+(t>>16)+(n>>16);return r<<16|65535&n},h=function(e,t){return e>>>t|e<<32-t},p=function(e,t){return e>>>t},g=function(e,t,n){return e&t^~e&n},y=function(e,t,n){return e&t^e&n^t&n},w=function(e){return h(e,2)^h(e,13)^h(e,22);},b=function(e){return h(e,6)^h(e,11)^h(e,25)},v=function(e){return h(e,7)^h(e,18)^p(e,3)},m=function(e){return h(e,17)^h(e,19)^p(e,10)},_=function(e,t){var n,r,o,i,u,a,f,s,c,l,h,p,_=new Array(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),E=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),I=new Array(64);e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var c=0;c<e.length;c+=16){n=E[0],r=E[1],o=E[2],i=E[3],u=E[4],a=E[5],f=E[6],s=E[7];for(var l=0;l<64;l++)l<16?I[l]=e[l+c]:I[l]=d(d(d(m(I[l-2]),I[l-7]),v(I[l-15])),I[l-16]),h=d(d(d(d(s,b(u)),g(u,a,f)),_[l]),I[l]),p=d(w(n),y(n,r,o)),s=f,f=a,a=u,u=d(i,h),i=o,o=r,r=n,n=d(h,p);E[0]=d(n,E[0]),E[1]=d(r,E[1]),E[2]=d(o,E[2]),E[3]=d(i,E[3]),E[4]=d(u,E[4]),E[5]=d(a,E[5]),E[6]=d(f,E[6]),E[7]=d(s,E[7])}return E};t.exports=function(e){return l.hash(e,_,32,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],10:[function(e,t,n){(function(e,n,r,o,i,u,a,f,s){function c(){}var e=t.exports={};e.nextTick=function(){var e="undefined"!=typeof window&&window.setImmediate,t="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(e)return function(e){return window.setImmediate(e)};if(t){var n=[];return window.addEventListener("message",function(e){var t=e.source;if((t===window||null===t)&&"process-tick"===e.data&&(e.stopPropagation(),n.length>0)){var r=n.shift();r()}},!0),function(e){n.push(e),window.postMessage("process-tick","*")}}return function(e){setTimeout(e,0)}}(),e.title="browser",e.browser=!0,e.env={},e.argv=[],e.on=c,e.addListener=c,e.once=c,e.off=c,e.removeListener=c,e.removeAllListeners=c,e.emit=c,e.binding=function(e){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(e){throw new Error("process.chdir is not supported")}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:10}],11:[function(e,t,n){(function(e,t,r,o,i,u,a,f,s){n.read=function(e,t,n,r,o){var i,u,a=8*o-r-1,f=(1<<a)-1,s=f>>1,c=-7,l=n?o-1:0,d=n?-1:1,h=e[t+l];for(l+=d,i=h&(1<<-c)-1,h>>=-c,c+=a;c>0;i=256*i+e[t+l],l+=d,c-=8);for(u=i&(1<<-c)-1,i>>=-c,c+=r;c>0;u=256*u+e[t+l],l+=d,c-=8);if(0===i)i=1-s;else{if(i===f)return u?NaN:(h?-1:1)*(1/0);u+=Math.pow(2,r),i-=s}return(h?-1:1)*u*Math.pow(2,i-r)},n.write=function(e,t,n,r,o,i){var u,a,f,s=8*i-o-1,c=(1<<s)-1,l=c>>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:i-1,p=r?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,u=c):(u=Math.floor(Math.log(t)/Math.LN2),t*(f=Math.pow(2,-u))<1&&(u--,f*=2),t+=u+l>=1?d/f:d*Math.pow(2,1-l),t*f>=2&&(u++,f/=2),u+l>=c?(a=0,u=c):u+l>=1?(a=(t*f-1)*Math.pow(2,o),u+=l):(a=t*Math.pow(2,l-1)*Math.pow(2,o),u=0));o>=8;e[n+h]=255&a,h+=p,a/=256,o-=8);for(u=u<<o|a,s+=o;s>0;e[n+h]=255&u,h+=p,u/=256,s-=8);e[n+h-p]|=128*g}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/ieee754/index.js","/node_modules/ieee754")},{buffer:3,lYpoI2:10}]},{},[1])(1)});}).call(this,typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})},{}],2:[function(require,module,exports){// http://wiki.commonjs.org/wiki/Unit_Testing/1.0//// THIS IS NOT TESTED NOR LIKELY TO WORK OUTSIDE V8!//// Originally from narwhal.js (http://narwhaljs.org)// Copyright (c) 2009 Thomas Robinson <280north.com>//// Permission is hereby granted, free of charge, to any person obtaining a copy// of this software and associated documentation files (the 'Software'), to// deal in the Software without restriction, including without limitation the// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or// sell copies of the Software, and to permit persons to whom the Software is// furnished to do so, subject to the following conditions://// The above copyright notice and this permission notice shall be included in// all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE// AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.// when used in node, this will actually load the util module we depend on// versus loading the builtin util module as happens otherwise// this is a bug in node module loading as far as I am concernedvar util = require('util/');var pSlice = Array.prototype.slice;var hasOwn = Object.prototype.hasOwnProperty;// 1. The assert module provides functions that throw// AssertionError's when particular conditions are not met. The// assert module must conform to the following interface.var assert = module.exports = ok;// 2. The AssertionError is defined in assert.// new assert.AssertionError({ message: message,//                             actual: actual,//                             expected: expected })assert.AssertionError = function AssertionError(options) {  this.name = 'AssertionError';  this.actual = options.actual;  this.expected = options.expected;  this.operator = options.operator;  if (options.message) {    this.message = options.message;    this.generatedMessage = false;  } else {    this.message = getMessage(this);    this.generatedMessage = true;  }  var stackStartFunction = options.stackStartFunction || fail;  if (Error.captureStackTrace) {    Error.captureStackTrace(this, stackStartFunction);  }  else {    // non v8 browsers so we can have a stacktrace    var err = new Error();    if (err.stack) {      var out = err.stack;      // try to strip useless frames      var fn_name = stackStartFunction.name;      var idx = out.indexOf('\n' + fn_name);      if (idx >= 0) {        // once we have located the function frame        // we need to strip out everything before it (and its line)        var next_line = out.indexOf('\n', idx + 1);        out = out.substring(next_line + 1);      }      this.stack = out;    }  }};// assert.AssertionError instanceof Errorutil.inherits(assert.AssertionError, Error);function replacer(key, value) {  if (util.isUndefined(value)) {    return '' + value;  }  if (util.isNumber(value) && (isNaN(value) || !isFinite(value))) {    return value.toString();  }  if (util.isFunction(value) || util.isRegExp(value)) {    return value.toString();  }  return value;}function truncate(s, n) {  if (util.isString(s)) {    return s.length < n ? s : s.slice(0, n);  } else {    return s;  }}function getMessage(self) {  return truncate(JSON.stringify(self.actual, replacer), 128) + ' ' +         self.operator + ' ' +         truncate(JSON.stringify(self.expected, replacer), 128);}// At present only the three keys mentioned above are used and// understood by the spec. Implementations or sub modules can pass// other keys to the AssertionError's constructor - they will be// ignored.// 3. All of the following functions must throw an AssertionError// when a corresponding condition is not met, with a message that// may be undefined if not provided.  All assertion methods provide// both the actual and expected values to the assertion error for// display purposes.function fail(actual, expected, message, operator, stackStartFunction) {  throw new assert.AssertionError({    message: message,    actual: actual,    expected: expected,    operator: operator,    stackStartFunction: stackStartFunction  });}// EXTENSION! allows for well behaved errors defined elsewhere.assert.fail = fail;// 4. Pure assertion tests whether a value is truthy, as determined// by !!guard.// assert.ok(guard, message_opt);// This statement is equivalent to assert.equal(true, !!guard,// message_opt);. To test strictly for the value true, use// assert.strictEqual(true, guard, message_opt);.function ok(value, message) {  if (!value) fail(value, true, message, '==', assert.ok);}assert.ok = ok;// 5. The equality assertion tests shallow, coercive equality with// ==.// assert.equal(actual, expected, message_opt);assert.equal = function equal(actual, expected, message) {  if (actual != expected) fail(actual, expected, message, '==', assert.equal);};// 6. The non-equality assertion tests for whether two objects are not equal// with != assert.notEqual(actual, expected, message_opt);assert.notEqual = function notEqual(actual, expected, message) {  if (actual == expected) {    fail(actual, expected, message, '!=', assert.notEqual);  }};// 7. The equivalence assertion tests a deep equality relation.// assert.deepEqual(actual, expected, message_opt);assert.deepEqual = function deepEqual(actual, expected, message) {  if (!_deepEqual(actual, expected)) {    fail(actual, expected, message, 'deepEqual', assert.deepEqual);  }};function _deepEqual(actual, expected) {  // 7.1. All identical values are equivalent, as determined by ===.  if (actual === expected) {    return true;  } else if (util.isBuffer(actual) && util.isBuffer(expected)) {    if (actual.length != expected.length) return false;    for (var i = 0; i < actual.length; i++) {      if (actual[i] !== expected[i]) return false;    }    return true;  // 7.2. If the expected value is a Date object, the actual value is  // equivalent if it is also a Date object that refers to the same time.  } else if (util.isDate(actual) && util.isDate(expected)) {    return actual.getTime() === expected.getTime();  // 7.3 If the expected value is a RegExp object, the actual value is  // equivalent if it is also a RegExp object with the same source and  // properties (`global`, `multiline`, `lastIndex`, `ignoreCase`).  } else if (util.isRegExp(actual) && util.isRegExp(expected)) {    return actual.source === expected.source &&           actual.global === expected.global &&           actual.multiline === expected.multiline &&           actual.lastIndex === expected.lastIndex &&           actual.ignoreCase === expected.ignoreCase;  // 7.4. Other pairs that do not both pass typeof value == 'object',  // equivalence is determined by ==.  } else if (!util.isObject(actual) && !util.isObject(expected)) {    return actual == expected;  // 7.5 For all other Object pairs, including Array objects, equivalence is  // determined by having the same number of owned properties (as verified  // with Object.prototype.hasOwnProperty.call), the same set of keys  // (although not necessarily the same order), equivalent values for every  // corresponding key, and an identical 'prototype' property. Note: this  // accounts for both named and indexed properties on Arrays.  } else {    return objEquiv(actual, expected);  }}function isArguments(object) {  return Object.prototype.toString.call(object) == '[object Arguments]';}function objEquiv(a, b) {  if (util.isNullOrUndefined(a) || util.isNullOrUndefined(b))    return false;  // an identical 'prototype' property.  if (a.prototype !== b.prototype) return false;  //~~~I've managed to break Object.keys through screwy arguments passing.  //   Converting to array solves the problem.  if (isArguments(a)) {    if (!isArguments(b)) {      return false;    }    a = pSlice.call(a);    b = pSlice.call(b);    return _deepEqual(a, b);  }  try {    var ka = objectKeys(a),        kb = objectKeys(b),        key, i;  } catch (e) {//happens when one is a string literal and the other isn't    return false;  }  // having the same number of owned properties (keys incorporates  // hasOwnProperty)  if (ka.length != kb.length)    return false;  //the same set of keys (although not necessarily the same order),  ka.sort();  kb.sort();  //~~~cheap key test  for (i = ka.length - 1; i >= 0; i--) {    if (ka[i] != kb[i])      return false;  }  //equivalent values for every corresponding key, and  //~~~possibly expensive deep test  for (i = ka.length - 1; i >= 0; i--) {    key = ka[i];    if (!_deepEqual(a[key], b[key])) return false;  }  return true;}// 8. The non-equivalence assertion tests for any deep inequality.// assert.notDeepEqual(actual, expected, message_opt);assert.notDeepEqual = function notDeepEqual(actual, expected, message) {  if (_deepEqual(actual, expected)) {    fail(actual, expected, message, 'notDeepEqual', assert.notDeepEqual);  }};// 9. The strict equality assertion tests strict equality, as determined by ===.// assert.strictEqual(actual, expected, message_opt);assert.strictEqual = function strictEqual(actual, expected, message) {  if (actual !== expected) {    fail(actual, expected, message, '===', assert.strictEqual);  }};// 10. The strict non-equality assertion tests for strict inequality, as// determined by !==.  assert.notStrictEqual(actual, expected, message_opt);assert.notStrictEqual = function notStrictEqual(actual, expected, message) {  if (actual === expected) {    fail(actual, expected, message, '!==', assert.notStrictEqual);  }};function expectedException(actual, expected) {  if (!actual || !expected) {    return false;  }  if (Object.prototype.toString.call(expected) == '[object RegExp]') {    return expected.test(actual);  } else if (actual instanceof expected) {    return true;  } else if (expected.call({}, actual) === true) {    return true;  }  return false;}function _throws(shouldThrow, block, expected, message) {  var actual;  if (util.isString(expected)) {    message = expected;    expected = null;  }  try {    block();  } catch (e) {    actual = e;  }  message = (expected && expected.name ? ' (' + expected.name + ').' : '.') +            (message ? ' ' + message : '.');  if (shouldThrow && !actual) {    fail(actual, expected, 'Missing expected exception' + message);  }  if (!shouldThrow && expectedException(actual, expected)) {    fail(actual, expected, 'Got unwanted exception' + message);  }  if ((shouldThrow && actual && expected &&      !expectedException(actual, expected)) || (!shouldThrow && actual)) {    throw actual;  }}// 11. Expected to throw an error:// assert.throws(block, Error_opt, message_opt);assert.throws = function(block, /*optional*/error, /*optional*/message) {  _throws.apply(this, [true].concat(pSlice.call(arguments)));};// EXTENSION! This is annoying to write outside this module.assert.doesNotThrow = function(block, /*optional*/message) {  _throws.apply(this, [false].concat(pSlice.call(arguments)));};assert.ifError = function(err) { if (err) {throw err;}};var objectKeys = Object.keys || function (obj) {  var keys = [];  for (var key in obj) {    if (hasOwn.call(obj, key)) keys.push(key);  }  return keys;};},{"util/":5}],3:[function(require,module,exports){if (typeof Object.create === 'function') {  // implementation from standard node.js 'util' module  module.exports = function inherits(ctor, superCtor) {    ctor.super_ = superCtor    ctor.prototype = Object.create(superCtor.prototype, {      constructor: {        value: ctor,        enumerable: false,        writable: true,        configurable: true      }    });  };} else {  // old school shim for old browsers  module.exports = function inherits(ctor, superCtor) {    ctor.super_ = superCtor    var TempCtor = function () {}    TempCtor.prototype = superCtor.prototype    ctor.prototype = new TempCtor()    ctor.prototype.constructor = ctor  }}},{}],4:[function(require,module,exports){module.exports = function isBuffer(arg) {  return arg && typeof arg === 'object'    && typeof arg.copy === 'function'    && typeof arg.fill === 'function'    && typeof arg.readUInt8 === 'function';}},{}],5:[function(require,module,exports){(function (process,global){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.var formatRegExp = /%[sdj%]/g;exports.format = function(f) {  if (!isString(f)) {    var objects = [];    for (var i = 0; i < arguments.length; i++) {      objects.push(inspect(arguments[i]));    }    return objects.join(' ');  }  var i = 1;  var args = arguments;  var len = args.length;  var str = String(f).replace(formatRegExp, function(x) {    if (x === '%%') return '%';    if (i >= len) return x;    switch (x) {      case '%s': return String(args[i++]);      case '%d': return Number(args[i++]);      case '%j':        try {          return JSON.stringify(args[i++]);        } catch (_) {          return '[Circular]';        }      default:        return x;    }  });  for (var x = args[i]; i < len; x = args[++i]) {    if (isNull(x) || !isObject(x)) {      str += ' ' + x;    } else {      str += ' ' + inspect(x);    }  }  return str;};// Mark that a method should not be used.// Returns a modified function which warns once by default.// If --no-deprecation is set, then it is a no-op.exports.deprecate = function(fn, msg) {  // Allow for deprecating things in the process of starting up.  if (isUndefined(global.process)) {    return function() {      return exports.deprecate(fn, msg).apply(this, arguments);    };  }  if (process.noDeprecation === true) {    return fn;  }  var warned = false;  function deprecated() {    if (!warned) {      if (process.throwDeprecation) {        throw new Error(msg);      } else if (process.traceDeprecation) {        console.trace(msg);      } else {        console.error(msg);      }      warned = true;    }    return fn.apply(this, arguments);  }  return deprecated;};var debugs = {};var debugEnviron;exports.debuglog = function(set) {  if (isUndefined(debugEnviron))    debugEnviron = process.env.NODE_DEBUG || '';  set = set.toUpperCase();  if (!debugs[set]) {    if (new RegExp('\\b' + set + '\\b', 'i').test(debugEnviron)) {      var pid = process.pid;      debugs[set] = function() {        var msg = exports.format.apply(exports, arguments);        console.error('%s %d: %s', set, pid, msg);      };    } else {      debugs[set] = function() {};    }  }  return debugs[set];};/** * Echos the value of a value. Trys to print the value out * in the best way possible given the different types. * * @param {Object} obj The object to print out. * @param {Object} opts Optional options object that alters the output. *//* legacy: obj, showHidden, depth, colors*/function inspect(obj, opts) {  // default options  var ctx = {    seen: [],    stylize: stylizeNoColor  };  // legacy...  if (arguments.length >= 3) ctx.depth = arguments[2];  if (arguments.length >= 4) ctx.colors = arguments[3];  if (isBoolean(opts)) {    // legacy...    ctx.showHidden = opts;  } else if (opts) {    // got an "options" object    exports._extend(ctx, opts);  }  // set default options  if (isUndefined(ctx.showHidden)) ctx.showHidden = false;  if (isUndefined(ctx.depth)) ctx.depth = 2;  if (isUndefined(ctx.colors)) ctx.colors = false;  if (isUndefined(ctx.customInspect)) ctx.customInspect = true;  if (ctx.colors) ctx.stylize = stylizeWithColor;  return formatValue(ctx, obj, ctx.depth);}exports.inspect = inspect;// http://en.wikipedia.org/wiki/ANSI_escape_code#graphicsinspect.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]};// Don't use 'blue' not visible on cmd.exeinspect.styles = {  'special': 'cyan',  'number': 'yellow',  'boolean': 'yellow',  'undefined': 'grey',  'null': 'bold',  'string': 'green',  'date': 'magenta',  // "name": intentionally not styling  'regexp': 'red'};function stylizeWithColor(str, styleType) {  var style = inspect.styles[styleType];  if (style) {    return '\u001b[' + inspect.colors[style][0] + 'm' + str +           '\u001b[' + inspect.colors[style][1] + 'm';  } else {    return str;  }}function stylizeNoColor(str, styleType) {  return str;}function arrayToHash(array) {  var hash = {};  array.forEach(function(val, idx) {    hash[val] = true;  });  return hash;}function formatValue(ctx, value, recurseTimes) {  // Provide a hook for user-specified inspect functions.  // Check that value is an object with an inspect function on it  if (ctx.customInspect &&      value &&      isFunction(value.inspect) &&      // Filter out the util module, it's inspect function is special      value.inspect !== exports.inspect &&      // Also filter out any prototype objects using the circular check.      !(value.constructor && value.constructor.prototype === value)) {    var ret = value.inspect(recurseTimes, ctx);    if (!isString(ret)) {      ret = formatValue(ctx, ret, recurseTimes);    }    return ret;  }  // Primitive types cannot have properties  var primitive = formatPrimitive(ctx, value);  if (primitive) {    return primitive;  }  // Look up the keys of the object.  var keys = Object.keys(value);  var visibleKeys = arrayToHash(keys);  if (ctx.showHidden) {    keys = Object.getOwnPropertyNames(value);  }  // IE doesn't make error fields non-enumerable  // http://msdn.microsoft.com/en-us/library/ie/dww52sbt(v=vs.94).aspx  if (isError(value)      && (keys.indexOf('message') >= 0 || keys.indexOf('description') >= 0)) {    return formatError(value);  }  // Some type of object without properties can be shortcutted.  if (keys.length === 0) {    if (isFunction(value)) {      var name = value.name ? ': ' + value.name : '';      return ctx.stylize('[Function' + name + ']', 'special');    }    if (isRegExp(value)) {      return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');    }    if (isDate(value)) {      return ctx.stylize(Date.prototype.toString.call(value), 'date');    }    if (isError(value)) {      return formatError(value);    }  }  var base = '', array = false, braces = ['{', '}'];  // Make Array say that they are Array  if (isArray(value)) {    array = true;    braces = ['[', ']'];  }  // Make functions say that they are functions  if (isFunction(value)) {    var n = value.name ? ': ' + value.name : '';    base = ' [Function' + n + ']';  }  // Make RegExps say that they are RegExps  if (isRegExp(value)) {    base = ' ' + RegExp.prototype.toString.call(value);  }  // Make dates with properties first say the date  if (isDate(value)) {    base = ' ' + Date.prototype.toUTCString.call(value);  }  // Make error with message first say the error  if (isError(value)) {    base = ' ' + formatError(value);  }  if (keys.length === 0 && (!array || value.length == 0)) {    return braces[0] + base + braces[1];  }  if (recurseTimes < 0) {    if (isRegExp(value)) {      return ctx.stylize(RegExp.prototype.toString.call(value), 'regexp');    } else {      return ctx.stylize('[Object]', 'special');    }  }  ctx.seen.push(value);  var output;  if (array) {    output = formatArray(ctx, value, recurseTimes, visibleKeys, keys);  } else {    output = keys.map(function(key) {      return formatProperty(ctx, value, recurseTimes, visibleKeys, key, array);    });  }  ctx.seen.pop();  return reduceToSingleString(output, base, braces);}function formatPrimitive(ctx, value) {  if (isUndefined(value))    return ctx.stylize('undefined', 'undefined');  if (isString(value)) {    var simple = '\'' + JSON.stringify(value).replace(/^"|"$/g, '')                                             .replace(/'/g, "\\'")                                             .replace(/\\"/g, '"') + '\'';    return ctx.stylize(simple, 'string');  }  if (isNumber(value))    return ctx.stylize('' + value, 'number');  if (isBoolean(value))    return ctx.stylize('' + value, 'boolean');  // For some reason typeof null is "object", so special case here.  if (isNull(value))    return ctx.stylize('null', 'null');}function formatError(value) {  return '[' + Error.prototype.toString.call(value) + ']';}function formatArray(ctx, value, recurseTimes, visibleKeys, keys) {  var output = [];  for (var i = 0, l = value.length; i < l; ++i) {    if (hasOwnProperty(value, String(i))) {      output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,          String(i), true));    } else {      output.push('');    }  }  keys.forEach(function(key) {    if (!key.match(/^\d+$/)) {      output.push(formatProperty(ctx, value, recurseTimes, visibleKeys,          key, true));    }  });  return output;}function formatProperty(ctx, value, recurseTimes, visibleKeys, key, array) {  var name, str, desc;  desc = Object.getOwnPropertyDescriptor(value, key) || { value: value[key] };  if (desc.get) {    if (desc.set) {      str = ctx.stylize('[Getter/Setter]', 'special');    } else {      str = ctx.stylize('[Getter]', 'special');    }  } else {    if (desc.set) {      str = ctx.stylize('[Setter]', 'special');    }  }  if (!hasOwnProperty(visibleKeys, key)) {    name = '[' + key + ']';  }  if (!str) {    if (ctx.seen.indexOf(desc.value) < 0) {      if (isNull(recurseTimes)) {        str = formatValue(ctx, desc.value, null);      } else {        str = formatValue(ctx, desc.value, recurseTimes - 1);      }      if (str.indexOf('\n') > -1) {        if (array) {          str = str.split('\n').map(function(line) {            return '  ' + line;          }).join('\n').substr(2);        } else {          str = '\n' + str.split('\n').map(function(line) {            return '   ' + line;          }).join('\n');        }      }    } else {      str = ctx.stylize('[Circular]', 'special');    }  }  if (isUndefined(name)) {    if (array && key.match(/^\d+$/)) {      return str;    }    name = JSON.stringify('' + key);    if (name.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)) {      name = name.substr(1, name.length - 2);      name = ctx.stylize(name, 'name');    } else {      name = name.replace(/'/g, "\\'")                 .replace(/\\"/g, '"')                 .replace(/(^"|"$)/g, "'");      name = ctx.stylize(name, 'string');    }  }  return name + ': ' + str;}function reduceToSingleString(output, base, braces) {  var numLinesEst = 0;  var length = output.reduce(function(prev, cur) {    numLinesEst++;    if (cur.indexOf('\n') >= 0) numLinesEst++;    return prev + cur.replace(/\u001b\[\d\d?m/g, '').length + 1;  }, 0);  if (length > 60) {    return braces[0] +           (base === '' ? '' : base + '\n ') +           ' ' +           output.join(',\n  ') +           ' ' +           braces[1];  }  return braces[0] + base + ' ' + output.join(', ') + ' ' + braces[1];}// NOTE: These type checking functions intentionally don't use `instanceof`// because it is fragile and can be easily faked with `Object.create()`.function isArray(ar) {  return Array.isArray(ar);}exports.isArray = isArray;function isBoolean(arg) {  return typeof arg === 'boolean';}exports.isBoolean = isBoolean;function isNull(arg) {  return arg === null;}exports.isNull = isNull;function isNullOrUndefined(arg) {  return arg == null;}exports.isNullOrUndefined = isNullOrUndefined;function isNumber(arg) {  return typeof arg === 'number';}exports.isNumber = isNumber;function isString(arg) {  return typeof arg === 'string';}exports.isString = isString;function isSymbol(arg) {  return typeof arg === 'symbol';}exports.isSymbol = isSymbol;function isUndefined(arg) {  return arg === void 0;}exports.isUndefined = isUndefined;function isRegExp(re) {  return isObject(re) && objectToString(re) === '[object RegExp]';}exports.isRegExp = isRegExp;function isObject(arg) {  return typeof arg === 'object' && arg !== null;}exports.isObject = isObject;function isDate(d) {  return isObject(d) && objectToString(d) === '[object Date]';}exports.isDate = isDate;function isError(e) {  return isObject(e) &&      (objectToString(e) === '[object Error]' || e instanceof Error);}exports.isError = isError;function isFunction(arg) {  return typeof arg === 'function';}exports.isFunction = isFunction;function isPrimitive(arg) {  return arg === null ||         typeof arg === 'boolean' ||         typeof arg === 'number' ||         typeof arg === 'string' ||         typeof arg === 'symbol' ||  // ES6 symbol         typeof arg === 'undefined';}exports.isPrimitive = isPrimitive;exports.isBuffer = require('./support/isBuffer');function objectToString(o) {  return Object.prototype.toString.call(o);}function pad(n) {  return n < 10 ? '0' + n.toString(10) : n.toString(10);}var months = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep',              'Oct', 'Nov', 'Dec'];// 26 Feb 16:19:34function timestamp() {  var d = new Date();  var time = [pad(d.getHours()),              pad(d.getMinutes()),              pad(d.getSeconds())].join(':');  return [d.getDate(), months[d.getMonth()], time].join(' ');}// log is just a thin wrapper to console.log that prepends a timestampexports.log = function() {  console.log('%s - %s', timestamp(), exports.format.apply(exports, arguments));};/** * Inherit the prototype methods from one constructor into another. * * The Function.prototype.inherits from lang.js rewritten as a standalone * function (not on Function.prototype). NOTE: If this file is to be loaded * during bootstrapping this function needs to be rewritten using some native * functions as prototype setup using normal JavaScript does not work as * expected during bootstrapping (see mirror.js in r114903). * * @param {function} ctor Constructor function which needs to inherit the *     prototype. * @param {function} superCtor Constructor function to inherit prototype from. */exports.inherits = require('inherits');exports._extend = function(origin, add) {  // Don't do anything if add isn't an object  if (!add || !isObject(add)) return origin;  var keys = Object.keys(add);  var i = keys.length;  while (i--) {    origin[keys[i]] = add[keys[i]];  }  return origin;};function hasOwnProperty(obj, prop) {  return Object.prototype.hasOwnProperty.call(obj, prop);}}).call(this,require("7YKIPe"),typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : {})},{"./support/isBuffer":4,"7YKIPe":9,"inherits":3}],6:[function(require,module,exports){var lookup = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';;(function (exports) {	'use strict';  var Arr = (typeof Uint8Array !== 'undefined')    ? Uint8Array    : Array	var PLUS   = '+'.charCodeAt(0)	var SLASH  = '/'.charCodeAt(0)	var NUMBER = '0'.charCodeAt(0)	var LOWER  = 'a'.charCodeAt(0)	var UPPER  = 'A'.charCodeAt(0)	var PLUS_URL_SAFE = '-'.charCodeAt(0)	var SLASH_URL_SAFE = '_'.charCodeAt(0)	function decode (elt) {		var code = elt.charCodeAt(0)		if (code === PLUS ||		    code === PLUS_URL_SAFE)			return 62 // '+'		if (code === SLASH ||		    code === SLASH_URL_SAFE)			return 63 // '/'		if (code < NUMBER)			return -1 //no match		if (code < NUMBER + 10)			return code - NUMBER + 26 + 26		if (code < UPPER + 26)			return code - UPPER		if (code < LOWER + 26)			return code - LOWER + 26	}	function b64ToByteArray (b64) {		var i, j, l, tmp, placeHolders, arr		if (b64.length % 4 > 0) {			throw new Error('Invalid string. Length must be a multiple of 4')		}		// the number of equal signs (place holders)		// if there are two placeholders, than the two characters before it		// represent one byte		// if there is only one, then the three characters before it represent 2 bytes		// this is just a cheap hack to not do indexOf twice		var len = b64.length		placeHolders = '=' === b64.charAt(len - 2) ? 2 : '=' === b64.charAt(len - 1) ? 1 : 0		// base64 is 4/3 + up to two characters of the original data		arr = new Arr(b64.length * 3 / 4 - placeHolders)		// if there are placeholders, only get up to the last complete 4 chars		l = placeHolders > 0 ? b64.length - 4 : b64.length		var L = 0		function push (v) {			arr[L++] = v		}		for (i = 0, j = 0; i < l; i += 4, j += 3) {			tmp = (decode(b64.charAt(i)) << 18) | (decode(b64.charAt(i + 1)) << 12) | (decode(b64.charAt(i + 2)) << 6) | decode(b64.charAt(i + 3))			push((tmp & 0xFF0000) >> 16)			push((tmp & 0xFF00) >> 8)			push(tmp & 0xFF)		}		if (placeHolders === 2) {			tmp = (decode(b64.charAt(i)) << 2) | (decode(b64.charAt(i + 1)) >> 4)			push(tmp & 0xFF)		} else if (placeHolders === 1) {			tmp = (decode(b64.charAt(i)) << 10) | (decode(b64.charAt(i + 1)) << 4) | (decode(b64.charAt(i + 2)) >> 2)			push((tmp >> 8) & 0xFF)			push(tmp & 0xFF)		}		return arr	}	function uint8ToBase64 (uint8) {		var i,			extraBytes = uint8.length % 3, // if we have 1 byte left, pad 2 bytes			output = "",			temp, length		function encode (num) {			return lookup.charAt(num)		}		function tripletToBase64 (num) {			return encode(num >> 18 & 0x3F) + encode(num >> 12 & 0x3F) + encode(num >> 6 & 0x3F) + encode(num & 0x3F)		}		// go through the array every three bytes, we'll deal with trailing stuff later		for (i = 0, length = uint8.length - extraBytes; i < length; i += 3) {			temp = (uint8[i] << 16) + (uint8[i + 1] << 8) + (uint8[i + 2])			output += tripletToBase64(temp)		}		// pad the end with zeros, but make sure to not forget the extra bytes		switch (extraBytes) {			case 1:				temp = uint8[uint8.length - 1]				output += encode(temp >> 2)				output += encode((temp << 4) & 0x3F)				output += '=='				break			case 2:				temp = (uint8[uint8.length - 2] << 8) + (uint8[uint8.length - 1])				output += encode(temp >> 10)				output += encode((temp >> 4) & 0x3F)				output += encode((temp << 2) & 0x3F)				output += '='				break		}		return output	}	exports.toByteArray = b64ToByteArray	exports.fromByteArray = uint8ToBase64}(typeof exports === 'undefined' ? (this.base64js = {}) : exports))},{}],7:[function(require,module,exports){/*! * The buffer module from node.js, for the browser. * * @author   Feross Aboukhadijeh <feross@feross.org> <http://feross.org> * @license  MIT */var base64 = require('base64-js')var ieee754 = require('ieee754')exports.Buffer = Bufferexports.SlowBuffer = Bufferexports.INSPECT_MAX_BYTES = 50Buffer.poolSize = 8192/** * If `Buffer._useTypedArrays`: *   === true    Use Uint8Array implementation (fastest) *   === false   Use Object implementation (compatible down to IE6) */Buffer._useTypedArrays = (function () {  // Detect if browser supports Typed Arrays. Supported browsers are IE 10+, Firefox 4+,  // Chrome 7+, Safari 5.1+, Opera 11.6+, iOS 4.2+. If the browser does not support adding  // properties to `Uint8Array` instances, then that's the same as no `Uint8Array` support  // because we need to be able to add all the node Buffer API methods. This is an issue  // in Firefox 4-29. Now fixed: https://bugzilla.mozilla.org/show_bug.cgi?id=695438  try {    var buf = new ArrayBuffer(0)    var arr = new Uint8Array(buf)    arr.foo = function () { return 42 }    return 42 === arr.foo() &&        typeof arr.subarray === 'function' // Chrome 9-10 lack `subarray`  } catch (e) {    return false  }})()/** * Class: Buffer * ============= * * The Buffer constructor returns instances of `Uint8Array` that are augmented * with function properties for all the node `Buffer` API functions. We use * `Uint8Array` so that square bracket notation works as expected -- it returns * a single octet. * * By augmenting the instances, we can avoid modifying the `Uint8Array` * prototype. */function Buffer (subject, encoding, noZero) {  if (!(this instanceof Buffer))    return new Buffer(subject, encoding, noZero)  var type = typeof subject  // Workaround: node's base64 implementation allows for non-padded strings  // while base64-js does not.  if (encoding === 'base64' && type === 'string') {    subject = stringtrim(subject)    while (subject.length % 4 !== 0) {      subject = subject + '='    }  }  // Find the length  var length  if (type === 'number')    length = coerce(subject)  else if (type === 'string')    length = Buffer.byteLength(subject, encoding)  else if (type === 'object')    length = coerce(subject.length) // assume that object is array-like  else    throw new Error('First argument needs to be a number, array or string.')  var buf  if (Buffer._useTypedArrays) {    // Preferred: Return an augmented `Uint8Array` instance for best performance    buf = Buffer._augment(new Uint8Array(length))  } else {    // Fallback: Return THIS instance of Buffer (created by `new`)    buf = this    buf.length = length    buf._isBuffer = true  }  var i  if (Buffer._useTypedArrays && typeof subject.byteLength === 'number') {    // Speed optimization -- use set if we're copying from a typed array    buf._set(subject)  } else if (isArrayish(subject)) {    // Treat array-ish objects as a byte array    for (i = 0; i < length; i++) {      if (Buffer.isBuffer(subject))        buf[i] = subject.readUInt8(i)      else        buf[i] = subject[i]    }  } else if (type === 'string') {    buf.write(subject, 0, encoding)  } else if (type === 'number' && !Buffer._useTypedArrays && !noZero) {    for (i = 0; i < length; i++) {      buf[i] = 0    }  }  return buf}// STATIC METHODS// ==============Buffer.isEncoding = function (encoding) {  switch (String(encoding).toLowerCase()) {    case 'hex':    case 'utf8':    case 'utf-8':    case 'ascii':    case 'binary':    case 'base64':    case 'raw':    case 'ucs2':    case 'ucs-2':    case 'utf16le':    case 'utf-16le':      return true    default:      return false  }}Buffer.isBuffer = function (b) {  return !!(b !== null && b !== undefined && b._isBuffer)}Buffer.byteLength = function (str, encoding) {  var ret  str = str + ''  switch (encoding || 'utf8') {    case 'hex':      ret = str.length / 2      break    case 'utf8':    case 'utf-8':      ret = utf8ToBytes(str).length      break    case 'ascii':    case 'binary':    case 'raw':      ret = str.length      break    case 'base64':      ret = base64ToBytes(str).length      break    case 'ucs2':    case 'ucs-2':    case 'utf16le':    case 'utf-16le':      ret = str.length * 2      break    default:      throw new Error('Unknown encoding')  }  return ret}Buffer.concat = function (list, totalLength) {  assert(isArray(list), 'Usage: Buffer.concat(list, [totalLength])\n' +      'list should be an Array.')  if (list.length === 0) {    return new Buffer(0)  } else if (list.length === 1) {    return list[0]  }  var i  if (typeof totalLength !== 'number') {    totalLength = 0    for (i = 0; i < list.length; i++) {      totalLength += list[i].length    }  }  var buf = new Buffer(totalLength)  var pos = 0  for (i = 0; i < list.length; i++) {    var item = list[i]    item.copy(buf, pos)    pos += item.length  }  return buf}// BUFFER INSTANCE METHODS// =======================function _hexWrite (buf, string, offset, length) {  offset = Number(offset) || 0  var remaining = buf.length - offset  if (!length) {    length = remaining  } else {    length = Number(length)    if (length > remaining) {      length = remaining    }  }  // must be an even number of digits  var strLen = string.length  assert(strLen % 2 === 0, 'Invalid hex string')  if (length > strLen / 2) {    length = strLen / 2  }  for (var i = 0; i < length; i++) {    var byte = parseInt(string.substr(i * 2, 2), 16)    assert(!isNaN(byte), 'Invalid hex string')    buf[offset + i] = byte  }  Buffer._charsWritten = i * 2  return i}function _utf8Write (buf, string, offset, length) {  var charsWritten = Buffer._charsWritten =    blitBuffer(utf8ToBytes(string), buf, offset, length)  return charsWritten}function _asciiWrite (buf, string, offset, length) {  var charsWritten = Buffer._charsWritten =    blitBuffer(asciiToBytes(string), buf, offset, length)  return charsWritten}function _binaryWrite (buf, string, offset, length) {  return _asciiWrite(buf, string, offset, length)}function _base64Write (buf, string, offset, length) {  var charsWritten = Buffer._charsWritten =    blitBuffer(base64ToBytes(string), buf, offset, length)  return charsWritten}function _utf16leWrite (buf, string, offset, length) {  var charsWritten = Buffer._charsWritten =    blitBuffer(utf16leToBytes(string), buf, offset, length)  return charsWritten}Buffer.prototype.write = function (string, offset, length, encoding) {  // Support both (string, offset, length, encoding)  // and the legacy (string, encoding, offset, length)  if (isFinite(offset)) {    if (!isFinite(length)) {      encoding = length      length = undefined    }  } else {  // legacy    var swap = encoding    encoding = offset    offset = length    length = swap  }  offset = Number(offset) || 0  var remaining = this.length - offset  if (!length) {    length = remaining  } else {    length = Number(length)    if (length > remaining) {      length = remaining    }  }  encoding = String(encoding || 'utf8').toLowerCase()  var ret  switch (encoding) {    case 'hex':      ret = _hexWrite(this, string, offset, length)      break    case 'utf8':    case 'utf-8':      ret = _utf8Write(this, string, offset, length)      break    case 'ascii':      ret = _asciiWrite(this, string, offset, length)      break    case 'binary':      ret = _binaryWrite(this, string, offset, length)      break    case 'base64':      ret = _base64Write(this, string, offset, length)      break    case 'ucs2':    case 'ucs-2':    case 'utf16le':    case 'utf-16le':      ret = _utf16leWrite(this, string, offset, length)      break    default:      throw new Error('Unknown encoding')  }  return ret}Buffer.prototype.toString = function (encoding, start, end) {  var self = this  encoding = String(encoding || 'utf8').toLowerCase()  start = Number(start) || 0  end = (end !== undefined)    ? Number(end)    : end = self.length  // Fastpath empty strings  if (end === start)    return ''  var ret  switch (encoding) {    case 'hex':      ret = _hexSlice(self, start, end)      break    case 'utf8':    case 'utf-8':      ret = _utf8Slice(self, start, end)      break    case 'ascii':      ret = _asciiSlice(self, start, end)      break    case 'binary':      ret = _binarySlice(self, start, end)      break    case 'base64':      ret = _base64Slice(self, start, end)      break    case 'ucs2':    case 'ucs-2':    case 'utf16le':    case 'utf-16le':      ret = _utf16leSlice(self, start, end)      break    default:      throw new Error('Unknown encoding')  }  return ret}Buffer.prototype.toJSON = function () {  return {    type: 'Buffer',    data: Array.prototype.slice.call(this._arr || this, 0)  }}// copy(targetBuffer, targetStart=0, sourceStart=0, sourceEnd=buffer.length)Buffer.prototype.copy = function (target, target_start, start, end) {  var source = this  if (!start) start = 0  if (!end && end !== 0) end = this.length  if (!target_start) target_start = 0  // Copy 0 bytes; we're done  if (end === start) return  if (target.length === 0 || source.length === 0) return  // Fatal error conditions  assert(end >= start, 'sourceEnd < sourceStart')  assert(target_start >= 0 && target_start < target.length,      'targetStart out of bounds')  assert(start >= 0 && start < source.length, 'sourceStart out of bounds')  assert(end >= 0 && end <= source.length, 'sourceEnd out of bounds')  // Are we oob?  if (end > this.length)    end = this.length  if (target.length - target_start < end - start)    end = target.length - target_start + start  var len = end - start  if (len < 100 || !Buffer._useTypedArrays) {    for (var i = 0; i < len; i++)      target[i + target_start] = this[i + start]  } else {    target._set(this.subarray(start, start + len), target_start)  }}function _base64Slice (buf, start, end) {  if (start === 0 && end === buf.length) {    return base64.fromByteArray(buf)  } else {    return base64.fromByteArray(buf.slice(start, end))  }}function _utf8Slice (buf, start, end) {  var res = ''  var tmp = ''  end = Math.min(buf.length, end)  for (var i = start; i < end; i++) {    if (buf[i] <= 0x7F) {      res += decodeUtf8Char(tmp) + String.fromCharCode(buf[i])      tmp = ''    } else {      tmp += '%' + buf[i].toString(16)    }  }  return res + decodeUtf8Char(tmp)}function _asciiSlice (buf, start, end) {  var ret = ''  end = Math.min(buf.length, end)  for (var i = start; i < end; i++)    ret += String.fromCharCode(buf[i])  return ret}function _binarySlice (buf, start, end) {  return _asciiSlice(buf, start, end)}function _hexSlice (buf, start, end) {  var len = buf.length  if (!start || start < 0) start = 0  if (!end || end < 0 || end > len) end = len  var out = ''  for (var i = start; i < end; i++) {    out += toHex(buf[i])  }  return out}function _utf16leSlice (buf, start, end) {  var bytes = buf.slice(start, end)  var res = ''  for (var i = 0; i < bytes.length; i += 2) {    res += String.fromCharCode(bytes[i] + bytes[i+1] * 256)  }  return res}Buffer.prototype.slice = function (start, end) {  var len = this.length  start = clamp(start, len, 0)  end = clamp(end, len, len)  if (Buffer._useTypedArrays) {    return Buffer._augment(this.subarray(start, end))  } else {    var sliceLen = end - start    var newBuf = new Buffer(sliceLen, undefined, true)    for (var i = 0; i < sliceLen; i++) {      newBuf[i] = this[i + start]    }    return newBuf  }}// `get` will be removed in Node 0.13+Buffer.prototype.get = function (offset) {  console.log('.get() is deprecated. Access using array indexes instead.')  return this.readUInt8(offset)}// `set` will be removed in Node 0.13+Buffer.prototype.set = function (v, offset) {  console.log('.set() is deprecated. Access using array indexes instead.')  return this.writeUInt8(v, offset)}Buffer.prototype.readUInt8 = function (offset, noAssert) {  if (!noAssert) {    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset < this.length, 'Trying to read beyond buffer length')  }  if (offset >= this.length)    return  return this[offset]}function _readUInt16 (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 1 < buf.length, 'Trying to read beyond buffer length')  }  var len = buf.length  if (offset >= len)    return  var val  if (littleEndian) {    val = buf[offset]    if (offset + 1 < len)      val |= buf[offset + 1] << 8  } else {    val = buf[offset] << 8    if (offset + 1 < len)      val |= buf[offset + 1]  }  return val}Buffer.prototype.readUInt16LE = function (offset, noAssert) {  return _readUInt16(this, offset, true, noAssert)}Buffer.prototype.readUInt16BE = function (offset, noAssert) {  return _readUInt16(this, offset, false, noAssert)}function _readUInt32 (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 3 < buf.length, 'Trying to read beyond buffer length')  }  var len = buf.length  if (offset >= len)    return  var val  if (littleEndian) {    if (offset + 2 < len)      val = buf[offset + 2] << 16    if (offset + 1 < len)      val |= buf[offset + 1] << 8    val |= buf[offset]    if (offset + 3 < len)      val = val + (buf[offset + 3] << 24 >>> 0)  } else {    if (offset + 1 < len)      val = buf[offset + 1] << 16    if (offset + 2 < len)      val |= buf[offset + 2] << 8    if (offset + 3 < len)      val |= buf[offset + 3]    val = val + (buf[offset] << 24 >>> 0)  }  return val}Buffer.prototype.readUInt32LE = function (offset, noAssert) {  return _readUInt32(this, offset, true, noAssert)}Buffer.prototype.readUInt32BE = function (offset, noAssert) {  return _readUInt32(this, offset, false, noAssert)}Buffer.prototype.readInt8 = function (offset, noAssert) {  if (!noAssert) {    assert(offset !== undefined && offset !== null,        'missing offset')    assert(offset < this.length, 'Trying to read beyond buffer length')  }  if (offset >= this.length)    return  var neg = this[offset] & 0x80  if (neg)    return (0xff - this[offset] + 1) * -1  else    return this[offset]}function _readInt16 (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 1 < buf.length, 'Trying to read beyond buffer length')  }  var len = buf.length  if (offset >= len)    return  var val = _readUInt16(buf, offset, littleEndian, true)  var neg = val & 0x8000  if (neg)    return (0xffff - val + 1) * -1  else    return val}Buffer.prototype.readInt16LE = function (offset, noAssert) {  return _readInt16(this, offset, true, noAssert)}Buffer.prototype.readInt16BE = function (offset, noAssert) {  return _readInt16(this, offset, false, noAssert)}function _readInt32 (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 3 < buf.length, 'Trying to read beyond buffer length')  }  var len = buf.length  if (offset >= len)    return  var val = _readUInt32(buf, offset, littleEndian, true)  var neg = val & 0x80000000  if (neg)    return (0xffffffff - val + 1) * -1  else    return val}Buffer.prototype.readInt32LE = function (offset, noAssert) {  return _readInt32(this, offset, true, noAssert)}Buffer.prototype.readInt32BE = function (offset, noAssert) {  return _readInt32(this, offset, false, noAssert)}function _readFloat (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset + 3 < buf.length, 'Trying to read beyond buffer length')  }  return ieee754.read(buf, offset, littleEndian, 23, 4)}Buffer.prototype.readFloatLE = function (offset, noAssert) {  return _readFloat(this, offset, true, noAssert)}Buffer.prototype.readFloatBE = function (offset, noAssert) {  return _readFloat(this, offset, false, noAssert)}function _readDouble (buf, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset + 7 < buf.length, 'Trying to read beyond buffer length')  }  return ieee754.read(buf, offset, littleEndian, 52, 8)}Buffer.prototype.readDoubleLE = function (offset, noAssert) {  return _readDouble(this, offset, true, noAssert)}Buffer.prototype.readDoubleBE = function (offset, noAssert) {  return _readDouble(this, offset, false, noAssert)}Buffer.prototype.writeUInt8 = function (value, offset, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset < this.length, 'trying to write beyond buffer length')    verifuint(value, 0xff)  }  if (offset >= this.length) return  this[offset] = value}function _writeUInt16 (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 1 < buf.length, 'trying to write beyond buffer length')    verifuint(value, 0xffff)  }  var len = buf.length  if (offset >= len)    return  for (var i = 0, j = Math.min(len - offset, 2); i < j; i++) {    buf[offset + i] =        (value & (0xff << (8 * (littleEndian ? i : 1 - i)))) >>>            (littleEndian ? i : 1 - i) * 8  }}Buffer.prototype.writeUInt16LE = function (value, offset, noAssert) {  _writeUInt16(this, value, offset, true, noAssert)}Buffer.prototype.writeUInt16BE = function (value, offset, noAssert) {  _writeUInt16(this, value, offset, false, noAssert)}function _writeUInt32 (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 3 < buf.length, 'trying to write beyond buffer length')    verifuint(value, 0xffffffff)  }  var len = buf.length  if (offset >= len)    return  for (var i = 0, j = Math.min(len - offset, 4); i < j; i++) {    buf[offset + i] =        (value >>> (littleEndian ? i : 3 - i) * 8) & 0xff  }}Buffer.prototype.writeUInt32LE = function (value, offset, noAssert) {  _writeUInt32(this, value, offset, true, noAssert)}Buffer.prototype.writeUInt32BE = function (value, offset, noAssert) {  _writeUInt32(this, value, offset, false, noAssert)}Buffer.prototype.writeInt8 = function (value, offset, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset < this.length, 'Trying to write beyond buffer length')    verifsint(value, 0x7f, -0x80)  }  if (offset >= this.length)    return  if (value >= 0)    this.writeUInt8(value, offset, noAssert)  else    this.writeUInt8(0xff + value + 1, offset, noAssert)}function _writeInt16 (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 1 < buf.length, 'Trying to write beyond buffer length')    verifsint(value, 0x7fff, -0x8000)  }  var len = buf.length  if (offset >= len)    return  if (value >= 0)    _writeUInt16(buf, value, offset, littleEndian, noAssert)  else    _writeUInt16(buf, 0xffff + value + 1, offset, littleEndian, noAssert)}Buffer.prototype.writeInt16LE = function (value, offset, noAssert) {  _writeInt16(this, value, offset, true, noAssert)}Buffer.prototype.writeInt16BE = function (value, offset, noAssert) {  _writeInt16(this, value, offset, false, noAssert)}function _writeInt32 (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 3 < buf.length, 'Trying to write beyond buffer length')    verifsint(value, 0x7fffffff, -0x80000000)  }  var len = buf.length  if (offset >= len)    return  if (value >= 0)    _writeUInt32(buf, value, offset, littleEndian, noAssert)  else    _writeUInt32(buf, 0xffffffff + value + 1, offset, littleEndian, noAssert)}Buffer.prototype.writeInt32LE = function (value, offset, noAssert) {  _writeInt32(this, value, offset, true, noAssert)}Buffer.prototype.writeInt32BE = function (value, offset, noAssert) {  _writeInt32(this, value, offset, false, noAssert)}function _writeFloat (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 3 < buf.length, 'Trying to write beyond buffer length')    verifIEEE754(value, 3.4028234663852886e+38, -3.4028234663852886e+38)  }  var len = buf.length  if (offset >= len)    return  ieee754.write(buf, value, offset, littleEndian, 23, 4)}Buffer.prototype.writeFloatLE = function (value, offset, noAssert) {  _writeFloat(this, value, offset, true, noAssert)}Buffer.prototype.writeFloatBE = function (value, offset, noAssert) {  _writeFloat(this, value, offset, false, noAssert)}function _writeDouble (buf, value, offset, littleEndian, noAssert) {  if (!noAssert) {    assert(value !== undefined && value !== null, 'missing value')    assert(typeof littleEndian === 'boolean', 'missing or invalid endian')    assert(offset !== undefined && offset !== null, 'missing offset')    assert(offset + 7 < buf.length,        'Trying to write beyond buffer length')    verifIEEE754(value, 1.7976931348623157E+308, -1.7976931348623157E+308)  }  var len = buf.length  if (offset >= len)    return  ieee754.write(buf, value, offset, littleEndian, 52, 8)}Buffer.prototype.writeDoubleLE = function (value, offset, noAssert) {  _writeDouble(this, value, offset, true, noAssert)}Buffer.prototype.writeDoubleBE = function (value, offset, noAssert) {  _writeDouble(this, value, offset, false, noAssert)}// fill(value, start=0, end=buffer.length)Buffer.prototype.fill = function (value, start, end) {  if (!value) value = 0  if (!start) start = 0  if (!end) end = this.length  if (typeof value === 'string') {    value = value.charCodeAt(0)  }  assert(typeof value === 'number' && !isNaN(value), 'value is not a number')  assert(end >= start, 'end < start')  // Fill 0 bytes; we're done  if (end === start) return  if (this.length === 0) return  assert(start >= 0 && start < this.length, 'start out of bounds')  assert(end >= 0 && end <= this.length, 'end out of bounds')  for (var i = start; i < end; i++) {    this[i] = value  }}Buffer.prototype.inspect = function () {  var out = []  var len = this.length  for (var i = 0; i < len; i++) {    out[i] = toHex(this[i])    if (i === exports.INSPECT_MAX_BYTES) {      out[i + 1] = '...'      break    }  }  return '<Buffer ' + out.join(' ') + '>'}/** * Creates a new `ArrayBuffer` with the *copied* memory of the buffer instance. * Added in Node 0.12. Only available in browsers that support ArrayBuffer. */Buffer.prototype.toArrayBuffer = function () {  if (typeof Uint8Array !== 'undefined') {    if (Buffer._useTypedArrays) {      return (new Buffer(this)).buffer    } else {      var buf = new Uint8Array(this.length)      for (var i = 0, len = buf.length; i < len; i += 1)        buf[i] = this[i]      return buf.buffer    }  } else {    throw new Error('Buffer.toArrayBuffer not supported in this browser')  }}// HELPER FUNCTIONS// ================function stringtrim (str) {  if (str.trim) return str.trim()  return str.replace(/^\s+|\s+$/g, '')}var BP = Buffer.prototype/** * Augment a Uint8Array *instance* (not the Uint8Array class!) with Buffer methods */Buffer._augment = function (arr) {  arr._isBuffer = true  // save reference to original Uint8Array get/set methods before overwriting  arr._get = arr.get  arr._set = arr.set  // deprecated, will be removed in node 0.13+  arr.get = BP.get  arr.set = BP.set  arr.write = BP.write  arr.toString = BP.toString  arr.toLocaleString = BP.toString  arr.toJSON = BP.toJSON  arr.copy = BP.copy  arr.slice = BP.slice  arr.readUInt8 = BP.readUInt8  arr.readUInt16LE = BP.readUInt16LE  arr.readUInt16BE = BP.readUInt16BE  arr.readUInt32LE = BP.readUInt32LE  arr.readUInt32BE = BP.readUInt32BE  arr.readInt8 = BP.readInt8  arr.readInt16LE = BP.readInt16LE  arr.readInt16BE = BP.readInt16BE  arr.readInt32LE = BP.readInt32LE  arr.readInt32BE = BP.readInt32BE  arr.readFloatLE = BP.readFloatLE  arr.readFloatBE = BP.readFloatBE  arr.readDoubleLE = BP.readDoubleLE  arr.readDoubleBE = BP.readDoubleBE  arr.writeUInt8 = BP.writeUInt8  arr.writeUInt16LE = BP.writeUInt16LE  arr.writeUInt16BE = BP.writeUInt16BE  arr.writeUInt32LE = BP.writeUInt32LE  arr.writeUInt32BE = BP.writeUInt32BE  arr.writeInt8 = BP.writeInt8  arr.writeInt16LE = BP.writeInt16LE  arr.writeInt16BE = BP.writeInt16BE  arr.writeInt32LE = BP.writeInt32LE  arr.writeInt32BE = BP.writeInt32BE  arr.writeFloatLE = BP.writeFloatLE  arr.writeFloatBE = BP.writeFloatBE  arr.writeDoubleLE = BP.writeDoubleLE  arr.writeDoubleBE = BP.writeDoubleBE  arr.fill = BP.fill  arr.inspect = BP.inspect  arr.toArrayBuffer = BP.toArrayBuffer  return arr}// slice(start, end)function clamp (index, len, defaultValue) {  if (typeof index !== 'number') return defaultValue  index = ~~index;  // Coerce to integer.  if (index >= len) return len  if (index >= 0) return index  index += len  if (index >= 0) return index  return 0}function coerce (length) {  // Coerce length to a number (possibly NaN), round up  // in case it's fractional (e.g. 123.456) then do a  // double negate to coerce a NaN to 0. Easy, right?  length = ~~Math.ceil(+length)  return length < 0 ? 0 : length}function isArray (subject) {  return (Array.isArray || function (subject) {    return Object.prototype.toString.call(subject) === '[object Array]'  })(subject)}function isArrayish (subject) {  return isArray(subject) || Buffer.isBuffer(subject) ||      subject && typeof subject === 'object' &&      typeof subject.length === 'number'}function toHex (n) {  if (n < 16) return '0' + n.toString(16)  return n.toString(16)}function utf8ToBytes (str) {  var byteArray = []  for (var i = 0; i < str.length; i++) {    var b = str.charCodeAt(i)    if (b <= 0x7F)      byteArray.push(str.charCodeAt(i))    else {      var start = i      if (b >= 0xD800 && b <= 0xDFFF) i++      var h = encodeURIComponent(str.slice(start, i+1)).substr(1).split('%')      for (var j = 0; j < h.length; j++)        byteArray.push(parseInt(h[j], 16))    }  }  return byteArray}function asciiToBytes (str) {  var byteArray = []  for (var i = 0; i < str.length; i++) {    // Node's code seems to be doing this and not & 0x7F..    byteArray.push(str.charCodeAt(i) & 0xFF)  }  return byteArray}function utf16leToBytes (str) {  var c, hi, lo  var byteArray = []  for (var i = 0; i < str.length; i++) {    c = str.charCodeAt(i)    hi = c >> 8    lo = c % 256    byteArray.push(lo)    byteArray.push(hi)  }  return byteArray}function base64ToBytes (str) {  return base64.toByteArray(str)}function blitBuffer (src, dst, offset, length) {  var pos  for (var i = 0; i < length; i++) {    if ((i + offset >= dst.length) || (i >= src.length))      break    dst[i + offset] = src[i]  }  return i}function decodeUtf8Char (str) {  try {    return decodeURIComponent(str)  } catch (err) {    return String.fromCharCode(0xFFFD) // UTF 8 invalid char  }}/* * We have to make sure that the value is a valid integer. This means that it * is non-negative. It has no fractional component and that it does not * exceed the maximum allowed value. */function verifuint (value, max) {  assert(typeof value === 'number', 'cannot write a non-number as a number')  assert(value >= 0, 'specified a negative value for writing an unsigned value')  assert(value <= max, 'value is larger than maximum value for type')  assert(Math.floor(value) === value, 'value has a fractional component')}function verifsint (value, max, min) {  assert(typeof value === 'number', 'cannot write a non-number as a number')  assert(value <= max, 'value larger than maximum allowed value')  assert(value >= min, 'value smaller than minimum allowed value')  assert(Math.floor(value) === value, 'value has a fractional component')}function verifIEEE754 (value, max, min) {  assert(typeof value === 'number', 'cannot write a non-number as a number')  assert(value <= max, 'value larger than maximum allowed value')  assert(value >= min, 'value smaller than minimum allowed value')}function assert (test, message) {  if (!test) throw new Error(message || 'Failed assertion')}},{"base64-js":6,"ieee754":18}],8:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.function EventEmitter() {  this._events = this._events || {};  this._maxListeners = this._maxListeners || undefined;}module.exports = EventEmitter;// Backwards-compat with node 0.10.xEventEmitter.EventEmitter = EventEmitter;EventEmitter.prototype._events = undefined;EventEmitter.prototype._maxListeners = undefined;// By default EventEmitters will print a warning if more than 10 listeners are// added to it. This is a useful default which helps finding memory leaks.EventEmitter.defaultMaxListeners = 10;// Obviously not all Emitters should be limited to 10. This function allows// that to be increased. Set to zero for unlimited.EventEmitter.prototype.setMaxListeners = function(n) {  if (!isNumber(n) || n < 0 || isNaN(n))    throw TypeError('n must be a positive number');  this._maxListeners = n;  return this;};EventEmitter.prototype.emit = function(type) {  var er, handler, len, args, i, listeners;  if (!this._events)    this._events = {};  // If there is no 'error' event listener then throw.  if (type === 'error') {    if (!this._events.error ||        (isObject(this._events.error) && !this._events.error.length)) {      er = arguments[1];      if (er instanceof Error) {        throw er; // Unhandled 'error' event      }      throw TypeError('Uncaught, unspecified "error" event.');    }  }  handler = this._events[type];  if (isUndefined(handler))    return false;  if (isFunction(handler)) {    switch (arguments.length) {      // fast cases      case 1:        handler.call(this);        break;      case 2:        handler.call(this, arguments[1]);        break;      case 3:        handler.call(this, arguments[1], arguments[2]);        break;      // slower      default:        len = arguments.length;        args = new Array(len - 1);        for (i = 1; i < len; i++)          args[i - 1] = arguments[i];        handler.apply(this, args);    }  } else if (isObject(handler)) {    len = arguments.length;    args = new Array(len - 1);    for (i = 1; i < len; i++)      args[i - 1] = arguments[i];    listeners = handler.slice();    len = listeners.length;    for (i = 0; i < len; i++)      listeners[i].apply(this, args);  }  return true;};EventEmitter.prototype.addListener = function(type, listener) {  var m;  if (!isFunction(listener))    throw TypeError('listener must be a function');  if (!this._events)    this._events = {};  // To avoid recursion in the case that type === "newListener"! Before  // adding it to the listeners, first emit "newListener".  if (this._events.newListener)    this.emit('newListener', type,              isFunction(listener.listener) ?              listener.listener : listener);  if (!this._events[type])    // Optimize the case of one listener. Don't need the extra array object.    this._events[type] = listener;  else if (isObject(this._events[type]))    // If we've already got an array, just append.    this._events[type].push(listener);  else    // Adding the second element, need to change to array.    this._events[type] = [this._events[type], listener];  // Check for listener leak  if (isObject(this._events[type]) && !this._events[type].warned) {    var m;    if (!isUndefined(this._maxListeners)) {      m = this._maxListeners;    } else {      m = EventEmitter.defaultMaxListeners;    }    if (m && m > 0 && this._events[type].length > m) {      this._events[type].warned = true;      console.error('(node) warning: possible EventEmitter memory ' +                    'leak detected. %d listeners added. ' +                    'Use emitter.setMaxListeners() to increase limit.',                    this._events[type].length);      if (typeof console.trace === 'function') {        // not supported in IE 10        console.trace();      }    }  }  return this;};EventEmitter.prototype.on = EventEmitter.prototype.addListener;EventEmitter.prototype.once = function(type, listener) {  if (!isFunction(listener))    throw TypeError('listener must be a function');  var fired = false;  function g() {    this.removeListener(type, g);    if (!fired) {      fired = true;      listener.apply(this, arguments);    }  }  g.listener = listener;  this.on(type, g);  return this;};// emits a 'removeListener' event iff the listener was removedEventEmitter.prototype.removeListener = function(type, listener) {  var list, position, length, i;  if (!isFunction(listener))    throw TypeError('listener must be a function');  if (!this._events || !this._events[type])    return this;  list = this._events[type];  length = list.length;  position = -1;  if (list === listener ||      (isFunction(list.listener) && list.listener === listener)) {    delete this._events[type];    if (this._events.removeListener)      this.emit('removeListener', type, listener);  } else if (isObject(list)) {    for (i = length; i-- > 0;) {      if (list[i] === listener ||          (list[i].listener && list[i].listener === listener)) {        position = i;        break;      }    }    if (position < 0)      return this;    if (list.length === 1) {      list.length = 0;      delete this._events[type];    } else {      list.splice(position, 1);    }    if (this._events.removeListener)      this.emit('removeListener', type, listener);  }  return this;};EventEmitter.prototype.removeAllListeners = function(type) {  var key, listeners;  if (!this._events)    return this;  // not listening for removeListener, no need to emit  if (!this._events.removeListener) {    if (arguments.length === 0)      this._events = {};    else if (this._events[type])      delete this._events[type];    return this;  }  // emit removeListener for all listeners on all events  if (arguments.length === 0) {    for (key in this._events) {      if (key === 'removeListener') continue;      this.removeAllListeners(key);    }    this.removeAllListeners('removeListener');    this._events = {};    return this;  }  listeners = this._events[type];  if (isFunction(listeners)) {    this.removeListener(type, listeners);  } else {    // LIFO order    while (listeners.length)      this.removeListener(type, listeners[listeners.length - 1]);  }  delete this._events[type];  return this;};EventEmitter.prototype.listeners = function(type) {  var ret;  if (!this._events || !this._events[type])    ret = [];  else if (isFunction(this._events[type]))    ret = [this._events[type]];  else    ret = this._events[type].slice();  return ret;};EventEmitter.listenerCount = function(emitter, type) {  var ret;  if (!emitter._events || !emitter._events[type])    ret = 0;  else if (isFunction(emitter._events[type]))    ret = 1;  else    ret = emitter._events[type].length;  return ret;};function isFunction(arg) {  return typeof arg === 'function';}function isNumber(arg) {  return typeof arg === 'number';}function isObject(arg) {  return typeof arg === 'object' && arg !== null;}function isUndefined(arg) {  return arg === void 0;}},{}],9:[function(require,module,exports){// shim for using process in browservar process = module.exports = {};process.nextTick = (function () {    var canSetImmediate = typeof window !== 'undefined'    && window.setImmediate;    var canPost = typeof window !== 'undefined'    && window.postMessage && window.addEventListener    ;    if (canSetImmediate) {        return function (f) { return window.setImmediate(f) };    }    if (canPost) {        var queue = [];        window.addEventListener('message', function (ev) {            var source = ev.source;            if ((source === window || source === null) && ev.data === 'process-tick') {                ev.stopPropagation();                if (queue.length > 0) {                    var fn = queue.shift();                    fn();                }            }        }, true);        return function nextTick(fn) {            queue.push(fn);            window.postMessage('process-tick', '*');        };    }    return function nextTick(fn) {        setTimeout(fn, 0);    };})();process.title = 'browser';process.browser = true;process.env = {};process.argv = [];function noop() {}process.on = noop;process.addListener = noop;process.once = noop;process.off = noop;process.removeListener = noop;process.removeAllListeners = noop;process.emit = noop;process.binding = function (name) {    throw new Error('process.binding is not supported');}// TODO(shtylman)process.cwd = function () { return '/' };process.chdir = function (dir) {    throw new Error('process.chdir is not supported');};},{}],10:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.// a duplex stream is just a stream that is both readable and writable.// Since JS doesn't have multiple prototypal inheritance, this class// prototypally inherits from Readable, and then parasitically from// Writable.module.exports = Duplex;var inherits = require('inherits');var setImmediate = require('process/browser.js').nextTick;var Readable = require('./readable.js');var Writable = require('./writable.js');inherits(Duplex, Readable);Duplex.prototype.write = Writable.prototype.write;Duplex.prototype.end = Writable.prototype.end;Duplex.prototype._write = Writable.prototype._write;function Duplex(options) {  if (!(this instanceof Duplex))    return new Duplex(options);  Readable.call(this, options);  Writable.call(this, options);  if (options && options.readable === false)    this.readable = false;  if (options && options.writable === false)    this.writable = false;  this.allowHalfOpen = true;  if (options && options.allowHalfOpen === false)    this.allowHalfOpen = false;  this.once('end', onend);}// the no-half-open enforcerfunction onend() {  // if we allow half-open state, or if the writable side ended,  // then we're ok.  if (this.allowHalfOpen || this._writableState.ended)    return;  // no more data can be written.  // But allow more writes to happen in this tick.  var self = this;  setImmediate(function () {    self.end();  });}},{"./readable.js":14,"./writable.js":16,"inherits":19,"process/browser.js":12}],11:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.module.exports = Stream;var EE = require('events').EventEmitter;var inherits = require('inherits');inherits(Stream, EE);Stream.Readable = require('./readable.js');Stream.Writable = require('./writable.js');Stream.Duplex = require('./duplex.js');Stream.Transform = require('./transform.js');Stream.PassThrough = require('./passthrough.js');// Backwards-compat with node 0.4.xStream.Stream = Stream;// old-style streams.  Note that the pipe method (the only relevant// part of this class) is overridden in the Readable class.function Stream() {  EE.call(this);}Stream.prototype.pipe = function(dest, options) {  var source = this;  function ondata(chunk) {    if (dest.writable) {      if (false === dest.write(chunk) && source.pause) {        source.pause();      }    }  }  source.on('data', ondata);  function ondrain() {    if (source.readable && source.resume) {      source.resume();    }  }  dest.on('drain', ondrain);  // If the 'end' option is not supplied, dest.end() will be called when  // source gets the 'end' or 'close' events.  Only dest.end() once.  if (!dest._isStdio && (!options || options.end !== false)) {    source.on('end', onend);    source.on('close', onclose);  }  var didOnEnd = false;  function onend() {    if (didOnEnd) return;    didOnEnd = true;    dest.end();  }  function onclose() {    if (didOnEnd) return;    didOnEnd = true;    if (typeof dest.destroy === 'function') dest.destroy();  }  // don't leave dangling pipes when there are errors.  function onerror(er) {    cleanup();    if (EE.listenerCount(this, 'error') === 0) {      throw er; // Unhandled stream error in pipe.    }  }  source.on('error', onerror);  dest.on('error', onerror);  // remove all the event listeners that were added.  function cleanup() {    source.removeListener('data', ondata);    dest.removeListener('drain', ondrain);    source.removeListener('end', onend);    source.removeListener('close', onclose);    source.removeListener('error', onerror);    dest.removeListener('error', onerror);    source.removeListener('end', cleanup);    source.removeListener('close', cleanup);    dest.removeListener('close', cleanup);  }  source.on('end', cleanup);  source.on('close', cleanup);  dest.on('close', cleanup);  dest.emit('pipe', source);  // Allow for unix-like usage: A.pipe(B).pipe(C)  return dest;};},{"./duplex.js":10,"./passthrough.js":13,"./readable.js":14,"./transform.js":15,"./writable.js":16,"events":8,"inherits":19}],12:[function(require,module,exports){// shim for using process in browservar process = module.exports = {};process.nextTick = (function () {    var canSetImmediate = typeof window !== 'undefined'    && window.setImmediate;    var canPost = typeof window !== 'undefined'    && window.postMessage && window.addEventListener    ;    if (canSetImmediate) {        return function (f) { return window.setImmediate(f) };    }    if (canPost) {        var queue = [];        window.addEventListener('message', function (ev) {            var source = ev.source;            if ((source === window || source === null) && ev.data === 'process-tick') {                ev.stopPropagation();                if (queue.length > 0) {                    var fn = queue.shift();                    fn();                }            }        }, true);        return function nextTick(fn) {            queue.push(fn);            window.postMessage('process-tick', '*');        };    }    return function nextTick(fn) {        setTimeout(fn, 0);    };})();process.title = 'browser';process.browser = true;process.env = {};process.argv = [];process.binding = function (name) {    throw new Error('process.binding is not supported');}// TODO(shtylman)process.cwd = function () { return '/' };process.chdir = function (dir) {    throw new Error('process.chdir is not supported');};},{}],13:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.// a passthrough stream.// basically just the most minimal sort of Transform stream.// Every written chunk gets output as-is.module.exports = PassThrough;var Transform = require('./transform.js');var inherits = require('inherits');inherits(PassThrough, Transform);function PassThrough(options) {  if (!(this instanceof PassThrough))    return new PassThrough(options);  Transform.call(this, options);}PassThrough.prototype._transform = function(chunk, encoding, cb) {  cb(null, chunk);};},{"./transform.js":15,"inherits":19}],14:[function(require,module,exports){(function (process){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.module.exports = Readable;Readable.ReadableState = ReadableState;var EE = require('events').EventEmitter;var Stream = require('./index.js');var Buffer = require('buffer').Buffer;var setImmediate = require('process/browser.js').nextTick;var StringDecoder;var inherits = require('inherits');inherits(Readable, Stream);function ReadableState(options, stream) {  options = options || {};  // the point at which it stops calling _read() to fill the buffer  // Note: 0 is a valid value, means "don't call _read preemptively ever"  var hwm = options.highWaterMark;  this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;  // cast to ints.  this.highWaterMark = ~~this.highWaterMark;  this.buffer = [];  this.length = 0;  this.pipes = null;  this.pipesCount = 0;  this.flowing = false;  this.ended = false;  this.endEmitted = false;  this.reading = false;  // In streams that never have any data, and do push(null) right away,  // the consumer can miss the 'end' event if they do some I/O before  // consuming the stream.  So, we don't emit('end') until some reading  // happens.  this.calledRead = false;  // a flag to be able to tell if the onwrite cb is called immediately,  // or on a later tick.  We set this to true at first, becuase any  // actions that shouldn't happen until "later" should generally also  // not happen before the first write call.  this.sync = true;  // whenever we return null, then we set a flag to say  // that we're awaiting a 'readable' event emission.  this.needReadable = false;  this.emittedReadable = false;  this.readableListening = false;  // object stream flag. Used to make read(n) ignore n and to  // make all the buffer merging and length checks go away  this.objectMode = !!options.objectMode;  // Crypto is kind of old and crusty.  Historically, its default string  // encoding is 'binary' so we have to make this configurable.  // Everything else in the universe uses 'utf8', though.  this.defaultEncoding = options.defaultEncoding || 'utf8';  // when piping, we only care about 'readable' events that happen  // after read()ing all the bytes and not getting any pushback.  this.ranOut = false;  // the number of writers that are awaiting a drain event in .pipe()s  this.awaitDrain = 0;  // if true, a maybeReadMore has been scheduled  this.readingMore = false;  this.decoder = null;  this.encoding = null;  if (options.encoding) {    if (!StringDecoder)      StringDecoder = require('string_decoder').StringDecoder;    this.decoder = new StringDecoder(options.encoding);    this.encoding = options.encoding;  }}function Readable(options) {  if (!(this instanceof Readable))    return new Readable(options);  this._readableState = new ReadableState(options, this);  // legacy  this.readable = true;  Stream.call(this);}// Manually shove something into the read() buffer.// This returns true if the highWaterMark has not been hit yet,// similar to how Writable.write() returns true if you should// write() some more.Readable.prototype.push = function(chunk, encoding) {  var state = this._readableState;  if (typeof chunk === 'string' && !state.objectMode) {    encoding = encoding || state.defaultEncoding;    if (encoding !== state.encoding) {      chunk = new Buffer(chunk, encoding);      encoding = '';    }  }  return readableAddChunk(this, state, chunk, encoding, false);};// Unshift should *always* be something directly out of read()Readable.prototype.unshift = function(chunk) {  var state = this._readableState;  return readableAddChunk(this, state, chunk, '', true);};function readableAddChunk(stream, state, chunk, encoding, addToFront) {  var er = chunkInvalid(state, chunk);  if (er) {    stream.emit('error', er);  } else if (chunk === null || chunk === undefined) {    state.reading = false;    if (!state.ended)      onEofChunk(stream, state);  } else if (state.objectMode || chunk && chunk.length > 0) {    if (state.ended && !addToFront) {      var e = new Error('stream.push() after EOF');      stream.emit('error', e);    } else if (state.endEmitted && addToFront) {      var e = new Error('stream.unshift() after end event');      stream.emit('error', e);    } else {      if (state.decoder && !addToFront && !encoding)        chunk = state.decoder.write(chunk);      // update the buffer info.      state.length += state.objectMode ? 1 : chunk.length;      if (addToFront) {        state.buffer.unshift(chunk);      } else {        state.reading = false;        state.buffer.push(chunk);      }      if (state.needReadable)        emitReadable(stream);      maybeReadMore(stream, state);    }  } else if (!addToFront) {    state.reading = false;  }  return needMoreData(state);}// if it's past the high water mark, we can push in some more.// Also, if we have no data yet, we can stand some// more bytes.  This is to work around cases where hwm=0,// such as the repl.  Also, if the push() triggered a// readable event, and the user called read(largeNumber) such that// needReadable was set, then we ought to push more, so that another// 'readable' event will be triggered.function needMoreData(state) {  return !state.ended &&         (state.needReadable ||          state.length < state.highWaterMark ||          state.length === 0);}// backwards compatibility.Readable.prototype.setEncoding = function(enc) {  if (!StringDecoder)    StringDecoder = require('string_decoder').StringDecoder;  this._readableState.decoder = new StringDecoder(enc);  this._readableState.encoding = enc;};// Don't raise the hwm > 128MBvar MAX_HWM = 0x800000;function roundUpToNextPowerOf2(n) {  if (n >= MAX_HWM) {    n = MAX_HWM;  } else {    // Get the next highest power of 2    n--;    for (var p = 1; p < 32; p <<= 1) n |= n >> p;    n++;  }  return n;}function howMuchToRead(n, state) {  if (state.length === 0 && state.ended)    return 0;  if (state.objectMode)    return n === 0 ? 0 : 1;  if (isNaN(n) || n === null) {    // only flow one buffer at a time    if (state.flowing && state.buffer.length)      return state.buffer[0].length;    else      return state.length;  }  if (n <= 0)    return 0;  // If we're asking for more than the target buffer level,  // then raise the water mark.  Bump up to the next highest  // power of 2, to prevent increasing it excessively in tiny  // amounts.  if (n > state.highWaterMark)    state.highWaterMark = roundUpToNextPowerOf2(n);  // don't have that much.  return null, unless we've ended.  if (n > state.length) {    if (!state.ended) {      state.needReadable = true;      return 0;    } else      return state.length;  }  return n;}// you can override either this method, or the async _read(n) below.Readable.prototype.read = function(n) {  var state = this._readableState;  state.calledRead = true;  var nOrig = n;  if (typeof n !== 'number' || n > 0)    state.emittedReadable = false;  // if we're doing read(0) to trigger a readable event, but we  // already have a bunch of data in the buffer, then just trigger  // the 'readable' event and move on.  if (n === 0 &&      state.needReadable &&      (state.length >= state.highWaterMark || state.ended)) {    emitReadable(this);    return null;  }  n = howMuchToRead(n, state);  // if we've ended, and we're now clear, then finish it up.  if (n === 0 && state.ended) {    if (state.length === 0)      endReadable(this);    return null;  }  // All the actual chunk generation logic needs to be  // *below* the call to _read.  The reason is that in certain  // synthetic stream cases, such as passthrough streams, _read  // may be a completely synchronous operation which may change  // the state of the read buffer, providing enough data when  // before there was *not* enough.  //  // So, the steps are:  // 1. Figure out what the state of things will be after we do  // a read from the buffer.  //  // 2. If that resulting state will trigger a _read, then call _read.  // Note that this may be asynchronous, or synchronous.  Yes, it is  // deeply ugly to write APIs this way, but that still doesn't mean  // that the Readable class should behave improperly, as streams are  // designed to be sync/async agnostic.  // Take note if the _read call is sync or async (ie, if the read call  // has returned yet), so that we know whether or not it's safe to emit  // 'readable' etc.  //  // 3. Actually pull the requested chunks out of the buffer and return.  // if we need a readable event, then we need to do some reading.  var doRead = state.needReadable;  // if we currently have less than the highWaterMark, then also read some  if (state.length - n <= state.highWaterMark)    doRead = true;  // however, if we've ended, then there's no point, and if we're already  // reading, then it's unnecessary.  if (state.ended || state.reading)    doRead = false;  if (doRead) {    state.reading = true;    state.sync = true;    // if the length is currently zero, then we *need* a readable event.    if (state.length === 0)      state.needReadable = true;    // call internal read method    this._read(state.highWaterMark);    state.sync = false;  }  // If _read called its callback synchronously, then `reading`  // will be false, and we need to re-evaluate how much data we  // can return to the user.  if (doRead && !state.reading)    n = howMuchToRead(nOrig, state);  var ret;  if (n > 0)    ret = fromList(n, state);  else    ret = null;  if (ret === null) {    state.needReadable = true;    n = 0;  }  state.length -= n;  // If we have nothing in the buffer, then we want to know  // as soon as we *do* get something into the buffer.  if (state.length === 0 && !state.ended)    state.needReadable = true;  // If we happened to read() exactly the remaining amount in the  // buffer, and the EOF has been seen at this point, then make sure  // that we emit 'end' on the very next tick.  if (state.ended && !state.endEmitted && state.length === 0)    endReadable(this);  return ret;};function chunkInvalid(state, chunk) {  var er = null;  if (!Buffer.isBuffer(chunk) &&      'string' !== typeof chunk &&      chunk !== null &&      chunk !== undefined &&      !state.objectMode &&      !er) {    er = new TypeError('Invalid non-string/buffer chunk');  }  return er;}function onEofChunk(stream, state) {  if (state.decoder && !state.ended) {    var chunk = state.decoder.end();    if (chunk && chunk.length) {      state.buffer.push(chunk);      state.length += state.objectMode ? 1 : chunk.length;    }  }  state.ended = true;  // if we've ended and we have some data left, then emit  // 'readable' now to make sure it gets picked up.  if (state.length > 0)    emitReadable(stream);  else    endReadable(stream);}// Don't emit readable right away in sync mode, because this can trigger// another read() call => stack overflow.  This way, it might trigger// a nextTick recursion warning, but that's not so bad.function emitReadable(stream) {  var state = stream._readableState;  state.needReadable = false;  if (state.emittedReadable)    return;  state.emittedReadable = true;  if (state.sync)    setImmediate(function() {      emitReadable_(stream);    });  else    emitReadable_(stream);}function emitReadable_(stream) {  stream.emit('readable');}// at this point, the user has presumably seen the 'readable' event,// and called read() to consume some data.  that may have triggered// in turn another _read(n) call, in which case reading = true if// it's in progress.// However, if we're not ended, or reading, and the length < hwm,// then go ahead and try to read some more preemptively.function maybeReadMore(stream, state) {  if (!state.readingMore) {    state.readingMore = true;    setImmediate(function() {      maybeReadMore_(stream, state);    });  }}function maybeReadMore_(stream, state) {  var len = state.length;  while (!state.reading && !state.flowing && !state.ended &&         state.length < state.highWaterMark) {    stream.read(0);    if (len === state.length)      // didn't get any data, stop spinning.      break;    else      len = state.length;  }  state.readingMore = false;}// abstract method.  to be overridden in specific implementation classes.// call cb(er, data) where data is <= n in length.// for virtual (non-string, non-buffer) streams, "length" is somewhat// arbitrary, and perhaps not very meaningful.Readable.prototype._read = function(n) {  this.emit('error', new Error('not implemented'));};Readable.prototype.pipe = function(dest, pipeOpts) {  var src = this;  var state = this._readableState;  switch (state.pipesCount) {    case 0:      state.pipes = dest;      break;    case 1:      state.pipes = [state.pipes, dest];      break;    default:      state.pipes.push(dest);      break;  }  state.pipesCount += 1;  var doEnd = (!pipeOpts || pipeOpts.end !== false) &&              dest !== process.stdout &&              dest !== process.stderr;  var endFn = doEnd ? onend : cleanup;  if (state.endEmitted)    setImmediate(endFn);  else    src.once('end', endFn);  dest.on('unpipe', onunpipe);  function onunpipe(readable) {    if (readable !== src) return;    cleanup();  }  function onend() {    dest.end();  }  // when the dest drains, it reduces the awaitDrain counter  // on the source.  This would be more elegant with a .once()  // handler in flow(), but adding and removing repeatedly is  // too slow.  var ondrain = pipeOnDrain(src);  dest.on('drain', ondrain);  function cleanup() {    // cleanup event handlers once the pipe is broken    dest.removeListener('close', onclose);    dest.removeListener('finish', onfinish);    dest.removeListener('drain', ondrain);    dest.removeListener('error', onerror);    dest.removeListener('unpipe', onunpipe);    src.removeListener('end', onend);    src.removeListener('end', cleanup);    // if the reader is waiting for a drain event from this    // specific writer, then it would cause it to never start    // flowing again.    // So, if this is awaiting a drain, then we just call it now.    // If we don't know, then assume that we are waiting for one.    if (!dest._writableState || dest._writableState.needDrain)      ondrain();  }  // if the dest has an error, then stop piping into it.  // however, don't suppress the throwing behavior for this.  // check for listeners before emit removes one-time listeners.  var errListeners = EE.listenerCount(dest, 'error');  function onerror(er) {    unpipe();    if (errListeners === 0 && EE.listenerCount(dest, 'error') === 0)      dest.emit('error', er);  }  dest.once('error', onerror);  // Both close and finish should trigger unpipe, but only once.  function onclose() {    dest.removeListener('finish', onfinish);    unpipe();  }  dest.once('close', onclose);  function onfinish() {    dest.removeListener('close', onclose);    unpipe();  }  dest.once('finish', onfinish);  function unpipe() {    src.unpipe(dest);  }  // tell the dest that it's being piped to  dest.emit('pipe', src);  // start the flow if it hasn't been started already.  if (!state.flowing) {    // the handler that waits for readable events after all    // the data gets sucked out in flow.    // This would be easier to follow with a .once() handler    // in flow(), but that is too slow.    this.on('readable', pipeOnReadable);    state.flowing = true;    setImmediate(function() {      flow(src);    });  }  return dest;};function pipeOnDrain(src) {  return function() {    var dest = this;    var state = src._readableState;    state.awaitDrain--;    if (state.awaitDrain === 0)      flow(src);  };}function flow(src) {  var state = src._readableState;  var chunk;  state.awaitDrain = 0;  function write(dest, i, list) {    var written = dest.write(chunk);    if (false === written) {      state.awaitDrain++;    }  }  while (state.pipesCount && null !== (chunk = src.read())) {    if (state.pipesCount === 1)      write(state.pipes, 0, null);    else      forEach(state.pipes, write);    src.emit('data', chunk);    // if anyone needs a drain, then we have to wait for that.    if (state.awaitDrain > 0)      return;  }  // if every destination was unpiped, either before entering this  // function, or in the while loop, then stop flowing.  //  // NB: This is a pretty rare edge case.  if (state.pipesCount === 0) {    state.flowing = false;    // if there were data event listeners added, then switch to old mode.    if (EE.listenerCount(src, 'data') > 0)      emitDataEvents(src);    return;  }  // at this point, no one needed a drain, so we just ran out of data  // on the next readable event, start it over again.  state.ranOut = true;}function pipeOnReadable() {  if (this._readableState.ranOut) {    this._readableState.ranOut = false;    flow(this);  }}Readable.prototype.unpipe = function(dest) {  var state = this._readableState;  // if we're not piping anywhere, then do nothing.  if (state.pipesCount === 0)    return this;  // just one destination.  most common case.  if (state.pipesCount === 1) {    // passed in one, but it's not the right one.    if (dest && dest !== state.pipes)      return this;    if (!dest)      dest = state.pipes;    // got a match.    state.pipes = null;    state.pipesCount = 0;    this.removeListener('readable', pipeOnReadable);    state.flowing = false;    if (dest)      dest.emit('unpipe', this);    return this;  }  // slow case. multiple pipe destinations.  if (!dest) {    // remove all.    var dests = state.pipes;    var len = state.pipesCount;    state.pipes = null;    state.pipesCount = 0;    this.removeListener('readable', pipeOnReadable);    state.flowing = false;    for (var i = 0; i < len; i++)      dests[i].emit('unpipe', this);    return this;  }  // try to find the right one.  var i = indexOf(state.pipes, dest);  if (i === -1)    return this;  state.pipes.splice(i, 1);  state.pipesCount -= 1;  if (state.pipesCount === 1)    state.pipes = state.pipes[0];  dest.emit('unpipe', this);  return this;};// set up data events if they are asked for// Ensure readable listeners eventually get somethingReadable.prototype.on = function(ev, fn) {  var res = Stream.prototype.on.call(this, ev, fn);  if (ev === 'data' && !this._readableState.flowing)    emitDataEvents(this);  if (ev === 'readable' && this.readable) {    var state = this._readableState;    if (!state.readableListening) {      state.readableListening = true;      state.emittedReadable = false;      state.needReadable = true;      if (!state.reading) {        this.read(0);      } else if (state.length) {        emitReadable(this, state);      }    }  }  return res;};Readable.prototype.addListener = Readable.prototype.on;// pause() and resume() are remnants of the legacy readable stream API// If the user uses them, then switch into old mode.Readable.prototype.resume = function() {  emitDataEvents(this);  this.read(0);  this.emit('resume');};Readable.prototype.pause = function() {  emitDataEvents(this, true);  this.emit('pause');};function emitDataEvents(stream, startPaused) {  var state = stream._readableState;  if (state.flowing) {    // https://github.com/isaacs/readable-stream/issues/16    throw new Error('Cannot switch to old mode now.');  }  var paused = startPaused || false;  var readable = false;  // convert to an old-style stream.  stream.readable = true;  stream.pipe = Stream.prototype.pipe;  stream.on = stream.addListener = Stream.prototype.on;  stream.on('readable', function() {    readable = true;    var c;    while (!paused && (null !== (c = stream.read())))      stream.emit('data', c);    if (c === null) {      readable = false;      stream._readableState.needReadable = true;    }  });  stream.pause = function() {    paused = true;    this.emit('pause');  };  stream.resume = function() {    paused = false;    if (readable)      setImmediate(function() {        stream.emit('readable');      });    else      this.read(0);    this.emit('resume');  };  // now make it start, just in case it hadn't already.  stream.emit('readable');}// wrap an old-style stream as the async data source.// This is *not* part of the readable stream interface.// It is an ugly unfortunate mess of history.Readable.prototype.wrap = function(stream) {  var state = this._readableState;  var paused = false;  var self = this;  stream.on('end', function() {    if (state.decoder && !state.ended) {      var chunk = state.decoder.end();      if (chunk && chunk.length)        self.push(chunk);    }    self.push(null);  });  stream.on('data', function(chunk) {    if (state.decoder)      chunk = state.decoder.write(chunk);    if (!chunk || !state.objectMode && !chunk.length)      return;    var ret = self.push(chunk);    if (!ret) {      paused = true;      stream.pause();    }  });  // proxy all the other methods.  // important when wrapping filters and duplexes.  for (var i in stream) {    if (typeof stream[i] === 'function' &&        typeof this[i] === 'undefined') {      this[i] = function(method) { return function() {        return stream[method].apply(stream, arguments);      }}(i);    }  }  // proxy certain important events.  var events = ['error', 'close', 'destroy', 'pause', 'resume'];  forEach(events, function(ev) {    stream.on(ev, function (x) {      return self.emit.apply(self, ev, x);    });  });  // when we try to consume some more bytes, simply unpause the  // underlying stream.  self._read = function(n) {    if (paused) {      paused = false;      stream.resume();    }  };  return self;};// exposed for testing purposes only.Readable._fromList = fromList;// Pluck off n bytes from an array of buffers.// Length is the combined lengths of all the buffers in the list.function fromList(n, state) {  var list = state.buffer;  var length = state.length;  var stringMode = !!state.decoder;  var objectMode = !!state.objectMode;  var ret;  // nothing in the list, definitely empty.  if (list.length === 0)    return null;  if (length === 0)    ret = null;  else if (objectMode)    ret = list.shift();  else if (!n || n >= length) {    // read it all, truncate the array.    if (stringMode)      ret = list.join('');    else      ret = Buffer.concat(list, length);    list.length = 0;  } else {    // read just some of it.    if (n < list[0].length) {      // just take a part of the first list item.      // slice is the same for buffers and strings.      var buf = list[0];      ret = buf.slice(0, n);      list[0] = buf.slice(n);    } else if (n === list[0].length) {      // first list is a perfect match      ret = list.shift();    } else {      // complex case.      // we have enough to cover it, but it spans past the first buffer.      if (stringMode)        ret = '';      else        ret = new Buffer(n);      var c = 0;      for (var i = 0, l = list.length; i < l && c < n; i++) {        var buf = list[0];        var cpy = Math.min(n - c, buf.length);        if (stringMode)          ret += buf.slice(0, cpy);        else          buf.copy(ret, c, 0, cpy);        if (cpy < buf.length)          list[0] = buf.slice(cpy);        else          list.shift();        c += cpy;      }    }  }  return ret;}function endReadable(stream) {  var state = stream._readableState;  // If we get here before consuming all the bytes, then that is a  // bug in node.  Should never happen.  if (state.length > 0)    throw new Error('endReadable called on non-empty stream');  if (!state.endEmitted && state.calledRead) {    state.ended = true;    setImmediate(function() {      // Check that we didn't get one last unshift.      if (!state.endEmitted && state.length === 0) {        state.endEmitted = true;        stream.readable = false;        stream.emit('end');      }    });  }}function forEach (xs, f) {  for (var i = 0, l = xs.length; i < l; i++) {    f(xs[i], i);  }}function indexOf (xs, x) {  for (var i = 0, l = xs.length; i < l; i++) {    if (xs[i] === x) return i;  }  return -1;}}).call(this,require("7YKIPe"))},{"./index.js":11,"7YKIPe":9,"buffer":7,"events":8,"inherits":19,"process/browser.js":12,"string_decoder":17}],15:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.// a transform stream is a readable/writable stream where you do// something with the data.  Sometimes it's called a "filter",// but that's not a great name for it, since that implies a thing where// some bits pass through, and others are simply ignored.  (That would// be a valid example of a transform, of course.)//// While the output is causally related to the input, it's not a// necessarily symmetric or synchronous transformation.  For example,// a zlib stream might take multiple plain-text writes(), and then// emit a single compressed chunk some time in the future.//// Here's how this works://// The Transform stream has all the aspects of the readable and writable// stream classes.  When you write(chunk), that calls _write(chunk,cb)// internally, and returns false if there's a lot of pending writes// buffered up.  When you call read(), that calls _read(n) until// there's enough pending readable data buffered up.//// In a transform stream, the written data is placed in a buffer.  When// _read(n) is called, it transforms the queued up data, calling the// buffered _write cb's as it consumes chunks.  If consuming a single// written chunk would result in multiple output chunks, then the first// outputted bit calls the readcb, and subsequent chunks just go into// the read buffer, and will cause it to emit 'readable' if necessary.//// This way, back-pressure is actually determined by the reading side,// since _read has to be called to start processing a new chunk.  However,// a pathological inflate type of transform can cause excessive buffering// here.  For example, imagine a stream where every byte of input is// interpreted as an integer from 0-255, and then results in that many// bytes of output.  Writing the 4 bytes {ff,ff,ff,ff} would result in// 1kb of data being output.  In this case, you could write a very small// amount of input, and end up with a very large amount of output.  In// such a pathological inflating mechanism, there'd be no way to tell// the system to stop doing the transform.  A single 4MB write could// cause the system to run out of memory.//// However, even in such a pathological case, only a single written chunk// would be consumed, and then the rest would wait (un-transformed) until// the results of the previous transformed chunk were consumed.module.exports = Transform;var Duplex = require('./duplex.js');var inherits = require('inherits');inherits(Transform, Duplex);function TransformState(options, stream) {  this.afterTransform = function(er, data) {    return afterTransform(stream, er, data);  };  this.needTransform = false;  this.transforming = false;  this.writecb = null;  this.writechunk = null;}function afterTransform(stream, er, data) {  var ts = stream._transformState;  ts.transforming = false;  var cb = ts.writecb;  if (!cb)    return stream.emit('error', new Error('no writecb in Transform class'));  ts.writechunk = null;  ts.writecb = null;  if (data !== null && data !== undefined)    stream.push(data);  if (cb)    cb(er);  var rs = stream._readableState;  rs.reading = false;  if (rs.needReadable || rs.length < rs.highWaterMark) {    stream._read(rs.highWaterMark);  }}function Transform(options) {  if (!(this instanceof Transform))    return new Transform(options);  Duplex.call(this, options);  var ts = this._transformState = new TransformState(options, this);  // when the writable side finishes, then flush out anything remaining.  var stream = this;  // start out asking for a readable event once data is transformed.  this._readableState.needReadable = true;  // we have implemented the _read method, and done the other things  // that Readable wants before the first _read call, so unset the  // sync guard flag.  this._readableState.sync = false;  this.once('finish', function() {    if ('function' === typeof this._flush)      this._flush(function(er) {        done(stream, er);      });    else      done(stream);  });}Transform.prototype.push = function(chunk, encoding) {  this._transformState.needTransform = false;  return Duplex.prototype.push.call(this, chunk, encoding);};// This is the part where you do stuff!// override this function in implementation classes.// 'chunk' is an input chunk.//// Call `push(newChunk)` to pass along transformed output// to the readable side.  You may call 'push' zero or more times.//// Call `cb(err)` when you are done with this chunk.  If you pass// an error, then that'll put the hurt on the whole operation.  If you// never call cb(), then you'll never get another chunk.Transform.prototype._transform = function(chunk, encoding, cb) {  throw new Error('not implemented');};Transform.prototype._write = function(chunk, encoding, cb) {  var ts = this._transformState;  ts.writecb = cb;  ts.writechunk = chunk;  ts.writeencoding = encoding;  if (!ts.transforming) {    var rs = this._readableState;    if (ts.needTransform ||        rs.needReadable ||        rs.length < rs.highWaterMark)      this._read(rs.highWaterMark);  }};// Doesn't matter what the args are here.// _transform does all the work.// That we got here means that the readable side wants more data.Transform.prototype._read = function(n) {  var ts = this._transformState;  if (ts.writechunk && ts.writecb && !ts.transforming) {    ts.transforming = true;    this._transform(ts.writechunk, ts.writeencoding, ts.afterTransform);  } else {    // mark that we need a transform, so that any data that comes in    // will get processed, now that we've asked for it.    ts.needTransform = true;  }};function done(stream, er) {  if (er)    return stream.emit('error', er);  // if there's nothing in the write buffer, then that means  // that nothing more will ever be provided  var ws = stream._writableState;  var rs = stream._readableState;  var ts = stream._transformState;  if (ws.length)    throw new Error('calling transform done when ws.length != 0');  if (ts.transforming)    throw new Error('calling transform done when still transforming');  return stream.push(null);}},{"./duplex.js":10,"inherits":19}],16:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.// A bit simpler than readable streams.// Implement an async ._write(chunk, cb), and it'll handle all// the drain event emission and buffering.module.exports = Writable;Writable.WritableState = WritableState;var isUint8Array = typeof Uint8Array !== 'undefined'  ? function (x) { return x instanceof Uint8Array }  : function (x) {    return x && x.constructor && x.constructor.name === 'Uint8Array'  };var isArrayBuffer = typeof ArrayBuffer !== 'undefined'  ? function (x) { return x instanceof ArrayBuffer }  : function (x) {    return x && x.constructor && x.constructor.name === 'ArrayBuffer'  };var inherits = require('inherits');var Stream = require('./index.js');var setImmediate = require('process/browser.js').nextTick;var Buffer = require('buffer').Buffer;inherits(Writable, Stream);function WriteReq(chunk, encoding, cb) {  this.chunk = chunk;  this.encoding = encoding;  this.callback = cb;}function WritableState(options, stream) {  options = options || {};  // the point at which write() starts returning false  // Note: 0 is a valid value, means that we always return false if  // the entire buffer is not flushed immediately on write()  var hwm = options.highWaterMark;  this.highWaterMark = (hwm || hwm === 0) ? hwm : 16 * 1024;  // object stream flag to indicate whether or not this stream  // contains buffers or objects.  this.objectMode = !!options.objectMode;  // cast to ints.  this.highWaterMark = ~~this.highWaterMark;  this.needDrain = false;  // at the start of calling end()  this.ending = false;  // when end() has been called, and returned  this.ended = false;  // when 'finish' is emitted  this.finished = false;  // should we decode strings into buffers before passing to _write?  // this is here so that some node-core streams can optimize string  // handling at a lower level.  var noDecode = options.decodeStrings === false;  this.decodeStrings = !noDecode;  // Crypto is kind of old and crusty.  Historically, its default string  // encoding is 'binary' so we have to make this configurable.  // Everything else in the universe uses 'utf8', though.  this.defaultEncoding = options.defaultEncoding || 'utf8';  // not an actual buffer we keep track of, but a measurement  // of how much we're waiting to get pushed to some underlying  // socket or file.  this.length = 0;  // a flag to see when we're in the middle of a write.  this.writing = false;  // a flag to be able to tell if the onwrite cb is called immediately,  // or on a later tick.  We set this to true at first, becuase any  // actions that shouldn't happen until "later" should generally also  // not happen before the first write call.  this.sync = true;  // a flag to know if we're processing previously buffered items, which  // may call the _write() callback in the same tick, so that we don't  // end up in an overlapped onwrite situation.  this.bufferProcessing = false;  // the callback that's passed to _write(chunk,cb)  this.onwrite = function(er) {    onwrite(stream, er);  };  // the callback that the user supplies to write(chunk,encoding,cb)  this.writecb = null;  // the amount that is being written when _write is called.  this.writelen = 0;  this.buffer = [];}function Writable(options) {  // Writable ctor is applied to Duplexes, though they're not  // instanceof Writable, they're instanceof Readable.  if (!(this instanceof Writable) && !(this instanceof Stream.Duplex))    return new Writable(options);  this._writableState = new WritableState(options, this);  // legacy.  this.writable = true;  Stream.call(this);}// Otherwise people can pipe Writable streams, which is just wrong.Writable.prototype.pipe = function() {  this.emit('error', new Error('Cannot pipe. Not readable.'));};function writeAfterEnd(stream, state, cb) {  var er = new Error('write after end');  // TODO: defer error events consistently everywhere, not just the cb  stream.emit('error', er);  setImmediate(function() {    cb(er);  });}// If we get something that is not a buffer, string, null, or undefined,// and we're not in objectMode, then that's an error.// Otherwise stream chunks are all considered to be of length=1, and the// watermarks determine how many objects to keep in the buffer, rather than// how many bytes or characters.function validChunk(stream, state, chunk, cb) {  var valid = true;  if (!Buffer.isBuffer(chunk) &&      'string' !== typeof chunk &&      chunk !== null &&      chunk !== undefined &&      !state.objectMode) {    var er = new TypeError('Invalid non-string/buffer chunk');    stream.emit('error', er);    setImmediate(function() {      cb(er);    });    valid = false;  }  return valid;}Writable.prototype.write = function(chunk, encoding, cb) {  var state = this._writableState;  var ret = false;  if (typeof encoding === 'function') {    cb = encoding;    encoding = null;  }  if (!Buffer.isBuffer(chunk) && isUint8Array(chunk))    chunk = new Buffer(chunk);  if (isArrayBuffer(chunk) && typeof Uint8Array !== 'undefined')    chunk = new Buffer(new Uint8Array(chunk));    if (Buffer.isBuffer(chunk))    encoding = 'buffer';  else if (!encoding)    encoding = state.defaultEncoding;  if (typeof cb !== 'function')    cb = function() {};  if (state.ended)    writeAfterEnd(this, state, cb);  else if (validChunk(this, state, chunk, cb))    ret = writeOrBuffer(this, state, chunk, encoding, cb);  return ret;};function decodeChunk(state, chunk, encoding) {  if (!state.objectMode &&      state.decodeStrings !== false &&      typeof chunk === 'string') {    chunk = new Buffer(chunk, encoding);  }  return chunk;}// if we're already writing something, then just put this// in the queue, and wait our turn.  Otherwise, call _write// If we return false, then we need a drain event, so set that flag.function writeOrBuffer(stream, state, chunk, encoding, cb) {  chunk = decodeChunk(state, chunk, encoding);  var len = state.objectMode ? 1 : chunk.length;  state.length += len;  var ret = state.length < state.highWaterMark;  state.needDrain = !ret;  if (state.writing)    state.buffer.push(new WriteReq(chunk, encoding, cb));  else    doWrite(stream, state, len, chunk, encoding, cb);  return ret;}function doWrite(stream, state, len, chunk, encoding, cb) {  state.writelen = len;  state.writecb = cb;  state.writing = true;  state.sync = true;  stream._write(chunk, encoding, state.onwrite);  state.sync = false;}function onwriteError(stream, state, sync, er, cb) {  if (sync)    setImmediate(function() {      cb(er);    });  else    cb(er);  stream.emit('error', er);}function onwriteStateUpdate(state) {  state.writing = false;  state.writecb = null;  state.length -= state.writelen;  state.writelen = 0;}function onwrite(stream, er) {  var state = stream._writableState;  var sync = state.sync;  var cb = state.writecb;  onwriteStateUpdate(state);  if (er)    onwriteError(stream, state, sync, er, cb);  else {    // Check if we're actually ready to finish, but don't emit yet    var finished = needFinish(stream, state);    if (!finished && !state.bufferProcessing && state.buffer.length)      clearBuffer(stream, state);    if (sync) {      setImmediate(function() {        afterWrite(stream, state, finished, cb);      });    } else {      afterWrite(stream, state, finished, cb);    }  }}function afterWrite(stream, state, finished, cb) {  if (!finished)    onwriteDrain(stream, state);  cb();  if (finished)    finishMaybe(stream, state);}// Must force callback to be called on nextTick, so that we don't// emit 'drain' before the write() consumer gets the 'false' return// value, and has a chance to attach a 'drain' listener.function onwriteDrain(stream, state) {  if (state.length === 0 && state.needDrain) {    state.needDrain = false;    stream.emit('drain');  }}// if there's something in the buffer waiting, then process itfunction clearBuffer(stream, state) {  state.bufferProcessing = true;  for (var c = 0; c < state.buffer.length; c++) {    var entry = state.buffer[c];    var chunk = entry.chunk;    var encoding = entry.encoding;    var cb = entry.callback;    var len = state.objectMode ? 1 : chunk.length;    doWrite(stream, state, len, chunk, encoding, cb);    // if we didn't call the onwrite immediately, then    // it means that we need to wait until it does.    // also, that means that the chunk and cb are currently    // being processed, so move the buffer counter past them.    if (state.writing) {      c++;      break;    }  }  state.bufferProcessing = false;  if (c < state.buffer.length)    state.buffer = state.buffer.slice(c);  else    state.buffer.length = 0;}Writable.prototype._write = function(chunk, encoding, cb) {  cb(new Error('not implemented'));};Writable.prototype.end = function(chunk, encoding, cb) {  var state = this._writableState;  if (typeof chunk === 'function') {    cb = chunk;    chunk = null;    encoding = null;  } else if (typeof encoding === 'function') {    cb = encoding;    encoding = null;  }  if (typeof chunk !== 'undefined' && chunk !== null)    this.write(chunk, encoding);  // ignore unnecessary end() calls.  if (!state.ending && !state.finished)    endWritable(this, state, cb);};function needFinish(stream, state) {  return (state.ending &&          state.length === 0 &&          !state.finished &&          !state.writing);}function finishMaybe(stream, state) {  var need = needFinish(stream, state);  if (need) {    state.finished = true;    stream.emit('finish');  }  return need;}function endWritable(stream, state, cb) {  state.ending = true;  finishMaybe(stream, state);  if (cb) {    if (state.finished)      setImmediate(cb);    else      stream.once('finish', cb);  }  state.ended = true;}},{"./index.js":11,"buffer":7,"inherits":19,"process/browser.js":12}],17:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.//// Permission is hereby granted, free of charge, to any person obtaining a// copy of this software and associated documentation files (the// "Software"), to deal in the Software without restriction, including// without limitation the rights to use, copy, modify, merge, publish,// distribute, sublicense, and/or sell copies of the Software, and to permit// persons to whom the Software is furnished to do so, subject to the// following conditions://// The above copyright notice and this permission notice shall be included// in all copies or substantial portions of the Software.//// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE// USE OR OTHER DEALINGS IN THE SOFTWARE.var Buffer = require('buffer').Buffer;function assertEncoding(encoding) {  if (encoding && !Buffer.isEncoding(encoding)) {    throw new Error('Unknown encoding: ' + encoding);  }}var StringDecoder = exports.StringDecoder = function(encoding) {  this.encoding = (encoding || 'utf8').toLowerCase().replace(/[-_]/, '');  assertEncoding(encoding);  switch (this.encoding) {    case 'utf8':      // CESU-8 represents each of Surrogate Pair by 3-bytes      this.surrogateSize = 3;      break;    case 'ucs2':    case 'utf16le':      // UTF-16 represents each of Surrogate Pair by 2-bytes      this.surrogateSize = 2;      this.detectIncompleteChar = utf16DetectIncompleteChar;      break;    case 'base64':      // Base-64 stores 3 bytes in 4 chars, and pads the remainder.      this.surrogateSize = 3;      this.detectIncompleteChar = base64DetectIncompleteChar;      break;    default:      this.write = passThroughWrite;      return;  }  this.charBuffer = new Buffer(6);  this.charReceived = 0;  this.charLength = 0;};StringDecoder.prototype.write = function(buffer) {  var charStr = '';  var offset = 0;  // if our last write ended with an incomplete multibyte character  while (this.charLength) {    // determine how many remaining bytes this buffer has to offer for this char    var i = (buffer.length >= this.charLength - this.charReceived) ?                this.charLength - this.charReceived :                buffer.length;    // add the new bytes to the char buffer    buffer.copy(this.charBuffer, this.charReceived, offset, i);    this.charReceived += (i - offset);    offset = i;    if (this.charReceived < this.charLength) {      // still not enough chars in this buffer? wait for more ...      return '';    }    // get the character that was split    charStr = this.charBuffer.slice(0, this.charLength).toString(this.encoding);    // lead surrogate (D800-DBFF) is also the incomplete character    var charCode = charStr.charCodeAt(charStr.length - 1);    if (charCode >= 0xD800 && charCode <= 0xDBFF) {      this.charLength += this.surrogateSize;      charStr = '';      continue;    }    this.charReceived = this.charLength = 0;    // if there are no more bytes in this buffer, just emit our char    if (i == buffer.length) return charStr;    // otherwise cut off the characters end from the beginning of this buffer    buffer = buffer.slice(i, buffer.length);    break;  }  var lenIncomplete = this.detectIncompleteChar(buffer);  var end = buffer.length;  if (this.charLength) {    // buffer the incomplete character bytes we got    buffer.copy(this.charBuffer, 0, buffer.length - lenIncomplete, end);    this.charReceived = lenIncomplete;    end -= lenIncomplete;  }  charStr += buffer.toString(this.encoding, 0, end);  var end = charStr.length - 1;  var charCode = charStr.charCodeAt(end);  // lead surrogate (D800-DBFF) is also the incomplete character  if (charCode >= 0xD800 && charCode <= 0xDBFF) {    var size = this.surrogateSize;    this.charLength += size;    this.charReceived += size;    this.charBuffer.copy(this.charBuffer, size, 0, size);    this.charBuffer.write(charStr.charAt(charStr.length - 1), this.encoding);    return charStr.substring(0, end);  }  // or just emit the charStr  return charStr;};StringDecoder.prototype.detectIncompleteChar = function(buffer) {  // determine how many bytes we have to check at the end of this buffer  var i = (buffer.length >= 3) ? 3 : buffer.length;  // Figure out if one of the last i bytes of our buffer announces an  // incomplete char.  for (; i > 0; i--) {    var c = buffer[buffer.length - i];    // See http://en.wikipedia.org/wiki/UTF-8#Description    // 110XXXXX    if (i == 1 && c >> 5 == 0x06) {      this.charLength = 2;      break;    }    // 1110XXXX    if (i <= 2 && c >> 4 == 0x0E) {      this.charLength = 3;      break;    }    // 11110XXX    if (i <= 3 && c >> 3 == 0x1E) {      this.charLength = 4;      break;    }  }  return i;};StringDecoder.prototype.end = function(buffer) {  var res = '';  if (buffer && buffer.length)    res = this.write(buffer);  if (this.charReceived) {    var cr = this.charReceived;    var buf = this.charBuffer;    var enc = this.encoding;    res += buf.slice(0, cr).toString(enc);  }  return res;};function passThroughWrite(buffer) {  return buffer.toString(this.encoding);}function utf16DetectIncompleteChar(buffer) {  var incomplete = this.charReceived = buffer.length % 2;  this.charLength = incomplete ? 2 : 0;  return incomplete;}function base64DetectIncompleteChar(buffer) {  var incomplete = this.charReceived = buffer.length % 3;  this.charLength = incomplete ? 3 : 0;  return incomplete;}},{"buffer":7}],18:[function(require,module,exports){exports.read = function (buffer, offset, isLE, mLen, nBytes) {  var e, m  var eLen = (nBytes * 8) - mLen - 1  var eMax = (1 << eLen) - 1  var eBias = eMax >> 1  var nBits = -7  var i = isLE ? (nBytes - 1) : 0  var d = isLE ? -1 : 1  var s = buffer[offset + i]  i += d  e = s & ((1 << (-nBits)) - 1)  s >>= (-nBits)  nBits += eLen  for (; nBits > 0; e = (e * 256) + buffer[offset + i], i += d, nBits -= 8) {}  m = e & ((1 << (-nBits)) - 1)  e >>= (-nBits)  nBits += mLen  for (; nBits > 0; m = (m * 256) + buffer[offset + i], i += d, nBits -= 8) {}  if (e === 0) {    e = 1 - eBias  } else if (e === eMax) {    return m ? NaN : ((s ? -1 : 1) * Infinity)  } else {    m = m + Math.pow(2, mLen)    e = e - eBias  }  return (s ? -1 : 1) * m * Math.pow(2, e - mLen)}exports.write = function (buffer, value, offset, isLE, mLen, nBytes) {  var e, m, c  var eLen = (nBytes * 8) - mLen - 1  var eMax = (1 << eLen) - 1  var eBias = eMax >> 1  var rt = (mLen === 23 ? Math.pow(2, -24) - Math.pow(2, -77) : 0)  var i = isLE ? 0 : (nBytes - 1)  var d = isLE ? 1 : -1  var s = value < 0 || (value === 0 && 1 / value < 0) ? 1 : 0  value = Math.abs(value)  if (isNaN(value) || value === Infinity) {    m = isNaN(value) ? 1 : 0    e = eMax  } else {    e = Math.floor(Math.log(value) / Math.LN2)    if (value * (c = Math.pow(2, -e)) < 1) {      e--      c *= 2    }    if (e + eBias >= 1) {      value += rt / c    } else {      value += rt * Math.pow(2, 1 - eBias)    }    if (value * c >= 2) {      e++      c /= 2    }    if (e + eBias >= eMax) {      m = 0      e = eMax    } else if (e + eBias >= 1) {      m = ((value * c) - 1) * Math.pow(2, mLen)      e = e + eBias    } else {      m = value * Math.pow(2, eBias - 1) * Math.pow(2, mLen)      e = 0    }  }  for (; mLen >= 8; buffer[offset + i] = m & 0xff, i += d, m /= 256, mLen -= 8) {}  e = (e << mLen) | m  eLen += mLen  for (; eLen > 0; buffer[offset + i] = e & 0xff, i += d, e /= 256, eLen -= 8) {}  buffer[offset + i - d] |= s * 128}},{}],19:[function(require,module,exports){module.exports=require(3)},{}],20:[function(require,module,exports){'use strict';var assert = require('assert');var stream = require('stream');var hash = require('../index');describe('writeToStream', function() {  it('should emit information about an object to a stream', function() {    var strm = new stream.PassThrough();        hash.writeToStream({foo: 'bar'}, strm);    var result = strm.read().toString();    assert.strictEqual(typeof result, 'string');    assert.notStrictEqual(result.indexOf('foo'), -1);    assert.notStrictEqual(result.indexOf('bar'), -1);  });  it('should leave out keys when excludeValues = true', function() {    var strm = new stream.PassThrough();        hash.writeToStream({foo: 'bar'}, {excludeValues: true}, strm);    var result = strm.read().toString();    assert.strictEqual(typeof result, 'string');    assert.notStrictEqual(result.indexOf('foo'), -1);    assert.   strictEqual(result.indexOf('bar'), -1);  });});},{"../index":1,"assert":2,"stream":11}]},{},[20])
 |