☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
[ VENDOR STATS ]
SOON 🐛 CWE-401
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2025-25946

CVE-2025-25946 Memory Leak in Bento4
📅 PUBLISHED: 2025-02-19 00:00 UTC 🔄 UPDATED: 2026-08-12 09:03 UTC
⏳ SCORE PENDING — ANALYSIS IN PROGRESS [ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.19%
👁️
0.19% probability
4.8× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
VULNERABLE: 1.6.0-641
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
SOON
PENDING NVD
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-25946 is a memory leak vulnerability in Bento4 v1.6.0-641, specifically within the AP4_MarlinIpmpEncryptingProcessor::Initialize and AP4_Processor::Process functions in Ap4Marlin.cpp and Ap4Processor.cpp. An attacker can trigger this leak by providing a specially crafted MP4 input file to the mp4encrypt utility, leading to uncontrolled memory consumption. This issue is unpatched, and no public exploit code or proof-of-concept is available. The vulnerability is classified under CWE-401 (Improper Release of Memory Before Removing Last Reference).

⚡ AUTOMATE YOUR CVE INTELLIGENCE

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.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

Bento4 is a C++ library and toolset for MP4 file manipulation, commonly used in media processing pipelines. This vulnerability affects the mp4encrypt binary, which is part of the Bento4 distribution. No package manager (NPM, PyPI, Go, Ruby) is involved; the software is typically compiled from source or distributed as a binary. Users should verify the integrity of their Bento4 builds and monitor for any updates from the vendor.

CVSS Breakdown & Threat Level

  • CVSS Score: 0.0 (No official CVSS vector assigned)
  • Attack Vector (AV): Local (requires crafted MP4 file)
  • Attack Complexity (AC): Low
  • Privileges Required (PR): None
  • User Interaction (UI): Required (user must run mp4encrypt on the malicious file)
  • Scope (S): Unchanged
  • Confidentiality (C): None
  • Integrity (I): None
  • Availability (A): Low (memory exhaustion)
  • Threat Level: Low (no remote exploitation, no data breach)

Deep Dive & Mechanics

The vulnerability resides in the Marlin IPMP (Intellectual Property Management and Protection) encrypting processor. When mp4encrypt processes a crafted MP4 file, the AP4_MarlinIpmpEncryptingProcessor::Initialize function allocates memory for encryption contexts but fails to release it properly if an error occurs during processing. Similarly, AP4_Processor::Process may leak memory when handling malformed track data. The leak is triggered by:

  1. Parsing a specially crafted MP4 file with malformed Marlin protection headers.
  2. The Initialize function allocating resources for encryption.
  3. An error condition (e.g., invalid track reference) causing an early return without freeing allocated memory.
  4. Repeated processing of such files leading to cumulative memory exhaustion.

The leak is not exploitable for code execution but can cause denial of service by exhausting system memory.

Vulnerable vs. Patched Code

Vulnerable Code (Bento4 v1.6.0-641):

// Ap4Marlin.cpp
AP4_Result AP4_MarlinIpmpEncryptingProcessor::Initialize(AP4_Track* track) {
    AP4_Result result = AP4_SUCCESS;
    // Allocate encryption context
    AP4_MarlinIpmpEncryptingTrack* encrypting_track = new AP4_MarlinIpmpEncryptingTrack();
    if (encrypting_track == NULL) {
        return AP4_ERROR_OUT_OF_MEMORY;
    }
    // ... processing that may fail ...
    if (AP4_FAILED(result)) {
        // Missing: delete encrypting_track;
        return result; // Leak occurs here
    }
    // ...
}

Patched Code (Hypothetical Fix):

AP4_Result AP4_MarlinIpmpEncryptingProcessor::Initialize(AP4_Track* track) {
    AP4_Result result = AP4_SUCCESS;
    AP4_MarlinIpmpEncryptingTrack* encrypting_track = new AP4_MarlinIpmpEncryptingTrack();
    if (encrypting_track == NULL) {
        return AP4_ERROR_OUT_OF_MEMORY;
    }
    // ... processing that may fail ...
    if (AP4_FAILED(result)) {
        delete encrypting_track; // Proper cleanup
        return result;
    }
    // ...
}

Exploitation & Lab Setup

Red Team

No public exploit code exists. To reproduce the vulnerability:

  1. Obtain Bento4 v1.6.0-641 source and compile mp4encrypt.
  2. Craft a malicious MP4 file with a malformed Marlin protection box (e.g., invalid sinf box or missing track reference).
  3. Run: ./mp4encrypt --method MARLIN --key <key> --property <prop> malicious.mp4 output.mp4
  4. Monitor memory usage with top or htop; repeated execution will show increasing memory consumption.

Blue Team

  • Monitor for excessive memory usage by mp4encrypt processes.
  • Use file integrity monitoring to detect crafted MP4 files.
  • Implement resource limits (ulimit) for media processing tools.
  • Sandbox mp4encrypt execution in a restricted environment.

Indicators of Compromise (IOCs)

  • File Hashes: No specific hashes available; crafted MP4 files will have unusual Marlin protection box structures.
  • Process Behavior: mp4encrypt consuming increasing memory over time.
  • Network: No network indicators (local vulnerability).
  • Logs: System logs may show out-of-memory errors when processing multiple malicious files.

Detection Engineering

YARA Rule

rule CVE_2025_25946_Bento4_Memory_Leak {
    meta:
        description = "Detects crafted MP4 files targeting Bento4 memory leak in Marlin processor"
        author = "Valters IT"
        date = "2025-03-01"
        reference = "CVE-2025-25946"
    strings:
        $marlin_box = "sinf"  // Protection scheme information box
        $marlin_header = { 6D 61 72 6C }  // "marl" in hex
        $invalid_track = { 00 00 00 00 }  // Potential null track reference
    condition:
        $marlin_box at 0 and $marlin_header and #invalid_track > 2
}

Sigma Rule

title: Bento4 mp4encrypt Memory Leak Exploitation Attempt
id: 7a8b9c0d-1e2f-3a4b-5c6d-7e8f9a0b1c2d
status: experimental
description: Detects execution of mp4encrypt with crafted MP4 files causing memory leak
author: Valters IT
date: 2025-03-01
logsource:
    category: process_creation
    product: linux
detection:
    selection:
        Image|endswith: '/mp4encrypt'
        CommandLine|contains: '--method MARLIN'
    condition: selection
falsepositives:
    - Legitimate use of Marlin encryption
level: low

Suricata Rule

alert http any any -> any any (msg:"CVE-2025-25946 Bento4 mp4encrypt Memory Leak Attempt"; flow:to_server; content:"|73 69 6E 66|"; depth:4; content:"|6D 61 72 6C|"; distance:0; within:4; classtype:attempted-dos; sid:1000001; rev:1;)

Remediation & Mitigation

  • Immediate: Avoid processing untrusted MP4 files with mp4encrypt. Use resource limits (e.g., ulimit -v 500000) to cap memory usage.
  • Short-term: Apply the hypothetical patch shown in the Vulnerable vs. Patched Code section to your local Bento4 build.
  • Long-term: Monitor the Bento4 project for an official fix. Consider switching to an alternative MP4 encryption tool (e.g., GPAC, FFmpeg with encryption support).
  • Detection: Deploy the YARA and Sigma rules to identify malicious files and process behavior.

Valters IT
Senior DevSecOps & Cyber Threat Intelligence Expert

👁️ SHODAN DORKS (THREAT HUNTING)

What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.

bento4 mp4encrypt
bento4 ap4marlin
◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-25946/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.