diff options
592 files changed, 5028 insertions, 941 deletions
diff --git a/.htaccess b/.htaccess index 115a02495c8..65957a29838 100644 --- a/.htaccess +++ b/.htaccess @@ -1,4 +1,4 @@ -# Version: 8.1.0 +# Version: 8.2.0 <IfModule mod_headers.c> <IfModule mod_fcgid.c> <IfModule mod_setenvif.c> @@ -140,6 +140,7 @@ Georg Ehrke <georg@owncloud.com> Georg Ehrke <developer@georgehrke.com> Georg Ehrke <georg@owncloud.com> Georg Ehrke <georg.stefan.germany@googlemail.com> Georg Ehrke <georg@owncloud.com> Georg Ehrke <ownclouddev@georgswebsite.de> Georg Ehrke <georg@owncloud.com> Georg Ehrke <devgeorg@ownCloud.com> +Georg Ehrke <georg@owncloud.com> Georg Ehrke <georg@ownCloud.com> Golnaz Nilieh <g382nilieh@gmail.com> Grundik <grundik@ololo.cc> Guillaume AMAT <guillaume.amat@informatique-libre.com> diff --git a/.scrutinizer.yml b/.scrutinizer.yml index 9a28c0f03f7..c788343e5d3 100644 --- a/.scrutinizer.yml +++ b/.scrutinizer.yml @@ -21,4 +21,4 @@ imports: tools: external_code_coverage: - timeout: 3600 # Timeout in seconds. 60 minutes + timeout: 7200 # Timeout in seconds. 120 minutes diff --git a/3rdparty b/3rdparty -Subproject a79a7ee86b70db60fee8caa7caaad11be9fd004 +Subproject 2e896dfaa036d60362e314a30b7f55dcc91a109 diff --git a/apps/encryption/appinfo/application.php b/apps/encryption/appinfo/application.php index cb9c33cfe58..d4804394c5f 100644 --- a/apps/encryption/appinfo/application.php +++ b/apps/encryption/appinfo/application.php @@ -2,8 +2,9 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> - * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/appinfo/register_command.php b/apps/encryption/appinfo/register_command.php index 8a9df8ea3eb..f727fdf9d70 100644 --- a/apps/encryption/appinfo/register_command.php +++ b/apps/encryption/appinfo/register_command.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Thomas Müller <deepdiver@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ use OCA\Encryption\Command\MigrateKeys; diff --git a/apps/encryption/appinfo/routes.php b/apps/encryption/appinfo/routes.php index 8fa163d0751..a73cc578437 100644 --- a/apps/encryption/appinfo/routes.php +++ b/apps/encryption/appinfo/routes.php @@ -2,6 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/command/migratekeys.php b/apps/encryption/command/migratekeys.php index b814d697a2c..e6e5e7b70b0 100644 --- a/apps/encryption/command/migratekeys.php +++ b/apps/encryption/command/migratekeys.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Thomas Müller <thomas.mueller@tmit.eu> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Encryption\Command; diff --git a/apps/encryption/controller/recoverycontroller.php b/apps/encryption/controller/recoverycontroller.php index f1a2651443e..a92c49f539f 100644 --- a/apps/encryption/controller/recoverycontroller.php +++ b/apps/encryption/controller/recoverycontroller.php @@ -3,6 +3,8 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/controller/settingscontroller.php b/apps/encryption/controller/settingscontroller.php index 7fa3f469a14..641c97e1d6e 100644 --- a/apps/encryption/controller/settingscontroller.php +++ b/apps/encryption/controller/settingscontroller.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/controller/statuscontroller.php b/apps/encryption/controller/statuscontroller.php index cdc4b2e92e0..f330f726c0b 100644 --- a/apps/encryption/controller/statuscontroller.php +++ b/apps/encryption/controller/statuscontroller.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/hooks/contracts/ihook.php b/apps/encryption/hooks/contracts/ihook.php index d4f20700d78..53217f8ac06 100644 --- a/apps/encryption/hooks/contracts/ihook.php +++ b/apps/encryption/hooks/contracts/ihook.php @@ -1,6 +1,8 @@ <?php /** * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/l10n/et_EE.js b/apps/encryption/l10n/et_EE.js index dfd1cdfcb69..0c33015cdf1 100644 --- a/apps/encryption/l10n/et_EE.js +++ b/apps/encryption/l10n/et_EE.js @@ -8,6 +8,7 @@ OC.L10N.register( "Could not enable recovery key. Please check your recovery key password!" : "Ei suutnud lubada taastevõtit. Palun kontrolli oma taastevõtme parooli!", "Recovery key successfully disabled" : "Taastevõtme keelamine õnnestus", "Could not disable recovery key. Please check your recovery key password!" : "Ei suuda keelata taastevõtit. Palun kontrolli oma taastevõtme parooli!", + "Missing parameters" : "Paramttrid puuduvad", "Please provide the old recovery password" : "Palun sisesta vana taastevõtme parool", "Please provide a new recovery password" : "Palun sisesta uus taastevõtme parool", "Please repeat the new recovery password" : "Palun korda uut taastevõtme parooli", diff --git a/apps/encryption/l10n/et_EE.json b/apps/encryption/l10n/et_EE.json index e5a4bd72482..1f8f74dc7fe 100644 --- a/apps/encryption/l10n/et_EE.json +++ b/apps/encryption/l10n/et_EE.json @@ -6,6 +6,7 @@ "Could not enable recovery key. Please check your recovery key password!" : "Ei suutnud lubada taastevõtit. Palun kontrolli oma taastevõtme parooli!", "Recovery key successfully disabled" : "Taastevõtme keelamine õnnestus", "Could not disable recovery key. Please check your recovery key password!" : "Ei suuda keelata taastevõtit. Palun kontrolli oma taastevõtme parooli!", + "Missing parameters" : "Paramttrid puuduvad", "Please provide the old recovery password" : "Palun sisesta vana taastevõtme parool", "Please provide a new recovery password" : "Palun sisesta uus taastevõtme parool", "Please repeat the new recovery password" : "Palun korda uut taastevõtme parooli", diff --git a/apps/encryption/lib/crypto/crypt.php b/apps/encryption/lib/crypto/crypt.php index 65af3a93d0a..f3cf38fb96c 100644 --- a/apps/encryption/lib/crypto/crypt.php +++ b/apps/encryption/lib/crypto/crypt.php @@ -2,6 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/encryption/lib/crypto/encryption.php b/apps/encryption/lib/crypto/encryption.php index fe1d955524a..1fa0581506b 100644 --- a/apps/encryption/lib/crypto/encryption.php +++ b/apps/encryption/lib/crypto/encryption.php @@ -2,8 +2,11 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> - * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Jan-Christoph Borchardt <hey@jancborchardt.net> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/lib/hookmanager.php b/apps/encryption/lib/hookmanager.php index 4b885cd7f64..0fea1b0f9f2 100644 --- a/apps/encryption/lib/hookmanager.php +++ b/apps/encryption/lib/hookmanager.php @@ -3,6 +3,8 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/lib/migration.php b/apps/encryption/lib/migration.php index 3acf77e4c44..98fc5be777a 100644 --- a/apps/encryption/lib/migration.php +++ b/apps/encryption/lib/migration.php @@ -1,23 +1,22 @@ <?php /** - * ownCloud + * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * - * @copyright (C) 2015 ownCloud, Inc. + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 * - * @author Bjoern Schiessle <schiessle@owncloud.com> + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. * - * 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, + * This program 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. + * 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/>. + * You should have received a copy of the GNU Affero General Public License, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> * */ diff --git a/apps/encryption/lib/recovery.php b/apps/encryption/lib/recovery.php index 61a659e484e..e31a14fba63 100644 --- a/apps/encryption/lib/recovery.php +++ b/apps/encryption/lib/recovery.php @@ -2,6 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/lib/session.php b/apps/encryption/lib/session.php index 9709518a27d..c3759c3fc56 100644 --- a/apps/encryption/lib/session.php +++ b/apps/encryption/lib/session.php @@ -3,6 +3,8 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/lib/users/setup.php b/apps/encryption/lib/users/setup.php index fd8261cc637..f224826ed52 100644 --- a/apps/encryption/lib/users/setup.php +++ b/apps/encryption/lib/users/setup.php @@ -3,6 +3,8 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/lib/util.php b/apps/encryption/lib/util.php index afed96aaa38..fbedc5d6077 100644 --- a/apps/encryption/lib/util.php +++ b/apps/encryption/lib/util.php @@ -2,6 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/controller/RecoveryControllerTest.php b/apps/encryption/tests/controller/RecoveryControllerTest.php index 89b541e7bd6..d122b992ef0 100644 --- a/apps/encryption/tests/controller/RecoveryControllerTest.php +++ b/apps/encryption/tests/controller/RecoveryControllerTest.php @@ -1,9 +1,23 @@ <?php /** - * @author Clark Tomlinson <clark@owncloud.com> + * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ diff --git a/apps/encryption/tests/controller/SettingsControllerTest.php b/apps/encryption/tests/controller/SettingsControllerTest.php index 478bf8213b5..ed8135b9c4d 100644 --- a/apps/encryption/tests/controller/SettingsControllerTest.php +++ b/apps/encryption/tests/controller/SettingsControllerTest.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/hooks/UserHooksTest.php b/apps/encryption/tests/hooks/UserHooksTest.php index b0cc9cc924a..921c924d015 100644 --- a/apps/encryption/tests/hooks/UserHooksTest.php +++ b/apps/encryption/tests/hooks/UserHooksTest.php @@ -1,9 +1,24 @@ <?php /** - * @author Clark Tomlinson <clark@owncloud.com> + * @author Björn Schießle <schiessle@owncloud.com> + * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ diff --git a/apps/encryption/tests/lib/HookManagerTest.php b/apps/encryption/tests/lib/HookManagerTest.php index fb74c05546b..b1d511cb89b 100644 --- a/apps/encryption/tests/lib/HookManagerTest.php +++ b/apps/encryption/tests/lib/HookManagerTest.php @@ -1,6 +1,9 @@ <?php /** * @author Clark Tomlinson <fallen013@gmail.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/lib/KeyManagerTest.php b/apps/encryption/tests/lib/KeyManagerTest.php index eb43d5a843f..2561b29462f 100644 --- a/apps/encryption/tests/lib/KeyManagerTest.php +++ b/apps/encryption/tests/lib/KeyManagerTest.php @@ -2,6 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/encryption/tests/lib/MigrationTest.php b/apps/encryption/tests/lib/MigrationTest.php index c876cea05c9..c07a4539e98 100644 --- a/apps/encryption/tests/lib/MigrationTest.php +++ b/apps/encryption/tests/lib/MigrationTest.php @@ -1,23 +1,23 @@ <?php - /** - * ownCloud +/** + * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * - * @copyright (C) 2015 ownCloud, Inc. + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 * - * @author Bjoern Schiessle <schiessle@owncloud.com> + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. * - * 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, + * This program 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. + * 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/>. + * You should have received a copy of the GNU Affero General Public License, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> * */ diff --git a/apps/encryption/tests/lib/RecoveryTest.php b/apps/encryption/tests/lib/RecoveryTest.php index 0b85192690b..8d5d31af0b8 100644 --- a/apps/encryption/tests/lib/RecoveryTest.php +++ b/apps/encryption/tests/lib/RecoveryTest.php @@ -1,6 +1,10 @@ <?php /** + * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/lib/UtilTest.php b/apps/encryption/tests/lib/UtilTest.php index 18cf0386793..e75e8ea36b4 100644 --- a/apps/encryption/tests/lib/UtilTest.php +++ b/apps/encryption/tests/lib/UtilTest.php @@ -1,6 +1,9 @@ <?php /** + * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/lib/crypto/cryptTest.php b/apps/encryption/tests/lib/crypto/cryptTest.php index f850725108b..14ed1513e1e 100644 --- a/apps/encryption/tests/lib/crypto/cryptTest.php +++ b/apps/encryption/tests/lib/crypto/cryptTest.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/lib/crypto/encryptionTest.php b/apps/encryption/tests/lib/crypto/encryptionTest.php index c6c0d57eff5..7b0b29fe197 100644 --- a/apps/encryption/tests/lib/crypto/encryptionTest.php +++ b/apps/encryption/tests/lib/crypto/encryptionTest.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/encryption/tests/lib/users/SetupTest.php b/apps/encryption/tests/lib/users/SetupTest.php index 354de26253e..e6936c5c12e 100644 --- a/apps/encryption/tests/lib/users/SetupTest.php +++ b/apps/encryption/tests/lib/users/SetupTest.php @@ -1,6 +1,8 @@ <?php /** * @author Clark Tomlinson <fallen013@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files/ajax/delete.php b/apps/files/ajax/delete.php index dcd05d8da9e..2d02869df14 100644 --- a/apps/files/ajax/delete.php +++ b/apps/files/ajax/delete.php @@ -1,13 +1,11 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> - * @author Björn Schießle <schiessle@owncloud.com> * @author Frank Karlitschek <frank@owncloud.org> * @author Jakob Sack <mail@jakobsack.de> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/ajax/getstoragestats.php b/apps/files/ajax/getstoragestats.php index e56e425c1c6..10f8704dded 100644 --- a/apps/files/ajax/getstoragestats.php +++ b/apps/files/ajax/getstoragestats.php @@ -2,7 +2,6 @@ /** * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/ajax/move.php b/apps/files/ajax/move.php index ab02f993f82..0961636a116 100644 --- a/apps/files/ajax/move.php +++ b/apps/files/ajax/move.php @@ -5,7 +5,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/apps/files/ajax/newfile.php b/apps/files/ajax/newfile.php index 6dd3e3e7a80..be09b288d4b 100644 --- a/apps/files/ajax/newfile.php +++ b/apps/files/ajax/newfile.php @@ -4,7 +4,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/ajax/newfolder.php b/apps/files/ajax/newfolder.php index b15457e0173..a2897dd437a 100644 --- a/apps/files/ajax/newfolder.php +++ b/apps/files/ajax/newfolder.php @@ -6,7 +6,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/ajax/rename.php b/apps/files/ajax/rename.php index edb6dd7862d..a24a57b1046 100644 --- a/apps/files/ajax/rename.php +++ b/apps/files/ajax/rename.php @@ -7,6 +7,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files/ajax/upload.php b/apps/files/ajax/upload.php index debdf26ffdf..4bc2ce8bdf3 100644 --- a/apps/files/ajax/upload.php +++ b/apps/files/ajax/upload.php @@ -9,7 +9,6 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Luke Policinski <lpolicinski@gmail.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Roman Geber <rgeber@owncloudapps.com> * @author TheSFReader <TheSFReader@gmail.com> diff --git a/apps/files/appinfo/app.php b/apps/files/appinfo/app.php index c483ad31ec5..40b194ab882 100644 --- a/apps/files/appinfo/app.php +++ b/apps/files/appinfo/app.php @@ -3,7 +3,6 @@ * @author Jakob Sack <mail@jakobsack.de> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/appinfo/remote.php b/apps/files/appinfo/remote.php index 325773a81ea..fff3332ef49 100644 --- a/apps/files/appinfo/remote.php +++ b/apps/files/appinfo/remote.php @@ -50,7 +50,7 @@ $server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, $defaults->getName() // FIXME: The following line is a workaround for legacy components relying on being able to send a GET to / $server->addPlugin(new \OC\Connector\Sabre\DummyGetResponsePlugin()); $server->addPlugin(new \OC\Connector\Sabre\FilesPlugin($objectTree)); -$server->addPlugin(new \OC\Connector\Sabre\MaintenancePlugin()); +$server->addPlugin(new \OC\Connector\Sabre\MaintenancePlugin(\OC::$server->getConfig())); $server->addPlugin(new \OC\Connector\Sabre\ExceptionLoggerPlugin('webdav', \OC::$server->getLogger())); // wait with registering these until auth is handled and the filesystem is setup diff --git a/apps/files/appinfo/routes.php b/apps/files/appinfo/routes.php index 08c9041062d..ceeb3cdcc8a 100644 --- a/apps/files/appinfo/routes.php +++ b/apps/files/appinfo/routes.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tobias Kaminsky <tobias@kaminsky.me> diff --git a/apps/files/download.php b/apps/files/download.php index c85051e0f4e..b0628e394be 100644 --- a/apps/files/download.php +++ b/apps/files/download.php @@ -1,5 +1,6 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Felix Moeller <mail@felixmoeller.de> * @author Frank Karlitschek <frank@owncloud.org> * @author Jakob Sack <mail@jakobsack.de> diff --git a/apps/files/index.php b/apps/files/index.php index ee12df5f075..4f103f975cb 100644 --- a/apps/files/index.php +++ b/apps/files/index.php @@ -8,7 +8,6 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Roman Geber <rgeber@owncloudapps.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files/js/filelist.js b/apps/files/js/filelist.js index 5fc444e6121..417c4b9fe99 100644 --- a/apps/files/js/filelist.js +++ b/apps/files/js/filelist.js @@ -1131,6 +1131,14 @@ return false; } + // Did share service die or something else fail? + if (result.status === 500) { + // Go home + this.changeDirectory('/'); + OC.Notification.show(t('files', 'This directory is unavailable, please check the logs or contact the administrator')); + return false; + } + if (result.status === 404) { // go back home this.changeDirectory('/'); diff --git a/apps/files/l10n/ast.js b/apps/files/l10n/ast.js index 2b2359f9e98..297ebd60484 100644 --- a/apps/files/l10n/ast.js +++ b/apps/files/l10n/ast.js @@ -42,8 +42,12 @@ OC.L10N.register( "Delete" : "Desaniciar", "Disconnect storage" : "Desconeutar almacenamientu", "Unshare" : "Dexar de compartir", + "No permission to delete" : "Ensin permisos pa desaniciar", "Download" : "Descargar", + "Select" : "Esbillar", "Pending" : "Pendiente", + "Unable to determine date" : "Imposible determinar la fecha", + "This operation is forbidden" : "La operación ta prohibida", "Error moving file." : "Fallu moviendo'l ficheru.", "Error moving file" : "Fallu moviendo'l ficheru", "Error" : "Fallu", diff --git a/apps/files/l10n/ast.json b/apps/files/l10n/ast.json index 23f78d08323..b242d62a521 100644 --- a/apps/files/l10n/ast.json +++ b/apps/files/l10n/ast.json @@ -40,8 +40,12 @@ "Delete" : "Desaniciar", "Disconnect storage" : "Desconeutar almacenamientu", "Unshare" : "Dexar de compartir", + "No permission to delete" : "Ensin permisos pa desaniciar", "Download" : "Descargar", + "Select" : "Esbillar", "Pending" : "Pendiente", + "Unable to determine date" : "Imposible determinar la fecha", + "This operation is forbidden" : "La operación ta prohibida", "Error moving file." : "Fallu moviendo'l ficheru.", "Error moving file" : "Fallu moviendo'l ficheru", "Error" : "Fallu", diff --git a/apps/files/l10n/cs_CZ.js b/apps/files/l10n/cs_CZ.js index 9c0d27d9f44..39f0a9e6958 100644 --- a/apps/files/l10n/cs_CZ.js +++ b/apps/files/l10n/cs_CZ.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Vybrat", "Pending" : "Nevyřízené", "Unable to determine date" : "Nelze určit datum", + "This operation is forbidden" : "Tato operace je zakázána", + "This directory is unavailable, please check the logs or contact the administrator" : "Tento adresář není dostupný, zkontrolujte prosím logy nebo kontaktujte svého správce systému", "Error moving file." : "Chyba při přesunu souboru.", "Error moving file" : "Chyba při přesunu souboru", "Error" : "Chyba", @@ -62,7 +64,9 @@ OC.L10N.register( "_Uploading %n file_::_Uploading %n files_" : ["Nahrávám %n soubor","Nahrávám %n soubory","Nahrávám %n souborů"], "\"{name}\" is an invalid file name." : "\"{name}\" je neplatným názvem souboru.", "File name cannot be empty." : "Název souboru nemůže být prázdný řetězec.", + "Storage of {owner} is full, files can not be updated or synced anymore!" : "Úložiště uživatele {owner} je zaplněné, soubory nelze aktualizovat a synchronizovat!", "Your storage is full, files can not be updated or synced anymore!" : "Vaše úložiště je plné, nelze aktualizovat ani synchronizovat soubory.", + "Storage of {owner} is almost full ({usedSpacePercent}%)" : "Úložiště uživatele {owner} je téměř plné ({usedSpacePercent}%)", "Your storage is almost full ({usedSpacePercent}%)" : "Vaše úložiště je téměř plné ({usedSpacePercent}%)", "_matches '{filter}'_::_match '{filter}'_" : ["odpovídá '{filter}'","odpovídá '{filter}'","odpovídá '{filter}'"], "{dirs} and {files}" : "{dirs} a {files}", diff --git a/apps/files/l10n/cs_CZ.json b/apps/files/l10n/cs_CZ.json index 663161c5e42..8742662c1da 100644 --- a/apps/files/l10n/cs_CZ.json +++ b/apps/files/l10n/cs_CZ.json @@ -45,6 +45,8 @@ "Select" : "Vybrat", "Pending" : "Nevyřízené", "Unable to determine date" : "Nelze určit datum", + "This operation is forbidden" : "Tato operace je zakázána", + "This directory is unavailable, please check the logs or contact the administrator" : "Tento adresář není dostupný, zkontrolujte prosím logy nebo kontaktujte svého správce systému", "Error moving file." : "Chyba při přesunu souboru.", "Error moving file" : "Chyba při přesunu souboru", "Error" : "Chyba", @@ -60,7 +62,9 @@ "_Uploading %n file_::_Uploading %n files_" : ["Nahrávám %n soubor","Nahrávám %n soubory","Nahrávám %n souborů"], "\"{name}\" is an invalid file name." : "\"{name}\" je neplatným názvem souboru.", "File name cannot be empty." : "Název souboru nemůže být prázdný řetězec.", + "Storage of {owner} is full, files can not be updated or synced anymore!" : "Úložiště uživatele {owner} je zaplněné, soubory nelze aktualizovat a synchronizovat!", "Your storage is full, files can not be updated or synced anymore!" : "Vaše úložiště je plné, nelze aktualizovat ani synchronizovat soubory.", + "Storage of {owner} is almost full ({usedSpacePercent}%)" : "Úložiště uživatele {owner} je téměř plné ({usedSpacePercent}%)", "Your storage is almost full ({usedSpacePercent}%)" : "Vaše úložiště je téměř plné ({usedSpacePercent}%)", "_matches '{filter}'_::_match '{filter}'_" : ["odpovídá '{filter}'","odpovídá '{filter}'","odpovídá '{filter}'"], "{dirs} and {files}" : "{dirs} a {files}", diff --git a/apps/files/l10n/da.js b/apps/files/l10n/da.js index 8235311a5a7..af8367560d5 100644 --- a/apps/files/l10n/da.js +++ b/apps/files/l10n/da.js @@ -47,6 +47,7 @@ OC.L10N.register( "Select" : "Vælg", "Pending" : "Afventer", "Unable to determine date" : "Kan ikke fastslå datoen", + "This operation is forbidden" : "Denne operation er forbudt", "Error moving file." : "Fejl ved flytning af fil", "Error moving file" : "Fejl ved flytning af fil", "Error" : "Fejl", diff --git a/apps/files/l10n/da.json b/apps/files/l10n/da.json index 449408fa9b1..44c2f7aafe1 100644 --- a/apps/files/l10n/da.json +++ b/apps/files/l10n/da.json @@ -45,6 +45,7 @@ "Select" : "Vælg", "Pending" : "Afventer", "Unable to determine date" : "Kan ikke fastslå datoen", + "This operation is forbidden" : "Denne operation er forbudt", "Error moving file." : "Fejl ved flytning af fil", "Error moving file" : "Fejl ved flytning af fil", "Error" : "Fejl", diff --git a/apps/files/l10n/de.js b/apps/files/l10n/de.js index 203175890fc..00d88d52918 100644 --- a/apps/files/l10n/de.js +++ b/apps/files/l10n/de.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "Ausstehend", "Unable to determine date" : "Datum konnte nicht ermittelt werden", "This operation is forbidden" : "Diese Operation ist nicht erlaubt", + "This directory is unavailable, please check the logs or contact the administrator" : "Dieses Verzeichnis ist nicht verfügbar, bitte überprüfe die Logdateien oder kontaktiere den Administrator", "Error moving file." : "Fehler beim Verschieben der Datei.", "Error moving file" : "Fehler beim Verschieben der Datei", "Error" : "Fehler", diff --git a/apps/files/l10n/de.json b/apps/files/l10n/de.json index 51de8020ae4..7d75fb70ead 100644 --- a/apps/files/l10n/de.json +++ b/apps/files/l10n/de.json @@ -46,6 +46,7 @@ "Pending" : "Ausstehend", "Unable to determine date" : "Datum konnte nicht ermittelt werden", "This operation is forbidden" : "Diese Operation ist nicht erlaubt", + "This directory is unavailable, please check the logs or contact the administrator" : "Dieses Verzeichnis ist nicht verfügbar, bitte überprüfe die Logdateien oder kontaktiere den Administrator", "Error moving file." : "Fehler beim Verschieben der Datei.", "Error moving file" : "Fehler beim Verschieben der Datei", "Error" : "Fehler", diff --git a/apps/files/l10n/de_DE.js b/apps/files/l10n/de_DE.js index 3ab5051e7ef..69699135b8f 100644 --- a/apps/files/l10n/de_DE.js +++ b/apps/files/l10n/de_DE.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "Ausstehend", "Unable to determine date" : "Datum konnte nicht ermittelt werden", "This operation is forbidden" : "Diese Operation ist nicht erlaubt", + "This directory is unavailable, please check the logs or contact the administrator" : "Dieses Verzeichnis ist nicht verfügbar, bitte überprüfen Sie die Logdateien oder kontaktieren Sie den Administrator", "Error moving file." : "Fehler beim Verschieben der Datei.", "Error moving file" : "Fehler beim Verschieben der Datei", "Error" : "Fehler", diff --git a/apps/files/l10n/de_DE.json b/apps/files/l10n/de_DE.json index 5d3c3ad4474..2a1e548ec5f 100644 --- a/apps/files/l10n/de_DE.json +++ b/apps/files/l10n/de_DE.json @@ -46,6 +46,7 @@ "Pending" : "Ausstehend", "Unable to determine date" : "Datum konnte nicht ermittelt werden", "This operation is forbidden" : "Diese Operation ist nicht erlaubt", + "This directory is unavailable, please check the logs or contact the administrator" : "Dieses Verzeichnis ist nicht verfügbar, bitte überprüfen Sie die Logdateien oder kontaktieren Sie den Administrator", "Error moving file." : "Fehler beim Verschieben der Datei.", "Error moving file" : "Fehler beim Verschieben der Datei", "Error" : "Fehler", diff --git a/apps/files/l10n/el.js b/apps/files/l10n/el.js index 10f7326d928..255f70f29e5 100644 --- a/apps/files/l10n/el.js +++ b/apps/files/l10n/el.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Επιλογή", "Pending" : "Εκκρεμεί", "Unable to determine date" : "Αδυναμία προσδιορισμού ημερομηνίας ", + "This operation is forbidden" : "Αυτή η ενέργεια απαγορεύεται", + "This directory is unavailable, please check the logs or contact the administrator" : "Ο κατάλογος δεν είναι διαθέσιμος, παρακαλώ ελέγξτε τα αρχεία καταγραφής ή επικοινωνήστε με το διαχειριστή", "Error moving file." : "Σφάλμα κατά τη μετακίνηση του αρχείου.", "Error moving file" : "Σφάλμα κατά τη μετακίνηση του αρχείου", "Error" : "Σφάλμα", diff --git a/apps/files/l10n/el.json b/apps/files/l10n/el.json index 8f3d92e53cf..2b72213e533 100644 --- a/apps/files/l10n/el.json +++ b/apps/files/l10n/el.json @@ -45,6 +45,8 @@ "Select" : "Επιλογή", "Pending" : "Εκκρεμεί", "Unable to determine date" : "Αδυναμία προσδιορισμού ημερομηνίας ", + "This operation is forbidden" : "Αυτή η ενέργεια απαγορεύεται", + "This directory is unavailable, please check the logs or contact the administrator" : "Ο κατάλογος δεν είναι διαθέσιμος, παρακαλώ ελέγξτε τα αρχεία καταγραφής ή επικοινωνήστε με το διαχειριστή", "Error moving file." : "Σφάλμα κατά τη μετακίνηση του αρχείου.", "Error moving file" : "Σφάλμα κατά τη μετακίνηση του αρχείου", "Error" : "Σφάλμα", diff --git a/apps/files/l10n/es.js b/apps/files/l10n/es.js index cb4e16063dc..281c0bba516 100644 --- a/apps/files/l10n/es.js +++ b/apps/files/l10n/es.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "Pendiente", "Unable to determine date" : "No se pudo determinar la fecha", "This operation is forbidden" : "Esta operación está prohibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Esta carpeta no está disponible, por favor verifique los registros o contáctese con el administrador", "Error moving file." : "Error al mover el archivo.", "Error moving file" : "Error moviendo archivo", "Error" : "Error", diff --git a/apps/files/l10n/es.json b/apps/files/l10n/es.json index a86ebff33db..40f11037293 100644 --- a/apps/files/l10n/es.json +++ b/apps/files/l10n/es.json @@ -46,6 +46,7 @@ "Pending" : "Pendiente", "Unable to determine date" : "No se pudo determinar la fecha", "This operation is forbidden" : "Esta operación está prohibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Esta carpeta no está disponible, por favor verifique los registros o contáctese con el administrador", "Error moving file." : "Error al mover el archivo.", "Error moving file" : "Error moviendo archivo", "Error" : "Error", diff --git a/apps/files/l10n/et_EE.js b/apps/files/l10n/et_EE.js index 7eada9d7875..1bf4a0a5aa3 100644 --- a/apps/files/l10n/et_EE.js +++ b/apps/files/l10n/et_EE.js @@ -42,10 +42,13 @@ OC.L10N.register( "Delete" : "Kustuta", "Disconnect storage" : "Ühenda andmehoidla lahti.", "Unshare" : "Lõpeta jagamine", + "No permission to delete" : "Kustutamiseks pole õigusi", "Download" : "Lae alla", "Select" : "Vali", "Pending" : "Ootel", "Unable to determine date" : "Kuupäeva tuvastamine ei õnnestunud", + "This operation is forbidden" : "See toiming on keelatud", + "This directory is unavailable, please check the logs or contact the administrator" : "See kaust pole saadaval. Palun kontrolli logifaile või võta ühendust administraatoriga", "Error moving file." : "Viga faili liigutamisel.", "Error moving file" : "Viga faili eemaldamisel", "Error" : "Viga", diff --git a/apps/files/l10n/et_EE.json b/apps/files/l10n/et_EE.json index 342c43b5daf..d7b1703dfc5 100644 --- a/apps/files/l10n/et_EE.json +++ b/apps/files/l10n/et_EE.json @@ -40,10 +40,13 @@ "Delete" : "Kustuta", "Disconnect storage" : "Ühenda andmehoidla lahti.", "Unshare" : "Lõpeta jagamine", + "No permission to delete" : "Kustutamiseks pole õigusi", "Download" : "Lae alla", "Select" : "Vali", "Pending" : "Ootel", "Unable to determine date" : "Kuupäeva tuvastamine ei õnnestunud", + "This operation is forbidden" : "See toiming on keelatud", + "This directory is unavailable, please check the logs or contact the administrator" : "See kaust pole saadaval. Palun kontrolli logifaile või võta ühendust administraatoriga", "Error moving file." : "Viga faili liigutamisel.", "Error moving file" : "Viga faili eemaldamisel", "Error" : "Viga", diff --git a/apps/files/l10n/fi_FI.js b/apps/files/l10n/fi_FI.js index 970d4b3c033..abeb0b26b23 100644 --- a/apps/files/l10n/fi_FI.js +++ b/apps/files/l10n/fi_FI.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "Odottaa", "Unable to determine date" : "Päivämäärän määrittäminen epäonnistui", "This operation is forbidden" : "Tämä toiminto on kielletty", + "This directory is unavailable, please check the logs or contact the administrator" : "Hakemisto ei ole käytettävissä. Tarkista lokit tai ole yhteydessä ylläpitoon.", "Error moving file." : "Virhe tiedostoa siirrettäessä.", "Error moving file" : "Virhe tiedostoa siirrettäessä", "Error" : "Virhe", diff --git a/apps/files/l10n/fi_FI.json b/apps/files/l10n/fi_FI.json index e278dc49ef1..f67505268c7 100644 --- a/apps/files/l10n/fi_FI.json +++ b/apps/files/l10n/fi_FI.json @@ -46,6 +46,7 @@ "Pending" : "Odottaa", "Unable to determine date" : "Päivämäärän määrittäminen epäonnistui", "This operation is forbidden" : "Tämä toiminto on kielletty", + "This directory is unavailable, please check the logs or contact the administrator" : "Hakemisto ei ole käytettävissä. Tarkista lokit tai ole yhteydessä ylläpitoon.", "Error moving file." : "Virhe tiedostoa siirrettäessä.", "Error moving file" : "Virhe tiedostoa siirrettäessä", "Error" : "Virhe", diff --git a/apps/files/l10n/fr.js b/apps/files/l10n/fr.js index e334a7a7687..1d57bb79d07 100644 --- a/apps/files/l10n/fr.js +++ b/apps/files/l10n/fr.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "En attente", "Unable to determine date" : "Impossible de déterminer la date", "This operation is forbidden" : "Cette opération est interdite", + "This directory is unavailable, please check the logs or contact the administrator" : "Ce répertoire n'est pas disponible. Consultez les logs ou contactez votre administrateur", "Error moving file." : "Erreur lors du déplacement du fichier.", "Error moving file" : "Erreur lors du déplacement du fichier", "Error" : "Erreur", diff --git a/apps/files/l10n/fr.json b/apps/files/l10n/fr.json index 6523ab1642c..2b578466faa 100644 --- a/apps/files/l10n/fr.json +++ b/apps/files/l10n/fr.json @@ -46,6 +46,7 @@ "Pending" : "En attente", "Unable to determine date" : "Impossible de déterminer la date", "This operation is forbidden" : "Cette opération est interdite", + "This directory is unavailable, please check the logs or contact the administrator" : "Ce répertoire n'est pas disponible. Consultez les logs ou contactez votre administrateur", "Error moving file." : "Erreur lors du déplacement du fichier.", "Error moving file" : "Erreur lors du déplacement du fichier", "Error" : "Erreur", diff --git a/apps/files/l10n/gl.js b/apps/files/l10n/gl.js index 7072472336a..2ab8c9f94ab 100644 --- a/apps/files/l10n/gl.js +++ b/apps/files/l10n/gl.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "Pendentes", "Unable to determine date" : "Non é posíbel determinar a data", "This operation is forbidden" : "Esta operación está prohibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Este directorio non está dispoñíbel, comprobe os rexistros ou póñase en contacto co administrador", "Error moving file." : "Produciuse un erro ao mover o ficheiro.", "Error moving file" : "Produciuse un erro ao mover o ficheiro", "Error" : "Erro", diff --git a/apps/files/l10n/gl.json b/apps/files/l10n/gl.json index be62cd0a2c8..0668c535aee 100644 --- a/apps/files/l10n/gl.json +++ b/apps/files/l10n/gl.json @@ -46,6 +46,7 @@ "Pending" : "Pendentes", "Unable to determine date" : "Non é posíbel determinar a data", "This operation is forbidden" : "Esta operación está prohibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Este directorio non está dispoñíbel, comprobe os rexistros ou póñase en contacto co administrador", "Error moving file." : "Produciuse un erro ao mover o ficheiro.", "Error moving file" : "Produciuse un erro ao mover o ficheiro", "Error" : "Erro", diff --git a/apps/files/l10n/it.js b/apps/files/l10n/it.js index a766d07f1d2..2c57c0e5ac5 100644 --- a/apps/files/l10n/it.js +++ b/apps/files/l10n/it.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Seleziona", "Pending" : "In corso", "Unable to determine date" : "Impossibile determinare la data", + "This operation is forbidden" : "Questa operazione è vietata", + "This directory is unavailable, please check the logs or contact the administrator" : "Questa cartella non è disponibile, controlla i log o contatta l'amministratore", "Error moving file." : "Errore durante lo spostamento del file.", "Error moving file" : "Errore durante lo spostamento del file", "Error" : "Errore", diff --git a/apps/files/l10n/it.json b/apps/files/l10n/it.json index aa9704291d1..4ebb6a360b5 100644 --- a/apps/files/l10n/it.json +++ b/apps/files/l10n/it.json @@ -45,6 +45,8 @@ "Select" : "Seleziona", "Pending" : "In corso", "Unable to determine date" : "Impossibile determinare la data", + "This operation is forbidden" : "Questa operazione è vietata", + "This directory is unavailable, please check the logs or contact the administrator" : "Questa cartella non è disponibile, controlla i log o contatta l'amministratore", "Error moving file." : "Errore durante lo spostamento del file.", "Error moving file" : "Errore durante lo spostamento del file", "Error" : "Errore", diff --git a/apps/files/l10n/ja.js b/apps/files/l10n/ja.js index ffe551e5e1b..6aae198aac6 100644 --- a/apps/files/l10n/ja.js +++ b/apps/files/l10n/ja.js @@ -47,6 +47,7 @@ OC.L10N.register( "Select" : "選択", "Pending" : "中断", "Unable to determine date" : "更新日不明", + "This operation is forbidden" : "この操作は禁止されています", "Error moving file." : "ファイル移動でエラー", "Error moving file" : "ファイルの移動エラー", "Error" : "エラー", diff --git a/apps/files/l10n/ja.json b/apps/files/l10n/ja.json index dfee36655a3..675edbb6974 100644 --- a/apps/files/l10n/ja.json +++ b/apps/files/l10n/ja.json @@ -45,6 +45,7 @@ "Select" : "選択", "Pending" : "中断", "Unable to determine date" : "更新日不明", + "This operation is forbidden" : "この操作は禁止されています", "Error moving file." : "ファイル移動でエラー", "Error moving file" : "ファイルの移動エラー", "Error" : "エラー", diff --git a/apps/files/l10n/nb_NO.js b/apps/files/l10n/nb_NO.js index 3870544e19b..b7741835c0f 100644 --- a/apps/files/l10n/nb_NO.js +++ b/apps/files/l10n/nb_NO.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Velg", "Pending" : "Ventende", "Unable to determine date" : "Kan ikke fastslå datoen", + "This operation is forbidden" : "Operasjonen er forbudt", + "This directory is unavailable, please check the logs or contact the administrator" : "Denne mappen er utilgjengelig. Sjekk loggene eller kontakt administrator", "Error moving file." : "Feil ved flytting av fil.", "Error moving file" : "Feil ved flytting av fil", "Error" : "Feil", diff --git a/apps/files/l10n/nb_NO.json b/apps/files/l10n/nb_NO.json index 28fb382255e..662d8433c21 100644 --- a/apps/files/l10n/nb_NO.json +++ b/apps/files/l10n/nb_NO.json @@ -45,6 +45,8 @@ "Select" : "Velg", "Pending" : "Ventende", "Unable to determine date" : "Kan ikke fastslå datoen", + "This operation is forbidden" : "Operasjonen er forbudt", + "This directory is unavailable, please check the logs or contact the administrator" : "Denne mappen er utilgjengelig. Sjekk loggene eller kontakt administrator", "Error moving file." : "Feil ved flytting av fil.", "Error moving file" : "Feil ved flytting av fil", "Error" : "Feil", diff --git a/apps/files/l10n/nl.js b/apps/files/l10n/nl.js index 1db55ee448b..85bebde9c3e 100644 --- a/apps/files/l10n/nl.js +++ b/apps/files/l10n/nl.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "In behandeling", "Unable to determine date" : "Kon datum niet vaststellen", "This operation is forbidden" : "Deze taak is verboden", + "This directory is unavailable, please check the logs or contact the administrator" : "Deze map is niet beschikbaar. Verifieer de logs of neem contact op met de beheerder", "Error moving file." : "Fout bij verplaatsen bestand.", "Error moving file" : "Fout bij verplaatsen bestand", "Error" : "Fout", diff --git a/apps/files/l10n/nl.json b/apps/files/l10n/nl.json index e88336081e2..9094ed1b031 100644 --- a/apps/files/l10n/nl.json +++ b/apps/files/l10n/nl.json @@ -46,6 +46,7 @@ "Pending" : "In behandeling", "Unable to determine date" : "Kon datum niet vaststellen", "This operation is forbidden" : "Deze taak is verboden", + "This directory is unavailable, please check the logs or contact the administrator" : "Deze map is niet beschikbaar. Verifieer de logs of neem contact op met de beheerder", "Error moving file." : "Fout bij verplaatsen bestand.", "Error moving file" : "Fout bij verplaatsen bestand", "Error" : "Fout", diff --git a/apps/files/l10n/pt_BR.js b/apps/files/l10n/pt_BR.js index f961bfd341d..583123252f9 100644 --- a/apps/files/l10n/pt_BR.js +++ b/apps/files/l10n/pt_BR.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Selecionar", "Pending" : "Pendente", "Unable to determine date" : "Impossível determinar a data", + "This operation is forbidden" : "Esta operação é proibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Este diretório não está disponível, por favor, verifique os logs ou entre em contato com o administrador", "Error moving file." : "Erro movendo o arquivo.", "Error moving file" : "Erro movendo o arquivo", "Error" : "Erro", diff --git a/apps/files/l10n/pt_BR.json b/apps/files/l10n/pt_BR.json index 29cc2ce34c4..31227d66f82 100644 --- a/apps/files/l10n/pt_BR.json +++ b/apps/files/l10n/pt_BR.json @@ -45,6 +45,8 @@ "Select" : "Selecionar", "Pending" : "Pendente", "Unable to determine date" : "Impossível determinar a data", + "This operation is forbidden" : "Esta operação é proibida", + "This directory is unavailable, please check the logs or contact the administrator" : "Este diretório não está disponível, por favor, verifique os logs ou entre em contato com o administrador", "Error moving file." : "Erro movendo o arquivo.", "Error moving file" : "Erro movendo o arquivo", "Error" : "Erro", diff --git a/apps/files/l10n/ru.js b/apps/files/l10n/ru.js index 7ad52c51ee6..a2a7bc69c96 100644 --- a/apps/files/l10n/ru.js +++ b/apps/files/l10n/ru.js @@ -47,6 +47,8 @@ OC.L10N.register( "Select" : "Выбрать", "Pending" : "Ожидание", "Unable to determine date" : "Невозможно определить дату", + "This operation is forbidden" : "Операция запрещена", + "This directory is unavailable, please check the logs or contact the administrator" : "Директория недоступна, пожалуйста проверьте журнал сообщений или свяжитесь с администратором", "Error moving file." : "Ошибка при перемещении файла.", "Error moving file" : "Ошибка при перемещении файла", "Error" : "Ошибка", @@ -77,7 +79,7 @@ OC.L10N.register( "A file or folder has been <strong>deleted</strong>" : "<strong>Удален</strong> файл или каталог", "A file or folder has been <strong>restored</strong>" : "<strong>Восстановлен</strong> файл или каталог", "You created %1$s" : "Вы создали %1$s", - "%2$s created %1$s" : "%2$s создано %1$s", + "%2$s created %1$s" : "%2$s создал %1$s", "%1$s was created in a public folder" : "%1$s создан в общем каталоге", "You changed %1$s" : "Вы изменили %1$s", "%2$s changed %1$s" : "%2$s изменил %1$s", diff --git a/apps/files/l10n/ru.json b/apps/files/l10n/ru.json index 1772b494914..80487e989fb 100644 --- a/apps/files/l10n/ru.json +++ b/apps/files/l10n/ru.json @@ -45,6 +45,8 @@ "Select" : "Выбрать", "Pending" : "Ожидание", "Unable to determine date" : "Невозможно определить дату", + "This operation is forbidden" : "Операция запрещена", + "This directory is unavailable, please check the logs or contact the administrator" : "Директория недоступна, пожалуйста проверьте журнал сообщений или свяжитесь с администратором", "Error moving file." : "Ошибка при перемещении файла.", "Error moving file" : "Ошибка при перемещении файла", "Error" : "Ошибка", @@ -75,7 +77,7 @@ "A file or folder has been <strong>deleted</strong>" : "<strong>Удален</strong> файл или каталог", "A file or folder has been <strong>restored</strong>" : "<strong>Восстановлен</strong> файл или каталог", "You created %1$s" : "Вы создали %1$s", - "%2$s created %1$s" : "%2$s создано %1$s", + "%2$s created %1$s" : "%2$s создал %1$s", "%1$s was created in a public folder" : "%1$s создан в общем каталоге", "You changed %1$s" : "Вы изменили %1$s", "%2$s changed %1$s" : "%2$s изменил %1$s", diff --git a/apps/files/l10n/th_TH.js b/apps/files/l10n/th_TH.js index 522cd0d8aef..40af2bb490d 100644 --- a/apps/files/l10n/th_TH.js +++ b/apps/files/l10n/th_TH.js @@ -48,6 +48,7 @@ OC.L10N.register( "Pending" : "อยู่ระหว่างดำเนินการ", "Unable to determine date" : "ไม่สามารถกำหนดวัน", "This operation is forbidden" : "การดำเนินการนี้ถูกห้าม", + "This directory is unavailable, please check the logs or contact the administrator" : "ไม่สามารถใช้งานไดเรกทอรีนี้โปรดตรวจสอบบันทึกหรือติดต่อผู้ดูแลระบบ", "Error moving file." : "ข้อผิดพลาดในการเคลื่อนย้ายไฟล์", "Error moving file" : "ข้อผิดพลาดในการเคลื่อนย้ายไฟล์", "Error" : "ข้อผิดพลาด", diff --git a/apps/files/l10n/th_TH.json b/apps/files/l10n/th_TH.json index 04fe8835d23..a6febf6fadf 100644 --- a/apps/files/l10n/th_TH.json +++ b/apps/files/l10n/th_TH.json @@ -46,6 +46,7 @@ "Pending" : "อยู่ระหว่างดำเนินการ", "Unable to determine date" : "ไม่สามารถกำหนดวัน", "This operation is forbidden" : "การดำเนินการนี้ถูกห้าม", + "This directory is unavailable, please check the logs or contact the administrator" : "ไม่สามารถใช้งานไดเรกทอรีนี้โปรดตรวจสอบบันทึกหรือติดต่อผู้ดูแลระบบ", "Error moving file." : "ข้อผิดพลาดในการเคลื่อนย้ายไฟล์", "Error moving file" : "ข้อผิดพลาดในการเคลื่อนย้ายไฟล์", "Error" : "ข้อผิดพลาด", diff --git a/apps/files/l10n/uk.js b/apps/files/l10n/uk.js index cf006f9c0d6..167897b57e5 100644 --- a/apps/files/l10n/uk.js +++ b/apps/files/l10n/uk.js @@ -47,6 +47,7 @@ OC.L10N.register( "Select" : "Оберіть", "Pending" : "Очікування", "Unable to determine date" : "Неможливо визначити дату", + "This operation is forbidden" : "Ця операція заборонена", "Error moving file." : "Помилка переміщення файлу.", "Error moving file" : "Помилка переміщення файлу", "Error" : "Помилка", diff --git a/apps/files/l10n/uk.json b/apps/files/l10n/uk.json index 1a313865f7a..803d9887627 100644 --- a/apps/files/l10n/uk.json +++ b/apps/files/l10n/uk.json @@ -45,6 +45,7 @@ "Select" : "Оберіть", "Pending" : "Очікування", "Unable to determine date" : "Неможливо визначити дату", + "This operation is forbidden" : "Ця операція заборонена", "Error moving file." : "Помилка переміщення файлу.", "Error moving file" : "Помилка переміщення файлу", "Error" : "Помилка", diff --git a/apps/files/l10n/zh_CN.js b/apps/files/l10n/zh_CN.js index 66b638df86f..76cbe4110a8 100644 --- a/apps/files/l10n/zh_CN.js +++ b/apps/files/l10n/zh_CN.js @@ -42,15 +42,19 @@ OC.L10N.register( "Delete" : "删除", "Disconnect storage" : "断开储存连接", "Unshare" : "取消共享", + "No permission to delete" : "无权删除", "Download" : "下载", "Select" : "选择", "Pending" : "等待", "Unable to determine date" : "无法确定日期", + "This operation is forbidden" : "操作被禁止", + "This directory is unavailable, please check the logs or contact the administrator" : "此目录不可用,请检查日志或联系管理员", "Error moving file." : "移动文件出错。", "Error moving file" : "移动文件错误", "Error" : "错误", "Could not rename file" : "不能重命名文件", "Error deleting file." : "删除文件出错。", + "No entries in this folder match '{filter}'" : "此文件夹中无项目匹配“{filter}”", "Name" : "名称", "Size" : "大小", "Modified" : "修改日期", @@ -60,13 +64,18 @@ OC.L10N.register( "_Uploading %n file_::_Uploading %n files_" : ["上传 %n 个文件"], "\"{name}\" is an invalid file name." : "“{name}”是一个无效的文件名。", "File name cannot be empty." : "文件名不能为空。", + "Storage of {owner} is full, files can not be updated or synced anymore!" : "{owner} 的存储空间已满,文件将无法更新或同步!", "Your storage is full, files can not be updated or synced anymore!" : "您的存储空间已满,文件将无法更新或同步!", + "Storage of {owner} is almost full ({usedSpacePercent}%)" : "{owner} 的存储空间即将用完 ({usedSpacePercent}%)", "Your storage is almost full ({usedSpacePercent}%)" : "您的存储空间即将用完 ({usedSpacePercent}%)", + "_matches '{filter}'_::_match '{filter}'_" : ["匹配“{filter}”"], "{dirs} and {files}" : "{dirs} 和 {files}", "Favorited" : "已收藏", "Favorite" : "收藏", + "An error occurred while trying to update the tags" : "更新标签时出错", "A new file or folder has been <strong>created</strong>" : "一个新的文件或文件夹已被<strong>创建</strong>", "A file or folder has been <strong>changed</strong>" : "一个文件或文件夹已被<strong>修改</strong>", + "Limit notifications about creation and changes to your <strong>favorite files</strong> <em>(Stream only)</em>" : "针对<strong>已收藏文件</strong>的新建和修改发送有限的通知 <em>(仅流)</em>", "A file or folder has been <strong>deleted</strong>" : "一个文件或文件夹已被<strong>删除</strong>", "A file or folder has been <strong>restored</strong>" : "一个文件或文件夹已经被 <strong>恢复</strong>", "You created %1$s" : "您创建了%1$s", @@ -85,6 +94,7 @@ OC.L10N.register( "Maximum upload size" : "最大上传大小", "max. possible: " : "最大允许: ", "Save" : "保存", + "Can not be edited from here due to insufficient permissions." : "由于权限不足无法在此编辑。", "Settings" : "设置", "WebDAV" : "WebDAV", "Use this address to <a href=\"%s\" target=\"_blank\">access your Files via WebDAV</a>" : "使用这个地址 <a href=\"%s\" target=\"_blank\">通过 WebDAV 访问您的文件</a>", @@ -95,7 +105,9 @@ OC.L10N.register( "Folder" : "文件夹", "Upload" : "上传", "Cancel upload" : "取消上传", + "No files in here" : "无文件", "Upload some content or sync with your devices!" : "上传一些内容或者与设备同步!", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Upload too large" : "上传文件过大", "The files you are trying to upload exceed the maximum size for file uploads on this server." : "您正尝试上传的文件超过了此服务器可以上传的最大容量限制", diff --git a/apps/files/l10n/zh_CN.json b/apps/files/l10n/zh_CN.json index eb27d81060d..44e763a42fd 100644 --- a/apps/files/l10n/zh_CN.json +++ b/apps/files/l10n/zh_CN.json @@ -40,15 +40,19 @@ "Delete" : "删除", "Disconnect storage" : "断开储存连接", "Unshare" : "取消共享", + "No permission to delete" : "无权删除", "Download" : "下载", "Select" : "选择", "Pending" : "等待", "Unable to determine date" : "无法确定日期", + "This operation is forbidden" : "操作被禁止", + "This directory is unavailable, please check the logs or contact the administrator" : "此目录不可用,请检查日志或联系管理员", "Error moving file." : "移动文件出错。", "Error moving file" : "移动文件错误", "Error" : "错误", "Could not rename file" : "不能重命名文件", "Error deleting file." : "删除文件出错。", + "No entries in this folder match '{filter}'" : "此文件夹中无项目匹配“{filter}”", "Name" : "名称", "Size" : "大小", "Modified" : "修改日期", @@ -58,13 +62,18 @@ "_Uploading %n file_::_Uploading %n files_" : ["上传 %n 个文件"], "\"{name}\" is an invalid file name." : "“{name}”是一个无效的文件名。", "File name cannot be empty." : "文件名不能为空。", + "Storage of {owner} is full, files can not be updated or synced anymore!" : "{owner} 的存储空间已满,文件将无法更新或同步!", "Your storage is full, files can not be updated or synced anymore!" : "您的存储空间已满,文件将无法更新或同步!", + "Storage of {owner} is almost full ({usedSpacePercent}%)" : "{owner} 的存储空间即将用完 ({usedSpacePercent}%)", "Your storage is almost full ({usedSpacePercent}%)" : "您的存储空间即将用完 ({usedSpacePercent}%)", + "_matches '{filter}'_::_match '{filter}'_" : ["匹配“{filter}”"], "{dirs} and {files}" : "{dirs} 和 {files}", "Favorited" : "已收藏", "Favorite" : "收藏", + "An error occurred while trying to update the tags" : "更新标签时出错", "A new file or folder has been <strong>created</strong>" : "一个新的文件或文件夹已被<strong>创建</strong>", "A file or folder has been <strong>changed</strong>" : "一个文件或文件夹已被<strong>修改</strong>", + "Limit notifications about creation and changes to your <strong>favorite files</strong> <em>(Stream only)</em>" : "针对<strong>已收藏文件</strong>的新建和修改发送有限的通知 <em>(仅流)</em>", "A file or folder has been <strong>deleted</strong>" : "一个文件或文件夹已被<strong>删除</strong>", "A file or folder has been <strong>restored</strong>" : "一个文件或文件夹已经被 <strong>恢复</strong>", "You created %1$s" : "您创建了%1$s", @@ -83,6 +92,7 @@ "Maximum upload size" : "最大上传大小", "max. possible: " : "最大允许: ", "Save" : "保存", + "Can not be edited from here due to insufficient permissions." : "由于权限不足无法在此编辑。", "Settings" : "设置", "WebDAV" : "WebDAV", "Use this address to <a href=\"%s\" target=\"_blank\">access your Files via WebDAV</a>" : "使用这个地址 <a href=\"%s\" target=\"_blank\">通过 WebDAV 访问您的文件</a>", @@ -93,7 +103,9 @@ "Folder" : "文件夹", "Upload" : "上传", "Cancel upload" : "取消上传", + "No files in here" : "无文件", "Upload some content or sync with your devices!" : "上传一些内容或者与设备同步!", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Upload too large" : "上传文件过大", "The files you are trying to upload exceed the maximum size for file uploads on this server." : "您正尝试上传的文件超过了此服务器可以上传的最大容量限制", diff --git a/apps/files/tests/activitytest.php b/apps/files/tests/activitytest.php index 1f8d6330e51..4ab8ad11eae 100644 --- a/apps/files/tests/activitytest.php +++ b/apps/files/tests/activitytest.php @@ -1,11 +1,24 @@ <?php /** - * Copyright (c) 2015 Joas Schilling <nickvergessen@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * -*/ + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ namespace OCA\Files\Tests; diff --git a/apps/files/tests/controller/apicontrollertest.php b/apps/files/tests/controller/apicontrollertest.php index 0ec38e0e2e7..35d00af75ba 100644 --- a/apps/files/tests/controller/apicontrollertest.php +++ b/apps/files/tests/controller/apicontrollertest.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Roeland Jago Douma <roeland@famdouma.nl> diff --git a/apps/files/tests/js/filelistSpec.js b/apps/files/tests/js/filelistSpec.js index 6bcef8b6f4f..b12ac2f2517 100644 --- a/apps/files/tests/js/filelistSpec.js +++ b/apps/files/tests/js/filelistSpec.js @@ -1290,6 +1290,17 @@ describe('OCA.Files.FileList tests', function() { fakeServer.respond(); expect(fileList.getCurrentDirectory()).toEqual('/'); }); + it('switches to root dir when current directory is unavailable', function() { + fakeServer.respondWith(/\/index\.php\/apps\/files\/ajax\/list.php\?dir=%2funexist/, [ + 500, { + "Content-Type": "application/json" + }, + '' + ]); + fileList.changeDirectory('/unexist'); + fakeServer.respond(); + expect(fileList.getCurrentDirectory()).toEqual('/'); + }); it('shows mask before loading file list then hides it at the end', function() { var showMaskStub = sinon.stub(fileList, 'showMask'); var hideMaskStub = sinon.stub(fileList, 'hideMask'); diff --git a/apps/files/tests/service/tagservice.php b/apps/files/tests/service/tagservice.php index 2b5d1e5ec34..147e698aaaa 100644 --- a/apps/files/tests/service/tagservice.php +++ b/apps/files/tests/service/tagservice.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/ajax/applicable.php b/apps/files_external/ajax/applicable.php index b41f2e0c0df..1b93cc3a1aa 100644 --- a/apps/files_external/ajax/applicable.php +++ b/apps/files_external/ajax/applicable.php @@ -2,7 +2,6 @@ /** * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_external/ajax/dropbox.php b/apps/files_external/ajax/dropbox.php index 495387b45bb..55dc417b73a 100644 --- a/apps/files_external/ajax/dropbox.php +++ b/apps/files_external/ajax/dropbox.php @@ -3,7 +3,6 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Volkan Gezer <volkangezer@gmail.com> diff --git a/apps/files_external/appinfo/app.php b/apps/files_external/appinfo/app.php index cc64e298b96..66897eba3d3 100644 --- a/apps/files_external/appinfo/app.php +++ b/apps/files_external/appinfo/app.php @@ -6,7 +6,6 @@ * @author j-ed <juergen@eisfair.org> * @author Martin Mattel <martin.mattel@diemattels.at> * @author Michael Gapczynski <GapczynskiM@gmail.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Philipp Kapfer <philipp.kapfer@gmx.at> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> diff --git a/apps/files_external/appinfo/routes.php b/apps/files_external/appinfo/routes.php index 8c6dff7a901..97eb1353b1e 100644 --- a/apps/files_external/appinfo/routes.php +++ b/apps/files_external/appinfo/routes.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Ross Nicoll <jrn@jrn.me.uk> diff --git a/apps/files_external/l10n/cs_CZ.js b/apps/files_external/l10n/cs_CZ.js index f2e86b5748c..4698dd915ac 100644 --- a/apps/files_external/l10n/cs_CZ.js +++ b/apps/files_external/l10n/cs_CZ.js @@ -55,6 +55,11 @@ OC.L10N.register( "Personal" : "Osobní", "System" : "Systém", "Enable encryption" : "Povolit šifrování", + "Enable previews" : "Povolit náhledy", + "Check for changes" : "Zkontrolovat změny", + "Never" : "Nikdy", + "Once every direct access" : "Jednou pro každý přímý přístup", + "Every time the filesystem is used" : "Pokaždé když je použit souborový systém", "All users. Type to select user or group." : "Všichni uživatelé. Začněte psát pro výběr uživatelů a skupin.", "(group)" : "(skupina)", "Saved" : "Uloženo", diff --git a/apps/files_external/l10n/cs_CZ.json b/apps/files_external/l10n/cs_CZ.json index b96a2e52274..53b2162dafe 100644 --- a/apps/files_external/l10n/cs_CZ.json +++ b/apps/files_external/l10n/cs_CZ.json @@ -53,6 +53,11 @@ "Personal" : "Osobní", "System" : "Systém", "Enable encryption" : "Povolit šifrování", + "Enable previews" : "Povolit náhledy", + "Check for changes" : "Zkontrolovat změny", + "Never" : "Nikdy", + "Once every direct access" : "Jednou pro každý přímý přístup", + "Every time the filesystem is used" : "Pokaždé když je použit souborový systém", "All users. Type to select user or group." : "Všichni uživatelé. Začněte psát pro výběr uživatelů a skupin.", "(group)" : "(skupina)", "Saved" : "Uloženo", diff --git a/apps/files_external/l10n/et_EE.js b/apps/files_external/l10n/et_EE.js index 07bdfa7cdd3..bc43609aca2 100644 --- a/apps/files_external/l10n/et_EE.js +++ b/apps/files_external/l10n/et_EE.js @@ -43,19 +43,35 @@ OC.L10N.register( "Username as share" : "Kasutajanimi kui jagamine", "URL" : "URL", "Secure https://" : "Turvaline https://", + "SFTP with secret key login" : "SFTP koos salajase võtmega logimisega", + "Public key" : "Avalik võti", + "Storage with id \"%i\" not found" : "Salvestuskohta ID-ga \"%i\" ei leitud", + "Invalid mount point" : "Vigane ühenduspunkt", + "Invalid storage backend \"%s\"" : "Vigane salvestuskoha taustsüsteem \"%s\"", "Access granted" : "Ligipääs on antud", "Error configuring Dropbox storage" : "Viga Dropboxi salvestusruumi seadistamisel", "Grant access" : "Anna ligipääs", "Error configuring Google Drive storage" : "Viga Google Drive'i salvestusruumi seadistamisel", "Personal" : "Isiklik", "System" : "Süsteem", + "Enable encryption" : "Luba krüpteerimine", + "Enable previews" : "Luba eelvaated", + "Check for changes" : "Otsi uuendusi", + "Never" : "Mitte kunagi", + "Once every direct access" : "Kord iga otsese pöördumise korral", + "Every time the filesystem is used" : "Iga kord, kui failisüsteemi kasutatakse", "All users. Type to select user or group." : "Kõik kasutajad. Kirjuta, et valida kasutaja või grupp.", "(group)" : "(grupp)", "Saved" : "Salvestatud", + "Generate keys" : "Loo võtmed", + "Error generating key pair" : "Viga võtmepaari loomisel", "<b>Note:</b> " : "<b>Märkus:</b>", + "and" : "ja", "<b>Note:</b> The cURL support in PHP is not enabled or installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> cURL tugi puudub PHP paigalduses. FTP %s hoidla ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata cURL tugi.", "<b>Note:</b> The FTP support in PHP is not enabled or installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> FTP tugi puudub PHP paigalduses. FTP %s hoidla ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata FTP tugi.", "<b>Note:</b> \"%s\" is not installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> \"%s\" pole paigaldatud. Hoidla %s ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata vajalik tugi.", + "No external storage configured" : "Välist salvestuskohta pole seadistatud", + "You can add external storages in the personal settings" : "Sa võid lisada välise salvestuskoha isiklikes seadetes", "Name" : "Nimi", "Storage type" : "Andmehoidla tüüp", "Scope" : "Skoop", @@ -64,6 +80,7 @@ OC.L10N.register( "Configuration" : "Seadistamine", "Available for" : "Saadaval", "Add storage" : "Lisa andmehoidla", + "Advanced settings" : "Lisavalikud", "Delete" : "Kustuta", "Enable User External Storage" : "Luba kasutajatele väline salvestamine", "Allow users to mount the following external storage" : "Võimalda kasutajatel ühendada järgmist välist andmehoidlat" diff --git a/apps/files_external/l10n/et_EE.json b/apps/files_external/l10n/et_EE.json index 11592f9e9a7..4870b55afb3 100644 --- a/apps/files_external/l10n/et_EE.json +++ b/apps/files_external/l10n/et_EE.json @@ -41,19 +41,35 @@ "Username as share" : "Kasutajanimi kui jagamine", "URL" : "URL", "Secure https://" : "Turvaline https://", + "SFTP with secret key login" : "SFTP koos salajase võtmega logimisega", + "Public key" : "Avalik võti", + "Storage with id \"%i\" not found" : "Salvestuskohta ID-ga \"%i\" ei leitud", + "Invalid mount point" : "Vigane ühenduspunkt", + "Invalid storage backend \"%s\"" : "Vigane salvestuskoha taustsüsteem \"%s\"", "Access granted" : "Ligipääs on antud", "Error configuring Dropbox storage" : "Viga Dropboxi salvestusruumi seadistamisel", "Grant access" : "Anna ligipääs", "Error configuring Google Drive storage" : "Viga Google Drive'i salvestusruumi seadistamisel", "Personal" : "Isiklik", "System" : "Süsteem", + "Enable encryption" : "Luba krüpteerimine", + "Enable previews" : "Luba eelvaated", + "Check for changes" : "Otsi uuendusi", + "Never" : "Mitte kunagi", + "Once every direct access" : "Kord iga otsese pöördumise korral", + "Every time the filesystem is used" : "Iga kord, kui failisüsteemi kasutatakse", "All users. Type to select user or group." : "Kõik kasutajad. Kirjuta, et valida kasutaja või grupp.", "(group)" : "(grupp)", "Saved" : "Salvestatud", + "Generate keys" : "Loo võtmed", + "Error generating key pair" : "Viga võtmepaari loomisel", "<b>Note:</b> " : "<b>Märkus:</b>", + "and" : "ja", "<b>Note:</b> The cURL support in PHP is not enabled or installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> cURL tugi puudub PHP paigalduses. FTP %s hoidla ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata cURL tugi.", "<b>Note:</b> The FTP support in PHP is not enabled or installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> FTP tugi puudub PHP paigalduses. FTP %s hoidla ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata FTP tugi.", "<b>Note:</b> \"%s\" is not installed. Mounting of %s is not possible. Please ask your system administrator to install it." : "<b>Märkus:</b> \"%s\" pole paigaldatud. Hoidla %s ühendamine pole võimalik. Palu oma süsteemihalduril paigaldata vajalik tugi.", + "No external storage configured" : "Välist salvestuskohta pole seadistatud", + "You can add external storages in the personal settings" : "Sa võid lisada välise salvestuskoha isiklikes seadetes", "Name" : "Nimi", "Storage type" : "Andmehoidla tüüp", "Scope" : "Skoop", @@ -62,6 +78,7 @@ "Configuration" : "Seadistamine", "Available for" : "Saadaval", "Add storage" : "Lisa andmehoidla", + "Advanced settings" : "Lisavalikud", "Delete" : "Kustuta", "Enable User External Storage" : "Luba kasutajatele väline salvestamine", "Allow users to mount the following external storage" : "Võimalda kasutajatel ühendada järgmist välist andmehoidlat" diff --git a/apps/files_external/l10n/ja.js b/apps/files_external/l10n/ja.js index 7abf8067b6d..9181fbb4e3a 100644 --- a/apps/files_external/l10n/ja.js +++ b/apps/files_external/l10n/ja.js @@ -54,6 +54,7 @@ OC.L10N.register( "Personal" : "個人", "System" : "システム", "Enable encryption" : "暗号化を有効に", + "Check for changes" : "変更点を確認", "All users. Type to select user or group." : "すべてのユーザー。ユーザー、グループを追加", "(group)" : "(グループ)", "Saved" : "保存されました", diff --git a/apps/files_external/l10n/ja.json b/apps/files_external/l10n/ja.json index 6da6fe15b12..19a986bfb99 100644 --- a/apps/files_external/l10n/ja.json +++ b/apps/files_external/l10n/ja.json @@ -52,6 +52,7 @@ "Personal" : "個人", "System" : "システム", "Enable encryption" : "暗号化を有効に", + "Check for changes" : "変更点を確認", "All users. Type to select user or group." : "すべてのユーザー。ユーザー、グループを追加", "(group)" : "(グループ)", "Saved" : "保存されました", diff --git a/apps/files_external/l10n/zh_CN.js b/apps/files_external/l10n/zh_CN.js index 1045c03423f..0b2731fd911 100644 --- a/apps/files_external/l10n/zh_CN.js +++ b/apps/files_external/l10n/zh_CN.js @@ -31,6 +31,7 @@ OC.L10N.register( "Error configuring Google Drive storage" : "配置Google Drive存储时出错", "Personal" : "个人", "System" : "系统", + "Enable encryption" : "启用加密", "Saved" : "已保存", "<b>Note:</b> " : "<b>注意:</b>", "Name" : "名称", diff --git a/apps/files_external/l10n/zh_CN.json b/apps/files_external/l10n/zh_CN.json index b6a826e4209..6d842332264 100644 --- a/apps/files_external/l10n/zh_CN.json +++ b/apps/files_external/l10n/zh_CN.json @@ -29,6 +29,7 @@ "Error configuring Google Drive storage" : "配置Google Drive存储时出错", "Personal" : "个人", "System" : "系统", + "Enable encryption" : "启用加密", "Saved" : "已保存", "<b>Note:</b> " : "<b>注意:</b>", "Name" : "名称", diff --git a/apps/files_external/lib/config.php b/apps/files_external/lib/config.php index 40e9a75790f..5dc6d06ae06 100644 --- a/apps/files_external/lib/config.php +++ b/apps/files_external/lib/config.php @@ -124,10 +124,10 @@ class OC_Mount_Config { self::addStorageIdToConfig($data['user']); $user = \OC::$server->getUserManager()->get($data['user']); if (!$user) { - \OC_Log::write( + \OCP\Util::writeLog( 'files_external', 'Cannot init external mount points for non-existant user "' . $data['user'] . '".', - \OC_Log::WARN + \OCP\Util::WARN ); return; } diff --git a/apps/files_external/lib/google.php b/apps/files_external/lib/google.php index 541113fb530..8199d97eacb 100644 --- a/apps/files_external/lib/google.php +++ b/apps/files_external/lib/google.php @@ -5,6 +5,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Christopher Schäpers <kondou@ts.unde.re> * @author Jörn Friedrich Dreyer <jfd@butonic.de> + * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Philipp Kapfer <philipp.kapfer@gmx.at> diff --git a/apps/files_external/lib/sftp_key.php b/apps/files_external/lib/sftp_key.php index d9bcadb9eb7..1bcea6bc96d 100644 --- a/apps/files_external/lib/sftp_key.php +++ b/apps/files_external/lib/sftp_key.php @@ -1,5 +1,6 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Ross Nicoll <jrn@jrn.me.uk> * diff --git a/apps/files_external/lib/smb_oc.php b/apps/files_external/lib/smb_oc.php index 9fd3aa3721f..52b73c46ff9 100644 --- a/apps/files_external/lib/smb_oc.php +++ b/apps/files_external/lib/smb_oc.php @@ -1,6 +1,5 @@ <?php /** - * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/apps/files_external/list.php b/apps/files_external/list.php index c97c0d8f653..b98db79de89 100644 --- a/apps/files_external/list.php +++ b/apps/files_external/list.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/personal.php b/apps/files_external/personal.php index b2ab32411f9..1ac0f65a1f0 100644 --- a/apps/files_external/personal.php +++ b/apps/files_external/personal.php @@ -4,6 +4,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/service/globalstoragesservice.php b/apps/files_external/service/globalstoragesservice.php index 7df0f73f652..04445127b34 100644 --- a/apps/files_external/service/globalstoragesservice.php +++ b/apps/files_external/service/globalstoragesservice.php @@ -1,5 +1,7 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/service/storagesservice.php b/apps/files_external/service/storagesservice.php index 51eb4abcc00..930f994455e 100644 --- a/apps/files_external/service/storagesservice.php +++ b/apps/files_external/service/storagesservice.php @@ -1,5 +1,7 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/settings.php b/apps/files_external/settings.php index daf205d3d57..6db68713d98 100644 --- a/apps/files_external/settings.php +++ b/apps/files_external/settings.php @@ -6,6 +6,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_external/tests/backends/sftp.php b/apps/files_external/tests/backends/sftp.php index 29461c3abcc..da2c0ac6ba2 100644 --- a/apps/files_external/tests/backends/sftp.php +++ b/apps/files_external/tests/backends/sftp.php @@ -4,6 +4,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_external/tests/config.php b/apps/files_external/tests/config.php index 9907353588e..19dad215a36 100644 --- a/apps/files_external/tests/config.php +++ b/apps/files_external/tests/config.php @@ -3,7 +3,6 @@ * @author Christian Berendt <berendt@b1-systems.de> * @author hkjolhede <hkjolhede@gmail.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Ross Nicoll <jrn@jrn.me.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/apps/files_sharing/ajax/list.php b/apps/files_sharing/ajax/list.php index 354041fed9d..d09b61fd4ae 100644 --- a/apps/files_sharing/ajax/list.php +++ b/apps/files_sharing/ajax/list.php @@ -27,7 +27,7 @@ OCP\JSON::checkAppEnabled('files_sharing'); if(!isset($_GET['t'])){ \OC_Response::setStatus(\OC_Response::STATUS_BAD_REQUEST); - \OC_Log::write('core-preview', 'No token parameter was passed', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'No token parameter was passed', \OCP\Util::DEBUG); exit; } diff --git a/apps/files_sharing/ajax/publicpreview.php b/apps/files_sharing/ajax/publicpreview.php index 0734c8c1159..99a5bdaa859 100644 --- a/apps/files_sharing/ajax/publicpreview.php +++ b/apps/files_sharing/ajax/publicpreview.php @@ -36,20 +36,20 @@ $keepAspect = array_key_exists('a', $_GET) ? true : false; if($token === ''){ \OC_Response::setStatus(\OC_Response::STATUS_BAD_REQUEST); - \OC_Log::write('core-preview', 'No token parameter was passed', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'No token parameter was passed', \OCP\Util::DEBUG); exit; } $linkedItem = \OCP\Share::getShareByToken($token); if($linkedItem === false || ($linkedItem['item_type'] !== 'file' && $linkedItem['item_type'] !== 'folder')) { \OC_Response::setStatus(\OC_Response::STATUS_NOT_FOUND); - \OC_Log::write('core-preview', 'Passed token parameter is not valid', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'Passed token parameter is not valid', \OCP\Util::DEBUG); exit; } if(!isset($linkedItem['uid_owner']) || !isset($linkedItem['file_source'])) { \OC_Response::setStatus(\OC_Response::STATUS_INTERNAL_SERVER_ERROR); - \OC_Log::write('core-preview', 'Passed token seems to be valid, but it does not contain all necessary information . ("' . $token . '")', \OC_Log::WARN); + \OCP\Util::writeLog('core-preview', 'Passed token seems to be valid, but it does not contain all necessary information . ("' . $token . '")', \OCP\Util::WARN); exit; } @@ -77,7 +77,7 @@ if($linkedItem['item_type'] === 'folder') { $isValid = \OC\Files\Filesystem::isValidPath($file); if(!$isValid) { \OC_Response::setStatus(\OC_Response::STATUS_BAD_REQUEST); - \OC_Log::write('core-preview', 'Passed filename is not valid, might be malicious (file:"' . $file . '";ip:"' . \OC::$server->getRequest()->getRemoteAddress() . '")', \OC_Log::WARN); + \OCP\Util::writeLog('core-preview', 'Passed filename is not valid, might be malicious (file:"' . $file . '";ip:"' . \OC::$server->getRequest()->getRemoteAddress() . '")', \OCP\Util::WARN); exit; } $sharedFile = \OC\Files\Filesystem::normalizePath($file); @@ -96,7 +96,7 @@ if(substr($path, 0, 1) === '/') { if($maxX === 0 || $maxY === 0) { \OC_Response::setStatus(\OC_Response::STATUS_BAD_REQUEST); - \OC_Log::write('core-preview', 'x and/or y set to 0', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'x and/or y set to 0', \OCP\Util::DEBUG); exit; } @@ -113,5 +113,5 @@ try{ $preview->showPreview(); } catch (\Exception $e) { \OC_Response::setStatus(\OC_Response::STATUS_INTERNAL_SERVER_ERROR); - \OC_Log::write('core', $e->getmessage(), \OC_Log::DEBUG); + \OCP\Util::writeLog('core', $e->getmessage(), \OCP\Util::DEBUG); } diff --git a/apps/files_sharing/ajax/shareinfo.php b/apps/files_sharing/ajax/shareinfo.php index b2f88265ca1..3ea0fae8522 100644 --- a/apps/files_sharing/ajax/shareinfo.php +++ b/apps/files_sharing/ajax/shareinfo.php @@ -3,6 +3,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_sharing/api/local.php b/apps/files_sharing/api/local.php index 03812800c17..84a789f26e4 100644 --- a/apps/files_sharing/api/local.php +++ b/apps/files_sharing/api/local.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> @@ -27,6 +26,8 @@ namespace OCA\Files_Sharing\API; +use OC\HintException; + class Local { /** @@ -70,6 +71,10 @@ class Local { } $share['icon'] = substr(\OC_Helper::mimetypeIcon($share['mimetype']), 0, -3) . 'svg'; } + + if (!is_null($share['token'])) { + $share['url'] = \OC::$server->getURLGenerator()->linkToRouteAbsolute('files_sharing.sharecontroller.showShare', ['token' => $share['token']]); + } } return new \OC_OCS_Result($shares); } @@ -142,6 +147,12 @@ class Local { if ($shares === null || empty($shares)) { return new \OC_OCS_Result(null, 404, 'share doesn\'t exist'); } else { + foreach ($shares as &$share) { + if (!is_null($share['token'])) { + $share['url'] = \OC::$server->getURLGenerator()->linkToRouteAbsolute('files_sharing.sharecontroller.showShare', ['token' => $share['token']]); + } + } + return new \OC_OCS_Result($shares); } } @@ -163,7 +174,7 @@ class Local { } $select = '`*PREFIX*share`.`id`, `item_type`, `*PREFIX*share`.`parent`, `share_type`, `share_with`, `file_source`, `path` , `*PREFIX*share`.`permissions`, `stime`, `expiration`, `token`, `storage`, `mail_send`, `mail_send`'; - $getReshares = \OC_DB::prepare('SELECT ' . $select . ' FROM `*PREFIX*share` INNER JOIN `*PREFIX*filecache` ON `file_source` = `*PREFIX*filecache`.`fileid` WHERE `*PREFIX*share`.`file_source` = ? AND `*PREFIX*share`.`item_type` IN (\'file\', \'folder\') AND `uid_owner` != ?'); + $getReshares = \OCP\DB::prepare('SELECT ' . $select . ' FROM `*PREFIX*share` INNER JOIN `*PREFIX*filecache` ON `file_source` = `*PREFIX*filecache`.`fileid` WHERE `*PREFIX*share`.`file_source` = ? AND `*PREFIX*share`.`item_type` IN (\'file\', \'folder\') AND `uid_owner` != ?'); $reshares = $getReshares->execute(array($itemSource, \OCP\User::getUser()))->fetchAll(); foreach ($reshares as $key => $reshare) { @@ -294,6 +305,8 @@ class Local { $shareWith, $permissions ); + } catch (HintException $e) { + return new \OC_OCS_Result(null, 400, $e->getHint()); } catch (\Exception $e) { return new \OC_OCS_Result(null, 403, $e->getMessage()); } @@ -572,7 +585,7 @@ class Local { $result = $query->execute($args); if (\OCP\DB::isError($result)) { - \OCP\Util::writeLog('files_sharing', \OC_DB::getErrorMessage(), \OCP\Util::ERROR); + \OCP\Util::writeLog('files_sharing', \OCP\DB::getErrorMessage(), \OCP\Util::ERROR); return null; } if ($share = $result->fetchRow()) { diff --git a/apps/files_sharing/appinfo/app.php b/apps/files_sharing/appinfo/app.php index c54038f17e3..f72f5024622 100644 --- a/apps/files_sharing/appinfo/app.php +++ b/apps/files_sharing/appinfo/app.php @@ -2,10 +2,8 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Gadzy <dev@gadzy.fr> - * @author j-ed <juergen@eisfair.org> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/apps/files_sharing/appinfo/application.php b/apps/files_sharing/appinfo/application.php index 0eb20945070..b9c2844d78c 100644 --- a/apps/files_sharing/appinfo/application.php +++ b/apps/files_sharing/appinfo/application.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Sharing\Appinfo; diff --git a/apps/files_sharing/appinfo/info.xml b/apps/files_sharing/appinfo/info.xml index d6f7e4b1320..28c64cbb1b4 100644 --- a/apps/files_sharing/appinfo/info.xml +++ b/apps/files_sharing/appinfo/info.xml @@ -19,5 +19,4 @@ Turning the feature off removes shared files and folders on the server for all s <files>public.php</files> <webdav>publicwebdav.php</webdav> </public> - <ocsid>166050</ocsid> </info> diff --git a/apps/files_sharing/appinfo/routes.php b/apps/files_sharing/appinfo/routes.php index 78fa138f5b5..2686abed0ae 100644 --- a/apps/files_sharing/appinfo/routes.php +++ b/apps/files_sharing/appinfo/routes.php @@ -2,9 +2,11 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Georg Ehrke <georg@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/appinfo/update.php b/apps/files_sharing/appinfo/update.php index f19c9ee1f9b..e98b60ea36d 100644 --- a/apps/files_sharing/appinfo/update.php +++ b/apps/files_sharing/appinfo/update.php @@ -1,7 +1,6 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_sharing/appinfo/version b/apps/files_sharing/appinfo/version index ee6cdce3c29..b6160487433 100644 --- a/apps/files_sharing/appinfo/version +++ b/apps/files_sharing/appinfo/version @@ -1 +1 @@ -0.6.1 +0.6.2 diff --git a/apps/files_sharing/js/share.js b/apps/files_sharing/js/share.js index 11c3170c2f0..c754ebdbae9 100644 --- a/apps/files_sharing/js/share.js +++ b/apps/files_sharing/js/share.js @@ -25,6 +25,10 @@ * @param {OCA.Files.FileList} fileList file list to be extended */ attach: function(fileList) { + // core sharing is disabled/not loaded + if (!OC.Share) { + return; + } if (fileList.id === 'trashbin' || fileList.id === 'files.public') { return; } diff --git a/apps/files_sharing/l10n/cs_CZ.js b/apps/files_sharing/l10n/cs_CZ.js index d1d89a15999..66a1314ff29 100644 --- a/apps/files_sharing/l10n/cs_CZ.js +++ b/apps/files_sharing/l10n/cs_CZ.js @@ -40,6 +40,8 @@ OC.L10N.register( "%2$s shared %1$s with you" : "%2$s s vámi sdílí %1$s", "You shared %1$s via link" : "Sdílíte %1$s přes odkaz", "Shares" : "Sdílení", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "Sdílej se mnou pomocí mého #ownCloud sdruženého cloud ID, více na %s", + "Share with me through my #ownCloud Federated Cloud ID" : "Sdílej se mnou pomocí mého #ownCloud sdruženého cloud ID", "This share is password-protected" : "Toto sdílení je chráněno heslem", "The password is wrong. Try again." : "Heslo není správné. Zkuste to znovu.", "Password" : "Heslo", @@ -59,6 +61,12 @@ OC.L10N.register( "Federated Cloud Sharing" : "Propojené cloudové sdílení", "Open documentation" : "Otevřít dokumentaci", "Allow users on this server to send shares to other servers" : "Povolit uživatelům z tohoto serveru zasílat sdílení na jiné servery", - "Allow users on this server to receive shares from other servers" : "Povolit uživatelům z tohoto serveru přijímat sdílení z jiných serverů" + "Allow users on this server to receive shares from other servers" : "Povolit uživatelům z tohoto serveru přijímat sdílení z jiných serverů", + "Federated Cloud" : "Sdružený cloud", + "Your Federated Cloud ID:" : "Vaše sdružené cloud ID:", + "Share it:" : "Sdílet:", + "Add it to your website:" : "Přidat na svou webovou stránku:", + "Share with me via ownCloud" : "Sdíleno se mnou přes ownCloud", + "HTML Code:" : "HTML kód:" }, "nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;"); diff --git a/apps/files_sharing/l10n/cs_CZ.json b/apps/files_sharing/l10n/cs_CZ.json index 95fea4806cf..330d64061e4 100644 --- a/apps/files_sharing/l10n/cs_CZ.json +++ b/apps/files_sharing/l10n/cs_CZ.json @@ -38,6 +38,8 @@ "%2$s shared %1$s with you" : "%2$s s vámi sdílí %1$s", "You shared %1$s via link" : "Sdílíte %1$s přes odkaz", "Shares" : "Sdílení", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "Sdílej se mnou pomocí mého #ownCloud sdruženého cloud ID, více na %s", + "Share with me through my #ownCloud Federated Cloud ID" : "Sdílej se mnou pomocí mého #ownCloud sdruženého cloud ID", "This share is password-protected" : "Toto sdílení je chráněno heslem", "The password is wrong. Try again." : "Heslo není správné. Zkuste to znovu.", "Password" : "Heslo", @@ -57,6 +59,12 @@ "Federated Cloud Sharing" : "Propojené cloudové sdílení", "Open documentation" : "Otevřít dokumentaci", "Allow users on this server to send shares to other servers" : "Povolit uživatelům z tohoto serveru zasílat sdílení na jiné servery", - "Allow users on this server to receive shares from other servers" : "Povolit uživatelům z tohoto serveru přijímat sdílení z jiných serverů" + "Allow users on this server to receive shares from other servers" : "Povolit uživatelům z tohoto serveru přijímat sdílení z jiných serverů", + "Federated Cloud" : "Sdružený cloud", + "Your Federated Cloud ID:" : "Vaše sdružené cloud ID:", + "Share it:" : "Sdílet:", + "Add it to your website:" : "Přidat na svou webovou stránku:", + "Share with me via ownCloud" : "Sdíleno se mnou přes ownCloud", + "HTML Code:" : "HTML kód:" },"pluralForm" :"nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/da.js b/apps/files_sharing/l10n/da.js index 79d8ae76314..a31e6363f25 100644 --- a/apps/files_sharing/l10n/da.js +++ b/apps/files_sharing/l10n/da.js @@ -60,6 +60,9 @@ OC.L10N.register( "Open documentation" : "Åben dokumentation", "Allow users on this server to send shares to other servers" : "Tillad brugere på denne server, at sende delinger til andre servere", "Allow users on this server to receive shares from other servers" : "Tillad brugere på denne server, at modtage delinger fra andre servere", - "Federated Cloud" : "Federated Cloud" + "Federated Cloud" : "Federated Cloud", + "Share it:" : "Del:", + "Add it to your website:" : "Tilføj den til din hjemmeside:", + "HTML Code:" : "HTMLkode:" }, "nplurals=2; plural=(n != 1);"); diff --git a/apps/files_sharing/l10n/da.json b/apps/files_sharing/l10n/da.json index 15807298f4f..b91fbf21eb0 100644 --- a/apps/files_sharing/l10n/da.json +++ b/apps/files_sharing/l10n/da.json @@ -58,6 +58,9 @@ "Open documentation" : "Åben dokumentation", "Allow users on this server to send shares to other servers" : "Tillad brugere på denne server, at sende delinger til andre servere", "Allow users on this server to receive shares from other servers" : "Tillad brugere på denne server, at modtage delinger fra andre servere", - "Federated Cloud" : "Federated Cloud" + "Federated Cloud" : "Federated Cloud", + "Share it:" : "Del:", + "Add it to your website:" : "Tilføj den til din hjemmeside:", + "HTML Code:" : "HTMLkode:" },"pluralForm" :"nplurals=2; plural=(n != 1);" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/et_EE.js b/apps/files_sharing/l10n/et_EE.js index bbe0b020b42..aa6dde2d7bb 100644 --- a/apps/files_sharing/l10n/et_EE.js +++ b/apps/files_sharing/l10n/et_EE.js @@ -8,11 +8,15 @@ OC.L10N.register( "Shared with you" : "Sinuga jagatud", "Shared with others" : "Teistega jagatud", "Shared by link" : "Jagatud lingiga", + "Nothing shared with you yet" : "Sinuga pole veel midagi jagatud", + "Nothing shared yet" : "Midagi pole veel jagatud", + "No shared links" : "Jagatud linke pole", "Do you want to add the remote share {name} from {owner}@{remote}?" : "Soovid lisata kaugjagamise {name} asukohast {owner}@{remote}?", "Remote share" : "Kaugjagamine", "Remote share password" : "Kaugjagamise parool", "Cancel" : "Loobu", "Add remote share" : "Lisa kaugjagamine", + "You can upload into this folder" : "Sa saad sellesse kausta faile üles laadida", "Invalid ownCloud url" : "Vigane ownCloud url", "Share" : "Jaga", "Shared by" : "Jagas", @@ -38,7 +42,12 @@ OC.L10N.register( "Download" : "Lae alla", "Download %s" : "Laadi alla %s", "Direct link" : "Otsene link", + "Open documentation" : "Ava dokumentatsioon", "Allow users on this server to send shares to other servers" : "Luba selle serveri kasutajatel saata faile teistesse serveritesse", - "Allow users on this server to receive shares from other servers" : "Luba selle serveri kasutajatel võtta vastu jagamisi teistest serveritest" + "Allow users on this server to receive shares from other servers" : "Luba selle serveri kasutajatel võtta vastu jagamisi teistest serveritest", + "Share it:" : "Jaga seda:", + "Add it to your website:" : "Lisa see oma veebisaidile:", + "Share with me via ownCloud" : "Jaga minuga läbi ownCloudiga", + "HTML Code:" : "HTML kood:" }, "nplurals=2; plural=(n != 1);"); diff --git a/apps/files_sharing/l10n/et_EE.json b/apps/files_sharing/l10n/et_EE.json index 3e36c3540fa..0f0c3c492dd 100644 --- a/apps/files_sharing/l10n/et_EE.json +++ b/apps/files_sharing/l10n/et_EE.json @@ -6,11 +6,15 @@ "Shared with you" : "Sinuga jagatud", "Shared with others" : "Teistega jagatud", "Shared by link" : "Jagatud lingiga", + "Nothing shared with you yet" : "Sinuga pole veel midagi jagatud", + "Nothing shared yet" : "Midagi pole veel jagatud", + "No shared links" : "Jagatud linke pole", "Do you want to add the remote share {name} from {owner}@{remote}?" : "Soovid lisata kaugjagamise {name} asukohast {owner}@{remote}?", "Remote share" : "Kaugjagamine", "Remote share password" : "Kaugjagamise parool", "Cancel" : "Loobu", "Add remote share" : "Lisa kaugjagamine", + "You can upload into this folder" : "Sa saad sellesse kausta faile üles laadida", "Invalid ownCloud url" : "Vigane ownCloud url", "Share" : "Jaga", "Shared by" : "Jagas", @@ -36,7 +40,12 @@ "Download" : "Lae alla", "Download %s" : "Laadi alla %s", "Direct link" : "Otsene link", + "Open documentation" : "Ava dokumentatsioon", "Allow users on this server to send shares to other servers" : "Luba selle serveri kasutajatel saata faile teistesse serveritesse", - "Allow users on this server to receive shares from other servers" : "Luba selle serveri kasutajatel võtta vastu jagamisi teistest serveritest" + "Allow users on this server to receive shares from other servers" : "Luba selle serveri kasutajatel võtta vastu jagamisi teistest serveritest", + "Share it:" : "Jaga seda:", + "Add it to your website:" : "Lisa see oma veebisaidile:", + "Share with me via ownCloud" : "Jaga minuga läbi ownCloudiga", + "HTML Code:" : "HTML kood:" },"pluralForm" :"nplurals=2; plural=(n != 1);" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/fr.js b/apps/files_sharing/l10n/fr.js index 61ee5c1a61b..b866739e148 100644 --- a/apps/files_sharing/l10n/fr.js +++ b/apps/files_sharing/l10n/fr.js @@ -63,10 +63,10 @@ OC.L10N.register( "Allow users on this server to send shares to other servers" : "Autoriser les utilisateurs de ce serveur à envoyer des partages vers d'autres serveurs", "Allow users on this server to receive shares from other servers" : "Autoriser les utilisateurs de ce serveur à recevoir des partages d'autres serveurs", "Federated Cloud" : "Federated Cloud", - "Your Federated Cloud ID:" : "Votre ID Federated Cloud :", + "Your Federated Cloud ID:" : "Votre identifiant Federated Cloud :", "Share it:" : "Partager :", "Add it to your website:" : "Ajouter à votre site web :", "Share with me via ownCloud" : "Partagez avec moi via ownCloud", - "HTML Code:" : "Code HTML:" + "HTML Code:" : "Code HTML :" }, "nplurals=2; plural=(n > 1);"); diff --git a/apps/files_sharing/l10n/fr.json b/apps/files_sharing/l10n/fr.json index a57b1befbcc..b4592edcdcc 100644 --- a/apps/files_sharing/l10n/fr.json +++ b/apps/files_sharing/l10n/fr.json @@ -61,10 +61,10 @@ "Allow users on this server to send shares to other servers" : "Autoriser les utilisateurs de ce serveur à envoyer des partages vers d'autres serveurs", "Allow users on this server to receive shares from other servers" : "Autoriser les utilisateurs de ce serveur à recevoir des partages d'autres serveurs", "Federated Cloud" : "Federated Cloud", - "Your Federated Cloud ID:" : "Votre ID Federated Cloud :", + "Your Federated Cloud ID:" : "Votre identifiant Federated Cloud :", "Share it:" : "Partager :", "Add it to your website:" : "Ajouter à votre site web :", "Share with me via ownCloud" : "Partagez avec moi via ownCloud", - "HTML Code:" : "Code HTML:" + "HTML Code:" : "Code HTML :" },"pluralForm" :"nplurals=2; plural=(n > 1);" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/nb_NO.js b/apps/files_sharing/l10n/nb_NO.js index 972f0c2e638..b7e2dfc9b07 100644 --- a/apps/files_sharing/l10n/nb_NO.js +++ b/apps/files_sharing/l10n/nb_NO.js @@ -40,6 +40,8 @@ OC.L10N.register( "%2$s shared %1$s with you" : "%2$s delte %1$s med deg", "You shared %1$s via link" : "Du delte %1$s via lenke", "Shares" : "Delinger", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "Del med meg gjennom min #ownCloud ID for sammenknyttet sky, se %s", + "Share with me through my #ownCloud Federated Cloud ID" : "Del med meg gjennom min #ownCloud ID for sammenknyttet sky", "This share is password-protected" : "Denne delingen er passordbeskyttet", "The password is wrong. Try again." : "Passordet er feil. Prøv på nytt.", "Password" : "Passord", @@ -60,6 +62,11 @@ OC.L10N.register( "Open documentation" : "Åpne dokumentasjonen", "Allow users on this server to send shares to other servers" : "Tillat at brukere på denne serveren sender delinger til andre servere", "Allow users on this server to receive shares from other servers" : "Tillat at brukere på denne serveren mottar delinger fra andre servere", - "Federated Cloud" : "Sammenknyttet sky" + "Federated Cloud" : "Sammenknyttet sky", + "Your Federated Cloud ID:" : "Din ID for sammenknyttet sky:", + "Share it:" : "Del den:", + "Add it to your website:" : "Legg den på websiden din:", + "Share with me via ownCloud" : "Del med meg via ownCloud", + "HTML Code:" : "HTML-kode:" }, "nplurals=2; plural=(n != 1);"); diff --git a/apps/files_sharing/l10n/nb_NO.json b/apps/files_sharing/l10n/nb_NO.json index 9e3e93a6802..2e490bbcde7 100644 --- a/apps/files_sharing/l10n/nb_NO.json +++ b/apps/files_sharing/l10n/nb_NO.json @@ -38,6 +38,8 @@ "%2$s shared %1$s with you" : "%2$s delte %1$s med deg", "You shared %1$s via link" : "Du delte %1$s via lenke", "Shares" : "Delinger", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "Del med meg gjennom min #ownCloud ID for sammenknyttet sky, se %s", + "Share with me through my #ownCloud Federated Cloud ID" : "Del med meg gjennom min #ownCloud ID for sammenknyttet sky", "This share is password-protected" : "Denne delingen er passordbeskyttet", "The password is wrong. Try again." : "Passordet er feil. Prøv på nytt.", "Password" : "Passord", @@ -58,6 +60,11 @@ "Open documentation" : "Åpne dokumentasjonen", "Allow users on this server to send shares to other servers" : "Tillat at brukere på denne serveren sender delinger til andre servere", "Allow users on this server to receive shares from other servers" : "Tillat at brukere på denne serveren mottar delinger fra andre servere", - "Federated Cloud" : "Sammenknyttet sky" + "Federated Cloud" : "Sammenknyttet sky", + "Your Federated Cloud ID:" : "Din ID for sammenknyttet sky:", + "Share it:" : "Del den:", + "Add it to your website:" : "Legg den på websiden din:", + "Share with me via ownCloud" : "Del med meg via ownCloud", + "HTML Code:" : "HTML-kode:" },"pluralForm" :"nplurals=2; plural=(n != 1);" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/th_TH.js b/apps/files_sharing/l10n/th_TH.js index 5df005e01a7..2ab0d72bb56 100644 --- a/apps/files_sharing/l10n/th_TH.js +++ b/apps/files_sharing/l10n/th_TH.js @@ -40,8 +40,8 @@ OC.L10N.register( "%2$s shared %1$s with you" : "%2$s ถูกแชร์ %1$s กับคุณ", "You shared %1$s via link" : "คุณแชร์ %1$s ผ่านลิงค์", "Shares" : "แชร์", - "Share with me through my #ownCloud Federated Cloud ID, see %s" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยคลาวด์ไอดี สามารถดูได้ที่ %s", - "Share with me through my #ownCloud Federated Cloud ID" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยคลาวด์ไอดี", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยไอดีคลาวด์ในเครือ สามารถดูได้ที่ %s", + "Share with me through my #ownCloud Federated Cloud ID" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยไอดีคลาวด์ในเครือ", "This share is password-protected" : "นี้แชร์การป้องกันด้วยรหัสผ่าน", "The password is wrong. Try again." : "รหัสผ่านที่ไม่ถูกต้อง กรุณาลองอีกครั้ง", "Password" : "รหัสผ่าน", @@ -63,7 +63,7 @@ OC.L10N.register( "Allow users on this server to send shares to other servers" : "อนุญาตให้ผู้ใช้บนเซิร์ฟเวอร์นี้ส่งแชร์ไปยังเซิร์ฟเวอร์อื่นๆ", "Allow users on this server to receive shares from other servers" : "อนุญาตให้ผู้ใช้บนเซิร์ฟเวอร์นี้ได้รับการแชร์จากเซิร์ฟเวอร์อื่นๆ", "Federated Cloud" : "สหพันธ์คลาวด์", - "Your Federated Cloud ID:" : "คลาวด์ไอดีของคุณ:", + "Your Federated Cloud ID:" : "ไอดีคลาวด์ของคุณ:", "Share it:" : "แชร์มัน:", "Add it to your website:" : "เพิ่มไปยังเว็บไซต์ของคุณ:", "Share with me via ownCloud" : "แชร์ร่วมกับฉันผ่าน ownCloud", diff --git a/apps/files_sharing/l10n/th_TH.json b/apps/files_sharing/l10n/th_TH.json index e1a9655741f..a4525d255f4 100644 --- a/apps/files_sharing/l10n/th_TH.json +++ b/apps/files_sharing/l10n/th_TH.json @@ -38,8 +38,8 @@ "%2$s shared %1$s with you" : "%2$s ถูกแชร์ %1$s กับคุณ", "You shared %1$s via link" : "คุณแชร์ %1$s ผ่านลิงค์", "Shares" : "แชร์", - "Share with me through my #ownCloud Federated Cloud ID, see %s" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยคลาวด์ไอดี สามารถดูได้ที่ %s", - "Share with me through my #ownCloud Federated Cloud ID" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยคลาวด์ไอดี", + "Share with me through my #ownCloud Federated Cloud ID, see %s" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยไอดีคลาวด์ในเครือ สามารถดูได้ที่ %s", + "Share with me through my #ownCloud Federated Cloud ID" : "แชร์ร่วมกับฉันผ่าน #ownCloud ด้วยไอดีคลาวด์ในเครือ", "This share is password-protected" : "นี้แชร์การป้องกันด้วยรหัสผ่าน", "The password is wrong. Try again." : "รหัสผ่านที่ไม่ถูกต้อง กรุณาลองอีกครั้ง", "Password" : "รหัสผ่าน", @@ -61,7 +61,7 @@ "Allow users on this server to send shares to other servers" : "อนุญาตให้ผู้ใช้บนเซิร์ฟเวอร์นี้ส่งแชร์ไปยังเซิร์ฟเวอร์อื่นๆ", "Allow users on this server to receive shares from other servers" : "อนุญาตให้ผู้ใช้บนเซิร์ฟเวอร์นี้ได้รับการแชร์จากเซิร์ฟเวอร์อื่นๆ", "Federated Cloud" : "สหพันธ์คลาวด์", - "Your Federated Cloud ID:" : "คลาวด์ไอดีของคุณ:", + "Your Federated Cloud ID:" : "ไอดีคลาวด์ของคุณ:", "Share it:" : "แชร์มัน:", "Add it to your website:" : "เพิ่มไปยังเว็บไซต์ของคุณ:", "Share with me via ownCloud" : "แชร์ร่วมกับฉันผ่าน ownCloud", diff --git a/apps/files_sharing/l10n/uk.js b/apps/files_sharing/l10n/uk.js index 18a6dde9e3a..76e9b885257 100644 --- a/apps/files_sharing/l10n/uk.js +++ b/apps/files_sharing/l10n/uk.js @@ -59,6 +59,9 @@ OC.L10N.register( "Federated Cloud Sharing" : "Об’єднання хмарних сховищ", "Open documentation" : "Відкрити документацію", "Allow users on this server to send shares to other servers" : "Дозволити користувачам цього сервера публікувати на інших серверах", - "Allow users on this server to receive shares from other servers" : "Дозволити користувачам на цьому сервері отримувати публікації з інших серверів" + "Allow users on this server to receive shares from other servers" : "Дозволити користувачам на цьому сервері отримувати публікації з інших серверів", + "Share it:" : "Поділитися цим:", + "Add it to your website:" : "Додати до вашого сайту:", + "HTML Code:" : "HTML код:" }, "nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); diff --git a/apps/files_sharing/l10n/uk.json b/apps/files_sharing/l10n/uk.json index de200a1fe8f..74cccc1901c 100644 --- a/apps/files_sharing/l10n/uk.json +++ b/apps/files_sharing/l10n/uk.json @@ -57,6 +57,9 @@ "Federated Cloud Sharing" : "Об’єднання хмарних сховищ", "Open documentation" : "Відкрити документацію", "Allow users on this server to send shares to other servers" : "Дозволити користувачам цього сервера публікувати на інших серверах", - "Allow users on this server to receive shares from other servers" : "Дозволити користувачам на цьому сервері отримувати публікації з інших серверів" + "Allow users on this server to receive shares from other servers" : "Дозволити користувачам на цьому сервері отримувати публікації з інших серверів", + "Share it:" : "Поділитися цим:", + "Add it to your website:" : "Додати до вашого сайту:", + "HTML Code:" : "HTML код:" },"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" }
\ No newline at end of file diff --git a/apps/files_sharing/l10n/zh_CN.js b/apps/files_sharing/l10n/zh_CN.js index 11e71ab4819..f3bbbbcfcb9 100644 --- a/apps/files_sharing/l10n/zh_CN.js +++ b/apps/files_sharing/l10n/zh_CN.js @@ -23,6 +23,7 @@ OC.L10N.register( "This share is password-protected" : "这是一个密码保护的共享", "The password is wrong. Try again." : "用户名或密码错误!请重试", "Password" : "密码", + "No entries found in this folder" : "此文件夹中无项目", "Name" : "名称", "Share time" : "分享时间", "Sorry, this link doesn’t seem to work anymore." : "抱歉,此链接已失效", @@ -34,6 +35,8 @@ OC.L10N.register( "Add to your ownCloud" : "添加到您的 ownCloud", "Download" : "下载", "Download %s" : "下载 %s", - "Direct link" : "直接链接" + "Direct link" : "直接链接", + "Federated Cloud Sharing" : "联合云共享", + "Open documentation" : "打开文档" }, "nplurals=1; plural=0;"); diff --git a/apps/files_sharing/l10n/zh_CN.json b/apps/files_sharing/l10n/zh_CN.json index bc26e501a06..a8b4d45a62d 100644 --- a/apps/files_sharing/l10n/zh_CN.json +++ b/apps/files_sharing/l10n/zh_CN.json @@ -21,6 +21,7 @@ "This share is password-protected" : "这是一个密码保护的共享", "The password is wrong. Try again." : "用户名或密码错误!请重试", "Password" : "密码", + "No entries found in this folder" : "此文件夹中无项目", "Name" : "名称", "Share time" : "分享时间", "Sorry, this link doesn’t seem to work anymore." : "抱歉,此链接已失效", @@ -32,6 +33,8 @@ "Add to your ownCloud" : "添加到您的 ownCloud", "Download" : "下载", "Download %s" : "下载 %s", - "Direct link" : "直接链接" + "Direct link" : "直接链接", + "Federated Cloud Sharing" : "联合云共享", + "Open documentation" : "打开文档" },"pluralForm" :"nplurals=1; plural=0;" }
\ No newline at end of file diff --git a/apps/files_sharing/lib/cache.php b/apps/files_sharing/lib/cache.php index 49f5a4e8e7c..bb62e8078ad 100644 --- a/apps/files_sharing/lib/cache.php +++ b/apps/files_sharing/lib/cache.php @@ -120,7 +120,7 @@ class Shared_Cache extends Cache { if (!is_int($sourceId) || $sourceId === 0) { $sourceId = $this->storage->getSourceId(); } - $query = \OC_DB::prepare( + $query = \OCP\DB::prepare( 'SELECT `fileid`, `storage`, `path`, `parent`, `name`, `mimetype`, `mimepart`,' . ' `size`, `mtime`, `encrypted`, `storage_mtime`, `etag`, `permissions`' . ' FROM `*PREFIX*filecache` WHERE `fileid` = ?'); @@ -499,7 +499,7 @@ class Shared_Cache extends Cache { */ private function getParentInfo($id) { $sql = 'SELECT `parent`, `name` FROM `*PREFIX*filecache` WHERE `fileid` = ?'; - $query = \OC_DB::prepare($sql); + $query = \OCP\DB::prepare($sql); $result = $query->execute(array($id)); if ($row = $result->fetchRow()) { return array((int)$row['parent'], $row['name']); diff --git a/apps/files_sharing/lib/controllers/externalsharescontroller.php b/apps/files_sharing/lib/controllers/externalsharescontroller.php index da0951d8e7c..494a544b2b8 100644 --- a/apps/files_sharing/lib/controllers/externalsharescontroller.php +++ b/apps/files_sharing/lib/controllers/externalsharescontroller.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/lib/external/scanner.php b/apps/files_sharing/lib/external/scanner.php index 653d4b7dd47..60eb7c8dacd 100644 --- a/apps/files_sharing/lib/external/scanner.php +++ b/apps/files_sharing/lib/external/scanner.php @@ -34,7 +34,7 @@ class Scanner extends \OC\Files\Cache\Scanner { protected $storage; /** {@inheritDoc} */ - public function scan($path, $recursive = self::SCAN_RECURSIVE, $reuse = -1) { + public function scan($path, $recursive = self::SCAN_RECURSIVE, $reuse = -1, $lock = true) { $this->scanAll(); } @@ -48,9 +48,10 @@ class Scanner extends \OC\Files\Cache\Scanner { * @param int $reuseExisting * @param int $parentId * @param array | null $cacheData existing data in the cache for the file to be scanned + * @param bool $lock set to false to disable getting an additional read lock during scanning * @return array an array of metadata of the scanned file */ - public function scanFile($file, $reuseExisting = 0, $parentId = -1, $cacheData = null) { + public function scanFile($file, $reuseExisting = 0, $parentId = -1, $cacheData = null, $lock = true) { try { return parent::scanFile($file, $reuseExisting); } catch (ForbiddenException $e) { diff --git a/apps/files_sharing/lib/external/storage.php b/apps/files_sharing/lib/external/storage.php index 39e182feb60..3284a60172f 100644 --- a/apps/files_sharing/lib/external/storage.php +++ b/apps/files_sharing/lib/external/storage.php @@ -191,7 +191,7 @@ class Storage extends DAV implements ISharedStorage { throw new StorageInvalidException(); } else { // ownCloud instance is gone, likely to be a temporary server configuration error - throw $e; + throw new StorageNotAvailableException(); } } catch (ForbiddenException $e) { // auth error, remove share for now (provide a dialog in the future) @@ -201,10 +201,7 @@ class Storage extends DAV implements ISharedStorage { } catch (\GuzzleHttp\Exception\ConnectException $e) { throw new StorageNotAvailableException(); } catch (\GuzzleHttp\Exception\RequestException $e) { - if ($e->getCode() === 503) { - throw new StorageNotAvailableException(); - } - throw $e; + throw new StorageNotAvailableException(); } catch (\Exception $e) { throw $e; } @@ -250,16 +247,13 @@ class Storage extends DAV implements ISharedStorage { try { $response = $client->post($url, ['body' => ['password' => $password]]); } catch (\GuzzleHttp\Exception\RequestException $e) { - switch ($e->getCode()) { - case 401: - case 403: + if ($e->getCode() === 401 || $e->getCode() === 403) { throw new ForbiddenException(); - case 404: - throw new NotFoundException(); - case 500: - throw new \Exception(); } - throw $e; + // throw this to be on the safe side: the share will still be visible + // in the UI in case the failure is intermittent, and the user will + // be able to decide whether to remove it if it's really gone + throw new NotFoundException(); } return json_decode($response->getBody(), true); diff --git a/apps/files_sharing/lib/helper.php b/apps/files_sharing/lib/helper.php index c76704802b1..38cb73be29c 100644 --- a/apps/files_sharing/lib/helper.php +++ b/apps/files_sharing/lib/helper.php @@ -55,13 +55,13 @@ class Helper { $linkItem = \OCP\Share::getShareByToken($token, !$password); if($linkItem === false || ($linkItem['item_type'] !== 'file' && $linkItem['item_type'] !== 'folder')) { \OC_Response::setStatus(404); - \OC_Log::write('core-preview', 'Passed token parameter is not valid', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'Passed token parameter is not valid', \OCP\Util::DEBUG); exit; } if(!isset($linkItem['uid_owner']) || !isset($linkItem['file_source'])) { \OC_Response::setStatus(500); - \OC_Log::write('core-preview', 'Passed token seems to be valid, but it does not contain all necessary information . ("' . $token . '")', \OC_Log::WARN); + \OCP\Util::writeLog('core-preview', 'Passed token seems to be valid, but it does not contain all necessary information . ("' . $token . '")', \OCP\Util::WARN); exit; } diff --git a/apps/files_sharing/lib/hooks.php b/apps/files_sharing/lib/hooks.php index c3588ecdfe5..7dd04f2f4a0 100644 --- a/apps/files_sharing/lib/hooks.php +++ b/apps/files_sharing/lib/hooks.php @@ -2,6 +2,7 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_sharing/lib/mountprovider.php b/apps/files_sharing/lib/mountprovider.php index c5d3643f28d..3f59fd131d0 100644 --- a/apps/files_sharing/lib/mountprovider.php +++ b/apps/files_sharing/lib/mountprovider.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Sharing; diff --git a/apps/files_sharing/lib/propagation/changewatcher.php b/apps/files_sharing/lib/propagation/changewatcher.php index 483f436e289..9f23c19be88 100644 --- a/apps/files_sharing/lib/propagation/changewatcher.php +++ b/apps/files_sharing/lib/propagation/changewatcher.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Sharing\Propagation; @@ -25,10 +39,17 @@ class ChangeWatcher { private $baseView; /** + * @var RecipientPropagator + */ + private $recipientPropagator; + + /** * @param \OC\Files\View $baseView the view for the logged in user + * @param RecipientPropagator $recipientPropagator */ - public function __construct(View $baseView) { + public function __construct(View $baseView, RecipientPropagator $recipientPropagator) { $this->baseView = $baseView; + $this->recipientPropagator = $recipientPropagator; } @@ -39,6 +60,12 @@ class ChangeWatcher { if ($mount instanceof SharedMount) { $this->propagateForOwner($mount->getShare(), $mount->getInternalPath($fullPath), $mount->getOwnerPropagator()); } + $info = $this->baseView->getFileInfo($path); + if ($info) { + // trigger propagation if the subject of the write hook is shared. + // if a parent folder of $path is shared the propagation will be triggered from the change propagator hooks + $this->recipientPropagator->propagateById($info->getId()); + } } public function renameHook($params) { diff --git a/apps/files_sharing/lib/propagation/propagationmanager.php b/apps/files_sharing/lib/propagation/propagationmanager.php index fa073be7f60..7929c2aa5bb 100644 --- a/apps/files_sharing/lib/propagation/propagationmanager.php +++ b/apps/files_sharing/lib/propagation/propagationmanager.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Sharing\Propagation; @@ -75,7 +89,7 @@ class PropagationManager { if (isset($this->sharePropagators[$user])) { return $this->sharePropagators[$user]; } - $this->sharePropagators[$user] = new RecipientPropagator($user, $this->getChangePropagator($user), $this->config); + $this->sharePropagators[$user] = new RecipientPropagator($user, $this->getChangePropagator($user), $this->config, $this); return $this->sharePropagators[$user]; } @@ -101,7 +115,8 @@ class PropagationManager { if (!$user) { return; } - $watcher = new ChangeWatcher(Filesystem::getView()); + $recipientPropagator = $this->getSharePropagator($user->getUID()); + $watcher = new ChangeWatcher(Filesystem::getView(), $recipientPropagator); // for marking shares owned by the active user as dirty when a file inside them changes $this->listenToOwnerChanges($user->getUID(), $user->getUID()); diff --git a/apps/files_sharing/lib/propagation/recipientpropagator.php b/apps/files_sharing/lib/propagation/recipientpropagator.php index 5b7651f2ce7..97ea452aa6c 100644 --- a/apps/files_sharing/lib/propagation/recipientpropagator.php +++ b/apps/files_sharing/lib/propagation/recipientpropagator.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Sharing\Propagation; @@ -32,16 +46,23 @@ class RecipientPropagator { protected $config; /** + * @var PropagationManager + */ + private $manager; + + /** * @param string $userId current user, must match the propagator's * user * @param \OC\Files\Cache\ChangePropagator $changePropagator change propagator * initialized with a view for $user * @param \OCP\IConfig $config + * @param PropagationManager $manager */ - public function __construct($userId, $changePropagator, $config) { + public function __construct($userId, $changePropagator, $config, PropagationManager $manager) { $this->userId = $userId; $this->changePropagator = $changePropagator; $this->config = $config; + $this->manager = $manager; } /** @@ -101,18 +122,24 @@ class RecipientPropagator { */ public function attachToPropagator(ChangePropagator $propagator, $owner) { $propagator->listen('\OC\Files', 'propagate', function ($path, $entry) use ($owner) { - $shares = Share::getAllSharesForFileId($entry['fileid']); - foreach ($shares as $share) { - // propagate down the share tree - $this->markDirty($share, microtime(true)); + $this->propagateById($entry['fileid']); + }); + } - // propagate up the share tree - $user = $share['uid_owner']; + public function propagateById($id) { + $shares = Share::getAllSharesForFileId($id); + foreach ($shares as $share) { + // propagate down the share tree + $this->markDirty($share, microtime(true)); + + // propagate up the share tree + $user = $share['uid_owner']; + if($user !== $this->userId) { $view = new View('/' . $user . '/files'); $path = $view->getPath($share['file_source']); - $watcher = new ChangeWatcher($view); + $watcher = new ChangeWatcher($view, $this->manager->getSharePropagator($user)); $watcher->writeHook(['path' => $path]); } - }); + } } } diff --git a/apps/files_sharing/lib/share/file.php b/apps/files_sharing/lib/share/file.php index 1822c2468f1..9c09e05408b 100644 --- a/apps/files_sharing/lib/share/file.php +++ b/apps/files_sharing/lib/share/file.php @@ -183,7 +183,7 @@ class OC_Share_Backend_File implements OCP\Share_Backend_File_Dependent { if (isset($source['parent'])) { $parent = $source['parent']; while (isset($parent)) { - $query = \OC_DB::prepare('SELECT `parent`, `uid_owner` FROM `*PREFIX*share` WHERE `id` = ?', 1); + $query = \OCP\DB::prepare('SELECT `parent`, `uid_owner` FROM `*PREFIX*share` WHERE `id` = ?', 1); $item = $query->execute(array($parent))->fetchRow(); if (isset($item['parent'])) { $parent = $item['parent']; diff --git a/apps/files_sharing/lib/share/folder.php b/apps/files_sharing/lib/share/folder.php index d7b7c0c8f30..e18839b577d 100644 --- a/apps/files_sharing/lib/share/folder.php +++ b/apps/files_sharing/lib/share/folder.php @@ -64,7 +64,7 @@ class OC_Share_Backend_Folder extends OC_Share_Backend_File implements OCP\Share * @return mixed parent ID or null */ private function getParentId($child) { - $query = \OC_DB::prepare('SELECT `parent` FROM `*PREFIX*filecache` WHERE `fileid` = ?'); + $query = \OCP\DB::prepare('SELECT `parent` FROM `*PREFIX*filecache` WHERE `fileid` = ?'); $result = $query->execute(array($child)); $row = $result->fetchRow(); $parent = ($row) ? $row['parent'] : null; @@ -75,7 +75,7 @@ class OC_Share_Backend_Folder extends OC_Share_Backend_File implements OCP\Share public function getChildren($itemSource) { $children = array(); $parents = array($itemSource); - $query = \OC_DB::prepare('SELECT `id` FROM `*PREFIX*mimetypes` WHERE `mimetype` = ?'); + $query = \OCP\DB::prepare('SELECT `id` FROM `*PREFIX*mimetypes` WHERE `mimetype` = ?'); $result = $query->execute(array('httpd/unix-directory')); if ($row = $result->fetchRow()) { $mimetype = $row['id']; @@ -84,7 +84,7 @@ class OC_Share_Backend_Folder extends OC_Share_Backend_File implements OCP\Share } while (!empty($parents)) { $parents = "'".implode("','", $parents)."'"; - $query = OC_DB::prepare('SELECT `fileid`, `name`, `mimetype` FROM `*PREFIX*filecache`' + $query = \OCP\DB::prepare('SELECT `fileid`, `name`, `mimetype` FROM `*PREFIX*filecache`' .' WHERE `parent` IN ('.$parents.')'); $result = $query->execute(); $parents = array(); diff --git a/apps/files_sharing/lib/sharedmount.php b/apps/files_sharing/lib/sharedmount.php index 15aea0aa52a..fd672d0500c 100644 --- a/apps/files_sharing/lib/sharedmount.php +++ b/apps/files_sharing/lib/sharedmount.php @@ -41,34 +41,40 @@ class SharedMount extends MountPoint implements MoveableMount { */ protected $ownerPropagator; + /** + * @var \OC\Files\View + */ + private $recipientView; + public function __construct($storage, $mountpoint, $arguments = null, $loader = null) { // first update the mount point before creating the parent $this->ownerPropagator = $arguments['propagator']; - $newMountPoint = $this->verifyMountPoint($arguments['share'], $arguments['user']); + $this->recipientView = new View('/' . $arguments['user'] . '/files'); + $newMountPoint = $this->verifyMountPoint($arguments['share']); $absMountPoint = '/' . $arguments['user'] . '/files' . $newMountPoint; + $arguments['ownerView'] = new View('/' . $arguments['share']['uid_owner'] . '/files'); parent::__construct($storage, $absMountPoint, $arguments, $loader); } /** * check if the parent folder exists otherwise move the mount point up */ - private function verifyMountPoint(&$share, $user) { + private function verifyMountPoint(&$share) { $mountPoint = basename($share['file_target']); $parent = dirname($share['file_target']); - $view = new View('/' . $user . '/files'); - if (!$view->is_dir($parent)) { + if (!$this->recipientView->is_dir($parent)) { $parent = Helper::getShareFolder(); } $newMountPoint = \OCA\Files_Sharing\Helper::generateUniqueTarget( - \OC\Files\Filesystem::normalizePath($parent . '/' . $mountPoint), - array(), - new \OC\Files\View('/' . $user . '/files') - ); + \OC\Files\Filesystem::normalizePath($parent . '/' . $mountPoint), + [], + $this->recipientView + ); - if($newMountPoint !== $share['file_target']) { + if ($newMountPoint !== $share['file_target']) { self::updateFileTarget($newMountPoint, $share); $share['file_target'] = $newMountPoint; $share['unique_name'] = true; @@ -79,6 +85,7 @@ class SharedMount extends MountPoint implements MoveableMount { /** * update fileTarget in the database if the mount point changed + * * @param string $newPath * @param array $share reference to the share which should be modified * @return bool @@ -87,7 +94,7 @@ class SharedMount extends MountPoint implements MoveableMount { // if the user renames a mount point from a group share we need to create a new db entry // for the unique name if ($share['share_type'] === \OCP\Share::SHARE_TYPE_GROUP && empty($share['unique_name'])) { - $query = \OC_DB::prepare('INSERT INTO `*PREFIX*share` (`item_type`, `item_source`, `item_target`,' + $query = \OCP\DB::prepare('INSERT INTO `*PREFIX*share` (`item_type`, `item_source`, `item_target`,' .' `share_type`, `share_with`, `uid_owner`, `permissions`, `stime`, `file_source`,' .' `file_target`, `token`, `parent`) VALUES (?,?,?,?,?,?,?,?,?,?,?,?)'); $arguments = array($share['item_type'], $share['item_source'], $share['item_target'], @@ -95,11 +102,11 @@ class SharedMount extends MountPoint implements MoveableMount { $newPath, $share['token'], $share['id']); } else { // rename mount point - $query = \OC_DB::prepare( + $query = \OCP\DB::prepare( 'Update `*PREFIX*share` SET `file_target` = ? WHERE `id` = ?' - ); + ); $arguments = array($newPath, $share['id']); } diff --git a/apps/files_sharing/lib/sharedstorage.php b/apps/files_sharing/lib/sharedstorage.php index bf61dda3718..ff01489d77b 100644 --- a/apps/files_sharing/lib/sharedstorage.php +++ b/apps/files_sharing/lib/sharedstorage.php @@ -7,6 +7,7 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author scambra <sergio@entrecables.com> * @author Vincent Petry <pvince81@owncloud.com> * @@ -44,8 +45,14 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { private $files = array(); private static $isInitialized = array(); + /** + * @var \OC\Files\View + */ + private $ownerView; + public function __construct($arguments) { $this->share = $arguments['share']; + $this->ownerView = $arguments['ownerView']; } /** @@ -622,6 +629,11 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { /** @var \OCP\Files\Storage $targetStorage */ list($targetStorage, $targetInternalPath) = $this->resolvePath($path); $targetStorage->acquireLock($targetInternalPath, $type, $provider); + // lock the parent folders of the owner when locking the share as recipient + if ($path === '') { + $sourcePath = $this->ownerView->getPath($this->share['file_source']); + $this->ownerView->lockFile(dirname($sourcePath), ILockingProvider::LOCK_SHARED, true); + } } /** @@ -633,6 +645,11 @@ class Shared extends \OC\Files\Storage\Common implements ISharedStorage { /** @var \OCP\Files\Storage $targetStorage */ list($targetStorage, $targetInternalPath) = $this->resolvePath($path); $targetStorage->releaseLock($targetInternalPath, $type, $provider); + // unlock the parent folders of the owner when unlocking the share as recipient + if ($path === '') { + $sourcePath = $this->ownerView->getPath($this->share['file_source']); + $this->ownerView->unlockFile(dirname($sourcePath), ILockingProvider::LOCK_SHARED, true); + } } /** diff --git a/apps/files_sharing/lib/updater.php b/apps/files_sharing/lib/updater.php index 88bb68aa36e..9dd106a548c 100644 --- a/apps/files_sharing/lib/updater.php +++ b/apps/files_sharing/lib/updater.php @@ -77,10 +77,10 @@ class Shared_Updater { $shareType = $params['shareType']; if ($shareType === \OCP\Share::SHARE_TYPE_USER) { - self::correctUsersFolder($shareWith, '/'); + self::correctUsersFolder($shareWith, $params['fileTarget']); } elseif ($shareType === \OCP\Share::SHARE_TYPE_GROUP) { foreach (\OC_Group::usersInGroup($shareWith) as $user) { - self::correctUsersFolder($user, '/'); + self::correctUsersFolder($user, $params['fileTarget']); } } } @@ -138,7 +138,7 @@ class Shared_Updater { */ static public function fixBrokenSharesOnAppUpdate() { // delete all shares where the original file no longer exists - $findAndRemoveShares = \OC_DB::prepare('DELETE FROM `*PREFIX*share` ' . + $findAndRemoveShares = \OCP\DB::prepare('DELETE FROM `*PREFIX*share` ' . 'WHERE `item_type` IN (\'file\', \'folder\') ' . 'AND `file_source` NOT IN (SELECT `fileid` FROM `*PREFIX*filecache`)' ); diff --git a/apps/files_sharing/list.php b/apps/files_sharing/list.php index da640fd08d3..2577ed91006 100644 --- a/apps/files_sharing/list.php +++ b/apps/files_sharing/list.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/publicwebdav.php b/apps/files_sharing/publicwebdav.php index b70274e6bc0..be7530897f6 100644 --- a/apps/files_sharing/publicwebdav.php +++ b/apps/files_sharing/publicwebdav.php @@ -1,7 +1,6 @@ <?php /** - * @author Björn Schießle <schiessle@owncloud.com> - * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> @@ -47,7 +46,7 @@ $server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, $defaults->getName() // FIXME: The following line is a workaround for legacy components relying on being able to send a GET to / $server->addPlugin(new \OC\Connector\Sabre\DummyGetResponsePlugin()); $server->addPlugin(new \OC\Connector\Sabre\FilesPlugin($objectTree)); -$server->addPlugin(new \OC\Connector\Sabre\MaintenancePlugin()); +$server->addPlugin(new \OC\Connector\Sabre\MaintenancePlugin(\OC::$server->getConfig())); $server->addPlugin(new \OC\Connector\Sabre\ExceptionLoggerPlugin('webdav', \OC::$server->getLogger())); // wait with registering these until auth is handled and the filesystem is setup diff --git a/apps/files_sharing/settings-personal.php b/apps/files_sharing/settings-personal.php index fdf641e1d2c..9ff94eb16c8 100644 --- a/apps/files_sharing/settings-personal.php +++ b/apps/files_sharing/settings-personal.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Jan-Christoph Borchardt <hey@jancborchardt.net> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/tests/api.php b/apps/files_sharing/tests/api.php index d5a6fd5b657..af441b38ff2 100644 --- a/apps/files_sharing/tests/api.php +++ b/apps/files_sharing/tests/api.php @@ -311,6 +311,51 @@ class Test_Files_Sharing_Api extends TestCase { * @medium * @depends testCreateShare */ + function testPublicLinkUrl() { + // simulate a post request + $_POST['path'] = $this->folder; + $_POST['shareType'] = \OCP\Share::SHARE_TYPE_LINK; + + $result = \OCA\Files_Sharing\API\Local::createShare([]); + $this->assertTrue($result->succeeded()); + $data = $result->getData(); + + // check if we have a token + $this->assertTrue(is_string($data['token'])); + $id = $data['id']; + + // check for correct link + $url = \OC::$server->getURLGenerator()->getAbsoluteURL('/index.php/s/' . $data['token']); + $this->assertEquals($url, $data['url']); + + // check for link in getall shares + $result = \OCA\Files_Sharing\API\Local::getAllShares([]); + $this->assertTrue($result->succeeded()); + $data = $result->getData(); + $this->assertEquals($url, current($data)['url']); + + // check for path + $_GET['path'] = $this->folder; + $result = \OCA\Files_Sharing\API\Local::getAllShares([]); + $this->assertTrue($result->succeeded()); + $data = $result->getData(); + $this->assertEquals($url, current($data)['url']); + + // check in share id + $result = \OCA\Files_Sharing\API\Local::getShare(['id' => $id]); + $this->assertTrue($result->succeeded()); + $data = $result->getData(); + $this->assertEquals($url, current($data)['url']); + + //Clean up share + $fileinfo = $this->view->getFileInfo($this->folder); + \OCP\Share::unshare('folder', $fileinfo['fileid'], \OCP\Share::SHARE_TYPE_LINK, null); + } + + /** + * @medium + * @depends testCreateShare + */ function testGetShareFromSource() { $fileInfo = $this->view->getFileInfo($this->filename); diff --git a/apps/files_sharing/tests/controller/sharecontroller.php b/apps/files_sharing/tests/controller/sharecontroller.php index 8a075eeab9f..0b56aafc8a9 100644 --- a/apps/files_sharing/tests/controller/sharecontroller.php +++ b/apps/files_sharing/tests/controller/sharecontroller.php @@ -4,6 +4,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Cloutier <vincent1cloutier@gmail.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/tests/deleteorphanedsharesjobtest.php b/apps/files_sharing/tests/deleteorphanedsharesjobtest.php index 8b5afcb9149..124cb83e6f0 100644 --- a/apps/files_sharing/tests/deleteorphanedsharesjobtest.php +++ b/apps/files_sharing/tests/deleteorphanedsharesjobtest.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_sharing/tests/etagpropagation.php b/apps/files_sharing/tests/etagpropagation.php index 60b7c525e35..d978daf200c 100644 --- a/apps/files_sharing/tests/etagpropagation.php +++ b/apps/files_sharing/tests/etagpropagation.php @@ -1,5 +1,7 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -69,9 +71,12 @@ class EtagPropagation extends TestCase { $view1->mkdir('/directReshare'); $view1->mkdir('/sub1/sub2/folder/other'); $view1->mkdir('/sub1/sub2/folder/other'); + $view1->file_put_contents('/foo.txt', 'foobar'); $view1->file_put_contents('/sub1/sub2/folder/file.txt', 'foobar'); $view1->file_put_contents('/sub1/sub2/folder/inside/file.txt', 'foobar'); $folderInfo = $view1->getFileInfo('/sub1/sub2/folder'); + $fileInfo = $view1->getFileInfo('/foo.txt'); + \OCP\Share::shareItem('file', $fileInfo->getId(), \OCP\Share::SHARE_TYPE_USER, self::TEST_FILES_SHARING_API_USER2, 31); \OCP\Share::shareItem('folder', $folderInfo->getId(), \OCP\Share::SHARE_TYPE_USER, self::TEST_FILES_SHARING_API_USER2, 31); \OCP\Share::shareItem('folder', $folderInfo->getId(), \OCP\Share::SHARE_TYPE_USER, self::TEST_FILES_SHARING_API_USER3, 31); $folderInfo = $view1->getFileInfo('/directReshare'); @@ -179,6 +184,15 @@ class EtagPropagation extends TestCase { $this->assertAllUnchaged(); } + public function testOwnerWritesToSingleFileShare() { + $this->loginAsUser(self::TEST_FILES_SHARING_API_USER1); + Filesystem::file_put_contents('/foo.txt', 'bar'); + $this->assertEtagsNotChanged([self::TEST_FILES_SHARING_API_USER4, self::TEST_FILES_SHARING_API_USER3]); + $this->assertEtagsChanged([self::TEST_FILES_SHARING_API_USER1, self::TEST_FILES_SHARING_API_USER2]); + + $this->assertAllUnchaged(); + } + public function testOwnerWritesToShareWithReshare() { $this->loginAsUser(self::TEST_FILES_SHARING_API_USER1); Filesystem::file_put_contents('/sub1/sub2/folder/inside/bar.txt', 'bar'); diff --git a/apps/files_sharing/tests/locking.php b/apps/files_sharing/tests/locking.php new file mode 100644 index 00000000000..6d13fc1cda5 --- /dev/null +++ b/apps/files_sharing/tests/locking.php @@ -0,0 +1,101 @@ +<?php +/** + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace OCA\Files_sharing\Tests; + +use OC\Files\Filesystem; +use OC\Files\View; +use OC\Lock\MemcacheLockingProvider; +use OCP\Lock\ILockingProvider; + +class Locking extends TestCase { + /** + * @var \OC_User_Dummy + */ + private $userBackend; + + private $ownerUid; + private $recipientUid; + + public function setUp() { + parent::setUp(); + + $this->userBackend = new \OC_User_Dummy(); + \OC::$server->getUserManager()->registerBackend($this->userBackend); + + $this->ownerUid = $this->getUniqueID('owner_'); + $this->recipientUid = $this->getUniqueID('recipient_'); + $this->userBackend->createUser($this->ownerUid, ''); + $this->userBackend->createUser($this->recipientUid, ''); + + $this->loginAsUser($this->ownerUid); + Filesystem::mkdir('/foo'); + Filesystem::file_put_contents('/foo/bar.txt', 'asd'); + $fileId = Filesystem::getFileInfo('/foo/bar.txt')->getId(); + + \OCP\Share::shareItem('file', $fileId, \OCP\Share::SHARE_TYPE_USER, $this->recipientUid, 31); + + $this->loginAsUser($this->recipientUid); + $this->assertTrue(Filesystem::file_exists('bar.txt')); + } + + public function tearDown() { + \OC::$server->getUserManager()->removeBackend($this->userBackend); + parent::tearDown(); + } + + /** + * @expectedException \OCP\Lock\LockedException + */ + public function testLockAsRecipient() { + $this->loginAsUser($this->ownerUid); + + Filesystem::initMountPoints($this->recipientUid); + $recipientView = new View('/' . $this->recipientUid . '/files'); + $recipientView->lockFile('bar.txt', ILockingProvider::LOCK_EXCLUSIVE); + + Filesystem::rename('/foo', '/asd'); + } + + public function testUnLockAsRecipient() { + $this->loginAsUser($this->ownerUid); + + Filesystem::initMountPoints($this->recipientUid); + $recipientView = new View('/' . $this->recipientUid . '/files'); + $recipientView->lockFile('bar.txt', ILockingProvider::LOCK_EXCLUSIVE); + $recipientView->unlockFile('bar.txt', ILockingProvider::LOCK_EXCLUSIVE); + + $this->assertTrue(Filesystem::rename('/foo', '/asd')); + } + + public function testChangeLock() { + + Filesystem::initMountPoints($this->recipientUid); + $recipientView = new View('/' . $this->recipientUid . '/files'); + $recipientView->lockFile('bar.txt', ILockingProvider::LOCK_SHARED); + $recipientView->changeLock('bar.txt', ILockingProvider::LOCK_EXCLUSIVE); + $recipientView->unlockFile('bar.txt', ILockingProvider::LOCK_EXCLUSIVE); + + $this->assertTrue(true); + } +} diff --git a/apps/files_sharing/tests/middleware/sharingcheckmiddleware.php b/apps/files_sharing/tests/middleware/sharingcheckmiddleware.php index c52036e6f5b..0db8a1ed5bc 100644 --- a/apps/files_sharing/tests/middleware/sharingcheckmiddleware.php +++ b/apps/files_sharing/tests/middleware/sharingcheckmiddleware.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/apps/files_sharing/tests/permissions.php b/apps/files_sharing/tests/permissions.php index 91f0347163a..c10333defaa 100644 --- a/apps/files_sharing/tests/permissions.php +++ b/apps/files_sharing/tests/permissions.php @@ -3,6 +3,7 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/apps/files_sharing/tests/sharedmount.php b/apps/files_sharing/tests/sharedmount.php index ff4cb4c0e49..d1db6a644f0 100644 --- a/apps/files_sharing/tests/sharedmount.php +++ b/apps/files_sharing/tests/sharedmount.php @@ -5,6 +5,7 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -61,11 +62,11 @@ class Test_Files_Sharing_Mount extends OCA\Files_sharing\Tests\TestCase { self::TEST_FILES_SHARING_API_USER2, 31); $statement = "UPDATE `*PREFIX*share` SET `file_target` = ? where `share_with` = ?"; - $query = \OC_DB::prepare($statement); + $query = \OCP\DB::prepare($statement); $arguments = array('/foo/bar' . $this->folder, self::TEST_FILES_SHARING_API_USER2); $query->execute($arguments); - $query = \OC_DB::prepare('SELECT * FROM `*PREFIX*share`'); + $query = \OCP\DB::prepare('SELECT * FROM `*PREFIX*share`'); $result = $query->execute(); $shares = $result->fetchAll(); @@ -79,7 +80,7 @@ class Test_Files_Sharing_Mount extends OCA\Files_sharing\Tests\TestCase { // share should have moved up - $query = \OC_DB::prepare('SELECT * FROM `*PREFIX*share`'); + $query = \OCP\DB::prepare('SELECT * FROM `*PREFIX*share`'); $result = $query->execute(); $shares = $result->fetchAll(); diff --git a/apps/files_sharing/tests/sizepropagation.php b/apps/files_sharing/tests/sizepropagation.php index 4ab3475ccfc..dbaa316f603 100644 --- a/apps/files_sharing/tests/sizepropagation.php +++ b/apps/files_sharing/tests/sizepropagation.php @@ -1,6 +1,7 @@ <?php /** - * @author Vincent Petry <pvince81@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_sharing/tests/unsharechildren.php b/apps/files_sharing/tests/unsharechildren.php index b49180fdc83..c57070ba641 100644 --- a/apps/files_sharing/tests/unsharechildren.php +++ b/apps/files_sharing/tests/unsharechildren.php @@ -3,7 +3,7 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -40,7 +40,7 @@ class UnshareChildren extends TestCase { \OCP\Util::connectHook('OC_Filesystem', 'post_delete', '\OCA\Files_Sharing\Hooks', 'unshareChildren'); $this->folder = self::TEST_FOLDER_NAME; - $this->subfolder = '/subfolder_share_api_test'; + $this->subfolder = '/subfolder_share_api_test'; $this->subsubfolder = '/subsubfolder_share_api_test'; $this->filename = '/share-api-test'; @@ -49,12 +49,14 @@ class UnshareChildren extends TestCase { $this->view->mkdir($this->folder); $this->view->mkdir($this->folder . $this->subfolder); $this->view->mkdir($this->folder . $this->subfolder . $this->subsubfolder); - $this->view->file_put_contents($this->folder.$this->filename, $this->data); + $this->view->file_put_contents($this->folder . $this->filename, $this->data); $this->view->file_put_contents($this->folder . $this->subfolder . $this->filename, $this->data); } protected function tearDown() { - $this->view->deleteAll($this->folder); + if ($this->view) { + $this->view->deleteAll($this->folder); + } self::$tempStorage = null; diff --git a/apps/files_sharing/tests/updater.php b/apps/files_sharing/tests/updater.php index 294388bfe26..63ab452a5e1 100644 --- a/apps/files_sharing/tests/updater.php +++ b/apps/files_sharing/tests/updater.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -117,14 +116,34 @@ class Test_Files_Sharing_Updater extends OCA\Files_Sharing\Tests\TestCase { \OC\Files\Filesystem::getLoader()->removeStorageWrapper('oc_trashbin'); } + public function shareFolderProvider() { + return [ + ['/'], + ['/my_shares'], + ]; + } + /** * if a file gets shared the etag for the recipients root should change + * + * @dataProvider shareFolderProvider + * + * @param string $shareFolder share folder to use */ - function testShareFile() { + public function testShareFile($shareFolder) { + $config = \OC::$server->getConfig(); + $oldShareFolder = $config->getSystemValue('share_folder'); + $config->setSystemValue('share_folder', $shareFolder); + $this->loginHelper(self::TEST_FILES_SHARING_API_USER2); - $beforeShare = \OC\Files\Filesystem::getFileInfo(''); - $etagBeforeShare = $beforeShare->getEtag(); + $beforeShareRoot = \OC\Files\Filesystem::getFileInfo(''); + $etagBeforeShareRoot = $beforeShareRoot->getEtag(); + + \OC\Files\Filesystem::mkdir($shareFolder); + + $beforeShareDir = \OC\Files\Filesystem::getFileInfo($shareFolder); + $etagBeforeShareDir = $beforeShareDir->getEtag(); $this->loginHelper(self::TEST_FILES_SHARING_API_USER1); $fileinfo = \OC\Files\Filesystem::getFileInfo($this->folder); @@ -133,17 +152,25 @@ class Test_Files_Sharing_Updater extends OCA\Files_Sharing\Tests\TestCase { $this->loginHelper(self::TEST_FILES_SHARING_API_USER2); - $afterShare = \OC\Files\Filesystem::getFileInfo(''); - $etagAfterShare = $afterShare->getEtag(); + $afterShareRoot = \OC\Files\Filesystem::getFileInfo(''); + $etagAfterShareRoot = $afterShareRoot->getEtag(); + + $afterShareDir = \OC\Files\Filesystem::getFileInfo($shareFolder); + $etagAfterShareDir = $afterShareDir->getEtag(); - $this->assertTrue(is_string($etagBeforeShare)); - $this->assertTrue(is_string($etagAfterShare)); - $this->assertTrue($etagBeforeShare !== $etagAfterShare); + $this->assertTrue(is_string($etagBeforeShareRoot)); + $this->assertTrue(is_string($etagBeforeShareDir)); + $this->assertTrue(is_string($etagAfterShareRoot)); + $this->assertTrue(is_string($etagAfterShareDir)); + $this->assertTrue($etagBeforeShareRoot !== $etagAfterShareRoot); + $this->assertTrue($etagBeforeShareDir !== $etagAfterShareDir); // cleanup $this->loginHelper(self::TEST_FILES_SHARING_API_USER1); $result = \OCP\Share::unshare('folder', $fileinfo->getId(), \OCP\Share::SHARE_TYPE_USER, self::TEST_FILES_SHARING_API_USER2); $this->assertTrue($result); + + $config->setSystemValue('share_folder', $oldShareFolder); } /** diff --git a/apps/files_sharing/tests/watcher.php b/apps/files_sharing/tests/watcher.php index 4af5de6aaae..488792db4ef 100644 --- a/apps/files_sharing/tests/watcher.php +++ b/apps/files_sharing/tests/watcher.php @@ -4,6 +4,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/apps/files_trashbin/ajax/delete.php b/apps/files_trashbin/ajax/delete.php index 944e353b1eb..63002671bfa 100644 --- a/apps/files_trashbin/ajax/delete.php +++ b/apps/files_trashbin/ajax/delete.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * @@ -65,7 +64,7 @@ foreach ($list as $file) { OCA\Files_Trashbin\Trashbin::delete($filename, \OCP\User::getUser(), $timestamp); if (OCA\Files_Trashbin\Trashbin::file_exists($filename, $timestamp)) { $error[] = $filename; - OC_Log::write('trashbin','can\'t delete ' . $filename . ' permanently.', OC_Log::ERROR); + \OCP\Util::writeLog('trashbin','can\'t delete ' . $filename . ' permanently.', \OCP\Util::ERROR); } // only list deleted files if not deleting everything else if (!$deleteAll) { diff --git a/apps/files_trashbin/ajax/list.php b/apps/files_trashbin/ajax/list.php index a777bdcf124..46168f7865e 100644 --- a/apps/files_trashbin/ajax/list.php +++ b/apps/files_trashbin/ajax/list.php @@ -2,7 +2,6 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/ajax/preview.php b/apps/files_trashbin/ajax/preview.php index af86dafa496..c8bae2c5ce9 100644 --- a/apps/files_trashbin/ajax/preview.php +++ b/apps/files_trashbin/ajax/preview.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Georg Ehrke <georg@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -36,13 +35,13 @@ $scalingUp = array_key_exists('scalingup', $_GET) ? (bool) $_GET['scalingup'] : if($file === '') { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('core-preview', 'No file parameter was passed', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'No file parameter was passed', \OCP\Util::DEBUG); exit; } if($maxX === 0 || $maxY === 0) { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('core-preview', 'x and/or y set to 0', \OC_Log::DEBUG); + \OCP\Util::writeLog('core-preview', 'x and/or y set to 0', \OCP\Util::DEBUG); exit; } @@ -72,5 +71,5 @@ try{ $preview->showPreview(); }catch(\Exception $e) { \OC_Response::setStatus(500); - \OC_Log::write('core', $e->getmessage(), \OC_Log::DEBUG); + \OCP\Util::writeLog('core', $e->getmessage(), \OCP\Util::DEBUG); } diff --git a/apps/files_trashbin/ajax/undelete.php b/apps/files_trashbin/ajax/undelete.php index e7d8562f57d..8eda7a8d640 100644 --- a/apps/files_trashbin/ajax/undelete.php +++ b/apps/files_trashbin/ajax/undelete.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> @@ -71,7 +70,7 @@ foreach ($list as $file) { if ( !OCA\Files_Trashbin\Trashbin::restore($path, $filename, $timestamp) ) { $error[] = $filename; - OC_Log::write('trashbin', 'can\'t restore ' . $filename, OC_Log::ERROR); + \OCP\Util::writeLog('trashbin', 'can\'t restore ' . $filename, \OCP\Util::ERROR); } else { $success[$i]['filename'] = $file; $success[$i]['timestamp'] = $timestamp; diff --git a/apps/files_trashbin/appinfo/info.xml b/apps/files_trashbin/appinfo/info.xml index 8735b61e2db..f8bc5e7d3d2 100644 --- a/apps/files_trashbin/appinfo/info.xml +++ b/apps/files_trashbin/appinfo/info.xml @@ -18,5 +18,4 @@ To prevent a user from running out of disk space, the ownCloud Deleted files app <documentation> <user>user-trashbin</user> </documentation> - <ocsid>166052</ocsid> </info> diff --git a/apps/files_trashbin/appinfo/routes.php b/apps/files_trashbin/appinfo/routes.php index 526ad1d4e35..99a03d6b969 100644 --- a/apps/files_trashbin/appinfo/routes.php +++ b/apps/files_trashbin/appinfo/routes.php @@ -1,6 +1,7 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files_trashbin/appinfo/update.php b/apps/files_trashbin/appinfo/update.php index 94bd353eccc..e1a0cf95576 100644 --- a/apps/files_trashbin/appinfo/update.php +++ b/apps/files_trashbin/appinfo/update.php @@ -2,7 +2,6 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/appinfo/version b/apps/files_trashbin/appinfo/version index b6160487433..844f6a91acb 100644 --- a/apps/files_trashbin/appinfo/version +++ b/apps/files_trashbin/appinfo/version @@ -1 +1 @@ -0.6.2 +0.6.3 diff --git a/apps/files_trashbin/command/expire.php b/apps/files_trashbin/command/expire.php index e7dd5c573c2..89b949bbcdf 100644 --- a/apps/files_trashbin/command/expire.php +++ b/apps/files_trashbin/command/expire.php @@ -1,7 +1,10 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_trashbin/l10n/be.js b/apps/files_trashbin/l10n/be.js index 3ed1bc6464a..c72c72bbe91 100644 --- a/apps/files_trashbin/l10n/be.js +++ b/apps/files_trashbin/l10n/be.js @@ -3,4 +3,4 @@ OC.L10N.register( { "Error" : "Памылка" }, -"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); +"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);"); diff --git a/apps/files_trashbin/l10n/be.json b/apps/files_trashbin/l10n/be.json index 501bc5f7dfb..a2514254e13 100644 --- a/apps/files_trashbin/l10n/be.json +++ b/apps/files_trashbin/l10n/be.json @@ -1,4 +1,4 @@ { "translations": { "Error" : "Памылка" -},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" +},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);" }
\ No newline at end of file diff --git a/apps/files_trashbin/l10n/et_EE.js b/apps/files_trashbin/l10n/et_EE.js index 4e74390edb1..9298fdd5b18 100644 --- a/apps/files_trashbin/l10n/et_EE.js +++ b/apps/files_trashbin/l10n/et_EE.js @@ -9,6 +9,7 @@ OC.L10N.register( "Error" : "Viga", "restored" : "taastatud", "No deleted files" : "Kustutatud faile pole", + "You will be able to recover deleted files from here" : "Sa saad siit kustutatud faile taastada", "No entries found in this folder" : "Selles kaustas ei leitud kirjeid", "Select all" : "Vali kõik", "Name" : "Nimi", diff --git a/apps/files_trashbin/l10n/et_EE.json b/apps/files_trashbin/l10n/et_EE.json index fa3aab09ba1..734c8f6f2ec 100644 --- a/apps/files_trashbin/l10n/et_EE.json +++ b/apps/files_trashbin/l10n/et_EE.json @@ -7,6 +7,7 @@ "Error" : "Viga", "restored" : "taastatud", "No deleted files" : "Kustutatud faile pole", + "You will be able to recover deleted files from here" : "Sa saad siit kustutatud faile taastada", "No entries found in this folder" : "Selles kaustas ei leitud kirjeid", "Select all" : "Vali kõik", "Name" : "Nimi", diff --git a/apps/files_trashbin/l10n/zh_CN.js b/apps/files_trashbin/l10n/zh_CN.js index 8c9512b1d66..0ef17e35d62 100644 --- a/apps/files_trashbin/l10n/zh_CN.js +++ b/apps/files_trashbin/l10n/zh_CN.js @@ -8,6 +8,9 @@ OC.L10N.register( "Delete permanently" : "永久删除", "Error" : "错误", "restored" : "已恢复", + "No deleted files" : "无已删除文件", + "You will be able to recover deleted files from here" : "你可以在此处恢复已删除的文件", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Name" : "名称", "Deleted" : "已删除", diff --git a/apps/files_trashbin/l10n/zh_CN.json b/apps/files_trashbin/l10n/zh_CN.json index 895d235aadb..0349f643555 100644 --- a/apps/files_trashbin/l10n/zh_CN.json +++ b/apps/files_trashbin/l10n/zh_CN.json @@ -6,6 +6,9 @@ "Delete permanently" : "永久删除", "Error" : "错误", "restored" : "已恢复", + "No deleted files" : "无已删除文件", + "You will be able to recover deleted files from here" : "你可以在此处恢复已删除的文件", + "No entries found in this folder" : "此文件夹中无项目", "Select all" : "全部选择", "Name" : "名称", "Deleted" : "已删除", diff --git a/apps/files_trashbin/lib/helper.php b/apps/files_trashbin/lib/helper.php index 320ad2eeb8e..42412d5d4c9 100644 --- a/apps/files_trashbin/lib/helper.php +++ b/apps/files_trashbin/lib/helper.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/apps/files_trashbin/lib/trashbin.php b/apps/files_trashbin/lib/trashbin.php index b30ea7c69f8..2d4ea7adc13 100644 --- a/apps/files_trashbin/lib/trashbin.php +++ b/apps/files_trashbin/lib/trashbin.php @@ -5,13 +5,13 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Florin Peter <github@florin-peter.de> * @author Georg Ehrke <georg@owncloud.com> - * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Qingping Hou <dave2008713@gmail.com> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Sjors van der Pluijm <sjors@desjors.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> @@ -160,7 +160,7 @@ class Trashbin { $query = \OC_DB::prepare("INSERT INTO `*PREFIX*files_trash` (`id`,`timestamp`,`location`,`user`) VALUES (?,?,?,?)"); $result = $query->execute(array($ownerFilename, $timestamp, $ownerLocation, $owner)); if (!$result) { - \OC_Log::write('files_trashbin', 'trash bin database couldn\'t be updated for the files owner', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database couldn\'t be updated for the files owner', \OC_log::ERROR); } } } @@ -216,7 +216,7 @@ class Trashbin { if ($trashStorage->file_exists($trashInternalPath)) { $trashStorage->unlink($trashInternalPath); } - \OC_Log::write('files_trashbin', 'Couldn\'t move ' . $file_path . ' to the trash bin', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'Couldn\'t move ' . $file_path . ' to the trash bin', \OC_log::ERROR); } if ($sourceStorage->file_exists($sourceInternalPath)) { // failed to delete the original file, abort @@ -231,7 +231,7 @@ class Trashbin { $query = \OC_DB::prepare("INSERT INTO `*PREFIX*files_trash` (`id`,`timestamp`,`location`,`user`) VALUES (?,?,?,?)"); $result = $query->execute(array($filename, $timestamp, $location, $user)); if (!$result) { - \OC_Log::write('files_trashbin', 'trash bin database couldn\'t be updated', \OC_log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database couldn\'t be updated', \OC_log::ERROR); } \OCP\Util::emitHook('\OCA\Files_Trashbin\Trashbin', 'post_moveToTrash', array('filePath' => \OC\Files\Filesystem::normalizePath($file_path), 'trashPath' => \OC\Files\Filesystem::normalizePath($filename . '.d' . $timestamp))); @@ -358,7 +358,7 @@ class Trashbin { if ($timestamp) { $location = self::getLocation($user, $filename, $timestamp); if ($location === false) { - \OC_Log::write('files_trashbin', 'trash bin database inconsistent!', \OC_Log::ERROR); + \OCP\Util::writeLog('files_trashbin', 'trash bin database inconsistent!', \OCP\Util::ERROR); } else { // if location no longer exists, restore file in the root directory if ($location !== '/' && @@ -675,7 +675,7 @@ class Trashbin { foreach ($files as $file) { if ($availableSpace < 0) { $tmp = self::delete($file['name'], $user, $file['mtime']); - \OC_Log::write('files_trashbin', 'remove "' . $file['name'] . '" (' . $tmp . 'B) to meet the limit of trash bin size (50% of available quota)', \OC_log::INFO); + \OCP\Util::writeLog('files_trashbin', 'remove "' . $file['name'] . '" (' . $tmp . 'B) to meet the limit of trash bin size (50% of available quota)', \OC_log::INFO); $availableSpace += $tmp; $size += $tmp; } else { @@ -704,7 +704,7 @@ class Trashbin { if ($timestamp <= $limit) { $count++; $size += self::delete($filename, $user, $timestamp); - \OC_Log::write('files_trashbin', 'remove "' . $filename . '" from trash bin because it is older than ' . $retention_obligation, \OC_log::INFO); + \OCP\Util::writeLog('files_trashbin', 'remove "' . $filename . '" from trash bin because it is older than ' . $retention_obligation, \OCP\Util::INFO); } else { break; } diff --git a/apps/files_trashbin/list.php b/apps/files_trashbin/list.php index 68602ef8d8a..890f03aa09a 100644 --- a/apps/files_trashbin/list.php +++ b/apps/files_trashbin/list.php @@ -2,7 +2,6 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_trashbin/tests/trashbin.php b/apps/files_trashbin/tests/trashbin.php index 5535b3315bc..299c45b19a7 100644 --- a/apps/files_trashbin/tests/trashbin.php +++ b/apps/files_trashbin/tests/trashbin.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Clark Tomlinson <fallen013@gmail.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/apps/files_versions/ajax/preview.php b/apps/files_versions/ajax/preview.php index fab46abdc48..8a9a5fba14c 100644 --- a/apps/files_versions/ajax/preview.php +++ b/apps/files_versions/ajax/preview.php @@ -1,7 +1,6 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -34,13 +33,13 @@ $scalingUp = array_key_exists('scalingup', $_GET) ? (bool) $_GET['scalingup'] : if($file === '' && $version === '') { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('versions-preview', 'No file parameter was passed', \OC_Log::DEBUG); + \OCP\Util::writeLog('versions-preview', 'No file parameter was passed', \OCP\Util::DEBUG); exit; } if($maxX === 0 || $maxY === 0) { \OC_Response::setStatus(400); //400 Bad Request - \OC_Log::write('versions-preview', 'x and/or y set to 0', \OC_Log::DEBUG); + \OCP\Util::writeLog('versions-preview', 'x and/or y set to 0', \OCP\Util::DEBUG); exit; } @@ -56,5 +55,5 @@ try { $preview->showPreview(); }catch(\Exception $e) { \OC_Response::setStatus(500); - \OC_Log::write('core', $e->getmessage(), \OC_Log::DEBUG); + \OCP\Util::writeLog('core', $e->getmessage(), \OCP\Util::DEBUG); } diff --git a/apps/files_versions/ajax/rollbackVersion.php b/apps/files_versions/ajax/rollbackVersion.php index 3f4d78af82b..e75df28dbcd 100644 --- a/apps/files_versions/ajax/rollbackVersion.php +++ b/apps/files_versions/ajax/rollbackVersion.php @@ -4,7 +4,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Frank Karlitschek <frank@owncloud.org> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Sam Tuke <mail@samtuke.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/apps/files_versions/appinfo/app.php b/apps/files_versions/appinfo/app.php index 0705371b8f4..3bad0d8a94d 100644 --- a/apps/files_versions/appinfo/app.php +++ b/apps/files_versions/appinfo/app.php @@ -2,7 +2,6 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Frank Karlitschek <frank@owncloud.org> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/files_versions/appinfo/info.xml b/apps/files_versions/appinfo/info.xml index 9aed8069b9b..8eab29b0ec6 100644 --- a/apps/files_versions/appinfo/info.xml +++ b/apps/files_versions/appinfo/info.xml @@ -18,5 +18,4 @@ In addition to the expiry of versions, ownCloud’s versions app makes certain n <user>user-versions</user> </documentation> <default_enable/> - <ocsid>166053</ocsid> </info> diff --git a/apps/files_versions/appinfo/routes.php b/apps/files_versions/appinfo/routes.php index 0ea37d3b1b1..5dbed1f93eb 100644 --- a/apps/files_versions/appinfo/routes.php +++ b/apps/files_versions/appinfo/routes.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/apps/files_versions/appinfo/update.php b/apps/files_versions/appinfo/update.php index 6fa0fd6185f..524f9bd153f 100644 --- a/apps/files_versions/appinfo/update.php +++ b/apps/files_versions/appinfo/update.php @@ -1,7 +1,6 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/files_versions/appinfo/version b/apps/files_versions/appinfo/version index 90a27f9cea6..af0b7ddbffd 100644 --- a/apps/files_versions/appinfo/version +++ b/apps/files_versions/appinfo/version @@ -1 +1 @@ -1.0.5 +1.0.6 diff --git a/apps/files_versions/command/expire.php b/apps/files_versions/command/expire.php index ec9aa3e80d3..4492497f851 100644 --- a/apps/files_versions/command/expire.php +++ b/apps/files_versions/command/expire.php @@ -1,9 +1,24 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OCA\Files_Versions\Command; diff --git a/apps/files_versions/download.php b/apps/files_versions/download.php index 3cc324c2306..22a218f472a 100644 --- a/apps/files_versions/download.php +++ b/apps/files_versions/download.php @@ -1,5 +1,6 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Björn Schießle <schiessle@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/apps/files_versions/l10n/is.js b/apps/files_versions/l10n/is.js index 25bf6aafbfc..bbfe2f42ab3 100644 --- a/apps/files_versions/l10n/is.js +++ b/apps/files_versions/l10n/is.js @@ -3,4 +3,4 @@ OC.L10N.register( { "Versions" : "Útgáfur" }, -"nplurals=2; plural=(n != 1);"); +"nplurals=2; plural=(n % 10 == 1 || n % 100 != 11);"); diff --git a/apps/files_versions/l10n/is.json b/apps/files_versions/l10n/is.json index d21e4480909..11d9d3383bd 100644 --- a/apps/files_versions/l10n/is.json +++ b/apps/files_versions/l10n/is.json @@ -1,4 +1,4 @@ { "translations": { "Versions" : "Útgáfur" -},"pluralForm" :"nplurals=2; plural=(n != 1);" +},"pluralForm" :"nplurals=2; plural=(n % 10 == 1 || n % 100 != 11);" }
\ No newline at end of file diff --git a/apps/files_versions/l10n/ru.js b/apps/files_versions/l10n/ru.js index 74ad347804b..25248b9de5f 100644 --- a/apps/files_versions/l10n/ru.js +++ b/apps/files_versions/l10n/ru.js @@ -8,4 +8,4 @@ OC.L10N.register( "No other versions available" : "Других версий не доступно", "Restore" : "Откатить" }, -"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); +"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);"); diff --git a/apps/files_versions/l10n/ru.json b/apps/files_versions/l10n/ru.json index b21bd54331f..738bb332d23 100644 --- a/apps/files_versions/l10n/ru.json +++ b/apps/files_versions/l10n/ru.json @@ -5,5 +5,5 @@ "More versions..." : "Ещё версии...", "No other versions available" : "Других версий не доступно", "Restore" : "Откатить" -},"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" +},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);" }
\ No newline at end of file diff --git a/apps/files_versions/lib/storage.php b/apps/files_versions/lib/storage.php index 296cebfe058..e0034f6165f 100644 --- a/apps/files_versions/lib/storage.php +++ b/apps/files_versions/lib/storage.php @@ -5,6 +5,7 @@ * @author Felix Moeller <mail@felixmoeller.de> * @author Florin Peter <github@florin-peter.de> * @author Georg Ehrke <georg@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/apps/files_versions/tests/versions.php b/apps/files_versions/tests/versions.php index 0b6bfc698d7..7cca409ed6c 100644 --- a/apps/files_versions/tests/versions.php +++ b/apps/files_versions/tests/versions.php @@ -4,7 +4,9 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/provisioning_api/appinfo/app.php b/apps/provisioning_api/appinfo/app.php index 33dfda9e6e9..bb5c541c4fd 100644 --- a/apps/provisioning_api/appinfo/app.php +++ b/apps/provisioning_api/appinfo/app.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/provisioning_api/appinfo/routes.php b/apps/provisioning_api/appinfo/routes.php index 87f073f82b0..323c8d609c7 100644 --- a/apps/provisioning_api/appinfo/routes.php +++ b/apps/provisioning_api/appinfo/routes.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> * diff --git a/apps/provisioning_api/lib/apps.php b/apps/provisioning_api/lib/apps.php index 2bafd06a084..22713865c1e 100644 --- a/apps/provisioning_api/lib/apps.php +++ b/apps/provisioning_api/lib/apps.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> * diff --git a/apps/provisioning_api/lib/groups.php b/apps/provisioning_api/lib/groups.php index cd156110635..81a5a6e5c30 100644 --- a/apps/provisioning_api/lib/groups.php +++ b/apps/provisioning_api/lib/groups.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> * @@ -62,7 +63,7 @@ class Groups{ // Validate name $groupid = isset($_POST['groupid']) ? $_POST['groupid'] : ''; if( preg_match( '/[^a-zA-Z0-9 _\.@\-]/', $groupid ) || empty($groupid)){ - \OC_Log::write('provisioning_api', 'Attempt made to create group using invalid characters.', \OC_Log::ERROR); + \OCP\Util::writeLog('provisioning_api', 'Attempt made to create group using invalid characters.', \OCP\Util::ERROR); return new OC_OCS_Result(null, 101, 'Invalid group name'); } // Check if it exists diff --git a/apps/provisioning_api/lib/users.php b/apps/provisioning_api/lib/users.php index b709e09726d..fada85b293d 100644 --- a/apps/provisioning_api/lib/users.php +++ b/apps/provisioning_api/lib/users.php @@ -1,6 +1,9 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Roeland Jago Douma <roeland@famdouma.nl> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tom Needham <tom@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -45,15 +48,15 @@ class Users { $userId = isset($_POST['userid']) ? $_POST['userid'] : null; $password = isset($_POST['password']) ? $_POST['password'] : null; if(OC_User::userExists($userId)) { - \OC_Log::write('ocs_api', 'Failed addUser attempt: User already exists.', \OC_Log::ERROR); + \OCP\Util::writeLog('ocs_api', 'Failed addUser attempt: User already exists.', \OCP\Util::ERROR); return new OC_OCS_Result(null, 102, 'User already exists'); } else { try { OC_User::createUser($userId, $password); - \OC_Log::write('ocs_api', 'Successful addUser call with userid: '.$_POST['userid'], \OC_Log::INFO); + \OCP\Util::writeLog('ocs_api', 'Successful addUser call with userid: '.$_POST['userid'], \OCP\Util::INFO); return new OC_OCS_Result(null, 100); } catch (\Exception $e) { - \OC_Log::write('ocs_api', 'Failed addUser attempt with exception: '.$e->getMessage(), \OC_Log::ERROR); + \OCP\Util::writeLog('ocs_api', 'Failed addUser attempt with exception: '.$e->getMessage(), \OCP\Util::ERROR); return new OC_OCS_Result(null, 101, 'Bad request'); } } diff --git a/apps/provisioning_api/tests/appstest.php b/apps/provisioning_api/tests/appstest.php index 94bff8bbf5b..c4298f017fc 100644 --- a/apps/provisioning_api/tests/appstest.php +++ b/apps/provisioning_api/tests/appstest.php @@ -3,6 +3,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/provisioning_api/tests/groupstest.php b/apps/provisioning_api/tests/groupstest.php index cb677d9b512..b8b02790698 100644 --- a/apps/provisioning_api/tests/groupstest.php +++ b/apps/provisioning_api/tests/groupstest.php @@ -3,6 +3,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/provisioning_api/tests/userstest.php b/apps/provisioning_api/tests/userstest.php index 0ba76355d58..f2862565039 100644 --- a/apps/provisioning_api/tests/userstest.php +++ b/apps/provisioning_api/tests/userstest.php @@ -2,7 +2,10 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Roeland Jago Douma <roeland@famdouma.nl> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tom Needham <tom@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/user_ldap/ajax/getNewServerConfigPrefix.php b/apps/user_ldap/ajax/getNewServerConfigPrefix.php index 897e4a9924f..41a061e6c50 100644 --- a/apps/user_ldap/ajax/getNewServerConfigPrefix.php +++ b/apps/user_ldap/ajax/getNewServerConfigPrefix.php @@ -1,7 +1,6 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> - * @author Christopher Schäpers <kondou@ts.unde.re> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/user_ldap/appinfo/info.xml b/apps/user_ldap/appinfo/info.xml index 88462902421..89c1a4ea3ff 100644 --- a/apps/user_ldap/appinfo/info.xml +++ b/apps/user_ldap/appinfo/info.xml @@ -17,7 +17,6 @@ A user logs into ownCloud with their LDAP or AD credentials, and is granted acce <documentation> <admin>admin-ldap</admin> </documentation> - <ocsid>166061</ocsid> <dependencies> <lib>ldap</lib> </dependencies> diff --git a/apps/user_ldap/appinfo/install.php b/apps/user_ldap/appinfo/install.php index bc43466bc1a..0b3f84b8baf 100644 --- a/apps/user_ldap/appinfo/install.php +++ b/apps/user_ldap/appinfo/install.php @@ -2,7 +2,6 @@ /** * @author Arthur Schiwon <blizzz@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/user_ldap/appinfo/version b/apps/user_ldap/appinfo/version index a918a2aa18d..ee6cdce3c29 100644 --- a/apps/user_ldap/appinfo/version +++ b/apps/user_ldap/appinfo/version @@ -1 +1 @@ -0.6.0 +0.6.1 diff --git a/apps/user_ldap/group_ldap.php b/apps/user_ldap/group_ldap.php index 0395a4a80e3..a7a90c75832 100644 --- a/apps/user_ldap/group_ldap.php +++ b/apps/user_ldap/group_ldap.php @@ -378,9 +378,11 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { && intval($this->access->connection->useMemberOfToDetectMembership) === 1 ) { $groupDNs = $this->access->readAttribute($userDN, 'memberOf'); + if (is_array($groupDNs)) { + $groupDNs = $this->access->groupsMatchFilter($groupDNs); foreach ($groupDNs as $dn) { - $groups[] = $this->access->dn2groupname($dn);; + $groups[] = $this->access->dn2groupname($dn); } } if($primaryGroup !== false) { diff --git a/apps/user_ldap/l10n/cs_CZ.js b/apps/user_ldap/l10n/cs_CZ.js index b3896f7e9bd..20269d7c406 100644 --- a/apps/user_ldap/l10n/cs_CZ.js +++ b/apps/user_ldap/l10n/cs_CZ.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Ověřit nastavení", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Přidá novou prázdnou konfiguraci", + "Add a new and blank configuration" : "Přidat novou a prázdnou konfiguraci", "Copy current configuration into new directory binding" : "Zkopírovat současnou konfiguraci do nového adresářového propojení", "Delete the current configuration" : "Smazat současnou konfiguraci", "Host" : "Počítač", diff --git a/apps/user_ldap/l10n/cs_CZ.json b/apps/user_ldap/l10n/cs_CZ.json index aaf10d22f9c..776290918db 100644 --- a/apps/user_ldap/l10n/cs_CZ.json +++ b/apps/user_ldap/l10n/cs_CZ.json @@ -76,7 +76,7 @@ "Verify settings" : "Ověřit nastavení", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Přidá novou prázdnou konfiguraci", + "Add a new and blank configuration" : "Přidat novou a prázdnou konfiguraci", "Copy current configuration into new directory binding" : "Zkopírovat současnou konfiguraci do nového adresářového propojení", "Delete the current configuration" : "Smazat současnou konfiguraci", "Host" : "Počítač", diff --git a/apps/user_ldap/l10n/da.js b/apps/user_ldap/l10n/da.js index 8b619bf4803..d029ed1b994 100644 --- a/apps/user_ldap/l10n/da.js +++ b/apps/user_ldap/l10n/da.js @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Verificér indstillinger", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Tilføjer en ny og blank konfiguration", "Copy current configuration into new directory binding" : "Kopiér nuværende konfiguration ind i en ny mappetildeling", "Delete the current configuration" : "Slet den aktuelle konfiguration", "Host" : "Vært", diff --git a/apps/user_ldap/l10n/da.json b/apps/user_ldap/l10n/da.json index 1311710c5c6..28bcfad508f 100644 --- a/apps/user_ldap/l10n/da.json +++ b/apps/user_ldap/l10n/da.json @@ -76,7 +76,6 @@ "Verify settings" : "Verificér indstillinger", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Tilføjer en ny og blank konfiguration", "Copy current configuration into new directory binding" : "Kopiér nuværende konfiguration ind i en ny mappetildeling", "Delete the current configuration" : "Slet den aktuelle konfiguration", "Host" : "Vært", diff --git a/apps/user_ldap/l10n/de.js b/apps/user_ldap/l10n/de.js index 1a2d1de62d4..e25b3cb10a8 100644 --- a/apps/user_ldap/l10n/de.js +++ b/apps/user_ldap/l10n/de.js @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Einstellungen überprüfen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Fügt eine neue und leere Konfiguration hinzu", "Copy current configuration into new directory binding" : "Aktuelle Konfiguration in eine neues Verzeichnis-Bind kopieren", "Delete the current configuration" : "Aktuelle Konfiguration löschen", "Host" : "Host", diff --git a/apps/user_ldap/l10n/de.json b/apps/user_ldap/l10n/de.json index 7a4843900c8..845d382af36 100644 --- a/apps/user_ldap/l10n/de.json +++ b/apps/user_ldap/l10n/de.json @@ -76,7 +76,6 @@ "Verify settings" : "Einstellungen überprüfen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Fügt eine neue und leere Konfiguration hinzu", "Copy current configuration into new directory binding" : "Aktuelle Konfiguration in eine neues Verzeichnis-Bind kopieren", "Delete the current configuration" : "Aktuelle Konfiguration löschen", "Host" : "Host", diff --git a/apps/user_ldap/l10n/de_DE.js b/apps/user_ldap/l10n/de_DE.js index b2dc48efca6..6880c5f1b70 100644 --- a/apps/user_ldap/l10n/de_DE.js +++ b/apps/user_ldap/l10n/de_DE.js @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Einstellungen überprüfen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Fügt eine neue und leere Konfiguration hinzu", "Copy current configuration into new directory binding" : "Aktuelle Konfiguration in eine neues Verzeichnis-Bind kopieren ", "Delete the current configuration" : "Aktuelle Konfiguration löschen", "Host" : "Host", diff --git a/apps/user_ldap/l10n/de_DE.json b/apps/user_ldap/l10n/de_DE.json index e58f29a0b60..61644710a34 100644 --- a/apps/user_ldap/l10n/de_DE.json +++ b/apps/user_ldap/l10n/de_DE.json @@ -76,7 +76,6 @@ "Verify settings" : "Einstellungen überprüfen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Fügt eine neue und leere Konfiguration hinzu", "Copy current configuration into new directory binding" : "Aktuelle Konfiguration in eine neues Verzeichnis-Bind kopieren ", "Delete the current configuration" : "Aktuelle Konfiguration löschen", "Host" : "Host", diff --git a/apps/user_ldap/l10n/el.js b/apps/user_ldap/l10n/el.js index c8207dbabfe..610fcc5af03 100644 --- a/apps/user_ldap/l10n/el.js +++ b/apps/user_ldap/l10n/el.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Επιβεβαίωση ρυθμίσεων", "1. Server" : "1. Διακομιστής", "%s. Server:" : "%s. Διακομιστής:", - "Adds a new and blank configuration" : "Προσθέτει μια νέα και κενή διαμόρφωση", + "Add a new and blank configuration" : "Προσθέτει μια νέα και κενή διαμόρφωση", "Copy current configuration into new directory binding" : "Αντιγραφή της τρέχουσας διαμόρφωσης σε νέο κατάλογο", "Delete the current configuration" : "Διαγραφή τρέχουσας διαμόρφωσης", "Host" : "Διακομιστής", diff --git a/apps/user_ldap/l10n/el.json b/apps/user_ldap/l10n/el.json index 1e861ba8f82..03dbf973b55 100644 --- a/apps/user_ldap/l10n/el.json +++ b/apps/user_ldap/l10n/el.json @@ -76,7 +76,7 @@ "Verify settings" : "Επιβεβαίωση ρυθμίσεων", "1. Server" : "1. Διακομιστής", "%s. Server:" : "%s. Διακομιστής:", - "Adds a new and blank configuration" : "Προσθέτει μια νέα και κενή διαμόρφωση", + "Add a new and blank configuration" : "Προσθέτει μια νέα και κενή διαμόρφωση", "Copy current configuration into new directory binding" : "Αντιγραφή της τρέχουσας διαμόρφωσης σε νέο κατάλογο", "Delete the current configuration" : "Διαγραφή τρέχουσας διαμόρφωσης", "Host" : "Διακομιστής", diff --git a/apps/user_ldap/l10n/en_GB.js b/apps/user_ldap/l10n/en_GB.js index baeed9a85ea..6bd17dcba4d 100644 --- a/apps/user_ldap/l10n/en_GB.js +++ b/apps/user_ldap/l10n/en_GB.js @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Verify settings", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Adds a new and blank configuration", "Copy current configuration into new directory binding" : "Copy current configuration into new directory binding", "Delete the current configuration" : "Delete the current configuration", "Host" : "Host", diff --git a/apps/user_ldap/l10n/en_GB.json b/apps/user_ldap/l10n/en_GB.json index 743ae2cd47f..8c19e37154b 100644 --- a/apps/user_ldap/l10n/en_GB.json +++ b/apps/user_ldap/l10n/en_GB.json @@ -76,7 +76,6 @@ "Verify settings" : "Verify settings", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Adds a new and blank configuration", "Copy current configuration into new directory binding" : "Copy current configuration into new directory binding", "Delete the current configuration" : "Delete the current configuration", "Host" : "Host", diff --git a/apps/user_ldap/l10n/es.js b/apps/user_ldap/l10n/es.js index 373c173f6db..02a45f1b444 100644 --- a/apps/user_ldap/l10n/es.js +++ b/apps/user_ldap/l10n/es.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Verificar configuración", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Añade una configuración nueva y vacía", + "Add a new and blank configuration" : "Agregar una configuración nueva y en blanco", "Copy current configuration into new directory binding" : "Copiar la actual configuración en un nuevo directorio de enlace", "Delete the current configuration" : "Elimina la actual configuración", "Host" : "Servidor", diff --git a/apps/user_ldap/l10n/es.json b/apps/user_ldap/l10n/es.json index 10f8e38c131..f836e54c067 100644 --- a/apps/user_ldap/l10n/es.json +++ b/apps/user_ldap/l10n/es.json @@ -76,7 +76,7 @@ "Verify settings" : "Verificar configuración", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Añade una configuración nueva y vacía", + "Add a new and blank configuration" : "Agregar una configuración nueva y en blanco", "Copy current configuration into new directory binding" : "Copiar la actual configuración en un nuevo directorio de enlace", "Delete the current configuration" : "Elimina la actual configuración", "Host" : "Servidor", diff --git a/apps/user_ldap/l10n/fr.js b/apps/user_ldap/l10n/fr.js index 3e548f717fb..9b0e871c9f0 100644 --- a/apps/user_ldap/l10n/fr.js +++ b/apps/user_ldap/l10n/fr.js @@ -27,7 +27,7 @@ OC.L10N.register( "More than 1.000 directory entries available." : "Il y a plus de 1000 entrées de répertoire disponibles.", " entries available within the provided Base DN" : "entrées disponibles dans le DN de base spécifié", "An error occurred. Please check the Base DN, as well as connection settings and credentials." : "Une erreur est survenue. Veuillez vérifier le DN de base, ainsi que les paramètres de connexion et les informations d'identification", - "Do you really want to delete the current Server Configuration?" : "Êtes-vous vraiment sûr de vouloir effacer la configuration actuelle du serveur ?", + "Do you really want to delete the current Server Configuration?" : "Êtes-vous sûr de vouloir effacer la configuration serveur actuelle ?", "Confirm Deletion" : "Confirmer la suppression", "Mappings cleared successfully!" : "Associations supprimées avec succès !", "Error while clearing the mappings." : "Erreur lors de la suppression des associations.", @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Tester les paramètres", "1. Server" : "1. Serveur", "%s. Server:" : "%s. Serveur :", - "Adds a new and blank configuration" : "Ajouter une nouvelle configuration vierge", "Copy current configuration into new directory binding" : "Copier la configuration actuelle vers une nouvelle", "Delete the current configuration" : "Supprimer la configuration actuelle", "Host" : "Hôte", @@ -94,10 +93,10 @@ OC.L10N.register( "Detect Base DN" : "Détecter le DN de base", "Test Base DN" : "Tester le DN de base", "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Évite les requêtes LDAP automatiques. Mieux pour les installations de grande ampleur, mais demande des connaissances en LDAP.", - "Manually enter LDAP filters (recommended for large directories)" : "Entrée manuelle des filtres LDAP (recommandé pour les annuaires de grande ampleur)", + "Manually enter LDAP filters (recommended for large directories)" : "Saisir les filtres LDAP manuellement (recommandé pour les annuaires de grande ampleur)", "Limit %s access to users meeting these criteria:" : "Limiter l'accès à %s aux utilisateurs respectant ces critères :", "The most common object classes for users are organizationalPerson, person, user, and inetOrgPerson. If you are not sure which object class to select, please consult your directory admin." : "Les classes d'objets fréquentes pour les utilisateurs sont : organizationalPerson, person, user et inetOrgPerson. Si vous n'êtes pas sûr de la classe à utiliser, demandez à l'administrateur de l'annuaire.", - "The filter specifies which LDAP users shall have access to the %s instance." : "Le filtre spécifie quels utilisateurs LDAP doivent avoir accès à l'instance %s.", + "The filter specifies which LDAP users shall have access to the %s instance." : "Le filtre spécifie quels utilisateurs LDAP auront accès à l'instance %s.", "Verify settings and count users" : "Vérifier les paramètres et compter les utilisateurs", "Saving" : "Enregistrement...", "Back" : "Retour", diff --git a/apps/user_ldap/l10n/fr.json b/apps/user_ldap/l10n/fr.json index a9119e0025d..6fb93d618e1 100644 --- a/apps/user_ldap/l10n/fr.json +++ b/apps/user_ldap/l10n/fr.json @@ -25,7 +25,7 @@ "More than 1.000 directory entries available." : "Il y a plus de 1000 entrées de répertoire disponibles.", " entries available within the provided Base DN" : "entrées disponibles dans le DN de base spécifié", "An error occurred. Please check the Base DN, as well as connection settings and credentials." : "Une erreur est survenue. Veuillez vérifier le DN de base, ainsi que les paramètres de connexion et les informations d'identification", - "Do you really want to delete the current Server Configuration?" : "Êtes-vous vraiment sûr de vouloir effacer la configuration actuelle du serveur ?", + "Do you really want to delete the current Server Configuration?" : "Êtes-vous sûr de vouloir effacer la configuration serveur actuelle ?", "Confirm Deletion" : "Confirmer la suppression", "Mappings cleared successfully!" : "Associations supprimées avec succès !", "Error while clearing the mappings." : "Erreur lors de la suppression des associations.", @@ -76,7 +76,6 @@ "Verify settings" : "Tester les paramètres", "1. Server" : "1. Serveur", "%s. Server:" : "%s. Serveur :", - "Adds a new and blank configuration" : "Ajouter une nouvelle configuration vierge", "Copy current configuration into new directory binding" : "Copier la configuration actuelle vers une nouvelle", "Delete the current configuration" : "Supprimer la configuration actuelle", "Host" : "Hôte", @@ -92,10 +91,10 @@ "Detect Base DN" : "Détecter le DN de base", "Test Base DN" : "Tester le DN de base", "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Évite les requêtes LDAP automatiques. Mieux pour les installations de grande ampleur, mais demande des connaissances en LDAP.", - "Manually enter LDAP filters (recommended for large directories)" : "Entrée manuelle des filtres LDAP (recommandé pour les annuaires de grande ampleur)", + "Manually enter LDAP filters (recommended for large directories)" : "Saisir les filtres LDAP manuellement (recommandé pour les annuaires de grande ampleur)", "Limit %s access to users meeting these criteria:" : "Limiter l'accès à %s aux utilisateurs respectant ces critères :", "The most common object classes for users are organizationalPerson, person, user, and inetOrgPerson. If you are not sure which object class to select, please consult your directory admin." : "Les classes d'objets fréquentes pour les utilisateurs sont : organizationalPerson, person, user et inetOrgPerson. Si vous n'êtes pas sûr de la classe à utiliser, demandez à l'administrateur de l'annuaire.", - "The filter specifies which LDAP users shall have access to the %s instance." : "Le filtre spécifie quels utilisateurs LDAP doivent avoir accès à l'instance %s.", + "The filter specifies which LDAP users shall have access to the %s instance." : "Le filtre spécifie quels utilisateurs LDAP auront accès à l'instance %s.", "Verify settings and count users" : "Vérifier les paramètres et compter les utilisateurs", "Saving" : "Enregistrement...", "Back" : "Retour", diff --git a/apps/user_ldap/l10n/gl.js b/apps/user_ldap/l10n/gl.js index 466144f4123..6ab06bb4b94 100644 --- a/apps/user_ldap/l10n/gl.js +++ b/apps/user_ldap/l10n/gl.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Verificar os axustes", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Engade unha configuración nova e en branco", + "Add a new and blank configuration" : "Engadir unha configuración nova e en branco", "Copy current configuration into new directory binding" : "Copiar a configuración no novo directorio vinculado", "Delete the current configuration" : "Eliminar a configuración actual", "Host" : "Máquina", diff --git a/apps/user_ldap/l10n/gl.json b/apps/user_ldap/l10n/gl.json index f67cc44d653..b1e4ffc05ce 100644 --- a/apps/user_ldap/l10n/gl.json +++ b/apps/user_ldap/l10n/gl.json @@ -76,7 +76,7 @@ "Verify settings" : "Verificar os axustes", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Engade unha configuración nova e en branco", + "Add a new and blank configuration" : "Engadir unha configuración nova e en branco", "Copy current configuration into new directory binding" : "Copiar a configuración no novo directorio vinculado", "Delete the current configuration" : "Eliminar a configuración actual", "Host" : "Máquina", diff --git a/apps/user_ldap/l10n/it.js b/apps/user_ldap/l10n/it.js index 55c1abb333f..80bdfdc177e 100644 --- a/apps/user_ldap/l10n/it.js +++ b/apps/user_ldap/l10n/it.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Verifica impostazioni", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Aggiunge una nuova configurazione", + "Add a new and blank configuration" : "Aggiunge una nuova configurazione vuota", "Copy current configuration into new directory binding" : "Copia la configurazione attuale nella nuova cartella associata", "Delete the current configuration" : "Elimina la configurazione attuale", "Host" : "Host", diff --git a/apps/user_ldap/l10n/it.json b/apps/user_ldap/l10n/it.json index 9bf6de0e336..8eea02f2c85 100644 --- a/apps/user_ldap/l10n/it.json +++ b/apps/user_ldap/l10n/it.json @@ -76,7 +76,7 @@ "Verify settings" : "Verifica impostazioni", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Aggiunge una nuova configurazione", + "Add a new and blank configuration" : "Aggiunge una nuova configurazione vuota", "Copy current configuration into new directory binding" : "Copia la configurazione attuale nella nuova cartella associata", "Delete the current configuration" : "Elimina la configurazione attuale", "Host" : "Host", diff --git a/apps/user_ldap/l10n/ja.js b/apps/user_ldap/l10n/ja.js index a6218138d5b..259f9facbd2 100644 --- a/apps/user_ldap/l10n/ja.js +++ b/apps/user_ldap/l10n/ja.js @@ -115,7 +115,7 @@ OC.L10N.register( "User Home Folder Naming Rule" : "ユーザーのホームフォルダー命名規則", "Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." : "ユーザー名を空のままにしてください(デフォルト)。もしくは、LDAPもしくはADの属性を指定してください。", "Internal Username" : "内部ユーザー名", - "By default the internal username will be created from the UUID attribute. It makes sure that the username is unique and characters do not need to be converted. The internal username has the restriction that only these characters are allowed: [ a-zA-Z0-9_.@- ]. Other characters are replaced with their ASCII correspondence or simply omitted. On collisions a number will be added/increased. The internal username is used to identify a user internally. It is also the default name for the user home folder. It is also a part of remote URLs, for instance for all *DAV services. With this setting, the default behavior can be overridden. To achieve a similar behavior as before ownCloud 5 enter the user display name attribute in the following field. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users." : "デフォルトでは、内部的なユーザー名がUUID属性から作成されます。これにより、ユーザー名がユニークであり、かつ文字の変換が不要であることを保証します。内部ユーザー名には、[ a-zA-Z0-9_.@- ] の文字のみが有効であるという制限があり、その他の文字は対応する ASCII コードに変換されるか単に無視されます。そのため、他のユーザ名との衝突の回数が増加するでしょう。内部ユーザー名は、内部的にユーザを識別するために用いられ、また、ownCloudにおけるデフォルトのホームフォルダー名としても用いられます。例えば*DAVサービスのように、リモートURLの一部でもあります。この設定により、デフォルトの振る舞いを再定義します。ownCloud 5 以前と同じような振る舞いにするためには、以下のフィールドにユーザー表示名の属性を入力します。空にするとデフォルトの振る舞いとなります。変更は新しくマッピング(追加)されたLDAPユーザーにおいてのみ有効となります。", + "By default the internal username will be created from the UUID attribute. It makes sure that the username is unique and characters do not need to be converted. The internal username has the restriction that only these characters are allowed: [ a-zA-Z0-9_.@- ]. Other characters are replaced with their ASCII correspondence or simply omitted. On collisions a number will be added/increased. The internal username is used to identify a user internally. It is also the default name for the user home folder. It is also a part of remote URLs, for instance for all *DAV services. With this setting, the default behavior can be overridden. To achieve a similar behavior as before ownCloud 5 enter the user display name attribute in the following field. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users." : "デフォルトでは、内部的なユーザー名がUUID属性から作成されます。これにより、ユーザー名がユニークであり、かつ文字の変換が不要であることを保証します。内部ユーザー名には、[ a-zA-Z0-9_.@- ] の文字のみが有効であるという制限があり、その他の文字は対応する ASCII コードに変換されるか単に無視されます。そのため、他のユーザー名との衝突の回数が増加するでしょう。内部ユーザー名は、内部的にユーザーを識別するために用いられ、また、ownCloudにおけるデフォルトのホームフォルダー名としても用いられます。例えば*DAVサービスのように、リモートURLの一部でもあります。この設定により、デフォルトの振る舞いを再定義します。ownCloud 5 以前と同じような振る舞いにするためには、以下のフィールドにユーザー表示名の属性を入力します。空にするとデフォルトの振る舞いとなります。変更は新しくマッピング(追加)されたLDAPユーザーにおいてのみ有効となります。", "Internal Username Attribute:" : "内部ユーザー名属性:", "Override UUID detection" : "UUID検出を再定義する", "By default, the UUID attribute is automatically detected. The UUID attribute is used to doubtlessly identify LDAP users and groups. Also, the internal username will be created based on the UUID, if not specified otherwise above. You can override the setting and pass an attribute of your choice. You must make sure that the attribute of your choice can be fetched for both users and groups and it is unique. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users and groups." : "デフォルトでは、UUID 属性は自動的に検出されます。UUID属性は、LDAPユーザーとLDAPグループを間違いなく識別するために利用されます。また、もしこれを指定しない場合は、内部ユーザー名はUUIDに基づいて作成されます。この設定は再定義することができ、あなたの選択した属性を用いることができます。選択した属性がユーザーとグループの両方に対して適用でき、かつユニークであることを確認してください。空であればデフォルトの振る舞いとなります。変更は、新しくマッピング(追加)されたLDAPユーザーとLDAPグループに対してのみ有効となります。", diff --git a/apps/user_ldap/l10n/ja.json b/apps/user_ldap/l10n/ja.json index 8b7d8389b9a..3dceb217eb6 100644 --- a/apps/user_ldap/l10n/ja.json +++ b/apps/user_ldap/l10n/ja.json @@ -113,7 +113,7 @@ "User Home Folder Naming Rule" : "ユーザーのホームフォルダー命名規則", "Leave empty for user name (default). Otherwise, specify an LDAP/AD attribute." : "ユーザー名を空のままにしてください(デフォルト)。もしくは、LDAPもしくはADの属性を指定してください。", "Internal Username" : "内部ユーザー名", - "By default the internal username will be created from the UUID attribute. It makes sure that the username is unique and characters do not need to be converted. The internal username has the restriction that only these characters are allowed: [ a-zA-Z0-9_.@- ]. Other characters are replaced with their ASCII correspondence or simply omitted. On collisions a number will be added/increased. The internal username is used to identify a user internally. It is also the default name for the user home folder. It is also a part of remote URLs, for instance for all *DAV services. With this setting, the default behavior can be overridden. To achieve a similar behavior as before ownCloud 5 enter the user display name attribute in the following field. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users." : "デフォルトでは、内部的なユーザー名がUUID属性から作成されます。これにより、ユーザー名がユニークであり、かつ文字の変換が不要であることを保証します。内部ユーザー名には、[ a-zA-Z0-9_.@- ] の文字のみが有効であるという制限があり、その他の文字は対応する ASCII コードに変換されるか単に無視されます。そのため、他のユーザ名との衝突の回数が増加するでしょう。内部ユーザー名は、内部的にユーザを識別するために用いられ、また、ownCloudにおけるデフォルトのホームフォルダー名としても用いられます。例えば*DAVサービスのように、リモートURLの一部でもあります。この設定により、デフォルトの振る舞いを再定義します。ownCloud 5 以前と同じような振る舞いにするためには、以下のフィールドにユーザー表示名の属性を入力します。空にするとデフォルトの振る舞いとなります。変更は新しくマッピング(追加)されたLDAPユーザーにおいてのみ有効となります。", + "By default the internal username will be created from the UUID attribute. It makes sure that the username is unique and characters do not need to be converted. The internal username has the restriction that only these characters are allowed: [ a-zA-Z0-9_.@- ]. Other characters are replaced with their ASCII correspondence or simply omitted. On collisions a number will be added/increased. The internal username is used to identify a user internally. It is also the default name for the user home folder. It is also a part of remote URLs, for instance for all *DAV services. With this setting, the default behavior can be overridden. To achieve a similar behavior as before ownCloud 5 enter the user display name attribute in the following field. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users." : "デフォルトでは、内部的なユーザー名がUUID属性から作成されます。これにより、ユーザー名がユニークであり、かつ文字の変換が不要であることを保証します。内部ユーザー名には、[ a-zA-Z0-9_.@- ] の文字のみが有効であるという制限があり、その他の文字は対応する ASCII コードに変換されるか単に無視されます。そのため、他のユーザー名との衝突の回数が増加するでしょう。内部ユーザー名は、内部的にユーザーを識別するために用いられ、また、ownCloudにおけるデフォルトのホームフォルダー名としても用いられます。例えば*DAVサービスのように、リモートURLの一部でもあります。この設定により、デフォルトの振る舞いを再定義します。ownCloud 5 以前と同じような振る舞いにするためには、以下のフィールドにユーザー表示名の属性を入力します。空にするとデフォルトの振る舞いとなります。変更は新しくマッピング(追加)されたLDAPユーザーにおいてのみ有効となります。", "Internal Username Attribute:" : "内部ユーザー名属性:", "Override UUID detection" : "UUID検出を再定義する", "By default, the UUID attribute is automatically detected. The UUID attribute is used to doubtlessly identify LDAP users and groups. Also, the internal username will be created based on the UUID, if not specified otherwise above. You can override the setting and pass an attribute of your choice. You must make sure that the attribute of your choice can be fetched for both users and groups and it is unique. Leave it empty for default behavior. Changes will have effect only on newly mapped (added) LDAP users and groups." : "デフォルトでは、UUID 属性は自動的に検出されます。UUID属性は、LDAPユーザーとLDAPグループを間違いなく識別するために利用されます。また、もしこれを指定しない場合は、内部ユーザー名はUUIDに基づいて作成されます。この設定は再定義することができ、あなたの選択した属性を用いることができます。選択した属性がユーザーとグループの両方に対して適用でき、かつユニークであることを確認してください。空であればデフォルトの振る舞いとなります。変更は、新しくマッピング(追加)されたLDAPユーザーとLDAPグループに対してのみ有効となります。", diff --git a/apps/user_ldap/l10n/nb_NO.js b/apps/user_ldap/l10n/nb_NO.js index c969be1ce75..25670ce73a8 100644 --- a/apps/user_ldap/l10n/nb_NO.js +++ b/apps/user_ldap/l10n/nb_NO.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Sjekk innstillinger", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Legger til en ny tom konfigurasjon", + "Add a new and blank configuration" : "Legg til en ny tom konfigurasjon", "Copy current configuration into new directory binding" : "Kopier gjeldende konfigurasjon til ny katalogbinding", "Delete the current configuration" : "Slett gjeldende konfigurasjon", "Host" : "Tjener", diff --git a/apps/user_ldap/l10n/nb_NO.json b/apps/user_ldap/l10n/nb_NO.json index 7a34b813ad8..588c9f6c213 100644 --- a/apps/user_ldap/l10n/nb_NO.json +++ b/apps/user_ldap/l10n/nb_NO.json @@ -76,7 +76,7 @@ "Verify settings" : "Sjekk innstillinger", "1. Server" : "1. server", "%s. Server:" : "%s. server:", - "Adds a new and blank configuration" : "Legger til en ny tom konfigurasjon", + "Add a new and blank configuration" : "Legg til en ny tom konfigurasjon", "Copy current configuration into new directory binding" : "Kopier gjeldende konfigurasjon til ny katalogbinding", "Delete the current configuration" : "Slett gjeldende konfigurasjon", "Host" : "Tjener", diff --git a/apps/user_ldap/l10n/nl.js b/apps/user_ldap/l10n/nl.js index 7e72b002a87..b12f3a02424 100644 --- a/apps/user_ldap/l10n/nl.js +++ b/apps/user_ldap/l10n/nl.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Verifiëren instellingen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Toevoegen blanco nieuwe configuratie", + "Add a new and blank configuration" : "Toevoegen nieuwe, blanco configuratie", "Copy current configuration into new directory binding" : "Kopieer de huidige configuratie naar een nieuwe directory binding", "Delete the current configuration" : "Verwijder de huidige configuratie", "Host" : "Host", diff --git a/apps/user_ldap/l10n/nl.json b/apps/user_ldap/l10n/nl.json index 415454da435..1b7b665781a 100644 --- a/apps/user_ldap/l10n/nl.json +++ b/apps/user_ldap/l10n/nl.json @@ -76,7 +76,7 @@ "Verify settings" : "Verifiëren instellingen", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Toevoegen blanco nieuwe configuratie", + "Add a new and blank configuration" : "Toevoegen nieuwe, blanco configuratie", "Copy current configuration into new directory binding" : "Kopieer de huidige configuratie naar een nieuwe directory binding", "Delete the current configuration" : "Verwijder de huidige configuratie", "Host" : "Host", diff --git a/apps/user_ldap/l10n/pl.js b/apps/user_ldap/l10n/pl.js index edd059273a8..e6092532818 100644 --- a/apps/user_ldap/l10n/pl.js +++ b/apps/user_ldap/l10n/pl.js @@ -50,7 +50,6 @@ OC.L10N.register( "Verify settings" : "Weryfikuj ustawienia", "1. Server" : "1. Serwer", "%s. Server:" : "%s. Serwer:", - "Adds a new and blank configuration" : "Dodaje nową, czystą konfigurację", "Copy current configuration into new directory binding" : "Kopiuje aktualną konfigurację do nowej lokalizacji", "Delete the current configuration" : "Usuwa aktualną konfigurację", "Host" : "Host", diff --git a/apps/user_ldap/l10n/pl.json b/apps/user_ldap/l10n/pl.json index d49417c99ae..feb45644090 100644 --- a/apps/user_ldap/l10n/pl.json +++ b/apps/user_ldap/l10n/pl.json @@ -48,7 +48,6 @@ "Verify settings" : "Weryfikuj ustawienia", "1. Server" : "1. Serwer", "%s. Server:" : "%s. Serwer:", - "Adds a new and blank configuration" : "Dodaje nową, czystą konfigurację", "Copy current configuration into new directory binding" : "Kopiuje aktualną konfigurację do nowej lokalizacji", "Delete the current configuration" : "Usuwa aktualną konfigurację", "Host" : "Host", diff --git a/apps/user_ldap/l10n/pt_BR.js b/apps/user_ldap/l10n/pt_BR.js index 2ee1f13da76..87c78e3d2f5 100644 --- a/apps/user_ldap/l10n/pt_BR.js +++ b/apps/user_ldap/l10n/pt_BR.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Verificar configurações", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Adiciona uma configuração nova e em branco", + "Add a new and blank configuration" : "Adiciona uma configuração nova e em branco", "Copy current configuration into new directory binding" : "Copie a configuração atual em um novo diretório obrigatório", "Delete the current configuration" : "Excluir a configuração atual", "Host" : "Host", diff --git a/apps/user_ldap/l10n/pt_BR.json b/apps/user_ldap/l10n/pt_BR.json index a0f3f79a352..169ff1db41c 100644 --- a/apps/user_ldap/l10n/pt_BR.json +++ b/apps/user_ldap/l10n/pt_BR.json @@ -76,7 +76,7 @@ "Verify settings" : "Verificar configurações", "1. Server" : "1. Servidor", "%s. Server:" : "%s. Servidor:", - "Adds a new and blank configuration" : "Adiciona uma configuração nova e em branco", + "Add a new and blank configuration" : "Adiciona uma configuração nova e em branco", "Copy current configuration into new directory binding" : "Copie a configuração atual em um novo diretório obrigatório", "Delete the current configuration" : "Excluir a configuração atual", "Host" : "Host", diff --git a/apps/user_ldap/l10n/ru.js b/apps/user_ldap/l10n/ru.js index 78aa87eb99b..8ddf80841a0 100644 --- a/apps/user_ldap/l10n/ru.js +++ b/apps/user_ldap/l10n/ru.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "Проверить настройки", "1. Server" : "Сервер 1.", "%s. Server:" : "Сервер %s:", - "Adds a new and blank configuration" : "Добавляет новую и пустую конфигурацию", + "Add a new and blank configuration" : "Добавить новую и пустую конфигурацию", "Copy current configuration into new directory binding" : "Копировать текущую конфигурацию в новую связь с каталогом", "Delete the current configuration" : "Удалить текущую конфигурацию", "Host" : "Сервер", diff --git a/apps/user_ldap/l10n/ru.json b/apps/user_ldap/l10n/ru.json index 98a447d6f89..ede0d5357d0 100644 --- a/apps/user_ldap/l10n/ru.json +++ b/apps/user_ldap/l10n/ru.json @@ -76,7 +76,7 @@ "Verify settings" : "Проверить настройки", "1. Server" : "Сервер 1.", "%s. Server:" : "Сервер %s:", - "Adds a new and blank configuration" : "Добавляет новую и пустую конфигурацию", + "Add a new and blank configuration" : "Добавить новую и пустую конфигурацию", "Copy current configuration into new directory binding" : "Копировать текущую конфигурацию в новую связь с каталогом", "Delete the current configuration" : "Удалить текущую конфигурацию", "Host" : "Сервер", diff --git a/apps/user_ldap/l10n/sk_SK.js b/apps/user_ldap/l10n/sk_SK.js index 86681991df4..612296be0cc 100644 --- a/apps/user_ldap/l10n/sk_SK.js +++ b/apps/user_ldap/l10n/sk_SK.js @@ -60,7 +60,6 @@ OC.L10N.register( "Verify settings" : "Overiť nastavenia", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Pridať novú prázdnu konfiguráciu", "Delete the current configuration" : "Vymazať súčasnú konfiguráciu", "Host" : "Hostiteľ", "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Môžete vynechať protokol, okrem prípadu, kedy sa vyžaduje SSL. Vtedy začnite s ldaps://", diff --git a/apps/user_ldap/l10n/sk_SK.json b/apps/user_ldap/l10n/sk_SK.json index 428251ec33a..abc6b5ec248 100644 --- a/apps/user_ldap/l10n/sk_SK.json +++ b/apps/user_ldap/l10n/sk_SK.json @@ -58,7 +58,6 @@ "Verify settings" : "Overiť nastavenia", "1. Server" : "1. Server", "%s. Server:" : "%s. Server:", - "Adds a new and blank configuration" : "Pridať novú prázdnu konfiguráciu", "Delete the current configuration" : "Vymazať súčasnú konfiguráciu", "Host" : "Hostiteľ", "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Môžete vynechať protokol, okrem prípadu, kedy sa vyžaduje SSL. Vtedy začnite s ldaps://", diff --git a/apps/user_ldap/l10n/sr.js b/apps/user_ldap/l10n/sr.js index 4e52cb05bd9..dd570c70e5c 100644 --- a/apps/user_ldap/l10n/sr.js +++ b/apps/user_ldap/l10n/sr.js @@ -78,7 +78,6 @@ OC.L10N.register( "Verify settings" : "Провери поставке", "1. Server" : "1. сервер", "%s. Server:" : "%s. Сервер:", - "Adds a new and blank configuration" : "Додаје нову празну поставу", "Copy current configuration into new directory binding" : "Копирај тренутну поставу у везивање новог директоријума", "Delete the current configuration" : "Обриши тренутне поставке", "Host" : "Домаћин", diff --git a/apps/user_ldap/l10n/sr.json b/apps/user_ldap/l10n/sr.json index c5b8b256cf8..91d9520d3b6 100644 --- a/apps/user_ldap/l10n/sr.json +++ b/apps/user_ldap/l10n/sr.json @@ -76,7 +76,6 @@ "Verify settings" : "Провери поставке", "1. Server" : "1. сервер", "%s. Server:" : "%s. Сервер:", - "Adds a new and blank configuration" : "Додаје нову празну поставу", "Copy current configuration into new directory binding" : "Копирај тренутну поставу у везивање новог директоријума", "Delete the current configuration" : "Обриши тренутне поставке", "Host" : "Домаћин", diff --git a/apps/user_ldap/l10n/th_TH.js b/apps/user_ldap/l10n/th_TH.js index d7215c96b6d..ea55c7c4936 100644 --- a/apps/user_ldap/l10n/th_TH.js +++ b/apps/user_ldap/l10n/th_TH.js @@ -78,7 +78,7 @@ OC.L10N.register( "Verify settings" : "ตรวจสอบการตั้งค่า", "1. Server" : "1. เซิร์ฟเวอร์", "%s. Server:" : "เซิร์ฟเวอร์%s", - "Adds a new and blank configuration" : "เพิ่มใหม่และกำหนดค่าว่างเปล่า", + "Add a new and blank configuration" : "เพิ่มใหม่และการกำหนดค่าว่าง", "Copy current configuration into new directory binding" : "คัดลอกการตั้งค่าปัจจุบันลงในไดเรกทอรีใหม่ที่ผูกกัน", "Delete the current configuration" : "ลบการตั้งค่าปัจจุบัน", "Host" : "โฮสต์", diff --git a/apps/user_ldap/l10n/th_TH.json b/apps/user_ldap/l10n/th_TH.json index 1a05c5c68ca..ace0e5517a7 100644 --- a/apps/user_ldap/l10n/th_TH.json +++ b/apps/user_ldap/l10n/th_TH.json @@ -76,7 +76,7 @@ "Verify settings" : "ตรวจสอบการตั้งค่า", "1. Server" : "1. เซิร์ฟเวอร์", "%s. Server:" : "เซิร์ฟเวอร์%s", - "Adds a new and blank configuration" : "เพิ่มใหม่และกำหนดค่าว่างเปล่า", + "Add a new and blank configuration" : "เพิ่มใหม่และการกำหนดค่าว่าง", "Copy current configuration into new directory binding" : "คัดลอกการตั้งค่าปัจจุบันลงในไดเรกทอรีใหม่ที่ผูกกัน", "Delete the current configuration" : "ลบการตั้งค่าปัจจุบัน", "Host" : "โฮสต์", diff --git a/apps/user_ldap/l10n/tr.js b/apps/user_ldap/l10n/tr.js index b9f893dccf0..e01fe04297e 100644 --- a/apps/user_ldap/l10n/tr.js +++ b/apps/user_ldap/l10n/tr.js @@ -54,7 +54,6 @@ OC.L10N.register( "Verify settings" : "Ayarları doğrula", "1. Server" : "1. Sunucu", "%s. Server:" : "%s. Sunucu:", - "Adds a new and blank configuration" : "Yeni ve boş bir yapılandırma ekler", "Copy current configuration into new directory binding" : "Geçerli yapılandırmayı yeni dizin bağlamasına kopyala", "Delete the current configuration" : "Geçerli yapılandırmayı sil", "Host" : "Sunucu", diff --git a/apps/user_ldap/l10n/tr.json b/apps/user_ldap/l10n/tr.json index 7733d546d5f..5936b41f7f0 100644 --- a/apps/user_ldap/l10n/tr.json +++ b/apps/user_ldap/l10n/tr.json @@ -52,7 +52,6 @@ "Verify settings" : "Ayarları doğrula", "1. Server" : "1. Sunucu", "%s. Server:" : "%s. Sunucu:", - "Adds a new and blank configuration" : "Yeni ve boş bir yapılandırma ekler", "Copy current configuration into new directory binding" : "Geçerli yapılandırmayı yeni dizin bağlamasına kopyala", "Delete the current configuration" : "Geçerli yapılandırmayı sil", "Host" : "Sunucu", diff --git a/apps/user_ldap/l10n/uk.js b/apps/user_ldap/l10n/uk.js index fe499d9ad67..de7bcf5faf7 100644 --- a/apps/user_ldap/l10n/uk.js +++ b/apps/user_ldap/l10n/uk.js @@ -10,6 +10,7 @@ OC.L10N.register( "No configuration specified" : "Немає конфігурації", "No data specified" : "Немає даних", " Could not set configuration %s" : "Не вдалося встановити конфігурацію %s", + "Action does not exist" : "Дія не існує", "Configuration incorrect" : "Невірна конфігурація", "Configuration incomplete" : "Конфігурація неповна", "Configuration OK" : "Конфігурація OK", @@ -19,6 +20,8 @@ OC.L10N.register( "{nthServer}. Server" : "{nthServer}. Сервер", "Do you really want to delete the current Server Configuration?" : "Ви дійсно бажаєте видалити поточну конфігурацію сервера ?", "Confirm Deletion" : "Підтвердіть Видалення", + "Mappings cleared successfully!" : "Відображення успішно очищенні!", + "Error while clearing the mappings." : "Помилка при очищенні відображень.", "Select attributes" : "Виберіть атрибути", "User found and settings verified." : "Користувача знайдено і налаштування перевірені.", "_%s group found_::_%s groups found_" : [" %s група знайдена "," %s груп знайдено ","%s груп знайдено "], @@ -32,10 +35,13 @@ OC.L10N.register( "Test Configuration" : "Тестове налаштування", "Help" : "Допомога", "Groups meeting these criteria are available in %s:" : "Групи, що відповідають цим критеріям доступні в %s:", + "Only from these groups:" : "Лише з цих груп:", "Search groups" : "Пошук груп", "Available groups" : "Доступні групи", "Selected groups" : "Обрані групи", + "LDAP Filter:" : "LDAP фільтр:", "The filter specifies which LDAP groups shall have access to the %s instance." : "Фільтр визначає, які LDAP групи повинні мати доступ до %s примірника.", + "LDAP / AD Email Address:" : "LDAP / AD Email адреса:", "Other Attributes:" : "Інші Атрибути:", "Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action. Example: \"uid=%%uid\"" : "Визначає фільтр, який слід застосовувати при спробі входу.\n%%uid замінює ім'я користувача при вході в систему. Приклад: \"uid=%%uid\"", "1. Server" : "1. Сервер", diff --git a/apps/user_ldap/l10n/uk.json b/apps/user_ldap/l10n/uk.json index 5a04bf4b356..6590a639dfa 100644 --- a/apps/user_ldap/l10n/uk.json +++ b/apps/user_ldap/l10n/uk.json @@ -8,6 +8,7 @@ "No configuration specified" : "Немає конфігурації", "No data specified" : "Немає даних", " Could not set configuration %s" : "Не вдалося встановити конфігурацію %s", + "Action does not exist" : "Дія не існує", "Configuration incorrect" : "Невірна конфігурація", "Configuration incomplete" : "Конфігурація неповна", "Configuration OK" : "Конфігурація OK", @@ -17,6 +18,8 @@ "{nthServer}. Server" : "{nthServer}. Сервер", "Do you really want to delete the current Server Configuration?" : "Ви дійсно бажаєте видалити поточну конфігурацію сервера ?", "Confirm Deletion" : "Підтвердіть Видалення", + "Mappings cleared successfully!" : "Відображення успішно очищенні!", + "Error while clearing the mappings." : "Помилка при очищенні відображень.", "Select attributes" : "Виберіть атрибути", "User found and settings verified." : "Користувача знайдено і налаштування перевірені.", "_%s group found_::_%s groups found_" : [" %s група знайдена "," %s груп знайдено ","%s груп знайдено "], @@ -30,10 +33,13 @@ "Test Configuration" : "Тестове налаштування", "Help" : "Допомога", "Groups meeting these criteria are available in %s:" : "Групи, що відповідають цим критеріям доступні в %s:", + "Only from these groups:" : "Лише з цих груп:", "Search groups" : "Пошук груп", "Available groups" : "Доступні групи", "Selected groups" : "Обрані групи", + "LDAP Filter:" : "LDAP фільтр:", "The filter specifies which LDAP groups shall have access to the %s instance." : "Фільтр визначає, які LDAP групи повинні мати доступ до %s примірника.", + "LDAP / AD Email Address:" : "LDAP / AD Email адреса:", "Other Attributes:" : "Інші Атрибути:", "Defines the filter to apply, when login is attempted. %%uid replaces the username in the login action. Example: \"uid=%%uid\"" : "Визначає фільтр, який слід застосовувати при спробі входу.\n%%uid замінює ім'я користувача при вході в систему. Приклад: \"uid=%%uid\"", "1. Server" : "1. Сервер", diff --git a/apps/user_ldap/l10n/zh_CN.js b/apps/user_ldap/l10n/zh_CN.js index e341c393865..15d0154921b 100644 --- a/apps/user_ldap/l10n/zh_CN.js +++ b/apps/user_ldap/l10n/zh_CN.js @@ -9,6 +9,7 @@ OC.L10N.register( "Do you really want to delete the current Server Configuration?" : "您真的想要删除当前服务器配置吗?", "Confirm Deletion" : "确认删除", "Invalid Host" : "无效的主机", + "Server" : "服务器", "Users" : "用户", "Groups" : "群组", "Test Configuration" : "测试配置", diff --git a/apps/user_ldap/l10n/zh_CN.json b/apps/user_ldap/l10n/zh_CN.json index 24cd71d6941..18c87aa6c6f 100644 --- a/apps/user_ldap/l10n/zh_CN.json +++ b/apps/user_ldap/l10n/zh_CN.json @@ -7,6 +7,7 @@ "Do you really want to delete the current Server Configuration?" : "您真的想要删除当前服务器配置吗?", "Confirm Deletion" : "确认删除", "Invalid Host" : "无效的主机", + "Server" : "服务器", "Users" : "用户", "Groups" : "群组", "Test Configuration" : "测试配置", diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index f38d11d4be3..b201220d725 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -347,6 +347,33 @@ class Access extends LDAPUtility implements user\IUserTools { } /** + * accepts an array of group DNs and tests whether they match the user + * filter by doing read operations against the group entries. Returns an + * array of DNs that match the filter. + * + * @param string[] $groupDNs + * @return string[] + */ + public function groupsMatchFilter($groupDNs) { + $validGroupDNs = []; + foreach($groupDNs as $dn) { + $cacheKey = 'groupsMatchFilter-'.$dn; + if($this->connection->isCached($cacheKey)) { + if($this->connection->getFromCache($cacheKey)) { + $validGroupDNs[] = $dn; + } + continue; + } + + $result = $this->readAttribute($dn, 'cn', $this->connection->ldapGroupFilter); + if(is_array($result)) { + $validGroupDNs[] = $dn; + } + } + return $validGroupDNs; + } + + /** * 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 diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php index 0328259d78f..2bb2e1f8cb6 100644 --- a/apps/user_ldap/lib/connection.php +++ b/apps/user_ldap/lib/connection.php @@ -9,7 +9,6 @@ * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> - * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/user_ldap/lib/proxy.php b/apps/user_ldap/lib/proxy.php index 347ea9ce6a9..ef01213990c 100644 --- a/apps/user_ldap/lib/proxy.php +++ b/apps/user_ldap/lib/proxy.php @@ -8,7 +8,6 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> - * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/user_ldap/lib/user/manager.php b/apps/user_ldap/lib/user/manager.php index c8c89374e98..2f5ee3adfb7 100644 --- a/apps/user_ldap/lib/user/manager.php +++ b/apps/user_ldap/lib/user/manager.php @@ -1,6 +1,7 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/apps/user_ldap/settings.php b/apps/user_ldap/settings.php index d17361cdfd5..fb54276b463 100644 --- a/apps/user_ldap/settings.php +++ b/apps/user_ldap/settings.php @@ -1,7 +1,6 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> - * @author ben-denham <bend@catalyst.net.nz> * @author Dominik Schmidt <dev@dominik-schmidt.de> * @author Frank Karlitschek <frank@owncloud.org> * @author Lukas Reschke <lukas@owncloud.com> diff --git a/apps/user_ldap/tests/.htaccess b/apps/user_ldap/tests/.htaccess new file mode 100755 index 00000000000..5e068d28661 --- /dev/null +++ b/apps/user_ldap/tests/.htaccess @@ -0,0 +1,14 @@ +# Generated by ownCloud on 2015-06-18 14:16:40 +# line below if for Apache 2.4 +<ifModule mod_authz_core.c> +Require all denied +</ifModule> + +# line below if for Apache 2.2 +<ifModule !mod_authz_core.c> +deny from all +Satisfy All +</ifModule> + +# section for Apache 2.2 and 2.4 +IndexIgnore * diff --git a/apps/user_ldap/tests/group_ldap.php b/apps/user_ldap/tests/group_ldap.php index aeb306174f0..f716618ce48 100644 --- a/apps/user_ldap/tests/group_ldap.php +++ b/apps/user_ldap/tests/group_ldap.php @@ -404,6 +404,10 @@ class Test_Group_Ldap extends \Test\TestCase { ->method('dn2groupname') ->will($this->returnArgument(0)); + $access->expects($this->once()) + ->method('groupsMatchFilter') + ->will($this->returnArgument(0)); + $groupBackend = new GroupLDAP($access); $groups = $groupBackend->getUserGroups('userX'); diff --git a/apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php b/apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php new file mode 100644 index 00000000000..6560153bb63 --- /dev/null +++ b/apps/user_ldap/tests/integration/lib/IntegrationTestAccessGroupsMatchFilter.php @@ -0,0 +1,158 @@ +<?php +/** + * Created by PhpStorm. + * User: blizzz + * Date: 26.06.15 + * Time: 18:13 + */ + +use OCA\user_ldap\lib\LDAP; + +require_once __DIR__ . '/../../../../../lib/base.php'; + +class IntegrationTestAccessGroupsMatchFilter { + /** @var LDAP */ + protected $ldap; + + /** @var \OCA\user_ldap\lib\Connection */ + protected $connection; + + /** @var \OCA\user_ldap\lib\Access */ + protected $access; + + /** @var string */ + protected $base; + + /** @var string[] */ + protected $server; + + public function __construct($host, $port, $bind, $pwd, $base) { + $this->base = $base; + $this->server = [ + 'host' => $host, + 'port' => $port, + 'dn' => $bind, + 'pwd' => $pwd + ]; + } + + /** + * prepares the LDAP environement and sets up a test configuration for + * the LDAP backend. + */ + public function init() { + require('setup-scripts/createExplicitUsers.php'); + require('setup-scripts/createExplicitGroups.php'); + + $this->initLDAPWrapper(); + $this->initConnection(); + $this->initAccess(); + } + + /** + * runs the test cases while outputting progress and result information + * + * If a test failed, the script is exited with return code 1. + */ + public function run() { + $cases = ['case1', 'case2']; + + foreach ($cases as $case) { + print("running $case " . PHP_EOL); + if (!$this->$case()) { + print(PHP_EOL . '>>> !!! Test ' . $case . ' FAILED !!! <<<' . PHP_EOL . PHP_EOL); + exit(1); + } + } + + print('Tests succeeded' . PHP_EOL); + } + + /** + * tests whether the group filter works with one specific group, while the + * input is the same. + * + * @return bool + */ + private function case1() { + $this->connection->setConfiguration(['ldapGroupFilter' => 'cn=RedGroup']); + + $dns = ['cn=RedGroup,ou=Groups,' . $this->base]; + $result = $this->access->groupsMatchFilter($dns); + return ($dns === $result); + } + + /** + * Tests whether a filter for limited groups is effective when more existing + * groups were passed for validation. + * + * @return bool + */ + private function case2() { + $this->connection->setConfiguration(['ldapGroupFilter' => '(|(cn=RedGroup)(cn=PurpleGroup))']); + + $dns = [ + 'cn=RedGroup,ou=Groups,' . $this->base, + 'cn=BlueGroup,ou=Groups,' . $this->base, + 'cn=PurpleGroup,ou=Groups,' . $this->base + ]; + $result = $this->access->groupsMatchFilter($dns); + + $status = + count($result) === 2 + && in_array('cn=RedGroup,ou=Groups,' . $this->base, $result) + && in_array('cn=PurpleGroup,ou=Groups,' . $this->base, $result); + + return $status; + } + + /** + * initializes the Access test instance + */ + private function initAccess() { + $this->access = new \OCA\user_ldap\lib\Access($this->connection, $this->ldap, new FakeManager()); + } + + /** + * initializes the test LDAP wrapper + */ + private function initLDAPWrapper() { + $this->ldap = new LDAP(); + } + + /** + * sets up the LDAP configuration to be used for the test + */ + private function initConnection() { + $this->connection = new \OCA\user_ldap\lib\Connection($this->ldap, '', null); + $this->connection->setConfiguration([ + 'ldapHost' => $this->server['host'], + 'ldapPort' => $this->server['port'], + 'ldapBase' => $this->base, + 'ldapAgentName' => $this->server['dn'], + 'ldapAgentPassword' => $this->server['pwd'], + 'ldapUserFilter' => 'objectclass=inetOrgPerson', + 'ldapUserDisplayName' => 'displayName', + 'ldapGroupDisplayName' => 'cn', + 'ldapLoginFilter' => 'uid=%uid', + 'ldapCacheTTL' => 0, + 'ldapConfigurationActive' => 1, + ]); + } +} + +/** + * Class FakeManager + * + * this is a mock of \OCA\user_ldap\lib\user\Manager which is a dependency of + * Access, that pulls plenty more things in. Because it is not needed in the + * scope of these tests, we replace it with a mock. + */ +class FakeManager extends \OCA\user_ldap\lib\user\Manager { + public function __construct() {} +} + +require_once('setup-scripts/config.php'); +$test = new IntegrationTestAccessGroupsMatchFilter($host, $port, $adn, $apwd, $bdn); +$test->init(); +$test->run(); diff --git a/apps/user_ldap/tests/integration/readme.md b/apps/user_ldap/tests/integration/readme.md new file mode 100644 index 00000000000..e20efef8fdc --- /dev/null +++ b/apps/user_ldap/tests/integration/readme.md @@ -0,0 +1,60 @@ +# Requirements # + +Have (as in do copy if not already done) the following files from https://github.com/owncloud/administration/tree/master/ldap-testing copied into the directory "setup-scripts": + + * start.sh + * stop.sh + * config.php + +Configure config.php according to your needs, also have a look into the LDAP and network settings in start.sh and stop.sh. + +# Usage # + +The basic command to run a test is: + +```# ./run-test.sh [phpscript]``` + +Yes, run it as root from within this directory. + +Example: + +``` +$ sudo ./run-test.sh lib/IntegrationTestAccessGroupsMatchFilter.php +71cbe88a4993e67066714d71c1cecc5ef26a54911a208103cb6294f90459e574 +c74dc0155db4efa7a0515d419528a8727bbc7596601cf25b0df05e348bd74895 +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +c74dc0155db4 osixia/phpldapadmin:0.5.1 "/sbin/my_init" 1 seconds ago Up Less than a second 80/tcp, 0.0.0.0:8443->443/tcp docker-phpldapadmin +71cbe88a4993 nickstenning/slapd:latest "/sbin/my_init" 1 seconds ago Up Less than a second 127.0.0.1:7770->389/tcp docker-slapd + +LDAP server now available under 127.0.0.1:7770 (internal IP is 172.17.0.78) +phpldapadmin now available under https://127.0.0.1:8443 + +created user : Alice Ealic +created group : RedGroup +created group : BlueGroup +created group : GreenGroup +created group : PurpleGroup +running case1 +running case2 +Tests succeeded +Stopping and resetting containers +docker-slapd +docker-phpldapadmin +docker-slapd +docker-phpldapadmin +``` + +# How it works # + +1. start.sh is executed which brings up a fresh and clean OpenLDAP in Docker. +2. The provided test script is executed. It also outputs results. +3. stop.sh is executed to shut down OpenLDAP + +# Beware # + +This is quick solution for basically one test case. With expension this mechanism should be improved as well. + +It does not run automatically, unless you do it. No integration with any testing framework. + +exceptionOnLostConnection.php is not part of this mechanism. Read its source and run it isolated. While you're at it, port it :þ + diff --git a/apps/user_ldap/tests/integration/run-test.sh b/apps/user_ldap/tests/integration/run-test.sh new file mode 100755 index 00000000000..e07e9b43408 --- /dev/null +++ b/apps/user_ldap/tests/integration/run-test.sh @@ -0,0 +1,17 @@ +#!/bin/sh + +if [ $1 ] ; then + TESTSCRIPT=$1 +else + echo "No test file given" exit +fi + +if [ ! -e "$TESTSCRIPT" ] ; then + echo "Test file does not exist" + exit +fi + + +# sleep is necessary, otherwise the LDAP server cannot be connected to, yet. +setup-scripts/start.sh && sleep 2 && php -f "$TESTSCRIPT" +setup-scripts/stop.sh diff --git a/apps/user_ldap/tests/integration/setup-scripts/createExplicitGroups.php b/apps/user_ldap/tests/integration/setup-scripts/createExplicitGroups.php new file mode 100644 index 00000000000..68854de5571 --- /dev/null +++ b/apps/user_ldap/tests/integration/setup-scripts/createExplicitGroups.php @@ -0,0 +1,52 @@ +<?php + +if(php_sapi_name() !== 'cli') { + print('Only via CLI, please.'); + exit(1); +} + +include __DIR__ . '/config.php'; + +$cr = ldap_connect($host, $port); +ldap_set_option($cr, LDAP_OPT_PROTOCOL_VERSION, 3); +$ok = ldap_bind($cr, $adn, $apwd); + +if (!$ok) { + die(ldap_error($cr)); +} + +$ouName = 'Groups'; +$ouDN = 'ou=' . $ouName . ',' . $bdn; + +//creates an OU +if (true) { + $entry = []; + $entry['objectclass'][] = 'top'; + $entry['objectclass'][] = 'organizationalunit'; + $entry['ou'] = $ouName; + $b = ldap_add($cr, $ouDN, $entry); + if (!$b) { + die(ldap_error($cr)); + } +} + +$groups = ['RedGroup', 'BlueGroup', 'GreenGroup', 'PurpleGroup']; +// groupOfNames requires groups to have at least one member +// the member used is created by createExplicitUsers.php script +$omniMember = 'uid=alice,ou=Users,' . $bdn; + +foreach ($groups as $cn) { + $newDN = 'cn=' . $cn . ',' . $ouDN; + + $entry = []; + $entry['cn'] = $cn; + $entry['objectclass'][] = 'groupOfNames'; + $entry['member'][] = $omniMember; + + $ok = ldap_add($cr, $newDN, $entry); + if ($ok) { + echo('created group ' . ': ' . $entry['cn'] . PHP_EOL); + } else { + die(ldap_error($cr)); + } +} diff --git a/apps/user_ldap/tests/integration/setup-scripts/createExplicitUsers.php b/apps/user_ldap/tests/integration/setup-scripts/createExplicitUsers.php new file mode 100644 index 00000000000..ac21d48fd16 --- /dev/null +++ b/apps/user_ldap/tests/integration/setup-scripts/createExplicitUsers.php @@ -0,0 +1,54 @@ +<?php + +if(php_sapi_name() !== 'cli') { + print('Only via CLI, please.'); + exit(1); +} + +include __DIR__ . '/config.php'; + +$cr = ldap_connect($host, $port); +ldap_set_option($cr, LDAP_OPT_PROTOCOL_VERSION, 3); +$ok = ldap_bind($cr, $adn, $apwd); + +if (!$ok) { + die(ldap_error($cr)); +} + +$ouName = 'Users'; +$ouDN = 'ou=' . $ouName . ',' . $bdn; + +//creates on OU +if (true) { + $entry = []; + $entry['objectclass'][] = 'top'; + $entry['objectclass'][] = 'organizationalunit'; + $entry['ou'] = $ouName; + $b = ldap_add($cr, $ouDN, $entry); + if (!$b) { + die(ldap_error($cr)); + } +} + +$users = ['alice']; + +foreach ($users as $uid) { + $newDN = 'uid=' . $uid . ',' . $ouDN; + $fn = ucfirst($uid); + $sn = ucfirst(str_shuffle($uid)); // not so explicit but it's OK. + + $entry = []; + $entry['cn'] = $fn . ' ' . $sn; + $entry['objectclass'][] = 'inetOrgPerson'; + $entry['objectclass'][] = 'person'; + $entry['sn'] = $sn; + $entry['userPassword'] = $uid; + $entry['displayName'] = $sn . ', ' . $fn; + + $ok = ldap_add($cr, $newDN, $entry); + if ($ok) { + echo('created user ' . ': ' . $entry['cn'] . PHP_EOL); + } else { + die(ldap_error($cr)); + } +} diff --git a/apps/user_ldap/tests/user_ldap.php b/apps/user_ldap/tests/user_ldap.php index 2f15a5acc6d..2b99e1c2dc8 100644 --- a/apps/user_ldap/tests/user_ldap.php +++ b/apps/user_ldap/tests/user_ldap.php @@ -2,6 +2,7 @@ /** * @author Arthur Schiwon <blizzz@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> diff --git a/apps/user_ldap/user_ldap.php b/apps/user_ldap/user_ldap.php index 014d60c7316..caff30a0e60 100644 --- a/apps/user_ldap/user_ldap.php +++ b/apps/user_ldap/user_ldap.php @@ -120,9 +120,11 @@ class USER_LDAP extends BackendUtility implements \OCP\IUserBackend, \OCP\UserIn /** * Get a list of all users - * @return string[] with all uids * - * Get a list of all users. + * @param string $search + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids */ public function getUsers($search = '', $limit = 10, $offset = 0) { $search = $this->access->escapeFilterPart($search, true); @@ -328,9 +330,11 @@ class USER_LDAP extends BackendUtility implements \OCP\IUserBackend, \OCP\UserIn /** * Get a list of all display names - * @return array with all displayNames (value) and the correspondig uids (key) * - * Get a list of all display names and user ids. + * @param string $search + * @param string|null $limit + * @param string|null $offset + * @return array an array of all displayNames (value) and the corresponding uids (key) */ public function getDisplayNames($search = '', $limit = null, $offset = null) { $cacheKey = 'getDisplayNames-'.$search.'-'.$limit.'-'.$offset; diff --git a/apps/user_ldap/user_proxy.php b/apps/user_ldap/user_proxy.php index 53d453e54fd..683529eb902 100644 --- a/apps/user_ldap/user_proxy.php +++ b/apps/user_ldap/user_proxy.php @@ -132,9 +132,11 @@ class User_Proxy extends lib\Proxy implements \OCP\IUserBackend, \OCP\UserInterf /** * Get a list of all users - * @return string[] with all uids * - * Get a list of all users. + * @param string $search + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids */ public function getUsers($search = '', $limit = 10, $offset = 0) { //we do it just as the /OC_User implementation: do not play around with limit and offset but ask all backends @@ -208,10 +210,11 @@ class User_Proxy extends lib\Proxy implements \OCP\IUserBackend, \OCP\UserInterf } /** - * Get a list of all display names - * @return array with all displayNames (value) and the corresponding uids (key) - * * Get a list of all display names and user ids. + * @param string $search + * @param string|null $limit + * @param string|null $offset + * @return array an array of all displayNames (value) and the corresponding uids (key) */ public function getDisplayNames($search = '', $limit = null, $offset = null) { //we do it just as the /OC_User implementation: do not play around with limit and offset but ask all backends diff --git a/apps/user_webdavauth/appinfo/app.php b/apps/user_webdavauth/appinfo/app.php index d27e804d8ba..3f76f803efd 100644 --- a/apps/user_webdavauth/appinfo/app.php +++ b/apps/user_webdavauth/appinfo/app.php @@ -4,6 +4,7 @@ * @author Frank Karlitschek <frank@owncloud.org> * @author j-ed <juergen@eisfair.org> * @author Morris Jobke <hey@morrisjobke.de> + * @author Roeland Jago Douma <roeland@famdouma.nl> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/apps/user_webdavauth/appinfo/info.xml b/apps/user_webdavauth/appinfo/info.xml index 755a6d5bfb4..b0827fb51f8 100644 --- a/apps/user_webdavauth/appinfo/info.xml +++ b/apps/user_webdavauth/appinfo/info.xml @@ -12,5 +12,4 @@ <types> <authentication/> </types> - <ocsid>166062</ocsid> </info> diff --git a/apps/user_webdavauth/appinfo/version b/apps/user_webdavauth/appinfo/version index 238afc2b279..a3fdef3af89 100644 --- a/apps/user_webdavauth/appinfo/version +++ b/apps/user_webdavauth/appinfo/version @@ -1 +1 @@ -1.1.0.1 +1.1.0.2 diff --git a/apps/user_webdavauth/l10n/is.js b/apps/user_webdavauth/l10n/is.js index c6580e434b5..cc9515a9455 100644 --- a/apps/user_webdavauth/l10n/is.js +++ b/apps/user_webdavauth/l10n/is.js @@ -4,4 +4,4 @@ OC.L10N.register( "WebDAV Authentication" : "WebDAV Auðkenni", "Save" : "Vista" }, -"nplurals=2; plural=(n != 1);"); +"nplurals=2; plural=(n % 10 == 1 || n % 100 != 11);"); diff --git a/apps/user_webdavauth/l10n/is.json b/apps/user_webdavauth/l10n/is.json index a9ab8d7246c..e59f0457738 100644 --- a/apps/user_webdavauth/l10n/is.json +++ b/apps/user_webdavauth/l10n/is.json @@ -1,5 +1,5 @@ { "translations": { "WebDAV Authentication" : "WebDAV Auðkenni", "Save" : "Vista" -},"pluralForm" :"nplurals=2; plural=(n != 1);" +},"pluralForm" :"nplurals=2; plural=(n % 10 == 1 || n % 100 != 11);" }
\ No newline at end of file diff --git a/apps/user_webdavauth/l10n/ru.js b/apps/user_webdavauth/l10n/ru.js index b52d1ed81be..2af520e8396 100644 --- a/apps/user_webdavauth/l10n/ru.js +++ b/apps/user_webdavauth/l10n/ru.js @@ -6,4 +6,4 @@ OC.L10N.register( "Save" : "Сохранить", "The user credentials will be sent to this address. This plugin checks the response and will interpret the HTTP statuscodes 401 and 403 as invalid credentials, and all other responses as valid credentials." : "Учётные данные пользователя будут отправлены на этот адрес. Плагин проверит ответ и будет рассматривать HTTP коды 401 и 403 как неверные учётные данные, при любом другом ответе - учётные данные пользователя верны." }, -"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);"); +"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);"); diff --git a/apps/user_webdavauth/l10n/ru.json b/apps/user_webdavauth/l10n/ru.json index e265fc80ed4..88b53330acc 100644 --- a/apps/user_webdavauth/l10n/ru.json +++ b/apps/user_webdavauth/l10n/ru.json @@ -3,5 +3,5 @@ "Address:" : "Адрес:", "Save" : "Сохранить", "The user credentials will be sent to this address. This plugin checks the response and will interpret the HTTP statuscodes 401 and 403 as invalid credentials, and all other responses as valid credentials." : "Учётные данные пользователя будут отправлены на этот адрес. Плагин проверит ответ и будет рассматривать HTTP коды 401 и 403 как неверные учётные данные, при любом другом ответе - учётные данные пользователя верны." -},"pluralForm" :"nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);" +},"pluralForm" :"nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || (n%100>=11 && n%100<=14)? 2 : 3);" }
\ No newline at end of file diff --git a/apps/user_webdavauth/user_webdavauth.php b/apps/user_webdavauth/user_webdavauth.php index be61cce5088..acd7ec8507c 100644 --- a/apps/user_webdavauth/user_webdavauth.php +++ b/apps/user_webdavauth/user_webdavauth.php @@ -3,7 +3,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Felix Moeller <mail@felixmoeller.de> * @author Frank Karlitschek <frank@owncloud.org> - * @author Georg Ehrke <georg@ownCloud.com> + * @author Georg Ehrke <georg@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author opensaucesystems <ashley@opensaucesystems.com> * @author Thomas Müller <thomas.mueller@tmit.eu> @@ -34,27 +34,27 @@ class OC_USER_WEBDAVAUTH extends OC_User_Backend implements \OCP\IUserBackend { public function deleteUser($uid) { // Can't delete user - OC_Log::write('OC_USER_WEBDAVAUTH', 'Not possible to delete users from web frontend using WebDAV user backend', 3); + OCP\Util::writeLog('OC_USER_WEBDAVAUTH', 'Not possible to delete users from web frontend using WebDAV user backend', 3); return false; } public function setPassword ( $uid, $password ) { // We can't change user password - OC_Log::write('OC_USER_WEBDAVAUTH', 'Not possible to change password for users from web frontend using WebDAV user backend', 3); + OCP\Util::writeLog('OC_USER_WEBDAVAUTH', 'Not possible to change password for users from web frontend using WebDAV user backend', 3); return false; } public function checkPassword( $uid, $password ) { $arr = explode('://', $this->webdavauth_url, 2); if( ! isset($arr) OR count($arr) !== 2) { - OC_Log::write('OC_USER_WEBDAVAUTH', 'Invalid Url: "'.$this->webdavauth_url.'" ', 3); + OCP\Util::writeLog('OC_USER_WEBDAVAUTH', 'Invalid Url: "'.$this->webdavauth_url.'" ', 3); return false; } list($webdavauth_protocol, $webdavauth_url_path) = $arr; $url= $webdavauth_protocol.'://'.urlencode($uid).':'.urlencode($password).'@'.$webdavauth_url_path; $headers = get_headers($url); if($headers==false) { - OC_Log::write('OC_USER_WEBDAVAUTH', 'Not possible to connect to WebDAV Url: "'.$webdavauth_protocol.'://'.$webdavauth_url_path.'" ', 3); + OCP\Util::writeLog('OC_USER_WEBDAVAUTH', 'Not possible to connect to WebDAV Url: "'.$webdavauth_protocol.'://'.$webdavauth_url_path.'" ', 3); return false; } diff --git a/build/.htaccess b/build/.htaccess new file mode 100644 index 00000000000..c7a7b79feac --- /dev/null +++ b/build/.htaccess @@ -0,0 +1,12 @@ +# line below if for Apache 2.4 +<ifModule mod_authz_core.c> +Require all denied +</ifModule> + +# line below if for Apache 2.2 +<ifModule !mod_authz_core.c> +deny from all +</ifModule> + +# section for Apache 2.2 and 2.4 +IndexIgnore * diff --git a/build/license.php b/build/license.php index 6e3806e1464..214ea3c2269 100644 --- a/build/license.php +++ b/build/license.php @@ -144,7 +144,7 @@ EOD; } private function getAuthors($file) { - $out = shell_exec("git blame --line-porcelain $file | sed -n 's/^author //p;s/^author-mail //p' | sed 'N;s/\\n/ /' | sort | uniq"); + $out = shell_exec("git blame --line-porcelain $file | sed -n 's/^author //p;s/^author-mail //p' | sed 'N;s/\\n/ /' | sort -f | uniq"); $authors = explode(PHP_EOL, $out); $authors = array_filter($authors, function($author) { diff --git a/config/config.sample.php b/config/config.sample.php index 535b2c3a5cc..19e7843d6c9 100644 --- a/config/config.sample.php +++ b/config/config.sample.php @@ -1025,14 +1025,14 @@ $CONFIG = array( /** - * Enables the EXPERIMENTAL file locking. - * This is disabled by default as it is experimental. + * Enables transactional file locking. + * This is disabled by default as it is still beta. * * Prevents concurrent processes to access the same files * at the same time. Can help prevent side effects that would * be caused by concurrent operations. * - * WARNING: EXPERIMENTAL + * WARNING: BETA quality */ 'filelocking.enabled' => false, diff --git a/console.php b/console.php index 781905b04b5..3fee81c70c7 100644 --- a/console.php +++ b/console.php @@ -2,9 +2,10 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Christian Kampka <christian@kampka.net> + * @author Jost Baron <Jost.Baron@gmx.de> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/core/ajax/preview.php b/core/ajax/preview.php index 2c25d6f9219..c5714396409 100644 --- a/core/ajax/preview.php +++ b/core/ajax/preview.php @@ -3,7 +3,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/core/ajax/share.php b/core/ajax/share.php index e78d274815d..6cf5eb00cb6 100644 --- a/core/ajax/share.php +++ b/core/ajax/share.php @@ -3,8 +3,8 @@ * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> + * @author Craig Morrissey <craig@owncloud.com> * @author dampfklon <me@dampfklon.de> - * @author Jan-Christoph Borchardt <hey@jancborchardt.net> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> @@ -12,6 +12,7 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Ramiro Aparicio <rapariciog@gmail.com> * @author Robin Appelman <icewind@owncloud.com> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Thomas Tanghus <thomas@tanghus.net> * @author Vincent Petry <pvince81@owncloud.com> @@ -66,6 +67,8 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo } else { OC_JSON::success(); } + } catch (\OC\HintException $exception) { + OC_JSON::error(array('data' => array('message' => $exception->getHint()))); } catch (Exception $exception) { OC_JSON::error(array('data' => array('message' => $exception->getMessage()))); } @@ -273,8 +276,15 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo $sharedUsers = []; $sharedGroups = []; if (isset($_GET['itemShares'])) { - $sharedUsers = isset($_GET['itemShares'][OCP\Share::SHARE_TYPE_USER]) ? $_GET['itemShares'][OCP\Share::SHARE_TYPE_USER] : []; - $sharedGroups = isset($_GET['itemShares'][OCP\Share::SHARE_TYPE_GROUP]) ? $_GET['itemShares'][OCP\Share::SHARE_TYPE_GROUP] : []; + if (isset($_GET['itemShares'][OCP\Share::SHARE_TYPE_USER]) && + is_array($_GET['itemShares'][OCP\Share::SHARE_TYPE_USER])) { + $sharedUsers = $_GET['itemShares'][OCP\Share::SHARE_TYPE_USER]; + } + + if (isset($_GET['itemShares'][OCP\Share::SHARE_TYPE_GROUP]) && + is_array($_GET['itemShares'][OCP\Share::SHARE_TYPE_GROUP])) { + $sharedGroups = isset($_GET['itemShares'][OCP\Share::SHARE_TYPE_GROUP]); + } } $count = 0; @@ -352,8 +362,24 @@ if (isset($_POST['action']) && isset($_POST['itemType']) && isset($_POST['itemSo ) ); } + $contactManager = \OC::$server->getContactsManager(); + $addressBookContacts = $contactManager->search($_GET['search'], ['CLOUD', 'FN']); + foreach ($addressBookContacts as $contact) { + if (isset($contact['CLOUD'])) { + foreach ($contact['CLOUD'] as $cloudId) { + $shareWith[] = array( + 'label' => $contact['FN'] . ' (' . $cloudId . ')', + 'value' => array( + 'shareType' => \OCP\Share::SHARE_TYPE_REMOTE, + 'shareWith' => $cloudId + ) + ); + } + } + } } + $sorter = new \OC\Share\SearchResultSorter((string)$_GET['search'], 'label', \OC::$server->getLogger()); diff --git a/core/ajax/update.php b/core/ajax/update.php index 6a29b5b1c33..2f34708faea 100644 --- a/core/ajax/update.php +++ b/core/ajax/update.php @@ -3,6 +3,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> diff --git a/core/application.php b/core/application.php index cca2c600118..0fbb8dacdb7 100644 --- a/core/application.php +++ b/core/application.php @@ -4,6 +4,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Roeland Jago Douma <roeland@famdouma.nl> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/avatar/avatarcontroller.php b/core/avatar/avatarcontroller.php index 19ea1f7a4d8..95baf23f4fa 100644 --- a/core/avatar/avatarcontroller.php +++ b/core/avatar/avatarcontroller.php @@ -1,6 +1,8 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Roeland Jago Douma <roeland@famdouma.nl> * diff --git a/core/command/app/checkcode.php b/core/command/app/checkcode.php index 9e5514429ff..ecec51e5768 100644 --- a/core/command/app/checkcode.php +++ b/core/command/app/checkcode.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/core/command/check.php b/core/command/check.php index ddfe9b73bba..cd7f8ee8e4c 100644 --- a/core/command/check.php +++ b/core/command/check.php @@ -1,5 +1,25 @@ <?php - +/** + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ namespace OC\Core\Command; use OCP\IConfig; diff --git a/core/command/maintenance/install.php b/core/command/maintenance/install.php index dbc5ed77509..2fea5add438 100644 --- a/core/command/maintenance/install.php +++ b/core/command/maintenance/install.php @@ -1,6 +1,8 @@ <?php /** + * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Christian Kampka <christian@kampka.net> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/command/status.php b/core/command/status.php index 737113d4f85..a65e985a9ec 100644 --- a/core/command/status.php +++ b/core/command/status.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/command/upgrade.php b/core/command/upgrade.php index cf376148a00..44e0b66c17c 100644 --- a/core/command/upgrade.php +++ b/core/command/upgrade.php @@ -3,6 +3,7 @@ * @author Andreas Fischer <bantu@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Owen Winkler <a_github@midnightcircus.com> + * @author Steffen Lindner <mail@steffen-lindner.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * @@ -25,6 +26,7 @@ namespace OC\Core\Command; +use OC\Console\TimestampFormatter; use OC\Updater; use OCP\IConfig; use Symfony\Component\Console\Command\Command; @@ -109,6 +111,12 @@ class Upgrade extends Command { } if(\OC::checkUpgrade(false)) { + if (OutputInterface::VERBOSITY_NORMAL < $output->getVerbosity()) { + // Prepend each line with a little timestamp + $timestampFormatter = new TimestampFormatter($this->config, $output->getFormatter()); + $output->setFormatter($timestampFormatter); + } + $self = $this; $updater = new Updater(\OC::$server->getHTTPHelper(), \OC::$server->getConfig()); @@ -129,9 +137,11 @@ class Upgrade extends Command { $updater->listen('\OC\Updater', 'updateEnd', function ($success) use($output, $updateStepEnabled, $self) { $mode = $updateStepEnabled ? 'Update' : 'Update simulation'; - $status = $success ? 'successful' : 'failed' ; - $type = $success ? 'info' : 'error'; - $message = "<$type>$mode $status</$type>"; + if ($success) { + $message = "<info>$mode successful</info>"; + } else { + $message = "<error>$mode failed</error>"; + } $output->writeln($message); }); $updater->listen('\OC\Updater', 'dbUpgrade', function () use($output) { @@ -168,6 +178,15 @@ class Upgrade extends Command { $output->writeln("<error>$message</error>"); }); + if(OutputInterface::VERBOSITY_NORMAL < $output->getVerbosity()) { + $updater->listen('\OC\Updater', 'repairInfo', function ($message) use($output) { + $output->writeln('<info>Repair info: ' . $message . '</info>'); + }); + $updater->listen('\OC\Updater', 'repairStep', function ($message) use($output) { + $output->writeln('<info>Repair step: ' . $message . '</info>'); + }); + } + $success = $updater->upgrade(); $this->postUpgradeCheck($input, $output); diff --git a/core/command/user/add.php b/core/command/user/add.php index c52ec4d0090..07060bb172f 100644 --- a/core/command/user/add.php +++ b/core/command/user/add.php @@ -1,6 +1,8 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Laurens Post <lkpost@scept.re> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/core/command/user/delete.php b/core/command/user/delete.php index 63b81134873..e80c63bc732 100644 --- a/core/command/user/delete.php +++ b/core/command/user/delete.php @@ -1,6 +1,8 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Jens-Christian Fischer <jens-christian.fischer@switch.ch> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/command/user/lastseen.php b/core/command/user/lastseen.php index 92fcb1d449b..931165ef9f6 100644 --- a/core/command/user/lastseen.php +++ b/core/command/user/lastseen.php @@ -1,6 +1,7 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/command/user/report.php b/core/command/user/report.php index 5d89c0ae549..7a830f64c07 100644 --- a/core/command/user/report.php +++ b/core/command/user/report.php @@ -1,6 +1,7 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/core/command/user/resetpassword.php b/core/command/user/resetpassword.php index 3e4b41c0a43..6c5846bcef3 100644 --- a/core/command/user/resetpassword.php +++ b/core/command/user/resetpassword.php @@ -2,6 +2,9 @@ /** * @author Andreas Fischer <bantu@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> + * @author Clark Tomlinson <fallen013@gmail.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Laurens Post <lkpost@scept.re> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/core/css/apps.css b/core/css/apps.css index af2e85e3b9b..57133729f15 100644 --- a/core/css/apps.css +++ b/core/css/apps.css @@ -410,7 +410,6 @@ position: relative; height: 100%; overflow-y: auto; - z-index: 100; } #app-content-wrapper { @@ -556,3 +555,4 @@ em { z-index:500; padding:16px; } + diff --git a/core/l10n/cs_CZ.js b/core/l10n/cs_CZ.js index c2aadb0de84..9cd3c35d30d 100644 --- a/core/l10n/cs_CZ.js +++ b/core/l10n/cs_CZ.js @@ -4,6 +4,7 @@ OC.L10N.register( "Couldn't send mail to following users: %s " : "Nebylo možné odeslat email následujícím uživatelům: %s", "Turned on maintenance mode" : "Zapnut režim údržby", "Turned off maintenance mode" : "Vypnut režim údržby", + "Maintenance mode is kept active" : "Mód údržby je aktivní", "Updated database" : "Zaktualizována databáze", "Checked database schema update" : "Aktualizace schéma databáze byla ověřena", "Checked database schema update for apps" : "Aktualizace schéma databáze aplikací byla ověřena", @@ -76,6 +77,8 @@ OC.L10N.register( "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "PHP nemá práva pro čtení v /dev/urandom, to je ale z bezpečnostních důvodů velmi doporučováno. Více informací lze nalézt v <a href=\"{docLink}\">dokumentaci</a>.", "Error occurred while checking server setup" : "Při ověřování nastavení serveru došlo k chybě", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "HTTP hlavička \"{header}\" není nakonfigurována ve shodě s \"{expected}\". To značí možné ohrožení bezpečnosti a soukromí a je doporučeno toto nastavení upravit.", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "HTTP hlavička \"Strict-Transport-Security\" není nakonfigurována na minimum \"{seconds}\" sekund. Pro vylepšení bezpečnosti doporučujeme povolit HSTS dle popisu v našich <a href=\"{docUrl}\">bezpečnostních tipech</a>.", + "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "Přistupujete na tuto stránku přes protokol HTTP. Důrazně doporučujeme nakonfigurovat server tak, aby vyžadoval použití HTTPS jak je popsáno v našich <a href=\"{docUrl}\">bezpečnostních tipech</a>.", "Shared" : "Sdílené", "Shared with {recipients}" : "Sdíleno s {recipients}", "Share" : "Sdílet", @@ -147,6 +150,7 @@ OC.L10N.register( "New Password" : "Nové heslo", "Reset password" : "Obnovit heslo", "Searching other places" : "Prohledávání ostatních umístění", + "No search results in other places" : "Žádné nálezy v ostatních umístěních", "_{count} search result in other places_::_{count} search results in other places_" : ["{count} nález v ostatních umístěních","{count} nálezy v ostatních umístěních","{count} nálezů v ostatních umístěních"], "Personal" : "Osobní", "Users" : "Uživatelé", diff --git a/core/l10n/cs_CZ.json b/core/l10n/cs_CZ.json index f10ac871ed5..767864582d8 100644 --- a/core/l10n/cs_CZ.json +++ b/core/l10n/cs_CZ.json @@ -2,6 +2,7 @@ "Couldn't send mail to following users: %s " : "Nebylo možné odeslat email následujícím uživatelům: %s", "Turned on maintenance mode" : "Zapnut režim údržby", "Turned off maintenance mode" : "Vypnut režim údržby", + "Maintenance mode is kept active" : "Mód údržby je aktivní", "Updated database" : "Zaktualizována databáze", "Checked database schema update" : "Aktualizace schéma databáze byla ověřena", "Checked database schema update for apps" : "Aktualizace schéma databáze aplikací byla ověřena", @@ -74,6 +75,8 @@ "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "PHP nemá práva pro čtení v /dev/urandom, to je ale z bezpečnostních důvodů velmi doporučováno. Více informací lze nalézt v <a href=\"{docLink}\">dokumentaci</a>.", "Error occurred while checking server setup" : "Při ověřování nastavení serveru došlo k chybě", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "HTTP hlavička \"{header}\" není nakonfigurována ve shodě s \"{expected}\". To značí možné ohrožení bezpečnosti a soukromí a je doporučeno toto nastavení upravit.", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "HTTP hlavička \"Strict-Transport-Security\" není nakonfigurována na minimum \"{seconds}\" sekund. Pro vylepšení bezpečnosti doporučujeme povolit HSTS dle popisu v našich <a href=\"{docUrl}\">bezpečnostních tipech</a>.", + "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "Přistupujete na tuto stránku přes protokol HTTP. Důrazně doporučujeme nakonfigurovat server tak, aby vyžadoval použití HTTPS jak je popsáno v našich <a href=\"{docUrl}\">bezpečnostních tipech</a>.", "Shared" : "Sdílené", "Shared with {recipients}" : "Sdíleno s {recipients}", "Share" : "Sdílet", @@ -145,6 +148,7 @@ "New Password" : "Nové heslo", "Reset password" : "Obnovit heslo", "Searching other places" : "Prohledávání ostatních umístění", + "No search results in other places" : "Žádné nálezy v ostatních umístěních", "_{count} search result in other places_::_{count} search results in other places_" : ["{count} nález v ostatních umístěních","{count} nálezy v ostatních umístěních","{count} nálezů v ostatních umístěních"], "Personal" : "Osobní", "Users" : "Uživatelé", diff --git a/core/l10n/et_EE.js b/core/l10n/et_EE.js index 7452be84d80..f02f2aebd2e 100644 --- a/core/l10n/et_EE.js +++ b/core/l10n/et_EE.js @@ -10,11 +10,13 @@ OC.L10N.register( "Updated \"%s\" to %s" : "Uuendatud \"%s\" -> %s", "Repair warning: " : "Paranda hoiatus:", "Repair error: " : "Paranda viga:", + "Invalid file provided" : "Vigane fail", "No image or file provided" : "Ühtegi pilti või faili pole pakutud", "Unknown filetype" : "Tundmatu failitüüp", "Invalid image" : "Vigane pilt", "No temporary profile picture available, try again" : "Ühtegi ajutist profiili pilti pole saadaval, proovi uuesti", "No crop data provided" : "Lõikeandmeid ei leitud", + "Crop is not square" : "Lõikamine pole ruudukujuline", "Sunday" : "Pühapäev", "Monday" : "Esmaspäev", "Tuesday" : "Teisipäev", @@ -74,6 +76,7 @@ OC.L10N.register( "Error while changing permissions" : "Viga õiguste muutmisel", "Shared with you and the group {group} by {owner}" : "Jagatud sinu ja {group} grupiga {owner} poolt", "Shared with you by {owner}" : "Sinuga jagas {owner}", + "Share with users or groups …" : "Jaga kasutajate või gruppidega ...", "Share link" : "Jaga linki", "The public link will expire no later than {days} days after it is created" : "Avalik link aegub mitte hiljem kui pärast {days} päeva selle loomist", "Link" : "Link", @@ -86,6 +89,7 @@ OC.L10N.register( "Set expiration date" : "Määra aegumise kuupäev", "Expiration" : "Aegumine", "Expiration date" : "Aegumise kuupäev", + "An error occured. Please try again" : "Tekkis tõrge. Palun proovi uuesti", "Adding user..." : "Kasutaja lisamine...", "group" : "grupp", "Resharing is not allowed" : "Edasijagamine pole lubatud", @@ -117,8 +121,10 @@ OC.L10N.register( "Hello {name}, the weather is {weather}" : "Tere {name}, ilm on {weather}", "Hello {name}" : "Tere, {name}", "_download %n file_::_download %n files_" : ["laadi alla %n fail","laadi alla %n faili"], + "{version} is available. Get more information on how to update." : "{version} on saadaval. Vaata lisainfot uuendamise kohta.", "Updating {productName} to version {version}, this may take a while." : "Uuendan {productName} versioonile {version}, see võtab veidi aega.", "Please reload the page." : "Palun laadi see uuesti.", + "The update was unsuccessful. " : "Uuendamine ebaõnnestus.", "The update was successful. Redirecting you to ownCloud now." : "Uuendus oli edukas. Kohe suunatakse Sind ownCloudi.", "Couldn't reset password because the token is invalid" : "Ei saanud parooli taastada, kuna märgend on vigane", "Couldn't send reset email. Please make sure your username is correct." : "Ei suutnud lähtestada e-maili. Palun veendu, et kasutajatunnus on õige.", @@ -128,6 +134,9 @@ OC.L10N.register( "New password" : "Uus parool", "New Password" : "Uus parool", "Reset password" : "Nulli parool", + "Searching other places" : "Otsi teistest kohtadest", + "No search results in other places" : "Teistest kohtadest otsimine ei andnud tulemusi", + "_{count} search result in other places_::_{count} search results in other places_" : ["{count} otsingutulemus teistest kohtadest","{count} otsingutulemust teistest kohtadest"], "Personal" : "Isiklik", "Users" : "Kasutajad", "Apps" : "Rakendused", @@ -160,6 +169,7 @@ OC.L10N.register( "File: %s" : "Fail: %s", "Line: %s" : "Rida: %s", "Trace" : "Jälita", + "Security warning" : "Turvahoiatus", "Your data directory and files are probably accessible from the internet because the .htaccess file does not work." : "Su andmete kataloog ja failid on tõenäoliselt internetist vabalt saadaval kuna .htaccess fail ei toimi.", "For information how to properly configure your server, please see the <a href=\"%s\" target=\"_blank\">documentation</a>." : "Serveri korrektseks seadistuseks palun tutvu <a href=\"%s\" target=\"_blank\">dokumentatsiooniga</a>.", "Create an <strong>admin account</strong>" : "Loo <strong>admini konto</strong>", @@ -168,11 +178,14 @@ OC.L10N.register( "Data folder" : "Andmete kaust", "Configure the database" : "Seadista andmebaasi", "Only %s is available." : "Ainult %s on saadaval.", + "For more details check out the documentation." : "Lisainfot vaata dokumentatsioonist.", "Database user" : "Andmebaasi kasutaja", "Database password" : "Andmebaasi parool", "Database name" : "Andmebasi nimi", "Database tablespace" : "Andmebaasi tabeliruum", "Database host" : "Andmebaasi host", + "Performance warning" : "Kiiruse hoiatus", + "SQLite will be used as database." : "Andmebaasina kasutatakse SQLite", "Finish setup" : "Lõpeta seadistamine", "Finishing …" : "Lõpetamine ...", "Need help?" : "Vajad abi?", diff --git a/core/l10n/et_EE.json b/core/l10n/et_EE.json index 2d28fc176de..6f4c93578b3 100644 --- a/core/l10n/et_EE.json +++ b/core/l10n/et_EE.json @@ -8,11 +8,13 @@ "Updated \"%s\" to %s" : "Uuendatud \"%s\" -> %s", "Repair warning: " : "Paranda hoiatus:", "Repair error: " : "Paranda viga:", + "Invalid file provided" : "Vigane fail", "No image or file provided" : "Ühtegi pilti või faili pole pakutud", "Unknown filetype" : "Tundmatu failitüüp", "Invalid image" : "Vigane pilt", "No temporary profile picture available, try again" : "Ühtegi ajutist profiili pilti pole saadaval, proovi uuesti", "No crop data provided" : "Lõikeandmeid ei leitud", + "Crop is not square" : "Lõikamine pole ruudukujuline", "Sunday" : "Pühapäev", "Monday" : "Esmaspäev", "Tuesday" : "Teisipäev", @@ -72,6 +74,7 @@ "Error while changing permissions" : "Viga õiguste muutmisel", "Shared with you and the group {group} by {owner}" : "Jagatud sinu ja {group} grupiga {owner} poolt", "Shared with you by {owner}" : "Sinuga jagas {owner}", + "Share with users or groups …" : "Jaga kasutajate või gruppidega ...", "Share link" : "Jaga linki", "The public link will expire no later than {days} days after it is created" : "Avalik link aegub mitte hiljem kui pärast {days} päeva selle loomist", "Link" : "Link", @@ -84,6 +87,7 @@ "Set expiration date" : "Määra aegumise kuupäev", "Expiration" : "Aegumine", "Expiration date" : "Aegumise kuupäev", + "An error occured. Please try again" : "Tekkis tõrge. Palun proovi uuesti", "Adding user..." : "Kasutaja lisamine...", "group" : "grupp", "Resharing is not allowed" : "Edasijagamine pole lubatud", @@ -115,8 +119,10 @@ "Hello {name}, the weather is {weather}" : "Tere {name}, ilm on {weather}", "Hello {name}" : "Tere, {name}", "_download %n file_::_download %n files_" : ["laadi alla %n fail","laadi alla %n faili"], + "{version} is available. Get more information on how to update." : "{version} on saadaval. Vaata lisainfot uuendamise kohta.", "Updating {productName} to version {version}, this may take a while." : "Uuendan {productName} versioonile {version}, see võtab veidi aega.", "Please reload the page." : "Palun laadi see uuesti.", + "The update was unsuccessful. " : "Uuendamine ebaõnnestus.", "The update was successful. Redirecting you to ownCloud now." : "Uuendus oli edukas. Kohe suunatakse Sind ownCloudi.", "Couldn't reset password because the token is invalid" : "Ei saanud parooli taastada, kuna märgend on vigane", "Couldn't send reset email. Please make sure your username is correct." : "Ei suutnud lähtestada e-maili. Palun veendu, et kasutajatunnus on õige.", @@ -126,6 +132,9 @@ "New password" : "Uus parool", "New Password" : "Uus parool", "Reset password" : "Nulli parool", + "Searching other places" : "Otsi teistest kohtadest", + "No search results in other places" : "Teistest kohtadest otsimine ei andnud tulemusi", + "_{count} search result in other places_::_{count} search results in other places_" : ["{count} otsingutulemus teistest kohtadest","{count} otsingutulemust teistest kohtadest"], "Personal" : "Isiklik", "Users" : "Kasutajad", "Apps" : "Rakendused", @@ -158,6 +167,7 @@ "File: %s" : "Fail: %s", "Line: %s" : "Rida: %s", "Trace" : "Jälita", + "Security warning" : "Turvahoiatus", "Your data directory and files are probably accessible from the internet because the .htaccess file does not work." : "Su andmete kataloog ja failid on tõenäoliselt internetist vabalt saadaval kuna .htaccess fail ei toimi.", "For information how to properly configure your server, please see the <a href=\"%s\" target=\"_blank\">documentation</a>." : "Serveri korrektseks seadistuseks palun tutvu <a href=\"%s\" target=\"_blank\">dokumentatsiooniga</a>.", "Create an <strong>admin account</strong>" : "Loo <strong>admini konto</strong>", @@ -166,11 +176,14 @@ "Data folder" : "Andmete kaust", "Configure the database" : "Seadista andmebaasi", "Only %s is available." : "Ainult %s on saadaval.", + "For more details check out the documentation." : "Lisainfot vaata dokumentatsioonist.", "Database user" : "Andmebaasi kasutaja", "Database password" : "Andmebaasi parool", "Database name" : "Andmebasi nimi", "Database tablespace" : "Andmebaasi tabeliruum", "Database host" : "Andmebaasi host", + "Performance warning" : "Kiiruse hoiatus", + "SQLite will be used as database." : "Andmebaasina kasutatakse SQLite", "Finish setup" : "Lõpeta seadistamine", "Finishing …" : "Lõpetamine ...", "Need help?" : "Vajad abi?", diff --git a/core/l10n/fr.js b/core/l10n/fr.js index 41693fff08a..db2569bfd18 100644 --- a/core/l10n/fr.js +++ b/core/l10n/fr.js @@ -77,7 +77,7 @@ OC.L10N.register( "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "/dev/urandom n'est pas lisible par PHP, ce qui est fortement déconseillé pour des raisons de sécurité. Plus d'informations peuvent être trouvées dans notre <a href=\"{docLink}\">documentation</a>.", "Error occurred while checking server setup" : "Une erreur s'est produite lors de la vérification de la configuration du serveur", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "L'en-tête HTTP \"{header}\" n'est pas configurée pour être égale à \"{expected}\" créant potentiellement un risque relié à la sécurité et à la vie privée. Il est donc recommandé d'ajuster ce paramètre.", - "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "L'en-tête HTTP \"Strict-Transport-Security\" n'est pas configurée à \"{seconds}\" secondes. Pour renforcer la sécurité nous recommandons d'activer HSTS comme décrit sur votre <a href=\"{docUrl}\">aide de sécurité</a>.", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "L'en-tête HTTP \"Strict-Transport-Security\" n'est pas configurée à \"{seconds}\" secondes. Pour renforcer la sécurité nous recommandons d'activer HSTS comme décrit dans notre <a href=\"{docUrl}\">aide à la sécurité</a>.", "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "Vous accédez à ce site via HTTP. Nous vous recommandons fortement de configurer votre serveur pour forcer l'utilisation de HTTPS, comme expliqué dans notre <a href=\"{docUrl}\">aide à la sécurité</a>.", "Shared" : "Partagé", "Shared with {recipients}" : "Partagé avec {recipients}", diff --git a/core/l10n/fr.json b/core/l10n/fr.json index d1559fccd10..bfebc91fda7 100644 --- a/core/l10n/fr.json +++ b/core/l10n/fr.json @@ -75,7 +75,7 @@ "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "/dev/urandom n'est pas lisible par PHP, ce qui est fortement déconseillé pour des raisons de sécurité. Plus d'informations peuvent être trouvées dans notre <a href=\"{docLink}\">documentation</a>.", "Error occurred while checking server setup" : "Une erreur s'est produite lors de la vérification de la configuration du serveur", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "L'en-tête HTTP \"{header}\" n'est pas configurée pour être égale à \"{expected}\" créant potentiellement un risque relié à la sécurité et à la vie privée. Il est donc recommandé d'ajuster ce paramètre.", - "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "L'en-tête HTTP \"Strict-Transport-Security\" n'est pas configurée à \"{seconds}\" secondes. Pour renforcer la sécurité nous recommandons d'activer HSTS comme décrit sur votre <a href=\"{docUrl}\">aide de sécurité</a>.", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "L'en-tête HTTP \"Strict-Transport-Security\" n'est pas configurée à \"{seconds}\" secondes. Pour renforcer la sécurité nous recommandons d'activer HSTS comme décrit dans notre <a href=\"{docUrl}\">aide à la sécurité</a>.", "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "Vous accédez à ce site via HTTP. Nous vous recommandons fortement de configurer votre serveur pour forcer l'utilisation de HTTPS, comme expliqué dans notre <a href=\"{docUrl}\">aide à la sécurité</a>.", "Shared" : "Partagé", "Shared with {recipients}" : "Partagé avec {recipients}", diff --git a/core/l10n/ja.js b/core/l10n/ja.js index ff91074eff0..92eb72569d4 100644 --- a/core/l10n/ja.js +++ b/core/l10n/ja.js @@ -170,7 +170,7 @@ OC.L10N.register( "Internal Server Error" : "内部サーバエラー", "The server encountered an internal error and was unable to complete your request." : "サーバー内でエラーが発生したため、リクエストを完了できませんでした。", "Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report." : "このエラーが繰り返し表示されるようであれば、以下の技術情報を添付してサーバー管理者に報告してください。", - "More details can be found in the server log." : "詳しい情報は、サーバーのログを確認してください。", + "More details can be found in the server log." : "詳細は、サーバーのログを確認してください。", "Technical details" : "技術詳細", "Remote Address: %s" : "リモートアドレス: %s", "Request ID: %s" : "リクエスト ID: %s", @@ -190,7 +190,7 @@ OC.L10N.register( "Configure the database" : "データベースを設定してください", "Only %s is available." : "%s のみ有効です。", "Install and activate additional PHP modules to choose other database types." : "他のデータベースタイプを選択するためには、追加の PHP モジュールインストールして有効化してください。", - "For more details check out the documentation." : "詳細についてはドキュメントを確認して下さい。", + "For more details check out the documentation." : "詳細は、ドキュメントを確認してください。", "Database user" : "データベースのユーザー名", "Database password" : "データベースのパスワード", "Database name" : "データベース名", diff --git a/core/l10n/ja.json b/core/l10n/ja.json index 3f4748332d0..4a92efa21f4 100644 --- a/core/l10n/ja.json +++ b/core/l10n/ja.json @@ -168,7 +168,7 @@ "Internal Server Error" : "内部サーバエラー", "The server encountered an internal error and was unable to complete your request." : "サーバー内でエラーが発生したため、リクエストを完了できませんでした。", "Please contact the server administrator if this error reappears multiple times, please include the technical details below in your report." : "このエラーが繰り返し表示されるようであれば、以下の技術情報を添付してサーバー管理者に報告してください。", - "More details can be found in the server log." : "詳しい情報は、サーバーのログを確認してください。", + "More details can be found in the server log." : "詳細は、サーバーのログを確認してください。", "Technical details" : "技術詳細", "Remote Address: %s" : "リモートアドレス: %s", "Request ID: %s" : "リクエスト ID: %s", @@ -188,7 +188,7 @@ "Configure the database" : "データベースを設定してください", "Only %s is available." : "%s のみ有効です。", "Install and activate additional PHP modules to choose other database types." : "他のデータベースタイプを選択するためには、追加の PHP モジュールインストールして有効化してください。", - "For more details check out the documentation." : "詳細についてはドキュメントを確認して下さい。", + "For more details check out the documentation." : "詳細は、ドキュメントを確認してください。", "Database user" : "データベースのユーザー名", "Database password" : "データベースのパスワード", "Database name" : "データベース名", diff --git a/core/l10n/zh_CN.js b/core/l10n/zh_CN.js index de7679e9bb1..fa0f251134d 100644 --- a/core/l10n/zh_CN.js +++ b/core/l10n/zh_CN.js @@ -4,6 +4,7 @@ OC.L10N.register( "Couldn't send mail to following users: %s " : "无法发送邮件到用户: %s ", "Turned on maintenance mode" : "启用维护模式", "Turned off maintenance mode" : "关闭维护模式", + "Maintenance mode is kept active" : "维护模式已被启用", "Updated database" : "数据库已更新", "Checked database schema update" : "已经检查数据库架构更新", "Checked database schema update for apps" : "已经检查应用的数据库架构更新", @@ -73,8 +74,11 @@ OC.L10N.register( "This server has no working Internet connection. This means that some of the features like mounting external storage, notifications about updates or installation of third-party apps will not work. Accessing files remotely and sending of notification emails might not work, either. We suggest to enable Internet connection for this server if you want to have all features." : "该服务器没有工作在互联网连接,这意味着像挂载外部存储,第三方应用的更新或者安装的通知将不会工作。远程文件访问和邮件通知的发送也可能不会工作。如果你想拥有所有功能,我们建议你为服务器打开互联网连接。", "Your data directory and your files are probably accessible from the Internet. The .htaccess file is not working. We strongly suggest that you configure your web server in a way that the data directory is no longer accessible or you move the data directory outside the web server document root." : "你的数据目录和你的文件可能从互联网被访问到。.htaccess 文件不工作。我们强烈建议你配置你的网页服务器,使数据目录不再可访问,或者将数据目录移动到网页服务器根文档目录之外。", "No memory cache has been configured. To enhance your performance please configure a memcache if available. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "内存缓存未配置。如果可用,请配置 memcache 来增强性能。更多信息请查看我们的<a href=\"{docLink}\">文档</a> 。", + "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "/dev/urandom 无法被 PHP 读取,处于安全原因,这是强烈不推荐的。请查看<a href=\"{docLink}\">文档</a>了解详情。", "Error occurred while checking server setup" : "当检查服务器启动时出错", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "\"{header}\" HTTP 头部没有配置和 \"{expected}\" 的一样。这是一个潜在的安全或者隐私风险,我们调整这项设置。", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "HTTP 严格传输安全(Strict-Transport-Security)报头未配置到至少“{seconds}”秒。处于增强安全性考虑,我们推荐按照<a href=\"{docUrl}\">安全提示</a>启用 HSTS。", + "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "您正在通过 HTTP 访问该站点,我们强烈建议您按照<a href=\"{docUrl}\">安全提示</a>配置服务器强制使用 HTTPS。", "Shared" : "已共享", "Shared with {recipients}" : "由{recipients}分享", "Share" : "分享", @@ -84,6 +88,9 @@ OC.L10N.register( "Error while changing permissions" : "修改权限时出错", "Shared with you and the group {group} by {owner}" : "{owner} 共享给您及 {group} 组", "Shared with you by {owner}" : "{owner} 与您共享", + "Share with users or groups …" : "分享给其他用户或组 ...", + "Share with users, groups or remote users …" : "分享给其他用户、组或远程用户 ...", + "Share with people on other ownClouds using the syntax username@example.com/owncloud" : "使用语法 username@example.com/owncloud 分享给其他 ownCloud 上的用户", "Share link" : "分享链接", "The public link will expire no later than {days} days after it is created" : "这个共享链接将在创建后 {days} 天失效", "Link" : "链接", @@ -96,6 +103,7 @@ OC.L10N.register( "Set expiration date" : "设置过期日期", "Expiration" : "过期", "Expiration date" : "过期日期", + "An error occured. Please try again" : "发生了一个错误请重新尝试", "Adding user..." : "添加用户中...", "group" : "群组", "remote" : "远程", @@ -128,6 +136,7 @@ OC.L10N.register( "Hello {name}, the weather is {weather}" : "您好 {name},今天天气是{weather}", "Hello {name}" : "你好 {name}", "_download %n file_::_download %n files_" : ["下载 %n 个文件"], + "{version} is available. Get more information on how to update." : "{version} 现在可用。获取更多升级相关信息。", "Updating {productName} to version {version}, this may take a while." : "更新 {productName} 到版本 {version},这可能需要一些时间。", "Please reload the page." : "请重新加载页面。", "The update was unsuccessful. " : "升级未成功", @@ -141,6 +150,7 @@ OC.L10N.register( "New Password" : "新密码", "Reset password" : "重置密码", "Searching other places" : "搜索其他地方", + "No search results in other places" : "在其他地方没有搜索结果", "_{count} search result in other places_::_{count} search results in other places_" : ["在其他地方有 {count} 个搜索结果"], "Personal" : "个人", "Users" : "用户", @@ -174,6 +184,7 @@ OC.L10N.register( "File: %s" : "文件: %s", "Line: %s" : "行: %s", "Trace" : "追踪", + "Security warning" : "安全警告", "Your data directory and files are probably accessible from the internet because the .htaccess file does not work." : "您的数据目录和文件可能可以直接被互联网访问,因为 .htaccess 并未正常工作。", "For information how to properly configure your server, please see the <a href=\"%s\" target=\"_blank\">documentation</a>." : "关于如何配置服务器,请参见 <a href=\"%s\" target=\"_blank\">此文档</a>。", "Create an <strong>admin account</strong>" : "创建<strong>管理员账号</strong>", @@ -182,21 +193,28 @@ OC.L10N.register( "Data folder" : "数据目录", "Configure the database" : "配置数据库", "Only %s is available." : "仅 %s 可用。", + "Install and activate additional PHP modules to choose other database types." : "安装或激活额外的 PHP 模块以选择其他数据库类型。", + "For more details check out the documentation." : "请查阅文档获得详细信息。", "Database user" : "数据库用户", "Database password" : "数据库密码", "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 …" : "正在结束 ...", + "Need help?" : "需要帮助?", + "See the documentation" : "查看文档", "This application requires JavaScript for correct operation. Please {linkstart}enable JavaScript{linkend} and reload the page." : "对于正确的操作,该应用要求 JavaScript 。请 {linkstart} 打开 JavaScript {linkend} ,然后重新载入页面。", "Log out" : "注销", "Search" : "搜索", "Server side authentication failed!" : "服务端验证失败!", "Please contact your administrator." : "请联系你的管理员。", + "An internal error occured." : "发生了内部错误。", + "Please try again or contact your administrator." : "请重试或联系管理员。", "Forgot your password? Reset it!" : "忘记密码?立即重置!", "remember" : "记住", "Log in" : "登录", diff --git a/core/l10n/zh_CN.json b/core/l10n/zh_CN.json index 954f7c8c9cf..365cee1fb0b 100644 --- a/core/l10n/zh_CN.json +++ b/core/l10n/zh_CN.json @@ -2,6 +2,7 @@ "Couldn't send mail to following users: %s " : "无法发送邮件到用户: %s ", "Turned on maintenance mode" : "启用维护模式", "Turned off maintenance mode" : "关闭维护模式", + "Maintenance mode is kept active" : "维护模式已被启用", "Updated database" : "数据库已更新", "Checked database schema update" : "已经检查数据库架构更新", "Checked database schema update for apps" : "已经检查应用的数据库架构更新", @@ -71,8 +72,11 @@ "This server has no working Internet connection. This means that some of the features like mounting external storage, notifications about updates or installation of third-party apps will not work. Accessing files remotely and sending of notification emails might not work, either. We suggest to enable Internet connection for this server if you want to have all features." : "该服务器没有工作在互联网连接,这意味着像挂载外部存储,第三方应用的更新或者安装的通知将不会工作。远程文件访问和邮件通知的发送也可能不会工作。如果你想拥有所有功能,我们建议你为服务器打开互联网连接。", "Your data directory and your files are probably accessible from the Internet. The .htaccess file is not working. We strongly suggest that you configure your web server in a way that the data directory is no longer accessible or you move the data directory outside the web server document root." : "你的数据目录和你的文件可能从互联网被访问到。.htaccess 文件不工作。我们强烈建议你配置你的网页服务器,使数据目录不再可访问,或者将数据目录移动到网页服务器根文档目录之外。", "No memory cache has been configured. To enhance your performance please configure a memcache if available. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "内存缓存未配置。如果可用,请配置 memcache 来增强性能。更多信息请查看我们的<a href=\"{docLink}\">文档</a> 。", + "/dev/urandom is not readable by PHP which is highly discouraged for security reasons. Further information can be found in our <a href=\"{docLink}\">documentation</a>." : "/dev/urandom 无法被 PHP 读取,处于安全原因,这是强烈不推荐的。请查看<a href=\"{docLink}\">文档</a>了解详情。", "Error occurred while checking server setup" : "当检查服务器启动时出错", "The \"{header}\" HTTP header is not configured to equal to \"{expected}\". This is a potential security or privacy risk and we recommend adjusting this setting." : "\"{header}\" HTTP 头部没有配置和 \"{expected}\" 的一样。这是一个潜在的安全或者隐私风险,我们调整这项设置。", + "The \"Strict-Transport-Security\" HTTP header is not configured to least \"{seconds}\" seconds. For enhanced security we recommend enabling HSTS as described in our <a href=\"{docUrl}\">security tips</a>." : "HTTP 严格传输安全(Strict-Transport-Security)报头未配置到至少“{seconds}”秒。处于增强安全性考虑,我们推荐按照<a href=\"{docUrl}\">安全提示</a>启用 HSTS。", + "You are accessing this site via HTTP. We strongly suggest you configure your server to require using HTTPS instead as described in our <a href=\"{docUrl}\">security tips</a>." : "您正在通过 HTTP 访问该站点,我们强烈建议您按照<a href=\"{docUrl}\">安全提示</a>配置服务器强制使用 HTTPS。", "Shared" : "已共享", "Shared with {recipients}" : "由{recipients}分享", "Share" : "分享", @@ -82,6 +86,9 @@ "Error while changing permissions" : "修改权限时出错", "Shared with you and the group {group} by {owner}" : "{owner} 共享给您及 {group} 组", "Shared with you by {owner}" : "{owner} 与您共享", + "Share with users or groups …" : "分享给其他用户或组 ...", + "Share with users, groups or remote users …" : "分享给其他用户、组或远程用户 ...", + "Share with people on other ownClouds using the syntax username@example.com/owncloud" : "使用语法 username@example.com/owncloud 分享给其他 ownCloud 上的用户", "Share link" : "分享链接", "The public link will expire no later than {days} days after it is created" : "这个共享链接将在创建后 {days} 天失效", "Link" : "链接", @@ -94,6 +101,7 @@ "Set expiration date" : "设置过期日期", "Expiration" : "过期", "Expiration date" : "过期日期", + "An error occured. Please try again" : "发生了一个错误请重新尝试", "Adding user..." : "添加用户中...", "group" : "群组", "remote" : "远程", @@ -126,6 +134,7 @@ "Hello {name}, the weather is {weather}" : "您好 {name},今天天气是{weather}", "Hello {name}" : "你好 {name}", "_download %n file_::_download %n files_" : ["下载 %n 个文件"], + "{version} is available. Get more information on how to update." : "{version} 现在可用。获取更多升级相关信息。", "Updating {productName} to version {version}, this may take a while." : "更新 {productName} 到版本 {version},这可能需要一些时间。", "Please reload the page." : "请重新加载页面。", "The update was unsuccessful. " : "升级未成功", @@ -139,6 +148,7 @@ "New Password" : "新密码", "Reset password" : "重置密码", "Searching other places" : "搜索其他地方", + "No search results in other places" : "在其他地方没有搜索结果", "_{count} search result in other places_::_{count} search results in other places_" : ["在其他地方有 {count} 个搜索结果"], "Personal" : "个人", "Users" : "用户", @@ -172,6 +182,7 @@ "File: %s" : "文件: %s", "Line: %s" : "行: %s", "Trace" : "追踪", + "Security warning" : "安全警告", "Your data directory and files are probably accessible from the internet because the .htaccess file does not work." : "您的数据目录和文件可能可以直接被互联网访问,因为 .htaccess 并未正常工作。", "For information how to properly configure your server, please see the <a href=\"%s\" target=\"_blank\">documentation</a>." : "关于如何配置服务器,请参见 <a href=\"%s\" target=\"_blank\">此文档</a>。", "Create an <strong>admin account</strong>" : "创建<strong>管理员账号</strong>", @@ -180,21 +191,28 @@ "Data folder" : "数据目录", "Configure the database" : "配置数据库", "Only %s is available." : "仅 %s 可用。", + "Install and activate additional PHP modules to choose other database types." : "安装或激活额外的 PHP 模块以选择其他数据库类型。", + "For more details check out the documentation." : "请查阅文档获得详细信息。", "Database user" : "数据库用户", "Database password" : "数据库密码", "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 …" : "正在结束 ...", + "Need help?" : "需要帮助?", + "See the documentation" : "查看文档", "This application requires JavaScript for correct operation. Please {linkstart}enable JavaScript{linkend} and reload the page." : "对于正确的操作,该应用要求 JavaScript 。请 {linkstart} 打开 JavaScript {linkend} ,然后重新载入页面。", "Log out" : "注销", "Search" : "搜索", "Server side authentication failed!" : "服务端验证失败!", "Please contact your administrator." : "请联系你的管理员。", + "An internal error occured." : "发生了内部错误。", + "Please try again or contact your administrator." : "请重试或联系管理员。", "Forgot your password? Reset it!" : "忘记密码?立即重置!", "remember" : "记住", "Log in" : "登录", diff --git a/core/register_command.php b/core/register_command.php index 801148aa55e..03775fd7870 100644 --- a/core/register_command.php +++ b/core/register_command.php @@ -4,6 +4,7 @@ * @author Christian Kampka <christian@kampka.net> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/core/routes.php b/core/routes.php index 15554397cc1..57fa606f5fb 100644 --- a/core/routes.php +++ b/core/routes.php @@ -4,7 +4,6 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Christopher Schäpers <kondou@ts.unde.re> * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Roeland Jago Douma <roeland@famdouma.nl> diff --git a/core/strings.php b/core/strings.php index fdd3116b12f..e89228844d8 100644 --- a/core/strings.php +++ b/core/strings.php @@ -1,7 +1,6 @@ <?php /** * @author Jan-Christoph Borchardt <hey@jancborchardt.net> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/base.php b/lib/base.php index b9f2e4ad661..8812d5698f1 100644 --- a/lib/base.php +++ b/lib/base.php @@ -12,7 +12,7 @@ * @author Florin Peter <github@florin-peter.de> * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> + * @author Hugo Gonzalez Labrador <hglavra@gmail.com> * @author Jakob Sack <mail@jakobsack.de> * @author Jan-Christoph Borchardt <hey@jancborchardt.net> * @author Joas Schilling <nickvergessen@owncloud.com> @@ -730,8 +730,14 @@ class OC { // NOTE: This will be replaced to use OCP $userSession = self::$server->getUserSession(); $userSession->listen('\OC\User', 'postLogin', function () { - $cache = new \OC\Cache\File(); - $cache->gc(); + try { + $cache = new \OC\Cache\File(); + $cache->gc(); + } catch (\Exception $e) { + // a GC exception should not prevent users from using OC, + // so log the exception + \OC::$server->getLogger()->warning('Exception when running cache gc: ' . $e->getMessage(), array('app' => 'core')); + } }); } } diff --git a/lib/l10n/ast.js b/lib/l10n/ast.js index 9d51e3f82b3..65fc143fbe4 100644 --- a/lib/l10n/ast.js +++ b/lib/l10n/ast.js @@ -25,6 +25,7 @@ OC.L10N.register( "_%n minute ago_::_%n minutes ago_" : ["hai %n minutu","hai %n minutos"], "seconds ago" : "hai segundos", "web services under your control" : "servicios web baxo'l to control", + "File name contains at least one invalid character" : "El nome del ficheru contién polo menos un carácter non válidu", "App directory already exists" : "El direutoriu de l'aplicación yá esiste", "Can't create app folder. Please fix permissions. %s" : "Nun pue crease la carpeta de l'aplicación. Por favor, igua los permisos. %s", "No source specified when installing app" : "Nun s'especificó nenguna fonte al instalar app", diff --git a/lib/l10n/ast.json b/lib/l10n/ast.json index 788455ab179..675451858e9 100644 --- a/lib/l10n/ast.json +++ b/lib/l10n/ast.json @@ -23,6 +23,7 @@ "_%n minute ago_::_%n minutes ago_" : ["hai %n minutu","hai %n minutos"], "seconds ago" : "hai segundos", "web services under your control" : "servicios web baxo'l to control", + "File name contains at least one invalid character" : "El nome del ficheru contién polo menos un carácter non válidu", "App directory already exists" : "El direutoriu de l'aplicación yá esiste", "Can't create app folder. Please fix permissions. %s" : "Nun pue crease la carpeta de l'aplicación. Por favor, igua los permisos. %s", "No source specified when installing app" : "Nun s'especificó nenguna fonte al instalar app", diff --git a/lib/l10n/cs_CZ.js b/lib/l10n/cs_CZ.js index 01817f5cde5..fd30fc3463b 100644 --- a/lib/l10n/cs_CZ.js +++ b/lib/l10n/cs_CZ.js @@ -38,12 +38,14 @@ OC.L10N.register( "_%n minute ago_::_%n minutes ago_" : ["před %n minutou","před %n minutami","před %n minutami"], "seconds ago" : "před pár sekundami", "web services under your control" : "webové služby pod Vaší kontrolou", + "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Modul s id: %s neexistuje. Povolte ho prosím ve svých nastaveních aplikací nebo kontaktujte svého administrátora.", "Empty filename is not allowed" : "Prázdné jméno souboru není povoleno", "Dot files are not allowed" : "Jména souborů začínající tečkou nejsou povolena", "4-byte characters are not supported in file names" : "4-bytové znaky nejsou podporovány ve jménech souborů", "File name is a reserved word" : "Jméno souboru je rezervované slovo", "File name contains at least one invalid character" : "Jméno souboru obsahuje nejméně jeden neplatný znak", "File name is too long" : "Jméno souboru je moc dlouhé", + "File is currently busy, please try again later" : "Soubor je používán, zkus to později", "Can't read file" : "Nelze přečíst soubor", "App directory already exists" : "Adresář aplikace již existuje", "Can't create app folder. Please fix permissions. %s" : "Nelze vytvořit složku aplikace. Opravte práva souborů. %s", @@ -84,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Zadejte uživatelské jméno správce.", "Set an admin password." : "Zadejte heslo správce.", "Can't create or write into the data directory %s" : "Nelze vytvořit nebo zapisovat do datového adresáře %s", + "Invalid Federated Cloud ID" : "Neplatné sdružené cloud ID", "%s shared »%s« with you" : "%s s vámi sdílí »%s«", "%s via %s" : "%s pomocí %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Sdílení %s selhalo, podpůrná vrstva nepodporuje typ sdílení %i", diff --git a/lib/l10n/cs_CZ.json b/lib/l10n/cs_CZ.json index ab5e4662633..3ee3cc16587 100644 --- a/lib/l10n/cs_CZ.json +++ b/lib/l10n/cs_CZ.json @@ -36,12 +36,14 @@ "_%n minute ago_::_%n minutes ago_" : ["před %n minutou","před %n minutami","před %n minutami"], "seconds ago" : "před pár sekundami", "web services under your control" : "webové služby pod Vaší kontrolou", + "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Modul s id: %s neexistuje. Povolte ho prosím ve svých nastaveních aplikací nebo kontaktujte svého administrátora.", "Empty filename is not allowed" : "Prázdné jméno souboru není povoleno", "Dot files are not allowed" : "Jména souborů začínající tečkou nejsou povolena", "4-byte characters are not supported in file names" : "4-bytové znaky nejsou podporovány ve jménech souborů", "File name is a reserved word" : "Jméno souboru je rezervované slovo", "File name contains at least one invalid character" : "Jméno souboru obsahuje nejméně jeden neplatný znak", "File name is too long" : "Jméno souboru je moc dlouhé", + "File is currently busy, please try again later" : "Soubor je používán, zkus to později", "Can't read file" : "Nelze přečíst soubor", "App directory already exists" : "Adresář aplikace již existuje", "Can't create app folder. Please fix permissions. %s" : "Nelze vytvořit složku aplikace. Opravte práva souborů. %s", @@ -82,6 +84,7 @@ "Set an admin username." : "Zadejte uživatelské jméno správce.", "Set an admin password." : "Zadejte heslo správce.", "Can't create or write into the data directory %s" : "Nelze vytvořit nebo zapisovat do datového adresáře %s", + "Invalid Federated Cloud ID" : "Neplatné sdružené cloud ID", "%s shared »%s« with you" : "%s s vámi sdílí »%s«", "%s via %s" : "%s pomocí %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Sdílení %s selhalo, podpůrná vrstva nepodporuje typ sdílení %i", diff --git a/lib/l10n/el.js b/lib/l10n/el.js index 5119ed41c12..4ead3fb9254 100644 --- a/lib/l10n/el.js +++ b/lib/l10n/el.js @@ -42,6 +42,7 @@ OC.L10N.register( "File name is a reserved word" : "Το όνομα αρχείου είναι λέξη που έχει δεσμευτεί", "File name contains at least one invalid character" : "Το όνομα αρχείου περιέχει έναν τουλάχιστον μη έγκυρο χαρακτήρα", "File name is too long" : "Το όνομα αρχείου είνια πολύ μεγάλο", + "File is currently busy, please try again later" : "Το αρχείο χρησιμοποιείται αυτή τη στιγμή, παρακαλώ προσπαθήστε αργότερα", "Can't read file" : "Αδυναμία ανάγνωσης αρχείου", "App directory already exists" : "Ο κατάλογος εφαρμογών υπάρχει ήδη", "Can't create app folder. Please fix permissions. %s" : "Δεν είναι δυνατόν να δημιουργηθεί ο φάκελος εφαρμογής. Παρακαλώ διορθώστε τις άδειες πρόσβασης. %s", @@ -82,6 +83,7 @@ OC.L10N.register( "Set an admin username." : "Εισάγετε όνομα χρήστη διαχειριστή.", "Set an admin password." : "Εισάγετε συνθηματικό διαχειριστή.", "Can't create or write into the data directory %s" : "Αδύνατη η δημιουργία ή συγγραφή στον κατάλογο δεδομένων %s", + "Invalid Federated Cloud ID" : "Μη έγκυρο Federated Cloud ID", "%s shared »%s« with you" : "Ο %s διαμοιράστηκε μαζί σας το »%s«", "%s via %s" : "%s μέσω %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Αποτυχία διαμοιρασμού %s, γιατί το σύστημα υποστήριξης δεν επιτρέπει κοινόχρηστα τύπου %i", diff --git a/lib/l10n/el.json b/lib/l10n/el.json index 84eb654c90e..bb6df966a87 100644 --- a/lib/l10n/el.json +++ b/lib/l10n/el.json @@ -40,6 +40,7 @@ "File name is a reserved word" : "Το όνομα αρχείου είναι λέξη που έχει δεσμευτεί", "File name contains at least one invalid character" : "Το όνομα αρχείου περιέχει έναν τουλάχιστον μη έγκυρο χαρακτήρα", "File name is too long" : "Το όνομα αρχείου είνια πολύ μεγάλο", + "File is currently busy, please try again later" : "Το αρχείο χρησιμοποιείται αυτή τη στιγμή, παρακαλώ προσπαθήστε αργότερα", "Can't read file" : "Αδυναμία ανάγνωσης αρχείου", "App directory already exists" : "Ο κατάλογος εφαρμογών υπάρχει ήδη", "Can't create app folder. Please fix permissions. %s" : "Δεν είναι δυνατόν να δημιουργηθεί ο φάκελος εφαρμογής. Παρακαλώ διορθώστε τις άδειες πρόσβασης. %s", @@ -80,6 +81,7 @@ "Set an admin username." : "Εισάγετε όνομα χρήστη διαχειριστή.", "Set an admin password." : "Εισάγετε συνθηματικό διαχειριστή.", "Can't create or write into the data directory %s" : "Αδύνατη η δημιουργία ή συγγραφή στον κατάλογο δεδομένων %s", + "Invalid Federated Cloud ID" : "Μη έγκυρο Federated Cloud ID", "%s shared »%s« with you" : "Ο %s διαμοιράστηκε μαζί σας το »%s«", "%s via %s" : "%s μέσω %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Αποτυχία διαμοιρασμού %s, γιατί το σύστημα υποστήριξης δεν επιτρέπει κοινόχρηστα τύπου %i", diff --git a/lib/l10n/es.js b/lib/l10n/es.js index 0a5eadd24bd..42ecd7e7bb1 100644 --- a/lib/l10n/es.js +++ b/lib/l10n/es.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "El nombre de archivo es una palabra reservada", "File name contains at least one invalid character" : "El nombre del archivo contiene al menos un carácter inválido", "File name is too long" : "El nombre del archivo es demasiado largo", + "File is currently busy, please try again later" : "Archivo se encuentra actualmente ocupado, por favor inténtelo de nuevo más tarde", "Can't read file" : "No se puede leer archivo", "App directory already exists" : "El directorio de la aplicación ya existe", "Can't create app folder. Please fix permissions. %s" : "No se puede crear la carpeta de la aplicación. Corrija los permisos. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Configurar un nombre de usuario del administrador", "Set an admin password." : "Configurar la contraseña del administrador.", "Can't create or write into the data directory %s" : "No es posible crear o escribir en el directorio de datos %s", + "Invalid Federated Cloud ID" : "ID Nube federada inválida", "%s shared »%s« with you" : "%s ha compartido »%s« contigo", "%s via %s" : "%s vía %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "No se pudo compartir %s porque el repositorio no permite recursos compartidos del tipo %i", diff --git a/lib/l10n/es.json b/lib/l10n/es.json index 7398e7243c4..6f28071f04b 100644 --- a/lib/l10n/es.json +++ b/lib/l10n/es.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "El nombre de archivo es una palabra reservada", "File name contains at least one invalid character" : "El nombre del archivo contiene al menos un carácter inválido", "File name is too long" : "El nombre del archivo es demasiado largo", + "File is currently busy, please try again later" : "Archivo se encuentra actualmente ocupado, por favor inténtelo de nuevo más tarde", "Can't read file" : "No se puede leer archivo", "App directory already exists" : "El directorio de la aplicación ya existe", "Can't create app folder. Please fix permissions. %s" : "No se puede crear la carpeta de la aplicación. Corrija los permisos. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Configurar un nombre de usuario del administrador", "Set an admin password." : "Configurar la contraseña del administrador.", "Can't create or write into the data directory %s" : "No es posible crear o escribir en el directorio de datos %s", + "Invalid Federated Cloud ID" : "ID Nube federada inválida", "%s shared »%s« with you" : "%s ha compartido »%s« contigo", "%s via %s" : "%s vía %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "No se pudo compartir %s porque el repositorio no permite recursos compartidos del tipo %i", diff --git a/lib/l10n/et_EE.js b/lib/l10n/et_EE.js index 284c9556322..2d211f341b9 100644 --- a/lib/l10n/et_EE.js +++ b/lib/l10n/et_EE.js @@ -18,10 +18,17 @@ OC.L10N.register( "Invalid image" : "Vigane pilt", "today" : "täna", "yesterday" : "eile", + "_%n day ago_::_%n days ago_" : ["%n päev tagasi","%n päeva tagasi"], "last month" : "viimasel kuul", "last year" : "viimasel aastal", + "_%n year ago_::_%n years ago_" : ["%n aasta tagasi","%n aastat tagasi"], "seconds ago" : "sekundit tagasi", "web services under your control" : "veebitenused sinu kontrolli all", + "Empty filename is not allowed" : "Tühi failinimi pole lubatud", + "Dot files are not allowed" : "Punktiga failid pole lubatud", + "File name contains at least one invalid character" : "Faili nimesonvähemalt üks keelatud märk", + "File name is too long" : "Faili nimi on liiga pikk", + "Can't read file" : "Faili lugemine ebaõnnestus", "App directory already exists" : "Rakendi kataloog on juba olemas", "Can't create app folder. Please fix permissions. %s" : "Ei saa luua rakendi kataloogi. Palun korrigeeri õigusi. %s", "No source specified when installing app" : "Ühegi lähteallikat pole rakendi paigalduseks määratletud", diff --git a/lib/l10n/et_EE.json b/lib/l10n/et_EE.json index b19225c16e2..c23fd35f541 100644 --- a/lib/l10n/et_EE.json +++ b/lib/l10n/et_EE.json @@ -16,10 +16,17 @@ "Invalid image" : "Vigane pilt", "today" : "täna", "yesterday" : "eile", + "_%n day ago_::_%n days ago_" : ["%n päev tagasi","%n päeva tagasi"], "last month" : "viimasel kuul", "last year" : "viimasel aastal", + "_%n year ago_::_%n years ago_" : ["%n aasta tagasi","%n aastat tagasi"], "seconds ago" : "sekundit tagasi", "web services under your control" : "veebitenused sinu kontrolli all", + "Empty filename is not allowed" : "Tühi failinimi pole lubatud", + "Dot files are not allowed" : "Punktiga failid pole lubatud", + "File name contains at least one invalid character" : "Faili nimesonvähemalt üks keelatud märk", + "File name is too long" : "Faili nimi on liiga pikk", + "Can't read file" : "Faili lugemine ebaõnnestus", "App directory already exists" : "Rakendi kataloog on juba olemas", "Can't create app folder. Please fix permissions. %s" : "Ei saa luua rakendi kataloogi. Palun korrigeeri õigusi. %s", "No source specified when installing app" : "Ühegi lähteallikat pole rakendi paigalduseks määratletud", diff --git a/lib/l10n/fi_FI.js b/lib/l10n/fi_FI.js index 28d4556cc12..c8b5fb5bdb4 100644 --- a/lib/l10n/fi_FI.js +++ b/lib/l10n/fi_FI.js @@ -37,11 +37,13 @@ OC.L10N.register( "_%n minute ago_::_%n minutes ago_" : ["%n minuutti sitten","%n minuuttia sitten"], "seconds ago" : "sekuntia sitten", "web services under your control" : "verkkopalvelut hallinnassasi", + "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Moduulia tunnisteella %s ei ole olemassa. Ota se käyttöön sovellusasetuksista tai ota yhteys ylläpitoon.", "Empty filename is not allowed" : "Tiedostonimi ei voi olla tyhjä", "Dot files are not allowed" : "Pistetiedostot eivät ole sallittuja", "4-byte characters are not supported in file names" : "4 tavun merkit eivät ole tuettuja tiedostojen nimissä", "File name contains at least one invalid character" : "Tiedoston nimi sisältää ainakin yhden virheellisen merkin", "File name is too long" : "Tiedoston nimi on liian pitkä", + "File is currently busy, please try again later" : "Tiedosto on parhaillaan käytössä, yritä myöhemmin uudelleen", "Can't read file" : "Tiedostoa ei voi lukea", "App directory already exists" : "Sovelluskansio on jo olemassa", "Can't create app folder. Please fix permissions. %s" : "Sovelluskansion luominen ei onnistu. Korjaa käyttöoikeudet. %s", diff --git a/lib/l10n/fi_FI.json b/lib/l10n/fi_FI.json index d6842c69102..83171dd042c 100644 --- a/lib/l10n/fi_FI.json +++ b/lib/l10n/fi_FI.json @@ -35,11 +35,13 @@ "_%n minute ago_::_%n minutes ago_" : ["%n minuutti sitten","%n minuuttia sitten"], "seconds ago" : "sekuntia sitten", "web services under your control" : "verkkopalvelut hallinnassasi", + "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Moduulia tunnisteella %s ei ole olemassa. Ota se käyttöön sovellusasetuksista tai ota yhteys ylläpitoon.", "Empty filename is not allowed" : "Tiedostonimi ei voi olla tyhjä", "Dot files are not allowed" : "Pistetiedostot eivät ole sallittuja", "4-byte characters are not supported in file names" : "4 tavun merkit eivät ole tuettuja tiedostojen nimissä", "File name contains at least one invalid character" : "Tiedoston nimi sisältää ainakin yhden virheellisen merkin", "File name is too long" : "Tiedoston nimi on liian pitkä", + "File is currently busy, please try again later" : "Tiedosto on parhaillaan käytössä, yritä myöhemmin uudelleen", "Can't read file" : "Tiedostoa ei voi lukea", "App directory already exists" : "Sovelluskansio on jo olemassa", "Can't create app folder. Please fix permissions. %s" : "Sovelluskansion luominen ei onnistu. Korjaa käyttöoikeudet. %s", diff --git a/lib/l10n/fr.js b/lib/l10n/fr.js index e320dec38f7..dcb797478fd 100644 --- a/lib/l10n/fr.js +++ b/lib/l10n/fr.js @@ -44,6 +44,7 @@ OC.L10N.register( "File name is a reserved word" : "Ce nom de fichier est un mot réservé", "File name contains at least one invalid character" : "Le nom de fichier contient un (des) caractère(s) non valide(s)", "File name is too long" : "Nom de fichier trop long", + "File is currently busy, please try again later" : "Le fichier est actuellement occupé, veuillez ré-essayer ultérieurement.", "Can't read file" : "Impossible de lire le fichier", "App directory already exists" : "Le dossier de l'application existe déjà", "Can't create app folder. Please fix permissions. %s" : "Impossible de créer le dossier de l'application. Corrigez les droits d'accès. %s", @@ -119,14 +120,14 @@ OC.L10N.register( "The username is already being used" : "Ce nom d'utilisateur est déjà utilisé", "No database drivers (sqlite, mysql, or postgresql) installed." : "Aucun pilote de base de données n’est installé (sqlite, mysql ou postgresql).", "Microsoft Windows Platform is not supported" : "La plate-forme Microsoft Windows n'est pas prise en charge.", - "Running ownCloud Server on the Microsoft Windows platform is not supported. We suggest you use a Linux server in a virtual machine if you have no option for migrating the server itself. Find Linux packages as well as easy to deploy virtual machine images on <a href=\"%s\">%s</a>. For migrating existing installations to Linux you can find some tips and a migration script in <a href=\"%s\">our documentation</a>." : "Executer un serveur ownCloud sur une plate-forme Microsoft Windows n'est pas pris en charge. Nous vous suggérons d'utiliser un serveur Linux sur une machine virtuelle si vous n'avez pas la possibilité de migrer votre serveur. Les paquets Linux ainsi que des images virtuelles faciles à déployer se trouvent sur <a href=\"%s\">%s</a>. Pour migrer des installations existantes vers Linux, vous trouverez des conseils et des scripts de migration dans <a href=\"%s\">notre documentation</a>.", + "Running ownCloud Server on the Microsoft Windows platform is not supported. We suggest you use a Linux server in a virtual machine if you have no option for migrating the server itself. Find Linux packages as well as easy to deploy virtual machine images on <a href=\"%s\">%s</a>. For migrating existing installations to Linux you can find some tips and a migration script in <a href=\"%s\">our documentation</a>." : "Executer un serveur ownCloud sur une plate-forme Microsoft Windows n'est pas pris en charge. Si vous n'avez pas la possibilité de migrer votre serveur, nous vous suggérons d'utiliser un serveur Linux dans une machine virtuelle . Les paquets Linux nécessaires ainsi que des images virtuelles faciles à déployer se trouvent sur <a href=\"%s\">%s</a>. Pour migrer des installations existantes vers Linux, vous trouverez des conseils et des scripts de migration dans <a href=\"%s\">notre documentation</a>.", "Cannot write into \"config\" directory" : "Impossible d’écrire dans le répertoire \"config\"", "Cannot write into \"apps\" directory" : "Impossible d’écrire dans le répertoire \"apps\"", "This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Ce problème est généralement résolu %sen donnant au serveur web un accès en écriture au répertoire apps%s ou en désactivant l'appstore dans le fichier de configuration.", "Cannot create \"data\" directory (%s)" : "Impossible de créer le répertoire \"data\" (%s)", "This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Ce problème est généralement résolu <a href=\"%s\" target=\"_blank\">en donnant au serveur web un accès en écriture au répertoire racine</a>.", "Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Le problème de permissions peut généralement être résolu %sen donnant au serveur web un accès en écriture au répertoire racine%s", - "Setting locale to %s failed" : "La spécification des paramètres régionaux à %s a échoué", + "Setting locale to %s failed" : "Echec de la spécification des paramètres régionaux à %s", "Please install one of these locales on your system and restart your webserver." : "Veuillez installer l'un de ces paramètres régionaux sur votre système et redémarrer votre serveur web.", "Please ask your server administrator to install the module." : "Veuillez demander à votre administrateur d’installer le module.", "PHP module %s not installed." : "Le module PHP %s n’est pas installé.", diff --git a/lib/l10n/fr.json b/lib/l10n/fr.json index 141de893071..b5b1ce1a0da 100644 --- a/lib/l10n/fr.json +++ b/lib/l10n/fr.json @@ -42,6 +42,7 @@ "File name is a reserved word" : "Ce nom de fichier est un mot réservé", "File name contains at least one invalid character" : "Le nom de fichier contient un (des) caractère(s) non valide(s)", "File name is too long" : "Nom de fichier trop long", + "File is currently busy, please try again later" : "Le fichier est actuellement occupé, veuillez ré-essayer ultérieurement.", "Can't read file" : "Impossible de lire le fichier", "App directory already exists" : "Le dossier de l'application existe déjà", "Can't create app folder. Please fix permissions. %s" : "Impossible de créer le dossier de l'application. Corrigez les droits d'accès. %s", @@ -117,14 +118,14 @@ "The username is already being used" : "Ce nom d'utilisateur est déjà utilisé", "No database drivers (sqlite, mysql, or postgresql) installed." : "Aucun pilote de base de données n’est installé (sqlite, mysql ou postgresql).", "Microsoft Windows Platform is not supported" : "La plate-forme Microsoft Windows n'est pas prise en charge.", - "Running ownCloud Server on the Microsoft Windows platform is not supported. We suggest you use a Linux server in a virtual machine if you have no option for migrating the server itself. Find Linux packages as well as easy to deploy virtual machine images on <a href=\"%s\">%s</a>. For migrating existing installations to Linux you can find some tips and a migration script in <a href=\"%s\">our documentation</a>." : "Executer un serveur ownCloud sur une plate-forme Microsoft Windows n'est pas pris en charge. Nous vous suggérons d'utiliser un serveur Linux sur une machine virtuelle si vous n'avez pas la possibilité de migrer votre serveur. Les paquets Linux ainsi que des images virtuelles faciles à déployer se trouvent sur <a href=\"%s\">%s</a>. Pour migrer des installations existantes vers Linux, vous trouverez des conseils et des scripts de migration dans <a href=\"%s\">notre documentation</a>.", + "Running ownCloud Server on the Microsoft Windows platform is not supported. We suggest you use a Linux server in a virtual machine if you have no option for migrating the server itself. Find Linux packages as well as easy to deploy virtual machine images on <a href=\"%s\">%s</a>. For migrating existing installations to Linux you can find some tips and a migration script in <a href=\"%s\">our documentation</a>." : "Executer un serveur ownCloud sur une plate-forme Microsoft Windows n'est pas pris en charge. Si vous n'avez pas la possibilité de migrer votre serveur, nous vous suggérons d'utiliser un serveur Linux dans une machine virtuelle . Les paquets Linux nécessaires ainsi que des images virtuelles faciles à déployer se trouvent sur <a href=\"%s\">%s</a>. Pour migrer des installations existantes vers Linux, vous trouverez des conseils et des scripts de migration dans <a href=\"%s\">notre documentation</a>.", "Cannot write into \"config\" directory" : "Impossible d’écrire dans le répertoire \"config\"", "Cannot write into \"apps\" directory" : "Impossible d’écrire dans le répertoire \"apps\"", "This can usually be fixed by %sgiving the webserver write access to the apps directory%s or disabling the appstore in the config file." : "Ce problème est généralement résolu %sen donnant au serveur web un accès en écriture au répertoire apps%s ou en désactivant l'appstore dans le fichier de configuration.", "Cannot create \"data\" directory (%s)" : "Impossible de créer le répertoire \"data\" (%s)", "This can usually be fixed by <a href=\"%s\" target=\"_blank\">giving the webserver write access to the root directory</a>." : "Ce problème est généralement résolu <a href=\"%s\" target=\"_blank\">en donnant au serveur web un accès en écriture au répertoire racine</a>.", "Permissions can usually be fixed by %sgiving the webserver write access to the root directory%s." : "Le problème de permissions peut généralement être résolu %sen donnant au serveur web un accès en écriture au répertoire racine%s", - "Setting locale to %s failed" : "La spécification des paramètres régionaux à %s a échoué", + "Setting locale to %s failed" : "Echec de la spécification des paramètres régionaux à %s", "Please install one of these locales on your system and restart your webserver." : "Veuillez installer l'un de ces paramètres régionaux sur votre système et redémarrer votre serveur web.", "Please ask your server administrator to install the module." : "Veuillez demander à votre administrateur d’installer le module.", "PHP module %s not installed." : "Le module PHP %s n’est pas installé.", diff --git a/lib/l10n/gl.js b/lib/l10n/gl.js index a26402aa062..67356d1c673 100644 --- a/lib/l10n/gl.js +++ b/lib/l10n/gl.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "O nome de ficheiro é unha palabra reservada", "File name contains at least one invalid character" : "O nome de ficheiro contén algún carácter incorrecto", "File name is too long" : "O nome de ficheiro é longo de máis", + "File is currently busy, please try again later" : "O ficheiro está ocupado neste momento, tenteo máis tarde.", "Can't read file" : "Non é posíbel ler o ficheiro", "App directory already exists" : "Xa existe o directorio da aplicación", "Can't create app folder. Please fix permissions. %s" : "Non é posíbel crear o cartafol de aplicacións. Corrixa os permisos. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Estabeleza un nome de usuario administrador", "Set an admin password." : "Estabeleza un contrasinal de administrador", "Can't create or write into the data directory %s" : "Non é posíbel crear ou escribir o directorio «data» %s", + "Invalid Federated Cloud ID" : "ID de nube federada incorrecto", "%s shared »%s« with you" : "%s compartiu «%s» con vostede", "%s via %s" : "%s vía %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Fallou a compartición de %s, xa que a infraestrutura non permite accións do tipo %i", diff --git a/lib/l10n/gl.json b/lib/l10n/gl.json index 9dea5d004d0..355ba0dec48 100644 --- a/lib/l10n/gl.json +++ b/lib/l10n/gl.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "O nome de ficheiro é unha palabra reservada", "File name contains at least one invalid character" : "O nome de ficheiro contén algún carácter incorrecto", "File name is too long" : "O nome de ficheiro é longo de máis", + "File is currently busy, please try again later" : "O ficheiro está ocupado neste momento, tenteo máis tarde.", "Can't read file" : "Non é posíbel ler o ficheiro", "App directory already exists" : "Xa existe o directorio da aplicación", "Can't create app folder. Please fix permissions. %s" : "Non é posíbel crear o cartafol de aplicacións. Corrixa os permisos. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Estabeleza un nome de usuario administrador", "Set an admin password." : "Estabeleza un contrasinal de administrador", "Can't create or write into the data directory %s" : "Non é posíbel crear ou escribir o directorio «data» %s", + "Invalid Federated Cloud ID" : "ID de nube federada incorrecto", "%s shared »%s« with you" : "%s compartiu «%s» con vostede", "%s via %s" : "%s vía %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Fallou a compartición de %s, xa que a infraestrutura non permite accións do tipo %i", diff --git a/lib/l10n/it.js b/lib/l10n/it.js index cd821421201..1bdda442f01 100644 --- a/lib/l10n/it.js +++ b/lib/l10n/it.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "Il nome del file è una parola riservata", "File name contains at least one invalid character" : "Il nome del file contiene almeno un carattere non valido", "File name is too long" : "Il nome del file è troppo lungo", + "File is currently busy, please try again later" : "Il file è attualmente occupato, riprova più tardi", "Can't read file" : "Impossibile leggere il file", "App directory already exists" : "La cartella dell'applicazione esiste già", "Can't create app folder. Please fix permissions. %s" : "Impossibile creare la cartella dell'applicazione. Correggi i permessi. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Imposta un nome utente di amministrazione.", "Set an admin password." : "Imposta una password di amministrazione.", "Can't create or write into the data directory %s" : "Impossibile creare o scrivere nella cartella dei dati %s", + "Invalid Federated Cloud ID" : "ID di cloud federata non valido", "%s shared »%s« with you" : "%s ha condiviso «%s» con te", "%s via %s" : "%s tramite %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Condivisione di %s non riuscita, poiché il motore non consente condivisioni del tipo %i", diff --git a/lib/l10n/it.json b/lib/l10n/it.json index 2d6d28d2168..f802e65993b 100644 --- a/lib/l10n/it.json +++ b/lib/l10n/it.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "Il nome del file è una parola riservata", "File name contains at least one invalid character" : "Il nome del file contiene almeno un carattere non valido", "File name is too long" : "Il nome del file è troppo lungo", + "File is currently busy, please try again later" : "Il file è attualmente occupato, riprova più tardi", "Can't read file" : "Impossibile leggere il file", "App directory already exists" : "La cartella dell'applicazione esiste già", "Can't create app folder. Please fix permissions. %s" : "Impossibile creare la cartella dell'applicazione. Correggi i permessi. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Imposta un nome utente di amministrazione.", "Set an admin password." : "Imposta una password di amministrazione.", "Can't create or write into the data directory %s" : "Impossibile creare o scrivere nella cartella dei dati %s", + "Invalid Federated Cloud ID" : "ID di cloud federata non valido", "%s shared »%s« with you" : "%s ha condiviso «%s» con te", "%s via %s" : "%s tramite %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Condivisione di %s non riuscita, poiché il motore non consente condivisioni del tipo %i", diff --git a/lib/l10n/nb_NO.js b/lib/l10n/nb_NO.js index 7af3c98bdc3..e797430c102 100644 --- a/lib/l10n/nb_NO.js +++ b/lib/l10n/nb_NO.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "Filnavnet er et reservert ord", "File name contains at least one invalid character" : "Filnavnet inneholder minst ett ulovlig tegn", "File name is too long" : "Filnavnet er for langt", + "File is currently busy, please try again later" : "Filen er opptatt for øyeblikket, prøv igjen senere", "Can't read file" : "Kan ikke lese fil", "App directory already exists" : "App-mappe finnes allerede", "Can't create app folder. Please fix permissions. %s" : "Kan ikke opprette app-mappe. Vennligst ordne opp i tillatelser. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Sett et admin-brukernavn.", "Set an admin password." : "Sett et admin-passord.", "Can't create or write into the data directory %s" : "Kan ikke opprette eller skrive i datamappen %s", + "Invalid Federated Cloud ID" : "Ugyldig ID for sammenknyttet sky", "%s shared »%s« with you" : "%s delte »%s« med deg", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Deling av %s feilet, fordi serveren ikke tillater delinger fra type %i", diff --git a/lib/l10n/nb_NO.json b/lib/l10n/nb_NO.json index 671e5bde226..081927ea686 100644 --- a/lib/l10n/nb_NO.json +++ b/lib/l10n/nb_NO.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "Filnavnet er et reservert ord", "File name contains at least one invalid character" : "Filnavnet inneholder minst ett ulovlig tegn", "File name is too long" : "Filnavnet er for langt", + "File is currently busy, please try again later" : "Filen er opptatt for øyeblikket, prøv igjen senere", "Can't read file" : "Kan ikke lese fil", "App directory already exists" : "App-mappe finnes allerede", "Can't create app folder. Please fix permissions. %s" : "Kan ikke opprette app-mappe. Vennligst ordne opp i tillatelser. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Sett et admin-brukernavn.", "Set an admin password." : "Sett et admin-passord.", "Can't create or write into the data directory %s" : "Kan ikke opprette eller skrive i datamappen %s", + "Invalid Federated Cloud ID" : "Ugyldig ID for sammenknyttet sky", "%s shared »%s« with you" : "%s delte »%s« med deg", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Deling av %s feilet, fordi serveren ikke tillater delinger fra type %i", diff --git a/lib/l10n/nl.js b/lib/l10n/nl.js index f98f194d233..25e4f35241a 100644 --- a/lib/l10n/nl.js +++ b/lib/l10n/nl.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "Bestandsnaam is een gereserveerd woord", "File name contains at least one invalid character" : "De bestandsnaam bevat ten minste één verboden teken", "File name is too long" : "De bestandsnaam is te lang", + "File is currently busy, please try again later" : "Bestandsverwerking bezig, probeer het later opnieuw", "Can't read file" : "Kan bestand niet lezen", "App directory already exists" : "App directory bestaat al", "Can't create app folder. Please fix permissions. %s" : "Kan de app map niet aanmaken, Herstel de permissies. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Stel de gebruikersnaam van de beheerder in.", "Set an admin password." : "Stel een beheerderswachtwoord in.", "Can't create or write into the data directory %s" : "Kan niets creëren of wegschrijven in datadirectory %s", + "Invalid Federated Cloud ID" : "Ongeldige Federated Cloud ID", "%s shared »%s« with you" : "%s deelde »%s« met u", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Delen van %s is mislukt, omdat de share-backend niet toestaat om type %i te delen", diff --git a/lib/l10n/nl.json b/lib/l10n/nl.json index 7615a9dc851..d5b0dba3214 100644 --- a/lib/l10n/nl.json +++ b/lib/l10n/nl.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "Bestandsnaam is een gereserveerd woord", "File name contains at least one invalid character" : "De bestandsnaam bevat ten minste één verboden teken", "File name is too long" : "De bestandsnaam is te lang", + "File is currently busy, please try again later" : "Bestandsverwerking bezig, probeer het later opnieuw", "Can't read file" : "Kan bestand niet lezen", "App directory already exists" : "App directory bestaat al", "Can't create app folder. Please fix permissions. %s" : "Kan de app map niet aanmaken, Herstel de permissies. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Stel de gebruikersnaam van de beheerder in.", "Set an admin password." : "Stel een beheerderswachtwoord in.", "Can't create or write into the data directory %s" : "Kan niets creëren of wegschrijven in datadirectory %s", + "Invalid Federated Cloud ID" : "Ongeldige Federated Cloud ID", "%s shared »%s« with you" : "%s deelde »%s« met u", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Delen van %s is mislukt, omdat de share-backend niet toestaat om type %i te delen", diff --git a/lib/l10n/pt_BR.js b/lib/l10n/pt_BR.js index d9d4c04156b..05abaa83ebb 100644 --- a/lib/l10n/pt_BR.js +++ b/lib/l10n/pt_BR.js @@ -31,8 +31,11 @@ OC.L10N.register( "yesterday" : "ontem", "_%n day ago_::_%n days ago_" : ["%n dia atrás","%n dias atrás"], "last month" : "último mês", + "_%n month ago_::_%n months ago_" : ["há %n mês atrás","há %n meses atrás"], "last year" : "último ano", "_%n year ago_::_%n years ago_" : ["%n ano atrás","%n anos atrás"], + "_%n hour ago_::_%n hours ago_" : ["há %n hora atrás","há %n horas atrás"], + "_%n minute ago_::_%n minutes ago_" : ["há %n minuto atrás","há %n minutos atrás"], "seconds ago" : "segundos atrás", "web services under your control" : "serviços web sob seu controle", "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Módulo com id: %s não existe. Ative-o em suas configurações de aplicativos ou contate o administrador.", @@ -42,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "O nome do arquivo é uma palavra reservada", "File name contains at least one invalid character" : "O nome do arquivo contém pelo menos um caractere inválido", "File name is too long" : "O nome do arquivo é muito longo", + "File is currently busy, please try again later" : "O arquivo está ocupado, tente novamente mais tarde", "Can't read file" : "Não é possível ler arquivo", "App directory already exists" : "Diretório App já existe", "Can't create app folder. Please fix permissions. %s" : "Não é possível criar pasta app. Corrija as permissões. %s", @@ -82,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Defina um nome do usuário administrador.", "Set an admin password." : "Defina uma senha de administrador.", "Can't create or write into the data directory %s" : "Não é possível criar ou gravar no diretório de dados %s", + "Invalid Federated Cloud ID" : "Associação Inválida de Nuvem ID", "%s shared »%s« with you" : "%s compartilhou »%s« com você", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "O compartilhamento %s falhou, porque o processo interno não permite ações de tipo %i", diff --git a/lib/l10n/pt_BR.json b/lib/l10n/pt_BR.json index fe6fc1c3dba..454e3f05b8a 100644 --- a/lib/l10n/pt_BR.json +++ b/lib/l10n/pt_BR.json @@ -29,8 +29,11 @@ "yesterday" : "ontem", "_%n day ago_::_%n days ago_" : ["%n dia atrás","%n dias atrás"], "last month" : "último mês", + "_%n month ago_::_%n months ago_" : ["há %n mês atrás","há %n meses atrás"], "last year" : "último ano", "_%n year ago_::_%n years ago_" : ["%n ano atrás","%n anos atrás"], + "_%n hour ago_::_%n hours ago_" : ["há %n hora atrás","há %n horas atrás"], + "_%n minute ago_::_%n minutes ago_" : ["há %n minuto atrás","há %n minutos atrás"], "seconds ago" : "segundos atrás", "web services under your control" : "serviços web sob seu controle", "Module with id: %s does not exist. Please enable it in your apps settings or contact your administrator." : "Módulo com id: %s não existe. Ative-o em suas configurações de aplicativos ou contate o administrador.", @@ -40,6 +43,7 @@ "File name is a reserved word" : "O nome do arquivo é uma palavra reservada", "File name contains at least one invalid character" : "O nome do arquivo contém pelo menos um caractere inválido", "File name is too long" : "O nome do arquivo é muito longo", + "File is currently busy, please try again later" : "O arquivo está ocupado, tente novamente mais tarde", "Can't read file" : "Não é possível ler arquivo", "App directory already exists" : "Diretório App já existe", "Can't create app folder. Please fix permissions. %s" : "Não é possível criar pasta app. Corrija as permissões. %s", @@ -80,6 +84,7 @@ "Set an admin username." : "Defina um nome do usuário administrador.", "Set an admin password." : "Defina uma senha de administrador.", "Can't create or write into the data directory %s" : "Não é possível criar ou gravar no diretório de dados %s", + "Invalid Federated Cloud ID" : "Associação Inválida de Nuvem ID", "%s shared »%s« with you" : "%s compartilhou »%s« com você", "%s via %s" : "%s via %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "O compartilhamento %s falhou, porque o processo interno não permite ações de tipo %i", diff --git a/lib/l10n/ru.js b/lib/l10n/ru.js index 1e072085c23..625d537add6 100644 --- a/lib/l10n/ru.js +++ b/lib/l10n/ru.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "Имя файла является зарезервированным словом", "File name contains at least one invalid character" : "Имя файла содержит по крайней мере один некорректный символ", "File name is too long" : "Имя файла слишком длинное.", + "File is currently busy, please try again later" : "Файл в данный момент используется, повторите попытку позже.", "Can't read file" : "Не удается прочитать файл", "App directory already exists" : "Каталог приложения уже существует", "Can't create app folder. Please fix permissions. %s" : "Не удалось создать каталог. Исправьте права доступа. %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "Задать имя пользователя для admin.", "Set an admin password." : "Задать пароль для admin.", "Can't create or write into the data directory %s" : "Невозможно создать или записать в каталог данных %s", + "Invalid Federated Cloud ID" : "Неверный ID в объединении облачных хранилищ.", "%s shared »%s« with you" : "%s поделился »%s« с вами", "%s via %s" : "%s через %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Не удалось поделиться %s, общий доступ не допускает публикации из элементов типа %i", diff --git a/lib/l10n/ru.json b/lib/l10n/ru.json index 9df90934ead..6d7497fafa8 100644 --- a/lib/l10n/ru.json +++ b/lib/l10n/ru.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "Имя файла является зарезервированным словом", "File name contains at least one invalid character" : "Имя файла содержит по крайней мере один некорректный символ", "File name is too long" : "Имя файла слишком длинное.", + "File is currently busy, please try again later" : "Файл в данный момент используется, повторите попытку позже.", "Can't read file" : "Не удается прочитать файл", "App directory already exists" : "Каталог приложения уже существует", "Can't create app folder. Please fix permissions. %s" : "Не удалось создать каталог. Исправьте права доступа. %s", @@ -83,6 +84,7 @@ "Set an admin username." : "Задать имя пользователя для admin.", "Set an admin password." : "Задать пароль для admin.", "Can't create or write into the data directory %s" : "Невозможно создать или записать в каталог данных %s", + "Invalid Federated Cloud ID" : "Неверный ID в объединении облачных хранилищ.", "%s shared »%s« with you" : "%s поделился »%s« с вами", "%s via %s" : "%s через %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "Не удалось поделиться %s, общий доступ не допускает публикации из элементов типа %i", diff --git a/lib/l10n/th_TH.js b/lib/l10n/th_TH.js index 4af45f2e7ea..70e700dc4d0 100644 --- a/lib/l10n/th_TH.js +++ b/lib/l10n/th_TH.js @@ -45,6 +45,7 @@ OC.L10N.register( "File name is a reserved word" : "ชื่อแฟ้มเป็นคำสงวน", "File name contains at least one invalid character" : "ชื่อแฟ้มมีหนึ่งตัวอักษรที่ไม่ถูกต้อง", "File name is too long" : "ชื่อแฟ้มยาวเกินไป", + "File is currently busy, please try again later" : "ขณะนี้ไฟล์กำลังใช้งานอยู่ โปรดลองอีกครั้งในภายหลัง", "Can't read file" : "ไม่สามารถอ่านไฟล์", "App directory already exists" : "มีไดเรกทอรีแอพฯอยู่แล้ว", "Can't create app folder. Please fix permissions. %s" : "ไม่สามารถสร้างโฟลเดอร์แอพพลิเคชัน โปรดแก้ไขการอนุญาต: %s", @@ -85,6 +86,7 @@ OC.L10N.register( "Set an admin username." : "ตั้งค่าชื่อผู้ดูแลระบบ", "Set an admin password." : "ตั้งค่ารหัสผ่านผู้ดูแลระบบ", "Can't create or write into the data directory %s" : "ไม่สามารถสร้างหรือเขียนลงในข้อมูลไดเรกทอรี %s", + "Invalid Federated Cloud ID" : "ไอดีคลาวด์ในเครือไม่ถูกต้อง", "%s shared »%s« with you" : "%s ถูกแชร์ »%s« กับคุณ", "%s via %s" : "%s ผ่านทาง %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "การแชร์ %s ล้มเหลวเพราะแบ็กเอนด์ไม่อนุญาตให้แชร์จากไฟล์ประเภท %i", diff --git a/lib/l10n/th_TH.json b/lib/l10n/th_TH.json index 6aca08fad88..32e5d276c32 100644 --- a/lib/l10n/th_TH.json +++ b/lib/l10n/th_TH.json @@ -43,6 +43,7 @@ "File name is a reserved word" : "ชื่อแฟ้มเป็นคำสงวน", "File name contains at least one invalid character" : "ชื่อแฟ้มมีหนึ่งตัวอักษรที่ไม่ถูกต้อง", "File name is too long" : "ชื่อแฟ้มยาวเกินไป", + "File is currently busy, please try again later" : "ขณะนี้ไฟล์กำลังใช้งานอยู่ โปรดลองอีกครั้งในภายหลัง", "Can't read file" : "ไม่สามารถอ่านไฟล์", "App directory already exists" : "มีไดเรกทอรีแอพฯอยู่แล้ว", "Can't create app folder. Please fix permissions. %s" : "ไม่สามารถสร้างโฟลเดอร์แอพพลิเคชัน โปรดแก้ไขการอนุญาต: %s", @@ -83,6 +84,7 @@ "Set an admin username." : "ตั้งค่าชื่อผู้ดูแลระบบ", "Set an admin password." : "ตั้งค่ารหัสผ่านผู้ดูแลระบบ", "Can't create or write into the data directory %s" : "ไม่สามารถสร้างหรือเขียนลงในข้อมูลไดเรกทอรี %s", + "Invalid Federated Cloud ID" : "ไอดีคลาวด์ในเครือไม่ถูกต้อง", "%s shared »%s« with you" : "%s ถูกแชร์ »%s« กับคุณ", "%s via %s" : "%s ผ่านทาง %s", "Sharing %s failed, because the backend does not allow shares from type %i" : "การแชร์ %s ล้มเหลวเพราะแบ็กเอนด์ไม่อนุญาตให้แชร์จากไฟล์ประเภท %i", diff --git a/lib/private/activitymanager.php b/lib/private/activitymanager.php index 26db0c78df2..7b1d5d29f2e 100644 --- a/lib/private/activitymanager.php +++ b/lib/private/activitymanager.php @@ -3,7 +3,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/api.php b/lib/private/api.php index dd50162f03e..8e483b7efe9 100644 --- a/lib/private/api.php +++ b/lib/private/api.php @@ -3,6 +3,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> diff --git a/lib/private/app.php b/lib/private/app.php index 4814561baec..e45d9ac07ba 100644 --- a/lib/private/app.php +++ b/lib/private/app.php @@ -312,8 +312,8 @@ class OC_App { \OC::$server->getConfig(), \OC::$server->getLogger() ); - $appData = $ocsClient->getApplication($app); - $download= $ocsClient->getApplicationDownload($app); + $appData = $ocsClient->getApplication($app, \OC_Util::getVersion()); + $download= $ocsClient->getApplicationDownload($app, \OC_Util::getVersion()); if(isset($download['downloadlink']) and $download['downloadlink']!='') { // Replace spaces in download link without encoding entire URL $download['downloadlink'] = str_replace(' ', '%20', $download['downloadlink']); @@ -918,7 +918,7 @@ class OC_App { if (is_null($category)) { - $categoryNames = $ocsClient->getCategories(); + $categoryNames = $ocsClient->getCategories(\OC_Util::getVersion()); if (is_array($categoryNames)) { // Check that categories of apps were retrieved correctly if (!$categories = array_keys($categoryNames)) { @@ -930,7 +930,7 @@ class OC_App { } $page = 0; - $remoteApps = $ocsClient->getApplications($categories, $page, $filter); + $remoteApps = $ocsClient->getApplications($categories, $page, $filter, \OC_Util::getVersion()); $apps = []; $i = 0; $l = \OC::$server->getL10N('core'); @@ -1088,7 +1088,7 @@ class OC_App { $config, \OC::$server->getLogger() ); - $appData = $ocsClient->getApplication($app); + $appData = $ocsClient->getApplication($app, \OC_Util::getVersion()); // check if app is a shipped app or not. OCS apps have an integer as id, shipped apps use a string if (!is_numeric($app)) { @@ -1174,6 +1174,8 @@ class OC_App { $appData = self::getAppInfo($appId); if (array_key_exists('ocsid', $appData)) { OC_Appconfig::setValue($appId, 'ocsid', $appData['ocsid']); + } elseif(OC_Appconfig::getValue($appId, 'ocsid', null) !== null) { + OC_Appconfig::deleteKey($appId, 'ocsid'); } foreach ($appData['remote'] as $name => $path) { OCP\CONFIG::setAppValue('core', 'remote_' . $name, $appId . '/' . $path); @@ -1223,22 +1225,27 @@ class OC_App { // just modify the description if it is available // otherwise this will create a $data element with an empty 'description' if (isset($data['description'])) { - // sometimes the description contains line breaks and they are then also - // shown in this way in the app management which isn't wanted as HTML - // manages line breaks itself - - // first of all we split on empty lines - $paragraphs = preg_split("!\n[[:space:]]*\n!m", $data['description']); - - $result = []; - foreach ($paragraphs as $value) { - // replace multiple whitespace (tabs, space, newlines) inside a paragraph - // with a single space - also trims whitespace - $result[] = trim(preg_replace('![[:space:]]+!m', ' ', $value)); - } + if (is_string($data['description'])) { + // sometimes the description contains line breaks and they are then also + // shown in this way in the app management which isn't wanted as HTML + // manages line breaks itself + + // first of all we split on empty lines + $paragraphs = preg_split("!\n[[:space:]]*\n!mu", $data['description']); + + $result = []; + foreach ($paragraphs as $value) { + // replace multiple whitespace (tabs, space, newlines) inside a paragraph + // with a single space - also trims whitespace + $result[] = trim(preg_replace('![[:space:]]+!mu', ' ', $value)); + } + + // join the single paragraphs with a empty line in between + $data['description'] = implode("\n\n", $result); - // join the single paragraphs with a empty line in between - $data['description'] = implode("\n\n", $result); + } else { + $data['description'] = ''; + } } return $data; diff --git a/lib/private/app/appmanager.php b/lib/private/app/appmanager.php index c9d4a777c4a..7a61cd53c59 100644 --- a/lib/private/app/appmanager.php +++ b/lib/private/app/appmanager.php @@ -1,5 +1,7 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * diff --git a/lib/private/app/codechecker.php b/lib/private/app/codechecker.php index 8c2f3405fb9..326bf8cd888 100644 --- a/lib/private/app/codechecker.php +++ b/lib/private/app/codechecker.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/lib/private/app/platformrepository.php b/lib/private/app/platformrepository.php index bebd93006c9..fa71bd7d91a 100644 --- a/lib/private/app/platformrepository.php +++ b/lib/private/app/platformrepository.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/appconfig.php b/lib/private/appconfig.php index 37532616e1e..b88df10dddd 100644 --- a/lib/private/appconfig.php +++ b/lib/private/appconfig.php @@ -3,6 +3,7 @@ * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Jakob Sack <mail@jakobsack.de> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/lib/private/appframework/app.php b/lib/private/appframework/app.php index f6c1e31cddd..0188d221be1 100644 --- a/lib/private/appframework/app.php +++ b/lib/private/appframework/app.php @@ -1,5 +1,6 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/lib/private/appframework/http/request.php b/lib/private/appframework/http/request.php index 2455209cdf3..f826ef45bb5 100644 --- a/lib/private/appframework/http/request.php +++ b/lib/private/appframework/http/request.php @@ -2,6 +2,7 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Bernhard Posselt <dev@bernhard-posselt.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> @@ -658,11 +659,6 @@ class Request implements \ArrayAccess, \Countable, IRequest { * @return string Server host */ public function getServerHost() { - // FIXME: Ugly workaround that we need to get rid of - if (\OC::$CLI && defined('PHPUNIT_RUN')) { - return 'localhost'; - } - // overwritehost is always trusted $host = $this->getOverwriteHost(); if ($host !== null) { @@ -680,7 +676,11 @@ class Request implements \ArrayAccess, \Countable, IRequest { return $host; } else { $trustedList = $this->config->getSystemValue('trusted_domains', []); - return $trustedList[0]; + if(!empty($trustedList)) { + return $trustedList[0]; + } else { + return ''; + } } } diff --git a/lib/private/appframework/utility/controllermethodreflector.php b/lib/private/appframework/utility/controllermethodreflector.php index e013a74253a..63cf5ac24f0 100644 --- a/lib/private/appframework/utility/controllermethodreflector.php +++ b/lib/private/appframework/utility/controllermethodreflector.php @@ -3,7 +3,7 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Olivier Paroz <github@oparoz.com> - * @author Philipp Knechtges <philipp-dev@knechtges.com> + * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/lib/private/appframework/utility/simplecontainer.php b/lib/private/appframework/utility/simplecontainer.php index c7dff6f4571..5a69d3dbbd2 100644 --- a/lib/private/appframework/utility/simplecontainer.php +++ b/lib/private/appframework/utility/simplecontainer.php @@ -1,6 +1,7 @@ <?php /** * @author Bernhard Posselt <dev@bernhard-posselt.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/lib/private/apphelper.php b/lib/private/apphelper.php index c4ddc1b077e..9084d2b8ab4 100644 --- a/lib/private/apphelper.php +++ b/lib/private/apphelper.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/avatar.php b/lib/private/avatar.php index 133ab4bcd61..55c328b6778 100644 --- a/lib/private/avatar.php +++ b/lib/private/avatar.php @@ -3,12 +3,12 @@ * @author Arthur Schiwon <blizzz@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Lukas Reschke <lukas@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/avatarmanager.php b/lib/private/avatarmanager.php index 42f711ee249..6b33e8d8e8b 100644 --- a/lib/private/avatarmanager.php +++ b/lib/private/avatarmanager.php @@ -1,6 +1,8 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Roeland Jago Douma <roeland@famdouma.nl> diff --git a/lib/private/cache/file.php b/lib/private/cache/file.php index 4742128ecbe..69008c7fab5 100644 --- a/lib/private/cache/file.php +++ b/lib/private/cache/file.php @@ -1,16 +1,8 @@ <?php /** - * @author Arthur Schiwon <blizzz@owncloud.com> - * @author Bart Visscher <bartv@thisnet.nl> - * @author Björn Schießle <schiessle@owncloud.com> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Michael Gapczynski <GapczynskiM@gmail.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Robin Appelman <icewind@owncloud.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Thomas Tanghus <thomas@tanghus.net> - * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -33,9 +25,12 @@ namespace OC\Cache; use OC\Files\Filesystem; use OC\Files\View; +use OCP\ICache; use OCP\Security\ISecureRandom; -class File { +class File implements ICache { + + /** @var View */ protected $storage; /** @@ -182,9 +177,16 @@ class File { } while (($file = readdir($dh)) !== false) { if ($file != '.' and $file != '..') { - $mtime = $storage->filemtime('/' . $file); - if ($mtime < $now) { - $storage->unlink('/' . $file); + try { + $mtime = $storage->filemtime('/' . $file); + if ($mtime < $now) { + $storage->unlink('/' . $file); + } + } catch (\OCP\Lock\LockedException $e) { + // ignore locked chunks + \OC::$server->getLogger()->debug('Could not cleanup locked chunk "' . $file . '"', array('app' => 'core')); + } catch (\OCP\Files\LockNotAcquiredException $e) { + \OC::$server->getLogger()->debug('Could not cleanup locked chunk "' . $file . '"', array('app' => 'core')); } } } diff --git a/lib/private/connector/sabre/auth.php b/lib/private/connector/sabre/auth.php index 5a32a9112ba..8a6eaab5bf8 100644 --- a/lib/private/connector/sabre/auth.php +++ b/lib/private/connector/sabre/auth.php @@ -30,7 +30,12 @@ */ namespace OC\Connector\Sabre; -class Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { +use Exception; +use Sabre\DAV\Auth\Backend\AbstractBasic; +use Sabre\DAV\Exception\NotAuthenticated; +use Sabre\DAV\Exception\ServiceUnavailable; + +class Auth extends AbstractBasic { const DAV_AUTHENTICATED = 'AUTHENTICATED_TO_DAV_BACKEND'; /** @@ -69,7 +74,7 @@ class Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { } else { \OC_Util::setUpFS(); //login hooks may need early access to the filesystem if(\OC_User::login($username, $password)) { - // make sure we use owncloud's internal username here + // make sure we use ownCloud's internal username here // and not the HTTP auth supplied one, see issue #14048 $ocUser = \OC_User::getUser(); \OC_Util::setUpFS($ocUser); @@ -99,21 +104,30 @@ class Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { } /** - * Override function here. We want to cache authentication cookies - * in the syncing client to avoid HTTP-401 roundtrips. - * If the sync client supplies the cookies, then OC_User::isLoggedIn() - * will return true and we can see this WebDAV request as already authenticated, - * even if there are no HTTP Basic Auth headers. - * In other case, just fallback to the parent implementation. - * - * @param \Sabre\DAV\Server $server - * @param $realm - * @return bool - */ + * Override function here. We want to cache authentication cookies + * in the syncing client to avoid HTTP-401 roundtrips. + * If the sync client supplies the cookies, then OC_User::isLoggedIn() + * will return true and we can see this WebDAV request as already authenticated, + * even if there are no HTTP Basic Auth headers. + * In other case, just fallback to the parent implementation. + * + * @param \Sabre\DAV\Server $server + * @param string $realm + * @return bool + * @throws ServiceUnavailable + */ public function authenticate(\Sabre\DAV\Server $server, $realm) { - $result = $this->auth($server, $realm); - return $result; + try { + $result = $this->auth($server, $realm); + return $result; + } catch (NotAuthenticated $e) { + throw $e; + } catch (Exception $e) { + $class = get_class($e); + $msg = $e->getMessage(); + throw new ServiceUnavailable("$class: $msg"); + } } /** diff --git a/lib/private/connector/sabre/copyetagheaderplugin.php b/lib/private/connector/sabre/copyetagheaderplugin.php index 9f5d74654cc..863d4cf3e10 100644 --- a/lib/private/connector/sabre/copyetagheaderplugin.php +++ b/lib/private/connector/sabre/copyetagheaderplugin.php @@ -1,12 +1,23 @@ <?php - /** - * ownCloud + * @author Morris Jobke <hey@morrisjobke.de> + * @author Vincent Petry <pvince81@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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. * - * @author Vincent Petry - * @copyright 2015 Vincent Petry <pvince81@owncloud.com> + * You should have received a copy of the GNU Affero General Public License, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> * - * @license AGPL3 */ namespace OC\Connector\Sabre; diff --git a/lib/private/connector/sabre/custompropertiesbackend.php b/lib/private/connector/sabre/custompropertiesbackend.php index 14989a5bac3..47f34909a08 100644 --- a/lib/private/connector/sabre/custompropertiesbackend.php +++ b/lib/private/connector/sabre/custompropertiesbackend.php @@ -1,5 +1,7 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/lib/private/connector/sabre/directory.php b/lib/private/connector/sabre/directory.php index e99411068f1..551176e4bd2 100644 --- a/lib/private/connector/sabre/directory.php +++ b/lib/private/connector/sabre/directory.php @@ -4,6 +4,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/private/connector/sabre/file.php b/lib/private/connector/sabre/file.php index 740660f466b..e4f53a219d2 100644 --- a/lib/private/connector/sabre/file.php +++ b/lib/private/connector/sabre/file.php @@ -2,10 +2,7 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> - * @author chli1 <chli1@users.noreply.github.com> - * @author Chris Wilson <chris+github@qwirx.com> * @author Jakob Sack <mail@jakobsack.de> - * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> @@ -99,7 +96,11 @@ class File extends Node implements IFile { // chunked handling if (isset($_SERVER['HTTP_OC_CHUNKED'])) { - return $this->createFileChunked($data); + try { + return $this->createFileChunked($data); + } catch (\Exception $e) { + $this->convertToSabreException($e); + } } list($partStorage) = $this->fileView->resolvePath($this->path); @@ -128,7 +129,6 @@ class File extends Node implements IFile { $target = $partStorage->fopen($internalPartPath, 'wb'); if ($target === false) { \OC_Log::write('webdav', '\OC\Files\Filesystem::fopen() failed', \OC_Log::ERROR); - $partStorage->unlink($internalPartPath); // because we have no clue about the cause we can only throw back a 500/Internal Server Error throw new Exception('Could not write file contents'); } @@ -141,32 +141,15 @@ class File extends Node implements IFile { if (isset($_SERVER['CONTENT_LENGTH']) && $_SERVER['REQUEST_METHOD'] !== 'LOCK') { $expected = $_SERVER['CONTENT_LENGTH']; if ($count != $expected) { - $partStorage->unlink($internalPartPath); throw new BadRequest('expected filesize ' . $expected . ' got ' . $count); } } - } catch (NotPermittedException $e) { - // a more general case - due to whatever reason the content could not be written - throw new Forbidden($e->getMessage()); - } catch (EntityTooLargeException $e) { - // the file is too big to be stored - throw new EntityTooLarge($e->getMessage()); - } catch (InvalidContentException $e) { - // the file content is not permitted - throw new UnsupportedMediaType($e->getMessage()); - } catch (InvalidPathException $e) { - // the path for the file was not valid - // TODO: find proper http status code for this case - throw new Forbidden($e->getMessage()); - } catch (LockNotAcquiredException $e) { - // the file is currently being written to by another process - throw new FileLocked($e->getMessage(), $e->getCode(), $e); - } catch (GenericEncryptionException $e) { - // returning 503 will allow retry of the operation at a later point in time - throw new ServiceUnavailable("Encryption not ready: " . $e->getMessage()); - } catch (StorageNotAvailableException $e) { - throw new ServiceUnavailable("Failed to write file contents: " . $e->getMessage()); + } catch (\Exception $e) { + if ($needsPartFile) { + $partStorage->unlink($internalPartPath); + } + $this->convertToSabreException($e); } try { @@ -195,6 +178,9 @@ class File extends Node implements IFile { try { $this->fileView->changeLock($this->path, ILockingProvider::LOCK_EXCLUSIVE); } catch (LockedException $e) { + if ($needsPartFile) { + $partStorage->unlink($internalPartPath); + } throw new FileLocked($e->getMessage(), $e->getCode(), $e); } @@ -207,12 +193,11 @@ class File extends Node implements IFile { } if (!$run || $renameOkay === false || $fileExists === false) { \OC_Log::write('webdav', 'renaming part file to final file failed', \OC_Log::ERROR); - $partStorage->unlink($internalPartPath); throw new Exception('Could not rename part file to final file'); } - } catch (\OCP\Files\LockNotAcquiredException $e) { - // the file is currently being written to by another process - throw new FileLocked($e->getMessage(), $e->getCode(), $e); + } catch (\Exception $e) { + $partStorage->unlink($internalPartPath); + $this->convertToSabreException($e); } } @@ -368,6 +353,7 @@ class File extends Node implements IFile { if ($chunk_handler->isComplete()) { list($storage,) = $this->fileView->resolvePath($path); $needsPartFile = $this->needsPartFile($storage); + $partFile = null; try { $targetPath = $path . '/' . $info['name']; @@ -383,6 +369,9 @@ class File extends Node implements IFile { \OC_Log::write('webdav', '\OC\Files\Filesystem::rename() failed', \OC_Log::ERROR); // only delete if an error occurred and the target file was already created if ($fileExists) { + // set to null to avoid double-deletion when handling exception + // stray part file + $partFile = null; $this->fileView->unlink($targetPath); } throw new Exception('Could not rename part file assembled from chunks'); @@ -402,10 +391,11 @@ class File extends Node implements IFile { $info = $this->fileView->getFileInfo($targetPath); return $info->getEtag(); - } catch (StorageNotAvailableException $e) { - throw new ServiceUnavailable("Failed to put file: " . $e->getMessage()); - } catch (LockedException $e) { - throw new FileLocked($e->getMessage(), $e->getCode(), $e); + } catch (\Exception $e) { + if ($partFile !== null) { + $this->fileView->unlink($partFile); + } + $this->convertToSabreException($e); } } @@ -426,4 +416,47 @@ class File extends Node implements IFile { return !$storage->instanceOfStorage('OCA\Files_Sharing\External\Storage') && !$storage->instanceOfStorage('OC\Files\Storage\OwnCloud'); } + + /** + * Convert the given exception to a SabreException instance + * + * @param \Exception $e + * + * @throws \Sabre\DAV\Exception + */ + private function convertToSabreException(\Exception $e) { + if ($e instanceof \Sabre\DAV\Exception) { + throw $e; + } + if ($e instanceof NotPermittedException) { + // a more general case - due to whatever reason the content could not be written + throw new Forbidden($e->getMessage(), 0, $e); + } + if ($e instanceof EntityTooLargeException) { + // the file is too big to be stored + throw new EntityTooLarge($e->getMessage(), 0, $e); + } + if ($e instanceof InvalidContentException) { + // the file content is not permitted + throw new UnsupportedMediaType($e->getMessage(), 0, $e); + } + if ($e instanceof InvalidPathException) { + // the path for the file was not valid + // TODO: find proper http status code for this case + throw new Forbidden($e->getMessage(), 0, $e); + } + if ($e instanceof LockedException || $e instanceof LockNotAcquiredException) { + // the file is currently being written to by another process + throw new FileLocked($e->getMessage(), $e->getCode(), $e); + } + if ($e instanceof GenericEncryptionException) { + // returning 503 will allow retry of the operation at a later point in time + throw new ServiceUnavailable('Encryption not ready: ' . $e->getMessage(), 0, $e); + } + if ($e instanceof StorageNotAvailableException) { + throw new ServiceUnavailable('Failed to write file contents: ' . $e->getMessage(), 0, $e); + } + + throw new \Sabre\DAV\Exception($e->getMessage(), 0, $e); + } } diff --git a/lib/private/connector/sabre/filesplugin.php b/lib/private/connector/sabre/filesplugin.php index 09d931be606..608e8cd9017 100644 --- a/lib/private/connector/sabre/filesplugin.php +++ b/lib/private/connector/sabre/filesplugin.php @@ -1,6 +1,8 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/lib/private/connector/sabre/maintenanceplugin.php b/lib/private/connector/sabre/maintenanceplugin.php index c4c9a5340bc..5b48abbc517 100644 --- a/lib/private/connector/sabre/maintenanceplugin.php +++ b/lib/private/connector/sabre/maintenanceplugin.php @@ -2,6 +2,7 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * @@ -24,17 +25,34 @@ namespace OC\Connector\Sabre; -class MaintenancePlugin extends \Sabre\DAV\ServerPlugin -{ +use OCP\IConfig; +use Sabre\DAV\Exception\ServiceUnavailable; +use Sabre\DAV\ServerPlugin; + +class MaintenancePlugin extends ServerPlugin { + + /** @var IConfig */ + private $config; /** * Reference to main server object * - * @var \Sabre\DAV\Server + * @var Server */ private $server; /** + * @param IConfig $config + */ + public function __construct(IConfig $config = null) { + $this->config = $config; + if (is_null($config)) { + $this->config = \OC::$server->getConfig(); + } + } + + + /** * This initializes the plugin. * * This function is called by \Sabre\DAV\Server, after @@ -46,7 +64,6 @@ class MaintenancePlugin extends \Sabre\DAV\ServerPlugin * @return void */ public function initialize(\Sabre\DAV\Server $server) { - $this->server = $server; $this->server->on('beforeMethod', array($this, 'checkMaintenanceMode'), 10); } @@ -55,19 +72,18 @@ class MaintenancePlugin extends \Sabre\DAV\ServerPlugin * This method is called before any HTTP method and returns http status code 503 * in case the system is in maintenance mode. * - * @throws \Sabre\DAV\Exception\ServiceUnavailable - * @internal param string $method + * @throws ServiceUnavailable * @return bool */ public function checkMaintenanceMode() { - if (\OC::$server->getSystemConfig()->getValue('singleuser', false)) { - throw new \Sabre\DAV\Exception\ServiceUnavailable(); + if ($this->config->getSystemValue('singleuser', false)) { + throw new ServiceUnavailable('System in single user mode.'); } - if (\OC_Config::getValue('maintenance', false)) { - throw new \Sabre\DAV\Exception\ServiceUnavailable(); + if ($this->config->getSystemValue('maintenance', false)) { + throw new ServiceUnavailable('System in maintenance mode.'); } if (\OC::checkUpgrade(false)) { - throw new \Sabre\DAV\Exception\ServiceUnavailable('Upgrade needed'); + throw new ServiceUnavailable('Upgrade needed'); } return true; diff --git a/lib/private/connector/sabre/tagsplugin.php b/lib/private/connector/sabre/tagsplugin.php index 6a788b9f3aa..7756eb45bda 100644 --- a/lib/private/connector/sabre/tagsplugin.php +++ b/lib/private/connector/sabre/tagsplugin.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/console/application.php b/lib/private/console/application.php index f2aacbfc0e6..7c709927219 100644 --- a/lib/private/console/application.php +++ b/lib/private/console/application.php @@ -1,5 +1,24 @@ <?php - +/** + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ namespace OC\Console; use OC_App; diff --git a/lib/private/console/timestampformatter.php b/lib/private/console/timestampformatter.php new file mode 100644 index 00000000000..f0c0f4c4520 --- /dev/null +++ b/lib/private/console/timestampformatter.php @@ -0,0 +1,107 @@ +<?php +/** + * @author Joas Schilling <nickvergessen@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace OC\Console; + + +use OCP\IConfig; +use Symfony\Component\Console\Formatter\OutputFormatterInterface; +use Symfony\Component\Console\Formatter\OutputFormatterStyleInterface; + +class TimestampFormatter implements OutputFormatterInterface { + /** @var IConfig */ + protected $config; + + /** + * @param IConfig $config + * @param OutputFormatterInterface $formatter + */ + public function __construct(IConfig $config, OutputFormatterInterface $formatter) { + $this->config = $config; + $this->formatter = $formatter; + } + + /** + * Sets the decorated flag. + * + * @param bool $decorated Whether to decorate the messages or not + */ + public function setDecorated($decorated) { + $this->formatter->setDecorated($decorated); + } + + /** + * Gets the decorated flag. + * + * @return bool true if the output will decorate messages, false otherwise + */ + public function isDecorated() { + return $this->formatter->isDecorated(); + } + + /** + * Sets a new style. + * + * @param string $name The style name + * @param OutputFormatterStyleInterface $style The style instance + */ + public function setStyle($name, OutputFormatterStyleInterface $style) { + $this->formatter->setStyle($name, $style); + } + + /** + * Checks if output formatter has style with specified name. + * + * @param string $name + * @return bool + */ + public function hasStyle($name) { + $this->formatter->hasStyle($name); + } + + /** + * Gets style options from style with specified name. + * + * @param string $name + * @return OutputFormatterStyleInterface + */ + public function getStyle($name) { + return $this->formatter->getStyle($name); + } + + /** + * Formats a message according to the given styles. + * + * @param string $message The message to style + * @return string The styled message, prepended with a timestamp using the + * log timezone and dateformat, e.g. "2015-06-23T17:24:37+02:00" + */ + public function format($message) { + + $timeZone = $this->config->getSystemValue('logtimezone', null); + $timeZone = $timeZone !== null ? new \DateTimeZone($timeZone) : null; + + $time = new \DateTime('now', $timeZone); + $timestampInfo = $time->format($this->config->getSystemValue('logdateformat', 'c')); + + return $timestampInfo . ' ' . $this->formatter->format($message); + } +} diff --git a/lib/private/db/migrator.php b/lib/private/db/migrator.php index fcfe5d96279..6a587ede631 100644 --- a/lib/private/db/migrator.php +++ b/lib/private/db/migrator.php @@ -5,6 +5,7 @@ * @author Robin Appelman <icewind@owncloud.com> * @author tbelau666 <thomas.belau@gmx.de> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Victor Dubiniuk <dubiniuk@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/db/ocsqliteplatform.php b/lib/private/db/ocsqliteplatform.php index fe39e20c864..543f58b90ec 100644 --- a/lib/private/db/ocsqliteplatform.php +++ b/lib/private/db/ocsqliteplatform.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Robin Appelman <icewind@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OC\DB; diff --git a/lib/private/encryption/hookmanager.php b/lib/private/encryption/hookmanager.php index 31ecb2fbcf6..d096b7ff3ad 100644 --- a/lib/private/encryption/hookmanager.php +++ b/lib/private/encryption/hookmanager.php @@ -1,5 +1,7 @@ <?php /** + * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/encryption/keys/storage.php b/lib/private/encryption/keys/storage.php index 848d5c0134a..b754462d9b0 100644 --- a/lib/private/encryption/keys/storage.php +++ b/lib/private/encryption/keys/storage.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/encryption/manager.php b/lib/private/encryption/manager.php index 4841533cac1..1e0a065e25a 100644 --- a/lib/private/encryption/manager.php +++ b/lib/private/encryption/manager.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Jan-Christoph Borchardt <hey@jancborchardt.net> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/encryption/update.php b/lib/private/encryption/update.php index 02579fd9136..125946ab266 100644 --- a/lib/private/encryption/update.php +++ b/lib/private/encryption/update.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/encryption/util.php b/lib/private/encryption/util.php index 80499249561..8bff65428d3 100644 --- a/lib/private/encryption/util.php +++ b/lib/private/encryption/util.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Jan-Christoph Borchardt <hey@jancborchardt.net> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/files.php b/lib/private/files.php index 5a3e1029199..17e2e5a398f 100644 --- a/lib/private/files.php +++ b/lib/private/files.php @@ -1,22 +1,21 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> - * @author Brice Maron <brice@bmaron.net> * @author dratini0 <dratini0@gmail.com> - * @author Fabian Henze <flyser42@gmx.de> * @author Frank Karlitschek <frank@owncloud.org> * @author Jakob Sack <mail@jakobsack.de> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author josh4trunks <joshruehlig@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> * @author mvn23 <schopdiedwaas@gmail.com> * @author Nicolai Ehemann <en@enlightened.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> * @author Thibaut GRIDEL <tgridel@free.fr> * @author Thomas Müller <thomas.mueller@tmit.eu> @@ -43,6 +42,9 @@ // TODO: get rid of this using proper composer packages require_once 'mcnetic/phpzipstreamer/ZipStreamer.php'; +use OC\Lock\NoopLockingProvider; +use OCP\Lock\ILockingProvider; + /** * Class for file server access * @@ -82,11 +84,15 @@ class OC_Files { * @param boolean $only_header ; boolean to only send header of the request */ public static function get($dir, $files, $only_header = false) { + $view = \OC\Files\Filesystem::getView(); $xsendfile = false; - if (isset($_SERVER['MOD_X_SENDFILE_ENABLED']) || - isset($_SERVER['MOD_X_SENDFILE2_ENABLED']) || - isset($_SERVER['MOD_X_ACCEL_REDIRECT_ENABLED'])) { - $xsendfile = true; + if (\OC::$server->getLockingProvider() instanceof NoopLockingProvider) { + if (isset($_SERVER['MOD_X_SENDFILE_ENABLED']) || + isset($_SERVER['MOD_X_SENDFILE2_ENABLED']) || + isset($_SERVER['MOD_X_ACCEL_REDIRECT_ENABLED']) + ) { + $xsendfile = true; + } } if (is_array($files) && count($files) === 1) { @@ -131,7 +137,9 @@ class OC_Files { OC_Util::obEnd(); try { - + if ($get_type === self::FILE) { + $view->lockFile($filename, ILockingProvider::LOCK_SHARED); + } if ($zip or \OC\Files\Filesystem::isReadable($filename)) { self::sendHeaders($filename, $name, $zip); } elseif (!\OC\Files\Filesystem::file_exists($filename)) { @@ -168,7 +176,6 @@ class OC_Files { set_time_limit($executionTime); } else { if ($xsendfile) { - $view = \OC\Files\Filesystem::getView(); /** @var $storage \OC\Files\Storage\Storage */ list($storage) = $view->resolvePath($filename); if ($storage->isLocal()) { @@ -180,6 +187,13 @@ class OC_Files { \OC\Files\Filesystem::readfile($filename); } } + if ($get_type === self::FILE) { + $view->unlockFile($filename, ILockingProvider::LOCK_SHARED); + } + } catch (\OCP\Lock\LockedException $ex) { + $l = \OC::$server->getL10N('core'); + $hint = method_exists($ex, 'getHint') ? $ex->getHint() : ''; + \OC_Template::printErrorPage($l->t('File is currently busy, please try again later'), $hint); } catch (\Exception $ex) { $l = \OC::$server->getL10N('core'); $hint = method_exists($ex, 'getHint') ? $ex->getHint() : ''; diff --git a/lib/private/files/cache/cache.php b/lib/private/files/cache/cache.php index a82ccec2813..680398e383f 100644 --- a/lib/private/files/cache/cache.php +++ b/lib/private/files/cache/cache.php @@ -4,6 +4,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Florin Peter <github@florin-peter.de> + * @author Jens-Christian Fischer <jens-christian.fischer@switch.ch> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Michael Gapczynski <GapczynskiM@gmail.com> diff --git a/lib/private/files/config/mountprovidercollection.php b/lib/private/files/config/mountprovidercollection.php index a14a6ef796f..c75c64ae445 100644 --- a/lib/private/files/config/mountprovidercollection.php +++ b/lib/private/files/config/mountprovidercollection.php @@ -57,8 +57,14 @@ class MountProviderCollection implements IMountProviderCollection, Emitter { */ public function getMountsForUser(IUser $user) { $loader = $this->loader; - return array_reduce($this->providers, function ($mounts, IMountProvider $provider) use ($user, $loader) { - return array_merge($mounts, $provider->getMountsForUser($user, $loader)); + $mounts = array_map(function (IMountProvider $provider) use ($user, $loader) { + return $provider->getMountsForUser($user, $loader); + }, $this->providers); + $mounts = array_filter($mounts, function ($result) { + return is_array($result); + }); + return array_reduce($mounts, function (array $mounts, array $providerMounts) { + return array_merge($mounts, $providerMounts); }, array()); } diff --git a/lib/private/files/filesystem.php b/lib/private/files/filesystem.php index 4d991e5d11d..90019b649c4 100644 --- a/lib/private/files/filesystem.php +++ b/lib/private/files/filesystem.php @@ -2,10 +2,9 @@ /** * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> - * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> * @author Florin Peter <github@florin-peter.de> - * @author Georg Ehrke <georg@ownCloud.com> + * @author Georg Ehrke <georg@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> diff --git a/lib/private/files/mapper.php b/lib/private/files/mapper.php index 17831d69abb..2c8760ba40e 100644 --- a/lib/private/files/mapper.php +++ b/lib/private/files/mapper.php @@ -4,7 +4,6 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/lib/private/files/objectstore/noopscanner.php b/lib/private/files/objectstore/noopscanner.php index 3a0df13a290..cdcc0149ab3 100644 --- a/lib/private/files/objectstore/noopscanner.php +++ b/lib/private/files/objectstore/noopscanner.php @@ -3,6 +3,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/files/storage/dav.php b/lib/private/files/storage/dav.php index 15f513585fe..d67e6b9f97e 100644 --- a/lib/private/files/storage/dav.php +++ b/lib/private/files/storage/dav.php @@ -5,7 +5,6 @@ * @author Björn Schießle <schiessle@owncloud.com> * @author Carlos Cerrillo <ccerrillo@gmail.com> * @author Felix Moeller <mail@felixmoeller.de> - * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> diff --git a/lib/private/files/storage/local.php b/lib/private/files/storage/local.php index 315a8e7e25d..53465f8585e 100644 --- a/lib/private/files/storage/local.php +++ b/lib/private/files/storage/local.php @@ -7,6 +7,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Klaas Freitag <freitag@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/lib/private/files/storage/localtempfiletrait.php b/lib/private/files/storage/localtempfiletrait.php index e7f51a1807f..86c8b5c8377 100644 --- a/lib/private/files/storage/localtempfiletrait.php +++ b/lib/private/files/storage/localtempfiletrait.php @@ -1,5 +1,7 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/files/storage/mappedlocal.php b/lib/private/files/storage/mappedlocal.php index 4b527357254..932320267e4 100644 --- a/lib/private/files/storage/mappedlocal.php +++ b/lib/private/files/storage/mappedlocal.php @@ -6,6 +6,7 @@ * @author Clark Tomlinson <fallen013@gmail.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> diff --git a/lib/private/files/storage/storage.php b/lib/private/files/storage/storage.php index bd809099e1f..f46ac544b56 100644 --- a/lib/private/files/storage/storage.php +++ b/lib/private/files/storage/storage.php @@ -2,6 +2,7 @@ /** * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/files/storage/storagefactory.php b/lib/private/files/storage/storagefactory.php index 31b4090eda2..62b393c845c 100644 --- a/lib/private/files/storage/storagefactory.php +++ b/lib/private/files/storage/storagefactory.php @@ -1,6 +1,5 @@ <?php /** - * @author Björn Schießle <schiessle@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/lib/private/files/storage/temporary.php b/lib/private/files/storage/temporary.php index 0f259905c80..ca348313e45 100644 --- a/lib/private/files/storage/temporary.php +++ b/lib/private/files/storage/temporary.php @@ -27,7 +27,7 @@ namespace OC\Files\Storage; * local storage backend in temporary folder for testing purpose */ class Temporary extends Local{ - public function __construct($arguments) { + public function __construct($arguments = null) { parent::__construct(array('datadir' => \OC_Helper::tmpFolder())); } diff --git a/lib/private/files/storage/wrapper/encryption.php b/lib/private/files/storage/wrapper/encryption.php index 8d1f80c53c0..8818b822fa7 100644 --- a/lib/private/files/storage/wrapper/encryption.php +++ b/lib/private/files/storage/wrapper/encryption.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. @@ -350,7 +353,7 @@ class Encryption extends Wrapper { $size = $unencryptedSize = 0; $realFile = $this->util->stripPartialFileExtension($path); - $targetExists = $this->file_exists($realFile); + $targetExists = $this->file_exists($realFile) || $this->file_exists($path); $targetIsEncrypted = false; if ($targetExists) { // in case the file exists we require the explicit module as @@ -361,8 +364,12 @@ class Encryption extends Wrapper { $encryptionModule = $this->encryptionManager->getEncryptionModule($encryptionModuleId); } - $size = $this->storage->filesize($path); - $unencryptedSize = $this->filesize($path); + if ($this->file_exists($path)) { + $size = $this->storage->filesize($path); + $unencryptedSize = $this->filesize($path); + } else { + $size = $unencryptedSize = 0; + } } try { @@ -608,7 +615,11 @@ class Encryption extends Wrapper { $header = ''; $realFile = $this->util->stripPartialFileExtension($path); if ($this->storage->file_exists($realFile)) { - $handle = $this->storage->fopen($realFile, 'r'); + $path = $realFile; + } + + if ($this->storage->file_exists($path)) { + $handle = $this->storage->fopen($path, 'r'); $firstBlock = fread($handle, $this->util->getHeaderSize()); fclose($handle); if (substr($firstBlock, 0, strlen(Util::HEADER_START)) === Util::HEADER_START) { diff --git a/lib/private/files/stream/encryption.php b/lib/private/files/stream/encryption.php index 22d230e7c86..1cef37baf9f 100644 --- a/lib/private/files/stream/encryption.php +++ b/lib/private/files/stream/encryption.php @@ -1,8 +1,10 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> - * @author Jasper Knockaert <jasper@knockaert.nl> + * @author jknockaert <jasper@knockaert.nl> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -301,7 +303,7 @@ class Encryption extends Wrapper { $length = 0; // loop over $data to fit it in 6126 sized unencrypted blocks - while (strlen($data) > 0) { + while (isset($data[0])) { $remainingLength = strlen($data); // set the cache to the current 6126 block diff --git a/lib/private/files/utils/scanner.php b/lib/private/files/utils/scanner.php index 23a9e26b3bc..3d68eb530a2 100644 --- a/lib/private/files/utils/scanner.php +++ b/lib/private/files/utils/scanner.php @@ -76,11 +76,10 @@ class Scanner extends PublicEmitter { //TODO: move to the node based fileapi once that's done \OC_Util::tearDownFS(); \OC_Util::setupFS($this->user); - $absolutePath = Filesystem::getView()->getAbsolutePath($dir); $mountManager = Filesystem::getMountManager(); - $mounts = $mountManager->findIn($absolutePath); - $mounts[] = $mountManager->find($absolutePath); + $mounts = $mountManager->findIn($dir); + $mounts[] = $mountManager->find($dir); $mounts = array_reverse($mounts); //start with the mount of $dir return $mounts; diff --git a/lib/private/files/view.php b/lib/private/files/view.php index 61adc6246fb..1706818f03e 100644 --- a/lib/private/files/view.php +++ b/lib/private/files/view.php @@ -79,6 +79,8 @@ class View { */ private $lockingProvider; + private $lockingEnabled; + /** * @param string $root * @throws \Exception If $root contains an invalid path @@ -94,6 +96,7 @@ class View { $this->fakeRoot = $root; $this->updater = new Updater($this); $this->lockingProvider = \OC::$server->getLockingProvider(); + $this->lockingEnabled = !($this->lockingProvider instanceof \OC\Lock\NoopLockingProvider); } public function getAbsolutePath($path = '/') { @@ -559,11 +562,12 @@ class View { $this->updater->update($path); - $this->unlockFile($path, ILockingProvider::LOCK_EXCLUSIVE); + $this->changeLock($path, ILockingProvider::LOCK_SHARED); if ($this->shouldEmitHooks($path) && $result !== false) { $this->emit_file_hooks_post($exists, $path); } + $this->unlockFile($path, ILockingProvider::LOCK_SHARED); return $result; } else { $this->unlockFile($path, ILockingProvider::LOCK_EXCLUSIVE); @@ -615,6 +619,7 @@ class View { public function rename($path1, $path2) { $absolutePath1 = Filesystem::normalizePath($this->getAbsolutePath($path1)); $absolutePath2 = Filesystem::normalizePath($this->getAbsolutePath($path2)); + $result = false; if ( Filesystem::isValidPath($path2) and Filesystem::isValidPath($path1) @@ -629,7 +634,12 @@ class View { } $this->lockFile($path1, ILockingProvider::LOCK_SHARED, true); - $this->lockFile($path2, ILockingProvider::LOCK_SHARED, true); + try { + $this->lockFile($path2, ILockingProvider::LOCK_SHARED, true); + } catch (LockedException $e) { + $this->unlockFile($path1, ILockingProvider::LOCK_SHARED); + throw $e; + } $run = true; if ($this->shouldEmitHooks() && (Cache\Scanner::isPartialFile($path1) && !Cache\Scanner::isPartialFile($path2))) { @@ -695,8 +705,8 @@ class View { } } - $this->unlockFile($path1, ILockingProvider::LOCK_EXCLUSIVE, true); - $this->unlockFile($path2, ILockingProvider::LOCK_EXCLUSIVE, true); + $this->changeLock($path1, ILockingProvider::LOCK_SHARED, true); + $this->changeLock($path2, ILockingProvider::LOCK_SHARED, true); if ((Cache\Scanner::isPartialFile($path1) && !Cache\Scanner::isPartialFile($path2)) && $result !== false) { if ($this->shouldEmitHooks()) { @@ -714,15 +724,11 @@ class View { ); } } - return $result; - } else { - $this->unlockFile($path1, ILockingProvider::LOCK_SHARED, true); - $this->unlockFile($path2, ILockingProvider::LOCK_SHARED, true); - return false; } - } else { - return false; + $this->unlockFile($path1, ILockingProvider::LOCK_SHARED, true); + $this->unlockFile($path2, ILockingProvider::LOCK_SHARED, true); } + return $result; } /** @@ -737,6 +743,7 @@ class View { public function copy($path1, $path2, $preserveMtime = false) { $absolutePath1 = Filesystem::normalizePath($this->getAbsolutePath($path1)); $absolutePath2 = Filesystem::normalizePath($this->getAbsolutePath($path2)); + $result = false; if ( Filesystem::isValidPath($path2) and Filesystem::isValidPath($path1) @@ -788,8 +795,7 @@ class View { $this->updater->update($path2); - $this->unlockFile($path2, ILockingProvider::LOCK_EXCLUSIVE); - $this->unlockFile($path1, ILockingProvider::LOCK_SHARED); + $this->changeLock($path2, ILockingProvider::LOCK_SHARED); if ($this->shouldEmitHooks() && $result !== false) { \OC_Hook::emit( @@ -802,15 +808,12 @@ class View { ); $this->emit_file_hooks_post($exists, $path2); } - return $result; - } else { + $this->unlockFile($path2, ILockingProvider::LOCK_SHARED); $this->unlockFile($path1, ILockingProvider::LOCK_SHARED); - return false; } - } else { - return false; } + return $result; } /** @@ -1025,7 +1028,9 @@ class View { $this->changeLock($path, ILockingProvider::LOCK_SHARED); } - if ($operation === 'fopen' and is_resource($result)) { + $unlockLater = false; + if ($this->lockingEnabled && $operation === 'fopen' && is_resource($result)) { + $unlockLater = true; $result = CallbackWrapper::wrap($result, null, null, function () use ($hooks, $path) { if (in_array('write', $hooks)) { $this->unlockFile($path, ILockingProvider::LOCK_EXCLUSIVE); @@ -1033,16 +1038,19 @@ class View { $this->unlockFile($path, ILockingProvider::LOCK_SHARED); } }); - } else if (in_array('write', $hooks) || in_array('delete', $hooks) || in_array('read', $hooks)) { - $this->unlockFile($path, ILockingProvider::LOCK_SHARED); } - if ($this->shouldEmitHooks($path) && $result !== false) { if ($operation != 'fopen') { //no post hooks for fopen, the file stream is still open $this->runHooks($hooks, $path, true); } } + + if (!$unlockLater + && (in_array('write', $hooks) || in_array('delete', $hooks) || in_array('read', $hooks)) + ) { + $this->unlockFile($path, ILockingProvider::LOCK_SHARED); + } return $result; } else { $this->unlockFile($path, ILockingProvider::LOCK_SHARED); diff --git a/lib/private/group/manager.php b/lib/private/group/manager.php index f8defe476c4..65ae49dfcd2 100644 --- a/lib/private/group/manager.php +++ b/lib/private/group/manager.php @@ -4,10 +4,13 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author macjohnny <estebanmarin@gmx.ch> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Roeland Jago Douma <roeland@famdouma.nl> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author voxsim <Simon Vocella> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/group/metadata.php b/lib/private/group/metadata.php index 66eb032d4bf..63447012b0c 100644 --- a/lib/private/group/metadata.php +++ b/lib/private/group/metadata.php @@ -1,6 +1,7 @@ <?php /** * @author Arthur Schiwon <blizzz@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Stephan Peijnik <speijnik@anexia-it.com> diff --git a/lib/private/helper.php b/lib/private/helper.php index f4de5b0d9f8..4c2f1f509c8 100644 --- a/lib/private/helper.php +++ b/lib/private/helper.php @@ -16,7 +16,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Olivier Paroz <github@oparoz.com> * @author Owen Winkler <a_github@midnightcircus.com> * @author Pellaeon Lin <nfsmwlin@gmail.com> * @author Robin Appelman <icewind@owncloud.com> diff --git a/lib/private/hooks/emittertrait.php b/lib/private/hooks/emittertrait.php index 5d471a3f553..256bf468c4f 100644 --- a/lib/private/hooks/emittertrait.php +++ b/lib/private/hooks/emittertrait.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/installer.php b/lib/private/installer.php index 41f13f0f5f9..bd214be5667 100644 --- a/lib/private/installer.php +++ b/lib/private/installer.php @@ -227,8 +227,8 @@ class OC_Installer{ \OC::$server->getConfig(), \OC::$server->getLogger() ); - $appData = $ocsClient->getApplication($ocsId); - $download = $ocsClient->getApplicationDownload($ocsId); + $appData = $ocsClient->getApplication($ocsId, \OC_Util::getVersion()); + $download = $ocsClient->getApplicationDownload($ocsId, \OC_Util::getVersion()); if (isset($download['downloadlink']) && trim($download['downloadlink']) !== '') { $download['downloadlink'] = str_replace(' ', '%20', $download['downloadlink']); @@ -395,7 +395,7 @@ class OC_Installer{ \OC::$server->getConfig(), \OC::$server->getLogger() ); - $ocsdata = $ocsClient->getApplication($ocsid); + $ocsdata = $ocsClient->getApplication($ocsid, \OC_Util::getVersion()); $ocsversion= (string) $ocsdata['version']; $currentversion=OC_App::getAppVersion($app); if (version_compare($ocsversion, $currentversion, '>')) { diff --git a/lib/private/l10n/string.php b/lib/private/l10n/string.php index f5d80e695ca..77469f88d19 100644 --- a/lib/private/l10n/string.php +++ b/lib/private/l10n/string.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Jakob Sack <mail@jakobsack.de> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> diff --git a/lib/private/legacy/appconfig.php b/lib/private/legacy/appconfig.php index 3bf1fbd739e..54e568d9ff6 100644 --- a/lib/private/legacy/appconfig.php +++ b/lib/private/legacy/appconfig.php @@ -5,6 +5,7 @@ * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/lock/memcachelockingprovider.php b/lib/private/lock/memcachelockingprovider.php index 85b62c8340f..5f2b5e5a4b8 100644 --- a/lib/private/lock/memcachelockingprovider.php +++ b/lib/private/lock/memcachelockingprovider.php @@ -1,6 +1,8 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/lock/nooplockingprovider.php b/lib/private/lock/nooplockingprovider.php index 4f33b881555..a8571f2aec4 100644 --- a/lib/private/lock/nooplockingprovider.php +++ b/lib/private/lock/nooplockingprovider.php @@ -1,5 +1,7 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/log.php b/lib/private/log.php index 840713b2eda..dd5cb6efbb9 100644 --- a/lib/private/log.php +++ b/lib/private/log.php @@ -2,7 +2,6 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Bernhard Posselt <dev@bernhard-posselt.com> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/private/log/errorhandler.php b/lib/private/log/errorhandler.php index 5e92db398f9..d10c44cc0cd 100644 --- a/lib/private/log/errorhandler.php +++ b/lib/private/log/errorhandler.php @@ -3,6 +3,7 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Björn Schießle <schiessle@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/log/owncloud.php b/lib/private/log/owncloud.php index 0125164394d..01112ef7f9d 100644 --- a/lib/private/log/owncloud.php +++ b/lib/private/log/owncloud.php @@ -2,18 +2,11 @@ /** * @author Andreas Fischer <bantu@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> - * @author Bernhard Posselt <dev@bernhard-posselt.com> - * @author Björn Schießle <schiessle@owncloud.com> - * @author Felix Moeller <mail@felixmoeller.de> - * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> - * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Owen Winkler <a_github@midnightcircus.com> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Tom Needham <tom@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/log/syslog.php b/lib/private/log/syslog.php index 8595b707d59..863d1d6c201 100644 --- a/lib/private/log/syslog.php +++ b/lib/private/log/syslog.php @@ -1,6 +1,5 @@ <?php /** - * @author Andreas Fischer <bantu@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/private/memcache/arraycache.php b/lib/private/memcache/arraycache.php index 8a3fdd2f7c5..33c8bea8746 100644 --- a/lib/private/memcache/arraycache.php +++ b/lib/private/memcache/arraycache.php @@ -2,6 +2,7 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/memcache/factory.php b/lib/private/memcache/factory.php index 320657a71ad..5bb7e42c808 100644 --- a/lib/private/memcache/factory.php +++ b/lib/private/memcache/factory.php @@ -6,6 +6,8 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/memcache/nullcache.php b/lib/private/memcache/nullcache.php index f971ffc9b2d..de27b03e71d 100644 --- a/lib/private/memcache/nullcache.php +++ b/lib/private/memcache/nullcache.php @@ -1,7 +1,10 @@ <?php /** * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Thomas Müller <thomas.mueller@tmit.eu> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/memcache/redis.php b/lib/private/memcache/redis.php index 30619c356bc..21477798059 100644 --- a/lib/private/memcache/redis.php +++ b/lib/private/memcache/redis.php @@ -2,7 +2,9 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> + * @author Michael Telatynski <7t3chguy@gmail.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/mimetypes.list.php b/lib/private/mimetypes.list.php index 5f222cbd835..efb8089420e 100644 --- a/lib/private/mimetypes.list.php +++ b/lib/private/mimetypes.list.php @@ -1,10 +1,12 @@ <?php /** + * @author Aidan Amavi <github@aidanamavi.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Normal Ra <normalraw@gmail.com> * @author Olivier Paroz <github@oparoz.com> * @author Robin Appelman <icewind@owncloud.com> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Thomas Tanghus <thomas@tanghus.net> * @author tiezdne <oswald.84@t-online.de> * @author Victor Dubiniuk <dubiniuk@owncloud.com> @@ -45,6 +47,7 @@ return array( 'blend' => array('application/x-blender', null), 'bin' => array('application/x-bin', null), 'bmp' => array('image/bmp', null), + 'bpg' => array('image/bpg', null), 'cb7' => array('application/x-cbr', null), 'cba' => array('application/x-cbr', null), 'cbr' => array('application/x-cbr', null), diff --git a/lib/private/ocsclient.php b/lib/private/ocsclient.php index f10a97428e2..18ba4cea003 100644 --- a/lib/private/ocsclient.php +++ b/lib/private/ocsclient.php @@ -7,11 +7,11 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Kamil Domanski <kdomanski@kdemail.net> * @author Lukas Reschke <lukas@owncloud.com> + * @author Martin Mattel <martin.mattel@diemattels.at> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Sam Tuke <mail@samtuke.com> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -106,11 +106,12 @@ class OCSClient { /** * Get all the categories from the OCS server * + * @param array $targetVersion The target ownCloud version * @return array|null an array of category ids or null * @note returns NULL if config value appstoreenabled is set to false * This function returns a list of all the application categories on the OCS server */ - public function getCategories() { + public function getCategories(array $targetVersion) { if (!$this->isAppStoreEnabled()) { return null; } @@ -121,6 +122,9 @@ class OCSClient { $this->getAppStoreUrl() . '/content/categories', [ 'timeout' => 5, + 'query' => [ + 'version' => implode('x', $targetVersion), + ], ] ); } catch(\Exception $e) { @@ -155,9 +159,10 @@ class OCSClient { * @param array $categories * @param int $page * @param string $filter + * @param array $targetVersion The target ownCloud version * @return array An array of application data */ - public function getApplications(array $categories, $page, $filter) { + public function getApplications(array $categories, $page, $filter, array $targetVersion) { if (!$this->isAppStoreEnabled()) { return []; } @@ -169,7 +174,7 @@ class OCSClient { [ 'timeout' => 5, 'query' => [ - 'version' => implode('x', \OC_Util::getVersion()), + 'version' => implode('x', $targetVersion), 'filter' => $filter, 'categories' => implode('x', $categories), 'sortmode' => 'new', @@ -229,11 +234,12 @@ class OCSClient { * Get an the applications from the OCS server * * @param string $id + * @param array $targetVersion The target ownCloud version * @return array|null an array of application data or null * * This function returns an applications from the OCS server */ - public function getApplication($id) { + public function getApplication($id, array $targetVersion) { if (!$this->isAppStoreEnabled()) { return null; } @@ -244,6 +250,9 @@ class OCSClient { $this->getAppStoreUrl() . '/content/data/' . urlencode($id), [ 'timeout' => 5, + 'query' => [ + 'version' => implode('x', $targetVersion), + ], ] ); } catch(\Exception $e) { @@ -284,16 +293,18 @@ class OCSClient { $app['description'] = (string)$tmp->description; $app['detailpage'] = (string)$tmp->detailpage; $app['score'] = (int)$tmp->score; + $app['level'] = (int)$tmp->approved; return $app; } /** * Get the download url for an application from the OCS server - * @param $id + * @param string $id + * @param array $targetVersion The target ownCloud version * @return array|null an array of application data or null */ - public function getApplicationDownload($id) { + public function getApplicationDownload($id, array $targetVersion) { if (!$this->isAppStoreEnabled()) { return null; } @@ -304,6 +315,9 @@ class OCSClient { $url, [ 'timeout' => 5, + 'query' => [ + 'version' => implode('x', $targetVersion), + ], ] ); } catch(\Exception $e) { diff --git a/lib/private/preview.php b/lib/private/preview.php index f3599852838..cc954bc3653 100644 --- a/lib/private/preview.php +++ b/lib/private/preview.php @@ -7,9 +7,8 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Olivier Paroz <github@oparoz.com> * @author Robin Appelman <icewind@owncloud.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tobias Kaminsky <tobias@kaminsky.me> * diff --git a/lib/private/preview/bitmap.php b/lib/private/preview/bitmap.php index 3071c788724..12ad4f020eb 100644 --- a/lib/private/preview/bitmap.php +++ b/lib/private/preview/bitmap.php @@ -2,7 +2,7 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/bmp.php b/lib/private/preview/bmp.php index 0547f053cc1..2a24a783d52 100644 --- a/lib/private/preview/bmp.php +++ b/lib/private/preview/bmp.php @@ -1,6 +1,7 @@ <?php /** - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/gif.php b/lib/private/preview/gif.php index e2b7c7e2ea2..08f6c41d98c 100644 --- a/lib/private/preview/gif.php +++ b/lib/private/preview/gif.php @@ -1,6 +1,7 @@ <?php /** - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/image.php b/lib/private/preview/image.php index dbaf5deb08d..f9c27e690f6 100644 --- a/lib/private/preview/image.php +++ b/lib/private/preview/image.php @@ -1,9 +1,9 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Olivier Paroz <owncloud@interfasys.ch> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Thomas Tanghus <thomas@tanghus.net> * diff --git a/lib/private/preview/jpeg.php b/lib/private/preview/jpeg.php index 69edd95835c..86e447d3406 100644 --- a/lib/private/preview/jpeg.php +++ b/lib/private/preview/jpeg.php @@ -1,6 +1,7 @@ <?php /** - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/markdown.php b/lib/private/preview/markdown.php index f73351125ed..f5e74697621 100644 --- a/lib/private/preview/markdown.php +++ b/lib/private/preview/markdown.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/movie.php b/lib/private/preview/movie.php index 43e49bfb747..a687fefff65 100644 --- a/lib/private/preview/movie.php +++ b/lib/private/preview/movie.php @@ -1,9 +1,9 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/preview/mp3.php b/lib/private/preview/mp3.php index 49667d0dd05..25fe6566e44 100644 --- a/lib/private/preview/mp3.php +++ b/lib/private/preview/mp3.php @@ -1,9 +1,9 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Thomas Tanghus <thomas@tanghus.net> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/preview/msoffice2003.php b/lib/private/preview/msoffice2003.php index 1403000f619..dd00cacedf3 100644 --- a/lib/private/preview/msoffice2003.php +++ b/lib/private/preview/msoffice2003.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/msoffice2007.php b/lib/private/preview/msoffice2007.php index bd53b59fe62..8fcdabc0484 100644 --- a/lib/private/preview/msoffice2007.php +++ b/lib/private/preview/msoffice2007.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/msofficedoc.php b/lib/private/preview/msofficedoc.php index bae41017616..6ce003387fb 100644 --- a/lib/private/preview/msofficedoc.php +++ b/lib/private/preview/msofficedoc.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/office.php b/lib/private/preview/office.php index 0a61a32df40..f72c5def35f 100644 --- a/lib/private/preview/office.php +++ b/lib/private/preview/office.php @@ -2,6 +2,7 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/opendocument.php b/lib/private/preview/opendocument.php index ce24bb22d8b..21df2b5909a 100644 --- a/lib/private/preview/opendocument.php +++ b/lib/private/preview/opendocument.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/png.php b/lib/private/preview/png.php index f40c1dbcc88..a6755671326 100644 --- a/lib/private/preview/png.php +++ b/lib/private/preview/png.php @@ -1,6 +1,7 @@ <?php /** - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/provider.php b/lib/private/preview/provider.php index ed1f3a1c5c9..d9b80939246 100644 --- a/lib/private/preview/provider.php +++ b/lib/private/preview/provider.php @@ -3,6 +3,8 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/preview/staroffice.php b/lib/private/preview/staroffice.php index 43e2e8e7f3c..b06de79f707 100644 --- a/lib/private/preview/staroffice.php +++ b/lib/private/preview/staroffice.php @@ -1,7 +1,6 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/svg.php b/lib/private/preview/svg.php index 92d21c07385..4e3cba576fb 100644 --- a/lib/private/preview/svg.php +++ b/lib/private/preview/svg.php @@ -1,9 +1,9 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/preview/txt.php b/lib/private/preview/txt.php index 684438684fb..0bba570a8c9 100644 --- a/lib/private/preview/txt.php +++ b/lib/private/preview/txt.php @@ -1,9 +1,7 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Nmz <nemesiz@nmz.lt> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/private/preview/xbitmap.php b/lib/private/preview/xbitmap.php index db7b85ff012..8001f21684a 100644 --- a/lib/private/preview/xbitmap.php +++ b/lib/private/preview/xbitmap.php @@ -1,6 +1,7 @@ <?php /** - * @author Olivier Paroz <owncloud@interfasys.ch> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/previewmanager.php b/lib/private/previewmanager.php index 78ae12cd2e5..e351c010c85 100644 --- a/lib/private/previewmanager.php +++ b/lib/private/previewmanager.php @@ -2,6 +2,7 @@ /** * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/lib/private/repair.php b/lib/private/repair.php index 43350995beb..166efd3eb8f 100644 --- a/lib/private/repair.php +++ b/lib/private/repair.php @@ -1,5 +1,6 @@ <?php /** + * @author Arthur Schiwon <blizzz@owncloud.com> * @author Georg Ehrke <georg@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> @@ -33,6 +34,7 @@ use OC\Repair\AssetCache; use OC\Repair\CleanTags; use OC\Repair\Collation; use OC\Repair\DropOldJobs; +use OC\Repair\RemoveGetETagEntries; use OC\Repair\SqliteAutoincrement; use OC\Repair\DropOldTables; use OC\Repair\FillETags; @@ -108,6 +110,7 @@ class Repair extends BasicEmitter { new CleanTags(\OC_DB::getConnection()), new DropOldTables(\OC_DB::getConnection()), new DropOldJobs(\OC::$server->getJobList()), + new RemoveGetETagEntries(\OC_DB::getConnection()), ); } diff --git a/lib/private/repairstep.php b/lib/private/repairstep.php index ef0dfa9ed5f..25cb91da68e 100644 --- a/lib/private/repairstep.php +++ b/lib/private/repairstep.php @@ -1,6 +1,5 @@ <?php /** - * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/response.php b/lib/private/response.php index 5725af2b893..f1a429463f2 100644 --- a/lib/private/response.php +++ b/lib/private/response.php @@ -1,5 +1,6 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> diff --git a/lib/private/route/route.php b/lib/private/route/route.php index b33360f11ec..86f05b85e5b 100644 --- a/lib/private/route/route.php +++ b/lib/private/route/route.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author David Prévot <taffit@debian.org> * @author Felix Moeller <mail@felixmoeller.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/lib/private/server.php b/lib/private/server.php index 7e233e64575..6a65895cd69 100644 --- a/lib/private/server.php +++ b/lib/private/server.php @@ -1,5 +1,6 @@ <?php /** + * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Bernhard Reiter <ockham@raz.or.at> diff --git a/lib/private/servernotavailableexception.php b/lib/private/servernotavailableexception.php index 5a57917d23a..b273f50be98 100644 --- a/lib/private/servernotavailableexception.php +++ b/lib/private/servernotavailableexception.php @@ -15,7 +15,7 @@ * GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License, version 3, - * along with this program. If not, see <http://www.gnu.org/licenses/> + * along with this program. If not, see <http://www.gnu.org/licenses/> * */ diff --git a/lib/private/setup.php b/lib/private/setup.php index 1ffe074dc34..50bf0dceafc 100644 --- a/lib/private/setup.php +++ b/lib/private/setup.php @@ -10,7 +10,6 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Martin Mattel <martin.mattel@diemattels.at> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Sean Comeau <sean@ftlnetworks.ca> * @author Serge Martin <edb@sigluy.net> diff --git a/lib/private/setup/abstractdatabase.php b/lib/private/setup/abstractdatabase.php index cc361a62caf..13daf1782fc 100644 --- a/lib/private/setup/abstractdatabase.php +++ b/lib/private/setup/abstractdatabase.php @@ -2,7 +2,6 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/setup/mysql.php b/lib/private/setup/mysql.php index 713c779e2cc..b9246a915a6 100644 --- a/lib/private/setup/mysql.php +++ b/lib/private/setup/mysql.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Michael Göhler <somebody.here@gmx.de> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/private/setup/oci.php b/lib/private/setup/oci.php index 4e1cb7de610..791dc7232f5 100644 --- a/lib/private/setup/oci.php +++ b/lib/private/setup/oci.php @@ -4,7 +4,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> * diff --git a/lib/private/setup/postgresql.php b/lib/private/setup/postgresql.php index 082cb6073ff..597e38f43a6 100644 --- a/lib/private/setup/postgresql.php +++ b/lib/private/setup/postgresql.php @@ -4,7 +4,6 @@ * @author Christopher Schäpers <kondou@ts.unde.re> * @author eduardo <eduardo@vnexu.net> * @author Joas Schilling <nickvergessen@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/setup/sqlite.php b/lib/private/setup/sqlite.php index 4a9ead3d510..820a89d4cff 100644 --- a/lib/private/setup/sqlite.php +++ b/lib/private/setup/sqlite.php @@ -1,7 +1,6 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/share/helper.php b/lib/private/share/helper.php index 65167dd7549..26bbca81317 100644 --- a/lib/private/share/helper.php +++ b/lib/private/share/helper.php @@ -4,6 +4,7 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Miguel Prokop <miguel.prokop@vtu.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> @@ -27,6 +28,8 @@ namespace OC\Share; +use OC\HintException; + class Helper extends \OC\Share\Constants { /** @@ -216,32 +219,74 @@ class Helper extends \OC\Share\Constants { } /** - * Extracts the necessary remote name from a given link + * Strips away a potential file names and trailing slashes: + * - http://localhost + * - http://localhost/ + * - http://localhost/index.php + * - http://localhost/index.php/s/{shareToken} * - * Strips away a potential file name, to allow - * - user - * - user@localhost - * - user@http://localhost - * - user@http://localhost/ - * - user@http://localhost/index.php - * - user@http://localhost/index.php/s/{shareToken} + * all return: http://localhost * * @param string $shareWith * @return string */ - public static function fixRemoteURLInShareWith($shareWith) { - if (strpos($shareWith, '@')) { - list($user, $remote) = explode('@', $shareWith, 2); + protected static function fixRemoteURL($remote) { + $remote = str_replace('\\', '/', $remote); + if ($fileNamePosition = strpos($remote, '/index.php')) { + $remote = substr($remote, 0, $fileNamePosition); + } + $remote = rtrim($remote, '/'); - $remote = str_replace('\\', '/', $remote); - if ($fileNamePosition = strpos($remote, '/index.php')) { - $remote = substr($remote, 0, $fileNamePosition); - } - $remote = rtrim($remote, '/'); + return $remote; + } + + /** + * split user and remote from federated cloud id + * + * @param string $id + * @return array + * @throws HintException + */ + public static function splitUserRemote($id) { + if (strpos($id, '@') === false) { + $l = \OC::$server->getL10N('core'); + $hint = $l->t('Invalid Federated Cloud ID'); + throw new HintException('Invalid Federated Cloud ID', $hint); + } + + // Find the first character that is not allowed in user names + $id = str_replace('\\', '/', $id); + $posSlash = strpos($id, '/'); + $posColon = strpos($id, ':'); + + if ($posSlash === false && $posColon === false) { + $invalidPos = strlen($id); + } else if ($posSlash === false) { + $invalidPos = $posColon; + } else if ($posColon === false) { + $invalidPos = $posSlash; + } else { + $invalidPos = min($posSlash, $posColon); + } + + // Find the last @ before $invalidPos + $pos = $lastAtPos = 0; + while ($lastAtPos !== false && $lastAtPos <= $invalidPos) { + $pos = $lastAtPos; + $lastAtPos = strpos($id, '@', $pos + 1); + } - $shareWith = $user . '@' . $remote; + if ($pos !== false) { + $user = substr($id, 0, $pos); + $remote = substr($id, $pos + 1); + $remote = self::fixRemoteURL($remote); + if (!empty($user) && !empty($remote)) { + return array($user, $remote); + } } - return rtrim($shareWith, '/'); + $l = \OC::$server->getL10N('core'); + $hint = $l->t('Invalid Federated Cloud ID'); + throw new HintException('Invalid Fededrated Cloud ID', $hint); } } diff --git a/lib/private/share/mailnotifications.php b/lib/private/share/mailnotifications.php index 7120d8493b0..8056260bf17 100644 --- a/lib/private/share/mailnotifications.php +++ b/lib/private/share/mailnotifications.php @@ -2,11 +2,11 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tom Needham <tom@owncloud.com> - * @author Lukas Reschke <lukas@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/share/share.php b/lib/private/share/share.php index 954071fdd6c..af7f78b9ff5 100644 --- a/lib/private/share/share.php +++ b/lib/private/share/share.php @@ -127,8 +127,8 @@ class Share extends Constants { $cache = false; $view = new \OC\Files\View('/' . $ownerUser . '/files'); - if ($view->file_exists($path)) { - $meta = $view->getFileInfo($path); + $meta = $view->getFileInfo($path); + if ($meta) { $path = substr($meta->getPath(), strlen('/' . $ownerUser . '/files')); } else { // if the file doesn't exists yet we start with the parent folder @@ -372,6 +372,22 @@ class Share extends Constants { if ($fileDependent && !self::isFileReachable($row['path'], $row['storage_id'])) { continue; } + if ($fileDependent && (int)$row['file_parent'] === -1) { + // if it is a mount point we need to get the path from the mount manager + $mountManager = \OC\Files\Filesystem::getMountManager(); + $mountPoint = $mountManager->findByStorageId($row['storage_id']); + if (!empty($mountPoint)) { + $path = $mountPoint[0]->getMountPoint(); + $path = trim($path, '/'); + $path = substr($path, strlen($owner) + 1); //normalize path to 'files/foo.txt` + $row['path'] = $path; + } else { + \OC::$server->getLogger()->warning( + 'Could not resolve mount point for ' . $row['storage_id'], + ['app' => 'OCP\Share'] + ); + } + } $shares[] = $row; } @@ -554,6 +570,7 @@ class Share extends Constants { * @param string $itemSourceName * @param \DateTime $expirationDate * @return boolean|string Returns true on success or false on failure, Returns token on success for links + * @throws \OC\HintException when the share type is remote and the shareWith is invalid * @throws \Exception */ public static function shareItem($itemType, $itemSource, $shareType, $shareWith, $permissions, $itemSourceName = null, \DateTime $expirationDate = null) { @@ -749,7 +766,8 @@ class Share extends Constants { $token = \OC::$server->getSecureRandom()->getMediumStrengthGenerator()->generate(self::TOKEN_LENGTH, \OCP\Security\ISecureRandom::CHAR_LOWER . \OCP\Security\ISecureRandom::CHAR_UPPER . \OCP\Security\ISecureRandom::CHAR_DIGITS); - $shareWith = Helper::fixRemoteURLInShareWith($shareWith); + list($user, $remote) = Helper::splitUserRemote($shareWith); + $shareWith = $user . '@' . $remote; $shareId = self::put($itemType, $itemSource, $shareType, $shareWith, $uidOwner, $permissions, null, $token, $itemSourceName); $send = false; @@ -1300,8 +1318,8 @@ class Share extends Constants { $hookParams['deletedShares'] = $deletedShares; \OC_Hook::emit('OCP\Share', 'post_unshare', $hookParams); if ((int)$item['share_type'] === \OCP\Share::SHARE_TYPE_REMOTE && \OC::$server->getUserSession()->getUser()) { - $urlParts = explode('@', $item['share_with'], 2); - self::sendRemoteUnshare($urlParts[1], $item['id'], $item['token']); + list(, $remote) = Helper::splitUserRemote($item['share_with']); + self::sendRemoteUnshare($remote, $item['id'], $item['token']); } } @@ -1703,11 +1721,20 @@ class Share extends Constants { $row['permissions'] &= ~\OCP\Constants::PERMISSION_SHARE; } // Add display names to result + $row['share_with_displayname'] = $row['share_with']; if ( isset($row['share_with']) && $row['share_with'] != '' && - isset($row['share_with']) && $row['share_type'] === self::SHARE_TYPE_USER) { + $row['share_type'] === self::SHARE_TYPE_USER) { $row['share_with_displayname'] = \OCP\User::getDisplayName($row['share_with']); - } else { - $row['share_with_displayname'] = $row['share_with']; + } else if(isset($row['share_with']) && $row['share_with'] != '' && + $row['share_type'] === self::SHARE_TYPE_REMOTE) { + $addressBookEntries = \OC::$server->getContactsManager()->search($row['share_with'], ['CLOUD']); + foreach ($addressBookEntries as $entry) { + foreach ($entry['CLOUD'] as $cloudID) { + if ($cloudID === $row['share_with']) { + $row['share_with_displayname'] = $entry['FN']; + } + } + } } if ( isset($row['uid_owner']) && $row['uid_owner'] != '') { $row['displayname_owner'] = \OCP\User::getDisplayName($row['uid_owner']); @@ -2279,7 +2306,7 @@ class Share extends Constants { if ($fileDependent) { $select = '`*PREFIX*share`.`id`, `*PREFIX*share`.`parent`, `share_type`, `path`, `storage`, ' . '`share_with`, `uid_owner` , `file_source`, `stime`, `*PREFIX*share`.`permissions`, ' - . '`*PREFIX*storages`.`id` AS `storage_id`'; + . '`*PREFIX*storages`.`id` AS `storage_id`, `*PREFIX*filecache`.`parent` as `file_parent`'; } else { $select = '`id`, `parent`, `share_type`, `share_with`, `uid_owner`, `item_source`, `stime`, `*PREFIX*share`.`permissions`'; } @@ -2289,7 +2316,7 @@ class Share extends Constants { $select = '`*PREFIX*share`.`id`, `item_type`, `item_source`, `*PREFIX*share`.`parent`,' . ' `share_type`, `share_with`, `file_source`, `file_target`, `path`, `*PREFIX*share`.`permissions`, `stime`,' . ' `expiration`, `token`, `storage`, `mail_send`, `uid_owner`, ' - . '`*PREFIX*storages`.`id` AS `storage_id`'; + . '`*PREFIX*storages`.`id` AS `storage_id`, `*PREFIX*filecache`.`parent` as `file_parent`'; } else { $select = '`id`, `item_type`, `item_source`, `parent`, `share_type`, `share_with`, `*PREFIX*share`.`permissions`,' . ' `stime`, `file_source`, `expiration`, `token`, `mail_send`, `uid_owner`'; @@ -2306,7 +2333,7 @@ class Share extends Constants { . '`*PREFIX*share`.`parent`, `share_type`, `share_with`, `uid_owner`,' . '`file_source`, `path`, `file_target`, `*PREFIX*share`.`permissions`,' . '`stime`, `expiration`, `token`, `storage`, `mail_send`,' - . '`*PREFIX*storages`.`id` AS `storage_id`'; + . '`*PREFIX*storages`.`id` AS `storage_id`, `*PREFIX*filecache`.`parent` as `file_parent`'; } } } @@ -2427,10 +2454,10 @@ class Share extends Constants { */ private static function sendRemoteShare($token, $shareWith, $name, $remote_id, $owner) { - list($user, $remote) = explode('@', $shareWith, 2); + list($user, $remote) = Helper::splitUserRemote($shareWith); if ($user && $remote) { - $url = rtrim($remote, '/') . self::BASE_PATH_TO_SHARE_API . '?format=' . self::RESPONSE_FORMAT; + $url = $remote . self::BASE_PATH_TO_SHARE_API . '?format=' . self::RESPONSE_FORMAT; $local = \OC::$server->getURLGenerator()->getAbsoluteURL('/'); diff --git a/lib/private/template/resourcenotfoundexception.php b/lib/private/template/resourcenotfoundexception.php index 26655b78eee..22f8bcea059 100644 --- a/lib/private/template/resourcenotfoundexception.php +++ b/lib/private/template/resourcenotfoundexception.php @@ -1,6 +1,7 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/templatelayout.php b/lib/private/templatelayout.php index 998a683d841..93bf6cbd307 100644 --- a/lib/private/templatelayout.php +++ b/lib/private/templatelayout.php @@ -9,6 +9,7 @@ * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Remco Brenninkmeijer <requist1@starmail.nl> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> diff --git a/lib/private/tempmanager.php b/lib/private/tempmanager.php index eeffc6b339d..b8cef8e036e 100644 --- a/lib/private/tempmanager.php +++ b/lib/private/tempmanager.php @@ -1,8 +1,9 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * @author Robin Appelman <icewind@owncloud.com> - * @author Lukas Reschke <lukas@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/private/updater.php b/lib/private/updater.php index 00c6569a52f..cba87434165 100644 --- a/lib/private/updater.php +++ b/lib/private/updater.php @@ -8,6 +8,7 @@ * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Steffen Lindner <mail@steffen-lindner.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Victor Dubiniuk <dubiniuk@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> @@ -73,7 +74,9 @@ class Updater extends BasicEmitter { * @param IConfig $config * @param ILogger $log */ - public function __construct(HTTPHelper $httpHelper, IConfig $config, ILogger $log = null) { + public function __construct(HTTPHelper $httpHelper, + IConfig $config, + ILogger $log = null) { $this->httpHelper = $httpHelper; $this->log = $log; $this->config = $config; @@ -126,12 +129,12 @@ class Updater extends BasicEmitter { } if (is_null($updaterUrl)) { - $updaterUrl = 'https://apps.owncloud.com/updater.php'; + $updaterUrl = 'https://updates.owncloud.com/server/'; } $this->config->setAppValue('core', 'lastupdatedat', time()); - if ($this->config->getAppValue('core', 'installedat', '') == '') { + if ($this->config->getAppValue('core', 'installedat', '') === '') { $this->config->setAppValue('core', 'installedat', microtime(true)); } @@ -146,22 +149,20 @@ class Updater extends BasicEmitter { //fetch xml data from updater $url = $updaterUrl . '?version=' . $versionString; - // set a sensible timeout of 10 sec to stay responsive even if the update server is down. - - $tmp = array(); + $tmp = []; $xml = $this->httpHelper->getUrlContent($url); if ($xml) { $loadEntities = libxml_disable_entity_loader(true); $data = @simplexml_load_string($xml); libxml_disable_entity_loader($loadEntities); if ($data !== false) { - $tmp['version'] = $data->version; - $tmp['versionstring'] = $data->versionstring; - $tmp['url'] = $data->url; - $tmp['web'] = $data->web; + $tmp['version'] = (string)$data->version; + $tmp['versionstring'] = (string)$data->versionstring; + $tmp['url'] = (string)$data->url; + $tmp['web'] = (string)$data->web; } } else { - $data = array(); + $data = []; } // Cache the result @@ -238,6 +239,12 @@ class Updater extends BasicEmitter { $repair->listen('\OC\Repair', 'error', function ($description) { $this->emit('\OC\Updater', 'repairError', array($description)); }); + $repair->listen('\OC\Repair', 'info', function ($description) { + $this->emit('\OC\Updater', 'repairInfo', array($description)); + }); + $repair->listen('\OC\Repair', 'step', function ($description) { + $this->emit('\OC\Updater', 'repairStep', array($description)); + }); } /** @@ -359,7 +366,6 @@ class Updater extends BasicEmitter { include \OC_App::getAppPath($appId) . '/appinfo/preupdate.php'; } - /** * upgrades all apps within a major ownCloud upgrade. Also loads "priority" * (types authentication, filesystem, logging, in that order) afterwards. @@ -410,6 +416,9 @@ class Updater extends BasicEmitter { * ownCloud version. disable them if not. * This is important if you upgrade ownCloud and have non ported 3rd * party apps installed. + * + * @return array + * @throws \Exception */ private function checkAppsRequirements() { $isCoreUpgrade = $this->isCodeUpgrade(); @@ -446,6 +455,9 @@ class Updater extends BasicEmitter { return $disabledApps; } + /** + * @return bool + */ private function isCodeUpgrade() { $installedVersion = $this->config->getSystemValue('version', '0.0.0'); $currentVersion = implode('.', OC_Util::getVersion()); @@ -455,7 +467,11 @@ class Updater extends BasicEmitter { return false; } - private function upgradeAppStoreApps($disabledApps) { + /** + * @param array $disabledApps + * @throws \Exception + */ + private function upgradeAppStoreApps(array $disabledApps) { foreach($disabledApps as $app) { if (OC_Installer::isUpdateAvailable($app)) { $ocsId = \OC::$server->getConfig()->getAppValue($app, 'ocsid', ''); diff --git a/lib/private/user.php b/lib/private/user.php index 8083b4e40be..7c3cb528a9a 100644 --- a/lib/private/user.php +++ b/lib/private/user.php @@ -10,6 +10,7 @@ * @author Florian Preinstorfer <nblock@archlinux.us> * @author Georg Ehrke <georg@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/lib/private/user/backend.php b/lib/private/user/backend.php index 0775bc05588..10bf3e28085 100644 --- a/lib/private/user/backend.php +++ b/lib/private/user/backend.php @@ -134,11 +134,13 @@ abstract class OC_User_Backend implements OC_User_Interface { } /** - * Get a list of all users - * @return array an array of all uids - * - * Get a list of all users. - */ + * Get a list of all users + * + * @param string $search + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids + */ public function getUsers($search = '', $limit = null, $offset = null) { return array(); } @@ -171,10 +173,12 @@ abstract class OC_User_Backend implements OC_User_Interface { } /** - * Get a list of all display names - * @return array an array of all displayNames (value) and the corresponding uids (key) - * * Get a list of all display names and user ids. + * + * @param string $search + * @param string|null $limit + * @param string|null $offset + * @return array an array of all displayNames (value) and the corresponding uids (key) */ public function getDisplayNames($search = '', $limit = null, $offset = null) { $displayNames = array(); diff --git a/lib/private/user/database.php b/lib/private/user/database.php index d080bff04b5..3cf73f939e5 100644 --- a/lib/private/user/database.php +++ b/lib/private/user/database.php @@ -8,6 +8,7 @@ * @author fabian <fabian@web2.0-apps.de> * @author Georg Ehrke <georg@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Michael Gapczynski <GapczynskiM@gmail.com> @@ -142,10 +143,12 @@ class OC_User_Database extends OC_User_Backend implements \OCP\IUserBackend { } /** - * Get a list of all display names - * @return array an array of all displayNames (value) and the correspondig uids (key) - * * Get a list of all display names and user ids. + * + * @param string $search + * @param string|null $limit + * @param string|null $offset + * @return array an array of all displayNames (value) and the corresponding uids (key) */ public function getDisplayNames($search = '', $limit = null, $offset = null) { $parameters = []; @@ -223,9 +226,11 @@ class OC_User_Database extends OC_User_Backend implements \OCP\IUserBackend { /** * Get a list of all users - * @return array an array of all uids * - * Get a list of all users. + * @param string $search + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids */ public function getUsers($search = '', $limit = null, $offset = null) { $parameters = []; diff --git a/lib/private/user/dummy.php b/lib/private/user/dummy.php index 85552740fac..3779f7b5ddf 100644 --- a/lib/private/user/dummy.php +++ b/lib/private/user/dummy.php @@ -108,11 +108,9 @@ class OC_User_Dummy extends OC_User_Backend implements \OCP\IUserBackend { * Get a list of all users * * @param string $search - * @param int $limit - * @param int $offset - * @return string[] with all uids - * - * Get a list of all users. + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids */ public function getUsers($search = '', $limit = null, $offset = null) { if (empty($search)) { diff --git a/lib/private/user/interface.php b/lib/private/user/interface.php index abaca9bad7c..1ccda618e10 100644 --- a/lib/private/user/interface.php +++ b/lib/private/user/interface.php @@ -28,35 +28,37 @@ interface OC_User_Interface { /** - * Check if backend implements actions - * @param int $actions bitwise-or'ed actions - * @return boolean - * - * Returns the supported actions as int to be - * compared with \OC_User_Backend::CREATE_USER etc. - */ + * Check if backend implements actions + * @param int $actions bitwise-or'ed actions + * @return boolean + * + * Returns the supported actions as int to be + * compared with \OC_User_Backend::CREATE_USER etc. + */ public function implementsActions($actions); /** - * delete a user - * @param string $uid The username of the user to delete - * @return bool - */ + * delete a user + * @param string $uid The username of the user to delete + * @return bool + */ public function deleteUser($uid); /** - * Get a list of all users - * @return array an array of all uids - * - * Get a list of all users. - */ + * Get a list of all users + * + * @param string $search + * @param null|int $limit + * @param null|int $offset + * @return string[] an array of all uids + */ public function getUsers($search = '', $limit = null, $offset = null); /** - * check if a user exists - * @param string $uid the username - * @return boolean - */ + * check if a user exists + * @param string $uid the username + * @return boolean + */ public function userExists($uid); /** @@ -67,10 +69,12 @@ interface OC_User_Interface { public function getDisplayName($uid); /** - * Get a list of all display names - * @return array an array of all displayNames (value) and the corresponding uids (key) - * * Get a list of all display names and user ids. + * + * @param string $search + * @param string|null $limit + * @param string|null $offset + * @return array an array of all displayNames (value) and the corresponding uids (key) */ public function getDisplayNames($search = '', $limit = null, $offset = null); diff --git a/lib/private/user/nouserexception.php b/lib/private/user/nouserexception.php index 9452362b4e6..0a077d960bd 100644 --- a/lib/private/user/nouserexception.php +++ b/lib/private/user/nouserexception.php @@ -1,12 +1,23 @@ <?php /** - * ownCloud + * @author Jörn Friedrich Dreyer <jfd@butonic.de> + * @author Morris Jobke <hey@morrisjobke.de> * - * This file is licensed under the Affero General Public License version 3 or - * later. See the COPYING-AGPL file. + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> * - * @author Jörn Friedrich Dreyer <jfd@owncloud.com> - * @copyright Jörn Friedrich Dreyer 2015 */ namespace OC\User; diff --git a/lib/private/util.php b/lib/private/util.php index 59408c0fc03..9c78ad3ad1c 100644 --- a/lib/private/util.php +++ b/lib/private/util.php @@ -11,10 +11,10 @@ * @author Christian Reiner <github@christian-reiner.info> * @author Christopher Schäpers <kondou@ts.unde.re> * @author Clark Tomlinson <fallen013@gmail.com> + * @author cmeh <cmeh@users.noreply.github.com> * @author Florin Peter <github@florin-peter.de> * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author helix84 <helix84@centrum.sk> * @author Jakob Sack <mail@jakobsack.de> * @author Joas Schilling <nickvergessen@owncloud.com> diff --git a/lib/public/api.php b/lib/public/api.php index 6b920b6cf52..a99a3af1c1d 100644 --- a/lib/public/api.php +++ b/lib/public/api.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Tom Needham <tom@owncloud.com> * diff --git a/lib/public/app/iappmanager.php b/lib/public/app/iappmanager.php index 208cd70f422..d8f261660c1 100644 --- a/lib/public/app/iappmanager.php +++ b/lib/public/app/iappmanager.php @@ -1,5 +1,6 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * diff --git a/lib/public/appframework/http/datadisplayresponse.php b/lib/public/appframework/http/datadisplayresponse.php index 35272d0f823..31b4c83ff3c 100644 --- a/lib/public/appframework/http/datadisplayresponse.php +++ b/lib/public/appframework/http/datadisplayresponse.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Roeland Jago Douma <roeland@famdouma.nl> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/appframework/http/icallbackresponse.php b/lib/public/appframework/http/icallbackresponse.php index 87da73a5ad5..aa238cbcac9 100644 --- a/lib/public/appframework/http/icallbackresponse.php +++ b/lib/public/appframework/http/icallbackresponse.php @@ -2,6 +2,7 @@ /** * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/appframework/http/ioutput.php b/lib/public/appframework/http/ioutput.php index ad90dc1e4cb..ba4c031001b 100644 --- a/lib/public/appframework/http/ioutput.php +++ b/lib/public/appframework/http/ioutput.php @@ -1,6 +1,7 @@ <?php /** * @author Bernhard Posselt <dev@bernhard-posselt.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/appframework/http/notfoundresponse.php b/lib/public/appframework/http/notfoundresponse.php index 8f59384faf1..968df6c310c 100644 --- a/lib/public/appframework/http/notfoundresponse.php +++ b/lib/public/appframework/http/notfoundresponse.php @@ -1,6 +1,7 @@ <?php /** * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/appframework/http/streamresponse.php b/lib/public/appframework/http/streamresponse.php index 625b3d62278..b2e0df3a75f 100644 --- a/lib/public/appframework/http/streamresponse.php +++ b/lib/public/appframework/http/streamresponse.php @@ -2,6 +2,7 @@ /** * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/appframework/iapi.php b/lib/public/appframework/iapi.php index 2de2a360453..7d1d230a77f 100644 --- a/lib/public/appframework/iapi.php +++ b/lib/public/appframework/iapi.php @@ -2,7 +2,6 @@ /** * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/lib/public/command/ibus.php b/lib/public/command/ibus.php index b27edc04742..796862fbcac 100644 --- a/lib/public/command/ibus.php +++ b/lib/public/command/ibus.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/command/icommand.php b/lib/public/command/icommand.php index 6ec07575b44..ed152f4c6c3 100644 --- a/lib/public/command/icommand.php +++ b/lib/public/command/icommand.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/encryption/exceptions/genericencryptionexception.php b/lib/public/encryption/exceptions/genericencryptionexception.php index 5648e5edf73..c1041e81642 100644 --- a/lib/public/encryption/exceptions/genericencryptionexception.php +++ b/lib/public/encryption/exceptions/genericencryptionexception.php @@ -1,6 +1,9 @@ <?php /** + * @author Björn Schießle <schiessle@owncloud.com> * @author Clark Tomlinson <fallen013@gmail.com> + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/encryption/iencryptionmodule.php b/lib/public/encryption/iencryptionmodule.php index 975e57744e9..183b322e714 100644 --- a/lib/public/encryption/iencryptionmodule.php +++ b/lib/public/encryption/iencryptionmodule.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/encryption/ifile.php b/lib/public/encryption/ifile.php index 8b3f0fa4bf3..0d1381238f0 100644 --- a/lib/public/encryption/ifile.php +++ b/lib/public/encryption/ifile.php @@ -1,6 +1,7 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/encryption/imanager.php b/lib/public/encryption/imanager.php index 0b12c7524d2..07e2925b76c 100644 --- a/lib/public/encryption/imanager.php +++ b/lib/public/encryption/imanager.php @@ -1,6 +1,9 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/encryption/keys/istorage.php b/lib/public/encryption/keys/istorage.php index 17677814107..e206373c46a 100644 --- a/lib/public/encryption/keys/istorage.php +++ b/lib/public/encryption/keys/istorage.php @@ -1,6 +1,8 @@ <?php /** * @author Björn Schießle <schiessle@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/files/filenametoolongexception.php b/lib/public/files/filenametoolongexception.php index ccf56e19a6b..61cb8a21fb6 100644 --- a/lib/public/files/filenametoolongexception.php +++ b/lib/public/files/filenametoolongexception.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/files/invalidcharacterinpathexception.php b/lib/public/files/invalidcharacterinpathexception.php index a25712353b6..52e20dfcb46 100644 --- a/lib/public/files/invalidcharacterinpathexception.php +++ b/lib/public/files/invalidcharacterinpathexception.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/files/reservedwordexception.php b/lib/public/files/reservedwordexception.php index 0fda9841194..fc70c607185 100644 --- a/lib/public/files/reservedwordexception.php +++ b/lib/public/files/reservedwordexception.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/files/storage.php b/lib/public/files/storage.php index a238b77eb96..41218996382 100644 --- a/lib/public/files/storage.php +++ b/lib/public/files/storage.php @@ -1,6 +1,5 @@ <?php /** - * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> @@ -88,7 +87,7 @@ interface Storage { public function opendir($path); /** - * see http://php.net/manual/en/function.is_dir.php + * see http://php.net/manual/en/function.is-dir.php * * @param string $path * @return bool @@ -97,7 +96,7 @@ interface Storage { public function is_dir($path); /** - * see http://php.net/manual/en/function.is_file.php + * see http://php.net/manual/en/function.is-file.php * * @param string $path * @return bool diff --git a/lib/public/http/client/iclient.php b/lib/public/http/client/iclient.php index ab907dcfb82..aadb9efd1bb 100644 --- a/lib/public/http/client/iclient.php +++ b/lib/public/http/client/iclient.php @@ -1,6 +1,7 @@ <?php /** * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/http/client/iclientservice.php b/lib/public/http/client/iclientservice.php index 2a8bff7bc69..14dfcc071b8 100644 --- a/lib/public/http/client/iclientservice.php +++ b/lib/public/http/client/iclientservice.php @@ -1,6 +1,7 @@ <?php /** * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/http/client/iresponse.php b/lib/public/http/client/iresponse.php index 3a717d1650c..0e0ef4c5014 100644 --- a/lib/public/http/client/iresponse.php +++ b/lib/public/http/client/iresponse.php @@ -1,6 +1,7 @@ <?php /** * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/icertificatemanager.php b/lib/public/icertificatemanager.php index aeb18fd37f5..b1a16d8b5ee 100644 --- a/lib/public/icertificatemanager.php +++ b/lib/public/icertificatemanager.php @@ -1,5 +1,6 @@ <?php /** + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * diff --git a/lib/public/igroupmanager.php b/lib/public/igroupmanager.php index 4f41c808c9f..862c77218de 100644 --- a/lib/public/igroupmanager.php +++ b/lib/public/igroupmanager.php @@ -1,6 +1,8 @@ <?php /** * @author Bernhard Posselt <dev@bernhard-posselt.com> + * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * diff --git a/lib/public/ihelper.php b/lib/public/ihelper.php index 41fe3f57c0a..45a078b6cbc 100644 --- a/lib/public/ihelper.php +++ b/lib/public/ihelper.php @@ -1,6 +1,7 @@ <?php /** * @author Bart Visscher <bartv@thisnet.nl> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/iimage.php b/lib/public/iimage.php index c62bf36d2de..38db14db77c 100644 --- a/lib/public/iimage.php +++ b/lib/public/iimage.php @@ -1,6 +1,8 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> + * @author Olivier Paroz <github@oparoz.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/imemcache.php b/lib/public/imemcache.php index a1a00791b63..01c29903039 100644 --- a/lib/public/imemcache.php +++ b/lib/public/imemcache.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/iservercontainer.php b/lib/public/iservercontainer.php index 27702803207..97ca7f13aa6 100644 --- a/lib/public/iservercontainer.php +++ b/lib/public/iservercontainer.php @@ -4,6 +4,7 @@ * @author Bernhard Posselt <dev@bernhard-posselt.com> * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> diff --git a/lib/public/itags.php b/lib/public/itags.php index 7faeb619fde..12dbdc1522a 100644 --- a/lib/public/itags.php +++ b/lib/public/itags.php @@ -1,10 +1,7 @@ <?php /** * @author Bernhard Reiter <ockham@raz.or.at> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Morris Jobke <hey@morrisjobke.de> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> - * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.com> * @author Thomas Tanghus <thomas@tanghus.net> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/lib/public/lock/ilockingprovider.php b/lib/public/lock/ilockingprovider.php index fd2aa615452..f1aa7956033 100644 --- a/lib/public/lock/ilockingprovider.php +++ b/lib/public/lock/ilockingprovider.php @@ -1,5 +1,6 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/public/lock/lockedexception.php b/lib/public/lock/lockedexception.php index d6cec4cc48a..e7071339618 100644 --- a/lib/public/lock/lockedexception.php +++ b/lib/public/lock/lockedexception.php @@ -1,6 +1,8 @@ <?php /** + * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/mail/imailer.php b/lib/public/mail/imailer.php index 9580104a8bf..ac3fe9b0e49 100644 --- a/lib/public/mail/imailer.php +++ b/lib/public/mail/imailer.php @@ -1,6 +1,7 @@ <?php /** * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/preview/iprovider.php b/lib/public/preview/iprovider.php index 1a581768ad4..821cdb32fa3 100644 --- a/lib/public/preview/iprovider.php +++ b/lib/public/preview/iprovider.php @@ -1,6 +1,7 @@ <?php /** * @author Joas Schilling <nickvergessen@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/public/response.php b/lib/public/response.php index 42220e4cf9c..953c797824c 100644 --- a/lib/public/response.php +++ b/lib/public/response.php @@ -1,7 +1,9 @@ <?php /** + * @author Andreas Fischer <bantu@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> * @author Frank Karlitschek <frank@owncloud.org> + * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/public/share.php b/lib/public/share.php index 6c8b82f4293..86e6deb9194 100644 --- a/lib/public/share.php +++ b/lib/public/share.php @@ -9,6 +9,7 @@ * @author Michael Kuhn <suraia@ikkoku.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> + * @author Roeland Jago Douma <roeland@famdouma.nl> * @author Sam Tuke <mail@samtuke.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @@ -255,6 +256,7 @@ class Share extends \OC\Share\Constants { * @param string $itemSourceName * @param \DateTime $expirationDate * @return bool|string Returns true on success or false on failure, Returns token on success for links + * @throws \OC\HintException when the share type is remote and the shareWith is invalid * @throws \Exception * @since 5.0.0 - parameter $itemSourceName was added in 6.0.0, parameter $expirationDate was added in 7.0.0 */ diff --git a/lib/public/template.php b/lib/public/template.php index 63079c0fc30..cc91bff2528 100644 --- a/lib/public/template.php +++ b/lib/public/template.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> - * @author Georg Ehrke <georg@ownCloud.com> * @author Jan-Christoph Borchardt <hey@jancborchardt.net> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> diff --git a/lib/public/user.php b/lib/public/user.php index e2413e32783..23f77c0a35f 100644 --- a/lib/public/user.php +++ b/lib/public/user.php @@ -7,7 +7,6 @@ * @author Joas Schilling <nickvergessen@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lorenzo M. Catucci <lorenzo@sancho.ccd.uniroma2.it> - * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin McCorkell <rmccorkell@karoshi.org.uk> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/lib/repair/collation.php b/lib/repair/collation.php index e28ee3ab114..7eb14f0ded2 100644 --- a/lib/repair/collation.php +++ b/lib/repair/collation.php @@ -60,6 +60,7 @@ class Collation extends BasicEmitter implements \OC\RepairStep { $tables = $this->getAllNonUTF8BinTables($this->connection); foreach ($tables as $table) { + $this->emit('\OC\Repair', 'info', array("Change collation for $table ...")); $query = $this->connection->prepare('ALTER TABLE `' . $table . '` CONVERT TO CHARACTER SET utf8 COLLATE utf8_bin;'); $query->execute(); } diff --git a/lib/repair/preview.php b/lib/repair/preview.php index 28c0ab96683..2284da93734 100644 --- a/lib/repair/preview.php +++ b/lib/repair/preview.php @@ -1,7 +1,6 @@ <?php /** * @author Georg Ehrke <georg@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/lib/repair/removegetetagentries.php b/lib/repair/removegetetagentries.php new file mode 100644 index 00000000000..40040763654 --- /dev/null +++ b/lib/repair/removegetetagentries.php @@ -0,0 +1,59 @@ +<?php +/** + * @author Morris Jobke <hey@morrisjobke.de> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace OC\Repair; + +use OC\Hooks\BasicEmitter; +use OCP\IDBConnection; + +class RemoveGetETagEntries extends BasicEmitter { + + /** + * @var IDBConnection + */ + protected $connection; + + /** + * @param IDBConnection $connection + */ + public function __construct(IDBConnection $connection) { + $this->connection = $connection; + } + + public function getName() { + return 'Remove getetag entries in properties table'; + } + + /** + * Removes all entries with the key "{DAV:}getetag" from the table properties + */ + public function run() { + $sql = 'DELETE FROM `*PREFIX*properties`' + . ' WHERE `propertyname` = ?'; + $deletedRows = $this->connection->executeUpdate($sql, ['{DAV:}getetag']); + + $this->emit( + '\OC\Repair', + 'info', + ['Removed ' . $deletedRows . ' unneeded "{DAV:}getetag" entries from properties table.'] + ); + } +} diff --git a/lib/repair/repairlegacystorages.php b/lib/repair/repairlegacystorages.php index 1bc49678f0d..5ba452cbbc6 100644 --- a/lib/repair/repairlegacystorages.php +++ b/lib/repair/repairlegacystorages.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Vincent Petry <pvince81@owncloud.com> * diff --git a/lib/repair/repairmimetypes.php b/lib/repair/repairmimetypes.php index fa6aa1130d6..89ad0ed16c7 100644 --- a/lib/repair/repairmimetypes.php +++ b/lib/repair/repairmimetypes.php @@ -1,8 +1,10 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Normal Ra <normalraw@gmail.com> * @author Olivier Paroz <github@oparoz.com> + * @author Victor Dubiniuk <dubiniuk@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/lib/repair/sqliteautoincrement.php b/lib/repair/sqliteautoincrement.php index 79b1fe7870e..b8ae5c47ff3 100644 --- a/lib/repair/sqliteautoincrement.php +++ b/lib/repair/sqliteautoincrement.php @@ -1,9 +1,23 @@ <?php /** - * Copyright (c) 2015 Vincent Petry <pvince81@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Morris Jobke <hey@morrisjobke.de> + * @author Vincent Petry <pvince81@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OC\Repair; diff --git a/ocs-provider/index.php b/ocs-provider/index.php new file mode 100644 index 00000000000..316b39cace8 --- /dev/null +++ b/ocs-provider/index.php @@ -0,0 +1,34 @@ +<?php +/** + * @author Lukas Reschke <lukas@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +require_once('../lib/base.php'); +require_once(__DIR__ . '/provider.php'); + +header('Content-Type: application/json'); + +$server = \OC::$server; + +$controller = new Provider( + 'ocs_provider', + $server->getRequest(), + $server->getAppManager() +); +echo $controller->buildProviderList()->render(); diff --git a/ocs-provider/provider.php b/ocs-provider/provider.php new file mode 100644 index 00000000000..04da7402c98 --- /dev/null +++ b/ocs-provider/provider.php @@ -0,0 +1,92 @@ +<?php +/** + * @author Lukas Reschke <lukas@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +class Provider extends \OCP\AppFramework\Controller { + /** @var \OCP\App\IAppManager */ + private $appManager; + + /** + * @param string $appName + * @param \OCP\IRequest $request + * @param \OCP\App\IAppManager $appManager + */ + public function __construct($appName, + \OCP\IRequest $request, + \OCP\App\IAppManager $appManager) { + parent::__construct($appName, $request); + $this->appManager = $appManager; + } + + /** + * @return \OCP\AppFramework\Http\JSONResponse + */ + public function buildProviderList() { + $services = [ + 'version' => 2, + 'PRIVATE_DATA' => [ + 'version' => 1, + 'endpoints' => [ + 'store' => '/ocs/v1.php/privatedata/setattribute', + 'read' => '/ocs/v1.php/privatedata/getattribute', + 'delete' => '/ocs/v1.php/privatedata/deleteattribute', + ], + ], + ]; + + if($this->appManager->isEnabledForUser('files_sharing')) { + $services['SHARING'] = [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/apps/files_sharing/api/v1/shares', + ], + ]; + $services['FEDERATED_SHARING'] = [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/cloud/shares', + 'webdav' => '/public.php/webdav/', + ], + ]; + } + + if($this->appManager->isEnabledForUser('activity')) { + $services['ACTIVITY'] = [ + 'version' => 1, + 'endpoints' => [ + 'list' => '/ocs/v1.php/cloud/activity', + ], + ]; + } + + if($this->appManager->isEnabledForUser('provisioning_api')) { + $services['PROVISIONING'] = [ + 'version' => 1, + 'endpoints' => [ + 'user' => '/ocs/v1.php/cloud/users', + 'groups' => '/ocs/v1.php/cloud/groups', + 'apps' => '/ocs/v1.php/cloud/apps', + ], + ]; + } + + return new \OCP\AppFramework\Http\JSONResponse($services); + } +}
\ No newline at end of file diff --git a/ocs/routes.php b/ocs/routes.php index 751a16d538e..f8e6f33c48a 100644 --- a/ocs/routes.php +++ b/ocs/routes.php @@ -2,6 +2,7 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tom Needham <tom@owncloud.com> diff --git a/ocs/v1.php b/ocs/v1.php index 8002ca602e6..2829cf08c57 100644 --- a/ocs/v1.php +++ b/ocs/v1.php @@ -4,6 +4,7 @@ * @author Frank Karlitschek <frank@owncloud.org> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Tom Needham <tom@owncloud.com> * @author Vincent Petry <pvince81@owncloud.com> diff --git a/public.php b/public.php index f390166d06e..858e8af7782 100644 --- a/public.php +++ b/public.php @@ -7,6 +7,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> + * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/remote.php b/remote.php index 4db887a0843..0b43f949ad4 100644 --- a/remote.php +++ b/remote.php @@ -5,7 +5,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jörn Friedrich Dreyer <jfd@butonic.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * @author Vincent Petry <pvince81@owncloud.com> @@ -26,22 +25,72 @@ * along with this program. If not, see <http://www.gnu.org/licenses/> * */ + +use OC\Connector\Sabre\ExceptionLoggerPlugin; +use Sabre\DAV\Exception\ServiceUnavailable; +use Sabre\DAV\Server; + +/** + * Class RemoteException + * Dummy exception class to be use locally to identify certain conditions + */ +class RemoteException extends Exception { +} + +/** + * @param Exception $e + */ +function handleException(Exception $e) { + $request = \OC::$server->getRequest(); + // in case the request content type is text/xml - we assume it's a WebDAV request + $isXmlContentType = strpos($request->getHeader('Content-Type'), 'text/xml'); + if ($isXmlContentType === 0) { + // fire up a simple server to properly process the exception + $server = new Server(); + $server->addPlugin(new ExceptionLoggerPlugin('webdav', \OC::$server->getLogger())); + $server->on('beforeMethod', function () use ($e) { + if ($e instanceof RemoteException) { + switch ($e->getCode()) { + case OC_Response::STATUS_SERVICE_UNAVAILABLE: + throw new ServiceUnavailable($e->getMessage()); + case OC_Response::STATUS_NOT_FOUND: + throw new \Sabre\DAV\Exception\NotFound($e->getMessage()); + } + } + $class = get_class($e); + $msg = $e->getMessage(); + throw new ServiceUnavailable("$class: $msg"); + }); + $server->exec(); + } else { + $statusCode = OC_Response::STATUS_INTERNAL_SERVER_ERROR; + if ($e instanceof \OC\ServiceUnavailableException ) { + $statusCode = OC_Response::STATUS_SERVICE_UNAVAILABLE; + } + \OCP\Util::writeLog('remote', $e->getMessage(), \OCP\Util::FATAL); + if ($e instanceof RemoteException) { + OC_Response::setStatus($e->getCode()); + OC_Template::printErrorPage($e->getMessage()); + } else { + OC_Response::setStatus($statusCode); + OC_Template::printExceptionErrorPage($e); + } + } +} + try { require_once 'lib/base.php'; if (\OCP\Util::needUpgrade()) { // since the behavior of apps or remotes are unpredictable during // an upgrade, return a 503 directly - OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE); - OC_Template::printErrorPage('Service unavailable'); - exit; + throw new RemoteException('Service unavailable', OC_Response::STATUS_SERVICE_UNAVAILABLE); } $request = \OC::$server->getRequest(); $pathInfo = $request->getPathInfo(); if ($pathInfo === false || $pathInfo === '') { - OC_Response::setStatus(OC_Response::STATUS_NOT_FOUND); - exit; + throw new RemoteException('Path not found', OC_Response::STATUS_NOT_FOUND); } if (!$pos = strpos($pathInfo, '/', 1)) { $pos = strlen($pathInfo); @@ -51,8 +100,7 @@ try { $file = \OC::$server->getConfig()->getAppValue('core', 'remote_' . $service); if(is_null($file)) { - OC_Response::setStatus(OC_Response::STATUS_NOT_FOUND); - exit; + throw new RemoteException('Path not found', OC_Response::STATUS_NOT_FOUND); } // force language as given in the http request @@ -83,12 +131,6 @@ try { $baseuri = OC::$WEBROOT . '/remote.php/'.$service.'/'; require_once $file; -} catch (\OC\ServiceUnavailableException $ex) { - OC_Response::setStatus(OC_Response::STATUS_SERVICE_UNAVAILABLE); - \OCP\Util::writeLog('remote', $ex->getMessage(), \OCP\Util::FATAL); - OC_Template::printExceptionErrorPage($ex); } catch (Exception $ex) { - OC_Response::setStatus(OC_Response::STATUS_INTERNAL_SERVER_ERROR); - \OCP\Util::writeLog('remote', $ex->getMessage(), \OCP\Util::FATAL); - OC_Template::printExceptionErrorPage($ex); + handleException($ex); } diff --git a/settings/admin.php b/settings/admin.php index ee252ceb141..533b6152492 100644 --- a/settings/admin.php +++ b/settings/admin.php @@ -2,11 +2,13 @@ /** * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> + * @author Björn Schießle <schiessle@owncloud.com> * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> * @author Jan-Christoph Borchardt <hey@jancborchardt.net> * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Martin Mattel <martin.mattel@diemattels.at> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> diff --git a/settings/ajax/enableapp.php b/settings/ajax/enableapp.php index b63bce76d92..69b186bb9f3 100644 --- a/settings/ajax/enableapp.php +++ b/settings/ajax/enableapp.php @@ -4,7 +4,6 @@ * @author Christopher Schäpers <kondou@ts.unde.re> * @author Kamil Domanski <kdomanski@kdemail.net> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/settings/ajax/navigationdetect.php b/settings/ajax/navigationdetect.php index 16c7e20955f..d7c1cbc5a12 100644 --- a/settings/ajax/navigationdetect.php +++ b/settings/ajax/navigationdetect.php @@ -2,7 +2,6 @@ /** * @author Bart Visscher <bartv@thisnet.nl> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/settings/ajax/togglegroups.php b/settings/ajax/togglegroups.php index f85505b632c..87b60e485bf 100644 --- a/settings/ajax/togglegroups.php +++ b/settings/ajax/togglegroups.php @@ -5,7 +5,6 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/settings/ajax/togglesubadmins.php b/settings/ajax/togglesubadmins.php index 632768ac368..767baa9f3ee 100644 --- a/settings/ajax/togglesubadmins.php +++ b/settings/ajax/togglesubadmins.php @@ -3,7 +3,6 @@ * @author Bart Visscher <bartv@thisnet.nl> * @author Georg Ehrke <georg@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. diff --git a/settings/ajax/updateapp.php b/settings/ajax/updateapp.php index 4541b80056e..5fc88290c91 100644 --- a/settings/ajax/updateapp.php +++ b/settings/ajax/updateapp.php @@ -4,7 +4,6 @@ * @author Frank Karlitschek <frank@owncloud.org> * @author Georg Ehrke <georg@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> * diff --git a/settings/application.php b/settings/application.php index 920d172c93d..03203b48564 100644 --- a/settings/application.php +++ b/settings/application.php @@ -1,8 +1,11 @@ <?php /** + * @author Björn Schießle <schiessle@owncloud.com> * @author Georg Ehrke <georg@owncloud.com> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/settings/changepassword/controller.php b/settings/changepassword/controller.php index 69b7ca710a9..12499ada15d 100644 --- a/settings/changepassword/controller.php +++ b/settings/changepassword/controller.php @@ -2,10 +2,10 @@ /** * @author Björn Schießle <schiessle@owncloud.com> * @author Christopher Schäpers <kondou@ts.unde.re> + * @author Clark Tomlinson <fallen013@gmail.com> * @author cmeh <cmeh@users.noreply.github.com> * @author Florin Peter <github@florin-peter.de> * @author Jakob Sack <mail@jakobsack.de> - * @author Joas Schilling <nickvergessen@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> * @author Sam Tuke <mail@samtuke.com> diff --git a/settings/controller/appsettingscontroller.php b/settings/controller/appsettingscontroller.php index d64c945c02c..6803985d5db 100644 --- a/settings/controller/appsettingscontroller.php +++ b/settings/controller/appsettingscontroller.php @@ -127,7 +127,7 @@ class AppSettingsController extends Controller { if($this->ocsClient->isAppStoreEnabled()) { // apps from external repo via OCS - $ocs = $this->ocsClient->getCategories(); + $ocs = $this->ocsClient->getCategories(\OC_Util::getVersion()); if ($ocs) { foreach($ocs as $k => $v) { $categories[] = [ @@ -169,6 +169,15 @@ class AppSettingsController extends Controller { } return ($a < $b) ? -1 : 1; }); + foreach($apps as $key => $app) { + if(!array_key_exists('level', $app) && array_key_exists('ocsid', $app)) { + $remoteAppEntry = $this->ocsClient->getApplication($app['ocsid'], \OC_Util::getVersion()); + + if(array_key_exists('level', $remoteAppEntry)) { + $apps[$key]['level'] = $remoteAppEntry['level']; + } + } + } break; // not-installed apps case 1: @@ -176,6 +185,15 @@ class AppSettingsController extends Controller { $apps = array_filter($apps, function ($app) { return !$app['active']; }); + foreach($apps as $key => $app) { + if(!array_key_exists('level', $app) && array_key_exists('ocsid', $app)) { + $remoteAppEntry = $this->ocsClient->getApplication($app['ocsid'], \OC_Util::getVersion()); + + if(array_key_exists('level', $remoteAppEntry)) { + $apps[$key]['level'] = $remoteAppEntry['level']; + } + } + } usort($apps, function ($a, $b) { $a = (string)$a['name']; $b = (string)$b['name']; diff --git a/settings/controller/checksetupcontroller.php b/settings/controller/checksetupcontroller.php index 3ced5af5a5f..0b4c72acab7 100644 --- a/settings/controller/checksetupcontroller.php +++ b/settings/controller/checksetupcontroller.php @@ -1,6 +1,8 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> + * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/settings/controller/groupscontroller.php b/settings/controller/groupscontroller.php index 6cb0cd3e008..218a9c0d51c 100644 --- a/settings/controller/groupscontroller.php +++ b/settings/controller/groupscontroller.php @@ -1,5 +1,6 @@ <?php /** + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * diff --git a/settings/controller/logsettingscontroller.php b/settings/controller/logsettingscontroller.php index f3de1fbb7c6..cae0d419e2b 100644 --- a/settings/controller/logsettingscontroller.php +++ b/settings/controller/logsettingscontroller.php @@ -2,6 +2,7 @@ /** * @author Georg Ehrke <georg@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> + * @author Thomas Müller <thomas.mueller@tmit.eu> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/settings/controller/userscontroller.php b/settings/controller/userscontroller.php index d0b5267e3c8..d9b6ba7f721 100644 --- a/settings/controller/userscontroller.php +++ b/settings/controller/userscontroller.php @@ -1,5 +1,6 @@ <?php /** + * @author Clark Tomlinson <fallen013@gmail.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/settings/l10n/cs_CZ.js b/settings/l10n/cs_CZ.js index 1d3fc13d1b6..b7f3646c30b 100644 --- a/settings/l10n/cs_CZ.js +++ b/settings/l10n/cs_CZ.js @@ -10,6 +10,7 @@ OC.L10N.register( "Cron" : "Cron", "Email server" : "Emailový server", "Log" : "Záznam", + "Server Status" : "Stav serveru", "Tips & tricks" : "Tipy a triky", "Updates" : "Aktualizace", "Authentication error" : "Chyba přihlášení", @@ -55,9 +56,13 @@ OC.L10N.register( "Migration in progress. Please wait until the migration is finished" : "Migrace probíhá. Počkejte prosím než bude dokončena", "Migration started …" : "Migrace spuštěna ...", "Sending..." : "Odesílání...", + "Official" : "Oficiální", + "Approved" : "Potvrzeno", + "Experimental" : "Experimentální", "All" : "Vše", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Oficiální aplikace jsou vyvíjeny komunitou ownCloud. Nabízejí funkce důležité pro ownCloud a jsou připraveny pro nasazení v produkčním prostředí.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Schválené aplikace jsou vyvíjeny důvěryhodnými vývojáři a prošly zběžným bezpečnostním prověřením. Jsou aktivně udržovány v repozitáři s otevřeným kódem a jejich správci je považují za stabilní pro občasné až normální použití.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "U této aplikace nebyla provedena kontrola na bezpečnostní problémy. Aplikace je nová nebo nestabilní. Instalujte pouze na vlastní nebezpečí.", "Update to %s" : "Aktualizovat na %s", "Please wait...." : "Čekejte prosím...", "Error while disabling app" : "Chyba při zakazování aplikace", @@ -115,6 +120,7 @@ OC.L10N.register( "PHP is apparently setup to strip inline doc blocks. This will make several core apps inaccessible." : "PHP je patrně nastaveno tak, aby odstraňovalo bloky komentářů. Toto bude mít za následek nedostupnost množství hlavních aplikací.", "This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "Toto je pravděpodobně způsobeno aplikacemi pro urychlení načítání jako jsou Zend OPcache nebo eAccelerator.", "Your server is running on Microsoft Windows. We highly recommend Linux for optimal user experience." : "Server běží v prostředí Microsoft Windows. Pro optimální uživatelské pohodlí doporučujeme přejít na Linux.", + "%1$s below version %2$s is installed, for stability and performance reasons we recommend to update to a newer %1$s version." : "Je nainstalován %1$s nižší verze než %2$s, z důvodu lepší stability a výkonu doporučujeme aktualizovat na novější verzi %1$s.", "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "Schází PHP modul 'fileinfo'. Doporučujeme jej povolit pro nejlepší výsledky detekce typů MIME.", "System locale can not be set to a one which supports UTF-8." : "Není možné nastavit znakovou sadu, která podporuje UTF-8.", "This means that there might be problems with certain characters in file names." : "To znamená, že se mohou vyskytnout problémy s určitými znaky v názvech souborů.", @@ -180,6 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Vylepšení souboru config.php", "Theming" : "Vzhledy", "Hardening and security guidance" : "Průvodce vylepšením bezpečnosti", + "Transactional File Locking is enabled." : "Transakční zamykání souboru je povoleno.", + "Transactional File Locking is disabled." : "Transakční zamykání souboru není povoleno.", "Version" : "Verze", "Developer documentation" : "Vývojářská dokumentace", "Experimental applications ahead" : "Experimentální aplikace v pořadí", diff --git a/settings/l10n/cs_CZ.json b/settings/l10n/cs_CZ.json index 976c4dc867e..504518dd1c1 100644 --- a/settings/l10n/cs_CZ.json +++ b/settings/l10n/cs_CZ.json @@ -8,6 +8,7 @@ "Cron" : "Cron", "Email server" : "Emailový server", "Log" : "Záznam", + "Server Status" : "Stav serveru", "Tips & tricks" : "Tipy a triky", "Updates" : "Aktualizace", "Authentication error" : "Chyba přihlášení", @@ -53,9 +54,13 @@ "Migration in progress. Please wait until the migration is finished" : "Migrace probíhá. Počkejte prosím než bude dokončena", "Migration started …" : "Migrace spuštěna ...", "Sending..." : "Odesílání...", + "Official" : "Oficiální", + "Approved" : "Potvrzeno", + "Experimental" : "Experimentální", "All" : "Vše", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Oficiální aplikace jsou vyvíjeny komunitou ownCloud. Nabízejí funkce důležité pro ownCloud a jsou připraveny pro nasazení v produkčním prostředí.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Schválené aplikace jsou vyvíjeny důvěryhodnými vývojáři a prošly zběžným bezpečnostním prověřením. Jsou aktivně udržovány v repozitáři s otevřeným kódem a jejich správci je považují za stabilní pro občasné až normální použití.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "U této aplikace nebyla provedena kontrola na bezpečnostní problémy. Aplikace je nová nebo nestabilní. Instalujte pouze na vlastní nebezpečí.", "Update to %s" : "Aktualizovat na %s", "Please wait...." : "Čekejte prosím...", "Error while disabling app" : "Chyba při zakazování aplikace", @@ -113,6 +118,7 @@ "PHP is apparently setup to strip inline doc blocks. This will make several core apps inaccessible." : "PHP je patrně nastaveno tak, aby odstraňovalo bloky komentářů. Toto bude mít za následek nedostupnost množství hlavních aplikací.", "This is probably caused by a cache/accelerator such as Zend OPcache or eAccelerator." : "Toto je pravděpodobně způsobeno aplikacemi pro urychlení načítání jako jsou Zend OPcache nebo eAccelerator.", "Your server is running on Microsoft Windows. We highly recommend Linux for optimal user experience." : "Server běží v prostředí Microsoft Windows. Pro optimální uživatelské pohodlí doporučujeme přejít na Linux.", + "%1$s below version %2$s is installed, for stability and performance reasons we recommend to update to a newer %1$s version." : "Je nainstalován %1$s nižší verze než %2$s, z důvodu lepší stability a výkonu doporučujeme aktualizovat na novější verzi %1$s.", "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "Schází PHP modul 'fileinfo'. Doporučujeme jej povolit pro nejlepší výsledky detekce typů MIME.", "System locale can not be set to a one which supports UTF-8." : "Není možné nastavit znakovou sadu, která podporuje UTF-8.", "This means that there might be problems with certain characters in file names." : "To znamená, že se mohou vyskytnout problémy s určitými znaky v názvech souborů.", @@ -178,6 +184,8 @@ "Improving the config.php" : "Vylepšení souboru config.php", "Theming" : "Vzhledy", "Hardening and security guidance" : "Průvodce vylepšením bezpečnosti", + "Transactional File Locking is enabled." : "Transakční zamykání souboru je povoleno.", + "Transactional File Locking is disabled." : "Transakční zamykání souboru není povoleno.", "Version" : "Verze", "Developer documentation" : "Vývojářská dokumentace", "Experimental applications ahead" : "Experimentální aplikace v pořadí", diff --git a/settings/l10n/da.js b/settings/l10n/da.js index 3b821dcea00..3d93e75e860 100644 --- a/settings/l10n/da.js +++ b/settings/l10n/da.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Alle", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Officielt program er udviklet af ownCloud fællesskabet. Funktionerne spiller en central rolle i ownCloud og kan bruges i produktionsmiljøer.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Godkendte programmer er udviklet af betroet udviklere som har bestået en let sikkerheds gennemgang. De er aktivt vedligeholdt i et åben kode lager og udviklerne vurdere programmet til at være stabilt for normalt brug.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Dette program er ikke kontrolleret for sikkerhedsproblemer, og er nyt eller kendt for at være ustabilt. Installer for egen risiko.", "Update to %s" : "Opdatér til %s", "Please wait...." : "Vent venligst...", "Error while disabling app" : "Kunne ikke deaktivere app", @@ -185,8 +186,6 @@ OC.L10N.register( "Improving the config.php" : "Forbedring af config.php", "Theming" : "Temaer", "Hardening and security guidance" : "Modstanddygtighed og sikkerheds vejledning", - "Experimental File Lock is enabled." : "Eksperimentel fillås er slået til.", - "Experimental File Lock is disabled." : "Eksperimentel fillås er slået fra.", "Version" : "Version", "Developer documentation" : "Dokumentation for udviklere", "Experimental applications ahead" : "Kommende eksperimentale programmer", diff --git a/settings/l10n/da.json b/settings/l10n/da.json index 82a4c87bdc5..db7da4b3585 100644 --- a/settings/l10n/da.json +++ b/settings/l10n/da.json @@ -60,6 +60,7 @@ "All" : "Alle", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Officielt program er udviklet af ownCloud fællesskabet. Funktionerne spiller en central rolle i ownCloud og kan bruges i produktionsmiljøer.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Godkendte programmer er udviklet af betroet udviklere som har bestået en let sikkerheds gennemgang. De er aktivt vedligeholdt i et åben kode lager og udviklerne vurdere programmet til at være stabilt for normalt brug.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Dette program er ikke kontrolleret for sikkerhedsproblemer, og er nyt eller kendt for at være ustabilt. Installer for egen risiko.", "Update to %s" : "Opdatér til %s", "Please wait...." : "Vent venligst...", "Error while disabling app" : "Kunne ikke deaktivere app", @@ -183,8 +184,6 @@ "Improving the config.php" : "Forbedring af config.php", "Theming" : "Temaer", "Hardening and security guidance" : "Modstanddygtighed og sikkerheds vejledning", - "Experimental File Lock is enabled." : "Eksperimentel fillås er slået til.", - "Experimental File Lock is disabled." : "Eksperimentel fillås er slået fra.", "Version" : "Version", "Developer documentation" : "Dokumentation for udviklere", "Experimental applications ahead" : "Kommende eksperimentale programmer", diff --git a/settings/l10n/de.js b/settings/l10n/de.js index b606262f531..b1133558e56 100644 --- a/settings/l10n/de.js +++ b/settings/l10n/de.js @@ -186,8 +186,6 @@ OC.L10N.register( "Improving the config.php" : "Die config.php optimieren", "Theming" : "Themes verwenden", "Hardening and security guidance" : "Systemhärtung und Sicherheitsempfehlungen", - "Experimental File Lock is enabled." : "Experimentelle Dateisperre ist aktiviert.", - "Experimental File Lock is disabled." : "Experimentelle Dateisperre ist deaktiviert.", "Version" : "Version", "Developer documentation" : "Dokumentation für Entwickler", "Experimental applications ahead" : "Experimentelle Apps nachfolgend", diff --git a/settings/l10n/de.json b/settings/l10n/de.json index a0d0ee23f9b..3e623c02bb4 100644 --- a/settings/l10n/de.json +++ b/settings/l10n/de.json @@ -184,8 +184,6 @@ "Improving the config.php" : "Die config.php optimieren", "Theming" : "Themes verwenden", "Hardening and security guidance" : "Systemhärtung und Sicherheitsempfehlungen", - "Experimental File Lock is enabled." : "Experimentelle Dateisperre ist aktiviert.", - "Experimental File Lock is disabled." : "Experimentelle Dateisperre ist deaktiviert.", "Version" : "Version", "Developer documentation" : "Dokumentation für Entwickler", "Experimental applications ahead" : "Experimentelle Apps nachfolgend", diff --git a/settings/l10n/de_DE.js b/settings/l10n/de_DE.js index 2e889228c8e..2f5467dd5b9 100644 --- a/settings/l10n/de_DE.js +++ b/settings/l10n/de_DE.js @@ -186,8 +186,6 @@ OC.L10N.register( "Improving the config.php" : "Die config.php optimieren", "Theming" : "Themes verwenden", "Hardening and security guidance" : "Systemhärtung und Sicherheitsempfehlungen", - "Experimental File Lock is enabled." : "Experimentelle Dateisperre ist aktiviert.", - "Experimental File Lock is disabled." : "Experimentelle Dateisperre ist deaktiviert.", "Version" : "Version", "Developer documentation" : "Dokumentation für Entwickler", "Experimental applications ahead" : "Experimentelle Apps nachfolgend", diff --git a/settings/l10n/de_DE.json b/settings/l10n/de_DE.json index 896dee19893..b64099fe4d2 100644 --- a/settings/l10n/de_DE.json +++ b/settings/l10n/de_DE.json @@ -184,8 +184,6 @@ "Improving the config.php" : "Die config.php optimieren", "Theming" : "Themes verwenden", "Hardening and security guidance" : "Systemhärtung und Sicherheitsempfehlungen", - "Experimental File Lock is enabled." : "Experimentelle Dateisperre ist aktiviert.", - "Experimental File Lock is disabled." : "Experimentelle Dateisperre ist deaktiviert.", "Version" : "Version", "Developer documentation" : "Dokumentation für Entwickler", "Experimental applications ahead" : "Experimentelle Apps nachfolgend", diff --git a/settings/l10n/el.js b/settings/l10n/el.js index 195b191479c..176f74b2ce4 100644 --- a/settings/l10n/el.js +++ b/settings/l10n/el.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Όλες", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Οι επίσημες εφαρμογές αναπτύσσονται από την κοινότητα ownCloud. Προσφέρουν λειτουργικότητα κοντά στο ownCloud και είναι έτοιμες για χρήση.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Οι εγκεκριμένες εφαρμογές αναπτύχθηκαν από αξιόπιστους προγραμματιστές και έχουν περάσει έναν συνοπτικό έλεγχο ασφαλείας. Διατηρούνται ενεργά σε ένα αποθετήριο ανοιχτού κώδικα και οι συντηρητές θεωρούν οτι είναι σταθερές για κανονική χρήση.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Η εφαρμογή αυτή δεν ελέγχεται για θέματα ασφάλειας και είναι νέα ή είναι γνωστό ότι είναι ασταθής. Η εγκατάσταση γίνεται με δική σας ευθύνη.", "Update to %s" : "Ενημέρωση σε %s", "Please wait...." : "Παρακαλώ περιμένετε...", "Error while disabling app" : "Σφάλμα κατά την απενεργοποίηση εισόδου", @@ -185,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Βελτίωση του config.php", "Theming" : "Θέματα", "Hardening and security guidance" : "Οδηγίες ασφάλειας και θωράκισης", - "Experimental File Lock is enabled." : "Το πειραματικό κλείδωμα αρχείων είναι ενεργοποιημένο.", - "Experimental File Lock is disabled." : "Το πειραματικό κλείδωμα αρχείων είναι απενεργοποιημένο.", + "Transactional File Locking is enabled." : "Το μεταβατικό κλείδωμα αρχείων είναι ενεργοποιημένο.", + "Transactional File Locking is disabled." : "Το μεταβατικό κλείδωμα αρχείων είναι απενεργοποιημένο.", "Version" : "Έκδοση", "Developer documentation" : "Τεκμηρίωση προγραμματιστή", "Experimental applications ahead" : "Πειραματικές εφαρμογές", diff --git a/settings/l10n/el.json b/settings/l10n/el.json index 5be1d59fb44..2d99623e8a2 100644 --- a/settings/l10n/el.json +++ b/settings/l10n/el.json @@ -60,6 +60,7 @@ "All" : "Όλες", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Οι επίσημες εφαρμογές αναπτύσσονται από την κοινότητα ownCloud. Προσφέρουν λειτουργικότητα κοντά στο ownCloud και είναι έτοιμες για χρήση.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Οι εγκεκριμένες εφαρμογές αναπτύχθηκαν από αξιόπιστους προγραμματιστές και έχουν περάσει έναν συνοπτικό έλεγχο ασφαλείας. Διατηρούνται ενεργά σε ένα αποθετήριο ανοιχτού κώδικα και οι συντηρητές θεωρούν οτι είναι σταθερές για κανονική χρήση.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Η εφαρμογή αυτή δεν ελέγχεται για θέματα ασφάλειας και είναι νέα ή είναι γνωστό ότι είναι ασταθής. Η εγκατάσταση γίνεται με δική σας ευθύνη.", "Update to %s" : "Ενημέρωση σε %s", "Please wait...." : "Παρακαλώ περιμένετε...", "Error while disabling app" : "Σφάλμα κατά την απενεργοποίηση εισόδου", @@ -183,8 +184,8 @@ "Improving the config.php" : "Βελτίωση του config.php", "Theming" : "Θέματα", "Hardening and security guidance" : "Οδηγίες ασφάλειας και θωράκισης", - "Experimental File Lock is enabled." : "Το πειραματικό κλείδωμα αρχείων είναι ενεργοποιημένο.", - "Experimental File Lock is disabled." : "Το πειραματικό κλείδωμα αρχείων είναι απενεργοποιημένο.", + "Transactional File Locking is enabled." : "Το μεταβατικό κλείδωμα αρχείων είναι ενεργοποιημένο.", + "Transactional File Locking is disabled." : "Το μεταβατικό κλείδωμα αρχείων είναι απενεργοποιημένο.", "Version" : "Έκδοση", "Developer documentation" : "Τεκμηρίωση προγραμματιστή", "Experimental applications ahead" : "Πειραματικές εφαρμογές", diff --git a/settings/l10n/en_GB.js b/settings/l10n/en_GB.js index b14f36e0154..1512ec7e1cf 100644 --- a/settings/l10n/en_GB.js +++ b/settings/l10n/en_GB.js @@ -182,8 +182,6 @@ OC.L10N.register( "Improving the config.php" : "Improving the config.php", "Theming" : "Theming", "Hardening and security guidance" : "Hardening and security guidance", - "Experimental File Lock is enabled." : "Experimental File Lock is enabled.", - "Experimental File Lock is disabled." : "Experimental File Lock is disabled.", "Version" : "Version", "Developer documentation" : "Developer documentation", "Experimental applications ahead" : "Experimental applications ahead", diff --git a/settings/l10n/en_GB.json b/settings/l10n/en_GB.json index c86d1417e8f..143103d032e 100644 --- a/settings/l10n/en_GB.json +++ b/settings/l10n/en_GB.json @@ -180,8 +180,6 @@ "Improving the config.php" : "Improving the config.php", "Theming" : "Theming", "Hardening and security guidance" : "Hardening and security guidance", - "Experimental File Lock is enabled." : "Experimental File Lock is enabled.", - "Experimental File Lock is disabled." : "Experimental File Lock is disabled.", "Version" : "Version", "Developer documentation" : "Developer documentation", "Experimental applications ahead" : "Experimental applications ahead", diff --git a/settings/l10n/es.js b/settings/l10n/es.js index e406af485e7..50267d51c74 100644 --- a/settings/l10n/es.js +++ b/settings/l10n/es.js @@ -186,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Mejorar el config.php", "Theming" : "Personalizar el tema", "Hardening and security guidance" : "Guía de protección y seguridad", - "Experimental File Lock is enabled." : "Experimental files locking habilitado", - "Experimental File Lock is disabled." : "Experimental files locking deshabilitado", + "Transactional File Locking is enabled." : "Bloqueo de archivos transaccional está habilitado.", + "Transactional File Locking is disabled." : "Bloqueo de archivos transaccional está deshabilitado.", "Version" : "Versión", "Developer documentation" : "Documentación de desarrollador", "Experimental applications ahead" : "Aplicaciones experimentales más adelante", diff --git a/settings/l10n/es.json b/settings/l10n/es.json index f351fbd3a0a..b9a49670c90 100644 --- a/settings/l10n/es.json +++ b/settings/l10n/es.json @@ -184,8 +184,8 @@ "Improving the config.php" : "Mejorar el config.php", "Theming" : "Personalizar el tema", "Hardening and security guidance" : "Guía de protección y seguridad", - "Experimental File Lock is enabled." : "Experimental files locking habilitado", - "Experimental File Lock is disabled." : "Experimental files locking deshabilitado", + "Transactional File Locking is enabled." : "Bloqueo de archivos transaccional está habilitado.", + "Transactional File Locking is disabled." : "Bloqueo de archivos transaccional está deshabilitado.", "Version" : "Versión", "Developer documentation" : "Documentación de desarrollador", "Experimental applications ahead" : "Aplicaciones experimentales más adelante", diff --git a/settings/l10n/et_EE.js b/settings/l10n/et_EE.js index e3c8817a814..92cbcc518db 100644 --- a/settings/l10n/et_EE.js +++ b/settings/l10n/et_EE.js @@ -1,10 +1,15 @@ OC.L10N.register( "settings", { + "APCu" : "APCu", + "Redis" : "Redis", "Sharing" : "Jagamine", "External Storage" : "Väline salvestuskoht", "Cron" : "Cron", + "Email server" : "E-kirjade server", "Log" : "Logi", + "Server Status" : "Serveri olek", + "Tips & tricks" : "Nõuanded ja trikid", "Updates" : "Uuendused", "Authentication error" : "Autentimise viga", "Your full name has been changed." : "Sinu täispikk nimi on muudetud.", @@ -23,14 +28,29 @@ OC.L10N.register( "Unable to change password" : "Ei suuda parooli muuta", "Enabled" : "Sisse lülitatud", "Not enabled" : "Pole sisse lülitatud", + "Migration Completed" : "Kolimine on lõpetatud", + "Group already exists." : "Grupp on juba olemas.", + "Unable to add group." : "Gruppi lisamine ebaõnnestus.", + "Unable to delete group." : "Grupi kustutamineebaõnnestus.", "Saved" : "Salvestatud", "test email settings" : "testi e-posti seadeid", "Email sent" : "E-kiri on saadetud", "You need to set your user email before being able to send test emails." : "Pead seadistama oma e-postienne kui on võimalik saata test-kirju.", + "Invalid mail address" : "Vigane e-posti aadress", + "A user with that name already exists." : "Selle nimega kasutaja on juba olemas.", + "Unable to create user." : "Kasutaja loomine ebaõnnestus.", + "Your %s account was created" : "Sinu %s konto on loodud", + "Unable to delete user." : "Kasutaja kustutamine ebaõnnestus.", + "Forbidden" : "Keelatud", + "Invalid user" : "Vigane kasutaja", + "Unable to change mail address" : "E-posti aadressi muutmine ebaõnnestus", "Email saved" : "Kiri on salvestatud", "Are you really sure you want add \"{domain}\" as trusted domain?" : "Oled sa kindel, et soovid lisada domeeni \"{domain}\" usaldusväärseks domeeniks?", "Add trusted domain" : "Lis ausaldusväärne domeen", "Sending..." : "Saadan...", + "Official" : "Ametlik", + "Approved" : "Heaks kiidetud", + "Experimental" : "Katsetusjärgus", "All" : "Kõik", "Update to %s" : "Uuenda versioonile %s", "Please wait...." : "Palun oota...", @@ -66,6 +86,8 @@ OC.L10N.register( "Error creating user" : "Viga kasutaja loomisel", "A valid password must be provided" : "Sisesta nõuetele vastav parool", "__language_name__" : "Eesti", + "Sync clients" : "Klientide sünkroniseerimine", + "Personal info" : "Isiklik info", "SSL root certificates" : "SSL root sertifikaadid", "Everything (fatal issues, errors, warnings, info, debug)" : "Kõik (tõsised probleemid, veateated, hoiatused, info, veatuvastus)", "Info, warnings, errors and fatal issues" : "Info, hoiatused, veateted ja tõsised probleemid", @@ -83,6 +105,7 @@ OC.L10N.register( "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "PHP moodul 'fileinfo' puudub. Soovitame tungivalt see lisada saavutamaks parimaid tulemusi failitüüpide tuvastamisel.", "System locale can not be set to a one which supports UTF-8." : "Süsteemi lokaliseeringuks ei saa panna sellist, mis toetab UTF-8-t.", "This means that there might be problems with certain characters in file names." : "See tähendab, et võib esineda probleeme failide nimedes mõnede sümbolitega.", + "Open documentation" : "Ava dokumentatsioon", "Allow apps to use the Share API" : "Luba rakendustel kasutada Share API-t", "Allow users to share via link" : "Luba kasutajatel lingiga jagamist ", "Enforce password protection" : "Sunni parooliga kaitsmist", @@ -100,6 +123,8 @@ OC.L10N.register( "Execute one task with each page loaded" : "Käivita toiming igal lehe laadimisel", "cron.php is registered at a webcron service to call cron.php every 15 minutes over http." : "cron.php on registreeritud webcron teenuses, et käivitada fail cron.php iga 15 minuti tagant üle http.", "Use system's cron service to call the cron.php file every 15 minutes." : "Kasuta süsteemi cron teenust, et käivitada fail cron.php iga 15 minuti järel.", + "Enable encryption" : "Luba krüpteerimine", + "Start migration" : "Alusta kolimist", "This is used for sending out notifications." : "Seda kasutatakse teadete välja saatmiseks.", "Send mode" : "Saatmise viis", "Encryption" : "Krüpteerimine", @@ -116,19 +141,38 @@ OC.L10N.register( "Test email settings" : "Testi e-posti seadeid", "Send email" : "Saada kiri", "Log level" : "Logi tase", + "Download logfile" : "Laadi logifail alla", "More" : "Rohkem", "Less" : "Vähem", + "How to do backups" : "Kuidas teha varukoopiaid", + "Advanced monitoring" : "Lisavalikutega jälgimine", + "Performance tuning" : "Kiiruse seadistamine", + "Improving the config.php" : "config.php faili täiendamine", + "Theming" : "Teemad", "Version" : "Versioon", + "Developer documentation" : "Arendaja dokumentatsioon", "by" : "lisas", "licensed" : "litsenseeritud", "Documentation:" : "Dokumentatsioon:", "User Documentation" : "Kasutaja dokumentatsioon", "Admin Documentation" : "Admin dokumentatsioon", + "Show description …" : "Näita kirjeldist ...", + "Hide description …" : "Peida kirjeldus ...", "Enable only for specific groups" : "Luba ainult kindlad grupid", "Uninstall App" : "Eemada rakend", + "Enable experimental apps" : "Luba katsetusjärgus rakenduste kasutamine", + "No apps found for your version" : "Sinu versiooni jaoks ei leitud ühtegi rakendust", "Cheers!" : "Terekest!", + "User documentation" : "Kasutaja dokumentatsioon", + "Administrator documentation" : "Administraatori dokumentatsioon", + "Online documentation" : "Võrgus olev dokumentatsioon", "Forum" : "Foorum", + "Issue tracker" : "Probleemide jälgija", + "Commercial support" : "Tasuline kasutajatugi", "Get the apps to sync your files" : "Hangi rakendusi failide sünkroniseerimiseks", + "Desktop client" : "Töölaua klient", + "Android app" : "Androidi rakendus", + "iOS app" : "iOS-i rakendus", "Show First Run Wizard again" : "Näita veelkord Esmase Käivituse Juhendajat", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Kasutad <strong>%s</strong> saadavalolevast <strong>%s</strong>", "Password" : "Parool", @@ -136,9 +180,12 @@ OC.L10N.register( "Current password" : "Praegune parool", "New password" : "Uus parool", "Change password" : "Muuda parooli", + "Full name" : "Täielik nimi", + "No display name set" : "Näidatavat nime pole veel määratud", "Email" : "E-post", "Your email address" : "Sinu e-posti aadress", "Fill in an email address to enable password recovery and receive notifications" : "Täida e-posti aadress võimaldamaks parooli taastamist ning teadete saamist.", + "No email address set" : "E-posti aadressi pole veel määratud", "Profile picture" : "Profiili pilt", "Upload new" : "Laadi uus üles", "Select new from Files" : "Vali failidest uus", @@ -155,10 +202,14 @@ OC.L10N.register( "Valid until %s" : "Kehtib kuni %s", "Show storage location" : "Näita salvestusruumi asukohta", "Show last log in" : "Viimane sisselogimine", + "Send email to new user" : "Saada uuele kasutajale e-kiri", + "Show email address" : "Näita e-posti aadressi", "Username" : "Kasutajanimi", + "E-Mail" : "E-post", "Create" : "Lisa", "Admin Recovery Password" : "Admini parooli taastamine", "Enter the recovery password in order to recover the users files during password change" : "Sisesta taasteparool kasutaja failide taastamiseks paroolivahetuse käigus", + "Search Users" : "Otsi kasutajaid", "Add Group" : "Lisa grupp", "Group" : "Grupp", "Everyone" : "Igaüks", @@ -174,6 +225,7 @@ OC.L10N.register( "Last Login" : "Viimane sisselogimine", "change full name" : "Muuda täispikka nime", "set new password" : "määra uus parool", + "change email address" : "muuda e-posti aadressi", "Default" : "Vaikeväärtus" }, "nplurals=2; plural=(n != 1);"); diff --git a/settings/l10n/et_EE.json b/settings/l10n/et_EE.json index 50c261cd8c3..3181d5dbb66 100644 --- a/settings/l10n/et_EE.json +++ b/settings/l10n/et_EE.json @@ -1,8 +1,13 @@ { "translations": { + "APCu" : "APCu", + "Redis" : "Redis", "Sharing" : "Jagamine", "External Storage" : "Väline salvestuskoht", "Cron" : "Cron", + "Email server" : "E-kirjade server", "Log" : "Logi", + "Server Status" : "Serveri olek", + "Tips & tricks" : "Nõuanded ja trikid", "Updates" : "Uuendused", "Authentication error" : "Autentimise viga", "Your full name has been changed." : "Sinu täispikk nimi on muudetud.", @@ -21,14 +26,29 @@ "Unable to change password" : "Ei suuda parooli muuta", "Enabled" : "Sisse lülitatud", "Not enabled" : "Pole sisse lülitatud", + "Migration Completed" : "Kolimine on lõpetatud", + "Group already exists." : "Grupp on juba olemas.", + "Unable to add group." : "Gruppi lisamine ebaõnnestus.", + "Unable to delete group." : "Grupi kustutamineebaõnnestus.", "Saved" : "Salvestatud", "test email settings" : "testi e-posti seadeid", "Email sent" : "E-kiri on saadetud", "You need to set your user email before being able to send test emails." : "Pead seadistama oma e-postienne kui on võimalik saata test-kirju.", + "Invalid mail address" : "Vigane e-posti aadress", + "A user with that name already exists." : "Selle nimega kasutaja on juba olemas.", + "Unable to create user." : "Kasutaja loomine ebaõnnestus.", + "Your %s account was created" : "Sinu %s konto on loodud", + "Unable to delete user." : "Kasutaja kustutamine ebaõnnestus.", + "Forbidden" : "Keelatud", + "Invalid user" : "Vigane kasutaja", + "Unable to change mail address" : "E-posti aadressi muutmine ebaõnnestus", "Email saved" : "Kiri on salvestatud", "Are you really sure you want add \"{domain}\" as trusted domain?" : "Oled sa kindel, et soovid lisada domeeni \"{domain}\" usaldusväärseks domeeniks?", "Add trusted domain" : "Lis ausaldusväärne domeen", "Sending..." : "Saadan...", + "Official" : "Ametlik", + "Approved" : "Heaks kiidetud", + "Experimental" : "Katsetusjärgus", "All" : "Kõik", "Update to %s" : "Uuenda versioonile %s", "Please wait...." : "Palun oota...", @@ -64,6 +84,8 @@ "Error creating user" : "Viga kasutaja loomisel", "A valid password must be provided" : "Sisesta nõuetele vastav parool", "__language_name__" : "Eesti", + "Sync clients" : "Klientide sünkroniseerimine", + "Personal info" : "Isiklik info", "SSL root certificates" : "SSL root sertifikaadid", "Everything (fatal issues, errors, warnings, info, debug)" : "Kõik (tõsised probleemid, veateated, hoiatused, info, veatuvastus)", "Info, warnings, errors and fatal issues" : "Info, hoiatused, veateted ja tõsised probleemid", @@ -81,6 +103,7 @@ "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "PHP moodul 'fileinfo' puudub. Soovitame tungivalt see lisada saavutamaks parimaid tulemusi failitüüpide tuvastamisel.", "System locale can not be set to a one which supports UTF-8." : "Süsteemi lokaliseeringuks ei saa panna sellist, mis toetab UTF-8-t.", "This means that there might be problems with certain characters in file names." : "See tähendab, et võib esineda probleeme failide nimedes mõnede sümbolitega.", + "Open documentation" : "Ava dokumentatsioon", "Allow apps to use the Share API" : "Luba rakendustel kasutada Share API-t", "Allow users to share via link" : "Luba kasutajatel lingiga jagamist ", "Enforce password protection" : "Sunni parooliga kaitsmist", @@ -98,6 +121,8 @@ "Execute one task with each page loaded" : "Käivita toiming igal lehe laadimisel", "cron.php is registered at a webcron service to call cron.php every 15 minutes over http." : "cron.php on registreeritud webcron teenuses, et käivitada fail cron.php iga 15 minuti tagant üle http.", "Use system's cron service to call the cron.php file every 15 minutes." : "Kasuta süsteemi cron teenust, et käivitada fail cron.php iga 15 minuti järel.", + "Enable encryption" : "Luba krüpteerimine", + "Start migration" : "Alusta kolimist", "This is used for sending out notifications." : "Seda kasutatakse teadete välja saatmiseks.", "Send mode" : "Saatmise viis", "Encryption" : "Krüpteerimine", @@ -114,19 +139,38 @@ "Test email settings" : "Testi e-posti seadeid", "Send email" : "Saada kiri", "Log level" : "Logi tase", + "Download logfile" : "Laadi logifail alla", "More" : "Rohkem", "Less" : "Vähem", + "How to do backups" : "Kuidas teha varukoopiaid", + "Advanced monitoring" : "Lisavalikutega jälgimine", + "Performance tuning" : "Kiiruse seadistamine", + "Improving the config.php" : "config.php faili täiendamine", + "Theming" : "Teemad", "Version" : "Versioon", + "Developer documentation" : "Arendaja dokumentatsioon", "by" : "lisas", "licensed" : "litsenseeritud", "Documentation:" : "Dokumentatsioon:", "User Documentation" : "Kasutaja dokumentatsioon", "Admin Documentation" : "Admin dokumentatsioon", + "Show description …" : "Näita kirjeldist ...", + "Hide description …" : "Peida kirjeldus ...", "Enable only for specific groups" : "Luba ainult kindlad grupid", "Uninstall App" : "Eemada rakend", + "Enable experimental apps" : "Luba katsetusjärgus rakenduste kasutamine", + "No apps found for your version" : "Sinu versiooni jaoks ei leitud ühtegi rakendust", "Cheers!" : "Terekest!", + "User documentation" : "Kasutaja dokumentatsioon", + "Administrator documentation" : "Administraatori dokumentatsioon", + "Online documentation" : "Võrgus olev dokumentatsioon", "Forum" : "Foorum", + "Issue tracker" : "Probleemide jälgija", + "Commercial support" : "Tasuline kasutajatugi", "Get the apps to sync your files" : "Hangi rakendusi failide sünkroniseerimiseks", + "Desktop client" : "Töölaua klient", + "Android app" : "Androidi rakendus", + "iOS app" : "iOS-i rakendus", "Show First Run Wizard again" : "Näita veelkord Esmase Käivituse Juhendajat", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Kasutad <strong>%s</strong> saadavalolevast <strong>%s</strong>", "Password" : "Parool", @@ -134,9 +178,12 @@ "Current password" : "Praegune parool", "New password" : "Uus parool", "Change password" : "Muuda parooli", + "Full name" : "Täielik nimi", + "No display name set" : "Näidatavat nime pole veel määratud", "Email" : "E-post", "Your email address" : "Sinu e-posti aadress", "Fill in an email address to enable password recovery and receive notifications" : "Täida e-posti aadress võimaldamaks parooli taastamist ning teadete saamist.", + "No email address set" : "E-posti aadressi pole veel määratud", "Profile picture" : "Profiili pilt", "Upload new" : "Laadi uus üles", "Select new from Files" : "Vali failidest uus", @@ -153,10 +200,14 @@ "Valid until %s" : "Kehtib kuni %s", "Show storage location" : "Näita salvestusruumi asukohta", "Show last log in" : "Viimane sisselogimine", + "Send email to new user" : "Saada uuele kasutajale e-kiri", + "Show email address" : "Näita e-posti aadressi", "Username" : "Kasutajanimi", + "E-Mail" : "E-post", "Create" : "Lisa", "Admin Recovery Password" : "Admini parooli taastamine", "Enter the recovery password in order to recover the users files during password change" : "Sisesta taasteparool kasutaja failide taastamiseks paroolivahetuse käigus", + "Search Users" : "Otsi kasutajaid", "Add Group" : "Lisa grupp", "Group" : "Grupp", "Everyone" : "Igaüks", @@ -172,6 +223,7 @@ "Last Login" : "Viimane sisselogimine", "change full name" : "Muuda täispikka nime", "set new password" : "määra uus parool", + "change email address" : "muuda e-posti aadressi", "Default" : "Vaikeväärtus" },"pluralForm" :"nplurals=2; plural=(n != 1);" }
\ No newline at end of file diff --git a/settings/l10n/fi_FI.js b/settings/l10n/fi_FI.js index 0cdd7b931cb..cb39b8ca9af 100644 --- a/settings/l10n/fi_FI.js +++ b/settings/l10n/fi_FI.js @@ -175,8 +175,8 @@ OC.L10N.register( "Improving the config.php" : "Config.php-tiedoston parantaminen", "Theming" : "Teemojen käyttö", "Hardening and security guidance" : "Turvaamis- ja tietoturvaopas", - "Experimental File Lock is enabled." : "Kokeellinen tiedostolukitus on käytössä.", - "Experimental File Lock is disabled." : "Kokeellinen tiedostolukitus on pois käytöstä.", + "Transactional File Locking is enabled." : "Transaktiopohjainen tiedostolukitus käytössä.", + "Transactional File Locking is disabled." : "Transaktiopohjainen tiedostolukitus on pois käytöstä.", "Version" : "Versio", "Developer documentation" : "Kehittäjädokumentaatio", "Experimental applications ahead" : "Kokeellisia sovelluksia edessä", diff --git a/settings/l10n/fi_FI.json b/settings/l10n/fi_FI.json index 1545be84685..96e65ca7176 100644 --- a/settings/l10n/fi_FI.json +++ b/settings/l10n/fi_FI.json @@ -173,8 +173,8 @@ "Improving the config.php" : "Config.php-tiedoston parantaminen", "Theming" : "Teemojen käyttö", "Hardening and security guidance" : "Turvaamis- ja tietoturvaopas", - "Experimental File Lock is enabled." : "Kokeellinen tiedostolukitus on käytössä.", - "Experimental File Lock is disabled." : "Kokeellinen tiedostolukitus on pois käytöstä.", + "Transactional File Locking is enabled." : "Transaktiopohjainen tiedostolukitus käytössä.", + "Transactional File Locking is disabled." : "Transaktiopohjainen tiedostolukitus on pois käytöstä.", "Version" : "Versio", "Developer documentation" : "Kehittäjädokumentaatio", "Experimental applications ahead" : "Kokeellisia sovelluksia edessä", diff --git a/settings/l10n/fr.js b/settings/l10n/fr.js index 64f41ad1ee4..6fc16b5e142 100644 --- a/settings/l10n/fr.js +++ b/settings/l10n/fr.js @@ -45,9 +45,9 @@ OC.L10N.register( "Invalid mail address" : "Adresse email non valide", "A user with that name already exists." : "Un utilisateur à ce nom existe déjà.", "Unable to create user." : "Impossible de créer l'utilisateur.", - "Your %s account was created" : "Votre compte %s a été créé.", + "Your %s account was created" : "Votre compte %s a été créé", "Unable to delete user." : "Impossible de supprimer l'utilisateur.", - "Forbidden" : "Iinterdit", + "Forbidden" : "interdit", "Invalid user" : "Utilisateur non valable", "Unable to change mail address" : "Impossible de modifier l'adresse de courriel", "Email saved" : "Email sauvegardé", @@ -75,7 +75,7 @@ OC.L10N.register( "Uninstalling ...." : "Désinstallation...", "Error while uninstalling app" : "Erreur lors de la désinstallation de l'application", "Uninstall" : "Désinstaller", - "Select a profile picture" : "Selectionner une photo de profil ", + "Select a profile picture" : "Selectionnez une photo de profil ", "Very weak password" : "Mot de passe de très faible sécurité", "Weak password" : "Mot de passe de faible sécurité", "So-so password" : "Mot de passe de sécurité tout juste acceptable", @@ -124,7 +124,7 @@ OC.L10N.register( "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "Le module PHP 'fileinfo' est manquant. Il est vivement recommandé de l'activer afin d'obtenir de meilleurs résultats de détection mime-type.", "System locale can not be set to a one which supports UTF-8." : "Les paramètres régionaux ne peuvent pas être configurés avec prise en charge d'UTF-8.", "This means that there might be problems with certain characters in file names." : "Cela signifie qu'il pourrait y avoir des problèmes avec certains caractères dans les noms de fichier.", - "We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "Nous vous recommandons d'installer sur votre système les paquets requis à la prise en charge de l'un des paramètres régionaux suivants : %s", + "We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "Nous vous recommandons d'installer sur votre système les paquets nécessaires à la prise en charge de l'un des paramètres régionaux suivants : %s", "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\")" : "Si votre installation n'a pas été effectuée à la racine du domaine et qu'elle utilise le cron du système, il peut y avoir des problèmes avec la génération d'URL. Pour les éviter, veuillez configurer l'option \"overwrite.cli.url\" de votre fichier config.php avec le chemin de la racine de votre installation (suggéré : \"%s\")", "It was not possible to execute the cronjob via CLI. The following technical errors have appeared:" : "La tâche cron n'a pu s'exécuter via CLI. Ces erreurs techniques sont apparues :", "Please double check the <a target=\"_blank\" href=\"%s\">installation guides ↗</a>, and check for any errors or warnings in the <a href=\"#log-section\">log</a>." : "Consultez les <a target=\"_blank\" href=\"%s\">guides d'installation ↗</a>, et cherchez des erreurs ou avertissements dans <a href=\"#log-section\">les logs</a>.", @@ -186,8 +186,6 @@ OC.L10N.register( "Improving the config.php" : "Amélioration du config.php ", "Theming" : "Personnalisation de l'apparence", "Hardening and security guidance" : "Guide pour le renforcement et la sécurité", - "Experimental File Lock is enabled." : "Le verrouillage expérimental de fichiers est activé.", - "Experimental File Lock is disabled." : "Le verrouillage expérimental de fichiers est désactivé.", "Version" : "Version", "Developer documentation" : "Documentation pour développeurs", "Experimental applications ahead" : "Attention! Applications expérimentales", diff --git a/settings/l10n/fr.json b/settings/l10n/fr.json index b9f94209763..adfe0289230 100644 --- a/settings/l10n/fr.json +++ b/settings/l10n/fr.json @@ -43,9 +43,9 @@ "Invalid mail address" : "Adresse email non valide", "A user with that name already exists." : "Un utilisateur à ce nom existe déjà.", "Unable to create user." : "Impossible de créer l'utilisateur.", - "Your %s account was created" : "Votre compte %s a été créé.", + "Your %s account was created" : "Votre compte %s a été créé", "Unable to delete user." : "Impossible de supprimer l'utilisateur.", - "Forbidden" : "Iinterdit", + "Forbidden" : "interdit", "Invalid user" : "Utilisateur non valable", "Unable to change mail address" : "Impossible de modifier l'adresse de courriel", "Email saved" : "Email sauvegardé", @@ -73,7 +73,7 @@ "Uninstalling ...." : "Désinstallation...", "Error while uninstalling app" : "Erreur lors de la désinstallation de l'application", "Uninstall" : "Désinstaller", - "Select a profile picture" : "Selectionner une photo de profil ", + "Select a profile picture" : "Selectionnez une photo de profil ", "Very weak password" : "Mot de passe de très faible sécurité", "Weak password" : "Mot de passe de faible sécurité", "So-so password" : "Mot de passe de sécurité tout juste acceptable", @@ -122,7 +122,7 @@ "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "Le module PHP 'fileinfo' est manquant. Il est vivement recommandé de l'activer afin d'obtenir de meilleurs résultats de détection mime-type.", "System locale can not be set to a one which supports UTF-8." : "Les paramètres régionaux ne peuvent pas être configurés avec prise en charge d'UTF-8.", "This means that there might be problems with certain characters in file names." : "Cela signifie qu'il pourrait y avoir des problèmes avec certains caractères dans les noms de fichier.", - "We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "Nous vous recommandons d'installer sur votre système les paquets requis à la prise en charge de l'un des paramètres régionaux suivants : %s", + "We strongly suggest installing the required packages on your system to support one of the following locales: %s." : "Nous vous recommandons d'installer sur votre système les paquets nécessaires à la prise en charge de l'un des paramètres régionaux suivants : %s", "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\")" : "Si votre installation n'a pas été effectuée à la racine du domaine et qu'elle utilise le cron du système, il peut y avoir des problèmes avec la génération d'URL. Pour les éviter, veuillez configurer l'option \"overwrite.cli.url\" de votre fichier config.php avec le chemin de la racine de votre installation (suggéré : \"%s\")", "It was not possible to execute the cronjob via CLI. The following technical errors have appeared:" : "La tâche cron n'a pu s'exécuter via CLI. Ces erreurs techniques sont apparues :", "Please double check the <a target=\"_blank\" href=\"%s\">installation guides ↗</a>, and check for any errors or warnings in the <a href=\"#log-section\">log</a>." : "Consultez les <a target=\"_blank\" href=\"%s\">guides d'installation ↗</a>, et cherchez des erreurs ou avertissements dans <a href=\"#log-section\">les logs</a>.", @@ -184,8 +184,6 @@ "Improving the config.php" : "Amélioration du config.php ", "Theming" : "Personnalisation de l'apparence", "Hardening and security guidance" : "Guide pour le renforcement et la sécurité", - "Experimental File Lock is enabled." : "Le verrouillage expérimental de fichiers est activé.", - "Experimental File Lock is disabled." : "Le verrouillage expérimental de fichiers est désactivé.", "Version" : "Version", "Developer documentation" : "Documentation pour développeurs", "Experimental applications ahead" : "Attention! Applications expérimentales", diff --git a/settings/l10n/gl.js b/settings/l10n/gl.js index dd597c7a138..6c2a41777cb 100644 --- a/settings/l10n/gl.js +++ b/settings/l10n/gl.js @@ -186,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Mellorando o config.php", "Theming" : "Tematización", "Hardening and security guidance" : "Orientacións sobre fortificación e seguridade", - "Experimental File Lock is enabled." : "O bloqueo de ficheiros (experimental) está activado.", - "Experimental File Lock is disabled." : "O bloqueo de ficheiros (experimental) está desactivado.", + "Transactional File Locking is enabled." : "O bloque transaccional de ficheiros está activado.", + "Transactional File Locking is disabled." : "O bloque transaccional de ficheiros está desactivado.", "Version" : "Versión", "Developer documentation" : "Documentación do desenvolvedor", "Experimental applications ahead" : "Ante as aplicacións experimentais", diff --git a/settings/l10n/gl.json b/settings/l10n/gl.json index 3d21e3dac8e..570cf1d7757 100644 --- a/settings/l10n/gl.json +++ b/settings/l10n/gl.json @@ -184,8 +184,8 @@ "Improving the config.php" : "Mellorando o config.php", "Theming" : "Tematización", "Hardening and security guidance" : "Orientacións sobre fortificación e seguridade", - "Experimental File Lock is enabled." : "O bloqueo de ficheiros (experimental) está activado.", - "Experimental File Lock is disabled." : "O bloqueo de ficheiros (experimental) está desactivado.", + "Transactional File Locking is enabled." : "O bloque transaccional de ficheiros está activado.", + "Transactional File Locking is disabled." : "O bloque transaccional de ficheiros está desactivado.", "Version" : "Versión", "Developer documentation" : "Documentación do desenvolvedor", "Experimental applications ahead" : "Ante as aplicacións experimentais", diff --git a/settings/l10n/it.js b/settings/l10n/it.js index 95d22bbf48d..9f6032fd7af 100644 --- a/settings/l10n/it.js +++ b/settings/l10n/it.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Tutti", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Le applicazioni ufficiali sono sviluppate da e con la comunità di ownCloud. Offrono le funzioni fondamentali di ownCloud e sono pronte per l'utilizzo in produzione.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Le applicazioni approvate sono sviluppate da sviluppatori affidabili e hanno passato un rapido controllo di sicurezza. Sono attivamente mantenute in un deposito aperto del codice e i loro responsabili le ritengono pronte sia per un utilizzo casuale che per un utilizzo continuativo.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Questa applicazione non è stata sottoposta a controlli di sicurezza, è nuova o notoriamente instabile. Installala a tuo rischio.", "Update to %s" : "Aggiornato a %s", "Please wait...." : "Attendere...", "Error while disabling app" : "Errore durante la disattivazione", @@ -185,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Ottimizzare il config.php", "Theming" : "Temi", "Hardening and security guidance" : "Guida alla messa in sicurezza", - "Experimental File Lock is enabled." : "Il blocco file sperimentale è abilitato.", - "Experimental File Lock is disabled." : "Il blocco file sperimentale è disabilitato.", + "Transactional File Locking is enabled." : "Il blocco file transazionale è abilitato.", + "Transactional File Locking is disabled." : "Il blocco file transazionale è disabilitato.", "Version" : "Versione", "Developer documentation" : "Documentazione dello sviluppatore", "Experimental applications ahead" : "Prima le applicazioni sperimentali", diff --git a/settings/l10n/it.json b/settings/l10n/it.json index 805e00b8fb2..5cf8d09d4f8 100644 --- a/settings/l10n/it.json +++ b/settings/l10n/it.json @@ -60,6 +60,7 @@ "All" : "Tutti", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Le applicazioni ufficiali sono sviluppate da e con la comunità di ownCloud. Offrono le funzioni fondamentali di ownCloud e sono pronte per l'utilizzo in produzione.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Le applicazioni approvate sono sviluppate da sviluppatori affidabili e hanno passato un rapido controllo di sicurezza. Sono attivamente mantenute in un deposito aperto del codice e i loro responsabili le ritengono pronte sia per un utilizzo casuale che per un utilizzo continuativo.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Questa applicazione non è stata sottoposta a controlli di sicurezza, è nuova o notoriamente instabile. Installala a tuo rischio.", "Update to %s" : "Aggiornato a %s", "Please wait...." : "Attendere...", "Error while disabling app" : "Errore durante la disattivazione", @@ -183,8 +184,8 @@ "Improving the config.php" : "Ottimizzare il config.php", "Theming" : "Temi", "Hardening and security guidance" : "Guida alla messa in sicurezza", - "Experimental File Lock is enabled." : "Il blocco file sperimentale è abilitato.", - "Experimental File Lock is disabled." : "Il blocco file sperimentale è disabilitato.", + "Transactional File Locking is enabled." : "Il blocco file transazionale è abilitato.", + "Transactional File Locking is disabled." : "Il blocco file transazionale è disabilitato.", "Version" : "Versione", "Developer documentation" : "Documentazione dello sviluppatore", "Experimental applications ahead" : "Prima le applicazioni sperimentali", diff --git a/settings/l10n/ja.js b/settings/l10n/ja.js index 58ce3061523..2b4f4d4179b 100644 --- a/settings/l10n/ja.js +++ b/settings/l10n/ja.js @@ -1,6 +1,7 @@ OC.L10N.register( "settings", { + "Redis" : "Redis", "Security & setup warnings" : "セキュリティ&セットアップ警告", "Sharing" : "共有", "Server-side encryption" : "サーバーサイド暗号化", @@ -8,6 +9,7 @@ OC.L10N.register( "Cron" : "Cron", "Email server" : "メールサーバー", "Log" : "ログ", + "Server Status" : "サーバーステータス", "Tips & tricks" : "Tips & tricks", "Updates" : "アップデート", "Authentication error" : "認証エラー", @@ -49,6 +51,7 @@ OC.L10N.register( "Are you really sure you want add \"{domain}\" as trusted domain?" : "\"{domain}\" を信頼するドメインに追加してもよろしいでしょうか?", "Add trusted domain" : "信頼するドメイン名に追加", "Sending..." : "送信中…", + "Experimental" : "実験的", "All" : "すべて", "Update to %s" : "%sにアップデート", "Please wait...." : "しばらくお待ちください...", diff --git a/settings/l10n/ja.json b/settings/l10n/ja.json index 0cdbb741d77..081116b2083 100644 --- a/settings/l10n/ja.json +++ b/settings/l10n/ja.json @@ -1,4 +1,5 @@ { "translations": { + "Redis" : "Redis", "Security & setup warnings" : "セキュリティ&セットアップ警告", "Sharing" : "共有", "Server-side encryption" : "サーバーサイド暗号化", @@ -6,6 +7,7 @@ "Cron" : "Cron", "Email server" : "メールサーバー", "Log" : "ログ", + "Server Status" : "サーバーステータス", "Tips & tricks" : "Tips & tricks", "Updates" : "アップデート", "Authentication error" : "認証エラー", @@ -47,6 +49,7 @@ "Are you really sure you want add \"{domain}\" as trusted domain?" : "\"{domain}\" を信頼するドメインに追加してもよろしいでしょうか?", "Add trusted domain" : "信頼するドメイン名に追加", "Sending..." : "送信中…", + "Experimental" : "実験的", "All" : "すべて", "Update to %s" : "%sにアップデート", "Please wait...." : "しばらくお待ちください...", diff --git a/settings/l10n/nb_NO.js b/settings/l10n/nb_NO.js index 84177b03c37..5dfac59d7f9 100644 --- a/settings/l10n/nb_NO.js +++ b/settings/l10n/nb_NO.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Alle", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Offisielle apper utvikles av og innenfor ownCloud-fellesskapet. De tilbyr funksjonalitet som er sentral for ownCloud og er forberedt for produksjonsbruk.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Godkjente apper er utviklet av pålitelige utviklere og har gjennomgått en rask sikkerhetssjekk. De vedlikeholdes aktivt i et åpent kode-depot og utviklerne anser dem for å være stabile for tilfeldig til normal bruk.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Denne appen er ikke sjekket for sikkerhetsproblemer og er ny eller ansett for å være ustabil. Installer på egen risiko.", "Update to %s" : "Oppdater til %s", "Please wait...." : "Vennligst vent...", "Error while disabling app" : "Deaktivering av app feilet", @@ -185,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Forbedring av config.php", "Theming" : "Temaer", "Hardening and security guidance" : "Herding og sikkerhetsveiledning", - "Experimental File Lock is enabled." : "Eksperimentell fil-låsing er aktivert.", - "Experimental File Lock is disabled." : "Eksperimentell fil-låsing er deaktivert.", + "Transactional File Locking is enabled." : "Transaksjonsbasert fil-låsing er aktivert.", + "Transactional File Locking is disabled." : "Transaksjonsbasert fil-låsing er deaktivert.", "Version" : "Versjon", "Developer documentation" : "Utviklerdokumentasjon", "Experimental applications ahead" : "Eksperimentelle applikasjoner forut", diff --git a/settings/l10n/nb_NO.json b/settings/l10n/nb_NO.json index 27cc0a5ccab..4d12db4d365 100644 --- a/settings/l10n/nb_NO.json +++ b/settings/l10n/nb_NO.json @@ -60,6 +60,7 @@ "All" : "Alle", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Offisielle apper utvikles av og innenfor ownCloud-fellesskapet. De tilbyr funksjonalitet som er sentral for ownCloud og er forberedt for produksjonsbruk.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Godkjente apper er utviklet av pålitelige utviklere og har gjennomgått en rask sikkerhetssjekk. De vedlikeholdes aktivt i et åpent kode-depot og utviklerne anser dem for å være stabile for tilfeldig til normal bruk.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Denne appen er ikke sjekket for sikkerhetsproblemer og er ny eller ansett for å være ustabil. Installer på egen risiko.", "Update to %s" : "Oppdater til %s", "Please wait...." : "Vennligst vent...", "Error while disabling app" : "Deaktivering av app feilet", @@ -183,8 +184,8 @@ "Improving the config.php" : "Forbedring av config.php", "Theming" : "Temaer", "Hardening and security guidance" : "Herding og sikkerhetsveiledning", - "Experimental File Lock is enabled." : "Eksperimentell fil-låsing er aktivert.", - "Experimental File Lock is disabled." : "Eksperimentell fil-låsing er deaktivert.", + "Transactional File Locking is enabled." : "Transaksjonsbasert fil-låsing er aktivert.", + "Transactional File Locking is disabled." : "Transaksjonsbasert fil-låsing er deaktivert.", "Version" : "Versjon", "Developer documentation" : "Utviklerdokumentasjon", "Experimental applications ahead" : "Eksperimentelle applikasjoner forut", diff --git a/settings/l10n/nl.js b/settings/l10n/nl.js index ab539acea35..f8f883c1f59 100644 --- a/settings/l10n/nl.js +++ b/settings/l10n/nl.js @@ -186,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "config.php verbeteren", "Theming" : "Thema's", "Hardening and security guidance" : "Hardening en security advies", - "Experimental File Lock is enabled." : "Experimentele bestandsblokkade is geactiveerd", - "Experimental File Lock is disabled." : "Experimentele bestandsblokkade is gedeactiveerd", + "Transactional File Locking is enabled." : "Transactionele File Locking is ingeschakeld.", + "Transactional File Locking is disabled." : "Transactionele File Locking is uitgeschakeld.", "Version" : "Versie", "Developer documentation" : "Ontwikkelaarsdocumentatie", "Experimental applications ahead" : "Experimentele applicaties vooraan", diff --git a/settings/l10n/nl.json b/settings/l10n/nl.json index 4e2274892dd..403f4a2b075 100644 --- a/settings/l10n/nl.json +++ b/settings/l10n/nl.json @@ -184,8 +184,8 @@ "Improving the config.php" : "config.php verbeteren", "Theming" : "Thema's", "Hardening and security guidance" : "Hardening en security advies", - "Experimental File Lock is enabled." : "Experimentele bestandsblokkade is geactiveerd", - "Experimental File Lock is disabled." : "Experimentele bestandsblokkade is gedeactiveerd", + "Transactional File Locking is enabled." : "Transactionele File Locking is ingeschakeld.", + "Transactional File Locking is disabled." : "Transactionele File Locking is uitgeschakeld.", "Version" : "Versie", "Developer documentation" : "Ontwikkelaarsdocumentatie", "Experimental applications ahead" : "Experimentele applicaties vooraan", diff --git a/settings/l10n/pt_BR.js b/settings/l10n/pt_BR.js index 7431234e882..631922f4af0 100644 --- a/settings/l10n/pt_BR.js +++ b/settings/l10n/pt_BR.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Todos", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Aplicativos oficiais são desenvolvidos por e dentro da comunidade ownCloud. Eles oferecem funcionalidade central para ownCloud e estão prontos para uso em produção.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Aplicativos aprovados são desenvolvidos pelos desenvolvedores confiáveis e passaram por uma verificação de segurança superficial. Eles são ativamente mantidos em um repositório de código aberto e seus mantenedores consideram que eles para sejam estáveis para um casual uso normal.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Este aplicativo não foi verificado para as questões de segurança e é novo ou conhecido por ser instável. Instale por seu próprio risco.", "Update to %s" : "Atualizado para %s", "Please wait...." : "Por favor, aguarde...", "Error while disabling app" : "Erro enquanto desabilitava o aplicativo", @@ -185,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "Melhorando o config.php", "Theming" : "Elaborar um tema", "Hardening and security guidance" : "Orientações de proteção e segurança", - "Experimental File Lock is enabled." : "Bloqueio de Arquivo Experimental está habilitado.", - "Experimental File Lock is disabled." : "Bloqueio de Arquivo Experimental está desativado.", + "Transactional File Locking is enabled." : "Bloqueio de Arquivo Transacional está habilitado.", + "Transactional File Locking is disabled." : "Bloqueio de Arquivo Transacional está desabilitado.", "Version" : "Versão", "Developer documentation" : "Documentação do desenvolvedor", "Experimental applications ahead" : "Aplicações experimentais à frente", diff --git a/settings/l10n/pt_BR.json b/settings/l10n/pt_BR.json index 99a69b87c51..b4af20ead58 100644 --- a/settings/l10n/pt_BR.json +++ b/settings/l10n/pt_BR.json @@ -60,6 +60,7 @@ "All" : "Todos", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Aplicativos oficiais são desenvolvidos por e dentro da comunidade ownCloud. Eles oferecem funcionalidade central para ownCloud e estão prontos para uso em produção.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Aplicativos aprovados são desenvolvidos pelos desenvolvedores confiáveis e passaram por uma verificação de segurança superficial. Eles são ativamente mantidos em um repositório de código aberto e seus mantenedores consideram que eles para sejam estáveis para um casual uso normal.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Este aplicativo não foi verificado para as questões de segurança e é novo ou conhecido por ser instável. Instale por seu próprio risco.", "Update to %s" : "Atualizado para %s", "Please wait...." : "Por favor, aguarde...", "Error while disabling app" : "Erro enquanto desabilitava o aplicativo", @@ -183,8 +184,8 @@ "Improving the config.php" : "Melhorando o config.php", "Theming" : "Elaborar um tema", "Hardening and security guidance" : "Orientações de proteção e segurança", - "Experimental File Lock is enabled." : "Bloqueio de Arquivo Experimental está habilitado.", - "Experimental File Lock is disabled." : "Bloqueio de Arquivo Experimental está desativado.", + "Transactional File Locking is enabled." : "Bloqueio de Arquivo Transacional está habilitado.", + "Transactional File Locking is disabled." : "Bloqueio de Arquivo Transacional está desabilitado.", "Version" : "Versão", "Developer documentation" : "Documentação do desenvolvedor", "Experimental applications ahead" : "Aplicações experimentais à frente", diff --git a/settings/l10n/ru.js b/settings/l10n/ru.js index 9e2e2c0f9a5..f4f66292018 100644 --- a/settings/l10n/ru.js +++ b/settings/l10n/ru.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "Все", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Официальные приложения разработаны силами сообщества ownCloud. Они полностью функциональны и готовы к работе.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Подтвержденные приложения разработаны доверенными разработчиками и прошли краткую проверку на наличие проблем с безопасностью. Они активно поддерживаются в открытых репозиториях и сопровождающие их разработчики подтверждают, что приложения достаточно стабильны для нормальной работы.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Это приложение не проверялось на наличие проблем с безопасностью, также оно может работать нестабильно. Устанавливайте на свой страх и риск.", "Update to %s" : "Обновить до %s", "Please wait...." : "Пожалуйста подождите...", "Error while disabling app" : "Ошибка при отключении приложения", @@ -185,12 +186,12 @@ OC.L10N.register( "Improving the config.php" : "Улучшение config.php", "Theming" : "Темы оформления", "Hardening and security guidance" : "Руководство по безопасности и защите", - "Experimental File Lock is enabled." : "Экспериментальная блокировка файлов включена.", - "Experimental File Lock is disabled." : "Экспериментальная блокировка файлов отключена.", + "Transactional File Locking is enabled." : "Транзакционная блокировка файлов включена.", + "Transactional File Locking is disabled." : "Транзакционная блокировка файлов отключена.", "Version" : "Версия", "Developer documentation" : "Документация для разработчиков", "Experimental applications ahead" : "Экспериментальные приложения", - "Experimental apps are not checked for security issues, new or known to be unstable and under heavy development. Installing them can cause data loss or security breaches." : "Экспериментальные приложения не проверялись на наличие уязвимостей безопасности, так-же могут быть не стабильны, т.к. находятся в активной разработке. Их установка может повлечь потерю информации или нарушение безопасности.", + "Experimental apps are not checked for security issues, new or known to be unstable and under heavy development. Installing them can cause data loss or security breaches." : "Экспериментальные приложения не проверялись на наличие уязвимостей безопасности, они также могут быть нестабильны, т.к. находятся в активной разработке. Их установка может повлечь потерю информации или нарушение безопасности.", "by" : "автор", "licensed" : "Лицензировано", "Documentation:" : "Документация:", diff --git a/settings/l10n/ru.json b/settings/l10n/ru.json index 52e4eb8bfa5..61740f80abc 100644 --- a/settings/l10n/ru.json +++ b/settings/l10n/ru.json @@ -60,6 +60,7 @@ "All" : "Все", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Официальные приложения разработаны силами сообщества ownCloud. Они полностью функциональны и готовы к работе.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Подтвержденные приложения разработаны доверенными разработчиками и прошли краткую проверку на наличие проблем с безопасностью. Они активно поддерживаются в открытых репозиториях и сопровождающие их разработчики подтверждают, что приложения достаточно стабильны для нормальной работы.", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "Это приложение не проверялось на наличие проблем с безопасностью, также оно может работать нестабильно. Устанавливайте на свой страх и риск.", "Update to %s" : "Обновить до %s", "Please wait...." : "Пожалуйста подождите...", "Error while disabling app" : "Ошибка при отключении приложения", @@ -183,12 +184,12 @@ "Improving the config.php" : "Улучшение config.php", "Theming" : "Темы оформления", "Hardening and security guidance" : "Руководство по безопасности и защите", - "Experimental File Lock is enabled." : "Экспериментальная блокировка файлов включена.", - "Experimental File Lock is disabled." : "Экспериментальная блокировка файлов отключена.", + "Transactional File Locking is enabled." : "Транзакционная блокировка файлов включена.", + "Transactional File Locking is disabled." : "Транзакционная блокировка файлов отключена.", "Version" : "Версия", "Developer documentation" : "Документация для разработчиков", "Experimental applications ahead" : "Экспериментальные приложения", - "Experimental apps are not checked for security issues, new or known to be unstable and under heavy development. Installing them can cause data loss or security breaches." : "Экспериментальные приложения не проверялись на наличие уязвимостей безопасности, так-же могут быть не стабильны, т.к. находятся в активной разработке. Их установка может повлечь потерю информации или нарушение безопасности.", + "Experimental apps are not checked for security issues, new or known to be unstable and under heavy development. Installing them can cause data loss or security breaches." : "Экспериментальные приложения не проверялись на наличие уязвимостей безопасности, они также могут быть нестабильны, т.к. находятся в активной разработке. Их установка может повлечь потерю информации или нарушение безопасности.", "by" : "автор", "licensed" : "Лицензировано", "Documentation:" : "Документация:", diff --git a/settings/l10n/sr.js b/settings/l10n/sr.js index fa0c2e670ff..9c0b9412d20 100644 --- a/settings/l10n/sr.js +++ b/settings/l10n/sr.js @@ -185,8 +185,6 @@ OC.L10N.register( "Improving the config.php" : "Побољшање фајла поставки", "Theming" : "Теме", "Hardening and security guidance" : "Ојачавање система и безбедносне препоруке", - "Experimental File Lock is enabled." : "Експериментални катанац фајла је укључен.", - "Experimental File Lock is disabled." : "Експериментални катанац фајла је искључен.", "Version" : "Верзија", "Developer documentation" : "Програмерска документација", "Experimental applications ahead" : "Експериментална апликација", diff --git a/settings/l10n/sr.json b/settings/l10n/sr.json index b06019a061f..bfd2356d925 100644 --- a/settings/l10n/sr.json +++ b/settings/l10n/sr.json @@ -183,8 +183,6 @@ "Improving the config.php" : "Побољшање фајла поставки", "Theming" : "Теме", "Hardening and security guidance" : "Ојачавање система и безбедносне препоруке", - "Experimental File Lock is enabled." : "Експериментални катанац фајла је укључен.", - "Experimental File Lock is disabled." : "Експериментални катанац фајла је искључен.", "Version" : "Верзија", "Developer documentation" : "Програмерска документација", "Experimental applications ahead" : "Експериментална апликација", diff --git a/settings/l10n/th_TH.js b/settings/l10n/th_TH.js index 754b88dc2c7..5b8d92c0e12 100644 --- a/settings/l10n/th_TH.js +++ b/settings/l10n/th_TH.js @@ -62,6 +62,7 @@ OC.L10N.register( "All" : "ทั้งหมด", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "แอพพลิเคชันมีการพัฒนาอย่างเป็นทางการภายในชุมชน ownCloud พวกเขามีการทำงานเป็นศูนย์กลางของ ownCloud และพร้อมสำหรับการใช้งานผลิตภัณฑ์", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "แอพพลิเคชันได้รับการอนุมัติและพัฒนาโดยนักพัฒนาที่น่าเชื่อถือและได้ผ่านการตรวจสอบความปลอดภัยคร่าวๆ พวกเขาจะได้รับการบำรุงรักษาอย่างดีในการเก็บข้อมูลรหัสเปิด มันอาจยังไม่เสถียรพอสำหรับการเปิดใช้งานปกติ", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "แอพฯ นี้ไม่ได้ตรวจสอบปัญหาด้านความปลอดภัยและเป็นแอพฯใหม่หรือที่รู้จักกันคือจะไม่เสถียร ติดตั้งบนความเสี่ยงของคุณเอง", "Update to %s" : "อัพเดทไปยัง %s", "Please wait...." : "กรุณารอสักครู่...", "Error while disabling app" : "เกิดข้อผิดพลาดขณะปิดการใช้งานแอพพลิเคชัน", @@ -185,8 +186,8 @@ OC.L10N.register( "Improving the config.php" : "ปรับปรุงไฟล์ config.php", "Theming" : "ชุดรูปแบบ", "Hardening and security guidance" : "คำแนะนำการรักษาความปลอดภัย", - "Experimental File Lock is enabled." : "ทดลองล็อคไฟล์ถูกเปิดใช้งาน", - "Experimental File Lock is disabled." : "ทดลองล็อคไฟล์ถูกปิดใช้งาน", + "Transactional File Locking is enabled." : "เปิดใช้งานล็อคไฟล์ขณะทำธุรกรรม", + "Transactional File Locking is disabled." : "ปิดใช้งานล็อคไฟล์ขณะทำธุรกรรม", "Version" : "รุ่น", "Developer documentation" : "เอกสารสำหรับนักพัฒนา", "Experimental applications ahead" : "การใช้งานก่อนการทดลอง", diff --git a/settings/l10n/th_TH.json b/settings/l10n/th_TH.json index 5f5928134bb..18acdb2a9a0 100644 --- a/settings/l10n/th_TH.json +++ b/settings/l10n/th_TH.json @@ -60,6 +60,7 @@ "All" : "ทั้งหมด", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "แอพพลิเคชันมีการพัฒนาอย่างเป็นทางการภายในชุมชน ownCloud พวกเขามีการทำงานเป็นศูนย์กลางของ ownCloud และพร้อมสำหรับการใช้งานผลิตภัณฑ์", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "แอพพลิเคชันได้รับการอนุมัติและพัฒนาโดยนักพัฒนาที่น่าเชื่อถือและได้ผ่านการตรวจสอบความปลอดภัยคร่าวๆ พวกเขาจะได้รับการบำรุงรักษาอย่างดีในการเก็บข้อมูลรหัสเปิด มันอาจยังไม่เสถียรพอสำหรับการเปิดใช้งานปกติ", + "This app is not checked for security issues and is new or known to be unstable. Install at your own risk." : "แอพฯ นี้ไม่ได้ตรวจสอบปัญหาด้านความปลอดภัยและเป็นแอพฯใหม่หรือที่รู้จักกันคือจะไม่เสถียร ติดตั้งบนความเสี่ยงของคุณเอง", "Update to %s" : "อัพเดทไปยัง %s", "Please wait...." : "กรุณารอสักครู่...", "Error while disabling app" : "เกิดข้อผิดพลาดขณะปิดการใช้งานแอพพลิเคชัน", @@ -183,8 +184,8 @@ "Improving the config.php" : "ปรับปรุงไฟล์ config.php", "Theming" : "ชุดรูปแบบ", "Hardening and security guidance" : "คำแนะนำการรักษาความปลอดภัย", - "Experimental File Lock is enabled." : "ทดลองล็อคไฟล์ถูกเปิดใช้งาน", - "Experimental File Lock is disabled." : "ทดลองล็อคไฟล์ถูกปิดใช้งาน", + "Transactional File Locking is enabled." : "เปิดใช้งานล็อคไฟล์ขณะทำธุรกรรม", + "Transactional File Locking is disabled." : "ปิดใช้งานล็อคไฟล์ขณะทำธุรกรรม", "Version" : "รุ่น", "Developer documentation" : "เอกสารสำหรับนักพัฒนา", "Experimental applications ahead" : "การใช้งานก่อนการทดลอง", diff --git a/settings/l10n/tr.js b/settings/l10n/tr.js index 47a6aacab13..d66540f7a17 100644 --- a/settings/l10n/tr.js +++ b/settings/l10n/tr.js @@ -185,8 +185,6 @@ OC.L10N.register( "Improving the config.php" : "config.php iyileştirme", "Theming" : "Tema", "Hardening and security guidance" : "Sağlamlaştırma ve güvenlik rehberliği", - "Experimental File Lock is enabled." : "Deneysel Dosya Kilidi etkin.", - "Experimental File Lock is disabled." : "Deneysel Dosya Kilidi devre dışı.", "Version" : "Sürüm", "Developer documentation" : "Geliştirici belgelendirmesi", "Experimental applications ahead" : "İlerideki deneysel uygulamalar", diff --git a/settings/l10n/tr.json b/settings/l10n/tr.json index 94b16491d42..54452acbf77 100644 --- a/settings/l10n/tr.json +++ b/settings/l10n/tr.json @@ -183,8 +183,6 @@ "Improving the config.php" : "config.php iyileştirme", "Theming" : "Tema", "Hardening and security guidance" : "Sağlamlaştırma ve güvenlik rehberliği", - "Experimental File Lock is enabled." : "Deneysel Dosya Kilidi etkin.", - "Experimental File Lock is disabled." : "Deneysel Dosya Kilidi devre dışı.", "Version" : "Sürüm", "Developer documentation" : "Geliştirici belgelendirmesi", "Experimental applications ahead" : "İlerideki deneysel uygulamalar", diff --git a/settings/l10n/uk.js b/settings/l10n/uk.js index 6c816bb02f0..5fd3562c4f5 100644 --- a/settings/l10n/uk.js +++ b/settings/l10n/uk.js @@ -1,6 +1,7 @@ OC.L10N.register( "settings", { + "Redis" : "Redis", "Security & setup warnings" : "Попередження безпеки та налаштування", "Sharing" : "Спільний доступ", "Server-side encryption" : "Серверне шіфрування", @@ -53,6 +54,8 @@ OC.L10N.register( "Migration in progress. Please wait until the migration is finished" : "Міграція триває. Будь ласка, зачекайте доки процес міграції завершиться", "Migration started …" : "Міграцію розпочато ...", "Sending..." : "Надсилання...", + "Official" : "Офіційні", + "Experimental" : "Експериментальні", "All" : "Всі", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Офіційні застосунки розроблені спільнотою ownCloud. Вони реалізують основні можливості ownCloud і готові до використання в продакшні.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Схвалені застосунки розроблені довіреними розробниками і пройшли незалежну перевірку безпеки. Їх активно супроводжують у репозиторії з відкритим кодом, а їх розробники стежать, щоб вони були стабільні й прийнятні для повсякденного використання.", diff --git a/settings/l10n/uk.json b/settings/l10n/uk.json index 11d7b4db6dd..ff06368269c 100644 --- a/settings/l10n/uk.json +++ b/settings/l10n/uk.json @@ -1,4 +1,5 @@ { "translations": { + "Redis" : "Redis", "Security & setup warnings" : "Попередження безпеки та налаштування", "Sharing" : "Спільний доступ", "Server-side encryption" : "Серверне шіфрування", @@ -51,6 +52,8 @@ "Migration in progress. Please wait until the migration is finished" : "Міграція триває. Будь ласка, зачекайте доки процес міграції завершиться", "Migration started …" : "Міграцію розпочато ...", "Sending..." : "Надсилання...", + "Official" : "Офіційні", + "Experimental" : "Експериментальні", "All" : "Всі", "Official apps are developed by and within the ownCloud community. They offer functionality central to ownCloud and are ready for production use." : "Офіційні застосунки розроблені спільнотою ownCloud. Вони реалізують основні можливості ownCloud і готові до використання в продакшні.", "Approved apps are developed by trusted developers and have passed a cursory security check. They are actively maintained in an open code repository and their maintainers deem them to be stable for casual to normal use." : "Схвалені застосунки розроблені довіреними розробниками і пройшли незалежну перевірку безпеки. Їх активно супроводжують у репозиторії з відкритим кодом, а їх розробники стежать, щоб вони були стабільні й прийнятні для повсякденного використання.", diff --git a/settings/l10n/zh_CN.js b/settings/l10n/zh_CN.js index c2234b882da..9c4f07d8463 100644 --- a/settings/l10n/zh_CN.js +++ b/settings/l10n/zh_CN.js @@ -2,9 +2,13 @@ OC.L10N.register( "settings", { "Sharing" : "共享", + "Server-side encryption" : "服务器端加密", "External Storage" : "外部存储", "Cron" : "计划任务", + "Email server" : "电子邮件服务器", "Log" : "日志", + "Server Status" : "服务器状态", + "Tips & tricks" : "技巧提示", "Updates" : "更新", "Authentication error" : "认证错误", "Your full name has been changed." : "您的全名已修改。", @@ -22,6 +26,8 @@ OC.L10N.register( "Wrong admin recovery password. Please check the password and try again." : "错误的管理员恢复密码。请检查密码并重试。", "Unable to change password" : "不能更改密码", "Enabled" : "开启", + "Not enabled" : "未启用", + "Migration Completed" : "迁移完成", "Saved" : "已保存", "test email settings" : "测试电子邮件设置", "Email sent" : "邮件已发送", @@ -31,6 +37,7 @@ OC.L10N.register( "Add trusted domain" : "添加信任域", "Sending..." : "正在发送...", "All" : "全部", + "Update to %s" : "更新为 %s", "Please wait...." : "请稍等....", "Error while disabling app" : "禁用 app 时出错", "Disable" : "禁用", @@ -63,7 +70,9 @@ OC.L10N.register( "Error creating user" : "创建用户出错", "A valid password must be provided" : "必须提供合法的密码", "__language_name__" : "简体中文", - "SSL root certificates" : "SSL根证书", + "Sync clients" : "同步客户端", + "Personal info" : "个人信息", + "SSL root certificates" : "SSL 根证书", "Everything (fatal issues, errors, warnings, info, debug)" : "所有(灾难性问题,错误,警告,信息,调试)", "Info, warnings, errors and fatal issues" : "信息,警告,错误和灾难性问题", "Warnings, errors and fatal issues" : "警告,错误和灾难性问题", @@ -80,6 +89,7 @@ OC.L10N.register( "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "PHP模块'文件信息'丢失. 我们强烈建议启用此模块以便mime类型检测取得最佳结果.", "System locale can not be set to a one which supports UTF-8." : "系统语系无法设置为支持 UTF-8 的语系。", "This means that there might be problems with certain characters in file names." : "这意味着一些文件名中的特定字符可能有问题。", + "Open documentation" : "打开文档", "Allow apps to use the Share API" : "允许应用软件使用共享API", "Allow users to share via link" : "允许用户通过链接分享文件", "Enforce password protection" : "强制密码保护", @@ -97,6 +107,8 @@ OC.L10N.register( "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 已注册于一个 webcron 服务来通过 http 每 15 分钟执行 cron.php。", "Use system's cron service to call the cron.php file every 15 minutes." : "使用系统 CRON 服务每 15 分钟执行一次 cron.php 文件。", + "Enable server-side encryption" : "启用服务器端加密", + "Enable encryption" : "启用加密", "This is used for sending out notifications." : "这被用于发送通知。", "Send mode" : "发送模式", "Encryption" : "加密", @@ -115,6 +127,10 @@ OC.L10N.register( "More" : "更多", "Less" : "更少", "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "特别当使用桌面客户端来同步文件时,不鼓励使用 SQLite 。", + "Advanced monitoring" : "高级监控", + "Performance tuning" : "性能优化", + "Improving the config.php" : "正在优化 config.php", + "Theming" : "主题", "Version" : "版本", "by" : "被", "Documentation:" : "文档:", @@ -123,8 +139,14 @@ OC.L10N.register( "Enable only for specific groups" : "仅对特定的组开放", "Uninstall App" : "卸载应用", "Cheers!" : "干杯!", + "User documentation" : "用户文档", + "Administrator documentation" : "管理员文档", + "Online documentation" : "在线文档", "Forum" : "论坛", "Get the apps to sync your files" : "安装应用进行文件同步", + "Desktop client" : "桌面客户端", + "Android app" : "Android 应用", + "iOS app" : "iOS 应用", "Show First Run Wizard again" : "再次显示首次运行向导", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "你已使用 <strong>%s</strong>,有效空间 <strong>%s</strong>", "Password" : "密码", @@ -149,12 +171,14 @@ OC.L10N.register( "Valid until" : "有效期至", "Issued By" : "授权由", "Valid until %s" : "有效期至 %s", + "Developed by the {communityopen}ownCloud community{linkclose}, the {githubopen}source code{linkclose} is licensed under the {licenseopen}<abbr title=\"Affero General Public License\">AGPL</abbr>{linkclose}." : "由 {communityopen}ownCloud 社区{linkclose}开发,{githubopen}源代码{linkclose}在 {licenseopen}<abbr title=\"Affero General Public License\">AGPL</abbr> 许可证{linkclose}下发布。", "Show storage location" : "显示存储位置", "Show last log in" : "显示最后登录", "Username" : "用户名", "Create" : "创建", "Admin Recovery Password" : "管理恢复密码", "Enter the recovery password in order to recover the users files during password change" : "输入恢复密码来在更改密码的时候恢复用户文件", + "Search Users" : "搜索用户", "Add Group" : "增加组", "Group" : "分组", "Everyone" : "所有人", @@ -166,9 +190,11 @@ OC.L10N.register( "Full Name" : "全名", "Quota" : "配额", "Storage Location" : "存储空间位置", + "User Backend" : "用户后端", "Last Login" : "最后登录", "change full name" : "更改全名", "set new password" : "设置新密码", + "change email address" : "修改电子邮箱地址", "Default" : "默认" }, "nplurals=1; plural=0;"); diff --git a/settings/l10n/zh_CN.json b/settings/l10n/zh_CN.json index 15517f26720..195385e6aab 100644 --- a/settings/l10n/zh_CN.json +++ b/settings/l10n/zh_CN.json @@ -1,8 +1,12 @@ { "translations": { "Sharing" : "共享", + "Server-side encryption" : "服务器端加密", "External Storage" : "外部存储", "Cron" : "计划任务", + "Email server" : "电子邮件服务器", "Log" : "日志", + "Server Status" : "服务器状态", + "Tips & tricks" : "技巧提示", "Updates" : "更新", "Authentication error" : "认证错误", "Your full name has been changed." : "您的全名已修改。", @@ -20,6 +24,8 @@ "Wrong admin recovery password. Please check the password and try again." : "错误的管理员恢复密码。请检查密码并重试。", "Unable to change password" : "不能更改密码", "Enabled" : "开启", + "Not enabled" : "未启用", + "Migration Completed" : "迁移完成", "Saved" : "已保存", "test email settings" : "测试电子邮件设置", "Email sent" : "邮件已发送", @@ -29,6 +35,7 @@ "Add trusted domain" : "添加信任域", "Sending..." : "正在发送...", "All" : "全部", + "Update to %s" : "更新为 %s", "Please wait...." : "请稍等....", "Error while disabling app" : "禁用 app 时出错", "Disable" : "禁用", @@ -61,7 +68,9 @@ "Error creating user" : "创建用户出错", "A valid password must be provided" : "必须提供合法的密码", "__language_name__" : "简体中文", - "SSL root certificates" : "SSL根证书", + "Sync clients" : "同步客户端", + "Personal info" : "个人信息", + "SSL root certificates" : "SSL 根证书", "Everything (fatal issues, errors, warnings, info, debug)" : "所有(灾难性问题,错误,警告,信息,调试)", "Info, warnings, errors and fatal issues" : "信息,警告,错误和灾难性问题", "Warnings, errors and fatal issues" : "警告,错误和灾难性问题", @@ -78,6 +87,7 @@ "The PHP module 'fileinfo' is missing. We strongly recommend to enable this module to get best results with mime-type detection." : "PHP模块'文件信息'丢失. 我们强烈建议启用此模块以便mime类型检测取得最佳结果.", "System locale can not be set to a one which supports UTF-8." : "系统语系无法设置为支持 UTF-8 的语系。", "This means that there might be problems with certain characters in file names." : "这意味着一些文件名中的特定字符可能有问题。", + "Open documentation" : "打开文档", "Allow apps to use the Share API" : "允许应用软件使用共享API", "Allow users to share via link" : "允许用户通过链接分享文件", "Enforce password protection" : "强制密码保护", @@ -95,6 +105,8 @@ "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 已注册于一个 webcron 服务来通过 http 每 15 分钟执行 cron.php。", "Use system's cron service to call the cron.php file every 15 minutes." : "使用系统 CRON 服务每 15 分钟执行一次 cron.php 文件。", + "Enable server-side encryption" : "启用服务器端加密", + "Enable encryption" : "启用加密", "This is used for sending out notifications." : "这被用于发送通知。", "Send mode" : "发送模式", "Encryption" : "加密", @@ -113,6 +125,10 @@ "More" : "更多", "Less" : "更少", "Especially when using the desktop client for file syncing the use of SQLite is discouraged." : "特别当使用桌面客户端来同步文件时,不鼓励使用 SQLite 。", + "Advanced monitoring" : "高级监控", + "Performance tuning" : "性能优化", + "Improving the config.php" : "正在优化 config.php", + "Theming" : "主题", "Version" : "版本", "by" : "被", "Documentation:" : "文档:", @@ -121,8 +137,14 @@ "Enable only for specific groups" : "仅对特定的组开放", "Uninstall App" : "卸载应用", "Cheers!" : "干杯!", + "User documentation" : "用户文档", + "Administrator documentation" : "管理员文档", + "Online documentation" : "在线文档", "Forum" : "论坛", "Get the apps to sync your files" : "安装应用进行文件同步", + "Desktop client" : "桌面客户端", + "Android app" : "Android 应用", + "iOS app" : "iOS 应用", "Show First Run Wizard again" : "再次显示首次运行向导", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "你已使用 <strong>%s</strong>,有效空间 <strong>%s</strong>", "Password" : "密码", @@ -147,12 +169,14 @@ "Valid until" : "有效期至", "Issued By" : "授权由", "Valid until %s" : "有效期至 %s", + "Developed by the {communityopen}ownCloud community{linkclose}, the {githubopen}source code{linkclose} is licensed under the {licenseopen}<abbr title=\"Affero General Public License\">AGPL</abbr>{linkclose}." : "由 {communityopen}ownCloud 社区{linkclose}开发,{githubopen}源代码{linkclose}在 {licenseopen}<abbr title=\"Affero General Public License\">AGPL</abbr> 许可证{linkclose}下发布。", "Show storage location" : "显示存储位置", "Show last log in" : "显示最后登录", "Username" : "用户名", "Create" : "创建", "Admin Recovery Password" : "管理恢复密码", "Enter the recovery password in order to recover the users files during password change" : "输入恢复密码来在更改密码的时候恢复用户文件", + "Search Users" : "搜索用户", "Add Group" : "增加组", "Group" : "分组", "Everyone" : "所有人", @@ -164,9 +188,11 @@ "Full Name" : "全名", "Quota" : "配额", "Storage Location" : "存储空间位置", + "User Backend" : "用户后端", "Last Login" : "最后登录", "change full name" : "更改全名", "set new password" : "设置新密码", + "change email address" : "修改电子邮箱地址", "Default" : "默认" },"pluralForm" :"nplurals=1; plural=0;" }
\ No newline at end of file diff --git a/settings/personal.php b/settings/personal.php index 7bf1110c03e..f4409e633cf 100644 --- a/settings/personal.php +++ b/settings/personal.php @@ -8,6 +8,7 @@ * @author Georg Ehrke <georg@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> * @author Jan-Christoph Borchardt <hey@jancborchardt.net> + * @author Lukas Reschke <lukas@owncloud.com> * @author Marvin Thomas Rabe <mrabe@marvinrabe.de> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/settings/routes.php b/settings/routes.php index 52b320cbdb5..10c3117c183 100644 --- a/settings/routes.php +++ b/settings/routes.php @@ -9,9 +9,7 @@ * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Raghu Nayyar <me@iraghu.com> - * @author Robin Appelman <icewind@owncloud.com> * @author Thomas Müller <thomas.mueller@tmit.eu> - * @author Vincent Petry <pvince81@owncloud.com> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 diff --git a/settings/templates/admin.php b/settings/templates/admin.php index fb6ef9b3e77..a55071bdf84 100644 --- a/settings/templates/admin.php +++ b/settings/templates/admin.php @@ -533,9 +533,9 @@ if ($_['cronErrors']) { <ul> <li> <?php if ($_['fileLockingEnabled']) { - p($l->t('Experimental File Lock is enabled.')); + p($l->t('Transactional File Locking is enabled.')); } else { - p($l->t('Experimental File Lock is disabled.')); + p($l->t('Transactional File Locking is disabled.')); } ?> </li> </ul> diff --git a/settings/users.php b/settings/users.php index c438e5fbfd0..3d7f39aa367 100644 --- a/settings/users.php +++ b/settings/users.php @@ -7,6 +7,7 @@ * @author Daniel Molkentin <daniel@molkentin.de> * @author Georg Ehrke <georg@owncloud.com> * @author Jakob Sack <mail@jakobsack.de> + * @author Joas Schilling <nickvergessen@owncloud.com> * @author Lukas Reschke <lukas@owncloud.com> * @author Morris Jobke <hey@morrisjobke.de> * @author Robin Appelman <icewind@owncloud.com> diff --git a/tests/files/file_put_contents.txt b/tests/files/file_put_contents.txt new file mode 100644 index 00000000000..e69de29bb2d --- /dev/null +++ b/tests/files/file_put_contents.txt diff --git a/tests/lib/app.php b/tests/lib/app.php index 3f380f74fd2..485091cee4c 100644 --- a/tests/lib/app.php +++ b/tests/lib/app.php @@ -503,9 +503,17 @@ class Test_App extends \Test\TestCase { ['description' => "This is a multiline test with some new lines"] ], [ + ['description' => hex2bin('5065726d657420646520732761757468656e7469666965722064616e732070697769676f20646972656374656d656e74206176656320736573206964656e74696669616e7473206f776e636c6f75642073616e73206c65732072657461706572206574206d657420c3a0206a6f757273206365757820636920656e20636173206465206368616e67656d656e74206465206d6f742064652070617373652e0d0a0d')], + ['description' => "Permet de s'authentifier dans piwigo directement avec ses identifiants owncloud sans les retaper et met à jours ceux ci en cas de changement de mot de passe."] + ], + [ ['not-a-description' => " \t This is a multiline \n test with \n \t some new lines "], ['not-a-description' => " \t This is a multiline \n test with \n \t some new lines "] ], + [ + ['description' => [100, 'bla']], + ['description' => ""] + ], ]; } @@ -513,9 +521,11 @@ class Test_App extends \Test\TestCase { * Test app info parser * * @dataProvider appDataProvider + * @param array $data + * @param array $expected */ - public function testParseAppInfo($data, $expected) { - $this->assertEquals($expected, \OC_App::parseAppInfo($data)); + public function testParseAppInfo(array $data, array $expected) { + $this->assertSame($expected, \OC_App::parseAppInfo($data)); } } diff --git a/tests/lib/appframework/http/RequestTest.php b/tests/lib/appframework/http/RequestTest.php index a4bf3519bfc..de3430d757c 100644 --- a/tests/lib/appframework/http/RequestTest.php +++ b/tests/lib/appframework/http/RequestTest.php @@ -773,7 +773,23 @@ class RequestTest extends \Test\TestCase { $this->assertEquals('from.forwarded.host2:8080', $request->getInsecureServerHost()); } - public function testGetServerHost() { + public function testGetServerHostWithOverwriteHost() { + $this->config + ->expects($this->at(0)) + ->method('getSystemValue') + ->with('overwritehost') + ->will($this->returnValue('my.overwritten.host')); + $this->config + ->expects($this->at(1)) + ->method('getSystemValue') + ->with('overwritecondaddr') + ->will($this->returnValue('')); + $this->config + ->expects($this->at(2)) + ->method('getSystemValue') + ->with('overwritehost') + ->will($this->returnValue('my.overwritten.host')); + $request = new Request( [], $this->secureRandom, @@ -781,7 +797,80 @@ class RequestTest extends \Test\TestCase { $this->stream ); - $this->assertEquals('localhost', $request->getServerHost()); + $this->assertEquals('my.overwritten.host', $request->getServerHost()); + } + + public function testGetServerHostWithTrustedDomain() { + $this->config + ->expects($this->at(3)) + ->method('getSystemValue') + ->with('trusted_domains') + ->will($this->returnValue(['my.trusted.host'])); + + $request = new Request( + [ + 'server' => [ + 'HTTP_X_FORWARDED_HOST' => 'my.trusted.host', + ], + ], + $this->secureRandom, + $this->config, + $this->stream + ); + + $this->assertEquals('my.trusted.host', $request->getServerHost()); + } + + public function testGetServerHostWithUntrustedDomain() { + $this->config + ->expects($this->at(3)) + ->method('getSystemValue') + ->with('trusted_domains') + ->will($this->returnValue(['my.trusted.host'])); + $this->config + ->expects($this->at(4)) + ->method('getSystemValue') + ->with('trusted_domains') + ->will($this->returnValue(['my.trusted.host'])); + + $request = new Request( + [ + 'server' => [ + 'HTTP_X_FORWARDED_HOST' => 'my.untrusted.host', + ], + ], + $this->secureRandom, + $this->config, + $this->stream + ); + + $this->assertEquals('my.trusted.host', $request->getServerHost()); + } + + public function testGetServerHostWithNoTrustedDomain() { + $this->config + ->expects($this->at(3)) + ->method('getSystemValue') + ->with('trusted_domains') + ->will($this->returnValue([])); + $this->config + ->expects($this->at(4)) + ->method('getSystemValue') + ->with('trusted_domains') + ->will($this->returnValue([])); + + $request = new Request( + [ + 'server' => [ + 'HTTP_X_FORWARDED_HOST' => 'my.untrusted.host', + ], + ], + $this->secureRandom, + $this->config, + $this->stream + ); + + $this->assertEquals('', $request->getServerHost()); } public function testGetOverwriteHostDefaultNull() { diff --git a/tests/lib/cache/file.php b/tests/lib/cache/file.php index e31f84ee6f1..94001291d86 100644 --- a/tests/lib/cache/file.php +++ b/tests/lib/cache/file.php @@ -23,12 +23,22 @@ namespace Test\Cache; class FileCache extends \Test_Cache { - /** @var string */ + /** + * @var string + * */ private $user; - /** @var string */ + /** + * @var string + * */ private $datadir; - /** @var \OC\Files\Storage\Storage */ + /** + * @var \OC\Files\Storage\Storage + * */ private $storage; + /** + * @var \OC\Files\View + * */ + private $rootView; function skip() { //$this->skipUnless(OC_User::isLoggedIn()); @@ -59,13 +69,18 @@ class FileCache extends \Test_Cache { \OC_User::setUserId('test'); //set up the users dir - $rootView = new \OC\Files\View(''); - $rootView->mkdir('/test'); + $this->rootView = new \OC\Files\View(''); + $this->rootView->mkdir('/test'); $this->instance=new \OC\Cache\File(); + + // forces creation of cache folder for subsequent tests + $this->instance->set('hack', 'hack'); } protected function tearDown() { + $this->instance->remove('hack', 'hack'); + \OC_User::setUserId($this->user); \OC_Config::setValue('cachedirectory', $this->datadir); @@ -75,4 +90,73 @@ class FileCache extends \Test_Cache { parent::tearDown(); } + + private function setupMockStorage() { + $mockStorage = $this->getMock( + '\OC\Files\Storage\Local', + ['filemtime', 'unlink'], + [['datadir' => \OC::$server->getTempManager()->getTemporaryFolder()]] + ); + + \OC\Files\Filesystem::mount($mockStorage, array(), '/test/cache'); + + return $mockStorage; + } + + public function testGarbageCollectOldKeys() { + $mockStorage = $this->setupMockStorage(); + + $mockStorage->expects($this->atLeastOnce()) + ->method('filemtime') + ->will($this->returnValue(100)); + $mockStorage->expects($this->once()) + ->method('unlink') + ->with('key1') + ->will($this->returnValue(true)); + + $this->instance->set('key1', 'value1'); + $this->instance->gc(); + } + + public function testGarbageCollectLeaveRecentKeys() { + $mockStorage = $this->setupMockStorage(); + + $mockStorage->expects($this->atLeastOnce()) + ->method('filemtime') + ->will($this->returnValue(time() + 3600)); + $mockStorage->expects($this->never()) + ->method('unlink') + ->with('key1'); + $this->instance->set('key1', 'value1'); + $this->instance->gc(); + } + + public function lockExceptionProvider() { + return [ + [new \OCP\Lock\LockedException('key1')], + [new \OCP\Files\LockNotAcquiredException('key1', 1)], + ]; + } + + /** + * @dataProvider lockExceptionProvider + */ + public function testGarbageCollectIgnoreLockedKeys($testException) { + $mockStorage = $this->setupMockStorage(); + + $mockStorage->expects($this->atLeastOnce()) + ->method('filemtime') + ->will($this->returnValue(100)); + $mockStorage->expects($this->atLeastOnce()) + ->method('unlink') + ->will($this->onConsecutiveCalls( + $this->throwException($testException), + $this->returnValue(true) + )); + + $this->instance->set('key1', 'value1'); + $this->instance->set('key2', 'value2'); + + $this->instance->gc(); + } } diff --git a/tests/lib/connector/sabre/MaintenancePluginTest.php b/tests/lib/connector/sabre/MaintenancePluginTest.php new file mode 100644 index 00000000000..e5b50f71de6 --- /dev/null +++ b/tests/lib/connector/sabre/MaintenancePluginTest.php @@ -0,0 +1,73 @@ +<?php +/** + * @author Thomas Müller <thomas.mueller@tmit.eu> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace Test\Connector\Sabre; + +use OC\Connector\Sabre\MaintenancePlugin; +use Test\TestCase; +use OCP\IConfig; + +/** + * Class MaintenancePluginTest + * + * @package Test\Connector\Sabre + */ +class MaintenancePluginTest extends TestCase { + /** @var IConfig */ + private $config; + /** @var MaintenancePlugin */ + private $maintenancePlugin; + + public function setUp() { + parent::setUp(); + + $this->config = $this->getMock('\OCP\IConfig'); + $this->maintenancePlugin = new MaintenancePlugin($this->config); + } + + /** + * @expectedException \Sabre\DAV\Exception\ServiceUnavailable + * @expectedExceptionMessage System in single user mode. + */ + public function testSingleUserMode() { + $this->config + ->expects($this->once()) + ->method('getSystemValue') + ->with('singleuser', false) + ->will($this->returnValue(true)); + + $this->maintenancePlugin->checkMaintenanceMode(); + } + + /** + * @expectedException \Sabre\DAV\Exception\ServiceUnavailable + * @expectedExceptionMessage System in single user mode. + */ + public function testMaintenanceMode() { + $this->config + ->expects($this->exactly(1)) + ->method('getSystemValue') + ->will($this->onConsecutiveCalls([false, true])); + + $this->maintenancePlugin->checkMaintenanceMode(); + } + +} diff --git a/tests/lib/connector/sabre/file.php b/tests/lib/connector/sabre/file.php index 834698d90cb..246f7f6d0a2 100644 --- a/tests/lib/connector/sabre/file.php +++ b/tests/lib/connector/sabre/file.php @@ -10,6 +10,7 @@ namespace Test\Connector\Sabre; use Test\HookHelper; use OC\Files\Filesystem; +use OCP\Lock\ILockingProvider; class File extends \Test\TestCase { @@ -33,6 +34,7 @@ class File extends \Test\TestCase { public function tearDown() { $userManager = \OC::$server->getUserManager(); $userManager->get($this->user)->delete(); + unset($_SERVER['HTTP_OC_CHUNKED']); parent::tearDown(); } @@ -44,23 +46,92 @@ class File extends \Test\TestCase { return $stream; } + + public function fopenFailuresProvider() { + return [ + [ + // return false + null, + '\Sabre\Dav\Exception', + false + ], + [ + new \OCP\Files\NotPermittedException(), + 'Sabre\DAV\Exception\Forbidden' + ], + [ + new \OCP\Files\EntityTooLargeException(), + 'OC\Connector\Sabre\Exception\EntityTooLarge' + ], + [ + new \OCP\Files\InvalidContentException(), + 'OC\Connector\Sabre\Exception\UnsupportedMediaType' + ], + [ + new \OCP\Files\InvalidPathException(), + 'Sabre\DAV\Exception\Forbidden' + ], + [ + new \OCP\Files\LockNotAcquiredException('/test.txt', 1), + 'OC\Connector\Sabre\Exception\FileLocked' + ], + [ + new \OCP\Lock\LockedException('/test.txt'), + 'OC\Connector\Sabre\Exception\FileLocked' + ], + [ + new \OCP\Encryption\Exceptions\GenericEncryptionException(), + 'Sabre\DAV\Exception\ServiceUnavailable' + ], + [ + new \OCP\Files\StorageNotAvailableException(), + 'Sabre\DAV\Exception\ServiceUnavailable' + ], + [ + new \Sabre\DAV\Exception('Generic sabre exception'), + 'Sabre\DAV\Exception', + false + ], + [ + new \Exception('Generic exception'), + 'Sabre\DAV\Exception' + ], + ]; + } + /** - * @expectedException \Sabre\DAV\Exception + * @dataProvider fopenFailuresProvider */ - public function testSimplePutFails() { + public function testSimplePutFails($thrownException, $expectedException, $checkPreviousClass = true) { // setup - $storage = $this->getMock('\OC\Files\Storage\Local', ['fopen'], [['datadir' => \OC::$server->getTempManager()->getTemporaryFolder()]]); + $storage = $this->getMock( + '\OC\Files\Storage\Local', + ['fopen'], + [['datadir' => \OC::$server->getTempManager()->getTemporaryFolder()]] + ); + \OC\Files\Filesystem::mount($storage, [], $this->user . '/'); $view = $this->getMock('\OC\Files\View', array('getRelativePath', 'resolvePath'), array()); - $view->expects($this->any()) + $view->expects($this->atLeastOnce()) ->method('resolvePath') - ->will($this->returnValue(array($storage, ''))); - $storage->expects($this->once()) - ->method('fopen') - ->will($this->returnValue(false)); + ->will($this->returnCallback( + function($path) use ($storage){ + return [$storage, $path]; + } + )); + + if ($thrownException !== null) { + $storage->expects($this->once()) + ->method('fopen') + ->will($this->throwException($thrownException)); + } else { + $storage->expects($this->once()) + ->method('fopen') + ->will($this->returnValue(false)); + } $view->expects($this->any()) ->method('getRelativePath') - ->will($this->returnValue('/test.txt')); + ->will($this->returnArgument(0)); $info = new \OC\Files\FileInfo('/test.txt', null, null, array( 'permissions' => \OCP\Constants::PERMISSION_ALL @@ -69,9 +140,97 @@ class File extends \Test\TestCase { $file = new \OC\Connector\Sabre\File($view, $info); // action - $file->put('test data'); + $caughtException = null; + try { + $file->put('test data'); + } catch (\Exception $e) { + $caughtException = $e; + } + + $this->assertInstanceOf($expectedException, $caughtException); + if ($checkPreviousClass) { + $this->assertInstanceOf(get_class($thrownException), $caughtException->getPrevious()); + } + + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); } + /** + * Test putting a file using chunking + * + * @dataProvider fopenFailuresProvider + */ + public function testChunkedPutFails($thrownException, $expectedException, $checkPreviousClass = false) { + // setup + $storage = $this->getMock( + '\OC\Files\Storage\Local', + ['fopen'], + [['datadir' => \OC::$server->getTempManager()->getTemporaryFolder()]] + ); + \OC\Files\Filesystem::mount($storage, [], $this->user . '/'); + $view = $this->getMock('\OC\Files\View', ['getRelativePath', 'resolvePath'], []); + $view->expects($this->atLeastOnce()) + ->method('resolvePath') + ->will($this->returnCallback( + function($path) use ($storage){ + return [$storage, $path]; + } + )); + + if ($thrownException !== null) { + $storage->expects($this->once()) + ->method('fopen') + ->will($this->throwException($thrownException)); + } else { + $storage->expects($this->once()) + ->method('fopen') + ->will($this->returnValue(false)); + } + + $view->expects($this->any()) + ->method('getRelativePath') + ->will($this->returnArgument(0)); + + $_SERVER['HTTP_OC_CHUNKED'] = true; + + $info = new \OC\Files\FileInfo('/test.txt-chunking-12345-2-0', null, null, [ + 'permissions' => \OCP\Constants::PERMISSION_ALL + ], null); + $file = new \OC\Connector\Sabre\File($view, $info); + + // put first chunk + $this->assertNull($file->put('test data one')); + + $info = new \OC\Files\FileInfo('/test.txt-chunking-12345-2-1', null, null, [ + 'permissions' => \OCP\Constants::PERMISSION_ALL + ], null); + $file = new \OC\Connector\Sabre\File($view, $info); + + // action + $caughtException = null; + try { + // last chunk + $file->put('test data two'); + } catch (\Exception $e) { + $caughtException = $e; + } + + $this->assertInstanceOf($expectedException, $caughtException); + if ($checkPreviousClass) { + $this->assertInstanceOf(get_class($thrownException), $caughtException->getPrevious()); + } + + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); + } + + /** + * Simulate putting a file to the given path. + * + * @param string $path path to put the file into + * @param string $viewRoot root to use for the view + * + * @return result of the PUT operaiton which is usually the etag + */ private function doPut($path, $viewRoot = null) { $view = \OC\Files\Filesystem::getView(); if (!is_null($viewRoot)) { @@ -90,14 +249,23 @@ class File extends \Test\TestCase { $file = new \OC\Connector\Sabre\File($view, $info); - $this->assertNotEmpty($file->put($this->getStream('test data'))); + return $file->put($this->getStream('test data')); } /** * Test putting a single file */ public function testPutSingleFile() { - $this->doPut('/foo.txt'); + $this->assertNotEmpty($this->doPut('/foo.txt')); + } + + /** + * Test putting a file using chunking + */ + public function testChunkedPut() { + $_SERVER['HTTP_OC_CHUNKED'] = true; + $this->assertNull($this->doPut('/test.txt-chunking-12345-2-0')); + $this->assertNotEmpty($this->doPut('/test.txt-chunking-12345-2-1')); } /** @@ -106,7 +274,7 @@ class File extends \Test\TestCase { public function testPutSingleFileTriggersHooks() { HookHelper::setUpHooks(); - $this->doPut('/foo.txt'); + $this->assertNotEmpty($this->doPut('/foo.txt')); $this->assertCount(4, HookHelper::$hookCalls); $this->assertHookCall( @@ -140,7 +308,7 @@ class File extends \Test\TestCase { HookHelper::setUpHooks(); - $this->doPut('/foo.txt'); + $this->assertNotEmpty($this->doPut('/foo.txt')); $this->assertCount(4, HookHelper::$hookCalls); $this->assertHookCall( @@ -177,7 +345,7 @@ class File extends \Test\TestCase { HookHelper::setUpHooks(); // happens with public webdav where the view root is the share root - $this->doPut('/foo.txt', '/' . $this->user . '/files/noderoot'); + $this->assertNotEmpty($this->doPut('/foo.txt', '/' . $this->user . '/files/noderoot')); $this->assertCount(4, HookHelper::$hookCalls); $this->assertHookCall( @@ -211,8 +379,6 @@ class File extends \Test\TestCase { /** * Test put file with cancelled hook - * - * @expectedException \Sabre\DAV\Exception */ public function testPutSingleFileCancelPreHook() { \OCP\Util::connectHook( @@ -222,13 +388,22 @@ class File extends \Test\TestCase { 'cancellingCallback' ); - $this->doPut('/foo.txt'); + // action + $thrown = false; + try { + $this->doPut('/foo.txt'); + } catch (\Sabre\DAV\Exception $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles(), 'No stray part files'); } /** - * @expectedException \Sabre\DAV\Exception + * Test exception when the uploaded size did not match */ - public function testSimplePutFailsOnRename() { + public function testSimplePutFailsSizeCheck() { // setup $view = $this->getMock('\OC\Files\View', array('rename', 'getRelativePath', 'filesize')); @@ -238,7 +413,8 @@ class File extends \Test\TestCase { ->will($this->returnValue(false)); $view->expects($this->any()) ->method('getRelativePath') - ->will($this->returnValue('/test.txt')); + ->will($this->returnArgument(0)); + $view->expects($this->any()) ->method('filesize') ->will($this->returnValue(123456)); @@ -253,18 +429,87 @@ class File extends \Test\TestCase { $file = new \OC\Connector\Sabre\File($view, $info); // action - $file->put($this->getStream('test data')); + $thrown = false; + try { + $file->put($this->getStream('test data')); + } catch (\Sabre\DAV\Exception\BadRequest $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); } /** - * @expectedException \OC\Connector\Sabre\Exception\InvalidPath + * Test exception during final rename in simple upload mode + */ + public function testSimplePutFailsMoveFromStorage() { + $view = new \OC\Files\View('/' . $this->user . '/files'); + + // simulate situation where the target file is locked + $view->lockFile('/test.txt', ILockingProvider::LOCK_EXCLUSIVE); + + $info = new \OC\Files\FileInfo('/' . $this->user . '/files/test.txt', null, null, array( + 'permissions' => \OCP\Constants::PERMISSION_ALL + ), null); + + $file = new \OC\Connector\Sabre\File($view, $info); + + // action + $thrown = false; + try { + $file->put($this->getStream('test data')); + } catch (\OC\Connector\Sabre\Exception\FileLocked $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); + } + + /** + * Test exception during final rename in chunk upload mode + */ + public function testChunkedPutFailsFinalRename() { + $view = new \OC\Files\View('/' . $this->user . '/files'); + + // simulate situation where the target file is locked + $view->lockFile('/test.txt', ILockingProvider::LOCK_EXCLUSIVE); + + $_SERVER['HTTP_OC_CHUNKED'] = true; + + $info = new \OC\Files\FileInfo('/' . $this->user . '/files/test.txt-chunking-12345-2-0', null, null, [ + 'permissions' => \OCP\Constants::PERMISSION_ALL + ], null); + $file = new \OC\Connector\Sabre\File($view, $info); + $this->assertNull($file->put('test data one')); + + $info = new \OC\Files\FileInfo('/' . $this->user . '/files/test.txt-chunking-12345-2-1', null, null, [ + 'permissions' => \OCP\Constants::PERMISSION_ALL + ], null); + $file = new \OC\Connector\Sabre\File($view, $info); + + // action + $thrown = false; + try { + $file->put($this->getStream('test data')); + } catch (\OC\Connector\Sabre\Exception\FileLocked $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); + } + + /** + * Test put file with invalid chars */ public function testSimplePutInvalidChars() { // setup $view = $this->getMock('\OC\Files\View', array('getRelativePath')); $view->expects($this->any()) ->method('getRelativePath') - ->will($this->returnValue('/*')); + ->will($this->returnArgument(0)); $info = new \OC\Files\FileInfo('/*', null, null, array( 'permissions' => \OCP\Constants::PERMISSION_ALL @@ -272,7 +517,15 @@ class File extends \Test\TestCase { $file = new \OC\Connector\Sabre\File($view, $info); // action - $file->put($this->getStream('test data')); + $thrown = false; + try { + $file->put($this->getStream('test data')); + } catch (\OC\Connector\Sabre\Exception\InvalidPath $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); } /** @@ -286,7 +539,7 @@ class File extends \Test\TestCase { $view->expects($this->any()) ->method('getRelativePath') - ->will($this->returnValue('/*')); + ->will($this->returnArgument(0)); $info = new \OC\Files\FileInfo('/*', null, null, array( 'permissions' => \OCP\Constants::PERMISSION_ALL @@ -296,7 +549,6 @@ class File extends \Test\TestCase { } /** - * @expectedException \Sabre\DAV\Exception\BadRequest */ public function testUploadAbort() { // setup @@ -308,7 +560,7 @@ class File extends \Test\TestCase { ->will($this->returnValue(false)); $view->expects($this->any()) ->method('getRelativePath') - ->will($this->returnValue('/test.txt')); + ->will($this->returnArgument(0)); $view->expects($this->any()) ->method('filesize') ->will($this->returnValue(123456)); @@ -323,7 +575,15 @@ class File extends \Test\TestCase { $file = new \OC\Connector\Sabre\File($view, $info); // action - $file->put($this->getStream('test data')); + $thrown = false; + try { + $file->put($this->getStream('test data')); + } catch (\Sabre\DAV\Exception\BadRequest $e) { + $thrown = true; + } + + $this->assertTrue($thrown); + $this->assertEmpty($this->listPartFiles($view, ''), 'No stray part files'); } /** @@ -484,4 +744,29 @@ class File extends \Test\TestCase { ); } + /** + * Returns part files in the given path + * + * @param \OC\Files\View view which root is the current user's "files" folder + * @param string $path path for which to list part files + * + * @return array list of part files + */ + private function listPartFiles(\OC\Files\View $userView = null, $path = '') { + if ($userView === null) { + $userView = \OC\Files\Filesystem::getView(); + } + $files = []; + list($storage, $internalPath) = $userView->resolvePath($path); + $realPath = $storage->getSourcePath($internalPath); + $dh = opendir($realPath); + while (($file = readdir($dh)) !== false) { + if (substr($file, strlen($file) - 5, 5) === '.part') { + $files[] = $file; + } + } + closedir($dh); + return $files; + } + } diff --git a/tests/lib/files/storage/wrapper/encryption.php b/tests/lib/files/storage/wrapper/encryption.php index 175713de497..a10e95a3f8b 100644 --- a/tests/lib/files/storage/wrapper/encryption.php +++ b/tests/lib/files/storage/wrapper/encryption.php @@ -381,10 +381,12 @@ class Encryption extends \Test\Files\Storage\Storage { /** * @dataProvider dataTestGetHeader - * @param $path - * @param $strippedPath + * + * @param string $path + * @param bool $strippedPathExists + * @param string $strippedPath */ - public function testGetHeader($path, $strippedPath) { + public function testGetHeader($path, $strippedPathExists, $strippedPath) { $sourceStorage = $this->getMockBuilder('\OC\Files\Storage\Storage') ->disableOriginalConstructor()->getMock(); @@ -409,17 +411,25 @@ class Encryption extends \Test\Files\Storage\Storage { $util->expects($this->once())->method('stripPartialFileExtension') ->with($path)->willReturn($strippedPath); - $sourceStorage->expects($this->once())->method('file_exists') - ->with($strippedPath)->willReturn(false); + $sourceStorage->expects($this->at(0)) + ->method('file_exists') + ->with($strippedPath) + ->willReturn($strippedPathExists); + $sourceStorage->expects($this->at(1)) + ->method('file_exists') + ->with($strippedPathExists ? $strippedPath : $path) + ->willReturn(false); $this->invokePrivate($instance, 'getHeader', [$path]); } public function dataTestGetHeader() { return array( - array('/foo/bar.txt', '/foo/bar.txt'), - array('/foo/bar.txt.part', '/foo/bar.txt'), - array('/foo/bar.txt.ocTransferId7437493.part', '/foo/bar.txt'), + array('/foo/bar.txt', false, '/foo/bar.txt'), + array('/foo/bar.txt.part', false, '/foo/bar.txt'), + array('/foo/bar.txt.ocTransferId7437493.part', false, '/foo/bar.txt'), + array('/foo/bar.txt.part', true, '/foo/bar.txt'), + array('/foo/bar.txt.ocTransferId7437493.part', true, '/foo/bar.txt'), ); } } diff --git a/tests/lib/files/utils/scanner.php b/tests/lib/files/utils/scanner.php index dfc683c1bcf..ca64b1db72e 100644 --- a/tests/lib/files/utils/scanner.php +++ b/tests/lib/files/utils/scanner.php @@ -11,6 +11,8 @@ namespace Test\Files\Utils; use OC\Files\Filesystem; use OC\Files\Mount\MountPoint; use OC\Files\Storage\Temporary; +use OCP\Files\Storage\IStorageFactory; +use OCP\IUser; class TestScanner extends \OC\Files\Utils\Scanner { /** @@ -39,14 +41,22 @@ class TestScanner extends \OC\Files\Utils\Scanner { } class Scanner extends \Test\TestCase { + /** + * @var \OC_User_Dummy + */ + private $userBackend; + protected function setUp() { parent::setUp(); + $this->userBackend = new \OC_User_Dummy(); + \OC::$server->getUserManager()->registerBackend($this->userBackend); $this->loginAsUser(); } protected function tearDown() { $this->logout(); + \OC::$server->getUserManager()->removeBackend($this->userBackend); parent::tearDown(); } @@ -94,6 +104,39 @@ class Scanner extends \Test\TestCase { $this->assertEquals($old, $new); } + public function testScanSubMount() { + $uid = $this->getUniqueID(); + $this->userBackend->createUser($uid, 'test'); + + $mountProvider = $this->getMock('\OCP\Files\Config\IMountProvider'); + + $storage = new Temporary(array()); + $mount = new MountPoint($storage, '/' . $uid . '/files/foo'); + + $mountProvider->expects($this->any()) + ->method('getMountsForUser') + ->will($this->returnCallback(function (IUser $user, IStorageFactory $storageFactory) use ($mount, $uid) { + if ($user->getUID() === $uid) { + return [$mount]; + } else { + return []; + } + })); + + \OC::$server->getMountProviderCollection()->registerProvider($mountProvider); + $cache = $storage->getCache(); + + $storage->mkdir('folder'); + $storage->file_put_contents('foo.txt', 'qwerty'); + $storage->file_put_contents('folder/bar.txt', 'qwerty'); + + $scanner = new \OC\Files\Utils\Scanner($uid, \OC::$server->getDatabaseConnection()); + + $this->assertFalse($cache->inCache('folder/bar.txt')); + $scanner->scan('/' . $uid . '/files/foo'); + $this->assertTrue($cache->inCache('folder/bar.txt')); + } + public function testChangePropagator() { /** * @var \OC\Files\Cache\ChangePropagator $propagator diff --git a/tests/lib/files/view.php b/tests/lib/files/view.php index 42768a0b274..382c033f19c 100644 --- a/tests/lib/files/view.php +++ b/tests/lib/files/view.php @@ -51,15 +51,16 @@ class View extends \Test\TestCase { protected function setUp() { parent::setUp(); + \OC_Hook::clear(); \OC_User::clearBackends(); \OC_User::useBackend(new \OC_User_Dummy()); //login \OC_User::createUser('test', 'test'); - $this->user = \OC_User::getUser(); $this->loginAsUser('test'); + $this->user = \OC_User::getUser(); // clear mounts but somehow keep the root storage // that was initialized above... \OC\Files\Filesystem::clearMounts(); @@ -1350,4 +1351,658 @@ class View extends \Test\TestCase { $defaultRootValue->setValue($oldRoot); $this->assertEquals($shouldEmit, $result); } + + + public function basicOperationProviderForLocks() { + return [ + // --- write hook ---- + [ + 'touch', + ['touch-create.txt'], + 'touch-create.txt', + 'create', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + ILockingProvider::LOCK_SHARED, + ], + [ + 'fopen', + ['test-write.txt', 'w'], + 'test-write.txt', + 'write', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + null, + // exclusive lock stays until fclose + ILockingProvider::LOCK_EXCLUSIVE, + ], + [ + 'mkdir', + ['newdir'], + 'newdir', + 'write', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + ILockingProvider::LOCK_SHARED, + ], + [ + 'file_put_contents', + ['file_put_contents.txt', 'blah'], + 'file_put_contents.txt', + 'write', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + ILockingProvider::LOCK_SHARED, + ], + + // ---- delete hook ---- + [ + 'rmdir', + ['dir'], + 'dir', + 'delete', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + ILockingProvider::LOCK_SHARED, + ], + [ + 'unlink', + ['test.txt'], + 'test.txt', + 'delete', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_EXCLUSIVE, + ILockingProvider::LOCK_SHARED, + ], + + // ---- read hook (no post hooks) ---- + [ + 'file_get_contents', + ['test.txt'], + 'test.txt', + 'read', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_SHARED, + null, + ], + [ + 'fopen', + ['test.txt', 'r'], + 'test.txt', + 'read', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_SHARED, + null, + ], + [ + 'opendir', + ['dir'], + 'dir', + 'read', + ILockingProvider::LOCK_SHARED, + ILockingProvider::LOCK_SHARED, + null, + ], + + // ---- no lock, touch hook --- + ['touch', ['test.txt'], 'test.txt', 'touch', null, null, null], + + // ---- no hooks, no locks --- + ['is_dir', ['dir'], 'dir', null], + ['is_file', ['dir'], 'dir', null], + ['stat', ['dir'], 'dir', null], + ['filetype', ['dir'], 'dir', null], + ['filesize', ['dir'], 'dir', null], + ['isCreatable', ['dir'], 'dir', null], + ['isReadable', ['dir'], 'dir', null], + ['isUpdatable', ['dir'], 'dir', null], + ['isDeletable', ['dir'], 'dir', null], + ['isSharable', ['dir'], 'dir', null], + ['file_exists', ['dir'], 'dir', null], + ['filemtime', ['dir'], 'dir', null], + ]; + } + + /** + * Test whether locks are set before and after the operation + * + * @dataProvider basicOperationProviderForLocks + * + * @param string $operation operation name on the view + * @param array $operationArgs arguments for the operation + * @param string $lockedPath path of the locked item to check + * @param string $hookType hook type + * @param int $expectedLockBefore expected lock during pre hooks + * @param int $expectedLockduring expected lock during operation + * @param int $expectedLockAfter expected lock during post hooks + * @param int $expectedStrayLock expected lock after returning, should + * be null (unlock) for most operations + */ + public function testLockBasicOperation( + $operation, + $operationArgs, + $lockedPath, + $hookType, + $expectedLockBefore = ILockingProvider::LOCK_SHARED, + $expectedLockDuring = ILockingProvider::LOCK_SHARED, + $expectedLockAfter = ILockingProvider::LOCK_SHARED, + $expectedStrayLock = null + ) { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$operation]) + ->getMock(); + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + + // work directly on disk because mkdir might be mocked + $realPath = $storage->getSourcePath(''); + mkdir($realPath . '/files'); + mkdir($realPath . '/files/dir'); + file_put_contents($realPath . '/files/test.txt', 'blah'); + $storage->getScanner()->scan('files'); + + $storage->expects($this->once()) + ->method($operation) + ->will($this->returnCallback( + function() use ($view, $lockedPath, &$lockTypeDuring){ + $lockTypeDuring = $this->getFileLockType($view, $lockedPath); + + return true; + } + )); + + $this->assertNull($this->getFileLockType($view, $lockedPath), 'File not locked before operation'); + + $this->connectMockHooks($hookType, $view, $lockedPath, $lockTypePre, $lockTypePost); + + // do operation + call_user_func_array(array($view, $operation), $operationArgs); + + if ($hookType !== null) { + $this->assertEquals($expectedLockBefore, $lockTypePre, 'File locked properly during pre-hook'); + $this->assertEquals($expectedLockAfter, $lockTypePost, 'File locked properly during post-hook'); + $this->assertEquals($expectedLockDuring, $lockTypeDuring, 'File locked properly during operation'); + } else { + $this->assertNull($lockTypeDuring, 'File not locked during operation'); + } + + $this->assertEquals($expectedStrayLock, $this->getFileLockType($view, $lockedPath)); + } + + /** + * Test locks for file_put_content with stream. + * This code path uses $storage->fopen instead + */ + public function testLockFilePutContentWithStream() { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $path = 'test_file_put_contents.txt'; + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods(['fopen']) + ->getMock(); + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + $storage->mkdir('files'); + + $storage->expects($this->once()) + ->method('fopen') + ->will($this->returnCallback( + function() use ($view, $path, &$lockTypeDuring){ + $lockTypeDuring = $this->getFileLockType($view, $path); + + return fopen('php://temp', 'r+'); + } + )); + + $this->connectMockHooks('write', $view, $path, $lockTypePre, $lockTypePost); + + $this->assertNull($this->getFileLockType($view, $path), 'File not locked before operation'); + + // do operation + $view->file_put_contents($path, fopen('php://temp', 'r+')); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypePre, 'File locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypePost, 'File locked properly during post-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeDuring, 'File locked properly during operation'); + + $this->assertNull($this->getFileLockType($view, $path)); + } + + /** + * Test locks for fopen with fclose at the end + */ + public function testLockFopen() { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $path = 'test_file_put_contents.txt'; + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods(['fopen']) + ->getMock(); + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + $storage->mkdir('files'); + + $storage->expects($this->once()) + ->method('fopen') + ->will($this->returnCallback( + function() use ($view, $path, &$lockTypeDuring){ + $lockTypeDuring = $this->getFileLockType($view, $path); + + return fopen('php://temp', 'r+'); + } + )); + + $this->connectMockHooks('write', $view, $path, $lockTypePre, $lockTypePost); + + $this->assertNull($this->getFileLockType($view, $path), 'File not locked before operation'); + + // do operation + $res = $view->fopen($path, 'w'); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypePre, 'File locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeDuring, 'File locked properly during operation'); + $this->assertNull(null, $lockTypePost, 'No post hook, no lock check possible'); + + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeDuring, 'File still locked after fopen'); + + fclose($res); + + $this->assertNull($this->getFileLockType($view, $path), 'File unlocked after fclose'); + } + + /** + * Test locks for fopen with fclose at the end + * + * @dataProvider basicOperationProviderForLocks + * + * @param string $operation operation name on the view + * @param array $operationArgs arguments for the operation + * @param string $path path of the locked item to check + */ + public function testLockBasicOperationUnlocksAfterException( + $operation, + $operationArgs, + $path + ) { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$operation]) + ->getMock(); + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + + // work directly on disk because mkdir might be mocked + $realPath = $storage->getSourcePath(''); + mkdir($realPath . '/files'); + mkdir($realPath . '/files/dir'); + file_put_contents($realPath . '/files/test.txt', 'blah'); + $storage->getScanner()->scan('files'); + + $storage->expects($this->once()) + ->method($operation) + ->will($this->returnCallback( + function() { + throw new \Exception('Simulated exception'); + } + )); + + $thrown = false; + try { + call_user_func_array(array($view, $operation), $operationArgs); + } catch (\Exception $e) { + $thrown = true; + $this->assertEquals('Simulated exception', $e->getMessage()); + } + $this->assertTrue($thrown, 'Exception was rethrown'); + $this->assertNull($this->getFileLockType($view, $path), 'File got unlocked after exception'); + } + + /** + * Test locks for fopen with fclose at the end + * + * @dataProvider basicOperationProviderForLocks + * + * @param string $operation operation name on the view + * @param array $operationArgs arguments for the operation + * @param string $path path of the locked item to check + * @param string $hookType hook type + */ + public function testLockBasicOperationUnlocksAfterCancelledHook( + $operation, + $operationArgs, + $path, + $hookType + ) { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$operation]) + ->getMock(); + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + $storage->mkdir('files'); + + \OCP\Util::connectHook( + \OC\Files\Filesystem::CLASSNAME, + $hookType, + '\Test\HookHelper', + 'cancellingCallback' + ); + + call_user_func_array(array($view, $operation), $operationArgs); + + $this->assertNull($this->getFileLockType($view, $path), 'File got unlocked after exception'); + } + + public function lockFileRenameOrCopyDataProvider() { + return [ + ['rename', ILockingProvider::LOCK_EXCLUSIVE], + ['copy', ILockingProvider::LOCK_SHARED], + ]; + } + + /** + * Test locks for rename or copy operation + * + * @dataProvider lockFileRenameOrCopyDataProvider + * + * @param string $operation operation to be done on the view + * @param int $expectedLockTypeSourceDuring expected lock type on source file during + * the operation + */ + public function testLockFileRename($operation, $expectedLockTypeSourceDuring) { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$operation]) + ->getMock(); + + $sourcePath = 'original.txt'; + $targetPath = 'target.txt'; + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + $storage->mkdir('files'); + $view->file_put_contents($sourcePath, 'meh'); + + $storage->expects($this->once()) + ->method($operation) + ->will($this->returnCallback( + function() use ($view, $sourcePath, $targetPath, &$lockTypeSourceDuring, &$lockTypeTargetDuring){ + $lockTypeSourceDuring = $this->getFileLockType($view, $sourcePath); + $lockTypeTargetDuring = $this->getFileLockType($view, $targetPath); + + return true; + } + )); + + $this->connectMockHooks($operation, $view, $sourcePath, $lockTypeSourcePre, $lockTypeSourcePost); + $this->connectMockHooks($operation, $view, $targetPath, $lockTypeTargetPre, $lockTypeTargetPost); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked before operation'); + $this->assertNull($this->getFileLockType($view, $targetPath), 'Target file not locked before operation'); + + $view->$operation($sourcePath, $targetPath); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePre, 'Source file locked properly during pre-hook'); + $this->assertEquals($expectedLockTypeSourceDuring, $lockTypeSourceDuring, 'Source file locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePost, 'Source file locked properly during post-hook'); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPre, 'Target file locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeTargetDuring, 'Target file locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPost, 'Target file locked properly during post-hook'); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked after operation'); + $this->assertNull($this->getFileLockType($view, $targetPath), 'Target file not locked after operation'); + } + + /** + * Test rename operation: unlock first path when second path was locked + */ + public function testLockFileRenameUnlockOnException() { + $this->loginAsUser('test'); + + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $sourcePath = 'original.txt'; + $targetPath = 'target.txt'; + $view->file_put_contents($sourcePath, 'meh'); + + // simulate that the target path is already locked + $view->lockFile($targetPath, ILockingProvider::LOCK_EXCLUSIVE); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked before operation'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $this->getFileLockType($view, $targetPath), 'Target file is locked before operation'); + + $thrown = false; + try { + $view->rename($sourcePath, $targetPath); + } catch (\OCP\Lock\LockedException $e) { + $thrown = true; + } + + $this->assertTrue($thrown, 'LockedException thrown'); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked after operation'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $this->getFileLockType($view, $targetPath), 'Target file still locked after operation'); + + $view->unlockFile($targetPath, ILockingProvider::LOCK_EXCLUSIVE); + } + + public function lockFileRenameOrCopyCrossStorageDataProvider() { + return [ + ['rename', 'moveFromStorage', ILockingProvider::LOCK_EXCLUSIVE], + ['copy', 'copyFromStorage', ILockingProvider::LOCK_SHARED], + ]; + } + + /** + * Test locks for rename or copy operation cross-storage + * + * @dataProvider lockFileRenameOrCopyCrossStorageDataProvider + * + * @param string $viewOperation operation to be done on the view + * @param string $storageOperation operation to be mocked on the storage + * @param int $expectedLockTypeSourceDuring expected lock type on source file during + * the operation + */ + public function testLockFileRenameCrossStorage($viewOperation, $storageOperation, $expectedLockTypeSourceDuring) { + $view = new \OC\Files\View('/' . $this->user . '/files/'); + + $storage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$storageOperation]) + ->getMock(); + $storage2 = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([$storageOperation]) + ->getMock(); + + $sourcePath = 'original.txt'; + $targetPath = 'substorage/target.txt'; + + \OC\Files\Filesystem::mount($storage, array(), $this->user . '/'); + \OC\Files\Filesystem::mount($storage2, array(), $this->user . '/files/substorage'); + $storage->mkdir('files'); + $view->file_put_contents($sourcePath, 'meh'); + + $storage->expects($this->never()) + ->method($storageOperation); + $storage2->expects($this->once()) + ->method($storageOperation) + ->will($this->returnCallback( + function() use ($view, $sourcePath, $targetPath, &$lockTypeSourceDuring, &$lockTypeTargetDuring){ + $lockTypeSourceDuring = $this->getFileLockType($view, $sourcePath); + $lockTypeTargetDuring = $this->getFileLockType($view, $targetPath); + + return true; + } + )); + + $this->connectMockHooks($viewOperation, $view, $sourcePath, $lockTypeSourcePre, $lockTypeSourcePost); + $this->connectMockHooks($viewOperation, $view, $targetPath, $lockTypeTargetPre, $lockTypeTargetPost); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked before operation'); + $this->assertNull($this->getFileLockType($view, $targetPath), 'Target file not locked before operation'); + + $view->$viewOperation($sourcePath, $targetPath); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePre, 'Source file locked properly during pre-hook'); + $this->assertEquals($expectedLockTypeSourceDuring, $lockTypeSourceDuring, 'Source file locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePost, 'Source file locked properly during post-hook'); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPre, 'Target file locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeTargetDuring, 'Target file locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPost, 'Target file locked properly during post-hook'); + + $this->assertNull($this->getFileLockType($view, $sourcePath), 'Source file not locked after operation'); + $this->assertNull($this->getFileLockType($view, $targetPath), 'Target file not locked after operation'); + } + + /** + * Test locks when moving a mount point + */ + public function testLockMoveMountPoint() { + $this->loginAsUser('test'); + + $subStorage = $this->getMockBuilder('\OC\Files\Storage\Temporary') + ->setMethods([]) + ->getMock(); + + $mount = $this->getMock( + '\Test\TestMoveableMountPoint', + ['moveMount'], + [$subStorage, $this->user . '/files/substorage'] + ); + + $mountProvider = $this->getMock('\OCP\Files\Config\IMountProvider'); + $mountProvider->expects($this->once()) + ->method('getMountsForUser') + ->will($this->returnValue([$mount])); + + $mountProviderCollection = \OC::$server->getMountProviderCollection(); + $mountProviderCollection->registerProvider($mountProvider); + + $view = new \OC\Files\View('/' . $this->user . '/files/'); + $view->mkdir('subdir'); + + $sourcePath = 'substorage'; + $targetPath = 'subdir/substorage_moved'; + + $mount->expects($this->once()) + ->method('moveMount') + ->will($this->returnCallback( + function($target) use ($mount, $view, $sourcePath, $targetPath, &$lockTypeSourceDuring, &$lockTypeTargetDuring, &$lockTypeSharedRootDuring){ + $lockTypeSourceDuring = $this->getFileLockType($view, $sourcePath, true); + $lockTypeTargetDuring = $this->getFileLockType($view, $targetPath, true); + + $lockTypeSharedRootDuring = $this->getFileLockType($view, $sourcePath, false); + + $mount->setMountPoint($target); + + return true; + } + )); + + $this->connectMockHooks('rename', $view, $sourcePath, $lockTypeSourcePre, $lockTypeSourcePost, true); + $this->connectMockHooks('rename', $view, $targetPath, $lockTypeTargetPre, $lockTypeTargetPost, true); + // in pre-hook, mount point is still on $sourcePath + $this->connectMockHooks('rename', $view, $sourcePath, $lockTypeSharedRootPre, $dummy, false); + // in post-hook, mount point is now on $targetPath + $this->connectMockHooks('rename', $view, $targetPath, $dummy, $lockTypeSharedRootPost, false); + + $this->assertNull($this->getFileLockType($view, $sourcePath, false), 'Shared storage root not locked before operation'); + $this->assertNull($this->getFileLockType($view, $sourcePath, true), 'Source path not locked before operation'); + $this->assertNull($this->getFileLockType($view, $targetPath, true), 'Target path not locked before operation'); + + $view->rename($sourcePath, $targetPath); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePre, 'Source path locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeSourceDuring, 'Source path locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeSourcePost, 'Source path locked properly during post-hook'); + + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPre, 'Target path locked properly during pre-hook'); + $this->assertEquals(ILockingProvider::LOCK_EXCLUSIVE, $lockTypeTargetDuring, 'Target path locked properly during operation'); + $this->assertEquals(ILockingProvider::LOCK_SHARED, $lockTypeTargetPost, 'Target path locked properly during post-hook'); + + $this->assertNull($lockTypeSharedRootPre, 'Shared storage root not locked during pre-hook'); + $this->assertNull($lockTypeSharedRootDuring, 'Shared storage root not locked during move'); + $this->assertNull($lockTypeSharedRootPost, 'Shared storage root not locked during post-hook'); + + $this->assertNull($this->getFileLockType($view, $sourcePath, false), 'Shared storage root not locked after operation'); + $this->assertNull($this->getFileLockType($view, $sourcePath, true), 'Source path not locked after operation'); + $this->assertNull($this->getFileLockType($view, $targetPath, true), 'Target path not locked after operation'); + + \Test\TestCase::invokePrivate($mountProviderCollection, 'providers', [[]]); + } + + /** + * Connect hook callbacks for hook type + * + * @param string $hookType hook type or null for none + * @param \OC\Files\View $view view to check the lock on + * @param string $path path for which to check the lock + * @param int $lockTypePre variable to receive lock type that was active in the pre-hook + * @param int $lockTypePost variable to receive lock type that was active in the post-hook + * @param bool $onMountPoint true to check the mount point instead of the + * mounted storage + */ + private function connectMockHooks($hookType, $view, $path, &$lockTypePre, &$lockTypePost, $onMountPoint = false) { + if ($hookType === null) { + return; + } + + $eventHandler = $this->getMockBuilder('\stdclass') + ->setMethods(['preCallback', 'postCallback']) + ->getMock(); + + $eventHandler->expects($this->any()) + ->method('preCallback') + ->will($this->returnCallback( + function() use ($view, $path, $onMountPoint, &$lockTypePre){ + $lockTypePre = $this->getFileLockType($view, $path, $onMountPoint); + } + )); + $eventHandler->expects($this->any()) + ->method('postCallback') + ->will($this->returnCallback( + function() use ($view, $path, $onMountPoint, &$lockTypePost){ + $lockTypePost = $this->getFileLockType($view, $path, $onMountPoint); + } + )); + + if ($hookType !== null) { + \OCP\Util::connectHook( + \OC\Files\Filesystem::CLASSNAME, + $hookType, + $eventHandler, + 'preCallback' + ); + \OCP\Util::connectHook( + \OC\Files\Filesystem::CLASSNAME, + 'post_' . $hookType, + $eventHandler, + 'postCallback' + ); + } + } + + /** + * Returns the file lock type + * + * @param \OC\Files\View $view view + * @param string $path path + * @param bool $onMountPoint true to check the mount point instead of the + * mounted storage + * + * @return int lock type or null if file was not locked + */ + private function getFileLockType(\OC\Files\View $view, $path, $onMountPoint = false) { + if ($this->isFileLocked($view, $path, ILockingProvider::LOCK_EXCLUSIVE, $onMountPoint)) { + return ILockingProvider::LOCK_EXCLUSIVE; + } else if ($this->isFileLocked($view, $path, ILockingProvider::LOCK_SHARED, $onMountPoint)) { + return ILockingProvider::LOCK_SHARED; + } + return null; + } } diff --git a/tests/lib/ocsclienttest.php b/tests/lib/ocsclienttest.php index ca8a2a2a2e8..80102eb62ee 100644 --- a/tests/lib/ocsclienttest.php +++ b/tests/lib/ocsclienttest.php @@ -85,7 +85,7 @@ class OCSClientTest extends \Test\TestCase { ->method('getSystemValue') ->with('appstoreenabled', true) ->will($this->returnValue(false)); - $this->assertNull($this->ocsClient->getCategories()); + $this->assertNull($this->ocsClient->getCategories([8, 1, 0, 7])); } public function testGetCategoriesExceptionClient() { @@ -108,6 +108,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/categories', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->throwException(new \Exception('TheErrorMessage'))); @@ -127,7 +128,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getCategories()); + $this->assertNull($this->ocsClient->getCategories([8, 1, 0, 7])); } public function testGetCategoriesParseError() { @@ -156,6 +157,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/categories', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -175,7 +177,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getCategories()); + $this->assertNull($this->ocsClient->getCategories([8, 1, 0, 7])); } public function testGetCategoriesSuccessful() { @@ -239,6 +241,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/categories', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -256,7 +259,7 @@ class OCSClientTest extends \Test\TestCase { 924 => 'ownCloud Tool', 925 => 'ownCloud other', ]; - $this->assertSame($expected, $this->ocsClient->getCategories()); + $this->assertSame($expected, $this->ocsClient->getCategories([8, 1, 0, 7])); } public function testGetApplicationsDisabledAppStore() { @@ -265,7 +268,7 @@ class OCSClientTest extends \Test\TestCase { ->method('getSystemValue') ->with('appstoreenabled', true) ->will($this->returnValue(false)); - $this->assertSame([], $this->ocsClient->getApplications([], 1, 'approved')); + $this->assertSame([], $this->ocsClient->getApplications([], 1, 'approved', [8, 1, 0, 7])); } public function testGetApplicationsExceptionClient() { @@ -289,7 +292,7 @@ class OCSClientTest extends \Test\TestCase { [ 'timeout' => 5, 'query' => [ - 'version' => implode('x', \OC_Util::getVersion()), + 'version' => implode('x', [8, 1, 0, 7]), 'filter' => 'approved', 'categories' => '815x1337', 'sortmode' => 'new', @@ -316,7 +319,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertSame([], $this->ocsClient->getApplications([815, 1337], 1, 'approved')); + $this->assertSame([], $this->ocsClient->getApplications([815, 1337], 1, 'approved', [8, 1, 0, 7])); } public function testGetApplicationsParseError() { @@ -346,7 +349,7 @@ class OCSClientTest extends \Test\TestCase { [ 'timeout' => 5, 'query' => [ - 'version' => implode('x', \OC_Util::getVersion()), + 'version' => implode('x', [8, 1, 0, 7]), 'filter' => 'approved', 'categories' => '815x1337', 'sortmode' => 'new', @@ -373,7 +376,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertSame([], $this->ocsClient->getApplications([815, 1337], 1, 'approved')); + $this->assertSame([], $this->ocsClient->getApplications([815, 1337], 1, 'approved', [8, 1, 0, 7])); } public function testGetApplicationsSuccessful() { @@ -482,7 +485,7 @@ class OCSClientTest extends \Test\TestCase { [ 'timeout' => 5, 'query' => [ - 'version' => implode('x', \OC_Util::getVersion()), + 'version' => implode('x', [8, 1, 0, 7]), 'filter' => 'approved', 'categories' => '815x1337', 'sortmode' => 'new', @@ -539,7 +542,7 @@ class OCSClientTest extends \Test\TestCase { 'profilepage' => 'http://opendesktop.org/usermanager/search.php?username=owncloud', ], ]; - $this->assertEquals($expected, $this->ocsClient->getApplications([815, 1337], 1, 'approved')); + $this->assertEquals($expected, $this->ocsClient->getApplications([815, 1337], 1, 'approved', [8, 1, 0, 7])); } public function tesGetApplicationDisabledAppStore() { @@ -548,7 +551,7 @@ class OCSClientTest extends \Test\TestCase { ->method('getSystemValue') ->with('appstoreenabled', true) ->will($this->returnValue(false)); - $this->assertNull($this->ocsClient->getApplication('MyId')); + $this->assertNull($this->ocsClient->getApplication('MyId', [8, 1, 0, 7])); } public function testGetApplicationExceptionClient() { @@ -571,6 +574,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/data/MyId', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->throwException(new \Exception('TheErrorMessage'))); @@ -590,7 +594,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getApplication('MyId')); + $this->assertNull($this->ocsClient->getApplication('MyId', [8, 1, 0, 7])); } public function testGetApplicationParseError() { @@ -619,6 +623,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/data/MyId', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -638,7 +643,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getApplication('MyId')); + $this->assertNull($this->ocsClient->getApplication('MyId', [8, 1, 0, 7])); } public function testGetApplicationSuccessful() { @@ -732,6 +737,7 @@ class OCSClientTest extends \Test\TestCase { <downloadpackagename1></downloadpackagename1> <downloadrepository1></downloadrepository1> <downloadsize1>1</downloadsize1> + <approved>200</approved> </content> </data> </ocs> @@ -745,6 +751,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/data/MyId', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -770,8 +777,9 @@ class OCSClientTest extends \Test\TestCase { 'changed' => 1404743680, 'description' => 'Placeholder for future updates', 'score' => 50, + 'level' => 200, ]; - $this->assertSame($expected, $this->ocsClient->getApplication('MyId')); + $this->assertSame($expected, $this->ocsClient->getApplication('MyId', [8, 1, 0, 7])); } public function testGetApplicationEmptyXml() { $this->config @@ -807,6 +815,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/data/MyId', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -816,7 +825,7 @@ class OCSClientTest extends \Test\TestCase { ->method('newClient') ->will($this->returnValue($client)); - $this->assertSame(null, $this->ocsClient->getApplication('MyId')); + $this->assertSame(null, $this->ocsClient->getApplication('MyId', [8, 1, 0, 7])); } public function testGetApplicationDownloadDisabledAppStore() { @@ -825,7 +834,7 @@ class OCSClientTest extends \Test\TestCase { ->method('getSystemValue') ->with('appstoreenabled', true) ->will($this->returnValue(false)); - $this->assertNull($this->ocsClient->getApplicationDownload('MyId')); + $this->assertNull($this->ocsClient->getApplicationDownload('MyId', [8, 1, 0, 7])); } public function testGetApplicationDownloadExceptionClient() { @@ -848,6 +857,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/download/MyId/1', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->throwException(new \Exception('TheErrorMessage'))); @@ -867,7 +877,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getApplicationDownload('MyId')); + $this->assertNull($this->ocsClient->getApplicationDownload('MyId', [8, 1, 0, 7])); } public function testGetApplicationDownloadParseError() { @@ -896,6 +906,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/download/MyId/1', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -915,7 +926,7 @@ class OCSClientTest extends \Test\TestCase { ] ); - $this->assertNull($this->ocsClient->getApplicationDownload('MyId')); + $this->assertNull($this->ocsClient->getApplicationDownload('MyId', [8, 1, 0, 7])); } public function testGetApplicationDownloadUrlSuccessful() { @@ -962,6 +973,7 @@ class OCSClientTest extends \Test\TestCase { 'https://api.owncloud.com/v1/content/download/MyId/1', [ 'timeout' => 5, + 'query' => ['version' => '8x1x0x7'], ] ) ->will($this->returnValue($response)); @@ -974,6 +986,6 @@ class OCSClientTest extends \Test\TestCase { $expected = [ 'downloadlink' => 'https://apps.owncloud.com/CONTENT/content-files/166052-files_trashbin.zip', ]; - $this->assertSame($expected, $this->ocsClient->getApplicationDownload('MyId')); + $this->assertSame($expected, $this->ocsClient->getApplicationDownload('MyId', [8, 1, 0, 7])); } } diff --git a/tests/lib/repair/removegetetagentriestest.php b/tests/lib/repair/removegetetagentriestest.php new file mode 100644 index 00000000000..43b7bf323c0 --- /dev/null +++ b/tests/lib/repair/removegetetagentriestest.php @@ -0,0 +1,77 @@ +<?php +/** + * @author Morris Jobke <hey@morrisjobke.de> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace Test\Repair; + +use OC\Repair\RemoveGetETagEntries; +use Test\TestCase; + +class RemoveGetETagEntriesTest extends TestCase { + /** @var \OCP\IDBConnection */ + protected $connection; + + protected function setUp() { + parent::setUp(); + + $this->connection = \OC::$server->getDatabaseConnection(); + } + + public function testRun() { + + $userName = 'removePropertiesUser'; + $data = [ + [$userName, '/abc.def.txt', '{DAV:}getetag', 'abcdef'], + [$userName, '/abc.def.txt', '{DAV:}anotherRandomProperty', 'ghi'], + ]; + + // insert test data + $sqlToInsertProperties = 'INSERT INTO `*PREFIX*properties` (`userid`, `propertypath`, `propertyname`, `propertyvalue`) VALUES (?, ?, ? ,?)'; + foreach ($data as $entry) { + $this->connection->executeUpdate($sqlToInsertProperties, $entry); + } + + // check if test data is written to DB + $sqlToFetchProperties = 'SELECT `userid`, `propertypath`, `propertyname`, `propertyvalue` FROM `*PREFIX*properties` WHERE `userid` = ?'; + $stmt = $this->connection->executeQuery($sqlToFetchProperties, [$userName]); + $entries = $stmt->fetchAll(\PDO::FETCH_NUM); + + $this->assertCount(2, $entries, 'Asserts that two entries are returned as we have inserted two'); + foreach($entries as $entry) { + $this->assertTrue(in_array($entry, $data), 'Asserts that the entries are the ones from the test data set'); + } + + // run repair step + $repair = new RemoveGetETagEntries($this->connection); + $repair->run(); + + // check if test data is correctly modified in DB + $stmt = $this->connection->executeQuery($sqlToFetchProperties, [$userName]); + $entries = $stmt->fetchAll(\PDO::FETCH_NUM); + + $this->assertCount(1, $entries, 'Asserts that only one entry is returned after the repair step - the other one has to be removed'); + $this->assertSame($data[1], $entries[0], 'Asserts that the returned entry is the correct one from the test data set'); + + // remove test data + $sqlToRemoveProperties = 'DELETE FROM `*PREFIX*properties` WHERE `userid` = ?'; + $this->connection->executeUpdate($sqlToRemoveProperties, [$userName]); + } + +} diff --git a/tests/lib/server.php b/tests/lib/server.php index f2971fea25d..cf0ad8265bf 100644 --- a/tests/lib/server.php +++ b/tests/lib/server.php @@ -99,6 +99,7 @@ class Server extends \Test\TestCase { ['NavigationManager', '\OC\NavigationManager'], ['NavigationManager', '\OCP\INavigationManager'], ['UserCache', '\OC\Cache\File'], + ['UserCache', '\OCP\ICache'], ['OcsClient', '\OC\OCSClient'], diff --git a/tests/lib/share/helper.php b/tests/lib/share/helper.php index 0385263fd91..e37a3db8bf0 100644 --- a/tests/lib/share/helper.php +++ b/tests/lib/share/helper.php @@ -50,44 +50,31 @@ class Test_Share_Helper extends \Test\TestCase { $this->assertSame($expected, $result); } - public function fixRemoteURLInShareWithData() { - $userPrefix = ['test@', 'na/me@']; + public function dataTestSplitUserRemote() { + $userPrefix = ['user@name', 'username']; $protocols = ['', 'http://', 'https://']; $remotes = [ 'localhost', - 'test:foobar@localhost', 'local.host', 'dev.local.host', 'dev.local.host/path', + 'dev.local.host/at@inpath', '127.0.0.1', '::1', '::192.0.2.128', + '::192.0.2.128/at@inpath', ]; - $testCases = [ - ['test', 'test'], - ['na/me', 'na/me'], - ['na/me/', 'na/me'], - ['na/index.php', 'na/index.php'], - ['http://localhost', 'http://localhost'], - ['http://localhost/', 'http://localhost'], - ['http://localhost/index.php', 'http://localhost/index.php'], - ['http://localhost/index.php/s/token', 'http://localhost/index.php/s/token'], - ['http://test:foobar@localhost', 'http://test:foobar@localhost'], - ['http://test:foobar@localhost/', 'http://test:foobar@localhost'], - ['http://test:foobar@localhost/index.php', 'http://test:foobar@localhost'], - ['http://test:foobar@localhost/index.php/s/token', 'http://test:foobar@localhost'], - ]; - + $testCases = []; foreach ($userPrefix as $user) { foreach ($remotes as $remote) { foreach ($protocols as $protocol) { - $baseUrl = $user . $protocol . $remote; + $baseUrl = $user . '@' . $protocol . $remote; - $testCases[] = [$baseUrl, $baseUrl]; - $testCases[] = [$baseUrl . '/', $baseUrl]; - $testCases[] = [$baseUrl . '/index.php', $baseUrl]; - $testCases[] = [$baseUrl . '/index.php/s/token', $baseUrl]; + $testCases[] = [$baseUrl, $user, $protocol . $remote]; + $testCases[] = [$baseUrl . '/', $user, $protocol . $remote]; + $testCases[] = [$baseUrl . '/index.php', $user, $protocol . $remote]; + $testCases[] = [$baseUrl . '/index.php/s/token', $user, $protocol . $remote]; } } } @@ -95,9 +82,43 @@ class Test_Share_Helper extends \Test\TestCase { } /** - * @dataProvider fixRemoteURLInShareWithData + * @dataProvider dataTestSplitUserRemote + * + * @param string $remote + * @param string $expectedUser + * @param string $expectedUrl + */ + public function testSplitUserRemote($remote, $expectedUser, $expectedUrl) { + list($remoteUser, $remoteUrl) = \OC\Share\Helper::splitUserRemote($remote); + $this->assertSame($expectedUser, $remoteUser); + $this->assertSame($expectedUrl, $remoteUrl); + } + + public function dataTestSplitUserRemoteError() { + return array( + // Invalid path + array('user@'), + + // Invalid user + array('@server'), + array('us/er@server'), + array('us:er@server'), + + // Invalid splitting + array('user'), + array(''), + array('us/erserver'), + array('us:erserver'), + ); + } + + /** + * @dataProvider dataTestSplitUserRemoteError + * + * @param string $id + * @expectedException \OC\HintException */ - public function testFixRemoteURLInShareWith($remote, $expected) { - $this->assertSame($expected, \OC\Share\Helper::fixRemoteURLInShareWith($remote)); + public function testSplitUserRemoteError($id) { + \OC\Share\Helper::splitUserRemote($id); } } diff --git a/tests/lib/share/share.php b/tests/lib/share/share.php index f03ed43e7fc..92f6b612688 100644 --- a/tests/lib/share/share.php +++ b/tests/lib/share/share.php @@ -968,6 +968,35 @@ class Test_Share extends \Test\TestCase { } + public function dataShareWithRemoteUserAndRemoteIsInvalid() { + return [ + // Invalid path + array('user@'), + + // Invalid user + array('@server'), + array('us/er@server'), + array('us:er@server'), + + // Invalid splitting + array('user'), + array(''), + array('us/erserver'), + array('us:erserver'), + ]; + } + + /** + * @dataProvider dataShareWithRemoteUserAndRemoteIsInvalid + * + * @param string $remoteId + * @expectedException \OC\HintException + */ + public function testShareWithRemoteUserAndRemoteIsInvalid($remoteId) { + OC_User::setUserId($this->user1); + OCP\Share::shareItem('test', 'test.txt', OCP\Share::SHARE_TYPE_REMOTE, $remoteId, \OCP\Constants::PERMISSION_ALL); + } + public function testUnshareAll() { $this->shareUserTestFileWithUser($this->user1, $this->user2); $this->shareUserTestFileWithUser($this->user2, $this->user3); diff --git a/tests/lib/testcase.php b/tests/lib/testcase.php index d385a903d1e..407c5165140 100644 --- a/tests/lib/testcase.php +++ b/tests/lib/testcase.php @@ -104,6 +104,7 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase { self::tearDownAfterClassCleanFileCache(); self::tearDownAfterClassCleanStrayDataFiles($dataDir); self::tearDownAfterClassCleanStrayHooks(); + self::tearDownAfterClassCleanStrayLocks(); parent::tearDownAfterClass(); } @@ -197,6 +198,13 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase { } /** + * Clean up the list of locks + */ + static protected function tearDownAfterClassCleanStrayLocks() { + \OC::$server->getLockingProvider()->releaseAll(); + } + + /** * Login and setup FS as a given user, * sets the given user as the current user. * @@ -249,11 +257,13 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase { * @param \OC\Files\View $view view * @param string $path path to check * @param int $type lock type + * @param bool $onMountPoint true to check the mount point instead of the + * mounted storage * * @return boolean true if the file is locked with the * given type, false otherwise */ - protected function isFileLocked($view, $path, $type) { + protected function isFileLocked($view, $path, $type, $onMountPoint = false) { // Note: this seems convoluted but is necessary because // the format of the lock key depends on the storage implementation // (in our case mostly md5) @@ -266,10 +276,10 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase { $checkType = \OCP\Lock\ILockingProvider::LOCK_SHARED; } try { - $view->lockFile($path, $checkType); + $view->lockFile($path, $checkType, $onMountPoint); // no exception, which means the lock of $type is not set // clean up - $view->unlockFile($path, $checkType); + $view->unlockFile($path, $checkType, $onMountPoint); return false; } catch (\OCP\Lock\LockedException $e) { // we could not acquire the counter-lock, which means diff --git a/tests/lib/testmoveablemountpoint.php b/tests/lib/testmoveablemountpoint.php new file mode 100644 index 00000000000..262016b76c1 --- /dev/null +++ b/tests/lib/testmoveablemountpoint.php @@ -0,0 +1,49 @@ +<?php +/** + * @author Vincent Petry <pvince81@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +namespace Test; + +use OC\Files\Mount; + +/** + * Test moveable mount for mocking + */ +class TestMoveableMountPoint extends Mount\MountPoint implements Mount\MoveableMount { + + /** + * Move the mount point to $target + * + * @param string $target the target mount point + * @return bool + */ + public function moveMount($target) { + $this->setMountPoint($target); + } + + /** + * Remove the mount points + * + * @return mixed + * @return bool + */ + public function removeMount() { + } +} diff --git a/tests/lib/updater.php b/tests/lib/updater.php index 13b45b3d8e7..28577071b4c 100644 --- a/tests/lib/updater.php +++ b/tests/lib/updater.php @@ -1,107 +1,347 @@ <?php /** - * Copyright (c) 2014 Lukas Reschke <lukas@owncloud.com> - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. + * @author Lukas Reschke <lukas@owncloud.com> + * @author Victor Dubiniuk <dubiniuk@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * */ namespace OC; +use OCP\IConfig; +use OCP\ILogger; + class UpdaterTest extends \Test\TestCase { + /** @var IConfig */ + private $config; + /** @var HTTPHelper */ + private $httpHelper; + /** @var ILogger */ + private $logger; + /** @var Updater */ + private $updater; - public function versionCompatibilityTestData() { - return array( - array('1.0.0.0', '2.2.0', true), - array('1.1.1.1', '2.0.0', true), - array('5.0.3', '4.0.3', false), - array('12.0.3', '13.4.5', true), - array('1', '2', true), - array('2', '2', true), - array('6.0.5', '6.0.6', true), - array('5.0.6', '7.0.4', false) + public function setUp() { + parent::setUp(); + $this->config = $this->getMockBuilder('\\OCP\\IConfig') + ->disableOriginalConstructor() + ->getMock(); + $this->httpHelper = $this->getMockBuilder('\\OC\\HTTPHelper') + ->disableOriginalConstructor() + ->getMock(); + $this->logger = $this->getMockBuilder('\\OCP\\ILogger') + ->disableOriginalConstructor() + ->getMock(); + + $this->updater = new Updater( + $this->httpHelper, + $this->config, + $this->logger ); } /** + * @param string $baseUrl + * @return string + */ + private function buildUpdateUrl($baseUrl) { + return $baseUrl . '?version='.implode('x', \OC_Util::getVersion()).'xinstalledatxlastupdatedatx'.\OC_Util::getChannel().'x'.\OC_Util::getEditionString().'x'; + } + + /** + * @return array + */ + public function versionCompatibilityTestData() { + return [ + ['1.0.0.0', '2.2.0', true], + ['1.1.1.1', '2.0.0', true], + ['5.0.3', '4.0.3', false], + ['12.0.3', '13.4.5', true], + ['1', '2', true], + ['2', '2', true], + ['6.0.5', '6.0.6', true], + ['5.0.6', '7.0.4', false], + ]; + } + + public function testSetSimulateStepEnabled() { + $this->updater->setSimulateStepEnabled(true); + $this->assertSame(true, $this->invokePrivate($this->updater, 'simulateStepEnabled')); + $this->updater->setSimulateStepEnabled(false); + $this->assertSame(false, $this->invokePrivate($this->updater, 'simulateStepEnabled')); + } + + public function testSetUpdateStepEnabled() { + $this->updater->setUpdateStepEnabled(true); + $this->assertSame(true, $this->invokePrivate($this->updater, 'updateStepEnabled')); + $this->updater->setUpdateStepEnabled(false); + $this->assertSame(false, $this->invokePrivate($this->updater, 'updateStepEnabled')); + } + + public function testSetSkip3rdPartyAppsDisable() { + $this->updater->setSkip3rdPartyAppsDisable(true); + $this->assertSame(true, $this->invokePrivate($this->updater, 'skip3rdPartyAppsDisable')); + $this->updater->setSkip3rdPartyAppsDisable(false); + $this->assertSame(false, $this->invokePrivate($this->updater, 'skip3rdPartyAppsDisable')); + } + + /** * @dataProvider versionCompatibilityTestData + * + * @param string $oldVersion + * @param string $newVersion + * @param bool $result */ public function testIsUpgradePossible($oldVersion, $newVersion, $result) { - $updater = new Updater(\OC::$server->getHTTPHelper(), \OC::$server->getConfig()); + $updater = new Updater($this->httpHelper, $this->config); $this->assertSame($result, $updater->isUpgradePossible($oldVersion, $newVersion)); } - public function testBrokenXmlResponse(){ - $invalidUpdater = $this->getUpdaterMock('OMG!'); - $invalidResult = $invalidUpdater->check(); - $this->assertEmpty($invalidResult); + public function testCheckInCache() { + $expectedResult = [ + 'version' => '8.0.4.2', + 'versionstring' => 'ownCloud 8.0.4', + 'url' => 'https://download.owncloud.org/community/owncloud-8.0.4.zip', + 'web' => 'http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html', + ]; + + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(time())); + $this->config + ->expects($this->at(1)) + ->method('getAppValue') + ->with('core', 'lastupdateResult') + ->will($this->returnValue(json_encode($expectedResult))); + + $this->assertSame($expectedResult, $this->updater->check()); } - public function testEmptyResponse(){ - $emptyUpdater = $this->getUpdaterMock(''); - $emptyResult = $emptyUpdater->check(); - $this->assertEmpty($emptyResult); + public function testCheckWithoutUpdateUrl() { + $expectedResult = [ + 'version' => '8.0.4.2', + 'versionstring' => 'ownCloud 8.0.4', + 'url' => 'https://download.owncloud.org/community/owncloud-8.0.4.zip', + 'web' => 'http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html', + ]; + + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(0)); + $this->config + ->expects($this->at(1)) + ->method('setAppValue') + ->with('core', 'lastupdatedat', $this->isType('integer')); + $this->config + ->expects($this->at(3)) + ->method('getAppValue') + ->with('core', 'installedat') + ->will($this->returnValue('installedat')); + $this->config + ->expects($this->at(4)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue('lastupdatedat')); + $this->config + ->expects($this->at(5)) + ->method('setAppValue') + ->with('core', 'lastupdateResult', json_encode($expectedResult)); + + $updateXml = '<?xml version="1.0"?> +<owncloud> + <version>8.0.4.2</version> + <versionstring>ownCloud 8.0.4</versionstring> + <url>https://download.owncloud.org/community/owncloud-8.0.4.zip</url> + <web>http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html</web> +</owncloud>'; + $this->httpHelper + ->expects($this->once()) + ->method('getUrlContent') + ->with($this->buildUpdateUrl('https://updates.owncloud.com/server/')) + ->will($this->returnValue($updateXml)); - // Error while fetching new contents e.g. too many redirects - $falseUpdater = $this->getUpdaterMock(false); - $falseResult = $falseUpdater->check(); - $this->assertEmpty($falseResult); + $this->assertSame($expectedResult, $this->updater->check()); } - public function testValidEmptyXmlResponse(){ - $updater = $this->getUpdaterMock( - '<?xml version="1.0"?><owncloud><version></version><versionstring></versionstring><url></url><web></web></owncloud>' - ); - $result = array_map('strval', $updater->check()); - - $this->assertArrayHasKey('version', $result); - $this->assertArrayHasKey('versionstring', $result); - $this->assertArrayHasKey('url', $result); - $this->assertArrayHasKey('web', $result); - $this->assertEmpty($result['version']); - $this->assertEmpty($result['versionstring']); - $this->assertEmpty($result['url']); - $this->assertEmpty($result['web']); + public function testCheckWithInvalidXml() { + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(0)); + $this->config + ->expects($this->at(1)) + ->method('setAppValue') + ->with('core', 'lastupdatedat', $this->isType('integer')); + $this->config + ->expects($this->at(3)) + ->method('getAppValue') + ->with('core', 'installedat') + ->will($this->returnValue('installedat')); + $this->config + ->expects($this->at(4)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue('lastupdatedat')); + $this->config + ->expects($this->at(5)) + ->method('setAppValue') + ->with('core', 'lastupdateResult', 'false'); + + $updateXml = 'Invalid XML Response!'; + $this->httpHelper + ->expects($this->once()) + ->method('getUrlContent') + ->with($this->buildUpdateUrl('https://updates.owncloud.com/server/')) + ->will($this->returnValue($updateXml)); + + $this->assertSame([], $this->updater->check()); } - public function testValidUpdateResponse(){ - $newUpdater = $this->getUpdaterMock( - '<?xml version="1.0"?> + public function testCheckWithUpdateUrl() { + $expectedResult = [ + 'version' => '8.0.4.2', + 'versionstring' => 'ownCloud 8.0.4', + 'url' => 'https://download.owncloud.org/community/owncloud-8.0.4.zip', + 'web' => 'http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html', + ]; + + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(0)); + $this->config + ->expects($this->at(1)) + ->method('setAppValue') + ->with('core', 'lastupdatedat', $this->isType('integer')); + $this->config + ->expects($this->at(3)) + ->method('getAppValue') + ->with('core', 'installedat') + ->will($this->returnValue('installedat')); + $this->config + ->expects($this->at(4)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue('lastupdatedat')); + $this->config + ->expects($this->at(5)) + ->method('setAppValue') + ->with('core', 'lastupdateResult', json_encode($expectedResult)); + + $updateXml = '<?xml version="1.0"?> <owncloud> - <version>7.0.3.4</version> - <versionstring>ownCloud 7.0.3</versionstring> - <url>http://download.owncloud.org/community/owncloud-7.0.3.zip</url> - <web>http://owncloud.org/</web> -</owncloud>' - ); - $newResult = array_map('strval', $newUpdater->check()); - - $this->assertArrayHasKey('version', $newResult); - $this->assertArrayHasKey('versionstring', $newResult); - $this->assertArrayHasKey('url', $newResult); - $this->assertArrayHasKey('web', $newResult); - $this->assertEquals('7.0.3.4', $newResult['version']); - $this->assertEquals('ownCloud 7.0.3', $newResult['versionstring']); - $this->assertEquals('http://download.owncloud.org/community/owncloud-7.0.3.zip', $newResult['url']); - $this->assertEquals('http://owncloud.org/', $newResult['web']); + <version>8.0.4.2</version> + <versionstring>ownCloud 8.0.4</versionstring> + <url>https://download.owncloud.org/community/owncloud-8.0.4.zip</url> + <web>http://doc.owncloud.org/server/8.0/admin_manual/maintenance/upgrade.html</web> +</owncloud>'; + $this->httpHelper + ->expects($this->once()) + ->method('getUrlContent') + ->with($this->buildUpdateUrl('https://myupdater.com/')) + ->will($this->returnValue($updateXml)); + + $this->assertSame($expectedResult, $this->updater->check('https://myupdater.com/')); } - protected function getUpdaterMock($content){ - // Invalidate cache - $mockedConfig = $this->getMockBuilder('\OCP\IConfig') - ->disableOriginalConstructor() - ->getMock() - ; + public function testCheckWithEmptyValidXmlResponse() { + $expectedResult = [ + 'version' => '', + 'versionstring' => '', + 'url' => '', + 'web' => '', + ]; - $clientService = $this->getMock('\OCP\Http\Client\IClientService'); - $mockedHTTPHelper = $this->getMockBuilder('\OC\HTTPHelper') - ->setConstructorArgs([\OC::$server->getConfig(), $clientService]) - ->getMock() - ; + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(0)); + $this->config + ->expects($this->at(1)) + ->method('setAppValue') + ->with('core', 'lastupdatedat', $this->isType('integer')); + $this->config + ->expects($this->at(3)) + ->method('getAppValue') + ->with('core', 'installedat') + ->will($this->returnValue('installedat')); + $this->config + ->expects($this->at(4)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue('lastupdatedat')); - $mockedHTTPHelper->expects($this->once())->method('getUrlContent')->will($this->returnValue($content)); + $updateXml = '<?xml version="1.0"?> +<owncloud> + <version></version> + <versionstring></versionstring> + <url></url> + <web></web> +</owncloud>'; + $this->httpHelper + ->expects($this->once()) + ->method('getUrlContent') + ->with($this->buildUpdateUrl('https://updates.owncloud.com/server/')) + ->will($this->returnValue($updateXml)); - return new Updater($mockedHTTPHelper, $mockedConfig); + $this->assertSame($expectedResult, $this->updater->check()); } + public function testCheckWithEmptyInvalidXmlResponse() { + $expectedResult = []; + + $this->config + ->expects($this->at(0)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue(0)); + $this->config + ->expects($this->at(1)) + ->method('setAppValue') + ->with('core', 'lastupdatedat', $this->isType('integer')); + $this->config + ->expects($this->at(3)) + ->method('getAppValue') + ->with('core', 'installedat') + ->will($this->returnValue('installedat')); + $this->config + ->expects($this->at(4)) + ->method('getAppValue') + ->with('core', 'lastupdatedat') + ->will($this->returnValue('lastupdatedat')); + $this->config + ->expects($this->at(5)) + ->method('setAppValue') + ->with('core', 'lastupdateResult', json_encode($expectedResult)); + + $updateXml = ''; + $this->httpHelper + ->expects($this->once()) + ->method('getUrlContent') + ->with($this->buildUpdateUrl('https://updates.owncloud.com/server/')) + ->will($this->returnValue($updateXml)); + + $this->assertSame($expectedResult, $this->updater->check()); + } } diff --git a/tests/ocs-provider/provider.php b/tests/ocs-provider/provider.php new file mode 100644 index 00000000000..34bd6067588 --- /dev/null +++ b/tests/ocs-provider/provider.php @@ -0,0 +1,170 @@ +<?php +/** + * @author Lukas Reschke <lukas@owncloud.com> + * + * @copyright Copyright (c) 2015, ownCloud, Inc. + * @license AGPL-3.0 + * + * This code is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License, version 3, + * as published by the Free Software Foundation. + * + * This program 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, version 3, + * along with this program. If not, see <http://www.gnu.org/licenses/> + * + */ + +class OcsProviderTest extends \Test\TestCase { + /** @var \OCP\IRequest */ + private $request; + /** @var \OCP\App\IAppManager */ + private $appManager; + /** @var Provider */ + private $ocsProvider; + + public function setUp() { + parent::setUp(); + + require_once '../ocs-provider/provider.php'; + + $this->request = $this->getMockBuilder('\\OCP\\IRequest')->getMock(); + $this->appManager = $this->getMockBuilder('\\OCP\\App\\IAppManager')->getMock(); + $this->ocsProvider = new Provider('ocs_provider', $this->request, $this->appManager); + } + + public function testBuildProviderListWithoutAnythingEnabled() { + $this->appManager + ->expects($this->at(0)) + ->method('isEnabledForUser') + ->with('files_sharing') + ->will($this->returnValue(false)); + $this->appManager + ->expects($this->at(1)) + ->method('isEnabledForUser') + ->with('activity') + ->will($this->returnValue(false)); + $this->appManager + ->expects($this->at(2)) + ->method('isEnabledForUser') + ->with('provisioning_api') + ->will($this->returnValue(false)); + + $expected = new \OCP\AppFramework\Http\JSONResponse( + [ + 'version' => 2, + 'PRIVATE_DATA' => [ + 'version' => 1, + 'endpoints' => [ + 'store' => '/ocs/v1.php/privatedata/setattribute', + 'read' => '/ocs/v1.php/privatedata/getattribute', + 'delete' => '/ocs/v1.php/privatedata/deleteattribute', + ], + ], + ] + ); + + $this->assertEquals($expected, $this->ocsProvider->buildProviderList()); + } + + public function testBuildProviderListWithSharingEnabled() { + $this->appManager + ->expects($this->at(0)) + ->method('isEnabledForUser') + ->with('files_sharing') + ->will($this->returnValue(true)); + $this->appManager + ->expects($this->at(1)) + ->method('isEnabledForUser') + ->with('activity') + ->will($this->returnValue(false)); + $this->appManager + ->expects($this->at(2)) + ->method('isEnabledForUser') + ->with('provisioning_api') + ->will($this->returnValue(false)); + + $expected = new \OCP\AppFramework\Http\JSONResponse( + [ + 'version' => 2, + 'PRIVATE_DATA' => [ + 'version' => 1, + 'endpoints' => [ + 'store' => '/ocs/v1.php/privatedata/setattribute', + 'read' => '/ocs/v1.php/privatedata/getattribute', + 'delete' => '/ocs/v1.php/privatedata/deleteattribute', + ], + ], + 'FEDERATED_SHARING' => [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/cloud/shares', + 'webdav' => '/public.php/webdav/', + ], + ], + 'SHARING' => [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/apps/files_sharing/api/v1/shares', + ], + ], + ] + ); + + $this->assertEquals($expected, $this->ocsProvider->buildProviderList()); + } + + public function testBuildProviderListWithEverythingEnabled() { + $this->appManager + ->expects($this->any()) + ->method('isEnabledForUser') + ->will($this->returnValue(true)); + + $expected = new \OCP\AppFramework\Http\JSONResponse( + [ + 'version' => 2, + 'PRIVATE_DATA' => [ + 'version' => 1, + 'endpoints' => [ + 'store' => '/ocs/v1.php/privatedata/setattribute', + 'read' => '/ocs/v1.php/privatedata/getattribute', + 'delete' => '/ocs/v1.php/privatedata/deleteattribute', + ], + ], + 'FEDERATED_SHARING' => [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/cloud/shares', + 'webdav' => '/public.php/webdav/', + ], + ], + 'SHARING' => [ + 'version' => 1, + 'endpoints' => [ + 'share' => '/ocs/v1.php/apps/files_sharing/api/v1/shares', + ], + ], + 'ACTIVITY' => [ + 'version' => 1, + 'endpoints' => [ + 'list' => '/ocs/v1.php/cloud/activity', + ], + ], + 'PROVISIONING' => [ + 'version' => 1, + 'endpoints' => [ + 'user' => '/ocs/v1.php/cloud/users', + 'groups' => '/ocs/v1.php/cloud/groups', + 'apps' => '/ocs/v1.php/cloud/apps', + ], + ], + ] + ); + + $this->assertEquals($expected, $this->ocsProvider->buildProviderList()); + } +} diff --git a/tests/phpunit-autotest.xml b/tests/phpunit-autotest.xml index 2bf3ca3cf9d..499c69bc9d1 100644 --- a/tests/phpunit-autotest.xml +++ b/tests/phpunit-autotest.xml @@ -10,6 +10,7 @@ <directory suffix='.php'>lib/</directory> <directory suffix='.php'>settings/</directory> <directory suffix='.php'>core/</directory> + <directory suffix='.php'>ocs-provider/</directory> <file>apps.php</file> </testsuite> <!-- filters for code coverage --> diff --git a/tests/phpunit.xml.dist b/tests/phpunit.xml.dist index 346c8f5f9c9..19fa38209a9 100644 --- a/tests/phpunit.xml.dist +++ b/tests/phpunit.xml.dist @@ -4,6 +4,7 @@ <directory suffix='.php'>lib/</directory> <directory suffix='.php'>settings/</directory> <directory suffix='.php'>core/</directory> + <directory suffix='.php'>ocs-provider/</directory> <file>apps.php</file> </testsuite> <!-- filters for code coverage --> diff --git a/version.php b/version.php index 8a61c494bf6..341e82671ea 100644 --- a/version.php +++ b/version.php @@ -2,7 +2,6 @@ /** * @author Frank Karlitschek <frank@owncloud.org> * @author Lukas Reschke <lukas@owncloud.com> - * @author Morris Jobke <hey@morrisjobke.de> * * @copyright Copyright (c) 2015, ownCloud, Inc. * @license AGPL-3.0 @@ -23,10 +22,10 @@ // We only can count up. The 4. digit is only for the internal patchlevel to trigger DB upgrades // between betas, final and RCs. This is _not_ the public version number. Reset minor/patchlevel // when updating major/minor version number. -$OC_Version=array(8, 1, 0, 7); +$OC_Version=array(8, 2, 0, 0); // The human readable string -$OC_VersionString='8.1 RC1'; +$OC_VersionString='8.2 pre alpha'; // The ownCloud channel $OC_Channel='git'; |