In configurations where no default gateway is defined in system, running TUN mode does not add default gateway redirection to TUN IP.
Environment
Windows 10
Default route is removed to ensure that NO traffic outbounds system, except via Xray server.
Addded explicit route for server IP via router.
What is expected
Default gateway 0/0 should be created by XRayClient regardless of existing default gateway.
Reproduce
Say your system has default gateway via router 192.168.1.1 and your Xray server is 111.22.33.44
Error
In configurations where no default gateway is defined in system, running TUN mode does not add default gateway redirection to TUN IP.
Environment
Windows 10 Default route is removed to ensure that NO traffic outbounds system, except via Xray server. Addded explicit route for server IP via router.
What is expected
Default gateway
0/0
should be created by XRayClient regardless of existing default gateway.Reproduce
Say your system has default gateway via router 192.168.1.1 and your Xray server is 111.22.33.44
route delete 0.0.0.0 mask 0.0.0.0
route add 111.22.33.44 mask 255.255.255.255 192.168.1.1
route print
, see that no route to0.0.0.0 mask 0.0.0.0
is added.Workaround
Define any default route to non-existing address in local network, i.e.
192.168.1.254
:route /p add 0.0.0.0 mask 0.0.0.0 192.168.1.254