Module Name: src Committed By: kre Date: Mon Jan 21 14:09:24 UTC 2019
Modified Files: src/bin/sh: sh.1 Log Message: Add an explanation of the error (warning) RANDOM initialisation failed when the shell might print after RANDOM has been reseeded (which includes at sh startup) the next time RANDOM is accessed. It indicates that /dev/urandom was not available or did not provide data - in that case, sh uses a (weak) seed made out of the pid and time (but otherwise nothing else changes). To generate a diff of this commit: cvs rdiff -u -r1.216 -r1.217 src/bin/sh/sh.1 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/bin/sh/sh.1 diff -u src/bin/sh/sh.1:1.216 src/bin/sh/sh.1:1.217 --- src/bin/sh/sh.1:1.216 Wed Dec 12 20:22:43 2018 +++ src/bin/sh/sh.1 Mon Jan 21 14:09:24 2019 @@ -1,4 +1,4 @@ -.\" $NetBSD: sh.1,v 1.216 2018/12/12 20:22:43 kre Exp $ +.\" $NetBSD: sh.1,v 1.217 2019/01/21 14:09:24 kre Exp $ .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" @@ -4254,6 +4254,14 @@ This is also how the initial seed is gen assigned before .Ev RANDOM is first accessed after shell initialization. +Should the error message +.Dq "RANDOM initialisation failed" +appear on standard error, it indicates that the source +of good random numbers was not available, and +.Ev RANDOM +has instead been seeded with a more predictable value. +The following sequence of random numbers will +not be as unpredictable as they otherwise would be. .It Ev SECONDS Returns the number of seconds since the current shell was started. If unset, it remains unset, and returns nothing, unless set again.