CVE-2025-21781 json
batman-adv: fix panic during interface removal
published 2025-02-27 20 mo ago modified 2026-06-17 4 mo ago also EUVD-2025-5148
- cvss
- 5.5
- version 3.1, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.2%
- EPSS 0.2% chance of exploitation in 30 days, percentile 13%
- public exploits
- 0
- none known
Summary
In the Linux kernel, the following vulnerability has been resolved:
batman-adv: fix panic during interface removal
Reference counting is used to ensure that batadv_hardif_neigh_node and batadv_hard_iface are not freed before/during batadv_v_elp_throughput_metric_update work is finished.
But there isn't a guarantee that the hard if will remain associated with a soft interface up until the work is finished.
This fixes a crash triggered by reboot that looks like this:
Call trace: batadv_v_mesh_free+0xd0/0x4dc [batman_adv] batadv_v_elp_throughput_metric_update+0x1c/0xa4 process_one_work+0x178/0x398 worker_thread+0x2e8/0x4d0 kthread+0xd8/0xdc ret_from_fork+0x10/0x20
(the batadv_v_mesh_free call is misleading, and does not actually happen)
I was able to make the issue happen more reliably by changing hardif_neigh->bat_v.metric_work work to be delayed work. This allowed me to track down and confirm the fix.
[sven@narfation.org: prevent entering batadv_v_elp_get_throughput without soft_iface]
Patch / fix
- Linux Linux 5.4.291, 5.10.235, 5.15.179, 6.1.129, 6.6.79, 6.12.16, 6.13.4, 6.14
- linux Debian 12 6.1.129-1
- linux Debian 14, Debian 13 6.12.16-1
debian advisories DEBIAN-CVE-2025-21781
- linux Ubuntu 20.04 LTS 5.4.0-216.236
- linux Ubuntu 22.04 LTS 5.15.0-140.150
- linux Ubuntu 24.04 LTS 6.8.0-78.78
- linux-aws Ubuntu 20.04 LTS 5.4.0-1146.156
- linux-aws Ubuntu 22.04 LTS 5.15.0-1084.91
- linux-aws Ubuntu 24.04 LTS 6.8.0-1035.37
- linux-gcp Ubuntu 20.04 LTS 5.4.0-1149.158
- linux-gcp Ubuntu 22.04 LTS 5.15.0-1083.92
ubuntu advisories UBUNTU-CVE-2025-21781
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- kernel-coco SLE Module for Confidential Computing Technical Preview 15 SP6 6.4.0-15061.21.coco15sp6.1
- kernel-syms-coco SLE Module for Confidential Computing Technical Preview 15 SP6 6.4.0-15061.21.coco15sp6.1
- kernel-coco_debug SLE Module for Confidential Computing Technical Preview 15 SP6 6.4.0-15061.21.coco15sp6.1
- kernel-source-coco SLE Module for Confidential Computing Technical Preview 15 SP6 6.4.0-15061.21.coco15sp6.1
- kernel-source Linux Micro 6.1, Linux Micro 6.0 6.4.0-28.1
- kernel-default Linux Micro 6.1, Linux Micro 6.0 6.4.0-28.1
- kernel-kvmsmall Linux Micro 6.1, Linux Micro 6.0 6.4.0-28.1
- kernel-default-base Linux Micro 6.1, Linux Micro 6.0 6.4.0-28.1.21.6
suse advisories SUSE-SU-2025:01919-1SUSE-SU-2025:20192-1SUSE-SU-2025:20270-1SUSE-SU-2025:20190-1SUSE-SU-2025:20260-1SUSE-SU-2025:1180-1
- git.kernel.org/stable/c/167422a07096a6006599067c8b55884064fa0b72 commit
- git.kernel.org/stable/c/ce3f1545bf8fa28bd05ec113679e8e6cd23af577 commit
- git.kernel.org/stable/c/f0a16c6c79768180333f3e41ce63f32730e3c3af commit
- git.kernel.org/stable/c/7eb5dd201695645af071592a50026eb780081a72 commit
- git.kernel.org/stable/c/072b2787321903287a126c148e8db87dd7ef96fe commit
- git.kernel.org/stable/c/2c3fb7df4cc6d043f70d4a8a10f8b915bbfb75e7 commit
- git.kernel.org/stable/c/522b1596ea19e327853804da2de60aeb9c5d6f42 commit
- git.kernel.org/stable/c/ccb7276a6d26d6f8416e315b43b45e15ee7f29e2 commit
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2025-21781 updated
kernel: batman-adv: fix panic during interface removal
-
Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 more Red Hat Enterprise Linux 7 perf, kernel, bpftool, kernel-rt, python-perf, kernel-kdump, +8 more Red Hat Enterprise Linux 8 perf, kernel, bpftool, kernel-rt, kernel-core, kernel-tools, +29 more Red Hat Enterprise Linux 9 rv, perf, rtla, kernel, bpftool, libperf, +83 more Red Hat Enterprise Linux 10 kernelnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Exploit prediction
0.22% chance of exploitation in the next 30 days, higher than 13% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Affected products
- Linux Linux
Classification
- Technology feeds
References
-
git.kernel.org
/stable/c/167422a07096a6006599067c8b55884064fa0b72
patch
-
git.kernel.org
/stable/c/ce3f1545bf8fa28bd05ec113679e8e6cd23af577
patch
-
git.kernel.org
/stable/c/f0a16c6c79768180333f3e41ce63f32730e3c3af
patch
-
git.kernel.org
/stable/c/7eb5dd201695645af071592a50026eb780081a72
patch
-
git.kernel.org
/stable/c/072b2787321903287a126c148e8db87dd7ef96fe
patch
-
git.kernel.org
/stable/c/2c3fb7df4cc6d043f70d4a8a10f8b915bbfb75e7
patch
-
git.kernel.org
/stable/c/522b1596ea19e327853804da2de60aeb9c5d6f42
patch
-
git.kernel.org
/stable/c/ccb7276a6d26d6f8416e315b43b45e15ee7f29e2
patch
- lists.debian.org /debian-lts-announce/2025/05/msg00030.html
- lists.debian.org /debian-lts-announce/2025/03/msg00028.html
Sources
- CVE List CVE-2025-21781
- NVD CVE-2025-21781
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.