CVE-2026-45859: netfilter: nfnetlink_queue: do shared-unconfirmed check before segmentation
From: Greg Kroah-Hartman <[email protected]>
Description
===========
In the Linux kernel, the following vulnerability has been resolved:
netfilter: nfnetlink_queue: do shared-unconfirmed check before segmentation
Ulrich reports a regression with nfqueue:
If an application did not set the 'F_GSO' capability flag and a gso packet with an unconfirmed nf_conn entry is received all packets are now dropped instead of queued, because the check happens after skb_gso_segment(). In that case, we did have exclusive ownership of the skb and its associated conntrack entry. The elevated use count is due to skb_clone happening via skb_gso_segment().
Move the check so that its peformed vs. the aggregated packet.
Then, annotate the individual segments except the first one so we can do a 2nd check at reinject time.
For the normal case, where userspace does in-order reinjects, this avoids packet drops: first reinjected segment continues traversal and confirms entry, remaining segments observe the confirmed entry.
While at it, simplify nf_ct_drop_unconfirmed(): We only care about unconfirmed entries with a refcnt > 1, there is no need to special-case dying entries.
This only happens with UDP. With TCP, the only unconfirmed packet will be the TCP SYN, those aren't aggregated by GRO.
Next patch adds a udpgro test case to cover this scenario.
The Linux kernel CVE team has assigned CVE-2026-45859 to this issue.
Affected and fixed versions
===========================
Issue introduced in 6.11 with commit 7d8dc1c7be8d3509e8f5164dd5df64c8e34d7eeb and fixed in 6.12.75 with commit 79b713ef4261a8ead96af4703f89d0b5f25532e2 Issue introduced in 6.11 with commit 7d8dc1c7be8d3509e8f5164dd5df64c8e34d7eeb and fixed in 6.18.14 with commit 23901aa6b8a2f294c4b774436b4691f3ff863a8f Issue introduced in 6.11 with commit 7d8dc1c7be8d3509e8f5164dd5df64c8e34d7eeb and fixed in 6.19.4 with commit b740e7ddd7ca0dbfeafca3f5e52717206cf28524 Issue introduced in 6.11 with commit 7d8dc1c7be8d3509e8f5164dd5df64c8e34d7eeb and fixed in 7.0 with commit 207b3ebacb6113acaaec0d171d5307032c690004 Issue introduced in 5.15.166 with commit 6c4a0ba674f410ab99a30a16f32dac0ebfed5cd3 Issue introduced in 6.1.107 with commit 6dcc8ba8a6074bb79040f502dc66ad23a58a1c86 Issue introduced in 6.6.48 with commit 74e6eb7fd27ef1ccc68041dbc66e6d80d2e4a1a0 Issue introduced in 6.10.7 with commit 025b3326c5c409b372d0103ad30f174e55adbd1b
Please see https://www.kernel.org for a full list of currently supported kernel versions by the kernel community.
Unaffected versions might change over time as fixes are backported to older supported kernel versions. The official CVE entry at
https://cve.org/CVERecord/?id=CVE-2026-45859
will be updated if fixes are backported, please check that for the most up to date information about this issue.
Affected files
==============
The file(s) affected by this issue are:
include/net/netfilter/nf_queue.h
net/netfilter/nfnetlink_queue.c
Mitigation
==========
The Linux kernel CVE team recommends that you update to the latest stable kernel version for this, and many other bugfixes. Individual changes are never tested alone, but rather are part of a larger kernel release. Cherry-picking individual commits is not recommended or supported by the Linux kernel community at all. If however, updating to the latest release is impossible, the individual changes to resolve this issue can be found at these commits:
https://git.kernel.org/stable/c/79b713ef4261a8ead96af4703f89d0b5f25532e2 https://git.kernel.org/stable/c/23901aa6b8a2f294c4b774436b4691f3ff863a8f https://git.kernel.org/stable/c/b740e7ddd7ca0dbfeafca3f5e52717206cf28524 https://git.kernel.org/stable/c/207b3ebacb6113acaaec0d171d5307032c690004