[wpa_supplicant] Cumulative patch from commit c54a5e96b

Bug: 154862045
Test: Confirm random dialog token usage from logs
Test: Verify Passpoint ANQP functionality and Passpoint association
Test: act.py -c ../WifiDppConfig.json -tc WifiDppTest
Test: Connect to Passpoint, Open, WPA2, WPA3 networks and run traffic

c54a5e96b Randomize GAS dialog token
a803ba4f9 Use more specific reason codes for 4-way handshake timeouts
ff0b87304 nl80211: Process unprotected Beacon frame RX events
a39e9af90 nl80211: DPP listen mode callback
e81e2091b Remove now unused Boolean/TRUE/FALSE definitions
3d58e8286 FILS: Convert Boolean to C99 bool
86ea761e9 mesh: Convert Boolean to C99 bool
71140cd5b RADIUS: Convert Boolean to C99 bool
2c55e67aa airtime_policy: Convert Boolean to C99 bool
f75a0339d state_machine: Convert Boolean to C99 bool
0365458eb HE: Replace Boolean with C99 bool
5e5eb5a31 MACsec: Convert Boolean to C99 bool
d15e109e2 EAP peer: Convert Boolean to C99 bool
c9d70dd32 RSN supp: Convert Boolean to C99 bool
da8478a1a EAPOL supp: Convert Boolean to C99 bool
37e3501bf FST: Convert Boolean to C99 bool
3dc69721e EAPOL auth: Convert Boolean to C99 bool
56024a233 WPA auth: Convert Boolean to C99 bool
4d9c313f2 WPA: Fix wpa_parse_kde_ies() handling with vendor specific elements
1025a9052 Sync with mac80211-next.git include/uapi/linux/nl80211.h

Change-Id: I4fc553d84810ba82fdc626767c2e8a5640e4ca51
diff --git a/src/rsn_supp/preauth.c b/src/rsn_supp/preauth.c
index a101921..d4d1307 100644
--- a/src/rsn_supp/preauth.c
+++ b/src/rsn_supp/preauth.c
@@ -252,9 +252,9 @@
 	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);
diff --git a/src/rsn_supp/wpa.c b/src/rsn_supp/wpa.c
index 3ce5327..33e7f41 100644
--- a/src/rsn_supp/wpa.c
+++ b/src/rsn_supp/wpa.c
@@ -818,11 +818,11 @@
 		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
@@ -1723,7 +1723,7 @@
 		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);
 
@@ -2696,7 +2696,8 @@
 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) {
@@ -2705,12 +2706,9 @@
 	} 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"
@@ -2913,7 +2911,7 @@
 		 * 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 */