Description
libvips is a fast image processing library with low memory needs. Prior to version 8.18.3, libvips built with libultrahdr support can incorrectly size an output buffer in libvips/foreign/uhdrsave.c within vips_foreign_save_uhdr_set_raw_hdr when a pipeline enlarges an incoming JPEG to a very large output before encoding a gain map through VipsForeignSaveUhdr. The undersized allocation can cause a heap buffer over-read that may disclose adjacent data or crash the process. This issue is fixed in version 8.18.3.
Published: 2026-08-20
Score: 2 Low
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

libvips, a lightweight image processing library, contains a bug that can cause a heap buffer over-read when a JPEG image is enlarged and then re-encoded with a gain map. The flaw arises from an undersized output buffer allocation in the function that builds the raw header for UltraHDR output. An attacker who can provide a crafted image may trigger an over-read that could expose adjacent memory contents or crash the process. The vulnerability is classified as CWE‑125 and CWE‑126, both heap-based buffer over-read weaknesses.

Affected Systems

Versions of libvips prior to 8.18.3 that are compiled with libultrahdr support are affected. The issue is specifically triggered by pipelines that enlarge an incoming JPEG to a very large output before encoding a gain map through VipsForeignSaveUhdr. Upgrading to libvips 8.18.3 or later resolves the problem.

Risk and Exploitability

The CVSS score of 2 indicates low severity, and the EPSS score of <1% indicates a very low but non‑zero likelihood of exploitation in the wild. The vulnerability is not listed in the CISA KEV catalog, implying that no publicly known exploit code exists. The attack vector is inferred to be via image processing, potentially exploitable by any user who can supply images to a vulnerable libvips‑based application, but effective exploitation would require constructing a specific oversized JPEG that triggers the undersized buffer allocation.

Generated by OpenCVE AI on August 31, 2026 at 14:16 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Update libvips to version 8.18.3 or newer
  • Ensure that the upgraded library is linked in all affected application binaries
  • Disable gain map processing for external images if the enhanced feature is not required

Generated by OpenCVE AI on August 31, 2026 at 14:16 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Mon, 31 Aug 2026 12:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-125
References
Metrics threat_severity

None

cvssV3_1

{'score': 5.0, 'vector': 'CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:L/I:N/A:H'}

threat_severity

Moderate


Thu, 20 Aug 2026 23:45:00 +0000

Type Values Removed Values Added
First Time appeared Libvips
Libvips libvips
Vendors & Products Libvips
Libvips libvips

Thu, 20 Aug 2026 21:15:00 +0000

Type Values Removed Values Added
Description libvips is a fast image processing library with low memory needs. Prior to version 8.18.3, libvips built with libultrahdr support can incorrectly size an output buffer in libvips/foreign/uhdrsave.c within vips_foreign_save_uhdr_set_raw_hdr when a pipeline enlarges an incoming JPEG to a very large output before encoding a gain map through VipsForeignSaveUhdr. The undersized allocation can cause a heap buffer over-read that may disclose adjacent data or crash the process. This issue is fixed in version 8.18.3.
Title libvips: Possible heap-based buffer read overflow when resizing and re-encoding a JPEG with gain map
Weaknesses CWE-126
References
Metrics cvssV4_0

{'score': 2, 'vector': 'CVSS:4.0/AV:L/AC:H/AT:N/PR:L/UI:N/VC:L/VI:N/VA:L/SC:N/SI:N/SA:N'}


cve-icon MITRE

Status: PUBLISHED

Assigner: GitHub_M

Published:

Updated: 2026-08-21T21:45:43.586Z

Reserved: 2026-08-04T21:48:08.612Z

Link: CVE-2026-70652

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-08-20T21:17:08.270

Modified: 2026-08-21T22:16:43.600

Link: CVE-2026-70652

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-08-20T21:04:51Z

Links: CVE-2026-70652 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-08-31T14:30:09Z

Weaknesses