mirror of
https://github.com/shufflewzc/faker3.git
synced 2024-11-15 00:09:20 +08:00
20 lines
89 KiB
JavaScript
20 lines
89 KiB
JavaScript
|
/*
|
|||
|
活动名称:积分兑换E卡 · 超级会员
|
|||
|
活动链接:https://cjhy-isv.isvjcloud.com/mc/wxPointShopView/pointExgECard?venderId=<店铺id>&giftId=<活动id>
|
|||
|
环境变量:
|
|||
|
jd_pointExgECard_activityUrl // 活动链接
|
|||
|
jd_pointExgECard_threads // 控制并发线程数(正整数),默认1,最大5
|
|||
|
jd_pointExgECard_interval // 自定义运行间隔时长(整数,单位毫秒),默认1000
|
|||
|
jd_pointExgECard_notify // 是否推送通知(true/false),默认不推送
|
|||
|
jd_pointExgECard_pinFilter // 账号pin过滤,多个用@进行分割
|
|||
|
jd_pointExgECard_hotbreak // IP限制后继续执行(true/false),默认false
|
|||
|
|
|||
|
cron:1 1 1 1 *
|
|||
|
|
|||
|
*/
|
|||
|
|
|||
|
const $ = new Env('积分兑换E卡(超级会员)')
|
|||
|
function esf1_AG(){}var zhQPPwn=Object['defineProperty'],f5uzsmB,gPkrIo,ecOO9R0,OUDLqZZ,uBeVvIt,aFyxPgK,VJXqzE,tDRMXls,hMrNrgT,sOnLvTL,cUvoWz,azkhMSE,t689mL,YvxpfkI,xHruNT,iazYCw6,pPgHLfN,fN5m_Q,tSEj1F;function XPJ4agk(esf1_AG){return f5uzsmB[esf1_AG<0x59?esf1_AG-0x5e:esf1_AG-0x5a]}f5uzsmB=i27Y5o.call(this);function dLs2Sk(esf1_AG,zhQPPwn){gPkrIo(esf1_AG,'length',{value:zhQPPwn,configurable:XPJ4agk(0xb7)});return esf1_AG}gPkrIo=Object.defineProperty;var ghRIGT5=[],i2iV9nN=[':k[qx3IA','.mw/)fiSy','S@|@"P5n^','BF0Ad59E9(zrtY','c#+K~','T7vx0U^^XqZ','~P]l66kbz!NJ}O','}Iet(','QvAqm.g?','C?M#Z+LSmRu','kdoIe','$&a?Y','R+PXFU7`',XPJ4agk(0x5c),'~3&>>gv','7ZnV6EkINn>a`dN','++xJ!XP`~n6y{7lbI)','B^9Axy8sWT5Q5@dB','2bj~','@NB9:F#`','Zh?*ctM)','G&z~9"N`','>hfV+EG`','j^3~Y','@NB9:F,UZnp0W^!RC}J%%U|pX_+}*z','@NB9:F,UZnp0W^!RC}J%?E8s%Tq%7|p','G2=3N','@NB9:F,UZnp0W^!RC}J%mXls|]"H)','@NB9:F,UZnp0W^!RC}J%~5ls|]"H)','[}1>f','@NB9:F,UZnp0W^!RC}J%`0,UBh4_:dPb','fx&>0Uv','@NB9:F,UZnp0W^!RC}J%kWls#TdQ&@p','e+TF#',')3H?','b7a?>gx`','!V9?','`36>f','2`nhu6}4.#RG[ugUhDo4.zH[fX>e:b6/+>cJf','hys?S','7ZnV6Es`','V7=~Igv',XPJ4agk(0x5b),']+">egjOp_5Q)','#^p~7','$&yXjWv','BZVJAHx`','b7O>P%)q,','YZO>f',XPJ4agk(0x5a),'h1~K=WeZkwL65XBV%t?N','DLy6AY=4=Yq53w;HP~o{sT)','Re6BH6sJDy&h/9gUaBbP!])','33QXJg6p*O',XPJ4agk(0x5a),'h1~K=WeZkwAd5XLqa`9/14[kq1y5hE4UlN3(vr%[?S',']+">jH:`~T3M*d8by}&','<7v?^}]`',']+">jH:`','o&}>8%P`','J+z~',XPJ4agk(0x61),'JZp~_Xf11T',XPJ4agk(0x5e),'PS_JI','IE<V7','IE<VwJTO1P8hqt/jrb=%{%v',XPJ4agk(0x5a),'h1~K=WeZkwAd5XLqa`qu','7Uihf>L44#E5E}CH9;3([~)','M7C?','63s?k!#`','ZN[+q}o%%(',XPJ4agk(0x5a),'h1~K=We!:bajY=/a;LnNXRDqC7^iE},UGo3ZnrH[aF*{8]AQTsL$Z','BZ9?',XPJ4agk(0x5b),'63s?k!<11T','v%6R>MyeB|c@<Oby($','AZfVY','f+[9lhP`','>z`q>e1&','%qN+Tpn&','%%5R','<zjY+Z$t{v','I^O>GX]`','!%`Wo~BgP','~o/%eFIC*','P+4}hc=M,',XPJ4agk(0x5c),'f+[9lhA1qOoQDUu/27@J}XII+=','O1SW5mUU<j','v%SqKrIt=#[d$','S+H?My#I*','Lz(pwev',XPJ4agk(0x5a),'I^O>GX]`',']+yXeFIC|o2J7|7<~)','2hB9KE@`','v]VQa8Oq&','":*JzE,)','D}@JXUP`','R+PXFU7`','|b"9q$II7P',XPJ4agk(0x5d),'P"C+.>QZBAPh%<1Ut={{c6"~";z{y_razs[^rg|46',XPJ4agk(0x5a),']+">}X)q@Cc3jtwb2b=~','f+[9lhP`','kZ[>kMb`','+>cJm}@`','++q~','#^p~7',']+=~fFs`','|bI,|yG`','fZt?Ig$H*',XPJ4agk(0x5a),XPJ4agk(0x5d),'EiKju6tjC7IVq*T','f+[9lhA1qOoQDUu/27@J}XII+=','#^p~7',']+O>l2v','BZ9?',XPJ4agk(0x5a),'PS_JI','|bs?qm,UX!9d(gp','BZ9?',']+">#wkQ@C}','BZ9?','BZ9?','63s?S','x?eJKU3cQC}','I+&>$;WpE_=nqt6/o?`','x?e5V$xI*','7^m?','"V[9N5n1*','$&O>q8MpIDq|Aui<@hd~','$&O>q8MpS=rQU3*skg&','VRQq`xG`','V76>f','^guALJ%E{,T}@)@fOjm?','Yx8Sl%P`','YZx5:!<11T',XPJ4agk(0x5a),'<7v?u5f11T',',xB>iX]`','w4C?>g@`','jZ2~',XPJ4agk(0x5d),'YZx5:!#`',XPJ4agk(0x5d),'VRQq/Mls%_2W)','BZ9?',XPJ4agk(0x5d),XPJ4agk(0x5a),'BZ9?',XPJ4agk(0x60),'c}}9#gv',XPJ4agk(0x5a),'9Ef1ZC9K3ev?aW','sHq*','nHrSCx<O','9Ef1ZCIO','TU!*ex(','sHq*','AvSwhBjQ','RUki',XPJ4agk(0x5a),'63s?S','63s?k!<11T','VRQq`xG`','^:u*=',']+">#w;)','|b9?','S+!>f%G`','[&">s','I+yqJgG`M]5','~aGgh.%ffv',XPJ4agk(0x5f),'4Z6>f',XPJ4agk(0x5e),XPJ4agk(0x5a),'BZ9?','O7TYS','|bs?qm,UX!9d(gp',']+">AH$l6nKt|3','L5iK3`"a^e&h]{u','4Z6>f','BZ9?','BZ9?','I+&>$;WpE_=nqt6/o?`',XPJ4agk(0x5a),'|b!><HG`',']+">AHx`','F}SEytv','|b"9q$]`',XPJ4agk(0x5a),'YU2j14{IaE;','`c{:f>rJqY8','nrWhoKS>yIc','quSjy`na!W5idECH4o3','98)kGs(fMX&ht<e','nr@imO?>^e&)','BZ9?','hyVJ#MBp^T',XPJ4agk(0x5f),'BZ9?',XPJ4agk(0x60),'BZ9?','s+^XaykI*',',ZS,=','{9%XUUb`','c~r,(n=w',',+<$@GAw','ZZlJiXv','E(.SmC<wz8','D2z,','"V8q!}]`','M~`S!4E2','Ta7#','(o5zB',XPJ4agk(0x64),')7z,99IOO8`;_n@+0jcYmCk?O8d','x?">f[#`','5g<*f','A_4GHOQu@','l1kd4E=w','t~?#!]jw','A^s?f',']+O>M$Es*','zvI$;3Cps5Z&0XtlzvI$;3Cps5Z&0XtlzvI$;3Cps5Z&0XtlB2',',mxJL,XRUhLr2','+1W$','r0<,tC<wz8','X:cJiXG`','>ZS,',',mxJL,!eG8tne:OA',']+=~/y_I7P3`w3kIy}!>>F@`','dV?I<Ha`','>ZC?','Wmz3K','e1kJ5zD','+x_%^X=Mc,f','`Y3Iwjek+[L','Tac#IF^9,C7y"]b','{9Y>{%OUJq;|h^Qb`BYXf',XPJ4agk(0x61),'01kJR','H0?#','33VJz^`c*','J^!9IwVI*','^ju#','Y|rIwjHw','c_z5f','j#NJP96xr?(','7+|zP]Kw','d0`SVtUw','&mZz,9p2','B<c#A4T2','{(3X','P<st}uE2','<7v?^}]`','k~gS%EHw','nPrIs9T2','`Y3BR','7+|zG:LwI?Ri&Aqe5jq]!]fboi?rwXbZTav,!','P<st}uer+[','M~
|
|||
|
// 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"])
|