mirror of
https://github.com/nextcloud/server.git
synced 2026-04-15 22:11:17 -04:00
only encrypt file to users with encryption keys
This commit is contained in:
parent
b4df4cc61d
commit
38e5da05af
2 changed files with 2 additions and 3 deletions
|
|
@ -92,8 +92,6 @@ class Hooks {
|
|||
}
|
||||
|
||||
// Encrypt existing user files:
|
||||
// This serves to upgrade old versions of the encryption
|
||||
// app (see appinfo/spec.txt)
|
||||
if (
|
||||
$util->encryptAll('/' . $params['uid'] . '/' . 'files', $session->getLegacyKey(), $params['password'])
|
||||
) {
|
||||
|
|
|
|||
|
|
@ -506,9 +506,10 @@ class Stream {
|
|||
|
||||
// Get all users sharing the file includes current user
|
||||
$uniqueUserIds = $util->getSharingUsersArray($sharingEnabled, $this->relPath, $this->userId);
|
||||
$checkedUserIds = $util->filterShareReadyUsers($uniqueUserIds);
|
||||
|
||||
// Fetch public keys for all sharing users
|
||||
$publicKeys = Keymanager::getPublicKeys($this->rootView, $uniqueUserIds);
|
||||
$publicKeys = Keymanager::getPublicKeys($this->rootView, $checkedUserIds['ready']);
|
||||
|
||||
// Encrypt enc key for all sharing users
|
||||
$this->encKeyfiles = Crypt::multiKeyEncrypt($this->plainKey, $publicKeys);
|
||||
|
|
|
|||
Loading…
Reference in a new issue