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
fix(security): mobile token, bind-address, route scoping, validator hardening
P1-1 StartMCPServer binds 127.0.0.1 by default; 0.0.0.0 only in Docker mode.
StartRemoteServer keeps 0.0.0.0 (explicit user action for WiFi/mobile).
P1-2 Coordinator token never returned to renderer. Removed 'token' field from
StartRemoteServer, GetRemoteStatus, and StartMCPServer IPC returns.
GetMCPStatus.serverUrl now uses getMCPRemoteServerUrl (no token).
RemoteAccess store type and initial state updated accordingly.
P1-3 Third mobileToken generated at startup. wifiUrl/tailscaleUrl/url all
embed mobileToken instead of coordinator token. Mobile callers are
classified as 'mobile' and restricted to GET /api/agents, GET /api/tasks
(read-only). Only coordinator token grants WebSocket + write routes.
P2-1 redactServerUrl() exported from server.ts; used in register.ts console.warn
to strip token query param before logging.
P2-2 validateBranchName rejects path traversal (/../) and shell metacharacters
(`$(){}[]<>\\'*?!#;|&") in addition to existing control-char checks.
P2-3 MCP_HydrateCoordinatedTask now calls validateBranchName on branchName and
baseBranch (if present) — matches validation enforced by createTask.
P2-4 PARALLEL_CODE_MCP_TOKEN added to SpawnAgent ENV_BLOCK_LIST so a crafted
IPC call cannot override the MCP auth token in spawned agents.
P2-5 X-Coordinator-Id header is now verified against registered coordinators
(isRegisteredCoordinator) before being used for task scoping. Unregistered
IDs are silently ignored — caller sees unscoped view.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
0 commit comments