CVE-2024-24686

7.8 HIGH

📋 TL;DR

This CVE describes stack-based buffer overflow vulnerabilities in libigl's readOFF function when parsing malicious .off files. Attackers can exploit these vulnerabilities by providing specially crafted files, potentially leading to arbitrary code execution. Users and applications that process .off files with libigl v2.5.0 are affected.

💻 Affected Systems

Products:
  • libigl
Versions: v2.5.0
Operating Systems: All platforms where libigl is used
Default Config Vulnerable: ⚠️ Yes
Notes: Any application using libigl's readOFF function to parse .off files is vulnerable. The vulnerability is in the comment parsing within the faces section.

📦 What is this software?

⚠️ Risk & Real-World Impact

🔴

Worst Case

Remote code execution with the privileges of the application processing the .off file, potentially leading to full system compromise.

🟠

Likely Case

Application crash (denial of service) or limited code execution depending on exploit sophistication and system protections.

🟢

If Mitigated

Application crash with no code execution if modern exploit mitigations (ASLR, stack canaries) are effective.

🌐 Internet-Facing: MEDIUM - Requires user or system to process attacker-controlled .off files, which could occur through web uploads or automated processing.
🏢 Internal Only: LOW - Typically requires local file access or internal user interaction with malicious files.

🎯 Exploit Status

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

Exploitation requires crafting a malicious .off file and getting it processed by vulnerable software. No public exploit code is currently known.

🛠️ Fix & Mitigation

✅ Official Fix

Patch Version: v2.5.1 or later

Vendor Advisory: https://github.com/libigl/libigl/releases

Restart Required: No

Instructions:

1. Update libigl to version 2.5.1 or later. 2. Recompile any applications using libigl with the updated library. 3. Replace any statically linked versions of libigl in your applications.

🔧 Temporary Workarounds

Input validation for .off files

all

Implement strict validation of .off file contents before processing with libigl, particularly checking comment sections for excessive length.

Disable .off file processing

all

Temporarily disable functionality that processes .off files if not essential for operations.

🧯 If You Can't Patch

  • Implement strict file upload controls and scanning for .off files from untrusted sources.
  • Run applications with minimal privileges and enable exploit mitigations (ASLR, DEP, stack canaries).

🔍 How to Verify

Check if Vulnerable:

Check if your application uses libigl v2.5.0 and processes .off files via the readOFF function. Review source code or dependencies for libigl version.

Check Version:

Check build configuration files (CMakeLists.txt, package.json, etc.) or library headers for version information.

Verify Fix Applied:

Verify libigl version is 2.5.1 or later and that applications have been recompiled with the updated library.

📡 Detection & Monitoring

Log Indicators:

  • Application crashes when processing .off files
  • Unexpected process termination with segmentation faults

Network Indicators:

  • Unusual .off file uploads to web applications
  • Network transfers of .off files to vulnerable systems

SIEM Query:

Process: (name contains application using libigl) AND Event: (crash OR segmentation fault) AND File: (*.off)

🔗 References

📤 Share & Export