CVE-2021-39252

7.8 HIGH

📋 TL;DR

CVE-2021-39252 is an out-of-bounds read vulnerability in NTFS-3G's ntfs_ie_lookup function. Attackers can exploit this by mounting a specially crafted NTFS image, potentially causing crashes or information disclosure. Systems using NTFS-3G versions before 2021.8.22 are affected.

💻 Affected Systems

Products:
  • NTFS-3G
  • Tuxera NTFS-3G
  • Linux distributions with NTFS-3G packages
Versions: All versions before 2021.8.22
Operating Systems: Linux, macOS, FreeBSD, Other Unix-like systems using NTFS-3G
Default Config Vulnerable: ⚠️ Yes
Notes: Vulnerable when mounting NTFS filesystems. Systems that don't use NTFS-3G or don't mount NTFS partitions are not affected.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Denial of service (system crash) or information disclosure from kernel memory when processing malicious NTFS images

🟠

Likely Case

Application crash or denial of service when mounting malicious NTFS filesystems

🟢

If Mitigated

Minimal impact if systems don't mount untrusted NTFS images and have proper access controls

🌐 Internet-Facing: LOW - Requires mounting NTFS images, which is typically not an internet-facing service
🏢 Internal Only: MEDIUM - Internal users could exploit by mounting malicious NTFS images on shared systems

🎯 Exploit Status

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

Exploitation requires ability to mount NTFS images. Proof of concept available in advisory. Requires local access or ability to mount filesystems.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 2021.8.22 and later

Vendor Advisory: https://github.com/tuxera/ntfs-3g/security/advisories/GHSA-q759-8j5v-q5jp

Restart Required: No

Instructions:

1. Update NTFS-3G to version 2021.8.22 or later. 2. For Linux distributions, use package manager: 'sudo apt update && sudo apt upgrade ntfs-3g' (Debian/Ubuntu) or 'sudo yum update ntfs-3g' (RHEL/CentOS/Fedora). 3. For source installations, download from https://github.com/tuxera/ntfs-3g/releases and compile.

🔧 Temporary Workarounds

Restrict NTFS mounting

linux

Prevent mounting of NTFS filesystems from untrusted sources

# Add to /etc/fstab: noauto option for NTFS partitions
# Use mount permissions: mount -o nosuid,noexec,nodev ntfs_partition

Disable NTFS-3G if unused

linux

Remove or disable NTFS-3G if NTFS support is not needed

sudo apt remove ntfs-3g
sudo yum remove ntfs-3g

🧯 If You Can't Patch

  • Avoid mounting NTFS images from untrusted sources
  • Implement strict access controls on filesystem mounting capabilities

🔍 How to Verify

Check if Vulnerable:

Check NTFS-3G version: 'ntfs-3g --version' or 'dpkg -l | grep ntfs-3g' or 'rpm -q ntfs-3g'

Check Version:

ntfs-3g --version

Verify Fix Applied:

Verify version is 2021.8.22 or higher: 'ntfs-3g --version | grep -q "2021.8.2[2-9]\|2021.8.[3-9]\|2021.[9-9]\|202[2-9]"'

📡 Detection & Monitoring

Log Indicators:

  • Kernel logs showing filesystem errors or crashes when mounting NTFS
  • System logs with NTFS-3G segmentation faults

Network Indicators:

  • Not applicable - local filesystem vulnerability

SIEM Query:

source="*syslog*" AND ("ntfs-3g" OR "NTFS") AND ("segmentation fault" OR "crash" OR "out of bounds")

🔗 References

📤 Share & Export