CVE-2024-35803

x86/efistub: Call mixed mode boot services on the firmware's stack

No CVSS score yet EPSS 0.22%

Published 17 May 2024 Updated 11 May 2026 CNA: Linux

Check your servers for CVE-2024-35803

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-35803 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:

x86/efistub: Call mixed mode boot services on the firmware's stack

Normally, the EFI stub calls into the EFI boot services using the stack that was live when the stub was entered. According to the UEFI spec, this stack needs to be at least 128k in size - this might seem large but all asynchronous processing and event handling in EFI runs from the same stack and so quite a lot of space may be used in practice.

In mixed mode, the situation is a bit different: the bootloader calls the 32-bit EFI stub entry point, which calls the decompressor's 32-bit entry point, where the boot stack is set up, using a fixed allocation of 16k. This stack is still in use when the EFI stub is started in 64-bit mode, and so all calls back into the EFI firmware will be using the decompressor's limited boot stack.

Due to the placement of the boot stack right after the boot heap, any stack overruns have gone unnoticed. However, commit

5c4feadb0011983b ("x86/decompressor: Move global symbol references to C code")

moved the definition of the boot heap into C code, and now the boot stack is placed right at the base of BSS, where any overruns will corrupt the end of the .data section.

While it would be possible to work around this by increasing the size of the boot stack, doing so would affect all x86 systems, and mixed mode systems are a tiny (and shrinking) fraction of the x86 installed base.

So instead, record the firmware stack pointer value when entering from the 32-bit firmware, and switch to this stack every time a EFI boot service call is made.

Exploitation

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

The assessment of CISA (SSVC, 28 May 2024):

Exploitation
none: CISA did not find evidence of exploitation or a public proof of concept
Automatable
no: each attack takes manual steps
Technical impact
partial: limited control or limited data

Affected products

As the CNA lists them.

ProductVersions
Linux
affected from b8ff87a6158886771677e6dc8139bac6e3cba717, before 2149f8a56e2ed345c7a4d022a79f6b8fc53ae926
affected from b8ff87a6158886771677e6dc8139bac6e3cba717, before 930775060ca348b8665f60eef14b204172d14f31
affected from b8ff87a6158886771677e6dc8139bac6e3cba717, before fba7ee7187581b5bc222003e73e2592b398bb06d
affected from b8ff87a6158886771677e6dc8139bac6e3cba717, before 725351c036452b7db5771a7bed783564bc4b99cc
affected from b8ff87a6158886771677e6dc8139bac6e3cba717, before cefcd4fe2e3aaf792c14c9e56dab89e3d7a65d02
Other versions: unaffected
Linux
affected 3.15
unaffected before 3.15
unaffected from 6.1.84 up to and including 6.1.*
unaffected from 6.6.24 up to and including 6.6.*
unaffected from 6.7.12 up to and including 6.7.*
unaffected from 6.8.3 up to and including 6.8.*
unaffected 6.9 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-35803 /usr/share/doc/linux-image-$(uname -r)/changelog.Debian.gz
# RHEL, Rocky, Alma
rpm -q --changelog kernel | grep CVE-2024-35803

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-35803
trivy image --scanners vuln IMAGE | grep CVE-2024-35803

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-35803 of the CVE List (CVE Program), CVE Terms of Use; the CISA KEV catalog and the CISA ADP container; EPSS of FIRST. The text of the record is shown as published. Data sources and licences.