From patchwork Sun Nov 18 22:18:58 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jouni Malinen X-Patchwork-Id: 999588 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="IEb4yZ6M"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="M7bFMMBJ"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=codeaurora.org header.i=@codeaurora.org header.b="FezdmN07"; dkim=neutral (0-bit key) header.d=codeaurora.org header.i=@codeaurora.org header.b="boSILO/W"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42ymfT39X3z9s3q for ; Mon, 19 Nov 2018 09:21:49 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=Wsash5tfEeci0JLnKidUBJycBsGldZx07gmVBkWBEEw=; b=IEb 4yZ6Mp4focbTnNrHah3/YNsXfxz1v0l6J4bMLBa2wGbmOXGFE0i2QY8p/nfJCnIR7ETsWChITKmzn kFKJXSnqH9zcTgwiIJUcziLD3NcBy09JAONE7fhyaSCBdXWlejNaIt9vw8R/QzwCmxBjtrfKQ/szI B5b2gtrP2zqOSYCNf70LE06Pt1NBYdcH2uhjexWZhqoadzgyxvHzLh2OPxHf1NRVxSFkJZJqy2hux ro2o0jHQivad6bMm7HdMNqxSx9D1UiW76ocotKMt2iAT6hPWOh0WJDHp6ObWbK4jb2ePg/Y9eQKKg BVGNMH/U7bvcjYJvPXOejeve0CeKscA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVRJ-0002Xh-Ht; Sun, 18 Nov 2018 22:21:13 +0000 Received: from casper.infradead.org ([2001:8b0:10b:1236::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVPk-0001Hc-BU for hostap@bombadil.infradead.org; Sun, 18 Nov 2018 22:19:36 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Message-Id:Date:Subject:Cc:To:From: Sender:Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=iWSWxCOUSlvRAnBZqNs4Ozlg2JZ/iD5+bPPOJ1OiKh4=; b=M7bFMMBJiby9GCOmp8nsWCzYn 484EV3+FoAXy3AtLxR6NjanaWkyJ7q48PjcLCcqxUh7OZd+rBW34/Cf1KJQjwkr/9ySShgofvaFV6 6QRBGzibsbjM9nxBLYooKV5KaJ21N5RC4cF/HWVwFMlB60sP9q+q0rrWmW1yH3YtQDNQJM5W9nnWJ U93wf805OkfQovTfHqE4+QOmUG+MYGxiEbviZqrlJ1GINaB2TgtsTrp+Eu21JgtbR/Ns7FpSVg2O1 fjkHEQ/sgls3PGLvumYukCyN2LFpR+ErCxpDECRdcqkbsiCOHOZJiCxn9riV5K/DU2Wz5C+HP6X0c hbOm2K70A==; Received: from smtp.codeaurora.org ([198.145.29.96]) by casper.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVPg-0005f6-Pu for hostap@lists.infradead.org; Sun, 18 Nov 2018 22:19:34 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 790A360714; Sun, 18 Nov 2018 22:19:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1542579559; bh=KttqrUwE3UBTtT5PeeXgCjv6YE/+UnkpvA7aTupCHBo=; h=From:To:Cc:Subject:Date:From; b=FezdmN07sf4/yyAZMB1jE82p7B6wZ5qQV4nvu51dv9NZlQCWk/tTuZqf78ReI4ChE AR1EpDCrK7QqEKIV6gPO/6Juf1/rs9vPux2lYFs40nRi/t7QgzpL3K3oEGjgMWVg4Y KwDszbX0tZHtWFgQ59z1wMnTDAmQo1tkd6LWMgDk= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_INVALID, DKIM_SIGNED autolearn=no autolearn_force=no version=3.4.0 Received: from jouni.codeaurora.org (37-33-76-121.bb.dnainternet.fi [37.33.76.121]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jouni@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 77F8F60714; Sun, 18 Nov 2018 22:19:17 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1542579558; bh=KttqrUwE3UBTtT5PeeXgCjv6YE/+UnkpvA7aTupCHBo=; h=From:To:Cc:Subject:Date:From; b=boSILO/WjXDTDh3wIbHfyRXmFlvgWsbGOVM0znzTXxhm1E2MczHVp8nz+QtGRiPXY wRIRkY/V8t5xzWU6mPoNSVGEcvsF4q5HburRy9aBP/SuEQ/zzH5AWQAjGq6P+zU7lj hPE0oz/IjNqwa84Q5+5qLNIlS46Q/d/MDbheXVYE= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 77F8F60714 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=jouni@codeaurora.org From: Jouni Malinen To: hostap@lists.infradead.org Subject: [PATCH 1/2] hostapd: Add Multi-AP protocol support Date: Mon, 19 Nov 2018 00:18:58 +0200 Message-Id: <1542579539-16577-1-git-send-email-jouni@codeaurora.org> X-Mailer: git-send-email 2.7.4 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181118_221933_110783_6421B7F5 X-CRM114-Status: GOOD ( 24.16 ) X-Spam-Score: -2.4 (--) X-Spam-Report: SpamAssassin version 3.4.1 on casper.infradead.org summary: Content analysis details: (-2.4 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [198.145.29.96 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-Mailman-Approved-At: Sun, 18 Nov 2018 14:20:57 -0800 X-BeenThere: hostap@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Venkateswara Naralasetty , Jouni Malinen MIME-Version: 1.0 Sender: "Hostap" Errors-To: hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Venkateswara Naralasetty The purpose of Multi-AP specification is to enable inter-operability across Wi-Fi access points (APs) from different vendors. Advertise vendor specific Multi-AP capabilities in (Re)Association response frame, if user enable Multi-AP functionality through configuration parameter.Create one AP/VLAN interface for the client which supports Multi-AP since as per the Multi-AP spec fronthaul AP should receive both 3addr and 4addr frames from the backhaul STA. This patch introducing one new configuration parameter 'multi_ap_enabled' to enable Multi-AP functionlity. Signed-off-by: Venkateswara Naralasetty Signed-off-by: Jouni Malinen --- hostapd/Makefile | 4 +++ hostapd/config_file.c | 13 ++++++++++ hostapd/defconfig | 3 +++ hostapd/hostapd.conf | 7 ++++++ src/ap/ap_config.h | 4 +++ src/ap/ieee802_11.c | 57 +++++++++++++++++++++++++++++++++++++++++- src/ap/sta_info.c | 2 +- src/ap/sta_info.h | 1 + src/common/ieee802_11_common.c | 11 ++++++++ src/common/ieee802_11_common.h | 2 ++ src/common/ieee802_11_defs.h | 25 ++++++++++++++++++ 11 files changed, 127 insertions(+), 2 deletions(-) diff --git a/hostapd/Makefile b/hostapd/Makefile index 2ce8b7d..4db3d34 100644 --- a/hostapd/Makefile +++ b/hostapd/Makefile @@ -61,6 +61,10 @@ CFLAGS += -DCONFIG_NATIVE_WINDOWS LIBS += -lws2_32 endif +ifdef CONFIG_MULTI_AP +CFLAGS += -DCONFIG_MULTI_AP +endif + OBJS += main.o OBJS += config_file.o diff --git a/hostapd/config_file.c b/hostapd/config_file.c index b26da71..72508ab 100644 --- a/hostapd/config_file.c +++ b/hostapd/config_file.c @@ -4111,6 +4111,19 @@ static int hostapd_config_fill(struct hostapd_config *conf, } else if (os_strcmp(buf, "coloc_intf_reporting") == 0) { bss->coloc_intf_reporting = atoi(pos); #endif /* CONFIG_OWE */ +#ifdef CONFIG_MULTI_AP + } else if (os_strcmp(buf, "multi_ap_enabled") == 0) { + int val = atoi(pos); + + if (val > 3 || val < 0) { + wpa_printf(MSG_ERROR, + "Line %d: Invalid multi_ap_enabled '%s'", + line, buf); + return -1; + } + + bss->multi_ap_enabled = val; +#endif /*CONFIG_MULTI_AP */ } else { wpa_printf(MSG_ERROR, "Line %d: unknown configuration item '%s'", diff --git a/hostapd/defconfig b/hostapd/defconfig index c67c662..7746c13 100644 --- a/hostapd/defconfig +++ b/hostapd/defconfig @@ -373,3 +373,6 @@ CONFIG_IPV6=y # Override default value for the wpa_disable_eapol_key_retries configuration # parameter. See that parameter in hostapd.conf for more details. #CFLAGS += -DDEFAULT_WPA_DISABLE_EAPOL_KEY_RETRIES=1 + +#Multi-AP protocol support +#CONFIG_MULTI_AP=y diff --git a/hostapd/hostapd.conf b/hostapd/hostapd.conf index a005217..5a2c4bb 100644 --- a/hostapd/hostapd.conf +++ b/hostapd/hostapd.conf @@ -438,6 +438,13 @@ wmm_ac_vo_txop_limit=47 wmm_ac_vo_acm=0 # Note: for IEEE 802.11b mode: cWmin=3 cWmax=4 burst=102 +#Enable Multi-AP functionality. +#0:default +#1:Enable Multi-AP as BACKHAUL_BSS +#2:Enable Multi-AP as FRONTHAUL_BSS +#3:Enable Multi-AP as BACKHAUL_BSS and FRONTHAUL_BSS +#multi_ap_enabled=0 + # Static WEP key configuration # # The key number to use when transmitting. diff --git a/src/ap/ap_config.h b/src/ap/ap_config.h index 778366d..7fa45f7 100644 --- a/src/ap/ap_config.h +++ b/src/ap/ap_config.h @@ -686,6 +686,10 @@ struct hostapd_bss_config { #endif /* CONFIG_OWE */ int coloc_intf_reporting; + +#ifdef CONFIG_MULTI_AP + int multi_ap_enabled; +#endif /*CONFIG_MULTI_AP */ }; /** diff --git a/src/ap/ieee802_11.c b/src/ap/ieee802_11.c index d2d6b17..d464d82 100644 --- a/src/ap/ieee802_11.c +++ b/src/ap/ieee802_11.c @@ -62,6 +62,34 @@ prepare_auth_resp_fils(struct hostapd_data *hapd, int *is_pub); #endif /* CONFIG_FILS */ +u8 * hostapd_eid_multi_ap(struct hostapd_data *hapd, u8 *eid) +{ + u8 *pos = eid; + +#ifdef CONFIG_MULTI_AP + struct multi_ap_ie *map = (struct multi_ap_ie *) (pos + 2); + int multi_ap_enabled = hapd->conf->multi_ap_enabled; + + if (!multi_ap_enabled) + return eid; + + eid[0] = WLAN_EID_VENDOR_SPECIFIC; + eid[1] = 7; /* len */ + WPA_PUT_BE24(map->oui, OUI_WFA); + map->oui_type = MULTI_AP_OUI_TYPE; + map->sub_elem_id = MULTI_AP_SUB_ELEM_TYPE; + map->sub_elem_len = 0x1; + if (multi_ap_enabled & BACKHAUL_BSS) + map->sub_elem_val |= MULTI_AP_BACKHAUL_BSS; + if (multi_ap_enabled & FRONTHAUL_BSS) + map->sub_elem_val |= MULTI_AP_FRONTHAUL_BSS; + + pos = (u8 *) (map + 1); +#endif /* CONFIG_MULTI_AP */ + + return pos; +} + u8 * hostapd_eid_supp_rates(struct hostapd_data *hapd, u8 *eid) { u8 *pos = eid; @@ -2210,6 +2238,21 @@ static u16 check_wmm(struct hostapd_data *hapd, struct sta_info *sta, return WLAN_STATUS_SUCCESS; } +#ifdef CONFIG_MULTI_AP +static u16 hostapd_validate_multi_ap_ie(struct hostapd_data *hapd, struct sta_info *sta, + const u8 *multi_ap_ie) +{ + sta->flags &= ~WLAN_STA_MULTI_AP; + + if (multi_ap_ie) { + struct multi_ap_ie *map = (struct multi_ap_ie *)multi_ap_ie; + if (map->sub_elem_id != MULTI_AP_SUB_ELEM_TYPE) + return WLAN_STATUS_UNSPECIFIED_FAILURE; + sta->flags |= WLAN_STA_MULTI_AP; + } + return WLAN_STATUS_SUCCESS; +} +#endif /* CONFIG_MULTI_AP */ static u16 copy_supp_rates(struct hostapd_data *hapd, struct sta_info *sta, struct ieee802_11_elems *elems) @@ -2466,6 +2509,15 @@ static u16 check_assoc_ies(struct hostapd_data *hapd, struct sta_info *sta, resp = copy_supp_rates(hapd, sta, &elems); if (resp != WLAN_STATUS_SUCCESS) return resp; + +#ifdef CONFIG_MULTI_AP + if (hapd->conf->multi_ap_enabled) { + resp = hostapd_validate_multi_ap_ie(hapd, sta, elems.multi_ap); + if (resp != WLAN_STATUS_SUCCESS) + return resp; + } +#endif /* CONFIG_MULTI_AP */ + #ifdef CONFIG_IEEE80211N resp = copy_sta_ht_capab(hapd, sta, elems.ht_capabilities); if (resp != WLAN_STATUS_SUCCESS) @@ -2995,6 +3047,9 @@ static u16 send_assoc_resp(struct hostapd_data *hapd, struct sta_info *sta, } #endif /* CONFIG_WPS */ + if (sta && (sta->flags & WLAN_STA_MULTI_AP)) + p = hostapd_eid_multi_ap(hapd, p); + #ifdef CONFIG_P2P if (sta && sta->p2p_ie && hapd->p2p_group) { struct wpabuf *p2p_resp_ie; @@ -4227,7 +4282,7 @@ static void handle_assoc_cb(struct hostapd_data *hapd, sta->flags |= WLAN_STA_WDS; } - if (sta->flags & WLAN_STA_WDS) { + if (sta->flags & (WLAN_STA_WDS | WLAN_STA_MULTI_AP)) { int ret; char ifname_wds[IFNAMSIZ + 1]; diff --git a/src/ap/sta_info.c b/src/ap/sta_info.c index 179cf43..6d683f7 100644 --- a/src/ap/sta_info.c +++ b/src/ap/sta_info.c @@ -166,7 +166,7 @@ void ap_free_sta(struct hostapd_data *hapd, struct sta_info *sta) /* just in case */ ap_sta_set_authorized(hapd, sta, 0); - if (sta->flags & WLAN_STA_WDS) + if (sta->flags & (WLAN_STA_WDS | WLAN_STA_MULTI_AP)) hostapd_set_wds_sta(hapd, NULL, sta->addr, sta->aid, 0); if (sta->ipaddr) diff --git a/src/ap/sta_info.h b/src/ap/sta_info.h index 9cac6f1..2b60e92 100644 --- a/src/ap/sta_info.h +++ b/src/ap/sta_info.h @@ -36,6 +36,7 @@ #define WLAN_STA_VHT_OPMODE_ENABLED BIT(20) #define WLAN_STA_VENDOR_VHT BIT(21) #define WLAN_STA_PENDING_FILS_ERP BIT(22) +#define WLAN_STA_MULTI_AP BIT(23) #define WLAN_STA_PENDING_DISASSOC_CB BIT(29) #define WLAN_STA_PENDING_DEAUTH_CB BIT(30) #define WLAN_STA_NONERP BIT(31) diff --git a/src/common/ieee802_11_common.c b/src/common/ieee802_11_common.c index e1ef277..3f138da 100644 --- a/src/common/ieee802_11_common.c +++ b/src/common/ieee802_11_common.c @@ -126,6 +126,17 @@ static int ieee802_11_parse_vendor_specific(const u8 *pos, size_t elen, elems->roaming_cons_sel = pos; elems->roaming_cons_sel_len = elen; break; + case MULTI_AP_OUI_TYPE: + if (elen < 7) { + wpa_printf(MSG_MSGDUMP, "short Multi-AP " + "information element ignored " + "(len=%lu)", + (unsigned long) elen); + return -1; + } + elems->multi_ap = pos; + elems->multi_ap_len = elen; + break; default: wpa_printf(MSG_MSGDUMP, "Unknown WFA " "information element ignored " diff --git a/src/common/ieee802_11_common.h b/src/common/ieee802_11_common.h index ff7e51d..f602f87 100644 --- a/src/common/ieee802_11_common.h +++ b/src/common/ieee802_11_common.h @@ -84,6 +84,7 @@ struct ieee802_11_elems { const u8 *power_capab; const u8 *roaming_cons_sel; const u8 *password_id; + const u8 *multi_ap; u8 ssid_len; u8 supp_rates_len; @@ -130,6 +131,7 @@ struct ieee802_11_elems { u8 power_capab_len; u8 roaming_cons_sel_len; u8 password_id_len; + u8 multi_ap_len; struct mb_ies_info mb_ies; }; diff --git a/src/common/ieee802_11_defs.h b/src/common/ieee802_11_defs.h index 762e731..c1a3a85 100644 --- a/src/common/ieee802_11_defs.h +++ b/src/common/ieee802_11_defs.h @@ -1210,6 +1210,31 @@ struct ieee80211_ampe_ie { #define MBO_OUI_TYPE 22 #define OWE_IE_VENDOR_TYPE 0x506f9a1c #define OWE_OUI_TYPE 28 +#define MULTI_AP_OUI_TYPE 0x1B + +#ifdef CONFIG_MULTI_AP +#define MULTI_AP_SUB_ELEM_TYPE 0x06 +#define MULTI_AP_BACKHAUL_BSS 0x40 +#define MULTI_AP_FRONTHAUL_BSS 0x20 +#define BACKHAUL_BSS 1 +#define FRONTHAUL_BSS 2 + +/*MAP Information Element (used in (Re)Association Request frames) + */ +struct multi_ap_ie { + /* Element ID: 221 (0xdd); Length: 7 */ + u8 oui[3]; /* OUI_WFA 50:6F:9A */ + u8 oui_type; /* 0x1B */ + u8 sub_elem_id; /* 0x06 */ + u8 sub_elem_len; /* 1 */ + u8 sub_elem_val; /* BIT(7):Backhaul STA + * BIT(6):Backhaul BSS + * BIT(5):Fronthaul BSS + * BIT(3) to BIT(0) reserved + */ + +} STRUCT_PACKED; +#endif /* CONFIG_MULTI_AP */ #define WMM_OUI_TYPE 2 #define WMM_OUI_SUBTYPE_INFORMATION_ELEMENT 0 From patchwork Sun Nov 18 22:18:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jouni Malinen X-Patchwork-Id: 999587 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="l7B8MGCf"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=infradead.org header.i=@infradead.org header.b="QEZ2+BNQ"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=codeaurora.org header.i=@codeaurora.org header.b="RGHAn5tg"; dkim=neutral (0-bit key) header.d=codeaurora.org header.i=@codeaurora.org header.b="GEjLorma"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 42ymfT3F4xz9s7T for ; Mon, 19 Nov 2018 09:21:48 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To:Message-Id:Date:Subject:To:From:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=+d/zw3Nxu9EiqtZuyrBfpbGzMqdIFptryymq3ngvdag=; b=l7B8MGCf+0JT9jkzVj4OQ6pHlT HBKorWi5zeRfLEoep6s04cUCre7+HXZQDgPRffcvH/7rcTmJrSBYvNpB1/zHyJNv+moLaJQBYJSf4 eojmCOfVr2p4FUdNTo1jg3nqARtJKZM2eoxY5LFkozd+FrlPS+bCV7vcJOZ8s+dhU/OzzQKu6mJ4b Ww8Y2uwpc9HA7VwbMX5d7KJ19szOGL/0vOVNhDYC72Vge6+O47mvlcC5pJmKo5Sy7lw58UKKVKXox YvKqndsr23Ui3fJzfLtEJdwOEXER/NMDnw8eyRa3hsbpfFOhxZ87CKSEYh8FMdQUSMiiyGEv28O0X sZesNV9w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVRL-0002Zw-TM; Sun, 18 Nov 2018 22:21:15 +0000 Received: from merlin.infradead.org ([2001:8b0:10b:1231::1]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVPm-0001Hj-7E for hostap@bombadil.infradead.org; Sun, 18 Nov 2018 22:19:38 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=References:In-Reply-To:Message-Id:Date: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=BGiQC4k/PfmBe6hSd/cTXEbkDYAYgAzdU2ro0eLTpUU=; b=QEZ2+BNQq28MRf6GAFwcwlM7E bsVioxHtlinuc5/yf0l55qXtGEAbypWBDvKCTtEPe5sAL/1kkzRJoIuMvj7ff/Ez/FecQLO0ZRRm9 GxBST8y52kg42f/rBpzc1V77uN+GjwdIqUTwIGThtlFcMb/nGKFnQ9v/PlgMjfUixFIB8/Hlu25WC xpYJuk7ggKHpkmK9rPvNhDEu+YLRsVFyWQ9qwZpOlovzJwbd2esMkKtfDeVZbiFEYeOeUs4YjUV1V 8QHffSKUoHxDUxp2cDu3lV/HujFbRuJKCyUCwUY9mkKm2kzxOdSJeeyi/7sZ3FB8VutloLCdTqrFr ASGFg6MhA==; Received: from smtp.codeaurora.org ([198.145.29.96]) by merlin.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gOVPj-0002Rx-44 for hostap@lists.infradead.org; Sun, 18 Nov 2018 22:19:36 +0000 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 515216028D; Sun, 18 Nov 2018 22:19:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1542579562; bh=pPl5TCyvJjepRJx8rm+Ik/7DrZAfl2uIpQiC5YFy3B8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=RGHAn5tg0cMiUZQJIlOTY1G6Nkru2bU0fr6m2XzoRQo8nzQ23aX+/k3EOCrpGxt6/ C3lxjOBGB7vCQqDL5kgciISawKndOW0EVwv+coXrCVaIx8puFIFcdJT5cN7F0WirkM vRctUUi0F+nN/V2wG9gMcB0bMFrG9o6nRYawT3fI= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.7 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_INVALID, DKIM_SIGNED autolearn=no autolearn_force=no version=3.4.0 Received: from jouni.codeaurora.org (37-33-76-121.bb.dnainternet.fi [37.33.76.121]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: jouni@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id 61D7E6028D; Sun, 18 Nov 2018 22:19:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1542579561; bh=pPl5TCyvJjepRJx8rm+Ik/7DrZAfl2uIpQiC5YFy3B8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GEjLorma0mAvVU+XQTh5x1zA1XVPrPyZKDbyV8JxjBJEMmLGJrJTxsQJamshPLNDA de/ug2qORA1m1XX/w/9+pyzFM+CJSmMBDURlMY8MqtKoMNiXv+hutQ0d1Z99qdad/1 IIrkZTtZQwIAmElLXQlZMR2hH8FkNNPyMhYQvOvw= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 61D7E6028D Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=jouni@codeaurora.org From: Jouni Malinen To: hostap@lists.infradead.org Subject: [PATCH 2/2] wpa_supplicant: Add Multi-AP protocol support to supplicant Date: Mon, 19 Nov 2018 00:18:59 +0200 Message-Id: <1542579539-16577-2-git-send-email-jouni@codeaurora.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1542579539-16577-1-git-send-email-jouni@codeaurora.org> References: <1542579539-16577-1-git-send-email-jouni@codeaurora.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181118_171935_383217_A970933A X-CRM114-Status: GOOD ( 27.27 ) X-Spam-Score: -2.5 (--) X-Spam-Report: SpamAssassin version 3.4.2 on merlin.infradead.org summary: Content analysis details: (-2.5 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_PASS SPF: sender matches SPF record -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [198.145.29.96 listed in list.dnswl.org] -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-Mailman-Approved-At: Sun, 18 Nov 2018 14:21:06 -0800 X-BeenThere: hostap@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Venkateswara Naralasetty , Jouni Malinen MIME-Version: 1.0 Sender: "Hostap" Errors-To: hostap-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org From: Venkateswara Naralasetty Advertise vendor specific Multi-AP IE in (Re)Association request and process Multi-AP IE from (Re)Association response frames if user enable Multi-AP fuctionality. This patch introducing new configuration parameter 'multi_ap_enabled' to enable/disable Multi-AP funtionality from user. Signed-off-by: Venkateswara Naralasetty Signed-off-by: Jouni Malinen --- src/common/ieee802_11_defs.h | 1 + src/drivers/driver.h | 10 +++++++++ src/drivers/driver_nl80211.c | 44 ++++++++++++++++++++++++++++++++++++++ wpa_supplicant/Makefile | 4 ++++ wpa_supplicant/config.c | 3 +++ wpa_supplicant/config_ssid.h | 8 +++++++ wpa_supplicant/ctrl_iface.c | 9 ++++++++ wpa_supplicant/defconfig | 3 +++ wpa_supplicant/driver_i.h | 11 ++++++++++ wpa_supplicant/events.c | 34 +++++++++++++++++++++++++++++ wpa_supplicant/sme.c | 43 +++++++++++++++++++++++++++++++++++++ wpa_supplicant/wpa_supplicant.c | 29 +++++++++++++++++++++++++ wpa_supplicant/wpa_supplicant.conf | 4 ++++ 13 files changed, 203 insertions(+) diff --git a/src/common/ieee802_11_defs.h b/src/common/ieee802_11_defs.h index c1a3a85..8033e58 100644 --- a/src/common/ieee802_11_defs.h +++ b/src/common/ieee802_11_defs.h @@ -1216,6 +1216,7 @@ struct ieee80211_ampe_ie { #define MULTI_AP_SUB_ELEM_TYPE 0x06 #define MULTI_AP_BACKHAUL_BSS 0x40 #define MULTI_AP_FRONTHAUL_BSS 0x20 +#define MULTI_AP_BACKHAUL_STA 0x80 #define BACKHAUL_BSS 1 #define FRONTHAUL_BSS 2 diff --git a/src/drivers/driver.h b/src/drivers/driver.h index d34c679..df6ddaa 100644 --- a/src/drivers/driver.h +++ b/src/drivers/driver.h @@ -4079,6 +4079,16 @@ struct wpa_driver_ops { */ int (*send_external_auth_status)(void *priv, struct external_auth *params); + +#ifdef CONFIG_MULTI_AP + /** + * set_multi_ap - Enable/disable Multi-AP functionality + * @priv: Private driver interface data + * @bridge_ifname: Name of the bridge interface + * @val: 0 for Multi-AP disable, 1 for Multi-AP enable + */ + int (*set_multi_ap)(void *priv, const char *bridge_ifname, int val); +#endif /* CONFIG_MULTI_AP */ }; /** diff --git a/src/drivers/driver_nl80211.c b/src/drivers/driver_nl80211.c index 771e766..6ec0d0a 100644 --- a/src/drivers/driver_nl80211.c +++ b/src/drivers/driver_nl80211.c @@ -10647,6 +10647,47 @@ fail: return ret; } +#ifdef CONFIG_MULTI_AP +static int nl80211_set_multi_ap(void *priv, const char *bridge_ifname, int val) +{ + struct i802_bss *bss = priv; + struct wpa_driver_nl80211_data *drv = bss->drv; + struct nl_msg *msg; + int ret = -ENOBUFS; + + msg = nl80211_cmd_msg(drv->first_bss, 0, NL80211_CMD_SET_INTERFACE); + if (!msg || nla_put_u8(msg, NL80211_ATTR_4ADDR, val)) + goto fail; + + if (bridge_ifname[0] && bss->added_if_into_bridge && !val) { + if (linux_br_del_if(drv->global->ioctl_sock, + bridge_ifname, bss->ifname)) { + wpa_printf(MSG_ERROR, "nl80211: Failed to remove the " + "interface %s to a bridge %s", + bss->ifname, bridge_ifname); + return -1; + } + bss->added_if_into_bridge = 0; + } + + ret = send_and_recv_msgs(drv, msg, NULL, NULL); + msg = NULL; + if (!ret) { + if (bridge_ifname[0] && val) { + if (i802_check_bridge(drv, bss, + bridge_ifname, bss->ifname) < 0) + return -1; + } + return 0; + } + +fail: + nlmsg_free(msg); + wpa_printf(MSG_ERROR, "nl80211: Failed to set Multi-AP"); + + return ret; +} +#endif /* CONFIG_MULTI_AP */ const struct wpa_driver_ops wpa_driver_nl80211_ops = { .name = "nl80211", @@ -10776,4 +10817,7 @@ const struct wpa_driver_ops wpa_driver_nl80211_ops = { .get_ext_capab = nl80211_get_ext_capab, .update_connect_params = nl80211_update_connection_params, .send_external_auth_status = nl80211_send_external_auth_status, +#ifdef CONFIG_MULTI_AP + .set_multi_ap = nl80211_set_multi_ap, +#endif /* CONFIG_MULTI_AP */ }; diff --git a/wpa_supplicant/Makefile b/wpa_supplicant/Makefile index c2e93e2..52892ea 100644 --- a/wpa_supplicant/Makefile +++ b/wpa_supplicant/Makefile @@ -96,6 +96,10 @@ CONFIG_NO_RANDOM_POOL= CONFIG_OPENSSL_CMAC=y endif +ifdef CONFIG_MULTI_AP +CFLAGS += -DCONFIG_MULTI_AP +endif + OBJS = config.o OBJS += notify.o OBJS += bss.o diff --git a/wpa_supplicant/config.c b/wpa_supplicant/config.c index c439606..2171476 100644 --- a/wpa_supplicant/config.c +++ b/wpa_supplicant/config.c @@ -2320,6 +2320,9 @@ static const struct parse_data ssid_fields[] = { #endif /* CONFIG_DPP */ { INT_RANGE(owe_group, 0, 65535) }, { INT_RANGE(owe_only, 0, 1) }, +#ifdef CONFIG_MULTI_AP + { INT_RANGE(multi_ap_enabled, 0, 1) }, +#endif }; #undef OFFSET diff --git a/wpa_supplicant/config_ssid.h b/wpa_supplicant/config_ssid.h index d2a52d7..8f51ab3 100644 --- a/wpa_supplicant/config_ssid.h +++ b/wpa_supplicant/config_ssid.h @@ -937,6 +937,14 @@ struct wpa_ssid { * the selection attempts for OWE BSS exceed the configured threshold. */ int owe_transition_bss_select_count; + +#ifdef CONFIG_MULTI_AP + /** multi_ap_enabled - Enable/disable Multi-AP functionality + * 0 = disable Multi-AP + * 1 = enable Multi-AP + */ + int multi_ap_enabled; +#endif /* CONFIG_MULTI_AP */ }; #endif /* CONFIG_SSID_H */ diff --git a/wpa_supplicant/ctrl_iface.c b/wpa_supplicant/ctrl_iface.c index 77a3133..b158e9a 100644 --- a/wpa_supplicant/ctrl_iface.c +++ b/wpa_supplicant/ctrl_iface.c @@ -3328,6 +3328,15 @@ static int wpa_supplicant_ctrl_iface_update_network( else if (os_strcmp(name, "priority") == 0) wpa_config_update_prio_list(wpa_s->conf); +#ifdef CONFIG_MULTI_AP + if (os_strcmp(name, "multi_ap_enabled") == 0) { + wpa_supplicant_deauthenticate(wpa_s, WLAN_REASON_DEAUTH_LEAVING); + if (wpa_drv_set_multi_ap(wpa_s, wpa_s->bridge_ifname, + ssid->multi_ap_enabled)) + wpa_printf(MSG_ERROR, "failed to set Multi-AP\n"); + } +#endif /* CONFIG_MULTI_AP */ + return 0; } diff --git a/wpa_supplicant/defconfig b/wpa_supplicant/defconfig index 08f5857..3c3081c 100644 --- a/wpa_supplicant/defconfig +++ b/wpa_supplicant/defconfig @@ -593,3 +593,6 @@ CONFIG_BACKEND=file # Opportunistic Wireless Encryption (OWE) # Experimental implementation of draft-harkins-owe-07.txt #CONFIG_OWE=y + +#Multi-AP protocol support +#CONFIG_MULTI_AP=y diff --git a/wpa_supplicant/driver_i.h b/wpa_supplicant/driver_i.h index 078de23..d5809c7 100644 --- a/wpa_supplicant/driver_i.h +++ b/wpa_supplicant/driver_i.h @@ -30,6 +30,17 @@ static inline void wpa_drv_deinit(struct wpa_supplicant *wpa_s) wpa_s->driver->deinit(wpa_s->drv_priv); } +#ifdef CONFIG_MULTI_AP +static inline int wpa_drv_set_multi_ap(struct wpa_supplicant *wpa_s, + const char *bridge_ifname, int val) +{ + if (wpa_s->driver->set_multi_ap) + return wpa_s->driver->set_multi_ap(wpa_s->drv_priv, + bridge_ifname, val); + return -1; +} +#endif /* CONFIG_MULTI_AP */ + static inline int wpa_drv_set_param(struct wpa_supplicant *wpa_s, const char *param) { diff --git a/wpa_supplicant/events.c b/wpa_supplicant/events.c index dd6dd52..837f036 100644 --- a/wpa_supplicant/events.c +++ b/wpa_supplicant/events.c @@ -2266,6 +2266,26 @@ static void interworking_process_assoc_resp(struct wpa_supplicant *wpa_s, #endif /* CONFIG_INTERWORKING */ +#ifdef CONFIG_MULTI_AP +static int wpa_validate_multi_ap_ie(struct wpa_supplicant *wpa_s, + const u8 *ies, size_t ies_len) +{ + struct ieee802_11_elems elems; + + if (ies == NULL) + return -1; + + if (ieee802_11_parse_elems(ies, ies_len, &elems, 1) == ParseFailed) + return -1; + + if (wpa_s->current_ssid->multi_ap_enabled && !elems.multi_ap) { + wpa_printf(MSG_INFO, " AP doesn't support Multi-AP"); + return -1; + } + + return 0; +} +#endif /* CONFIG_MULTI_AP */ #ifdef CONFIG_FST static int wpas_fst_update_mbie(struct wpa_supplicant *wpa_s, @@ -2343,6 +2363,20 @@ static int wpa_supplicant_event_associnfo(struct wpa_supplicant *wpa_s, get_ie(data->assoc_info.resp_ies, data->assoc_info.resp_ies_len, WLAN_EID_VHT_CAP)) wpa_s->ieee80211ac = 1; +#ifdef CONFIG_MULTI_AP + if (wpa_validate_multi_ap_ie(wpa_s, data->assoc_info.resp_ies, + data->assoc_info.resp_ies_len)) { + wpa_supplicant_deauthenticate(wpa_s, + WLAN_REASON_INVALID_IE); + return -1; + } else if (wpa_drv_set_multi_ap(wpa_s, wpa_s->bridge_ifname, + wpa_s->current_ssid->multi_ap_enabled)) { + wpa_printf(MSG_ERROR, "failed to set Multi-AP\n"); + wpa_supplicant_deauthenticate(wpa_s, + WLAN_REASON_DEAUTH_LEAVING); + return -1; + } +#endif /* CONFIG_MULTI_AP */ } if (data->assoc_info.beacon_ies) wpa_hexdump(MSG_DEBUG, "beacon_ies", diff --git a/wpa_supplicant/sme.c b/wpa_supplicant/sme.c index d569aca..5d1ec35 100644 --- a/wpa_supplicant/sme.c +++ b/wpa_supplicant/sme.c @@ -39,6 +39,26 @@ static void sme_obss_scan_timeout(void *eloop_ctx, void *timeout_ctx); static void sme_stop_sa_query(struct wpa_supplicant *wpa_s); #endif /* CONFIG_IEEE80211W */ +#ifdef CONFIG_MULTI_AP +static struct wpabuf *multi_ap_build_assoc_req_ie(void) +{ + struct wpabuf *ie = NULL; + + ie = wpabuf_alloc(10); + if (!ie) + return NULL; + + wpabuf_put_u8(ie, WLAN_EID_VENDOR_SPECIFIC); + wpabuf_put_u8(ie, 7); /* len */ + wpabuf_put_be24(ie, OUI_WFA); + wpabuf_put_u8(ie, MULTI_AP_OUI_TYPE); + wpabuf_put_u8(ie, MULTI_AP_SUB_ELEM_TYPE); + wpabuf_put_u8(ie, 1); /* sub elem len */ + wpabuf_put_u8(ie, MULTI_AP_BACKHAUL_STA); + + return ie; +} +#endif /* CONFIG_MULTI_AP */ #ifdef CONFIG_SAE @@ -1548,6 +1568,29 @@ void sme_associate(struct wpa_supplicant *wpa_s, enum wpas_mode mode, } #endif /* CONFIG_OWE */ +#ifdef CONFIG_MULTI_AP + if (wpa_s->conf->ssid->multi_ap_enabled) { + struct wpabuf *multi_ap_ie; + + multi_ap_ie = multi_ap_build_assoc_req_ie(); + if (!multi_ap_ie) { + wpa_printf(MSG_ERROR, "Multi-AP: Failed to build Multi-AP IE"); + return; + } + if (wpa_s->sme.assoc_req_ie_len + wpabuf_len(multi_ap_ie) > + sizeof(wpa_s->sme.assoc_req_ie)) { + wpa_printf(MSG_ERROR, + "Multi-AP: Not enough buffer for Association Request frame element"); + wpabuf_free(multi_ap_ie); + return; + } + os_memcpy(wpa_s->sme.assoc_req_ie + wpa_s->sme.assoc_req_ie_len, + wpabuf_head(multi_ap_ie), wpabuf_len(multi_ap_ie)); + wpa_s->sme.assoc_req_ie_len += wpabuf_len(multi_ap_ie); + wpabuf_free(multi_ap_ie); + } +#endif /* CONFIG_MULTI_AP */ + params.bssid = bssid; params.ssid = wpa_s->sme.ssid; params.ssid_len = wpa_s->sme.ssid_len; diff --git a/wpa_supplicant/wpa_supplicant.c b/wpa_supplicant/wpa_supplicant.c index 0fe2adb..b061810 100644 --- a/wpa_supplicant/wpa_supplicant.c +++ b/wpa_supplicant/wpa_supplicant.c @@ -285,6 +285,25 @@ void wpa_supplicant_cancel_auth_timeout(struct wpa_supplicant *wpa_s) wpa_s->last_con_fail_realm_len = 0; } +#ifdef CONFIG_MULTI_AP +u8 *wpa_add_multi_ap_info_ie(u8 *pos, size_t *len) +{ + struct multi_ap_ie *map = (struct multi_ap_ie *) (pos + 2); + + pos[1] = WLAN_EID_VENDOR_SPECIFIC; + pos[2] = 7; /* len */ + WPA_PUT_BE24((u8 *)map, OUI_WFA); + map->oui_type = MULTI_AP_OUI_TYPE; + map->sub_elem_id = MULTI_AP_SUB_ELEM_TYPE; + map->sub_elem_len = 0x01;/* sub element len */ + map->sub_elem_val = MULTI_AP_BACKHAUL_STA; + + pos = (u8 *) (map + 1); + *len += (2 + sizeof(*map)); + + return pos; +} +#endif /* CONFIG_MULTI_AP */ /** * wpa_supplicant_initiate_eapol - Configure EAPOL state machine @@ -2808,6 +2827,11 @@ static u8 * wpas_populate_assoc_ies( } #endif /* CONFIG_IEEE80211R */ +#ifdef CONFIG_MULTI_AP + if (ssid->multi_ap_enabled && ((max_wpa_ie_len - wpa_ie_len) > 9)) + wpa_add_multi_ap_info_ie(wpa_ie, &wpa_ie_len); +#endif /* CONFIG_MULTI_AP */ + params->wpa_ie = wpa_ie; params->wpa_ie_len = wpa_ie_len; params->auth_alg = algs; @@ -3303,6 +3327,11 @@ void wpa_supplicant_deauthenticate(struct wpa_supplicant *wpa_s, } #endif /* CONFIG_MESH */ +#ifdef CONFIG_MULTI_AP + if (wpa_s->current_ssid && wpa_s->current_ssid->multi_ap_enabled) + wpa_drv_set_multi_ap(wpa_s, wpa_s->bridge_ifname, 0); +#endif /* CONFIG_MULTI_AP */ + if (addr) { wpa_drv_deauthenticate(wpa_s, addr, reason_code); os_memset(&event, 0, sizeof(event)); diff --git a/wpa_supplicant/wpa_supplicant.conf b/wpa_supplicant/wpa_supplicant.conf index 4f59160..ba9dc03 100644 --- a/wpa_supplicant/wpa_supplicant.conf +++ b/wpa_supplicant/wpa_supplicant.conf @@ -1422,6 +1422,10 @@ fast_reauth=1 # Transitioning between states). #fst_llt=100 +# Enable Multi-AP funtionality. +# default = 0 (disable Multi-AP). +# multi_ap_enabled = 1 (enable Multi-AP). + # Example blocks: # Simple case: WPA-PSK, PSK as an ASCII passphrase, allow all valid ciphers