CVE-2022-49552

5.5 MEDIUM

📋 TL;DR

A Linux kernel vulnerability in the BPF subsystem where JIT blinding incorrectly randomizes special ld_imm64 instructions pointing to BPF subprograms, causing kernel crashes. This affects systems running Linux kernels with BPF JIT enabled and using BPF subprograms. Attackers could potentially cause denial of service.

💻 Affected Systems

Products:
  • Linux kernel
Versions: Specific vulnerable versions not explicitly stated in CVE, but patches available for stable branches
Operating Systems: Linux distributions using affected kernel versions
Default Config Vulnerable: ✅ No
Notes: Only vulnerable when BPF JIT is enabled and BPF programs with subprograms are used. Many distributions disable BPF JIT 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, potentially allowing limited information disclosure through crash dumps.

🟠

Likely Case

System crash when specific BPF programs with subprograms are loaded, causing denial of service on affected systems.

🟢

If Mitigated

No impact if BPF JIT is disabled or systems don't use BPF subprograms.

🌐 Internet-Facing: LOW - Requires local access or ability to load BPF programs, typically not exposed to internet.
🏢 Internal Only: MEDIUM - Local users or processes with CAP_BPF capability could trigger crashes on vulnerable systems.

🎯 Exploit Status

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

Requires ability to load BPF programs (typically CAP_BPF capability) and knowledge of triggering conditions.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Patches available in stable kernel branches via provided git commits

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

Restart Required: Yes

Instructions:

1. Update Linux kernel to patched version from distribution vendor. 2. Reboot system to load new kernel. 3. Verify BPF functionality works without crashes.

🔧 Temporary Workarounds

Disable BPF JIT

linux

Disable BPF JIT compilation to prevent the vulnerability from being triggered

echo 0 > /proc/sys/net/core/bpf_jit_enable

Restrict BPF program loading

linux

Limit which users/processes can load BPF programs using capabilities or SELinux/AppArmor

🧯 If You Can't Patch

  • Disable BPF JIT compilation system-wide
  • Implement strict capability controls to prevent unauthorized BPF program loading

🔍 How to Verify

Check if Vulnerable:

Check if BPF JIT is enabled: cat /proc/sys/net/core/bpf_jit_enable. If returns 1 and kernel is unpatched, system is vulnerable.

Check Version:

uname -r

Verify Fix Applied:

Check kernel version after update and verify BPF programs with subprograms load without crashes.

📡 Detection & Monitoring

Log Indicators:

  • Kernel panic messages mentioning 'unable to handle page fault' with RIP near 0x100000001
  • BPF program loading failures
  • System crash/reboot events

SIEM Query:

Search for kernel logs containing 'BUG: unable to handle page fault' AND 'RIP: 0010:0x100000001' OR 'bpf_loop' crash patterns

🔗 References

📤 Share & Export