Questions tagged [ssh-tunneling]

An SSH tunnel provides an encrypted channel based on the SSH protocol.

Filter by
Sorted by
Tagged with
0 votes
1 answer
20 views

Double tunnel hop via SSH

I'm using WinSSHTerm to connect to a proxy, from which I then connect to a server hosting a data warehouse. I just can't figure out how to reproduce my Putty connection using a shell command. Short ...
user avatar
  • 101
1 vote
0 answers
29 views

Access Apache NiFi running on remote VM via browser and PuTTY

I'm trying to access a Virtual Machine running in Google Cloud which has a Apache NiFi service running on port 8080 on the VM. I have managed to create an ssh key and upload the public SSH key to the ...
user avatar
0 votes
0 answers
24 views

Permanent SSH tunnel through bastion host

I have the following command that I run locally on my mac to be able to access a DB server trough a bastion host: ssh -L 9234:MYSERVERIP:5432 USER@MYBASTIONIP -i MyBastionPemKey.pem that works just ...
user avatar
  • 101
0 votes
1 answer
14 views

ssh reverse mysql tunnel with a aliased host

I am trying to ssh into my server and then access the mysql on localhost for quick prototype development when testing on live. Here is my connection in the server: mysql -h db_master_www -u game -D ...
user avatar
0 votes
0 answers
20 views

Help to configure SSH tunnel to access to a remote server

Here my scenario: 192.168.2.222 --- VPN ---> 192.168.2.200 / 192.168.0.10 --- LAN ---> 192.168.0.50 My local machine My remote machine Target server Due to the ...
user avatar
  • 557
0 votes
1 answer
56 views

Access internet on linux machine using ssh connection with windows machine

Given a windows machine A and an linux machine B, I tried to implement this solution (also reading on this website) to access internet on B via A (machine A has internet access). On the windows ...
user avatar
0 votes
2 answers
52 views

SSH Forwarding between client and two servers

I'm trying to figure out how to set up a shh tunnel between client and two servers. I need client to connect to ServerB via ServerA. These are the facts: Client can connect to ServerA (via public IP)....
user avatar
0 votes
0 answers
40 views

Create SSH tunneling with multiple hosts

I want to create an SSH tunneling from: 192.168.6.66 -> 172.17.6.2 -> 172.11.3.3 -> 192.168.1.23 -> 192.168.6.71 What I'm trying is: On 192.168.1.23 to access to the last hop 192.168.6.71:...
user avatar
  • 3
0 votes
1 answer
63 views

Hardening reverse SSH tunnel (via jump host)

When inspecting the system logs of some other issue, I noticed that I was getting lots of SSH attempts in real time. Specifically I have about 10'000 attempts daily! $ grep Disconnected /var/log/auth....
user avatar
  • 911
0 votes
1 answer
19 views

restricted ssh tunnel through external facing server to mysql on internal server

Using my user I'm able to set up an ssh tunnel to mysql (port 3306) on an internal server by tunneling through an external server using: ssh -L 33306:localhost:33306 me@external.com ssh -L 33306:...
user avatar
0 votes
0 answers
34 views

Reverse SSH Tunneling via middleman

I have two machines, both in a VPN network, let's call them A and B and there is a user John on his own machine C. A is not discoverable by John but B is. Let's make a user on machine A, 'rose'. What ...
user avatar
  • 1
0 votes
1 answer
35 views

What is the default bind address used when opening an SSH tunnel without explicitly specifying it

When opening an SSH tunnel, e.g. as follows on Ubuntu 21.10: $ ssh -f -N -L 1234:127.0.0.1:5678 user@server what is(are) the default bind address(es) used under the hood (if any)? Is this equivalent ...
user avatar
  • 213
0 votes
2 answers
146 views

SSH: ProxyJump from user without shell

I have a system user syncoid as $ cat /etc/passwd syncoid:x:993:990::/var/lib/syncoid:/run/current-system/sw/bin/nologin with the following ssh config: $ cat /var/lib/syncoid/.ssh/config Host eve ...
user avatar
0 votes
1 answer
229 views

Using ssh+socat for remote port forwarding without ssh -R tunnel

I know that I can use ssh's remote port tunneling to create a connection between remote and localhost like such, ssh -fN user@remote -R remote_port:localhost:local_port I would like to do the above ...
user avatar
0 votes
0 answers
40 views

Question about hosting behind router

