elevenmoon999/dsh-clash-proxy ↗★ 0
dsh-clash-proxy
Self-contained rule-splitting proxy plugin for DeepSeek Harness: subscription-based routing (domestic direct / international via ss/trojan/vless/vmess/hysteria2/socks5/http nodes) confined to the harness process tree, with a native Web GUI management page — no external Clash/mihomo dependency
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:elevenmoon999/dsh-clash-proxy说明文档
阅读完整 README ↗Configuration
The Clash Proxy settings card (or a profile patch overlay):
| Field | Default | Meaning |
|---|---|---|
enabled | true | Master switch; nothing listens or is injected when false |
subscriptionUrl | empty | Clash subscription URL; CLASH_SUBSCRIPTION_URL env var also works |
fetchProxyUrl | empty | Optional upstream proxy for fetching the subscription itself |
autoUpdateHours | 24 | Subscription refresh interval in hours, 0 disables |
groupType | url-test | Auto group type: url-test / select / fallback |
latencyTestUrl | gstatic 204 | Node health-check / latency-test URL |
latencyTimeoutMs | 3000 | Per-node latency test timeout |
noProxy | loopback | Extra NO_PROXY entries (loopback is always forced) |
extraRules | [] | Extra rule lines, e.g. DOMAIN-SUFFIX,example.com,DIRECT |
excludeRules | [] | Subscription rules to drop (substring match) |
Data directory: $DSH_HOME/clash-proxy/ (subscription cache, selection state). Routing data ships inside the package (lib/core/data/*.json.gz) and works offline; rebuild it with npm run build:cn-data.
Usage & verification
Usage example (run inside DSH):
curl -x http://127.0.0.1:
https://ipinfo.io # see the foreign exit IP
curl https://www.baidu.com # domestic direct, instant
Verification status (layered):
- ✅ Verified:
- Rule engine / subscription parsing / SS AEAD (
test/smoke.mjs) - vmess(ws), trojan(ws+tls), vless(ws) end-to-end (local xray oracle)
- hysteria2 / vless-reality manually verified against real nodes (script not published to avoid leaking credentials)
- Real splitting + socks5/ss nodes via curl (
test/proxy-e2e.mjs)
- Rule engine / subscription parsing / SS AEAD (
- ⏳ To verify (recommended before publish):
- Fresh-profile install smoke test (
dsh plugin addthen first boot) npm pack --dry-runpackage completeness (confirmlib/native/connector.exeandcordis.patch.ymlare included)- Multi-instance random ports never collide
- Fresh-profile install smoke test (