Skip to content

Commit 9eb6fba

Browse files
committed
wifi: mwifiex: Fix missed return in oob checks failed path
jira VULN-154524 cve-bf CVE-2023-53226 commit-author Polaris Pi <pinkperfect2021@gmail.com> commit 2785851 Add missed return in mwifiex_uap_queue_bridged_pkt() and mwifiex_process_rx_packet(). Fixes: 1195852 ("wifi: mwifiex: Fix OOB and integer underflow when rx packets") Signed-off-by: Polaris Pi <pinkperfect2021@gmail.com> Reported-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Kalle Valo <kvalo@kernel.org> Link: https://lore.kernel.org/r/20230810083911.3725248-1-pinkperfect2021@gmail.com (cherry picked from commit 2785851) Signed-off-by: Jonathan Maple <jmaple@ciq.com>
1 parent 7343d5b commit 9eb6fba

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

drivers/net/wireless/marvell/mwifiex/sta_rx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ int mwifiex_process_rx_packet(struct mwifiex_private *priv,
105105
skb->len, rx_pkt_off);
106106
priv->stats.rx_dropped++;
107107
dev_kfree_skb_any(skb);
108+
return -1;
108109
}
109110

110111
if (sizeof(*rx_pkt_hdr) + rx_pkt_off <= skb->len &&

drivers/net/wireless/marvell/mwifiex/uap_txrx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ static void mwifiex_uap_queue_bridged_pkt(struct mwifiex_private *priv,
122122
skb->len, le16_to_cpu(uap_rx_pd->rx_pkt_offset));
123123
priv->stats.rx_dropped++;
124124
dev_kfree_skb_any(skb);
125+
return;
125126
}
126127

127128
if ((!memcmp(&rx_pkt_hdr->rfc1042_hdr, bridge_tunnel_header,

0 commit comments

Comments
 (0)