Bugzilla – Attachment 73 Details for
Bug 215
No warning for failed ssh -v -R
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
please try this
A (text/plain), 3.33 KB, created by
Markus Friedl
on 2002-04-15 00:52:41 AEST
(
hide
)
Description:
please try this
Filename:
MIME Type:
Creator:
Markus Friedl
Created:
2002-04-15 00:52:41 AEST
Size:
3.33 KB
patch
obsolete
>Index: channels.c >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/channels.c,v >retrieving revision 1.172 >diff -u -r1.172 channels.c >--- channels.c 25 Mar 2002 21:13:51 -0000 1.172 >+++ channels.c 14 Apr 2002 14:47:52 -0000 >@@ -2126,7 +2126,7 @@ > const char *address_to_bind = "0.0.0.0"; > packet_start(SSH2_MSG_GLOBAL_REQUEST); > packet_put_cstring("tcpip-forward"); >- packet_put_char(0); /* boolean: want reply */ >+ packet_put_char(1); /* boolean: want reply */ > packet_put_cstring(address_to_bind); > packet_put_int(listen_port); > packet_send(); >Index: clientloop.c >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/clientloop.c,v >retrieving revision 1.99 >diff -u -r1.99 clientloop.c >--- clientloop.c 21 Mar 2002 23:07:37 -0000 1.99 >+++ clientloop.c 14 Apr 2002 14:47:55 -0000 >@@ -1314,6 +1314,7 @@ > client_init_dispatch_20(void) > { > dispatch_init(&dispatch_protocol_error); >+ > dispatch_set(SSH2_MSG_CHANNEL_CLOSE, &channel_input_oclose); > dispatch_set(SSH2_MSG_CHANNEL_DATA, &channel_input_data); > dispatch_set(SSH2_MSG_CHANNEL_EOF, &channel_input_ieof); >@@ -1327,6 +1328,10 @@ > > /* rekeying */ > dispatch_set(SSH2_MSG_KEXINIT, &kex_input_kexinit); >+ >+ /* global request reply messages */ >+ dispatch_set(SSH2_MSG_REQUEST_FAILURE, &client_global_request_reply); >+ dispatch_set(SSH2_MSG_REQUEST_SUCCESS, &client_global_request_reply); > } > static void > client_init_dispatch_13(void) >Index: clientloop.h >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/clientloop.h,v >retrieving revision 1.6 >diff -u -r1.6 clientloop.h >--- clientloop.h 26 Jun 2001 17:27:23 -0000 1.6 >+++ clientloop.h 14 Apr 2002 14:47:55 -0000 >@@ -37,3 +37,4 @@ > > /* Client side main loop for the interactive session. */ > int client_loop(int, int, int); >+void client_global_request_reply(int type, u_int32_t seq, void *ctxt); >Index: ssh.c >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/ssh.c,v >retrieving revision 1.169 >diff -u -r1.169 ssh.c >--- ssh.c 26 Mar 2002 11:37:05 -0000 1.169 >+++ ssh.c 14 Apr 2002 14:47:57 -0000 >@@ -138,6 +138,9 @@ > /* Should we execute a command or invoke a subsystem? */ > int subsystem_flag = 0; > >+/* # of replies received for global requests */ >+static int client_global_request_id = 0; >+ > /* Prints a help message to the user. This function never returns. */ > > static void >@@ -1019,6 +1022,27 @@ > if (type == SSH2_MSG_CHANNEL_FAILURE) > fatal("Request for subsystem '%.*s' failed on channel %d", > len, (u_char *)buffer_ptr(&command), id); >+} >+ >+void >+client_global_request_reply(int type, u_int32_t seq, void *ctxt) >+{ >+ int i; >+ >+ i = client_global_request_id++; >+ if (i >= options.num_remote_forwards) { >+ error("client_global_request_reply: too many replies %d > %d", >+ i, options.num_remote_forwards); >+ return; >+ } >+ debug("remote forward %s for: listen %d, connect %s:%d", >+ type == SSH2_MSG_REQUEST_SUCCESS ? "success" : "failure", >+ options.remote_forwards[i].port, >+ options.remote_forwards[i].host, >+ options.remote_forwards[i].host_port); >+ if (type == SSH2_MSG_REQUEST_FAILURE) >+ log("Warning: remote port forwarding failed for listen port %d", >+ options.remote_forwards[i].port); > } > > /* request pty/x11/agent/tcpfwd/shell for channel */
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 215
: 73