mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-07-31 12:22:16 +03:00
defaultWireguardClients always allocated new tunnel addresses from the hardcoded 10.0.0.0/24 base, so a legacy or migrated inbound whose peers live in a different subnet (e.g. 172.16.0.0/24) got new clients in an unrelated, unroutable range. Derive the allocation base from the existing peers' /24 and fall back to 10.0.0.0/24 only when there are none.