Linux: wifi: libipw: reject too-short beacon and probe responses
What fixes it
- 23afeb5d2bdfd34c8a0a661876291a4fa9978293LinuxCVE List
- 89959ff00a978f3172726d3d5f861ee6f1aae26dLinuxCVE List
- 14ae269c1306053ddf1ccf37c4bd66e085a652d1LinuxCVE List
- 2c87bbc00dc93149d1dc4f803ad92d92e4ef3758LinuxCVE List
- 19959fb60228f6dccc40d55507f8b1a751c2dc89LinuxCVE List
- 5ce5721e8cbe3e80db8f43851cc2a2a92485ef4bLinuxCVE List
A fixed version on one release line is not the upgrade target for every line. Check your exact version and any vendor backports.
Description
In the Linux kernel, the following vulnerability has been resolved:
wifi: libipw: reject too-short beacon and probe responses
libipw_process_probe_response() and the libipw_network_init() call it makes assume the frame contains the full 36-byte beacon and probe response prefix, but the ipw2100 and ipw2200 receive paths only establish that a management frame carries the generic 24-byte three-address header.
libipw_network_init() then computes the information element length as
stats->len - sizeof(*beacon)
stats->len is a u16 and sizeof() has type size_t, so the subtraction is evaluated as size_t and wraps instead of going negative. Truncating that to the u16 length parameter of libipw_parse_info_param() yields 65524 for a 24-byte beacon, and the parser then walks the receive buffer as if it held almost 64 KiB of information elements, reading past the allocation.
Reject the frame before any fixed field is touched.
Found by an AI-assisted review of length arithmetic in management frame parsers. Verified with a KUnit case under Generic KASAN on arm64 under QEMU; I do not have the hardware, so it is not tested on a real device.
Text from CVE List
Affected versions 18
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before cee6f141b3bebe62eb0363fd147acb52023935f0CVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 23afeb5d2bdfd34c8a0a661876291a4fa9978293CVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 89959ff00a978f3172726d3d5f861ee6f1aae26dCVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 14ae269c1306053ddf1ccf37c4bd66e085a652d1CVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before ff756e6647722b7d225d882f7bdb186d8eee318eCVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 2c87bbc00dc93149d1dc4f803ad92d92e4ef3758CVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 19959fb60228f6dccc40d55507f8b1a751c2dc89CVE List
- Linuxaffected: b453872c35cfcbdbf5a794737817f7d4e7b1b579 before 5ce5721e8cbe3e80db8f43851cc2a2a92485ef4bCVE List
- Linuxaffected: 2.6.14CVE List
- Linuxunaffected: all versions before 2.6.14CVE List
- Linuxunaffected: 5.10.271 through 5.10.*CVE List
- Linuxunaffected: 5.15.222 through 5.15.*CVE List
- Linuxunaffected: 6.1.189 through 6.1.*CVE List
- Linuxunaffected: 6.6.158 through 6.6.*CVE List
- Linuxunaffected: 6.12.112 through 6.12.*CVE List
- Linuxunaffected: 6.18.54 through 6.18.*CVE List
- Linuxunaffected: 7.2.8 through 7.2.*CVE List
- Linuxunaffected: 7.3CVE List
References 8
- git.kernel.org/stable/c/cee6f141b3bebe62eb0363fd147acb52023935f0Referencevia CVE List
- git.kernel.org/stable/c/23afeb5d2bdfd34c8a0a661876291a4fa9978293Referencevia CVE List
- git.kernel.org/stable/c/89959ff00a978f3172726d3d5f861ee6f1aae26dReferencevia CVE List
- git.kernel.org/stable/c/14ae269c1306053ddf1ccf37c4bd66e085a652d1Referencevia CVE List
- git.kernel.org/stable/c/ff756e6647722b7d225d882f7bdb186d8eee318eReferencevia CVE List
- git.kernel.org/stable/c/2c87bbc00dc93149d1dc4f803ad92d92e4ef3758Referencevia CVE List
- git.kernel.org/stable/c/19959fb60228f6dccc40d55507f8b1a751c2dc89Referencevia CVE List
- git.kernel.org/stable/c/5ce5721e8cbe3e80db8f43851cc2a2a92485ef4bReferencevia CVE List