During PASN pairing verification, the PASN authentication frame is
received without the need for provision discovery. If the pairing
initiator's peer entry is removed and added again or the MAC address
is randomized, the Authentication frame is discarded because the PASN
data is not initialized. Therefore, ensure that the PASN data for the
peer is initialized if it is not already present. Also set the P2P2
bool variable to true.
Signed-off-by: Vinay Gannevaram <quic_vganneva@quicinc.com>
}
if (!dev->pasn) {
- p2p_dbg(p2p, "PASN: Uninitialized");
- return -1;
+ dev->pasn = pasn_data_init();
+ if (!dev->pasn) {
+ p2p_dbg(p2p, "PASN: Uninitialized");
+ return -1;
+ }
}
pasn = dev->pasn;
if (wpa_s->global->p2p_disabled || !p2p)
return -2;
+
+ wpa_s->p2p2 = true;
return p2p_pasn_auth_rx(p2p, mgmt, len, freq);
}