{"id":"CVE-2024-5827","published":"2024-06-28T19:27:33Z","modified":"2025-10-15T12:50:30Z","title":"Arbitrary File Write by Prompt Injection via DuckDB SQL in vanna-ai/vanna","vendor":"vanna-ai","product":"vanna-ai/vanna","tier":"core","eol":null,"affectedVersions":[{"vendor":"vanna-ai","product":"vanna-ai/vanna","versions":[">= unspecified, <= latest"]}],"ssvc":{"exploitation":"poc","automatable":"yes","technicalImpact":"total","timestamp":"2024-07-01T17:39:40.142547Z","from":"CISA ADP","provenance":"source"},"description":{"text":"Vanna v0.3.4 is vulnerable to SQL injection in its DuckDB integration exposed to its Flask Web APIs. Attackers can inject malicious SQL training data and generate corresponding queries to write arbitrary files on the victim's file system, such as backdoor.php with contents `<?php system($_GET[0]); ?>`. This can lead to command execution or the creation of backdoors.","provenance":"source","from":"CVE.org"},"summary":{"text":"The vulnerability is an SQL injection flaw in the DuckDB integration of vanna-ai/vanna (vanna-ai vendor) version 0.3.4, reachable through its Flask web APIs. An unauthenticated remote attacker can submit malicious SQL training data and trigger generation of corresponding queries that write arbitrary files to the victim's file system, such as a PHP backdoor, which can lead to command execution.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-01T01:03:39Z"},"cvss":{"score":9.8,"severity":"CRITICAL","version":"3.0","vector":"CVSS:3.0/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.03424,"percentile":0.89125,"date":"2026-11-24","provenance":"source"},"kev":null,"vulncheckKev":{"dateAdded":"2024-12-05","exploitedFirstSeen":"2024-12-05","ransomware":false,"evidence":[{"url":"https://dashboard.shadowserver.org/statistics/honeypot/vulnerability/map/?host_type=src&vulnerability=cve-2024-5827","date":"2024-12-05"}],"evidenceTotal":1,"provenance":"source"},"exploited":true,"otx":{"pulseCount":0,"pulses":[],"provenance":"machine"},"cwes":[{"id":"CWE-89","name":"Improper Neutralization of Special Elements used in an SQL Command"}],"references":[{"url":"https://huntr.com/bounties/e4e64a51-618b-41d0-8f56-1d2146d8825e","tags":[]}],"techniques":[],"reports":[],"affected":[],"advisories":[],"euvd":{"id":"EUVD-2024-46973","url":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2024-46973","exploited":false,"exploitedSince":null,"provenance":"source"},"exploits":[],"exploitSources":{"nuclei":[{"id":"CVE-2024-5827","name":"Vanna - SQL injection","severity":"critical","path":"http/cves/2024/CVE-2024-5827.yaml","url":"https://github.com/projectdiscovery/nuclei-templates/blob/main/http/cves/2024/CVE-2024-5827.yaml"}],"provenance":"source"},"exploitRefs":[],"flow":[],"timeline":[{"date":"2024-06-28","kind":"published","label":"Published (CVE.org)","url":"https://www.cve.org/CVERecord?id=CVE-2024-5827","provenance":"source"},{"date":"2024-12-05","kind":"exploited-reported","label":"Exploitation first reported (VulnCheck KEV evidence)","url":"https://dashboard.shadowserver.org/statistics/honeypot/vulnerability/map/?host_type=src&vulnerability=cve-2024-5827","provenance":"source"}],"speed":{"daysToPublicExploit":null,"firstExploitFrom":null,"daysToKev":null},"priority":{"score":64.7,"factors":[{"name":"In a KEV catalog","points":35.0,"detail":"listed in VulnCheck KEV"},{"name":"Recent KEV listing","points":0.0,"detail":"added 719 days ago"},{"name":"Known ransomware use","points":0.0,"detail":"not known"},{"name":"EPSS percentile","points":17.82,"detail":"percentile 0.8912"},{"name":"Named in threat reports","points":0.0,"detail":"0 reports"},{"name":"Public exploit code","points":5.0,"detail":"1 nuclei template"},{"name":"Mentioned in OTX pulses","points":0.0,"detail":"0 pulses"},{"name":"CVSS severity","points":6.86,"detail":"base score 9.8"},{"name":"End-of-life product","points":0.0,"detail":"supported or unknown"}]}}