LangChain serialization injection vulnerability enables secret extraction (GHSA-r399-636x-v7f6)
- Severity:
- High
Description
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.
Recommendation
Update the @langchain/core package to the latest compatible version. Followings are version details:
Affected version(s): **< 0.3.80 >= 1.0.0, < 1.1.8** Patched version(s): **0.3.80 1.1.8**
References
Related Issues
- Lobe Chat affected by Cross-Site Scripting(XSS) that can escalate to Remote Code Execution(RCE) - CVE-2026-23733
- Websites were able to send any requests to the development server and read the response in vite - CVE-2025-24010
- Parsed HTML anchor links in Markdown provided to parseMarkdown can result in XSS in @nuxtjs/mdc - CVE-2025-24981
- Babel vulnerable to arbitrary code execution when compiling specifically crafted malicious code - CVE-2023-45133
- Tags:
- npm
- @langchain/core
Anything's wrong? Let us know Last updated on December 24, 2025