Commit Graph
4382 Commits
Author SHA1 Message Date
Henglie 8800161758 fix: apply ech-opts in tuic outbound dial (#3564)
Clone `t.tlsConfig` per dial and invoke `t.echConfig.ClientHandle` when
`ech-opts` is enabled so TUIC QUIC handshakes populate
`EncryptedClientHelloConfigList` without racing on shared `*tls.Config`
state across concurrent dials.
Prerelease-Alpha
2026-12-05 07:51:12 +08:00
semanym faf5a5e0a2 fix: do not cache zero-byte closed connections in sniffer skipList (#3550)
In Dispatcher.TCPSniff, any error returned by sniffDomain incremented
skipList[dstIP:port], including connections that closed or were canceled
before sending a single application byte (such as speculative browser
pre-connects or Happy Eyeballs races). Six such zero-byte closures
disabled SNI sniffing for all domains sharing that IP:port for the full
600 s TTL.

Skip caching the failure when conn.Buffered() == 0 and the error is a
connection-closed or cancellation error (io.EOF, io.ErrUnexpectedEOF,
net.ErrClosed, syscall.ECONNRESET, context.Canceled, etc.), while still
counting server-first read timeouts (os.ErrDeadlineExceeded) and
unrecognized or truncated payloads.

Fixes #3527
2026-11-30 18:42:08 +08:00
Abhijeet Chugh 5807ee08fd fix: forget in-flight dns lookups on ResetConnection (#3533)
A lookup that starts while the old network is going away (for example
Wi-Fi dropping on Android) can be sent to servers that will never
answer. It runs on its own DefaultDNSTimeout inside the singleflight
group, and every later request for the same name joins it, even after
the platform has signalled the network change (Clash Meta for Android
calls ClearCache and ResetConnection on every DNS change). So all
requests for that name fail together when the stale lookup times out.

Reset the singleflight group both before and after resetting the
clients. Before, so requests made while a client reset is blocked
(DoH's ResetConnection waits for clientMu) start a fresh lookup instead
of joining one stuck on the old network. After, so requests made once
ResetConnection returns do not join a lookup that started during the
reset on a connection from before the change.
2026-11-29 08:52:49 +08:00
Iaroslav 4ffa6eea4b fix: validate websocket upgrade and Hijacker before writing 101 (#3538) 2026-11-29 08:21:52 +08:00
塵 72214858cf feat: allow configuring XHTTP HTTP/2 stream receive window (#3331) 2026-11-29 08:20:49 +08:00
Iaroslav ba0cfd094e fix: reset hysteria defragger when FragCount does not match (#3537) 2026-11-29 08:18:19 +08:00
Chenx Dust 87e08489b7 fix: pass valid rAddrPort in Tailscale SystemPacketListener (#3535) 2026-11-27 23:14:54 +08:00
Bukely_ 53f61d4291 fix: avoid xhttp init panic when the system clock is wrong (#3521)
ChromeVersion() had no lower bound. A clock before ~2012 gave a negative
version, and the GREASE helpers indexed with a negative modulo during
package init, crashing the core even for `mihomo -v`. Clamp the version
to startVersion.
2026-11-25 13:25:12 +08:00
lovitus dd74780d4e fix: close the outbound when smux options are invalid (#3517)
ParseProxy built the outbound and then returned early if the smux options
failed to decode or NewSingMux failed, without closing it. Outbounds that
acquire process-wide state in their constructor kept it: EasyTier and
Tailscale register a DNS client by name and only remove it in Close, so a
failed parse left a client behind that a later outbound of the same name
would replace and then delete.

Close the outbound on both error paths and keep the wrapped value in a
separate variable so a failed NewSingMux cannot shadow the proxy that needs
closing.
2026-11-25 09:04:24 +08:00
ztywyjandZou c7af25cee0 feat: add WebSocket support to GOST relay (#3507)
Co-authored-by: Zou <zou@outlook.com>
2026-11-24 21:03:19 +08:00
wwqgtxx fc3bd70369 fix: always convert domain to lowercase for rule matching 2026-11-24 10:56:58 +08:00
enfein e13f0f187e chore: update mieru version (#3514)
See https://github.com/enfein/mieru/releases/tag/v3.40.0 for the summary of changes.
2026-11-24 08:33:16 +08:00
Livy Yao 100ff73ae7 fix: correct msftncsi hostname typo in default fake-ip-filter (#3481)
dns.msftnsci.com / www.msftnsci.com are transposed; NCSI probes dns.msftncsi.com and www.msftncsi.com. Under fake-ip, the unfiltered real probe host resolves to 198.18.x.x and Windows 10 reports "no internet".
2026-11-20 08:18:09 +08:00
i40e 024152115c feat: allow disable redir-host mapping in fake-ip mode (#3496)
When a real IP is returned from fake-ip-filter, subsequent connection
toward the real IP will be mapped back to domain (redir-host behavior).
For configurations with a small number of filtered real IP, the real IP
returned is functionally equivalent to a fake IP.

Add a configuration option to disable the redir-host behavior in fake
IP mode.
2026-11-20 07:44:34 +08:00
Esko Mobius 2be2f08909 fix: skip expired entries when picking reusable connections for xhttp (#3479) 2026-11-18 09:37:53 +08:00
SoulOriginal 0976eb6ac1 fix: PROCESS-NAME/PROCESS-PATH rules miss when any process exits during the /proc search on Linux
https://github.com/MetaCubeX/mihomo/issues/3469
2026-11-18 08:18:10 +08:00
wwqgtxx 7907040f27 chore: ignored invalid dns-mode for tun 2026-11-18 08:06:41 +08:00
wwqgtxx 3c0d10a503 chore: adjust internal function 2026-11-15 17:48:09 +08:00
wwqgtxx 184857ce21 fix: ss none packet write 2026-11-14 23:28:18 +08:00
wwqgtxx 7e73a9448b fix: ShadowTLS v2 not work with X25519MLKEM768
The v2 server authenticates the client only if its HMAC covers all the
data relayed from the handshake server, or all but the last write. The
client hashed only the bytes the TLS stack asked for, which end at the
server Finished record, so session tickets sent in the same flight were
left out whenever the stack's last read did not happen to pick them up.
With an X25519MLKEM768 ServerHello this happened on every connection to
a Go crypto/tls handshake server, and the chrome fingerprint always fell
back. Read the socket through a 16 KiB buffer and hash everything each
read returns, as the original implementation does.
2026-11-14 23:09:45 +08:00
wwqgtxx a9e5c456e3 chore: adjust randomization weights 2026-11-14 23:09:19 +08:00
wwqgtxx 4c57a4a600 chore: remove unnecessary forwarding code 2026-11-14 16:05:41 +08:00
CatMsg d569d9eba7 feat: support optional userkey for Snell v6 outbound (#3460) 2026-11-14 15:57:54 +08:00
AaronChen0 12b81d465a fix: use correct format verb for subscription-userinfo parse errors (#3455) 2026-11-12 09:13:57 +08:00
MiaM1ku 0455d0d28c chore: bump embedded easytier-go core to keep guest memory off the Go heap (#3454)
go.mod / go.sum: github.com/easytier/easytier/easytier-go
  v0.0.0-20260910071355-3d0c9c3ca5e2
  -> v0.0.0-20261111015056-2abb1676b475

Upstream: easytier/easytier#2782 (690b6be4778f). Guest linear memory now lives
outside the Go heap (PROT_NONE reservation committed in place), Hosts share one
wazero CompilationCache, and the first compile is followed by FreeOSMemory.

Measured on Alpha (one easytier outbound, 4 peers: 2 tcp + 2 udp, persistent
flows through mihomo's SOCKS5 inbound, VmRSS):
  200 flows: 389.9 MiB -> 205.1 MiB
  400 flows: 702.0 MiB -> 287.9 MiB
  first dial: 220.1 MiB -> 107.8 MiB
  second outbound: +49.4 MiB / 2.0 s -> +12.4 MiB / 76 ms
v1.19.34
2026-11-11 13:53:39 +08:00
wwqgtxx f7ec2b9a4b chore: update utls to go1.26-based 2026-11-11 10:23:01 +08:00
Sloan Gray c3bdf7798a fix: skip empty age secret key in DecryptBytes (#3450)
A proxy-provider without its own age-secret-key passes "" to
age.DecryptBytes, which failed with "no identities found" before the
global secret keys were tried.
2026-11-11 09:45:40 +08:00
wwqgtxx 478af2a57c fix: auto route rules for tun 2026-11-06 10:47:06 +08:00
wwqgtxx 9466681813 chore: code cleanup 2026-11-06 10:40:07 +08:00
Romanov Caesar 2d1a22e311 feat: support multiple users for shadowsocks listener (#3383)
Add `users` (username: password) to the shadowsocks listener so that
multiple users can share one port. The matched username is set as
InUser, so IN-USER rules work for both TCP and UDP.

- 2022-blake3-aes-*: `password` is the server PSK and each user password
  is the user PSK, clients use "iPSK:uPSK".
- legacy AEAD: user passwords are used directly, `password` must be empty.
- other methods return an error when `users` is set.
2026-11-06 10:11:14 +08:00
Aleksey Fedorov e9b9a1a87f fix: convert httpupgrade share links to ws with v2ray-http-upgrade (#3415) 2026-11-06 09:19:19 +08:00
Chikage0o0 9002a4fed3 fix: easytier drain unused host packets to prevent data-plane stalls (#3400)
Consume raw host/TUN packet egress for each running instance so the bounded EasyTier packet sink cannot backpressure the data plane. Stop receiving when the instance closes or the adapter is canceled, and document packet ownership.
2026-11-05 21:41:32 +08:00
YONG f1f640b12f feat: add Snell version 6 support (outbound + inbound) (#3410) 2026-11-05 18:29:11 +08:00
Gtio 69c16319b1 fix: keep bytes that arrive with the HTTP proxy's CONNECT response (#3382) 2026-10-30 17:22:37 +08:00
wwqgtxx ca8d7c41bf fix: ssh clients do not close when underlying connection writing errors 2026-10-28 19:15:53 +08:00
Zephyruso ff179c43a1 feat: add ss-password generation functionality to the command line tool (#3372) 2026-10-28 15:17:00 +08:00
wwqgtxx de439c8812 fix: drain cached data before reading upstream 2026-10-28 14:43:41 +08:00
wwqgtxx 5b79f3c367 fix: tfo-go not working on go1.26.9+ and go1.27.2+ 2026-10-26 23:36:36 +08:00
wwqgtxx b6a15182c2 fix: i386 struct define of PROCESS_MEMORY_COUNTERS 2026-10-26 12:29:58 +08:00
SaladDay 6780eeeb27 fix: prevent SOCKS domain length arithmetic overflow (#3359) 2026-10-25 08:13:14 +08:00
enfein 91e85eebf0 chore: allow mieru inbound to actively close idle TCP connection (#3354) 2026-10-24 08:12:35 +08:00
saba-futai 3f27ef39f8 chore: refactored and fixed issues for sudoku while also improving performance (#3333) v1.19.33 2026-10-21 23:51:58 +08:00
Chenx Dust 2df147b906 feat: support dns-mode for tun (#3288) 2026-10-21 23:44:35 +08:00
wwqgtxx c4e818694c fix: CVE-2026-97031 for crypto/tls 2026-10-21 23:24:35 +08:00
Token 94b13aed49 fix: dialer-proxy cycle check takes quadratic time and memory (#3315) 2026-10-13 20:38:16 +08:00
Token df1b07af2c fix: a sub-millisecond URL test is reported as a failure (#3316) 2026-10-13 20:10:59 +08:00
Token 349af19116 fix: the embedded shadowsocks listener can't be closed (#3314) 2026-10-13 20:02:16 +08:00
enfein bc76c1398c chore: update mieru version (#3304)
Mainly fixes an issue of infinite TCP read retry when using QUIC like Hy2
as mieru's dialer proxy. The issue was reported by a user of mihomo 1.19.32.

Also includes other improvements.
2026-10-11 09:38:59 +08:00
Younes Beriane e4dd968de9 fix: keep fake-ip allocation state when cloning the pool on reload (#3283) 2026-10-08 15:57:16 +08:00
Cassian433 80101933c0 fix: bound doh dials so ones the query gave up on cannot pile up (#3274) 2026-10-08 15:04:41 +08:00