summaryrefslogtreecommitdiffstats
path: root/usr/local
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2015-08-12 12:07:15 -0400
committerjim-p <jimp@pfsense.org>2015-08-12 12:10:46 -0400
commit709c2f99f1bf99022ee8ba670cfd8025e2c71592 (patch)
treefde3ebe661cc80e526944be6dbebd2fe051b1c24 /usr/local
parent24850bca184ba103fad984da638fe7252071d1af (diff)
downloadpfsense-709c2f99f1bf99022ee8ba670cfd8025e2c71592.zip
pfsense-709c2f99f1bf99022ee8ba670cfd8025e2c71592.tar.gz
Fix GUI auth from RADIUS to grab group names from the Class attribute. Implements #935
The RADIUS server must populate the Class attribute with a string, semicolon-separated, of user groups. Similar to LDAP, local groups must exist with matching names, and privileges are determined by the local matching groups.
Diffstat (limited to 'usr/local')
-rw-r--r--usr/local/www/diag_authentication.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr/local/www/diag_authentication.php b/usr/local/www/diag_authentication.php
index df68560..704e92a 100644
--- a/usr/local/www/diag_authentication.php
+++ b/usr/local/www/diag_authentication.php
@@ -55,9 +55,10 @@ if ($_POST) {
$input_errors[] = gettext("A username and password must be specified.");
if (!$input_errors) {
- if (authenticate_user($_POST['username'], $_POST['passwordfld'], $authcfg)) {
+ $attributes = array();
+ if (authenticate_user($_POST['username'], $_POST['passwordfld'], $authcfg, $attributes)) {
$savemsg = gettext("User") . ": " . $_POST['username'] . " " . gettext("authenticated successfully.");
- $groups = getUserGroups($_POST['username'], $authcfg);
+ $groups = getUserGroups($_POST['username'], $authcfg, $attributes);
$savemsg .= "<br />" . gettext("This user is a member of these groups") . ": <br />";
foreach ($groups as $group)
$savemsg .= "{$group} ";
OpenPOWER on IntegriCloud