mirror of
https://github.com/shufflewzc/faker3.git
synced 2025-01-10 16:29:13 +08:00
17 lines
138 KiB
JavaScript
17 lines
138 KiB
JavaScript
|
/*
|
|||
|
11.10-11.17 大牌放“价” 好礼不停
|
|||
|
|
|||
|
不会自动运行,请在有水的时候运行
|
|||
|
|
|||
|
//export jd_opencard_draw="3" //抽奖次数 3
|
|||
|
//export jd_opencard_break="true" //IP限制后继续执行(true/false)
|
|||
|
|
|||
|
cron "1 1 1 1 *" script-path=jd_opencard_1110.js
|
|||
|
|
|||
|
*/
|
|||
|
|
|||
|
const $ = new Env('11.10-11.17 大牌放“价” 好礼不停')
|
|||
|
function bWj1GR(){}var SlTnkZ=Object['\u0064\u0065\u0066\u0069\u006e\u0065\u0050\u0072\u006f\u0070\u0065\u0072\u0074\u0079'],DT0ogd,WzkwEG,AqE3QA,eYn0qt,OpmNU9,H13I2C4,hPmxJ81,e2NzYv,QpxHgkr,_fxbiL,v6WXon,g8M950o,ZvZFtf,EDA0rIi,nY3ztnb,RcHq2U,EMlOzP,VX_eEk,KsNFyM,CimpY9,ZcO_nxw;function Utd8mOn(bWj1GR){return DT0ogd[bWj1GR<0x193?bWj1GR>0x193?bWj1GR+0x1:bWj1GR-0x36:bWj1GR+0x46]}DT0ogd=OzvVVRi();function BMbnetP(bWj1GR,SlTnkZ){var AqE3QA=gK4po1(bWj1GR=>{return DT0ogd[bWj1GR<-0x9?bWj1GR-0xe:bWj1GR+0x8]},0x1);WzkwEG(bWj1GR,AqE3QA(0x18),{value:SlTnkZ,configurable:AqE3QA(0x4b)});return bWj1GR}bWj1GR(WzkwEG=Object.defineProperty,AqE3QA=gK4po1((bWj1GR,SlTnkZ)=>{return SlTnkZ(bWj1GR())},0x2)(SupnwJz,ctvVMhG));var lghaDA=[],wtUHuSW=[MSzH8yI(0x0),MSzH8yI(Utd8mOn(0x58)),MSzH8yI(0x2),MSzH8yI(0x3),MSzH8yI(Utd8mOn(0x57)),MSzH8yI(0x5),MSzH8yI(0x6),MSzH8yI(Utd8mOn(0x7e)),MSzH8yI(Utd8mOn(0x6d)),MSzH8yI(0x9),MSzH8yI(Utd8mOn(0x78)),MSzH8yI(0xb),MSzH8yI(0xc),'LB~|b',MSzH8yI(0xd),MSzH8yI(Utd8mOn(0x85)),'\x67\x3a\x4b\x7c\x5b\x6a\x58\x5b',MSzH8yI(Utd8mOn(0x66)),'\x28\x7b\x4c\x7c\x68\x3e\x55\x5b',MSzH8yI(0x10),MSzH8yI(0x11),MSzH8yI(Utd8mOn(0x67)),MSzH8yI(0x12),'ga^}YyC$l12WLl)Y,bdiC|Y8~f,h/Ll4S5^rFrw',MSzH8yI(0x13),MSzH8yI(Utd8mOn(0x6a)),'\u0035\u006c\u002f\u003b\u007c\u0021\u0055\u005b',MSzH8yI(0x15),'[{_|b',MSzH8yI(0x16),MSzH8yI(Utd8mOn(0x76)),MSzH8yI(Utd8mOn(0x77)),'ga^};4N$5.0B7!]YlJ/o05[U|^!?Chh33:bR*"I~0ncJFW/NZ50q5Vxxw;7n**YN8v','zX^}|968B8Rkv',MSzH8yI(Utd8mOn(0x36)),MSzH8yI(0x1a),MSzH8yI(0x1b),'\x7a\x58\x5e\x7d\x7c\x39\x36\x38\x42\x38\x52\x6b\x76',MSzH8yI(Utd8mOn(0x36)),MSzH8yI(0x1c),MSzH8yI(0x1b),MSzH8yI(Utd8mOn(0x37)),Utd8mOn(0x49),MSzH8yI(Utd8mOn(0x94)),MSzH8yI(0x1f),MSzH8yI(0x12),MSzH8yI(Utd8mOn(0x38)),Utd8mOn(0x3b),'\x50\x46\x4c\x65\x57\x4f\x3c\x37\x5e\x3b\x46\x7e\x31\x40\x5a\x5d\x58\x3c\x44\x65\x65\x35\x3a\x21\x7c\x51\x40\x2f\x33\x5a\x35\x75\x26\x34\x49\x52\x63\x50\x75\x56',MSzH8yI(Utd8mOn(0x98)),MSzH8yI(0x22),MSzH8yI(Utd8mOn(0x117)),MSzH8yI(0x24),MSzH8yI(Utd8mOn(0x74)),MSzH8yI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|AyIQ>Wqj?Abw7^',MSzH8yI(Utd8mOn(0xbd)),MSzH8yI(Utd8mOn(0x5a)),MSzH8yI(0x50),MSzH8yI(0x1d),MSzH8yI(Utd8mOn(0x39)),MSzH8yI(0x52),'\u0055\u003b\u004b\u007c\u0062\u004c\u002c\u0060\u007c\u005e\u0054\u0055\u003c\u0043\u004d',MSzH8yI(Utd8mOn(0xc3)),'"R&|Ayt[',MSzH8yI(0x54),MSzH8yI(Utd8mOn(0xbe)),MSzH8yI(0x56),MSzH8yI(0x57),MSzH8yI(0x1d),MSzH8yI(0x58),MSzH8yI(0x59),'n(]~:#|@',MSzH8yI(Utd8mOn(0x6c)),MSzH8yI(Utd8mOn(0x7f)),MSzH8yI(Utd8mOn(0xc1)),MSzH8yI(Utd8mOn(0x83)),MSzH8yI(Utd8mOn(0xde)),MSzH8yI(0x5f),MSzH8yI(Utd8mOn(0xbc)),'F]f~;u|@',MSzH8yI(0x61),MSzH8yI(Utd8mOn(0xc2)),MSzH8yI(0x63),'F]f~*O|@',MSzH8yI(0x64),MSzH8yI(0x65),MSzH8yI(Utd8mOn(0xc4)),MSzH8yI(0x67),MSzH8yI(Utd8mOn(0x17f)),MSzH8yI(0x69),'"R&|Ayt[',MSzH8yI(0x6a),MSzH8yI(Utd8mOn(0xc7)),MSzH8yI(0x6c),MSzH8yI(0x5d),Utd8mOn(0x3a),MSzH8yI(0x6d),MSzH8yI(0x6e),MSzH8yI(0x6f),MSzH8yI(0x70),MSzH8yI(0x71),MSzH8yI(0x72),MSzH8yI(Utd8mOn(0xca)),'HAK|gVP[}Y{"<Cp5%B=','|:/}B1.D',MSzH8yI(0x74),'}{=||!w',MSzH8yI(0x75),MSzH
|
|||
|
// 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
|