- markus@cvs.openbsd.org 2001/02/28 09:57:07
     [packet.c packet.h sshconnect2.c]
     in ssh protocol v2 use ignore messages for padding (instead of
     trailing \0).
diff --git a/sshconnect2.c b/sshconnect2.c
index 12335e8..8b52323 100644
--- a/sshconnect2.c
+++ b/sshconnect2.c
@@ -23,7 +23,7 @@
  */
 
 #include "includes.h"
-RCSID("$OpenBSD: sshconnect2.c,v 1.48 2001/02/15 23:19:59 markus Exp $");
+RCSID("$OpenBSD: sshconnect2.c,v 1.49 2001/02/28 09:57:07 markus Exp $");
 
 #include <openssl/bn.h>
 #include <openssl/md5.h>
@@ -658,9 +658,10 @@
 	packet_put_cstring(authctxt->service);
 	packet_put_cstring(authctxt->method->name);
 	packet_put_char(0);
-	ssh_put_password(password);
+	packet_put_cstring(password);
 	memset(password, 0, strlen(password));
 	xfree(password);
+	packet_inject_ignore(64);
 	packet_send();
 	packet_write_wait();
 	return 1;
@@ -928,13 +929,14 @@
 
 		response = cli_prompt(prompt, echo);
 
-		ssh_put_password(response);
+		packet_put_cstring(response);
 		memset(response, 0, strlen(response));
 		xfree(response);
 		xfree(prompt);
 	}
 	packet_done(); /* done with parsing incoming message. */
 
+	packet_inject_ignore(64);
 	packet_send();
 	packet_write_wait();
 }