Google 搜索需要验证时自动切换 DuckDuckGo

Google 搜索需要验证时自动切换 DuckDuckGo 搜索相同内容

  1. // ==UserScript==
  2. // @name Google reCAPTCHA Bypass to DuckDuckGo
  3. // @name:zh-CN Google 搜索需要验证时自动切换 DuckDuckGo
  4. // @namespace http://tampermonkey.net/
  5. // @version 1.0
  6. // @description Automatically redirects Google reCAPTCHA page to DuckDuckGo search with the same query
  7. // @description:zh-cn Google 搜索需要验证时自动切换 DuckDuckGo 搜索相同内容
  8. // @author Dangel
  9. // @license MIT
  10. // @match https://www.google.com/sorry/index*
  11. // @match https://www.google.ad/sorry/index*
  12. // @match https://www.google.ae/sorry/index*
  13. // @match https://www.google.com.af/sorry/index*
  14. // @match https://www.google.com.ag/sorry/index*
  15. // @match https://www.google.com.ai/sorry/index*
  16. // @match https://www.google.al/sorry/index*
  17. // @match https://www.google.am/sorry/index*
  18. // @match https://www.google.co.ao/sorry/index*
  19. // @match https://www.google.com.ar/sorry/index*
  20. // @match https://www.google.as/sorry/index*
  21. // @match https://www.google.at/sorry/index*
  22. // @match https://www.google.com.au/sorry/index*
  23. // @match https://www.google.az/sorry/index*
  24. // @match https://www.google.ba/sorry/index*
  25. // @match https://www.google.com.bd/sorry/index*
  26. // @match https://www.google.be/sorry/index*
  27. // @match https://www.google.bf/sorry/index*
  28. // @match https://www.google.bg/sorry/index*
  29. // @match https://www.google.com.bh/sorry/index*
  30. // @match https://www.google.bi/sorry/index*
  31. // @match https://www.google.bj/sorry/index*
  32. // @match https://www.google.com.bn/sorry/index*
  33. // @match https://www.google.com.bo/sorry/index*
  34. // @match https://www.google.com.br/sorry/index*
  35. // @match https://www.google.bs/sorry/index*
  36. // @match https://www.google.bt/sorry/index*
  37. // @match https://www.google.co.bw/sorry/index*
  38. // @match https://www.google.by/sorry/index*
  39. // @match https://www.google.com.bz/sorry/index*
  40. // @match https://www.google.ca/sorry/index*
  41. // @match https://www.google.cd/sorry/index*
  42. // @match https://www.google.cf/sorry/index*
  43. // @match https://www.google.cg/sorry/index*
  44. // @match https://www.google.ch/sorry/index*
  45. // @match https://www.google.ci/sorry/index*
  46. // @match https://www.google.co.ck/sorry/index*
  47. // @match https://www.google.cl/sorry/index*
  48. // @match https://www.google.cm/sorry/index*
  49. // @match https://www.google.cn/sorry/index*
  50. // @match https://www.google.com.co/sorry/index*
  51. // @match https://www.google.co.cr/sorry/index*
  52. // @match https://www.google.com.cu/sorry/index*
  53. // @match https://www.google.cv/sorry/index*
  54. // @match https://www.google.com.cy/sorry/index*
  55. // @match https://www.google.cz/sorry/index*
  56. // @match https://www.google.de/sorry/index*
  57. // @match https://www.google.dj/sorry/index*
  58. // @match https://www.google.dk/sorry/index*
  59. // @match https://www.google.dm/sorry/index*
  60. // @match https://www.google.com.do/sorry/index*
  61. // @match https://www.google.dz/sorry/index*
  62. // @match https://www.google.com.ec/sorry/index*
  63. // @match https://www.google.ee/sorry/index*
  64. // @match https://www.google.com.eg/sorry/index*
  65. // @match https://www.google.es/sorry/index*
  66. // @match https://www.google.com.et/sorry/index*
  67. // @match https://www.google.fi/sorry/index*
  68. // @match https://www.google.com.fj/sorry/index*
  69. // @match https://www.google.fm/sorry/index*
  70. // @match https://www.google.fr/sorry/index*
  71. // @match https://www.google.ga/sorry/index*
  72. // @match https://www.google.ge/sorry/index*
  73. // @match https://www.google.gg/sorry/index*
  74. // @match https://www.google.com.gh/sorry/index*
  75. // @match https://www.google.com.gi/sorry/index*
  76. // @match https://www.google.gl/sorry/index*
  77. // @match https://www.google.gm/sorry/index*
  78. // @match https://www.google.gr/sorry/index*
  79. // @match https://www.google.com.gt/sorry/index*
  80. // @match https://www.google.gy/sorry/index*
  81. // @match https://www.google.com.hk/sorry/index*
  82. // @match https://www.google.hn/sorry/index*
  83. // @match https://www.google.hr/sorry/index*
  84. // @match https://www.google.ht/sorry/index*
  85. // @match https://www.google.hu/sorry/index*
  86. // @match https://www.google.co.id/sorry/index*
  87. // @match https://www.google.ie/sorry/index*
  88. // @match https://www.google.co.il/sorry/index*
  89. // @match https://www.google.im/sorry/index*
  90. // @match https://www.google.co.in/sorry/index*
  91. // @match https://www.google.iq/sorry/index*
  92. // @match https://www.google.is/sorry/index*
  93. // @match https://www.google.it/sorry/index*
  94. // @match https://www.google.je/sorry/index*
  95. // @match https://www.google.com.jm/sorry/index*
  96. // @match https://www.google.jo/sorry/index*
  97. // @match https://www.google.co.jp/sorry/index*
  98. // @match https://www.google.co.ke/sorry/index*
  99. // @match https://www.google.com.kh/sorry/index*
  100. // @match https://www.google.ki/sorry/index*
  101. // @match https://www.google.kg/sorry/index*
  102. // @match https://www.google.co.kr/sorry/index*
  103. // @match https://www.google.com.kw/sorry/index*
  104. // @match https://www.google.kz/sorry/index*
  105. // @match https://www.google.la/sorry/index*
  106. // @match https://www.google.com.lb/sorry/index*
  107. // @match https://www.google.li/sorry/index*
  108. // @match https://www.google.lk/sorry/index*
  109. // @match https://www.google.co.ls/sorry/index*
  110. // @match https://www.google.lt/sorry/index*
  111. // @match https://www.google.lu/sorry/index*
  112. // @match https://www.google.lv/sorry/index*
  113. // @match https://www.google.com.ly/sorry/index*
  114. // @match https://www.google.co.ma/sorry/index*
  115. // @match https://www.google.md/sorry/index*
  116. // @match https://www.google.me/sorry/index*
  117. // @match https://www.google.mg/sorry/index*
  118. // @match https://www.google.mk/sorry/index*
  119. // @match https://www.google.ml/sorry/index*
  120. // @match https://www.google.com.mm/sorry/index*
  121. // @match https://www.google.mn/sorry/index*
  122. // @match https://www.google.ms/sorry/index*
  123. // @match https://www.google.com.mt/sorry/index*
  124. // @match https://www.google.mu/sorry/index*
  125. // @match https://www.google.mv/sorry/index*
  126. // @match https://www.google.mw/sorry/index*
  127. // @match https://www.google.com.mx/sorry/index*
  128. // @match https://www.google.com.my/sorry/index*
  129. // @match https://www.google.co.mz/sorry/index*
  130. // @match https://www.google.com.na/sorry/index*
  131. // @match https://www.google.com.ng/sorry/index*
  132. // @match https://www.google.com.ni/sorry/index*
  133. // @match https://www.google.ne/sorry/index*
  134. // @match https://www.google.nl/sorry/index*
  135. // @match https://www.google.no/sorry/index*
  136. // @match https://www.google.com.np/sorry/index*
  137. // @match https://www.google.nr/sorry/index*
  138. // @match https://www.google.nu/sorry/index*
  139. // @match https://www.google.co.nz/sorry/index*
  140. // @match https://www.google.com.om/sorry/index*
  141. // @match https://www.google.com.pa/sorry/index*
  142. // @match https://www.google.com.pe/sorry/index*
  143. // @match https://www.google.com.pg/sorry/index*
  144. // @match https://www.google.com.ph/sorry/index*
  145. // @match https://www.google.com.pk/sorry/index*
  146. // @match https://www.google.pl/sorry/index*
  147. // @match https://www.google.pn/sorry/index*
  148. // @match https://www.google.com.pr/sorry/index*
  149. // @match https://www.google.ps/sorry/index*
  150. // @match https://www.google.pt/sorry/index*
  151. // @match https://www.google.com.py/sorry/index*
  152. // @match https://www.google.com.qa/sorry/index*
  153. // @match https://www.google.ro/sorry/index*
  154. // @match https://www.google.ru/sorry/index*
  155. // @match https://www.google.rw/sorry/index*
  156. // @match https://www.google.com.sa/sorry/index*
  157. // @match https://www.google.com.sb/sorry/index*
  158. // @match https://www.google.sc/sorry/index*
  159. // @match https://www.google.se/sorry/index*
  160. // @match https://www.google.com.sg/sorry/index*
  161. // @match https://www.google.sh/sorry/index*
  162. // @match https://www.google.si/sorry/index*
  163. // @match https://www.google.sk/sorry/index*
  164. // @match https://www.google.com.sl/sorry/index*
  165. // @match https://www.google.sn/sorry/index*
  166. // @match https://www.google.so/sorry/index*
  167. // @match https://www.google.sm/sorry/index*
  168. // @match https://www.google.sr/sorry/index*
  169. // @match https://www.google.st/sorry/index*
  170. // @match https://www.google.com.sv/sorry/index*
  171. // @match https://www.google.td/sorry/index*
  172. // @match https://www.google.tg/sorry/index*
  173. // @match https://www.google.co.th/sorry/index*
  174. // @match https://www.google.com.tj/sorry/index*
  175. // @match https://www.google.tl/sorry/index*
  176. // @match https://www.google.tm/sorry/index*
  177. // @match https://www.google.tn/sorry/index*
  178. // @match https://www.google.to/sorry/index*
  179. // @match https://www.google.com.tr/sorry/index*
  180. // @match https://www.google.tt/sorry/index*
  181. // @match https://www.google.com.tw/sorry/index*
  182. // @match https://www.google.co.tz/sorry/index*
  183. // @match https://www.google.com.ua/sorry/index*
  184. // @match https://www.google.co.ug/sorry/index*
  185. // @match https://www.google.co.uk/sorry/index*
  186. // @match https://www.google.com.uy/sorry/index*
  187. // @match https://www.google.co.uz/sorry/index*
  188. // @match https://www.google.com.vc/sorry/index*
  189. // @match https://www.google.co.ve/sorry/index*
  190. // @match https://www.google.vg/sorry/index*
  191. // @match https://www.google.co.vi/sorry/index*
  192. // @match https://www.google.com.vn/sorry/index*
  193. // @match https://www.google.vu/sorry/index*
  194. // @match https://www.google.ws/sorry/index*
  195. // @match https://www.google.rs/sorry/index*
  196. // @match https://www.google.co.za/sorry/index*
  197. // @match https://www.google.co.zm/sorry/index*
  198. // @match https://www.google.co.zw/sorry/index*
  199. // @match https://www.google.cat/sorry/index*
  200. // @grant none
  201. // ==/UserScript==
  202.  
  203. (function() {
  204. 'use strict';
  205.  
  206. // Get the current URL
  207. const currentUrl = window.location.href;
  208.  
  209. // Extract the 'continue' parameter which contains the original search query
  210. const urlParams = new URLSearchParams(window.location.search);
  211. const continueUrl = urlParams.get('continue');
  212.  
  213. if (continueUrl) {
  214. // Extract the 'q' parameter from the 'continue' URL
  215. const continueUrlParams = new URLSearchParams(new URL(continueUrl).search);
  216. const searchQuery = continueUrlParams.get('q');
  217.  
  218. if (searchQuery) {
  219. // Decode the search query
  220. const decodedQuery = decodeURIComponent(searchQuery);
  221.  
  222. // Construct the DuckDuckGo search URL
  223. const duckDuckGoUrl = `https://duckduckgo.com/?q=${encodeURIComponent(decodedQuery)}`;
  224.  
  225. // Redirect to DuckDuckGo
  226. window.location.href = duckDuckGoUrl;
  227. }
  228. }
  229. })();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址