wifi: brcmsmac: fix UAF in brcms_free_timer()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ 5b435de0d786869c95d1962121af0d7df2542009 · < 1edb3ddd261e973a4d577c0547e63bfa25a8170d| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
wifi: brcmsmac: fix UAF in brcms_free_timer()
brcms_free_timer() calls brcms_del_timer() which uses the non-synchronous cancel_delayed_work() to cancel the timer's underlying delayed work. If the work callback (_brcms_timer) is already running, cancel_delayed_work() returns false without waiting, and brcms_free_timer() proceeds to kfree(t) while the callback still accesses t through container_of().
Add an explicit cancel_delayed_work_sync() after brcms_del_timer() to guarantee that any in-flight callback has completed before the timer structure is freed.
From the CVE record · Linux
The Linux kernel's brcmsmac driver can free a timer while its delayed-work callback is still using it, causing a use-after-free. The input does not specify how an attacker could trigger this condition or whether network access, authentication, or user interaction is required.
Teams running Linux kernels with the brcmsmac driver should check their versions; affected versions are not specified.