Zephyr Project up to 4.4.1 virtio PCI driver virtio_pci.c virtio_pci_read_cap cap_len out-of-bounds write
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.2 | $0-$5k | 1.57 |
Summary
A vulnerability marked as critical has been reported in Zephyr Project Zephyr up to 4.4.1. This affects the function virtio_pci_read_cap of the file drivers/virtio/virtio_pci.c of the component virtio PCI driver. Performing a manipulation of the argument cap_len results in out-of-bounds write.
This vulnerability was named CVE-2026-13216. The attack may be initiated remotely. There is no available exploit.
Details
A vulnerability was found in Zephyr Project Zephyr up to 4.4.1. It has been classified as critical. This affects the function virtio_pci_read_cap of the file drivers/virtio/virtio_pci.c of the component virtio PCI driver. The manipulation of the argument cap_len with an unknown input leads to a out-of-bounds write vulnerability. CWE is classifying the issue as CWE-787. The product writes data past the end, or before the beginning, of the intended buffer. This is going to have an impact on integrity, and availability. The summary by CVE is:
The virtio PCI driver (drivers/virtio/virtio_pci.c) parses a device's PCI capability list during driver initialization. In virtio_pci_read_cap() the device-supplied capability length byte cap_len (read from PCI config space via pcie_conf_read()) was only checked with assert(tmp.cap_len == cap_struct_size). That assert resolves to __ASSERT_NO_MSG(), gated by CONFIG_ASSERT, which defaults off in production builds, so the value reached the copy logic completely unvalidated. The length then drives a loop that copies extra capability dwords into a fixed-size stack buffer supplied by the caller. A cap_len below the 24-byte base struct virtio_pci_cap underflows the unsigned extra_data_words count to a near-SIZE_MAX value, producing an effectively unbounded stack write; a cap_len above the caller's buffer (up to 255) writes up to roughly 228 bytes of device-controlled data past the buffer. Both are out-of-bounds writes of attacker-controlled content executed in kernel mode during boot-time device probe. The input originates from the virtio device. In the common deployment where Zephyr runs as a guest under a hypervisor, the device backend is the host, which already fully outranks the guest, so the bug yields no privilege escalation. The exploitable case is a virtio device that is untrusted relative to the Zephyr kernel — an untrusted or physical/passthrough virtio PCIe device on a bare-metal system, or a confidential-computing posture where the guest must defend against the host — where a malicious device can corrupt the kernel stack and potentially achieve code execution or a crash. The fix replaces the compiled-out assert with a runtime range check rejecting cap_len outside [sizeof(struct virtio_pci_cap), cap_struct_size] before any arithmetic or copy.
The advisory is shared at github.com. This vulnerability is uniquely identified as CVE-2026-13216 since 06/24/2026. The exploitability is told to be easy. It is possible to initiate the attack remotely. No form of authentication is needed for exploitation. Technical details are known, but no exploit is available.
Upgrading to version 4.4.2 eliminates this vulnerability. Applying the patch d98dacee24ad10c972d3b7281c9009d82ed351c9 is able to eliminate this problem.
If you want to get the best quality for vulnerability data then you always have to consider VulDB.
Product
Type
Vendor
Name
Version
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CVSSv3
VulDB Meta Base Score: 6.3VulDB Meta Temp Score: 6.2
VulDB Base Score: 6.5
VulDB Temp Score: 6.2
VulDB Vector: 🔒
VulDB Reliability: 🔍
CNA Base Score: 6.1
CNA Vector (zephyr): 🔒
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: Out-of-bounds writeCWE: CWE-787 / CWE-119
CAPEC: 🔒
ATT&CK: 🔒
Physical: Yes
Local: Partially
Remote: Yes
Availability: 🔒
Status: Not defined
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: UpgradeStatus: 🔍
0-Day Time: 🔒
Upgrade: Zephyr 4.4.2
Patch: d98dacee24ad10c972d3b7281c9009d82ed351c9
Timeline
06/24/2026 CVE reserved08/25/2026 Advisory disclosed
08/25/2026 VulDB entry created
08/25/2026 VulDB entry last update
Sources
Advisory: github.comStatus: Confirmed
CVE: CVE-2026-13216 (🔒)
GCVE (CVE): GCVE-0-2026-13216
GCVE (VulDB): GCVE-100-395133
Entry
Created: 08/25/2026 18:45Changes: 08/25/2026 18:45 (69)
Complete: 🔍
Cache ID: 216::103
If you want to get the best quality for vulnerability data then you always have to consider VulDB.
No comments yet. Languages: en.
Please log in to comment.