From 86e320819c5ae246f55ce0a9e53cda605fb088f9 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Thu, 11 Jul 2013 17:01:49 +0300 Subject: [PATCH] P2P NFC: Copy DH parameters to a separate group interface The DH public and private key needs to be copied for the separate group interface if that is used for a P2P group. Signed-hostap: Jouni Malinen --- wpa_supplicant/p2p_supplicant.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/wpa_supplicant/p2p_supplicant.c b/wpa_supplicant/p2p_supplicant.c index 254314db7..586708719 100644 --- a/wpa_supplicant/p2p_supplicant.c +++ b/wpa_supplicant/p2p_supplicant.c @@ -1370,6 +1370,11 @@ static void wpas_p2p_clone_config(struct wpa_supplicant *dst, d->dtim_period = s->dtim_period; d->disassoc_low_ack = s->disassoc_low_ack; d->disable_scan_offload = s->disable_scan_offload; + + if (s->wps_nfc_dh_privkey && s->wps_nfc_dh_pubkey) { + d->wps_nfc_dh_privkey = wpabuf_dup(s->wps_nfc_dh_privkey); + d->wps_nfc_dh_pubkey = wpabuf_dup(s->wps_nfc_dh_pubkey); + } }