Skip to content

Commit

Permalink
Fixed issue [security] #16068: Stored Cross Site Scripting Vulnerabil…
Browse files Browse the repository at this point in the history
…ity in permission rules. (Thanks to Matthew Aberegg)
  • Loading branch information
ptelu committed Apr 2, 2020
1 parent a63c6f5 commit 2aada33
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -83,6 +83,10 @@ public function applyedit()
$aPermissiontemplate = Yii::app()->request->getPost('Permissiontemplates');
$model = $this->loadModel($aPermissiontemplate['ptid']);

// XSS filter
$aPermissiontemplate['name'] = CHtml::encode($aPermissiontemplate['name']);
$aPermissiontemplate['description'] = CHtml::encode($aPermissiontemplate['description']);

$newAttributes = array_merge($model->attributes, $aPermissiontemplate);
$model->attributes = $newAttributes;

Expand Down

0 comments on commit 2aada33

Please sign in to comment.