aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.htaccess1
-rw-r--r--.user.ini1
-rw-r--r--apps/files/controller/apicontroller.php6
-rw-r--r--apps/files/js/tagsplugin.js16
-rw-r--r--apps/files/l10n/cs_CZ.js1
-rw-r--r--apps/files/l10n/cs_CZ.json1
-rw-r--r--apps/files/l10n/da.js1
-rw-r--r--apps/files/l10n/da.json1
-rw-r--r--apps/files/l10n/de.js1
-rw-r--r--apps/files/l10n/de.json1
-rw-r--r--apps/files/l10n/de_DE.js1
-rw-r--r--apps/files/l10n/de_DE.json1
-rw-r--r--apps/files/l10n/en@pirate.js4
-rw-r--r--apps/files/l10n/en@pirate.json4
-rw-r--r--apps/files/l10n/en_GB.js1
-rw-r--r--apps/files/l10n/en_GB.json1
-rw-r--r--apps/files/l10n/es.js1
-rw-r--r--apps/files/l10n/es.json1
-rw-r--r--apps/files/l10n/fi_FI.js1
-rw-r--r--apps/files/l10n/fi_FI.json1
-rw-r--r--apps/files/l10n/fr.js5
-rw-r--r--apps/files/l10n/fr.json5
-rw-r--r--apps/files/l10n/gl.js1
-rw-r--r--apps/files/l10n/gl.json1
-rw-r--r--apps/files/l10n/it.js1
-rw-r--r--apps/files/l10n/it.json1
-rw-r--r--apps/files/l10n/jv.js4
-rw-r--r--apps/files/l10n/jv.json4
-rw-r--r--apps/files/l10n/ko.js1
-rw-r--r--apps/files/l10n/ko.json1
-rw-r--r--apps/files/l10n/nl.js1
-rw-r--r--apps/files/l10n/nl.json1
-rw-r--r--apps/files/l10n/pt_BR.js1
-rw-r--r--apps/files/l10n/pt_BR.json1
-rw-r--r--apps/files/l10n/pt_PT.js1
-rw-r--r--apps/files/l10n/pt_PT.json1
-rw-r--r--apps/files/l10n/ru.js1
-rw-r--r--apps/files/l10n/ru.json1
-rw-r--r--apps/files/l10n/sk_SK.js1
-rw-r--r--apps/files/l10n/sk_SK.json1
-rw-r--r--apps/files/l10n/sr.js1
-rw-r--r--apps/files/l10n/sr.json1
-rw-r--r--apps/files/l10n/tr.js1
-rw-r--r--apps/files/l10n/tr.json1
-rw-r--r--apps/files/l10n/uk.js1
-rw-r--r--apps/files/l10n/uk.json1
-rw-r--r--apps/files_encryption/l10n/de.js2
-rw-r--r--apps/files_encryption/l10n/de.json2
-rw-r--r--apps/files_encryption/l10n/pt_PT.js2
-rw-r--r--apps/files_encryption/l10n/pt_PT.json2
-rw-r--r--apps/files_encryption/l10n/uk.js1
-rw-r--r--apps/files_encryption/l10n/uk.json1
-rw-r--r--apps/files_external/appinfo/app.php142
-rw-r--r--apps/files_external/appinfo/application.php33
-rw-r--r--apps/files_external/appinfo/routes.php20
-rw-r--r--apps/files_external/controller/ajaxcontroller.php48
-rw-r--r--apps/files_external/js/dropbox.js5
-rw-r--r--apps/files_external/js/google.js5
-rw-r--r--apps/files_external/js/sftp_key.js53
-rw-r--r--apps/files_external/l10n/ja.js2
-rw-r--r--apps/files_external/l10n/ja.json2
-rw-r--r--apps/files_external/lib/sftp.php21
-rw-r--r--apps/files_external/lib/sftp_key.php194
-rw-r--r--apps/files_external/tests/README.md58
-rw-r--r--apps/files_external/tests/backends/sftp_key.php85
-rw-r--r--apps/files_external/tests/config.php10
-rw-r--r--apps/files_sharing/l10n/ja.js5
-rw-r--r--apps/files_sharing/l10n/ja.json5
-rw-r--r--apps/files_sharing/lib/cache.php8
-rw-r--r--apps/files_sharing/lib/controllers/sharecontroller.php2
-rw-r--r--apps/files_sharing/lib/sharedstorage.php2
-rw-r--r--apps/files_versions/l10n/de.js2
-rw-r--r--apps/files_versions/l10n/de.json2
-rw-r--r--apps/files_versions/l10n/de_DE.js2
-rw-r--r--apps/files_versions/l10n/de_DE.json2
-rw-r--r--apps/user_ldap/ajax/wizard.php2
-rw-r--r--apps/user_ldap/js/settings.js14
-rw-r--r--apps/user_ldap/lib/access.php14
-rw-r--r--apps/user_ldap/lib/wizard.php20
-rw-r--r--apps/user_ldap/user_ldap.php2
-rw-r--r--config/config.sample.php4
-rw-r--r--core/css/share.css7
-rw-r--r--core/js/js.js2
-rw-r--r--core/l10n/de.js8
-rw-r--r--core/l10n/de.json8
-rw-r--r--core/l10n/de_DE.js4
-rw-r--r--core/l10n/de_DE.json4
-rw-r--r--core/l10n/es.js1
-rw-r--r--core/l10n/es.json1
-rw-r--r--core/l10n/fr.js6
-rw-r--r--core/l10n/fr.json6
-rw-r--r--core/l10n/ru.js3
-rw-r--r--core/l10n/ru.json3
-rw-r--r--core/l10n/sk_SK.js6
-rw-r--r--core/l10n/sk_SK.json6
-rw-r--r--l10n/l10n.pl2
-rw-r--r--lib/l10n/de.js54
-rw-r--r--lib/l10n/de.json54
-rw-r--r--lib/l10n/de_DE.js16
-rw-r--r--lib/l10n/de_DE.json16
-rw-r--r--lib/l10n/ja.js2
-rw-r--r--lib/l10n/ja.json2
-rw-r--r--lib/l10n/uk.js1
-rw-r--r--lib/l10n/uk.json1
-rw-r--r--lib/private/app.php15
-rw-r--r--lib/private/appconfig.php2
-rw-r--r--lib/private/appframework/core/api.php4
-rw-r--r--lib/private/appframework/http/request.php52
-rw-r--r--lib/private/avatar.php9
-rw-r--r--lib/private/cache/file.php2
-rw-r--r--lib/private/cache/fileglobal.php2
-rw-r--r--lib/private/config.php7
-rw-r--r--lib/private/files/cache/cache.php4
-rw-r--r--lib/private/files/cache/wrapper/cachejail.php2
-rw-r--r--lib/private/files/cache/wrapper/cachewrapper.php4
-rw-r--r--lib/private/files/fileinfo.php7
-rw-r--r--lib/private/files/storage/common.php8
-rw-r--r--lib/private/helper.php7
-rw-r--r--lib/private/hook.php2
-rw-r--r--lib/private/installer.php1
-rw-r--r--lib/private/legacy/preferences.php121
-rw-r--r--lib/private/log/owncloud.php2
-rw-r--r--lib/private/naturalsort.php17
-rw-r--r--lib/private/ocs.php2
-rw-r--r--lib/private/preferences.php181
-rw-r--r--lib/private/repair.php2
-rw-r--r--lib/private/request.php12
-rw-r--r--lib/private/server.php7
-rw-r--r--lib/private/share/share.php11
-rw-r--r--lib/private/tags.php6
-rw-r--r--lib/private/template.php2
-rw-r--r--lib/private/tempmanager.php14
-rw-r--r--lib/private/util.php26
-rw-r--r--lib/public/appframework/apicontroller.php10
-rw-r--r--lib/public/appframework/http/ocsresponse.php99
-rw-r--r--lib/public/appframework/ocscontroller.php103
-rw-r--r--lib/public/files/storage.php30
-rw-r--r--lib/public/iappconfig.php2
-rw-r--r--lib/public/iavatar.php7
-rw-r--r--lib/public/irequest.php7
-rw-r--r--lib/public/itags.php6
-rw-r--r--lib/public/share_backend.php2
-rw-r--r--lib/repair/enablefilesapp.php50
-rw-r--r--settings/l10n/de.js10
-rw-r--r--settings/l10n/de.json10
-rw-r--r--settings/l10n/de_DE.js6
-rw-r--r--settings/l10n/de_DE.json6
-rw-r--r--settings/l10n/ja.js12
-rw-r--r--settings/l10n/ja.json12
-rw-r--r--settings/l10n/sk_SK.js3
-rw-r--r--settings/l10n/sk_SK.json3
-rw-r--r--settings/l10n/sr.js2
-rw-r--r--settings/l10n/sr.json2
-rw-r--r--tests/lib/appframework/controller/ApiControllerTest.php9
-rw-r--r--tests/lib/appframework/controller/ControllerTest.php17
-rw-r--r--tests/lib/appframework/controller/OCSControllerTest.php134
-rw-r--r--tests/lib/appframework/dependencyinjection/DIContainerTest.php5
-rw-r--r--tests/lib/appframework/http/DispatcherTest.php132
-rw-r--r--tests/lib/appframework/http/OCSResponseTest.php73
-rw-r--r--tests/lib/appframework/http/RequestTest.php68
-rw-r--r--tests/lib/appframework/middleware/MiddlewareDispatcherTest.php12
-rw-r--r--tests/lib/appframework/middleware/MiddlewareTest.php10
-rw-r--r--tests/lib/appframework/middleware/security/CORSMiddlewareTest.php23
-rw-r--r--tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php12
-rw-r--r--tests/lib/appframework/middleware/sessionmiddlewaretest.php5
165 files changed, 1684 insertions, 802 deletions
diff --git a/.htaccess b/.htaccess
index 78e6255c878..cf9af3f72d1 100644
--- a/.htaccess
+++ b/.htaccess
@@ -13,6 +13,7 @@ php_value post_max_size 513M
php_value memory_limit 512M
php_value mbstring.func_overload 0
php_value always_populate_raw_post_data -1
+php_value default_charset 'UTF-8'
<IfModule mod_env.c>
SetEnv htaccessWorking true
</IfModule>
diff --git a/.user.ini b/.user.ini
index 09f6a05ff6c..ef440b53fe5 100644
--- a/.user.ini
+++ b/.user.ini
@@ -3,3 +3,4 @@ post_max_size=513M
memory_limit=512M
mbstring.func_overload=0
always_populate_raw_post_data=-1
+default_charset='UTF-8'
diff --git a/apps/files/controller/apicontroller.php b/apps/files/controller/apicontroller.php
index a8bea27e4bb..1bb07010a27 100644
--- a/apps/files/controller/apicontroller.php
+++ b/apps/files/controller/apicontroller.php
@@ -76,11 +76,11 @@ class ApiController extends Controller {
try {
$this->tagService->updateFileTags($path, $tags);
} catch (\OCP\Files\NotFoundException $e) {
- return new DataResponse($e->getMessage(), Http::STATUS_NOT_FOUND);
+ return new DataResponse(['message' => $e->getMessage()], Http::STATUS_NOT_FOUND);
} catch (\OCP\Files\StorageNotAvailableException $e) {
- return new DataResponse($e->getMessage(), Http::STATUS_SERVICE_UNAVAILABLE);
+ return new DataResponse(['message' => $e->getMessage()], Http::STATUS_SERVICE_UNAVAILABLE);
} catch (\Exception $e) {
- return new DataResponse($e->getMessage(), Http::STATUS_NOT_FOUND);
+ return new DataResponse(['message' => $e->getMessage()], Http::STATUS_NOT_FOUND);
}
$result['tags'] = $tags;
}
diff --git a/apps/files/js/tagsplugin.js b/apps/files/js/tagsplugin.js
index 27ab3eced04..293e25176f3 100644
--- a/apps/files/js/tagsplugin.js
+++ b/apps/files/js/tagsplugin.js
@@ -109,7 +109,9 @@
self.applyFileTags(
dir + '/' + fileName,
- tags
+ tags,
+ $actionEl,
+ isFavorite
).then(function(result) {
// response from server should contain updated tags
var newTags = result.tags;
@@ -157,8 +159,10 @@
*
* @param {String} fileName path to the file or folder to tag
* @param {Array.<String>} tagNames array of tag names
+ * @param {Object} $actionEl element
+ * @param {boolean} isFavorite Was the item favorited before
*/
- applyFileTags: function(fileName, tagNames) {
+ applyFileTags: function(fileName, tagNames, $actionEl, isFavorite) {
var encodedPath = OC.encodePath(fileName);
while (encodedPath[0] === '/') {
encodedPath = encodedPath.substr(1);
@@ -171,6 +175,14 @@
}),
dataType: 'json',
type: 'POST'
+ }).fail(function(response) {
+ var message = '';
+ // show message if it is available
+ if(response.responseJSON && response.responseJSON.message) {
+ message = ': ' + response.responseJSON.message;
+ }
+ OC.Notification.showTemporary(t('files', 'An error occurred while trying to update the tags') + message);
+ toggleStar($actionEl, isFavorite);
});
}
};
diff --git a/apps/files/l10n/cs_CZ.js b/apps/files/l10n/cs_CZ.js
index b864b8316d2..e4170df0ed3 100644
--- a/apps/files/l10n/cs_CZ.js
+++ b/apps/files/l10n/cs_CZ.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} a {files}",
"Favorited" : "Přidáno k oblíbeným",
"Favorite" : "Oblíbené",
+ "An error occurred while trying to update the tags" : "Při pokusu o úpravu tagů nastala chyba",
"%s could not be renamed as it has been deleted" : "%s nelze přejmenovat, protože byl smazán",
"%s could not be renamed" : "%s nemůže být přejmenován",
"Upload (max. %s)" : "Nahrát (max. %s)",
diff --git a/apps/files/l10n/cs_CZ.json b/apps/files/l10n/cs_CZ.json
index ecff8b31757..facc6476356 100644
--- a/apps/files/l10n/cs_CZ.json
+++ b/apps/files/l10n/cs_CZ.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} a {files}",
"Favorited" : "Přidáno k oblíbeným",
"Favorite" : "Oblíbené",
+ "An error occurred while trying to update the tags" : "Při pokusu o úpravu tagů nastala chyba",
"%s could not be renamed as it has been deleted" : "%s nelze přejmenovat, protože byl smazán",
"%s could not be renamed" : "%s nemůže být přejmenován",
"Upload (max. %s)" : "Nahrát (max. %s)",
diff --git a/apps/files/l10n/da.js b/apps/files/l10n/da.js
index 80ca71ef04d..fa85be4e7c8 100644
--- a/apps/files/l10n/da.js
+++ b/apps/files/l10n/da.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} og {files}",
"Favorited" : "Gjort til foretrukken",
"Favorite" : "Foretrukken",
+ "An error occurred while trying to update the tags" : "Der opstod en fejl under forsøg på at opdatere mærkerne",
"%s could not be renamed as it has been deleted" : "%s kunne ikke omdøbes, da den er blevet slettet",
"%s could not be renamed" : "%s kunne ikke omdøbes",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/da.json b/apps/files/l10n/da.json
index 27a70fa59c3..0209c2cb9ab 100644
--- a/apps/files/l10n/da.json
+++ b/apps/files/l10n/da.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} og {files}",
"Favorited" : "Gjort til foretrukken",
"Favorite" : "Foretrukken",
+ "An error occurred while trying to update the tags" : "Der opstod en fejl under forsøg på at opdatere mærkerne",
"%s could not be renamed as it has been deleted" : "%s kunne ikke omdøbes, da den er blevet slettet",
"%s could not be renamed" : "%s kunne ikke omdøbes",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/de.js b/apps/files/l10n/de.js
index 7fa9cd9af28..de4af2e168e 100644
--- a/apps/files/l10n/de.js
+++ b/apps/files/l10n/de.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} und {files}",
"Favorited" : "Favorisiert",
"Favorite" : "Favorit",
+ "An error occurred while trying to update the tags" : "Es ist ein Fehler beim Aktualisieren der Tags aufgetreten",
"%s could not be renamed as it has been deleted" : "%s konnte nicht umbenannt werden, da es gelöscht wurde",
"%s could not be renamed" : "%s konnte nicht umbenannt werden",
"Upload (max. %s)" : "Hochladen (max. %s)",
diff --git a/apps/files/l10n/de.json b/apps/files/l10n/de.json
index e37d96abd2e..9d5c5419edc 100644
--- a/apps/files/l10n/de.json
+++ b/apps/files/l10n/de.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} und {files}",
"Favorited" : "Favorisiert",
"Favorite" : "Favorit",
+ "An error occurred while trying to update the tags" : "Es ist ein Fehler beim Aktualisieren der Tags aufgetreten",
"%s could not be renamed as it has been deleted" : "%s konnte nicht umbenannt werden, da es gelöscht wurde",
"%s could not be renamed" : "%s konnte nicht umbenannt werden",
"Upload (max. %s)" : "Hochladen (max. %s)",
diff --git a/apps/files/l10n/de_DE.js b/apps/files/l10n/de_DE.js
index 9d864bf3626..f27d579efec 100644
--- a/apps/files/l10n/de_DE.js
+++ b/apps/files/l10n/de_DE.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} und {files}",
"Favorited" : "Favorisiert",
"Favorite" : "Favorit",
+ "An error occurred while trying to update the tags" : "Es ist ein Fehler beim Aktualisieren der Tags aufgetreten",
"%s could not be renamed as it has been deleted" : "%s konnte nicht umbenannt werden, da es gelöscht wurde",
"%s could not be renamed" : "%s konnte nicht umbenannt werden",
"Upload (max. %s)" : "Hochladen (max. %s)",
diff --git a/apps/files/l10n/de_DE.json b/apps/files/l10n/de_DE.json
index bc2fd5acddd..2c80e6f2b9c 100644
--- a/apps/files/l10n/de_DE.json
+++ b/apps/files/l10n/de_DE.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} und {files}",
"Favorited" : "Favorisiert",
"Favorite" : "Favorit",
+ "An error occurred while trying to update the tags" : "Es ist ein Fehler beim Aktualisieren der Tags aufgetreten",
"%s could not be renamed as it has been deleted" : "%s konnte nicht umbenannt werden, da es gelöscht wurde",
"%s could not be renamed" : "%s konnte nicht umbenannt werden",
"Upload (max. %s)" : "Hochladen (max. %s)",
diff --git a/apps/files/l10n/en@pirate.js b/apps/files/l10n/en@pirate.js
index 709448d1af3..db9b7b949c9 100644
--- a/apps/files/l10n/en@pirate.js
+++ b/apps/files/l10n/en@pirate.js
@@ -1,10 +1,10 @@
OC.L10N.register(
"files",
{
+ "Download" : "Download",
"_%n folder_::_%n folders_" : ["",""],
"_%n file_::_%n files_" : ["",""],
"_Uploading %n file_::_Uploading %n files_" : ["",""],
- "_matches '{filter}'_::_match '{filter}'_" : ["",""],
- "Download" : "Download"
+ "_matches '{filter}'_::_match '{filter}'_" : ["",""]
},
"nplurals=2; plural=(n != 1);");
diff --git a/apps/files/l10n/en@pirate.json b/apps/files/l10n/en@pirate.json
index d5057651887..c7c86950aa0 100644
--- a/apps/files/l10n/en@pirate.json
+++ b/apps/files/l10n/en@pirate.json
@@ -1,8 +1,8 @@
{ "translations": {
+ "Download" : "Download",
"_%n folder_::_%n folders_" : ["",""],
"_%n file_::_%n files_" : ["",""],
"_Uploading %n file_::_Uploading %n files_" : ["",""],
- "_matches '{filter}'_::_match '{filter}'_" : ["",""],
- "Download" : "Download"
+ "_matches '{filter}'_::_match '{filter}'_" : ["",""]
},"pluralForm" :"nplurals=2; plural=(n != 1);"
} \ No newline at end of file
diff --git a/apps/files/l10n/en_GB.js b/apps/files/l10n/en_GB.js
index 664c8cf9010..a0083e4e77d 100644
--- a/apps/files/l10n/en_GB.js
+++ b/apps/files/l10n/en_GB.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} and {files}",
"Favorited" : "Favourited",
"Favorite" : "Favourite",
+ "An error occurred while trying to update the tags" : "An error occurred whilst trying to update the tags",
"%s could not be renamed as it has been deleted" : "%s could not be renamed as it has been deleted",
"%s could not be renamed" : "%s could not be renamed",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/en_GB.json b/apps/files/l10n/en_GB.json
index fdc0b587386..16c8cdbc824 100644
--- a/apps/files/l10n/en_GB.json
+++ b/apps/files/l10n/en_GB.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} and {files}",
"Favorited" : "Favourited",
"Favorite" : "Favourite",
+ "An error occurred while trying to update the tags" : "An error occurred whilst trying to update the tags",
"%s could not be renamed as it has been deleted" : "%s could not be renamed as it has been deleted",
"%s could not be renamed" : "%s could not be renamed",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/es.js b/apps/files/l10n/es.js
index f1bbb505832..e80999d3f63 100644
--- a/apps/files/l10n/es.js
+++ b/apps/files/l10n/es.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} y {files}",
"Favorited" : "Agregado a favoritos",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Se produjo un error al tratar de actualizar las etiquetas",
"%s could not be renamed as it has been deleted" : "%s no se pudo renombrar pues ha sido eliminado",
"%s could not be renamed" : "%s no pudo ser renombrado",
"Upload (max. %s)" : "Subida (máx. %s)",
diff --git a/apps/files/l10n/es.json b/apps/files/l10n/es.json
index 019c52d1310..fbd3ceced03 100644
--- a/apps/files/l10n/es.json
+++ b/apps/files/l10n/es.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} y {files}",
"Favorited" : "Agregado a favoritos",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Se produjo un error al tratar de actualizar las etiquetas",
"%s could not be renamed as it has been deleted" : "%s no se pudo renombrar pues ha sido eliminado",
"%s could not be renamed" : "%s no pudo ser renombrado",
"Upload (max. %s)" : "Subida (máx. %s)",
diff --git a/apps/files/l10n/fi_FI.js b/apps/files/l10n/fi_FI.js
index cd15c95ffa5..6bf4484abc3 100644
--- a/apps/files/l10n/fi_FI.js
+++ b/apps/files/l10n/fi_FI.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} ja {files}",
"Favorited" : "Lisätty suosikkeihin",
"Favorite" : "Suosikki",
+ "An error occurred while trying to update the tags" : "Tunnisteiden päivitystä yrittäessä tapahtui virhe",
"%s could not be renamed as it has been deleted" : "Kohdetta %s ei voitu nimetä uudelleen, koska se on poistettu",
"%s could not be renamed" : "kohteen %s nimeäminen uudelleen epäonnistui",
"Upload (max. %s)" : "Lähetys (enintään %s)",
diff --git a/apps/files/l10n/fi_FI.json b/apps/files/l10n/fi_FI.json
index a3677691bd0..29dd4d462dd 100644
--- a/apps/files/l10n/fi_FI.json
+++ b/apps/files/l10n/fi_FI.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} ja {files}",
"Favorited" : "Lisätty suosikkeihin",
"Favorite" : "Suosikki",
+ "An error occurred while trying to update the tags" : "Tunnisteiden päivitystä yrittäessä tapahtui virhe",
"%s could not be renamed as it has been deleted" : "Kohdetta %s ei voitu nimetä uudelleen, koska se on poistettu",
"%s could not be renamed" : "kohteen %s nimeäminen uudelleen epäonnistui",
"Upload (max. %s)" : "Lähetys (enintään %s)",
diff --git a/apps/files/l10n/fr.js b/apps/files/l10n/fr.js
index 9bf9fdcd401..eab3108b510 100644
--- a/apps/files/l10n/fr.js
+++ b/apps/files/l10n/fr.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} et {files}",
"Favorited" : "Marqué comme favori",
"Favorite" : "Favoris",
+ "An error occurred while trying to update the tags" : "Une erreur est survenue lors de la tentative de mise à jour des étiquettes",
"%s could not be renamed as it has been deleted" : "%s ne peut être renommé car il a été supprimé ",
"%s could not be renamed" : "%s ne peut être renommé",
"Upload (max. %s)" : "Envoi (max. %s)",
@@ -98,14 +99,14 @@ OC.L10N.register(
"Upload" : "Chargement",
"Cancel upload" : "Annuler l'envoi",
"No files yet" : "Aucun fichier pour l'instant",
- "Upload some content or sync with your devices!" : "Envoyez des fichiers ou synchronisez en depuis vos appareils",
+ "Upload some content or sync with your devices!" : "Déposez du contenu ou synchronisez vos appareils !",
"No entries found in this folder" : "Aucune entrée trouvée dans ce dossier",
"Select all" : "Tout sélectionner",
"Upload too large" : "Téléversement trop volumineux",
"The files you are trying to upload exceed the maximum size for file uploads on this server." : "Les fichiers que vous essayez d'envoyer dépassent la taille maximale d'envoi permise par ce serveur.",
"Files are being scanned, please wait." : "Les fichiers sont en cours d'analyse, veuillez patienter.",
"Currently scanning" : "Analyse en cours",
- "No favorites" : "Pas de favori",
+ "No favorites" : "Aucun favori",
"Files and folders you mark as favorite will show up here" : "Les fichiers et dossiers ajoutés à vos favoris apparaîtront ici"
},
"nplurals=2; plural=(n > 1);");
diff --git a/apps/files/l10n/fr.json b/apps/files/l10n/fr.json
index fd36fda4125..ada9eb38e18 100644
--- a/apps/files/l10n/fr.json
+++ b/apps/files/l10n/fr.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} et {files}",
"Favorited" : "Marqué comme favori",
"Favorite" : "Favoris",
+ "An error occurred while trying to update the tags" : "Une erreur est survenue lors de la tentative de mise à jour des étiquettes",
"%s could not be renamed as it has been deleted" : "%s ne peut être renommé car il a été supprimé ",
"%s could not be renamed" : "%s ne peut être renommé",
"Upload (max. %s)" : "Envoi (max. %s)",
@@ -96,14 +97,14 @@
"Upload" : "Chargement",
"Cancel upload" : "Annuler l'envoi",
"No files yet" : "Aucun fichier pour l'instant",
- "Upload some content or sync with your devices!" : "Envoyez des fichiers ou synchronisez en depuis vos appareils",
+ "Upload some content or sync with your devices!" : "Déposez du contenu ou synchronisez vos appareils !",
"No entries found in this folder" : "Aucune entrée trouvée dans ce dossier",
"Select all" : "Tout sélectionner",
"Upload too large" : "Téléversement trop volumineux",
"The files you are trying to upload exceed the maximum size for file uploads on this server." : "Les fichiers que vous essayez d'envoyer dépassent la taille maximale d'envoi permise par ce serveur.",
"Files are being scanned, please wait." : "Les fichiers sont en cours d'analyse, veuillez patienter.",
"Currently scanning" : "Analyse en cours",
- "No favorites" : "Pas de favori",
+ "No favorites" : "Aucun favori",
"Files and folders you mark as favorite will show up here" : "Les fichiers et dossiers ajoutés à vos favoris apparaîtront ici"
},"pluralForm" :"nplurals=2; plural=(n > 1);"
} \ No newline at end of file
diff --git a/apps/files/l10n/gl.js b/apps/files/l10n/gl.js
index 98c71ef207c..ffd897981f3 100644
--- a/apps/files/l10n/gl.js
+++ b/apps/files/l10n/gl.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Marcado como favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Houbo un erro ao tentar actualizar as etiquetas",
"%s could not be renamed as it has been deleted" : "Non é posíbel renomear %s xa que foi eliminado",
"%s could not be renamed" : "%s non pode cambiar de nome",
"Upload (max. %s)" : "Envío (máx. %s)",
diff --git a/apps/files/l10n/gl.json b/apps/files/l10n/gl.json
index 0d0ba4a269c..d5ba50053c4 100644
--- a/apps/files/l10n/gl.json
+++ b/apps/files/l10n/gl.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Marcado como favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Houbo un erro ao tentar actualizar as etiquetas",
"%s could not be renamed as it has been deleted" : "Non é posíbel renomear %s xa que foi eliminado",
"%s could not be renamed" : "%s non pode cambiar de nome",
"Upload (max. %s)" : "Envío (máx. %s)",
diff --git a/apps/files/l10n/it.js b/apps/files/l10n/it.js
index 8ec7c4c3478..d0a186ad2e9 100644
--- a/apps/files/l10n/it.js
+++ b/apps/files/l10n/it.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Preferiti",
"Favorite" : "Preferito",
+ "An error occurred while trying to update the tags" : "Si è verificato un errore durante il tentativo di aggiornare le etichette",
"%s could not be renamed as it has been deleted" : "%s non può essere rinominato poiché è stato eliminato",
"%s could not be renamed" : "%s non può essere rinominato",
"Upload (max. %s)" : "Carica (massimo %s)",
diff --git a/apps/files/l10n/it.json b/apps/files/l10n/it.json
index 44dcc27c8a9..0632884914d 100644
--- a/apps/files/l10n/it.json
+++ b/apps/files/l10n/it.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Preferiti",
"Favorite" : "Preferito",
+ "An error occurred while trying to update the tags" : "Si è verificato un errore durante il tentativo di aggiornare le etichette",
"%s could not be renamed as it has been deleted" : "%s non può essere rinominato poiché è stato eliminato",
"%s could not be renamed" : "%s non può essere rinominato",
"Upload (max. %s)" : "Carica (massimo %s)",
diff --git a/apps/files/l10n/jv.js b/apps/files/l10n/jv.js
index adbd28854f5..5a6438c3851 100644
--- a/apps/files/l10n/jv.js
+++ b/apps/files/l10n/jv.js
@@ -1,10 +1,10 @@
OC.L10N.register(
"files",
{
+ "Download" : "Njipuk",
"_%n folder_::_%n folders_" : ["",""],
"_%n file_::_%n files_" : ["",""],
"_Uploading %n file_::_Uploading %n files_" : ["",""],
- "_matches '{filter}'_::_match '{filter}'_" : ["",""],
- "Download" : "Njipuk"
+ "_matches '{filter}'_::_match '{filter}'_" : ["",""]
},
"nplurals=2; plural=(n != 1);");
diff --git a/apps/files/l10n/jv.json b/apps/files/l10n/jv.json
index 9c2ed5bfbfb..71ada4daa9e 100644
--- a/apps/files/l10n/jv.json
+++ b/apps/files/l10n/jv.json
@@ -1,8 +1,8 @@
{ "translations": {
+ "Download" : "Njipuk",
"_%n folder_::_%n folders_" : ["",""],
"_%n file_::_%n files_" : ["",""],
"_Uploading %n file_::_Uploading %n files_" : ["",""],
- "_matches '{filter}'_::_match '{filter}'_" : ["",""],
- "Download" : "Njipuk"
+ "_matches '{filter}'_::_match '{filter}'_" : ["",""]
},"pluralForm" :"nplurals=2; plural=(n != 1);"
} \ No newline at end of file
diff --git a/apps/files/l10n/ko.js b/apps/files/l10n/ko.js
index d352bacc5ed..22dab10bd36 100644
--- a/apps/files/l10n/ko.js
+++ b/apps/files/l10n/ko.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} 그리고 {files}",
"Favorited" : "책갈피에 추가됨",
"Favorite" : "즐겨찾기",
+ "An error occurred while trying to update the tags" : "태그를 업데이트하는 중 오류 발생",
"%s could not be renamed as it has been deleted" : "%s이(가) 삭제되었기 때문에 이름을 변경할 수 없습니다",
"%s could not be renamed" : "%s의 이름을 변경할 수 없습니다",
"Upload (max. %s)" : "업로드(최대 %s)",
diff --git a/apps/files/l10n/ko.json b/apps/files/l10n/ko.json
index f12256b681a..3dbddd90263 100644
--- a/apps/files/l10n/ko.json
+++ b/apps/files/l10n/ko.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} 그리고 {files}",
"Favorited" : "책갈피에 추가됨",
"Favorite" : "즐겨찾기",
+ "An error occurred while trying to update the tags" : "태그를 업데이트하는 중 오류 발생",
"%s could not be renamed as it has been deleted" : "%s이(가) 삭제되었기 때문에 이름을 변경할 수 없습니다",
"%s could not be renamed" : "%s의 이름을 변경할 수 없습니다",
"Upload (max. %s)" : "업로드(최대 %s)",
diff --git a/apps/files/l10n/nl.js b/apps/files/l10n/nl.js
index d6c654608db..c630cf93127 100644
--- a/apps/files/l10n/nl.js
+++ b/apps/files/l10n/nl.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} en {files}",
"Favorited" : "Favoriet",
"Favorite" : "Favoriet",
+ "An error occurred while trying to update the tags" : "Er trad een fout op bij uw poging de tags bij te werken",
"%s could not be renamed as it has been deleted" : "%s kon niet worden hernoemd, omdat het verwijderd is",
"%s could not be renamed" : "%s kon niet worden hernoemd",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/nl.json b/apps/files/l10n/nl.json
index d3e22bbdaa1..34bf8e2ae29 100644
--- a/apps/files/l10n/nl.json
+++ b/apps/files/l10n/nl.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} en {files}",
"Favorited" : "Favoriet",
"Favorite" : "Favoriet",
+ "An error occurred while trying to update the tags" : "Er trad een fout op bij uw poging de tags bij te werken",
"%s could not be renamed as it has been deleted" : "%s kon niet worden hernoemd, omdat het verwijderd is",
"%s could not be renamed" : "%s kon niet worden hernoemd",
"Upload (max. %s)" : "Upload (max. %s)",
diff --git a/apps/files/l10n/pt_BR.js b/apps/files/l10n/pt_BR.js
index 156d8555baf..bd7df2569fa 100644
--- a/apps/files/l10n/pt_BR.js
+++ b/apps/files/l10n/pt_BR.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Ocorreu um erro enquanto tentava atualizar as etiquetas",
"%s could not be renamed as it has been deleted" : "%s não pode ser renomeado pois foi apagado",
"%s could not be renamed" : "%s não pode ser renomeado",
"Upload (max. %s)" : "Envio (max. %s)",
diff --git a/apps/files/l10n/pt_BR.json b/apps/files/l10n/pt_BR.json
index caabd009e16..04f60e2c1dd 100644
--- a/apps/files/l10n/pt_BR.json
+++ b/apps/files/l10n/pt_BR.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Ocorreu um erro enquanto tentava atualizar as etiquetas",
"%s could not be renamed as it has been deleted" : "%s não pode ser renomeado pois foi apagado",
"%s could not be renamed" : "%s não pode ser renomeado",
"Upload (max. %s)" : "Envio (max. %s)",
diff --git a/apps/files/l10n/pt_PT.js b/apps/files/l10n/pt_PT.js
index 57c37495e4e..08126e0d97f 100644
--- a/apps/files/l10n/pt_PT.js
+++ b/apps/files/l10n/pt_PT.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Assinalado como Favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Ocorreu um erro ao tentar atualizar as tags",
"%s could not be renamed as it has been deleted" : "Não foi possível renomear %s devido a ter sido eliminado",
"%s could not be renamed" : "%s não pode ser renomeada",
"Upload (max. %s)" : "Enviar (max. %s)",
diff --git a/apps/files/l10n/pt_PT.json b/apps/files/l10n/pt_PT.json
index bd168dfb4b1..2622ae07f3e 100644
--- a/apps/files/l10n/pt_PT.json
+++ b/apps/files/l10n/pt_PT.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} e {files}",
"Favorited" : "Assinalado como Favorito",
"Favorite" : "Favorito",
+ "An error occurred while trying to update the tags" : "Ocorreu um erro ao tentar atualizar as tags",
"%s could not be renamed as it has been deleted" : "Não foi possível renomear %s devido a ter sido eliminado",
"%s could not be renamed" : "%s não pode ser renomeada",
"Upload (max. %s)" : "Enviar (max. %s)",
diff --git a/apps/files/l10n/ru.js b/apps/files/l10n/ru.js
index 853cb02112d..2dd30d57eeb 100644
--- a/apps/files/l10n/ru.js
+++ b/apps/files/l10n/ru.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} и {files}",
"Favorited" : "Избранное",
"Favorite" : "Избранное",
+ "An error occurred while trying to update the tags" : "Во время обновления тегов возникла ошибка",
"%s could not be renamed as it has been deleted" : "Невозможно переименовать %s, поскольку объект удалён.",
"%s could not be renamed" : "%s не может быть переименован",
"Upload (max. %s)" : "Загрузка (максимум %s)",
diff --git a/apps/files/l10n/ru.json b/apps/files/l10n/ru.json
index 4852a8aebcd..08730639b6d 100644
--- a/apps/files/l10n/ru.json
+++ b/apps/files/l10n/ru.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} и {files}",
"Favorited" : "Избранное",
"Favorite" : "Избранное",
+ "An error occurred while trying to update the tags" : "Во время обновления тегов возникла ошибка",
"%s could not be renamed as it has been deleted" : "Невозможно переименовать %s, поскольку объект удалён.",
"%s could not be renamed" : "%s не может быть переименован",
"Upload (max. %s)" : "Загрузка (максимум %s)",
diff --git a/apps/files/l10n/sk_SK.js b/apps/files/l10n/sk_SK.js
index 3dd7dd1b27a..77c381261ba 100644
--- a/apps/files/l10n/sk_SK.js
+++ b/apps/files/l10n/sk_SK.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} a {files}",
"Favorited" : "Pridané k obľúbeným",
"Favorite" : "Obľúbené",
+ "An error occurred while trying to update the tags" : "Pri pokuse o aktualizáciu štítkov došlo k chybe",
"%s could not be renamed as it has been deleted" : "%s nebolo možné premenovať, pretože bol zmazaný",
"%s could not be renamed" : "%s nemohol byť premenovaný",
"Upload (max. %s)" : "Nahrať (max. %s)",
diff --git a/apps/files/l10n/sk_SK.json b/apps/files/l10n/sk_SK.json
index ab2cf57be75..953123dc576 100644
--- a/apps/files/l10n/sk_SK.json
+++ b/apps/files/l10n/sk_SK.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} a {files}",
"Favorited" : "Pridané k obľúbeným",
"Favorite" : "Obľúbené",
+ "An error occurred while trying to update the tags" : "Pri pokuse o aktualizáciu štítkov došlo k chybe",
"%s could not be renamed as it has been deleted" : "%s nebolo možné premenovať, pretože bol zmazaný",
"%s could not be renamed" : "%s nemohol byť premenovaný",
"Upload (max. %s)" : "Nahrať (max. %s)",
diff --git a/apps/files/l10n/sr.js b/apps/files/l10n/sr.js
index 73ed91ee7e3..46ce8b63ae2 100644
--- a/apps/files/l10n/sr.js
+++ b/apps/files/l10n/sr.js
@@ -43,6 +43,7 @@ OC.L10N.register(
"WebDAV" : "WebDAV",
"New" : "Нова",
"Text file" : "текстуална датотека",
+ "New folder" : "Нова фасцикла",
"Folder" : "фасцикла",
"From link" : "Са везе",
"Upload" : "Отпреми",
diff --git a/apps/files/l10n/sr.json b/apps/files/l10n/sr.json
index e0529d980fc..e931c8e27c8 100644
--- a/apps/files/l10n/sr.json
+++ b/apps/files/l10n/sr.json
@@ -41,6 +41,7 @@
"WebDAV" : "WebDAV",
"New" : "Нова",
"Text file" : "текстуална датотека",
+ "New folder" : "Нова фасцикла",
"Folder" : "фасцикла",
"From link" : "Са везе",
"Upload" : "Отпреми",
diff --git a/apps/files/l10n/tr.js b/apps/files/l10n/tr.js
index 6a497a4b3c1..f4dfcb87a2c 100644
--- a/apps/files/l10n/tr.js
+++ b/apps/files/l10n/tr.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} ve {files}",
"Favorited" : "Sık kullanılanlara eklendi",
"Favorite" : "Sık kullanılan",
+ "An error occurred while trying to update the tags" : "Etiketler güncellenmeye çalışılırken bir hata oluştu",
"%s could not be renamed as it has been deleted" : "%s, silindiği için adlandırılamadı",
"%s could not be renamed" : "%s yeniden adlandırılamadı",
"Upload (max. %s)" : "Yükle (azami: %s)",
diff --git a/apps/files/l10n/tr.json b/apps/files/l10n/tr.json
index 7f23744c96a..ba8312a1eb8 100644
--- a/apps/files/l10n/tr.json
+++ b/apps/files/l10n/tr.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} ve {files}",
"Favorited" : "Sık kullanılanlara eklendi",
"Favorite" : "Sık kullanılan",
+ "An error occurred while trying to update the tags" : "Etiketler güncellenmeye çalışılırken bir hata oluştu",
"%s could not be renamed as it has been deleted" : "%s, silindiği için adlandırılamadı",
"%s could not be renamed" : "%s yeniden adlandırılamadı",
"Upload (max. %s)" : "Yükle (azami: %s)",
diff --git a/apps/files/l10n/uk.js b/apps/files/l10n/uk.js
index 83ac40ff889..2b7eab5cf39 100644
--- a/apps/files/l10n/uk.js
+++ b/apps/files/l10n/uk.js
@@ -79,6 +79,7 @@ OC.L10N.register(
"{dirs} and {files}" : "{dirs} і {files}",
"Favorited" : "Улюблений",
"Favorite" : "Улюблений",
+ "An error occurred while trying to update the tags" : "Виникла помилка при спробі оновити мітки",
"%s could not be renamed as it has been deleted" : "%s не може бути перейменований, оскільки він видалений",
"%s could not be renamed" : "%s не може бути перейменований",
"Upload (max. %s)" : "Завантаження (макс. %s)",
diff --git a/apps/files/l10n/uk.json b/apps/files/l10n/uk.json
index 67c13571dd7..c756d224352 100644
--- a/apps/files/l10n/uk.json
+++ b/apps/files/l10n/uk.json
@@ -77,6 +77,7 @@
"{dirs} and {files}" : "{dirs} і {files}",
"Favorited" : "Улюблений",
"Favorite" : "Улюблений",
+ "An error occurred while trying to update the tags" : "Виникла помилка при спробі оновити мітки",
"%s could not be renamed as it has been deleted" : "%s не може бути перейменований, оскільки він видалений",
"%s could not be renamed" : "%s не може бути перейменований",
"Upload (max. %s)" : "Завантаження (макс. %s)",
diff --git a/apps/files_encryption/l10n/de.js b/apps/files_encryption/l10n/de.js
index e589640bbfb..544d7630833 100644
--- a/apps/files_encryption/l10n/de.js
+++ b/apps/files_encryption/l10n/de.js
@@ -23,7 +23,7 @@ OC.L10N.register(
"Your private key is not valid! Likely your password was changed outside of %s (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 außerhalb von %s 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.",
"Can not decrypt this file, probably this is a shared file. Please ask the file owner to reshare the file with you." : "Die Datei kann nicht entschlüsselt werden, da die Datei möglicherweise eine geteilte Datei ist. Bitte frage den Dateibesitzer, ob er die Datei nochmals mit Dir teilt.",
"Unknown error. Please check your system settings or contact your administrator" : "Unbekannter Fehler. Bitte prüfe Deine Systemeinstellungen oder kontaktiere Deinen Administrator",
- "Initial encryption started... This can take some time. Please wait." : "Initialverschlüsselung gestartet... Dies kann einige Zeit dauern. Bitte warten.",
+ "Initial encryption started... This can take some time. Please wait." : "Initialverschlüsselung gestartet… Dies kann einige Zeit dauern. Bitte warten.",
"Initial encryption running... Please try again later." : "Anfangsverschlüsselung läuft … Bitte versuche es später wieder.",
"Missing requirements." : "Fehlende Vorraussetzungen",
"Please make sure that OpenSSL together with the PHP extension is enabled and configured properly. For now, the encryption app has been disabled." : "Bitte stelle sicher, dass OpenSSL zusammen mit der PHP-Erweiterung aktiviert und richtig konfiguriert ist. Die Verschlüsselungsanwendung ist vorerst deaktiviert.",
diff --git a/apps/files_encryption/l10n/de.json b/apps/files_encryption/l10n/de.json
index 99646e4a76a..7ba97e39ac5 100644
--- a/apps/files_encryption/l10n/de.json
+++ b/apps/files_encryption/l10n/de.json
@@ -21,7 +21,7 @@
"Your private key is not valid! Likely your password was changed outside of %s (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 außerhalb von %s 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.",
"Can not decrypt this file, probably this is a shared file. Please ask the file owner to reshare the file with you." : "Die Datei kann nicht entschlüsselt werden, da die Datei möglicherweise eine geteilte Datei ist. Bitte frage den Dateibesitzer, ob er die Datei nochmals mit Dir teilt.",
"Unknown error. Please check your system settings or contact your administrator" : "Unbekannter Fehler. Bitte prüfe Deine Systemeinstellungen oder kontaktiere Deinen Administrator",
- "Initial encryption started... This can take some time. Please wait." : "Initialverschlüsselung gestartet... Dies kann einige Zeit dauern. Bitte warten.",
+ "Initial encryption started... This can take some time. Please wait." : "Initialverschlüsselung gestartet… Dies kann einige Zeit dauern. Bitte warten.",
"Initial encryption running... Please try again later." : "Anfangsverschlüsselung läuft … Bitte versuche es später wieder.",
"Missing requirements." : "Fehlende Vorraussetzungen",
"Please make sure that OpenSSL together with the PHP extension is enabled and configured properly. For now, the encryption app has been disabled." : "Bitte stelle sicher, dass OpenSSL zusammen mit der PHP-Erweiterung aktiviert und richtig konfiguriert ist. Die Verschlüsselungsanwendung ist vorerst deaktiviert.",
diff --git a/apps/files_encryption/l10n/pt_PT.js b/apps/files_encryption/l10n/pt_PT.js
index 3d6e8a50749..7d392923094 100644
--- a/apps/files_encryption/l10n/pt_PT.js
+++ b/apps/files_encryption/l10n/pt_PT.js
@@ -11,7 +11,7 @@ OC.L10N.register(
"Please provide the old recovery password" : "Escreva a palavra-passe de recuperação antiga",
"Please provide a new recovery password" : "Escreva a nova palavra-passe de recuperação",
"Please repeat the new recovery password" : "Escreva de novo a nova palavra-passe de recuperação",
- "Password successfully changed." : "Senha alterada com sucesso.",
+ "Password successfully changed." : "Palavra-passe alterada com sucesso.",
"Could not change the password. Maybe the old password was not correct." : "Não foi possível alterar a senha. Possivelmente a senha antiga não está correta.",
"Could not update the private key password." : "Não foi possível atualizar a senha da chave privada.",
"The old password was not correct, please try again." : "A senha antiga não estava correta, por favor, tente de novo.",
diff --git a/apps/files_encryption/l10n/pt_PT.json b/apps/files_encryption/l10n/pt_PT.json
index d2a34ec9d01..5f7d0a22f34 100644
--- a/apps/files_encryption/l10n/pt_PT.json
+++ b/apps/files_encryption/l10n/pt_PT.json
@@ -9,7 +9,7 @@
"Please provide the old recovery password" : "Escreva a palavra-passe de recuperação antiga",
"Please provide a new recovery password" : "Escreva a nova palavra-passe de recuperação",
"Please repeat the new recovery password" : "Escreva de novo a nova palavra-passe de recuperação",
- "Password successfully changed." : "Senha alterada com sucesso.",
+ "Password successfully changed." : "Palavra-passe alterada com sucesso.",
"Could not change the password. Maybe the old password was not correct." : "Não foi possível alterar a senha. Possivelmente a senha antiga não está correta.",
"Could not update the private key password." : "Não foi possível atualizar a senha da chave privada.",
"The old password was not correct, please try again." : "A senha antiga não estava correta, por favor, tente de novo.",
diff --git a/apps/files_encryption/l10n/uk.js b/apps/files_encryption/l10n/uk.js
index e01a79f23c5..a5f70cf8589 100644
--- a/apps/files_encryption/l10n/uk.js
+++ b/apps/files_encryption/l10n/uk.js
@@ -29,6 +29,7 @@ OC.L10N.register(
"Please make sure that OpenSSL together with the PHP extension is enabled and configured properly. For now, the encryption app has been disabled." : "Будь ласка, переконайтеся, що OpenSSL разом з розширенням PHP включена і налаштована належним чином. В даний час, шифрування додатку було відключено.",
"Following users are not set up for encryption:" : "Для наступних користувачів шифрування не налаштоване:",
"Go directly to your %spersonal settings%s." : "Перейти навпростець до ваших %spersonal settings%s.",
+ "Server-side Encryption" : "Серверне шіфрування",
"Encryption App is enabled but your keys are not initialized, please log-out and log-in again" : "Доданок шифрування ввімкнено, але ваші ключі не ініціалізовано, вийдіть та зайдіть знову",
"Enable recovery key (allow to recover users files in case of password loss):" : "Ввімкнути ключ відновлення (дозволяє користувачам відновлювати файли при втраті паролю):",
"Recovery key password" : "Пароль ключа відновлення",
diff --git a/apps/files_encryption/l10n/uk.json b/apps/files_encryption/l10n/uk.json
index 51dd3c26335..69c44021eae 100644
--- a/apps/files_encryption/l10n/uk.json
+++ b/apps/files_encryption/l10n/uk.json
@@ -27,6 +27,7 @@
"Please make sure that OpenSSL together with the PHP extension is enabled and configured properly. For now, the encryption app has been disabled." : "Будь ласка, переконайтеся, що OpenSSL разом з розширенням PHP включена і налаштована належним чином. В даний час, шифрування додатку було відключено.",
"Following users are not set up for encryption:" : "Для наступних користувачів шифрування не налаштоване:",
"Go directly to your %spersonal settings%s." : "Перейти навпростець до ваших %spersonal settings%s.",
+ "Server-side Encryption" : "Серверне шіфрування",
"Encryption App is enabled but your keys are not initialized, please log-out and log-in again" : "Доданок шифрування ввімкнено, але ваші ключі не ініціалізовано, вийдіть та зайдіть знову",
"Enable recovery key (allow to recover users files in case of password loss):" : "Ввімкнути ключ відновлення (дозволяє користувачам відновлювати файли при втраті паролю):",
"Recovery key password" : "Пароль ключа відновлення",
diff --git a/apps/files_external/appinfo/app.php b/apps/files_external/appinfo/app.php
index 9b5994338a1..70f6b0159a6 100644
--- a/apps/files_external/appinfo/app.php
+++ b/apps/files_external/appinfo/app.php
@@ -18,6 +18,7 @@ OC::$CLASSPATH['OC\Files\Storage\SMB_OC'] = 'files_external/lib/smb_oc.php';
OC::$CLASSPATH['OC\Files\Storage\AmazonS3'] = 'files_external/lib/amazons3.php';
OC::$CLASSPATH['OC\Files\Storage\Dropbox'] = 'files_external/lib/dropbox.php';
OC::$CLASSPATH['OC\Files\Storage\SFTP'] = 'files_external/lib/sftp.php';
+OC::$CLASSPATH['OC\Files\Storage\SFTP_Key'] = 'files_external/lib/sftp_key.php';
OC::$CLASSPATH['OC_Mount_Config'] = 'files_external/lib/config.php';
OC::$CLASSPATH['OCA\Files\External\Api'] = 'files_external/lib/api.php';
@@ -26,39 +27,41 @@ if (OCP\Config::getAppValue('files_external', 'allow_user_mounting', 'yes') == '
OCP\App::registerPersonal('files_external', 'personal');
}
-\OCA\Files\App::getNavigationManager()->add(
- array(
- "id" => 'extstoragemounts',
- "appname" => 'files_external',
- "script" => 'list.php',
- "order" => 30,
- "name" => $l->t('External storage')
- )
-);
+\OCA\Files\App::getNavigationManager()->add([
+ "id" => 'extstoragemounts',
+ "appname" => 'files_external',
+ "script" => 'list.php',
+ "order" => 30,
+ "name" => $l->t('External storage')
+]);
// connecting hooks
OCP\Util::connectHook('OC_Filesystem', 'post_initMountPoints', '\OC_Mount_Config', 'initMountPointsHook');
OCP\Util::connectHook('OC_User', 'post_login', 'OC\Files\Storage\SMB_OC', 'login');
-OC_Mount_Config::registerBackend('\OC\Files\Storage\Local', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\Local', [
'backend' => (string)$l->t('Local'),
'priority' => 150,
- 'configuration' => array(
- 'datadir' => (string)$l->t('Location'))));
+ 'configuration' => [
+ 'datadir' => (string)$l->t('Location')
+ ],
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\AmazonS3', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\AmazonS3', [
'backend' => (string)$l->t('Amazon S3'),
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'key' => (string)$l->t('Key'),
'secret' => '*'.$l->t('Secret'),
- 'bucket' => (string)$l->t('Bucket')),
- 'has_dependencies' => true));
+ 'bucket' => (string)$l->t('Bucket'),
+ ],
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\AmazonS3', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\AmazonS3', [
'backend' => (string)$l->t('Amazon S3 and compliant'),
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'key' => (string)$l->t('Access Key'),
'secret' => '*'.$l->t('Secret Key'),
'bucket' => (string)$l->t('Bucket'),
@@ -66,48 +69,56 @@ OC_Mount_Config::registerBackend('\OC\Files\Storage\AmazonS3', array(
'port' => '&'.$l->t('Port'),
'region' => '&'.$l->t('Region'),
'use_ssl' => '!'.$l->t('Enable SSL'),
- 'use_path_style' => '!'.$l->t('Enable Path Style')),
- 'has_dependencies' => true));
+ 'use_path_style' => '!'.$l->t('Enable Path Style')
+ ],
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\Dropbox', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\Dropbox', [
'backend' => 'Dropbox',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'configured' => '#configured',
'app_key' => (string)$l->t('App key'),
'app_secret' => '*'.$l->t('App secret'),
'token' => '#token',
- 'token_secret' => '#token_secret'),
+ 'token_secret' => '#token_secret'
+ ],
'custom' => 'dropbox',
- 'has_dependencies' => true));
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\FTP', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\FTP', [
'backend' => 'FTP',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('Host'),
'user' => (string)$l->t('Username'),
'password' => '*'.$l->t('Password'),
'root' => '&'.$l->t('Remote subfolder'),
- 'secure' => '!'.$l->t('Secure ftps://')),
- 'has_dependencies' => true));
+ 'secure' => '!'.$l->t('Secure ftps://')
+ ],
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\Google', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\Google', [
'backend' => 'Google Drive',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'configured' => '#configured',
'client_id' => (string)$l->t('Client ID'),
'client_secret' => '*'.$l->t('Client secret'),
- 'token' => '#token'),
+ 'token' => '#token',
+ ],
'custom' => 'google',
- 'has_dependencies' => true));
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\Swift', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\Swift', [
'backend' => (string)$l->t('OpenStack Object Storage'),
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'user' => (string)$l->t('Username'),
'bucket' => (string)$l->t('Bucket'),
'region' => '&'.$l->t('Region (optional for OpenStack Object Storage)'),
@@ -117,63 +128,86 @@ OC_Mount_Config::registerBackend('\OC\Files\Storage\Swift', array(
'service_name' => '&'.$l->t('Service Name (required for OpenStack Object Storage)'),
'url' => '&'.$l->t('URL of identity endpoint (required for OpenStack Object Storage)'),
'timeout' => '&'.$l->t('Timeout of HTTP requests in seconds'),
- ),
- 'has_dependencies' => true));
+ ],
+ 'has_dependencies' => true,
+]);
if (!OC_Util::runningOnWindows()) {
- OC_Mount_Config::registerBackend('\OC\Files\Storage\SMB', array(
+ OC_Mount_Config::registerBackend('\OC\Files\Storage\SMB', [
'backend' => 'SMB / CIFS',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('Host'),
'user' => (string)$l->t('Username'),
'password' => '*'.$l->t('Password'),
'share' => (string)$l->t('Share'),
- 'root' => '&'.$l->t('Remote subfolder')),
- 'has_dependencies' => true));
+ 'root' => '&'.$l->t('Remote subfolder'),
+ ],
+ 'has_dependencies' => true,
+ ]);
- OC_Mount_Config::registerBackend('\OC\Files\Storage\SMB_OC', array(
+ OC_Mount_Config::registerBackend('\OC\Files\Storage\SMB_OC', [
'backend' => (string)$l->t('SMB / CIFS using OC login'),
'priority' => 90,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('Host'),
'username_as_share' => '!'.$l->t('Username as share'),
'share' => '&'.$l->t('Share'),
- 'root' => '&'.$l->t('Remote subfolder')),
- 'has_dependencies' => true));
+ 'root' => '&'.$l->t('Remote subfolder'),
+ ],
+ 'has_dependencies' => true,
+ ]);
}
-OC_Mount_Config::registerBackend('\OC\Files\Storage\DAV', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\DAV', [
'backend' => 'WebDAV',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('URL'),
'user' => (string)$l->t('Username'),
'password' => '*'.$l->t('Password'),
'root' => '&'.$l->t('Remote subfolder'),
- 'secure' => '!'.$l->t('Secure https://')),
- 'has_dependencies' => true));
+ 'secure' => '!'.$l->t('Secure https://'),
+ ],
+ 'has_dependencies' => true,
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\OwnCloud', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\OwnCloud', [
'backend' => 'ownCloud',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('URL'),
'user' => (string)$l->t('Username'),
'password' => '*'.$l->t('Password'),
'root' => '&'.$l->t('Remote subfolder'),
- 'secure' => '!'.$l->t('Secure https://'))));
+ 'secure' => '!'.$l->t('Secure https://'),
+ ],
+]);
-OC_Mount_Config::registerBackend('\OC\Files\Storage\SFTP', array(
+OC_Mount_Config::registerBackend('\OC\Files\Storage\SFTP', [
'backend' => 'SFTP',
'priority' => 100,
- 'configuration' => array(
+ 'configuration' => [
'host' => (string)$l->t('Host'),
'user' => (string)$l->t('Username'),
'password' => '*'.$l->t('Password'),
- 'root' => '&'.$l->t('Remote subfolder'))));
+ 'root' => '&'.$l->t('Remote subfolder'),
+ ],
+]);
+OC_Mount_Config::registerBackend('\OC\Files\Storage\SFTP_Key', [
+ 'backend' => 'SFTP with secret key login',
+ 'priority' => 100,
+ 'configuration' => array(
+ 'host' => (string)$l->t('Host'),
+ 'user' => (string)$l->t('Username'),
+ 'public_key' => (string)$l->t('Public key'),
+ 'private_key' => '#private_key',
+ 'root' => '&'.$l->t('Remote subfolder')),
+ 'custom' => 'sftp_key',
+ ]
+);
$mountProvider = new \OCA\Files_External\Config\ConfigAdapter();
\OC::$server->getMountProviderCollection()->registerProvider($mountProvider);
diff --git a/apps/files_external/appinfo/application.php b/apps/files_external/appinfo/application.php
new file mode 100644
index 00000000000..b1605bb98a8
--- /dev/null
+++ b/apps/files_external/appinfo/application.php
@@ -0,0 +1,33 @@
+<?php
+/**
+ * Copyright (c) 2015 University of Edinburgh <Ross.Nicoll@ed.ac.uk>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+
+namespace OCA\Files_External\Appinfo;
+
+use \OCA\Files_External\Controller\AjaxController;
+use \OCP\AppFramework\App;
+use \OCP\IContainer;
+
+ /**
+ * @package OCA\Files_External\Appinfo
+ */
+class Application extends App {
+ public function __construct(array $urlParams=array()) {
+ parent::__construct('files_external', $urlParams);
+ $container = $this->getContainer();
+
+ /**
+ * Controllers
+ */
+ $container->registerService('AjaxController', function (IContainer $c) {
+ return new AjaxController(
+ $c->query('AppName'),
+ $c->query('Request')
+ );
+ });
+ }
+}
diff --git a/apps/files_external/appinfo/routes.php b/apps/files_external/appinfo/routes.php
index b852b34c5d3..5c7c4eca909 100644
--- a/apps/files_external/appinfo/routes.php
+++ b/apps/files_external/appinfo/routes.php
@@ -20,6 +20,23 @@
*
*/
+namespace OCA\Files_External\Appinfo;
+
+$application = new Application();
+$application->registerRoutes(
+ $this,
+ array(
+ 'routes' => array(
+ array(
+ 'name' => 'Ajax#getSshKeys',
+ 'url' => '/ajax/sftp_key.php',
+ 'verb' => 'POST',
+ 'requirements' => array()
+ )
+ )
+ )
+);
+
/** @var $this OC\Route\Router */
$this->create('files_external_add_mountpoint', 'ajax/addMountPoint.php')
@@ -37,10 +54,11 @@ $this->create('files_external_dropbox', 'ajax/dropbox.php')
$this->create('files_external_google', 'ajax/google.php')
->actionInclude('files_external/ajax/google.php');
+
$this->create('files_external_list_applicable', '/applicable')
->actionInclude('files_external/ajax/applicable.php');
-OC_API::register('get',
+\OC_API::register('get',
'/apps/files_external/api/v1/mounts',
array('\OCA\Files\External\Api', 'getUserMounts'),
'files_external');
diff --git a/apps/files_external/controller/ajaxcontroller.php b/apps/files_external/controller/ajaxcontroller.php
new file mode 100644
index 00000000000..141fc7817d2
--- /dev/null
+++ b/apps/files_external/controller/ajaxcontroller.php
@@ -0,0 +1,48 @@
+<?php
+/**
+ * Copyright (c) 2015 University of Edinburgh <Ross.Nicoll@ed.ac.uk>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+
+namespace OCA\Files_External\Controller;
+
+use OCP\AppFramework\Controller;
+use OCP\IRequest;
+use OCP\AppFramework\Http\JSONResponse;
+
+class AjaxController extends Controller {
+ public function __construct($appName, IRequest $request) {
+ parent::__construct($appName, $request);
+ }
+
+ private function generateSshKeys() {
+ $rsa = new \Crypt_RSA();
+ $rsa->setPublicKeyFormat(CRYPT_RSA_PUBLIC_FORMAT_OPENSSH);
+ $rsa->setPassword(\OC::$server->getConfig()->getSystemValue('secret', ''));
+
+ $key = $rsa->createKey();
+ // Replace the placeholder label with a more meaningful one
+ $key['publicKey'] = str_replace('phpseclib-generated-key', gethostname(), $key['publickey']);
+
+ return $key;
+ }
+
+ /**
+ * Generates an SSH public/private key pair.
+ *
+ * @NoAdminRequired
+ */
+ public function getSshKeys() {
+ $key = $this->generateSshKeys();
+ return new JSONResponse(
+ array('data' => array(
+ 'private_key' => $key['privatekey'],
+ 'public_key' => $key['publickey']
+ ),
+ 'status' => 'success'
+ ));
+ }
+
+}
diff --git a/apps/files_external/js/dropbox.js b/apps/files_external/js/dropbox.js
index 6baaabe11b6..2880e910f2c 100644
--- a/apps/files_external/js/dropbox.js
+++ b/apps/files_external/js/dropbox.js
@@ -65,7 +65,10 @@ $(document).ready(function() {
|| $(tr).find('.chzn-select').val() != null))
{
if ($(tr).find('.dropbox').length == 0) {
- $(config).append('<a class="button dropbox">'+t('files_external', 'Grant access')+'</a>');
+ $(config).append($(document.createElement('input'))
+ .addClass('button dropbox')
+ .attr('type', 'button')
+ .attr('value', t('files_external', 'Grant access')));
} else {
$(tr).find('.dropbox').show();
}
diff --git a/apps/files_external/js/google.js b/apps/files_external/js/google.js
index 068c2c13c66..b9a5e66b800 100644
--- a/apps/files_external/js/google.js
+++ b/apps/files_external/js/google.js
@@ -85,8 +85,9 @@ $(document).ready(function() {
|| $(tr).find('.chzn-select').val() != null))
{
if ($(tr).find('.google').length == 0) {
- $(config).append($('<a/>').addClass('button google')
- .text(t('files_external', 'Grant access')));
+ $(config).append($(document.createElement('input')).addClass('button google')
+ .attr('type', 'button')
+ .attr('value', t('files_external', 'Grant access')));
} else {
$(tr).find('.google').show();
}
diff --git a/apps/files_external/js/sftp_key.js b/apps/files_external/js/sftp_key.js
new file mode 100644
index 00000000000..2b39628247c
--- /dev/null
+++ b/apps/files_external/js/sftp_key.js
@@ -0,0 +1,53 @@
+$(document).ready(function() {
+
+ $('#externalStorage tbody tr.\\\\OC\\\\Files\\\\Storage\\\\SFTP_Key').each(function() {
+ var tr = $(this);
+ var config = $(tr).find('.configuration');
+ if ($(config).find('.sftp_key').length === 0) {
+ setupTableRow(tr, config);
+ }
+ });
+
+ // We can't catch the DOM elements being added, but we can pick up when
+ // they receive focus
+ $('#externalStorage').on('focus', 'tbody tr.\\\\OC\\\\Files\\\\Storage\\\\SFTP_Key', function() {
+ var tr = $(this);
+ var config = $(tr).find('.configuration');
+
+ if ($(config).find('.sftp_key').length === 0) {
+ setupTableRow(tr, config);
+ }
+ });
+
+ $('#externalStorage').on('click', '.sftp_key', function(event) {
+ event.preventDefault();
+ var tr = $(this).parent().parent();
+ generateKeys(tr);
+ });
+
+ function setupTableRow(tr, config) {
+ $(config).append($(document.createElement('input')).addClass('button sftp_key')
+ .attr('type', 'button')
+ .attr('value', t('files_external', 'Generate keys')));
+ // If there's no private key, build one
+ if (0 === $(config).find('[data-parameter="private_key"]').val().length) {
+ generateKeys(tr);
+ }
+ }
+
+ function generateKeys(tr) {
+ var config = $(tr).find('.configuration');
+
+ $.post(OC.filePath('files_external', 'ajax', 'sftp_key.php'), {}, function(result) {
+ if (result && result.status === 'success') {
+ $(config).find('[data-parameter="public_key"]').val(result.data.public_key);
+ $(config).find('[data-parameter="private_key"]').val(result.data.private_key);
+ OC.MountConfig.saveStorage(tr, function() {
+ // Nothing to do
+ });
+ } else {
+ OC.dialogs.alert(result.data.message, t('files_external', 'Error generating key pair') );
+ }
+ });
+ }
+});
diff --git a/apps/files_external/l10n/ja.js b/apps/files_external/l10n/ja.js
index 4c343daf902..f981ff6535f 100644
--- a/apps/files_external/l10n/ja.js
+++ b/apps/files_external/l10n/ja.js
@@ -65,7 +65,7 @@ OC.L10N.register(
"External Storage" : "外部ストレージ",
"Folder name" : "フォルダー名",
"Configuration" : "設定",
- "Available for" : "以下が利用可能",
+ "Available for" : "利用可能",
"Add storage" : "ストレージを追加",
"Delete" : "削除",
"Enable User External Storage" : "ユーザーの外部ストレージを有効にする",
diff --git a/apps/files_external/l10n/ja.json b/apps/files_external/l10n/ja.json
index 77aff58b9f7..d2cb64ad528 100644
--- a/apps/files_external/l10n/ja.json
+++ b/apps/files_external/l10n/ja.json
@@ -63,7 +63,7 @@
"External Storage" : "外部ストレージ",
"Folder name" : "フォルダー名",
"Configuration" : "設定",
- "Available for" : "以下が利用可能",
+ "Available for" : "利用可能",
"Add storage" : "ストレージを追加",
"Delete" : "削除",
"Enable User External Storage" : "ユーザーの外部ストレージを有効にする",
diff --git a/apps/files_external/lib/sftp.php b/apps/files_external/lib/sftp.php
index f6c56669734..2a762ad068f 100644
--- a/apps/files_external/lib/sftp.php
+++ b/apps/files_external/lib/sftp.php
@@ -20,7 +20,7 @@ class SFTP extends \OC\Files\Storage\Common {
/**
* @var \Net_SFTP
*/
- private $client;
+ protected $client;
private static $tempFiles = array();
@@ -42,7 +42,8 @@ class SFTP extends \OC\Files\Storage\Common {
$this->host = substr($this->host, $proto+3);
}
$this->user = $params['user'];
- $this->password = $params['password'];
+ $this->password
+ = isset($params['password']) ? $params['password'] : '';
$this->root
= isset($params['root']) ? $this->cleanPath($params['root']) : '/';
@@ -101,6 +102,18 @@ class SFTP extends \OC\Files\Storage\Common {
return 'sftp::' . $this->user . '@' . $this->host . '/' . $this->root;
}
+ public function getHost() {
+ return $this->host;
+ }
+
+ public function getRoot() {
+ return $this->root;
+ }
+
+ public function getUser() {
+ return $this->user;
+ }
+
/**
* @param string $path
*/
@@ -121,7 +134,7 @@ class SFTP extends \OC\Files\Storage\Common {
return false;
}
- private function writeHostKeys($keys) {
+ protected function writeHostKeys($keys) {
try {
$keyPath = $this->hostKeysPath();
if ($keyPath && file_exists($keyPath)) {
@@ -137,7 +150,7 @@ class SFTP extends \OC\Files\Storage\Common {
return false;
}
- private function readHostKeys() {
+ protected function readHostKeys() {
try {
$keyPath = $this->hostKeysPath();
if (file_exists($keyPath)) {
diff --git a/apps/files_external/lib/sftp_key.php b/apps/files_external/lib/sftp_key.php
new file mode 100644
index 00000000000..6113f88a8ff
--- /dev/null
+++ b/apps/files_external/lib/sftp_key.php
@@ -0,0 +1,194 @@
+<?php
+/**
+ * Copyright (c) 2014, 2015 University of Edinburgh <Ross.Nicoll@ed.ac.uk>
+ * This file is licensed under the Affero General Public License version 3 or
+ * later.
+ * See the COPYING-README file.
+ */
+namespace OC\Files\Storage;
+
+/**
+* Uses phpseclib's Net_SFTP class and the Net_SFTP_Stream stream wrapper to
+* provide access to SFTP servers.
+*/
+class SFTP_Key extends \OC\Files\Storage\SFTP {
+ private $publicKey;
+ private $privateKey;
+
+ public function __construct($params) {
+ parent::__construct($params);
+ $this->publicKey = $params['public_key'];
+ $this->privateKey = $params['private_key'];
+ }
+
+ /**
+ * Returns the connection.
+ *
+ * @return \Net_SFTP connected client instance
+ * @throws \Exception when the connection failed
+ */
+ public function getConnection() {
+ if (!is_null($this->client)) {
+ return $this->client;
+ }
+
+ $hostKeys = $this->readHostKeys();
+ $this->client = new \Net_SFTP($this->getHost());
+
+ // The SSH Host Key MUST be verified before login().
+ $currentHostKey = $this->client->getServerPublicHostKey();
+ if (array_key_exists($this->getHost(), $hostKeys)) {
+ if ($hostKeys[$this->getHost()] !== $currentHostKey) {
+ throw new \Exception('Host public key does not match known key');
+ }
+ } else {
+ $hostKeys[$this->getHost()] = $currentHostKey;
+ $this->writeHostKeys($hostKeys);
+ }
+
+ $key = $this->getPrivateKey();
+ if (is_null($key)) {
+ throw new \Exception('Secret key could not be loaded');
+ }
+ if (!$this->client->login($this->getUser(), $key)) {
+ throw new \Exception('Login failed');
+ }
+ return $this->client;
+ }
+
+ /**
+ * Returns the private key to be used for authentication to the remote server.
+ *
+ * @return \Crypt_RSA instance or null in case of a failure to load the key.
+ */
+ private function getPrivateKey() {
+ $key = new \Crypt_RSA();
+ $key->setPassword(\OC::$server->getConfig()->getSystemValue('secret', ''));
+ if (!$key->loadKey($this->privateKey)) {
+ // Should this exception rather than return null?
+ return null;
+ }
+ return $key;
+ }
+
+ /**
+ * Throws an exception if the provided host name/address is invalid (cannot be resolved
+ * and is not an IPv4 address).
+ *
+ * @return true; never returns in case of a problem, this return value is used just to
+ * make unit tests happy.
+ */
+ public function assertHostAddressValid($hostname) {
+ // TODO: Should handle IPv6 addresses too
+ if (!preg_match('/^\d+\.\d+\.\d+\.\d+$/', $hostname) && gethostbyname($hostname) === $hostname) {
+ // Hostname is not an IPv4 address and cannot be resolved via DNS
+ throw new \InvalidArgumentException('Cannot resolve hostname.');
+ }
+ return true;
+ }
+
+ /**
+ * Throws an exception if the provided port number is invalid (cannot be resolved
+ * and is not an IPv4 address).
+ *
+ * @return true; never returns in case of a problem, this return value is used just to
+ * make unit tests happy.
+ */
+ public function assertPortNumberValid($port) {
+ if (!preg_match('/^\d+$/', $port)) {
+ throw new \InvalidArgumentException('Port number must be a number.');
+ }
+ if ($port < 0 || $port > 65535) {
+ throw new \InvalidArgumentException('Port number must be between 0 and 65535 inclusive.');
+ }
+ return true;
+ }
+
+ /**
+ * Replaces anything that's not an alphanumeric character or "." in a hostname
+ * with "_", to make it safe for use as part of a file name.
+ */
+ protected function sanitizeHostName($name) {
+ return preg_replace('/[^\d\w\._]/', '_', $name);
+ }
+
+ /**
+ * Replaces anything that's not an alphanumeric character or "_" in a username
+ * with "_", to make it safe for use as part of a file name.
+ */
+ protected function sanitizeUserName($name) {
+ return preg_replace('/[^\d\w_]/', '_', $name);
+ }
+
+ public function test() {
+ if (empty($this->getHost())) {
+ \OC::$server->getLogger()->warning('Hostname has not been specified');
+ return false;
+ }
+ if (empty($this->getUser())) {
+ \OC::$server->getLogger()->warning('Username has not been specified');
+ return false;
+ }
+ if (!isset($this->privateKey)) {
+ \OC::$server->getLogger()->warning('Private key was missing from the request');
+ return false;
+ }
+
+ // Sanity check the host
+ $hostParts = explode(':', $this->getHost());
+ try {
+ if (count($hostParts) == 1) {
+ $hostname = $hostParts[0];
+ $this->assertHostAddressValid($hostname);
+ } else if (count($hostParts) == 2) {
+ $hostname = $hostParts[0];
+ $this->assertHostAddressValid($hostname);
+ $this->assertPortNumberValid($hostParts[1]);
+ } else {
+ throw new \Exception('Host connection string is invalid.');
+ }
+ } catch(\Exception $e) {
+ \OC::$server->getLogger()->warning($e->getMessage());
+ return false;
+ }
+
+ // Validate the key
+ $key = $this->getPrivateKey();
+ if (is_null($key)) {
+ \OC::$server->getLogger()->warning('Secret key could not be loaded');
+ return false;
+ }
+
+ try {
+ if ($this->getConnection()->nlist() === false) {
+ return false;
+ }
+ } catch(\Exception $e) {
+ // We should be throwing a more specific error, so we're not just catching
+ // Exception here
+ \OC::$server->getLogger()->warning($e->getMessage());
+ return false;
+ }
+
+ // Save the key somewhere it can easily be extracted later
+ if (\OC::$server->getUserSession()->getUser()) {
+ $view = new \OC\Files\View('/'.\OC::$server->getUserSession()->getUser()->getUId().'/files_external/sftp_keys');
+ if (!$view->is_dir('')) {
+ if (!$view->mkdir('')) {
+ \OC::$server->getLogger()->warning('Could not create secret key directory.');
+ return false;
+ }
+ }
+ $key_filename = $this->sanitizeUserName($this->getUser()).'@'.$this->sanitizeHostName($hostname).'.pub';
+ $key_file = $view->fopen($key_filename, "w");
+ if ($key_file) {
+ fwrite($key_file, $this->publicKey);
+ fclose($key_file);
+ } else {
+ \OC::$server->getLogger()->warning('Could not write secret key file.');
+ }
+ }
+
+ return true;
+ }
+}
diff --git a/apps/files_external/tests/README.md b/apps/files_external/tests/README.md
new file mode 100644
index 00000000000..35a0232434e
--- /dev/null
+++ b/apps/files_external/tests/README.md
@@ -0,0 +1,58 @@
+# How to run the files external unit tests
+
+## Components
+
+The files_external relies - as the name already says - on external file system
+providers. To test easily against such a provider we use some scripts to setup
+a provider (and of course also cleanup that provider). Those scripts can be
+found in the `tests/env` folder of the files_external app.
+
+### Naming Conventions
+
+The current implementation supports a script that starts with `start-` for the
+setup step which is executed before the PHPUnit run and an optional script
+starting with `stop-` (and have the same ending as the start script) to cleanup
+the provider. For example: `start-webdav-ownCloud.sh` and
+`stop-webdav-ownCloud.sh`. As a second requirement after this prefix there has
+to be the name of the backend test suite. In the above example the test suite
+`tests/backends/webdav.php` is used. The last part is a name that can be chosen
+freely.
+
+## Hands-on way of unit test execution
+
+Run all files_external unit tests by invoking the following in the ownCloud
+core root folder:
+
+ ./autotest-external.sh
+
+This script supports to get passed a database as first argument:
+
+ ./autotest-external.sh sqlite
+
+You can also pass the name of the external file system provider as a second
+argument that should be executed. This is the name of the script without the
+prefix `start-` (or `stop-`) and without the extension `.sh` from the above
+mentioned components in `test/env`. So if you want to start the WebDAV backend
+tests against an ownCloud instance you can run following:
+
+ ./autotest-external.sh sqlite webdav-ownCloud
+
+This runs the script `start-webdav-ownCloud.sh` from the `tests/env` folder,
+then runs the unit test suite from `backends/webdav.php` (because the middle part of
+the name of the script is `webdav`) and finally tries to call
+`stop-webdav-ownCloud.sh` for cleanup purposes.
+
+## The more manual way of unit test execution
+
+If you want to debug your external storage provider, you maybe don't want to
+fire it up, execute the unit tests and clean everything up for each debugging
+step. In this case you can simply start the external storage provider instance
+and run the unit test multiple times against the instance for debugging purposes.
+To do this you just need to follow these steps (from within
+`apps/files_external/tests`):
+
+ 1. run the start step (`env/start-BACKEND-NAME.sh`) or start the environment by
+ hand (i.e. setting up an instance manually in a virtual box)
+ 2. run the unit tests with following command (you can repeat that step multiple times):
+ `phpunit --configuration ../../../tests/phpunit-autotest-external.xml backends/BACKEND.php`
+ 3. call the cleanup script (`env/stop-BACKEND-NAME.sh`) or cleanup by hand
diff --git a/apps/files_external/tests/backends/sftp_key.php b/apps/files_external/tests/backends/sftp_key.php
new file mode 100644
index 00000000000..4e55cc37ca3
--- /dev/null
+++ b/apps/files_external/tests/backends/sftp_key.php
@@ -0,0 +1,85 @@
+<?php
+
+/**
+ * ownCloud
+ *
+ * @author Henrik Kjölhede
+ * @copyright 2013 Henrik Kjölhede hkjolhede@gmail.com
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ */
+
+namespace Test\Files\Storage;
+
+class SFTP_Key extends Storage {
+ private $config;
+
+ protected function setUp() {
+ parent::setUp();
+
+ $id = $this->getUniqueID();
+ $this->config = include('files_external/tests/config.php');
+ if ( ! is_array($this->config) or ! isset($this->config['sftp_key']) or ! $this->config['sftp_key']['run']) {
+ $this->markTestSkipped('SFTP with key backend not configured');
+ }
+ $this->config['sftp_key']['root'] .= '/' . $id; //make sure we have an new empty folder to work in
+ $this->instance = new \OC\Files\Storage\SFTP_Key($this->config['sftp_key']);
+ $this->instance->mkdir('/');
+ }
+
+ protected function tearDown() {
+ if ($this->instance) {
+ $this->instance->rmdir('/');
+ }
+
+ parent::tearDown();
+ }
+
+ /**
+ * @expectedException InvalidArgumentException
+ */
+ public function testInvalidAddressShouldThrowException() {
+ # I'd use example.com for this, but someone decided to break the spec and make it resolve
+ $this->instance->assertHostAddressValid('notarealaddress...');
+ }
+
+ public function testValidAddressShouldPass() {
+ $this->assertTrue($this->instance->assertHostAddressValid('localhost'));
+ }
+
+ /**
+ * @expectedException InvalidArgumentException
+ */
+ public function testNegativePortNumberShouldThrowException() {
+ $this->instance->assertPortNumberValid('-1');
+ }
+
+ /**
+ * @expectedException InvalidArgumentException
+ */
+ public function testNonNumericalPortNumberShouldThrowException() {
+ $this->instance->assertPortNumberValid('a');
+ }
+
+ /**
+ * @expectedException InvalidArgumentException
+ */
+ public function testHighPortNumberShouldThrowException() {
+ $this->instance->assertPortNumberValid('65536');
+ }
+
+ public function testValidPortNumberShouldPass() {
+ $this->assertTrue($this->instance->assertPortNumberValid('22222'));
+ }
+}
diff --git a/apps/files_external/tests/config.php b/apps/files_external/tests/config.php
index 62aff4d1bc1..cf9cdfeead8 100644
--- a/apps/files_external/tests/config.php
+++ b/apps/files_external/tests/config.php
@@ -88,5 +88,13 @@ return array(
'user'=>'test',
'password'=>'test',
'root'=>'/test'
- )
+ ),
+ 'sftp_key' => array (
+ 'run'=>false,
+ 'host'=>'localhost',
+ 'user'=>'test',
+ 'public_key'=>'ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAAgQDJPTvz3OLonF2KSGEKP/nd4CPmRYvemG2T4rIiNYjDj0U5y+2sKEWbjiUlQl2bsqYuVoJ+/UNJlGQbbZ08kQirFeo1GoWBzqioaTjUJfbLN6TzVVKXxR9YIVmH7Ajg2iEeGCndGgbmnPfj+kF9TR9IH8vMVvtubQwf7uEwB0ALhw== phpseclib-generated-key',
+ 'private_key'=>'test',
+ 'root'=>'/test'
+ ),
);
diff --git a/apps/files_sharing/l10n/ja.js b/apps/files_sharing/l10n/ja.js
index e82bfd6c612..8608d02f617 100644
--- a/apps/files_sharing/l10n/ja.js
+++ b/apps/files_sharing/l10n/ja.js
@@ -24,8 +24,8 @@ OC.L10N.register(
"Invalid ownCloud url" : "無効なownCloud URL です",
"Share" : "共有",
"Shared by" : "共有者:",
- "A file or folder was shared from <strong>another server</strong>" : "ファイルまたはフォルダーは <strong>他のサーバー</strong>から共有されました",
- "A public shared file or folder was <strong>downloaded</strong>" : "公開共有ファイルまたはフォルダーは<strong>ダウンロード済み</strong>です",
+ "A file or folder was shared from <strong>another server</strong>" : "ファイルまたはフォルダーが<strong>他のサーバー</strong>から共有されたとき",
+ "A public shared file or folder was <strong>downloaded</strong>" : "公開共有ファイルまたはフォルダーが<strong>ダウンロードされた</strong>とき",
"You received a new remote share from %s" : "%sからリモート共有のリクエストは\n届きました。",
"Public shared folder %1$s was downloaded" : "公開共有フォルダ %1$s がダウンロードされました",
"Public shared file %1$s was downloaded" : "公開共有ファイル %1$s がダウンロードされました",
@@ -45,6 +45,7 @@ OC.L10N.register(
"Download" : "ダウンロード",
"Download %s" : "%s をダウンロード",
"Direct link" : "リンク",
+ "Federated Cloud Sharing" : "統合されたクラウド共有",
"Allow users on this server to send shares to other servers" : "ユーザーがこのサーバーから他のサーバーに共有することを許可する",
"Allow users on this server to receive shares from other servers" : "ユーザーが他のサーバーからこのサーバーに共有することを許可する"
},
diff --git a/apps/files_sharing/l10n/ja.json b/apps/files_sharing/l10n/ja.json
index 375ab797b58..017596b2172 100644
--- a/apps/files_sharing/l10n/ja.json
+++ b/apps/files_sharing/l10n/ja.json
@@ -22,8 +22,8 @@
"Invalid ownCloud url" : "無効なownCloud URL です",
"Share" : "共有",
"Shared by" : "共有者:",
- "A file or folder was shared from <strong>another server</strong>" : "ファイルまたはフォルダーは <strong>他のサーバー</strong>から共有されました",
- "A public shared file or folder was <strong>downloaded</strong>" : "公開共有ファイルまたはフォルダーは<strong>ダウンロード済み</strong>です",
+ "A file or folder was shared from <strong>another server</strong>" : "ファイルまたはフォルダーが<strong>他のサーバー</strong>から共有されたとき",
+ "A public shared file or folder was <strong>downloaded</strong>" : "公開共有ファイルまたはフォルダーが<strong>ダウンロードされた</strong>とき",
"You received a new remote share from %s" : "%sからリモート共有のリクエストは\n届きました。",
"Public shared folder %1$s was downloaded" : "公開共有フォルダ %1$s がダウンロードされました",
"Public shared file %1$s was downloaded" : "公開共有ファイル %1$s がダウンロードされました",
@@ -43,6 +43,7 @@
"Download" : "ダウンロード",
"Download %s" : "%s をダウンロード",
"Direct link" : "リンク",
+ "Federated Cloud Sharing" : "統合されたクラウド共有",
"Allow users on this server to send shares to other servers" : "ユーザーがこのサーバーから他のサーバーに共有することを許可する",
"Allow users on this server to receive shares from other servers" : "ユーザーが他のサーバーからこのサーバーに共有することを許可する"
},"pluralForm" :"nplurals=1; plural=0;"
diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php
index 21f807f3533..e0737834812 100644
--- a/apps/files_sharing/lib/cache.php
+++ b/apps/files_sharing/lib/cache.php
@@ -45,7 +45,7 @@ class Shared_Cache extends Cache {
* Get the source cache of a shared file or folder
*
* @param string $target Shared target file path
- * @return \OC\Files\Cache\Cache
+ * @return \OC\Files\Cache\Cache|false
*/
private function getSourceCache($target) {
if ($target === false || $target === $this->storage->getMountPoint()) {
@@ -82,7 +82,7 @@ class Shared_Cache extends Cache {
* get the stored metadata of a file or folder
*
* @param string|int $file
- * @return array
+ * @return array|false
*/
public function get($file) {
if (is_string($file)) {
@@ -148,7 +148,7 @@ class Shared_Cache extends Cache {
* get the metadata of all files stored in $folder
*
* @param string $folderId
- * @return array
+ * @return array|false
*/
public function getFolderContentsById($folderId) {
$cache = $this->getSourceCache('');
@@ -178,7 +178,7 @@ class Shared_Cache extends Cache {
* @param string $file
* @param array $data
*
- * @return int file id
+ * @return int|false file id
*/
public function put($file, array $data) {
$file = ($file === false) ? '' : $file;
diff --git a/apps/files_sharing/lib/controllers/sharecontroller.php b/apps/files_sharing/lib/controllers/sharecontroller.php
index cd013d4ca96..34339154b5c 100644
--- a/apps/files_sharing/lib/controllers/sharecontroller.php
+++ b/apps/files_sharing/lib/controllers/sharecontroller.php
@@ -131,7 +131,7 @@ class ShareController extends Controller {
*
* @param string $token
* @param string $path
- * @return TemplateResponse
+ * @return TemplateResponse|RedirectResponse
*/
public function showShare($token, $path = '') {
\OC_User::setIncognitoMode(true);
diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php
index d992f8f70b4..ccfbebddb29 100644
--- a/apps/files_sharing/lib/sharedstorage.php
+++ b/apps/files_sharing/lib/sharedstorage.php
@@ -80,7 +80,7 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage {
/**
* Get the source file path for a shared file
* @param string $target Shared target file path
- * @return string source file path or false if not found
+ * @return string|false source file path or false if not found
*/
public function getSourcePath($target) {
$source = $this->getFile($target);
diff --git a/apps/files_versions/l10n/de.js b/apps/files_versions/l10n/de.js
index 71905567b34..012167a7329 100644
--- a/apps/files_versions/l10n/de.js
+++ b/apps/files_versions/l10n/de.js
@@ -4,7 +4,7 @@ OC.L10N.register(
"Could not revert: %s" : "Konnte %s nicht zurücksetzen",
"Versions" : "Versionen",
"Failed to revert {file} to revision {timestamp}." : "Konnte {file} der Revision {timestamp} nicht rückgängig machen.",
- "More versions..." : "Weitere Versionen...",
+ "More versions..." : "Weitere Versionen…",
"No other versions available" : "Keine anderen Versionen verfügbar",
"Restore" : "Wiederherstellen"
},
diff --git a/apps/files_versions/l10n/de.json b/apps/files_versions/l10n/de.json
index f6feac199e2..74d7f066df8 100644
--- a/apps/files_versions/l10n/de.json
+++ b/apps/files_versions/l10n/de.json
@@ -2,7 +2,7 @@
"Could not revert: %s" : "Konnte %s nicht zurücksetzen",
"Versions" : "Versionen",
"Failed to revert {file} to revision {timestamp}." : "Konnte {file} der Revision {timestamp} nicht rückgängig machen.",
- "More versions..." : "Weitere Versionen...",
+ "More versions..." : "Weitere Versionen…",
"No other versions available" : "Keine anderen Versionen verfügbar",
"Restore" : "Wiederherstellen"
},"pluralForm" :"nplurals=2; plural=(n != 1);"
diff --git a/apps/files_versions/l10n/de_DE.js b/apps/files_versions/l10n/de_DE.js
index 0b8e5cdeac7..012167a7329 100644
--- a/apps/files_versions/l10n/de_DE.js
+++ b/apps/files_versions/l10n/de_DE.js
@@ -4,7 +4,7 @@ OC.L10N.register(
"Could not revert: %s" : "Konnte %s nicht zurücksetzen",
"Versions" : "Versionen",
"Failed to revert {file} to revision {timestamp}." : "Konnte {file} der Revision {timestamp} nicht rückgängig machen.",
- "More versions..." : "Mehrere Versionen...",
+ "More versions..." : "Weitere Versionen…",
"No other versions available" : "Keine anderen Versionen verfügbar",
"Restore" : "Wiederherstellen"
},
diff --git a/apps/files_versions/l10n/de_DE.json b/apps/files_versions/l10n/de_DE.json
index 6e5a8ec3bdb..74d7f066df8 100644
--- a/apps/files_versions/l10n/de_DE.json
+++ b/apps/files_versions/l10n/de_DE.json
@@ -2,7 +2,7 @@
"Could not revert: %s" : "Konnte %s nicht zurücksetzen",
"Versions" : "Versionen",
"Failed to revert {file} to revision {timestamp}." : "Konnte {file} der Revision {timestamp} nicht rückgängig machen.",
- "More versions..." : "Mehrere Versionen...",
+ "More versions..." : "Weitere Versionen…",
"No other versions available" : "Keine anderen Versionen verfügbar",
"Restore" : "Wiederherstellen"
},"pluralForm" :"nplurals=2; plural=(n != 1);"
diff --git a/apps/user_ldap/ajax/wizard.php b/apps/user_ldap/ajax/wizard.php
index 48bfb56311c..7c4ef3a9a29 100644
--- a/apps/user_ldap/ajax/wizard.php
+++ b/apps/user_ldap/ajax/wizard.php
@@ -85,7 +85,7 @@ switch($action) {
exit;
}
} catch (\Exception $e) {
- \OCP\JSON::error(array('message' => $e->getMessage()));
+ \OCP\JSON::error(array('message' => $e->getMessage(), 'code' => $e->getCode()));
exit;
}
\OCP\JSON::error();
diff --git a/apps/user_ldap/js/settings.js b/apps/user_ldap/js/settings.js
index b1abb0994ba..768d62a18d1 100644
--- a/apps/user_ldap/js/settings.js
+++ b/apps/user_ldap/js/settings.js
@@ -351,7 +351,7 @@ var LdapWizard = {
encodeURIComponent($('#ldap_serverconfig_chooser').val());
LdapWizard.showSpinner(spinnerID);
- var request = LdapWizard.ajax(param,
+ LdapWizard.ajax(param,
function(result) {
LdapWizard.applyChanges(result);
LdapWizard.hideSpinner(spinnerID);
@@ -360,7 +360,7 @@ var LdapWizard = {
}
},
function (result) {
- OC.Notification.show('Counting the entries failed with, ' + result.message);
+ OC.Notification.showTemporary('Counting the entries failed with: ' + result.message);
LdapWizard.hideSpinner(spinnerID);
if(!_.isUndefined(doneCallback)) {
doneCallback(method);
@@ -371,11 +371,17 @@ var LdapWizard = {
},
countGroups: function(doneCallback) {
- LdapWizard._countThings('countGroups', '#ldap_group_count', doneCallback);
+ var groupFilter = $('#ldap_group_filter').val();
+ if(!_.isEmpty(groupFilter)) {
+ LdapWizard._countThings('countGroups', '#ldap_group_count', doneCallback);
+ }
},
countUsers: function(doneCallback) {
- LdapWizard._countThings('countUsers', '#ldap_user_count', doneCallback);
+ var userFilter = $('#ldap_userlist_filter').val();
+ if(!_.isEmpty(userFilter)) {
+ LdapWizard._countThings('countUsers', '#ldap_user_count', doneCallback);
+ }
},
/**
diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php
index b6394823947..76cd9713e4e 100644
--- a/apps/user_ldap/lib/access.php
+++ b/apps/user_ldap/lib/access.php
@@ -303,7 +303,7 @@ class Access extends LDAPUtility implements user\IUserTools {
/**
* returns the LDAP DN for the given internal ownCloud name of the user
* @param string $name the ownCloud name in question
- * @return string with the LDAP DN on success, otherwise false
+ * @return string|false with the LDAP DN on success, otherwise false
*/
public function username2dn($name) {
$fdn = $this->userMapper->getDNbyName($name);
@@ -322,7 +322,7 @@ class Access extends LDAPUtility implements user\IUserTools {
* returns the internal ownCloud name for the given LDAP DN of the group, false on DN outside of search DN or failure
* @param string $fdn the dn of the group object
* @param string $ldapName optional, the display name of the object
- * @return string with the name to use in ownCloud, false on DN outside of search DN
+ * @return string|false with the name to use in ownCloud, false on DN outside of search DN
*/
public function dn2groupname($fdn, $ldapName = null) {
//To avoid bypassing the base DN settings under certain circumstances
@@ -339,7 +339,7 @@ class Access extends LDAPUtility implements user\IUserTools {
* returns the internal ownCloud name for the given LDAP DN of the user, false on DN outside of search DN or failure
* @param string $dn the dn of the user object
* @param string $ldapName optional, the display name of the object
- * @return string with with the name to use in ownCloud
+ * @return string|false with with the name to use in ownCloud
*/
public function dn2username($fdn, $ldapName = null) {
//To avoid bypassing the base DN settings under certain circumstances
@@ -357,7 +357,7 @@ class Access extends LDAPUtility implements user\IUserTools {
* @param string $dn the dn of the user object
* @param string $ldapName optional, the display name of the object
* @param bool $isUser optional, whether it is a user object (otherwise group assumed)
- * @return string with with the name to use in ownCloud
+ * @return string|false with with the name to use in ownCloud
*/
public function dn2ocname($fdn, $ldapName = null, $isUser = true) {
if($isUser) {
@@ -508,7 +508,7 @@ class Access extends LDAPUtility implements user\IUserTools {
/**
* creates a unique name for internal ownCloud use for users. Don't call it directly.
* @param string $name the display name of the object
- * @return string with with the name to use in ownCloud or false if unsuccessful
+ * @return string|false with with the name to use in ownCloud or false if unsuccessful
*
* Instead of using this method directly, call
* createAltInternalOwnCloudName($name, true)
@@ -530,7 +530,7 @@ class Access extends LDAPUtility implements user\IUserTools {
/**
* creates a unique name for internal ownCloud use for groups. Don't call it directly.
* @param string $name the display name of the object
- * @return string with with the name to use in ownCloud or false if unsuccessful.
+ * @return string|false with with the name to use in ownCloud or false if unsuccessful.
*
* Instead of using this method directly, call
* createAltInternalOwnCloudName($name, false)
@@ -569,7 +569,7 @@ class Access extends LDAPUtility implements user\IUserTools {
* creates a unique name for internal ownCloud use.
* @param string $name the display name of the object
* @param boolean $isUser whether name should be created for a user (true) or a group (false)
- * @return string with with the name to use in ownCloud or false if unsuccessful
+ * @return string|false with with the name to use in ownCloud or false if unsuccessful
*/
private function createAltInternalOwnCloudName($name, $isUser) {
$originalTTL = $this->connection->ldapCacheTTL;
diff --git a/apps/user_ldap/lib/wizard.php b/apps/user_ldap/lib/wizard.php
index 2e4507a2585..ed9188bc880 100644
--- a/apps/user_ldap/lib/wizard.php
+++ b/apps/user_ldap/lib/wizard.php
@@ -110,7 +110,7 @@ class Wizard extends LDAPUtility {
return false;
}
$groupsTotal = ($groupsTotal !== false) ? $groupsTotal : 0;
- $output = self::$l->n('%s group found', '%s groups found', $groupsTotal, $groupsTotal);
+ $output = self::$l->n('%s group found', '%s groups found', $groupsTotal, array($groupsTotal));
$this->result->addChange('ldap_group_count', $output);
return $this->result;
}
@@ -124,7 +124,7 @@ class Wizard extends LDAPUtility {
$usersTotal = $this->countEntries($filter, 'users');
$usersTotal = ($usersTotal !== false) ? $usersTotal : 0;
- $output = self::$l->n('%s user found', '%s users found', $usersTotal, $usersTotal);
+ $output = self::$l->n('%s user found', '%s users found', $usersTotal, array($usersTotal));
$this->result->addChange('ldap_user_count', $output);
return $this->result;
}
@@ -314,7 +314,7 @@ class Wizard extends LDAPUtility {
/**
* detects the available LDAP attributes
- * @return array The instance's WizardResult instance
+ * @return array|false The instance's WizardResult instance
* @throws \Exception
*/
private function getUserAttributes() {
@@ -348,7 +348,7 @@ class Wizard extends LDAPUtility {
/**
* detects the available LDAP groups
- * @return WizardResult the instance's WizardResult instance
+ * @return WizardResult|false the instance's WizardResult instance
*/
public function determineGroupsForGroups() {
return $this->determineGroups('ldap_groupfilter_groups',
@@ -358,7 +358,7 @@ class Wizard extends LDAPUtility {
/**
* detects the available LDAP groups
- * @return WizardResult the instance's WizardResult instance
+ * @return WizardResult|false the instance's WizardResult instance
*/
public function determineGroupsForUsers() {
return $this->determineGroups('ldap_userfilter_groups',
@@ -370,7 +370,7 @@ class Wizard extends LDAPUtility {
* @param string $dbKey
* @param string $confKey
* @param bool $testMemberOf
- * @return WizardResult the instance's WizardResult instance
+ * @return WizardResult|false the instance's WizardResult instance
* @throws \Exception
*/
private function determineGroups($dbKey, $confKey, $testMemberOf = true) {
@@ -467,7 +467,7 @@ class Wizard extends LDAPUtility {
/**
* Detects the available object classes
- * @return WizardResult the instance's WizardResult instance
+ * @return WizardResult|false the instance's WizardResult instance
* @throws \Exception
*/
public function determineGroupObjectClasses() {
@@ -524,7 +524,7 @@ class Wizard extends LDAPUtility {
}
/**
- * @return WizardResult
+ * @return WizardResult|false
* @throws \Exception
*/
public function getGroupFilter() {
@@ -548,7 +548,7 @@ class Wizard extends LDAPUtility {
}
/**
- * @return WizardResult
+ * @return WizardResult|false
* @throws \Exception
*/
public function getUserListFilter() {
@@ -1146,7 +1146,7 @@ class Wizard extends LDAPUtility {
* Configuration class
* @param bool $po whether the objectClass with most result entries
* shall be pre-selected via the result
- * @return array, list of found items.
+ * @return array|false list of found items.
* @throws \Exception
*/
private function determineFeature($objectclasses, $attr, $dbkey, $confkey, $po = false) {
diff --git a/apps/user_ldap/user_ldap.php b/apps/user_ldap/user_ldap.php
index 051e760105b..270e94121d5 100644
--- a/apps/user_ldap/user_ldap.php
+++ b/apps/user_ldap/user_ldap.php
@@ -303,7 +303,7 @@ class USER_LDAP extends BackendUtility implements \OCP\IUserBackend, \OCP\UserIn
/**
* get display name of the user
* @param string $uid user ID of the user
- * @return string display name
+ * @return string|false display name
*/
public function getDisplayName($uid) {
if(!$this->userExists($uid)) {
diff --git a/config/config.sample.php b/config/config.sample.php
index 0f8abb5d5e5..42ef59f079c 100644
--- a/config/config.sample.php
+++ b/config/config.sample.php
@@ -669,6 +669,10 @@ $CONFIG = array(
* - OC\Preview\StarOffice
* - OC\Preview\SVG
* - OC\Preview\TIFF
+ *
+ * .. note:: Troubleshooting steps for the MS Word previews are available
+ * at the :doc:`collaborative_documents_configuration#troubleshooting` section
+ * of the Administrators Manual.
*
* The following providers are not available in Microsoft Windows:
*
diff --git a/core/css/share.css b/core/css/share.css
index de909219b76..3ebf3a4b220 100644
--- a/core/css/share.css
+++ b/core/css/share.css
@@ -16,6 +16,13 @@
padding:16px;
}
+@media only screen and (min-width: 768px) and (max-width: 990px) {
+ #dropdown {
+ /* this limits the dropdown to float below the sidebar for mid narrow screens */
+ left: 20px;
+ }
+}
+
#dropdown.shareDropDown .unshare.icon-loading-small {
margin-top: 1px;
}
diff --git a/core/js/js.js b/core/js/js.js
index 234cc328dfb..808c2c28adf 100644
--- a/core/js/js.js
+++ b/core/js/js.js
@@ -117,7 +117,7 @@ var OC={
/**
* Generates the absolute url for the given relative url, which can contain parameters.
* @param {string} url
- * @param params
+ * @param [params] params
* @return {string} Absolute URL for the given relative URL
*/
generateUrl: function(url, params) {
diff --git a/core/l10n/de.js b/core/l10n/de.js
index 78e9f741de5..453c3919e6b 100644
--- a/core/l10n/de.js
+++ b/core/l10n/de.js
@@ -34,7 +34,7 @@ OC.L10N.register(
"November" : "November",
"December" : "Dezember",
"Settings" : "Einstellungen",
- "Saving..." : "Speichern...",
+ "Saving..." : "Speichern…",
"Couldn't send reset email. Please contact your administrator." : "Die E-Mail zum Zurücksetzen konnte nicht versendet werden. Bitte kontaktiere Deinen Administrator.",
"The link to reset your password has been sent to your email. If you do not receive it within a reasonable amount of time, check your spam/junk folders.<br>If it is not there ask your local administrator." : "Der Link zum Rücksetzen Deines Passworts ist an Deine E-Mail-Adresse vesandt worden. Wenn Du ihn innerhalb eines annehmbaren Zeitraums nicht empfängst, prüfe Deine Spam-Ordner.<br>Sollte er sich nicht darin befinden, frage bei Deinem lokalen Administrator nach.",
"Your files are encrypted. If you haven't enabled the recovery key, there will be no way to get your data back after your password is reset.<br />If you are not sure what to do, please contact your administrator before you continue. <br />Do you really want to continue?" : "Deine Dateien sind verschlüsselt. Solltest Du den Wiederherstellungsschlüssel nicht aktiviert haben, gibt es keine Möglichkeit, Deine Daten zurückzuerhalten, nachdem Dein Passwort zurückgesetzt ist.<br />Falls Du Dir nicht sicher bist, was zu tun ist, kontaktiere bitte Deinen Administrator, bevor Du fortfährst.<br />Willst Du wirklich fortfahren?",
@@ -76,7 +76,7 @@ OC.L10N.register(
"Error while changing permissions" : "Fehler beim Ändern der Rechte",
"Shared with you and the group {group} by {owner}" : "{owner} hat dies mit Dir und der Gruppe {group} geteilt",
"Shared with you by {owner}" : "{owner} hat dies mit Dir geteilt",
- "Share with user or group …" : "Mit Benutzer oder Gruppe teilen ....",
+ "Share with user or group …" : "Mit Benutzer oder Gruppe teilen…",
"Share link" : "Link teilen",
"The public link will expire no later than {days} days after it is created" : "Der öffentliche Link wird spätestens {days} Tage nach seiner Erstellung ablaufen",
"Link" : "Link",
@@ -105,7 +105,7 @@ OC.L10N.register(
"Password protected" : "Durch ein Passwort geschützt",
"Error unsetting expiration date" : "Fehler beim Entfernen des Ablaufdatums",
"Error setting expiration date" : "Fehler beim Setzen des Ablaufdatums",
- "Sending ..." : "Sende ...",
+ "Sending ..." : "Senden…",
"Email sent" : "E-Mail wurde verschickt",
"Warning" : "Warnung",
"The object type is not specified." : "Der Objekttyp ist nicht angegeben.",
@@ -194,7 +194,7 @@ OC.L10N.register(
"For larger installations we recommend to choose a different database backend." : "Bei größeren Installationen wird die Wahl eines anderen Datenbank-Backends empfohlen.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Insbesondere bei Nutzung des Desktop Clients zur Dateisynchronisierung wird vom Einsatz von SQLite abgeraten.",
"Finish setup" : "Installation abschließen",
- "Finishing …" : "Abschließen ...",
+ "Finishing …" : "Abschließen…",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Diese Anwendung benötigt ein aktiviertes JavaScript zum korrekten Betrieb. Bitte <a href=\"http://enable-javascript.com/\" target=\"_blank\">aktiviere JavaScript</a> und lade diese Seite neu.",
"%s is available. Get more information on how to update." : "%s ist verfügbar. Hole weitere Informationen zu Aktualisierungen ein.",
"Log out" : "Abmelden",
diff --git a/core/l10n/de.json b/core/l10n/de.json
index 0aa0bfd50e0..0a0ed4865ec 100644
--- a/core/l10n/de.json
+++ b/core/l10n/de.json
@@ -32,7 +32,7 @@
"November" : "November",
"December" : "Dezember",
"Settings" : "Einstellungen",
- "Saving..." : "Speichern...",
+ "Saving..." : "Speichern…",
"Couldn't send reset email. Please contact your administrator." : "Die E-Mail zum Zurücksetzen konnte nicht versendet werden. Bitte kontaktiere Deinen Administrator.",
"The link to reset your password has been sent to your email. If you do not receive it within a reasonable amount of time, check your spam/junk folders.<br>If it is not there ask your local administrator." : "Der Link zum Rücksetzen Deines Passworts ist an Deine E-Mail-Adresse vesandt worden. Wenn Du ihn innerhalb eines annehmbaren Zeitraums nicht empfängst, prüfe Deine Spam-Ordner.<br>Sollte er sich nicht darin befinden, frage bei Deinem lokalen Administrator nach.",
"Your files are encrypted. If you haven't enabled the recovery key, there will be no way to get your data back after your password is reset.<br />If you are not sure what to do, please contact your administrator before you continue. <br />Do you really want to continue?" : "Deine Dateien sind verschlüsselt. Solltest Du den Wiederherstellungsschlüssel nicht aktiviert haben, gibt es keine Möglichkeit, Deine Daten zurückzuerhalten, nachdem Dein Passwort zurückgesetzt ist.<br />Falls Du Dir nicht sicher bist, was zu tun ist, kontaktiere bitte Deinen Administrator, bevor Du fortfährst.<br />Willst Du wirklich fortfahren?",
@@ -74,7 +74,7 @@
"Error while changing permissions" : "Fehler beim Ändern der Rechte",
"Shared with you and the group {group} by {owner}" : "{owner} hat dies mit Dir und der Gruppe {group} geteilt",
"Shared with you by {owner}" : "{owner} hat dies mit Dir geteilt",
- "Share with user or group …" : "Mit Benutzer oder Gruppe teilen ....",
+ "Share with user or group …" : "Mit Benutzer oder Gruppe teilen…",
"Share link" : "Link teilen",
"The public link will expire no later than {days} days after it is created" : "Der öffentliche Link wird spätestens {days} Tage nach seiner Erstellung ablaufen",
"Link" : "Link",
@@ -103,7 +103,7 @@
"Password protected" : "Durch ein Passwort geschützt",
"Error unsetting expiration date" : "Fehler beim Entfernen des Ablaufdatums",
"Error setting expiration date" : "Fehler beim Setzen des Ablaufdatums",
- "Sending ..." : "Sende ...",
+ "Sending ..." : "Senden…",
"Email sent" : "E-Mail wurde verschickt",
"Warning" : "Warnung",
"The object type is not specified." : "Der Objekttyp ist nicht angegeben.",
@@ -192,7 +192,7 @@
"For larger installations we recommend to choose a different database backend." : "Bei größeren Installationen wird die Wahl eines anderen Datenbank-Backends empfohlen.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Insbesondere bei Nutzung des Desktop Clients zur Dateisynchronisierung wird vom Einsatz von SQLite abgeraten.",
"Finish setup" : "Installation abschließen",
- "Finishing …" : "Abschließen ...",
+ "Finishing …" : "Abschließen…",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Diese Anwendung benötigt ein aktiviertes JavaScript zum korrekten Betrieb. Bitte <a href=\"http://enable-javascript.com/\" target=\"_blank\">aktiviere JavaScript</a> und lade diese Seite neu.",
"%s is available. Get more information on how to update." : "%s ist verfügbar. Hole weitere Informationen zu Aktualisierungen ein.",
"Log out" : "Abmelden",
diff --git a/core/l10n/de_DE.js b/core/l10n/de_DE.js
index 21d4775fdb0..847c9d80ac5 100644
--- a/core/l10n/de_DE.js
+++ b/core/l10n/de_DE.js
@@ -105,7 +105,7 @@ OC.L10N.register(
"Password protected" : "Passwortgeschützt",
"Error unsetting expiration date" : "Fehler beim Entfernen des Ablaufdatums",
"Error setting expiration date" : "Fehler beim Setzen des Ablaufdatums",
- "Sending ..." : "Sende ...",
+ "Sending ..." : "Senden…",
"Email sent" : "Email gesendet",
"Warning" : "Warnung",
"The object type is not specified." : "Der Objekttyp ist nicht angegeben.",
@@ -194,7 +194,7 @@ OC.L10N.register(
"For larger installations we recommend to choose a different database backend." : "Bei größeren Installationen wird die Wahl eines anderen Datenbank-Backends empfohlen.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Insbesondere bei Nutzung des Desktop Clients zur Dateisynchronisierung wird vom Einsatz von SQLite abgeraten.",
"Finish setup" : "Installation abschließen",
- "Finishing …" : "Abschließen ...",
+ "Finishing …" : "Abschließen…",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Diese Anwendung benötigt ein aktiviertes JavaScript, um richtig zu funktionieren. Bitte <a href=\"http://enable-javascript.com/\" target=\"_blank\">aktivieren Sie JavaScript</a> und laden Sie diese Seite neu.",
"%s is available. Get more information on how to update." : "%s ist verfügbar. Holen Sie weitere Informationen zu Aktualisierungen ein.",
"Log out" : "Abmelden",
diff --git a/core/l10n/de_DE.json b/core/l10n/de_DE.json
index 79d2e494085..2c19f56c115 100644
--- a/core/l10n/de_DE.json
+++ b/core/l10n/de_DE.json
@@ -103,7 +103,7 @@
"Password protected" : "Passwortgeschützt",
"Error unsetting expiration date" : "Fehler beim Entfernen des Ablaufdatums",
"Error setting expiration date" : "Fehler beim Setzen des Ablaufdatums",
- "Sending ..." : "Sende ...",
+ "Sending ..." : "Senden…",
"Email sent" : "Email gesendet",
"Warning" : "Warnung",
"The object type is not specified." : "Der Objekttyp ist nicht angegeben.",
@@ -192,7 +192,7 @@
"For larger installations we recommend to choose a different database backend." : "Bei größeren Installationen wird die Wahl eines anderen Datenbank-Backends empfohlen.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Insbesondere bei Nutzung des Desktop Clients zur Dateisynchronisierung wird vom Einsatz von SQLite abgeraten.",
"Finish setup" : "Installation abschließen",
- "Finishing …" : "Abschließen ...",
+ "Finishing …" : "Abschließen…",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Diese Anwendung benötigt ein aktiviertes JavaScript, um richtig zu funktionieren. Bitte <a href=\"http://enable-javascript.com/\" target=\"_blank\">aktivieren Sie JavaScript</a> und laden Sie diese Seite neu.",
"%s is available. Get more information on how to update." : "%s ist verfügbar. Holen Sie weitere Informationen zu Aktualisierungen ein.",
"Log out" : "Abmelden",
diff --git a/core/l10n/es.js b/core/l10n/es.js
index 05c65f263f9..2d4d8cdf659 100644
--- a/core/l10n/es.js
+++ b/core/l10n/es.js
@@ -191,6 +191,7 @@ OC.L10N.register(
"Database host" : "Host de la base de datos",
"Performance Warning" : "Advertencia de rendimiento",
"SQLite will be used as database." : "SQLite se empleará como base de datos.",
+ "For larger installations we recommend to choose a different database backend." : "Para grandes instalaciones recomendamos seleccionar una base de datos diferente",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "El uso de SQLite esta desaconsejado especialmente cuando se usa el cliente de escritorio para que se sincronizan los ficheros.",
"Finish setup" : "Completar la instalación",
"Finishing …" : "Finalizando...",
diff --git a/core/l10n/es.json b/core/l10n/es.json
index 0d327c3a818..e0c5f18a5d3 100644
--- a/core/l10n/es.json
+++ b/core/l10n/es.json
@@ -189,6 +189,7 @@
"Database host" : "Host de la base de datos",
"Performance Warning" : "Advertencia de rendimiento",
"SQLite will be used as database." : "SQLite se empleará como base de datos.",
+ "For larger installations we recommend to choose a different database backend." : "Para grandes instalaciones recomendamos seleccionar una base de datos diferente",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "El uso de SQLite esta desaconsejado especialmente cuando se usa el cliente de escritorio para que se sincronizan los ficheros.",
"Finish setup" : "Completar la instalación",
"Finishing …" : "Finalizando...",
diff --git a/core/l10n/fr.js b/core/l10n/fr.js
index 2ea5d59da1e..9060e5c0644 100644
--- a/core/l10n/fr.js
+++ b/core/l10n/fr.js
@@ -133,9 +133,9 @@ OC.L10N.register(
"New password" : "Nouveau mot de passe",
"New Password" : "Nouveau mot de passe",
"Reset password" : "Réinitialiser le mot de passe",
- "Searching other places" : "Recherche en cours dans d'autres lieux",
- "No search result in other places" : "Aucun résultat dans d'autres lieux",
- "_{count} search result in other places_::_{count} search results in other places_" : ["{count} résultat de recherche dans d'autres lieux","{count} résultats de recherche dans d'autres lieux"],
+ "Searching other places" : "Recherche en cours dans d'autres emplacements",
+ "No search result in other places" : "Aucun résultat dans d'autres emplacements",
+ "_{count} search result in other places_::_{count} search results in other places_" : ["{count} résultat de recherche dans d'autres lieux","{count} résultats de recherche dans d'autres emplacements"],
"Mac OS X is not supported and %s will not work properly on this platform. Use it at your own risk! " : "Mac OS X n'est pas pris en charge et %s ne fonctionnera pas correctement sur cette plate-forme. Son utilisation est à vos risques et périls !",
"For the best results, please consider using a GNU/Linux server instead." : "Pour obtenir les meilleurs résultats, vous devriez utiliser un serveur GNU/Linux.",
"It seems that this %s instance is running on a 32-bit PHP environment and the open_basedir has been configured in php.ini. This will lead to problems with files over 4GB and is highly discouraged." : "Il semble que cette instance %s fonctionne sur un environnement PHP 32-bits et open_basedir a été configuré dans php.ini. Cela engendre des problèmes avec les fichiers supérieurs à 4Go et cela est donc fortement déconseillé.",
diff --git a/core/l10n/fr.json b/core/l10n/fr.json
index a9a75750bde..7c03a4fc3fc 100644
--- a/core/l10n/fr.json
+++ b/core/l10n/fr.json
@@ -131,9 +131,9 @@
"New password" : "Nouveau mot de passe",
"New Password" : "Nouveau mot de passe",
"Reset password" : "Réinitialiser le mot de passe",
- "Searching other places" : "Recherche en cours dans d'autres lieux",
- "No search result in other places" : "Aucun résultat dans d'autres lieux",
- "_{count} search result in other places_::_{count} search results in other places_" : ["{count} résultat de recherche dans d'autres lieux","{count} résultats de recherche dans d'autres lieux"],
+ "Searching other places" : "Recherche en cours dans d'autres emplacements",
+ "No search result in other places" : "Aucun résultat dans d'autres emplacements",
+ "_{count} search result in other places_::_{count} search results in other places_" : ["{count} résultat de recherche dans d'autres lieux","{count} résultats de recherche dans d'autres emplacements"],
"Mac OS X is not supported and %s will not work properly on this platform. Use it at your own risk! " : "Mac OS X n'est pas pris en charge et %s ne fonctionnera pas correctement sur cette plate-forme. Son utilisation est à vos risques et périls !",
"For the best results, please consider using a GNU/Linux server instead." : "Pour obtenir les meilleurs résultats, vous devriez utiliser un serveur GNU/Linux.",
"It seems that this %s instance is running on a 32-bit PHP environment and the open_basedir has been configured in php.ini. This will lead to problems with files over 4GB and is highly discouraged." : "Il semble que cette instance %s fonctionne sur un environnement PHP 32-bits et open_basedir a été configuré dans php.ini. Cela engendre des problèmes avec les fichiers supérieurs à 4Go et cela est donc fortement déconseillé.",
diff --git a/core/l10n/ru.js b/core/l10n/ru.js
index 044f78ecec9..083f8ba780c 100644
--- a/core/l10n/ru.js
+++ b/core/l10n/ru.js
@@ -189,6 +189,9 @@ OC.L10N.register(
"Database name" : "Название базы данных",
"Database tablespace" : "Табличое пространство базы данных",
"Database host" : "Хост базы данных",
+ "Performance Warning" : "Предупреждение о производительности",
+ "SQLite will be used as database." : "В качестве базы данных будет использована SQLite.",
+ "For larger installations we recommend to choose a different database backend." : "Для крупных проектов мы советуем выбрать другую базу данных.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Особенно вызывает сомнение использование SQLite при синхронизации файлов с использование клиента для ПК.",
"Finish setup" : "Завершить установку",
"Finishing …" : "Завершение...",
diff --git a/core/l10n/ru.json b/core/l10n/ru.json
index 93fd051fa28..79c59badf61 100644
--- a/core/l10n/ru.json
+++ b/core/l10n/ru.json
@@ -187,6 +187,9 @@
"Database name" : "Название базы данных",
"Database tablespace" : "Табличое пространство базы данных",
"Database host" : "Хост базы данных",
+ "Performance Warning" : "Предупреждение о производительности",
+ "SQLite will be used as database." : "В качестве базы данных будет использована SQLite.",
+ "For larger installations we recommend to choose a different database backend." : "Для крупных проектов мы советуем выбрать другую базу данных.",
"Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Особенно вызывает сомнение использование SQLite при синхронизации файлов с использование клиента для ПК.",
"Finish setup" : "Завершить установку",
"Finishing …" : "Завершение...",
diff --git a/core/l10n/sk_SK.js b/core/l10n/sk_SK.js
index 81e82f331b0..a199c0e2930 100644
--- a/core/l10n/sk_SK.js
+++ b/core/l10n/sk_SK.js
@@ -134,7 +134,7 @@ OC.L10N.register(
"New Password" : "Nové heslo",
"Reset password" : "Obnovenie hesla",
"Searching other places" : "Prehľadanie ostatných umiestnení",
- "No search result in other places" : "Žiadne výsledky z prehľadávania ostatných umiestnení",
+ "No search result in other places" : "Žiadne výsledky z prehľadávania v ostatných umiestneniach",
"_{count} search result in other places_::_{count} search results in other places_" : ["{count} výsledok v ostatných umiestneniach","{count} výsledky v ostatných umiestneniach","{count} výsledkov v ostatných umiestneniach"],
"Mac OS X is not supported and %s will not work properly on this platform. Use it at your own risk! " : "Mac OS X nie je podporovaný a %s nebude správne fungovať na tejto platforme. Použite ho na vlastné riziko!",
"For the best results, please consider using a GNU/Linux server instead." : "Pre dosiahnutie najlepších výsledkov, prosím zvážte použitie GNU/Linux servera.",
@@ -189,6 +189,10 @@ OC.L10N.register(
"Database name" : "Meno databázy",
"Database tablespace" : "Tabuľkový priestor databázy",
"Database host" : "Server databázy",
+ "Performance Warning" : "Varovanie o výkone",
+ "SQLite will be used as database." : "Bude použitá SQLite databáza.",
+ "For larger installations we recommend to choose a different database backend." : "Pre veľké inštalácie odporúčame vybrať si iné databázové riešenie.",
+ "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Najmä pri používaní klientských aplikácií na synchronizáciu s desktopom neodporúčame používať SQLite.",
"Finish setup" : "Dokončiť inštaláciu",
"Finishing …" : "Dokončujem...",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Táto aplikácia potrebuje JavaScript pre správne fungovanie. Prosím <a href=\"http://enable-javascript.com/\" target=\"_blank\">zapnite si JavaScript</a> a obnovte stránku",
diff --git a/core/l10n/sk_SK.json b/core/l10n/sk_SK.json
index 903de55ee4a..7a3b0e2240d 100644
--- a/core/l10n/sk_SK.json
+++ b/core/l10n/sk_SK.json
@@ -132,7 +132,7 @@
"New Password" : "Nové heslo",
"Reset password" : "Obnovenie hesla",
"Searching other places" : "Prehľadanie ostatných umiestnení",
- "No search result in other places" : "Žiadne výsledky z prehľadávania ostatných umiestnení",
+ "No search result in other places" : "Žiadne výsledky z prehľadávania v ostatných umiestneniach",
"_{count} search result in other places_::_{count} search results in other places_" : ["{count} výsledok v ostatných umiestneniach","{count} výsledky v ostatných umiestneniach","{count} výsledkov v ostatných umiestneniach"],
"Mac OS X is not supported and %s will not work properly on this platform. Use it at your own risk! " : "Mac OS X nie je podporovaný a %s nebude správne fungovať na tejto platforme. Použite ho na vlastné riziko!",
"For the best results, please consider using a GNU/Linux server instead." : "Pre dosiahnutie najlepších výsledkov, prosím zvážte použitie GNU/Linux servera.",
@@ -187,6 +187,10 @@
"Database name" : "Meno databázy",
"Database tablespace" : "Tabuľkový priestor databázy",
"Database host" : "Server databázy",
+ "Performance Warning" : "Varovanie o výkone",
+ "SQLite will be used as database." : "Bude použitá SQLite databáza.",
+ "For larger installations we recommend to choose a different database backend." : "Pre veľké inštalácie odporúčame vybrať si iné databázové riešenie.",
+ "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Najmä pri používaní klientských aplikácií na synchronizáciu s desktopom neodporúčame používať SQLite.",
"Finish setup" : "Dokončiť inštaláciu",
"Finishing …" : "Dokončujem...",
"This application requires JavaScript for correct operation. Please <a href=\"http://enable-javascript.com/\" target=\"_blank\">enable JavaScript</a> and reload the page." : "Táto aplikácia potrebuje JavaScript pre správne fungovanie. Prosím <a href=\"http://enable-javascript.com/\" target=\"_blank\">zapnite si JavaScript</a> a obnovte stránku",
diff --git a/l10n/l10n.pl b/l10n/l10n.pl
index 7443a5f941d..26ed4ecba30 100644
--- a/l10n/l10n.pl
+++ b/l10n/l10n.pl
@@ -44,7 +44,7 @@ sub crawlFiles{
push( @found, crawlFiles( $dir.'/'.$i ));
}
else{
- push(@found,$dir.'/'.$i) if $i =~ /\.js$/ || $i =~ /\.php$/;
+ push(@found,$dir.'/'.$i) if $i =~ /.*(?<!\.min)\.js$/ || $i =~ /\.php$/;
}
}
diff --git a/lib/l10n/de.js b/lib/l10n/de.js
index 91f2544058b..0ed8a3b208a 100644
--- a/lib/l10n/de.js
+++ b/lib/l10n/de.js
@@ -1,7 +1,7 @@
OC.L10N.register(
"lib",
{
- "Cannot write into \"config\" directory!" : "Das Schreiben in das \"config\"-Verzeichnis ist nicht möglich!",
+ "Cannot write into \"config\" directory!" : "Das Schreiben in das „config“-Verzeichnis ist nicht möglich!",
"This can usually be fixed by giving the webserver write access to the config directory" : "Dies kann normalerweise repariert werden, indem dem Webserver Schreibzugriff auf das config-Verzeichnis gegeben wird",
"See %s" : "Siehe %s",
"This can usually be fixed by %sgiving the webserver write access to the config directory%s." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das config-Verzeichnis %s gegeben wird.",
@@ -25,7 +25,7 @@ OC.L10N.register(
"Recommended" : "Empfohlen",
"App \\\"%s\\\" can't be installed because it is not compatible with this version of ownCloud." : "Applikation \\\"%s\\\" kann nicht installiert werden, da sie mit dieser ownCloud Version nicht kompatibel ist.",
"App \\\"%s\\\" cannot be installed because the following dependencies are not fulfilled: %s" : "Die App \\\"%s\\\" kann nicht installiert werden, weil die folgenden Abhängigkeiten nicht erfüllt sind: %s",
- "No app name specified" : "Es wurde kein Applikation-Name angegeben",
+ "No app name specified" : "Es wurde kein App-Name angegeben",
"Unknown filetype" : "Unbekannter Dateityp",
"Invalid image" : "Ungültiges Bild",
"today" : "Heute",
@@ -48,35 +48,35 @@ OC.L10N.register(
"No path specified when installing app from local file" : "Bei der Installation der Applikation aus einer lokalen Datei wurde kein Pfad angegeben",
"Archives of type %s are not supported" : "Archive vom Typ %s werden nicht unterstützt",
"Failed to open archive when installing app" : "Das Archiv konnte bei der Installation der Applikation nicht geöffnet werden",
- "App does not provide an info.xml file" : "Die Applikation enthält keine info,xml Datei",
+ "App does not provide an info.xml file" : "Die Applikation enthält keine info.xml Datei",
"App can't be installed because of not allowed code in the App" : "Die Applikation kann auf Grund von unerlaubtem Code nicht installiert werden",
"App can't be installed because it is not compatible with this version of ownCloud" : "Die Anwendung konnte nicht installiert werden, weil Sie nicht mit dieser Version von ownCloud kompatibel ist.",
"App can't be installed because it contains the <shipped>true</shipped> tag which is not allowed for non shipped apps" : "Die Applikation konnte nicht installiert werden, da diese das <shipped>true</shipped> Tag beinhaltet und dieses, bei nicht mitausgelieferten Applikationen, nicht erlaubt ist",
"App can't be installed because the version in info.xml/version is not the same as the version reported from the app store" : "Die Applikation konnte nicht installiert werden, da die Version in der info.xml nicht die gleiche Version wie im App-Store ist",
"Application is not enabled" : "Die Anwendung ist nicht aktiviert",
- "Authentication error" : "Fehler bei der Anmeldung",
+ "Authentication error" : "Authentifizierungsfehler",
"Token expired. Please reload page." : "Token abgelaufen. Bitte lade die Seite neu.",
"Unknown user" : "Unbekannter Benutzer",
"%s enter the database username." : "%s gib den Datenbank-Benutzernamen an.",
- "%s enter the database name." : "%s gib den Datenbank-Namen an.",
- "%s you may not use dots in the database name" : "%s Der Datenbank-Name darf keine Punkte enthalten",
- "MS SQL username and/or password not valid: %s" : "MS SQL Benutzername und/oder Password ungültig: %s",
- "You need to enter either an existing account or the administrator." : "Du musst entweder ein existierendes Benutzerkonto oder das Administratoren-Konto angeben.",
- "MySQL/MariaDB username and/or password not valid" : "MySQL/MariaDB Benutzername und/oder Passwort sind nicht gültig",
- "DB Error: \"%s\"" : "DB Fehler: \"%s\"",
- "Offending command was: \"%s\"" : "Fehlerhafter Befehl war: \"%s\"",
+ "%s enter the database name." : "%s gib den Datenbanknamen an.",
+ "%s you may not use dots in the database name" : "%s Der Datenbankname darf keine Punkte enthalten",
+ "MS SQL username and/or password not valid: %s" : "MS SQL-Benutzername und/oder -Passwort ungültig: %s",
+ "You need to enter either an existing account or the administrator." : "Du musst entweder ein existierendes Benutzerkonto oder das Administratorenkonto angeben.",
+ "MySQL/MariaDB username and/or password not valid" : "MySQL/MariaDB-Benutzername und/oder -Passwort sind nicht gültig",
+ "DB Error: \"%s\"" : "DB-Fehler: „%s“",
+ "Offending command was: \"%s\"" : "Fehlerhafter Befehl war: „%s“",
"MySQL/MariaDB user '%s'@'localhost' exists already." : "MySQL/MariaDB Benutzer '%s'@'localhost' existiert bereits.",
- "Drop this user from MySQL/MariaDB" : "Lösche diesen Benutzer von MySQL/MariaDB",
- "MySQL/MariaDB user '%s'@'%%' already exists" : "MySQL/MariaDB Benutzer '%s'@'%%' existiert bereits",
- "Drop this user from MySQL/MariaDB." : "Lösche diesen Benutzer von MySQL/MariaDB.",
+ "Drop this user from MySQL/MariaDB" : "Diesen Benutzer aus MySQL/MariaDB löschen",
+ "MySQL/MariaDB user '%s'@'%%' already exists" : "MySQL/MariaDB-Benutzer '%s'@'%%' existiert bereits",
+ "Drop this user from MySQL/MariaDB." : "Diesen Benutzer aus MySQL/MariaDB löschen.",
"Oracle connection could not be established" : "Es konnte keine Verbindung zur Oracle-Datenbank hergestellt werden",
- "Oracle username and/or password not valid" : "Oracle Benutzername und/oder Passwort ungültig",
- "Offending command was: \"%s\", name: %s, password: %s" : "Fehlerhafter Befehl war: \"%s\", Name: %s, Passwort: %s",
- "PostgreSQL username and/or password not valid" : "PostgreSQL Benutzername und/oder Passwort ungültig",
- "Set an admin username." : "Setze Administrator Benutzername.",
- "Set an admin password." : "Setze Administrator Passwort",
- "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder beschreiben werden",
- "%s shared »%s« with you" : "%s teilte »%s« mit Dir",
+ "Oracle username and/or password not valid" : "Oracle-Benutzername und/oder -Passwort ungültig",
+ "Offending command was: \"%s\", name: %s, password: %s" : "Fehlerhafter Befehl war: „%s“, Name: %s, Passwort: %s",
+ "PostgreSQL username and/or password not valid" : "PostgreSQL-Benutzername und/oder -Passwort ungültig",
+ "Set an admin username." : "Einen Administrator-Benutzernamen setzen.",
+ "Set an admin password." : "Ein Administrator-Passwort setzen.",
+ "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder es kann darin nicht geschrieben werden.",
+ "%s shared »%s« with you" : "%s hat „%s“ mit Dir geteilt",
"Sharing %s failed, because the backend does not allow shares from type %i" : "Freigabe von %s fehlgeschlagen, da das Backend die Freigabe vom Typ %i nicht erlaubt.",
"Sharing %s failed, because the file does not exist" : "Freigabe von %s fehlgeschlagen, da die Datei nicht existiert",
"You are not allowed to share %s" : "Die Freigabe von %s ist Dir nicht erlaubt",
@@ -103,16 +103,16 @@ OC.L10N.register(
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Freigabe von %s fehlgeschlagen, da das Freigabe-Backend für %s nicht in dieser Quelle gefunden werden konnte",
"Sharing %s failed, because the file could not be found in the file cache" : "Freigabe von %s fehlgeschlagen, da die Datei im Datei-Cache nicht gefunden werden konnte",
"Could not find category \"%s\"" : "Die Kategorie \"%s\" konnte nicht gefunden werden.",
- "Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: \"a-z\", \"A-Z\", \"0-9\" und \"_.@-\"",
+ "Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: „a-z“, „A-Z“, „0-9“ und „_.@-“",
"A valid username must be provided" : "Es muss ein gültiger Benutzername angegeben werden",
"A valid password must be provided" : "Es muss ein gültiges Passwort angegeben werden",
"The username is already being used" : "Dieser Benutzername existiert bereits",
- "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL, oder PostgreSQL) installiert.",
+ "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MySQL oder PostgreSQL) installiert.",
"Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Berechtigungen können normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Wurzelverzeichnis %s gegeben wird.",
- "Cannot write into \"config\" directory" : "Das Schreiben in das \"config\"-Verzeichnis nicht möglich",
- "Cannot write into \"apps\" directory" : "Das Schreiben in das \"apps\"-Verzeichnis nicht möglich",
+ "Cannot write into \"config\" directory" : "Das Schreiben in das „config“-Verzeichnis ist nicht möglich",
+ "Cannot write into \"apps\" directory" : "Das Schreiben in das „apps“-Verzeichnis ist nicht möglich",
"This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Anwendungsverzeichnis %s gegeben wird oder die Anwendungsauswahl in der Konfigurationsdatei deaktiviert wird.",
- "Cannot create \"data\" directory (%s)" : "Das Erstellen des \"data\"-Verzeichnisses nicht möglich (%s)",
+ "Cannot create \"data\" directory (%s)" : "Das Erstellen des „data“-Verzeichnisses ist nicht möglich (%s)",
"This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Dies kann normalerweise repariert werden, indem dem Webserver <a href=\"%s\" target=\"_blank\" Schreibzugriff auf das Wurzelverzeichnis gegeben wird</a>.",
"Setting locale to %s failed" : "Das Setzen der Umgebungslokale auf %s fehlgeschlagen",
"Please install one of these locales on your system and restart your webserver." : "Bitte installiere eine dieser Sprachen auf Deinem System und starte den Webserver neu.",
@@ -132,7 +132,7 @@ OC.L10N.register(
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Bitte ändere die Berechtigungen auf 0770 sodass das Verzeichnis nicht von anderen Nutzer angezeigt werden kann.",
"Data directory (%s) is readable by other users" : "Daten-Verzeichnis (%s) ist von anderen Nutzern lesbar",
"Data directory (%s) is invalid" : "Daten-Verzeichnis (%s) ist ungültig",
- "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stelle sicher, dass das Daten-Verzeichnis eine Datei namens \".ocdata\" im Wurzelverzeichnis enthält.",
+ "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stelle sicher, dass das Datenverzeichnis auf seiner ersten Ebene eine Datei namens „.ocdata“ enthält.",
"Could not obtain lock type %d on \"%s\"." : "Sperrtyp %d auf \"%s\" konnte nicht ermittelt werden."
},
"nplurals=2; plural=(n != 1);");
diff --git a/lib/l10n/de.json b/lib/l10n/de.json
index ae255cd7b1e..6f101492749 100644
--- a/lib/l10n/de.json
+++ b/lib/l10n/de.json
@@ -1,5 +1,5 @@
{ "translations": {
- "Cannot write into \"config\" directory!" : "Das Schreiben in das \"config\"-Verzeichnis ist nicht möglich!",
+ "Cannot write into \"config\" directory!" : "Das Schreiben in das „config“-Verzeichnis ist nicht möglich!",
"This can usually be fixed by giving the webserver write access to the config directory" : "Dies kann normalerweise repariert werden, indem dem Webserver Schreibzugriff auf das config-Verzeichnis gegeben wird",
"See %s" : "Siehe %s",
"This can usually be fixed by %sgiving the webserver write access to the config directory%s." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das config-Verzeichnis %s gegeben wird.",
@@ -23,7 +23,7 @@
"Recommended" : "Empfohlen",
"App \\\"%s\\\" can't be installed because it is not compatible with this version of ownCloud." : "Applikation \\\"%s\\\" kann nicht installiert werden, da sie mit dieser ownCloud Version nicht kompatibel ist.",
"App \\\"%s\\\" cannot be installed because the following dependencies are not fulfilled: %s" : "Die App \\\"%s\\\" kann nicht installiert werden, weil die folgenden Abhängigkeiten nicht erfüllt sind: %s",
- "No app name specified" : "Es wurde kein Applikation-Name angegeben",
+ "No app name specified" : "Es wurde kein App-Name angegeben",
"Unknown filetype" : "Unbekannter Dateityp",
"Invalid image" : "Ungültiges Bild",
"today" : "Heute",
@@ -46,35 +46,35 @@
"No path specified when installing app from local file" : "Bei der Installation der Applikation aus einer lokalen Datei wurde kein Pfad angegeben",
"Archives of type %s are not supported" : "Archive vom Typ %s werden nicht unterstützt",
"Failed to open archive when installing app" : "Das Archiv konnte bei der Installation der Applikation nicht geöffnet werden",
- "App does not provide an info.xml file" : "Die Applikation enthält keine info,xml Datei",
+ "App does not provide an info.xml file" : "Die Applikation enthält keine info.xml Datei",
"App can't be installed because of not allowed code in the App" : "Die Applikation kann auf Grund von unerlaubtem Code nicht installiert werden",
"App can't be installed because it is not compatible with this version of ownCloud" : "Die Anwendung konnte nicht installiert werden, weil Sie nicht mit dieser Version von ownCloud kompatibel ist.",
"App can't be installed because it contains the <shipped>true</shipped> tag which is not allowed for non shipped apps" : "Die Applikation konnte nicht installiert werden, da diese das <shipped>true</shipped> Tag beinhaltet und dieses, bei nicht mitausgelieferten Applikationen, nicht erlaubt ist",
"App can't be installed because the version in info.xml/version is not the same as the version reported from the app store" : "Die Applikation konnte nicht installiert werden, da die Version in der info.xml nicht die gleiche Version wie im App-Store ist",
"Application is not enabled" : "Die Anwendung ist nicht aktiviert",
- "Authentication error" : "Fehler bei der Anmeldung",
+ "Authentication error" : "Authentifizierungsfehler",
"Token expired. Please reload page." : "Token abgelaufen. Bitte lade die Seite neu.",
"Unknown user" : "Unbekannter Benutzer",
"%s enter the database username." : "%s gib den Datenbank-Benutzernamen an.",
- "%s enter the database name." : "%s gib den Datenbank-Namen an.",
- "%s you may not use dots in the database name" : "%s Der Datenbank-Name darf keine Punkte enthalten",
- "MS SQL username and/or password not valid: %s" : "MS SQL Benutzername und/oder Password ungültig: %s",
- "You need to enter either an existing account or the administrator." : "Du musst entweder ein existierendes Benutzerkonto oder das Administratoren-Konto angeben.",
- "MySQL/MariaDB username and/or password not valid" : "MySQL/MariaDB Benutzername und/oder Passwort sind nicht gültig",
- "DB Error: \"%s\"" : "DB Fehler: \"%s\"",
- "Offending command was: \"%s\"" : "Fehlerhafter Befehl war: \"%s\"",
+ "%s enter the database name." : "%s gib den Datenbanknamen an.",
+ "%s you may not use dots in the database name" : "%s Der Datenbankname darf keine Punkte enthalten",
+ "MS SQL username and/or password not valid: %s" : "MS SQL-Benutzername und/oder -Passwort ungültig: %s",
+ "You need to enter either an existing account or the administrator." : "Du musst entweder ein existierendes Benutzerkonto oder das Administratorenkonto angeben.",
+ "MySQL/MariaDB username and/or password not valid" : "MySQL/MariaDB-Benutzername und/oder -Passwort sind nicht gültig",
+ "DB Error: \"%s\"" : "DB-Fehler: „%s“",
+ "Offending command was: \"%s\"" : "Fehlerhafter Befehl war: „%s“",
"MySQL/MariaDB user '%s'@'localhost' exists already." : "MySQL/MariaDB Benutzer '%s'@'localhost' existiert bereits.",
- "Drop this user from MySQL/MariaDB" : "Lösche diesen Benutzer von MySQL/MariaDB",
- "MySQL/MariaDB user '%s'@'%%' already exists" : "MySQL/MariaDB Benutzer '%s'@'%%' existiert bereits",
- "Drop this user from MySQL/MariaDB." : "Lösche diesen Benutzer von MySQL/MariaDB.",
+ "Drop this user from MySQL/MariaDB" : "Diesen Benutzer aus MySQL/MariaDB löschen",
+ "MySQL/MariaDB user '%s'@'%%' already exists" : "MySQL/MariaDB-Benutzer '%s'@'%%' existiert bereits",
+ "Drop this user from MySQL/MariaDB." : "Diesen Benutzer aus MySQL/MariaDB löschen.",
"Oracle connection could not be established" : "Es konnte keine Verbindung zur Oracle-Datenbank hergestellt werden",
- "Oracle username and/or password not valid" : "Oracle Benutzername und/oder Passwort ungültig",
- "Offending command was: \"%s\", name: %s, password: %s" : "Fehlerhafter Befehl war: \"%s\", Name: %s, Passwort: %s",
- "PostgreSQL username and/or password not valid" : "PostgreSQL Benutzername und/oder Passwort ungültig",
- "Set an admin username." : "Setze Administrator Benutzername.",
- "Set an admin password." : "Setze Administrator Passwort",
- "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder beschreiben werden",
- "%s shared »%s« with you" : "%s teilte »%s« mit Dir",
+ "Oracle username and/or password not valid" : "Oracle-Benutzername und/oder -Passwort ungültig",
+ "Offending command was: \"%s\", name: %s, password: %s" : "Fehlerhafter Befehl war: „%s“, Name: %s, Passwort: %s",
+ "PostgreSQL username and/or password not valid" : "PostgreSQL-Benutzername und/oder -Passwort ungültig",
+ "Set an admin username." : "Einen Administrator-Benutzernamen setzen.",
+ "Set an admin password." : "Ein Administrator-Passwort setzen.",
+ "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder es kann darin nicht geschrieben werden.",
+ "%s shared »%s« with you" : "%s hat „%s“ mit Dir geteilt",
"Sharing %s failed, because the backend does not allow shares from type %i" : "Freigabe von %s fehlgeschlagen, da das Backend die Freigabe vom Typ %i nicht erlaubt.",
"Sharing %s failed, because the file does not exist" : "Freigabe von %s fehlgeschlagen, da die Datei nicht existiert",
"You are not allowed to share %s" : "Die Freigabe von %s ist Dir nicht erlaubt",
@@ -101,16 +101,16 @@
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Freigabe von %s fehlgeschlagen, da das Freigabe-Backend für %s nicht in dieser Quelle gefunden werden konnte",
"Sharing %s failed, because the file could not be found in the file cache" : "Freigabe von %s fehlgeschlagen, da die Datei im Datei-Cache nicht gefunden werden konnte",
"Could not find category \"%s\"" : "Die Kategorie \"%s\" konnte nicht gefunden werden.",
- "Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: \"a-z\", \"A-Z\", \"0-9\" und \"_.@-\"",
+ "Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: „a-z“, „A-Z“, „0-9“ und „_.@-“",
"A valid username must be provided" : "Es muss ein gültiger Benutzername angegeben werden",
"A valid password must be provided" : "Es muss ein gültiges Passwort angegeben werden",
"The username is already being used" : "Dieser Benutzername existiert bereits",
- "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL, oder PostgreSQL) installiert.",
+ "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MySQL oder PostgreSQL) installiert.",
"Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Berechtigungen können normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Wurzelverzeichnis %s gegeben wird.",
- "Cannot write into \"config\" directory" : "Das Schreiben in das \"config\"-Verzeichnis nicht möglich",
- "Cannot write into \"apps\" directory" : "Das Schreiben in das \"apps\"-Verzeichnis nicht möglich",
+ "Cannot write into \"config\" directory" : "Das Schreiben in das „config“-Verzeichnis ist nicht möglich",
+ "Cannot write into \"apps\" directory" : "Das Schreiben in das „apps“-Verzeichnis ist nicht möglich",
"This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Anwendungsverzeichnis %s gegeben wird oder die Anwendungsauswahl in der Konfigurationsdatei deaktiviert wird.",
- "Cannot create \"data\" directory (%s)" : "Das Erstellen des \"data\"-Verzeichnisses nicht möglich (%s)",
+ "Cannot create \"data\" directory (%s)" : "Das Erstellen des „data“-Verzeichnisses ist nicht möglich (%s)",
"This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Dies kann normalerweise repariert werden, indem dem Webserver <a href=\"%s\" target=\"_blank\" Schreibzugriff auf das Wurzelverzeichnis gegeben wird</a>.",
"Setting locale to %s failed" : "Das Setzen der Umgebungslokale auf %s fehlgeschlagen",
"Please install one of these locales on your system and restart your webserver." : "Bitte installiere eine dieser Sprachen auf Deinem System und starte den Webserver neu.",
@@ -130,7 +130,7 @@
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Bitte ändere die Berechtigungen auf 0770 sodass das Verzeichnis nicht von anderen Nutzer angezeigt werden kann.",
"Data directory (%s) is readable by other users" : "Daten-Verzeichnis (%s) ist von anderen Nutzern lesbar",
"Data directory (%s) is invalid" : "Daten-Verzeichnis (%s) ist ungültig",
- "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stelle sicher, dass das Daten-Verzeichnis eine Datei namens \".ocdata\" im Wurzelverzeichnis enthält.",
+ "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stelle sicher, dass das Datenverzeichnis auf seiner ersten Ebene eine Datei namens „.ocdata“ enthält.",
"Could not obtain lock type %d on \"%s\"." : "Sperrtyp %d auf \"%s\" konnte nicht ermittelt werden."
},"pluralForm" :"nplurals=2; plural=(n != 1);"
} \ No newline at end of file
diff --git a/lib/l10n/de_DE.js b/lib/l10n/de_DE.js
index 02346b0e8d2..34b75e28884 100644
--- a/lib/l10n/de_DE.js
+++ b/lib/l10n/de_DE.js
@@ -54,7 +54,7 @@ OC.L10N.register(
"App can't be installed because it contains the <shipped>true</shipped> tag which is not allowed for non shipped apps" : "Die Applikation konnte nicht installiert werden, da diese das <shipped>true</shipped> Tag beinhaltet und dieses, bei nicht mitausgelieferten Applikationen, nicht erlaubt ist ist",
"App can't be installed because the version in info.xml/version is not the same as the version reported from the app store" : "Die Applikation konnte nicht installiert werden, da die Version in der info.xml nicht die gleiche Version wie im App-Store ist",
"Application is not enabled" : "Die Anwendung ist nicht aktiviert",
- "Authentication error" : "Authentifizierungs-Fehler",
+ "Authentication error" : "Authentifizierungsfehler",
"Token expired. Please reload page." : "Token abgelaufen. Bitte laden Sie die Seite neu.",
"Unknown user" : "Unbekannter Benutzer",
"%s enter the database username." : "%s geben Sie den Datenbank-Benutzernamen an.",
@@ -75,8 +75,8 @@ OC.L10N.register(
"PostgreSQL username and/or password not valid" : "PostgreSQL-Benutzername und/oder -Passwort ungültig",
"Set an admin username." : "Einen Administrator-Benutzernamen setzen.",
"Set an admin password." : "Setze Administrator Passwort",
- "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder beschreiben werden",
- "%s shared »%s« with you" : "%s hat »%s« mit Ihnen geteilt",
+ "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder es kann darin nicht geschrieben werden.",
+ "%s shared »%s« with you" : "%s hat „%s“ mit Ihnen geteilt",
"Sharing %s failed, because the backend does not allow shares from type %i" : "Freigabe von %s fehlgeschlagen, da das Backend die Freigabe vom Typ %i nicht erlaubt.",
"Sharing %s failed, because the file does not exist" : "Freigabe von %s fehlgeschlagen, da die Datei nicht existiert",
"You are not allowed to share %s" : "Die Freigabe von %s ist Ihnen nicht erlaubt",
@@ -102,17 +102,17 @@ OC.L10N.register(
"Sharing %s failed, because resharing is not allowed" : "Freigabe von %s fehlgeschlagen, da das nochmalige Freigeben einer Freigabe nicht erlaubt ist",
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Freigabe von %s fehlgeschlagen, da das Freigabe-Backend für %s nicht in dieser Quelle gefunden werden konnte",
"Sharing %s failed, because the file could not be found in the file cache" : "Freigabe von %s fehlgeschlagen, da die Datei im Datei-Cache nicht gefunden werden konnte",
- "Could not find category \"%s\"" : "Die Kategorie \"%s\" konnte nicht gefunden werden.",
+ "Could not find category \"%s\"" : "Die Kategorie „%s“ konnte nicht gefunden werden.",
"Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: »a-z«, »A-Z«, »0-9« und »_.@-«",
"A valid username must be provided" : "Es muss ein gültiger Benutzername angegeben werden",
"A valid password must be provided" : "Es muss ein gültiges Passwort angegeben werden",
"The username is already being used" : "Der Benutzername existiert bereits",
- "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL, oder PostgreSQL) installiert.",
+ "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL oder PostgreSQL) installiert.",
"Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Berechtigungen können normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Wurzelverzeichnis %s gegeben wird.",
"Cannot write into \"config\" directory" : "Das Schreiben in das »config«-Verzeichnis ist nicht möglich",
- "Cannot write into \"apps\" directory" : "Das Schreiben in das »apps«-Verzeichnis ist nicht möglich",
+ "Cannot write into \"apps\" directory" : "Das Schreiben in das „apps“-Verzeichnis ist nicht möglich",
"This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Anwendungsverzeichnis %s gegeben wird oder die Anwendungsauswahl in der Konfigurationsdatei deaktiviert wird.",
- "Cannot create \"data\" directory (%s)" : "Das Erstellen des »data«-Verzeichnisses ist nicht möglich (%s)",
+ "Cannot create \"data\" directory (%s)" : "Das Erstellen des „data“-Verzeichnisses ist nicht möglich (%s)",
"This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Dies kann normalerweise repariert werden, indem dem Webserver <a href=\"%s\" target=\"_blank\" Schreibzugriff auf das Wurzelverzeichnis gegeben wird</a>.",
"Setting locale to %s failed" : "Das Setzen der Umgebungslokale auf %s fehlgeschlagen",
"Please install one of these locales on your system and restart your webserver." : "Bitte installieren Sie eine dieser Sprachen auf Ihrem System und starten Sie den Webserver neu.",
@@ -132,7 +132,7 @@ OC.L10N.register(
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Bitte ändern Sie die Berechtigungen auf 0770, so dass das Verzeichnis nicht von anderen Benutzern angezeigt werden kann.",
"Data directory (%s) is readable by other users" : "Daten-Verzeichnis (%s) ist von anderen Benutzern lesbar",
"Data directory (%s) is invalid" : "Daten-Verzeichnis (%s) ist ungültig",
- "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stellen Sie sicher, dass das Daten-Verzeichnis eine Datei namens \".ocdata\" im Wurzelverzeichnis enthält.",
+ "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stellen Sie sicher, dass das Datenverzeichnis auf seiner ersten Ebene eine Datei namens „.ocdata“ enthält.",
"Could not obtain lock type %d on \"%s\"." : "Sperrtyp %d auf »%s« konnte nicht ermittelt werden."
},
"nplurals=2; plural=(n != 1);");
diff --git a/lib/l10n/de_DE.json b/lib/l10n/de_DE.json
index 20ff8b059ee..a64b625fa8e 100644
--- a/lib/l10n/de_DE.json
+++ b/lib/l10n/de_DE.json
@@ -52,7 +52,7 @@
"App can't be installed because it contains the <shipped>true</shipped> tag which is not allowed for non shipped apps" : "Die Applikation konnte nicht installiert werden, da diese das <shipped>true</shipped> Tag beinhaltet und dieses, bei nicht mitausgelieferten Applikationen, nicht erlaubt ist ist",
"App can't be installed because the version in info.xml/version is not the same as the version reported from the app store" : "Die Applikation konnte nicht installiert werden, da die Version in der info.xml nicht die gleiche Version wie im App-Store ist",
"Application is not enabled" : "Die Anwendung ist nicht aktiviert",
- "Authentication error" : "Authentifizierungs-Fehler",
+ "Authentication error" : "Authentifizierungsfehler",
"Token expired. Please reload page." : "Token abgelaufen. Bitte laden Sie die Seite neu.",
"Unknown user" : "Unbekannter Benutzer",
"%s enter the database username." : "%s geben Sie den Datenbank-Benutzernamen an.",
@@ -73,8 +73,8 @@
"PostgreSQL username and/or password not valid" : "PostgreSQL-Benutzername und/oder -Passwort ungültig",
"Set an admin username." : "Einen Administrator-Benutzernamen setzen.",
"Set an admin password." : "Setze Administrator Passwort",
- "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder beschreiben werden",
- "%s shared »%s« with you" : "%s hat »%s« mit Ihnen geteilt",
+ "Can't create or write into the data directory %s" : "Das Datenverzeichnis %s kann nicht erstellt oder es kann darin nicht geschrieben werden.",
+ "%s shared »%s« with you" : "%s hat „%s“ mit Ihnen geteilt",
"Sharing %s failed, because the backend does not allow shares from type %i" : "Freigabe von %s fehlgeschlagen, da das Backend die Freigabe vom Typ %i nicht erlaubt.",
"Sharing %s failed, because the file does not exist" : "Freigabe von %s fehlgeschlagen, da die Datei nicht existiert",
"You are not allowed to share %s" : "Die Freigabe von %s ist Ihnen nicht erlaubt",
@@ -100,17 +100,17 @@
"Sharing %s failed, because resharing is not allowed" : "Freigabe von %s fehlgeschlagen, da das nochmalige Freigeben einer Freigabe nicht erlaubt ist",
"Sharing %s failed, because the sharing backend for %s could not find its source" : "Freigabe von %s fehlgeschlagen, da das Freigabe-Backend für %s nicht in dieser Quelle gefunden werden konnte",
"Sharing %s failed, because the file could not be found in the file cache" : "Freigabe von %s fehlgeschlagen, da die Datei im Datei-Cache nicht gefunden werden konnte",
- "Could not find category \"%s\"" : "Die Kategorie \"%s\" konnte nicht gefunden werden.",
+ "Could not find category \"%s\"" : "Die Kategorie „%s“ konnte nicht gefunden werden.",
"Only the following characters are allowed in a username: \"a-z\", \"A-Z\", \"0-9\", and \"_.@-\"" : "Folgende Zeichen sind im Benutzernamen erlaubt: »a-z«, »A-Z«, »0-9« und »_.@-«",
"A valid username must be provided" : "Es muss ein gültiger Benutzername angegeben werden",
"A valid password must be provided" : "Es muss ein gültiges Passwort angegeben werden",
"The username is already being used" : "Der Benutzername existiert bereits",
- "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL, oder PostgreSQL) installiert.",
+ "No database drivers (sqlite, mysql, or postgresql) installed." : "Keine Datenbanktreiber (SQLite, MYSQL oder PostgreSQL) installiert.",
"Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Berechtigungen können normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Wurzelverzeichnis %s gegeben wird.",
"Cannot write into \"config\" directory" : "Das Schreiben in das »config«-Verzeichnis ist nicht möglich",
- "Cannot write into \"apps\" directory" : "Das Schreiben in das »apps«-Verzeichnis ist nicht möglich",
+ "Cannot write into \"apps\" directory" : "Das Schreiben in das „apps“-Verzeichnis ist nicht möglich",
"This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Dies kann normalerweise repariert werden, indem dem Webserver %s Schreibzugriff auf das Anwendungsverzeichnis %s gegeben wird oder die Anwendungsauswahl in der Konfigurationsdatei deaktiviert wird.",
- "Cannot create \"data\" directory (%s)" : "Das Erstellen des »data«-Verzeichnisses ist nicht möglich (%s)",
+ "Cannot create \"data\" directory (%s)" : "Das Erstellen des „data“-Verzeichnisses ist nicht möglich (%s)",
"This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Dies kann normalerweise repariert werden, indem dem Webserver <a href=\"%s\" target=\"_blank\" Schreibzugriff auf das Wurzelverzeichnis gegeben wird</a>.",
"Setting locale to %s failed" : "Das Setzen der Umgebungslokale auf %s fehlgeschlagen",
"Please install one of these locales on your system and restart your webserver." : "Bitte installieren Sie eine dieser Sprachen auf Ihrem System und starten Sie den Webserver neu.",
@@ -130,7 +130,7 @@
"Please change the permissions to 0770 so that the directory cannot be listed by other users." : "Bitte ändern Sie die Berechtigungen auf 0770, so dass das Verzeichnis nicht von anderen Benutzern angezeigt werden kann.",
"Data directory (%s) is readable by other users" : "Daten-Verzeichnis (%s) ist von anderen Benutzern lesbar",
"Data directory (%s) is invalid" : "Daten-Verzeichnis (%s) ist ungültig",
- "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stellen Sie sicher, dass das Daten-Verzeichnis eine Datei namens \".ocdata\" im Wurzelverzeichnis enthält.",
+ "Please check that the data directory contains a file \".ocdata\" in its root." : "Bitte stellen Sie sicher, dass das Datenverzeichnis auf seiner ersten Ebene eine Datei namens „.ocdata“ enthält.",
"Could not obtain lock type %d on \"%s\"." : "Sperrtyp %d auf »%s« konnte nicht ermittelt werden."
},"pluralForm" :"nplurals=2; plural=(n != 1);"
} \ No newline at end of file
diff --git a/lib/l10n/ja.js b/lib/l10n/ja.js
index bf0e4f4b4cc..8d5d005ce79 100644
--- a/lib/l10n/ja.js
+++ b/lib/l10n/ja.js
@@ -22,7 +22,7 @@ OC.L10N.register(
"Settings" : "設定",
"Users" : "ユーザー",
"Admin" : "管理",
- "Recommended" : "推奨",
+ "Recommended" : "おすすめ",
"App \\\"%s\\\" can't be installed because it is not compatible with this version of ownCloud." : "アプリ \\\"%s\\\" をインストールできません。現在のownCloudのバージョンと互換性がありません。",
"App \\\"%s\\\" cannot be installed because the following dependencies are not fulfilled: %s" : "次の依存関係は無いため\\\"%s\\\"のアプリをインストールできません:%s",
"No app name specified" : "アプリ名が未指定",
diff --git a/lib/l10n/ja.json b/lib/l10n/ja.json
index 6e3749cd3b7..5b6e8f4f212 100644
--- a/lib/l10n/ja.json
+++ b/lib/l10n/ja.json
@@ -20,7 +20,7 @@
"Settings" : "設定",
"Users" : "ユーザー",
"Admin" : "管理",
- "Recommended" : "推奨",
+ "Recommended" : "おすすめ",
"App \\\"%s\\\" can't be installed because it is not compatible with this version of ownCloud." : "アプリ \\\"%s\\\" をインストールできません。現在のownCloudのバージョンと互換性がありません。",
"App \\\"%s\\\" cannot be installed because the following dependencies are not fulfilled: %s" : "次の依存関係は無いため\\\"%s\\\"のアプリをインストールできません:%s",
"No app name specified" : "アプリ名が未指定",
diff --git a/lib/l10n/uk.js b/lib/l10n/uk.js
index b2cd33fed40..ee35acd8dab 100644
--- a/lib/l10n/uk.js
+++ b/lib/l10n/uk.js
@@ -7,6 +7,7 @@ OC.L10N.register(
"This can usually be fixed by %sgiving the webserver write access to the config directory%s." : "Зазвичай це можна виправити, %sнадавши веб-серверу права на запис в теці конфігурації%s.",
"Sample configuration detected" : "Виявлено приклад конфігурації",
"It has been detected that the sample configuration has been copied. This can break your installation and is unsupported. Please read the documentation before performing changes on config.php" : "Була виявлена конфігурація з прикладу. Це може нашкодити вашій системі та не підтримується. Будь ласка, зверніться до документації перед внесенням змін в файл config.php",
+ "PHP %s or higher is required." : "Необхідно PHP %s або вище",
"Help" : "Допомога",
"Personal" : "Особисте",
"Settings" : "Налаштування",
diff --git a/lib/l10n/uk.json b/lib/l10n/uk.json
index 1a9c42d7d4e..2969c10ea97 100644
--- a/lib/l10n/uk.json
+++ b/lib/l10n/uk.json
@@ -5,6 +5,7 @@
"This can usually be fixed by %sgiving the webserver write access to the config directory%s." : "Зазвичай це можна виправити, %sнадавши веб-серверу права на запис в теці конфігурації%s.",
"Sample configuration detected" : "Виявлено приклад конфігурації",
"It has been detected that the sample configuration has been copied. This can break your installation and is unsupported. Please read the documentation before performing changes on config.php" : "Була виявлена конфігурація з прикладу. Це може нашкодити вашій системі та не підтримується. Будь ласка, зверніться до документації перед внесенням змін в файл config.php",
+ "PHP %s or higher is required." : "Необхідно PHP %s або вище",
"Help" : "Допомога",
"Personal" : "Особисте",
"Settings" : "Налаштування",
diff --git a/lib/private/app.php b/lib/private/app.php
index 60b644e58e2..a92ddd40e6f 100644
--- a/lib/private/app.php
+++ b/lib/private/app.php
@@ -34,6 +34,7 @@ use OC\App\Platform;
* upgrading and removing apps.
*/
class OC_App {
+ static private $appVersion = [];
static private $settingsForms = array();
static private $adminForms = array();
static private $personalForms = array();
@@ -492,7 +493,7 @@ class OC_App {
/**
* Get the path where to install apps
*
- * @return string
+ * @return string|false
*/
public static function getInstallPath() {
if (OC_Config::getValue('appstoreenabled', true) == false) {
@@ -603,8 +604,11 @@ class OC_App {
* @return string
*/
public static function getAppVersion($appId) {
- $file = self::getAppPath($appId);
- return ($file !== false) ? self::getAppVersionByPath($file) : '0';
+ if (!isset(self::$appVersion[$appId])) {
+ $file = self::getAppPath($appId);
+ self::$appVersion[$appId] = ($file !== false) ? self::getAppVersionByPath($file) : '0';
+ }
+ return self::$appVersion[$appId];
}
/**
@@ -898,7 +902,7 @@ class OC_App {
/**
* get a list of all apps on apps.owncloud.com
- * @return array, multi-dimensional array of apps.
+ * @return array|false multi-dimensional array of apps.
* Keys: id, name, type, typename, personid, license, detailpage, preview, changed, description
*/
public static function getAppstoreApps($filter = 'approved', $category = null) {
@@ -1158,6 +1162,7 @@ class OC_App {
if (file_exists(self::getAppPath($appId) . '/appinfo/database.xml')) {
OC_DB::updateDbFromStructure(self::getAppPath($appId) . '/appinfo/database.xml');
}
+ unset(self::$appVersion[$appId]);
if (!self::isEnabled($appId)) {
return false;
}
@@ -1188,7 +1193,7 @@ class OC_App {
/**
* @param string $appId
- * @return \OC\Files\View
+ * @return \OC\Files\View|false
*/
public static function getStorage($appId) {
if (OC_App::isEnabled($appId)) { //sanity check
diff --git a/lib/private/appconfig.php b/lib/private/appconfig.php
index 1874d9f2b19..cd27f91bf01 100644
--- a/lib/private/appconfig.php
+++ b/lib/private/appconfig.php
@@ -245,7 +245,7 @@ class AppConfig implements \OCP\IAppConfig {
*
* @param string|false $app
* @param string|false $key
- * @return array
+ * @return array|false
*/
public function getValues($app, $key) {
if (($app !== false) == ($key !== false)) {
diff --git a/lib/private/appframework/core/api.php b/lib/private/appframework/core/api.php
index 2f01015bb15..ab66c54c921 100644
--- a/lib/private/appframework/core/api.php
+++ b/lib/private/appframework/core/api.php
@@ -136,7 +136,7 @@ class API implements IApi{
* @param string $slotName name of slot, in another word, this is the
* name of the method that will be called when registered
* signal is emitted.
- * @return bool, always true
+ * @return bool always true
*/
public function connectHook($signalClass, $signalName, $slotClass, $slotName) {
return \OCP\Util::connectHook($signalClass, $signalName, $slotClass, $slotName);
@@ -148,7 +148,7 @@ class API implements IApi{
* @param string $signalClass class name of emitter
* @param string $signalName name of signal
* @param array $params default: array() array with additional data
- * @return bool, true if slots exists or false if not
+ * @return bool true if slots exists or false if not
*/
public function emitHook($signalClass, $signalName, $params = array()) {
return \OCP\Util::emitHook($signalClass, $signalName, $params);
diff --git a/lib/private/appframework/http/request.php b/lib/private/appframework/http/request.php
index 6012033fe52..4902671d4b8 100644
--- a/lib/private/appframework/http/request.php
+++ b/lib/private/appframework/http/request.php
@@ -25,6 +25,7 @@
namespace OC\AppFramework\Http;
use OCP\IRequest;
+use OCP\Security\ISecureRandom;
/**
* Class for accessing variables in the request.
@@ -48,24 +49,32 @@ class Request implements \ArrayAccess, \Countable, IRequest {
'method',
'requesttoken',
);
+ /** @var ISecureRandom */
+ protected $secureRandom;
+ /** @var string */
+ protected $requestId = '';
/**
* @param array $vars An associative array with the following optional values:
- * @param array 'urlParams' the parameters which were matched from the URL
- * @param array 'get' the $_GET array
- * @param array|string 'post' the $_POST array or JSON string
- * @param array 'files' the $_FILES array
- * @param array 'server' the $_SERVER array
- * @param array 'env' the $_ENV array
- * @param array 'cookies' the $_COOKIE array
- * @param string 'method' the request method (GET, POST etc)
- * @param string|false 'requesttoken' the requesttoken or false when not available
+ * - array 'urlParams' the parameters which were matched from the URL
+ * - array 'get' the $_GET array
+ * - array|string 'post' the $_POST array or JSON string
+ * - array 'files' the $_FILES array
+ * - array 'server' the $_SERVER array
+ * - array 'env' the $_ENV array
+ * - array 'cookies' the $_COOKIE array
+ * - string 'method' the request method (GET, POST etc)
+ * - string|false 'requesttoken' the requesttoken or false when not available
+ * @param ISecureRandom $secureRandom
+ * @param string $stream
* @see http://www.php.net/manual/en/reserved.variables.php
*/
- public function __construct(array $vars=array(), $stream='php://input') {
-
+ public function __construct(array $vars=array(),
+ ISecureRandom $secureRandom,
+ $stream='php://input') {
$this->inputStream = $stream;
$this->items['params'] = array();
+ $this->secureRandom = $secureRandom;
if(!array_key_exists('method', $vars)) {
$vars['method'] = 'GET';
@@ -384,4 +393,23 @@ class Request implements \ArrayAccess, \Countable, IRequest {
// Valid token
return true;
}
- }}
+ }
+
+ /**
+ * Returns an ID for the request, value is not guaranteed to be unique and is mostly meant for logging
+ * If `mod_unique_id` is installed this value will be taken.
+ * @return string
+ */
+ public function getId() {
+ if(isset($this->server['UNIQUE_ID'])) {
+ return $this->server['UNIQUE_ID'];
+ }
+
+ if(empty($this->requestId)) {
+ $this->requestId = $this->secureRandom->getLowStrengthGenerator()->generate(20);
+ }
+
+ return $this->requestId;
+ }
+
+}
diff --git a/lib/private/avatar.php b/lib/private/avatar.php
index a9d9346d50a..5e234d77bb2 100644
--- a/lib/private/avatar.php
+++ b/lib/private/avatar.php
@@ -43,6 +43,15 @@ class OC_Avatar implements \OCP\IAvatar {
}
/**
+ * Check if an avatar exists for the user
+ *
+ * @return bool
+ */
+ public function exists() {
+ return $this->view->file_exists('avatar.jpg') || $this->view->file_exists('avatar.png');
+ }
+
+ /**
* sets the users avatar
* @param \OC_Image|resource|string $data OC_Image, imagedata or path to set a new avatar
* @throws Exception if the provided file is not a jpg or png image
diff --git a/lib/private/cache/file.php b/lib/private/cache/file.php
index 4e7c065678e..3b500c4e45b 100644
--- a/lib/private/cache/file.php
+++ b/lib/private/cache/file.php
@@ -83,7 +83,7 @@ class File {
public function hasKey($key) {
$storage = $this->getStorage();
- if ($storage && $storage->is_file($key)) {
+ if ($storage && $storage->is_file($key) && $storage->isReadable($key)) {
return true;
}
return false;
diff --git a/lib/private/cache/fileglobal.php b/lib/private/cache/fileglobal.php
index d9e0fd46d37..8406adabd75 100644
--- a/lib/private/cache/fileglobal.php
+++ b/lib/private/cache/fileglobal.php
@@ -52,7 +52,7 @@ class FileGlobal {
public function hasKey($key) {
$key = $this->fixKey($key);
$cache_dir = self::getCacheDir();
- if ($cache_dir && is_file($cache_dir.$key)) {
+ if ($cache_dir && is_file($cache_dir.$key) && is_readable($cache_dir.$key)) {
$mtime = filemtime($cache_dir.$key);
if ($mtime < time()) {
unlink($cache_dir.$key);
diff --git a/lib/private/config.php b/lib/private/config.php
index 31e536221dd..5c8cc89f0f0 100644
--- a/lib/private/config.php
+++ b/lib/private/config.php
@@ -236,8 +236,11 @@ class Config {
flock($filePointer, LOCK_UN);
fclose($filePointer);
- // Clear the opcode cache
- \OC_Util::clearOpcodeCache();
+ // Try invalidating the opcache just for the file we wrote...
+ if (!\OC_Util::deleteFromOpcodeCache($this->configFilePath)) {
+ // But if that doesn't work, clear the whole cache.
+ \OC_Util::clearOpcodeCache();
+ }
}
}
diff --git a/lib/private/files/cache/cache.php b/lib/private/files/cache/cache.php
index cad4c8a40b9..06a884072e0 100644
--- a/lib/private/files/cache/cache.php
+++ b/lib/private/files/cache/cache.php
@@ -436,7 +436,7 @@ class Cache {
/**
* @param string $file
*
- * @return int, Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
+ * @return int Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
*/
public function getStatus($file) {
// normalize file
@@ -689,7 +689,7 @@ class Cache {
* instead does a global search in the cache table
*
* @param int $id
- * @return array, first element holding the storage id, second the path
+ * @return array first element holding the storage id, second the path
*/
static public function getById($id) {
$sql = 'SELECT `storage`, `path` FROM `*PREFIX*filecache` WHERE `fileid` = ?';
diff --git a/lib/private/files/cache/wrapper/cachejail.php b/lib/private/files/cache/wrapper/cachejail.php
index 3f7ea66ea1b..bb065643cf7 100644
--- a/lib/private/files/cache/wrapper/cachejail.php
+++ b/lib/private/files/cache/wrapper/cachejail.php
@@ -163,7 +163,7 @@ class CacheJail extends CacheWrapper {
/**
* @param string $file
*
- * @return int, Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
+ * @return int Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
*/
public function getStatus($file) {
return $this->cache->getStatus($this->getSourcePath($file));
diff --git a/lib/private/files/cache/wrapper/cachewrapper.php b/lib/private/files/cache/wrapper/cachewrapper.php
index 83811520e4b..a5997edb307 100644
--- a/lib/private/files/cache/wrapper/cachewrapper.php
+++ b/lib/private/files/cache/wrapper/cachewrapper.php
@@ -152,7 +152,7 @@ class CacheWrapper extends Cache {
/**
* @param string $file
*
- * @return int, Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
+ * @return int Cache::NOT_FOUND, Cache::PARTIAL, Cache::SHALLOW or Cache::COMPLETE
*/
public function getStatus($file) {
return $this->cache->getStatus($file);
@@ -260,7 +260,7 @@ class CacheWrapper extends Cache {
* instead does a global search in the cache table
*
* @param int $id
- * @return array, first element holding the storage id, second the path
+ * @return array first element holding the storage id, second the path
*/
static public function getById($id) {
return parent::getById($id);
diff --git a/lib/private/files/fileinfo.php b/lib/private/files/fileinfo.php
index e4a397dcca2..1acb62033dd 100644
--- a/lib/private/files/fileinfo.php
+++ b/lib/private/files/fileinfo.php
@@ -159,11 +159,10 @@ class FileInfo implements \OCP\Files\FileInfo, \ArrayAccess {
* @return \OCP\Files\FileInfo::TYPE_FILE|\OCP\Files\FileInfo::TYPE_FOLDER
*/
public function getType() {
- if (isset($this->data['type'])) {
- return $this->data['type'];
- } else {
- return $this->getMimetype() === 'httpd/unix-directory' ? self::TYPE_FOLDER : self::TYPE_FILE;
+ if (!isset($this->data['type'])) {
+ $this->data['type'] = ($this->getMimetype() === 'httpd/unix-directory') ? self::TYPE_FOLDER : self::TYPE_FILE;
}
+ return $this->data['type'];
}
public function getData() {
diff --git a/lib/private/files/storage/common.php b/lib/private/files/storage/common.php
index b2bf41f751c..9c233e447a6 100644
--- a/lib/private/files/storage/common.php
+++ b/lib/private/files/storage/common.php
@@ -343,7 +343,7 @@ abstract class Common implements \OC\Files\Storage\Storage {
* get the owner of a path
*
* @param string $path The path to get the owner
- * @return string uid or false
+ * @return string|false uid or false
*/
public function getOwner($path) {
return \OC_User::getUser();
@@ -353,7 +353,7 @@ abstract class Common implements \OC\Files\Storage\Storage {
* get the ETag for a file or folder
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function getETag($path) {
$ETagFunction = \OC_Connector_Sabre_Node::$ETagFunction;
@@ -400,7 +400,7 @@ abstract class Common implements \OC\Files\Storage\Storage {
* get the free space in the storage
*
* @param string $path
- * @return int
+ * @return int|false
*/
public function free_space($path) {
return \OCP\Files\FileInfo::SPACE_UNKNOWN;
@@ -445,7 +445,7 @@ abstract class Common implements \OC\Files\Storage\Storage {
* For now the returned array can hold the parameter url - in future more attributes might follow.
*
* @param string $path
- * @return array
+ * @return array|false
*/
public function getDirectDownload($path) {
return [];
diff --git a/lib/private/helper.php b/lib/private/helper.php
index c87eb63b662..887c3f33402 100644
--- a/lib/private/helper.php
+++ b/lib/private/helper.php
@@ -289,12 +289,7 @@ class OC_Helper {
**/
public static function userAvatarSet($user) {
$avatar = new \OC_Avatar($user);
- $image = $avatar->get(1);
- if ($image instanceof \OC_Image) {
- return true;
- } else {
- return false;
- }
+ return $avatar->exists();
}
/**
diff --git a/lib/private/hook.php b/lib/private/hook.php
index c9ca58f779e..00fb4cb0ff5 100644
--- a/lib/private/hook.php
+++ b/lib/private/hook.php
@@ -52,7 +52,7 @@ class OC_Hook{
* @param string $signalclass class name of emitter
* @param string $signalname name of signal
* @param mixed $params default: array() array with additional data
- * @return bool, true if slots exists or false if not
+ * @return bool true if slots exists or false if not
*
* Emits a signal. To get data from the slot use references!
*
diff --git a/lib/private/installer.php b/lib/private/installer.php
index 4f4a498b739..b4fbe527b4f 100644
--- a/lib/private/installer.php
+++ b/lib/private/installer.php
@@ -547,7 +547,6 @@ class OC_Installer{
'OC_L10N::',
'OC_Log::',
'OC_Mail::',
- 'OC_Preferences::',
'OC_Request::',
'OC_Response::',
'OC_Template::',
diff --git a/lib/private/legacy/preferences.php b/lib/private/legacy/preferences.php
deleted file mode 100644
index 907aafbc915..00000000000
--- a/lib/private/legacy/preferences.php
+++ /dev/null
@@ -1,121 +0,0 @@
-<?php
-/**
- * ownCloud
- *
- * @author Frank Karlitschek
- * @author Jakob Sack
- * @copyright 2012 Frank Karlitschek frank@owncloud.org
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
- * License as published by the Free Software Foundation; either
- * version 3 of the License, or any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
- *
- * You should have received a copy of the GNU Affero General Public
- * License along with this library. If not, see <http://www.gnu.org/licenses/>.
- *
- */
-
-/**
- * This class provides an easy way for storing user preferences.
- * @deprecated use \OCP\IConfig methods instead
- */
-class OC_Preferences{
- /**
- * Get the available keys for an app
- * @param string $user user
- * @param string $app the app we are looking for
- * @return array an array of key names
- * @deprecated use getUserKeys of \OCP\IConfig instead
- *
- * This function gets all keys of an app of an user. Please note that the
- * values are not returned.
- */
- public static function getKeys( $user, $app ) {
- return \OC::$server->getConfig()->getUserKeys($user, $app);
- }
-
- /**
- * Gets the preference
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @param string $default = null, default value if the key does not exist
- * @return string the value or $default
- * @deprecated use getUserValue of \OCP\IConfig instead
- *
- * This function gets a value from the preferences table. If the key does
- * not exist the default value will be returned
- */
- public static function getValue( $user, $app, $key, $default = null ) {
- return \OC::$server->getConfig()->getUserValue($user, $app, $key, $default);
- }
-
- /**
- * sets a value in the preferences
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @param string $value value
- * @param string $preCondition only set value if the key had a specific value before
- * @return bool true if value was set, otherwise false
- * @deprecated use setUserValue of \OCP\IConfig instead
- *
- * Adds a value to the preferences. If the key did not exist before, it
- * will be added automagically.
- */
- public static function setValue( $user, $app, $key, $value, $preCondition = null ) {
- try {
- \OC::$server->getConfig()->setUserValue($user, $app, $key, $value, $preCondition);
- return true;
- } catch(\OCP\PreConditionNotMetException $e) {
- return false;
- }
- }
-
- /**
- * Deletes a key
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @return bool true
- * @deprecated use deleteUserValue of \OCP\IConfig instead
- *
- * Deletes a key.
- */
- public static function deleteKey( $user, $app, $key ) {
- \OC::$server->getConfig()->deleteUserValue($user, $app, $key);
- return true;
- }
-
- /**
- * Remove user from preferences
- * @param string $user user
- * @return bool
- * @deprecated use deleteUser of \OCP\IConfig instead
- *
- * Removes all keys in preferences belonging to the user.
- */
- public static function deleteUser( $user ) {
- \OC::$server->getConfig()->deleteAllUserValues($user);
- return true;
- }
-
- /**
- * Remove app from all users
- * @param string $app app
- * @return bool
- * @deprecated use deleteAppFromAllUsers of \OCP\IConfig instead
- *
- * Removes all keys in preferences belonging to the app.
- */
- public static function deleteAppFromAllUsers( $app ) {
- \OC::$server->getConfig()->deleteAppFromAllUsers($app);
- return true;
- }
-}
diff --git a/lib/private/log/owncloud.php b/lib/private/log/owncloud.php
index c8ae61032aa..8e55bf1c695 100644
--- a/lib/private/log/owncloud.php
+++ b/lib/private/log/owncloud.php
@@ -68,7 +68,7 @@ class OC_Log_Owncloud {
$timezone = new DateTimeZone('UTC');
}
$time = new DateTime(null, $timezone);
- $reqId = \OC_Request::getRequestID();
+ $reqId = \OC::$server->getRequest()->getId();
$remoteAddr = \OC_Request::getRemoteAddress();
// remove username/passwords from URLs before writing the to the log file
$time = $time->format($format);
diff --git a/lib/private/naturalsort.php b/lib/private/naturalsort.php
index 6e259630f79..d511bfa3f66 100644
--- a/lib/private/naturalsort.php
+++ b/lib/private/naturalsort.php
@@ -12,6 +12,7 @@ namespace OC;
class NaturalSort {
private static $instance;
private $collator;
+ private $cache = array();
/**
* Split the given string in chunks of numbers and strings
@@ -21,13 +22,15 @@ class NaturalSort {
private function naturalSortChunkify($t) {
// Adapted and ported to PHP from
// http://my.opera.com/GreyWyvern/blog/show.dml/1671288
+ if (isset($this->cache[$t])) {
+ return $this->cache[$t];
+ }
$tz = array();
$x = 0;
$y = -1;
$n = null;
- $length = strlen($t);
- while ($x < $length) {
+ while (isset($t[$x])) {
$c = $t[$x];
// only include the dot in strings
$m = ((!$n && $c === '.') || ($c >= '0' && $c <= '9'));
@@ -40,6 +43,7 @@ class NaturalSort {
$tz[$y] .= $c;
$x++;
}
+ $this->cache[$t] = $tz;
return $tz;
}
@@ -75,14 +79,13 @@ class NaturalSort {
// instead of ["test.txt", "test (2).txt"]
$aa = self::naturalSortChunkify($a);
$bb = self::naturalSortChunkify($b);
- $alen = count($aa);
- $blen = count($bb);
- for ($x = 0; $x < $alen && $x < $blen; $x++) {
+ for ($x = 0; isset($aa[$x]) && isset($bb[$x]); $x++) {
$aChunk = $aa[$x];
$bChunk = $bb[$x];
if ($aChunk !== $bChunk) {
- if (is_numeric($aChunk) && is_numeric($bChunk)) {
+ // test first character (character comparison, not number comparison)
+ if ($aChunk[0] >= '0' && $aChunk[0] <= '9' && $bChunk[0] >= '0' && $bChunk[0] <= '9') {
$aNum = (int)$aChunk;
$bNum = (int)$bChunk;
return $aNum - $bNum;
@@ -90,7 +93,7 @@ class NaturalSort {
return self::getCollator()->compare($aChunk, $bChunk);
}
}
- return $alen - $blen;
+ return count($aa) - count($bb);
}
/**
diff --git a/lib/private/ocs.php b/lib/private/ocs.php
index 214b28fa22c..bbe642a247d 100644
--- a/lib/private/ocs.php
+++ b/lib/private/ocs.php
@@ -121,7 +121,7 @@ class OC_OCS {
* @param int|string $itemsperpage
* @return string xml/json
*/
- private static function generateXml($format, $status, $statuscode,
+ public static function generateXml($format, $status, $statuscode,
$message, $data=array(), $tag='', $tagattribute='', $dimension=-1, $itemscount='', $itemsperpage='') {
if($format=='json') {
$json=array();
diff --git a/lib/private/preferences.php b/lib/private/preferences.php
deleted file mode 100644
index cd4a9fd1c19..00000000000
--- a/lib/private/preferences.php
+++ /dev/null
@@ -1,181 +0,0 @@
-<?php
-/**
- * ownCloud
- *
- * @author Frank Karlitschek
- * @author Jakob Sack
- * @copyright 2012 Frank Karlitschek frank@owncloud.org
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
- * License as published by the Free Software Foundation; either
- * version 3 of the License, or any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
- *
- * You should have received a copy of the GNU Affero General Public
- * License along with this library. If not, see <http://www.gnu.org/licenses/>.
- *
- */
-/*
- *
- * The following SQL statement is just a help for developers and will not be
- * executed!
- *
- * CREATE TABLE `preferences` (
- * `userid` VARCHAR( 255 ) NOT NULL ,
- * `appid` VARCHAR( 255 ) NOT NULL ,
- * `configkey` VARCHAR( 255 ) NOT NULL ,
- * `configvalue` VARCHAR( 255 ) NOT NULL
- * )
- *
- */
-
-namespace OC;
-
-use OCP\IDBConnection;
-use OCP\PreConditionNotMetException;
-
-
-/**
- * This class provides an easy way for storing user preferences.
- * @deprecated use \OCP\IConfig methods instead
- */
-class Preferences {
-
- /**
- * 3 dimensional array with the following structure:
- * [ $userId =>
- * [ $appId =>
- * [ $key => $value ]
- * ]
- * ]
- *
- * @var array $cache
- */
- protected $cache = array();
-
- /** @var \OCP\IConfig */
- protected $config;
-
- /**
- * @param \OCP\IDBConnection $conn
- */
- public function __construct(IDBConnection $conn) {
- $this->config = \OC::$server->getConfig();
- }
-
- /**
- * Get the available keys for an app
- * @param string $user user
- * @param string $app the app we are looking for
- * @return array an array of key names
- * @deprecated use getUserKeys of \OCP\IConfig instead
- *
- * This function gets all keys of an app of an user. Please note that the
- * values are not returned.
- */
- public function getKeys($user, $app) {
- return $this->config->getUserKeys($user, $app);
- }
-
- /**
- * Gets the preference
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @param string $default = null, default value if the key does not exist
- * @return string the value or $default
- * @deprecated use getUserValue of \OCP\IConfig instead
- *
- * This function gets a value from the preferences table. If the key does
- * not exist the default value will be returned
- */
- public function getValue($user, $app, $key, $default = null) {
- return $this->config->getUserValue($user, $app, $key, $default);
- }
-
- /**
- * sets a value in the preferences
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @param string $value value
- * @param string $preCondition only set value if the key had a specific value before
- * @return bool true if value was set, otherwise false
- * @deprecated use setUserValue of \OCP\IConfig instead
- *
- * Adds a value to the preferences. If the key did not exist before, it
- * will be added automagically.
- */
- public function setValue($user, $app, $key, $value, $preCondition = null) {
- try {
- $this->config->setUserValue($user, $app, $key, $value, $preCondition);
- return true;
- } catch(PreConditionNotMetException $e) {
- return false;
- }
- }
-
- /**
- * Gets the preference for an array of users
- * @param string $app
- * @param string $key
- * @param array $users
- * @return array Mapped values: userid => value
- * @deprecated use getUserValueForUsers of \OCP\IConfig instead
- */
- public function getValueForUsers($app, $key, $users) {
- return $this->config->getUserValueForUsers($app, $key, $users);
- }
-
- /**
- * Gets the users for a preference
- * @param string $app
- * @param string $key
- * @param string $value
- * @return array
- * @deprecated use getUsersForUserValue of \OCP\IConfig instead
- */
- public function getUsersForValue($app, $key, $value) {
- return $this->config->getUsersForUserValue($app, $key, $value);
- }
-
- /**
- * Deletes a key
- * @param string $user user
- * @param string $app app
- * @param string $key key
- * @deprecated use deleteUserValue of \OCP\IConfig instead
- *
- * Deletes a key.
- */
- public function deleteKey($user, $app, $key) {
- $this->config->deleteUserValue($user, $app, $key);
- }
-
- /**
- * Remove user from preferences
- * @param string $user user
- * @deprecated use deleteAllUserValues of \OCP\IConfig instead
- *
- * Removes all keys in preferences belonging to the user.
- */
- public function deleteUser($user) {
- $this->config->deleteAllUserValues($user);
- }
-
- /**
- * Remove app from all users
- * @param string $app app
- * @deprecated use deleteAppFromAllUsers of \OCP\IConfig instead
- *
- * Removes all keys in preferences belonging to the app.
- */
- public function deleteAppFromAllUsers($app) {
- $this->config->deleteAppFromAllUsers($app);
- }
-}
diff --git a/lib/private/repair.php b/lib/private/repair.php
index c74283896fd..d9fd99707e8 100644
--- a/lib/private/repair.php
+++ b/lib/private/repair.php
@@ -13,7 +13,6 @@ use OC\Hooks\Emitter;
use OC\Repair\AssetCache;
use OC\Repair\CleanTags;
use OC\Repair\Collation;
-use OC\Repair\EnableFilesApp;
use OC\Repair\FillETags;
use OC\Repair\InnoDB;
use OC\Repair\RepairConfig;
@@ -85,7 +84,6 @@ class Repair extends BasicEmitter {
new AssetCache(),
new FillETags(\OC_DB::getConnection()),
new CleanTags(\OC_DB::getConnection()),
- new EnableFilesApp(\OC::$server->getConfig()),
);
}
diff --git a/lib/private/request.php b/lib/private/request.php
index 3bf7d94d9cf..ab011c913d9 100644
--- a/lib/private/request.php
+++ b/lib/private/request.php
@@ -13,7 +13,6 @@ class OC_Request {
const USER_AGENT_ANDROID_MOBILE_CHROME = '#Android.*Chrome/[.0-9]*#';
const USER_AGENT_FREEBOX = '#^Mozilla/5\.0$#';
const REGEX_LOCALHOST = '/^(127\.0\.0\.1|localhost)$/';
- static protected $reqId;
/**
* Returns the remote address, if the connection came from a trusted proxy and `forwarded_for_headers` has been configured
@@ -44,17 +43,6 @@ class OC_Request {
}
/**
- * Returns an ID for the request, value is not guaranteed to be unique and is mostly meant for logging
- * @return string
- */
- public static function getRequestID() {
- if(self::$reqId === null) {
- self::$reqId = hash('md5', microtime().\OC::$server->getSecureRandom()->getLowStrengthGenerator()->generate(20));
- }
- return self::$reqId;
- }
-
- /**
* Check overwrite condition
* @param string $type
* @return bool
diff --git a/lib/private/server.php b/lib/private/server.php
index 15c33e1905f..b023534ae21 100644
--- a/lib/private/server.php
+++ b/lib/private/server.php
@@ -10,7 +10,6 @@ use OC\Cache\UserCache;
use OC\Diagnostics\NullQueryLogger;
use OC\Diagnostics\EventLogger;
use OC\Diagnostics\QueryLogger;
-use OC\Files\Config\StorageManager;
use OC\Security\CertificateManager;
use OC\Files\Node\Root;
use OC\Files\View;
@@ -64,7 +63,7 @@ class Server extends SimpleContainer implements IServerContainer {
}
return new Request(
- array(
+ [
'get' => $_GET,
'post' => $_POST,
'files' => $_FILES,
@@ -76,7 +75,9 @@ class Server extends SimpleContainer implements IServerContainer {
: null,
'urlParams' => $urlParams,
'requesttoken' => $requestToken,
- ), $stream
+ ],
+ $this->getSecureRandom(),
+ $stream
);
});
$this->registerService('PreviewManager', function ($c) {
diff --git a/lib/private/share/share.php b/lib/private/share/share.php
index 9c3c6a2d3af..4753f6ecbfa 100644
--- a/lib/private/share/share.php
+++ b/lib/private/share/share.php
@@ -1166,13 +1166,20 @@ class Share extends \OC\Share\Constants {
* @return null
*/
protected static function unshareItem(array $item, $newParent = null) {
+
+ $shareType = (int)$item['share_type'];
+ $shareWith = null;
+ if ($shareType !== \OCP\Share::SHARE_TYPE_LINK) {
+ $shareWith = $item['share_with'];
+ }
+
// Pass all the vars we have for now, they may be useful
$hookParams = array(
'id' => $item['id'],
'itemType' => $item['item_type'],
'itemSource' => $item['item_source'],
- 'shareType' => (int)$item['share_type'],
- 'shareWith' => $item['share_with'],
+ 'shareType' => $shareType,
+ 'shareWith' => $shareWith,
'itemParent' => $item['parent'],
'uidOwner' => $item['uid_owner'],
);
diff --git a/lib/private/tags.php b/lib/private/tags.php
index 4d737e47e07..200ec8c2771 100644
--- a/lib/private/tags.php
+++ b/lib/private/tags.php
@@ -247,7 +247,7 @@ class Tags implements \OCP\ITags {
* Throws an exception if the tag could not be found.
*
* @param string $tag Tag id or name.
- * @return array An array of object ids or false on error.
+ * @return array|false An array of object ids or false on error.
*/
public function getIdsForTag($tag) {
$result = null;
@@ -337,7 +337,7 @@ class Tags implements \OCP\ITags {
* Add a new tag.
*
* @param string $name A string with a name of the tag
- * @return false|string the id of the added tag or false on error.
+ * @return false|int the id of the added tag or false on error.
*/
public function add($name) {
$name = trim($name);
@@ -575,7 +575,7 @@ class Tags implements \OCP\ITags {
/**
* Get favorites for an object type
*
- * @return array An array of object ids.
+ * @return array|false An array of object ids.
*/
public function getFavorites() {
try {
diff --git a/lib/private/template.php b/lib/private/template.php
index d407eb8384c..4fa1c867d54 100644
--- a/lib/private/template.php
+++ b/lib/private/template.php
@@ -223,7 +223,7 @@ class OC_Template extends \OC\Template\Base {
$content->assign('trace', $exception->getTraceAsString());
$content->assign('debugMode', defined('DEBUG') && DEBUG === true);
$content->assign('remoteAddr', OC_Request::getRemoteAddress());
- $content->assign('requestID', OC_Request::getRequestID());
+ $content->assign('requestID', \OC::$server->getRequest()->getId());
$content->printPage();
die();
}
diff --git a/lib/private/tempmanager.php b/lib/private/tempmanager.php
index a3bb07f9d63..60b9c9dc0d4 100644
--- a/lib/private/tempmanager.php
+++ b/lib/private/tempmanager.php
@@ -132,12 +132,14 @@ class TempManager implements ITempManager {
$cutOfTime = time() - 3600;
$files = array();
$dh = opendir($this->tmpBaseDir);
- while (($file = readdir($dh)) !== false) {
- if (substr($file, 0, 7) === 'oc_tmp_') {
- $path = $this->tmpBaseDir . '/' . $file;
- $mtime = filemtime($path);
- if ($mtime < $cutOfTime) {
- $files[] = $path;
+ if ($dh) {
+ while (($file = readdir($dh)) !== false) {
+ if (substr($file, 0, 7) === 'oc_tmp_') {
+ $path = $this->tmpBaseDir . '/' . $file;
+ $mtime = filemtime($path);
+ if ($mtime < $cutOfTime) {
+ $files[] = $path;
+ }
}
}
}
diff --git a/lib/private/util.php b/lib/private/util.php
index 9a01ca3ac95..988ea5c7c7b 100644
--- a/lib/private/util.php
+++ b/lib/private/util.php
@@ -1272,6 +1272,32 @@ class OC_Util {
}
/**
+ * Clear a single file from the opcode cache
+ * This is useful for writing to the config file
+ * in case the opcode cache does not re-validate files
+ * Returns true if successful, false if unsuccessful:
+ * caller should fall back on clearing the entire cache
+ * with clearOpcodeCache() if unsuccessful
+ *
+ * @param string $path the path of the file to clear from the cache
+ * @return bool true if underlying function returns true, otherwise false
+ */
+ public static function deleteFromOpcodeCache($path) {
+ $ret = false;
+ if ($path) {
+ // APC >= 3.1.1
+ if (function_exists('apc_delete_file')) {
+ $ret = @apc_delete_file($path);
+ }
+ // Zend OpCache >= 7.0.0, PHP >= 5.5.0
+ if (function_exists('opcache_invalidate')) {
+ $ret = opcache_invalidate($path);
+ }
+ }
+ return $ret;
+ }
+
+ /**
* Clear the opcode cache if one exists
* This is necessary for writing to the config file
* in case the opcode cache does not re-validate files
diff --git a/lib/public/appframework/apicontroller.php b/lib/public/appframework/apicontroller.php
index 5272f3ed529..b62e352c319 100644
--- a/lib/public/appframework/apicontroller.php
+++ b/lib/public/appframework/apicontroller.php
@@ -3,7 +3,7 @@
* ownCloud - App Framework
*
* @author Bernhard Posselt
- * @copyright 2012 Bernhard Posselt nukeawhale@gmail.com
+ * @copyright 2012 Bernhard Posselt <dev@bernhard-posselt.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
@@ -44,17 +44,17 @@ abstract class ApiController extends Controller {
* constructor of the controller
* @param string $appName the name of the app
* @param IRequest $request an instance of the request
- * @param string $corsMethods: comma seperated string of HTTP verbs which
+ * @param string $corsMethods: comma seperated string of HTTP verbs which
* should be allowed for websites or webapps when calling your API, defaults to
* 'PUT, POST, GET, DELETE, PATCH'
* @param string $corsAllowedHeaders: comma seperated string of HTTP headers
- * which should be allowed for websites or webapps when calling your API,
+ * which should be allowed for websites or webapps when calling your API,
* defaults to 'Authorization, Content-Type, Accept'
* @param int $corsMaxAge number in seconds how long a preflighted OPTIONS
* request should be cached, defaults to 1728000 seconds
*/
- public function __construct($appName,
- IRequest $request,
+ public function __construct($appName,
+ IRequest $request,
$corsMethods='PUT, POST, GET, DELETE, PATCH',
$corsAllowedHeaders='Authorization, Content-Type, Accept',
$corsMaxAge=1728000){
diff --git a/lib/public/appframework/http/ocsresponse.php b/lib/public/appframework/http/ocsresponse.php
new file mode 100644
index 00000000000..590a256fe28
--- /dev/null
+++ b/lib/public/appframework/http/ocsresponse.php
@@ -0,0 +1,99 @@
+<?php
+/**
+ * ownCloud - App Framework
+ *
+ * @author Bernhard Posselt
+ * @copyright 2015 Bernhard Posselt <dev@bernhard-posselt.com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+/**
+ * Public interface of ownCloud for apps to use.
+ * AppFramework\HTTP\JSONResponse class
+ */
+
+namespace OCP\AppFramework\Http;
+
+use OCP\AppFramework\Http;
+
+use OC_OCS;
+
+/**
+ * A renderer for OCS responses
+ */
+class OCSResponse extends Response {
+
+ private $data;
+ private $format;
+ private $statuscode;
+ private $message;
+ private $tag;
+ private $tagattribute;
+ private $dimension;
+ private $itemscount;
+ private $itemsperpage;
+
+ /**
+ * generates the xml or json response for the API call from an multidimenional data array.
+ * @param string $format
+ * @param string $status
+ * @param string $statuscode
+ * @param string $message
+ * @param array $data
+ * @param string $tag
+ * @param string $tagattribute
+ * @param int $dimension
+ * @param int|string $itemscount
+ * @param int|string $itemsperpage
+ */
+ public function __construct($format, $status, $statuscode, $message,
+ $data=[], $tag='', $tagattribute='',
+ $dimension=-1, $itemscount='',
+ $itemsperpage='') {
+ $this->format = $format;
+ $this->status = $status;
+ $this->statuscode = $statuscode;
+ $this->message = $message;
+ $this->data = $data;
+ $this->tag = $tag;
+ $this->tagattribute = $tagattribute;
+ $this->dimension = $dimension;
+ $this->itemscount = $itemscount;
+ $this->itemsperpage = $itemsperpage;
+
+ // set the correct header based on the format parameter
+ if ($format === 'json') {
+ $this->addHeader(
+ 'Content-Type', 'application/json; charset=utf-8'
+ );
+ } else {
+ $this->addHeader(
+ 'Content-Type', 'application/xml; charset=utf-8'
+ );
+ }
+ }
+
+
+ public function render() {
+ return OC_OCS::generateXml(
+ $this->format, $this->status, $this->statuscode, $this->message,
+ $this->data, $this->tag, $this->tagattribute, $this->dimension,
+ $this->itemscount, $this->itemsperpage
+ );
+ }
+
+
+} \ No newline at end of file
diff --git a/lib/public/appframework/ocscontroller.php b/lib/public/appframework/ocscontroller.php
new file mode 100644
index 00000000000..3e9907666bb
--- /dev/null
+++ b/lib/public/appframework/ocscontroller.php
@@ -0,0 +1,103 @@
+<?php
+/**
+ * ownCloud - App Framework
+ *
+ * @author Bernhard Posselt
+ * @copyright 2015 Bernhard Posselt <dev@bernhard-posselt.com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+/**
+ * Public interface of ownCloud for apps to use.
+ * AppFramework\Controller class
+ */
+
+namespace OCP\AppFramework;
+
+use OCP\AppFramework\Http\DataResponse;
+use OCP\AppFramework\Http\OCSResponse;
+use OCP\IRequest;
+
+
+/**
+ * Base class to inherit your controllers from that are used for RESTful APIs
+ */
+abstract class OCSController extends ApiController {
+
+ /**
+ * constructor of the controller
+ * @param string $appName the name of the app
+ * @param IRequest $request an instance of the request
+ * @param string $corsMethods: comma seperated string of HTTP verbs which
+ * should be allowed for websites or webapps when calling your API, defaults to
+ * 'PUT, POST, GET, DELETE, PATCH'
+ * @param string $corsAllowedHeaders: comma seperated string of HTTP headers
+ * which should be allowed for websites or webapps when calling your API,
+ * defaults to 'Authorization, Content-Type, Accept'
+ * @param int $corsMaxAge number in seconds how long a preflighted OPTIONS
+ * request should be cached, defaults to 1728000 seconds
+ */
+ public function __construct($appName,
+ IRequest $request,
+ $corsMethods='PUT, POST, GET, DELETE, PATCH',
+ $corsAllowedHeaders='Authorization, Content-Type, Accept',
+ $corsMaxAge=1728000){
+ parent::__construct($appName, $request, $corsMethods,
+ $corsAllowedHeaders, $corsMaxAge);
+ $this->registerResponder('json', function ($data) {
+ return $this->buildOCSResponse('json', $data);
+ });
+ $this->registerResponder('xml', function ($data) {
+ return $this->buildOCSResponse('xml', $data);
+ });
+ }
+
+
+ /**
+ * Unwrap data and build ocs response
+ * @param string $format json or xml
+ * @param array|DataResponse $data the data which should be transformed
+ */
+ private function buildOCSResponse($format, $data) {
+ if ($data instanceof DataResponse) {
+ $data = $data->getData();
+ }
+
+ $params = [
+ 'status' => 'OK',
+ 'statuscode' => 100,
+ 'message' => 'OK',
+ 'data' => [],
+ 'tag' => '',
+ 'tagattribute' => '',
+ 'dimension' => 'dynamic',
+ 'itemscount' => '',
+ 'itemsperpage' => ''
+ ];
+
+ foreach ($data as $key => $value) {
+ $params[$key] = $value;
+ }
+
+ return new OCSResponse(
+ $format, $params['status'], $params['statuscode'],
+ $params['message'], $params['data'], $params['tag'],
+ $params['tagattribute'], $params['dimension'],
+ $params['itemscount'], $params['itemsperpage']
+ );
+ }
+
+}
diff --git a/lib/public/files/storage.php b/lib/public/files/storage.php
index 36d5b800df6..3e6559c28f7 100644
--- a/lib/public/files/storage.php
+++ b/lib/public/files/storage.php
@@ -72,7 +72,7 @@ interface Storage {
* see http://php.net/manual/en/function.opendir.php
*
* @param string $path
- * @return resource
+ * @return resource|false
*/
public function opendir($path);
@@ -97,7 +97,7 @@ interface Storage {
* only the following keys are required in the result: size and mtime
*
* @param string $path
- * @return array
+ * @return array|false
*/
public function stat($path);
@@ -105,7 +105,7 @@ interface Storage {
* see http://php.net/manual/en/function.filetype.php
*
* @param string $path
- * @return bool
+ * @return string|false
*/
public function filetype($path);
@@ -114,7 +114,7 @@ interface Storage {
* The result for filesize when called on a folder is required to be 0
*
* @param string $path
- * @return int
+ * @return int|false
*/
public function filesize($path);
@@ -179,7 +179,7 @@ interface Storage {
* see http://php.net/manual/en/function.filemtime.php
*
* @param string $path
- * @return int
+ * @return int|false
*/
public function filemtime($path);
@@ -187,7 +187,7 @@ interface Storage {
* see http://php.net/manual/en/function.file_get_contents.php
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function file_get_contents($path);
@@ -231,7 +231,7 @@ interface Storage {
*
* @param string $path
* @param string $mode
- * @return resource
+ * @return resource|false
*/
public function fopen($path, $mode);
@@ -240,7 +240,7 @@ interface Storage {
* The mimetype for a folder is required to be "httpd/unix-directory"
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function getMimeType($path);
@@ -250,7 +250,7 @@ interface Storage {
* @param string $type
* @param string $path
* @param bool $raw
- * @return string
+ * @return string|false
*/
public function hash($type, $path, $raw = false);
@@ -258,7 +258,7 @@ interface Storage {
* see http://php.net/manual/en/function.free_space.php
*
* @param string $path
- * @return int
+ * @return int|false
*/
public function free_space($path);
@@ -266,7 +266,7 @@ interface Storage {
* search for occurrences of $query in file names
*
* @param string $query
- * @return array
+ * @return array|false
*/
public function search($query);
@@ -285,7 +285,7 @@ interface Storage {
* The local version of the file can be temporary and doesn't have to be persistent across requests
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function getLocalFile($path);
@@ -294,7 +294,7 @@ interface Storage {
* The local version of the folder can be temporary and doesn't have to be persistent across requests
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function getLocalFolder($path);
/**
@@ -313,7 +313,7 @@ interface Storage {
* get the ETag for a file or folder
*
* @param string $path
- * @return string
+ * @return string|false
*/
public function getETag($path);
@@ -342,7 +342,7 @@ interface Storage {
* For now the returned array can hold the parameter url - in future more attributes might follow.
*
* @param string $path
- * @return array
+ * @return array|false
*/
public function getDirectDownload($path);
}
diff --git a/lib/public/iappconfig.php b/lib/public/iappconfig.php
index cbd1a7e0573..3a976b4a263 100644
--- a/lib/public/iappconfig.php
+++ b/lib/public/iappconfig.php
@@ -58,7 +58,7 @@ interface IAppConfig {
*
* @param string|false $key
* @param string|false $app
- * @return array
+ * @return array|false
*/
public function getValues($app, $key);
diff --git a/lib/public/iavatar.php b/lib/public/iavatar.php
index 213d2e6cef5..fdb044f9e5c 100644
--- a/lib/public/iavatar.php
+++ b/lib/public/iavatar.php
@@ -21,6 +21,13 @@ interface IAvatar {
function get($size = 64);
/**
+ * Check if an avatar exists for the user
+ *
+ * @return bool
+ */
+ public function exists();
+
+ /**
* sets the users avatar
* @param Image $data mixed imagedata or path to set a new avatar
* @throws \Exception if the provided file is not a jpg or png image
diff --git a/lib/public/irequest.php b/lib/public/irequest.php
index 988b3aebd7b..b5ea1fa95da 100644
--- a/lib/public/irequest.php
+++ b/lib/public/irequest.php
@@ -127,4 +127,11 @@ interface IRequest {
* @return bool true if CSRF check passed
*/
public function passesCSRFCheck();
+
+ /**
+ * Returns an ID for the request, value is not guaranteed to be unique and is mostly meant for logging
+ * If `mod_unique_id` is installed this value will be taken.
+ * @return string
+ */
+ public function getId();
}
diff --git a/lib/public/itags.php b/lib/public/itags.php
index 238b12c6424..ec6da9eb512 100644
--- a/lib/public/itags.php
+++ b/lib/public/itags.php
@@ -97,7 +97,7 @@ interface ITags {
* Throws an exception if the tag could not be found.
*
* @param string|integer $tag Tag id or name.
- * @return array An array of object ids or false on error.
+ * @return array|false An array of object ids or false on error.
*/
public function getIdsForTag($tag);
@@ -123,7 +123,7 @@ interface ITags {
* Add a new tag.
*
* @param string $name A string with a name of the tag
- * @return int the id of the added tag or false if it already exists.
+ * @return int|false the id of the added tag or false if it already exists.
*/
public function add($name);
@@ -158,7 +158,7 @@ interface ITags {
/**
* Get favorites for an object type
*
- * @return array An array of object ids.
+ * @return array|false An array of object ids.
*/
public function getFavorites();
diff --git a/lib/public/share_backend.php b/lib/public/share_backend.php
index 1ae63d4c1db..0062648d82c 100644
--- a/lib/public/share_backend.php
+++ b/lib/public/share_backend.php
@@ -46,7 +46,7 @@ interface Share_Backend {
* Converts the shared item sources back into the item in the specified format
* @param array $items Shared items
* @param int $format
- * @return TODO
+ * @return array
*
* The items array is a 3-dimensional array with the item_source as the
* first key and the share id as the second key to an array with the share
diff --git a/lib/repair/enablefilesapp.php b/lib/repair/enablefilesapp.php
deleted file mode 100644
index a3298cf76b3..00000000000
--- a/lib/repair/enablefilesapp.php
+++ /dev/null
@@ -1,50 +0,0 @@
-<?php
-/**
- * Copyright (c) 2015 Morris Jobke <hey@morrisjobke.de>
- * This file is licensed under the Affero General Public License version 3 or
- * later.
- * See the COPYING-README file.
- */
-
-namespace OC\Repair;
-
-use OC\Hooks\BasicEmitter;
-use OC\RepairStep;
-use OCP\IConfig;
-
-/**
- * Class EnableFilesApp - enables files app if disabled
- *
- * TODO: remove this with ownCloud 8.1 - this isn't possible anymore with 8.0
- *
- * @package OC\Repair
- */
-class EnableFilesApp extends BasicEmitter implements RepairStep {
-
- /** @var IConfig */
- protected $config;
-
- /**
- * @param IConfig $config
- */
- public function __construct(IConfig $config) {
- $this->config = $config;
- }
-
- /**
- * @return string
- */
- public function getName() {
- return 'Re-enable file app';
- }
-
- /**
- * Enables the files app if it is disabled
- */
- public function run() {
- if ($this->config->getAppValue('files', 'enabled', 'no') !== 'yes') {
- $this->config->setAppValue('files', 'enabled', 'yes');
- $this->emit('\OC\Repair', 'info', ['Files app was disabled - re-enabled']);
- }
- }
-}
diff --git a/settings/l10n/de.js b/settings/l10n/de.js
index b9fa4d575e3..c9886e0ac3f 100644
--- a/settings/l10n/de.js
+++ b/settings/l10n/de.js
@@ -53,17 +53,17 @@ OC.L10N.register(
"Email saved" : "E-Mail Adresse gespeichert",
"Are you really sure you want add \"{domain}\" as trusted domain?" : "Bist Du dir wirklich sicher, dass Du \"{domain}\" als vertrauenswürdige Domain hinzufügen möchtest?",
"Add trusted domain" : "Vertrauenswürdige Domain hinzufügen",
- "Sending..." : "Sende...",
+ "Sending..." : "Senden…",
"All" : "Alle",
- "Please wait...." : "Bitte warten...",
+ "Please wait...." : "Bitte warten…",
"Error while disabling app" : "Beim Deaktivieren der Applikation ist ein Fehler aufgetreten",
"Disable" : "Deaktivieren",
"Enable" : "Aktivieren",
"Error while enabling app" : "Beim Aktivieren der Applikation ist ein Fehler aufgetreten",
- "Updating...." : "Aktualisierung...",
+ "Updating...." : "Aktualisierung…",
"Error while updating app" : "Fehler beim Aktualisieren der App",
"Updated" : "Aktualisiert",
- "Uninstalling ...." : "Deinstalliere ....",
+ "Uninstalling ...." : "Deinstallieren…",
"Error while uninstalling app" : "Fehler beim Deinstallieren der App",
"Uninstall" : "Deinstallieren",
"Select a profile picture" : "Wähle ein Profilbild",
@@ -74,7 +74,7 @@ OC.L10N.register(
"Strong password" : "Starkes Passwort",
"Valid until {date}" : "Gültig bis {date}",
"Delete" : "Löschen",
- "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien... Bitte warten, dieser Vorgang kann einige Zeit beanspruchen.",
+ "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien… Bitte warten, dieser Vorgang kann einige Zeit beanspruchen.",
"Delete encryption keys permanently." : "Verschlüsselungsschlüssel dauerhaft löschen.",
"Restore encryption keys." : "Verschlüsselungsschlüssel wiederherstellen.",
"Groups" : "Gruppen",
diff --git a/settings/l10n/de.json b/settings/l10n/de.json
index 4b9396cfb96..7c429a97568 100644
--- a/settings/l10n/de.json
+++ b/settings/l10n/de.json
@@ -51,17 +51,17 @@
"Email saved" : "E-Mail Adresse gespeichert",
"Are you really sure you want add \"{domain}\" as trusted domain?" : "Bist Du dir wirklich sicher, dass Du \"{domain}\" als vertrauenswürdige Domain hinzufügen möchtest?",
"Add trusted domain" : "Vertrauenswürdige Domain hinzufügen",
- "Sending..." : "Sende...",
+ "Sending..." : "Senden…",
"All" : "Alle",
- "Please wait...." : "Bitte warten...",
+ "Please wait...." : "Bitte warten…",
"Error while disabling app" : "Beim Deaktivieren der Applikation ist ein Fehler aufgetreten",
"Disable" : "Deaktivieren",
"Enable" : "Aktivieren",
"Error while enabling app" : "Beim Aktivieren der Applikation ist ein Fehler aufgetreten",
- "Updating...." : "Aktualisierung...",
+ "Updating...." : "Aktualisierung…",
"Error while updating app" : "Fehler beim Aktualisieren der App",
"Updated" : "Aktualisiert",
- "Uninstalling ...." : "Deinstalliere ....",
+ "Uninstalling ...." : "Deinstallieren…",
"Error while uninstalling app" : "Fehler beim Deinstallieren der App",
"Uninstall" : "Deinstallieren",
"Select a profile picture" : "Wähle ein Profilbild",
@@ -72,7 +72,7 @@
"Strong password" : "Starkes Passwort",
"Valid until {date}" : "Gültig bis {date}",
"Delete" : "Löschen",
- "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien... Bitte warten, dieser Vorgang kann einige Zeit beanspruchen.",
+ "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien… Bitte warten, dieser Vorgang kann einige Zeit beanspruchen.",
"Delete encryption keys permanently." : "Verschlüsselungsschlüssel dauerhaft löschen.",
"Restore encryption keys." : "Verschlüsselungsschlüssel wiederherstellen.",
"Groups" : "Gruppen",
diff --git a/settings/l10n/de_DE.js b/settings/l10n/de_DE.js
index 9ed520da8fa..3bef405cf4b 100644
--- a/settings/l10n/de_DE.js
+++ b/settings/l10n/de_DE.js
@@ -55,12 +55,12 @@ OC.L10N.register(
"Add trusted domain" : "Vertrauenswürdige Domain hinzufügen",
"Sending..." : "Wird gesendet …",
"All" : "Alle",
- "Please wait...." : "Bitte warten....",
+ "Please wait...." : "Bitte warten…",
"Error while disabling app" : "Beim Deaktivieren der Applikation ist ein Fehler aufgetreten",
"Disable" : "Deaktivieren",
"Enable" : "Aktivieren",
"Error while enabling app" : "Beim Aktivieren der Applikation ist ein Fehler aufgetreten",
- "Updating...." : "Update...",
+ "Updating...." : "Update…",
"Error while updating app" : "Es ist ein Fehler während des Updates aufgetreten",
"Updated" : "Aktualisiert",
"Uninstalling ...." : "Wird deinstalliert …",
@@ -74,7 +74,7 @@ OC.L10N.register(
"Strong password" : "Starkes Passwort",
"Valid until {date}" : "Gültig bis {date}",
"Delete" : "Löschen",
- "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien... Bitte warten Sie, dieser Vorgang kann einige Zeit beanspruchen.",
+ "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien… Bitte warten Sie, dieser Vorgang kann einige Zeit beanspruchen.",
"Delete encryption keys permanently." : "Verschlüsselungsschlüssel dauerhaft löschen.",
"Restore encryption keys." : "Verschlüsselungsschlüssel wiederherstellen.",
"Groups" : "Gruppen",
diff --git a/settings/l10n/de_DE.json b/settings/l10n/de_DE.json
index 361a3aa9614..c74968f2c56 100644
--- a/settings/l10n/de_DE.json
+++ b/settings/l10n/de_DE.json
@@ -53,12 +53,12 @@
"Add trusted domain" : "Vertrauenswürdige Domain hinzufügen",
"Sending..." : "Wird gesendet …",
"All" : "Alle",
- "Please wait...." : "Bitte warten....",
+ "Please wait...." : "Bitte warten…",
"Error while disabling app" : "Beim Deaktivieren der Applikation ist ein Fehler aufgetreten",
"Disable" : "Deaktivieren",
"Enable" : "Aktivieren",
"Error while enabling app" : "Beim Aktivieren der Applikation ist ein Fehler aufgetreten",
- "Updating...." : "Update...",
+ "Updating...." : "Update…",
"Error while updating app" : "Es ist ein Fehler während des Updates aufgetreten",
"Updated" : "Aktualisiert",
"Uninstalling ...." : "Wird deinstalliert …",
@@ -72,7 +72,7 @@
"Strong password" : "Starkes Passwort",
"Valid until {date}" : "Gültig bis {date}",
"Delete" : "Löschen",
- "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien... Bitte warten Sie, dieser Vorgang kann einige Zeit beanspruchen.",
+ "Decrypting files... Please wait, this can take some time." : "Entschlüssele Dateien… Bitte warten Sie, dieser Vorgang kann einige Zeit beanspruchen.",
"Delete encryption keys permanently." : "Verschlüsselungsschlüssel dauerhaft löschen.",
"Restore encryption keys." : "Verschlüsselungsschlüssel wiederherstellen.",
"Groups" : "Gruppen",
diff --git a/settings/l10n/ja.js b/settings/l10n/ja.js
index 385156e5620..0e0547c8be2 100644
--- a/settings/l10n/ja.js
+++ b/settings/l10n/ja.js
@@ -55,7 +55,7 @@ OC.L10N.register(
"Add trusted domain" : "信頼するドメイン名に追加",
"Sending..." : "送信中…",
"All" : "すべて",
- "Please wait...." : "しばらくお待ちください。",
+ "Please wait...." : "しばらくお待ちください...",
"Error while disabling app" : "アプリ無効化中にエラーが発生",
"Disable" : "無効",
"Enable" : "有効にする",
@@ -127,15 +127,15 @@ OC.L10N.register(
"We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "次のロケールをサポートするために、システムに必要なパッケージをインストールすることを強くおすすめします: %s。",
"URL generation in notification emails" : "通知メールにURLを生成",
"If your installation is not installed in the root of the domain and uses system cron, there can be issues with the URL generation. To avoid these problems, please set the \"overwrite.cli.url\" option in your config.php file to the webroot path of your installation (Suggested: \"%s\")" : "もし、URLがドメインのルート(/)で終わっていない場合で、システムのcronを利用している場合、URLの生成に問題が発生します。その場合は、config.php ファイルの中の \"overwrite.cli.url\" オプションをインストールしたwebrootのパスに設定してください。(推奨: \"%s\")",
- "Configuration Checks" : "設定を確認",
+ "Configuration Checks" : "設定のチェック",
"No problems found" : "問題は見つかりませんでした",
"Please double check the <a href='%s'>installation guides</a>." : "<a href='%s'>インストールガイド</a>をよく確認してください。",
"Last cron was executed at %s." : "直近では%sにcronが実行されました。",
"Last cron was executed at %s. This is more than an hour ago, something seems wrong." : "直近では%sにcronが実行されました。これは1時間以上前になるので、何かおかしいです。",
- "Cron was not executed yet!" : "cron は未だ実行されていません!",
+ "Cron was not executed yet!" : "cronはまだ実行されていません!",
"Execute one task with each page loaded" : "各ページの読み込み時にタスクを実行します。",
"cron.php is registered at a webcron service to call cron.php every 15 minutes over http." : "cron.phpは、HTTP経由で15分ごとにcron.phpを実行するようwebcronサービスに登録されています。",
- "Use system's cron service to call the cron.php file every 15 minutes." : "システムの cron サービスを利用して、15分間隔で cron.php ファイルを実行する。",
+ "Use system's cron service to call the cron.php file every 15 minutes." : "システムのcronサービスを利用して、15分間隔でcron.phpファイルを実行する。",
"Allow apps to use the Share API" : "アプリからの共有APIの利用を許可する",
"Allow users to share via link" : "URLリンクで共有を許可する",
"Enforce password protection" : "常にパスワード保護を有効にする",
@@ -178,8 +178,8 @@ OC.L10N.register(
"Developed by the <a href=\"http://ownCloud.org/contact\" target=\"_blank\">ownCloud community</a>, the <a href=\"https://github.com/owncloud\" target=\"_blank\">source code</a> is licensed under the <a href=\"http://www.gnu.org/licenses/agpl-3.0.html\" target=\"_blank\"><abbr title=\"Affero General Public License\">AGPL</abbr></a>." : "<a href=\"http://ownCloud.org/contact\" target=\"_blank\">ownCloud コミュニティ</a>により開発されています。 <a href=\"https://github.com/owncloud\" target=\"_blank\">ソースコード</a>は、<a href=\"http://www.gnu.org/licenses/agpl-3.0.html\" target=\"_blank\"><abbr title=\"Affero General Public License\">AGPL</abbr></a> ライセンスの下で提供されています。",
"More apps" : "他のアプリ",
"Add your app" : "アプリを追加",
- "by" : "により",
- "licensed" : "ライセンスされた",
+ "by" : "by",
+ "licensed" : "ライセンス",
"Documentation:" : "ドキュメント:",
"User Documentation" : "ユーザードキュメント",
"Admin Documentation" : "管理者ドキュメント",
diff --git a/settings/l10n/ja.json b/settings/l10n/ja.json
index 04f05c201c8..83193ef9c8c 100644
--- a/settings/l10n/ja.json
+++ b/settings/l10n/ja.json
@@ -53,7 +53,7 @@
"Add trusted domain" : "信頼するドメイン名に追加",
"Sending..." : "送信中…",
"All" : "すべて",
- "Please wait...." : "しばらくお待ちください。",
+ "Please wait...." : "しばらくお待ちください...",
"Error while disabling app" : "アプリ無効化中にエラーが発生",
"Disable" : "無効",
"Enable" : "有効にする",
@@ -125,15 +125,15 @@
"We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "次のロケールをサポートするために、システムに必要なパッケージをインストールすることを強くおすすめします: %s。",
"URL generation in notification emails" : "通知メールにURLを生成",
"If your installation is not installed in the root of the domain and uses system cron, there can be issues with the URL generation. To avoid these problems, please set the \"overwrite.cli.url\" option in your config.php file to the webroot path of your installation (Suggested: \"%s\")" : "もし、URLがドメインのルート(/)で終わっていない場合で、システムのcronを利用している場合、URLの生成に問題が発生します。その場合は、config.php ファイルの中の \"overwrite.cli.url\" オプションをインストールしたwebrootのパスに設定してください。(推奨: \"%s\")",
- "Configuration Checks" : "設定を確認",
+ "Configuration Checks" : "設定のチェック",
"No problems found" : "問題は見つかりませんでした",
"Please double check the <a href='%s'>installation guides</a>." : "<a href='%s'>インストールガイド</a>をよく確認してください。",
"Last cron was executed at %s." : "直近では%sにcronが実行されました。",
"Last cron was executed at %s. This is more than an hour ago, something seems wrong." : "直近では%sにcronが実行されました。これは1時間以上前になるので、何かおかしいです。",
- "Cron was not executed yet!" : "cron は未だ実行されていません!",
+ "Cron was not executed yet!" : "cronはまだ実行されていません!",
"Execute one task with each page loaded" : "各ページの読み込み時にタスクを実行します。",
"cron.php is registered at a webcron service to call cron.php every 15 minutes over http." : "cron.phpは、HTTP経由で15分ごとにcron.phpを実行するようwebcronサービスに登録されています。",
- "Use system's cron service to call the cron.php file every 15 minutes." : "システムの cron サービスを利用して、15分間隔で cron.php ファイルを実行する。",
+ "Use system's cron service to call the cron.php file every 15 minutes." : "システムのcronサービスを利用して、15分間隔でcron.phpファイルを実行する。",
"Allow apps to use the Share API" : "アプリからの共有APIの利用を許可する",
"Allow users to share via link" : "URLリンクで共有を許可する",
"Enforce password protection" : "常にパスワード保護を有効にする",
@@ -176,8 +176,8 @@
"Developed by the <a href=\"http://ownCloud.org/contact\" target=\"_blank\">ownCloud community</a>, the <a href=\"https://github.com/owncloud\" target=\"_blank\">source code</a> is licensed under the <a href=\"http://www.gnu.org/licenses/agpl-3.0.html\" target=\"_blank\"><abbr title=\"Affero General Public License\">AGPL</abbr></a>." : "<a href=\"http://ownCloud.org/contact\" target=\"_blank\">ownCloud コミュニティ</a>により開発されています。 <a href=\"https://github.com/owncloud\" target=\"_blank\">ソースコード</a>は、<a href=\"http://www.gnu.org/licenses/agpl-3.0.html\" target=\"_blank\"><abbr title=\"Affero General Public License\">AGPL</abbr></a> ライセンスの下で提供されています。",
"More apps" : "他のアプリ",
"Add your app" : "アプリを追加",
- "by" : "により",
- "licensed" : "ライセンスされた",
+ "by" : "by",
+ "licensed" : "ライセンス",
"Documentation:" : "ドキュメント:",
"User Documentation" : "ユーザードキュメント",
"Admin Documentation" : "管理者ドキュメント",
diff --git a/settings/l10n/sk_SK.js b/settings/l10n/sk_SK.js
index e320a3bd632..a79072c5970 100644
--- a/settings/l10n/sk_SK.js
+++ b/settings/l10n/sk_SK.js
@@ -115,6 +115,9 @@ OC.L10N.register(
"PHP is apparently setup to strip inline doc blocks. This will make several core apps inaccessible." : "PHP je zjavne nastavené, aby odstraňovalo bloky vloženej dokumentácie. To zneprístupní niekoľko základných aplikácií.",
"This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "To je pravdepodobne spôsobené cache/akcelerátorom ako napr. Zend OPcache alebo eAccelerator.",
"Database Performance Info" : "Informácie o výkone databázy",
+ "SQLite is used as database. For larger installations we recommend to switch to a different database backend." : "Ako databáza je použitá SQLite. Pre veľké inštalácie odporúčame prejsť na inú databázu.",
+ "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Najmä pri používaní aplikácie na synchronizáciu s desktopom nie je databáza SQLite doporučená.",
+ "To migrate to another database use the command line tool: 'occ db:convert-type'" : "Pre migráciu na inú databázu možno použiť aplikáciu pre príkazový riadok: 'occ db:convert-type'",
"Microsoft Windows Platform" : "Platforma Microsoft Windows",
"Your server is running on Microsoft Windows. We highly recommend Linux for optimal user experience." : "Server je spustený s Microsoft Windows. Pre optimálne používanie odporúčame Linux.",
"Module 'fileinfo' missing" : "Chýba modul 'fileinfo'",
diff --git a/settings/l10n/sk_SK.json b/settings/l10n/sk_SK.json
index 24ffec558d2..201fd7ba024 100644
--- a/settings/l10n/sk_SK.json
+++ b/settings/l10n/sk_SK.json
@@ -113,6 +113,9 @@
"PHP is apparently setup to strip inline doc blocks. This will make several core apps inaccessible." : "PHP je zjavne nastavené, aby odstraňovalo bloky vloženej dokumentácie. To zneprístupní niekoľko základných aplikácií.",
"This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "To je pravdepodobne spôsobené cache/akcelerátorom ako napr. Zend OPcache alebo eAccelerator.",
"Database Performance Info" : "Informácie o výkone databázy",
+ "SQLite is used as database. For larger installations we recommend to switch to a different database backend." : "Ako databáza je použitá SQLite. Pre veľké inštalácie odporúčame prejsť na inú databázu.",
+ "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "Najmä pri používaní aplikácie na synchronizáciu s desktopom nie je databáza SQLite doporučená.",
+ "To migrate to another database use the command line tool: 'occ db:convert-type'" : "Pre migráciu na inú databázu možno použiť aplikáciu pre príkazový riadok: 'occ db:convert-type'",
"Microsoft Windows Platform" : "Platforma Microsoft Windows",
"Your server is running on Microsoft Windows. We highly recommend Linux for optimal user experience." : "Server je spustený s Microsoft Windows. Pre optimálne používanie odporúčame Linux.",
"Module 'fileinfo' missing" : "Chýba modul 'fileinfo'",
diff --git a/settings/l10n/sr.js b/settings/l10n/sr.js
index a0d388d1dc9..915913b8950 100644
--- a/settings/l10n/sr.js
+++ b/settings/l10n/sr.js
@@ -11,6 +11,7 @@ OC.L10N.register(
"Unable to add user to group %s" : "Не могу да додам корисника у групу %s",
"Unable to remove user from group %s" : "Не могу да уклоним корисника из групе %s",
"Couldn't update app." : "Не могу да ажурирам апликацију.",
+ "Wrong password" : "Лозинка пограшна",
"Email sent" : "Порука је послата",
"Email saved" : "Е-порука сачувана",
"Please wait...." : "Сачекајте…",
@@ -41,6 +42,7 @@ OC.L10N.register(
"Allow apps to use the Share API" : "Дозвољава апликацијама да користе API Share",
"Allow resharing" : "Дозволи поновно дељење",
"Enforce HTTPS" : "Наметни HTTPS",
+ "Authentication required" : "Неопходна провера идентитета",
"Server address" : "Адреса сервера",
"Port" : "Порт",
"Log level" : "Ниво бележења",
diff --git a/settings/l10n/sr.json b/settings/l10n/sr.json
index a8314f1ccb5..cb6bd430507 100644
--- a/settings/l10n/sr.json
+++ b/settings/l10n/sr.json
@@ -9,6 +9,7 @@
"Unable to add user to group %s" : "Не могу да додам корисника у групу %s",
"Unable to remove user from group %s" : "Не могу да уклоним корисника из групе %s",
"Couldn't update app." : "Не могу да ажурирам апликацију.",
+ "Wrong password" : "Лозинка пограшна",
"Email sent" : "Порука је послата",
"Email saved" : "Е-порука сачувана",
"Please wait...." : "Сачекајте…",
@@ -39,6 +40,7 @@
"Allow apps to use the Share API" : "Дозвољава апликацијама да користе API Share",
"Allow resharing" : "Дозволи поновно дељење",
"Enforce HTTPS" : "Наметни HTTPS",
+ "Authentication required" : "Неопходна провера идентитета",
"Server address" : "Адреса сервера",
"Port" : "Порт",
"Log level" : "Ниво бележења",
diff --git a/tests/lib/appframework/controller/ApiControllerTest.php b/tests/lib/appframework/controller/ApiControllerTest.php
index 3055fbe0da8..b2e52cc0b5c 100644
--- a/tests/lib/appframework/controller/ApiControllerTest.php
+++ b/tests/lib/appframework/controller/ApiControllerTest.php
@@ -4,7 +4,7 @@
* ownCloud - App Framework
*
* @author Bernhard Posselt
- * @copyright 2012 Bernhard Posselt nukeawhale@gmail.com
+ * @copyright 2012 Bernhard Posselt <dev@bernhard-posselt.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
@@ -25,18 +25,19 @@
namespace OCP\AppFramework;
use OC\AppFramework\Http\Request;
-use OCP\AppFramework\Http\TemplateResponse;
class ChildApiController extends ApiController {};
class ApiControllerTest extends \Test\TestCase {
-
+ /** @var ChildApiController */
+ protected $controller;
public function testCors() {
$request = new Request(
- array('server' => array('HTTP_ORIGIN' => 'test'))
+ ['server' => ['HTTP_ORIGIN' => 'test']],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$this->controller = new ChildApiController('app', $request, 'verbs',
'headers', 100);
diff --git a/tests/lib/appframework/controller/ControllerTest.php b/tests/lib/appframework/controller/ControllerTest.php
index 18d47d00f6b..58395d05914 100644
--- a/tests/lib/appframework/controller/ControllerTest.php
+++ b/tests/lib/appframework/controller/ControllerTest.php
@@ -66,15 +66,16 @@ class ControllerTest extends \Test\TestCase {
parent::setUp();
$request = new Request(
- array(
- 'get' => array('name' => 'John Q. Public', 'nickname' => 'Joey'),
- 'post' => array('name' => 'Jane Doe', 'nickname' => 'Janey'),
- 'urlParams' => array('name' => 'Johnny Weissmüller'),
- 'files' => array('file' => 'filevalue'),
- 'env' => array('PATH' => 'daheim'),
- 'session' => array('sezession' => 'kein'),
+ [
+ 'get' => ['name' => 'John Q. Public', 'nickname' => 'Joey'],
+ 'post' => ['name' => 'Jane Doe', 'nickname' => 'Janey'],
+ 'urlParams' => ['name' => 'Johnny Weissmüller'],
+ 'files' => ['file' => 'filevalue'],
+ 'env' => ['PATH' => 'daheim'],
+ 'session' => ['sezession' => 'kein'],
'method' => 'hi',
- )
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$this->app = $this->getMock('OC\AppFramework\DependencyInjection\DIContainer',
diff --git a/tests/lib/appframework/controller/OCSControllerTest.php b/tests/lib/appframework/controller/OCSControllerTest.php
new file mode 100644
index 00000000000..3b4de1d7a05
--- /dev/null
+++ b/tests/lib/appframework/controller/OCSControllerTest.php
@@ -0,0 +1,134 @@
+<?php
+
+/**
+ * ownCloud - App Framework
+ *
+ * @author Bernhard Posselt
+ * @copyright 2015 Bernhard Posselt <dev@bernhard-posselt.com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+
+namespace OCP\AppFramework;
+
+use OC\AppFramework\Http\Request;
+use OCP\AppFramework\Http\DataResponse;
+
+
+class ChildOCSController extends OCSController {}
+
+
+class OCSControllerTest extends \Test\TestCase {
+
+
+ public function testCors() {
+ $request = new Request(
+ array('server' => array('HTTP_ORIGIN' => 'test')),
+ $this->getMock('\OCP\Security\ISecureRandom')
+ );
+ $controller = new ChildOCSController('app', $request, 'verbs',
+ 'headers', 100);
+
+ $response = $controller->preflightedCors();
+
+ $headers = $response->getHeaders();
+
+ $this->assertEquals('test', $headers['Access-Control-Allow-Origin']);
+ $this->assertEquals('verbs', $headers['Access-Control-Allow-Methods']);
+ $this->assertEquals('headers', $headers['Access-Control-Allow-Headers']);
+ $this->assertEquals('false', $headers['Access-Control-Allow-Credentials']);
+ $this->assertEquals(100, $headers['Access-Control-Max-Age']);
+ }
+
+
+ public function testXML() {
+ $controller = new ChildOCSController('app', new Request(
+ [],
+ $this->getMock('\OCP\Security\ISecureRandom')
+ ));
+ $expected = "<?xml version=\"1.0\"?>\n" .
+ "<ocs>\n" .
+ " <meta>\n" .
+ " <status>OK</status>\n" .
+ " <statuscode>400</statuscode>\n" .
+ " <message>OK</message>\n" .
+ " </meta>\n" .
+ " <data>\n" .
+ " <test>hi</test>\n" .
+ " </data>\n" .
+ "</ocs>\n";
+
+ $params = [
+ 'data' => [
+ 'test' => 'hi'
+ ],
+ 'statuscode' => 400
+ ];
+
+ $out = $controller->buildResponse($params, 'xml')->render();
+ $this->assertEquals($expected, $out);
+ }
+
+
+ public function testXMLDataResponse() {
+ $controller = new ChildOCSController('app', new Request(
+ [],
+ $this->getMock('\OCP\Security\ISecureRandom')
+ ));
+ $expected = "<?xml version=\"1.0\"?>\n" .
+ "<ocs>\n" .
+ " <meta>\n" .
+ " <status>OK</status>\n" .
+ " <statuscode>400</statuscode>\n" .
+ " <message>OK</message>\n" .
+ " </meta>\n" .
+ " <data>\n" .
+ " <test>hi</test>\n" .
+ " </data>\n" .
+ "</ocs>\n";
+
+ $params = new DataResponse([
+ 'data' => [
+ 'test' => 'hi'
+ ],
+ 'statuscode' => 400
+ ]);
+
+ $out = $controller->buildResponse($params, 'xml')->render();
+ $this->assertEquals($expected, $out);
+ }
+
+
+ public function testJSON() {
+ $controller = new ChildOCSController('app', new Request(
+ [],
+ $this->getMock('\OCP\Security\ISecureRandom')
+ ));
+ $expected = '{"status":"OK","statuscode":400,"message":"OK",' .
+ '"totalitems":"","itemsperpage":"","data":{"test":"hi"}}';
+ $params = [
+ 'data' => [
+ 'test' => 'hi'
+ ],
+ 'statuscode' => 400
+ ];
+
+ $out = $controller->buildResponse($params, 'json')->render();
+ $this->assertEquals($expected, $out);
+ }
+
+
+}
diff --git a/tests/lib/appframework/dependencyinjection/DIContainerTest.php b/tests/lib/appframework/dependencyinjection/DIContainerTest.php
index 08e72aff984..43309f64e63 100644
--- a/tests/lib/appframework/dependencyinjection/DIContainerTest.php
+++ b/tests/lib/appframework/dependencyinjection/DIContainerTest.php
@@ -71,7 +71,10 @@ class DIContainerTest extends \Test\TestCase {
public function testMiddlewareDispatcherIncludesSecurityMiddleware(){
- $this->container['Request'] = new Request(array('method' => 'GET'));
+ $this->container['Request'] = new Request(
+ ['method' => 'GET'],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$security = $this->container['SecurityMiddleware'];
$dispatcher = $this->container['MiddlewareDispatcher'];
diff --git a/tests/lib/appframework/http/DispatcherTest.php b/tests/lib/appframework/http/DispatcherTest.php
index 3933e00804b..832cd80e60a 100644
--- a/tests/lib/appframework/http/DispatcherTest.php
+++ b/tests/lib/appframework/http/DispatcherTest.php
@@ -276,13 +276,16 @@ class DispatcherTest extends \Test\TestCase {
public function testControllerParametersInjected() {
- $this->request = new Request(array(
- 'post' => array(
+ $this->request = new Request(
+ [
+ 'post' => [
'int' => '3',
'bool' => 'false'
- ),
- 'method' => 'POST'
- ));
+ ],
+ 'method' => 'POST'
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
@@ -298,14 +301,17 @@ class DispatcherTest extends \Test\TestCase {
public function testControllerParametersInjectedDefaultOverwritten() {
- $this->request = new Request(array(
- 'post' => array(
- 'int' => '3',
- 'bool' => 'false',
- 'test2' => 7
- ),
- 'method' => 'POST'
- ));
+ $this->request = new Request(
+ [
+ 'post' => [
+ 'int' => '3',
+ 'bool' => 'false',
+ 'test2' => 7
+ ],
+ 'method' => 'POST',
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
@@ -322,16 +328,19 @@ class DispatcherTest extends \Test\TestCase {
public function testResponseTransformedByUrlFormat() {
- $this->request = new Request(array(
- 'post' => array(
- 'int' => '3',
- 'bool' => 'false'
- ),
- 'urlParams' => array(
- 'format' => 'text'
- ),
- 'method' => 'GET'
- ));
+ $this->request = new Request(
+ [
+ 'post' => [
+ 'int' => '3',
+ 'bool' => 'false'
+ ],
+ 'urlParams' => [
+ 'format' => 'text'
+ ],
+ 'method' => 'GET'
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
@@ -347,16 +356,19 @@ class DispatcherTest extends \Test\TestCase {
public function testResponseTransformsDataResponse() {
- $this->request = new Request(array(
- 'post' => array(
- 'int' => '3',
- 'bool' => 'false'
- ),
- 'urlParams' => array(
- 'format' => 'json'
- ),
- 'method' => 'GET'
- ));
+ $this->request = new Request(
+ [
+ 'post' => [
+ 'int' => '3',
+ 'bool' => 'false'
+ ],
+ 'urlParams' => [
+ 'format' => 'json'
+ ],
+ 'method' => 'GET'
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
@@ -372,17 +384,20 @@ class DispatcherTest extends \Test\TestCase {
public function testResponseTransformedByAcceptHeader() {
- $this->request = new Request(array(
- 'post' => array(
- 'int' => '3',
- 'bool' => 'false'
- ),
- 'server' => array(
- 'HTTP_ACCEPT' => 'application/text, test',
- 'HTTP_CONTENT_TYPE' => 'application/x-www-form-urlencoded'
- ),
- 'method' => 'PUT'
- ));
+ $this->request = new Request(
+ [
+ 'post' => [
+ 'int' => '3',
+ 'bool' => 'false'
+ ],
+ 'server' => [
+ 'HTTP_ACCEPT' => 'application/text, test',
+ 'HTTP_CONTENT_TYPE' => 'application/x-www-form-urlencoded'
+ ],
+ 'method' => 'PUT'
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
@@ -398,19 +413,22 @@ class DispatcherTest extends \Test\TestCase {
public function testResponsePrimarilyTransformedByParameterFormat() {
- $this->request = new Request(array(
- 'post' => array(
- 'int' => '3',
- 'bool' => 'false'
- ),
- 'get' => array(
- 'format' => 'text'
- ),
- 'server' => array(
- 'HTTP_ACCEPT' => 'application/json, test'
- ),
- 'method' => 'POST'
- ));
+ $this->request = new Request(
+ [
+ 'post' => [
+ 'int' => '3',
+ 'bool' => 'false'
+ ],
+ 'get' => [
+ 'format' => 'text'
+ ],
+ 'server' => [
+ 'HTTP_ACCEPT' => 'application/json, test'
+ ],
+ 'method' => 'POST'
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->dispatcher = new Dispatcher(
$this->http, $this->middlewareDispatcher, $this->reflector,
$this->request
diff --git a/tests/lib/appframework/http/OCSResponseTest.php b/tests/lib/appframework/http/OCSResponseTest.php
new file mode 100644
index 00000000000..111dc7ad0a3
--- /dev/null
+++ b/tests/lib/appframework/http/OCSResponseTest.php
@@ -0,0 +1,73 @@
+<?php
+
+/**
+ * ownCloud - App Framework
+ *
+ * @author Bernhard Posselt
+ * @copyright 2015 Bernhard Posselt <dev@bernhard-posselt.com>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE
+ * License as published by the Free Software Foundation; either
+ * version 3 of the License, or any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU AFFERO GENERAL PUBLIC LICENSE for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+
+namespace OC\AppFramework\Http;
+
+
+use OCP\AppFramework\Http\OCSResponse;
+
+
+class OCSResponseTest extends \Test\TestCase {
+
+
+ public function testHeadersJSON() {
+ $response = new OCSResponse('json', 1, 2, 3);
+ $type = $response->getHeaders()['Content-Type'];
+ $this->assertEquals('application/json; charset=utf-8', $type);
+ }
+
+
+ public function testHeadersXML() {
+ $response = new OCSResponse('xml', 1, 2, 3);
+ $type = $response->getHeaders()['Content-Type'];
+ $this->assertEquals('application/xml; charset=utf-8', $type);
+ }
+
+
+ public function testRender() {
+ $response = new OCSResponse(
+ 'xml', 'status', 2, 'message', ['test' => 'hi'], 'tag', 'abc',
+ 'dynamic', 3, 4
+ );
+ $out = $response->render();
+ $expected = "<?xml version=\"1.0\"?>\n" .
+ "<ocs>\n" .
+ " <meta>\n" .
+ " <status>status</status>\n" .
+ " <statuscode>2</statuscode>\n" .
+ " <message>message</message>\n" .
+ " <totalitems>3</totalitems>\n" .
+ " <itemsperpage>4</itemsperpage>\n" .
+ " </meta>\n" .
+ " <data>\n" .
+ " <test>hi</test>\n" .
+ " </data>\n" .
+ "</ocs>\n";
+
+ $this->assertEquals($expected, $out);
+
+ }
+
+
+}
diff --git a/tests/lib/appframework/http/RequestTest.php b/tests/lib/appframework/http/RequestTest.php
index 85db76efe71..eeba64b7f69 100644
--- a/tests/lib/appframework/http/RequestTest.php
+++ b/tests/lib/appframework/http/RequestTest.php
@@ -8,9 +8,13 @@
namespace OC\AppFramework\Http;
-global $data;
+use OCP\Security\ISecureRandom;
class RequestTest extends \Test\TestCase {
+ /** @var string */
+ protected $stream = 'fakeinput://data';
+ /** @var ISecureRandom */
+ protected $secureRandom;
protected function setUp() {
parent::setUp();
@@ -20,7 +24,8 @@ class RequestTest extends \Test\TestCase {
stream_wrapper_unregister('fakeinput');
}
stream_wrapper_register('fakeinput', 'RequestStream');
- $this->stream = 'fakeinput://data';
+
+ $this->secureRandom = $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock();
}
protected function tearDown() {
@@ -34,7 +39,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET',
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
// Countable
$this->assertEquals(2, count($request));
@@ -61,7 +66,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET'
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals(3, count($request));
$this->assertEquals('Janey', $request->{'nickname'});
@@ -78,7 +83,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET'
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$request['nickname'] = 'Janey';
}
@@ -91,7 +96,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET'
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$request->{'nickname'} = 'Janey';
}
@@ -104,7 +109,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET',
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$result = $request->post;
}
@@ -114,7 +119,7 @@ class RequestTest extends \Test\TestCase {
'method' => 'GET',
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('GET', $request->method);
$result = $request->get;
$this->assertEquals('John Q. Public', $result['name']);
@@ -129,7 +134,7 @@ class RequestTest extends \Test\TestCase {
'server' => array('CONTENT_TYPE' => 'application/json; utf-8')
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('POST', $request->method);
$result = $request->post;
$this->assertEquals('John Q. Public', $result['name']);
@@ -147,7 +152,7 @@ class RequestTest extends \Test\TestCase {
'server' => array('CONTENT_TYPE' => 'application/x-www-form-urlencoded'),
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('PATCH', $request->method);
$result = $request->patch;
@@ -166,7 +171,7 @@ class RequestTest extends \Test\TestCase {
'server' => array('CONTENT_TYPE' => 'application/json; utf-8'),
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('PUT', $request->method);
$result = $request->put;
@@ -181,7 +186,7 @@ class RequestTest extends \Test\TestCase {
'server' => array('CONTENT_TYPE' => 'application/json; utf-8'),
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('PATCH', $request->method);
$result = $request->patch;
@@ -200,7 +205,7 @@ class RequestTest extends \Test\TestCase {
'server' => array('CONTENT_TYPE' => 'image/png'),
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$this->assertEquals('PUT', $request->method);
$resource = $request->put;
$contents = stream_get_contents($resource);
@@ -223,7 +228,7 @@ class RequestTest extends \Test\TestCase {
'urlParams' => array('id' => '2'),
);
- $request = new Request($vars, $this->stream);
+ $request = new Request($vars, $this->secureRandom, $this->stream);
$newParams = array('id' => '3', 'test' => 'test2');
$request->setUrlParameters($newParams);
@@ -231,4 +236,39 @@ class RequestTest extends \Test\TestCase {
$this->assertEquals('3', $request->getParam('id'));
$this->assertEquals('3', $request->getParams()['id']);
}
+
+ public function testGetIdWithModUnique() {
+ $vars = [
+ 'server' => [
+ 'UNIQUE_ID' => 'GeneratedUniqueIdByModUnique'
+ ],
+ ];
+
+ $request = new Request($vars, $this->secureRandom, $this->stream);
+ $this->assertSame('GeneratedUniqueIdByModUnique', $request->getId());
+ }
+
+ public function testGetIdWithoutModUnique() {
+ $lowRandomSource = $this->getMockBuilder('\OCP\Security\ISecureRandom')
+ ->disableOriginalConstructor()->getMock();
+ $lowRandomSource->expects($this->once())
+ ->method('generate')
+ ->with('20')
+ ->will($this->returnValue('GeneratedByOwnCloudItself'));
+
+ $this->secureRandom
+ ->expects($this->once())
+ ->method('getLowStrengthGenerator')
+ ->will($this->returnValue($lowRandomSource));
+
+ $request = new Request([], $this->secureRandom, $this->stream);
+ $this->assertSame('GeneratedByOwnCloudItself', $request->getId());
+ }
+
+ public function testGetIdWithoutModUniqueStable() {
+ $request = new Request([], \OC::$server->getSecureRandom(), $this->stream);
+ $firstId = $request->getId();
+ $secondId = $request->getId();
+ $this->assertSame($firstId, $secondId);
+ }
}
diff --git a/tests/lib/appframework/middleware/MiddlewareDispatcherTest.php b/tests/lib/appframework/middleware/MiddlewareDispatcherTest.php
index be8765afd39..078543c7b59 100644
--- a/tests/lib/appframework/middleware/MiddlewareDispatcherTest.php
+++ b/tests/lib/appframework/middleware/MiddlewareDispatcherTest.php
@@ -126,8 +126,16 @@ class MiddlewareDispatcherTest extends \Test\TestCase {
private function getControllerMock(){
- return $this->getMock('OCP\AppFramework\Controller', array('method'),
- array('app', new Request(array('method' => 'GET'))));
+ return $this->getMock(
+ 'OCP\AppFramework\Controller',
+ ['method'],
+ ['app',
+ new Request(
+ ['method' => 'GET'],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ )
+ ]
+ );
}
diff --git a/tests/lib/appframework/middleware/MiddlewareTest.php b/tests/lib/appframework/middleware/MiddlewareTest.php
index b41ec33eb15..fcc0c300a8a 100644
--- a/tests/lib/appframework/middleware/MiddlewareTest.php
+++ b/tests/lib/appframework/middleware/MiddlewareTest.php
@@ -51,8 +51,14 @@ class MiddlewareTest extends \Test\TestCase {
->disableOriginalConstructor()
->getMock();
- $this->controller = $this->getMock('OCP\AppFramework\Controller',
- array(), array($this->api, new Request()));
+ $this->controller = $this->getMock(
+ 'OCP\AppFramework\Controller',
+ [],
+ [
+ $this->api,
+ new Request([], $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock())
+ ]
+ );
$this->exception = new \Exception();
$this->response = $this->getMock('OCP\AppFramework\Http\Response');
}
diff --git a/tests/lib/appframework/middleware/security/CORSMiddlewareTest.php b/tests/lib/appframework/middleware/security/CORSMiddlewareTest.php
index b4bbcce5ad7..57a7c524abe 100644
--- a/tests/lib/appframework/middleware/security/CORSMiddlewareTest.php
+++ b/tests/lib/appframework/middleware/security/CORSMiddlewareTest.php
@@ -32,7 +32,12 @@ class CORSMiddlewareTest extends \Test\TestCase {
*/
public function testSetCORSAPIHeader() {
$request = new Request(
- array('server' => array('HTTP_ORIGIN' => 'test'))
+ [
+ 'server' => [
+ 'HTTP_ORIGIN' => 'test'
+ ]
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$this->reflector->reflect($this, __FUNCTION__);
$middleware = new CORSMiddleware($request, $this->reflector);
@@ -45,7 +50,12 @@ class CORSMiddlewareTest extends \Test\TestCase {
public function testNoAnnotationNoCORSHEADER() {
$request = new Request(
- array('server' => array('HTTP_ORIGIN' => 'test'))
+ [
+ 'server' => [
+ 'HTTP_ORIGIN' => 'test'
+ ]
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$middleware = new CORSMiddleware($request, $this->reflector);
@@ -59,7 +69,7 @@ class CORSMiddlewareTest extends \Test\TestCase {
* @CORS
*/
public function testNoOriginHeaderNoCORSHEADER() {
- $request = new Request();
+ $request = new Request([], $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock());
$this->reflector->reflect($this, __FUNCTION__);
$middleware = new CORSMiddleware($request, $this->reflector);
@@ -75,7 +85,12 @@ class CORSMiddlewareTest extends \Test\TestCase {
*/
public function testCorsIgnoredIfWithCredentialsHeaderPresent() {
$request = new Request(
- array('server' => array('HTTP_ORIGIN' => 'test'))
+ [
+ 'server' => [
+ 'HTTP_ORIGIN' => 'test'
+ ]
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$this->reflector->reflect($this, __FUNCTION__);
$middleware = new CORSMiddleware($request, $this->reflector);
diff --git a/tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php b/tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php
index a8925403a95..3acba7ce1d8 100644
--- a/tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php
+++ b/tests/lib/appframework/middleware/security/SecurityMiddlewareTest.php
@@ -314,10 +314,14 @@ class SecurityMiddlewareTest extends \Test\TestCase {
public function testAfterExceptionReturnsRedirect(){
$this->request = new Request(
- array('server' =>
- array('HTTP_ACCEPT' => 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
- 'REQUEST_URI' => 'owncloud/index.php/apps/specialapp')
- )
+ [
+ 'server' =>
+ [
+ 'HTTP_ACCEPT' => 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
+ 'REQUEST_URI' => 'owncloud/index.php/apps/specialapp'
+ ]
+ ],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
);
$this->middleware = $this->getMiddleware(true, true);
$response = $this->middleware->afterException($this->controller, 'test',
diff --git a/tests/lib/appframework/middleware/sessionmiddlewaretest.php b/tests/lib/appframework/middleware/sessionmiddlewaretest.php
index 344b555ec3c..c417225d908 100644
--- a/tests/lib/appframework/middleware/sessionmiddlewaretest.php
+++ b/tests/lib/appframework/middleware/sessionmiddlewaretest.php
@@ -33,7 +33,10 @@ class SessionMiddlewareTest extends \Test\TestCase {
protected function setUp() {
parent::setUp();
- $this->request = new Request();
+ $this->request = new Request(
+ [],
+ $this->getMockBuilder('\OCP\Security\ISecureRandom')->getMock()
+ );
$this->reflector = new ControllerMethodReflector();
}