Repository navigation
web_fetch: support local proxy tools that use fake-ip DNS, via a configurable CIDR allowlist #5459
Replies: 1 comment
|
Confirmed your full chain at master 49a606b (= 0.1.2-alpha.5, the version you cite) — source matches your quote line for line, and you've hit a known seam, not a one-off. Verified facts
This is the third report of the same triangle, not a new bug
On your temp patch (adding
Two other useful levers
Upstream fix candidates, in order: Config |
Uh oh!
There was an error while loading. Please reload this page.
环境
0.1.2-alpha.5(macOS)问题现象
web_fetch对任何 URL 都失败:原因
@deepseek-ai/dsh-web-fetch-http在建立连接前要求解析出的所有地址均为公网单播地址(SSRF 防护)。fake-ip 模式的代理会在系统层接管 DNS 并按设计返回保留段地址:198.18.0.2)198.18.0.0/15(RFC 2544 段),ipaddr.js 判定为reserved因此 fake-ip 机器上
web_fetch全域失败,harness 其余功能不受影响。该校验硬编码在isPublicIpAddress,插件Config仅暴露尺寸/超时等五个字段(maxResponseBytes、maxBodyChars、timeoutMs、maxRedirects、userAgent),没有配置出口。诉求
希望官方支持 fake-ip 场景,例如:
allowedCidrs: ["198.18.0.0/15", "fd00:6152::/32"]一类的配置项扩展放行集合,回环/私网/链路本地默认仍全部拦截;或已验证的临时补丁(改
isPublicIpAddress两行):实测(macOS + Surge 增强模式):
https://pi.dev返回 200 正常抓取;http://127.0.0.1/仍被WEB_BLOCKED_URL拦截,内网防护未受影响。缺点是升级即被覆盖,故求官方方案。All reactions