User Tools

Site Tools


tunneling

Tunneling

SSH via proxy (using corkscrew)

$ ssh -l dominik -p 443 dominik.is-a-geek.org -o ProxyCommand="corkscrew 192.168.120.253 3128 %h %p ~/.ssh/proxyauth" "$@"

.ssh/proxyauth

s01:12345

SSH port-forwarding

ssh -fND localhost:12345 user@server

Configure Web-Browser to use SOCKS on localhost port 12345

and also to use DNS via this connection, for Firefox it's

network.proxy.socks_remote_dns = true

Reverse port-forwarding

home$ ssh -NR 9000:localhost:9000 user@server
home$ netcat -l 9000
server$ netcat localhost 9000

Tor

/etc/tor/torrc

HttpProxy 192.168.120.253:3128
HttpProxyAuthenticator s01:12345
HttpsProxy 192.168.120.253:3128
HttpsProxyAuthenticator s01:12345

#FascistFirewall 1

Webbrowser proxy setup

  • use SOCKS5
  • localhost:9050
  • do DNS-queries through proxy

torify & tor-resolve

Transparently handle networking for other apps using the LD_PRELOAD-trick.

$ torify holdingnuts
$ tor-resolve dominik.is-a-geek.org

SSH common connection

FIXME Move to ssh

ServerAliveInterval 60

Host example.com
        ControlMaster auto
        ControlPath ~/.ssh/socket-%r@%h:%p
        Ciphers blowfish-cbc
        Compression yes
tunneling.txt · Last modified: 2012-04-28 10:06 CEST by dominik