GAS: Update source MAC address on preassoc_mac_addr randomization
The GAS query source MAC address was not getting updated correctly when preassoc_mac_addr is enabled. Fix this by copying the current MAC address to the GAS query source address. Signed-off-by: Veerendranath Jakkam <vjakkam@codeaurora.org>
This commit is contained in:
parent
1289ecf4cc
commit
43106e122b
1 changed files with 9 additions and 7 deletions
|
@ -694,13 +694,15 @@ static void gas_query_start_cb(struct wpa_radio_work *work, int deinit)
|
|||
return;
|
||||
}
|
||||
|
||||
if (!query->maintain_addr && !wpa_s->conf->gas_rand_mac_addr &&
|
||||
wpas_update_random_addr_disassoc(wpa_s) < 0) {
|
||||
wpa_msg(wpa_s, MSG_INFO,
|
||||
"Failed to assign random MAC address for GAS");
|
||||
gas_query_free(query, 1);
|
||||
radio_work_done(work);
|
||||
return;
|
||||
if (!query->maintain_addr && !wpa_s->conf->gas_rand_mac_addr) {
|
||||
if (wpas_update_random_addr_disassoc(wpa_s) < 0) {
|
||||
wpa_msg(wpa_s, MSG_INFO,
|
||||
"Failed to assign random MAC address for GAS");
|
||||
gas_query_free(query, 1);
|
||||
radio_work_done(work);
|
||||
return;
|
||||
}
|
||||
os_memcpy(query->sa, wpa_s->own_addr, ETH_ALEN);
|
||||
}
|
||||
|
||||
gas->work = work;
|
||||
|
|
Loading…
Reference in a new issue