Bug 79149 - [maintainer update] security/rkhunter
Summary: [maintainer update] security/rkhunter
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Simon Barner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-03-23 02:40 UTC by vaidab
Modified: 2005-05-18 17:38 UTC (History)
1 user (show)

See Also:


Attachments
file.diff (167 bytes, patch)
2005-03-23 02:40 UTC, vaidab
no flags Details | Diff
file.diff (1.07 KB, patch)
2005-03-23 02:40 UTC, vaidab
no flags Details | Diff
file.diff (838 bytes, patch)
2005-03-23 02:40 UTC, vaidab
no flags Details | Diff
file.diff (293 bytes, patch)
2005-03-23 02:40 UTC, vaidab
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description vaidab 2005-03-23 02:40:02 UTC

Fix: PORTNAME=	rkhunter
-PORTVERSION=	1.1.9
+PORTVERSION=	1.2.3
  CATEGORIES=	security
  MASTER_SITES=	http://downloads.rootkit.nl/

# Prefix: INSTALLDIR
- INSTALLFILES2="
--nooverwrite:rkhunter.conf:/usr/local/etc/rkhunter.conf:RK%%Hunter%%configuration%%file
--overwrite:rkhunter:/usr/local/bin/rkhunter:RK%%Hunter%%binary
-+overwrite:rkhunter.conf:/etc/rkhunter.conf.sample:RK%%Hunter%%configuration%%file
-+overwrite:rkhunter:/bin/rkhunter:RK%%Hunter%%binary
- "
- 
- # Create directories (only if they do not exist)
-@@ -137,10 +134,7 @@
+@@ -136,9 +133,7 @@
   ${INSTALLDIR}/etc
   ${INSTALLDIR}/bin
   ${INSTALLDIR}/lib/rkhunter/db
  -${INSTALLDIR}/lib/rkhunter/docs
   ${INSTALLDIR}/lib/rkhunter/scripts
  -${INSTALLDIR}/lib/rkhunter/tmp
--/usr/local/etc
+ /usr/local/etc
+ /usr/local/bin
   "
- 
- CHECKDIR="/usr/local"
-@@ -347,9 +341,6 @@
+@@ -397,9 +392,6 @@
   #################################################################################


@@ -39,36 +30,27 @@
   echo "${INSTALLER_NAME} ${INSTALLER_VERSION} (${INSTALLER_COPYRIGHT})"
   echo $ECHOOPT "---------------"
   echo "Starting installation/update"
-@@ -469,7 +460,7 @@
-       echo "Skipped (no overwrite)"
-     else
-       #error redirection in .rkhunter it's just for a clear display if user run not as root
--      cp -f ${INSTALLPREFIX}${CURFILE} ${NEWFILE} 2> ~/.rkhunter.log
-+      cp -f ${INSTALLPREFIX}${CURFILE} "${INSTALLDIR}/${NEWFILE}" 2> ~/.rkhunter.log
-       if [ $? -eq 0 ]
-         then
- 	  echo $E "OK"
-@@ -483,11 +474,11 @@
+@@ -532,11 +524,11 @@
   done

   # Installation dir to configuration file
  -INSTALLDIRCHECK=`cat /usr/local/etc/rkhunter.conf | grep "INSTALLDIR="`
-+INSTALLDIRCHECK=`cat $INSTALLDIR/etc/rkhunter.conf.sample | grep "INSTALLDIR="`
++INSTALLDIRCHECK=`cat ${INSTALLDIR}/etc/rkhunter.conf | grep "INSTALLDIR="`
   if [ "${INSTALLDIRCHECK}" = "" ]
     then
  -    echo "" >> /usr/local/etc/rkhunter.conf
  -    echo "INSTALLDIR=${INSTALLDIR}" >> /usr/local/etc/rkhunter.conf
-+    echo "" >> $INSTALLDIR/etc/rkhunter.conf.sample
-+    echo "INSTALLDIR=${INSTALLDIR}" >> $INSTALLDIR/etc/rkhunter.conf.sample
++    echo "" >> ${INSTALLDIR}/etc/rkhunter.conf
++    echo "INSTALLDIR=${INSTALLDIR}" >> ${INSTALLDIR}/etc/rkhunter.conf
       echo "Configuration updated with installation path (${INSTALLDIR})"
     else
       echo "Configuration already updated."
-@@ -497,7 +488,7 @@
+@@ -546,7 +538,7 @@
   then
   	echo ""
   	echo $E "$t17"
  -	echo "$t18 (/usr/local/bin/rkhunter)"
-+	echo "$t18 ($INSTALLDIR/bin/rkhunter)"
++	echo "$t18 (${INSTALLDIR}/rkhunter)"
   else
   	echo ""
   	echo $E "$t19"
