Permalink
Browse files

security report MDL-20834 Fixing roles checks

  • Loading branch information...
1 parent 5ed143c commit 6d558e7705c78c5467e061aeb33ac248f279c2e0 @moodler moodler committed Nov 25, 2009
Showing with 1 addition and 1 deletion.
  1. +1 −1 admin/report/security/lib.php
@@ -1110,7 +1110,7 @@ function report_security_check_riskbackup($detailed=false) {
$result->status = null;
$result->link = null;
- if ($roles = get_roles_with_capability('moodle/backup:userinfo', CAP_ALLOW)) {
+ if ($roles = get_roles_with_capability('moodle/backup:userinfo', CAP_ALLOW, get_context_instance(CONTEXT_SYSTEM))) {
// Find all the users who have the potential ability to backup user info. Ignoring the actual backup capability for now
// because it could easily be ALLOWed later and then these user info caps would suddenly be a problem.
$sqluserinfo = "SELECT u.id, u.firstname, u.lastname, u.picture, u.imagealt, u.email, ra.contextid, ra.roleid

0 comments on commit 6d558e7

Please sign in to comment.