diff options
-rw-r--r-- | apps/encryption/lib/Crypto/Encryption.php | 2 | ||||
-rw-r--r-- | apps/encryption/lib/KeyManager.php | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/apps/encryption/lib/Crypto/Encryption.php b/apps/encryption/lib/Crypto/Encryption.php index 838c63e9495..465856fd28d 100644 --- a/apps/encryption/lib/Crypto/Encryption.php +++ b/apps/encryption/lib/Crypto/Encryption.php @@ -516,7 +516,7 @@ class Encryption implements IEncryptionModule { * @throws DecryptionFailedException */ public function isReadable($path, $uid) { - $fileKey = $this->keyManager->getFileKey($path, $uid); + $fileKey = $this->keyManager->getFileKey($path, $uid, null); if (empty($fileKey)) { $owner = $this->util->getOwner($path); if ($owner !== $uid) { diff --git a/apps/encryption/lib/KeyManager.php b/apps/encryption/lib/KeyManager.php index 5c933b5f8b2..f0005b45761 100644 --- a/apps/encryption/lib/KeyManager.php +++ b/apps/encryption/lib/KeyManager.php @@ -485,7 +485,7 @@ class KeyManager { $privateKey); } } - if ($useLegacyFileKey ?? false) { + if (!($useLegacyFileKey ?? false)) { if ($shareKey && $privateKey) { return $this->crypt->multiKeyDecrypt($shareKey, $privateKey); } |