[Brev][Onboard] post-onboarding secure link behaves differently per agent - Hermes returns HTTP 400 Invalid Host header, OpenClaw is blocked by a gateway token prompt, Deep Agents works
Description
Every NemoClaw Brev launchable exposes a per-instance secure link — referred to below as {secure-link}, whose host is {secure-link-host} — protected by Pomerium plus NVIDIA SSO.
Before onboarding the behaviour is consistent and correct across all three agents: the link redirects to /onboard and the onboarding wizard loads.
After onboarding completes, the same link produces three different outcomes depending on which agent was onboarded, and two of the three leave the user with no way to reach their agent from the browser:
| Agent | Post-onboarding result |
|---|---|
| OpenClaw | The link serves the agent dashboard, which then demands a gateway token/password that cannot be obtained in the browser. |
| Hermes | The link returns HTTP 400 with {"detail":"Invalid Host header. Dashboard requests must use the hostname the server was bound to."} |
| Deep Agents | The link serves /dashboard normally after SSO. This is the expected behaviour. |
Two contributing defects in the launchable's nginx configuration are described under Analysis: the routes /health and /v1/ are hard-proxied to a Hermes-only port (8642) and return 502 on the other two agents, and the reverse proxy forwards the external Host header to agent dashboards that validate it.
- Platform scope: Reproduced on Brev launchable (Ubuntu 22.04) only; other platforms not tested
- Regression: Unknown — earlier versions not tested
Environment
Device: Brev launchable instances (n2d-standard-4, CPU-only, no GPU) x3
OS: Ubuntu 22.04.5 LTS (Linux 6.8.0-1064-gcp)
Architecture: x86_64
Node.js: v22.23.2
npm: 10.9.8
Docker: Docker version 29.1.3, build 29.1.3-0ubuntu3~22.04.2
OpenShell CLI: openshell 0.0.85
NemoClaw: nemoclaw v0.0.97
OpenClaw: OpenClaw 2026.7.1 (2d2ddc4); Hermes Agent v0.18.0;
LangChain Deep Agents Code v0.1.34
Steps to Reproduce
-
Deploy three Brev instances from the NemoClaw launchable.
-
On each, onboard a different agent through the onboarding web UI: OpenClaw, Hermes Agent, and LangChain Deep Agents Code.
-
Before onboarding, open each instance's secure link
{secure-link}and complete NVIDIA SSO. Confirm all three redirect to/onboard(consistent, correct). -
After onboarding completes on each instance, open the secure link again and complete SSO:
- OpenClaw —
{secure-link}/chat?session=agent%3Amain%3Amain - Hermes —
{secure-link}/ - Deep Agents —
{secure-link}/dashboard
- OpenClaw —
-
On each host, reproduce without SSO by sending the external hostname as the
Hostheader to the local reverse proxy:curl -i -H "Host: {secure-link-host}" http://127.0.0.1/ -
On each host, also request the shared routes:
curl -o /dev/null -w "%{http_code}\n" http://127.0.0.1/health curl -o /dev/null -w "%{http_code}\n" http://127.0.0.1/v1/models
Expected Result
After onboarding, the secure link lands the authenticated user on their agent's usable interface, consistently for every agent — the same way it consistently lands on /onboard before onboarding. Having already passed Pomerium and NVIDIA SSO, the user should not be stopped by a second credential prompt that the browser cannot satisfy, and should not receive a raw HTTP 400 or 502.
Shared routes exposed by the reverse proxy (/health, /v1/) should either work for every agent or not be routed at all for agents that do not implement them.
Actual Result
Post-onboarding, the same URL shape yields three different results.
1) Hermes — HTTP 400, hard failure. Reproduced on two separate Hermes instances:
$ curl -i -H "Host: {secure-link-host}" http://127.0.0.1/
HTTP/1.1 400 Bad Request
content-type: application/json
{"detail":"Invalid Host header. Dashboard requests must use the hostname the server was bound to."}
2) OpenClaw — HTTP 200, but the page is a token wall:
$ curl -H "Host: {secure-link-host}" "http://127.0.0.1/chat?session=agent%3Amain%3Amain"
200 text/html 14406 bytes <title>OpenClaw Control</title> (page renders a "Connect" token/password prompt)
The response is byte-identical to the response for / (14406 bytes), because the dashboard is a client-side-routed SPA: no path or query string changes what the server returns, so no deep link can bypass the prompt.
3) Deep Agents — HTTP 200, /dashboard renders. Correct behaviour.
Shared routes, measured on each host over the loopback proxy:
route OpenClaw Hermes Deep Agents
/ 200 400 200
/onboard 200 200 200
/dashboard 200 200 200
/health 502 200 502
/v1/models 502 401 502
Port check per host:
8642 listening -> OpenClaw NO, Hermes YES, Deep Agents NO
18789 listening -> OpenClaw YES, Hermes YES, Deep Agents NO
Analysis
The nginx configuration baked into the launchable image is byte-identical on all three instances, but the backends it targets exist only for some agents.
A) /health and /v1/ are hard-proxied to port 8642, which only Hermes runs.
location = /v1 { proxy_pass http://127.0.0.1:8642/v1; ... }
location /v1/ { proxy_pass http://127.0.0.1:8642; ... }
location = /health { proxy_pass http://127.0.0.1:8642/health; ... }
Nothing listens on 8642 on the OpenClaw and Deep Agents hosts, so both routes return a raw 502. The configuration contains exactly one error_page 502 fallback and it is inside location /, commented "If OpenClaw (port 18789) is running, serve it at /. If it returns 502/503/504, fall back to our Next.js app." The /health and /v1/ blocks have no such fallback. /health is the conventional endpoint an uptime monitor or load balancer polls, so a healthy OpenClaw or Deep Agents instance is reported as down.
B) The root proxy forwards the external Host header to the agent dashboard.
location / { proxy_pass http://127.0.0.1:18789; proxy_set_header Host $host; ... }
$host is the Brev hostname. The Hermes dashboard validates the Host header against the interface it bound to (loopback) and rejects anything else with HTTP 400 Invalid Host header. Requests to the same dashboard with Host: 127.0.0.1 return 200, which is why the failure only appears through the secure link and not in local testing.
C) OpenClaw's dashboard token can only travel in a URL fragment.
getDashboardUrl() in onboard-ui/lib/services/openclaw.ts builds the dashboard URL as `${base}#token=${token}`. A URL fragment is never sent to the server, so neither Pomerium nor nginx can supply it. Only the onboarding UI's own in-page link carries the token; a user who opens the secure link directly, or who is handed the link, has no browser-reachable way to obtain it and must SSH to the host and run nemoclaw {sandbox} gateway-token.
D) Deep Agents works by accident of the fallback: it is a terminal-runtime agent with no dashboard on 18789 at all, so location / hits the error_page 502 fallback and serves the Next.js app, which does not validate the Host header.
Suggested fix: generate the reverse-proxy configuration per agent rather than shipping one template for all of them — only route /health and /v1/ for agents that serve them, and extend the 502 fallback to any route that is conditionally backed. Additionally, agent dashboards reached through the secure link need the external hostname in their allowed-Host list, and the post-onboarding landing target needs to be an entry point that works after SSO for every agent.
Related Bugs / not duplicate of
Issues #8101, #8105 and #8109 concern the onboarding UI misreporting a successful sandbox build as an error. This report is unrelated to that: it concerns what the per-instance secure link serves after onboarding has completed successfully.
Logs
Reverse proxy responses with the external hostname supplied as the Host header, collected on each host over loopback (three separate instances):
Hermes instance A:
code=400 ctype=application/json size=99
{"detail":"Invalid Host header. Dashboard requests must use the hostname the server was bound to."}
Hermes instance B:
code=400 ctype=application/json size=99
{"detail":"Invalid Host header. Dashboard requests must use the hostname the server was bound to."}
OpenClaw instance, path /chat?session=agent%3Amain%3Amain:
code=200 ctype=text/html size=14406
<!doctype html>
<html data-openclaw-terminal-enabled="false" lang="en">
Deep Agents instance, path /dashboard:
code=200 ctype=text/html size=14710
<!DOCTYPE html><html lang="en" ...>
Will go out in the next LKG, likely v0.0.103 via a fix in the brev launchable.