An SSH tunnel allows forwarding any traffic over the SSH protocol. This is used to secure the transmission or allow data to be exchanged where network restrictions are in place.

learn more… | top users | synonyms

25
votes
7answers
42k views

List open SSH tunnels

I use a lot of SSH tunnels to various servers on my linux machine (for tunnelling to databases, web servers etc) and it would be really handy to view a list of current open tunnels via a shell script. ...
16
votes
5answers
11k views

SSH access to office host behind NAT router

I would like to access the ssh port of my office linux host from home. Unfortunately the host is located behind a NAT router. So, the IP address is not publicly available. There is however access to ...
15
votes
3answers
10k views

How secure is an SSH tunnel or connection?

I have often advised people to use an SSH tunnel to secure their browsing on open WIFIs or in other insecure situations. I was recently asked by a friend how secure a SSH tunnel is after I had ...
14
votes
4answers
13k views

How to make ssh tunnel open to public?

Well refering back to this question i am running the command ssh -R 8080:localhost:80 -N root@website.com on mac. Yet the port that is being tunneled is not working publicly. I am running such a ...
11
votes
2answers
4k views

Differences between ssh -L to -D

I'm trying to understand the differences between ssh -L to -D. Is there anything else except for that -D is SOCKS only? Thanks!
11
votes
5answers
20k views

Automatic SSH tunneling from Windows

I'm trying to set up a Windows computer to always have two SSH tunnels to my Linux server. Currently, I'm using PuTTY to open the two SSH tunnels: I log in to the server in PuTTY, leave it ...
10
votes
2answers
1k views

How to determine the port allocated on the server for a dynamically bound openssh reverse tunnel?

When creating reverse tunnels on recent versions of OpenSSH a remote port of 0 can be given to bind any available port: -R [bind_address:]port:host:hostport ... If the port argument is ...
8
votes
4answers
3k views

If I use an SSH tunnel to get around a firewall, what does the sysadmin see?

