{"cve":"CVE-2026-26013","nvd":{"published":"2026-02-10T22:17:00.453","modified":"2026-06-17T10:25:35.927","status":"Analyzed","description":"LangChain is a framework for building agents and LLM-powered applications. Prior to 1.2.11, the ChatOpenAI.get_num_tokens_from_messages() method fetches arbitrary image_url values without validation when computing token counts for vision-enabled models. This allows attackers to trigger Server-Side Request Forgery (SSRF) attacks by providing malicious image URLs in user input. This vulnerability is fixed in 1.2.11.","cvss_v4":null,"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:L","score":3.7},"cwes":["CWE-918"],"references":["https://github.com/langchain-ai/langchain/commit/2b4b1dc29a833d4053deba4c2b77a3848c834565","https://github.com/langchain-ai/langchain/releases/tag/langchain-core%3D%3D1.2.11","https://github.com/langchain-ai/langchain/security/advisories/GHSA-2g6r-c272-w58r"],"products":["langchain:langchain_core"],"source":"nvd","synced_at":"2026-10-19T22:23:35.260773158+00:00"},"epss":{"cve":"CVE-2026-26013","score":0.0043,"percentile":0.37252,"date":"2026-10-31"},"kev":null,"osv":[{"id":"GHSA-2g6r-c272-w58r","url":"https://osv.dev/vulnerability/GHSA-2g6r-c272-w58r","summary":"LangChain affected by SSRF via image_url token counting in ChatOpenAI.get_num_tokens_from_messages","modified":"2026-09-10T03:50:33.793703014Z","packages":[{"ecosystem":"PyPI","name":"langchain-core","purl":"pkg:pypi/langchain-core","ranges":["<1.2.11"],"fixed":["1.2.11"]}]},{"id":"PYSEC-2026-2562","url":"https://osv.dev/vulnerability/PYSEC-2026-2562","summary":"LangChain affected by SSRF via image_url token counting in ChatOpenAI.get_num_tokens_from_messages","modified":"2026-07-13T16:31:48.686407787Z","packages":[{"ecosystem":"PyPI","name":"langchain-core","purl":"pkg:pypi/langchain-core","ranges":["<1.2.11"],"fixed":["1.2.11"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}