CVE-2024-47540 GHSL-2024-197: GStreamer uses uninitialized stack memory in Matroska/WebM demuxer

High 8.6 Published Updated

An attacker can hijack execution flow and potentially execute code via uninitialized stack memory in the GStreamer Matroska demuxer.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2024-47540?

CVE-2024-47540 is a high-severity memory corruption vulnerability in Gstreamer Gstreamer, published on 11 Dec 2024. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

GStreamer is a library for constructing graphs of media-handling components. An uninitialized stack variable vulnerability has been identified in the gst_matroska_demux_add_wvpk_header function within matroska-demux.c. When size < 4, the program calls gst_buffer_unmap with an uninitialized map variable. Then, in the gst_memory_unmap function, the program will attempt to unmap the buffer using the uninitialized map variable, causing a function pointer hijack, as it will jump to mem->allocator->mem_unmap_full or mem->allocator->mem_unmap. This vulnerability could allow an attacker to hijack the execution flow, potentially leading to code execution. This vulnerability is fixed in 1.24.10.

Weakness: CWE-908, CWE-457

Which versions are affected by CVE-2024-47540?

It affects 1 product.

Linux distribution packages (1)
gstreamer-plugins-good openSUSE:TumbleweedAll versions1.24.11-2.1

Products include Gstreamer Gstreamer.

How do I fix CVE-2024-47540?

Upgrade to a fixed version.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2024-47540 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-47540 exists.

All Gstreamer Gstreamer vulnerabilities

Sources

Also known as AZL-62393, DEBIAN-CVE-2024-47540, UBUNTU-CVE-2024-47540, openSUSE-SU-2025:14699-1.

Is CVE-2024-47540 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free