CVE-2024-42076

5.5 MEDIUM

📋 TL;DR

This CVE describes a kernel information leak vulnerability in the Linux kernel's J1939 CAN bus subsystem. The j1939_send_one() function fails to initialize unused data in network frames, allowing uninitialized kernel memory to be leaked to user space via raw_recvmsg(). This affects systems using the J1939 protocol stack in the Linux kernel.

💻 Affected Systems

Products:
  • Linux kernel
Versions: Versions before the fix commits (specific versions vary by distribution)
Operating Systems: Linux distributions with vulnerable kernel versions
Default Config Vulnerable: ✅ No
Notes: Only vulnerable if the J1939 CAN protocol stack is enabled and used. Many systems don't use J1939 by default.

📦 What is this software?

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

Linux Kernel by Linux

The Linux Kernel is the core component of the Linux operating system, serving as the critical interface between computer hardware and software processes. As the heart of millions of servers, cloud infrastructure, embedded systems, Android devices, and IoT deployments worldwide, the Linux Kernel mana...

Learn more about Linux Kernel →

⚠️ Risk & Real-World Impact

🔴

Worst Case

Sensitive kernel memory contents (potentially including passwords, keys, or other sensitive data) could be leaked to unprivileged users, potentially enabling further attacks.

🟠

Likely Case

Limited information disclosure of uninitialized kernel memory, which could reveal system state information or aid in bypassing kernel security mechanisms.

🟢

If Mitigated

No information leak occurs; uninitialized memory is properly zeroed before being sent to user space.

🌐 Internet-Facing: LOW - J1939 is primarily used in industrial/automotive networks and typically not exposed to the internet.
🏢 Internal Only: MEDIUM - Systems using J1939 CAN bus communication could leak kernel memory to local users or network peers.

🎯 Exploit Status

Public PoC: ✅ No
Weaponized: UNKNOWN
Unauthenticated Exploit: ✅ No
Complexity: MEDIUM

Exploitation requires access to the J1939 socket interface, typically requiring local access or network access to CAN bus systems.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Fixed in kernel commits: 4c5dc3927e17489c1cae6f48c0d5e4acb4cae01f, 5e4ed38eb17eaca42de57d500cc0f9668d2b6abf, a2a0ebff7fdeb2f66e29335adf64b9e457300dd4, ab2a683938ba4416d389c2f5651cbbb2c41b779f, b7cdf1dd5d2a2d8200efd98d1893684db48fe134

Vendor Advisory: https://git.kernel.org/stable/c/4c5dc3927e17489c1cae6f48c0d5e4acb4cae01f

Restart Required: Yes

Instructions:

1. Update to a patched kernel version from your distribution. 2. Reboot the system to load the new kernel. 3. Verify the fix is applied by checking kernel version.

🔧 Temporary Workarounds

Disable J1939 module

linux

If J1939 functionality is not required, disable the kernel module to prevent exploitation.

modprobe -r can_j1939
echo 'blacklist can_j1939' >> /etc/modprobe.d/blacklist.conf

🧯 If You Can't Patch

  • Restrict access to CAN bus interfaces using appropriate permissions and network segmentation
  • Implement strict access controls on systems using J1939 protocol

🔍 How to Verify

Check if Vulnerable:

Check if J1939 module is loaded: lsmod | grep j1939. If loaded and kernel version is vulnerable, system is at risk.

Check Version:

uname -r

Verify Fix Applied:

Check kernel version includes the fix commits or is newer than vulnerable versions. Verify J1939 module can be loaded without information leak.

📡 Detection & Monitoring

Log Indicators:

  • Kernel logs showing KMSAN warnings about information leaks
  • Unexpected CAN bus traffic patterns

Network Indicators:

  • Unusual J1939 protocol traffic from unexpected sources

SIEM Query:

Search for kernel logs containing 'KMSAN: kernel-infoleak' or 'j1939' with error messages

🔗 References

📤 Share & Export