{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2024-5826","id":"CVE-2024-5826","title":"Remote Code Execution via Prompt Injection in vanna-ai/vanna","description":"In the latest version of vanna-ai/vanna, the `vanna.ask` function is vulnerable to remote code execution due to prompt injection. The root cause is the lack of a sandbox when executing LLM-generated code, allowing an attacker to manipulate the code executed by the `exec` function in `src/vanna/base/base.py`. This vulnerability can be exploited by an attacker to achieve remote code execution on the","descriptionLong":"In the latest version of vanna-ai/vanna, the `vanna.ask` function is vulnerable to remote code execution due to prompt injection. The root cause is the lack of a sandbox when executing LLM-generated code, allowing an attacker to manipulate the code executed by the `exec` function in `src/vanna/base/base.py`. This vulnerability can be exploited by an attacker to achieve remote code execution on the app backend server, potentially gaining full control of the server.","published":"2024-06-27T18:40:37.441Z","updated":"2026-06-17T08:16:43.470Z","reserved":"2024-06-10T22:43:12.603Z","status":"Deferred","rejected":false,"assigner":"@huntr_ai","metric":{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"@huntr_ai"},"metrics":[{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"@huntr_ai"},{"version":"3.0","score":9.8,"vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","rating":"critical","source":"huntr.dev"}],"rating":"critical","products":["vanna-ai/vanna"],"affectedProducts":[{"vendor":"vanna-ai","product":"vanna-ai/vanna","defaultStatus":null,"versions":[{"version":"unspecified","status":"affected","versionType":"custom","lessThanOrEqual":"latest"}],"platforms":[]}],"packages":[],"cwes":["CWE-94"],"aliases":[],"references":[{"url":"https://huntr.com/bounties/90620087-44ac-4e43-b659-3c5d30889369","tags":["x_transferred"]}],"patchReferenced":false,"fixAvailable":false,"exploitReferenced":false,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total"},"epss":0.00882,"epssPercentile":0.59918,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2024-5826","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-5826","ok":true,"note":"Deferred"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2024-5826","ok":false,"note":"no open-source package data"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2024-5826","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}