From ba2853caac636d2ae596d74561fa0233567242d4 Mon Sep 17 00:00:00 2001 From: Jérémy DECOOL Date: Sun, 12 Feb 2017 11:01:36 +0100 Subject: Prevent target='_blank' vulnerability on dynamic link --- classes/feeds.php | 12 ++++++------ classes/pref/prefs.php | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'classes') diff --git a/classes/feeds.php b/classes/feeds.php index a41109383..6b96d8364 100755 --- a/classes/feeds.php +++ b/classes/feeds.php @@ -398,7 +398,7 @@ class Feeds extends Handler_Protected { alt=\"Publish article\" onclick='togglePub($id)'>"; } -# $content_link = "" . +# $content_link = "" . # $line["title"] . ""; # $content_link = " ". $line["title"] . " $entry_author"; @@ -691,13 +691,13 @@ class Feeds extends Handler_Protected { $tmp_line = $this->dbh->fetch_assoc($tmp_result); - $reply['content'] .= "" . $tmp_line['title'] . ""; $reply['content'] .= " "; - $reply['content'] .= ""; + $reply['content'] .= ""; $reply['content'] .= ""; $reply['content'] .= ""; @@ -746,12 +746,12 @@ class Feeds extends Handler_Protected { $comments_url = htmlspecialchars($line["link"]); } $entry_comments = "$num_comments ". + target='_blank' rel='noopener noreferrer' href=\"$comments_url\">$num_comments ". _ngettext("comment", "comments", $num_comments).""; } else { if ($line["comments"] && $line["link"] != $line["comments"]) { - $entry_comments = "".__("comments").""; + $entry_comments = "".__("comments").""; } } diff --git a/classes/pref/prefs.php b/classes/pref/prefs.php index 9a7ab55a0..ece9e8078 100644 --- a/classes/pref/prefs.php +++ b/classes/pref/prefs.php @@ -776,7 +776,7 @@ class Pref_Prefs extends Handler_Protected { print ""; print "" . htmlspecialchars($about[1]); if (@$about[4]) { - print " — ".__("more info").""; } print ""; @@ -835,7 +835,7 @@ class Pref_Prefs extends Handler_Protected { print ""; print ""; if (@$about[4]) { - print " — ".__("more info").""; } print ""; -- cgit v1.2.3-54-g00ecf