2024-08-19 15:49:34 +00:00
|
|
|
|
var _0xodK='jsjiami.com.v7';const _0x218239=_0x1e9b;(function(_0x2576b2,_0x16b7d8,_0x36a847,_0x47eb96,_0x205137,_0x47897d,_0x4752cc){return _0x2576b2=_0x2576b2>>0x7,_0x47897d='hs',_0x4752cc='hs',function(_0xe1121e,_0xe7b06d,_0x266ec5,_0x421f97,_0x157dcb){const _0x540026=_0x1e9b;_0x421f97='tfi',_0x47897d=_0x421f97+_0x47897d,_0x157dcb='up',_0x4752cc+=_0x157dcb,_0x47897d=_0x266ec5(_0x47897d),_0x4752cc=_0x266ec5(_0x4752cc),_0x266ec5=0x0;const _0xeaa55c=_0xe1121e();while(!![]&&--_0x47eb96+_0xe7b06d){try{_0x421f97=parseInt(_0x540026(0x67a,'Ph)S'))/0x1+parseInt(_0x540026(0x492,'@[OF'))/0x2+parseInt(_0x540026(0x229,'aIuR'))/0x3+parseInt(_0x540026(0x662,'QApt'))/0x4+parseInt(_0x540026(0x54d,'RfEK'))/0x5*(parseInt(_0x540026(0x544,'5J%w'))/0x6)+parseInt(_0x540026(0x44e,'O7ZI'))/0x7*(parseInt(_0x540026(0x45d,'Vw]5'))/0x8)+-parseInt(_0x540026(0x254,'L1T%'))/0x9*(parseInt(_0x540026(0x642,'JS*j'))/0xa);}catch(_0xfb86e1){_0x421f97=_0x266ec5;}finally{_0x157dcb=_0xeaa55c[_0x47897d]();if(_0x2576b2<=_0x47eb96)_0x266ec5?_0x205137?_0x421f97=_0x157dcb:_0x205137=_0x157dcb:_0x266ec5=_0x157dcb;else{if(_0x266ec5==_0x205137['replace'](/[OKgBfwEkQeRnUMXtlF=]/g,'')){if(_0x421f97===_0xe7b06d){_0xeaa55c['un'+_0x47897d](_0x157dcb);break;}_0xeaa55c[_0x4752cc](_0x157dcb);}}}}}(_0x36a847,_0x16b7d8,function(_0x4e800e,_0x3425b2,_0x36e51b,_0x287ce1,_0x2875d3,_0x23feda,_0xba064a){return _0x3425b2='\x73\x70\x6c\x69\x74',_0x4e800e=arguments[0x0],_0x4e800e=_0x4e800e[_0x3425b2](''),_0x36e51b=`\x72\x65\x76\x65\x72\x73\x65`,_0x4e800e=_0x4e800e[_0x36e51b]('\x76'),_0x287ce1=`\x6a\x6f\x69\x6e`,(0x17ef09,_0x4e800e[_0x287ce1](''));});}(0x6680,0x8d9a6,_0x288c,0xcf),_0x288c)&&(_0xodK=_0x218239(0x13c,'JR^6'));const _0x5d5971=(function(){let _0x208d7a=!![];return function(_0x41ac46,_0xcccca6){const _0x1a37ce=_0x208d7a?function(){const _0x765a25=_0x1e9b;if(_0xcccca6){const _0x14ea57=_0xcccca6[_0x765a25(0x507,'GlrW')](_0x41ac46,arguments);return _0xcccca6=null,_0x14ea57;}}:function(){};return _0x208d7a=![],_0x1a37ce;};}()),_0x38f92b=_0x5d5971(this,function(){const _0x1bbf2e=_0x218239,_0x3f1183={'yeYRb':_0x1bbf2e(0x1ef,'O7ZI')};return _0x38f92b[_0x1bbf2e(0x60b,'dH8R')]()[_0x1bbf2e(0x4e4,'dH8R')](_0x3f1183[_0x1bbf2e(0x174,'VKPW')])[_0x1bbf2e(0x140,'P#)5')]()[_0x1bbf2e(0x206,'J!t3')](_0x38f92b)[_0x1bbf2e(0x673,'9d*C')](_0x3f1183[_0x1bbf2e(0x18f,'sv&w')]);});function _0x288c(){const _0x5ab055=(function(){return[...[_0xodK,'wkBjBsXjetiaRmgwBiE.UUcQofm.nvUK7RlgOMgF==','sSkJDSkAoa','eCkbW4pcO2NcSq','vmksqmkxeZDjfuJdPu3dGq','W6/dHq3cSsm','W5RcLCoGqqW','WPrLjqjV','W60eW5VcTCo7','W5WoWQtcLCkq','W5pcHJTTW77cJSojjuCDxWWbFmkYWQf7','lmoMrqldKW','W7a/Dq','WRKiWOZcQ8oZ','wmoex2FcIG','xGeVjaC','CSkXW4ldJW','gXZcOmk1WQys','xtXsgSkV','WODADmkaA3G','WP1ItMBcLSo0WRCxkZtcQszdWRNcOW','WPrmW70VxCkSgmoXcCoAWOhdG8kz','ESo8rwVcVa','W4VdIaJdOXO','W554W6TVW7a','W7HmzZvS','dmo1WRBdU00','W7VdVa7cKJa','b8orWQJdRu0','zb5T','W63cH8oYeq','W47dTSkdW44B','W6tLT6xMNlFLIQRLIB/KUjZMLQjt','BaCOlYC','WQVcUx/dMCoj','pqeKWQ3dVq','oSoTW4XqfSoZ','W4FdSbJcHIe','fG/cOSkiWQWXW7zSW6vsWPO','W648WQTpda','W77cTmobjCkm','zfdcPmoLWRKmW6q','W7ddNeTEWQG','W5rrd8ojW5tdRWpdTLG','BuRcPa','D8oxwwxcJa','BHpcL8kIuW','WRLcfdztl8o3WPyYxa','dCo8trNcPW','WOfDFSouWPtdU2tdOX1rD2mYcq','WPDUr3RdICoRWP9EdthdRIjIW7dcUK/cQcZdRq','s8k0W4JdKCo5','m8kQa3OR','W6xcTtCitSorWOSCWQK','WPjjDmk+Fq','g8o7FGZdUCkT','4PQX77MHW7O','C0NcR8oFWRK','ySkkW4pdQSoo','W43dH8k/W6q','vg5nWOPUW4XkW6ddQxmCWRZdJa','oJNdSW','pCo/WP0dyqyZqSokjG','WOHmW73dJt0','pVcvUQtdRcFLV4JLIyxOO7/PHBil','WRbFEfFdJrq','WQjNt1/dNW','kNBcOfb9','W4HwzGXA','W7XrxtT7WQnJlxOVFLK','ib8nWQ/dHa','5O2O5AYu5As96lwKWQO','W6W/yCon','Fr5SbCke','WR12W6tdSXy','ASkXW57dJ8o8','W5RdTSktW6yp','W5tdL8k4W6CFW5S','WRTkB8kmuq','WO5azCo/WQS','WQVcGmoG','4PYsWOlOH5JMNQxOV5FOOlNPG7/LIANKURNPLj7ORO/cIW','W5ddL11GWQW','WRhcRxKDDq','WPGxWQNcKSogWOy','WOdcSmkz','4P+TW5lOV7hLIk3LI6tKV7ROO7NPHPJMMiFLKypPOQdLJ7FLPlBLIQRdRCku','WQbGv37dSq','5P6K5A+O6kcOWR7cVrxdImk1WORcU1GNo8oEmdFdKmksW6b65lYw6lED77Y+5Pw25Rgk5zg055wP5lI555gl','r8kwr8kPfa','heRcGeXMxa','aSoBWR4KDW','d1NcNNrW','gCoRWOCzsq','eCkanf4O','W4RdSv8','WOn7W6pdQtxdLG','
|
2024-06-28 07:47:44 +00:00
|
|
|
|
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
|