Package: rkhunter
Version: 1.4.2-0.4
Severity: normal

This NMU fixes an RC bug (#770242) with only a small change to the postinst 
script:

-        rkhtmpdir=$(grep '^TMPDIR' /etc/rkhunter.conf | sed 's/TMPDIR=//')
+        rkhtmpdir=/var/lib/rkhunter/tmp
+        if [ -e "/etc/rkhunter.conf" ]; then
+            rkhtmpdir=$(grep '^TMPDIR' /etc/rkhunter.conf | sed 's/TMPDIR=//')
+        fi
         [ -f $rkhtmpdir/passwd ] || cp -p /etc/passwd $rkhtmpdir >/dev/null 
2>&1

A full debdiff is attached.

Francois
diff -Nru rkhunter-1.4.2/debian/changelog rkhunter-1.4.2/debian/changelog
--- rkhunter-1.4.2/debian/changelog	2014-11-07 14:35:51.000000000 +1300
+++ rkhunter-1.4.2/debian/changelog	2014-11-29 00:27:20.000000000 +1300
@@ -1,3 +1,10 @@
+rkhunter (1.4.2-0.4) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Work-around missing /etc/rkhunter.conf in postinst (closes: #770242)
+
+ -- Francois Marier <franc...@debian.org>  Sat, 29 Nov 2014 00:26:17 +1300
+
 rkhunter (1.4.2-0.3) unstable; urgency=medium
 
   * Non-maintainer upload.
diff -Nru rkhunter-1.4.2/debian/postinst rkhunter-1.4.2/debian/postinst
--- rkhunter-1.4.2/debian/postinst	2014-11-07 14:35:51.000000000 +1300
+++ rkhunter-1.4.2/debian/postinst	2014-11-29 00:27:20.000000000 +1300
@@ -35,7 +35,10 @@
         # Copy the passwd/group files to the TMP directory
         # to avoid warnings when rkhunter is first run.
         # This is normally done by the installer script.
-        rkhtmpdir=$(grep '^TMPDIR' /etc/rkhunter.conf | sed 's/TMPDIR=//')
+        rkhtmpdir=/var/lib/rkhunter/tmp
+        if [ -e "/etc/rkhunter.conf" ]; then
+            rkhtmpdir=$(grep '^TMPDIR' /etc/rkhunter.conf | sed 's/TMPDIR=//')
+        fi
         [ -f $rkhtmpdir/passwd ] || cp -p /etc/passwd $rkhtmpdir >/dev/null 2>&1
         [ -f $rkhtmpdir/group ] || cp -p /etc/group $rkhtmpdir >/dev/null 2>&1
 
_______________________________________________
forensics-devel mailing list
forensics-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/forensics-devel

Reply via email to