Fix a NULL deref in an error path
The SRP_create_verifier_BN function goes to the |err| label if the |salt| value passed to it is NULL. It is then deref'd. Reviewed-by: Rich Salz <rsalz@openssl.org>
This commit is contained in:
parent
e113c9c59d
commit
3bbd1d63e2
@ -644,7 +644,7 @@ int SRP_create_verifier_BN(const char *user, const char *pass, BIGNUM **salt,
|
|||||||
*salt = salttmp;
|
*salt = salttmp;
|
||||||
|
|
||||||
err:
|
err:
|
||||||
if (*salt != salttmp)
|
if (salt != NULL && *salt != salttmp)
|
||||||
BN_clear_free(salttmp);
|
BN_clear_free(salttmp);
|
||||||
BN_clear_free(x);
|
BN_clear_free(x);
|
||||||
BN_CTX_free(bn_ctx);
|
BN_CTX_free(bn_ctx);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user