We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fe46f23 commit e2a7b12Copy full SHA for e2a7b12
lib/private/Session/CryptoSessionData.php
@@ -32,6 +32,7 @@
32
use OCP\ISession;
33
use OCP\Security\ICrypto;
34
use OCP\Session\Exceptions\SessionNotAvailableException;
35
+use function OCP\Log\logger;
36
37
/**
38
* Class CryptoSessionData
@@ -82,9 +83,14 @@ protected function initializeSession() {
82
83
try {
84
$this->sessionValues = json_decode(
85
$this->crypto->decrypt($encryptedSessionData, $this->passphrase),
- true
86
+ true,
87
+ 512,
88
+ JSON_THROW_ON_ERROR,
89
);
90
} catch (\Exception $e) {
91
+ logger('core')->critical('Could not decrypt or decode encrypted session data', [
92
+ 'exception' => $e,
93
+ ]);
94
$this->sessionValues = [];
95
$this->regenerateId(true, false);
96
}
0 commit comments