I use an SSH tunnel for the port my browser uses to access the internet. The result is I get around the firewall my network uses, which prevents me from using many sites I want to use (facebook, ...
8
votes
2answers
3k views

Setting up ssh config file with id_rsa through tunnel

I've been struggling to set up a valid configuration to open a connection with a second machine, passing through another one, and using an id_rsa (which requests me a password) to connect to the third ...
8
votes
3answers
6k views

SSH Reverse socks tunnel

ssh -D can make a socks port at local machine, which pass the traffic to the remote, then to other places. ssh -L port:host:hostport, listen port at local machine, pass the traffic to "host:hostport" ...
8
votes
2answers
2k views

Dropped ssh/X session, how to pickup where left off?

I am VPN from a Linux box to another. I log in to the other box with ssh -X. I open an X window/program in an attempt to do a software installation. The painful truth is that this software cannot be ...
8
votes
2answers
3k views

An equivalent of ssh port-tunneling for Windows servers?

my home is Linux servers where SSH can always be used to get around a slightly-too-restrictive firewall. At work however, all of the servers we deal with are Windows based. I'm needing to connect to ...
8
votes
4answers
3k views

Finding IP or hostname of origin machine (ssh)

I connect to a number of machines constantly, from different physical locations (and thus different physical machines). Most of this is done though ssh, sometimes a gateway machine or two is required ...
6
votes
1answer
3k views

SSH as socks proxy through multiple hosts

Can the following be achieved with SSH. There are three machines involved: A. My local machine at home B. The SSH gateway server at school C. A workstation in a lab, only reachable through B I ...
6
votes
2answers
424 views

How to connect to a SSH session that was backgrounded with -f -N?

I'm doing some work where I need to pivot off a machine using proxychains so I'm connecting to a system and binding a local port like so... ssh -f -N -D 9000 user@host.com … which returns me back ...
6
votes
2answers
2k views

SSH Tunnel doesn't work in China

Last year I was working in China for a few months. I never bothered setting up a real VPN, but just created a SSH tunnel, and changed my browsers proxy settings to connect through it. Everything ...
5
votes
4answers
238 views

Secure Connection from Insecure Computer

I am going to be traveling out of the country to a pretty questionable area and I would like to be able to access my online banking while I am away. If I were taking my own computer, this wouldn't be ...
5
votes
6answers
8k views

How to tunnel port 25565 through SSH?

I want to play a game which is hosted on port 25565 (minecraft!), but my university firewall does not allow this port. I have a dedicated server running linux not too far from uni, so I think there's ...
5
votes
3answers
2k views

How to script a database migration using an SSH tunnel?

I am trying to create a sync.sh script that coordinates with our less-than-ideal version control for our website. This script will migrate a live copy of the database to our development environment ...
5
votes
2answers
6k views

How to make remote connection (ssh tunnel) with putty/ssh?

I am trying to make a tunnel between a server and laptop with Putty. The problem is, since the laptop has no public IP adress, I have to make a reverse connection. But I really dont know how to do ...
5
votes
2answers
2k views

Why is my connection via ssh tunneling much slower than other connections to a remote machine?

I rented a small Linux box with an intention to use it as a proxy for netflix etc. When I ssh and run wget my speeds are like 20Mb/s but when I connect with putty and go to speedtest I only get ...
5
votes
1answer
708 views

How to specify what port RDP responds to?

I need to figure out a way to force RDP(Remote Desktop) to respond to a specific port Instead of a RHP(Random High Port). I am not asking how to change what port RDP "Listens" on, but rather the ...
5
votes
2answers
5k views

Accessing IPv6 addresses through an SSH tunnel

I have a remote Arch Linux server which has IPv6 enabled (through Tunnelbroker, I am able to do ping6 ipv6.google.com successfully) and I want to know if it's possible to use PuTTY on my Windows 7 ...
5
votes
3answers
7k views

How can I resume a large scp file transfer when using port forwarding?

I have a machine a couple of hops away, and I need to set up port forwarding in order to transfer files. Edit: To be clear, the multiple hops are needed in order to access the remote machine. From ...
5
votes
2answers
1k views

All client outbound SSH is being blocked … are there any workarounds?

I want to ssh out of a machine running a client to connect to an SSH remote server. The reason I need this is to port forward/tunnel and get an open connection to an application on the client. The ...
5
votes
3answers
503 views

Mount remote drive by port forwarding

I have a windows 7 computer at home and a remote windows XP machine with an external USB drive attached to it. I would like to be able to copy files to and from home/the remote USB drive. The problem ...
4
votes
5answers
485 views

Multiple command prompts with one SSH connection?

I have a need to do a lot in vim on a remote server which I need to SSH into. I find that it is best if I can look at multiple documents in multiple windows on my desktop, so to do this I open two or ...
4
votes
2answers
3k views

SSH tunnel to home network, and access router web interface

I'm trying to use an ssh tunnel from a remote location to connect to my home network and access the router web interface. I have SSH access to the home network, and I can connect to the gateway ...
4
votes
3answers
4k views

How do I SCP a file through an intermediate server?

I'm using Ccygwin on WinXP (with the bash shell). I want to SCP a file from my localhost to a remote machine -- host2. However, I can only SSH to an intermediate machine -- host1, and then from ...
4
votes
2answers
774 views

Ssh port forwarding with Remote Desktop timing out

My work computer, a Windows 7 Enterprise PC called WORKPC, is running Remote Desktop. I have configured Windows Firewall on WORKPC to allow access to the Remote Dekstop service from only two IP ...
3
votes
3answers
205 views

anonymous browsing

I just watched a video by Eben Moglen about the increasing surveillance of our connected network devices and a lot of what he said rang true. The video can be found here if you're interested. I'm not ...
3
votes
3answers
4k views

Is there a sshuttle equivalent for windows - ssh tunneling for windows

I have been using sshuttle on my linux desktop for a long time to circumvent the restrictions of vietnamese ISPs. However I wonder if there's a similar easy to use software for windows? Something that ...
3
votes
1answer
1k views

How to keep ssh connection alive?

Sometims I need to keep ssh connection alive for hour or even more. Mysql big dumps or big TAR archives, for example, may require persistent connection for a long period of time. But Iam keep ...
3
votes
2answers
2k views

scp through intermediate server

I need to copy a file from a computer I can only access via SSHing into an intermediate computer. Home -> server.com -> cluster.com I'm trying to copy from cluster.com to home. I can ssh from ...
3
votes
4answers
2k views

How to create an SSH tunnel

Ok, here is the setup. I'm outside the local network and connecting to my home network using iSSH (on iPad), so far so good, I used to redirect my home mediacenter to localhost by creating a tunnel . ...
3
votes
2answers
708 views

Keep alive with MyEnTunnel or other SSH-background tunnel app

I'm successfully using MyEnTunnel to forward traffic to a remote SOCKS-server. If I don't use the tunnel for a while the connection seems to turn stale, but doesn't fail, hence the browser waits for ...
3
votes
4answers
1k views

How can I use SSH to tunnel to a port that's open on the machine I have access to but not open to the outside world?

I currently use SSH to tunnel my internet connection, using ssh -p <port> -ND <local port> <user>@<ip address>, and this works great. However, I'd like to bind a local port to ...
3
votes
3answers
6k views

uTorrent and PuTTY -> How to turn the connection into an active one?

There is an active, and passive mode when we talk about torrent. Passive, is when you can't connect to the peers actively. Active is when your ports are forwarder, and others can connect to you. ...
3
votes
1answer
184 views

How do I set up an SSH tunnel to a whitelisted box?

We have a trusted machine which is authorized to connect to a special web service on port 12345, as shown below. The web service whitelists specific clients, and only those IP addresses are allowed to ...
3
votes
2answers
1k views

Using WinSCP with SSH server and 2 machine hops

I'm on a windows machine using putty to ssh into my schools server. From there I need to "slogin -XY machine1" and then "slogin -XY machine2" . Ideally, I'd like to use WinSCP to connect and ...
3
votes
3answers
722 views

How to set up SSH tunnel between 2 machines behind 2 different NATs

I have Windows PC behind a NAT/Firewall at home, and a Windows PC behind a NAT/Firewall at work. i.e. Neither PC has a publicly visible IP address. On each of the PCs, I am running a Ubuntu VM on ...
3
votes
1answer
450 views

SSH as socks proxy through multiple hosts (with http proxy involved)

There are three machines involved. Home PC Gateway Server Squid Proxy Server on a workstation. I want to surf internet using the Squid proxy server on my Home PC I don't have a direct access to the ...
3
votes
2answers
2k views

connecting to mysql over ssh

All the computers involved are Mac OS X 10.6.x machines. I am on computer A, and have mysql running on it, and can connect to it as A~ $ mysql -u punkish -p database and so on. I have access to ...
3
votes
1answer
462 views

How can I mosh over multiple hops (for example, via tunnel or ProxyCommand)?

I have a system that I can only access via multiple ssh logins. I recently found out about using ProxyCommand or SSH tunnels to make the connection transparently. Is it possible to mosh instead, and ...
3
votes
2answers
2k views

vnc via ssh tunnel: channel 3: open failed: connect failed: No route to host

I was used to connect from A to a system B through vnc with ssh tunnel via C. I do the following: In B I start the vncserver: vncserver and let's say I get the :12 In A I open the ssh tunnel: ...
3
votes
1answer
78 views

SCP files to a server in LAN from WAN

I need to SCP a bunch of files from my local machine to a machine in a LAN via a machine with a public ip. Like this: my machine -> machine with public IP (XXX.XXX.XXX.XXX) -> machine with private ...
3
votes
2answers
4k views

chrome socks proxy through ssh forwarding timeouts

I'm attempting to forward all traffic through from Google Chrome through a SSH tunnel. When Firefox is configured to use the tunnel, it works. When chrome is launched with the proxy args appended, it ...
2
votes
2answers
954 views

If I route traffic through a SOCKS proxy, does the remote host do the DNS lookups?

I sometimes route my Web traffic through ssh using a SOCKS proxy. The purpose is to have all traffic be encrypted. The way I do it is to open up a terminal and run this... $ ssh -v -C -N -D 9000 ...
2
votes
2answers
192 views

ssh -D doesn't establish tunnel, it just connect as interactive session. Why?

I am trying to create a SOCKS5 tunnel, but for some reason using -D does not work. Here is an excerpt: laptop:~ localuser$ ssh -D 8080 -p 2222 remoteuser@remotehost.com remoteuser@remotehost.com's ...
2
votes
1answer
994 views

How to tunnel a local port onto a remote server

I have a domain that i bought from DynDNS. I pointed the domain at my ip adress so i can run servers. The problem I have is that I don't live near the server computer... Can I use an ssh tunnel? As I ...