PatchSiren

PatchSiren cyber security CVE debrief

CVE-2026-125198 FFmpeg CVE debrief

A memory leak vulnerability exists in FFmpeg through version 9.0.2 in the mediaformat_jni_setBuffer() function within libavcodec/mediacodec_wrapper.c. This vulnerability occurs because buffers wrapped with NewDirectByteBuffer() are never freed. An attacker can exploit this by providing crafted media files with large extradata, leading to native memory leaks on each MediaCodec decoder configuration in Android applications, which can cause resource exhaustion.

Vendor
FFmpeg
Product
Unknown
CVSS
LOW 2
CISA KEV
Not listed in stored evidence
Original CVE published
2026-11-09
Original CVE updated
2026-11-13
Advisory published
2026-11-09
Advisory updated
2026-11-13

Who should care

Defenders responsible for Android applications that utilize FFmpeg for media processing should assess exposure and prioritize verification and remediation efforts. This includes reviewing the application's codebase, verifying the FFmpeg version, and ensuring that the application is not vulnerable to this memory leak vulnerability. Additionally, defenders should monitor for crafted media files with large extradata that could exploit this vulnerability and

Why it matters

Defenders should care about this vulnerability because it can lead to resource exhaustion in Android applications that use FFmpeg for media processing, potentially causing denial of service (DoS) and impacting application performance and stability. Verification and remediation efforts are necessary to prevent exploitation.

  • Resource exhaustion in Android applications due to native memory leaks
  • Potential denial of service (DoS) due to resource exhaustion
  • Need for verification of FFmpeg version and update to a fixed version
  • Possible impact on performance and stability of affected applications

Technical summary

The memory leak vulnerability in FFmpeg through version 9.0.2 is caused by the mediaformat_jni_setBuffer() function in libavcodec/mediacodec_wrapper.c never freeing buffers wrapped with NewDirectByteBuffer(). This can be exploited by supplying crafted media files with large extradata, leading to native memory leaks in Android applications and potentially causing resource exhaustion. The vulnerability can be triggered when an attacker provides a specially crafted media file that causes the mediaformat_jni_setBuffer() function to allocate a large amount of memory, which is not properly released. This can lead to a denial of service (DoS) condition, causing the application to consume excessive resources and become

Defensive priority

Defenders should prioritize verifying and updating FFmpeg to a version that fixes this memory leak vulnerability, especially in Android applications that utilize FFmpeg for media processing.

Recommended defensive actions

  • Verify FFmpeg version and update to a fixed version if necessary
  • Review Android applications that utilize FFmpeg for media processing and ensure they are not vulnerable
  • Monitor for crafted media files with large extradata that could exploit this vulnerability
  • Perform a thorough review of the Android application's codebase to identify potential areas where the vulnerability could be exploited
  • Implement additional monitoring and logging to detect potential exploitation attempts
  • Conduct regular security audits to identify and address potential vulnerabilities in the Android application
  • Consider implementing a Web Application Firewall (WAF) to detect and prevent exploitation attempts

Evidence notes

The vulnerability is confirmed in FFmpeg version 9.0.2. The source item from the GitHub Advisory Database provides details about the memory leak in the mediaformat_jni_setBuffer() function. Official CVE and NVD records also document this vulnerability.

Sources and references

Verified primary and authoritative sources

  • CVE-2026-125198 CVE Program record

    Publisher, destination, and source semantics verified

    URL: https://www.cve.org/CVERecord?id=CVE-2026-125198

    CVE Program - Official CVE Program record with source-provided CVE metadata.

  • CVE-2026-125198 NVD vulnerability detail

    Publisher, destination, and source semantics verified

    URL: https://nvd.nist.gov/vuln/detail/CVE-2026-125198

    NIST National Vulnerability Database - Official NIST NVD detail page and source-specific vulnerability assessment.

Supplemental references

  • FFmpeg through 9.0.2 contains a memory leak vulnerability in mediaformat_jni_setBuffer() in...

    Unverified legacy reference

    URL: https://github.com/advisories/GHSA-4q2x-vx5w-h3m6

    github_advisory_database

  • Source reference

    Unverified legacy reference

    URL: https://github.com/FFmpeg/FFmpeg/commit/e5d295b3cd467fc713300e208ba2dacc7ff603a0

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22550

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://github.com/FFmpeg/FFmpeg

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://github.com/FFmpeg/FFmpeg/blob/n9.0.2/libavcodec/mediacodec_wrapper.c

    Supplemental source

  • Source reference

    Unverified legacy reference

    URL: https://www.vulncheck.com/advisories/ffmpeg-through-9.0.2-memory-leak-via-mediacodec-jni-setbuffer

    Supplemental source

Methodology and review provenance

AI-assisted synthesis based on stored public vulnerability evidence. System validation, approval state, and publication status do not by themselves establish human review of this revision. PatchSiren helps prioritize defensive review and does not prove exposure or remediation on any system.