From 3baff6a2ad2bbad9adf69977f4efcc32a150a208 Mon Sep 17 00:00:00 2001 From: Felix Van der Jeugt Date: Mon, 28 Sep 2020 16:51:36 +0200 Subject: [PATCH] rewrite accidental searches over TLS --- config/qutebrowser/config.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/config/qutebrowser/config.py b/config/qutebrowser/config.py index 6a51eba..419c4cc 100644 --- a/config/qutebrowser/config.py +++ b/config/qutebrowser/config.py @@ -126,4 +126,9 @@ def intercept(info: interceptor.Request) -> None: new_url.setScheme('http') info.redirect(new_url) + elif 'juy4e6eicawzdrz7.onion' == info.request_url.host() and 'https' == info.request_url.scheme(): + new_url = QUrl(info.request_url) + new_url.setScheme('http') + info.redirect(new_url) + interceptor.register(intercept)