{"id":"CVE-2026-125229","summary":"FFmpeg through 9.0.2 Out-of-Bounds Memory Access in Huffyuv/FFVHUFF Median Predictor","details":"FFmpeg through 9.0.2 contains an out-of-bounds memory access vulnerability in the encode_frame() function of libavcodec/huffyuvenc.c, because encode_init() never validates minimum frame dimensions for the median predictor. Attackers can supply a tiny video, such as a 2-pixel-wide or 1-2-pixel-tall frame, that causes negative sub_median_pred lengths and out-of-bounds reads and writes when transcoded to huffyuv or ffvhuff, crashing the encoder.","modified":"2026-11-15T07:04:25.582758240Z","published":"2026-11-09T19:11:41.580Z","database_specific":{"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/125xxx/CVE-2026-125229.json","cna_assigner":"VulnCheck","cwe_ids":["CWE-787"]},"references":[{"type":"WEB","url":"https://code.ffmpeg.org/FFmpeg/FFmpeg"},{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/125xxx/CVE-2026-125229.json"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-125229"},{"type":"ADVISORY","url":"https://www.vulncheck.com/advisories/ffmpeg-through-9.0.2-out-of-bounds-memory-access-in-huffyuv-ffvhuff-median-predictor"},{"type":"REPORT","url":"https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/25573"},{"type":"FIX","url":"https://github.com/FFmpeg/FFmpeg/commit/45f98d0819efe2b7ce93e9034b7e6a4ed6700621"},{"type":"PACKAGE","url":"https://github.com/FFmpeg/FFmpeg"},{"type":"ARTICLE","url":"https://github.com/FFmpeg/FFmpeg/blob/n9.0.2/libavcodec/huffyuvenc.c#L762"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/ffmpeg/ffmpeg","events":[{"introduced":"0"},{"fixed":"45f98d0819efe2b7ce93e9034b7e6a4ed6700621"}],"database_specific":{"extracted_events":[{"source":"AFFECTED_FIELD","strategy":"StandardRange","range":[{"introduced":"0"},{"last_affected":"9.0.2"}]},{"range":[{"fixed":"45f98d0819efe2b7ce93e9034b7e6a4ed6700621"}],"source":"REFERENCES_COMMIT"}]}}],"versions":["n9.1-dev","n8.2-dev","n8.1-dev","n7.2-dev","n7.1-dev","n6.2-dev","n6.1-dev","n5.2-dev","n5.1-dev","n4.5-dev","n4.4-dev","n4.3-dev","n4.2-dev","n4.1-dev","n3.5-dev","n3.4-dev","n3.3-dev","n3.2-dev","n3.1-dev","n2.9-dev","n2.8-dev","n2.7-dev","n2.6-dev","n2.5-dev","n2.4-dev","n2.3-dev","n2.2-dev","n2.0","n2.1-dev","n1.3-dev","n1.2-dev","n1.1-dev","n0.12-dev","n0.11-dev","n0.8","N"],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-125229.json","vanir_signatures":[{"source":"https://github.com/ffmpeg/ffmpeg/commit/45f98d0819efe2b7ce93e9034b7e6a4ed6700621","target":{"file":"libavcodec/huffyuvenc.c"},"deprecated":false,"digest":{"line_hashes":["307667985491789000275631932974891260342","208621109897897082511578004248185495444","70917620550781355686414988586813650721"],"threshold":0.9},"id":"CVE-2026-125229-1776823b","signature_type":"Line","signature_version":"v1"},{"signature_type":"Function","signature_version":"v1","source":"https://github.com/ffmpeg/ffmpeg/commit/45f98d0819efe2b7ce93e9034b7e6a4ed6700621","target":{"file":"libavcodec/huffyuvenc.c","function":"encode_init"},"deprecated":false,"digest":{"function_hash":"63880948287330484787672774325776051131","length":5942},"id":"CVE-2026-125229-1a3d0eef"}],"vanir_signatures_modified":"2026-11-15T07:04:25Z"}}],"schema_version":"1.9.2","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N"}]}