[PATCH] wext: really disassociate

Jouni Malinen j at w1.fi
Sun Feb 8 12:47:08 EST 2009


On Fri, Feb 06, 2009 at 04:16:34PM -0500, Dan Williams wrote:

> Really disassociate when tearing stuff down; drivers may sometimes
> (legally) keep trying to reassociate unless the BSSID is unlocked.  If
> the SSID is unlocked too, under WEXT drivers are able to pick an SSID to
> associate, so kill that behavior by setting a bogus SSID.  Unfortunately
> WEXT doesn't provide an easy method to say "stop whatever doing and just
> idle".

> diff --git a/src/drivers/driver_wext.c b/src/drivers/driver_wext.c
> @@ -1911,9 +1911,24 @@ static int wpa_driver_wext_disassociate(void *priv, const u8 *addr,

> +	ret = wpa_driver_wext_mlme(drv, addr, IW_MLME_DISASSOC,
> +	                           reason_code);
> +	if (ret == 0) {

Why do the random-SSID thing only if SIOCSIWMLME succeeds? I would
expect that there are drivers that do not implement SIOCSIWMLME and
they could benefit even more about the SSID change. Furthermore,
shouldn't this same code be used in wpa_driver_wext_deauthenticate(),
too?

-- 
Jouni Malinen                                            PGP id EFC895FA


More information about the HostAP mailing list