Skip to content
HighVulnerabilityLLM-specific

GHSA-pjwx-r37v-7724: LangChain vulnerable to unsafe deserialization of attacker-controlled objects through overly broad `load()` allowlists

Published
Record updated
View JSON
Affected
  • langchain-core <= 0.3.84, fixed in 0.3.85, released May 5, 2026, 3 days before disclosure
  • langchain-core >= 1.0.0, <= 1.3.2, fixed in 1.3.3, released May 5, 2026, 3 days before disclosure
Known exploitation
Not listed in the CISA Known Exploited Vulnerabilities catalog at the last check.
EPSS
0.4%

Summary

LangChain's older runtime code paths deserialize run inputs, run outputs, and other application-controlled payloads using overly broad allowlists, sometimes calling `load()` with `allowed_objects="all"`. Attacker-supplied LangChain serialized constructor dictionaries can therefore cause trusted classes to be instantiated with untrusted constructor arguments, when the application accepts untrusted structured input and preserves it in run data. A related `_is_lc_secret` validation bypass in the serialization layer provides an additional path to the same revival logic.

Mitigation

LangChain will deprecate `RunnableWithMessageHistory`, `astream_log()` and `astream_events(version="v1")`, and applications should migrate to the currently recommended APIs, including the `stream` API. LangChain will also update `load()` and `loads()` to tighten deserialization so broad object revival is not applied implicitly to untrusted or application-controlled payloads.