Description
Incomplete validation of dunder attributes allows an attacker to escape from the Local Python execution environment sandbox, enforced by smolagents. The attack requires a Prompt Injection in order to trick the agent to create malicious code.
Problem types
CWE-94 Improper Control of Generation of Code ('Code Injection')
Product status
References
research.jfrog.com/...on-sandbox-escape-jfsa-2025-001434277/
github.com/huggingface/smolagents/pull/1551