diff options
author | Joas Schilling <213943+nickvergessen@users.noreply.github.com> | 2024-04-18 10:48:03 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-18 10:48:03 +0200 |
commit | 5fffbcfe8650eab75b00e8d188fbc95b0e43f3a8 (patch) | |
tree | f571daed4b6077edc44eabb6645c05f8f91cbd1b | |
parent | 2161387ac751b070a93e7eb8f38d006093703b0d (diff) | |
parent | 64d32abb4857f51476488e8946c6e9a6af0d2f89 (diff) | |
download | nextcloud-server-5fffbcfe8650eab75b00e8d188fbc95b0e43f3a8.tar.gz nextcloud-server-5fffbcfe8650eab75b00e8d188fbc95b0e43f3a8.zip |
Merge pull request #44889 from nextcloud/bugfix/noid/skip-cross-storage-move-with-ac
fix(files): Also skip cross storage move with access control
-rw-r--r-- | lib/private/Files/Storage/Local.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/private/Files/Storage/Local.php b/lib/private/Files/Storage/Local.php index 909b124ff64..2c90a28fe3b 100644 --- a/lib/private/Files/Storage/Local.php +++ b/lib/private/Files/Storage/Local.php @@ -584,11 +584,14 @@ class Local extends \OC\Files\Storage\Common { } private function canDoCrossStorageMove(IStorage $sourceStorage) { + /** @psalm-suppress UndefinedClass */ return $sourceStorage->instanceOfStorage(Local::class) // Don't treat ACLStorageWrapper like local storage where copy can be done directly. // Instead, use the slower recursive copying in php from Common::copyFromStorage with // more permissions checks. && !$sourceStorage->instanceOfStorage('OCA\GroupFolders\ACL\ACLStorageWrapper') + // Same for access control + && !$sourceStorage->instanceOfStorage(\OCA\FilesAccessControl\StorageWrapper::class) // when moving encrypted files we have to handle keys and the target might not be encrypted && !$sourceStorage->instanceOfStorage(Encryption::class); } |