Skip to content
HighVulnerability

GHSA-fg23-3346-88f5: Langroid: Path traversal in the file tools allows read/write outside configured current directory

Published
Record updated
View JSON
Affected
  • langroid <= 0.63.0
Fixed in
0.64.0
Known exploitation
Not listed in the CISA Known Exploited Vulnerabilities catalog at the last check.
EPSS
0.2%

Summary

Langroid's ReadFileTool and WriteFileTool in langroid/agent/tools/file_tools.py only change the process working directory to curr_dir and never check that the resolved file_path stays inside it. A tool caller can pass traversal sequences such as ../secret.txt to read, or ../written_by_tool.txt to write, files outside the configured directory. The source's local PoC confirmed both read and write escapes against the current repository checkout.

Mitigation

The source does not state a fix yet. Check the original advisory for updates.