mirror of https://github.com/KingRan/KR.git
19 lines
86 KiB
JavaScript
19 lines
86 KiB
JavaScript
|
/**
|
|||
|
|
|||
|
活动名称:签到有礼(超级无线欧莱雅)
|
|||
|
活动链接:https://lzkj-isv.isvjcloud.com/prod/cc/interactsaas/index?activityType=<10023/10040>&templateId=<模板id>&activityId=<活动id>&nodeId=<nodeid>&prd=cjwx
|
|||
|
支持activityType :(10023/10040)
|
|||
|
环境变量:jd_lzkj_loreal_daySign_url // 活动链接
|
|||
|
|
|||
|
cron:1 1 1 1 *
|
|||
|
============Quantumultx===============
|
|||
|
[task_local]
|
|||
|
#lzkj_loreal签到有礼
|
|||
|
1 1 1 1 * jd_lzkj_loreal_daySign.js, tag=lzkj_loreal签到有礼, enabled=true
|
|||
|
*/
|
|||
|
|
|||
|
const $ = new Env("签到有礼(lzkj_loreal)");
|
|||
|
var version_='jsjiami.com.v7';const iI1iIIIl=iiI11lii;(function(iiIIl1lI,ili1IIi,iilIi1l,IlIlIlI,li1i1IlI,I1llI11,Ill1lllI){return iiIIl1lI=iiIIl1lI>>0x5,I1llI11='hs',Ill1lllI='hs',function(IlIIil1I,l1Iil1II,li1l1l1I,l1l1iii,llIlIII){const lI1iiiil=iiI11lii;l1l1iii='tfi',I1llI11=l1l1iii+I1llI11,llIlIII='up',Ill1lllI+=llIlIII,I1llI11=li1l1l1I(I1llI11),Ill1lllI=li1l1l1I(Ill1lllI),li1l1l1I=0x0;const iIIl1l=IlIIil1I();while(!![]&&--IlIlIlI+l1Iil1II){try{l1l1iii=-parseInt(lI1iiiil(0x395,'ERc@'))/0x1+-parseInt(lI1iiiil(0x4d5,'%X4q'))/0x2+-parseInt(lI1iiiil(0x45d,'gZRR'))/0x3*(parseInt(lI1iiiil(0x300,']fKr'))/0x4)+parseInt(lI1iiiil(0x3a6,'Azj8'))/0x5*(parseInt(lI1iiiil(0x454,'CAoY'))/0x6)+-parseInt(lI1iiiil(0x2e8,'CAoY'))/0x7+-parseInt(lI1iiiil(0x240,'Azj8'))/0x8*(-parseInt(lI1iiiil(0x37d,'btB('))/0x9)+-parseInt(lI1iiiil(0x209,'n$z#'))/0xa*(-parseInt(lI1iiiil(0x2ca,'BwXl'))/0xb);}catch(llIlil1I){l1l1iii=li1l1l1I;}finally{llIlIII=iIIl1l[I1llI11]();if(iiIIl1lI<=IlIlIlI)li1l1l1I?li1i1IlI?l1l1iii=llIlIII:li1i1IlI=llIlIII:li1l1l1I=llIlIII;else{if(li1l1l1I==li1i1IlI['replace'](/[PRdAVytUQDHTklxMLpB=]/g,'')){if(l1l1iii===l1Iil1II){iIIl1l['un'+I1llI11](llIlIII);break;}iIIl1l[Ill1lllI](llIlIII);}}}}}(iilIi1l,ili1IIi,function(llll1ii1,Ili111il,il1l11Ii,i1iiI1ll,illI1Ii,Ili1llIi,li11l11){return Ili111il='\x73\x70\x6c\x69\x74',llll1ii1=arguments[0x0],llll1ii1=llll1ii1[Ili111il](''),il1l11Ii='\x72\x65\x76\x65\x72\x73\x65',llll1ii1=llll1ii1[il1l11Ii]('\x76'),i1iiI1ll='\x6a\x6f\x69\x6e',(0x131b3a,llll1ii1[i1iiI1ll](''));});}(0x1960,0x9052f,IillIIii,0xcd),IillIIii)&&(version_=IillIIii);function IillIIii(){const iIIl11l1=(function(){return[version_,'DVjAUsVyjkTiamRixQL.McHlopmHH.Lvd7RTPtPB==','W6FdH8o3','rmouW60','6iYO5y+JWQOIsXTuW7C95As26lAJ772g','fxCjW5xdRG','D3BcMG0','W71LWPGYvG','gKjqW5NcVmoXWOZcRvtdNr3dH8o6jZ1nWPVcTH7dI8o/W6OVk8k6m8kaWQCBALVdISojoSoRW4ioWOjpB8koW6q3n1VdLSos','W59Wm8ottYrk','vh0Fumk4W40','kEE6LowmOCo0','xSkntdpdPuqxW68DymobWPyvWPPGFCkKv2PoW7fEWQSbgqddSI4qW5elzSkAW5JcRG','eIVcOCkIf8kKBmkRWO0','FxBcGWK','W6apWQpcGSos','naxdO8oEomkZ','lmkaW5/dUmkIW6y','kYm8WRy6W4zVksO','pdqH','fCkJqemG','WQ7cH1vhW7b5gmkz','sCoyW7VdUSoRFv0','w8oVW4VdPmoX','W6WzWOtcMSoe','pHDlzCkVW6RcRCobg8khW5z1WQi','W6elWPpcQ8kvW7XF','5P6q5B+c5AAN','WQWKq8k3WO0','AowkJos/Qa','umkkcHxdHq','tmoNrCoTtW','5B6F5y2u5AEa6lwZ4P2Ouo+8VEMfLoAxKoAjOoIJIUIfNEAFLq','k8kcWOm7WRdcNuTQWPtdGSkwCSkxxa','44kRW6lMNyBOGBFOJRFLJ5xMTzFLI4tKVixMGy8','5PQs5lQx5PE35O+M55Q/57cJ5z6R','W63dQHOdWR5p','B1T8WQu','AMGohv0','j8kYW60buN5OBmk3cHyjWOa','W6WoWPhcLSoL','W7PhWOm','wmouW7NdPSo2zLFcIG','f8owW49YBCo2BqNdLmkwWOVcTeSDcSknDfro','WQ8XuSkrWOvK','W5BcTa7dHgHjp2O','g8kfWOmGWRJcM0XjWQy','WPtdScxdIwDn','k8kUW6SluLf0CCkQebaaWP8','tMSYumkYW4XWWPRcRmkcW5RcPrddMG','E2LzWQZdJG','WRe7rSkHWPTI','W4fWfCoFyq','dh/cLq','lIiWWR4wW6zOkW','q8oJWP7cMmkQx3C','WPtdQI3dLKS','nrtdOSocoSkGv8otW6S','wSokWRpcK0W','EuyBz8kZ','nSkuWQ00WPi','mKW1','lrDwzq','pCkBDK8B','oxpcUmoyWO8','W4vHpmoMzW','W5TcWRKgvq','m8kjWO0','rmoqWQqjta','cvlcHmovWPK','evePW7RdPWNcUSkyAq','gZFdVSkOfW','pZ44WQ02W6y','ESo1WRhcIxG3rmoBW7RdSCoyqG','W7JdOHitWPHmkCoY','5As1W5hdUG','W5RcIe17W6RdV8krpYi','b+wlV+s9PG','pmk5W4ZdOCkmWO7dTmk3b8o8WQpdSfmznmo7Aq','W6ObWOa','W7ddGrOTWRu','nZq7WQSRW6a','ieDcW77cMq','d3pcUSolWPu','oIeLWQa2W6TVmcBdUSkjl8ksiI5G','W7aGWRlcQCkz','lSkeW5ZdUG','W4/dNbODWRS','hCoCuKNcKL47W4PaE8kyW6m','5lUR5PMM5lYT5zcP','WPy7xGSCDSoPWPLY','t8oyWQS','W4BdUghdJSkY','W4OXWP/dJmk6','W5fHoSo0','W4RdUbevWP9diSo4','rey3W7RdRadcP8kODCkKyNylW7WMkGxdLCofDmkZh1tcIaZcN8k2W7ZcU8oZFJ9ecdhcJmo2WOZcRCoLm8ovsMRdOdddHa','ddSZASk2W55LWRu','W6NcGez+W50','v8kndGddOGW','wCoLWPxcJCkCCxX2','WRFdQqFdMwG','W44LWOZcQmkr','Fmo1WR8','DSk8WQWseKG2ECoP','5P615OIL5yMU6i+H5y+Y5Psa5O2F','uCopWOZcR2qBF8oRW6ddMSoS','5lID5A+c5z+W','WOpcPqBcOSoun8oIsCo6','FCkFWQmDc8ksW7CoWQab','afnxW5NcKmkOW4ZdPKi','bSohW5qUFq','W6XZbSo0EW','FmouW7NdMSks','adZcP8kfgmkUya','W4/cRaJdR2zQaGNcGa','WPyMrbGnvSoOWPe','W4yQWQVcMCosttfiWPa','umkgW6ZcG0zSjNeC','gCkJWPOkWPe','CCkJW43cR2G','uLScwCk/','W4D6kConvcjwW6fZ','kG/dTW','bSkaC2ak','deW4W7JdHW/cVSkB','e3NcLCkYq8oeaCkpu0S','DmkiWQmedSobWQXy','
|
|||
|
|
|||
|
// 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"])
|