Proxy Redirect

Redirect to privacy respecting proxy frontends

  1. // ==UserScript==
  2. // @name Proxy Redirect
  3. // @author Schimon Jehudah, Adv.
  4. // @collaborator hacker09
  5. // @collaborator Konf
  6. // @homepageURL https://greasyfork.org/scripts/465936-proxy-redirect
  7. // @supportURL https://greasyfork.org/scripts/465936-proxy-redirect/feedback
  8. // @copyright 2023 - 2025, Schimon Jehudah (http://schimon.i2p)
  9. // @license AGPL-3.0-only; https://www.gnu.org/licenses/agpl-3.0.en.html
  10. // @namespace i2p.schimon.proxy-redirect
  11. // @description Redirect to privacy respecting proxy frontends
  12. // @run-at document-start
  13. // @version 25.05.26
  14. // @grant GM.getValue
  15. // @grant GM.registerMenuCommand
  16. // @grant GM.setValue
  17. // @grant GM.xmlHttpRequest
  18. // @grant GM_xmlhttpRequest
  19. // @match file:///*
  20. // @match *://*/*
  21. // @connect 0011.lt
  22. // @connect 076.ne.jp
  23. // @connect 0ut0f.space
  24. // @connect 1search.i2p
  25. // @connect 1d4.us
  26. // @connect 2syis2nnyytz6jnusnjurva4swlaizlnleiks5mjp46phuwjbdjqwgqd.onion
  27. // @connect 40two.app
  28. // @connect 42l.fr
  29. // @connect absturztau.be
  30. // @connect actionsack.com
  31. // @connect adminforge.de
  32. // @connect albony.xyz
  33. // @connect arancia.click
  34. // @connect artemislena.eu
  35. // @connect asynchronousexchange.com
  36. // @connect batsense.net
  37. // @connect bibliogram.art
  38. // @connect btdig.i2p
  39. // @connect btdig.com
  40. // @connect btdigggink2pdqzqrik3blmqemsbntpzwxottujilcdjfz56jumzfsyd.onion
  41. // @connect bus-hit.me
  42. // @connect cadence.moe
  43. // @connect catsarch.i2p
  44. // @connect catfluori.de
  45. // @connect cblgh.org
  46. // @connect censors.us
  47. // @connect chauvet.pro
  48. // @connect citizen4.eu
  49. // @connect cowfee.moe
  50. // @connect creller.net
  51. // @connect crewz.me
  52. // @connect cn.i2p
  53. // @connect datatunnel.xyz
  54. // @connect dcs0.hu
  55. // @connect domain.glass
  56. // @connect datura.network
  57. // @connect duckdns.org
  58. // @connect ducks.party
  59. // @connect dynabyte.ca
  60. // @connect ebnar.xyz
  61. // @connect envs.net
  62. // @connect esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion
  63. // @connect etsi.me
  64. // @connect exarius.org
  65. // @connect facilmap.org
  66. // @connect farside.link
  67. // @connect fdn.fr
  68. // @connect flokinet.to
  69. // @connect flux.industries
  70. // @connect fmac.xyz
  71. // @connect froth.zone
  72. // @connect gatti.ninja
  73. // @connect ggc-project.de
  74. // @connect ggtyler.dev
  75. // @connect gnu.style
  76. // @connect go.metastem.su
  77. // @connect grimneko.de
  78. // @connect hostux.net
  79. // @connect hxvy0.gq
  80. // @connect hyperborea.cloud
  81. // @connect iket.me
  82. // @connect il.ax
  83. // @connect incogniweb.net
  84. // @connect incogsnoo.com
  85. // @connect invak.id
  86. // @connect jamiethalacker.dev
  87. // @connect jeikobu.net
  88. // @connect jewtube.i2p
  89. // @connect jing.rocks
  90. // @connect josias.dev
  91. // @connect jpope.org
  92. // @connect k62ptris7p72aborr4zoanee7xai6wguucveptwgxs5vbgt7qzpq.b32.i2p
  93. // @connect kavin.rocks
  94. // @connect kittywi.re
  95. // @connect kylrth.com
  96. // @connect ledditqo2mxfvlgobxnlhrkq4dh34jss6evfkdkb2thlvy6dn4f4gpyd.onion
  97. // @connect libredd.it
  98. // @connect libreddit.de
  99. // @connect libreddit.eu.org
  100. // @connect libreddit.hu
  101. // @connect libreddit.nl
  102. // @connect lingva.ml
  103. // @connect lqs5fjmajyp7rvp4qvyubwofzi6d4imua7vs237rkc4m5qogitqwrgyd.onion
  104. // @connect lr.n8pjl.ca
  105. // @connect lunar.icu
  106. // @connect melmac.space
  107. // @connect mint.lgbt
  108. // @connect moeyy.cn
  109. // @connect moomoo.me
  110. // @connect mywire.org
  111. // @connect mdosch.de
  112. // @connect monocles.de
  113. // @connect nadeko.net
  114. // @connect neet.works
  115. // @connect nerdvpn.de
  116. // @connect netlify.app
  117. // @connect neuters.de
  118. // @connect ngn.tf
  119. // @connect nitter.hu
  120. // @connect nitter.it
  121. // @connect nitter.net
  122. // @connect nitter.one
  123. // @connect nixnet.services
  124. // @connect no-logs.com
  125. // @connect nogoo.me
  126. // @connect northboot.xyz
  127. // @connect nttr.stream
  128. // @connect oakleycord.dev
  129. // @connect ononoki.org
  130. // @connect ooguy.com
  131. // @connect openstreetmap.org
  132. // @connect osi.kr
  133. // @connect oversold.host
  134. // @connect owacon.moe
  135. // @connect owo.si
  136. // @connect pabloferreiro.es
  137. // @connect paulgo.io
  138. // @connect pavot.ca
  139. // @connect phreedom.club
  140. // @connect piped.video
  141. // @connect poketube.fun
  142. // @connect priv.au
  143. // @connect privacy.com.de
  144. // @connect private.coffee
  145. // @connect projectsegfau.lt
  146. // @connect procurx.pt
  147. // @connect prvcy.eu
  148. // @connect puffyan.us
  149. // @connect pussthecat.org
  150. // @connect qwik.i2p
  151. // @connect qwikxx2erhx6qrymued6ox2qkf2yeogjwypqvzoif4fqkljixasr6oid.onion
  152. // @connect r.nf
  153. // @connect r4fo.com
  154. // @connect rabbit-company.com
  155. // @connect rasp.fr
  156. // @connect reallyaweso.me
  157. // @connect resrv.org
  158. // @connect revvy.de
  159. // @connect riverside.rocks
  160. // @connect rtrace.io
  161. // @connect scribe.rip
  162. // @connect search.cdev.nexus
  163. // @connect search.im-in.space
  164. // @connect search.zdechov.net
  165. // @connect searx.ankha.ac
  166. // @connect searx.be
  167. // @connect searx.ee
  168. // @connect searx.fi
  169. // @connect searx.ninja
  170. // @connect searx.ru
  171. // @connect sethforprivacy.com
  172. // @connect simplifiedprivacy.com
  173. // @connect simplytranslate.org
  174. // @connect smnz.de
  175. // @connect snopyta.org
  176. // @connect sny.sh
  177. // @connect some-things.org
  178. // @connect sp-codes.de
  179. // @connect spike.codes
  180. // @connect spjmllawtheisznfs7uryhxumin26ssv2draj7oope3ok3wuhy43eoyd.onion
  181. // @connect strongthany.cc
  182. // @connect stuehieyr.com
  183. // @connect sugoma.tk
  184. // @connect syncpundit.com
  185. // @connect teddit.i2p
  186. // @connect teddit.net
  187. // @connect tedditfyn6idalzso5wam5qd3kdtxoljjhbrbbx34q2xkcisvshuytad.onion
  188. // @connect theanonymouse.xyz
  189. // @connect tinfoil-hat.net
  190. // @connect tiekoetter.com
  191. // @connect tm4rwkeysv3zz3q5yacyr4rlmca2c4etkdobfvuqzt6vsfsu4weq.b32.i2p
  192. // @connect totaldarkness.net
  193. // @connect trom.tf
  194. // @connect tromdienste.de
  195. // @connect tux.land
  196. // @connect tux.pizza
  197. // @connect tuxcloud.net
  198. // @connect tyil.nl
  199. // @connect unixfox.eu
  200. // @connect unofficialbird.com
  201. // @connect userscripts-mirror.org
  202. // @connect vernapl3lpo3huqdx3pjzxqgdgavxjlmdskbvejh2gfqgmjuyvxq.b32.i2p
  203. // @connect vernaqj2qr2pijpgvf3od6ssc3ulz3nv52gwr3hba5l6humuzmgq.b32.i2p
  204. // @connect vernmzgraj6aaoafmehupvtkkynpaa67rxcdj2kinwiy6konn6rq.b32.i2p
  205. // @connect vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion
  206. // @connect vern.cc
  207. // @connect vern.i2p
  208. // @connect voidnet.tech
  209. // @connect vojkovic.xyz
  210. // @connect voring.me
  211. // @connect walkx.org
  212. // @connect webheberg.info
  213. // @connect weblibre.org
  214. // @connect whatever.social
  215. // @connect whatevertinfoil.de
  216. // @connect wikiless.i2p
  217. // @connect wikiless.org
  218. // @connect winscloud.net
  219. // @connect xcancel.com
  220. // @connect yewtu.be
  221. // @connect yonalee.eu
  222. // @connect ytmous.i2p
  223. // @connect xanny.family
  224. // @connect yacy.iko.soy
  225. // @connect zackptg5.com
  226. // @connect zaggy.nl
  227. // @connect zhaocloud.net
  228. // @connect zzls.i2p
  229. // @connect zzls.xyz
  230. // @icon data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNjRtbSIgaGVpZ2h0PSI2NG1tIiB2aWV3Qm94PSIwIDAgNjQgNjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHRleHQgeG1sOnNwYWNlPSJwcmVzZXJ2ZSIgc3R5bGU9ImZvbnQtd2VpZ2h0OjQwMDtmb250LXNpemU6MTkycHg7bGluZS1oZWlnaHQ6MDt0ZXh0LWluZGVudDowO3RleHQtYWxpZ246c3RhcnQ7dGV4dC1kZWNvcmF0aW9uLXN0eWxlOnNvbGlkO3RleHQtZGVjb3JhdGlvbi1jb2xvcjojMDAwO3dyaXRpbmctbW9kZTpsci10YjtkaXJlY3Rpb246bHRyO3RleHQtb3JpZW50YXRpb246bWl4ZWQ7ZG9taW5hbnQtYmFzZWxpbmU6YXV0bztiYXNlbGluZS1zaGlmdDpiYXNlbGluZTt0ZXh0LWFuY2hvcjpzdGFydDtzaGFwZS1wYWRkaW5nOjA7c2hhcGUtbWFyZ2luOjA7aW5saW5lLXNpemU6MDtvcGFjaXR5OjE7ZmlsbDojMDAwO2ZpbGwtb3BhY2l0eToxO3N0cm9rZS13aWR0aDoxLjI3OTgyO3N0cm9rZS1saW5lY2FwOmJ1dHQ7c3Ryb2tlLWxpbmVqb2luOm1pdGVyO3N0cm9rZS1taXRlcmxpbWl0OjQ7c3Ryb2tlLWRhc2hvZmZzZXQ6MDtzdHJva2Utb3BhY2l0eToxO3N0b3AtY29sb3I6IzAwMDtzdG9wLW9wYWNpdHk6MSIgeD0iMTcuMDA1MjQ1IiB5PSIzMS42NTg0MDUiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC00LjQzNjg1NjQgNDAuODk0OTQpIHNjYWxlKC4yNjQ1OCkiPjx0c3BhbiB4PSIxNy4wMDUyNDUiIHk9IjMxLjY1ODQwNSIgc3R5bGU9ImZvbnQtc2l6ZToxOTJweCI+8J+luDwvdHNwYW4+PC90ZXh0Pjwvc3ZnPgo=
  231. // ==/UserScript==
  232.  
  233. //TODO
  234.  
  235. // Display bar at top to enable redirection for current page when all instances are not enabled.
  236.  
  237. // Add https://www.qwant.com/maps/#map=9.00/XXX/YYY
  238.  
  239. //Rebrand: Open Redirect, Proxy Redirect
  240. //Rebrand: Freelink, LibreProxy, Libreproxy, Open Link, Proxy Direct, Proxy Link, Proxy Redirect
  241.  
  242. /*
  243.  
  244. FIXME"
  245.  
  246. Read settings from function pickURL
  247.  
  248. if (await GM.getValue('libreddit')) {
  249. proxyArray.push(proxy.libreddit)
  250. }
  251. if (await GM.getValue('teddit')) {
  252. proxyArray.push(proxy.teddit)
  253. }
  254. proxyArray = [proxy.libreddit, proxy.teddit];
  255.  
  256. urlArray = []
  257. if (await GM.getValue('libred')) {
  258. urlArray.concat(proxy.libred)
  259. }
  260.  
  261. NOTE
  262. This program was inspired by Farside project from Ben Busby
  263. For more information: https://farside.link
  264.  
  265. TODO
  266.  
  267. Add RDX https://rdx.overdevs.com/
  268.  
  269. Brand
  270. FreeDirector, Free Direct, FreeDirect.js
  271. Open Redirector, Open Redirect, Open Direct, OpenDirect.js
  272. Redirect.js, Redirect.user.js, Redirector.js
  273. UserDirect, UserRedirect
  274.  
  275. FIXME
  276. // @match *://*.imgur.com/*
  277. // @exclude *://i.*.imgur.com/*
  278.  
  279. FIXME RegEx
  280. // @exclude /*.medium\.com\/*\/(c|fit|v2)\/.*$/
  281.  
  282. */
  283.  
  284. // https://github.com/makyen
  285. // https://github.com/greasemonkey/greasemonkey/issues/3160#issuecomment-1456758080
  286. const gmXmlhttpRequest = typeof GM_xmlhttpRequest === 'function' ? GM_xmlhttpRequest : GM.xmlHttpRequest;
  287.  
  288. //const url = location.href;
  289.  
  290. const urlsMatchers = {
  291. 'exclude' : [
  292. {
  293. 'addr' : 'gist.github.com',
  294. 'host' : 'gist.github.com',
  295. 'path' : [],
  296. 'text' : ['View on GitHub'],
  297. },
  298. {
  299. 'addr' : 'github.com',
  300. 'host' : 'github.com',
  301. // not-href -> perhaps starts with, ends with and inclusive
  302. 'path' : [
  303. 'actions', 'archive', 'blame', 'blob', 'codespaces', 'collections',
  304. 'commit', 'compare', 'contribute', 'customer-stories', 'delete',
  305. 'discussions', 'edit', 'enterprise', 'events', 'features', 'files',
  306. 'graphs', 'issues', 'labels', 'login', 'marketplace', 'milestones',
  307. 'notifications', 'orgs', 'password_reset', 'pricing', 'projects', 'pull', 'pulse',
  308. 'releases', 'security', 'sessions', 'settings', 'signup', 'solutions',
  309. 'sponsors', 'tags', 'team/', 'topics', 'tree', 'trending', 'wiki'
  310. ],
  311. 'text' : ['View on GitHub'],
  312. },
  313. {
  314. 'addr' : 'gitlab.com',
  315. 'host' : 'gitlab.com',
  316. 'path' : [
  317. 'activity', 'artifacts', 'boards', 'cadences', 'compare', 'commits', 'jobs',
  318. 'labels', 'merge_requests', 'network', 'path_locks', 'pipeline_schedules',
  319. 'pipelines', 'project_members', 'requirements_management', 'sign_in',
  320. 'starrers', 'subgroups', 'successful_verification', 'tags', 'test_cases',
  321. 'tree', 'uploads', 'wikis'
  322. ],
  323. },
  324. {
  325. 'addr' : 'imdb.com',
  326. 'host' : 'imdb.com',
  327. 'path' : ['reviews'],
  328. },
  329. {
  330. 'addr' : 'medium.com',
  331. 'host' : 'medium.com',
  332. 'path' : ['feed/', 'c/', 'fit/', 'format:', 'resize:fit:', 'v2/'],
  333. },
  334. {
  335. 'addr' : 'safereddit.com',
  336. 'host' : 'safereddit.com',
  337. 'path' : [''],
  338. },
  339. {
  340. 'addr' : 'stackoverflow.com/questions/',
  341. 'host' : 'stackoverflow.com',
  342. 'path' : ['tagged', 'users'], // /questions/tagged
  343. },
  344. {
  345. 'addr' : 'tiktok.com',
  346. 'host' : 'tiktok.com',
  347. 'path' : ['discover', 'playlist'],
  348. },
  349. {
  350. 'addr' : 'www.torrentdownload.info',
  351. 'host' : 'torrentdownload.info',
  352. 'path' : ['feed_latest', 'search?q='],
  353. },
  354. {
  355. 'addr' : 'torrentz.eu',
  356. 'host' : 'torrentz.eu',
  357. 'path' : ['search?f='],
  358. },
  359. {
  360. 'addr' : 'torrentz.me',
  361. 'host' : 'torrentz.me',
  362. 'path' : ['search?f='],
  363. },
  364. {
  365. 'addr' : 'torrentz2.eu',
  366. 'host' : 'torrentz2.eu',
  367. 'path' : ['search?f='],
  368. },
  369. {
  370. 'addr' : 'torrentz2.is',
  371. 'host' : 'torrentz2.is',
  372. 'path' : ['search?f='],
  373. },
  374. // {
  375. // 'addr' : 'youtube.com',
  376. // 'host' : 'youtube.com',
  377. // 'path' : ['users'],
  378. // 'text' : ['Watch on YouTube'],
  379. // }
  380. ], // hosts, paths and texts to exclude
  381.  
  382. 'includeByHostname' : [
  383. {
  384. 'addr' : 'bandcamp.com',
  385. 'host' : 'bandcamp.com',
  386. },
  387. {
  388. 'addr' : 'bilibili.com',
  389. 'host' : 'bilibili.com',
  390. },
  391. {
  392. 'addr' : 'fandom.com',
  393. 'host' : 'fandom.com',
  394. },
  395. {
  396. 'addr' : 'gist.github.com',
  397. 'host' : 'gist.github.com',
  398. },
  399. {
  400. 'addr' : 'github.com',
  401. 'host' : 'github.com',
  402. },
  403. {
  404. 'addr' : 'gitlab.com',
  405. 'host' : 'gitlab.com',
  406. },
  407. {
  408. 'addr' : 'goodreads.com',
  409. 'host' : 'goodreads.com',
  410. },
  411. {
  412. 'addr' : 'imdb.com',
  413. 'host' : 'imdb.com',
  414. },
  415. {
  416. 'addr' : 'imgur.com',
  417. 'host' : 'imgur.com',
  418. },
  419. {
  420. 'addr' : 'instructables.com',
  421. 'host' : 'instructables.com',
  422. },
  423. {
  424. 'addr' : 'instagram.com',
  425. 'host' : 'instagram.com',
  426. },
  427. {
  428. 'addr' : 'invidious-invidious.invidious.svc.cluster.local:3000',
  429. 'host' : 'invidious-invidious.invidious.svc.cluster.local:3000',
  430. },
  431. {
  432. 'addr' : 'medium.com',
  433. 'host' : 'medium.com',
  434. },
  435. {
  436. 'addr' : 'moovitapp.com',
  437. 'host' : 'moovitapp.com',
  438. },
  439. {
  440. 'addr' : 'odysee.com',
  441. 'host' : 'odysee.com',
  442. },
  443. {
  444. 'addr' : 'reddit.com',
  445. 'host' : 'reddit.com',
  446. },
  447. {
  448. 'addr' : 'old.reddit.com',
  449. 'host' : 'old.reddit.com',
  450. },
  451. {
  452. 'addr' : 'quora.com',
  453. 'host' : 'quora.com',
  454. },
  455. {
  456. 'addr' : 'reuters.com',
  457. 'host' : 'reuters.com',
  458. },
  459. {
  460. 'addr' : 'tiktok.com',
  461. 'host' : 'tiktok.com',
  462. },
  463. {
  464. 'addr' : 'www.torrentdownload.info',
  465. 'host' : 'torrentdownload.info',
  466. },
  467. {
  468. 'addr' : 'torrentz.eu',
  469. 'host' : 'torrentz.eu',
  470. },
  471. {
  472. 'addr' : 'torrentz.me',
  473. 'host' : 'torrentz.me',
  474. },
  475. {
  476. 'addr' : 'torrentz2.eu',
  477. 'host' : 'torrentz2.eu',
  478. },
  479. {
  480. 'addr' : 'torrentz2.is',
  481. 'host' : 'torrentz2.is',
  482. },
  483. {
  484. 'addr' : 'twitter.com',
  485. 'host' : 'twitter.com',
  486. },
  487. {
  488. 'addr' : 'urbandictionary.com',
  489. 'host' : 'urbandictionary.com',
  490. },
  491. {
  492. 'addr' : 'userscripts.org',
  493. 'host' : 'userscripts.org',
  494. },
  495. {
  496. 'addr' : 'wikimap.toolforge.org',
  497. 'host' : 'wikimap.toolforge.org',
  498. },
  499. {
  500. 'addr' : 'search.yahoo.co.jp',
  501. 'host' : 'yahoo.co.jp',
  502. },
  503. {
  504. 'addr' : 'youtu.be',
  505. 'host' : 'youtu.be',
  506. },
  507. {
  508. 'addr' : 'youtube.com',
  509. 'host' : 'youtube.com',
  510. },
  511. {
  512. 'addr' : 'x.com',
  513. 'host' : 'x.com',
  514. }
  515. ], // hosts to include
  516.  
  517. 'includeBySLD' : [
  518. {
  519. 'addr' : 'bandcamp.com',
  520. 'host' : 'bandcamp.com',
  521. },
  522. {
  523. 'addr' : 'medium.com',
  524. 'host' : 'medium.com',
  525. },
  526. {
  527. 'addr' : 'reddit.com', // old.reddit.com
  528. 'host' : 'reddit',
  529. },
  530. {
  531. 'addr' : 'tumblr.com',
  532. 'host' : 'tumblr',
  533. },
  534. {
  535. 'addr' : 'wikipedia.org',
  536. 'host' : 'wikipedia',
  537. },
  538. {
  539. 'addr' : 'x.com',
  540. 'host' : 'x.com',
  541. }
  542. ], // hosts to include by second-level-domain
  543.  
  544. 'includeByPathnameAndSLD' : [
  545. {
  546. 'addr' : 'google.com',
  547. 'host' : 'google',
  548. 'path' : ['search'],
  549. }
  550. ], // hosts to include by pathname and second-level-domain
  551.  
  552. 'includeByPathname' : [
  553. {
  554. 'addr' : 'bt4g.org/magnet/',
  555. 'host' : 'bt4g.org',
  556. 'path' : ['magnet'],
  557. },
  558. {
  559. 'addr' : 'bt4gprx.com/magnet/',
  560. 'host' : 'bt4gprx.com',
  561. 'path' : ['magnet'],
  562. },
  563. {
  564. 'addr' : 'bing.com/(maps|search)',
  565. 'host' : 'bing.com',
  566. 'path' : ['maps', 'search'],
  567. },
  568. {
  569. 'addr' : 'fandom.com/wiki',
  570. 'host' : 'fandom.com',
  571. 'path' : ['wiki'],
  572. },
  573. {
  574. 'addr' : 'google.com/maps',
  575. 'host' : 'google.com',
  576. 'path' : ['maps'],
  577. },
  578. // {
  579. // 'addr' : 'google.com/sorry',
  580. // 'host' : 'google.com',
  581. // 'path' : ['sorry'],
  582. // },
  583. {
  584. 'addr' : 'stackoverflow.com/questions/',
  585. 'host' : 'stackoverflow.com',
  586. 'path' : ['questions'],
  587. },
  588. {
  589. 'addr' : 'yahoo.com/search',
  590. 'host' : 'yahoo.com',
  591. 'path' : ['search'],
  592. },
  593. {
  594. 'addr' : '(www|ul).waze.com/(live-map|ul)',
  595. 'host' : 'waze.com',
  596. 'path' : ['live-map', 'ul'],
  597. },
  598. {
  599. 'addr' : 'yandex.com/(maps|search)',
  600. 'host' : 'yandex.com',
  601. 'path' : ['maps', 'search'],
  602. },
  603. // { // THIS PART OF CODE BELONGS TO FJYT
  604. // 'addr' : 'youtube-nocookie.com',
  605. // 'host' : 'youtube-nocookie.com',
  606. // 'path' : ['@', 'channel', 'watch'],
  607. // },
  608. // { // THIS PART OF CODE BELONGS TO FJYT
  609. // 'addr' : 'youtube.com',
  610. // 'host' : 'youtube.com',
  611. // 'path' : ['@', 'channel', 'watch'],
  612. // }
  613. ], // hosts to include by pathname
  614.  
  615. };
  616.  
  617. const proxy = {
  618. "4get": {
  619. "clearnet": [
  620. "https://4get.ca",
  621. "https://4get.hbubli.cc",
  622. "https://4get.nadeko.net",
  623. "https://4get.plunked.party",
  624. "https://4get.sijh.net",
  625. "https://4get.silly.computer",
  626. "https://4get.zzls.xyz",
  627. "https://search.mint.lgbt",
  628. ],
  629. "i2p": [],
  630. "loki": [],
  631. "tor": [
  632. "http://4get.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion",
  633. "http://4getus.zzls2vhse6jeahgdz5snle37dnngmbeh4jgug5xvsdpmlchaw3ieonid.onion",
  634. "http://4get.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion",
  635. "http://d6imk74yn4crbqnni3kwioogwpqrfi4kay6ci7nghl363ogy4atctiid.onion",
  636. "http://4getwebfrq5zr4sxugk6htxvawqehxtdgjrbcn2oslllcol2vepa23yd.onion"
  637. ],
  638. "yggdrasil": []
  639. },
  640. "anonymousoverflow": {
  641. "clearnet": [
  642. "https://anonymousoverflow.privacyredirect.com",
  643. "https://anonymousoverflow.vern.cc",
  644. "https://ao.bloat.cat",
  645. "https://ao.ngn.tf",
  646. "https://ao.owo.si",
  647. "https://ao.phreedom.club",
  648. // "https://ao.rootdo.com", // CURRENTLY OFFLINE - WILL BE BACK SOON - NO ETA
  649. "https://ao.vern.cc",
  650. "https://code.whatever.social",
  651. "https://overflow.adminforge.de",
  652. "https://overflow.ducks.party",
  653. "https://overflow.hostux.net",
  654. "https://overflow.lunar.icu",
  655. "https://overflow.perennialte.ch",
  656. "https://overflow.projectsegfau.lt",
  657. "https://overflow.reallyaweso.me",
  658. "https://stackoverflow.vern.cc",
  659. ],
  660. "i2p": [
  661. "http://vernmzgraj6aaoafmehupvtkkynpaa67rxcdj2kinwiy6konn6rq.b32.i2p"
  662. ],
  663. "loki": [],
  664. "tor": [
  665. "http://anonymousoverflow.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  666. "http://ao.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  667. ],
  668. "yggdrasil": [
  669. "http://[301:f69c:2017:b6b8::8]"
  670. ]
  671. },
  672. "bibliogram": {
  673. "clearnet": [],
  674. "i2p": [],
  675. "loki": [],
  676. "tor": [
  677. "http://qsuiaf4jio2yaxdbj6ljte3jmr6m7g333rujoilbtipjeawnou26frad.onion",
  678. "http://rlp5gt4d7dtkok3yaogocbcvrs2tdligjrxipsamztjq4wwpxzjeuxqd.onion"
  679. ],
  680. "yggdrasil": []
  681. },
  682. "biblioreads": {
  683. "clearnet": [
  684. "https://biblioreads.eu.org",
  685. "https://biblioreads.ducks.party",
  686. "https://biblioreads.lunar.icu",
  687. "https://biblioreads.netlify.app",
  688. "https://bl.vern.cc",
  689. "https://biblioreads.privacyredirect.com"
  690. ],
  691. "i2p": [
  692. "http://vernapl3lpo3huqdx3pjzxqgdgavxjlmdskbvejh2gfqgmjuyvxq.b32.i2p"
  693. ],
  694. "loki": [],
  695. "tor": [
  696. "http://biblioreads.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  697. "http://bl.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  698. ],
  699. "yggdrasil": []
  700. },
  701. "binternet": {
  702. "clearnet": [
  703. "https://binternet.ducks.party",
  704. "https://bn.bloat.cat",
  705. "https://bn.opnxng.com",
  706. ],
  707. "i2p": [
  708. "http://revznkqdwy7nmlzql66x226g3qnapiooss3rg2uajbj4rypxjnba.b32.i2p",
  709. "http://5cv2aw6jhe6la444vpn3jvo46442ls3ccgp3difx5ddlv5yf4hlq.b32.i2p"
  710. ],
  711. "loki": [],
  712. "tor": [
  713. "http://binternet.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion",
  714. "http://binternet.skunky7dhv7nohsoalpwe3sxfz3fbkad7r3wk632riye25vqm3meqead.onion"
  715. ],
  716. "yggdrasil": []
  717. },
  718. "breezewiki": {
  719. "clearnet": [
  720. "https://antifandom.com",
  721. "https://bw.artemislena.eu",
  722. "https://breezewiki.pussthecat.org",
  723. "https://bw.projectsegfau.lt",
  724. "https://breeze.hostux.net",
  725. "https://breeze.nohost.network",
  726. "https://breezewiki.hyperreal.coffee",
  727. "https://breezewiki.nadeko.net",
  728. "https://bw.hamstro.dev",
  729. "https://fan.blitzw.in",
  730. "https://fandom.reallyaweso.me",
  731. "https://breezewiki.catsarch.com",
  732. "https://breeze.mint.lgbt",
  733. "https://z.opnxng.com"
  734. ],
  735. "i2p": [
  736. "http://bw.vern.i2p"
  737. ],
  738. "loki": [],
  739. "tor": [],
  740. "yggdrasil": []
  741. },
  742. "btdigg": {
  743. "clearnet": [
  744. "https://btdig.com"
  745. ],
  746. "i2p": [
  747. "http://btdig.i2p"
  748. ],
  749. "loki": [],
  750. "tor": [
  751. "http://btdigggink2pdqzqrik3blmqemsbntpzwxottujilcdjfz56jumzfsyd.onion"
  752. ],
  753. "yggdrasil": []
  754. },
  755. "cloudtube": {
  756. "clearnet": [
  757. "https://tube.cadence.moe",
  758. "https://tube.mint.lgbt",
  759. ],
  760. "i2p": [],
  761. "loki": [],
  762. "tor": [],
  763. "yggdrasil": []
  764. },
  765. "destructables": {
  766. "clearnet": [
  767. "https://ds.vern.cc"
  768. ],
  769. "i2p": [],
  770. "loki": [],
  771. "tor": [],
  772. "yggdrasil": []
  773. },
  774. "dumb": {
  775. "clearnet": [
  776. "https://dumb.privacydev.net",
  777. "https://dumb.ducks.party",
  778. "https://dm.vern.cc",
  779. "https://dumb.reallyaweso.me",
  780. "https://dumb.lunar.icu",
  781. ],
  782. "i2p": [
  783. "http://vernxpcpqi2y4uhu7to4rnjmyjjgzh3x3qxyzpmkhykefchkmleq.b32.i2p"
  784. ],
  785. "loki": [],
  786. "tor": [
  787. "http://dumb.g4c3eya4clenolymqbpgwz3q3tawoxw56yhzk4vugqrl6dtu3ejvhjid.onion",
  788. "http://dm.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion",
  789. "http://dm.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  790. ],
  791. "yggdrasil": []
  792. },
  793. "facilmap": {
  794. "clearnet": [
  795. "https://facilmap.org"
  796. ],
  797. "i2p": [],
  798. "loki": [],
  799. "tor": [],
  800. "yggdrasil": []
  801. },
  802. "gothub": {
  803. "clearnet": [
  804. "https://gothub.lunar.icu",
  805. "https://gothub.dev.projectsegfau.lt",
  806. "https://gothub.ducks.party",
  807. "https://gh.phreedom.club",
  808. "https://gothub.projectsegfau.lt",
  809. "https://gh.owo.si",
  810. "https://gothub.r4fo.com",
  811. "https://g.opnxng.com",
  812. "https://gothub.private.coffee",
  813. ],
  814. "i2p": [],
  815. "loki": [],
  816. "tor": [],
  817. "yggdrasil": []
  818. },
  819. //"imgin": {
  820. // "clearnet": [],
  821. // "i2p": [],
  822. // "loki": [],
  823. // "tor": [],
  824. // "yggdrasil": []
  825. //},
  826. "indestructables": {
  827. "clearnet": [
  828. "https://indestructables.private.coffee"
  829. ],
  830. "i2p": [],
  831. "loki": [],
  832. "tor": [],
  833. "yggdrasil": []
  834. },
  835. "alltube": {
  836. "clearnet": [
  837. "https://alltube.private.coffee"
  838. ],
  839. "i2p": [],
  840. "loki": [],
  841. "tor": [],
  842. "yggdrasil": []
  843. },
  844. "invidious": {
  845. "clearnet": [
  846. "https://inv.nadeko.net",
  847. "https://inv1.nadeko.net",
  848. "https://inv2.nadeko.net",
  849. "https://inv3.nadeko.net",
  850. "https://inv4.nadeko.net",
  851. "https://inv5.nadeko.net",
  852. "https://incogtube.com",
  853. "https://vid.puffyan.us",
  854. "https://yt.artemislena.eu",
  855. "https://iteroni.com",
  856. "https://yewtu.be",
  857. // "https://invidious.kavin.rocks",
  858. "https://invidious.reallyaweso.me",
  859. "https://monocles.live",
  860. "https://inv.riverside.rocks",
  861. "https://invidious.lunar.icu",
  862. "https://y.com.sb",
  863. "https://inv.bp.projectsegfau.lt",
  864. "https://invidious.privacyredirect.com",
  865. "https://invidious.flokinet.to",
  866. "https://invidious.sethforprivacy.com",
  867. "https://ytb.trom.tf",
  868. "https://invidious.domain.glass",
  869. // "https://tube.cthd.icu",
  870. "https://inv.vern.cc",
  871. "https://invidious.garudalinux.org",
  872. "https://youtube.owacon.moe",
  873. "https://invidious.tinfoil-hat.net",
  874. "https://iv.melmac.space",
  875. "https://invidious.tiekoetter.com",
  876. "https://invidious.baczek.me",
  877. "https://invidious.no-logs.com",
  878. "https://invidious.incogniweb.net",
  879. "https://invidious.0011.lt",
  880. "https://yt.funami.tech",
  881. "https://inv.tux.pizza",
  882. "https://vid.priv.au",
  883. "https://not-ytb.blocus.ch",
  884. "https://inv.creller.net",
  885. "https://inv.zzls.xyz",
  886. "https://yt.floss.media",
  887. "https://par1.iv.ggtyler.dev",
  888. "https://inv.citw.lgbt",
  889. "https://invidious.io.lol",
  890. "https://yt.oelrichsgarcia.de",
  891. "https://iv.nboeck.de",
  892. "https://invidious.protokolla.fi",
  893. "https://invidious.fi",
  894. "https://onion.tube",
  895. "https://inv.in.projectsegfau.lt",
  896. "https://invidious.privacydev.net",
  897. "https://invidious.takebackourtech.org",
  898. "https://qc1.iv.ggtyler.dev",
  899. "https://anontube.lvkaszus.pl",
  900. "https://invidious.asir.dev",
  901. "https://invidious.fdn.fr",
  902. "https://iv.datura.network",
  903. "https://invidious.private.coffee",
  904. "https://inv.pistasjis.net",
  905. "https://invidious.pavot.ca",
  906. "https://yt.cdaut.de",
  907. "https://yt.drgnz.club",
  908. "https://invidious.perennialte.ch",
  909. "https://yt.chaotic.ninja",
  910. "https://yt.omada.cafe",
  911. "https://super8.absturztau.be",
  912. "https://i.redsnake.io",
  913. "https://watch.supernets.org",
  914. "https://invidious.qwik.space",
  915. "https://invidious.nerdvpn.de",
  916. "https://invidious.projectsegfau.lt",
  917. "https://invidious.weblibre.org",
  918. "https://iv.ggtyler.dev",
  919. // "https://watch.thekitty.zone",
  920. "https://inv.us.projectsegfau.lt",
  921. "https://invidious.drgns.space",
  922. "https://invidious.kalli.st"
  923. ],
  924. "i2p": [
  925. "http://tube.i2p",
  926. "http://inv.cn.i2p",
  927. "http://jewtube.i2p",
  928. "http://ytmous.i2p",
  929. "http://pa7eextqat4wg35onzs4cnlhqa3gvzen243bcbrng67zyla4fqya.b32.i2p",
  930. "http://inv.vern.i2p",
  931. "http://inv.zzls.i2p",
  932. "http://invidious.qwik.i2p",
  933. "http://verni6dr4qxjgjumnvesxerh5rvhv6oy5ddeibaqy5d7tgbiiyfa.b32.i2p"
  934. ],
  935. "loki": [],
  936. "tor": [
  937. "http://tuberyps2pn6dor6h47brof3w2asmauahhk4ei42krugybzzzo55klad.onion",
  938. "http://qwikxxeiw4kgmml6vjw2bsxtviuwjce735dunai2djhu6q7qbacq73id.onion",
  939. "http://qwikxxt6jvggxzxe2v2fuzro5j7ibgphxmblmri6wkj5vpicdbo2kwad.onion",
  940. "http://inv.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  941. "http://inv1.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  942. "http://inv2.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  943. "http://inv3.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  944. "http://inv4.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  945. "http://inv5.nadekonw7plitnjuawu6ytjsl7jlglk2t6pyq6eftptmiv3dvqndwvyd.onion",
  946. "http://c7hqkpkpemu6e7emz5b4vyz7idjgdvgaaa3dyimmeojqbgpea3xqjoid.onion",
  947. "http://grwp24hodrefzvjjuccrkw3mjq4tzhaaq32amf33dzpmuxe7ilepcmad.onion",
  948. "http://invidious.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  949. "http://euxxcnhsynwmfidvhjf6uzptsmh4dipkmgdmcmxxuo7tunp3ad2jrwyd.onion",
  950. "http://invidious.g4c3eya4clenolymqbpgwz3q3tawoxw56yhzk4vugqrl6dtu3ejvhjid.onion",
  951. "http://iv.odysfvr23q5wgt7i456o5t3trw2cw5dgn56vbjfbq2m7xsc5vqbqpcyd.onion",
  952. "http://kbjggqkzv65ivcqj6bumvp337z6264huv5kpkwuv6gu5yjiskvan7fad.onion",
  953. "http://ng27owmagn5amdm7l5s3rsqxwscl5ynppnis5dqcasogkyxcfqn7psid.onion",
  954. "http://osbivz6guyeahrwp2lnwyjk2xos342h4ocsxyqrlaopqjuhwn2djiiyd.onion",
  955. "http://u2cvlit75owumwpy4dj2hsmvkq7nvrclkpht7xgyye2pyoxhpmclkrad.onion",
  956. "http://w6ijuptxiku4xpnnaetxvnkc5vqcdu7mgns2u77qefoixi63vbvnpnqd.onion"
  957. ],
  958. "yggdrasil": [
  959. "http://[200:168a:c80a:b258:1dfe:f920:4414:6897]"
  960. ]
  961. },
  962. "kddit": {
  963. "clearnet": [
  964. "https://kddit.kalli.st"
  965. ],
  966. "i2p": [],
  967. "loki": [],
  968. "tor": [],
  969. "yggdrasil": []
  970. },
  971. "minisearch": {
  972. "clearnet": [
  973. // "https://minisearch.r4fo.com"
  974. ],
  975. "i2p": [],
  976. "loki": [],
  977. "tor": [],
  978. "yggdrasil": []
  979. },
  980. "laboratory": {
  981. "clearnet": [
  982. "https://lab.vern.cc",
  983. // "https://laboratory.vitali64.duckdns.org"
  984. ],
  985. "i2p": [],
  986. "loki": [],
  987. "tor": [],
  988. "yggdrasil": []
  989. },
  990. "libmedium": {
  991. "clearnet": [
  992. "https://medium.hostux.net",
  993. "https://libmedium.batsense.net",
  994. "https://med.ngn.tf",
  995. "https://md.vern.cc"
  996. ],
  997. "i2p": [
  998. "http://vernaqj2qr2pijpgvf3od6ssc3ulz3nv52gwr3hba5l6humuzmgq.b32.i2p"
  999. ],
  1000. "loki": [],
  1001. "tor": [
  1002. "http://md.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  1003. ],
  1004. "yggdrasil": []
  1005. },
  1006. "librarian": {
  1007. "clearnet": [
  1008. "https://librarian.pussthecat.org",
  1009. "https://odysee.076.ne.jp",
  1010. "https://lbry.projectsegfau.lt",
  1011. "https://lbry.mywire.org",
  1012. "https://lbry.vern.cc",
  1013. "https://lbry.ooguy.com",
  1014. "https://lbn.frail.duckdns.org",
  1015. "https://odysee.owacon.moe",
  1016. "https://lbry.bcow.xyz"
  1017. ],
  1018. "i2p": [],
  1019. "loki": [],
  1020. "tor": [
  1021. "http://librarian.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  1022. "http://lbry.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion",
  1023. "http://5znbzx2xcymhddzekfjib3isgqq4ilcyxa2bsq6vqmnvbtgu4f776lqd.onion",
  1024. "http://bxewpsswttslepw27w2hhxhlizwm7l7y54x3jw5cfrb64hb6lgc557ad.onion"
  1025. ],
  1026. "yggdrasil": []
  1027. },
  1028. "libreddit": {
  1029. "clearnet": [
  1030. "https://libreddit.spike.codes",
  1031. "https://libreddit.nl",
  1032. "https://libreddit.strongthany.cc",
  1033. "https://libreddit.40two.app",
  1034. "https://libreddit.albony.xyz",
  1035. "https://libreddit.privacydev.net",
  1036. "https://libreddit.kavin.rocks",
  1037. "https://libreddit.privacy.com.de",
  1038. // "https://libreddit.no-logs.com",
  1039. "https://lr.creller.net",
  1040. "https://libreddit.dcs0.hu",
  1041. "https://libreddit.tux.pizza",
  1042. "https://snoo.habedieeh.re",
  1043. "https://lr.4201337.xyz",
  1044. "https://lr.artemislena.eu",
  1045. "https://libreddit.qwik.space",
  1046. "https://de.leddit.xyz",
  1047. "https://leddit.xyz",
  1048. "https://libreddit.autarkic.org",
  1049. "https://libreddit.crewz.me",
  1050. "https://libreddit.de",
  1051. "https://libreddit.dothq.co",
  1052. "https://libreddit.drivet.xyz",
  1053. // "https://libreddit.igna.rocks",
  1054. "https://libredd.it",
  1055. "https://libreddit.jamiethalacker.dev",
  1056. "https://libreddit.kylrth.com",
  1057. "https://libreddit.lunar.icu",
  1058. // "https://libreddit.northboot.xyz",
  1059. "https://libreddit.pussthecat.org",
  1060. "https://libreddit.silkky.cloud",
  1061. "https://libreddit.sugoma.tk",
  1062. "https://libreddit.winscloud.net",
  1063. "https://libreddit.yonalee.eu",
  1064. "https://lr.cowfee.moe",
  1065. // "https://lr.mint.lgbt",
  1066. "https://lr.oversold.host",
  1067. "https://lr.stilic.ml",
  1068. "https://r.nf",
  1069. "https://r.walkx.org",
  1070. "https://reddit.artemislena.eu",
  1071. "https://reddit.phii.me",
  1072. "https://reddit.rtrace.io",
  1073. "https://reddit.stuehieyr.com",
  1074. "https://libreddit.nohost.network",
  1075. "https://reddit.simo.sh"
  1076. ],
  1077. "i2p": [
  1078. "http://woo5ugmoomzbtaq6z46q4wgei5mqmc6jkafqfi5c37zni7xc4ymq.b32.i2p"
  1079. ],
  1080. "loki": [],
  1081. "tor": [
  1082. "http://spjmllawtheisznfs7uryhxumin26ssv2draj7oope3ok3wuhy43eoyd.onion",
  1083. "http://qwikxxeiw4kgmml6vjw2bsxtviuwjce735dunai2djhu6q7qbacq73id.onion",
  1084. "http://qwikxx4xqvhdyyazkrw7pwdpdppfnmn7j2n6cvq5zecm4atbppaslzad.onion",
  1085. "http://ecue64ybzvn6vjzl37kcsnwt4ycmbsyf74nbttyg7rkc3t3qwnj7mcyd.onion",
  1086. "http://fwhhsbrbltmrct5hshrnqlqygqvcgmnek3cnka55zj4y7nuus5muwyyd.onion",
  1087. "http://inytumdgnri7xsqtvpntjevaelxtgbjqkuqhtf6txxhwbll2fwqtakqd.onion",
  1088. "http://kphht2jcflojtqte4b4kyx7p2ahagv4debjj32nre67dxz7y57seqwyd.onion",
  1089. "http://kzhfp3nvb4qp575vy23ccbrgfocezjtl5dx66uthgrhu7nscu6rcwjyd.onion",
  1090. "http://lbrdtjaj7567ptdd4rv74lv27qhxfkraabnyphgcvptl64ijx2tijwid.onion",
  1091. "http://libreddit.2syis2nnyytz6jnusnjurva4swlaizlnleiks5mjp46phuwjbdjqwgqd.onion",
  1092. "http://ledditqo2mxfvlgobxnlhrkq4dh34jss6evfkdkb2thlvy6dn4f4gpyd.onion",
  1093. "http://libreddit.lqs5fjmajyp7rvp4qvyubwofzi6d4imua7vs237rkc4m5qogitqwrgyd.onion",
  1094. "http://libredoxhxwnmsb6dvzzd35hmgzmawsq5i764es7witwhddvpc2razid.onion",
  1095. "http://ol5begilptoou34emq2sshf3may3hlblvipdjtybbovpb7c7zodxmtqd.onion",
  1096. "http://liredejj74h5xjqr2dylnl5howb2bpikfowqoveub55ru27x43357iid.onion"
  1097. ],
  1098. "yggdrasil": []
  1099. },
  1100. "libremdb": {
  1101. "clearnet": [
  1102. "https://libremdb.iket.me",
  1103. "https://lmdb.ngn.tf",
  1104. "https://ld.vern.cc",
  1105. "https://binge.whatever.social",
  1106. "https://libremdb.ducks.party",
  1107. "https://libremdb.lunar.icu",
  1108. "https://libremdbeu.herokuapp.com",
  1109. "https://libremdb.pussthecat.org",
  1110. "https://libremdb.jeikobu.net",
  1111. "https://lmdb.hostux.net",
  1112. "https://libremdb.catsarch.com",
  1113. // "https://libremdb.fascinated.cc"
  1114. ],
  1115. "i2p": [
  1116. "http://vernz3ubrntql4wrgyrssd6u3qzi36zrhz2agbo6vibzbs5olk2q.b32.i2p"
  1117. ],
  1118. "loki": [],
  1119. "tor": [
  1120. "http://ld.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion",
  1121. "http://libremdb.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion"
  1122. ],
  1123. "yggdrasil": []
  1124. },
  1125. "librex": {
  1126. "clearnet": [
  1127. "https://search.pabloferreiro.es",
  1128. "https://search.funami.tech",
  1129. "https://librex.retro-hax.net",
  1130. "https://librex.zzls.xyz",
  1131. "https://librex.nohost.network",
  1132. "https://librex.baczek.me",
  1133. "https://buscar.weblibre.org",
  1134. "https://librex.mikata.ru",
  1135. "https://librex.myroware.eu",
  1136. "https://librex.pufe.org",
  1137. "https://librex.revvy.de",
  1138. "https://lx.vern.cc",
  1139. "https://search.femboy.hu",
  1140. "https://search.madreyk.xyz",
  1141. "https://search.milivojevic.in.rs",
  1142. "https://search.sesu.cc",
  1143. "https://search.tildevarsh.in",
  1144. "https://librex.ratakor.com",
  1145. "https://lx.drain.win"
  1146. ],
  1147. "i2p": [
  1148. "http://libremdb.catsarch.i2p",
  1149. "http://7huurwog32tny663wkglrhozfoyqyqmsuxjbd7dtudccx44awjda.b32.i2p",
  1150. "http://lqbchqljxiwl3bbjt4vqe76luovk5ly6khqhg7mt5qcqfn6e4sbq.b32.i2p",
  1151. "http://revekebotog64xrrammtsmjwtwlg3vqyzwdurzt2pu6botg4bejq.b32.i2p",
  1152. "http://vernziqfqvweijfaacmwazohgpdo2bt2ib2jlupt2pwwu27bhgxq.b32.i2p"
  1153. ],
  1154. "loki": [],
  1155. "tor": [
  1156. "http://fcnfg6avz45hqzwbneekq57u2mqbnwa7veyvjcc4dndqbatvkjlaj7yd.onion",
  1157. "http://f7ssz7l3biu4fugwctfpcx4txg5yq4gqhrt473ledsuc3ivtd3omniid.onion",
  1158. "http://librex.revvybrr6pvbx4n3j4475h4ghw4elqr4t5xo2vtd3gfpu2nrsnhh57id.onion",
  1159. "http://librex.zzlsghu6mvvwyy75mvga6gaf4znbp3erk5xwfzedb4gg6qqh2j6rlvid.onion",
  1160. "http://lx.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion",
  1161. "http://search.cepyxplublbyw2f4axy4pyztfbxmf63lrt2c7uwv6wl4iixz53czload.onion",
  1162. "http://search.swxoebbpeqiiixyhbuh3vbw53pdrmtbiaj2sqveol6kkn5rpapfi4aad.onion"
  1163. ],
  1164. "yggdrasil": []
  1165. },
  1166. "librey": {
  1167. "clearnet": [
  1168. "https://search.pabloferreiro.es",
  1169. "https://search.funami.tech",
  1170. "https://librex.retro-hax.net",
  1171. "https://search.davidovski.xyz",
  1172. "https://search.zeroish.xyz",
  1173. "https://search.seitan-ayoub.lol",
  1174. "https://lx.benike.me",
  1175. "https://librey.baczek.me",
  1176. "https://librex.yogeshlamichhane.com.np",
  1177. "https://librex.nohost.network",
  1178. "https://librex.ix.tc",
  1179. "https://librex.uk.to",
  1180. "https://librex.supernets.org",
  1181. "https://librey.org",
  1182. "https://librey.danyaal.xyz",
  1183. "https://ly.owo.si",
  1184. "https://search.ratakor.com",
  1185. "https://ahwx.org",
  1186. ],
  1187. "i2p": [
  1188. "http://d4vi3tvfui2rfzsxr33tin4a6542heulf4mhkokdpbhbcejlg3la.b32.i2p",
  1189. "http://libreyqmoa2iuihoyyscolhaymrxxgdrmkgmiufnyaukwub2c7ya.b32.i2p"
  1190. ],
  1191. "loki": [],
  1192. "tor": [
  1193. "http://ly.pk47sgwhncn5cgidm7bofngmh7lc7ukjdpk5bjwfemmyp27ovl25ikyd.onion",
  1194. "http://libreytvcxak42f3p7nxh3filsp2pjqesjii5f5e4eivs2gpcn77tdid.onion",
  1195. "http://hyy7rcvknwb22v4nnoar635wntiwr4uwzhiuyimemyl4fz6k7tahj5id.onion",
  1196. "http://wn5jl6fxlzzfenlyu3lc4q7jpw2saplrywxvxtvqbguotwd4y5cjeuqd.onion",
  1197. "http://jxhkfulu6wpdl4apuy4dyivuowmpprvsd7e3el2z73crq7fmyv7rjkyd.onion",
  1198. "http://ouosr2fq3lktngcvbz4r4op2lab5hbiz5y6g6toorsgieb7elet76jad.onion"
  1199. ],
  1200. "yggdrasil": []
  1201. },
  1202. "lieu": {
  1203. "clearnet": [
  1204. "https://lieu.cblgh.org"
  1205. ],
  1206. "i2p": [],
  1207. "loki": [],
  1208. "tor": [],
  1209. "yggdrasil": []
  1210. },
  1211. "lingva": {
  1212. "clearnet": [
  1213. "https://lingva.reallyaweso.me",
  1214. "https://translate.libtar.de",
  1215. "https://lingva.retiolus.net",
  1216. "https://translate.plausibility.cloud",
  1217. "https://lingva.lunar.icu",
  1218. "https://lingva.dialectapp.org"
  1219. ],
  1220. "i2p": [],
  1221. "loki": [],
  1222. "tor": [],
  1223. "yggdrasil": []
  1224. },
  1225. "materialious": {
  1226. "clearnet": [
  1227. "https://materialious.nadeko.net"
  1228. ],
  1229. "i2p": [],
  1230. "loki": [],
  1231. "tor": [],
  1232. "yggdrasil": []
  1233. },
  1234. "metastem": {
  1235. "clearnet": [
  1236. "https://go.metastem.su"
  1237. ],
  1238. "i2p": [],
  1239. "loki": [],
  1240. "tor": [],
  1241. "yggdrasil": []
  1242. },
  1243. "metastemwiki": {
  1244. "clearnet": [
  1245. "https://wiki.metastem.su"
  1246. ],
  1247. "i2p": [],
  1248. "loki": [],
  1249. "tor": [],
  1250. "yggdrasil": []
  1251. },
  1252. "mikuinvidious": {
  1253. "clearnet": [
  1254. "https://mi.resrv.org",
  1255. "https://mikuinv-gs.vern.cc",
  1256. "https://mikuinv.resrv.org",
  1257. "https://moeyy.cn/mikuinvidious"
  1258. ],
  1259. "i2p": [],
  1260. "loki": [],
  1261. "tor": [],
  1262. "yggdrasil": []
  1263. },
  1264. "mozhi": {
  1265. "clearnet": [
  1266. "https://mozhi.pussthecat.org",
  1267. "https://translate.bus-hit.me",
  1268. "https://translate.perennialte.ch"
  1269. ],
  1270. "i2p": [],
  1271. "loki": [],
  1272. "tor": [],
  1273. "yggdrasil": []
  1274. },
  1275. "neuters": {
  1276. "clearnet": [
  1277. "https://neuters.de",
  1278. "https://neuters.vern.cc",
  1279. "https://nu.vern.cc",
  1280. "https://reuters.vern.cc",
  1281. ],
  1282. "i2p": [],
  1283. "loki": [],
  1284. "tor": [],
  1285. "yggdrasil": []
  1286. },
  1287. "nitter": {
  1288. "clearnet": [
  1289. "https://nitter.hu",
  1290. "https://nitter.actionsack.com",
  1291. "https://nitter.net",
  1292. "https://nitter.1d4.us",
  1293. "https://nitter.nixnet.services",
  1294. "https://nitter.unixfox.eu",
  1295. "https://nitter.sethforprivacy.com",
  1296. "https://nitter.pussthecat.org",
  1297. "https://xcancel.com",
  1298. "https://nitter.it",
  1299. "https://nitter.moomoo.me",
  1300. "https://tw.artemislena.eu",
  1301. "https://nitter.snopyta.org",
  1302. "https://birdsite.xanny.family",
  1303. "https://nitter.domain.glass",
  1304. // "https://read.whatever.social",
  1305. // "https://nitter.lacontrevoie.fr",
  1306. "https://bird.trom.tf",
  1307. "https://nitter.hostux.net",
  1308. "https://nitter.sneed.network",
  1309. "https://twitter.owacon.moe",
  1310. "https://nitter.ggc-project.de",
  1311. "https://unofficialbird.com",
  1312. "https://nitter.fdn.fr",
  1313. "https://nitter.no-logs.com",
  1314. "https://nitter.one",
  1315. "https://nitter.ungovernable.men",
  1316. "https://nitter.private.coffee",
  1317. // "https://nitter.soopy.moe",
  1318. "https://nitter.oksocial.net",
  1319. "https://n.sneed.network",
  1320. "https://nitter.qwik.space",
  1321. "https://nitter.nohost.network",
  1322. "https://de.nttr.stream",
  1323. "https://nitter.42l.fr",
  1324. "https://nitter.bus-hit.me",
  1325. // "https://nitter.ca",
  1326. // "https://nitter.eu",
  1327. "https://nitter.grimneko.de",
  1328. "https://nitter.kavin.rocks",
  1329. "https://nitter.koyu.space",
  1330. "https://nttr.stream",
  1331. "https://twitter.076.ne.jp",
  1332. "https://twitter.censors.us",
  1333. "https://n.hyperborea.cloud",
  1334. "https://n.biendeo.com",
  1335. // "https://n.opnxng.com",
  1336. "https://nitter.adminforge.de",
  1337. "https://nitter.catsarch.com",
  1338. "https://nitter.cz",
  1339. "https://nitter.in.projectsegfau.lt",
  1340. "https://nitter.io.lol",
  1341. "https://nitter.ktachibana.party",
  1342. "https://nitter.kylrth.com",
  1343. "https://nitter.poast.org",
  1344. "https://nitter.privacydev.net",
  1345. "https://nitter.salastil.com",
  1346. "https://nitter.woodland.cafe",
  1347. "https://nitter.dcs0.hu"
  1348. ],
  1349. "i2p": [
  1350. "http://tm4rwkeysv3zz3q5yacyr4rlmca2c4etkdobfvuqzt6vsfsu4weq.b32.i2p"
  1351. ],
  1352. "loki": [],
  1353. "tor": [
  1354. "http://qwikxxeiw4kgmml6vjw2bsxtviuwjce735dunai2djhu6q7qbacq73id.onion",
  1355. "http://qwikxx2erhx6qrymued6ox2qkf2yeogjwypqvzoif4fqkljixasr6oid.onion",
  1356. "http://n.sneed4fmhevap3ci4xhf4wgkf72lwk275lcgomnfgwniwmqvaxyluuid.onion"
  1357. ],
  1358. "yggdrasil": []
  1359. },
  1360. "openstreetmap": {
  1361. "clearnet": [
  1362. "https://www.openstreetmap.org"
  1363. ],
  1364. "i2p": [],
  1365. "loki": [],
  1366. "tor": [],
  1367. "yggdrasil": []
  1368. },
  1369. "tubo": {
  1370. "clearnet": [
  1371. "https://tubo.media",
  1372. "https://tubo.reallyaweso.me"
  1373. ],
  1374. "i2p": [],
  1375. "loki": [],
  1376. "tor": [],
  1377. "yggdrasil": []
  1378. },
  1379. "twineo": {
  1380. "clearnet": [
  1381. "https://twineo.reallyaweso.me"
  1382. ],
  1383. "i2p": [],
  1384. "loki": [],
  1385. "tor": [],
  1386. "yggdrasil": []
  1387. },
  1388. "pipedmaterial": {
  1389. "clearnet": [
  1390. "https://piped-material.xn--17b.net"
  1391. ],
  1392. "i2p": [],
  1393. "loki": [],
  1394. "tor": [],
  1395. "yggdrasil": []
  1396. },
  1397. "piped": {
  1398. "clearnet": [
  1399. "https://piped.kavin.rocks",
  1400. "https://piped.mint.lgbt",
  1401. "https://piped.video",
  1402. "https://watch.whatevertinfoil.de",
  1403. "https://piped.ducks.party",
  1404. "https://watch.whatever.social",
  1405. "https://piped.reallyaweso.me",
  1406. "https://piped.hostux.net",
  1407. "https://piped.no-logs.com",
  1408. "https://piped.qdi.fi",
  1409. "https://piped.ngn.tf",
  1410. "https://il.ax",
  1411. "https://piped.projectsegfau.lt",
  1412. "https://pd.vern.cc",
  1413. "https://piped.privacydev.net",
  1414. "https://piped.chauvet.pro",
  1415. "https://piped.smnz.de",
  1416. "https://piped.adminforge.de",
  1417. "https://srv.piped.video",
  1418. "https://piped.lunar.icu",
  1419. "https://piped.garudalinux.org",
  1420. "https://piped.in.projectsegfau.lt",
  1421. "https://piped.mha.fi",
  1422. "https://piped.privacy.com.de",
  1423. "https://piped.us.projectsegfau.lt",
  1424. "https://watch.leptons.xyz",
  1425. "https://piped.palveluntarjoaja.eu"
  1426. ],
  1427. "i2p": [],
  1428. "loki": [],
  1429. "tor": [],
  1430. "yggdrasil": []
  1431. },
  1432. "priviblur": {
  1433. "clearnet": [
  1434. "https://tb.opnxng.com",
  1435. // "https://pb.bloat.cat"
  1436. ],
  1437. "i2p": [],
  1438. "loki": [],
  1439. "tor": [],
  1440. "yggdrasil": []
  1441. },
  1442. "pixivfe": {
  1443. "clearnet": [
  1444. "https://pixiv.ducks.party",
  1445. "https://pixiv.perennialte.ch",
  1446. "https://pixivfe.ducks.party",
  1447. "https://pixivfe.exozy.me"
  1448. ],
  1449. "i2p": [],
  1450. "loki": [],
  1451. "tor": [],
  1452. "yggdrasil": []
  1453. },
  1454. "poketube": {
  1455. "clearnet": [
  1456. "https://poketube.fun",
  1457. // "https://pt.zzls.xyz"
  1458. ],
  1459. "i2p": [],
  1460. "loki": [],
  1461. "tor": [],
  1462. "yggdrasil": []
  1463. },
  1464. "proxigram": {
  1465. "clearnet": [
  1466. "https://ig.opnxng.com",
  1467. "https://proxigram.lunar.icu",
  1468. "https://proxigram.ducks.party",
  1469. // "https://ig.vern.cc/",
  1470. // "https://proxigram.vern.cc",
  1471. // "https://instagram.vern.cc",
  1472. // "https://proxigram.privacyredirect.com",
  1473. // "https://proxigram.kyun.li"
  1474. ],
  1475. "i2p": [],
  1476. "loki": [],
  1477. "tor": [],
  1478. "yggdrasil": []
  1479. },
  1480. "proxitok": {
  1481. "clearnet": [
  1482. "https://proxitok.lunar.icu",
  1483. "https://tik.hostux.net",
  1484. "https://proxitok.pabloferreiro.es",
  1485. "https://proxitok.privacy.com.de",
  1486. "https://tok.adminforge.de",
  1487. "https://tok.habedieeh.re",
  1488. "https://proxitok.pussthecat.org",
  1489. "https://cringe.whatever.social",
  1490. "https://proxitok.privacydev.net",
  1491. "https://proxitok.pufe.org",
  1492. "https://cringe.datura.network",
  1493. "https://tok.artemislena.eu",
  1494. // "https://tok.thekitty.zone",
  1495. "https://proxitok.privacyredirect.com",
  1496. "https://tiktok.chauvet.pro",
  1497. // "https://proxitok.r4fo.com",
  1498. "https://tt.vern.cc",
  1499. "https://tiktok.vern.cc",
  1500. "https://proxitok.vern.cc"
  1501. ],
  1502. "i2p": [
  1503. "http://qr.vern.i2p"
  1504. ],
  1505. "loki": [],
  1506. "tor": [],
  1507. "yggdrasil": []
  1508. },
  1509. "quetre": {
  1510. "clearnet": [
  1511. "https://quetre.privacydev.net",
  1512. "https://quetre.pufe.org",
  1513. "https://que.wilbvr.me",
  1514. "https://quetre.iket.me",
  1515. "https://quetre.pussthecat.org",
  1516. "https://quetre.ducks.party",
  1517. "https://quetre.perennialte.ch",
  1518. "https://quetre.projectsegfau.lt",
  1519. "https://quetre.marcopisco.com",
  1520. "https://quetre.blackdrgn.nl",
  1521. "https://quetre.lunar.icu",
  1522. "https://quora.femboy.hu",
  1523. "https://quora.vern.cc",
  1524. // "https://quetre.fascinated.cc",
  1525. "https://quetre.rootdo.com"
  1526. ],
  1527. "i2p": [],
  1528. "loki": [],
  1529. "tor": [
  1530. "http://ask.habeehrhadazsw3izbrbilqajalfyqqln54mrja3iwpqxgcuxnus7eid.onion",
  1531. "http://qr.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion",
  1532. "http://quetre.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  1533. "http://quetre.g4c3eya4clenolymqbpgwz3q3tawoxw56yhzk4vugqrl6dtu3ejvhjid.onion",
  1534. "http://quora.cepyxplublbyw2f4axy4pyztfbxmf63lrt2c7uwv6wl4iixz53czload.onion"
  1535. ],
  1536. "yggdrasil": []
  1537. },
  1538. "redlib": {
  1539. "clearnet": [
  1540. "https://redlib.tiekoetter.com",
  1541. "https://redlib.nadeko.net",
  1542. "https://redlib.incogniweb.net",
  1543. "https://discuss.whatever.social",
  1544. "https://libreddit.bus-hit.me",
  1545. "https://l.opnxng.com",
  1546. "https://red.arancia.click",
  1547. "https://red.ngn.tf",
  1548. "https://redlib.mint.lgbt",
  1549. "https://reddit.invak.id",
  1550. "https://r.darrennathanael.com",
  1551. "https://red.artemislena.eu",
  1552. "https://reddit.owo.si",
  1553. "https://safereddit.com",
  1554. "https://lr.n8pjl.ca",
  1555. "https://libreddit.projectsegfau.lt",
  1556. "https://redlib.kittywi.re",
  1557. "https://redlib.privacyredirect.com",
  1558. // "https://redlib.vimmer.dev",
  1559. "https://redlib.catsarch.com",
  1560. "https://redlib.matthew.science",
  1561. "https://redlib.pussthecat.org/",
  1562. "https://redlib.tux.pizza",
  1563. "https://reddit.idevicehacked.com",
  1564. "https://redlib.private.coffee",
  1565. "https://redlib.ducks.party",
  1566. "https://redlib.reallyaweso.me",
  1567. "https://redlib.perennialte.ch",
  1568. "https://redlib.nohost.network",
  1569. "https://rl.bloat.cat"
  1570. ],
  1571. "i2p": [],
  1572. "loki": [],
  1573. "tor": [],
  1574. "yggdrasil": []
  1575. },
  1576. "rimgo": {
  1577. "clearnet": [
  1578. "https://ri.nadeko.net",
  1579. "https://rimgo.bus-hit.me",
  1580. "https://rimgo.pussthecat.org",
  1581. "https://rimgo.totaldarkness.net",
  1582. "https://rimgo.perennialte.ch",
  1583. "https://img.riverside.rocks",
  1584. "https://rimgo.reallyaweso.me",
  1585. "https://i.bcow.xyz",
  1586. "https://rimgo.hostux.net",
  1587. "https://rimgo.privacyredirect.com",
  1588. "https://ri.zzls.xyz",
  1589. "https://i.habedieeh.re",
  1590. "https://rimgo.ducks.party",
  1591. "https://rimgo.vern.cc",
  1592. "https://rimgo.nohost.network",
  1593. "https://imgur.artemislena.eu",
  1594. "https://rimgo.lunar.icu",
  1595. "https://rimgo.kling.gg",
  1596. "https://rimgo.projectsegfau.lt",
  1597. "https://rimgo.catsarch.com",
  1598. // "https://rimgo.fascinated.cc"
  1599. ],
  1600. "i2p": [],
  1601. "loki": [],
  1602. "tor": [],
  1603. "yggdrasil": []
  1604. },
  1605. "ruraldictionary": {
  1606. "clearnet": [
  1607. "https://rd.vern.cc",
  1608. "https://isdoingyour.mom",
  1609. ],
  1610. "i2p": [
  1611. "http://vern5cxiaufqvhv4hu5ypkvw3tiwvuinae4evdbqzrioql6s2sha.b32.i2p"
  1612. ],
  1613. "loki": [],
  1614. "tor": [
  1615. "http://ruraldictionary.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion",
  1616. "http://rd.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  1617. ],
  1618. "yggdrasil": []
  1619. },
  1620. "safetwitch": {
  1621. "clearnet": [
  1622. "https://safetwitch.drgns.space",
  1623. "https://st.ngn.tf",
  1624. "https://safetwitch.ducks.party",
  1625. "https://safetwitch.privacyredirect.com/"
  1626. ],
  1627. "i2p": [],
  1628. "loki": [],
  1629. "tor": [],
  1630. "yggdrasil": []
  1631. },
  1632. "scribe": {
  1633. "clearnet": [
  1634. "https://scribe.nixnet.services",
  1635. "https://scribe.ducks.party",
  1636. "https://scribe.rip",
  1637. "https://scribe.citizen4.eu",
  1638. "https://scribe.reallyaweso.me",
  1639. "https://scribe.froth.zone",
  1640. "https://scribe.privacyredirect.com",
  1641. "https://scribe.bus-hit.me",
  1642. "https://scribe.perennialte.ch",
  1643. "https://sc.vern.cc",
  1644. "https://scribe.manasiwibi.com",
  1645. "https://m.opnxng.com"
  1646. ],
  1647. "i2p": [],
  1648. "loki": [],
  1649. "tor": [],
  1650. "yggdrasil": []
  1651. },
  1652. "searx": {
  1653. "clearnet": [
  1654. "https://searx.namejeff.xyz",
  1655. "https://search.einfachzocken.eu",
  1656. "https://searx.foss.family",
  1657. "https://search.0ut0f.space",
  1658. "https://searx.oakleycord.dev",
  1659. "https://searxng.deliberate.world",
  1660. "https://searx.zaggy.nl",
  1661. "https://search.reallyaweso.me",
  1662. "https://search.incogniweb.net",
  1663. "https://seeks.hsbp.org",
  1664. "https://putin.agency",
  1665. "http://search.homecomputing.fr",
  1666. "https://seeks.okhin.fr",
  1667. "https://searx.arancia.click",
  1668. "https://s3arch.eu",
  1669. "https://search.nerdvpn.de",
  1670. "https://quackquackgo.nl",
  1671. "https://baresearch.org",
  1672. "https://searx.coding4schoki.org",
  1673. "https://searx.netzspielplatz.de",
  1674. "https://searx.perennialte.ch",
  1675. "https://searx.laquadrature.net",
  1676. "https://sx.thatxtreme.dev",
  1677. "https://vibrisse.gatti.ninja",
  1678. "https://search.smnz.de",
  1679. "https://search.sapti.me",
  1680. "https://twinkpad.pl",
  1681. "https://search.demoniak.ch",
  1682. "https://search.rhscz.eu",
  1683. "https://search.nadeko.net",
  1684. "https://searx.oe5tpo.com",
  1685. "https://search.trashserver.net",
  1686. "https://searxng.shreven.org",
  1687. "https://vanderwilhelm.me",
  1688. "https://nogoo.me",
  1689. "https://xo.wtf",
  1690. // "https://search.r4fo.com",
  1691. "https://searx.brihx.fr",
  1692. "https://search.kujiu.org",
  1693. "https://searx.new-admin.net",
  1694. "https://posativ.org/search",
  1695. "https://searx.crazypotato.tk",
  1696. "https://searx.32bitflo.at",
  1697. "https://el-hoyo.net/searx",
  1698. "https://www.privatesearch.io",
  1699. "https://search.jpope.org",
  1700. "https://search.casperlefantom.net",
  1701. "https://search.freezetux.net",
  1702. "https://framabee.org",
  1703. "https://searx.info",
  1704. "https://search.koehn.com",
  1705. "https://searx.fossencdi.org",
  1706. "https://search.jollausers.de",
  1707. "https://blackholeroutercondition.com",
  1708. "https://some.shady.website/search",
  1709. "https://matrix.ac/searx",
  1710. "https://searx.jeanphilippemorvan.info",
  1711. "https://searx.potato.hu",
  1712. "https://www.searx.de",
  1713. "https://searx.me",
  1714. "http://suche.linuxundich.de",
  1715. "https://search.blackit.de",
  1716. "https://suche.elaon.de",
  1717. "https://search.homecomputing.fr",
  1718. "https://trouvons.org",
  1719. "https://tontonroger.org",
  1720. "https://searx.volcanis.me",
  1721. "https://quackquackgo.nl/search",
  1722. "https://search.notoriousdev.com",
  1723. "https://www.ready.pm",
  1724. "https://searx.nulltime.net",
  1725. "https://searx.schrodinger.io",
  1726. "https://searx.drakonix.net",
  1727. "https://searx.aquilenet.fr",
  1728. "https://searx.4ray.co",
  1729. "https://search.azkware.net",
  1730. "https://schrodinger.io",
  1731. // "https://heraut.eu/search",
  1732. "https://searx.ch",
  1733. // "https://rathorian.fr",
  1734. "https://search.biboumail.fr",
  1735. "https://searx.xyz",
  1736. "https://searx.ru",
  1737. "https://searx.dk",
  1738. "https://suche.ftp.sh",
  1739. "https://searx.nogafa.org",
  1740. "https://www.gruble.de",
  1741. "https://search.disroot.org",
  1742. "https://searx.cc",
  1743. "https://www.search404.io",
  1744. "https://searx.org",
  1745. "https://searx.site",
  1746. "https://searx.foo.li",
  1747. "https://searx.mxchange.org",
  1748. "https://searx.darklun.ch",
  1749. "https://searx.blackspot.me",
  1750. "https://searx.decatec.de",
  1751. "https://searx.prvcy.eu",
  1752. "https://searx-anon.duckdns.org",
  1753. "https://searx.sunless.cloud",
  1754. "https://searx.fmac.xyz",
  1755. "https://search.gougeul.org",
  1756. "https://spot.ecloud.global",
  1757. "https://searx.ninja",
  1758. "https://searx.ca",
  1759. "https://searx.bar",
  1760. "https://searx.everdot.org",
  1761. "https://searx.ir",
  1762. "https://searx.be",
  1763. "https://searx.aleteoryx.me",
  1764. "https://searx.tunkki.xyz/searx",
  1765. "https://searx.tuxcloud.net",
  1766. "https://searx.underworld.fr",
  1767. "https://xeek.com",
  1768. "https://serx.cf",
  1769. "https://searxng.ch",
  1770. "https://search.st8.at",
  1771. "https://searx.roughs.ru",
  1772. "https://search.datura.network",
  1773. "https://searxng.online",
  1774. "https://search.im-in.space",
  1775. "https://search.zdechov.net",
  1776. "https://searx.ankha.ac",
  1777. "https://search.ngn.tf",
  1778. "https://searx.feneas.org",
  1779. "https://dynabyte.ca",
  1780. "https://search.in.projectsegfau.lt",
  1781. "https://searx.rasp.fr",
  1782. "https://searx.xkek.net",
  1783. "https://engo.mint.lgbt",
  1784. "https://timdor.noip.me/searx",
  1785. "https://trovu.komun.org",
  1786. "https://haku.ahmia.fi",
  1787. "https://searx.lavatech.top",
  1788. "https://searx.slash-dev.de",
  1789. "https://www.webrats.xyz",
  1790. "https://searx.tiekoetter.com",
  1791. "https://paulgo.io",
  1792. "https://searx.hummel-web.at",
  1793. "https://searx.webheberg.info",
  1794. "https://searx.tux.land",
  1795. "https://searx.gnous.eu",
  1796. "https://jsearch.pw",
  1797. "https://search.antonkling.se",
  1798. "https://searx.tk",
  1799. "https://searx.openhoofd.nl",
  1800. "https://searx.nixnet.services",
  1801. "https://searx.zapashcanon.fr",
  1802. "https://search.ethibox.fr",
  1803. "https://searx.theanonymouse.xyz",
  1804. "https://northboot.xyz",
  1805. "https://swag.pw",
  1806. "https://search.mdosch.de",
  1807. "https://sx.fedi.tech",
  1808. "https://s.zhaocloud.net",
  1809. "https://searx.zackptg5.com",
  1810. "https://searx.mha.fi",
  1811. "https://searx.divided-by-zero.eu",
  1812. "https://metasearch.nl",
  1813. "https://search.snopyta.org",
  1814. "https://searx.roflcopter.fr",
  1815. "https://sx.catgirl.cloud",
  1816. "https://searx.mastodontech.de",
  1817. "https://searx.dresden.network",
  1818. "https://darmarit.org/searx",
  1819. "https://suche.uferwerk.org",
  1820. "https://suche.dasnetzundich.de",
  1821. "https://anon.sx",
  1822. "https://nibblehole.com",
  1823. "https://opengo.nl",
  1824. "https://privatesearch.app",
  1825. "https://procurx.pt",
  1826. "https://recherche.catmargue.org",
  1827. "https://search.076.ne.jp",
  1828. "https://search.anonymize.com",
  1829. "https://search.asynchronousexchange.com",
  1830. "https://search.fedi.life",
  1831. "https://search.stinpriza.org",
  1832. "https://search.trom.tf",
  1833. "https://searx.bissisoft.com",
  1834. "https://searxzh.cn",
  1835. "https://searx.sk",
  1836. "https://searx.nevrlands.de",
  1837. "https://searx.akusov.xyz",
  1838. "https://a.searx.space",
  1839. "https://searx.hardwired.link",
  1840. "https://searx.stuehieyr.com",
  1841. "https://searx.sp-codes.de",
  1842. "https://searx.solusar.de",
  1843. "https://searx.tyil.nl",
  1844. "https://searx.vitanetworks.link",
  1845. "https://searx.zecircle.xyz",
  1846. "https://searx.semipvt.com",
  1847. "https://searx.se",
  1848. "https://searx.sadblog.xyz",
  1849. "https://searx.s1gm4.eu",
  1850. "https://searx.run",
  1851. "https://searx.operationtulip.com",
  1852. "https://searx.pwoss.org",
  1853. "https://searx.gnu.style",
  1854. "https://search.bluelock.org",
  1855. "https://search.jigsaw-security.com",
  1856. "https://www.searxs.eu",
  1857. "https://www.perfectpixel.de/searx",
  1858. "https://wtf.roflcopter.fr/searx",
  1859. "https://searx.thegreenwebfoundation.org",
  1860. "https://search.privacytools.io",
  1861. "https://search.blou.xyz",
  1862. "https://search.kling.gg",
  1863. "https://search.activemail.de",
  1864. "https://searx.al-f.net",
  1865. "https://searx.hsbp.org",
  1866. "https://search.ononoki.org",
  1867. "https://monocles.de",
  1868. "https://search.bka.li",
  1869. "https://searx.puffyan.us",
  1870. "https://searx.pussthecat.org",
  1871. "https://search.bus-hit.me",
  1872. "https://searx.thegpm.org",
  1873. "https://etsi.me",
  1874. "https://search.zzls.xyz",
  1875. "https://opnxng.com",
  1876. "https://searxng.tordenskjold.de",
  1877. "https://searx.alloca.dev",
  1878. // "https://cthd.icu",
  1879. // "https://searx.cthd.icu",
  1880. "https://search.neet.works",
  1881. "https://search.rabbit-company.com",
  1882. "https://searxng.zackptg5.com",
  1883. "https://searx.catfluori.de",
  1884. "https://www.higgssearch.com",
  1885. "https://search.projectsegfau.lt",
  1886. "https://searx.domain.glass",
  1887. "https://recherche.facil.services",
  1888. "https://searx.stemy.me",
  1889. "https://searxng.no-logs.com",
  1890. "https://search.exarius.org",
  1891. "https://priv.au",
  1892. "https://searx.work",
  1893. "https://searx.fi",
  1894. "https://searxng.pavot.ca",
  1895. "https://searx.envs.net",
  1896. "https://searx.simplifiedprivacy.com",
  1897. "https://searx.absturztau.be",
  1898. "https://search.vojkovic.xyz",
  1899. "https://searx.ebnar.xyz",
  1900. "https://searx.jaska.cc",
  1901. "https://search.rootdo.com",
  1902. "https://copp.gg",
  1903. "https://s.mble.dk",
  1904. "https://s.trung.fun",
  1905. "https://search.gcomm.ch",
  1906. "https://search.laksith.dev",
  1907. "https://search.leptons.xyz",
  1908. "https://search.modalogi.com",
  1909. "https://search.rowie.at",
  1910. "https://searx.daetalytica.io",
  1911. "https://searx.zhenyapav.com",
  1912. "https://apps.disroot.org",
  1913. "https://searx.danksquad.org",
  1914. "https://search.privacyredirect.com"
  1915. ],
  1916. "i2p": [
  1917. "http://mqamk4cfykdvhw5kjez2gnvse56gmnqxn7vkvvbuor4k4j2lbbnq.b32.i2p",
  1918. "http://ransack.i2p"
  1919. ],
  1920. "loki": [],
  1921. "tor": [
  1922. "http://eb6w5ctgodhchf3p.onion/searx",
  1923. "http://searchb5a7tmimez.onion",
  1924. "http://7jwxg5rakyfvikpi.onion",
  1925. "http://ulrn6sryqaifefld.onion",
  1926. "http://eb6w5ctgodhchf3p.onion",
  1927. "http://tp7nwuggtryzbla7.onion/searx",
  1928. "http://htk2rvtgj6vv3ppj.onion",
  1929. "http://searx7hcqiogbrhk.onion",
  1930. "http://searx.bsbvtqi5oq2cqzn32zt4cr2f2z2rwots3dq7gmdcnlyqoxko2wx6reqd.onion",
  1931. "http://3afisqjw2rxm6z7mmstyt5rx75qfqrgxnkzftknbp2vhipr2nrmrjdyd.onion",
  1932. "http://searxbgetrkiwxhdwi6svpgh7eotopqyxhbqiokrwzg7dcte44t36kyd.onion",
  1933. "http://suche.xyzco456vwisukfg.onion",
  1934. "http://w5rl6wsd7mzj4bdkbuqvzidet5osdsm5jhg2f7nvfidakfq5exda5wid.onion",
  1935. "http://z34ambyi6makk6ta7ksog2sljly2ctt2sa3apekb7wkllk72sxecdtad.onion",
  1936. "http://search.4bkxscubgtxwvhpe.onion",
  1937. "http://juy4e6eicawzdrz7.onion",
  1938. "http://z5vawdol25vrmorm4yydmohsd4u6rdoj2sylvoi3e3nqvxkvpqul7bqd.onion",
  1939. "http://zbuc3bbzbfdqqo2x46repx2ddajbha6fpsjeeptjhhhhzji3zopxdqyd.onion",
  1940. "http://4n53nafyi77iplnbrpmxnp3x4exbswwxigujaxy3b37fvr7bvlopxeyd.onion",
  1941. "http://f4qfqajszpx5b7itzxt6mb7kj4ktpgbdq7lq6xaiqyqx6a7de3epptad.onion",
  1942. "http://searx.cwuzdtzlubq5uual.onion",
  1943. "http://searx3aolosaf3urwnhpynlhuokqsgz47si4pzz5hvb7uuzyjncl2tid.onion",
  1944. "http://rq2w52kyrif3xpfihkgjnhqm3a5aqhoikpv72z3drpjglfzc2wr5z4yd.onion",
  1945. "http://yra4tke2pwcnatxjkufpw6kvebu3h3ti2jca2lcdpgx3mpwol326lzid.onion"
  1946. ],
  1947. "yggdrasil": []
  1948. },
  1949. "shoelace": {
  1950. "clearnet": [
  1951. "https://shoelace.mint.lgbt",
  1952. ],
  1953. "i2p": [],
  1954. "loki": [],
  1955. "tor": [],
  1956. "yggdrasil": []
  1957. },
  1958. "simplytranslate": {
  1959. "clearnet": [
  1960. "https://manerakai.asuscomm.com:447",
  1961. "https://simplytranslate.org",
  1962. "https://simplytranslate.reallyaweso.me",
  1963. "https://translate.northboot.xyz",
  1964. "https://simplytranslate.leemoon.network",
  1965. "https://st.privacydev.net",
  1966. "https://tl.vern.cc",
  1967. ],
  1968. "i2p": [],
  1969. "loki": [],
  1970. "tor": [],
  1971. "yggdrasil": []
  1972. },
  1973. "libretranslate": {
  1974. "clearnet": [
  1975. "https://translate.reallyaweso.me"
  1976. ],
  1977. "i2p": [],
  1978. "loki": [],
  1979. "tor": [],
  1980. "yggdrasil": []
  1981. },
  1982. "spot": {
  1983. "clearnet": [
  1984. "https://search.ggc-project.de"
  1985. ],
  1986. "i2p": [],
  1987. "loki": [],
  1988. "tor": [],
  1989. "yggdrasil": []
  1990. },
  1991. "teddit": {
  1992. "clearnet": [
  1993. "https://incogsnoo.com",
  1994. "https://i.opnxng.com",
  1995. "https://teddit.projectsegfau.lt",
  1996. ],
  1997. "i2p": [
  1998. "http://k62ptris7p72aborr4zoanee7xai6wguucveptwgxs5vbgt7qzpq.b32.i2p",
  1999. "http://teddit.i2p"
  2000. ],
  2001. "loki": [],
  2002. "tor": [
  2003. "http://t.sneed4fmhevap3ci4xhf4wgkf72lwk275lcgomnfgwniwmqvaxyluuid.onion",
  2004. "http://tedditfyn6idalzso5wam5qd3kdtxoljjhbrbbx34q2xkcisvshuytad.onion"
  2005. ],
  2006. "yggdrasil": [
  2007. "http://[200:5e4b:515c:e42b:3e73:6fbf:2f11:779d]"
  2008. ]
  2009. },
  2010. "tent": {
  2011. "clearnet": [
  2012. "https://tent.sny.sh",
  2013. ],
  2014. "i2p": [],
  2015. "loki": [],
  2016. "tor": [],
  2017. "yggdrasil": []
  2018. },
  2019. "uso": {
  2020. "clearnet": [
  2021. "https://userscripts-mirror.org"
  2022. ],
  2023. "i2p": [],
  2024. "loki": [],
  2025. "tor": [],
  2026. "yggdrasil": []
  2027. },
  2028. "wayback-classic": {
  2029. "clearnet": [
  2030. "https://wayback-classic.net",
  2031. ],
  2032. "i2p": [],
  2033. "loki": [],
  2034. "tor": [
  2035. "http://waybackclassic.esmail5pdn24shtvieloeedh7ehz3nrwcdivnfhfcedl7gf4kwddhkqd.onion"
  2036. ],
  2037. "yggdrasil": []
  2038. },
  2039. "whoogle": {
  2040. "clearnet": [
  2041. "https://search.sethforprivacy.com",
  2042. "https://wg.vern.cc",
  2043. ],
  2044. "i2p": [
  2045. "http://verneks7rfjptpz5fpii7n7nrxilsidi2qxepeuuf66c3tsf4nhq.b32.i2p"
  2046. ],
  2047. "loki": [],
  2048. "tor": [
  2049. "http://nuifgsnbb2mcyza74o7illtqmuaqbwu4flam3cdmsrnudwcmkqur37qd.onion",
  2050. "http://whoglqjdkgt2an4tdepberwqz3hk7tjo4kqgdnuj77rt7nshw2xqhqad.onion",
  2051. "http://whoogle.g4c3eya4clenolymqbpgwz3q3tawoxw56yhzk4vugqrl6dtu3ejvhjid.onion",
  2052. "http://whoogle.vernccvbvyi5qhfzyqengccj7lkove6bjot2xhh5kajhwvidqafczrad.onion"
  2053. ],
  2054. "yggdrasil": []
  2055. },
  2056. "wikiless": {
  2057. "clearnet": [
  2058. "https://wikiless.org",
  2059. "https://wikiless.tiekoetter.com",
  2060. "https://wiki.adminforge.de",
  2061. "https://wl.vern.cc",
  2062. "https://w.sneed.network",
  2063. "https://wiki.froth.zone",
  2064. "https://wikiless.lunar.icu",
  2065. "https://wikiless.northboot.xyz",
  2066. // "https://wikiless.rootdo.com",
  2067. ],
  2068. "i2p": [
  2069. "http://wikiless.i2p"
  2070. ],
  2071. "loki": [],
  2072. "tor": [
  2073. "http://dj2tbh2nqfxyfmvq33cjmhuw7nb6am7thzd3zsjvizeqf374fixbrxyd.onion",
  2074. "http://w.sneed4fmhevap3ci4xhf4wgkf72lwk275lcgomnfgwniwmqvaxyluuid.onion"
  2075. ],
  2076. "yggdrasil": []
  2077. },
  2078. "wikiless-dark": {
  2079. "clearnet": [
  2080. "https://wikiless.reallyaweso.me",
  2081. "https://wiki.owo.si",
  2082. "https://wikiless.privacyredirect.com",
  2083. "https://wikiless.funami.tech"
  2084. ],
  2085. "i2p": [
  2086. "http://wikiless.i2p"
  2087. ],
  2088. "loki": [],
  2089. "tor": [
  2090. "http://dj2tbh2nqfxyfmvq33cjmhuw7nb6am7thzd3zsjvizeqf374fixbrxyd.onion",
  2091. "http://w.sneed4fmhevap3ci4xhf4wgkf72lwk275lcgomnfgwniwmqvaxyluuid.onion"
  2092. ],
  2093. "yggdrasil": []
  2094. },
  2095. "everybodywiki": {
  2096. "clearnet": [
  2097. "https://everybodywiki.com"
  2098. ],
  2099. "i2p": [],
  2100. "loki": [],
  2101. "tor": [],
  2102. "yggdrasil": []
  2103. },
  2104. "wikiwand": {
  2105. "clearnet": [
  2106. "https://www.wikiwand.com"
  2107. ],
  2108. "i2p": [],
  2109. "loki": [],
  2110. "tor": [],
  2111. "yggdrasil": []
  2112. },
  2113. "yacy": {
  2114. "clearnet": [
  2115. "https://search.cdev.nexus",
  2116. "https://yacy.iko.soy",
  2117. ],
  2118. "i2p": [
  2119. "http://1search.i2p"
  2120. ],
  2121. "loki": [],
  2122. "tor": [
  2123. "http://yacy.bsbvtqi5oq2cqzn32zt4cr2f2z2rwots3dq7gmdcnlyqoxko2wx6reqd.onion"
  2124. ],
  2125. "yggdrasil": []
  2126. }
  2127. };
  2128.  
  2129. sessionDisableProxyRedirect = sessionStorage.getItem('disableProxyRedirect');
  2130. if (sessionDisableProxyRedirect == 'true') {
  2131. window.addEventListener('load', function() {
  2132. let spanElement = document.createElement('span');
  2133. document.body.prepend(spanElement);
  2134. document.body.style.marginTop = '50px';
  2135. spanElement.innerHTML = '🥸 Proxy Redirect Userscript for Greasemonkey is disabled. Click to enable it.';
  2136. spanElement.style.background = 'powderblue'; // '#e0e8f6'; // '#f1f1f1';
  2137. spanElement.style.color = '#000';
  2138. spanElement.style.cursor = 'pointer';
  2139. spanElement.style.direction = 'ltr';
  2140. spanElement.style.display = 'block';
  2141. //spanElement.style.fontWeight = 'bold';
  2142. spanElement.style.lineHeight = '30px';
  2143. //spanElement.style.marginBottom = '50px';
  2144. spanElement.style.textAlign = 'center';
  2145. spanElement.style.userSelect = 'none';
  2146. spanElement.style.position = 'fixed';
  2147. spanElement.style.top = '0';
  2148. spanElement.style.right = '0';
  2149. spanElement.style.left = '0';
  2150. spanElement.style.zIndex = '1000000';
  2151. spanElement.onclick = () => {
  2152. sessionStorage.removeItem('disableProxyRedirect');
  2153. location.reload();
  2154. };
  2155. });
  2156. return;
  2157. };
  2158.  
  2159. function pageLoader(newUrl) {
  2160. //window.onprogress = (event) => {
  2161. // /questions/6464592/how-to-align-entire-html-body-to-the-center
  2162. const loadPage = '<html xmlns="http://www.w3.org/1999/xhtml" style="display:table;margin:auto;"><head><link type="image/svg+xml" rel="shortcut icon" href="data:image/svg+xml,&lt;svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22&gt; &lt;text y=%22.9em%22 font-size=%2290%22&gt;&#x1F978;&lt;/text&gt; &lt;/svg&gt;"/><title>Proxy Redirect</title></head><body style="padding:1em;display:table-cell;height:100%;background-color:#f1f1f1;font-family:system-ui;cursor:default;user-select:none;max-height:100%;max-width:100%;"><dl><dt><h1>&#x1F978; Proxy Redirect</h1></dt><dd><h2>The request is being redirected to a privacy proxy frontend.</h2><div id="message"><h3 style="color:#0000ff;">Redirecting...</h3></div><div>Made for <a href="https://falkon.org">Falkon</a></div></dd></dl></body></html>';
  2163. const domParser = new DOMParser();
  2164. const newDocument = domParser.parseFromString(loadPage, 'text/html');
  2165. //newDocument.querySelector('#icon-tc').onclick = () => {disable()}; // FIXME
  2166. //newDocument.querySelector('#icon-tc').addEventListener("click", disable, false);
  2167. const insertDocument = document.importNode(newDocument.documentElement, true);
  2168. const removeDocument = document.documentElement;
  2169. document.replaceChild(insertDocument, removeDocument);
  2170. let div = document.querySelector('#message');
  2171. if (div) {
  2172. div.innerHTML = `<h4>Proceeding to a privacy proxy frontend at <a href="${newUrl}" style="color:#7a7a7a;">${newUrl.hostname}</a></h4>`;
  2173. //div.onclick = () => {location.href = newUrl};
  2174. } else {
  2175. location.href = 'https://greasyfork.org/scripts/465936-proxy-redirect?autoredirect';
  2176. }
  2177. }
  2178.  
  2179. function noRespond(url, newUrl) {
  2180. let div = document.querySelector('#message');
  2181. div.innerHTML = `<h3>If the redirection does not occur automatically, then <a href="${newUrl}">click here</a>.</h3><h3>A third-party service is utilized to handle this redirection.</h3><h3>Redirecting within three seconds...</h3><hr/><h3>🐵 Greasemonkey requires your attention!</h3><h4 style="color:#ff0000;">Proxy list appears to be out of date or API GM.xmlHttpRequest is missing.</h4><ul><li><h4>Update your <a href="https://greasyfork.org/scripts/465936-proxy-redirect">Proxy Redirect</a> installation; or</h4></li><li><h4>Proceed to the <span id="disable-proxy-redirect"><u>original page</u></span>.</h4></li></ul><div>Powered by <a href="https://farside.link">Far Side</a></div><br/>`;
  2182. document.querySelector('#disable-proxy-redirect').onclick = () => {
  2183. sessionStorage.setItem('disableProxyRedirect', 'true');
  2184. location.reload();
  2185. };
  2186. }
  2187.  
  2188. // FIXME
  2189. // /questions/1397329/how-to-remove-the-hash-from-window-location-url-with-javascript-without-page-r
  2190. function disable() {
  2191. window.location.href =
  2192. window.location.href.substr(
  2193. 0,
  2194. window.location.href.indexOf('#'))
  2195. + '#noredirect';
  2196. }
  2197.  
  2198. /*
  2199. loop = setInterval(function() {
  2200. //modifyURL(location.href);
  2201. window.open(newURL,'_self');
  2202. //location.href = newURL;
  2203. console.info('Redirecting to ' + newURL);
  2204. clearInterval(loop);
  2205. }, 1000);
  2206. */
  2207.  
  2208. /*
  2209. function modifyURL() {
  2210. inst = pickURL();
  2211. // make function synchronous
  2212. // /questions/8778267/synchronous-gm-xmlhttprequest-acting-asynchronously
  2213. stat = statRES(inst);
  2214. if (stat.match(200)) {
  2215. newURL = settURL();
  2216. } else {
  2217. pickURL(url);
  2218. }
  2219. return newURL;
  2220. }
  2221. */
  2222.  
  2223. //(window.onload = alert()
  2224.  
  2225. // TODO Nested elements (i.e. element "a" inside another element)
  2226. // See "else if e.target.hasChildNodes()"
  2227.  
  2228. (function addEventListeners() {
  2229. document.addEventListener("DOMContentLoaded",
  2230. function() {
  2231. for (linkElement of document.links) {
  2232. // mouseover works with keyboard too
  2233. linkElement.addEventListener("mouseover",
  2234. async function(e) {
  2235. if (e.target && e.target.nodeName == "A") {
  2236. hyperLink = e.target;
  2237. await xhrHyperLink(hyperLink);
  2238. } // else if e.target.hasChildNodes()
  2239. },
  2240. {
  2241. once: true
  2242. }
  2243. );
  2244. }
  2245. }
  2246. );
  2247. })();
  2248.  
  2249. function linkOnError(node) {
  2250. node.style.color = 'orange';
  2251. node.style.fontStyle = 'italic';
  2252. node.title = 'Proxy state check was not possible. Please refresh and try again in case the offered page is offline.';
  2253. }
  2254.  
  2255. function linkOnFail(node) {
  2256. node.style.color = 'red';
  2257. node.style.fontStyle = 'italic';
  2258. node.title = 'No proxy was found. Utilizing Farside to intermediate proxy.';
  2259. }
  2260.  
  2261. function linkOnProgress(node) {
  2262. node.style.color = 'aquamarine';
  2263. node.title = 'Looking up for online proxy... Please wait.';
  2264. }
  2265.  
  2266. function linkOnSuccess(node) {
  2267. text = node.textContent
  2268. node.textContent = `🥸 ${text}`; // TODO enable once removeEventListener is solved.
  2269. node.title = 'Proxy link has been found!';
  2270. //node.removeAttribute('title');
  2271. node.style.color = 'forestgreen'; // TODO remove once removeEventListener is solved.
  2272. node.style.fontWeight = 'bold'; // TODO remove once removeEventListener is solved.
  2273. //node.removeAttribute('style'); // TODO enable once removeEventListener is solved.
  2274. }
  2275.  
  2276. function isValid(url, node) {
  2277. try {
  2278. url = new URL(url);
  2279. } catch (err) {
  2280. return;
  2281. }
  2282. let hostName = url.hostname;
  2283. let pathName = url.pathname;
  2284. // check by excluded
  2285. for (let i = 0; i < urlsMatchers.exclude.length; i++) {
  2286. //if (hostName.endsWith(urlsMatchers.exclude[i].host)) {
  2287. //if (hostName.match(urlsMatchers.exclude[i].host)) {
  2288. if (hostName == urlsMatchers.exclude[i].host ||
  2289. hostName == 'www.' + urlsMatchers.exclude[i].host) {
  2290. for (let j = 0; j < urlsMatchers.exclude[i].path.length; j++) {
  2291. if (pathName.includes('/' + urlsMatchers.exclude[i].path[j])) {
  2292. return 0; // exit further check
  2293. }
  2294. }
  2295. if (node) {
  2296. let text = node.outerText;
  2297. if (urlsMatchers.exclude[i].text) {
  2298. for (let j = 0; j < urlsMatchers.exclude[i].text.length; j++) {
  2299. if (text.match(urlsMatchers.exclude[i].text[j])) {
  2300. return 0; // exit further check
  2301. }
  2302. }
  2303. }
  2304. }
  2305. }
  2306. }
  2307. // continue to includeByHostname
  2308. for (let i = 0; i < urlsMatchers.includeByHostname.length; i++) {
  2309. // perhaps use 'match' and create a new object.array for domains with multiple subdomains
  2310. if (hostName == urlsMatchers.includeByHostname[i].host ||
  2311. hostName == 'www.' + urlsMatchers.includeByHostname[i].host) {
  2312. //if (hostName.endsWith(urlsMatchers.includeByHostname[i].host)) {
  2313. return 1;
  2314. }
  2315. }
  2316. // continue to specific
  2317. for (let i = 0; i < urlsMatchers.includeByPathname.length; i++) {
  2318. if (hostName.endsWith(urlsMatchers.includeByPathname[i].host)) {
  2319. for (let j = 0; j < urlsMatchers.includeByPathname[i].path.length; j++) {
  2320. if (pathName.startsWith('/' + urlsMatchers.includeByPathname[i].path[j])) {
  2321. return 1;
  2322. }
  2323. }
  2324. }
  2325. }
  2326. // continue to second-level-domain
  2327. for (let i = 0; i < urlsMatchers.includeBySLD.length; i++) {
  2328. partedHost = hostName.split('.');
  2329. partedHost.shift();
  2330. if (partedHost.join('.').match(urlsMatchers.includeBySLD[i].host)) {
  2331. //if (partedHost[partedHost.length-2].match(urlsMatchers.includeBySLD[i].host)) {
  2332. return 1;
  2333. }
  2334. }
  2335. // continue to second-level-domain and path
  2336. for (let i = 0; i < urlsMatchers.includeByPathnameAndSLD.length; i++) {
  2337. partedHost = hostName.split('.');
  2338. // TODO Test
  2339. if (partedHost[partedHost.length-2].match(urlsMatchers.includeByPathnameAndSLD[i].host)) {
  2340. for (let j = 0; j < urlsMatchers.includeByPathnameAndSLD[i].path.length; j++) {
  2341. if (pathName.startsWith('/' + urlsMatchers.includeByPathnameAndSLD[i].path[j])) {
  2342. return 1;
  2343. }
  2344. }
  2345. }
  2346. }
  2347. }
  2348.  
  2349. // var caller = (function xhr() {
  2350. async function xhrHyperLink(node) {
  2351. let url = node.href;
  2352. let valid = isValid(url, node);
  2353. if (!valid) {return;}
  2354. //let url = node.href;
  2355. //if (!url) {return;}
  2356. let instanceSelect = await pickInstance(url);
  2357. let result = await pickURL(instanceSelect);
  2358. if (!result) {return;}
  2359. let instanceName = result.name;
  2360. let instanceType = result.type;
  2361. let instanceUrl = result.url;
  2362. if (!url) {return;}
  2363. let newPath = modifyPathname(instanceName, url);
  2364. let newUrl = new URL(instanceUrl + newPath);
  2365. let counter = 0;
  2366.  
  2367. console.log(`
  2368. Setting Proxy to ${instanceName}
  2369. URL: ${newUrl}
  2370. `);
  2371.  
  2372. console.log(`
  2373. URL: ${url}
  2374. Selected: ${instanceUrl}
  2375. Pathname: ${newPath}
  2376. `);
  2377.  
  2378. try {
  2379. gmXmlhttpRequest({
  2380. method: 'GET',
  2381. url: instanceUrl,
  2382. synchronous: true,
  2383. onprogress: linkOnProgress(node),
  2384. onload: async function(response) {
  2385. if (response.finalUrl.startsWith(instanceUrl) && response.status == 200) {
  2386. newPath = modifyPathname(instanceName, url);
  2387. newUrl = new URL(instanceUrl + newPath);
  2388. node.href = newUrl;
  2389. linkOnSuccess(node)
  2390. } else {
  2391. instanceUrlPrint = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  2392. instanceUrlPrint = instanceUrlPrint.replace(/\./g,'-');
  2393. console.warn('Instance URL ' + instanceUrl + ' might be out of service. URL has changed. Please report this to the developer.');
  2394. if (maxAttempts(instanceName, instanceType, counter)) {
  2395. instanceUrl = farSide(instanceName, instanceUrl);
  2396. if (!instanceUrl) {
  2397. instanceObj = await pickURL(instanceName);
  2398. instanceUrl = instanceObj.url;
  2399. }
  2400. newPath = modifyPathname(instanceName, url);
  2401. node.href = new URL(instanceUrl + newPath);
  2402. linkOnFail(node);
  2403. return;
  2404. }
  2405. maxAttempts(instanceName, instanceType, counter);
  2406. xhr();
  2407. }
  2408. },
  2409. onerror: async function(response) {
  2410. instanceUrlPrint = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  2411. instanceUrlPrint = instanceUrlPrint.replace(/\./g,'-');
  2412. console.warn('Instance URL ' + instanceUrl + ' might be offline. Status error: ' + response.status + '. Please report this to the developer.');
  2413. instanceUrl = farSide(instanceName, instanceUrl);
  2414. if (!instanceUrl) {
  2415. instanceObj = await pickURL(instanceName);
  2416. instanceUrl = instanceObj.url;
  2417. }
  2418. newPath = modifyPathname(instanceName, url);
  2419. node.href = new URL(instanceUrl + newPath);
  2420. linkOnError(node);
  2421. if (maxAttempts(instanceName, instanceType, counter)) {
  2422. instanceUrl = farSide(instanceName, instanceUrl);
  2423. if (!instanceUrl) {
  2424. instanceObj = await pickURL(instanceName);
  2425. instanceUrl = instanceObj.url;
  2426. }
  2427. newPath = modifyPathname(instanceName, url);
  2428. node.href = new URL(instanceUrl + newPath);
  2429. linkOnFail(node);
  2430. return;
  2431. }
  2432. maxAttempts(instanceName, instanceType, counter);
  2433. xhr();
  2434. }
  2435. });
  2436. } catch (err) {
  2437. console.warn(err);
  2438. console.info('API GM.xmlHttpRequest does not seem to be available. Defaulting to Farside.link. Contribute your help in C++ to improve Greasemonkey for Falkon https://bugs.kde.org/show_bug.cgi?id=466533');
  2439. //pickURL();
  2440. instanceUrl = farSide(instanceName, instanceUrl);
  2441. if (!instanceUrl) {
  2442. instanceObj = await pickURL(instanceName);
  2443. instanceUrl = instanceObj.url;
  2444. }
  2445. //if ((proxy[instanceName].clearnet).filter(str => str.includes('farside.link')).length) {
  2446. // instanceUrl = (proxy[instanceName].clearnet).filter(str => str.includes('farside.link'))[0];
  2447. //}
  2448. newPath = modifyPathname(instanceName, url);
  2449. node.href = new URL(instanceUrl + newPath);
  2450. }
  2451. }
  2452.  
  2453. // var caller = (function xhr() {
  2454. var init = (async function xhrAddressBar() {
  2455. let url = document.location.href;
  2456. if (!url) {return;}
  2457. let valid = isValid(url);
  2458. if (!valid) {return;}
  2459. let instanceSelect = await pickInstance(url);
  2460. let result = await pickURL(instanceSelect);
  2461. if (!result) {return;}
  2462. let instanceName = result.name;
  2463. let instanceType = result.type;
  2464. let instanceUrl = result.url;
  2465. if (!url) {return;}
  2466. let newPath = modifyPathname(instanceName, url);
  2467. let newUrl = new URL(instanceUrl + newPath);
  2468. let counter = 0;
  2469.  
  2470. console.log(`
  2471. Setting Proxy to ${instanceName}
  2472. URL: ${newUrl}
  2473. `);
  2474.  
  2475. console.log(`
  2476. URL: ${url}
  2477. Selected: ${instanceUrl}
  2478. Pathname: ${newPath}
  2479. `);
  2480.  
  2481. try {
  2482. gmXmlhttpRequest({
  2483. method: 'GET',
  2484. url: instanceUrl,
  2485. synchronous: true,
  2486. onprogress: pageLoader(newUrl),
  2487. onload: async function(response) {
  2488. // FIXME wiki.slipfox.xyz and wikiless.bloatcat.tk are selected albeit none should be selected.
  2489. if (response.finalUrl.startsWith(instanceUrl) && response.status == 200) {
  2490. newPath = modifyPathname(instanceName, url);
  2491. newUrl = new URL(instanceUrl + newPath);
  2492. await wait(3);
  2493. location.href = newUrl;
  2494. } else {
  2495. instanceUrl = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  2496. instanceUrl = instanceUrl.replace(/\./g,'-');
  2497. console.warn('Instance URL ' + instanceUrl + ' might be out of service. URL has changed. Please report this to the developer.');
  2498. if (maxAttempts(instanceName, instanceType, counter)) {
  2499. instanceUrl = farSide(instanceName, instanceUrl);
  2500. if (!instanceUrl) {
  2501. instanceObj = await pickURL(instanceName);
  2502. instanceUrl = instanceObj.url;
  2503. }
  2504. newPath = modifyPathname(instanceName, url);
  2505. newUrl = new URL(instanceUrl + newPath);
  2506. noRespond(url, newUrl);
  2507. await wait(5);
  2508. location.href = newUrl;
  2509. }
  2510. maxAttempts(instanceName, instanceType, counter);
  2511. xhr();
  2512. }
  2513. },
  2514. onerror: async function(response) {
  2515. instanceUrl = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  2516. instanceUrl = instanceUrl.replace(/\./g,'-');
  2517. console.warn('Instance URL ' + instanceUrl + ' might be offline. Status error: ' + response.status + '. Please report this to the developer.');
  2518. if (maxAttempts(instanceName, instanceType, counter)) {
  2519. instanceUrl = farSide(instanceName, instanceUrl);
  2520. if (!instanceUrl) {
  2521. instanceObj = await pickURL(instanceName);
  2522. instanceUrl = instanceObj.url;
  2523. }
  2524. newPath = modifyPathname(instanceName, url);
  2525. newUrl = new URL(instanceUrl + newPath);
  2526. noRespond(url, newUrl);
  2527. await wait(5);
  2528. location.href = newUrl;
  2529. }
  2530. maxAttempts(instanceName, instanceType, counter);
  2531. xhr();
  2532. }
  2533. });
  2534. } catch (err) {
  2535. console.warn(err);
  2536. console.info('API GM.xmlHttpRequest does not seem to be available. Defaulting to Farside.link. Contribute your help in C++ to improve Greasemonkey for Falkon https://bugs.kde.org/show_bug.cgi?id=466533');
  2537. //pickURL();
  2538. instanceUrl = farSide(instanceName, instanceUrl);
  2539. if (!instanceUrl) {
  2540. instanceObj = await pickURL(instanceName);
  2541. instanceUrl = instanceObj.url;
  2542. }
  2543. //if ((proxy[instanceName].clearnet).filter(str => str.includes('farside.link')).length) {
  2544. // instanceUrl = (proxy[instanceName].clearnet).filter(str => str.includes('farside.link'))[0];
  2545. //}
  2546. newPath = modifyPathname(instanceName, url);
  2547. newUrl = new URL(instanceUrl + newPath);
  2548. await wait(3);
  2549. location.href = newUrl;
  2550. }
  2551. })();
  2552.  
  2553. function farSide(instanceName, instanceUrl) {
  2554. switch (instanceName) {
  2555. case '4get':
  2556. instanceUrl = 'https://farside.link/4get';
  2557. break;
  2558. case 'anonymousoverflow':
  2559. instanceUrl = 'https://farside.link/anonymousoverflow';
  2560. break;
  2561. case 'bibliogram':
  2562. instanceUrl = 'https://farside.link/bibliogram';
  2563. break;
  2564. case 'breezewiki':
  2565. instanceUrl = 'https://farside.link/breezewiki';
  2566. break;
  2567. case 'dumb':
  2568. instanceUrl = 'https://farside.link/dumb';
  2569. break;
  2570. case 'gothub':
  2571. instanceUrl = 'https://farside.link/gothub';
  2572. break;
  2573. case 'invidious':
  2574. instanceUrl = 'https://farside.link/invidious';
  2575. break;
  2576. case 'librarian':
  2577. instanceUrl = 'https://farside.link/librarian';
  2578. break;
  2579. case 'libreddit':
  2580. instanceUrl = 'https://farside.link/libreddit';
  2581. break;
  2582. case 'libremdb':
  2583. instanceUrl = 'https://farside.link/libremdb';
  2584. break;
  2585. case 'librex':
  2586. instanceUrl = 'https://farside.link/librex';
  2587. break;
  2588. case 'librey':
  2589. instanceUrl = 'https://farside.link/librey';
  2590. break;
  2591. case 'lingva':
  2592. instanceUrl = 'https://farside.link/lingva';
  2593. break;
  2594. case 'nitter':
  2595. instanceUrl = 'https://farside.link/nitter';
  2596. break;
  2597. case 'piped':
  2598. instanceUrl = 'https://farside.link/piped';
  2599. break;
  2600. case 'proxigram':
  2601. instanceUrl = 'https://farside.link/proxigram';
  2602. break;
  2603. case 'proxitok':
  2604. instanceUrl = 'https://farside.link/proxitok';
  2605. break;
  2606. case 'quetre':
  2607. instanceUrl = 'https://farside.link/quetre';
  2608. break;
  2609. case 'redlib':
  2610. instanceUrl = 'https://farside.link/redlib';
  2611. break;
  2612. case 'rimgo':
  2613. instanceUrl = 'https://farside.link/rimgo';
  2614. break;
  2615. case 'scribe':
  2616. instanceUrl = 'https://farside.link/scribe';
  2617. break;
  2618. case 'searx':
  2619. instanceUrl = 'https://farside.link/searxng';
  2620. break;
  2621. case 'simplytranslate':
  2622. instanceUrl = 'https://farside.link/simplytranslate';
  2623. break;
  2624. case 'teddit':
  2625. instanceUrl = 'https://farside.link/teddit';
  2626. break;
  2627. case 'whoogle':
  2628. instanceUrl = 'https://farside.link/whoogle';
  2629. break;
  2630. case 'wikiless':
  2631. instanceUrl = 'https://farside.link/wikiless';
  2632. break;
  2633. //case 'yacy':
  2634. // instanceUrl = 'https://farside.link/yacy';
  2635. // break;
  2636. default:
  2637. instanceUrl = 0;
  2638. }
  2639. return instanceUrl;
  2640. }
  2641.  
  2642. function maxAttempts(instanceName, instanceType, counter) {
  2643. counter = counter + 1;
  2644. if (counter == proxy[instanceName][instanceType].length) {
  2645. return true;
  2646. } else {
  2647. return counter;
  2648. }
  2649. }
  2650.  
  2651. function setValue(para, sourceURL) {
  2652. if (sourceURL.searchParams.get(para)) {
  2653. para = [para];
  2654. return pickParameters(para, sourceURL);
  2655. } else {
  2656. return 'auto';
  2657. }
  2658. }
  2659.  
  2660. function pickParameters(para, sourceURL) {
  2661. for (let i = 0; i < para.length; i++) {
  2662. if (sourceURL.searchParams.get(para[i])) {
  2663. para = sourceURL.searchParams.get(para[i]);
  2664. sourceURL.searchParams.delete(para[i]);
  2665. return para;
  2666. }
  2667. }
  2668. }
  2669.  
  2670. /*
  2671.  
  2672. FIXME Check whether instance is enabled.
  2673. TODO Do not add instance is is disabled,
  2674. so that the redirector will not halt
  2675. when a disabled instance is chosen.
  2676.  
  2677. */
  2678.  
  2679. async function pickInstance(url) {
  2680.  
  2681. let sourceURL = new URL(url);
  2682. let paras = ['continue', 'retpath'];
  2683.  
  2684. for (let i = 0; i < paras.length; i++) {
  2685. if (sourceURL.searchParams.get(paras[i])) {
  2686. //sourceURL = pickParameters(paras[i], sourceURL);
  2687. sourceURL = sourceURL.searchParams.get(paras[i]);
  2688. sourceURL = new URL(sourceURL);
  2689. }
  2690. }
  2691.  
  2692. let hostname = sourceURL.hostname;
  2693. let pathname = sourceURL.pathname;
  2694. let instanceName;
  2695. let instanceNameArray = [];
  2696.  
  2697. switch (true) {
  2698.  
  2699. case hostname == 'bandcamp.com':
  2700. case hostname == 'www.bandcamp.com':
  2701. case hostname.endsWith('.bandcamp.com'):
  2702. instanceName = 'tent';
  2703. break;
  2704.  
  2705. case hostname == 'bilibili.com':
  2706. case hostname == 'www.bilibili.com':
  2707. case hostname.endsWith('.bilibili.com'):
  2708. instanceName = 'mikuinvidious';
  2709. break;
  2710.  
  2711. //case pathname.startsWith('/magnet/') && (hostname == 'bt4g.org' || hostname == 'www.bt4g.org'):
  2712. //case pathname.startsWith('/magnet/') && hostname == 'bt4gprx.com' || hostname == 'www.bt4gprx.com':
  2713. case pathname.startsWith('/hash/') && hostname == 'downloadtorrentfile.com' || hostname == 'www.downloadtorrentfile.com':
  2714. case hostname == 'torrentdownload.info':
  2715. case hostname == 'www.torrentdownload.info':
  2716. case hostname == 'torrentz.eu':
  2717. case hostname == 'www.torrentz.eu':
  2718. case hostname == 'torrentz.me':
  2719. case hostname == 'www.torrentz.me':
  2720. case hostname == 'torrentz2.is':
  2721. case hostname == 'www.torrentz2.is':
  2722. instanceName = 'btdigg';
  2723. break;
  2724.  
  2725. //case hostname == 'fandom.com':
  2726. //case hostname == 'www.fandom.com':
  2727. case hostname.endsWith('.fandom.com'):
  2728. instanceName = 'breezewiki';
  2729. break;
  2730.  
  2731. case hostname == 'github.com':
  2732. case hostname == 'www.github.com':
  2733. case hostname.endsWith('.github.com'):
  2734. instanceName = 'gothub';
  2735. break;
  2736.  
  2737. case hostname == 'gitlab.com':
  2738. case hostname == 'www.gitlab.com':
  2739. instanceName = 'laboratory';
  2740. break;
  2741.  
  2742. case hostname == 'goodreads.com':
  2743. case hostname == 'www.goodreads.com':
  2744. instanceName = 'biblioreads';
  2745. break;
  2746.  
  2747. // TODO quadkey (mapquest)
  2748. // NOTE quadkeyToTile(quadkey) See /mapbox/tilebelt
  2749. case hostname.endsWith('wikimap.toolforge.org'):
  2750. case (hostname.endsWith('moovitapp.com') &&
  2751. sourceURL.search.includes('tll')):
  2752. case (hostname.endsWith('bing.com') &&
  2753. pathname.startsWith('/maps')):
  2754. case (hostname.includes('google.') &&
  2755. pathname.startsWith('/maps')):
  2756. case (hostname.includes('waze.com') &&
  2757. pathname.startsWith('/live-map')):
  2758. case (hostname.includes('waze.com') &&
  2759. pathname.startsWith('/ul')):
  2760. case (hostname.includes('yandex.') &&
  2761. pathname.startsWith('/maps')):
  2762. instanceNameArray.push('facilmap');
  2763. instanceNameArray.push('openstreetmap');
  2764. break;
  2765.  
  2766. case hostname == 'imdb.com':
  2767. case hostname == 'www.imdb.com':
  2768. instanceName = 'libremdb';
  2769. break;
  2770.  
  2771. case hostname == 'imgur.com':
  2772. case hostname == 'www.imgur.com':
  2773. //instanceNameArray.push('imgin');
  2774. instanceNameArray.push('rimgo');
  2775. break;
  2776.  
  2777. case hostname == 'instructables.com':
  2778. case hostname == 'www.instructables.com':
  2779. instanceNameArray.push('destructables');
  2780. instanceNameArray.push('indestructables');
  2781. break;
  2782.  
  2783. case hostname == 'instagram.com':
  2784. case hostname == 'www.instagram.com':
  2785. //instanceNameArray.push('bibliogram');
  2786. instanceNameArray.push('proxigram');
  2787. break;
  2788.  
  2789. //case hostname == 'medium.com':
  2790. //case hostname == 'www.medium.com':
  2791. case hostname == 'medium.com':
  2792. case hostname == 'www.medium.com':
  2793. case hostname.endsWith('.medium.com'):
  2794. instanceNameArray.push('libmedium');
  2795. instanceNameArray.push('scribe');
  2796. break;
  2797.  
  2798. case hostname == 'odysee.com':
  2799. case hostname == 'www.odysee.com':
  2800. instanceName = 'librarian';
  2801. break;
  2802.  
  2803. case hostname == 'quora.com':
  2804. case hostname == 'www.quora.com':
  2805. instanceName = 'quetre';
  2806. break;
  2807.  
  2808. case hostname == 'reddit.com':
  2809. case hostname == 'old.reddit.com':
  2810. case hostname == 'www.reddit.com':
  2811. case hostname == 'preview.redd.it':
  2812. instanceNameArray.push('libreddit');
  2813. instanceNameArray.push('redlib');
  2814. instanceNameArray.push('teddit');
  2815. break;
  2816.  
  2817. case hostname == 'reuters.com':
  2818. case hostname == 'www.reuters.com':
  2819. instanceName = 'neuters';
  2820. break;
  2821.  
  2822. // FIXME
  2823. case (hostname.startsWith('search.yahoo.')):
  2824. //case (pathname.startsWith('/search')):
  2825. case (hostname.includes('yandex.') &&
  2826. pathname.startsWith('/search')):
  2827. case (hostname.includes('yahoo.') &&
  2828. pathname.startsWith('/search')):
  2829. case (hostname.includes('bing.') &&
  2830. pathname.startsWith('/search')):
  2831. case (hostname.includes('google.') &&
  2832. pathname.startsWith('/search')):
  2833. instanceNameArray.push('4get');
  2834. instanceNameArray.push('librex');
  2835. instanceNameArray.push('librey');
  2836. instanceNameArray.push('lieu');
  2837. instanceNameArray.push('metastem');
  2838. instanceNameArray.push('searx');
  2839. instanceNameArray.push('spot');
  2840. instanceNameArray.push('whoogle');
  2841. break;
  2842.  
  2843. case hostname == 'stackoverflow.com':
  2844. case hostname == 'www.stackoverflow.com':
  2845. instanceName = 'anonymousoverflow';
  2846. break;
  2847.  
  2848. case hostname == 'tiktok.com':
  2849. case hostname == 'www.tiktok.com':
  2850. instanceName = 'proxitok';
  2851. break;
  2852.  
  2853. case (hostname.endsWith('translate.yandex.com')):
  2854. // FIXME website blocks us from redirecting
  2855. // function setTimeout() seems to not work
  2856. // consider different approach/way
  2857. case (hostname.endsWith('translate.google.com')):
  2858. instanceNameArray.push('lingva');
  2859. instanceNameArray.push('simplytranslate');
  2860. break;
  2861.  
  2862. case (hostname.endsWith('.tumblr.com')):
  2863. instanceName = 'priviblur';
  2864. break;
  2865.  
  2866. case hostname == 'twitter.com':
  2867. case hostname == 'www.twitter.com':
  2868. case hostname == 'x.com':
  2869. case hostname == 'www.x.com':
  2870. instanceName = 'nitter';
  2871. break;
  2872.  
  2873. case hostname == 'urbandictionary.com':
  2874. case hostname == 'www.urbandictionary.com':
  2875. instanceName = 'ruraldictionary';
  2876. break;
  2877.  
  2878. case hostname == 'userscripts.org':
  2879. case hostname == 'www.userscripts.org':
  2880. instanceName = 'uso';
  2881. break;
  2882.  
  2883. //case hostname == 'wikipedia.org':
  2884. //case hostname == 'www.wikipedia.org':
  2885. case hostname.endsWith('.wikipedia.org'):
  2886. // instanceNameArray.push('everybodywiki');
  2887. // instanceNameArray.push('metastemwiki');
  2888. instanceNameArray.push('wikiless');
  2889. // instanceNameArray.push('wikiwand');
  2890. break;
  2891.  
  2892. case hostname == 'youtu.be':
  2893. case hostname == 'www.youtu.be':
  2894. case hostname == 'youtube.com':
  2895. case hostname == 'www.youtube.com':
  2896. case hostname == 'youtube-nocookie.com':
  2897. case hostname == 'www.youtube-nocookie.com':
  2898. //case hostname.endsWith('invidious-invidious.invidious.svc.cluster.local:3000'):
  2899. instanceNameArray.push('alltube');
  2900. instanceNameArray.push('cloudtube');
  2901. instanceNameArray.push('invidious');
  2902. instanceNameArray.push('materialious');
  2903. instanceNameArray.push('piped');
  2904. // //instanceNameArray.push('pipedmaterial');
  2905. instanceNameArray.push('poketube');
  2906. instanceNameArray.push('tubo');
  2907. break;
  2908.  
  2909. //default:
  2910. // return target;
  2911.  
  2912. }
  2913.  
  2914. // proxy select
  2915. if (instanceNameArray.length) {
  2916. instanceName = instanceNameArray[Math.floor(Math.random()*instanceNameArray.length)];
  2917. //urlArray = proxyArray[Math.floor(Math.random()*proxyArray.length)];
  2918. }
  2919.  
  2920. return instanceName;
  2921.  
  2922. }
  2923.  
  2924. function removeParameters(sourceURL) {
  2925.  
  2926. switch (sourceURL.hostname) {
  2927. case 'youtube.com':
  2928. case 'www.youtube.com':
  2929. case 'youtube-nocookie.com':
  2930. case 'www.youtube-nocookie.com':
  2931. sourceURL.searchParams.delete('app')
  2932. break;
  2933. }
  2934.  
  2935. return sourceURL;
  2936.  
  2937. }
  2938.  
  2939. // TODO
  2940. // Settle hostname
  2941. function modifyHostname(instanceName, url) {
  2942. let lang, partedHost;
  2943. let sourceURL = new URL(url);
  2944. let hostname = sourceURL.hostname;
  2945.  
  2946. switch (instanceName) {
  2947.  
  2948. case 'everybodywiki':
  2949. // extract language code
  2950. partedHost = hostname.split('.');
  2951. if (partedHost.length === 3 || partedHost.length === 4) {
  2952. lang = partedHost[0];
  2953. }
  2954. newHostname = `${lang}.everybodywiki.com`;
  2955. sourceURL.hostname = newHostname;
  2956. break;
  2957.  
  2958. }
  2959.  
  2960. return sourceURL;
  2961.  
  2962. }
  2963.  
  2964. // Settle pathname
  2965. function modifyPathname(instanceName, url) {
  2966. let brand, lang, name, newPath, para, partedHost;
  2967. let sourceURL = new URL(url);
  2968. //url = removeParameters(sourceURL);
  2969. let pathname = sourceURL.pathname;
  2970. let hostname = sourceURL.hostname;
  2971. //let parameter = sourceURL.searchParams;
  2972.  
  2973. switch (instanceName) {
  2974.  
  2975. // NOTE This "case" is not required albeit it makes the URL more clear
  2976. case 'alltube':
  2977. cleansedUrl = removeParameters(sourceURL);
  2978. newPath = `/info?url=${cleansedUrl}`;
  2979. break;
  2980.  
  2981. // consider function setTimeout()
  2982. case 'bibliogram':
  2983. if (!pathname.includes('accounts/login')) {
  2984. newPath = `/u/${para}`;
  2985. } else {
  2986. if (sourceURL.searchParams.get('next')) {
  2987. para = ['next'];
  2988. para = pickParameters(para, sourceURL);
  2989. newPath = `/u/${para}`;
  2990. }
  2991. }
  2992. break;
  2993.  
  2994. case 'breezewiki':
  2995. // extract wiki name
  2996. partedHost = hostname.split('.');
  2997. if (partedHost.length === 3 || partedHost.length === 4) {
  2998. brand = partedHost[0];
  2999. }
  3000. newPath = `/${brand}${pathname}`;
  3001. break;
  3002.  
  3003. case 'btdigg':
  3004. // extract sha1sum
  3005. //hash = pathname.split('/')[2];
  3006. let hash = pathname.split('/');
  3007. for (let i = 0; i < hash.length; i++) {
  3008. if (hash[i].length === 40 || hash[i].length === 33) {
  3009. hash = hash[i];
  3010. break;
  3011. }
  3012. }
  3013. newPath = `/${hash}`;
  3014. break;
  3015.  
  3016. case 'cloudtube':
  3017. case 'invidious':
  3018. case 'piped':
  3019. case 'pipedmaterial':
  3020. case 'poketube':
  3021. if (sourceURL.searchParams.get('v')) {
  3022. para = ['v'];
  3023. para = pickParameters(para, sourceURL);
  3024. newPath = `/watch?v=${para}`;
  3025. }
  3026. break;
  3027.  
  3028. case 'libreddit':
  3029. case 'redlib':
  3030. case 'teddit':
  3031. let newPathPart;
  3032. if (instanceName == 'teddit') {
  3033. newPathPart = '/pics/w:null_';
  3034. } else {
  3035. newPathPart = '/img/';
  3036. }
  3037. if (hostname == 'preview.redd.it') {
  3038. newPath = `${newPathPart}${pathname}`;
  3039. } else
  3040. if (hostname.endsWith('reddit.com') && pathname == '/media' && sourceURL.searchParams.get('url')) {
  3041. let extractedURL = new URL(sourceURL.searchParams.get('url'))
  3042. if (extractedURL.hostname == 'preview.redd.it') {
  3043. extractedPathname = extractedURL.pathname.split('-').pop();
  3044. extractedPathname = extractedPathname.replace('/','');
  3045. newPath = `${newPathPart}${extractedPathname}`;
  3046. }
  3047. }
  3048. break;
  3049.  
  3050. case 'gothub':
  3051. if (hostname.endsWith('gist.github.com')) {
  3052. newPath = `/gist${pathname}`;
  3053. }
  3054. break;
  3055.  
  3056. case 'laboratory':
  3057. newPath = '/' + hostname + pathname;
  3058. break;
  3059.  
  3060. // case 'libmedium':
  3061. //partedHost = hostname.split('.');
  3062. //if (partedHost.length === 3 || partedHost.length === 4) {
  3063. // name = partedHost[0];
  3064. //}
  3065. //newPath = `/@${name}${pathname}`;
  3066. // newPath = pathname;
  3067. // break;
  3068.  
  3069. case 'librex':
  3070. case 'metastem':
  3071. case 'spot':
  3072. // extract search parameter
  3073. para = ['q', 'text', 'p'];
  3074. para = pickParameters(para, sourceURL);
  3075. newPath = `/search.php?q=${para}`;
  3076. break;
  3077.  
  3078. case 'lingva':
  3079. // extract text parameter
  3080. let paras = ['sl', 'tl', 'text'];
  3081.  
  3082. for (let i = 0; i < paras.length; i++) {
  3083. paras[i] = setValue(paras[i], sourceURL);
  3084. }
  3085.  
  3086. //if (paras[2] === 'auto') { paras[2] = ''; }
  3087.  
  3088. if ((paras[0] == 'auto') && (paras[1] == 'auto')) {
  3089. newPath = `/${paras[2]}`;
  3090. } else {
  3091. newPath = `/${paras[0]}/${paras[1]}/${paras[2]}`;
  3092. }
  3093. break;
  3094.  
  3095. case 'facilmap':
  3096. case 'openstreetmap':
  3097. // extract coordinations
  3098. /*
  3099. if (pathname.includes('@')) {
  3100. cord = pathname.split('/')[2].split('&')[0].slice(1);
  3101. cord = cord.split(',');
  3102. }
  3103. newPath = '/#map=' + cord[2].slice(0, 1) +
  3104. '/' + cord[0] + '/' + cord[1];
  3105. */
  3106. let cord, lat, lon, zoom;
  3107. // extract coordinations
  3108. if (sourceURL.search.includes('%7E')) { // %7E is ~
  3109. para = ['cp'];
  3110. cord = pickParameters(para, sourceURL);
  3111. cord = cord.split('~');
  3112. para = ['lvl'];
  3113. zoom = pickParameters(para, sourceURL);
  3114. lat = cord[0];
  3115. lon = cord[1];
  3116. } else
  3117. if (sourceURL.search.includes('to')) {
  3118. para = ['to'];
  3119. cord = pickParameters(para, sourceURL);
  3120. cord = cord.slice(3).split(',');
  3121. lat = cord[0];
  3122. lon = cord[1];
  3123. } else
  3124. if (pathname.includes('ul') &&
  3125. sourceURL.search.includes('ll')) {
  3126. para = ['ll'];
  3127. cord = pickParameters(para, sourceURL);
  3128. cord = cord.split(',');
  3129. para = ['zoom'];
  3130. zoom = pickParameters(para, sourceURL);
  3131. lat = cord[0];
  3132. lon = cord[1];
  3133. } else
  3134. if (sourceURL.search.includes('ll')) {
  3135. para = ['ll'];
  3136. cord = pickParameters(para, sourceURL);
  3137. cord = cord.split(',');
  3138. para = ['z'];
  3139. zoom = pickParameters(para, sourceURL);
  3140. lat = cord[0];
  3141. lon = cord[1];
  3142. } else
  3143. if (sourceURL.search.includes('tll')) {
  3144. para = ['tll'];
  3145. cord = pickParameters(para, sourceURL);
  3146. cord = cord.split('_');
  3147. lat = cord[0];
  3148. lon = cord[1];
  3149. } else
  3150. if (pathname.includes('@')) {
  3151. partedPath = pathname.split('/')
  3152. for (let i = 0; i < partedPath.length; i++) {
  3153. if (partedPath[i].startsWith('@')) {
  3154. cord = partedPath[i].split(',');
  3155. }
  3156. }
  3157. lat = cord[0].slice(1);
  3158. lon = cord[1];
  3159. zoom = cord[2];
  3160. //newPath = `/#map=${cord[2].slice(0, 2)}/${cord[0].slice(1)}/${cord[1]}`;
  3161. //newPath = `/#map=${cord[2]}/${cord[0].slice(1)}/${cord[1]}`;
  3162. //newPath = `/#${cord[2]}/${cord[0].slice(1)}/${cord[1]}/`;
  3163. }
  3164.  
  3165. if (lat && lon && zoom) {
  3166. newPath = `/#${zoom}/${lat}/${lon}/`;
  3167. } else
  3168. if (lat && lon && !zoom) {
  3169. newPath = `/#10/${lat}/${lon}/`;
  3170. }
  3171.  
  3172. if (!newPath && sourceURL.searchParams.get('q')) {
  3173. para = ['q'];
  3174. para = pickParameters(para, sourceURL);
  3175. newPath = `/search?query=${para}`;
  3176. instanceUrl = 'https://www.openstreetmap.org'; // TODO Check why this line exist
  3177. }
  3178. break;
  3179.  
  3180. case 'lieu':
  3181. case 'searx':
  3182. case 'whoogle':
  3183. // extract search parameter
  3184. para = ['q', 'text', 'p'];
  3185. para = pickParameters(para, sourceURL);
  3186. newPath = `/search?q=${para}`;
  3187. break;
  3188.  
  3189. case 'metastemwiki':
  3190. // extract language code
  3191. partedHost = hostname.split('.');
  3192. if (partedHost.length === 3 || partedHost.length === 4) {
  3193. lang = partedHost[0];
  3194. }
  3195. newPath = `/#${pathname}/${lang}`;
  3196. break;
  3197.  
  3198. case 'mikuinvidious':
  3199. if (!hostname.startsWith('www.')) {
  3200. partedHost = hostname.split('.');
  3201. if (partedHost.length === 3 || partedHost.length === 4) {
  3202. name = partedHost[0];
  3203. }
  3204. newPath = `/${name}${pathname}`;
  3205. }
  3206. break;
  3207.  
  3208. case 'priviblur':
  3209. if (hostname == '64.media.tumblr.com') {
  3210. newPath = `/tblr/media/64${pathname}`;
  3211. } else {
  3212. partedHost = hostname.split('.');
  3213. if (partedHost.length === 3 || partedHost.length === 4) {
  3214. subname = partedHost[0];
  3215. }
  3216. pathname = pathname.replace('/image/', '/post/');
  3217. if (pathname == '/library') {pathname = '';}
  3218. if (subname == 'www') {subname = '';}
  3219. newPath = `/${subname}${pathname}`;
  3220. }
  3221. break;
  3222.  
  3223. case 'tent':
  3224. partedHost = hostname.split('.');
  3225. if (partedHost.length === 3 || partedHost.length === 4) {
  3226. artist = partedHost[0];
  3227. }
  3228. partedPath = pathname.split('/');
  3229. type = partedPath[1];
  3230. name = partedPath[2];
  3231. if (name) {
  3232. newPath = `/release.php?artist=${artist}&type=${type}&name=${name}`;
  3233. } else {
  3234. newPath = `/release.php?artist=${artist}&type=${type}`;
  3235. }
  3236. break;
  3237.  
  3238. case 'wikiless':
  3239. // extract language code
  3240. partedHost = hostname.split('.');
  3241. if (partedHost.length === 3 || partedHost.length === 4) {
  3242. lang = partedHost[0];
  3243. }
  3244. newPath = `${pathname}?lang=${lang}`;
  3245. break;
  3246.  
  3247. case 'wikiwand':
  3248. // extract language code
  3249. partedHost = hostname.split('.');
  3250. if (partedHost.length === 3 || partedHost.length === 4) {
  3251. lang = partedHost[0];
  3252. }
  3253. partedPath = pathname.split('/');
  3254. pathname = partedPath[2];
  3255. newPath = `/${lang}/${pathname}`;
  3256. break;
  3257.  
  3258. case 'yacy':
  3259. // extract search parameter
  3260. para = ['q', 'text', 'p'];
  3261. //pickParameters(para, sourceURL); // works even when just calling the function?
  3262. para = pickParameters(para, sourceURL);
  3263. newPath = `/yacysearch.html?query=${para}`;
  3264. break;
  3265.  
  3266. }
  3267.  
  3268. if (!newPath || newPath == '/') {
  3269. newPath = pathname + sourceURL.search + sourceURL.hash;
  3270. }
  3271.  
  3272. return newPath;
  3273.  
  3274. }
  3275.  
  3276. (async function registerMenuCommand(){
  3277. try {
  3278. for (let key in proxy) {
  3279. let keyValue = await GM.getValue(key, true);
  3280. let icon, status, value;
  3281. if (keyValue) {
  3282. icon = '🔀'
  3283. status = 'on';
  3284. value = false;
  3285. } else {
  3286. icon = '🔁'
  3287. status = 'off';
  3288. value = true;
  3289. }
  3290. await GM.registerMenuCommand(`${icon} ${key} [${status}]`.toUpperCase(), () => toggleStatus(key, value, status));
  3291. }
  3292. for (let key of ['dhttp', 'i2p', 'loki', 'tor', 'veilid', 'yggdrasil']) {
  3293. let keyValue = await GM.getValue(key, false);
  3294. let icon, status, value;
  3295. if (keyValue) {
  3296. icon = '🔒'
  3297. status = 'on';
  3298. value = false;
  3299. } else {
  3300. icon = '🔓'
  3301. status = 'off';
  3302. value = true;
  3303. }
  3304. await GM.registerMenuCommand(`${icon} ${key} system [${status}]`.toUpperCase(), () => toggleStatus(key, value, status), key[0]);
  3305. }
  3306. } catch (err) {
  3307. console.warn(err);
  3308. console.info('API GM.registerMenuCommand does not seem to be available.');
  3309. }
  3310. })();
  3311.  
  3312. async function toggleStatus(key, value, status) {
  3313. await GM.setValue(key, value);
  3314. //alert(`${key} is now ${status}d`)
  3315. //location.reload();
  3316. }
  3317.  
  3318. (function instanceSwitcher(){
  3319. document.addEventListener("DOMContentLoaded",
  3320. async function() {
  3321. let instanceSelect = isInstance();
  3322. if (instanceSelect) {
  3323. infoBar(instanceSelect);
  3324. //proxyButton(instanceSelect);
  3325. reverseURL(location.href);
  3326. await GM.registerMenuCommand(`🎲️ Switch Instance`,
  3327. () => xhrInstanceSwitcher(instanceSelect), 'S'); // ↻ ↯ ↫
  3328. }
  3329. });
  3330. })();
  3331.  
  3332. // TODO
  3333. function reverseURL() {
  3334.  
  3335. // NOTE Useful for bookmarking original URL
  3336.  
  3337. }
  3338.  
  3339. // Check whether current page is a proxy instance
  3340. // If it is, create a menu command and a top bar to switch with another instance.
  3341. function isInstance(){
  3342. for (i in proxy) {
  3343. for (j in proxy[i]) {
  3344. for (k in proxy[i][j]) {
  3345. let url
  3346. url = proxy[i][j][k];
  3347. url = new URL(url);
  3348. if (location.hostname == url.hostname) {
  3349. instanceName = i;
  3350. return instanceName;
  3351. }
  3352. }
  3353. }
  3354. }
  3355. }
  3356.  
  3357. function proxyButton(instanceSelect) {
  3358. let namespace = 'i2p-schimon-proxy-button';
  3359. let bttn = document.createElement(namespace);
  3360. bttn.id = namespace;
  3361. document.body.append(bttn);
  3362. let icon = document.createElement(namespace);
  3363. bttn.append(icon)
  3364. let text = document.createElement(namespace);
  3365. bttn.append(text)
  3366. text.textContent = `Switch ${instanceSelect} instance`;
  3367. // set color
  3368. //text.style.borderWidth = '5px';
  3369. //text.style.borderRadius = '5px';
  3370. //text.style.borderColor = 'red';
  3371. //text.style.background = 'black';
  3372. //text.style.color = 'whitesmoke';
  3373. // set position
  3374. text.style.display = 'none';
  3375. text.style.position = 'fixed';
  3376. text.style.bottom = 0;
  3377. text.style.right = 0;
  3378. text.style.marginTop = '100px';
  3379. text.style.marginRight = '60px';
  3380. text.style.minHeight = '40px';
  3381. // set font
  3382. text.style.fontFamily = 'system-ui';
  3383. text.style.fontSize = '20px';
  3384. text.style.fontStyle = 'italic';
  3385. text.style.fontWeight = 'bold';
  3386. //icon.title = `🥸 Switch ${instanceSelect} instance`;
  3387. // set content
  3388. icon.textContent = '🥸';
  3389. icon.style.all = 'unset';
  3390. // set font
  3391. icon.style.fontFamily = 'system-ui';
  3392. icon.style.fontSize = '20px';
  3393. icon.style.fontWeight = 'bold';
  3394. // set position
  3395. icon.style.position = 'fixed';
  3396. icon.style.bottom = 0;
  3397. icon.style.right = 0;
  3398. // set appearance
  3399. icon.style.marginTop = '100px';
  3400. icon.style.marginRight = '10px';
  3401. icon.style.minWidth = '50px';
  3402. icon.style.minHeight = '50px';
  3403. icon.style.zIndex = 10000;
  3404. icon.style.opacity = 0.5;
  3405. //icon.style.transition = 'all .5s ease .5s';
  3406. // center character
  3407. icon.style.justifyContent = 'center';
  3408. icon.style.alignItems = 'center';
  3409. icon.style.display = 'flex';
  3410. // disable selection marks
  3411. icon.style.outline = 'none';
  3412. bttn.style.userSelect = 'none';
  3413. bttn.style.cursor = 'default';
  3414. bttn.onmouseover = () => {
  3415. //bttn.textContent = `Switch ${instanceSelect} instance 🥸`;
  3416. icon.style.opacity = 'unset';
  3417. text.style.display = 'unset';
  3418. };
  3419. bttn.onmouseleave = () => {
  3420. icon.textContent = `🥸`;
  3421. icon.style.opacity = 0.8;
  3422. text.style.display = 'none';
  3423. };
  3424. bttn.onclick = async () => {
  3425. await xhrInstanceSwitcher(instanceSelect);
  3426. };
  3427. }
  3428.  
  3429. function getOriginalLink(instanceSelect) {
  3430. let lang, originalLink, originalPath, splitPathname;
  3431. let sourceURL = new URL(location.href);
  3432. let pathname = sourceURL.pathname;
  3433. pathname = pathname.replace('//', '/');
  3434. //let hostname = sourceURL.hostname;
  3435. switch (instanceSelect) {
  3436. case 'alltube':
  3437. originalLink = sourceURL.searchParams.get('url').replace('/www.','/');
  3438. break;
  3439. case 'anonymousoverflow':
  3440. // NOTE Not good due to I2P and onion not having HTTP(S)
  3441. //sourceURL.hostname = 'stackoverflow.com';
  3442. //originalLink = sourceURL;
  3443. originalLink = `https://stackoverflow.com${pathname}`;
  3444. break;
  3445. case 'biblioreads':
  3446. originalLink = `https://goodreads.com${pathname}`;
  3447. break;
  3448. case 'breezewiki':
  3449. splitPathname = pathname.split('/');
  3450. splitPathname.shift();
  3451. let brand = splitPathname.shift();
  3452. originalPath = splitPathname.join('/');
  3453. originalLink = `https://${brand}.fandom.com/${originalPath}`;
  3454. break;
  3455. case 'btdigg':
  3456. if (location.href.includes('/search?')) {
  3457. originalLink = sourceURL;
  3458. } else {
  3459. hash = pathname.split('/')[1];
  3460. originalLink = `magnet:?xt=urn:btih:${hash}`;
  3461. }
  3462. break;
  3463. case 'cloudtube':
  3464. case 'invidious':
  3465. case 'materialious':
  3466. case 'piped':
  3467. case 'pipedmaterial':
  3468. case 'poketube':
  3469. let pageId;
  3470. if (pathname.includes('/embed/') || instanceSelect == 'materialious') {
  3471. pageId = pathname.split('/')[2];
  3472. } else {
  3473. pageId = sourceURL.searchParams.get('v');
  3474. }
  3475. originalLink = `https://youtube.com/watch?v=${pageId}`;
  3476. break;
  3477. case 'destructables':
  3478. case 'indestructables':
  3479. originalLink = `https://instructables.com${pathname}`;
  3480. break;
  3481. case 'gothub':
  3482. originalLink = `https://github.com${pathname}`;
  3483. break;
  3484. case 'laboratory':
  3485. originalLink = `https://${pathname}`;
  3486. break;
  3487. case 'libmedium':
  3488. splitPathname = pathname.split('/');
  3489. //let handler = splitPathname[1].substring(1);
  3490. let handler = splitPathname[1];
  3491. originalPath = splitPathname[2];
  3492. originalLink = `https://${handler}.medium.com/${originalPath}`;
  3493. break;
  3494. case 'libremdb':
  3495. originalLink = `https://imdb.com${pathname}`;
  3496. break;
  3497. case 'librarian':
  3498. originalLink = `https://odysee.com${pathname}`;
  3499. break;
  3500. case 'nitter':
  3501. originalLink = `https://twitter.com${pathname}`;
  3502. break;
  3503. case 'neuters':
  3504. originalLink = `https://reuters.com${pathname}`;
  3505. break;
  3506. case 'proxitok':
  3507. originalLink = `https://tiktok.com${pathname}`;
  3508. break;
  3509. case 'quetre':
  3510. originalLink = `https://quora.com${pathname}`;
  3511. break;
  3512. case 'libreddit':
  3513. case 'redlib':
  3514. case 'teddit':
  3515. if (pathname.includes('/img/')) {
  3516. filename = pathname.split('/')[2];
  3517. originalLink = `https://preview.redd.it/${filename}`;
  3518. } else
  3519. if (pathname.includes('/pics/')) {
  3520. filename = pathname.split('/')[2].replace('w:null_', '');
  3521. originalLink = `https://preview.redd.it/${filename}`;
  3522. } else {
  3523. originalLink = `https://reddit.com${pathname}`;
  3524. }
  3525. break;
  3526. case 'metastemwiki':
  3527. splitHash = sourceURL.hash.split('/')
  3528. lang = splitHash[3];
  3529. pathname = splitHash[2];
  3530. originalLink = `https://${lang}.wikipedia.org/wiki/${pathname}`;
  3531. break;
  3532. case 'imgin':
  3533. case 'rimgo':
  3534. originalLink = `https://imgur.com${pathname}`;
  3535. break;
  3536. case 'scribe':
  3537. originalLink = `https://medium.medium.com${pathname}`;
  3538. break;
  3539. case 'tent':
  3540. let artist = sourceURL.searchParams.get('artist');
  3541. let name = sourceURL.searchParams.get('name');
  3542. let type = sourceURL.searchParams.get('type');
  3543. if (type) {
  3544. originalLink = `https://${artist}.bandcamp.com/${type}/${name}`;
  3545. } else {
  3546. originalLink = `https://${artist}.bandcamp.com/`;
  3547. }
  3548. break;
  3549. case 'wikiless':
  3550. lang = sourceURL.searchParams.get('lang');
  3551. if (!lang) {
  3552. lang = document.querySelector('html').lang;
  3553. }
  3554. originalLink = `https://${lang}.wikipedia.org${pathname}`;
  3555. break;
  3556. case 'wikiwand':
  3557. splitPathname = pathname.split('/')
  3558. lang = splitPathname[1];
  3559. pathname = splitPathname[2];
  3560. originalLink = `https://${lang}.wikipedia.org/wiki/${pathname}`;
  3561. break;
  3562. default:
  3563. originalLink = ``;
  3564. }
  3565. return originalLink;
  3566. }
  3567.  
  3568. function infoBar(instanceSelect) {
  3569. let originalLink = getOriginalLink(instanceSelect);
  3570. let namespace = 'i2p-schimon-proxy-bar';
  3571. let bar = document.createElement(namespace);
  3572. document.body.prepend(bar);
  3573. bar.id = namespace;
  3574. instanceSelectCapitalized = instanceSelect[0].toUpperCase() + instanceSelect.substring(1);
  3575. //bar.title = 'Click to switch to another instance';
  3576. bar.style.all = 'unset';
  3577. bar.style.direction = 'ltr';
  3578. bar.style.backgroundColor = '#f1f1f1';
  3579. bar.style.color = '#000';
  3580. bar.style.borderTop = 'ridge';
  3581. bar.style.fontFamily = 'system-ui';
  3582. bar.style.fontSize = '0.8em'
  3583. //bar.style.fontSize = 'larger';
  3584. bar.style.right = 0;
  3585. bar.style.left = 0;
  3586. bar.style.bottom = 0;
  3587. bar.style.zIndex = 10000000000;
  3588. //bar.style.padding = '6px';
  3589. bar.style.position = 'fixed';
  3590. //bar.style.textAlign = 'center';
  3591. bar.style.userSelect = 'none';
  3592. bar.style.opacity = 0.5;
  3593. //bar.onmouseleave = () => { // onmouseout
  3594. // bar.style.opacity = 0.8;
  3595. //};
  3596. bar.onmouseover = () => { // mouseenter
  3597. bar.style.opacity = 'unset';
  3598. };
  3599. bar.style.display = 'block';
  3600. //bar.style.lineHeight = '40px';
  3601. document.body.style.marginBottom = '40px';
  3602. // TODO Hide when screen is too narrow to hold all elements in one line
  3603. let spanTitle = document.createElement('span');
  3604. spanTitle.textContent = 'URL';
  3605. spanTitle.title = `${instanceSelectCapitalized}`;
  3606. spanTitle.style.margin = '5px';
  3607. spanTitle.style.fontWeight = 'bold';
  3608. bar.append(spanTitle);
  3609. let text = document.createElement('input');
  3610. text.value = originalLink;
  3611. text.style.all = 'unset';
  3612. text.style.margin = '3px';
  3613. //text.style.minWidth = '30%';
  3614. text.style.background = '#fff';
  3615. text.style.borderRadius = '10px';
  3616. text.style.borderStyle = 'inset';
  3617. text.style.borderColor = '-internal-light-dark(rgb(118, 118, 118), rgb(133, 133, 133))';
  3618. bar.append(text);
  3619. let spanSelect = document.createElement('span');
  3620. spanSelect.textContent = 'Select';
  3621. spanSelect.title = 'Select an instance';
  3622. spanSelect.style.margin = '5px';
  3623. spanSelect.style.fontWeight = 'bold';
  3624. bar.append(spanSelect);
  3625. let select = document.createElement('select');
  3626. select.style.all = 'unset';
  3627. select.style.textAlign = 'left';
  3628. select.style.margin = '3px';
  3629. //select.style.maxWidth = '30%';
  3630. select.style.background = '#fff';
  3631. select.style.borderRadius = '10px';
  3632. select.style.borderStyle = 'inset';
  3633. select.style.borderColor = '-internal-light-dark(rgb(118, 118, 118), rgb(133, 133, 133))';
  3634. select.oninput = async () => {replaceOrigin(select.value);};
  3635. bar.append(select);
  3636. for (i in proxy[instanceSelect]) {
  3637. for (j of proxy[instanceSelect][i]) {
  3638. let option = document.createElement('option');
  3639. option.textContent = j;
  3640. option.value = j;
  3641. select.append(option);
  3642. }
  3643. }
  3644. let buttons = document.createElement('span');
  3645. buttons.style.float = 'right';
  3646. let buttonSwitch = document.createElement('button');
  3647. buttonSwitch.textContent = '🎲️ Random';
  3648. buttonSwitch.title = 'Switch instance randomly';
  3649. buttonSwitch.style.all = 'unset';
  3650. buttonSwitch.style.margin = '3px';
  3651. buttonSwitch.onclick = async () => {await xhrInstanceSwitcher(instanceSelect);};
  3652. buttons.append(buttonSwitch);
  3653. let buttonReturn = document.createElement('button');
  3654. buttonReturn.textContent = '🏠️ Return';
  3655. buttonReturn.title = 'Return to origin page (click twice)';
  3656. buttonReturn.style.all = 'unset';
  3657. buttonReturn.style.margin = '3px';
  3658. buttonReturn.ondblclick = async () => {location.href = originalLink;};
  3659. buttons.append(buttonReturn);
  3660. let buttonClose = document.createElement('button');
  3661. buttonClose.textContent = '🚪️ Close';
  3662. buttonClose.title = 'Close this bar';
  3663. buttonClose.style.all = 'unset';
  3664. //buttonClose.style.fontWeight = 'bold';
  3665. buttonClose.style.margin = '3px';
  3666. buttonClose.style.marginRight = '15px';
  3667. buttonClose.onclick = async () => {bar.remove();};
  3668. buttons.append(buttonClose);
  3669. bar.append(buttons);
  3670. //let span = document.createElement('span');
  3671. //span.textContent = 'Proxy Redirect';
  3672. ////span.style.fontWeight = 'normal';
  3673. ////span.style.fontStyle = 'italic';
  3674. //span.style.margin = '3px';
  3675. //bar.append(span);
  3676. }
  3677.  
  3678. function replaceOrigin(newUrl) {
  3679. let url = new URL(location.href);
  3680. let pathname = url.pathname + url.search;
  3681. location.href = newUrl + pathname;
  3682. //url.origin = newUrl;
  3683. //location.href = url
  3684. }
  3685.  
  3686. async function pickURL(instanceName) {
  3687. // instance select
  3688. let urlArray, telecomSystem;
  3689. if (instanceName && await GM.getValue(instanceName, true)) {
  3690. for (let key of ['dhttp', 'i2p', 'loki', 'tor', 'veilid', 'yggdrasil']) {
  3691. if (await GM.getValue(key, false) &&
  3692. proxy[instanceName][key].length) {
  3693. urlArray = proxy[instanceName][key];
  3694. telecomSystem = key;
  3695. break;
  3696. }
  3697. }
  3698. if (!urlArray) {
  3699. urlArray = proxy[instanceName].clearnet;
  3700. telecomSystem = 'clearnet';
  3701. }
  3702. let urlSelect = urlArray[Math.floor(Math.random()*urlArray.length)];
  3703. return {name : instanceName, url : urlSelect, type : telecomSystem};
  3704. }
  3705. }
  3706.  
  3707. async function xhrInstanceSwitcher(instanceSelect) {
  3708. let url = location.href;
  3709. let result = await pickURL(instanceSelect);
  3710. if (!result) {return;}
  3711. let instanceName = result.name;
  3712. let instanceType = result.type;
  3713. let instanceUrl = result.url;
  3714. if (!url) {return;}
  3715. let newPath = location.pathname + location.search;
  3716. let newUrl = new URL(instanceUrl + newPath);
  3717. let counter = 0;
  3718.  
  3719. console.log(`
  3720. Setting Proxy to ${instanceName}
  3721. URL: ${newUrl}
  3722. `);
  3723.  
  3724. console.log(`
  3725. URL: ${url}
  3726. Selected: ${instanceUrl}
  3727. Pathname: ${newPath}
  3728. `);
  3729.  
  3730. try {
  3731. gmXmlhttpRequest({
  3732. method: 'GET',
  3733. url: instanceUrl,
  3734. synchronous: true,
  3735. onprogress: pageLoader(newUrl),
  3736. onload: async function(response) {
  3737. if (response.finalUrl.startsWith(instanceUrl) && response.status == 200) {
  3738. newUrl = new URL(instanceUrl + newPath);
  3739. await wait(3);
  3740. location.href = newUrl;
  3741. } else {
  3742. instanceUrl = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  3743. instanceUrl = instanceUrl.replace(/\./g,'-');
  3744. console.warn('Instance URL ' + instanceUrl + ' might be out of service. URL has changed. Please report this to the developer.');
  3745. if (maxAttempts(instanceName, instanceType, counter)) {
  3746. instanceUrl = farSide(instanceName, instanceUrl);
  3747. if (!instanceUrl) {
  3748. instanceObj = await pickURL(instanceName);
  3749. instanceUrl = instanceObj.url;
  3750. }
  3751. newPath = modifyPathname(instanceName, url);
  3752. newUrl = new URL(instanceUrl + newPath);
  3753. noRespond(url, newUrl);
  3754. await wait(5);
  3755. location.href = newUrl;
  3756. }
  3757. maxAttempts(instanceName, instanceType, counter);
  3758. xhr();
  3759. }
  3760. },
  3761. onerror: async function(response) {
  3762. instanceUrl = instanceUrl.slice(instanceUrl.lastIndexOf('/')+1);
  3763. instanceUrl = instanceUrl.replace(/\./g,'-');
  3764. console.warn('Instance URL ' + instanceUrl + ' might be offline. Status error: ' + response.status + '. Please report this to the developer.');
  3765. if (maxAttempts(instanceName, instanceType, counter)) {
  3766. instanceUrl = farSide(instanceName, instanceUrl);
  3767. if (!instanceUrl) {
  3768. instanceObj = await pickURL(instanceName);
  3769. instanceUrl = instanceObj.url;
  3770. }
  3771. newPath = modifyPathname(instanceName, url);
  3772. newUrl = new URL(instanceUrl + newPath);
  3773. noRespond(url, newUrl);
  3774. await wait(5);
  3775. location.href = newUrl;
  3776. }
  3777. maxAttempts(instanceName, instanceType, counter);
  3778. xhr();
  3779. }
  3780. });
  3781. } catch (err) {
  3782. console.warn(err);
  3783. console.info('API GM.xmlHttpRequest does not seem to be available. Defaulting to Farside.link. Contribute your help in C++ to improve Greasemonkey for Falkon https://bugs.kde.org/show_bug.cgi?id=466533');
  3784. //pickURL();
  3785. instanceUrl = farSide(instanceName, instanceUrl);
  3786. if (!instanceUrl) {
  3787. instanceObj = await pickURL(instanceName);
  3788. instanceUrl = instanceObj.url;
  3789. }
  3790. //if ((proxy[instanceName].clearnet).filter(str => str.includes('farside.link')).length) {
  3791. // instanceUrl = (proxy[instanceName].clearnet).filter(str => str.includes('farside.link'))[0];
  3792. //}
  3793. newUrl = new URL(instanceUrl + newPath);
  3794. await wait(3);
  3795. location.href = newUrl;
  3796. }
  3797. }
  3798.  
  3799. async function wait(seconds) {
  3800. return new Promise(resolve => setTimeout(resolve, seconds * 1000));
  3801. }