From b4c3e8f820f818fc35c278e5eb67cb106f73c25f Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Thu, 25 Sep 2025 14:22:31 +0200 Subject: Fix IdP list merging --- src/webview.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/webview.cpp') diff --git a/src/webview.cpp b/src/webview.cpp index c4995bd..d9a689d 100644 --- a/src/webview.cpp +++ b/src/webview.cpp @@ -100,7 +100,7 @@ WebView::WebView(QWidget* parent) // Any url filtering, since many pages allow you to escape through different links auto bl = Global::urlBlacklist(); auto wl = Global::urlWhitelist(); - _profile->setRequestInterceptor(new SlxUrlRequestInterceptor(urlListToRegExp(bl), urlListToRegExp(wl))); + _profile->setUrlRequestInterceptor(new SlxUrlRequestInterceptor(urlListToRegExp(bl), urlListToRegExp(wl))); } // Use our custom page to receive activity signals from injected JS @@ -279,12 +279,11 @@ void WebView::installJsInjectionScript() { // If we should filter the list of allowed IdPs, inject the list into // the page as JavaScript - static QRegularExpression REGEX("[^\\w./:@-]", QRegularExpression::UseUnicodePropertiesOption); const auto& map = Global::getCombinedIdpWhitelist(); QSet idpList; for (auto it = map.constBegin(); it != map.constEnd(); ++it) { - for (QString s : it.value().toStringList()) { - idpList.insert(s.replace(REGEX, QString())); + for (const QString &s : it.value().toString().split(' ')) { + idpList.insert(s); } } idpSpaceList = idpList.values().join(' '); -- cgit v1.2.3-55-g7522