P2P: Overwrite pending interface only after verifying BSS entry
Previously, the P2P Interface Address of the peer gets updated in the peer table every time based on the scan results. For example, in a two port concurrency scenario, where the peer device has two interfaces with unique P2P Interface Addresses and with same P2P Device Address, based on the Probe Response/Beacon frames from these two interfaces, their peer table gets updated, but each of these updates happens in the peer table only based on the P2P Device Address. So, the same peer's P2P Interface address is updated every time and hence, at any instant, only one P2P Device Address to P2P Interface Address mapping entry exist in the peer table for the peer which has two interfaces. When we try to join a group operated by the peer, lookup happens in the peer table and when an interface entry is not available, the pending interface address gets overwritten with the P2P Device Address and hence the P2P connection can fail. Since the BSS table is the one that is up-to-date, this fix will ensure that the interface overwriting will happen only when there is no BSS entry for the pending P2P Interface Address as well. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
This commit is contained in:
parent
4b15c3f256
commit
4e5367516b
1 changed files with 2 additions and 2 deletions
|
@ -4354,8 +4354,8 @@ static void wpas_p2p_scan_res_join(struct wpa_supplicant *wpa_s,
|
||||||
p2p_get_interface_addr(wpa_s->global->p2p,
|
p2p_get_interface_addr(wpa_s->global->p2p,
|
||||||
wpa_s->pending_join_dev_addr,
|
wpa_s->pending_join_dev_addr,
|
||||||
iface_addr) == 0 &&
|
iface_addr) == 0 &&
|
||||||
os_memcmp(iface_addr, wpa_s->pending_join_dev_addr, ETH_ALEN) != 0)
|
os_memcmp(iface_addr, wpa_s->pending_join_dev_addr, ETH_ALEN) != 0
|
||||||
{
|
&& !wpa_bss_get_bssid(wpa_s, wpa_s->pending_join_iface_addr)) {
|
||||||
wpa_printf(MSG_DEBUG, "P2P: Overwrite pending interface "
|
wpa_printf(MSG_DEBUG, "P2P: Overwrite pending interface "
|
||||||
"address for join from " MACSTR " to " MACSTR
|
"address for join from " MACSTR " to " MACSTR
|
||||||
" based on newly discovered P2P peer entry",
|
" based on newly discovered P2P peer entry",
|
||||||
|
|
Loading…
Reference in a new issue