aboutsummaryrefslogtreecommitdiff
path: root/libssh/kex.c
diff options
context:
space:
mode:
authorAris Adamantiadis <aris@0xbadc0de.be>2005-08-20 23:53:42 +0000
committerAris Adamantiadis <aris@0xbadc0de.be>2005-08-20 23:53:42 +0000
commit6c0503f6c68ba92638516257c9991bcfd660e41e (patch)
treea75b5da9f1cedf2eabf3a82067a75116e04f544b /libssh/kex.c
parentbddce3a5da9f24c18a9ca69e08da50ca4de4671d (diff)
downloadlibssh-6c0503f6c68ba92638516257c9991bcfd660e41e.tar.gz
libssh-6c0503f6c68ba92638516257c9991bcfd660e41e.tar.xz
libssh-6c0503f6c68ba92638516257c9991bcfd660e41e.zip
some debugging things in ssh1 key exchange
git-svn-id: svn+ssh://svn.berlios.de/svnroot/repos/libssh/trunk@14 7dcaeef0-15fb-0310-b436-a5af3365683c
Diffstat (limited to 'libssh/kex.c')
-rw-r--r--libssh/kex.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libssh/kex.c b/libssh/kex.c
index 6716fc92..45ec3f77 100644
--- a/libssh/kex.c
+++ b/libssh/kex.c
@@ -419,6 +419,7 @@ int ssh_get_kex1(SSH_SESSION *session){
enc_session=encrypt_session_key(session,svr,host);
bits=string_len(enc_session)*8 - 7;
+ ssh_say(2,"%d bits,%d bytes encrypted session\n",bits,string_len(enc_session));
bits=htons(bits);
/* the encrypted mpint */
buffer_add_data(session->out_buffer,&bits,sizeof(u16));
@@ -434,8 +435,7 @@ int ssh_get_kex1(SSH_SESSION *session){
session->current_crypto=session->next_crypto;
session->next_crypto=NULL;
if(packet_wait(session,SSH_SMSG_SUCCESS,1)){
- printf("qqchose a merdé: %s\n",ssh_get_error(session));
- exit(1);
+ ssh_set_error(session,SSH_FATAL,"Key exchange failed : %s\n",ssh_get_error(session));
return -1;
}
ssh_say(1,"received SSH_SMSG_SUCCESS\n");