From d32f2006c71ffbc3c00c9d8d1bf695644c2ebc28 Mon Sep 17 00:00:00 2001 From: Brian Lycett Date: Thu, 22 Jul 2021 09:16:38 +0100 Subject: [PATCH] Fix for LDAP_GROUP_MEMBERSHIP_USES_UID override --- www/includes/config.inc.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/www/includes/config.inc.php b/www/includes/config.inc.php index 5e5d5d1..c1b23ae 100644 --- a/www/includes/config.inc.php +++ b/www/includes/config.inc.php @@ -33,7 +33,10 @@ if (getenv('LDAP_ACCOUNT_ADDITIONAL_ATTRIBUTES')) { $LDAP['account_additional_attributes'] = getenv('LDAP_ACCOUNT_ADDITIONAL_ATTRIBUTES'); } if (getenv('LDAP_GROUP_MEMBERSHIP_ATTRIBUTE')) { $LDAP['group_membership_attribute'] = getenv('LDAP_GROUP_MEMBERSHIP_ATTRIBUTE'); } - if (getenv('LDAP_GROUP_MEMBERSHIP_USES_UID') and strtoupper(getenv('LDAP_GROUP_MEMBERSHIP_USES_UID')) == TRUE ) { $LDAP['group_membership_uses_uid'] = TRUE; } + if (getenv('LDAP_GROUP_MEMBERSHIP_USES_UID') { + if (strtoupper(getenv('LDAP_GROUP_MEMBERSHIP_USES_UID')) == TRUE ) { $LDAP['group_membership_uses_uid'] = TRUE; } + if (strtoupper(getenv('LDAP_GROUP_MEMBERSHIP_USES_UID')) == FALSE ) { $LDAP['group_membership_uses_uid'] = FALSE; } + } $LDAP['require_starttls'] = ((strcasecmp(getenv('LDAP_REQUIRE_STARTTLS'),'TRUE') == 0) ? TRUE : FALSE); $LDAP['ignore_cert_errors'] = ((strcasecmp(getenv('LDAP_IGNORE_CERT_ERRORS'),'TRUE') == 0) ? TRUE : FALSE);