diff options
author | Côme Chilliet <come.chilliet@nextcloud.com> | 2022-11-07 10:54:02 +0100 |
---|---|---|
committer | Côme Chilliet <come.chilliet@nextcloud.com> | 2023-01-20 11:22:08 +0100 |
commit | 7ebbb6b2ca52e122adfca88e4b9a2805863e43d3 (patch) | |
tree | a465abf8518491171e898a8534a97d1ec933e450 /apps/encryption | |
parent | 9369b67df3888ae0b30dda47f5211843f42c6514 (diff) | |
download | nextcloud-server-7ebbb6b2ca52e122adfca88e4b9a2805863e43d3.tar.gz nextcloud-server-7ebbb6b2ca52e122adfca88e4b9a2805863e43d3.zip |
Remove workarounds specific to 7.4
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
Diffstat (limited to 'apps/encryption')
-rw-r--r-- | apps/encryption/lib/Crypto/Crypt.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/apps/encryption/lib/Crypto/Crypt.php b/apps/encryption/lib/Crypto/Crypt.php index 8bfeb0c7a68..efb5a6868b0 100644 --- a/apps/encryption/lib/Crypto/Crypt.php +++ b/apps/encryption/lib/Crypto/Crypt.php @@ -316,8 +316,8 @@ class Crypt { throw new \InvalidArgumentException( sprintf( - 'Unsupported cipher (%s) defined.', - $cipher + 'Unsupported cipher (%s) defined.', + $cipher ) ); } @@ -470,8 +470,7 @@ class Crypt { */ protected function isValidPrivateKey($plainKey) { $res = openssl_get_privatekey($plainKey); - // TODO: remove resource check one php7.4 is not longer supported - if (is_resource($res) || (is_object($res) && get_class($res) === 'OpenSSLAsymmetricKey')) { + if (is_object($res) && get_class($res) === 'OpenSSLAsymmetricKey') { $sslInfo = openssl_pkey_get_details($res); if (isset($sslInfo['key'])) { return true; |