Multi-AP: Honor wds_sta even with multi_ap

When multi_ap is active, hostapd creates an AP-VLAN interface for 4addr
stations, even though wds_sta is not configured.

A check should be added to determine if wds_sta is active before
re-enabling the WDS mode by creating an AP-VLAN for 4addr stations.

Signed-off-by: Baligh Gasmi <gasmibal@gmail.com>
This commit is contained in:
gasmibal@gmail.com 2024-04-28 21:47:21 +02:00 committed by Jouni Malinen
parent 90344c323e
commit 93a3c59ad9
2 changed files with 2 additions and 0 deletions

View file

@ -6647,6 +6647,7 @@ static void handle_assoc_cb(struct hostapd_data *hapd,
if ((sta->flags & WLAN_STA_WDS) ||
(sta->flags & WLAN_STA_MULTI_AP &&
(hapd->conf->multi_ap & BACKHAUL_BSS) &&
hapd->conf->wds_sta &&
!(sta->flags & WLAN_STA_WPS))) {
int ret;
char ifname_wds[IFNAMSIZ + 1];

View file

@ -235,6 +235,7 @@ void ap_free_sta(struct hostapd_data *hapd, struct sta_info *sta)
if ((sta->flags & WLAN_STA_WDS) ||
(sta->flags & WLAN_STA_MULTI_AP &&
(hapd->conf->multi_ap & BACKHAUL_BSS) &&
hapd->conf->wds_sta &&
!(sta->flags & WLAN_STA_WPS)))
hostapd_set_wds_sta(hapd, NULL, sta->addr, sta->aid, 0);