{"id":"CVE-2025-5120","published":"2025-07-27T07:57:07Z","modified":"2025-07-28T14:09:25Z","title":"Sandbox Escape Vulnerability in huggingface/smolagents","vendor":"huggingface","product":"huggingface/smolagents","tier":"tail","description":{"text":"A sandbox escape vulnerability was identified in huggingface/smolagents version 1.14.0, allowing attackers to bypass the restricted execution environment and achieve remote code execution (RCE). The vulnerability stems from the local_python_executor.py module, which inadequately restricts Python code execution despite employing static and dynamic checks. Attackers can exploit whitelisted modules and functions to execute arbitrary code, compromising the host system. This flaw undermines the core security boundary intended to isolate untrusted code, posing risks such as unauthorized code execution, data leakage, and potential integration-level compromise. The issue is resolved in version 1.17.0.","provenance":"source","from":"CVE.org"},"cvss":{"score":7.6,"severity":"HIGH","version":"3.0","vector":"CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:H/A:L","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.31237,"percentile":0.98314,"provenance":"source"},"cwes":[{"id":"CWE-94","name":"Improper Control of Generation of Code"}],"references":[{"url":"https://huntr.com/bounties/63ab1cfe-b573-4cf5-a7d3-fb6c957e34b0","tags":[]},{"url":"https://github.com/huggingface/smolagents/commit/33a942e62b6fbf6a35d41f1c735bda2d64c163d0","tags":[]}],"priority":{"score":25.0,"factors":[{"name":"EPSS percentile","points":19.66},{"name":"CVSS severity","points":5.32}]},"vendorSlug":"huggingface","affectedVersions":[{"vendor":"huggingface","product":"huggingface/smolagents","versions":[">= unspecified, < 1.17.0"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2025-07-28T14:09:15.295611Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"PyPI","package":"smolagents","vulnerableRanges":["<1.17.0"],"patched":["1.17.0"],"from":["GHSA-6v92-r5mx-h5fx","PYSEC-2026-542"],"provenance":"source"}],"summary":{"text":"A sandbox escape flaw in the local_python_executor.py module of huggingface/smolagents lets the restricted Python execution environment be bypassed despite its static and dynamic checks. An attacker who can get untrusted code run through the agent, with a user interaction required, can abuse whitelisted modules and functions to execute arbitrary code on the host system.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-21T07:24:56Z"},"euvd":{"id":"EUVD-2025-22815","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2025-5120","published":"2025-07-27","fixed":"1.17.0","kev":false},{"cve":"CVE-2025-11844","published":"2025-10-22","fixed":"1.22.0","kev":false,"link":{"from":"CVE-2025-5120","to":"CVE-2025-11844","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"PyPI:smolagents","fromFixed":"1.17.0","toFixed":"1.22.0","daysApart":87}]}}],"package":"PyPI:smolagents"}}