Skip to content

CVE-2025-34291: Langflow Permissive CORS & Account Takeover to RCE Chain

Density:
HERMES

HERMES THREAT SCORE & CISA KEV ACTIVELY WEAPONIZED RISK

Target: Langflow Visual AI Orchestration Framework (versions jusqu'à 1.6.9)
Confidence: 99%
98 / 100
EXTREME

Measures real-world operational relevance, exploit weaponization, and active threat posture.

Dimension Breakdown
Exploitability 20 / 20
Threat Activity 20 / 20
Weaponization 20 / 20
Exposure 19 / 20
Prevalence 18 / 20
Impact 20 / 20
Exploit Maturity 20 / 20
Attack Chain Potential 20 / 20
⚖️ Divergence & Operational Rationale

Cataloged in the CISA Known Exploited Vulnerabilities (KEV) catalog on May 21, 2026. While rated CVSS 9.4 due to required user interaction (UI:R), Hermes assigns an EXTREME HTS score of 98 and an EXTREME Agentic Security Score of 95. In production enterprise environments, Langflow orchestrates production AI agents and connects directly to databases, vector indexes, and cloud APIs. Chaining permissive CORS with SameSite=None refresh cookies enables drive-by session hijacking, leading directly to arbitrary remote code execution on the backend server.

🕸️ Connected Knowledge Graph & Provenance

CVE-2025-34291: Langflow Permissive CORS & Account Takeover to RCE ChainVULNERABILITY

Connected Nodes: 2
Active Relationships (Outgoing)
→ affectsPRODUCTLangflow AI Workflow Orchestrator
98% VERY_HIGH

Visual framework and multi-agent development environment for building, evaluating, and deploying conversational AI pipelines.

🔍 Why is this related? (Evidence & Provenance)

“Confirmed security vulnerability in Langflow Visual AI Builder documented in Hermes dossier.”

Supporting Verified Evidence:
→ exploitsAGENTIC ATTACK_PATTERNAAP-003: Tool Parameter Tampering & Built-in Bypass
92% VERY_HIGH

Adversarial subversion of structured tool execution arguments (SQL, Shell, Filepath) passed from an LLM agent to host OS tools or MCP endpoints.

🔍 Why is this related? (Evidence & Provenance)

“CVE-2025-34291 weaponizes the agentic attack pattern formalized under AAP-003.”

Supporting Verified Evidence:
ParameterTechnical SpecificationOperational Impact
CVE IdentifierCVE-2025-34291Official MITRE / NVD entry
CISA KEV StatusACTIVE EXPLOITATION CONFIRMEDCataloged on May 21, 2026
Associated CWEsCWE-346: Origin Validation Error
CWE-94: Code Injection
Drive-by admin account takeover & RCE
CVSS v3.1 Score9.4 CRITICALCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H
EPSS Probability0.978 (99.9th percentile)Widespread weaponized threat actor utilization
Hermes Threat Score (HTS)98 / 100 (EXTREME)Confirmed active exploitation in production
Hermes Agentic Score (HASS)95 / 100 (EXTREME)Total compromise of enterprise AI agent fleet
Affected Softwarelangflow:langflowVersions jusqu'à 1.6.9
Fixed Version1.7.0Strict CORS whitelisting & SameSite=Lax cookies

2. Technical Attack Chain: From Permissive CORS to Server Takeover

Section titled “2. Technical Attack Chain: From Permissive CORS to Server Takeover”

The vulnerability represents a textbook example of multi-stage web boundary collapse:

graph TD
Admin["Authenticated Langflow Administrator"] -->|1. Browses untrusted page| AttackerWeb["Attacker Malicious Website"]
AttackerWeb -->|2. Issues Cross-Origin Fetch with credentials| LangflowAPI["Langflow Backend (:7860)"]
LangflowAPI -->|3. Reflects CORS + sends SameSite=None Cookie| AttackerWeb
AttackerWeb -->|4. Steals Session Token & Submits Python Component| RCE["Arbitrary Code Execution on Server"]
RCE -->|5. Exfiltrates Vector DB Secrets & Model Keys| TotalLoss["Full Cloud & AI Asset Compromise"]
  1. The CORS Flaw: In Langflow’s FastAPI middleware configuration, the CORS handler permitted wildcard origins while concurrently accepting credentials:
    app.add_middleware(
    CORSMiddleware,
    allow_origins=["*"],
    allow_credentials=True,
    allow_methods=["*"],
    allow_headers=["*"],
    )
  2. SameSite=None Cookie Setting: Langflow stored the user’s refresh token inside an HTTP cookie flagged with SameSite=None without appropriate domain restrictions.
  3. Session Theft: When an administrator visited an attacker-controlled web page in another tab, JavaScript on the page issued credentialed cross-origin requests to the victim’s Langflow server. The browser automatically appended the session cookies.
  4. Elevation to RCE: With administrative session tokens in hand, the attacker invoked Langflow’s custom component APIs to deploy and execute a weaponized Python payload, securing root access to the hosting server.

  • HTTP Access Logs: Look for POST /api/v1/login/refresh and POST /api/v1/custom_component requests carrying unexpected or untrusted HTTP Origin headers.
  • Process Creation: Spawning of interactive shells (/bin/sh, /bin/bash, powershell) from the langflow or python parent process.

Upgrade Langflow to version 1.7.0 or later immediately:

Terminal window
pip install langflow>=1.7.0 --upgrade