faker3/jd_car_sign.js

15 lines
78 KiB
JavaScript
Raw Normal View History

2024-11-12 11:17:55 +08:00
/*
活动名称车管家签到
环境变量jd_car_sign_interval // 自定义运行间隔时长整数单位毫秒默认1500
jd_car_sign_notify // 是否推送通知true/false默认不推送
jd_car_sign_pinFilter // 账号pin过滤多个用@进行分割
定时随机
*/
const $ = new Env('车管家签到')
function svH9Or(){}var ZDTRafz=Object['defineProperty'],DcYYUq,PZzH9G,Edn0vFm,KkzmbW,IW1A0Y,pDw9Ly,iWxpBg,fZLefN,CGqKyV,Qtf8cg,AfHwPgZ,pvw6lr,bmyWOKf,DAm8Hg,OS_skg,ypXOxu,Oc5ymZW,pSDkp9S,Azy2E4,E8zZWhJ;function QYvvpC(svH9Or){return DcYYUq[svH9Or<0x3b?svH9Or>0x3b?svH9Or-0x2c:svH9Or>0x3b?svH9Or+0x3d:svH9Or+0x4f:svH9Or-0x5a]}DcYYUq=IUKgsP();function Plj2r4(svH9Or,ZDTRafz){var Edn0vFm=HOe0qly(svH9Or=>{return DcYYUq[svH9Or<-0x5a?svH9Or-0x2f:svH9Or>0x31?svH9Or-0xe:svH9Or>-0x5a?svH9Or+0x59:svH9Or+0x40]},0x1);return PZzH9G.call(Edn0vFm(-0x19),svH9Or,Edn0vFm(-0x4b),{value:ZDTRafz,configurable:!0x0})}svH9Or(PZzH9G=Object.defineProperty,Edn0vFm=HOe0qly((svH9Or,ZDTRafz)=>{return ZDTRafz(svH9Or())},0x2)(d1WK0oD,OntuJn));var fM2RRpS=[],pfFxjY=[epkQ05(0x0),epkQ05(QYvvpC(-0x4a)),epkQ05(0x2),'\u0032\u002f\u007c\u0035\u0064\u0042\u005e\u0071',epkQ05(QYvvpC(-0x42)),'2/|5dBb_E)N"v',epkQ05(0x4),epkQ05(QYvvpC(-0x37)),epkQ05(0x6),epkQ05(QYvvpC(-0x3d)),epkQ05(0x8),epkQ05(0x9),epkQ05(0xa),epkQ05(0xb),'ghG*<uGws4J&!1|j<}k@F+K',epkQ05(0xc),'|s4@A{Fd',epkQ05(0xd),epkQ05(0xe),epkQ05(0xf),epkQ05(0x10),epkQ05(0x11),epkQ05(QYvvpC(-0x43)),epkQ05(QYvvpC(0x2b)),epkQ05(QYvvpC(-0x4f)),'~d4}cC#T7Qq|1c?_}$;T7i`1k]fNFHCJlf,Mk',epkQ05(QYvvpC(-0x1d)),epkQ05(QYvvpC(-0x11)),epkQ05(0x17),epkQ05(0x18),epkQ05(0x19),epkQ05(0x1a),epkQ05(0x1b),epkQ05(0x1c),epkQ05(0x1d),epkQ05(0x1e),epkQ05(0x1f),epkQ05(0x20),epkQ05(0x21),epkQ05(0x22),'}*WDV.N5FH9IjVJ90:4h]q$"^s2z{#Z_|;YS4<`19/By)LaxOE:GS',epkQ05(0x23),epkQ05(0x22),epkQ05(QYvvpC(-0x4f)),epkQ05(QYvvpC(-0x2a)),epkQ05(0x25),epkQ05(QYvvpC(-0xe)),'R2bf|]Ld',epkQ05(0x27),epkQ05(0x28),epkQ05(0x29),epkQ05(0x2a),epkQ05(0x2b),epkQ05(0x2c),epkQ05(0x28),epkQ05(0x29),epkQ05(QYvvpC(-0x10)),epkQ05(0x2b),epkQ05(0x2d),epkQ05(QYvvpC(-0x24)),epkQ05(QYvvpC(-0x18)),epkQ05(0x22),epkQ05(QYvvpC(-0x15)),epkQ05(0x31),epkQ05(0x32),epkQ05(0x33),epkQ05(QYvvpC(-0xc)),epkQ05(0x35),epkQ05(0x36),epkQ05(0x37),epkQ05(0x2c),epkQ05(0x38),epkQ05(QYvvpC(-0xa)),epkQ05(QYvvpC(-0x1)),epkQ05(0x22),epkQ05(0x3b),epkQ05(QYvvpC(0xc)),epkQ05(QYvvpC(-0x8)),epkQ05(0x23),epkQ05(QYvvpC(-0x4e)),epkQ05(QYvvpC(-0x44)),epkQ05(0x40),epkQ05(QYvvpC(-0x4d)),epkQ05(0x38),epkQ05(0x42),epkQ05(QYvvpC(-0x12)),epkQ05(QYvvpC(-0x4e)),epkQ05(QYvvpC(0x1)),epkQ05(0x44),epkQ05(0x45),'GAiWX`"*"bQzI%|ajS>n$%gd',epkQ05(0x46),epkQ05(QYvvpC(0x2)),epkQ05(0x48),epkQ05(QYvvpC(-0x4c)),epkQ05(0x4a),epkQ05(QYvvpC(-0x4d)),epkQ05(0x4b),epkQ05(0x4c),epkQ05(QYvvpC(0x3)),'oH5fr`|d',epkQ05(QYvvpC(-0x29)),epkQ05(0x4f),epkQ05(0x41),epkQ05(0x50),epkQ05(QYvvpC(-0x7)),epkQ05(0x50),epkQ05(QYvvpC(-0x4d)),'H#G|o',epkQ05(0x41),'SAJ+6|rxz',epkQ05(0x52),epkQ05(0x53),epkQ05(0x54),epkQ05(0x55),epkQ05(0x56),epkQ05(0x57),epkQ05(0x58),epkQ05(0x59),epkQ05(0x5a),epkQ05(QYvvpC(-0x30)),epkQ05(0x5c),'M]|Y.)U@',epkQ05(QYvvpC(0x12)),epkQ05(QYvvpC(0x8)),epkQ05(QYvvpC(-0x3a)),epkQ05(0x60),epkQ05(QYvvpC(0x7)),epkQ05(QYvvpC(0x5)),epkQ05(0x63),epkQ05(0x64),epkQ05(0x65),epkQ05(QYvvpC(0x9)),epkQ05(QYvvpC(0xd)),epkQ05(0x68),epkQ05(0x69),'\u003f\u007e\u0078\u007c','\u0057\u0023\u005e\u007c',epkQ05(QYvvpC(0xe)),epkQ05(0x6b),epkQ05(QYvvpC(-0x5)),epkQ05(0x6d),epkQ05(0x6e),'R{.|@a<B',epkQ05(QYvvpC(0x29)),epkQ05(0x70),'\x2e\x74\x3b\x49\x45\x59\x70\x2e\x31\x2c\x6b\x5f\x73\x33\x59\x47\x28\x73\x6c\x46\x3f\x2f\x60\x77\x3c\x6a\x47\x3b\x7c\x54',epkQ05(0x71),epkQ05(0x72),epkQ05(QYvvpC(-0x2d)),epkQ05(0x74),epkQ05(0x75),'(|fID52B',epkQ05(QYvvpC(0x1a)),epkQ05(0x77),epkQ05(QYvvpC(-0x4c)),epkQ05(QYvvpC(-0x35)),epkQ05(0x79),epkQ05(QYvvpC(0x1c)),epkQ05(QYvvpC(0x30)),epkQ05(0x7c),epkQ05(0x7d),epkQ05(0x7e),epkQ05(0x7f),epkQ05(0x80),epkQ05(QYvvpC(-0x13)),'6F.#|#wu9LX>(0Mng{HPt=vb?t',epkQ05(0x82),'"B0|]0czEtT5u5(UTqd',epkQ05(0x83),epkQ05(QYvvpC(0xf)),'#9Y&Z|&ZA',epkQ05(QYvvpC(0x16)),epkQ05(0x86),epkQ05(0x87),epkQ05(0x88),epkQ05(0x89),epkQ05(QYvvpC(0x22)),epkQ05(0x8b),'<O@Z[gPm|@#$xlOtcP+{S(K',epkQ05(0x8c),'m?[Bx;8;|2|VU|rb0AXWj',epkQ05(0x8d),'0Ay.gvJU$P@VSgpb1F|%g.`hpt%3sI>g)K',epkQ05(0x8e),epkQ05(0x8f),'B2tW06Jmp43D*,[U|B8]U*PZGhd%WD,L]OM>c',epkQ05(0x90),'\u006a\u0071\u0029\u006e\u0029\u0078\u0059\u0052\u003b\u003b\u0024\u0035\u0048\u0041\u0031\u0072\u0063\u00
// 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