C
C
Const V2014-11-21 16:50:24
SSH
Const V, 2014-11-21 16:50:24

Is it possible to forward one port to two computers at once?

At work, the very minimum of ports is open, in fact three: 21 for ftp, 22 for ssh and 80, that is, I can only log out of my work computer via ssh to port 22. Somehow I tried to change the ssh port on my home computer from work, in the end I had to edit the config back through my mobile phone. And in the home network there are two computers that I want to access via ssh. Is there any way to make it possible to connect to both computers on the same port without changing the port forwarding on the router remotely?
The second problem is that with working from home via ftp, I have to forward port 21 on the router from one computer to another every time, depending on the one from which I need to connect to an external ftp server.
Also, the Ubuntu graphical update program cannot work simultaneously on both computers, because it definitely needs port 80, and the router cannot give it to two computers at once, but this is at least solved by updating through the console.
Is there any solution to this problem, provided that I cannot use different external ports? I have already been advised to go first via ssh to one computer, and then in this session to go through the local network via ssh to the second computer, but it looks like some kind of terrible perversion... :-( And what to do with ftp in this case? direction to google?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
Y
Yuri Mikhailov, 2014-11-21
@yurijmi

Try to set up a VPN on the SSH port. In fact, there will be access to the entire locale

N
neolink, 2014-11-21
@neolink

one port to two others how do you imagine it? You need some other condition to determine where to send packets.
I don’t know what kind of router you have, but this can be solved by forwarding, for example, 4222 and 4333 ports to different computers, even if he doesn’t know how to do this, you can change the ssh port on different computers.
you can also go to the router/computer and connect from it anywhere via ssh
also via ssh you can do port_redirect to any computer on the local network (after connecting your local port. for example 5000 will be associated with any combination of ip:port available to the host to which you are logged in)

V
Valentin, 2014-11-21
@vvpoloskin

Can. set up ssh as a socks proxy and use some kind of socksifiers (proxychains?) to access resources

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question