Back
CVE-2024-7774
Path Traversal in langchain-ai/langchainjs
Medium6.5EPSS 0.56%
- Published
- Updated
- Reserved
- Assigned by
- @huntr_ai
Description
A path traversal vulnerability exists in the `getFullPath` method of langchain-ai/langchainjs version 0.2.5. This vulnerability allows attackers to save files anywhere in the filesystem, overwrite existing text files, read `.txt` files, and delete files. The vulnerability is exploited through the `setFileContent`, `getParsedFile`, and `mdelete` methods, which do not properly sanitize user input.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| @huntr_aiCNA (assigner) | 3.0 | Medium6.5 | CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N |
| NVDNVD · Analyzed | 3.1 | Critical9.1 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N |
- EPSS (exploitation in 30 days)
- 0.56% · top 53% of all CVEs (6 Nov 2026)
- CISA SSVC
- Exploitation: poc · Automatable: no · Technical impact: partial
Loading the EPSS history…
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 6.5.
Weakness
Affected products
langchain-ai · langchain-ai/langchainjs
- affected unspecified – < 0.2.19
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- npmlangchainGHSA-hc5w-c9f8-9cc4 (opens in a new tab)
References (2)
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-hc5w-c9f8-9cc4 (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://trackcve.app/cve/CVE-2024-7774)Record last updated .