FFmpeg versions 3.0 through 8.1.2 contain an out-of-bounds write vulnerability in the vf_swaprect video filter that allows attackers to corrupt heap… (CVE-2026-65706)
FFmpeg versions 3.0 through 8.1.2 contain an out-of-bounds write vulnerability in the vf_swaprect video filter. This occurs when processing crafted NV12 video frames with odd width dimensions, leading to heap memory corruption and potential process crashes. The issue arises from a buffer size mismatch during a memcpy operation in the filter_frame() function. This vulnerability can potentially allow code execution.
AI Analysis
Technical Summary
The vulnerability in FFmpeg's vf_swaprect video filter affects versions 3.0 through 8.1.2. It is caused by an out-of-bounds write due to reuse of a temporary row buffer sized for plane 0's single-byte pixel step across all planes. When processing a crafted NV12 video frame with odd width dimensions, specifically a 17x16 frame, an 18-byte memcpy is performed into a 17-byte heap allocation for the two-byte-per-sample interleaved chroma plane. This results in heap corruption and a process crash, with the potential for arbitrary code execution.
Potential Impact
Heap memory corruption can lead to process crashes and may allow attackers to execute arbitrary code. This compromises the confidentiality, integrity, and availability of affected systems running vulnerable FFmpeg versions.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. No official patch or fix information is provided in the available data. Users should monitor vendor communications for updates and avoid processing untrusted NV12 video frames with odd width dimensions in the vf_swaprect filter until a fix is available.
FFmpeg versions 3.0 through 8.1.2 contain an out-of-bounds write vulnerability in the vf_swaprect video filter that allows attackers to corrupt heap… (CVE-2026-65706)
Description
FFmpeg versions 3.0 through 8.1.2 contain an out-of-bounds write vulnerability in the vf_swaprect video filter. This occurs when processing crafted NV12 video frames with odd width dimensions, leading to heap memory corruption and potential process crashes. The issue arises from a buffer size mismatch during a memcpy operation in the filter_frame() function. This vulnerability can potentially allow code execution.
CVSS v4.0
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in FFmpeg's vf_swaprect video filter affects versions 3.0 through 8.1.2. It is caused by an out-of-bounds write due to reuse of a temporary row buffer sized for plane 0's single-byte pixel step across all planes. When processing a crafted NV12 video frame with odd width dimensions, specifically a 17x16 frame, an 18-byte memcpy is performed into a 17-byte heap allocation for the two-byte-per-sample interleaved chroma plane. This results in heap corruption and a process crash, with the potential for arbitrary code execution.
Potential Impact
Heap memory corruption can lead to process crashes and may allow attackers to execute arbitrary code. This compromises the confidentiality, integrity, and availability of affected systems running vulnerable FFmpeg versions.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. No official patch or fix information is provided in the available data. Users should monitor vendor communications for updates and avoid processing untrusted NV12 video frames with odd width dimensions in the vf_swaprect filter until a fix is available.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- GHSA-g9rh-4g64-7qxg
- Osv Schema Version
- 1.4.0
- Aliases
- ["CVE-2026-65706"]
- Ecosystems
- []
- Database Specific Severity
- HIGH
- Cvss Version
- 4.0
Threat ID: 6a629b0e9c2644c7f8d8632e
Added to database: 07/23/2026, 22:51:58 UTC
Last enriched: 07/24/2026, 00:06:58 UTC
Last updated: 07/24/2026, 03:48:28 UTC
Views: 7
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.