CVE Catalog

CVE-2026-82455

HighCVSS 7.1
Published: Translated: NVD NIST

Summary

RubyGems fails to re-validate path containment after filesystem symlink resolution during gem extraction. When a pre-existing symlink inside the destination directory points outside the extraction root, extracted files that appear to be written under the destination directory can instead be written outside of it, breaking the extraction safety boundary. The fix resolves the real path of the parent directory before writing and raises Gem::Package::PathError if it escapes the destination directory.

Risk Assessment

An attacker could exploit this vulnerability to write files outside the intended directory, potentially leading to overwriting critical system files or gaining unauthorized access.

Recommendation

Update RubyGems to a version that includes the fix, which resolves the real path before writing and validates directory boundaries.

Other vulnerabilities in RubyGems

See all
Original NVD description (English source)

RubyGems fails to re-validate path containment after filesystem symlink resolution during gem extraction. When a pre-existing symlink inside the destination directory points outside the extraction root, extracted files that appear to be written under the destination directory can instead be written outside of it, breaking the extraction safety boundary. The fix resolves the real path of the parent directory before writing and raises Gem::Package::PathError if it escapes the destination directory.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS