WPS: Mark added PSK entry with wps=1 tag for per-Enrollee PSK case

Commit 2bab073dfe ("WPS: Add new PSK entries with wps=1 tag") added
this when writing the new entry into a file, but the in-memory update
did not get the tag. Add it there as well.

Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
Jouni Malinen 2020-02-16 11:54:36 +02:00
parent dd3d5da3c7
commit 981b96caa9

View file

@ -125,6 +125,7 @@ static int hostapd_wps_new_psk_cb(void *ctx, const u8 *mac_addr,
os_memcpy(p->addr, mac_addr, ETH_ALEN); os_memcpy(p->addr, mac_addr, ETH_ALEN);
os_memcpy(p->p2p_dev_addr, p2p_dev_addr, ETH_ALEN); os_memcpy(p->p2p_dev_addr, p2p_dev_addr, ETH_ALEN);
os_memcpy(p->psk, psk, PMK_LEN); os_memcpy(p->psk, psk, PMK_LEN);
p->wps = 1;
if (hapd->new_psk_cb) { if (hapd->new_psk_cb) {
hapd->new_psk_cb(hapd->new_psk_cb_ctx, mac_addr, p2p_dev_addr, hapd->new_psk_cb(hapd->new_psk_cb_ctx, mac_addr, p2p_dev_addr,