diff options
-rw-r--r-- | issue_template.md | 2 | ||||
-rw-r--r-- | lib/private/Encryption/DecryptAll.php (renamed from lib/private/encryption/decryptall.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/EncryptionWrapper.php (renamed from lib/private/encryption/encryptionwrapper.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/DecryptionFailedException.php (renamed from lib/private/encryption/exceptions/decryptionfailedexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/EmptyEncryptionDataException.php (renamed from lib/private/encryption/exceptions/emptyencryptiondataexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/EncryptionFailedException.php (renamed from lib/private/encryption/exceptions/encryptionfailedexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/EncryptionHeaderKeyExistsException.php (renamed from lib/private/encryption/exceptions/encryptionheaderkeyexistsexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/EncryptionHeaderToLargeException.php (renamed from lib/private/encryption/exceptions/encryptionheadertolargeexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/ModuleAlreadyExistsException.php (renamed from lib/private/encryption/exceptions/modulealreadyexistsexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/ModuleDoesNotExistsException.php (renamed from lib/private/encryption/exceptions/moduledoesnotexistsexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Exceptions/UnknownCipherException.php (renamed from lib/private/encryption/exceptions/unknowncipherexception.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/File.php (renamed from lib/private/encryption/file.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/HookManager.php (renamed from lib/private/encryption/hookmanager.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Keys/Storage.php (renamed from lib/private/encryption/keys/storage.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Manager.php (renamed from lib/private/encryption/manager.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Update.php (renamed from lib/private/encryption/update.php) | 0 | ||||
-rw-r--r-- | lib/private/Encryption/Util.php (renamed from lib/private/encryption/util.php) | 0 | ||||
-rw-r--r-- | lib/private/files/filesystem.php | 4 | ||||
-rw-r--r-- | tests/lib/files/filesystem.php | 22 |
19 files changed, 26 insertions, 2 deletions
diff --git a/issue_template.md b/issue_template.md index b240da51a7d..cf96fc6148d 100644 --- a/issue_template.md +++ b/issue_template.md @@ -3,6 +3,8 @@ Thanks for reporting issues back to ownCloud! This is the issue tracker of ownCl This is the bug tracker for the Server component. Find other components at https://github.com/owncloud/core/blob/master/CONTRIBUTING.md#guidelines +For reporting potential security issues please see https://owncloud.org/security/ + To make it possible for us to help you please fill out below information carefully. --> ### Steps to reproduce diff --git a/lib/private/encryption/decryptall.php b/lib/private/Encryption/DecryptAll.php index 7a965a5f227..7a965a5f227 100644 --- a/lib/private/encryption/decryptall.php +++ b/lib/private/Encryption/DecryptAll.php diff --git a/lib/private/encryption/encryptionwrapper.php b/lib/private/Encryption/EncryptionWrapper.php index 11beb0cd6b1..11beb0cd6b1 100644 --- a/lib/private/encryption/encryptionwrapper.php +++ b/lib/private/Encryption/EncryptionWrapper.php diff --git a/lib/private/encryption/exceptions/decryptionfailedexception.php b/lib/private/Encryption/Exceptions/DecryptionFailedException.php index a0cbbc5cce0..a0cbbc5cce0 100644 --- a/lib/private/encryption/exceptions/decryptionfailedexception.php +++ b/lib/private/Encryption/Exceptions/DecryptionFailedException.php diff --git a/lib/private/encryption/exceptions/emptyencryptiondataexception.php b/lib/private/Encryption/Exceptions/EmptyEncryptionDataException.php index 2c90c2db7df..2c90c2db7df 100644 --- a/lib/private/encryption/exceptions/emptyencryptiondataexception.php +++ b/lib/private/Encryption/Exceptions/EmptyEncryptionDataException.php diff --git a/lib/private/encryption/exceptions/encryptionfailedexception.php b/lib/private/Encryption/Exceptions/EncryptionFailedException.php index 98e92eb199c..98e92eb199c 100644 --- a/lib/private/encryption/exceptions/encryptionfailedexception.php +++ b/lib/private/Encryption/Exceptions/EncryptionFailedException.php diff --git a/lib/private/encryption/exceptions/encryptionheaderkeyexistsexception.php b/lib/private/Encryption/Exceptions/EncryptionHeaderKeyExistsException.php index ab1a166018c..ab1a166018c 100644 --- a/lib/private/encryption/exceptions/encryptionheaderkeyexistsexception.php +++ b/lib/private/Encryption/Exceptions/EncryptionHeaderKeyExistsException.php diff --git a/lib/private/encryption/exceptions/encryptionheadertolargeexception.php b/lib/private/Encryption/Exceptions/EncryptionHeaderToLargeException.php index 7b706e621de..7b706e621de 100644 --- a/lib/private/encryption/exceptions/encryptionheadertolargeexception.php +++ b/lib/private/Encryption/Exceptions/EncryptionHeaderToLargeException.php diff --git a/lib/private/encryption/exceptions/modulealreadyexistsexception.php b/lib/private/Encryption/Exceptions/ModuleAlreadyExistsException.php index fcd08679acc..fcd08679acc 100644 --- a/lib/private/encryption/exceptions/modulealreadyexistsexception.php +++ b/lib/private/Encryption/Exceptions/ModuleAlreadyExistsException.php diff --git a/lib/private/encryption/exceptions/moduledoesnotexistsexception.php b/lib/private/Encryption/Exceptions/ModuleDoesNotExistsException.php index 282c9ec080b..282c9ec080b 100644 --- a/lib/private/encryption/exceptions/moduledoesnotexistsexception.php +++ b/lib/private/Encryption/Exceptions/ModuleDoesNotExistsException.php diff --git a/lib/private/encryption/exceptions/unknowncipherexception.php b/lib/private/Encryption/Exceptions/UnknownCipherException.php index beb4cb7f2e5..beb4cb7f2e5 100644 --- a/lib/private/encryption/exceptions/unknowncipherexception.php +++ b/lib/private/Encryption/Exceptions/UnknownCipherException.php diff --git a/lib/private/encryption/file.php b/lib/private/Encryption/File.php index ec55c2cea00..ec55c2cea00 100644 --- a/lib/private/encryption/file.php +++ b/lib/private/Encryption/File.php diff --git a/lib/private/encryption/hookmanager.php b/lib/private/Encryption/HookManager.php index 0bc42ec8159..0bc42ec8159 100644 --- a/lib/private/encryption/hookmanager.php +++ b/lib/private/Encryption/HookManager.php diff --git a/lib/private/encryption/keys/storage.php b/lib/private/Encryption/Keys/Storage.php index 47360f45aa5..47360f45aa5 100644 --- a/lib/private/encryption/keys/storage.php +++ b/lib/private/Encryption/Keys/Storage.php diff --git a/lib/private/encryption/manager.php b/lib/private/Encryption/Manager.php index 8714d161807..8714d161807 100644 --- a/lib/private/encryption/manager.php +++ b/lib/private/Encryption/Manager.php diff --git a/lib/private/encryption/update.php b/lib/private/Encryption/Update.php index 62c23c1fe0c..62c23c1fe0c 100644 --- a/lib/private/encryption/update.php +++ b/lib/private/Encryption/Update.php diff --git a/lib/private/encryption/util.php b/lib/private/Encryption/Util.php index 9e0cfca830d..9e0cfca830d 100644 --- a/lib/private/encryption/util.php +++ b/lib/private/Encryption/Util.php diff --git a/lib/private/files/filesystem.php b/lib/private/files/filesystem.php index ec9b537a358..7283c815c97 100644 --- a/lib/private/files/filesystem.php +++ b/lib/private/files/filesystem.php @@ -378,8 +378,6 @@ class Filesystem { if (isset(self::$usersSetup[$user])) { return; } - self::$usersSetup[$user] = true; - $root = \OC_User::getHome($user); $userManager = \OC::$server->getUserManager(); @@ -390,6 +388,8 @@ class Filesystem { throw new \OC\User\NoUserException('Backends provided no user object for ' . $user); } + self::$usersSetup[$user] = true; + $homeStorage = \OC::$server->getConfig()->getSystemValue('objectstore'); if (!empty($homeStorage)) { // sanity checks diff --git a/tests/lib/files/filesystem.php b/tests/lib/files/filesystem.php index 8245af0ace1..b5a3e147259 100644 --- a/tests/lib/files/filesystem.php +++ b/tests/lib/files/filesystem.php @@ -342,6 +342,28 @@ class Filesystem extends \Test\TestCase { } /** + * Tests that an exception is thrown when passed user does not exist. + */ + public function testLocalMountWhenUserDoesNotExistTwice() { + $thrown = 0; + $userId = $this->getUniqueID('user_'); + + try { + \OC\Files\Filesystem::initMountPoints($userId); + } catch (NoUserException $e) { + $thrown++; + } + + try { + \OC\Files\Filesystem::initMountPoints($userId); + } catch (NoUserException $e) { + $thrown++; + } + + $this->assertEquals(2, $thrown); + } + + /** * Tests that the home storage is used for the user's mount point */ public function testHomeMount() { |