jdpro/jd_super18.js

13 lines
327 KiB
JavaScript
Raw Normal View History

2024-08-18 02:59:29 +00:00
/*
变量REDCODE='7位字母'
export REDCODE18="xxxxxxx"
*/
const $ = new Env('超级18红包');
var _0xodD='jsjiami.com.v7';const _0x7a2d45=_0x2343;(function(_0x3847cb,_0x921138,_0x4c8ab4,_0x276c45,_0x35be7d,_0x526e5d,_0x200b7d){return _0x3847cb=_0x3847cb>>0x5,_0x526e5d='hs',_0x200b7d='hs',function(_0x437785,_0x2c62cb,_0x2509c1,_0xd46e9f,_0x1d8ab0){const _0x5e239c=_0x2343;_0xd46e9f='tfi',_0x526e5d=_0xd46e9f+_0x526e5d,_0x1d8ab0='up',_0x200b7d+=_0x1d8ab0,_0x526e5d=_0x2509c1(_0x526e5d),_0x200b7d=_0x2509c1(_0x200b7d),_0x2509c1=0x0;const _0x32a204=_0x437785();while(!![]&&--_0x276c45+_0x2c62cb){try{_0xd46e9f=parseInt(_0x5e239c(0x884,'96im'))/0x1+-parseInt(_0x5e239c(0x662,'TRq]'))/0x2*(-parseInt(_0x5e239c(0xbee,'ugI&'))/0x3)+parseInt(_0x5e239c(0xc56,'%VMI'))/0x4*(-parseInt(_0x5e239c(0xc87,'dpAQ'))/0x5)+-parseInt(_0x5e239c(0xfd2,'sYOh'))/0x6*(parseInt(_0x5e239c(0xdf5,'k93Q'))/0x7)+-parseInt(_0x5e239c(0x627,'26xB'))/0x8+-parseInt(_0x5e239c(0x107b,'dpAQ'))/0x9+parseInt(_0x5e239c(0x5c7,'QLZj'))/0xa;}catch(_0x2602df){_0xd46e9f=_0x2509c1;}finally{_0x1d8ab0=_0x32a204[_0x526e5d]();if(_0x3847cb<=_0x276c45)_0x2509c1?_0x35be7d?_0xd46e9f=_0x1d8ab0:_0x35be7d=_0x1d8ab0:_0x2509c1=_0x1d8ab0;else{if(_0x2509c1==_0x35be7d['replace'](/[CpUFerLVDTNEhftRSX=]/g,'')){if(_0xd46e9f===_0x2c62cb){_0x32a204['un'+_0x526e5d](_0x1d8ab0);break;}_0x32a204[_0x200b7d](_0x1d8ab0);}}}}}(_0x4c8ab4,_0x921138,function(_0x5a94db,_0x8d0986,_0xa3b1dd,_0x2713ed,_0x11789d,_0x8a5433,_0x431720){return _0x8d0986='\x73\x70\x6c\x69\x74',_0x5a94db=arguments[0x0],_0x5a94db=_0x5a94db[_0x8d0986](''),_0xa3b1dd=`\x72\x65\x76\x65\x72\x73\x65`,_0x5a94db=_0x5a94db[_0xa3b1dd]('\x76'),_0x2713ed=`\x6a\x6f\x69\x6e`,(0x17eb94,_0x5a94db[_0x2713ed](''));});}(0x1920,0x54fcc,_0x3937,0xcb),_0x3937)&&(_0xodD=0x382d);const _0x313ed4=$[_0x7a2d45(0xac4,'YJJ5')]()?require(_0x7a2d45(0x4ec,'96im')):'';let _0x375c7f='',_0x52f6fb=0xbb8,_0x5a7f3f=0x1,_0x7e7b3=0x0;function _0x3937(){const _0x3e4381=(function(){return[...[_0xodD,'FjpVsjUEtiLCUafemeit.SectXCoTm.EDvNh7RrR==','W7uPWPFdHYS','ug9gtmoH','W5SlW4RdMW','W7tdPuCphq','W7r+pCo2DW','wSkSWO/cK2C','WQHfW5fI','o8kTWOqX','hmobW5fe','ESkYACo/Fq','W7C/WOvqWQ4MFmkegeLEDSkWcYZdVmkjjxHKW7tdRConWOddVSoOox/dJSk0tZGvag/dSmoCWRnYWRddTc7cTSoGW4hdLSomW7xcNmkAWO1zWQ0','W5uDgxVcJCoXW44','rSkUWQRcGLW','g8oInSkMWRS','W4nFhmoWqtvxWORdKmoqdbW','W7ZdTqVcT8k2','W7vOW6DcW7e','W5/dP8orWP51W7jAeW','WOBcT30Vi3yYwZfa','c8oiW4XdWPu','amoWW43dTZdcOtaCwmk1WPze','WRRdKSoEW7iG','qw/dHmkLW5dcLCoLiCkq','W4iDW4/dSvi','WR5bW5vVomo6uq','W5DdbmoKCq','WR3dL8oVE1C','W7SHW7BdUxa','WQ05W5LyBq','emozWOX+','WQxcGeu8mq','gmoNfSkIWPC','aCoaWPRdIa','sbVcVSkMBG','rddcU8k7qa','WPXuW7jyW5S','5yUy5yI05RIi5y2t5lIi6Aga5y2n','WQpdM14hwW','gSoQW5jIWRu','jIxcGSkdsCkPta','W7RdOqxcJSkr','WR3dTKe/WO7dVCo0','W4BcTSkG','W5DIpCosDa','amkXWO8MswFdKgO','FEs6SEEqKX/cI2/dKSkHEHq5WOakrtZcMSoykZDWaW','W6KMBLhcTa','Ft1yWQKi','WQyVbgmn','WOqWW7qGWOq','yMbYdgOkWOe','irf+cCkv','WQujW5aDWOe','rZ/cUCkMDa','xmkWWPJcIge','WRFcGfuvlW','WPldIM0xWRi','W7ldLSkQW7BdNW','xvDMr8oU','WR/cG1C1aG','W7tdTSofWPXr','a8kpWQqDtW','W5aLzhxcGG','WRddRSoqbq','iCkTWQy7CgpdJ0ZcLCoHEq','x8kiWPZcOv4','WRC8W6jlyW','W6nBW6brW48','qwnAA8orW7K','WPhcKhynemo3W7z8jSoldMhcKYBdLgioWRGwzK3dIaddNSkOzWhcRrWWi8ozWP8dWQWTW4dcTmkpW4nqDSoBkvFdKtegWO1nC0pdGaZdIKBdOGCVWONcPmoyW7K','WO43WPtcI8kgx8k4W5LBW6eVt8omWOjNWRbwWOKxW402WQVdSmkZzCkZmxm4W4JcPKqeWPhdOwpcLh7dGCkorCooWOVdR8kGWQ3cRCkwkrxdNttdTZDjdSoYechdJXNdSSkXBa','BNn2j2btWP59Aa','WRRdKJFcVG','yeilW6y8WRm','W4ldTaNcQmkv','WOexl0y4','CfnWmLq','umkcWO7cKwW','dCoosConEvSTB24OWQuAW6ZdLCobBSkrW7bKWOS','aSoBWPVdLCkdWQe','W5zYW5ldImobumkHW4ewW7yKsCkbWOvTWRSE','W7OqW5ldP2e','vJBcI8kysG','sxzvt8oR','WPxdQfDDpG','WP/dVvqhya','W7ldOeLo','WPyrW6lcQSky','A8kldmk2vSoZeMe','WO7dTSo2Fa','eSobW5neWQryW7ZcISkLy1G','bmoGo8kHWP9sW5xdPq','eSoHWPD5tW','Ea7cK8kAzq','WRRdUvzJpq','W5qsW6tdVKq','W63WU52Y','k8oEaCkmWQK','WQnpW71oW5i','WQ8BW5y8WOPFxSo3oYy','WPNdKSoKj14','WRmeW54FWP4','emksWOCstG','W7CBWQJdIqC','ChrftSoxW7PKW5q','nSoiWQTRyG','WRpdKSoNW40mxmkXWOdcT8o3vJK','hSo3WORdU8kJ','n8oAf8kHWOi','nmoohCkT','W4dcMColW7/dNW','WONcV0G0iq','44gf5OYs56Eq44gf6k+W5ywo6iYk5y+zWPFdVxmEW5NcMWpNM5/MJzBKV4BNL7KpWRm+WQX1W4/NMyZKUlhKUQNNRQRLI6NOJR
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