From owner-freebsd-chat Tue Jun 1 21:50:11 1999 Delivered-To: freebsd-chat@freebsd.org Received: from adelphi.physics.adelaide.edu.au (adelphi.physics.adelaide.edu.au [129.127.36.247]) by hub.freebsd.org (Postfix) with ESMTP id BD92815024 for ; Tue, 1 Jun 1999 21:50:06 -0700 (PDT) (envelope-from kkennawa@physics.adelaide.edu.au) Received: from bragg (bragg [129.127.36.34]) by adelphi.physics.adelaide.edu.au (8.8.8/8.8.8/UofA-1.5) with SMTP id OAA10210; Wed, 2 Jun 1999 14:20:02 +0930 (CST) Received: from localhost by bragg; (5.65/1.1.8.2/05Aug95-0227PM) id AA29996; Wed, 2 Jun 1999 14:21:06 +0930 Date: Wed, 2 Jun 1999 14:21:05 +0930 (CST) From: Kris Kennaway X-Sender: kkennawa@bragg To: "Matthew D. Fuller" Cc: "Daniel O'Connor" , chat@freebsd.org Subject: Re: FreeBSD & X In-Reply-To: <19990601234004.W6251@futuresouth.com> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-chat@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Tue, 1 Jun 1999, Matthew D. Fuller wrote: > [23:38:21] mortis:~ > (ttyp6):{404}% cat bin/authcookiegen.sh > #!/bin/sh > # > # A half-decent xauth cookie generator > > DISPNUM=$1 > > # Generate the cookie in multiple parts, just for added safety > key1=`/usr/bin/vmstat -i | /sbin/md5` > key2=`/usr/bin/netstat -i | /sbin/md5` > key3=`/bin/ps -gaxuww | /sbin/md5` > key4=`/usr/sbin/pstat -f | /sbin/md5` Why not just dd if=/dev/urandom bs= The above doesn't give all that good randomization of your key.. Kris ----- "Never criticize anybody until you have walked a mile in their shoes, because by that time you will be a mile away and have their shoes." -- Unknown To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-chat" in the body of the message