CVE-2026-137906 in FFmpeg
Summary
by MITRE • 11/27/2026
FFmpeg 5.0 before 8.1.3 contains a NULL pointer dereference vulnerability in the IMF demuxer in libavformat/imfdec.c because open_virtual_track() accepts a virtual track with no resources. Attackers can supply a crafted IMF Composition Playlist whose virtual track lists no resources, causing set_context_streams_from_tracks() to dereference a NULL resource array and crash the process.
If you want to get best quality of vulnerability data, you may have to visit VulDB.
Analysis
by VulDB Data Team • 11/27/2026
The vulnerability identified in FFmpeg versions prior to 8.1.3 represents a critical input validation failure within the IMF demuxer component of libavformat. Specifically located in the source file imfdec.c, this flaw arises from an improper handling of virtual tracks during the initialization phase of media processing. The function open_virtual_track is designed to manage metadata and resource references for Interoperable Master Format compositions but fails to verify that a declared virtual track actually contains associated resources before proceeding with further operations. This lack of defensive programming allows attackers to craft malicious IMF Composition Playlist files where a virtual track entry exists in the manifest but lists zero or no underlying media resources, creating an inconsistent state within the application's internal data structures.
From a technical perspective, the core issue is a NULL pointer dereference that occurs when the processing logic attempts to access memory addresses associated with these non-existent resources. When set_context_streams_from_tracks processes the malformed input, it expects a valid array of resource pointers for each virtual track defined in the playlist. Because the crafted file provides an empty or null list of resources, the subsequent attempt to iterate over or reference this array results in accessing invalid memory locations. This specific type of error is classified under CWE-476, which denotes NULL Pointer Dereference, a common class of vulnerabilities that can lead to application crashes and potentially more severe exploitation scenarios depending on the context in which the dereferenced pointer is used.
The operational impact of this vulnerability primarily manifests as a denial of service condition for users or automated systems processing untrusted media files. When an attacker supplies a specially crafted IMF Composition Playlist, the FFmpeg process will encounter a fatal error and terminate unexpectedly due to the segmentation fault caused by the NULL dereference. This disruption can be particularly damaging in environments where FFmpeg is used as part of a larger pipeline for video transcoding, streaming services, or content ingestion systems that automatically parse incoming media files without rigorous pre-validation. The crash prevents legitimate users from accessing their intended media assets and can cause service outages if the application does not have robust error handling mechanisms to catch and recover from such exceptions gracefully.
In terms of threat modeling, this vulnerability aligns with ATT&CK technique T1496, which covers Resource Hijacking through denial-of-service vectors, although in this specific instance it is strictly limited to availability impact rather than resource exploitation for computational gain or persistence. The attack vector requires the victim to process a maliciously constructed file, placing this within the category of input validation flaws that are often exploited via social engineering or automated scanning tools targeting media processing services exposed on networks.
To mitigate this risk, organizations relying on FFmpeg must ensure they upgrade to version 8.1.3 or later, where the developers have implemented proper checks to validate resource arrays before dereferencing them. For environments unable to immediately patch, implementing a proxy layer that inspects incoming IMF files for structural integrity and validates track definitions against expected schemas can provide an additional defense-in-depth measure. Security teams should also configure their applications to handle segmentation faults gracefully by restarting the process rather than allowing it to remain in a corrupted state, although this is only a partial mitigation as repeated crashes may still lead to service degradation or resource exhaustion over time.