CVE-2025-21857
Linux Kernel vulnerability analysis and mitigation

Overview

CVE-2025-21857 is a NULL pointer dereference vulnerability discovered in the Linux kernel's network scheduling component. The vulnerability was disclosed on March 12, 2025, affecting various versions of the Linux kernel including versions 6.13 through 6.13.5, 6.7 through 6.12.17, and 6.3 through 6.6.80. The issue occurs in the net/sched/clsapi.c file where improper error handling in the tcfextsmisscookiebasealloc() function can lead to a NULL pointer dereference (NVD).

Technical details

The vulnerability stems from incorrect error handling in the tcfextsmisscookiebasealloc() function. When xaalloccyclic() returns 1 (indicating successful allocation after wrapping), it is incorrectly treated as an error. This causes tcfextsinitex() to set exts->actions to NULL and return 1 to flchange(). The flchange() function then treats this as a success, leading to tcfextsvalidateex() calling tcfaction_init() with a NULL exts->actions argument, resulting in a NULL pointer dereference. The vulnerability has been assigned a CVSS v3.1 base score of 5.5 (Medium) (NVD).

Impact

The vulnerability can result in a kernel NULL pointer dereference, which typically leads to a system crash or denial of service condition. This can affect system stability and availability, particularly in environments where the affected network scheduling components are actively used (NVD).

Mitigation and workarounds

The vulnerability has been patched in the Linux kernel. The fix involves modifying the error handling logic in tcfextsmisscookiebase_alloc() to properly check for negative error values instead of treating all non-zero values as errors. The patch is available through multiple kernel version updates and has been backported to affected stable kernel versions (Kernel Patch).

Additional resources


SourceThis report was generated using AI

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

“Best User Experience I have ever seen, provides full visibility to cloud workloads.”
David EstlickCISO
“Wiz provides a single pane of glass to see what is going on in our cloud environments.”
Adam FletcherChief Security Officer
“We know that if Wiz identifies something as critical, it actually is.”
Greg PoniatowskiHead of Threat and Vulnerability Management