3 Commits

Author SHA1 Message Date
cc55da831b release v1.4.1 2016-11-15 15:15:45 +01:00
848b01e53c Merge remote-tracking branch 'gh/split-wtp-patches' 2016-11-15 12:07:27 +01:00
890a2af6bb split STA deletion into immediate and delayed action
When sending a DeAuthentication frame to a STA we have to wait
a bit to make sure the driver has actually delivered the frame.
Once we get the DeAuthetication frame from a STA, we can stop
waiting and delete the STA.
2016-11-11 13:32:44 +01:00
2 changed files with 28 additions and 11 deletions

View File

@ -3,6 +3,15 @@ FreeWTP
Open Source CAPWAP WTP implementation
Version 1.4.1 - 15 Nov 2016
---------------------------
* fix endianness buf in RSNE processing
* command line fixes/enhances
* updated kernel patches for plain upstream and OpenWRT/LEDE
* remove some left over references to SmartCAPWAP
* fix STA removal (make sure the DeAuthentication frame is sent)
Version 1.4.0 - 22 Aug 2016
---------------------------

View File

@ -387,6 +387,20 @@ static void wifi_station_clean(struct wifi_station* station)
station->supportedratescount = 0;
}
/* */
static void wifi_station_schedule_delete(struct wifi_station* station)
{
ASSERT(station != NULL);
/* */
log_printf(LOG_INFO, "Schedule Delete station: " MACSTR, MAC2STR(station->address));
/* Delay delete station */
station->timeout_action = WIFI_STATION_TIMEOUT_ACTION_DELETE;
station->timeout.repeat = WIFI_STATION_TIMEOUT_AFTER_DEAUTHENTICATED / 1000.0;
ev_timer_again(EV_DEFAULT_UC_ &station->timeout);
}
/* */
static void wifi_station_delete(struct wifi_station* station)
{
@ -395,13 +409,9 @@ static void wifi_station_delete(struct wifi_station* station)
/* */
log_printf(LOG_INFO, "Delete station: " MACSTR, MAC2STR(station->address));
/* */
/* Free station into hash callback function */
wifi_station_clean(station);
/* Delay delete station */
station->timeout_action = WIFI_STATION_TIMEOUT_ACTION_DELETE;
station->timeout.repeat = WIFI_STATION_TIMEOUT_AFTER_DEAUTHENTICATED / 1000.0;
ev_timer_again(EV_DEFAULT_UC_ &station->timeout);
capwap_hash_delete(g_wifiglobal.stations, station->address);
}
/* */
@ -508,7 +518,7 @@ static void wifi_wlan_deauthentication_station(struct wifi_wlan* wlan,
wifi_wlan_send_mgmt_deauthentication(wlan, station->address, reasoncode);
/* delete station */
wifi_station_delete(station);
wifi_station_schedule_delete(station);
}
/* */
@ -585,9 +595,7 @@ static void wifi_station_timeout(EV_P_ ev_timer *w, int revents)
station->timeout_action);
if (station->timeout_action == WIFI_STATION_TIMEOUT_ACTION_DELETE) {
/* Free station into hash callback function */
wifi_station_clean(station);
capwap_hash_delete(g_wifiglobal.stations, station->address);
wifi_station_delete(station);
return;
}
@ -1574,7 +1582,7 @@ wifi_wlan_receive_ac_mgmt_deauthentication(struct wifi_wlan* wlan,
/* Delete station */
station = wifi_station_get(wlan, frame->da);
if (station)
wifi_station_delete(station);
wifi_station_schedule_delete(station);
return 1;
}