KR/jd_fcwb_auto.js

38 lines
91 KiB
JavaScript
Raw Normal View History

2023-12-05 17:20:15 +08:00
/*
欢乐淘金发财挖宝
入口APP 玩一玩 欢乐淘金
地址
https://bnzf.jd.com/?activityId=Bn1VWXtvgTv5ewPoMR-X8A // app默认入口
请先运行助力任务脚本 jd_fcwb_help.js
全部通关需下2单推荐助力满后领取奖励
环境变量
JD_FCWB_ID 指定活动ID 不指定默认 APP入口 格式Bn1VWXtvgTv5ewPoMR-X8A
JD_FCWB_ROUND 指定剩余血量 非必须不填默认剩余 1 退出
2023-12-05 18:30:59 +08:00
JD_FCWB_TXNUM 轮询提现页数 默认查询第一页一般无需填写
2023-12-05 17:20:15 +08:00
JD_FCWB_EXCHANGE 达到剩余血量是否领取奖励默认不启用领取奖励后相当于结束当天活动无法继续挖宝请自行对应设置
JD_FCWB_SWISH 是否延长提现时间默认不延长true/false
代理变量
本地IP理论正常助力也无需开启代理
JD_FCWB_PROXY_OPEN 代理启用变量默认不开启true/false
JD_FCWB_PROXY_TUNNRL 代理池代理地址变量默认不开启仅支持代理池模式(auto-proxy-pool)格式为http://ip:port
JD_FCWB_PROXY_URL API代理地址变量默认不开启仅支持 数据格式:txt;提取数量:每次一个格式为http://api.xxx.xxx
JD_FCWB_NO_PROXY 禁止走代理默认 127.0.0.1,*.baidu.com 需要自行修改
cron:1 1 1 1 *
============Quantumultx===============
[task_local]
#欢乐淘金发财挖宝任务
1 1 1 1 * jd_fcwb_auto.js, tag=欢乐淘金发财挖宝任务, enabled=true
*/
const $ = new Env('欢乐淘金(发财挖宝)任务')
2023-12-26 03:15:42 +08:00
var il='jsjiami.com.v7';const iiI1=iii1II;(function(l1IIi,l1IIl,l1I1il,III1ii,l1I1ii,III1il,I1IlI1){return l1IIi=l1IIi>>0x1,III1il='hs',I1IlI1='hs',function(i1111,iIIlII,IlIi1l,IiIiiI,IlIi1i){const illl11=iii1II;IiIiiI='tfi',III1il=IiIiiI+III1il,IlIi1i='up',I1IlI1+=IlIi1i,III1il=IlIi1l(III1il),I1IlI1=IlIi1l(I1IlI1),IlIi1l=0x0;const lIllii=i1111();while(!![]&&--III1ii+iIIlII){try{IiIiiI=-parseInt(illl11(0x1ad,'YAOY'))/0x1+-parseInt(illl11(0x1d4,'jbX2'))/0x2*(parseInt(illl11(0x586,'tb@8'))/0x3)+parseInt(illl11(0x28d,'nS3L'))/0x4*(parseInt(illl11(0x344,'neIS'))/0x5)+parseInt(illl11(0x351,'M!o&'))/0x6*(parseInt(illl11(0x1bf,'6XDd'))/0x7)+parseInt(illl11(0x334,'FlZ7'))/0x8+parseInt(illl11(0x476,'8!XV'))/0x9*(-parseInt(illl11(0x2be,'Jok#'))/0xa)+parseInt(illl11(0x271,'WOg2'))/0xb;}catch(l1il1){IiIiiI=IlIi1l;}finally{IlIi1i=lIllii[III1il]();if(l1IIi<=III1ii)IlIi1l?l1I1ii?IiIiiI=IlIi1i:l1I1ii=IlIi1i:IlIi1l=IlIi1i;else{if(IlIi1l==l1I1ii['replace'](/[UeBtGwHXkJITRWOMVxCFA=]/g,'')){if(IiIiiI===iIIlII){lIllii['un'+III1il](IlIi1i);break;}lIllii[I1IlI1](IlIi1i);}}}}}(l1I1il,l1IIl,function(IIiI,l1iil1,iiiIiI,Ill1i1,illl1I,lillI,Il11i){return l1iil1='\x73\x70\x6c\x69\x74',IIiI=arguments[0x0],IIiI=IIiI[l1iil1](''),iiiIiI=`\x72\x65\x76\x65\x72\x73\x65`,IIiI=IIiI[iiiIiI]('\x76'),Ill1i1=`\x6a\x6f\x69\x6e`,(0x14d504,IIiI[Ill1i1](''));});}(0x194,0x8b59c,Iii11l,0xcc),Iii11l)&&(il=0x395a);const I1iII=require(iiI1(0x31e,'nS3L')),IIlI1i=require(iiI1(0x559,'wTcj')),iiiI1i=require('./function/jdCommon'),iiiI1l=require(iiI1(0x3e5,'dvCb')),Ili1Ii=process[iiI1(0x4db,'QoD!')][iiI1(0x4e4,'HfOc')]||'1',Ii1l1I=process[iiI1(0x479,'64Vw')][iiI1(0x4b7,'4QtG')]||'Bn1VWXtvgTv5ewPoMR-X8A',iilII1=process[iiI1(0x47e,'wTcj')][iiI1(0x1e1,'Jok#')]?process[iiI1(0x27e,'jaXb')]['JD_FCWB_TXNUM']:'1',iiiI11=process[iiI1(0x45f,'hD5m')][iiI1(0x2cf,'WOg2')]===iiI1(0x432,'I64D'),l1lilI=process[iiI1(0x387,'M!o&')][iiI1(0x268,'6XDd')]===iiI1(0x3aa,'YAOY'),i1Iil1=process[iiI1(0x243,'rbPB')]['JD_FCWB_TXMAX_RETRY']||'3',liI1Ii=process[iiI1(0x332,'Q8bB')][iiI1(0x246,'RgT]')]===iiI1(0x3aa,'YAOY'),l1lil1=process[iiI1(0x392,'FlZ7')][iiI1(0x3c3,'2AH6')],i1lil=process[iiI1(0x319,'6XDd')][iiI1(0x376,'ScPJ')],I1iIl=process[iiI1(0x27e,'jaXb')][iiI1(0x49b,'aa4j')]||iiI1(0x33b,'XtIx'),IilII=process[iiI1(0x588,'lGbt')][iiI1(0x404,')Wy$')]===iiI1(0x568,'WOg2'),ili1l={'cNAsHasSnzWTAtWhIQR4dA':{0x1:0x6,0x2:0xf,0x3:0x10},'Bn1VWXtvgTv5ewPoMR-X8A':{0x1:0x5,0x2:0xf,0x3:0x11}};let i1lii=0x3e8;liI1Ii&&(l1lil1||i1lil)&&(i1lii=0x64);let iilIII='',liI1Il=0x0,I1iIi=![];if(liI1Ii){I1iIi=!![];try{require(iiI1(0x2c2,'8!XV'));if(i1lil){console['log']('\x0a☑\x20API地址代理已开启'),console[iiI1(0x249,'JXmH')]('☑️\x20代理地址为'+i1lil+'\x0a');let iilIIl=/[a-zA-Z0-9][-a-zA-Z0-9]{0,62}(\.[a-zA-Z0-9][-a-zA-Z0-9]{0,62})+\.?/g;global['GLOBAL_AGENT'][iiI1(0x324,'hD5m')]=iilIIl[iiI1(0x32d,'hD5m')](i1lil)[0x0]+','+I1iIl;}else l1lil1?(global[iiI1(0x511,'neIS')][iiI1(0x30b,'4QtG')]=l1lil1,global['GLOBAL_AGENT'][iiI1(0x339,'tb@8')]=''+I1iIl,console[iiI1(0x563,')Wy$')](iiI1(0x545,'Z!f!')),console[iiI1(0x459,'lGbt')](iiI1(0x33f,'t9(@')+global[iiI1(0x573,'6XDd')]['HTTP_PROXY']+'\x0a')):(console[iiI1(0x3fa,'aa4j')]('\x0a⚠\x20当前检测到已开启代理但未填写代理地址变量'),console[iiI1(0x418,'utFo')](iiI1(0x383,'E]vI')),console[iiI1(0x459,'lGbt')](iiI1(0x452,'@&&C')));}catch(i1Iili){console[iiI1(0x50e,'@&&C')](iiI1(0x38b,'lGbt')),console[iiI1(0x1f5,'QoD!')](iiI1(0x3d4,'tb@8')),I1iIi=![];}}else console['log'](iiI1(0x444,'I64D')),console[iiI1(0x512,'6XDd')](iiI1(0x20d,'t9(@'));function iii1II(_0x7c519c,_0x3242f4){const _0x3b3b5d=Iii11l();return iii1II=function(_0x294355,_0x420720){_0x294355=_0x294355-0x189;let _0x3ed12e=_0x3b3b5d[_0x294355];if(iii1II['sKGIbY']===undefined){var _0x36d46b=function(_0x20f8b5){const _0x1661e7='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x2a9104='',_0x255357='';for(let _0x2abb7f=0x0,_0x18a02a,_0xb68e17,_0x2c5dfd=0x0;_0xb68e17=_0x20f8b5['charAt'](_0x2c5dfd++);~_0xb68e17&&(_0x18a02a=_0x2abb7f%0x4?_0x18a02a*0x40+_0xb68
2023-12-05 17:20:15 +08:00
// 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