CVE-2023-20032

9.8 CRITICAL

📋 TL;DR

A heap buffer overflow vulnerability in ClamAV's HFS+ partition file parser allows remote unauthenticated attackers to execute arbitrary code or cause denial of service. This affects ClamAV versions 1.0.0 and earlier, 0.105.1 and earlier, and 0.103.7 and earlier. Any system using vulnerable ClamAV versions for file scanning is at risk.

💻 Affected Systems

Products:
  • ClamAV
Versions: 1.0.0 and earlier, 0.105.1 and earlier, 0.103.7 and earlier
Operating Systems: All platforms running ClamAV
Default Config Vulnerable: ⚠️ Yes
Notes: Any system using ClamAV for scanning HFS+ files is vulnerable regardless of configuration

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Remote code execution with ClamAV process privileges leading to full system compromise

🟠

Likely Case

Denial of service through process crashes disrupting scanning services

🟢

If Mitigated

Limited impact if proper network segmentation and least privilege are implemented

🌐 Internet-Facing: HIGH - Remote unauthenticated exploitation possible via submitted files
🏢 Internal Only: MEDIUM - Requires attacker to submit malicious files to scanning systems

🎯 Exploit Status

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

Vulnerability is remotely exploitable without authentication via crafted HFS+ files

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: 1.0.1, 0.105.2, 0.103.8

Vendor Advisory: https://blog.clamav.net/

Restart Required: Yes

Instructions:

1. Update ClamAV to patched version 2. Restart ClamAV service 3. Verify update with clamscan --version

🔧 Temporary Workarounds

Disable HFS+ file scanning

all

Configure ClamAV to skip HFS+ partition files

Add 'ScanHFSPlus no' to clamd.conf

Network segmentation

all

Isolate ClamAV scanning systems from critical networks

🧯 If You Can't Patch

  • Implement strict file upload controls to prevent HFS+ files from reaching scanners
  • Run ClamAV with minimal privileges and in isolated containers

🔍 How to Verify

Check if Vulnerable:

Run 'clamscan --version' and check if version is in affected range

Check Version:

clamscan --version

Verify Fix Applied:

Confirm version is 1.0.1, 0.105.2, or 0.103.8 or later

📡 Detection & Monitoring

Log Indicators:

  • ClamAV process crashes
  • Unusual memory usage patterns in ClamAV

Network Indicators:

  • Unexpected HFS+ file submissions to scanning endpoints

SIEM Query:

source="clamav" AND (event="crash" OR event="segfault")

🔗 References

📤 Share & Export