diff options
298 files changed, 2451 insertions, 2428 deletions
diff --git a/.gitignore b/.gitignore index 72e631fa7af..de467ec2cf9 100644 --- a/.gitignore +++ b/.gitignore @@ -109,3 +109,5 @@ Vagrantfile /tests/autotest* /tests/data/lorem-copy.txt /tests/data/testimage-copy.png +/config/config-autotest-backup.php +/config/autoconfig.php diff --git a/3rdparty b/3rdparty -Subproject 59f092231c6036838746262a4db80997908bb06 +Subproject 588b1308f4abf58acb3bb8519f6952d9890cca8 diff --git a/apps/files/appinfo/remote.php b/apps/files/appinfo/remote.php index f9fa792e133..dbab3256b98 100644 --- a/apps/files/appinfo/remote.php +++ b/apps/files/appinfo/remote.php @@ -27,37 +27,47 @@ * */ // Backends -$authBackend = new OC_Connector_Sabre_Auth(); -$lockBackend = new OC_Connector_Sabre_Locks(); -$requestBackend = new OC_Connector_Sabre_Request(); +$authBackend = new \OC\Connector\Sabre\Auth(); // Fire up server $objectTree = new \OC\Connector\Sabre\ObjectTree(); -$server = new OC_Connector_Sabre_Server($objectTree); -$server->httpRequest = $requestBackend; +$server = new \OC\Connector\Sabre\Server($objectTree); +// Set URL explicitly due to reverse-proxy situations +$server->httpRequest->setUrl(\OC::$server->getRequest()->getRequestUri()); $server->setBaseUri($baseuri); // Load plugins $defaults = new OC_Defaults(); $server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, $defaults->getName())); -$server->addPlugin(new \Sabre\DAV\Locks\Plugin($lockBackend)); -$server->addPlugin(new \Sabre\DAV\Browser\Plugin(false, false)); // Show something in the Browser, but no upload -$server->addPlugin(new OC_Connector_Sabre_FilesPlugin()); -$server->addPlugin(new OC_Connector_Sabre_MaintenancePlugin()); -$server->addPlugin(new OC_Connector_Sabre_ExceptionLoggerPlugin('webdav')); +// 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\ExceptionLoggerPlugin('webdav')); // wait with registering these until auth is handled and the filesystem is setup -$server->subscribeEvent('beforeMethod', function () use ($server, $objectTree) { +$server->on('beforeMethod', function () use ($server, $objectTree) { $view = \OC\Files\Filesystem::getView(); $rootInfo = $view->getFileInfo(''); // Create ownCloud Dir $mountManager = \OC\Files\Filesystem::getMountManager(); - $rootDir = new OC_Connector_Sabre_Directory($view, $rootInfo); + $rootDir = new \OC\Connector\Sabre\Directory($view, $rootInfo); $objectTree->init($rootDir, $view, $mountManager); $server->addPlugin(new \OC\Connector\Sabre\TagsPlugin($objectTree, \OC::$server->getTagManager())); - $server->addPlugin(new OC_Connector_Sabre_QuotaPlugin($view)); + $server->addPlugin(new \OC\Connector\Sabre\QuotaPlugin($view)); + + // custom properties plugin must be the last one + $server->addPlugin( + new \Sabre\DAV\PropertyStorage\Plugin( + new \OC\Connector\Sabre\CustomPropertiesBackend( + $objectTree, + \OC::$server->getDatabaseConnection(), + \OC::$server->getUserSession()->getUser() + ) + ) + ); }, 30); // priority 30: after auth (10) and acl(20), before lock(50) and handling the request // And off we go! diff --git a/apps/files/l10n/az.js b/apps/files/l10n/az.js index ab75ce05184..ef2c3df2b68 100644 --- a/apps/files/l10n/az.js +++ b/apps/files/l10n/az.js @@ -35,6 +35,8 @@ OC.L10N.register( "Invalid directory." : "Yalnış qovluq.", "Files" : "Fayllar", "All files" : "Bütün fayllar", + "Favorites" : "Sevimlilər", + "Home" : "Ev", "Unable to upload {filename} as it is a directory or has 0 bytes" : "Yükləmək olmur {filename} ona görə ki, ya qovluqdur yada ki, həcmi 0 baytdır ", "Total file size {size1} exceeds upload limit {size2}" : "Ümumi fayl həcmi {size1} yüklənmə limiti {size2} -ni aşır", "Not enough free space, you are uploading {size1} but only {size2} is left" : "Kifayət qədər boş yer yoxdur, siz yükləyirsiniz {size1} ancaq {size2} var. ", @@ -48,12 +50,24 @@ OC.L10N.register( "Error fetching URL" : "URL-in gətirilməsində səhv baş verdi", "Rename" : "Adı dəyiş", "Delete" : "Sil", + "Disconnect storage" : "Daşıyıcını ayır", + "Unshare" : "Paylaşımı durdur", "Download" : "Yüklə", + "Select" : "Seç", + "Pending" : "Gözləmə", + "Unable to determine date" : "Tarixi təyin etmək mümkün olmadı", + "Error moving file." : "Faylın köçürülməsində səhv baş verdi.", + "Error moving file" : "Faylın köçürülməsində səhv baş verdi", "Error" : "Səhv", + "Could not rename file" : "Faylın adını dəyişmək mümkün olmadı", + "Error deleting file." : "Faylın silinməsində səhv baş verdi.", + "No entries in this folder match '{filter}'" : "Bu qovluqda '{filter}' uyğunluğunda heç bir verilən tapılmadı", "Name" : "Ad", "Size" : "Həcm", + "Modified" : "Dəyişdirildi", "_%n folder_::_%n folders_" : ["",""], "_%n file_::_%n files_" : ["",""], + "You don’t have permission to upload or create files here" : "Sizin burda yükləməyə və ya fayl yaratmağa yetkiniz yoxdur ", "_Uploading %n file_::_Uploading %n files_" : ["",""], "_matches '{filter}'_::_match '{filter}'_" : ["",""], "A new file or folder has been <strong>created</strong>" : "Yeni fayl və ya direktoriya <strong>yaradılmışdır</strong>", diff --git a/apps/files/l10n/az.json b/apps/files/l10n/az.json index 505ab9ecaff..eb444a4c5b7 100644 --- a/apps/files/l10n/az.json +++ b/apps/files/l10n/az.json @@ -33,6 +33,8 @@ "Invalid directory." : "Yalnış qovluq.", "Files" : "Fayllar", "All files" : "Bütün fayllar", + "Favorites" : "Sevimlilər", + "Home" : "Ev", "Unable to upload {filename} as it is a directory or has 0 bytes" : "Yükləmək olmur {filename} ona görə ki, ya qovluqdur yada ki, həcmi 0 baytdır ", "Total file size {size1} exceeds upload limit {size2}" : "Ümumi fayl həcmi {size1} yüklənmə limiti {size2} -ni aşır", "Not enough free space, you are uploading {size1} but only {size2} is left" : "Kifayət qədər boş yer yoxdur, siz yükləyirsiniz {size1} ancaq {size2} var. ", @@ -46,12 +48,24 @@ "Error fetching URL" : "URL-in gətirilməsində səhv baş verdi", "Rename" : "Adı dəyiş", "Delete" : "Sil", + "Disconnect storage" : "Daşıyıcını ayır", + "Unshare" : "Paylaşımı durdur", "Download" : "Yüklə", + "Select" : "Seç", + "Pending" : "Gözləmə", + "Unable to determine date" : "Tarixi təyin etmək mümkün olmadı", + "Error moving file." : "Faylın köçürülməsində səhv baş verdi.", + "Error moving file" : "Faylın köçürülməsində səhv baş verdi", "Error" : "Səhv", + "Could not rename file" : "Faylın adını dəyişmək mümkün olmadı", + "Error deleting file." : "Faylın silinməsində səhv baş verdi.", + "No entries in this folder match '{filter}'" : "Bu qovluqda '{filter}' uyğunluğunda heç bir verilən tapılmadı", "Name" : "Ad", "Size" : "Həcm", + "Modified" : "Dəyişdirildi", "_%n folder_::_%n folders_" : ["",""], "_%n file_::_%n files_" : ["",""], + "You don’t have permission to upload or create files here" : "Sizin burda yükləməyə və ya fayl yaratmağa yetkiniz yoxdur ", "_Uploading %n file_::_Uploading %n files_" : ["",""], "_matches '{filter}'_::_match '{filter}'_" : ["",""], "A new file or folder has been <strong>created</strong>" : "Yeni fayl və ya direktoriya <strong>yaradılmışdır</strong>", diff --git a/apps/files/l10n/sl.js b/apps/files/l10n/sl.js index d5229f9bc61..d0bcd6392b2 100644 --- a/apps/files/l10n/sl.js +++ b/apps/files/l10n/sl.js @@ -75,7 +75,7 @@ OC.L10N.register( "Encryption App is enabled but your keys are not initialized, please log-out and log-in again" : "Program za šifriranje je omogočen, vendar ni začet. Odjavite se in nato ponovno prijavite.", "Invalid private key for Encryption App. Please update your private key password in your personal settings to recover access to your encrypted files." : "Ni ustreznega osebnega ključa za program za šifriranje. Posodobite osebni ključ za dostop do šifriranih datotek med nastavitvami.", "Encryption was disabled but your files are still encrypted. Please go to your personal settings to decrypt your files." : "Šifriranje je onemogočeno, datoteke pa so še vedno šifrirane. Odšifrirajte jih med nastavitvami.", - "_matches '{filter}'_::_match '{filter}'_" : ["","","",""], + "_matches '{filter}'_::_match '{filter}'_" : ["se sklada s filtrom '{filter}'","se skladata s filtrom '{filter}'","se skladajo s filtrom '{filter}'","se skladajo s filtrom '{filter}'"], "{dirs} and {files}" : "{dirs} in {files}", "Favorited" : "Označeno kot priljubljeno", "Favorite" : "Priljubljene", diff --git a/apps/files/l10n/sl.json b/apps/files/l10n/sl.json index 6ca654e3cf2..74786ed206d 100644 --- a/apps/files/l10n/sl.json +++ b/apps/files/l10n/sl.json @@ -73,7 +73,7 @@ "Encryption App is enabled but your keys are not initialized, please log-out and log-in again" : "Program za šifriranje je omogočen, vendar ni začet. Odjavite se in nato ponovno prijavite.", "Invalid private key for Encryption App. Please update your private key password in your personal settings to recover access to your encrypted files." : "Ni ustreznega osebnega ključa za program za šifriranje. Posodobite osebni ključ za dostop do šifriranih datotek med nastavitvami.", "Encryption was disabled but your files are still encrypted. Please go to your personal settings to decrypt your files." : "Šifriranje je onemogočeno, datoteke pa so še vedno šifrirane. Odšifrirajte jih med nastavitvami.", - "_matches '{filter}'_::_match '{filter}'_" : ["","","",""], + "_matches '{filter}'_::_match '{filter}'_" : ["se sklada s filtrom '{filter}'","se skladata s filtrom '{filter}'","se skladajo s filtrom '{filter}'","se skladajo s filtrom '{filter}'"], "{dirs} and {files}" : "{dirs} in {files}", "Favorited" : "Označeno kot priljubljeno", "Favorite" : "Priljubljene", diff --git a/apps/files_encryption/l10n/az.js b/apps/files_encryption/l10n/az.js index b8836e3611d..e5acbf937eb 100644 --- a/apps/files_encryption/l10n/az.js +++ b/apps/files_encryption/l10n/az.js @@ -6,6 +6,7 @@ OC.L10N.register( "Could not disable recovery key. Please check your recovery key password!" : "Geriqaytarılma açarını sondürmək olmur. Xahiş edirik geriqaytarılma key açarınızı yoxlayın.", "Recovery key successfully disabled" : "Bərpa açarı uğurla söndürüldü", "Password successfully changed." : "Şifrə uğurla dəyişdirildi.", + "Could not change the password. Maybe the old password was not correct." : "Şifrəni dəyişmək olmur, ola bilər ki, köhnə şifrə düzgün olmayıb.", "Your private key is not valid! Likely your password was changed outside of %s (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." : "Sizin gizli açarınız doğru deyil! Təxmin edilir ki, sizin şifrə %s-dən kənarda dəyişdirilib(misal üçün sizin koorporativ qovluq). Siz öz şifrələnmiş fayllarınıza yetkinizi bərpa etmək üçün, öz şifrənizi şəxsi quraşdırmalarınızda yeniləyə bilərsiniz.", "Unknown error. Please check your system settings or contact your administrator" : "Tanınmayan səhv. Xahiş olunur sistem quraşdırmalarınızı yoxlayın yada öz inzibatçınızla əlaqə yaradın", "Initial encryption running... Please try again later." : "İlkin şifrələnmə işləyir... Xahiş olunur birazdan yenidən müraciət edəsiniz.", diff --git a/apps/files_encryption/l10n/az.json b/apps/files_encryption/l10n/az.json index 94ed72f4ddf..21c819c347d 100644 --- a/apps/files_encryption/l10n/az.json +++ b/apps/files_encryption/l10n/az.json @@ -4,6 +4,7 @@ "Could not disable recovery key. Please check your recovery key password!" : "Geriqaytarılma açarını sondürmək olmur. Xahiş edirik geriqaytarılma key açarınızı yoxlayın.", "Recovery key successfully disabled" : "Bərpa açarı uğurla söndürüldü", "Password successfully changed." : "Şifrə uğurla dəyişdirildi.", + "Could not change the password. Maybe the old password was not correct." : "Şifrəni dəyişmək olmur, ola bilər ki, köhnə şifrə düzgün olmayıb.", "Your private key is not valid! Likely your password was changed outside of %s (e.g. your corporate directory). You can update your private key password in your personal settings to recover access to your encrypted files." : "Sizin gizli açarınız doğru deyil! Təxmin edilir ki, sizin şifrə %s-dən kənarda dəyişdirilib(misal üçün sizin koorporativ qovluq). Siz öz şifrələnmiş fayllarınıza yetkinizi bərpa etmək üçün, öz şifrənizi şəxsi quraşdırmalarınızda yeniləyə bilərsiniz.", "Unknown error. Please check your system settings or contact your administrator" : "Tanınmayan səhv. Xahiş olunur sistem quraşdırmalarınızı yoxlayın yada öz inzibatçınızla əlaqə yaradın", "Initial encryption running... Please try again later." : "İlkin şifrələnmə işləyir... Xahiş olunur birazdan yenidən müraciət edəsiniz.", diff --git a/apps/files_encryption/tests/webdav.php b/apps/files_encryption/tests/webdav.php deleted file mode 100755 index 0d5a8f82f2c..00000000000 --- a/apps/files_encryption/tests/webdav.php +++ /dev/null @@ -1,274 +0,0 @@ -<?php -/** - * @author Bjoern Schiessle <schiessle@owncloud.com> - * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Florin Peter <github@florin-peter.de> - * @author Joas Schilling <nickvergessen@gmx.de> - * @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> - * - * @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_Encryption\Tests; - -/** - * Class Webdav - * - * this class provide basic webdav tests for PUT,GET and DELETE - */ -class Webdav extends TestCase { - - const TEST_ENCRYPTION_WEBDAV_USER1 = "test-webdav-user1"; - - public $userId; - public $pass; - /** - * @var \OC\Files\View - */ - public $view; - public $dataShort; - public $stateFilesTrashbin; - - private $storage; - - public static function setUpBeforeClass() { - parent::setUpBeforeClass(); - - // create test user - self::loginHelper(self::TEST_ENCRYPTION_WEBDAV_USER1, true); - - } - - protected function setUp() { - parent::setUp(); - - // reset backend - \OC_User::useBackend('database'); - - // set user id - \OC_User::setUserId(self::TEST_ENCRYPTION_WEBDAV_USER1); - $this->userId = self::TEST_ENCRYPTION_WEBDAV_USER1; - $this->pass = self::TEST_ENCRYPTION_WEBDAV_USER1; - - // init filesystem view - $this->view = new \OC\Files\View('/'); - list($this->storage, ) = $this->view->resolvePath('/'); - // init short data - $this->dataShort = 'hats'; - - // remember files_trashbin state - $this->stateFilesTrashbin = \OC_App::isEnabled('files_trashbin'); - - // we don't want to tests with app files_trashbin enabled - \OC_App::disable('files_trashbin'); - - // create test user - self::loginHelper(self::TEST_ENCRYPTION_WEBDAV_USER1); - } - - protected function tearDown() { - // reset app files_trashbin - if ($this->stateFilesTrashbin) { - \OC_App::enable('files_trashbin'); - } else { - \OC_App::disable('files_trashbin'); - } - - parent::tearDown(); - } - - public static function tearDownAfterClass() { - // cleanup test user - \OC_User::deleteUser(self::TEST_ENCRYPTION_WEBDAV_USER1); - - parent::tearDownAfterClass(); - } - - /** - * test webdav put random file - */ - function testWebdavPUT() { - - // generate filename - $filename = '/tmp-' . $this->getUniqueID() . '.txt'; - - // set server vars - $_SERVER['REQUEST_METHOD'] = 'OPTIONS'; - - $_SERVER['REQUEST_METHOD'] = 'PUT'; - $_SERVER['REQUEST_URI'] = '/remote.php/webdav' . $filename; - $_SERVER['HTTP_AUTHORIZATION'] = 'Basic dGVzdC13ZWJkYXYtdXNlcjE6dGVzdC13ZWJkYXYtdXNlcjE='; - $_SERVER['CONTENT_TYPE'] = 'application/octet-stream'; - $_SERVER['PATH_INFO'] = '/webdav' . $filename; - $_SERVER['CONTENT_LENGTH'] = strlen($this->dataShort); - - // handle webdav request - $this->handleWebdavRequest($this->dataShort); - - // check if file was created - $this->assertTrue($this->view->file_exists('/' . $this->userId . '/files' . $filename)); - - // check if key-file was created - $this->assertTrue($this->view->file_exists( - '/' . $this->userId . '/files_encryption/keys/' . $filename . '/fileKey')); - - // check if shareKey-file was created - $this->assertTrue($this->view->file_exists( - '/' . $this->userId . '/files_encryption/keys/' . $filename . '/' . $this->userId . '.shareKey')); - - // disable encryption proxy to prevent recursive calls - $proxyStatus = \OC_FileProxy::$enabled; - \OC_FileProxy::$enabled = false; - - // get encrypted file content - $encryptedContent = $this->view->file_get_contents('/' . $this->userId . '/files' . $filename); - - // restore proxy state - \OC_FileProxy::$enabled = $proxyStatus; - - // check if encrypted content is valid - $this->assertTrue(\OCA\Files_Encryption\Crypt::isCatfileContent($encryptedContent)); - - // get decrypted file contents - $decrypt = file_get_contents('crypt:///' . $this->userId . '/files' . $filename); - - // check if file content match with the written content - $this->assertEquals($this->dataShort, $decrypt); - - // return filename for next test - return $filename; - } - - /** - * test webdav get random file - * - * @depends testWebdavPUT - */ - function testWebdavGET($filename) { - - // set server vars - $_SERVER['REQUEST_METHOD'] = 'GET'; - $_SERVER['REQUEST_URI'] = '/remote.php/webdav' . $filename; - $_SERVER['HTTP_AUTHORIZATION'] = 'Basic dGVzdC13ZWJkYXYtdXNlcjE6dGVzdC13ZWJkYXYtdXNlcjE='; - $_SERVER['PATH_INFO'] = '/webdav' . $filename; - - // handle webdav request - $content = $this->handleWebdavRequest(); - - // check if file content match with the written content - $this->assertEquals($this->dataShort, $content); - - // return filename for next test - return $filename; - } - - /** - * test webdav delete random file - * @depends testWebdavGET - */ - function testWebdavDELETE($filename) { - // set server vars - $_SERVER['REQUEST_METHOD'] = 'DELETE'; - $_SERVER['REQUEST_URI'] = '/remote.php/webdav' . $filename; - $_SERVER['HTTP_AUTHORIZATION'] = 'Basic dGVzdC13ZWJkYXYtdXNlcjE6dGVzdC13ZWJkYXYtdXNlcjE='; - $_SERVER['PATH_INFO'] = '/webdav' . $filename; - - // at the beginning the file should exist - $this->assertTrue($this->view->file_exists('/' . $this->userId . '/files' . $filename)); - - // handle webdav request - $content = $this->handleWebdavRequest(); - - // check if file was removed - $this->assertFalse($this->view->file_exists('/' . $this->userId . '/files' . $filename)); - - // check if key-file was removed - $this->assertFalse($this->view->file_exists( - '/' . $this->userId . '/files_encryption/keys/' . $filename . '/fileKey')); - - // check if shareKey-file was removed - $this->assertFalse($this->view->file_exists( - '/' . $this->userId . '/files_encryption/keys/' . $filename . '/' . $this->userId . '.shareKey')); - } - - /** - * handle webdav request - * - * @param bool $body - * @note this init procedure is copied from /apps/files/appinfo/remote.php - */ - function handleWebdavRequest($body = false) { - // Backends - $authBackend = $this->getMockBuilder('OC_Connector_Sabre_Auth') - ->setMethods(['validateUserPass']) - ->getMock(); - $authBackend->expects($this->any()) - ->method('validateUserPass') - ->will($this->returnValue(true)); - - $lockBackend = new \OC_Connector_Sabre_Locks(); - $requestBackend = new \OC_Connector_Sabre_Request(); - - // Create ownCloud Dir - $root = '/' . $this->userId . '/files'; - $view = new \OC\Files\View($root); - $publicDir = new \OC_Connector_Sabre_Directory($view, $view->getFileInfo('')); - $objectTree = new \OC\Connector\Sabre\ObjectTree(); - $mountManager = \OC\Files\Filesystem::getMountManager(); - $objectTree->init($publicDir, $view, $mountManager); - - // Fire up server - $server = new \Sabre\DAV\Server($publicDir); - $server->httpRequest = $requestBackend; - $server->setBaseUri('/remote.php/webdav/'); - - // Load plugins - $server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, 'ownCloud')); - $server->addPlugin(new \Sabre\DAV\Locks\Plugin($lockBackend)); - $server->addPlugin(new \Sabre\DAV\Browser\Plugin(false)); // Show something in the Browser, but no upload - $server->addPlugin(new \OC_Connector_Sabre_QuotaPlugin($view)); - $server->addPlugin(new \OC_Connector_Sabre_MaintenancePlugin()); - $server->debugExceptions = true; - - // Totally ugly hack to setup the FS - \OC::$server->getUserSession()->login($this->userId, $this->userId); - \OC_Util::setupFS($this->userId); - - // And off we go! - if ($body) { - $server->httpRequest->setBody($body); - } - - // turn on output buffering - ob_start(); - - // handle request - $server->exec(); - - // file content is written in the output buffer - $content = ob_get_contents(); - - // flush the output buffer and turn off output buffering - ob_end_clean(); - - // return captured content - return $content; - } -} diff --git a/apps/files_external/lib/owncloud.php b/apps/files_external/lib/owncloud.php index e9824140c7a..d00da691cd9 100644 --- a/apps/files_external/lib/owncloud.php +++ b/apps/files_external/lib/owncloud.php @@ -49,13 +49,13 @@ class OwnCloud extends \OC\Files\Storage\DAV{ $host = substr($host, 0, $hostSlashPos); } - if (substr($contextPath , 1) !== '/'){ + if (substr($contextPath, -1) !== '/'){ $contextPath .= '/'; } if (isset($params['root'])){ $root = $params['root']; - if (substr($root, 1) !== '/'){ + if (substr($root, 0, 1) !== '/'){ $root = '/' . $root; } } diff --git a/apps/files_external/lib/sftp.php b/apps/files_external/lib/sftp.php index c37663c4f86..b75092ef4e7 100644 --- a/apps/files_external/lib/sftp.php +++ b/apps/files_external/lib/sftp.php @@ -37,6 +37,7 @@ class SFTP extends \OC\Files\Storage\Common { private $user; private $password; private $root; + private $port = 22; /** * @var \Net_SFTP @@ -51,10 +52,21 @@ class SFTP extends \OC\Files\Storage\Common { \Net_SFTP_Stream::register(); $this->host = $params['host']; + + //deals with sftp://server example $proto = strpos($this->host, '://'); if ($proto != false) { $this->host = substr($this->host, $proto+3); } + + //deals with server:port + $hasPort = strpos($this->host,':'); + if($hasPort != false) { + $pieces = explode(":", $this->host); + $this->host = $pieces[0]; + $this->port = $pieces[1]; + } + $this->user = $params['user']; $this->password = isset($params['password']) ? $params['password'] : ''; @@ -82,7 +94,7 @@ class SFTP extends \OC\Files\Storage\Common { } $hostKeys = $this->readHostKeys(); - $this->client = new \Net_SFTP($this->host); + $this->client = new \Net_SFTP($this->host, $this->port); // The SSH Host Key MUST be verified before login(). $currentHostKey = $this->client->getServerPublicHostKey(); @@ -119,7 +131,7 @@ class SFTP extends \OC\Files\Storage\Common { * {@inheritdoc} */ public function getId(){ - return 'sftp::' . $this->user . '@' . $this->host . '/' . $this->root; + return 'sftp::' . $this->user . '@' . $this->host . ':' . $this->port . '/' . $this->root; } /** @@ -272,7 +284,7 @@ class SFTP extends \OC\Files\Storage\Common { if ($stat['type'] == NET_SFTP_TYPE_DIRECTORY) { return 'dir'; } - } catch (\Exeption $e) { + } catch (\Exception $e) { } return false; @@ -410,7 +422,7 @@ class SFTP extends \OC\Files\Storage\Common { // Do not pass the password here. We want to use the Net_SFTP object // supplied via stream context or fail. We only supply username and // hostname because this might show up in logs (they are not used). - $url = 'sftp://'.$this->user.'@'.$this->host.$this->root.$path; + $url = 'sftp://'.$this->user.'@'.$this->host.':'.$this->port.$this->root.$path; return $url; } } diff --git a/apps/files_external/tests/backends/sftp.php b/apps/files_external/tests/backends/sftp.php index f0405a1e211..e52c80b11b8 100644 --- a/apps/files_external/tests/backends/sftp.php +++ b/apps/files_external/tests/backends/sftp.php @@ -29,12 +29,12 @@ class SFTP extends Storage { parent::setUp(); $id = $this->getUniqueID(); - $this->config = include('files_external/tests/config.php'); - if ( ! is_array($this->config) or ! isset($this->config['sftp']) or ! $this->config['sftp']['run']) { + $this->config = include('files_external/tests/config.sftp.php'); + if (!is_array($this->config) or !$this->config['run']) { $this->markTestSkipped('SFTP backend not configured'); } - $this->config['sftp']['root'] .= '/' . $id; //make sure we have an new empty folder to work in - $this->instance = new \OC\Files\Storage\SFTP($this->config['sftp']); + $this->config['root'] .= '/' . $id; //make sure we have an new empty folder to work in + $this->instance = new \OC\Files\Storage\SFTP($this->config); $this->instance->mkdir('/'); } diff --git a/apps/files_external/tests/env/start-sftp-atmoz.sh b/apps/files_external/tests/env/start-sftp-atmoz.sh new file mode 100755 index 00000000000..7fb379839ba --- /dev/null +++ b/apps/files_external/tests/env/start-sftp-atmoz.sh @@ -0,0 +1,65 @@ +#!/bin/bash +# +# ownCloud +# +# This script start a docker container to test the files_external tests +# against. It will also change the files_external config to use the docker +# container as testing environment. This is reverted in the stop step.W +# +# Set environment variable DEBUG to print config file +# +# @author Morris Jobke +# @copyright 2015 Morris Jobke <hey@morrisjobke.de> +# + +if ! command -v docker >/dev/null 2>&1; then + echo "No docker executable found - skipped docker setup" + exit 0; +fi + +echo "Docker executable found - setup docker" + +echo "Fetch recent atmoz/sftp docker image" +docker pull atmoz/sftp + +# retrieve current folder to place the config in the parent folder +thisFolder=`echo $0 | replace "env/start-sftp-atmoz.sh" ""` + +if [ -z "$thisFolder" ]; then + thisFolder="." +fi; + +user=test +password=12345 + +container=`docker run -d atmoz/sftp $user:$password:1001` + +host=`docker inspect $container | grep IPAddress | cut -d '"' -f 4` + +cat > $thisFolder/config.sftp.php <<DELIM +<?php + +return array( + 'run'=>true, + 'host'=>'$host', + 'user'=>'$user', + 'password'=>'$password', + 'root'=>'', +); + +DELIM + +echo "sftp container: $container" + +# put container IDs into a file to drop them after the test run (keep in mind that multiple tests run in parallel on the same host) +echo $container >> $thisFolder/dockerContainerAtmoz.$EXECUTOR_NUMBER.sftp + +if [ -n "$DEBUG" ]; then + cat $thisFolder/config.sftp.php + cat $thisFolder/dockerContainerAtmoz.$EXECUTOR_NUMBER.sftp +fi + +# TODO find a way to determine the successful initialization inside the docker container +echo "Waiting 5 seconds for sftp initialization ... " +sleep 5 + diff --git a/apps/files_external/tests/env/stop-sftp-atmoz.sh b/apps/files_external/tests/env/stop-sftp-atmoz.sh new file mode 100755 index 00000000000..829855c807c --- /dev/null +++ b/apps/files_external/tests/env/stop-sftp-atmoz.sh @@ -0,0 +1,36 @@ +#!/bin/bash +# +# ownCloud +# +# This script stops the docker container the files_external tests were run +# against. It will also revert the config changes done in start step. +# +# @author Morris Jobke +# @copyright 2015 Morris Jobke <hey@morrisjobke.de> +# + +if ! command -v docker >/dev/null 2>&1; then + echo "No docker executable found - skipped docker stop" + exit 0; +fi + +echo "Docker executable found - stop and remove docker containers" + +# retrieve current folder to remove the config from the parent folder +thisFolder=`echo $0 | replace "env/stop-sftp-atmoz.sh" ""` + +if [ -z "$thisFolder" ]; then + thisFolder="." +fi; + +# stopping and removing docker containers +for container in `cat $thisFolder/dockerContainerAtmoz.$EXECUTOR_NUMBER.sftp`; do + echo "Stopping and removing docker container $container" + # kills running container and removes it + docker rm -f $container +done; + +# cleanup +rm $thisFolder/config.sftp.php +rm $thisFolder/dockerContainerAtmoz.$EXECUTOR_NUMBER.sftp + diff --git a/apps/files_external/tests/owncloudfunctions.php b/apps/files_external/tests/owncloudfunctions.php index de7bf3eff2b..0135c4618a3 100644 --- a/apps/files_external/tests/owncloudfunctions.php +++ b/apps/files_external/tests/owncloudfunctions.php @@ -81,6 +81,14 @@ class OwnCloudFunctions extends \Test\TestCase { ), 'http://testhost/testroot/remote.php/webdav/subdir/', ), + array( + array( + 'host' => 'http://testhost/testroot/', + 'root' => '/subdir', + 'secure' => false + ), + 'http://testhost/testroot/remote.php/webdav/subdir/', + ), ); } diff --git a/apps/files_sharing/l10n/sl.js b/apps/files_sharing/l10n/sl.js index a8b8a1ada0a..0e16dfaf48c 100644 --- a/apps/files_sharing/l10n/sl.js +++ b/apps/files_sharing/l10n/sl.js @@ -55,6 +55,7 @@ OC.L10N.register( "Download" : "Prejmi", "Download %s" : "Prejmi %s", "Direct link" : "Neposredna povezava", + "Federated Cloud Sharing" : "Upravljana souporaba oblaka", "Allow users on this server to send shares to other servers" : "Dovoli uporabnikom tega strežnika pošiljanje map za souporabo na druge strežnike.", "Allow users on this server to receive shares from other servers" : "Dovoli uporabnikom tega strežnika sprejemanje map za souporabo z drugih strežnikov." }, diff --git a/apps/files_sharing/l10n/sl.json b/apps/files_sharing/l10n/sl.json index acb9d153061..6bd7181561a 100644 --- a/apps/files_sharing/l10n/sl.json +++ b/apps/files_sharing/l10n/sl.json @@ -53,6 +53,7 @@ "Download" : "Prejmi", "Download %s" : "Prejmi %s", "Direct link" : "Neposredna povezava", + "Federated Cloud Sharing" : "Upravljana souporaba oblaka", "Allow users on this server to send shares to other servers" : "Dovoli uporabnikom tega strežnika pošiljanje map za souporabo na druge strežnike.", "Allow users on this server to receive shares from other servers" : "Dovoli uporabnikom tega strežnika sprejemanje map za souporabo z drugih strežnikov." },"pluralForm" :"nplurals=4; plural=(n%100==1 ? 0 : n%100==2 ? 1 : n%100==3 || n%100==4 ? 2 : 3);" diff --git a/apps/files_sharing/publicwebdav.php b/apps/files_sharing/publicwebdav.php index 30c8588ee3f..e96dabbdd3f 100644 --- a/apps/files_sharing/publicwebdav.php +++ b/apps/files_sharing/publicwebdav.php @@ -34,26 +34,24 @@ OC_Util::obEnd(); // Backends $authBackend = new OCA\Files_Sharing\Connector\PublicAuth(\OC::$server->getConfig()); -$lockBackend = new OC_Connector_Sabre_Locks(); -$requestBackend = new OC_Connector_Sabre_Request(); // Fire up server $objectTree = new \OC\Connector\Sabre\ObjectTree(); -$server = new OC_Connector_Sabre_Server($objectTree); -$server->httpRequest = $requestBackend; +$server = new \OC\Connector\Sabre\Server($objectTree); +// Set URL explicitly due to reverse-proxy situations +$server->httpRequest->setUrl(\OC::$server->getRequest()->getRequestUri()); $server->setBaseUri($baseuri); // Load plugins $defaults = new OC_Defaults(); $server->addPlugin(new \Sabre\DAV\Auth\Plugin($authBackend, $defaults->getName())); -$server->addPlugin(new \Sabre\DAV\Locks\Plugin($lockBackend)); $server->addPlugin(new \Sabre\DAV\Browser\Plugin(false)); // Show something in the Browser, but no upload -$server->addPlugin(new OC_Connector_Sabre_FilesPlugin()); -$server->addPlugin(new OC_Connector_Sabre_MaintenancePlugin()); -$server->addPlugin(new OC_Connector_Sabre_ExceptionLoggerPlugin('webdav')); +$server->addPlugin(new \OC\Connector\Sabre\FilesPlugin($objectTree)); +$server->addPlugin(new \OC\Connector\Sabre\MaintenancePlugin()); +$server->addPlugin(new \OC\Connector\Sabre\ExceptionLoggerPlugin('webdav')); // wait with registering these until auth is handled and the filesystem is setup -$server->subscribeEvent('beforeMethod', function () use ($server, $objectTree, $authBackend) { +$server->on('beforeMethod', function () use ($server, $objectTree, $authBackend) { $share = $authBackend->getShare(); $owner = $share['uid_owner']; $isWritable = $share['permissions'] & (\OCP\Constants::PERMISSION_UPDATE | \OCP\Constants::PERMISSION_CREATE); @@ -74,14 +72,14 @@ $server->subscribeEvent('beforeMethod', function () use ($server, $objectTree, $ // Create ownCloud Dir if ($rootInfo->getType() === 'dir') { - $root = new OC_Connector_Sabre_Directory($view, $rootInfo); + $root = new \OC\Connector\Sabre\Directory($view, $rootInfo); } else { - $root = new OC_Connector_Sabre_File($view, $rootInfo); + $root = new \OC\Connector\Sabre\File($view, $rootInfo); } $mountManager = \OC\Files\Filesystem::getMountManager(); $objectTree->init($root, $view, $mountManager); - $server->addPlugin(new OC_Connector_Sabre_QuotaPlugin($view)); + $server->addPlugin(new \OC\Connector\Sabre\QuotaPlugin($view)); }, 30); // priority 30: after auth (10) and acl(20), before lock(50) and handling the request // And off we go! diff --git a/apps/user_ldap/group_ldap.php b/apps/user_ldap/group_ldap.php index 1f03a81a759..7073700cfe1 100644 --- a/apps/user_ldap/group_ldap.php +++ b/apps/user_ldap/group_ldap.php @@ -254,32 +254,71 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { } /** - * returns a list of users that have the given group as primary group + * returns a filter for a "users in primary group" search or count operation * * @param string $groupDN - * @param $limit - * @param int $offset - * @return string[] + * @param string $search + * @return string + * @throws \Exception */ - public function getUsersInPrimaryGroup($groupDN, $limit = -1, $offset = 0) { + private function prepareFilterForUsersInPrimaryGroup($groupDN, $search = '') { $groupID = $this->getGroupPrimaryGroupID($groupDN); if($groupID === false) { - return array(); + throw new \Exception('Not a valid group'); } - $filter = $this->access->combineFilterWithAnd(array( - $this->access->connection->ldapUserFilter, - 'primaryGroupID=' . $groupID - )); + $filterParts = []; + $filterParts[] = $this->access->getFilterForUserCount(); + if(!empty($search)) { + $filterParts[] = $this->access->getFilterPartForUserSearch($search); + } + $filterParts[] = 'primaryGroupID=' . $groupID; + + $filter = $this->access->combineFilterWithAnd($filterParts); - $users = $this->access->fetchListOfUsers( - $filter, - array($this->access->connection->ldapUserDisplayName, 'dn'), - $limit, - $offset - ); + return $filter; + } + + /** + * returns a list of users that have the given group as primary group + * + * @param string $groupDN + * @param string $search + * @param int $limit + * @param int $offset + * @return string[] + */ + public function getUsersInPrimaryGroup($groupDN, $search = '', $limit = -1, $offset = 0) { + try { + $filter = $this->prepareFilterForUsersInPrimaryGroup($groupDN, $search); + return $this->access->fetchListOfUsers( + $filter, + array($this->access->connection->ldapUserDisplayName, 'dn'), + $limit, + $offset + ); + } catch (\Exception $e) { + return array(); + } + } - return $users; + /** + * returns the number of users that have the given group as primary group + * + * @param string $groupDN + * @param string $search + * @param int $limit + * @param int $offset + * @return int + */ + public function countUsersInPrimaryGroup($groupDN, $search = '', $limit = -1, $offset = 0) { + try { + $filter = $this->prepareFilterForUsersInPrimaryGroup($groupDN, $search); + $users = $this->access->countUsers($filter, array('dn'), $limit, $offset); + return (int)$users; + } catch (\Exception $e) { + return 0; + } } /** @@ -410,6 +449,7 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { if(!$this->groupExists($gid)) { return array(); } + $search = $this->access->escapeFilterPart($search, true); $cacheKey = 'usersInGroup-'.$gid.'-'.$search.'-'.$limit.'-'.$offset; // check for cache of the exact query $groupUsers = $this->access->connection->getFromCache($cacheKey); @@ -478,7 +518,7 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { $groupUsers = array_slice($groupUsers, $offset, $limit); //and get users that have the group as primary - $primaryUsers = $this->getUsersInPrimaryGroup($groupDN, $limit, $offset); + $primaryUsers = $this->getUsersInPrimaryGroup($groupDN, $search, $limit, $offset); $groupUsers = array_unique(array_merge($groupUsers, $primaryUsers)); $this->access->connection->writeToCache($cacheKey, $groupUsers); @@ -517,10 +557,13 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { } if(empty($search)) { - $groupUsers = count($members); + $primaryUsers = $this->countUsersInPrimaryGroup($groupDN, ''); + $groupUsers = count($members) + $primaryUsers; + $this->access->connection->writeToCache($cacheKey, $groupUsers); return $groupUsers; } + $search = $this->access->escapeFilterPart($search, true); $isMemberUid = (strtolower($this->access->connection->ldapGroupMemberAssocAttr) === 'memberuid'); @@ -562,10 +605,9 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { } //and get users that have the group as primary - $primaryUsers = $this->getUsersInPrimaryGroup($groupDN); - $groupUsers = array_unique(array_merge($groupUsers, $primaryUsers)); + $primaryUsers = $this->countUsersInPrimaryGroup($groupDN, $search); - return count($groupUsers); + return count($groupUsers) + $primaryUsers; } /** @@ -628,6 +670,7 @@ class GROUP_LDAP extends BackendUtility implements \OCP\GroupInterface { if(!$this->enabled) { return array(); } + $search = $this->access->escapeFilterPart($search, true); $pagingSize = $this->access->connection->ldapPagingSize; if ((! $this->access->connection->hasPagedResultSupport) || empty($pagingSize)) { diff --git a/apps/user_ldap/l10n/de.js b/apps/user_ldap/l10n/de.js index 2dab70d34af..93b7fc35c4c 100644 --- a/apps/user_ldap/l10n/de.js +++ b/apps/user_ldap/l10n/de.js @@ -4,37 +4,37 @@ OC.L10N.register( "Failed to clear the mappings." : "Löschen der Zuordnungen fehlgeschlagen.", "Failed to delete the server configuration" : "Löschen der Serverkonfiguration fehlgeschlagen", "The configuration is valid and the connection could be established!" : "Die Konfiguration ist gültig und die Verbindung konnte hergestellt werden!", - "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber die Verbindung ist fehlgeschlagen. Bitte überprüfe die Servereinstellungen und Anmeldeinformationen.", + "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber der LDAP-Bind ist fehlgeschlagen. Bitte überprüfe die Servereinstellungen und Anmeldeinformationen.", "The configuration is invalid. Please have a look at the logs for further details." : "Die Konfiguration ist ungültig. Weitere Details kannst Du in den Logdateien nachlesen.", - "No action specified" : "Keine Aktion spezifiziert", - "No configuration specified" : "Keine Konfiguration spezifiziert", - "No data specified" : "Keine Daten spezifiziert", + "No action specified" : "Keine Aktion angegeben", + "No configuration specified" : "Keine Konfiguration angegeben", + "No data specified" : "Keine Daten angegeben", " Could not set configuration %s" : "Die Konfiguration %s konnte nicht gesetzt werden", "Deletion failed" : "Löschen fehlgeschlagen", "Take over settings from recent server configuration?" : "Einstellungen von letzter Konfiguration übernehmen?", "Keep settings?" : "Einstellungen beibehalten?", "{nthServer}. Server" : "{nthServer}. - Server", - "Cannot add server configuration" : "Das Hinzufügen der Serverkonfiguration schlug fehl", + "Cannot add server configuration" : "Die Serverkonfiguration kann nicht hinzugefügt werden", "mappings cleared" : "Zuordnungen gelöscht", "Success" : "Erfolgreich", "Error" : "Fehler", - "Please specify a Base DN" : "Bitte einen Base-DN angeben", - "Could not determine Base DN" : "Base-DN konnte nicht festgestellt werden", - "Please specify the port" : "Bitte Port spezifizieren", + "Please specify a Base DN" : "Bitte einen Basis-DN angeben", + "Could not determine Base DN" : "Basis-DN konnte nicht ermittelt werden", + "Please specify the port" : "Bitte Port angeben", "Configuration OK" : "Konfiguration OK", "Configuration incorrect" : "Konfiguration nicht korrekt", "Configuration incomplete" : "Konfiguration nicht vollständig", - "Select groups" : "Wähle Gruppen aus", - "Select object classes" : "Objekt-Klassen auswählen", + "Select groups" : "Gruppen auswählen", + "Select object classes" : "Objektklassen auswählen", "Select attributes" : "Attribute auswählen", "Connection test succeeded" : "Verbindungstest erfolgreich", "Connection test failed" : "Verbindungstest fehlgeschlagen", - "Do you really want to delete the current Server Configuration?" : "Möchtest Du die aktuelle Serverkonfiguration wirklich löschen?", - "Confirm Deletion" : "Löschung bestätigen", + "Do you really want to delete the current Server Configuration?" : "Soll die aktuelle Serverkonfiguration wirklich gelöscht werden?", + "Confirm Deletion" : "Löschen bestätigen", "_%s group found_::_%s groups found_" : ["%s Gruppe gefunden","%s Gruppen gefunden"], "_%s user found_::_%s users found_" : ["%s Benutzer gefunden","%s Benutzer gefunden"], - "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Benutzeranzeigename-Attribut konnte nicht gefunden werden. Bitte gib es selber in den erweiterten LDAP-Einstellungen an.", - "Could not find the desired feature" : "Konnte die gewünschte Funktion nicht finden", + "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Anzeigename-Attribut des Benutzers konnte nicht gefunden werden. Bitte gib es in den erweiterten LDAP-Einstellungen selber an.", + "Could not find the desired feature" : "Die gewünschte Funktion konnte nicht gefunden werden", "Invalid Host" : "Ungültiger Host", "Server" : "Server", "User Filter" : "Nutzer-Filter", @@ -43,15 +43,15 @@ OC.L10N.register( "Save" : "Speichern", "Test Configuration" : "Testkonfiguration", "Help" : "Hilfe", - "Groups meeting these criteria are available in %s:" : "Gruppen-Versammlungen mit diesen Kriterien sind verfügbar in %s:", - "only those object classes:" : "Nur diese Objekt-Klassen:", - "only from those groups:" : "Nur von diesen Gruppen:", + "Groups meeting these criteria are available in %s:" : "Gruppen, auf die diese Kriterien zutreffen, sind verfügbar in %s:", + "only those object classes:" : "Nur diese Objektklassen:", + "only from those groups:" : "Nur aus diesen Gruppen:", "Edit raw filter instead" : "Original-Filter stattdessen bearbeiten", "Raw LDAP filter" : "Original LDAP-Filter", "The filter specifies which LDAP groups shall have access to the %s instance." : "Der Filter bestimmt, welche LDAP-Gruppen Zugriff auf die %s-Instanz haben sollen.", - "Test Filter" : "Test-Filter", + "Test Filter" : "Testfilter", "groups found" : "Gruppen gefunden", - "Users login with this attribute:" : "Nutzeranmeldung mit diesem Merkmal:", + "Users login with this attribute:" : "Nutzeranmeldung mit diesem Attribut:", "LDAP Username:" : "LDAP-Benutzername:", "LDAP Email Address:" : "LDAP-E-Mail-Adresse:", "Other Attributes:" : "Andere Attribute:", @@ -64,15 +64,15 @@ OC.L10N.register( "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Du kannst das Protokoll auslassen, außer wenn Du SSL benötigst. Beginne dann mit ldaps://", "Port" : "Port", "User DN" : "Benutzer-DN", - "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers für LDAP-Bind, z.B.: uid=agent,dc=example,dc=com. Für anonymen Zugriff lasse DN und Passwort leer.", + "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers, mit dem der LDAP-Bind durchgeführt werden soll, z.B. uid=agent,dc=example,dc=com. Für anonymen Zugriff lasse DN und Passwort leer.", "Password" : "Passwort", "For anonymous access, leave DN and Password empty." : "Lasse die Felder DN und Passwort für anonymen Zugang leer.", "One Base DN per line" : "Einen Basis-DN pro Zeile", - "You can specify Base DN for users and groups in the Advanced tab" : "Du kannst Basis-DN für Benutzer und Gruppen in dem \"Erweitert\"-Reiter konfigurieren", - "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser für größere Installationen, benötigt aber einiges an LDAP-Wissen.", - "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (erforderlich für große Verzeichnisse)", - "Limit %s access to users meeting these criteria:" : "Beschränken Sie den %s Zugriff auf die Benutzer-Sitzungen durch folgende Kriterien:", - "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter definiert welche LDAP-Benutzer Zugriff auf die %s Instanz haben sollen.", + "You can specify Base DN for users and groups in the Advanced tab" : "Du kannst Basis-DN für Benutzer und Gruppen im „Erweitert“-Reiter angeben", + "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser geeignet für größere Installationen, benötigt aber erweiterte LDAP-Kenntnisse.", + "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (empfohlen für große Verzeichnisse)", + "Limit %s access to users meeting these criteria:" : "Den %s-Zugriff auf Benutzer, die den folgenden Kriterien entsprechen, beschränken:", + "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter gibt an, welche LDAP-Benutzer Zugriff auf die %s-Instanz haben sollen.", "users found" : "Benutzer gefunden", "Saving" : "Speichern", "Back" : "Zurück", @@ -80,17 +80,17 @@ OC.L10N.register( "LDAP" : "LDAP", "Expert" : "Experte", "Advanced" : "Fortgeschritten", - "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann demzufolge zu unerwarteten Verhalten kommen. Bitte\ndeinen Systemadministator eine der beiden Anwendungen zu deaktivieren.", - "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte Deinen Systemadministrator das Modul zu installieren.", + "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann deshalb zu unerwartetem Systemverhalten kommen. Bitte kontaktiere Deinen Systemadministator und bitte um die Deaktivierung einer der beiden Anwendungen.", + "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte kontaktiere Deinen Systemadministrator und bitte um die Installation des Moduls.", "Connection Settings" : "Verbindungseinstellungen", "Configuration Active" : "Konfiguration aktiv", "When unchecked, this configuration will be skipped." : "Konfiguration wird übersprungen wenn deaktiviert", - "Backup (Replica) Host" : "Backup Host (Kopie)", + "Backup (Replica) Host" : "Backup von Host (Kopie) anlegen", "Give an optional backup host. It must be a replica of the main LDAP/AD server." : "Gib einen optionalen Backup Host an. Es muss sich um eine Kopie des Haupt LDAP/AD Servers handeln.", "Backup (Replica) Port" : "Backup Port", "Disable Main Server" : "Hauptserver deaktivieren", "Only connect to the replica server." : "Nur zum Replikat-Server verbinden.", - "Case insensitive LDAP server (Windows)" : "LDAP-Server (Windows - Groß- und Kleinschreibung bleibt unbeachtet)", + "Case insensitive LDAP server (Windows)" : "LDAP-Server ohne Unterscheidung von Groß-/Kleinschreibung (Windows)", "Turn off SSL certificate validation." : "Schalte die SSL-Zertifikatsprüfung aus.", "Not recommended, use it for testing only! If connection only works with this option, import the LDAP server's SSL certificate in your %s server." : "Nur für Testzwecke geeignet, sollte Standardmäßig nicht verwendet werden. Falls die Verbindung nur mit dieser Option funktioniert, importiere das SSL-Zertifikat des LDAP-Servers in deinen %s Server.", "Cache Time-To-Live" : "Speichere Time-To-Live zwischen", diff --git a/apps/user_ldap/l10n/de.json b/apps/user_ldap/l10n/de.json index b31dbbf38a7..2103a57a91b 100644 --- a/apps/user_ldap/l10n/de.json +++ b/apps/user_ldap/l10n/de.json @@ -2,37 +2,37 @@ "Failed to clear the mappings." : "Löschen der Zuordnungen fehlgeschlagen.", "Failed to delete the server configuration" : "Löschen der Serverkonfiguration fehlgeschlagen", "The configuration is valid and the connection could be established!" : "Die Konfiguration ist gültig und die Verbindung konnte hergestellt werden!", - "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber die Verbindung ist fehlgeschlagen. Bitte überprüfe die Servereinstellungen und Anmeldeinformationen.", + "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber der LDAP-Bind ist fehlgeschlagen. Bitte überprüfe die Servereinstellungen und Anmeldeinformationen.", "The configuration is invalid. Please have a look at the logs for further details." : "Die Konfiguration ist ungültig. Weitere Details kannst Du in den Logdateien nachlesen.", - "No action specified" : "Keine Aktion spezifiziert", - "No configuration specified" : "Keine Konfiguration spezifiziert", - "No data specified" : "Keine Daten spezifiziert", + "No action specified" : "Keine Aktion angegeben", + "No configuration specified" : "Keine Konfiguration angegeben", + "No data specified" : "Keine Daten angegeben", " Could not set configuration %s" : "Die Konfiguration %s konnte nicht gesetzt werden", "Deletion failed" : "Löschen fehlgeschlagen", "Take over settings from recent server configuration?" : "Einstellungen von letzter Konfiguration übernehmen?", "Keep settings?" : "Einstellungen beibehalten?", "{nthServer}. Server" : "{nthServer}. - Server", - "Cannot add server configuration" : "Das Hinzufügen der Serverkonfiguration schlug fehl", + "Cannot add server configuration" : "Die Serverkonfiguration kann nicht hinzugefügt werden", "mappings cleared" : "Zuordnungen gelöscht", "Success" : "Erfolgreich", "Error" : "Fehler", - "Please specify a Base DN" : "Bitte einen Base-DN angeben", - "Could not determine Base DN" : "Base-DN konnte nicht festgestellt werden", - "Please specify the port" : "Bitte Port spezifizieren", + "Please specify a Base DN" : "Bitte einen Basis-DN angeben", + "Could not determine Base DN" : "Basis-DN konnte nicht ermittelt werden", + "Please specify the port" : "Bitte Port angeben", "Configuration OK" : "Konfiguration OK", "Configuration incorrect" : "Konfiguration nicht korrekt", "Configuration incomplete" : "Konfiguration nicht vollständig", - "Select groups" : "Wähle Gruppen aus", - "Select object classes" : "Objekt-Klassen auswählen", + "Select groups" : "Gruppen auswählen", + "Select object classes" : "Objektklassen auswählen", "Select attributes" : "Attribute auswählen", "Connection test succeeded" : "Verbindungstest erfolgreich", "Connection test failed" : "Verbindungstest fehlgeschlagen", - "Do you really want to delete the current Server Configuration?" : "Möchtest Du die aktuelle Serverkonfiguration wirklich löschen?", - "Confirm Deletion" : "Löschung bestätigen", + "Do you really want to delete the current Server Configuration?" : "Soll die aktuelle Serverkonfiguration wirklich gelöscht werden?", + "Confirm Deletion" : "Löschen bestätigen", "_%s group found_::_%s groups found_" : ["%s Gruppe gefunden","%s Gruppen gefunden"], "_%s user found_::_%s users found_" : ["%s Benutzer gefunden","%s Benutzer gefunden"], - "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Benutzeranzeigename-Attribut konnte nicht gefunden werden. Bitte gib es selber in den erweiterten LDAP-Einstellungen an.", - "Could not find the desired feature" : "Konnte die gewünschte Funktion nicht finden", + "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Anzeigename-Attribut des Benutzers konnte nicht gefunden werden. Bitte gib es in den erweiterten LDAP-Einstellungen selber an.", + "Could not find the desired feature" : "Die gewünschte Funktion konnte nicht gefunden werden", "Invalid Host" : "Ungültiger Host", "Server" : "Server", "User Filter" : "Nutzer-Filter", @@ -41,15 +41,15 @@ "Save" : "Speichern", "Test Configuration" : "Testkonfiguration", "Help" : "Hilfe", - "Groups meeting these criteria are available in %s:" : "Gruppen-Versammlungen mit diesen Kriterien sind verfügbar in %s:", - "only those object classes:" : "Nur diese Objekt-Klassen:", - "only from those groups:" : "Nur von diesen Gruppen:", + "Groups meeting these criteria are available in %s:" : "Gruppen, auf die diese Kriterien zutreffen, sind verfügbar in %s:", + "only those object classes:" : "Nur diese Objektklassen:", + "only from those groups:" : "Nur aus diesen Gruppen:", "Edit raw filter instead" : "Original-Filter stattdessen bearbeiten", "Raw LDAP filter" : "Original LDAP-Filter", "The filter specifies which LDAP groups shall have access to the %s instance." : "Der Filter bestimmt, welche LDAP-Gruppen Zugriff auf die %s-Instanz haben sollen.", - "Test Filter" : "Test-Filter", + "Test Filter" : "Testfilter", "groups found" : "Gruppen gefunden", - "Users login with this attribute:" : "Nutzeranmeldung mit diesem Merkmal:", + "Users login with this attribute:" : "Nutzeranmeldung mit diesem Attribut:", "LDAP Username:" : "LDAP-Benutzername:", "LDAP Email Address:" : "LDAP-E-Mail-Adresse:", "Other Attributes:" : "Andere Attribute:", @@ -62,15 +62,15 @@ "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Du kannst das Protokoll auslassen, außer wenn Du SSL benötigst. Beginne dann mit ldaps://", "Port" : "Port", "User DN" : "Benutzer-DN", - "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers für LDAP-Bind, z.B.: uid=agent,dc=example,dc=com. Für anonymen Zugriff lasse DN und Passwort leer.", + "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers, mit dem der LDAP-Bind durchgeführt werden soll, z.B. uid=agent,dc=example,dc=com. Für anonymen Zugriff lasse DN und Passwort leer.", "Password" : "Passwort", "For anonymous access, leave DN and Password empty." : "Lasse die Felder DN und Passwort für anonymen Zugang leer.", "One Base DN per line" : "Einen Basis-DN pro Zeile", - "You can specify Base DN for users and groups in the Advanced tab" : "Du kannst Basis-DN für Benutzer und Gruppen in dem \"Erweitert\"-Reiter konfigurieren", - "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser für größere Installationen, benötigt aber einiges an LDAP-Wissen.", - "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (erforderlich für große Verzeichnisse)", - "Limit %s access to users meeting these criteria:" : "Beschränken Sie den %s Zugriff auf die Benutzer-Sitzungen durch folgende Kriterien:", - "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter definiert welche LDAP-Benutzer Zugriff auf die %s Instanz haben sollen.", + "You can specify Base DN for users and groups in the Advanced tab" : "Du kannst Basis-DN für Benutzer und Gruppen im „Erweitert“-Reiter angeben", + "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser geeignet für größere Installationen, benötigt aber erweiterte LDAP-Kenntnisse.", + "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (empfohlen für große Verzeichnisse)", + "Limit %s access to users meeting these criteria:" : "Den %s-Zugriff auf Benutzer, die den folgenden Kriterien entsprechen, beschränken:", + "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter gibt an, welche LDAP-Benutzer Zugriff auf die %s-Instanz haben sollen.", "users found" : "Benutzer gefunden", "Saving" : "Speichern", "Back" : "Zurück", @@ -78,17 +78,17 @@ "LDAP" : "LDAP", "Expert" : "Experte", "Advanced" : "Fortgeschritten", - "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann demzufolge zu unerwarteten Verhalten kommen. Bitte\ndeinen Systemadministator eine der beiden Anwendungen zu deaktivieren.", - "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte Deinen Systemadministrator das Modul zu installieren.", + "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann deshalb zu unerwartetem Systemverhalten kommen. Bitte kontaktiere Deinen Systemadministator und bitte um die Deaktivierung einer der beiden Anwendungen.", + "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte kontaktiere Deinen Systemadministrator und bitte um die Installation des Moduls.", "Connection Settings" : "Verbindungseinstellungen", "Configuration Active" : "Konfiguration aktiv", "When unchecked, this configuration will be skipped." : "Konfiguration wird übersprungen wenn deaktiviert", - "Backup (Replica) Host" : "Backup Host (Kopie)", + "Backup (Replica) Host" : "Backup von Host (Kopie) anlegen", "Give an optional backup host. It must be a replica of the main LDAP/AD server." : "Gib einen optionalen Backup Host an. Es muss sich um eine Kopie des Haupt LDAP/AD Servers handeln.", "Backup (Replica) Port" : "Backup Port", "Disable Main Server" : "Hauptserver deaktivieren", "Only connect to the replica server." : "Nur zum Replikat-Server verbinden.", - "Case insensitive LDAP server (Windows)" : "LDAP-Server (Windows - Groß- und Kleinschreibung bleibt unbeachtet)", + "Case insensitive LDAP server (Windows)" : "LDAP-Server ohne Unterscheidung von Groß-/Kleinschreibung (Windows)", "Turn off SSL certificate validation." : "Schalte die SSL-Zertifikatsprüfung aus.", "Not recommended, use it for testing only! If connection only works with this option, import the LDAP server's SSL certificate in your %s server." : "Nur für Testzwecke geeignet, sollte Standardmäßig nicht verwendet werden. Falls die Verbindung nur mit dieser Option funktioniert, importiere das SSL-Zertifikat des LDAP-Servers in deinen %s Server.", "Cache Time-To-Live" : "Speichere Time-To-Live zwischen", diff --git a/apps/user_ldap/l10n/de_DE.js b/apps/user_ldap/l10n/de_DE.js index 2e7ce537284..186d0d49937 100644 --- a/apps/user_ldap/l10n/de_DE.js +++ b/apps/user_ldap/l10n/de_DE.js @@ -4,37 +4,37 @@ OC.L10N.register( "Failed to clear the mappings." : "Löschen der Zuordnungen fehlgeschlagen.", "Failed to delete the server configuration" : "Löschen der Serverkonfiguration fehlgeschlagen", "The configuration is valid and the connection could be established!" : "Die Konfiguration ist gültig und die Verbindung konnte hergestellt werden!", - "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber die Verbindung ist fehlgeschlagen. Bitte überprüfen Sie die Servereinstellungen und die Anmeldeinformationen.", + "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber der LDAP-Bind ist fehlgeschlagen. Bitte überprüfen Sie die Servereinstellungen und die Anmeldeinformationen.", "The configuration is invalid. Please have a look at the logs for further details." : "Die Konfiguration ist ungültig. Weitere Details können Sie in den Logdateien nachlesen.", - "No action specified" : "Keine Aktion spezifiziert", - "No configuration specified" : "Keine Konfiguration spezifiziert", - "No data specified" : "Keine Daten spezifiziert", + "No action specified" : "Keine Aktion angegeben", + "No configuration specified" : "Keine Konfiguration angegeben", + "No data specified" : "Keine Daten angegeben", " Could not set configuration %s" : "Die Konfiguration %s konnte nicht gesetzt werden", "Deletion failed" : "Löschen fehlgeschlagen", "Take over settings from recent server configuration?" : "Einstellungen von letzter Konfiguration übernehmen?", "Keep settings?" : "Einstellungen beibehalten?", "{nthServer}. Server" : "{nthServer}. - Server", - "Cannot add server configuration" : "Das Hinzufügen der Serverkonfiguration schlug fehl", + "Cannot add server configuration" : "Die Serverkonfiguration kann nicht hinzugefügt werden", "mappings cleared" : "Zuordnungen gelöscht", "Success" : "Erfolg", "Error" : "Fehler", - "Please specify a Base DN" : "Bitte einen Base-DN angeben", - "Could not determine Base DN" : "Base-DN konnte nicht festgestellt werden", - "Please specify the port" : "Bitte Port spezifizieren", + "Please specify a Base DN" : "Bitte einen Basis-DN angeben", + "Could not determine Base DN" : "Basis-DN konnte nicht ermittelt werden", + "Please specify the port" : "Bitte Port angeben", "Configuration OK" : "Konfiguration OK", "Configuration incorrect" : "Konfiguration nicht korrekt", "Configuration incomplete" : "Konfiguration nicht vollständig", - "Select groups" : "Wähle Gruppen", - "Select object classes" : "Objekt-Klassen auswählen", + "Select groups" : "Gruppen auswählen", + "Select object classes" : "Objektklassen auswählen", "Select attributes" : "Attribute auswählen", "Connection test succeeded" : "Verbindungstest erfolgreich", "Connection test failed" : "Verbindungstest fehlgeschlagen", - "Do you really want to delete the current Server Configuration?" : "Möchten Sie die aktuelle Serverkonfiguration wirklich löschen?", - "Confirm Deletion" : "Löschung bestätigen", + "Do you really want to delete the current Server Configuration?" : "Soll die aktuelle Serverkonfiguration wirklich gelöscht werden?", + "Confirm Deletion" : "Löschen bestätigen", "_%s group found_::_%s groups found_" : ["%s Gruppe gefunden","%s Gruppen gefunden"], "_%s user found_::_%s users found_" : ["%s Benutzer gefunden","%s Benutzer gefunden"], - "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Benutzeranzeigename-Attribut konnte nicht gefunden werden. Bitte geben Sie es selber in den erweiterten LDAP-Einstellungen an.", - "Could not find the desired feature" : "Konnte die gewünschte Funktion nicht finden", + "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Anzeigename-Attribut des Benutzers konnte nicht gefunden werden. Bitte geben Sie es in den erweiterten LDAP-Einstellungen selber an.", + "Could not find the desired feature" : "Die gewünschte Funktion konnte nicht gefunden werden", "Invalid Host" : "Ungültiger Host", "Server" : "Server", "User Filter" : "Benutzer-Filter", @@ -43,15 +43,15 @@ OC.L10N.register( "Save" : "Speichern", "Test Configuration" : "Testkonfiguration", "Help" : "Hilfe", - "Groups meeting these criteria are available in %s:" : "Gruppen-Versammlungen mit diesen Kriterien sind verfügbar in %s:", - "only those object classes:" : "Nur diese Objekt-Klassen:", - "only from those groups:" : "Nur von diesen Gruppen:", + "Groups meeting these criteria are available in %s:" : "Gruppen, auf die diese Kriterien zutreffen, sind verfügbar in %s:", + "only those object classes:" : "Nur diese Objektklassen:", + "only from those groups:" : "Nur aus diesen Gruppen:", "Edit raw filter instead" : "Original-Filter stattdessen bearbeiten", "Raw LDAP filter" : "Original LDAP-Filter", "The filter specifies which LDAP groups shall have access to the %s instance." : "Der Filter bestimmt, welche LDAP-Gruppen Zugriff auf die %s-Instanz haben sollen.", - "Test Filter" : "Test-Filter", + "Test Filter" : "Testfilter", "groups found" : "Gruppen gefunden", - "Users login with this attribute:" : "Benutzeranmeldung mit diesem Merkmal:", + "Users login with this attribute:" : "Benutzeranmeldung mit diesem Attribut:", "LDAP Username:" : "LDAP-Benutzername:", "LDAP Email Address:" : "LDAP-E-Mail-Adresse:", "Other Attributes:" : "Andere Attribute:", @@ -64,15 +64,15 @@ OC.L10N.register( "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Sie können das Protokoll auslassen, außer wenn Sie SSL benötigen. Beginnen Sie dann mit ldaps://", "Port" : "Port", "User DN" : "Benutzer-DN", - "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers für LDAP-Bind, z.B.: uid=agent,dc=example,dc=com. Für einen anonymen Zugriff lassen Sie DN und Passwort leer.", + "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers, mit dem der LDAP-Bind durchgeführt werden soll, z.B. uid=agent,dc=example,dc=com. Für einen anonymen Zugriff lassen Sie DN und Passwort leer.", "Password" : "Passwort", "For anonymous access, leave DN and Password empty." : "Lassen Sie die Felder DN und Passwort für einen anonymen Zugang leer.", "One Base DN per line" : "Einen Basis-DN pro Zeile", - "You can specify Base DN for users and groups in the Advanced tab" : "Sie können Basis-DN für Benutzer und Gruppen in dem \"Erweitert\"-Reiter konfigurieren", - "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser für größere Installationen, benötigt aber einiges an LDAP-Wissen.", - "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (erforderlich für große Verzeichnisse)", - "Limit %s access to users meeting these criteria:" : "Beschränken Sie den %s Zugriff auf die Benutzer-Sitzungen durch folgende Kriterien:", - "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter definiert welche LDAP-Benutzer Zugriff auf die %s Instanz haben sollen.", + "You can specify Base DN for users and groups in the Advanced tab" : "Sie können Basis-DN für Benutzer und Gruppen im „Erweitert“-Reiter angeben", + "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser geeignet für größere Installationen, benötigt aber erweiterte LDAP-Kenntnisse.", + "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (empfohlen für große Verzeichnisse)", + "Limit %s access to users meeting these criteria:" : "Den %s-Zugriff auf Benutzer, die den folgenden Kriterien entsprechen, beschränken:", + "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter gibt an, welche LDAP-Benutzer Zugriff auf die %s-Instanz haben sollen.", "users found" : "Benutzer gefunden", "Saving" : "Speichern", "Back" : "Zurück", @@ -80,17 +80,17 @@ OC.L10N.register( "LDAP" : "LDAP", "Expert" : "Experte", "Advanced" : "Fortgeschritten", - "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann demzufolge zu unerwarteten Verhalten kommen. Bitten Sie Ihren Systemadministator eine der beiden Anwendungen zu deaktivieren.", - "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitten Sie Ihren Systemadministrator das Modul zu installieren.", + "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann deshalb zu unerwartetem Systemverhalten kommen. Bitten kontaktieren Sie Ihren Systemadministator und bitten Sie um die Deaktivierung einer der beiden Anwendungen.", + "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte kontaktieren Sie Ihren Systemadministrator und bitten Sie um die Installation des Moduls.", "Connection Settings" : "Verbindungseinstellungen", "Configuration Active" : "Konfiguration aktiv", "When unchecked, this configuration will be skipped." : "Wenn nicht angehakt, wird diese Konfiguration übersprungen.", - "Backup (Replica) Host" : "Backup Host (Kopie)", + "Backup (Replica) Host" : "Backup von Host (Kopie) anlegen", "Give an optional backup host. It must be a replica of the main LDAP/AD server." : "Geben Sie einen optionalen Backup Host an. Es muss sich um eine Kopie des Haupt LDAP/AD Servers handeln.", "Backup (Replica) Port" : "Backup Port", "Disable Main Server" : "Hauptserver deaktivieren", "Only connect to the replica server." : "Nur zum Replikat-Server verbinden.", - "Case insensitive LDAP server (Windows)" : "LDAP-Server (Windows: Groß- und Kleinschreibung bleibt unbeachtet)", + "Case insensitive LDAP server (Windows)" : "LDAP-Server ohne Unterscheidung von Groß-/Kleinschreibung (Windows)", "Turn off SSL certificate validation." : "Schalten Sie die SSL-Zertifikatsprüfung aus.", "Not recommended, use it for testing only! If connection only works with this option, import the LDAP server's SSL certificate in your %s server." : "Nur für Testzwecke geeignet, sollte Standardmäßig nicht verwendet werden. Falls die Verbindung nur mit dieser Option funktioniert, importieren Sie das SSL-Zertifikat des LDAP-Servers in Ihren %s Server.", "Cache Time-To-Live" : "Speichere Time-To-Live zwischen", diff --git a/apps/user_ldap/l10n/de_DE.json b/apps/user_ldap/l10n/de_DE.json index d847911a7bd..eb641284c9d 100644 --- a/apps/user_ldap/l10n/de_DE.json +++ b/apps/user_ldap/l10n/de_DE.json @@ -2,37 +2,37 @@ "Failed to clear the mappings." : "Löschen der Zuordnungen fehlgeschlagen.", "Failed to delete the server configuration" : "Löschen der Serverkonfiguration fehlgeschlagen", "The configuration is valid and the connection could be established!" : "Die Konfiguration ist gültig und die Verbindung konnte hergestellt werden!", - "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber die Verbindung ist fehlgeschlagen. Bitte überprüfen Sie die Servereinstellungen und die Anmeldeinformationen.", + "The configuration is valid, but the Bind failed. Please check the server settings and credentials." : "Die Konfiguration ist gültig, aber der LDAP-Bind ist fehlgeschlagen. Bitte überprüfen Sie die Servereinstellungen und die Anmeldeinformationen.", "The configuration is invalid. Please have a look at the logs for further details." : "Die Konfiguration ist ungültig. Weitere Details können Sie in den Logdateien nachlesen.", - "No action specified" : "Keine Aktion spezifiziert", - "No configuration specified" : "Keine Konfiguration spezifiziert", - "No data specified" : "Keine Daten spezifiziert", + "No action specified" : "Keine Aktion angegeben", + "No configuration specified" : "Keine Konfiguration angegeben", + "No data specified" : "Keine Daten angegeben", " Could not set configuration %s" : "Die Konfiguration %s konnte nicht gesetzt werden", "Deletion failed" : "Löschen fehlgeschlagen", "Take over settings from recent server configuration?" : "Einstellungen von letzter Konfiguration übernehmen?", "Keep settings?" : "Einstellungen beibehalten?", "{nthServer}. Server" : "{nthServer}. - Server", - "Cannot add server configuration" : "Das Hinzufügen der Serverkonfiguration schlug fehl", + "Cannot add server configuration" : "Die Serverkonfiguration kann nicht hinzugefügt werden", "mappings cleared" : "Zuordnungen gelöscht", "Success" : "Erfolg", "Error" : "Fehler", - "Please specify a Base DN" : "Bitte einen Base-DN angeben", - "Could not determine Base DN" : "Base-DN konnte nicht festgestellt werden", - "Please specify the port" : "Bitte Port spezifizieren", + "Please specify a Base DN" : "Bitte einen Basis-DN angeben", + "Could not determine Base DN" : "Basis-DN konnte nicht ermittelt werden", + "Please specify the port" : "Bitte Port angeben", "Configuration OK" : "Konfiguration OK", "Configuration incorrect" : "Konfiguration nicht korrekt", "Configuration incomplete" : "Konfiguration nicht vollständig", - "Select groups" : "Wähle Gruppen", - "Select object classes" : "Objekt-Klassen auswählen", + "Select groups" : "Gruppen auswählen", + "Select object classes" : "Objektklassen auswählen", "Select attributes" : "Attribute auswählen", "Connection test succeeded" : "Verbindungstest erfolgreich", "Connection test failed" : "Verbindungstest fehlgeschlagen", - "Do you really want to delete the current Server Configuration?" : "Möchten Sie die aktuelle Serverkonfiguration wirklich löschen?", - "Confirm Deletion" : "Löschung bestätigen", + "Do you really want to delete the current Server Configuration?" : "Soll die aktuelle Serverkonfiguration wirklich gelöscht werden?", + "Confirm Deletion" : "Löschen bestätigen", "_%s group found_::_%s groups found_" : ["%s Gruppe gefunden","%s Gruppen gefunden"], "_%s user found_::_%s users found_" : ["%s Benutzer gefunden","%s Benutzer gefunden"], - "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Benutzeranzeigename-Attribut konnte nicht gefunden werden. Bitte geben Sie es selber in den erweiterten LDAP-Einstellungen an.", - "Could not find the desired feature" : "Konnte die gewünschte Funktion nicht finden", + "Could not detect user display name attribute. Please specify it yourself in advanced ldap settings." : "Das Anzeigename-Attribut des Benutzers konnte nicht gefunden werden. Bitte geben Sie es in den erweiterten LDAP-Einstellungen selber an.", + "Could not find the desired feature" : "Die gewünschte Funktion konnte nicht gefunden werden", "Invalid Host" : "Ungültiger Host", "Server" : "Server", "User Filter" : "Benutzer-Filter", @@ -41,15 +41,15 @@ "Save" : "Speichern", "Test Configuration" : "Testkonfiguration", "Help" : "Hilfe", - "Groups meeting these criteria are available in %s:" : "Gruppen-Versammlungen mit diesen Kriterien sind verfügbar in %s:", - "only those object classes:" : "Nur diese Objekt-Klassen:", - "only from those groups:" : "Nur von diesen Gruppen:", + "Groups meeting these criteria are available in %s:" : "Gruppen, auf die diese Kriterien zutreffen, sind verfügbar in %s:", + "only those object classes:" : "Nur diese Objektklassen:", + "only from those groups:" : "Nur aus diesen Gruppen:", "Edit raw filter instead" : "Original-Filter stattdessen bearbeiten", "Raw LDAP filter" : "Original LDAP-Filter", "The filter specifies which LDAP groups shall have access to the %s instance." : "Der Filter bestimmt, welche LDAP-Gruppen Zugriff auf die %s-Instanz haben sollen.", - "Test Filter" : "Test-Filter", + "Test Filter" : "Testfilter", "groups found" : "Gruppen gefunden", - "Users login with this attribute:" : "Benutzeranmeldung mit diesem Merkmal:", + "Users login with this attribute:" : "Benutzeranmeldung mit diesem Attribut:", "LDAP Username:" : "LDAP-Benutzername:", "LDAP Email Address:" : "LDAP-E-Mail-Adresse:", "Other Attributes:" : "Andere Attribute:", @@ -62,15 +62,15 @@ "You can omit the protocol, except you require SSL. Then start with ldaps://" : "Sie können das Protokoll auslassen, außer wenn Sie SSL benötigen. Beginnen Sie dann mit ldaps://", "Port" : "Port", "User DN" : "Benutzer-DN", - "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers für LDAP-Bind, z.B.: uid=agent,dc=example,dc=com. Für einen anonymen Zugriff lassen Sie DN und Passwort leer.", + "The DN of the client user with which the bind shall be done, e.g. uid=agent,dc=example,dc=com. For anonymous access, leave DN and Password empty." : "Der DN des Benutzers, mit dem der LDAP-Bind durchgeführt werden soll, z.B. uid=agent,dc=example,dc=com. Für einen anonymen Zugriff lassen Sie DN und Passwort leer.", "Password" : "Passwort", "For anonymous access, leave DN and Password empty." : "Lassen Sie die Felder DN und Passwort für einen anonymen Zugang leer.", "One Base DN per line" : "Einen Basis-DN pro Zeile", - "You can specify Base DN for users and groups in the Advanced tab" : "Sie können Basis-DN für Benutzer und Gruppen in dem \"Erweitert\"-Reiter konfigurieren", - "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser für größere Installationen, benötigt aber einiges an LDAP-Wissen.", - "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (erforderlich für große Verzeichnisse)", - "Limit %s access to users meeting these criteria:" : "Beschränken Sie den %s Zugriff auf die Benutzer-Sitzungen durch folgende Kriterien:", - "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter definiert welche LDAP-Benutzer Zugriff auf die %s Instanz haben sollen.", + "You can specify Base DN for users and groups in the Advanced tab" : "Sie können Basis-DN für Benutzer und Gruppen im „Erweitert“-Reiter angeben", + "Avoids automatic LDAP requests. Better for bigger setups, but requires some LDAP knowledge." : "Verhindert automatische LDAP-Anfragen. Besser geeignet für größere Installationen, benötigt aber erweiterte LDAP-Kenntnisse.", + "Manually enter LDAP filters (recommended for large directories)" : "LDAP-Filter manuell eingeben (empfohlen für große Verzeichnisse)", + "Limit %s access to users meeting these criteria:" : "Den %s-Zugriff auf Benutzer, die den folgenden Kriterien entsprechen, beschränken:", + "The filter specifies which LDAP users shall have access to the %s instance." : "Der Filter gibt an, welche LDAP-Benutzer Zugriff auf die %s-Instanz haben sollen.", "users found" : "Benutzer gefunden", "Saving" : "Speichern", "Back" : "Zurück", @@ -78,17 +78,17 @@ "LDAP" : "LDAP", "Expert" : "Experte", "Advanced" : "Fortgeschritten", - "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann demzufolge zu unerwarteten Verhalten kommen. Bitten Sie Ihren Systemadministator eine der beiden Anwendungen zu deaktivieren.", - "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitten Sie Ihren Systemadministrator das Modul zu installieren.", + "<b>Warning:</b> Apps user_ldap and user_webdavauth are incompatible. You may experience unexpected behavior. Please ask your system administrator to disable one of them." : "<b>Warnung:</b> Die Anwendungen user_ldap und user_webdavauth sind inkompatibel. Es kann deshalb zu unerwartetem Systemverhalten kommen. Bitten kontaktieren Sie Ihren Systemadministator und bitten Sie um die Deaktivierung einer der beiden Anwendungen.", + "<b>Warning:</b> The PHP LDAP module is not installed, the backend will not work. Please ask your system administrator to install it." : "<b>Warnung:</b> Da das PHP-Modul für LDAP nicht installiert ist, wird das Backend nicht funktionieren. Bitte kontaktieren Sie Ihren Systemadministrator und bitten Sie um die Installation des Moduls.", "Connection Settings" : "Verbindungseinstellungen", "Configuration Active" : "Konfiguration aktiv", "When unchecked, this configuration will be skipped." : "Wenn nicht angehakt, wird diese Konfiguration übersprungen.", - "Backup (Replica) Host" : "Backup Host (Kopie)", + "Backup (Replica) Host" : "Backup von Host (Kopie) anlegen", "Give an optional backup host. It must be a replica of the main LDAP/AD server." : "Geben Sie einen optionalen Backup Host an. Es muss sich um eine Kopie des Haupt LDAP/AD Servers handeln.", "Backup (Replica) Port" : "Backup Port", "Disable Main Server" : "Hauptserver deaktivieren", "Only connect to the replica server." : "Nur zum Replikat-Server verbinden.", - "Case insensitive LDAP server (Windows)" : "LDAP-Server (Windows: Groß- und Kleinschreibung bleibt unbeachtet)", + "Case insensitive LDAP server (Windows)" : "LDAP-Server ohne Unterscheidung von Groß-/Kleinschreibung (Windows)", "Turn off SSL certificate validation." : "Schalten Sie die SSL-Zertifikatsprüfung aus.", "Not recommended, use it for testing only! If connection only works with this option, import the LDAP server's SSL certificate in your %s server." : "Nur für Testzwecke geeignet, sollte Standardmäßig nicht verwendet werden. Falls die Verbindung nur mit dieser Option funktioniert, importieren Sie das SSL-Zertifikat des LDAP-Servers in Ihren %s Server.", "Cache Time-To-Live" : "Speichere Time-To-Live zwischen", diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index 06d96fce441..3a8630fbdcc 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -968,7 +968,7 @@ class Access extends LDAPUtility implements user\IUserTools { /** * escapes (user provided) parts for LDAP filter * @param string $input, the provided value - * @param bool $allowAsterisk wether in * at the beginning should be preserved + * @param bool $allowAsterisk whether in * at the beginning should be preserved * @return string the escaped string */ public function escapeFilterPart($input, $allowAsterisk = false) { diff --git a/apps/user_ldap/lib/connection.php b/apps/user_ldap/lib/connection.php index f3e36fbbf26..4434780ce0b 100644 --- a/apps/user_ldap/lib/connection.php +++ b/apps/user_ldap/lib/connection.php @@ -38,6 +38,7 @@ namespace OCA\user_ldap\lib; * @property boolean hasPagedResultSupport * @property string[] ldapBaseUsers * @property int|string ldapPagingSize holds an integer + * @property bool|mixed|void ldapGroupMemberAssocAttr */ class Connection extends LDAPUtility { private $ldapConnectionRes = null; diff --git a/apps/user_ldap/lib/wizard.php b/apps/user_ldap/lib/wizard.php index 753c8e48a92..fe4eebf9e11 100644 --- a/apps/user_ldap/lib/wizard.php +++ b/apps/user_ldap/lib/wizard.php @@ -857,13 +857,23 @@ class Wizard extends LDAPUtility { } $base = $this->configuration->ldapBase[0]; foreach($cns as $cn) { - $rr = $this->ldap->search($cr, $base, 'cn=' . $cn, array('dn')); + $rr = $this->ldap->search($cr, $base, 'cn=' . $cn, array('dn', 'primaryGroupToken')); if(!$this->ldap->isResource($rr)) { continue; } $er = $this->ldap->firstEntry($cr, $rr); + $attrs = $this->ldap->getAttributes($cr, $er); $dn = $this->ldap->getDN($cr, $er); - $filter .= '(memberof=' . $dn . ')'; + if(empty($dn)) { + continue; + } + $filterPart = '(memberof=' . $dn . ')'; + if(isset($attrs['primaryGroupToken'])) { + $pgt = $attrs['primaryGroupToken'][0]; + $primaryFilterPart = '(primaryGroupID=' . $pgt .')'; + $filterPart = '(|' . $filterPart . $primaryFilterPart . ')'; + } + $filter .= $filterPart; } $filter .= ')'; } diff --git a/apps/user_ldap/tests/group_ldap.php b/apps/user_ldap/tests/group_ldap.php index 6be791f86bc..a2c6beb63a8 100644 --- a/apps/user_ldap/tests/group_ldap.php +++ b/apps/user_ldap/tests/group_ldap.php @@ -75,10 +75,15 @@ class Test_Group_Ldap extends \Test\TestCase { ->method('readAttribute') ->will($this->returnValue(array('u11', 'u22', 'u33', 'u34'))); + // for primary groups + $access->expects($this->once()) + ->method('countUsers') + ->will($this->returnValue(2)); + $groupBackend = new GroupLDAP($access); $users = $groupBackend->countUsersInGroup('group'); - $this->assertSame(4, $users); + $this->assertSame(6, $users); } public function testCountWithSearchString() { diff --git a/autotest-external.sh b/autotest-external.sh index 761477a4c97..74acddfd7a0 100755 --- a/autotest-external.sh +++ b/autotest-external.sh @@ -60,20 +60,25 @@ if [ "$1" ]; then fi fi -# Back up existing (dev) config if one exists -if [ -f config/config.php ]; then +# Back up existing (dev) config if one exists and backup not already there +if [ -f config/config.php ] && [ ! -f config/config-autotest-backup.php ]; then mv config/config.php config/config-autotest-backup.php fi -function restore_config { +function cleanup_config { + cd "$BASEDIR" # Restore existing config if [ -f config/config-autotest-backup.php ]; then mv config/config-autotest-backup.php config/config.php fi + # Remove autotest config + if [ -f config/autoconfig.php ]; then + rm config/autoconfig.php + fi } -# restore config on exit, even when killed -trap restore_config SIGINT SIGTERM +# restore config on exit +trap cleanup_config EXIT # use tmpfs for datadir - should speedup unit test execution if [ -d /dev/shm ]; then @@ -278,9 +283,6 @@ else execute_tests "$1" "$2" fi -cd "$BASEDIR" - -restore_config # # NOTES on mysql: # - CREATE DATABASE oc_autotest; diff --git a/autotest-hhvm.sh b/autotest-hhvm.sh index 4d8efa5a4b8..bf96a5133a6 100755 --- a/autotest-hhvm.sh +++ b/autotest-hhvm.sh @@ -66,20 +66,25 @@ if [ "$1" ]; then fi fi -# Back up existing (dev) config if one exists -if [ -f config/config.php ]; then +# Back up existing (dev) config if one exists and backup not already there +if [ -f config/config.php ] && [ ! -f config/config-autotest-backup.php ]; then mv config/config.php config/config-autotest-backup.php fi -function restore_config { +function cleanup_config { + cd "$BASEDIR" # Restore existing config if [ -f config/config-autotest-backup.php ]; then mv config/config-autotest-backup.php config/config.php fi + # Remove autotest config + if [ -f config/autoconfig.php ]; then + rm config/autoconfig.php + fi } -# restore config on exit, even when killed -trap restore_config SIGINT SIGTERM +# restore config on exit +trap cleanup_config EXIT # use tmpfs for datadir - should speedup unit test execution if [ -d /dev/shm ]; then @@ -236,9 +241,6 @@ else execute_tests "$1" "$2" "$3" fi -cd "$BASEDIR" - -restore_config # # NOTES on mysql: # - CREATE DATABASE oc_autotest; diff --git a/autotest.sh b/autotest.sh index 7bb4c80cb9b..647012ea618 100755 --- a/autotest.sh +++ b/autotest.sh @@ -60,20 +60,25 @@ if [ "$1" ]; then fi fi -# Back up existing (dev) config if one exists -if [ -f config/config.php ]; then +# Back up existing (dev) config if one exists and backup not already there +if [ -f config/config.php ] && [ ! -f config/config-autotest-backup.php ]; then mv config/config.php config/config-autotest-backup.php fi -function restore_config { +function cleanup_config { + cd "$BASEDIR" # Restore existing config if [ -f config/config-autotest-backup.php ]; then mv config/config-autotest-backup.php config/config.php fi + # Remove autotest config + if [ -f config/autoconfig.php ]; then + rm config/autoconfig.php + fi } -# restore config on exit, even when killed -trap restore_config SIGINT SIGTERM +# restore config on exit +trap cleanup_config EXIT # use tmpfs for datadir - should speedup unit test execution if [ -d /dev/shm ]; then @@ -234,9 +239,6 @@ else execute_tests "$1" "$FILENAME" "$3" fi -cd "$BASEDIR" - -restore_config # # NOTES on mysql: # - CREATE DATABASE oc_autotest; diff --git a/config/config.sample.php b/config/config.sample.php index 061f368b20e..10b079caa8a 100644 --- a/config/config.sample.php +++ b/config/config.sample.php @@ -55,7 +55,7 @@ $CONFIG = array( * * @deprecated This salt is deprecated and only used for legacy-compatibility, developers * should *NOT* use this value for anything nowadays. - * + * *'passwordsalt' => 'd3c944a9af095aa08f', */ 'passwordsalt' => '', @@ -508,6 +508,16 @@ $CONFIG = array( 'cron_log' => true, /** + * Location of the lock file for cron executions can be specified here. + * Default is within the tmp directory. The file is named in the following way + * owncloud-server-$INSTANCEID-cron.lock + * where $INSTANCEID is the string specified in the instanceid field. + * Because the cron lock file is accessed in regular intervals, it may prevent enabled disk drives from spinning down. + * A different location for this file can solve such issues. + */ +'cron.lockfile.location' => '', + +/** * Enables log rotation and limits the total size of logfiles. The default is 0, * or no rotation. Specify a size in bytes, for example 104857600 (100 megabytes * = 100 * 1024 * 1024 bytes). A new logfile is created with a new name when the @@ -669,7 +679,7 @@ $CONFIG = array( * - OC\Preview\StarOffice * - OC\Preview\SVG * - OC\Preview\TIFF - * + * * .. note:: Troubleshooting steps for the MS Word previews are available * at the :doc:`collaborative_documents_configuration` section * of the Administrators Manual. diff --git a/core/ajax/update.php b/core/ajax/update.php index baa01b4f208..656fe2736ac 100644 --- a/core/ajax/update.php +++ b/core/ajax/update.php @@ -36,9 +36,12 @@ if (OC::checkUpgrade(false)) { $eventSource = \OC::$server->createEventSource(); $updater = new \OC\Updater( \OC::$server->getHTTPHelper(), - \OC::$server->getAppConfig(), + \OC::$server->getConfig(), \OC_Log::$object ); + $incompatibleApps = []; + $disabledThirdPartyApps = []; + $updater->listen('\OC\Updater', 'maintenanceStart', function () use ($eventSource, $l) { $eventSource->send('success', (string)$l->t('Turned on maintenance mode')); }); @@ -57,13 +60,11 @@ if (OC::checkUpgrade(false)) { $updater->listen('\OC\Updater', 'appUpgrade', function ($app, $version) use ($eventSource, $l) { $eventSource->send('success', (string)$l->t('Updated "%s" to %s', array($app, $version))); }); - $updater->listen('\OC\Updater', 'disabledApps', function ($appList) use ($eventSource, $l) { - $list = array(); - foreach ($appList as $appId) { - $info = OC_App::getAppInfo($appId); - $list[] = $info['name'] . ' (' . $info['id'] . ')'; - } - $eventSource->send('success', (string)$l->t('Disabled incompatible apps: %s', implode(', ', $list))); + $updater->listen('\OC\Updater', 'incompatibleAppDisabled', function ($app) use (&$incompatibleApps) { + $incompatibleApps[]= $app; + }); + $updater->listen('\OC\Updater', 'thirdPartyAppDisabled', function ($app) use (&$disabledThirdPartyApps) { + $disabledThirdPartyApps[]= $app; }); $updater->listen('\OC\Updater', 'failure', function ($message) use ($eventSource) { $eventSource->send('failure', $message); @@ -73,6 +74,15 @@ if (OC::checkUpgrade(false)) { $updater->upgrade(); + if (!empty($incompatibleApps)) { + $eventSource->send('notice', + (string)$l->t('Following incompatible apps have been disabled: %s', implode(', ', $incompatibleApps))); + } + if (!empty($disabledThirdPartyApps)) { + $eventSource->send('notice', + (string)$l->t('Following 3rd party apps have been disabled: %s', implode(', ', $disabledThirdPartyApps))); + } + $eventSource->send('done', ''); $eventSource->close(); } diff --git a/core/command/upgrade.php b/core/command/upgrade.php index 91e4c3c744a..87e83afde29 100644 --- a/core/command/upgrade.php +++ b/core/command/upgrade.php @@ -100,7 +100,8 @@ class Upgrade extends Command { if(\OC::checkUpgrade(false)) { $self = $this; - $updater = new Updater(\OC::$server->getHTTPHelper(), \OC::$server->getAppConfig()); + $updater = new Updater(\OC::$server->getHTTPHelper(), + \OC::$server->getConfig()); $updater->setSimulateStepEnabled($simulateStepEnabled); $updater->setUpdateStepEnabled($updateStepEnabled); @@ -122,8 +123,17 @@ class Upgrade extends Command { $updater->listen('\OC\Updater', 'dbSimulateUpgrade', function () use($output) { $output->writeln('<info>Checked database schema update</info>'); }); - $updater->listen('\OC\Updater', 'disabledApps', function ($appList) use($output) { - $output->writeln('<info>Disabled incompatible apps: ' . implode(', ', $appList) . '</info>'); + $updater->listen('\OC\Updater', 'incompatibleAppDisabled', function ($app) use($output) { + $output->writeln('<info>Disabled incompatible app: ' . $app . '</info>'); + }); + $updater->listen('\OC\Updater', 'thirdPartyAppDisabled', function ($app) use($output) { + $output->writeln('<info>Disabled 3rd-party app: ' . $app . '</info>'); + }); + $updater->listen('\OC\Updater', 'appUpgradeCheck', function () use ($output) { + $output->writeln('<info>Checked database schema update for apps</info>'); + }); + $updater->listen('\OC\Updater', 'appUpgrade', function ($app, $version) use ($output) { + $output->writeln("<info>Updated <$app> to $version</info>"); }); $updater->listen('\OC\Updater', 'failure', function ($message) use($output, $self) { diff --git a/core/js/update.js b/core/js/update.js index f63808f65be..60f04832935 100644 --- a/core/js/update.js +++ b/core/js/update.js @@ -38,6 +38,9 @@ updateEventSource.listen('success', function(message) { $('<span>').append(message).append('<br />').appendTo($el); }); + updateEventSource.listen('notice', function(message) { + $('<span>').addClass('error').append(message).append('<br />').appendTo($el); + }); updateEventSource.listen('error', function(message) { $('<span>').addClass('error').append(message).append('<br />').appendTo($el); message = t('core', 'Please reload the page.'); diff --git a/core/l10n/af_ZA.js b/core/l10n/af_ZA.js index 516aa4c3eed..10f2c1da917 100644 --- a/core/l10n/af_ZA.js +++ b/core/l10n/af_ZA.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Databasis skema opdatering nagegaan", "Checked database schema update for apps" : "Databasis skema opdatering nagegaan vir sagteware", "Updated \"%s\" to %s" : "\"%s\" opgedateer na %s", - "Disabled incompatible apps: %s" : "Onversoenbare sagteware onaktief gemaak: %s", "No image or file provided" : "Geen prent of lêer voorsien", "Unknown filetype" : "Onbekende lêertipe", "Invalid image" : "Ongeldige prent", diff --git a/core/l10n/af_ZA.json b/core/l10n/af_ZA.json index c4cb73fb351..f37bdd5eef0 100644 --- a/core/l10n/af_ZA.json +++ b/core/l10n/af_ZA.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Databasis skema opdatering nagegaan", "Checked database schema update for apps" : "Databasis skema opdatering nagegaan vir sagteware", "Updated \"%s\" to %s" : "\"%s\" opgedateer na %s", - "Disabled incompatible apps: %s" : "Onversoenbare sagteware onaktief gemaak: %s", "No image or file provided" : "Geen prent of lêer voorsien", "Unknown filetype" : "Onbekende lêertipe", "Invalid image" : "Ongeldige prent", diff --git a/core/l10n/ast.js b/core/l10n/ast.js index ed921d7c2c5..d3cacf191b0 100644 --- a/core/l10n/ast.js +++ b/core/l10n/ast.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Anovamientu del esquema de base de datos revisáu", "Checked database schema update for apps" : "Anovamientu del esquema de base de datos p'aplicaciones revisáu", "Updated \"%s\" to %s" : "Anováu \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicaciones incompatibles desactivaes: %s", "No image or file provided" : "Nun s'especificó nenguna imaxe o ficheru", "Unknown filetype" : "Triba de ficheru desconocida", "Invalid image" : "Imaxe inválida", diff --git a/core/l10n/ast.json b/core/l10n/ast.json index 18398a020a8..7d6edc058fd 100644 --- a/core/l10n/ast.json +++ b/core/l10n/ast.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Anovamientu del esquema de base de datos revisáu", "Checked database schema update for apps" : "Anovamientu del esquema de base de datos p'aplicaciones revisáu", "Updated \"%s\" to %s" : "Anováu \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicaciones incompatibles desactivaes: %s", "No image or file provided" : "Nun s'especificó nenguna imaxe o ficheru", "Unknown filetype" : "Triba de ficheru desconocida", "Invalid image" : "Imaxe inválida", diff --git a/core/l10n/az.js b/core/l10n/az.js index 3dceae5700a..cbef0fadd5b 100644 --- a/core/l10n/az.js +++ b/core/l10n/az.js @@ -15,6 +15,7 @@ OC.L10N.register( "Saving..." : "Saxlama...", "No" : "Xeyir", "Yes" : "Bəli", + "Choose" : "Seç", "Ok" : "Oldu", "_{count} file conflict_::_{count} file conflicts_" : ["",""], "Cancel" : "Dayandır", diff --git a/core/l10n/az.json b/core/l10n/az.json index 76b54fcf83b..bf2da92574a 100644 --- a/core/l10n/az.json +++ b/core/l10n/az.json @@ -13,6 +13,7 @@ "Saving..." : "Saxlama...", "No" : "Xeyir", "Yes" : "Bəli", + "Choose" : "Seç", "Ok" : "Oldu", "_{count} file conflict_::_{count} file conflicts_" : ["",""], "Cancel" : "Dayandır", diff --git a/core/l10n/bg_BG.js b/core/l10n/bg_BG.js index b96c56d5eb6..f7fdacb6c80 100644 --- a/core/l10n/bg_BG.js +++ b/core/l10n/bg_BG.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Обновяването на схемата на базата данни е проверено", "Checked database schema update for apps" : "Обновяването на схемата на базата данни за приложения е проверено", "Updated \"%s\" to %s" : "Обновен \"%s\" до %s", - "Disabled incompatible apps: %s" : "Изключени са несъвместимите програми: %s.", "No image or file provided" : "Не бяха доставени картинка или файл", "Unknown filetype" : "Непознат файлов тип", "Invalid image" : "Невалидно изображение", diff --git a/core/l10n/bg_BG.json b/core/l10n/bg_BG.json index 628fd0761dd..b113f217b26 100644 --- a/core/l10n/bg_BG.json +++ b/core/l10n/bg_BG.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Обновяването на схемата на базата данни е проверено", "Checked database schema update for apps" : "Обновяването на схемата на базата данни за приложения е проверено", "Updated \"%s\" to %s" : "Обновен \"%s\" до %s", - "Disabled incompatible apps: %s" : "Изключени са несъвместимите програми: %s.", "No image or file provided" : "Не бяха доставени картинка или файл", "Unknown filetype" : "Непознат файлов тип", "Invalid image" : "Невалидно изображение", diff --git a/core/l10n/bs.js b/core/l10n/bs.js index 67e44ad6797..643408f0a84 100644 --- a/core/l10n/bs.js +++ b/core/l10n/bs.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Provjereno aktualiziranje šeme baze podataka", "Checked database schema update for apps" : "Provjereno ažuriranje šeme baze podataka za aplikacije", "Updated \"%s\" to %s" : "Aktualizirano \"%s\" do %s", - "Disabled incompatible apps: %s" : "Deaktivirane nekompatibilne aplikacije: %s", "No image or file provided" : "Ne postoji predviđena slika ili datoteka", "Unknown filetype" : "Nepoznat tip datoteke", "Invalid image" : "Nevažeća datoteka", diff --git a/core/l10n/bs.json b/core/l10n/bs.json index a1c6552b8dd..c58c057d384 100644 --- a/core/l10n/bs.json +++ b/core/l10n/bs.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Provjereno aktualiziranje šeme baze podataka", "Checked database schema update for apps" : "Provjereno ažuriranje šeme baze podataka za aplikacije", "Updated \"%s\" to %s" : "Aktualizirano \"%s\" do %s", - "Disabled incompatible apps: %s" : "Deaktivirane nekompatibilne aplikacije: %s", "No image or file provided" : "Ne postoji predviđena slika ili datoteka", "Unknown filetype" : "Nepoznat tip datoteke", "Invalid image" : "Nevažeća datoteka", diff --git a/core/l10n/ca.js b/core/l10n/ca.js index d473ceb84db..6d15d251f5a 100644 --- a/core/l10n/ca.js +++ b/core/l10n/ca.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "S'ha comprobat l'actualització de l'esquema de la base de dades", "Checked database schema update for apps" : "S'ha comprobat l'actualització de l'esquema de la base de dades per les apps", "Updated \"%s\" to %s" : "Actualitzat \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicacions incompatibles desactivades: %s", "No image or file provided" : "No s'han proporcionat imatges o fitxers", "Unknown filetype" : "Tipus de fitxer desconegut", "Invalid image" : "Imatge no vàlida", diff --git a/core/l10n/ca.json b/core/l10n/ca.json index 4018f6072f9..84ab24d00f2 100644 --- a/core/l10n/ca.json +++ b/core/l10n/ca.json @@ -6,7 +6,6 @@ "Checked database schema update" : "S'ha comprobat l'actualització de l'esquema de la base de dades", "Checked database schema update for apps" : "S'ha comprobat l'actualització de l'esquema de la base de dades per les apps", "Updated \"%s\" to %s" : "Actualitzat \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicacions incompatibles desactivades: %s", "No image or file provided" : "No s'han proporcionat imatges o fitxers", "Unknown filetype" : "Tipus de fitxer desconegut", "Invalid image" : "Imatge no vàlida", diff --git a/core/l10n/cs_CZ.js b/core/l10n/cs_CZ.js index d1878cd0be6..6550df41552 100644 --- a/core/l10n/cs_CZ.js +++ b/core/l10n/cs_CZ.js @@ -8,7 +8,6 @@ OC.L10N.register( "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", "Updated \"%s\" to %s" : "Aktualizováno z \"%s\" na %s", - "Disabled incompatible apps: %s" : "Zakázané nekompatibilní aplikace: %s", "No image or file provided" : "Soubor nebo obrázek nebyl zadán", "Unknown filetype" : "Neznámý typ souboru", "Invalid image" : "Chybný obrázek", diff --git a/core/l10n/cs_CZ.json b/core/l10n/cs_CZ.json index 39c1ec755f2..4d79cb51386 100644 --- a/core/l10n/cs_CZ.json +++ b/core/l10n/cs_CZ.json @@ -6,7 +6,6 @@ "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", "Updated \"%s\" to %s" : "Aktualizováno z \"%s\" na %s", - "Disabled incompatible apps: %s" : "Zakázané nekompatibilní aplikace: %s", "No image or file provided" : "Soubor nebo obrázek nebyl zadán", "Unknown filetype" : "Neznámý typ souboru", "Invalid image" : "Chybný obrázek", diff --git a/core/l10n/da.js b/core/l10n/da.js index ada9cd9d39f..168eb4f03cc 100644 --- a/core/l10n/da.js +++ b/core/l10n/da.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Tjekket database schema opdatering", "Checked database schema update for apps" : "Tjekkede databaseskemaets opdatering for apps", "Updated \"%s\" to %s" : "Opdaterede \"%s\" til %s", - "Disabled incompatible apps: %s" : "Deaktiverer inkompatible apps: %s", "No image or file provided" : "Ingen fil eller billede givet", "Unknown filetype" : "Ukendt filtype", "Invalid image" : "Ugyldigt billede", diff --git a/core/l10n/da.json b/core/l10n/da.json index 4e2d9be116d..5fac20fbf44 100644 --- a/core/l10n/da.json +++ b/core/l10n/da.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Tjekket database schema opdatering", "Checked database schema update for apps" : "Tjekkede databaseskemaets opdatering for apps", "Updated \"%s\" to %s" : "Opdaterede \"%s\" til %s", - "Disabled incompatible apps: %s" : "Deaktiverer inkompatible apps: %s", "No image or file provided" : "Ingen fil eller billede givet", "Unknown filetype" : "Ukendt filtype", "Invalid image" : "Ugyldigt billede", diff --git a/core/l10n/de.js b/core/l10n/de.js index 68c1815a881..6e4a012d26c 100644 --- a/core/l10n/de.js +++ b/core/l10n/de.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Datenbank-Schemenaktualisierung geprüft", "Checked database schema update for apps" : "Datenbank-Schemenaktualisierung für Apps geprüft", "Updated \"%s\" to %s" : "„%s“ zu %s aktualisiert", - "Disabled incompatible apps: %s" : "Deaktivierte inkompatible Apps: %s", "No image or file provided" : "Kein Bild oder Datei zur Verfügung gestellt", "Unknown filetype" : "Unbekannter Dateityp", "Invalid image" : "Ungültiges Bild", diff --git a/core/l10n/de.json b/core/l10n/de.json index 2dbe09051d7..890cfe46194 100644 --- a/core/l10n/de.json +++ b/core/l10n/de.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Datenbank-Schemenaktualisierung geprüft", "Checked database schema update for apps" : "Datenbank-Schemenaktualisierung für Apps geprüft", "Updated \"%s\" to %s" : "„%s“ zu %s aktualisiert", - "Disabled incompatible apps: %s" : "Deaktivierte inkompatible Apps: %s", "No image or file provided" : "Kein Bild oder Datei zur Verfügung gestellt", "Unknown filetype" : "Unbekannter Dateityp", "Invalid image" : "Ungültiges Bild", diff --git a/core/l10n/de_DE.js b/core/l10n/de_DE.js index d3e91e3af86..7def7cb4007 100644 --- a/core/l10n/de_DE.js +++ b/core/l10n/de_DE.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Aktualisierung des Datenbankschemas wurde überprüft", "Checked database schema update for apps" : "Aktualisierung des Datenbankschemas für Apps wurde überprüft", "Updated \"%s\" to %s" : "„%s“ zu %s aktualisiert", - "Disabled incompatible apps: %s" : "Deaktivierte inkompatible Apps: %s", "No image or file provided" : "Weder Bild noch eine Datei wurden zur Verfügung gestellt", "Unknown filetype" : "Unbekannter Dateityp", "Invalid image" : "Ungültiges Bild", diff --git a/core/l10n/de_DE.json b/core/l10n/de_DE.json index 0bae856c7ba..5b614b3bef2 100644 --- a/core/l10n/de_DE.json +++ b/core/l10n/de_DE.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Aktualisierung des Datenbankschemas wurde überprüft", "Checked database schema update for apps" : "Aktualisierung des Datenbankschemas für Apps wurde überprüft", "Updated \"%s\" to %s" : "„%s“ zu %s aktualisiert", - "Disabled incompatible apps: %s" : "Deaktivierte inkompatible Apps: %s", "No image or file provided" : "Weder Bild noch eine Datei wurden zur Verfügung gestellt", "Unknown filetype" : "Unbekannter Dateityp", "Invalid image" : "Ungültiges Bild", diff --git a/core/l10n/el.js b/core/l10n/el.js index 577b92bb758..51a30bb1ac2 100644 --- a/core/l10n/el.js +++ b/core/l10n/el.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Έλεγχος ενημέρωσης σχήματος βάσης δεδομένων", "Checked database schema update for apps" : "Έλεγχος ενημέρωσης σχήματος βάσης δεδομένων για εφαρμογές", "Updated \"%s\" to %s" : "Αναβαθμίστηκε \"%s\" σε %s", - "Disabled incompatible apps: %s" : "Απενεργοποιημένες μη συμβατές εφαρμογές: %s", "No image or file provided" : "Δεν δόθηκε εικόνα ή αρχείο", "Unknown filetype" : "Άγνωστος τύπος αρχείου", "Invalid image" : "Μη έγκυρη εικόνα", diff --git a/core/l10n/el.json b/core/l10n/el.json index 25160f8b6f1..da59184605c 100644 --- a/core/l10n/el.json +++ b/core/l10n/el.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Έλεγχος ενημέρωσης σχήματος βάσης δεδομένων", "Checked database schema update for apps" : "Έλεγχος ενημέρωσης σχήματος βάσης δεδομένων για εφαρμογές", "Updated \"%s\" to %s" : "Αναβαθμίστηκε \"%s\" σε %s", - "Disabled incompatible apps: %s" : "Απενεργοποιημένες μη συμβατές εφαρμογές: %s", "No image or file provided" : "Δεν δόθηκε εικόνα ή αρχείο", "Unknown filetype" : "Άγνωστος τύπος αρχείου", "Invalid image" : "Μη έγκυρη εικόνα", diff --git a/core/l10n/en_GB.js b/core/l10n/en_GB.js index e55fa7348c3..369c7c0fb61 100644 --- a/core/l10n/en_GB.js +++ b/core/l10n/en_GB.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Checked database schema update", "Checked database schema update for apps" : "Checked database schema update for apps", "Updated \"%s\" to %s" : "Updated \"%s\" to %s", - "Disabled incompatible apps: %s" : "Disabled incompatible apps: %s", "No image or file provided" : "No image or file provided", "Unknown filetype" : "Unknown filetype", "Invalid image" : "Invalid image", diff --git a/core/l10n/en_GB.json b/core/l10n/en_GB.json index b5b9e812b08..7409ded9adf 100644 --- a/core/l10n/en_GB.json +++ b/core/l10n/en_GB.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Checked database schema update", "Checked database schema update for apps" : "Checked database schema update for apps", "Updated \"%s\" to %s" : "Updated \"%s\" to %s", - "Disabled incompatible apps: %s" : "Disabled incompatible apps: %s", "No image or file provided" : "No image or file provided", "Unknown filetype" : "Unknown filetype", "Invalid image" : "Invalid image", diff --git a/core/l10n/es.js b/core/l10n/es.js index 395b0d1be5f..3f61e17f640 100644 --- a/core/l10n/es.js +++ b/core/l10n/es.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Actualización del esquema de base de datos revisado", "Checked database schema update for apps" : "Comprobada la actualización del esquema de la base de datos para aplicaciones", "Updated \"%s\" to %s" : "Se ha actualizado \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicaciones incompatibles desactivadas: %s", "No image or file provided" : "No se especificó ningún archivo o imagen", "Unknown filetype" : "Tipo de archivo desconocido", "Invalid image" : "Imagen inválida", diff --git a/core/l10n/es.json b/core/l10n/es.json index ee8f27b5271..18f3c3215f6 100644 --- a/core/l10n/es.json +++ b/core/l10n/es.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Actualización del esquema de base de datos revisado", "Checked database schema update for apps" : "Comprobada la actualización del esquema de la base de datos para aplicaciones", "Updated \"%s\" to %s" : "Se ha actualizado \"%s\" a %s", - "Disabled incompatible apps: %s" : "Aplicaciones incompatibles desactivadas: %s", "No image or file provided" : "No se especificó ningún archivo o imagen", "Unknown filetype" : "Tipo de archivo desconocido", "Invalid image" : "Imagen inválida", diff --git a/core/l10n/et_EE.js b/core/l10n/et_EE.js index d24977507ee..034c51e6e33 100644 --- a/core/l10n/et_EE.js +++ b/core/l10n/et_EE.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Andmebaasi skeemi uuendus kontrollitud", "Checked database schema update for apps" : "Andmebaasi skeemi uuendus rakendustele on kontrollitud", "Updated \"%s\" to %s" : "Uuendatud \"%s\" -> %s", - "Disabled incompatible apps: %s" : "Keelatud mitteühilduvad rakendid: %s", "No image or file provided" : "Ühtegi pilti või faili pole pakutud", "Unknown filetype" : "Tundmatu failitüüp", "Invalid image" : "Vigane pilt", diff --git a/core/l10n/et_EE.json b/core/l10n/et_EE.json index c19f7b45802..3e4811ced66 100644 --- a/core/l10n/et_EE.json +++ b/core/l10n/et_EE.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Andmebaasi skeemi uuendus kontrollitud", "Checked database schema update for apps" : "Andmebaasi skeemi uuendus rakendustele on kontrollitud", "Updated \"%s\" to %s" : "Uuendatud \"%s\" -> %s", - "Disabled incompatible apps: %s" : "Keelatud mitteühilduvad rakendid: %s", "No image or file provided" : "Ühtegi pilti või faili pole pakutud", "Unknown filetype" : "Tundmatu failitüüp", "Invalid image" : "Vigane pilt", diff --git a/core/l10n/eu.js b/core/l10n/eu.js index f234353b122..bf97fd83937 100644 --- a/core/l10n/eu.js +++ b/core/l10n/eu.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Egiaztatuta datu-basearen zerbitzariaren eguneraketa", "Checked database schema update for apps" : "Egiaztatuta aplikazioen datu-basearen zerbitzariaren eguneraketa", "Updated \"%s\" to %s" : "\"%s\" %s-ra eguneratua", - "Disabled incompatible apps: %s" : "Bateragarriak ez diren desgaitutako aplikazioak: %s", "No image or file provided" : "Ez da irudi edo fitxategirik zehaztu", "Unknown filetype" : "Fitxategi mota ezezaguna", "Invalid image" : "Baliogabeko irudia", diff --git a/core/l10n/eu.json b/core/l10n/eu.json index 675bbbb184a..cce4188b63f 100644 --- a/core/l10n/eu.json +++ b/core/l10n/eu.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Egiaztatuta datu-basearen zerbitzariaren eguneraketa", "Checked database schema update for apps" : "Egiaztatuta aplikazioen datu-basearen zerbitzariaren eguneraketa", "Updated \"%s\" to %s" : "\"%s\" %s-ra eguneratua", - "Disabled incompatible apps: %s" : "Bateragarriak ez diren desgaitutako aplikazioak: %s", "No image or file provided" : "Ez da irudi edo fitxategirik zehaztu", "Unknown filetype" : "Fitxategi mota ezezaguna", "Invalid image" : "Baliogabeko irudia", diff --git a/core/l10n/fa.js b/core/l10n/fa.js index 2240fe43264..6ba7a150d67 100644 --- a/core/l10n/fa.js +++ b/core/l10n/fa.js @@ -5,7 +5,6 @@ OC.L10N.register( "Turned on maintenance mode" : "حالت \" در دست تعمیر \" فعال شد .", "Turned off maintenance mode" : "حالت \" در دست تعمیر \" غیرفعال شد .", "Updated database" : "بروز رسانی پایگاه داده انجام شد .", - "Disabled incompatible apps: %s" : "اپ های ناسازگار غیرفعال شدند : %s", "No image or file provided" : "هیچ فایل یا تصویری وارد نشده است", "Unknown filetype" : "نوع فایل ناشناخته", "Invalid image" : "عکس نامعتبر", diff --git a/core/l10n/fa.json b/core/l10n/fa.json index a949586fd3e..3c6781a7e08 100644 --- a/core/l10n/fa.json +++ b/core/l10n/fa.json @@ -3,7 +3,6 @@ "Turned on maintenance mode" : "حالت \" در دست تعمیر \" فعال شد .", "Turned off maintenance mode" : "حالت \" در دست تعمیر \" غیرفعال شد .", "Updated database" : "بروز رسانی پایگاه داده انجام شد .", - "Disabled incompatible apps: %s" : "اپ های ناسازگار غیرفعال شدند : %s", "No image or file provided" : "هیچ فایل یا تصویری وارد نشده است", "Unknown filetype" : "نوع فایل ناشناخته", "Invalid image" : "عکس نامعتبر", diff --git a/core/l10n/fi_FI.js b/core/l10n/fi_FI.js index 641660f6970..e154c724d06 100644 --- a/core/l10n/fi_FI.js +++ b/core/l10n/fi_FI.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Tarkistettu tietokannan skeemapäivitys", "Checked database schema update for apps" : "Tarkistettu tietokannan skeemapäivitys sovelluksille", "Updated \"%s\" to %s" : "Päivitetty \"%s\" versioon %s", - "Disabled incompatible apps: %s" : "Yhteensopimattomat sovellukset poistettiin käytöstä: %s", "No image or file provided" : "Kuvaa tai tiedostoa ei määritelty", "Unknown filetype" : "Tuntematon tiedostotyyppi", "Invalid image" : "Virhellinen kuva", diff --git a/core/l10n/fi_FI.json b/core/l10n/fi_FI.json index e919f677f84..49378dce048 100644 --- a/core/l10n/fi_FI.json +++ b/core/l10n/fi_FI.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Tarkistettu tietokannan skeemapäivitys", "Checked database schema update for apps" : "Tarkistettu tietokannan skeemapäivitys sovelluksille", "Updated \"%s\" to %s" : "Päivitetty \"%s\" versioon %s", - "Disabled incompatible apps: %s" : "Yhteensopimattomat sovellukset poistettiin käytöstä: %s", "No image or file provided" : "Kuvaa tai tiedostoa ei määritelty", "Unknown filetype" : "Tuntematon tiedostotyyppi", "Invalid image" : "Virhellinen kuva", diff --git a/core/l10n/fr.js b/core/l10n/fr.js index c020571ff3b..0f390bbc6d4 100644 --- a/core/l10n/fr.js +++ b/core/l10n/fr.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Mise à jour du schéma de la base de données vérifiée", "Checked database schema update for apps" : "Mise à jour du schéma de la base de données pour les applications vérifiée", "Updated \"%s\" to %s" : "Mise à jour de « %s » vers %s", - "Disabled incompatible apps: %s" : "Applications incompatibles désactivées : %s", "No image or file provided" : "Aucun fichier fourni", "Unknown filetype" : "Type de fichier inconnu", "Invalid image" : "Image non valable", diff --git a/core/l10n/fr.json b/core/l10n/fr.json index dfbb452c077..d2ff338cc4d 100644 --- a/core/l10n/fr.json +++ b/core/l10n/fr.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Mise à jour du schéma de la base de données vérifiée", "Checked database schema update for apps" : "Mise à jour du schéma de la base de données pour les applications vérifiée", "Updated \"%s\" to %s" : "Mise à jour de « %s » vers %s", - "Disabled incompatible apps: %s" : "Applications incompatibles désactivées : %s", "No image or file provided" : "Aucun fichier fourni", "Unknown filetype" : "Type de fichier inconnu", "Invalid image" : "Image non valable", diff --git a/core/l10n/gl.js b/core/l10n/gl.js index d7ec7c9c8bc..1a0bb03d435 100644 --- a/core/l10n/gl.js +++ b/core/l10n/gl.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Comprobada a actualización do esquema da base de datos", "Checked database schema update for apps" : "Comprobada a actualización do esquema da base de datos para aplicacións", "Updated \"%s\" to %s" : "Actualizado «%s» a %s", - "Disabled incompatible apps: %s" : "Aplicacións incompatíbeis desactivadas: %s", "No image or file provided" : "Non forneceu ningunha imaxe ou ficheiro", "Unknown filetype" : "Tipo de ficheiro descoñecido", "Invalid image" : "Imaxe incorrecta", diff --git a/core/l10n/gl.json b/core/l10n/gl.json index ae9e923b606..7d4b889c6f4 100644 --- a/core/l10n/gl.json +++ b/core/l10n/gl.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Comprobada a actualización do esquema da base de datos", "Checked database schema update for apps" : "Comprobada a actualización do esquema da base de datos para aplicacións", "Updated \"%s\" to %s" : "Actualizado «%s» a %s", - "Disabled incompatible apps: %s" : "Aplicacións incompatíbeis desactivadas: %s", "No image or file provided" : "Non forneceu ningunha imaxe ou ficheiro", "Unknown filetype" : "Tipo de ficheiro descoñecido", "Invalid image" : "Imaxe incorrecta", diff --git a/core/l10n/hr.js b/core/l10n/hr.js index c9d0494f5dc..ebf432d5f88 100644 --- a/core/l10n/hr.js +++ b/core/l10n/hr.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Provjereno ažuriranje sheme baze podataka", "Checked database schema update for apps" : "Provjereno ažuriranje sheme baze podataka za aplikacije", "Updated \"%s\" to %s" : "Ažurirano \"%s\" u %s", - "Disabled incompatible apps: %s" : "Onemogućene inkompatibilne applikacije: %s", "No image or file provided" : "Nijedna slika ili datoteka nije dobavljena", "Unknown filetype" : "Vrsta datoteke nepoznata", "Invalid image" : "Slika neispravna", diff --git a/core/l10n/hr.json b/core/l10n/hr.json index b770f224923..8ea6eee60be 100644 --- a/core/l10n/hr.json +++ b/core/l10n/hr.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Provjereno ažuriranje sheme baze podataka", "Checked database schema update for apps" : "Provjereno ažuriranje sheme baze podataka za aplikacije", "Updated \"%s\" to %s" : "Ažurirano \"%s\" u %s", - "Disabled incompatible apps: %s" : "Onemogućene inkompatibilne applikacije: %s", "No image or file provided" : "Nijedna slika ili datoteka nije dobavljena", "Unknown filetype" : "Vrsta datoteke nepoznata", "Invalid image" : "Slika neispravna", diff --git a/core/l10n/hu_HU.js b/core/l10n/hu_HU.js index 13ccda12b0a..bb66447bc7f 100644 --- a/core/l10n/hu_HU.js +++ b/core/l10n/hu_HU.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Az adatbázis séma frissítését ellenőriztük", "Checked database schema update for apps" : "Az adatbázis séma frissítését ellenőriztük az alkalmazásokra vontakozóan", "Updated \"%s\" to %s" : "Frissítettük \"%s\"-t erre: %s", - "Disabled incompatible apps: %s" : "Letiltásra került inkompatibilis alkalmazások: %s", "No image or file provided" : "Nincs kép vagy fájl megadva", "Unknown filetype" : "Ismeretlen fájltípus", "Invalid image" : "Hibás kép", diff --git a/core/l10n/hu_HU.json b/core/l10n/hu_HU.json index dff7fa0756e..a50c421782b 100644 --- a/core/l10n/hu_HU.json +++ b/core/l10n/hu_HU.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Az adatbázis séma frissítését ellenőriztük", "Checked database schema update for apps" : "Az adatbázis séma frissítését ellenőriztük az alkalmazásokra vontakozóan", "Updated \"%s\" to %s" : "Frissítettük \"%s\"-t erre: %s", - "Disabled incompatible apps: %s" : "Letiltásra került inkompatibilis alkalmazások: %s", "No image or file provided" : "Nincs kép vagy fájl megadva", "Unknown filetype" : "Ismeretlen fájltípus", "Invalid image" : "Hibás kép", diff --git a/core/l10n/ia.js b/core/l10n/ia.js index 6dab1408744..783d310722b 100644 --- a/core/l10n/ia.js +++ b/core/l10n/ia.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Il ha verificate actualisation de schema de base de datos", "Checked database schema update for apps" : "Il ha verificate actualisation de schema de base de datos pro apps", "Updated \"%s\" to %s" : "Actualisava \"%s\" a %s", - "Disabled incompatible apps: %s" : "Apps non compatibile ha essite dishabilitate: %s", "No image or file provided" : "Il forniva necun imagine o file", "Unknown filetype" : "Typo de file incognite", "Invalid image" : "Imagine invalide", diff --git a/core/l10n/ia.json b/core/l10n/ia.json index 7c5521a994c..e55f945bdf6 100644 --- a/core/l10n/ia.json +++ b/core/l10n/ia.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Il ha verificate actualisation de schema de base de datos", "Checked database schema update for apps" : "Il ha verificate actualisation de schema de base de datos pro apps", "Updated \"%s\" to %s" : "Actualisava \"%s\" a %s", - "Disabled incompatible apps: %s" : "Apps non compatibile ha essite dishabilitate: %s", "No image or file provided" : "Il forniva necun imagine o file", "Unknown filetype" : "Typo de file incognite", "Invalid image" : "Imagine invalide", diff --git a/core/l10n/id.js b/core/l10n/id.js index 322b51f2fc5..98922aab281 100644 --- a/core/l10n/id.js +++ b/core/l10n/id.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Pembaruan skema basis data terperiksa", "Checked database schema update for apps" : "Pembaruan skema basis data terperiksa untuk aplikasi", "Updated \"%s\" to %s" : "Terbaru \"%s\" sampai %s", - "Disabled incompatible apps: %s" : "Aplikasi tidak kompatibel yang dinonaktifkan: %s", "No image or file provided" : "Tidak ada gambar atau berkas yang disediakan", "Unknown filetype" : "Tipe berkas tidak dikenal", "Invalid image" : "Gambar tidak sah", diff --git a/core/l10n/id.json b/core/l10n/id.json index 0eb62928aac..e1db89d455f 100644 --- a/core/l10n/id.json +++ b/core/l10n/id.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Pembaruan skema basis data terperiksa", "Checked database schema update for apps" : "Pembaruan skema basis data terperiksa untuk aplikasi", "Updated \"%s\" to %s" : "Terbaru \"%s\" sampai %s", - "Disabled incompatible apps: %s" : "Aplikasi tidak kompatibel yang dinonaktifkan: %s", "No image or file provided" : "Tidak ada gambar atau berkas yang disediakan", "Unknown filetype" : "Tipe berkas tidak dikenal", "Invalid image" : "Gambar tidak sah", diff --git a/core/l10n/it.js b/core/l10n/it.js index f41cea18d85..99d3cc0baaf 100644 --- a/core/l10n/it.js +++ b/core/l10n/it.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Verificato l'aggiornamento dello schema del database", "Checked database schema update for apps" : "Verificato l'aggiornamento dello schema del database per le applicazioni", "Updated \"%s\" to %s" : "Aggiornato \"%s\" a %s", - "Disabled incompatible apps: %s" : "Applicazione incompatibili disabilitate: %s", "No image or file provided" : "Non è stata fornita alcun immagine o file", "Unknown filetype" : "Tipo di file sconosciuto", "Invalid image" : "Immagine non valida", diff --git a/core/l10n/it.json b/core/l10n/it.json index 35313f952f5..dc003f96eac 100644 --- a/core/l10n/it.json +++ b/core/l10n/it.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Verificato l'aggiornamento dello schema del database", "Checked database schema update for apps" : "Verificato l'aggiornamento dello schema del database per le applicazioni", "Updated \"%s\" to %s" : "Aggiornato \"%s\" a %s", - "Disabled incompatible apps: %s" : "Applicazione incompatibili disabilitate: %s", "No image or file provided" : "Non è stata fornita alcun immagine o file", "Unknown filetype" : "Tipo di file sconosciuto", "Invalid image" : "Immagine non valida", diff --git a/core/l10n/ja.js b/core/l10n/ja.js index 5ea893132f7..84551ab8129 100644 --- a/core/l10n/ja.js +++ b/core/l10n/ja.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "指定データベースのスキーマを更新", "Checked database schema update for apps" : "アプリの指定データベースのスキーマを更新", "Updated \"%s\" to %s" : "\"%s\" を %s にアップデートしました。", - "Disabled incompatible apps: %s" : "無効化された非互換アプリ:%s", "No image or file provided" : "画像もしくはファイルが提供されていません", "Unknown filetype" : "不明なファイルタイプ", "Invalid image" : "無効な画像", diff --git a/core/l10n/ja.json b/core/l10n/ja.json index 223e2d6a073..724ba2eb37b 100644 --- a/core/l10n/ja.json +++ b/core/l10n/ja.json @@ -6,7 +6,6 @@ "Checked database schema update" : "指定データベースのスキーマを更新", "Checked database schema update for apps" : "アプリの指定データベースのスキーマを更新", "Updated \"%s\" to %s" : "\"%s\" を %s にアップデートしました。", - "Disabled incompatible apps: %s" : "無効化された非互換アプリ:%s", "No image or file provided" : "画像もしくはファイルが提供されていません", "Unknown filetype" : "不明なファイルタイプ", "Invalid image" : "無効な画像", diff --git a/core/l10n/kn.js b/core/l10n/kn.js index 6f6a15414bd..67f6759cb2f 100644 --- a/core/l10n/kn.js +++ b/core/l10n/kn.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "ಪರಿಶೀಲಿಸಿದ ದತ್ತಸಂಚಯ ಯೋಜನಾ ಅಪ್ಡೇಟ್", "Checked database schema update for apps" : "ನವೀಕರಿಸಿದ ದತ್ತಸಂಚಯದ ಯೋಜನಾ ಪ್ರತಿಗಳನ್ನು ಕಾಯಕ್ರಮಗಳೊಂದಿಗೆ ಪರಿಶೀಲಿಸಲಾಗಿದೆ", "Updated \"%s\" to %s" : "%s ರ ಆವೃತ್ತಿ %s ನ್ನು ನವೀಕರಿಸಲಾಗುತ್ತದೆ.", - "Disabled incompatible apps: %s" : "ಹೊಂದಾಣಿಕೆಯಾಗದ %s ಅಪ್ಲಿಕೇಶನ್ಗಳನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲಾಗಿದೆ", "No image or file provided" : "ಚಿತ್ರ ಅಥವಾ ಕಡತದ ಕೊರತೆ ಇದೆ", "Unknown filetype" : "ಅಪರಿಚಿತ ಕಡತ ಮಾದರಿ", "Invalid image" : "ಅಸಾಮರ್ಥ್ಯ ಚಿತ್ರ", diff --git a/core/l10n/kn.json b/core/l10n/kn.json index f1fe4ba6d15..a124f435de6 100644 --- a/core/l10n/kn.json +++ b/core/l10n/kn.json @@ -6,7 +6,6 @@ "Checked database schema update" : "ಪರಿಶೀಲಿಸಿದ ದತ್ತಸಂಚಯ ಯೋಜನಾ ಅಪ್ಡೇಟ್", "Checked database schema update for apps" : "ನವೀಕರಿಸಿದ ದತ್ತಸಂಚಯದ ಯೋಜನಾ ಪ್ರತಿಗಳನ್ನು ಕಾಯಕ್ರಮಗಳೊಂದಿಗೆ ಪರಿಶೀಲಿಸಲಾಗಿದೆ", "Updated \"%s\" to %s" : "%s ರ ಆವೃತ್ತಿ %s ನ್ನು ನವೀಕರಿಸಲಾಗುತ್ತದೆ.", - "Disabled incompatible apps: %s" : "ಹೊಂದಾಣಿಕೆಯಾಗದ %s ಅಪ್ಲಿಕೇಶನ್ಗಳನ್ನು ನಿಷ್ಕ್ರಿಯಗೊಳಿಸಲಾಗಿದೆ", "No image or file provided" : "ಚಿತ್ರ ಅಥವಾ ಕಡತದ ಕೊರತೆ ಇದೆ", "Unknown filetype" : "ಅಪರಿಚಿತ ಕಡತ ಮಾದರಿ", "Invalid image" : "ಅಸಾಮರ್ಥ್ಯ ಚಿತ್ರ", diff --git a/core/l10n/ko.js b/core/l10n/ko.js index c46252a1d0d..e6f34dcf0f6 100644 --- a/core/l10n/ko.js +++ b/core/l10n/ko.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "데이터베이스 스키마 업데이트 확인됨", "Checked database schema update for apps" : "앱용 데이터베이스 스키마 업데이트 확인됨", "Updated \"%s\" to %s" : "\"%s\"을(를) %s(으)로 업데이트함", - "Disabled incompatible apps: %s" : "호환되지 않는 앱 비활성화됨: %s", "No image or file provided" : "사진이나 파일이 없음", "Unknown filetype" : "알려지지 않은 파일 형식", "Invalid image" : "잘못된 사진", diff --git a/core/l10n/ko.json b/core/l10n/ko.json index 553f26bf2d3..39a780b46b6 100644 --- a/core/l10n/ko.json +++ b/core/l10n/ko.json @@ -6,7 +6,6 @@ "Checked database schema update" : "데이터베이스 스키마 업데이트 확인됨", "Checked database schema update for apps" : "앱용 데이터베이스 스키마 업데이트 확인됨", "Updated \"%s\" to %s" : "\"%s\"을(를) %s(으)로 업데이트함", - "Disabled incompatible apps: %s" : "호환되지 않는 앱 비활성화됨: %s", "No image or file provided" : "사진이나 파일이 없음", "Unknown filetype" : "알려지지 않은 파일 형식", "Invalid image" : "잘못된 사진", diff --git a/core/l10n/nb_NO.js b/core/l10n/nb_NO.js index c57e7649006..2537dab78ae 100644 --- a/core/l10n/nb_NO.js +++ b/core/l10n/nb_NO.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Sjekket oppdatering av databaseskjema", "Checked database schema update for apps" : "Sjekket databaseskjema-oppdatering for apper", "Updated \"%s\" to %s" : "Oppdaterte \"%s\" til %s", - "Disabled incompatible apps: %s" : "Deaktiverte ukompatible apper: %s", "No image or file provided" : "Bilde eller fil ikke angitt", "Unknown filetype" : "Ukjent filtype", "Invalid image" : "Ugyldig bilde", diff --git a/core/l10n/nb_NO.json b/core/l10n/nb_NO.json index 967f5592f39..d83a75dd017 100644 --- a/core/l10n/nb_NO.json +++ b/core/l10n/nb_NO.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Sjekket oppdatering av databaseskjema", "Checked database schema update for apps" : "Sjekket databaseskjema-oppdatering for apper", "Updated \"%s\" to %s" : "Oppdaterte \"%s\" til %s", - "Disabled incompatible apps: %s" : "Deaktiverte ukompatible apper: %s", "No image or file provided" : "Bilde eller fil ikke angitt", "Unknown filetype" : "Ukjent filtype", "Invalid image" : "Ugyldig bilde", diff --git a/core/l10n/nl.js b/core/l10n/nl.js index 9e5dd9844cc..0153b76518b 100644 --- a/core/l10n/nl.js +++ b/core/l10n/nl.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Database schema-update gecontroleerd", "Checked database schema update for apps" : "Database schema-update voor apps gecontroleerd", "Updated \"%s\" to %s" : "Bijgewerkt \"%s\" naar %s", - "Disabled incompatible apps: %s" : "Gedeactiveerde incompatibele apps: %s", "No image or file provided" : "Geen afbeelding of bestand opgegeven", "Unknown filetype" : "Onbekend bestandsformaat", "Invalid image" : "Ongeldige afbeelding", diff --git a/core/l10n/nl.json b/core/l10n/nl.json index 35de2db4f83..5e77ccec1d2 100644 --- a/core/l10n/nl.json +++ b/core/l10n/nl.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Database schema-update gecontroleerd", "Checked database schema update for apps" : "Database schema-update voor apps gecontroleerd", "Updated \"%s\" to %s" : "Bijgewerkt \"%s\" naar %s", - "Disabled incompatible apps: %s" : "Gedeactiveerde incompatibele apps: %s", "No image or file provided" : "Geen afbeelding of bestand opgegeven", "Unknown filetype" : "Onbekend bestandsformaat", "Invalid image" : "Ongeldige afbeelding", diff --git a/core/l10n/pl.js b/core/l10n/pl.js index 1509576ae7f..cc5d7eda41d 100644 --- a/core/l10n/pl.js +++ b/core/l10n/pl.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Sprawdzono aktualizację schematu bazy danych", "Checked database schema update for apps" : "Sprawdzono aktualizację schematu bazy danych dla aplikacji", "Updated \"%s\" to %s" : "Zaktualizowano \"%s\" do %s", - "Disabled incompatible apps: %s" : "Wyłączone niekompatybilne aplikacja: %s", "No image or file provided" : "Brak obrazu lub pliku dostarczonego", "Unknown filetype" : "Nieznany typ pliku", "Invalid image" : "Nieprawidłowe zdjęcie", diff --git a/core/l10n/pl.json b/core/l10n/pl.json index 46dc56ea500..8f6c1e649de 100644 --- a/core/l10n/pl.json +++ b/core/l10n/pl.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Sprawdzono aktualizację schematu bazy danych", "Checked database schema update for apps" : "Sprawdzono aktualizację schematu bazy danych dla aplikacji", "Updated \"%s\" to %s" : "Zaktualizowano \"%s\" do %s", - "Disabled incompatible apps: %s" : "Wyłączone niekompatybilne aplikacja: %s", "No image or file provided" : "Brak obrazu lub pliku dostarczonego", "Unknown filetype" : "Nieznany typ pliku", "Invalid image" : "Nieprawidłowe zdjęcie", diff --git a/core/l10n/pt_BR.js b/core/l10n/pt_BR.js index 24c5da655e8..9de63eb8f49 100644 --- a/core/l10n/pt_BR.js +++ b/core/l10n/pt_BR.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Verificado atualização do esquema de banco de dados", "Checked database schema update for apps" : "Verificar atualização do esquema de banco de dados para aplicativos", "Updated \"%s\" to %s" : "Atualizado \"%s\" para %s", - "Disabled incompatible apps: %s" : "Desabilitar aplicativos incompatíveis : %s", "No image or file provided" : "Nenhuma imagem ou arquivo fornecido", "Unknown filetype" : "Tipo de arquivo desconhecido", "Invalid image" : "Imagem inválida", diff --git a/core/l10n/pt_BR.json b/core/l10n/pt_BR.json index fd2d9645078..eae2d0519c4 100644 --- a/core/l10n/pt_BR.json +++ b/core/l10n/pt_BR.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Verificado atualização do esquema de banco de dados", "Checked database schema update for apps" : "Verificar atualização do esquema de banco de dados para aplicativos", "Updated \"%s\" to %s" : "Atualizado \"%s\" para %s", - "Disabled incompatible apps: %s" : "Desabilitar aplicativos incompatíveis : %s", "No image or file provided" : "Nenhuma imagem ou arquivo fornecido", "Unknown filetype" : "Tipo de arquivo desconhecido", "Invalid image" : "Imagem inválida", diff --git a/core/l10n/pt_PT.js b/core/l10n/pt_PT.js index c31cec07209..f636ada2549 100644 --- a/core/l10n/pt_PT.js +++ b/core/l10n/pt_PT.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Atualização do esquema da base de dados verificada.", "Checked database schema update for apps" : "Atualização do esquema da base de dados verificada.", "Updated \"%s\" to %s" : "Atualizado \"%s\" para %s", - "Disabled incompatible apps: %s" : "Apps incompatíveis desativadas: %s", "No image or file provided" : "Não foi fornecido nenhum ficheiro ou imagem", "Unknown filetype" : "Tipo de ficheiro desconhecido", "Invalid image" : "Imagem inválida", diff --git a/core/l10n/pt_PT.json b/core/l10n/pt_PT.json index a8a1e2ec17c..1deb346d4a1 100644 --- a/core/l10n/pt_PT.json +++ b/core/l10n/pt_PT.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Atualização do esquema da base de dados verificada.", "Checked database schema update for apps" : "Atualização do esquema da base de dados verificada.", "Updated \"%s\" to %s" : "Atualizado \"%s\" para %s", - "Disabled incompatible apps: %s" : "Apps incompatíveis desativadas: %s", "No image or file provided" : "Não foi fornecido nenhum ficheiro ou imagem", "Unknown filetype" : "Tipo de ficheiro desconhecido", "Invalid image" : "Imagem inválida", diff --git a/core/l10n/ro.js b/core/l10n/ro.js index 1ad37378518..dfe439306d7 100644 --- a/core/l10n/ro.js +++ b/core/l10n/ro.js @@ -6,7 +6,6 @@ OC.L10N.register( "Turned off maintenance mode" : "Modul mentenanță a fost dezactivat", "Updated database" : "Bază de date actualizată", "Updated \"%s\" to %s" : "\"%s\" a fost actualizat până la %s", - "Disabled incompatible apps: %s" : "Aplicatii incompatibile oprite: %s", "No image or file provided" : "Nu a fost furnizat vreo imagine sau fișier", "Unknown filetype" : "Tip fișier necunoscut", "Invalid image" : "Imagine invalidă", @@ -31,11 +30,13 @@ OC.L10N.register( "December" : "Decembrie", "Settings" : "Setări", "Saving..." : "Se salvează...", + "Couldn't send reset email. Please contact your administrator." : "Expedierea email-ului de resetare a eşuat. Vă rugăm să contactaţi administratorul dvs.", "I know what I'm doing" : "Eu știu ce fac", "Password can not be changed. Please contact your administrator." : "Parola nu poate fi modificata. Vă rugăm să contactați administratorul dvs.", "No" : "Nu", "Yes" : "Da", "Choose" : "Alege", + "Error loading file picker template: {error}" : "Eroare la încărcarea șablonului selectorului de fișiere: {error}", "Ok" : "Ok", "Error loading message template: {error}" : "Eroare la încărcarea şablonului de mesaje: {error}", "read-only" : "doar citire", @@ -62,10 +63,13 @@ OC.L10N.register( "Error while changing permissions" : "Eroare la modificarea permisiunilor", "Shared with you and the group {group} by {owner}" : "Distribuie cu tine si grupul {group} de {owner}", "Shared with you by {owner}" : "Distribuie cu tine de {owner}", + "Share with user or group …" : "Partajeaza cu utilizator sau cu grup", "Share link" : "Share link", + "The public link will expire no later than {days} days after it is created" : "Legătura publică va expira nu mai târziu de {days} zile de la ziua creării", "Link" : "Legătură", "Password protect" : "Protejare cu parolă", "Password" : "Parolă", + "Allow editing" : "Permite editarea", "Email link to person" : "Expediază legătura prin poșta electronică", "Send" : "Expediază", "Set expiration date" : "Specifică data expirării", @@ -80,6 +84,7 @@ OC.L10N.register( "can edit" : "poate edita", "access control" : "control acces", "create" : "creare", + "change" : "modifică", "delete" : "ștergere", "Password protected" : "Protejare cu parolă", "Error unsetting expiration date" : "Eroare la anularea datei de expirare", diff --git a/core/l10n/ro.json b/core/l10n/ro.json index ac14cb5bf14..d637984eb05 100644 --- a/core/l10n/ro.json +++ b/core/l10n/ro.json @@ -4,7 +4,6 @@ "Turned off maintenance mode" : "Modul mentenanță a fost dezactivat", "Updated database" : "Bază de date actualizată", "Updated \"%s\" to %s" : "\"%s\" a fost actualizat până la %s", - "Disabled incompatible apps: %s" : "Aplicatii incompatibile oprite: %s", "No image or file provided" : "Nu a fost furnizat vreo imagine sau fișier", "Unknown filetype" : "Tip fișier necunoscut", "Invalid image" : "Imagine invalidă", @@ -29,11 +28,13 @@ "December" : "Decembrie", "Settings" : "Setări", "Saving..." : "Se salvează...", + "Couldn't send reset email. Please contact your administrator." : "Expedierea email-ului de resetare a eşuat. Vă rugăm să contactaţi administratorul dvs.", "I know what I'm doing" : "Eu știu ce fac", "Password can not be changed. Please contact your administrator." : "Parola nu poate fi modificata. Vă rugăm să contactați administratorul dvs.", "No" : "Nu", "Yes" : "Da", "Choose" : "Alege", + "Error loading file picker template: {error}" : "Eroare la încărcarea șablonului selectorului de fișiere: {error}", "Ok" : "Ok", "Error loading message template: {error}" : "Eroare la încărcarea şablonului de mesaje: {error}", "read-only" : "doar citire", @@ -60,10 +61,13 @@ "Error while changing permissions" : "Eroare la modificarea permisiunilor", "Shared with you and the group {group} by {owner}" : "Distribuie cu tine si grupul {group} de {owner}", "Shared with you by {owner}" : "Distribuie cu tine de {owner}", + "Share with user or group …" : "Partajeaza cu utilizator sau cu grup", "Share link" : "Share link", + "The public link will expire no later than {days} days after it is created" : "Legătura publică va expira nu mai târziu de {days} zile de la ziua creării", "Link" : "Legătură", "Password protect" : "Protejare cu parolă", "Password" : "Parolă", + "Allow editing" : "Permite editarea", "Email link to person" : "Expediază legătura prin poșta electronică", "Send" : "Expediază", "Set expiration date" : "Specifică data expirării", @@ -78,6 +82,7 @@ "can edit" : "poate edita", "access control" : "control acces", "create" : "creare", + "change" : "modifică", "delete" : "ștergere", "Password protected" : "Protejare cu parolă", "Error unsetting expiration date" : "Eroare la anularea datei de expirare", diff --git a/core/l10n/ru.js b/core/l10n/ru.js index 50ac2e6d970..678858c40ee 100644 --- a/core/l10n/ru.js +++ b/core/l10n/ru.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Проверено обновление схемы БД", "Checked database schema update for apps" : "Проверено обновление схемы БД приложений", "Updated \"%s\" to %s" : "Обновлено \"%s\" до %s", - "Disabled incompatible apps: %s" : "Отключены несовместимые приложения: %s", "No image or file provided" : "Не указано изображение или файл", "Unknown filetype" : "Неизвестный тип файла", "Invalid image" : "Некорректное изображение", diff --git a/core/l10n/ru.json b/core/l10n/ru.json index 109189984aa..fc55b17dbbc 100644 --- a/core/l10n/ru.json +++ b/core/l10n/ru.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Проверено обновление схемы БД", "Checked database schema update for apps" : "Проверено обновление схемы БД приложений", "Updated \"%s\" to %s" : "Обновлено \"%s\" до %s", - "Disabled incompatible apps: %s" : "Отключены несовместимые приложения: %s", "No image or file provided" : "Не указано изображение или файл", "Unknown filetype" : "Неизвестный тип файла", "Invalid image" : "Некорректное изображение", diff --git a/core/l10n/sk_SK.js b/core/l10n/sk_SK.js index daf9d390c00..31833f9eb09 100644 --- a/core/l10n/sk_SK.js +++ b/core/l10n/sk_SK.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Skontrolovať aktualizáciu schémy databázy", "Checked database schema update for apps" : "Aktualizácia schémy databázy aplikácií bola overená", "Updated \"%s\" to %s" : "Aktualizované \"%s\" na %s", - "Disabled incompatible apps: %s" : "Zakázané nekompatibilné aplikácie: %s", "No image or file provided" : "Obrázok alebo súbor nebol zadaný", "Unknown filetype" : "Neznámy typ súboru", "Invalid image" : "Chybný obrázok", diff --git a/core/l10n/sk_SK.json b/core/l10n/sk_SK.json index 0cf5c67e63c..bee9eb8c105 100644 --- a/core/l10n/sk_SK.json +++ b/core/l10n/sk_SK.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Skontrolovať aktualizáciu schémy databázy", "Checked database schema update for apps" : "Aktualizácia schémy databázy aplikácií bola overená", "Updated \"%s\" to %s" : "Aktualizované \"%s\" na %s", - "Disabled incompatible apps: %s" : "Zakázané nekompatibilné aplikácie: %s", "No image or file provided" : "Obrázok alebo súbor nebol zadaný", "Unknown filetype" : "Neznámy typ súboru", "Invalid image" : "Chybný obrázok", diff --git a/core/l10n/sl.js b/core/l10n/sl.js index 28b0e54fca1..e880116e66b 100644 --- a/core/l10n/sl.js +++ b/core/l10n/sl.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Izbrana posodobitev sheme podatkovne zbirke", "Checked database schema update for apps" : "Izbrana posodobitev sheme podatkovne zbirke za programe", "Updated \"%s\" to %s" : "Datoteka \"%s\" je posodobljena na %s", - "Disabled incompatible apps: %s" : "Onemogočeni neskladni programi: %s", "No image or file provided" : "Ni podane datoteke ali slike", "Unknown filetype" : "Neznana vrsta datoteke", "Invalid image" : "Neveljavna slika", diff --git a/core/l10n/sl.json b/core/l10n/sl.json index 03d92bb6cec..c65ff0fd825 100644 --- a/core/l10n/sl.json +++ b/core/l10n/sl.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Izbrana posodobitev sheme podatkovne zbirke", "Checked database schema update for apps" : "Izbrana posodobitev sheme podatkovne zbirke za programe", "Updated \"%s\" to %s" : "Datoteka \"%s\" je posodobljena na %s", - "Disabled incompatible apps: %s" : "Onemogočeni neskladni programi: %s", "No image or file provided" : "Ni podane datoteke ali slike", "Unknown filetype" : "Neznana vrsta datoteke", "Invalid image" : "Neveljavna slika", diff --git a/core/l10n/sq.js b/core/l10n/sq.js index 7776db69b9f..c31b9a20253 100644 --- a/core/l10n/sq.js +++ b/core/l10n/sq.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Përditësim i skemës së kontrolluar të bazës së të dhënave", "Checked database schema update for apps" : "Përditësim i skemës së kontrolluar të bazës së të dhënave për aplikacionet", "Updated \"%s\" to %s" : "U përditësua \"%s\" në %s", - "Disabled incompatible apps: %s" : "Aplikacione të papajtueshme të bllokuara: %s", "No image or file provided" : "Nuk është dhënë asnjë imazh apo skedar", "Unknown filetype" : "Tip i panjohur skedari", "Invalid image" : "Imazh i pavlefshëm", diff --git a/core/l10n/sq.json b/core/l10n/sq.json index 2defbb25d92..d7c2a96da69 100644 --- a/core/l10n/sq.json +++ b/core/l10n/sq.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Përditësim i skemës së kontrolluar të bazës së të dhënave", "Checked database schema update for apps" : "Përditësim i skemës së kontrolluar të bazës së të dhënave për aplikacionet", "Updated \"%s\" to %s" : "U përditësua \"%s\" në %s", - "Disabled incompatible apps: %s" : "Aplikacione të papajtueshme të bllokuara: %s", "No image or file provided" : "Nuk është dhënë asnjë imazh apo skedar", "Unknown filetype" : "Tip i panjohur skedari", "Invalid image" : "Imazh i pavlefshëm", diff --git a/core/l10n/sr@latin.js b/core/l10n/sr@latin.js index 24ec80d0283..083e1095524 100644 --- a/core/l10n/sr@latin.js +++ b/core/l10n/sr@latin.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Provereno je osvežavanje šema baze podataka", "Checked database schema update for apps" : "Provereno je osvežavanje šema baze podataka za aplikacije", "Updated \"%s\" to %s" : "Osveženo je \"%s\" na \"%s\"", - "Disabled incompatible apps: %s" : "Isključene su nekompatibilne aplikacije; %s", "No image or file provided" : "Nije data slika ili fajl", "Unknown filetype" : "Nepoznat tip fajla", "Invalid image" : "Neispravna slika", diff --git a/core/l10n/sr@latin.json b/core/l10n/sr@latin.json index 9c4e3e05c03..5a03538aba0 100644 --- a/core/l10n/sr@latin.json +++ b/core/l10n/sr@latin.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Provereno je osvežavanje šema baze podataka", "Checked database schema update for apps" : "Provereno je osvežavanje šema baze podataka za aplikacije", "Updated \"%s\" to %s" : "Osveženo je \"%s\" na \"%s\"", - "Disabled incompatible apps: %s" : "Isključene su nekompatibilne aplikacije; %s", "No image or file provided" : "Nije data slika ili fajl", "Unknown filetype" : "Nepoznat tip fajla", "Invalid image" : "Neispravna slika", diff --git a/core/l10n/sv.js b/core/l10n/sv.js index 0abfbfb08fe..d275171b681 100644 --- a/core/l10n/sv.js +++ b/core/l10n/sv.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Kontrollerade uppdatering av databasschemat", "Checked database schema update for apps" : "Kontrollerade uppdatering av databasschemat för applikationer", "Updated \"%s\" to %s" : "Uppdaterade \"%s\" till %s", - "Disabled incompatible apps: %s" : "Inaktiverade inkompatibla appar: %s", "No image or file provided" : "Ingen bild eller fil har tillhandahållits", "Unknown filetype" : "Okänd filtyp", "Invalid image" : "Ogiltig bild", diff --git a/core/l10n/sv.json b/core/l10n/sv.json index 25fb4c61d26..51d2acd4ba3 100644 --- a/core/l10n/sv.json +++ b/core/l10n/sv.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Kontrollerade uppdatering av databasschemat", "Checked database schema update for apps" : "Kontrollerade uppdatering av databasschemat för applikationer", "Updated \"%s\" to %s" : "Uppdaterade \"%s\" till %s", - "Disabled incompatible apps: %s" : "Inaktiverade inkompatibla appar: %s", "No image or file provided" : "Ingen bild eller fil har tillhandahållits", "Unknown filetype" : "Okänd filtyp", "Invalid image" : "Ogiltig bild", diff --git a/core/l10n/tr.js b/core/l10n/tr.js index f7f5e00fbd9..470d6221fc1 100644 --- a/core/l10n/tr.js +++ b/core/l10n/tr.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Veritabanı şema güncellemesi denetlendi", "Checked database schema update for apps" : "Uygulamalar için veritabanı şema güncellemesi denetlendi", "Updated \"%s\" to %s" : "\"%s\", %s sürümüne güncellendi", - "Disabled incompatible apps: %s" : "Uyumsuz uygulamalar devre dışı bırakıldı: %s", "No image or file provided" : "Resim veya dosya belirtilmedi", "Unknown filetype" : "Bilinmeyen dosya türü", "Invalid image" : "Geçersiz resim", diff --git a/core/l10n/tr.json b/core/l10n/tr.json index dbedc32925e..6839f4182fa 100644 --- a/core/l10n/tr.json +++ b/core/l10n/tr.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Veritabanı şema güncellemesi denetlendi", "Checked database schema update for apps" : "Uygulamalar için veritabanı şema güncellemesi denetlendi", "Updated \"%s\" to %s" : "\"%s\", %s sürümüne güncellendi", - "Disabled incompatible apps: %s" : "Uyumsuz uygulamalar devre dışı bırakıldı: %s", "No image or file provided" : "Resim veya dosya belirtilmedi", "Unknown filetype" : "Bilinmeyen dosya türü", "Invalid image" : "Geçersiz resim", diff --git a/core/l10n/uk.js b/core/l10n/uk.js index abaa34cd71c..c9621e82403 100644 --- a/core/l10n/uk.js +++ b/core/l10n/uk.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "Перевірено оновлення схеми бази даних", "Checked database schema update for apps" : "Перевірено оновлення схеми бази даних для додатків", "Updated \"%s\" to %s" : "Оновлено \"%s\" до %s", - "Disabled incompatible apps: %s" : "Вимкнені несумісні додатки: %s", "No image or file provided" : "Немає наданого зображення або файлу", "Unknown filetype" : "Невідомий тип файлу", "Invalid image" : "Невірне зображення", diff --git a/core/l10n/uk.json b/core/l10n/uk.json index 9c10236ee06..78d963506b2 100644 --- a/core/l10n/uk.json +++ b/core/l10n/uk.json @@ -6,7 +6,6 @@ "Checked database schema update" : "Перевірено оновлення схеми бази даних", "Checked database schema update for apps" : "Перевірено оновлення схеми бази даних для додатків", "Updated \"%s\" to %s" : "Оновлено \"%s\" до %s", - "Disabled incompatible apps: %s" : "Вимкнені несумісні додатки: %s", "No image or file provided" : "Немає наданого зображення або файлу", "Unknown filetype" : "Невідомий тип файлу", "Invalid image" : "Невірне зображення", diff --git a/core/l10n/zh_CN.js b/core/l10n/zh_CN.js index 2b253177472..6f6f3eae681 100644 --- a/core/l10n/zh_CN.js +++ b/core/l10n/zh_CN.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "已经检查数据库架构更新", "Checked database schema update for apps" : "已经检查应用的数据库架构更新", "Updated \"%s\" to %s" : "更新 \"%s\" 为 %s", - "Disabled incompatible apps: %s" : "禁用不兼容应用:%s", "No image or file provided" : "没有提供图片或文件", "Unknown filetype" : "未知的文件类型", "Invalid image" : "无效的图像", diff --git a/core/l10n/zh_CN.json b/core/l10n/zh_CN.json index 744dba28020..14915c0a6f2 100644 --- a/core/l10n/zh_CN.json +++ b/core/l10n/zh_CN.json @@ -6,7 +6,6 @@ "Checked database schema update" : "已经检查数据库架构更新", "Checked database schema update for apps" : "已经检查应用的数据库架构更新", "Updated \"%s\" to %s" : "更新 \"%s\" 为 %s", - "Disabled incompatible apps: %s" : "禁用不兼容应用:%s", "No image or file provided" : "没有提供图片或文件", "Unknown filetype" : "未知的文件类型", "Invalid image" : "无效的图像", diff --git a/core/l10n/zh_TW.js b/core/l10n/zh_TW.js index 606cb52a461..fb8d85341f0 100644 --- a/core/l10n/zh_TW.js +++ b/core/l10n/zh_TW.js @@ -8,7 +8,6 @@ OC.L10N.register( "Checked database schema update" : "已檢查資料庫格式更新", "Checked database schema update for apps" : "已檢查應用程式的資料庫格式更新", "Updated \"%s\" to %s" : "已更新 %s 到 %s", - "Disabled incompatible apps: %s" : "停用不相容的應用程式:%s", "No image or file provided" : "未提供圖片或檔案", "Unknown filetype" : "未知的檔案類型", "Invalid image" : "無效的圖片", diff --git a/core/l10n/zh_TW.json b/core/l10n/zh_TW.json index d7d59312cce..85dcc38363f 100644 --- a/core/l10n/zh_TW.json +++ b/core/l10n/zh_TW.json @@ -6,7 +6,6 @@ "Checked database schema update" : "已檢查資料庫格式更新", "Checked database schema update for apps" : "已檢查應用程式的資料庫格式更新", "Updated \"%s\" to %s" : "已更新 %s 到 %s", - "Disabled incompatible apps: %s" : "停用不相容的應用程式:%s", "No image or file provided" : "未提供圖片或檔案", "Unknown filetype" : "未知的檔案類型", "Invalid image" : "無效的圖片", @@ -27,29 +27,6 @@ * along with this program. If not, see <http://www.gnu.org/licenses/> * */ -// Unfortunately we need this class for shutdown function -class TemporaryCronClass { - public static $sent = false; - public static $lockfile = ""; - public static $keeplock = false; -} - -// We use this function to handle (unexpected) shutdowns -function handleUnexpectedShutdown() { - // Delete lockfile - if (!TemporaryCronClass::$keeplock && file_exists(TemporaryCronClass::$lockfile)) { - unlink(TemporaryCronClass::$lockfile); - } - - // Say goodbye if the app did not shutdown properly - if (!TemporaryCronClass::$sent) { - if (OC::$CLI) { - echo 'Unexpected error!' . PHP_EOL; - } else { - OC_JSON::error(array('data' => array('message' => 'Unexpected error!'))); - } - } -} try { @@ -75,15 +52,11 @@ try { exit(0); } - // Handle unexpected errors - register_shutdown_function('handleUnexpectedShutdown'); - \OC::$server->getTempManager()->cleanOld(); // Exit if background jobs are disabled! - $appmode = OC_BackgroundJob::getExecutionType(); - if ($appmode == 'none') { - TemporaryCronClass::$sent = true; + $appMode = OC_BackgroundJob::getExecutionType(); + if ($appMode == 'none') { if (OC::$CLI) { echo 'Background Jobs are disabled!' . PHP_EOL; } else { @@ -93,35 +66,49 @@ try { } if (OC::$CLI) { - // Create lock file first - TemporaryCronClass::$lockfile = OC_Config::getValue("datadirectory", OC::$SERVERROOT . '/data') . '/cron.lock'; + $config = OC::$server->getConfig(); + $instanceId = $config->getSystemValue('instanceid'); + $lockFileName = 'owncloud-server-' . $instanceId . '-cron.lock'; + $lockDirectory = $config->getSystemValue('cron.lockfile.location', sys_get_temp_dir()); + $lockDirectory = rtrim($lockDirectory, '\\/'); + $lockFile = $lockDirectory . '/' . $lockFileName; + + if (!file_exists($lockFile)) { + touch($lockFile); + } // We call ownCloud from the CLI (aka cron) - if ($appmode != 'cron') { - // Use cron in future! + if ($appMode != 'cron') { OC_BackgroundJob::setExecutionType('cron'); } - // check if backgroundjobs is still running - if (file_exists(TemporaryCronClass::$lockfile)) { - TemporaryCronClass::$keeplock = true; - TemporaryCronClass::$sent = true; + // open the file and try to lock if. If it is not locked, the background + // job can be executed, otherwise another instance is already running + $fp = fopen($lockFile, 'w'); + $isLocked = flock($fp, LOCK_EX|LOCK_NB, $wouldBlock); + + // check if backgroundjobs is still running. The wouldBlock check is + // needed on systems with advisory locking, see + // http://php.net/manual/en/function.flock.php#45464 + if (!$isLocked || $wouldBlock) { echo "Another instance of cron.php is still running!" . PHP_EOL; exit(1); } - // Create a lock file - touch(TemporaryCronClass::$lockfile); - // Work $jobList = \OC::$server->getJobList(); $jobs = $jobList->getAll(); foreach ($jobs as $job) { $job->execute($jobList, $logger); } + + // unlock the file + flock($fp, LOCK_UN); + fclose($fp); + } else { // We call cron.php from some website - if ($appmode == 'cron') { + if ($appMode == 'cron') { // Cron is cron :-P OC_JSON::error(array('data' => array('message' => 'Backgroundjobs are using system cron!'))); } else { @@ -136,11 +123,9 @@ try { } } - // done! - TemporaryCronClass::$sent = true; // Log the successful cron execution if (\OC::$server->getConfig()->getSystemValue('cron_log', true)) { - \OC::$server->getAppConfig()->setValue('core', 'lastcron', time()); + \OC::$server->getConfig()->setAppValue('core', 'lastcron', time()); } exit(); diff --git a/lib/base.php b/lib/base.php index 1ffeb7bdec4..0ac39dec831 100644 --- a/lib/base.php +++ b/lib/base.php @@ -797,6 +797,9 @@ class OC { self::checkUpgrade(); } + // Always load authentication apps + OC_App::loadApps(['authentication']); + // Load minimum set of apps if (!self::checkUpgrade(false) && !$systemConfig->getValue('maintenance', false) @@ -805,8 +808,7 @@ class OC { if(OC_User::isLoggedIn()) { OC_App::loadApps(); } else { - // For guests: Load only authentication, filesystem and logging - OC_App::loadApps(array('authentication')); + // For guests: Load only filesystem and logging OC_App::loadApps(array('filesystem', 'logging')); \OC_User::tryBasicAuthLogin(); } @@ -815,7 +817,6 @@ class OC { if (!self::$CLI and (!isset($_GET["logout"]) or ($_GET["logout"] !== 'true'))) { try { if (!$systemConfig->getValue('maintenance', false) && !\OCP\Util::needUpgrade()) { - OC_App::loadApps(array('authentication')); OC_App::loadApps(array('filesystem', 'logging')); OC_App::loadApps(); } diff --git a/lib/l10n/fr.js b/lib/l10n/fr.js index aff31f2cd44..4474d946ab1 100644 --- a/lib/l10n/fr.js +++ b/lib/l10n/fr.js @@ -117,6 +117,8 @@ OC.L10N.register( "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é.", + "PHP setting \"%s\" is not set to \"%s\"." : "Le paramètre PHP \"%s\" n'est pas \"%s\".", + "Adjusting this setting in php.ini will make ownCloud run again" : "Ajuster ce paramètre dans php.ini permettra à ownCloud de fonctionner à nouveau", "Please ask your server administrator to update PHP to the latest version. Your PHP version is no longer supported by ownCloud and the PHP community." : "Veuillez demander à votre administrateur de mettre à jour PHP vers sa dernière version disponible. La vôtre n’est plus prise en charge par ownCloud ni par la communauté PHP.", "PHP is configured to populate raw post data. Since PHP 5.6 this will lead to PHP throwing notices for perfectly valid code." : "PHP est configuré pour remplir des données brutes POST. A partir de PHP 5.6, cela va générer des avis pour du code parfaitement valide.", "To fix this issue set <code>always_populate_raw_post_data</code> to <code>-1</code> in your php.ini" : "Pour corriger ce problème, configurez <code>always_populate_raw_post_data</code> à <code>-1</code> dans votre php.ini", diff --git a/lib/l10n/fr.json b/lib/l10n/fr.json index 460822d3e8b..122bd1e675b 100644 --- a/lib/l10n/fr.json +++ b/lib/l10n/fr.json @@ -115,6 +115,8 @@ "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é.", + "PHP setting \"%s\" is not set to \"%s\"." : "Le paramètre PHP \"%s\" n'est pas \"%s\".", + "Adjusting this setting in php.ini will make ownCloud run again" : "Ajuster ce paramètre dans php.ini permettra à ownCloud de fonctionner à nouveau", "Please ask your server administrator to update PHP to the latest version. Your PHP version is no longer supported by ownCloud and the PHP community." : "Veuillez demander à votre administrateur de mettre à jour PHP vers sa dernière version disponible. La vôtre n’est plus prise en charge par ownCloud ni par la communauté PHP.", "PHP is configured to populate raw post data. Since PHP 5.6 this will lead to PHP throwing notices for perfectly valid code." : "PHP est configuré pour remplir des données brutes POST. A partir de PHP 5.6, cela va générer des avis pour du code parfaitement valide.", "To fix this issue set <code>always_populate_raw_post_data</code> to <code>-1</code> in your php.ini" : "Pour corriger ce problème, configurez <code>always_populate_raw_post_data</code> à <code>-1</code> dans votre php.ini", diff --git a/lib/l10n/ru.js b/lib/l10n/ru.js index 6ee348d2fa1..2cade892280 100644 --- a/lib/l10n/ru.js +++ b/lib/l10n/ru.js @@ -117,6 +117,8 @@ OC.L10N.register( "Please install one of these locales on your system and restart your webserver." : "Установите один из этих языковых пакетов на вашу систему и перезапустите веб-сервер.", "Please ask your server administrator to install the module." : "Пожалуйста, попростите администратора сервера установить модуль.", "PHP module %s not installed." : "Не установлен PHP-модуль %s.", + "PHP setting \"%s\" is not set to \"%s\"." : "Параметр PHP \"%s\" не установлен в \"%s\".", + "Adjusting this setting in php.ini will make ownCloud run again" : "Установка этого параметра в php.ini позволит запуститься ownCloud снова.", "Please ask your server administrator to update PHP to the latest version. Your PHP version is no longer supported by ownCloud and the PHP community." : "Пожалуйста, обратитесь к администратору сервера, чтобы обновить PHP до последней версии. Установленная версия PHP больше не поддерживается ownCloud и сообществом PHP.", "PHP is configured to populate raw post data. Since PHP 5.6 this will lead to PHP throwing notices for perfectly valid code." : "В PHP включена директива \"always_populate_raw_post_data\". PHP версии 5.6 и выше, при включенной директиве, добавляет уведомления в журнал даже для абсолютно рабочего кода.", "To fix this issue set <code>always_populate_raw_post_data</code> to <code>-1</code> in your php.ini" : "Что-бы исправить эту ошибку, укажите значение <code>-1</code> в качестве значения параметра <code>always_populate_raw_post_data</code> в вашем php.ini", diff --git a/lib/l10n/ru.json b/lib/l10n/ru.json index 124b68038bd..662d0485eb9 100644 --- a/lib/l10n/ru.json +++ b/lib/l10n/ru.json @@ -115,6 +115,8 @@ "Please install one of these locales on your system and restart your webserver." : "Установите один из этих языковых пакетов на вашу систему и перезапустите веб-сервер.", "Please ask your server administrator to install the module." : "Пожалуйста, попростите администратора сервера установить модуль.", "PHP module %s not installed." : "Не установлен PHP-модуль %s.", + "PHP setting \"%s\" is not set to \"%s\"." : "Параметр PHP \"%s\" не установлен в \"%s\".", + "Adjusting this setting in php.ini will make ownCloud run again" : "Установка этого параметра в php.ini позволит запуститься ownCloud снова.", "Please ask your server administrator to update PHP to the latest version. Your PHP version is no longer supported by ownCloud and the PHP community." : "Пожалуйста, обратитесь к администратору сервера, чтобы обновить PHP до последней версии. Установленная версия PHP больше не поддерживается ownCloud и сообществом PHP.", "PHP is configured to populate raw post data. Since PHP 5.6 this will lead to PHP throwing notices for perfectly valid code." : "В PHP включена директива \"always_populate_raw_post_data\". PHP версии 5.6 и выше, при включенной директиве, добавляет уведомления в журнал даже для абсолютно рабочего кода.", "To fix this issue set <code>always_populate_raw_post_data</code> to <code>-1</code> in your php.ini" : "Что-бы исправить эту ошибку, укажите значение <code>-1</code> в качестве значения параметра <code>always_populate_raw_post_data</code> в вашем php.ini", diff --git a/lib/private/activitymanager.php b/lib/private/activitymanager.php index 30a54fa009c..c4759120a39 100644 --- a/lib/private/activitymanager.php +++ b/lib/private/activitymanager.php @@ -40,6 +40,19 @@ class ActivityManager implements IManager { */ private $extensions = array(); + /** @var array list of filters "name" => "is valid" */ + protected $validFilters = array( + 'all' => true, + 'by' => true, + 'self' => true, + ); + + /** @var array list of type icons "type" => "css class" */ + protected $typeIcons = array(); + + /** @var array list of special parameters "app" => ["text" => ["parameter" => "type"]] */ + protected $specialParameters = array(); + /** * @param $app * @param $subject @@ -124,39 +137,45 @@ class ActivityManager implements IManager { } /** - * @param array $types - * @param string $filter + * @param string $method * @return array */ - function filterNotificationTypes($types, $filter) { + function getDefaultTypes($method) { + $defaultTypes = array(); foreach($this->extensions as $extension) { $c = $extension(); if ($c instanceof IExtension) { - $result = $c->filterNotificationTypes($types, $filter); - if (is_array($result)) { - $types = $result; + $types = $c->getDefaultTypes($method); + if (is_array($types)) { + $defaultTypes = array_merge($types, $defaultTypes); } } } - return $types; + return $defaultTypes; } /** - * @param string $method - * @return array + * @param string $type + * @return string */ - function getDefaultTypes($method) { - $defaultTypes = array(); + function getTypeIcon($type) { + if (isset($this->typeIcons[$type])) { + return $this->typeIcons[$type]; + } + foreach($this->extensions as $extension) { $c = $extension(); if ($c instanceof IExtension) { - $types = $c->getDefaultTypes($method); - if (is_array($types)) { - $defaultTypes = array_merge($types, $defaultTypes); + $icon = $c->getTypeIcon($type); + if (is_string($icon)) { + $this->typeIcons[$type] = $icon; + return $icon; } } } - return $defaultTypes; + + $this->typeIcons[$type] = ''; + return ''; } /** @@ -188,38 +207,30 @@ class ActivityManager implements IManager { * @return array|false */ function getSpecialParameterList($app, $text) { + if (isset($this->specialParameters[$app][$text])) { + return $this->specialParameters[$app][$text]; + } + + if (!isset($this->specialParameters[$app])) { + $this->specialParameters[$app] = array(); + } + foreach($this->extensions as $extension) { $c = $extension(); if ($c instanceof IExtension) { $specialParameter = $c->getSpecialParameterList($app, $text); if (is_array($specialParameter)) { + $this->specialParameters[$app][$text] = $specialParameter; return $specialParameter; } } } + $this->specialParameters[$app][$text] = false; return false; } /** - * @param string $type - * @return string - */ - function getTypeIcon($type) { - foreach($this->extensions as $extension) { - $c = $extension(); - if ($c instanceof IExtension) { - $icon = $c->getTypeIcon($type); - if (is_string($icon)) { - return $icon; - } - } - } - - return ''; - } - - /** * @param array $activity * @return integer|false */ @@ -264,23 +275,54 @@ class ActivityManager implements IManager { * @return boolean */ function isFilterValid($filterValue) { + if (isset($this->validFilters[$filterValue])) { + return $this->validFilters[$filterValue]; + } + foreach($this->extensions as $extension) { $c = $extension(); if ($c instanceof IExtension) { if ($c->isFilterValid($filterValue) === true) { + $this->validFilters[$filterValue] = true; return true; } } } + $this->validFilters[$filterValue] = false; return false; } /** + * @param array $types + * @param string $filter + * @return array + */ + function filterNotificationTypes($types, $filter) { + if (!$this->isFilterValid($filter)) { + return $types; + } + + foreach($this->extensions as $extension) { + $c = $extension(); + if ($c instanceof IExtension) { + $result = $c->filterNotificationTypes($types, $filter); + if (is_array($result)) { + $types = $result; + } + } + } + return $types; + } + + /** * @param string $filter * @return array */ function getQueryForFilter($filter) { + if (!$this->isFilterValid($filter)) { + return [null, null]; + } $conditions = array(); $parameters = array(); diff --git a/lib/private/app.php b/lib/private/app.php index 365b0d09065..2950ded078a 100644 --- a/lib/private/app.php +++ b/lib/private/app.php @@ -959,39 +959,6 @@ class OC_App { } /** - * check if the current enabled apps are compatible with the current - * ownCloud version. disable them if not. - * This is important if you upgrade ownCloud and have non ported 3rd - * party apps installed. - * - * @param array $apps optional app id list to check, uses all enabled apps - * when not specified - * - * @return array containing the list of ids of the disabled apps - */ - public static function checkAppsRequirements($apps = array()) { - $disabledApps = array(); - if (empty($apps)) { - $apps = OC_App::getEnabledApps(); - } - $version = OC_Util::getVersion(); - foreach ($apps as $app) { - // check if the app is compatible with this version of ownCloud - $info = OC_App::getAppInfo($app); - if (!self::isAppCompatible($version, $info)) { - OC_Log::write('core', - 'App "' . $info['name'] . '" (' . $app . ') can\'t be used because it is' - . ' not compatible with this version of ownCloud', - OC_Log::ERROR); - OC_App::disable($app); - OC_Hook::emit('update', 'success', 'Disabled ' . $info['name'] . ' app because it is not compatible'); - $disabledApps[] = $app; - } - } - return $disabledApps; - } - - /** * Adjust the number of version parts of $version1 to match * the number of version parts of $version2. * diff --git a/lib/private/appframework/http/request.php b/lib/private/appframework/http/request.php index 959ea273280..95b99efafe8 100644 --- a/lib/private/appframework/http/request.php +++ b/lib/private/appframework/http/request.php @@ -480,8 +480,8 @@ class Request implements \ArrayAccess, \Countable, IRequest { } /** - * Returns the server protocol. It respects reverse proxy servers and load - * balancers. + * Returns the server protocol. It respects one or more reverse proxies servers + * and load balancers * @return string Server protocol (http or https) */ public function getServerProtocol() { @@ -491,7 +491,13 @@ class Request implements \ArrayAccess, \Countable, IRequest { } if (isset($this->server['HTTP_X_FORWARDED_PROTO'])) { - $proto = strtolower($this->server['HTTP_X_FORWARDED_PROTO']); + if (strpos($this->server['HTTP_X_FORWARDED_PROTO'], ',') !== false) { + $parts = explode(',', $this->server['HTTP_X_FORWARDED_PROTO']); + $proto = strtolower(trim($parts[0])); + } else { + $proto = strtolower($this->server['HTTP_X_FORWARDED_PROTO']); + } + // Verify that the protocol is always HTTP or HTTPS // default to http if an invalid value is provided return $proto === 'https' ? 'https' : 'http'; @@ -543,7 +549,7 @@ class Request implements \ArrayAccess, \Countable, IRequest { // strip off the script name's dir and file name // FIXME: Sabre does not really belong here - list($path, $name) = \Sabre\DAV\URLUtil::splitPath($scriptName); + list($path, $name) = \Sabre\HTTP\URLUtil::splitPath($scriptName); if (!empty($path)) { if($path === $pathInfo || strpos($pathInfo, $path.'/') === 0) { $pathInfo = substr($pathInfo, strlen($path)); @@ -575,7 +581,7 @@ class Request implements \ArrayAccess, \Countable, IRequest { } $pathInfo = $this->getRawPathInfo(); - // following is taken from \Sabre\DAV\URLUtil::decodePathSegment + // following is taken from \Sabre\HTTP\URLUtil::decodePathSegment $pathInfo = rawurldecode($pathInfo); $encoding = mb_detect_encoding($pathInfo, ['UTF-8', 'ISO-8859-1']); diff --git a/lib/private/connector/sabre/appenabledplugin.php b/lib/private/connector/sabre/appenabledplugin.php index 68356d3378c..e38af40c08e 100644 --- a/lib/private/connector/sabre/appenabledplugin.php +++ b/lib/private/connector/sabre/appenabledplugin.php @@ -69,7 +69,7 @@ class AppEnabledPlugin extends ServerPlugin { public function initialize(\Sabre\DAV\Server $server) { $this->server = $server; - $this->server->subscribeEvent('beforeMethod', array($this, 'checkAppEnabled'), 30); + $this->server->on('beforeMethod', array($this, 'checkAppEnabled'), 30); } /** diff --git a/lib/private/connector/sabre/auth.php b/lib/private/connector/sabre/auth.php index a095ee6e045..0fc76ea9df2 100644 --- a/lib/private/connector/sabre/auth.php +++ b/lib/private/connector/sabre/auth.php @@ -1,31 +1,7 @@ <?php -/** - * @author Arthur Schiwon <blizzz@owncloud.com> - * @author Bart Visscher <bartv@thisnet.nl> - * @author Jakob Sack <mail@jakobsack.de> - * @author Lukas Reschke <lukas@owncloud.com> - * @author Markus Goetz <markus@woboq.com> - * @author Michael Gapczynski <gapczynskim@gmail.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> - * @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/> - * - */ -class OC_Connector_Sabre_Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { +namespace OC\Connector\Sabre; + +class Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { const DAV_AUTHENTICATED = 'AUTHENTICATED_TO_DAV_BACKEND'; /** @@ -55,19 +31,19 @@ class OC_Connector_Sabre_Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { * @return bool */ protected function validateUserPass($username, $password) { - if (OC_User::isLoggedIn() && - $this->isDavAuthenticated(OC_User::getUser()) + if (\OC_User::isLoggedIn() && + $this->isDavAuthenticated(\OC_User::getUser()) ) { - OC_Util::setupFS(OC_User::getUser()); + \OC_Util::setupFS(\OC_User::getUser()); \OC::$server->getSession()->close(); return true; } else { - OC_Util::setUpFS(); //login hooks may need early access to the filesystem - if(OC_User::login($username, $password)) { + \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 // and not the HTTP auth supplied one, see issue #14048 - $ocUser = OC_User::getUser(); - OC_Util::setUpFS($ocUser); + $ocUser = \OC_User::getUser(); + \OC_Util::setUpFS($ocUser); \OC::$server->getSession()->set(self::DAV_AUTHENTICATED, $ocUser); \OC::$server->getSession()->close(); return true; @@ -86,7 +62,7 @@ class OC_Connector_Sabre_Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { * @return string|null */ public function getCurrentUser() { - $user = OC_User::getUser(); + $user = \OC_User::getUser(); if($user && $this->isDavAuthenticated($user)) { return $user; } @@ -117,11 +93,11 @@ class OC_Connector_Sabre_Auth extends \Sabre\DAV\Auth\Backend\AbstractBasic { * @return bool */ private function auth(\Sabre\DAV\Server $server, $realm) { - if (OC_User::handleApacheAuth() || - (OC_User::isLoggedIn() && is_null(\OC::$server->getSession()->get(self::DAV_AUTHENTICATED))) + if (\OC_User::handleApacheAuth() || + (\OC_User::isLoggedIn() && is_null(\OC::$server->getSession()->get(self::DAV_AUTHENTICATED))) ) { - $user = OC_User::getUser(); - OC_Util::setupFS($user); + $user = \OC_User::getUser(); + \OC_Util::setupFS($user); $this->currentUser = $user; \OC::$server->getSession()->close(); return true; diff --git a/lib/private/connector/sabre/custompropertiesbackend.php b/lib/private/connector/sabre/custompropertiesbackend.php new file mode 100644 index 00000000000..eaf13238b63 --- /dev/null +++ b/lib/private/connector/sabre/custompropertiesbackend.php @@ -0,0 +1,347 @@ +<?php + +/** + * ownCloud + * + * @author Vincent Petry + * @copyright 2015 Vincent Petry <pvince81@owncloud.com> + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE + * License as published by the Free Software Foundation; either + * version 3 of the License, or any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU AFFERO GENERAL PUBLIC LICENSE for more details. + * + * You should have received a copy of the GNU Affero General Public + * License along with this library. If not, see <http://www.gnu.org/licenses/>. + * + */ + +namespace OC\Connector\Sabre; + +use \Sabre\DAV\PropFind; +use \Sabre\DAV\PropPatch; +use \Sabre\HTTP\RequestInterface; +use \Sabre\HTTP\ResponseInterface; + +class CustomPropertiesBackend implements \Sabre\DAV\PropertyStorage\Backend\BackendInterface { + + /** + * Ignored properties + * + * @var array + */ + private $ignoredProperties = array( + '{DAV:}getcontentlength', + '{DAV:}getcontenttype', + '{DAV:}getetag', + '{DAV:}quota-used-bytes', + '{DAV:}quota-available-bytes', + '{DAV:}quota-available-bytes', + '{http://owncloud.org/ns}permissions', + '{http://owncloud.org/ns}downloadURL', + '{http://owncloud.org/ns}dDC', + '{http://owncloud.org/ns}size', + ); + + /** + * @var \Sabre\DAV\Tree + */ + private $tree; + + /** + * @var \OCP\IDBConnection + */ + private $connection; + + /** + * @var \OCP\IUser + */ + private $user; + + /** + * Properties cache + * + * @var array + */ + private $cache = []; + + /** + * @param \Sabre\DAV\Tree $tree node tree + * @param \OCP\IDBConnection $connection database connection + * @param \OCP\IUser $user owner of the tree and properties + */ + public function __construct( + \Sabre\DAV\Tree $tree, + \OCP\IDBConnection $connection, + \OCP\IUser $user) { + $this->tree = $tree; + $this->connection = $connection; + $this->user = $user->getUID(); + } + + /** + * Fetches properties for a path. + * + * @param string $path + * @param PropFind $propFind + * @return void + */ + public function propFind($path, PropFind $propFind) { + $node = $this->tree->getNodeForPath($path); + if (!($node instanceof \OC\Connector\Sabre\Node)) { + return; + } + + $requestedProps = $propFind->get404Properties(); + + // these might appear + $requestedProps = array_diff( + $requestedProps, + $this->ignoredProperties + ); + + if (empty($requestedProps)) { + return; + } + + if ($node instanceof \OC\Connector\Sabre\Directory + && $propFind->getDepth() !== 0 + ) { + // note: pre-fetching only supported for depth <= 1 + $this->loadChildrenProperties($node, $requestedProps); + } + + $props = $this->getProperties($node, $requestedProps); + foreach ($props as $propName => $propValue) { + $propFind->set($propName, $propValue); + } + } + + /** + * Updates properties for a path + * + * @param string $path + * @param PropPatch $propPatch + * + * @return void + */ + public function propPatch($path, PropPatch $propPatch) { + $node = $this->tree->getNodeForPath($path); + if (!($node instanceof \OC\Connector\Sabre\Node)) { + return; + } + + $propPatch->handleRemaining(function($changedProps) use ($node) { + return $this->updateProperties($node, $changedProps); + }); + } + + /** + * This method is called after a node is deleted. + * + * @param string $path path of node for which to delete properties + */ + public function delete($path) { + $statement = $this->connection->prepare( + 'DELETE FROM `*PREFIX*properties` WHERE `userid` = ? AND `propertypath` = ?' + ); + $statement->execute(array($this->user, '/' . $path)); + $statement->closeCursor(); + + unset($this->cache[$path]); + } + + /** + * This method is called after a successful MOVE + * + * @param string $source + * @param string $destination + * + * @return void + */ + public function move($source, $destination) { + $statement = $this->connection->prepare( + 'UPDATE `*PREFIX*properties` SET `propertypath` = ?' . + ' WHERE `userid` = ? AND `propertypath` = ?' + ); + $statement->execute(array('/' . $destination, $this->user, '/' . $source)); + $statement->closeCursor(); + } + + /** + * Returns a list of properties for this nodes.; + * @param \OC\Connector\Sabre\Node $node + * @param array $requestedProperties requested properties or empty array for "all" + * @return array + * @note The properties list is a list of propertynames the client + * requested, encoded as xmlnamespace#tagName, for example: + * http://www.example.org/namespace#author If the array is empty, all + * properties should be returned + */ + private function getProperties(\OC\Connector\Sabre\Node $node, array $requestedProperties) { + $path = $node->getPath(); + if (isset($this->cache[$path])) { + return $this->cache[$path]; + } + + // TODO: chunking if more than 1000 properties + $sql = 'SELECT * FROM `*PREFIX*properties` WHERE `userid` = ? AND `propertypath` = ?'; + + $whereValues = array($this->user, $path); + $whereTypes = array(null, null); + + if (!empty($requestedProperties)) { + // request only a subset + $sql .= ' AND `propertyname` in (?)'; + $whereValues[] = $requestedProperties; + $whereTypes[] = \Doctrine\DBAL\Connection::PARAM_STR_ARRAY; + } + + $result = $this->connection->executeQuery( + $sql, + $whereValues, + $whereTypes + ); + + $props = []; + while ($row = $result->fetch()) { + $props[$row['propertyname']] = $row['propertyvalue']; + } + + $result->closeCursor(); + + $this->cache[$path] = $props; + return $props; + } + + /** + * Update properties + * + * @param \OC\Connector\Sabre\Node $node node for which to update properties + * @param array $properties array of properties to update + * + * @return bool + */ + private function updateProperties($node, $properties) { + $path = $node->getPath(); + + $deleteStatement = $this->connection->prepare( + 'DELETE FROM `*PREFIX*properties`' . + ' WHERE `userid` = ? AND `propertypath` = ? AND `propertyname` = ?' + ); + + $insertStatement = $this->connection->prepare( + 'INSERT INTO `*PREFIX*properties`' . + ' (`userid`,`propertypath`,`propertyname`,`propertyvalue`) VALUES(?,?,?,?)' + ); + + $updateStatement = $this->connection->prepare( + 'UPDATE `*PREFIX*properties` SET `propertyvalue` = ?' . + ' WHERE `userid` = ? AND `propertypath` = ? AND `propertyname` = ?' + ); + + // TODO: use "insert or update" strategy ? + $existing = $this->getProperties($node, array()); + $this->connection->beginTransaction(); + foreach ($properties as $propertyName => $propertyValue) { + // If it was null, we need to delete the property + if (is_null($propertyValue)) { + if (array_key_exists($propertyName, $existing)) { + $deleteStatement->execute( + array( + $this->user, + $path, + $propertyName + ) + ); + $deleteStatement->closeCursor(); + } + } else { + if (!array_key_exists($propertyName, $existing)) { + $insertStatement->execute( + array( + $this->user, + $path, + $propertyName, + $propertyValue + ) + ); + $insertStatement->closeCursor(); + } else { + $updateStatement->execute( + array( + $propertyValue, + $this->user, + $path, + $propertyName + ) + ); + $updateStatement->closeCursor(); + } + } + } + + $this->connection->commit(); + unset($this->cache[$path]); + + return true; + } + + /** + * Bulk load properties for directory children + * + * @param \OC\Connector\Sabre\Directory $node + * @param array $requestedProperties requested properties + * + * @return void + */ + private function loadChildrenProperties(\OC\Connector\Sabre\Directory $node, $requestedProperties) { + $path = $node->getPath(); + if (isset($this->cache[$path])) { + // we already loaded them at some point + return; + } + + $childNodes = $node->getChildren(); + // pre-fill cache + foreach ($childNodes as $childNode) { + $this->cache[$childNode->getPath()] = []; + } + + $sql = 'SELECT * FROM `*PREFIX*properties` WHERE `userid` = ? AND `propertypath` LIKE ?'; + $sql .= ' AND `propertyname` in (?) ORDER BY `propertypath`, `propertyname`'; + + $result = $this->connection->executeQuery( + $sql, + array($this->user, rtrim($path, '/') . '/%', $requestedProperties), + array(null, null, \Doctrine\DBAL\Connection::PARAM_STR_ARRAY) + ); + + $props = []; + $oldPath = null; + $props = []; + while ($row = $result->fetch()) { + $path = $row['propertypath']; + if ($oldPath !== $path) { + // save previously gathered props + $this->cache[$oldPath] = $props; + $oldPath = $path; + // prepare props for next path + $props = []; + } + $props[$row['propertyname']] = $row['propertyvalue']; + } + if (!is_null($oldPath)) { + // save props from last run + $this->cache[$oldPath] = $props; + } + + $result->closeCursor(); + } + +} diff --git a/lib/private/connector/sabre/directory.php b/lib/private/connector/sabre/directory.php index 682fd62ee37..f13a0d7bbd8 100644 --- a/lib/private/connector/sabre/directory.php +++ b/lib/private/connector/sabre/directory.php @@ -1,4 +1,6 @@ <?php +namespace OC\Connector\Sabre; + /** * @author Arthur Schiwon <blizzz@owncloud.com> * @author Bart Visscher <bartv@thisnet.nl> @@ -24,7 +26,7 @@ * along with this program. If not, see <http://www.gnu.org/licenses/> * */ -class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node +class Directory extends \OC\Connector\Sabre\Node implements \Sabre\DAV\ICollection, \Sabre\DAV\IQuota { /** @@ -74,7 +76,7 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node if (isset($_SERVER['HTTP_OC_CHUNKED'])) { // exit if we can't create a new file and we don't updatable existing file - $info = OC_FileChunking::decodeName($name); + $info = \OC_FileChunking::decodeName($name); if (!$this->fileView->isCreatable($this->path) && !$this->fileView->isUpdatable($this->path . '/' . $info['name']) ) { @@ -91,7 +93,7 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node $path = $this->fileView->getAbsolutePath($this->path) . '/' . $name; // using a dummy FileInfo is acceptable here since it will be refreshed after the put is complete $info = new \OC\Files\FileInfo($path, null, null, array(), null); - $node = new OC_Connector_Sabre_File($this->fileView, $info); + $node = new \OC\Connector\Sabre\File($this->fileView, $info); return $node->put($data); } catch (\OCP\Files\StorageNotAvailableException $e) { throw new \Sabre\DAV\Exception\ServiceUnavailable($e->getMessage()); @@ -143,9 +145,9 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node } if ($info['mimetype'] == 'httpd/unix-directory') { - $node = new OC_Connector_Sabre_Directory($this->fileView, $info); + $node = new \OC\Connector\Sabre\Directory($this->fileView, $info); } else { - $node = new OC_Connector_Sabre_File($this->fileView, $info); + $node = new \OC\Connector\Sabre\File($this->fileView, $info); } return $node; } @@ -161,42 +163,9 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node } $folderContent = $this->fileView->getDirectoryContent($this->path); - $properties = array(); - $paths = array(); - foreach ($folderContent as $info) { - $name = $info->getName(); - $paths[] = $this->path . '/' . $name; - $properties[$this->path . '/' . $name][self::GETETAG_PROPERTYNAME] = '"' . $info->getEtag() . '"'; - } - // TODO: move this to a beforeGetPropertiesForPath event to pre-cache properties - // TODO: only fetch the requested properties - if (count($paths) > 0) { - // - // the number of arguments within IN conditions are limited in most databases - // we chunk $paths into arrays of 200 items each to meet this criteria - // - $chunks = array_chunk($paths, 200, false); - foreach ($chunks as $pack) { - $placeholders = join(',', array_fill(0, count($pack), '?')); - $query = OC_DB::prepare('SELECT * FROM `*PREFIX*properties`' - . ' WHERE `userid` = ?' . ' AND `propertypath` IN (' . $placeholders . ')'); - array_unshift($pack, OC_User::getUser()); // prepend userid - $result = $query->execute($pack); - while ($row = $result->fetchRow()) { - $propertypath = $row['propertypath']; - $propertyname = $row['propertyname']; - $propertyvalue = $row['propertyvalue']; - if ($propertyname !== self::GETETAG_PROPERTYNAME) { - $properties[$propertypath][$propertyname] = $propertyvalue; - } - } - } - } - $nodes = array(); foreach ($folderContent as $info) { $node = $this->getChild($info->getName(), $info); - $node->setPropertyCache($properties[$this->path . '/' . $info->getName()]); $nodes[] = $node; } $this->dirContent = $nodes; @@ -210,7 +179,13 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node * @return bool */ public function childExists($name) { - + // note: here we do NOT resolve the chunk file name to the real file name + // to make sure we return false when checking for file existence with a chunk + // file name. + // This is to make sure that "createFile" is still triggered + // (required old code) instead of "updateFile". + // + // TODO: resolve chunk file name here and implement "updateFile" $path = $this->path . '/' . $name; return $this->fileView->file_exists($path); @@ -245,7 +220,7 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node return $this->quotaInfo; } try { - $storageInfo = OC_Helper::getStorageInfo($this->info->getPath(), $this->info); + $storageInfo = \OC_Helper::getStorageInfo($this->info->getPath(), $this->info); $this->quotaInfo = array( $storageInfo['used'], $storageInfo['free'] @@ -256,32 +231,4 @@ class OC_Connector_Sabre_Directory extends OC_Connector_Sabre_Node } } - /** - * Returns a list of properties for this nodes.; - * - * The properties list is a list of propertynames the client requested, - * encoded as xmlnamespace#tagName, for example: - * http://www.example.org/namespace#author - * If the array is empty, all properties should be returned - * - * @param array $properties - * @return array - */ - public function getProperties($properties) { - $props = parent::getProperties($properties); - if (in_array(self::GETETAG_PROPERTYNAME, $properties) && !isset($props[self::GETETAG_PROPERTYNAME])) { - $props[self::GETETAG_PROPERTYNAME] = $this->info->getEtag(); - } - return $props; - } - - /** - * Returns the size of the node, in bytes - * - * @return int - */ - public function getSize() { - return $this->info->getSize(); - } - } diff --git a/lib/private/connector/sabre/dummygetresponseplugin.php b/lib/private/connector/sabre/dummygetresponseplugin.php new file mode 100644 index 00000000000..0b78fe7dcb3 --- /dev/null +++ b/lib/private/connector/sabre/dummygetresponseplugin.php @@ -0,0 +1,43 @@ +<?php +/** + * Copyright (c) 2015 Lukas Reschke <lukas@owncloud.com> + * This file is licensed under the Affero General Public License version 3 or + * later. + * See the COPYING-README file. + */ + +namespace OC\Connector\Sabre; + +/** + * Class DummyGetResponsePlugin is a plugin used to not show a "Not implemented" + * error to clients that rely on verifying the functionality of the ownCloud + * WebDAV backend using a simple GET to /. + * + * This is considered a legacy behaviour and implementers should consider sending + * a PROPFIND request instead to verify whether the WebDAV component is working + * properly. + * + * FIXME: Remove once clients are all compliant. + * + * @package OC\Connector\Sabre + */ +class DummyGetResponsePlugin extends \Sabre\DAV\ServerPlugin { + /** @var \Sabre\DAV\Server */ + protected $server; + + /** + * @param \Sabre\DAV\Server $server + * @return void + */ + function initialize(\Sabre\DAV\Server $server) { + $this->server = $server; + $this->server->on('method:GET', [$this,'httpGet'], 200); + } + + /** + * @return false + */ + function httpGet() { + return false; + } +} diff --git a/lib/private/connector/sabre/exception/entitytoolarge.php b/lib/private/connector/sabre/exception/entitytoolarge.php index 2d2a264fe6f..e18ac859dd5 100644 --- a/lib/private/connector/sabre/exception/entitytoolarge.php +++ b/lib/private/connector/sabre/exception/entitytoolarge.php @@ -1,24 +1,9 @@ <?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/> - * - */ -class OC_Connector_Sabre_Exception_EntityTooLarge extends \Sabre\DAV\Exception { + + +namespace OC\Connector\Sabre\Exception; + +class EntityTooLarge extends \Sabre\DAV\Exception { /** * Returns the HTTP status code for this exception diff --git a/lib/private/connector/sabre/exception/filelocked.php b/lib/private/connector/sabre/exception/filelocked.php index ce110e3cb37..6b6b7b0d856 100644 --- a/lib/private/connector/sabre/exception/filelocked.php +++ b/lib/private/connector/sabre/exception/filelocked.php @@ -1,26 +1,10 @@ <?php -/** - * @author Lukas Reschke <lukas@owncloud.com> - * @author Owen Winkler <a_github@midnightcircus.com> - * @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/> - * - */ -class OC_Connector_Sabre_Exception_FileLocked extends \Sabre\DAV\Exception { + +namespace OC\Connector\Sabre\Exception; + +use Exception; + +class FileLocked extends \Sabre\DAV\Exception { public function __construct($message = "", $code = 0, Exception $previous = null) { if($previous instanceof \OCP\Files\LockNotAcquiredException) { diff --git a/lib/private/connector/sabre/exception/unsupportedmediatype.php b/lib/private/connector/sabre/exception/unsupportedmediatype.php index ce6db21d89b..5a3716ae71b 100644 --- a/lib/private/connector/sabre/exception/unsupportedmediatype.php +++ b/lib/private/connector/sabre/exception/unsupportedmediatype.php @@ -1,24 +1,9 @@ <?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/> - * - */ -class OC_Connector_Sabre_Exception_UnsupportedMediaType extends \Sabre\DAV\Exception { + + +namespace OC\Connector\Sabre\Exception; + +class UnsupportedMediaType extends \Sabre\DAV\Exception { /** * Returns the HTTP status code for this exception diff --git a/lib/private/connector/sabre/exceptionloggerplugin.php b/lib/private/connector/sabre/exceptionloggerplugin.php index 2b2753c47e4..6ae57b3ec56 100644 --- a/lib/private/connector/sabre/exceptionloggerplugin.php +++ b/lib/private/connector/sabre/exceptionloggerplugin.php @@ -1,26 +1,8 @@ <?php -/** - * @author Thomas Müller <thomas.mueller@tmit.eu> - * @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/> - * - */ -class OC_Connector_Sabre_ExceptionLoggerPlugin extends \Sabre\DAV\ServerPlugin -{ + +namespace OC\Connector\Sabre; + +class ExceptionLoggerPlugin extends \Sabre\DAV\ServerPlugin { private $nonFatalExceptions = array( 'Sabre\DAV\Exception\NotAuthenticated' => true, // the sync client uses this to find out whether files exist, @@ -54,7 +36,7 @@ class OC_Connector_Sabre_ExceptionLoggerPlugin extends \Sabre\DAV\ServerPlugin */ public function initialize(\Sabre\DAV\Server $server) { - $server->subscribeEvent('exception', array($this, 'logException'), 10); + $server->on('exception', array($this, 'logException'), 10); } /** diff --git a/lib/private/connector/sabre/file.php b/lib/private/connector/sabre/file.php index 9b529d2e0f1..0355376c46b 100644 --- a/lib/private/connector/sabre/file.php +++ b/lib/private/connector/sabre/file.php @@ -1,38 +1,7 @@ <?php -/** - * @author Andreas Fischer <bantu@owncloud.com> - * @author Bart Visscher <bartv@thisnet.nl> - * @author Bjoern Schiessle <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@gmx.de> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Lukas Reschke <lukas@owncloud.com> - * @author Owen Winkler <a_github@midnightcircus.com> - * @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 - * - * 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 OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\DAV\IFile { +namespace OC\Connector\Sabre; + +class File extends \OC\Connector\Sabre\Node implements \Sabre\DAV\IFile { /** * Updates the data @@ -52,11 +21,12 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ * return an ETag, and just return null. * * @param resource $data + * * @throws \Sabre\DAV\Exception\Forbidden - * @throws OC_Connector_Sabre_Exception_UnsupportedMediaType + * @throws \OC\Connector\Sabre\Exception\UnsupportedMediaType * @throws \Sabre\DAV\Exception\BadRequest * @throws \Sabre\DAV\Exception - * @throws OC_Connector_Sabre_Exception_EntityTooLarge + * @throws \OC\Connector\Sabre\Exception\EntityTooLarge * @throws \Sabre\DAV\Exception\ServiceUnavailable * @return string|null */ @@ -110,11 +80,11 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ } catch (\OCP\Files\EntityTooLargeException $e) { // the file is too big to be stored - throw new OC_Connector_Sabre_Exception_EntityTooLarge($e->getMessage()); + throw new \OC\Connector\Sabre\Exception\EntityTooLarge($e->getMessage()); } catch (\OCP\Files\InvalidContentException $e) { // the file content is not permitted - throw new OC_Connector_Sabre_Exception_UnsupportedMediaType($e->getMessage()); + throw new \OC\Connector\Sabre\Exception\UnsupportedMediaType($e->getMessage()); } catch (\OCP\Files\InvalidPathException $e) { // the path for the file was not valid @@ -122,7 +92,7 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ throw new \Sabre\DAV\Exception\Forbidden($e->getMessage()); } catch (\OCP\Files\LockNotAcquiredException $e) { // the file is currently being written to by another process - throw new OC_Connector_Sabre_Exception_FileLocked($e->getMessage(), $e->getCode(), $e); + throw new \OC\Connector\Sabre\Exception\FileLocked($e->getMessage(), $e->getCode(), $e); } catch (\OCA\Files_Encryption\Exception\EncryptionException $e) { throw new \Sabre\DAV\Exception\Forbidden($e->getMessage()); } catch (\OCP\Files\StorageNotAvailableException $e) { @@ -155,7 +125,7 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ } catch (\OCP\Files\LockNotAcquiredException $e) { // the file is currently being written to by another process - throw new OC_Connector_Sabre_Exception_FileLocked($e->getMessage(), $e->getCode(), $e); + throw new \OC\Connector\Sabre\Exception\FileLocked($e->getMessage(), $e->getCode(), $e); } } @@ -215,34 +185,6 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ } catch (\OCP\Files\StorageNotAvailableException $e) { throw new \Sabre\DAV\Exception\ServiceUnavailable("Failed to unlink: ".$e->getMessage()); } - - // remove properties - $this->removeProperties(); - - } - - /** - * Returns the size of the node, in bytes - * - * @return int|float - */ - public function getSize() { - return $this->info->getSize(); - } - - /** - * Returns the ETag for a file - * - * An ETag is a unique identifier representing the current version of the - * file. If the file changes, the ETag MUST change. The ETag is an - * arbitrary string, but MUST be surrounded by double-quotes. - * - * Return null if the ETag can not effectively be determined - * - * @return mixed - */ - public function getETag() { - return '"' . $this->info->getEtag() . '"'; } /** @@ -288,13 +230,13 @@ class OC_Connector_Sabre_File extends OC_Connector_Sabre_Node implements \Sabre\ */ private function createFileChunked($data) { - list($path, $name) = \Sabre\DAV\URLUtil::splitPath($this->path); + list($path, $name) = \Sabre\HTTP\URLUtil::splitPath($this->path); - $info = OC_FileChunking::decodeName($name); + $info = \OC_FileChunking::decodeName($name); if (empty($info)) { throw new \Sabre\DAV\Exception\NotImplemented(); } - $chunk_handler = new OC_FileChunking($info); + $chunk_handler = new \OC_FileChunking($info); $bytesWritten = $chunk_handler->store($info['index'], $data); //detect aborted upload diff --git a/lib/private/connector/sabre/filesplugin.php b/lib/private/connector/sabre/filesplugin.php index d62f4e4ce53..1932dabd393 100644 --- a/lib/private/connector/sabre/filesplugin.php +++ b/lib/private/connector/sabre/filesplugin.php @@ -1,30 +1,21 @@ <?php -/** - * @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 - * - * 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 OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin -{ +namespace OC\Connector\Sabre; + +use \Sabre\DAV\PropFind; +use \Sabre\DAV\PropPatch; +use \Sabre\HTTP\RequestInterface; +use \Sabre\HTTP\ResponseInterface; + +class FilesPlugin extends \Sabre\DAV\ServerPlugin { // namespace const NS_OWNCLOUD = 'http://owncloud.org/ns'; + const FILEID_PROPERTYNAME = '{http://owncloud.org/ns}id'; + const PERMISSIONS_PROPERTYNAME = '{http://owncloud.org/ns}permissions'; + const DOWNLOADURL_PROPERTYNAME = '{http://owncloud.org/ns}downloadURL'; + const SIZE_PROPERTYNAME = '{http://owncloud.org/ns}size'; + const GETETAG_PROPERTYNAME = '{DAV:}getetag'; + const GETLASTMODIFIED_PROPERTYNAME = '{DAV:}getlastmodified'; /** * Reference to main server object @@ -34,6 +25,15 @@ class OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin private $server; /** + * @var \Sabre\DAV\Tree + */ + private $tree; + + public function __construct(\Sabre\DAV\Tree $tree) { + $this->tree = $tree; + } + + /** * This initializes the plugin. * * This function is called by \Sabre\DAV\Server, after @@ -47,69 +47,101 @@ class OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin public function initialize(\Sabre\DAV\Server $server) { $server->xmlNamespaces[self::NS_OWNCLOUD] = 'oc'; - $server->protectedProperties[] = '{' . self::NS_OWNCLOUD . '}id'; - $server->protectedProperties[] = '{' . self::NS_OWNCLOUD . '}permissions'; - $server->protectedProperties[] = '{' . self::NS_OWNCLOUD . '}size'; - $server->protectedProperties[] = '{' . self::NS_OWNCLOUD . '}downloadURL'; + $server->protectedProperties[] = self::FILEID_PROPERTYNAME; + $server->protectedProperties[] = self::PERMISSIONS_PROPERTYNAME; + $server->protectedProperties[] = self::SIZE_PROPERTYNAME; + $server->protectedProperties[] = self::DOWNLOADURL_PROPERTYNAME; + + // normally these cannot be changed (RFC4918), but we want them modifiable through PROPPATCH + $allowedProperties = ['{DAV:}getetag', '{DAV:}getlastmodified']; + $server->protectedProperties = array_diff($server->protectedProperties, $allowedProperties); $this->server = $server; - $this->server->subscribeEvent('beforeGetProperties', array($this, 'beforeGetProperties')); - $this->server->subscribeEvent('afterBind', array($this, 'sendFileIdHeader')); - $this->server->subscribeEvent('afterWriteContent', array($this, 'sendFileIdHeader')); + $this->server->on('propFind', array($this, 'handleGetProperties')); + $this->server->on('propPatch', array($this, 'handleUpdateProperties')); + $this->server->on('afterBind', array($this, 'sendFileIdHeader')); + $this->server->on('afterWriteContent', array($this, 'sendFileIdHeader')); + $this->server->on('beforeMethod:GET', array($this, 'handleRangeHeaders')); } /** * Adds all ownCloud-specific properties * - * @param string $path + * @param PropFind $propFind * @param \Sabre\DAV\INode $node - * @param array $requestedProperties - * @param array $returnedProperties * @return void */ - public function beforeGetProperties($path, \Sabre\DAV\INode $node, array &$requestedProperties, array &$returnedProperties) { + public function handleGetProperties(PropFind $propFind, \Sabre\DAV\INode $node) { - if ($node instanceof OC_Connector_Sabre_Node) { + if ($node instanceof \OC\Connector\Sabre\Node) { - $fileIdPropertyName = '{' . self::NS_OWNCLOUD . '}id'; - $permissionsPropertyName = '{' . self::NS_OWNCLOUD . '}permissions'; - if (array_search($fileIdPropertyName, $requestedProperties)) { - unset($requestedProperties[array_search($fileIdPropertyName, $requestedProperties)]); - } - if (array_search($permissionsPropertyName, $requestedProperties)) { - unset($requestedProperties[array_search($permissionsPropertyName, $requestedProperties)]); - } + $propFind->handle(self::FILEID_PROPERTYNAME, function() use ($node) { + return $node->getFileId(); + }); - /** @var $node OC_Connector_Sabre_Node */ - $fileId = $node->getFileId(); - if (!is_null($fileId)) { - $returnedProperties[200][$fileIdPropertyName] = $fileId; - } + $propFind->handle(self::PERMISSIONS_PROPERTYNAME, function() use ($node) { + return $node->getDavPermissions(); + }); - $permissions = $node->getDavPermissions(); - if (!is_null($permissions)) { - $returnedProperties[200][$permissionsPropertyName] = $permissions; - } + $propFind->handle(self::GETETAG_PROPERTYNAME, function() use ($node) { + return $node->getEtag(); + }); } - if ($node instanceof OC_Connector_Sabre_File) { - /** @var $node OC_Connector_Sabre_File */ - $directDownloadUrl = $node->getDirectDownload(); - if (isset($directDownloadUrl['url'])) { - $directDownloadUrlPropertyName = '{' . self::NS_OWNCLOUD . '}downloadURL'; - $returnedProperties[200][$directDownloadUrlPropertyName] = $directDownloadUrl['url']; - } + if ($node instanceof \OC\Connector\Sabre\File) { + $propFind->handle(self::DOWNLOADURL_PROPERTYNAME, function() use ($node) { + /** @var $node \OC\Connector\Sabre\File */ + $directDownloadUrl = $node->getDirectDownload(); + if (isset($directDownloadUrl['url'])) { + return $directDownloadUrl['url']; + } + return false; + }); } - if ($node instanceof OC_Connector_Sabre_Directory) { - $sizePropertyName = '{' . self::NS_OWNCLOUD . '}size'; - - /** @var $node OC_Connector_Sabre_Directory */ - $returnedProperties[200][$sizePropertyName] = $node->getSize(); + if ($node instanceof \OC\Connector\Sabre\Directory) { + $propFind->handle(self::SIZE_PROPERTYNAME, function() use ($node) { + return $node->getSize(); + }); } } /** + * Update ownCloud-specific properties + * + * @param string $path + * @param PropPatch $propPatch + * + * @return void + */ + public function handleUpdateProperties($path, PropPatch $propPatch) { + $propPatch->handle(self::GETLASTMODIFIED_PROPERTYNAME, function($time) use ($path) { + if (empty($time)) { + return false; + } + $node = $this->tree->getNodeForPath($path); + if (is_null($node)) { + return 404; + } + $node->touch($time); + return true; + }); + $propPatch->handle(self::GETETAG_PROPERTYNAME, function($etag) use ($path) { + if (empty($etag)) { + return false; + } + $node = $this->tree->getNodeForPath($path); + if (is_null($node)) { + return 404; + } + if ($node->setEtag($etag) !== -1) { + return true; + } + return false; + }); + } + + /** * @param string $filePath * @param \Sabre\DAV\INode $node * @throws \Sabre\DAV\Exception\BadRequest @@ -117,8 +149,8 @@ class OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin public function sendFileIdHeader($filePath, \Sabre\DAV\INode $node = null) { // chunked upload handling if (isset($_SERVER['HTTP_OC_CHUNKED'])) { - list($path, $name) = \Sabre\DAV\URLUtil::splitPath($filePath); - $info = OC_FileChunking::decodeName($name); + list($path, $name) = \Sabre\HTTP\URLUtil::splitPath($filePath); + $info = \OC_FileChunking::decodeName($name); if (!empty($info)) { $filePath = $path . '/' . $info['name']; } @@ -129,7 +161,7 @@ class OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin return; } $node = $this->server->tree->getNodeForPath($filePath); - if ($node instanceof OC_Connector_Sabre_Node) { + if ($node instanceof \OC\Connector\Sabre\Node) { $fileId = $node->getFileId(); if (!is_null($fileId)) { $this->server->httpResponse->setHeader('OC-FileId', $fileId); @@ -137,4 +169,17 @@ class OC_Connector_Sabre_FilesPlugin extends \Sabre\DAV\ServerPlugin } } + /** + * Remove range headers if encryption is enabled. + * + * @param RequestInterface $request + * @param ResponseInterface $response + */ + public function handleRangeHeaders(RequestInterface $request, ResponseInterface $response) { + if (\OC_App::isEnabled('files_encryption')) { + // encryption does not support range requests (yet) + $request->removeHeader('range'); + } + } + } diff --git a/lib/private/connector/sabre/locks.php b/lib/private/connector/sabre/locks.php deleted file mode 100644 index ec14f1d71b5..00000000000 --- a/lib/private/connector/sabre/locks.php +++ /dev/null @@ -1,191 +0,0 @@ -<?php -/** - * @author Bart Visscher <bartv@thisnet.nl> - * @author Felix Moeller <mail@felixmoeller.de> - * @author Jakob Sack <mail@jakobsack.de> - * @author Jörn Friedrich Dreyer <jfd@butonic.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 - * - * 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 OC_Connector_Sabre_Locks extends \Sabre\DAV\Locks\Backend\AbstractBackend { - - /** - * Returns a list of \Sabre\DAV\Locks_LockInfo objects - * - * This method should return all the locks for a particular uri, including - * locks that might be set on a parent uri. - * - * If returnChildLocks is set to true, this method should also look for - * any locks in the subtree of the uri for locks. - * - * @param string $uri - * @param bool $returnChildLocks - * @return array - */ - public function getLocks($uri, $returnChildLocks) { - - // NOTE: the following 10 lines or so could be easily replaced by - // pure sql. MySQL's non-standard string concatination prevents us - // from doing this though. - // NOTE: SQLite requires time() to be inserted directly. That's ugly - // but otherwise reading locks from SQLite Databases will return - // nothing - $query = 'SELECT * FROM `*PREFIX*locks`' - .' WHERE `userid` = ? AND (`created` + `timeout`) > '.time().' AND (( `uri` = ?)'; - if (OC_Config::getValue( "dbtype") === 'oci') { - //FIXME oracle hack: need to explicitly cast CLOB to CHAR for comparison - $query = 'SELECT * FROM `*PREFIX*locks`' - .' WHERE `userid` = ? AND (`created` + `timeout`) > '.time().' AND (( to_char(`uri`) = ?)'; - } - $params = array(OC_User::getUser(), $uri); - - // We need to check locks for every part in the uri. - $uriParts = explode('/', $uri); - - // We already covered the last part of the uri - array_pop($uriParts); - - $currentPath=''; - - foreach($uriParts as $part) { - - if ($currentPath) $currentPath.='/'; - $currentPath.=$part; - //FIXME oracle hack: need to explicitly cast CLOB to CHAR for comparison - if (OC_Config::getValue( "dbtype") === 'oci') { - $query.=' OR (`depth` != 0 AND to_char(`uri`) = ?)'; - } else { - $query.=' OR (`depth` != 0 AND `uri` = ?)'; - } - $params[] = $currentPath; - - } - - if ($returnChildLocks) { - - //FIXME oracle hack: need to explicitly cast CLOB to CHAR for comparison - if (OC_Config::getValue( "dbtype") === 'oci') { - $query.=' OR (to_char(`uri`) LIKE ?)'; - } else { - $query.=' OR (`uri` LIKE ?)'; - } - $params[] = $uri . '/%'; - - } - $query.=')'; - - $result = OC_DB::executeAudited( $query, $params ); - - $lockList = array(); - while( $row = $result->fetchRow()) { - - $lockInfo = new \Sabre\DAV\Locks\LockInfo(); - $lockInfo->owner = $row['owner']; - $lockInfo->token = $row['token']; - $lockInfo->timeout = $row['timeout']; - $lockInfo->created = $row['created']; - $lockInfo->scope = $row['scope']; - $lockInfo->depth = $row['depth']; - $lockInfo->uri = $row['uri']; - $lockList[] = $lockInfo; - - } - - return $lockList; - - } - - /** - * Locks a uri - * - * @param string $uri - * @param \Sabre\DAV\Locks\LockInfo $lockInfo - * @return bool - */ - public function lock($uri, \Sabre\DAV\Locks\LockInfo $lockInfo) { - - // We're making the lock timeout 5 minutes - $lockInfo->timeout = 300; - $lockInfo->created = time(); - $lockInfo->uri = $uri; - - $locks = $this->getLocks($uri, false); - $exists = false; - foreach($locks as $lock) { - if ($lock->token == $lockInfo->token) { - $exists = true; - break; - } - } - - if ($exists) { - $sql = 'UPDATE `*PREFIX*locks`' - .' SET `owner` = ?, `timeout` = ?, `scope` = ?, `depth` = ?, `uri` = ?, `created` = ?' - .' WHERE `userid` = ? AND `token` = ?'; - $result = OC_DB::executeAudited( $sql, array( - $lockInfo->owner, - $lockInfo->timeout, - $lockInfo->scope, - $lockInfo->depth, - $uri, - $lockInfo->created, - OC_User::getUser(), - $lockInfo->token) - ); - } else { - $sql = 'INSERT INTO `*PREFIX*locks`' - .' (`userid`,`owner`,`timeout`,`scope`,`depth`,`uri`,`created`,`token`)' - .' VALUES (?,?,?,?,?,?,?,?)'; - $result = OC_DB::executeAudited( $sql, array( - OC_User::getUser(), - $lockInfo->owner, - $lockInfo->timeout, - $lockInfo->scope, - $lockInfo->depth, - $uri, - $lockInfo->created, - $lockInfo->token) - ); - } - - return true; - - } - - /** - * Removes a lock from a uri - * - * @param string $uri - * @param \Sabre\DAV\Locks\LockInfo $lockInfo - * @return bool - */ - public function unlock($uri, \Sabre\DAV\Locks\LockInfo $lockInfo) { - - $sql = 'DELETE FROM `*PREFIX*locks` WHERE `userid` = ? AND `uri` = ? AND `token` = ?'; - if (OC_Config::getValue( "dbtype") === 'oci') { - //FIXME oracle hack: need to explicitly cast CLOB to CHAR for comparison - $sql = 'DELETE FROM `*PREFIX*locks` WHERE `userid` = ? AND to_char(`uri`) = ? AND `token` = ?'; - } - $result = OC_DB::executeAudited( $sql, array(OC_User::getUser(), $uri, $lockInfo->token)); - - return $result === 1; - - } - -} diff --git a/lib/private/connector/sabre/maintenanceplugin.php b/lib/private/connector/sabre/maintenanceplugin.php index 3d4e19ec470..ff55cdceab6 100644 --- a/lib/private/connector/sabre/maintenanceplugin.php +++ b/lib/private/connector/sabre/maintenanceplugin.php @@ -1,25 +1,7 @@ <?php -/** - * @author Bart Visscher <bartv@thisnet.nl> - * @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/> - * - */ -class OC_Connector_Sabre_MaintenancePlugin extends \Sabre\DAV\ServerPlugin +namespace OC\Connector\Sabre; + +class MaintenancePlugin extends \Sabre\DAV\ServerPlugin { /** @@ -43,7 +25,7 @@ class OC_Connector_Sabre_MaintenancePlugin extends \Sabre\DAV\ServerPlugin public function initialize(\Sabre\DAV\Server $server) { $this->server = $server; - $this->server->subscribeEvent('beforeMethod', array($this, 'checkMaintenanceMode'), 10); + $this->server->on('beforeMethod', array($this, 'checkMaintenanceMode'), 10); } /** @@ -55,10 +37,10 @@ class OC_Connector_Sabre_MaintenancePlugin extends \Sabre\DAV\ServerPlugin * @return bool */ public function checkMaintenanceMode() { - if (OC_Config::getValue('maintenance', false)) { + if (\OC_Config::getValue('maintenance', false)) { throw new \Sabre\DAV\Exception\ServiceUnavailable(); } - if (OC::checkUpgrade(false)) { + if (\OC::checkUpgrade(false)) { throw new \Sabre\DAV\Exception\ServiceUnavailable('Upgrade needed'); } diff --git a/lib/private/connector/sabre/node.php b/lib/private/connector/sabre/node.php index 7df4453cb25..8fee6a4eb4e 100644 --- a/lib/private/connector/sabre/node.php +++ b/lib/private/connector/sabre/node.php @@ -1,36 +1,4 @@ <?php -/** - * @author Arthur Schiwon <blizzz@owncloud.com> - * @author Bart Visscher <bartv@thisnet.nl> - * @author Björn Schießle <schiessle@owncloud.com> - * @author Jakob Sack <mail@jakobsack.de> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author Klaas Freitag <freitag@owncloud.com> - * @author Markus Goetz <markus@woboq.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> - * @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/> - * - */ -use Sabre\DAV\URLUtil; -use OC\Connector\Sabre\TagList; /** * ownCloud @@ -52,10 +20,10 @@ use OC\Connector\Sabre\TagList; * License along with this library. If not, see <http://www.gnu.org/licenses/>. * */ -abstract class OC_Connector_Sabre_Node implements \Sabre\DAV\INode, \Sabre\DAV\IProperties { - const GETETAG_PROPERTYNAME = '{DAV:}getetag'; - const LASTMODIFIED_PROPERTYNAME = '{DAV:}lastmodified'; +namespace OC\Connector\Sabre; + +abstract class Node implements \Sabre\DAV\INode { /** * Allow configuring the method used to generate Etags * @@ -111,6 +79,15 @@ abstract class OC_Connector_Sabre_Node implements \Sabre\DAV\INode, \Sabre\DAV\I } /** + * Returns the full path + * + * @return string + */ + public function getPath() { + return $this->path; + } + + /** * Renames the node * @param string $name The new name * @throws \Sabre\DAV\Exception\BadRequest @@ -123,23 +100,19 @@ abstract class OC_Connector_Sabre_Node implements \Sabre\DAV\INode, \Sabre\DAV\I throw new \Sabre\DAV\Exception\Forbidden(); } - list($parentPath,) = URLUtil::splitPath($this->path); - list(, $newName) = URLUtil::splitPath($name); + list($parentPath,) = \Sabre\HTTP\URLUtil::splitPath($this->path); + list(, $newName) = \Sabre\HTTP\URLUtil::splitPath($name); if (!\OCP\Util::isValidFileName($newName)) { throw new \Sabre\DAV\Exception\BadRequest(); } $newPath = $parentPath . '/' . $newName; - $oldPath = $this->path; $this->fileView->rename($this->path, $newPath); $this->path = $newPath; - $query = OC_DB::prepare('UPDATE `*PREFIX*properties` SET `propertypath` = ?' - . ' WHERE `userid` = ? AND `propertypath` = ?'); - $query->execute(array($newPath, OC_User::getUser(), $oldPath)); $this->refreshInfo(); } @@ -170,91 +143,38 @@ abstract class OC_Connector_Sabre_Node implements \Sabre\DAV\INode, \Sabre\DAV\I } /** - * Updates properties on this node, - * @see \Sabre\DAV\IProperties::updateProperties - * @param array $properties - * @return boolean + * Returns the ETag for a file + * + * An ETag is a unique identifier representing the current version of the + * file. If the file changes, the ETag MUST change. The ETag is an + * arbitrary string, but MUST be surrounded by double-quotes. + * + * Return null if the ETag can not effectively be determined + * + * @return string */ - public function updateProperties($properties) { - $existing = $this->getProperties(array()); - foreach ($properties as $propertyName => $propertyValue) { - // If it was null, we need to delete the property - if (is_null($propertyValue)) { - if (array_key_exists($propertyName, $existing)) { - $query = OC_DB::prepare('DELETE FROM `*PREFIX*properties`' - . ' WHERE `userid` = ? AND `propertypath` = ? AND `propertyname` = ?'); - $query->execute(array(OC_User::getUser(), $this->path, $propertyName)); - } - } else { - if (strcmp($propertyName, self::GETETAG_PROPERTYNAME) === 0) { - \OC\Files\Filesystem::putFileInfo($this->path, array('etag' => $propertyValue)); - } elseif (strcmp($propertyName, self::LASTMODIFIED_PROPERTYNAME) === 0) { - $this->touch($propertyValue); - } else { - if (!array_key_exists($propertyName, $existing)) { - $query = OC_DB::prepare('INSERT INTO `*PREFIX*properties`' - . ' (`userid`,`propertypath`,`propertyname`,`propertyvalue`) VALUES(?,?,?,?)'); - $query->execute(array(OC_User::getUser(), $this->path, $propertyName, $propertyValue)); - } else { - $query = OC_DB::prepare('UPDATE `*PREFIX*properties` SET `propertyvalue` = ?' - . ' WHERE `userid` = ? AND `propertypath` = ? AND `propertyname` = ?'); - $query->execute(array($propertyValue, OC_User::getUser(), $this->path, $propertyName)); - } - } - } - - } - $this->setPropertyCache(null); - return true; + public function getETag() { + return '"' . $this->info->getEtag() . '"'; } /** - * removes all properties for this node and user + * Sets the ETag + * + * @param string $etag + * + * @return int file id of updated file or -1 on failure */ - public function removeProperties() { - $query = OC_DB::prepare('DELETE FROM `*PREFIX*properties`' - . ' WHERE `userid` = ? AND `propertypath` = ?'); - $query->execute(array(OC_User::getUser(), $this->path)); - - $this->setPropertyCache(null); + public function setETag($etag) { + return $this->fileView->putFileInfo($this->path, array('etag' => $etag)); } /** - * Returns a list of properties for this nodes.; - * @param array $properties - * @return array - * @note The properties list is a list of propertynames the client - * requested, encoded as xmlnamespace#tagName, for example: - * http://www.example.org/namespace#author If the array is empty, all - * properties should be returned + * Returns the size of the node, in bytes + * + * @return int|float */ - public function getProperties($properties) { - - if (is_null($this->property_cache)) { - $sql = 'SELECT * FROM `*PREFIX*properties` WHERE `userid` = ? AND `propertypath` = ?'; - $result = OC_DB::executeAudited($sql, array(OC_User::getUser(), $this->path)); - - $this->property_cache = array(); - while ($row = $result->fetchRow()) { - $this->property_cache[$row['propertyname']] = $row['propertyvalue']; - } - - $this->property_cache[self::GETETAG_PROPERTYNAME] = '"' . $this->info->getEtag() . '"'; - } - - // if the array was empty, we need to return everything - if (count($properties) == 0) { - return $this->property_cache; - } - - $props = array(); - foreach ($properties as $property) { - if (isset($this->property_cache[$property])) { - $props[$property] = $this->property_cache[$property]; - } - } - - return $props; + public function getSize() { + return $this->info->getSize(); } /** @@ -271,7 +191,7 @@ abstract class OC_Connector_Sabre_Node implements \Sabre\DAV\INode, \Sabre\DAV\I */ public function getFileId() { if ($this->info->getId()) { - $instanceId = OC_Util::getInstanceId(); + $instanceId = \OC_Util::getInstanceId(); $id = sprintf('%08d', $this->info->getId()); return $id . $instanceId; } diff --git a/lib/private/connector/sabre/objecttree.php b/lib/private/connector/sabre/objecttree.php index 8793b612936..585be637813 100644 --- a/lib/private/connector/sabre/objecttree.php +++ b/lib/private/connector/sabre/objecttree.php @@ -30,7 +30,7 @@ use OC\Files\Mount\MoveableMount; use OCP\Files\StorageInvalidException; use OCP\Files\StorageNotAvailableException; -class ObjectTree extends \Sabre\DAV\ObjectTree { +class ObjectTree extends \Sabre\DAV\Tree { /** * @var \OC\Files\View @@ -44,8 +44,6 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { /** * Creates the object - * - * This method expects the rootObject to be passed as a parameter */ public function __construct() { } @@ -62,6 +60,35 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { } /** + * If the given path is a chunked file name, converts it + * to the real file name. Only applies if the OC-CHUNKED header + * is present. + * + * @param string $path chunk file path to convert + * + * @return string path to real file + */ + private function resolveChunkFile($path) { + if (isset($_SERVER['HTTP_OC_CHUNKED'])) { + // resolve to real file name to find the proper node + list($dir, $name) = \Sabre\HTTP\URLUtil::splitPath($path); + if ($dir == '/' || $dir == '.') { + $dir = ''; + } + + $info = \OC_FileChunking::decodeName($name); + // only replace path if it was really the chunked file + if (isset($info['transferid'])) { + // getNodePath is called for multiple nodes within a chunk + // upload call + $path = $dir . '/' . $info['name']; + $path = ltrim($path, '/'); + } + } + return $path; + } + + /** * Returns the INode object for the requested path * * @param string $path @@ -102,12 +129,15 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { $info = null; } } else { + // resolve chunk file name to real name, if applicable + $path = $this->resolveChunkFile($path); + // read from cache try { $info = $this->fileView->getFileInfo($path); } catch (StorageNotAvailableException $e) { throw new \Sabre\DAV\Exception\ServiceUnavailable('Storage not available'); - } catch (StorageInvalidException $e){ + } catch (StorageInvalidException $e) { throw new \Sabre\DAV\Exception\NotFound('Storage ' . $path . ' is invalid'); } } @@ -117,9 +147,9 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { } if ($info->getType() === 'dir') { - $node = new \OC_Connector_Sabre_Directory($this->fileView, $info); + $node = new \OC\Connector\Sabre\Directory($this->fileView, $info); } else { - $node = new \OC_Connector_Sabre_File($this->fileView, $info); + $node = new \OC\Connector\Sabre\File($this->fileView, $info); } $this->cache[$path] = $node; @@ -146,8 +176,8 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { if ($sourceNode instanceof \Sabre\DAV\ICollection and $this->nodeExists($destinationPath)) { throw new \Sabre\DAV\Exception\Forbidden('Could not copy directory ' . $sourceNode . ', target exists'); } - list($sourceDir,) = \Sabre\DAV\URLUtil::splitPath($sourcePath); - list($destinationDir,) = \Sabre\DAV\URLUtil::splitPath($destinationPath); + list($sourceDir,) = \Sabre\HTTP\URLUtil::splitPath($sourcePath); + list($destinationDir,) = \Sabre\HTTP\URLUtil::splitPath($destinationPath); $isMovableMount = false; $sourceMount = $this->mountManager->find($this->fileView->getAbsolutePath($sourcePath)); @@ -183,12 +213,6 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { throw new \Sabre\DAV\Exception\ServiceUnavailable($e->getMessage()); } - // update properties - $query = \OC_DB::prepare('UPDATE `*PREFIX*properties` SET `propertypath` = ?' - . ' WHERE `userid` = ? AND `propertypath` = ?'); - $query->execute(array(\OC\Files\Filesystem::normalizePath($destinationPath), \OC_User::getUser(), - \OC\Files\Filesystem::normalizePath($sourcePath))); - $this->markDirty($sourceDir); $this->markDirty($destinationDir); @@ -229,7 +253,7 @@ class ObjectTree extends \Sabre\DAV\ObjectTree { throw new \Sabre\DAV\Exception\ServiceUnavailable($e->getMessage()); } - list($destinationDir,) = \Sabre\DAV\URLUtil::splitPath($destination); + list($destinationDir,) = \Sabre\HTTP\URLUtil::splitPath($destination); $this->markDirty($destinationDir); } } diff --git a/lib/private/connector/sabre/principal.php b/lib/private/connector/sabre/principal.php index 917d9887393..06842cc7b90 100644 --- a/lib/private/connector/sabre/principal.php +++ b/lib/private/connector/sabre/principal.php @@ -30,6 +30,7 @@ namespace OC\Connector\Sabre; use OCP\IUserManager; use OCP\IConfig; +use \Sabre\DAV\PropPatch; class Principal implements \Sabre\DAVACL\PrincipalBackend\BackendInterface { /** @var IConfig */ @@ -137,7 +138,7 @@ class Principal implements \Sabre\DAVACL\PrincipalBackend\BackendInterface { * @throws \Sabre\DAV\Exception */ public function getGroupMembership($principal) { - list($prefix, $name) = \Sabre\DAV\URLUtil::splitPath($principal); + list($prefix, $name) = \Sabre\HTTP\URLUtil::splitPath($principal); $group_membership = array(); if ($prefix === 'principals') { @@ -174,19 +175,28 @@ class Principal implements \Sabre\DAVACL\PrincipalBackend\BackendInterface { /** * @param string $path - * @param array $mutations + * @param PropPatch $propPatch * @return int */ - function updatePrincipal($path, $mutations) { + function updatePrincipal($path, PropPatch $propPatch) { return 0; } /** * @param string $prefixPath * @param array $searchProperties + * @param string $test * @return array */ - function searchPrincipals($prefixPath, array $searchProperties) { + function searchPrincipals($prefixPath, array $searchProperties, $test = 'allof') { return []; } + + /** + * @param string $uri + * @return string + */ + function findByUri($uri) { + return ''; + } } diff --git a/lib/private/connector/sabre/quotaplugin.php b/lib/private/connector/sabre/quotaplugin.php index 8601f8aada6..6c0f9f3f950 100644 --- a/lib/private/connector/sabre/quotaplugin.php +++ b/lib/private/connector/sabre/quotaplugin.php @@ -1,31 +1,6 @@ <?php -/** - * @author Felix Moeller <mail@felixmoeller.de> - * @author Morris Jobke <hey@morrisjobke.de> - * @author Robin Appelman <icewind@owncloud.com> - * @author Robin McCorkell <rmccorkell@karoshi.org.uk> - * @author scambra <sergio@entrecables.com> - * @author Scrutinizer Auto-Fixer <auto-fixer@scrutinizer-ci.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 - * - * 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 Sabre\DAV\URLUtil; + +namespace OC\Connector\Sabre; /** * This plugin check user quota and deny creating files when they exceeds the quota. @@ -34,7 +9,7 @@ use Sabre\DAV\URLUtil; * @copyright Copyright (C) 2012 entreCables S.L. All rights reserved. * @license http://code.google.com/p/sabredav/wiki/License Modified BSD License */ -class OC_Connector_Sabre_QuotaPlugin extends \Sabre\DAV\ServerPlugin { +class QuotaPlugin extends \Sabre\DAV\ServerPlugin { /** * @var \OC\Files\View @@ -70,8 +45,8 @@ class OC_Connector_Sabre_QuotaPlugin extends \Sabre\DAV\ServerPlugin { $this->server = $server; - $server->subscribeEvent('beforeWriteContent', array($this, 'checkQuota'), 10); - $server->subscribeEvent('beforeCreateFile', array($this, 'checkQuota'), 10); + $server->on('beforeWriteContent', array($this, 'checkQuota'), 10); + $server->on('beforeCreateFile', array($this, 'checkQuota'), 10); } /** @@ -88,11 +63,11 @@ class OC_Connector_Sabre_QuotaPlugin extends \Sabre\DAV\ServerPlugin { if (substr($uri, 0, 1) !== '/') { $uri = '/' . $uri; } - list($parentUri, $newName) = URLUtil::splitPath($uri); + list($parentUri, $newName) = \Sabre\HTTP\URLUtil::splitPath($uri); $req = $this->server->httpRequest; if ($req->getHeader('OC-Chunked')) { - $info = OC_FileChunking::decodeName($newName); - $chunkHandler = new OC_FileChunking($info); + $info = \OC_FileChunking::decodeName($newName); + $chunkHandler = new \OC_FileChunking($info); // subtract the already uploaded size to see whether // there is still enough space for the remaining chunks $length -= $chunkHandler->getCurrentSize(); diff --git a/lib/private/connector/sabre/request.php b/lib/private/connector/sabre/request.php deleted file mode 100644 index 35fd671edd0..00000000000 --- a/lib/private/connector/sabre/request.php +++ /dev/null @@ -1,50 +0,0 @@ -<?php -/** - * @author Bart Visscher <bartv@thisnet.nl> - * @author Lukas Reschke <lukas@owncloud.com> - * @author Stefan Herbrechtsmeier <stefan@herbrechtsmeier.net> - * @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/> - * - */ -class OC_Connector_Sabre_Request extends \Sabre\HTTP\Request { - /** - * Returns the requested uri - * - * @return string - */ - public function getUri() { - return \OC::$server->getRequest()->getRequestUri(); - } - - /** - * Returns a specific item from the _SERVER array. - * - * Do not rely on this feature, it is for internal use only. - * - * @param string $field - * @return string - */ - public function getRawServerValue($field) { - if($field == 'REQUEST_URI') { - return $this->getUri(); - } - else{ - return isset($this->_SERVER[$field])?$this->_SERVER[$field]:null; - } - } -} diff --git a/lib/private/connector/sabre/server.php b/lib/private/connector/sabre/server.php index f17f46a81cf..0dc81554d56 100644 --- a/lib/private/connector/sabre/server.php +++ b/lib/private/connector/sabre/server.php @@ -1,38 +1,13 @@ <?php +namespace OC\Connector\Sabre; + /** - * @author Andreas Fischer <bantu@owncloud.com> - * @author Jörn Friedrich Dreyer <jfd@butonic.de> - * @author scolebrook <scolebrook@mac.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 - * - * 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. + * Class \OC\Connector\Sabre\Server * - * 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/> + * This class overrides some methods from @see \Sabre\DAV\Server. * */ -class OC_Connector_Sabre_Server extends Sabre\DAV\Server { - - /** - * @var string - */ - private $overLoadedUri = null; - - /** - * @var boolean - */ - private $ignoreRangeHeader = false; +class Server extends \Sabre\DAV\Server { /** * @see \Sabre\DAV\Server @@ -40,261 +15,6 @@ class OC_Connector_Sabre_Server extends Sabre\DAV\Server { public function __construct($treeOrNode = null) { parent::__construct($treeOrNode); self::$exposeVersion = false; - } - - public function getRequestUri() { - - if (!is_null($this->overLoadedUri)) { - return $this->overLoadedUri; - } - - return parent::getRequestUri(); - } - - public function checkPreconditions($handleAsGET = false) { - // chunked upload handling - if (isset($_SERVER['HTTP_OC_CHUNKED'])) { - $filePath = parent::getRequestUri(); - list($path, $name) = \Sabre\DAV\URLUtil::splitPath($filePath); - $info = OC_FileChunking::decodeName($name); - if (!empty($info)) { - $filePath = $path . '/' . $info['name']; - $this->overLoadedUri = $filePath; - } - } - - $result = parent::checkPreconditions($handleAsGET); - $this->overLoadedUri = null; - return $result; - } - - public function getHTTPRange() { - if ($this->ignoreRangeHeader) { - return null; - } - return parent::getHTTPRange(); - } - - protected function httpGet($uri) { - $range = $this->getHTTPRange(); - - if (OC_App::isEnabled('files_encryption') && $range) { - // encryption does not support range requests - $this->ignoreRangeHeader = true; - } - return parent::httpGet($uri); - } - - /** - * @see \Sabre\DAV\Server - */ - protected function httpPropfind($uri) { - - // $xml = new \Sabre\DAV\XMLReader(file_get_contents('php://input')); - $requestedProperties = $this->parsePropFindRequest($this->httpRequest->getBody(true)); - - $depth = $this->getHTTPDepth(1); - // The only two options for the depth of a propfind is 0 or 1 - // if ($depth!=0) $depth = 1; - - $newProperties = $this->getPropertiesForPath($uri,$requestedProperties,$depth); - - // This is a multi-status response - $this->httpResponse->sendStatus(207); - $this->httpResponse->setHeader('Content-Type','application/xml; charset=utf-8'); - $this->httpResponse->setHeader('Vary','Brief,Prefer'); - - // Normally this header is only needed for OPTIONS responses, however.. - // iCal seems to also depend on these being set for PROPFIND. Since - // this is not harmful, we'll add it. - $features = array('1','3', 'extended-mkcol'); - foreach($this->plugins as $plugin) { - $features = array_merge($features,$plugin->getFeatures()); - } - - $this->httpResponse->setHeader('DAV',implode(', ',$features)); - - $prefer = $this->getHTTPPrefer(); - $minimal = $prefer['return-minimal']; - - $data = $this->generateMultiStatus($newProperties, $minimal); - $this->httpResponse->sendBody($data); - - } - - /** - * Small helper to support PROPFIND with DEPTH_INFINITY. - * @param string $path - */ - private function addPathNodesRecursively(&$nodes, $path) { - foreach($this->tree->getChildren($path) as $childNode) { - $nodes[$path . '/' . $childNode->getName()] = $childNode; - if ($childNode instanceof \Sabre\DAV\ICollection) - $this->addPathNodesRecursively($nodes, $path . '/' . $childNode->getName()); - } - } - - public function getPropertiesForPath($path, $propertyNames = array(), $depth = 0) { - - // if ($depth!=0) $depth = 1; - - $path = rtrim($path,'/'); - - // This event allows people to intercept these requests early on in the - // process. - // - // We're not doing anything with the result, but this can be helpful to - // pre-fetch certain expensive live properties. - $this->broadCastEvent('beforeGetPropertiesForPath', array($path, $propertyNames, $depth)); - - $returnPropertyList = array(); - - $parentNode = $this->tree->getNodeForPath($path); - $nodes = array( - $path => $parentNode - ); - if ($depth==1 && $parentNode instanceof \Sabre\DAV\ICollection) { - foreach($this->tree->getChildren($path) as $childNode) - $nodes[$path . '/' . $childNode->getName()] = $childNode; - } else if ($depth == self::DEPTH_INFINITY && $parentNode instanceof \Sabre\DAV\ICollection) { - $this->addPathNodesRecursively($nodes, $path); - } - - // If the propertyNames array is empty, it means all properties are requested. - // We shouldn't actually return everything we know though, and only return a - // sensible list. - $allProperties = count($propertyNames)==0; - - foreach($nodes as $myPath=>$node) { - - $currentPropertyNames = $propertyNames; - - $newProperties = array( - '200' => array(), - '404' => array(), - ); - - if ($allProperties) { - // Default list of propertyNames, when all properties were requested. - $currentPropertyNames = array( - '{DAV:}getlastmodified', - '{DAV:}getcontentlength', - '{DAV:}resourcetype', - '{DAV:}quota-used-bytes', - '{DAV:}quota-available-bytes', - '{DAV:}getetag', - '{DAV:}getcontenttype', - ); - } - - // If the resourceType was not part of the list, we manually add it - // and mark it for removal. We need to know the resourcetype in order - // to make certain decisions about the entry. - // WebDAV dictates we should add a / and the end of href's for collections - $removeRT = false; - if (!in_array('{DAV:}resourcetype',$currentPropertyNames)) { - $currentPropertyNames[] = '{DAV:}resourcetype'; - $removeRT = true; - } - - $result = $this->broadcastEvent('beforeGetProperties',array($myPath, $node, &$currentPropertyNames, &$newProperties)); - // If this method explicitly returned false, we must ignore this - // node as it is inaccessible. - if ($result===false) continue; - - if (count($currentPropertyNames) > 0) { - - if ($node instanceof \Sabre\DAV\IProperties) { - $nodeProperties = $node->getProperties($currentPropertyNames); - - // The getProperties method may give us too much, - // properties, in case the implementor was lazy. - // - // So as we loop through this list, we will only take the - // properties that were actually requested and discard the - // rest. - foreach($currentPropertyNames as $k=>$currentPropertyName) { - if (isset($nodeProperties[$currentPropertyName])) { - unset($currentPropertyNames[$k]); - $newProperties[200][$currentPropertyName] = $nodeProperties[$currentPropertyName]; - } - } - - } - - } - - foreach($currentPropertyNames as $prop) { - - if (isset($newProperties[200][$prop])) continue; - - switch($prop) { - case '{DAV:}getlastmodified' : if ($node->getLastModified()) $newProperties[200][$prop] = new \Sabre\DAV\Property\GetLastModified($node->getLastModified()); break; - case '{DAV:}getcontentlength' : - if ($node instanceof \Sabre\DAV\IFile) { - $size = $node->getSize(); - if (!is_null($size)) { - $newProperties[200][$prop] = 0 + $size; - } - } - break; - case '{DAV:}quota-used-bytes' : - if ($node instanceof \Sabre\DAV\IQuota) { - $quotaInfo = $node->getQuotaInfo(); - $newProperties[200][$prop] = $quotaInfo[0]; - } - break; - case '{DAV:}quota-available-bytes' : - if ($node instanceof \Sabre\DAV\IQuota) { - $quotaInfo = $node->getQuotaInfo(); - $newProperties[200][$prop] = $quotaInfo[1]; - } - break; - case '{DAV:}getetag' : if ($node instanceof \Sabre\DAV\IFile && $etag = $node->getETag()) $newProperties[200][$prop] = $etag; break; - case '{DAV:}getcontenttype' : if ($node instanceof \Sabre\DAV\IFile && $ct = $node->getContentType()) $newProperties[200][$prop] = $ct; break; - case '{DAV:}supported-report-set' : - $reports = array(); - foreach($this->plugins as $plugin) { - $reports = array_merge($reports, $plugin->getSupportedReportSet($myPath)); - } - $newProperties[200][$prop] = new \Sabre\DAV\Property\SupportedReportSet($reports); - break; - case '{DAV:}resourcetype' : - $newProperties[200]['{DAV:}resourcetype'] = new \Sabre\DAV\Property\ResourceType(); - foreach($this->resourceTypeMapping as $className => $resourceType) { - if ($node instanceof $className) $newProperties[200]['{DAV:}resourcetype']->add($resourceType); - } - break; - - } - - // If we were unable to find the property, we will list it as 404. - if (!$allProperties && !isset($newProperties[200][$prop])) $newProperties[404][$prop] = null; - - } - - $this->broadcastEvent('afterGetProperties',array(trim($myPath,'/'),&$newProperties, $node)); - - $newProperties['href'] = trim($myPath,'/'); - - // Its is a WebDAV recommendation to add a trailing slash to collectionnames. - // Apple's iCal also requires a trailing slash for principals (rfc 3744), though this is non-standard. - if ($myPath!='' && isset($newProperties[200]['{DAV:}resourcetype'])) { - $rt = $newProperties[200]['{DAV:}resourcetype']; - if ($rt->is('{DAV:}collection') || $rt->is('{DAV:}principal')) { - $newProperties['href'] .='/'; - } - } - - // If the resourcetype property was manually added to the requested property list, - // we will remove it again. - if ($removeRT) unset($newProperties[200]['{DAV:}resourcetype']); - - $returnPropertyList[] = $newProperties; - - } - - return $returnPropertyList; - + $this->enablePropfindDepthInfinity = true; } } diff --git a/lib/private/connector/sabre/taglist.php b/lib/private/connector/sabre/taglist.php index 22b422c20b3..97f9e797579 100644 --- a/lib/private/connector/sabre/taglist.php +++ b/lib/private/connector/sabre/taglist.php @@ -83,9 +83,10 @@ class TagList extends DAV\Property { * It will only decode tag values. * * @param \DOMElement $dom + * @param array $propertyMap * @return \OC\Connector\Sabre\TagList */ - static function unserialize(\DOMElement $dom) { + static function unserialize(\DOMElement $dom, array $propertyMap) { $tags = array(); foreach($dom->childNodes as $child) { diff --git a/lib/private/connector/sabre/tagsplugin.php b/lib/private/connector/sabre/tagsplugin.php index 87de08d333e..7756eb45bda 100644 --- a/lib/private/connector/sabre/tagsplugin.php +++ b/lib/private/connector/sabre/tagsplugin.php @@ -41,6 +41,9 @@ namespace OC\Connector\Sabre; * */ +use \Sabre\DAV\PropFind; +use \Sabre\DAV\PropPatch; + class TagsPlugin extends \Sabre\DAV\ServerPlugin { @@ -76,13 +79,19 @@ class TagsPlugin extends \Sabre\DAV\ServerPlugin private $cachedTags; /** + * @var \Sabre\DAV\Tree + */ + private $tree; + + /** + * @param \Sabre\DAV\Tree $tree tree * @param \OCP\ITagManager $tagManager tag manager */ - public function __construct(\Sabre\DAV\ObjectTree $objectTree, \OCP\ITagManager $tagManager) { - $this->objectTree = $objectTree; + public function __construct(\Sabre\DAV\Tree $tree, \OCP\ITagManager $tagManager) { + $this->tree = $tree; $this->tagManager = $tagManager; $this->tagger = null; - $this->cachedTags = null; + $this->cachedTags = array(); } /** @@ -102,25 +111,8 @@ class TagsPlugin extends \Sabre\DAV\ServerPlugin $server->propertyMap[self::TAGS_PROPERTYNAME] = 'OC\\Connector\\Sabre\\TagList'; $this->server = $server; - $this->server->subscribeEvent('beforeGetProperties', array($this, 'beforeGetProperties')); - $this->server->subscribeEvent('beforeGetPropertiesForPath', array($this, 'beforeGetPropertiesForPath')); - $this->server->subscribeEvent('updateProperties', array($this, 'updateProperties')); - } - - /** - * Searches and removes a value from the given array - * - * @param array $requestedProps - * @param string $propName to remove - * @return boolean true if the property was present, false otherwise - */ - private function findAndRemoveProperty(&$requestedProps, $propName) { - $index = array_search($propName, $requestedProps); - if ($index !== false) { - unset($requestedProps[$index]); - return true; - } - return false; + $this->server->on('propFind', array($this, 'handleGetProperties')); + $this->server->on('propPatch', array($this, 'handleUpdateProperties')); } /** @@ -166,7 +158,10 @@ class TagsPlugin extends \Sabre\DAV\ServerPlugin return $this->cachedTags[$fileId]; } else { $tags = $this->getTagger()->getTagsForObjects(array($fileId)); - if ($tags) { + if ($tags !== false) { + if (empty($tags)) { + return array(); + } return current($tags); } } @@ -200,108 +195,98 @@ class TagsPlugin extends \Sabre\DAV\ServerPlugin } /** - * Pre-fetch tags info + * Adds tags and favorites properties to the response, + * if requested. * - * @param string $path - * @param array $requestedProperties - * @param integer $depth + * @param PropFind $propFind + * @param \Sabre\DAV\INode $node * @return void */ - public function beforeGetPropertiesForPath( - $path, - array $requestedProperties, - $depth + public function handleGetProperties( + PropFind $propFind, + \Sabre\DAV\INode $node ) { - $node = $this->objectTree->getNodeForPath($path); - if (!($node instanceof \OC_Connector_Sabre_Directory)) { + if (!($node instanceof \OC\Connector\Sabre\Node)) { return; } - if ($this->findAndRemoveProperty($requestedProperties, self::TAGS_PROPERTYNAME) - || $this->findAndRemoveProperty($requestedProperties, self::FAVORITE_PROPERTYNAME) - ) { - $fileIds = array(); + // need prefetch ? + if ($node instanceof \OC\Connector\Sabre\Directory + && $propFind->getDepth() !== 0 + && (!is_null($propFind->getStatus(self::TAGS_PROPERTYNAME)) + || !is_null($propFind->getStatus(self::FAVORITE_PROPERTYNAME)) + )) { // note: pre-fetching only supported for depth <= 1 $folderContent = $node->getChildren(); - // TODO: refactor somehow with the similar array that is created - // in getChildren() + $fileIds[] = (int)$node->getId(); foreach ($folderContent as $info) { - $fileIds[] = $info->getId(); + $fileIds[] = (int)$info->getId(); } $tags = $this->getTagger()->getTagsForObjects($fileIds); - if ($tags) { - $this->cachedTags = $tags; + if ($tags === false) { + // the tags API returns false on error... + $tags = array(); } - } - } - /** - * Adds tags and favorites properties to the response, - * if requested. - * - * @param string $path - * @param \Sabre\DAV\INode $node - * @param array $requestedProperties - * @param array $returnedProperties - * @return void - */ - public function beforeGetProperties( - $path, - \Sabre\DAV\INode $node, - array &$requestedProperties, - array &$returnedProperties - ) { - if (!($node instanceof \OC_Connector_Sabre_Node)) { - return; + $this->cachedTags = $this->cachedTags + $tags; + $emptyFileIds = array_diff($fileIds, array_keys($tags)); + // also cache the ones that were not found + foreach ($emptyFileIds as $fileId) { + $this->cachedTags[$fileId] = []; + } } $tags = null; $isFav = null; - if ($this->findAndRemoveProperty($requestedProperties, self::TAGS_PROPERTYNAME)) { + + $propFind->handle(self::TAGS_PROPERTYNAME, function() use ($tags, &$isFav, $node) { list($tags, $isFav) = $this->getTagsAndFav($node->getId()); - $returnedProperties[200][self::TAGS_PROPERTYNAME] = new TagList($tags); - } - if ($this->findAndRemoveProperty($requestedProperties, self::FAVORITE_PROPERTYNAME)) { - if (is_null($tags)) { - list($tags, $isFav) = $this->getTagsAndFav($node->getId()); + return new TagList($tags); + }); + + $propFind->handle(self::FAVORITE_PROPERTYNAME, function() use ($isFav, $node) { + if (is_null($isFav)) { + list(, $isFav) = $this->getTagsAndFav($node->getId()); } - $returnedProperties[200][self::FAVORITE_PROPERTYNAME] = $isFav; - } + return $isFav; + }); } /** * Updates tags and favorites properties, if applicable. * * @param string $path - * @param \Sabre\DAV\INode $node - * @param array $requestedProperties - * @param array $returnedProperties - * @return bool success status + * @param PropPatch $propPatch + * + * @return void */ - public function updateProperties(array &$properties, array &$result, \Sabre\DAV\INode $node) { - if (!($node instanceof \OC_Connector_Sabre_Node)) { - return; - } + public function handleUpdateProperties($path, PropPatch $propPatch) { + $propPatch->handle(self::TAGS_PROPERTYNAME, function($tagList) use ($path) { + $node = $this->tree->getNodeForPath($path); + if (is_null($node)) { + return 404; + } + $this->updateTags($node->getId(), $tagList->getTags()); + return true; + }); - $fileId = $node->getId(); - if (isset($properties[self::TAGS_PROPERTYNAME])) { - $tagsProp = $properties[self::TAGS_PROPERTYNAME]; - unset($properties[self::TAGS_PROPERTYNAME]); - $this->updateTags($fileId, $tagsProp->getTags()); - $result[200][self::TAGS_PROPERTYNAME] = new TagList($tagsProp->getTags()); - } - if (isset($properties[self::FAVORITE_PROPERTYNAME])) { - $favState = $properties[self::FAVORITE_PROPERTYNAME]; - unset($properties[self::FAVORITE_PROPERTYNAME]); + $propPatch->handle(self::FAVORITE_PROPERTYNAME, function($favState) use ($path) { + $node = $this->tree->getNodeForPath($path); + if (is_null($node)) { + return 404; + } if ((int)$favState === 1 || $favState === 'true') { - $favState = true; - $this->getTagger()->tagAs($fileId, self::TAG_FAVORITE); + $this->getTagger()->tagAs($node->getId(), self::TAG_FAVORITE); } else { - $favState = false; - $this->getTagger()->unTag($fileId, self::TAG_FAVORITE); + $this->getTagger()->unTag($node->getId(), self::TAG_FAVORITE); } - $result[200][self::FAVORITE_PROPERTYNAME] = $favState; - } - return true; + + if (is_null($favState)) { + // confirm deletion + return 204; + } + + return 200; + }); } } diff --git a/lib/private/db/statementwrapper.php b/lib/private/db/statementwrapper.php index 14b68d60f43..30f40172109 100644 --- a/lib/private/db/statementwrapper.php +++ b/lib/private/db/statementwrapper.php @@ -80,7 +80,6 @@ class OC_DB_StatementWrapper { } if ($this->isManipulation) { $count = $this->statement->rowCount(); - $this->statement->closeCursor(); return $count; } else { return $this; diff --git a/lib/private/files/storage/common.php b/lib/private/files/storage/common.php index 56aa5328c78..d8df8f948cb 100644 --- a/lib/private/files/storage/common.php +++ b/lib/private/files/storage/common.php @@ -382,7 +382,7 @@ abstract class Common implements \OC\Files\Storage\Storage { * @return string|false */ public function getETag($path) { - $ETagFunction = \OC_Connector_Sabre_Node::$ETagFunction; + $ETagFunction = \OC\Connector\Sabre\Node::$ETagFunction; if ($ETagFunction) { $hash = call_user_func($ETagFunction, $path); return $hash; diff --git a/lib/private/files/storage/dav.php b/lib/private/files/storage/dav.php index 0d70f612ec0..477a3b499c0 100644 --- a/lib/private/files/storage/dav.php +++ b/lib/private/files/storage/dav.php @@ -38,7 +38,7 @@ namespace OC\Files\Storage; use OCP\Files\StorageInvalidException; use OCP\Files\StorageNotAvailableException; -use Sabre\DAV\Exception; +use Sabre\DAV\ClientHttpException; class DAV extends \OC\Files\Storage\Common { protected $password; @@ -104,6 +104,7 @@ class DAV extends \OC\Files\Storage\Common { ); $this->client = new \Sabre\DAV\Client($settings); + $this->client->setThrowExceptions(true); if ($this->secure === true && $this->certPath) { $this->client->addTrustedCertificates($this->certPath); @@ -152,9 +153,10 @@ class DAV extends \OC\Files\Storage\Common { } \OC\Files\Stream\Dir::register($id, $content); return opendir('fakedir://' . $id); - } catch (Exception\NotFound $e) { - return false; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404) { + return false; + } $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -174,9 +176,10 @@ class DAV extends \OC\Files\Storage\Common { $responseType = $response["{DAV:}resourcetype"]->resourceType; } return (count($responseType) > 0 and $responseType[0] == "{DAV:}collection") ? 'dir' : 'file'; - } catch (Exception\NotFound $e) { - return false; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404) { + return false; + } $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -192,9 +195,10 @@ class DAV extends \OC\Files\Storage\Common { try { $this->client->propfind($this->encodePath($path), array('{DAV:}resourcetype')); return true; //no 404 exception - } catch (Exception\NotFound $e) { - return false; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404) { + return false; + } $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -311,9 +315,10 @@ class DAV extends \OC\Files\Storage\Common { if ($this->file_exists($path)) { try { $this->client->proppatch($this->encodePath($path), array('{DAV:}lastmodified' => $mtime)); - } catch (Exception\NotImplemented $e) { - return false; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 501) { + return false; + } $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -367,7 +372,7 @@ class DAV extends \OC\Files\Storage\Common { $this->removeCachedFile($path1); $this->removeCachedFile($path2); return true; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -385,7 +390,7 @@ class DAV extends \OC\Files\Storage\Common { $this->client->request('COPY', $path1, null, array('Destination' => $path2)); $this->removeCachedFile($path2); return true; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -404,11 +409,12 @@ class DAV extends \OC\Files\Storage\Common { 'mtime' => strtotime($response['{DAV:}getlastmodified']), 'size' => (int)isset($response['{DAV:}getcontentlength']) ? $response['{DAV:}getcontentlength'] : 0, ); - } catch (Exception\NotFound $e) { - return array(); - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404) { + return array(); + } $this->convertSabreException($e); - return false; + return array(); } catch (\Exception $e) { // TODO: log for now, but in the future need to wrap/rethrow exception \OCP\Util::writeLog('files_external', $e->getMessage(), \OCP\Util::ERROR); @@ -433,9 +439,10 @@ class DAV extends \OC\Files\Storage\Common { } else { return false; } - } catch (Exception\NotFound $e) { - return false; - } catch (\Sabre\DAV\Exception $e) { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404) { + return false; + } $this->convertSabreException($e); return false; } catch (\Exception $e) { @@ -478,16 +485,13 @@ class DAV extends \OC\Files\Storage\Common { try { $response = $this->client->request($method, $this->encodePath($path), $body); return $response['statusCode'] == $expected; - } catch (Exception\NotFound $e) { - if ($method === 'DELETE') { + } catch (ClientHttpException $e) { + if ($e->getHttpStatus() === 404 && $method === 'DELETE') { return false; } $this->convertSabreException($e); return false; - } catch (\Sabre\DAV\Exception $e) { - $this->convertSabreException($e); - return false; } catch (\Exception $e) { // TODO: log for now, but in the future need to wrap/rethrow exception \OCP\Util::writeLog('files_external', $e->getMessage(), \OCP\Util::ERROR); @@ -591,9 +595,10 @@ class DAV extends \OC\Files\Storage\Common { $remoteMtime = strtotime($response['{DAV:}getlastmodified']); return $remoteMtime > $time; } - } catch (Exception\NotFound $e) { - return false; } catch (Exception $e) { + if ($e->getHttpStatus() === 404) { + return false; + } $this->convertSabreException($e); return false; } @@ -603,19 +608,19 @@ class DAV extends \OC\Files\Storage\Common { * Convert sabre DAV exception to a storage exception, * then throw it * - * @param \Sabre\Dav\Exception $e sabre exception + * @param ClientException $e sabre exception * @throws StorageInvalidException if the storage is invalid, for example * when the authentication expired or is invalid * @throws StorageNotAvailableException if the storage is not available, * which might be temporary */ - private function convertSabreException(\Sabre\Dav\Exception $e) { + private function convertSabreException(ClientException $e) { \OCP\Util::writeLog('files_external', $e->getMessage(), \OCP\Util::ERROR); - if ($e instanceof \Sabre\DAV\Exception\NotAuthenticated) { + if ($e->getHttpStatus() === 401) { // either password was changed or was invalid all along throw new StorageInvalidException(get_class($e).': '.$e->getMessage()); - } else if ($e instanceof \Sabre\DAV\Exception\MethodNotAllowed) { - // ignore exception, false will be returned + } else if ($e->getHttpStatus() === 405) { + // ignore exception for MethodNotAllowed, false will be returned return; } diff --git a/lib/private/group.php b/lib/private/group.php index 85632248d24..c6846e27581 100644 --- a/lib/private/group.php +++ b/lib/private/group.php @@ -277,7 +277,8 @@ class OC_Group { $displayNames ); if ($diff) { - $displayNames = array_merge($diff, $displayNames); + // A fix for LDAP users. array_merge loses keys... + $displayNames = $diff + $displayNames; } } return $displayNames; diff --git a/lib/private/naturalsort.php b/lib/private/naturalsort.php index ef242eb7ab9..535e4a7676f 100644 --- a/lib/private/naturalsort.php +++ b/lib/private/naturalsort.php @@ -28,6 +28,19 @@ class NaturalSort { private $cache = array(); /** + * Instantiate a new \OC\NaturalSort instance. + * @param object $injectedCollator + */ + public function __construct($injectedCollator = null) { + // inject an instance of \Collator('en_US') to force using the php5-intl Collator + // or inject an instance of \OC\NaturalSort_DefaultCollator to force using Owncloud's default collator + if (isset($injectedCollator)) { + $this->collator = $injectedCollator; + \OC_Log::write('core', 'forced use of '.get_class($injectedCollator), \OC_Log::DEBUG); + } + } + + /** * Split the given string in chunks of numbers and strings * @param string $t string * @return array of strings and number chunks diff --git a/lib/private/naturalsort_defaultcollator.php b/lib/private/naturalsort_defaultcollator.php index f777cfd794f..94db6dfbae5 100644 --- a/lib/private/naturalsort_defaultcollator.php +++ b/lib/private/naturalsort_defaultcollator.php @@ -22,9 +22,13 @@ namespace OC; class NaturalSort_DefaultCollator { public function compare($a, $b) { - if ($a === $b) { - return 0; + $result = strcasecmp($a, $b); + if ($result === 0) { + if ($a === $b) { + return 0; + } + return ($a > $b) ? -1 : 1; } - return ($a < $b) ? -1 : 1; + return ($result < 0) ? -1 : 1; } } diff --git a/lib/private/templatelayout.php b/lib/private/templatelayout.php index c8be5631fec..9f06c7b45eb 100644 --- a/lib/private/templatelayout.php +++ b/lib/private/templatelayout.php @@ -77,7 +77,8 @@ class OC_TemplateLayout extends OC_Template { // Update notification if($this->config->getSystemValue('updatechecker', true) === true && OC_User::isAdminUser(OC_User::getUser())) { - $updater = new \OC\Updater(\OC::$server->getHTTPHelper(), \OC::$server->getAppConfig()); + $updater = new \OC\Updater(\OC::$server->getHTTPHelper(), + \OC::$server->getConfig()); $data = $updater->check(); if(isset($data['version']) && $data['version'] != '' and $data['version'] !== Array()) { diff --git a/lib/private/updater.php b/lib/private/updater.php index f76630d411d..5b505d7dedb 100644 --- a/lib/private/updater.php +++ b/lib/private/updater.php @@ -30,6 +30,9 @@ namespace OC; use OC\Hooks\BasicEmitter; +use OC_App; +use OC_Util; +use OCP\IConfig; /** * Class that handles autoupdating of ownCloud @@ -42,29 +45,27 @@ use OC\Hooks\BasicEmitter; */ class Updater extends BasicEmitter { - /** - * @var \OC\Log $log - */ + /** @var \OC\Log $log */ private $log; - /** - * @var \OC\HTTPHelper $helper; - */ + /** @var \OC\HTTPHelper $helper */ private $httpHelper; - /** - * @var \OCP\IAppConfig; - */ + /** @var IConfig */ private $config; + /** @var bool */ private $simulateStepEnabled; + /** @var bool */ private $updateStepEnabled; /** + * @param HTTPHelper $httpHelper + * @param IConfig $config * @param \OC\Log $log */ - public function __construct($httpHelper, $config, $log = null) { + public function __construct(HTTPHelper $httpHelper, IConfig $config, $log = null) { $this->httpHelper = $httpHelper; $this->log = $log; $this->config = $config; @@ -102,23 +103,23 @@ class Updater extends BasicEmitter { public function check($updaterUrl = null) { // Look up the cache - it is invalidated all 30 minutes - if (($this->config->getValue('core', 'lastupdatedat') + 1800) > time()) { - return json_decode($this->config->getValue('core', 'lastupdateResult'), true); + if (((int)$this->config->getAppValue('core', 'lastupdatedat') + 1800) > time()) { + return json_decode($this->config->getAppValue('core', 'lastupdateResult'), true); } if (is_null($updaterUrl)) { $updaterUrl = 'https://apps.owncloud.com/updater.php'; } - $this->config->setValue('core', 'lastupdatedat', time()); + $this->config->setAppValue('core', 'lastupdatedat', time()); - if ($this->config->getValue('core', 'installedat', '') == '') { - $this->config->setValue('core', 'installedat', microtime(true)); + if ($this->config->getAppValue('core', 'installedat', '') == '') { + $this->config->setAppValue('core', 'installedat', microtime(true)); } $version = \OC_Util::getVersion(); - $version['installed'] = $this->config->getValue('core', 'installedat'); - $version['updated'] = $this->config->getValue('core', 'lastupdatedat'); + $version['installed'] = $this->config->getAppValue('core', 'installedat'); + $version['updated'] = $this->config->getAppValue('core', 'lastupdatedat'); $version['updatechannel'] = \OC_Util::getChannel(); $version['edition'] = \OC_Util::getEditionString(); $version['build'] = \OC_Util::getBuild(); @@ -146,7 +147,7 @@ class Updater extends BasicEmitter { } // Cache the result - $this->config->setValue('core', 'lastupdateResult', json_encode($data)); + $this->config->setAppValue('core', 'lastupdateResult', json_encode($data)); return $tmp; } @@ -157,9 +158,9 @@ class Updater extends BasicEmitter { * @return bool true if the operation succeeded, false otherwise */ public function upgrade() { - \OC_Config::setValue('maintenance', true); + $this->config->setSystemValue('maintenance', true); - $installedVersion = \OC_Config::getValue('version', '0.0.0'); + $installedVersion = $this->config->getSystemValue('version', '0.0.0'); $currentVersion = implode('.', \OC_Util::getVersion()); if ($this->log) { $this->log->debug('starting upgrade from ' . $installedVersion . ' to ' . $currentVersion, array('app' => 'core')); @@ -172,7 +173,7 @@ class Updater extends BasicEmitter { $this->emit('\OC\Updater', 'failure', array($exception->getMessage())); } - \OC_Config::setValue('maintenance', false); + $this->config->setSystemValue('maintenance', false); $this->emit('\OC\Updater', 'maintenanceEnd'); } @@ -220,10 +221,10 @@ class Updater extends BasicEmitter { // create empty file in data dir, so we can later find // out that this is indeed an ownCloud data directory // (in case it didn't exist before) - file_put_contents(\OC_Config::getValue('datadirectory', \OC::$SERVERROOT . '/data') . '/.ocdata', ''); + file_put_contents($this->config->getSystemValue('datadirectory', \OC::$SERVERROOT . '/data') . '/.ocdata', ''); // pre-upgrade repairs - $repair = new \OC\Repair(\OC\Repair::getBeforeUpgradeRepairSteps()); + $repair = new Repair(Repair::getBeforeUpgradeRepairSteps()); $repair->run(); // simulate DB upgrade @@ -238,22 +239,18 @@ class Updater extends BasicEmitter { if ($this->updateStepEnabled) { $this->doCoreUpgrade(); - $disabledApps = \OC_App::checkAppsRequirements(); - if (!empty($disabledApps)) { - $this->emit('\OC\Updater', 'disabledApps', array($disabledApps)); - } - + $this->checkAppsRequirements(); $this->doAppUpgrade(); // post-upgrade repairs - $repair = new \OC\Repair(\OC\Repair::getRepairSteps()); + $repair = new Repair(Repair::getRepairSteps()); $repair->run(); //Invalidate update feed - $this->config->setValue('core', 'lastupdatedat', 0); + $this->config->setAppValue('core', 'lastupdatedat', 0); // only set the final version if everything went well - \OC_Config::setValue('version', implode('.', \OC_Util::getVersion())); + $this->config->setSystemValue('version', implode('.', \OC_Util::getVersion())); } } @@ -278,14 +275,11 @@ class Updater extends BasicEmitter { $apps = \OC_App::getEnabledApps(); foreach ($apps as $appId) { - if ($version) { - $info = \OC_App::getAppInfo($appId); - $compatible = \OC_App::isAppCompatible($version, $info); - } else { - $compatible = true; - } + $info = \OC_App::getAppInfo($appId); + $compatible = \OC_App::isAppCompatible($version, $info); + $isShipped = \OC_App::isShipped($appId); - if ($compatible && \OC_App::shouldUpgrade($appId)) { + if ($compatible && $isShipped && \OC_App::shouldUpgrade($appId)) { /** * FIXME: The preupdate check is performed before the database migration, otherwise database changes * are not possible anymore within it. - Consider this when touching the code. @@ -356,5 +350,50 @@ class Updater extends BasicEmitter { } } } + + /** + * check if the current enabled apps are compatible with the current + * ownCloud version. disable them if not. + * This is important if you upgrade ownCloud and have non ported 3rd + * party apps installed. + */ + private function checkAppsRequirements() { + $isCoreUpgrade = $this->isCodeUpgrade(); + $apps = OC_App::getEnabledApps(); + $version = OC_Util::getVersion(); + foreach ($apps as $app) { + // check if the app is compatible with this version of ownCloud + $info = OC_App::getAppInfo($app); + if(!OC_App::isAppCompatible($version, $info)) { + OC_App::disable($app); + $this->emit('\OC\Updater', 'incompatibleAppDisabled', array($app)); + } + // no need to disable any app in case this is a non-core upgrade + if (!$isCoreUpgrade) { + continue; + } + // shipped apps will remain enabled + if (OC_App::isShipped($app)) { + continue; + } + // authentication and session apps will remain enabled as well + if (OC_App::isType($app, ['session', 'authentication'])) { + continue; + } + + // disable any other 3rd party apps + \OC_App::disable($app); + $this->emit('\OC\Updater', 'thirdPartyAppDisabled', array($app)); + } + } + + private function isCodeUpgrade() { + $installedVersion = $this->config->getSystemValue('version', '0.0.0'); + $currentVersion = implode('.', OC_Util::getVersion()); + if (version_compare($currentVersion, $installedVersion, '>')) { + return true; + } + return false; + } } diff --git a/lib/private/user/session.php b/lib/private/user/session.php index 0bc03f7b5e6..ead3a4f7a13 100644 --- a/lib/private/user/session.php +++ b/lib/private/user/session.php @@ -285,27 +285,30 @@ class Session implements IUserSession, Emitter { * @param string $token */ public function setMagicInCookie($username, $token) { - $secure_cookie = \OC_Config::getValue("forcessl", false); //TODO: DI for cookies and OC_Config + $secureCookie = \OC_Config::getValue("forcessl", false); //TODO: DI for cookies and OC_Config $expires = time() + \OC_Config::getValue('remember_login_cookie_lifetime', 60 * 60 * 24 * 15); - setcookie("oc_username", $username, $expires, \OC::$WEBROOT, '', $secure_cookie); - setcookie("oc_token", $token, $expires, \OC::$WEBROOT, '', $secure_cookie, true); - setcookie("oc_remember_login", "1", $expires, \OC::$WEBROOT, '', $secure_cookie); + setcookie("oc_username", $username, $expires, \OC::$WEBROOT, '', $secureCookie, true); + setcookie("oc_token", $token, $expires, \OC::$WEBROOT, '', $secureCookie, true); + setcookie("oc_remember_login", "1", $expires, \OC::$WEBROOT, '', $secureCookie, true); } /** * Remove cookie for "remember username" */ public function unsetMagicInCookie() { + //TODO: DI for cookies and OC_Config + $secureCookie = \OC_Config::getValue('forcessl', false); + unset($_COOKIE["oc_username"]); //TODO: DI unset($_COOKIE["oc_token"]); unset($_COOKIE["oc_remember_login"]); - setcookie('oc_username', '', time() - 3600, \OC::$WEBROOT); - setcookie('oc_token', '', time() - 3600, \OC::$WEBROOT); - setcookie('oc_remember_login', '', time() - 3600, \OC::$WEBROOT); + setcookie('oc_username', '', time() - 3600, \OC::$WEBROOT, '',$secureCookie, true); + setcookie('oc_token', '', time() - 3600, \OC::$WEBROOT, '', $secureCookie, true); + setcookie('oc_remember_login', '', time() - 3600, \OC::$WEBROOT, '', $secureCookie, true); // old cookies might be stored under /webroot/ instead of /webroot // and Firefox doesn't like it! - setcookie('oc_username', '', time() - 3600, \OC::$WEBROOT . '/'); - setcookie('oc_token', '', time() - 3600, \OC::$WEBROOT . '/'); - setcookie('oc_remember_login', '', time() - 3600, \OC::$WEBROOT . '/'); + setcookie('oc_username', '', time() - 3600, \OC::$WEBROOT . '/', '', $secureCookie, true); + setcookie('oc_token', '', time() - 3600, \OC::$WEBROOT . '/', '', $secureCookie, true); + setcookie('oc_remember_login', '', time() - 3600, \OC::$WEBROOT . '/', '', $secureCookie, true); } } diff --git a/lib/private/vobject/compoundproperty.php b/lib/private/vobject/compoundproperty.php deleted file mode 100644 index aaeeeed527e..00000000000 --- a/lib/private/vobject/compoundproperty.php +++ /dev/null @@ -1,69 +0,0 @@ -<?php -/** - * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Thomas Tanghus <thomas@tanghus.net> - * - * @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\VObject; - -/** - * This class overrides \Sabre\VObject\Property::serialize() to not - * double escape commas and semi-colons in compound properties. -*/ -class CompoundProperty extends \Sabre\VObject\Property\Compound { - - /** - * Turns the object back into a serialized blob. - * - * @return string - */ - public function serialize() { - - $str = $this->name; - if ($this->group) { - $str = $this->group . '.' . $this->name; - } - - foreach($this->parameters as $param) { - $str.=';' . $param->serialize(); - } - $src = array( - "\n", - ); - $out = array( - '\n', - ); - $str.=':' . str_replace($src, $out, $this->value); - - $out = ''; - while(strlen($str) > 0) { - if (strlen($str) > 75) { - $out .= mb_strcut($str, 0, 75, 'utf-8') . "\r\n"; - $str = ' ' . mb_strcut($str, 75, strlen($str), 'utf-8'); - } else { - $out .= $str . "\r\n"; - $str = ''; - break; - } - } - - return $out; - - } - -} diff --git a/lib/private/vobject/stringproperty.php b/lib/private/vobject/stringproperty.php deleted file mode 100644 index a0911563061..00000000000 --- a/lib/private/vobject/stringproperty.php +++ /dev/null @@ -1,77 +0,0 @@ -<?php -/** - * @author Christopher Schäpers <kondou@ts.unde.re> - * @author Thomas Tanghus <thomas@tanghus.net> - * - * @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\VObject; - -/** - * This class overrides \Sabre\VObject\Property::serialize() properly - * escape commas and semi-colons in string properties. -*/ -class StringProperty extends \Sabre\VObject\Property { - - /** - * Turns the object back into a serialized blob. - * - * @return string - */ - public function serialize() { - - $str = $this->name; - if ($this->group) { - $str = $this->group . '.' . $this->name; - } - - foreach($this->parameters as $param) { - $str.=';' . $param->serialize(); - } - - $src = array( - '\\', - "\n", - ';', - ',', - ); - $out = array( - '\\\\', - '\n', - '\;', - '\,', - ); - $value = strtr($this->value, array('\,' => ',', '\;' => ';', '\\\\' => '\\')); - $str.=':' . str_replace($src, $out, $value); - - $out = ''; - while(strlen($str) > 0) { - if (strlen($str) > 75) { - $out .= mb_strcut($str, 0, 75, 'utf-8') . "\r\n"; - $str = ' ' . mb_strcut($str, 75, strlen($str), 'utf-8'); - } else { - $out .= $str . "\r\n"; - $str = ''; - break; - } - } - - return $out; - - } - -} diff --git a/lib/public/activity/iextension.php b/lib/public/activity/iextension.php index b85532ded1f..643ea11cffa 100644 --- a/lib/public/activity/iextension.php +++ b/lib/public/activity/iextension.php @@ -42,16 +42,6 @@ interface IExtension { public function getNotificationTypes($languageCode); /** - * The extension can filter the types based on the filter if required. - * In case no filter is to be applied false is to be returned unchanged. - * - * @param array $types - * @param string $filter - * @return array|false - */ - public function filterNotificationTypes($types, $filter); - - /** * For a given method additional types to be displayed in the settings can be returned. * In case no additional types are to be added false is to be returned. * @@ -61,6 +51,15 @@ interface IExtension { public function getDefaultTypes($method); /** + * A string naming the css class for the icon to be used can be returned. + * If no icon is known for the given type false is to be returned. + * + * @param string $type + * @return string|false + */ + public function getTypeIcon($type); + + /** * The extension can translate a given message to the requested languages. * If no translation is available false is to be returned. * @@ -88,15 +87,6 @@ interface IExtension { public function getSpecialParameterList($app, $text); /** - * A string naming the css class for the icon to be used can be returned. - * If no icon is known for the given type false is to be returned. - * - * @param string $type - * @return string|false - */ - public function getTypeIcon($type); - - /** * The extension can define the parameter grouping by returning the index as integer. * In case no grouping is required false is to be returned. * @@ -123,6 +113,16 @@ interface IExtension { public function isFilterValid($filterValue); /** + * The extension can filter the types based on the filter if required. + * In case no filter is to be applied false is to be returned unchanged. + * + * @param array $types + * @param string $filter + * @return array|false + */ + public function filterNotificationTypes($types, $filter); + + /** * For a given filter the extension can specify the sql query conditions including parameters for that query. * In case the extension does not know the filter false is to be returned. * The query condition and the parameters are to be returned as array with two elements. diff --git a/lib/public/activity/imanager.php b/lib/public/activity/imanager.php index ded17336ed8..bc320a0f8b4 100644 --- a/lib/public/activity/imanager.php +++ b/lib/public/activity/imanager.php @@ -72,17 +72,16 @@ interface IManager { function getNotificationTypes($languageCode); /** - * @param array $types - * @param string $filter + * @param string $method * @return array */ - function filterNotificationTypes($types, $filter); + function getDefaultTypes($method); /** - * @param string $method - * @return array + * @param string $type + * @return string */ - function getDefaultTypes($method); + function getTypeIcon($type); /** * @param string $app @@ -103,12 +102,6 @@ interface IManager { function getSpecialParameterList($app, $text); /** - * @param string $type - * @return string - */ - function getTypeIcon($type); - - /** * @param array $activity * @return integer|false */ @@ -126,6 +119,13 @@ interface IManager { function isFilterValid($filterValue); /** + * @param array $types + * @param string $filter + * @return array + */ + function filterNotificationTypes($types, $filter); + + /** * @param string $filter * @return array */ diff --git a/settings/l10n/ar.js b/settings/l10n/ar.js index a72db207ab8..5ce37c57091 100644 --- a/settings/l10n/ar.js +++ b/settings/l10n/ar.js @@ -104,7 +104,6 @@ OC.L10N.register( "Show First Run Wizard again" : "ابدأ خطوات بداية التشغيل من جديد", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "تم إستهلاك <strong>%s</strong> من المتوفر <strong>%s</strong>", "Password" : "كلمة المرور", - "Your password was changed" : "لقد تم تغيير كلمة السر", "Unable to change your password" : "لم يتم تعديل كلمة السر بنجاح", "Current password" : "كلمات السر الحالية", "New password" : "كلمات سر جديدة", diff --git a/settings/l10n/ar.json b/settings/l10n/ar.json index cda4c35ea27..7941e5bbd55 100644 --- a/settings/l10n/ar.json +++ b/settings/l10n/ar.json @@ -102,7 +102,6 @@ "Show First Run Wizard again" : "ابدأ خطوات بداية التشغيل من جديد", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "تم إستهلاك <strong>%s</strong> من المتوفر <strong>%s</strong>", "Password" : "كلمة المرور", - "Your password was changed" : "لقد تم تغيير كلمة السر", "Unable to change your password" : "لم يتم تعديل كلمة السر بنجاح", "Current password" : "كلمات السر الحالية", "New password" : "كلمات سر جديدة", diff --git a/settings/l10n/ast.js b/settings/l10n/ast.js index fedf6481efc..bd0a5b60009 100644 --- a/settings/l10n/ast.js +++ b/settings/l10n/ast.js @@ -162,7 +162,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Amosar nuevamente l'Encontu d'execución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usasti <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Camudóse la contraseña", "Unable to change your password" : "Nun pudo camudase la contraseña", "Current password" : "Contraseña actual", "New password" : "Contraseña nueva", diff --git a/settings/l10n/ast.json b/settings/l10n/ast.json index 0d4433008d1..5569f896496 100644 --- a/settings/l10n/ast.json +++ b/settings/l10n/ast.json @@ -160,7 +160,6 @@ "Show First Run Wizard again" : "Amosar nuevamente l'Encontu d'execución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usasti <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Camudóse la contraseña", "Unable to change your password" : "Nun pudo camudase la contraseña", "Current password" : "Contraseña actual", "New password" : "Contraseña nueva", diff --git a/settings/l10n/az.js b/settings/l10n/az.js index 0da0afcfba7..728681f504c 100644 --- a/settings/l10n/az.js +++ b/settings/l10n/az.js @@ -1,6 +1,7 @@ OC.L10N.register( "settings", { + "Security" : "Təhlükəsizlik", "Authentication error" : "Təyinat metodikası", "Your full name has been changed." : "Sizin tam adınız dəyişdirildi.", "Unable to change full name" : "Tam adı dəyişmək olmur", @@ -85,6 +86,7 @@ OC.L10N.register( "PHP charset is not set to UTF-8" : "PHP simvol tipi UTF-8 deyil", "Send mode" : "Göndərmə rejimi", "Authentication method" : "Qeydiyyat metodikası", + "Authentication required" : "Qeydiyyat tələb edilir", "More" : "Yenə", "by" : "onunla", "User Documentation" : "İstifadəçi sənədləri", diff --git a/settings/l10n/az.json b/settings/l10n/az.json index b0d0d4ebfed..258c991e04a 100644 --- a/settings/l10n/az.json +++ b/settings/l10n/az.json @@ -1,4 +1,5 @@ { "translations": { + "Security" : "Təhlükəsizlik", "Authentication error" : "Təyinat metodikası", "Your full name has been changed." : "Sizin tam adınız dəyişdirildi.", "Unable to change full name" : "Tam adı dəyişmək olmur", @@ -83,6 +84,7 @@ "PHP charset is not set to UTF-8" : "PHP simvol tipi UTF-8 deyil", "Send mode" : "Göndərmə rejimi", "Authentication method" : "Qeydiyyat metodikası", + "Authentication required" : "Qeydiyyat tələb edilir", "More" : "Yenə", "by" : "onunla", "User Documentation" : "İstifadəçi sənədləri", diff --git a/settings/l10n/bg_BG.js b/settings/l10n/bg_BG.js index 9cebcef5d99..5e8ee127a6e 100644 --- a/settings/l10n/bg_BG.js +++ b/settings/l10n/bg_BG.js @@ -198,7 +198,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Покажи Настройките за Първоначално Зареждане отново", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Използвал си <strong>%s</strong> от наличните <strong>%s</strong>.", "Password" : "Парола", - "Your password was changed" : "Паролата ти е промена.", "Unable to change your password" : "Неуспешна промяна на паролата.", "Current password" : "Текуща парола", "New password" : "Нова парола", diff --git a/settings/l10n/bg_BG.json b/settings/l10n/bg_BG.json index d301bf135c2..41d1ac5bde2 100644 --- a/settings/l10n/bg_BG.json +++ b/settings/l10n/bg_BG.json @@ -196,7 +196,6 @@ "Show First Run Wizard again" : "Покажи Настройките за Първоначално Зареждане отново", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Използвал си <strong>%s</strong> от наличните <strong>%s</strong>.", "Password" : "Парола", - "Your password was changed" : "Паролата ти е промена.", "Unable to change your password" : "Неуспешна промяна на паролата.", "Current password" : "Текуща парола", "New password" : "Нова парола", diff --git a/settings/l10n/bn_BD.js b/settings/l10n/bn_BD.js index 8abbbe7e555..f4a44c8320b 100644 --- a/settings/l10n/bn_BD.js +++ b/settings/l10n/bn_BD.js @@ -71,7 +71,6 @@ OC.L10N.register( "Show First Run Wizard again" : "প্রথমবার চালানোর যাদুকর পূনরায় প্রদর্শন কর", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "আপনি ব্যবহার করছেন <strong>%s</strong>, সুলভ <strong>%s</strong> এর মধ্যে।", "Password" : "কূটশব্দ", - "Your password was changed" : "আপনার কূটশব্দটি পরিবর্তন করা হয়েছে ", "Unable to change your password" : "আপনার কূটশব্দটি পরিবর্তন করতে সক্ষম নয়", "Current password" : "বর্তমান কূটশব্দ", "New password" : "নতুন কূটশব্দ", diff --git a/settings/l10n/bn_BD.json b/settings/l10n/bn_BD.json index e7ff1436f0e..c3e34524941 100644 --- a/settings/l10n/bn_BD.json +++ b/settings/l10n/bn_BD.json @@ -69,7 +69,6 @@ "Show First Run Wizard again" : "প্রথমবার চালানোর যাদুকর পূনরায় প্রদর্শন কর", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "আপনি ব্যবহার করছেন <strong>%s</strong>, সুলভ <strong>%s</strong> এর মধ্যে।", "Password" : "কূটশব্দ", - "Your password was changed" : "আপনার কূটশব্দটি পরিবর্তন করা হয়েছে ", "Unable to change your password" : "আপনার কূটশব্দটি পরিবর্তন করতে সক্ষম নয়", "Current password" : "বর্তমান কূটশব্দ", "New password" : "নতুন কূটশব্দ", diff --git a/settings/l10n/bs.js b/settings/l10n/bs.js index 7f1ceba2eb4..59c42c983b6 100644 --- a/settings/l10n/bs.js +++ b/settings/l10n/bs.js @@ -192,7 +192,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Opet pokažite First Run Wizard", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Iskoristili ste <strong>%s</strong> od raspoloživog <strong>%s</strong>", "Password" : "Lozinka", - "Your password was changed" : "Vaša lozinka je promijenjena", "Unable to change your password" : "Vašu lozinku nije moguće promijeniti", "Current password" : "Trenutna lozinka", "New password" : "Nova lozinka", diff --git a/settings/l10n/bs.json b/settings/l10n/bs.json index 6d4df935749..9985485755c 100644 --- a/settings/l10n/bs.json +++ b/settings/l10n/bs.json @@ -190,7 +190,6 @@ "Show First Run Wizard again" : "Opet pokažite First Run Wizard", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Iskoristili ste <strong>%s</strong> od raspoloživog <strong>%s</strong>", "Password" : "Lozinka", - "Your password was changed" : "Vaša lozinka je promijenjena", "Unable to change your password" : "Vašu lozinku nije moguće promijeniti", "Current password" : "Trenutna lozinka", "New password" : "Nova lozinka", diff --git a/settings/l10n/ca.js b/settings/l10n/ca.js index 5d09e8b42cb..6dbc26d1dc2 100644 --- a/settings/l10n/ca.js +++ b/settings/l10n/ca.js @@ -172,7 +172,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Torna a mostrar l'assistent de primera execució", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Heu utilitzat <strong>%s</strong> d'un total disponible de <strong>%s</strong>", "Password" : "Contrasenya", - "Your password was changed" : "La seva contrasenya s'ha canviat", "Unable to change your password" : "No s'ha pogut canviar la contrasenya", "Current password" : "Contrasenya actual", "New password" : "Contrasenya nova", diff --git a/settings/l10n/ca.json b/settings/l10n/ca.json index 589b10f0535..8b7c9486fc2 100644 --- a/settings/l10n/ca.json +++ b/settings/l10n/ca.json @@ -170,7 +170,6 @@ "Show First Run Wizard again" : "Torna a mostrar l'assistent de primera execució", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Heu utilitzat <strong>%s</strong> d'un total disponible de <strong>%s</strong>", "Password" : "Contrasenya", - "Your password was changed" : "La seva contrasenya s'ha canviat", "Unable to change your password" : "No s'ha pogut canviar la contrasenya", "Current password" : "Contrasenya actual", "New password" : "Contrasenya nova", diff --git a/settings/l10n/cs_CZ.js b/settings/l10n/cs_CZ.js index d5a0414ed77..b720c3a36cc 100644 --- a/settings/l10n/cs_CZ.js +++ b/settings/l10n/cs_CZ.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Znovu zobrazit průvodce prvním spuštěním", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Používáte <strong>%s</strong> z <strong>%s</strong> dostupných", "Password" : "Heslo", - "Your password was changed" : "Vaše heslo bylo změněno", "Unable to change your password" : "Změna vašeho hesla se nezdařila", "Current password" : "Současné heslo", "New password" : "Nové heslo", diff --git a/settings/l10n/cs_CZ.json b/settings/l10n/cs_CZ.json index 0d871a230ae..8ba0d3686a2 100644 --- a/settings/l10n/cs_CZ.json +++ b/settings/l10n/cs_CZ.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Znovu zobrazit průvodce prvním spuštěním", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Používáte <strong>%s</strong> z <strong>%s</strong> dostupných", "Password" : "Heslo", - "Your password was changed" : "Vaše heslo bylo změněno", "Unable to change your password" : "Změna vašeho hesla se nezdařila", "Current password" : "Současné heslo", "New password" : "Nové heslo", diff --git a/settings/l10n/da.js b/settings/l10n/da.js index c8b47c74ff5..101895f2239 100644 --- a/settings/l10n/da.js +++ b/settings/l10n/da.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Vis guiden for første kørsel igen.", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brugt <strong>%s</strong> af den tilgængelige <strong>%s</strong>", "Password" : "Kodeord", - "Your password was changed" : "Din adgangskode blev ændret", "Unable to change your password" : "Ude af stand til at ændre dit kodeord", "Current password" : "Nuværende adgangskode", "New password" : "Nyt kodeord", diff --git a/settings/l10n/da.json b/settings/l10n/da.json index 6f16c11742e..677a1eacf74 100644 --- a/settings/l10n/da.json +++ b/settings/l10n/da.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Vis guiden for første kørsel igen.", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brugt <strong>%s</strong> af den tilgængelige <strong>%s</strong>", "Password" : "Kodeord", - "Your password was changed" : "Din adgangskode blev ændret", "Unable to change your password" : "Ude af stand til at ændre dit kodeord", "Current password" : "Nuværende adgangskode", "New password" : "Nyt kodeord", diff --git a/settings/l10n/de.js b/settings/l10n/de.js index 8fcb89256bf..bde0db1eddf 100644 --- a/settings/l10n/de.js +++ b/settings/l10n/de.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Den Einrichtungsassistenten erneut anzeigen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du verwendest <strong>%s</strong> der verfügbaren <strong>%s</strong>", "Password" : "Passwort", - "Your password was changed" : "Dein Passwort wurde geändert.", "Unable to change your password" : "Passwort konnte nicht geändert werden", "Current password" : "Aktuelles Passwort", "New password" : "Neues Passwort", diff --git a/settings/l10n/de.json b/settings/l10n/de.json index 7694130d6b2..04780ea45fb 100644 --- a/settings/l10n/de.json +++ b/settings/l10n/de.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Den Einrichtungsassistenten erneut anzeigen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du verwendest <strong>%s</strong> der verfügbaren <strong>%s</strong>", "Password" : "Passwort", - "Your password was changed" : "Dein Passwort wurde geändert.", "Unable to change your password" : "Passwort konnte nicht geändert werden", "Current password" : "Aktuelles Passwort", "New password" : "Neues Passwort", diff --git a/settings/l10n/de_DE.js b/settings/l10n/de_DE.js index 36db9c491f5..647aa970d87 100644 --- a/settings/l10n/de_DE.js +++ b/settings/l10n/de_DE.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Den Einrichtungsassistenten erneut anzeigen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Sie verwenden <strong>%s</strong> der verfügbaren <strong>%s</strong>", "Password" : "Passwort", - "Your password was changed" : "Ihr Passwort wurde geändert.", "Unable to change your password" : "Das Passwort konnte nicht geändert werden", "Current password" : "Aktuelles Passwort", "New password" : "Neues Passwort", diff --git a/settings/l10n/de_DE.json b/settings/l10n/de_DE.json index 96238c84540..85107043f1f 100644 --- a/settings/l10n/de_DE.json +++ b/settings/l10n/de_DE.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Den Einrichtungsassistenten erneut anzeigen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Sie verwenden <strong>%s</strong> der verfügbaren <strong>%s</strong>", "Password" : "Passwort", - "Your password was changed" : "Ihr Passwort wurde geändert.", "Unable to change your password" : "Das Passwort konnte nicht geändert werden", "Current password" : "Aktuelles Passwort", "New password" : "Neues Passwort", diff --git a/settings/l10n/el.js b/settings/l10n/el.js index ea187d47b11..1197ed4cb85 100644 --- a/settings/l10n/el.js +++ b/settings/l10n/el.js @@ -182,7 +182,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Προβολή Οδηγού Πρώτης Εκτέλεσης ξανά", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Χρησιμοποιήσατε <strong>%s</strong> από τα <strong>%s</strong> διαθέσιμα", "Password" : "Συνθηματικό", - "Your password was changed" : "Το συνθηματικό σας έχει αλλάξει", "Unable to change your password" : "Δεν ήταν δυνατή η αλλαγή του κωδικού πρόσβασης", "Current password" : "Τρέχων συνθηματικό", "New password" : "Νέο συνθηματικό", diff --git a/settings/l10n/el.json b/settings/l10n/el.json index 313061da69c..b540762c43e 100644 --- a/settings/l10n/el.json +++ b/settings/l10n/el.json @@ -180,7 +180,6 @@ "Show First Run Wizard again" : "Προβολή Οδηγού Πρώτης Εκτέλεσης ξανά", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Χρησιμοποιήσατε <strong>%s</strong> από τα <strong>%s</strong> διαθέσιμα", "Password" : "Συνθηματικό", - "Your password was changed" : "Το συνθηματικό σας έχει αλλάξει", "Unable to change your password" : "Δεν ήταν δυνατή η αλλαγή του κωδικού πρόσβασης", "Current password" : "Τρέχων συνθηματικό", "New password" : "Νέο συνθηματικό", diff --git a/settings/l10n/en_GB.js b/settings/l10n/en_GB.js index d3b729fe341..3dc345af1eb 100644 --- a/settings/l10n/en_GB.js +++ b/settings/l10n/en_GB.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Show First Run Wizard again", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "You have used <strong>%s</strong> of the available <strong>%s</strong>", "Password" : "Password", - "Your password was changed" : "Your password was changed", "Unable to change your password" : "Unable to change your password", "Current password" : "Current password", "New password" : "New password", diff --git a/settings/l10n/en_GB.json b/settings/l10n/en_GB.json index d53b4f96833..56c07258139 100644 --- a/settings/l10n/en_GB.json +++ b/settings/l10n/en_GB.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Show First Run Wizard again", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "You have used <strong>%s</strong> of the available <strong>%s</strong>", "Password" : "Password", - "Your password was changed" : "Your password was changed", "Unable to change your password" : "Unable to change your password", "Current password" : "Current password", "New password" : "New password", diff --git a/settings/l10n/eo.js b/settings/l10n/eo.js index fe778dc687e..4e9ef54e3c4 100644 --- a/settings/l10n/eo.js +++ b/settings/l10n/eo.js @@ -105,7 +105,6 @@ OC.L10N.register( "Get the apps to sync your files" : "Ekhavu la aplikaĵojn por sinkronigi viajn dosierojn", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Vi uzas <strong>%s</strong> el la disponeblaj <strong>%s</strong>", "Password" : "Pasvorto", - "Your password was changed" : "Via pasvorto ŝanĝiĝis", "Unable to change your password" : "Ne eblis ŝanĝi vian pasvorton", "Current password" : "Nuna pasvorto", "New password" : "Nova pasvorto", diff --git a/settings/l10n/eo.json b/settings/l10n/eo.json index 39f074ef265..8f20ea88e7f 100644 --- a/settings/l10n/eo.json +++ b/settings/l10n/eo.json @@ -103,7 +103,6 @@ "Get the apps to sync your files" : "Ekhavu la aplikaĵojn por sinkronigi viajn dosierojn", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Vi uzas <strong>%s</strong> el la disponeblaj <strong>%s</strong>", "Password" : "Pasvorto", - "Your password was changed" : "Via pasvorto ŝanĝiĝis", "Unable to change your password" : "Ne eblis ŝanĝi vian pasvorton", "Current password" : "Nuna pasvorto", "New password" : "Nova pasvorto", diff --git a/settings/l10n/es.js b/settings/l10n/es.js index 662cd614373..d87343756bd 100644 --- a/settings/l10n/es.js +++ b/settings/l10n/es.js @@ -206,7 +206,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostrar nuevamente el Asistente de ejecución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ha usado <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Su contraseña ha sido cambiada", "Unable to change your password" : "No se ha podido cambiar su contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña", diff --git a/settings/l10n/es.json b/settings/l10n/es.json index 8ea35ce5d0c..21a6eeb33bd 100644 --- a/settings/l10n/es.json +++ b/settings/l10n/es.json @@ -204,7 +204,6 @@ "Show First Run Wizard again" : "Mostrar nuevamente el Asistente de ejecución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ha usado <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Su contraseña ha sido cambiada", "Unable to change your password" : "No se ha podido cambiar su contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña", diff --git a/settings/l10n/es_AR.js b/settings/l10n/es_AR.js index 29707061740..ff9fca121c7 100644 --- a/settings/l10n/es_AR.js +++ b/settings/l10n/es_AR.js @@ -115,7 +115,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostrar de nuevo el asistente de primera ejecución", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usás <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Tu contraseña fue cambiada", "Unable to change your password" : "No fue posible cambiar tu contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña:", diff --git a/settings/l10n/es_AR.json b/settings/l10n/es_AR.json index 9239387063a..1ccfaeccef3 100644 --- a/settings/l10n/es_AR.json +++ b/settings/l10n/es_AR.json @@ -113,7 +113,6 @@ "Show First Run Wizard again" : "Mostrar de nuevo el asistente de primera ejecución", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usás <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Tu contraseña fue cambiada", "Unable to change your password" : "No fue posible cambiar tu contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña:", diff --git a/settings/l10n/es_MX.js b/settings/l10n/es_MX.js index 26e1d1955e9..4ac14bdb7f9 100644 --- a/settings/l10n/es_MX.js +++ b/settings/l10n/es_MX.js @@ -85,7 +85,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostrar nuevamente el Asistente de ejecución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ha usado <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Su contraseña ha sido cambiada", "Unable to change your password" : "No se ha podido cambiar su contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña", diff --git a/settings/l10n/es_MX.json b/settings/l10n/es_MX.json index a991d6439ac..d451f5c0a86 100644 --- a/settings/l10n/es_MX.json +++ b/settings/l10n/es_MX.json @@ -83,7 +83,6 @@ "Show First Run Wizard again" : "Mostrar nuevamente el Asistente de ejecución inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ha usado <strong>%s</strong> de los <strong>%s</strong> disponibles", "Password" : "Contraseña", - "Your password was changed" : "Su contraseña ha sido cambiada", "Unable to change your password" : "No se ha podido cambiar su contraseña", "Current password" : "Contraseña actual", "New password" : "Nueva contraseña", diff --git a/settings/l10n/et_EE.js b/settings/l10n/et_EE.js index 87d4c5abc7f..43673df6893 100644 --- a/settings/l10n/et_EE.js +++ b/settings/l10n/et_EE.js @@ -171,7 +171,6 @@ OC.L10N.register( "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", - "Your password was changed" : "Sinu parooli on muudetud", "Unable to change your password" : "Sa ei saa oma parooli muuta", "Current password" : "Praegune parool", "New password" : "Uus parool", diff --git a/settings/l10n/et_EE.json b/settings/l10n/et_EE.json index e43356e4dbb..a88e29a1896 100644 --- a/settings/l10n/et_EE.json +++ b/settings/l10n/et_EE.json @@ -169,7 +169,6 @@ "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", - "Your password was changed" : "Sinu parooli on muudetud", "Unable to change your password" : "Sa ei saa oma parooli muuta", "Current password" : "Praegune parool", "New password" : "Uus parool", diff --git a/settings/l10n/eu.js b/settings/l10n/eu.js index 35b430e372e..78b1999cecc 100644 --- a/settings/l10n/eu.js +++ b/settings/l10n/eu.js @@ -199,7 +199,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Erakutsi berriz Lehenengo Aldiko Morroia", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Dagoeneko <strong>%s</strong> erabili duzu eskuragarri duzun <strong>%s</strong>etatik", "Password" : "Pasahitza", - "Your password was changed" : "Zure pasahitza aldatu da", "Unable to change your password" : "Ezin izan da zure pasahitza aldatu", "Current password" : "Uneko pasahitza", "New password" : "Pasahitz berria", diff --git a/settings/l10n/eu.json b/settings/l10n/eu.json index 7f09ef4a0cc..7f250c79941 100644 --- a/settings/l10n/eu.json +++ b/settings/l10n/eu.json @@ -197,7 +197,6 @@ "Show First Run Wizard again" : "Erakutsi berriz Lehenengo Aldiko Morroia", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Dagoeneko <strong>%s</strong> erabili duzu eskuragarri duzun <strong>%s</strong>etatik", "Password" : "Pasahitza", - "Your password was changed" : "Zure pasahitza aldatu da", "Unable to change your password" : "Ezin izan da zure pasahitza aldatu", "Current password" : "Uneko pasahitza", "New password" : "Pasahitz berria", diff --git a/settings/l10n/fa.js b/settings/l10n/fa.js index 28a27162077..ecf7ddb8558 100644 --- a/settings/l10n/fa.js +++ b/settings/l10n/fa.js @@ -135,7 +135,6 @@ OC.L10N.register( "Show First Run Wizard again" : "راهبری کمکی اجرای اول را دوباره نمایش بده", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "شما استفاده کردید از <strong>%s</strong> از میزان در دسترس <strong>%s</strong>", "Password" : "گذرواژه", - "Your password was changed" : "رمز عبور شما تغییر یافت", "Unable to change your password" : "ناتوان در تغییر گذرواژه", "Current password" : "گذرواژه کنونی", "New password" : "گذرواژه جدید", diff --git a/settings/l10n/fa.json b/settings/l10n/fa.json index 226d11516d7..6d91b7e4064 100644 --- a/settings/l10n/fa.json +++ b/settings/l10n/fa.json @@ -133,7 +133,6 @@ "Show First Run Wizard again" : "راهبری کمکی اجرای اول را دوباره نمایش بده", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "شما استفاده کردید از <strong>%s</strong> از میزان در دسترس <strong>%s</strong>", "Password" : "گذرواژه", - "Your password was changed" : "رمز عبور شما تغییر یافت", "Unable to change your password" : "ناتوان در تغییر گذرواژه", "Current password" : "گذرواژه کنونی", "New password" : "گذرواژه جدید", diff --git a/settings/l10n/fi_FI.js b/settings/l10n/fi_FI.js index c5a6737c5e4..40c64f455ef 100644 --- a/settings/l10n/fi_FI.js +++ b/settings/l10n/fi_FI.js @@ -200,7 +200,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Näytä ensimmäisen käyttökerran avustaja uudelleen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Käytössäsi on <strong>%s</strong>/<strong>%s</strong>", "Password" : "Salasana", - "Your password was changed" : "Salasanasi vaihdettiin", "Unable to change your password" : "Salasanaasi ei voitu vaihtaa", "Current password" : "Nykyinen salasana", "New password" : "Uusi salasana", diff --git a/settings/l10n/fi_FI.json b/settings/l10n/fi_FI.json index f86134556b7..4b1d4d19c9c 100644 --- a/settings/l10n/fi_FI.json +++ b/settings/l10n/fi_FI.json @@ -198,7 +198,6 @@ "Show First Run Wizard again" : "Näytä ensimmäisen käyttökerran avustaja uudelleen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Käytössäsi on <strong>%s</strong>/<strong>%s</strong>", "Password" : "Salasana", - "Your password was changed" : "Salasanasi vaihdettiin", "Unable to change your password" : "Salasanaasi ei voitu vaihtaa", "Current password" : "Nykyinen salasana", "New password" : "Uusi salasana", diff --git a/settings/l10n/fr.js b/settings/l10n/fr.js index b8b197ec3fa..1b45b6d3e5f 100644 --- a/settings/l10n/fr.js +++ b/settings/l10n/fr.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Revoir la fenêtre d'accueil affichée lors de votre première connexion", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Vous utilisez <strong>%s</strong> des <strong>%s<strong> disponibles", "Password" : "Mot de passe", - "Your password was changed" : "Votre mot de passe a été changé", "Unable to change your password" : "Impossible de changer votre mot de passe", "Current password" : "Mot de passe actuel", "New password" : "Nouveau mot de passe", diff --git a/settings/l10n/fr.json b/settings/l10n/fr.json index d56ea8904b3..a76d6c765e0 100644 --- a/settings/l10n/fr.json +++ b/settings/l10n/fr.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Revoir la fenêtre d'accueil affichée lors de votre première connexion", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Vous utilisez <strong>%s</strong> des <strong>%s<strong> disponibles", "Password" : "Mot de passe", - "Your password was changed" : "Votre mot de passe a été changé", "Unable to change your password" : "Impossible de changer votre mot de passe", "Current password" : "Mot de passe actuel", "New password" : "Nouveau mot de passe", diff --git a/settings/l10n/gl.js b/settings/l10n/gl.js index 144e48e9c5a..6e4d165e2dc 100644 --- a/settings/l10n/gl.js +++ b/settings/l10n/gl.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Amosar o axudante da primeira execución outra vez", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ten en uso <strong>%s</strong> do total dispoñíbel de <strong>%s</strong>", "Password" : "Contrasinal", - "Your password was changed" : "O seu contrasinal foi cambiado", "Unable to change your password" : "Non é posíbel cambiar o seu contrasinal", "Current password" : "Contrasinal actual", "New password" : "Novo contrasinal", diff --git a/settings/l10n/gl.json b/settings/l10n/gl.json index c86aa42b361..a8ba75c4f6c 100644 --- a/settings/l10n/gl.json +++ b/settings/l10n/gl.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Amosar o axudante da primeira execución outra vez", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ten en uso <strong>%s</strong> do total dispoñíbel de <strong>%s</strong>", "Password" : "Contrasinal", - "Your password was changed" : "O seu contrasinal foi cambiado", "Unable to change your password" : "Non é posíbel cambiar o seu contrasinal", "Current password" : "Contrasinal actual", "New password" : "Novo contrasinal", diff --git a/settings/l10n/he.js b/settings/l10n/he.js index 038478d7a36..6788476e410 100644 --- a/settings/l10n/he.js +++ b/settings/l10n/he.js @@ -62,7 +62,6 @@ OC.L10N.register( "Show First Run Wizard again" : "הצגת אשף ההפעלה הראשונית שוב", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "השתמשת ב־<strong>%s</strong> מתוך <strong>%s</strong> הזמינים לך", "Password" : "סיסמא", - "Your password was changed" : "הססמה שלך הוחלפה", "Unable to change your password" : "לא ניתן לשנות את הססמה שלך", "Current password" : "ססמה נוכחית", "New password" : "ססמה חדשה", diff --git a/settings/l10n/he.json b/settings/l10n/he.json index 57029e3d7cf..076e4bbd68f 100644 --- a/settings/l10n/he.json +++ b/settings/l10n/he.json @@ -60,7 +60,6 @@ "Show First Run Wizard again" : "הצגת אשף ההפעלה הראשונית שוב", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "השתמשת ב־<strong>%s</strong> מתוך <strong>%s</strong> הזמינים לך", "Password" : "סיסמא", - "Your password was changed" : "הססמה שלך הוחלפה", "Unable to change your password" : "לא ניתן לשנות את הססמה שלך", "Current password" : "ססמה נוכחית", "New password" : "ססמה חדשה", diff --git a/settings/l10n/hr.js b/settings/l10n/hr.js index 22f0770a50b..ba6b71c0a2d 100644 --- a/settings/l10n/hr.js +++ b/settings/l10n/hr.js @@ -159,7 +159,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Opet pokažite First Run Wizard", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Iskoristili ste <strong>%s</strong> od raspoloživog <strong>%s</strong>", "Password" : "Lozinka", - "Your password was changed" : "Vaša je lozinka promijenjena", "Unable to change your password" : "Vašu lozinku nije moguće promijeniti", "Current password" : "Trenutna lozinka", "New password" : "Nova lozinka", diff --git a/settings/l10n/hr.json b/settings/l10n/hr.json index efdcabbb067..53968fd10d2 100644 --- a/settings/l10n/hr.json +++ b/settings/l10n/hr.json @@ -157,7 +157,6 @@ "Show First Run Wizard again" : "Opet pokažite First Run Wizard", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Iskoristili ste <strong>%s</strong> od raspoloživog <strong>%s</strong>", "Password" : "Lozinka", - "Your password was changed" : "Vaša je lozinka promijenjena", "Unable to change your password" : "Vašu lozinku nije moguće promijeniti", "Current password" : "Trenutna lozinka", "New password" : "Nova lozinka", diff --git a/settings/l10n/hu_HU.js b/settings/l10n/hu_HU.js index 78cd074d7bc..6eb11e35281 100644 --- a/settings/l10n/hu_HU.js +++ b/settings/l10n/hu_HU.js @@ -157,7 +157,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Nézzük meg újra az első bejelentkezéskori segítséget!", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Az Ön tárterület-felhasználása jelenleg: <strong>%s</strong>. Maximálisan ennyi áll rendelkezésére: <strong>%s</strong>", "Password" : "Jelszó", - "Your password was changed" : "A jelszava megváltozott", "Unable to change your password" : "A jelszó nem változtatható meg", "Current password" : "A jelenlegi jelszó", "New password" : "Az új jelszó", diff --git a/settings/l10n/hu_HU.json b/settings/l10n/hu_HU.json index 6764efd7e2b..7cf45d0c4e0 100644 --- a/settings/l10n/hu_HU.json +++ b/settings/l10n/hu_HU.json @@ -155,7 +155,6 @@ "Show First Run Wizard again" : "Nézzük meg újra az első bejelentkezéskori segítséget!", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Az Ön tárterület-felhasználása jelenleg: <strong>%s</strong>. Maximálisan ennyi áll rendelkezésére: <strong>%s</strong>", "Password" : "Jelszó", - "Your password was changed" : "A jelszava megváltozott", "Unable to change your password" : "A jelszó nem változtatható meg", "Current password" : "A jelenlegi jelszó", "New password" : "Az új jelszó", diff --git a/settings/l10n/id.js b/settings/l10n/id.js index 8d23b994ade..596f961e650 100644 --- a/settings/l10n/id.js +++ b/settings/l10n/id.js @@ -199,7 +199,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Tampilkan Penuntun Konfigurasi Awal", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Anda telah menggunakan <strong>%s</strong> dari total <strong>%s</strong>", "Password" : "Sandi", - "Your password was changed" : "Sandi Anda telah diubah", "Unable to change your password" : "Gagal mengubah sandi Anda", "Current password" : "Sandi saat ini", "New password" : "Sandi baru", diff --git a/settings/l10n/id.json b/settings/l10n/id.json index 04671c29a8a..4bf286c2249 100644 --- a/settings/l10n/id.json +++ b/settings/l10n/id.json @@ -197,7 +197,6 @@ "Show First Run Wizard again" : "Tampilkan Penuntun Konfigurasi Awal", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Anda telah menggunakan <strong>%s</strong> dari total <strong>%s</strong>", "Password" : "Sandi", - "Your password was changed" : "Sandi Anda telah diubah", "Unable to change your password" : "Gagal mengubah sandi Anda", "Current password" : "Sandi saat ini", "New password" : "Sandi baru", diff --git a/settings/l10n/is.js b/settings/l10n/is.js index f3c408a5b1e..c89ac8d95f3 100644 --- a/settings/l10n/is.js +++ b/settings/l10n/is.js @@ -36,7 +36,6 @@ OC.L10N.register( "Commercial Support" : "Borgaður stuðningur", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Þú hefur notað <strong>%s</strong> af tiltæku <strong>%s</strong>", "Password" : "Lykilorð", - "Your password was changed" : "Lykilorði þínu hefur verið breytt", "Unable to change your password" : "Ekki tókst að breyta lykilorðinu þínu", "Current password" : "Núverandi lykilorð", "New password" : "Nýtt lykilorð", diff --git a/settings/l10n/is.json b/settings/l10n/is.json index 424e4f5c32e..3b61d9f363e 100644 --- a/settings/l10n/is.json +++ b/settings/l10n/is.json @@ -34,7 +34,6 @@ "Commercial Support" : "Borgaður stuðningur", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Þú hefur notað <strong>%s</strong> af tiltæku <strong>%s</strong>", "Password" : "Lykilorð", - "Your password was changed" : "Lykilorði þínu hefur verið breytt", "Unable to change your password" : "Ekki tókst að breyta lykilorðinu þínu", "Current password" : "Núverandi lykilorð", "New password" : "Nýtt lykilorð", diff --git a/settings/l10n/it.js b/settings/l10n/it.js index 3598b81ba90..d2d09d580a3 100644 --- a/settings/l10n/it.js +++ b/settings/l10n/it.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostra nuovamente la procedura di primo avvio", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Hai utilizzato <strong>%s</strong> dei <strong>%s</strong> disponibili", "Password" : "Password", - "Your password was changed" : "La tua password è cambiata", "Unable to change your password" : "Modifica password non riuscita", "Current password" : "Password attuale", "New password" : "Nuova password", diff --git a/settings/l10n/it.json b/settings/l10n/it.json index 08b5adf2d9e..cbabc620152 100644 --- a/settings/l10n/it.json +++ b/settings/l10n/it.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Mostra nuovamente la procedura di primo avvio", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Hai utilizzato <strong>%s</strong> dei <strong>%s</strong> disponibili", "Password" : "Password", - "Your password was changed" : "La tua password è cambiata", "Unable to change your password" : "Modifica password non riuscita", "Current password" : "Password attuale", "New password" : "Nuova password", diff --git a/settings/l10n/ja.js b/settings/l10n/ja.js index a38e852e4c9..18a5e959b85 100644 --- a/settings/l10n/ja.js +++ b/settings/l10n/ja.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "初回ウィザードを再表示する", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "現在 <strong>%s</strong> / <strong>%s</strong> を利用しています", "Password" : "パスワード", - "Your password was changed" : "パスワードを変更しました", "Unable to change your password" : "パスワードを変更することができません", "Current password" : "現在のパスワード", "New password" : "新しいパスワード", diff --git a/settings/l10n/ja.json b/settings/l10n/ja.json index 832c3ac895a..a6ddc9b4047 100644 --- a/settings/l10n/ja.json +++ b/settings/l10n/ja.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "初回ウィザードを再表示する", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "現在 <strong>%s</strong> / <strong>%s</strong> を利用しています", "Password" : "パスワード", - "Your password was changed" : "パスワードを変更しました", "Unable to change your password" : "パスワードを変更することができません", "Current password" : "現在のパスワード", "New password" : "新しいパスワード", diff --git a/settings/l10n/ka_GE.js b/settings/l10n/ka_GE.js index 6d968ff1d9c..176faa93185 100644 --- a/settings/l10n/ka_GE.js +++ b/settings/l10n/ka_GE.js @@ -62,7 +62,6 @@ OC.L10N.register( "Show First Run Wizard again" : "მაჩვენე თავიდან გაშვებული ვიზარდი", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "თქვენ გამოყენებული გაქვთ <strong>%s</strong> –ი –<strong>%s<strong>–დან", "Password" : "პაროლი", - "Your password was changed" : "თქვენი პაროლი შეიცვალა", "Unable to change your password" : "თქვენი პაროლი არ შეიცვალა", "Current password" : "მიმდინარე პაროლი", "New password" : "ახალი პაროლი", diff --git a/settings/l10n/ka_GE.json b/settings/l10n/ka_GE.json index a852ecbf45e..40862fa6f00 100644 --- a/settings/l10n/ka_GE.json +++ b/settings/l10n/ka_GE.json @@ -60,7 +60,6 @@ "Show First Run Wizard again" : "მაჩვენე თავიდან გაშვებული ვიზარდი", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "თქვენ გამოყენებული გაქვთ <strong>%s</strong> –ი –<strong>%s<strong>–დან", "Password" : "პაროლი", - "Your password was changed" : "თქვენი პაროლი შეიცვალა", "Unable to change your password" : "თქვენი პაროლი არ შეიცვალა", "Current password" : "მიმდინარე პაროლი", "New password" : "ახალი პაროლი", diff --git a/settings/l10n/km.js b/settings/l10n/km.js index 253fc61aab2..e243bb15cd5 100644 --- a/settings/l10n/km.js +++ b/settings/l10n/km.js @@ -79,7 +79,6 @@ OC.L10N.register( "Show First Run Wizard again" : "បង្ហាញ First Run Wizard ម្តងទៀត", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "អ្នកបានប្រើ <strong>%s</strong> ក្នុងចំណោមចំនួនមាន <strong>%s</strong>", "Password" : "ពាក្យសម្ងាត់", - "Your password was changed" : "ពាក្យសម្ងាត់របស់អ្នកត្រូវបានប្ដូរ", "Unable to change your password" : "មិនអាចប្ដូរពាក្យសម្ងាត់របស់អ្នកបានទេ", "Current password" : "ពាក្យសម្ងាត់បច្ចុប្បន្ន", "New password" : "ពាក្យសម្ងាត់ថ្មី", diff --git a/settings/l10n/km.json b/settings/l10n/km.json index 45d5b992f6c..2fa48eee176 100644 --- a/settings/l10n/km.json +++ b/settings/l10n/km.json @@ -77,7 +77,6 @@ "Show First Run Wizard again" : "បង្ហាញ First Run Wizard ម្តងទៀត", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "អ្នកបានប្រើ <strong>%s</strong> ក្នុងចំណោមចំនួនមាន <strong>%s</strong>", "Password" : "ពាក្យសម្ងាត់", - "Your password was changed" : "ពាក្យសម្ងាត់របស់អ្នកត្រូវបានប្ដូរ", "Unable to change your password" : "មិនអាចប្ដូរពាក្យសម្ងាត់របស់អ្នកបានទេ", "Current password" : "ពាក្យសម្ងាត់បច្ចុប្បន្ន", "New password" : "ពាក្យសម្ងាត់ថ្មី", diff --git a/settings/l10n/kn.js b/settings/l10n/kn.js index 8d7bd3c2a1f..4bfcff4af4f 100644 --- a/settings/l10n/kn.js +++ b/settings/l10n/kn.js @@ -130,7 +130,6 @@ OC.L10N.register( "Bugtracker" : "ವಿವಾದಾ೦ಶ ಅನ್ವಷಕ ", "Commercial Support" : "ವಾಣಿಜ್ಯ ಬೆಂಬಲ", "Password" : "ಗುಪ್ತ ಪದ", - "Your password was changed" : "ನಿಮ್ಮ ಗುಪ್ತಪದವನ್ನು ಬದಲಾಯಿತು", "Unable to change your password" : "ನಿನ್ನ ಗುಪ್ತಪದವನ್ನು ಬದಲಾಯಿಸಲು ಸಾಧ್ಯವಿಲ್ಲ", "Current password" : "ಪ್ರಸ್ತುತ ಗುಪ್ತಪದ", "New password" : "ಹೊಸ ಗುಪ್ತಪದ", diff --git a/settings/l10n/kn.json b/settings/l10n/kn.json index e3e8491ab5b..d772f8f3770 100644 --- a/settings/l10n/kn.json +++ b/settings/l10n/kn.json @@ -128,7 +128,6 @@ "Bugtracker" : "ವಿವಾದಾ೦ಶ ಅನ್ವಷಕ ", "Commercial Support" : "ವಾಣಿಜ್ಯ ಬೆಂಬಲ", "Password" : "ಗುಪ್ತ ಪದ", - "Your password was changed" : "ನಿಮ್ಮ ಗುಪ್ತಪದವನ್ನು ಬದಲಾಯಿತು", "Unable to change your password" : "ನಿನ್ನ ಗುಪ್ತಪದವನ್ನು ಬದಲಾಯಿಸಲು ಸಾಧ್ಯವಿಲ್ಲ", "Current password" : "ಪ್ರಸ್ತುತ ಗುಪ್ತಪದ", "New password" : "ಹೊಸ ಗುಪ್ತಪದ", diff --git a/settings/l10n/ko.js b/settings/l10n/ko.js index 850f4c5691a..9a957f1c0cc 100644 --- a/settings/l10n/ko.js +++ b/settings/l10n/ko.js @@ -202,7 +202,6 @@ OC.L10N.register( "Show First Run Wizard again" : "첫 실행 마법사 다시 보이기", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "현재 공간 중 <strong>%s</strong>/<strong>%s</strong>을(를) 사용 중입니다", "Password" : "암호", - "Your password was changed" : "암호가 변경되었습니다", "Unable to change your password" : "암호를 변경할 수 없음", "Current password" : "현재 암호", "New password" : "새 암호", diff --git a/settings/l10n/ko.json b/settings/l10n/ko.json index 9678fb6c140..a9ca8c5ae9e 100644 --- a/settings/l10n/ko.json +++ b/settings/l10n/ko.json @@ -200,7 +200,6 @@ "Show First Run Wizard again" : "첫 실행 마법사 다시 보이기", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "현재 공간 중 <strong>%s</strong>/<strong>%s</strong>을(를) 사용 중입니다", "Password" : "암호", - "Your password was changed" : "암호가 변경되었습니다", "Unable to change your password" : "암호를 변경할 수 없음", "Current password" : "현재 암호", "New password" : "새 암호", diff --git a/settings/l10n/lt_LT.js b/settings/l10n/lt_LT.js index 33faafdcdd7..a4bd1c8cf29 100644 --- a/settings/l10n/lt_LT.js +++ b/settings/l10n/lt_LT.js @@ -81,7 +81,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Rodyti pirmo karto vedlį dar kartą", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Jūs naudojate <strong>%s</strong> iš galimų <strong>%s</strong>", "Password" : "Slaptažodis", - "Your password was changed" : "Jūsų slaptažodis buvo pakeistas", "Unable to change your password" : "Neįmanoma pakeisti slaptažodžio", "Current password" : "Dabartinis slaptažodis", "New password" : "Naujas slaptažodis", diff --git a/settings/l10n/lt_LT.json b/settings/l10n/lt_LT.json index 38a457f9eaa..5cd7d7d70cc 100644 --- a/settings/l10n/lt_LT.json +++ b/settings/l10n/lt_LT.json @@ -79,7 +79,6 @@ "Show First Run Wizard again" : "Rodyti pirmo karto vedlį dar kartą", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Jūs naudojate <strong>%s</strong> iš galimų <strong>%s</strong>", "Password" : "Slaptažodis", - "Your password was changed" : "Jūsų slaptažodis buvo pakeistas", "Unable to change your password" : "Neįmanoma pakeisti slaptažodžio", "Current password" : "Dabartinis slaptažodis", "New password" : "Naujas slaptažodis", diff --git a/settings/l10n/lv.js b/settings/l10n/lv.js index a8165344fb3..335359e4170 100644 --- a/settings/l10n/lv.js +++ b/settings/l10n/lv.js @@ -144,7 +144,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Vēlreiz rādīt pirmās palaišanas vedni", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Jūs lietojat <strong>%s</strong> no pieejamajiem <strong>%s</strong>", "Password" : "Parole", - "Your password was changed" : "Jūru parole tika nomainīta", "Unable to change your password" : "Nevar nomainīt jūsu paroli", "Current password" : "Pašreizējā parole", "New password" : "Jauna parole", diff --git a/settings/l10n/lv.json b/settings/l10n/lv.json index c73a4fe6deb..e3ac702051d 100644 --- a/settings/l10n/lv.json +++ b/settings/l10n/lv.json @@ -142,7 +142,6 @@ "Show First Run Wizard again" : "Vēlreiz rādīt pirmās palaišanas vedni", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Jūs lietojat <strong>%s</strong> no pieejamajiem <strong>%s</strong>", "Password" : "Parole", - "Your password was changed" : "Jūru parole tika nomainīta", "Unable to change your password" : "Nevar nomainīt jūsu paroli", "Current password" : "Pašreizējā parole", "New password" : "Jauna parole", diff --git a/settings/l10n/mk.js b/settings/l10n/mk.js index d105bb993f1..c1755f1c1f9 100644 --- a/settings/l10n/mk.js +++ b/settings/l10n/mk.js @@ -116,7 +116,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Прикажи го повторно волшебникот при првото стартување", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Имате искористено <strong>%s</strong> од достапните <strong>%s</strong>", "Password" : "Лозинка", - "Your password was changed" : "Вашата лозинка беше променета.", "Unable to change your password" : "Вашата лозинка неможе да се смени", "Current password" : "Моментална лозинка", "New password" : "Нова лозинка", diff --git a/settings/l10n/mk.json b/settings/l10n/mk.json index 958a2d4efe5..803a95c1d02 100644 --- a/settings/l10n/mk.json +++ b/settings/l10n/mk.json @@ -114,7 +114,6 @@ "Show First Run Wizard again" : "Прикажи го повторно волшебникот при првото стартување", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Имате искористено <strong>%s</strong> од достапните <strong>%s</strong>", "Password" : "Лозинка", - "Your password was changed" : "Вашата лозинка беше променета.", "Unable to change your password" : "Вашата лозинка неможе да се смени", "Current password" : "Моментална лозинка", "New password" : "Нова лозинка", diff --git a/settings/l10n/nb_NO.js b/settings/l10n/nb_NO.js index a770fc623c9..0b1f7d38aa4 100644 --- a/settings/l10n/nb_NO.js +++ b/settings/l10n/nb_NO.js @@ -202,7 +202,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Vis \"Førstegangs veiviser\" på nytt", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brukt <strong>%s</strong> av de tilgjengelige <strong>%s</strong>", "Password" : "Passord", - "Your password was changed" : "Passord har blitt endret", "Unable to change your password" : "Kunne ikke endre passordet ditt", "Current password" : "Nåværende passord", "New password" : "Nytt passord", diff --git a/settings/l10n/nb_NO.json b/settings/l10n/nb_NO.json index 311a945155d..4262761da91 100644 --- a/settings/l10n/nb_NO.json +++ b/settings/l10n/nb_NO.json @@ -200,7 +200,6 @@ "Show First Run Wizard again" : "Vis \"Førstegangs veiviser\" på nytt", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brukt <strong>%s</strong> av de tilgjengelige <strong>%s</strong>", "Password" : "Passord", - "Your password was changed" : "Passord har blitt endret", "Unable to change your password" : "Kunne ikke endre passordet ditt", "Current password" : "Nåværende passord", "New password" : "Nytt passord", diff --git a/settings/l10n/nl.js b/settings/l10n/nl.js index 4ef5edc1a17..bce1ce6c007 100644 --- a/settings/l10n/nl.js +++ b/settings/l10n/nl.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Toon de Eerste start Wizard opnieuw", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "U heeft <strong>%s</strong> gebruikt van de beschikbare <strong>%s</strong>", "Password" : "Wachtwoord", - "Your password was changed" : "Je wachtwoord is veranderd", "Unable to change your password" : "Niet in staat om uw wachtwoord te wijzigen", "Current password" : "Huidig wachtwoord", "New password" : "Nieuw", diff --git a/settings/l10n/nl.json b/settings/l10n/nl.json index c1f7e7b5d32..ba6ea8094aa 100644 --- a/settings/l10n/nl.json +++ b/settings/l10n/nl.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Toon de Eerste start Wizard opnieuw", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "U heeft <strong>%s</strong> gebruikt van de beschikbare <strong>%s</strong>", "Password" : "Wachtwoord", - "Your password was changed" : "Je wachtwoord is veranderd", "Unable to change your password" : "Niet in staat om uw wachtwoord te wijzigen", "Current password" : "Huidig wachtwoord", "New password" : "Nieuw", diff --git a/settings/l10n/nn_NO.js b/settings/l10n/nn_NO.js index 626c8881a6a..a3a7b28ecc8 100644 --- a/settings/l10n/nn_NO.js +++ b/settings/l10n/nn_NO.js @@ -72,7 +72,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Vis Oppstartvegvisaren igjen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brukt <strong>%s</strong> av dine tilgjengelege <strong>%s</strong>", "Password" : "Passord", - "Your password was changed" : "Passordet ditt er endra", "Unable to change your password" : "Klarte ikkje endra passordet", "Current password" : "Passord", "New password" : "Nytt passord", diff --git a/settings/l10n/nn_NO.json b/settings/l10n/nn_NO.json index 517b14dbaf3..ae608118105 100644 --- a/settings/l10n/nn_NO.json +++ b/settings/l10n/nn_NO.json @@ -70,7 +70,6 @@ "Show First Run Wizard again" : "Vis Oppstartvegvisaren igjen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har brukt <strong>%s</strong> av dine tilgjengelege <strong>%s</strong>", "Password" : "Passord", - "Your password was changed" : "Passordet ditt er endra", "Unable to change your password" : "Klarte ikkje endra passordet", "Current password" : "Passord", "New password" : "Nytt passord", diff --git a/settings/l10n/oc.js b/settings/l10n/oc.js index 0c025b54d1e..d1f686f18bc 100644 --- a/settings/l10n/oc.js +++ b/settings/l10n/oc.js @@ -23,7 +23,6 @@ OC.L10N.register( "More" : "Mai d'aquò", "by" : "per", "Password" : "Senhal", - "Your password was changed" : "Ton senhal a cambiat", "Unable to change your password" : "Pas possible de cambiar ton senhal", "Current password" : "Senhal en cors", "New password" : "Senhal novèl", diff --git a/settings/l10n/oc.json b/settings/l10n/oc.json index dbf2a7f3dfd..700e91c3d73 100644 --- a/settings/l10n/oc.json +++ b/settings/l10n/oc.json @@ -21,7 +21,6 @@ "More" : "Mai d'aquò", "by" : "per", "Password" : "Senhal", - "Your password was changed" : "Ton senhal a cambiat", "Unable to change your password" : "Pas possible de cambiar ton senhal", "Current password" : "Senhal en cors", "New password" : "Senhal novèl", diff --git a/settings/l10n/pl.js b/settings/l10n/pl.js index 044500b756d..121f90a5af6 100644 --- a/settings/l10n/pl.js +++ b/settings/l10n/pl.js @@ -195,7 +195,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Uruchom ponownie kreatora pierwszego uruchomienia", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Wykorzystujesz <strong>%s</strong> z dostępnych <strong>%s</strong>", "Password" : "Hasło", - "Your password was changed" : "Twoje hasło zostało zmienione", "Unable to change your password" : "Nie można zmienić hasła", "Current password" : "Bieżące hasło", "New password" : "Nowe hasło", diff --git a/settings/l10n/pl.json b/settings/l10n/pl.json index 1e6cc0a54d8..ea50c2c51ee 100644 --- a/settings/l10n/pl.json +++ b/settings/l10n/pl.json @@ -193,7 +193,6 @@ "Show First Run Wizard again" : "Uruchom ponownie kreatora pierwszego uruchomienia", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Wykorzystujesz <strong>%s</strong> z dostępnych <strong>%s</strong>", "Password" : "Hasło", - "Your password was changed" : "Twoje hasło zostało zmienione", "Unable to change your password" : "Nie można zmienić hasła", "Current password" : "Bieżące hasło", "New password" : "Nowe hasło", diff --git a/settings/l10n/pt_BR.js b/settings/l10n/pt_BR.js index a82eb562434..b19c48b81b5 100644 --- a/settings/l10n/pt_BR.js +++ b/settings/l10n/pt_BR.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostrar Assistente de Primeira Execução novamente", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Você usou <strong>%s</strong> do seu espaço de <strong>%s</strong>", "Password" : "Senha", - "Your password was changed" : "Sua senha foi alterada", "Unable to change your password" : "Não é possivel alterar a sua senha", "Current password" : "Senha atual", "New password" : "Nova senha", diff --git a/settings/l10n/pt_BR.json b/settings/l10n/pt_BR.json index ba87d32eaa0..16e085db6a2 100644 --- a/settings/l10n/pt_BR.json +++ b/settings/l10n/pt_BR.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Mostrar Assistente de Primeira Execução novamente", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Você usou <strong>%s</strong> do seu espaço de <strong>%s</strong>", "Password" : "Senha", - "Your password was changed" : "Sua senha foi alterada", "Unable to change your password" : "Não é possivel alterar a sua senha", "Current password" : "Senha atual", "New password" : "Nova senha", diff --git a/settings/l10n/pt_PT.js b/settings/l10n/pt_PT.js index 88e9ce961fd..b285fa8569c 100644 --- a/settings/l10n/pt_PT.js +++ b/settings/l10n/pt_PT.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Mostrar novamente Wizard de Arranque Inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usou <strong>%s</strong> do disponivel <strong>%s</strong>", "Password" : "Palavra-passe", - "Your password was changed" : "A sua palavra-passe foi alterada", "Unable to change your password" : "Não foi possível alterar a sua palavra-passe", "Current password" : "Palavra-passe atual", "New password" : "Nova palavra-passe", diff --git a/settings/l10n/pt_PT.json b/settings/l10n/pt_PT.json index 517f66da82b..7d9f87dad02 100644 --- a/settings/l10n/pt_PT.json +++ b/settings/l10n/pt_PT.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Mostrar novamente Wizard de Arranque Inicial", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Usou <strong>%s</strong> do disponivel <strong>%s</strong>", "Password" : "Palavra-passe", - "Your password was changed" : "A sua palavra-passe foi alterada", "Unable to change your password" : "Não foi possível alterar a sua palavra-passe", "Current password" : "Palavra-passe atual", "New password" : "Nova palavra-passe", diff --git a/settings/l10n/ro.js b/settings/l10n/ro.js index c21c575340c..fd8cfe72aef 100644 --- a/settings/l10n/ro.js +++ b/settings/l10n/ro.js @@ -93,7 +93,6 @@ OC.L10N.register( "Get the apps to sync your files" : "Ia acum aplicatia pentru sincronizarea fisierelor ", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ați utilizat <strong>%s</strong> din <strong>%s</strong> disponibile", "Password" : "Parolă", - "Your password was changed" : "Parola a fost modificată", "Unable to change your password" : "Imposibil de-ați schimbat parola", "Current password" : "Parola curentă", "New password" : "Noua parolă", diff --git a/settings/l10n/ro.json b/settings/l10n/ro.json index 202eca186ba..7e7e33abd34 100644 --- a/settings/l10n/ro.json +++ b/settings/l10n/ro.json @@ -91,7 +91,6 @@ "Get the apps to sync your files" : "Ia acum aplicatia pentru sincronizarea fisierelor ", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ați utilizat <strong>%s</strong> din <strong>%s</strong> disponibile", "Password" : "Parolă", - "Your password was changed" : "Parola a fost modificată", "Unable to change your password" : "Imposibil de-ați schimbat parola", "Current password" : "Parola curentă", "New password" : "Noua parolă", diff --git a/settings/l10n/ru.js b/settings/l10n/ru.js index dc8c42ab8c4..44708e116ba 100644 --- a/settings/l10n/ru.js +++ b/settings/l10n/ru.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Показать помощник настройки снова", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Вы использовали <strong>%s</strong> из доступных <strong>%s</strong>", "Password" : "Пароль", - "Your password was changed" : "Ваш пароль был изменён", "Unable to change your password" : "Невозможно сменить пароль", "Current password" : "Текущий пароль", "New password" : "Новый пароль", diff --git a/settings/l10n/ru.json b/settings/l10n/ru.json index 2e7dfb544ad..7a658429a22 100644 --- a/settings/l10n/ru.json +++ b/settings/l10n/ru.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "Показать помощник настройки снова", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Вы использовали <strong>%s</strong> из доступных <strong>%s</strong>", "Password" : "Пароль", - "Your password was changed" : "Ваш пароль был изменён", "Unable to change your password" : "Невозможно сменить пароль", "Current password" : "Текущий пароль", "New password" : "Новый пароль", diff --git a/settings/l10n/si_LK.js b/settings/l10n/si_LK.js index dfe65fe1d89..1e7df83d8dd 100644 --- a/settings/l10n/si_LK.js +++ b/settings/l10n/si_LK.js @@ -28,7 +28,6 @@ OC.L10N.register( "Less" : "අඩු", "by" : "විසින්", "Password" : "මුර පදය", - "Your password was changed" : "ඔබගේ මුර පදය වෙනස් කෙරුණි", "Unable to change your password" : "මුර පදය වෙනස් කළ නොහැකි විය", "Current password" : "වත්මන් මුරපදය", "New password" : "නව මුරපදය", diff --git a/settings/l10n/si_LK.json b/settings/l10n/si_LK.json index f295fd21691..3a70a7d5b4a 100644 --- a/settings/l10n/si_LK.json +++ b/settings/l10n/si_LK.json @@ -26,7 +26,6 @@ "Less" : "අඩු", "by" : "විසින්", "Password" : "මුර පදය", - "Your password was changed" : "ඔබගේ මුර පදය වෙනස් කෙරුණි", "Unable to change your password" : "මුර පදය වෙනස් කළ නොහැකි විය", "Current password" : "වත්මන් මුරපදය", "New password" : "නව මුරපදය", diff --git a/settings/l10n/sk_SK.js b/settings/l10n/sk_SK.js index c342480cc68..d77b0d6786b 100644 --- a/settings/l10n/sk_SK.js +++ b/settings/l10n/sk_SK.js @@ -202,7 +202,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Znovu zobraziť sprievodcu prvým spustením", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Použili ste <strong>%s</strong> z <strong>%s</strong> dostupných ", "Password" : "Heslo", - "Your password was changed" : "Vaše heslo bolo zmenené", "Unable to change your password" : "Nie je možné zmeniť vaše heslo", "Current password" : "Aktuálne heslo", "New password" : "Nové heslo", diff --git a/settings/l10n/sk_SK.json b/settings/l10n/sk_SK.json index d638c878639..dac528cb896 100644 --- a/settings/l10n/sk_SK.json +++ b/settings/l10n/sk_SK.json @@ -200,7 +200,6 @@ "Show First Run Wizard again" : "Znovu zobraziť sprievodcu prvým spustením", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Použili ste <strong>%s</strong> z <strong>%s</strong> dostupných ", "Password" : "Heslo", - "Your password was changed" : "Vaše heslo bolo zmenené", "Unable to change your password" : "Nie je možné zmeniť vaše heslo", "Current password" : "Aktuálne heslo", "New password" : "Nové heslo", diff --git a/settings/l10n/sl.js b/settings/l10n/sl.js index 42c85f42187..23a37851b2d 100644 --- a/settings/l10n/sl.js +++ b/settings/l10n/sl.js @@ -183,7 +183,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Zaženi čarovnika prvega zagona", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Uporabljenega je <strong>%s</strong> od razpoložljivih <strong>%s</strong> prostora.", "Password" : "Geslo", - "Your password was changed" : "Geslo je spremenjeno", "Unable to change your password" : "Gesla ni mogoče spremeniti.", "Current password" : "Trenutno geslo", "New password" : "Novo geslo", diff --git a/settings/l10n/sl.json b/settings/l10n/sl.json index 57aa3377864..bfa3077dafb 100644 --- a/settings/l10n/sl.json +++ b/settings/l10n/sl.json @@ -181,7 +181,6 @@ "Show First Run Wizard again" : "Zaženi čarovnika prvega zagona", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Uporabljenega je <strong>%s</strong> od razpoložljivih <strong>%s</strong> prostora.", "Password" : "Geslo", - "Your password was changed" : "Geslo je spremenjeno", "Unable to change your password" : "Gesla ni mogoče spremeniti.", "Current password" : "Trenutno geslo", "New password" : "Novo geslo", diff --git a/settings/l10n/sq.js b/settings/l10n/sq.js index a878c4939e9..54f483e55d3 100644 --- a/settings/l10n/sq.js +++ b/settings/l10n/sq.js @@ -101,7 +101,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Rishfaq përsëri fazat për hapjen e herës së parë", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ju keni përdorur <strong>%s</strong> nga <strong>%s</strong> të mundshme ", "Password" : "Fjalëkalim", - "Your password was changed" : "fjalëkalimi juaj u ndryshua", "Unable to change your password" : "Nuk është e mundur të ndryshohet fjalëkalimi", "Current password" : "Fjalëkalimi aktual", "New password" : "Fjalëkalimi i ri", diff --git a/settings/l10n/sq.json b/settings/l10n/sq.json index 940649710d4..409a0321175 100644 --- a/settings/l10n/sq.json +++ b/settings/l10n/sq.json @@ -99,7 +99,6 @@ "Show First Run Wizard again" : "Rishfaq përsëri fazat për hapjen e herës së parë", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ju keni përdorur <strong>%s</strong> nga <strong>%s</strong> të mundshme ", "Password" : "Fjalëkalim", - "Your password was changed" : "fjalëkalimi juaj u ndryshua", "Unable to change your password" : "Nuk është e mundur të ndryshohet fjalëkalimi", "Current password" : "Fjalëkalimi aktual", "New password" : "Fjalëkalimi i ri", diff --git a/settings/l10n/sr.js b/settings/l10n/sr.js index ad8a5f883b9..e0b57625ec1 100644 --- a/settings/l10n/sr.js +++ b/settings/l10n/sr.js @@ -77,7 +77,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Поново прикажи чаробњак за прво покретање", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Искористили сте <strong>%s</strong> од дозвољених <strong>%s</strong>", "Password" : "Лозинка", - "Your password was changed" : "Лозинка је промењена", "Unable to change your password" : "Не могу да изменим вашу лозинку", "Current password" : "Тренутна лозинка", "New password" : "Нова лозинка", diff --git a/settings/l10n/sr.json b/settings/l10n/sr.json index a279c927549..453829661da 100644 --- a/settings/l10n/sr.json +++ b/settings/l10n/sr.json @@ -75,7 +75,6 @@ "Show First Run Wizard again" : "Поново прикажи чаробњак за прво покретање", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Искористили сте <strong>%s</strong> од дозвољених <strong>%s</strong>", "Password" : "Лозинка", - "Your password was changed" : "Лозинка је промењена", "Unable to change your password" : "Не могу да изменим вашу лозинку", "Current password" : "Тренутна лозинка", "New password" : "Нова лозинка", diff --git a/settings/l10n/sv.js b/settings/l10n/sv.js index 5666613033d..3f510f1d407 100644 --- a/settings/l10n/sv.js +++ b/settings/l10n/sv.js @@ -198,7 +198,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Visa Första uppstarts-guiden igen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har använt <strong>%s</strong> av tillgängliga <strong>%s</strong>", "Password" : "Lösenord", - "Your password was changed" : "Ditt lösenord har ändrats", "Unable to change your password" : "Kunde inte ändra ditt lösenord", "Current password" : "Nuvarande lösenord", "New password" : "Nytt lösenord", diff --git a/settings/l10n/sv.json b/settings/l10n/sv.json index f7dc49fb1a8..11b6f9b5b5c 100644 --- a/settings/l10n/sv.json +++ b/settings/l10n/sv.json @@ -196,7 +196,6 @@ "Show First Run Wizard again" : "Visa Första uppstarts-guiden igen", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Du har använt <strong>%s</strong> av tillgängliga <strong>%s</strong>", "Password" : "Lösenord", - "Your password was changed" : "Ditt lösenord har ändrats", "Unable to change your password" : "Kunde inte ändra ditt lösenord", "Current password" : "Nuvarande lösenord", "New password" : "Nytt lösenord", diff --git a/settings/l10n/ta_LK.js b/settings/l10n/ta_LK.js index c1088c3ca83..69bd9b741fc 100644 --- a/settings/l10n/ta_LK.js +++ b/settings/l10n/ta_LK.js @@ -28,7 +28,6 @@ OC.L10N.register( "by" : "மூலம்", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "நீங்கள் <strong>%s</strong> இலுள்ள <strong>%s</strong>பயன்படுத்தியுள்ளீர்கள்", "Password" : "கடவுச்சொல்", - "Your password was changed" : "உங்களுடைய கடவுச்சொல் மாற்றப்பட்டுள்ளது", "Unable to change your password" : "உங்களுடைய கடவுச்சொல்லை மாற்றமுடியாது", "Current password" : "தற்போதைய கடவுச்சொல்", "New password" : "புதிய கடவுச்சொல்", diff --git a/settings/l10n/ta_LK.json b/settings/l10n/ta_LK.json index 8e13b58deae..0b51a0c4a94 100644 --- a/settings/l10n/ta_LK.json +++ b/settings/l10n/ta_LK.json @@ -26,7 +26,6 @@ "by" : "மூலம்", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "நீங்கள் <strong>%s</strong> இலுள்ள <strong>%s</strong>பயன்படுத்தியுள்ளீர்கள்", "Password" : "கடவுச்சொல்", - "Your password was changed" : "உங்களுடைய கடவுச்சொல் மாற்றப்பட்டுள்ளது", "Unable to change your password" : "உங்களுடைய கடவுச்சொல்லை மாற்றமுடியாது", "Current password" : "தற்போதைய கடவுச்சொல்", "New password" : "புதிய கடவுச்சொல்", diff --git a/settings/l10n/th_TH.js b/settings/l10n/th_TH.js index 95023aa083c..11b67dfeb89 100644 --- a/settings/l10n/th_TH.js +++ b/settings/l10n/th_TH.js @@ -50,7 +50,6 @@ OC.L10N.register( "Show First Run Wizard again" : "แสดงหน้าจอวิซาร์ดนำทางครั้งแรกอีกครั้ง", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "คุณได้ใช้งานไปแล้ว <strong>%s</strong> จากจำนวนที่สามารถใช้ได้ <strong>%s</strong>", "Password" : "รหัสผ่าน", - "Your password was changed" : "รหัสผ่านของคุณถูกเปลี่ยนแล้ว", "Unable to change your password" : "ไม่สามารถเปลี่ยนรหัสผ่านของคุณได้", "Current password" : "รหัสผ่านปัจจุบัน", "New password" : "รหัสผ่านใหม่", diff --git a/settings/l10n/th_TH.json b/settings/l10n/th_TH.json index 6141d0f9507..611c4689b9f 100644 --- a/settings/l10n/th_TH.json +++ b/settings/l10n/th_TH.json @@ -48,7 +48,6 @@ "Show First Run Wizard again" : "แสดงหน้าจอวิซาร์ดนำทางครั้งแรกอีกครั้ง", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "คุณได้ใช้งานไปแล้ว <strong>%s</strong> จากจำนวนที่สามารถใช้ได้ <strong>%s</strong>", "Password" : "รหัสผ่าน", - "Your password was changed" : "รหัสผ่านของคุณถูกเปลี่ยนแล้ว", "Unable to change your password" : "ไม่สามารถเปลี่ยนรหัสผ่านของคุณได้", "Current password" : "รหัสผ่านปัจจุบัน", "New password" : "รหัสผ่านใหม่", diff --git a/settings/l10n/tr.js b/settings/l10n/tr.js index cc0ef42460d..49621f79ec9 100644 --- a/settings/l10n/tr.js +++ b/settings/l10n/tr.js @@ -207,7 +207,6 @@ OC.L10N.register( "Show First Run Wizard again" : "İlk Çalıştırma Sihirbazı'nı yeniden göster", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Kullandığınız: <strong>%s</strong>. Kullanılabilir alan: <strong>%s</strong>", "Password" : "Parola", - "Your password was changed" : "Parolanız değiştirildi", "Unable to change your password" : "Parolanız değiştirilemiyor", "Current password" : "Mevcut parola", "New password" : "Yeni parola", diff --git a/settings/l10n/tr.json b/settings/l10n/tr.json index 61e72fcd73d..35919cc6e63 100644 --- a/settings/l10n/tr.json +++ b/settings/l10n/tr.json @@ -205,7 +205,6 @@ "Show First Run Wizard again" : "İlk Çalıştırma Sihirbazı'nı yeniden göster", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Kullandığınız: <strong>%s</strong>. Kullanılabilir alan: <strong>%s</strong>", "Password" : "Parola", - "Your password was changed" : "Parolanız değiştirildi", "Unable to change your password" : "Parolanız değiştirilemiyor", "Current password" : "Mevcut parola", "New password" : "Yeni parola", diff --git a/settings/l10n/ug.js b/settings/l10n/ug.js index 9affc7e8372..762bf0f0668 100644 --- a/settings/l10n/ug.js +++ b/settings/l10n/ug.js @@ -46,7 +46,6 @@ OC.L10N.register( "Online Documentation" : "توردىكى قوللانما", "Forum" : "مۇنبەر", "Password" : "ئىم", - "Your password was changed" : "ئىمىڭىز مۇۋەپپەقىيەتلىك ئۆزگەرتىلدى", "Unable to change your password" : "ئىمنى ئۆزگەرتكىلى بولمايدۇ.", "Current password" : "نۆۋەتتىكى ئىم", "New password" : "يېڭى ئىم", diff --git a/settings/l10n/ug.json b/settings/l10n/ug.json index 869d599f9d1..08022fb03f7 100644 --- a/settings/l10n/ug.json +++ b/settings/l10n/ug.json @@ -44,7 +44,6 @@ "Online Documentation" : "توردىكى قوللانما", "Forum" : "مۇنبەر", "Password" : "ئىم", - "Your password was changed" : "ئىمىڭىز مۇۋەپپەقىيەتلىك ئۆزگەرتىلدى", "Unable to change your password" : "ئىمنى ئۆزگەرتكىلى بولمايدۇ.", "Current password" : "نۆۋەتتىكى ئىم", "New password" : "يېڭى ئىم", diff --git a/settings/l10n/uk.js b/settings/l10n/uk.js index 95e2061b2eb..efc66181123 100644 --- a/settings/l10n/uk.js +++ b/settings/l10n/uk.js @@ -196,7 +196,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Показувати Майстер Налаштувань знову", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ви використали <strong>%s</strong> із доступних <strong>%s</strong>", "Password" : "Пароль", - "Your password was changed" : "Ваш пароль змінено", "Unable to change your password" : "Не вдалося змінити Ваш пароль", "Current password" : "Поточний пароль", "New password" : "Новий пароль", diff --git a/settings/l10n/uk.json b/settings/l10n/uk.json index 12d6f84ec63..8e73947d236 100644 --- a/settings/l10n/uk.json +++ b/settings/l10n/uk.json @@ -194,7 +194,6 @@ "Show First Run Wizard again" : "Показувати Майстер Налаштувань знову", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Ви використали <strong>%s</strong> із доступних <strong>%s</strong>", "Password" : "Пароль", - "Your password was changed" : "Ваш пароль змінено", "Unable to change your password" : "Не вдалося змінити Ваш пароль", "Current password" : "Поточний пароль", "New password" : "Новий пароль", diff --git a/settings/l10n/vi.js b/settings/l10n/vi.js index 4a1fe013e64..f709bbfde5c 100644 --- a/settings/l10n/vi.js +++ b/settings/l10n/vi.js @@ -54,7 +54,6 @@ OC.L10N.register( "Show First Run Wizard again" : "Hiện lại việc chạy đồ thuật khởi đầu", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Bạn đã sử dụng <strong>%s </ strong> có sẵn <strong> %s </ strong>", "Password" : "Mật khẩu", - "Your password was changed" : "Mật khẩu của bạn đã được thay đổi.", "Unable to change your password" : "Không thể đổi mật khẩu", "Current password" : "Mật khẩu cũ", "New password" : "Mật khẩu mới", diff --git a/settings/l10n/vi.json b/settings/l10n/vi.json index 7d883c9cfc8..7d49ccab801 100644 --- a/settings/l10n/vi.json +++ b/settings/l10n/vi.json @@ -52,7 +52,6 @@ "Show First Run Wizard again" : "Hiện lại việc chạy đồ thuật khởi đầu", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "Bạn đã sử dụng <strong>%s </ strong> có sẵn <strong> %s </ strong>", "Password" : "Mật khẩu", - "Your password was changed" : "Mật khẩu của bạn đã được thay đổi.", "Unable to change your password" : "Không thể đổi mật khẩu", "Current password" : "Mật khẩu cũ", "New password" : "Mật khẩu mới", diff --git a/settings/l10n/zh_CN.js b/settings/l10n/zh_CN.js index 9b91fd3cae9..0b8a5fcc9d9 100644 --- a/settings/l10n/zh_CN.js +++ b/settings/l10n/zh_CN.js @@ -159,7 +159,6 @@ OC.L10N.register( "Show First Run Wizard again" : "再次显示首次运行向导", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "你已使用 <strong>%s</strong>,有效空间 <strong>%s</strong>", "Password" : "密码", - "Your password was changed" : "密码已修改", "Unable to change your password" : "无法修改密码", "Current password" : "当前密码", "New password" : "新密码", diff --git a/settings/l10n/zh_CN.json b/settings/l10n/zh_CN.json index 4fddc4e3514..a10cf172c5a 100644 --- a/settings/l10n/zh_CN.json +++ b/settings/l10n/zh_CN.json @@ -157,7 +157,6 @@ "Show First Run Wizard again" : "再次显示首次运行向导", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "你已使用 <strong>%s</strong>,有效空间 <strong>%s</strong>", "Password" : "密码", - "Your password was changed" : "密码已修改", "Unable to change your password" : "无法修改密码", "Current password" : "当前密码", "New password" : "新密码", diff --git a/settings/l10n/zh_TW.js b/settings/l10n/zh_TW.js index e4f39a273b8..26c7845186f 100644 --- a/settings/l10n/zh_TW.js +++ b/settings/l10n/zh_TW.js @@ -129,7 +129,6 @@ OC.L10N.register( "Show First Run Wizard again" : "再次顯示首次使用精靈", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "您已經使用了 <strong>%s</strong> ,目前可用空間為 <strong>%s</strong>", "Password" : "密碼", - "Your password was changed" : "你的密碼已更改", "Unable to change your password" : "無法變更您的密碼", "Current password" : "目前密碼", "New password" : "新密碼", diff --git a/settings/l10n/zh_TW.json b/settings/l10n/zh_TW.json index ac0efa8f086..0daf6e52612 100644 --- a/settings/l10n/zh_TW.json +++ b/settings/l10n/zh_TW.json @@ -127,7 +127,6 @@ "Show First Run Wizard again" : "再次顯示首次使用精靈", "You have used <strong>%s</strong> of the available <strong>%s</strong>" : "您已經使用了 <strong>%s</strong> ,目前可用空間為 <strong>%s</strong>", "Password" : "密碼", - "Your password was changed" : "你的密碼已更改", "Unable to change your password" : "無法變更您的密碼", "Current password" : "目前密碼", "New password" : "新密碼", diff --git a/tests/lib/activitymanager.php b/tests/lib/activitymanager.php index 6a5af7b259b..d227c05d827 100644 --- a/tests/lib/activitymanager.php +++ b/tests/lib/activitymanager.php @@ -31,16 +31,6 @@ class Test_ActivityManager extends \Test\TestCase { $this->assertEquals(2, sizeof($result)); } - public function testFilterNotificationTypes() { - $result = $this->activityManager->filterNotificationTypes(array('NT0', 'NT1', 'NT2', 'NT3'), 'FILTER1'); - $this->assertTrue(is_array($result)); - $this->assertEquals(3, sizeof($result)); - - $result = $this->activityManager->filterNotificationTypes(array('NT0', 'NT1', 'NT2', 'NT3'), 'FILTER2'); - $this->assertTrue(is_array($result)); - $this->assertEquals(4, sizeof($result)); - } - public function testDefaultTypes() { $result = $this->activityManager->getDefaultTypes('stream'); $this->assertTrue(is_array($result)); @@ -51,6 +41,14 @@ class Test_ActivityManager extends \Test\TestCase { $this->assertEquals(0, sizeof($result)); } + public function testTypeIcon() { + $result = $this->activityManager->getTypeIcon('NT1'); + $this->assertEquals('icon-nt-one', $result); + + $result = $this->activityManager->getTypeIcon('NT2'); + $this->assertEquals('', $result); + } + public function testTranslate() { $result = $this->activityManager->translate('APP0', '', '', array(), false, false, 'en'); $this->assertEquals('Stupid translation', $result); @@ -67,14 +65,6 @@ class Test_ActivityManager extends \Test\TestCase { $this->assertFalse($result); } - public function testTypeIcon() { - $result = $this->activityManager->getTypeIcon('NT1'); - $this->assertEquals('icon-nt-one', $result); - - $result = $this->activityManager->getTypeIcon('NT2'); - $this->assertEquals('', $result); - } - public function testGroupParameter() { $result = $this->activityManager->getGroupParameter(array()); $this->assertEquals(5, $result); @@ -90,15 +80,27 @@ class Test_ActivityManager extends \Test\TestCase { $result = $this->activityManager->isFilterValid('fv01'); $this->assertTrue($result); - $result = $this->activityManager->isFilterValid('FV2'); + $result = $this->activityManager->isFilterValid('InvalidFilter'); $this->assertFalse($result); } + public function testFilterNotificationTypes() { + $result = $this->activityManager->filterNotificationTypes(array('NT0', 'NT1', 'NT2', 'NT3'), 'fv01'); + $this->assertTrue(is_array($result)); + $this->assertEquals(3, sizeof($result)); + + $result = $this->activityManager->filterNotificationTypes(array('NT0', 'NT1', 'NT2', 'NT3'), 'InvalidFilter'); + $this->assertTrue(is_array($result)); + $this->assertEquals(4, sizeof($result)); + } + public function testQueryForFilter() { + // Register twice, to test the created sql part $this->activityManager->registerExtension(function() { return new SimpleExtension(); }); - $result = $this->activityManager->getQueryForFilter('filter1'); + + $result = $this->activityManager->getQueryForFilter('fv01'); $this->assertEquals( array( ' and ((`app` = ? and `message` like ?) or (`app` = ? and `message` like ?))', @@ -106,8 +108,8 @@ class Test_ActivityManager extends \Test\TestCase { ), $result ); - $result = $this->activityManager->isFilterValid('filter2'); - $this->assertFalse($result); + $result = $this->activityManager->getQueryForFilter('InvalidFilter'); + $this->assertEquals(array(null, null), $result); } } @@ -117,13 +119,6 @@ class SimpleExtension implements \OCP\Activity\IExtension { return array('NT1', 'NT2'); } - public function filterNotificationTypes($types, $filter) { - if ($filter === 'FILTER1') { - unset($types[0]); - } - return $types; - } - public function getDefaultTypes($method) { if ($method === 'stream') { return array('DT0'); @@ -132,6 +127,13 @@ class SimpleExtension implements \OCP\Activity\IExtension { return array(); } + public function getTypeIcon($type) { + if ($type === 'NT1') { + return 'icon-nt-one'; + } + return ''; + } + public function translate($app, $text, $params, $stripPath, $highlightParams, $languageCode) { if ($app === 'APP0') { return "Stupid translation"; @@ -148,13 +150,6 @@ class SimpleExtension implements \OCP\Activity\IExtension { return false; } - public function getTypeIcon($type) { - if ($type === 'NT1') { - return 'icon-nt-one'; - } - return ''; - } - public function getGroupParameter($activity) { return 5; } @@ -174,8 +169,15 @@ class SimpleExtension implements \OCP\Activity\IExtension { return false; } + public function filterNotificationTypes($types, $filter) { + if ($filter === 'fv01') { + unset($types[0]); + } + return $types; + } + public function getQueryForFilter($filter) { - if ($filter === 'filter1') { + if ($filter === 'fv01') { return array('`app` = ? and `message` like ?', array('mail', 'ownCloud%')); } @@ -189,11 +191,11 @@ class NoOpExtension implements \OCP\Activity\IExtension { return false; } - public function filterNotificationTypes($types, $filter) { + public function getDefaultTypes($method) { return false; } - public function getDefaultTypes($method) { + public function getTypeIcon($type) { return false; } @@ -205,10 +207,6 @@ class NoOpExtension implements \OCP\Activity\IExtension { return false; } - public function getTypeIcon($type) { - return false; - } - public function getGroupParameter($activity) { return false; } @@ -221,6 +219,10 @@ class NoOpExtension implements \OCP\Activity\IExtension { return false; } + public function filterNotificationTypes($types, $filter) { + return false; + } + public function getQueryForFilter($filter) { return false; } diff --git a/tests/lib/appframework/http/RequestTest.php b/tests/lib/appframework/http/RequestTest.php index 3185a0093c4..282d13a3397 100644 --- a/tests/lib/appframework/http/RequestTest.php +++ b/tests/lib/appframework/http/RequestTest.php @@ -593,6 +593,27 @@ class RequestTest extends \Test\TestCase { $this->assertSame('http', $request->getServerProtocol()); } + public function testGetServerProtocolBehindLoadBalancers() { + $this->config + ->expects($this->once()) + ->method('getSystemValue') + ->with('overwriteprotocol') + ->will($this->returnValue('')); + + $request = new Request( + [ + 'server' => [ + 'HTTP_X_FORWARDED_PROTO' => 'https,http,http' + ], + ], + $this->secureRandom, + $this->config, + $this->stream + ); + + $this->assertSame('https', $request->getServerProtocol()); + } + /** * @dataProvider userAgentProvider * @param string $testAgent diff --git a/tests/lib/connector/sabre/custompropertiesbackend.php b/tests/lib/connector/sabre/custompropertiesbackend.php new file mode 100644 index 00000000000..ee0c3c4e53d --- /dev/null +++ b/tests/lib/connector/sabre/custompropertiesbackend.php @@ -0,0 +1,248 @@ +<?php + +namespace Tests\Connector\Sabre; + +/** + * 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. + */ +class CustomPropertiesBackend extends \Test\TestCase { + + /** + * @var \Sabre\DAV\Server + */ + private $server; + + /** + * @var \Sabre\DAV\ObjectTree + */ + private $tree; + + /** + * @var \OC\Connector\Sabre\CustomPropertiesBackend + */ + private $plugin; + + /** + * @var \OCP\IUser + */ + private $user; + + public function setUp() { + parent::setUp(); + $this->server = new \Sabre\DAV\Server(); + $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') + ->disableOriginalConstructor() + ->getMock(); + + $userId = $this->getUniqueID('testcustompropertiesuser'); + + $this->user = $this->getMock('\OCP\IUser'); + $this->user->expects($this->any()) + ->method('getUID') + ->will($this->returnValue($userId)); + + $this->plugin = new \OC\Connector\Sabre\CustomPropertiesBackend( + $this->tree, + \OC::$server->getDatabaseConnection(), + $this->user + ); + } + + public function tearDown() { + $connection = \OC::$server->getDatabaseConnection(); + $deleteStatement = $connection->prepare( + 'DELETE FROM `*PREFIX*properties`' . + ' WHERE `userid` = ?' + ); + $deleteStatement->execute( + array( + $this->user->getUID(), + ) + ); + $deleteStatement->closeCursor(); + } + + private function createTestNode($class) { + $node = $this->getMockBuilder($class) + ->disableOriginalConstructor() + ->getMock(); + $node->expects($this->any()) + ->method('getId') + ->will($this->returnValue(123)); + + $node->expects($this->any()) + ->method('getPath') + ->will($this->returnValue('/dummypath')); + + return $node; + } + + private function applyDefaultProps($path = '/dummypath') { + // properties to set + $propPatch = new \Sabre\DAV\PropPatch(array( + 'customprop' => 'value1', + 'customprop2' => 'value2', + )); + + $this->plugin->propPatch( + $path, + $propPatch + ); + + $propPatch->commit(); + + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertEquals(200, $result['customprop']); + $this->assertEquals(200, $result['customprop2']); + } + + /** + * Test setting/getting properties + */ + public function testSetGetPropertiesForFile() { + $node = $this->createTestNode('\OC\Connector\Sabre\File'); + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + + $this->applyDefaultProps(); + + $propFind = new \Sabre\DAV\PropFind( + '/dummypath', + array( + 'customprop', + 'customprop2', + 'unsetprop', + ), + 0 + ); + + $this->plugin->propFind( + '/dummypath', + $propFind + ); + + $this->assertEquals('value1', $propFind->get('customprop')); + $this->assertEquals('value2', $propFind->get('customprop2')); + $this->assertEquals(array('unsetprop'), $propFind->get404Properties()); + } + + /** + * Test getting properties from directory + */ + public function testGetPropertiesForDirectory() { + $rootNode = $this->createTestNode('\OC\Connector\Sabre\Directory'); + + $nodeSub = $this->getMockBuilder('\OC\Connector\Sabre\File') + ->disableOriginalConstructor() + ->getMock(); + $nodeSub->expects($this->any()) + ->method('getId') + ->will($this->returnValue(456)); + + $nodeSub->expects($this->any()) + ->method('getPath') + ->will($this->returnValue('/dummypath/test.txt')); + + $rootNode->expects($this->once()) + ->method('getChildren') + ->will($this->returnValue(array($nodeSub))); + + $this->tree->expects($this->at(0)) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($rootNode)); + + $this->tree->expects($this->at(1)) + ->method('getNodeForPath') + ->with('/dummypath/test.txt') + ->will($this->returnValue($nodeSub)); + + $this->tree->expects($this->at(2)) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($rootNode)); + + $this->tree->expects($this->at(3)) + ->method('getNodeForPath') + ->with('/dummypath/test.txt') + ->will($this->returnValue($nodeSub)); + + $this->applyDefaultProps('/dummypath'); + $this->applyDefaultProps('/dummypath/test.txt'); + + $propNames = array( + 'customprop', + 'customprop2', + 'unsetprop', + ); + + $propFindRoot = new \Sabre\DAV\PropFind( + '/dummypath', + $propNames, + 1 + ); + + $propFindSub = new \Sabre\DAV\PropFind( + '/dummypath/test.txt', + $propNames, + 0 + ); + + $this->plugin->propFind( + '/dummypath', + $propFindRoot + ); + + $this->plugin->propFind( + '/dummypath/test.txt', + $propFindSub + ); + + // TODO: find a way to assert that no additional SQL queries were + // run while doing the second propFind + + $this->assertEquals('value1', $propFindRoot->get('customprop')); + $this->assertEquals('value2', $propFindRoot->get('customprop2')); + $this->assertEquals(array('unsetprop'), $propFindRoot->get404Properties()); + + $this->assertEquals('value1', $propFindSub->get('customprop')); + $this->assertEquals('value2', $propFindSub->get('customprop2')); + $this->assertEquals(array('unsetprop'), $propFindSub->get404Properties()); + } + + /** + * Test delete property + */ + public function testDeleteProperty() { + $node = $this->createTestNode('\OC\Connector\Sabre\File'); + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + + $this->applyDefaultProps(); + + $propPatch = new \Sabre\DAV\PropPatch(array( + 'customprop' => null, + )); + + $this->plugin->propPatch( + '/dummypath', + $propPatch + ); + + $propPatch->commit(); + + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertEquals(204, $result['customprop']); + } +} diff --git a/tests/lib/connector/sabre/directory.php b/tests/lib/connector/sabre/directory.php index 599a6ca3f7c..e7fbd1d27b6 100644 --- a/tests/lib/connector/sabre/directory.php +++ b/tests/lib/connector/sabre/directory.php @@ -27,7 +27,7 @@ class Test_OC_Connector_Sabre_Directory extends \Test\TestCase { ->method('getPath') ->will($this->returnValue('')); - return new OC_Connector_Sabre_Directory($this->view, $this->info); + return new \OC\Connector\Sabre\Directory($this->view, $this->info); } /** @@ -131,7 +131,7 @@ class Test_OC_Connector_Sabre_Directory extends \Test\TestCase { ->method('getRelativePath') ->will($this->returnValue('')); - $dir = new OC_Connector_Sabre_Directory($this->view, $this->info); + $dir = new \OC\Connector\Sabre\Directory($this->view, $this->info); $nodes = $dir->getChildren(); $this->assertEquals(2, count($nodes)); @@ -139,21 +139,6 @@ class Test_OC_Connector_Sabre_Directory extends \Test\TestCase { // calling a second time just returns the cached values, // does not call getDirectoryContents again $nodes = $dir->getChildren(); - - $properties = array('testprop', OC_Connector_Sabre_Node::GETETAG_PROPERTYNAME); - $this->assertEquals(2, count($nodes)); - $this->assertEquals( - array( - OC_Connector_Sabre_Node::GETETAG_PROPERTYNAME => '"abc"' - ), - $nodes[0]->getProperties($properties) - ); - $this->assertEquals( - array( - OC_Connector_Sabre_Node::GETETAG_PROPERTYNAME => '"def"' - ), - $nodes[1]->getProperties($properties) - ); } public function testGetQuotaInfo() { @@ -182,7 +167,7 @@ class Test_OC_Connector_Sabre_Directory extends \Test\TestCase { ->method('getStorage') ->will($this->returnValue($storage)); - $dir = new OC_Connector_Sabre_Directory($this->view, $this->info); + $dir = new \OC\Connector\Sabre\Directory($this->view, $this->info); $this->assertEquals([200, 800], $dir->getQuotaInfo()); //200 used, 800 free } } diff --git a/tests/lib/connector/sabre/file.php b/tests/lib/connector/sabre/file.php index 33dc78f87d8..2ef5fd794be 100644 --- a/tests/lib/connector/sabre/file.php +++ b/tests/lib/connector/sabre/file.php @@ -26,7 +26,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions'=>\OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->put('test data'); @@ -52,7 +52,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); $this->assertNotEmpty($file->put('test data')); } @@ -86,7 +86,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->put('test data'); @@ -109,7 +109,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { $info = new \OC\Files\FileInfo('/super*star.txt', null, null, array( 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->put('test data'); @@ -130,7 +130,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { $info = new \OC\Files\FileInfo('/super*star.txt', null, null, array( 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); $file->setName('/super*star.txt'); } @@ -163,7 +163,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->put('test data'); @@ -185,7 +185,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->delete(); @@ -203,7 +203,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => 0 ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->delete(); @@ -226,7 +226,7 @@ class Test_OC_Connector_Sabre_File extends \Test\TestCase { 'permissions' => \OCP\Constants::PERMISSION_ALL ), null); - $file = new OC_Connector_Sabre_File($view, $info); + $file = new \OC\Connector\Sabre\File($view, $info); // action $file->delete(); diff --git a/tests/lib/connector/sabre/filesplugin.php b/tests/lib/connector/sabre/filesplugin.php new file mode 100644 index 00000000000..54d43d66dda --- /dev/null +++ b/tests/lib/connector/sabre/filesplugin.php @@ -0,0 +1,174 @@ +<?php + +namespace Tests\Connector\Sabre; + +/** + * 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. + */ +class FilesPlugin extends \Test\TestCase { + const GETETAG_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::GETETAG_PROPERTYNAME; + const FILEID_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::FILEID_PROPERTYNAME; + const SIZE_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::SIZE_PROPERTYNAME; + const PERMISSIONS_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::PERMISSIONS_PROPERTYNAME; + const GETLASTMODIFIED_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::GETLASTMODIFIED_PROPERTYNAME; + const DOWNLOADURL_PROPERTYNAME = \OC\Connector\Sabre\FilesPlugin::DOWNLOADURL_PROPERTYNAME; + + /** + * @var \Sabre\DAV\Server + */ + private $server; + + /** + * @var \Sabre\DAV\ObjectTree + */ + private $tree; + + /** + * @var \OC\Connector\Sabre\FilesPlugin + */ + private $plugin; + + public function setUp() { + parent::setUp(); + $this->server = new \Sabre\DAV\Server(); + $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') + ->disableOriginalConstructor() + ->getMock(); + $this->plugin = new \OC\Connector\Sabre\FilesPlugin($this->tree); + $this->plugin->initialize($this->server); + } + + private function createTestNode($class) { + $node = $this->getMockBuilder($class) + ->disableOriginalConstructor() + ->getMock(); + $node->expects($this->any()) + ->method('getId') + ->will($this->returnValue(123)); + + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + + $node->expects($this->any()) + ->method('getFileId') + ->will($this->returnValue(123)); + $node->expects($this->any()) + ->method('getEtag') + ->will($this->returnValue('"abc"')); + $node->expects($this->any()) + ->method('getDavPermissions') + ->will($this->returnValue('R')); + + return $node; + } + + /** + */ + public function testGetPropertiesForFile() { + $node = $this->createTestNode('\OC\Connector\Sabre\File'); + + $propFind = new \Sabre\DAV\PropFind( + '/dummyPath', + array( + self::GETETAG_PROPERTYNAME, + self::FILEID_PROPERTYNAME, + self::SIZE_PROPERTYNAME, + self::PERMISSIONS_PROPERTYNAME, + self::DOWNLOADURL_PROPERTYNAME, + ), + 0 + ); + + $node->expects($this->once()) + ->method('getDirectDownload') + ->will($this->returnValue(array('url' => 'http://example.com/'))); + $node->expects($this->never()) + ->method('getSize'); + + $this->plugin->handleGetProperties( + $propFind, + $node + ); + + $this->assertEquals('"abc"', $propFind->get(self::GETETAG_PROPERTYNAME)); + $this->assertEquals(123, $propFind->get(self::FILEID_PROPERTYNAME)); + $this->assertEquals(null, $propFind->get(self::SIZE_PROPERTYNAME)); + $this->assertEquals('R', $propFind->get(self::PERMISSIONS_PROPERTYNAME)); + $this->assertEquals('http://example.com/', $propFind->get(self::DOWNLOADURL_PROPERTYNAME)); + $this->assertEquals(array(self::SIZE_PROPERTYNAME), $propFind->get404Properties()); + } + + public function testGetPropertiesForDirectory() { + $node = $this->createTestNode('\OC\Connector\Sabre\Directory'); + + $propFind = new \Sabre\DAV\PropFind( + '/dummyPath', + array( + self::GETETAG_PROPERTYNAME, + self::FILEID_PROPERTYNAME, + self::SIZE_PROPERTYNAME, + self::PERMISSIONS_PROPERTYNAME, + self::DOWNLOADURL_PROPERTYNAME, + ), + 0 + ); + + $node->expects($this->never()) + ->method('getDirectDownload'); + $node->expects($this->once()) + ->method('getSize') + ->will($this->returnValue(1025)); + + $this->plugin->handleGetProperties( + $propFind, + $node + ); + + $this->assertEquals('"abc"', $propFind->get(self::GETETAG_PROPERTYNAME)); + $this->assertEquals(123, $propFind->get(self::FILEID_PROPERTYNAME)); + $this->assertEquals(1025, $propFind->get(self::SIZE_PROPERTYNAME)); + $this->assertEquals('R', $propFind->get(self::PERMISSIONS_PROPERTYNAME)); + $this->assertEquals(null, $propFind->get(self::DOWNLOADURL_PROPERTYNAME)); + $this->assertEquals(array(self::DOWNLOADURL_PROPERTYNAME), $propFind->get404Properties()); + } + + public function testUpdateProps() { + $node = $this->createTestNode('\OC\Connector\Sabre\File'); + + $testDate = 'Fri, 13 Feb 2015 00:01:02 GMT'; + + $node->expects($this->once()) + ->method('touch') + ->with($testDate); + + $node->expects($this->once()) + ->method('setEtag') + ->with('newetag') + ->will($this->returnValue(true)); + + // properties to set + $propPatch = new \Sabre\DAV\PropPatch(array( + self::GETETAG_PROPERTYNAME => 'newetag', + self::GETLASTMODIFIED_PROPERTYNAME => $testDate + )); + + $this->plugin->handleUpdateProperties( + '/dummypath', + $propPatch + ); + + $propPatch->commit(); + + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertEquals(200, $result[self::GETLASTMODIFIED_PROPERTYNAME]); + $this->assertEquals(200, $result[self::GETETAG_PROPERTYNAME]); + } + +} diff --git a/tests/lib/connector/sabre/node.php b/tests/lib/connector/sabre/node.php index 1e927deed44..e1ae05b2170 100644 --- a/tests/lib/connector/sabre/node.php +++ b/tests/lib/connector/sabre/node.php @@ -49,7 +49,7 @@ class Node extends \Test\TestCase { ->will($this->returnValue($type)); $view = $this->getMock('\OC\Files\View'); - $node = new \OC_Connector_Sabre_File($view, $info); + $node = new \OC\Connector\Sabre\File($view, $info); $this->assertEquals($expected, $node->getDavPermissions()); } } diff --git a/tests/lib/connector/sabre/objecttree.php b/tests/lib/connector/sabre/objecttree.php index 2548066214b..3c972fe6f0f 100644 --- a/tests/lib/connector/sabre/objecttree.php +++ b/tests/lib/connector/sabre/objecttree.php @@ -10,7 +10,7 @@ namespace Test\OC\Connector\Sabre; use OC\Files\FileInfo; -use OC_Connector_Sabre_Directory; +use OC\Connector\Sabre\Directory; use PHPUnit_Framework_TestCase; class TestDoubleFileView extends \OC\Files\View { @@ -103,7 +103,7 @@ class ObjectTree extends \Test\TestCase { $info = new FileInfo('', null, null, array(), null); - $rootDir = new OC_Connector_Sabre_Directory($view, $info); + $rootDir = new Directory($view, $info); $objectTree = $this->getMock('\OC\Connector\Sabre\ObjectTree', array('nodeExists', 'getNodeForPath'), array($rootDir, $view)); @@ -119,4 +119,123 @@ class ObjectTree extends \Test\TestCase { $objectTree->move($source, $dest); } + /** + * @dataProvider nodeForPathProvider + */ + public function testGetNodeForPath( + $inputFileName, + $fileInfoQueryPath, + $outputFileName, + $type, + $enableChunkingHeader + ) { + + if ($enableChunkingHeader) { + $_SERVER['HTTP_OC_CHUNKED'] = true; + } + + $rootNode = $this->getMockBuilder('\OC\Connector\Sabre\Directory') + ->disableOriginalConstructor() + ->getMock(); + $mountManager = $this->getMock('\OC\Files\Mount\Manager'); + $view = $this->getMock('\OC\Files\View'); + $fileInfo = $this->getMock('\OCP\Files\FileInfo'); + $fileInfo->expects($this->once()) + ->method('getType') + ->will($this->returnValue($type)); + $fileInfo->expects($this->once()) + ->method('getName') + ->will($this->returnValue($outputFileName)); + + $view->expects($this->once()) + ->method('getFileInfo') + ->with($fileInfoQueryPath) + ->will($this->returnValue($fileInfo)); + + $tree = new \OC\Connector\Sabre\ObjectTree(); + $tree->init($rootNode, $view, $mountManager); + + $node = $tree->getNodeForPath($inputFileName); + + $this->assertNotNull($node); + $this->assertEquals($outputFileName, $node->getName()); + + if ($type === 'file') { + $this->assertTrue($node instanceof \OC\Connector\Sabre\File); + } else { + $this->assertTrue($node instanceof \OC\Connector\Sabre\Directory); + } + + unset($_SERVER['HTTP_OC_CHUNKED']); + } + + function nodeForPathProvider() { + return array( + // regular file + array( + 'regularfile.txt', + 'regularfile.txt', + 'regularfile.txt', + 'file', + false + ), + // regular directory + array( + 'regulardir', + 'regulardir', + 'regulardir', + 'dir', + false + ), + // regular file with chunking + array( + 'regularfile.txt', + 'regularfile.txt', + 'regularfile.txt', + 'file', + true + ), + // regular directory with chunking + array( + 'regulardir', + 'regulardir', + 'regulardir', + 'dir', + true + ), + // file with chunky file name + array( + 'regularfile.txt-chunking-123566789-10-1', + 'regularfile.txt', + 'regularfile.txt', + 'file', + true + ), + // regular file in subdir + array( + 'subdir/regularfile.txt', + 'subdir/regularfile.txt', + 'regularfile.txt', + 'file', + false + ), + // regular directory in subdir + array( + 'subdir/regulardir', + 'subdir/regulardir', + 'regulardir', + 'dir', + false + ), + // file with chunky file name in subdir + array( + 'subdir/regularfile.txt-chunking-123566789-10-1', + 'subdir/regularfile.txt', + 'regularfile.txt', + 'file', + true + ), + ); + } + } diff --git a/tests/lib/connector/sabre/principal.php b/tests/lib/connector/sabre/principal.php index 5d13aa4421e..1841a79bec7 100644 --- a/tests/lib/connector/sabre/principal.php +++ b/tests/lib/connector/sabre/principal.php @@ -10,6 +10,7 @@ namespace Test\Connector\Sabre; +use \Sabre\DAV\PropPatch; use OCP\IUserManager; use OCP\IConfig; @@ -240,7 +241,7 @@ class Principal extends \Test\TestCase { } public function testUpdatePrincipal() { - $this->assertSame(0, $this->connector->updatePrincipal('foo', [])); + $this->assertSame(0, $this->connector->updatePrincipal('foo', new PropPatch(array()))); } public function testSearchPrincipals() { diff --git a/tests/lib/connector/sabre/quotaplugin.php b/tests/lib/connector/sabre/quotaplugin.php index f08637854ce..48f8f319ae4 100644 --- a/tests/lib/connector/sabre/quotaplugin.php +++ b/tests/lib/connector/sabre/quotaplugin.php @@ -14,14 +14,14 @@ class Test_OC_Connector_Sabre_QuotaPlugin extends \Test\TestCase { private $server; /** - * @var OC_Connector_Sabre_QuotaPlugin + * @var \OC\Connector\Sabre\QuotaPlugin */ private $plugin; private function init($quota) { $view = $this->buildFileViewMock($quota); $this->server = new \Sabre\DAV\Server(); - $this->plugin = new OC_Connector_Sabre_QuotaPlugin($view); + $this->plugin = new \OC\Connector\Sabre\QuotaPlugin($view); $this->plugin->initialize($this->server); } @@ -30,7 +30,7 @@ class Test_OC_Connector_Sabre_QuotaPlugin extends \Test\TestCase { */ public function testLength($expected, $headers) { $this->init(0); - $this->server->httpRequest = new \Sabre\HTTP\Request($headers); + $this->server->httpRequest = new \Sabre\HTTP\Request(null, null, $headers); $length = $this->plugin->getLength(); $this->assertEquals($expected, $length); } @@ -41,7 +41,7 @@ class Test_OC_Connector_Sabre_QuotaPlugin extends \Test\TestCase { public function testCheckQuota($quota, $headers) { $this->init($quota); - $this->server->httpRequest = new Sabre\HTTP\Request($headers); + $this->server->httpRequest = new \Sabre\HTTP\Request(null, null, $headers); $result = $this->plugin->checkQuota(''); $this->assertTrue($result); } @@ -53,39 +53,39 @@ class Test_OC_Connector_Sabre_QuotaPlugin extends \Test\TestCase { public function testCheckExceededQuota($quota, $headers) { $this->init($quota); - $this->server->httpRequest = new Sabre\HTTP\Request($headers); + $this->server->httpRequest = new \Sabre\HTTP\Request(null, null, $headers); $this->plugin->checkQuota(''); } public function quotaOkayProvider() { return array( array(1024, array()), - array(1024, array('HTTP_X_EXPECTED_ENTITY_LENGTH' => '1024')), - array(1024, array('HTTP_CONTENT_LENGTH' => '512')), - array(1024, array('HTTP_OC_TOTAL_LENGTH' => '1024', 'HTTP_CONTENT_LENGTH' => '512')), - // \OCP\Files\FileInfo::SPACE_UNKNOWN = -2 + array(1024, array('X-EXPECTED-ENTITY-LENGTH' => '1024')), + array(1024, array('CONTENT-LENGTH' => '512')), + array(1024, array('OC-TOTAL-LENGTH' => '1024', 'CONTENT-LENGTH' => '512')), + // \OCP\Files\FileInfo::SPACE-UNKNOWN = -2 array(-2, array()), - array(-2, array('HTTP_X_EXPECTED_ENTITY_LENGTH' => '1024')), - array(-2, array('HTTP_CONTENT_LENGTH' => '512')), - array(-2, array('HTTP_OC_TOTAL_LENGTH' => '1024', 'HTTP_CONTENT_LENGTH' => '512')), + array(-2, array('X-EXPECTED-ENTITY-LENGTH' => '1024')), + array(-2, array('CONTENT-LENGTH' => '512')), + array(-2, array('OC-TOTAL-LENGTH' => '1024', 'CONTENT-LENGTH' => '512')), ); } public function quotaExceededProvider() { return array( - array(1023, array('HTTP_X_EXPECTED_ENTITY_LENGTH' => '1024')), - array(511, array('HTTP_CONTENT_LENGTH' => '512')), - array(2047, array('HTTP_OC_TOTAL_LENGTH' => '2048', 'HTTP_CONTENT_LENGTH' => '1024')), + array(1023, array('X-EXPECTED-ENTITY-LENGTH' => '1024')), + array(511, array('CONTENT-LENGTH' => '512')), + array(2047, array('OC-TOTAL-LENGTH' => '2048', 'CONTENT-LENGTH' => '1024')), ); } public function lengthProvider() { return array( array(null, array()), - array(1024, array('HTTP_X_EXPECTED_ENTITY_LENGTH' => '1024')), - array(512, array('HTTP_CONTENT_LENGTH' => '512')), - array(2048, array('HTTP_OC_TOTAL_LENGTH' => '2048', 'HTTP_CONTENT_LENGTH' => '1024')), - array(4096, array('HTTP_OC_TOTAL_LENGTH' => '2048', 'HTTP_X_EXPECTED_ENTITY_LENGTH' => '4096')), + array(1024, array('X-EXPECTED-ENTITY-LENGTH' => '1024')), + array(512, array('CONTENT-LENGTH' => '512')), + array(2048, array('OC-TOTAL-LENGTH' => '2048', 'CONTENT-LENGTH' => '1024')), + array(4096, array('OC-TOTAL-LENGTH' => '2048', 'X-EXPECTED-ENTITY-LENGTH' => '4096')), ); } diff --git a/tests/lib/connector/sabre/tagsplugin.php b/tests/lib/connector/sabre/tagsplugin.php index 2afea061ec3..f8af73fecfb 100644 --- a/tests/lib/connector/sabre/tagsplugin.php +++ b/tests/lib/connector/sabre/tagsplugin.php @@ -42,7 +42,7 @@ class TagsPlugin extends \Test\TestCase { public function setUp() { parent::setUp(); $this->server = new \Sabre\DAV\Server(); - $this->tree = $this->getMockBuilder('\Sabre\DAV\ObjectTree') + $this->tree = $this->getMockBuilder('\Sabre\DAV\Tree') ->disableOriginalConstructor() ->getMock(); $this->tagger = $this->getMock('\OCP\ITags'); @@ -59,7 +59,7 @@ class TagsPlugin extends \Test\TestCase { * @dataProvider tagsGetPropertiesDataProvider */ public function testGetProperties($tags, $requestedProperties, $expectedProperties) { - $node = $this->getMockBuilder('\OC_Connector_Sabre_Node') + $node = $this->getMockBuilder('\OC\Connector\Sabre\Node') ->disableOriginalConstructor() ->getMock(); $node->expects($this->any()) @@ -76,29 +76,35 @@ class TagsPlugin extends \Test\TestCase { ->with($this->equalTo(array(123))) ->will($this->returnValue(array(123 => $tags))); - $returnedProperties = array(); - - $this->plugin->beforeGetProperties( - '', - $node, + $propFind = new \Sabre\DAV\PropFind( + '/dummyPath', $requestedProperties, - $returnedProperties + 0 ); - $this->assertEquals($expectedProperties, $returnedProperties); + $this->plugin->handleGetProperties( + $propFind, + $node + ); + + $result = $propFind->getResultForMultiStatus(); + + $this->assertEmpty($result[404]); + unset($result[404]); + $this->assertEquals($expectedProperties, $result); } /** * @dataProvider tagsGetPropertiesDataProvider */ public function testPreloadThenGetProperties($tags, $requestedProperties, $expectedProperties) { - $node1 = $this->getMockBuilder('\OC_Connector_Sabre_File') + $node1 = $this->getMockBuilder('\OC\Connector\Sabre\File') ->disableOriginalConstructor() ->getMock(); $node1->expects($this->any()) ->method('getId') ->will($this->returnValue(111)); - $node2 = $this->getMockBuilder('\OC_Connector_Sabre_File') + $node2 = $this->getMockBuilder('\OC\Connector\Sabre\File') ->disableOriginalConstructor() ->getMock(); $node2->expects($this->any()) @@ -113,7 +119,7 @@ class TagsPlugin extends \Test\TestCase { $expectedCallCount = 1; } - $node = $this->getMockBuilder('\OC_Connector_Sabre_Directory') + $node = $this->getMockBuilder('\OC\Connector\Sabre\Directory') ->disableOriginalConstructor() ->getMock(); $node->expects($this->any()) @@ -123,14 +129,9 @@ class TagsPlugin extends \Test\TestCase { ->method('getChildren') ->will($this->returnValue(array($node1, $node2))); - $this->tree->expects($this->once()) - ->method('getNodeForPath') - ->with('/subdir') - ->will($this->returnValue($node)); - $this->tagger->expects($this->exactly($expectedCallCount)) ->method('getTagsForObjects') - ->with($this->equalTo(array(111, 222))) + ->with($this->equalTo(array(123, 111, 222))) ->will($this->returnValue( array( 111 => $tags, @@ -138,22 +139,41 @@ class TagsPlugin extends \Test\TestCase { ) )); - $returnedProperties = array(); - - $this->plugin->beforeGetPropertiesForPath( + // simulate sabre recursive PROPFIND traversal + $propFindRoot = new \Sabre\DAV\PropFind( '/subdir', $requestedProperties, 1 ); - - $this->plugin->beforeGetProperties( + $propFind1 = new \Sabre\DAV\PropFind( '/subdir/test.txt', - $node1, $requestedProperties, - $returnedProperties + 0 + ); + $propFind2 = new \Sabre\DAV\PropFind( + '/subdir/test2.txt', + $requestedProperties, + 0 ); - $this->assertEquals($expectedProperties, $returnedProperties); + $this->plugin->handleGetProperties( + $propFindRoot, + $node + ); + $this->plugin->handleGetProperties( + $propFind1, + $node1 + ); + $this->plugin->handleGetProperties( + $propFind2, + $node2 + ); + + $result = $propFind1->getResultForMultiStatus(); + + $this->assertEmpty($result[404]); + unset($result[404]); + $this->assertEquals($expectedProperties, $result); } function tagsGetPropertiesDataProvider() { @@ -193,7 +213,9 @@ class TagsPlugin extends \Test\TestCase { array( array('tag1', 'tag2', self::TAG_FAVORITE), array(), - array(), + array( + 200 => array() + ), ), // request both with none set, receive both array( @@ -212,13 +234,18 @@ class TagsPlugin extends \Test\TestCase { public function testUpdateTags() { // this test will replace the existing tags "tagremove" with "tag1" and "tag2" // and keep "tagkeep" - $node = $this->getMockBuilder('\OC_Connector_Sabre_Node') + $node = $this->getMockBuilder('\OC\Connector\Sabre\Node') ->disableOriginalConstructor() ->getMock(); $node->expects($this->any()) ->method('getId') ->will($this->returnValue(123)); + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + $this->tagger->expects($this->at(0)) ->method('getTagsForObjects') ->with($this->equalTo(array(123))) @@ -238,58 +265,109 @@ class TagsPlugin extends \Test\TestCase { ->with(123, 'tagremove'); // properties to set - $properties = array( + $propPatch = new \Sabre\DAV\PropPatch(array( self::TAGS_PROPERTYNAME => new \OC\Connector\Sabre\TagList(array('tag1', 'tag2', 'tagkeep')) - ); - $result = array(); + )); - $this->plugin->updateProperties( - $properties, - $result, - $node + $this->plugin->handleUpdateProperties( + '/dummypath', + $propPatch ); + $propPatch->commit(); + // all requested properties removed, as they were processed already - $this->assertEmpty($properties); + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertEquals(200, $result[self::TAGS_PROPERTYNAME]); + $this->assertFalse(isset($result[self::FAVORITE_PROPERTYNAME])); + } + + public function testUpdateTagsFromScratch() { + $node = $this->getMockBuilder('\OC\Connector\Sabre\Node') + ->disableOriginalConstructor() + ->getMock(); + $node->expects($this->any()) + ->method('getId') + ->will($this->returnValue(123)); + + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + + $this->tagger->expects($this->at(0)) + ->method('getTagsForObjects') + ->with($this->equalTo(array(123))) + ->will($this->returnValue(array())); + + // then tag as tag1 and tag2 + $this->tagger->expects($this->at(1)) + ->method('tagAs') + ->with(123, 'tag1'); + $this->tagger->expects($this->at(2)) + ->method('tagAs') + ->with(123, 'tag2'); - $this->assertEquals( - new \OC\Connector\Sabre\TagList(array('tag1', 'tag2', 'tagkeep')), - $result[200][self::TAGS_PROPERTYNAME] + // properties to set + $propPatch = new \Sabre\DAV\PropPatch(array( + self::TAGS_PROPERTYNAME => new \OC\Connector\Sabre\TagList(array('tag1', 'tag2', 'tagkeep')) + )); + + $this->plugin->handleUpdateProperties( + '/dummypath', + $propPatch ); - $this->assertFalse(isset($result[200][self::FAVORITE_PROPERTYNAME])); + + $propPatch->commit(); + + // all requested properties removed, as they were processed already + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertEquals(200, $result[self::TAGS_PROPERTYNAME]); + $this->assertFalse(false, isset($result[self::FAVORITE_PROPERTYNAME])); } public function testUpdateFav() { // this test will replace the existing tags "tagremove" with "tag1" and "tag2" // and keep "tagkeep" - $node = $this->getMockBuilder('\OC_Connector_Sabre_Node') + $node = $this->getMockBuilder('\OC\Connector\Sabre\Node') ->disableOriginalConstructor() ->getMock(); $node->expects($this->any()) ->method('getId') ->will($this->returnValue(123)); + $this->tree->expects($this->any()) + ->method('getNodeForPath') + ->with('/dummypath') + ->will($this->returnValue($node)); + // set favorite tag $this->tagger->expects($this->once()) ->method('tagAs') ->with(123, self::TAG_FAVORITE); // properties to set - $properties = array( + $propPatch = new \Sabre\DAV\PropPatch(array( self::FAVORITE_PROPERTYNAME => true - ); - $result = array(); - $this->plugin->updateProperties( - $properties, - $result, - $node + )); + + $this->plugin->handleUpdateProperties( + '/dummypath', + $propPatch ); + $propPatch->commit(); + // all requested properties removed, as they were processed already - $this->assertEmpty($properties); + $this->assertEmpty($propPatch->getRemainingMutations()); - $this->assertTrue($result[200][self::FAVORITE_PROPERTYNAME]); - $this->assertFalse(isset($result[200][self::TAGS_PROPERTYNAME])); + $result = $propPatch->getResult(); + $this->assertFalse(false, isset($result[self::TAGS_PROPERTYNAME])); + $this->assertEquals(200, isset($result[self::FAVORITE_PROPERTYNAME])); // unfavorite now // set favorite tag @@ -297,18 +375,24 @@ class TagsPlugin extends \Test\TestCase { ->method('unTag') ->with(123, self::TAG_FAVORITE); - $properties = array( + // properties to set + $propPatch = new \Sabre\DAV\PropPatch(array( self::FAVORITE_PROPERTYNAME => false + )); + + $this->plugin->handleUpdateProperties( + '/dummypath', + $propPatch ); - $result = array(); - $this->plugin->updateProperties( - $properties, - $result, - $node - ); - $this->assertFalse($result[200][self::FAVORITE_PROPERTYNAME]); - $this->assertFalse(isset($result[200][self::TAGS_PROPERTYNAME])); + $propPatch->commit(); + + // all requested properties removed, as they were processed already + $this->assertEmpty($propPatch->getRemainingMutations()); + + $result = $propPatch->getResult(); + $this->assertFalse(false, isset($result[self::TAGS_PROPERTYNAME])); + $this->assertEquals(200, isset($result[self::FAVORITE_PROPERTYNAME])); } } diff --git a/tests/lib/naturalsort.php b/tests/lib/naturalsort.php index e022a855309..8fcbc6f5fd3 100644 --- a/tests/lib/naturalsort.php +++ b/tests/lib/naturalsort.php @@ -8,27 +8,32 @@ class Test_NaturalSort extends \Test\TestCase { - public function setUp() { - parent::setUp(); - + /** + * @dataProvider naturalSortDataProvider + */ + public function testNaturalSortCompare($array, $sorted) + { if(!class_exists('Collator')) { - $this->markTestSkipped('The intl module is not available, natural sorting will not work as expected.'); + $this->markTestSkipped('The intl module is not available, natural sorting might not work as expected.'); return; } + $comparator = \OC\NaturalSort::getInstance(); + usort($array, array($comparator, 'compare')); + $this->assertEquals($sorted, $array); } /** - * @dataProvider naturalSortDataProvider - */ - public function testNaturalSortCompare($array, $sorted) + * @dataProvider defaultCollatorDataProvider + */ + public function testDefaultCollatorCompare($array, $sorted) { - $comparator = \OC\NaturalSort::getInstance(); + $comparator = new \OC\NaturalSort(new \OC\NaturalSort_DefaultCollator()); usort($array, array($comparator, 'compare')); $this->assertEquals($sorted, $array); } /** - * Data provider for natural sort. + * Data provider for natural sorting with php5-intl's Collator. * Must provide the same result as in core/js/tests/specs/coreSpec.js * @return array test cases */ @@ -181,4 +186,85 @@ class Test_NaturalSort extends \Test\TestCase { ), ); } + + /** + * Data provider for natural sorting with \OC\NaturalSort_DefaultCollator. + * Must provide the same result as in core/js/tests/specs/coreSpec.js + * @return array test cases + */ + public function defaultCollatorDataProvider() + { + return array( + // different casing + array( + // unsorted + array( + 'aaa', + 'bbb', + 'BBB', + 'AAA' + ), + // sorted + array( + 'aaa', + 'AAA', + 'bbb', + 'BBB' + ) + ), + // numbers + array( + // unsorted + array( + '124.txt', + 'abc1', + '123.txt', + 'abc', + 'abc2', + 'def (2).txt', + 'ghi 10.txt', + 'abc12', + 'def.txt', + 'def (1).txt', + 'ghi 2.txt', + 'def (10).txt', + 'abc10', + 'def (12).txt', + 'z', + 'ghi.txt', + 'za', + 'ghi 1.txt', + 'ghi 12.txt', + 'zz', + '15.txt', + '15b.txt', + ), + // sorted + array( + '15.txt', + '15b.txt', + '123.txt', + '124.txt', + 'abc', + 'abc1', + 'abc2', + 'abc10', + 'abc12', + 'def.txt', + 'def (1).txt', + 'def (2).txt', + 'def (10).txt', + 'def (12).txt', + 'ghi.txt', + 'ghi 1.txt', + 'ghi 2.txt', + 'ghi 10.txt', + 'ghi 12.txt', + 'z', + 'za', + 'zz', + ) + ), + ); + } } diff --git a/tests/lib/updater.php b/tests/lib/updater.php index f847ffc91bf..7a1bc48e1a8 100644 --- a/tests/lib/updater.php +++ b/tests/lib/updater.php @@ -88,7 +88,7 @@ class UpdaterTest extends \Test\TestCase { protected function getUpdaterMock($content){ // Invalidate cache - $mockedAppConfig = $this->getMockBuilder('\OC\AppConfig') + $mockedConfig = $this->getMockBuilder('\OCP\IConfig') ->disableOriginalConstructor() ->getMock() ; @@ -101,7 +101,7 @@ class UpdaterTest extends \Test\TestCase { $mockedHTTPHelper->expects($this->once())->method('getUrlContent')->will($this->returnValue($content)); - return new Updater($mockedHTTPHelper, $mockedAppConfig); + return new Updater($mockedHTTPHelper, $mockedConfig); } } diff --git a/tests/lib/vobject.php b/tests/lib/vobject.php deleted file mode 100644 index 6fabf30e48f..00000000000 --- a/tests/lib/vobject.php +++ /dev/null @@ -1,40 +0,0 @@ -<?php -/** - * Copyright (c) 2013 Thomas Tanghus (thomas@tanghus.net) - * This file is licensed under the Affero General Public License version 3 or - * later. - * See the COPYING-README file. - */ - -class Test_VObject extends \Test\TestCase { - - protected function setUp() { - parent::setUp(); - - Sabre\VObject\Property::$classMap['SUMMARY'] = 'OC\VObject\StringProperty'; - Sabre\VObject\Property::$classMap['ORG'] = 'OC\VObject\CompoundProperty'; - } - - function testStringProperty() { - $property = Sabre\VObject\Property::create('SUMMARY', 'Escape;this,please'); - $this->assertEquals("SUMMARY:Escape\;this\,please\r\n", $property->serialize()); - } - - function testCompoundProperty() { - - $arr = array( - 'ABC, Inc.', - 'North American Division', - 'Marketing;Sales', - ); - - $property = Sabre\VObject\Property::create('ORG'); - $property->setParts($arr); - - $this->assertEquals('ABC\, Inc.;North American Division;Marketing\;Sales', $property->value); - $this->assertEquals('ORG:ABC\, Inc.;North American Division;Marketing\;Sales' . "\r\n", $property->serialize()); - $this->assertEquals(3, count($property->getParts())); - $parts = $property->getParts(); - $this->assertEquals('Marketing;Sales', $parts[2]); - } -} |