fix(computer-server): harden unauthenticated network access - #2222
Open
civonafets wants to merge 1 commit into
Open
fix(computer-server): harden unauthenticated network access#2222civonafets wants to merge 1 commit into
civonafets wants to merge 1 commit into
Conversation
civonafets
requested review from
ddupont808,
f-trycua and
r33drichards
as code owners
July 15, 2026 06:36
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ServerAPImain.pyexecution bind to loopbackWhy
Local mode intentionally permits requests without a
CONTAINER_NAME, but the server exposes shell execution, arbitrary filesystem access, PTYs, browser control, and desktop input. Binding that mode to a network interface turns the service into unauthenticated remote code execution. Binding to loopback alone also leaves it reachable from a malicious web page unless browser origins are checked.Current
mainalready defaults the normal CLI to127.0.0.1. This change closes the remaining startup paths, prevents an explicit remote bind from silently disabling the protection, and covers the mounted MCP and other control routes that were not included in #1899. Authenticated container deployments keep their existing external-origin behavior. An isolated development setup can acknowledge the risk withCUA_ALLOW_UNAUTHENTICATED_REMOTE=1.Tests
CUA_TELEMETRY_ENABLED=false uv run --group test pytest libs/python/computer-server/tests -q(75 passed)Closes #1892