dsh-lan-access
开发工具 活跃维护

dsh-lan-access

woyeshishen/dsh-lan-access

轻量静态Cordis插件,可将Web管理界面绑定至0.0.0.0实现局域网访问,同时为HTTP非安全源提供crypto.randomUUID兼容补丁,部署后无需额外配置即可快速启用远程访问能力。

0
Stars 标星
0
Forks 分支
0
Watchers 关注
0
Open Issues
PowerShell
主要语言
Apache-2.0
开源协议
67 KB
仓库大小
1 个月前
最后推送
一键安装扩展 / 插件指令
dsh plugin --profile web add github:woyeshishen/dsh-lan-access
git clone https://github.com/woyeshishen/dsh-lan-access.git
git clone git@github.com:woyeshishen/dsh-lan-access.git
README.md main

dsh-lan-access

npm version
license

中文 | English

Bind the DeepSeek Harness (DSH) Web GUI to 0.0.0.0 so other machines on the LAN can reach it — plus a crypto.randomUUID polyfill that makes the GUI fully work over plain-HTTP LAN origins — without modifying any shipped dsh code.

Features

🌐 LAN access Rebind the Web GUI to 0.0.0.0 via an id-targeted config patch. No --host flag involved, so the built-in 0.0.0.0 guard never runs
🛡️ crypto.randomUUID polyfill Injects a tiny script into index.html so /api RPCs work on non-secure HTTP origins (the Web API is undefined there)
🔓 Remote privileged methods Settings / credentials / agent presets work from the LAN too (allowRemotePrivileged, default on)
📦 Install once, keep working Static bundle auto-mounts into the profile and loads at DSH startup, survives restarts

Install

One-liner (recommended)

Windows (PowerShell)

irm https://raw.githubusercontent.com/woyeshishen/dsh-lan-access/main/scripts/install.ps1 | iex

macOS / Linux

bash <(curl -fsSL https://raw.githubusercontent.com/woyeshishen/dsh-lan-access/main/scripts/install.sh)

dsh plugin command

From npm

dsh plugin --profile web add @woyeshishen/dsh-lan-access

From GitHub

dsh plugin --profile web add github:woyeshishen/dsh-lan-access

After install, the plugin auto-mounts into the profile; restart DSH (or hot-reload) to activate.

Notes

  • The bind host is pinned to 0.0.0.0 by this plugin's patch; edit
    cordis.patch.yml if you need a different posture.
  • --port still works (the patch keeps the !!js port expression).
  • By default privileged /api methods (settings/credentials/agent presets)
    are reachable from trusted LAN hosts (allowRemotePrivileged: true); set
    config: { allowRemotePrivileged: false } on the lan-access row to
    restore loopback-only for them.
  • Uninstall: dsh plugin --profile web remove @woyeshishen/dsh-lan-access
  • This plugin intentionally exposes a remote-code-execution surface to the
    network — only use it on a trusted LAN.

Development

npm install
npm run build     # tsc -> lib/
npm run check     # type-check only
npm run check:legacy   # cordis.patch.yml structure sanity check

License

Apache-2.0