# CVE-2025-59730: Heap-buffer-overflow write in FFmpeg SANM decoding due to lack of bounds-checking in old\_codec48

- Priority: **Routine**
- Reason: Not severe (CVSS 5.7, adjacent network); no exploitation reported by the 5 checked sources
- Next step: Fix in the normal cadence
- Status: published
- Published: 2025-10-06 · Modified: 2025-10-06
- Aliases: UBUNTU-CVE-2025-59730, DEBIAN-CVE-2025-59730, CGA-24fw-q8v7-rj35, CGA-cq96-9cv9-w39m, CGA-qcgg-pm7x-7m5m, CGA-rp4m-6xv9-5px7, CGA-2phm-vmgr-mm8q, CGA-3457-8m5c-wqcf, CGA-477p-q64g-6mr5, CGA-4j29-qc2j-7f23, CGA-5ccw-g3v4-xf76, CGA-7qwj-585r-87vf, CGA-cfp3-vw5g-jx34, CGA-f579-2rq6-c38x, CGA-f7cr-g7h4-3997, CGA-gffc-cqxh-6g5f, CGA-ggw8-m4h3-g845, CGA-jfj4-9893-q727, CGA-jgqg-5367-jw3v, CGA-jp89-j86r-6hhr, CGA-m33x-7ffc-h2v4, CGA-p45h-w6v7-pc7j, CGA-pgm5-9r87-x77x, CGA-q8vc-m2vc-qvh7, CGA-qgq7-66jp-qx6q, CGA-w3xg-wvm3-p4fq, CGA-w7qv-pjv5-hgx7, CGA-wx4r-j789-53hr, CGA-2gxh-j756-xhfr, CGA-3pgh-v77h-6843, CGA-5w64-mj2h-wc7v, CGA-wv68-g8cv-mcvg, CGA-fr8w-8723-w276, CGA-hj47-grph-7p6m, CGA-hqm7-c253-97xm, CGA-vg9v-mm9p-g39f, CGA-6p6r-7cm4-766v, CGA-73mj-5m53-xmwg, CGA-9vpw-wx79-7r5j, CGA-jj5w-2gr8-qq83, CGA-mg6c-5p47-v286, CGA-mjg7-355q-wmq3, CGA-p74m-4rjp-rh58, CGA-q37f-mmwh-hc28, CGA-459m-7j5v-vm3w, CGA-83rx-4cmq-x8pr, CGA-gmvj-9rhh-g6wm, CGA-h3mc-g5gw-xjx9, CGA-h4x5-2j87-q4gg, CGA-x3cr-qwq5-vf9p, ALPINE-CVE-2025-59730
- Record: https://cvemate.com/vulnerability/CVE-2025-59730 · JSON: https://cvemate.com/vulnerability/CVE-2025-59730/json

## Description

```text
When decoding a frame for a SANM file (ANIM v0 variant), the decoded data can be larger than the buffer allocated for it.

Frames encoded with codec 48 can specify their resolution (width x height). A buffer of appropriate size is allocated depending on the resolution.

This codec can encode the frame contents using a run-length encoding algorithm. There are no checks that the decoded frame fits in the allocated buffer, leading to a heap-buffer-overflow.

process_frame_obj initializes the buffers based on the frame resolution:



We recommend upgrading to version 8.0 or beyond.
```

## Signals

- CVSS: 5.7 medium (v4.0, CVE.org) CVSS:4.0/AV:A/AC:H/AT:P/PR:L/UI:P/VC:L/VI:H/VA:N/SC:L/SI:H/SA:N
- EPSS: 0.162%, percentile 5.6%, as of 2026-12-04
- Known exploited (KEV): CISA not listed, ENISA not listed, CIRCL not listed
- Ransomware use: none recorded
- Public exploits: 0

## Affected (first 20 of 30)

- alpine ffmpeg (Alpine Linux): \< 8.0-r0
- chainguard eco-python-ffmpeg-6-minimal (Chainguard): All versions (No fix recorded)
- chainguard eco-python-ffmpeg-6-minimal-dev (Chainguard): All versions (No fix recorded)
- chainguard eco-python-ffmpeg-6-minimal-static (Chainguard): All versions (No fix recorded)
- chainguard eco-python-ffmpeg-7-minimal (Chainguard): All versions (No fix recorded)
- chainguard eco-python-ffmpeg-7-minimal-dev (Chainguard): All versions (No fix recorded)
- chainguard eco-python-ffmpeg-7-minimal-static (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-6 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-7 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-7.1 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-dev (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libavcodec61 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libavdevice61 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libavfilter10 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libavformat61 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libavutil59 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libpostproc58 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libswresample5 (Chainguard): All versions (No fix recorded)
- chainguard ffmpeg-fips-7.1-libswscale8 (Chainguard): All versions (No fix recorded)

## References

- <https://issuetracker.google.com/434637586>
- <https://ubuntu.com/security/CVE-2025-59730>
- <https://www.cve.org/CVERecord?id=CVE-2025-59730>
- <https://security-tracker.debian.org/tracker/CVE-2025-59730>
- <https://github.com/CVEProject/cvelistV5/tree/main/cves/2025/59xxx/CVE-2025-59730.json>
- <https://nvd.nist.gov/vuln/detail/CVE-2025-59730>
- <https://git.ffmpeg.org/ffmpeg.git>
- <https://security.alpinelinux.org/vuln/CVE-2025-59730>

---

Data as of 2026-12-05T06:22:22.884Z. The priority label is CveMate's own model from public evidence, not an official rating, and it knows nothing about your assets. How labels are decided: https://cvemate.com/faq#priority
