# CVE-2024-26895: wifi: wilc1000: prevent use-after-free on vif when cleaning up all interfaces

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

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; 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.33% (percentile 18, 2026-11-26)
- **CWE:** CWE-416
- **Published:** 2024-04-17T10:27:46.585Z
- **Modified:** 2026-10-15T01:17:30.123Z

## Who should check

- Anyone running Linux \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 5956f4203b6cdd0755bbdd21b45f3933c7026208; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< fe20e3d56bc911408fc3c27a17c59e9d7885f7d1; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< a9545af2a533739ffb64d6c9a6fec6f13e2b505f; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 24228dcf1d30c2231caa332be7d3090ac59fbfe9; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< cb5942b77c05d54310a0420cac12935e9b6aa21c
- Anyone running Linux 5.5

## Description

In the Linux kernel, the following vulnerability has been resolved:

wifi: wilc1000: prevent use-after-free on vif when cleaning up all interfaces

wilc\_netdev\_cleanup currently triggers a KASAN warning, which can be
observed on interface registration error path, or simply by
removing the module/unbinding device from driver:

echo spi0.1 \> /sys/bus/spi/drivers/wilc1000\_spi/unbind

==================================================================
BUG: KASAN: slab-use-after-free in wilc\_netdev\_cleanup+0x508/0x5cc
Read of size 4 at addr c54d1ce8 by task sh/86

CPU: 0 PID: 86 Comm: sh Not tainted 6.8.0-rc1+ \#117
Hardware name: Atmel SAMA5
 unwind\_backtrace from show\_stack+0x18/0x1c
 show\_stack from dump\_stack\_lvl+0x34/0x58
 dump\_stack\_lvl from print\_report+0x154/0x500
 print\_report from kasan\_report+0xac/0xd8
 kasan\_report from wilc\_netdev\_cleanup+0x508/0x5cc
 wilc\_netdev\_cleanup from wilc\_bus\_remove+0xc8/0xec
 wilc\_bus\_remove from spi\_remove+0x8c/0xac
 spi\_remove from device\_release\_driver\_internal+0x434/0x5f8
 device\_release\_driver\_internal from unbind\_store+0xbc/0x108
 unbind\_store from kernfs\_fop\_write\_iter+0x398/0x584
 kernfs\_fop\_write\_iter from vfs\_write+0x728/0xf88
 vfs\_write from ksys\_write+0x110/0x1e4
 ksys\_write from ret\_fast\_syscall+0x0/0x1c

\[...\]

Allocated by task 1:
 kasan\_save\_track+0x30/0x5c
 \_\_kasan\_kmalloc+0x8c/0x94
 \_\_kmalloc\_node+0x1cc/0x3e4
 kvmalloc\_node+0x48/0x180
 alloc\_netdev\_mqs+0x68/0x11dc
 alloc\_etherdev\_mqs+0x28/0x34
 wilc\_netdev\_ifc\_init+0x34/0x8ec
 wilc\_cfg80211\_init+0x690/0x910
 wilc\_bus\_probe+0xe0/0x4a0
 spi\_probe+0x158/0x1b0
 really\_probe+0x270/0xdf4
 \_\_driver\_probe\_device+0x1dc/0x580
 driver\_probe\_device+0x60/0x140
 \_\_driver\_attach+0x228/0x5d4
 bus\_for\_each\_dev+0x13c/0x1a8
 bus\_add\_driver+0x2a0/0x608
 driver\_register+0x24c/0x578
 do\_one\_initcall+0x180/0x310
 kernel\_init\_freeable+0x424/0x484
 kernel\_init+0x20/0x148
 ret\_from\_fork+0x14/0x28

Freed by task 86:
 kasan\_save\_track+0x30/0x5c
 kasan\_save\_free\_info+0x38/0x58
 \_\_kasan\_slab\_free+0xe4/0x140
 kfree+0xb0/0x238
 device\_release+0xc0/0x2a8
 kobject\_put+0x1d4/0x46c
 netdev\_run\_todo+0x8fc/0x11d0
 wilc\_netdev\_cleanup+0x1e4/0x5cc
 wilc\_bus\_remove+0xc8/0xec
 spi\_remove+0x8c/0xac
 device\_release\_driver\_internal+0x434/0x5f8
 unbind\_store+0xbc/0x108
 kernfs\_fop\_write\_iter+0x398/0x584
 vfs\_write+0x728/0xf88
 ksys\_write+0x110/0x1e4
 ret\_fast\_syscall+0x0/0x1c
 \[...\]

