escape role name to prevent xss attack

This commit is contained in:
Uwe Steinmann 2022-03-28 21:33:48 +02:00
parent 283d051d3a
commit 9e92524fdb

View File

@ -351,7 +351,7 @@ $(document).ready( function() {
);
$options = array();
foreach($roles as $role) {
$options[] = array($role->getID(), $role->getName(), ($currUser && $currUser->getRole()->getID() == $role->getID()));
$options[] = array($role->getID(), htmlspecialchars($role->getName()), ($currUser && $currUser->getRole()->getID() == $role->getID()));
}
$this->formField(
getMLText("role"),