Vulnerabilities

CVE-2026-32630

Medium 5.3 CVSS 3.1

Description

file-type detects the file type of a file, stream, or data. From 20.0.0 to 21.3.1, a crafted ZIP file can trigger excessive memory growth during type detection in file-type when using fileTypeFromBuffer(), fileTypeFromBlob(), or fileTypeFromFile(). The ZIP inflate output limit is enforced for stream-based detection, but not for known-size inputs. As a result, a small compressed ZIP can cause file-type to inflate and process a much larger payload while probing ZIP-based formats such as OOXML. This vulnerability is fixed in 21.3.2.

Description as published by the source, in English.

Key facts

Published
2026-03-16
Last modified
2026-06-17
Assigned by
security-advisories@github.com
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Scored by
security-advisories@github.com
Probability of exploitation
0.3 % higher than 22 % of all known vulnerabilities
EPSS, next 30 days, model v2026.06.15
Fix available
Yes, see references

Affected products

Vendor Product Versions Status
file-type (npm) ≥ 20.0.0, < 21.3.2 Affected
Sindresorhus File-type ≥ 20.0.0, < 21.3.2 Affected

Weakness type

References

Related at Berigo

Articles

Does this affect you?

A vulnerability matters only if you run the product, in an affected version, somewhere an attacker can reach.

Check your asset list Browse all vulnerabilities