Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

Fix(security): XSS security vulnerabilities #12030

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion www/include/home/customViews/rename.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
require_once _CENTREON_PATH_ . "www/class/centreonWidget.class.php";
require_once _CENTREON_PATH_ . "www/class/centreonSession.class.php";
require_once _CENTREON_PATH_ . "www/class/centreonUser.class.php";
require_once _CENTREON_PATH_ . "www/class/HtmlAnalyzer.php";

session_start();
session_write_close();
Expand Down Expand Up @@ -85,7 +86,7 @@

$widgetObj = new CentreonWidget($centreon, $db);
try {
echo $widgetObj->rename($widgetId, $newName);
echo $widgetObj->rename($widgetId, htmlspecialchars($newName, ENT_QUOTES, 'UTF-8'));
} catch (CentreonWidgetException $e) {
echo $e->getMessage();
}