# on remote server edit /etc/ssh/sshd_config and add
PermitTunnel yes
# restart ssh
sudo service ssh restart
#From local computer connect to the remote server (ex : VM Virtualbox in my case)
ssh -D 10998 -vv -N -C -w 0:0 my-remote-server
#on remote serveur (@home)
ifconfig tun0 172.16.0.1 netmask 255.255.255.252
ifconfig tun0 up
# verify
ifconfig
# active ip forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward
# activate routing
iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
# on local computer route subnet 192.168.1.0 @home
route add -net 192.168.1.0 netmask 255.255.255.0 gw 172.16.0.1 tun0
# on local windows use local proxy socks on 10998
# exemple with chrome & Falcon Proxy plugin
Aucun commentaire:
Enregistrer un commentaire