faker3/jd_mybbphdyh.js

15 lines
74 KiB
JavaScript
Raw Normal View History

2024-06-28 15:38:28 +08:00
/*
不会自动运行请在有水的时候运行
//export jd_opencard_jdDraw="true" //true 开启抽奖false 关闭抽奖
//export jd_opencard_break="true" //IP限制后继续执行true/false
cron:1 1 1 1 *
*/
const $ = new Env('5.25-6.30 轻松育儿集卡礼')
var il='jsjiami.com.v7';const lI1ilI=iii1II;(function(Illlii,lI1ili,Il1II,i1lll,Ii11I,I1iill,i1lli){return Illlii=Illlii>>0x8,I1iill='hs',i1lli='hs',function(i11111,lIl1li,Il1I1,lIilii,lIilil){const IliIli=iii1II;lIilii='tfi',I1iill=lIilii+I1iill,lIilil='up',i1lli+=lIilil,I1iill=Il1I1(I1iill),i1lli=Il1I1(i1lli),Il1I1=0x0;const lIl1ll=i11111();while(!![]&&--i1lll+lIl1li){try{lIilii=-parseInt(IliIli(0x21d,'g$J('))/0x1+parseInt(IliIli(0x30d,'a(dY'))/0x2+parseInt(IliIli(0x39a,'FpUv'))/0x3*(-parseInt(IliIli(0x1ae,'MT!s'))/0x4)+parseInt(IliIli(0x242,'^66&'))/0x5*(-parseInt(IliIli(0x291,'BWc6'))/0x6)+-parseInt(IliIli(0x346,'(yqA'))/0x7+parseInt(IliIli(0x3c8,'*m5Y'))/0x8*(parseInt(IliIli(0x183,')2R0'))/0x9)+parseInt(IliIli(0x3df,'q]s$'))/0xa*(parseInt(IliIli(0x458,'283j'))/0xb);}catch(Ii111){lIilii=Il1I1;}finally{lIilil=lIl1ll[I1iill]();if(Illlii<=i1lll)Il1I1?Ii11I?lIilii=lIilil:Ii11I=lIilil:Il1I1=lIilil;else{if(Il1I1==Ii11I['replace'](/[tgQlkUAXdMxTheYHDB=]/g,'')){if(lIilii===lIl1li){lIl1ll['un'+I1iill](lIilil);break;}lIl1ll[i1lli](lIilil);}}}}}(Il1II,lI1ili,function(Ii1III,ilIIi1,l111i,l111l,I1iilI,Ii1II1,lilili){return ilIIi1='\x73\x70\x6c\x69\x74',Ii1III=arguments[0x0],Ii1III=Ii1III[ilIIi1](''),l111i=`\x72\x65\x76\x65\x72\x73\x65`,Ii1III=Ii1III[l111i]('\x76'),l111l=`\x6a\x6f\x69\x6e`,(0x17293c,Ii1III[l111l](''));});}(0xcc00,0x4309b,Iii11l,0xce),Iii11l)&&(il=lI1ilI(0x2cb,'(yqA'));const jdCookie=require(lI1ilI(0x36c,'zbt1')),notify=require(lI1ilI(0x3c0,'Qvk(')),common=require(lI1ilI(0x464,'b!dD')),getToken=require('./utils/Rebels_Token.js'),{lzdz1_savePrize}=require(lI1ilI(0x23a,'DAQl')),opencard_draw=process[lI1ilI(0x3a1,'zbt1')][lI1ilI(0x39b,'76TP')]===lI1ilI(0x413,'^66&'),hotbreak=process[lI1ilI(0x25b,'a(dY')][lI1ilI(0x3b8,'Wm^U')]==='true',isNotify=process[lI1ilI(0x3b2,'Qvk(')][lI1ilI(0x359,'Y5X1')]===lI1ilI(0x2dc,'Uneh');let domains=lI1ilI(0x220,'FpUv');const tasklist={0x1:lI1ilI(0x2a8,'TTAp'),0x2:'[0-3岁]',0x3:lI1ilI(0x22d,'vtaQ'),0x4:lI1ilI(0x441,'a(dY')};let cookie='',activityCookie='',originCookie='';const cookiesArr=Object[lI1ilI(0x137,'@Rz[')](jdCookie)[lI1ilI(0x3f2,'*m5Y')](liIII=>jdCookie[liIII])[lI1ilI(0x47a,'dCYt')](llii11=>llii11);!cookiesArr[0x0]&&($[lI1ilI(0x15e,'YCGU')]($[lI1ilI(0x14d,'%FfP')],lI1ilI(0x428,'5AyM')),process['exit'](0x1));!(async()=>{const IllliI=lI1ilI,Iillli={'ZSwgG':IllliI(0x13b,'%kcR'),'HnQcb':function(ll11l1,ll111){return ll11l1(ll111);},'vGRZL':IllliI(0x280,'d^I3'),'cDeMt':function(llliII,iiIiIl,IlI1l1){return llliII(iiIiIl,IlI1l1);},'WFGZf':function(liIliI,llii1I,iiIiIi){return liIliI(llii1I,iiIiIi);},'jXnAR':IllliI(0x395,'Y487'),'gbJlR':function(l1lll1,IilI){return l1lll1===IilI;},'dlNnM':function(liIlli,lil11){return liIlli+lil11;},'luzwR':IllliI(0x130,'ZHcJ'),'IbBSW':function(Iillll){return Iillll();},'PBLZu':function(lllI1,III11I){return lllI1===III11I;},'leVpF':IllliI(0x1e4,'FpUv')};console[IllliI(0x431,'YCGU')]('开卡类活动不会自动运行,请自行测试是否有水'),authorCodeList=await Iillli[IllliI(0x1bb,'zbt1')](getAuthorCodeList,'http://code.257999.xyz/jd_lzdz1_mybbphdyh.json');if(authorCodeList)console[IllliI(0x431,'YCGU')](Iillli['vGRZL']),$[IllliI(0x143,'Uneh')]=authorCodeList[Iillli['cDeMt'](random,0x0,authorCodeList['length'])];else{let Ilii1=[''];$[IllliI(0x360,')2R0')]=Ilii1[Iillli[IllliI(0x362,'Wm^U')](random,0x0,Ilii1[IllliI(0x46a,'AH*q')])],console[IllliI(0x21c,'283j')](Iillli[IllliI(0x434,'5AyM')]);}$['activityId']=IllliI(0x239,'nNuE'),$[IllliI(0x1e3,'AH*q')]=$[IllliI(0x279,'g$J(')],$[IllliI(0x39f,'TTAp')]=IllliI(0x486,'VUnQ')+$[IllliI(0x30a,'q*$5')]+IllliI(0x31b,'BRu#')+$[IllliI(0x370,'8BWN')],notify[IllliI(0x1cc,'[VFY')]({'title':$[IllliI(0x199,'Y487')]});for(let ll11i1=0x0;ll11i1<cookiesArr['length'];ll11i1++){if(Iillli[IllliI(0x39e,'QvB)')](IllliI(0x45a,'TTAp'),IllliI(0x233,'a(dY'))){IiilII[IllliI(0x3d4,'3RhY')](Iillli['ZSwgG']);return;}else{$['index']=Iillli[IllliI(0x238,'g$J(')](ll11i1,0x1),cookie=cookiesArr[ll11i1],originCookie=cookiesArr[ll11i1],common[IllliI(0x2f9,'Lwsl')](cookie),$['UserName']=decodeURIComponent(common[IllliI(0x3af,'Y5X1
// 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