diff options
author | Bjoern Schiessle <schiessle@owncloud.com> | 2013-07-29 17:06:05 +0200 |
---|---|---|
committer | Bjoern Schiessle <schiessle@owncloud.com> | 2013-07-29 17:06:05 +0200 |
commit | b6fa0e4eefb332dc1fb9b45df50de4621ed8e6bd (patch) | |
tree | 2ca892180568bd5c76facbfd9e6762621485a5dd /apps/files_encryption/hooks | |
parent | 830f5d24c77b863bd49eda0cbc4ba812add8065d (diff) | |
download | nextcloud-server-b6fa0e4eefb332dc1fb9b45df50de4621ed8e6bd.tar.gz nextcloud-server-b6fa0e4eefb332dc1fb9b45df50de4621ed8e6bd.zip |
working decrypt files method
Diffstat (limited to 'apps/files_encryption/hooks')
-rw-r--r-- | apps/files_encryption/hooks/hooks.php | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/apps/files_encryption/hooks/hooks.php b/apps/files_encryption/hooks/hooks.php index b2a17f6bca5..d9c3f49b736 100644 --- a/apps/files_encryption/hooks/hooks.php +++ b/apps/files_encryption/hooks/hooks.php @@ -62,18 +62,7 @@ class Hooks { return false;
}
- $encryptedKey = Keymanager::getPrivateKey($view, $params['uid']);
-
- $privateKey = Crypt::decryptPrivateKey($encryptedKey, $params['password']);
-
- if ($privateKey === false) {
- \OCP\Util::writeLog('Encryption library', 'Private key for user "' . $params['uid']
- . '" is not valid! Maybe the user password was changed from outside if so please change it back to gain access', \OCP\Util::ERROR);
- }
-
- $session = new \OCA\Encryption\Session($view);
-
- $session->setPrivateKey($privateKey);
+ $session = $util->initEncryption($params);
// Check if first-run file migration has already been performed
$ready = false;
|