Intel

AIKIDO-2026-999895

shrine is vulnerable to Path Traversal

Pre-CVE
Found by Aikido Intel before public disclosure or CVE publication.
Published Jun 26, 2026
June 26, 2026

59

CVE Score

Medium

Path Traversal

Are you affected? Scan for Free

TL;DR

The file_system storage in shrine builds the full path to a file by joining the configured storage directory with the file id, without validating where the result resolves. When the id comes from attacker-controlled data, such as a tampered cached attachment hash containing ../ sequences, the path can resolve to a location outside of the storage directory. Operations like opening, deleting, checking existence, and uploading then act on arbitrary files on the host filesystem, allowing out-of-bounds file read and deletion. The fix raises Shrine::Error whenever an id would resolve outside of the storage directory.

How do I fix this?

Upgrade the shrine library to the patch version.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and your application uses the file_system storage with file identifiers derived from attacker-controlled data.

Package

Versions

0.9.0 - 3.7.1

Fixed in 3.8.0

Background info

shrine is vulnerable to Path Traversal in versions 0.9.0 - 3.7.1.

Get secure today,
quickly and for free.

Secure your code, cloud, and runtime in one central system. Connect a repo to discover what the reasoning agents find in your codebase.

No credit card required | Scan results in 32 seconds.

Trusted by 150k+ orgs
  • Revolut
  • n8n
  • Lovable
  • Deel
  • Prove
  • Omnea