CVE-2025-55642
Executive Summary
CVE-2025-55642 is a denial-of-service vulnerability in GPAC MP4Box version 2.4, specifically within the avidmx_process function in isomedia/isom_write.c. The vulnerability is a floating point exception (FPE) that can be triggered by processing a specially crafted MP4 file. This can lead to a crash of the MP4Box application, potentially disrupting automated media processing pipelines. No public exploit code or proof-of-concept is currently available, and the patch status is unknown.
This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.
No signup required
Supply Chain & Package Security
GPAC is an open-source multimedia framework used in various media processing tools and pipelines. While not a direct package manager dependency (like NPM or PyPI), it is often compiled from source or distributed via system package managers. A crash in MP4Box can disrupt CI/CD pipelines, media transcoding services, and any automated system relying on this tool for file validation or conversion. Organizations using GPAC in their supply chain should monitor for updates and consider sandboxing MP4Box execution.
CVSS Breakdown & Threat Level
- CVSS Score: 0.0 (No official vector assigned)
- Attack Vector (AV): Local (requires a crafted file to be processed)
- Attack Complexity (AC): Low (the crafted file can be easily created)
- Privileges Required (PR): None (the user processing the file is typically unprivileged)
- User Interaction (UI): Required (user must open/process the file)
- Scope (S): Unchanged
- Confidentiality (C): None
- Integrity (I): None
- Availability (A): High (application crash)
Threat Level: Medium. The vulnerability is a denial-of-service with no remote code execution or data breach potential. However, it can be used to disrupt media processing services.
Deep Dive & Mechanics
The vulnerability resides in the avidmx_process function within isomedia/isom_write.c. This function is responsible for processing AVID MXF (Material eXchange Format) files. A floating point exception occurs when the code performs a division operation with a divisor that is zero or results in an invalid floating-point operation (e.g., division by zero, square root of a negative number). In this context, a crafted MXF file can cause the function to compute a value that leads to a division by zero, triggering the FPE and crashing the application.
The specific code path is likely in a calculation involving sample durations, time scales, or other numeric metadata extracted from the file. Without a patch or detailed analysis, the exact line is unknown, but the root cause is improper validation of numeric values before arithmetic operations.
Vulnerable vs. Patched Code
Since no patch is available, a comparison cannot be made. However, a hypothetical fix would involve:
Vulnerable Code (Conceptual):
int duration = sample_count / time_scale;If
time_scaleis zero, this causes a division by zero.Patched Code (Conceptual):
if (time_scale == 0) { // Handle error, skip sample, or set default return -1; } int duration = sample_count / time_scale;
Exploitation & Lab Setup
Red Team
- Craft a Malicious MXF File: Create an MXF file with a zero value in a field used as a divisor (e.g.,
time_scalein theavidmx_processfunction). This can be done using a hex editor or by modifying an existing MXF file. - Deliver the File: Send the file via email, upload to a web service, or place it in a directory processed by MP4Box.
- Trigger the Vulnerability: Run
MP4Box -info malicious.mxfor any command that triggers theavidmx_processfunction. - Observe Crash: The application will crash with a floating point exception.
Example Command:
MP4Box -info malicious.mxf
Blue Team
- Monitor for Crashes: Use system logs (e.g.,
journalctl, Windows Event Viewer) to detect MP4Box crashes with signalSIGFPE(floating point exception). - File Integrity Monitoring: Monitor for the creation or modification of MXF files in directories processed by MP4Box.
- Sandboxing: Run MP4Box in a sandboxed environment (e.g., Docker container with limited resources) to contain crashes.
- Input Validation: Implement a pre-processing script that validates MXF files before passing them to MP4Box. Check for zero values in critical numeric fields.
Example Pre-processing Script (Python):
import struct
def validate_mxf(filepath):
with open(filepath, 'rb') as f:
# Simplified check - real MXF parsing is complex
# Look for time_scale field (example offset)
f.seek(0x100) # Hypothetical offset
data = f.read(4)
time_scale = struct.unpack('>I', data)[0]
if time_scale == 0:
raise ValueError("Invalid MXF: time_scale is zero")
Indicators of Compromise (IOCs)
- File Hashes: (None available, but any MXF file that triggers the crash)
- Process Name:
MP4Box - Signal:
SIGFPE(floating point exception) - Log Entry:
Floating point exception (core dumped)in system logs - Network: No network indicators (local file processing)
Detection Engineering
YARA Rule
rule CVE_2025_55642_GPAC_FPE {
meta:
description = "Detects MXF files likely to trigger CVE-2025-55642 in GPAC MP4Box"
author = "Valters IT"
date = "2025-04-10"
reference = "CVE-2025-55642"
strings:
$mxf_header = { 06 0E 2B 34 02 05 01 01 0D 01 02 01 01 02 01 00 } // MXF header
$zero_time_scale = { 00 00 00 00 } // Potential zero time_scale field
condition:
$mxf_header at 0 and $zero_time_scale
}
Sigma Rule
title: GPAC MP4Box Floating Point Exception
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects MP4Box crashes due to floating point exception (CVE-2025-55642)
author: Valters IT
date: 2025-04-10
logsource:
category: process_creation
product: linux
detection:
selection:
Image|endswith: '/MP4Box'
CommandLine|contains: 'mxf'
condition: selection
falsepositives:
- Legitimate MXF files with unusual metadata
level: medium
Suricata Rule
alert tcp any any -> any any (msg:"CVE-2025-55642 GPAC MP4Box MXF FPE Attempt"; flow:to_server,established; file_store; fileext:"mxf"; content:"|06 0E 2B 34 02 05 01 01 0D 01 02 01 01 02 01 00|"; distance:0; within:16; sid:1000001; rev:1;)
Remediation & Mitigation
- Patch: Monitor GPAC repository for a patch. Apply it as soon as available.
- Workaround: Avoid processing untrusted MXF files with MP4Box. Use alternative tools for MXF validation.
- Input Validation: Implement a wrapper script that checks for zero values in critical MXF fields before passing to MP4Box.
- Sandboxing: Run MP4Box in a container with limited resources and restart policies.
- Monitoring: Deploy the YARA and Sigma rules to detect malicious MXF files and crashes.
Valters IT