Skip to content

fix - #101

Open
wtklcx wants to merge 3 commits into
macronut:mainfrom
wtklcx:main
Open

fix#101
wtklcx wants to merge 3 commits into
macronut:mainfrom
wtklcx:main

Conversation

@wtklcx

@wtklcx wtklcx commented Oct 19, 2026

Copy link
Copy Markdown

No description provided.

@wtklcx

wtklcx commented Oct 22, 2026

Copy link
Copy Markdown
Author

更新了下 DNS 出站的 IPv4/IPv6 连接逻辑,支持双栈优先级判断,和连接失败或超时后支持回退机制。

dns 的 type 可以指定 type=A,AAAA 单双写和查询优先级,hint 也支持 ipv4/ipv6 的单双写,也支持按顺序查询。

在设置生效性上,hint 的优先级最高,其次是 dns 的 type,然后看 device 来决定双栈策略,最后托底保留原始 ipv4 策略。

hint 如果 ipv4 和 ipv6 双写时按 hint 顺序决定优先级;没有 hint 时, dns 的 type 双写按书写顺序决定优先级;两者都没有时,有双栈 device 就 IPv6 优先,否则默认 IPv4 优先。

单写 hint 或网卡只有一个可用地址族时,只使用该地址族,不回退。

A 和 AAAA 查询可以同时发起,但不能因为同时查 DNS 就同时无条件发起连接。

@Cuthead

Cuthead commented Nov 3, 2026

Copy link
Copy Markdown

双栈那块是我写的。你的 fix 是要 fix 什么问题?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants