Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Oct 2011 13:54:44 GMT
From:      Jim Pirzyk <pirzyk@FreeBSD.org>
To:        freebsd-gnats-submit@FreeBSD.org
Subject:   ports/161490: rkhunter.conf file overwrote after upgrade
Message-ID:  <201110111354.p9BDsh1d005185@red.freebsd.org>
Resent-Message-ID: <201110111400.p9BE0HkQ062069@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         161490
>Category:       ports
>Synopsis:       rkhunter.conf file overwrote after upgrade
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 11 14:00:16 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator:     Jim Pirzyk
>Release:        8.2-RELEASE
>Organization:
>Environment:
FreeBSD amigo.home.pirzyk.org 8.2-RELEASE-p3 FreeBSD 8.2-RELEASE-p3 #0: Tue Sep 27 18:45:57 UTC 2011     root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC  amd64

>Description:
When upgrading the rkhunter port, the rkhunter.conf file (a config file) gets overwrote by the package. Per the Porter's handbook (7.3), attached is a patch to the pkg-plist.  The Makefile was doing the update properly.


>How-To-Repeat:

>Fix:


Patch attached with submission follows:

--- ./pkg-plist.orig	2011-04-20 08:53:50.000000000 -0400
+++ ./pkg-plist	2011-10-11 09:45:21.870038241 -0400
@@ -1,7 +1,9 @@
 @comment $FreeBSD: ports/security/rkhunter/pkg-plist,v 1.10 2011/04/20 12:53:50 sbz Exp $
 bin/rkhunter
 etc/periodic/security/415.rkhunter
-etc/rkhunter.conf
+@unexec if cmp -s %D/etc/rkhunter.conf.sample %D/etc/rkhunter.conf; then rm -f %D/etc/rkhunter.conf; fi
+etc/rkhunter.conf.sample
+@exec if [ ! -f %D/etc/rkhunter.conf ] ; then cp -p %D/%F %B/rkhunter.conf; fi
 lib/rkhunter/scripts/check_modules.pl
 lib/rkhunter/scripts/filehashsha.pl
 lib/rkhunter/scripts/readlink.sh


>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201110111354.p9BDsh1d005185>