├── 35459_sfsy.js ├── README.md ├── aliyun.js ├── axj.js ├── cehngren ├── dyjsb.js ├── fqmfxs.js ├── huyadouyu ├── jk.js ├── jlqc.js ├── live ├── live2 ├── ltyd.py ├── lxzx.js ├── maoren.js ├── mxbc.js ├── qckf.js ├── qdzs.js ├── qianti.js ├── qk365.js ├── qm.js ├── raw_master_ysf.js ├── shpj.js ├── smzdm_auto_sign_bot.py ├── sy.js ├── sysxc.js ├── tpyqc.js ├── tvbox ├── xbk.js ├── xsgjz(1).py ├── ylw.js ├── zstj.js ├── 华硕会员.js ├── 南湖声音.js ├── 喜力club.js ├── 多娇江山.js ├── 柠檬绿地g.js ├── 爱海盐.js ├── 畅游.py ├── 第一电动2.11修.js ├── 美步.js ├── 蒙牛超级会员.js ├── 运动柯城.js └── 阅读抽奖.py /README.md: -------------------------------------------------------------------------------- 1 | # ziyong 2 | 青龙面板自用脚本,请勿外传 3 | 内容来源网络,仅供学习测试,下载后请于24h内删除。 4 | -------------------------------------------------------------------------------- /aliyun.js: -------------------------------------------------------------------------------- 1 | //阿里云盘连续签到活动 2 | 3 | const $ = API(); 4 | const refresh_token = '';//抓包搜请求体关键字:refresh_token 5 | 6 | !(async () => { 7 | 8 | if (!refresh_token) { 9 | console.log('先填写refresh_token!'); 10 | return 11 | } 12 | await main(); 13 | 14 | })().catch(async (e) => { 15 | console.log('', '❌失败! 原因:' + e + '!', ''); 16 | }).finally(() => { 17 | $.done(); 18 | }); 19 | 20 | var token = ""; 21 | async function main() { 22 | try { 23 | const url = `https://auth.aliyundrive.com/v2/account/token`; 24 | const method = `POST`; 25 | const headers = { 26 | 'Connection': `keep-alive`, 27 | 'Content-Type': `application/json; charset=UTF-8`, 28 | 'X-Canary': `client=iOS,app=adrive,version=v4.1.3`, 29 | 'User-Agent': `AliApp(AYSD/4.1.3) com.alicloud.smartdrive/4.1.3 Version/16.3 Channel/201200 Language/zh-Hans-CN /iOS Mobile/iPhone15,2`, 30 | 'Host': `auth.aliyundrive.com`, 31 | 'Accept-Language': `zh-CN,zh-Hans;q=0.9`, 32 | 'Accept': `*/*` 33 | }; 34 | const body = `{"grant_type":"refresh_token","app_id":"pJZInNHN2dZWk8qg","refresh_token":"${refresh_token}"}`; 35 | 36 | const myRequest = { 37 | url: url, 38 | method: method, 39 | headers: headers, 40 | body: body 41 | }; 42 | 43 | let a = await $.http.post(myRequest); 44 | let data = JSON.parse(a.body); 45 | if (data.code == 'InvalidParameter.RefreshToken') { 46 | //{"code":"InvalidParameter.RefreshToken","message":"The input parameter refresh_token is not valid. ","requestId":null} 47 | console.log(`token刷新失败,${data.message}`); 48 | } 49 | else{ 50 | console.log(data.nick_name); 51 | token = data.access_token; 52 | await sign(); 53 | } 54 | 55 | } catch (error) { 56 | console.log('error:' + error); 57 | } 58 | } 59 | 60 | async function sign() { 61 | try { 62 | const url = `https://member.aliyundrive.com/v1/activity/sign_in_list`; 63 | const method = `POST`; 64 | const headers = { 65 | 'Connection': `keep-alive`, 66 | 'Content-Type': `application/json`, 67 | 'Origin': `https://pages.aliyundrive.com`, 68 | 'X-Canary': `client=web,app=other,version=v0.1.0`, 69 | 'User-Agent': `Mozilla/5.0 (iPhone; CPU iPhone OS 16_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/20D5024e iOS16.3 (iPhone15,2;zh-Hans-CN) App/4.1.3 AliApp(yunpan/4.1.3) com.alicloud.smartdrive/28278449 Channel/201200 AliApp(AYSD/4.1.3) com.alicloud.smartdrive/4.1.3 Version/16.3 Channel/201200 Language/zh-Hans-CN /iOS Mobile/iPhone15,2 language/zh-Hans-CN`, 70 | 'Authorization': `Bearer ${token}`, 71 | 'Host': `member.aliyundrive.com`, 72 | 'Referer': `https://pages.aliyundrive.com/`, 73 | 'Accept-Language': `zh-CN,zh-Hans;q=0.9`, 74 | 'Accept': `application/json, text/plain, */*` 75 | }; 76 | const body = `{"isReward":false}`; 77 | 78 | const myRequest = { 79 | url: url, 80 | method: method, 81 | headers: headers, 82 | body: body 83 | }; 84 | let a = await $.http.post(myRequest); 85 | let data = JSON.parse(a.body); 86 | if (data.success) { 87 | console.log(`已连续签到${data.result.signInCount}天!`); 88 | await sign_in_reward(data.result.signInCount); 89 | } 90 | else { 91 | console.log(`签到失败,${data.message}!`); 92 | } 93 | 94 | } catch (error) { 95 | console.log(error); 96 | } 97 | } 98 | 99 | async function sign_in_reward(day) { 100 | try { 101 | const url = `https://member.aliyundrive.com/v1/activity/sign_in_reward`; 102 | const method = `POST`; 103 | const headers = { 104 | 'Connection': `keep-alive`, 105 | 'Content-Type': `application/json`, 106 | 'Origin': `https://pages.aliyundrive.com`, 107 | 'X-Canary': `client=web,app=other,version=v0.1.0`, 108 | 'User-Agent': `Mozilla/5.0 (iPhone; CPU iPhone OS 16_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/20D5024e iOS16.3 (iPhone15,2;zh-Hans-CN) App/4.1.3 AliApp(yunpan/4.1.3) com.alicloud.smartdrive/28278449 Channel/201200 AliApp(AYSD/4.1.3) com.alicloud.smartdrive/4.1.3 Version/16.3 Channel/201200 Language/zh-Hans-CN /iOS Mobile/iPhone15,2 language/zh-Hans-CN`, 109 | 'Authorization': `Bearer ${token}`, 110 | 'Host': `member.aliyundrive.com`, 111 | 'Referer': `https://pages.aliyundrive.com/`, 112 | 'Accept-Language': `zh-CN,zh-Hans;q=0.9`, 113 | 'Accept': `application/json, text/plain, */*` 114 | }; 115 | const body = `{"signInDay":${day}}`; 116 | 117 | const myRequest = { 118 | url: url, 119 | method: method, 120 | headers: headers, 121 | body: body 122 | }; 123 | 124 | let a = await $.http.post(myRequest); 125 | let data = JSON.parse(a.body); 126 | if (data.success) { 127 | console.log(`奖励:${data.result.name},${data.result.description},${data.result.notice}!`); 128 | } 129 | else { 130 | console.log(`奖励获取失败:${data.message}!`); 131 | } 132 | 133 | } catch (error) { 134 | console.log(error); 135 | } 136 | } 137 | 138 | 139 | /*********************************** API *************************************/ 140 | function ENV() { const e = "undefined" != typeof $task, t = "undefined" != typeof $loon, s = "undefined" != typeof $httpClient && !t, i = "function" == typeof require && "undefined" != typeof $jsbox; return { isQX: e, isLoon: t, isSurge: s, isNode: "function" == typeof require && !i, isJSBox: i, isRequest: "undefined" != typeof $request, isScriptable: "undefined" != typeof importModule } } function HTTP(e = { baseURL: "" }) { const { isQX: t, isLoon: s, isSurge: i, isScriptable: n, isNode: o } = ENV(), r = /https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&\/\/=]*)/; const u = {}; return ["GET", "POST", "PUT", "DELETE", "HEAD", "OPTIONS", "PATCH"].forEach(l => u[l.toLowerCase()] = (u => (function (u, l) { l = "string" == typeof l ? { url: l } : l; const h = e.baseURL; h && !r.test(l.url || "") && (l.url = h ? h + l.url : l.url); const a = (l = { ...e, ...l }).timeout, c = { onRequest: () => { }, onResponse: e => e, onTimeout: () => { }, ...l.events }; let f, d; if (c.onRequest(u, l), t) f = $task.fetch({ method: u, ...l }); else if (s || i || o) f = new Promise((e, t) => { (o ? require("request") : $httpClient)[u.toLowerCase()](l, (s, i, n) => { s ? t(s) : e({ statusCode: i.status || i.statusCode, headers: i.headers, body: n }) }) }); else if (n) { const e = new Request(l.url); e.method = u, e.headers = l.headers, e.body = l.body, f = new Promise((t, s) => { e.loadString().then(s => { t({ statusCode: e.response.statusCode, headers: e.response.headers, body: s }) }).catch(e => s(e)) }) } const p = a ? new Promise((e, t) => { d = setTimeout(() => (c.onTimeout(), t(`${u} URL: ${l.url} exceeds the timeout ${a} ms`)), a) }) : null; return (p ? Promise.race([p, f]).then(e => (clearTimeout(d), e)) : f).then(e => c.onResponse(e)) })(l, u))), u } function API(e = "untitled", t = !1) { const { isQX: s, isLoon: i, isSurge: n, isNode: o, isJSBox: r, isScriptable: u } = ENV(); return new class { constructor(e, t) { this.name = e, this.debug = t, this.http = HTTP(), this.env = ENV(), this.node = (() => { if (o) { return { fs: require("fs") } } return null })(), this.initCache(); Promise.prototype.delay = function (e) { return this.then(function (t) { return ((e, t) => new Promise(function (s) { setTimeout(s.bind(null, t), e) }))(e, t) }) } } initCache() { if (s && (this.cache = JSON.parse($prefs.valueForKey(this.name) || "{}")), (i || n) && (this.cache = JSON.parse($persistentStore.read(this.name) || "{}")), o) { let e = "root.json"; this.node.fs.existsSync(e) || this.node.fs.writeFileSync(e, JSON.stringify({}), { flag: "wx" }, e => console.log(e)), this.root = {}, e = `${this.name}.json`, this.node.fs.existsSync(e) ? this.cache = JSON.parse(this.node.fs.readFileSync(`${this.name}.json`)) : (this.node.fs.writeFileSync(e, JSON.stringify({}), { flag: "wx" }, e => console.log(e)), this.cache = {}) } } persistCache() { const e = JSON.stringify(this.cache, null, 2); s && $prefs.setValueForKey(e, this.name), (i || n) && $persistentStore.write(e, this.name), o && (this.node.fs.writeFileSync(`${this.name}.json`, e, { flag: "w" }, e => console.log(e)), this.node.fs.writeFileSync("root.json", JSON.stringify(this.root, null, 2), { flag: "w" }, e => console.log(e))) } write(e, t) { if (this.log(`SET ${t}`), -1 !== t.indexOf("#")) { if (t = t.substr(1), n || i) return $persistentStore.write(e, t); if (s) return $prefs.setValueForKey(e, t); o && (this.root[t] = e) } else this.cache[t] = e; this.persistCache() } read(e) { return this.log(`READ ${e}`), -1 === e.indexOf("#") ? this.cache[e] : (e = e.substr(1), n || i ? $persistentStore.read(e) : s ? $prefs.valueForKey(e) : o ? this.root[e] : void 0) } delete(e) { if (this.log(`DELETE ${e}`), -1 !== e.indexOf("#")) { if (e = e.substr(1), n || i) return $persistentStore.write(null, e); if (s) return $prefs.removeValueForKey(e); o && delete this.root[e] } else delete this.cache[e]; this.persistCache() } notify(e, t = "", l = "", h = {}) { const a = h["open-url"], c = h["media-url"]; if (s && $notify(e, t, l, h), n && $notification.post(e, t, l + `${c ? "\n多媒体:" + c : ""}`, { url: a }), i) { let s = {}; a && (s.openUrl = a), c && (s.mediaUrl = c), "{}" === JSON.stringify(s) ? $notification.post(e, t, l) : $notification.post(e, t, l, s) } if (o || u) { const s = l + (a ? `\n点击跳转: ${a}` : "") + (c ? `\n多媒体: ${c}` : ""); if (r) { require("push").schedule({ title: e, body: (t ? t + "\n" : "") + s }) } else console.log(`${e}\n${t}\n${s}\n\n`) } } log(e) { this.debug && console.log(`[${this.name}] LOG: ${this.stringify(e)}`) } info(e) { console.log(`[${this.name}] INFO: ${this.stringify(e)}`) } error(e) { console.log(`[${this.name}] ERROR: ${this.stringify(e)}`) } wait(e) { return new Promise(t => setTimeout(t, e)) } done(e = {}) { s || i || n ? $done(e) : o && !r && "undefined" != typeof $context && ($context.headers = e.headers, $context.statusCode = e.statusCode, $context.body = e.body) } stringify(e) { if ("string" == typeof e || e instanceof String) return e; try { return JSON.stringify(e, null, 2) } catch (e) { return "[object Object]" } } }(e, t) } 141 | /*****************************************************************************/ -------------------------------------------------------------------------------- /axj.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 作者:AX 3 | * ========= 青龙--配置文件 =========== 4 | * 项目名称:安心记加班 5 | * 变量名 axj 账号1Au&tk@账号2Au&tk 6 | * 抓Authorization 扭蛋抽奖需开抓包抽奖然后body里的deviceToken 7 | * 一天运行三次 cron 10 6,15,19 * * * 8 | * 2023/1/21 完善转盘抽奖 扭蛋抽奖 9 | * 多账号用 换行 或 @ 分割 10 | * ==================================== 11 | * 12 | */ 13 | 14 | 15 | 16 | const $ = new Env("安心记"); 17 | const ckName = "axj"; 18 | let show = "金币兑换现金" 19 | //-------------------- 一般不动变量区域 ------------------------------------- 20 | //const utils = require("./utils"); 21 | const notify = $.isNode() ? require("./sendNotify") : ""; 22 | const Notify = 1; //0为关闭通知,1为打开通知,默认为1 23 | let debug = 0; //Debug调试 0关闭 1开启 24 | let envSplitor = ["@", "\n"]; //多账号分隔符 25 | let ck = msg = ''; //let ck,msg 26 | let host, hostname; 27 | let userCookie = ($.isNode() ? process.env[ckName] : $.getdata()) || ''; 28 | let userList = []; 29 | let userIdx = 0; 30 | let userCount = 0; 31 | //---------------------- 自定义变量区域 ----------------------------------- 32 | //--------------------------------------------------------- 33 | 34 | async function start() { 35 | console.log(show) 36 | console.log('\n================== 查询金币 ==================\n'); 37 | taskall = []; 38 | for (let user of userList) { 39 | taskall.push(await user.info_point('金币查询')); 40 | await wait(2); 41 | } 42 | await Promise.all(taskall); 43 | console.log('\n================== 每日签到 ==================\n'); 44 | taskall = []; 45 | for (let user of userList) { 46 | taskall.push(await user.task_sign('每日签到')); 47 | await wait(2); 48 | } 49 | await Promise.all(taskall); 50 | console.log('\n================== 查询抽奖次数 ==================\n'); 51 | taskall = []; 52 | for (let user of userList) { 53 | taskall.push(await user.task_cx('开始查询')); 54 | await wait(2); 55 | } 56 | await Promise.all(taskall); 57 | console.log('\n================== 查询扭蛋抽奖次数 ==================\n'); 58 | taskall = []; 59 | for (let user of userList) { 60 | taskall.push(await user.task_ndcx('开始查询')); 61 | await wait(2); 62 | } 63 | await Promise.all(taskall); 64 | console.log('\n================== 运行后金币查询 ==================\n'); 65 | taskall = []; 66 | for (let user of userList) { 67 | taskall.push(await user.task_a('开始查询')); 68 | await wait(2); 69 | } 70 | 71 | await Promise.all(taskall); 72 | 73 | } 74 | class UserInfo { 75 | constructor(str) { 76 | this.index = ++userIdx; 77 | this.cktest = str.split('&')[0]; //单账号多变量分隔符 78 | this.cktest2 = str.split('&')[1]; 79 | this.ck = "Bearer " + this.cktest.replace('Bearer', '') 80 | this.ck2 = this.cktest2; 81 | //let ck = str.split('&') 82 | //this.data1 = ck[0] 83 | //this.sign = this.ck1 84 | //this.userid = this.ck2 85 | this.headers={ 86 | //'Content-Type': 'application/x-www-form-urlencoded', 87 | //Host: 'ymshapi.dmhw1688.com', 88 | //'User-Agent': 'okhttp/4.9.1', 89 | 'content-type': 'application/json', 90 | 'User-Agent':'PostmanRuntime-ApipostRuntime/1.1.0', 91 | 'Cache-Control':'no-cache', 92 | 'content-type':'application/json', 93 | 'Accept':'*/*', 94 | 'Accept-Encoding':'gzip, deflate, br', 95 | 'Connection':'keep-alive', 96 | 'Authorization': this.ck, 97 | //body: 'merchantId=20&appType=1&appId=28&sign=this.ck1&devVersion=1.4.5&userId=this.ck2' 98 | } 99 | 100 | } 101 | 102 | async info_point(name) { // 金币查询 103 | try { 104 | let options = { 105 | method: "GET", 106 | url: `https://market-gateway.julanling.com/activity-third-account/api/cash/draw/drawIndex?os=ANDROID&appVersion=6.9.20&appChannel=unknow`, 107 | headers: {'Authorization': this.ck}, 108 | //body: `{"os":"ANDROID","appVersion":"6.9.20","appChannel":"vivo","deviceToken":"4e978751b3e56331d11bf8f6a0ff95fd"}`, 109 | 110 | }; 111 | //console.log(options); 112 | let result = await httpRequest(options, name); 113 | //console.log(result); 114 | if (result.errorCode == 0) { 115 | DoubleLog(`账号[${this.index}] 金币: ${result.results.balanceAmount}`); 116 | } else { 117 | DoubleLog(`账号[${this.index}] 金币查询:失败 ❌ 了呢,原因未知!`); 118 | console.log(result); 119 | } 120 | } catch (error) { 121 | console.log(error); 122 | } 123 | 124 | } 125 | async task_sign(name) { // 执行签到 126 | try { 127 | let options = { 128 | method: 'POST', 129 | url: 'https://market-gateway.julanling.com/market-center/api2/signIn/signIn', 130 | headers: this.headers, 131 | body: '{"os":"ANDROID","appVersion":"6.9.20","appChannel":"vivo","deviceToken":"4e978751b3e56331d11bf8f6a0ff95fd"}', 132 | }; 133 | //console.log(options); 134 | let result = await httpRequest(options, name); 135 | //console.log(result); 136 | if (result.errorCode == "0") { 137 | DoubleLog(`账号[${this.index}] 签到: ${result.results.amount}`); 138 | } else { 139 | DoubleLog(`账号[${this.index}] 签到:失败 ❌ 了呢,原因未知!` + result.errorStr); 140 | //console.log(result); 141 | } 142 | } catch (error) { 143 | console.log(error); 144 | } 145 | } 146 | async task_cx(name) { // 抽奖查询 147 | try { 148 | let options = { 149 | method: 'Get', 150 | url: 'https://market-gateway.julanling.com/market-center/api2/dial/detailCore?appChannel=vivo&appVersion=6.9.20&operatingSystem=ANDROID&os=ANDROID', 151 | headers: {'Authorization': this.ck}, 152 | //body: '{"os":"ANDROID","appVersion":"6.9.20","appChannel":"vivo","deviceToken":"4e978751b3e56331d11bf8f6a0ff95fd"}', 153 | }; 154 | //console.log(options); 155 | let result = await httpRequest(options, name); 156 | //console.log(result); 157 | if (result.errorCode == 0) { 158 | DoubleLog(`账号[${this.index}] 开始查询: ${result.results.dialValidNum}`); 159 | let dialValidNum = parseInt(result.results.dialValidNum) 160 | if (dialValidNum > 0) { 161 | console.log("判断当前可抽奖" + dialValidNum + "次,开始抽奖"); 162 | for (let i = 0; i < dialValidNum; i++) { 163 | await this.task_cj("抽奖"); 164 | 165 | await wait(6); 166 | //await this.task_lq("领取"); 167 | } 168 | } 169 | } else { 170 | DoubleLog(`账号[${this.index}] 查询失败 ❌ 了呢,原因未知!` + result.errorStr); 171 | //console.log(result); 172 | } 173 | } catch (error) { 174 | console.log(error); 175 | } 176 | } 177 | async task_cj(name) { // 执行抽奖 178 | try { 179 | let options = { 180 | method: 'POST', 181 | url: 'https://market-gateway.julanling.com/market-center/api2/dial/luckyDraw', 182 | headers: this.headers, 183 | body: '{"appChannel":"vivo","appVersion":"6.9.20","operatingSystem":"ANDROID","os":"ANDROID"}', 184 | }; 185 | //console.log(options); 186 | let result = await httpRequest(options, name); 187 | 188 | //await (i); 189 | //this.bizNo = i; 190 | //console.log(result); 191 | if (result.errorCode == "0") { 192 | DoubleLog(`账号[${this.index}] 抽奖获得: ${result.results.amount} 领奖编号${result.results.bizNo}`); 193 | 194 | let i = result.results.bizNo; 195 | this.body=`{"bizNo":"${i}","appChannel":"vivo","appVersion":"6.9.20","operatingSystem":"ANDROID","os":"ANDROID"}` 196 | //console.log(i); 197 | //await i (result.results.bizNo); 198 | //let bizNo = DoubleLog (result.results.bizNo); 199 | } else { 200 | DoubleLog(`账号[${this.index}] 抽奖失败 ❌ 了呢,原因未知!` + result.errorStr); 201 | //console.log(result); 202 | } 203 | } catch (error) { 204 | console.log(error); 205 | } 206 | 207 | let options = { 208 | method: 'POST', 209 | url: 'https://market-gateway.julanling.com/market-center/api2/dial/receiveDialCoin', 210 | headers: this.headers, 211 | //body: `{"bizNo":"${this.bizNo}","appChannel":"vivo","appVersion":"6.9.20","operatingSystem":"ANDROID","os":"ANDROID"}`, 212 | body:this.body, 213 | }; 214 | //console.log(options); 215 | let result = await httpRequest(options, name); 216 | //console.log(result); 217 | if (result.errorCode == "0") { 218 | DoubleLog(`账号[${this.index}] 领取: ${result.results.amount}`); 219 | } else { 220 | DoubleLog(`账号[${this.index}] 领取失败 ❌ 了呢,原因未知!` + result.errorStr); 221 | //console.log(result); 222 | } 223 | } catch (error) { 224 | console.log(error); 225 | } 226 | 227 | 228 | /*async task_lq(name) { // 抽奖奖励领取 229 | 230 | 231 | try { 232 | let options = { 233 | method: 'POST', 234 | url: 'https://market-gateway.julanling.com/market-center/api2/dial/receiveDialCoin', 235 | headers: this.headers, 236 | //body: `{"bizNo":"${this.bizNo}","appChannel":"vivo","appVersion":"6.9.20","operatingSystem":"ANDROID","os":"ANDROID"}`, 237 | body:this.body, 238 | }; 239 | //console.log(options); 240 | let result = await httpRequest(options, name); 241 | //console.log(result); 242 | if (result.errorCode == "0") { 243 | DoubleLog(`账号[${this.index}] 领取: ${result.results.amount}`); 244 | } else { 245 | DoubleLog(`账号[${this.index}] 领取失败 ❌ 了呢,原因未知!` + result.errorStr); 246 | //console.log(result); 247 | } 248 | } catch (error) { 249 | console.log(error); 250 | } 251 | }*/ 252 | 253 | async task_ndcx(name) { // 扭蛋次数查询 254 | try { 255 | let options = { 256 | method: "post", 257 | url: `https://market-gateway.julanling.com/market-center/api2/gacha/luckyDraw`, 258 | headers: this.headers, 259 | body: `{"deviceToken":"${this.ck2}","version":"6.9.20","os":"ANDROID","appVersion":"6.9.20","appChannel":"unknow"}`, 260 | 261 | }; 262 | //console.log(options); 263 | let result = await httpRequest(options, name); 264 | if (result.errorCode == 0) { 265 | DoubleLog(`账号[${this.index}] 开始查询: ${result.results.remainTimes}`); 266 | let remainTimes = parseInt(result.results.remainTimes) 267 | if (remainTimes > 0) { 268 | console.log("判断当前可抽奖" + remainTimes + "次,开始抽奖"); 269 | for (let i = 0; i < remainTimes; i++) { 270 | await this.task_ndcj("抽奖"); 271 | await wait(6); 272 | } 273 | } 274 | } 275 | 276 | //console.log(result); 277 | if (result.result == 1) { 278 | DoubleLog(`账号[${this.index}] 查询: ${result.data.remainTimes}`); 279 | } else { 280 | DoubleLog(`账号[${this.index}] 查询失败 ❌ 了呢,原因`+ result.errorStr); 281 | console.log(result); 282 | } 283 | } catch (error) { 284 | console.log(error); 285 | } 286 | 287 | } 288 | async task_ndcj(name) { // 扭蛋抽奖 289 | try { 290 | let options = { 291 | method: 'POST', 292 | url: 'https://market-gateway.julanling.com/market-center/api2/gacha/luckyDraw', 293 | headers: this.headers, 294 | body: `{"deviceToken":"${this.ck2}","version":"6.9.20","os":"ANDROID","appVersion":"6.9.20","appChannel":"unknow"}`, 295 | }; 296 | //console.log(options); 297 | let result = await httpRequest(options, name); 298 | //console.log(result); 299 | if (result.errorCode == 0) { 300 | DoubleLog(`账号[${this.index}] 抽奖获得: ${result.results.name}`); 301 | } else { 302 | DoubleLog(`账号[${this.index}] 抽奖失败 ❌ 了呢,原因` + result.errorStr); 303 | //console.log(result); 304 | } 305 | } catch (error) { 306 | console.log(error); 307 | } 308 | } 309 | async task_a(name) { // 运行后金币查询 310 | try { 311 | let options = { 312 | method: "GET", 313 | url: `https://market-gateway.julanling.com/activity-third-account/api/cash/draw/drawIndex?os=ANDROID&appVersion=6.9.20&appChannel=unknow`, 314 | headers: {'Authorization': this.ck}, 315 | //body: `{"os":"ANDROID","appVersion":"6.9.20","appChannel":"vivo","deviceToken":"4e978751b3e56331d11bf8f6a0ff95fd"}`, 316 | 317 | }; 318 | //console.log(options); 319 | let result = await httpRequest(options, name); 320 | //console.log(result); 321 | if (result.errorCode == 0) { 322 | DoubleLog(`账号[${this.index}] 运行后金币查询: ${result.results.balanceAmount}`); 323 | } else { 324 | DoubleLog(`账号[${this.index}] 金币查询:失败 ❌ 了呢,原因未知!`); 325 | console.log(result); 326 | } 327 | } catch (error) { 328 | console.log(error); 329 | } 330 | 331 | } 332 | 333 | 334 | } 335 | 336 | !(async () => { 337 | if (!(await checkEnv())) return; 338 | if (userList.length > 0) { 339 | await start(); 340 | } 341 | await SendMsg(msg); 342 | })() 343 | .catch((e) => console.log(e)) 344 | .finally(() => $.done()); 345 | 346 | 347 | // #region ******************************************************** 固定代码 ******************************************************** 348 | 349 | // 变量检查与处理 350 | async function checkEnv() { 351 | if (userCookie) { 352 | // console.log(userCookie); 353 | let e = envSplitor[0]; 354 | for (let o of envSplitor) 355 | if (userCookie.indexOf(o) > -1) { 356 | e = o; 357 | break; 358 | } 359 | for (let n of userCookie.split(e)) n && userList.push(new UserInfo(n)); 360 | userCount = userList.length; 361 | } else { 362 | console.log("未找到CK"); 363 | return; 364 | } 365 | return console.log(`共找到${userCount}个账号`), true;//true == !0 366 | } 367 | // =========================================== 不懂不要动 ========================================================= 368 | // 网络请求 (get, post等) 369 | async function httpRequest(options, name) { var request = require("request"); return new Promise((resolve) => { if (!name) { let tmp = arguments.callee.toString(); let re = /function\s*(\w*)/i; let matches = re.exec(tmp); name = matches[1] } if (debug) { console.log(`\n【debug】===============这是${name}请求信息===============`); console.log(options) } request(options, function (error, response) { if (error) throw new Error(error); let data = response.body; try { if (debug) { console.log(`\n\n【debug】===============这是${name}返回数据==============`); console.log(data) } if (typeof data == "string") { if (isJsonString(data)) { let result = JSON.parse(data); if (debug) { console.log(`\n【debug】=============这是${name}json解析后数据============`); console.log(result) } resolve(result) } else { let result = data; resolve(result) } function isJsonString(str) { if (typeof str == "string") { try { if (typeof JSON.parse(str) == "object") { return true } } catch (e) { return false } } return false } } else { let result = data; resolve(result) } } catch (e) { console.log(error, response); console.log(`\n ${name}失败了!请稍后尝试!!`) } finally { resolve() } }) }) } 370 | // 等待 X 秒 371 | function wait(n) { return new Promise(function (resolve) { setTimeout(resolve, n * 1000) }) } 372 | // 双平台log输出 373 | function DoubleLog(data) { if ($.isNode()) { if (data) { console.log(`${data}`); msg += `\n${data}` } } else { console.log(`${data}`); msg += `\n${data}` } } 374 | // 发送消息 375 | async function SendMsg(message) { if (!message) return; if (Notify > 0) { if ($.isNode()) { var notify = require("./sendNotify"); await notify.sendNotify($.name, message) } else { $.msg($.name, '', message) } } else { console.log(message) } } 376 | // 完整 Env 377 | 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"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.get(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { try { if (t.headers["set-cookie"]) { const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar } } catch (t) { this.logErr(t) } }).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) })) } post(t, e = (() => { })) { if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.post(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) }); else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t)); else if (this.isNode()) { this.initGotEnv(t); const { url: s, ...i } = t; this.got.post(s, i).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) }) } } time(t, e = null) { const s = e ? new Date(e) : new Date; let i = { "M+": s.getMonth() + 1, "d+": s.getDate(), "H+": s.getHours(), "m+": s.getMinutes(), "s+": s.getSeconds(), "q+": Math.floor((s.getMonth() + 3) / 3), S: s.getMilliseconds() }; /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); return t } msg(e = t, s = "", i = "", r) { const o = t => { if (!t) return t; if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { "open-url": t } : this.isSurge() ? { url: t } : void 0; if ("object" == typeof t) { if (this.isLoon()) { let e = t.openUrl || t.url || t["open-url"], s = t.mediaUrl || t["media-url"]; return { openUrl: e, mediaUrl: s } } if (this.isQuanX()) { let e = t["open-url"] || t.url || t.openUrl, s = t["media-url"] || t.mediaUrl; return { "open-url": e, "media-url": s } } if (this.isSurge()) { let e = t.url || t.openUrl || t["open-url"]; return { url: e } } } }; if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { let t = ["", "==============📣系统通知📣=============="]; t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) } } log(...t) { t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) } logErr(t, e) { const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) } wait(t) { return new Promise(e => setTimeout(e, t)) } done(t = {}) { const e = (new Date).getTime(), s = (e - this.startTime) / 1e3; this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) } }(t, e) } 378 | -------------------------------------------------------------------------------- /live2: -------------------------------------------------------------------------------- 1 | #EXTM3U x-tvg-url="https://epg.112114.xyz/pp.xml.gz,https://assets.livednow.com/epg.xml" 2 | #EXTINF:-1 tvg-name="CCTV1" tvg-logo="https://epg.iill.top/logo/CCTV1.png" group-title="•央视「IPV6」",CCTV1「IPV6」 3 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226559/index.m3u8 4 | #EXTINF:-1 tvg-name="CCTV2" tvg-logo="https://epg.iill.top/logo/CCTV2.png" group-title="•央视「IPV6」",CCTV2「IPV6」 5 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226540/index.m3u8 6 | #EXTINF:-1 tvg-name="CCTV3" tvg-logo="https://epg.iill.top/logo/CCTV3.png" group-title="•央视「IPV6」",CCTV3「IPV6」 7 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226021/index.m3u8 8 | #EXTINF:-1 tvg-name="CCTV4" tvg-logo="https://epg.iill.top/logo/CCTV4.png" group-title="•央视「IPV6」",CCTV4「IPV6」 9 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226428/index.m3u8 10 | #EXTINF:-1 tvg-name="CCTV5" tvg-logo="https://epg.iill.top/logo/CCTV5.png" group-title="•央视「IPV6」",CCTV5「IPV6」 11 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226019/index.m3u8 12 | #EXTINF:-1 tvg-name="CCTV5+" tvg-logo="https://epg.iill.top/logo/CCTV5+.png" group-title="•央视「IPV6」",CCTV5+「IPV6」 13 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221225603/index.m3u8 14 | #EXTINF:-1 tvg-name="CCTV6" tvg-logo="https://epg.iill.top/logo/CCTV6.png" group-title="•央视「IPV6」",CCTV6「IPV6」 15 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226010/index.m3u8 16 | #EXTINF:-1 tvg-name="CCTV7" tvg-logo="https://epg.iill.top/logo/CCTV7.png" group-title="•央视「IPV6」",CCTV7「IPV6」 17 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221225733/index.m3u8 18 | #EXTINF:-1 tvg-name="CCTV8" tvg-logo="https://epg.iill.top/logo/CCTV8.png" group-title="•央视「IPV6」",CCTV8「IPV6」 19 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226008/index.m3u8 20 | #EXTINF:-1 tvg-name="CCTV9" tvg-logo="https://epg.iill.top/logo/CCTV9.png" group-title="•央视「IPV6」",CCTV9「IPV6」 21 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221225734/index.m3u8 22 | #EXTINF:-1 tvg-name="CCTV10" tvg-logo="https://epg.iill.top/logo/CCTV10.png" group-title="•央视「IPV6」",CCTV10「IPV6」 23 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226473/index.m3u8 24 | #EXTINF:-1 tvg-name="CCTV11" tvg-logo="https://epg.iill.top/logo/CCTV11.png" group-title="•央视「IPV6」",CCTV11「IPV6」 25 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226565/index.m3u8 26 | #EXTINF:-1 tvg-name="CCTV12" tvg-logo="https://epg.iill.top/logo/CCTV12.png" group-title="•央视「IPV6」",CCTV12「IPV6」 27 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226568/index.m3u8 28 | #EXTINF:-1 tvg-name="CCTV13" tvg-logo="https://epg.iill.top/logo/CCTV13.png" group-title="•央视「IPV6」",CCTV13「IPV6」 29 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226537/index.m3u8 30 | #EXTINF:-1 tvg-name="CCTV14" tvg-logo="https://epg.iill.top/logo/CCTV14.png" group-title="•央视「IPV6」",CCTV14「IPV6」 31 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226591/index.m3u8 32 | #EXTINF:-1 tvg-name="CCTV15" tvg-logo="https://epg.iill.top/logo/CCTV15.png" group-title="•央视「IPV6」",CCTV15「IPV6」 33 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226476/index.m3u8 34 | #EXTINF:-1 tvg-name="CCTV16" tvg-logo="https://epg.iill.top/logo/CCTV16.png" group-title="•央视「IPV6」",CCTV16「IPV6」 35 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226100/index.m3u8 36 | #EXTINF:-1 tvg-name="CCTV17" tvg-logo="https://epg.iill.top/logo/CCTV17.png" group-title="•央视「IPV6」",CCTV17「IPV6」 37 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221225765/index.m3u8 38 | #EXTINF:-1 tvg-name="湖南卫视" tvg-logo="https://epg.iill.top/logo/湖南卫视.png" group-title="•卫视「IPV6」",湖南卫视「IPV6」 39 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226307/index.m3u8 40 | #EXTINF:-1 tvg-name="浙江卫视" tvg-logo="https://epg.iill.top/logo/浙江卫视.png" group-title="•卫视「IPV6」",浙江卫视「IPV6」 41 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226339/index.m3u8 42 | #EXTINF:-1 tvg-name="江苏卫视" tvg-logo="https://epg.iill.top/logo/江苏卫视.png" group-title="•卫视「IPV6」",江苏卫视「IPV6」 43 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226310/index.m3u8 44 | #EXTINF:-1 tvg-name="东方卫视" tvg-logo="https://epg.iill.top/logo/东方卫视.png" group-title="•卫视「IPV6」",东方卫视「IPV6」 45 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226345/index.m3u8 46 | #EXTINF:-1 tvg-name="广东卫视" tvg-logo="https://epg.iill.top/logo/广东卫视.png" group-title="•卫视「IPV6」",广东卫视「IPV6」 47 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226248/index.m3u8 48 | #EXTINF:-1 tvg-name="广西卫视" tvg-logo="https://epg.iill.top/logo/广西卫视.png" group-title="•卫视「IPV6」",广西卫视「IPV6」 49 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226549/index.m3u8 50 | #EXTINF:-1 tvg-name="深圳卫视" tvg-logo="https://epg.iill.top/logo/深圳卫视.png" group-title="•卫视「IPV6」",深圳卫视「IPV6」 51 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226313/index.m3u8 52 | #EXTINF:-1 tvg-name="北京卫视" tvg-logo="https://epg.iill.top/logo/北京卫视.png" group-title="•卫视「IPV6」",北京卫视「IPV6」 53 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226450/index.m3u8 54 | #EXTINF:-1 tvg-name="东南卫视" tvg-logo="https://epg.iill.top/logo/东南卫视.png" group-title="•卫视「IPV6」",东南卫视「IPV6」 55 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226341/index.m3u8 56 | #EXTINF:-1 tvg-name="四川卫视" tvg-logo="https://epg.iill.top/logo/四川卫视.png" group-title="•卫视「IPV6」",四川卫视「IPV6」 57 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226338/index.m3u8 58 | #EXTINF:-1 tvg-name="天津卫视" tvg-logo="https://epg.iill.top/logo/天津卫视.png" group-title="•卫视「IPV6」",天津卫视「IPV6」 59 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226459/index.m3u8 60 | #EXTINF:-1 tvg-name="安徽卫视" tvg-logo="https://epg.iill.top/logo/安徽卫视.png" group-title="•卫视「IPV6」",安徽卫视「IPV6」 61 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226391/index.m3u8 62 | #EXTINF:-1 tvg-name="山东卫视" tvg-logo="https://epg.iill.top/logo/山东卫视.png" group-title="•卫视「IPV6」",山东卫视「IPV6」 63 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226456/index.m3u8 64 | #EXTINF:-1 tvg-name="江西卫视" tvg-logo="https://epg.iill.top/logo/江西卫视.png" group-title="•卫视「IPV6」",江西卫视「IPV6」 65 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226344/index.m3u8 66 | #EXTINF:-1 tvg-name="河北卫视" tvg-logo="https://epg.iill.top/logo/河北卫视.png" group-title="•卫视「IPV6」",河北卫视「IPV6 67 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226406/index.m3u8 68 | #EXTINF:-1 tvg-name="河南卫视" tvg-logo="https://epg.iill.top/logo/河南卫视.png" group-title="•卫视「IPV6」",河南卫视「IPV6」 69 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226480/index.m3u8 70 | #EXTINF:-1 tvg-name="海南卫视" tvg-logo="https://epg.iill.top/logo/海南卫视.png" group-title="•卫视「IPV6」",海南卫视「IPV6」 71 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226465/index.m3u8 72 | #EXTINF:-1 tvg-name="湖北卫视" tvg-logo="https://epg.iill.top/logo/湖北卫视.png" group-title="•卫视「IPV6」",湖北卫视「IPV6」 73 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226477/index.m3u8 74 | #EXTINF:-1 tvg-name="贵州卫视" tvg-logo="https://epg.iill.top/logo/贵州卫视.png" group-title="•卫视「IPV6」",贵州卫视「IPV6」 75 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226474/index.m3u8 76 | #EXTINF:-1 tvg-name="辽宁卫视" tvg-logo="https://epg.iill.top/logo/辽宁卫视.png" group-title="•卫视「IPV6」",辽宁卫视「IPV6 77 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226546/index.m3u8 78 | #EXTINF:-1 tvg-name="重庆卫视" tvg-logo="https://epg.iill.top/logo/重庆卫视.png" group-title="•卫视「IPV6」",重庆卫视「IPV6」 79 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226409/index.m3u8 80 | #EXTINF:-1 tvg-name="吉林卫视" tvg-logo="https://epg.iill.top/logo/吉林卫视.png" group-title="•卫视「IPV6」",吉林卫视「IPV6」 81 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226397/index.m3u8 82 | #EXTINF:-1 tvg-name="黑龙江卫视" tvg-logo="https://epg.iill.top/logo/黑龙江卫视.png" group-title="•卫视「IPV6」",黑龙江卫视「IPV6」 83 | http://[2409:8087:1a01:df::7005]/ottrrs.hl.chinamobile.com/PLTV/88888888/224/3221226327/index.m3u8 84 | -------------------------------------------------------------------------------- /ltyd.py: -------------------------------------------------------------------------------- 1 | import requests 2 | import time 3 | 4 | 5 | '''' 6 | accesstoken,phoneNumber 搜索抓包,参数在请求头 7 | 8 | 开抓包看满15分钟 抽一次奖,下面参数都在请求体 9 | sign1 抓包搜newreadadd 10 | sign2 抓包搜 addDrawTimes 11 | sign3 抓包搜 addReadTime 12 | acticeindex 抓包搜 doDraw 13 | ''' 14 | 15 | accesstoken = "" 16 | phoneNumber4net = "" 17 | 18 | # pushplus+推送,没有不写 19 | token = '' 20 | topic = '' 21 | 22 | sign1='' 23 | 24 | sign2="" 25 | 26 | sign3="" 27 | 28 | acticeindex="" 29 | 30 | 31 | class Main(): 32 | def __init__(self,accesstoken,phoneNumber4net,token,topic,sign1,sign2,sign3,acticeindex): 33 | self.headers = { 34 | "accesstoken": accesstoken, 35 | } 36 | self.cookies = { 37 | "useraccount": phoneNumber4net, 38 | "phoneNumber4net": phoneNumber4net, 39 | } 40 | self.token = token 41 | self.topic = topic 42 | self.sign1 = sign1 43 | self.sign2 = sign2 44 | self.sign3 = sign3 45 | self.acticeindex = acticeindex 46 | 47 | 48 | self.messsage = '>>> 沃阅读抽奖:\n\n' 49 | 50 | for i in range(32): 51 | self.newreadadd() #获取阅读 52 | self.addDrawTime() #开始阅读 53 | self.addReadtime() #完成阅读 54 | self.lottery() #开始抽奖 55 | self.push_notifacation() 56 | 57 | print('--------抽奖完成!--------\n\n') 58 | print('----------by: Dreamfeelings') 59 | #获取阅读 60 | def newreadadd(self): 61 | time.sleep(2) 62 | print('\n--------获取阅读任务!--------\n') 63 | url = "https://10010.woread.com.cn/ng_woread_service/rest/basics/newreadadd" 64 | data = { 65 | "sign": self.sign1 66 | } 67 | response = requests.post(url, headers=self.headers, cookies=self.cookies, json=data) 68 | print(response.text) 69 | 70 | #开始阅读 71 | def addDrawTime(self): 72 | time.sleep(2) 73 | print('\n--------开始阅读!--------\n') 74 | data = { 75 | "sign": self.sign2 76 | } 77 | url = "https://10010.woread.com.cn/ng_woread_service/rest/basics/addDrawTimes" 78 | response = requests.post(url, headers=self.headers, cookies=self.cookies, json=data) 79 | print(response.text) 80 | 81 | print('正在阅读: ') 82 | # for i in tqdm(range(1000)): 83 | for i in range(120): 84 | time.sleep(1) 85 | print('阅读完成!\n') 86 | 87 | #完成阅读 88 | def addReadtime(self): 89 | time.sleep(2) 90 | print('\n--------正在完成阅读任务!--------\n') 91 | data = { 92 | "sign": self.sign3 93 | } 94 | url = "https://10010.woread.com.cn/ng_woread_service/rest/history/addReadTime" 95 | response = requests.post(url, headers=self.headers, cookies=self.cookies, json=data).json() 96 | 97 | if response['code'] == '0000' : 98 | print(response) 99 | print('阅读任务提交成功!') 100 | return 1 101 | else: 102 | time.sleep(5) 103 | response = requests.post(url, headers=self.headers, cookies=self.cookies, json=data).json() 104 | if response['code'] == '0000' : 105 | print(response) 106 | print('阅读任务提交成功!') 107 | return 1 108 | else: 109 | print(response) 110 | print('阅读任务提交失败!') 111 | 112 | #开始抽奖 113 | def lottery(self): 114 | print('\n--------开始抽奖!--------\n\n') 115 | time.sleep(3) 116 | 117 | data = { 118 | "acticeindex": self.acticeindex, 119 | "t": int(time.time()) 120 | } 121 | url = "https://10010.woread.com.cn/touchextenernal/actsub/doDraw.action" 122 | response = requests.post(url, headers=self.headers, cookies=self.cookies, data=data).json() 123 | print(response) 124 | try: 125 | if response['prizedesc'] != '': 126 | self.messsage += response['prizedesc'] 127 | except: 128 | pass 129 | 130 | #推送消息 131 | def push_notifacation(self): 132 | title = '联通任务通知: ' 133 | content = self.messsage 134 | 135 | url = 'http://www.pushplus.plus/send' 136 | data = { 137 | 'token': self.token, 138 | 'title': title, 139 | 'content': content, 140 | "topic": self.topic 141 | } 142 | 143 | res = requests.post(url, data=data).json() 144 | # print(res) 145 | try: 146 | status = '推送成功!' if res['code'] == 200 else res['msg'] 147 | print(status) 148 | except: 149 | print('推送异常!') 150 | 151 | if __name__ == '__main__': 152 | Main(accesstoken,phoneNumber4net,token,topic,sign1,sign2,sign3,acticeindex) -------------------------------------------------------------------------------- /raw_master_ysf.js: -------------------------------------------------------------------------------- 1 | /** 2 | * 变量 3 | * export ysfAuthorization='XXXXXXXXX' 4 | * 多号@或换行 5 | * cron 0 0 * * * ysf.js 6 | */ 7 | const $ = new Env('云闪付签到') 8 | const axios = require('axios'); 9 | let request = require("request"); 10 | request = request.defaults({ 11 | jar: true 12 | }); 13 | const { 14 | log 15 | } = console; 16 | const Notify = 1; //0为关闭通知,1为打开通知,默认为1 17 | const debug = 1; //0为关闭调试,1为打开调试,默认为0 18 | // if ($.isNode()) { 19 | // console.log('node环境'); 20 | // } else { 21 | // console.log('非node环境'); 22 | // } 23 | 24 | //此处填写京东账号cookie。 25 | // let Authorization = [] 26 | 27 | // 判断环境变量里面是否有云闪付Authorization 28 | // if (process.env.ysfAuthorization) { 29 | // if (process.env.ysfAuthorization.indexOf('&') > -1) { 30 | // Authorization = process.env.ysfAuthorization.split('&'); 31 | // } else if (process.env.ysfAuthorization.indexOf('\n') > -1) { 32 | // Authorization = process.env.ysfAuthorization.split('\n'); 33 | // } else { 34 | // Authorization = [process.env.ysfAuthorization]; 35 | // } 36 | // } 37 | 38 | // console.log('Authorization', Authorization); 39 | 40 | // 去重 41 | // Authorization = [...new Set(Authorization.filter(item => !!item))] 42 | 43 | // console.log(`\n====================共${Authorization.length}个云闪付账号=========\n`); 44 | let ysfAuthorization = ($.isNode() ? process.env.ysfAuthorization : $.getdata("ysfAuthorization")) || "" 45 | let ysfAuthorizationArr = []; 46 | let data = ''; 47 | let msg = ''; 48 | // var hours = new Date().getMonth(); 49 | /** 50 | * 签到 51 | * @param {any} item 数据项 52 | * @returns 53 | */ 54 | async function signIn (item) { 55 | return new Promise((resolve) => { 56 | const options = { 57 | method: 'POST', 58 | url: 'https://youhui.95516.com/newsign/api/daily_sign_in', 59 | headers: { 60 | // Host: 'youhui.95516.com', 61 | Accept: '*/*', 62 | Authorization: `Bearer ${item}`, 63 | 64 | 'Accept-Encoding': 'gzip, deflate, br', 65 | 'Content-Type': 'application/json', 66 | // 'Origin': 'https://youhui.95516.com', 67 | 'Content-Length': 2, 68 | // 'User-Agent': 'Mozilla/5.0 (iPhone; CPU iPhone OS 16_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 /sa-sdk-ios/sensors-verify/analytics.95516.com?production (com.unionpay.chsp) (cordova 4.5.4) (updebug 0) (version 929) (UnionPay/1.0 CloudPay) (clientVersion 189) (language zh_CN) (upHtml) (walletMode 00) ', 69 | // 'Referer': 'https://youhui.95516.com/newsign/public/app/index.html', 70 | 'Connection': 'keep-alive', 71 | }, 72 | } 73 | if (debug) { 74 | log(`\n【debug】=============== 这是 请求 url ===============`); 75 | log(JSON.stringify(options)); 76 | } 77 | axios.request(options).then(async function (response) { 78 | try { 79 | log('response:', response) 80 | data = response.data; 81 | if (debug) { 82 | log(`\n\n【debug】===============这是 返回data==============`); 83 | log(JSON.stringify(response.data)); 84 | } 85 | if (data.code == 200) { 86 | log(data.message) 87 | } else 88 | log(data.message) 89 | 90 | 91 | 92 | } catch (e) { 93 | log(`异常:${data},原因:${data.message}`) 94 | } 95 | }).catch(function (error) { 96 | console.error(error); 97 | }).then(res => { 98 | //这里处理正确返回 99 | resolve(); 100 | }); 101 | }) 102 | 103 | } 104 | 105 | async function Envs () { 106 | if (ysfAuthorization) { 107 | if (ysfAuthorization.indexOf("@") != -1) { 108 | ysfAuthorization.split("@").forEach((item) => { 109 | 110 | ysfAuthorizationArr.push(item); 111 | }); 112 | } else if (ysfAuthorization.indexOf("\n") != -1) { 113 | ysfAuthorization.split("\n").forEach((item) => { 114 | ysfAuthorizationArr.push(item); 115 | }); 116 | } else { 117 | ysfAuthorizationArr.push(ysfAuthorization); 118 | } 119 | } else { 120 | log(`\n 【${$.name}】:未填写变量 ysfAuthorization`) 121 | return; 122 | } 123 | 124 | return true; 125 | } 126 | 127 | function addNotifyStr (str, is_log = true) { 128 | if (is_log) { 129 | log(`${str}\n`) 130 | } 131 | msg += `${str}\n` 132 | } 133 | 134 | var timestamp = Math.round(new Date().getTime() / 1000).toString(); 135 | !(async () => { 136 | if (typeof $request !== "undefined") { 137 | await GetRewrite(); 138 | } else { 139 | if (!(await Envs())) 140 | return; 141 | else { 142 | 143 | log(`\n\n============================================= \n脚本执行 - 北京时间(UTC+8):${new Date( 144 | new Date().getTime() + new Date().getTimezoneOffset() * 60 * 1000 + 145 | 8 * 60 * 60 * 1000).toLocaleString()} \n=============================================\n`); 146 | 147 | 148 | 149 | // log(`\n============ 微信公众号:柠檬玩机交流 ============`) 150 | log(`\n=================== 共找到 ${ysfAuthorizationArr.length} 个账号 ===================`) 151 | if (debug) { 152 | log(`【debug】 这是你的全部账号数组:\n ${ysfAuthorizationArr}`); 153 | } 154 | for (let index = 0; index < ysfAuthorizationArr.length; index++) { 155 | 156 | let num = index + 1 157 | addNotifyStr(`\n==== 开始【第 ${num} 个账号】====\n`, true) 158 | 159 | ysfAuthorization = ysfAuthorizationArr[index]; 160 | await signIn(ysfAuthorization) 161 | } 162 | await SendMsg(msg); 163 | } 164 | } 165 | })() 166 | .catch((e) => log(e)) 167 | .finally(() => $.done()) 168 | 169 | // !(async () => { 170 | // Authorization.forEach((item) => { 171 | // await signIn(item) 172 | // }) 173 | // }) 174 | 175 | /** 176 | * 发送消息 177 | * @param {string} message 消息 178 | * @returns 179 | */ 180 | async function SendMsg (message) { 181 | if (!message) 182 | return; 183 | 184 | if (Notify > 0) { 185 | if ($.isNode()) { 186 | var notify = require('./sendNotify'); 187 | await notify.sendNotify($.name, message); 188 | } else { 189 | $.msg(message); 190 | } 191 | } else { 192 | log(message); 193 | } 194 | } 195 | 196 | function Env (t, e) { 197 | "undefined" != typeof process && JSON.stringify(process.env).indexOf("GITHUB") > -1 && process.exit(0); 198 | 199 | class s { 200 | constructor(t) { this.env = t } 201 | 202 | send (t, e = "GET") { 203 | t = "string" == typeof t ? { url: t } : t; 204 | let s = this.get; 205 | return "POST" === e && (s = this.post), new Promise((e, i) => { s.call(this, t, (t, s, r) => { t ? i(t) : e(s) }) }) 206 | } 207 | 208 | get (t) { return this.send.call(this.env, t) } 209 | 210 | post (t) { return this.send.call(this.env, t, "POST") } 211 | } 212 | 213 | return new class { 214 | 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}, 开始!`) } 215 | 216 | isNode () { return "undefined" != typeof module && !!module.exports } 217 | 218 | isQuanX () { return "undefined" != typeof $task } 219 | 220 | isSurge () { return "undefined" != typeof $httpClient && "undefined" == typeof $loon } 221 | 222 | isLoon () { return "undefined" != typeof $loon } 223 | 224 | toObj (t, e = null) { try { return JSON.parse(t) } catch { return e } } 225 | 226 | toStr (t, e = null) { try { return JSON.stringify(t) } catch { return e } } 227 | 228 | getjson (t, e) { 229 | let s = e; 230 | const i = this.getdata(t); 231 | if (i) try { s = JSON.parse(this.getdata(t)) } catch { } 232 | return s 233 | } 234 | 235 | setjson (t, e) { try { return this.setdata(JSON.stringify(t), e) } catch { return !1 } } 236 | 237 | getScript (t) { return new Promise(e => { this.get({ url: t }, (t, s, i) => e(i)) }) } 238 | 239 | runScript (t, e) { 240 | return new Promise(s => { 241 | let i = this.getdata("@chavy_boxjs_userCfgs.httpapi"); 242 | i = i ? i.replace(/\n/g, "").trim() : i; 243 | let r = this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout"); 244 | r = r ? 1 * r : 20, r = e && e.timeout ? e.timeout : r; 245 | const [o, h] = i.split("@"), n = { 246 | url: `http://${h}/v1/scripting/evaluate`, 247 | body: { script_text: t, mock_type: "cron", timeout: r }, 248 | headers: { "X-Key": o, Accept: "*/*" } 249 | }; 250 | this.post(n, (t, e, i) => s(i)) 251 | }).catch(t => this.logErr(t)) 252 | } 253 | 254 | loaddata () { 255 | if (!this.isNode()) return {}; 256 | { 257 | this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); 258 | const t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), 259 | s = this.fs.existsSync(t), i = !s && this.fs.existsSync(e); 260 | if (!s && !i) return {}; 261 | { 262 | const i = s ? t : e; 263 | try { return JSON.parse(this.fs.readFileSync(i)) } catch (t) { return {} } 264 | } 265 | } 266 | } 267 | 268 | writedata () { 269 | if (this.isNode()) { 270 | this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); 271 | const t = this.path.resolve(this.dataFile), e = this.path.resolve(process.cwd(), this.dataFile), 272 | s = this.fs.existsSync(t), i = !s && this.fs.existsSync(e), r = JSON.stringify(this.data); 273 | s ? this.fs.writeFileSync(t, r) : i ? this.fs.writeFileSync(e, r) : this.fs.writeFileSync(t, r) 274 | } 275 | } 276 | 277 | lodash_get (t, e, s) { 278 | const i = e.replace(/\[(\d+)\]/g, ".$1").split("."); 279 | let r = t; 280 | for (const t of i) if (r = Object(r)[t], void 0 === r) return s; 281 | return r 282 | } 283 | 284 | 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) } 285 | 286 | getdata (t) { 287 | let e = this.getval(t); 288 | if (/^@/.test(t)) { 289 | const [, s, i] = /^@(.*?)\.(.*?)$/.exec(t), r = s ? this.getval(s) : ""; 290 | if (r) try { 291 | const t = JSON.parse(r); 292 | e = t ? this.lodash_get(t, i, "") : e 293 | } catch (t) { e = "" } 294 | } 295 | return e 296 | } 297 | 298 | setdata (t, e) { 299 | let s = !1; 300 | if (/^@/.test(e)) { 301 | const [, i, r] = /^@(.*?)\.(.*?)$/.exec(e), o = this.getval(i), 302 | h = i ? "null" === o ? null : o || "{}" : "{}"; 303 | try { 304 | const e = JSON.parse(h); 305 | this.lodash_set(e, r, t), s = this.setval(JSON.stringify(e), i) 306 | } catch (e) { 307 | const o = {}; 308 | this.lodash_set(o, r, t), s = this.setval(JSON.stringify(o), i) 309 | } 310 | } else s = this.setval(t, e); 311 | return s 312 | } 313 | 314 | 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 } 315 | 316 | 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 } 317 | 318 | 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)) } 319 | 320 | get (t, e = (() => { })) { 321 | t.headers && (delete t.headers["Content-Type"], delete t.headers["Content-Length"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.get(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { 322 | const { 323 | statusCode: s, 324 | statusCode: i, 325 | headers: r, 326 | body: o 327 | } = t; 328 | e(null, { status: s, statusCode: i, headers: r, body: o }, o) 329 | }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { 330 | try { 331 | if (t.headers["set-cookie"]) { 332 | const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); 333 | s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar 334 | } 335 | } catch (t) { this.logErr(t) } 336 | }).then(t => { 337 | const { statusCode: s, statusCode: i, headers: r, body: o } = t; 338 | e(null, { status: s, statusCode: i, headers: r, body: o }, o) 339 | }, t => { 340 | const { message: s, response: i } = t; 341 | e(s, i, i && i.body) 342 | })) 343 | } 344 | 345 | post (t, e = (() => { })) { 346 | if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.post(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) }); else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { 347 | const { 348 | statusCode: s, 349 | statusCode: i, 350 | headers: r, 351 | body: o 352 | } = t; 353 | e(null, { status: s, statusCode: i, headers: r, body: o }, o) 354 | }, t => e(t)); else if (this.isNode()) { 355 | this.initGotEnv(t); 356 | const { url: s, ...i } = t; 357 | this.got.post(s, i).then(t => { 358 | const { statusCode: s, statusCode: i, headers: r, body: o } = t; 359 | e(null, { status: s, statusCode: i, headers: r, body: o }, o) 360 | }, t => { 361 | const { message: s, response: i } = t; 362 | e(s, i, i && i.body) 363 | }) 364 | } 365 | } 366 | 367 | time (t, e = null) { 368 | const s = e ? new Date(e) : new Date; 369 | let i = { 370 | "M+": s.getMonth() + 1, 371 | "d+": s.getDate(), 372 | "H+": s.getHours(), 373 | "m+": s.getMinutes(), 374 | "s+": s.getSeconds(), 375 | "q+": Math.floor((s.getMonth() + 3) / 3), 376 | S: s.getMilliseconds() 377 | }; 378 | /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); 379 | for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); 380 | return t 381 | } 382 | 383 | msg (e = t, s = "", i = "", r) { 384 | const o = t => { 385 | if (!t) return t; 386 | if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { "open-url": t } : this.isSurge() ? { url: t } : void 0; 387 | if ("object" == typeof t) { 388 | if (this.isLoon()) { 389 | let e = t.openUrl || t.url || t["open-url"], s = t.mediaUrl || t["media-url"]; 390 | return { openUrl: e, mediaUrl: s } 391 | } 392 | if (this.isQuanX()) { 393 | let e = t["open-url"] || t.url || t.openUrl, s = t["media-url"] || t.mediaUrl; 394 | return { "open-url": e, "media-url": s } 395 | } 396 | if (this.isSurge()) { 397 | let e = t.url || t.openUrl || t["open-url"]; 398 | return { url: e } 399 | } 400 | } 401 | }; 402 | if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { 403 | let t = ["", "==============📣系统通知📣=============="]; 404 | t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) 405 | } 406 | } 407 | 408 | log (...t) { t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) } 409 | 410 | logErr (t, e) { 411 | const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); 412 | s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) 413 | } 414 | 415 | wait (t) { return new Promise(e => setTimeout(e, t)) } 416 | 417 | done (t = {}) { 418 | const e = (new Date).getTime(), s = (e - this.startTime) / 1e3; 419 | this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) 420 | } 421 | }(t, e) 422 | } -------------------------------------------------------------------------------- /shpj.js: -------------------------------------------------------------------------------- 1 | /* 2 | 诗画浦江 app 3 | 4 | cron 10 8,10 * * * shpj.js 5 | 6 | ========= 青龙--配置文件--贴心复制区域 ========= 7 | # 诗画浦江 8 | export shpj=' x-session-id & x-request-id ' 9 | 10 | 11 | 多账号用 换行 或 @ 分割 12 | tg频道: https://t.me/yml2213_tg 13 | */ 14 | 15 | 16 | const utils = require("yml2213-utils") 17 | const $ = new Env("诗画浦江") // 1.名字改了 18 | const ckName = "shpj" // 2. 英文名字改一下 19 | //-------------------- 一般不动变量区域 ------------------------------------- // 3. 不用管 20 | const notify = $.isNode() ? require("./sendNotify") : "" 21 | const Notify = 1 //0为关闭通知,1为打开通知,默认为1 22 | let envSplitor = ["@", "\n"] 23 | let ck = msg = '' 24 | let host, hostname 25 | let userCookie = process.env[ckName] 26 | let userList = [] 27 | let userIdx = 0 28 | let userCount = 0 29 | //---------------------- 自定义变量区域 ----------------------------------- // 4. 要杀变量自己加 30 | 31 | let app_id = 14 32 | let text = sign = '' 33 | //--------------------------------------------------------- 34 | 35 | async function start() { // 5. 开始任务区域 自己按照格式加 36 | 37 | 38 | console.log('\n================== 用户信息 ==================\n') 39 | taskall = [] 40 | for (let user of userList) { 41 | taskall.push(user.user_info('用户信息')) 42 | } 43 | await Promise.all(taskall) 44 | 45 | console.log('\n================== 任务列表 ==================\n') 46 | taskall = [] 47 | for (let user of userList) { 48 | taskall.push(user.task_list('任务列表')) 49 | } 50 | await Promise.all(taskall) 51 | 52 | 53 | 54 | } 55 | 56 | // 6. 一整个class 就是完整的任务 57 | class UserInfo { 58 | constructor(str) { // 7. 构造函数 处理变量等 用 this 挂在对象上 59 | this.index = ++userIdx 60 | this.ck = str.split('&') 61 | this.xs = this.ck[0] 62 | this.xr = this.ck[1] 63 | this.salt = 'FR*r!isE5W' 64 | this.id = app_id 65 | this.ts = utils.ts13() 66 | } 67 | 68 | 69 | // 8. 每个函数实现一个功能 70 | async signin(name) { //签到 71 | let path = '/api/user_mumber/sign' 72 | let sign = this.get_sign(path) 73 | 74 | let options = { //9. 就是组成请求的数据 75 | method: "Get", 76 | url: `https://vapp.tmuyun.com${path}`, // 9. url 77 | headers: { // 9. headers 78 | "X-SESSION-ID": this.xs, 79 | "X-REQUEST-ID": this.xr, 80 | "X-TIMESTAMP": this.ts, 81 | "X-SIGNATURE": sign, 82 | "Cache-Control": `no-cache`, 83 | "X-TENANT-ID": `14`, 84 | 'Host': 'vapp.tmuyun.com', 85 | }, 86 | } 87 | 88 | // console.log(options); 89 | let result = await httpRequest(name, options) // 10. 请求返回 result 90 | 91 | // console.log(result); 92 | if (result.code == 0) { // 11. 返回 result判断 93 | DoubleLog(`账号[${this.index}] ${name}" ${result.data.reason}, 获得积分 ${result.data.signIntegral}`) 94 | await utils.wait(3) 95 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 96 | 97 | 98 | 99 | 100 | } 101 | 102 | 103 | async user_info(name) { // 用户信息 104 | let path = '/api/user_mumber/account_detail' 105 | let sign = this.get_sign(path) 106 | 107 | let options = { 108 | method: "Get", 109 | url: `https://vapp.tmuyun.com${path}`, 110 | headers: { 111 | "X-SESSION-ID": this.xs, 112 | "X-REQUEST-ID": this.xr, 113 | "X-TIMESTAMP": this.ts, 114 | "X-SIGNATURE": sign, 115 | "Cache-Control": `no-cache`, 116 | "X-TENANT-ID": `14`, 117 | 'Host': 'vapp.tmuyun.com', 118 | }, 119 | } 120 | 121 | // console.log(options); 122 | let result = await httpRequest(name, options) 123 | 124 | // console.log(result); 125 | if (result.code == 0) { 126 | DoubleLog(`账号[${this.index}] ${result.data.rst.nick_name}, 手机号: ${utils.phone_num(result.data.rst.mobile)}, 积分 ${result.data.rst.total_integral}, 等级 ${result.data.rst.grade} ${result.data.rst.grade_name}`) 127 | this.nickname = result.data.rst.nick_name 128 | 129 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 130 | 131 | 132 | 133 | 134 | } 135 | 136 | // 任务列表 completed 0 未完成 1 完成 137 | async task_list(name) { 138 | let path = '/api/user_mumber/numberCenter' 139 | let sign = this.get_sign(path) 140 | 141 | let options = { 142 | method: "Get", 143 | url: `https://vapp.tmuyun.com${path}`, 144 | headers: { 145 | "X-SESSION-ID": this.xs, 146 | "X-REQUEST-ID": this.xr, 147 | "X-TIMESTAMP": this.ts, 148 | "X-SIGNATURE": sign, 149 | "Cache-Control": `no-cache`, 150 | "X-TENANT-ID": `14`, 151 | 'Host': 'vapp.tmuyun.com', 152 | }, 153 | } 154 | 155 | // console.log(options); 156 | let result = await httpRequest(name, options) 157 | 158 | // console.log(result); 159 | if (result.code == 0) { 160 | let tasks = result.data.rst.user_task_list 161 | // console.log(tasks); 162 | for (const task of tasks) { // completed 0 未完成 1 完成 163 | this.task_name = task.name 164 | this.finish_times = task.finish_times 165 | this.frequency = task.frequency 166 | if (task.completed == 0) { 167 | if (task.id == 133) { // 每日签到 168 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 169 | await this.signin(this.task_name) 170 | } 171 | if (task.id == 134) { // 新闻资讯阅读 172 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 173 | let num = this.frequency - this.finish_times 174 | for (let index = 0; index < num; index++) { 175 | await this.read(this.task_name) 176 | } 177 | } 178 | if (task.id == 135) { // 分享资讯给好友 179 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 180 | let num = this.frequency - this.finish_times 181 | for (let index = 0; index < num; index++) { 182 | await this.share(this.task_name) 183 | } 184 | } 185 | if (task.id == 136) { // 新闻资讯评论 186 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 187 | let num = this.frequency - this.finish_times 188 | for (let index = 0; index < num; index++) { 189 | await this.comment(this.task_name) 190 | } 191 | } 192 | if (task.id == 137) { // 新闻资讯点赞 193 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 194 | let num = this.frequency - this.finish_times 195 | for (let index = 0; index < num; index++) { 196 | await this.like(this.task_name) 197 | } 198 | } 199 | if (task.id == 138) { // 使用本地服务 200 | DoubleLog(`账号 ${this.nickname} : ${this.task_name}----${this.finish_times}/${this.frequency}`) 201 | await this.local_srv(this.task_name) 202 | } 203 | 204 | } else DoubleLog(`${this.task_name}: 已完成`) 205 | } 206 | 207 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 208 | } 209 | 210 | 211 | async artic(name) { // 获取文章 212 | let path = '/api/article/channel_list' 213 | let sign = this.get_sign(path) 214 | let a = utils.randomInt(1, 5) 215 | 216 | let options = { 217 | method: "Get", 218 | url: `https://vapp.tmuyun.com${path}?channel_id=5cc2ccbe1b011b18ee37591d&isDiFangHao=false&is_new=true&list_count=${a * 10}&size=10&start=${this.ts}`, 219 | headers: { 220 | "X-SESSION-ID": this.xs, 221 | "X-REQUEST-ID": this.xr, 222 | "X-TIMESTAMP": this.ts, 223 | "X-SIGNATURE": sign, 224 | "Cache-Control": `no-cache`, 225 | "X-TENANT-ID": `14`, 226 | 'Host': 'vapp.tmuyun.com', 227 | }, 228 | } 229 | 230 | // console.log(options); 231 | let result = await httpRequest(name, options) 232 | 233 | // console.log(result); 234 | if (result.code == 0) { 235 | DoubleLog(`账号[${this.index}] ${name}, ok`) 236 | let p = utils.randomInt(0, 9) 237 | this.rid = result.data.article_list[p].id 238 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 239 | } 240 | 241 | async read(name) { // 新闻资讯阅读 242 | await this.artic('获取文章') 243 | 244 | let path = '/api/article/detail' 245 | let sign = this.get_sign(path) 246 | 247 | let options = { 248 | method: "Get", 249 | url: `https://vapp.tmuyun.com${path}?id=${this.rid}`, 250 | headers: { 251 | "X-SESSION-ID": this.xs, 252 | "X-REQUEST-ID": this.xr, 253 | "X-TIMESTAMP": this.ts, 254 | "X-SIGNATURE": sign, 255 | "Cache-Control": `no-cache`, 256 | "X-TENANT-ID": `14`, 257 | 'Host': 'vapp.tmuyun.com', 258 | }, 259 | } 260 | let result = await httpRequest(name, options) 261 | 262 | // console.log(result); 263 | if (result.code == 0) { 264 | DoubleLog(`账号[${this.index}] ${name}, 文章ID${this.rid} ${result.data.article.list_title}`) 265 | await wait(3) 266 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 267 | } 268 | 269 | async share(name) { // 分享资讯给好友 270 | await this.artic('获取文章') 271 | 272 | let path = '/api/user_mumber/doTask' 273 | let sign = this.get_sign(path) 274 | 275 | let options = { 276 | method: "POST", 277 | url: `https://vapp.tmuyun.com${path}`, 278 | headers: { 279 | "X-SESSION-ID": this.xs, 280 | "X-REQUEST-ID": this.xr, 281 | "X-TIMESTAMP": this.ts, 282 | "X-SIGNATURE": sign, 283 | "Cache-Control": `no-cache`, 284 | "X-TENANT-ID": `14`, 285 | 'Host': 'vapp.tmuyun.com', 286 | "Content-Type": `application/x-www-form-urlencoded`, 287 | }, 288 | form: { 289 | 'memberType': '3', 290 | 'member_type': '3' 291 | } 292 | } 293 | let result = await httpRequest(name, options) 294 | 295 | // console.log(result); 296 | if (result.code == 0) { 297 | DoubleLog(`账号[${this.index}] ${name} :文章ID ${this.rid}, ok}`) 298 | await wait(3) 299 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 300 | } 301 | 302 | async comment(name) { // 新闻资讯评论 303 | await this.artic('获取文章') 304 | 305 | let path = '/api/comment/create' 306 | let sign = this.get_sign(path) 307 | 308 | let options = { 309 | method: "POST", 310 | url: `https://vapp.tmuyun.com${path}`, 311 | headers: { 312 | "X-SESSION-ID": this.xs, 313 | "X-REQUEST-ID": this.xr, 314 | "X-TIMESTAMP": this.ts, 315 | "X-SIGNATURE": sign, 316 | "Cache-Control": `no-cache`, 317 | "X-TENANT-ID": `14`, 318 | 'Host': 'vapp.tmuyun.com', 319 | "Content-Type": `application/x-www-form-urlencoded`, 320 | }, 321 | form: { 322 | 'channel_article_id': this.rid, 323 | 'content': 1 324 | } 325 | } 326 | let result = await httpRequest(name, options) 327 | 328 | // console.log(result); 329 | if (result.code == 0) { 330 | DoubleLog(`账号[${this.index}] ${name} :文章ID ${this.rid}, ok}`) 331 | await wait(3) 332 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 333 | } 334 | 335 | async like(name) { // 新闻资讯点赞 336 | await this.artic('获取文章') 337 | 338 | let path = '/api/favorite/like' 339 | let sign = this.get_sign(path) 340 | 341 | let options = { 342 | method: "POST", 343 | url: `https://vapp.tmuyun.com${path}`, 344 | headers: { 345 | "X-SESSION-ID": this.xs, 346 | "X-REQUEST-ID": this.xr, 347 | "X-TIMESTAMP": this.ts, 348 | "X-SIGNATURE": sign, 349 | "Cache-Control": `no-cache`, 350 | "X-TENANT-ID": `14`, 351 | 'Host': 'vapp.tmuyun.com', 352 | "Content-Type": `application/x-www-form-urlencoded`, 353 | }, 354 | form: { 355 | 'id': this.rid, 356 | 'action': true 357 | } 358 | } 359 | let result = await httpRequest(name, options) 360 | 361 | // console.log(result); 362 | if (result.code == 0) { 363 | DoubleLog(`账号[${this.index}] ${name} :文章ID ${this.rid}, ok}`) 364 | await wait(3) 365 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 366 | } 367 | 368 | async local_srv(name) { // 使用本地服务 369 | await this.artic('获取文章') 370 | 371 | let path = '/api/user_mumber/doTas' 372 | let sign = this.get_sign(path) 373 | 374 | let options = { 375 | method: "POST", 376 | url: `https://vapp.tmuyun.com${path}`, 377 | headers: { 378 | "X-SESSION-ID": this.xs, 379 | "X-REQUEST-ID": this.xr, 380 | "X-TIMESTAMP": this.ts, 381 | "X-SIGNATURE": sign, 382 | "Cache-Control": `no-cache`, 383 | "X-TENANT-ID": `14`, 384 | 'Host': 'vapp.tmuyun.com', 385 | "Content-Type": `application/x-www-form-urlencoded`, 386 | }, 387 | form: { 388 | 'memberType': 6, 389 | 'member_type': 6 390 | } 391 | } 392 | let result = await httpRequest(name, options) 393 | 394 | // console.log(result); 395 | if (result.code == 0) { 396 | DoubleLog(`账号[${this.index}] ${name} : 成功 获得 ${result.data.score_notify.integral} 积分`) 397 | await wait(3) 398 | } else DoubleLog(`账号[${this.index}] ${name} 失败❌了呢`), console.log(result) 399 | } 400 | 401 | 402 | 403 | get_sign(path) { 404 | let _data = `${path}&&${this.xs}&&${this.xr}&&${this.ts}&&${this.salt}&&${this.id}` 405 | // console.log('_data: ', _data); 406 | sign = utils.SHA256_Encrypt(_data) 407 | return sign 408 | } 409 | 410 | 411 | 412 | 413 | } 414 | 415 | !(async () => { 416 | if (!(await checkEnv())) return 417 | if (userList.length > 0) { 418 | await start() 419 | } 420 | await SendMsg(msg) 421 | })() 422 | .catch((e) => console.log(e)) 423 | .finally(() => $.done()) 424 | 425 | 426 | 427 | // 下面的不用管了 全默认就行 记得装 yml2213-utils 依赖 428 | // #region ******************************************************** 固定代码 ******************************************************** 429 | 430 | 431 | // 变量检查与处理 432 | async function checkEnv() { 433 | if (userCookie) { 434 | // console.log(userCookie); 435 | let e = envSplitor[0] 436 | for (let o of envSplitor) 437 | if (userCookie.indexOf(o) > -1) { 438 | e = o 439 | break 440 | } 441 | for (let n of userCookie.split(e)) n && userList.push(new UserInfo(n)) 442 | userCount = userList.length 443 | } else { 444 | console.log("未找到CK") 445 | return 446 | } 447 | return console.log(`共找到${userCount}个账号`), !0 448 | } 449 | 450 | 451 | 452 | // =========================================== 不懂不要动 ========================================================= 453 | function Env(name, e) { class s { constructor(name) { this.env = name } } return new (class { constructor(name) { (this.name = name), (this.logs = []), (this.startTime = new Date().getTime()), this.log(`\n🔔${this.name}, 开始!`) } isNode() { return "undefined" != typeof module && !!module.exports } log(...name) { name.length > 0 && (this.logs = [...this.logs, ...name]), console.log(name.join(this.logSeparator)) } done() { const e = new Date().getTime(), s = (e - this.startTime) / 1e3; this.log(`\n🔔${this.name}, 结束! 🕛 ${s} 秒`) } })(name, e) } async function httpRequest(name, options) { if (!name) { name = /function\s*(\w*)/i.exec(arguments.callee.toString())[1] } try { let result = await utils.httpRequest(name, options); if (result) { return result } { DoubleLog(`未知错误(1)`) } } catch (error) { console.log(error) } } async function SendMsg(message) { if (!message) return; if (Notify > 0) { if ($.isNode()) { var notify = require("../sendNotify"); await notify.sendNotify($.name, message) } else { console.log($.name, "", message) } } else { console.log(message) } } function wait(n) { return new Promise(function (resolve) { setTimeout(resolve, n * 1000) }) } function DoubleLog(data) { console.log(` ${data}`); msg += `\n ${data}` } 454 | 455 | -------------------------------------------------------------------------------- /smzdm_auto_sign_bot.py: -------------------------------------------------------------------------------- 1 | """ 2 | 什么值得买自动签到脚本 3 | 4 | 借鉴(copy)自lws1122,fork 自:https://gitee.com/lsw1122/smzdm_bot 5 | """ 6 | ''' 7 | cron: 0 1 * * * smzdm_auto_sign_bot.py 8 | new Env('张大妈自动签到'); 9 | ''' 10 | 11 | import requests, os, datetime, sys 12 | from sys import argv 13 | import requests 14 | import json 15 | import time 16 | import hmac 17 | import hashlib 18 | import base64 19 | import urllib.parse 20 | 21 | """ 22 | http headers 23 | """ 24 | DEFAULT_HEADERS = { 25 | 'Accept': '*/*', 26 | 'Accept-Encoding': 'gzip, deflate, br', 27 | 'Accept-Language': 'zh-CN,zh;q=0.9', 28 | 'Connection': 'keep-alive', 29 | 'Host': 'zhiyou.smzdm.com', 30 | 'Referer': 'https://www.smzdm.com/', 31 | 'Sec-Fetch-Dest': 'script', 32 | 'Sec-Fetch-Mode': 'no-cors', 33 | 'Sec-Fetch-Site': 'same-site', 34 | 'User-Agent': 'Mozilla/5.0 (iPhone; CPU iPhone OS 13_2_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/13.0.3 Mobile/15E148 Safari/604.1 Edg/108.0.0.0', 35 | } 36 | 37 | # 签到用的url 38 | SIGN_URL = 'https://zhiyou.smzdm.com/user/checkin/jsonp_checkin' 39 | 40 | # 环境变量中用于存放cookie的key值 41 | KEY_OF_COOKIE = "SMZDM_COOKIE" 42 | 43 | TG_TOKEN = '' 44 | TG_USER_ID = '' 45 | # serverJ 46 | SCKEY = '' 47 | # push+ 48 | PUSH_PLUS_TOKEN = '' 49 | # 钉钉机器人 50 | DD_BOT_TOKEN = '' 51 | DD_BOT_SECRET = '' 52 | 53 | if "TG_BOT_TOKEN" in os.environ and len(os.environ["TG_BOT_TOKEN"]) > 1 and "TG_USER_ID" in os.environ and len( 54 | os.environ["TG_USER_ID"]) > 1: 55 | TG_TOKEN = os.environ["TG_BOT_TOKEN"] 56 | TG_USER_ID = os.environ["TG_USER_ID"] 57 | 58 | if "PUSH_KEY" in os.environ and len(os.environ["PUSH_KEY"]) > 1: 59 | SCKEY = os.environ["PUSH_KEY"] 60 | 61 | if "DD_BOT_TOKEN" in os.environ and len(os.environ["DD_BOT_TOKEN"]) > 1 and "DD_BOT_SECRET" in os.environ and len( 62 | os.environ["DD_BOT_SECRET"]) > 1: 63 | DD_BOT_TOKEN = os.environ["DD_BOT_TOKEN"] 64 | DD_BOT_SECRET = os.environ["DD_BOT_SECRET"] 65 | 66 | if "PUSH_PLUS_TOKEN" in os.environ and len(os.environ["PUSH_PLUS_TOKEN"]) > 1: 67 | PUSH_PLUS_TOKEN = os.environ["PUSH_PLUS_TOKEN"] 68 | 69 | 70 | def logout(self): 71 | print("[{0}]: {1}".format(datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S"), self)) 72 | sys.stdout.flush() 73 | 74 | 75 | def push_via_boot(title, content): 76 | dingding_bot(title, content) 77 | telegram_bot(title, content) 78 | serverJ(title, content) 79 | push_plus_bot(title, content) 80 | 81 | 82 | def dingding_bot(title, content): 83 | if not DD_BOT_TOKEN or not DD_BOT_SECRET: 84 | print("钉钉推送服务的DD_BOT_TOKEN或者DD_BOT_SECRET未设置!!\n取消推送") 85 | return 86 | timestamp = str(round(time.time() * 1000)) # 时间戳 87 | secret_enc = DD_BOT_SECRET.encode('utf-8') 88 | string_to_sign = '{}\n{}'.format(timestamp, DD_BOT_SECRET) 89 | string_to_sign_enc = string_to_sign.encode('utf-8') 90 | hmac_code = hmac.new(secret_enc, string_to_sign_enc, digestmod=hashlib.sha256).digest() 91 | sign = urllib.parse.quote_plus(base64.b64encode(hmac_code)) # 签名 92 | print('开始使用 钉钉机器人 推送消息...', end='') 93 | url = f'https://oapi.dingtalk.com/robot/send?access_token={DD_BOT_TOKEN}×tamp={timestamp}&sign={sign}' 94 | headers = {'Content-Type': 'application/json;charset=utf-8'} 95 | data = { 96 | 'msgtype': 'text', 97 | 'text': {'content': f'{title}\n\n{content}'} 98 | } 99 | response = requests.post(url=url, data=json.dumps(data), headers=headers, timeout=15).json() 100 | if not response['errcode']: 101 | print('推送成功!') 102 | else: 103 | print('推送失败!') 104 | 105 | 106 | def telegram_bot(title, content): 107 | try: 108 | print("\n") 109 | bot_token = TG_TOKEN 110 | user_id = TG_USER_ID 111 | if not bot_token or not user_id: 112 | print("tg服务的bot_token或者user_id未设置!!\n取消推送") 113 | return 114 | print("tg服务启动") 115 | url = f"https://api.telegram.org/bot{TG_TOKEN}/sendMessage" 116 | 117 | headers = {'Content-Type': 'application/x-www-form-urlencoded'} 118 | payload = {'chat_id': str(TG_USER_ID), 'text': f'{title}\n\n{content}', 'disable_web_page_preview': 'true'} 119 | proxies = None 120 | 121 | try: 122 | response = requests.post(url=url, headers=headers, params=payload, proxies=proxies).json() 123 | except: 124 | print('推送失败!') 125 | if response['ok']: 126 | print('推送成功!') 127 | else: 128 | print('推送失败!') 129 | except Exception as e: 130 | print(e) 131 | 132 | 133 | # push推送 134 | def push_plus_bot(title, content): 135 | try: 136 | print("\n") 137 | if not PUSH_PLUS_TOKEN: 138 | print("PUSHPLUS服务的token未设置!!\n取消推送") 139 | return 140 | print("PUSHPLUS服务启动") 141 | url = 'http://pushplus.hxtrip.com/send' 142 | data = { 143 | "token": PUSH_PLUS_TOKEN, 144 | "title": title, 145 | "content": content 146 | } 147 | body = json.dumps(data).encode(encoding='utf-8') 148 | headers = {'Content-Type': 'application/json'} 149 | response = requests.post(url=url, data=body, headers=headers).json() 150 | if response['code'] == 200: 151 | print('推送成功!') 152 | else: 153 | print('推送失败!') 154 | except Exception as e: 155 | print(e) 156 | 157 | 158 | def serverJ(title, content): 159 | try: 160 | print("\n") 161 | if not SCKEY: 162 | print("server酱服务的SCKEY未设置!!\n取消推送") 163 | return 164 | print("serverJ服务启动") 165 | data = { 166 | "title": title, 167 | "desp": content.replace("\n", "\n\n") 168 | } 169 | response = requests.post("https://sctapi.ftqq.com/{SCKEY}.send", data=data).json() 170 | if response['errno'] == 0: 171 | print('推送成功!') 172 | else: 173 | print('推送失败!') 174 | except Exception as e: 175 | print(e) 176 | 177 | 178 | class SignBot(object): 179 | 180 | def __init__(self): 181 | self.session = requests.Session() 182 | # 添加 headers 183 | self.session.headers = DEFAULT_HEADERS 184 | 185 | def __json_check(self, msg): 186 | """ 187 | 对请求 盖乐世社区 返回的数据进行进行检查 188 | 1.判断是否 json 形式 189 | """ 190 | try: 191 | result = msg.json() 192 | return True 193 | except Exception as e: 194 | logout(f'Error : {e}') 195 | return False 196 | 197 | def load_cookie_str(self, cookies): 198 | """ 199 | 起一个什么值得买的,带cookie的session 200 | cookie 为浏览器复制来的字符串 201 | :param cookie: 登录过的社区网站 cookie 202 | """ 203 | self.session.headers['Cookie'] = cookies 204 | 205 | def checkin(self): 206 | """ 207 | 签到函数 208 | """ 209 | msg = self.session.get(SIGN_URL) 210 | if self.__json_check(msg): 211 | return msg.json() 212 | return msg.content 213 | 214 | 215 | if __name__ == '__main__': 216 | bot = SignBot() 217 | cookies = os.environ[KEY_OF_COOKIE] 218 | cookieList = cookies.split("&") 219 | logout("检测到{}个cookie记录\n开始签到".format(len(cookieList))) 220 | index = 0 221 | for c in cookieList: 222 | bot.load_cookie_str(c) 223 | result = bot.checkin() 224 | msg = "\n⭐⭐⭐签到成功{1}天⭐⭐⭐\n🏅🏅🏅金币[{2}]\n🏅🏅🏅积分[{3}]\n🏅🏅🏅经验[{4}],\n🏅🏅🏅等级[{5}]\n🏅🏅补签卡[{6}]".format( 225 | index, 226 | result['data']["checkin_num"], 227 | result['data']["gold"], 228 | result['data']["point"], 229 | result['data']["exp"], 230 | result['data']["rank"], 231 | result['data']["cards"]) 232 | logout(msg) 233 | logout("开始推送,暂时支持【Telegram】【钉钉】【push+】【serverJ】") 234 | push_via_boot("张大妈自动签到", msg) 235 | # telegram_bot("张大妈自动签到", msg) 236 | index += 1 237 | logout("签到结束") 238 | -------------------------------------------------------------------------------- /sysxc.js: -------------------------------------------------------------------------------- 1 | /* 2 | 目标: 小程序 书亦烧仙草+ #小程序://书亦烧仙草/AlwBO6Ambtufllu 3 | 4 | 抓包 https://scrm-prod.shuyi.org.cn/saas-gateway/api/mini-app/v1/member/mine 域名请求头里中的auth和dt-user-token用&连接 不分顺序 5 | 6 | 7 | 格式:export shuyi="auth=xxxxxxxx&token=xxxxxxx" 多账号换行隔开 8 | 9 | cron: 32 5 12 * * ? 每天一到两次 10 | 11 | */ 12 | 13 | var _0xody='jsjiami.com.v6',_0xody_=['_0xody'],_0x465e=[_0xody,'\u4e66\u4ea6\u70e7\u4ed9\u8349\x2b','\x4d\x6f\x7a\x69\x6c\x6c\x61\x2f\x35\x2e\x30\x20\x28\x4c\x69\x6e\x75\x78\x3b\x20\x41\x6e\x64\x72\x6f\x69\x64\x20\x31\x30\x3b\x20\x56\x31\x38\x32\x34\x41\x20\x42\x75\x69\x6c\x64\x2f\x51\x50\x31\x41\x2e\x31\x39\x30\x37\x31\x31\x2e\x30\x32\x30\x3b\x20\x77\x76\x29\x20\x41\x70\x70\x6c\x65\x57\x65\x62\x4b\x69\x74\x2f\x35\x33\x37\x2e\x33\x36\x20\x28\x4b\x48\x54\x4d\x4c\x2c\x20\x6c\x69\x6b\x65\x20\x47\x65\x63\x6b\x6f\x29\x20\x56\x65\x72\x73\x69\x6f\x6e\x2f\x34\x2e\x30\x20\x43\x68\x72\x6f\x6d\x65\x2f\x38\x36\x2e\x30\x2e\x34\x32\x34\x30\x2e\x39\x39\x20\x58\x57\x45\x42\x2f\x34\x33\x37\x35\x20\x4d\x4d\x57\x45\x42\x53\x44\x4b\x2f\x32\x30\x32\x32\x30\x38\x30\x35\x20\x4d\x6f\x62\x69\x6c\x65\x20\x53\x61\x66\x61\x72\x69\x2f\x35\x33\x37\x2e\x33\x36\x20\x4d\x4d\x57\x45\x42\x49\x44\x2f\x31\x35\x37\x31\x20\x4d\x69\x63\x72\x6f\x4d\x65\x73\x73\x65\x6e\x67\x65\x72\x2f\x38\x2e\x30\x2e\x32\x37\x2e\x32\x32\x32\x30\x28\x30\x78\x32\x38\x30\x30\x31\x42\x35\x39\x29\x20\x57\x65\x43\x68\x61\x74\x2f\x61\x72\x6d\x36\x34\x20\x57\x65\x69\x78\x69\x6e\x20\x4e\x65\x74\x54\x79\x70\x65\x2f\x63\x74\x6c\x74\x65\x20\x4c\x61\x6e\x67\x75\x61\x67\x65\x2f\x7a\x68\x5f\x43\x4e\x20\x41\x42\x49\x2f\x61\x72\x6d\x36\x34\x20\x4d\x69\x6e\x69\x50\x72\x6f\x67\x72\x61\x6d\x45\x6e\x76\x2f\x61\x6e\x64\x72\x6f\x69\x64','\x69\x73\x4e\x6f\x64\x65','\x65\x6e\x76','\x73\x68\x75\x79\x69','\x67\x65\x74\x64\x61\x74\x61','\x69\x6e\x64\x65\x78','\x6e\x61\x6d\x65','\x76\x61\x6c\x69\x64','\x63\x61\x6e\x52\x65\x61\x64','\x70\x61\x72\x61\x6d','\x73\x74\x72\x32\x6a\x73\x6f\x6e','\x63\x6b\x56\x61\x6c\x69\x64','\x6c\x6f\x67\x41\x6e\x64\x4e\x6f\x74\x69\x66\x79','\u8d26\u53f7\x5b','\x5d\x43\x4b\u683c\u5f0f\u9519\u8bef','\x68\x74\x74\x70\x73\x3a\x2f\x2f\x73\x63\x72\x6d\x2d\x70\x72\x6f\x64\x2e\x73\x68\x75\x79\x69\x2e\x6f\x72\x67\x2e\x63\x6e\x2f\x73\x61\x61\x73\x2d\x67\x61\x74\x65\x77\x61\x79\x2f\x61\x70\x69\x2f\x6d\x69\x6e\x69\x2d\x61\x70\x70\x2f\x76\x31\x2f\x6d\x65\x6d\x62\x65\x72\x2f\x6d\x69\x6e\x65\x3f\x69\x3d\x31','\x61\x75\x74\x68','\x74\x6f\x6b\x65\x6e','\x67\x65\x74','\x65\x72\x72\x6e\x6f','\x64\x61\x74\x61','\x75\x73\x65\x72','\x5d\u8d26\u53f7\x3a','\x6e\x69\x63\x6b\x6e\x61\x6d\x65','\x20\u4f18\u60e0\u5238\x3a','\x63\x6f\x75\x70\x6f\x6e\x5f\x6e\x75\x6d\x73','\u5f20\x20\u79ef\u5206\x3a','\x63\x72\x65\x64\x69\x74\x31','\x20\u4f59\u989d\x3a','\x63\x72\x65\x64\x69\x74\x32','\x5d\u67e5\u8be2\u8d26\u6237\u5931\u8d25\uff0c\u53d8\u91cf\u5931\u6548\u6216\u68c0\u67e5\u53d8\u91cf\u683c\u5f0f','\x72\x65\x73\x6f\x6c\x76\x65','\x73\x69\x67\x6e','\x68\x74\x74\x70\x73\x3a\x2f\x2f\x73\x63\x72\x6d\x2d\x70\x72\x6f\x64\x2e\x73\x68\x75\x79\x69\x2e\x6f\x72\x67\x2e\x63\x6e\x2f\x73\x61\x61\x73\x2d\x67\x61\x74\x65\x77\x61\x79\x2f\x61\x70\x69\x2f\x61\x67\x67\x2d\x74\x72\x61\x64\x65\x2f\x76\x31\x2f\x73\x69\x67\x6e\x49\x6e\x2f\x69\x6e\x73\x65\x72\x74\x53\x69\x67\x6e\x49\x6e\x56\x32\x3f\x6d\x65\x6d\x62\x65\x72\x49\x64\x3d','\x64\x72\x61\x77\x54\x79\x70\x65\x3d\x42\x26\x62\x69\x7a\x46\x72\x6f\x6d\x3d\x32\x32\x36\x26\x61\x63\x74\x69\x76\x69\x74\x79\x49\x64\x3d\x54\x54\x4c\x58\x4a\x32\x30\x32\x31\x30\x33\x33\x30','\x68\x65\x61\x64\x65\x72\x73','\x64\x74\x2d\x75\x73\x65\x72\x2d\x74\x6f\x6b\x65\x6e','\x72\x65\x73\x75\x6c\x74\x43\x6f\x64\x65','\x5d\u7b2c\x3a','\x64\x61\x79\x73','\u5929\u7b7e\u5230\x20\u83b7\u5f97\x3a','\x70\x6f\x69\x6e\x74\x52\x65\x77\x61\x72\x64\x4e\x75\x6d','\x72\x65\x73\x75\x6c\x74\x4d\x73\x67','\x75\x6e\x64\x65\x66\x69\x6e\x65\x64','\x0a\u901a\u77e5\u533a\uff1a\x0a\u611f\u8c22\u7fa4\u53cb\u6295\u7a3f\x20\u8fde\u7b7e\u5f97\u6ee1\u51cf\u5238\uff0c\x33\x30\u5929\u767d\u5ad6\u4e00\u676f','\x66\x69\x6c\x74\x65\x72','\x6c\x65\x6e\x67\x74\x68','\x0a\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x20\u8d26\u53f7\u68c0\u6d4b\x20\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d','\x70\x75\x73\x68','\x77\x61\x69\x74','\x61\x6c\x6c','\x0a\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x20\u6bcf\u65e5\u7b7e\u5230\x20\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d\x2d','\x73\x68\x6f\x77\x6d\x73\x67','\x63\x61\x74\x63\x68','\x6c\x6f\x67','\x66\x69\x6e\x61\x6c\x6c\x79','\x64\x6f\x6e\x65','\x68\x74\x74\x70\x73\x3a\x2f\x2f\x76\x31\x2e\x6a\x69\x6e\x72\x69\x73\x68\x69\x63\x69\x2e\x63\x6f\x6d\x2f\x61\x6c\x6c\x2e\x6a\x73\x6f\x6e','\x63\x6f\x6e\x74\x65\x6e\x74','\x20\x20\x0a\x20\u2014\u2014\u2014\u2014\u300a','\x6f\x72\x69\x67\x69\x6e','\x61\x75\x74\x68\x6f\x72','\x69\x6e\x64\x65\x78\x4f\x66','\x73\x70\x6c\x69\x74','\x0a\u274c\u672a\u627e\u5230\x43\x4b\x20\u8bf7\u9605\u8bfb\u811a\u672c\u8bf4\u660e','\u5171\u627e\u5230','\u4e2a\u8d26\u53f7','\x72\x65\x70\x6c\x61\x63\x65','\x73\x63\x72\x6d\x2d\x70\x72\x6f\x64\x2e\x73\x68\x75\x79\x69\x2e\x6f\x72\x67\x2e\x63\x6e','\x62\x6f\x64\x79','\x63\x6f\x6e\x74\x65\x6e\x74\x2d\x74\x79\x70\x65','\x61\x70\x70\x6c\x69\x63\x61\x74\x69\x6f\x6e\x2f\x6a\x73\x6f\x6e','\x43\x6f\x6e\x74\x65\x6e\x74\x2d\x4c\x65\x6e\x67\x74\x68','\x73\x65\x6e\x64','\u8bf7\u6c42\u5931\u8d25','\x73\x74\x72\x69\x6e\x67\x69\x66\x79','\x6f\x62\x6a\x65\x63\x74','\x70\x61\x72\x73\x65','\x47\x49\x54\x48\x55\x42','\x65\x78\x69\x74','\x6e\x6f\x74\x69\x66\x79\x53\x74\x72','\x73\x74\x61\x72\x74\x54\x69\x6d\x65','\x67\x65\x74\x54\x69\x6d\x65','\x61\x73\x73\x69\x67\x6e','\x20\u5f00\u59cb\u8fd0\u884c\uff1a','\x65\x78\x70\x6f\x72\x74\x73','\x69\x73\x51\x75\x61\x6e\x58','\x69\x73\x53\x75\x72\x67\x65','\x69\x73\x4c\x6f\x6f\x6e','\x67\x65\x74\x76\x61\x6c','\x74\x65\x73\x74','\x65\x78\x65\x63','\x6c\x6f\x64\x61\x73\x68\x5f\x67\x65\x74','\x73\x65\x74\x64\x61\x74\x61','\x6e\x75\x6c\x6c','\x6c\x6f\x64\x61\x73\x68\x5f\x73\x65\x74','\x73\x65\x74\x76\x61\x6c','\x72\x65\x61\x64','\x76\x61\x6c\x75\x65\x46\x6f\x72\x4b\x65\x79','\x6c\x6f\x61\x64\x64\x61\x74\x61','\x77\x72\x69\x74\x65','\x73\x65\x74\x56\x61\x6c\x75\x65\x46\x6f\x72\x4b\x65\x79','\x77\x72\x69\x74\x65\x64\x61\x74\x61','\x70\x6f\x73\x74','\x70\x75\x74','\x64\x65\x6c\x65\x74\x65','\u65e0\u6548\u7684\x68\x74\x74\x70\u65b9\u6cd5\uff1a','\x69\x73\x4e\x65\x65\x64\x52\x65\x77\x72\x69\x74\x65','\x75\x72\x6c','\x74\x69\x6d\x65\x6f\x75\x74','\x74\x68\x65\x6e','\x6d\x65\x74\x68\x6f\x64','\x74\x6f\x55\x70\x70\x65\x72\x43\x61\x73\x65','\x6f\x70\x74\x73','\x66\x65\x74\x63\x68','\x67\x6f\x74','\x69\x6e\x73\x74\x61\x6e\x63\x65','\x65\x78\x74\x65\x6e\x64','\x74\x69\x6d\x65','\x67\x65\x74\x4d\x6f\x6e\x74\x68','\x67\x65\x74\x44\x61\x74\x65','\x67\x65\x74\x48\x6f\x75\x72\x73','\x67\x65\x74\x4d\x69\x6e\x75\x74\x65\x73','\x67\x65\x74\x53\x65\x63\x6f\x6e\x64\x73','\x66\x6c\x6f\x6f\x72','\x67\x65\x74\x4d\x69\x6c\x6c\x69\x73\x65\x63\x6f\x6e\x64\x73','\x67\x65\x74\x46\x75\x6c\x6c\x59\x65\x61\x72','\x73\x75\x62\x73\x74\x72','\x20\u8fd0\u884c\u901a\u77e5\x0a\x0a','\x2e\x2f\x73\x65\x6e\x64\x4e\x6f\x74\x69\x66\x79','\x0a\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x20\u63a8\u9001\x20\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d','\x73\x65\x6e\x64\x4e\x6f\x74\x69\x66\x79','\x6d\x73\x67','\x73\x74\x72\x69\x6e\x67','\x6f\x70\x65\x6e\x55\x72\x6c','\x6f\x70\x65\x6e\x2d\x75\x72\x6c','\x6d\x65\x64\x69\x61\x55\x72\x6c','\x6d\x65\x64\x69\x61\x2d\x75\x72\x6c','\x69\x73\x4d\x75\x74\x65','\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x20\u7cfb\u7edf\u901a\u77e5\x20\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d\x3d','\x6a\x6f\x69\x6e','\x67\x65\x74\x4d\x69\x6e','\x67\x65\x74\x4d\x61\x78','\x70\x61\x64\x53\x74\x72','\x6a\x73\x6f\x6e\x32\x73\x74\x72','\x6b\x65\x79\x73','\x73\x6f\x72\x74','\x72\x61\x6e\x64\x6f\x6d\x53\x74\x72\x69\x6e\x67','\x61\x62\x63\x64\x65\x66\x30\x31\x32\x33\x34\x35\x36\x37\x38\x39','\x63\x68\x61\x72\x41\x74','\x72\x61\x6e\x64\x6f\x6d','\x72\x61\x6e\x64\x6f\x6d\x4c\x69\x73\x74','\x20\u8fd0\u884c\u7ed3\u675f\uff0c\u5171\u8fd0\u884c\u4e86\x20','\x20\u79d2\uff01','\x66\x6a\x62\x73\x6a\x47\x42\x41\x5a\x57\x50\x69\x61\x6d\x68\x59\x66\x69\x59\x45\x2e\x4f\x63\x6b\x6f\x6d\x4a\x2e\x76\x36\x3d\x3d'];function _0x5c09(_0x45bd88,_0x3b47c2){_0x45bd88=~~'0x'['concat'](_0x45bd88['slice'](0x0));var _0x369349=_0x465e[_0x45bd88];return _0x369349;};(function(_0x4171c0,_0x308413){var _0x39c21e=0x0;for(_0x308413=_0x4171c0['shift'](_0x39c21e>>0x2);_0x308413&&_0x308413!==(_0x4171c0['pop'](_0x39c21e>>0x3)+'')['replace'](/[fbGBAZWPhYfYEOkJ=]/g,'');_0x39c21e++){_0x39c21e=_0x39c21e^0x12286b;}}(_0x465e,_0x5c09));const $=new Env(_0x5c09('0'));let envSplitor=['\x0a'];let defaultUA=_0x5c09('1');let httpResult,httpReq,httpResp;let userCookie=($[_0x5c09('2')]()?process[_0x5c09('3')][_0x5c09('4')]:$[_0x5c09('5')](_0x5c09('4')))||'';let userList=[];let userIdx=0x0;let userCount=0x0;class UserInfo{constructor(_0x2b0295){this[_0x5c09('6')]=++userIdx;this[_0x5c09('7')]=this[_0x5c09('6')];this[_0x5c09('8')]=![];this[_0x5c09('9')]=![];try{this[_0x5c09('a')]=$[_0x5c09('b')](_0x2b0295);this[_0x5c09('c')]=!![];}catch(_0x3ffadc){this[_0x5c09('c')]=![];$[_0x5c09('d')](_0x5c09('e')+this[_0x5c09('6')]+_0x5c09('f'));}}async['\x6d\x79'](){try{let _0x3d79c8=_0x5c09('10');let _0x8361e9='';let _0x3ade24=''+this[_0x5c09('a')][_0x5c09('11')];let _0x5d0f14=''+this[_0x5c09('a')][_0x5c09('12')];let _0x29075e=populateUrlObject(_0x3d79c8,_0x3ade24,_0x5d0f14,_0x8361e9);await httpRequest(_0x5c09('13'),_0x29075e);let _0x50e3ff=httpResult;if(!_0x50e3ff)return;if(_0x50e3ff[_0x5c09('14')]==0x0){this[_0x5c09('8')]=!![];this[_0x5c09('9')]=!![];this['\x6c\x64']=_0x50e3ff[_0x5c09('15')][_0x5c09('16')]['\x69\x64'];$[_0x5c09('d')](_0x5c09('e')+this[_0x5c09('7')]+_0x5c09('17')+_0x50e3ff[_0x5c09('15')][_0x5c09('16')][_0x5c09('18')]+_0x5c09('19')+_0x50e3ff[_0x5c09('15')][_0x5c09('16')][_0x5c09('1a')]+_0x5c09('1b')+_0x50e3ff[_0x5c09('15')][_0x5c09('16')][_0x5c09('1c')]+_0x5c09('1d')+_0x50e3ff[_0x5c09('15')][_0x5c09('16')][_0x5c09('1e')]);}else{$[_0x5c09('d')](_0x5c09('e')+this[_0x5c09('7')]+_0x5c09('1f'));}}catch(_0x5d4e34){}finally{return Promise[_0x5c09('20')](0x1);}}async[_0x5c09('21')](){try{let _0x335d30=_0x5c09('22')+this['\x6c\x64'];let _0x2c9b99=_0x5c09('23');let _0x17174b=''+this[_0x5c09('a')][_0x5c09('11')];let _0x409f7e=populateUrlObject(_0x335d30,_0x17174b,_0x2c9b99);delete _0x409f7e[_0x5c09('24')][_0x5c09('25')];await httpRequest(_0x5c09('13'),_0x409f7e);let _0x506ddb=httpResult;if(!_0x506ddb)return;if(_0x506ddb[_0x5c09('26')]==0x0){$[_0x5c09('d')](_0x5c09('e')+this[_0x5c09('7')]+_0x5c09('27')+_0x506ddb[_0x5c09('15')][_0x5c09('28')]+_0x5c09('29')+_0x506ddb[_0x5c09('15')][_0x5c09('2a')]+'\u79ef\u5206');}else{$[_0x5c09('d')](_0x5c09('e')+this[_0x5c09('7')]+'\x5d'+_0x506ddb[_0x5c09('2b')]);}}catch(_0x304295){}finally{return Promise[_0x5c09('20')](0x1);}}}!(async()=>{if(typeof $request!==_0x5c09('2c')){}else{if(!(await checkEnv()))return;await sc();$[_0x5c09('d')](_0x5c09('2d'));let _0x12c231=[];let _0x3b91f9=userList[_0x5c09('2e')](_0x348ac3=>_0x348ac3[_0x5c09('c')]);if(_0x3b91f9[_0x5c09('2f')]>0x0){$[_0x5c09('d')](_0x5c09('30'));_0x12c231=[];for(let _0x5816ab of _0x3b91f9){_0x12c231[_0x5c09('31')](_0x5816ab['\x6d\x79']());await $[_0x5c09('32')](0x1388);}await Promise[_0x5c09('33')](_0x12c231);_0x3b91f9=_0x3b91f9[_0x5c09('2e')](_0x394376=>_0x394376[_0x5c09('8')]);if(_0x3b91f9[_0x5c09('2f')]>0x0){$[_0x5c09('d')](_0x5c09('34'));_0x12c231=[];for(let _0x36c05b of _0x3b91f9[_0x5c09('2e')](_0x1191b8=>_0x1191b8[_0x5c09('9')])){_0x12c231[_0x5c09('31')](_0x36c05b[_0x5c09('21')]());}await Promise[_0x5c09('33')](_0x12c231);}}await $[_0x5c09('35')]();}})()[_0x5c09('36')](_0x7a76ad=>console[_0x5c09('37')](_0x7a76ad))[_0x5c09('38')](()=>$[_0x5c09('39')]());async function sc(){try{let _0xb43813=_0x5c09('3a');let _0x40ac0a='';let _0x501b2d=populateUrlObject(_0xb43813,_0x40ac0a);await httpRequest(_0x5c09('13'),_0x501b2d);let _0x2311f2=httpResult;if(!_0x2311f2)return;$[_0x5c09('d')]('\x0a\x20'+_0x2311f2[_0x5c09('3b')]+_0x5c09('3c')+_0x2311f2[_0x5c09('3d')]+'\u300b'+_0x2311f2[_0x5c09('3e')]);var _0x13cc39=_0x2311f2[_0x5c09('3b')];}catch(_0x50d2f0){}finally{return Promise[_0x5c09('20')](0x1);}}async function checkEnv(){if(userCookie){let _0x4d4e53=envSplitor[0x0];for(let _0x41fe2c of envSplitor){if(userCookie[_0x5c09('3f')](_0x41fe2c)>-0x1){_0x4d4e53=_0x41fe2c;break;}}for(let _0x21fc32 of userCookie[_0x5c09('40')](_0x4d4e53)){if(_0x21fc32)userList[_0x5c09('31')](new UserInfo(_0x21fc32));}userCount=userList[_0x5c09('2f')];}else{console[_0x5c09('37')](_0x5c09('41'));return;}console[_0x5c09('37')](_0x5c09('42')+userCount+_0x5c09('43'));return!![];}function populateUrlObject(_0xb33933,_0x6fcda6,_0x1a984c,_0x354467=''){let _0x5ebcd9=_0xb33933[_0x5c09('44')]('\x2f\x2f','\x2f')[_0x5c09('40')]('\x2f')[0x1];let _0x197312={'\x75\x72\x6c':_0xb33933,'\x68\x65\x61\x64\x65\x72\x73':{'Host':_0x5ebcd9,'auth':_0x6fcda6,'dt-user-token':_0x1a984c,'hostname':_0x5c09('45'),'User-Agent':defaultUA},'\x74\x69\x6d\x65\x6f\x75\x74':0x1388};if(_0x354467){_0x197312[_0x5c09('46')]=_0x354467;_0x197312[_0x5c09('24')][_0x5c09('47')]=_0x5c09('48');_0x197312[_0x5c09('24')][_0x5c09('49')]=_0x197312[_0x5c09('46')]?_0x197312[_0x5c09('46')][_0x5c09('2f')]:0x0;}return _0x197312;}async function httpRequest(_0x332ef0,_0x788ed){httpResult=null,httpReq=null,httpResp=null;return new Promise(_0x373672=>{$[_0x5c09('4a')](_0x332ef0,_0x788ed,async(_0x4bcfba,_0x2461fd,_0x3022ad)=>{try{httpReq=_0x2461fd;httpResp=_0x3022ad;if(_0x4bcfba){console[_0x5c09('37')](_0x332ef0+_0x5c09('4b'));console[_0x5c09('37')](JSON[_0x5c09('4c')](_0x4bcfba));}else{if(_0x3022ad[_0x5c09('46')]){if(typeof _0x3022ad[_0x5c09('46')]==_0x5c09('4d')){httpResult=_0x3022ad[_0x5c09('46')];}else{try{httpResult=JSON[_0x5c09('4e')](_0x3022ad[_0x5c09('46')]);}catch(_0x13e39a){httpResult=_0x3022ad[_0x5c09('46')];}}}}}catch(_0x12363f){console[_0x5c09('37')](_0x12363f);}finally{_0x373672();}});});}function Env(_0x32f0f1,_0x1c845a){_0x5c09('2c')!=typeof process&&JSON[_0x5c09('4c')](process[_0x5c09('3')])[_0x5c09('3f')](_0x5c09('4f'))>-0x1&&process[_0x5c09('50')](0x0);return new class{constructor(_0x32f0f1,_0x1c845a){this[_0x5c09('7')]=_0x32f0f1;this[_0x5c09('51')]='';this[_0x5c09('52')]=new Date()[_0x5c09('53')]();Object[_0x5c09('54')](this,_0x1c845a);console[_0x5c09('37')](this[_0x5c09('7')]+_0x5c09('55'));}[_0x5c09('2')](){return _0x5c09('2c')!=typeof module&&!!module[_0x5c09('56')];}[_0x5c09('57')](){return _0x5c09('2c')!=typeof $task;}[_0x5c09('58')](){return _0x5c09('2c')!=typeof $httpClient&&_0x5c09('2c')==typeof $loon;}[_0x5c09('59')](){return _0x5c09('2c')!=typeof $loon;}[_0x5c09('5')](_0x2118f0){let _0x5a9a89=this[_0x5c09('5a')](_0x2118f0);if(/^@/[_0x5c09('5b')](_0x2118f0)){const [,_0x223d91,_0x2f7c5b]=/^@(.*?)\.(.*?)$/[_0x5c09('5c')](_0x2118f0),_0x11b766=_0x223d91?this[_0x5c09('5a')](_0x223d91):'';if(_0x11b766)try{const _0x2118f0=JSON[_0x5c09('4e')](_0x11b766);_0x5a9a89=_0x2118f0?this[_0x5c09('5d')](_0x2118f0,_0x2f7c5b,''):_0x5a9a89;}catch(_0x57e3b9){_0x5a9a89='';}}return _0x5a9a89;}[_0x5c09('5e')](_0x26a3e6,_0x35ac04){let _0x11f96d=!0x1;if(/^@/[_0x5c09('5b')](_0x35ac04)){const [,_0xd9de0d,_0x18fa3e]=/^@(.*?)\.(.*?)$/[_0x5c09('5c')](_0x35ac04),_0x1d5067=this[_0x5c09('5a')](_0xd9de0d),_0x594bf4=_0xd9de0d?_0x5c09('5f')===_0x1d5067?null:_0x1d5067||'\x7b\x7d':'\x7b\x7d';try{const _0x35ac04=JSON[_0x5c09('4e')](_0x594bf4);this[_0x5c09('60')](_0x35ac04,_0x18fa3e,_0x26a3e6),_0x11f96d=this[_0x5c09('61')](JSON[_0x5c09('4c')](_0x35ac04),_0xd9de0d);}catch(_0xf539b){const _0x1d5067={};this[_0x5c09('60')](_0x1d5067,_0x18fa3e,_0x26a3e6),_0x11f96d=this[_0x5c09('61')](JSON[_0x5c09('4c')](_0x1d5067),_0xd9de0d);}}else{_0x11f96d=this[_0x5c09('61')](_0x26a3e6,_0x35ac04);}return _0x11f96d;}[_0x5c09('5a')](_0x7d6784){return this[_0x5c09('58')]()||this[_0x5c09('59')]()?$persistentStore[_0x5c09('62')](_0x7d6784):this[_0x5c09('57')]()?$prefs[_0x5c09('63')](_0x7d6784):this[_0x5c09('2')]()?(this[_0x5c09('15')]=this[_0x5c09('64')](),this[_0x5c09('15')][_0x7d6784]):this[_0x5c09('15')]&&this[_0x5c09('15')][_0x7d6784]||null;}[_0x5c09('61')](_0x1273aa,_0x3beff2){return this[_0x5c09('58')]()||this[_0x5c09('59')]()?$persistentStore[_0x5c09('65')](_0x1273aa,_0x3beff2):this[_0x5c09('57')]()?$prefs[_0x5c09('66')](_0x1273aa,_0x3beff2):this[_0x5c09('2')]()?(this[_0x5c09('15')]=this[_0x5c09('64')](),this[_0x5c09('15')][_0x3beff2]=_0x1273aa,this[_0x5c09('67')](),!0x0):this[_0x5c09('15')]&&this[_0x5c09('15')][_0x3beff2]||null;}[_0x5c09('4a')](_0x17e729,_0xfc06ab,_0x4cb7c0=()=>{}){if(_0x17e729!=_0x5c09('13')&&_0x17e729!=_0x5c09('68')&&_0x17e729!=_0x5c09('69')&&_0x17e729!=_0x5c09('6a')){console[_0x5c09('37')](_0x5c09('6b')+_0x17e729);return;}if(_0x17e729==_0x5c09('13')&&_0xfc06ab[_0x5c09('24')]){delete _0xfc06ab[_0x5c09('24')][_0x5c09('47')];delete _0xfc06ab[_0x5c09('24')][_0x5c09('49')];}else if(_0xfc06ab[_0x5c09('46')]&&_0xfc06ab[_0x5c09('24')]){if(!_0xfc06ab[_0x5c09('24')][_0x5c09('47')])_0xfc06ab[_0x5c09('24')][_0x5c09('47')]=_0x5c09('48');}if(this[_0x5c09('58')]()||this[_0x5c09('59')]()){if(this[_0x5c09('58')]()&&this[_0x5c09('6c')]){_0xfc06ab[_0x5c09('24')]=_0xfc06ab[_0x5c09('24')]||{};Object[_0x5c09('54')](_0xfc06ab[_0x5c09('24')],{'X-Surge-Skip-Scripting':!0x1});}let _0x55701b={'\x6d\x65\x74\x68\x6f\x64':_0x17e729,'\x75\x72\x6c':_0xfc06ab[_0x5c09('6d')],'\x68\x65\x61\x64\x65\x72\x73':_0xfc06ab[_0x5c09('24')],'\x74\x69\x6d\x65\x6f\x75\x74':_0xfc06ab[_0x5c09('6e')],'\x64\x61\x74\x61':_0xfc06ab[_0x5c09('46')]};if(_0x17e729==_0x5c09('13'))delete _0x55701b[_0x5c09('15')];$axios(_0x55701b)[_0x5c09('6f')](_0xfc06ab=>{const {status:i,request:q,headers:r,data:o}=_0xfc06ab;_0x4cb7c0(null,q,{'\x73\x74\x61\x74\x75\x73\x43\x6f\x64\x65':i,'\x68\x65\x61\x64\x65\x72\x73':r,'\x62\x6f\x64\x79':o});})[_0x5c09('36')](_0x43bb17=>console[_0x5c09('37')](_0x43bb17));}else if(this[_0x5c09('57')]()){_0xfc06ab[_0x5c09('70')]=_0x17e729[_0x5c09('71')](),this[_0x5c09('6c')]&&(_0xfc06ab[_0x5c09('72')]=_0xfc06ab[_0x5c09('72')]||{},Object[_0x5c09('54')](_0xfc06ab[_0x5c09('72')],{'\x68\x69\x6e\x74\x73':!0x1})),$task[_0x5c09('73')](_0xfc06ab)[_0x5c09('6f')](_0xfc06ab=>{const {statusCode:i,request:q,headers:r,body:o}=_0xfc06ab;_0x4cb7c0(null,q,{'\x73\x74\x61\x74\x75\x73\x43\x6f\x64\x65':i,'\x68\x65\x61\x64\x65\x72\x73':r,'\x62\x6f\x64\x79':o});},_0xfc06ab=>_0x4cb7c0(_0xfc06ab));}else if(this[_0x5c09('2')]()){this[_0x5c09('74')]=this[_0x5c09('74')]?this[_0x5c09('74')]:require(_0x5c09('74'));const {url:s,..._0x56967e}=_0xfc06ab;this[_0x5c09('75')]=this[_0x5c09('74')][_0x5c09('76')]({'\x66\x6f\x6c\x6c\x6f\x77\x52\x65\x64\x69\x72\x65\x63\x74':![]});this[_0x5c09('75')][_0x17e729](s,_0x56967e)[_0x5c09('6f')](_0xfc06ab=>{const {statusCode:_0x56967e,request:q,headers:r,body:o}=_0xfc06ab;_0x4cb7c0(null,q,{'\x73\x74\x61\x74\x75\x73\x43\x6f\x64\x65':_0x56967e,'\x68\x65\x61\x64\x65\x72\x73':r,'\x62\x6f\x64\x79':o});},_0xfc06ab=>{const {message:s,response:_0x56967e}=_0xfc06ab;_0x4cb7c0(s,_0x56967e,_0x56967e&&_0x56967e[_0x5c09('46')]);});}}[_0x5c09('77')](_0xc066ba){let _0x3c6d8a={'M+':new Date()[_0x5c09('78')]()+0x1,'d+':new Date()[_0x5c09('79')](),'h+':new Date()[_0x5c09('7a')](),'m+':new Date()[_0x5c09('7b')](),'s+':new Date()[_0x5c09('7c')](),'q+':Math[_0x5c09('7d')]((new Date()[_0x5c09('78')]()+0x3)/0x3),'\x53':new Date()[_0x5c09('7e')]()};/(y+)/[_0x5c09('5b')](_0xc066ba)&&(_0xc066ba=_0xc066ba[_0x5c09('44')](RegExp['\x24\x31'],(new Date()[_0x5c09('7f')]()+'')[_0x5c09('80')](0x4-RegExp['\x24\x31'][_0x5c09('2f')])));for(let _0x1830bd in _0x3c6d8a)new RegExp('\x28'+_0x1830bd+'\x29')[_0x5c09('5b')](_0xc066ba)&&(_0xc066ba=_0xc066ba[_0x5c09('44')](RegExp['\x24\x31'],0x1==RegExp['\x24\x31'][_0x5c09('2f')]?_0x3c6d8a[_0x1830bd]:('\x30\x30'+_0x3c6d8a[_0x1830bd])[_0x5c09('80')]((''+_0x3c6d8a[_0x1830bd])[_0x5c09('2f')])));return _0xc066ba;}async[_0x5c09('35')](){if(!this[_0x5c09('51')])return;let _0x23ed67=this[_0x5c09('7')]+_0x5c09('81')+this[_0x5c09('51')];if($[_0x5c09('2')]()){var _0xf0d5c5=require(_0x5c09('82'));console[_0x5c09('37')](_0x5c09('83'));await _0xf0d5c5[_0x5c09('84')](this[_0x5c09('7')],_0x23ed67);}else{this[_0x5c09('85')](_0x23ed67);}}[_0x5c09('d')](_0x121f53){console[_0x5c09('37')](_0x121f53);this[_0x5c09('51')]+=_0x121f53;this[_0x5c09('51')]+='\x0a';}[_0x5c09('85')](_0x539d99=t,_0x455208='',_0x12d6fd='',_0x3e9012){const _0x44bcb7=_0x126a29=>{if(!_0x126a29)return _0x126a29;if(_0x5c09('86')==typeof _0x126a29)return this[_0x5c09('59')]()?_0x126a29:this[_0x5c09('57')]()?{'open-url':_0x126a29}:this[_0x5c09('58')]()?{'\x75\x72\x6c':_0x126a29}:void 0x0;if(_0x5c09('4d')==typeof _0x126a29){if(this[_0x5c09('59')]()){let _0x539d99=_0x126a29[_0x5c09('87')]||_0x126a29[_0x5c09('6d')]||_0x126a29[_0x5c09('88')],_0x455208=_0x126a29[_0x5c09('89')]||_0x126a29[_0x5c09('8a')];return{'\x6f\x70\x65\x6e\x55\x72\x6c':_0x539d99,'\x6d\x65\x64\x69\x61\x55\x72\x6c':_0x455208};}if(this[_0x5c09('57')]()){let _0x539d99=_0x126a29[_0x5c09('88')]||_0x126a29[_0x5c09('6d')]||_0x126a29[_0x5c09('87')],_0x455208=_0x126a29[_0x5c09('8a')]||_0x126a29[_0x5c09('89')];return{'open-url':_0x539d99,'media-url':_0x455208};}if(this[_0x5c09('58')]()){let _0x539d99=_0x126a29[_0x5c09('6d')]||_0x126a29[_0x5c09('87')]||_0x126a29[_0x5c09('88')];return{'\x75\x72\x6c':_0x539d99};}}};this[_0x5c09('8b')]||(this[_0x5c09('58')]()||this[_0x5c09('59')]()?$notification[_0x5c09('68')](_0x539d99,_0x455208,_0x12d6fd,_0x44bcb7(_0x3e9012)):this[_0x5c09('57')]()&&$notify(_0x539d99,_0x455208,_0x12d6fd,_0x44bcb7(_0x3e9012)));let _0x420024=['',_0x5c09('8c')];_0x420024[_0x5c09('31')](_0x539d99),_0x455208&&_0x420024[_0x5c09('31')](_0x455208),_0x12d6fd&&_0x420024[_0x5c09('31')](_0x12d6fd),console[_0x5c09('37')](_0x420024[_0x5c09('8d')]('\x0a'));}[_0x5c09('8e')](_0x46eeca,_0x35de77){return _0x46eeca<_0x35de77?_0x46eeca:_0x35de77;}[_0x5c09('8f')](_0xcf0da7,_0x2aa48a){return _0xcf0da7<_0x2aa48a?_0x2aa48a:_0xcf0da7;}[_0x5c09('90')](_0x4ec89f,_0x12ba9e,_0x1b8a9a='\x30'){let _0x224943=String(_0x4ec89f);let _0x1fd5b1=_0x12ba9e>_0x224943[_0x5c09('2f')]?_0x12ba9e-_0x224943[_0x5c09('2f')]:0x0;let _0x5d15d7='';for(let _0x5545d1=0x0;_0x5545d1<_0x1fd5b1;_0x5545d1++){_0x5d15d7+=_0x1b8a9a;}_0x5d15d7+=_0x224943;return _0x5d15d7;}[_0x5c09('91')](_0x52227b,_0x8a828d,_0x22be5c=![]){let _0x4e232e=[];for(let _0x1870fa of Object[_0x5c09('92')](_0x52227b)[_0x5c09('93')]()){let _0x560596=_0x52227b[_0x1870fa];if(_0x560596&&_0x22be5c)_0x560596=encodeURIComponent(_0x560596);_0x4e232e[_0x5c09('31')](_0x1870fa+'\x3d'+_0x560596);}return _0x4e232e[_0x5c09('8d')](_0x8a828d);}[_0x5c09('b')](_0x58c5c9,_0x3b6ad6=![]){let _0x1cd252={};for(let _0x2b9a62 of _0x58c5c9[_0x5c09('40')]('\x26')){if(!_0x2b9a62)continue;let _0x385b9c=_0x2b9a62[_0x5c09('3f')]('\x3d');if(_0x385b9c==-0x1)continue;let _0x3b4872=_0x2b9a62[_0x5c09('80')](0x0,_0x385b9c);let _0x1d4221=_0x2b9a62[_0x5c09('80')](_0x385b9c+0x1);if(_0x3b6ad6)_0x1d4221=decodeURIComponent(_0x1d4221);_0x1cd252[_0x3b4872]=_0x1d4221;}return _0x1cd252;}[_0x5c09('94')](_0x488c5a,_0x19a72c=_0x5c09('95')){let _0xe7f4db='';for(let _0x1addac=0x0;_0x1addac<_0x488c5a;_0x1addac++){_0xe7f4db+=_0x19a72c[_0x5c09('96')](Math[_0x5c09('7d')](Math[_0x5c09('97')]()*_0x19a72c[_0x5c09('2f')]));}return _0xe7f4db;}[_0x5c09('98')](_0x291ef5){let _0x2dec02=Math[_0x5c09('7d')](Math[_0x5c09('97')]()*_0x291ef5[_0x5c09('2f')]);return _0x291ef5[_0x2dec02];}[_0x5c09('32')](_0x1427f1){return new Promise(_0x351b49=>setTimeout(_0x351b49,_0x1427f1));}[_0x5c09('39')](_0x2db3dd={}){const _0x821e7f=new Date()[_0x5c09('53')](),_0x284da9=(_0x821e7f-this[_0x5c09('52')])/0x3e8;console[_0x5c09('37')]('\x0a'+this[_0x5c09('7')]+_0x5c09('99')+_0x284da9+_0x5c09('9a'));if(this[_0x5c09('58')]()||this[_0x5c09('57')]()||this[_0x5c09('59')]())$done(_0x2db3dd);}}(_0x32f0f1,_0x1c845a);};_0xody='jsjiami.com.v6'; 14 | -------------------------------------------------------------------------------- /tpyqc.js: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * 4 | * 项目类型:APP 5 | * 项目名称:太平洋汽车 6 | * 项目抓包:手机号 & 密码 7 | * 项目变量:lekebo_tpyqc_Cookie 8 | * 项目定时:每天运行一次 9 | * cron: 10 8 * * * 10 | * github仓库:https://github.com/ 11 | * 12 | * test 13 | */ 14 | 15 | 16 | //===============脚本版本=================// 17 | let scriptVersion = "1.0.1"; 18 | let update_data = "完成签到,七天签到 3 元红包 , 14 天 2 元红包"; 19 | //=======================================// 20 | const $ = new Env('太平洋汽车'); 21 | const notify = $.isNode() ? require('./sendNotify') : ''; 22 | const Notify = 1 //0为关闭通知,1为打开通知,默认为1 23 | const {log} = console; 24 | let scriptVersionLatest = ""; 25 | let UserCookie = ($.isNode() ? process.env.lekebo_tpyqc_Cookie : $.getdata('lekebo_tpyqc_Cookie')) || ''; 26 | let UserCookieArr = []; 27 | let data = ''; 28 | let msg =``; 29 | let isSign = false; 30 | var timestamp = Math.round(new Date().getTime()).toString(); 31 | let host = 'mrobot.pcauto.com.cn'; 32 | let hostname = 'https://' + host; 33 | //=======================================// 34 | !(async () => { 35 | if (typeof $request !== "undefined") { 36 | await GetRewrite(); 37 | } else { 38 | if (!(await Envs())){ 39 | return; 40 | } else { 41 | DoubleLog(`\n test`) 42 | await getVersion(); 43 | DoubleLog(`\n================ 共找到 ${UserCookieArr.length} 个账号 ================ \n 脚本执行✌北京时间(UTC+8):${new Date(new Date().getTime() + new Date().getTimezoneOffset() * 60 * 1000 + 8 * 60 * 60 * 1000).toLocaleString()} \n================ 版本对比检查更新 ================`); 44 | if (scriptVersionLatest != scriptVersion) { 45 | DoubleLog(`\n 当前版本:${scriptVersion}`) 46 | DoubleLog(`\n 最新版本:${scriptVersionLatest}`) 47 | DoubleLog(`\n 更新信息:${update_data}`) 48 | } else { 49 | DoubleLog(`\n 版本信息:${scriptVersion} ,已是最新版本无需更新开始执行脚本`) 50 | } 51 | for (let index = 0; index < UserCookieArr.length; index++) { 52 | let num = index + 1 53 | DoubleLog(`\n================ 开始第 ${num} 个账号 ================`) 54 | ck = UserCookieArr[index].split("&"); 55 | taskBeforeScore = 0; 56 | await start(); 57 | } 58 | await SendMsg(msg); 59 | } 60 | } 61 | 62 | })() 63 | .catch((e) => log(e)) 64 | .finally(() => $.done()) 65 | 66 | /** 67 | * 获取基础信息 68 | * @returns {Promise} 69 | */ 70 | async function start() { 71 | await login(2 * 1000); 72 | await $.wait(2000); 73 | await getMemberInfo(1,2 * 1000); 74 | await $.wait(2000); 75 | await signin(2 * 1000); 76 | await $.wait(2000); 77 | await getMemberInfo(2,2 * 1000); 78 | await $.wait(2000); 79 | return true; 80 | } 81 | /** 82 | * 查询会员信息 83 | * @param timeout 84 | * @returns {Promise} 85 | */ 86 | function login(timeout = 2000) { 87 | return new Promise((resolve) => { 88 | let url = { 89 | url: `${hostname}/auto_passport3_back_intf/passport3/rest/login_new.jsp`, 90 | headers: { 91 | Host: host, 92 | 'Content-Type': 'application/x-www-form-urlencoded', 93 | }, 94 | body: `password=${ck[1]}&username=${ck[0]}`, 95 | } 96 | $.post(url, async (error, response, data) => { 97 | try { 98 | let result = JSON.parse(data); 99 | if (result.status == 0) { 100 | ck = result.common_session_id; 101 | DoubleLog(`\n 账号登录: ✅ ,${result.message}`) 102 | } else { 103 | DoubleLog(`\n 账号登录: ❌ ,原因是:${result.msg}`) 104 | } 105 | } catch (e) { 106 | DoubleLog(`\n 信息异常: ❌ ,${response}`) 107 | } finally { 108 | resolve(); 109 | } 110 | }, timeout) 111 | }) 112 | } 113 | /** 114 | * 查询会员信息 115 | * @param timeout 116 | * @returns {Promise} 117 | */ 118 | function getMemberInfo(task,timeout = 2000) { 119 | return new Promise((resolve) => { 120 | let url = { 121 | url: `${hostname}/xsp/s/auto/info/nocache/task/getLoginUserInfo.xsp`, 122 | headers: { 123 | 'Host': host, 124 | 'Cookie': `common_session_id=${ck}`, 125 | }, 126 | } 127 | $.post(url, async (error, response, data) => { 128 | try { 129 | let result = JSON.parse(data); 130 | if (task == 1) { 131 | DoubleLog(`\n 会员信息: ✅ ,会员:${result.userName},当前 ${result.goldCount} 积分`) 132 | } else if (task == 2) { 133 | DoubleLog(`\n 积分查询: ✅ ,签到后有积分 ${result.goldCount}`); 134 | } else { 135 | DoubleLog(`\n 积分查询: ❌ ,原因是:${data}`) 136 | } 137 | } catch (e) { 138 | DoubleLog(`查询会员信息异常:${data},原因:${e}`) 139 | } finally { 140 | resolve(); 141 | } 142 | }, timeout) 143 | }) 144 | } 145 | /** 146 | * 签到 147 | * @param timeout 148 | * @returns {Promise} 149 | */ 150 | function signin(timeout = 2000) { 151 | return new Promise((resolve) => { 152 | let url = { 153 | url: `https://app-server.pcauto.com.cn/api/info/sign/register`, 154 | headers: { 155 | 'Content-Type': 'text/plain', 156 | 'Cookie': `common_session_id=${ck}`, 157 | }, 158 | body: '{}', 159 | } 160 | $.post(url, async (error, response, data) => { 161 | try { 162 | let result = JSON.parse(data); 163 | if (result.code == 200) { 164 | DoubleLog(`\n 签到成功: ✅ ,签到${result.message}`) 165 | } else { 166 | DoubleLog(`\n 签到失败: ❌ ,原因是:${result.message}`) 167 | } 168 | } catch (e) { 169 | DoubleLog(`\n 信息异常: ❌ ,${response}`) 170 | } finally { 171 | resolve(); 172 | } 173 | }, timeout) 174 | }) 175 | } 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | // ============================================重写============================================ \\ 201 | async function GetRewrite() { 202 | if ($request.url.indexOf("member/api/info/?userKeys=v1.0&pageName=member-info-index-search&formName=searchForm&kwwMember.memberId") > -1) { 203 | let ck = ''; 204 | let theRequest = new Object(); 205 | if ($request.url.indexOf("?") != -1) { 206 | let info = $request.url.split('?'); 207 | let strs = info[1].split("&"); 208 | for (var i = 0; i < strs.length; i++) { 209 | theRequest[strs[i].split("=")[0]] = unescape(strs[i].split("=")[1]); 210 | } 211 | ck = theRequest.memberId; 212 | } 213 | if (kwwUid) { 214 | if (memberId.indexOf(ck) == -1) { 215 | memberId = memberId + "@" + ck; 216 | $.setdata(memberId, "kwwUid"); 217 | List = memberId.split("@"); 218 | $.msg(`【${$.name}】` + ` 获取第${memberId.length}个 ck 成功: ${ck} ,不用请自行关闭重写!`); 219 | } 220 | } else { 221 | $.setdata(ck, "memberId"); 222 | $.msg(`【${$.name}】` + ` 获取第1个 ck 成功: ${ck} ,不用请自行关闭重写!`); 223 | } 224 | } 225 | } 226 | 227 | 228 | // ============================================变量检查============================================ \\ 229 | async function Envs() { 230 | if (UserCookie) { 231 | if (UserCookie.indexOf("@") != -1) { 232 | UserCookie.split("@").forEach((item) => { 233 | UserCookieArr.push(item); 234 | }); 235 | } else if (UserCookie.indexOf("\n") != -1) { 236 | UserCookie.split("\n").forEach((item) => { 237 | UserCookieArr.push(item); 238 | }); 239 | } else { 240 | UserCookieArr.push(UserCookie); 241 | } 242 | } else { 243 | console.log(`\n 乐客播提示:系统变量未填写 lekebo_tpyqc_Cookie`) 244 | return; 245 | } 246 | return true; 247 | } 248 | // ============================================发送消息============================================ \\ 249 | async function SendMsg(message) { 250 | if (!message) 251 | return; 252 | 253 | if (Notify > 0) { 254 | if ($.isNode()) { 255 | var notify = require('./sendNotify'); 256 | await notify.sendNotify($.name, message); 257 | } else { 258 | $.msg(message); 259 | } 260 | } else { 261 | log(message); 262 | } 263 | } 264 | /** 265 | * 添加消息 266 | * @param str 267 | * @param is_log 268 | */ 269 | function addNotifyStr(str, is_log = true) { 270 | if (is_log) { 271 | log(`${str}\n`) 272 | } 273 | msg += `${str}\n` 274 | } 275 | /** 276 | * 双平台log输出 277 | */ 278 | function DoubleLog(data) { 279 | if ($.isNode()) { 280 | if (data) { 281 | console.log(`${data}`); 282 | msg += `${data}`; 283 | } 284 | } else { 285 | console.log(`${data}`); 286 | msg += `${data}`; 287 | } 288 | } 289 | function randomNum(min, max) { 290 | if (arguments.length === 0) return Math.random() 291 | if (!max) max = 10 ** (Math.log(min) * Math.LOG10E + 1 | 0) - 1 292 | return Math.floor(Math.random() * (max - min + 1) + min); 293 | } 294 | 295 | function DealScriptStr(str) { 296 | str = str.replace(/\/\*.*?\*\//g, ' '); 297 | str = str.replace(/\b0(\d+)/g, '0o$1'); 298 | return str; 299 | } 300 | /** 301 | * 随机UA 302 | * @param inputString 303 | * @returns {*} 304 | */ 305 | function getUA() { 306 | $.UUID = randomString(40) 307 | const buildMap = { 308 | "167814": `10.1.4`, 309 | "167841": `10.1.6`, 310 | "167853": `10.2.0` 311 | } 312 | $.osVersion = `${randomNum(13, 14)}.${randomNum(3, 6)}.${randomNum(1, 3)}` 313 | let network = `network/${['4g', '5g', 'wifi'][randomNum(0, 2)]}` 314 | $.mobile = `iPhone${randomNum(9, 13)},${randomNum(1, 3)}` 315 | $.build = ["167814", "167841", "167853"][randomNum(0, 2)] 316 | $.appVersion = buildMap[$.build] 317 | return `jdapp;iPhone;${$.appVersion};${$.osVersion};${$.UUID};M/5.0;${network};ADID/;model/${$.mobile};addressid/;appBuild/${$.build};jdSupportDarkMode/0;Mozilla/5.0 (iPhone; CPU iPhone OS ${$.osVersion.replace(/\./g, "_")} like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148;supportJDSHWK/1;` 318 | } 319 | 320 | /** 321 | * 随机数生成 322 | */ 323 | function randomString(e) { 324 | e = e || 32; 325 | var t = "QWERTYUIOPASDFGHJKLZXCVBNM1234567890", 326 | a = t.length, 327 | n = ""; 328 | for (i = 0; i < e; i++) 329 | n += t.charAt(Math.floor(Math.random() * a)); 330 | return n 331 | } 332 | 333 | /** 334 | * 修改配置文件 335 | */ 336 | function modify() { 337 | fs.readFile('/ql/data/config/config.sh','utf8',function(err,dataStr){ 338 | if(err){ 339 | return log('读取文件失败!'+err) 340 | } 341 | else { 342 | var result = dataStr.replace(/regular/g,string); 343 | fs.writeFile('/ql/data/config/config.sh', result, 'utf8', function (err) { 344 | if (err) {return log(err);} 345 | }); 346 | } 347 | }) 348 | } 349 | 350 | /** 351 | * 获取远程版本 352 | */ 353 | function getVersion(timeout = 3 * 1000) { 354 | return new Promise((resolve) => { 355 | let url = { 356 | url: `https://ghproxy.com/https://raw.githubusercontent.com/qq274023/lekebo/master/lekebo_kww.js`, 357 | } 358 | $.get(url, async (err, resp, data) => { 359 | try { 360 | scriptVersionLatest = data.match(/scriptVersion = "([\d\.]+)"/)[1] 361 | update_data = data.match(/update_data = "(.*?)"/)[1] 362 | } catch (e) { 363 | $.logErr(e, resp); 364 | } finally { 365 | resolve() 366 | } 367 | }, timeout) 368 | }) 369 | } 370 | 371 | // md5 372 | function MD5Encrypt(a) { function b(a, b) { return a << b | a >>> 32 - b } function c(a, b) { var c, d, e, f, g; return e = 2147483648 & a, f = 2147483648 & b, c = 1073741824 & a, d = 1073741824 & b, g = (1073741823 & a) + (1073741823 & b), c & d ? 2147483648 ^ g ^ e ^ f : c | d ? 1073741824 & g ? 3221225472 ^ g ^ e ^ f : 1073741824 ^ g ^ e ^ f : g ^ e ^ f } function d(a, b, c) { return a & b | ~a & c } function e(a, b, c) { return a & c | b & ~c } function f(a, b, c) { return a ^ b ^ c } function g(a, b, c) { return b ^ (a | ~c) } function h(a, e, f, g, h, i, j) { return a = c(a, c(c(d(e, f, g), h), j)), c(b(a, i), e) } function i(a, d, f, g, h, i, j) { return a = c(a, c(c(e(d, f, g), h), j)), c(b(a, i), d) } function j(a, d, e, g, h, i, j) { return a = c(a, c(c(f(d, e, g), h), j)), c(b(a, i), d) } function k(a, d, e, f, h, i, j) { return a = c(a, c(c(g(d, e, f), h), j)), c(b(a, i), d) } function l(a) { for (var b, c = a.length, d = c + 8, e = (d - d % 64) / 64, f = 16 * (e + 1), g = new Array(f - 1), h = 0, i = 0; c > i;)b = (i - i % 4) / 4, h = i % 4 * 8, g[b] = g[b] | a.charCodeAt(i) << h, i++; return b = (i - i % 4) / 4, h = i % 4 * 8, g[b] = g[b] | 128 << h, g[f - 2] = c << 3, g[f - 1] = c >>> 29, g } function m(a) { var b, c, d = "", e = ""; for (c = 0; 3 >= c; c++)b = a >>> 8 * c & 255, e = "0" + b.toString(16), d += e.substr(e.length - 2, 2); return d } function n(a) { a = a.replace(/\r\n/g, "\n"); for (var b = "", c = 0; c < a.length; c++) { var d = a.charCodeAt(c); 128 > d ? b += String.fromCharCode(d) : d > 127 && 2048 > d ? (b += String.fromCharCode(d >> 6 | 192), b += String.fromCharCode(63 & d | 128)) : (b += String.fromCharCode(d >> 12 | 224), b += String.fromCharCode(d >> 6 & 63 | 128), b += String.fromCharCode(63 & d | 128)) } return b } var o, p, q, r, s, t, u, v, w, x = [], y = 7, z = 12, A = 17, B = 22, C = 5, D = 9, E = 14, F = 20, G = 4, H = 11, I = 16, J = 23, K = 6, L = 10, M = 15, N = 21; for (a = n(a), x = l(a), t = 1732584193, u = 4023233417, v = 2562383102, w = 271733878, o = 0; o < x.length; o += 16)p = t, q = u, r = v, s = w, t = h(t, u, v, w, x[o + 0], y, 3614090360), w = h(w, t, u, v, x[o + 1], z, 3905402710), v = h(v, w, t, u, x[o + 2], A, 606105819), u = h(u, v, w, t, x[o + 3], B, 3250441966), t = h(t, u, v, w, x[o + 4], y, 4118548399), w = h(w, t, u, v, x[o + 5], z, 1200080426), v = h(v, w, t, u, x[o + 6], A, 2821735955), u = h(u, v, w, t, x[o + 7], B, 4249261313), t = h(t, u, v, w, x[o + 8], y, 1770035416), w = h(w, t, u, v, x[o + 9], z, 2336552879), v = h(v, w, t, u, x[o + 10], A, 4294925233), u = h(u, v, w, t, x[o + 11], B, 2304563134), t = h(t, u, v, w, x[o + 12], y, 1804603682), w = h(w, t, u, v, x[o + 13], z, 4254626195), v = h(v, w, t, u, x[o + 14], A, 2792965006), u = h(u, v, w, t, x[o + 15], B, 1236535329), t = i(t, u, v, w, x[o + 1], C, 4129170786), w = i(w, t, u, v, x[o + 6], D, 3225465664), v = i(v, w, t, u, x[o + 11], E, 643717713), u = i(u, v, w, t, x[o + 0], F, 3921069994), t = i(t, u, v, w, x[o + 5], C, 3593408605), w = i(w, t, u, v, x[o + 10], D, 38016083), v = i(v, w, t, u, x[o + 15], E, 3634488961), u = i(u, v, w, t, x[o + 4], F, 3889429448), t = i(t, u, v, w, x[o + 9], C, 568446438), w = i(w, t, u, v, x[o + 14], D, 3275163606), v = i(v, w, t, u, x[o + 3], E, 4107603335), u = i(u, v, w, t, x[o + 8], F, 1163531501), t = i(t, u, v, w, x[o + 13], C, 2850285829), w = i(w, t, u, v, x[o + 2], D, 4243563512), v = i(v, w, t, u, x[o + 7], E, 1735328473), u = i(u, v, w, t, x[o + 12], F, 2368359562), t = j(t, u, v, w, x[o + 5], G, 4294588738), w = j(w, t, u, v, x[o + 8], H, 2272392833), v = j(v, w, t, u, x[o + 11], I, 1839030562), u = j(u, v, w, t, x[o + 14], J, 4259657740), t = j(t, u, v, w, x[o + 1], G, 2763975236), w = j(w, t, u, v, x[o + 4], H, 1272893353), v = j(v, w, t, u, x[o + 7], I, 4139469664), u = j(u, v, w, t, x[o + 10], J, 3200236656), t = j(t, u, v, w, x[o + 13], G, 681279174), w = j(w, t, u, v, x[o + 0], H, 3936430074), v = j(v, w, t, u, x[o + 3], I, 3572445317), u = j(u, v, w, t, x[o + 6], J, 76029189), t = j(t, u, v, w, x[o + 9], G, 3654602809), w = j(w, t, u, v, x[o + 12], H, 3873151461), v = j(v, w, t, u, x[o + 15], I, 530742520), u = j(u, v, w, t, x[o + 2], J, 3299628645), t = k(t, u, v, w, x[o + 0], K, 4096336452), w = k(w, t, u, v, x[o + 7], L, 1126891415), v = k(v, w, t, u, x[o + 14], M, 2878612391), u = k(u, v, w, t, x[o + 5], N, 4237533241), t = k(t, u, v, w, x[o + 12], K, 1700485571), w = k(w, t, u, v, x[o + 3], L, 2399980690), v = k(v, w, t, u, x[o + 10], M, 4293915773), u = k(u, v, w, t, x[o + 1], N, 2240044497), t = k(t, u, v, w, x[o + 8], K, 1873313359), w = k(w, t, u, v, x[o + 15], L, 4264355552), v = k(v, w, t, u, x[o + 6], M, 2734768916), u = k(u, v, w, t, x[o + 13], N, 1309151649), t = k(t, u, v, w, x[o + 4], K, 4149444226), w = k(w, t, u, v, x[o + 11], L, 3174756917), v = k(v, w, t, u, x[o + 2], M, 718787259), u = k(u, v, w, t, x[o + 9], N, 3951481745), t = c(t, p), u = c(u, q), v = c(v, r), w = c(w, s); var O = m(t) + m(u) + m(v) + m(w); return O.toLowerCase() } 373 | // 完整 Env 374 | 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"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.get(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { try { if (t.headers["set-cookie"]) { const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar } } catch (t) { this.logErr(t) } }).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) })) } post(t, e = (() => { })) { if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.post(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) }); else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t)); else if (this.isNode()) { this.initGotEnv(t); const { url: s, ...i } = t; this.got.post(s, i).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) }) } } time(t, e = null) { const s = e ? new Date(e) : new Date; let i = { "M+": s.getMonth() + 1, "d+": s.getDate(), "H+": s.getHours(), "m+": s.getMinutes(), "s+": s.getSeconds(), "q+": Math.floor((s.getMonth() + 3) / 3), S: s.getMilliseconds() }; /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); return t } msg(e = t, s = "", i = "", r) { const o = t => { if (!t) return t; if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { "open-url": t } : this.isSurge() ? { url: t } : void 0; if ("object" == typeof t) { if (this.isLoon()) { let e = t.openUrl || t.url || t["open-url"], s = t.mediaUrl || t["media-url"]; return { openUrl: e, mediaUrl: s } } if (this.isQuanX()) { let e = t["open-url"] || t.url || t.openUrl, s = t["media-url"] || t.mediaUrl; return { "open-url": e, "media-url": s } } if (this.isSurge()) { let e = t.url || t.openUrl || t["open-url"]; return { url: e } } } }; if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { let t = ["", "==============📣系统通知📣=============="]; t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) } } log(...t) { t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) } logErr(t, e) { const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) } wait(t) { return new Promise(e => setTimeout(e, t)) } done(t = {}) { const e = (new Date).getTime(), s = (e - this.startTime) / 1e3; this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) } }(t, e) } 375 | -------------------------------------------------------------------------------- /tvbox: -------------------------------------------------------------------------------- 1 | //目前线路 个人自用 来源均为网络搜集 请勿贩卖 2 | { 3 | "urls": [ 4 | { 5 | "url": "http://www.饭太硬.com/tv", 6 | "name": "【推荐】饭太硬接口" 7 | }, 8 | { 9 | "url": "http://肥猫.live", 10 | "name": "肥猫接口" 11 | }, 12 | { 13 | "url": "http://pandown.pro/tvbox/tvbox.json", 14 | "name": "巧计线路" 15 | }, 16 | { 17 | "url": "http://rihou.cc:99/荷城茶秀", 18 | "name": "荷城茶秀线路" 19 | }, 20 | { 21 | "url": "http://xhww.fun/小米/DEMO.json", 22 | "name": "小米接口" 23 | }, 24 | { 25 | "url": "http://tv.nxog.top/m/", 26 | "name": "讴歌线路" 27 | }, 28 | { 29 | "url": "https://github.moeyy.xyz/https://raw.githubusercontent.com/xyq254245/xyqonlinerule/main/XYQTVBox.json", 30 | "name": "香雅情镜像线路" 31 | }, 32 | { 33 | "url": "https://mirror.ghproxy.com/raw.githubusercontent.com/PizazzGY/TVBox/main/api.json", 34 | "name": "酷安潇洒哥线路" 35 | }, 36 | { 37 | "url": "https://mirror.ghproxy.com/raw.githubusercontent.com/gaotianliuyun/gao/master/0827.json", 38 | "name": "FongMI线路" 39 | }, 40 | { 41 | "url": "http://bp.tvbox.cam/", 42 | "name": "小白线路" 43 | }, 44 | { 45 | "url": "http://itvbox.cc/tvbox/云星日记/1.m3u8", 46 | "name": "云星日记线路" 47 | }, 48 | { 49 | "url": "https://100km.top/0", 50 | "name": "骚0线路" 51 | }, 52 | { 53 | "url": "https://wds.ecsxs.com/230989.json", 54 | "name": "春盈天下线路 py" 55 | }, 56 | { 57 | "url": "https://tvbox.cainisi.cf/", 58 | "name": "菜妮丝 XBPQ" 59 | }, 60 | { 61 | "url": "https://mirror.ghproxy.com/raw.githubusercontent.com/gaotianliuyun/gao/master/js.json", 62 | "name": "高天流云js" 63 | }, 64 | { 65 | "url": "https://mirror.ghproxy.com/raw.githubusercontent.com/gaotianliuyun/gao/master/XYQ.json", 66 | "name": "高天流云 XYQ" 67 | }, 68 | { 69 | "url": "https://agit.ai/Yoursmile7/TVBox/raw/branch/master/XC.json", 70 | "name": "南风线路" 71 | }, 72 | { 73 | "url": "https://神器每日推送.tk/pz.json", 74 | "name": "神器线路" 75 | }, 76 | { 77 | "url": "https://notabug.org/imbig66/tv-spider-man/raw/master/%E9%85%8D%E7%BD%AE/0801.json", 78 | "name": "胖虎线路" 79 | } 80 | ] 81 | } 82 | -------------------------------------------------------------------------------- /xsgjz(1).py: -------------------------------------------------------------------------------- 1 | #变量xsgCookie,抓取小时工记账的authorization变量 2 | #定时调成5 6-18/6 * * * 3 | 4 | from cgitb import text 5 | import json 6 | import time 7 | import requests as r 8 | import requests 9 | import re 10 | import json 11 | import os 12 | 13 | #获取名字链接 14 | mzurl = "https://xsg-api.julanling.com/app/user/info" 15 | #获取金币数量链接 16 | jburl = "https://xsg-api.julanling.com/h5/api/activityThirdAccount/coin/getAccount" 17 | #签到链接 18 | signurl = "https://market-gateway.julanling.com/market-center/api2/signIn/signIn" 19 | #转盘链接 20 | zpurl = "https://market-gateway.julanling.com/market-center/api2/dial/luckyDraw" 21 | #转盘金币领奖链接 22 | zpljurl = "https://market-gateway.julanling.com/market-center/api2/dial/receiveDialCoin" 23 | #转盘宝箱领奖链接 24 | zpbxurl = "https://market-gateway.julanling.com/market-center/api2/dial/openBox" 25 | #转盘双倍卡链接 26 | zpsburl = "https://market-gateway.julanling.com/market-center/api2/dial/receiveDoubleCardBag" 27 | #获取宝箱状态 28 | bxzturl= "https://market-gateway.julanling.com/market-center/api2/dial/detailCore?appVersion=4.4.20" 29 | #刷新扭蛋状态 30 | ndsxurl = "https://market-gateway.julanling.com/market-center/api2/gacha/index?os=ANDROID&appVersion=4.4.20" 31 | #扭蛋链接 32 | ndurl = "https://market-gateway.julanling.com/market-center/api2/gacha/luckyDraw" 33 | #扭蛋广告链接 34 | ndadurl = "https://market-gateway.julanling.com/market-center/api2/gacha/finishGachaTask" 35 | #7次广告链接 36 | qiadurl = "https://market-gateway.julanling.com/market-center/api2/assignment/finishAssignment" 37 | 38 | 39 | 40 | if os.environ.get("xsgCookie"): 41 | dvm = os.environ["xsgCookie"] 42 | if dvm != '': 43 | if "@" in dvm: 44 | Coo = dvm.split("@") 45 | elif "&" in dvm: 46 | Coo = dvm.split('&') 47 | else: 48 | Coo = dvm.split('\n') 49 | adv=1 50 | for i in Coo: 51 | headers = { 52 | "security": "cD1jb20uanVsYW5nbGluZy54c2dqeiZjPXhzZ2p6X3lpbmd5b25nYmFvJnY9NC40LjIwJmQ9MzU1MWU0MDFiYjQ0MWVlY2JiNDU5ZjkwMDE1MzJlMzEmdT1ZN2wyVitQNWdOd0RBRFZjR0huQ2VzbXAmdD0xNjczMDk4OTY5.7e9e9d0818df515f6a384d9d5debde40", 53 | "authorization": i, 54 | "user-agent": 'Mozilla/5.0 (Linux; Android 11; M2012K11AC Build/RKQ1.200826.002; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/107.0.5304.105 Mobile Safari/537.36;_android{"version":4420,"versionName":"4.4.20","userType":"1","sdkVersion":"30","statusBarHeight":29,"toolBarHeight":73,"imei":"","oaid":"ad58bc17b41a81c7","channel":"xsgjz_yingyongbao","uid":10522}_android', 55 | "content-type": "application/json;charset=UTF-8" 56 | } 57 | print(f'登录第{adv}个账号') 58 | adv=adv+1 59 | 60 | #登录验证 61 | resp = r.post(mzurl, headers=headers) 62 | xx = json.loads(resp.text) 63 | if xx["results"] == "null": 64 | print("登录失败,请重新获取Authorization") 65 | continue 66 | else: 67 | print("用户ID:"+xx["results"]["nickname"]) 68 | 69 | #获取金币数量 70 | jb = r.post(jburl, headers=headers) 71 | xb = json.loads(jb.text) 72 | if xb["results"] == "null": 73 | print("获取金币失败,请检测Authorization是否可用") 74 | else: 75 | print("目前金币数量:"+str(xb["results"]["credits"])) 76 | print("可提现:"+str(xb["results"]["aboutAmount"])) 77 | print("今日赚取金币数量:"+str(xb["results"]["currentCredits"])) 78 | 79 | time.sleep(2) 80 | 81 | #签到 82 | qdbody = {"os":"ANDROID","appVersion":"4.4.20","appChannel":"xsgjz_yingyongbao","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9"} 83 | qd = r.post(signurl, headers=headers, json=qdbody) 84 | qdd = json.loads(qd.text) 85 | print("开始签到") 86 | if qdd["errorCode"] == 0: 87 | print("签到成功获取金币:"+str(qdd["results"]["amount"])) 88 | else: 89 | print("签到失败原因:"+str(qdd["errorStr"])) 90 | 91 | time.sleep(2) 92 | 93 | #转转盘 94 | nc=1 95 | zzpyz = r.get(bxzturl, headers=headers) 96 | zptz = json.loads(zzpyz.text) 97 | zpsycs = str(zptz["results"]["dialValidNum"]) 98 | print("转盘剩余次数"+zpsycs) 99 | zpsycs=int(zpsycs) 100 | for o in range(zpsycs): 101 | print("开始第"+str(nc)+"次转盘") 102 | time.sleep(3) 103 | nc=nc+1 104 | body = {"appChannel":"xsgjz_yingyongbao","appVersion":"4.4.20","appPackage":"com.julangling.xsgjz","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","operatingSystem":"ANDROID"} 105 | zp = r.post(zpurl, headers=headers,json=body) 106 | zpp = json.loads(zp.text) 107 | if zpp["errorCode"] == 0: 108 | if zpp["results"]["awardType"] == "GOLD": 109 | biz = zpp["results"]["bizNo"] 110 | zpbody = { 111 | "bizNo":biz, 112 | "appChannel":"xsgjz_yingyongbao", 113 | "appVersion":"4.4.20", 114 | "appPackage":"com.julangling.xsgjz", 115 | "deviceToken":"19a9e4453155dcbc348f5fbff0c075c9", 116 | "operatingSystem":"ANDROID" 117 | } 118 | time.sleep(3) 119 | lj = r.post(zpljurl, headers=headers,json=zpbody) 120 | ljj = json.loads(lj.text) 121 | print("抽到金币"+str(ljj["results"]["amount"])) 122 | 123 | elif zpp["results"]["awardType"] == "DOUBLE_VIDEO": 124 | print("抽到双倍卡,需要观看广告") 125 | biz = zpp["results"]["bizNo"] 126 | zpbody = { 127 | "bizNo":biz, 128 | "appChannel":"xsgjz_yingyongbao", 129 | "appVersion":"4.4.20", 130 | "appPackage":"com.julangling.xsgjz", 131 | "deviceToken":"19a9e4453155dcbc348f5fbff0c075c9", 132 | "operatingSystem":"ANDROID" 133 | } 134 | time.sleep(3) 135 | sb = r.post(zpsburl, headers=headers,json=zpbody) 136 | sbb = json.loads(sb.text) 137 | print("观看成功剩余翻倍奖励次数"+str(sbb["results"]["dialCardBag"]["DOUBLE"])) 138 | 139 | print("转盘结束,查看可领取那些宝箱") 140 | #转盘5次宝箱奖励body 141 | bx1={"businessType":"XSG_BOX_ONE","appChannel":"xsgjz_yingyongbao","appVersion":"4.4.20","appPackage":"com.julangling.xsgjz","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","operatingSystem":"ANDROID"} 142 | #转盘18次宝箱奖励body 143 | bx2={"businessType":"XSG_BOX_TWO","appChannel":"xsgjz_yingyongbao","appVersion":"4.4.20","appPackage":"com.julangling.xsgjz","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","operatingSystem":"ANDROID"} 144 | #转盘30次宝箱奖励body 145 | bx3={"businessType":"XSG_BOX_THREE","appChannel":"xsgjz_yingyongbao","appVersion":"4.4.20","appPackage":"com.julangling.xsgjz","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","operatingSystem":"ANDROID"} 146 | #转盘55次宝箱奖励body 147 | bx4={"businessType":"XSG_BOX_FOUR","appChannel":"xsgjz_yingyongbao","appVersion":"4.4.20","appPackage":"com.julangling.xsgjz","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","operatingSystem":"ANDROID"} 148 | 149 | #转盘宝箱领取 150 | time.sleep(3) 151 | print("开始领转盘5次箱子奖励") 152 | zpbx1 = r.post(zpbxurl, headers=headers,json=bx1) 153 | bxx1 = json.loads(zpbx1.text) 154 | if bxx1["errorCode"] == 0: 155 | results = bxx1['results'] 156 | openBoxAwards = results['openBoxAwards'] 157 | bx1jb = openBoxAwards[0]['amount'] 158 | print("领取成功获得"+str(bx1jb)+"金币") 159 | else: 160 | print("领取失败,原因:"+str(bxx1["errorStr"])) 161 | time.sleep(3) 162 | 163 | time.sleep(3) 164 | print("开始领转盘18次箱子奖励") 165 | zpbx2 = r.post(zpbxurl, headers=headers,json=bx2) 166 | bxx2 = json.loads(zpbx2.text) 167 | if bxx2["errorCode"] == 0: 168 | results2 = bxx2['results'] 169 | openBoxAwards2 = results2['openBoxAwards'] 170 | bx2jb = openBoxAwards2[0]['amount'] 171 | print("领取成功获得"+str(bx2jb)+"金币") 172 | bxbizNo2 = bxx2['results']['openBoxAwards'][1]['bizNo'] 173 | print("领取箱子双倍卡,需要观看广告") 174 | zpbody = { 175 | "bizNo":bxbizNo2, 176 | "appChannel":"xsgjz_yingyongbao", 177 | "appVersion":"4.4.20", 178 | "appPackage":"com.julangling.xsgjz", 179 | "deviceToken":"19a9e4453155dcbc348f5fbff0c075c9", 180 | "operatingSystem":"ANDROID" 181 | } 182 | time.sleep(3) 183 | sb = r.post(zpsburl, headers=headers,json=zpbody) 184 | sbb = json.loads(sb.text) 185 | print("观看成功剩余翻倍奖励次数"+str(sbb["results"]["dialCardBag"]["DOUBLE"])) 186 | del bxx2 187 | del results2 188 | del openBoxAwards2 189 | del bx2jb 190 | del bxbizNo2 191 | del sb 192 | del sbb 193 | else: 194 | print("领取失败,原因:"+str(bxx2["errorStr"])) 195 | time.sleep(3) 196 | 197 | 198 | time.sleep(5) 199 | print("开始领转盘30次箱子奖励") 200 | zpbx3 = r.post(zpbxurl, headers=headers,json=bx3) 201 | bxx3 = json.loads(zpbx3.text) 202 | if bxx3["errorCode"] == 0: 203 | results3 = bxx3['results'] 204 | openBoxAwards3 = results3['openBoxAwards'] 205 | bx3jb = openBoxAwards3[0]['amount'] 206 | print("领取成功获得"+str(bx3jb)+"金币") 207 | bxbizNo3 = bxx3['results']['openBoxAwards'][1]['bizNo'] 208 | print("领取箱子双倍卡,需要观看广告") 209 | zpbody = { 210 | "bizNo":bxbizNo3, 211 | "appChannel":"xsgjz_yingyongbao", 212 | "appVersion":"4.4.20", 213 | "appPackage":"com.julangling.xsgjz", 214 | "deviceToken":"19a9e4453155dcbc348f5fbff0c075c9", 215 | "operatingSystem":"ANDROID" 216 | } 217 | time.sleep(3) 218 | sb = r.post(zpsburl, headers=headers,json=zpbody) 219 | sbb = json.loads(sb.text) 220 | print("观看成功剩余翻倍奖励次数"+str(sbb["results"]["dialCardBag"]["DOUBLE"])) 221 | del bxx3 222 | del results3 223 | del openBoxAwards3 224 | del bx3jb 225 | del bxbizNo3 226 | del sb 227 | del sbb 228 | else: 229 | print("领取失败,原因:"+str(bxx3["errorStr"])) 230 | time.sleep(3) 231 | 232 | 233 | 234 | time.sleep(3) 235 | print("开始领转盘55次箱子奖励") 236 | zpbx4 = r.post(zpbxurl, headers=headers,json=bx4) 237 | bxx4 = json.loads(zpbx4.text) 238 | if bxx4["errorCode"] == 0: 239 | results4 = bxx4['results'] 240 | openBoxAwards4 = results4['openBoxAwards'] 241 | bx4jb = openBoxAwards4[0]['amount'] 242 | print("领取成功获得"+str(bx4jb)+"金币") 243 | bxbizNo4 = bxx4['results']['openBoxAwards'][1]['bizNo'] 244 | print("领取箱子双倍卡,需要观看广告") 245 | zpbody = { 246 | "bizNo":bxbizNo4, 247 | "appChannel":"xsgjz_yingyongbao", 248 | "appVersion":"4.4.20", 249 | "appPackage":"com.julangling.xsgjz", 250 | "deviceToken":"19a9e4453155dcbc348f5fbff0c075c9", 251 | "operatingSystem":"ANDROID" 252 | } 253 | time.sleep(3) 254 | sb = r.post(zpsburl, headers=headers,json=zpbody) 255 | sbb = json.loads(sb.text) 256 | print("观看成功剩余翻倍奖励次数"+str(sbb["results"]["dialCardBag"]["DOUBLE"])) 257 | del bxx4 258 | del results4 259 | del openBoxAwards4 260 | del bx4jb 261 | del bxbizNo4 262 | del sb 263 | del sbb 264 | else: 265 | print("领取失败,原因:"+str(bxx4["errorStr"])) 266 | time.sleep(3) 267 | 268 | 269 | 270 | #扭蛋 271 | vc=1 272 | bc=1 273 | #先刷新扭蛋列表 274 | ndsx = r.get(ndsxurl, headers=headers) 275 | ndsxx = json.loads(ndsx.text) 276 | #判断扭蛋广告可观看次数 277 | ndadcs= ndsxx["results"]["remainVideoTimes"] 278 | print("扭蛋广告剩余次数"+str(ndadcs)) 279 | #观看扭蛋广告 280 | for o in range(ndadcs): 281 | print("开始第"+str(bc)+"次观看扭蛋广告") 282 | bc=bc+1 283 | time.sleep(3) 284 | ndadbody={"businessType":"XSG_DAILY_GACHA_INC_VIDEOS","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","version":"4.4.20","os":"ANDROID","appVersion":"4.4.20","appChannel":"unknow"} 285 | ndad = r.post(ndadurl, headers=headers,json=ndadbody) 286 | nddad = json.loads(ndad.text) 287 | if nddad['errorCode'] == 0: 288 | print("获得"+str(nddad["results"]["amount"])+"次抽奖次数") 289 | print("目前有"+str(nddad["results"]["remainTimes"])+"次抽奖次数") 290 | time.sleep(3) 291 | else: 292 | print("扭蛋失败原因"+nddad['errorStr']) 293 | 294 | 295 | ndsx = r.get(ndsxurl, headers=headers) 296 | ndsxx = json.loads(ndsx.text) 297 | #判断扭蛋次数 298 | ndsycs = ndsxx["results"]["remainTimes"] 299 | print("扭蛋剩余次数"+str(ndsycs)) 300 | #开始扭蛋 301 | for o in range(ndsycs): 302 | print("开始第"+str(vc)+"次扭蛋") 303 | vc=vc+1 304 | time.sleep(3) 305 | ndbody={"deviceToken":"19a9e4453155dcbc348f5fbff0c075c9","version":"4.4.20","os":"ANDROID","appVersion":"4.4.20","appChannel":"unknow"} 306 | nd = r.post(ndurl, headers=headers,json=ndbody) 307 | ndd = json.loads(nd.text) 308 | if ndd['errorCode'] == 0: 309 | if ndd["results"]["awardType"] == 'ADVERT': 310 | print("抽到了空气广告") 311 | else: 312 | print("抽到"+str(ndd["results"]["name"])) 313 | else: 314 | print("扭蛋失败原因"+ndd['errorStr']) 315 | 316 | time.sleep(3) 317 | #看广告7次 318 | for c in range(7): 319 | qiadbody={"businessType":"XSG_MONEY_CENTER_INCENTIVE_VIDEO","os":"ANDROID","appVersion":"4.4.20","appChannel":"xsgjz_yingyongbao","deviceToken":"19a9e4453155dcbc348f5fbff0c075c9"} 320 | adws = r.post(qiadurl, headers=headers,json=qiadbody) 321 | adwss = json.loads(adws.text) 322 | if adwss['errorCode'] == 0: 323 | adwssjb = adwss["results"]["awardInfos"] 324 | adwssjbb = adwssjb[0]['amount'] 325 | print("获得金币"+str(adwssjbb)+"个") 326 | print("等待20秒,才可以观看广告") 327 | time.sleep(21) 328 | else: 329 | 330 | break 331 | 332 | 333 | 334 | -------------------------------------------------------------------------------- /zstj.js: -------------------------------------------------------------------------------- 1 | /* 2 | 日期: 2023/1/31 17:00 3 | 4 | APP:掌上天津极速版 5 | HOST:bbs.zaitianjin.net 6 | export zstjhd='userId&salf' 7 | */ 8 | const $ = new Env('掌上天津极速版'); 9 | const axios = require('axios'); 10 | const CryptoJS = require('crypto-js'); 11 | let request = require("request"); 12 | request = request.defaults({ 13 | jar: true 14 | }); 15 | const { 16 | log 17 | } = console; 18 | const Notify = 1; //0为关闭通知,1为打开通知,默认为1 19 | const debug = 0; //0为关闭调试,1为打开调试,默认为0 20 | 21 | let zstjhd = ($.isNode() ? process.env.zstjhd : $.getdata("zstjhd")) || "" 22 | let zstjhdArr = []; 23 | let data = ''; 24 | let msg = ''; 25 | var hours = new Date().getMonth(); 26 | 27 | var timestamp = Math.round(new Date().getTime()/1000).toString(); 28 | !(async () => { 29 | if (typeof $request !== "undefined") { 30 | await GetRewrite(); 31 | } else { 32 | if (!(await Envs())) 33 | return; 34 | else { 35 | 36 | log(`\n\n============================================= \n脚本执行 - 北京时间(UTC+8):${new Date( 37 | new Date().getTime() + new Date().getTimezoneOffset() * 60 * 1000 + 38 | 8 * 60 * 60 * 1000).toLocaleString()} \n=============================================\n`); 39 | 40 | 41 | 42 | log(`\n============ 微信公众号:福利社 ============`) 43 | log(`\n=================== 共找到 ${zstjhdArr.length} 个账号 ===================`) 44 | if (debug) { 45 | log(`【debug】 这是你的全部账号数组:\n ${zstjhdArr}`); 46 | } 47 | for (let index = 0; index < zstjhdArr.length; index++) { 48 | 49 | let num = index + 1 50 | addNotifyStr(`\n==== 开始【第 ${num} 个账号】====\n`, true) 51 | 52 | zstjhd = zstjhdArr[index]; 53 | uid = zstjhd.split('&')[0] 54 | salf = zstjhd.split('&')[1] 55 | 56 | await sign() 57 | await signinfo() 58 | 59 | } 60 | //await SendMsg(msg); 61 | } 62 | } 63 | })() 64 | .catch((e) => log(e)) 65 | .finally(() => $.done()) 66 | async function signinfo() { 67 | t = timestamp 68 | macs = genmac() 69 | mac = encodeURIComponent(macs) 70 | 71 | s ='brand=OPPO&client=android&deviceInfo=OPPO_PCAM00_2021040100_10&interfaceVersion=v2.8&lat=30.1&lng=114.2&mac='+macs+'&model=PCAM00&privacyStatus=1®ion=天津市&salf='+salf+'×tamp='+t+'&uid='+uid+'&userId='+uid+'&version=2.8.4&versionCode=154' 72 | s = encode(s) 73 | 74 | signs = CryptoJS.HmacSHA1(s, '1s_vsegymTasdgKxiKvRz5vDlyzmc92A_H6A8zg6I').toString().toUpperCase() 75 | return new Promise((resolve) => { 76 | var options = { 77 | method: 'POST', 78 | url: 'https://bbs.zaitianjin.net/zstj/v2.8/index.php', 79 | headers: { 80 | 'Content-Type': 'application/x-www-form-urlencoded', 81 | 'Host': 'bbs.zaitianjin.net', 82 | 'Connection': 'Keep-Alive', 83 | 'Accept-Encoding': 'gzip', 84 | 'User-Agent': 'okhttp/4.9.3' 85 | }, 86 | data: 'c=User&lng=114.2&privacyStatus=1&sign='+signs+'&interfaceVersion=v2.8&version=2.8.4&userId='+uid+'&m=signInfo&mac='+mac+'&versionCode=154&deviceInfo=OPPO_PCAM00_2021040100_10&uid='+uid+'&client=android&model=PCAM00®ion=%E5%A4%A9%E6%B4%A5%E5%B8%82&salf='+salf+'&brand=OPPO&lat=30.1×tamp='+t 87 | }; 88 | if (debug) { 89 | log(`\n【debug】=============== 这是 请求 url ===============`); 90 | log(JSON.stringify(options)); 91 | } 92 | axios.request(options).then(async function(response) { 93 | try { 94 | data = response.data; 95 | if (debug) { 96 | log(`\n\n【debug】===============这是 返回data==============`); 97 | log(JSON.stringify(response.data)); 98 | } 99 | if(data.code == 1){ 100 | log('签到天数: '+data.data.signDays) 101 | 102 | log('累计签到天数: '+data.data.signAllDays) 103 | 104 | log('今日是否签到: '+data.data.signStatue) 105 | 106 | log('连续签到7天奖励: '+data.data.signData) 107 | 108 | }else log(data.codemsg) 109 | 110 | 111 | 112 | } catch (e) { 113 | log(`异常:${data},原因:${data.codemsg}`) 114 | } 115 | }).catch(function(error) { 116 | console.error(error); 117 | }).then(res => { 118 | //这里处理正确返回 119 | resolve(); 120 | }); 121 | }) 122 | 123 | } 124 | async function sign() { 125 | t = timestamp 126 | macs = genmac() 127 | mac = encodeURIComponent(macs) 128 | 129 | s ='brand=OPPO&client=android&deviceInfo=OPPO_PCAM00_2021040100_10&interfaceVersion=v2.8&lat=30.1&lng=114.2&mac='+macs+'&model=PCAM00&privacyStatus=1®ion=天津市&salf='+salf+'×tamp='+t+'&uid='+uid+'&userId='+uid+'&version=2.8.4&versionCode=154' 130 | s = encode(s) 131 | 132 | signs = CryptoJS.HmacSHA1(s, '1s_vsegymTasdgKxiKvRz5vDlyzmc92A_H6A8zg6I').toString().toUpperCase() 133 | return new Promise((resolve) => { 134 | var options = { 135 | method: 'POST', 136 | url: 'https://bbs.zaitianjin.net/zstj/v2.8/index.php', 137 | headers: { 138 | 'Content-Type': 'application/x-www-form-urlencoded', 139 | 'Host': 'bbs.zaitianjin.net', 140 | 'Connection': 'Keep-Alive', 141 | 'Accept-Encoding': 'gzip', 142 | 'User-Agent': 'okhttp/4.9.3' 143 | }, 144 | 145 | data: 'c=Credit&lng=114.2&privacyStatus=1&sign='+signs+'&interfaceVersion=v2.8&version=2.8.4&userId='+uid+'&m=sign&mac='+mac+'&versionCode=154&deviceInfo=OPPO_PCAM00_2021040100_10&uid='+uid+'&client=android&model=PCAM00®ion=%E5%A4%A9%E6%B4%A5%E5%B8%82&salf='+salf+'&brand=OPPO&lat=30.1×tamp='+t 146 | 147 | }; 148 | if (debug) { 149 | log(`\n【debug】=============== 这是 请求 url ===============`); 150 | log(JSON.stringify(options)); 151 | } 152 | axios.request(options).then(async function(response) { 153 | try { 154 | data = response.data; 155 | if (debug) { 156 | log(`\n\n【debug】===============这是 返回data==============`); 157 | log(JSON.stringify(response.data)); 158 | } 159 | if(data.code == 1){ 160 | log(data.codemsg) 161 | 162 | }else log(data.codemsg) 163 | 164 | 165 | 166 | } catch (e) { 167 | log(`异常:${data},原因:${data.codemsg}`) 168 | } 169 | }).catch(function(error) { 170 | console.error(error); 171 | }).then(res => { 172 | //这里处理正确返回 173 | resolve(); 174 | }); 175 | }) 176 | 177 | } 178 | async function Envs() { 179 | if (zstjhd) { 180 | if (zstjhd.indexOf("@") != -1) { 181 | zstjhd.split("@").forEach((item) => { 182 | 183 | zstjhdArr.push(item); 184 | }); 185 | } else if (zstjhd.indexOf("\n") != -1) { 186 | zstjhd.split("\n").forEach((item) => { 187 | zstjhdArr.push(item); 188 | }); 189 | } else { 190 | zstjhdArr.push(zstjhd); 191 | } 192 | } else { 193 | log(`\n 【${$.name}】:未填写变量 zstjhd`) 194 | return; 195 | } 196 | 197 | return true; 198 | } 199 | function addNotifyStr(str, is_log = true) { 200 | if (is_log) { 201 | log(`${str}\n`) 202 | } 203 | msg += `${str}\n` 204 | } 205 | 206 | 207 | function encode(str){ 208 | //var b = new Buffer(str); 209 | var b = Buffer.from(str); 210 | var s = b.toString('base64'); 211 | var s = s.replace(/\//g,'_') 212 | return s 213 | } 214 | 215 | 216 | 217 | 218 | function genmac(){var ran1=ran1=Math.floor(Math.random()*256);ran1=ran1.toString(16).toUpperCase();if(ran1.length==1)ran1="0"+ran1;var ran2=Math.floor(Math.random()*256);ran2=ran2.toString(16).toUpperCase();if(ran2.length==1)ran2="0"+ran2;var ran3=Math.floor(Math.random()*256);ran3=ran3.toString(16).toUpperCase();if(ran3.length==1)ran3="0"+ran3;var ran4=Math.floor(Math.random()*256);ran4=ran4.toString(16).toUpperCase();if(ran4.length==1)ran4="0"+ran4;var ran5=Math.floor(Math.random()*256);ran5=ran5.toString(16).toUpperCase();if(ran5.length==1)ran5="0"+ran5;var ran6=Math.floor(Math.random()*256);ran6=ran6.toString(16).toUpperCase();if(ran6.length==1)ran6="0"+ran6;var res="";res=ran1+":"+ran2+":"+ran3+":"+ran4+":"+ran5+":"+ran6;return res;} 219 | // ============================================发送消息============================================ \\ 220 | async function SendMsg(message) { 221 | if (!message) 222 | return; 223 | 224 | if (Notify > 0) { 225 | if ($.isNode()) { 226 | var notify = require('./sendNotify'); 227 | await notify.sendNotify($.name, message); 228 | } else { 229 | $.msg(message); 230 | } 231 | } else { 232 | log(message); 233 | } 234 | } 235 | 236 | function Env(t, e) { 237 | "undefined" != typeof process && JSON.stringify(process.env).indexOf("GITHUB") > -1 && process.exit(0); 238 | 239 | class s { 240 | constructor(t) { 241 | this.env = t 242 | } 243 | 244 | send(t, e = "GET") { 245 | t = "string" == typeof t ? { 246 | url: t 247 | } : t; 248 | let s = this.get; 249 | return "POST" === e && (s = this.post), new Promise((e, i) => { 250 | s.call(this, t, (t, s, r) => { 251 | t ? i(t) : e(s) 252 | }) 253 | }) 254 | } 255 | 256 | get(t) { 257 | return this.send.call(this.env, t) 258 | } 259 | 260 | post(t) { 261 | return this.send.call(this.env, t, "POST") 262 | } 263 | } 264 | 265 | return new class { 266 | constructor(t, e) { 267 | 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}, 开始!`) 268 | } 269 | 270 | isNode() { 271 | return "undefined" != typeof module && !!module.exports 272 | } 273 | 274 | isQuanX() { 275 | return "undefined" != typeof $task 276 | } 277 | 278 | isSurge() { 279 | return "undefined" != typeof $httpClient && "undefined" == typeof $loon 280 | } 281 | 282 | isLoon() { 283 | return "undefined" != typeof $loon 284 | } 285 | 286 | toObj(t, e = null) { 287 | try { 288 | return JSON.parse(t) 289 | } catch { 290 | return e 291 | } 292 | } 293 | 294 | toStr(t, e = null) { 295 | try { 296 | return JSON.stringify(t) 297 | } catch { 298 | return e 299 | } 300 | } 301 | 302 | getjson(t, e) { 303 | let s = e; 304 | const i = this.getdata(t); 305 | if (i) try { 306 | s = JSON.parse(this.getdata(t)) 307 | } catch {} 308 | return s 309 | } 310 | 311 | setjson(t, e) { 312 | try { 313 | return this.setdata(JSON.stringify(t), e) 314 | } catch { 315 | return !1 316 | } 317 | } 318 | 319 | getScript(t) { 320 | return new Promise(e => { 321 | this.get({ 322 | url: t 323 | }, (t, s, i) => e(i)) 324 | }) 325 | } 326 | 327 | runScript(t, e) { 328 | return new Promise(s => { 329 | let i = this.getdata("@chavy_boxjs_userCfgs.httpapi"); 330 | i = i ? i.replace(/\n/g, "").trim() : i; 331 | let r = this.getdata("@chavy_boxjs_userCfgs.httpapi_timeout"); 332 | r = r ? 1 * r : 20, r = e && e.timeout ? e.timeout : r; 333 | const [o, h] = i.split("@"), n = { 334 | url: `http://${h}/v1/scripting/evaluate`, 335 | body: { 336 | script_text: t, 337 | mock_type: "cron", 338 | timeout: r 339 | }, 340 | headers: { 341 | "X-Key": o, 342 | Accept: "*/*" 343 | } 344 | }; 345 | this.post(n, (t, e, i) => s(i)) 346 | }).catch(t => this.logErr(t)) 347 | } 348 | 349 | loaddata() { 350 | if (!this.isNode()) return {}; { 351 | this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); 352 | const t = this.path.resolve(this.dataFile), 353 | e = this.path.resolve(process.cwd(), this.dataFile), 354 | s = this.fs.existsSync(t), 355 | i = !s && this.fs.existsSync(e); 356 | if (!s && !i) return {}; { 357 | const i = s ? t : e; 358 | try { 359 | return JSON.parse(this.fs.readFileSync(i)) 360 | } catch (t) { 361 | return {} 362 | } 363 | } 364 | } 365 | } 366 | 367 | writedata() { 368 | if (this.isNode()) { 369 | this.fs = this.fs ? this.fs : require("fs"), this.path = this.path ? this.path : require("path"); 370 | const t = this.path.resolve(this.dataFile), 371 | e = this.path.resolve(process.cwd(), this.dataFile), 372 | s = this.fs.existsSync(t), 373 | i = !s && this.fs.existsSync(e), 374 | r = JSON.stringify(this.data); 375 | s ? this.fs.writeFileSync(t, r) : i ? this.fs.writeFileSync(e, r) : this.fs.writeFileSync(t, r) 376 | } 377 | } 378 | 379 | lodash_get(t, e, s) { 380 | const i = e.replace(/\[(\d+)\]/g, ".$1").split("."); 381 | let r = t; 382 | for (const t of i) 383 | if (r = Object(r)[t], void 0 === r) return s; 384 | return r 385 | } 386 | 387 | lodash_set(t, e, s) { 388 | 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) 389 | } 390 | 391 | getdata(t) { 392 | let e = this.getval(t); 393 | if (/^@/.test(t)) { 394 | const [, s, i] = /^@(.*?)\.(.*?)$/.exec(t), r = s ? this.getval(s) : ""; 395 | if (r) try { 396 | const t = JSON.parse(r); 397 | e = t ? this.lodash_get(t, i, "") : e 398 | } catch (t) { 399 | e = "" 400 | } 401 | } 402 | return e 403 | } 404 | 405 | setdata(t, e) { 406 | let s = !1; 407 | if (/^@/.test(e)) { 408 | const [, i, r] = /^@(.*?)\.(.*?)$/.exec(e), o = this.getval(i), 409 | h = i ? "null" === o ? null : o || "{}" : "{}"; 410 | try { 411 | const e = JSON.parse(h); 412 | this.lodash_set(e, r, t), s = this.setval(JSON.stringify(e), i) 413 | } catch (e) { 414 | const o = {}; 415 | this.lodash_set(o, r, t), s = this.setval(JSON.stringify(o), i) 416 | } 417 | } else s = this.setval(t, e); 418 | return s 419 | } 420 | 421 | getval(t) { 422 | 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 423 | } 424 | 425 | setval(t, e) { 426 | 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 427 | } 428 | 429 | initGotEnv(t) { 430 | 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)) 431 | } 432 | 433 | get(t, e = (() => {})) { 434 | t.headers && (delete t.headers["Content-Type"], delete t.headers["Content-Length"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { 435 | "X-Surge-Skip-Scripting": !1 436 | })), $httpClient.get(t, (t, s, i) => { 437 | !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) 438 | })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { 439 | hints: !1 440 | })), $task.fetch(t).then(t => { 441 | const { 442 | statusCode: s, 443 | statusCode: i, 444 | headers: r, 445 | body: o 446 | } = t; 447 | e(null, { 448 | status: s, 449 | statusCode: i, 450 | headers: r, 451 | body: o 452 | }, o) 453 | }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { 454 | try { 455 | if (t.headers["set-cookie"]) { 456 | const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); 457 | s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar 458 | } 459 | } catch (t) { 460 | this.logErr(t) 461 | } 462 | }).then(t => { 463 | const { 464 | statusCode: s, 465 | statusCode: i, 466 | headers: r, 467 | body: o 468 | } = t; 469 | e(null, { 470 | status: s, 471 | statusCode: i, 472 | headers: r, 473 | body: o 474 | }, o) 475 | }, t => { 476 | const { 477 | message: s, 478 | response: i 479 | } = t; 480 | e(s, i, i && i.body) 481 | })) 482 | } 483 | 484 | post(t, e = (() => {})) { 485 | if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { 486 | "X-Surge-Skip-Scripting": !1 487 | })), $httpClient.post(t, (t, s, i) => { 488 | !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) 489 | }); 490 | else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { 491 | hints: !1 492 | })), $task.fetch(t).then(t => { 493 | const { 494 | statusCode: s, 495 | statusCode: i, 496 | headers: r, 497 | body: o 498 | } = t; 499 | e(null, { 500 | status: s, 501 | statusCode: i, 502 | headers: r, 503 | body: o 504 | }, o) 505 | }, t => e(t)); 506 | else if (this.isNode()) { 507 | this.initGotEnv(t); 508 | const { 509 | url: s, 510 | ...i 511 | } = t; 512 | this.got.post(s, i).then(t => { 513 | const { 514 | statusCode: s, 515 | statusCode: i, 516 | headers: r, 517 | body: o 518 | } = t; 519 | e(null, { 520 | status: s, 521 | statusCode: i, 522 | headers: r, 523 | body: o 524 | }, o) 525 | }, t => { 526 | const { 527 | message: s, 528 | response: i 529 | } = t; 530 | e(s, i, i && i.body) 531 | }) 532 | } 533 | } 534 | 535 | time(t, e = null) { 536 | const s = e ? new Date(e) : new Date; 537 | let i = { 538 | "M+": s.getMonth() + 1, 539 | "d+": s.getDate(), 540 | "H+": s.getHours(), 541 | "m+": s.getMinutes(), 542 | "s+": s.getSeconds(), 543 | "q+": Math.floor((s.getMonth() + 3) / 3), 544 | S: s.getMilliseconds() 545 | }; 546 | /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); 547 | for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); 548 | return t 549 | } 550 | 551 | msg(e = t, s = "", i = "", r) { 552 | const o = t => { 553 | if (!t) return t; 554 | if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { 555 | "open-url": t 556 | } : this.isSurge() ? { 557 | url: t 558 | } : void 0; 559 | if ("object" == typeof t) { 560 | if (this.isLoon()) { 561 | let e = t.openUrl || t.url || t["open-url"], 562 | s = t.mediaUrl || t["media-url"]; 563 | return { 564 | openUrl: e, 565 | mediaUrl: s 566 | } 567 | } 568 | if (this.isQuanX()) { 569 | let e = t["open-url"] || t.url || t.openUrl, 570 | s = t["media-url"] || t.mediaUrl; 571 | return { 572 | "open-url": e, 573 | "media-url": s 574 | } 575 | } 576 | if (this.isSurge()) { 577 | let e = t.url || t.openUrl || t["open-url"]; 578 | return { 579 | url: e 580 | } 581 | } 582 | } 583 | }; 584 | if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { 585 | let t = ["", "==============📣系统通知📣=============="]; 586 | t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) 587 | } 588 | } 589 | 590 | log(...t) { 591 | t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) 592 | } 593 | 594 | logErr(t, e) { 595 | const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); 596 | s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) 597 | } 598 | 599 | wait(t) { 600 | return new Promise(e => setTimeout(e, t)) 601 | } 602 | 603 | done(t = {}) { 604 | const e = (new Date).getTime(), 605 | s = (e - this.startTime) / 1e3; 606 | this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) 607 | } 608 | }(t, e) 609 | } 610 | -------------------------------------------------------------------------------- /南湖声音.js: -------------------------------------------------------------------------------- 1 | /* 2 | APP:南湖声音 3 | 功能:完成任务,获得积分 4 | 抓包:https://vapp.tmuyun.com/ 任意-请求头中 x-session-id 或使用 手机号#密码 两者互不影响 5 | 变量:nhsyCookie='xxxx@12345678910#abcdefg ' 多个账号用 @ 或者 换行 分割 6 | 定时一天三次 7 | cron: 25 8,10,19 * * * 8 | */ 9 | const $ = new Env('南湖声音') 10 | const notify = $.isNode() ? require('./sendNotify') : ''; 11 | const CryptoJS = require("crypto-js"); 12 | const salt = "FR*r!isE5W"; 13 | const appid = 57; 14 | let cookiesArr = [], 15 | message = "", 16 | channelId = ["6329970cad61a4052a4a389e", "63299704fe3fc1537e564c7b", "632996fcb40eef1840196532", "63299326ad61a4052a4a387b","632996f0ad61a4052a4a3899","632996d2b40eef184019652f"] 17 | cookie = ($.isNode() ? process.env.nhsyCookie : $.getdata("nhsyCookie")) || `` 18 | helpAu = ($.isNode() ? process.env.jrychelpAu : $.getdata("jrychelpAu")) || true 19 | !(async () => { 20 | await requireConfig(); 21 | for (let i = 0; i < cookiesArr.length; i++) { 22 | if (cookiesArr[i]) { 23 | sessionid = '' 24 | msg = ''; 25 | $.index = i + 1; 26 | $.nickName = ''; 27 | $.userId = ''; 28 | $.mobile = ''; 29 | $.userIdStr = ''; 30 | $.vehicleToken = ''; 31 | $.taskList = {} 32 | $.queryList = {} 33 | await getCookie(cookiesArr[i]) 34 | await account_detail(); 35 | console.log(`\n******开始【🐳南湖声音账号${$.index}】${$.nickName}|${$.mobile}*********\n`); 36 | await main() 37 | } 38 | } 39 | if ($.isNode() && message) { 40 | await notify.sendNotify(`${$.name}`, `${message}`) 41 | } 42 | })() 43 | .catch((e) => $.logErr(e)) 44 | .finally(() => $.done()) 45 | 46 | async function main() { 47 | if ($.userId) { 48 | console.log(`【获取任务列表】`) 49 | await numberCenter() 50 | console.log(`【开始完成任务】`) 51 | await article() 52 | for (i = 0; i < $.taskList.length; i++) { 53 | if ($.taskList[i].completed === 1) { 54 | console.log(`[${$.taskList[i].name}]已完成`) 55 | continue 56 | } else { 57 | console.log(`去完成任务:${$.taskList[i].name}`) 58 | await doTask($.taskList[i]) 59 | } 60 | } 61 | if (helpAu == true) { 62 | console.log(`【环境变量:jrychelpAu 默认为True 前往助力作者】`) 63 | await invite() 64 | } 65 | console.log(`【查询账号信息】`) 66 | await account_detail() 67 | console.log(`拥有:[${$.integral}]积分 | 等级:[${$.grade}]-${$.grade_name}`) 68 | msg += `拥有:[${$.integral}]积分 \n等级:[${$.grade}]-${$.grade_name}\n\n` 69 | await showMsg() 70 | } else console.log(`获取userId失败,退出任务`) 71 | } 72 | async function doTask(task) { 73 | let type = JSON.stringify(task.id); 74 | let num = Number(task.frequency) - Number(task.finish_times) 75 | //console.log(`去完成:${task.name},id:${type}`) 76 | switch (type) { 77 | case '1358': //签到 78 | await signin() 79 | break; 80 | case '1348': //分享资讯给好友 81 | for (j = 0; j < num && j < $.acticleList.length; j++) { 82 | console.log(`去分享:${$.acticleList[j].list_title}`) 83 | await share($.acticleList[j].id) 84 | await $.wait(1500) 85 | } 86 | break; 87 | case '1351': //新闻资讯评论 88 | for (j = 0; j < num && j < $.acticleList.length; j++) { 89 | console.log(`去评论:${$.acticleList[j].list_title}`) 90 | await comment($.acticleList[j].id) 91 | await $.wait(1500) 92 | } 93 | break; 94 | case '1350': //新闻资讯点赞 95 | for (j = 0; j < num && j < $.acticleList.length; j++) { 96 | console.log(`去点赞:${$.acticleList[j].list_title}`) 97 | await like($.acticleList[j].id) 98 | await $.wait(1500) 99 | } 100 | break; 101 | case '1359': //邀请 102 | console.log(`邀请功能暂未上线`) 103 | break; 104 | default: 105 | console.log(`${task.name}暂未上线,请反馈作者`); 106 | } 107 | } 108 | /** 109 | * 110 | * 获取登录Code 111 | */ 112 | async function credential_auth() { 113 | let url = { 114 | url: `https://passport.tmuyun.com/web/oauth/credential_auth`, 115 | body: `client_id=10013&password=${encodeURIComponent($.pwd)}&phone_number=${$.mobile}`, 116 | headers: { 117 | 'Host': 'passport.tmuyun.com', 118 | 'Content-Type': 'application/x-www-form-urlencoded', 119 | 'Accept-Encoding': 'gzip, deflate, br' 120 | } 121 | } 122 | return new Promise(resolve => { 123 | $.post(url, async (err, resp, data) => { 124 | try { 125 | if (err) { 126 | console.log(`${err}`) 127 | console.log(`${$.name} API请求失败,请检查网路重试`) 128 | } else { 129 | if (data) { 130 | data = JSON.parse(data); 131 | //console.log(JSON.stringify(data)); 132 | if (data.code === 0) { 133 | await login(data.data.authorization_code.code) 134 | } else { 135 | console.log(data.message) 136 | } 137 | } else { 138 | console.log("没有返回数据") 139 | } 140 | } 141 | } catch (e) { 142 | $.logErr(e, resp) 143 | } finally { 144 | resolve(data); 145 | } 146 | }) 147 | }) 148 | } 149 | /** 150 | * 151 | * 登录 152 | */ 153 | async function login(code) { 154 | let body = 'code=' + code 155 | sessionid = '63777162fe3fc118b09fab89' 156 | return new Promise(resolve => { 157 | $.post(taskPostUrl('/api/zbtxz/login', body), async (err, resp, data) => { 158 | try { 159 | if (err) { 160 | console.log(`${err}`) 161 | console.log(`${$.name} API请求失败,请检查网路重试`) 162 | } else { 163 | if (data) { 164 | data = JSON.parse(data); 165 | //console.log(JSON.stringify(data)); 166 | if (data.code === 0) { 167 | sessionid = data.data.session.id 168 | } else { 169 | //console.log(JSON.stringify(data)) 170 | } 171 | } else { 172 | console.log("没有返回数据") 173 | } 174 | } 175 | } catch (e) { 176 | $.logErr(e, resp) 177 | } finally { 178 | resolve(data); 179 | } 180 | }) 181 | }) 182 | } 183 | /** 184 | * 185 | * 获取账号信息 186 | */ 187 | async function account_detail() { 188 | let body = '' 189 | return new Promise(resolve => { 190 | $.get((taskUrl("/api/user_mumber/account_detail", body)), async (err, resp, data) => { 191 | try { 192 | if (err) { 193 | console.log(`${err}`) 194 | console.log(`${$.name} API请求失败,请检查网路重试`) 195 | } else { 196 | if (data) { 197 | data = JSON.parse(data); 198 | //console.log(JSON.stringify(data)); 199 | if (data.code === 0) { 200 | $.userId = data.data.rst.id 201 | $.nickName = data.data.rst.nick_name 202 | $.mobile = data.data.rst.mobile 203 | $.grade = data.data.rst.grade 204 | $.grade_name = data.data.rst.grade_name 205 | $.integral = data.data.rst.total_integral 206 | } else { 207 | //console.log(JSON.stringify(data)) 208 | } 209 | } else { 210 | console.log("没有返回数据") 211 | } 212 | } 213 | } catch (e) { 214 | $.logErr(e, resp) 215 | } finally { 216 | resolve(data); 217 | } 218 | }) 219 | }) 220 | } 221 | /** 222 | * 223 | * 获取任务列表 224 | */ 225 | async function numberCenter() { 226 | let body = '' 227 | return new Promise(resolve => { 228 | $.get((taskUrl("/api/user_mumber/numberCenter", body)), async (err, resp, data) => { 229 | try { 230 | if (err) { 231 | console.log(`${err}`) 232 | console.log(`${$.name} API请求失败,请检查网路重试`) 233 | } else { 234 | if (data) { 235 | data = JSON.parse(data); 236 | //console.log(JSON.stringify(data)); 237 | if (data.code === 0) { 238 | console.log(`获取成功!`) 239 | $.taskList = data.data.rst['user_task_list'] 240 | //console.log(JSON.stringify($.taskList)) 241 | } else { 242 | console.log(JSON.stringify(data)) 243 | } 244 | } else { 245 | console.log("没有返回数据") 246 | } 247 | } 248 | } catch (e) { 249 | $.logErr(e, resp) 250 | } finally { 251 | resolve(data); 252 | } 253 | }) 254 | }) 255 | } 256 | /** 257 | * 258 | * 签到 259 | */ 260 | async function signin() { 261 | let body = '' 262 | return new Promise(resolve => { 263 | $.get((taskUrl("/api/user_mumber/sign", body)), async (err, resp, data) => { 264 | try { 265 | if (err) { 266 | console.log(`${err}`) 267 | console.log(`${$.name} API请求失败,请检查网路重试`) 268 | } else { 269 | if (data) { 270 | data = JSON.parse(data); 271 | //console.log(JSON.stringify(data)); 272 | if (data.code === 0) { 273 | console.log(`签到成功!获得:${data.data.signIntegral}积分`) 274 | } else { 275 | console.log(data.message) 276 | } 277 | } else { 278 | console.log("没有返回数据") 279 | } 280 | } 281 | } catch (e) { 282 | $.logErr(e, resp) 283 | } finally { 284 | resolve(data); 285 | } 286 | }) 287 | }) 288 | } 289 | /** 290 | * 291 | * 获取文章 292 | */ 293 | async function article() { 294 | let body = `?channel_id=${channelId[Math.floor(Math.random()*channelId.length)]}&isDiFangHao=false&is_new=1&list_count=${Math.floor(Math.random()*5+1)*10}&size=10&start=${Date.now()}` 295 | return new Promise(resolve => { 296 | $.get((taskUrl("/api/article/channel_list", body)), async (err, resp, data) => { 297 | try { 298 | if (err) { 299 | console.log(`${err}`) 300 | console.log(`${$.name} API请求失败,请检查网路重试`) 301 | } else { 302 | if (data) { 303 | data = JSON.parse(data); 304 | //console.log(JSON.stringify(data)); 305 | if (data.code === 0) { 306 | $.acticleList = data.data['article_list'] 307 | } else { 308 | console.log(data.message) 309 | } 310 | } else { 311 | console.log("没有返回数据") 312 | } 313 | } 314 | } catch (e) { 315 | $.logErr(e, resp) 316 | } finally { 317 | resolve(data); 318 | } 319 | }) 320 | }) 321 | } 322 | /** 323 | * 324 | * 浏览新闻资讯 325 | */ 326 | async function read(id) { 327 | let body = `?id=${id}` 328 | return new Promise(resolve => { 329 | $.get((taskUrl("/api/article/detail", body)), async (err, resp, data) => { 330 | try { 331 | if (err) { 332 | console.log(`${err}`) 333 | console.log(`${$.name} API请求失败,请检查网路重试`) 334 | } else { 335 | if (data) { 336 | data = JSON.parse(data); 337 | //console.log(JSON.stringify(data)); 338 | if (data.code === 0) { 339 | console.log(`浏览成功!`) 340 | if (data.data['score_notify']) console.log(`浏览任务完成,获得[${data.data.score_notify.integral}]积分`) 341 | } else { 342 | console.log(data.message) 343 | } 344 | } else { 345 | console.log("没有返回数据") 346 | } 347 | } 348 | } catch (e) { 349 | $.logErr(e, resp) 350 | } finally { 351 | resolve(data); 352 | } 353 | }) 354 | }) 355 | } 356 | /** 357 | * 358 | * 分享资讯给好友 359 | */ 360 | async function share() { 361 | let body = `member_type=3&memberType=3` 362 | return new Promise(resolve => { 363 | $.post((taskPostUrl("/api/user_mumber/doTask", body)), async (err, resp, data) => { 364 | try { 365 | if (err) { 366 | console.log(`${err}`) 367 | console.log(`${$.name} API请求失败,请检查网路重试`) 368 | } else { 369 | if (data) { 370 | data = JSON.parse(data); 371 | //console.log(JSON.stringify(data)); 372 | if (data.code === 0) { 373 | console.log(`分享成功!`) 374 | if (data.data) console.log(`分享任务完成,获得[${data.data.score_notify.integral}]积分`) 375 | } else { 376 | console.log(data.message) 377 | } 378 | } else { 379 | console.log("没有返回数据") 380 | } 381 | } 382 | } catch (e) { 383 | $.logErr(e, resp) 384 | } finally { 385 | resolve(data); 386 | } 387 | }) 388 | }) 389 | } 390 | /** 391 | * 392 | * 新闻资讯评论 393 | */ 394 | async function comment(id) { 395 | let body = `channel_article_id=${id}&content=1` 396 | return new Promise(resolve => { 397 | $.post((taskPostUrl("/api/comment/create", body)), async (err, resp, data) => { 398 | try { 399 | if (err) { 400 | console.log(`${err}`) 401 | console.log(`${$.name} API请求失败,请检查网路重试`) 402 | } else { 403 | if (data) { 404 | data = JSON.parse(data); 405 | //console.log(JSON.stringify(data)); 406 | if (data.code === 0) { 407 | console.log(`评论成功!`) 408 | if (data.data) console.log(`评论任务完成,获得[${data.data.score_notify.integral}]积分`) 409 | } else { 410 | console.log(data.message) 411 | } 412 | } else { 413 | console.log("没有返回数据") 414 | } 415 | } 416 | } catch (e) { 417 | $.logErr(e, resp) 418 | } finally { 419 | resolve(data); 420 | } 421 | }) 422 | }) 423 | } 424 | /** 425 | * 426 | * 新闻资讯点赞 427 | */ 428 | async function like(id) { 429 | let body = `id=${id}&action=true` 430 | return new Promise(resolve => { 431 | $.post((taskPostUrl("/api/favorite/like", body)), async (err, resp, data) => { 432 | try { 433 | if (err) { 434 | console.log(`${err}`) 435 | console.log(`${$.name} API请求失败,请检查网路重试`) 436 | } else { 437 | if (data) { 438 | data = JSON.parse(data); 439 | //console.log(JSON.stringify(data)); 440 | if (data.code === 0) { 441 | console.log(`点赞成功!`) 442 | if (data.data) console.log(`点赞任务完成,获得[${data.data.score_notify.integral}]积分`) 443 | } else { 444 | console.log(data.message) 445 | } 446 | } else { 447 | console.log("没有返回数据") 448 | } 449 | } 450 | } catch (e) { 451 | $.logErr(e, resp) 452 | } finally { 453 | resolve(data); 454 | } 455 | }) 456 | }) 457 | } 458 | /** 459 | * 460 | * 使用本地服务 461 | */ 462 | async function local() { 463 | let body = `member_type=6&memberType=6` 464 | return new Promise(resolve => { 465 | $.post((taskPostUrl("/api/user_mumber/doTask", body)), async (err, resp, data) => { 466 | try { 467 | if (err) { 468 | console.log(`${err}`) 469 | console.log(`${$.name} API请求失败,请检查网路重试`) 470 | } else { 471 | if (data) { 472 | data = JSON.parse(data); 473 | //console.log(JSON.stringify(data)); 474 | if (data.code === 0) { 475 | console.log(`使用成功!`) 476 | if (data.data) console.log(`使用成功,获得[${data.data.score_notify.integral}]积分`) 477 | } else { 478 | console.log(data.message) 479 | } 480 | } else { 481 | console.log("没有返回数据") 482 | } 483 | } 484 | } catch (e) { 485 | $.logErr(e, resp) 486 | } finally { 487 | resolve(data); 488 | } 489 | }) 490 | }) 491 | } 492 | /** 493 | * 494 | * 助力 495 | */ 496 | async function invite() { 497 | let body = `ref_code=V73XF9` 498 | return new Promise(resolve => { 499 | $.post((taskPostUrl("/api/account/update_ref_code", body)), async (err, resp, data) => { 500 | try { 501 | if (err) { 502 | console.log(`${err}`) 503 | console.log(`${$.name} API请求失败,请检查网路重试`) 504 | } else { 505 | if (data) { 506 | data = JSON.parse(data); 507 | //console.log(JSON.stringify(data)); 508 | if (data.code === 0) { 509 | console.log(`助力成功!`) 510 | } else { 511 | console.log(data.message) 512 | } 513 | } else { 514 | console.log("没有返回数据") 515 | } 516 | } 517 | } catch (e) { 518 | $.logErr(e, resp) 519 | } finally { 520 | resolve(data); 521 | } 522 | }) 523 | }) 524 | } 525 | /** 526 | * 527 | * API 528 | */ 529 | function taskUrl(type, body) { 530 | getSign(type) 531 | return { 532 | url: `https://vapp.tmuyun.com${type}${body}`, 533 | headers: { 534 | "X-SESSION-ID": sessionid, 535 | "X-REQUEST-ID": requestid, 536 | "X-TIMESTAMP": timestamp, 537 | "X-SIGNATURE": sign, 538 | "Cache-Control": `no-cache`, 539 | "X-TENANT-ID": 57, 540 | 'Host': 'vapp.tmuyun.com', 541 | 'Connection': 'Keep-Alive', 542 | "Content-Type": `application/x-www-form-urlencoded`, 543 | 'User-Agent': `1.2.2;${requestid};iPad13,4;IOS;16.2;Appstore` 544 | }, 545 | } 546 | } 547 | 548 | function taskPostUrl(type, body) { 549 | getSign(type) 550 | return { 551 | url: `https://vapp.tmuyun.com${type}`, 552 | body: `${body}`, 553 | headers: { 554 | "X-SESSION-ID": sessionid, 555 | "X-REQUEST-ID": requestid, 556 | "X-TIMESTAMP": timestamp, 557 | "X-SIGNATURE": sign, 558 | "Cache-Control": `no-cache`, 559 | "X-TENANT-ID": 57, 560 | 'Host': 'vapp.tmuyun.com', 561 | 'Connection': 'Keep-Alive', 562 | "Content-Type": `application/x-www-form-urlencoded`, 563 | 'User-Agent': `1.2.2;${requestid};iPad13,4;IOS;16.2;Appstore` 564 | }, 565 | } 566 | } 567 | /** 568 | * 获取X-SIGNATURE 569 | */ 570 | function getSign(type) { 571 | timestamp = Date.now() 572 | requestid = uuid() 573 | sign = CryptoJS.SHA256(`${type}&&${sessionid}&&${requestid}&&${timestamp}&&${salt}&&${appid}`).toString() 574 | //console.log(sign) 575 | } 576 | 577 | function uuid() { 578 | function S4() { 579 | return (((1 + Math.random()) * 0x10000) | 0).toString(16).substring(1); 580 | } 581 | return (S4() + S4() + "-" + S4() + "-" + S4() + "-" + S4() + "-" + S4() + S4() + S4()); 582 | } 583 | /** 584 | * 585 | * RSA加密 586 | */ 587 | async function RSA_Encrypt(data) { 588 | let url = { 589 | url: `https://www.bejson.com/Bejson/Api/Rsa/pubEncrypt`, 590 | headers: { 591 | "Accept": "application/json, text/javascript, */*; q=0.01", 592 | "Accept-Encoding": " gzip, deflate, br", 593 | "Content-Type": "application/x-www-form-urlencoded; charset=UTF-8", 594 | "Host": "www.bejson.com", 595 | "User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36", 596 | }, 597 | body: `publicKey=-----BEGIN+PUBLIC+KEY-----%0D%0AMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQD6XO7e9YeAOs%2BcFqwa7ETJ%2BWXizPqQeXv68i5vqw9pFREsrqiBTRcg7wB0RIp3rJkDpaeVJLsZqYm5TW7FWx%2FiOiXFc%2BzCPvaKZric2dXCw27EvlH5rq%2BzwIPDAJHGAfnn1nmQH7wR3PCatEIb8pz5GFlTHMlluw4ZYmnOwg%2BthwIDAQAB%0D%0A-----END+PUBLIC+KEY-----&encStr=${data}&etype=rsa2` 598 | } 599 | return new Promise(resolve => { 600 | $.post(url, async (err, resp, data) => { 601 | try { 602 | if (err) { 603 | console.log(`${err}`) 604 | console.log(`${$.name} API请求失败,请检查网路重试`) 605 | } else { 606 | if (data) { 607 | data = JSON.parse(data); 608 | //console.log(JSON.stringify(data)); 609 | if (data.code === 200) { 610 | 611 | } else { 612 | console.log(data.msg) 613 | } 614 | } else { 615 | console.log("没有返回数据") 616 | } 617 | } 618 | } catch (e) { 619 | $.logErr(e, resp) 620 | } finally { 621 | resolve(data.data); 622 | } 623 | }) 624 | }) 625 | } 626 | /** 627 | * 628 | * 消息推送 629 | */ 630 | function showMsg() { 631 | message += `=== ${$.nickName} | ${$.mobile} ===\n`; 632 | message += msg 633 | //console.log(message) 634 | } 635 | /** 636 | * 637 | * cookie处理 638 | */ 639 | function requireConfig() { 640 | if (cookie) { 641 | if (cookie.indexOf("@") != -1) { 642 | cookie.split("@").forEach((item) => { 643 | cookiesArr.push(item); 644 | }); 645 | } else if (cookie.indexOf("\n") != -1) { 646 | cookie.split("\n").forEach((item) => { 647 | cookiesArr.push(item); 648 | }); 649 | } else { 650 | cookiesArr.push(cookie); 651 | } 652 | console.log(`\n============================================= \n脚本执行 - 北京时间(UTC+8):${new Date(new Date().getTime() +new Date().getTimezoneOffset() * 60 * 1000 + 8 * 60 * 60 * 1000).toLocaleString()} \n=============================================\n`) 653 | console.log(`\n=========共有${cookiesArr.length}个${$.name}账号Cookie=========\n`); 654 | } else { 655 | console.log(`\n【缺少nhsyCookies环境变量或者Cookies为空!】`) 656 | return; 657 | } 658 | } 659 | /** 660 | * cookie转换 661 | */ 662 | async function getCookie(rawCookie) { 663 | if (rawCookie.includes('#')) { 664 | $.pwd = await RSA_Encrypt(rawCookie.split('#')[1]) 665 | $.mobile = rawCookie.split('#')[0] 666 | await credential_auth() 667 | } else { 668 | sessionid = rawCookie; 669 | } 670 | } 671 | // prettier-ignore 672 | function Env(t,e){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"]),this.isSurge()||this.isLoon()?(this.isSurge()&&this.isNeedRewrite&&(t.headers=t.headers||{},Object.assign(t.headers,{"X-Surge-Skip-Scripting":!1})),$httpClient.get(t,(t,s,i)=>{!t&&s&&(s.body=i,s.statusCode=s.status),e(t,s,i)})):this.isQuanX()?(this.isNeedRewrite&&(t.opts=t.opts||{},Object.assign(t.opts,{hints:!1})),$task.fetch(t).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>e(t))):this.isNode()&&(this.initGotEnv(t),this.got(t).on("redirect",(t,e)=>{try{if(t.headers["set-cookie"]){const s=t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString();s&&this.ckjar.setCookieSync(s,null),e.cookieJar=this.ckjar}}catch(t){this.logErr(t)}}).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>{const{message:s,response:i}=t;e(s,i,i&&i.body)}))}post(t,e=(()=>{})){if(t.body&&t.headers&&!t.headers["Content-Type"]&&(t.headers["Content-Type"]="application/x-www-form-urlencoded"),t.headers&&delete t.headers["Content-Length"],this.isSurge()||this.isLoon())this.isSurge()&&this.isNeedRewrite&&(t.headers=t.headers||{},Object.assign(t.headers,{"X-Surge-Skip-Scripting":!1})),$httpClient.post(t,(t,s,i)=>{!t&&s&&(s.body=i,s.statusCode=s.status),e(t,s,i)});else if(this.isQuanX())t.method="POST",this.isNeedRewrite&&(t.opts=t.opts||{},Object.assign(t.opts,{hints:!1})),$task.fetch(t).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>e(t));else if(this.isNode()){this.initGotEnv(t);const{url:s,...i}=t;this.got.post(s,i).then(t=>{const{statusCode:s,statusCode:i,headers:r,body:o}=t;e(null,{status:s,statusCode:i,headers:r,body:o},o)},t=>{const{message:s,response:i}=t;e(s,i,i&&i.body)})}}time(t,e=null){const s=e?new Date(e):new Date;let i={"M+":s.getMonth()+1,"d+":s.getDate(),"H+":s.getHours(),"m+":s.getMinutes(),"s+":s.getSeconds(),"q+":Math.floor((s.getMonth()+3)/3),S:s.getMilliseconds()};/(y+)/.test(t)&&(t=t.replace(RegExp.$1,(s.getFullYear()+"").substr(4-RegExp.$1.length)));for(let e in i)new RegExp("("+e+")").test(t)&&(t=t.replace(RegExp.$1,1==RegExp.$1.length?i[e]:("00"+i[e]).substr((""+i[e]).length)));return t}msg(e=t,s="",i="",r){const o=t=>{if(!t)return t;if("string"==typeof t)return this.isLoon()?t:this.isQuanX()?{"open-url":t}:this.isSurge()?{url:t}:void 0;if("object"==typeof t){if(this.isLoon()){let e=t.openUrl||t.url||t["open-url"],s=t.mediaUrl||t["media-url"];return{openUrl:e,mediaUrl:s}}if(this.isQuanX()){let e=t["open-url"]||t.url||t.openUrl,s=t["media-url"]||t.mediaUrl;return{"open-url":e,"media-url":s}}if(this.isSurge()){let e=t.url||t.openUrl||t["open-url"];return{url:e}}}};if(this.isMute||(this.isSurge()||this.isLoon()?$notification.post(e,s,i,o(r)):this.isQuanX()&&$notify(e,s,i,o(r))),!this.isMuteLog){let t=["","==============📣系统通知📣=============="];t.push(e),s&&t.push(s),i&&t.push(i),console.log(t.join("\n")),this.logs=this.logs.concat(t)}}log(...t){t.length>0&&(this.logs=[...this.logs,...t]),console.log(t.join(this.logSeparator))}logErr(t,e){const s=!this.isSurge()&&!this.isQuanX()&&!this.isLoon();s?this.log("",`❗️${this.name}, 错误!`,t.stack):this.log("",`❗️${this.name}, 错误!`,t)}wait(t){return new Promise(e=>setTimeout(e,t))}done(t={}){const e=(new Date).getTime(),s=(e-this.startTime)/1e3;this.log("",`🔔${this.name}, 结束! 🕛 ${s} 秒`),this.log(),(this.isSurge()||this.isQuanX()||this.isLoon())&&$done(t)}}(t,e)} 673 | -------------------------------------------------------------------------------- /柠檬绿地g.js: -------------------------------------------------------------------------------- 1 | /** 2 | *下载地址 https://gu.gkewang.com/front/inviter/register/00bsE6e6?activityCode=INVITECLIE 3 | * 绿地g优app签到 4 | * 邀请码:00bsE6e6 5 | * 定时一次 (第一次手动进一下签到页面) 6 | * ========= 青龙--配置文件 ========= 7 | * 变量格式: export ldgy_hd=手机号&token ,多账号用 换行 或 @ 分割 8 | * 抓app.gkewang.com下body 的token 9 | * 如果是这种格式 %22token%22:%22XXXXXXXXXXXXXXXXXX%22 (只需要XXXXXXXXXXXXXX这部分) 10 | * token有效期未知 11 | */ 12 | 13 | const { log } = require("console"); 14 | const $ = new Env("绿地g优"); 15 | const notify = $.isNode() ? require("./sendNotify") : ""; 16 | const Notify = 1 //0为关闭通知,1为打开通知,默认为1 17 | const debug = 0 //0为关闭调试,1为打开调试,默认为0 18 | //--------------------------------------------------------------------------------------------------------- 19 | let ckStr = ($.isNode() ? process.env.ldgy_hd : $.getdata('ldgy_hd')) || ''; 20 | let msg, ck; 21 | let ck_status = true; 22 | //--------------------------------------------------------------------------------------------------------- 23 | let Change = '无' 24 | //--------------------------------------------------------------------------------------------------------- 25 | 26 | async function tips(ckArr) { 27 | let Version = `\n📌 测试 ` 28 | DoubleLog(`${Version}\n📌 🆙 更新内容: ${Change}`); 29 | DoubleLog(`\n========== 共找到 ${ckArr.length} 个账号 ==========`); 30 | debugLog(`【debug】 这是你的账号数组:\n ${ckArr}`); 31 | } 32 | 33 | !(async () => { 34 | let ckArr = await checkEnv(ckStr, "ldgy_hd"); 35 | await tips(ckArr); 36 | for (let index = 0; index < ckArr.length; index++) { 37 | let num = index + 1; 38 | DoubleLog(`\n-------- 开始【第 ${num} 个账号】--------`); 39 | ck = ckArr[index].split("&"); 40 | debugLog(`【debug】 这是你第 ${num} 账号信息:\n ${ck}`); 41 | await start(); 42 | } 43 | await SendMsg(msg); 44 | 45 | })() 46 | .catch((e) => $.logErr(e)) 47 | .finally(() => $.done()); 48 | 49 | async function start() { 50 | 51 | console.log("\n开始 签到"); 52 | await $.wait(1 * 1000); 53 | await signin(); 54 | await $.wait(2 * 1000); 55 | } 56 | /** 57 | * 签到 httpPost 58 | */ 59 | async function signin() { 60 | let ncstr=randString().toLowerCase(); 61 | let sg=MD5Encrypt('vHSF2oKE8N48aXshyv1sbGdxA1CWKU0HyvYrjMRvHocEfBUKXDDABZx21EvOeTHMItw5FNoM7amaIWe7zQ03tdM6R7F3eyy{"head":{"service":"101212 ","token":"'+ck[1]+'","userCode":"'+ck[0]+'","nonceStr":"'+ncstr+'"},"body":{}}') 62 | let bd=encodeURI('plainText={"head":{"service":"101212+","token":"'+ck[1]+'","userCode":"'+ck[0]+'","nonceStr":"'+ncstr+'"},"body":{}}&cipherText='+sg); 63 | try { 64 | let url = { 65 | url: 'https://app.gkewang.com/jkt/api/app/v2', 66 | headers: { 67 | 'Host':'app.gkewang.com', 68 | 'channel':'CH_BD', 69 | 'bddeviceid':'', 70 | 'version':'2.4.6', 71 | 'User-Agent':'okhttp/3.12.1', 72 | 'Content-Length': '304', 73 | 'Content-Type': 'application/x-www-form-urlencoded;charset=utf-8', 74 | }, 75 | body: bd 76 | }; 77 | let rc = await httpPost(url, `签到`); 78 | 79 | if (rc.msg=='处理成功') { 80 | DoubleLog(rc.result.msg); 81 | await wait(3); 82 | } 83 | if(rc.code==900001) 84 | { 85 | DoubleLog(rc.msg); 86 | } 87 | else console.log(rc); 88 | } catch (error) { 89 | console.log(error); 90 | } 91 | 92 | } 93 | // #region ******************************************************** 固定代码 ******************************************************** 94 | /** 95 | * 变量检查 96 | */ 97 | async function checkEnv(ck, Variables) { 98 | return new Promise((resolve) => { 99 | let ckArr = [] 100 | if (ck) { 101 | if (ck.indexOf("@") !== -1) { 102 | 103 | ck.split("@").forEach((item) => { 104 | ckArr.push(item); 105 | }); 106 | } else if (ck.indexOf("\n") !== -1) { 107 | 108 | ck.split("\n").forEach((item) => { 109 | ckArr.push(item); 110 | }); 111 | } else { 112 | ckArr.push(ck); 113 | } 114 | resolve(ckArr) 115 | } else { 116 | console.log(` ${$.neme}:未填写变量 ${Variables} ,请仔细阅读脚本说明!`) 117 | } 118 | } 119 | ) 120 | } 121 | 122 | function randString(e) 123 | { 124 | e = e || 32; 125 | for (var n = "ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678", t = n.length, a = "", i = 0; i < e; i++) 126 | a += n.charAt(Math.floor(Math.random() * t)); 127 | return a; 128 | } 129 | 130 | 131 | /** 132 | * 发送消息 133 | */ 134 | async function SendMsg(message) { 135 | if (!message) return; 136 | if (Notify > 0) { 137 | if ($.isNode()) { 138 | var notify = require("./sendNotify"); 139 | await notify.sendNotify($.name, message); 140 | } else { 141 | // $.msg(message); 142 | $.msg($.name, '', message) 143 | } 144 | } else { 145 | console.log(message); 146 | } 147 | } 148 | 149 | /** 150 | * 双平台log输出 151 | */ 152 | function DoubleLog(data) { 153 | if ($.isNode()) { 154 | if (data) { 155 | console.log(` ${data}`); 156 | msg += `\n ${data}`; 157 | } 158 | } else { 159 | console.log(` ${data}`); 160 | msg += `\n ${data}`; 161 | } 162 | 163 | } 164 | 165 | /** 166 | * 等待 X 秒 167 | */ 168 | function wait(n) { 169 | return new Promise(function (resolve) { 170 | setTimeout(resolve, n * 1000); 171 | }); 172 | } 173 | /** 174 | * post请求 175 | */ 176 | async function httpPost(postUrlObject, tip, timeout = 3) { 177 | return new Promise((resolve) => { 178 | let url = postUrlObject; 179 | if (!tip) { 180 | let tmp = arguments.callee.toString(); 181 | let re = /function\s*(\w*)/i; 182 | let matches = re.exec(tmp); 183 | tip = matches[1]; 184 | } 185 | if (debug) { 186 | console.log(`\n 【debug】=============== 这是 ${tip} 请求 url ===============`); 187 | console.log(url); 188 | } 189 | 190 | $.post( 191 | url, 192 | async (err, resp, data) => { 193 | try { 194 | if (debug) { 195 | console.log(`\n\n 【debug】===============这是 ${tip} 返回data==============`); 196 | console.log(data); 197 | console.log(`\n 【debug】=============这是 ${tip} json解析后数据============`); 198 | console.log(JSON.parse(data)); 199 | } 200 | let result = JSON.parse(data); 201 | if (result == undefined) { 202 | return; 203 | } else { 204 | resolve(result); 205 | } 206 | 207 | } catch (e) { 208 | console.log(err, resp); 209 | console.log(`\n ${tip} 失败了!请稍后尝试!!`); 210 | msg = `\n ${tip} 失败了!请稍后尝试!!` 211 | } finally { 212 | resolve(); 213 | } 214 | }, 215 | timeout 216 | ); 217 | }); 218 | } 219 | 220 | /** 221 | * debug调试 222 | */ 223 | function debugLog(...args) { 224 | if (debug) { 225 | console.log(...args); 226 | } 227 | } 228 | 229 | // md5 230 | function MD5Encrypt(a) { function b(a, b) { return a << b | a >>> 32 - b } function c(a, b) { var c, d, e, f, g; return e = 2147483648 & a, f = 2147483648 & b, c = 1073741824 & a, d = 1073741824 & b, g = (1073741823 & a) + (1073741823 & b), c & d ? 2147483648 ^ g ^ e ^ f : c | d ? 1073741824 & g ? 3221225472 ^ g ^ e ^ f : 1073741824 ^ g ^ e ^ f : g ^ e ^ f } function d(a, b, c) { return a & b | ~a & c } function e(a, b, c) { return a & c | b & ~c } function f(a, b, c) { return a ^ b ^ c } function g(a, b, c) { return b ^ (a | ~c) } function h(a, e, f, g, h, i, j) { return a = c(a, c(c(d(e, f, g), h), j)), c(b(a, i), e) } function i(a, d, f, g, h, i, j) { return a = c(a, c(c(e(d, f, g), h), j)), c(b(a, i), d) } function j(a, d, e, g, h, i, j) { return a = c(a, c(c(f(d, e, g), h), j)), c(b(a, i), d) } function k(a, d, e, f, h, i, j) { return a = c(a, c(c(g(d, e, f), h), j)), c(b(a, i), d) } function l(a) { for (var b, c = a.length, d = c + 8, e = (d - d % 64) / 64, f = 16 * (e + 1), g = new Array(f - 1), h = 0, i = 0; c > i;)b = (i - i % 4) / 4, h = i % 4 * 8, g[b] = g[b] | a.charCodeAt(i) << h, i++; return b = (i - i % 4) / 4, h = i % 4 * 8, g[b] = g[b] | 128 << h, g[f - 2] = c << 3, g[f - 1] = c >>> 29, g } function m(a) { var b, c, d = "", e = ""; for (c = 0; 3 >= c; c++)b = a >>> 8 * c & 255, e = "0" + b.toString(16), d += e.substr(e.length - 2, 2); return d } function n(a) { a = a.replace(/\r\n/g, "\n"); for (var b = "", c = 0; c < a.length; c++) { var d = a.charCodeAt(c); 128 > d ? b += String.fromCharCode(d) : d > 127 && 2048 > d ? (b += String.fromCharCode(d >> 6 | 192), b += String.fromCharCode(63 & d | 128)) : (b += String.fromCharCode(d >> 12 | 224), b += String.fromCharCode(d >> 6 & 63 | 128), b += String.fromCharCode(63 & d | 128)) } return b } var o, p, q, r, s, t, u, v, w, x = [], y = 7, z = 12, A = 17, B = 22, C = 5, D = 9, E = 14, F = 20, G = 4, H = 11, I = 16, J = 23, K = 6, L = 10, M = 15, N = 21; for (a = n(a), x = l(a), t = 1732584193, u = 4023233417, v = 2562383102, w = 271733878, o = 0; o < x.length; o += 16)p = t, q = u, r = v, s = w, t = h(t, u, v, w, x[o + 0], y, 3614090360), w = h(w, t, u, v, x[o + 1], z, 3905402710), v = h(v, w, t, u, x[o + 2], A, 606105819), u = h(u, v, w, t, x[o + 3], B, 3250441966), t = h(t, u, v, w, x[o + 4], y, 4118548399), w = h(w, t, u, v, x[o + 5], z, 1200080426), v = h(v, w, t, u, x[o + 6], A, 2821735955), u = h(u, v, w, t, x[o + 7], B, 4249261313), t = h(t, u, v, w, x[o + 8], y, 1770035416), w = h(w, t, u, v, x[o + 9], z, 2336552879), v = h(v, w, t, u, x[o + 10], A, 4294925233), u = h(u, v, w, t, x[o + 11], B, 2304563134), t = h(t, u, v, w, x[o + 12], y, 1804603682), w = h(w, t, u, v, x[o + 13], z, 4254626195), v = h(v, w, t, u, x[o + 14], A, 2792965006), u = h(u, v, w, t, x[o + 15], B, 1236535329), t = i(t, u, v, w, x[o + 1], C, 4129170786), w = i(w, t, u, v, x[o + 6], D, 3225465664), v = i(v, w, t, u, x[o + 11], E, 643717713), u = i(u, v, w, t, x[o + 0], F, 3921069994), t = i(t, u, v, w, x[o + 5], C, 3593408605), w = i(w, t, u, v, x[o + 10], D, 38016083), v = i(v, w, t, u, x[o + 15], E, 3634488961), u = i(u, v, w, t, x[o + 4], F, 3889429448), t = i(t, u, v, w, x[o + 9], C, 568446438), w = i(w, t, u, v, x[o + 14], D, 3275163606), v = i(v, w, t, u, x[o + 3], E, 4107603335), u = i(u, v, w, t, x[o + 8], F, 1163531501), t = i(t, u, v, w, x[o + 13], C, 2850285829), w = i(w, t, u, v, x[o + 2], D, 4243563512), v = i(v, w, t, u, x[o + 7], E, 1735328473), u = i(u, v, w, t, x[o + 12], F, 2368359562), t = j(t, u, v, w, x[o + 5], G, 4294588738), w = j(w, t, u, v, x[o + 8], H, 2272392833), v = j(v, w, t, u, x[o + 11], I, 1839030562), u = j(u, v, w, t, x[o + 14], J, 4259657740), t = j(t, u, v, w, x[o + 1], G, 2763975236), w = j(w, t, u, v, x[o + 4], H, 1272893353), v = j(v, w, t, u, x[o + 7], I, 4139469664), u = j(u, v, w, t, x[o + 10], J, 3200236656), t = j(t, u, v, w, x[o + 13], G, 681279174), w = j(w, t, u, v, x[o + 0], H, 3936430074), v = j(v, w, t, u, x[o + 3], I, 3572445317), u = j(u, v, w, t, x[o + 6], J, 76029189), t = j(t, u, v, w, x[o + 9], G, 3654602809), w = j(w, t, u, v, x[o + 12], H, 3873151461), v = j(v, w, t, u, x[o + 15], I, 530742520), u = j(u, v, w, t, x[o + 2], J, 3299628645), t = k(t, u, v, w, x[o + 0], K, 4096336452), w = k(w, t, u, v, x[o + 7], L, 1126891415), v = k(v, w, t, u, x[o + 14], M, 2878612391), u = k(u, v, w, t, x[o + 5], N, 4237533241), t = k(t, u, v, w, x[o + 12], K, 1700485571), w = k(w, t, u, v, x[o + 3], L, 2399980690), v = k(v, w, t, u, x[o + 10], M, 4293915773), u = k(u, v, w, t, x[o + 1], N, 2240044497), t = k(t, u, v, w, x[o + 8], K, 1873313359), w = k(w, t, u, v, x[o + 15], L, 4264355552), v = k(v, w, t, u, x[o + 6], M, 2734768916), u = k(u, v, w, t, x[o + 13], N, 1309151649), t = k(t, u, v, w, x[o + 4], K, 4149444226), w = k(w, t, u, v, x[o + 11], L, 3174756917), v = k(v, w, t, u, x[o + 2], M, 718787259), u = k(u, v, w, t, x[o + 9], N, 3951481745), t = c(t, p), u = c(u, q), v = c(v, r), w = c(w, s); var O = m(t) + m(u) + m(v) + m(w); return O.toLowerCase() } 231 | 232 | // 完整 Env 233 | 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"]), this.isSurge() || this.isLoon() ? (this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.get(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) })) : this.isQuanX() ? (this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t))) : this.isNode() && (this.initGotEnv(t), this.got(t).on("redirect", (t, e) => { try { if (t.headers["set-cookie"]) { const s = t.headers["set-cookie"].map(this.cktough.Cookie.parse).toString(); s && this.ckjar.setCookieSync(s, null), e.cookieJar = this.ckjar } } catch (t) { this.logErr(t) } }).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) })) } post(t, e = (() => { })) { if (t.body && t.headers && !t.headers["Content-Type"] && (t.headers["Content-Type"] = "application/x-www-form-urlencoded"), t.headers && delete t.headers["Content-Length"], this.isSurge() || this.isLoon()) this.isSurge() && this.isNeedRewrite && (t.headers = t.headers || {}, Object.assign(t.headers, { "X-Surge-Skip-Scripting": !1 })), $httpClient.post(t, (t, s, i) => { !t && s && (s.body = i, s.statusCode = s.status), e(t, s, i) }); else if (this.isQuanX()) t.method = "POST", this.isNeedRewrite && (t.opts = t.opts || {}, Object.assign(t.opts, { hints: !1 })), $task.fetch(t).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => e(t)); else if (this.isNode()) { this.initGotEnv(t); const { url: s, ...i } = t; this.got.post(s, i).then(t => { const { statusCode: s, statusCode: i, headers: r, body: o } = t; e(null, { status: s, statusCode: i, headers: r, body: o }, o) }, t => { const { message: s, response: i } = t; e(s, i, i && i.body) }) } } time(t, e = null) { const s = e ? new Date(e) : new Date; let i = { "M+": s.getMonth() + 1, "d+": s.getDate(), "H+": s.getHours(), "m+": s.getMinutes(), "s+": s.getSeconds(), "q+": Math.floor((s.getMonth() + 3) / 3), S: s.getMilliseconds() }; /(y+)/.test(t) && (t = t.replace(RegExp.$1, (s.getFullYear() + "").substr(4 - RegExp.$1.length))); for (let e in i) new RegExp("(" + e + ")").test(t) && (t = t.replace(RegExp.$1, 1 == RegExp.$1.length ? i[e] : ("00" + i[e]).substr(("" + i[e]).length))); return t } msg(e = t, s = "", i = "", r) { const o = t => { if (!t) return t; if ("string" == typeof t) return this.isLoon() ? t : this.isQuanX() ? { "open-url": t } : this.isSurge() ? { url: t } : void 0; if ("object" == typeof t) { if (this.isLoon()) { let e = t.openUrl || t.url || t["open-url"], s = t.mediaUrl || t["media-url"]; return { openUrl: e, mediaUrl: s } } if (this.isQuanX()) { let e = t["open-url"] || t.url || t.openUrl, s = t["media-url"] || t.mediaUrl; return { "open-url": e, "media-url": s } } if (this.isSurge()) { let e = t.url || t.openUrl || t["open-url"]; return { url: e } } } }; if (this.isMute || (this.isSurge() || this.isLoon() ? $notification.post(e, s, i, o(r)) : this.isQuanX() && $notify(e, s, i, o(r))), !this.isMuteLog) { let t = ["", "==============📣系统通知📣=============="]; t.push(e), s && t.push(s), i && t.push(i), console.log(t.join("\n")), this.logs = this.logs.concat(t) } } log(...t) { t.length > 0 && (this.logs = [...this.logs, ...t]), console.log(t.join(this.logSeparator)) } logErr(t, e) { const s = !this.isSurge() && !this.isQuanX() && !this.isLoon(); s ? this.log("", `❗️${this.name}, 错误!`, t.stack) : this.log("", `❗️${this.name}, 错误!`, t) } wait(t) { return new Promise(e => setTimeout(e, t)) } done(t = {}) { const e = (new Date).getTime(), s = (e - this.startTime) / 1e3; this.log("", `🔔${this.name}, 结束! 🕛 ${s} 秒`), this.log(), (this.isSurge() || this.isQuanX() || this.isLoon()) && $done(t) } }(t, e) } 234 | 235 | //#endregion 236 | 237 | -------------------------------------------------------------------------------- /畅游.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # @Time: 2023年03月13日13时39分 3 | # @File: 畅游.py 4 | # @auth: Dreamfeelings 5 | import requests 6 | ''' 7 | 抓包抓 Authorization 8 | ''' 9 | Authorization = '' 10 | 11 | #签到 12 | def singin(Authorization): 13 | headers = { 14 | "Authorization": Authorization, 15 | "User-Agent": "Mozilla/5.0 (Linux; Android 13; 22011211C Build/TP1A.220624.014; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/109.0.5414.117 Mobile Safari/537.36; unicom{version:android@10.0200,desmobile:13185791278};devicetype{deviceBrand:Xiaomi,deviceModel:22011211C};{yw_code:}", 16 | } 17 | url = "https://game.wostore.cn/api/app/user/v2/signIn" 18 | response = requests.get(url, headers=headers) 19 | print(response.text) 20 | def lottery(Authorization): 21 | headers = { 22 | "Authorization": Authorization , 23 | "User-Agent": "Mozilla/5.0 (Linux; Android 13; 22011211C Build/TP1A.220624.014; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/109.0.5414.117 Mobile Safari/537.36; unicom{version:android@10.0200,desmobile:13185791278};devicetype{deviceBrand:Xiaomi,deviceModel:22011211C};{yw_code:}", 24 | } 25 | url = "https://game.wostore.cn/api/app/user/v2/benefit/lottery" 26 | params = { 27 | "id": "1" 28 | } 29 | response = requests.get(url, headers=headers, params=params) 30 | print(response.text) 31 | 32 | if __name__ == '__main__': 33 | singin(Authorization) 34 | lottery(Authorization) 35 | 36 | -------------------------------------------------------------------------------- /阅读抽奖.py: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | # @Time: 2023年03月13日12时44分 3 | # @File: 联通阅读 抽奖.py 4 | # @auth: Dreamfeelings 5 | import requests 6 | import time 7 | 8 | ''' 9 | 抓包抓 accesstoken , phoneNumber4net 10 | ''' 11 | 12 | accesstoken = '' 13 | phoneNumber4net = '' 14 | token = '' #pushplus token 15 | 16 | #阅读抽奖 17 | def read_lottery(accesstoken,phoneNumber4net,token): 18 | print('开始阅读抽奖!\n') 19 | result = '' 20 | # 抽奖 21 | headers = { 22 | "accesstoken": accesstoken, 23 | "User-Agent": "Mozilla/5.0 (Linux; Android 13; 22011211C Build/TP1A.220624.014; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/109.0.5414.117 Mobile Safari/537.36; unicom{version:android@10.0200,desmobile:13185791278};devicetype{deviceBrand:Xiaomi,deviceModel:22011211C};{yw_code:}", 24 | } 25 | cookies = { 26 | "phoneNumber4net": phoneNumber4net, 27 | } 28 | data = { 29 | "sign": "ZTU4Mjk4OTZjNzdjOTU3NDA1NDY4NjQyY2ViNjRlMzc0Mjc4MzE3MTU5ZGQ1ZDlkN2M1YzAyNTVjNGNlMDNhZTc4ZWQ0MTgwMTc4NzhiOTEzMmM0N2Q4NzlhNGI1ZDNkYzdiYzc5OTA5YzI3OTFkZjczN2I2MjY4MGUyYWJlMDI1YmM2MzAyODcwYWJiNmM2MmM5N2ZiNjljOTBiYWM5NWY3MTM2N2U1YjI4MWIwNDk5NGQ2NGZkNDU1ZjExN2VhOTg5YzkwYWE1NjFmYzQyMTY5Mzg2YjIxZGYxMDllMDJlNzIzM2E1YWFjNDAxNDA2MzA3ZThmODRmYmE5ZTEwZjUwZmFkMzljODg3ODY2YTAxZWM3ZmM0YjNiMzE3OGY0MDBkODc2MDUxYjEwOWU1ZWIyMzdlMjE0NTQwM2RiNWUxZDJlNWRjYjg2NmRiODBlOTBjOGI1YTBkNGNjYjViMGUxNzc5ZjMyMWRhMDRlMGZiZTFiYjc3MWE1MjlkYWQ3NGU4MmRmYTYzMjM0YmE5NzQyZjBmN2U0ZGE4Y2ZjZGY=" 30 | } 31 | for i in range(7): 32 | res = requests.post('https://10010.woread.com.cn/ng_woread_service/rest/basics/doDraw', headers=headers, 33 | cookies=cookies, json=data).json() 34 | if res['success'] == False: 35 | print(res['message']) 36 | result += res['message'] 37 | break 38 | else: 39 | prizedesc = res['data']['prizedesc'] # 奖品信息 40 | result += res['message'] 41 | print(prizedesc) 42 | time.sleep(2) 43 | pushplus(result,token) 44 | 45 | # pushplus推送 46 | def pushplus(content,token): 47 | title = '联通营业厅任务通知: ' 48 | url = 'http://www.pushplus.plus/send' 49 | data = { 50 | 'token' :token, 51 | 'title' : title, 52 | 'content' : content 53 | } 54 | 55 | res = requests.post(url,data=data).json() 56 | # print(res) 57 | try: 58 | status = '推送成功!' if res['code'] == 200 else res['msg'] 59 | print(status) 60 | except: 61 | print('推送异常!') 62 | if __name__ == '__main__': 63 | read_lottery(accesstoken,phoneNumber4net,token) --------------------------------------------------------------------------------