CVE-2025-68665Langchain.js
Critical 9.1 No auth needed
Follow: this CVE · Langchain · Langchain.js We alert you by email or Slack (account required).
- Priority
- 70
- CVSS 3.1
- 9.1
- EPSS
- —
- Auth required
- No
- Published
- Dec 23, 2025
- Updated
- Oct 19, 2026
- Category
- Application · Cross-platform
- Weakness (CWE)
- CWE-502
- SSVC (CISA)
- Exploitation: proof of concept · Automatable: yes · Technical impact: partial
- Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:N
What happens
LangChain is a framework for building LLM-powered applications. Prior to @langchain/core versions 0.3.80 and 1.1.8, and prior to langchain versions 0.3.37 and 1.2.3, a serialization injection vulnerability exists in LangChain JS's toJSON() method (and subsequently when string-ifying objects using JSON.stringify(). The method did not escape objects with 'lc' keys when serializing free-form data in kwargs. The 'lc' key is used internally by LangChain to mark serialized objects. When user-controlled data contains this key structure, it is treated as a legitimate LangChain object during deserialization rather than plain user data. This issue has been patched in @langchain/core versions 0.3.80 and 1.1.8, and langchain versions 0.3.37 and 1.2.3
What to do
- Apply the vendor's security update for Langchain.js.
- It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.
Affected packages
| Ecosystem | Package | Affected versions | Fixed in | How to upgrade |
|---|---|---|---|---|
| npm | @langchain/core |
≥ 1.0.0 < 1.1.8 |
1.1.8 |
npm install @langchain/core@1.1.8 |
| npm | @langchain/core |
< 0.3.80 |
0.3.80 |
npm install @langchain/core@0.3.80 |
| npm | langchain |
≥ 1.0.0 < 1.2.3 |
1.2.3 |
npm install langchain@1.2.3 |
| npm | langchain |
< 0.3.37 |
0.3.37 |
npm install langchain@0.3.37 |
Per OSV / GitHub Advisories (GHSA-r399-636x-v7f6). Check the version in your lockfile before upgrading.
Affected products (CPE)
| Vendor | Product | Versions |
|---|---|---|
| langchain | langchain.js | < 0.3.37 |
| langchain | langchain.js | ≥ 1.0.0 < 1.2.3 |
| langchain | langchain/core | < 0.3.80 |
| langchain | langchain/core | ≥ 1.0.0 < 1.1.8 |
Official sources
References
Links published by the sources. Open them with care.
- github.com Patch
- github.com Release Notes
- github.com Release Notes
- github.com Vendor Advisory