2023-12-05 17:47:52 +08:00
|
|
|
|
var iil='jsjiami.com.v7';const iilIi1=iii1II;if(function(I1IIli,Il1I1i,lIilI1,Il1I1l,Ii1Il1,iIIIli,I1IIll){return I1IIli=I1IIli>>0x1,iIIIli='hs',I1IIll='hs',function(i1Ii1,lIilII,ilIlli,I1IIlI,ilIlll){const lIllil=iii1II;I1IIlI='tfi',iIIIli=I1IIlI+iIIIli,ilIlll='up',I1IIll+=ilIlll,iIIIli=ilIlli(iIIIli),I1IIll=ilIlli(I1IIll),ilIlli=0x0;const Ii1Iii=i1Ii1();while(!![]&&--Il1I1l+lIilII){try{I1IIlI=-parseInt(lIllil(0x256,'Qx8d'))/0x1*(-parseInt(lIllil(0x4d0,'8FsO'))/0x2)+parseInt(lIllil(0x2b3,'l&8g'))/0x3+-parseInt(lIllil(0x4ac,'9lM4'))/0x4+parseInt(lIllil(0x4b3,'jium'))/0x5+parseInt(lIllil(0x1f8,'ZGY#'))/0x6*(parseInt(lIllil(0x20f,'*fIn'))/0x7)+parseInt(lIllil(0x215,'b%aF'))/0x8*(parseInt(lIllil(0x3e6,'3aR5'))/0x9)+parseInt(lIllil(0x334,'kGus'))/0xa*(-parseInt(lIllil(0x203,'lH@)'))/0xb);}catch(Ii1Iil){I1IIlI=ilIlli;}finally{ilIlll=Ii1Iii[iIIIli]();if(I1IIli<=Il1I1l)ilIlli?Ii1Il1?I1IIlI=ilIlll:Ii1Il1=ilIlll:ilIlli=ilIlll;else{if(ilIlli==Ii1Il1['replace'](/[tVHxPKMAwCFfDEuegXq=]/g,'')){if(I1IIlI===lIilII){Ii1Iii['un'+iIIIli](ilIlll);break;}Ii1Iii[I1IIll](ilIlll);}}}}}(lIilI1,Il1I1i,function(ll1IiI,li1li,iIIIll,ll1Ii1,li1ll,iliii1,i1IiI){return li1li='\x73\x70\x6c\x69\x74',ll1IiI=arguments[0x0],ll1IiI=ll1IiI[li1li](''),iIIIll=`\x72\x65\x76\x65\x72\x73\x65`,ll1IiI=ll1IiI[iIIIll]('\x76'),ll1Ii1=`\x6a\x6f\x69\x6e`,(0x14a5d3,ll1IiI[ll1Ii1](''));});}(0x192,0x4dd0e,Iii11l,0xcb),Iii11l){}const l111l=require(iilIi1(0x23a,'hNmZ')),I1iilI=require(iilIi1(0x3fb,'pYBs')),Ii1II1=require(iilIi1(0x197,'I7Aa')),lilili=require(iilIi1(0x48a,'jium')),IliIli=process[iilIi1(0x49a,'Mv@$')][iilIi1(0x3bf,')n6l')]||'1',lI1ilI=process[iilIi1(0x1b6,'Ahqt')][iilIi1(0x223,'bMBc')]||iilIi1(0x4bc,'8FsO'),IllliI=process[iilIi1(0x45b,'$1gE')][iilIi1(0x382,'[bXH')]?process[iilIi1(0x1f1,'OMnD')][iilIi1(0x2ec,'B%d#')]:'1',IliIll=process['env'][iilIi1(0x4ad,'l&8g')]===iilIi1(0x2a6,'LkGI'),iIiili=process[iilIi1(0x42d,'jium')]['JD_FCWB_SWISH']==='true',lilill=process[iilIi1(0x1bd,'[bXH')][iilIi1(0x409,'UPy5')]||'3',IilI1=process[iilIi1(0x2d1,'0ch#')][iilIi1(0x1c1,'gjA#')]==='true',l1lI1=process['env']['JD_FCWB_PROXY_TUNNRL'],Ili1I1=process['env'][iilIi1(0x4c8,'*fIn')],lI1I1i=process[iilIi1(0x331,'^jod')]['JD_FCWB_NO_PROXY']||'*.kingran.cf,127.0.0.1,*.baidu.com',liI1II=process['env'][iilIi1(0x3f1,'OJHY')]===iilIi1(0x41f,'$f]E'),i1Iii1={0x1:0x5,0x2:0xf,0x3:0x11};let l1liii=0x3e8;IilI1&&(l1lI1||Ili1I1)&&(l1liii=0x64);let I1Ili1=0x17,l1liil='',i1ll1=0x0,lilI1I=![];if(IilI1){lilI1I=!![];try{require('global-agent/bootstrap');if(Ili1I1){console[iilIi1(0x318,'ZGY#')](iilIi1(0x405,'$46(')),console[iilIi1(0x3da,'UotA')](iilIi1(0x191,'UotA')+Ili1I1+'\x0a');let iIIli1=/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62})+\.?/g;global['GLOBAL_AGENT'][iilIi1(0x1a0,'kGus')]=iIIli1[iilIi1(0x43a,']%jo')](Ili1I1)[0x0]+','+lI1I1i;}else l1lI1?(global[iilIi1(0x340,'G43B')]['HTTP_PROXY']=l1lI1,global[iilIi1(0x295,'myK0')][iilIi1(0x46c,'8FsO')]=''+lI1I1i,console[iilIi1(0x48c,'Y$!^')](iilIi1(0x287,'jium')),console['log']('☑️\x20代理地址为:'+global[iilIi1(0x322,'$f]E')][iilIi1(0x196,'jium')]+'\x0a')):(console[iilIi1(0x3da,'UotA')]('\x0a⚠️\x20当前检测到已开启代理,但未填写代理地址变量'),console[iilIi1(0x3e1,'pYBs')]('⚠\x20代理池变量:export\x20JD_FCWB_PROXY_TUNNRL=\x27http://ip:port\x27'),console[iilIi1(0x3e8,'B%d#')](iilIi1(0x368,'(!DS')));}catch(Ii1l1i){console['log'](iilIi1(0x3ac,'AA(X')),console[iilIi1(0x273,'%S)$')]('\x0a安装命令:npm\x20install\x20global-agent\x0a'),lilI1I=![];}}else console[iilIi1(0x488,'OMnD')](iilIi1(0x255,'Qx8d')),console[iilIi1(0x212,']%jo')]('⚠\x20开启代理变量:export\x20JD_FCWB_PROXY_OPEN=\x27true\x27\x20\x0a');let lI1I1l='';const Il1Il=Object['keys'](l111l)[iilIi1(0x404,'Mbh5')](l1lIl=>l111l[l1lIl])['filter'](Ii1l1l=>Ii1l1l);!Il1Il[0x0]&&($['msg']($[iilIi1(0x3f3,'I7Aa')],'【提示】请先获取Cookie'),process['exit'](0x1));!(async()=>{const I111=iilIi1,i1Iiil={'fjQIV':function(i1Iiii,l1lIi){return i1Iiii+l1lIi;},'qfUbc':I111(0x2a1,'3aR5'),'kSECY':I111(0x375,'bMBc'),'EjrMB':I111(0x418,'1wu
|
|
|
|
|
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.d
|