summaryrefslogtreecommitdiffstats
path: root/apps/files_encryption
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files_encryption')
-rw-r--r--apps/files_encryption/hooks/hooks.php16
-rw-r--r--apps/files_encryption/l10n/cs_CZ.php1
-rw-r--r--apps/files_encryption/l10n/de.php1
-rw-r--r--apps/files_encryption/l10n/gl.php1
-rw-r--r--apps/files_encryption/l10n/it.php1
-rw-r--r--apps/files_encryption/l10n/pt_BR.php1
-rw-r--r--apps/files_encryption/l10n/pt_PT.php10
-rw-r--r--apps/files_encryption/l10n/sl.php2
-rw-r--r--apps/files_encryption/l10n/sv.php1
-rwxr-xr-xapps/files_encryption/tests/share.php9
10 files changed, 32 insertions, 11 deletions
diff --git a/apps/files_encryption/hooks/hooks.php b/apps/files_encryption/hooks/hooks.php
index b2a17f6bca5..741df166b70 100644
--- a/apps/files_encryption/hooks/hooks.php
+++ b/apps/files_encryption/hooks/hooks.php
@@ -238,6 +238,7 @@ class Hooks {
*/
public static function preShared($params) {
+ $l = new \OC_L10N('files_encryption');
$users = array();
$view = new \OC\Files\View('/public-keys/');
@@ -250,21 +251,18 @@ class Hooks {
break;
}
- $error = false;
+ $notConfigured = array();
foreach ($users as $user) {
if (!$view->file_exists($user . '.public.key')) {
- $error = true;
- break;
+ $notConfigured[] = $user;
}
}
- if ($error) // Set flag var 'run' to notify emitting
- // script that hook execution failed
- {
- $params['run']->run = false;
+ if (count($notConfigured) > 0) {
+ $params['run'] = false;
+ $params['error'] = $l->t('Following users are not set up for encryption:') . ' ' . join(', ' , $notConfigured);
}
- // TODO: Make sure files_sharing provides user
- // feedback on failed share
+
}
/**
diff --git a/apps/files_encryption/l10n/cs_CZ.php b/apps/files_encryption/l10n/cs_CZ.php
index 7b2ce2d65c5..4dd06280d87 100644
--- a/apps/files_encryption/l10n/cs_CZ.php
+++ b/apps/files_encryption/l10n/cs_CZ.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Váš soukromý klíč není platný! Pravděpodobně bylo heslo změněno zvně systému ownCloud (např. ve vašem firemním adresáři). Můžete opravit vaše heslo soukromého klíče ve svém osobním nastavení pro obnovení přístupu k vašim zašifrovaným souborům.",
"Missing requirements." => "Nesplněné závislosti.",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Ujistěte se prosím, že máte nainstalované PHP verze PHP 5.3.3 s nainstalovaným a správně nastaveným rozšířením OpenSSL. Prozatím byla šifrovací aplikace zablokována.",
+"Following users are not set up for encryption:" => "Následující uživatelé nejsou připraveni k zakódování:",
"Saving..." => "Ukládám...",
"Your private key is not valid! Maybe the your password was changed from outside." => "Váš soukromý klíč není platný! Pravděpodobně bylo vaše heslo změněno zvenčí.",
"You can unlock your private key in your " => "Můžete odemknout váš soukromý klíč ve vašem",
diff --git a/apps/files_encryption/l10n/de.php b/apps/files_encryption/l10n/de.php
index d8265906db5..69b15aa00a8 100644
--- a/apps/files_encryption/l10n/de.php
+++ b/apps/files_encryption/l10n/de.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Dein privater Schlüssel ist ungültig. Möglicher Weise wurde von außerhalb Dein Passwort geändert (z.B. in deinem gemeinsamen Verzeichnis). Du kannst das Passwort deines privaten Schlüssels in den persönlichen Einstellungen aktualisieren, um wieder an deine Dateien zu gelangen.",
"Missing requirements." => "Fehlende Vorraussetzungen",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Bitte stellen Sie sicher, dass PHP 5.3.3 oder neuer installiert ist und die OpenSSL-PHP-Erweiterung aktiviert und richtig konfiguriert ist. Die Verschlüsselungsanwendung wurde vorerst deaktiviert.",
+"Following users are not set up for encryption:" => "Für folgende Nutzer ist keine Verschlüsselung eingerichtet:",
"Saving..." => "Speichern...",
"Your private key is not valid! Maybe the your password was changed from outside." => "Ihr privater Schlüssel ist ungültig! Eventuell wurde Ihr Passwort von außerhalb geändert.",
"You can unlock your private key in your " => "Du kannst den privaten Schlüssel ändern und zwar in deinem",
diff --git a/apps/files_encryption/l10n/gl.php b/apps/files_encryption/l10n/gl.php
index db6f57bb36d..7b3ad526734 100644
--- a/apps/files_encryption/l10n/gl.php
+++ b/apps/files_encryption/l10n/gl.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "A chave privada non é correcta! É probábel que o seu contrasinal teña sido cambiado desde o exterior (p.ex. o seu directorio corporativo). Vostede pode actualizar o contrasinal da súa chave privada nos seus axustes persoais para recuperar o acceso aos seus ficheiros",
"Missing requirements." => "Non se cumpren os requisitos.",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Asegúrese de que está instalado o PHP 5.3.3 ou posterior e de que a extensión OpenSSL PHP estea activada e configurada correctamente. Polo de agora foi desactivado o aplicativo de cifrado.",
+"Following users are not set up for encryption:" => "Os seguintes usuarios non teñen configuración para o cifrado:",
"Saving..." => "Gardando...",
"Your private key is not valid! Maybe the your password was changed from outside." => "A chave privada non é correcta! É probábel que o seu contrasinal teña sido cambiado desde o exterior. ",
"You can unlock your private key in your " => "Pode desbloquear a chave privada nos seus",
diff --git a/apps/files_encryption/l10n/it.php b/apps/files_encryption/l10n/it.php
index 8d15d1ced36..db1a1b1709a 100644
--- a/apps/files_encryption/l10n/it.php
+++ b/apps/files_encryption/l10n/it.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "La chiave privata non è valida! Forse la password è stata cambiata esternamente al sistema di ownCloud (ad es. la directory aziendale). Puoi aggiornare la password della chiave privata nelle impostazioni personali per ottenere nuovamente l'accesso ai file.",
"Missing requirements." => "Requisiti mancanti.",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Assicurati che sia installato PHP 5.3.3 o versioni successive e che l'estensione OpenSSL di PHP sia abilitata e configurata correttamente. Per ora, l'applicazione di cifratura è disabilitata.",
+"Following users are not set up for encryption:" => "I seguenti utenti non sono configurati per la cifratura:",
"Saving..." => "Salvataggio in corso...",
"Your private key is not valid! Maybe the your password was changed from outside." => "La tua chiave privata non è valida! Forse è stata modifica dall'esterno.",
"You can unlock your private key in your " => "Puoi sbloccare la chiave privata nelle tue",
diff --git a/apps/files_encryption/l10n/pt_BR.php b/apps/files_encryption/l10n/pt_BR.php
index 1563243c993..3404ce4a542 100644
--- a/apps/files_encryption/l10n/pt_BR.php
+++ b/apps/files_encryption/l10n/pt_BR.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Sua chave privada não é válida! Provavelmente sua senha foi alterada fora do sistema ownCloud (por exemplo, seu diretório corporativo). Você pode atualizar sua senha de chave privada em suas configurações pessoais para recuperar o acesso a seus arquivos criptografados.",
"Missing requirements." => "Requisitos em falta.",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Por favor, certifique-se que o PHP 5.3.3 ou mais recente está instalado e que a extensão PHP OpenSSL está habilitado e configurado corretamente. Por enquanto, o aplicativo de criptografia foi desativado.",
+"Following users are not set up for encryption:" => "Seguintes usuários não estão configurados para criptografia:",
"Saving..." => "Salvando...",
"Your private key is not valid! Maybe the your password was changed from outside." => "Sua chave privada não é válida! Talvez sua senha tenha sido mudada.",
"You can unlock your private key in your " => "Você pode desbloquear sua chave privada nas suas",
diff --git a/apps/files_encryption/l10n/pt_PT.php b/apps/files_encryption/l10n/pt_PT.php
index d3cf596fda5..15a9ee6de63 100644
--- a/apps/files_encryption/l10n/pt_PT.php
+++ b/apps/files_encryption/l10n/pt_PT.php
@@ -5,15 +5,25 @@
"Could not disable recovery key. Please check your recovery key password!" => "Não foi possível desactivar a chave de recuperação. Por favor verifique a password da chave de recuperação.",
"Password successfully changed." => "Password alterada com sucesso.",
"Could not change the password. Maybe the old password was not correct." => "Não foi possivel alterar a password. Possivelmente a password antiga não está correcta.",
+"Could not update the private key password. Maybe the old password was not correct." => "Não foi possível alterar a chave. Possivelmente a password antiga não está correcta.",
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Chave privada não é válida! Provavelmente senha foi alterada fora do sistema ownCloud (exemplo, o diretório corporativo). Pode atualizar password da chave privada em configurações personalizadas para recuperar o acesso aos seus arquivos encriptados.",
+"Missing requirements." => "Faltam alguns requisitos.",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Por favor, certifique-se que PHP 5.3.3 ou mais recente está instalado e que a extensão PHP OpenSSL está ativada e corretamente configurada. Por agora, a encripitação está desativado.",
"Saving..." => "A guardar...",
"personal settings" => "configurações personalizadas ",
"Encryption" => "Encriptação",
+"Enable recovery key (allow to recover users files in case of password loss):" => "Active a chave de recuperação (permite recuperar os ficheiros no caso de perda da password):",
+"Recovery key password" => "Chave de recuperação da conta",
"Enabled" => "Activado",
"Disabled" => "Desactivado",
+"Change recovery key password:" => "Alterar a chave de recuperação:",
+"Old Recovery key password" => "Chave anterior de recuperação da conta",
+"New Recovery key password" => "Nova chave de recuperação da conta",
"Change Password" => "Mudar a Password",
+"Old log-in password" => "Password anterior da conta",
+"Current log-in password" => "Password actual da conta",
"Enable password recovery:" => "ativar recuperação do password:",
+"Enabling this option will allow you to reobtain access to your encrypted files in case of password loss" => "Ao activar esta opção, tornar-lhe-a possível a obtenção de acesso aos seus ficheiros encriptados caso perca a password.",
"File recovery settings updated" => "Actualizadas as definições de recuperação de ficheiros",
"Could not update file recovery" => "Não foi possível actualizar a recuperação de ficheiros"
);
diff --git a/apps/files_encryption/l10n/sl.php b/apps/files_encryption/l10n/sl.php
index 8b28ba01155..016937c1415 100644
--- a/apps/files_encryption/l10n/sl.php
+++ b/apps/files_encryption/l10n/sl.php
@@ -8,6 +8,8 @@
"Private key password successfully updated." => "Zasebni ključ za geslo je bil uspešno posodobljen.",
"Could not update the private key password. Maybe the old password was not correct." => "Zasebnega ključa za geslo ni bilo mogoče posodobiti. Morda vnos starega gesla ni bil pravilen.",
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Vaš zasebni ključ ni veljaven. Morda je bilo vaše geslo spremenjeno zunaj sistema ownCloud (npr. v skupnem imeniku). Svoj zasebni ključ, ki vam bo omogočil dostop do šifriranih dokumentov, lahko posodobite v osebnih nastavitvah.",
+"Missing requirements." => "Manjkajoče zahteve",
+"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Preverite, da imate na strežniku nameščen PHP 5.3.3 ali novejši in da je omogočen in pravilno nastavljen PHP OpenSSL . Zaenkrat je šifriranje onemogočeno.",
"Saving..." => "Poteka shranjevanje ...",
"Your private key is not valid! Maybe the your password was changed from outside." => "Vaš zasebni ključ ni veljaven. Morda je bilo vaše geslo spremenjeno.",
"You can unlock your private key in your " => "Svoj zasebni ključ lahko odklenite v",
diff --git a/apps/files_encryption/l10n/sv.php b/apps/files_encryption/l10n/sv.php
index 2cef6686fce..785d46cdc76 100644
--- a/apps/files_encryption/l10n/sv.php
+++ b/apps/files_encryption/l10n/sv.php
@@ -10,6 +10,7 @@
"Your private key is not valid! Likely your password was changed outside the ownCloud system (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." => "Din privata lösenordsnyckel är inte giltig! Troligen har ditt lösenord ändrats utanför ownCloud (t.ex. i företagets katalogtjänst). Du kan uppdatera den privata lösenordsnyckeln under dina personliga inställningar för att återfå tillgång till dina filer.",
"Missing requirements." => "Krav som saknas",
"Please make sure that PHP 5.3.3 or newer is installed and that the OpenSSL PHP extension is enabled and configured properly. For now, the encryption app has been disabled." => "Kontrollera att PHP 5.3.3 eller senare är installerad och att tillägget OpenSSL PHP är aktiverad och rätt inställd. Kryperingsappen är därför tillsvidare inaktiverad.",
+"Following users are not set up for encryption:" => "Följande användare har inte aktiverat kryptering:",
"Saving..." => "Sparar...",
"Your private key is not valid! Maybe the your password was changed from outside." => "Din privata lösenordsnyckel är inte giltig! Kanske byttes ditt lösenord från utsidan.",
"You can unlock your private key in your " => "Du kan låsa upp din privata nyckel i dina",
diff --git a/apps/files_encryption/tests/share.php b/apps/files_encryption/tests/share.php
index ebf678da78e..5f3d5005090 100755
--- a/apps/files_encryption/tests/share.php
+++ b/apps/files_encryption/tests/share.php
@@ -881,8 +881,13 @@ class Test_Encryption_Share extends \PHPUnit_Framework_TestCase {
\OC_FileProxy::$enabled = $proxyStatus;
// share the file
- \OCP\Share::shareItem('file', $fileInfo['fileid'], \OCP\Share::SHARE_TYPE_GROUP, \Test_Encryption_Share::TEST_ENCRYPTION_SHARE_GROUP1, OCP\PERMISSION_ALL);
-
+ try {
+ \OCP\Share::shareItem('file', $fileInfo['fileid'], \OCP\Share::SHARE_TYPE_GROUP, \Test_Encryption_Share::TEST_ENCRYPTION_SHARE_GROUP1, OCP\PERMISSION_ALL);
+ } catch (Exception $e) {
+ $this->assertEquals(0, strpos($e->getMessage(), "Following users are not set up for encryption"));
+ }
+
+
// login as admin
\Test_Encryption_Util::loginHelper(\Test_Encryption_Share::TEST_ENCRYPTION_SHARE_USER1);