]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
hostapd: Add current wpa parameter into GET_CONFIG output
authorMohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Thu, 25 Jun 2015 12:42:49 +0000 (18:12 +0530)
committerJouni Malinen <j@w1.fi>
Fri, 17 Jul 2015 21:17:34 +0000 (00:17 +0300)
This can be used, e.g., by an action script to update new WPS
settings for the AP.

Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
hostapd/ctrl_iface.c

index 9f745f4956a7025b389f7912b8799521e3e5e622..5ef35979e6ac62992b36ae3e6903664222ec4cd7 100644 (file)
@@ -1107,6 +1107,13 @@ static int hostapd_ctrl_iface_get_config(struct hostapd_data *hapd,
        }
 #endif /* CONFIG_WPS */
 
+       if (hapd->conf->wpa) {
+               ret = os_snprintf(pos, end - pos, "wpa=%d\n", hapd->conf->wpa);
+               if (os_snprintf_error(end - pos, ret))
+                       return pos - buf;
+               pos += ret;
+       }
+
        if (hapd->conf->wpa && hapd->conf->wpa_key_mgmt) {
                ret = os_snprintf(pos, end - pos, "key_mgmt=");
                if (os_snprintf_error(end - pos, ret))