Browser-based graphical shell and control plane for a Linux server you own — real terminal, file manager, live metrics and BYOK AI in one mobile-first workspace. Next.js 16 · React 19 · node-pty · Tailwind v4 · shadcn/ui. Public alpha, self-hosted.
TypeScript browser-shellcontrol-planefile-managerhomelabmobile-firstnextjsptyreactself-hostedserver-managementshadcn-uisysadmintailwindcssterminaltypescriptvpsweb-desktopweb-terminal
feat(a2a): enable local and inbound defaults
Rahman8838f660fb11
diff --git a/.env.example b/.env.exampleindex fbee4792..97e7eb21 100644--- a/.env.example+++ b/.env.example@@ -213,15 +213,15 @@ OS_SESSION_SECRET=# OS_A2A_CREDENTIAL_STORE=~/.mso/private/a2a-credentials.json # outbound peer API-key/Bearer/OAuth access-token profiles (0600)# OS_A2A_INBOUND_TOKEN_STORE=~/.mso/private/a2a-inbound-tokens.json # inbound bearer hashes only (0600)# OS_A2A_TASK_STORE=~/.mso/private/a2a-tasks.json # bounded explicit inbound A2A task/message state (0600)-# Authenticated inbound A2A is OFF unless both this flag and OS_PUBLIC_ORIGIN are set.-# Enabling publishes /.well-known/agent-card.json and /a2a/v1, but every protocol+# Authenticated inbound A2A is enabled by default when OS_PUBLIC_ORIGIN is set.+# Set OS_A2A_INBOUND_ENABLED=0 as a kill switch. This publishes /.well-known/agent-card.json and /a2a/v1, but every protocol# call still requires an owner-minted scoped bearer from `mso a2a inbound create`.-# OS_A2A_INBOUND_ENABLED=0-# Same-host A2A is a separate opt-in. Default 0 keeps outbound discovery strictly-# public HTTPS. Set 1 only when agents on THIS host need loopback A2A. It permits+# OS_A2A_INBOUND_ENABLED=1+# Same-host A2A is enabled by default. Set OS_A2A_ALLOW_LOOPBACK=0 to disable it.+# It permits# HTTP only for 127.0.0.1, ::1, and localhost; RFC1918/LAN/Docker/link-local and# hostnames resolving to private addresses remain blocked. This flag affects A2A only.-# OS_A2A_ALLOW_LOOPBACK=0+# OS_A2A_ALLOW_LOOPBACK=1# Optional override for the same-host A2A origin. Normally leave unset; MSO derives# loopback from the installed service port and still validates exact-loopback policy.# OS_A2A_LOOPBACK_ORIGIN=http://127.0.0.1:4005diff --git a/docs/A2A.md b/docs/A2A.mdindex 591df62d..11138bad 100644--- a/docs/A2A.md+++ b/docs/A2A.md@@ -55,7 +55,7 @@ Start peers at `read`. Promote to `write` or `exec` only when that remote agent## Enable the inbound server-Inbound requires **both** an explicit flag and an explicit HTTPS public origin:+Public inbound is enabled by default whenever an explicit HTTPS public origin exists. `OS_A2A_INBOUND_ENABLED=0` is the kill switch:```bashOS_A2A_INBOUND_ENABLED=1@@ -88,7 +88,7 @@ The Settings → **A2A** panel exposes the same flow, shows the one-time token o## Same-host local A2A between terminal sessions-Local A2A is independent from public inbound A2A. It is **off by default**. Enable it explicitly on the MSO service:+Local A2A is independent from public inbound A2A and is **enabled by default**. The environment value below documents the default; set it to `0` only when you want to disable same-host A2A:```bashOS_A2A_ALLOW_LOOPBACK=1@@ -96,7 +96,7 @@ OS_A2A_ALLOW_LOOPBACK=1Rebuild/restart the service after changing its environment. This flag changes only A2A discovery/register/message/handoff traffic. It does not relax the generic provider HTTP client or any other MSO HTTP surface.-With the flag enabled, A2A accepts HTTP only when the literal destination is exactly `127.0.0.1`, `[::1]`, or `localhost`. It still rejects RFC1918 ranges, carrier/private ranges, link-local, Docker/LAN addresses, wildcard addresses, `.local`/`.lan` style hosts, and any non-loopback hostname whose DNS resolves to a private/loopback/link-local address. Public destinations continue to use HTTPS plus DNS re-resolution, resolved-IP pinning, and redirect refusal.+By default, A2A accepts HTTP only when the literal destination is exactly `127.0.0.1`, `[::1]`, or `localhost`. It still rejects RFC1918 ranges, carrier/private ranges, link-local, Docker/LAN addresses, wildcard addresses, `.local`/`.lan` style hosts, and any non-loopback hostname whose DNS resolves to a private/loopback/link-local address. Public destinations continue to use HTTPS plus DNS re-resolution, resolved-IP pinning, and redirect refusal.MSO treats each durable terminal AI session as a local A2A target. A session records its current working directory when created/resumed/updated, so another session can resolve it by:diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.mdindex 88dfad58..b0d1afbf 100644--- a/docs/CHANGELOG.md+++ b/docs/CHANGELOG.md@@ -8,6 +8,7 @@ this is the *what*, and it is what Settings → About shows as “What's new”.**Added**+- `a2a` enable local and inbound defaults- ship authenticated and local A2A- `agent` add eval-gated tool forge- `agent` add interactive permissions and a2a v1diff --git a/docs/PROGRESS.md b/docs/PROGRESS.mdindex b99cbcc0..0ab1e23b 100644--- a/docs/PROGRESS.md+++ b/docs/PROGRESS.md@@ -4,12 +4,12 @@ Running log of what shipped each phase. Newest at top.## 2026-09-02 — MSO 1.8.0 authenticated inbound A2A-- **Shipped surface:** A2A v1 outbound credentials/streaming plus an opt-in authenticated inbound Agent Card and JSON-RPC/SSE server, with owner Settings → A2A management for peers, credentials, tasks, and audit activity.+- **Shipped surface:** A2A v1 outbound credentials/streaming plus authenticated inbound Agent Card and JSON-RPC/SSE server, with owner Settings → A2A management for peers, credentials, tasks, and audit activity.- **Authority model:** inbound bearer profiles are owner-minted `read | write | exec` delegated capabilities. Model-visible tools and MCP dispatch both enforce the scope; owner memory/session tool families remain unavailable to inbound callers.- **Isolation:** inbound tasks persist only explicit A2A messages/results, are isolated by credential principal, and use `taskId` as the MSO workflow session boundary so concurrent tasks cannot cross-control one another.- **Credentials:** outbound API-key/Bearer/OAuth access-token profiles live in private `0600` storage and bind to sanitized Agent Card security schemes. Inbound raw bearer tokens are shown once and only their hashes persist. Unsupported query/cookie API keys, non-Bearer HTTP auth, mTLS, and multi-scheme AND requirements fail closed.- **Streaming:** `SendStreamingMessage` and `SubscribeToTask` use SSE; observer disconnect does not cancel execution. `CancelTask` remains the explicit cancellation boundary.-- **Ingress:** `/.well-known/agent-card.json` and `/a2a/v1` are machine-protocol surfaces with no document CSP/nonce or browser-cookie CSRF gate; `/api/v1/a2a` remains owner-cookie + CSRF protected. Inbound serving stays disabled unless `OS_A2A_INBOUND_ENABLED=1` and an explicit HTTPS `OS_PUBLIC_ORIGIN` are both configured.+- **Ingress:** `/.well-known/agent-card.json` and `/a2a/v1` are machine-protocol surfaces with no document CSP/nonce or browser-cookie CSRF gate; `/api/v1/a2a` remains owner-cookie + CSRF protected. Public inbound serving is enabled when an explicit HTTPS `OS_PUBLIC_ORIGIN` is configured; `OS_A2A_INBOUND_ENABLED=0` disables it. Same-host exact-loopback A2A is enabled by default and can be disabled with `OS_A2A_ALLOW_LOOPBACK=0`.- **CLI:** `mso a2a state`, `stream`, `auth ...`, and `inbound ...` added; credential secrets are read interactively and sent through stdin rather than process argv.- **Verification:** targeted A2A/assistant/provider and ingress suites, typecheck, targeted ESLint, generated docs, and architecture/docs checks pass. Full release verification/build follows this entry before deployment.diff --git a/lib/a2a/inbound-config.ts b/lib/a2a/inbound-config.tsindex 9fc43a4a..497cfbf7 100644--- a/lib/a2a/inbound-config.ts+++ b/lib/a2a/inbound-config.ts@@ -41,7 +41,7 @@ export function a2aInboundConfig(): A2AInboundConfig {reason: "demo_mode",};- const publicEnabled = process.env.OS_A2A_INBOUND_ENABLED === "1";+ const publicEnabled = process.env.OS_A2A_INBOUND_ENABLED !== "0";const localEnabled = a2aLoopbackEnabled();if (!publicEnabled && !localEnabled)return {diff --git a/lib/a2a/network.test.ts b/lib/a2a/network.test.tsindex d2ba1279..1ae801f5 100644--- a/lib/a2a/network.test.ts+++ b/lib/a2a/network.test.ts@@ -13,8 +13,15 @@ const resolver =(answers: Array<{ address: string; family: number }>) => async () =>answers;-describe("A2A loopback-only opt in", () => {- it("keeps the default strict and rejects HTTP loopback", () => {+describe("A2A loopback-only default", () => {+ it("allows exact HTTP loopback by default", () => {+ expect(+ assertA2AUrl("http://127.0.0.1:4555/.well-known/agent-card.json").hostname,+ ).toBe("127.0.0.1");+ });++ it("supports an explicit kill switch", () => {+ vi.stubEnv(A2A_ALLOW_LOOPBACK_ENV, "0");expect(() =>assertA2AUrl("http://127.0.0.1:4555/.well-known/agent-card.json"),).toThrow(/loopback HTTP is disabled/);@@ -24,7 +31,7 @@ describe("A2A loopback-only opt in", () => {"http://127.0.0.1:4555/.well-known/agent-card.json","http://[::1]:4555/.well-known/agent-card.json","http://localhost:4555/.well-known/agent-card.json",- ])("accepts exact loopback only when explicitly enabled: %s", async (url) => {+ ])("accepts exact loopback: %s", async (url) => {vi.stubEnv(A2A_ALLOW_LOOPBACK_ENV, "1");expect(assertA2AUrl(url).toString()).toBe(new URL(url).toString());const endpoint = await resolveA2AEndpoint(diff --git a/lib/a2a/network.ts b/lib/a2a/network.tsindex 392d9f8d..4ea90f74 100644--- a/lib/a2a/network.ts+++ b/lib/a2a/network.ts@@ -30,7 +30,7 @@ function cleanHost(url: URL): string {}export function a2aLoopbackEnabled(): boolean {- return process.env[A2A_ALLOW_LOOPBACK_ENV] === "1";+ return process.env[A2A_ALLOW_LOOPBACK_ENV] !== "0";}export function isExactA2ALoopbackHost(host: string): boolean {