CVE-2021-29154

7.8 HIGH

📋 TL;DR

This vulnerability in Linux kernel BPF JIT compilers allows attackers to execute arbitrary code within kernel context due to incorrect branch displacement calculations. It affects Linux systems with kernel versions through 5.11.12 that have BPF JIT enabled. Attackers can gain kernel-level privileges and potentially compromise the entire system.

💻 Affected Systems

Products:
  • Linux Kernel
Versions: Through 5.11.12
Operating Systems: Linux distributions using affected kernel versions
Default Config Vulnerable: ⚠️ Yes
Notes: Requires BPF JIT to be enabled (default on many distributions). Systems with CONFIG_BPF_JIT_ALWAYS_ON=y are 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 →

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

Full system compromise with kernel-level code execution, allowing attackers to install persistent malware, steal sensitive data, or disrupt critical services.

🟠

Likely Case

Local privilege escalation from unprivileged user to root, enabling attackers to bypass security controls and access restricted resources.

🟢

If Mitigated

Limited impact if BPF JIT is disabled or systems are properly segmented with minimal user access.

🌐 Internet-Facing: MEDIUM
🏢 Internal Only: HIGH

🎯 Exploit Status

Public PoC: ⚠️ Yes
Weaponized: LIKELY
Unauthenticated Exploit: ✅ No
Complexity: MEDIUM

Exploitation requires local access. Proof-of-concept code has been published in security advisories.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Linux kernel 5.11.13 and later

Vendor Advisory: https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=26f55a59dc65ff77cd1c4b37991e26497fc68049

Restart Required: Yes

Instructions:

1. Update kernel to version 5.11.13 or later. 2. For distributions: Use package manager (apt/yum/dnf) to update kernel package. 3. Reboot system to load new kernel.

🔧 Temporary Workarounds

Disable BPF JIT

linux

Disables the BPF JIT compiler to prevent exploitation

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

Restrict BPF system calls

linux

Use seccomp or other mechanisms to restrict bpf() system calls

🧯 If You Can't Patch

  • Implement strict access controls and limit local user accounts
  • Deploy kernel security modules (SELinux/AppArmor) with strict policies

🔍 How to Verify

Check if Vulnerable:

Check kernel version: uname -r. If version <= 5.11.12 and BPF JIT is enabled, system is vulnerable.

Check Version:

uname -r

Verify Fix Applied:

Verify kernel version is >= 5.11.13 and check /proc/sys/net/core/bpf_jit_enable returns 1 (if JIT needed).

📡 Detection & Monitoring

Log Indicators:

  • Kernel panic logs
  • Unexpected BPF program loads
  • Suspicious privilege escalation attempts

Network Indicators:

  • Unusual outbound connections from kernel processes

SIEM Query:

source="kernel" AND ("BPF" OR "JIT" OR "kernel panic")

🔗 References

📤 Share & Export