2023-07-27 16:14:01 +08:00
|
|
|
|
/*
|
|
|
|
|
东东水果:脚本更新地址 jd_fruit_help.js
|
|
|
|
|
更新时间:2021-5-18
|
|
|
|
|
活动入口:京东APP我的-更多工具-东东农场
|
|
|
|
|
==========================Quantumultx=========================
|
|
|
|
|
[task_local]
|
2023-08-25 03:43:26 +08:00
|
|
|
|
#东东农场内部互助
|
2023-07-27 16:14:01 +08:00
|
|
|
|
20 4,16 * * * jd_fruit_help.js, tag=东东农场内部互助, img-url=https://raw.githubusercontent.com/58xinian/icon/master/jdnc.png, enabled=true
|
|
|
|
|
=========================Loon=============================
|
|
|
|
|
[Script]
|
|
|
|
|
cron "20 4,16 * * *" script-path=jd_fruit_help.js,tag=东东农场内部互助
|
|
|
|
|
|
|
|
|
|
=========================Surge============================
|
|
|
|
|
东东农场内部互助 = type=cron,cronexp="20 4,16 * * *",wake-system=1,timeout=3600,script-path=jd_fruit_help.js
|
|
|
|
|
|
|
|
|
|
=========================小火箭===========================
|
|
|
|
|
东东农场内部互助 = type=cron,script-path=jd_fruit_help.js, cronexpr="20 4,16 * * *", timeout=3600, enable=true
|
|
|
|
|
|
|
|
|
|
*/
|
|
|
|
|
const $ = new Env('东东农场内部水滴互助');
|
2023-08-25 11:05:55 +08:00
|
|
|
|
let cookiesArr = [],
|
|
|
|
|
cookie = '',
|
|
|
|
|
jdFruitShareArr = [],
|
|
|
|
|
isBox = false,
|
|
|
|
|
notify,
|
|
|
|
|
allMessage = '';
|
|
|
|
|
let shareCodes = [ // 这个列表填入你要助力的好友的shareCode
|
|
|
|
|
// //账号一的好友shareCode,不同好友的shareCode中间用@符号隔开
|
|
|
|
|
// '5853550f71014282912b76d95beb84c0@b58ddba3317b44ceb0ac86ea8952998c@8d724eb95e3847b6a1526587d1836f27@a80b7d1db41a4381b742232da9d22443@ce107b8f64d24f62a92292180f764018@c73ea563a77d4464b273503d3838fec1@0dd9a7fd1feb449fb1bf854a3ec0e801',
|
|
|
|
|
// //账号二的好友shareCode,不同好友的shareCode中间用@符号隔开
|
|
|
|
|
// '5853550f71014282912b76d95beb84c0@b58ddba3317b44ceb0ac86ea8952998c@8d724eb95e3847b6a1526587d1836f27@a80b7d1db41a4381b742232da9d22443@ce107b8f64d24f62a92292180f764018@c73ea563a77d4464b273503d3838fec1@0dd9a7fd1feb449fb1bf854a3ec0e801',
|
|
|
|
|
]
|
|
|
|
|
let newShareCodes=[];
|
2023-08-29 15:38:30 +08:00
|
|
|
|
var version_='jsjiami.com.v7';const lIil11lI=iiIi11ii;(function(iII1iIII,ill1il11,Ilii1lI,II1iIl1I,ilI11Ili,liliIli,IiiIiIl1){return iII1iIII=iII1iIII>>0x9,liliIli='hs',IiiIiIl1='hs',function(ill1llii,lli1iII1,IlIlIli1,iI1lI111,l11llI11){const Iilii11l=iiIi11ii;iI1lI111='tfi',liliIli=iI1lI111+liliIli,l11llI11='up',IiiIiIl1+=l11llI11,liliIli=IlIlIli1(liliIli),IiiIiIl1=IlIlIli1(IiiIiIl1),IlIlIli1=0x0;const li1i11Il=ill1llii();while(!![]&&--II1iIl1I+lli1iII1){try{iI1lI111=-parseInt(Iilii11l(0x3fa,'RR%G'))/0x1*(parseInt(Iilii11l(0x2b9,'HNc9'))/0x2)+-parseInt(Iilii11l(0x536,'i#VV'))/0x3+-parseInt(Iilii11l(0x1ef,'REY]'))/0x4*(-parseInt(Iilii11l(0x2e8,')O*4'))/0x5)+-parseInt(Iilii11l(0x2b7,'maMS'))/0x6+parseInt(Iilii11l(0x3d3,'hgE2'))/0x7+-parseInt(Iilii11l(0x497,'JyTV'))/0x8+-parseInt(Iilii11l(0x4f4,'E9H6'))/0x9*(-parseInt(Iilii11l(0x25e,'1syw'))/0xa);}catch(iiI1IIii){iI1lI111=IlIlIli1;}finally{l11llI11=li1i11Il[liliIli]();if(iII1iIII<=II1iIl1I)IlIlIli1?ilI11Ili?iI1lI111=l11llI11:ilI11Ili=l11llI11:IlIlIli1=l11llI11;else{if(IlIlIli1==ilI11Ili['replace'](/[lfheEwbTXgVxBCAWypru=]/g,'')){if(iI1lI111===lli1iII1){li1i11Il['un'+liliIli](l11llI11);break;}li1i11Il[IiiIiIl1](l11llI11);}}}}}(Ilii1lI,ill1il11,function(lIiIilI1,lil1iIl1,IilIIilI,i1li1Il1,Ili11i1,IiiiiIIl,llIiilIl){return lil1iIl1='\x73\x70\x6c\x69\x74',lIiIilI1=arguments[0x0],lIiIilI1=lIiIilI1[lil1iIl1](''),IilIIilI=`\x72\x65\x76\x65\x72\x73\x65`,lIiIilI1=lIiIilI1[IilIIilI]('\x76'),i1li1Il1=`\x6a\x6f\x69\x6e`,(0x13ba3b,lIiIilI1[i1li1Il1](''));});}(0x18200,0x84695,IIlIllli,0xc3),IIlIllli)&&(version_=IIlIllli);let IlIiIlii='',l1ilII='',il1ll1ll={},li1il11I=![];const lIl1iili=$[lIil11lI(0x504,'XfNd')]()?process['env'][lIil11lI(0x3d4,'O8hT')]?process[lIil11lI(0x359,'RR%G')][lIil11lI(0x1cd,'rK4K')]:0x64:$[lIil11lI(0x1dc,'REY]')]('retainWater')?$[lIil11lI(0x1ce,'uUR3')](lIil11lI(0x50b,'ZzxL')):0x64;let ii1I1il1=!![],lIi1IlI1=![],Iiliil1=$[lIil11lI(0x391,'o@ug')]()?0x14:0x5;const iIlIli11=lIil11lI(0x3f9,'o@ug'),liI1i1I1=lIil11lI(0x33a,'ew!k'),ii1Ilii1=require(lIil11lI(0x2e0,'Cr5p')),lli11lll=require(lIil11lI(0x3bd,'1o*(')),l111I11l=require(lIil11lI(0x3ff,'ew!k'));let iIiIll11=ilil1iiI(0x28),Ii1Ii1I=ilil1iiI(0xa,lIil11lI(0x38a,'1^u1')),lIIiIlIi=ilil1iiI(0x20,'1234567890qwertyuiopasdfghjklzxcvbnm'),lliiI11=ilil1iiI(0x2,lIil11lI(0x241,'@R!O'))+'-'+ilil1iiI(0x4,lIil11lI(0x3e6,'4Xd8'))+'-'+ilil1iiI(0x4,lIil11lI(0x3f7,'1o*('))+'-'+ilil1iiI(0x5,'1234567890'),lIIi1il='106.475'+Math[lIil11lI(0x282,'IY$&')](Math[lIil11lI(0x3e5,'L[Ep')]()*0x383+0x64),ii1IiIlI=lIil11lI(0x426,'@S!7')+Math[lIil11lI(0x49b,'v)m2')](Math[lIil11lI(0x3ac,'Lew!')]()*0x383+0x64),lI1IllI='',lII1iI1=new Date()[lIil11lI(0x26d,'4Xd8')](),lIi11lI1=!![];const IiII1iIi=require('fs');let lIlI11ll=![],l1lllIii=lIil11lI(0x28f,'Ijp)'),ilIiiiil=IiII1iIi[lIil11lI(0x507,'1syw')](l1lllIii),l1Iiiii1=[];ilIiiiil&&(console[lIil11lI(0x3a9,'@S!7')](lIil11lI(0x35a,'maMS')),l1Iiiii1=IiII1iIi['readFileSync'](l1lllIii,lIil11lI(0x587,'lBql')),l1Iiiii1&&(l1Iiiii1=l1Iiiii1[lIil11lI(0x579,'Ijp)')](),l1Iiiii1=JSON[lIil11lI(0x2c0,'XfNd')](l1Iiiii1)));let l1l1lIli=0x0,lili1lIi=![],ll1iilii=[];function IIlIllli(){const llI111=(function(){return[...[version_,'exljgwsjAbixVapmEiW.coum.bhvC7fprTXyTBEW==','oK3dIeJdTa','aGZdRmoDW6RcHmkCW5O','W6yrW4ldUSow','hSoybq','WPhcP8khA0ZdUG','nZBdL3dcTJW','nJJdG0hcOtZdPL8CW6WCrmonW68','WRhcHa/dIIJcLcu','WQ7dSCkSnuW3naC','smoiWRPZhG','rSoyWRjmgSohW5hdPSobW78','W5ZdG8k4WOtdUCoGW5bXW5TXnWW','n8oAna','WOddPu3dNq4','gCodemkLW5C','A8ksstddNLVcTbemmSk8W4epcqVdQupdQCk3wG','W7/dO8okwZ8','W7/dGJddVqu','44cE5yQh5yMK6l655lMf','WP3cTCo9W6NcNG','AuFcKWRcPKy','cUs4Mos5UoweTowFVWldRCoMWOv55P+G6k+A6kY15Rgn5AsN6lESpUkcG++7IEkbU++5Ja','hfFdHY7cIW','W6/dNCosW6m','pSoxu8ouga','Dmoad8oQWRa','dEISIUMhSoAxToEBGow9VoInUUwoIG4UWQFdJXqK','m8oicNWhWQ0','p8kDxSo5wSkQW4i','kCoEuSkHda','AmoTlSojWRxdPXVcKLRcHa','qSosWRK','WP5gomkyWRtdQSkhW4i5WPGs','cZFdRCoeW7u','luFdVINcSv0bemkBW7j2','WP/cHmoMW5tcRq','WOBcKmoHW5u','aaRdQa','nZBdLW','W6u6WQu','W707WQzzva','dMtdUIlcKW','oCo5n8kCW4dcVCoG','W7PIBJ02','W418zYJdLG','WO7cP8kDAfNdPSky','5OIF5yQXW7u','l
|
2023-07-27 16:14:01 +08:00
|
|
|
|
// prettier-ignore
|
2023-08-25 03:43:26 +08:00
|
|
|
|
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"])
|