Branch 'roundcubemail-plugins-kolab-3.1' - plugins/kolab_auth
Aleksander Machniak
machniak at kolabsys.com
Thu Jan 16 14:07:33 CET 2014
plugins/kolab_auth/kolab_auth_ldap.php | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
New commits:
commit a441f72613d191280ef90cf8e5e70fa9f1effd08
Author: Aleksander Machniak <machniak at kolabsys.com>
Date: Thu Jan 16 14:06:00 2014 +0100
Allow mixed-case in LDAP attribute names in fieldmap (Bug #2776)
diff --git a/plugins/kolab_auth/kolab_auth_ldap.php b/plugins/kolab_auth/kolab_auth_ldap.php
index 2f2ca14..ddf7cff 100644
--- a/plugins/kolab_auth/kolab_auth_ldap.php
+++ b/plugins/kolab_auth/kolab_auth_ldap.php
@@ -329,9 +329,12 @@ class kolab_auth_ldap extends rcube_ldap_generic
// fields mapping
foreach ($this->fieldmap as $field => $attr) {
- if (isset($entry[$attr])) {
- $entry[$field] = $entry[$attr];
+ // $entry is indexed by lower-case attribute names
+ $attr_lc = strtolower($attr);
+ if (isset($entry[$attr_lc])) {
+ $entry[$field] = $entry[$attr_lc];
}
+ // @TODO: consider returning also $entry[$attr] when $attr != $attr_lc
}
return $entry;
More information about the commits
mailing list