mirror of https://github.com/6dylan6/jdpro.git
7 lines
249 KiB
JavaScript
7 lines
249 KiB
JavaScript
|
/*
|
||
|
1 6 29 2 * jd_wyw_award.js
|
||
|
*/
|
||
|
|
||
|
const $ = new Env('玩一玩兑换');
|
||
|
const bdy_0x447d34=bdy_0x2472;(function(_0xd8abb7,_0x286ae2){const bdy_0x2b04e0={_0x315659:'\x30\x78\x33\x30\x31',_0x17deac:'\x74\x7a\x31\x7a',_0x20f846:'\x30\x78\x34\x63\x36',_0x278c74:'\x2a\x41\x6e\x79',_0x1fc532:'\x30\x78\x33\x61\x62',_0x419ca2:'\x30\x78\x34\x31\x61',_0x3779eb:'\x5b\x4a\x5b\x5a',_0x347b50:'\x30\x78\x33\x33\x39',_0x11b235:'\x44\x59\x59\x53',_0x309461:'\x30\x78\x34\x38\x36',_0x2c0dd4:'\x37\x59\x43\x4e',_0x3f8a44:'\x30\x78\x35\x36\x61',_0x17fcc3:'\x69\x72\x75\x23',_0x29fe82:'\x30\x78\x34\x38\x37',_0x4e1074:'\x56\x4d\x76\x79',_0x361975:'\x30\x78\x32\x35\x34',_0x5c70b4:'\x30\x78\x33\x39\x31',_0x3956d6:'\x75\x48\x34\x45',_0x1a2a46:'\x30\x78\x33\x32\x66',_0x3f3c68:'\x4b\x77\x77\x66'},_0x4df80f=bdy_0x2472,_0x22250c=_0xd8abb7();while(!![]){try{const _0x2a9366=-parseInt(_0x4df80f(bdy_0x2b04e0._0x315659,bdy_0x2b04e0._0x17deac))/(-0x1*-0x1fe7+0x15b0+-0x26*0x169)+-parseInt(_0x4df80f(bdy_0x2b04e0._0x20f846,bdy_0x2b04e0._0x278c74))/(-0x18a3+-0x1f27+-0x4*-0xdf3)*(parseInt(_0x4df80f(bdy_0x2b04e0._0x1fc532,bdy_0x2b04e0._0x278c74))/(-0x2298*-0x1+0x1723+-0x39b8))+parseInt(_0x4df80f(bdy_0x2b04e0._0x419ca2,bdy_0x2b04e0._0x3779eb))/(0x999*-0x2+-0x7*-0x44b+0x19*-0x6f)*(-parseInt(_0x4df80f(bdy_0x2b04e0._0x347b50,bdy_0x2b04e0._0x11b235))/(-0xcbb*-0x1+0x1*0x17c5+0x21*-0x11b))+-parseInt(_0x4df80f(bdy_0x2b04e0._0x309461,bdy_0x2b04e0._0x2c0dd4))/(-0x260+0x1de6+0x10*-0x1b8)+parseInt(_0x4df80f(bdy_0x2b04e0._0x3f8a44,bdy_0x2b04e0._0x17fcc3))/(-0x1*-0x11b1+-0x1a*0x118+0x563*0x2)+-parseInt(_0x4df80f(bdy_0x2b04e0._0x29fe82,bdy_0x2b04e0._0x4e1074))/(0x2b3*0x5+0x5f*0x17+-0x1600)*(-parseInt(_0x4df80f(bdy_0x2b04e0._0x361975,bdy_0x2b04e0._0x278c74))/(0xef*-0xd+0x1aa+-0x5*-0x21a))+-parseInt(_0x4df80f(bdy_0x2b04e0._0x5c70b4,bdy_0x2b04e0._0x3956d6))/(-0x14fe+0x1c36+-0x72e)*(-parseInt(_0x4df80f(bdy_0x2b04e0._0x1a2a46,bdy_0x2b04e0._0x3f3c68))/(0x23b8+-0x2e*0xe+-0x2129));if(_0x2a9366===_0x286ae2)break;else _0x22250c['push'](_0x22250c['shift']());}catch(_0x20ed33){_0x22250c['push'](_0x22250c['shift']());}}}(bdy_0x1bd8,0x39a*0x552+-0xbede2+0x2eafc));const bdy_0x4ebba4=$[bdy_0x447d34('\x30\x78\x31\x65\x33','\x53\x61\x79\x55')]()?require(bdy_0x447d34('\x30\x78\x34\x66\x66','\x52\x4f\x43\x31')):'',bdy_0x4dd5f1=$[bdy_0x447d34('\x30\x78\x34\x31\x30','\x75\x48\x34\x45')]()?require(bdy_0x447d34('\x30\x78\x32\x35\x38','\x6f\x78\x5d\x34')):'',bdy_0x2b5e1c=require(bdy_0x447d34('\x30\x78\x35\x39\x30','\x62\x5d\x7a\x73')),bdy_0x1ee92a=require(bdy_0x447d34('\x30\x78\x34\x34\x35','\x64\x7a\x71\x30')),bdy_0x347110=process[bdy_0x447d34('\x30\x78\x31\x63\x31','\x41\x54\x56\x57')][bdy_0x447d34('\x30\x78\x33\x64\x34','\x56\x6a\x37\x6c')]?process[bdy_0x447d34('\x30\x78\x34\x64\x62','\x64\x4b\x76\x74')][bdy_0x447d34('\x30\x78\x33\x36\x34','\x4f\x32\x55\x39')]:'\x31\x30';let bdy_0x54ad8c=bdy_0x447d34('\x30\x78\x31\x61\x34','\x31\x2a\x57\x40');const bdy_0xf7d120=process[bdy_0x447d34('\x30\x78\x35\x37\x39','\x64\x7a\x71\x30')][bdy_0x447d34('\x30\x78\x34\x30\x63','\x68\x74\x40\x77')]?process[bdy_0x447d34('\x30\x78\x33\x63\x32','\x6f\x52\x5b\x36')][bdy_0x447d34('\x30\x78\x31\x39\x62','\x67\x79\x6b\x31')]:'\x35';let bdy_0x1b5e27=[],bdy_0x369ad5='',bdy_0xc374b3=0x236d*-0x1+-0x2*-0x1136+0x101,bdy_0x5739af={};if(process[bdy_0x447d34('\x30\x78\x33\x66\x39','\x49\x71\x40\x65')][bdy_0x447d34('\x30\x78\x32\x39\x32','\x66\x4a\x39\x77')])try{require(bdy_0x447d34('\x30\x78\x34\x32\x32','\x4f\x32\x55\x39')),bdy_0x5739af=require(bdy_0x447d34('\x30\x78\x34\x30\x38','\x54\x43\x4b\x21')),$[bdy_0x447d34('\x30\x78\x33\x37\x30','\x64\x4b\x76\x74')]=bdy_0x5739af[bdy_0x447d34('\x30\x78\x34\x61\x31','\x31\x4d\x7a\x59')]($[bdy_0x447d34('\x30\x78\x35\x36\x36','\x54\x43\x4b\x21')][bdy_0x447d34('\x30\x78\x34\x31\x37','\x64\x7a\x71\x30')]($)),$[bdy_0x447d34('\x30\x78\x34\x65\x37','\x62\x5d\x7a\x73')]=bdy_0x5739af[bdy_0x447d34('\x30\x78\x33\x63\x33','\x5d\x31\x47\x70')]($[bdy_0x447d34('\x30\x78\x35\x36\x62','\x53\x61\x79\x55')][bdy_0x447d34('\x30\x78\x31\x65\x36','\x73\x43\x6c\x33')]($));}catch{$[bdy_0x447d34('\x30\x78\x32\x61\x34','\x62\x5d\x7a\x73')](bdy_0x447d34('\x30\x78\x32\x61\x62','\x56\x6a\x37
|
||
|
function Env(o, t) { 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((r, i) => { s.call(this, t, (t, e, s) => { t ? i(t) : r(e) }) }) } 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.logLevels = { debug: 0, info: 1, warn: 2, error: 3 }, this.logLevelPrefixs = { debug: "[DEBUG] ", info: "[INFO] ", warn: "[WARN] ", error: "[ERROR] " }, this.logLevel = "info", 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.encoding = "utf-8", this.startTime = (new Date).getTime(), Object.assign(this, e), this.log("", `🔔${this.name}, 开始!`) } getEnv() { return "undefined" != typeof $environment && $environment["surge-version"] ? "Surge" : "undefined" != typeof $environment && $environment["stash-version"] ? "Stash" : "undefined" != typeof module && module.exports ? "Node.js" : "undefined" != typeof $task ? "Quantumult X" : "undefined" != typeof $loon ? "Loon" : "undefined" != typeof $rocket ? "Shadowrocket" : void 0 } isNode() { return "Node.js" === this.getEnv() } isQuanX() { return "Quantumult X" === this.getEnv() } isSurge() { return "Surge" === this.getEnv() } isLoon() { return "Loon" === this.getEnv() } isShadowrocket() { return "Shadowrocket" === this.getEnv() } isStash() { return "Stash" === this.getEnv() } toObj(t, e = null) { try { return JSON.parse(t) } catch { return e } } toStr(t, e = null, ...s) { try { return JSON.stringify(t, ...s) } catch { return e } } getjson(t, e) { let s = e; if (this.getdata(t)) 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(r => { this.get({ url: t }, (t, e, s) => r(s)) }) } runScript(a, o) { return new Promise(r => { let t = this.getdata("@chavy_boxjs_userCfgs.httpapi"); t = t && t.replace(/\n/g, "").trim(); var e = (e = this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout")) ? +e : 20, [s, i] = (e = o && o.timeout ? o.timeout : e, t.split("@")); this.post({ url: `http://${i}/v1/scripting/evaluate`, body: { script_text: a, mock_type: "cron", timeout: e }, headers: { "X-Key": s, Accept: "*/*" }, timeout: e }, (t, e, s) => r(s)) }).catch(t => this.logErr(t)) } loaddata() { if (!this.isNode()) return {}; this.fs = this.fs || require("fs"), this.path = this.path || require("path"); var t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), s = this.fs.existsSync(t), r = !s && this.fs.existsSync(e); if (!s && !r) return {}; r = s ? t : e; try { return JSON.parse(this.fs.readFileSync(r)) } catch (t) { return {} } } writedata() { var t, e, s, r, i; this.isNode() && (this.fs = this.fs || require("fs"), this.path = this.path || require("path"), t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), r = !(s = this.fs.existsSync(t)) && this.fs.existsSync(e), i = JSON.stringify(this.data), !s && r ? this.fs.writeFileSync(e, i) : this.fs.writeFileSync(t, i)) } lodash_get(t, e, s) { let r = t; for (const t of e.replace(/\[(\d+)\]/g, ".$1").split(".")) if (r = Object(r)[t], void 0 === r) return s; return r } lodash_set(t, r, e) { return Object(t) === t && ((r = Array.isArray(r) ? r : r.toString().match(/[^.[\]]+/g) || []).slice(0, -1).reduce((t, e, s) => Object(t[e]) === t[e] ? t[e] : t[e] = Math.abs(r[s + 1]) >> 0 == +r[s + 1] ? [] : {}, t)[r[r.length - 1]] = e), t } getdata(t) { let e = this.getval(t); if (/^@/.test(t)) { var [, s, r] = /^@(.*?)\.(.*?)$/.exec(t); if (s = s ? this.getval(s) : "") try { const t = JSON.parse(s); e = t ? this.lodash_get(t, r, "") : e } catch (t) { e = "" } } return e } setdata(t, e) { let s = !1; if (/^@/.test(e)) { var [, r, i] = /^@(.*?)\.(.*?)$/.exec(e), a = this.getval(r), a = r ? "null" === a ? null : a || "{}" : "{}"; tr
|