Intel

AIKIDO-2026-549562

enhanced-resolve is vulnerable to Path Traversal

Path Traversal Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published 2 days ago

30

Low Risk

This Affects:

JSenhanced-resolve
4.2.0 - 5.24.3
Fixed in 5.24.4
Are you affected? Scan for Free

TL;DR

The RestrictionsPlugin in enhanced-resolve confines module resolution to configured restrictions paths using an isInside containment check. That check treats a backslash as a path separator on every platform, so on posix systems a resolved path that begins with a restriction string followed by a backslash is accepted even though it names a sibling outside the restricted directory. This lets resolution succeed for files outside the intended boundary, defeating the confinement the restrictions option is meant to enforce. The fix aligns containment with path.win32 and path.posix semantics so a backslash stays an ordinary filename character on posix and the boundary is enforced correctly.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and you configure the restrictions option with string path prefixes to confine module resolution.

Background info

enhanced-resolve is vulnerable to Path Traversal in versions 4.2.0 - 5.24.3.

How to fix this

Upgrade the enhanced-resolve library to the patch version.