1

I have vps server, install softether on it , softether use tap device name tap_se with subnet 192.168.24.0/21 netmask 255.255.248.0 broadcast 192.168.31.259,

clients connect with openvpn or l2tp to softether , and softether use local dhcp to assign ip in subnet 192,168.24.0/21 to them;

i want to socksify outgoin traffic of softether to another server use tun2socks or alternative , and need to change routes table to do this , what must happen must be : tap_se ==> tun0 ==> eth0

some suggested routes are :

# Bypass upstream socks5 server
sudo ip route add SOCKS5_SERVER dev DEFAULT_IFACE metric 10
sudo ip -6 route add SOCKS5_SERVER dev DEFAULT_IFACE metric 10

# Route others
sudo ip route add default dev tun0 metric 20
sudo ip -6 route add default dev tun0 metric 20

or :

ip route del default
ip route add default via 198.18.0.1 dev tun0 metric 1
ip route add default via 172.17.0.1 dev eth0 metric 10

and i create tun0 with these commands :

ip tuntap add mode tun dev tun0
ip addr add 198.18.0.1/15 dev tun0
ip link set dev tun0 up

but when do this , i lost my connection to server and need to reboot to routes restore to default, what is correct rules to do all outgoing traffic of tap_se goes through tun0 without lost connection to vps

0

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.