# CVE-2026-105418: NULL pointer dereference in SocketCAN getsockopt/setsockopt on an unbound socket

- **Severity:** MEDIUM 5.5
- **CVSS:** 5.5 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; 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)
- **CWE:** CWE-476
- **Published:** 2026-12-02T05:20:32.362Z
- **Modified:** 2026-12-02T06:17:24.140Z

> **AI summary (AI-generated, claude-haiku-5-5):** An unprivileged local user can crash the Zephyr kernel via a NULL pointer dereference by calling setsockopt or getsockopt on an unbound SocketCAN socket.

## Who should check

- Anyone running zephyrproject zephyr \>= 2.0.0, \< 4.3.2; \>= 4.4.0, \< 4.5.0

## Description

The SocketCAN socket layer in subsys/net/lib/sockets/sockets\_can.c dereferences a NULL device pointer when a NET\_SOL\_CAN\_RAW socket option is read or written on a CAN socket that has not yet been bound. A freshly created CAN socket has interface index -1. net\_context\_get\_iface() therefore returns NULL, net\_if\_get\_device() returns NULL, and can\_sock\_setsockopt\_vmeth() / can\_sock\_getsockopt\_vmeth() read dev-\>api without a check and then call through the resulting pointer.

Any thread that can create a CAN socket can trigger the dereference by calling setsockopt() or getsockopt() at level SOL\_CAN\_RAW before bind(). That ordering is common in code ported from Linux. Because zsock\_socket, zsock\_setsockopt and zsock\_getsockopt are system calls, an unprivileged user-mode thread on a CONFIG\_USERSPACE build with CONFIG\_NET\_SOCKETS\_CAN enabled can make the kernel perform the faulting access in supervisor mode.

The result is a kernel fatal error that halts or resets the system: a local denial of service across the user/kernel boundary. On targets without NULL-pointer fault detection, the kernel instead makes an indirect call through a value read from low memory, which the attacker does not control. Builds without CONFIG\_USERSPACE gain no privilege boundary from this defect. The fix makes both socket-option handlers fail with ENODEV until the socket is bound to a CAN interface.

## Affected and fixed versions

- zephyrproject zephyr: \>= 2.0.0, \< 4.3.2; \>= 4.4.0, \< 4.5.0 (cvelist)

## Technologies

Zephyr RTOS

## Mitigation

- Upgrade zephyr to 4.5.0 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-105418. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-105418.md
Affected: zephyrproject zephyr >= 2.0.0, < 4.3.2; >= 4.4.0, < 4.5.0
Fixed in: zephyrproject zephyr 4.3.2, zephyrproject zephyr 4.5.0

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-105418 being exploited?

There is no confirmed exploitation: CVE-2026-105418 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known.

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

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

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

zephyrproject zephyr \>= 2.0.0, \< 4.3.2; \>= 4.4.0, \< 4.5.0.

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

Yes. Fixed in zephyrproject zephyr 4.3.2, zephyrproject zephyr 4.5.0. Upgrade zephyr to 4.5.0 or later.

### How do I check if I'm affected by CVE-2026-105418?

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-r5vr-3m56-grq2>
- patch: <https://github.com/zephyrproject-rtos/zephyr/commit/c7bb91ec09ed58dac9b04e4fb03a8b767f17aed0>

## 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-105418>

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