diff --git a/phpseclib/Crypt/RSA.php b/phpseclib/Crypt/RSA.php index ac9101ae..48192c58 100644 --- a/phpseclib/Crypt/RSA.php +++ b/phpseclib/Crypt/RSA.php @@ -966,7 +966,7 @@ class RSA if (!$rsa->load($key, $type)) { return false; } - unset($rsa->publicExponent); + $rsa->publicExponent = false; // don't overwrite the old key if the new key is invalid $this->load($rsa);