Check phpinfo() available before using it

This commit is contained in:
David Anderson 2021-12-21 14:17:16 +00:00 committed by GitHub
parent 0868023216
commit dd9dfeec18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -515,7 +515,7 @@ class Crypt_RSA
case !function_exists('openssl_pkey_get_details'):
define('CRYPT_RSA_MODE', CRYPT_RSA_MODE_INTERNAL);
break;
case extension_loaded('openssl') && version_compare(PHP_VERSION, '4.2.0', '>=') && file_exists($this->configFile):
case function_exists('phpinfo') && extension_loaded('openssl') && version_compare(PHP_VERSION, '4.2.0', '>=') && file_exists($this->configFile):
// some versions of XAMPP have mismatched versions of OpenSSL which causes it not to work
ob_start();
@phpinfo();