mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-01-30 00:22:13 +01:00
Merge pull request #3266 from dgarske/unit_test
Fix for DH compute key compatibility function failure
This commit is contained in:
@@ -29795,7 +29795,7 @@ int wolfSSL_DH_compute_key(unsigned char* key, WOLFSSL_BIGNUM* otherPub,
|
||||
privSz = wolfSSL_BN_bn2bin(dh->priv_key, priv);
|
||||
pubSz = wolfSSL_BN_bn2bin(otherPub, pub);
|
||||
if (dh->inSet == 0 && SetDhInternal(dh) != SSL_SUCCESS){
|
||||
WOLFSSL_MSG("Bad DH set internal");
|
||||
WOLFSSL_MSG("Bad DH set internal");
|
||||
}
|
||||
if (privSz <= 0 || pubSz <= 0)
|
||||
WOLFSSL_MSG("Bad BN2bin set");
|
||||
@@ -29811,6 +29811,8 @@ int wolfSSL_DH_compute_key(unsigned char* key, WOLFSSL_BIGNUM* otherPub,
|
||||
XFREE(priv, NULL, DYNAMIC_TYPE_PRIVATE_KEY);
|
||||
#endif
|
||||
|
||||
WOLFSSL_LEAVE("wolfSSL_DH_compute_key", ret);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user