LangChain Community: redirect chaining can lead to SSRF bypass via RecursiveUrlLoader
Summary
| CVE | CVE-2026-27795 |
|---|---|
| State | PUBLISHED |
| Assigner | GitHub_M |
| Source Priority | CVE Program / NVD first with legacy fallback |
| Published | 2026-02-25 18:23:41 UTC |
| Updated | 2026-04-13 14:15:35 UTC |
| Description | LangChain is a framework for building LLM-powered applications. Prior to version 1.1.8, a redirect-based Server-Side Request Forgery (SSRF) bypass exists in `RecursiveUrlLoader` in `@langchain/community`. The loader validates the initial URL but allows the underlying fetch to follow redirects automatically, which permits a transition from a safe public URL to an internal or metadata endpoint without revalidation. This is a bypass of the SSRF protections introduced in 1.1.14 (CVE-2026-26019). Users should upgrade to `@langchain/community` 1.1.18, which validates every redirect hop by disabling automatic redirects and re-validating `Location` targets before following them. In this version, automatic redirects are disabled (`redirect: "manual"`), each 3xx `Location` is resolved and validated with `validateSafeUrl()` before the next request, and a maximum redirect limit prevents infinite loops. |
Risk And Classification
Primary CVSS: v3.1 7.4 HIGH from [email protected]
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:N/A:N
EPSS: 0.000420000 probability, percentile 0.125120000 (date 2026-04-15)
Problem Types: CWE-918 | CWE-918 CWE-918: Server-Side Request Forgery (SSRF)
| Version | Source | Type | Score | Severity | Vector |
|---|---|---|---|---|---|
| 3.1 | [email protected] | Primary | 7.4 | HIGH | CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:N/A:N |
| 3.1 | [email protected] | Secondary | 4.1 | MEDIUM | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:N/A:N |
| 3.1 | CNA | DECLARED | 4.1 | MEDIUM | CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:N/A:N |
CVSS v3.1 Breakdown
Attack Vector
NetworkAttack Complexity
LowPrivileges Required
NoneUser Interaction
RequiredScope
ChangedConfidentiality
HighIntegrity
NoneAvailability
NoneCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:N/A:N
NVD Known Affected Configurations (CPE 2.3)
| Type | Vendor | Product | Version | Update | Edition | Language |
|---|---|---|---|---|---|---|
| Application | Langchain | Langchain Community | All | All | All | All |
Vendor Declared Affected Products
| Source | Vendor | Product | Version | Platforms |
|---|---|---|---|---|
| CNA | Langchain-ai | Langchainjs | affected < 1.1.18 | Not specified |
References
| Reference | Source | Link | Tags |
|---|---|---|---|
| github.com/langchain-ai/langchainjs/pull/9990 | [email protected] | github.com | Issue Tracking |
| github.com/langchain-ai/langchainjs/security/advisories/GHSA-gf3v-fwqg-4vh7 | [email protected] | github.com | Not Applicable |
| github.com/langchain-ai/langchainjs/commit/d5e3db0d01ab321ec70a875805b2f... | [email protected] | github.com | Patch |
| github.com/langchain-ai/langchainjs/commit/2812d2b2b9fd9343c4850e2ab906b... | [email protected] | github.com | Patch |
| github.com/langchain-ai/langchainjs/releases/tag/%40langchain%2Fcommunit... | [email protected] | github.com | Release Notes |
| github.com/langchain-ai/langchainjs/releases/tag/%40langchain%2Fcommunit... | [email protected] | github.com | Release Notes |
| github.com/langchain-ai/langchainjs/security/advisories/GHSA-mphv-75cg-56wg | [email protected] | github.com | Vendor Advisory |
| CVE Program record | CVE.ORG | www.cve.org | canonical |
| NVD vulnerability detail | NVD | nvd.nist.gov | canonical, analysis |
No vendor comments have been submitted for this CVE.
There are currently no legacy QID mappings associated with this CVE.