aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant/bss.c
diff options
context:
space:
mode:
authorWitold Sowa <witold.sowa@gmail.com>2010-01-16 14:37:37 (GMT)
committerJouni Malinen <j@w1.fi>2010-01-16 14:37:37 (GMT)
commit7899e2f42d91336393ec464fc85b57bd9e1cf1d5 (patch)
tree8052fb48e55efc24d56f0d87b60cf27e3eaaee40 /wpa_supplicant/bss.c
parent8c0906542c06d862ffae10e2984330b28ed505a6 (diff)
downloadhostap-7899e2f42d91336393ec464fc85b57bd9e1cf1d5.zip
hostap-7899e2f42d91336393ec464fc85b57bd9e1cf1d5.tar.gz
hostap-7899e2f42d91336393ec464fc85b57bd9e1cf1d5.tar.bz2
dbus: Change WPA/RSNIE byte array props to dicts
Expose RSN and WPA properties for BSS objects containing information about key management and cipher suites. Get rid of WPA/RSN/WPSIE byte array properties and add IEs byte array property with all IE data instead.
Diffstat (limited to 'wpa_supplicant/bss.c')
-rw-r--r--wpa_supplicant/bss.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/wpa_supplicant/bss.c b/wpa_supplicant/bss.c
index 414fa35..d5bb040 100644
--- a/wpa_supplicant/bss.c
+++ b/wpa_supplicant/bss.c
@@ -60,6 +60,7 @@
#define WPA_BSS_RSNIE_CHANGED_FLAG BIT(5)
#define WPA_BSS_WPS_CHANGED_FLAG BIT(6)
#define WPA_BSS_RATES_CHANGED_FLAG BIT(7)
+#define WPA_BSS_IES_CHANGED_FLAG BIT(8)
static void wpa_bss_remove(struct wpa_supplicant *wpa_s, struct wpa_bss *bss)
@@ -217,6 +218,11 @@ static u32 wpa_bss_compare_res(const struct wpa_bss *old,
if (caps_diff & IEEE80211_CAP_IBSS)
changes |= WPA_BSS_MODE_CHANGED_FLAG;
+ if (old->ie_len == new->ie_len &&
+ os_memcmp(old + 1, new + 1, old->ie_len) == 0)
+ return changes;
+ changes |= WPA_BSS_IES_CHANGED_FLAG;
+
if (!are_ies_equal(old, new, WPA_IE_VENDOR_TYPE))
changes |= WPA_BSS_WPAIE_CHANGED_FLAG;
@@ -258,6 +264,9 @@ static void notify_bss_changes(struct wpa_supplicant *wpa_s, u32 changes,
if (changes & WPA_BSS_WPS_CHANGED_FLAG)
wpas_notify_bss_wps_changed(wpa_s, bss->id);
+ if (changes & WPA_BSS_IES_CHANGED_FLAG)
+ wpas_notify_bss_ies_changed(wpa_s, bss->id);
+
if (changes & WPA_BSS_RATES_CHANGED_FLAG)
wpas_notify_bss_rates_changed(wpa_s, bss->id);
}