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-2024-42094 Overview
CVE-2024-42094 is a vulnerability in the Linux kernel's IBM Communications Vehicle (IUCV) networking subsystem. The flaw stems from explicit allocation of a cpumask variable on the kernel stack within the net/iucv code. On kernels built with CONFIG_CPUMASK_OFFSTACK=y, this allocation pattern can trigger stack overflow conditions. The vulnerability affects local attackers with low privileges and can impact confidentiality and system availability. The upstream fix replaces direct stack allocation with the config-neutral *cpumask_var API family, delegating allocation strategy to the kernel build configuration. The issue is tracked under [CWE-787] (Out-of-bounds Write).
Critical Impact
A local, low-privileged user on a system with CONFIG_CPUMASK_OFFSTACK=y can trigger kernel stack overflow in the net/iucv path, resulting in confidentiality exposure and denial of service.
Affected Products
- Linux Kernel (multiple stable branches prior to the fix commits)
- Debian LTS distributions (per Debian LTS advisory)
- Siemens industrial products referenced in SSA-265688, SSA-355557, and SSA-613116
Discovery Timeline
- 2024-07-29 - CVE-2024-42094 published to NVD
- 2026-10-15 - Last updated in NVD database
Technical Details for CVE-2024-42094
Vulnerability Analysis
The vulnerability resides in the Linux kernel net/iucv subsystem, which implements the Inter-User Communication Vehicle protocol used on IBM Z (s390x) architectures. The affected code declares a cpumask variable directly on the kernel stack. On kernels built with CONFIG_CPUMASK_OFFSTACK=y, which is common on systems configured for large CPU counts (NR_CPUS in the thousands), the cpumask type expands significantly in size. Placing such a structure on the limited kernel stack can exhaust available stack space, leading to out-of-bounds writes beyond the stack frame.
Stack corruption in kernel context typically results in a kernel panic or exploitable memory corruption. Because the IUCV code paths are reachable from local user context, a low-privileged user can trigger the overflow by exercising affected socket or communication operations.
Root Cause
The root cause is improper use of kernel memory allocation primitives. Kernel developers are expected to use the *cpumask_var API family (alloc_cpumask_var, zalloc_cpumask_var, free_cpumask_var) to allocate cpumask instances in a configuration-neutral manner. When CONFIG_CPUMASK_OFFSTACK is enabled, these APIs allocate the mask on the heap instead of the stack. The vulnerable code bypassed this abstraction, hard-coding stack allocation and introducing the overflow risk.
Attack Vector
The attack vector is local. An unprivileged local user interacts with the IUCV subsystem through standard kernel interfaces, triggering the code path that declares the oversized cpumask on the stack. Exploitation requires that the target kernel be compiled with CONFIG_CPUMASK_OFFSTACK=y and that IUCV be available, conditions most commonly met on IBM Z systems. The result is kernel stack corruption, which manifests as a crash (denial of service) or potential disclosure of kernel memory contents.
The vulnerability mechanism is described in prose only; verified exploit code is not publicly available. See the upstream kernel commits for the exact source changes.
Detection Methods for CVE-2024-42094
Indicators of Compromise
- Unexpected kernel oops or panic messages referencing iucv symbols in dmesg or /var/log/kern.log
- Kernel stack trace entries indicating stack corruption or overflow in net/iucv functions
- Repeated process crashes or system reboots originating from workloads that use IUCV sockets on s390x hosts
Detection Strategies
- Inventory running kernels with uname -r and cross-reference against the fixed versions listed in the kernel.org stable commits
- Verify kernel build configuration for CONFIG_CPUMASK_OFFSTACK and CONFIG_IUCV using /boot/config-$(uname -r) or /proc/config.gz
- Monitor s390x systems where IUCV is loaded (lsmod | grep iucv) for abnormal termination events
Monitoring Recommendations
- Forward kernel ring buffer and syslog data to a centralized logging platform and alert on BUG:, Oops:, or stack-trace patterns involving IUCV
- Track package versions of linux-image-* on Debian-based systems against the Debian LTS Announcement advisory
- For industrial deployments, correlate asset inventory with Siemens advisories SSA-265688, SSA-355557, and SSA-613116
How to Mitigate CVE-2024-42094
Immediate Actions Required
- Apply vendor kernel updates that include the upstream fix commits for net/iucv immediately on affected systems
- Prioritize patching of IBM Z (s390x) hosts and any Linux systems with CONFIG_CPUMASK_OFFSTACK=y where IUCV is reachable
- Review Siemens product advisories and apply firmware or OS updates for impacted industrial devices
Patch Information
The fix is distributed across multiple stable kernel branches. Relevant upstream commits include 0af718a, 2b08552, 2d090c7, 724e796, 842afb4, 9dadab0, be4e130, and d85ca81. Debian users should install the kernel update described in the Debian LTS Announcement.
Workarounds
- Where IUCV is not required, unload and blacklist the iucv kernel module to remove the vulnerable code path
- Restrict local user access on affected hosts and enforce least-privilege policies until patching is complete
- On custom kernels, consider rebuilding with CONFIG_CPUMASK_OFFSTACK=n only after evaluating the operational impact on large-CPU-count systems
# Check kernel configuration and IUCV module status
grep CONFIG_CPUMASK_OFFSTACK /boot/config-$(uname -r)
lsmod | grep iucv
# Temporarily unload IUCV where not required
sudo modprobe -r iucv
# Blacklist to prevent reload on reboot
echo 'blacklist iucv' | sudo tee /etc/modprobe.d/blacklist-iucv.conf
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

