A question about /ssh/revdial #4752
-
|
I'm a new user of ShellHub and I have a question. When an SSH client connects to a device, why doesn't it directly query the ConnectionManager cache to obtain the dialer, but instead let the agent initiate the /ssh/revdial?revdial.dialer=uID request to obtain the dialer through the uID? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
The reason the SSH client doesn’t directly access the When a device connects to ShellHub, it establishes a persistent WebSocket connection to the server. This WebSocket isn’t used for data transfer in the actual SSH sessions — it acts more like a control channel, allowing the server to send commands or requests to the agent (such as asking it to initiate a new tunnel). Whenever an SSH client initiates a connection, ShellHub generates a unique identifier (uid) for that session and stores it. Then, using the existing WebSocket connection, the server sends a message to the agent, instructing it to open a new connection to |
Beta Was this translation helpful? Give feedback.
The reason the SSH client doesn’t directly access the
ConnectionManagercache to get the dialer and instead relies on the agent to initiate the/ssh/revdial?revdial.dialer=uidis rooted in ShellHub’s architecture and its use of reverse tunneling over a persistent WebSocket control channel.When a device connects to ShellHub, it establishes a persistent WebSocket connection to the server. This WebSocket isn’t used for data transfer in the actual SSH sessions — it acts more like a control channel, allowing the server to send commands or requests to the agent (such as asking it to initiate a new tunnel).
Whenever an SSH client initiates a connection, ShellHub generates a unique identifier (u…