mirror of
https://github.com/phpseclib/phpseclib.git
synced 2025-01-27 09:08:24 +00:00
RSA: loading keys could error out if xml extension wasn't installed
This commit is contained in:
parent
978b2adbfc
commit
9fae7ec89d
@ -1470,6 +1470,10 @@ class Crypt_RSA
|
||||
// http://en.wikipedia.org/wiki/XML_Signature
|
||||
case CRYPT_RSA_PRIVATE_FORMAT_XML:
|
||||
case CRYPT_RSA_PUBLIC_FORMAT_XML:
|
||||
if (!extension_loaded('xml')) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$this->components = array();
|
||||
|
||||
$xml = xml_parser_create('UTF-8');
|
||||
|
Loading…
x
Reference in New Issue
Block a user