summaryrefslogtreecommitdiff
path: root/PROTOCOL.mux
diff options
context:
space:
mode:
Diffstat (limited to 'PROTOCOL.mux')
-rw-r--r--PROTOCOL.mux30
1 files changed, 24 insertions, 6 deletions
diff --git a/PROTOCOL.mux b/PROTOCOL.mux
index 2a5817bd7..9ad256602 100644
--- a/PROTOCOL.mux
+++ b/PROTOCOL.mux
@@ -73,6 +73,13 @@ non-multiplexed ssh(1) connection. Two additional cases that the
73client must cope with are it receiving a signal itself and the 73client must cope with are it receiving a signal itself and the
74server disconnecting without sending an exit message. 74server disconnecting without sending an exit message.
75 75
76A master may also send a MUX_S_TTY_ALLOC_FAIL before MUX_S_EXIT_MESSAGE
77if remote TTY allocation was unsuccessful. The client may use this to
78return its local tty to "cooked" mode.
79
80 uint32 MUX_S_TTY_ALLOC_FAIL
81 uint32 session id
82
763. Health checks 833. Health checks
77 84
78The client may request a health check/PID report from a server: 85The client may request a health check/PID report from a server:
@@ -149,10 +156,21 @@ The client then sends its standard input and output file descriptors
149 156
150The contents of "reserved" are currently ignored. 157The contents of "reserved" are currently ignored.
151 158
152A server may reply with a MUX_S_SESSION_OPEED, a MUX_S_PERMISSION_DENIED 159A server may reply with a MUX_S_SESSION_OPENED, a MUX_S_PERMISSION_DENIED
153or a MUX_S_FAILURE. 160or a MUX_S_FAILURE.
154 161
1558. Status messages 1628. Requesting shutdown of mux listener
163
164A client may request the master to stop accepting new multiplexing requests
165and remove its listener socket.
166
167 uint32 MUX_C_STOP_LISTENING
168 uint32 request id
169
170A server may reply with a MUX_S_OK, a MUX_S_PERMISSION_DENIED or a
171MUX_S_FAILURE.
172
1739. Status messages
156 174
157The MUX_S_OK message is empty: 175The MUX_S_OK message is empty:
158 176
@@ -169,7 +187,7 @@ The MUX_S_PERMISSION_DENIED and MUX_S_FAILURE include a reason:
169 uint32 client request id 187 uint32 client request id
170 string reason 188 string reason
171 189
1729. Protocol numbers 19010. Protocol numbers
173 191
174#define MUX_MSG_HELLO 0x00000001 192#define MUX_MSG_HELLO 0x00000001
175#define MUX_C_NEW_SESSION 0x10000002 193#define MUX_C_NEW_SESSION 0x10000002
@@ -178,6 +196,7 @@ The MUX_S_PERMISSION_DENIED and MUX_S_FAILURE include a reason:
178#define MUX_C_OPEN_FWD 0x10000006 196#define MUX_C_OPEN_FWD 0x10000006
179#define MUX_C_CLOSE_FWD 0x10000007 197#define MUX_C_CLOSE_FWD 0x10000007
180#define MUX_C_NEW_STDIO_FWD 0x10000008 198#define MUX_C_NEW_STDIO_FWD 0x10000008
199#define MUX_C_STOP_LISTENING 0x10000009
181#define MUX_S_OK 0x80000001 200#define MUX_S_OK 0x80000001
182#define MUX_S_PERMISSION_DENIED 0x80000002 201#define MUX_S_PERMISSION_DENIED 0x80000002
183#define MUX_S_FAILURE 0x80000003 202#define MUX_S_FAILURE 0x80000003
@@ -185,6 +204,7 @@ The MUX_S_PERMISSION_DENIED and MUX_S_FAILURE include a reason:
185#define MUX_S_ALIVE 0x80000005 204#define MUX_S_ALIVE 0x80000005
186#define MUX_S_SESSION_OPENED 0x80000006 205#define MUX_S_SESSION_OPENED 0x80000006
187#define MUX_S_REMOTE_PORT 0x80000007 206#define MUX_S_REMOTE_PORT 0x80000007
207#define MUX_S_TTY_ALLOC_FAIL 0x80000008
188 208
189#define MUX_FWD_LOCAL 1 209#define MUX_FWD_LOCAL 1
190#define MUX_FWD_REMOTE 2 210#define MUX_FWD_REMOTE 2
@@ -192,12 +212,10 @@ The MUX_S_PERMISSION_DENIED and MUX_S_FAILURE include a reason:
192 212
193XXX TODO 213XXX TODO
194XXX extended status (e.g. report open channels / forwards) 214XXX extended status (e.g. report open channels / forwards)
195XXX graceful close (delete listening socket, but keep existing sessions active)
196XXX lock (maybe) 215XXX lock (maybe)
197XXX watch in/out traffic (pre/post crypto) 216XXX watch in/out traffic (pre/post crypto)
198XXX inject packet (what about replies) 217XXX inject packet (what about replies)
199XXX server->client error/warning notifications 218XXX server->client error/warning notifications
200XXX port0 rfwd (need custom response message)
201XXX send signals via mux 219XXX send signals via mux
202 220
203$OpenBSD: PROTOCOL.mux,v 1.4 2011/01/31 21:42:15 djm Exp $ 221$OpenBSD: PROTOCOL.mux,v 1.7 2011/05/08 12:52:01 djm Exp $