KR/jd_jk11.js

17 lines
80 KiB
JavaScript
Raw Normal View History

2023-10-24 15:36:53 +08:00
/*
10.24-11.11 联合集卡 双十一冲
10.31可瓜分
2023-10-25 17:52:00 +08:00
cron:31 11 24-31/3,1-11/3 10,11 *
2023-10-24 15:36:53 +08:00
============Quantumultx===============
[task_local]
#10.24-11.11 联合集卡 双十一冲
2023-10-25 17:52:00 +08:00
31 11 24-31/3,1-11/3 10,11 * jd_jk.js, tag=10.24-11.11 联合集卡 双十一冲, enabled=true
2023-10-24 15:36:53 +08:00
*/
const $ = new Env('10.24-11.11 联合集卡 双十一冲');
2023-10-31 17:06:36 +08:00
var version_='jsjiami.com.v7';const I1ii1=iii1II;function iii1II(_0x55917e,_0x4ce768){const _0x35f186=Iii11l();return iii1II=function(_0x13419f,_0x45c700){_0x13419f=_0x13419f-0x1b0;let _0xf38cde=_0x35f186[_0x13419f];if(iii1II['GUJoWZ']===undefined){var _0x444dd3=function(_0x14a515){const _0x583128='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=';let _0x5ec10c='',_0x33ef64='';for(let _0x54b094=0x0,_0x5d152d,_0x39e755,_0x2445ec=0x0;_0x39e755=_0x14a515['charAt'](_0x2445ec++);~_0x39e755&&(_0x5d152d=_0x54b094%0x4?_0x5d152d*0x40+_0x39e755:_0x39e755,_0x54b094++%0x4)?_0x5ec10c+=String['fromCharCode'](0xff&_0x5d152d>>(-0x2*_0x54b094&0x6)):0x0){_0x39e755=_0x583128['indexOf'](_0x39e755);}for(let _0x29eb12=0x0,_0x42bf1a=_0x5ec10c['length'];_0x29eb12<_0x42bf1a;_0x29eb12++){_0x33ef64+='%'+('00'+_0x5ec10c['charCodeAt'](_0x29eb12)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x33ef64);};const _0x240198=function(_0x29f8eb,_0x32beda){let _0x5a2412=[],_0x320b6b=0x0,_0x3e5376,_0x388e95='';_0x29f8eb=_0x444dd3(_0x29f8eb);let _0x5e06a1;for(_0x5e06a1=0x0;_0x5e06a1<0x100;_0x5e06a1++){_0x5a2412[_0x5e06a1]=_0x5e06a1;}for(_0x5e06a1=0x0;_0x5e06a1<0x100;_0x5e06a1++){_0x320b6b=(_0x320b6b+_0x5a2412[_0x5e06a1]+_0x32beda['charCodeAt'](_0x5e06a1%_0x32beda['length']))%0x100,_0x3e5376=_0x5a2412[_0x5e06a1],_0x5a2412[_0x5e06a1]=_0x5a2412[_0x320b6b],_0x5a2412[_0x320b6b]=_0x3e5376;}_0x5e06a1=0x0,_0x320b6b=0x0;for(let _0x1cd9b9=0x0;_0x1cd9b9<_0x29f8eb['length'];_0x1cd9b9++){_0x5e06a1=(_0x5e06a1+0x1)%0x100,_0x320b6b=(_0x320b6b+_0x5a2412[_0x5e06a1])%0x100,_0x3e5376=_0x5a2412[_0x5e06a1],_0x5a2412[_0x5e06a1]=_0x5a2412[_0x320b6b],_0x5a2412[_0x320b6b]=_0x3e5376,_0x388e95+=String['fromCharCode'](_0x29f8eb['charCodeAt'](_0x1cd9b9)^_0x5a2412[(_0x5a2412[_0x5e06a1]+_0x5a2412[_0x320b6b])%0x100]);}return _0x388e95;};iii1II['YFAGyW']=_0x240198,_0x55917e=arguments,iii1II['GUJoWZ']=!![];}const _0x2a00a1=_0x35f186[0x0],_0x1638f9=_0x13419f+_0x2a00a1,_0x52b398=_0x55917e[_0x1638f9];return!_0x52b398?(iii1II['sBvpTA']===undefined&&(iii1II['sBvpTA']=!![]),_0xf38cde=iii1II['YFAGyW'](_0xf38cde,_0x45c700),_0x55917e[_0x1638f9]=_0xf38cde):_0xf38cde=_0x52b398,_0xf38cde;},iii1II(_0x55917e,_0x4ce768);}function Iii11l(){const l1lll=(function(){return[...[version_,'MjUYMsEtYjwYUiqapmMiqp.Jcoumrxn.ywv7nCkl==','WQZcUmkwC8kX','hSomW7NdQJS','W5qUASobza','W7FcQsm','mbPrWPRcOW','WOFcL182ySkFm8onkwFcSSkvW5vQW57dOwi','wfbnW4tdGq','eCkdiq','i8oqW4fjWPZcJw0','qCoQpCkk','f8oJW5DIWQu','cedcGaxdTq','W7FcJCk0ymk9WR4cWQ8bWQ1WuSkNWPeGqs08kG','xgad','heGDWRFcHq','W5/cGduwuvm','u8odlmkPwWRdSc0tcHfkW6O','W5BcTHm/AW','W6z+WOJcJxW','oJ5H','W5D8WQBcTqRdPCoKWPexph7dTfr2W5NdRmk7','fgqfl0FdIa','W5dcRapdI8ke','WQDnlr5byG','WP7cMg00Fq','W5lcOgFcGCo/','5yAp5l686i635B2d772+','WRf3W6tdSSosW6BcM8kWWQtdUCopW7hdNx16WOiriSkVW6tdJCoTW4q','WPVdVsZcKsBdGq','5y2u5yUh5ysM77+Z','kgdcJWpdMdLc','WQX2WOVcPa','zSokpCkSpa','WQddHZ/cJqm','WQ7cM8k9','C8oGoSkRdq','ESoTWQvFau9GWRNcHCkrW64x6k635RoO5Awr6lwM77Y66k6J5QcM5PYY57YL6lAm6yE46kYP','wmofcuvRW5xdGa','W7eHib3dHJX6','nSkAWQzMDG','y8oDo8k1ka','W5nLW4ZdQmoG','WPVdSt7cKc0','WQLcWPBcOZO','hmoJW53dKcC','sSo1nSkbgYFcK8oqW4qGWRmyD8oV','lUAAV+wrI+MyTUM+Ko+8Lq','h3WgeeldTLivWOi','W5OkpSosW4pcQ8kLAHDr','caZdHSkLAI0kzG','WQy5WO5syG','p8o3W5ldPWtdOa','W6dcPJVdISkBDq','cr4E','ySoHW5NdOqJcOSoNWONdMSkLiSkDqZW0WQRcTLxcUJmm','WQrmibvW','WQ82crldQIm','zSo1aCkaWPn7W5ddP8kYW7u','WR8vjJxdVq','W7JcKmk+ymo+W5aNWOJORP/MSOdLPk/OTltVV4RORjtMOOtMNOVNVjBOTRZPHOxORjW','aCkQw8o0rSkEA2BdUgfqW5GfxrPgrKe','lSoLWO9jka','W5WmpSoOW53cRCkHxc5qWRnTiCkwbmoIgmoZsG','WQ11WOZcPdH/','o8kQw8opimkbj8kfnG','rCokW5PyW6pdVY/cK8oPmSk+ya','W7LLW7xdTmoqWR3cJW','W5LjW5xdMmoKWOS','kCkFsmovpa','fXPwkum','dSkekCk9DqddSIqFhwbnW4zes3xdTCk5W74','dW5YWO/cOW','b8oYW5FdIs4','nKS3','r8oFdq','er4Fwa','W4xcGJe0WRK','WPiQWQ9rEa','vConWRpcKmoDfrldJmoXWPFORz3MSBJLPiFOTAhVVP/ORA3MO6dMN5pNVyxOT5lPHjtORju','v8ooW4eFW6dcTIZcKCk+','W5pcO1ZcN8oZ','W4dcJtyDrLq','xMyhnXWqW5GY','j8opWPNcUmoE','m2GrWPhcJW','WOerWPf+DG','WR1dnGnT','WPZdQvlcSrq','p8kZta','rCozW4CFW7JcUdhcJSkonq','WO1VW4TgCW','W6xcVWKzva','gCknmSkS','ACoNhKT7','kCo
2023-10-24 15:36:53 +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.data[t]||null}setval(t,e){return this.isSurge()||this.isLoon()?$persistentStore.write(t,e):this.isQuanX()?$prefs.setValueForKey(t,e):this.isNode()?(this.data=this.loaddata(),this.data[e]=t,this.writedata(),!0):this.data&&this.data[e]||null}initGotEnv(t){this.got=this.got?this.got:require("got"),this.cktough=this.cktough?this.cktough:require("tough-cookie"),this.ckjar=this.ckjar?this.ckjar:new this.cktough.CookieJar,t&&(t.headers=t.headers?t.headers:{},void 0===t.headers.Cookie&&void 0===t.cookieJar&&(t.cookieJar=this.ckjar))}get(t,e=(()=>{})){t.headers&&(delete t.headers["Content-Type"],delete t.headers["Content-Length"])