From 3f13e382f5572d3e9a2aa6fabcb9f3c01b753171 Mon Sep 17 00:00:00 2001 From: Oleg Sh <> Date: Sat, 16 Mar 2024 14:49:56 +0100 Subject: [PATCH] Fixed Reflected XSS: https://github.com/UnickSoft/graphonline/issues/49 --- tpl/home.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tpl/home.php b/tpl/home.php index 286d73a..ba02dba 100755 --- a/tpl/home.php +++ b/tpl/home.php @@ -748,9 +748,9 @@
= L('rename_vertex')?>
= L('rename_text')?>
-= isset($_POST["matrix"]) ? $_POST["matrix"] : ""?>
-= isset($_POST["separator"]) ? $_POST["separator"] : ""?>
-= isset($_POST["incidenceMatrix"]) ? $_POST["incidenceMatrix"] : ""?>
+= isset($_POST["matrix"]) ? htmlspecialchars ($_POST["matrix"]) : ""?>
+= isset($_POST["separator"]) ? htmlspecialchars ($_POST["separator"]) : ""?>
+= isset($_POST["incidenceMatrix"]) ? htmlspecialchars ($_POST["incidenceMatrix"]) : ""?>
= isset($_POST["pairs"]) ? str_replace("<", "<", str_replace(">", ">", $_POST["pairs"])) : ""?>
= L('current_language')?>
= L('edit_weight')?>