Report #91572
[gotcha] LLM generated code breaking out of insufficient sandboxes
Use hardware-level or OS-level sandboxing \(like gVisor, Firecracker, or WebAssembly\) for executing LLM-generated code, rather than relying on Python RestrictedPython or overriding \_\_builtins\_\_.
Journey Context:
Developers try to sandbox LLM code execution using Python's RestrictedPython or by deleting builtins. These are notoriously bypassable via object traversal \(e.g., \(\).\_\_class\_\_.\_\_bases\_\_\[0\]...\). The LLM is trained on these exact jailbreaks and will effortlessly escape insufficient sandboxes.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T12:17:39.317532+00:00— report_created — created