You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
protocol: tcp endpoint still runs the HTTP parser on plaintext traffic, and tls: skip cannot be set through policy update --add-endpoint #4903
I use OpenShell to run sandboxed browser desktops for AI agents. The browser reaches the internet only through a forward proxy that enforces the site list, so a mode change applies instantly instead of waiting for a policy revision. The sandbox policy allows only the proxy endpoint. I directly encountered the HTTP parser rejecting proxy traffic on an endpoint declared as protocol: tcp.
Problem Statement
Two small inconsistencies:
An endpoint with protocol: tcp still runs the HTTP parser on plaintext HTTP. A forward-proxy request (CONNECT or absolute-form) is allowed by OPA and then denied by the parser. protocol: tcp reads as "native TCP, no L7" (the validator even says "ask an administrator to add native TCP access explicitly"), so an opaque tunnel was expected.
Only tls: skip gives a raw tunnel, and it cannot be set through policy update --add-endpoint. The options segment accepts only allow-uninspected-credentials, websocket-credential-rewrite, request-body-credential-rewrite and allowed-ip=.
Impact / Why This Matters
To allow one proxy endpoint, the operator has to rewrite and re-apply the whole policy file with openshell policy set --policy ... instead of adding a single endpoint. Without reading the parser's denial reason, it looks as if HTTP proxies cannot be used from a sandbox at all.
With a full policy file and tls: skip on the endpoint, the proxy works (HTTP 200 through CONNECT) and the proxy's own allow/deny takes effect. A SOCKS5 proxy on a protocol: tcp endpoint works without tls: skip (not HTTP, so the parser does not engage), which is how we found the difference.
Acceptance Criteria
Either protocol: tcp skips the HTTP parser, or the docs state that plaintext HTTP on a tcp endpoint is still parsed and only tls: skip gives a raw tunnel.
tls: skip can be set for a single endpoint through policy update --add-endpoint.
Reproduction Steps
Run a plain HTTP forward proxy that supports CONNECT on proxy.internal:3128.
Activity