mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-16 03:16:01 +00:00
add some protection against opener attacks if external site is opened via window.open()
This commit is contained in:
@@ -1957,7 +1957,7 @@
|
||||
# $entry .= " <a target=\"_blank\" href=\"" . htmlspecialchars($url) . "\">" .
|
||||
# $filename . " (" . $ctype . ")" . "</a>";
|
||||
|
||||
$entry = "<div onclick=\"window.open('".htmlspecialchars($url)."')\"
|
||||
$entry = "<div onclick=\"openUrlPopup('".htmlspecialchars($url)."')\"
|
||||
dojoType=\"dijit.MenuItem\">$filename ($ctype)</div>";
|
||||
|
||||
array_push($entries_html, $entry);
|
||||
@@ -2038,7 +2038,7 @@
|
||||
else
|
||||
$filename = "";
|
||||
|
||||
$rv .= "<div onclick='window.open(\"".htmlspecialchars($entry["url"])."\")'
|
||||
$rv .= "<div onclick='openUrlPopup(\"".htmlspecialchars($entry["url"])."\")'
|
||||
dojoType=\"dijit.MenuItem\">".$filename . $title."</div>";
|
||||
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user