Skip to content
Not rated

CVE-2026-31422 net/sched: cls_flow: fix NULL pointer dereference on shared blocks

Description

In the Linux kernel, the following vulnerability has been resolved: net/sched: cls_flow: fix NULL pointer dereference on shared blocks flow_change() calls tcf_block_q() and dereferences q->handle to derive a default baseclass. Shared blocks leave block->q NULL, causing a NULL deref when a flow filter without a fully qualified baseclass is created on a shared block. Check tcf_block_shared() before accessing block->q and return -EINVAL for shared blocks. This avoids the null-deref shown below: ======================================================================= KASAN: null-ptr-deref in range [0x0000000000000038-0x000000000000003f] RIP: 0010:flow_change (net/sched/cls_flow.c:508) Call Trace: tc_new_tfilter (net/sched/cls_api.c:2432) rtnetlink_rcv_msg (net/core/rtnetlink.c:6980) [...] =======================================================================

Affected products and versions

Product Affected versions Fixed in
Linux 7.0 earliest → < 7.0 7.0
Linux 6.19 earliest → < 6.19.12 6.19.12
Linux 6.18 earliest → < 6.18.22 6.18.22
Linux 6.12 earliest → < 6.12.81 6.12.81
Linux 6.6 earliest → < 6.6.134 6.6.134
Linux 6.1 earliest → < 6.1.168 6.1.168
Linux 5.15 earliest → < 5.15.203 5.15.203
Linux 5.10 earliest → < 5.10.253 5.10.253
Linux 4.15 No fix stated
Show the 3 other branches
Product Affected versions Fixed in
SIMATIC S7-1500 CPU 1518-4 PN/DP MFP 3.1 3.1.7 → latest No fix stated
SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP 3.1 3.1.7 → latest No fix stated
SIPLUS S7-1500 CPU 1518-4 PN/DP MFP 3.1 3.1.7 → latest No fix stated
The 18286 CVEs of Linux →
Track this CVE