Message ID | CAF4y=ytjrr_etYASMyv-X=bXd2xAmmCxAc-9ce=xO0Q36+X_ZA@mail.gmail.com |
---|---|
State | Changes Requested |
Headers | show |
Series | nl80211: Donot use external_auth when driver does not support | expand |
On Sun, Nov 10, 2019 at 03:19:19PM +0530, Nishant Chaprana wrote: > diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c > @@ -2465,7 +2465,8 @@ static int > nl80211_mgmt_subscribe_ap_dev_sme(struct i802_bss *bss) > if (nl80211_action_subscribe_ap(bss)) > goto out_err; > > - if (bss->drv->device_ap_sme) { > + if (bss->drv->device_ap_sme && > + (bss->drv->capa.flags & WPA_DRIVER_FLAGS_SME)) { > u16 type = (WLAN_FC_TYPE_MGMT << 2) | (WLAN_FC_STYPE_AUTH << 4); > > /* Register for all Authentication frames */ Could you please clarify why this would be needed and why WPA_DRIVER_FLAGS_SME is used here? That flag indicates that the driver uses wpa_supplicant SME in station mode and as such, is not really supposed to be used for determining how to behave in AP mode. What exactly does this fix? Are you sure this does not break SAE in AP mode with drivers that need to use hostapd to perform SAE authentication?
On Fri, Feb 28, 2020 at 10:47:01PM +0530, Nishant Chaprana wrote: > This patch fixes the issue when P2P GO was created and peer was unable to > connect to that GO. After some analysis about p2p connection issue, I found > that my driver didnot support external authentication. Peer P2P device was > unable to join the connection, so I made this patch to not to perform > external authentication when driver doesnot support it using this flag. > > I think this check should not break existing functionality in SAE mode. This sounds really strange.. external_auth is used only for SAE, but P2P does not use SAE. There is something quite wrong here since the external authentication mechanism should not come into play at all when a P2P GO goes through authentication and association. Can you please provide a wpa_supplicant debug log from the GO showing the details on what fails?
diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 4c8dcad8d..3d39a817d 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -2465,7 +2465,8 @@ static int nl80211_mgmt_subscribe_ap_dev_sme(struct i802_bss *bss) if (nl80211_action_subscribe_ap(bss)) goto out_err; - if (bss->drv->device_ap_sme) { + if (bss->drv->device_ap_sme && + (bss->drv->capa.flags & WPA_DRIVER_FLAGS_SME)) { u16 type = (WLAN_FC_TYPE_MGMT << 2) | (WLAN_FC_STYPE_AUTH << 4);
Signed-off-by: Nishant Chaprana <nishantchaprana@gmail.com> --- src/drivers/driver_nl80211.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) /* Register for all Authentication frames */ -- 2.17.1