Bug#287220: wpa_supplicant and unkown open AP

Norbert Preining preining
Tue Mar 29 22:40:53 PST 2005


On Mon, 21 M?r 2005, preining wrote:
> Ok, so it was too simple. Well, I will look into the code and see what
> has happened. The problem is that I don't have an AP around here to test
> it, grrr.

SUCCESS!! Ok, at least for *me* it did work with the attached patch. I
don't know when the other function is called, but I found the place
where it is really usefull to add the patch.

Here in my flat it worked ...

See attached diff

Best wishes

Norbert

-------------------------------------------------------------------------------
Norbert Preining <preining AT logic DOT at>                 Universit? di Siena
sip:preining at at43.tuwien.ac.at                             +43 (0) 59966-690018
gpg DSA: 0x09C5B094      fp: 14DF 2E6C 0307 BE6D AD76  A9C0 D2BF 4AA3 09C5 B094
-------------------------------------------------------------------------------
GREAT WAKERING (participial vb.)
Panic which sets in when you badly need to go to the lavatory and
cannot make up your mind about what book or magazine to take with you.
			--- Douglas Adams, The Meaning of Liff
-------------- next part --------------
--- wpa_supplicant.c.orig	2005-03-30 08:35:18.000000000 +0200
+++ wpa_supplicant.c	2005-03-30 08:34:10.000000000 +0200
@@ -1756,6 +1756,26 @@
 				break;
 			}
 		}
+		/* scan for ssid=* */
+		for (ssid = group; ssid; ssid = ssid->pnext) {
+			if (ssid->ssid_len == 1 &&
+			    memcmp(ssid->ssid,"*",1) == 0
+			    &&
+			    (!ssid->bssid_set ||
+			     memcmp(bss->bssid, ssid->bssid, ETH_ALEN) == 0) &&
+			    ((ssid->key_mgmt & WPA_KEY_MGMT_NONE) ||
+			     (ssid->key_mgmt & WPA_KEY_MGMT_IEEE8021X_NO_WPA)))
+			{
+				selected = bss;
+				*selected_ssid = ssid;
+				wpa_printf(MSG_DEBUG, "   selected non-WPA DEFAULT AP "
+					   MACSTR " ssid='%s'",
+					   MAC2STR(bss->bssid),
+					   wpa_ssid_txt(bss->ssid,
+						        bss->ssid_len));
+				break;
+			}
+		}
 	}
 
 	return selected;



More information about the Hostap mailing list