CVE-2024-58007

soc: qcom: socinfo: Avoid out of bounds read of serial number

No CVSS score yet EPSS 0.25%

Published 27 Feb 2025 Updated 11 May 2026 CNA: Linux

Check your servers for CVE-2024-58007

The Vulnpocalypse collector sends the package list of each Linux server and of its container images once a day. Vulnpocalypse shows every server where CVE-2024-58007 affects the running kernel, with the command that installs the fix. The free plan covers one server and one domain and does not need a credit card.

Check my servers

Description

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

soc: qcom: socinfo: Avoid out of bounds read of serial number

On MSM8916 devices, the serial number exposed in sysfs is constant and does not change across individual devices. It's always:

db410c:/sys/devices/soc0$ cat serial_number 2644893864

The firmware used on MSM8916 exposes SOCINFO_VERSION(0, 8), which does not have support for the serial_num field in the socinfo struct. There is an existing check to avoid exposing the serial number in that case, but it's not correct: When checking the item_size returned by SMEM, we need to make sure the *end* of the serial_num is within bounds, instead of comparing with the *start* offset. The serial_number currently exposed on MSM8916 devices is just an out of bounds read of whatever comes after the socinfo struct in SMEM.

Fix this by changing offsetof() to offsetofend(), so that the size of the field is also taken into account.

Exploitation

EPSS 0.25%: the probability of exploitation activity in the next 30 days, from the EPSS model of FIRST. The score is higher than 17.8% of all scored CVEs. Scores of 1 Dec 2026.

Affected products

As the CNA lists them.

ProductVersions
Linux
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 7445fa05317534bbd8b373c0eff8319187916030
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 2495c6598731b6d7f565140f2bd63ef4bc36ce7d
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 2d09d3c9afa2fc422ac3df7c9b8534f350ee19dd
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 9c88b3a3fae4d60641c3a45be66269d00eff33cd
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 47470acd719d45c4c8c418c07962f74cc995652b
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 407c928305c1a37232a63811c400ef616f85ccbc
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 0a92feddae0634a0b87c04b19d343f6af97af700
affected from efb448d0a3fca01bb987dd70963da6185b81751e, before 22cf4fae6660b6e1a583a41cbf84e3046ca9ccd0
Other versions: unaffected
Linux
affected 5.4
unaffected before 5.4
unaffected from 5.4.291 up to and including 5.4.*
unaffected from 5.10.235 up to and including 5.10.*
unaffected from 5.15.179 up to and including 5.15.*
unaffected from 6.1.129 up to and including 6.1.*
unaffected from 6.6.78 up to and including 6.6.*
unaffected from 6.12.14 up to and including 6.12.*
unaffected from 6.13.3 up to and including 6.13.*
unaffected 6.14 and later
Other versions: affected

Is my server affected?

This CVE is in the Linux kernel. Compare the running kernel with the fixed kernel version of your distribution, and reboot after a kernel update:

uname -r
# Debian, Ubuntu: does the changelog of the running kernel name the CVE?
zgrep -l CVE-2024-58007 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2024-58007

With Trivy, on the host and for a container image. When a package is affected, it prints the installed and the fixed version:

trivy rootfs --scanners vuln / | grep CVE-2024-58007
trivy image --scanners vuln IMAGE | grep CVE-2024-58007

Vulnpocalypse makes this comparison every day for the package lists of your servers and container images, including language packages (npm, PyPI, Go, Maven and others), and sends the command that installs the fix. Start free with one server and one domain or read how to install the collector.

References

Other references

Source: the record CVE-2024-58007 of the CVE List (CVE Program), CVE Terms of Use; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.