authsec-openclaw runs OpenClaw behind AuthSec SSO.
The current working path in this repository is a local, single-user operator setup:
- browser login goes through AuthSec
- OpenClaw sees the logged-in user identity
who am I?can answer from the authenticated session context- browser, Discord, and Windows local-machine actions work after a Windows node is paired and unlocked
This is the guide to follow if you want the setup that is working in this repo today.
- cmd/authsec-openclaw-proxy/main.go: the AuthSec reverse proxy in front of OpenClaw
- deploy/docker-compose/docker-compose.yml: the local Docker stack
- deploy/docker-compose/openclaw-config/openclaw.json: the OpenClaw gateway config used by the stack
- deploy/docker-compose/run-openclaw-node.ps1: helper for Windows node run, pairing, unlock, and status
Use this repository for:
- local development on Windows
- one operator using AuthSec SSO
- OpenClaw in Docker
- optional Discord bot integration
- local Windows command and browser access through a paired OpenClaw node
Do not treat the current checked-in config as a hardened public deployment. The local setup intentionally relaxes some Control UI auth/device rules so http://localhost:8080 works during development.
-
Install prerequisites.
- Docker Desktop
- PowerShell
- Node.js + npm
- Go if you want to rebuild the proxy locally
-
Configure the environment file.
- Copy
deploy/docker-compose/.env.exampletodeploy/docker-compose/.envif needed. - Fill in AuthSec values, gateway token, session secret, and model/provider keys.
- Copy
-
Start the stack.
cd deploy/docker-compose docker compose up -d --build
-
Open the proxy.
- Local HTTP:
http://localhost:8080
- Local HTTP:
-
Sign in through AuthSec.
- After login, ask
who am I? - The answer should include your AuthSec identity.
- After login, ask
-
Pair your Windows node if you want local-machine access.
- Install the OpenClaw CLI:
npm install -g openclaw@latest
- From the repo root:
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode run
- If the first run says
pairing required, approve the pending request from another terminal:
docker exec openclaw-gateway sh -lc "node /app/openclaw.mjs devices list --json" docker exec openclaw-gateway sh -lc "node /app/openclaw.mjs devices approve <request-id> --json"
- Then start the node again:
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode run
-
Unlock node exec approvals for local-machine actions.
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode unlock powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode status
-
Test local tools in chat.
who am I?Open Notepad on node RitamKrKunduOpen my Downloads folder on node RitamKrKunduUse the browser on node RitamKrKundu and open https://authsec.ai
Use the complete Docker and pairing guide in deploy/docker-compose/README.md.
- Browser automation and Windows app/file opening require a connected Windows node. The Docker container alone is not enough.
/host-homeis only a mounted filesystem path. It does not mean Linux-in-Docker can launch Windows GUI apps by itself.- Discord must target a real channel or user, for example
channel:<id>oruser:<id>. - Web search is different from browser automation. If you want search results through the search tool, configure a provider such as Brave Search.
From deploy/docker-compose:
docker compose up -d --build
docker compose up -d --build --force-recreate openclaw proxy
docker compose logs -f openclaw proxy
docker compose downFrom the repo root:
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode run
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode unlock
powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode status
openclaw.cmd nodes status- If
who am I?does not show your identity, check internal/auth/middleware.go and confirm the proxy is writingUSER.md. - If local-machine commands fail with
SYSTEM_RUN_DENIED: approval required, run:powershell -ExecutionPolicy Bypass -File deploy/docker-compose/run-openclaw-node.ps1 -Mode unlock
- If OpenClaw says the node is not connected, leave the
-Mode runterminal open and verify:openclaw.cmd nodes status - If Discord says the target is unknown, give it a channel or user target instead of only the server name.
- Keep the gateway token, AuthSec secrets, provider keys, and Discord token out of commits and screenshots.
- The local config currently allows insecure localhost Control UI auth for development convenience.
- Before exposing this stack publicly over HTTPS, tighten the OpenClaw Control UI auth/device settings and review deploy/docker-compose/openclaw-config/openclaw.json.
Older scaffold-era docs were written before the current local single-user flow was stabilized. If something in this README conflicts with an older note elsewhere, follow this README and the Docker guide linked above.