mirror of
https://github.com/vanhoefm/fragattacks.git
synced 2025-02-17 17:43:06 -05:00
nl80211: Do not add all virtual interfaces to drv->if_indices
Commit 04eff7d5ba96b5b452e4e1a70db3af6668762b08 or something around that timeframe may have caused a regression on how drv->if_indices gets used with wpa_supplicant. Most (curretly likely all) wpa_supplicant virtual interface use cases should not actually use this. This could result in issues with P2P group interfaces delivering events to incorrect interface (parent rather than the group interface). The previous commit removed some of the issues, but more complete fix is to undo some of those merged hostapd/wpa_supplicant operations. Filter add_ifidx() uses based on hostapd vs. wpa_supplicant and iftype to get closer to the earlier wpa_supplicant behavior for the driver events from virtual interfaces. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
de88430311
commit
147848ec4d
@ -7811,8 +7811,17 @@ static int nl80211_create_iface_once(struct wpa_driver_nl80211_data *drv,
|
|||||||
if (ifidx <= 0)
|
if (ifidx <= 0)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
/* start listening for EAPOL on this interface */
|
/*
|
||||||
add_ifidx(drv, ifidx);
|
* Some virtual interfaces need to process EAPOL packets and events on
|
||||||
|
* the parent interface. This is used mainly with hostapd.
|
||||||
|
*/
|
||||||
|
if (drv->hostapd ||
|
||||||
|
iftype == NL80211_IFTYPE_AP_VLAN ||
|
||||||
|
iftype == NL80211_IFTYPE_WDS ||
|
||||||
|
iftype == NL80211_IFTYPE_MONITOR) {
|
||||||
|
/* start listening for EAPOL on this interface */
|
||||||
|
add_ifidx(drv, ifidx);
|
||||||
|
}
|
||||||
|
|
||||||
if (addr && iftype != NL80211_IFTYPE_MONITOR &&
|
if (addr && iftype != NL80211_IFTYPE_MONITOR &&
|
||||||
linux_set_ifhwaddr(drv->global->ioctl_sock, ifname, addr)) {
|
linux_set_ifhwaddr(drv->global->ioctl_sock, ifname, addr)) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user