Skip to content

fix(serve): bind 127.0.0.1 by default + warn on insecure public binds#234

Open
rylinjames wants to merge 1 commit into
mainfrom
fix/serve-bind-localhost-default
Open

fix(serve): bind 127.0.0.1 by default + warn on insecure public binds#234
rylinjames wants to merge 1 commit into
mainfrom
fix/serve-bind-localhost-default

Conversation

@rylinjames

Copy link
Copy Markdown
Collaborator

Audit §3.2 / Part 1 #5 — the highest serve-security item.

Problem

tether serve and tether go defaulted to host 0.0.0.0 with an empty api_key. Out of the box, the robot's /act endpoint was drivable by anyone on the network — no auth, all interfaces. (lerobot's CVE-2026-25874, an unauth RCE on its PolicyServer, makes secure-by-default robot serving both a real risk and a positioning advantage.)

Change — ⚠️ breaking, intentional

  • Default host is now 127.0.0.1 (localhost only).
  • Operators who need network exposure pass --host 0.0.0.0 explicitly.
  • When they bind a non-loopback host without --api-key, a prominent security warning prints (shared _warn_insecure_bind helper, wired into both serve transports and go).

Migration: existing setups that relied on remote access must add --host 0.0.0.0 (and ideally --api-key).

Tests

tests/test_serve_bind_security.py (5): serve+go default host is 127.0.0.1; warns on 0.0.0.0 / arbitrary public IP without a key; silent on loopback and when an api_key is set.

This is the serve-security default flip; the related auth gaps (/guard/reset unauthenticated, ZMQ unauthenticated kill) are separate runtime changes.

🤖 Generated with Claude Code

Audit §3.2 / Part 1 #5 (highest serve-security item).

`tether serve` and `tether go` defaulted to host 0.0.0.0 with an empty
api_key, so out of the box the robot's /act endpoint was drivable by anyone
on the network — no auth, all interfaces. lerobot's CVE-2026-25874 (unauth
RCE on its PolicyServer) makes secure-by-default serving both a real risk and
a positioning advantage.

BREAKING (intentional): the default host is now 127.0.0.1 (localhost only).
Operators who need network exposure pass --host 0.0.0.0 explicitly. When they
do so WITHOUT --api-key, a prominent security warning prints (shared
_warn_insecure_bind helper, wired into both serve transports and go).

Tests (tests/test_serve_bind_security.py, 5): serve+go default host is
127.0.0.1; warns on 0.0.0.0 / arbitrary public IP without a key; silent on
loopback (127.0.0.1/localhost/::1) and when an api_key is set.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant