CVE-2022-50293

5.5 MEDIUM

📋 TL;DR

A memory handling vulnerability in the Linux kernel's Btrfs filesystem could cause a kernel panic when the system runs out of memory during certain filesystem operations. This affects Linux systems using Btrfs filesystem. The vulnerability allows denial of service through system crashes.

💻 Affected Systems

Products:
  • Linux kernel
Versions: Kernel versions with vulnerable Btrfs implementation (specific versions not provided in CVE)
Operating Systems: Linux distributions using Btrfs filesystem
Default Config Vulnerable: ⚠️ Yes
Notes: Only affects systems using Btrfs filesystem. Systems using other filesystems are not vulnerable.

📦 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 →

⚠️ Risk & Real-World Impact

🔴

Worst Case

Complete system crash and kernel panic requiring reboot, potentially causing data corruption or loss in Btrfs volumes.

🟠

Likely Case

System crash when Btrfs operations encounter memory pressure, leading to denial of service.

🟢

If Mitigated

Transaction abort with error return instead of crash, maintaining system stability.

🌐 Internet-Facing: LOW - Requires local access or ability to trigger specific Btrfs operations.
🏢 Internal Only: MEDIUM - Local users or processes could trigger the condition through filesystem operations.

🎯 Exploit Status

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

Requires ability to trigger Btrfs operations that could exhaust memory during extent item manipulation.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Kernel versions with commits 162d053e15fe985f754ef495a96eb3db970c43ed, 1baf3370e2dc5e6bd1368348736189457dab2a27, 50f993da945074b2a069da099a0331b23a0c89a0, or 7fbcb635c8fc927d139f3302babcf1b42c09265c

Vendor Advisory: https://git.kernel.org/stable/c/162d053e15fe985f754ef495a96eb3db970c43ed

Restart Required: Yes

Instructions:

1. Update Linux kernel to patched version. 2. Reboot system to load new kernel. 3. Verify kernel version after reboot.

🔧 Temporary Workarounds

Avoid Btrfs usage

all

Use alternative filesystems like ext4 or XFS instead of Btrfs

Memory pressure management

all

Monitor and manage system memory to prevent exhaustion during Btrfs operations

🧯 If You Can't Patch

  • Monitor system memory usage and implement memory limits
  • Restrict Btrfs operations to trusted users only

🔍 How to Verify

Check if Vulnerable:

Check kernel version and verify if Btrfs is in use: 'uname -r' and 'mount | grep btrfs'

Check Version:

uname -r

Verify Fix Applied:

Verify kernel version includes the fix commits and test Btrfs operations under memory pressure

📡 Detection & Monitoring

Log Indicators:

  • Kernel panic messages in /var/log/kern.log or dmesg
  • Btrfs error messages related to memory allocation

Network Indicators:

  • None - local vulnerability only

SIEM Query:

source="kernel" AND ("BUG_ON" OR "kernel panic" OR "btrfs" AND "ENOMEM")

🔗 References

📤 Share & Export