fakeip-compat
为 TUN Fake-IP 与 LAN 网络提供 web.fetch 兼容的 DNS 提取能力 适合已在 Mihomo/Clash 网络中运行的环境,需配置 LAN 与 Fake-IP 网段及可用 DoH 路径。
安装
$
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:iwinoid/fakeip-compat说明文档
阅读完整 README ↗Usage
Configuration
| Key | Default | Notes |
|---|---|---|
lanCidr | 192.168.0.0/16 | LAN allowlist. System-resolved results inside it transport pinned. |
fakeV4Cidr / fakeV6Cidr | 198.18.0.0/16 / fdfe:dcba:9876::/48 | Local Fake-IP pools. Match them to the Clash Verge config. |
dohEndpoints | 1.1.1.1/dns-query, 8.8.8.8/resolve | Trusted DoH (JSON API) over direct IP-literal endpoints. First fully successful endpoint wins. |
dohTimeoutMs | 8000 | Budget for one DoH lookup. |
lanInsecure | false | Skip TLS check on the LAN path only. Turn it on for self-signed devices. |
maxResponseBytes / maxBodyChars / timeoutMs / maxRedirects / userAgent | 5000000 / 100000 / 30000 / 5 / official UA | Same meaning as the official provider. |
Settings UI
The plugin registers a fakeip-compat settings section and a browser card of the same name (lib/client.js, hand-written, no build step). After a DSH restart the card shows under Settings → Plugins → Plugin configuration. Every field in the table above edits there. Saves apply at once with no restart. Invalid input (such as a bad CIDR) blocks the save. A bad runtime edit keeps the last valid value and never breaks an in-flight fetch. Environments without a settings service (such as headless) fall back to the merged config.
Configuration
| Key | Default | Notes |
|---|---|---|
lanCidr | 192.168.0.0/16 | LAN allowlist. System-resolved results inside it transport pinned. |
fakeV4Cidr / fakeV6Cidr | 198.18.0.0/16 / fdfe:dcba:9876::/48 | Local Fake-IP pools. Match them to the Clash Verge config. |
dohEndpoints | 1.1.1.1/dns-query, 8.8.8.8/resolve | Trusted DoH (JSON API) over direct IP-literal endpoints. First fully successful endpoint wins. |
dohTimeoutMs | 8000 | Budget for one DoH lookup. |
lanInsecure | false | Skip TLS check on the LAN path only. Turn it on for self-signed devices. |
maxResponseBytes / maxBodyChars / timeoutMs / maxRedirects / userAgent | 5000000 / 100000 / 30000 / 5 / official UA | Same meaning as the official provider. |