--- a/src/ap/hostapd.c +++ b/src/ap/hostapd.c @@ -2449,7 +2449,11 @@ static int hostapd_owe_iface_iter(struct if (!bss->conf->ssid.ssid_set || !bss->conf->ssid.ssid_len || is_zero_ether_addr(bss->own_addr)) continue; - + if (!os_memcmp(hapd->conf->owe_transition_bssid, bss->own_addr, ETH_ALEN) && + hapd->conf->owe_transition_ssid_len == bss->conf->ssid.ssid_len && + !os_memcmp(hapd->conf->owe_transition_ssid, bss->conf->ssid.ssid, + bss->conf->ssid.ssid_len)) + return 0; os_memcpy(hapd->conf->owe_transition_bssid, bss->own_addr, ETH_ALEN); os_memcpy(hapd->conf->owe_transition_ssid, @@ -2466,10 +2470,6 @@ static int hostapd_owe_iface_iter(struct int hostapd_owe_trans_get_info(struct hostapd_data *hapd) { - if (hapd->conf->owe_transition_ssid_len > 0 && - !is_zero_ether_addr(hapd->conf->owe_transition_bssid)) - return 0; - /* Find transition mode SSID/BSSID information from a BSS operated by * this hostapd instance. */ if (!hapd->iface->interfaces ||