From 5985d00c6f451ef67cc998be538ecff8ff840192 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Mon, 27 Aug 2012 21:32:32 +0200 Subject: [PATCH] LDAP: transliterate other latin characters to ASCII when creating owncloud names. Already created usernames are not being affected. --- apps/user_ldap/lib/access.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index ec3b526491..68df4c4cb9 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -564,6 +564,10 @@ abstract class Access { return $name; } + // Translitaration + //latin characters to ASCII + $name = iconv('UTF-8', 'ASCII//TRANSLIT', $name); + //REPLACEMENTS $name = \OCP\Util::mb_str_replace(' ', '_', $name, 'UTF-8');