Skip to content

Commit

Permalink
fixes #1168 prevent XSS on pwg.images.setInfo
Browse files Browse the repository at this point in the history
  • Loading branch information
plegall committed Mar 24, 2020
1 parent b3027b1 commit 078cd73
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion include/ws_functions/pwg.images.php
Expand Up @@ -1674,7 +1674,12 @@ function ws_images_setInfo($params, $service)
);
}

$update['file'] = $params['file'];
// prevent XSS, remove HTML tags
$update['file'] = strip_tags($params['file']);
if (empty($update['file']))
{
unset($update['file']);
}
}

if (count(array_keys($update)) > 0)
Expand Down

0 comments on commit 078cd73

Please sign in to comment.