OCV: Report validation errors for (Re)Association Request frames
Add the OCV-FAILURE control interface event to notify upper layers of OCV validation issues in FT and FILS (Re)Association Request frames. Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
parent
5071248bd4
commit
01ceb88c77
2 changed files with 10 additions and 0 deletions
|
@ -24,6 +24,7 @@
|
|||
#include "common/dpp.h"
|
||||
#include "common/ocv.h"
|
||||
#include "common/wpa_common.h"
|
||||
#include "common/wpa_ctrl.h"
|
||||
#include "radius/radius.h"
|
||||
#include "radius/radius_client.h"
|
||||
#include "p2p/p2p.h"
|
||||
|
@ -3511,6 +3512,9 @@ static int check_assoc_ies(struct hostapd_data *hapd, struct sta_info *sta,
|
|||
tx_chanwidth, tx_seg1_idx) != 0) {
|
||||
wpa_printf(MSG_WARNING, "FILS: OCV failed: %s",
|
||||
ocv_errorstr);
|
||||
wpa_msg(hapd->msg_ctx, MSG_INFO, OCV_FAILURE "addr="
|
||||
MACSTR " frame=fils-reassoc-req error=%s",
|
||||
MAC2STR(sta->addr), ocv_errorstr);
|
||||
return WLAN_STATUS_UNSPECIFIED_FAILURE;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include "common/ieee802_11_defs.h"
|
||||
#include "common/ieee802_11_common.h"
|
||||
#include "common/ocv.h"
|
||||
#include "common/wpa_ctrl.h"
|
||||
#include "drivers/driver.h"
|
||||
#include "crypto/aes.h"
|
||||
#include "crypto/aes_siv.h"
|
||||
|
@ -3467,6 +3468,11 @@ int wpa_ft_validate_reassoc(struct wpa_state_machine *sm, const u8 *ies,
|
|||
if (ocv_verify_tx_params(parse.oci, parse.oci_len, &ci,
|
||||
tx_chanwidth, tx_seg1_idx) != 0) {
|
||||
wpa_printf(MSG_WARNING, "OCV failed: %s", ocv_errorstr);
|
||||
if (sm->wpa_auth->conf.msg_ctx)
|
||||
wpa_msg(sm->wpa_auth->conf.msg_ctx, MSG_INFO,
|
||||
OCV_FAILURE "addr=" MACSTR
|
||||
" frame=ft-reassoc-req error=%s",
|
||||
MAC2STR(sm->addr), ocv_errorstr);
|
||||
return WLAN_STATUS_UNSPECIFIED_FAILURE;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue