Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [ssh-tunnel]

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

0
votes
0answers
5 views

MySQL, Sequel Pro via ssh, access denied error

Before I get into details, there are at least a couple of questions that seem to address the same problematic behavior, but the answers given to the questions don't apply in my situation, which I will ...
0
votes
1answer
17 views

Restrict ssh user to connection only

Setting up an SSH jump box to allow some outside people to access an internal server. I have the authentication stuff all working where they will use a private/public key pair to authenticate. I'll ...
0
votes
2answers
47 views

Access remote server with private IP through a *DIFFERENT* server with public IP

Let's assume the following hosts: localhost : my laptop remoteserver : a server with a public IP which runs a SSH server on port 22. (remoteserver ip for example 194.152.16.111) private....
2
votes
1answer
59 views

SSH tunnel and reverse SSH tunnel at the same time on the same port

I have a computer A, a server B (Azure VM) and a second computer C. I want to connect from A to C through the server B. Setup: A: ssh -i location_of_private_key -L 12000:public_IP_of_B:20000 user@...
0
votes
0answers
22 views

ssh tunnel and reverse tunnel on same port

I have a AWS server that I want to use as a bridge to pass a vnc session. I am currently trying to figure things out on my computer. I'm using putty to make the SSH tunnel and the reverse tunnel (...
0
votes
0answers
5 views

Tunnelling server traffic throuh SSH when port forwarding on network is unavailable? [migrated]

Setup At home, I have a little Raspberry Pi 3 that runs services that are exposed to the internet. For example, it is running a HTTP server. I will call this server raspberry. I can manage raspberry ...
0
votes
0answers
48 views

Empty reply when CURLing through proxy

I'm using ssh to create a proxy connection to an EC2 instance: ssh -v -D 8123 ubuntu@some.ip.address But when I test it using curl, I get: http_proxy="http://localhost:8123" curl example.com curl: (...
0
votes
0answers
62 views

Use SSH Tunnel with MSSQL

An owner of a MS SQL db has allowed access to their db from an IP address of a remote machine I own. I can SSH into that machine and connect to the DB using: ssh -i my.pem 100.0.0.100 sqlcmd -...
1
vote
1answer
45 views

Why isn't NFS over SSH transparent to NFS?

NFS over LAN seems to work as expected - one downloads nfs-utils rpm, makes a share, modifies ownership and SEL, allows nfs in firewalld, launches nfs-server daemon, and everything is good to go. ...
1
vote
0answers
144 views

SSH Tunnel - channel 3: open failed: administratively prohibited: open failed

ssh -D 9090 user@host when I try to request web pages through socks5 (127.0.0.1:9090) I get: channel 3: open failed: administratively prohibited: open failed server sshd_config: #MaxStartups 10:30:...
0
votes
1answer
29 views

strange behaviour multihop ssh

I have three machines A, B, C. The aim is to be able to transfer files from A to C. I have ssh access from A to B, and B to C; B and C are on a local network. This can be achieved with the scp -o ...
0
votes
1answer
35 views

How to expose a port+url visible to one machine to another

Essentially I have 3 machines: A, B and C A can see B (and vice versa) and B can see C (and vice versa). A can't see C (not part of the same network). I have access to A and B. Meaning I can start ...
0
votes
0answers
41 views

Portforwarding with MobaXTerm

I'm currently having to port forward from a remote server, through a gateway server, then to my localhost; however, I'm having a slight bit of trouble. Using PuTTY, I can do this and confirm that it ...
1
vote
1answer
34 views

Allow SSH Reverse Tunneling (-R), but not Local Forwarding (-L)?

We have a customer with a remote server who wants to restrict times we can access the server (most customers we have on-demand access initiated locally). I'm setting up a script for them so they can ...
0
votes
1answer
34 views

How can I remotely connect via ssh and reuse this connection for other apps without asking for the original credentials?

There's a remote Ubuntu container that I can access via SSH using a one-time connection code (username-password). I'm using Windows, and don't have much rights on the container itself. So I'm trying ...
1
vote
1answer
29 views

SSH on remote machine under NAT and dynamic IP

I have different hosts that are connected over a cellular network (so NAT and dynamic IP). I have a central server that I want to use to use as gateway to access those machine SSH server for remote ...
0
votes
0answers
27 views

How to setup port-forwarding between docker cli and host machine? (Permission denied: publickey)

I'm inside a docker cli (via docker exec -it cli bash). And I need to host a simple development server (expressjs) in the container. For reasons of I dont want to get into, I cant create a dockerfile ...
1
vote
1answer
99 views

ssl connection to aws serverless aurora

This is actually a follow-up question of this. I have created an Aurora Serverless database on AWS, created a VPC with 2 subnets as required by Serverless aurora and a Cloud9 connected to the subnet ...
0
votes
1answer
64 views

SSH tunneling and running commands inside Docker image

I'm pretty new to Docker and have a docker image, I need to do following: perform SSH tunneling to three different addresses from inside the docker image that to the outside. Then, I need to run a ...
-2
votes
1answer
50 views

How to test ssh tunelling?

Let's say I create a reverse ssh tunnel, with the following command. ssh -R 8080:localhost:11111 user@remote I can test that the tunnel is open on the remote with nc command nc -v 127.0.0.1 8080 ...
0
votes
1answer
40 views

Proxy a remote server as localhost

There is a server running in a "remotehost:some_port". I can connect to it from my linux machine like telnet remotehost remoteport. I have an application in the linux machine that is configured to ...
0
votes
0answers
47 views

SSH proxy jump interactive

I have a system wherein I am using SSH proxy jump as a way to connect from machine A to machine X through some number of intermediary steps. The advantage to this is that I can have an SSHkey on ...
0
votes
1answer
34 views

SSH keys for utility services on remote production server

For convienience I'd like to have a private SSH key on my remote server. But doing that creates a vulnerability if the server were hacked. Same as if I'd hard coded a password, anyone who broke in ...
0
votes
1answer
78 views

autossh options to open a port through a jumpbox

I'm connecting to a DB in a private subnet through a bastion host: ssh -N -M -i ${PEM_FILE} -L 3306:${DB_HOST}:3306 ec2-user@${BASTION_PUBLIC_IP} But the connection drops very quickly. Is there a ...
0
votes
1answer
23 views

Working around firewall to install packages

Hi I've been using linux for couple years now but never really sent much time on sysadmin stuff so I sort of know pieces of the answer but I need someone help me fill in the gaps. I have an EC2 ...
0
votes
1answer
20 views

How can I determine which request is periodically timing out through my ssh tunnel?

I am using a ssh tunnel from OSX combined with the SwitchyOmega chrome plugin to browse via a ubuntu box like this: ssh -D 54321 1.2.3.4 This timeout only occurs after I've started chrome. but even ...
0
votes
0answers
42 views

SSH tunnel for serving web sites from localhost

This is more question... When I do like this... I am able to serve my site to external IP of my VPS... ssh -L 8080:localhost:80 username@server.com How secure and is it okay to serve websites ...
0
votes
1answer
160 views

Can you connect to a VPN through an SSH reverse tunnel?

Say I have two machines, both running Linux; Machine A is running a VPN server and is behind a NAT. Machine B is the VPN client. Machine A creates a reverse SSH tunnel from itself to Machine B, ...
1
vote
1answer
200 views

Why can't I connect to MariaDB with Navicat through SSH tunnel?

I've always used Navicat on windows to manage my MySQL/Percona instances. A few days ago I bought a new server and have installed MariaDB 10.3.9. I can connect to it fine when I'm in a putty session ...
0
votes
0answers
64 views

Redirect HTTPS traffic into proxy or SSH tunnel?

Situation: I have a Linux machine, an application that attempts to download data by hard-coded URL over HTTPS. Problem is: ip of data server is blacklisted upstream. However, I have a machine free ...
0
votes
0answers
19 views

How to setup an outgoing proxy-like mechanism with only `ssh -f`?

I usually encounter this situation: I have an HPC protected by some firewall. I can access its login node through VPN and ssh. The ssh is capable of X-forward and forward port tunneling but no ...
0
votes
1answer
213 views

How to use socket file to access server if SSH Agent forwarding is enabled

I have bastion host. I connect to the bastion host using username/password. And I have private key for destination Server. Flow: Local Machine -> Bastion -> Destination I know that It's ...
0
votes
1answer
70 views

Simulate network environment and forwarding packets?

My question might be a bit weird, but here's some background first: I've got a client with devices in their own network with different IPs (mostly 192.168.x.x). From the outside, I connect to one of ...
-1
votes
1answer
67 views

When someone gains remote access to a server are there other ways to execute system commands other than the bash shell?

