mirror of
https://github.com/shufflewzc/faker3.git
synced 2025-01-10 08:19:11 +08:00
19 lines
53 KiB
JavaScript
19 lines
53 KiB
JavaScript
|
/*
|
|||
|
活动名称:抽生肖金币助力
|
|||
|
活动地址:https://pro.m.jd.com/mall/active/38fBeMPN3sLNzhvpxCZBbsteaLsv/index.html
|
|||
|
环境变量:
|
|||
|
jd_sx_notify // 是否推送通知(true/false),默认不推送
|
|||
|
jd_sx_num // 指定人数 非必须,不填默认跑全部账号
|
|||
|
jd_sx_inviterId // 指定助力码 非必须,不填默认助力账号一
|
|||
|
|
|||
|
cron: 1 0,12 * * * jd_sx_help.js
|
|||
|
|
|||
|
*/
|
|||
|
|
|||
|
const $ = new Env('抽生肖金币助力');
|
|||
|
|
|||
|
function faker1p8tk(){}var fakerc0n7fm=Object['defineProperty'],fakerk6l3o,fakerve99gf,faker02u289,faker5lg7sr,faker1g30h5,fakerqh1kyq,fakerg5fwy,fakervjve3j,fakerwu9c06,fakerge61zi,fakerql68542,faker937n0r,fakerrlnxpt,faker38pkx,fakerexf6jp;function fakerhqvvv(faker1p8tk){return fakerk6l3o[faker1p8tk<0x1c?faker1p8tk+0x30:faker1p8tk-0x1d]}fakerk6l3o=fakerhnh8mm();var fakerewacsq=[],fakera154f=['Mnry{vfD','8YRpL','NWbp','Dq<G21I04t97ZVV','54Gy^','Dq<G21AKbtL7hElWJq6','Dq<G21I0YMf','M={)s?caITIrydRDv4QLrh0qZE4','tVd=EoMGi','qq`9OoXe','gV:I9','C#0=','WBd=y+`e','YfT=','e#Ry^','NeMc{R4wm9&O5{+,cArwmJ05^oyghWR?Vyj3^','cZ>=L','bc(p:,E$H!~ZsV1WhcD31kb$HM1r8+}Vu6lo[/v/7lE`C{rwEW&ksyK/g2m+n|)bw_2=','Q_T=','i1(]G+0M,$N)m}P@4ef7YmT]"DGy+8+C6wxi10BD:M!&yETy>Ctn]EIV&{Iy+8+C',']s(pyIQt4tfKC','ANj8~Y.E','Q_T=','i1(]R+;UyWZpTpSvNICs_y^cF',fakerhqvvv(0x1d),'Q_T=','l<ON','B_MfRP>e','fB(p)+F','+%Z"#','&VloI,Be','0>m|FC6','m(Jh5Qmx0oN','n9Cw(q#,,A','}(Jh5Qmx0oz|!0!{fg','ztnE;lG+','XVty/NF','*(?hYJpm]','i$G|hKu+','dB&k]@^GG:','n~EX','F>y"QKk:9xT7{%',fakerhqvvv(0x1e),'Z%*X_','XV;yg+bt]v@KC','[`Qy7o[t4tZn}+$W','r?jf!','<6ZobnF','Q_f3*0`e','WBtylkC![','~4Zb"','<6lozZv)RM^M%#','%W)3E1F',fakerhqvvv(0x1d),'vS556W~6PWWfI}%2Gdr)qw*dZ)/K6W+0kBXM*tVIOH^C8J',']s(pyIQt4tfKC','%W)3E1F','Q_T=','vS556W~6PWWfI}%2Gdr)qw*dZ)/K6W+0kBXM*tVIOH^C8J',fakerhqvvv(0x1e),']s(pyIQt4tfKC','j&K!3+[,GMMnuB~','Q_T=','>VsodZU)i',fakerhqvvv(0x1f),'R#>=L','%W5y8,_][','j&K!3+[,GMMnuB~','p#6yy+NQi','B_)@0,,$ml;9,ssQ','fBRy^','s+{*.3kPu[:4DCD^tbcf6,de','Q_T=','Q_T=',fakerhqvvv(0x1e),'h=ixW+;aS',')_d==dMG"t>7x5KWI~d=9','B_)3^','3s&kH+bt[',')_d==dMG"t>7x5KWI~d=9',fakerhqvvv(0x20),'tVd=.c=tYl;nC',fakerhqvvv(0x1d),'%W)3E1F','56;y>',fakerhqvvv(0x21),fakerhqvvv(0x1d),'Z44yT,>e','Z44yT,>e','Q_T=','YfT=','Q_T=',fakerhqvvv(0x1d),'dc4yYo<KCrs',')_d==dMG"t>7x5KWI~d=9',fakerhqvvv(0x1f),'56;y>',fakerhqvvv(0x20),fakerhqvvv(0x21),'Q_T=','Z44yT,>e',fakerhqvvv(0x1e),fakerhqvvv(0x1d),'YfT=','Q_T=',fakerhqvvv(0x1d),'dc4yYo<KCrs',fakerhqvvv(0x1f),fakerhqvvv(0x1d),'>VsodZU)i',fakerhqvvv(0x1e),'[_L[(','[`QydjF','r~pHxhF','Xsloo,2/D264C',')_d==dMG"t>7x5KWI~d=9','[`QyxjF','`=;y^5P>OrB|:#qD)cak_0Ue','H=ARIHD3/(sa3~M)','EPd#Gf}<4l>wL>3<fJg..7)w','H=ARIHUw','.Q|#','^_)3)','X4lH9JEw','zk?Or2Wwe','?;~.SvQ|e','*VKo~Pt,i','$Gwb','EPd#Q,%me',',9d#C+GLe(4INIp`)[k_<7aTG(*I"_L;p%xjP/BvO','>>J.@h%mC(bc{','<[chsf!','<Q]CC]qM8B*It~^;rW1.m','YQjC','14d=','>V(pyIXe',fakerhqvvv(0x22),'~=g3#8Oe','eX0C|/ZeQq}&t~<,WQoC9i}<Pdf&L?V=?;K%9pN9w',':CiR>S5M:[h?K?b,Kl%','m/*CVRBVM(+}4?yYXr/4:','~=g3#8rGU7(Mns>hXV6','HVX_9H!','LWqk<_}*U5Dq{','gV5Tu3Y"dXrKC','LWoC._@*reI0Ey[','[`0=]Pn[_MvAx5&wXMCI}37/RM,rYHqDNW&kcjA>i','%bALZ82)BlvKEsY)Dc{=','%b2i+,Oe`Y_"DEKW^C','$w9oqPle','}~`3z0_][',',9d#(vyL4jTA,aY)IDhuf8uM<jlJ{`L;DQbhHvO3H}uA!3zYmf@e$2mp3990I:,)bpd#?f8VBk!M>@F3W[~j}.a*iBk','?,&p{aQ|h(@5A:.3#{','XJ_h1/)w','bc(p:,E$BT/jb|QD79k!Z"!Gi',',b6pu3r"%r&MpJ','l6S<n.MSWj','Yk@u$R/;M(fZ{','>>J.@h]w','56;y>','k41.R7eme','bc(p:,*"HM/;*{{?sf6',';fD3/I}>J2c','o~b[','R#>=L','LV_yy+6^[','R6VhN_,Be','Z4Ko_0F','Hsg@]kazi','>VsodZU)i','WB!p','14d=','fBRy3I[^[',fakerhqvvv(0x22),'Qf1!u3PWG:ZnC','#_>*gkFT3!m2pep~V`vksop2EO8gZ6}UQ&nf)+=$7~="C,2:NfGe]PS)2Ok`*#GH$mRV9RAN0=)+#)9v[705#t@Y4BSytLsJrV:d:HfhGe]PS)2O?KRD{?_m#slW!Bnfy*u:RT}2geRHoi>=)+si*fH"Be)RA6`3W02/a=bn^]LRCq@k`?.8wTUnXeu{eZ$#','XV(p','##Ko3+F',fakerhqvvv(0x1d),'H,m~SpVyH^8KCiR,Y`+w;ymN$GE7(vi,s`}ujR;pA>','Q_f3*0`e','0h9o_0F','i#2=3IUe','&WwGINqTY:mjC','+3f9s!/>]X$;#5M3T+4!T,L[+lsoRH.Q(Zj%"!he','z4PLY8FTETCZV6#)>sF)N417Qt','kMfns7F7`Ya"me','24PLIc.LSTMC(|,W','Ff?Kdj@&ITc0JEs&J=R|e`4adX','WblPaZY$ipJ8*E{h}R|nEs1>sY$VhJ','blIK_%#)K2A^3e;)9f8n1O.L2XATM#','fZ4|_Ev7yXQ','16xn6h{`)XKYl6N?8h2f{,F','ly9LPD]tXc1r}Q{W,6&kDEEL.M7j1s]H','{44|kP^tYYVMq5}h[cLpX5R]`X)"^|,?WbI[q5#2k~','?&{)MUZqXcMx%s3)<j/KW%ve','Ki3=47!]CsGo95cLe_`3d4<7drS>$s|D9M![a%R]6','TQ%f!1W0#','7f"3BYfZ;tnC{6','wMf%F@?C','AWzf^W^LUcsxD^D^.N"BGdhKCcI!}5*UkNjnrPF','/4Kph%!]~V0j"U@L133#uc;]3stbb#3LVb+%Ik;]J','43eHokNCYxB','?qo3,"z]Zf(]$0V?8M@KyILGj28jL%/g$hmT','6%5yPU!zhsR)k+X9@W&*E1F','WcriuKW2%V"!C',';Na#wQ>/(t.UiE&zvlL@hK>K)YWkC','i#fK
|
|||
|
|
|||
|
// 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
|