mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-02-17 17:43:06 -05:00
DPP: Fix a memory leak on an error path
Fix a memory leak exposed by the dpp_own_config_sign_fail test. Fixes: 52d469de1112 ("DPP2: Support multiple Config Objects in Enrollee") Signed-off-by: Alexander Wetzel <alexander@wetzel-home.de>
This commit is contained in:
parent
972edba185
commit
78d338d1b1
@ -6859,8 +6859,11 @@ int dpp_configurator_own_config(struct dpp_authentication *auth,
|
||||
dpp_copy_csign(&auth->conf_obj[0], auth->conf->csign);
|
||||
|
||||
conf_obj = dpp_build_conf_obj(auth, ap, 0);
|
||||
if (!conf_obj)
|
||||
if (!conf_obj) {
|
||||
wpabuf_free(auth->conf_obj[0].c_sign_key);
|
||||
auth->conf_obj[0].c_sign_key = NULL;
|
||||
goto fail;
|
||||
}
|
||||
ret = dpp_parse_conf_obj(auth, wpabuf_head(conf_obj),
|
||||
wpabuf_len(conf_obj));
|
||||
fail:
|
||||
|
Loading…
x
Reference in New Issue
Block a user