您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
B站纯净的av地址号转换
// ==UserScript== // @name 纯净av号地址 // @description B站纯净的av地址号转换 // @language zh-CN // @version 0.9 // @icon https://www.bilibili.com/favicon.ico // @match *://*.bilibili.com/* // @author liuAbin // @run-at document-start // @grant unsafeWindow // @namespace https://gf.qytechs.cn/scripts/437620 // @license MIT? idk // ==/UserScript== // this script is a fork from: https://gf.qytechs.cn/scripts/408684 const table='fZodR9XQDSUm21yCkr6zBqiveYah8bt4xsWpHnJE7jL5VG3guMTKNPAwcF', s=[11,10,3,8,4,6], xor=177451812, add=8728348608; switch([/www\.bilibili\.com\/s\/video\/BV/, /(search|space)\.bilibili\.com/] .findIndex(e => e.test(location.href))){ case 0: //location.pathname = `/video/${dec(location.pathname.replace('/s/video/', ''))}`; location.href = location.origin + `/video/${dec(location.pathname.replace('/s/video/', ''))}` break; case 1: unsafeWindow.onload = function() { document.querySelectorAll('a[href*="/BV"]').forEach(e => { var url = new URL(e.href); url.pathname = `/video/${dec(url.pathname.replace('/s/video/', ''))}`; e.href = url.href; }); }; break; case -1: } switch([/www\.bilibili\.com\/video\/BV/, /(search|space)\.bilibili\.com/] .findIndex(e => e.test(location.href))){ case 0: //location.pathname = `/video/${dec(location.pathname.replace('/video/', ''))}`; location.href = location.origin + `/video/${dec(location.pathname.replace('/video/', ''))}` //alert(location.pathname) //location.search = ``; break; case 1: unsafeWindow.onload = function() { document.querySelectorAll('a[href*="/BV"]').forEach(e => { var url = new URL(e.href); url.pathname = `/video/${dec(url.pathname.replace('/video/', ''))}`; e.href = url.href; }); }; break; case -1: } function dec(x){ var i, r = 0; for(i of Array(6).keys()){ r += table.indexOf(x[s[i]])*58**i;} return `av${(r-add)^xor}`; } function enc(x){ x=(parseInt(x)^xor)+add; var i, r=[...'BV1 4 1 7 ']; for(i of Array(6).keys()){ r[s[i]]=table[Math.floor(x/58**i)%58]} return r.join('') }
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址