var rule = { title: '百忙无果[官]', host: 'https://pianku.api.%6d%67%74%76.com', homeUrl: '', searchUrl: 'https://mobileso.bz.%6d%67%74%76.com/msite/search/v2?q=**&pn=fypage&pc=10', detailUrl: 'https://pcweb.api.mgtv.com/episode/list?page=1&size=50&video_id=fyid', searchable: 2, quickSearch: 0, filterable: 1, multi: 1, url: '/rider/list/pcweb/v3?platform=pcweb&channelId=fyclass&pn=fypage&pc=80&hudong=1&_support=10000000&kind=a1&area=a1', filter_url: 'year={{fl.year or "all"}}&sort={{fl.sort or "all"}}&chargeInfo={{fl.chargeInfo or "all"}}', headers: { 'User-Agent': 'PC_UA' }, timeout: 5000, class_name: '臻彩4K⚡电影&臻彩4K⚡电视剧&臻彩4K⚡综艺&臻彩4K⚡动漫&臻彩4K⚡纪录片&臻彩4K⚡教育&臻彩4K⚡少儿', class_url: '3&2&1&50&51&115&10', filter: { "1": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }], "2": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }], "3": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }], "50": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }], "51": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }], "115": [{ "key": "chargeInfo", "name": "付费类型", "value": [{ "n": "全部", "v": "all" }, { "n": "免费", "v": "b1" }, { "n": "vip", "v": "b2" }, { "n": "VIP用券", "v": "b3" }, { "n": "付费点播", "v": "b4" }] }, { "key": "sort", "name": "排序", "value": [{ "n": "最新", "v": "c1" }, { "n": "最热", "v": "c2" }, { "n": "知乎高分", "v": "c4" }] }, { "key": "year", "name": "年代", "value": [{ "n": "全部", "v": "all" }, { "n": "2026", "v": "2026" }, { "n": "2025", "v": "2025" }, { "n": "2024", "v": "2024" }, { "n": "2023", "v": "2023" }, { "n": "2022", "v": "2022" }, { "n": "2021", "v": "2021" }, { "n": "2020", "v": "2020" }, { "n": "2019", "v": "2019" }, { "n": "2018", "v": "2018" }, { "n": "2017", "v": "2017" }, { "n": "2016", "v": "2016" }, { "n": "2015", "v": "2015" }, { "n": "2014", "v": "2014" }, { "n": "2013", "v": "2013" }, { "n": "2012", "v": "2012" }, { "n": "2011", "v": "2011" }, { "n": "2010", "v": "2010" }, { "n": "2009", "v": "2009" }, { "n": "2008", "v": "2008" }, { "n": "2007", "v": "2007" }, { "n": "2006", "v": "2006" }, { "n": "2005", "v": "2005" }, { "n": "2004", "v": "2004" }] }] }, limit: 20, play_parse: true, lazy: $js.toString(() => { try { let videoUrl = input.split("?")[0]; // 动态生成百万IP池 function generateMillionIPs() { const ipPool = []; // 生成A类地址段 (1.0.0.0 - 126.255.255.255) for (let a = 1; a <= 126; a++) { if (a === 10 || a === 127) continue; // 跳过私有地址和回环 for (let b = 0; b <= 255; b++) { // 每个A类段随机选择部分B类地址 if (Math.random() < 0.1) { // 10%的概率选择该B段 for (let c = 0; c <= 255; c++) { // 每个B类段随机选择部分C类地址 if (Math.random() < 0.01) { // 1%的概率选择该C段 const ip = `${a}.${b}.${c}.${Math.floor(Math.random() * 254) + 1}`; const port = [80, 8080, 3128, 443, 8443][Math.floor(Math.random() * 5)]; ipPool.push(`http://${ip}:${port}`); } } } } } // 生成B类地址段 (128.0.0.0 - 191.255.255.255) for (let a = 128; a <= 191; a++) { for (let b = 0; b <= 255; b++) { if (a === 172 && b >= 16 && b <= 31) continue; // 跳过私有地址 if (Math.random() < 0.05) { // 5%的概率选择该B段 for (let c = 0; c <= 255; c++) { if (Math.random() < 0.005) { // 0.5%的概率选择该C段 const ip = `${a}.${b}.${c}.${Math.floor(Math.random() * 254) + 1}`; const port = [80, 8080, 3128, 443, 8443][Math.floor(Math.random() * 5)]; ipPool.push(`http://${ip}:${port}`); } } } } } // 生成C类地址段 (192.0.0.0 - 223.255.255.255) for (let a = 192; a <= 223; a++) { for (let b = 0; b <= 255; b++) { if (a === 192 && b === 168) continue; // 跳过私有地址 if (a === 198 && b >= 18 && b <= 19) continue; // 跳过测试地址 if (Math.random() < 0.02) { // 2%的概率选择该B段 for (let c = 0; c <= 255; c++) { if (Math.random() < 0.002) { // 0.2%的概率选择该C段 const ip = `${a}.${b}.${c}.${Math.floor(Math.random() * 254) + 1}`; const port = [80, 8080, 3128, 443, 8443][Math.floor(Math.random() * 5)]; ipPool.push(`http://${ip}:${port}`); } } } } } return ipPool; } // 定义解析接口 const parseApis = [ "https://niubi.69mini.com/jsonapi/?url=", "http://jiexi.fc8001.top/GswHCTkjDZybiWZy.php?url=" ]; let playUrl = videoUrl; // 默认使用原始地址 let found = false; // 轮询尝试解析接口 for (let api of parseApis) { try { // 动态生成随机IP(每次都是全新的IP) const randomA = Math.floor(Math.random() * 223) + 1; let randomB = Math.floor(Math.random() * 256); let randomC = Math.floor(Math.random() * 256); let randomD = Math.floor(Math.random() * 254) + 1; // 避免私有地址和特殊地址 if (randomA === 10 || (randomA === 172 && randomB >= 16 && randomB <= 31) || (randomA === 192 && randomB === 168) || randomA === 127) { randomA = 8; // 回退到可用的公共地址 } const randomPort = [80, 8080, 3128, 443, 8443][Math.floor(Math.random() * 5)]; const randomProxy = `http://${randomA}.${randomB}.${randomC}.${randomD}:${randomPort}`; const proxyIp = `${randomA}.${randomB}.${randomC}.${randomD}`; // 生成随机User-Agent const userAgents = [ 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36', 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36', 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0', 'Mozilla/5.0 (iPhone; CPU iPhone OS 17_2 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.2 Mobile/15E148 Safari/604.1' ]; const randomUserAgent = userAgents[Math.floor(Math.random() * userAgents.length)]; let fullApi = api + encodeURIComponent(videoUrl); let response = fetch(fullApi, { method: 'GET', headers: { 'User-Agent': randomUserAgent, 'X-Forwarded-For': proxyIp, 'X-Real-IP': proxyIp, 'CF-Connecting-IP': proxyIp, 'Client-IP': proxyIp, 'X-Forwarded-Host': proxyIp, 'Forwarded': `for=${proxyIp}`, 'Referer': 'https://www.mgtv.com/', 'Accept': 'application/json, text/plain, */*', 'Accept-Language': 'zh-CN,zh;q=0.9,en;q=0.8' }, timeout: 10000 }); let data = JSON.parse(response); if (data.url && data.url.trim()) { // 检查是否是被屏蔽的地址 if (data.url.trim().startsWith("https://d.feiliupan.com/t/112641693848702976/IP使用次数超限,请加群签到.mp4") || data.url.trim().startsWith("https://web.wya6.com/d/super/zhuimi/qfad.mp4") || data.url.trim().startsWith("https://web.wya6.com/d/super/zhuimi/Anomaly.mp4")) { // 跳过被屏蔽地址,继续尝试其他解析接口 continue; } playUrl = data.url; found = true; break; // 成功获取播放地址,跳出循环 } } catch (e) { // 当前接口失败,尝试下一个 continue; } } // 最终检查地址是否被屏蔽 if (playUrl.startsWith("https://web.wya6.com/d/super/zhuimi/qfad.mp4") || playUrl.startsWith("https://web.wya6.com/d/super/zhuimi/Anomaly.mp4")) { playUrl = videoUrl; // 回退到原始视频地址 } input = { parse: 0, url: playUrl, jx: found ? 0 : 1, danmaku: "" + videoUrl }; } catch (e) { // 所有解析失败时使用原始地址 let videoUrl = input.split("?")[0]; input = { parse: 0, url: videoUrl, jx: 1, danmaku: "" + videoUrl }; } }), 一级: 'json:data.hitDocs;title;img;updateInfo||rightCorner.text;playPartId', 二级: $js.toString(() => { fetch_params.headers.Referer = "https://www.mgtv.com"; fetch_params.headers["User-Agent"] = MOBILE_UA; pdfh = jsp.pdfh; pdfa = jsp.pdfa; pd = jsp.pd; VOD = {}; let d = []; let html = request(input); let json = JSON.parse(html); let host = "https://www.mgtv.com"; let ourl = json.data.list.length > 0 ? json.data.list[0].url : json.data.series[0].url; if (!/^http/.test(ourl)) { ourl = host + ourl } fetch_params.headers["User-Agent"] = MOBILE_UA; html = request(ourl); if (html.includes("window.location =")) { print("开始获取ourl"); ourl = pdfh(html, "meta[http-equiv=refresh]&&content").split("url=")[1]; print("获取到ourl:" + ourl); html = request(ourl) } try { let details = pdfh(html, ".m-details&&Html").replace(/h1>/, "h6>").replace(/div/g, "br"); print(details); let actor = "", director = "", time = ""; if (/播出时间/.test(details)) { actor = pdfh(html, "p:eq(5)&&Text").substr(0, 25); director = pdfh(html, "p:eq(4)&&Text"); time = pdfh(html, "p:eq(3)&&Text") } else { actor = pdfh(html, "p:eq(4)&&Text").substr(0, 25); director = pdfh(html, "p:eq(3)&&Text"); time = "已完结" } let _img = pd(html, ".video-img&&img&&src"); let JJ = pdfh(html, ".desc&&Text").split("简介:")[1]; let _desc = time; VOD.vod_name = pdfh(html, ".vt-txt&&Text"); VOD.type_name = pdfh(html, "p:eq(0)&&Text").substr(0, 6); VOD.vod_area = pdfh(html, "p:eq(1)&&Text"); VOD.vod_actor = actor; VOD.vod_director = director; VOD.vod_remarks = _desc; VOD.vod_pic = _img; VOD.vod_content = JJ; if (!VOD.vod_name) { VOD.vod_name = VOD.type_name; } } catch (e) { log("获取影片信息发生错误:" + e.message) } function getRjpg(imgUrl, xs) { xs = xs || 3; let picSize = /jpg_/.test(imgUrl) ? imgUrl.split("jpg_")[1].split(".")[0] : false; let rjpg = false; if (picSize) { let a = parseInt(picSize.split("x")[0]) * xs; let b = parseInt(picSize.split("x")[1]) * xs; rjpg = a + "x" + b + ".jpg" } let img = /jpg_/.test(imgUrl) && rjpg ? imgUrl.replace(imgUrl.split("jpg_")[1], rjpg) : imgUrl; return img } if (json.data.total === 1 && json.data.list.length === 1) { let data = json.data.list[0]; let url = "https://www.mgtv.com" + data.url; d.push({ title: data.t4, desc: data.t2, pic_url: getRjpg(data.img), url: url }) } else if (json.data.list.length > 1) { for (let i = 1; i <= json.data.total_page; i++) { if (i > 1) { json = JSON.parse(fetch(input.replace("page=1", "page=" + i), {})) } json.data.list.forEach(function(data) { let url = "https://www.mgtv.com" + data.url; if (data.isIntact == "1") { d.push({ title: data.t4, desc: data.t2, pic_url: getRjpg(data.img), url: url }) } }) } } else { print(input + "暂无片源") } VOD.vod_play_from = "老三4K"; VOD.vod_play_url = d.map(function(it) { return it.title + "$" + it.url }).join("#"); setResult(d); }), 搜索: $js.toString(() => { fetch_params.headers.Referer = "https://www.mgtv.com"; fetch_params.headers["User-Agent"] = MOBILE_UA; let d = []; let html = request(input); let json = JSON.parse(html); json.data.contents.forEach(function(data) { if (data.type && data.type == 'media') { let item = data.data[0]; let desc = item.desc.join(','); let fyclass = ''; if (item.source === "imgo") { let img = item.img ? item.img : ''; try { fyclass = item.rpt.match(/idx=(.*?)&/)[1] + '$'; } catch (e) { log(e.message); fyclass = ''; } log(fyclass); d.push({ title: item.title.replace(/|<\/B>/g, ''), img: img, content: '', desc: desc, url: fyclass + item.url.match(/.*\/(.*?)\.html/)[1] }) } } }); setResult(d); }), }