diff options
author | 2014-01-19 00:39:40 +0000 | |
---|---|---|
committer | 2014-01-19 00:39:40 +0000 | |
commit | ec33a7664d2f3a19abd038ef7c5985861157bd44 (patch) | |
tree | 22855fb4a15f60db7514516e842c14d15735bab8 | |
parent | we no long use the /var/hash files, but rely on the SHA256.sig file. (diff) | |
download | wireguard-openbsd-ec33a7664d2f3a19abd038ef7c5985861157bd44.tar.xz wireguard-openbsd-ec33a7664d2f3a19abd038ef7c5985861157bd44.zip |
With the earlier initialization of the random subsystem, random_hostseed()
is no longer providing significant value. The random subsystem is in
pretty good state, and moments later userland will feed the dmesg.
ok jsing
-rw-r--r-- | sys/dev/rnd.c | 12 | ||||
-rw-r--r-- | sys/dev/rndvar.h | 3 | ||||
-rw-r--r-- | sys/kern/init_main.c | 4 |
3 files changed, 3 insertions, 16 deletions
diff --git a/sys/dev/rnd.c b/sys/dev/rnd.c index 3995f3967dd..39bfaf1c1e0 100644 --- a/sys/dev/rnd.c +++ b/sys/dev/rnd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rnd.c,v 1.151 2014/01/19 00:24:01 deraadt Exp $ */ +/* $OpenBSD: rnd.c,v 1.152 2014/01/19 00:39:40 deraadt Exp $ */ /* * Copyright (c) 2011 Theo de Raadt. @@ -783,16 +783,6 @@ random_start(void) timeout_set(&rnd_timeout, dequeue_randomness, NULL); } -void -random_hostseed(void) -{ - if (msgbufp == NULL || msgbufp->msg_magic != MSG_MAGIC) - return; - add_entropy_words((u_int32_t *)msgbufp->msg_bufc, - msgbufp->msg_bufs / sizeof(u_int32_t)); - arc4_init(NULL, NULL); -} - int randomopen(dev_t dev, int flag, int mode, struct proc *p) { diff --git a/sys/dev/rndvar.h b/sys/dev/rndvar.h index 165e7f8ea96..5e631d92dbf 100644 --- a/sys/dev/rndvar.h +++ b/sys/dev/rndvar.h @@ -1,4 +1,4 @@ -/* $OpenBSD: rndvar.h,v 1.31 2013/03/29 01:35:37 tedu Exp $ */ +/* $OpenBSD: rndvar.h,v 1.32 2014/01/19 00:39:40 deraadt Exp $ */ /* * Copyright (c) 1996,2000 Michael Shalayeff. @@ -71,7 +71,6 @@ extern struct rndstats rndstats; void random_init(void); void random_start(void); -void random_hostseed(void); void enqueue_randomness(int, int); void arc4random_buf(void *, size_t); diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index 809a592ddcc..aa19b48cebd 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: init_main.c,v 1.198 2014/01/19 00:22:58 deraadt Exp $ */ +/* $OpenBSD: init_main.c,v 1.199 2014/01/19 00:39:40 deraadt Exp $ */ /* $NetBSD: init_main.c,v 1.84.4.1 1996/06/02 09:08:06 mrg Exp $ */ /* @@ -354,8 +354,6 @@ main(void *framep) /* Configure the devices */ cpu_configure(); - random_hostseed(); - /* Configure virtual memory system, set vm rlimits. */ uvm_init_limits(p); |