[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#741684: opu: package clamav/0.98.1+dfsg-1+deb6u2



Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: opu

See #741512 for details. Upstream config file renaming in 0.98 did not get
properly accounted for in the packaging causing both upgrade bugs and new
options not being correctly supported.  The attached debdiff fixes both
issues
diff -u clamav-0.98.1+dfsg/debian/rules clamav-0.98.1+dfsg/debian/rules
--- clamav-0.98.1+dfsg/debian/rules
+++ clamav-0.98.1+dfsg/debian/rules
@@ -41,19 +41,19 @@
 
 config.status: configure
 	dh_testdir
-	egrep '^#[[:alpha:]]' etc/clamd.conf | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
+	egrep '^#[[:alpha:]]' etc/clamd.conf.sample | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
 	  if ! grep -q "$${opt}" debian/clamav-base.postinst.in ; then \
 	    echo "Unhandled option(clamd.conf): $${opt}"; \
 	    exit 1; \
 	  fi;\
 	done;
-	egrep '^#[[:alpha:]]' etc/freshclam.conf | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
+	egrep '^#[[:alpha:]]' etc/freshclam.conf.sample | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
 	  if ! grep -q "$${opt}" debian/clamav-freshclam.postinst.in ; then \
 	    echo "Unhandled option (freshclam.conf): $${opt}"; \
 	    exit 1; \
 	  fi;\
 	done;
-	egrep '^#[[:alpha:]]' etc/clamav-milter.conf | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
+	egrep '^#[[:alpha:]]' etc/clamav-milter.conf.sample | sed -e 's/^#//' | awk '{print $$1}' | while read opt; do \
 	  if ! grep -q "$${opt}" debian/clamav-milter.postinst.in ; then \
 	    echo "Unhandled option (clamav-milter.conf): $${opt}"; \
 	    exit 1; \
diff -u clamav-0.98.1+dfsg/debian/clamav-milter.postinst.in clamav-0.98.1+dfsg/debian/clamav-milter.postinst.in
--- clamav-0.98.1+dfsg/debian/clamav-milter.postinst.in
+++ clamav-0.98.1+dfsg/debian/clamav-milter.postinst.in
@@ -95,6 +95,10 @@
     db_metaget clamav-milter/MaxFileSize value || true
     maxfilesize="`echo $RET | sed -e s/M//g`"
     MaxFSize="${maxfilesize}M"
+    db_metaget clamav-milter/LogRotate value || true
+    LogRotate="$RET"
+    db_metaget clamav-milter/SupportMultipleRecipients value || true
+    SupportMultipleRecipients="$RET"
 
     if [ -z "$logfile" ] || [ "$logfile" = 'none' ]; then
       logsyslog=true
@@ -160,7 +164,9 @@
 LogVerbose $logverbose
 LogInfected $loginfected
 LogClean $logclean
+LogRotate $LogRotate
 MaxFileSize $MaxFSize
+SupportMultipleRecipients $SupportMultipleRecipients
 EOF
     if [ -n "$SkipAuthenticated" ]; then
       cat >> $DEBCONFFILE << EOF
@@ -208,6 +214,7 @@
       echo "LogTime $logtime" >> $DEBCONFFILE
       echo "LogFileUnlock $logfileunlock" >> $DEBCONFFILE
       echo "LogFileMaxSize $logfilemaxsize" >> $DEBCONFFILE
+      echo "LogRotate $LogRotate" >> $DEBCONFFILE
     fi
 
     [ -n "$miltersocketgrp" ] && echo "MilterSocketGroup $miltersocketgrp" >> $DEBCONFFILE
diff -u clamav-0.98.1+dfsg/debian/clamav-base.postinst.in clamav-0.98.1+dfsg/debian/clamav-base.postinst.in
--- clamav-0.98.1+dfsg/debian/clamav-base.postinst.in
+++ clamav-0.98.1+dfsg/debian/clamav-base.postinst.in
@@ -149,6 +149,8 @@
       db_metaget clamav-base/LogTime value || true
       logtime="$RET"
     fi
+    db_metaget clamav-base/LogRotate value || true
+    logrotate="$RET"
     db_get clamav-base/SelfCheck || true
     selfcheck="$RET"
     db_metaget clamav-base/Bytecode value || true
@@ -159,6 +161,36 @@
       db_metaget clamav-base/BytecodeTimeout value || true
       bytecodetime="$RET"
     fi
+    db_metaget clamav-base/ScanOnAccess value || true
+    ScanOnAccess="$RET"
+    if [ $ScanOnAccess = "yes" ]; then
+      db_metaget clamav-base/OnAccessIncludePath value || true
+      OnAccessIncludePath="$RET"
+      db_metaget clamav-base/OnAccessExcludePath value || true
+      OnAccessExcludePath="$RET"
+      db_metaget clamav-base/OnAccessMaxFileSize value || true
+      OnAccessMaxFileSize="$RET"
+      db_metaget clamav-base/OnAccessExcludeUID value || true
+      OnAccessExcludeUID="$RET"
+    fi
+    db_metaget clamav-base/AllowAllMatchScan value || true
+    AllowAllMatchScan="$RET"
+    db_metaget clamav-base/ForceToDisk value || true
+    ForceToDisk="$RET"
+    db_metaget clamav-base/DisableCertCheck value || true
+    DisableCertCheck="$RET"
+    db_metaget clamav-base/ScanSWF value || true
+    ScanSWF="$RET"
+    db_metaget clamav-base/MaxEmbeddedPE value || true
+    MaxEmbeddedPE="$RET"
+    db_metaget clamav-base/MaxHTMLNormalize value || true
+    MaxHTMLNormalize="$RET"
+    db_metaget clamav-base/MaxHTMLNoTags value || true
+    MaxHTMLNoTags="$RET"
+    db_metaget clamav-base/MaxScriptNormalize value || true
+    MaxScriptNormalize="$RET"
+    db_metaget clamav-base/MaxZipTypeRcg value || true
+    MaxZipTypeRcg="$RET"
 
     slurp_config "$CLAMAVCONF"
     
@@ -198,6 +230,7 @@
     [ -z "$maxconnQleng" ] && maxconnQleng=15
     [ -z "$streamsavelength" ] && streamsavelength=10
     [ -z "$LogFacility" ] && LogFacility=LOG_LOCAL6
+    [ -z "$LogRotate" ] && LogRotate=true
     [ -z "$LogFileUnlock" ] && LogFileUnlock=false
     [ -z "$LogFileMaxSize" ] && LogFileMaxSize=0
     [ -z "$LogClean" ] && LogClean=false
@@ -272,6 +305,7 @@
 MaxThreads $maxthreads
 MaxConnectionQueueLength $maxconnQleng
 LogSyslog $logsyslog
+LogRotate $logrotate
 LogFacility $LogFacility
 LogClean $LogClean
 LogVerbose $LogVerbose
@@ -281,8 +315,14 @@
 Foreground $Foreground
 Debug $Debug
 ScanPE $ScanPE
+MaxEmbeddedPE $MaxEmbeddedPE
 ScanOLE2 $ScanOLE2
 ScanHTML $ScanHTML
+MaxHTMLNormalize $MaxHTMLNormalize
+MaxHTMLNoTags $MaxHTMLNoTags
+MaxScriptNormalize $MaxScriptNormalize
+MaxZipTypeRcg $MaxZipTypeRcg
+ScanSWF $ScanSWF
 DetectBrokenExecutables $DetectBrokenExecutables
 ExitOnOOM $ExitOnOOM
 LeaveTemporaryFiles $LeaveTemporaryFiles
@@ -302,6 +342,14 @@
 MaxQueue $MaxQueue
 ExtendedDetectionInfo $ExtendedDetectionInfo
 OLE2BlockMacros $OLE2BlockMacros
+ScanOnAccess $ScanOnAccess
+OnAccessIncludePath $OnAccessIncludePath
+OnAccessExcludePath $OnAccessExcludePath
+OnAccessMaxFileSize $OnAccessMaxFileSize
+OnAccessExcludeUID $OnAccessExcludeUID
+AllowAllMatchScan $AllowAllMatchScan
+ForceToDisk $ForceToDisk
+DisableCertCheck $DisableCertCheck
 EOF
 
     if is_true "$StructuredDataDetection"; then
@@ -376,7 +424,7 @@
     
   else
     ucf_cleanup "$CLAMAVCONF"
-    ucf_upgrade_check "$CLAMAVCONF" /usr/share/doc/clamav-base/examples/clamd.conf /var/lib/ucf/cache/:etc:clamav:clamd.conf
+    ucf_upgrade_check "$CLAMAVCONF" /usr/share/doc/clamav-base/examples/clamd.conf.sample /var/lib/ucf/cache/:etc:clamav:clamd.conf
 
     db_stop || true
   fi
diff -u clamav-0.98.1+dfsg/debian/changelog clamav-0.98.1+dfsg/debian/changelog
--- clamav-0.98.1+dfsg/debian/changelog
+++ clamav-0.98.1+dfsg/debian/changelog
@@ -1,3 +1,17 @@
+clamav (0.98.1+dfsg-1+deb6u2) oldstable; urgency=medium
+
+  [ Andreas Cadhalpun ]
+  * debian/clamav-base.postinst.in and debian/rules: Update to reflect the
+    change from examples/clamd.conf to examples/clamd.conf.sample
+   (Closes: #741512)
+
+  [ Scott Kitterman ]
+  * Add options in debian/clamav-base.postinst.in, clamav-daemon.postinst.in,
+    clamav-freshclam.postinst.in, and clamav-milter.postinst.in for new 0.98
+    series options
+
+ -- Scott Kitterman <scott@kitterman.com>  Sat, 15 Mar 2014 11:47:54 -0400
+
 clamav (0.98.1+dfsg-1+deb6u1) oldstable; urgency=medium
 
   [ Adam Conrad ]
diff -u clamav-0.98.1+dfsg/debian/clamav-freshclam.postinst.in clamav-0.98.1+dfsg/debian/clamav-freshclam.postinst.in
--- clamav-0.98.1+dfsg/debian/clamav-freshclam.postinst.in
+++ clamav-0.98.1+dfsg/debian/clamav-freshclam.postinst.in
@@ -96,6 +96,10 @@
   [ "$RET" = "true" ] && notify="/etc/clamav/clamd.conf"
   db_metaget clamav-base/Bytecode value || true
   bytecode="$RET"
+  db_metaget clamav-base/LogRotate value || true
+  LogRotate="$RET"
+  db_metaget clamav-base/PrivateMirror value || true
+  PrivateMirror="$RET"
 
   slurp_config "$FRESHCLAMCONFFILE"
 
@@ -109,7 +113,11 @@
     if echo "$udlogfile" | grep -q '^/dev/'; then
       make_logrotate=false
     else
-      make_logrotate=true
+      if [ -n $LogRotate ]; then
+        make_logrotate=true
+      else
+        make_logrotate=false
+      fi
     fi
     [ -n "$User" ] || User=clamav
     if [ "$make_logrotate" = 'true' ]; then
@@ -204,6 +212,7 @@
 LogSyslog $LogSyslog
 LogFacility $LogFacility
 LogFileMaxSize $LogFileMaxSize
+LogRotate $Logrotate
 LogTime $LogTime
 Foreground $Foreground
 Debug $Debug
@@ -218,6 +227,7 @@
 ScriptedUpdates $ScriptedUpdates
 CompressLocalDatabase $CompressLocalDatabase
 Bytecode $bytecode
+PrivateMirror $PrivateMirror
 EOF
 
   if [ -n "$notify" ] ;then
diff -u clamav-0.98.1+dfsg/debian/clamav-daemon.postinst.in clamav-0.98.1+dfsg/debian/clamav-daemon.postinst.in
--- clamav-0.98.1+dfsg/debian/clamav-daemon.postinst.in
+++ clamav-0.98.1+dfsg/debian/clamav-daemon.postinst.in
@@ -38,7 +38,11 @@
     if echo "$LogFile" | grep -q '^/dev/'; then
       make_logrotate=false
     else
-      make_logrotate=true
+      if [ $LogRotate ]; then
+        make_logrotate=true
+      else
+        make_logrotate=false
+      fi
     fi
     [ -n "$User" ] || User=clamav
     if [ "$make_logrotate" = 'true' ]; then

Reply to: