SECURITY & CVE TRACK RECORD
LangChain Security Advisories, CVEs & Patched Versions
Historical vulnerability disclosures, CVSS severity ratings, affected version ranges, and verified patch releases for LangChain.
LangSmith SDK: Public prompt pull deserializes untrusted manifests without trust boundary warning
## Description
The LangSmith SDK's prompt pull methods (`pull_prompt` / `pull_prompt_commit` in Python, `pullPrompt` / `pullPromptCommit` in JS/TS) fetch and deserialize prompt manifests from the LangSmith Hub. These manifests may contain serialized LangChain objects and mode...
Vulnerable Range:
0 -> 0.3.30
Fix Version:
0.3.30
Langchain SQL Injection vulnerability
A vulnerability in the GraphCypherQAChain class of langchain-ai/langchain version 0.2.5 allows for SQL injection through prompt injection. This vulnerability can lead to unauthorized data manipulation, data exfiltration, denial of service (DoS) by deleting all data, breaches i...
Vulnerable Range:
0 -> 0.2.0
Fix Version:
0.2.0
langchain vulnerable to path traversal
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, pote...
Vulnerable Range:
0 -> 0.0.353
Fix Version:
0.0.353
langchain Server-Side Request Forgery vulnerability
With the following crawler configuration:
```python
from bs4 import BeautifulSoup as Soup
url = "https://example.com"
loader = RecursiveUrlLoader(
url=url, max_depth=2, extractor=lambda x: Soup(x, "html.parser").text
)
docs = loader.load()
```
An attacker in control of...
Vulnerable Range:
0 -> 0.1.0
Fix Version:
0.1.0
Langchain Server-Side Request Forgery vulnerability
In Langchain before 0.0.329, prompt injection allows an attacker to force the service to retrieve data from an arbitrary URL, essentially providing SSRF and potentially injecting content into downstream tasks.
Vulnerable Range:
0 -> 0.0.329
Fix Version:
0.0.329
Langchain SQL Injection vulnerability
In Langchain before 0.0.247, prompt injection allows execution of arbitrary code against the SQL service provided by the chain.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
LangChain is a framework for building agents and LLM-powered applications. Prior to 1.3.9, several LangChain components that resolve filesystem paths or expand search patterns do not consistently conf
LangChain is a framework for building agents and LLM-powered applications. Prior to 1.3.9, several LangChain components that resolve filesystem paths or expand search patterns do not consistently confine the resolved path to the intended root directory. Affected behaviors incl...
Vulnerable Range:
0 -> 1.3.9
Fix Version:
1.3.9
LangChain: Path traversal and sandbox escape in LangChain file-search middleware and loaders
## Summary
Several LangChain components that resolve filesystem paths or expand search patterns do not consistently confine the *resolved* path to the intended root directory. Affected behaviors include: a file-search agent middleware that validates a starting directory but n...
Vulnerable Range:
0 -> 1.3.9, 0 -> 1.4.6
Fix Version:
1.3.9
LangSmith SDK: Public prompt pull deserializes untrusted manifests without trust boundary warning
## Description
The LangSmith SDK's prompt pull methods (`pull_prompt` / `pull_prompt_commit` in Python, `pullPrompt` / `pullPromptCommit` in JS/TS) fetch and deserialize prompt manifests from the LangSmith Hub. These manifests may contain serialized LangChain objects and mode...
Vulnerable Range:
0 -> 0.8.0, 0 -> 0.6.0, 0 -> 1.0.7
Fix Version:
0.8.0
Resolved in official release langchain==0.3.28. Review release changelog for technical vulnerability and fix details.
Vulnerable Range:
< langchain==0.3.28
Langchain SQL Injection vulnerability
A vulnerability in the GraphCypherQAChain class of langchain-ai/langchain version 0.2.5 allows for SQL injection through prompt injection. This vulnerability can lead to unauthorized data manipulation, data exfiltration, denial of service (DoS) by deleting all data, breaches i...
Vulnerable Range:
0.2.0 -> 0.2.19, 0 -> 0.2.0
Fix Version:
0.2.19
A vulnerability in the FAISS.deserialize_from_bytes function of langchain-ai/langchain allows for pickle deserialization of untrusted data. This can lead to the execution of arbitrary commands via the
A vulnerability in the FAISS.deserialize_from_bytes function of langchain-ai/langchain allows for pickle deserialization of untrusted data. This can lead to the execution of arbitrary commands via the os.system function. The issue affects the latest version of the product.
Vulnerable Range:
0 -> 0.2.9
Fix Version:
0.2.9
Denial of service in langchain-community
Denial of service in `SitemapLoader` Document Loader in the `langchain-community` package, affecting versions below 0.2.5. The `parse_sitemap` method, responsible for parsing sitemaps and extracting URLs, lacks a mechanism to prevent infinite recursion when a sitemap URL refer...
Vulnerable Range:
0 -> 0.2.5, 0 -> 0.2.5
Fix Version:
0.2.5
A Denial-of-Service (DoS) vulnerability exists in the `SitemapLoader` class of the `langchain-ai/langchain` repository, affecting all versions. The `parse_sitemap` method, responsible for parsing site
A Denial-of-Service (DoS) vulnerability exists in the `SitemapLoader` class of the `langchain-ai/langchain` repository, affecting all versions. The `parse_sitemap` method, responsible for parsing sitemaps and extracting URLs, lacks a mechanism to prevent infinite recursion whe...
Vulnerable Range:
0 -> 73c42306745b0831aa6fe7fe4eeb70d2c2d87a82, 0 -> 0.2.5
Fix Version:
73c42306745b0831aa6fe7fe4eeb70d2c2d87a82
langchain vulnerable to path traversal
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, pote...
Vulnerable Range:
0 -> 0.0.353
Fix Version:
0.0.353
LangChain directory traversal vulnerability
LangChain through 0.1.10 allows ../ directory traversal by an actor who is able to control the final part of the path parameter in a load_chain call. This bypasses the intended behavior of loading configurations only from the hwchase17/langchain-hub GitHub repository. The outc...
Vulnerable Range:
0 -> 0.0.339, 0 -> 0.1.30
Fix Version:
0.0.339
LangChain through 0.1.10 allows ../ directory traversal by an actor who is able to control the final part of the path parameter in a load_chain call. This bypasses the intended behavior of loading con
LangChain through 0.1.10 allows ../ directory traversal by an actor who is able to control the final part of the path parameter in a load_chain call. This bypasses the intended behavior of loading configurations only from the hwchase17/langchain-hub GitHub repository. The outc...
Vulnerable Range:
0 -> 0.1.11
Fix Version:
0.1.11
langchain Server-Side Request Forgery vulnerability
With the following crawler configuration:
```python
from bs4 import BeautifulSoup as Soup
url = "https://example.com"
loader = RecursiveUrlLoader(
url=url, max_depth=2, extractor=lambda x: Soup(x, "html.parser").text
)
docs = loader.load()
```
An attacker in control of...
Vulnerable Range:
0 -> 0.1.0
Fix Version:
0.1.0
Langchain Server-Side Request Forgery vulnerability
In Langchain before 0.0.329, prompt injection allows an attacker to force the service to retrieve data from an arbitrary URL, essentially providing SSRF and potentially injecting content into downstream tasks.
Vulnerable Range:
0 -> 0.0.329
Fix Version:
0.0.329
Langchain SQL Injection vulnerability
In Langchain before 0.0.247, prompt injection allows execution of arbitrary code against the SQL service provided by the chain.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
LangChain Server Side Request Forgery vulnerability
LangChain before 0.0.317 allows SSRF via `document_loaders/recursive_url_loader.py` because crawling can proceed from an external server to an internal server.
Vulnerable Range:
0 -> 0.0.317
Fix Version:
0.0.317
LangChain before 0.0.317 allows SSRF via document_loaders/recursive_url_loader.py because crawling can proceed from an external server to an internal server.
LangChain before 0.0.317 allows SSRF via document_loaders/recursive_url_loader.py because crawling can proceed from an external server to an internal server.
Vulnerable Range:
0 -> 9ecb7240a480720ec9d739b3877a52f76098a2b8, 0 -> 0.0.317
Fix Version:
9ecb7240a480720ec9d739b3877a52f76098a2b8
Langchain vulnerable to arbitrary code execution via the evaluate function in the numexpr library
An issue in LanChain-ai Langchain v.0.0.245 allows a remote attacker to execute arbitrary code via the evaluate function in the numexpr library.
Patches: Released in v.0.0.308. numexpr dependency is optional for langchain.
Vulnerable Range:
0 -> 0.0.308, 0 -> 2.8.5
Fix Version:
0.0.308
An issue in LanChain-ai Langchain v.0.0.245 allows a remote attacker to execute arbitrary code via the evaluate function in the numexpr library.
An issue in LanChain-ai Langchain v.0.0.245 allows a remote attacker to execute arbitrary code via the evaluate function in the numexpr library.
Vulnerable Range:
0 -> 0.0.308
Fix Version:
0.0.308
langchain vulnerable to arbitrary code execution
An issue in langchain v.0.0.171 allows a remote attacker to execute arbitrary code via the via the a json file to the `load_prompt` parameter. This is related to `__subclasses__` or a template.
Vulnerable Range:
0 -> 0.0.312
Fix Version:
0.0.312
An issue in langchain v.0.0.171 allows a remote attacker to execute arbitrary code via the via the a json file to the load_prompt parameter.
An issue in langchain v.0.0.171 allows a remote attacker to execute arbitrary code via the via the a json file to the load_prompt parameter.
Vulnerable Range:
0 -> 0.0.171
Fix Version:
0.0.171
LangChain vulnerable to arbitrary code execution
An issue in Harrison Chase langchain before version 0.0.236 allows a remote attacker to execute arbitrary code via the `from_math_prompt` and `from_colored_object_prompt` functions.
Vulnerable Range:
0 -> 0.0.236
Fix Version:
0.0.236
LangChain vulnerable to arbitrary code execution
An issue in LangChain prior to v.0.0.247 allows a remote attacker to execute arbitrary code via the prompt parameter.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
LangChain vulnerable to arbitrary code execution
An issue in langchain langchain-ai before version 0.0.325 allows a remote attacker to execute arbitrary code via a crafted script to the PythonAstREPLTool._run component.
Vulnerable Range:
0 -> 0.0.325
Fix Version:
0.0.325
An issue in LangChain v.0.0.231 allows a remote attacker to execute arbitrary code via the prompt parameter.
An issue in LangChain v.0.0.231 allows a remote attacker to execute arbitrary code via the prompt parameter.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
An issue in Harrison Chase langchain v.0.0.194 and before allows a remote attacker to execute arbitrary code via the from_math_prompt and from_colored_object_prompt functions.
An issue in Harrison Chase langchain v.0.0.194 and before allows a remote attacker to execute arbitrary code via the from_math_prompt and from_colored_object_prompt functions.
Vulnerable Range:
0 -> 0.0.195
Fix Version:
0.0.195
An issue in langchain langchain-ai v.0.0.232 and before allows a remote attacker to execute arbitrary code via a crafted script to the PythonAstREPLTool._run component.
An issue in langchain langchain-ai v.0.0.232 and before allows a remote attacker to execute arbitrary code via a crafted script to the PythonAstREPLTool._run component.
Vulnerable Range:
0 -> 0.0.233
Fix Version:
0.0.233
langchain Code Injection vulnerability
An issue in Harrison Chase langchain allows an attacker to execute arbitrary code via the PALChain,from_math_prompt(llm).run in the python exec method.
Vulnerable Range:
0 -> 0.0.236
Fix Version:
0.0.236
An issue in Harrison Chase langchain v.0.0.194 allows an attacker to execute arbitrary code via the python exec calls in the PALChain, affected functions include from_math_prompt and from_colored_obje
An issue in Harrison Chase langchain v.0.0.194 allows an attacker to execute arbitrary code via the python exec calls in the PALChain, affected functions include from_math_prompt and from_colored_object_prompt.
Vulnerable Range:
0 -> 0.0.236
Fix Version:
0.0.236
langchain vulnerable to arbitrary code execution
An issue in langchain allows a remote attacker to execute arbitrary code via the PALChain parameter in the Python exec method.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
langchain SQL Injection vulnerability
SQL injection vulnerability in langchain allows a remote attacker to obtain sensitive information via the SQLDatabaseChain component.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
An issue in langchain v.0.0.64 allows a remote attacker to execute arbitrary code via the PALChain parameter in the Python exec method.
An issue in langchain v.0.0.64 allows a remote attacker to execute arbitrary code via the PALChain parameter in the Python exec method.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
SQL injection vulnerability in langchain v.0.0.64 allows a remote attacker to obtain sensitive information via the SQLDatabaseChain component.
SQL injection vulnerability in langchain v.0.0.64 allows a remote attacker to obtain sensitive information via the SQLDatabaseChain component.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
langchain arbitrary code execution vulnerability
An issue in langchain allows an attacker to execute arbitrary code via the PALChain in the python exec method.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
An issue in langchain v.0.0.199 allows an attacker to execute arbitrary code via the PALChain in the python exec method.
An issue in langchain v.0.0.199 allows an attacker to execute arbitrary code via the PALChain in the python exec method.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
Langchain vulnerable to arbitrary code execution
Langchain 0.0.171 is vulnerable to Arbitrary code execution in `load_prompt`.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
Langchain 0.0.171 is vulnerable to Arbitrary code execution in load_prompt.
Langchain 0.0.171 is vulnerable to Arbitrary code execution in load_prompt.
Vulnerable Range:
0 -> 0.0.247
Fix Version:
0.0.247
Langchain OS Command Injection vulnerability
Langchain before v0.0.225 was discovered to contain a remote code execution (RCE) vulnerability in the component JiraAPIWrapper (aka the JIRA API wrapper). This vulnerability allows attackers to execute arbitrary code via crafted input. As noted in the "releases/tag" reference...
Vulnerable Range:
0 -> 0.0.225
Fix Version:
0.0.225
Langchain 0.0.171 is vulnerable to Arbitrary Code Execution.
Langchain 0.0.171 is vulnerable to Arbitrary Code Execution.
Vulnerable Range:
0 -> 0.0.225
Fix Version:
0.0.225
LangChain vulnerable to code injection
In LangChain through 0.0.131, the `LLMMathChain` chain allows prompt injection attacks that can execute arbitrary code via the Python `exec()` method.
Vulnerable Range:
0 -> unfixed
Fix Version:
Review Advisory
In LangChain through 0.0.131, the LLMMathChain chain allows prompt injection attacks that can execute arbitrary code via the Python exec method.
In LangChain through 0.0.131, the LLMMathChain chain allows prompt injection attacks that can execute arbitrary code via the Python exec method.
Vulnerable Range:
0 -> 0.0.132
Fix Version:
0.0.132