summaryrefslogtreecommitdiff
path: root/share
diff options
context:
space:
mode:
authorJasper Lievisse Adriaanse <jasper@cvs.openbsd.org>2018-04-28 15:45:00 +0000
committerJasper Lievisse Adriaanse <jasper@cvs.openbsd.org>2018-04-28 15:45:00 +0000
commitd2aaab80e37b4e76e5cd539983916e5d7dbaf773 (patch)
treee0d12c3bee51150c5e294631e23df47429d120d4 /share
parent88c894b365edc9ba3d99f1dba14020c90bf81e72 (diff)
replace add_*_randomness with enqueue_randomness()
this gets rid of the source annotation which doesn't really add anything other than adding complexitiy. randomess is generally good enough that the few extra bits that the source type would add are not worth it. ok mikeb@ deraadt@
Diffstat (limited to 'share')
-rw-r--r--share/man/man4/acpihve.46
-rw-r--r--share/man/man4/man4.octeon/octrng.46
-rw-r--r--share/man/man4/uonerng.48
-rw-r--r--share/man/man4/urng.48
-rw-r--r--share/man/man9/arc4random.948
5 files changed, 20 insertions, 56 deletions
diff --git a/share/man/man4/acpihve.4 b/share/man/man4/acpihve.4
index 5cbdedd713c..d251e212dcb 100644
--- a/share/man/man4/acpihve.4
+++ b/share/man/man4/acpihve.4
@@ -1,4 +1,4 @@
-.\" $OpenBSD: acpihve.4,v 1.1 2017/01/10 08:54:14 jsg Exp $
+.\" $OpenBSD: acpihve.4,v 1.2 2018/04/28 15:44:59 jasper Exp $
.\"
.\" Copyright (c) 2017 Jonathan Gray <jsg@openbsd.org>
.\"
@@ -14,7 +14,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: January 10 2017 $
+.Dd $Mdocdate: April 28 2018 $
.Dt ACPIHVE 4
.Os
.Sh NAME
@@ -29,7 +29,7 @@ The
driver feeds this entropy into the kernel's entropy pool.
.Sh SEE ALSO
.Xr acpi 4 ,
-.Xr add_true_randomness 9
+.Xr enqueue_randomness 9
.Sh HISTORY
The
.Nm
diff --git a/share/man/man4/man4.octeon/octrng.4 b/share/man/man4/man4.octeon/octrng.4
index fcc9eec758f..02d99a18b03 100644
--- a/share/man/man4/man4.octeon/octrng.4
+++ b/share/man/man4/man4.octeon/octrng.4
@@ -1,4 +1,4 @@
-.\" $OpenBSD: octrng.4,v 1.3 2015/10/22 11:01:49 sobrado Exp $
+.\" $OpenBSD: octrng.4,v 1.4 2018/04/28 15:44:59 jasper Exp $
.\"
.\" Copyright (c) 2013 Paul Irofti <pirofti@openbsd.org>
.\"
@@ -15,7 +15,7 @@
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
.\"
-.Dd $Mdocdate: October 22 2015 $
+.Dd $Mdocdate: April 28 2018 $
.Dt OCTRNG 4 octeon
.Os
.Sh NAME
@@ -32,7 +32,7 @@ After the 5 seconds it takes for the device to be initialized, the
.Nm
driver feeds the random subsystem's entropy pool 32 bits of data every
10 milliseconds through the
-.Xr add_true_randomness 9
+.Xr enqueue_randomness 9
API.
.Sh SEE ALSO
.Xr intro 4 ,
diff --git a/share/man/man4/uonerng.4 b/share/man/man4/uonerng.4
index 6f3baf7897e..b1fd07aeef6 100644
--- a/share/man/man4/uonerng.4
+++ b/share/man/man4/uonerng.4
@@ -1,4 +1,4 @@
-.\" $OpenBSD: uonerng.4,v 1.2 2016/01/08 10:20:05 jmc Exp $
+.\" $OpenBSD: uonerng.4,v 1.3 2018/04/28 15:44:59 jasper Exp $
.\"
.\" Copyright (c) 2015 Devin Reade <gdr@gno.org>
.\"
@@ -14,7 +14,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: January 8 2016 $
+.Dd $Mdocdate: April 28 2018 $
.Dt ONERNG 4
.Os
.Sh NAME
@@ -29,7 +29,7 @@ driver provides support for the Moonbase Otago OneRNG, a USB true random
number generator (TRNG).
.Nm
reads raw entropy from the OneRNG and uses
-.Xr add_true_randomness 9
+.Xr enqueue_randomness 9
to add it to the system entropy pool.
.Pp
The OneRNG is capable of operating in one of several modes, some of
@@ -44,7 +44,7 @@ which is also the manufacturer's default mode.
.Sh SEE ALSO
.Xr intro 4 ,
.Xr usb 4 ,
-.Xr add_true_randomness 9
+.Xr enqueue_randomness 9
.Pp
Moonbase Otago:
.Lk http://onerng.info/onerng
diff --git a/share/man/man4/urng.4 b/share/man/man4/urng.4
index b7cf11f98d5..7a65ae50376 100644
--- a/share/man/man4/urng.4
+++ b/share/man/man4/urng.4
@@ -1,4 +1,4 @@
-.\" $OpenBSD: urng.4,v 1.4 2017/09/25 18:47:53 jasper Exp $
+.\" $OpenBSD: urng.4,v 1.5 2018/04/28 15:44:59 jasper Exp $
.\"
.\" Copyright (c) 2015 Sean Levy <attila@stalphonsos.com>
.\" Copyright (c) 2017 Jasper Lievisse Adriaanse <jasper@openbsd.org>
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: September 25 2017 $
+.Dd $Mdocdate: April 28 2018 $
.Dt URNG 4
.Os
.Sh NAME
@@ -31,7 +31,7 @@ driver provides support for various true random number generator
.Nm
reads raw entropy from the device at a (hardware dependent) interval
and stirs it into the system entropy pool with
-.Xr add_true_randomness 9 .
+.Xr enqueue_randomness 9 .
.Sh HARDWARE
The following devices are supported by this driver:
.Bl -tag -width "Altus Metrum"
@@ -43,7 +43,7 @@ This device is capable of providing entropy at 10Mbit/s.
.Sh SEE ALSO
.Xr intro 4 ,
.Xr usb 4 ,
-.Xr add_true_randomness 9
+.Xr enqueue_randomness 9
.Sh HISTORY
The
.Nm
diff --git a/share/man/man9/arc4random.9 b/share/man/man9/arc4random.9
index 13759d53c65..e7197195a75 100644
--- a/share/man/man9/arc4random.9
+++ b/share/man/man9/arc4random.9
@@ -1,4 +1,4 @@
-.\" $OpenBSD: arc4random.9,v 1.12 2015/11/23 17:53:57 jmc Exp $
+.\" $OpenBSD: arc4random.9,v 1.13 2018/04/28 15:44:59 jasper Exp $
.\"
.\" Copyright (c) 1996,2000 Michael Shalayeff
.\" All rights reserved.
@@ -23,20 +23,14 @@
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd $Mdocdate: November 23 2015 $
+.Dd $Mdocdate: April 28 2018 $
.Dt ARC4RANDOM 9
.Os
.Sh NAME
.Nm arc4random ,
.Nm arc4random_buf ,
.Nm arc4random_uniform ,
-.Nm add_true_randomness ,
-.Nm add_timer_randomness ,
-.Nm add_mouse_randomness ,
-.Nm add_tty_randomness ,
-.Nm add_net_randomness ,
-.Nm add_disk_randomness ,
-.Nm add_audio_randomness
+.Nm enqueue_randomness ,
.Nd kernel random subsystem
.Sh SYNOPSIS
.In sys/systm.h
@@ -48,19 +42,7 @@
.Fn arc4random_uniform "u_int32_t upper_bound"
.In dev/rndvar.h
.Ft void
-.Fn add_true_randomness "int"
-.Ft void
-.Fn add_timer_randomness "int"
-.Ft void
-.Fn add_mouse_randomness "int"
-.Ft void
-.Fn add_tty_randomness "int"
-.Ft void
-.Fn add_net_randomness "int"
-.Ft void
-.Fn add_disk_randomness "int"
-.Ft void
-.Fn add_audio_randomness "int"
+.Fn enqueue_randomness "int"
.Sh DESCRIPTION
The
.Fn add_random
@@ -69,28 +51,10 @@ to create a key for the ChaCha stream cipher used in the
.Fn arc4random
series of functions.
.Pp
-The
-.Fn add_mouse_randomness ,
-.Fn add_tty_randomness ,
-.Fn add_net_randomness ,
-.Fn add_disk_randomness
-and
-.Fn add_audio_randomness
-routines are used to
-supply data for the random data source device for further processing.
-The processing involves calculating inter-event timedelta and inserting
-it into a pool which is cryptographically mixed multiple times.
-.Pp
-.Fn add_true_randomness
-does not involve the usual timing calculations,
-and causes the supplied data argument to be added to the entropy pool,
+.Fn enqueue_randomness
+causes the supplied data argument to be added to the entropy pool,
increasing the entropy counter by 32 bits.
.Pp
-.Fn add_timer_randomness
-will not cause the entropy counter to rise.
-It is used to change the state of the pool periodically,
-mostly by means of timing the random driver's operations.
-.Pp
.Fn arc4random
and
.Fn arc4random_buf