I am hardening a server and attempting to build a restrictive layer to a potential hacker even with root access to the server to do harm. If a user gains root or user access to the shell via say ...
0
votes
0answers
121 views

How to expand the usable IP range OPENVPN

I'm trying to set up a server that has over 1000 usable IPs, so I could in theory assign a static ip to that many devices. I have been able to set up an OpenVPN server with a /24 (mask 255.255.255.0) ...
0
votes
0answers
17 views

How can you restrict a specific dockerized webapp to tunneled connections?

So I have a few Docker webapps running on one server (swarm mode but without replication), like webapp1.mydomain.tld, webapp2.mydomain.tld accessible to the world. And I want mydomain.tld/phpldapadmin/...
0
votes
1answer
201 views

Securely sharing SSH access in a team with SSH bastion

I need to share SSH access to a number of servers with my teammates and looking for a secure way to do it. I came up with a configuration involving a SSH bastion server, but not sure how (and if) it ...
0
votes
1answer
65 views

Rewrite / Redirect Host With SSH Config File?

My company has three separate jump hosts. Something like: jump1.example.com, jump2.example.com, and jump3.example.com All internal servers must be accessed through these jumphosts: local ---> ...
0
votes
0answers
91 views

High CPU blocking performance on SSH tunnel with PHP-FPM

I've a Debian 9 VPS set up with Apache and PHP-FPM. It connects to another VPS to access a common database server VPS via an SSH tunnel. Mostly this works fine. Running a test for broken links ...
0
votes
1answer
93 views

End-End Encryption on SSH passing though 'untrusted' jump servers

I need to SSH between 2 "clients", both behind CGNATs, by using a third party server as a jump. This use case has been covered on this site already but: How do I make it so the SSH traffic is not ...
0
votes
0answers
29 views

Remote Debugging Through port 22

my IDE is running on a windows box 192.168.1.1, by enable debugging I have to start the debug server and listen on port 9000 then I instruct the python application running on the remote Linux box 192....
0
votes
1answer
156 views

Forward forwarded port in Docker

I have some trouble forwarding ports that are LocalForward to the container via SSH Tunnel. The whole network looks like this: This is my Dockerfile for the GW Container: FROM ubuntu:latest RUN ...
1
vote
0answers
315 views

Match address rule in sshd_config, , difference between localhost, 127.0.0.1 and [::1]

I would like to understand why these three rules in sshd_config behave differently : Match host localhost PasswordAuthentication yes Match address 127.0.0.1 PasswordAuthentication yes Match ...
1
vote
2answers
33 views

How to find the port used by sshd for a port bind without sudo?

To remove a given port bind the pid can be found with sudo netstat -lnpt and then removed with kill pid. As the process name is known (sshd) the non sudoer user who started it may found the pid with : ...
0
votes
0answers
49 views

Use ssh to redirect ports for VPN to Windows VPN-Server

I have a Windows 2016 Server configured with SSTP VPN in my private network. There is a public IPV6 address and the IPV4 address is behind carrier grade nat. So there is no way to access my VPN server ...
0
votes
0answers
49 views

Hop SSH servers with same key and escalate to root then query mysql and export results

Ideally, I would like to use a some sort of GUI to perform MySQL queries and be able to export results to the host computer. I need my host to ssh into a jump server, then ssh to another server, ...
0
votes
1answer
221 views

SSH Tunnel connected but can't git clone

I believe this is a fairly simple one, but on the face of things I am sure its not "wrong". I am trying to ssh tunnel in from my linux machine into a OSx machine that has access to my VPN. Setting ...
2
votes
2answers
2k views

ssh port forwarding with firewall-cmd

I'm trying to do an ssh tunnel into a server behind NAT: ssh from laptop --> Host with port forwarding in firewall --> Get directly into guest (172.16.0.2, behind host NAT). Using iptables on Host - ...
0
votes
1answer
113 views

how to forbid connecting to localhost for ssh socks5 proxy

when I start ssh socks5 proxy like that ssh user@localhost -D 0.0.0.0:1080 it allows to anyone to connect to localhost like curl --socks5 server.com localhost:12345 which can be a security issue for ...
0
votes
2answers
786 views

Eroor: $ ssh: Could not resolve hostname [HOSTNAME]: Name or service not known

I am on windows 10 machine. I need to ssh to our Bastion and then do port forwarding to connect to AWS instance. I have a config file that I use to ssh. My config file is as following: Host [host] ...