CVE-2024-12366 CVE-2024-12366
Attackers can inject prompts to execute arbitrary Python code via PandasAI's interactive prompt function, leading to remote code execution.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- None listed
What is CVE-2024-12366?
CVE-2024-12366 is a critical code injection vulnerability in Sinaptik AI PandasAI, published on 11 Feb 2025. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
PandasAI uses an interactive prompt function that is vulnerable to prompt injection and run arbitrary Python code that can lead to Remote Code Execution (RCE) instead of the intended explanation of the natural language processing by the LLM.
Which versions are affected by CVE-2024-12366?
3 open source packages ship an affected version, including pandasai.
| Package | Affected | Fixed in |
|---|---|---|
pandasai PyPI | All versions to 2.4.2 | None |
pandasai PyPI | All versions to 2.4.2 | None |
pandasai PyPI | All versions to 2.4.2 | None |
How do I fix CVE-2024-12366?
No fix has been published for CVE-2024-12366 yet. Limit exposure of the affected software until one is available.
Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.
Is CVE-2024-12366 being exploited?
There is no known exploitation of CVE-2024-12366 in the wild and no public exploit code.
Sources
Also known as GHSA-vv2h-2w3q-3fx7, PYSEC-2026-448.