summaryrefslogtreecommitdiff
path: root/clientloop.c
diff options
context:
space:
mode:
Diffstat (limited to 'clientloop.c')
-rw-r--r--clientloop.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/clientloop.c b/clientloop.c
index 4805f3c83..1ed245e22 100644
--- a/clientloop.c
+++ b/clientloop.c
@@ -59,7 +59,7 @@
59 */ 59 */
60 60
61#include "includes.h" 61#include "includes.h"
62RCSID("$OpenBSD: clientloop.c,v 1.53 2001/03/06 01:08:27 millert Exp $"); 62RCSID("$OpenBSD: clientloop.c,v 1.54 2001/04/04 00:06:53 markus Exp $");
63 63
64#include "ssh.h" 64#include "ssh.h"
65#include "ssh1.h" 65#include "ssh1.h"
@@ -73,6 +73,7 @@ RCSID("$OpenBSD: clientloop.c,v 1.53 2001/03/06 01:08:27 millert Exp $");
73#include "buffer.h" 73#include "buffer.h"
74#include "bufaux.h" 74#include "bufaux.h"
75#include "key.h" 75#include "key.h"
76#include "kex.h"
76#include "log.h" 77#include "log.h"
77#include "readconf.h" 78#include "readconf.h"
78#include "clientloop.h" 79#include "clientloop.h"
@@ -130,6 +131,9 @@ static int connection_out; /* Connection to server (output). */
130void client_init_dispatch(void); 131void client_init_dispatch(void);
131int session_ident = -1; 132int session_ident = -1;
132 133
134/*XXX*/
135extern Kex *xxx_kex;
136
133/* Returns the user\'s terminal to normal mode if it had been put in raw mode. */ 137/* Returns the user\'s terminal to normal mode if it had been put in raw mode. */
134 138
135void 139void
@@ -548,6 +552,11 @@ process_escapes(Buffer *bin, Buffer *bout, Buffer *berr, char *buf, int len)
548 /* We have been continued. */ 552 /* We have been continued. */
549 continue; 553 continue;
550 554
555 case 'R':
556 debug("Rekeying");
557 kex_send_kexinit(xxx_kex);
558 continue;
559
551 case '&': 560 case '&':
552 /* XXX does not work yet with proto 2 */ 561 /* XXX does not work yet with proto 2 */
553 if (compat20) 562 if (compat20)
@@ -762,7 +771,7 @@ client_process_output(fd_set * writeset)
762void 771void
763client_process_buffered_input_packets(void) 772client_process_buffered_input_packets(void)
764{ 773{
765 dispatch_run(DISPATCH_NONBLOCK, &quit_pending, NULL); 774 dispatch_run(DISPATCH_NONBLOCK, &quit_pending, compat20 ? xxx_kex : NULL);
766} 775}
767 776
768/* scan buf[] for '~' before sending data to the peer */ 777/* scan buf[] for '~' before sending data to the peer */
@@ -1196,7 +1205,10 @@ client_input_channel_req(int type, int plen, void *ctxt)
1196void 1205void
1197client_init_dispatch_20(void) 1206client_init_dispatch_20(void)
1198{ 1207{
1199 dispatch_init(&dispatch_protocol_error); 1208 int i;
1209 /* dispatch_init(&dispatch_protocol_error); */
1210 for (i = 50; i <= 254; i++)
1211 dispatch_set(i, &dispatch_protocol_error);
1200 dispatch_set(SSH2_MSG_CHANNEL_CLOSE, &channel_input_oclose); 1212 dispatch_set(SSH2_MSG_CHANNEL_CLOSE, &channel_input_oclose);
1201 dispatch_set(SSH2_MSG_CHANNEL_DATA, &channel_input_data); 1213 dispatch_set(SSH2_MSG_CHANNEL_DATA, &channel_input_data);
1202 dispatch_set(SSH2_MSG_CHANNEL_EOF, &channel_input_ieof); 1214 dispatch_set(SSH2_MSG_CHANNEL_EOF, &channel_input_ieof);