CVE-2026-66758
Gimp: integer overflow in file-fits plugin causes a heap-based buffer overflow on crafted fits images
What happened?
A flaw was found in the file-fits plugin in GIMP. When processing a FITS image file, the plugin calculates memory allocation sizes using signed 32-bit integers for width and height. If a crafted file sets both values to large values, their product exceeds 2^31 and overflows, resulting in an undersized heap-based buffer allocation. This integer overflow issue results in a heap-based buffer overflow when cfitsio subsequently writes a full row of pixels in the buffer, causing memory corruption, potentially leading to arbitrary code execution or a denial of service.
Affected software and versions
| Software | Version information | Fixed version |
|---|---|---|
| gimpGNOME | Default status: affected | See vendor advisory |
| gimp:2.8Red Hat | unaffected: 8100020260824165450.4c9c024f to < * | See vendor advisory |
| gimpRed Hat | unaffected: 2:3.0.4-4.el9_8.9 to < * | See vendor advisory |
| gimpRed Hat | unaffected: 2:2.99.8-4.el9_2.7 to < * | See vendor advisory |
| gimpRed Hat | unaffected: 2:2.99.8-4.el9_4.19 to < * | See vendor advisory |
| gimpRed Hat | unaffected: 2:2.99.8-4.el9_6.20 to < * | See vendor advisory |
| gimpRed Hat | Default status: affected | See vendor advisory |
| gimpRed Hat | Default status: affected | See vendor advisory |
Version information comes from the source record and can include unaffected products and exceptions. Distribution packages may contain backported fixes: an older upstream version alone does not prove a server is affected.
Is it being exploited?
This CVE was not listed in the CISA catalogue at our last retrieval. This does not establish that exploitation is absent.
How to respond
- Confirm the product, installed package version, and any configuration requirements in the vendor advisory.
- Follow the vendor’s remediation or workaround guidance in the references below. Structured fixed-version data is unavailable here; the publisher’s description may include a fix or workaround.
- Restart affected services if required, then verify the running version. Known exploitation may warrant investigation as well as patching.
Sources and remediation references
- https://www.cve.org/CVERecord?id=CVE-2026-66758
- https://access.redhat.com/errata/RHSA-2026:50817
- https://access.redhat.com/errata/RHSA-2026:62507
- https://access.redhat.com/errata/RHSA-2026:73768
- https://access.redhat.com/errata/RHSA-2026:80509
- https://access.redhat.com/errata/RHSA-2026:93589
- https://access.redhat.com/security/cve/CVE-2026-66758
- https://bugzilla.redhat.com/show_bug.cgi?id=2507475
- https://gitlab.gnome.org/GNOME/gimp/-/issues/16528