ports/67207: Minor cleanup security/clamav
Rob Evers
rob at debank.tv
Wed May 26 08:20:54 UTC 2004
>Number: 67207
>Category: ports
>Synopsis: Minor cleanup security/clamav
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Wed May 26 01:20:12 PDT 2004
>Closed-Date:
>Last-Modified:
>Originator: Rob Evers
>Release: FreeBSD 5.2-CURRENT i386
>Organization:
>Environment:
System: FreeBSD flappie.debank.tv 5.2-CURRENT FreeBSD 5.2-CURRENT #1: Sun Feb 29 20:35:15 CET 2004 rob at flappie.debank.tv:/usr/obj/usr/src/sys/FLAPPIE i386
>Description:
Minor cleanup security/clamav
Change the default milter socket to match clamav-devel port (/var/run/clamav/clmilter.sock)
This doesn't affect users with already installed config files.
Note: the clamav and clamav-devel port now have the same default locations for sockets and log-files, this should make it painless to switch between the two.
Remove some options from the clamav-freshclam.sh script, these are already covered in the config file (freshclam.conf)
>How-To-Repeat:
>Fix:
--- clamav.patch begins here ---
diff -ruN ../clamav.orig/Makefile ./Makefile
--- ../clamav.orig/Makefile Tue May 25 11:49:23 2004
+++ ./Makefile Wed May 26 10:03:27 2004
@@ -7,6 +7,7 @@
PORTNAME= clamav
PORTVERSION= ${DISTVERSION:S/-rc//g:S/-/./g}
+PORTREVISION= 1
CATEGORIES= security
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE_EXTENDED}
MASTER_SITE_SUBDIR= clamav
@@ -42,9 +43,7 @@
--disable-clamuko \
--disable-clamav \
--enable-bigstack \
- --disable-dependency-tracking \
- --with-user=${CLAMAVUSER} \
- --with-group=${CLAMAVGROUP}
+ --disable-dependency-tracking
CPPFLAGS+= -I${LOCALBASE}/include \
${PTHREAD_CFLAGS}
LDFLAGS+= -L${LOCALBASE}/lib \
@@ -55,12 +54,12 @@
MAN5= clamav.conf.5
MAN8= clamd.8 clamav-milter.8
+CONFLICTS= clamav-devel-*
+
CLAMAVUSER?= clamav
CLAMAVGROUP?= clamav
CLAMAV_CLAMD_SOCKET?= /var/run/clamav/clamd
-CLAMAV_MILTER_SOCKET?= /var/run/clmilter.sock
-
-CONFLICTS= clamav-devel-*
+CLAMAV_MILTER_SOCKET?= /var/run/clamav/clmilter.sock
SED_SCRIPT= -e 's|%%PREFIX%%|${PREFIX}|g' \
-e 's|%%DATADIR%%|${DATADIR}|g' \
@@ -110,8 +109,6 @@
${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
@${REINPLACE_CMD} -e 's|/usr/lib/sendmail|/usr/sbin/sendmail|g' \
${WRKSRC}/clamav-milter/clamav-milter.c
-
-# @${REINPLACE_CMD} -E -e 's/(_LIBS=.*)-l?pthread -lc_r[[:>:]]/\1${PTHREAD_LIBS}/' \
post-build:
@${REINPLACE_CMD} ${SED_CONF} ${BUILD_WRKSRC}/etc/clamav.conf
diff -ruN ../clamav.orig/files/clamav-freshclam.sh ./files/clamav-freshclam.sh
--- ../clamav.orig/files/clamav-freshclam.sh Tue May 25 11:49:23 2004
+++ ./files/clamav-freshclam.sh Wed May 26 09:29:32 2004
@@ -9,11 +9,11 @@
# KEYWORD: FreeBSD shutdown
#
-# Add the following lines to /etc/rc.conf to enable freshclam:
+# Add the following lines to /etc/rc.conf to enable freshclam daemon:
#
#clamav_freshclam_enable="YES"
#
-# See freshclam(8) for flags
+# See freshclam(1) for flags
#
. %%RC_SUBR%%
@@ -23,11 +23,12 @@
command=%%PREFIX%%/bin/freshclam
required_dirs=%%DATADIR%%
+required_files=%%PREFIX%%/etc/freshclam.conf
# set defaults
clamav_freshclam_enable=${clamav_freshclam_enable:-"NO"}
-clamav_freshclam_flags=${clamav_freshclam_flags:-"--checks=1 --datadir=%%DATADIR%% --daemon-notify=%%PREFIX%%/etc/clamav.conf --log=/var/log/clamav/freshclam.log"}
+clamav_freshclam_flags=${clamav_freshclam_flags:-"--daemon-notify=%%PREFIX%%/etc/clamav.conf"}
load_rc_config $name
--- clamav.patch ends here ---
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list