]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
FT: Make FT-over-DS configurable (hostapd.conf ft_over_ds=0/1)
authorShan Palanisamy <Shan.Palanisamy@Atheros.com>
Mon, 25 Oct 2010 10:35:51 +0000 (13:35 +0300)
committerJouni Malinen <j@w1.fi>
Sun, 6 Mar 2011 12:31:42 +0000 (14:31 +0200)
hostapd/config_file.c
src/ap/ap_config.c
src/ap/ap_config.h
src/ap/wpa_auth.h
src/ap/wpa_auth_ft.c
src/ap/wpa_auth_glue.c

index 4b9d0978333a902d6ac7fd1616f01eed2190bda9..e89205972e8d18940242f4dd28cd7d3679262665 100644 (file)
@@ -1673,6 +1673,8 @@ struct hostapd_config * hostapd_config_read(const char *fname)
                        }
                } else if (os_strcmp(buf, "pmk_r1_push") == 0) {
                        bss->pmk_r1_push = atoi(pos);
+               } else if (os_strcmp(buf, "ft_over_ds") == 0) {
+                       bss->ft_over_ds = atoi(pos);
 #endif /* CONFIG_IEEE80211R */
 #ifndef CONFIG_NO_CTRL_IFACE
                } else if (os_strcmp(buf, "ctrl_interface") == 0) {
index a4036243117b85e9846f8c602003e533c5b113e0..3fd82763fc80493300f0c2b4b30f0db148f1177c 100644 (file)
@@ -89,6 +89,10 @@ void hostapd_config_defaults_bss(struct hostapd_bss_config *bss)
 
        /* Set to -1 as defaults depends on HT in setup */
        bss->wmm_enabled = -1;
+
+#ifdef CONFIG_IEEE80211R
+       bss->ft_over_ds = 1;
+#endif /* CONFIG_IEEE80211R */
 }
 
 
index cdc676af2d47350ec7bf73e9556b83f3576e2d64..0016a7c9b78f35ee7eb52302837faea54b78b5d9 100644 (file)
@@ -232,6 +232,7 @@ struct hostapd_bss_config {
        struct ft_remote_r0kh *r0kh_list;
        struct ft_remote_r1kh *r1kh_list;
        int pmk_r1_push;
+       int ft_over_ds;
 #endif /* CONFIG_IEEE80211R */
 
        char *ctrl_interface; /* directory for UNIX domain sockets */
index d0136c71b6665217563665a0b22abc9862414496..52ef2573cf40c574cfd1b51c4e7add281e8e38ac 100644 (file)
@@ -160,6 +160,7 @@ struct wpa_auth_config {
        struct ft_remote_r0kh *r0kh_list;
        struct ft_remote_r1kh *r1kh_list;
        int pmk_r1_push;
+       int ft_over_ds;
 #endif /* CONFIG_IEEE80211R */
 };
 
index 6631d23cec48eadcc3d351062c6ccb8dcc7f4a1f..65f5f4caa7f576b22e83b6e6ef86bb78bd98d9c9 100644 (file)
@@ -92,7 +92,9 @@ int wpa_write_mdie(struct wpa_auth_config *conf, u8 *buf, size_t len)
        *pos++ = MOBILITY_DOMAIN_ID_LEN + 1;
        os_memcpy(pos, conf->mobility_domain, MOBILITY_DOMAIN_ID_LEN);
        pos += MOBILITY_DOMAIN_ID_LEN;
-       capab = RSN_FT_CAPAB_FT_OVER_DS;
+       capab = 0;
+       if (conf->ft_over_ds)
+               capab |= RSN_FT_CAPAB_FT_OVER_DS;
        *pos++ = capab;
 
        return pos - buf;
index bd97678a7c4fba825785078afd5833bdd2536a82..a6ce4c8435ca40682a91a847f4c2d63381ea8045 100644 (file)
@@ -71,6 +71,7 @@ static void hostapd_wpa_auth_conf(struct hostapd_bss_config *conf,
        wconf->r0kh_list = conf->r0kh_list;
        wconf->r1kh_list = conf->r1kh_list;
        wconf->pmk_r1_push = conf->pmk_r1_push;
+       wconf->ft_over_ds = conf->ft_over_ds;
 #endif /* CONFIG_IEEE80211R */
 }