Skip to content

docs(agent-server): say what --token does not buy - #927

Merged
ericleepi314 merged 1 commit into
mainfrom
docs/agent-server-plaintext-caveat
Sep 11, 2026
Merged

docs(agent-server): say what --token does not buy#927
ericleepi314 merged 1 commit into
mainfrom
docs/agent-server-plaintext-caveat

Conversation

@ericleepi314

Copy link
Copy Markdown
Collaborator

#924 made --token mandatory off loopback and explained why it is required. It
never said what the token stops short of, which leaves the paragraph reading as
"bind wide, pass a token, you're fine."

Both listeners are plaintext. The bearer token rides an Authorization
header over http://, and POST /sessions replies with a ws:// URL carrying
the per-session token as a query parameter:

ws_url = f'ws://{host}:{ws_port}/ws/{info.id}?token={token}'

There is no TLS anywhere in that server. So --token answers who may
connect
, not who may watch — anyone positioned to read the traffic, rather
than merely to reach the port, can lift either token and create sessions
afterwards.

That makes a remote bind defensible on a trusted network or behind a TLS
terminator, and not defensible on its own over the internet. The docs now say
so.

Deliberately unchanged: the refusal message and the --token help text.
Both were already accurate — they state what is wrong without a token and
claim nothing about what having one achieves. Only the prose someone plans a
deployment from needed the caveat.

Raised in review of #924, and verified against the code rather than taken on
report — grep for ssl/TLS in src/server/server.py returns nothing, and the
ws_url line is quoted above. This is the same failure shape as the #920
correction: a true fact (--token gates POST /sessions) carrying an
inference I had not checked (that it therefore makes the bind safe).

Docs only.

🤖 Generated with Claude Code

https://claude.ai/code/session_01WAB22BuCSRhjbpR3a8kc5v

#924 made `--token` mandatory off loopback and explained why. It did not say
what the token stops short of, which leaves the paragraph reading as "bind
wide, pass a token, you are fine."

Both listeners are plaintext. The bearer token travels in an `Authorization`
header over `http://`, and `POST /sessions` answers with a `ws://` URL
carrying the per-session token as a query parameter (`server.py`, `ws_url`);
there is no TLS anywhere in that server. So the token distinguishes who may
connect, not who may watch — anyone able to read the traffic can lift it and
create sessions afterwards.

That makes a remote bind defensible on a trusted network or behind a TLS
terminator, and not defensible on its own over the internet. The refusal
message and `--help` text were already accurate — they say what is wrong
without a token and claim nothing about what having one achieves — so only
the prose that a reader plans a deployment from needed the clause.

Raised in review of #924 and verified against the code rather than taken on
report: the same shape as the #920 correction, where I let a true fact carry
an inference I had not checked.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WAB22BuCSRhjbpR3a8kc5v
@github-actions

Copy link
Copy Markdown

Test Results

     5 files   1 009 suites   30m 10s ⏱️
15 749 tests 15 723 ✅ 22 💤 4 ❌
31 604 runs  31 534 ✅ 66 💤 4 ❌

For more details on these failures, see this check.

Results for commit fd2f5ec.

@ericleepi314
ericleepi314 merged commit 954dc87 into main Sep 11, 2026
6 of 8 checks passed
@ericleepi314
ericleepi314 deleted the docs/agent-server-plaintext-caveat branch September 11, 2026 22:45
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