dsh-web
zhu1090093659/dsh-webDeepSeek Harness(DSH)Web 插件聚合生态包 · 一切皆插件,创意工坊分发(dsh-market.com)
Ask for a sudo password in the DSH composer and run remote root commands over SSH without putting the password in the transcript.
DSH 的远端 sudo 密码面板:在输入框位置弹出,密码只走 stdin,不进对话、工具参数、环境变量或磁盘。
A composer-hosted sudo password prompt for DeepSeek Harness: the password goes to the remote sudo over stdin and never enters the transcript, tool arguments, environment, or disk.
中文 · English
passwordTtlMs: 0 每次都要密码;正整数时密码只在宿主内存保留该时长。sudo -k,不假设 ticket 能跨 ssh 复用。command -v sudo 兜底。/dev/null。从 npm(推荐):
dsh plugin --profile desktop add dsh-remote-sudo从 GitHub:
dsh plugin --profile desktop add github:seudut/dsh-remote-sudo#v0.1.1或在插件管理器里选“从 Git 仓库安装”,填 github:seudut/dsh-remote-sudo#v0.1.1。
然后在 profile 的 cordis.patch.yml 加入:
- insert:
- id: sudo-askpass
name: 'dsh-remote-sudo'重启 DSH。前置条件:ssh 能密钥登录。
插件管理器安装会同时处理 bundle 选择;命令行安装需要手动加这一行。本地开发时,把 github:... 换成插件目录的绝对路径即可。
config:
passwordTtlMs: 0 # 0 = 每次都要密码;正整数 = 内存缓存毫秒数键 · 默认 · 说明 passwordTtlMs · 0 · 0 = 每次都要密码;正整数 = 密码在宿主内存保留的毫秒数
让 agent 调用 remote_sudo:
用remote_sudo在 aliyun 上执行apt-get update
参数 · 必填 · 说明 host · 是 · ~/.ssh/config 别名 command · 是 · 远端 root 命令 description · 否 · 面板里的短标签
需要密码时弹面板;passwordTtlMs 内不重复弹;取消/停止会结束调用。多端同时打开时每端都会看到同一个 prompt,先提交者生效,其余端自动撤销。
NOPASSWD。timeout。npm test
node test/real-host-probe.mjs # 手动:真实主机 + 错误密码验证链路passwordTtlMs: 0 asks every call; a positive value keeps the password in host memory for that window.sudo -k after every command and never assumes a no-TTY ticket survives across ssh.command -v sudo./dev/null.From npm (recommended):
dsh plugin --profile desktop add dsh-remote-sudoFrom GitHub:
dsh plugin --profile desktop add github:seudut/dsh-remote-sudo#v0.1.1Or use the plugin manager's "install from Git repository" with github:seudut/dsh-remote-sudo#v0.1.1.
Then add this row to the profile's cordis.patch.yml:
- insert:
- id: sudo-askpass
name: 'dsh-remote-sudo'Restart DSH. Requires key-based ssh access.
The plugin manager also selects the bundle; a CLI install needs this row manually. For local development, replace the github:... spec with the absolute path of the checkout.
config:
passwordTtlMs: 0 # 0 = ask every call; positive = in-memory TTL in msKey · Default · Meaning passwordTtlMs · 0 · 0 asks every call; a positive value is the in-memory password TTL in milliseconds
Ask the agent to call remote_sudo:
Useremote_sudoto runapt-get updateon aliyun
Argument · Required · Meaning host · yes · SSH alias from ~/.ssh/config command · yes · root command to run remotely description · no · short label shown in the panel
The panel appears when a password is needed; within passwordTtlMs it does not ask again. Cancel/stop ends the call. When several browsers are open, each shows the same prompt; the first answer wins and the others dismiss themselves.
NOPASSWD.timeout in the remote command for a hard limit.npm test
node test/real-host-probe.mjs # manual: real host + wrong passwordMIT