wlan: Drop invalid EAPOL packets in SAP mode

Drop inalid EAPOL packets in SAP mode which are not
destined to self mac address.

Change-Id: I9754dddf580e60bd88ddc6e28355162499a8d125
CRs-Fixed: 2868054
This commit is contained in:
Dundi Raviteja 2021-03-10 11:56:36 +05:30 committed by Nolen Johnson
parent 0a25b3c7c0
commit d25cb7e425
1 changed files with 15 additions and 1 deletions

View File

@ -1303,7 +1303,21 @@ VOS_STATUS hdd_softap_rx_packet_cbk( v_VOID_t *vosContext,
VOS_TRACE( VOS_MODULE_ID_HDD_SOFTAP, VOS_TRACE_LEVEL_ERROR,"%s: Failure extracting skb from vos pkt", __func__);
return VOS_STATUS_E_FAILURE;
}
if (TRUE == hdd_IsEAPOLPacket(pVosPacket)) {
//wlan_hdd_log_eapol(skb, WIFI_EVENT_DRIVER_EAPOL_FRAME_RECEIVED);
if (vos_mem_compare2(skb->data,
pAdapter->macAddressCurrent.bytes, 6) != 0) {
//VOS_TRACE(VOS_MODULE_ID_HDD_SAP_DATA, VOS_TRACE_LEVEL_ERROR,
// "Packet is not destined to this address, dropping");
kfree_skb(skb);
pVosPacket = pNextVosPacket;
continue;
}
}
pVosPacket->pSkb = NULL;
//hdd_softap_dump_sk_buff(skb);
skb->dev = pAdapter->dev;