From owner-freebsd-arch Tue Feb 27 11:53:30 2001 Delivered-To: freebsd-arch@freebsd.org Received: from point.osg.gov.bc.ca (point.osg.gov.bc.ca [142.32.102.44]) by hub.freebsd.org (Postfix) with ESMTP id 3A7EA37B71A; Tue, 27 Feb 2001 11:53:25 -0800 (PST) (envelope-from Cy.Schubert@uumail.gov.bc.ca) Received: (from daemon@localhost) by point.osg.gov.bc.ca (8.8.7/8.8.8) id LAA18051; Tue, 27 Feb 2001 11:53:08 -0800 Received: from passer.osg.gov.bc.ca(142.32.110.29) via SMTP by point.osg.gov.bc.ca, id smtpda18049; Tue Feb 27 11:53:02 2001 Received: (from uucp@localhost) by passer.osg.gov.bc.ca (8.11.2/8.9.1) id f1RJqvF29879; Tue, 27 Feb 2001 11:52:57 -0800 (PST) Received: from cwsys9.cwsent.com(10.2.2.1), claiming to be "cwsys.cwsent.com" via SMTP by passer9.cwsent.com, id smtpdF29873; Tue Feb 27 11:52:29 2001 Received: (from uucp@localhost) by cwsys.cwsent.com (8.11.2/8.9.1) id f1RJqSs35224; Tue, 27 Feb 2001 11:52:28 -0800 (PST) Message-Id: <200102271952.f1RJqSs35224@cwsys.cwsent.com> Received: from localhost.cwsent.com(127.0.0.1), claiming to be "cwsys" via SMTP by localhost.cwsent.com, id smtpdA34593; Tue Feb 27 11:51:29 2001 X-Mailer: exmh version 2.3.1 01/18/2001 with nmh-1.0.4 Reply-To: Cy Schubert - ITSD Open Systems Group From: Cy Schubert - ITSD Open Systems Group X-Sender: schubert To: Garance A Drosihn Cc: Kris Kennaway , Terry Lambert , "Jacques A. Vidrine" , arch@FreeBSD.ORG Subject: Re: rand(3) (was Re: cvs commit: ports/astro/xglobe/files patch-random) In-reply-to: Your message of "Tue, 27 Feb 2001 13:30:46 EST." Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Tue, 27 Feb 2001 11:51:29 -0800 Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message , Garance A Drosihn writes: > At 11:15 PM -0800 2/26/01, Kris Kennaway wrote: > >There goes your "pseudo-standardization" argument out the window, > >which means you obviously hadn't checked your facts and were just > >describing the state of your internal fantasy universe. Thanks > >for wasting everyone's time with this silly thread. > > I am aware of other people who live in the same fantasy universe, > so I think this thread is spiraling downwards. A few of those > people even ran tests to see if rand() produced the same results > across the platforms they cared about, and once that was proven, > they just assumed that would remain true (most of them are doing > comparisons across time, though, not across platforms. Still, > "across time" tends to become "across platforms", as hardware > changes around here). It *is* interesting to find out that glibc > does use the same algorithm as random(). Glibc hasn't been > used much among the people I'm thinking of, but it's certainly > getting used more as linux makes inroads on campus. Now I am > also wondering if rand() still produces similar results across > the other unix platforms we have on campus. Just as with virtually everything else in this industry we have multiple standards (don't even get me started with the telecommunications and building industries). Some shops or developers may wish to integrate across platforms while others focus on FreeBSD/Linux. Could we not implement a solution similar to malloc()'s /etc/malloc.conf and MALLOC_OPTIONS? The default could be set to rand() calling random(), while setting the appropriate option would revert to the "old" behaviour. Or, #ifdef. Either way we satisfy both camps. Ideally, rand() is insecure and should be removed or should call random(), protecting clueless developers from themselves and more importantly protecting clueless end users from clueless developers. We three choices: 1. Status quo. 2. A more secure rand(). 3. A hybrid. Regards, Phone: (250)387-8437 Cy Schubert Fax: (250)387-5766 Team Leader, Sun/Alpha Team Internet: Cy.Schubert@osg.gov.bc.ca Open Systems Group, ITSD, ISTA Province of BC To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message