net: vlan: fix VLAN 0 refcount imbalance of toggling filtering during runtime
Key facts
- Attack vector
- Local
- Privileges required
- Low
- User interaction
- None
- Attack complexity
- Low
- Impact type
- —
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- Partial Red Hat: 10 fixed, 4 without a fix
Attack profile from CVSS 3.1 · CNA. Fix status from CNA and Red Hat.
Summary
In the Linux kernel, the following vulnerability has been resolved: net: vlan: fix VLAN 0 refcount imbalance of toggling filtering during runtime Assuming the "rx-vlan-filter" feature is enabled on a net device, the 8021q module will automatically add or remove VLAN 0 when the net device is put administratively up or down, respectively. There are a couple of problems with the above scheme. The first problem is a memory leak that can happen if the "rx-vlan-filter" feature is disabled while the device is running: # ip link add bond1 up type bond mode 0 # ethtool -K bond1 rx-vlan-filter off # ip link del dev bond1 When the device is put administratively down the "rx-vlan-filter" feature is disabled, so the 8021q module will not remove VLAN 0 and the memory will be leaked [1]. Another problem that can happen is that the kernel can automatically delete VLAN 0 when the device is put administratively down despite not adding it when the device was put administratively up since during that time the "rx-vlan-filter" feature was disabled. null-ptr-unref or bug_on[2] will be triggered by unregister_vlan_dev() for refcount imbalance if toggling filtering during runtime: $ ip link add bond0 type bond mode 0 $ ip link add link bond0 name vlan0 type vlan id 0 protocol 802.1q $ ethtool -K bond0 rx-vlan-filter off $ ifconfig bond0 up $ ethtool -K bond0 rx-vlan-filter on $ ifconfig bond0 down $ ip link del vlan0 Root cause is as below: step1: add vlan0 for real_dev, such as bond, team. register_vlan_dev vlan_vid_add(real_dev,htons(ETH_P_8021Q),0) //refcnt=1 step2: disable vlan filter feature and enable real_dev step3: change filter from 0 to 1 vlan_device_event vlan_filter_push_vids ndo_vlan_rx_add_vid //No refcnt added to real_dev vlan0 step4: real_dev down vlan_device_event vlan_vid_del(dev, htons(ETH_P_8021Q), 0); //refcnt=0 vlan_info_rcu_free //free vlan0 step5: delete vlan0 unregister_vlan_dev BUG_ON(!vlan_info); //vlan_info is null Fix both problems by noting in the VLAN info whether VLAN 0 was automatically added upon NETDEV_UP and based on that decide whether it should be deleted upon NETDEV_DOWN, regardless of the state of the "rx-vlan-filter" feature. [1] unreferenced object 0xffff8880068e3100 (size 256): comm "ip", pid 384, jiffies 4296130254 hex dump (first 32 bytes): 00 20 30 0d 80 88 ff ff 00 00 00 00 00 00 00 00 . 0............. 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ backtrace (crc 81ce31fa): __kmalloc_cache_noprof+0x2b5/0x340 vlan_vid_add+0x434/0x940 vlan_device_event.cold+0x75/0xa8 notifier_call_chain+0xca/0x150 __dev_notify_flags+0xe3/0x250 rtnl_configure_link+0x193/0x260 rtnl_newlink_create+0x383/0x8e0 __rtnl_newlink+0x22c/0xa40 rtnl_newlink+0x627/0xb00 rtnetlink_rcv_msg+0x6fb/0xb70 netlink_rcv_skb+0x11f/0x350 netlink_unicast+0x426/0x710 netlink_sendmsg+0x75a/0xc20 __sock_sendmsg+0xc1/0x150 ____sys_sendmsg+0x5aa/0x7b0 ___sys_sendmsg+0xfc/0x180 [2] kernel BUG at net/8021q/vlan.c:99! Oops: invalid opcode: 0000 [#1] SMP KASAN PTI CPU: 0 UID: 0 PID: 382 Comm: ip Not tainted 6.16.0-rc3 #61 PREEMPT(voluntary) Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.13.0-0-gf21b5a4aeb02-prebuilt.qemu.org 04/01/2014 RIP: 0010:unregister_vlan_dev (net/8021q/vlan.c:99 (discriminator 1)) RSP: 0018:ffff88810badf310 EFLAGS: 00010246 RAX: 0000000000000000 RBX: ffff88810da84000 RCX: ffffffffb47ceb9a RDX: dffffc0000000000 RSI: 0000000000000008 RDI: ffff88810e8b43c8 RBP: 0000000000000000 R08: 0000000000000000 R09: fffffbfff6cefe80 R10: ffffffffb677f407 R11: ffff88810badf3c0 R12: ffff88810e8b4000 R13: 0000000000000000 R14: ffff88810642a5c0 R15: 000000000000017e FS: 00007f1ff68c20c0(0000) GS:ffff888163a24000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f1ff5dad240 CR3: 0000000107e56000 CR4: 00000000000006f0 Call Trace: <TASK ---truncated---
Why it matters now
SSVC decision points
CISA ADP · SSVC 2.0.3
- Exploitation
- None
- Automatable
- No
- Technical impact
- Total
The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.
Affected products
| Vendor | Product | Affected versions | Fixed in | Status | Source |
|---|---|---|---|---|---|
| Linux | Linux | 2.6.36 and later | 5.4.297, 5.10.241, 5.15.190, 6.1.147, 6.6.100, 6.12.40, 6.15.8, 6.16 | Patch available | CNA |
- Linux VendorLinux Affected 2.6.36 and later Fixed in 5.4.297, 5.10.241, 5.15.190, 6.1.147, 6.6.100, 6.12.40, 6.15.8, 6.16 Patch available CNA
CPE configurations NVD · 8
| CPE | Versions | Role | Vendor |
|---|---|---|---|
| cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* | 2.6.36 to before 5.4.297; 5.5 to before 5.10.241; 5.11 to before 5.15.190; 5.16 to before 6.1.147; 6.2 to before 6.6.100; 6.7 to before 6.12.40; 6.13 to before 6.15.8 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc1:*:*:*:*:*:* | 6.16 rc1 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc2:*:*:*:*:*:* | 6.16 rc2 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc3:*:*:*:*:*:* | 6.16 rc3 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc4:*:*:*:*:*:* | 6.16 rc4 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc5:*:*:*:*:*:* | 6.16 rc5 | Vulnerable | Linux |
| cpe:2.3:o:linux:linux_kernel:6.16:rc6:*:*:*:*:*:* | 6.16 rc6 | Vulnerable | Linux |
| cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:* | 11.0 | Vulnerable | Debian |
- cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:* Versions 2.6.36 to before 5.4.297; 5.5 to before 5.10.241; 5.11 to before 5.15.190; 5.16 to before 6.1.147; 6.2 to before 6.6.100; 6.7 to before 6.12.40; 6.13 to before 6.15.8 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc1:*:*:*:*:*:* Versions 6.16 rc1 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc2:*:*:*:*:*:* Versions 6.16 rc2 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc3:*:*:*:*:*:* Versions 6.16 rc3 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc4:*:*:*:*:*:* Versions 6.16 rc4 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc5:*:*:*:*:*:* Versions 6.16 rc5 Vulnerable ·Linux
- cpe:2.3:o:linux:linux_kernel:6.16:rc6:*:*:*:*:*:* Versions 6.16 rc6 Vulnerable ·Linux
- cpe:2.3:o:debian:debian_linux:11.0:*:*:*:*:*:*:* Versions 11.0 Vulnerable ·Debian
Remediation
- Fix · CNA Linux (Linux) Fixed in 5.4.297, 5.10.241, 5.15.190, 6.1.147, 6.6.100, 6.12.40, 6.15.8, 6.16
Red Hat 2 advisories
- RHSA-2026:18587 Released 2026-05-19 · Red Hat rating Moderatekernel security update
- Red Hat Enterprise Linux AppStream (v. 9) kernel-64k-debug-devel-5.14.0-687.5.1.el9_8, kernel-64k-debug-devel-matched-5.14.0-687.5.1.el9_8, kernel-64k-devel-5.14.0-687.5.1.el9_8 +12
- Red Hat Enterprise Linux BaseOS (v. 9) kernel-5.14.0-687.5.1.el9_8, kernel-64k-5.14.0-687.5.1.el9_8, kernel-64k-core-5.14.0-687.5.1.el9_8 +28
- Red Hat Enterprise Linux CodeReady Linux Builder (v. 9) kernel-tools-libs-devel-5.14.0-687.5.1.el9_8, libperf-5.14.0-687.5.1.el9_8
- Red Hat Enterprise Linux Real Time (v. 9) kernel-rt-5.14.0-687.5.1.el9_8, kernel-rt-64k-5.14.0-687.5.1.el9_8, kernel-rt-64k-core-5.14.0-687.5.1.el9_8 +21
- Red Hat Enterprise Linux Real Time for NFV (v. 9) kernel-rt-5.14.0-687.5.1.el9_8, kernel-rt-core-5.14.0-687.5.1.el9_8, kernel-rt-debug-5.14.0-687.5.1.el9_8 +9
- RHSA-2026:18134 Released 2026-05-19 · Red Hat rating Moderatekernel security update
- Red Hat Enterprise Linux AppStream (v. 10) kernel-64k-debug-devel-6.12.0-211.7.1.el10_2, kernel-64k-debug-devel-matched-6.12.0-211.7.1.el10_2, kernel-64k-devel-6.12.0-211.7.1.el10_2 +12
- Red Hat Enterprise Linux BaseOS (v. 10) kernel-6.12.0-211.7.1.el10_2, kernel-64k-6.12.0-211.7.1.el10_2, kernel-64k-core-6.12.0-211.7.1.el10_2 +29
- Red Hat Enterprise Linux CodeReady Linux Builder (v. 10) kernel-tools-libs-devel-6.12.0-211.7.1.el10_2, libperf-6.12.0-211.7.1.el10_2
- Red Hat Enterprise Linux Real Time (v. 10) kernel-rt-6.12.0-211.7.1.el10_2, kernel-rt-64k-6.12.0-211.7.1.el10_2, kernel-rt-64k-core-6.12.0-211.7.1.el10_2 +21
- Red Hat Enterprise Linux Real Time for NFV (v. 10) kernel-rt-6.12.0-211.7.1.el10_2, kernel-rt-core-6.12.0-211.7.1.el10_2, kernel-rt-debug-6.12.0-211.7.1.el10_2 +9
Vendor assessments
Red Hat
Red Hat rating: Moderate. Red Hat's page for this CVE →
| Product | Status | Plan or fix |
|---|---|---|
| Red Hat Enterprise Linux 6 | Affected | No fix planned: Out of support scope |
| Red Hat Enterprise Linux 7 | Affected | No fix yet: Fix deferred |
| Red Hat Enterprise Linux 8 | Affected | No fix yet: Fix deferred |
| Red Hat Enterprise Linux 9 | Affected | No fix yet: Fix deferred |
| Red Hat Enterprise Linux AppStream (v. 10) | Fixed | RHSA-2026:18134 |
| Red Hat Enterprise Linux AppStream (v. 9) | Fixed | RHSA-2026:18587 |
| Red Hat Enterprise Linux BaseOS (v. 10) | Fixed | RHSA-2026:18134 |
| Red Hat Enterprise Linux BaseOS (v. 9) | Fixed | RHSA-2026:18587 |
| Red Hat Enterprise Linux CodeReady Linux Builder (v. 10) | Fixed | RHSA-2026:18134 |
| Red Hat Enterprise Linux CodeReady Linux Builder (v. 9) | Fixed | RHSA-2026:18587 |
| Red Hat Enterprise Linux Real Time (v. 10) | Fixed | RHSA-2026:18134 |
| Red Hat Enterprise Linux Real Time (v. 9) | Fixed | RHSA-2026:18587 |
| Red Hat Enterprise Linux Real Time for NFV (v. 10) | Fixed | RHSA-2026:18134 |
| Red Hat Enterprise Linux Real Time for NFV (v. 9) | Fixed | RHSA-2026:18587 |
Timeline
- 2026-10-02 Threatist record created from CVE-2025-38470
- 2026-10-03 Alias added: GHSA-wcqx-2f73-xqmx
- 2026-10-16 CISA SSVC decision points changed
References
Patch 8
- https://git.kernel.org/stable/c/ba48d3993af23753e1f1f01c8d592de9c7785f24
- https://git.kernel.org/stable/c/35142b3816832889e50164d993018ea5810955ae
- https://git.kernel.org/stable/c/047b61a24d7c866c502aeeea482892969a68f216
- https://git.kernel.org/stable/c/d43ef15bf4856c8c4c6c3572922331a5f06deb77
- https://git.kernel.org/stable/c/bb515c41306454937464da055609b5fb0a27821b
- https://git.kernel.org/stable/c/8984bcbd1edf5bee5be06ad771d157333b790c33
- https://git.kernel.org/stable/c/93715aa2d80e6c5cea1bb486321fc4585076928b
- https://git.kernel.org/stable/c/579d4f9ca9a9a605184a9b162355f6ba131f678d
More Linux Kernel vulnerabilities
- TI-2025-26358 tls: fix handling of zero-length records on the rx_list KEVCVSS 3.1CRITICAL 9.8
- TI-2026-38352 netfilter: bridge: make ebt_snat ARP rewrite writable KEVCVSS 3.1HIGH 8.8
- TI-2013-05264 The (1) get_user and (2) put_user API functions in the Linux kernel before 3.5.5 on the… KEVCVSS 3.1HIGH 8.8
- TI-2022-00125 Integer overflow in kernel KEVCVSS 3.1HIGH 8.4
- TI-2013-01864 The perf_swevent_init function in kernel/events/core.c in the Linux kernel before 3.8.9… KEVCVSS 3.1HIGH 8.4
- TI-2021-05514 Heap Out-Of-Bounds Write in Netfilter IP6T_SO_SET_REPLACE KEVCVSS 3.1HIGH 8.3
Sources
- CVE-2025-38470 · CVE Program
- CVE-2025-38470 · NVD
- FIRST EPSS
- GHSA-wcqx-2f73-xqmx · GitHub Advisory Database · CC BY 4.0
- CVE-2025-38470 · Red Hat security data · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences