{"id":"CVE-2025-54387","published":"2025-08-05T00:10:26Z","modified":"2025-08-05T14:11:59Z","title":"IPX is Vulnerable to Path Traversal via Prefix Matching Bypass","vendor":"unjs","product":"ipx","tier":"tail","description":{"text":"IPX is an image optimizer powered by sharp and svgo. In versions 1.3.1 and below, 2.0.0-0 through 2.1.0, and 3.0.0 through 3.1.0, the approach used to check whether a path is within allowed directories is vulnerable to path prefix bypass when the allowed directories do not end with a path separator. This occurs because the check relies on a raw string prefix comparison. This is fixed in versions 1.3.2, 2.1.1 and 3.1.1.","provenance":"source","from":"CVE.org"},"cvss":{"score":6.9,"severity":"MEDIUM","version":"4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:L/VI:N/VA:N/SC:H/SI:L/SA:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.01139,"percentile":0.6633,"provenance":"source"},"cwes":[{"id":"CWE-22","name":"Improper Limitation of a Pathname to a Restricted Directory"}],"references":[{"url":"https://github.com/unjs/ipx/security/advisories/GHSA-mm3p-j368-7jcr","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/unjs/ipx/commit/81693ddbfc062cc922e4e2406e8427ab4e3ad214","tags":["x_refsource_MISC"]},{"url":"https://github.com/unjs/ipx/releases/tag/v1.3.2","tags":["x_refsource_MISC"]},{"url":"https://github.com/unjs/ipx/releases/tag/v2.1.1","tags":["x_refsource_MISC"]},{"url":"https://github.com/unjs/ipx/releases/tag/v3.1.1","tags":["x_refsource_MISC"]}],"priority":{"score":18.1,"factors":[{"name":"EPSS percentile","points":13.27},{"name":"CVSS severity","points":4.83}]},"vendorSlug":"unjs","affectedVersions":[{"vendor":"unjs","product":"ipx","versions":["< 1.3.2",">= 2.0.0-0, < 2.1.1",">= 3.0.0, < 3.1.1"]}],"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"partial","timestamp":"2025-08-05T14:11:56.190437Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"npm","package":"ipx","vulnerableRanges":["<1.3.2",">=2.0.0-0, <2.1.1",">=3.0.0, <3.1.1"],"patched":["1.3.2","2.1.1","3.1.1"],"from":["GHSA-mm3p-j368-7jcr"],"provenance":"source"}],"summary":{"text":"IPX, the image optimizer in the unjs ipx product, contains a path traversal flaw: its check that a requested path stays inside the allowed directories compares raw string prefixes, so it can be bypassed when those directories do not end with a path separator. An unauthenticated remote attacker who can reach the service over the network, without any user interaction, can exploit this to read files outside the permitted directories, with limited confidentiality impact.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T21:29:24Z"},"euvd":{"id":"EUVD-2025-23570","exploited":false,"provenance":"source"}}