{"id":"CVE-2026-25879","published":"2026-06-01T22:27:13Z","modified":"2026-06-02T15:45:42Z","title":"Langroid has Prompt to SQL Injection, Leading to RCE","vendor":"langroid","product":"langroid","tier":"tail","description":{"text":"Langroid is a framework for building large-language-model-powered applications. Prior to version 0.63.0, SQLChatAgent executes SQL produced by an LLM, which is influenceable by prompt injection. When configured with a database role that has privileges enabling code execution or filesystem access (e.g., PostgreSQL pg_execute_server_program, MySQL FILE, MSSQL xp_cmdshell), an attacker who can shape the agent's input — including indirectly via data returned to the LLM — can coerce execution of dialect-specific primitives such as `COPY ... FROM PROGRAM`, achieving RCE on the database host. Fixed in v0.63.0 by defaulting SQLChatAgent to a SELECT-only sqlglot-parsed statement allowlist with a dialect-aware dangerous-pattern blocklist; allow_dangerous_operations=True restores the previous unrestricted behavior for trusted deployments.","provenance":"source","from":"CVE.org"},"cvss":{"score":9.8,"severity":"CRITICAL","version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00554,"percentile":0.47182,"provenance":"source"},"cwes":[{"id":"CWE-89","name":"Improper Neutralization of Special Elements used in an SQL Command"},{"id":"CWE-94","name":"Improper Control of Generation of Code"}],"references":[{"url":"https://github.com/langroid/langroid/security/advisories/GHSA-mxfr-6hcw-j9rq","tags":["x_refsource_CONFIRM"]}],"priority":{"score":16.3,"factors":[{"name":"EPSS percentile","points":9.44},{"name":"CVSS severity","points":6.86}]},"vendorSlug":"langroid","affectedVersions":[{"vendor":"langroid","product":"langroid","versions":["< 0.63.0"]}],"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"total","timestamp":"2026-06-02T15:03:18.990011Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"langroid","vulnerableRanges":["<0.63.0"],"patched":["0.63.0"],"from":["GHSA-mxfr-6hcw-j9rq","PYSEC-2026-382"],"provenance":"source"}],"euvd":{"id":"EUVD-2026-33830","exploited":false,"provenance":"source"}}