Locvps油猴跳验证脚本
in CodingWall with 1 comment
// ==UserScript==
// @name         locvps mjj
// @namespace    http://tampermonkey.net/
// @version      2024-11-20
// @description  try to take over the world!
// @author       You
// @match        https://my.locvps.net/*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=locvps.net
// @grant        none
// ==/UserScript==
(function() {
    'use strict';
    // 定义一个URL验证函数
    function isValidUrl(url) {
        // 这里可以定义你的URL规则
        return url.indexOf('smsAuth&at=check')===-1;
    }

    $.ajaxPrefilter(function(options, originalOptions, jqXHR) {
        if (!isValidUrl(options.url)) {
            // 如果URL不符合规则,阻止请求发送并返回错误信息
            var errorMessage = '请求的URL不符合规则:' + options.url;
            console.error(errorMessage);
            jqXHR.abort();
            return false;
        }
    });
})();
Responses
  1. flycat

    thanks

    Reply