CVE-2025-39851: vxlan: Fix NPD when refreshing an FDB entry with a nexthop object
In the Linux kernel, the following vulnerability has been resolved:
vxlan: Fix NPD when refreshing an FDB entry with a nexthop object
VXLAN FDB entries can point to either a remote destination or an FDB
nexthop group. The latter is usually used in EVPN deployments where
learning is disabled.
However, when learning is enabled, an incoming packet might try to
refresh an FDB entry that points to an FDB nexthop group and therefore
does not have a remote. Such packets should be dropped, but they are
only dropped after dereferencing the non-existent remote, resulting in a
NPD [1] which can be reproduced using [2].
Fix by dropping such packets earlier. Remove the misleading comment from
first_remote_rcu().
[1]
BUG: kernel NULL pointer dereference, address: 0000000000000000
[...]
CPU: 13 UID: 0 PID: 361 Comm: mausezahn Not tainted 6.17.0-rc1-virtme-g9f6b606b6b37 #1 PREEMPT(voluntary)
Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.17.0-4.fc41 04/01/2014
RIP: 0010:vxlan_snoop+0x98/0x1e0
[...]
Call Trace:
<TASK>
vxlan_encap_bypass+0x209/0x240
encap_bypass_if_local+0xb1/0x100
vxlan_xmit_one+0x1375/0x17e0
vxlan_xmit+0x6b4/0x15f0
dev_hard_start_xmit+0x5d/0x1c0
__dev_queue_xmit+0x246/0xfd0
packet_sendmsg+0x113a/0x1850
__sock_sendmsg+0x38/0x70
__sys_sendto+0x126/0x180
__x64_sys_sendto+0x24/0x30
do_syscall_64+0xa4/0x260
entry_SYSCALL_64_after_hwframe+0x4b/0x53
[2]
#!/bin/bash
ip address add 192.0.2.1/32 dev lo
ip address add 192.0.2.2/32 dev lo
ip nexthop add id 1 via 192.0.2.3 fdb
ip nexthop add id 10 group 1 fdb
ip link add name vx0 up type vxlan id 10010 local 192.0.2.1 dstport 12345 localbypass
ip link add name vx1 up type vxlan id 10020 local 192.0.2.2 dstport 54321 learning
bridge fdb add 00:11:22:33:44:55 dev vx0 self static dst 192.0.2.2 port 54321 vni 10020
bridge fdb add 00:aa:bb:cc:dd:ee dev vx1 self static nhid 10
mausezahn vx0 -a 00:aa:bb:cc:dd:ee -b 00:11:22:33:44:55 -c 1 -q
Security readout for executives and security teams
Plain-English summary
A flaw in the Linux VXLAN networking code can cause a kernel NULL-pointer dereference and potentially crash the system. It occurs when an incoming packet refreshes a forwarding entry tied to a nexthop group while VXLAN learning is enabled. The primary business risk is service disruption on affected network infrastructure or hosts.
Executive priority
Prioritize affected VXLAN or EVPN infrastructure because successful triggering may interrupt network or host availability without authentication. Patch reachable production systems promptly after compatibility testing. Systems not using the specific VXLAN learning and nexthop-group combination are lower priority, but version and configuration evidence should support that conclusion.
Technical view
CVE-2025-39851 is a CWE-476 flaw in vxlan_snoop(). An FDB nexthop-group entry has no remote destination, but the vulnerable path dereferences that missing remote before rejecting the packet. The upstream correction moves the rejection earlier. CVSS 3.1 rates it 7.5: network-accessible, low complexity, unauthenticated, and availability-only.
Likely exposure
Exposure is concentrated in Linux systems using VXLAN with learning enabled and FDB entries referencing nexthop groups, commonly associated with EVPN deployments. An attacker must be able to deliver relevant traffic into the affected VXLAN forwarding path. The supplied version data includes 5.8, 6.12.46, 6.16.6, and 6.17, but distro backports require verification.
Exploitation context
The supplied record is not in CISA KEV and provides no evidence of active exploitation. A reproducer existed for confirming the crash, but that alone does not establish real-world attacks. Practical reachability depends on VXLAN topology and traffic access.
Researcher notes
The vulnerable state requires an FDB entry backed by an FDB nexthop group, no remote destination, and a learning-enabled VXLAN path attempting a refresh. The fix drops the packet before remote dereference. The supplied affected-version representation is incomplete or ambiguous, so map upstream commits to distribution packages before declaring exposure or remediation.
Mitigation direction
Apply a vendor-supported kernel containing the referenced VXLAN fix.
Check distribution advisories for backported fixes and corrected package versions.
Restrict untrusted traffic from reaching affected VXLAN forwarding paths until patched.
Disable unnecessary VXLAN learning or affected configurations only after operational review.
Validation and detection
Inventory Linux kernel versions on systems providing VXLAN or EVPN networking.
Identify VXLAN interfaces using learning alongside FDB nexthop-group entries.
Confirm the installed vendor kernel incorporates the applicable referenced fix.
Review kernel logs for NULL-pointer dereferences involving vxlan_snoop.
Validate remediation safely in staging without reproducing the crash in production.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-476: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-476 · source CWE mapping
NULL Pointer Dereference
NULL Pointer Dereference represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.