diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2011-01-09 00:06:51 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2011-01-09 00:06:51 +0000 |
commit | 5184e1977dc1560318ab493280820be82b90def9 (patch) | |
tree | adf4f57f2889c3db84208b38cd6d1ccdbe10ead1 | |
parent | b288d2afa17ee27c1afe9739aac0d45a71f0c621 (diff) |
update random(4) and arc4random(9) manual pages
-rw-r--r-- | share/man/man4/random.4 | 6 | ||||
-rw-r--r-- | share/man/man9/Makefile | 24 | ||||
-rw-r--r-- | share/man/man9/arc4random.9 (renamed from share/man/man9/random.9) | 23 | ||||
-rw-r--r-- | share/man/man9/idgen32.9 | 6 | ||||
-rw-r--r-- | share/man/man9/md5.9 | 6 |
5 files changed, 26 insertions, 39 deletions
diff --git a/share/man/man4/random.4 b/share/man/man4/random.4 index ce43a8615fe..7e45fbe16cb 100644 --- a/share/man/man4/random.4 +++ b/share/man/man4/random.4 @@ -1,4 +1,4 @@ -.\" $OpenBSD: random.4,v 1.26 2011/01/07 08:23:27 jmc Exp $ +.\" $OpenBSD: random.4,v 1.27 2011/01/09 00:06:50 deraadt Exp $ .\" .\" Copyright (c) 1996, 1997 Michael Shalayeff .\" @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd $Mdocdate: January 7 2011 $ +.Dd $Mdocdate: January 9 2011 $ .Dt RANDOM 4 .Os .Sh NAME @@ -64,7 +64,7 @@ these devices every time. .Xr glxsb 4 , .Xr pchb 4 , .Xr md5 9 , -.Xr random 9 +.Xr arc4random 9 .Sh HISTORY A .Nm diff --git a/share/man/man9/Makefile b/share/man/man9/Makefile index d325f02f87c..475a25e80d7 100644 --- a/share/man/man9/Makefile +++ b/share/man/man9/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.159 2010/09/24 13:33:00 matthew Exp $ +# $OpenBSD: Makefile,v 1.160 2011/01/09 00:06:50 deraadt Exp $ # $NetBSD: Makefile,v 1.4 1996/01/09 03:23:01 thorpej Exp $ # Makefile for section 9 (kernel function and variable) manual pages. @@ -20,7 +20,7 @@ MAN= altq.9 aml_evalnode.9 atomic.9 audio.9 autoconf.9 bio_register.9 \ mountroothook_establish.9 mutex.9 namei.9 \ panic.9 pci_conf_read.9 pci_intr_map.9 pfind.9 physio.9 pmap.9 \ pool.9 powerhook_establish.9 ppsratecheck.9 printf.9 psignal.9 \ - radio.9 random.9 rasops.9 ratecheck.9 resettodr.9 rssadapt.9 rwlock.9 \ + radio.9 arc4random.9 rasops.9 ratecheck.9 resettodr.9 rssadapt.9 rwlock.9 \ sensor_attach.9 \ shutdownhook_establish.9 tsleep.9 spl.9 startuphook_establish.9 \ socreate.9 style.9 syscall.9 systrace.9 sysctl_int.9 \ @@ -247,17 +247,15 @@ MLINKS+=powerhook_establish.9 powerhook_disestablish.9 MLINKS+=printf.9 snprintf.9 printf.9 vsnprintf.9 printf.9 vprintf.9 \ printf.9 uprintf.9 printf.9 ttyprintf.9 printf.9 db_printf.9 MLINKS+=psignal.9 pgsignal.9 psignal.9 gsignal.9 -MLINKS+=random.9 add_true_randomness.9 \ - random.9 add_timer_randomness.9 \ - random.9 add_mouse_randomness.9 \ - random.9 add_tty_randomness.9 \ - random.9 add_net_randomness.9 \ - random.9 add_disk_randomness.9 \ - random.9 add_audio_randomness.9 \ - random.9 get_random_bytes.9 \ - random.9 arc4random.9 \ - random.9 arc4random_buf.9 \ - random.9 arc4random_uniform.9 +MLINKS+=arc4random.9 add_true_randomness.9 \ + arc4random.9 add_timer_randomness.9 \ + arc4random.9 add_mouse_randomness.9 \ + arc4random.9 add_tty_randomness.9 \ + arc4random.9 add_net_randomness.9 \ + arc4random.9 add_disk_randomness.9 \ + arc4random.9 add_audio_randomness.9 \ + arc4random.9 arc4random_buf.9 \ + arc4random.9 arc4random_uniform.9 MLINKS+=rasops.9 rasops_init.9 rasops.9 rasops_reconfig.9 MLINKS+=rssadapt.9 ieee80211_rssadapt_choose.9 \ rssadapt.9 ieee80211_rssadapt_input.9 \ diff --git a/share/man/man9/random.9 b/share/man/man9/arc4random.9 index 9eeef884a3d..6b2d17ecaef 100644 --- a/share/man/man9/random.9 +++ b/share/man/man9/arc4random.9 @@ -1,4 +1,4 @@ -.\" $OpenBSD: random.9,v 1.26 2010/10/02 15:58:30 tedu Exp $ +.\" $OpenBSD: arc4random.9,v 1.4 2011/01/09 00:06:50 deraadt Exp $ .\" .\" Copyright (c) 1996,2000 Michael Shalayeff .\" All rights reserved. @@ -23,12 +23,12 @@ .\" (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: October 2 2010 $ -.Dt RND 9 +.Dd $Mdocdate: January 9 2011 $ +.Dt ARC4RANDOM 9 .Os .Sh NAME -.Nm random -.Nd device kernel interface +.Nm arc4random +.Nd kernel random subsystem .Sh SYNOPSIS .Fd #include <dev/rndvar.h> .Ft void @@ -45,8 +45,6 @@ .Fn add_disk_randomness "int" .Ft void .Fn add_audio_randomness "int" -.Ft void -.Fn get_random_bytes "void *buf" "size_t nbytes" .Ft u_int32_t .Fn arc4random "void" .Ft void @@ -77,15 +75,10 @@ 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 get_random_bytes -may be used to retrieve strong random data. -.Pp .Fn arc4random and .Fn arc4random_buf -will give random 32 bit numbers hashed with -the ARC4 algorithm, which appears to be faster and less abusive -to the entropy pool. +provide random numbers. They may be called safely in any kernel context. .Pp .Fn arc4random_uniform will return a uniformly distributed random number less than @@ -95,7 +88,3 @@ avoiding "modulo bias" when the upper bound is not a power of two. .Xr arc4random 3 , .Xr pchb 4 , .Xr random 4 -.Sh CAVEATS -None of these functions should really be called during the -.Xr autoconf 4 -process. diff --git a/share/man/man9/idgen32.9 b/share/man/man9/idgen32.9 index 33cd0b34f84..4c276c2657f 100644 --- a/share/man/man9/idgen32.9 +++ b/share/man/man9/idgen32.9 @@ -1,4 +1,4 @@ -.\" $OpenBSD: idgen32.9,v 1.1 2008/06/10 09:16:15 deraadt Exp $ +.\" $OpenBSD: idgen32.9,v 1.2 2011/01/09 00:06:50 deraadt Exp $ .\" .\" Copyright (c) 2008 Damien Miller <djm@mindrot.org> .\" All rights reserved. @@ -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: June 10 2008 $ +.Dd $Mdocdate: January 9 2011 $ .Dt IDGEN32 9 .Os .Sh NAME @@ -47,7 +47,7 @@ function returns a new ID in host byte order. Note that this function will never return 0 as it often has a special meaning in network protocols. .Sh SEE ALSO -.Xr random 9 +.Xr arc4random 9 .Sh HISTORY The .Nm diff --git a/share/man/man9/md5.9 b/share/man/man9/md5.9 index 99a619e8ea0..743e18d56c7 100644 --- a/share/man/man9/md5.9 +++ b/share/man/man9/md5.9 @@ -1,4 +1,4 @@ -.\" $OpenBSD: md5.9,v 1.10 2007/05/31 19:20:00 jmc Exp $ +.\" $OpenBSD: md5.9,v 1.11 2011/01/09 00:06:50 deraadt Exp $ .\" .\" Copyright (c) 1996 Michael Shalayeff .\" All rights reserved. @@ -23,7 +23,7 @@ .\" (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: May 31 2007 $ +.Dd $Mdocdate: January 9 2011 $ .Dt MD5 9 .Os .Sh NAME @@ -68,4 +68,4 @@ The MD5 cryptographic checksum was devised by Ronald Rivest, and is documented in RFC 1321, "The MD5 Message Digest Algorithm". .Sh SEE ALSO .Xr random 4 , -.Xr random 9 +.Xr arc4random 9 |