diff options
author | Arthur Schiwon <blizzz@owncloud.com> | 2012-06-06 12:29:48 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2012-06-06 12:29:48 +0200 |
commit | 190fca1121d4b37d7c4b2f96204daf7d8d0dded6 (patch) | |
tree | a348f29441f67a90a3ea4de712a8b0560bd44e5d /apps/user_ldap | |
parent | ca0108aabf0c922d44c0a9ae984e479278909bcb (diff) | |
download | nextcloud-server-190fca1121d4b37d7c4b2f96204daf7d8d0dded6.tar.gz nextcloud-server-190fca1121d4b37d7c4b2f96204daf7d8d0dded6.zip |
LDPA: don't drop legal whitespaces when sanitizing DN. Fixes oc-914
Diffstat (limited to 'apps/user_ldap')
-rw-r--r-- | apps/user_ldap/lib_ldap.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/user_ldap/lib_ldap.php b/apps/user_ldap/lib_ldap.php index b900a67ec31..f6942ad326e 100644 --- a/apps/user_ldap/lib_ldap.php +++ b/apps/user_ldap/lib_ldap.php @@ -530,7 +530,7 @@ class OC_LDAP { static private function sanitizeDN($dn) { //OID sometimes gives back DNs with whitespace after the comma a la "uid=foo, cn=bar, dn=..." We need to tackle this! - $dn = preg_replace('/,\s+/',',',$dn); + $dn = preg_replace('/([^\\\]),(\s+)/','\1,',$dn); //make comparisons and everything work $dn = strtolower($dn); |