zapret-kvn/xray_fluent
Repository files (latest commit first)
Filename Latest commit message Latest commit date
loop-uh 7acad15dcd fix: resolve AWG uplink via WinAPI and unify the sidecar relay seam
The AmneziaWG sidecar failed at startup with "Physical interface for
Amnezia UDP transport not found". Three compounding causes:

- physical_network() spawned PowerShell and filtered on HardwareInterface,
  which wrongly excludes Hyper-V / WSL / Docker vEthernet uplinks, so every
  AWG key failed identically on such hosts; a transient miss aborted the
  whole startup with a hard OSError.
- A successful tunnel changes the outbound IP (e.g. 10.9.0.49), which the
  network monitor misread as a real network change and reconnected on,
  re-running the resolve while the tunnel held the default route — a
  self-inflicted flap.

Replace the PowerShell probe with a pure-WinAPI resolver: extend
win_netinfo (GetAdaptersAddresses gateways, DNS, OperStatus, IfType,
Ipv4Metric) and pick the up adapter that owns an IPv4 gateway and a
routable address, lowest Ipv4Metric. Requiring a gateway naturally
excludes the WireGuard/AWG TUN (it has none), so the relay never binds
back onto its own tunnel; dropping HardwareInterface fixes vEthernet
uplinks. The owned Go core still hard-requires a non-zero interface index
(IP_UNICAST_IF, no default-bind fallback), so a transient miss is retried
instead of aborting. Ignore network-change events whose address is the
active tunnel's own, breaking the reconnect loop.

Extract the shared sidecar seam — the loopback SOCKS relay must accept a
TCP connection before the sing-box front dials it — into
engines/sidecar.wait_for_loopback_relay(). Hysteria delegates to it (no
behavior change); Amnezia adopts it as a confirming gate after
relay_ready, so both cores share one readiness contract. The divergent
domain models (config handoff, handshake detection, failure taxonomy,
recovery) intentionally stay per-engine.

Verified on Linux: 890 unit tests pass (offscreen). Tunnel-comes-up and
Hysteria startup still need on-device confirmation on Windows.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HAjvZYzPW2yTtToKJXGdbS
2026-09-14 11:54:30 +03:00
..
application fix: resolve AWG uplink via WinAPI and unify the sidecar relay seam 2026-09-14 11:54:30 +03:00
diagnostics fix: retain authenticated Hysteria when health endpoints time out 2026-09-06 14:32:52 +03:00
engines fix: resolve AWG uplink via WinAPI and unify the sidecar relay seam 2026-09-14 11:54:30 +03:00
importer feat: use official Amnezia transport and organize runtime modules 2026-09-06 00:14:08 +03:00
network fix: unify transport transitions and restore direct Russian services 2026-09-06 01:10:35 +03:00
platform fix: resolve AWG uplink via WinAPI and unify the sidecar relay seam 2026-09-14 11:54:30 +03:00
profiles fix: preserve interactive server table and bound DNS fallback readiness 2026-09-06 02:07:48 +03:00
ui fix: refresh managed DNS and cache server table rendering 2026-09-06 14:51:07 +03:00
updates feat: use official Amnezia transport and organize runtime modules 2026-09-06 00:14:08 +03:00
__init__.py feat: use official Amnezia transport and organize runtime modules 2026-09-06 00:14:08 +03:00
constants.py release: prepare v0.6.5 2026-09-06 19:29:39 +03:00