Path Traversal in langchain-ai/langchain (langchain-ai langchain-ai/langchain)
At a glance
- Source
- NVD
- EPSS
- EPSS 1.87 % · percentile 79 ()
- State
- PUBLISHED
- Published
- Updated
- Assigner
- @huntr_ai
- NVD status
- Analyzed
Description
langchain-ai/langchain is vulnerable to path traversal due to improper limitation of a pathname to a restricted directory ('Path Traversal') in its LocalFileStore functionality. An attacker can leverage this vulnerability to read or write files anywhere on the filesystem, potentially leading to information disclosure or remote code execution. The issue lies in the handling of file paths in the mset and mget methods, where user-supplied input is not adequately sanitized, allowing directory traversal sequences to reach unintended directories.
Weaknesses (CWE)
- CWE-22 — Improper Limitation of a Pathname to a Restricted Directory
References
Scores
| Version | Score | Vector | Scored by |
|---|---|---|---|
| CVSS 3.0 | MEDIUM 6.5 | CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N | @huntr_ai |
| CVSS 3.1 | HIGH 8.8 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H | NVD · nvd@nist.gov (Primary) |
| CVSS 3.0 | MEDIUM 6.5 | CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N | NVD · security@huntr.dev (Secondary) |
Advisories
- GHSA-rgp8-pm28-3759 — langchain vulnerable to path traversal
- PYSEC-2026-1510 — langchain vulnerable to path traversal
European references
- ENISA EUVD · EUVD-2024-1298
- GCVE · GCVE-0-2024-3571
CERT-FR advisories
- CERTFR-2025-AVI-0538 — Multiples vulnérabilités dans VMware Tanzu · cert.ssi.gouv.fr
Affected configurations (NVD CPE)
cpe:2.3:a:langchain:langchain:0.0.351:*:*:*:*:*:*:*
Affected products
| Product | Versions |
|---|---|
| langchain-ai · langchain-ai/langchain | affected unspecified < 0.0.353 |
Sources
| Source | Licence |
|---|---|
| CVE List (CVEProject cvelistV5) | CVE Program Terms of Use |
| EPSS (FIRST.org) | FIRST — attribution requested |
| ENISA EUVD | ENISA — reproduction authorised, source acknowledged |
| CERT-FR (ANSSI) | Licence Ouverte / Etalab 2.0 |
| NVD (NIST) via fkie-cad/nvd-json-data-feeds | Public domain — this product uses data from the NVD API but is not endorsed or certified by the NVD |