From 09e1d8384a1015998a3a7e4e751fd625501bc2a5 Mon Sep 17 00:00:00 2001 From: BaaRai <130491490+BaaRai@users.noreply.github.com> Date: Wed, 2 Dec 2026 16:39:41 +0100 Subject: [PATCH] docs: correct the sandbox dialer comment about proxy redirects The dialer sees each hop on a direct connection only. Through a proxy it sees the proxy, and sandboxRedirectCheck checks the hop. The old comment claimed all hops and redirects, which contradicted the redirect check added in this branch. --- agent/sandbox.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/agent/sandbox.go b/agent/sandbox.go index 84132cb2..a7c258cc 100644 --- a/agent/sandbox.go +++ b/agent/sandbox.go @@ -200,7 +200,8 @@ func SandboxEgressPolicy(ctx context.Context) *sandbox.EgressPolicy { // sandboxScopeDialContext wraps baseDial so every TCP connection made by panel // WebFetch in ARTEX_SANDBOX=required mode validates and pins the target IP via // the task's sandbox.EgressPolicy (blocking non-scope IPs, IMDS, loopback, -// RFC1918, and IPv6 across all hops and redirects). +// RFC1918, and IPv6). It sees each hop on a direct connection; through a proxy +// it only sees the proxy, and sandboxRedirectCheck checks the hop. func sandboxScopeDialContext(policy *sandbox.EgressPolicy, baseDial func(ctx context.Context, network, addr string) (net.Conn, error)) func(ctx context.Context, network, addr string) (net.Conn, error) { return SandboxScopeDialContext("WebFetch", policy, baseDial) }