summaryrefslogtreecommitdiffstats
path: root/apps/user_ldap
diff options
context:
space:
mode:
Diffstat (limited to 'apps/user_ldap')
-rw-r--r--apps/user_ldap/ajax/deleteConfiguration.php4
-rw-r--r--apps/user_ldap/l10n/de_DE.php28
-rw-r--r--apps/user_ldap/l10n/fa.php9
-rw-r--r--apps/user_ldap/l10n/fi_FI.php8
-rw-r--r--apps/user_ldap/l10n/gl.php33
-rw-r--r--apps/user_ldap/lib/connection.php7
-rw-r--r--apps/user_ldap/user_ldap.php7
7 files changed, 74 insertions, 22 deletions
diff --git a/apps/user_ldap/ajax/deleteConfiguration.php b/apps/user_ldap/ajax/deleteConfiguration.php
index b7d633a049d..ade57110d34 100644
--- a/apps/user_ldap/ajax/deleteConfiguration.php
+++ b/apps/user_ldap/ajax/deleteConfiguration.php
@@ -27,9 +27,9 @@ OCP\JSON::checkAppEnabled('user_ldap');
OCP\JSON::callCheck();
$prefix = $_POST['ldap_serverconfig_chooser'];
-if(\OCA\user_ldap\lib\Helper::deleteServerConfiguration($prefix)){
+if(\OCA\user_ldap\lib\Helper::deleteServerConfiguration($prefix)) {
OCP\JSON::success();
} else {
$l=OC_L10N::get('user_ldap');
OCP\JSON::error(array('message' => $l->t('Failed to delete the server configuration')));
-} \ No newline at end of file
+}
diff --git a/apps/user_ldap/l10n/de_DE.php b/apps/user_ldap/l10n/de_DE.php
index 69faf5dc45d..45edda2debb 100644
--- a/apps/user_ldap/l10n/de_DE.php
+++ b/apps/user_ldap/l10n/de_DE.php
@@ -1,20 +1,20 @@
<?php $TRANSLATIONS = array(
"Failed to delete the server configuration" => "Das Löschen der Server-Konfiguration schlug fehl",
-"The configuration is valid and the connection could be established!" => "Die Konfiguration ist valide und eine Verbindung konnte hergestellt werden!",
-"The configuration is valid, but the Bind failed. Please check the server settings and credentials." => "Die Konfiguration ist valide, aber das Herstellen einer Verbindung schlug fehl. Bitte überprüfen Sie die Server-Einstellungen und Zertifikate.",
-"The configuration is invalid. Please look in the ownCloud log for further details." => "Die Konfiguration ist nicht valide. Weitere Details können Sie im ownCloud-Log nachlesen.",
+"The configuration is valid and the connection could be established!" => "Die Konfiguration ist gültig und die Verbindung konnte hergestellt werden!",
+"The configuration is valid, but the Bind failed. Please check the server settings and credentials." => "Die Konfiguration ist gültig, aber das Herstellen der Verbindung schlug fehl. Bitte überprüfen Sie die Server-Einstellungen und Zertifikate.",
+"The configuration is invalid. Please look in the ownCloud log for further details." => "Die Konfiguration ist ungültig. Weitere Details können Sie im ownCloud-Log nachlesen.",
"Deletion failed" => "Löschen fehlgeschlagen",
-"Take over settings from recent server configuration?" => "Sollen die Einstellungen der letzten Server-Konfiguration übernommen werden?",
+"Take over settings from recent server configuration?" => "Sollen die Einstellungen der letzten Serverkonfiguration übernommen werden?",
"Keep settings?" => "Einstellungen behalten?",
-"Cannot add server configuration" => "Das Hinzufügen der Server-Konfiguration schlug fehl",
-"Connection test succeeded" => "Verbindungs-Test erfolgreich",
-"Connection test failed" => "Verbindungs-Test fehlgeschlagen",
-"Do you really want to delete the current Server Configuration?" => "Möchten Sie wirklich die Server-Konfiguration löschen?",
+"Cannot add server configuration" => "Das Hinzufügen der Serverkonfiguration schlug fehl",
+"Connection test succeeded" => "Verbindungstest erfolgreich",
+"Connection test failed" => "Verbindungstest fehlgeschlagen",
+"Do you really want to delete the current Server Configuration?" => "Möchten Sie die Serverkonfiguration wirklich löschen?",
"Confirm Deletion" => "Löschung bestätigen",
"<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behaviour. Please ask your system administrator to disable one of them." => "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann demzufolge zu unerwarteten Verhalten kommen. Bitten Sie Ihren Systemadministator eine der beiden Anwendungen zu deaktivieren.",
"<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." => "<b>Warnung:</b> Da das PHP-Modul für LDAP ist nicht installiert, das Backend wird nicht funktionieren. Bitten Sie Ihren Systemadministrator das Modul zu installieren.",
-"Server configuration" => "Server-Konfiguration",
-"Add Server Configuration" => "Server-Konfiguration hinzufügen",
+"Server configuration" => "Serverkonfiguration",
+"Add Server Configuration" => "Serverkonfiguration hinzufügen",
"Host" => "Host",
"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Sie können das Protokoll auslassen, außer wenn Sie SSL benötigen. Beginnen Sie dann mit ldaps://",
"Base DN" => "Basis-DN",
@@ -33,7 +33,7 @@
"Group Filter" => "Gruppen-Filter",
"Defines the filter to apply, when retrieving groups." => "Definiert den Filter für die Anfrage der Gruppen.",
"without any placeholder, e.g. \"objectClass=posixGroup\"." => "ohne Platzhalter, z.B.: \"objectClass=posixGroup\"",
-"Connection Settings" => "Verbindungs-Einstellungen",
+"Connection Settings" => "Verbindungseinstellungen",
"Configuration Active" => "Konfiguration aktiv",
"When unchecked, this configuration will be skipped." => "Wenn nicht angehakt, wird diese Konfiguration übersprungen.",
"Port" => "Port",
@@ -41,7 +41,7 @@
"Give an optional backup host. It must be a replica of the main LDAP/AD server." => "Optionaler Backup Host. Es muss ein Replikat des eigentlichen LDAP/AD Servers sein.",
"Backup (Replica) Port" => "Back-Up (Replikation) Port",
"Disable Main Server" => "Hauptserver deaktivieren",
-"When switched on, ownCloud will only connect to the replica server." => "Wenn eingeschaltet wird sich ownCloud nur mit dem Replilat-Server verbinden.",
+"When switched on, ownCloud will only connect to the replica server." => "Wenn eingeschaltet wird sich ownCloud nur mit dem Replikat-Server verbinden.",
"Use TLS" => "Nutze TLS",
"Do not use it additionally for LDAPS connections, it will fail." => "Benutze es nicht zusätzlich für LDAPS Verbindungen, es wird scheitern.",
"Case insensitve LDAP server (Windows)" => "LDAP-Server (Windows: Groß- und Kleinschreibung bleibt unbeachtet)",
@@ -49,7 +49,7 @@
"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Falls die Verbindung es erfordert, muss das SSL-Zertifikat des LDAP-Server importiert werden.",
"Not recommended, use for testing only." => "Nicht empfohlen, nur zu Testzwecken.",
"in seconds. A change empties the cache." => "in Sekunden. Eine Änderung leert den Cache.",
-"Directory Settings" => "Verzeichnis-Einstellungen",
+"Directory Settings" => "Verzeichniseinstellungen",
"User Display Name Field" => "Feld für den Anzeigenamen des Benutzers",
"The LDAP attribute to use to generate the user`s ownCloud name." => "Das LDAP-Attribut für die Generierung des Benutzernamens in ownCloud. ",
"Base User Tree" => "Basis-Benutzerbaum",
@@ -62,7 +62,7 @@
"One Group Base DN per line" => "Ein Gruppen Base DN pro Zeile",
"Group Search Attributes" => "Gruppen-Suche Eigenschaften",
"Group-Member association" => "Assoziation zwischen Gruppe und Benutzer",
-"Special Attributes" => "besondere Eigenschaften",
+"Special Attributes" => "Besondere Eigenschaften",
"in bytes" => "in Bytes",
"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Ohne Eingabe wird der Benutzername (Standard) verwendet. Anderenfall trage ein LDAP/AD-Attribut ein.",
"Help" => "Hilfe"
diff --git a/apps/user_ldap/l10n/fa.php b/apps/user_ldap/l10n/fa.php
index 7ddd7dad5c3..7816ef7c6f7 100644
--- a/apps/user_ldap/l10n/fa.php
+++ b/apps/user_ldap/l10n/fa.php
@@ -1,8 +1,17 @@
<?php $TRANSLATIONS = array(
+"Failed to delete the server configuration" => "عملیات حذف پیکربندی سرور ناموفق ماند",
+"The configuration is valid and the connection could be established!" => "پیکربندی معتبر است و ارتباط می تواند برقرار شود",
"Deletion failed" => "حذف کردن انجام نشد",
"Keep settings?" => "آیا تنظیمات ذخیره شود ؟",
+"Connection test succeeded" => "تست اتصال با موفقیت انجام گردید",
+"Connection test failed" => "تست اتصال ناموفق بود",
+"Do you really want to delete the current Server Configuration?" => "آیا واقعا می خواهید پیکربندی کنونی سرور را حذف کنید؟",
+"Confirm Deletion" => "تایید حذف",
+"Server configuration" => "پیکربندی سرور",
+"Add Server Configuration" => "افزودن پیکربندی سرور",
"Host" => "میزبانی",
"Password" => "رمز عبور",
"Port" => "درگاه",
+"in bytes" => "در بایت",
"Help" => "راه‌نما"
);
diff --git a/apps/user_ldap/l10n/fi_FI.php b/apps/user_ldap/l10n/fi_FI.php
index 1c2a92f844a..bfbd6c78564 100644
--- a/apps/user_ldap/l10n/fi_FI.php
+++ b/apps/user_ldap/l10n/fi_FI.php
@@ -1,5 +1,10 @@
<?php $TRANSLATIONS = array(
"Deletion failed" => "Poisto epäonnistui",
+"Keep settings?" => "Säilytetäänkö asetukset?",
+"Cannot add server configuration" => "Palvelinasetusten lisäys epäonnistui",
+"Connection test succeeded" => "Yhteystesti onnistui",
+"Connection test failed" => "Yhteystesti epäonnistui",
+"Confirm Deletion" => "Vahvista poisto",
"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 vaadit SSL:ää. Aloita silloin ldaps://",
"Base DN" => "Oletus DN",
@@ -17,13 +22,16 @@
"Group Filter" => "Ryhmien suodatus",
"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\".",
+"Connection Settings" => "Yhteysasetukset",
"Port" => "Portti",
+"Disable Main Server" => "Poista pääpalvelin käytöstä",
"Use TLS" => "Käytä TLS:ää",
"Case insensitve LDAP server (Windows)" => "Kirjainkoosta piittamaton LDAP-palvelin (Windows)",
"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.",
"in seconds. A change empties the cache." => "sekunneissa. Muutos tyhjentää välimuistin.",
+"Directory Settings" => "Hakemistoasetukset",
"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ä ",
"Base User Tree" => "Oletuskäyttäjäpuu",
diff --git a/apps/user_ldap/l10n/gl.php b/apps/user_ldap/l10n/gl.php
index 36c1f7af114..2d07f3215ef 100644
--- a/apps/user_ldap/l10n/gl.php
+++ b/apps/user_ldap/l10n/gl.php
@@ -1,9 +1,24 @@
<?php $TRANSLATIONS = array(
+"Failed to delete the server configuration" => "Non foi posíbel eliminar a configuración do servidor",
+"The configuration is valid and the connection could be established!" => "A configuración é correcta e pode estabelecerse a conexión.",
+"The configuration is valid, but the Bind failed. Please check the server settings and credentials." => "A configuración é correcta, mais a ligazón non. Comprobe a configuración do servidor e as credenciais.",
+"The configuration is invalid. Please look in the ownCloud log for further details." => "A configuración non é correcta. Vexa o rexistro de ownCloud para máis detalles",
"Deletion failed" => "Fallou o borrado",
+"Take over settings from recent server configuration?" => "Tomar os recentes axustes de configuración do servidor?",
+"Keep settings?" => "Manter os axustes?",
+"Cannot add server configuration" => "Non é posíbel engadir a configuración do servidor",
+"Connection test succeeded" => "A proba de conexión foi satisfactoria",
+"Connection test failed" => "A proba de conexión fracasou",
+"Do you really want to delete the current Server Configuration?" => "Confirma que quere eliminar a configuración actual do servidor?",
+"Confirm Deletion" => "Confirmar a eliminación",
"<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behaviour. Please ask your system administrator to disable one of them." => "<b>Aviso:</b> Os aplicativos user_ldap e user_webdavauth son incompatíbeis. Pode acontecer un comportamento estraño. Consulte co administrador do sistema para desactivar un deles.",
+"<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." => "<b>Aviso:</b> O módulo PHP LDAP non está instalado, o servidor non funcionará. Consulte co administrador do sistema para instalalo.",
+"Server configuration" => "Configuración do servidor",
+"Add Server Configuration" => "Engadir a configuración do servidor",
"Host" => "Servidor",
"You can omit the protocol, except you require SSL. Then start with ldaps://" => "Pode omitir o protocolo agás que precise de SSL. Nese caso comece con ldaps://",
"Base DN" => "DN base",
+"One Base DN per line" => "Un DN base por liña",
"You can specify Base DN for users and groups in the Advanced tab" => "Pode especificar a DN base para usuarios e grupos na lapela de «Avanzado»",
"User DN" => "DN do 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." => "O DN do cliente do usuario co que hai que estabelecer unha conexión, p.ex uid=axente, dc=exemplo, dc=com. Para o acceso anónimo deixe o DN e o contrasinal baleiros.",
@@ -18,20 +33,36 @@
"Group Filter" => "Filtro de grupo",
"Defines the filter to apply, when retrieving groups." => "Define o filtro a aplicar cando se recompilan os grupos.",
"without any placeholder, e.g. \"objectClass=posixGroup\"." => "sen ningunha marca de posición, como p.ex «objectClass=grupoPosix».",
+"Connection Settings" => "Axustes da conexión",
+"Configuration Active" => "Configuración activa",
+"When unchecked, this configuration will be skipped." => "Se está sen marcar, omítese esta configuración.",
"Port" => "Porto",
+"Backup (Replica) Host" => "Servidor da copia de seguranza (Réplica)",
+"Give an optional backup host. It must be a replica of the main LDAP/AD server." => "Indicar un servidor de copia de seguranza opcional. Debe ser unha réplica do servidor principal LDAP/AD.",
+"Backup (Replica) Port" => "Porto da copia de seguranza (Réplica)",
+"Disable Main Server" => "Desactivar o servidor principal",
+"When switched on, ownCloud will only connect to the replica server." => "Cando está activado, ownCloud só se conectará ao servidor de réplica.",
"Use TLS" => "Usar TLS",
+"Do not use it additionally for LDAPS connections, it will fail." => "Non utilizalo ademais para conexións LDAPS xa que fallará.",
"Case insensitve LDAP server (Windows)" => "Servidor LDAP que non distingue entre maiúsculas e minúsculas (Windows)",
"Turn off SSL certificate validation." => "Desactiva a validación do certificado SSL.",
-"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Se a conexión só funciona con esta opción importa o certificado SSL do servidor LDAP no seu servidor ownCloud.",
+"If connection only works with this option, import the LDAP server's SSL certificate in your ownCloud server." => "Se a conexión só funciona con esta opción importe o certificado SSL do servidor LDAP no seu servidor ownCloud.",
"Not recommended, use for testing only." => "Non se recomenda. Só para probas.",
"in seconds. A change empties the cache." => "en segundos. Calquera cambio baleira a caché.",
+"Directory Settings" => "Axustes do directorio",
"User Display Name Field" => "Campo de mostra do nome de usuario",
"The LDAP attribute to use to generate the user`s ownCloud name." => "O atributo LDAP a empregar para xerar o nome de usuario de ownCloud.",
"Base User Tree" => "Base da árbore de usuarios",
+"One User Base DN per line" => "Un DN base de usuario por liña",
+"User Search Attributes" => "Atributos de busca do usuario",
+"Optional; one attribute per line" => "Opcional; un atributo por liña",
"Group Display Name Field" => "Campo de mostra do nome de grupo",
"The LDAP attribute to use to generate the groups`s ownCloud name." => "O atributo LDAP úsase para xerar os nomes dos grupos de ownCloud.",
"Base Group Tree" => "Base da árbore de grupo",
+"One Group Base DN per line" => "Un DN base de grupo por liña",
+"Group Search Attributes" => "Atributos de busca do grupo",
"Group-Member association" => "Asociación de grupos e membros",
+"Special Attributes" => "Atributos especiais",
"in bytes" => "en bytes",
"Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." => "Deixar baleiro para o nome de usuario (predeterminado). Noutro caso, especifique un atributo LDAP/AD.",
"Help" => "Axuda"
diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php
index 63cd5e78da5..abbc133038c 100644
--- a/apps/user_ldap/lib/connection.php
+++ b/apps/user_ldap/lib/connection.php
@@ -193,7 +193,7 @@ class Connection {
private function getValue($varname) {
static $defaults;
- if(is_null($defaults)){
+ if(is_null($defaults)) {
$defaults = $this->getDefaults();
}
return \OCP\Config::getAppValue($this->configID,
@@ -323,7 +323,8 @@ class Connection {
foreach($config as $parameter => $value) {
if(($parameter == 'homeFolderNamingRule'
- || $params[$parameter] == 'homeFolderNamingRule')
+ || (isset($params[$parameter])
+ && $params[$parameter] == 'homeFolderNamingRule'))
&& !empty($value)) {
$value = 'attr:'.$value;
}
@@ -364,7 +365,7 @@ class Connection {
case 'ldapBaseGroups':
case 'ldapAttributesForUserSearch':
case 'ldapAttributesForGroupSearch':
- if(is_array($value)){
+ if(is_array($value)) {
$value = implode("\n", $value);
}
break;
diff --git a/apps/user_ldap/user_ldap.php b/apps/user_ldap/user_ldap.php
index 2b247362448..44a19478598 100644
--- a/apps/user_ldap/user_ldap.php
+++ b/apps/user_ldap/user_ldap.php
@@ -227,7 +227,7 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface {
$this->connection->ldapUserDisplayName);
if($displayName && (count($displayName) > 0)) {
- $this->connection->writeToCache($cacheKey, $displayName);
+ $this->connection->writeToCache($cacheKey, $displayName[0]);
return $displayName[0];
}
@@ -264,7 +264,10 @@ class USER_LDAP extends lib\Access implements \OCP\UserInterface {
* compared with OC_USER_BACKEND_CREATE_USER etc.
*/
public function implementsActions($actions) {
- return (bool)((OC_USER_BACKEND_CHECK_PASSWORD | OC_USER_BACKEND_GET_HOME) & $actions);
+ return (bool)((OC_USER_BACKEND_CHECK_PASSWORD
+ | OC_USER_BACKEND_GET_HOME
+ | OC_USER_BACKEND_GET_DISPLAYNAME)
+ & $actions);
}
/**