Skip to content

Commit

Permalink
Merge pull request #213 from iConn/patch-5
Browse files Browse the repository at this point in the history
Critical Security issue - Privilege Scalation
  • Loading branch information
thyseus committed Sep 14, 2016
2 parents c15351a + 2274ae6 commit f314752
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions user/models/YumUser.php
Expand Up @@ -241,6 +241,9 @@ public function rules() {
$rules[] = array('notifyType, avatar, id', 'safe');
$rules[] = array('password', 'required', 'on' => array('insert', 'registration'));
$rules[] = array('createtime, lastvisit, lastaction, superuser, status', 'numerical', 'integerOnly' => true);

$rules[] = array('superuser', 'safe', 'on'=> 'managerUserUpdate');
$rules[] = array('superuser', 'unsafe', 'on'=> 'userUpdate, registration, insert, update');

if (Yum::hasModule('avatar')) {
// require an avatar image in the avatar upload screen
Expand Down

0 comments on commit f314752

Please sign in to comment.