mirror of
https://github.com/openssl/openssl.git
synced 2024-12-09 05:51:54 +08:00
Do not call ossl_ffc_name_to_dh_named_group with NULL argument
Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/17498)
This commit is contained in:
parent
f58bb2dd00
commit
3b53f88c00
@ -37,6 +37,7 @@ int ossl_ffc_params_fromdata(FFC_PARAMS *ffc, const OSSL_PARAM params[])
|
||||
const DH_NAMED_GROUP *group = NULL;
|
||||
|
||||
if (prm->data_type != OSSL_PARAM_UTF8_STRING
|
||||
|| prm->data == NULL
|
||||
|| (group = ossl_ffc_name_to_dh_named_group(prm->data)) == NULL
|
||||
|| !ossl_ffc_named_group_set_pqg(ffc, group))
|
||||
#endif
|
||||
|
@ -532,6 +532,7 @@ static int dh_gen_common_set_params(void *genctx, const OSSL_PARAM params[])
|
||||
const DH_NAMED_GROUP *group = NULL;
|
||||
|
||||
if (p->data_type != OSSL_PARAM_UTF8_STRING
|
||||
|| p->data == NULL
|
||||
|| (group = ossl_ffc_name_to_dh_named_group(p->data)) == NULL
|
||||
|| ((gctx->group_nid =
|
||||
ossl_ffc_named_group_get_uid(group)) == NID_undef)) {
|
||||
|
Loading…
Reference in New Issue
Block a user