Commit 2e87a797 authored by Chen Ridong's avatar Chen Ridong
Browse files

wifi: wfx: fix possible NULL pointer dereference in wfx_set_mfp_ap()

mainline inclusion
from mainline-v6.8-rc1
commit fe0a7776d4d19e613bb8dd80fe2d78ae49e8b49d
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/I96GAG
CVE: CVE-2023-52593

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=fe0a7776d4d19e613bb8dd80fe2d78ae49e8b49d



----------------------------------------------------------------------

Since 'ieee80211_beacon_get()' can return NULL, 'wfx_set_mfp_ap()'
should check the return value before examining skb data. So convert
the latter to return an appropriate error code and propagate it to
return from 'wfx_start_ap()' as well. Compile tested only.

Signed-off-by: default avatarDmitry Antipov <dmantipov@yandex.ru>
Tested-by: default avatarJérôme Pouiller <jerome.pouiller@silabs.com>
Acked-by: default avatarJérôme Pouiller <jerome.pouiller@silabs.com>
Signed-off-by: default avatarKalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20231204171130.141394-1-dmantipov@yandex.ru



Conflicts
	drivers/staging/wfx/sta.c

Signed-off-by: default avatarChen Ridong <chenridong@huawei.com>
parent 513f709d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment