Skip to content

Commit e0751a7

Browse files
committed
LDAP: Remove duplicate definition of extldap_get_admin() - refs #4662
1 parent 8c01738 commit e0751a7

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

app/config/auth.conf.dist.php

+3-11
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@
117117
'password' => 'userPassword',
118118
'status' => '!5', // Forcing status to 5; To change this set 'status' => 'func' and implement an extldap_get_status($ldap_array) function
119119
'active' => '!1', // Forcing active to 1; To change this set 'status' => 'func' and implement an extldap_get_active($ldap_array) function
120-
'admin' => 'func' // Using the extldap_get_admin() function to check if user is an administrator based on some ldap user record value
120+
'admin' => 'func' // Using the extldap_get_admin() function (defined in main/auth/external_login/ldap.inc.php) to check if user is an administrator based on some ldap user record value
121121
/* Extras example
122122
'extra' => array(
123123
'title' => 'title',
@@ -134,14 +134,6 @@
134134
$extldap_user_correspondance = $ldapUserCorrespondance;
135135
}
136136

137-
/**
138-
* Example method to get whether the user is an admin or not. Please implement your logic inside.
139-
*/
140-
function extldap_get_admin($ldap_array)
141-
{
142-
return 0; // By default users comming from ldap are not Administrators
143-
}
144-
145137
/**
146138
* OpenID
147139
*/
@@ -155,8 +147,8 @@ function extldap_get_admin($ldap_array)
155147
* CAS
156148
*/
157149
$cas = [
158-
'service_base_url' => '', //The base url of your service required by phpCAS since compliance with
159-
//https://github.com/advisories/GHSA-8q72-6qq8-xv64 in version 1.6
150+
'service_base_url' => '', //The base url of your service required by phpCAS since compliance with
151+
//https://github.com/advisories/GHSA-8q72-6qq8-xv64 in version 1.6
160152
//with this https://github.com/apereo/phpCAS/commit/b759361d904a2cb2a3bcee9411fc348cfde5d163
161153
//It should be the URL of you Chamilo or an array of all the URLs in case of a multiURL installation including https and / at the end
162154
'force_redirect' => false,

0 commit comments

Comments
 (0)