2023-11-09 19:58:12 +08:00
|
|
|
|
var version_='jsjiami.com.v7';const iiiII=iii1II;(function(ilii11,iiiIl,iiIliI,liIiIl,lII11,illiI1,iIll1i){return ilii11=ilii11>>0x7,illiI1='hs',iIll1i='hs',function(iIll1l,iIIii,ilIl1l,Ii1l1,Il1IlI){const lII1I=iii1II;Ii1l1='tfi',illiI1=Ii1l1+illiI1,Il1IlI='up',iIll1i+=Il1IlI,illiI1=ilIl1l(illiI1),iIll1i=ilIl1l(iIll1i),ilIl1l=0x0;const l11Ii=iIll1l();while(!![]&&--liIiIl+iIIii){try{Ii1l1=parseInt(lII1I(0x4a4,']&V!'))/0x1+parseInt(lII1I(0x355,'rf$('))/0x2+-parseInt(lII1I(0x2eb,']&V!'))/0x3+parseInt(lII1I(0x2db,'fe)v'))/0x4+-parseInt(lII1I(0x204,'jtR9'))/0x5*(-parseInt(lII1I(0x4e3,'fe)v'))/0x6)+parseInt(lII1I(0x418,'YJ2H'))/0x7+-parseInt(lII1I(0x158,'28fR'))/0x8;}catch(iIll11){Ii1l1=ilIl1l;}finally{Il1IlI=l11Ii[illiI1]();if(ilii11<=liIiIl)ilIl1l?lII11?Ii1l1=Il1IlI:lII11=Il1IlI:ilIl1l=Il1IlI;else{if(ilIl1l==lII11['replace'](/[AduDePWfUtkQTqryJLMBlY=]/g,'')){if(Ii1l1===iIIii){l11Ii['un'+illiI1](Il1IlI);break;}l11Ii[iIll1i](Il1IlI);}}}}}(iiIliI,iiiIl,function(IIilll,iIIil,lli1Ii,lli1Il,l11Il,IIilli,l1III1){return iIIil='\x73\x70\x6c\x69\x74',IIilll=arguments[0x0],IIilll=IIilll[iIIil](''),lli1Ii=`\x72\x65\x76\x65\x72\x73\x65`,IIilll=IIilll[lli1Ii]('\x76'),lli1Il=`\x6a\x6f\x69\x6e`,(0x146bd2,IIilll[lli1Il](''));});}(0x5e80,0xb410f,Iii11l,0xbf),Iii11l)&&(version_=iiiII(0x243,']VDX'));const ill1l=$[iiiII(0x4f8,'0HmV')]()?require('./jdCookie.js'):'',iiIIi1=$[iiiII(0x2b8,']z23')]()?require(iiiII(0x664,'KHKU')):'';let i1liI1=$[iiiII(0x362,'OAra')]()?process[iiiII(0x225,'9(S)')][iiiII(0x124,'M@cu')]?process['env'][iiiII(0x5fd,'YJ2H')]:'0':$[iiiII(0x506,'Z%I8')](iiiII(0x698,'OAra'))?$[iiiII(0x199,'G8Qh')](iiiII(0x396,'[wn2')):'0',l1IilI=$[iiiII(0x678,'HEfG')]()?process[iiiII(0x65e,'ykVr')][iiiII(0x333,'[xvW')]?process[iiiII(0x132,'Z%I8')][iiiII(0x548,'H9Cs')]:![]:$['getdata']('opencard_addCart')?$[iiiII(0x36d,'M!(M')](iiiII(0x488,'28fR')):![];const ll1I1i=process[iiiII(0x13c,'xvJZ')][iiiII(0x475,'2cFp')]===iiiII(0x302,']VDX'),iiiiII=require(iiiII(0x32d,'9Uz0')),ll1I1l=require(iiiII(0x3b9,'2cFp')),iilI=require(iiiII(0x327,'[iOM')),IIilI1=require(iiiII(0x367,'&GHg'));let li1Il1='https://lzdz1-isv.isvjcloud.com',i1ii1I=[],iil1='',iiIIiI={};if($['isNode']()){Object['keys'](ill1l)[iiiII(0x307,'fcb%')](lIII1=>{const iiIlil=iiiII;i1ii1I[iiIlil(0x170,'v^iU')](ill1l[lIII1]);});if(process[iiiII(0x48f,'9Uz0')]['JD_DEBUG']&&process[iiiII(0x4d3,'YJ2H')]['JD_DEBUG']===iiiII(0x4c1,'2cFp'))console[iiiII(0x3d4,'&GHg')]=()=>{};}else i1ii1I=[$['getdata']('CookieJD'),$['getdata'](iiiII(0x33b,'G8Qh')),...ill11($['getdata'](iiiII(0x3eb,'Th$A'))||'[]')[iiiII(0x20c,'(7gi')](llIi11=>llIi11[iiiII(0x4b8,'YXUg')])][iiiII(0x2ce,'M@cu')](IIi11I=>!!IIi11I);allMessage='',message='',$[iiiII(0x211,'BA)d')]=![],$[iiiII(0x3e7,'KHKU')]=![],$[iiiII(0xb2,'1@wR')]=![];let i1liII='',ilII1i='',ill1I=process[iiiII(0x323,'Th$A')]['JD_LZ_OPENCARD']?process['env'][iiiII(0x53d,'M!(M')]:iiiII(0x263,'&7Ey'),ilII1l='',IIilII='';$[iiiII(0x352,'0HmV')]=process['env']['jd_opencard_whitelist']||ilII1l,$[iiiII(0x675,'ff3x')]=process[iiiII(0x21b,'0HmV')][iiiII(0x245,'v^iU')]||IIilII,li1Iii(),i1liIl(),$['errMsgPin']=[],!(async()=>{const il11il=iiiII,iiIIlI={'uSCFV':function(IIl1II,iill){return IIl1II(iill);},'dslsI':function(iiIIl1,llIi1I){return iiIIl1>llIi1I;},'WPVyT':function(lIlIii,li1Ili){return lIlIii===li1Ili;},'mfXvr':'false','GGurL':il11il(0x340,'9Uz0'),'RwUOK':function(I11lil,Ili1li){return I11lil!==Ili1li;},'tyTDy':'XGGsu','PQCcX':'sivAt','rUgVZ':il11il(0x341,']VDX'),'XYoMa':function(lIlIil,I11lii){return lIlIil(I11lii);},'VWLCO':il11il(0x517,'ff3x'),'XLMFo':il11il(0x144,'QI$f'),'PIWXl':function(li1Ill,Ili1ll,IIl1Il){return li1Ill(Ili1ll,IIl1Il);},'PNYnR':'TAZzW','DGjyO':il11il(0x3e0,'ff3x'),'RuVie':'dcbfbea6c6584acba3020468b6c5f9bb','icDqk':function(l1Iili,IIi11l){return l1Iili+IIi11l;},'QVpjm':il11il(0x2b3,'Th$A'),'FkPev':'PpcAC','FJttW':'bhuID','WNLnF':function(l1Iill,iiiiIi){return l1Iill===iiiiIi;},'eLHWo':il11il(0x659,'fe)v'),'hJwGw':function(iiiiIl,IIi11i){return iiiiIl+IIi11i;},'ZywVi':'\x0a******开始【京东账号','qIVUW':il11il(0x1e7,']&V!'),'MDCsF':function(iiIIl
|
|
|
|
|
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"])
|