dsh-drift
Manifest validCapability drift detection: audit a plugin once, store a baseline of what it could do, then after every upgrade report only what is NEW (new install scripts, shell/eval access, outbound domains, crede
dsh-drift
装之前扫一次不够。升级之后,它可能悄悄多出 shell、外联、凭据访问。
问题
现有安全插件几乎都是「装之前扫一次」。但插件会升级:
v1.2.0 只读文件
v1.3.0 多了一行 child_process.execSync
你早就不是当初审的那份代码了,而没有人提醒你重新审一遍。
它做什么
drift_baseline { target: "某个插件目录" } ← 审完存基线
↓(中间插件升级了)
drift_check { target: "同一个目录" } ← 只报新增了什么
输出示例:
🔴 dsh-foo 1.2.0 → 1.3.0:新增了 3 项能力(high)
· 新增安装期脚本 postinstall
· 新增能力 execSync
· 新增凭据路径访问 .ssh
建议:新增了能力就该重新审一遍——升级不等于安全。
三个设计原则
- 只报新增。能力减少说明变安全了;版本号变化只是发布动作。都不报。
- 画像稳定。同样的代码跑两次,画像逐字节一致——否则漂移检测会全是误报。
- 不评分。评分会诱导"这次分数差不多就放行";这里只回答一个问题:它多了什么。
严重度怎么定
| 新增 | 级别 | 理由 |
|---|---|---|
| 安装期脚本 | high | 跑在安装那一刻,最容易藏东西 |
child_process / eval / vm | high | 能把代码变成命令 |
凭据路径(.ssh / .env / api_key) | high | 直接对着秘密去 |
原生依赖(.node) | medium | 二进制里看不清 |
| 外联域名 | medium | 数据可能出去 |
三个工具
| 工具 | 作用 |
|---|---|
drift_baseline { target } | 存当前能力基线 |
drift_check { target } | 对比基线,只报新增 |
drift_list {} | 列出已存基线 |
基线存在 ~/.dsh/drift/baselines/<插件名>.json。
能力边界
- 只看静态代码:运行时才出现的行为(动态拼 URL、读配置决定连哪)抓不到
- 不判断"恶意":新增能力不等于恶意,它只是告诉你"该重新看一眼"
- 画像有粒度:按 API 名与域名归类,不做到调用级
License
MIT
Comments
Loading…
Similar plugins
by ZSeven-W
DeepSeek Harness (DSH) plugin: a read-only ledger for the plugins you already have installed — a capability inventory with file:line evidence, declared-vs-detected reconciliation, cross-profile versio
★ 29
↓ 227/wk
MIT
JavaScript
Nov 16, 2026
dsh plugin --profile web add @zseven-w/dsh-harborby dove-a
Path registry for DSH (DeepSeek Harness) plugins: inventory all installed plugins/presets/skills with real paths & sources, detect new/removed/upgraded changes, scan C-drive residue references, verify
★ 0
MIT
JavaScript
Aug 19, 2026
dsh plugin --profile web add @a_dove/dsh-plugin-registryby Equinox7379
Update radar for DSH: compares every installed link: plugin against its git upstream and reports which are behind. Read-only, zero runtime deps.
★ 0
MIT
JavaScript
Aug 14, 2026
dsh plugin --profile web add dsh-update-radarDiagnostics for DeepSeek Harness plugins: finds plugins that failed to load, rows a failed update left behind, unmanaged entries - plus a disk scan for update leftovers.
★ 0
MIT
TypeScript
dsh plugin --profile web add @ragnoryok1/dsh-plugin-doctorby jiuyuan-yi
DeepSeek Harness 更新守卫:更新前检查插件兼容性,启动失败可自愈(测试版)
★ 1
MIT
JavaScript
Nov 6, 2026
dsh plugin --profile web add dsh-update-guardby lw-storm
This plugin provides version management and rollback capabilities. When another plugin causes an error that prevents DSH from launching, forcing you to clear all plugins, this plugin can quickly resto
★ 0
JavaScript
Aug 29, 2026
dsh plugin --profile web add dsh-plugin-version-management