Sanitize graph title input (#11919)

This commit is contained in:
Jellyfrog
2020-07-09 19:48:36 +02:00
committed by GitHub
parent 98d6fc1ace
commit a3ae3805d1

View File

@@ -60,7 +60,7 @@ function graph_error($string)
include 'includes/html/graphs/common.inc.php';
$rrd_options .= ' HRULE:0#555555';
$rrd_options .= " --title='".$string."'";
$rrd_options .= " --title=" . escapeshellarg($string);
rrdtool_graph($graphfile, $rrd_options);