Parcourir la source

WPS: Set correct Device Password ID in M2

It looks like we don't set correspondent Device Password ID attribute in
M2 message during PBC registration. Without it TG185n STA was not able
to connect to our AP in PBC mode. Attached patch fixes this.
Andriy Tkachuk il y a 16 ans
Parent
commit
25e31cccbe
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      src/wps/wps_registrar.c

+ 1 - 1
src/wps/wps_registrar.c

@@ -1117,7 +1117,7 @@ static struct wpabuf * wps_build_m2(struct wps_data *wps)
 	    wps_build_rf_bands(&wps->wps->dev, msg) ||
 	    wps_build_assoc_state(wps, msg) ||
 	    wps_build_config_error(msg, WPS_CFG_NO_ERROR) ||
-	    wps_build_dev_password_id(msg, DEV_PW_DEFAULT) ||
+	    wps_build_dev_password_id(msg, wps->dev_pw_id) ||
 	    wps_build_os_version(&wps->wps->dev, msg) ||
 	    wps_build_authenticator(wps, msg)) {
 		wpabuf_free(msg);