CVE-2025-38558

5.5 MEDIUM

📋 TL;DR

A NULL pointer dereference vulnerability in the Linux kernel's USB gadget UVC driver causes kernel crashes when userspace configures frame-based video formats without explicitly defining color matching descriptors. This affects systems using USB gadget functionality with UVC video streaming, particularly embedded devices and Android systems. The vulnerability leads to denial of service through kernel panics.

💻 Affected Systems

Products:
  • Linux kernel
Versions: Kernel versions between commit f5e7bdd34aca and fixes in stable branches (6.6.58-android15 shown in crash log)
Operating Systems: Linux distributions, Android
Default Config Vulnerable: ✅ No
Notes: Only vulnerable when USB gadget UVC functionality is enabled and configured via configfs with frame-based formats. Most desktop/server distributions don't enable USB gadget 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 →

⚠️ Risk & Real-World Impact

🔴

Worst Case

Kernel panic leading to system crash and denial of service, requiring physical or remote reboot to restore functionality.

🟠

Likely Case

System instability or crash when configuring USB gadget UVC video streaming with frame-based formats, disrupting USB video functionality.

🟢

If Mitigated

No impact if USB gadget UVC functionality is not used or if proper kernel patches are applied.

🌐 Internet-Facing: LOW - Requires local USB gadget configuration access; not directly exploitable over network.
🏢 Internal Only: MEDIUM - Local users with USB gadget configuration privileges can cause denial of service.

🎯 Exploit Status

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

Requires local access to configure USB gadget via configfs. Crash is triggered during legitimate configuration operations rather than malicious payload.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Fixed in stable kernel commits: 323a80a1a5ace319a722909c006d5bdb2a35d273, 6db61c1aa23075eeee90e083ca3f6567a5635da6, 7f8576fc9d1a203d12474bf52710c7af68cae490

Vendor Advisory: https://git.kernel.org/stable/c/323a80a1a5ace319a722909c006d5bdb2a35d273

Restart Required: No

Instructions:

1. Update to patched kernel version from your distribution vendor. 2. For custom kernels, apply the fix commits to your kernel source. 3. Recompile and deploy the updated kernel.

🔧 Temporary Workarounds

Disable USB gadget UVC functionality

all

Prevent the vulnerable code path by disabling USB gadget UVC support in kernel configuration

echo "blacklist uvc" >> /etc/modprobe.d/blacklist.conf
rmmod uvc

Avoid frame-based format configuration

all

Configure USB gadget UVC with only uncompressed or MJPEG formats which have proper color matching initialization

🧯 If You Can't Patch

  • Restrict configfs access to trusted users only
  • Monitor kernel logs for UVC configuration attempts and crashes

🔍 How to Verify

Check if Vulnerable:

Check if kernel is vulnerable by examining kernel version and checking if USB gadget UVC module is loaded: lsmod | grep uvc

Check Version:

uname -r

Verify Fix Applied:

Verify kernel version includes the fix commits or test UVC gadget configuration with frame-based formats without crash

📡 Detection & Monitoring

Log Indicators:

  • Kernel panic messages mentioning NULL pointer dereference at uvcg_framebased_make or __uvcg_fill_strm
  • USB gadget configuration errors in system logs

Network Indicators:

  • None - local vulnerability only

SIEM Query:

source="kernel" AND ("NULL pointer dereference" AND "uvc" OR "uvcg_framebased_make")

🔗 References

📤 Share & Export