Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-93261 Overview
CVE-2026-93261 is a NULL pointer dereference vulnerability in the Linux kernel's lockdep (lock dependency validator) subsystem. The flaw resides in the __lock_set_class() function within locking/lockdep. The function calls register_lock_class() and uses the returned pointer directly in pointer arithmetic without validating that the return value is non-NULL. When the lock class pool is exhausted, graph_lock() fails, or key validation fails, register_lock_class() returns NULL. The subsequent subtraction produces a corrupted hlock->class_idx value that triggers a NULL or out-of-bounds pointer dereference during reacquire_held_locks().
Critical Impact
Local kernel crash (denial of service) through a corrupted lock class index that leads to an invalid pointer dereference inside the lockdep validator.
Affected Products
- Linux kernel versions containing the unpatched __lock_set_class() implementation in kernel/locking/lockdep.c
- Distributions shipping kernels prior to the stable backport commits referenced below
- Builds compiled with CONFIG_LOCKDEP or CONFIG_PROVE_LOCKING enabled
Discovery Timeline
- 2026-09-24 - CVE-2026-93261 published to NVD
- 2026-09-24 - Last updated in NVD database
Technical Details for CVE-2026-93261
Vulnerability Analysis
The vulnerability resides in __lock_set_class(), a lockdep helper that reclassifies a held lock. The function invokes register_lock_class() to look up or allocate a lock class descriptor, then computes the class index with pointer arithmetic: hlock->class_idx = class - lock_classes;. The code path assumes register_lock_class() always returns a valid pointer into the lock_classes[] array.
register_lock_class() can legitimately return NULL under three conditions: the global lock_classes[] pool is exhausted (MAX_LOCKDEP_KEYS reached), graph_lock() fails to acquire the lockdep internal graph lock, or lock key validation fails. When NULL is returned, the subtraction NULL - lock_classes yields a large negative offset that is stored as a corrupted class_idx. The following call to reacquire_held_locks() passes this corrupted index to hlock_class(), which performs array indexing and dereferences a wild pointer, panicking the kernel.
The __lock_acquire() function at the same call site already handles NULL correctly, so the fix brings __lock_set_class() into parity by adding the missing NULL check. This is classified as a NULL Pointer Dereference [CWE-476].
Root Cause
The root cause is a missing return value check after calling an allocation-style helper. __lock_set_class() trusted register_lock_class() to succeed, while the parallel code path in __lock_acquire() already treated NULL as a failure case. This inconsistency allowed resource exhaustion or internal validator failures to translate into a kernel-level invalid pointer dereference.
Attack Vector
Triggering the bug requires conditions that cause register_lock_class() to return NULL on a path that calls __lock_set_class(). The most reachable condition is exhaustion of the MAX_LOCKDEP_KEYS pool, which occurs on long-running kernels with many dynamically allocated locks or on debug builds that register large numbers of distinct lock classes. A local user able to allocate kernel objects that register new lock classes may be able to push the system toward exhaustion. The impact is a kernel crash rather than code execution. Exploitation requires CONFIG_LOCKDEP to be enabled, which limits exposure primarily to development, debug, and some distribution kernels.
See the upstream fix in Kernel Git Commit f6093ff and backports Kernel Git Commit 59a5c7d, Kernel Git Commit 5c3bff6, and Kernel Git Commit 7577e00 for implementation details.
Detection Methods for CVE-2026-93261
Indicators of Compromise
- Kernel oops or panic messages referencing __lock_set_class, reacquire_held_locks, or hlock_class in dmesg or serial console logs
- Prior lockdep warnings such as BUG: MAX_LOCKDEP_KEYS too low! indicating lock class pool pressure before the crash
- Unexpected system reboots on hosts running lockdep-enabled kernels with long uptimes
Detection Strategies
- Compare the running kernel version against the stable trees that received the backport commits listed in the references
- Audit kernel build configurations for CONFIG_LOCKDEP=y or CONFIG_PROVE_LOCKING=y to identify systems within scope
- Monitor /proc/lockdep_stats for lock-classes approaching MAX_LOCKDEP_KEYS, which signals the precondition for the NULL return
Monitoring Recommendations
- Forward kernel ring buffer logs (journald, rsyslog, or kmsg) to a centralized log store for pattern matching on lockdep diagnostics
- Alert on repeated MAX_LOCKDEP_KEYS warnings on any host, since they precede the NULL dereference condition
- Track kernel package versions across the fleet to confirm patched builds are deployed on hosts running debug or lockdep-enabled kernels
How to Mitigate CVE-2026-93261
Immediate Actions Required
- Upgrade to a kernel that includes the lockdep NULL check backport from one of the referenced stable commits
- Prioritize patching on hosts built with CONFIG_LOCKDEP or CONFIG_PROVE_LOCKING, including debug and development systems
- Reboot affected systems after upgrade so the fixed kernel image is loaded
Patch Information
The upstream fix adds a NULL return value check in __lock_set_class() consistent with the handling in __lock_acquire(). Stable branch backports are published in Kernel Git Commit f6093ff, Kernel Git Commit 59a5c7d, Kernel Git Commit 5c3bff6, Kernel Git Commit 7577e00, Kernel Git Commit 9be10f4, Kernel Git Commit b2113dc, Kernel Git Commit e7c69c6, and Kernel Git Commit f56e54f. Apply distribution-provided kernel updates where available.
Workarounds
- On production systems that do not require lock validation, rebuild the kernel without CONFIG_LOCKDEP and CONFIG_PROVE_LOCKING to eliminate the vulnerable code path
- Restrict local access to multi-tenant hosts running lockdep-enabled kernels until the patch is applied
- Reboot long-running debug kernels periodically to reset lock class pool usage and reduce the chance of MAX_LOCKDEP_KEYS exhaustion
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

