Skip to content

[Bug] MCP tools fail with -32603 when JWT_SECRET is set (cross-host MCP) #1906

Description

Environment

  • BrowserOS Version: 0.46.25.0
  • Chromium Version: 148.0.7966.97
  • Architecture: macOS (Intel)
  • OS: macOS 14.5+

Problem

When AGENT_RUNNER_JWT_SECRET is set, the MCP server returns HTTP 500 / JSON-RPC error -32603 Internal Server Error on all tool calls.

Setup (Cross-host MCP)

  • Agent: 192.168.88.61 (GPU server)
  • BrowserOS: 192.168.88.58 (MacBook Pro)
  • CDP port: 9015 (localhost)

Connection:

  1. JWT set via launchctl setenv
  2. SSH tunnel: ssh -L 19015:127.0.0.1:9015 -N -f macbook
  3. MCP connects to port 9007 via Streamable HTTP
  4. CDP via tunnel on 19015

Logs:

{"level":30,"msg":"Connected to CDP on port 9015"}
{"level":50,"msg":"Unhandled Error" at handlePostRequest}

Expected

  • initialize returns 200 with serverInfo
  • tools/list returns 16 tools
  • tools/call returns snapshot

Actual

  • All calls return 500 with -32603 Internal server error

Questions

  1. Is Streamable HTTP correct for cross-host MCP?
  2. Should JWT be set via plist EnvironmentVariables?
  3. Known issues with handlePostRequest?

Full details: /home/pg/pgwiki/browseros_issue.md

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions