From owner-freebsd-questions@FreeBSD.ORG Wed Mar 2 04:53:45 2005 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A6D9016A4CE for ; Wed, 2 Mar 2005 04:53:45 +0000 (GMT) Received: from hosea.tallye.com (joel.tallye.com [216.99.199.78]) by mx1.FreeBSD.org (Postfix) with ESMTP id 04E5A43D46 for ; Wed, 2 Mar 2005 04:53:45 +0000 (GMT) (envelope-from lorenl@alzatex.com) Received: from hosea.tallye.com (hosea.tallye.com [127.0.0.1]) by hosea.tallye.com (8.12.8/8.12.10) with ESMTP id j224rcqS012002 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 1 Mar 2005 20:53:40 -0800 Received: (from sttng359@localhost) by hosea.tallye.com (8.12.8/8.12.10/Submit) id j224rc6H012000; Tue, 1 Mar 2005 20:53:38 -0800 X-Authentication-Warning: hosea.tallye.com: sttng359 set sender to lorenl@alzatex.com using -f Date: Tue, 1 Mar 2005 20:53:37 -0800 From: "Loren M. Lang" To: Kris Kennaway Message-ID: <20050302045337.GB30896@alzatex.com> References: <20050228124023.GH1672@alzatex.com> <20050228201308.GC70059@xor.obsecurity.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050228201308.GC70059@xor.obsecurity.org> User-Agent: Mutt/1.4.1i X-GPG-Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc X-GPG-Fingerprint: B3B9 D669 69C9 09EC 1BCD 835A FAF3 7A46 E4A3 280C cc: "Loren M. Lang" cc: Rob cc: Ted Mittelstaedt cc: FreeBSD questions Subject: Re: /dev/io , /dev/mem : only used by Xorg? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Mar 2005 04:53:45 -0000 On Mon, Feb 28, 2005 at 12:13:08PM -0800, Kris Kennaway wrote: > On Mon, Feb 28, 2005 at 04:58:02AM -0800, Ted Mittelstaedt wrote: > > > Yes - there's some random testing suites on the Internet, find a > > few and compile them. (ENT for example) Run them repeatedly and see what > > happens. > > > > Part of the problem is that BY DEFAULT the random device DOES NOT > > look at interrupts. See the man page for rndcontrol. Presumably > > the system admin of the system knows this and looks at his dmesg > > output to see which irq's are assigned to network cards and hard > > disks (which are fairly good sources of randomness) and sets the > > random device to use these. In practice this isn't something mentioned > > in the install docs so it is very unlikely many people know. > > > > Another strange thing is that /dev/random should block when it > > runs out of entropy - it doesen't seem to do so, however. And the > > device doesen't seem to gain entropy that quickly. > > No, it should not block because it's not defined to block and that > would be a bad interface anyway. It does return as many bytes as it > can, and if the application wants more entropy than given then it can > either poll, or fall back to alternative mechanisms as it sees fit > (blocking would prevent this). I would expect it to behave like other descriptors where by default it should block unless the O_NONBLOCK flag it set in which it would return immediately with an error message EAGAIN. Then an app designer can choose which he wants. But /dev/random should not just always return some data even if there's not enough entropy in the pool. That's /dev/urandom's job. > > Anyway, all your concerns are moot for 5.x. > > Kris -- I sense much NT in you. NT leads to Bluescreen. Bluescreen leads to downtime. Downtime leads to suffering. NT is the path to the darkside. Powerful Unix is. Public Key: ftp://ftp.tallye.com/pub/lorenl_pubkey.asc Fingerprint: CEE1 AAE2 F66C 59B5 34CA C415 6D35 E847 0118 A3D2