0

Installation is like this: on server1, use ssh -D server1:1080 root@server2 to setup a socks proxy. meanwhile, on server1, there is an IPsec/xauth VPN server running with vpn network 192.168.42.0/24. Then laptop does VPN connect to server1.

After VPN connection, if I config laptop to use socks proxy server1:1080, the laptop can access server2 network through the SSH socks proxy successfully. But I hope to forward traffic from VPN network to server1:1080 transparently on server1 without config laptop to use socks proxy. I guess I should use iptables.

0

Man,

what you're looking for is called redsocks

From the excerpt:

This tool allows you to redirect any TCP connection to SOCKS or HTTPS proxy using your firewall, so redirection may be system-wide or network-wide.

  • yeah, I found redsocks to proxy tcp connections, I am still struggling with UDP connection. It seems redsocks can do UDP, but I haven't done it successfully – quicksort Jun 6 at 13:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.