Security Vulnerability Report
中文
CVE-2025-63757 CVSS 7.5 HIGH

CVE-2025-63757

Published: 2025-12-18 15:15:57
Last Modified: 2025-12-30 20:04:36

Description

Integer overflow vulnerability in the yuv2ya16_X_c_template function in libswscale/output.c in FFmpeg 8.0.

CVSS Details

CVSS Score
7.5
Severity
HIGH
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Configurations (Affected Products)

cpe:2.3:a:ffmpeg:ffmpeg:8:*:*:*:*:*:*:* - VULNERABLE
FFmpeg 8.0
FFmpeg < 8.0 (可能受影响,需验证)

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
/* * CVE-2025-63757 PoC - Integer overflow in FFmpeg yuv2ya16_X_c_template * This PoC demonstrates triggering the integer overflow in libswscale * Compile: gcc -o poc poc.c -lavutil -lavcodec -lavformat -lavswscale */ #include <stdio.h> #include <stdlib.h> #include <stdint.h> // Simulate the vulnerable function behavior void simulate_yuv2ya16_overflow(int width, int height, int srcStride, int dstStride) { // Vulnerable calculation without overflow check int64_t required_size = (int64_t)height * srcStride; int64_t output_size = (int64_t)height * dstStride; printf("Width: %d, Height: %d\n", width, height); printf("Source stride: %d, Dest stride: %d\n", srcStride, dstStride); printf("Calculated size: %lld\n", required_size); // Trigger overflow with large values if (required_size > INT32_MAX || output_size > INT32_MAX) { printf("[+] Integer overflow detected!\n"); printf("[+] This can lead to buffer overflow or crash\n"); } } int main() { printf("CVE-2025-63757 PoC - FFmpeg Integer Overflow\n"); printf("===========================================\n\n"); // Test case 1: Normal values printf("Test 1: Normal values\n"); simulate_yuv2ya16_overflow(1920, 1080, 1920, 3840); printf("\n"); // Test case 2: Values that trigger overflow printf("Test 2: Overflow triggering values\n"); simulate_yuv2ya16_overflow(65536, 65536, 131072, 262144); return 0; } /* * Real-world exploitation: * 1. Create a malicious video file with crafted dimensions * 2. Use FFmpeg to process the file * 3. The yuv2ya16_X_c_template function will process the malformed YUV data * 4. Integer overflow occurs in size calculations * 5. This can lead to heap buffer overflow or denial of service */

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2025-63757", "sourceIdentifier": "[email protected]", "published": "2025-12-18T15:15:56.750", "lastModified": "2025-12-30T20:04:35.607", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "Integer overflow vulnerability in the yuv2ya16_X_c_template function in libswscale/output.c in FFmpeg 8.0."}], "metrics": {"cvssMetricV31": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H", "baseScore": 7.5, "baseSeverity": "HIGH", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "HIGH"}, "exploitabilityScore": 3.9, "impactScore": 3.6}]}, "weaknesses": [{"source": "134c704f-9b21-4f2e-91b3-4a467353bcc0", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-190"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:ffmpeg:ffmpeg:8:*:*:*:*:*:*:*", "matchCriteriaId": "5C890C75-1515-4BA4-B060-7851843CC0DB"}]}]}], "references": [{"url": "https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/20698", "source": "[email protected]", "tags": ["Issue Tracking"]}, {"url": "https://ffmpeg.org/security.html", "source": "[email protected]", "tags": ["Product"]}, {"url": "https://gist.github.com/miora-sora/43c1c5616dd5b4f960a9d20296ef4833", "source": "[email protected]", "tags": ["Patch"]}]}}