Adds an attributes parameter to the ldap adapter (#184)

* Adds an attribute parameter to the ldap adapter

Using this parameter is much more efficient than the default action (which is to return all attributes and their associated values). The use of this parameter should therefore be considered good practice.

(from https://www.php.net/manual/en/function.ldap-search.php)

* Updates the docs about ldap_attributes parameter

* Enhances portuguese translation

* Update backend/Services/Auth/Adapters/LDAP.php

Commit suggestion
This commit is contained in:
Luiz Kill
2021-02-18 05:18:30 -03:00
committed by GitHub
parent 55f3dd1a5f
commit a48fa3c717
3 changed files with 26 additions and 23 deletions

View File

@@ -100,6 +100,7 @@ Replace your current Auth handler in `configuration.php` file like this:
'ldap_bindPass'=>'ldapbinduser-password',
'ldap_baseDN'=>'cn=users,dc=ldap,dc=example,dc=com',
'ldap_filter'=>'(uid=*)', //ex: 'ldap_filter'=>'(&(uid=*)(memberOf=cn=administrators,cn=groups,dc=ldap,dc=example,dc=com))',
'ldap_attributes' => ["uid","cn","dn"],
'ldap_userFieldMapping'=> [
'username' =>'uid',
'name' =>'cn',