Re: How to disassociate a station from an user space program?


From: Jouni Malinen (jkmaline_at_cc.hut.fi)
Date: 2002-09-09 17:56:03 UTC



On Mon, Sep 09, 2002 at 02:54:01PM +0200, Victor Aleo wrote:

> My question is: How can I do that? I have installed succesfully the
> Prism2-2002-05-19 driver and my WLAN card works right. I thought that I
> could use the Wireless Extensions functions, but I have not found any
> function there to disassociate a station. Then, I guess the only way is
> to use the functions provided by the hostapd.c but there is no any
> function to disassociate a station neither. Is that right?

To disassociate (and also deauthenticate) a station:

iwpriv wlan0 kickmac <hwaddr>

However, the station will probably authenticate and associate again immediately after this, so you would first need to deny this with:

iwpriv wlan0 maccmd 2
iwpriv wlan0 addmac <hwaddr>

You can get statistics from /proc/net/prism2/wlan0/<hwaddr> (or /proc/net/hostap/wlan0/<hwaddr> in CVS snapshot version).

hostapd does not yet have an API for doing this kind of management operations. Please also note, that CVS version has change quite a bit after 2002-05-19 release and I would recommend using the latest snapshot version, especially with hostapd.

-- 
Jouni Malinen                                            PGP id EFC895FA


This archive was generated by hypermail 2.1.4.