Dropbear 0.44 release

Matt Johnston matt at ucc.asn.au
Fri Jan 14 13:11:15 WST 2005


On Mon, Jan 10, 2005 at 11:30:00PM +0800, Matt Johnston wrote:
> > b) Run a "scp <file> <host>" command to a host you never connected before. 
> > Now the following question is issued:
> > 
> > Host '192.168.193.251' is not in the trusted hosts file.
> > (fingerprint md5 c0:e0:89:a3:62:36:3b:16:86:13:2e:9b:11:f3:6b:71)
> > Do you want to continue connecting? (y/n)
> > 
> > Whatever I type I can't continue. Only a CTRL-C will work (or a kill from 
> > another terminal). Running the dbclient before the scp command and adding 
> > the host to the list of known hosts solves the problem.
> 
> Ah, I had forgotten that this was the issue, I was thinking
> it was that password auth failed with scp - sorry. I'll look
> at a patch for it.

Attached is a patch which should fix the issue, it'll be in
the next release.  As usual let me know if there are any
issues with it.

Matt
-------------- next part --------------
--- cli-kex.c
+++ cli-kex.c
@@ -115,13 +115,23 @@
 static void ask_to_confirm(unsigned char* keyblob, unsigned int keybloblen) {
 
 	char* fp = NULL;
+	FILE *tty = NULL;
+	char response = 'z';
 
 	fp = sign_key_fingerprint(keyblob, keybloblen);
 	fprintf(stderr, "\nHost '%s' is not in the trusted hosts file.\n(fingerprint %s)\nDo you want to continue connecting? (y/n)\n", 
 			cli_opts.remotehost, 
 			fp);
 
-	if (getc(stdin) == 'y') {
+	tty = fopen(_PATH_TTY, "r");
+	if (tty) {
+		response = getc(tty);
+		fclose(tty);
+	} else {
+		response = getc(stdin);
+	}
+
+	if (response == 'y') {
 		m_free(fp);
 		return;
 	}


More information about the Dropbear mailing list