faker3/jd_wechat_signRedpacket.js
2024-06-28 15:38:28 +08:00

14 lines
33 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

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

/*
京东微信签到红包
红包仅可在微信小程序使用
cron:29 4 * * *
*/
const $ = new Env('京东微信签到红包')
var il='jsjiami.com.v7';const i1ilIi=iii1II;function iii1II(_0x1dc3bd,_0x4ff881){const _0x5bd1ec=Iii11l();return iii1II=function(_0x22f136,_0x3eccba){_0x22f136=_0x22f136-0x73;let _0x231ea0=_0x5bd1ec[_0x22f136];if(iii1II['hLPdBo']===undefined){var _0x5b4ece=function(_0x43448f){const _0x57c350='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0xdfae59='',_0xafe673='';for(let _0x184370=0x0,_0x363194,_0xbb0dc9,_0x295609=0x0;_0xbb0dc9=_0x43448f['charAt'](_0x295609++);~_0xbb0dc9&&(_0x363194=_0x184370%0x4?_0x363194*0x40+_0xbb0dc9:_0xbb0dc9,_0x184370++%0x4)?_0xdfae59+=String['fromCharCode'](0xff&_0x363194>>(-0x2*_0x184370&0x6)):0x0){_0xbb0dc9=_0x57c350['indexOf'](_0xbb0dc9);}for(let _0xe0e462=0x0,_0x353fc6=_0xdfae59['length'];_0xe0e462<_0x353fc6;_0xe0e462++){_0xafe673+='%'+('00'+_0xdfae59['charCodeAt'](_0xe0e462)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0xafe673);};const _0x425410=function(_0x3e8c45,_0x44f862){let _0x4c712e=[],_0x1e2e7b=0x0,_0x135345,_0x1e6573='';_0x3e8c45=_0x5b4ece(_0x3e8c45);let _0x509e94;for(_0x509e94=0x0;_0x509e94<0x100;_0x509e94++){_0x4c712e[_0x509e94]=_0x509e94;}for(_0x509e94=0x0;_0x509e94<0x100;_0x509e94++){_0x1e2e7b=(_0x1e2e7b+_0x4c712e[_0x509e94]+_0x44f862['charCodeAt'](_0x509e94%_0x44f862['length']))%0x100,_0x135345=_0x4c712e[_0x509e94],_0x4c712e[_0x509e94]=_0x4c712e[_0x1e2e7b],_0x4c712e[_0x1e2e7b]=_0x135345;}_0x509e94=0x0,_0x1e2e7b=0x0;for(let _0xf39a74=0x0;_0xf39a74<_0x3e8c45['length'];_0xf39a74++){_0x509e94=(_0x509e94+0x1)%0x100,_0x1e2e7b=(_0x1e2e7b+_0x4c712e[_0x509e94])%0x100,_0x135345=_0x4c712e[_0x509e94],_0x4c712e[_0x509e94]=_0x4c712e[_0x1e2e7b],_0x4c712e[_0x1e2e7b]=_0x135345,_0x1e6573+=String['fromCharCode'](_0x3e8c45['charCodeAt'](_0xf39a74)^_0x4c712e[(_0x4c712e[_0x509e94]+_0x4c712e[_0x1e2e7b])%0x100]);}return _0x1e6573;};iii1II['zJdIJu']=_0x425410,_0x1dc3bd=arguments,iii1II['hLPdBo']=!![];}const _0x4a052f=_0x5bd1ec[0x0],_0x599bfc=_0x22f136+_0x4a052f,_0x3b74a6=_0x1dc3bd[_0x599bfc];return!_0x3b74a6?(iii1II['ryaFtk']===undefined&&(iii1II['ryaFtk']=!![]),_0x231ea0=iii1II['zJdIJu'](_0x231ea0,_0x3eccba),_0x1dc3bd[_0x599bfc]=_0x231ea0):_0x231ea0=_0x3b74a6,_0x231ea0;},iii1II(_0x1dc3bd,_0x4ff881);}(function(iii1l1,IIliIl,II11ll,liiI1I,ililII,lI1II1,i1ilII){return iii1l1=iii1l1>>0x5,lI1II1='hs',i1ilII='hs',function(iIIii1,IllIi1,lilIII,Ii1ilI,II11i1){const il1ll=iii1II;Ii1ilI='tfi',lI1II1=Ii1ilI+lI1II1,II11i1='up',i1ilII+=II11i1,lI1II1=lilIII(lI1II1),i1ilII=lilIII(i1ilII),lilIII=0x0;const iliIil=iIIii1();while(!![]&&--liiI1I+IllIi1){try{Ii1ilI=parseInt(il1ll(0xfa,'uvl3'))/0x1*(parseInt(il1ll(0x94,'^w*0'))/0x2)+-parseInt(il1ll(0x19f,'Y*%w'))/0x3+-parseInt(il1ll(0x11c,'qte3'))/0x4+parseInt(il1ll(0x9f,'rwuD'))/0x5*(-parseInt(il1ll(0xe1,'uvl3'))/0x6)+-parseInt(il1ll(0x16a,'Rtkt'))/0x7*(-parseInt(il1ll(0x132,'wlVB'))/0x8)+-parseInt(il1ll(0x10f,'E[Op'))/0x9+parseInt(il1ll(0x145,'sMqA'))/0xa;}catch(iliIii){Ii1ilI=lilIII;}finally{II11i1=iliIil[lI1II1]();if(iii1l1<=liiI1I)lilIII?ililII?Ii1ilI=II11i1:ililII=II11i1:lilIII=II11i1;else{if(lilIII==ililII['replace'](/[RMbEVyKBerlqtPSQIADCN=]/g,'')){if(Ii1ilI===IllIi1){iliIil['un'+lI1II1](II11i1);break;}iliIil[i1ilII](II11i1);}}}}}(II11ll,IIliIl,function(lill1i,il1li,iIIill,iilii,Ill11i,iilil,Ill11l){return il1li='\x73\x70\x6c\x69\x74',lill1i=arguments[0x0],lill1i=lill1i[il1li](''),iIIill=`\x72\x65\x76\x65\x72\x73\x65`,lill1i=lill1i[iIIill]('\x76'),iilii=`\x6a\x6f\x69\x6e`,(0x16bda1,lill1i[iilii](''));});}(0x19a0,0x18e26,Iii11l,0xcf),Iii11l)&&(il=i1ilIi(0x102,'fpGe'));const notify=$[i1ilIi(0xc2,'2JBc')]()?require(i1ilIi(0x14d,'1Hi0')):'',jdCookieNode=$['isNode']()?require(i1ilIi(0x8c,'s7vA')):'',{H5st}=require('./utils/Rebels_H'),common=require(i1ilIi(0xd8,'Rtkt'));let cookiesArr=[],cookie='',message;if($[i1ilIi(0x191,'0mJC')]()){Object[i1ilIi(0x148,'sp@D')](jdCookieNode)['forEach'](li1i1i=>{cookiesArr['push'](jdCookieNode[li1i1i]);});if(process[i1ilIi(0xd5,'fpGe')][i1ilIi(0x11d,'^w*0')]&&process[i1ilIi(0x1a4,'bdHJ')]['JD_DEBUG']===i1ilIi(0x18c,'jb4X'))console[i1ilIi(0xf4,'VGjr')]=()=>{};}else cookiesArr=[$[i1ilIi(0x121,'@bU[')](i1ilIi(0x154,'I5!b')),$[i1ilIi(0x19a,'2JBc')](i1ilIi(0x131,'bdHJ')),...jsonParse($['getdata'](i1ilIi(0x198,'VrS9'))||'[]')[i1ilIi(0x14b,'sMqA')](IlIli1=>IlIli1[i1ilIi(0x111,'sn(M')])]['filter'](illIiI=>!!illIiI);function Iii11l(){const I1il1l=(function(){return[...[il,'PKRejbsEqjAiamVbMi.StcDColrmBQ.vbN7yAqIq==','jmkTW5CpW40','xSoOW7GEWRG','57QF5y+S776g','5AEac++/LoAYTEAESoInQUwnHowKQUwsRq','W7RdKvFcRW','emohWOJcQSka','D8kommkvtCksccmzpG','kLBcNfT+ar4','f8oZW5DaeG','rLi1WOigWRr0WPS','AN0xWQ4F','W67cNCkcWPTL','W7RdN03cQW','W7a7AL/cLW','B0VcNf1KhcuKW4G','W7CWWQy6EX8Jxq','wwi/','AwOoW6X0','vwSVW4bT','rLOYWOa','tfORWOq','qITajCoNW7pcU0pcQa','xEIUN+MgI+AuS+EyH+w9Q+ImHUwnIxHwjCoqf8kH','wSosW5WyWQC','E8kEBCkUEmoGE8klWOvGW60','DYVcKCktWRiLW7eaf8ou','ACkFsG','l8o5W693','ENmFWQaX','tHrr','smosvCo1zG','BfdcNua','lGVdNG0YiImpW50Moa','WRCzo2hdIMNdVMSdW4TxrHZdOdDYW5O/tCozi8obWQGMybOWtNSmWQuIW5TaW5rJFSoDFmoDkcBdRSk+','n8oiWPVcPSk+','wmowuSoAra','WRPwne0h','tx4kmJ8','zCozW77cHZi','WQxdRSkLW6JdU2m0WOJdI3fZwSoygSkXWQHUDCkoW4hdPa/cICo7iq','x1VdGmoRW6FdVxtcGdFdNJtdUConWPu','g8k8WOaira','yIhcRCkWWQO','W5ydEujLW5ZcNq','W688WOClWPi','W5xdM8kwxCkT','p8keWR4','W4FOJOdLVP8','aSo3W615oMBcN2VdIG','WONcKq9gWOtdHg8','a8kxW68PW6CJWOnWdZ7cRgddT8kSEHZdQSk8W6uyW4iFW7T8WQneW6xdKwDiv2FdJ8oooCkRfZFdK0mAWOiBjCkTebv9wMKEW5DVW4SmW7ZdNq','W6Cyxv7cUq','WOHsWQH4W5dcVSoZcaxdJhBcI8kQW4VdS3z8uSkxWQ3dVSkMW7VcQspcUJldUmkTWQfXFSoc','W4vrmqa7WORdSCoSWQFcSmk9WQ0','EmomW53cLH8','tSoRW6uAWQqN','W7/dRSkcwG','WRRcUCoXW4RcMgRcTdZdLSkI','uJnBkCoNW6dcHedcO8k+WQuEeq','omosW5Hija','W40meCoktW','W6XSqdFcIdTuo0FcJq','WQ4joWNcKN83','5lUO5PEE5BA0566F5yMzW6NNRly','WQBcVCoYW6NcGq','566F5yUo57Uz5yYf5yY55AYP','WRdcTmo5WR/cOJuwWOhdIhrrlq','WOBcJsNcJSoXWRNcT2y','uSoetCoQr14','lmoSWOq','W4ddTmkBqxS','kSobW7/dSmkkWRxcPq','iSo3W615oMBLTkFLPj7MLRbvW4VcKq','xcXv','kmk7W7apW7G','gmkxW5aAW5O','WPGMW5xdJa','zxG2W6JdLa','W6r4qZe','WR/cObhcPmoWWPRcM1i','WPOosq','6lEn5y+a5PEO5PEK','uf8HWQCZ','W5NdLCkNW6NdNW','jEIoJ+w/KEs9VUAcQ+wjO++9LW','uc9cimoGW7FcS1hcUmkIWQjEb0tdVW7cIwhcQqbtDv/dSSovpCo4WPqYWP7cPLldSW','tSoRW64u','kmkmW7qYW718W6yBxa','gG5VECoCqSou','W6D8xsFcNtvE','A2SQW5TB','WOPhEmofW7K','W7pdG0q','W5mtuwRcOG','u0NdHSoXW6m','W6vYWRu','WODyBW','WPPahM0Q','rszckq','57IH5y6hW6lKUyRPM4lLSilNQAJLUzBKV7BNLlaG','WPWnBG','ugm/WPCa'],...(function(){return[...['fSoOWRBcKmkY','W55LW67cUCo4','5AELW6dVVBROJB3LVkpKUj7KU6NLPBFLK4BVV6ldTG','WPqSA3T6','WOvnWR9rW4VcRW','W4Dyh8kGeCoBWRpdOLZcH8kwW40a','W6xcO8k6WQz4','5AsiWPNVVlpOJltLVR7KU5ZKU43LPPFLKABVVl7cKG','WRpcTM3dUG','W6FdQ8k5W6ZdVxGnWQ0','m8kkW6WkW5W','WPSaxG','lmoRW6u','mSoejSkadSkxkIuBmKBcJq','W6ZdLCkRENq','u8oruCoNrLq','W4ZdNmk/rCk1','oCoJW4FdTCkT','44o+5OYA56sW44cg6kYd5ysJ6iYy5yYc5lIX5lIG6lAg5y+h5lQnASkHkwOVWO/dSoEANoAoI+s9TUEwSNJcQJnmW4jb55Qf5lUc5lUx56+x5yMA6i6p5y+r','BCk5W5tcTSkk','WRz/px82CwxdQW','mSoKWRRcJ8kX','lmo9W5/dMSkt','W4ZcHSkAWRHpza','WQNcHrFcImof','nJ7LPBtOTOOBeownR+wBOvtdPa','WOadE0fP','W71mW68','W6VdTSk+W7/dOtDmW7BdQ31OcCkfhSo4WQXPnmkaW57dPK7cJSoWnapcQtJcUNekWRVcLSk8WQJdRfxcNZtdRsZdQCkn','5lIB5PA55BwW566x5yQTt+ESOq','WOxcNW9H','jaeHW60Ox8ocW7q','W6aXy3FcISk+jmoP','W5xdJSkMFmkTWQ5GhCksyailW7ZdR3/cP8oyyCobW4BcOhpcTCkiWPOkzSk9AL7dGuLGgmkFFNZdUeeYW4VdJmo3','W5uweSo+','W7FdJmkLW6BdGG','wbvJESos','W4RcGCknWOnaBCkBta','rCors8oI','W5qQW7ZdNff6W7K','W6WoWPCSWRhcTaW','D3CRW4zLaSoEmuddTa','WRiUgMFdJgv9f0NcVWFdMG','FSoBF8oifW','5lUL5lQ26lw75y2G','DNeI','AwO3W4zuv8kzzXC','uCkgW7S','WR95yCodW4G','WQi1W6xcH8ozbNtdJW','CCkmW6tcISkj','W5iDkSomsW','pmkdWPJdLwXRWRmGBheiW7O','WRWQW4VdGv8','WR3cO215WRCeW4lcPmoYuSofxSo5vSk/m2q0WPpcQqfjz8owx8k2jq','BCoAACoTtL0C','WPKSW4ddU0LIW5Pf','W4CKdmoIsa','lCodlSo0l8omESkY','W7jcW7ZcG8oi','AfaFpaG','WQBcNvnZWR0','nSkfWQ8','W5mvWPqB','pmkXjmobWO7cSgZdJ8k3','oWCH','W7tdS+wKPEI2ReFcQUwpOUwzISoSEW','WQJcPI7cS8ox','iHSJW5eDumowW7O','qSoFu8opsG','cmkmW788','W5NdLCk8Aq','zvCH','WRxcOhm','xN0vW6FdGG','t8knW7VcOmkL','W5SvWPunwW','WO1rmw0S','bCkkW7GYW5P4W4e6','W7ykWO0R','W4vPFIZcIa','C20lW4bEvq','W5xdJSkMFmkTWQ5GhCkdybetWRVdOttcUSozlmokW4JcUxlcTmkcWPzlpSk2oGJdIZi5gmkyygFcObSIW4tdHCkUhhVdPZZdT8opt1SZnNFdVG0Lpv8xWRZdLCobW7q','W4iAshxcO8kDfG','57IO5yYCbUs6KEMARowXNEEOSow7MUs9SEExGvG','bSowW6FdP8kM','W6OMWQiZWOC','kCogor/dQG','aSo3W615oMBcPMxcVa','i8ofW6BdSq','WQqjpb7cKMWZ','ywtdQ8oyW4K','W5JdKeO2W4BcLZZdJG','6k6s5yMH6zU35Owr5z6PW6xdHs/cNmob6lYU5ywI5Qcp5l+x5Pw55ywl5A+zqEw4ToITRUMcUEI/GoIhHUAFT+woSoIpQUwnH8ojW5ucWOJcHmor','wmknm8kijG','eW9XW5ryW7HzWPvJWQj1dW','lSk1jSoeWOu','WOSLjaZcKG','FCkBg8kJea','W6VdOmkftW','dSknW60','5l2p5Oki5yM+776z','fZLhiSoQW6dcU0RcV8keWQHm','WOFcPg5YWOW'],...(function(){return['WRNcQCoPW5/cIW','W63dRCk9','bWyjW4aP','57Mj5yYYios5QEMBJEwZGEEOIUw4HEs+R+EvH1ldNa','ESo2BSkAW5FdPvtdImkJW4FdPqC','44ob5O6m56A444o4W74iySoxW4iw5Bw25AAt5PsB','WQaYqwj5','FxSXW6nvv8kzBZ3cSmovd1iB','wwi/W4xdKCkM','W5CTWOG1BG','E8okCSorgG','W7GBmgpdMW','xCoSW7lcGXu','jmoXWOZcSSkR','lCo3W6vxixe','WP9oEmoj','hWlcGmkOWQZcUJFcHh7cUW','dSoedZBdLq','WO3cOhhdUYJdQXddJW','WRqYW7q','D8kxDmoRtq','WRpcTdjtWQO','W7xdQCoCtui','g1P1W5Ki','iCkAW4hcGr88WQKtrhH+W5P9','wHTthCoN','WP1/jLiZDuG','DCkygCkkb8kAcG','zsHzF8oo','wSktW7xcLSotW5ezEsmbWR9hWOuZh8obiq','fCoRcZy','W6ldQSktW5xdKq','W77cUHVcOCo9WQRcUW','WRGLW4/cI8oe','dSowaaZdIa','a8oPdZ3dHG','BIn3tCoo','z8omEG','W7zgW7ZcHmobjSo8','W6j2wGVcNZPAo2dcJb0','WR/cVCoVW58','WOGJtx95','W7KbihBdKd3cHt0sW54dwLFcRtf/WPeYvSoGDCocWQr8EtyWtwafWQiHW6fmW515FmozFCofFI7dN8o3FxzyW73dPtW9dwqT','W51MWPdcMXW5W6H6W5TOcmoK','r8o3W4ShWRq','5lMB5PEg5Bw6566E5yQqEUEUSq','W4n5ihSRBN0','WR/cVbtcICoBWP/cHW','57UV5y6HWQpKUzhPMRVLS47NQ4/LUkxKVOlNLQy6bq','W4iadCoWDd8','WPPwWQP9W5FcUSo7gHu','WR/cObhcPmoNWO/cG1vYWOS','WP0hEKfTW5/dHq','qSoyCSoLzW','W5tdLmkXymkRW7aQqq','WQdcQmoYW5VcMttdL3RdH8kZirRcSSkOmmkIW4niWONcI8oyWPVdIh/dRMNcUmktcCkOW6KFnSk2eYdcR8oLq3mgiSoy','o8k8jSon','DSketmosESo1','W7LvsGBcTG','jrhdNWiKsxHY','W654wJu','pSkyWR4','W6ddJSkYW67dVG','6k295yUM6zQH5OwB5z+uefqTrmkA6l+I5yEj5QgB5l645Psz5yA/5A+zqEw6V+IVN+MaT+I+GUIeIoAFQUwmKEInLowpHmkkWRtdILNcHmoA','W6pdRSkw','Cv7cMLDI','WQBcN8oXW6dcRW','qmoUFSoseG','WRu9W7BcIa','FmoCW70AWQC','4P+ns+IhVUADS+I8GoIIN+MaRUwkQUs7S+MxVUIVSe8','W6jTwItcJ2GuEN3cJapdMNq1ru0fkc0qwwTXWQNdH8omzCkrW6lcLfBdN8kic8kUhmohcCk9ECoXpSkXBePae8oEDcxdSxRdKSo4W6ldMqnAsSkuW4ldKmk7W70','WR/cVqtcO8oAWPZcI0D+','WOvyFW','CCk8aSkCeW','E+IpN+w/Kq','zCk7a8kHna','44ko5O2G56sz44oF6k2N5yEc6i6J5y6y5lUI5lM86ls/5yYN5lQwWQjwsmkxWPyBd+EzTUAoJUs9KUEuQXnVbHtdRtRNMi3KUkNKUl3NR4xLIRZOJkBLJAu','WQOFbHxcL30','W5igbCo1wtVdNgC','W5KbxuFcUSkp','wSogW47cLXiYWQSD','Ds/cLmkbWQu','DmkFiCkve8ojs2unpKhcMM10WQldPSk1W5NdLSkRWONcICk5aMhdQvJcGM3dGCkof2VdUSkfgCkpWP/dQrjysbi','WRVcTCoHW4xcRM/cGsy','wgi/WO0+','W5/dLCk2Dq','yCouW4BcGa','pGSPW5iD','WRC1W6ZcImoXc3q','tCkNDmocrG','56YT5yUB5OUj5yUZ','fSkGWRqHqW','WQdcPaj1WO8','WP3cR8oJW5NcPg/cLta','qmoTW6qyWPjWWQCRWQqJ','W5eBWP4','ueBdNa','CCkojSkwaCkuaq','W4iCm2JdOgJdH2iCW4apgK7dNd90W6W4xSoJdSoqWR5W','WQq2wYdcLt5iELZcJbpdIxeLF1aeccOCqcP8','57Q+5y+U772p'];}())];}())];}());Iii11l=function(){return I1il1l;};return Iii11l();};!(async()=>{const lill1l=i1ilIi,lI1lli={'yfmYm':lill1l(0x15c,'qte3'),'HFQOv':function(Ill1l,llI1Il){return Ill1l<llI1Il;},'zVFMz':function(ii1iii,i11iil){return ii1iii(i11iil);},'cTZTX':function(Ill1i,ii1iil){return Ill1i+ii1iil;},'cmDIa':function(lllI1l,i11iii){return lllI1l!==i11iii;},'Mmamv':lill1l(0xdb,'sn(M'),'icoQa':lill1l(0xa0,'sn(M'),'nCwKE':function(llI1Ii,lllI1i,li1i1l){return llI1Ii(lllI1i,li1i1l);},'AZyug':function(II1i1,lI1lll){return II1i1*lI1lll;}};if(!cookiesArr[0x0]){$[lill1l(0xb1,'6V)G')]($[lill1l(0x17f,'jb4X')],lill1l(0x152,'0Url'),lill1l(0xab,'TP%r'),{'open-url':lI1lli[lill1l(0xfd,'9py8')]});return;}for(let iIiII=0x0;lI1lli[lill1l(0xe4,'Y*%w')](iIiII,cookiesArr['length']);iIiII++){if(cookiesArr[iIiII]){cookie=cookiesArr[iIiII],$[lill1l(0xc5,'s7vA')]=lI1lli['zVFMz'](decodeURIComponent,cookie['match'](/pt_pin=([^; ]+)(?=;?)/)&&cookie[lill1l(0xb5,'uvl3')](/pt_pin=([^; ]+)(?=;?)/)[0x1]),$[lill1l(0x73,'0Url')]=lI1lli[lill1l(0x14e,'(06k')](iIiII,0x1),$['isLogin']=!![],$[lill1l(0x18e,'bdHJ')]='',message='',console[lill1l(0x15b,'aEfn')]('\x0a******开始【京东账号'+$['index']+'】'+($['nickName']||$[lill1l(0xd2,'TP%r')])+lill1l(0x84,'fpGe'));if(!$[lill1l(0x8f,'1Hi0')]){if(lI1lli['cmDIa'](lI1lli[lill1l(0x10d,'WeO1')],lI1lli[lill1l(0xcc,'hBzV')])){$[lill1l(0x189,'sp@D')]($[lill1l(0xcb,'s7vA')],lill1l(0x79,'OUa5'),lill1l(0x16c,'Jtyh')+$[lill1l(0x7f,'Gs8V')]+'\x20'+($['nickName']||$[lill1l(0x86,'sp@D')])+'\x0a请重新登录获取\x0ahttps://bean.m.jd.com/bean/signIndex.action',{'open-url':lI1lli[lill1l(0x137,'WeO1')]});$['isNode']()&&await notify['sendNotify']($[lill1l(0x128,'Rtkt')]+lill1l(0x122,'VrS9')+$['UserName'],'京东账号'+$['index']+'\x20'+$['UserName']+lill1l(0xf0,'hBzV'));continue;}else IiIl[lill1l(0x7c,'tlPJ')](IiIi,iI1ll1);}$['UA']='Mozilla/5.0\x20(iPad;\x20CPU\x20OS\x2016_4_1\x20like\x20Mac\x20OS\x20X)\x20AppleWebKit/605.1.15\x20(KHTML,\x20like\x20Gecko)\x20Mobile/15E148\x20MicroMessenger/8.0.49(0x1800312b)\x20NetType/WIFI\x20Language/zh_CN',await Main(),await $[lill1l(0x18f,'Bfm4')](lI1lli[lill1l(0xb6,'TP%r')](parseInt,lI1lli[lill1l(0xd1,'PgIc')](Math['random'](),0x3e8)+0x7d0,0xa));}}})()[i1ilIi(0x17b,'aEfn')](iiiliI=>{const l1l1i1=i1ilIi;$['log']('','❌\x20'+$[l1l1i1(0x199,'@bU[')]+l1l1i1(0x182,'sp@D')+iiiliI+'!','');})[i1ilIi(0xcd,'OUa5')](()=>{const i1iiI=i1ilIi;$[i1iiI(0xe6,'HT)d')]();});async function Main(){const i1ilIl=i1ilIi,li1i1I={'nWcTB':i1ilIl(0x10a,'VrS9'),'zYCfu':function(illIii,ii1il1){return illIii(ii1il1);},'dropX':'CookiesJD','sLdRJ':i1ilIl(0x12c,'Y*%w'),'znUvw':function(lI1llI,illIil){return lI1llI===illIil;},'doXyc':i1ilIl(0xec,'0mJC'),'OpPxt':'wKxdM'};try{$[i1ilIl(0x10b,'PgIc')]=![];const Ill1I=await common[i1ilIl(0x7b,'0mJC')](cookie);if(!Ill1I&&typeof Ill1I==='boolean'){if(i1ilIl(0x18b,'mGz4')===li1i1I[i1ilIl(0xae,'Rtkt')]){console[i1ilIl(0xd4,'jb4X')]('账号无效');return;}else lI1Iii=[i1li['getdata']('CookieJD'),li1II['getdata'](li1i1I[i1ilIl(0x106,'Bfm4')]),...li1i1I['zYCfu'](IliI11,i1ll[i1ilIl(0x9a,'aEfn')](li1i1I[i1ilIl(0x81,'cVO(')])||'[]')['map'](lIli11=>lIli11[i1ilIl(0xa5,'KBr)')])]['filter'](lllI1I=>!!lllI1I);}await SignComponent_querySignList(),!$[i1ilIl(0x8e,'I5!b')]&&li1i1I['znUvw']($['signStatus'],0x0)&&(li1i1I[i1ilIl(0x164,'wlVB')](li1i1I[i1ilIl(0x183,'^w*0')],i1ilIl(0x120,'(06k'))?(await SignComponent_doSignTask(),await $[i1ilIl(0x9c,'TP%r')](parseInt(Math[i1ilIl(0x14f,'9py8')]()*0x3e8+0x3e8,0xa))):IiilIl['log']('','❌\x20'+iii1Ii['name']+i1ilIl(0x159,'0mJC')+iii1Il+'!',''));}catch(IlIlii){li1i1I['znUvw'](li1i1I[i1ilIl(0x190,'Rtkt')],i1ilIl(0xfc,'cVO('))?console['log']('❌\x20脚本运行遇到了错误\x0a'+IlIlii):(iIli11+=i1ilIl(0xdc,'mGz4')+Iiiil[i1ilIl(0xe3,'Y*%w')]+i1ilIl(0x77,'hrpT'),Iiiii=!![]);}}function jsonParse(liil11){const llI11I=i1ilIi,iiillI={'DFLTt':llI11I(0x90,'wlVB'),'gVUUS':llI11I(0xb7,'@O6P'),'vOTRc':llI11I(0x19d,'IbMl')};if(typeof liil11==llI11I(0x11e,'9py8'))try{if(iiillI[llI11I(0xff,'mG1B')]!==iiillI['gVUUS'])return JSON['parse'](liil11);else i1lI[llI11I(0x187,'sE[6')]();}catch(l1iIII){return console[llI11I(0xf7,'wlVB')](l1iIII),$[llI11I(0x136,'HT)d')]($['name'],'',iiillI['vOTRc']),[];}}async function SignComponent_doSignTask(){const Il1i11=i1ilIi,llI1I1={'mWWys':function(IlIlil){return IlIlil();},'HWYdI':function(lIli1I,II1il){return lIli1I===II1il;},'OFfYX':function(lllI11,I1lIll){return lllI11+I1lIll;},'tGLaF':function(I1lIli,II1ii){return I1lIli===II1ii;},'natBk':function(IIIIII,lillII){return IIIIII>lillII;},'ZQRwY':'yHsNN','ahYZC':function(ii1ilI,lI1ll1){return ii1ilI===lI1ll1;},'kHxRI':Il1i11(0x98,'wlVB'),'JBjlT':Il1i11(0x179,'KBr)'),'ONLVY':'iyMbY','DffmF':Il1i11(0x8b,'Y*%w'),'ZWmfM':'hot_channel','KrlsM':Il1i11(0xaf,'uvl3'),'HNKWZ':Il1i11(0x1a0,'K@1K'),'fwwcG':'10004','VyrTb':Il1i11(0x10e,'^Y)x'),'kMFlW':'zh-cn','jYqKP':Il1i11(0x12f,'4eE('),'rlbyl':'open_id=oTGnpnEbVBxcRWonF3ePdFIOMSCY;','colLc':Il1i11(0xd3,'sn(M'),'GtVAn':function(iIiI1,liil1I){return iIiI1*liil1I;}};return new Promise(async i11ii1=>{const Iil1i1=Il1i11,IlIliI={'xAcys':function(l1iII1,iiill1){return l1iII1+iiill1;},'edNYz':function(lIli1i,IIIII1){const iii1li=iii1II;return llI1I1[iii1li(0x17c,'mG1B')](lIli1i,IIIII1);}};if(Iil1i1(0x95,'OUa5')!==llI1I1[Iil1i1(0xda,'bdHJ')])llI1I1[Iil1i1(0xbe,'1Hi0')](lliiil);else{const ii1ill={'appId':llI1I1[Iil1i1(0x19e,'1Hi0')],'functionId':Iil1i1(0xd7,'Gs8V'),'appid':llI1I1[Iil1i1(0x12d,'qte3')],'clientVersion':llI1I1[Iil1i1(0x195,'@bU[')],'client':llI1I1['HNKWZ'],'body':{'activityId':llI1I1[Iil1i1(0x97,'IbMl')],'version':0x1},'version':Iil1i1(0x139,'OUa5'),'ua':$['UA']},II1iI=await H5st[Iil1i1(0x177,'@O6P')](ii1ill);let llI1II={'url':Iil1i1(0x9e,'Gs8V')+Date[Iil1i1(0x75,'qte3')]()+'&loginType=2&clientType=wxapp&'+II1iI['params']+'&loginWQBiz=signcomponent','headers':{'Accept':llI1I1['VyrTb'],'Accept-Encoding':Iil1i1(0x91,'mGz4'),'Accept-Language':llI1I1[Iil1i1(0x196,'Bfm4')],'Connection':Iil1i1(0xe0,'1Hi0'),'Content-Type':llI1I1[Iil1i1(0x7d,'jb4X')],'Cookie':llI1I1[Iil1i1(0xfe,'I5!b')](llI1I1['rlbyl'],cookie),'Referer':Iil1i1(0xbb,'Rtkt'),'Origin':Iil1i1(0xbb,'Rtkt'),'x-rp-client':llI1I1[Iil1i1(0x185,'9py8')],'User-Agent':$['UA']},'timeout':llI1I1['GtVAn'](0x14,0x3e8)};$[Iil1i1(0xf9,'uvl3')](llI1II,async(lIli1l,lillIi,illIi1)=>{const IIii11=Iil1i1;if(llI1I1['HWYdI'](IIii11(0x100,'s7vA'),IIii11(0x170,'hrpT')))for(let liil1i of Illl11['rewardList']){if(liil1i[IIii11(0x13c,'4eE(')]===0x0)Iiii1+='红包:'+liil1i['discount']+'红包(仅限小程序使用)\x0a',lIIili=!![];else liil1i[IIii11(0xac,'K@1K')]===0x1&&(IiiIil+=IIii11(0x1a5,'hBzV')+liil1i[IIii11(0x184,'hBzV')]+'(满'+liil1i['quota']+'减'+liil1i['discount']+')\x0a',IiiIii=!![]);}else try{if(lIli1l)console[IIii11(0x13a,'hrpT')](llI1I1[IIii11(0x141,'aEfn')]('',JSON[IIii11(0x16e,'0mJC')](lIli1l)));else{if(llI1I1[IIii11(0x151,'@bU[')]('dyaOq','CtRtE'))I1ilI1[IIii11(0x11f,'cVO(')](IlIliI[IIii11(0x18d,'I5!b')]('',iillll[IIii11(0xa6,'^Y)x')](lIIilI)));else{illIi1=JSON[IIii11(0xc6,'oHV3')](illIi1);if(illIi1[IIii11(0x186,'bdHJ')]===0x0&&illIi1['subCode']===0x0){let i1l1iI=IIii11(0xcf,'6V)G');if(illIi1[IIii11(0xb0,'Rtkt')]['signDays']>0x0){if(llI1I1[IIii11(0x17d,'0Url')](IIii11(0x13b,'I5!b'),'MLutp')){if(ilI1lI['type']===0x0)ll1iI+=IIii11(0xbf,'hBzV')+iI1lll[IIii11(0x17a,'Jtyh')]+IIii11(0x13d,'qte3');else IlIliI['edNYz'](IlI1il[IIii11(0x162,'KBr)')],0x1)&&(l1lIll+=IIii11(0x12e,'mG1B')+I1l1II[IIii11(0x178,'rwuD')]+'(满'+IIli1I[IIii11(0x74,'TP%r')]+'减'+I1i11I['discount']+')');}else i1l1iI+=',第'+(illIi1[IIii11(0xed,'Y*%w')][IIii11(0x171,'OUa5')]||0x0)+'天';}if(illIi1['data']['rewardList']&&llI1I1[IIii11(0x11a,'TP%r')](illIi1[IIii11(0xb8,'OUa5')][IIii11(0x113,'TP%r')]['length'],0x0)){if(llI1I1[IIii11(0x103,'6V)G')](llI1I1[IIii11(0x146,'i4][')],'vUaJK')){I1iIil[IIii11(0x99,'@O6P')](lI1Iil[IIii11(0xee,'Y*%w')],IIii11(0xc1,'HT)d'),IIii11(0x161,'sE[6'),{'open-url':IIii11(0xc7,'1Hi0')});return;}else for(let Iiili1 of illIi1['data']['rewardList']){if(llI1I1[IIii11(0x93,'qte3')](Iiili1[IIii11(0x83,'hrpT')],0x0))i1l1iI+=IIii11(0x109,'hrpT')+Iiili1['discount']+IIii11(0x194,'Rtkt');else Iiili1[IIii11(0x162,'KBr)')]===0x1&&(i1l1iI+=',获得优惠券:'+Iiili1[IIii11(0x165,'i4][')]+'(满'+Iiili1[IIii11(0x134,'0mJC')]+'减'+Iiili1['discount']+')');}}console['log'](i1l1iI);}else illIi1[IIii11(0xd6,'1Hi0')]?IIii11(0x197,'IbMl')!==llI1I1[IIii11(0x96,'IbMl')]?lI11Ii[IIii11(0x16f,'mGz4')](IIii11(0xa1,'aEfn')+Iiill[IIii11(0x1a3,'(06k')][IIii11(0x129,'^w*0')]+IIii11(0x142,'^w*0')+l11i1i):console[IIii11(0x13e,'E[Op')](''+illIi1[IIii11(0x118,'2JBc')]):console[IIii11(0x188,'mG1B')](''+JSON[IIii11(0xef,'4eE(')](illIi1));}}}catch(i1i11I){if(llI1I1[IIii11(0xce,'VGjr')](IIii11(0x163,'qte3'),llI1I1['JBjlT']))try{return Iliili[IIii11(0x15a,'E[Op')](Iliill);}catch(iii1ii){return I1llil[IIii11(0x16d,'0mJC')](iii1ii),I1llii[IIii11(0x14c,'VrS9')](lilIll['name'],'',IIii11(0xb3,'Rtkt')),[];}else $[IIii11(0x144,'^Y)x')](i1i11I,lillIi);}finally{i11ii1();}});}});}async function SignComponent_querySignList(){const iliIl1=i1ilIi,il1iIi={'uvVGa':function(iii1il,II11li){return iii1il+II11li;},'ZEpuD':iliIl1(0x157,'i4]['),'ibjvO':function(I1l11i,iIIiiI){return I1l11i===iIIiiI;},'EKmMN':iliIl1(0x1a2,'1Hi0'),'srHWV':'AYZQg','AyilI':iliIl1(0xe5,'i4]['),'ZNVlX':iliIl1(0xa9,'9py8'),'yJZZw':iliIl1(0x16b,'@O6P'),'cLxal':'rUhZG','rXyvi':iliIl1(0x19c,'PgIc'),'Lexlv':'apple','lcsQR':'10004','qJhQJ':'application/json,\x20text/plain,\x20*/*','dNbIv':iliIl1(0x8a,'(06k'),'yzHhP':'keep-alive','qqIRE':function(liiI1i,ililIi){return liiI1i+ililIi;},'XiwSH':'open_id=oTGnpnEbVBxcRWonF3ePdFIOMSCY;','CXkVl':iliIl1(0x192,'sE[6'),'FBHpA':iliIl1(0x169,'0mJC'),'LMzQc':function(lilIIl,ililIl){return lilIIl*ililIl;}};return new Promise(async liiI1l=>{const iii1ll=iliIl1,i1l1II={'spiEj':function(i1ill,I1l11l){return il1iIi['uvVGa'](i1ill,I1l11l);},'xADMu':il1iIi['ZEpuD'],'zYylW':function(lilIIi,i1l1Il){const Ii1il1=iii1II;return il1iIi[Ii1il1(0xf8,'9py8')](lilIIi,i1l1Il);},'VkURA':function(llIli,i1i11l){return llIli!==i1i11l;},'fYTlb':il1iIi[iii1ll(0xd0,'6V)G')],'eLaBq':il1iIi[iii1ll(0x173,'KBr)')],'stKCN':function(i1i11i,II11l1){return i1i11i===II11l1;},'yPVDT':il1iIi['AyilI'],'kZwhT':il1iIi[iii1ll(0xe7,'WeO1')],'Punhw':function(Iil1lI,IiiliI){return Iil1lI===IiiliI;},'PDkhs':function(iii1iI,llIll){return iii1iI===llIll;},'goKBj':function(il1iII,iilli){return il1iII===iilli;},'RYYfI':iii1ll(0x88,'VGjr'),'kpMga':il1iIi[iii1ll(0x115,'VrS9')],'wVVij':iii1ll(0x11b,'PgIc'),'TLAZO':'未登录','aYTNx':il1iIi[iii1ll(0xb2,'qte3')]};if('CHuMa'===iii1ll(0x1a1,'2JBc'))i11I1l[iii1ll(0x193,'WeO1')]=!![];else{const II11lI={'functionId':iii1ll(0x176,'0Url'),'appid':iii1ll(0x9b,'Rtkt'),'clientVersion':il1iIi[iii1ll(0x13f,'Y*%w')],'client':il1iIi[iii1ll(0x172,'mGz4')],'body':{'activityId':il1iIi[iii1ll(0x116,'KBr)')],'version':0x1}};let lI1IIi={'url':iii1ll(0x10c,'bdHJ')+Date[iii1ll(0xbd,'hrpT')]()+iii1ll(0x1a6,'4eE(')+II11lI[iii1ll(0x117,'Rtkt')]+iii1ll(0x105,'E[Op')+II11lI[iii1ll(0x135,'hrpT')]+iii1ll(0xfb,'Gs8V')+II11lI[iii1ll(0x114,'4eE(')]+'&&body='+encodeURIComponent(JSON[iii1ll(0xe8,'uvl3')](II11lI[iii1ll(0xca,'sE[6')]))+iii1ll(0x101,'qte3'),'headers':{'Accept':il1iIi['qJhQJ'],'Accept-Encoding':'gzip,\x20deflate,\x20br','Accept-Language':il1iIi[iii1ll(0x143,'E[Op')],'Connection':il1iIi['yzHhP'],'Content-Type':'application/x-www-form-urlencoded','Cookie':il1iIi['qqIRE'](il1iIi[iii1ll(0x14a,'bdHJ')],cookie),'Referer':il1iIi['CXkVl'],'Origin':il1iIi[iii1ll(0x124,'bdHJ')],'x-rp-client':il1iIi['FBHpA'],'User-Agent':$['UA']},'timeout':il1iIi['LMzQc'](0x14,0x3e8)};$[iii1ll(0x112,'(06k')](lI1IIi,async(I1l11I,Ilil1l,iIIiii)=>{const IIliI1=iii1ll,iilll={'haDQs':function(il1iI1,IlllIi){return il1iI1==IlllIi;},'XHYAX':i1l1II[IIliI1(0x9d,'E[Op')],'PPHPu':'请勿随意在BoxJs输入框修改内容\x0a建议通过脚本去获取cookie','wyvsC':function(iIIiil,i1l1Ii){const il1lI=IIliI1;return i1l1II[il1lI(0xc9,'Y*%w')](iIIiil,i1l1Ii);}};try{if(i1l1II[IIliI1(0xe2,'VrS9')](i1l1II['fYTlb'],i1l1II[IIliI1(0x158,'^w*0')])){if(I1l11I)i1l1II[IIliI1(0xeb,'0mJC')](i1l1II[IIliI1(0xc0,'1Hi0')],IIliI1(0x89,'PgIc'))?IIllI[IIliI1(0x12a,'sMqA')](''+lliilI[IIliI1(0xbc,'^w*0')](lili1)):console[IIliI1(0x15b,'aEfn')](i1l1II['spiEj']('',JSON[IIliI1(0xbc,'^w*0')](I1l11I)));else{if(i1l1II[IIliI1(0x140,'cVO(')](IIliI1(0x8d,'4eE('),i1l1II[IIliI1(0x85,'IbMl')])){iIIiii=JSON['parse'](iIIiii);if(i1l1II[IIliI1(0x127,'tlPJ')](iIIiii[IIliI1(0x130,'sn(M')],0x0)&&iIIiii[IIliI1(0xa3,'^w*0')]===0x0){$[IIliI1(0xa7,'^w*0')]=iIIiii[IIliI1(0xb0,'Rtkt')][IIliI1(0xad,'VGjr')]||0x0;if(i1l1II[IIliI1(0x175,'rwuD')](iIIiii[IIliI1(0xde,'HT)d')]['status'],0x1)||i1l1II[IIliI1(0x125,'bdHJ')](iIIiii[IIliI1(0x166,'9py8')][IIliI1(0xc4,'WeO1')],0x2)){let I1iIIl='',lI1IIl=![];for(let i1ilI of iIIiii['data'][IIliI1(0x15f,'hBzV')]){if(i1ilI['days']===iIIiii[IIliI1(0x15e,'PgIc')][IIliI1(0xc8,'TP%r')])for(let iii1lI of i1ilI[IIliI1(0xf3,'oHV3')]){if(i1l1II[IIliI1(0xdf,'cVO(')](iii1lI[IIliI1(0x162,'KBr)')],0x0))IIliI1(0x150,'sE[6')==='LDHFp'?i1ilii[IIliI1(0x188,'mG1B')](IIliI1(0xba,'Bfm4')+iIIII1):(I1iIIl+=IIliI1(0xd9,'1Hi0')+iii1lI[IIliI1(0x149,'qte3')]+IIliI1(0xa4,'@bU['),lI1IIl=!![]);else i1l1II['Punhw'](iii1lI[IIliI1(0x126,'rwuD')],0x1)&&(I1iIIl+='优惠券:'+iii1lI['useRange']+'(满'+iii1lI[IIliI1(0x7e,'@O6P')]+'减'+iii1lI['discount']+')\x0a',lI1IIl=!![]);}}lI1IIl?console[IIliI1(0x11f,'cVO(')](IIliI1(0x15d,'OUa5')+iIIiii['data'][IIliI1(0xc3,'KBr)')]+IIliI1(0x147,'9py8')+I1iIIl):i1l1II[IIliI1(0x104,'oHV3')](i1l1II[IIliI1(0x80,'s7vA')],IIliI1(0x155,'cVO('))?console[IIliI1(0x181,'hBzV')](IIliI1(0x119,'Y*%w')+iIIiii['data']['signDays']+IIliI1(0xdd,'^Y)x')):IIli11[IIliI1(0x16f,'mGz4')](i1l1II['spiEj']('',IllIII['stringify'](ii1li)));}}else{if(iIIiii[IIliI1(0x168,'Bfm4')]){if(i1l1II['VkURA'](i1l1II['kpMga'],i1l1II[IIliI1(0x18a,'tlPJ')])){lilIil[IIliI1(0xea,'tlPJ')](IIliI1(0x12b,'hrpT'));return;}else console['log'](''+iIIiii[IIliI1(0x133,'Rtkt')]),[i1l1II[IIliI1(0xf1,'sn(M')],i1l1II[IIliI1(0x19b,'fpGe')]]['some'](Iiilil=>iIIiii[IIliI1(0xa8,'E[Op')][IIliI1(0xaa,'sE[6')](Iiilil))&&($['hotFlag']=!![]);}else{if(IIliI1(0x76,'hBzV')===IIliI1(0xb9,'sn(M')){if(iilll[IIliI1(0x107,'sE[6')](typeof iIIl1l,iilll[IIliI1(0xf6,'Y*%w')]))try{return iliIIi['parse'](ill11I);}catch(iillI){return Iliiii[IIliI1(0xb4,'(06k')](iillI),i1illI[IIliI1(0x189,'sp@D')](i1IIl[IIliI1(0xf5,'VrS9')],'',iilll[IIliI1(0x7a,'E[Op')]),[];}}else console[IIliI1(0x15b,'aEfn')](''+JSON[IIliI1(0x180,'K@1K')](iIIiii));}}}else{IiilI1['keys'](IIII1l)['forEach'](IIliIi=>{const IliIIl=IIliI1;IlI11[IliIIl(0x92,'IbMl')](iIIIIl[IIliIi]);});if(IlI1I[IIliI1(0x87,'OUa5')][IIliI1(0x160,'WeO1')]&&iilll[IIliI1(0x110,'s7vA')](II11Ii[IIliI1(0x17e,'6V)G')][IIliI1(0xe9,'jb4X')],IIliI1(0x138,'fpGe')))II11Il['log']=()=>{};}}}else return IliilI[IIliI1(0x108,'6V)G')](i1II1),iIIl11[IIliI1(0x123,'4eE(')](l1l1I1['name'],'',iilll[IIliI1(0x153,'mGz4')]),[];}catch(i1il1){$['logErr'](i1il1,Ilil1l);}finally{i1l1II['goKBj'](i1l1II['aYTNx'],i1l1II[IIliI1(0x156,'@bU[')])?liiI1l():IiiIi1[IIliI1(0x82,'VrS9')](l1ii1,ii1ll);}});}});}var version_ = 'jsjiami.com.v7';
// prettier-ignore
function Env(t,e){"undefined"!=typeof process&&JSON.stringify(process.env).indexOf("GITHUB")>-1&&process.exit(0);class s{constructor(t){this.env=t}send(t,e="GET"){t="string"==typeof t?{url:t}:t;let s=this.get;return"POST"===e&&(s=this.post),new Promise((e,i)=>{s.call(this,t,(t,s,r)=>{t?i(t):e(s)})})}get(t){return this.send.call(this.env,t)}post(t){return this.send.call(this.env,t,"POST")}}return new class{constructor(t,e){this.name=t,this.http=new s(this),this.data=null,this.dataFile="box.dat",this.logs=[],this.isMute=!1,this.isNeedRewrite=!1,this.logSeparator="\n",this.startTime=(new Date).getTime(),Object.assign(this,e),this.log("",`🔔${this.name}, 开始!`)}isNode(){return"undefined"!=typeof module&&!!module.exports}isQuanX(){return"undefined"!=typeof $task}isSurge(){return"undefined"!=typeof $httpClient&&"undefined"==typeof $loon}isLoon(){return"undefined"!=typeof $loon}toObj(t,e=null){try{return JSON.parse(t)}catch{return e}}toStr(t,e=null){try{return JSON.stringify(t)}catch{return e}}getjson(t,e){let s=e;const i=this.getdata(t);if(i)try{s=JSON.parse(this.getdata(t))}catch{}return s}setjson(t,e){try{return this.setdata(JSON.stringify(t),e)}catch{return!1}}getScript(t){return new Promise(e=>{this.get({url:t},(t,s,i)=>e(i))})}runScript(t,e){return new Promise(s=>{let i=this.getdata("@chavy_boxjs_userCfgs.httpapi");i=i?i.replace(/\n/g,"").trim():i;let r=this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout");r=r?1*r:20,r=e&&e.timeout?e.timeout:r;const[o,h]=i.split("@"),n={url:`http://${h}/v1/scripting/evaluate`,body:{script_text:t,mock_type:"cron",timeout:r},headers:{"X-Key":o,Accept:"*/*"}};this.post(n,(t,e,i)=>s(i))}).catch(t=>this.logErr(t))}loaddata(){if(!this.isNode())return{};{this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e);if(!s&&!i)return{};{const i=s?t:e;try{return JSON.parse(this.fs.readFileSync(i))}catch(t){return{}}}}}writedata(){if(this.isNode()){this.fs=this.fs?this.fs:require("fs"),this.path=this.path?this.path:require("path");const t=this.path.resolve(this.dataFile),e=this.path.resolve(process.cwd(),this.dataFile),s=this.fs.existsSync(t),i=!s&&this.fs.existsSync(e),r=JSON.stringify(this.data);s?this.fs.writeFileSync(t,r):i?this.fs.writeFileSync(e,r):this.fs.writeFileSync(t,r)}}lodash_get(t,e,s){const i=e.replace(/\[(\d+)\]/g,".$1").split(".");let r=t;for(const t of i)if(r=Object(r)[t],void 0===r)return s;return r}lodash_set(t,e,s){return Object(t)!==t?t:(Array.isArray(e)||(e=e.toString().match(/[^.[\]]+/g)||[]),e.slice(0,-1).reduce((t,s,i)=>Object(t[s])===t[s]?t[s]:t[s]=Math.abs(e[i+1])>>0==+e[i+1]?[]:{},t)[e[e.length-1]]=s,t)}getdata(t){let e=this.getval(t);if(/^@/.test(t)){const[,s,i]=/^@(.*?)\.(.*?)$/.exec(t),r=s?this.getval(s):"";if(r)try{const t=JSON.parse(r);e=t?this.lodash_get(t,i,""):e}catch(t){e=""}}return e}setdata(t,e){let s=!1;if(/^@/.test(e)){const[,i,r]=/^@(.*?)\.(.*?)$/.exec(e),o=this.getval(i),h=i?"null"===o?null:o||"{}":"{}";try{const e=JSON.parse(h);this.lodash_set(e,r,t),s=this.setval(JSON.stringify(e),i)}catch(e){const o={};this.lodash_set(o,r,t),s=this.setval(JSON.stringify(o),i)}}else s=this.setval(t,e);return s}getval(t){return this.isSurge()||this.isLoon()?$persistentStore.read(t):this.isQuanX()?$prefs.valueForKey(t):this.isNode()?(this.data=this.loaddata(),this.data[t]):this.data&&this.data[t]||null}setval(t,e){return this.isSurge()||this.isLoon()?$persistentStore.write(t,e):this.isQuanX()?$prefs.setValueForKey(t,e):this.isNode()?(this.data=this.loaddata(),this.data[e]=t,this.writedata(),!0):this.data&&this.data[e]||null}initGotEnv(t){this.got=this.got?this.got:require("got"),this.cktough=this.cktough?this.cktough:require("tough-cookie"),this.ckjar=this.ckjar?this.ckjar:new this.cktough.CookieJar,t&&(t.headers=t.headers?t.headers:{},void 0===t.headers.Cookie&&void 0===t.cookieJar&&(t.cookieJar=this.ckjar))}get(t,e=(()=>{})){t.headers&&(delete t.headers["Content-Type"],delete t.headers["Content-Length"]),this.isSurge()||this.isLoon()?(this.isSurge()&&this.isNeedRewrite&&(t.headers=t.headers||{},Object.assign(t.headers,{"X-Surge-Skip-Scripting":!1})),$httpClient.get(t,(t,s,i)=>{!t&&s&&(s.body=i,s.statusCode=s.status),e(t,s,i)})):this.isQuanX()?(this.isNeedRewrite&&(t.opts=t.opts||{},Object.assign(t.opts,{hints:!1})),$task.fetch(t).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>e(t))):this.isNode()&&(this.initGotEnv(t),this.got(t).on("redirect",(t,e)=>{try{if(t.headers["set-cookie"]){const s=t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString();s&&this.ckjar.setCookieSync(s,null),e.cookieJar=this.ckjar}}catch(t){this.logErr(t)}}).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>{const{message:s,response:i}=t;e(s,i,i&&i.body)}))}post(t,e=(()=>{})){if(t.body&&t.headers&&!t.headers["Content-Type"]&&(t.headers["Content-Type"]="application/x-www-form-urlencoded"),t.headers&&delete t.headers["Content-Length"],this.isSurge()||this.isLoon())this.isSurge()&&this.isNeedRewrite&&(t.headers=t.headers||{},Object.assign(t.headers,{"X-Surge-Skip-Scripting":!1})),$httpClient.post(t,(t,s,i)=>{!t&&s&&(s.body=i,s.statusCode=s.status),e(t,s,i)});else if(this.isQuanX())t.method="POST",this.isNeedRewrite&&(t.opts=t.opts||{},Object.assign(t.opts,{hints:!1})),$task.fetch(t).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>e(t));else if(this.isNode()){this.initGotEnv(t);const{url:s,...i}=t;this.got.post(s,i).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>{const{message:s,response:i}=t;e(s,i,i&&i.body)})}}time(t,e=null){const s=e?new Date(e):new Date;let i={"M+":s.getMonth()+1,"d+":s.getDate(),"H+":s.getHours(),"m+":s.getMinutes(),"s+":s.getSeconds(),"q+":Math.floor((s.getMonth()+3)/3),S:s.getMilliseconds()};/(y+)/.test(t)&&(t=t.replace(RegExp.$1,(s.getFullYear()+"").substr(4-RegExp.$1.length)));for(let e in i)new RegExp("("+e+")").test(t)&&(t=t.replace(RegExp.$1,1==RegExp.$1.length?i[e]:("00"+i[e]).substr((""+i[e]).length)));return t}msg(e=t,s="",i="",r){const o=t=>{if(!t)return t;if("string"==typeof t)return this.isLoon()?t:this.isQuanX()?{"open-url":t}:this.isSurge()?{url:t}:void 0;if("object"==typeof t){if(this.isLoon()){let e=t.openUrl||t.url||t["open-url"],s=t.mediaUrl||t["media-url"];return{openUrl:e,mediaUrl:s}}if(this.isQuanX()){let e=t["open-url"]||t.url||t.openUrl,s=t["media-url"]||t.mediaUrl;return{"open-url":e,"media-url":s}}if(this.isSurge()){let e=t.url||t.openUrl||t["open-url"];return{url:e}}}};if(this.isMute||(this.isSurge()||this.isLoon()?$notification.post(e,s,i,o(r)):this.isQuanX()&&$notify(e,s,i,o(r))),!this.isMuteLog){let t=["","==============📣系统通知📣=============="];t.push(e),s&&t.push(s),i&&t.push(i),console.log(t.join("\n")),this.logs=this.logs.concat(t)}}log(...t){t.length>0&&(this.logs=[...this.logs,...t]),console.log(t.join(this.logSeparator))}logErr(t,e){const s=!this.isSurge()&&!this.isQuanX()&&!this.isLoon();s?this.log("",`❗️${this.name}, 错误!`,t.stack):this.log("",`❗️${this.name}, 错误!`,t)}wait(t){return new Promise(e=>setTimeout(e,t))}done(t={}){const e=(new Date).getTime(),s=(e-this.startTime)/1e3;this.log("",`🔔${this.name}, 结束! 🕛 ${s}`),this.log(),(this.isSurge()||this.isQuanX()||this.isLoon())&&$done(t)}}(t,e)}