# Use a custom database directory (you can override it with the
   # --dbdir parameter)
-@@ -25,4 +25,4 @@
- #MD5WHITELIST=/bin/ps:9bd8bf260adc81d3a43a086fce6b430a
- #MD5WHITELIST=/bin/ps:404583a6b166c2f7ac1287445a9de6b3
- 
--# The End
-\ No newline at end of file
-+# The End
Comment 1 Simon Barner freebsd_committer 2005-03-24 13:29:43 UTC
Responsible Changed
From-To: freebsd-ports-bugs->barner

I'll handle this.
Comment 2 Simon Barner freebsd_committer 2005-03-24 13:42:16 UTC
Hi,

your patch does not apply cleanly. Could you please re-create it?

diff -ruN rkhunter.orig rkhunter > rkhunter.patch

In case you don't know, you can get the current CVS version of your port
here:

http://www.freebsd.org/cgi/cvsweb.cgi/ports/security/rkhunter/ (Save as
tarball)

Simon
Comment 3 vaidab 2005-03-24 15:15:36 UTC
diff -ruN rkhunter.old/Makefile rkhunter/Makefile
--- rkhunter.old/Makefile	Wed Mar 23 03:17:59 2005
+++ rkhunter/Makefile	Wed Mar 23 03:18:25 2005
@@ -6,7 +6,7 @@
  #

  PORTNAME=	rkhunter
-PORTVERSION=	1.1.9
+PORTVERSION=	1.2.3
  CATEGORIES=	security
  MASTER_SITES=	http://downloads.rootkit.nl/

diff -ruN rkhunter.old/distinfo rkhunter/distinfo
--- rkhunter.old/distinfo	Wed Mar 23 03:17:59 2005
+++ rkhunter/distinfo	Wed Mar 23 03:18:40 2005
@@ -1,2 +1,2 @@
-MD5 (rkhunter-1.1.9.tar.gz) = 2e24806cb1267124fba6132009e30f1b
-SIZE (rkhunter-1.1.9.tar.gz) = 115254
+MD5 (rkhunter-1.2.3.tar.gz) = 404ae3f5cde3ede8e3be1ee1f04f52d5
+SIZE (rkhunter-1.2.3.tar.gz) = 169545
diff -ruN rkhunter.old/files/patch-installer.sh rkhunter/files/patch-installer.sh
--- rkhunter.old/files/patch-installer.sh	Wed Mar 23 03:17:59 2005
+++ rkhunter/files/patch-installer.sh	Wed Mar 23 04:18:46 2005
@@ -1,6 +1,6 @@
---- installer.sh.orig	Fri Aug 20 15:11:04 2004
-+++ installer.sh	Sun Aug 29 23:56:46 2004
-@@ -120,15 +120,12 @@
+--- installer.sh.old	Wed Mar 23 03:35:06 2005
++++ installer.sh	Wed Mar 23 04:18:44 2005
+@@ -119,9 +119,6 @@
   overwrite:programs_good.dat:/db/programs_good.dat:Database%%Program%%versions
   overwrite:defaulthashes.dat:/db/defaulthashes.dat:Database%%Default%%file%%hashes
   overwrite:md5blacklist.dat:/db/md5blacklist.dat:Database%%MD5%%blacklisted%%files
@@ -10,26 +10,17 @@
   "

   # Prefix: INSTALLDIR
- INSTALLFILES2="
--nooverwrite:rkhunter.conf:/usr/local/etc/rkhunter.conf:RK%%Hunter%%configuration%%file
--overwrite:rkhunter:/usr/local/bin/rkhunter:RK%%Hunter%%binary
-+overwrite:rkhunter.conf:/etc/rkhunter.conf.sample:RK%%Hunter%%configuration%%file
-+overwrite:rkhunter:/bin/rkhunter:RK%%Hunter%%binary
- "
- 
- # Create directories (only if they do not exist)
-@@ -137,10 +134,7 @@
+@@ -136,9 +133,7 @@
   ${INSTALLDIR}/etc
   ${INSTALLDIR}/bin
   ${INSTALLDIR}/lib/rkhunter/db
  -${INSTALLDIR}/lib/rkhunter/docs
   ${INSTALLDIR}/lib/rkhunter/scripts
  -${INSTALLDIR}/lib/rkhunter/tmp
--/usr/local/etc
+ /usr/local/etc
+ /usr/local/bin
   "
- 
- CHECKDIR="/usr/local"
-@@ -347,9 +341,6 @@
+@@ -397,9 +392,6 @@
   #################################################################################


@@ -39,36 +30,27 @@
   echo "${INSTALLER_NAME} ${INSTALLER_VERSION} (${INSTALLER_COPYRIGHT})"
   echo $ECHOOPT "---------------"
   echo "Starting installation/update"
