jdpro/jd_txtotal.js

9 lines
46 KiB
JavaScript
Raw Normal View History

2024-01-02 12:59:48 +00:00
/*
统计转赚红包和特价抽现金提现金额
1 1 11 1 * https://raw.githubusercontent.com/6dylan6/jdpro/main/jd_txtotal.js
*/
const $ = new Env('抽现金提现统计');
var _0xodX='jsjiami.com.v7';const _0x455eed=_0x54f6;(function(_0x5db5eb,_0x1af562,_0x4e709e,_0x4a0f71,_0x2beb6d,_0x18f99e,_0x57ef62){return _0x5db5eb=_0x5db5eb>>0x3,_0x18f99e='hs',_0x57ef62='hs',function(_0x66a95e,_0x5cf451,_0x4aa8ae,_0x5e730f,_0x600a5f){const _0xffe4c6=_0x54f6;_0x5e730f='tfi',_0x18f99e=_0x5e730f+_0x18f99e,_0x600a5f='up',_0x57ef62+=_0x600a5f,_0x18f99e=_0x4aa8ae(_0x18f99e),_0x57ef62=_0x4aa8ae(_0x57ef62),_0x4aa8ae=0x0;const _0x5e161f=_0x66a95e();while(!![]&&--_0x4a0f71+_0x5cf451){try{_0x5e730f=-parseInt(_0xffe4c6(0x245,'p&Aj'))/0x1+-parseInt(_0xffe4c6(0x1a7,'2h(a'))/0x2*(parseInt(_0xffe4c6(0x159,'p&Aj'))/0x3)+-parseInt(_0xffe4c6(0x2df,'H)qL'))/0x4*(parseInt(_0xffe4c6(0x2eb,'ps#M'))/0x5)+parseInt(_0xffe4c6(0x256,'SZzM'))/0x6+-parseInt(_0xffe4c6(0x248,'*&nf'))/0x7*(-parseInt(_0xffe4c6(0x1a4,'39pG'))/0x8)+-parseInt(_0xffe4c6(0x1a1,'v(WO'))/0x9*(parseInt(_0xffe4c6(0x2cd,'*x$C'))/0xa)+parseInt(_0xffe4c6(0x26d,'MlwN'))/0xb;}catch(_0x568132){_0x5e730f=_0x4aa8ae;}finally{_0x600a5f=_0x5e161f[_0x18f99e]();if(_0x5db5eb<=_0x4a0f71)_0x4aa8ae?_0x2beb6d?_0x5e730f=_0x600a5f:_0x2beb6d=_0x600a5f:_0x4aa8ae=_0x600a5f;else{if(_0x4aa8ae==_0x2beb6d['replace'](/[fFnIDyLEPdQRJtwKbquWC=]/g,'')){if(_0x5e730f===_0x5cf451){_0x5e161f['un'+_0x18f99e](_0x600a5f);break;}_0x5e161f[_0x57ef62](_0x600a5f);}}}}}(_0x4e709e,_0x1af562,function(_0x3df9d8,_0x59e290,_0x4eca50,_0x20d76a,_0x1e0b66,_0x533976,_0x4b79a5){return _0x59e290='\x73\x70\x6c\x69\x74',_0x3df9d8=arguments[0x0],_0x3df9d8=_0x3df9d8[_0x59e290](''),_0x4eca50=`\x72\x65\x76\x65\x72\x73\x65`,_0x3df9d8=_0x3df9d8[_0x4eca50]('\x76'),_0x20d76a=`\x6a\x6f\x69\x6e`,(0x1483a9,_0x3df9d8[_0x20d76a](''));});}(0x658,0x8ec9b,_0x5c2c,0xcd),_0x5c2c)&&(_0xodX=`\x2da`);const _0x55e751=$[_0x455eed(0x2e9,'Eurh')]()?require(_0x455eed(0x2f5,'88eM')):'',_0x451b7e=$[_0x455eed(0x2cb,'HbWX')]()?require(_0x455eed(0x2c5,'39pG')):'',_0x35033d=require(_0x455eed(0x285,'aRAN')),_0x39c0a8=require(_0x455eed(0x28c,'utOL'));let _0x153102=!![],_0x1cf1a1=[],_0x12d9b6='',_0x39fd6e='',_0x504e7e='';if(process[_0x455eed(0x2b3,'%xlm')][_0x455eed(0x193,'5Nx(')]){const _0x257fc0=require(_0x455eed(0x23a,'Ger0'));$[_0x455eed(0x293,'S8iP')]=_0x257fc0[_0x455eed(0x2f4,'SZzM')]($[_0x455eed(0x1cb,'i6$y')][_0x455eed(0x1e8,'39pG')]($)),$[_0x455eed(0x140,'x[#)')]=_0x257fc0[_0x455eed(0x253,'0Akb')]($[_0x455eed(0x177,'xL&4')][_0x455eed(0x2b7,'5Nx(')]($));}if(_0x455eed(0x195,'938y')=='0')return;if($[_0x455eed(0x28f,')Tc1')]()){Object[_0x455eed(0x27f,'MlwN')](_0x451b7e)[_0x455eed(0x282,'v(WO')](_0x299ce8=>{const _0x32bf24=_0x455eed;_0x1cf1a1[_0x32bf24(0x2e4,'FPfE')](_0x451b7e[_0x299ce8]);});if(process[_0x455eed(0x273,'938y')][_0x455eed(0x21a,'Eurh')]&&process[_0x455eed(0x201,'FPfE')][_0x455eed(0x16f,'UqSw')]===_0x455eed(0x286,'SZzM'))console[_0x455eed(0x220,'S8iP')]=()=>{};}else _0x1cf1a1=[$[_0x455eed(0x155,')Tc1')](_0x455eed(0x199,'39pG')),$[_0x455eed(0x16d,'Eurh')](_0x455eed(0x131,'ps#M')),..._0x302a62($[_0x455eed(0x1ab,'6C#C')](_0x455eed(0x29b,'88eM'))||'[]')[_0x455eed(0x13c,'utOL')](_0x426c97=>_0x426c97[_0x455eed(0x1dc,'utOL')])][_0x455eed(0x12b,'FPfE')](_0x56ead4=>!!_0x56ead4);!(async()=>{const _0x46423c=_0x455eed,_0x4210ce={'ZfnHO':_0x46423c(0x1e7,'S8iP'),'bCYEZ':function(_0x1312f7,_0x4e5f0a){return _0x1312f7==_0x4e5f0a;},'VkFKv':_0x46423c(0x2a5,'39pG'),'lNwyd':_0x46423c(0x1a6,'i4F%'),'yhorD':_0x46423c(0x200,'IR%)'),'ZbePC':_0x46423c(0x2e1,'W[hI'),'Cwgcv':_0x46423c(0x2a3,'Da)T'),'TuufK':_0x46423c(0x190,'p9s)'),'QTOli':_0x46423c(0x2c7,'S8iP'),'fOBir':_0x46423c(0x1fd,'p9s)'),'GseiP':function(_0x32c660,_0x5e0312){return _0x32c660+_0x5e0312;},'IYdkB':function(_0x32f5c9,_0x1be14e){return _0x32f5c9<_0x1be14e;},'Nknzx':function(_0x5026ec,_0x25239f){return _0x5026ec===_0x25239f;},'SkTxR':_0x46423c(0x157,'39pG'),'AfMDl':_0x46423c(0x2bf,'Fq9f'),'tfijT':function(_0x2b429e,_0x56f2ef){return _0x2b429e(_0x56f2ef);},'WLTqk':function(_0x1e5f3a,_0x264e57){return _0x1e5f3a+_0x264e57;},'rnVhH':function(_0x5b49f5){return _0x5b49f5();},'gsRvg':_0x46423c(0x14d,'0Akb'),'USBqC':_0x46423c(0x191,'%xlm'),'fSofI':function(_0x40814b,_0x2e2db9){return _0x40814b!==_0
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