HIGH8.8
PYSEC-2026-1432
Guardrails has an arbitrary code execution vulnerability
Quick fix
PYSEC-2026-1432 — guardrails-ai: upgrade to the fixed version with the command below.
pip install --upgrade 'guardrails-ai>=0.5.10'Details
An arbitrary code execution vulnerability exists in versions 0.2.9 up to 0.5.10 of the Guardrails AI Guardrails framework because of the way it validates XML files. If a victim user loads a maliciously crafted XML file containing Python code, the code will be passed to an eval function, causing it to execute on the user's machine.
Are you affected?
Enter the version of the package you're using.
Affected packages
PyPI/guardrails-ai
Introduced in:
0.2.9Fixed in: 0.5.10Fix
pip install --upgrade 'guardrails-ai>=0.5.10'References
- https://nvd.nist.gov/vuln/detail/CVE-2024-45858[ADVISORY]
- https://github.com/guardrails-ai/guardrails/commit/ab12701e8c3ef41273ff9b3912f2e4e28ae8306f[WEB]
- https://github.com/guardrails-ai/guardrails[PACKAGE]
- https://hiddenlayer.com/sai-security-advisory/2024-09-guardrails[WEB]
- https://pypi.org/project/guardrails-ai[PACKAGE]
- https://github.com/advisories/GHSA-w392-75q8-vr67[ADVISORY]