diff options
author | Sam Tuke <samtuke@owncloud.com> | 2013-02-27 18:50:57 +0000 |
---|---|---|
committer | Sam Tuke <samtuke@owncloud.com> | 2013-02-27 18:50:57 +0000 |
commit | 0bc7d3bcf833e257fa4b2ae3b74d60bef63218b8 (patch) | |
tree | a2b898ccfa8927314dce3e2e9f44ac46b4566712 | |
parent | 953319a2c3d85bf0d5eb86511c7466188b5ca45f (diff) | |
download | nextcloud-server-0bc7d3bcf833e257fa4b2ae3b74d60bef63218b8.tar.gz nextcloud-server-0bc7d3bcf833e257fa4b2ae3b74d60bef63218b8.zip |
Added notes where to reuse old keys instead of generating new ones
-rw-r--r-- | apps/files_encryption/lib/stream.php | 1 | ||||
-rw-r--r-- | apps/files_encryption/lib/util.php | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/apps/files_encryption/lib/stream.php b/apps/files_encryption/lib/stream.php index d4b993b4c06..f4bd6f1b6b0 100644 --- a/apps/files_encryption/lib/stream.php +++ b/apps/files_encryption/lib/stream.php @@ -318,6 +318,7 @@ class Stream { // one), save the newly generated keyfile if ( ! $this->getKey() ) { + // TODO: Reuse the keyfile, it it exists, instead of making a new one $this->keyfile = Crypt::generateKey(); $this->publicKey = Keymanager::getPublicKey( $this->rootView, $this->userId ); diff --git a/apps/files_encryption/lib/util.php b/apps/files_encryption/lib/util.php index cd223bd7029..6a18feea7df 100644 --- a/apps/files_encryption/lib/util.php +++ b/apps/files_encryption/lib/util.php @@ -692,6 +692,7 @@ class Util { // Save the recrypted key to it's owner's keyfiles directory // Save new sharekeys to all necessary user directory + // TODO: Reuse the keyfile, it it exists, instead of making a new one if ( ! Keymanager::setFileKey( $this->view, $filePath, $fileOwner, $multiEncKey['data'] ) || ! Keymanager::setShareKeys( $this->view, $filePath, $multiEncKey['keys'] ) |