From 3c0022d73a9b9db5739bf58bef369eaa71024156 Mon Sep 17 00:00:00 2001 From: gorhill Date: Thu, 27 Apr 2017 09:09:29 -0400 Subject: [PATCH] more cases re #2529 --- src/js/dashboard-common.js | 2 +- src/js/document-blocked.js | 1 + src/settings.html | 4 ++-- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/js/dashboard-common.js b/src/js/dashboard-common.js index 47e04c5ca..7b22e6d42 100644 --- a/src/js/dashboard-common.js +++ b/src/js/dashboard-common.js @@ -113,7 +113,7 @@ self.uBlockDashboard.dateNowToSensibleString = function() { /******************************************************************************/ // Open links in the proper window -uDom('a').attr('target', '_blank'); +uDom('a').attr('target', '_blank').attr('rel', 'noopener noreferrer'); uDom('a[href*="dashboard.html"]').attr('target', '_parent'); uDom('.whatisthis').on('click', function() { uDom(this) diff --git a/src/js/document-blocked.js b/src/js/document-blocked.js index 6657a027f..89d6a0e51 100644 --- a/src/js/document-blocked.js +++ b/src/js/document-blocked.js @@ -73,6 +73,7 @@ var details = {}; node.textContent = entry.title; node.setAttribute('href', url); node.setAttribute('target', '_blank'); + node.setAttribute('rel', 'noopener noreferrer'); } else { node = document.createTextNode(entry.title); } diff --git a/src/settings.html b/src/settings.html index f96381519..6ad861f9a 100644 --- a/src/settings.html +++ b/src/settings.html @@ -21,8 +21,8 @@