I feel like a noob because I can't figure this one out. I have a linux machine (a raspberry pi running raspbian) behind a router, and I'm trying to host a website on it (port forwarding is not an ...
user avatar
1 vote
1 answer
60 views

How to forward all port from Debian to Windows with OpenVPN

My Setup: Debian 10 from Azure Windows 10 from Azure Debian 10 is a clean new server from Azure with only OpenVPN installed and set up using the script from this Repository. Windows 10 is full of ...
user avatar
0 votes
1 answer
241 views

SOCAT (only) reverse tunnel

I have a situation where we are trying to get data from one network to another - specifically access to a private maven repo on a different network. Network 1 contains a maven repo. And network is ...
user avatar
  • 157
0 votes
1 answer
467 views

SSH Tunnel (Port forwarding) in background

I have a command to forward a port from my computer to a server, as follows: ssh -L 8000:localhost:8888 myserver.com I would like to run this command in background. I don't need to enter user and ...
user avatar
  • 143
0 votes
1 answer
78 views

Expose local dev server externally with SSH Tunneling / Port Forwarding through Raspberry Pi

I'm trying to expose my local dev server externally so that my web app can be tested by users who are not in my local network. Users who test the web app must run the apps with localhost:3000 and ...
user avatar
0 votes
2 answers
111 views

rsync files between two remotes, with only access from the "intermediate"

EDIT #1 As per answer by roaima, I tried (here with user1=user2) [user3@M3]$ ssh -R 50000:M2:22 user1@M1 rsync -e "ssh -p 50000" -avz /absolute_path1/ user2@localhost:/absolute_path2/ ...
user avatar
1 vote
2 answers
86 views

Ssh to server2 via server1 using the credentials on server1

I have two servers, server1 and server2, and I can connect to server2 via server1: localUser@localMachine $ ssh user1@server1 user1@server1 $ ssh user2@server2 user2@server2 $ I can do this in one ...
user avatar
  • 215k
-1 votes
1 answer
68 views

How to: several ssh tunnels for http but using sub[1|2].domain.tld in the browser (redirect? proxy?)

Sry: still looking for the correct title of the question. i have two ssh (http) tunnels to a remote server. port 8080 and port 3000 ssh -L 3000:127.0.0.1:3000 -L 8080:127.0.0.1:8080 user@server localy ...
user avatar
  • 11
0 votes
0 answers
39 views

I want to use an SSH server to provide internet connectivity with sshuttle

I have a local network containing a machine named black running Ubuntu 16 server, and a raspberry pi. The pi has two network cards. One faces this local network, and the other connects to my ISP via ...
user avatar
0 votes
0 answers
44 views

Question regarding port forwarding from local to remote

Hi am just learning some port forwarding concepts and my doubt/question is below. I have a remote ec2 where jasper (j.s.p.r) is running on 7000 port, i can only access this jasper ec2 instance via a ...
user avatar
2 votes
1 answer
302 views

SSH config for connecting to host via reverse SSH tunnel

I set up a reverse SSH tunnel to access a node, node1, behind a NAT. I have set up an EC2 instance, myEC2, to act as the intermediary. From my laptop, when I want to access node1, I have to SSH into ...
user avatar
0 votes
0 answers
196 views

Send ssh through tor

I want to use Tor like this: ssh -N -D 8070 user@111.222.333.44 -p 22 --> Tor --> internet I understand Tor can be routed --thru port--> 8070. Also or in conjunction tor can be routed ...
user avatar
  • 11
0 votes
3 answers
69 views

scp+ssh+scp in a single connection

I don't know the nomenclature, but basically our corporate environment is setup with jumphosts so creating an ssh tunnel is really slow. Therefore I'm hoping there is some way to perform these three ...
user avatar
2 votes
2 answers
859 views

How to throttle bandwidth of SSH connection

How do I limit the speed of an SSH connection? For example, when I am doing port forwarding (ssh -L ...), reverse tunneling (ssh -R ...), or SOCKS5 dynamic port forwarding (ssh -D ...), I may want to ...
user avatar
  • 1,832
2 votes
1 answer
756 views

How to increase the compression level of SSH tunnels

This is how I establish an SSH tunnel (dynamic port forwarding using SOCKS) from a local computer to a remote computer: ssh -C -N -D 12345 user@192.168.1.2 I use compression (-C) because my bandwidth ...
user avatar
  • 1,832
-1 votes
1 answer
66 views

How to config ~/.ssh/config when ProxyCommand doesn't work but ssh -tt does

I need ssh host aa , then ssh host bb . But it is unconvenient, I want to make a config ssh to host bb directly . I have test all methods and found # Working ssh -tt root@aa ssh -tt root@bb # Not ...
user avatar
  • 415
1 vote
0 answers
67 views

Can't create SSH SOCKS tunnel with a chroot'ed user

I'm attempting to set up a SOCKS proxy via ssh with a user in a chroot jail. After creating the tunnel, connection attempts result in: channel 2: open failed: administratively prohibited: open failed ...
user avatar
  • 113
0 votes
1 answer
236 views

Using SCP in a Bastion VM setup with an established SSH tunnel

I am looking at ways to mitigate the potential for using scp commands within GCE VMs that are running CentOS 8. Current setup is a bastion VM being able to SSH into a secondary VM (instance-1). I have ...
user avatar
  • 103
0 votes
1 answer
51 views

Copying tar.gz file as binary type over ssh

I am new to Mac or linux world. I am trying to ssh into one of the router and copy firware file from my pc. I can copy the tar.gz file as is but I have been asked to copy as binary then I can do burn ...
user avatar
  • 1
0 votes
1 answer
166 views

Detect if your server is being accessed via a jump server

I wanna see if it is possible to detect when a jump server is being used. Imagine the following scenario: Client -(ssh)-> JumpServer -(ssh)-> Server Are there any logs or anything (IP addresses ...
user avatar
0 votes
0 answers
80 views

SSH connect through Proxy with ControlMaster

local --> proxy ==> server Say, I have a long connection between proxy and server using ControlMaster. Now I want to connect from local to server directly through this exisiting SSH long ...
user avatar
  • 1
1 vote
0 answers
219 views

Why is SSHFS so much less stable than SSH?

If I'm on a very slow and/or slightly hiccupy internet connection, and I ssh foo@bar.baz, the connection will mostly stay up. If there's particularly bad lag, output (and echoed input) will take ...
user avatar
1 vote
2 answers
90 views

How to implement user restricted access to SSH

Intro This is a question that seeks an extension of the answers at how-to-restrict-an-ssh-user-to-only-allow-ssh-tunneling Problem Statement I have tried to implement the suggestion at the reference ...
user avatar
0 votes
0 answers
9 views

command result is not helping for creating tunnel when broken

The following code always echos "Not Creating new tunnel connection" regardless if the tunnel exists or not. if ssh -p 3129 myuser@tunnel.myserver.com ls then echo Not Creating new ...
user avatar
  • 149
1 vote
0 answers
196 views

automatically reset sshfs when it locks up, remount fails unless done manually

i have 2 local dirs on my server mounted on a remote server. Local maintains connections with autossh -M 23 -R 24:localhost:22 user@server While remote mounts with dirs-sshfs.sh sshfs -o reconnect,...
user avatar
1 vote
1 answer
654 views

SSH Tunnel with automatic reconnect and password auth in Docker container

I want to forward a Socks5 proxy using SSH with password authentication inside a Docker container. YES, I know that SSH keys would be better. But since it's not my own server, I'm not able to use keys,...
user avatar
  • 279
0 votes
0 answers
266 views

SSH local port forwarding or SSH + Socat

I would like to connect to a service running on port X on a host. The service cannot be reached on the host IP address and port. There are 2 options I know which can achieve this: Local port ...
user avatar
  • 113
0 votes
1 answer
77 views

Connect to a device attached to remotehost and map to localhost

I have a device on a remote host which connects via IP address (see image below). For this example, my remote host is named myremote, and the device is visible on myremote as 192.168.3.15, port 55555....
user avatar
0 votes
1 answer
22 views

how to access VM services that is reachable from layers-deep jump server only?

I have a setup of servers like: Workstation --> Jump1 --> jump2 --> server1:4489 so jump1 is only SSH-accessible from Workstation jump2 only SSH-accessible from Jump1 & server1 has a ...
user avatar
  • 1,613
0 votes
1 answer
95 views

why does forwarding X11 over reverse ssh tunnel not work properly

I have a host which I want to access through reverse ssh and I also want to forward X11. So I did this on the remote host: ssh -X -R 43022:localhost:22 usr@myhost -p 2222 and I can connect fine with ...
user avatar
  • 1,937
0 votes
1 answer
145 views

Restrict web server traffic to only clients connected over a SSH tunnel

NOTE: I'm not sure if this is the right place to ask this question or if I'm asking the right question. Please bear with me if I'm wrong and let me know how I can correct my question or move it to the ...
user avatar
  • 103
1 vote
1 answer
118 views

Expose postgres server to public network with an intermediate server

I have a postgres server (but it could be any service, I suppose) running in local a network and a server (AWS EC2 instance) that I'd like to use as an intermediary to access the database. So far, I'...
user avatar
  • 11
0 votes
0 answers
38 views

Reverse SSH Tunnel - Connections Suddenly Fail

I have a couple of remote machines (a Pi4 and a 2010 MBA) on which I have set up a reverse SSH tunnel to my home iMac. This has been working fine for several years. I also have a Pi4 on my local ...
user avatar
  • 75
0 votes
1 answer
78 views

Port forwarding between 3 dedicated servers

I have a main node on one dedicated server where all ports are opened. I have to additional dedicated servers where some ports that we are using to communicate between servers are closed by ISP ...
user avatar
0 votes
0 answers
324 views

kex_exchange_identification error: Git behind Reverse Proxy

Not really sure where to go here. I'm stuck. I've got a git repository (call it hostname Git) running on a local VM that I can access locally via git@git.lan, I can have my router forward any port to ...
user avatar
  • 101
0 votes
1 answer
54 views

how to do double tunneling to send big data?

I have 4 computer A, B, C, and D. Computer A and B in one city and Computer C and D in another city. Computer A and D are two cluster machine. Computer B and C is connected through VPN. I have a huge ...
user avatar

1
2 3 4 5
13