summaryrefslogtreecommitdiff
path: root/rsa.c
diff options
context:
space:
mode:
Diffstat (limited to 'rsa.c')
-rw-r--r--rsa.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/rsa.c b/rsa.c
index 597d20fb8..1df8fbc95 100644
--- a/rsa.c
+++ b/rsa.c
@@ -35,7 +35,7 @@
35*/ 35*/
36 36
37#include "includes.h" 37#include "includes.h"
38RCSID("$Id: rsa.c,v 1.7 2000/01/29 09:40:22 damien Exp $"); 38RCSID("$Id: rsa.c,v 1.8 2000/03/05 05:10:46 damien Exp $");
39 39
40#include "rsa.h" 40#include "rsa.h"
41#include "ssh.h" 41#include "ssh.h"
@@ -49,6 +49,7 @@ rsa_alive()
49{ 49{
50 RSA *key; 50 RSA *key;
51 51
52 seed_rng();
52 key = RSA_generate_key(32, 3, NULL, NULL); 53 key = RSA_generate_key(32, 3, NULL, NULL);
53 if (key == NULL) 54 if (key == NULL)
54 return (0); 55 return (0);
@@ -77,7 +78,7 @@ keygen_progress(int p, int n, void *arg)
77void 78void
78seed_rng() 79seed_rng()
79{ 80{
80 char buf[32]; 81 char buf[64];
81 82
82 get_random_bytes(buf, sizeof(buf)); 83 get_random_bytes(buf, sizeof(buf));
83 RAND_seed(buf, sizeof(buf)); 84 RAND_seed(buf, sizeof(buf));