diff --git a/www/include/home/customViews/rename.php b/www/include/home/customViews/rename.php index fb7368e5548..9921c592b7d 100644 --- a/www/include/home/customViews/rename.php +++ b/www/include/home/customViews/rename.php @@ -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(); @@ -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(); }