Skip to content

armgit / mso

Public Imported from GitHub
0

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.

fix: harden audited execution, integrations and release journeys

Rahman4c033c2e37e1
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 554f34fb..4dd5dd41 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -6,6 +6,8 @@ on:
pull_request:
branches: [main]
workflow_dispatch:
+ schedule:
+ - cron: "17 3 * * *"
permissions:
contents: read
@@ -17,6 +19,7 @@ concurrency:
jobs:
verify:
name: Verify
+ if: github.event_name != 'schedule'
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
@@ -26,7 +29,7 @@ jobs:
- name: Setup bun
uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2
with:
- bun-version: 1.3.14
+ bun-version: 1.4.2
- name: Setup Node
uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020 # v7.0.0
@@ -68,3 +71,25 @@ jobs:
- name: Production build
run: bun run build
+
+ - name: Install browser
+ run: node_modules/.bin/playwright install --with-deps chromium
+
+ - name: Required browser journeys
+ run: bun run e2e:release
+
+ dependency-watch:
+ name: Scheduled dependency audit
+ if: github.event_name == 'schedule'
+ runs-on: ubuntu-latest
+ timeout-minutes: 10
+ steps:
+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
+ - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6
+ with:
+ bun-version: 1.4.2
+ - uses: actions/setup-node@820762786026740c76f36085b0efc47a31fe5020
+ with:
+ node-version: 22
+ - run: bun install --frozen-lockfile
+ - run: bun run audit:strict
diff --git a/app/login/page.tsx b/app/login/page.tsx
new file mode 100644
index 00000000..56de67e9
--- /dev/null
+++ b/app/login/page.tsx
@@ -0,0 +1,14 @@
+import { redirect } from "next/navigation";
+import { ServerLoginPage } from "@/features/auth";
+import { getSessionContext } from "@/lib/auth/require-session";
+import { safeReturnPath } from "@/lib/auth/return-path";
+import { IS_DEMO } from "@/lib/demo";
+
+export default async function LoginPage({ searchParams }: {
+ searchParams: Promise<{ returnTo?: string | string[] }>;
+}) {
+ if (IS_DEMO) redirect("/");
+ const returnTo = safeReturnPath((await searchParams).returnTo);
+ if (await getSessionContext()) redirect(returnTo);
+ return <ServerLoginPage returnTo={returnTo} />;
+}
diff --git a/bun.lock b/bun.lock
index 8c9ed4ed..deea0fd4 100644
--- a/bun.lock
+++ b/bun.lock
@@ -25,7 +25,7 @@
"geist": "^1.7.2",
"konva": "^10.3.1",
"lucide-react": "^1.33.0",
- "next": "^16.3.2",
+ "next": "^16.3.3",
"node-pty": "^1.1.0",
"react": "^19.2.7",
"react-dom": "^19.2.7",
@@ -37,16 +37,19 @@
"yaml": "^2.9.0",
},
"devDependencies": {
+ "@axe-core/playwright": "^4.13.0",
+ "@playwright/test": "^1.58.2",
"@tailwindcss/postcss": "^4.3.0",
"@types/node": "^22.19.20",
"@types/react": "^19.2.17",
"@types/react-dom": "^19.2.5",
"@vitest/coverage-v8": "^4.1.11",
"eslint": "^9.39.4",
- "eslint-config-next": "^16.3.2",
+ "eslint-config-next": "^16.3.3",
"fast-check": "^4.9.0",
"parse5": "8.0.1",
"postcss": "^8.5.26",
+ "simple-icons": "^16.30.0",
"tailwindcss": "^4.3.0",
"typescript": "^5.9.3",
"vitest": "^4.1.11",
@@ -57,15 +60,18 @@
"node-pty",
],
"overrides": {
+ "js-yaml": "^4.3.2",
"nanoid": "^3.3.18",
"postcss": "^8.5.10",
- "sharp": "^0.35.3",
+ "sharp": "^0.35.4",
},
"packages": {
"@alloc/quick-lru": ["@alloc/[email protected]", "", {}, "sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw=="],
"@anthropic-ai/sdk": ["@anthropic-ai/[email protected]", "", { "dependencies": { "json-schema-to-ts": "^3.1.1", "standardwebhooks": "^1.0.0" }, "peerDependencies": { "zod": "^3.25.0 || ^4.0.0" }, "optionalPeers": ["zod"], "bin": { "anthropic-ai-sdk": "bin/cli" } }, "sha512-ZlvmNFT/iIF6JD13rxbbMWD8nvGR0RaUp6yMQnoc+4Af0YjVVe/bIdW1XSQQsoxXAtg1NaT6Vak0LKFlJ4d37Q=="],
+ "@axe-core/playwright": ["@axe-core/[email protected]", "", { "dependencies": { "axe-core": "~4.13.0" }, "peerDependencies": { "playwright-core": ">= 1.0.0" } }, "sha512-6YLx+kxXu5GJceG4ozFg+33a2EMTdjYwWGloJ3sb9Kta5pp+ZNS53uxGVog5JetIY8s++P5UrtX+cri+u0VAVg=="],
+
"@babel/code-frame": ["@babel/[email protected]", "", { "dependencies": { "@babel/helper-validator-identifier": "^7.29.7", "js-tokens": "^4.0.0", "picocolors": "^1.1.1" } }, "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw=="],
"@babel/compat-data": ["@babel/[email protected]", "", {}, "sha512-locTkQyKvwIEgBzVrn8693ebc97F2U8ZHjbXwDXJ5Fn2TCpNwTlKcaKLkdHop5c/icOFE7qt7Q9JC5hnKNa6Gg=="],
@@ -146,57 +152,57 @@
"@img/colour": ["@img/[email protected]", "", {}, "sha512-Td76q7j57o/tLVdgS746cYARfSyxk8iEfRxewL9h4OMzYhbW4TAcppl0mT4eyqXddh6L/jwoM75mo7ixa/pCeQ=="],
- "@img/sharp-darwin-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-darwin-arm64": "1.3.2" }, "os": "darwin", "cpu": "arm64" }, "sha512-RMnFX7YQsMoh7lWfcM4NEHHymBX/rLuKNPVM84XE9ONPcaSCDgE7CHIHpSgPcO2xcRthgBy1HfNO319mwhIAkg=="],
+ "@img/sharp-darwin-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-darwin-arm64": "1.3.3" }, "os": "darwin", "cpu": "arm64" }, "sha512-Uhfl4V4lhP2nbUVF9+hyH1+luj86f1gUFeo8ALYxFoULoU+G87D43BfeMP8XHsk9boxAnCY/bf2EHwhA7MuGsA=="],
- "@img/sharp-darwin-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-darwin-x64": "1.3.2" }, "os": "darwin", "cpu": "x64" }, "sha512-Xo+5uFBtLN0BKqieTxiFzFPQAUlBbbH5iBKyRX/z1JrbnYsHTfKJnUfL8+p2TPXr1pXqao4eeL4Rl144uDpK9w=="],
+ "@img/sharp-darwin-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-darwin-x64": "1.3.3" }, "os": "darwin", "cpu": "x64" }, "sha512-hWniXY3bG5qKpkKrAwPe4y+VTPmf086YQAnkxWh7uA1YrlRouWGa0M0Mxj3ZjnXFkv7/TD1bTy9lGUK26vRvWw=="],
- "@img/sharp-freebsd-wasm32": ["@img/[email protected]", "", { "dependencies": { "@img/sharp-wasm32": "0.35.3" }, "os": "freebsd" }, "sha512-lUxcqWIj2wMQ9BrwNjngcr1gWUr5xgaGThBRqPPalIC2n67Cqj1uPh8NnA/ZhAg8hUbKl+kVHKwgUIwe6ZYPrg=="],
+ "@img/sharp-freebsd-wasm32": ["@img/[email protected]", "", { "dependencies": { "@img/sharp-wasm32": "0.35.4" }, "os": "freebsd" }, "sha512-lIsKw/BU+kjB4eZjxrYrZmwOJYi3Ajrv66iAlBmUPyKc3HpnloevB1g3wxGD9P/5BbQ1brBGl65VRRrCvQDEqA=="],
- "@img/sharp-libvips-darwin-arm64": ["@img/[email protected]", "", { "os": "darwin", "cpu": "arm64" }, "sha512-9J6ypZFpQBj4YnePGoq/S38w6nz+vqg5WZLrLGY4YuSemdMq47GMLBPO42MzwdGwpg/agZ7xzZcFHa48xlywfg=="],
+ "@img/sharp-libvips-darwin-arm64": ["@img/[email protected]", "", { "os": "darwin", "cpu": "arm64" }, "sha512-suTBPTDGrI9WodccaDdwZItTSaBYASlBk1NSfElSHrUfzu3szG6lvIF58+WiFvnfzuK8ZBFS5zE00PxqxnRiPg=="],
- "@img/sharp-libvips-darwin-x64": ["@img/[email protected]", "", { "os": "darwin", "cpu": "x64" }, "sha512-m2pW1n6cns9VaubNwsZ+c3CRYjxNQWgJ5gPlnL1nbBcpkBvFm6SCFN5o0psFHI8w9n11NKhFkeEDns98tiqbEw=="],
+ "@img/sharp-libvips-darwin-x64": ["@img/[email protected]", "", { "os": "darwin", "cpu": "x64" }, "sha512-FVJZ5mITMobmXIz/hPDTw0EintTW5H3WfrxwLqEqjiIihlu+hVRyGrFQ60xl0Lxn7Bt3zdpevPaQi0HEzqz9fw=="],
- "@img/sharp-libvips-linux-arm": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm" }, "sha512-1eMLzy92I4J6rmi4mAT8yC3HxOtniyGELlzGbNMLLeqe052ahFQ0h6LFq+lh5DsDIdYViIDst08abvSbcEdLXQ=="],
+ "@img/sharp-libvips-linux-arm": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm" }, "sha512-3rbU4vqXXc3hY/OiXdl52xZvT0F1yEngWfvqudtPJg/KkyiaQw2DRsFrNzpmLvfavbwOq3qXn36GP8obHRULQA=="],
- "@img/sharp-libvips-linux-arm64": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-dqVSFynCox4C/J8kT16V7SIFAns0IjgLwkvYT7p8LQVmJ5OS5b6tI9IGflxTeuBS//zXeFIUbwt5dwxyZ17cnA=="],
+ "@img/sharp-libvips-linux-arm64": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-0DaL0A6Xu6sQSQFwe4iVCrKWU2cCTItnRsYsCdxAMm9NF6twAA9BKnoqy4hqz4+azQ0JHuA26qiUKsf1XJ/v5A=="],
- "@img/sharp-libvips-linux-ppc64": ["@img/[email protected]", "", { "os": "linux", "cpu": "ppc64" }, "sha512-3z0NHDxD6n5I9gc05U1eW1AyRm+Gznzq3naMrthPNqE6oYykcogW0l/jfpJdjYnuNl8R7yI9pNbE1XiUeyq0Aw=="],
+ "@img/sharp-libvips-linux-ppc64": ["@img/[email protected]", "", { "os": "linux", "cpu": "ppc64" }, "sha512-cdn1OvUBwsXhbC0zSzJnNzf5MZ/mTrobawDvNXBTxe8VtqKAm0sRuEY2Evzovb/w9JMk4TvRxqt1mekSuJz64w=="],
- "@img/sharp-libvips-linux-riscv64": ["@img/[email protected]", "", { "os": "linux", "cpu": "none" }, "sha512-bsb4rI+NldGOsXuej2r8OdSS8+zXDVaCWxyWrcv6kneTOlgAHtZABRzBBCwdsPiD90J4myNJuHpg6kA20ImW/w=="],
+ "@img/sharp-libvips-linux-riscv64": ["@img/[email protected]", "", { "os": "linux", "cpu": "none" }, "sha512-HjPVx7yKz+0lqdhDlTw1tt90wamBoxhiXpvl1XZpJLiHH4RCJ5yDTqH+VlYPv2fwFs89JFw4c1IexYOcQUi4IQ=="],
- "@img/sharp-libvips-linux-s390x": ["@img/[email protected]", "", { "os": "linux", "cpu": "s390x" }, "sha512-/ABshyj8gCpyIrNXnHn4LorDJ0HHm1VhXPBlxZ8zAtfVPAaSafXPGn+sUSIRiwaSBy0mmFjSjiXI5mkcwdChKQ=="],
+ "@img/sharp-libvips-linux-s390x": ["@img/[email protected]", "", { "os": "linux", "cpu": "s390x" }, "sha512-neWLh+3yCNThxnfy3c4BbVBeGgt9aftno+XbT56iK28RgeDs3UOFWviLWlUu0bArYVYJaFDK+RRohbicUNCm8Q=="],
- "@img/sharp-libvips-linux-x64": ["@img/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-ITPEtgffGJ0S6G9dRyw/366tJQqFRcHWPHhC+Stpg3Z8AEMrDrTr2lhdz4f/Y/HMbRh//7Z5mBzEpVdi62Oc3w=="],
+ "@img/sharp-libvips-linux-x64": ["@img/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-4vKmvAst9nrowcqquKFAyZJUDolUaIp8uRiN0mWFguJ1IplC9/pitXtlnnlU4aa/eJw3J7i67V+pwUL+wZGdsA=="],
- "@img/sharp-libvips-linuxmusl-arm64": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-zE9EdiUzUmg5mDT5a1rk5fYJ6GWPloTwWBYDS14naqHsL+EaMpDj1AWnpLgh3u0YCORv2Tt50wrcrpYqkP97Kw=="],
+ "@img/sharp-libvips-linuxmusl-arm64": ["@img/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-Y9kQaLMuNoB0bPYOOdcZMaseNrFpPodIWWMrx+CZyydf2xn68j9WYc6sWWRrDwNkzCQjKYfc68L7jKjGlHMibw=="],
- "@img/sharp-libvips-linuxmusl-x64": ["@img/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-m0lrLiUt+lBYnCFr8qV/65yMR4E/c7/wf78I5eKTdkEakFAlZ9QlzEM3QIhhAwVeUhLAHLcCq7a7Vszq/oFNZQ=="],
+ "@img/sharp-libvips-linuxmusl-x64": ["@img/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-fj8Mv0HHfD1Rr+4I68+3agJynxDWtBFgicTbSOb9Bke6pIwzGcJ+RX/yHjmiEGFMCavY/dxvem7MyNaJF+wDiw=="],
- "@img/sharp-linux-arm": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-arm": "1.3.2" }, "os": "linux", "cpu": "arm" }, "sha512-affVWCTLooy8TSxbDx2qkzuDeaWLNVBA+P//FNBirHsXpP2fuBhk5AuboYUnrDnzoXes8GFjpTx0SBFOCRg+FA=="],
+ "@img/sharp-linux-arm": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-arm": "1.3.3" }, "os": "linux", "cpu": "arm" }, "sha512-7OAS8gI0EReKGVN2HssHlM6umJgxF5VI3xN0p9FA91p/YO+ou5hiNghLdZ5BEHztwaaK5+bLKRf8x/o2L2nk9A=="],
- "@img/sharp-linux-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-arm64": "1.3.2" }, "os": "linux", "cpu": "arm64" }, "sha512-QgKDspHPnrU+GQ55XPhGwyhC8acLVOOSyAvo1oVfFmrIXLkDNmGWzAfDZ4xK8oSA1qBQrALcHX0G5UZni/SuFQ=="],
+ "@img/sharp-linux-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-arm64": "1.3.3" }, "os": "linux", "cpu": "arm64" }, "sha512-De4jpEnAU8Hd5oT0j1G3uL4ZvTuipVMn7YC6vPaJhy6/7EwEae0SVAoBrUMYQbkLGDm85taVWwuPc1a44LTzCQ=="],
- "@img/sharp-linux-ppc64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-ppc64": "1.3.2" }, "os": "linux", "cpu": "ppc64" }, "sha512-sMd8rDxmpLOwv/7N44klFjOD5DUO7FLdjiXDI0hoxYaf7Ar262dQIEkosE98bps+5HPLtp/EvNqeqQtOycP/IA=="],
+ "@img/sharp-linux-ppc64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-ppc64": "1.3.3" }, "os": "linux", "cpu": "ppc64" }, "sha512-2oYZJeIl4kCcMGk4ouZVjnkCtFrpQFlNEtJ6GbxzhHQchwH0NH/qEb9ykmOl29dqwMq+JhFdZn+1ak2FKhI9fQ=="],
- "@img/sharp-linux-riscv64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-riscv64": "1.3.2" }, "os": "linux", "cpu": "none" }, "sha512-0Eob78yjlYPfL5vMNWAW55l3R9Y6BQS/gOfe0ZcP9mEz9ohhKSt4im1hayiknXgf8AWrFqMvJcKIdmLmEe7yeQ=="],
+ "@img/sharp-linux-riscv64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-riscv64": "1.3.3" }, "os": "linux", "cpu": "none" }, "sha512-cPbNChoRURAWdebDIHSenxRpgEdy7JkPydSnUxRm9VvKD7m0/xVaR/8Fzlu81pk5nHEvHH87UZUA7cTtwnbJSA=="],
- "@img/sharp-linux-s390x": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-s390x": "1.3.2" }, "os": "linux", "cpu": "s390x" }, "sha512-KgAxQ0DxpNOq1rG2t5cgTgShJFGSuU7XO45cqC+1NVOuZnP6tlgZRuSYOfNupGkHID0o3cJOsw4DVeJpMovcGw=="],
+ "@img/sharp-linux-s390x": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-s390x": "1.3.3" }, "os": "linux", "cpu": "s390x" }, "sha512-RY0JFY8Fd6RonCBtHz+DvadaPkXDSI1AUn6yWL9TipqkZ1vY8w8evqdgyDFnkm4/K1ve1TvZiaePP5oSd4+WVQ=="],
- "@img/sharp-linux-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-x64": "1.3.2" }, "os": "linux", "cpu": "x64" }, "sha512-8pqvxubL2PGdhlPy6GLqzDYMUjyRmKAwKHYKixpdJYBUK7PJ0C029XdsnpFIdgRZG68fZiGdHVWcKPvtiPB4cA=="],
+ "@img/sharp-linux-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linux-x64": "1.3.3" }, "os": "linux", "cpu": "x64" }, "sha512-9qvvEAuk8k89TfWUoX2htWjbAMX8p+NxCppjpcg5k6xMsjhBQPTsoIh36h9Qde4WRuGpJeYnOjdosDn/cnv+OA=="],
- "@img/sharp-linuxmusl-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linuxmusl-arm64": "1.3.2" }, "os": "linux", "cpu": "arm64" }, "sha512-Vz0iQjzzcSX3HCbfwFfCSG/9SCIqyO0mH2sXyiHaAYfBk0cRsCWXRyQYX0ovCK/PAQBbTzQ0dsPQHh5MAFL59w=="],
+ "@img/sharp-linuxmusl-arm64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linuxmusl-arm64": "1.3.3" }, "os": "linux", "cpu": "arm64" }, "sha512-KB5jxpfWQTr0nc3xdHtWChdbifHrBGsd2SM62Eyxrl8afikm+f5qGBU75SJIZBT/S1MC8XyacdlXBMSWq6OURA=="],
- "@img/sharp-linuxmusl-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linuxmusl-x64": "1.3.2" }, "os": "linux", "cpu": "x64" }, "sha512-6O1NPKcDVj9QEdg7Hx549EX8U0rp6yXQERqru6yRN7fGBn32UvIRJUlWnk+8xDCiG76hXVBbX82NZ/ZKr0euIg=="],
+ "@img/sharp-linuxmusl-x64": ["@img/[email protected]", "", { "optionalDependencies": { "@img/sharp-libvips-linuxmusl-x64": "1.3.3" }, "os": "linux", "cpu": "x64" }, "sha512-f+eZJZIQNEEd26RPSW+76chwOf1XtA2Y/O+5ocVyLliHkeih3e+jhLVBdNTd2rS3IbNXK8+ug93Vf5ZXtF5Lxg=="],
- "@img/sharp-wasm32": ["@img/[email protected]", "", { "dependencies": { "@emnapi/runtime": "^1.11.1" } }, "sha512-cZ0XkcYGpHZkqW6iCkqTcmUC0CD9DhD5d/qeZlZkfRBn6GnHniZXLUo5+9xw8Iv76YE6LQFN9YNBlKREcCG76w=="],
+ "@img/sharp-wasm32": ["@img/[email protected]", "", { "dependencies": { "@emnapi/runtime": "^1.11.3" } }, "sha512-zQnl4Kwp7Q6NHsENtU2T/00Zi+w3AQNwz3+UaTyVBy2FpXrzXzGjndpK61onhZjRtRpQXxCTeqw19bVyXOh7jA=="],
- "@img/sharp-webcontainers-wasm32": ["@img/[email protected]", "", { "dependencies": { "@img/sharp-wasm32": "0.35.3" }, "cpu": "none" }, "sha512-2rnq7bX3NzeR2T4YWgz8qiG4h3TSdMe+vN1iQXpJleSJ3SM5zQ8Fy2SyyXAWlbxpEZ2Y+Z4u1BePgJEYbSy80Q=="],
+ "@img/sharp-webcontainers-wasm32": ["@img/[email protected]", "", { "dependencies": { "@img/sharp-wasm32": "0.35.4" }, "cpu": "none" }, "sha512-ESfNkywmCfPNyaZjxooddJQiQ+l/nTpGEOGthxiLnIHXC/CmcBixnfwUleX9mCz9ovrUUvKMap/pm8RYbzfwaA=="],
- "@img/sharp-win32-arm64": ["@img/[email protected]", "", { "os": "win32", "cpu": "arm64" }, "sha512-4bPwFdMbeC4JQ8L8LOyWp6nsHcboP5fxkp6iPOXz2Vg49R42TuMs2whkJ5OAP4/Ul035qOzy0AecOF9VOscn4w=="],
+ "@img/sharp-win32-arm64": ["@img/[email protected]", "", { "os": "win32", "cpu": "arm64" }, "sha512-iNdlBX9gLVvqe2I3uIJSIKTq6wckP/DYxZtcqxm09x5Gi24DnFBmPAWZmr60ZyYMG0xlzo6goG3670ar+RXvRw=="],
- "@img/sharp-win32-ia32": ["@img/[email protected]", "", { "os": "win32", "cpu": "ia32" }, "sha512-r53mXsBN6lFUDiST764SvgwUdHAqM4rPAiDzAmf4fLoB6X/rkfyTrLCg6+g17wJJiCmB3JYgHuUldCWUIRFSXw=="],
+ "@img/sharp-win32-ia32": ["@img/[email protected]", "", { "os": "win32", "cpu": "ia32" }, "sha512-kqRsbaa5CS6KHlpxnN7WhE6vAAugXyZButpRdvDWetlv6Qv4N9WTcrWzF7tXfB9T7MsoadqdI8hmwLq6UlLvtw=="],
- "@img/sharp-win32-x64": ["@img/[email protected]", "", { "os": "win32", "cpu": "x64" }, "sha512-D4y1vNeZrIIJCN+uHaWVtH86B+aCrdMYYjicy9pXHvbGZeGYLLSd3wdVuC37FxVXlU1ARsk84eKWfWMXGYEqvA=="],
+ "@img/sharp-win32-x64": ["@img/[email protected]", "", { "os": "win32", "cpu": "x64" }, "sha512-XtmnYhBcrORsJ4XJngyzr/EWP0hRZLAZRFaApdKuviyqF78+ylxh2y06ZmtULAMOnObJ3ucpN0AcwSWnMowTRg=="],
"@imgly/background-removal": ["@imgly/[email protected]", "", { "dependencies": { "lodash-es": "^4.17.21", "ndarray": "~1.0.0", "zod": "^3.23.8" }, "peerDependencies": { "onnxruntime-web": "1.21.0" } }, "sha512-/1ZryrMYg2ckIvJKoTu5Np50JfYMVffDMlVmppw/BdbN3pBTN7e6stI5/7E/LVh9DDzz6J588s7sWqul3fy5wA=="],
@@ -212,25 +218,25 @@
"@napi-rs/wasm-runtime": ["@napi-rs/[email protected]", "", { "dependencies": { "@tybys/wasm-util": "^0.10.3" }, "peerDependencies": { "@emnapi/core": "^1.7.1 || ^2.0.0-alpha.3", "@emnapi/runtime": "^1.7.1 || ^2.0.0-alpha.3" } }, "sha512-JfB4kuJQjaoHuCTseIINHtHWeJnvgEcxjwA5t/Y00ZgaOO1Crz3fjT/p8kT28zA/Caz7oiUMn3d6H2yOVCVwuw=="],
- "@next/env": ["@next/[email protected]", "", {}, "sha512-8k4YoG8cM7LWlkfzGNYCRBbFNlernLiMw4s0btVl+CmmWqn3VpYypA72/5Feb1UWdxe6tHqr5KHP4p4Y4m9luA=="],
+ "@next/env": ["@next/[email protected]", "", {}, "sha512-cjWZnUUa6jZq2kFaNe/ZyJdZonOZ/QoN0Zka2nz/FLOrfx14pQuM9c5RaSVkWMqgdt4ksgPAMWPyHSs/CyV48Q=="],
- "@next/eslint-plugin-next": ["@next/[email protected]", "", { "dependencies": { "@eslint-community/eslint-utils": "4.9.1", "fast-glob": "3.3.1" } }, "sha512-z+HW1cZgt8QhByw8p2EbxF94AImgsKIYUbtSkA7Zld2T9yrKAlys4jNOcAOCtv6csX2CoA/5qCVyesL5pHmJ0A=="],
+ "@next/eslint-plugin-next": ["@next/[email protected]", "", { "dependencies": { "@eslint-community/eslint-utils": "4.9.1", "fast-glob": "3.3.1" } }, "sha512-szW9y2Aumu4z88YXfTzcFsgUAg2k64uzbtcO5L9f1AKS4w/GUKJcbFllRflROVyNPgJtGOnvNxiyp3v6b+prIA=="],
- "@next/swc-darwin-arm64": ["@next/[email protected]", "", { "os": "darwin", "cpu": "arm64" }, "sha512-ib5Llm93YCKoKWDh6ZaHq6QWTuOZ2bRkSnUwMmX8dsRIOkBNL1vVlSiUKSfixPL9SSh9pvukzqajk/klkn5vqg=="],
+ "@next/swc-darwin-arm64": ["@next/[email protected]", "", { "os": "darwin", "cpu": "arm64" }, "sha512-iBr3I5LZNk5/bgl5//iTgD2tcym14MX0Xo7fD//u9dYAEgGzza1y9oywluPtf74YnOswVdH1908aK9xVz7zQTw=="],
- "@next/swc-darwin-x64": ["@next/[email protected]", "", { "os": "darwin", "cpu": "x64" }, "sha512-qd98fX2+I5nYJDioW2o7nSjoxM5KvWdeDefM80igia4+C/qSIEhH4MhTE+hO/7qKM7W37/Mq+dOWp8UePSyLHw=="],
+ "@next/swc-darwin-x64": ["@next/[email protected]", "", { "os": "darwin", "cpu": "x64" }, "sha512-2dpiSyl2Jw/NrBPaU2MAKGSa+2MR82pJIn4Sm5Rjr+gxAeuh0z158Su3Z2O8zn7UNNq+ej4bToed6RcRN/Lydg=="],
- "@next/swc-linux-arm64-gnu": ["@next/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-vqsgb6FAOzcrCccsLXiKtAy5t8EzO+uOazuFaSkQxeY0tNONG3vpHYy8pyBafcI5SNFPTeyard6yTr6SzNGo2A=="],
+ "@next/swc-linux-arm64-gnu": ["@next/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-+t+U8HZT+fApePCS5h89CSH3datz29MkzyfCn+6fpsZBG/oiEOhINcb9rtkv6sdpToLGFn2e6146NzaKCXkqrA=="],
- "@next/swc-linux-arm64-musl": ["@next/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-xIe1eujfHUB2XcxHGddxJyu6TJRPjC5NpIkQYB/32ESkt5VkQyIAjmLRS38c+s6QY+qjtY/4KarVDzXRuD7lZQ=="],
+ "@next/swc-linux-arm64-musl": ["@next/[email protected]", "", { "os": "linux", "cpu": "arm64" }, "sha512-mx03GNs1ocQA5JQ4FxDMmIsNkdrZh8cuezKCrId28e5/gIPU/l7Kcy2+vmCCzdjnnmXJy+iOAu+7K0QppO6Urg=="],
- "@next/swc-linux-x64-gnu": ["@next/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-Fe0SA2j8X0kmc3aveuHD7UktO3AE2+mH3LguP60vGbz7u0z+MrDXbeb5iZFYAwR7EzzzXJ2Yk966w9mGTFMqfA=="],
+ "@next/swc-linux-x64-gnu": ["@next/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-YIhGY6fSMfha52bnVxnzc9zaVBzJg+cqQTOD8tXIBSx4fuv0pVMxQTE0PaS59YhnMOiYiG09IMwxJAf/CFm/Dw=="],
- "@next/swc-linux-x64-musl": ["@next/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-TFBipb+gyesI/2Ve4zVu7kGltBWN/R466G5/1gtt2lECfc22G1pjkTxu68Q9aFcOaXiRGTQfvDbQQFe7mYgxiQ=="],
+ "@next/swc-linux-x64-musl": ["@next/[email protected]", "", { "os": "linux", "cpu": "x64" }, "sha512-+eaaX6axpDb0yF1GCpiERe6njplvdC+nks/fKfcHu3XPGRrald8P3/X7yv7QLdjA51knnxwl9pxdIJsg+w1L+Q=="],
- "@next/swc-win32-arm64-msvc": ["@next/[email protected]", "", { "os": "win32", "cpu": "arm64" }, "sha512-rVtmnNpBYIosDnKD/96dKxFsJnwnn1WRGG/HioSe8XCm2ksSHNrd2R6+hSjvTBxeMNhJ9pYeu/90cWB1nQLuNA=="],
+ "@next/swc-win32-arm64-msvc": ["@next/[email protected]", "", { "os": "win32", "cpu": "arm64" }, "sha512-0jcXW7Xs/uzICrmgV3MhDYDeRy++1CqnpDIerlPIqYO4bhzB4WNbX/aRnQclustsAyTkFKB0z6rbcjmNg5tR8A=="],
- "@next/swc-win32-x64-msvc": ["@next/[email protected]", "", { "os": "win32", "cpu": "x64" }, "sha512-H4Y2o2/JcHu8LtwzD5CXfHhwxwz8gfsx2HXDEw46Mtev5xHnEmB7HNtZtmriw5ReUOjRtcDqo7XSbU01FT9NlA=="],
+ "@next/swc-win32-x64-msvc": ["@next/[email protected]", "", { "os": "win32", "cpu": "x64" }, "sha512-vvBzwu1pYQCp92maZCFCIw/XgOTMR5tur9GjakwIo2cmwRTMKajRZZDS9+e4KsUZWKu1E007WUeAFXRRjZeuzw=="],
"@nodelib/fs.scandir": ["@nodelib/[email protected]", "", { "dependencies": { "@nodelib/fs.stat": "2.0.5", "run-parallel": "^1.1.9" } }, "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g=="],
@@ -242,6 +248,8 @@
"@oxc-project/types": ["@oxc-project/[email protected]", "", {}, "sha512-7W+2q5AKQVU36fkaryontrHn3YDt1RyUYXatw9i5H8ocYe2sPKSFB6eS8WNPeRKiN1qAWWZUPm7gwFzJGrccqQ=="],
+ "@playwright/test": ["@playwright/[email protected]", "", { "dependencies": { "playwright": "1.63.0" }, "bin": { "playwright": "cli.js" } }, "sha512-oxMK4vllB9RK5NQ2l1pq1IfOf2AvnEuj/vYGDj0H2nMtmtZpKtCwt/l00GEO6xjGfpBNAvjovvYdCm50dRQkpQ=="],
+
"@protobufjs/aspromise": ["@protobufjs/[email protected]", "", {}, "sha512-j+gKExEuLmKwvz3OgROXtrJ2UG2x8Ch2YZUxahh+s1F2HZ+wAceUNLkvy6zKCPVRkU++ZWQrdxsUeQXmcg4uoQ=="],
"@protobufjs/base64": ["@protobufjs/[email protected]", "", {}, "sha512-AZkcAA5vnN/v4PDqKyMR5lx7hZttPDgClv83E//FMNhR2TMcLUhfRUBHCmSl0oi9zMgDDqRUJkSxO3wm85+XLg=="],
@@ -548,7 +556,7 @@
"available-typed-arrays": ["[email protected]", "", { "dependencies": { "possible-typed-array-names": "^1.0.0" } }, "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ=="],
- "axe-core": ["[email protected]", "", {}, "sha512-s7iGf5GaVMxEG0ENN9x+xTr7GFZCb1ZP/1uATUpCEK2X78nDB3RwbtFCo9pGAf9ru+VwoQ464DkaLEeRM08wJA=="],
+ "axe-core": ["[email protected]", "", {}, "sha512-UzGt8zg7Ny8djbYMhxl2zuEevVa7r2gJjYY5Lwr1xM7+XU2nd6CkIWFTVcCIbAP63vSz71NaVyyuSk9lHKcy0A=="],
"axobject-query": ["[email protected]", "", {}, "sha512-qIj0G9wZbMGNLjLmg1PT6v2mE9AH2zlnADJD/2tC6E00hgmhUOfEB6greHPAfLRSufHqROIUTkw6E+M3lH0PTQ=="],
@@ -652,7 +660,7 @@
"eslint": ["[email protected]", "", { "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.2", "@eslint/config-helpers": "^0.4.2", "@eslint/core": "^0.17.0", "@eslint/eslintrc": "^3.3.6", "@eslint/js": "9.39.5", "@eslint/plugin-kit": "^0.4.1", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", "@types/estree": "^1.0.6", "ajv": "^6.14.0", "chalk": "^4.0.0", "cross-spawn": "^7.0.6", "debug": "^4.3.2", "escape-string-regexp": "^4.0.0", "eslint-scope": "^8.4.0", "eslint-visitor-keys": "^4.2.1", "espree": "^10.4.0", "esquery": "^1.5.0", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", "file-entry-cache": "^8.0.0", "find-up": "^5.0.0", "glob-parent": "^6.0.2", "ignore": "^5.2.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", "json-stable-stringify-without-jsonify": "^1.0.1", "lodash.merge": "^4.6.2", "minimatch": "^3.1.5", "natural-compare": "^1.4.0", "optionator": "^0.9.3" }, "peerDependencies": { "jiti": "*" }, "optionalPeers": ["jiti"], "bin": { "eslint": "bin/eslint.js" } }, "sha512-DgZS62aPLXKlnxILS/AYCoRvHaZeXceIzlXPkkGGzJWSow1aEk0lbTlxUSlyjC8jcaKxAdOnTDz+o1JFSBsyjw=="],
- "eslint-config-next": ["[email protected]", "", { "dependencies": { "@next/eslint-plugin-next": "16.3.2", "eslint-import-resolver-node": "^0.3.6", "eslint-import-resolver-typescript": "^3.5.2", "eslint-plugin-import": "^2.32.0", "eslint-plugin-jsx-a11y": "^6.10.0", "eslint-plugin-react": "^7.37.0", "eslint-plugin-react-hooks": "^7.0.0", "globals": "16.4.0", "typescript-eslint": "^8.46.0" }, "peerDependencies": { "eslint": ">=9.0.0", "typescript": ">=3.3.1" }, "optionalPeers": ["typescript"] }, "sha512-gTABOJmyc6pEgSX1Z1VOjBxkSmo5Hkdj+ePclDf8HLGTsnVWzgtDdrOeQrAnUkf0JNJJhwPuXrsIwmFZRKJLoQ=="],
+ "eslint-config-next": ["[email protected]", "", { "dependencies": { "@next/eslint-plugin-next": "16.3.4", "eslint-import-resolver-node": "^0.3.6", "eslint-import-resolver-typescript": "^3.5.2", "eslint-plugin-import": "^2.32.0", "eslint-plugin-jsx-a11y": "^6.10.0", "eslint-plugin-react": "^7.37.0", "eslint-plugin-react-hooks": "^7.0.0", "globals": "16.4.0", "typescript-eslint": "^8.46.0" }, "peerDependencies": { "eslint": ">=9.0.0", "typescript": ">=3.3.1" }, "optionalPeers": ["typescript"] }, "sha512-35/8RM10huEL9vlr8hUZMERMENHBrnyHN3ZZkF9efSgzGaqK34jIqry44A956//zriUhUAUW0XSkcolhrryqAA=="],
"eslint-import-resolver-node": ["[email protected]", "", { "dependencies": { "debug": "^3.2.7", "is-core-module": "^2.16.1", "resolve": "^2.0.0-next.6" } }, "sha512-tRrKqFyCaKict5hOd244sL6EQFNycnMQnBe+j8uqGNXYzsImGbGUU4ibtoaBmv5FLwJwcFJNeg1GeVjQfbMrDQ=="],
@@ -856,7 +864,7 @@
"js-tokens": ["[email protected]", "", {}, "sha512-lM/UBzQmfJRo9ABXbPWemivdCW8V2G8FHaHdypQaIy523snUjog0W71ayWXTjiR+ixeMyVHN2XcpnTd/liPg/Q=="],
- "js-yaml": ["[email protected]", "", { "dependencies": { "argparse": "^2.0.1" }, "bin": { "js-yaml": "bin/js-yaml.js" } }, "sha512-CY6crGq313MX8GkwvB7tzgp99vjQxY1++5y10/BKN/GUfHqWaOGQMNZkBvqSzsZKWk/ijwHlWzzkLulsGHhjWQ=="],
+ "js-yaml": ["[email protected]", "", { "dependencies": { "argparse": "^2.0.1" }, "bin": { "js-yaml": "bin/js-yaml.js" } }, "sha512-SFNOvSJ+Dgf/9An904Yx+CgSlIPCkIpao4qo51lpee25TIRejdH3rhR4EZMGoNx3/TP3O+wzWuiTFl4sqbltzA=="],
"jsesc": ["[email protected]", "", { "bin": { "jsesc": "bin/jsesc" } }, "sha512-/sM3dO2FOzXjKQhJuo0Q173wf2KOo8t4I8vHy6lF9poUp7bKT0/NHE8fPX23PwfhnykfqnC2xRxOnVw5XuGIaA=="],
@@ -946,7 +954,7 @@
"ndarray": ["[email protected]", "", { "dependencies": { "iota-array": "^1.0.0", "is-buffer": "^1.0.2" } }, "sha512-B4JHA4vdyZU30ELBw3g7/p9bZupyew5a7tX1Y/gGeF2hafrPaQZhgrGQfsvgfYbgdFZjYwuEcnaobeM/WMW+HQ=="],
- "next": ["[email protected]", "", { "dependencies": { "@next/env": "16.3.2", "@swc/helpers": "0.5.23", "baseline-browser-mapping": "^2.9.19", "caniuse-lite": "^1.0.30001579", "postcss": "8.5.23", "styled-jsx": "5.1.6" }, "optionalDependencies": { "@next/swc-darwin-arm64": "16.3.2", "@next/swc-darwin-x64": "16.3.2", "@next/swc-linux-arm64-gnu": "16.3.2", "@next/swc-linux-arm64-musl": "16.3.2", "@next/swc-linux-x64-gnu": "16.3.2", "@next/swc-linux-x64-musl": "16.3.2", "@next/swc-win32-arm64-msvc": "16.3.2", "@next/swc-win32-x64-msvc": "16.3.2", "sharp": "^0.35.3" }, "peerDependencies": { "@opentelemetry/api": "^1.1.0", "@playwright/test": "^1.51.1", "babel-plugin-react-compiler": "*", "react": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", "react-dom": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", "sass": "^1.3.0" }, "optionalPeers": ["@opentelemetry/api", "@playwright/test", "babel-plugin-react-compiler", "sass"], "bin": { "next": "dist/bin/next" } }, "sha512-/ZCaubUy17Lld1SiPWxuPbCk2ihqAxF2QNQaPZeEaEb7t1I58qhsJN187D7AfpapHAqUPXH0f/thtdW9dWgWFg=="],
+ "next": ["[email protected]", "", { "dependencies": { "@next/env": "16.3.4", "@swc/helpers": "0.5.23", "baseline-browser-mapping": "^2.9.19", "caniuse-lite": "^1.0.30001579", "postcss": "8.5.23", "styled-jsx": "5.1.6" }, "optionalDependencies": { "@next/swc-darwin-arm64": "16.3.4", "@next/swc-darwin-x64": "16.3.4", "@next/swc-linux-arm64-gnu": "16.3.4", "@next/swc-linux-arm64-musl": "16.3.4", "@next/swc-linux-x64-gnu": "16.3.4", "@next/swc-linux-x64-musl": "16.3.4", "@next/swc-win32-arm64-msvc": "16.3.4", "@next/swc-win32-x64-msvc": "16.3.4", "sharp": "^0.35.4" }, "peerDependencies": { "@opentelemetry/api": "^1.1.0", "@playwright/test": "^1.51.1", "babel-plugin-react-compiler": "*", "react": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", "react-dom": "^18.2.0 || 19.0.0-rc-de68d2f4-20241204 || ^19.0.0", "sass": "^1.3.0" }, "optionalPeers": ["@opentelemetry/api", "@playwright/test", "babel-plugin-react-compiler", "sass"], "bin": { "next": "dist/bin/next" } }, "sha512-/Ztf6CeRH+ejEXUrYtqI4gkS66eFIHuSwqi60RgcpWKodxFZx2/dqVCMKBwILfAHXQ+F1b1vAudgj3mnxqtoIA=="],
"node-addon-api": ["[email protected]", "", {}, "sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ=="],
@@ -1004,6 +1012,10 @@
"platform": ["[email protected]", "", {}, "sha512-fnWVljUchTro6RiCFvCXBbNhJc2NijN7oIQxbwsyL0buWJPG85v81ehlHI9fXrJsMNgTofEoWIQeClKpgxFLrg=="],
+ "playwright": ["[email protected]", "", { "dependencies": { "playwright-core": "1.63.0" }, "bin": { "playwright": "cli.js" } }, "sha512-+7ziBLidS4NaNCdt57SUDT+wYmmd5fmiQejUic/kb+YsYSCPyOOE9sebzMjNmQrsnNpDJqd4WHvV/8lfKfUDUg=="],
+
+ "playwright-core": ["[email protected]", "", { "bin": { "playwright-core": "cli.js" } }, "sha512-rYCsBF/M5HjUch52bbtVONEFjv6Xu8sm8h72dNlR5bzIE1fvC/bxgspzkjSfU+MweEMmPM8KJebG6nnyxo5mCg=="],
+
"possible-typed-array-names": ["[email protected]", "", {}, "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg=="],
"postcss": ["[email protected]", "", { "dependencies": { "nanoid": "^3.3.17", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-u82N74LFzG8ca+dD8puPnplTXoGH4fTPpVGuIbt36G3qvNlkvfD0lEAZSxaly3KX8TS/L1A1gsCEmvKmBcVbkQ=="],
@@ -1070,7 +1082,7 @@
"set-proto": ["[email protected]", "", { "dependencies": { "dunder-proto": "^1.0.1", "es-errors": "^1.3.0", "es-object-atoms": "^1.0.0" } }, "sha512-RJRdvCo6IAnPdsvP/7m6bsQqNnn1FCBX5ZNtFL98MmFF/4xAIJTIg1YbHW5DC2W5SKZanrC6i4HsJqlajw/dZw=="],
- "sharp": ["[email protected]", "", { "dependencies": { "@img/colour": "^1.1.0", "detect-libc": "^2.1.2", "semver": "^7.8.5" }, "optionalDependencies": { "@img/sharp-darwin-arm64": "0.35.3", "@img/sharp-darwin-x64": "0.35.3", "@img/sharp-freebsd-wasm32": "0.35.3", "@img/sharp-libvips-darwin-arm64": "1.3.2", "@img/sharp-libvips-darwin-x64": "1.3.2", "@img/sharp-libvips-linux-arm": "1.3.2", "@img/sharp-libvips-linux-arm64": "1.3.2", "@img/sharp-libvips-linux-ppc64": "1.3.2", "@img/sharp-libvips-linux-riscv64": "1.3.2", "@img/sharp-libvips-linux-s390x": "1.3.2", "@img/sharp-libvips-linux-x64": "1.3.2", "@img/sharp-libvips-linuxmusl-arm64": "1.3.2", "@img/sharp-libvips-linuxmusl-x64": "1.3.2", "@img/sharp-linux-arm": "0.35.3", "@img/sharp-linux-arm64": "0.35.3", "@img/sharp-linux-ppc64": "0.35.3", "@img/sharp-linux-riscv64": "0.35.3", "@img/sharp-linux-s390x": "0.35.3", "@img/sharp-linux-x64": "0.35.3", "@img/sharp-linuxmusl-arm64": "0.35.3", "@img/sharp-linuxmusl-x64": "0.35.3", "@img/sharp-webcontainers-wasm32": "0.35.3", "@img/sharp-win32-arm64": "0.35.3", "@img/sharp-win32-ia32": "0.35.3", "@img/sharp-win32-x64": "0.35.3" }, "peerDependencies": { "@types/node": "*" }, "optionalPeers": ["@types/node"] }, "sha512-ej0zVHuZGHCiABXcNxeYhpRnPNPAcvbG8RMdBAhDAxLKkCRVSpK3Iyu7qbqw3JMzoj0REeM6f3tJLtVwl0023Q=="],
+ "sharp": ["[email protected]", "", { "dependencies": { "@img/colour": "^1.1.0", "detect-libc": "^2.1.2", "semver": "^7.8.5" }, "optionalDependencies": { "@img/sharp-darwin-arm64": "0.35.4", "@img/sharp-darwin-x64": "0.35.4", "@img/sharp-freebsd-wasm32": "0.35.4", "@img/sharp-libvips-darwin-arm64": "1.3.3", "@img/sharp-libvips-darwin-x64": "1.3.3", "@img/sharp-libvips-linux-arm": "1.3.3", "@img/sharp-libvips-linux-arm64": "1.3.3", "@img/sharp-libvips-linux-ppc64": "1.3.3", "@img/sharp-libvips-linux-riscv64": "1.3.3", "@img/sharp-libvips-linux-s390x": "1.3.3", "@img/sharp-libvips-linux-x64": "1.3.3", "@img/sharp-libvips-linuxmusl-arm64": "1.3.3", "@img/sharp-libvips-linuxmusl-x64": "1.3.3", "@img/sharp-linux-arm": "0.35.4", "@img/sharp-linux-arm64": "0.35.4", "@img/sharp-linux-ppc64": "0.35.4", "@img/sharp-linux-riscv64": "0.35.4", "@img/sharp-linux-s390x": "0.35.4", "@img/sharp-linux-x64": "0.35.4", "@img/sharp-linuxmusl-arm64": "0.35.4", "@img/sharp-linuxmusl-x64": "0.35.4", "@img/sharp-webcontainers-wasm32": "0.35.4", "@img/sharp-win32-arm64": "0.35.4", "@img/sharp-win32-ia32": "0.35.4", "@img/sharp-win32-x64": "0.35.4" }, "peerDependencies": { "@types/node": "*" }, "optionalPeers": ["@types/node"] }, "sha512-n++8XWcj+jCOr2IOl7h8LbKnGBDY4aPbmprMONBNFdn0ImXqpGVv5zliDs0V9HbmbCQLpbuo2ej9rAoOQTvMDA=="],
"shebang-command": ["[email protected]", "", { "dependencies": { "shebang-regex": "^3.0.0" } }, "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA=="],
@@ -1086,6 +1098,8 @@
"siginfo": ["[email protected]", "", {}, "sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g=="],
+ "simple-icons": ["[email protected]", "", {}, "sha512-YX/HmgEqjpn5Zs3myzKp8ek5Ti+TdrkvNWn9skGLetg9tOg0cTjYizj9ESAYJn4xwc0GQYVGzQxBELDfbxq7WQ=="],
+
"source-map-js": ["[email protected]", "", {}, "sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA=="],
"stable-hash": ["[email protected]", "", {}, "sha512-+L3ccpzibovGXFK+Ap/f8LOS0ahMrHTf3xu7mMLSpEGU0EO9ucaysSylKo9eRDFNhWve/y275iPmIZ4z39a9iA=="],
@@ -1228,8 +1242,6 @@
"@tailwindcss/oxide-wasm32-wasi/tslib": ["[email protected]", "", { "bundled": true }, "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w=="],
- "@tailwindcss/postcss/postcss": ["[email protected]", "", { "dependencies": { "nanoid": "^3.3.16", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-DTPx3RWSSnWyzLxQnlH0rJP+EW5ekl16ZU4/psbIhA0e53kJfdgaN5vKM+xP7yJtXVu+nfdVFmlgFDEKAe4Pyw=="],
-
"@typescript-eslint/eslint-plugin/ignore": ["[email protected]", "", {}, "sha512-BAg6QkE8W+TuQLrrw0Ugr7HegXduRuuj8/ti2kSOc+jz1dmx8/WNcjr6XGnq5YpDWxFwwaavqD0+jIUOKelTsw=="],
"@typescript-eslint/typescript-estree/minimatch": ["[email protected]", "", { "dependencies": { "brace-expansion": "^5.0.8" } }, "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A=="],
@@ -1244,6 +1256,8 @@
"eslint-plugin-import/debug": ["[email protected]", "", { "dependencies": { "ms": "^2.1.1" } }, "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ=="],
+ "eslint-plugin-jsx-a11y/axe-core": ["[email protected]", "", {}, "sha512-s7iGf5GaVMxEG0ENN9x+xTr7GFZCb1ZP/1uATUpCEK2X78nDB3RwbtFCo9pGAf9ru+VwoQ464DkaLEeRM08wJA=="],
+
"eslint-plugin-react-hooks/zod": ["[email protected]", "", {}, "sha512-ytENFjIJFl2UwYglde2jchW2Hwm4GJFLDiSXWdTrJQBIN9Fcyp7n4DhxJEiWNAJMV1/BqWfW/kkg71UDcHJyTQ=="],
"fast-glob/glob-parent": ["[email protected]", "", { "dependencies": { "is-glob": "^4.0.1" } }, "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow=="],
@@ -1258,14 +1272,10 @@
"micromatch/picomatch": ["[email protected]", "", {}, "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA=="],
- "next/postcss": ["[email protected]", "", { "dependencies": { "nanoid": "^3.3.16", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-DTPx3RWSSnWyzLxQnlH0rJP+EW5ekl16ZU4/psbIhA0e53kJfdgaN5vKM+xP7yJtXVu+nfdVFmlgFDEKAe4Pyw=="],
-
"sharp/semver": ["[email protected]", "", { "bin": { "semver": "bin/semver.js" } }, "sha512-Y7/KDsb8LjooZpwaqGyulO6DQlksgCncchHGk+sZIY4SBvUocMBEFH5Ur1fI4dV+Jvl0w6cjvucaIi40puRioA=="],
"vite/lightningcss": ["[email protected]", "", { "dependencies": { "detect-libc": "^2.0.3" }, "optionalDependencies": { "lightningcss-android-arm64": "1.33.0", "lightningcss-darwin-arm64": "1.33.0", "lightningcss-darwin-x64": "1.33.0", "lightningcss-freebsd-x64": "1.33.0", "lightningcss-linux-arm-gnueabihf": "1.33.0", "lightningcss-linux-arm64-gnu": "1.33.0", "lightningcss-linux-arm64-musl": "1.33.0", "lightningcss-linux-x64-gnu": "1.33.0", "lightningcss-linux-x64-musl": "1.33.0", "lightningcss-win32-arm64-msvc": "1.33.0", "lightningcss-win32-x64-msvc": "1.33.0" } }, "sha512-WkUDrojuJs0xkgGf2udWxa3yGBRxPtxUkB79i6aCZLRgc7PM8fZe9TosfPDcvEpQZbuFASnHYmRLBLUbmLOIIA=="],
- "vite/postcss": ["[email protected]", "", { "dependencies": { "nanoid": "^3.3.16", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-DTPx3RWSSnWyzLxQnlH0rJP+EW5ekl16ZU4/psbIhA0e53kJfdgaN5vKM+xP7yJtXVu+nfdVFmlgFDEKAe4Pyw=="],
-
"@next/eslint-plugin-next/@eslint-community/eslint-utils/eslint-visitor-keys": ["[email protected]", "", {}, "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag=="],
"@typescript-eslint/typescript-estree/minimatch/brace-expansion": ["[email protected]", "", { "dependencies": { "balanced-match": "^4.0.2" } }, "sha512-ScQ4IuvIEF1TMlP7Zt+vjJ//9zlPb2SDcxWxM3bk8s6t6GGdJ7KO1dCcTidOPJKePW30LE/2cT7wCyPho9/Wxg=="],
diff --git a/docs/ARCHITECTURE.md b/docs/ARCHITECTURE.md
index 6e23bf4a..29461da1 100644
--- a/docs/ARCHITECTURE.md
+++ b/docs/ARCHITECTURE.md
@@ -123,7 +123,7 @@ MSO exposes exactly two user-visible MCP App classes instead:
- `render_mso_block` binds `ui://mso/block-v2.html` for compact validation, action buttons, and
CRUD input-output. A button returns a user-approved follow-up message; it does not execute a
mutation inside the widget, so ordinary scope, approval, audit, and workflow rules still apply.
-- `render_mso_page` binds the canonical `ui://mso/page-v10.html` resource for native `/`, `/monitor`, `/project`, `/diff`,
+- `render_mso_page` binds the canonical `ui://mso/page-v11.html` resource for native `/`, `/monitor`, `/project`, `/diff`,
`/browser`, and `/apps/<reviewed-id>` views. Native Page views call the same bounded MSO tools.
`workflow_start` is orchestration-only and headless: it still owns workflow isolation, skill/recipe
@@ -158,6 +158,8 @@ uses canonical path/containment checks and additionally blocks credential materi
MSO's own state, `.env*`, SSH/GPG material and other sensitive-home paths unless a supervised
operator explicitly enables the documented escape hatch.
+Explicit cwd must be an existing directory within writable roots after realpath resolution. Only omitted cwd defaults to home; invalid exec/job/PTY targets never silently retarget commands.
+
Interactive PTYs are intentionally stronger than filtered one-shot exec. A PTY is a real
login shell; raw keystrokes do not have reliable command boundaries. Authentication and
session lifecycle are therefore the boundary, not the one-shot destructive-command regex.
@@ -261,6 +263,7 @@ bun run ship "docs: describe the verified change"
The release path regenerates derived changelog data, runs push gates (including an
out-of-tree production build), pushes the exact commit, then hands the in-place
build/restart/final verification to the owner user manager when launched through MSO/MCP.
+Before push, the out-of-tree build runs required browser journeys against synthetic device/credential stores and a local provider fixture.
A successful finalizer ends `~/.mso/self-update.log` with `UPDATE OK`.
For operator updates use Settings → About or `mso update`; use `--rebuild` for the
diff --git a/docs/DEVELOPMENT.md b/docs/DEVELOPMENT.md
index 85b4bbc0..46c83ec3 100644
--- a/docs/DEVELOPMENT.md
+++ b/docs/DEVELOPMENT.md
@@ -37,19 +37,35 @@ idempotently with `bash scripts/gates.sh --install`.
The gate runs the repository-owned `bun run verify`, cycle checks, generated-changelog freshness, documentation/skill checks,
comparison evidence/freshness, the strict high/critical dependency audit, and an out-of-tree production
-build.
-`check-contrast.mjs` is informational. None of the build verification touches the live
+build plus mandatory synthetic browser journeys.
+`check-contrast.mjs` blocks palette regressions. None of the build verification touches the live
checkout's `.next`. A healthy push ends with `audit: clean at high/critical.` and
`build: HEAD compiles (out-of-tree).`
The local dependency audit may explicitly skip an unavailable registry; that is not a security pass.
`bun run audit:strict`, the pre-push gate, and the assurance runner reject incomplete evidence. `test:features` distinguishes
PASS, PARTIAL, SKIPPED and FAIL. Per-area exact-include configurations and result-set validation prevent substring-filter double counting; a root inventory contract prevents unregistered root tests. Slices without colocated unit tests are listed as coverage gaps,
-not invented successes. Browser rendering and live third-party operations need separate acceptance.
+not invented successes. The required browser fixture covers public guides, direct login/return, launcher clicks and desktop/phone reflow, plus real local-provider rejection and immediate role demotion. Live third-party OAuth still needs provider-specific acceptance.
The gate has no sibling-repository runner or dormant Convex deployment step. Worktree hook installation
uses Git's shared hook path rather than assuming `.git` is a directory.
+## Browser release fixtures
+
+Install the pinned browser once with `node_modules/.bin/playwright install chromium`
+(on CI use `--with-deps`). `scripts/verify-build.sh` runs `e2e:release` against the
+same out-of-tree build. A missing browser or failed journey blocks the push; no
+production password, approved device, or integration is borrowed. Fixture stores,
+filesystem roots and provider endpoints are temporary and loopback-only. Normal
+CI runs the same journeys after its production build. A daily dependency job
+runs the strict audit so advisory status cannot silently age out.
+
+Coverage floors are statements 42%, branches 40%, functions 32%, lines 43.5%,
+ratcheted from the measured audit baseline. These are regression floors, not a
+claim that every feature is covered. Two-instance tests independently load origin,
+widget CSP and external app catalogs. The literal guard is supporting evidence,
+not a substitute for runtime isolation tests.
+
## Comparison governance
`docs/comparison-data.json` is the only hand-edited comparison source. It records criterion
diff --git a/docs/PROGRESS.md b/docs/PROGRESS.md
index 74eea5f2..2dde9ab7 100644
--- a/docs/PROGRESS.md
+++ b/docs/PROGRESS.md
@@ -1,3 +1,11 @@
+## 2026-09-09 — Audit hardening and required browser release journeys
+
+The audit found outdated security dependencies, implicit command retargeting, historical connection checks presented as current health, and an indirect sign-in path. Patched dependency floors retain the existing stack. Explicit invalid cwd now fails before exec/job/PTY launch; successful one-shot results expose their resolved cwd. Connection doctor pins credentials and records a bounded result for that exact revision; rejected access and unavailable providers no longer display an old green Verified state. Credential rotation and later checks reject stale results.
+
+Integrations now links directly to login with a validated same-origin return destination, refreshes cards after Verify, uses embedded provider SVG marks where available, and exposes setup instructions without two collapsed levels. Signed-out desktop entry labels mock data persistently; Settings avoids fetching owner AI configuration for anonymous/delegated visitors. Standalone heading hierarchy and verified text contrast are corrected.
+
+The release build is followed by synthetic browser journeys for desktop, phone portrait and landscape, login/return, a local provider that changes from success to 401, state after reload, harmless file/exec operations and live device-role demotion. Public Integrations also runs automated accessibility checks. All fixture state is disposable; no production credentials are used. Unit test environment baselines and two-instance resource/CSP tests prevent host configuration from changing default-test expectations. Coverage floors follow the observed baseline; palette regressions now fail; strict dependencies are checked daily in CI. Validation results are recorded after execution below.
+
## 2026-09-09 — Instance portability and MCP privacy boundary
MSO source no longer owns an operator hostname, home path, project root, MCP widget origin, or external Page app. Browser origin comes from `OS_PUBLIC_ORIGIN`; the MCP Apps sibling origin is derived per installation or overridden with `OS_MCP_UI_ORIGIN`; reviewed external Page apps are an empty-by-default, bounded `MSO_SURFACE_APPS_JSON` catalog. Current repository/worktree instructions resolve the active checkout rather than assuming a maintainer home. A repository-wide instance-literal gate now rejects known operator-instance domains/paths across runtime code, tests, docs, workflows, and official skills. Maintainer deployments keep their own public values only in ignored/local runtime configuration.
diff --git a/docs/generated/MCP-CATALOG.md b/docs/generated/MCP-CATALOG.md
index 27b9f399..6ee95b24 100644
--- a/docs/generated/MCP-CATALOG.md
+++ b/docs/generated/MCP-CATALOG.md
@@ -4,13 +4,13 @@
## Full MSO catalog
-<!-- mcp-toolset: server=1.12.2 version=2026.09.07.1 tools=97 read=47 write=30 exec=20 -->
+<!-- mcp-toolset: server=1.12.3 version=2026.09.09.1 tools=97 read=47 write=30 exec=20 -->
| Fact | Current source value |
|---|---:|
-| MCP server | `1.12.2` |
-| Toolset | `2026.09.07.1` |
-| Toolset changed at | `2026-09-07T19:40:00Z` |
+| MCP server | `1.12.3` |
+| Toolset | `2026.09.09.1` |
+| Toolset changed at | `2026-09-09T05:55:00Z` |
| Transport tools | **99** |
| Model/operator tools | **97** |
| Read | **47** |
@@ -131,7 +131,7 @@
## ChatGPT static profile
-<!-- mcp-chatgpt-profile: server=1.12.2 version=2026.09.07.1 tools=71 read=37 write=21 exec=13 app-only=2 total=73 -->
+<!-- mcp-chatgpt-profile: server=1.12.3 version=2026.09.09.1 tools=71 read=37 write=21 exec=13 app-only=2 total=73 -->
The ChatGPT profile is a fail-closed static projection defined by `CHATGPT_TOOL_NAMES`. OAuth scope is still enforced independently; project-owned MCP tool names remain dynamic data behind the generic project bridge.
diff --git a/frontend/slices/appshell/components/shells/context-menu.tsx b/frontend/slices/appshell/components/shells/context-menu.tsx
index 9e8a68d6..68f08344 100644
--- a/frontend/slices/appshell/components/shells/context-menu.tsx
+++ b/frontend/slices/appshell/components/shells/context-menu.tsx
@@ -176,7 +176,7 @@ export function ContextMenu({ pos, items, onClose }: { pos: Pos; items: MenuItem
}, [sub]);
if (!pos) return null;
- // Match shell.rahmanef.com: LEFT-aligned rows, icon on the LEFT, accent-fill hover
+ // Shared shell layout: LEFT-aligned rows, icon on the LEFT, accent-fill hover
// on the --primary token (never a hex). Metrics are per-persona + pointer-aware
// (see menuMetrics) and BOTH panels share them.
const m = menuMetrics(active.id);
diff --git a/frontend/slices/appshell/features/widgets/components/widget-picker.tsx b/frontend/slices/appshell/features/widgets/components/widget-picker.tsx
index 5a421525..8629e183 100644
--- a/frontend/slices/appshell/features/widgets/components/widget-picker.tsx
+++ b/frontend/slices/appshell/features/widgets/components/widget-picker.tsx
@@ -26,7 +26,7 @@ class PreviewBoundary extends Component<{ children: ReactNode }, { failed: boole
}
}
-// Desktop-widget picker — a live-preview gallery (mirrors shell.rahmanef.com):
+// Desktop-widget picker — a live-preview gallery (uses the shared shell layout):
// each card mounts the REAL widget clipped to a small box (pointer-events-none so
// it's non-interactive), and clicking the card adds/removes it. Arrange by
// dragging widgets on the desktop (no up/down reorder here anymore).
diff --git a/frontend/slices/appshell/features/widgets/components/widgets-defs-vps.tsx b/frontend/slices/appshell/features/widgets/components/widgets-defs-vps.tsx
index 3a565ded..5d398224 100644
--- a/frontend/slices/appshell/features/widgets/components/widgets-defs-vps.tsx
+++ b/frontend/slices/appshell/features/widgets/components/widgets-defs-vps.tsx
@@ -9,7 +9,7 @@ import { Card } from "./widget-cards";
import { mdToHtml } from "./md";
import { safeEmbedUrl } from "./embed-url";
-// VPS-native + content widgets ported from shell.rahmanef.com's set: a stopwatch,
+// VPS-native + content widgets ported from the original shell widget set: a stopwatch,
// a URL embed, a sandboxed-HTML snippet, a markdown note, an active-shell picker,
// and a theme toggle. Split out to keep widgets-defs.tsx under the line ceiling.
// All are interactive (opt back into pointer events).
diff --git a/frontend/slices/auth/components/auth-gate.tsx b/frontend/slices/auth/components/auth-gate.tsx
index 227ae687..a92fec59 100644
--- a/frontend/slices/auth/components/auth-gate.tsx
+++ b/frontend/slices/auth/components/auth-gate.tsx
@@ -5,6 +5,7 @@ import { useEffect, useState, type ReactNode } from "react";
import { Loader2 } from "lucide-react";
import { useAppearance } from "@/lib/appearance";
import { IS_DEMO } from "@/lib/demo";
+import { SessionModeBanner } from "./session-mode-banner";
import { useSession } from "../lib/use-session";
// The shell is PUBLIC: anyone can open it and browse on mock data — no sign-in
@@ -56,6 +57,7 @@ function GatedOS({ children }: { children: ReactNode }) {
return (
<>
{children}
+ <SessionModeBanner />
{status === "in" && <FirstLoginOnboarding />}
</>
); // signed-in AND signed-out → the shell (mock when out)
diff --git a/frontend/slices/auth/components/login-page.tsx b/frontend/slices/auth/components/login-page.tsx
new file mode 100644
index 00000000..a4182fe4
--- /dev/null
+++ b/frontend/slices/auth/components/login-page.tsx
@@ -0,0 +1,22 @@
+"use client";
+
+import Link from "next/link";
+
+import { AppearanceProvider } from "@/lib/appearance";
+import { LoginCard } from "./login-screen";
+
+export function ServerLoginPage({ returnTo }: { returnTo: string }) {
+ return (
+ <AppearanceProvider>
+ <main className="grid h-dvh w-full place-items-center overflow-y-auto bg-background px-4 py-8 text-foreground">
+ <div className="w-full max-w-sm space-y-5 rounded-xl border border-border bg-card p-6 shadow-sm">
+ <LoginCard onAuthed={() => window.location.assign(returnTo)} />
+ <p className="text-sm text-muted-foreground">Access follows this device’s approved role. Integrations require Owner access.</p>
+ <Link prefetch={false} href="/" className="inline-flex min-h-11 items-center text-sm text-primary underline underline-offset-4">
+ Continue with demo data
+ </Link>
+ </div>
+ </main>
+ </AppearanceProvider>
+ );
+}
diff --git a/frontend/slices/auth/components/login-screen.tsx b/frontend/slices/auth/components/login-screen.tsx
index 029bd738..54f25d57 100644
--- a/frontend/slices/auth/components/login-screen.tsx
+++ b/frontend/slices/auth/components/login-screen.tsx
@@ -133,7 +133,7 @@ export function LoginCard({ onAuthed }: { onAuthed: () => void }) {
export function LoginScreen({ onAuthed }: { onAuthed: () => void }) {
const { tweaks } = useAppearance();
return (
- <div className="relative grid h-dvh w-screen place-items-center overflow-hidden">
+ <div className="relative grid min-h-dvh w-full place-items-center overflow-y-auto py-8">
<div
className={cn(!tweaks.wallpaperStyle && `wp-${tweaks.wallpaper === "auto" ? "aurora" : tweaks.wallpaper}`, "absolute inset-0 -z-10 bg-cover bg-center")}
style={tweaks.wallpaperStyle}
diff --git a/frontend/slices/auth/components/session-mode-banner.tsx b/frontend/slices/auth/components/session-mode-banner.tsx
new file mode 100644
index 00000000..6ff2ad54
--- /dev/null
+++ b/frontend/slices/auth/components/session-mode-banner.tsx
@@ -0,0 +1,27 @@
+"use client";
+
+import Link from "next/link";
+
+import { useAppearance } from "@/lib/appearance";
+import { useSession } from "../lib/use-session";
+
+// Always visible, including after navigation; never imply mock metrics are live.
+export function SessionModeBanner() {
+ const { status, role } = useSession();
+ const { tweaks } = useAppearance();
+ const live = status === "in" && tweaks.server.mode === "live";
+ return (
+ <aside
+ aria-label="Server connection mode"
+ className="fixed right-2 top-9 z-[60] flex max-w-[calc(100vw-1rem)] items-center gap-3 rounded-lg border border-border bg-popover px-3 py-2 text-xs text-popover-foreground shadow-sm"
+ data-connection-mode={live ? "live" : "mock"}
+ >
+ <span>{live ? `Live server · ${role}` : "Demo · Mock data only"}</span>
+ {status === "out" && (
+ <Link prefetch={false} href="/login" className="rounded px-2 py-1 font-semibold text-primary underline underline-offset-4 focus-visible:outline-2 focus-visible:outline-ring">
+ Sign in
+ </Link>
+ )}
+ </aside>
+ );
+}
diff --git a/frontend/slices/auth/index.ts b/frontend/slices/auth/index.ts
index 116c3174..77a0745e 100644
--- a/frontend/slices/auth/index.ts
+++ b/frontend/slices/auth/index.ts
@@ -5,3 +5,4 @@ export { LoginScreen, LoginCard } from "./components/login-screen";
export { DevicesPanel } from "./components/devices-panel";
export { SessionProvider, useSession, type SessionStatus } from "./lib/use-session";
export type { DeviceRole } from "@/lib/auth/roles";
+export { ServerLoginPage } from "./components/login-page";
diff --git a/frontend/slices/os-settings/app.tsx b/frontend/slices/os-settings/app.tsx
index f352e860..f308e070 100644
--- a/frontend/slices/os-settings/app.tsx
+++ b/frontend/slices/os-settings/app.tsx
@@ -2,6 +2,7 @@
import { useEffect, useState } from "react";
import { useAppearance, effectiveServerTarget } from "@/lib/appearance";
+import { useSession } from "@/features/auth";
import { IS_DEMO } from "@/lib/demo";
import {
useActiveShell,
@@ -14,6 +15,7 @@ import { SettingsShell } from "./components/settings-shell";
// Default export so os-shell can lazy-load it as a window app.
export default function OsSettings() {
const { tweaks } = useAppearance();
+ const { status, role } = useSession();
// Shared Settings state stays here; SettingsShell selects the presentation profile.
// No shell-specific layout/config lives in this headless app controller.
const { surface } = useActiveShell();
@@ -28,12 +30,12 @@ export default function OsSettings() {
useEffect(() => {
// Demo never calls /api (no auth) — the fetch would 401 and greet every
// visitor with an error toast. The default model label stands in.
- if (IS_DEMO) return;
+ if (IS_DEMO || status !== "in" || role !== "owner") return;
fetch("/api/config", { cache: "no-store" })
.then((r) => (r.ok ? r.json() : Promise.reject(new Error(`HTTP ${r.status}`))))
.then((c) => c?.model && setModel(`${c.provider ?? "provider"}/${c.model}`))
.catch(() => toast("Failed to load AI config", { tone: "error" }));
- }, []);
+ }, [status, role]);
// Surface system preferences to the shell AI Inspector.
usePublishInspector(
diff --git a/frontend/slices/os-settings/components/server-section.tsx b/frontend/slices/os-settings/components/server-section.tsx
index 5ad499b9..62e8d0ea 100644
--- a/frontend/slices/os-settings/components/server-section.tsx
+++ b/frontend/slices/os-settings/components/server-section.tsx
@@ -126,7 +126,7 @@ export function ServerSection() {
{authed ? (
<SettingsActionRow label="Sign out" onClick={onSignOut} />
) : (
- <SettingsActionRow label="Sign in (admin)" icon={<LogIn />} onClick={() => setLoginFor(liveTargetId)} />
+ <SettingsActionRow label="Sign in to MSO" icon={<LogIn />} onClick={() => setLoginFor(liveTargetId)} />
)}
</SettingsSection>
)}
diff --git a/lib/auth/return-path.test.ts b/lib/auth/return-path.test.ts
new file mode 100644
index 00000000..05d72ea4
--- /dev/null
+++ b/lib/auth/return-path.test.ts
@@ -0,0 +1,11 @@
+import { describe, expect, it } from "vitest";
+import { safeReturnPath } from "./return-path";
+
+describe("login return path", () => {
+ it.each(["https://evil.test", "//evil.test", "/\\\\evil.test", "/\n/evil.test", "/login?returnTo=/login", null])("rejects unsafe destination %j", value => {
+ expect(safeReturnPath(value)).toBe("/");
+ });
+ it("preserves a local destination and query", () => {
+ expect(safeReturnPath("/integrations?transfer=1")).toBe("/integrations?transfer=1");
+ });
+});
diff --git a/lib/auth/return-path.ts b/lib/auth/return-path.ts
new file mode 100644
index 00000000..7607ba25
--- /dev/null
+++ b/lib/auth/return-path.ts
@@ -0,0 +1,8 @@
+// Same-origin paths only. Reject browser URL normalization tricks and login loops.
+export function safeReturnPath(value: unknown): string {
+ if (typeof value !== "string" || !value.startsWith("/") || value.startsWith("//")) return "/";
+ if (/[\\\\\x00-\x20\x7f]/.test(value) || value.length > 2048) return "/";
+ const url = new URL(value, "https://mso.example.invalid");
+ if (url.origin !== "https://mso.example.invalid" || url.pathname === "/login") return "/";
+ return url.pathname + url.search + url.hash;
+}
diff --git a/lib/contracts/os-api.ts b/lib/contracts/os-api.ts
index 9cc49805..07709e79 100644
--- a/lib/contracts/os-api.ts
+++ b/lib/contracts/os-api.ts
@@ -17,7 +17,7 @@ export type FsHit = { name: string; path: string; kind: "dir" | "file" };
export type UploadFile = { relPath: string; file: File };
export type UploadResult = { written: number; failed?: string[] };
export type UploadProgress = { loaded: number; total: number };
-export type ExecResult = { stdout: string; stderr: string; code: number };
+export type ExecResult = { stdout: string; stderr: string; code: number; cwd?: string };
export type Process = { pid: number; name: string; status: string; cpu: number; mem: number };
export type ServiceScope = "system" | "user";
export type ServiceAction = "start" | "stop" | "restart";
diff --git a/lib/host/exec-cwd.test.ts b/lib/host/exec-cwd.test.ts
new file mode 100644
index 00000000..5f586f64
--- /dev/null
+++ b/lib/host/exec-cwd.test.ts
@@ -0,0 +1,37 @@
+import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
+import { promises as fs } from "node:fs";
+import os from "node:os";
+import path from "node:path";
+import { resolveCwd, runCommand } from "./exec";
+
+let dir: string;
+beforeEach(async () => {
+ dir = await fs.mkdtemp(path.join(os.tmpdir(), "mso-cwd-"));
+ vi.stubEnv("OS_FS_WRITE_ROOTS", dir);
+});
+afterEach(async () => {
+ vi.unstubAllEnvs();
+ await fs.rm(dir, { recursive: true, force: true });
+});
+describe("explicit command targets", () => {
+ it("defaults only omitted cwd and returns the actual execution directory", async () => {
+ expect(await resolveCwd()).toBe(os.homedir());
+ expect(await runCommand("pwd", dir)).toMatchObject({ code: 0, cwd: await fs.realpath(dir) });
+ });
+ it("rejects a missing directory before running a command", async () => {
+ await expect(runCommand("exit 0", path.join(dir, "missing"))).rejects.toThrow("does not exist");
+ });
+ it("rejects empty paths, files and explicit home outside writable roots", async () => {
+ await fs.writeFile(path.join(dir, "file"), "fixture");
+ await expect(resolveCwd("")).rejects.toThrow("empty");
+ await expect(resolveCwd(path.join(dir, "file"))).rejects.toThrow("not a directory");
+ await expect(resolveCwd("~")).rejects.toThrow("outside writable roots");
+ });
+ it("resolves symlinks before checking roots", async () => {
+ await fs.symlink(os.homedir(), path.join(dir, "escape"));
+ await expect(resolveCwd(path.join(dir, "escape"))).rejects.toThrow("outside writable roots");
+ await fs.mkdir(path.join(dir, "inside"));
+ await fs.symlink(path.join(dir, "inside"), path.join(dir, "alias"));
+ expect(await resolveCwd(path.join(dir, "alias"))).toBe(path.join(dir, "inside"));
+ });
+});
diff --git a/lib/host/exec-filter.test.ts b/lib/host/exec-filter.test.ts
index 55d96e69..e159c1c7 100644
--- a/lib/host/exec-filter.test.ts
+++ b/lib/host/exec-filter.test.ts
@@ -175,9 +175,8 @@ describe("runCommand", () => {
expect(res.stdout.trim()).toBe(os.homedir());
});
- it("falls back to home when the requested cwd is outside the write roots", async () => {
+ it("rejects an explicit cwd outside the write roots", async () => {
vi.stubEnv("OS_FS_WRITE_ROOTS", os.homedir());
- const res = await runCommand("pwd", "/etc");
- expect(res.stdout.trim()).toBe(os.homedir());
+ await expect(runCommand("pwd", "/etc")).rejects.toThrow("outside writable roots");
});
});
diff --git a/lib/host/exec.ts b/lib/host/exec.ts
index ce038df2..7c1a3e36 100644
--- a/lib/host/exec.ts
+++ b/lib/host/exec.ts
@@ -1,6 +1,6 @@
// SERVER-ONLY. One-shot shell runner behind /api/v1/exec/run. Non-interactive:
// captured stdout/stderr + exit code, bounded time + output. cwd is constrained
-// to the WRITE roots (falls back to home). The command itself is the
+// to the WRITE roots (explicit invalid paths fail closed). The command itself is the
// session-authenticated owner's responsibility (this is a VPS-control OS — RCE
// for the owner is the point; the gate is the signed-cookie + approved device).
import { exec } from "child_process";
@@ -30,21 +30,24 @@ export function destructiveReason(cmd: string): string | null {
return matchDestructive(cmd);
}
-// Shared with the PTY manager (pty.ts): same write-root bound, same fall-home.
+// Shared by one-shot commands, async jobs and PTYs. Only omitted cwd defaults.
export async function resolveCwd(requested?: string): Promise<string> {
const home = homeDir();
- if (!requested || requested === "~") return home;
- const absolute = requested.startsWith("~/")
+ if (requested === undefined) return home;
+ if (typeof requested !== "string" || !requested.trim()) throw new HostError("Working directory must not be empty");
+ const absolute = requested === "~" ? home : requested.startsWith("~/")
? path.join(home, requested.slice(2))
: path.resolve(requested);
let real: string;
try {
real = await fs.realpath(absolute);
+ if (!(await fs.stat(real)).isDirectory()) throw new Error("not a directory");
} catch {
- return home; // cwd gone → fall back home rather than fail the command
+ throw new HostError("Working directory does not exist or is not a directory");
}
const roots = await resolveWriteRoots();
- return roots.some((r) => isUnderRoot(real, r)) ? real : home;
+ if (!roots.some((r) => isUnderRoot(real, r))) throw new HostError("Working directory is outside writable roots");
+ return real;
}
export async function runCommand(cmd: string, cwd?: string, artifactEnv: Record<string, string> = {}): Promise<ExecResult> {
@@ -71,6 +74,7 @@ export async function runCommand(cmd: string, cwd?: string, artifactEnv: Record<
stdout: String(stdout ?? ""),
stderr: String(stderr ?? "") + (e && e.killed ? "\n[timed out after 30s]" : ""),
code,
+ cwd: dir,
});
},
);
diff --git a/lib/host/pty.ts b/lib/host/pty.ts
index d5fa30d7..2d6d2c82 100644
--- a/lib/host/pty.ts
+++ b/lib/host/pty.ts
@@ -108,7 +108,7 @@ export async function openPty(opts: {
if (live >= MAX_SESSIONS && !reclaimDetachedSlot())
throw new HostError(`Too many terminal sessions (max ${MAX_SESSIONS}) — close one first`);
- const cwd = await resolveCwd(opts.cwd); // write-root bounded, falls back home
+ const cwd = await resolveCwd(opts.cwd); // write-root bounded; explicit invalid paths fail
const shell = process.env.SHELL || "/bin/bash";
const env = childEnv(); // process.env minus the app's own secrets
env.TERM = "xterm-256color";
diff --git a/lib/infra/clients.ts b/lib/infra/clients.ts
index c5b68dce..451b74a6 100644
--- a/lib/infra/clients.ts
+++ b/lib/infra/clients.ts
@@ -1,4 +1,5 @@
-import { currentIntegrationSelection, resolveIntegration } from "./connection-service";
+import { recordConnectionCheck } from "./connection-health";
+import { credentialSnapshot, currentIntegrationSelection, resolveIntegration } from "./connection-service";
import { verifyExternalIntegration } from "./connection-external";
import { doctorAdditionalProvider } from "./additional-doctor";
import { readInfraProvider } from "./store";
@@ -13,7 +14,7 @@ export { ensureDokployProject, listDokployProjects, listDokployApplications, lis
export { upsertHostingerDns } from "./hostinger";
export { listHostingerMailOrders, getHostingerMailPlan, listHostingerMail, listHostingerMailLogs, mutateHostingerMail } from "./hostinger-mail";
-export async function doctorInfraProvider(id: InfraProviderId, candidate?: InfraProviderValues): Promise<InfraDoctorResult> {
+async function probeInfraProvider(id: InfraProviderId, candidate?: InfraProviderValues): Promise<InfraDoctorResult> {
try {
if(!candidate){
try{const route=await resolveIntegration(id,currentIntegrationSelection());if(route.source!=="direct")return { ...await verifyExternalIntegration(id,{user:route.user,connection:route.id}), id };}catch(error){if(!["connection_not_found","user_required"].includes((error as Error).message))throw error;}
@@ -30,3 +31,21 @@ export async function doctorInfraProvider(id: InfraProviderId, candidate?: Infra
return { id, ok: false, detail: (error as Error).message.slice(0, 300) };
}
}
+
+// Pin the credential revision before probing; never attribute an old request to new keys.
+export async function doctorInfraProvider(id: InfraProviderId, candidate?: InfraProviderValues): Promise<InfraDoctorResult> {
+ if (candidate) return probeInfraProvider(id, candidate);
+ const selector = currentIntegrationSelection();
+ let snapshot;
+ try {
+ const route = await resolveIntegration(id, selector);
+ if (route.source !== "direct") return probeInfraProvider(id);
+ snapshot = await credentialSnapshot(id, { user: route.user, connection: route.id });
+ } catch {
+ return probeInfraProvider(id);
+ }
+ const checkedAt = Date.now();
+ const result = await probeInfraProvider(id, snapshot.connection.values);
+ const recorded = await recordConnectionCheck(id, snapshot, result, checkedAt);
+ return recorded ? result : { id, ok: null, detail: "Connection changed during verification. Check it again." };
+}
diff --git a/lib/infra/connection-health.test.ts b/lib/infra/connection-health.test.ts
new file mode 100644
index 00000000..f13417e0
--- /dev/null
+++ b/lib/infra/connection-health.test.ts
@@ -0,0 +1,55 @@
+import { beforeEach, describe, expect, it, vi } from "vitest";
+import { emptyIntegrationState } from "./identity";
+import { createConnectionIn, saveConnectionValues } from "./connection-service";
+import { connectionSummary } from "./connection-registry";
+import { recordConnectionCheck } from "./connection-health";
+
+const fixture = vi.hoisted(() => ({ state: null as any }));
+vi.mock("./connection-storage", () => ({
+ mutateIntegrationState: async (fn: (s: any) => unknown) => fn(fixture.state),
+ readIntegrationState: async () => fixture.state,
+}));
+beforeEach(() => {
+ fixture.state = emptyIntegrationState();
+ fixture.state.users.owner = { id: "owner", uid: "owner", label: "Owner", connections: {}, defaults: {} };
+ const c = createConnectionIn(fixture.state, { user: "owner", provider: "github", connection: "test" });
+ c.values = { apiKey: "synthetic-test-key" };
+ c.verifiedAt = 10;
+});
+const current = () => fixture.state.users.owner.connections.github.test;
+const snapshot = () => ({ user: "owner", connection: structuredClone(current()) });
+describe("revision-bound connection health", () => {
+ it("replaces historical verified state after invalid access, then recovers", async () => {
+ await recordConnectionCheck("github", snapshot(), { id: "github", ok: false, detail: "GitHub HTTP 401" }, 20);
+ expect(connectionSummary("owner", current()).state).toBe("invalid");
+ expect(current().verifiedAt).toBe(10);
+ await recordConnectionCheck("github", snapshot(), { id: "github", ok: true, detail: "ok" }, 30);
+ expect(connectionSummary("owner", current()).state).toBe("verified");
+ expect(current().verifiedAt).toBe(30);
+ });
+ it("distinguishes unavailable providers and stores no raw response", async () => {
+ await recordConnectionCheck("github", snapshot(), { id: "github", ok: false, detail: "HTTP 503 secret-response" }, 20);
+ expect(connectionSummary("owner", current()).state).toBe("unavailable");
+ expect(JSON.stringify(current().lastCheck)).not.toContain("secret-response");
+ });
+ it("rejects stale results after credential rotation or connection recreation", async () => {
+ const old = snapshot();
+ current().revision++;
+ expect(await recordConnectionCheck("github", old, { id: "github", ok: true, detail: "ok" }, 20)).toBe(false);
+ current().revision = old.connection.revision;
+ current().uid = "replacement";
+ expect(await recordConnectionCheck("github", old, { id: "github", ok: true, detail: "ok" }, 20)).toBe(false);
+ });
+ it("does not let a slower older request overwrite a later check", async () => {
+ const old = snapshot();
+ await recordConnectionCheck("github", old, { id: "github", ok: false, detail: "HTTP 401" }, 30);
+ expect(await recordConnectionCheck("github", old, { id: "github", ok: true, detail: "ok" }, 20)).toBe(false);
+ expect(connectionSummary("owner", current()).state).toBe("invalid");
+ });
+ it("clears the previous check when saving a new credential revision", async () => {
+ await recordConnectionCheck("github", snapshot(), { id: "github", ok: false, detail: "HTTP 401" }, 20);
+ await saveConnectionValues("github", { user: "owner", connection: "test" }, { apiKey: "rotated-fixture" }, current());
+ expect(current().lastCheck).toBeUndefined();
+ expect(connectionSummary("owner", current()).state).toBe("verified");
+ });
+});
diff --git a/lib/infra/connection-health.ts b/lib/infra/connection-health.ts
new file mode 100644
index 00000000..0069358e
--- /dev/null
+++ b/lib/infra/connection-health.ts
@@ -0,0 +1,31 @@
+import { mutateIntegrationState } from "./connection-storage";
+import type { IntegrationConnection } from "./identity";
+import type { InfraDoctorResult } from "./types";
+
+// Persist only a bounded category, never provider payloads or credentials.
+export function checkCategory(result: InfraDoctorResult) {
+ if (result.ok === true) return "verified" as const;
+ if (result.ok === null) return "unconfigured" as const;
+ // 403 can mean insufficient scope; label invalid access, not necessarily a bad key.
+ return /\bHTTP (401|403)\b|invalid.*(?:token|credential)|token.*(?:expired|revoked)/i.test(result.detail)
+ ? "invalid" as const : "unavailable" as const;
+}
+
+export async function recordConnectionCheck(
+ provider: string,
+ snapshot: { user: string; connection: IntegrationConnection },
+ result: InfraDoctorResult,
+ checkedAt: number,
+): Promise<boolean> {
+ return mutateIntegrationState(state => {
+ const previous = snapshot.connection;
+ const current = state.users[snapshot.user]?.connections[provider]?.[previous.id];
+ if (!current || current.uid !== previous.uid || current.revision !== previous.revision) return false;
+ if (current.lastCheck && current.lastCheck.checkedAt > checkedAt) return false;
+ const category = checkCategory(result);
+ current.lastCheck = { revision: current.revision, checkedAt, result: category };
+ if (category === "verified") current.verifiedAt = checkedAt;
+ // Preserve the historic last success, but summary state always uses lastCheck.
+ return true;
+ });
+}
diff --git a/lib/infra/connection-registry.ts b/lib/infra/connection-registry.ts
index 965f7bc0..f9773832 100644
--- a/lib/infra/connection-registry.ts
+++ b/lib/infra/connection-registry.ts
@@ -30,7 +30,7 @@ export function connectionSources(provider:string){return ["direct",...(COMPOSIO
export function connectionCatalog(){return listInfraProviderDefinitions().map(p=>({id:p.id,title:p.title,description:p.description,sources:connectionSources(p.id).map(id=>({id,label:id==="direct"?"MSO direct":id==="composio"?"Composio":"Provider MCP",methods:connectionMethods(p.id,id)}))}));}
export function connectionSummary(user:string,c:IntegrationConnection,isDefault=false){
const method=connectionMethod(c.provider,c.source,c.authMethod),missing=method.fields.filter(f=>f.required&&!c.values[f.key]).map(f=>f.key);
- return {user,id:c.id,label:c.label,provider:c.provider,source:c.source,authMethod:c.authMethod,scope:c.scope,revision:c.revision,isDefault,missing,fields:method.fields.map(f=>({...f,stored:Boolean(c.values[f.key])})),state:c.source==="direct"?(missing.length?"incomplete":c.verifiedAt?"verified":"configured"):c.external?.status??"authorization-required",verifiedAt:c.verifiedAt??null,external:c.external??null};
+ return {user,id:c.id,label:c.label,provider:c.provider,source:c.source,authMethod:c.authMethod,scope:c.scope,revision:c.revision,isDefault,missing,fields:method.fields.map(f=>({...f,stored:Boolean(c.values[f.key])})),state:c.source==="direct"?(missing.length?"incomplete":c.lastCheck?.revision===c.revision?c.lastCheck.result:c.verifiedAt?"verified":"configured"):c.external?.status??"authorization-required",verifiedAt:c.verifiedAt??null,lastCheck:c.lastCheck?.revision===c.revision?c.lastCheck:null,external:c.external??null};
}
export const composioDefinition=(provider:string)=>COMPOSIO[provider];
export const nativeDefinition=(provider:string)=>NATIVE[provider];
diff --git a/lib/infra/connection-service.ts b/lib/infra/connection-service.ts
index 4341c2c6..2fb544f5 100644
--- a/lib/infra/connection-service.ts
+++ b/lib/infra/connection-service.ts
@@ -46,7 +46,7 @@ export async function saveConnectionValues(provider:string,selector:ConnectionSe
if(Object.keys(values).some(k=>!allowed.has(k)))throw new IntegrationError("invalid_credential_fields");
const normalized=normalizeInfraValues(provider,values),candidate={...c.values,...normalized};
if(method.fields.some(f=>f.required&&!candidate[f.key]))throw new IntegrationError("required_fields_missing");
- c.values=candidate;c.revision++;c.updatedAt=Date.now();if(verified)c.verifiedAt=Date.now();else delete c.verifiedAt;
+ delete c.lastCheck; c.values=candidate;c.revision++;c.updatedAt=Date.now();if(verified)c.verifiedAt=Date.now();else delete c.verifiedAt;
return summaryIn(state,r.user,c);
});
}
diff --git a/lib/infra/connection-ui-style.ts b/lib/infra/connection-ui-style.ts
index fa48f76b..831799a1 100644
--- a/lib/infra/connection-ui-style.ts
+++ b/lib/infra/connection-ui-style.ts
@@ -1,8 +1,13 @@
// Shared by the browser route and the MCP Page; theme values come from widget-tokens.
export const CONNECTION_MANAGER_STYLE = String.raw`
+.integration .provider-mark svg{width:65%;height:65%;fill:currentColor}
+.integration .integration-signin{display:inline-flex;align-items:center;min-height:44px;padding:10px 16px;margin-bottom:18px;border-radius:9px;text-decoration:none}
+.integration .identity-guide[open]{padding-bottom:12px}
+.integration .connection-state[data-ready=true]{color:var(--success-text);background:color-mix(in srgb,var(--success-text) 10%,var(--surface))}
+
.integration.manager{--integration-rail:224px;--integration-gap:24px;max-width:1180px;width:100%}
.integration .identity-heading,.integration .provider-heading,.integration .connection-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}
-.integration .identity-heading h2{margin:0}.integration .identity-heading p{margin:5px 0 0}
+.integration .identity-heading :is(h1,h2){margin:0}.integration .identity-heading p{margin:5px 0 0}
.integration .identity-count{font:600 12px var(--font-body);color:var(--text-dim);white-space:nowrap}
.integration .identity-bar{display:flex;gap:10px;align-items:end;flex-wrap:wrap;margin:22px 0}
.integration .identity-bar>label{flex:1;max-width:340px;min-width:160px;margin:0}
@@ -27,7 +32,7 @@ export const CONNECTION_MANAGER_STYLE = String.raw`
.integration .connection-card h3{margin:0;font-size:17px;overflow-wrap:anywhere}
.integration .connection-heading{align-items:start}.integration .connection-heading small{margin:3px 0 0}
.integration .connection-state{font-size:12px;line-height:1.5;border:1px solid var(--sep-strong);border-radius:99px;padding:3px 9px;white-space:nowrap}
-.integration .connection-state[data-ready=true]{color:var(--os-accent);background:color-mix(in srgb,var(--os-accent) 8%,var(--surface))}
+.integration .connection-state[data-ready=true]{color:var(--success-text);background:color-mix(in srgb,var(--success-text) 10%,var(--surface))}
.integration .identity-tags{display:flex;flex-wrap:wrap;gap:6px;margin:14px 0;color:var(--text-dim);font-size:12px}
.integration .identity-tags span+span:before{content:"·";margin-right:6px}
.integration .identity-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:16px}
diff --git a/lib/infra/connection-ui.ts b/lib/infra/connection-ui.ts
index 4c093806..7fc7b1bb 100644
--- a/lib/infra/connection-ui.ts
+++ b/lib/infra/connection-ui.ts
@@ -1,11 +1,12 @@
export { CONNECTION_MANAGER_STYLE } from "./connection-ui-style";
-export const CONNECTION_MANAGER_SCRIPT=String.raw`
+import { PROVIDER_ICON_PATHS } from "./provider-icons";
+export const CONNECTION_MANAGER_SCRIPT=`const PROVIDER_ICON_PATHS=${JSON.stringify(PROVIDER_ICON_PATHS)};`+String.raw`
function mountConnectionManager(root,catalog,bridge,initial={}){
let disposed=false,sequence=0,snapshot=initial.snapshot||{users:[],connections:[],bindings:[]},user=initial.user||snapshot.user||null,provider=catalog.find(p=>p.id===initial.provider)||catalog.find(p=>p.id==="github")||catalog[0];
let detail,status,container;
const ready=c=>c.state==="verified"||c.state==="ACTIVE";
- const stateLabel=c=>ready(c)?"Verified":c.state==="incomplete"?"Needs setup":c.state==="configured"?"Not verified":"Authorize";
- const mark=p=>n("span",p.title.split(/[^A-Za-z0-9]+/).filter(Boolean).map(s=>s[0]).join("").slice(0,2).toUpperCase(),"provider-mark");
+ const stateLabel=c=>ready(c)?"Verified":c.state==="incomplete"?"Needs setup":c.state==="configured"?"Not verified":c.state==="invalid"?"Access rejected":c.state==="unavailable"?"Check unavailable":c.state==="unconfigured"?"Needs setup":"Authorize";
+ const mark=p=>{const wrap=n("span",undefined,"provider-mark"),svg=document.createElementNS("http://www.w3.org/2000/svg","svg"),shape=document.createElementNS("http://www.w3.org/2000/svg","path");wrap.setAttribute("aria-hidden","true");svg.setAttribute("viewBox","0 0 24 24");shape.setAttribute("d",PROVIDER_ICON_PATHS[p.id]||"M8 2h8v5h5v10h-5v5H8v-5H3V7h5V2zm2 2v5H5v6h5v5h4v-5h5V9h-5V4z");svg.append(shape);wrap.append(svg);return wrap};
const human=s=>s.replaceAll("-"," ").replaceAll("_"," ");
const n=(tag,text,cls)=>{const v=integrationNode(tag,text);if(cls)v.className=cls;return v};
const b=(text,fn,cls)=>{const v=n("button",text,cls);v.type="button";v.addEventListener("click",fn);return v};
@@ -14,10 +15,10 @@ function mountConnectionManager(root,catalog,bridge,initial={}){
function remember(){if(bridge.remember)bridge.remember({user,provider:provider.id})}
async function reload(){const version=++sequence;if(!bridge.query){draw();return}try{const next=await bridge.query({view:"snapshot",...(user?{user}:{})});if(disposed||version!==sequence)return;snapshot=next;user=next.user||user;draw();remember()}catch(e){if(!disposed){draw();status.textContent=textError(e)}}}
async function change(args,after=reload){if(!bridge.manage)return;try{status.textContent="Saving connection metadata…";await bridge.manage({...args,confirm:true});await after()}catch(e){status.textContent=textError(e)}}
- function guide(method,parent=detail){const d=n("details",undefined,"identity-guide");d.open=false;d.append(n("summary","How to get this credential / authorization"));const g=method.guidance,ol=n("ol");for(const step of g.steps)ol.append(n("li",step));d.append(ol);for(const[url,label]of [[g.url,"Official setup page"],[g.reference,"Documentation"]]){const a=n("a",label);a.href=url;a.rel="noopener noreferrer";a.target="_blank";if(bridge.openLink)a.addEventListener("click",e=>{e.preventDefault();Promise.resolve(bridge.openLink(url)).catch(error=>status.textContent=textError(error))});d.append(a)}parent.append(d)}
+ function guide(method,parent=detail){const d=n("details",undefined,"identity-guide");d.open=parent!==detail;d.append(n("summary","How to get this credential / authorization"));const g=method.guidance,ol=n("ol");for(const step of g.steps)ol.append(n("li",step));d.append(ol);for(const[url,label]of [[g.url,"Official setup page"],[g.reference,"Documentation"]]){const a=n("a",label);a.href=url;a.rel="noopener noreferrer";a.target="_blank";if(bridge.openLink)a.addEventListener("click",e=>{e.preventDefault();Promise.resolve(bridge.openLink(url)).catch(error=>status.textContent=textError(error))});d.append(a)}parent.append(d)}
function draw(){
root.replaceChildren();root.classList.add("integration","manager");
- const heading=n("header",undefined,"identity-heading"),title=n("div");title.append(n("h2","Integrations"),n("p","Connect your services. Choose the account each project uses."));heading.append(title,n("span",catalog.length+" services","identity-count"));root.append(heading);
+ const heading=n("header",undefined,"identity-heading"),title=n("div");title.append(n(bridge.headingLevel===1?"h1":"h2","Integrations"),n("p","Connect your services. Choose the account each project uses."));heading.append(title,n("span",catalog.length+" services","identity-count"));root.append(heading);
const toolbar=n("div",undefined,"identity-bar"),label=n("label","Credential owner"),select=n("select");select.setAttribute("aria-label","Credential owner");const placeholder=n("option","Choose a user");placeholder.value="";select.append(placeholder);
for(const row of snapshot.users){const o=n("option",row.label+" ("+row.id+")"+(row.isDefault?" · default":""));o.value=row.id;select.append(o)}select.value=user||"";select.addEventListener("change",()=>{user=select.value||null;remember();void reload()});label.append(select);toolbar.append(label,b("Refresh",reload));const tools=n("details",undefined,"identity-tools"),toolActions=n("div",undefined,"identity-actions");tools.append(n("summary","Settings"));toolActions.append(b("Manage users",profiles),b("Folder bindings",bindings));const transfer=b("Import / export JSON",()=>bridge.openTransfer?bridge.openTransfer():bridge.openTransferBrowser?.());transfer.disabled=!bridge.openTransfer&&!bridge.openTransferBrowser;toolActions.append(transfer);tools.append(toolActions);toolbar.append(tools);root.append(toolbar);
if(!bridge.manage)root.append(n("p","Sign in as an MSO Owner to manage credentials. Device roles and credential users are different; the public guides remain available.","identity-readonly"));
@@ -47,16 +48,16 @@ function mountConnectionManager(root,catalog,bridge,initial={}){
}
function drawProvider(){
detail.replaceChildren();const heading=n("header",undefined,"provider-heading"),title=n("div",undefined,"provider-title"),copy=n("div");copy.append(n("h2",provider.title),n("p",provider.description));title.append(mark(provider),copy);heading.append(title);detail.append(heading);
- const create=b("New connection",newConnection,"primary");create.disabled=!user||!bridge.manage;heading.append(create);
+ const create=b("New connection",newConnection,"primary");create.disabled=!user||!bridge.manage;if(bridge.manage)heading.append(create);
const rows=snapshot.connections.filter(c=>c.provider===provider.id);
- if(!rows.length){const empty=n("div",undefined,"identity-empty");empty.append(n("h3","Connect "+provider.title),n("p",user?"Add an account to start using "+provider.title+" in your projects.":"Select a credential owner to add an account."));const start=b("Add "+provider.title+" account",newConnection,"primary");start.disabled=!user||!bridge.manage;empty.append(start);detail.append(empty);const help=n("details");help.append(n("summary","Connection methods & setup guides"));for(const s of provider.sources)for(const m of s.methods){const info=n("section");info.append(n("h3",s.label+" · "+m.label));guide(m,info);help.append(info)}detail.append(help)}
+ if(!rows.length){const empty=n("div",undefined,"identity-empty");empty.append(n("h3","Connect "+provider.title),n("p",user?"Add an account to start using "+provider.title+" in your projects.":bridge.manage?"Select a credential owner to add an account.":"Read the setup guide below, then sign in to connect your account."));const start=b("Add "+provider.title+" account",newConnection,"primary");start.disabled=!user||!bridge.manage;if(bridge.manage)empty.append(start);detail.append(empty);const help=n("details");help.append(n("summary","Connection methods & setup guides"));for(const s of provider.sources)for(const m of s.methods){const info=n("section");info.append(n("h3",s.label+" · "+m.label));guide(m,info);help.append(info)}detail.append(help)}
for(const c of rows){const card=n("article",undefined,"connection-card");const top=n("header",undefined,"connection-heading"),name=n("div");name.append(n("h3",c.label),n("small",c.id));const state=n("span",stateLabel(c),"connection-state");state.dataset.ready=String(ready(c));top.append(name,state);card.append(top);const tags=n("div",undefined,"identity-tags");for(const value of [human(c.source),human(c.authMethod),c.isDefault?"Default account":""])if(value)tags.append(n("span",value));card.append(tags);const actions=n("div",undefined,"identity-actions"),more=n("details",undefined,"identity-tools"),secondary=n("div",undefined,"identity-actions");more.append(n("summary","More"));more.append(secondary);
const open=b(c.source==="direct"?(c.fields.some(f=>f.stored)?"Update credentials":"Finish setup"):"Authorize",()=>{if(c.source==="direct")void bridge.openSetup({user,provider:provider.id,connection:c.id}).catch(e=>status.textContent=textError(e));else external(c)});open.disabled=!bridge.manage;actions.append(open);
- const verify=b("Verify",async()=>{try{status.textContent="Checking selected connection…";const result=await bridge.execute({user,provider:provider.id,connection:c.id,operation:"verify"});status.textContent=(result.ok===true?"Verified: ":"Status: ")+result.detail}catch(e){status.textContent=textError(e)}});verify.disabled=!bridge.execute;actions.append(verify);
+ const verify=b("Verify",async()=>{try{status.textContent="Checking selected connection…";const result=await bridge.execute({user,provider:provider.id,connection:c.id,operation:"verify"});await reload();status.textContent=(result.ok===true?"Verified: ":"Status: ")+result.detail}catch(e){status.textContent=textError(e)}});verify.disabled=!bridge.execute;actions.append(verify);
const rename=b("Rename",()=>{detail.replaceChildren(n("h2","Rename connection"));const name=input("Label",c.label);detail.append(name.label,b("Save label",()=>change({action:"connection.rename",user,provider:provider.id,connection:c.id,label:name.input.value})),b("Cancel",drawProvider))});rename.disabled=!bridge.manage;secondary.append(rename);
if(c.source==="direct"&&c.fields.some(f=>f.stored)){const clear=b("Clear credentials",()=>confirmation("Clear this connection's credential fields",c.id,()=>change({action:"credential.delete",user,provider:provider.id,connection:c.id})),"danger");clear.disabled=!bridge.manage;secondary.append(clear)}
if(!c.isDefault){const def=b("Make default",()=>change({action:"connection.default",user,provider:provider.id,connection:c.id}));def.disabled=!bridge.manage;secondary.append(def)}
- const del=b("Delete",()=>confirmation("Delete named connection",c.id,()=>change({action:"connection.delete",user,provider:provider.id,connection:c.id})),"danger");del.disabled=!bridge.manage;secondary.append(del);actions.append(more);card.append(actions);if(c.verifiedAt)card.append(n("small","Last verified "+new Date(c.verifiedAt).toLocaleString()));detail.append(card);
+ const del=b("Delete",()=>confirmation("Delete named connection",c.id,()=>change({action:"connection.delete",user,provider:provider.id,connection:c.id})),"danger");del.disabled=!bridge.manage;secondary.append(del);actions.append(more);card.append(actions);if(c.lastCheck)card.append(n("small","Last checked "+new Date(c.lastCheck.checkedAt).toLocaleString()+" · "+stateLabel(c)));else if(c.verifiedAt)card.append(n("small","Last verified "+new Date(c.verifiedAt).toLocaleString()));detail.append(card);
}
}
function newConnection(){
@@ -71,7 +72,7 @@ function mountConnectionManager(root,catalog,bridge,initial={}){
detail.replaceChildren(n("h2",c.label),n("p",user+" / "+provider.id+" / "+c.source+" / "+c.authMethod));const method=provider.sources.find(s=>s.id===c.source).methods.find(m=>m.id===c.authMethod);guide(method);
if(c.source==="native-mcp"){detail.append(n("p","Authorize in the provider's own MCP client. MSO will return this route, never substitute a stored API key."),b("Back",drawProvider));return}
const broker=input("Composio project connection ID",c.external?.brokerConnection||""),config=input("Auth config ID (when several exist)",c.external?.authConfigId||""),managed=input("","","checkbox");managed.label.className="identity-check";managed.label.append(document.createTextNode("Allow creation of a managed OAuth config if none exists"));detail.append(broker.label,config.label,managed.label);
- const authorize=b("Open hosted authorization",async()=>{try{authorize.disabled=true;const result=await bridge.manage({action:"connection.authorize",confirm:true,user,provider:provider.id,connection:c.id,...(broker.input.value?{brokerConnection:broker.input.value}:{}),...(config.input.value?{authConfigId:config.input.value}:{}),createManaged:managed.input.checked});if(result.privateUrl){const a=n("a","Continue on Composio");a.href=result.privateUrl;a.rel="noopener noreferrer";a.target="_blank";a.addEventListener("click",e=>{if(bridge.openLink){e.preventDefault();bridge.openLink(result.privateUrl)}});detail.append(a)}status.textContent="Authorization pending. Complete the provider flow, then refresh status."}catch(e){status.textContent=textError(e);authorize.disabled=false}});authorize.disabled=Boolean(c.external?.connectedAccountId);detail.append(authorize,b("Refresh authorization status",async()=>{try{const result=await bridge.execute({user,provider:provider.id,connection:c.id,operation:"verify"});status.textContent=result.detail}catch(e){status.textContent=textError(e)}}),b("Back",drawProvider));
+ const authorize=b("Open hosted authorization",async()=>{try{authorize.disabled=true;const result=await bridge.manage({action:"connection.authorize",confirm:true,user,provider:provider.id,connection:c.id,...(broker.input.value?{brokerConnection:broker.input.value}:{}),...(config.input.value?{authConfigId:config.input.value}:{}),createManaged:managed.input.checked});if(result.privateUrl){const a=n("a","Continue on Composio");a.href=result.privateUrl;a.rel="noopener noreferrer";a.target="_blank";a.addEventListener("click",e=>{if(bridge.openLink){e.preventDefault();bridge.openLink(result.privateUrl)}});detail.append(a)}status.textContent="Authorization pending. Complete the provider flow, then refresh status."}catch(e){status.textContent=textError(e);authorize.disabled=false}});authorize.disabled=Boolean(c.external?.connectedAccountId);detail.append(authorize,b("Refresh authorization status",async()=>{try{const result=await bridge.execute({user,provider:provider.id,connection:c.id,operation:"verify"});await reload();status.textContent=result.detail}catch(e){status.textContent=textError(e)}}),b("Back",drawProvider));
}
draw();if(bridge.query)void reload();
return()=>{disposed=true;sequence++;root.replaceChildren();root.classList.remove("integration","manager")};
diff --git a/lib/infra/identity.ts b/lib/infra/identity.ts
index 07527d92..074d1a93 100644
--- a/lib/infra/identity.ts
+++ b/lib/infra/identity.ts
@@ -8,7 +8,8 @@ export type ExternalIdentity = { toolkit?: string; connectedAccountId?: string;
export type IntegrationConnection = {
id: string; uid: string; label: string; provider: string; source: ConnectionSource; authMethod: string;
scope: string; revision: number; values: Record<string,string>; external?: ExternalIdentity;
- createdAt: number; updatedAt: number; verifiedAt?: number; lease?: {id:string;until:number};
+ createdAt: number; updatedAt: number; verifiedAt?: number;
+ lastCheck?: { revision: number; checkedAt: number; result: "verified" | "invalid" | "unavailable" | "unconfigured" }; lease?: {id:string;until:number};
};
export type IntegrationUser = { id: string; uid:string; label: string; connections: Record<string, Record<string, IntegrationConnection>>; defaults: Record<string, string> };
export type IntegrationBinding = { path: string; user: string; connections: Record<string, string> };
diff --git a/lib/infra/provider-icons.ts b/lib/infra/provider-icons.ts
new file mode 100644
index 00000000..dc5d15ad
--- /dev/null
+++ b/lib/infra/provider-icons.ts
@@ -0,0 +1,15 @@
+// Provider SVG paths from Simple Icons (CC0); brand trademarks remain with their owners.
+// Source: https://github.com/simple-icons/simple-icons
+export const PROVIDER_ICON_PATHS: Record<string, string> = {
+ "github": "M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12",
+ "cloudflare": "M16.5088 16.8447c.1475-.5068.0908-.9707-.1553-1.3154-.2246-.3164-.6045-.499-1.0615-.5205l-8.6592-.1123a.1559.1559 0 0 1-.1333-.0713c-.0283-.042-.0351-.0986-.021-.1553.0278-.084.1123-.1484.2036-.1562l8.7359-.1123c1.0351-.0489 2.1601-.8868 2.5537-1.9136l.499-1.3013c.0215-.0561.0293-.1128.0147-.168-.5625-2.5463-2.835-4.4453-5.5499-4.4453-2.5039 0-4.6284 1.6177-5.3876 3.8614-.4927-.3658-1.1187-.5625-1.794-.499-1.2026.119-2.1665 1.083-2.2861 2.2856-.0283.31-.0069.6128.0635.894C1.5683 13.171 0 14.7754 0 16.752c0 .1748.0142.3515.0352.5273.0141.083.0844.1475.1689.1475h15.9814c.0909 0 .1758-.0645.2032-.1553l.12-.4268zm2.7568-5.5634c-.0771 0-.1611 0-.2383.0112-.0566 0-.1054.0415-.127.0976l-.3378 1.1744c-.1475.5068-.0918.9707.1543 1.3164.2256.3164.6055.498 1.0625.5195l1.8437.1133c.0557 0 .1055.0263.1329.0703.0283.043.0351.1074.0214.1562-.0283.084-.1132.1485-.204.1553l-1.921.1123c-1.041.0488-2.1582.8867-2.5527 1.914l-.1406.3585c-.0283.0713.0215.1416.0986.1416h6.5977c.0771 0 .1474-.0489.169-.126.1122-.4082.1757-.837.1757-1.2803 0-2.6025-2.125-4.727-4.7344-4.727",
+ "hostinger": "M16.415 0v7.16l5.785 3.384V2.949L16.415 0ZM1.8 0v11.237h18.815L14.89 8.09l-7.457-.003V3.024L1.8 0Zm14.615 20.894v-5.019l-7.514-.005c.007.033-5.82-3.197-5.82-3.197l19.119.091V24l-5.785-3.106ZM1.8 13.551v7.343l5.633 2.949v-6.988L1.8 13.551Z",
+ "vercel": "m12 1.608 12 20.784H0Z",
+ "convex-cloud": "M15.09 18.916c3.488-.387 6.776-2.246 8.586-5.348-.857 7.673-9.247 12.522-16.095 9.545a3.47 3.47 0 0 1-1.547-1.314c-1.539-2.417-2.044-5.492-1.318-8.282 2.077 3.584 6.3 5.78 10.374 5.399m-10.501-7.65c-1.414 3.266-1.475 7.092.258 10.24-6.1-4.59-6.033-14.41-.074-18.953a3.44 3.44 0 0 1 1.893-.707c2.825-.15 5.695.942 7.708 2.977-4.09.04-8.073 2.66-9.785 6.442m11.757-5.437C14.283 2.951 11.053.992 7.515.933c6.84-3.105 15.253 1.929 16.17 9.37a3.6 3.6 0 0 1-.334 2.02c-1.278 2.594-3.647 4.607-6.416 5.352 2.029-3.763 1.778-8.36-.589-11.847",
+ "convex": "M15.09 18.916c3.488-.387 6.776-2.246 8.586-5.348-.857 7.673-9.247 12.522-16.095 9.545a3.47 3.47 0 0 1-1.547-1.314c-1.539-2.417-2.044-5.492-1.318-8.282 2.077 3.584 6.3 5.78 10.374 5.399m-10.501-7.65c-1.414 3.266-1.475 7.092.258 10.24-6.1-4.59-6.033-14.41-.074-18.953a3.44 3.44 0 0 1 1.893-.707c2.825-.15 5.695.942 7.708 2.977-4.09.04-8.073 2.66-9.785 6.442m11.757-5.437C14.283 2.951 11.053.992 7.515.933c6.84-3.105 15.253 1.929 16.17 9.37a3.6 3.6 0 0 1-.334 2.02c-1.278 2.594-3.647 4.607-6.416 5.352 2.029-3.763 1.778-8.36-.589-11.847",
+ "resend": "M14.679 0c4.648 0 7.413 2.765 7.413 6.434s-2.765 6.434-7.413 6.434H12.33L24 24h-8.245l-8.88-8.44c-.636-.588-.93-1.273-.93-1.86 0-.831.587-1.565 1.713-1.883l4.574-1.224c1.737-.465 2.936-1.81 2.936-3.572 0-2.153-1.761-3.4-3.939-3.4H0V0z",
+ "stripe": "M13.976 9.15c-2.172-.806-3.356-1.426-3.356-2.409 0-.831.683-1.305 1.901-1.305 2.227 0 4.515.858 6.09 1.631l.89-5.494C18.252.975 15.697 0 12.165 0 9.667 0 7.589.654 6.104 1.872 4.56 3.147 3.757 4.992 3.757 7.218c0 4.039 2.467 5.76 6.476 7.219 2.585.92 3.445 1.574 3.445 2.583 0 .98-.84 1.545-2.354 1.545-1.875 0-4.965-.921-6.99-2.109l-.9 5.555C5.175 22.99 8.385 24 11.714 24c2.641 0 4.843-.624 6.328-1.813 1.664-1.305 2.525-3.236 2.525-5.732 0-4.128-2.524-5.851-6.594-7.305h.003z",
+ "clerk": "m21.47 20.829-2.881-2.881a.572.572 0 0 0-.7-.084 6.854 6.854 0 0 1-7.081 0 .576.576 0 0 0-.7.084l-2.881 2.881a.576.576 0 0 0-.103.69.57.57 0 0 0 .166.186 12 12 0 0 0 14.113 0 .58.58 0 0 0 .239-.423.576.576 0 0 0-.172-.453Zm.002-17.668-2.88 2.88a.569.569 0 0 1-.701.084A6.857 6.857 0 0 0 8.724 8.08a6.862 6.862 0 0 0-1.222 3.692 6.86 6.86 0 0 0 .978 3.764.573.573 0 0 1-.083.699l-2.881 2.88a.567.567 0 0 1-.864-.063A11.993 11.993 0 0 1 6.771 2.7a11.99 11.99 0 0 1 14.637-.405.566.566 0 0 1 .232.418.57.57 0 0 1-.168.448Zm-7.118 12.261a3.427 3.427 0 1 0 0-6.854 3.427 3.427 0 0 0 0 6.854Z",
+ "supabase": "M11.9 1.036c-.015-.986-1.26-1.41-1.874-.637L.764 12.05C-.33 13.427.65 15.455 2.409 15.455h9.579l.113 7.51c.014.985 1.259 1.408 1.873.636l9.262-11.653c1.093-1.375.113-3.403-1.645-3.403h-9.642z",
+ "mcp": "M13.85 0a4.16 4.16 0 0 0-2.95 1.217L1.456 10.66a.835.835 0 0 0 0 1.18.835.835 0 0 0 1.18 0l9.442-9.442a2.49 2.49 0 0 1 3.541 0 2.49 2.49 0 0 1 0 3.541L8.59 12.97l-.1.1a.835.835 0 0 0 0 1.18.835.835 0 0 0 1.18 0l.1-.098 7.03-7.034a2.49 2.49 0 0 1 3.542 0l.049.05a2.49 2.49 0 0 1 0 3.54l-8.54 8.54a1.96 1.96 0 0 0 0 2.755l1.753 1.753a.835.835 0 0 0 1.18 0 .835.835 0 0 0 0-1.18l-1.753-1.753a.266.266 0 0 1 0-.394l8.54-8.54a4.185 4.185 0 0 0 0-5.9l-.05-.05a4.16 4.16 0 0 0-2.95-1.218c-.2 0-.401.02-.6.048a4.17 4.17 0 0 0-1.17-3.552A4.16 4.16 0 0 0 13.85 0m0 3.333a.84.84 0 0 0-.59.245L6.275 10.56a4.186 4.186 0 0 0 0 5.902 4.186 4.186 0 0 0 5.902 0L19.16 9.48a.835.835 0 0 0 0-1.18.835.835 0 0 0-1.18 0l-6.985 6.984a2.49 2.49 0 0 1-3.54 0 2.49 2.49 0 0 1 0-3.54l6.983-6.985a.835.835 0 0 0 0-1.18.84.84 0 0 0-.59-.245"
+};
diff --git a/lib/infra/setup-browser.ts b/lib/infra/setup-browser.ts
index eb8c5a2c..29472e7c 100644
--- a/lib/infra/setup-browser.ts
+++ b/lib/infra/setup-browser.ts
@@ -12,7 +12,7 @@ export const INTEGRATION_BROWSER_SCRIPT=String.raw`
async function loadManager(){
cleanup();authController?.abort();authController=new AbortController();
let owner=false;try{const auth=await json("/api/auth/me",{signal:authController.signal});owner=auth.role==="owner"}catch{}
- const bridge={remember:s=>state=s,openLink:url=>window.open(url,"_blank","noopener,noreferrer")};
+ const bridge={headingLevel:1,remember:s=>state=s,openLink:url=>window.open(url,"_blank","noopener,noreferrer")};
if(owner){
bridge.openTransfer=openTransfer;
bridge.query=args=>json("/api/v1/integrations?"+new URLSearchParams(args));
@@ -21,7 +21,7 @@ export const INTEGRATION_BROWSER_SCRIPT=String.raw`
}
if(owner&&wantsTransfer){openTransfer();return}
cleanup=mountConnectionManager(root,INTEGRATIONS_CATALOG,bridge,state);
- if(!owner){const link=integrationNode("a","Sign in to MSO as Owner");link.href="/";link.target="_blank";link.rel="noopener noreferrer";root.prepend(link);const refresh=()=>{if(document.visibilityState!=="hidden")void loadManager()};document.addEventListener("visibilitychange",refresh,{signal:authController.signal});window.addEventListener("focus",refresh,{signal:authController.signal});}
+ if(!owner){const link=integrationNode("a","Sign in to MSO as Owner");link.href="/login?returnTo=%2Fintegrations";link.className="primary integration-signin";link.target="_blank";link.rel="noopener noreferrer";root.prepend(link);const refresh=()=>{if(document.visibilityState!=="hidden")void loadManager()};document.addEventListener("visibilitychange",refresh,{signal:authController.signal});window.addEventListener("focus",refresh,{signal:authController.signal});}
}
window.addEventListener("pagehide",()=>{cleanup();authController?.abort()},{once:true});
let token=location.hash.slice(1);history.replaceState(null,"",location.pathname);
diff --git a/lib/mcp/integration-setup.test.ts b/lib/mcp/integration-setup.test.ts
index 41161c3a..b3ba382d 100644
--- a/lib/mcp/integration-setup.test.ts
+++ b/lib/mcp/integration-setup.test.ts
@@ -20,7 +20,7 @@ describe("MCP integration setup privacy", () => {
it("requires write scope, accepts no credential parameters, and uses the existing Page", () => {
const tool = SURFACE_TOOLS.find(t => t.name === "integration_setup_open")!;
expect(tool.scope).toBe("write"); expect(Object.keys(tool.inputSchema.properties)).toEqual(["user", "connection", "provider", "method"]);
- expect((tool.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v10\.html$/);
+ expect((tool.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v11\.html$/);
expect(tool.meta?.["openai/outputTemplate"]).toBeUndefined();
expect(resolveSurfaceRoute("/integrations").kind).toBe("integrations");
expect(() => new Function(MSO_SURFACE_SCRIPT)).not.toThrow();
diff --git a/lib/mcp/local-agent-two-way.test.ts b/lib/mcp/local-agent-two-way.test.ts
index c45a4545..d125f00f 100644
--- a/lib/mcp/local-agent-two-way.test.ts
+++ b/lib/mcp/local-agent-two-way.test.ts
@@ -83,9 +83,10 @@ describe("two-way Local Agent MCP receive", () => {
});
it("preserves immediate reads when wait_ms is omitted", async () => {
- const startedAt = Date.now();
+ const subscribe = vi.spyOn(events, "subscribeLocalAgentMessages");
const response = await dispatch(call("local_agent_inbox"), "read", "mcp:a", { principal, sessionId: a.id });
- expect(Date.now() - startedAt).toBeLessThan(500);
+ expect(subscribe).not.toHaveBeenCalled();
+ subscribe.mockRestore();
expect(Array.isArray(textResult<unknown[]>(response))).toBe(true);
});
});
diff --git a/lib/mcp/privacy-portability.test.ts b/lib/mcp/privacy-portability.test.ts
index 89ccf797..d3600a37 100644
--- a/lib/mcp/privacy-portability.test.ts
+++ b/lib/mcp/privacy-portability.test.ts
@@ -1,10 +1,14 @@
-import { afterEach, describe, expect, it, vi } from "vitest";
+import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
const reset = () => {
vi.unstubAllEnvs();
vi.resetModules();
};
afterEach(reset);
+beforeEach(() => {
+ vi.stubEnv("OS_MCP_UI_ORIGIN", "");
+ vi.stubEnv("MSO_SURFACE_APPS_JSON", "");
+});
describe("portable public MCP configuration", () => {
it("derives safe public and sibling widget origins", async () => {
@@ -92,3 +96,29 @@ describe("portable public MCP configuration", () => {
);
});
});
+
+
+describe("two independent instance presentations", () => {
+ it("does not mix origins, app catalogs, resource HTML or CSP between instances", async () => {
+ const outputs: string[] = [];
+ for (const id of ["alpha", "beta"]) {
+ vi.resetModules();
+ vi.stubEnv("OS_PUBLIC_ORIGIN", `https://mso.${id}.example.test`);
+ vi.stubEnv("OS_MCP_UI_ORIGIN", `https://widgets.${id}.example.test`);
+ vi.stubEnv("MSO_SURFACE_APPS_JSON", JSON.stringify([{
+ id, title: id, description: id, origin: `https://app.${id}.example.test`,
+ startPath: "/embed", renderer: "iframe", presentation: "inline", environment: "preview",
+ }]));
+ const { readUiResource, MSO_PAGE_URI } = await import("./ui-resources");
+ const { publicSurfaceApps, surfaceFrameDomains } = await import("./surface-catalog");
+ expect(publicSurfaceApps().map(app => app.id)).toEqual([id]);
+ expect(surfaceFrameDomains()).toEqual([`https://app.${id}.example.test`]);
+ const serialized = JSON.stringify(readUiResource(MSO_PAGE_URI));
+ expect(serialized).toContain(`widgets.${id}.example.test`);
+ expect(serialized).toContain(`mso.${id}.example.test`);
+ outputs.push(serialized);
+ }
+ expect(outputs[0]).not.toContain("beta.example.test");
+ expect(outputs[1]).not.toContain("alpha.example.test");
+ });
+});
diff --git a/lib/mcp/tools-surface.test.ts b/lib/mcp/tools-surface.test.ts
index d245cfdd..744bfd33 100644
--- a/lib/mcp/tools-surface.test.ts
+++ b/lib/mcp/tools-surface.test.ts
@@ -39,7 +39,7 @@ describe("MSO Page MCP tools", () => {
url: "https://demo.example.test/embed",
});
expect(result.app).not.toHaveProperty("sandbox");
- expect((render.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v10\.html$/);
+ expect((render.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v11\.html$/);
expect(render.meta?.["openai/outputTemplate"]).toBeUndefined();
});
@@ -58,7 +58,7 @@ describe("MSO Page MCP tools", () => {
it("uses only the standard resource binding for Page tools", () => {
for (const name of ["render_mso_page", "integration_setup_open"] as const) {
const value = tool(name);
- expect((value.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v10\.html$/);
+ expect((value.meta?.ui as { resourceUri?: string }).resourceUri).toMatch(/^ui:\/\/mso\/page-v11\.html$/);
expect(value.meta?.["openai/outputTemplate"]).toBeUndefined();
}
});
diff --git a/lib/mcp/toolset.ts b/lib/mcp/toolset.ts
index 85449351..15464cf2 100644
--- a/lib/mcp/toolset.ts
+++ b/lib/mcp/toolset.ts
@@ -3,9 +3,9 @@ import type { Scope } from "./scope";
import type { McpTool } from "./tool-kit";
import { toolDescriptor, type McpToolProfile } from "./tool-contract";
-export const MCP_SERVER_VERSION = "1.12.2";
-export const MCP_TOOLSET_VERSION = "2026.09.07.1";
-export const MCP_TOOLSET_CHANGED_AT = "2026-09-07T19:40:00Z";
+export const MCP_SERVER_VERSION = "1.12.3";
+export const MCP_TOOLSET_VERSION = "2026.09.09.1";
+export const MCP_TOOLSET_CHANGED_AT = "2026-09-09T05:55:00Z";
export type McpToolsetInfo = {
serverVersion: string;
diff --git a/lib/mcp/ui-page-lifecycle.test.ts b/lib/mcp/ui-page-lifecycle.test.ts
index dd91772f..0709902b 100644
--- a/lib/mcp/ui-page-lifecycle.test.ts
+++ b/lib/mcp/ui-page-lifecycle.test.ts
@@ -1,10 +1,11 @@
import { inlineScripts } from "../../scripts/test-support/inline-scripts";
import { describe, expect, it } from "vitest";
-import { LEGACY_PAGE_V2_URI, LEGACY_PAGE_V3_URI, LEGACY_PAGE_V9_URI, MSO_PAGE_URI, listUiResources, readUiResource } from "./ui-resources";
+import { LEGACY_PAGE_V10_URI, LEGACY_PAGE_V2_URI, LEGACY_PAGE_V3_URI, LEGACY_PAGE_V9_URI, MSO_PAGE_URI, listUiResources, readUiResource } from "./ui-resources";
describe("MCP Page lifecycle and cached resource migration", () => {
it("serves current bytes to cached v2 clients without advertising a third UI", () => {
const page = readUiResource(MSO_PAGE_URI);
+ expect(readUiResource(LEGACY_PAGE_V10_URI)).toMatchObject({ uri: LEGACY_PAGE_V10_URI, text: page?.text });
expect(readUiResource(LEGACY_PAGE_V2_URI)).toMatchObject({ uri: LEGACY_PAGE_V2_URI, text: page?.text });
expect(readUiResource(LEGACY_PAGE_V3_URI)).toMatchObject({ uri: LEGACY_PAGE_V3_URI, text: page?.text });
expect(readUiResource(LEGACY_PAGE_V9_URI)).toMatchObject({ uri: LEGACY_PAGE_V9_URI, text: page?.text });
diff --git a/lib/mcp/ui-resources.test.ts b/lib/mcp/ui-resources.test.ts
index db838025..0049e5db 100644
--- a/lib/mcp/ui-resources.test.ts
+++ b/lib/mcp/ui-resources.test.ts
@@ -1,7 +1,11 @@
import { inlineScripts } from "../../scripts/test-support/inline-scripts";
-import { describe, expect, it, vi } from "vitest";
+import { afterAll, describe, expect, it, vi } from "vitest";
vi.mock("server-only", () => ({}));
+vi.stubEnv("OS_PUBLIC_ORIGIN", "https://mso.example.test");
+vi.stubEnv("OS_MCP_UI_ORIGIN", "");
+vi.stubEnv("MSO_SURFACE_APPS_JSON", "");
+afterAll(() => vi.unstubAllEnvs());
const { dispatch } = await import("./dispatch");
const {
@@ -157,7 +161,7 @@ describe("MCP Apps Block and Page contract", () => {
});
expect(content._meta.ui.csp.frameDomains).toBeUndefined();
expect(content._meta["openai/widgetCSP"]).toEqual({ connect_domains: [MSO_ORIGIN], redirect_domains: [MSO_ORIGIN] });
- expect(MSO_PAGE_URI).toContain("page-v10.html");
+ expect(MSO_PAGE_URI).toContain("page-v11.html");
});
it("returns only redacted structured workflow state and keeps status polling out of workflow memory", async () => {
diff --git a/lib/mcp/ui-resources.ts b/lib/mcp/ui-resources.ts
index 845732ca..746f51d1 100644
--- a/lib/mcp/ui-resources.ts
+++ b/lib/mcp/ui-resources.ts
@@ -8,6 +8,7 @@ export const MCP_APP_MIME_TYPE = "text/html;profile=mcp-app";
// across the UI-contract migration. They are intentionally not advertised by
// resources/list: the public product contract has exactly Block and Page.
export const LEGACY_BLOCK_V1_URI = "ui://mso/block-v1.html";
+export const LEGACY_PAGE_V10_URI = "ui://mso/page-v10.html";
export const LEGACY_PAGE_V9_URI = "ui://mso/page-v9.html";
export const LEGACY_PAGE_V8_URI = "ui://mso/page-v8.html";
export const LEGACY_PAGE_V7_URI = "ui://mso/page-v7.html";
@@ -31,6 +32,7 @@ export type McpUiResource = {
const RESOURCES: readonly McpUiResource[] = [MSO_BLOCK_RESOURCE, MSO_PAGE_RESOURCE];
const LEGACY_ALIASES = new Map<string, McpUiResource>([
+ [LEGACY_PAGE_V10_URI, MSO_PAGE_RESOURCE],
[LEGACY_PAGE_V9_URI, MSO_PAGE_RESOURCE],
[LEGACY_PAGE_V8_URI, MSO_PAGE_RESOURCE],
[LEGACY_PAGE_V7_URI, MSO_PAGE_RESOURCE],
diff --git a/lib/mcp/ui-surface.ts b/lib/mcp/ui-surface.ts
index bcf02ea6..e571d9e4 100644
--- a/lib/mcp/ui-surface.ts
+++ b/lib/mcp/ui-surface.ts
@@ -6,7 +6,7 @@ import { surfaceFrameDomains } from "./surface-catalog";
import { MSO_SURFACE_SCRIPT } from "./ui-surface-script";
import { MSO_SURFACE_STYLE } from "./ui-surface-style";
-export const MSO_PAGE_URI = "ui://mso/page-v10.html";
+export const MSO_PAGE_URI = "ui://mso/page-v11.html";
const MIME = "text/html;profile=mcp-app";
const html = String.raw`<main class="surface" aria-label="MSO Page">
diff --git a/lib/presentation/widget-tokens.ts b/lib/presentation/widget-tokens.ts
index 76b2be3e..552b9a46 100644
--- a/lib/presentation/widget-tokens.ts
+++ b/lib/presentation/widget-tokens.ts
@@ -1,7 +1,7 @@
/**
* Shared visual contract for ChatGPT Block and Page resources.
*
- * Core values mirror rahmanef.com/app/globals.css. The widget keeps its own
+ * Core values follow the MSO presentation palette. The widget keeps its own
* small presentation aliases, but the public brand palette stays single-source.
*/
const DARK_TOKENS = String.raw`
@@ -23,6 +23,7 @@ const DARK_TOKENS = String.raw`
--warning:#ff9f0a;
--info:#409cff;
--destructive-text:#ff5f57;
+--success-text:#65d486;
`;
export const MSO_WIDGET_TOKENS = String.raw`
@@ -46,6 +47,7 @@ color-scheme:light;
--inset:rgba(0,0,0,.04);
--shadow-pop:0 0 0 .5px rgba(0,0,0,.12),0 14px 38px -8px rgba(0,0,0,.32);
--success:#34c759;
+--success-text:#176e32;
--warning:#ff9500;
--info:#0060df;
--destructive-text:#d70015;
diff --git a/next.config.mjs b/next.config.mjs
index 65bcba5f..59567cde 100644
--- a/next.config.mjs
+++ b/next.config.mjs
@@ -106,7 +106,7 @@ const nextConfig = {
// Authenticated remote shell over HTTPS — refuse any plaintext leg so
// a MITM can't strip TLS and capture the session cookie before the
// redirect fires. 1 year. includeSubDomains omitted on purpose: not
- // every rahmanef.com subdomain is HTTPS-only.
+ // every configured cookie-domain subdomain is HTTPS-only.
{ key: "Strict-Transport-Security", value: "max-age=31536000" },
{ key: "Referrer-Policy", value: "strict-origin-when-cross-origin" },
// MSO is a private control plane even when reached through a temporary HTTPS tunnel.
diff --git a/package.json b/package.json
index c7ea5063..a86901b0 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "mso",
- "version": "0.2.4",
+ "version": "0.2.5",
"private": true,
"engines": {
"node": ">=20.9",
@@ -43,7 +43,8 @@
"audit:strict": "node scripts/audit.mjs --strict",
"test:features": "node scripts/test-features.mjs",
"screenshot:cli": "node scripts/capture-cli.mjs",
- "check:instance-literals": "bun scripts/check-instance-literals.mjs"
+ "check:instance-literals": "bun scripts/check-instance-literals.mjs",
+ "e2e:release": "node scripts/e2e/release.mjs"
},
"dependencies": {
"@anthropic-ai/sdk": "^0.120.0",
@@ -66,7 +67,7 @@
"geist": "^1.7.2",
"konva": "^10.3.1",
"lucide-react": "^1.33.0",
- "next": "^16.3.2",
+ "next": "^16.3.3",
"node-pty": "^1.1.0",
"react": "^19.2.7",
"react-dom": "^19.2.7",
@@ -82,20 +83,24 @@
],
"overrides": {
"postcss": "^8.5.10",
- "sharp": "^0.35.3",
- "nanoid": "^3.3.18"
+ "sharp": "^0.35.4",
+ "nanoid": "^3.3.18",
+ "js-yaml": "^4.3.2"
},
"devDependencies": {
+ "@axe-core/playwright": "^4.13.0",
+ "@playwright/test": "^1.58.2",
"@tailwindcss/postcss": "^4.3.0",
"@types/node": "^22.19.20",
"@types/react": "^19.2.17",
"@types/react-dom": "^19.2.5",
"@vitest/coverage-v8": "^4.1.11",
"eslint": "^9.39.4",
- "eslint-config-next": "^16.3.2",
+ "eslint-config-next": "^16.3.3",
"fast-check": "^4.9.0",
"parse5": "8.0.1",
"postcss": "^8.5.26",
+ "simple-icons": "^16.30.0",
"tailwindcss": "^4.3.0",
"typescript": "^5.9.3",
"vitest": "^4.1.11"
diff --git a/scripts/check-contrast.mjs b/scripts/check-contrast.mjs
index 333794b0..98693032 100644
--- a/scripts/check-contrast.mjs
+++ b/scripts/check-contrast.mjs
@@ -99,4 +99,4 @@ for (const mode of ["light", "dark"]) {
console.log(`\n${mode.toUpperCase()}: ${fails[mode].length} fail(s) below WCAG AA 4.5:1`);
for (const f of fails[mode]) console.log(` - ${f.preset.padEnd(20)} ${f.pair.padEnd(14)} ${f.ratio} (need ${f.min})`);
}
-console.log(`\nNOTE: passive audit, exit 0 regardless. Fix via preset tweak in lib/appearance/presets/.`);
+if (fails.light.length || fails.dark.length) process.exitCode = 1;
diff --git a/scripts/check-instance-literals.mjs b/scripts/check-instance-literals.mjs
index 39b1f375..35874cbb 100644
--- a/scripts/check-instance-literals.mjs
+++ b/scripts/check-instance-literals.mjs
@@ -15,7 +15,8 @@ const hits = [];
for (const file of candidates) {
let text;
try { text = await Bun.file(file).text(); } catch { continue; }
- for (const literal of forbidden) if (text.toLowerCase().includes(literal.toLowerCase())) hits.push(`${file}: ${literal}`);
+ const literals = /^(app|lib|frontend|components)\//.test(file) && !file.includes(".test.") ? [...forbidden, ["rahmanef", "com"].join(".")] : forbidden;
+ for (const literal of literals) if (text.toLowerCase().includes(literal.toLowerCase())) hits.push(`${file}: ${literal}`);
}
if (hits.length) {
console.error("Forbidden operator-instance literals in portable/public source:\n" + hits.join("\n"));
diff --git a/scripts/e2e/release-fixture.mjs b/scripts/e2e/release-fixture.mjs
new file mode 100644
index 00000000..9e4f29a7
--- /dev/null
+++ b/scripts/e2e/release-fixture.mjs
@@ -0,0 +1,71 @@
+import { mkdtemp, writeFile, rm, readFile } from "node:fs/promises";
+import { tmpdir } from "node:os";
+import path from "node:path";
+import { createServer } from "node:http";
+import { randomUUID, randomBytes } from "node:crypto";
+import { spawn } from "node:child_process";
+
+export async function releaseFixture() {
+ const dir = await mkdtemp(path.join(tmpdir(), "mso-release-e2e-"));
+ let providerStatus = 200;
+ const provider = createServer((req, res) => {
+ res.writeHead(req.url === "/api/check_admin_key" ? providerStatus : 404, { "content-type": "application/json" });
+ res.end("{}");
+ });
+ await new Promise(resolve => provider.listen(0, "127.0.0.1", resolve));
+ const providerUrl = `http://127.0.0.1:${provider.address().port}`;
+ const device = randomUUID(), password = randomBytes(24).toString("hex");
+ const deviceFile = path.join(dir, "devices.json");
+ const setRole = role => writeFile(deviceFile, JSON.stringify({
+ approved: { [device]: { label: "Release fixture", role, approvedAt: Date.now() } }, pending: {},
+ }), { mode: 0o600 });
+ await setRole("owner");
+ await writeFile(path.join(dir, "fixture.txt"), "MSO release fixture");
+ await writeFile(path.join(dir, "infra.json"), JSON.stringify({
+ version: 2, instanceId: randomUUID(), defaultUser: "fixture", bindings: [],
+ users: { fixture: { id: "fixture", uid: randomUUID(), label: "Release fixture", defaults: { convex: "local" },
+ connections: { convex: { local: { id: "local", uid: randomUUID(), label: "Local provider", provider: "convex",
+ source: "direct", authMethod: "direct", scope: "account", revision: 1,
+ values: { apiUrl: providerUrl, adminKey: "synthetic-fixture-key" },
+ createdAt: Date.now(), updatedAt: Date.now(), verifiedAt: Date.now() } } } } },
+ }), { mode: 0o600 });
+ // Never read deployment .env.local or borrow its credential/device stores.
+ const env = Object.fromEntries(Object.entries(process.env).filter(([key]) => !/^(OS_|MSO_|NEXT_PUBLIC_)/.test(key)));
+ const example = await readFile(path.join(process.cwd(), ".env.example"), "utf8");
+ for (const [, key] of example.matchAll(/\b((?:OS|MSO)_[A-Z_]*(?:STORE|PATH|DIR|LOG))=/g)) env[key] = path.join(dir, key.toLowerCase());
+ Object.assign(env, {
+ OS_DEVICE_STORE: deviceFile, OS_INFRA_STORE: path.join(dir, "infra.json"),
+ OS_CONFIG_STORE: path.join(dir, "config.json"), OS_PREFS_PATH: path.join(dir, "prefs.json"),
+ OS_AUDIT_LOG: path.join(dir, "audit.jsonl"), OS_LOGIN_PASSWORD: password,
+ OS_SESSION_SECRET: randomBytes(32).toString("hex"), OS_FS_READ_ROOTS: dir, OS_FS_WRITE_ROOTS: dir,
+ OS_MCP_ENABLED: "0", NEXT_PUBLIC_OS_DEMO: "0", NEXT_TELEMETRY_DISABLED: "1",
+ });
+ const reservation = createServer();
+ await new Promise(resolve => reservation.listen(0, "127.0.0.1", resolve));
+ const port = reservation.address().port;
+ await new Promise(resolve => reservation.close(resolve));
+ const base = `http://localhost:${port}`;
+ env.OS_PUBLIC_ORIGIN = base;
+ const server = spawn(process.execPath, ["node_modules/next/dist/bin/next", "start", "--hostname", "127.0.0.1", "--port", String(port)], { env, stdio: ["ignore", "pipe", "pipe"] });
+ let logs = "";
+ const capture = chunk => { logs = (logs + chunk.toString()).slice(-8000); };
+ server.stdout.on("data", capture); server.stderr.on("data", capture);
+ const close = async () => {
+ server.kill("SIGTERM");
+ await Promise.race([new Promise(resolve => server.once("exit", resolve)), new Promise(resolve => setTimeout(resolve, 3000))]);
+ if (server.exitCode === null) server.kill("SIGKILL");
+ provider.closeAllConnections();
+ await new Promise(resolve => provider.close(resolve));
+ await rm(dir, { recursive: true, force: true });
+ };
+ try {
+ let ready = false;
+ for (let i = 0; i < 120; i++) {
+ if (server.exitCode !== null) throw new Error("Fixture server exited: " + logs);
+ try { if ((await fetch(base + "/api/health")).ok) { ready = true; break; } } catch {}
+ await new Promise(resolve => setTimeout(resolve, 250));
+ }
+ if (!ready) throw new Error("Fixture server did not become ready: " + logs);
+ return { dir, base, device, password, setRole, revokeProvider: () => { providerStatus = 401; }, close };
+ } catch (error) { await close(); throw error; }
+}
diff --git a/scripts/e2e/release.mjs b/scripts/e2e/release.mjs
new file mode 100644
index 00000000..14a9ec4d
--- /dev/null
+++ b/scripts/e2e/release.mjs
@@ -0,0 +1,80 @@
+#!/usr/bin/env node
+// Required release journeys against a built app with synthetic stores and a local provider.
+import { chromium, expect } from "@playwright/test";
+import AxeBuilder from "@axe-core/playwright";
+import { releaseFixture } from "./release-fixture.mjs";
+
+const fixture = await releaseFixture();
+let browser;
+try {
+ browser = await chromium.launch({ headless: true });
+ for (const viewport of [{ width: 1363, height: 936 }, { width: 390, height: 844 }, { width: 844, height: 390 }]) {
+ const context = await browser.newContext({ viewport });
+ const page = await context.newPage();
+ const errors = [];
+ page.on("pageerror", error => errors.push(error.message));
+ await page.goto(fixture.base + "/integrations");
+ await expect(page.getByRole("heading", { name: "Integrations", exact: true, level: 1 })).toBeVisible();
+ await page.getByLabel("Search services").fill("GitHub");
+ await expect(page.getByRole("button", { name: "GitHub", exact: true })).toBeVisible();
+ await page.getByText("Connection methods & setup guides", { exact: true }).click();
+ await expect(page.getByRole("link", { name: "Official setup page" }).first()).toBeVisible();
+ expect(await page.evaluate(() => document.documentElement.scrollWidth <= innerWidth + 1)).toBe(true);
+ const accessibility = await new AxeBuilder({ page }).withTags(["wcag2a", "wcag2aa", "wcag21aa"]).analyze();
+ expect(accessibility.violations.map(v => ({ id: v.id, targets: v.nodes.map(n => n.target) }))).toEqual([]);
+ const popupPromise = context.waitForEvent("page");
+ await page.getByRole("link", { name: "Sign in to MSO as Owner" }).click();
+ const login = await popupPromise;
+ await expect(login.getByRole("heading", { name: "Sign in to your server" })).toBeVisible();
+ await login.close();
+ await page.goto(fixture.base);
+ await expect(page.getByLabel("Server connection mode")).toContainText("Mock data only");
+ // Real launcher click, not only deep-link route mounting.
+ const settings = page.locator('a[href="/settings"]:visible').first();
+ await expect(settings).toBeVisible();
+ await settings.click();
+ await expect(page).toHaveURL(/\/settings/);
+ await expect(page.getByLabel("Server connection mode")).toContainText("Mock data only");
+ expect(await page.evaluate(() => document.documentElement.scrollWidth <= innerWidth + 1)).toBe(true);
+ expect(errors).toEqual([]);
+ await context.close();
+ console.log(`PASS public guides, login entry, launcher and reflow ${viewport.width}x${viewport.height}`);
+ }
+ const context = await browser.newContext({ viewport: { width: 1280, height: 900 } });
+ await context.addInitScript(device => {
+ localStorage.setItem("mso.device.id", device);
+ localStorage.setItem("mso:onboarding:v1", "done");
+ }, fixture.device);
+ const page = await context.newPage();
+ await page.goto(fixture.base + "/login?returnTo=%2Fintegrations");
+ await page.locator('input[type="password"]').fill(fixture.password);
+ await page.getByRole("button", { name: "Unlock", exact: true }).click();
+ await expect(page).toHaveURL(fixture.base + "/integrations");
+ await expect(page.getByLabel("Credential owner")).toHaveValue("fixture");
+ await page.getByRole("button", { name: "Self-hosted Convex", exact: true }).click();
+ await page.getByRole("button", { name: "Verify", exact: true }).click();
+ await expect(page.locator(".connection-state")).toHaveText("Verified");
+ fixture.revokeProvider();
+ await page.getByRole("button", { name: "Verify", exact: true }).click();
+ await expect(page.locator(".connection-state")).toHaveText("Access rejected");
+ await page.reload();
+ await page.getByRole("button", { name: "Self-hosted Convex", exact: true }).click();
+ await expect(page.locator(".connection-state")).toHaveText("Access rejected");
+ const call = (route, body) => page.evaluate(async ([route, body]) => {
+ const res = await fetch(route, body ? { method: "POST", headers: { "content-type": "application/json" }, body: JSON.stringify(body) } : {});
+ return { status: res.status, body: await res.json() };
+ }, [route, body]);
+ const exec = await call("/api/v1/exec/run", { cmd: "pwd", cwd: fixture.dir });
+ expect(exec.status).toBe(200); expect(exec.body.cwd).toBe(fixture.dir);
+ expect((await call("/api/v1/exec/run", { cmd: "exit 0", cwd: fixture.dir + "/missing" })).status).not.toBe(200);
+ expect((await call("/api/v1/fs/list?path=" + encodeURIComponent(fixture.dir))).status).toBe(200);
+ await fixture.setRole("viewer");
+ expect((await call("/api/v1/integrations")).status).toBe(403);
+ expect((await call("/api/v1/exec/run", { cmd: "pwd", cwd: fixture.dir })).status).toBe(403);
+ console.log("PASS browser login/return, live provider revocation, reload, file/exec boundaries and immediate role demotion");
+ await context.close();
+} finally {
+ await browser?.close();
+ await fixture.close();
+}
+console.log("release E2E: all required journeys passed");
diff --git a/scripts/gates.sh b/scripts/gates.sh
index 075ab968..b596720d 100755
--- a/scripts/gates.sh
+++ b/scripts/gates.sh
@@ -47,8 +47,7 @@ fail() { echo ""; echo "❌ $1 push blocked."; [ -n "${2-}" ] && echo " $2"; e
echo "▶ running MSO verify"
bun run verify || fail "verify failed." "reproduce: bun run verify"
-# ── Guard 1b — architecture. check-contrast is informational (a WCAG palette audit
-# is a design task, not a push blocker), so it is allowed to exit non-zero.
+# ── Guard 1b — architecture and palette contrast regression gate.
# NOTE: check-slices.mjs used to run here. It and all 20 slice.json were deleted on
# 2026-08-03 (commit 844eef3) — do NOT let a hook reinstall re-add that line.
node scripts/check-cycles.mjs || fail "check-cycles: new import cycle introduced."
@@ -57,7 +56,7 @@ node scripts/check-docs.mjs || fail "documentation drift detected." "fix current
# and a stale one is what Settings → About would show. `bun run ship` regenerates
# it before committing; this catches a plain `git push`.
node scripts/gen-changelog.mjs --check || fail "changelog stale — run: node scripts/gen-changelog.mjs (or use \`bun run ship\`)."
-node scripts/check-contrast.mjs || true
+node scripts/check-contrast.mjs || fail "contrast regression detected."
# ── Guard 1c — dependency audit, high/critical only.
# Must live HERE rather than rely on an external CI wrapper. The audit wrapper
diff --git a/scripts/verify-build.sh b/scripts/verify-build.sh
index d3aaccaa..1c5974ba 100755
--- a/scripts/verify-build.sh
+++ b/scripts/verify-build.sh
@@ -35,3 +35,6 @@ cp -a "$REPO/node_modules/." "$TMP/node_modules/"
cd "$TMP"
# nice/ionice: this box also serves prod. A build gate must not starve :4005.
nice -n 15 ionice -c2 -n7 node node_modules/.bin/next build
+
+# Reuse this exact built tree for mandatory browser journeys; synthetic stores only.
+node scripts/e2e/release.mjs
diff --git a/scripts/worktree-gates.test.ts b/scripts/worktree-gates.test.ts
index d22f07ff..bdbbb529 100644
--- a/scripts/worktree-gates.test.ts
+++ b/scripts/worktree-gates.test.ts
@@ -14,6 +14,8 @@ function fixture(script: string) {
const result = spawnSync("git", args, { cwd: repo, encoding: "utf8" });
expect(result.status, result.stderr).toBe(0); return result.stdout.trim();
};
+ mkdirSync(path.join(repo, "scripts/e2e"), { recursive: true });
+ writeFileSync(path.join(repo, "scripts/e2e/release.mjs"), "import fs from 'node:fs'; if (!fs.existsSync('.build-verified') || fs.existsSync('.env.local')) throw Error('unsafe E2E fixture'); console.log('isolated E2E fixture passed');");
git("init", "-q"); git("add", "scripts");
git("-c", "user.name=Test", "-c", "[email protected]", "commit", "-qm", "fixture");
return { root, repo, git };
@@ -34,12 +36,13 @@ describe("isolated worktree release guards", () => {
it("builds a committed archive with copied dependency contents and no local secrets", () => {
const { root, repo } = fixture("verify-build.sh");
const modules = path.join(root, "modules"); mkdirSync(path.join(modules, ".bin"), { recursive: true });
- writeFileSync(path.join(modules, ".bin/next"), `const fs=require('node:fs'); if(fs.lstatSync('node_modules').isSymbolicLink()) throw Error('outside-root symlink'); if(fs.existsSync('.env.local')) throw Error('secret copied'); console.log('isolated build fixture passed');`);
+ writeFileSync(path.join(modules, ".bin/next"), `const fs=require('node:fs'); if(fs.lstatSync('node_modules').isSymbolicLink()) throw Error('outside-root symlink'); if(fs.existsSync('.env.local')) throw Error('secret copied'); fs.writeFileSync('.build-verified','ok'); console.log('isolated build fixture passed');`);
symlinkSync(modules, path.join(repo, "node_modules"), "dir");
writeFileSync(path.join(repo, ".env.local"), "# synthetic local configuration\n");
mkdirSync(path.join(repo, ".next")); writeFileSync(path.join(repo, ".next/keep"), "live marker");
const run = spawnSync("bash", ["scripts/verify-build.sh"], { cwd: repo, encoding: "utf8", timeout: 10_000 });
expect(run.status, run.stderr).toBe(0); expect(run.stdout).toContain("isolated build fixture passed");
+ expect(run.stdout).toContain("isolated E2E fixture passed");
expect(readFileSync(path.join(repo, ".next/keep"), "utf8")).toBe("live marker");
expect(existsSync(path.join(repo, ".env.local"))).toBe(true);
});
diff --git a/vitest.config.mts b/vitest.config.mts
index 0713b511..214196c9 100644
--- a/vitest.config.mts
+++ b/vitest.config.mts
@@ -59,13 +59,11 @@ export default defineConfig({
"**/.next/**",
],
thresholds: {
- // Ratcheted 2026-08-17 from 19/18/14/19 after the update-route, path,
- // download and env-reconciliation tests landed. Measured 20.36 / 19.08 /
- // 15.11 / 20.76 — these sit a hair under, as the comment above requires.
- statements: 20,
- branches: 18.5,
- functions: 15,
- lines: 20.5,
+ // Ratcheted from the September audit baseline: 42.29 / 40.04 / 32.76 / 44.00.
+ statements: 42,
+ branches: 40,
+ functions: 32,
+ lines: 43.5,
},
},
},