jdpro/jd_dplhbshop.js

5 lines
142 KiB
JavaScript
Raw Normal View History

2024-06-28 07:47:44 +00:00
const $ = new Env("大牌浏览店铺");
2024-08-29 16:59:05 +00:00
var _0xodc='jsjiami.com.v7';const _0x497e04=_0x52dc;if(function(_0x26c6eb,_0x322325,_0x21b534,_0x484c8e,_0x3895ae,_0x3d6293,_0x12f8d9){return _0x26c6eb=_0x26c6eb>>0x9,_0x3d6293='hs',_0x12f8d9='hs',function(_0x5820e9,_0x109681,_0x4c7713,_0xdd3a92,_0x420754){const _0x368337=_0x52dc;_0xdd3a92='tfi',_0x3d6293=_0xdd3a92+_0x3d6293,_0x420754='up',_0x12f8d9+=_0x420754,_0x3d6293=_0x4c7713(_0x3d6293),_0x12f8d9=_0x4c7713(_0x12f8d9),_0x4c7713=0x0;const _0x2e3b9f=_0x5820e9();while(!![]&&--_0x484c8e+_0x109681){try{_0xdd3a92=-parseInt(_0x368337(0x4fa,'!z1('))/0x1*(parseInt(_0x368337(0x5ef,'!7i#'))/0x2)+parseInt(_0x368337(0x283,'wvQ@'))/0x3+parseInt(_0x368337(0x235,'bmri'))/0x4+parseInt(_0x368337(0x68b,'wvQ@'))/0x5+parseInt(_0x368337(0x757,'QLSu'))/0x6+-parseInt(_0x368337(0x2cc,'06U0'))/0x7+parseInt(_0x368337(0x75d,'j3PY'))/0x8;}catch(_0x1ee99c){_0xdd3a92=_0x4c7713;}finally{_0x420754=_0x2e3b9f[_0x3d6293]();if(_0x26c6eb<=_0x484c8e)_0x4c7713?_0x3895ae?_0xdd3a92=_0x420754:_0x3895ae=_0x420754:_0x4c7713=_0x420754;else{if(_0x4c7713==_0x3895ae['replace'](/[bAJdHFNIGBlLunQwSRVMU=]/g,'')){if(_0xdd3a92===_0x109681){_0x2e3b9f['un'+_0x3d6293](_0x420754);break;}_0x2e3b9f[_0x12f8d9](_0x420754);}}}}}(_0x21b534,_0x322325,function(_0x3ce16f,_0x381776,_0x48aa30,_0x4501d8,_0xc3f1f7,_0x3b3ade,_0x5e8771){return _0x381776='\x73\x70\x6c\x69\x74',_0x3ce16f=arguments[0x0],_0x3ce16f=_0x3ce16f[_0x381776](''),_0x48aa30=`\x72\x65\x76\x65\x72\x73\x65`,_0x3ce16f=_0x3ce16f[_0x48aa30]('\x76'),_0x4501d8=`\x6a\x6f\x69\x6e`,(0x18037b,_0x3ce16f[_0x4501d8](''));});}(0x19a00,0x446c9,_0x26f3,0xcf),_0x26f3){}const _0x43f6ec=$[_0x497e04(0xf7,'180r')]()?require(_0x497e04(0x766,'aygY')):'',_0x4edee6=$[_0x497e04(0x729,'Gv73')]()?require(_0x497e04(0x254,'k^y4')):'',_0x7141a5=require(_0x497e04(0x67d,'Tfwc')),_0x599c96=require(_0x497e04(0x6ea,'!7i#')),_0x311fdd=require(_0x497e04(0x46b,'pBp^')),_0x11ec48=require(_0x497e04(0x3b5,'RvRH'));let _0x341024=[],_0x1805a5='',_0x5915e3='',_0x248d90='',_0x4c876b='3';if(process[_0x497e04(0x5c1,'#NgG')][_0x497e04(0x654,'RvRH')]){const _0x3c3da=require(_0x497e04(0x17e,'COsv'));$[_0x497e04(0x4e1,'pBp^')]=_0x3c3da[_0x497e04(0x5a2,'180r')]($[_0x497e04(0x244,'NnX]')][_0x497e04(0x3d6,'pBp^')]($)),$[_0x497e04(0x611,'wlRQ')]=_0x3c3da[_0x497e04(0x20f,'tuPS')]($[_0x497e04(0x2b3,'W8zp')][_0x497e04(0x706,'nhzX')]($));}if($[_0x497e04(0x487,'Tfwc')]()){Object[_0x497e04(0x645,'Wffg')](_0x43f6ec)[_0x497e04(0x6c2,'sM33')](_0x4aae9e=>{const _0x1fef03=_0x497e04;_0x341024[_0x1fef03(0x37b,'!7i#')](_0x43f6ec[_0x4aae9e]);});if(process[_0x497e04(0x421,'nvRe')][_0x497e04(0x2ed,'OE9F')]&&process[_0x497e04(0x5c1,'#NgG')][_0x497e04(0x243,'COsv')]===_0x497e04(0x172,'!z1('))console[_0x497e04(0x532,'lkcI')]=()=>{};}else _0x341024=[$[_0x497e04(0x362,'[2]2')](_0x497e04(0x386,'F9t8')),$[_0x497e04(0x686,'06U0')](_0x497e04(0x534,'#NgG')),...jsonfomat($[_0x497e04(0x631,'3*gb')](_0x497e04(0x461,'Tfwc'))||'[]')[_0x497e04(0x17b,'7Qnw')](_0x4b0a76=>_0x4b0a76[_0x497e04(0x270,'tuPS')])][_0x497e04(0x18d,'3r0U')](_0x53e108=>!!_0x53e108);let _0xd8d44a=process[_0x497e04(0x267,'eBW$')][_0x497e04(0x36b,'WW8T')]||_0x497e04(0x286,'nvRe'),_0x1653d1=process[_0x497e04(0x3ab,'Wffg')][_0x497e04(0x660,'Q&Kn')]||_0x497e04(0x2e3,'Tfwc'),_0x47a7a4=process[_0x497e04(0x697,'y&C^')][_0x497e04(0x169,'COsv')]||'',_0x2a1eef=_0x497e04(0x422,'1p4Y');$[_0x497e04(0x150,'bmri')]=_0x497e04(0xed,'k^y4'),$[_0x497e04(0x420,'Tfwc')]=$[_0x497e04(0x315,'KRex')][_0x497e04(0x3de,'!z1(')](/oC[0-9a-z]+/)[0x0],$[_0x497e04(0x2ac,'COsv')]=[_0x497e04(0x656,'7Qnw'),_0x497e04(0x214,']S4S')];_0x47a7a4!=''&&($[_0x497e04(0x446,'EK]A')]=_0x47a7a4[_0x497e04(0x15d,'nvRe')]('&'));$[_0x497e04(0x53e,'Q&Kn')]=_0x497e04(0x377,'VW8X'),$[_0x497e04(0x212,'y&C^')]=_0x497e04(0x540,'Wffg'),$[_0x497e04(0x628,'3r0U')]=![];let _0x392289=[_0x497e04(0x240,'Cy3x')];$[_0x497e04(0x6e3,'180r')]=_0x392289[_0x2ab5db(0x0,_0x392289[_0x497e04(0x37f,'vxhA')])],$[_0x497e04(0x608,'A1)d')]=process[_0x497e04(0x137,'NnX]')][_0x497e04(0x3d8,'[2]2')]||'',$[_0x497e04(0x3b1,'y&C^')]=![],$[_0x497e04(0x626,'NnX]')]=[],!(async()=>{const _0x3954da=_0x497e04,_0x56b881={'bPNwR':
2024-06-28 07:47:44 +00:00
function Env(o, t) { 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((r, i) => { s.call(this, t, (t, e, s) => { t ? i(t) : r(e) }) }) } 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.logLevels = { debug: 0, info: 1, warn: 2, error: 3 }, this.logLevelPrefixs = { debug: "[DEBUG] ", info: "[INFO] ", warn: "[WARN] ", error: "[ERROR] " }, this.logLevel = "info", 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.encoding = "utf-8", this.startTime = (new Date).getTime(), Object.assign(this, e), this.log("", `🔔${this.name}, 开始!`) } getEnv() { return "undefined" != typeof $environment && $environment["surge-version"] ? "Surge" : "undefined" != typeof $environment && $environment["stash-version"] ? "Stash" : "undefined" != typeof module && module.exports ? "Node.js" : "undefined" != typeof $task ? "Quantumult X" : "undefined" != typeof $loon ? "Loon" : "undefined" != typeof $rocket ? "Shadowrocket" : void 0 } isNode() { return "Node.js" === this.getEnv() } isQuanX() { return "Quantumult X" === this.getEnv() } isSurge() { return "Surge" === this.getEnv() } isLoon() { return "Loon" === this.getEnv() } isShadowrocket() { return "Shadowrocket" === this.getEnv() } isStash() { return "Stash" === this.getEnv() } toObj(t, e = null) { try { return JSON.parse(t) } catch { return e } } toStr(t, e = null, ...s) { try { return JSON.stringify(t, ...s) } catch { return e } } getjson(t, e) { let s = e; if (this.getdata(t)) 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(r => { this.get({ url: t }, (t, e, s) => r(s)) }) } runScript(a, o) { return new Promise(r => { let t = this.getdata("@chavy_boxjs_userCfgs.httpapi"); t = t && t.replace(/\n/g, "").trim(); var e = (e = this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout")) ? +e : 20, [s, i] = (e = o && o.timeout ? o.timeout : e, t.split("@")); this.post({ url: `http://${i}/v1/scripting/evaluate`, body: { script_text: a, mock_type: "cron", timeout: e }, headers: { "X-Key": s, Accept: "*/*" }, timeout: e }, (t, e, s) => r(s)) }).catch(t => this.logErr(t)) } loaddata() { if (!this.isNode()) return {}; this.fs = this.fs || require("fs"), this.path = this.path || require("path"); var t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), s = this.fs.existsSync(t), r = !s && this.fs.existsSync(e); if (!s && !r) return {}; r = s ? t : e; try { return JSON.parse(this.fs.readFileSync(r)) } catch (t) { return {} } } writedata() { var t, e, s, r, i; this.isNode() && (this.fs = this.fs || require("fs"), this.path = this.path || require("path"), t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), r = !(s = this.fs.existsSync(t)) && this.fs.existsSync(e), i = JSON.stringify(this.data), !s && r ? this.fs.writeFileSync(e, i) : this.fs.writeFileSync(t, i)) } lodash_get(t, e, s) { let r = t; for (const t of e.replace(/\[(\d+)\]/g, ".$1").split(".")) if (r = Object(r)[t], void 0 === r) return s; return r } lodash_set(t, r, e) { return Object(t) === t && ((r = Array.isArray(r) ? r : r.toString().match(/[^.[\]]+/g) || []).slice(0, -1).reduce((t, e, s) => Object(t[e]) === t[e] ? t[e] : t[e] = Math.abs(r[s + 1]) >> 0 == +r[s + 1] ? [] : {}, t)[r[r.length - 1]] = e), t } getdata(t) { let e = this.getval(t); if (/^@/.test(t)) { var [, s, r] = /^@(.*?)\.(.*?)$/.exec(t); if (s = s ? this.getval(s) : "") try { const t = JSON.parse(s); e = t ? this.lodash_get(t, r, "") : e } catch (t) { e = "" } } return e } setdata(t, e) { let s = !1; if (/^@/.test(e)) { var [, r, i] = /^@(.*?)\.(.*?)$/.exec(e), a = this.getval(r), a = r ? "null" === a ? null : a || "{}" : "{}"; tr