CVE-2026-12520
Stack buffer overflow and off-by-one writes in Zephyr HL7800 modem AT response handlers
Mitigation
- Upgrade zephyr to 4.4.2 or later.
Who should check
- Anyone running zephyrproject zephyr >= 2.4.0, < 4.3.2; >= 4.4.0, < 4.4.2
Vulnerability facts
- Affected
- zephyrproject zephyr >= 2.4.0, < 4.3.2; >= 4.4.0, < 4.4.2
- Fixed in
- zephyrproject zephyr 4.3.2, zephyrproject zephyr 4.4.2
- Exploited in the wild
- Not in CISA KEV
- Public exploit / PoC
- None known
- Remote exploitation
- Not remotely exploitable (local or adjacent access needed)
- CVSS
- 6.4 (v3.1, CNA)CVSS:3.1/AV:A/AC:H/PR:N/UI:N/S:U/C:L/I:L/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
- Attack vector: Adjacent network
- Attack complexity: High
- Privileges required: None
- User interaction: None
- Scope: Unchanged
- Confidentiality impact: Low
- Integrity impact: Low
- Availability impact: High
- EPSS
- 0.29% chance of exploitation in 30 days (percentile 14, 2026-11-26)
- CWE
- CWE-787
- Modified
Description
The Sierra Wireless HL7800 cellular modem driver (drivers/modem/vendor_standalone/hl7800.c, located at drivers/modem/hl7800.c in v4.4.0 and earlier) parses AT responses with roughly twenty handlers that call net_buf_linearize(value, sizeof(value), *buf, 0, len) into a 128-byte stack buffer and then write value[out_len] = 0. Because net_buf_linearize() (lib/net_buf/buf.c) can return a count equal to its destination-length argument, a field that exactly fills the buffer makes the terminating NUL land one byte past the end, a single-byte out-of-bounds write into adjacent stack memory. The +KCELLMEAS cell-measurement handler on_cmd_atcmdinfo_rssi() is worse: it passed the wire length len as the destination size (net_buf_linearize(value, len, *buf, 0, len)), so a response line longer than 128 bytes overflows the value stack buffer with attacker-influenceable content. The line length comes from net_buf_findcrlf(), which accumulates bytes across the whole net_buf fragment chain and is not bounded to 128, so an over-long line reaches the defect. The data originates from the cellular modem over UART, driven by the network: operator-scan results, +CGCONTRDP IP/DNS info, socket indications, and +KCELLMEAS neighbour-cell reports. An attacker able to shape what the modem emits — a rogue base station, a compromised modem baseband, or a remote peer feeding oversized response framing — can drive a line past 128 bytes. The handlers run in the driver's RX thread in kernel context, so the corruption is kernel-side. The +KCELLMEAS path is a full stack buffer overflow whose worst case is code execution in kernel context and whose floor is a reliable crash; the remaining sites are single-byte NUL out-of-bounds writes. Exploitation requires the modem to emit an over-long AT response line, giving high attack complexity over an adjacent (cellular radio) vector. The fix passes sizeof(dst) - 1 (and correct explicit bounds for the IMSI and +KCELLMEAS sites) so the terminator always stays in bounds.
Affected and fixed versions
| Package / product | Affected | Fixed | Source |
|---|---|---|---|
| zephyrproject zephyr | >= 2.4.0, < 4.3.2; >= 4.4.0, < 4.4.2 | — | cvelist |
Check your systems with an agent
Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.
Check whether anything I run is affected by CVE-2026-12520. Work read-only: do not install, upgrade, delete or change anything. Details: https://flawdb.com/CVE-2026-12520.md Affected: zephyrproject zephyr >= 2.4.0, < 4.3.2; >= 4.4.0, < 4.4.2 Fixed in: zephyrproject zephyr 4.3.2, zephyrproject zephyr 4.4.2 Steps: 1. Search this machine and project for zephyrproject zephyr: dependency manifests and lockfiles, installed packages, container images and running services. 2. For each match, note the installed version and whether it is inside the affected range. 3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
References
Vendor advisories
FAQ
Is CVE-2026-12520 being exploited?
There is no confirmed exploitation: CVE-2026-12520 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.29% chance of exploitation in the next 30 days (as of 2026-11-26).
How serious is CVE-2026-12520?
Medium: CVSS 6.4 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed). The attack needs conditions outside the attacker's control, which makes it harder.
Which versions are affected by CVE-2026-12520?
zephyrproject zephyr >= 2.4.0, < 4.3.2; >= 4.4.0, < 4.4.2.
Is there a fix for CVE-2026-12520?
Yes. Fixed in zephyrproject zephyr 4.3.2, zephyrproject zephyr 4.4.2. Upgrade zephyr to 4.4.2 or later.
How do I check if I'm affected by CVE-2026-12520?
Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.