Here’s a minimal setup for proxytunnel:
Apache2:
[...]
ProxyRequests On
AllowConnect 22
<Proxy *>
Order deny,allow
Deny from all
</Proxy>
<Proxy 127.0.0.1>
Order deny,allow
Allow from all
</Proxy>
[...]
Local SSH configuration:
Host vps_proxy
ProxyCommand proxytunnel -q -E -p VPS_IP:443 -d 127.0.0.1:22 -z
DynamicForward 1080
ServerAliveInterval 60
Port 443
Set up local SOCKS5 proxy:
ssh -D 1337 -q -N -f -C vps_proxy
tsocks (to run any command through an SSH tunnel) configuration:
/etc/tsocks.conf
[...]
server = localhost
server_type = 5
server_port = 1337
Try connecting to any ssh host:
tsocks ssh ...