LTI Integration - non-admin user in 'No institution' unable to login
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mahara |
Fix Released
|
High
|
Robert Lyon | ||
17.04 |
Fix Released
|
High
|
Robert Lyon | ||
17.10 |
Fix Released
|
High
|
Robert Lyon |
Bug Description
We do a check:
if (!$is_site_admin) {
// check user is member of configured OAuth institution
$institutions = array_keys(
if (!in_array(
... throw error and stop them logging in ...
}
}
The problem begins when we check what institutions they are in
load_user_
This only returns an array of institutions if the user is in 1 or more true institutions.
If they are not in a true institution they are in the 'No institution' (mahara) one.
We have already got a $userid from earlier in code so we know a user exists we just need to test them against the $WEBSERVICE_
Changed in mahara: | |
importance: | Undecided → High |
milestone: | none → 17.10.0 |
Patch for "master" branch: https:/ /reviews. mahara. org/8009