diff mbox

Interworking: don't filter probe requests when interworking is disabled.

Message ID 1398286081-29454-1-git-send-email-mbizon@freebox.fr
State Superseded
Headers show

Commit Message

Maxime Bizon April 23, 2014, 8:48 p.m. UTC
With hidden SSID (ignore_broadcast_ssid), an IOS device trying to
connect to the AP will send a probe request with ANT == 2.

If interworking support is just compiled (not enabled), we will drop
the probe request since default ANT is 0.

Check that interworking is enabled before filtering to match the
behaviour of code without CONFIG_INTERWORKING
---
 src/ap/beacon.c |    2 ++
 1 file changed, 2 insertions(+)
diff mbox

Patch

diff --git a/src/ap/beacon.c b/src/ap/beacon.c
index e06ce77..16685c7 100644
--- a/src/ap/beacon.c
+++ b/src/ap/beacon.c
@@ -603,6 +603,7 @@  void handle_probe_req(struct hostapd_data *hapd,
 	if (elems.interworking && elems.interworking_len >= 1) {
 		u8 ant = elems.interworking[0] & 0x0f;
 		if (ant != INTERWORKING_ANT_WILDCARD &&
+		    hapd->conf->interworking &&
 		    ant != hapd->conf->access_network_type) {
 			wpa_printf(MSG_MSGDUMP, "Probe Request from " MACSTR
 				   " for mismatching ANT %u ignored",
@@ -619,6 +620,7 @@  void handle_probe_req(struct hostapd_data *hapd,
 		else
 			hessid = elems.interworking + 1 + 2;
 		if (!is_broadcast_ether_addr(hessid) &&
+		    hapd->conf->interworking &&
 		    os_memcmp(hessid, hapd->conf->hessid, ETH_ALEN) != 0) {
 			wpa_printf(MSG_MSGDUMP, "Probe Request from " MACSTR
 				   " for mismatching HESSID " MACSTR