eapol_sm_configure(sm->preauth_eapol, -1, -1, 5, 6);
os_memcpy(sm->preauth_bssid, dst, ETH_ALEN);
- eapol_sm_notify_portValid(sm->preauth_eapol, TRUE);
+ eapol_sm_notify_portValid(sm->preauth_eapol, true);
/* 802.1X::portControl = Auto */
- eapol_sm_notify_portEnabled(sm->preauth_eapol, TRUE);
+ eapol_sm_notify_portEnabled(sm->preauth_eapol, true);
eloop_register_timeout(sm->dot11RSNAConfigSATimeout, 0,
rsn_preauth_timeout, sm, NULL);
wpa_sm_mlme_setprotection(
sm, addr, MLME_SETPROTECTION_PROTECT_TYPE_RX_TX,
MLME_SETPROTECTION_KEY_TYPE_PAIRWISE);
- eapol_sm_notify_portValid(sm->eapol, TRUE);
+ eapol_sm_notify_portValid(sm->eapol, true);
if (wpa_key_mgmt_wpa_psk(sm->key_mgmt) ||
sm->key_mgmt == WPA_KEY_MGMT_DPP ||
sm->key_mgmt == WPA_KEY_MGMT_OWE)
- eapol_sm_notify_eap_success(sm->eapol, TRUE);
+ eapol_sm_notify_eap_success(sm->eapol, true);
/*
* Start preauthentication after a short wait to avoid a
* possible race condition between the data receive and key
wpa_sm_mlme_setprotection(
sm, sm->bssid, MLME_SETPROTECTION_PROTECT_TYPE_RX,
MLME_SETPROTECTION_KEY_TYPE_PAIRWISE);
- eapol_sm_notify_portValid(sm->eapol, TRUE);
+ eapol_sm_notify_portValid(sm->eapol, true);
}
wpa_sm_set_state(sm, WPA_GROUP_HANDSHAKE);
int wpa_sm_get_mib(struct wpa_sm *sm, char *buf, size_t buflen)
{
char pmkid_txt[PMKID_LEN * 2 + 1];
- int rsna, ret;
+ bool rsna;
+ int ret;
size_t len;
if (sm->cur_pmksa) {
} else
pmkid_txt[0] = '\0';
- if ((wpa_key_mgmt_wpa_psk(sm->key_mgmt) ||
- wpa_key_mgmt_wpa_ieee8021x(sm->key_mgmt)) &&
- sm->proto == WPA_PROTO_RSN)
- rsna = 1;
- else
- rsna = 0;
+ rsna = (wpa_key_mgmt_wpa_psk(sm->key_mgmt) ||
+ wpa_key_mgmt_wpa_ieee8021x(sm->key_mgmt)) &&
+ sm->proto == WPA_PROTO_RSN;
ret = os_snprintf(buf, buflen,
"dot11RSNAOptionImplemented=TRUE\n"
* Clear portValid to kick EAPOL state machine to re-enter
* AUTHENTICATED state to get the EAPOL port Authorized.
*/
- eapol_sm_notify_portValid(sm->eapol, FALSE);
+ eapol_sm_notify_portValid(sm->eapol, false);
wpa_supplicant_key_neg_complete(sm, sm->bssid, 1);
/* Prepare for the next transition */