CVE-2025-21631

7.8 HIGH

📋 TL;DR

This is a use-after-free (UAF) vulnerability in the Linux kernel's BFQ I/O scheduler. It allows attackers with local access to potentially escalate privileges or crash the system by triggering a race condition during queue splitting operations. All Linux systems using the BFQ scheduler are affected.

💻 Affected Systems

Products:
  • Linux kernel with BFQ I/O scheduler enabled
Versions: Linux kernel versions up to and including v6.6 (specific affected versions may vary based on backports)
Operating Systems: Linux distributions using affected kernel versions
Default Config Vulnerable: ✅ No
Notes: Only vulnerable if BFQ scheduler is enabled (CONFIG_IOSCHED_BFQ=y). Many distributions use other schedulers 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 →

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

Local privilege escalation to root, kernel panic leading to denial of service, or arbitrary code execution in kernel context.

🟠

Likely Case

Kernel crash/panic causing system instability or denial of service, potentially leading to data corruption.

🟢

If Mitigated

No impact if proper kernel hardening and access controls prevent local attackers from triggering the race condition.

🌐 Internet-Facing: LOW - Requires local access to exploit, not directly exploitable over network.
🏢 Internal Only: HIGH - Local attackers or malicious users can exploit this to gain elevated privileges or crash systems.

🎯 Exploit Status

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

Requires local access and ability to trigger specific I/O operations to create race condition. Exploitation requires understanding of kernel internals.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Patched in kernel commits: 2550149fcdf2934155ff625d76ad4e3d4b25bbc6, bc2aeb35ff167e0c6b0cedf0c96a5c41e6cba1ed, be3eed59ac01f429ac10aaa46e26f653bcf581ab, f587c1ac68956c4703857d650d9b1cd7bb2ac4d7, fcede1f0a043ccefe9bc6ad57f12718e42f63f1d

Vendor Advisory: https://git.kernel.org/stable/c/2550149fcdf2934155ff625d76ad4e3d4b25bbc6

Restart Required: Yes

Instructions:

1. Update Linux kernel to version containing the fix. 2. Check if your distribution has backported the fix. 3. Reboot system to load new kernel.

🔧 Temporary Workarounds

Disable BFQ scheduler

linux

Switch to a different I/O scheduler like CFQ or deadline

echo 'cfq' > /sys/block/[device]/queue/scheduler

🧯 If You Can't Patch

  • Restrict local user access to prevent exploitation
  • Implement strict access controls and monitor for suspicious local activity

🔍 How to Verify

Check if Vulnerable:

Check kernel version and if BFQ scheduler is enabled: uname -r && grep CONFIG_IOSCHED_BFQ /boot/config-$(uname -r)

Check Version:

uname -r

Verify Fix Applied:

Verify kernel version is patched and check for presence of fix commits in kernel source

📡 Detection & Monitoring

Log Indicators:

  • Kernel panic logs
  • KASAN reports of use-after-free in bfq_init_rq
  • System crashes during I/O operations

Network Indicators:

  • None - local exploitation only

SIEM Query:

Search for kernel panic events or KASAN reports mentioning bfq_init_rq or bfq_split_bfqq

🔗 References

📤 Share & Export