-@@ -469,7 +460,7 @@
-       echo "Skipped (no overwrite)"
-     else
-       #error redirection in .rkhunter it's just for a clear display if user run not as root
--      cp -f ${INSTALLPREFIX}${CURFILE} ${NEWFILE} 2> ~/.rkhunter.log
-+      cp -f ${INSTALLPREFIX}${CURFILE} "${INSTALLDIR}/${NEWFILE}" 2> ~/.rkhunter.log
-       if [ $? -eq 0 ]
-         then
- 	  echo $E "OK"
-@@ -483,11 +474,11 @@
+@@ -532,11 +524,11 @@
   done

   # Installation dir to configuration file
  -INSTALLDIRCHECK=`cat /usr/local/etc/rkhunter.conf | grep "INSTALLDIR="`
-+INSTALLDIRCHECK=`cat $INSTALLDIR/etc/rkhunter.conf.sample | grep "INSTALLDIR="`
++INSTALLDIRCHECK=`cat ${INSTALLDIR}/etc/rkhunter.conf | grep "INSTALLDIR="`
   if [ "${INSTALLDIRCHECK}" = "" ]
     then
  -    echo "" >> /usr/local/etc/rkhunter.conf
  -    echo "INSTALLDIR=${INSTALLDIR}" >> /usr/local/etc/rkhunter.conf
-+    echo "" >> $INSTALLDIR/etc/rkhunter.conf.sample
-+    echo "INSTALLDIR=${INSTALLDIR}" >> $INSTALLDIR/etc/rkhunter.conf.sample
++    echo "" >> ${INSTALLDIR}/etc/rkhunter.conf
++    echo "INSTALLDIR=${INSTALLDIR}" >> ${INSTALLDIR}/etc/rkhunter.conf
       echo "Configuration updated with installation path (${INSTALLDIR})"
     else
       echo "Configuration already updated."
-@@ -497,7 +488,7 @@
+@@ -546,7 +538,7 @@
   then
   	echo ""
   	echo $E "$t17"
  -	echo "$t18 (/usr/local/bin/rkhunter)"
-+	echo "$t18 ($INSTALLDIR/bin/rkhunter)"
++	echo "$t18 (${INSTALLDIR}/rkhunter)"
   else
   	echo ""
   	echo $E "$t19"
diff -ruN rkhunter.old/files/patch-rkhunter.conf rkhunter/files/patch-rkhunter.conf
--- rkhunter.old/files/patch-rkhunter.conf	Wed Mar 23 03:17:59 2005
+++ rkhunter/files/patch-rkhunter.conf	Wed Mar 23 03:42:22 2005
@@ -1,18 +1,11 @@
---- files/rkhunter.conf	Fri Aug 20 15:02:59 2004
-+++ files/rkhunter.conf	Sun Aug 29 23:22:13 2004
-@@ -14,7 +14,7 @@
- 
- # Use a custom temporary directory (you can override it with the
- # --tmpdir parameter)
--#TMPDIR=/tmp
-+TMPDIR=/tmp
+--- files/rkhunter.conf.old	Wed Mar 23 03:34:19 2005
++++ files/rkhunter.conf	Wed Mar 23 03:41:50 2005
+@@ -18,7 +18,7 @@
+ # Note: don't use /tmp as your temporary directory, because some
+ # important files will be written to this directory. Be sure
+ # you have setup your permissions very tight.
+-#TMPDIR=/usr/local/rkhunter/lib/rkhunter/tmp
++TMPDIR=/root

   # Use a custom database directory (you can override it with the
   # --dbdir parameter)
-@@ -25,4 +25,4 @@
- #MD5WHITELIST=/bin/ps:9bd8bf260adc81d3a43a086fce6b430a
- #MD5WHITELIST=/bin/ps:404583a6b166c2f7ac1287445a9de6b3
- 
--# The End
-\ No newline at end of file
-+# The End
diff -ruN rkhunter.old/pkg-plist rkhunter/pkg-plist
--- rkhunter.old/pkg-plist	Wed Mar 23 03:17:59 2005
+++ rkhunter/pkg-plist	Wed Mar 23 04:26:12 2005
@@ -1,4 +1,4 @@
-etc/rkhunter.conf.sample
+etc/rkhunter.conf
  bin/rkhunter
  lib/rkhunter/db/backdoorports.dat
  lib/rkhunter/db/mirrors.dat
Comment 4 vaidab 2005-03-29 19:45:44 UTC
did you find the reason of the problem ?
Comment 5 Simon Barner freebsd_committer 2005-05-18 17:38:07 UTC
State Changed
From-To: open->closed

Committed (with modifications). Thanks for your submission!