UNPKG

hawkclient-cli

Version:

hawkclient-cli, a cli to test apis collection

1 lines 11.5 kB
const a0_0x13b896=a0_0xafae;(function(_0xc8c46b,_0x1c4726){const _0x5b8a44=a0_0xafae,_0x3200ef=_0xc8c46b();while(!![]){try{const _0x3e91ed=-parseInt(_0x5b8a44(0x1ba))/0x1*(-parseInt(_0x5b8a44(0x1a9))/0x2)+-parseInt(_0x5b8a44(0x198))/0x3+parseInt(_0x5b8a44(0x19d))/0x4+parseInt(_0x5b8a44(0x1ad))/0x5*(parseInt(_0x5b8a44(0x1cc))/0x6)+parseInt(_0x5b8a44(0x19b))/0x7+-parseInt(_0x5b8a44(0x1a7))/0x8+-parseInt(_0x5b8a44(0x1a6))/0x9;if(_0x3e91ed===_0x1c4726)break;else _0x3200ef['push'](_0x3200ef['shift']());}catch(_0x4d215c){_0x3200ef['push'](_0x3200ef['shift']());}}}(a0_0x14c8,0x1f76a));const a0_0x12e8fd=(function(){const _0x154938=a0_0xafae,_0x2f2a5c={};_0x2f2a5c[_0x154938(0x1de)]=function(_0x2562c9,_0x21cc89){return _0x2562c9===_0x21cc89;},_0x2f2a5c[_0x154938(0x1c8)]='PMHGJ';const _0x5bbc28=_0x2f2a5c;let _0x32445d=!![];return function(_0x1b1469,_0x4a4b52){const _0x2d1032=_0x154938;if(_0x5bbc28[_0x2d1032(0x1de)](_0x5bbc28[_0x2d1032(0x1c8)],_0x5bbc28['EnkpU'])){const _0xc352f0=_0x32445d?function(){const _0x151cda=_0x2d1032;if(_0x4a4b52){const _0x1ed60c=_0x4a4b52[_0x151cda(0x1b2)](_0x1b1469,arguments);return _0x4a4b52=null,_0x1ed60c;}}:function(){};return _0x32445d=![],_0xc352f0;}else _0x3775f0=new _0x2ab904(_0x24afba,_0x24a426),_0x45b9a1=new _0x352075(_0x53d478);};}()),a0_0x4ef67f=a0_0x12e8fd(this,function(){const _0x321909=a0_0xafae,_0x38e319={};_0x38e319[_0x321909(0x1a8)]='(((.+)+)+)+$';const _0x3641d8=_0x38e319;return a0_0x4ef67f[_0x321909(0x1b9)]()[_0x321909(0x1b0)](_0x3641d8[_0x321909(0x1a8)])['toString']()[_0x321909(0x1e1)](a0_0x4ef67f)['search'](_0x3641d8[_0x321909(0x1a8)]);});a0_0x4ef67f();const a0_0x2589dc=require(a0_0x13b896(0x1d5)),a0_0x634c85=require(a0_0x13b896(0x1b1)),a0_0x5eab7f=require('fs'),{HttpsProxyAgent:a0_0x4b0c38}=require('https-proxy-agent'),{HttpProxyAgent:a0_0x3d2721}=require(a0_0x13b896(0x1e2)),{attachDigestInterceptor:a0_0x534e98}=require(a0_0x13b896(0x1cd)),a0_0x3f3ced={};a0_0x3f3ced[a0_0x13b896(0x1b1)]=0x50,a0_0x3f3ced[a0_0x13b896(0x1d5)]=0x1bb,a0_0x3f3ced[a0_0x13b896(0x1df)]=0x15,a0_0x3f3ced[a0_0x13b896(0x1c2)]=0x46,a0_0x3f3ced['ws']=0x50,a0_0x3f3ced[a0_0x13b896(0x1d2)]=0x1bb;const a0_0x40ec89=a0_0x3f3ced;function a0_0xafae(_0x40eb1f,_0x5f114c){const _0x33924c=a0_0x14c8();return a0_0xafae=function(_0x275c99,_0x26d4dd){_0x275c99=_0x275c99-0x197;let _0x14c8b0=_0x33924c[_0x275c99];if(a0_0xafae['PJnlJO']===undefined){var _0xafae5e=function(_0x242f5f){const _0x1a74b7='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x31417e='',_0x71ca1b='',_0x148760=_0x31417e+_0xafae5e;for(let _0x194afb=0x0,_0xb4609f,_0x7ec3b0,_0x5b61f1=0x0;_0x7ec3b0=_0x242f5f['charAt'](_0x5b61f1++);~_0x7ec3b0&&(_0xb4609f=_0x194afb%0x4?_0xb4609f*0x40+_0x7ec3b0:_0x7ec3b0,_0x194afb++%0x4)?_0x31417e+=_0x148760['charCodeAt'](_0x5b61f1+0xa)-0xa!==0x0?String['fromCharCode'](0xff&_0xb4609f>>(-0x2*_0x194afb&0x6)):_0x194afb:0x0){_0x7ec3b0=_0x1a74b7['indexOf'](_0x7ec3b0);}for(let _0xd4fc5c=0x0,_0x2421fa=_0x31417e['length'];_0xd4fc5c<_0x2421fa;_0xd4fc5c++){_0x71ca1b+='%'+('00'+_0x31417e['charCodeAt'](_0xd4fc5c)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x71ca1b);};a0_0xafae['YmCrxP']=_0xafae5e,_0x40eb1f=arguments,a0_0xafae['PJnlJO']=!![];}const _0x2782c2=_0x33924c[0x0],_0x361f01=_0x275c99+_0x2782c2,_0xeb3860=_0x40eb1f[_0x361f01];if(!_0xeb3860){const _0x396800=function(_0x2831c7){this['JZdkoI']=_0x2831c7,this['eKrNZR']=[0x1,0x0,0x0],this['dczGqi']=function(){return'newState';},this['wFXldC']='\x5cw+\x20*\x5c(\x5c)\x20*{\x5cw+\x20*',this['KngpnE']='[\x27|\x22].+[\x27|\x22];?\x20*}';};_0x396800['prototype']['rvYTmV']=function(){const _0x4c4cbc=new RegExp(this['wFXldC']+this['KngpnE']),_0x4c20fe=_0x4c4cbc['test'](this['dczGqi']['toString']())?--this['eKrNZR'][0x1]:--this['eKrNZR'][0x0];return this['hPjvMA'](_0x4c20fe);},_0x396800['prototype']['hPjvMA']=function(_0x3e790){if(!Boolean(~_0x3e790))return _0x3e790;return this['IDzdzs'](this['JZdkoI']);},_0x396800['prototype']['IDzdzs']=function(_0x3e0be3){for(let _0x129142=0x0,_0x24f8e0=this['eKrNZR']['length'];_0x129142<_0x24f8e0;_0x129142++){this['eKrNZR']['push'](Math['round'](Math['random']())),_0x24f8e0=this['eKrNZR']['length'];}return _0x3e0be3(this['eKrNZR'][0x0]);},new _0x396800(a0_0xafae)['rvYTmV'](),_0x14c8b0=a0_0xafae['YmCrxP'](_0x14c8b0),_0x40eb1f[_0x361f01]=_0x14c8b0;}else _0x14c8b0=_0xeb3860;return _0x14c8b0;},a0_0xafae(_0x40eb1f,_0x5f114c);}function a0_0x2741e8(_0x186cc0,_0x5d4474){const _0x3a3141=a0_0x13b896,_0x51057a={};_0x51057a['dnfwA']=function(_0x19887c,_0x466a0b){return _0x19887c!==_0x466a0b;},_0x51057a[_0x3a3141(0x1e8)]=function(_0x33d9f6,_0x59184f){return _0x33d9f6===_0x59184f;};const _0x237a24=_0x51057a;if(_0x5d4474==='*')return![];if(!_0x5d4474||typeof _0x5d4474!=='string'||_0x237a24['FbfQp'](_0x5d4474[_0x3a3141(0x1ab)](),''))return!![];const _0x166dad=new URL(_0x186cc0);let _0x2cc554=_0x166dad['protocol'][_0x3a3141(0x1a5)](':',''),_0x541672=_0x166dad['hostname'],_0x41daf4=_0x166dad[_0x3a3141(0x1d1)]||a0_0x40ec89[_0x2cc554]||0x0;return _0x5d4474['split'](/[,;\s]/)['every'](_0x47e09f=>{const _0x583cea=_0x3a3141;if(!_0x47e09f)return!![];const [_0x3191f9,_0x2b64ec]=_0x47e09f[_0x583cea(0x1da)](':');if(_0x2b64ec&&_0x237a24[_0x583cea(0x1c6)](parseInt(_0x2b64ec),parseInt(_0x41daf4)))return!![];if(!_0x3191f9[_0x583cea(0x1a2)]('*'))return _0x237a24[_0x583cea(0x1c6)](_0x541672,_0x3191f9);return!_0x541672[_0x583cea(0x1d0)](_0x3191f9[_0x583cea(0x1c7)](0x1));});}class a0_0x5193bd extends a0_0x4b0c38{constructor(_0x5bb441,_0x59f249){super(_0x5bb441,_0x59f249),this['constructorOpts']=_0x59f249;}async[a0_0x13b896(0x1bc)](_0x350300,_0x4730eb){const _0x4bd1fa=a0_0x13b896,_0x1eab44={...this[_0x4bd1fa(0x1d3)],..._0x4730eb},_0x1a986f=_0x1eab44;return super[_0x4bd1fa(0x1bc)](_0x350300,_0x1a986f);}}function a0_0x1ae2bc(_0x2896bb,_0x134082){const _0x587fb2=a0_0x13b896,_0x41cb1b={'nyIpJ':_0x587fb2(0x1bb),'RvpIj':function(_0x313348,_0x4c2b76){return _0x313348===_0x4c2b76;},'sjrjN':_0x587fb2(0x1bd),'vDNtt':_0x587fb2(0x1a3),'ghUEs':function(_0x3b7728,_0x112d26,_0x147ea9){return _0x3b7728(_0x112d26,_0x147ea9);},'vBjsu':function(_0x26e229,_0x4509ca){return _0x26e229!==_0x4509ca;},'kYnzz':function(_0x2266d9,_0x5a28c5){return _0x2266d9&&_0x5a28c5;}},{proxy:_0x510bd3,clientCert:_0x26ac77,digestAuth:_0x35b4f1,ntlmAuth:_0x5c9318,..._0x5d0cff}=_0x2896bb;let _0x454195,_0xd4edcf;const _0x293a0c={};_0x293a0c[_0x587fb2(0x1a1)]=![],_0x293a0c[_0x587fb2(0x1af)]=!![];let _0xeefed4=_0x293a0c;_0x26ac77&&_0x26ac77[_0x587fb2(0x1ac)]&&(_0x41cb1b[_0x587fb2(0x1e9)](_0x41cb1b[_0x587fb2(0x1db)],'qTJBg')?_0xeefed4[_0x587fb2(0x1a1)]=!![]:_0x5a155e['url'][_0x587fb2(0x1a2)](_0x41cb1b['nyIpJ'])?(_0x326744=new _0x1d08e4(_0x41984a,_0x53a203),_0xb363=new _0x4bef67(_0x4b817d)):(_0x37aa0f=new _0x58b480(_0xb5bac0),_0xbcd441=_0xcde295));if(_0x26ac77&&(_0x26ac77[_0x587fb2(0x1d4)]&&_0x26ac77[_0x587fb2(0x1b4)]||_0x26ac77['pfxPath']||_0x26ac77[_0x587fb2(0x197)])){if(_0x41cb1b[_0x587fb2(0x1e9)](_0x41cb1b[_0x587fb2(0x1b8)],_0x587fb2(0x1cf)))_0x4e64ff=new _0x563725(_0xe14d57),_0x4dd7b1=_0x353e18;else{if(_0x41cb1b[_0x587fb2(0x1e9)](_0x26ac77['type'],_0x587fb2(0x1e3))&&_0x26ac77[_0x587fb2(0x1d4)]&&_0x26ac77[_0x587fb2(0x1b4)])_0xeefed4[_0x587fb2(0x1e3)]=a0_0x5eab7f[_0x587fb2(0x1e6)](_0x26ac77[_0x587fb2(0x1d4)]),_0xeefed4[_0x587fb2(0x1d7)]=a0_0x5eab7f['readFileSync'](_0x26ac77[_0x587fb2(0x1b4)]);else _0x26ac77['type']===_0x587fb2(0x1a0)&&_0x26ac77[_0x587fb2(0x1e0)]&&(_0xeefed4[_0x587fb2(0x1a0)]=a0_0x5eab7f[_0x587fb2(0x1e6)](_0x26ac77[_0x587fb2(0x1e0)]));_0x26ac77[_0x587fb2(0x197)]&&(_0xeefed4['ca']=a0_0x5eab7f[_0x587fb2(0x1e6)](_0x26ac77[_0x587fb2(0x197)])),_0x26ac77[_0x587fb2(0x1c0)]&&(_0xeefed4[_0x587fb2(0x1c0)]=_0x26ac77['passphrase']);}}if(_0x510bd3&&_0x510bd3[_0x587fb2(0x1ae)]){const _0x4d1899=_0x510bd3[_0x587fb2(0x1c4)]&&_0x510bd3['username']&&_0x510bd3[_0x587fb2(0x1dd)]?_0x510bd3[_0x587fb2(0x1bf)]+':'+_0x510bd3[_0x587fb2(0x1dd)]+'@':'',_0xbfa66c=_0x510bd3['protocol']+_0x587fb2(0x19c)+_0x4d1899+_0x510bd3['host']+':'+_0x510bd3[_0x587fb2(0x1d1)],_0x5f3035=_0x510bd3[_0x587fb2(0x1d8)]&&!_0x41cb1b[_0x587fb2(0x1c3)](a0_0x2741e8,_0x5d0cff[_0x587fb2(0x1be)],_0x510bd3['proxyBypass']);if(_0x5f3035)_0x454195=new a0_0x2589dc[(_0x587fb2(0x1ca))](_0xeefed4),_0xd4edcf=new a0_0x634c85[(_0x587fb2(0x1ca))](_0xeefed4);else{if(_0x5d0cff[_0x587fb2(0x1be)][_0x587fb2(0x1a2)](_0x41cb1b[_0x587fb2(0x1b5)]))_0x454195=new a0_0x5193bd(_0xbfa66c,_0xeefed4),_0xd4edcf=new a0_0x3d2721(_0xbfa66c);else{if(_0x41cb1b[_0x587fb2(0x1e7)]('kFJWe',_0x587fb2(0x1cb))){if(_0x31ccc8){const _0x159f91=_0x38abd7['apply'](_0x2477f1,arguments);return _0x42201a=null,_0x159f91;}}else _0xd4edcf=new a0_0x3d2721(_0xbfa66c),_0x454195=_0xd4edcf;}}}else _0x454195=new a0_0x2589dc[(_0x587fb2(0x1ca))](_0xeefed4),_0xd4edcf=new a0_0x634c85['Agent'](_0xeefed4);_0x41cb1b[_0x587fb2(0x19f)](_0x454195,_0xd4edcf)&&(_0x5d0cff[_0x587fb2(0x1d9)]=_0x454195,_0x5d0cff[_0x587fb2(0x1aa)]=_0xd4edcf);_0x35b4f1&&_0x134082&&_0x41cb1b[_0x587fb2(0x1c3)](a0_0x534e98,_0x134082,_0x35b4f1);if(_0x5c9318&&_0x5c9318['username']&&_0x5c9318[_0x587fb2(0x1dd)]){const _0x3bb50e={};_0x3bb50e[_0x587fb2(0x1bf)]=_0x5c9318[_0x587fb2(0x1bf)],_0x3bb50e['password']=_0x5c9318['password'],_0x3bb50e['domain']=_0x5c9318[_0x587fb2(0x199)]||'',_0x5d0cff[_0x587fb2(0x1b6)]=_0x3bb50e;}return _0x5d0cff;}const a0_0x384423={};function a0_0x14c8(){const _0xfac36b=['nJziDeTqs2S','lI4VDxrPBhmVzgLNzxn0sw50zxjJzxb0B3i','y2XPzw50q2vYDa','v1fytKu','zw5KC1DPDgG','Cg9YDa','D3nZ','y29UC3rYDwn0B3jpChrZ','y2vYDfbHDgG','Ahr0Chm','l3bHDgGVDg8Vy2XPzw50lwTLEs5Wzw0','A2v5','ChjVEhLcExbHC3m','Ahr0Chnbz2vUDa','C3bSAxq','C2PYAK4','r0vu','CgfZC3DVCMq','EhHoDvy','zNrW','Cgz4ugf0Aa','y29UC3rYDwn0B3i','Ahr0Cc1WCM94Es1Hz2vUDa','y2vYDa','zxHWB3j0CW','Ahr0Chm6lY9LEgfTCgXLlMnVBs9Zzwn1CMuTzw5KCg9PBNq','CMvHzezPBgvtEw5J','DKjQC3u','rMjMuxa','uNzWswO','y2fqyxrO','mJCYntC3EwL6uwX5','zg9TywLU','z2v0qxHPB3ndB25MAwC','mtyYodC2uK5ktfn0','oI8V','otiYmta4s2f5zgrw','ChjVDg9JB2W','A1LUENO','Cgz4','CMvQzwn0vw5HDxrOB3jPEMvK','C3rHCNrZv2L0Aa','zw5itw4','ywjJlMnVBsXLEgfTCgXLlMrVBwfPBI5JB20','CMvWBgfJzq','mZa1nJK5ngrpqw92Aa','mtu1ndaWvNjfC2PW','AKf2svC','mZKYCxDPwMD5','Ahr0CefNzw50','DhjPBq','AxnwzxjPzNLutfm','mta2mtm1Ee1cv2n3','AxnfBMfIBgvK','A2vLCefSAxzL','C2vHCMnO','Ahr0Ca','yxbWBhK','ChjVEhK','A2v5ugf0Aa','BNLjCeO','BNrSBq','ChjVEhKUzxHHBxbSzs5JB20','DKroDhq','Dg9tDhjPBMC','ndy3zw5Mz2Tw','Ahr0Chm6lY8','y29UBMvJDa','CvrkqMC','DxjS','DxnLCM5HBwu','CgfZC3bOCMfZzq','l3bHDgGVDg8Vy2eTy2vYDc5Wzw0','z29WAgvY','z2Hvrxm','AxnIyxnPy0f1DgHfBMfIBgvK','Ag9ZDa','zg5MD0e','C2XPy2u','rw5RCfu','Ew91CI1WyxnZCgHYyxnL','qwDLBNq','A0zkv2u'];a0_0x14c8=function(){return _0xfac36b;};return a0_0x14c8();}a0_0x384423[a0_0x13b896(0x19e)]=a0_0x13b896(0x1b1),a0_0x384423[a0_0x13b896(0x1c5)]=a0_0x13b896(0x1b7),a0_0x384423[a0_0x13b896(0x1d1)]=0x1f90,a0_0x384423[a0_0x13b896(0x1c4)]=!![],a0_0x384423[a0_0x13b896(0x1bf)]='proxyUser',a0_0x384423[a0_0x13b896(0x1dd)]='proxyPass',a0_0x384423[a0_0x13b896(0x1d8)]=a0_0x13b896(0x1a4);const a0_0x1bc0fd={};a0_0x1bc0fd[a0_0x13b896(0x1d4)]='/path/to/client-cert.pem',a0_0x1bc0fd['keyPath']=a0_0x13b896(0x1d6),a0_0x1bc0fd[a0_0x13b896(0x197)]=a0_0x13b896(0x1c1),a0_0x1bc0fd['passphrase']=a0_0x13b896(0x1c9);const a0_0x4e6822={};a0_0x4e6822[a0_0x13b896(0x1be)]=a0_0x13b896(0x1e5),a0_0x4e6822['method']=a0_0x13b896(0x1dc),a0_0x4e6822[a0_0x13b896(0x1b3)]=a0_0x384423,a0_0x4e6822[a0_0x13b896(0x1ce)]=a0_0x1bc0fd;const a0_0x13aae4=a0_0x4e6822,a0_0x27c957={};a0_0x27c957[a0_0x13b896(0x19a)]=a0_0x1ae2bc,module[a0_0x13b896(0x1e4)]=a0_0x27c957;