aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/wps_supplicant.c
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2009-11-21 13:34:23 +0200
committerJouni Malinen <j@w1.fi>2009-11-21 13:34:23 +0200
commite694b34474374c02aac98a11d3b9a7420229fa0c (patch)
treeef2a28fa6276c34c19f151e1ca20698d8bb8b5ab /wpa_supplicant/wps_supplicant.c
parentc3016248f4dff687e313c4aea978313ea139771b (diff)
downloadexternal_wpa_supplicant_8_ti-e694b34474374c02aac98a11d3b9a7420229fa0c.zip
external_wpa_supplicant_8_ti-e694b34474374c02aac98a11d3b9a7420229fa0c.tar.gz
external_wpa_supplicant_8_ti-e694b34474374c02aac98a11d3b9a7420229fa0c.tar.bz2
WPS ER: Add more AP information into the ctrl_interface message
This allow wpa_gui to show AP BSSID, WPS State (configured/unconfigured), and primary device type.
Diffstat (limited to 'wpa_supplicant/wps_supplicant.c')
-rw-r--r--wpa_supplicant/wps_supplicant.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/wpa_supplicant/wps_supplicant.c b/wpa_supplicant/wps_supplicant.c
index 28b961c..dc989d9 100644
--- a/wpa_supplicant/wps_supplicant.c
+++ b/wpa_supplicant/wps_supplicant.c
@@ -414,9 +414,20 @@ static void wpa_supplicant_wps_event_er_ap_add(struct wpa_supplicant *wpa_s,
struct wps_event_er_ap *ap)
{
char uuid_str[100];
+ char dev_type[20];
+
uuid_bin2str(ap->uuid, uuid_str, sizeof(uuid_str));
- wpa_msg(wpa_s, MSG_INFO, WPS_EVENT_ER_AP_ADD "%s|%s|%s|%s|%s|%s|%s",
- uuid_str,
+ if (ap->pri_dev_type)
+ os_snprintf(dev_type, sizeof(dev_type), "%u-%08X-%u",
+ WPA_GET_BE16(ap->pri_dev_type),
+ WPA_GET_BE32(ap->pri_dev_type + 2),
+ WPA_GET_BE16(ap->pri_dev_type + 6));
+ else
+ dev_type[0] = '\0';
+
+ wpa_msg(wpa_s, MSG_INFO, WPS_EVENT_ER_AP_ADD "%s " MACSTR
+ " pri_dev_type=%s wps_state=%d |%s|%s|%s|%s|%s|%s|",
+ uuid_str, MAC2STR(ap->mac_addr), dev_type, ap->wps_state,
ap->friendly_name ? ap->friendly_name : "",
ap->manufacturer ? ap->manufacturer : "",
ap->model_description ? ap->model_description : "",