diff gensignkey.c @ 852:7540c0822374 ecc

Various cleanups and fixes for warnings
author Matt Johnston <matt@ucc.asn.au>
date Tue, 12 Nov 2013 23:02:32 +0800
parents f4bb964c8678
children 04ede40a529a
line wrap: on
line diff
--- a/gensignkey.c	Sat Nov 09 00:14:28 2013 +0800
+++ b/gensignkey.c	Tue Nov 12 23:02:32 2013 +0800
@@ -85,6 +85,8 @@
 	/* now we can generate the key */
 	key = new_sign_key();
 
+	seedrandom();
+
 	switch(keytype) {
 #ifdef DROPBEAR_RSA
 		case DROPBEAR_SIGNKEY_RSA:
@@ -112,6 +114,8 @@
 			dropbear_exit("Internal error");
 	}
 
+	seedrandom();
+
 	buf = buf_new(MAX_PRIVKEY_SIZE); 
 
 	buf_put_priv_key(buf, key, keytype);