← back
CVE-2026-22860highCWE-22CWE-548

Rack has a Directory Traversal via Rack:Directory

21Vexday Risk Score

No sign of exploitation. No public exploitation artifact known so far.

ssvc Trackcvss 7.5epss 0.7%
exploitation probability
0.7%top 52% of all CVEs
observed exploitation
nono source reports it
In short

Rack::Directory allows attackers to list files and directories outside the intended root folder by crafting special URLs with path traversal sequences. This happens because the security check only compares text strings instead of properly validating the actual file path.

Technical detail

Rack::Directory uses a string prefix match on expanded paths to validate directory access, which can be bypassed via path traversal sequences like `/../root_example/` when the target path starts with the configured root string. An unauthenticated attacker can exploit this CWE-22 vulnerability to enumerate directories outside the intended root, leading to information disclosure (CWE-548). The issue is fixed in versions 2.2.22, 3.1.20, and 3.2.5.

Summary generated and translated by AI from the official description.
Rack is a modular Ruby web server interface. Prior to versions 2.2.22, 3.1.20, and 3.2.5, `Rack::Directory`’s path check used a string prefix match on the expanded path. A request like `/../root_example/` can escape the configured root if the target path starts with the root string, allowing directory listing outside the intended root. Versions 2.2.22, 3.1.20, and 3.2.5 fix the issue.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
Affected products
rack · rack