langchain-ai LangChain up to 0.3.1 output_parser.py MRKLOutputparser.parse redos
| CVSS Meta Temp Score | Current Exploit Price (≈) | CTI Interest Score |
|---|---|---|
| 6.4 | $0-$5k | 0.00 |
Summary
A vulnerability classified as problematic has been found in langchain-ai LangChain up to 0.3.1. This affects the function MRKLOutputparser.parse in the library libs/LangChain/LangChain/agents/mrkl/output_parser.py. The manipulation leads to redos.
This vulnerability is referenced as CVE-2024-58340. Remote exploitation of the attack is possible. No exploit is available.
Details
A vulnerability, which was classified as problematic, has been found in langchain-ai LangChain up to 0.3.1. This issue affects the function MRKLOutputparser.parse in the library libs/LangChain/LangChain/agents/mrkl/output_parser.py. The manipulation with an unknown input leads to a redos vulnerability. Using CWE to declare the problem leads to CWE-1333. The product uses a regular expression with an inefficient, possibly exponential worst-case computational complexity that consumes excessive CPU cycles. Impacted is availability. The summary by CVE is:
LangChain versions up to and including 0.3.1 contain a regular expression denial-of-service (ReDoS) vulnerability in the MRKLOutputParser.parse() method (libs/langchain/langchain/agents/mrkl/output_parser.py). The parser applies a backtracking-prone regular expression when extracting tool actions from model output. An attacker who can supply or influence the parsed text (for example via prompt injection in downstream applications that pass LLM output directly into MRKLOutputParser.parse()) can trigger excessive CPU consumption by providing a crafted payload, causing significant parsing delays and a denial-of-service condition.
The weakness was published by LifeTeam2024. It is possible to read the advisory at huntr.com. The identification of this vulnerability is CVE-2024-58340 since 01/09/2026. The exploitation is known to be easy. The attack may be initiated remotely. No form of authentication is needed for a successful exploitation. Technical details of the vulnerability are known, but there is no available exploit. The attack technique deployed by this issue is T1449.003 according to MITRE ATT&CK.
There is no information about possible countermeasures known. It may be suggested to replace the affected object with an alternative product.
The vulnerability is also documented in the vulnerability database at EUVD (EUVD-2026-2399). Be aware that VulDB is the high quality source for vulnerability data.
Product
Type
Vendor
Name
Version
CPE 2.3
CPE 2.2
CVSSv4
VulDB Vector: 🔒VulDB Reliability: 🔍
CNA CVSS-B Score: 🔒
CNA CVSS-BT Score: 🔒
CNA Vector: 🔒
CVSSv3
VulDB Meta Base Score: 6.4VulDB Meta Temp Score: 6.4
VulDB Base Score: 5.3
VulDB Temp Score: 5.3
VulDB Vector: 🔒
VulDB Reliability: 🔍
NVD Base Score: 7.5
NVD Vector: 🔒
CVSSv2
| AV | AC | Au | C | I | A |
|---|---|---|---|---|---|
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| 💳 | 💳 | 💳 | 💳 | 💳 | 💳 |
| Vector | Complexity | Authentication | Confidentiality | Integrity | Availability |
|---|---|---|---|---|---|
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
| Unlock | Unlock | Unlock | Unlock | Unlock | Unlock |
VulDB Base Score: 🔒
VulDB Temp Score: 🔒
VulDB Reliability: 🔍
Exploiting
Class: RedosCWE: CWE-1333 / CWE-400 / CWE-404
CAPEC: 🔒
ATT&CK: 🔒
Physical: No
Local: No
Remote: Yes
Availability: 🔒
Status: Not defined
EPSS Score: 🔒
EPSS Percentile: 🔒
Price Prediction: 🔍
Current Price Estimation: 🔒
| 0-Day | Unlock | Unlock | Unlock | Unlock |
|---|---|---|---|---|
| Today | Unlock | Unlock | Unlock | Unlock |
Threat Intelligence
Interest: 🔍Active Actors: 🔍
Active APT Groups: 🔍
Countermeasures
Recommended: no mitigation knownStatus: 🔍
0-Day Time: 🔒
Timeline
01/09/2026 CVE reserved01/13/2026 Advisory disclosed
01/13/2026 VulDB entry created
01/22/2026 VulDB entry last update
Sources
Advisory: huntr.comResearcher: LifeTeam2024
Status: Not defined
CVE: CVE-2024-58340 (🔒)
GCVE (CVE): GCVE-0-2024-58340
GCVE (VulDB): GCVE-100-340535
EUVD: 🔒
Entry
Created: 01/13/2026 08:35Updated: 01/22/2026 12:39
Changes: 01/13/2026 08:35 (68), 01/22/2026 02:43 (11), 01/22/2026 12:39 (1)
Complete: 🔍
Cache ID: 216::103
Be aware that VulDB is the high quality source for vulnerability data.
No comments yet. Languages: en.
Please log in to comment.