From 12b4a6504b3f7bad3c144761714fb429669f56d0 Mon Sep 17 00:00:00 2001 From: Darren Tucker Date: Sun, 21 Jun 2009 18:14:48 +1000 Subject: - andreas@cvs.openbsd.org 2009/05/27 06:34:36 [kex.c kex.h] Move the KEX_COOKIE_LEN define to kex.h ok markus@ --- ChangeLog | 4 ++++ clientloop.c | 8 +++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 11b75e92..ba0cfd79 100644 --- a/ChangeLog +++ b/ChangeLog @@ -67,6 +67,10 @@ Send SSH2_MSG_DISCONNECT when the client disconnects. From a larger change from Martin Forssen, maf at appgate dot com. ok markus@ + - andreas@cvs.openbsd.org 2009/05/27 06:34:36 + [kex.c kex.h] + Move the KEX_COOKIE_LEN define to kex.h + ok markus@ 20090616 - (dtucker) [configure.ac defines.h] Bug #1607: handle the case where fsid_t diff --git a/clientloop.c b/clientloop.c index 2cb8c3a4..d5a06556 100644 --- a/clientloop.c +++ b/clientloop.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clientloop.c,v 1.210 2009/05/25 06:48:01 andreas Exp $ */ +/* $OpenBSD: clientloop.c,v 1.211 2009/05/27 06:33:39 andreas Exp $ */ /* * Author: Tatu Ylonen * Copyright (c) 1995 Tatu Ylonen , Espoo, Finland @@ -1476,6 +1476,12 @@ client_loop(int have_pty, int escape_char_arg, int ssh2_chan_id) /* Stop watching for window change. */ signal(SIGWINCH, SIG_DFL); + packet_start(SSH2_MSG_DISCONNECT); + packet_put_int(SSH2_DISCONNECT_BY_APPLICATION); + packet_put_cstring("disconnected by user"); + packet_send(); + packet_write_wait(); + channel_free_all(); if (have_pty) -- cgit v1.2.3