From owner-cvs-all@FreeBSD.ORG Sat Apr 10 12:30:07 2004 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB75816A4CE; Sat, 10 Apr 2004 12:30:07 -0700 (PDT) Received: from storm.FreeBSD.org.uk (storm.FreeBSD.org.uk [194.242.157.42]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9045C43D39; Sat, 10 Apr 2004 12:30:06 -0700 (PDT) (envelope-from mark@grondar.org) Received: from storm.FreeBSD.org.uk (Ugrondar@localhost [127.0.0.1]) i3AJU552083176; Sat, 10 Apr 2004 20:30:05 +0100 (BST) (envelope-from mark@grondar.org) Received: (from Ugrondar@localhost)i3AJU52R083175; Sat, 10 Apr 2004 20:30:05 +0100 (BST) (envelope-from mark@grondar.org) X-Authentication-Warning: storm.FreeBSD.org.uk: Ugrondar set sender to mark@grondar.org using -f Received: from grondar.org (localhost [127.0.0.1])i3AJTJ8P070553; Sat, 10 Apr 2004 20:29:19 +0100 (BST) (envelope-from mark@grondar.org) From: Mark Murray Message-Id: <200404101929.i3AJTJ8P070553@grimreaper.grondar.org> To: richardcoleman@mindspring.com In-Reply-To: Your message of "Sat, 10 Apr 2004 14:40:12 EDT." <40783F8C.1010704@mindspring.com> Date: Sat, 10 Apr 2004 20:29:19 +0100 Sender: mark@grondar.org X-Spam-Score: 4 (****) FROM_NO_LOWER,MSGID_FROM_MTA_SHORT X-Scanned-By: MIMEDefang 2.39 cc: cvs-src@FreeBSD.ORG cc: src-committers@FreeBSD.ORG cc: cvs-all@FreeBSD.ORG Subject: Re: cvs commit: src/sys/modules/random Makefile src/sys/dev/random harvest.c hash.c hash.h nehemiah.c nehemiah.h probe.c randomdev.c randomdev.h randomdev_soft.c randomdev_soft.h yar X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Apr 2004 19:30:07 -0000 Richard Coleman writes: > > If it is felt that further whitening of the VIA C3 RNG is needed, > > then I believe that Yarrow would be overkill, and that a much smaller > > hash function will be sufficient. > > What do you have in mind? AES is already one of the faster ciphers > around. You could reduce the number of rounds used for AES, but it > would be hard to estimate the cryptographic strength. The C3 chip has AES on board, so something like this may do the trick: key = C3RNG(); seed ^= C3RNG(); /* seed is static */ output = encryptAES(key, seed); Cryptographic strength is of lesser importance here, as the key input is Very Nicely Random(tm), however AES's speed and spectral qualities make it a good choice. It is important to remember that the hash is purely there to destroy any trends/tendencies that the hardware generator may have, and for that purpose an LFSR may work just fine. The hash is a "Whitener", and its requirements here are that its output spectrum is flat. M -- Mark Murray iumop ap!sdn w,I idlaH