1
0
mirror of https://github.com/MetaCubeX/mihomo.git synced 2026-10-10 20:23:11 +08:00
Files
mihomo/component/resolver
TWO666 fb002210ff fix: tun dns hijack sending zero-filled or stale packets when PackBuffer reallocates (#3037)
D.Msg.PackBuffer sizes its scratch space by the uncompressed message length
and silently allocates a new slice when that exceeds the given buffer, even
though the compressed result would fit. The udp hijack path in
listener/sing_tun/dns.go always sends the original buffer, producing a
correct-length datagram full of zeros or stale bytes whenever a reply's
uncompressed size exceeds SafeDnsPacketSize (e.g. 100+ A records for one
name). Copy the packed result back into the caller's buffer when it fits.
The tcp path in RelayDnsConn already guards against this; the udp path did
not.
2026-07-27 13:03:03 +08:00
..
2022-04-20 22:52:05 +08:00
2026-02-07 12:07:01 +08:00
2025-04-11 09:20:58 +08:00