diff options
Diffstat (limited to 'apps/user_ldap')
-rw-r--r-- | apps/user_ldap/appinfo/install.php | 2 | ||||
-rw-r--r-- | apps/user_ldap/appinfo/update.php | 6 | ||||
-rw-r--r-- | apps/user_ldap/appinfo/version | 2 | ||||
-rw-r--r-- | apps/user_ldap/group_ldap.php | 2 | ||||
-rw-r--r-- | apps/user_ldap/l10n/ca.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/cs_CZ.php | 45 | ||||
-rw-r--r-- | apps/user_ldap/l10n/de.php | 3 | ||||
-rw-r--r-- | apps/user_ldap/l10n/eo.php | 2 | ||||
-rw-r--r-- | apps/user_ldap/l10n/es.php | 30 | ||||
-rw-r--r-- | apps/user_ldap/l10n/eu.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/fi_FI.php | 20 | ||||
-rw-r--r-- | apps/user_ldap/l10n/fr.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/it.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/ja_JP.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/pl.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/ro.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/ru.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/sl.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/sv.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/l10n/th_TH.php | 1 | ||||
-rw-r--r-- | apps/user_ldap/settings.php | 6 | ||||
-rw-r--r-- | apps/user_ldap/templates/settings.php | 4 | ||||
-rw-r--r-- | apps/user_ldap/tests/group_ldap.php | 4 | ||||
-rw-r--r-- | apps/user_ldap/user_ldap.php | 10 |
24 files changed, 100 insertions, 47 deletions
diff --git a/apps/user_ldap/appinfo/install.php b/apps/user_ldap/appinfo/install.php index 9efc3bb24d2..378957ec409 100644 --- a/apps/user_ldap/appinfo/install.php +++ b/apps/user_ldap/appinfo/install.php @@ -1,6 +1,6 @@ <?php $state = OCP\Config::getSystemValue('ldapIgnoreNamingRules', 'doSet'); -if($state == 'doSet'){ +if($state == 'doSet') { OCP\Config::setSystemValue('ldapIgnoreNamingRules', false); } diff --git a/apps/user_ldap/appinfo/update.php b/apps/user_ldap/appinfo/update.php index f06655c1dc1..f23285a0dc6 100644 --- a/apps/user_ldap/appinfo/update.php +++ b/apps/user_ldap/appinfo/update.php @@ -18,7 +18,7 @@ if(!is_null($pw)) { //detect if we can switch on naming guidelines. We won't do it on conflicts. //it's a bit spaghetti, but hey. $state = OCP\Config::getSystemValue('ldapIgnoreNamingRules', 'unset'); -if($state == 'unset'){ +if($state == 'unset') { OCP\Config::setSystemValue('ldapIgnoreNamingRules', false); } @@ -34,7 +34,7 @@ $groupBE = new \OCA\user_ldap\GROUP_LDAP(); $groupBE->setConnector($connector); foreach($objects as $object) { - $fetchDNSql = 'SELECT `ldap_dn` FROM `*PREFIX*ldap_'.$object.'_mapping`'; + $fetchDNSql = 'SELECT `ldap_dn`, `owncloud_name` FROM `*PREFIX*ldap_'.$object.'_mapping` WHERE `directory_uuid` = ""'; $updateSql = 'UPDATE `*PREFIX*ldap_'.$object.'_mapping` SET `ldap_DN` = ?, `directory_uuid` = ? WHERE `ldap_dn` = ?'; $query = OCP\DB::prepare($fetchDNSql); @@ -45,6 +45,8 @@ foreach($objects as $object) { $newDN = mb_strtolower($dn['ldap_dn'], 'UTF-8'); if($object == 'user') { $uuid = $userBE->getUUID($newDN); + //fix home folder to avoid new ones depending on the configuration + $userBE->getHome($dn['owncloud_name']); } else { $uuid = $groupBE->getUUID($newDN); } diff --git a/apps/user_ldap/appinfo/version b/apps/user_ldap/appinfo/version index e689e4949ef..444b3e8a75a 100644 --- a/apps/user_ldap/appinfo/version +++ b/apps/user_ldap/appinfo/version @@ -1 +1 @@ -0.2.0.26
\ No newline at end of file +0.2.0.30
\ No newline at end of file diff --git a/apps/user_ldap/group_ldap.php b/apps/user_ldap/group_ldap.php index aac3ed78917..5ec259f6c47 100644 --- a/apps/user_ldap/group_ldap.php +++ b/apps/user_ldap/group_ldap.php @@ -231,7 +231,7 @@ class GROUP_LDAP extends lib\Access implements \OCP\GroupInterface { * @param string $gid * @return bool */ - public function groupExists($gid){ + public function groupExists($gid) { if($this->connection->isCached('groupExists'.$gid)) { return $this->connection->getFromCache('groupExists'.$gid); } diff --git a/apps/user_ldap/l10n/ca.php b/apps/user_ldap/l10n/ca.php index 04b0f8997db..be72912040d 100644 --- a/apps/user_ldap/l10n/ca.php +++ b/apps/user_ldap/l10n/ca.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Atribut LDAP a usar per generar el nom de grup ownCloud.", "in bytes" => "en bytes", "in seconds. A change empties the cache." => "en segons. Un canvi buidarà la memòria de cau.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Deixeu-ho buit pel nom d'usuari (per defecte). Altrament, especifiqueu un atribut LDAP/AD.", "Help" => "Ajuda" ); diff --git a/apps/user_ldap/l10n/cs_CZ.php b/apps/user_ldap/l10n/cs_CZ.php index 6c0f227fa7a..c90dc9ed568 100644 --- a/apps/user_ldap/l10n/cs_CZ.php +++ b/apps/user_ldap/l10n/cs_CZ.php @@ -1,36 +1,37 @@ <?php $TRANSLATIONS = array( -"Host" => "Hostitel", -"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Nelze vynechat protokol vyžadující SSL. Začněte s ldaps://", -"Base DN" => "Base DN", -"You can specify Base DN for users and groups in the Advanced tab" => "V Rozšířeném nastavení můžete specifikovat pro své uživatele a skupiny element Base DN", -"User DN" => "DN uživatele", +"Host" => "Počítač", +"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Můžete vynechat protokol, vyjma pokud požadujete SSL. Tehdy začněte s ldaps://", +"Base DN" => "Základní DN", +"You can specify Base DN for users and groups in the Advanced tab" => "V rozšířeném nastavení můžete určit základní DN pro uživatele a skupiny", +"User DN" => "Uživatelské DN", "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." => "DN klentského uživatele ke kterému tvoříte vazbu, např. uid=agent,dc=example,dc=com. Pro anonymní přístup ponechte údaje DN and Heslo prázdné.", "Password" => "Heslo", -"For anonymous access, leave DN and Password empty." => "Pro anonymní přístup ponechte údaje DN and Heslo prázdné.", -"User Login Filter" => "Filtr uživatelských loginů", -"Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action." => "Definuje filtr, který je aplikován v průběhu logování. %%uid nahrazuje uživatelské jméno během logování.", -"use %%uid placeholder, e.g. \"uid=%%uid\"" => "použijte %%uid pro rezervované místo, např. \"uid=%%uid\"", -"User List Filter" => "Filtr uživateslkých seznamů", -"Defines the filter to apply, when retrieving users." => "Defunije filtr, který je plaikován při návratu uživatelů.", -"without any placeholder, e.g. \"objectClass=person\"." => "bez rezervace místa, např. \"objectClass=person\".", -"Group Filter" => "Filtr skupiny", -"Defines the filter to apply, when retrieving groups." => "Definuje filtr, který je aplikován při návratu skupin", -"without any placeholder, e.g. \"objectClass=posixGroup\"." => "bez rezervace místa, např. \"objectClass=posixGroup\".", +"For anonymous access, leave DN and Password empty." => "Pro anonymní přístup, ponechte údaje DN and heslo prázdné.", +"User Login Filter" => "Filtr přihlášení uživatelů", +"Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action." => "Určuje použitý filtr, při pokusu o přihlášení. %%uid nahrazuje uživatelské jméno v činnosti přihlášení.", +"use %%uid placeholder, e.g. \"uid=%%uid\"" => "použijte zástupný vzor %%uid, např. \"uid=%%uid\"", +"User List Filter" => "Filtr uživatelských seznamů", +"Defines the filter to apply, when retrieving users." => "Určuje použitý filtr, pro získávaní uživatelů.", +"without any placeholder, e.g. \"objectClass=person\"." => "bez zástupných znaků, např. \"objectClass=person\".", +"Group Filter" => "Filtr skupin", +"Defines the filter to apply, when retrieving groups." => "Určuje použitý filtr, pro získávaní skupin.", +"without any placeholder, e.g. \"objectClass=posixGroup\"." => "bez zástupných znaků, např. \"objectClass=posixGroup\".", "Port" => "Port", "Base User Tree" => "Základní uživatelský strom", "Base Group Tree" => "Základní skupinový strom", "Group-Member association" => "Asociace člena skupiny", -"Use TLS" => "Použijte TLS", -"Do not use it for SSL connections, it will fail." => "Nepoužívejte pro SSL připojení, připojení selže.", +"Use TLS" => "Použít TLS", +"Do not use it for SSL connections, it will fail." => "Nepoužívejte pro připojení pomocí SSL, připojení selže.", "Case insensitve LDAP server (Windows)" => "LDAP server nerozlišující velikost znaků (Windows)", -"Turn off SSL certificate validation." => "Vypněte ověřování SSL certifikátu", -"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "pokud pracuje připojení pouze pokud je teto volba aktivní, importujte SSL certifikát LDAP serveru do Vašeho serveru ownCloud.", -"Not recommended, use for testing only." => "Není doporučeno, pouze pro účely testování.", +"Turn off SSL certificate validation." => "Vypnout ověřování SSL certifikátu.", +"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Pokud připojení pracuje pouze s touto možností, tak importujte SSL certifikát SSL serveru do Vašeho serveru ownCloud", +"Not recommended, use for testing only." => "Není doporučeno, pouze pro testovací účely.", "User Display Name Field" => "Pole pro zobrazované jméno uživatele", "The LDAP attribute to use to generate the user`s ownCloud name." => "Atribut LDAP použitý k vytvoření jména uživatele ownCloud", "Group Display Name Field" => "Pole pro zobrazení jména skupiny", "The LDAP attribute to use to generate the groups`s ownCloud name." => "Atribut LDAP použitý k vytvoření jména skupiny ownCloud", -"in bytes" => "v bytech", -"in seconds. A change empties the cache." => "ve vteřinách. Změna vyprázdní dočasnou paměť.", +"in bytes" => "v bajtech", +"in seconds. A change empties the cache." => "ve vteřinách. Změna vyprázdní vyrovnávací paměť.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Ponechte prázdné pro uživatelské jméno (výchozí). Jinak uveďte LDAP/AD parametr.", "Help" => "Nápověda" ); diff --git a/apps/user_ldap/l10n/de.php b/apps/user_ldap/l10n/de.php index 9f917f277c4..2c178d0b4fd 100644 --- a/apps/user_ldap/l10n/de.php +++ b/apps/user_ldap/l10n/de.php @@ -23,7 +23,7 @@ "Use TLS" => "Nutze TLS", "Do not use it for SSL connections, it will fail." => "Verwenden Sie es nicht für SSL-Verbindungen, es wird fehlschlagen.", "Case insensitve LDAP server (Windows)" => "LDAP-Server (Windows: Groß- und Kleinschreibung bleibt unbeachtet)", -"Turn off SSL certificate validation." => "Schalte die SSL Zertifikatsprüfung aus.", +"Turn off SSL certificate validation." => "Schalte die SSL-Zertifikatsprüfung aus.", "If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Falls die Verbindung es erfordert, wird das SSL-Zertifikat des LDAP-Server importiert werden.", "Not recommended, use for testing only." => "Nicht empfohlen, nur zu Testzwecken.", "User Display Name Field" => "Feld für den Anzeigenamen des Benutzers", @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Das LDAP-Attribut für die Generierung des Gruppennamens in ownCloud. ", "in bytes" => "in Bytes", "in seconds. A change empties the cache." => "in Sekunden. Eine Änderung leert den Cache.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Ohne Eingabe wird der Benutzername (Standard) verwendet. Anderenfalls geben Sie ein LDAP/AD-Attribut an.", "Help" => "Hilfe" ); diff --git a/apps/user_ldap/l10n/eo.php b/apps/user_ldap/l10n/eo.php index 6f18506b095..683c60ef840 100644 --- a/apps/user_ldap/l10n/eo.php +++ b/apps/user_ldap/l10n/eo.php @@ -17,6 +17,7 @@ "Port" => "Pordo", "Base User Tree" => "Baza uzantarbo", "Base Group Tree" => "Baza gruparbo", +"Group-Member association" => "Asocio de grupo kaj membro", "Use TLS" => "Uzi TLS-on", "Do not use it for SSL connections, it will fail." => "Ne uzu ĝin por SSL-konektoj, ĝi malsukcesos.", "Case insensitve LDAP server (Windows)" => "LDAP-servilo blinda je litergrandeco (Vindozo)", @@ -28,5 +29,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "La atributo de LDAP uzota por generi la ownCloud-an nomon de la grupo.", "in bytes" => "duumoke", "in seconds. A change empties the cache." => "sekunde. Ajna ŝanĝo malplenigas la kaŝmemoron.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Lasu malplena por uzantonomo (defaŭlto). Alie, specifu LDAP/AD-atributon.", "Help" => "Helpo" ); diff --git a/apps/user_ldap/l10n/es.php b/apps/user_ldap/l10n/es.php index 55abf7b88e0..c89ceb8eee2 100644 --- a/apps/user_ldap/l10n/es.php +++ b/apps/user_ldap/l10n/es.php @@ -1,7 +1,37 @@ <?php $TRANSLATIONS = array( +"Host" => "Servidor", +"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Puede omitir el protocolo, excepto si requiere SSL. En ese caso, empiece con ldaps://", +"Base DN" => "DN base", +"You can specify Base DN for users and groups in the Advanced tab" => "Puede especificar el DN base para usuarios y grupos en la pestaña Avanzado", +"User DN" => "DN usuario", +"The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." => "El DN del usuario cliente con el que se hará la asociación, p.ej. uid=agente,dc=ejemplo,dc=com. Para acceso anónimo, deje DN y contraseña vacíos.", "Password" => "Contraseña", +"For anonymous access, leave DN and Password empty." => "Para acceso anónimo, deje DN y contraseña vacíos.", +"User Login Filter" => "Filtro de inicio de sesión de usuario", +"Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action." => "Define el filtro a aplicar cuando se ha realizado un login. %%uid remplazrá el nombre de usuario en el proceso de login.", +"use %%uid placeholder, e.g. \"uid=%%uid\"" => "usar %%uid como placeholder, ej: \"uid=%%uid\"", +"User List Filter" => "Lista de filtros de usuario", +"Defines the filter to apply, when retrieving users." => "Define el filtro a aplicar, cuando se obtienen usuarios.", +"without any placeholder, e.g. \"objectClass=person\"." => "Sin placeholder, ej: \"objectClass=person\".", +"Group Filter" => "Filtro de grupo", +"Defines the filter to apply, when retrieving groups." => "Define el filtro a aplicar, cuando se obtienen grupos.", +"without any placeholder, e.g. \"objectClass=posixGroup\"." => "Con cualquier placeholder, ej: \"objectClass=posixGroup\".", "Port" => "Puerto", +"Base User Tree" => "Árbol base de usuario", +"Base Group Tree" => "Árbol base de grupo", +"Group-Member association" => "Asociación Grupo-Miembro", "Use TLS" => "Usar TLS", +"Do not use it for SSL connections, it will fail." => "No usarlo para SSL, habrá error.", +"Case insensitve LDAP server (Windows)" => "Servidor de LDAP sensible a mayúsculas/minúsculas (Windows)", +"Turn off SSL certificate validation." => "Apagar la validación por certificado SSL.", +"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Si la conexión sólo funciona con esta opción, importe el certificado SSL del servidor LDAP en su servidor ownCloud.", +"Not recommended, use for testing only." => "No recomendado, sólo para pruebas.", +"User Display Name Field" => "Campo de nombre de usuario a mostrar", +"The LDAP attribute to use to generate the user`s ownCloud name." => "El atributo LDAP a usar para generar el nombre de usuario de ownCloud.", +"Group Display Name Field" => "Campo de nombre de grupo a mostrar", +"The LDAP attribute to use to generate the groups`s ownCloud name." => "El atributo LDAP a usar para generar el nombre de los grupos de ownCloud.", "in bytes" => "en bytes", +"in seconds. A change empties the cache." => "en segundos. Un cambio vacía la cache.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Vacío para el nombre de usuario (por defecto). En otro caso, especifique un atributo LDAP/AD.", "Help" => "Ayuda" ); diff --git a/apps/user_ldap/l10n/eu.php b/apps/user_ldap/l10n/eu.php index cc042b13892..35dacef3f2f 100644 --- a/apps/user_ldap/l10n/eu.php +++ b/apps/user_ldap/l10n/eu.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "ownCloud taldearen izena sortzeko erabiliko den LDAP atributua", "in bytes" => "bytetan", "in seconds. A change empties the cache." => "segundutan. Aldaketak katxea husten du.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Utzi hutsik erabiltzaile izenarako (lehentsia). Bestela zehaztu LDAP/AD atributua.", "Help" => "Laguntza" ); diff --git a/apps/user_ldap/l10n/fi_FI.php b/apps/user_ldap/l10n/fi_FI.php index f6d16f3acc1..24195649a64 100644 --- a/apps/user_ldap/l10n/fi_FI.php +++ b/apps/user_ldap/l10n/fi_FI.php @@ -1,13 +1,14 @@ <?php $TRANSLATIONS = array( "Host" => "Isäntä", -"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Voit jättää protokollan määrittämättä, paitsi kun käytät SSL:ää. Aloita silloin ldaps://", +"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Voit jättää protokollan määrittämättä, paitsi kun vaadit SSL:ää. Aloita silloin ldaps://", "Base DN" => "Oletus DN", -"You can specify Base DN for users and groups in the Advanced tab" => "Voit määrittää käyttäjien ja ryhmien oletus DN:n (distinguished name) 'tarkemmat asetukset' välilehdeltä ", +"You can specify Base DN for users and groups in the Advanced tab" => "Voit määrittää käyttäjien ja ryhmien oletus DN:n (distinguished name) 'tarkemmat asetukset'-välilehdeltä ", "User DN" => "Käyttäjän DN", "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." => "Asiakasohjelman DN, jolla yhdistäminen tehdään, ts. uid=agent,dc=example,dc=com. Mahdollistaaksesi anonyymin yhteyden, jätä DN ja salasana tyhjäksi.", "Password" => "Salasana", "For anonymous access, leave DN and Password empty." => "Jos haluat mahdollistaa anonyymin pääsyn, jätä DN ja Salasana tyhjäksi ", "User Login Filter" => "Login suodatus", +"Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action." => "Määrittelee käytettävän suodattimen, kun sisäänkirjautumista yritetään. %%uid korvaa sisäänkirjautumisessa käyttäjätunnuksen.", "use %%uid placeholder, e.g. \"uid=%%uid\"" => "käytä %%uid paikanvaraajaa, ts. \"uid=%%uid\"", "User List Filter" => "Käyttäjien suodatus", "Defines the filter to apply, when retrieving users." => "Määrittelee käytettävän suodattimen, kun käyttäjiä haetaan. ", @@ -16,16 +17,21 @@ "Defines the filter to apply, when retrieving groups." => "Määrittelee käytettävän suodattimen, kun ryhmiä haetaan. ", "without any placeholder, e.g. \"objectClass=posixGroup\"." => "ilman paikanvaraustermiä, ts. \"objectClass=posixGroup\".", "Port" => "Portti", -"Base User Tree" => "Oletus käyttäjäpuu", +"Base User Tree" => "Oletuskäyttäjäpuu", "Base Group Tree" => "Ryhmien juuri", -"Group-Member association" => "Ryhmä-jäsen assosiaatio (yhteys)", +"Group-Member association" => "Ryhmän ja jäsenen assosiaatio (yhteys)", "Use TLS" => "Käytä TLS:ää", -"Do not use it for SSL connections, it will fail." => "Älä käytä SSL yhteyttä varten, se epäonnistuu. ", +"Do not use it for SSL connections, it will fail." => "Älä käytä SSL-yhteyttä varten, se epäonnistuu. ", "Case insensitve LDAP server (Windows)" => "Kirjainkoosta piittamaton LDAP-palvelin (Windows)", -"Turn off SSL certificate validation." => "Sulje SSL sertifikaatin käyttö", -"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Jos yhteys toimii vain tällä optiolla, siirrä LDAP palvelimen SSL sertifikaatti onwCloud palvelimellesi. ", +"Turn off SSL certificate validation." => "Poista käytöstä SSL-varmenteen vahvistus", +"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Jos yhteys toimii vain tällä valinnalla, siirrä LDAP-palvelimen SSL-varmenne ownCloud-palvelimellesi.", "Not recommended, use for testing only." => "Ei suositella, käytä vain testausta varten.", +"User Display Name Field" => "Käyttäjän näytettävän nimen kenttä", +"The LDAP attribute to use to generate the user`s ownCloud name." => "LDAP-attribuutti, jota käytetään käyttäjän ownCloud-käyttäjänimenä ", +"Group Display Name Field" => "Ryhmän \"näytettävä nimi\"-kenttä", +"The LDAP attribute to use to generate the groups`s ownCloud name." => "LDAP-attribuutti, jota käytetään luomaan ryhmän ownCloud-nimi", "in bytes" => "tavuissa", "in seconds. A change empties the cache." => "sekunneissa. Muutos tyhjentää välimuistin.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Jätä tyhjäksi käyttäjänimi (oletusasetus). Muutoin anna LDAP/AD-atribuutti.", "Help" => "Ohje" ); diff --git a/apps/user_ldap/l10n/fr.php b/apps/user_ldap/l10n/fr.php index 0754aa01de8..a0b1c6b7d9c 100644 --- a/apps/user_ldap/l10n/fr.php +++ b/apps/user_ldap/l10n/fr.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "L'attribut LDAP utilisé pour générer les noms de groupes d'ownCloud.", "in bytes" => "en octets", "in seconds. A change empties the cache." => "en secondes. Tout changement vide le cache.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Laisser vide ", "Help" => "Aide" ); diff --git a/apps/user_ldap/l10n/it.php b/apps/user_ldap/l10n/it.php index c86b4ea2a57..f07f0aa5a42 100644 --- a/apps/user_ldap/l10n/it.php +++ b/apps/user_ldap/l10n/it.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "L'attributo LDAP da usare per generare il nome del gruppo ownCloud.", "in bytes" => "in byte", "in seconds. A change empties the cache." => "in secondi. Il cambio svuota la cache.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Lascia vuoto per il nome utente (predefinito). Altrimenti, specifica un attributo LDAP/AD.", "Help" => "Aiuto" ); diff --git a/apps/user_ldap/l10n/ja_JP.php b/apps/user_ldap/l10n/ja_JP.php index 8d4473b4e28..c8599f56362 100644 --- a/apps/user_ldap/l10n/ja_JP.php +++ b/apps/user_ldap/l10n/ja_JP.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "グループのownCloud名の生成に利用するLDAP属性。", "in bytes" => "バイト", "in seconds. A change empties the cache." => "秒。変更後にキャッシュがクリアされます。", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "ユーザ名を空のままにしてください(デフォルト)。そうでない場合は、LDAPもしくはADの属性を指定してください.", "Help" => "ヘルプ" ); diff --git a/apps/user_ldap/l10n/pl.php b/apps/user_ldap/l10n/pl.php index fa7618d68dc..7ebebe1e073 100644 --- a/apps/user_ldap/l10n/pl.php +++ b/apps/user_ldap/l10n/pl.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Atrybut LDAP służy do generowania nazwy grup ownCloud.", "in bytes" => "w bajtach", "in seconds. A change empties the cache." => "w sekundach. Zmiana opróżnia pamięć podręczną.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Pozostaw puste dla user name (domyślnie). W przeciwnym razie podaj atrybut LDAP/AD.", "Help" => "Pomoc" ); diff --git a/apps/user_ldap/l10n/ro.php b/apps/user_ldap/l10n/ro.php index 326e47f96fe..beeed857455 100644 --- a/apps/user_ldap/l10n/ro.php +++ b/apps/user_ldap/l10n/ro.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Atributul LDAP folosit pentru a genera numele grupurilor din ownCloud", "in bytes" => "în octeți", "in seconds. A change empties the cache." => "în secunde. O schimbare curăță memoria tampon.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Lăsați gol pentru numele de utilizator (implicit). În caz contrar, specificați un atribut LDAP / AD.", "Help" => "Ajutor" ); diff --git a/apps/user_ldap/l10n/ru.php b/apps/user_ldap/l10n/ru.php index 65ef8f47f42..92982d868b8 100644 --- a/apps/user_ldap/l10n/ru.php +++ b/apps/user_ldap/l10n/ru.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Атрибут LDAP для генерации имени группы ownCloud.", "in bytes" => "в байтах", "in seconds. A change empties the cache." => "в секундах. Изменение очистит кэш.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Оставьте имя пользователя пустым (по умолчанию). Иначе укажите атрибут LDAP/AD.", "Help" => "Помощь" ); diff --git a/apps/user_ldap/l10n/sl.php b/apps/user_ldap/l10n/sl.php index 312346958be..fd28b640156 100644 --- a/apps/user_ldap/l10n/sl.php +++ b/apps/user_ldap/l10n/sl.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "LDAP atribut uporabljen pri ustvarjanju ownCloud imen skupin.", "in bytes" => "v bajtih", "in seconds. A change empties the cache." => "v sekundah. Sprememba izprazni predpomnilnik.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Pustite prazno za uporabniško ime (privzeto). V nasprotnem primeru navedite LDAP/AD atribut.", "Help" => "Pomoč" ); diff --git a/apps/user_ldap/l10n/sv.php b/apps/user_ldap/l10n/sv.php index a23cc094b4d..2a0abb92967 100644 --- a/apps/user_ldap/l10n/sv.php +++ b/apps/user_ldap/l10n/sv.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "Attribut som används för att generera gruppnamn i ownCloud.", "in bytes" => "i bytes", "in seconds. A change empties the cache." => "i sekunder. En förändring tömmer cache.", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Lämnas tomt för användarnamn (standard). Ange annars ett LDAP/AD-attribut.", "Help" => "Hjälp" ); diff --git a/apps/user_ldap/l10n/th_TH.php b/apps/user_ldap/l10n/th_TH.php index a1baa648135..acc7a4936bc 100644 --- a/apps/user_ldap/l10n/th_TH.php +++ b/apps/user_ldap/l10n/th_TH.php @@ -32,5 +32,6 @@ "The LDAP attribute to use to generate the groups`s ownCloud name." => "คุณลักษณะ LDAP ที่ต้องการใช้สร้างชื่อกลุ่มของ ownCloud", "in bytes" => "ในหน่วยไบต์", "in seconds. A change empties the cache." => "ในอีกไม่กี่วินาที ระบบจะเปลี่ยนแปลงข้อมูลในแคชให้ว่างเปล่า", +"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "เว้นว่างไว้สำหรับ ชื่อผู้ใช้ (ค่าเริ่มต้น) หรือไม่กรุณาระบุคุณลักษณะของ LDAP/AD", "Help" => "ช่วยเหลือ" ); diff --git a/apps/user_ldap/settings.php b/apps/user_ldap/settings.php index 23018890eac..f765151456a 100644 --- a/apps/user_ldap/settings.php +++ b/apps/user_ldap/settings.php @@ -26,8 +26,8 @@ OCP\Util::addscript('user_ldap', 'settings'); OCP\Util::addstyle('user_ldap', 'settings'); if ($_POST) { - foreach($params as $param){ - if(isset($_POST[$param])){ + foreach($params as $param) { + if(isset($_POST[$param])) { if('ldap_agent_password' == $param) { OCP\Config::setAppValue('user_ldap', $param, base64_encode($_POST[$param])); } elseif('ldap_cache_ttl' == $param) { @@ -58,7 +58,7 @@ if ($_POST) { // fill template $tmpl = new OCP\Template( 'user_ldap', 'settings'); -foreach($params as $param){ +foreach($params as $param) { $value = OCP\Config::getAppValue('user_ldap', $param,''); $tmpl->assign($param, $value); } diff --git a/apps/user_ldap/templates/settings.php b/apps/user_ldap/templates/settings.php index d1aaeedbdf9..3a653ad7208 100644 --- a/apps/user_ldap/templates/settings.php +++ b/apps/user_ldap/templates/settings.php @@ -23,8 +23,8 @@ <p><label for="ldap_turn_off_cert_check"><?php echo $l->t('Turn off SSL certificate validation.');?></label><input type="checkbox" id="ldap_turn_off_cert_check" name="ldap_turn_off_cert_check" title="<?php echo $l->t('If connection only works with this option, import the LDAP server\'s SSL certificate in your ownCloud server.');?>" value="1"<?php if ($_['ldap_turn_off_cert_check']) echo ' checked'; ?>><br/><small><?php echo $l->t('Not recommended, use for testing only.');?></small></p> <p><label for="ldap_display_name"><?php echo $l->t('User Display Name Field');?></label><input type="text" id="ldap_display_name" name="ldap_display_name" value="<?php echo $_['ldap_display_name']; ?>" title="<?php echo $l->t('The LDAP attribute to use to generate the user`s ownCloud name.');?>" /></p> <p><label for="ldap_group_display_name"><?php echo $l->t('Group Display Name Field');?></label><input type="text" id="ldap_group_display_name" name="ldap_group_display_name" value="<?php echo $_['ldap_group_display_name']; ?>" title="<?php echo $l->t('The LDAP attribute to use to generate the groups`s ownCloud name.');?>" /></p> - <p><label for="ldap_quota_attr">Quota Field</label><input type="text" id="ldap_quota_attr" name="ldap_quota_attr" value="<?php echo $_['ldap_quota_attr']; ?>" /> - <label for="ldap_quota_def">Quota Default</label><input type="text" id="ldap_quota_def" name="ldap_quota_def" value="<?php if (isset($_['ldap_quota_def'])) echo $_['ldap_quota_def']; ?>" title="<?php echo $l->t('in bytes');?>" /></p> + <p><label for="ldap_quota_attr">Quota Field</label><input type="text" id="ldap_quota_attr" name="ldap_quota_attr" value="<?php echo $_['ldap_quota_attr']; ?>" /></p> + <p><label for="ldap_quota_def">Quota Default</label><input type="text" id="ldap_quota_def" name="ldap_quota_def" value="<?php if (isset($_['ldap_quota_def'])) echo $_['ldap_quota_def']; ?>" title="<?php echo $l->t('in bytes');?>" /></p> <p><label for="ldap_email_attr">Email Field</label><input type="text" id="ldap_email_attr" name="ldap_email_attr" value="<?php echo $_['ldap_email_attr']; ?>" /></p> <p><label for="ldap_cache_ttl">Cache Time-To-Live</label><input type="text" id="ldap_cache_ttl" name="ldap_cache_ttl" value="<?php echo $_['ldap_cache_ttl']; ?>" title="<?php echo $l->t('in seconds. A change empties the cache.');?>" /></p> <p><label for="home_folder_naming_rule">User Home Folder Naming Rule</label><input type="text" id="home_folder_naming_rule" name="home_folder_naming_rule" value="<?php echo $_['home_folder_naming_rule']; ?>" title="<?php echo $l->t('Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute.');?>" /></p> diff --git a/apps/user_ldap/tests/group_ldap.php b/apps/user_ldap/tests/group_ldap.php index ac66a608b76..b953127d86e 100644 --- a/apps/user_ldap/tests/group_ldap.php +++ b/apps/user_ldap/tests/group_ldap.php @@ -21,11 +21,11 @@ */ class Test_Group_Ldap extends UnitTestCase { - function setUp(){ + function setUp() { OC_Group::clearBackends(); } - function testSingleBackend(){ + function testSingleBackend() { OC_Group::useBackend(new OCA\user_ldap\GROUP_LDAP()); $group_ldap = new OCA\user_ldap\GROUP_LDAP(); diff --git a/apps/user_ldap/user_ldap.php b/apps/user_ldap/user_ldap.php index d297374600a..bacdb8b9ae1 100644 --- a/apps/user_ldap/user_ldap.php +++ b/apps/user_ldap/user_ldap.php @@ -65,7 +65,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface { * * Check if the password is correct without logging in the user */ - public function checkPassword($uid, $password){ + public function checkPassword($uid, $password) { //find out dn of the user name $filter = \OCP\Util::mb_str_replace('%uid', $uid, $this->connection->ldapLoginFilter, 'UTF-8'); $ldap_users = $this->fetchListOfUsers($filter, 'dn'); @@ -82,7 +82,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface { //do we have a username for him/her? $ocname = $this->dn2username($dn); - if($ocname){ + if($ocname) { //update some settings, if necessary $this->updateQuota($dn); $this->updateEmail($dn); @@ -100,7 +100,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface { * * Get a list of all users. */ - public function getUsers($search = '', $limit = 10, $offset = 0){ + public function getUsers($search = '', $limit = 10, $offset = 0) { $ldap_users = $this->connection->getFromCache('getUsers'); if(is_null($ldap_users)) { $ldap_users = $this->fetchListOfUsers($this->connection->ldapUserFilter, array($this->connection->ldapUserDisplayName, 'dn')); @@ -126,7 +126,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface { * @param string $uid the username * @return boolean */ - public function userExists($uid){ + public function userExists($uid) { if($this->connection->isCached('userExists'.$uid)) { return $this->connection->getFromCache('userExists'.$uid); } @@ -187,7 +187,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface { * @param string $uid the username * @return boolean */ - public function getHome($uid){ + public function getHome($uid) { if($this->userExists($uid)) { $homedir = \OCP\Config::getUserValue($uid, 'user_ldap', 'homedir', false); if(!$homedir) { |