Submit for MB_Solver

Sending the form after solving the captcha

目前为 2022-11-20 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name Submit for MB_Solver
  3. // @namespace Violentmonkey Scripts
  4. // @version 1.0
  5. // @description Sending the form after solving the captcha
  6. // @author MultiBot
  7. // @match *://*/*
  8. // @run-at document-end
  9. // @grant none
  10. // ==/UserScript==
  11.  
  12. (function() {
  13. 'use strict';
  14. function _Search_Captcha(){
  15. if (window.grecaptcha && !window.grecaptcha.getResponse()){
  16. return false;
  17. }
  18. if (typeof window.hcaptcha=="object" && !window.hcaptcha.getResponse()){
  19. return false;
  20. }
  21. if (typeof window.ACPuzzleInfo=="object" && !document.querySelector("#adcopy_response").value){
  22. return false;
  23. }
  24. if (document.querySelector('input#antibotlinks') && !document.querySelector('input#antibotlinks').value){
  25. return false;
  26. }
  27. return true;
  28. }
  29. function _Search_Selector(query){
  30. if (document.querySelector(query)) {
  31. var timer = setInterval(function() {
  32. if (_Search_Captcha()) {
  33. document.querySelector(query).submit(); clearInterval(timer);
  34. }
  35. }, 5000);
  36. }
  37. }
  38. let arr_sel = ['form[action*="/faucet/verify"]','form[action*="/firewall/verify"]','form[action*="/auth/login"]'];
  39. for(let key of arr_sel){
  40. _Search_Selector(key);
  41. }
  42. })();