From owner-freebsd-bugs Thu Nov 28 3:50: 5 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1FF8637B401 for ; Thu, 28 Nov 2002 03:50:03 -0800 (PST) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6701E43ECF for ; Thu, 28 Nov 2002 03:50:02 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.6/8.12.6) with ESMTP id gASBo2x3033876 for ; Thu, 28 Nov 2002 03:50:02 -0800 (PST) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.6/8.12.6/Submit) id gASBo2Ib033875; Thu, 28 Nov 2002 03:50:02 -0800 (PST) Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id CA67837B401 for ; Thu, 28 Nov 2002 03:44:56 -0800 (PST) Received: from www.idlepower.net (h24-79-84-133.vc.shawcable.net [24.79.84.133]) by mx1.FreeBSD.org (Postfix) with SMTP id E198943E4A for ; Thu, 28 Nov 2002 03:44:55 -0800 (PST) (envelope-from cperciva@www.idlepower.net) Received: (qmail 50373 invoked by uid 1000); 28 Nov 2002 11:44:48 -0000 Received: (for user cperciva) Message-Id: <20021128114448.50371.qmail@www.idlepower.net> Date: 28 Nov 2002 11:44:48 -0000 From: Colin Percival Reply-To: Colin Percival To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: bin/45817: [PATCH] Fortune files are needlessly randomized Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 45817 >Category: bin >Synopsis: [PATCH] Fortune files are needlessly randomized >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Thu Nov 28 03:50:01 PST 2002 >Closed-Date: >Last-Modified: >Originator: Colin Percival >Release: FreeBSD 5.0-CURRENT >Organization: >Environment: System: All versions of FreeBSD including the fortunes. >Description: In the build process, fortune files are randomized. This is 1. Entirely pointless, since fortune(6) performs its own randomization, and 2. Causes the fortune files to be different every time they are rebuilt. This will set off flags in any process which compares file checksums (to determine if files have been tampered with, or to determine which files need to be redistributed following a rebuild.) >How-To-Repeat: Build the fortune files twice, and compare their md5sums. >Fix: Remove the -r flag in the call to strfile: --- fortune.patch begins here --- Index: Makefile =================================================================== RCS file: /usr/cvsroot/src/games/fortune/datfiles/Makefile,v retrieving revision 1.29 diff -u -r1.29 Makefile --- Makefile 10 Nov 2002 23:41:01 -0000 1.29 +++ Makefile 28 Nov 2002 11:21:22 -0000 @@ -29,12 +29,12 @@ .for f in fortunes fortunes2 fortunes2-o freebsd-tips gerrold.limerick limerick murphy murphy-o startrek zippy $f.dat: $f PATH=$$PATH:/usr/games:${.OBJDIR}/../strfile \ - strfile -Crs ${.ALLSRC} ${.TARGET} + strfile -Cs ${.ALLSRC} ${.TARGET} .endfor fortunes-o.dat: fortunes-o PATH=$$PATH:/usr/games:${.OBJDIR}/../strfile \ - strfile -Crsx ${.ALLSRC} ${.TARGET} + strfile -Csx ${.ALLSRC} ${.TARGET} fortunes-o: fortunes-o.${TYPE} tr a-zA-Z n-za-mN-ZA-M < ${.ALLSRC} > ${.TARGET} --- fortune.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message