# CVE-2026-9771: Missing device-pointer validation in flash\_copy() syscall allows userspace privilege escalation

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 8.8
- **CVSS:** 8.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Changed (impact reaches other components); Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.14% (percentile 2, 2026-11-26)
- **CWE:** CWE-822, CWE-862
- **Published:** 2026-08-17T16:18:52.514Z
- **Modified:** 2026-11-04T05:19:07.243Z

## Who should check

- Anyone running zephyrproject zephyr \>= 4.0.0, \< 4.3.2; \>= 4.4.0, \< 4.4.2

## Description

The flash\_copy() system call is verified by z\_vrfy\_flash\_copy() in drivers/flash/flash\_util.c. On builds with CONFIG\_USERSPACE enabled, this handler is the kernel-side trust boundary for a user-mode caller. Prior to the fix it validated only the output buffer (K\_SYSCALL\_MEMORY\_WRITE) and passed the two struct device \* arguments, src\_dev and dst\_dev, directly into the implementation without any object validation — unlike every sibling flash syscall, which guards its device pointer with K\_SYSCALL\_DRIVER\_FLASH.

A user-mode thread fully controls the values of src\_dev/dst\_dev and the contents of its own address space. The implementation z\_impl\_flash\_copy() dereferences these pointers and calls through their driver-API function tables (e.g. api-\>get\_parameters(dst\_dev), flash\_read(src\_dev, ...), flash\_write(dst\_dev, ...)). By supplying a pointer to a forged struct device whose api table contains attacker-chosen function pointers, an unprivileged thread can cause the kernel to call arbitrary code in supervisor mode; passing any arbitrary or invalid address otherwise yields a kernel crash or out-of-bounds read.

The result is a local privilege escalation out of the userspace sandbox (with kernel denial-of-service and information disclosure as lesser outcomes). The fix adds K\_SYSCALL\_DRIVER\_FLASH(src\_dev, read) and K\_SYSCALL\_DRIVER\_FLASH(dst\_dev, write) to z\_vrfy\_flash\_copy(), which verify each device is a registered flash-driver kernel object the calling thread is permitted to use before any dereference, closing the path completely.

## Affected and fixed versions

- zephyrproject zephyr: \>= 4.0.0, \< 4.3.2; \>= 4.4.0, \< 4.4.2 (cvelist)

## Mitigation

- Upgrade zephyr to 4.4.2 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-9771. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-9771.md
Affected: zephyrproject zephyr >= 4.0.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.
```

## FAQ

### Is CVE-2026-9771 being exploited?

There is no confirmed exploitation: CVE-2026-9771 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.14% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2026-9771?

High: CVSS 8.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-9771?

zephyrproject zephyr \>= 4.0.0, \< 4.3.2; \>= 4.4.0, \< 4.4.2.

### Is there a fix for CVE-2026-9771?

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-9771?

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.

## References

- vendor: <https://github.com/zephyrproject-rtos/zephyr/security/advisories/GHSA-68cj-3hg4-5vpm>
- patch: <https://github.com/zephyrproject-rtos/zephyr/commit/1b1ecdc438092cdd469319a0d51cba6cf82e06f4>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-9771>

HTML: <https://flawdb.com/CVE-2026-9771> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-9771>
