CVE-2024-56539

Source
https://cve.org/CVERecord?id=CVE-2024-56539
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-56539.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2024-56539
Downstream
Related
Published
2024-12-27T14:11:21.487Z
Modified
2026-05-18T05:56:11.523675281Z
Summary
wifi: mwifiex: Fix memcpy() field-spanning write warning in mwifiex_config_scan()
Details

In the Linux kernel, the following vulnerability has been resolved:

wifi: mwifiex: Fix memcpy() field-spanning write warning in mwifiexconfigscan()

Replace one-element array with a flexible-array member in struct mwifiex_ie_types_wildcard_ssid_params to fix the following warning on a MT8173 Chromebook (mt8173-elm-hana):

[ 356.775250] ------------[ cut here ]------------ [ 356.784543] memcpy: detected field-spanning write (size 6) of single field "wildcardssidtlv->ssid" at drivers/net/wireless/marvell/mwifiex/scan.c:904 (size 1) [ 356.813403] WARNING: CPU: 3 PID: 742 at drivers/net/wireless/marvell/mwifiex/scan.c:904 mwifiexscannetworks+0x4fc/0xf28 [mwifiex]

The "(size 6)" above is exactly the length of the SSID of the network this device was connected to. The source of the warning looks like:

ssid_len = user_scan_in->ssid_list[i].ssid_len;
[...]
memcpy(wildcard_ssid_tlv->ssid,
       user_scan_in->ssid_list[i].ssid, ssid_len);

There is a #define WILDCARDSSIDTLVMAXSIZE that uses sizeof() on this struct, but it already didn't account for the size of the one-element array, so it doesn't need to be changed.

Database specific
{
    "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/56xxx/CVE-2024-56539.json",
    "cna_assigner": "Linux"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
5e6e3a92b9a4c9416b17f468fa5c7fa2233b8b4e
Fixed
a09760c513ae0f98c7082a1deace7fb6284ee866
Fixed
1de0ca1d7320a645ba2ee5954f64be08935b002a
Fixed
5fa329c44e1e635da2541eab28b6cdb8464fc8d1
Fixed
581261b2d6fdb4237b24fa13f5a5f87bf2861f2c
Fixed
b466746cfb6be43f9a1457bbee52ade397fb23ea
Fixed
c4698ef8c42e02782604bf4f8a489dbf6b0c1365
Fixed
e2de22e4b6213371d9e76f74a10ce817572a8d74
Fixed
d7774910c5583e61c5fe2571280366624ef48036
Fixed
d241a139c2e9f8a479f25c75ebd5391e6a448500

Database specific

source
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-56539.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
3.0.0
Fixed
4.19.325
Type
ECOSYSTEM
Events
Introduced
4.20.0
Fixed
5.4.287
Type
ECOSYSTEM
Events
Introduced
5.5.0
Fixed
5.10.231
Type
ECOSYSTEM
Events
Introduced
5.11.0
Fixed
5.15.174
Type
ECOSYSTEM
Events
Introduced
5.16.0
Fixed
6.1.120
Type
ECOSYSTEM
Events
Introduced
6.2.0
Fixed
6.6.64
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.11.11
Type
ECOSYSTEM
Events
Introduced
6.12.0
Fixed
6.12.2

Database specific

source
"https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-56539.json"