faker3/jd_wyw.js

17 lines
49 KiB
JavaScript
Raw Normal View History

2024-06-28 15:38:28 +08:00
/*
活动名称新版玩一玩 5.17-8.31结束
活动入口APP-我的-更多工具-玩一玩
活动建议定时自行修改奖票有效期2个月
2024-07-02 23:09:05 +08:00
活动变量jd_wyw_notify // 是否推送通知true/false默认不推送
2024-06-28 15:38:28 +08:00
jd_wyw_pinFilter // 账号pin过滤多个用@进行分割
如开启翻倍请自行修改定时建议运行10次每次间隔30分钟以上
cron:1 6,14,18 * * *
*/
const $ = new Env('新版玩一玩')
2024-07-02 23:09:05 +08:00
const _0xd6d9e1=_0x14e2;(function(_0x4d73c6,_0x1d0f30){const _0x28cd48=_0x14e2,_0x32f2a6=_0x4d73c6();while(!![]){try{const _0x115359=parseInt(_0x28cd48(0x2d1,'yw8J'))/0x1*(parseInt(_0x28cd48(0x328,'f4uV'))/0x2)+parseInt(_0x28cd48(0x2cc,'y&LJ'))/0x3*(parseInt(_0x28cd48(0x2a0,'iyMO'))/0x4)+parseInt(_0x28cd48(0x1ad,'oLjg'))/0x5+parseInt(_0x28cd48(0x1e6,'oLjg'))/0x6*(parseInt(_0x28cd48(0x320,'(bBN'))/0x7)+parseInt(_0x28cd48(0x220,'Y]G@'))/0x8*(-parseInt(_0x28cd48(0x2fb,'k1Xo'))/0x9)+-parseInt(_0x28cd48(0x29c,'yw8J'))/0xa*(parseInt(_0x28cd48(0x1ae,'NL1$'))/0xb)+-parseInt(_0x28cd48(0x268,'(bBN'))/0xc;if(_0x115359===_0x1d0f30)break;else _0x32f2a6['push'](_0x32f2a6['shift']());}catch(_0x21ae74){_0x32f2a6['push'](_0x32f2a6['shift']());}}}(_0x4b4e,0x3a85a));const jdCookie=require('./jdCookie'),notify=require(_0xd6d9e1(0x25a,'U4Vy')),common=require(_0xd6d9e1(0x183,'Kp9J')),{H5st}=require('./utils/Rebels_H');let turnlinkId=_0xd6d9e1(0x271,'0(I*'),superlinkId='aE-1vg6_no2csxgXFuv3Kg',taskThreads=process[_0xd6d9e1(0x295,'phHm')]['jd_wyw__threads']||'1';const runInterval=process[_0xd6d9e1(0x28c,'pk&1')][_0xd6d9e1(0x18a,'iKwP')]||_0xd6d9e1(0x180,'4CI5'),isNotify=(process[_0xd6d9e1(0x270,'62O(')][_0xd6d9e1(0x311,'(bBN')]||process[_0xd6d9e1(0x202,'XxCW')][_0xd6d9e1(0x1c9,'(bBN')])===_0xd6d9e1(0x1fe,'Gea8'),pinFilter=(process[_0xd6d9e1(0x270,'62O(')][_0xd6d9e1(0x16c,'pk&1')]||'')[_0xd6d9e1(0x28d,'Y]G@')]('@');function _0x4b4e(){const _0x16664a=['b8oXkSkC','5PoN5lU35PoN6AA+6Age5AEA6lEx7726','vgCGWPtdL8kGWO8','4P+iWRFOH5pMNkpOV63OOOpPGQFLIzRKUlhPLzVORj5e','WOBcVCkPWOC','w2C1WRZdK8kMWPL8iaFdSSoMWP54qL3cQ0pcPa','z8khDKO','W490rSk5WOO5WP7dRbK','WPvzaL5Oh8oRWQ4aW5ldHW','s2mVWONdM8kLWP1HcZldO8oLWQncqKVcOuNcOXDkW4VdMmkOWOKdWRi','eCoeWQe','FSkcW6VcOtP0W5/dTIJcG8kyAMC','imkwAwNdQmkBBW','W5SjW7O','WPrzWPJdV8o5WOBcVwG','WONcNEEjI+AdNEAEIUEEV++/SW','W7BdSSk5ALZcUW','5yE25O+S5yIQ6koh5Awn6lAC77+e','WOJcVLfaFCkCW4JcL3bzW44','5lQJ5yMn5yMf6kgu5AE16lwE776J','WPpcISkjfa','tSoiW6ziiCoJ','5yMS5yUDbW','dSkFW7ddImkrW4xcIW','ESkiW6iU','57+i576s5lI86AAv6AoS5AEx6lsW772p','WP/cK8ok','uKuyW5i','WOhcR8kiWO17WQDC','gSoJWO7cLa','CCkAz1y','WPbvdfzPcG','xCoRoZ0rnmogtvTwzmoAfa','DtPfWRrIWRpdPa','W4ZcKSoot0xcGW','WQdNIOhMG7RMNRNNNANVV7G','W4pcLCkNnq','cCoJWPtcJh7dPJ0GWOBcUCouBabQW7lcMMddOYOSesi','W4CuW7tdJmkwWOOJWRBdTfalm8k0DCox','WO9wW4pdH2NdGq','eSoadYyxbmor','WPZcGmkdfMeP','tYLEWRC8WOvafmkaWP8','zmkuALS','vCkeW7/cTSkViSkuW6iPW5u','sConW7HpcSoNW5hcTCoYiNOWfq','b0DB','57+E5yoO566H','8jcRLCoB','WO7cQfzSAmka','s2mVWONdM8kLWP1HcZldO8oLWQncxeFcSvG','WOFcR1f1FmouWOJdILXAW4ddPtNdJdpdGmoIE1XRW4RdHfmm','cCkwWR0','FSkcW6ZcRaDQW5pdVqq','WOdcISkDjNWVfCkMWQ7dIq','q3NdGG','WQaDq8ooW4JdHaVdLcX1D8k3W6eQW4uwW7xcVCkpzNi','W4JdNmkjWR/dIa','W63dUCk6AK/cUW','reeFW4BdSdVdNwBdOCkyFNBdHq','56Iz54+X5AsF6lAz77YY','zYekWPRcUq8U','eSoTWP0','bahdQmkOpNO7aLK2umk2W4yfWO7dQSk9pYe','WPbmW4FdOx7dGmk6','WOZdJCkQi8kr','W6JdUmkU','l8kfnfu','6lwp5yYn5PwK5PEi','W4FdMCo6kmoJW5nFxSoIuCoNWPmQWOdcMsmQkMi','f8osWPlcMNNdTa','W5ldPmod','t3yGWOtdH8kH','W5bVuW','hNVdUcJdOdtdISokCuxdUNlcPujE','b/gfGAH66lYF6kc357Qt5P2jpq','WP5yWP/dTG','vHdcMmoLgSoApem','WRFcJfZdNuxdQ8k9W6eTta','h8oHWO7cNghdUcGNWRZcR8oZFWrQW6JcM2RdJJC','e8opWQmaW63cTfi8','6kEs5AAh5Bc15PEr776P57IK5PYO57Yq5yoV772Y6lAt5B+r','5AwP56sw77+3','ymknW6hcVsTmW5G','W5mhW6NdLW','WPVcTCkJWOXEWQftW6xdJq','s2mVWONdM8kLWP1HcYFdSCoLWQfUra','5zoM5yYZ5ywj5Q+d5y+E5lUa','5yQ65yMUwa','W4NdImoRcColW4m','6AAf5Q+u6l+y5ywk5RAj5yMJ77YO6lAn6ycf','CmkABuNdM8kS','x8orW7bIlCoIW4q','mSo1C0HZaWhdMsddLmk+','gmkYWPRcVHpdHg7dQqxcLCoZ','jSkNWOe','CmkvASkeW7hcLGtcGa','pCkyBCovWPvOWPJcLSk5W7m','lMSlWQBdPraPW5VdHmkOWPhdJColACoIm8oVfmkjWQJdJ2jRDmojW6CU','gCk+WORcSqtdHgFdVWhdLq','ymkVlqS5wgC','W5r0qmkGWPDKW5JcPqhdKCk8wvxcISoisCo2z2ZcKmofWRVcLu7cR8kkWOfEW5hdPw/dV8k/WQm','tSomW6Tvn8o1','fdJcKxa','W4pcMmoetq','w2C1WRxdGmkGWPn9gtxdPq','hSkKyG','nmkdnq','y8kaCeC','rLyfW4NdUqZdOMFdT8k4D17dI8kLyW','fXFdSSkejNC','WOtcHmkEgKe4aCkS','vflcRCo0EYn3bf02rSkPW7a','W6JdSSkNAeNcPW','wYLyWRC','W4ZcMmoh','xCoRoZ0rnmogtvTrBmooes3cHttcMCkAW5ldKddcPLhcLvaevq','gCkBW7BdOCojW4xcU8oZW40/','WPFcGmkzngCZhSk7WPtdIrC','yYy/v
2024-06-28 15:38:28 +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"])