summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2007-12-31 23:09:25 +0000
committerScott Ullrich <sullrich@pfsense.org>2007-12-31 23:09:25 +0000
commit9671bc55295066974f013b1b2e71e46f9be012ec (patch)
tree65c87adaeb29971311cb15210e8955ab4f2ea882 /etc
parentb32a37912af7a8c0251b54e896d8673d407bf171 (diff)
downloadpfsense-9671bc55295066974f013b1b2e71e46f9be012ec.zip
pfsense-9671bc55295066974f013b1b2e71e46f9be012ec.tar.gz
Correctly return no groups when the user is not a member of a local group.
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/auth.inc4
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/inc/auth.inc b/etc/inc/auth.inc
index 8f66098..eeb0aef 100644
--- a/etc/inc/auth.inc
+++ b/etc/inc/auth.inc
@@ -68,6 +68,7 @@ function getAllowedGroups($logged_in_user) {
$fdny = fopen("/tmp/groups","w");
fwrite($fdny, print_r($allowed, true));
fclose($fdny);
+ $allowed = array();
if(is_array($config['system']['group']) && is_array($allowed_groups)) {
foreach($config['system']['group'] as $group) {
if(in_array($group['name'], $allowed_groups)) {
@@ -77,8 +78,7 @@ function getAllowedGroups($logged_in_user) {
}
}
}
- if(count($allowed)>1)
- return $allowed;
+ return $allowed;
}
$final_allowed = array();
OpenPOWER on IntegriCloud