/

CVE-2026-16511

Severity:

HIGH RISK

(8.8)

Unvalidated Writes (CWE-822) in Zephyr RTIO Syscalls

CVE-2026-16511

Awaiting Analysis

Vulnerability type

Category:

Improper Validation of Memory Pointers

CWE:

CWE-787, CWE-822, CWE-862

Impact:

Kernel Memory Corruption and Potential Privilege Escalation

Severity:

HIGH RISK

(8.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Zephyr RTIO syscall verifiers fail to adequately validate certain user-supplied pointers before the kernel writes through them. On builds with both userspace and RTIO enabled, a user-mode thread may be able to modify kernel memory and potentially escalate privileges; a separate flaw can allow a thread with an RTIO context grant to affect another context's I/O.

Affected context

The issue affects Zephyr systems built with both CONFIG_USERSPACE and CONFIG_RTIO enabled. It occurs in RTIO syscall handling: the cancel verifier passes a user-supplied handle into kernel code without validating or bounding it, while the copy-in handle verifier does not verify that its output pointer references writable user memory. The cancel path also requires authorization for the RTIO context that owns the relevant submission pool.

Exploit preconditions

  • Attack surface: RTIO syscalls exposed to user-mode threads.
  • Required access: The cancel syscall requires a userspace build but no RTIO context grant; the copy-in handle path requires a grant to an RTIO context.
  • Trigger point: Calling the cancel operation with a caller-controlled handle, or calling the copy-in operation with a caller-controlled output pointer.
  • Why exploitation is possible: The kernel writes through insufficiently checked pointers. In the cancel path, it also follows a pointer chain without first restricting the handle to valid submission-pool storage.
  • Configuration scope: Systems without CONFIG_USERSPACE or without CONFIG_RTIO are unaffected.

Why this happens

The syscall verifiers do not establish that user-provided addresses are safe for the kernel's intended reads or writes. The cancel path treats an untrusted handle as an RTIO submission entry, modifies its flags, and follows its next pointer; the copy-in path checks for a non-NULL output pointer but does not confirm that it is writable user memory. This primarily maps to CWE-822: Untrusted Pointer Dereference, with the resulting kernel writes also relating to CWE-787: Out-of-bounds Write. Missing authorization for the context that owns a submission pool additionally relates to CWE-862: Missing Authorization.

Potential impact

  • A user-mode thread could modify selected bits in kernel memory.
  • Kernel data-structure corruption could lead to privilege escalation or compromise of system integrity.
  • An invalid pointer chain could cause kernel faults or denial of service.
  • A thread with an RTIO context grant could cancel submissions belonging to another context if ownership checks are absent, potentially interrupting its I/O.

General mitigation guidance

Defensive patterns focus on validating both pointer safety and resource ownership before kernel access:

  • Check that user-provided output buffers are writable for the full size and duration of each kernel write.
  • Convert handles to kernel objects only after confirming they fall within the owning submission pool and refer to valid entries.
  • Require authorization for the RTIO context that owns the matched pool before permitting cancellation.
  • Prefer bounded, kernel-managed handles over following caller-influenced pointer chains.
  • Apply least privilege to userspace threads and expose only the RTIO contexts and operations they need.

How teams detect issues like this

  • Use static analysis to identify syscall handlers that dereference or write through user pointers without memory-region checks.
  • Review handle conversion and container macros for paths that accept untrusted addresses or follow pointer chains.
  • Check that output parameters receive writable-memory validation and that resource operations enforce ownership grants.
  • Add policy checks and review rules requiring bounds, memory-permission, and authorization checks at syscall boundaries.
  • Use automated code-review tools to help flag unchecked user-pointer access and missing object-permission checks.

Sources

SourceLink
github.comgithub.com/zephyrproject-rtos/zephyr/commit/3f244c1709ec0be533ed83d34998e942fc4da399
github.comgithub.com/zephyrproject-rtos/zephyr/commit/95c355c425763fbe5e735b9ef54dacce2c4ce21f
github.comgithub.com/zephyrproject-rtos/zephyr/commit/b1092a0aa7fbe67118ca4b08d5b4e54b34709a6e
github.comgithub.com/zephyrproject-rtos/zephyr/security/advisories/GHSA-3rh4-hpgj-jrww

Frequently asked

questions

The described issue is exposed through local user-mode RTIO syscalls; remote exploitation would depend on whether another part of a system lets a remote actor execute code or otherwise invoke those syscalls.

A user-mode thread can reach the cancel path on affected builds without an RTIO context grant. The copy-in handle path requires a grant to an RTIO context.

Validate user memory permissions before accessing pointers, bound handles to valid pool storage, and check permission for the context that owns the resource.

Treat syscall arguments as untrusted, centralize pointer and handle validation, and enforce resource ownership checks at every kernel boundary.

Find out what's already
exploitable in your codebase.