The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2024-35368

CVE-2024-35368: FFmpeg Use-After-Free Vulnerability

CVE-2024-35368 is a use-after-free vulnerability affecting FFmpeg n7.0 via the rkmpp_retrieve_frame function. This article covers technical details, affected versions, potential impact, and mitigation strategies.

Updated: January 22, 2026

CVE-2024-35368 Overview

CVE-2024-35368 is a Double Free vulnerability affecting FFmpeg n7.0. The flaw exists within the rkmpp_retrieve_frame function in libavcodec/rkmppdec.c, where improper memory management can lead to a double free condition. This memory corruption vulnerability can be exploited remotely without authentication, potentially enabling attackers to execute arbitrary code, corrupt data, or cause denial of service conditions on systems processing malicious media files.

Critical Impact

This Double Free vulnerability in FFmpeg's Rockchip MPP decoder allows unauthenticated remote attackers to potentially achieve arbitrary code execution or crash applications by providing specially crafted media input to affected FFmpeg installations.

Affected Products

  • FFmpeg version 7.0
  • Applications and systems utilizing FFmpeg 7.0 with Rockchip MPP hardware decoding support
  • Debian-based distributions with vulnerable FFmpeg packages

Discovery Timeline

  • 2024-11-29 - CVE-2024-35368 published to NVD
  • 2025-11-03 - Last updated in NVD database

Technical Details for CVE-2024-35368

Vulnerability Analysis

This vulnerability is classified as CWE-415 (Double Free), a memory corruption flaw that occurs when the free() function is called twice on the same memory address. In the context of FFmpeg's rkmpp_retrieve_frame function, the issue arises during error handling in the Rockchip MPP hardware decoder implementation.

When an error occurs during frame buffer reference allocation (specifically when av_buffer_ref(decoder->frames_ref) fails), the original code path would jump to a fail label that would attempt to free resources that may have already been partially cleaned up. This creates a scenario where the same memory can be freed twice, leading to heap corruption.

Double free vulnerabilities are particularly dangerous because they can corrupt the heap's metadata structures, potentially allowing an attacker to overwrite arbitrary memory locations during subsequent memory allocations. This can be leveraged to achieve code execution by carefully controlling the heap state and subsequent allocations.

Root Cause

The root cause lies in the error handling logic within the rkmpp_retrieve_frame function in libavcodec/rkmppdec.c. When av_buffer_ref() fails to allocate a buffer reference for frame->hw_frames_ctx, the code previously used a goto fail pattern that would attempt to clean up the frame. However, if the frame had already been partially initialized, this could result in attempting to free already-freed memory.

The vulnerable code path did not properly account for the state of the frame object during error conditions, leading to the double free scenario when memory allocation failed.

Attack Vector

The attack vector is network-based, requiring no privileges or user interaction. An attacker can exploit this vulnerability by:

  1. Crafting a malicious media file designed to trigger specific error conditions in the Rockchip MPP decoder
  2. Causing the av_buffer_ref() function to fail (e.g., through memory pressure or malformed input)
  3. Triggering the flawed error handling path that leads to a double free
  4. Potentially achieving heap corruption and subsequent code execution

The vulnerability can be triggered through any application using FFmpeg to process untrusted media content, including media players, transcoding services, and streaming applications.

c
// Security patch for CVE-2024-35368 - avcodec/rkmppdec: Fix double-free on error
// Source: https://github.com/ffmpeg/ffmpeg/commit/4513300989502090c4fd6560544dce399a8cd53c
 
            frame->hw_frames_ctx = av_buffer_ref(decoder->frames_ref);
            if (!frame->hw_frames_ctx) {
-                ret = AVERROR(ENOMEM);
-                goto fail;
+                av_frame_unref(frame);
+                return AVERROR(ENOMEM);
            }

            return 0;

The fix replaces the goto fail pattern with an immediate av_frame_unref(frame) call followed by a direct return. This ensures the frame is properly cleaned up exactly once before returning the error, eliminating the double free condition.

Detection Methods for CVE-2024-35368

Indicators of Compromise

  • Unexpected crashes or segmentation faults in FFmpeg-based applications during media processing
  • Heap corruption errors or memory-related exceptions in system logs when processing media files
  • Unusual process behavior in applications utilizing FFmpeg's Rockchip MPP decoder
  • Core dumps showing double free or heap corruption in rkmppdec.c related functions

Detection Strategies

  • Monitor FFmpeg-based applications for abnormal termination patterns, particularly when processing video content
  • Implement memory sanitizers (AddressSanitizer, Valgrind) in development and testing environments to detect double free conditions
  • Deploy application crash monitoring to identify potential exploitation attempts
  • Review system logs for segmentation faults or memory allocation errors associated with FFmpeg processes

Monitoring Recommendations

  • Enable detailed logging for media processing applications to capture error conditions in decoder components
  • Implement runtime application self-protection (RASP) to detect heap corruption attempts
  • Monitor resource utilization for FFmpeg processes, as exploitation attempts may cause abnormal memory patterns
  • Set up alerts for repeated crashes in media processing workflows that could indicate active exploitation

How to Mitigate CVE-2024-35368

Immediate Actions Required

  • Update FFmpeg to a patched version that includes commit 4513300989502090c4fd6560544dce399a8cd53c
  • Review systems using FFmpeg 7.0 with Rockchip MPP hardware decoding support and prioritize updates
  • Implement input validation and sandboxing for media processing workflows handling untrusted content
  • Consider temporarily disabling Rockchip MPP hardware decoding if updates cannot be immediately applied

Patch Information

FFmpeg has released a security patch addressing this vulnerability. The fix is available in FFmpeg commit 4513300989502090c4fd6560544dce399a8cd53c. Debian has also issued an advisory for affected packages, available in the Debian LTS Announcement.

Organizations should update their FFmpeg installations to include this fix. For those building from source, ensure the patched code is incorporated. Package-based installations should check for updated packages from their distribution.

Workarounds

  • Disable Rockchip MPP hardware decoding by avoiding the -hwaccel rkmpp option or related configurations if not essential
  • Process untrusted media files in sandboxed environments with restricted memory access
  • Implement strict input validation to reject potentially malicious media files before processing
  • Use containerization or virtualization to isolate FFmpeg processing from critical systems
bash
# Example: Disable Rockchip MPP hardware acceleration in FFmpeg
# Instead of using hardware acceleration:
# ffmpeg -hwaccel rkmpp -i input.mp4 output.mp4

# Use software decoding as a workaround:
ffmpeg -i input.mp4 -c:v libx264 output.mp4

# Or explicitly disable hardware acceleration:
ffmpeg -hwaccel none -i input.mp4 output.mp4

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeUse After Free

  • Vendor/TechFfmpeg

  • SeverityCRITICAL

  • CVSS Score9.8

  • EPSS Probability0.18%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-415
  • Technical References
  • GitHub Gist Example Code

  • FFmpeg Source Code Snippet

  • Debian LTS Announcement
  • Vendor Resources
  • FFmpeg Commit Summary
  • Related CVEs
  • CVE-2025-1373: FFmpeg Use-After-Free Vulnerability

  • CVE-2025-69693: FFmpeg RV60 Decoder OOB Read Vulnerability

  • CVE-2025-12343: FFmpeg TensorFlow Backend DoS Vulnerability

  • CVE-2025-10256: FFmpeg Firequalizer Filter DoS Vulnerability
Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English