Skip to main content
VulnerabilityPublished Updated

CVE-2026-34070: langchain · Path Traversal

Affects langchainSource CVE Database V5

0
Compare

Not known to be exploited · CVSS 7.5 High : upgrade to 1.2.22 soon.

Data as of 29 Oct 2026, 19:04 UTC

CVSS 3.1 base score
7.5High
How severe the flaw is on the 0–10 CVSS scale.
EPSS
1.4% chance of exploitation in 30 days – higher than 73% of CVEsExploit Prediction Scoring System: the likelihood attackers will use this flaw soon.
Patch
Available – fixed in 1.2.22
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

Exploitation evidence

  1. Disclosed: evidence found.

    CVE published 31 Mar 2026

  2. Detectable: no evidence on record.

    No public nuclei template indexed

  3. Weaponized: evidence found.

    Public exploit code: GitHub proofs of concept

  4. Exploited in the wild: no evidence on record.

    Not in CISA KEV and no source reports exploitation

  5. Observed by OffSeq Mirage: no evidence on record.

    No attack traffic recorded by OffSeq Mirage sensors

A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), GitHub proofs of concept, the Metasploit, Exploit-DB and nuclei-templates index as of 29 Oct 2026.

What to do

Upgrade langchain to 1.2.22.

Affected software

ProductAffectedFixed in
langchain-ailangchainAffected
  • <1.2.22
Fixed in
  • 1.2.22
PyPIlangchainpkg:pypi/langchainOther threatsAffected
  • <1.2.22
Fixed in
  • 1.2.22

Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.

AI-suggested

This vulnerability is patched in langchain version 1.2.22. Users should upgrade to version 1.2.22 or later to remediate this issue. Red Hat advisories confirm the availability of this fix. No additional mitigations are specified beyond applying the official patch.

Description

LangChain is a framework for building agents and LLM-powered applications. Prior to version 1.2.22, multiple functions in langchain_core.prompts.loading read files from paths embedded in deserialized config dicts without validating against directory traversal or absolute path injection. When an application passes user-influenced prompt configurations to load_prompt() or load_prompt_from_config(), an attacker can read arbitrary files on the host filesystem, constrained only by file-extension checks (.txt for templates, .json/.yaml for examples). This issue has been patched in version 1.2.22.

References

Community reviews

Loading reviews…