Re: [PATCH] WPS: Use shorter authentication timeout during no-SelReg iteration for PBC mode

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Apr 12, 2018 at 11:48:29AM +0200, Michael Olbrich wrote:
> 5add4101626b23c11f073630770896465d9cc8f3 ('WPS: Use shorter authentication
> timeout during no-SelReg iteration') introduced the shorter timeout for PIN
> mode.
> A shorter timeout in PBC mode is useful for P2P. This allows authentication
> retries after lost packages, before the group formation times out.

Oh, and retries only happen if I increase P2P_MAX_INITIAL_CONN_WAIT. I've
considered reducing the authentication timeout instead for P2P, but I
don't know how to detect P2P here. Any ideas?

Michael

> Signed-off-by: Michael Olbrich <m.olbrich@xxxxxxxxxxxxxx>
> ---
> 
> I'm not sure if this is the correct fix. I want to avoid the 70 seconds
> timeout for P2P and this seemed the cleanest way to achieve this.
> 
> Michael
> 
>  wpa_supplicant/wpa_supplicant.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c
> index 2c5d83cb2a84..1b4d45fe9e77 100644
> --- a/wpa_supplicant/wpa_supplicant.c
> +++ b/wpa_supplicant/wpa_supplicant.c
> @@ -3920,7 +3920,8 @@ void wpa_supplicant_rx_eapol(void *ctx, const u8 *src_addr,
>  #ifdef CONFIG_WPS
>  		if (wpa_s->current_ssid && wpa_s->current_bss &&
>  		    (wpa_s->current_ssid->key_mgmt & WPA_KEY_MGMT_WPS) &&
> -		    eap_is_wps_pin_enrollee(&wpa_s->current_ssid->eap)) {
> +		    (eap_is_wps_pbc_enrollee(&wpa_s->current_ssid->eap) ||
> +		     eap_is_wps_pin_enrollee(&wpa_s->current_ssid->eap))) {
>  			/*
>  			 * Use shorter timeout if going through WPS AP iteration
>  			 * for PIN config method with an AP that does not
> -- 
> 2.16.1
> 
> 
> _______________________________________________
> Hostap mailing list
> Hostap@xxxxxxxxxxxxxxxxxxx
> http://lists.infradead.org/mailman/listinfo/hostap
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
Hostap mailing list
Hostap@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/hostap



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux