All vulnerabilities

npm

CVE-2026-62297

ag-psd can exhaust memory when parsing crafted PSD dimensions

Severity
High 7.5
Published
13 Nov 2026
Last changed
13 Nov 2026
Added to UpHeron
23 Nov 2026
Fixed in
31.0.0
Exploit chance
0.5% in the next 30 daysHigher than 44% of CVEs. EPSS by FIRST, 24 Nov 2026
Weakness
CWE-789
Attack
Over the network · No login needed · No user action needed
Attacker can
Take it down
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Also known as
GHSA-qfx6-q44v-9qqw
Sources
OSV.dev and GitHub

Description

readPsd() commits the image/layer buffers from the declared header geometry (width x height x channels x depth, and per-layer rectangles) before validating those values against the actual data. A tiny crafted PSD declaring huge geometry forces a multi-gigabyte allocation.

On ag-psd 30.2.0, Node 24, a 52-byte PSD makes readPsd(buf) commit ~3.17 GB (measured peak RSS) in ~0.45 s before throwing a catchable RangeError ("Offset is outside the bounds of the DataView") — about 61,000,000x amplification. Because the buffer is committed before validation, the allocation OOM-kills the process before the error on essentially any host (uncatchable), and concurrent requests exhaust memory. Any service reading untrusted PSDs with ag-psd is exposed to a remote DoS.

This is distinct from #39 and #206, which involve genuinely large PSDs (memory proportional to real data). Here the input is 52 bytes: the file declares enormous geometry that is never present, so the allocation is driven by an…

From the GitHub Advisory Database, CC BY 4.0. Shortened; the full text is there.

Affected software

SoftwareAffected versions
ag-psdnpm · osv:npm:ag-psd
  • Every version before 31.0.0

About ag-psd

Weekly downloads (npm)
653,757npm, 24 Nov 2026

Vulnerabilities in ag-psd

In our list
2
Published in the last 12 months
2
Critical, last 12 months
0
High, last 12 months
2
Known exploited
0
Search the list for ag-psd

References