intelligence_src_cdcffed32aa78fd61f
- Source-provided label
- Publisher RSS metadata
- Evidence class
- mentioned in report
- Confidence
- Not reported
- Observed
- Nov 06, 2026 11:14 UTC
- Retrieved
- Nov 11, 2026 10:33 UTC
A memory-safety flaw in CPython can allow malicious AI model templates to escape code sandboxes and execute arbitrary code inside inference servers, according to security researchers at RunSybil. “By exploiting this vulnerability, attackers could gain a foothold inside servers responsible for processing millions of user requests,” Darius Houle, a security researcher at RunSybil, wrote in a blog post. “They also could strike directly at the underlying cloud infrastructure hosting those workloads.” The researchers demonstrated how a specially crafted model could exploit the flaw to bypass Jinja, a Python-based templating engine used to structure interactions between users and LLMs, sandbox protections, and execute code in the process of serving the model. The attack could expose AI hosting providers that allow customers to upload and run their own models, potentially giving attackers a foothold inside infrastructure processing requests for multiple customers, the post added. However, the Python Security Response Team (PSRT), which handles security reports involving CPython, disputed the security implications of the demonstration in a response to CSO. “We acknowledge the underlying CPython bug reported by RunSybil and appreciate their contribution to fixing it. However, we do not consider the demonstrated sandbox escape to be a CPython security vulnerability,” the team said. The disagreement centres on whether the interpreter should be responsible for preventing sandbox escapes. While RunSybil argues that the flaw creates risks for AI inference infrastructure, PSRT says executing untrusted Python code within a sandbox is outside CPython’s security threat model. Exploiting Python’s type-handling mechanism “The bug we discovered abuses CPython’s handling of generic types to accomplish a breakout,” Houle wrote. “We exploited it using objects that sandboxes make available in every template, even in empty sandbox contexts.” The researchers found that CPython can use a cached list of parameters even after an object has been modified through a callback. When the interpreter subsequently looks for a newly introduced parameter in the original list, it can receive an invalid index. An assertion designed to catch the condition is disabled in normal release builds, allowing the interpreter to access memory outside the expected bounds. RunSybil used this behavior to retrieve references to Python objects that the sandbox was supposed to keep inaccessible. “While an invalid address will generally crash the interpreter, an address pointing to a useful live Python object gives our callback a reference to that object (even when the sandbox never intends to expose it),” Houle wrote. The researchers then used the recovered object references to access Python classes and functions needed to construct executable code. Malicious model templates enable code execution To demonstrate the attack, RunSybil modified the Qwen2.5-0.5B-Instruct model by inserting a backdoored chat_template.jinja file. When the model was loaded and used through an inference-serving engine such as vLLM, the template enabled arbitrary code execution in the serving process. “Breaking out of the chat template sandbox and executing code represents a supply chain risk that endangers inference providers, library developers, and model users,” Houle wrote. The researchers said they shared proof-of-concept exploits with multiple inference providers supporting bring-your-own-model (BYOM) features, which allow customers to upload models from external sources. Python disputes vulnerability classification RunSybil disclosed the issue to CPython, the Pallets Project, which maintains Jinja, and Hugging Face. The researchers said they encountered conflicting views about which project should address the underlying problem. CPython maintains that the interpreter does not support sandboxing untrusted Python code as
2982a7a6d45be734460223db0f6a18022aadcf5c12938e60268ab641218057ceNetwork indicators are visibly defanged. This page does not make them clickable or send them to another service.
No validated file hashes or network indicators are stored for this record.
This record contains metadata and attribution only. It does not host, download, unpack, render, or execute malware samples.
Sources represented on this page. Publication and observation dates describe the content; successful batch dates describe local collection. A recent batch does not certify complete coverage or current provider availability.
1 sources: 0 stale, 0 needing attention, 0 paused, 0 unverified.
Stale means older than twice the recorded collection interval, with a minimum of one hour; without an interval, the threshold is 24 hours. Cached content remains available while a feed is stale, paused, or unverified.