mirror of
https://github.com/openssl/openssl.git
synced 2024-11-21 01:15:20 +08:00
fix previous modification -- if ssl->cert is NULL, don't follow the pointer.
This commit is contained in:
parent
927ddaffeb
commit
f3e67ac1bc
@ -575,6 +575,8 @@ int SSL_check_private_key(SSL *ssl)
|
||||
SSLerr(SSL_F_SSL_CHECK_PRIVATE_KEY,ERR_R_PASSED_NULL_PARAMETER);
|
||||
return(0);
|
||||
}
|
||||
if (ssl->cert == NULL)
|
||||
return 0;
|
||||
if (ssl->cert->key->x509 == NULL)
|
||||
{
|
||||
SSLerr(SSL_F_SSL_CHECK_PRIVATE_KEY,SSL_R_NO_CERTIFICATE_ASSIGNED);
|
||||
|
Loading…
Reference in New Issue
Block a user