jdpro/jd_jbpanDraw.js

6 lines
126 KiB
JavaScript
Raw Normal View History

2024-01-27 11:40:17 +00:00
/*
55 1 * * * jd_jbpanDraw.js
*/
const $ = new Env('京保大转盘');
2024-01-27 12:37:29 +00:00
(function(_0x5d485a,_0x11b7f2){const _0x389220={_0xefddb2:'\x30\x78\x32\x66\x63',_0x6bb3a:'\x6b\x5a\x31\x79',_0x1b3520:'\x30\x78\x31\x61\x31',_0x1ae7b3:'\x6b\x5a\x31\x79',_0x212d89:'\x30\x78\x31\x33\x31',_0x55bac6:'\x26\x34\x6c\x63',_0x53ca22:'\x30\x78\x32\x33\x32',_0x4a5654:'\x6e\x28\x30\x71',_0x1eed70:'\x30\x78\x32\x30\x34',_0x330292:'\x55\x73\x72\x6d',_0x51858e:'\x30\x78\x32\x64\x63',_0x6095f3:'\x5a\x38\x29\x58',_0xbd6fb6:'\x30\x78\x33\x33\x65',_0x554de1:'\x30\x78\x31\x62\x34',_0x4df8bc:'\x67\x21\x44\x6e',_0x2ee98c:'\x30\x78\x31\x37\x37',_0x1a05f3:'\x30\x78\x33\x30\x31',_0x57c04a:'\x40\x4a\x49\x6f',_0x4a3752:'\x30\x78\x31\x65\x37',_0x37ff27:'\x38\x54\x6f\x71',_0x1d5dbb:'\x30\x78\x32\x30\x33',_0x139ab4:'\x79\x5b\x6b\x65'},_0x19d040=_0x5d485a();while(!![]){try{const _0x4fdc3d=parseInt(_0x4e97(_0x389220._0xefddb2,_0x389220._0x6bb3a))/(-0x1*-0x1d12+-0x4f8+-0x1f*0xc7)*(-parseInt(_0x4e97(_0x389220._0x1b3520,_0x389220._0x1ae7b3))/(-0x7*-0xad+0x493*0x4+-0x1705))+parseInt(_0x4e97(_0x389220._0x212d89,_0x389220._0x55bac6))/(0x1aef+-0x13c2+0x7*-0x106)*(parseInt(_0x4e97(_0x389220._0x53ca22,_0x389220._0x4a5654))/(-0x1b75+-0x118a+0x3*0xf01))+-parseInt(_0x4e97(_0x389220._0x1eed70,_0x389220._0x330292))/(0xc19+0x16e5+-0x22f9*0x1)*(-parseInt(_0x4e97(_0x389220._0x51858e,_0x389220._0x6095f3))/(0xb88+-0x7c0*-0x2+-0x1b02))+parseInt(_0x4e97(_0x389220._0xbd6fb6,_0x389220._0x1ae7b3))/(0x335+-0x190d*-0x1+-0x291*0xb)*(parseInt(_0x4e97(_0x389220._0x554de1,_0x389220._0x4df8bc))/(-0xfc8+0xf29*0x1+0x1*0xa7))+parseInt(_0x4e97(_0x389220._0x2ee98c,_0x389220._0x6095f3))/(0xb+0x8d2*0x1+-0x8d4)+parseInt(_0x4e97(_0x389220._0x1a05f3,_0x389220._0x57c04a))/(-0x1b3+-0x7e4+-0x1ed*-0x5)*(parseInt(_0x4e97(_0x389220._0x4a3752,_0x389220._0x37ff27))/(-0x137f+0x3b+0x134f*0x1))+-parseInt(_0x4e97(_0x389220._0x1d5dbb,_0x389220._0x139ab4))/(0x5*-0x539+-0x43*0x89+0x17a*0x2a);if(_0x4fdc3d===_0x11b7f2)break;else _0x19d040['push'](_0x19d040['shift']());}catch(_0x909f2b){_0x19d040['push'](_0x19d040['shift']());}}}(_0x3008,0x131c3f+-0x1*0x144343+0x7d*0x1f1f));const _0x59f8f3=$[_0x4e97('\x30\x78\x31\x36\x64','\x58\x29\x44\x5b')]()?require(_0x4e97('\x30\x78\x32\x36\x34','\x6a\x28\x5a\x45')):'',_0x3e0f21=$[_0x4e97('\x30\x78\x33\x30\x32','\x48\x2a\x36\x54')]()?require(_0x4e97('\x30\x78\x33\x33\x36','\x58\x38\x57\x79')):'',_0x1776e9=require(_0x4e97('\x30\x78\x32\x35\x38','\x53\x6b\x73\x36'));let _0x3f2a45=[],_0x550c1b='',_0x6ee29c;if($[_0x4e97('\x30\x78\x32\x62\x34','\x52\x6d\x55\x39')]()){var _0x204867=new Buffer[(_0x4e97('\x30\x78\x31\x38\x66','\x33\x71\x49\x36'))](_0x4e97('\x30\x78\x33\x32\x35','\x5a\x24\x4b\x58'),_0x4e97('\x30\x78\x33\x33\x37','\x73\x7a\x6c\x65'))[_0x4e97('\x30\x78\x33\x31\x37','\x5a\x38\x29\x58')](_0x4e97('\x30\x78\x31\x66\x61','\x48\x2a\x36\x54'));Object[_0x4e97('\x30\x78\x31\x64\x65','\x58\x29\x44\x5b')](_0x3e0f21)[_0x4e97('\x30\x78\x31\x35\x31','\x43\x4d\x29\x63')](_0x21b273=>{const _0x480280={_0x82553b:'\x30\x78\x31\x62\x30',_0xec1f2b:'\x76\x32\x39\x57'};_0x3f2a45[_0x4e97(_0x480280._0x82553b,_0x480280._0xec1f2b)](_0x3e0f21[_0x21b273]);});if(process[_0x4e97('\x30\x78\x32\x33\x31','\x5a\x66\x79\x2a')][_0x4e97('\x30\x78\x31\x39\x38','\x5a\x30\x4d\x51')]&&process[_0x4e97('\x30\x78\x32\x61\x62','\x63\x51\x73\x51')][_0x4e97('\x30\x78\x31\x33\x30','\x64\x4a\x6e\x6d')]===_0x4e97('\x30\x78\x32\x63\x36','\x53\x6b\x73\x36'))console[_0x4e97('\x30\x78\x32\x39\x36','\x5e\x5a\x31\x28')]=()=>{};}else _0x3f2a45=[$[_0x4e97('\x30\x78\x31\x66\x65','\x73\x7a\x6c\x65')](_0x4e97('\x30\x78\x31\x65\x38','\x58\x38\x57\x79')),$[_0x4e97('\x30\x78\x32\x34\x33','\x4b\x48\x63\x39')](_0x4e97('\x30\x78\x32\x38\x30','\x38\x54\x6f\x71')),..._0x339284($[_0x4e97('\x30\x78\x33\x31\x34','\x66\x43\x67\x37')](_0x4e97('\x30\x78\x33\x31\x33','\x64\x4a\x6e\x6d'))||'\x5b\x5d')[_0x4e97('\x30\x78\x31\x62\x37','\x54\x47\x55\x67')](_0x1f0b8c=>_0x1f0b8c[_0x4e97('\x30\x78\x31\x37\x34','\x63\x51\x73\x51')])][_0x4e97('\x30\x78\x32\x62\x65','\x58\x38\x57\x79')](_0x97f7a8=>!!_0x97f7a8);!(async()=>{const _0x49212b={_0x29c06f:'\x30\x78\x33\x32\x64',_0x457a81:'\x77\x44\x32\x57',_0x2750a3:'\x30\x78\x32\x38\x62',_
2024-01-27 11:40:17 +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