diff options
author | Carl Schwan <carl@carlschwan.eu> | 2022-07-05 11:25:44 +0200 |
---|---|---|
committer | Carl Schwan <carl@carlschwan.eu> | 2022-07-05 11:25:44 +0200 |
commit | cdf3b60555eb559ea5f9b141903054afbc273062 (patch) | |
tree | 36224d892603426a3f1903251c0ee03f67baaff5 /lib/private | |
parent | ec465bf247ec2e9fd3df13f6a289ecc5fb6e4e2a (diff) | |
download | nextcloud-server-cdf3b60555eb559ea5f9b141903054afbc273062.tar.gz nextcloud-server-cdf3b60555eb559ea5f9b141903054afbc273062.zip |
Handle one time passwords
This adds an option to disable storing passwords in the database. This
might be desirable when using single use token as passwords or very
large passwords.
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
Diffstat (limited to 'lib/private')
-rw-r--r-- | lib/private/Authentication/Token/PublicKeyTokenProvider.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Authentication/Token/PublicKeyTokenProvider.php b/lib/private/Authentication/Token/PublicKeyTokenProvider.php index a1d75828e27..16425a2e1c3 100644 --- a/lib/private/Authentication/Token/PublicKeyTokenProvider.php +++ b/lib/private/Authentication/Token/PublicKeyTokenProvider.php @@ -368,7 +368,7 @@ class PublicKeyTokenProvider implements IProvider { $dbToken->setPublicKey($publicKey); $dbToken->setPrivateKey($this->encrypt($privateKey, $token)); - if (!is_null($password)) { + if (!is_null($password) && $this->config->getSystemValueBool('auth.storeCryptedPassword', true)) { $dbToken->setPassword($this->encryptPassword($password, $publicKey)); } |