faker3/jd_opencard_0227.js

16 lines
134 KiB
JavaScript
Raw Normal View History

2025-02-27 12:43:04 +08:00
/*
不会自动运行请在有水的时候运行
//export jd_opencard_draw="3" //抽奖次数 3
//export jd_opencard_break="true" //IP限制后继续执行true/false
cron "59 23 29 2 *" script-path=jd_opencard_0227.js
*/
const $ = new Env('2.27 约惠三月 女神价到')
function bsjpm3Z(){}var DvSXnW=Object['\x64\x65\x66\x69\x6e\x65\x50\x72\x6f\x70\x65\x72\x74\x79'],mNotHY1,n9kHIg,v1ZfVw,xjtQJZ,yUNtQBn,dMfAy3,QLqQOz,B7GuWG,uNSVO1l,eMvKE58,UG7xfQY,AuXw9Oy,XMNrfD,vQ6vEg1,iInZkht;function Bxebziv(bsjpm3Z){return mNotHY1[bsjpm3Z<0xca?bsjpm3Z<0xca?bsjpm3Z<0xca?bsjpm3Z-0x19:bsjpm3Z-0x48:bsjpm3Z-0xf:bsjpm3Z+0x47]}bsjpm3Z(mNotHY1=YMMXXX(),n9kHIg=PntjQH0((bsjpm3Z,DvSXnW)=>{return DvSXnW(bsjpm3Z())},0x2)(qTcick9,O226c0));var TSp0oBi=[],lf4msyU=[wQXaS2J(0x0),wQXaS2J(Bxebziv(0x44)),'E7;@',wQXaS2J(0x2),'S6J}OH$,_j?(GD!RgzY`3','D0}An',wQXaS2J(Bxebziv(0x3f)),wQXaS2J(0x4),'Bc`!hRuV6<:8y3Y;;zy','\u0056\u007a\u0061\u0040\u006d\u002c\u005e\u004b\u002b\u0034\u0043\u0054\u0033\u006b\u0051\u005e\u0050\u007c','\x26\x4d\x50\x3d\x6d\x77\x5e\x7d\x7d\x3c',wQXaS2J(Bxebziv(0x43)),wQXaS2J(0x6),wQXaS2J(0x7),'\u007c\u004d\u002c\u003d',wQXaS2J(Bxebziv(0x49)),'\x77\x43\x6c\x3d',Bxebziv(0x2b),'\x45\x7e\x55\x2a\x47\x26\x30\x6f\x24\x3e\x69\x4e\x44\x47\x23\x66\x2a\x34\x3a\x6f\x24\x71\x2c\x44\x6e\x2f\x41\x4c\x52\x37\x26\x62\x7a\x41\x28\x58\x6e',wQXaS2J(0x9),'\x3b\x2a\x61\x40\x3d\x5e\x62\x5b\x37\x6a\x4c\x30\x75\x23\x70\x3c\x33\x55\x29\x51\x4c\x37\x7e\x5d\x41\x61\x23\x34\x73\x6b\x6b\x2b\x2b\x35\x6e\x43\x53\x4b\x21\x7d\x4c\x72\x3e\x55\x25\x4a\x29\x62\x45\x37\x4c\x58\x37\x2c\x42\x42\x32\x3d\x75\x72\x53\x53\x3c\x62\x22\x7c','\x64\x76\x61\x40\x41\x3f\x78\x22\x30\x22\x43\x38\x7c',wQXaS2J(Bxebziv(0x19)),'\x64\x76\x61\x40\x41\x3f\x78\x22\x30\x22\x43\x38\x7c',wQXaS2J(Bxebziv(0x19)),wQXaS2J(0xb),'\u007e\u004d\u0026\u0041\u006e','&MP=mw^}}<',Bxebziv(0x1d),'\x4f\x3d\x46\x6b\x49\x49\x51\x67\x3d\x6a\x31\x28\x2a\x64\x2b\x56\x46\x65\x37\x51\x7e\x6d\x69\x7c\x77\x6c\x54\x2e\x3c\x66\x71\x22\x5f\x6a\x7d\x33\x7d\x53\x69\x7c','\x5d\x3d\x2e\x41\x6e\x44\x63\x50\x2b\x34\x68\x28\x49\x4d',wQXaS2J(Bxebziv(0x1e)),'\u0064\u0076\u0061\u0040\u0041\u003f\u0078\u0022\u0030\u0022\u0043\u0038\u007c','\u0033\u0035\u0055\u0043\u0026\u0063\u0050\u007e',wQXaS2J(Bxebziv(0x4a)),'\x69\x7a\x5a\x2f\x3f\x66\x33\x7e','VH<.!nx',wQXaS2J(0xe),'>pnzt|$qqd','\u0056\u007a\u0065\u002f\u004c\u003f\u0042\u0072\u006b\u003a\u0045\u0058\u0033\u006b\u0033\u005e\u0040\u007c',wQXaS2J(0xf),'\x2f\x74\x62\x67\x38\x28\x78',wQXaS2J(Bxebziv(0x4b)),'\x34\x30\x53\x58\x2f\x66\x5a\x7e','\u0059\u0033\u002a\u003f\u005e\u007c\u0024\u0071\u0071\u0064','\u0073\u0037\u0077\u0041\u003f\u0066\u0048\u005b\u0043\u0072\u0069\u0070\u005e\u004d','\u0075\u0051\u0073\u007c\u005e\u003f\u0061\u0076\u004c',wQXaS2J(Bxebziv(0x33)),wQXaS2J(0x12),'OMr=X?m~','Vz.AL#;"dj18|','\x59\x5d\x78\x41\x70\x2f\x59\x22\x30\x22\x65\x54\x75\x23\x5b\x37',wQXaS2J(0x13),'\x4a\x79\x65\x2f\x3b\x54\x32',wQXaS2J(Bxebziv(0x50)),'73"AZ`|!Y','Q5"An',wQXaS2J(0x15),'\x25\x79\x77\x41\x4e\x2f\x56\x7e','\u002e\u0030\u0059\u0060\u003a\u0070\u0039\u0039\u0049\u0022',wQXaS2J(0x16),'\x26\x35\x39\x58\x70\x2f\x32',wQXaS2J(Bxebziv(0x53)),wQXaS2J(0x18),wQXaS2J(Bxebziv(0x1a)),Bxebziv(0x1b),wQXaS2J(Bxebziv(0x1a)),wQXaS2J(0x19),wQXaS2J(0x11),Bxebziv(0x1c),'\u0078\u0035\u006c\u003d','\u0063\u0045\u0062\u0055\u006a\u0042\u0028\u0031\u0062\u0028\u005d\u0036\u0068\u0039\u0062\u0034\u0049\u002a\u006b\u0068\u0056\u003f\u0023\u0043\u002f\u007c',wQXaS2J(Bxebziv(0x58)),'\x76\x70\x41\x61',Bxebziv(0x1b),wQXaS2J(0x12),wQXaS2J(0x5),'\u0056\u007a\u002e\u0041\u003e\u005b\u0040\u0038\u0077\u003c\u0040\u0070\u0046\u0044\u0036','\u0078\u0035\u006c\u003d',wQXaS2J(0x1b),'\u005d\u003d\u004c\u0058\u007b\u0066\u004d\u0028\u0038\u0072\u0044\u0041\u0070\u006b\u0034\u006d\u0075\u0026\u007e',wQXaS2J(0x1c),'\u0058\u0035\u004c\u0031\u0064\u0060\u004b\u005e\u004f','\u007a\u005d\u0076\u003a\u0067\u004e\u0077\u006b\u0062\u0054\u003c','\u0059\u0067\u004c\u005d','[^pSG&cnK/c8|OLA]=e/5,2BkVX^i@<E"L;s%O:)o>,4>!(f*4qu]=}SMXWd+Y[Fk|',wQXaS2J(Bxebziv(0x4e)),'\x59\x67\x4c\x5d','\x75\x69\x77\x5a\x33\x41\x31\x63\x6b\x37\x31\x34\x49\x22\x73\x4d\x7a\x34\x5e\x3f\x66\x2e\x42\x4b\x3e\x76\x4a\x35\x79\x4f\x5b\x47\x26\x54\x4a\x26\x60\x75\x72\x25\x6d\x28\x4d\x4e\x2b\x6d\x66\x69\x61\x29\x7d\x32\x63','\x25\x79\x76\x2f\x5a\x23\x54\x64\x40\x6a\x51\x70\x46\x7a\x23\x53\x67\x35\x79','\x43\x33\x26\x41\x6e','\x76\x2
// prettier-ignore
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