Repository navigation
fix: publish the container transcript websocket on 127.0.0.1 only - #96
Merged
Mr-Pepe merged 1 commit intoOct 19, 2026
Merged
Conversation
Mr-Pepe
enabled auto-merge (squash)
October 19, 2026 16:49
Mr-Pepe
disabled auto-merge
October 19, 2026 17:16
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.
What
When you run an evaluation in Docker or Podman, anyone on your network can watch the entire run live. Karotte opens port 8001 so the terminal UI on your computer can show the transcript as it happens, and that stream has no password. Because the container command leaves
127.0.0.1off--publish, Docker and Podman open that port to every machine on the network instead of only yours. Anyone on the same Wi-Fi, office network, or shared server can connect tows://<your-ip>:8001and read the task prompt, the model's replies, every command and file the model touches, the submitted answers, and the score. Even if they connect late, the server replays the whole run from the start.The Apple VM, Firecracker, and Modal paths already lock this port to
127.0.0.1.apple_container.pyeven has a comment explaining why:get_container_run_commandinsrc/karotte/run_helpers.py(used fordocker,docker:gvisor,podman, andnerdctl) left127.0.0.1:off:Why
The live stream is only meant for the terminal UI on the machine running
karotte run. Inside the container, the WebSocket server accepts every connection and sends every event from the start of the run. Leaving the host port open on all network interfaces turns a local UI pipe into an unauthenticated feed of the evaluation, including private tasks, file contents, and grading output.How
127.0.0.1:{port}:{port}to--publishinget_container_run_command, matchingapple_container.py.TestGetContainerRunCommand.test_includes_port_publishto check for127.0.0.1:{port}:{port}.Testing
uv run --frozen --extra test python -m pytest tests/test_run_helpers.py::TestGetContainerRunCommand::test_includes_port_publish -n 0 -qtest_includes_port_publishfails on20ce4b2(8001:8001vs127.0.0.1:8001:8001) and passes with this patch.