[patch] Can't pass Wi-Fi WPS Test Plan.

Masashi Honma honma
Wed Jan 21 22:39:54 PST 2009


I can't pass the "Wi-Fi WPS Test Plan Version 1.0 [5.1.4. Add to AP using PIN Config method and PASS PHRASE through wired external registrar]". The wpa_supplicant-0.6.7 can't recoginize the testbed AP(BCM94704AGRRev-E.2.4) as WPS PIN AP. Because after PIN entered, the AP sends Selected Registrar attribute=0 and not send Device Password ID attribute.

Both attributes are optional on beacon and probe response on specification. So I think
1. Selected registrar=1 should not be checked on PIN. Because when Enrollee will try to start Registration protocol with not ready Registrar, the Registrar will response M2D message. On PBC, the check needed for multi PBC detection.

2. Device password id attribute should be checked if it exists. Because it is optional.

Below is patch for wpa_supplicant 0.6.7.

diff wpa_supplicant-0.6.7/src/wps/wps.c wpa_supplicant-0.6.7/src/wps/wps.c.bak

<  * wps_is_selected_pin_registrar - Check whether WPS IE indicates active PIN
>  * wps_is_selected_pbc_registrar - Check whether WPS IE indicates active PIN
< 	if (wps_parse_msg(msg, &attr) < 0)
< 		return 0;
< 	if (attr.dev_password_id != NULL &&
< 		WPA_GET_BE16(attr.dev_password_id) == DEV_PW_PUSHBUTTON)
> 	if (wps_parse_msg(msg, &attr) < 0 ||
> 	    !attr.selected_registrar || *attr.selected_registrar == 0 ||
> 	    !attr.dev_password_id ||
> 	    WPA_GET_BE16(attr.dev_password_id) == DEV_PW_PUSHBUTTON)

Masashi Honma.

More information about the Hostap mailing list