David Mosberger-Tan initial investigation \[1\] showed that this
use-after-free is due to netdevice unregistration during vif list
traversal. When unregistering a net device, since the needs\_free\_netdev has
been set to true during registration, the netdevice object is also freed,
and as a consequence, the corresponding vif object too, since it is
attached to it as private netdevice data. The next occurrence of the loop
then tries to access freed vif pointer to the list to move forward in the
list.

Fix this use-after-free thanks to two mechanisms:
- navigate in the list with list\_for\_each\_entry\_safe, which allows to
  safely modify the list as we go through each element. For each element,
  remove it from the list with list\_del\_rcu
- make sure to wait for RCU grace period end after each vif removal to make
  sure it is safe to free the corresponding vif too (through
  unregister\_netdev)

Since we are in a RCU "modifier" path (not a "reader" path), and because
such path is expected not to be concurrent to any other modifier (we are
using the vif\_mutex lock), we do not need to use RCU list API, that's why
we can benefit from list\_for\_each\_entry\_safe.

\[1\] https://lore.kernel.org/linux-wireless/ab077dbe58b1ea5de0a3b2ca21f275a07af967d2.camel@egauge.net/

## Affected and fixed versions

- Linux: \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 5956f4203b6cdd0755bbdd21b45f3933c7026208; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< fe20e3d56bc911408fc3c27a17c59e9d7885f7d1; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< a9545af2a533739ffb64d6c9a6fec6f13e2b505f; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 24228dcf1d30c2231caa332be7d3090ac59fbfe9; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< cb5942b77c05d54310a0420cac12935e9b6aa21c (cvelist)
- Linux: 5.5 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

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

Details: https://flawdb.com/CVE-2024-26895.md
Affected: Linux >= 8399918f3056e1033f0f4c08eab437fb38d6f22d, < 5956f4203b6cdd0755bbdd21b45f3933c7026208; >= 8399918f3056e1033f0f4c08eab437fb38d6f22d, < fe20e3d56bc911408fc3c27a17c59e9d7885f7d1; >= 8399918f3056e1033f0f4c08eab437fb38d6f22d, < a9545af2a533739ffb64d6c9a6fec6f13e2b505f; >= 8399918f3056e1033f0f4c0…
Fixed in: Linux 5956f4203b6cdd0755bbdd21b45f3933c7026208, Linux 3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447, Linux 24228dcf1d30c2231caa332be7d3090ac59fbfe9, Linux 73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb

Steps:
1. Search this machine and project for Linux: 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-2024-26895 being exploited?

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

### How serious is CVE-2024-26895?

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

### Which versions are affected by CVE-2024-26895?

Linux \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 5956f4203b6cdd0755bbdd21b45f3933c7026208; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< fe20e3d56bc911408fc3c27a17c59e9d7885f7d1; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< a9545af2a533739ffb64d6c9a6fec6f13e2b505f; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 24228dcf1d30c2231caa332be7d3090ac59fbfe9; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< 73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb; \>= 8399918f3056e1033f0f4c08eab437fb38d6f22d, \< cb5942b77c05d54310a0420cac12935e9b6aa21c; Linux 5.5.

### Is there a fix for CVE-2024-26895?

Yes. Fixed in Linux 5956f4203b6cdd0755bbdd21b45f3933c7026208, Linux 3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447, Linux 24228dcf1d30c2231caa332be7d3090ac59fbfe9, Linux 73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2024-26895?

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

- patch: <https://git.kernel.org/stable/c/5956f4203b6cdd0755bbdd21b45f3933c7026208>
- patch: <https://git.kernel.org/stable/c/fe20e3d56bc911408fc3c27a17c59e9d7885f7d1>
- patch: <https://git.kernel.org/stable/c/a9545af2a533739ffb64d6c9a6fec6f13e2b505f>
- patch: <https://git.kernel.org/stable/c/3da9d32b7f4a1a9f7e4bb15bb82f2b2dd6719447>
- patch: <https://git.kernel.org/stable/c/24228dcf1d30c2231caa332be7d3090ac59fbfe9>
- patch: <https://git.kernel.org/stable/c/73a2aa0aef86c2c07be5a2f42c9e6047e1a2f7bb>
- patch: <https://git.kernel.org/stable/c/cb5942b77c05d54310a0420cac12935e9b6aa21c>
- other: <https://lists.debian.org/debian-lts-announce/2024/06/msg00017.html>
- other: <https://cert-portal.siemens.com/productcert/html/ssa-265688.html>

## 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-2024-26895>

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