Additional rXSS fix / closes #1558

This commit is contained in:
Serghey Rodin 2018-05-16 17:23:04 +03:00
parent e62432e672
commit c80c4c472e

View file

@ -13,10 +13,10 @@ if (($_SESSION['user'] == 'admin') && (!empty($_SESSION['look']))) {
}
if (!empty($_REQUEST['path'])) {
$path = $_REQUEST['path'];
$path = htmlspecialchars($_REQUEST['path'], ENT_QUOTES, 'UTF-8');
if (!empty($_REQUEST['raw'])) {
header('content-type: image/jpeg');
passthru (VESTA_CMD . "v-open-fs-file " . $user . " " . escapeshellarg(htmlspecialchars($_REQUEST['path'], ENT_QUOTES, 'UTF-8')));
passthru (VESTA_CMD . "v-open-fs-file " . $user . " " . escapeshellarg($path));
exit;
}
}