# CVE-2026-106119: LangChain: MongoDBChatMessageHistory query injection can allow cross-session access

- Severity: Medium 6.0 (CVSS:4.0, scored by GitHub_M) `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.46%, higher than 41% of CVEs (2026-12-01)
- Published: 2026-10-06T18:01:24.262Z
- Modified: 2026-10-08T18:00:08.902Z
- Also known as: GHSA-m6rx-h84q-8r95
- Weaknesses: CWE-943
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial
- Assigned by: GitHub_M

## Description

LangChain is a framework for building LLM-powered applications. Prior to 1.3.1, MongoDBChatMessageHistory does not enforce the documented string type for an untrusted structured session identifier at runtime, allowing the identifier to be interpreted as a MongoDB query condition rather than as a literal value when multiple users' histories are stored in a shared MongoDB collection. An attacker able to invoke chat-history operations can read, modify, or delete another user's stored conversation. Applications using authenticated, server-controlled string identifiers are not affected. This issue is fixed in version 1.3.1.

(As written by CVE List.)

## Affected

- langchain-ai langchainjs: < 1.5.14
- @langchain mongodb: < 1.3.1
- @langchain/mongodb (npm): before 1.3.1

## Every score

- GitHub_M: CVSS:4.0 6.0 Medium `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N`
- GitHub: CVSS:4.0 Medium `CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N`

## References

- <https://github.com/langchain-ai/langchainjs/security/advisories/GHSA-m6rx-h84q-8r95> (web)
- <https://github.com/langchain-ai/langchainjs/pull/11672> (web)
- <https://github.com/langchain-ai/langchainjs/commit/946e3d856ff1f8ce7f7b9374c83f680a6ada79af> (web)
- <https://github.com/langchain-ai/langchainjs/releases/tag/@langchain/mongodb@1.3.1> (web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-106119> (advisory)
- <https://github.com/langchain-ai/langchainjs> (package)

## Sources

- CVE List: [CVE-2026-106119](https://www.cve.org/CVERecord?id=CVE-2026-106119), CVE Terms of Use, modified 2026-10-06
- GitHub Advisory Database: [GHSA-m6rx-h84q-8r95](https://github.com/advisories/GHSA-m6rx-h84q-8r95), CC-BY-4.0, modified 2026-10-08
- NVD: [CVE-2026-106119](https://nvd.nist.gov/vuln/detail/CVE-2026-106119), Public domain, modified 2026-10-06

---

Page: https://cve.day/CVE-2026-106119 · Whole record: https://cve.day/CVE-2026-106119.json · Rebuilt by cve.day 2026-11-25T22:59:42.395Z
