1. Home
  2. Vulnerabilities
  3. CVE-2026-62297

CVE-2026-62297

ag-psd has uncontrolled memory allocation via declared PSD dimensions (DoS)

Published 30 Oct 2026 · modified 2 Nov 2026 · Sources: NVD, CNA (vendor or assigner), CERT-FR, EPSS (FIRST)

Medium 50/100

Summary

ag-psd is a JavaScript library for reading and writing Photoshop Document files. Before the allocation-limit remediation attempt in version 31.0.0, `readPsd()` commits image and layer buffers from attacker-declared PSD geometry before validating the declarations against the actual available data or sane allocation limits. The `psdReader.js` implementation sizes off-heap typed arrays using `width`, `height`, `channels`, `depth` and `per-layer rectangles`, so a tiny PSD declaring enormous geometry can force multi-gigabyte memory allocation before a later bounds error. The reported 52-byte input on Node 24 produced approximately 3.17 GB peak RSS before a RangeError; under memory pressure the process can be terminated before the error can be caught, and concurrent inputs can exhaust memory. Services reading untrusted PSDs are exposed to denial of service. This differs from genuinely large PSD files whose memory demand is proportional to real input content. Version 31.0.0 adds a composite-image allocation limit, but complete coverage of the separately described layer-rectangle allocation path is not established and requires curator residual/scope review.

Affected products and versions

Agamnentzar (1 line(s))
Agamnentzar
ProductVersionsFixed inSource
ag-psd Versions not specified — CNA (vendor or assigner)
npm (1 line(s))
npm
ProductVersionsFixed inSource
ag-psd before 31.0.0 (excluded) 31.0.0 GitHub Advisory

Fix

Upgrade — npm/ag-psd 31.0.0official source

Source : GitHub Advisory

Workaround

No workaround provided.

Check whether you are affected

Exploit reported by sources

These links are tagged “exploit” by the NVD or CVE.org. We have neither verified nor copied them; open with care.

Timeline

  1. — CVE published (cve)

CERT-FR advisories

References

Data provenance

Status
NVD
Publication date
NVD
Description
CNA (vendor or assigner)
CVSS score
CNA (vendor or assigner)
Weakness (CWE)
NVD
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H (CVSS 3.1, CNA:GitHub_M)
Weakness
CWE-789 · Autre (CWE-789)

How this data is obtained and calculated