# CVE-2026-12235: Out-of-bounds write in Xtensa llext PLT relocation from malformed ELF (CWE-787)

- Severity: Medium 6.3 (CVSS:3.1, scored by zephyr) `CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:H/A:H`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.14%, higher than 3% of CVEs (2026-12-01)
- Public exploit code or proof of concept: one link below, marked "exploit"
- Published: 2026-08-12T04:55:15.620Z
- Modified: 2026-11-04T05:18:38.317Z
- Weaknesses: CWE-787
- SSVC (CISA-ADP): exploitation poc, automatable no, technical impact partial
- Assigned by: zephyr

## Description

The Linkable Loadable Extensions (llext) subsystem mis-handles PLT/RELA relocation entries when linking a relocatable (partially-linked) ELF extension. In llext_link_plt() (subsys/llext/llext_link.c), the relocatable branch (tgt != NULL, the path used for Xtensa relocatable objects) computed the patch address as ext->mem[LLEXT_MEM_TEXT] - text.sh_offset + rela.r_offset + tgt->sh_offset and then performed the relocation write there without validating rela.r_offset. Its sibling shared/dynamic branch already rejected out-of-range offsets via llext_file_offset().

rela.r_offset is read directly from the ELF's RELA table, so a crafted entry with an offset larger than the target section makes the write land arbitrarily far outside the extension's text buffer. The result is an attacker-influenced out-of-bounds write (the location via r_offset, the written value being the resolved symbol address) performed in supervisor context at link time, before any extension code runs.

The path is reached from llext_load() whenever an application loads an attacker-influenced ELF extension on Xtensa with writable storage; llext is documented to accept extensions of untrusted origin. Impact is supervisor-context memory corruption (integrity and availability loss, and a sandbox-boundary escape for user-mode extensions). Exploitation is gated by the Xtensa relocatable PLT path and writable storage, and turning the out-of-range write into a useful primitive is non-trivial.

The fix adds a bound check rejecting any RELA entry whose r_offset >= tgt->sh_size, mirroring the existing validation in the shared branch.

(As written by CVE List.)

## Affected

- zephyr: from 3.7.0 before 4.3.2; from 4.4.0 before 4.4.2

## References

- <https://github.com/zephyrproject-rtos/zephyr/security/advisories/GHSA-xv9q-6mrf-8j49> (exploit)
- <https://github.com/zephyrproject-rtos/zephyr/commit/106540afbd22087ad40b90f53fb22657754a719e> (patch)

## Sources

- CVE List: [CVE-2026-12235](https://www.cve.org/CVERecord?id=CVE-2026-12235), CVE Terms of Use, modified 2026-11-04
- NVD: [CVE-2026-12235](https://nvd.nist.gov/vuln/detail/CVE-2026-12235), Public domain, modified 2026-11-04

---

Page: https://cve.day/CVE-2026-12235 · Whole record: https://cve.day/CVE-2026-12235.json · Rebuilt by cve.day 2026-11-25T22:59:32.539Z
