PyPI: langroid
CVE-2026-50181
Safety vulnerability ID: SFTY-20260702-97723
Affected versions of the Langroid package are vulnerable to Path Traversal due to insufficient path validation in file operations. The `ReadFileTool` and `WriteFileTool` components fail to enforce that user-supplied `file_path` values remain within the configured `curr_dir`, allowing traversal sequences like `../` to access files outside the intended directory. An attacker can exploit this vulnerability by supplying crafted file paths to read or write files beyond the restricted directory, potentially exposing sensitive data or altering unauthorized files.
Overview
Langroid: Path traversal in the file tools allows read/write outside configured current directory
Advisory
langroid – Path Traversal
How to Fix
Mitigation and Workarounds
---
Vulnerable Functions
Functions linked to known vulnerabilities.
Verified by Safety
Our Cybersecurity Intelligence Team reviewed this vulnerability. We combine public data with our own research to find issues not yet reported to public sources.
Learn more
