CVE-2026-55443: LangChain Path Resolution Vulnerability Leading to Potential File Disclosure

langchain Updated 18 Jul 2026

Summary

22/06/2026
Yes i
Medium
5.5

CVE-2026-55443: LangChain is a framework for building agents and LLM-powered applications. Affects langchain versions < 1.3.9. Fixed in 1.3.9. How to fix ↓

Also tracked for

The same CVE-2026-55443 is tracked separately for each ecosystem and vendor. Its fix information is the same; the package and affected versions differ.

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

LangChain is a framework designed for building agents and applications powered by large language models (LLMs). It provides various components that facilitate the resolution of filesystem paths and the expansion of search patterns. However, prior to version 1.3.9, several of these components did not adequately restrict resolved paths to the intended root directory, leading to security concerns.

Vulnerability Detail

The vulnerability arises from several LangChain components that fail to consistently confine resolved filesystem paths to a designated root directory. Specifically, a file-search agent middleware validates the starting directory but neglects to validate the search pattern or the resolved target of matched files. This oversight allows glob patterns and symlinks to access files outside the intended root. Additionally, loaders that accept path fields may resolve them without proper confinement, and path-prefix authorization checks can mistakenly accept sibling paths that share a prefix. When these components process path values or search patterns influenced by untrusted sources, such as LLMs acting on untrusted input, it can lead to unauthorized disclosure of files.

How To Fix

Latest published version: 1.4.7 as of 22 Oct 2026

pip install --upgrade "langchain==1.4.7"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.3.9

This is the first release that contains the fix.

pip install --upgrade "langchain==1.3.9"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

As a temporary workaround, ensure that any path values or search patterns processed by LangChain components are validated and sanitized before being passed to the framework. This can help mitigate the risk of unauthorized file access.

Conclusion

The CVE-2026-55443 vulnerability in LangChain poses a significant risk of unauthorized file disclosure due to improper path resolution. Users are strongly advised to update to version 1.3.9 or later to mitigate this risk. Additionally, implementing validation and sanitization of path inputs can serve as a temporary workaround.

See every vulnerability recorded for langchain →

Share this vulnerability

FAQ

CVE-2026-55443 is a vulnerability in the LangChain framework that allows unauthorized access to files outside the intended directory due to improper path resolution.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

The vulnerability can lead to unauthorized file disclosure, where sensitive files outside the intended directory may be accessed by untrusted sources.

Yes, the vulnerability is fixed in version 1.3.9 of LangChain. It is recommended to update to this version or later.

Vulert is a tool that monitors and alerts in real-time for open-source vulnerabilities in software, using just the Pipfile.lock file.

Related vulnerabilities

Recent vulnerabilities recorded for langchain.

How To Fix

Latest published version: 1.4.7 as of 22 Oct 2026

pip install --upgrade "langchain==1.4.7"

Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.

If you need the minimum change

1.3.9

This is the first release that contains the fix.

pip install --upgrade "langchain==1.3.9"

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback