CVE-2021-3656

8.8 HIGH

📋 TL;DR

This vulnerability in KVM's AMD SVM nested virtualization allows a malicious L1 guest to disable security intercepts for L2 guests, potentially enabling L2 guests to read/write host physical memory. This could lead to system crashes, data leaks, or guest-to-host escape. Affects systems using KVM with AMD processors and nested virtualization enabled.

💻 Affected Systems

Products:
  • Linux Kernel KVM module
Versions: Linux kernel versions before commit c7dfa4009965a9b2d7b329ee970eb8da0d32f0bc (August 2021)
Operating Systems: Linux distributions using affected kernel versions
Default Config Vulnerable: ✅ No
Notes: Only vulnerable when using KVM with AMD processors and nested virtualization (SVM) enabled. Not applicable to Intel processors or non-nested configurations.

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

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 guest-to-host escape allowing L2 guest to execute arbitrary code on host, access all host memory, and potentially compromise the entire physical system.

🟠

Likely Case

System crash/DoS or sensitive data leakage from host memory to malicious guest.

🟢

If Mitigated

No impact if nested virtualization is disabled or systems are patched.

🌐 Internet-Facing: LOW (requires local guest access, not directly network exploitable)
🏢 Internal Only: MEDIUM (requires compromised guest VM with nested virtualization enabled)

🎯 Exploit Status

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

Exploitation requires: 1) AMD processor with SVM, 2) nested virtualization enabled, 3) malicious L1 guest access, 4) knowledge of KVM internals. No public exploits known.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: Linux kernel with commit c7dfa4009965a9b2d7b329ee970eb8da0d32f0bc

Vendor Advisory: https://bugzilla.redhat.com/show_bug.cgi?id=1983988

Restart Required: Yes

Instructions:

1. Update Linux kernel to version containing the fix. 2. For RHEL/CentOS: yum update kernel. 3. For Ubuntu/Debian: apt update && apt upgrade linux-image. 4. Reboot system to load new kernel.

🔧 Temporary Workarounds

Disable nested virtualization

linux

Prevents exploitation by disabling the vulnerable feature entirely

echo 'options kvm-amd nested=0' > /etc/modprobe.d/kvm-amd.conf
rmmod kvm-amd
modprobe kvm-amd

🧯 If You Can't Patch

  • Disable nested virtualization on all AMD hosts
  • Isolate/restrict access to VMs that require nested virtualization capabilities

🔍 How to Verify

Check if Vulnerable:

Check kernel version and if nested virtualization is enabled: cat /sys/module/kvm_amd/parameters/nested

Check Version:

uname -r

Verify Fix Applied:

Verify kernel version contains the fix commit: uname -r and check kernel changelog for commit c7dfa4009965a9b2d7b329ee970eb8da0d32f0bc

📡 Detection & Monitoring

Log Indicators:

  • Kernel crashes or panics
  • Unexpected VM exits in KVM logs
  • Suspicious nested VM creation patterns

Network Indicators:

  • None - this is a local hypervisor vulnerability

SIEM Query:

source="kvm" AND ("nested" OR "vmcb" OR "virt_ext")

🔗 References

📤 Share & Export