Intel

AIKIDO-2026-917028

langroid is vulnerable to Code Injection

Code InjectionGHSA-83w4-crcp-3w4p Published 4 days ago

98

Critical Risk

This Affects:

PYTHONlangroid
0.0.1 - 0.65.10
Fixed in 0.65.11
Are you affected? Scan for Free

TL;DR

CSVGraphAgent.pandas_to_kg executes fully LLM-generated Cypher through write_query without the validate_cypher_query and allow_dangerous_operations gating applied to the agent's other Cypher handlers. Input that influences the prompt, including CSV contents embedded verbatim into the system message, can drive arbitrary Cypher under the agent's Neo4j role. This allows full graph read and exfiltration, destructive writes, LOAD CSV from a remote URL, and configuration-conditional code execution where APOC or dbms procedures are enabled. The fix routes this handler through the same validation gate as the other Cypher tools.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and you use CSVGraphAgent against a Neo4j instance with untrusted CSV data or prompt-influenced input.

Background info

langroid is vulnerable to Code Injection in versions 0.0.1 - 0.65.10.

How to fix this

Upgrade the langroid library to the patch version.