Critical severity · published Oct 29, 2024
CVE-2024-7774
Path Traversal in langchain-ai/langchainjs
9.1
CVSS
0.6%
EPSS
No
On KEV
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.
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
Attack vector
Network
Complexity
Low
Privileges
None
User interaction
None
Confidentiality
High
Integrity
High
Availability
None
Scope
Unchanged
Exploitation
Is it being used?
Exploit prediction (EPSS)0.6% · higher than 46% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
LA
langchain-ai/langchainjs · langchain-ai
before 0.2.19 · source: vendor
LA
Langchain.js · Langchain
0.2.5 · source: NVD
LA
Langchain-ai\/langchainjs · Langchain-ai
before 0.2.19 · source: CISA