[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Dispatch incoming connections depending on username


I have not yet tried libssh and I want to know if my goal is reachable
with it before I do.

Is it possible with libssh to implement a SSH server so it listens to
incoming connections and split it, depending on the username, to another
port/another IP address?

Simple example (with almost real information):
I have a standard SSH server listening on port 2222 and another one
listening on IP address, port 22 (actually, it is a docker
container, running a standard SSH server). What I want to achieve is a
program listening on port 22 that will act like a direct connection to
port 2222 for any user but *foo* and will act like a direct connection
to if the user is *foo*, so when someone do /ssh
foo@xxxxxxxxxx/ it actually connects to the inner docker.

I already searched for something that would do that but until now, I
found nothing. If you know anything I am interested.

So, to summarize: is it possible or better already done?

Thank you.


Attachment: signature.asc
Description: OpenPGP digital signature

Re: Dispatch incoming connections depending on usernameJoseph Southwell <joseph@xxxxxxxxxxxxx>
Archive administrator: postmaster@lists.cynapses.org