// ==UserScript==
// @name 毒盘解析[JIE版]
// @author JIEMO
// @description 百毒网盘在线解析
// @version 1.7.0
// @namespace https://greasyfork.org/users/158417
// @match *://pan.baidu.com/s/*
// @match *://pan.baidu.com/share/*
// @match *://dupan.jie02.top/*
// ==/UserScript==
(function() {
'use strict';
//添加按钮(外扩)
function addJIE(){
//与填取pan.baidu.com的提取码脚本冲突
// let refore_url=window.location.href;
// code=refore_url.split("#")[1];
// $("#accessCode").val(code);
// setTimeout(function () {
// if($("#accessCode").val()!=""){
// $(".submit-a").click();
// }
// }, 300000);
var div = document.createElement("div");
div.innerHTML = "JIE解析";
var css = "position:fixed;top:60px;left:5px;z-index:999999999;width:100px;height:30px;line-height:30px;text-align:center;font-size:16px;font-family:Verdana, Arial, '楷体';font-weight:500;color:green;user-select:none;padding:0px;white-space:nowrap;border-radius:3px;border:2px solid red;cursor:pointer;";
div.style.cssText = css;
if(window.location.href.search("pan.baidu.com")!=-1){ document.body.appendChild(div);}
//监听事件
div.addEventListener("click",function(){
let after_url = window.location.href;
let new_url="";
if(after_url.search("/share/")!=-1){
new_url = after_url.replace("https://pan.baidu.com/share/init?surl=","http://dupan.jie02.top/s/1");
}else if(after_url.search("/s/")!=-1){
const url1 = "http://tts.baidu.com/text2audio?lan=zh&ie=UTF-8&per=4&text=" + encodeURI("开始JIE解析");
const audio = new Audio(url1);
audio.src = url1;
audio.play();
let CatPW_Info=document.getElementById("CatPW_Info").innerText;
let code=CatPW_Info.split("取码:")[1].split(" 解")[0];
new_url = after_url.replace("https://pan.baidu.com","http://dupan.jie02.top");
new_url = new_url.split("#list/path=%2F")[0];
new_url = new_url+"#"+code;
}
window.open(new_url, "_blank");
});
//填提取码
function fillCode(){
if(window.location.href.search("http://dupan.jie02.top/s/")!=-1){
if($('input').is('.swal2-input')){
let url=window.location.href;
let res="";
//弃用失效的提取码接口
// url=url.replace("dupan.jie02.top/s/","cors.jie02.top/?https://pwd.pandl.live/query?surl=");
// let code=fetch(url).then(res => res.text()).then(res=> $(".swal2-input").val(res));
res=url.split("#")[1];
$(".swal2-input").val(res);
setTimeout(function () {
if( $(".swal2-input").val()!=""){
$(".swal2-confirm").click();
}
}, 1);
const url3 = "http://tts.baidu.com/text2audio?lan=zh&ie=UTF-8&per=4&text=" + encodeURI("填写提取码完毕");
const audio = new Audio(url3);
audio.src = url3;
audio.play();
}
}
}
//验证当前token是否被限速
function verification(){
if(window.location.href.search("dupan.jie02.top/download")!=-1){
if($(".card-text").html().search("qdall")!=-1){
var div = document.createElement("div");
div.innerHTML = "当前token已被限速,请尝试刷新网页";
var css = "position:fixed;top:500px;left:450px;z-index:999999999;width:100px;height:30px;line-height:30px;text-align:center;font-size:50px;font-family:Verdana, Arial, '楷体';font-weight:500;color:red;user-select:none;padding:0px;white-space:nowrap;";
div.style.cssText = css;
if(window.self === window.top){ document.body.appendChild(div);}
const url4 = "http://tts.baidu.com/text2audio?lan=zh&ie=UTF-8&per=4&text=" + encodeURI("当前token已被限速,请尝试刷新网页");
const audio = new Audio(url4);
audio.src = url4;
audio.play();
}else{
if($("#key").html().search("9EVXZjcX")!=-1||$("#key").html().search("UEwMWRwb35Ka1Jv")!=-1){
var div2 = document.createElement("div");
div2.innerHTML = "当前处于超音速token,请勿滥用";
var css2 = "position:fixed;top:500px;left:450px;z-index:999999999;width:100px;height:30px;line-height:30px;text-align:center;font-size:50px;font-family:Verdana, Arial, '楷体';font-weight:500;color:green;user-select:none;padding:0px;white-space:nowrap;";
div2.style.cssText = css2;
if(window.self === window.top){ document.body.appendChild(div2);}
}
}
}
}
//生成复制按钮
function quickCopy(){
if(window.location.href.search("dupan.jie02.top/download")!=-1){
var parseurl=$("#http")[0].href;
var textarea = document.createElement("textarea");
textarea.id="copyTxt";
textarea.cols=30;
textarea.rows=10;
textarea.style.cssText="position:absolute;top:0;left:0;opacity:0;z-index:-20;";
var btn = document.createElement("button");
btn.innerText="复制http链接";
btn.style.cssText="font-family:Verdana, Arial, '楷体';color:red;position:absolute; z-index:999; top:177px;left:250px;";
document.body.appendChild(textarea);
document.getElementsByClassName('card-text')[0].insertBefore(btn,document.getElementsByClassName('http')[0]);
btn.onclick = function () {
copyTxt.value = parseurl;
copyTxt.select();
document.execCommand('copy');
}
}
}
fillCode();
verification();
quickCopy();
}
addJIE();
})();
毒盘解析[JIE版]百毒网盘在线解析
最新推荐文章于 2024-08-08 07:29:04 发布