小狐狸VIP视频免费看

来不及解释了,快上车!!!

// ==UserScript==
// @name         小狐狸VIP视频免费看
// @namespace    small_fox_vip_video_free_see_2
// @version      1.6
// @description  来不及解释了,快上车!!!
// @author       w2f
// @match        https://xhlld24244.cyou/*
// @match        https://xhlld1000.xyz/*
// @match        https://dfsd454.xyz/*
// @match        https://dfrd1009.cyou/*
// @include      /^http(s)?:\/\/ld01.xhlld\d+\.(cyou|xyz)/
// @include      /^http(s)?:\/\/ld.xhlld\d+\.(cyou|xyz)/
// @include      /^http(s)?:\/\/xhlld\d+\.(cyou|xyz)/
// @include      /^http(s)?:\/\/df\S+\.(cyou|xyz)/
// @icon         https://dfrd1009.cyou/favicon.ico
// @license      MIT
// @grant none
// @require      https://greasyfork.org/scripts/476730-ajaxhooker-2/code/ajaxHooker_2.js?version=1259979
// @run-at       document-start
// ==/UserScript==

(function() {
    'use strict';
    ajaxHooker.protect();
    ajaxHooker.filter([
        {type: 'xhr', url: '/view/getVideoInfo/', method: 'POST', async: true},//小狐狸
        {type: 'xhr', url: '/view/getLikeVideoList/', method: 'POST', async: true},//小狐狸
    ]);
    ajaxHooker.hook(request => {
        if (request.url.indexOf('/view/getVideoInfo/') > -1 ) {
            request.response = async res => {
                let jsonobj = JSON.parse(res.responseText);
                console.log("hooked!!! getVideoInfo ====>",jsonobj);
                //res.responseText = await modifyResponse2(res.responseText);
                //ajaxHooker.unhook();
                let tmp = jsonobj.data.coverUrl.split('cyou/')[1] || jsonobj.data.coverUrl.split('xyz/')[1];
                tmp = tmp.slice(0,17);//.split('/'); //"20240504/59kS6tea"
                window.m3u8_id = tmp;
            };
        }else if (request.url.indexOf('/view/getLikeVideoList/') > -1 ) {
            request.response = async res => {
                let jsonobj = JSON.parse(res.responseText);
                console.log("hooked!!! getLikeVideoList ====>",jsonobj);

                let m3u8_prefix = jsonobj.data.map(item=>{
                    let tmp = item.playUrl.split('/')[2] || item.playUrl.split('/')[2];
                    return tmp;
                });
                console.log("hooked!!! m3u8_prefix ====>",m3u8_prefix);

                window.m3u8_prefix = Array.from(new Set(m3u8_prefix));
                console.log("hooked!!! window.m3u8_prefix ====>",window.m3u8_prefix);
                //ajaxHooker.unhook();
            };
        }
    });
    async function modifyResponse2(responseText){
        let rspjson = await JSON.parse(responseText);
        let tmp = rspjson.data.coverUrl.split('cyou/')[1] || rspjson.data.coverUrl.split('xyz/')[1];
        tmp = tmp.slice(0,17);//.split('/');
        rspjson.data.collectCount = 0;
        rspjson.data.free = true;
        rspjson.data.isVip = true;
        rspjson.data.playUrl = rspjson.data.playUrl || `https://byym24091.cyou/${tmp}/index.m3u8`;
        //console.log("fixed rspjson====>",rspjson);
        return await JSON.stringify(rspjson);
    }
    function show_videoUrl(dizhi) {
        var xxx = document.querySelector("#my_add_dizhi"); if (xxx) xxx.parentNode.removeChild(xxx);
        var mydiv = document.createElement('div');
        let m3u8_str = "";
        for(var i =0; i <window.m3u8_prefix.length ;i++ ){
            if(window.m3u8_prefix[i] == undefined) continue;
            m3u8_str += `<a href="https://${window.m3u8_prefix[i]}/${window.m3u8_id}/index.m3u8" target="_blank">点此访问${i+1}</a>  `;
        }

        mydiv.innerHTML = `<div id="my_add_dizhi" style="color:red;font-size:14px;word-wrap: break-word;word-break: break-all;">\
            <p>✅视频已成功破解:<a href="https://byym24091.cyou/${window.m3u8_id}/index.m3u8" target="_blank">点此访问0</a> ${m3u8_str} </p>\
            <p>提示:若以上地址均无法播放,请去首页查看试看视频能否播放,试看视频也放不了说明服务器当前繁忙!</p></div>`;
        dizhi?.after(mydiv);
        clearInterval(my_timer);
    }

    function check_circle(){
        if(window.m3u8_prefix?.length && window.m3u8_id){
            let showpos = document.querySelector("#app > div > div.subjectBox > div > div:nth-child(3) > div:nth-child(3) > div:nth-child(1)") ||
                document.querySelector("#app > div > div:nth-child(1) > div:nth-child(6) > div:nth-child(1)"); //pc or moblie
            show_videoUrl(showpos);
        }else{
            console.log("⌛️视频破解中..");
        }
    }

    let my_timer = setInterval(check_circle, 2000);
})();