File tree Expand file tree Collapse file tree
content/manuals/ai/sandboxes/security Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -126,14 +126,20 @@ $ sbx run claude
126126The proxy reads the variable from your terminal session. See individual
127127[ agent pages] ( ../agents/ ) for the variable names each agent expects.
128128
129+ > [ !NOTE]
130+ > These environment variables are set on your host, not inside the sandbox.
131+ > Sandbox agents are pre-configured to use credentials managed by the
132+ > host-side proxy. For custom environment variables not tied to a
133+ > [ supported service] ( #supported-services ) , see
134+ > [ Setting custom environment variables] ( ../faq.md#how-do-i-set-custom-environment-variables-inside-a-sandbox ) .
135+
129136## Best practices
130137
131138- Use [ stored secrets] ( #stored-secrets ) over environment variables. The OS
132139 keychain encrypts credentials at rest and controls access, while environment
133140 variables are plaintext in your shell.
134- - Don't set API keys manually inside the sandbox. Credentials stored in
135- environment variables or configuration files inside the VM are readable by
136- the agent process directly.
141+ - Don't set API keys manually inside the sandbox. Sandbox agents are
142+ pre-configured to use proxy-managed credentials.
137143- For Claude Code and Codex, OAuth is another secure option: the flow runs on
138144 the host, so the token is never exposed inside the sandbox. For Claude Code,
139145 use ` /login ` inside the agent. For Codex, run ` sbx secret set -g openai --oauth ` .
You can’t perform that action at this time.
0 commit comments