From: Mathieu Olivari <math...@qca.qualcomm.com>

This is required explicitly for WPS 2.0 testing.

Signed-off-by: Mathieu Olivari <math...@qca.qualcomm.com>
Signed-off-by: Sujith Manoharan <c_man...@qca.qualcomm.com>
Signed-off-by: Luis R. Rodriguez <mcg...@qca.qualcomm.com>
---
 package/network/services/hostapd/files/hostapd.sh |   11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/package/network/services/hostapd/files/hostapd.sh 
b/package/network/services/hostapd/files/hostapd.sh
index ce0f227..56e6eb0 100644
--- a/package/network/services/hostapd/files/hostapd.sh
+++ b/package/network/services/hostapd/files/hostapd.sh
@@ -190,6 +190,17 @@ hostapd_set_bss_options() {
        config_get config_methods "$vif" wps_config
        [ "$wps_pbc" -gt 0 ] && append config_methods push_button
 
+       # For WPS 2.0 testing, the testing requires this as a feature.
+       # If we're configured to enable WPS and we hide our SSID, then
+       # we have to require an "explicit user operation to continue"
+       config_get_bool hidden "$vif" hidden 0
+       [ -n "$wps_possible" -a -n "$config_methods" -a "$hidden" -gt 0 ] && {
+               echo "Hidden SSID is enabled on \"$ifname\", WPS will be 
automatically disabled"
+               echo "Please press any key to continue."
+               read -s -n 1
+               wps_possible=
+       }
+
        [ -n "$wps_possible" -a -n "$config_methods" ] && {
                config_get device_type "$vif" wps_device_type "6-0050F204-1"
                config_get device_name "$vif" wps_device_name "OpenWrt AP"
-- 
1.7.10.4
_______________________________________________
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel

Reply via email to