Questions tagged [ssh-tunnel]

An SSH tunnel leverages the SSH protocol to transport unencrypted data through an encrypted connection.

An SSH (secure shell) tunnel provides a secure connection through which unencrypted data can be sent.

This technique can be useful for:
- Providing security for insecure network protocols.
- Hiding one's true location (ip).
- Circumventing blocked ports in firewalls.

857 questions
9
votes
2 answers

ssh -R binds to 127.0.0.1 only on remote

I'm running ssh -N -f -R127.0.2.3:23000:127.1.2.3:23000 user@remote , and I expect the tunnel on remote has opened on 127.0.2.3:23000, but it only opens on 127.0.0.1:23000, and it's inconvenient because I need to open several tunnels on remote, but…
Auxorro
  • 93
  • 1
  • 1
  • 3
9
votes
2 answers

SSH Local Port forwarding working from localhost only

I can directly access Host A ( 10.100.64.112) from my HomePC but cannot directly access Host B (172.88.3.31) . To access Host B , I need to first ssh to Host A and then to Host B . To directly access Host B , I tried to set up an SSH tunnel using…
Zama Ques
  • 523
  • 1
  • 9
  • 24
9
votes
2 answers

How do I stop my ssh tunnel when it is in the background?

I'm using this ssh command: ssh -fnN -L $LOCALPORT:$REMOTEHOST:$REMOTEPORT $HOST This creates my ssh connection in the background and forwards that port to the remote host through another host. This is great, and allows me to use my service behind a…
Mnebuerquo
  • 234
  • 2
  • 6
  • 15
9
votes
2 answers

How to limit reverse SSH tunelling ports?

We have a public server which accepts SSH connections from multiple clients behind firewalls. Each of these clients create a Reverse SSH tunnel by using the ssh -R command from their web servers at port 80 to our public server. The destination…
Utku Zihnioglu
  • 213
  • 2
  • 5
9
votes
2 answers

Can I use an SSH tunnel to access a web server that's listening on a different IP/Port on the same server?

I've got a web server that isn't quite ready for general availability but I'd still like to test some things remotely. Can I leverage an SSH tunnel to connect to the server and then use the tunnel to route to the web service that is operating on…
Mike B
  • 11,871
  • 42
  • 107
  • 168
8
votes
2 answers

Improving speed of large file transfer over high latency link

So, I've recently had the need to pull a large file over the internet from one of our offices overseas. Both offices have 50Mbit fibre links in both directions, but the round-trip-time is horrendous and varies from maybe 450ms on a good day and…
Ingo
  • 81
  • 1
  • 3
8
votes
5 answers

SSH Tunnel as a Windows Service

I want to set up an SSH tunnel to run as a Windows service, I need to be able to set it up using only the command line so this counts out any software that doesn't include a command line version. What tools are available for Windows that I could use…
Callum
  • 181
  • 1
  • 1
  • 3
8
votes
3 answers

SSH via 3rd Machine

Local Computer (Fedora) --SSH--> Server1 --SSH--> Server2 In some environments I work in, we have to use "jump boxes" where you ssh to one server in order to get to another server. Is there a quick way to do this, perhaps by editing…
SeanFromIT
  • 212
  • 1
  • 5
8
votes
4 answers

How do I log SSH port forwards?

Say I have an SSH server, with port forwarding enabled. It's fairly simple for a user to set up an SSH connection and forward BitTorrent traffic or other illegal or abusive traffic over it. How can I set up logging to record what port forwards users…
interfect
  • 313
  • 1
  • 2
  • 7
8
votes
2 answers

How can ssh allowed to setup remote port forwarding but not execute commands?

How can an SSH command be setup to allow port forwarding but not execute commands. I know that the ssh login can use -N to stop commands executing, but can the ssh config file be setup to disallow it? Restricting the type of shell and the path in…
vfclists
  • 1,632
  • 5
  • 22
  • 37
8
votes
1 answer

Connect to remote MySQL using proxy

I'm trying to connect to a remote MySQL server (with TCP access limited to a specific IP) using port forwarding via SSH, but still haven't figured out how to do it. Here's what I intend to do: Local[A] ---> Proxy[B] ---> Remote MySQL[C] [A] Local…
hypeflow
  • 83
  • 1
  • 1
  • 3
7
votes
1 answer

RDP equivalent to SSH port forwarding?

I'm connecting from one Windows machine to another using RDP. I'd like to forward traffic headed for localhost:81 to a machine accessible to the remote machine via its internal network on a local IP address, let's say 10.90.228.163. So I want the…
Jez
  • 1,393
  • 2
  • 12
  • 24
7
votes
1 answer

HTTP server through reverse ssh tunneling

I have linux-based device (let's say a Raspberry Pi) that hosts a HTTP server. This device regularly changes WiFi access point and is often not publicly accessible due to NAT and/or firewall. I want to setup a reverse ssh tunnel using a publicly…
DurandA
  • 173
  • 1
  • 1
  • 5
7
votes
1 answer

Copying SSH IDs between servers

Is it good practice to copy SSH IDs a la ssh-copy-id between remote servers in production, so that they can perform various SSH tasks with one another easier? In particular, I'm setting up SSH tunnels and don't like to have to look up the very…
Matt Joiner
  • 191
  • 1
  • 8
7
votes
1 answer

Making proxy available on remote server through ssh tunneling

I know I can use ssh tunneling to create a "proxy" on my machine so that I can make all the traffic generated locally go through a remote server. Like this: $ ssh -D 12345 myuser@remote_ssh_server But what about if I need to create a "proxy" on the…
Filipe Correia
  • 253
  • 1
  • 4
  • 9