merged with F-8

This commit is contained in:
ensc 2008-01-01 13:19:16 +00:00
parent b9a8a98bb8
commit 93ac5ce230
14 changed files with 98 additions and 163 deletions

View File

@ -1 +1,2 @@
clamav-0.92.clean.tar.gz
clamav-*.tar.gz*
clamav-*.*.rpm

5
README.fedora Normal file
View File

@ -0,0 +1,5 @@
Add
INPUT_MAIL_FILTER(`clamav', `S=local:/var/run/clamav-milter/clamav.sock, F=, T=S:4m;R:4m')dnl
to your sendmail.mc.

View File

@ -1,28 +0,0 @@
--- clamav-0.90rc3/libclamav.pc.in.private 2004-07-14 13:35:38.000000000 +0200
+++ clamav-0.90rc3/libclamav.pc.in 2007-02-04 12:24:35.000000000 +0100
@@ -6,6 +6,6 @@
Name: libclamav
Description: A GPL virus scanner
Version: @LIBCLAMAV_VERSION@
-Libs: -L${libdir} -lclamav @LIBCLAMAV_LIBS@
-Cflags: -I${includedir} @CFLAGS@
-
+Libs: -L${libdir} -lclamav
+Libs.private: -L${libdir} -lclamav @LIBCLAMAV_LIBS@
+Cflags: -I${includedir}
--- clamav-0.90rc3/clamav-config.in.private 2004-06-06 03:50:08.000000000 +0200
+++ clamav-0.90rc3/clamav-config.in 2007-02-04 12:25:27.000000000 +0100
@@ -55,11 +55,11 @@
;;
--cflags)
- echo -I@includedir@ @CFLAGS@
+ echo -I@includedir@
;;
--libs)
- echo -L@libdir@ @LIBCLAMAV_LIBS@
+ echo -L@libdir@ -lclamav
;;
*)

View File

@ -1,22 +0,0 @@
--- clamav-0.91.2/clamd/dazukoio_compat12.c.open 2007-03-06 14:38:06.000000000 +0100
+++ clamav-0.91.2/clamd/dazukoio_compat12.c 2007-08-25 12:36:30.000000000 +0200
@@ -89,7 +89,7 @@ int dazukoRegister_TS_compat12(struct da
if (dazuko->device < 0)
{
- dazuko->device = open("/dev/dazuko", 0);
+ dazuko->device = open("/dev/dazuko", O_RDONLY);
if (dazuko->device < 0)
return -1;
--- clamav-0.91.2/shared/misc.c.open 2007-03-31 21:27:31.000000000 +0200
+++ clamav-0.91.2/shared/misc.c 2007-08-25 12:36:30.000000000 +0200
@@ -165,7 +165,7 @@ int filecopy(const char *src, const char
if((s = open(src, O_RDONLY|O_BINARY)) == -1)
return -1;
- if((d = open(dest, O_CREAT|O_WRONLY|O_TRUNC|O_BINARY)) == -1) {
+ if((d = open(dest, O_CREAT|O_WRONLY|O_TRUNC|O_BINARY, 0600)) == -1) {
close(s);
return -1;
}

View File

@ -1,57 +0,0 @@
diff -up clamav-0.92/Makefile.in.BAD clamav-0.92/Makefile.in
--- clamav-0.92/Makefile.in.BAD 2007-12-21 12:39:00.000000000 -0500
+++ clamav-0.92/Makefile.in 2007-12-21 12:39:11.000000000 -0500
@@ -242,7 +242,7 @@ target_os = @target_os@
target_vendor = @target_vendor@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
-SUBDIRS = libclamunrar libclamunrar_iface libclamav clamscan clamd clamdscan freshclam sigtool clamconf database docs etc clamav-milter
+SUBDIRS = libclamav clamscan clamd clamdscan freshclam sigtool clamconf database docs etc clamav-milter
EXTRA_DIST = FAQ contrib test examples BUGS shared libclamav.pc.in UPGRADE COPYING.nsis COPYING.unrar COPYING.LGPL
bin_SCRIPTS = clamav-config
pkgconfigdir = $(libdir)/pkgconfig
diff -up clamav-0.92/configure.in.BAD clamav-0.92/configure.in
--- clamav-0.92/configure.in.BAD 2007-12-21 12:37:51.000000000 -0500
+++ clamav-0.92/configure.in 2007-12-21 12:38:00.000000000 -0500
@@ -1214,8 +1214,6 @@ AC_MSG_RESULT($have_signed_rightshift_ex
AC_C_FPU_BIGENDIAN
AC_OUTPUT([
-libclamunrar/Makefile
-libclamunrar_iface/Makefile
libclamav/Makefile
clamscan/Makefile
database/Makefile
diff -up clamav-0.92/Makefile.am.BAD clamav-0.92/Makefile.am
--- clamav-0.92/Makefile.am.BAD 2007-12-21 12:38:39.000000000 -0500
+++ clamav-0.92/Makefile.am 2007-12-21 12:38:47.000000000 -0500
@@ -16,7 +16,7 @@
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA.
-SUBDIRS = libclamunrar libclamunrar_iface libclamav clamscan clamd clamdscan freshclam sigtool clamconf database docs etc clamav-milter
+SUBDIRS = libclamav clamscan clamd clamdscan freshclam sigtool clamconf database docs etc clamav-milter
EXTRA_DIST = FAQ contrib test examples BUGS shared libclamav.pc.in UPGRADE COPYING.nsis COPYING.unrar COPYING.LGPL
bin_SCRIPTS=clamav-config
diff -up clamav-0.92/configure.BAD clamav-0.92/configure
--- clamav-0.92/configure.BAD 2007-12-21 12:45:38.000000000 -0500
+++ clamav-0.92/configure 2007-12-21 12:46:05.000000000 -0500
@@ -26397,7 +26397,7 @@ echo "$as_me: WARNING: Unable to determi
esac
-ac_config_files="$ac_config_files libclamunrar/Makefile libclamunrar_iface/Makefile libclamav/Makefile clamscan/Makefile database/Makefile docs/Makefile clamd/Makefile clamdscan/Makefile clamav-milter/Makefile freshclam/Makefile sigtool/Makefile clamconf/Makefile etc/Makefile Makefile clamav-config libclamav.pc docs/man/clamav-milter.8 docs/man/clamconf.1 docs/man/clamd.8 docs/man/clamd.conf.5 docs/man/clamdscan.1 docs/man/clamscan.1 docs/man/freshclam.1 docs/man/freshclam.conf.5 docs/man/sigtool.1"
+ac_config_files="$ac_config_files libclamav/Makefile clamscan/Makefile database/Makefile docs/Makefile clamd/Makefile clamdscan/Makefile clamav-milter/Makefile freshclam/Makefile sigtool/Makefile clamconf/Makefile etc/Makefile Makefile clamav-config libclamav.pc docs/man/clamav-milter.8 docs/man/clamconf.1 docs/man/clamd.8 docs/man/clamd.conf.5 docs/man/clamdscan.1 docs/man/clamscan.1 docs/man/freshclam.1 docs/man/freshclam.conf.5 docs/man/sigtool.1"
cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
@@ -27013,8 +27013,6 @@ do
case $ac_config_target in
"clamav-config.h") CONFIG_HEADERS="$CONFIG_HEADERS clamav-config.h" ;;
"depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libclamunrar/Makefile") CONFIG_FILES="$CONFIG_FILES libclamunrar/Makefile" ;;
- "libclamunrar_iface/Makefile") CONFIG_FILES="$CONFIG_FILES libclamunrar_iface/Makefile" ;;
"libclamav/Makefile") CONFIG_FILES="$CONFIG_FILES libclamav/Makefile" ;;
"clamscan/Makefile") CONFIG_FILES="$CONFIG_FILES clamscan/Makefile" ;;
"database/Makefile") CONFIG_FILES="$CONFIG_FILES database/Makefile" ;;

29
clamav-0.92-private.patch Normal file
View File

@ -0,0 +1,29 @@
--- clamav-0.92/libclamav.pc.in.private
+++ clamav-0.92/libclamav.pc.in
@@ -6,6 +6,6 @@ includedir=@includedir@
Name: libclamav
Description: A GPL virus scanner
Version: @LIBCLAMAV_VERSION@
-Libs: -L${libdir} -lclamav @LIBCLAMAV_LIBS@
-Cflags: -I${includedir} @CFLAGS@
-
+Libs: -L${libdir} -lclamav
+Libs.private: -L${libdir} -lclamav @LIBCLAMAV_LIBS@
+Cflags: -I${includedir}
--- clamav-0.92/clamav-config.in.private
+++ clamav-0.92/clamav-config.in
@@ -54,12 +54,8 @@ while test $# -gt 0; do
usage 0
;;
- --cflags)
- echo -I@includedir@ @CFLAGS@
- ;;
-
- --libs)
- echo -L@libdir@ @LIBCLAMAV_LIBS@
+ (--cflags|--libs)
+ ${PKG_CONFIG:-pkg-config} "$1" libclamav
;;
*)

View File

@ -1,16 +1,16 @@
#! /bin/bash
# Copyright (C) 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
#
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License.
#
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.

View File

@ -1,7 +1,8 @@
## $Id: clamav.spec,v 1.61 2007/12/21 18:06:29 spot Exp $
## $Id: clamav.spec,v 1.62 2007/12/21 18:11:32 spot Exp $
## Fedora Extras specific customization below...
%bcond_without fedora
%bcond_without fedora
%bcond_with unrar
##
%global username clamav
@ -18,19 +19,13 @@
Summary: End-user tools for the Clam Antivirus scanner
Name: clamav
Version: 0.92
Release: %release_func 3
Release: %release_func 4
License: GPLv2
License: %{?with_unrar:proprietary}%{!?with_unrar:GPLv2}
Group: Applications/File
URL: http://www.clamav.net
# Unfortunately, clamav includes support for RAR v3, derived from GPL
# incompatible unrar from RARlabs. We have to pull this code out.
# All that is needed to make the clean tarball is: rm -rf libclamunrar*
# Note that you also need patch26.
Source0: clamav-%{version}.clean.tar.gz
# Source0: http://download.sourceforge.net/sourceforge/clamav/%name-%version.tar.gz
# No sense in using this file for the time being.
# Source999: http://download.sourceforge.net/sourceforge/clamav/%name-%version.tar.gz.sig
Source0: http://download.sourceforge.net/sourceforge/clamav/%name-%version.tar.gz
Source999: http://download.sourceforge.net/sourceforge/clamav/%name-%version.tar.gz.sig
Source1: clamd-wrapper
Source2: clamd.sysconfig
Source3: clamd.logrotate
@ -40,9 +35,8 @@ Source7: clamd.SERVICE.init
Source8: clamav-notify-servers
Patch21: clamav-0.70-path.patch
Patch22: clamav-0.80-initoff.patch
Patch24: clamav-0.90rc3-private.patch
Patch24: clamav-0.92-private.patch
Patch25: clamav-0.92-open.patch
Patch26: clamav-0.92-nounrar.patch
BuildRoot: %_tmppath/%name-%version-%release-root
Requires: clamav-lib = %version-%release
Requires: data(clamav)
@ -73,6 +67,7 @@ Source100: clamd-gen
Requires: clamav-lib = %version-%release
Requires: clamav-filesystem = %version-%release
Requires(pre): %_libdir/pkgconfig
Requires: pkgconfig
%package data
Summary: Virus signature data for the Clam Antivirus scanner
@ -122,6 +117,7 @@ Requires(postun): %_initrddir
Summary: Sendmail-milter for the Clam Antivirus scanner
Group: System Environment/Daemons
Requires: init(clamav-milter)
Source300: README.fedora
BuildRequires: sendmail-devel
BuildRequires: fedora-usermgmt-devel
Provides: user(%milteruser)
@ -215,12 +211,7 @@ SysV initscripts template for the clamav server
%description milter
This package contains files which are needed to run the clamav-milter. It
can be activated by adding
| INPUT_MAIL_FILTER(`clamav', `S=local:%milterstatedir/clamav.sock, F=, T=S:4m;R:4m')dnl
to your sendmail.mc.
This package contains files which are needed to run the clamav-milter.
%description milter-sysv
The SysV initscripts for clamav-milter.
@ -235,7 +226,9 @@ The SysV initscripts for clamav-milter.
%patch22 -p1 -b .initoff
%patch24 -p1 -b .private
%patch25 -p1 -b .open
%patch26 -p1 -b .nounrar
install -p -m0644 %SOURCE300 clamav-milter/
perl -pi -e 's!^(#?LogFile ).*!\1/var/log/clamd.<SERVICE>!g;
s!^#?(LocalSocket ).*!\1/var/run/clamd.<SERVICE>/clamd.sock!g;
@ -254,12 +247,16 @@ CFLAGS="$RPM_OPT_FLAGS -Wall -W -Wmissing-prototypes -Wmissing-declarations -std
export LDFLAGS='-Wl,--as-needed'
# HACK: remove me, when configure uses $LIBS instead of $LDFLAGS for milter check
export LIBS='-lmilter -lpthread'
%configure --disable-clamav --with-dbdir=/var/lib/clamav \
--enable-milter --disable-static --disable-unrar
sed -i -e 's! -shared ! -Wl,--as-needed\0!g' libtool
# No rpath
sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
%configure --disable-clamav --with-dbdir=/var/lib/clamav \
--enable-milter --disable-static --disable-rpath \
%{!?with_unrar:--disable-unrar}
# build with --as-needed and disable rpath
sed -i \
-e 's! -shared ! -Wl,--as-needed\0!g' \
-e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
-e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' \
libtool
make %{?_smp_mflags}
@ -291,15 +288,20 @@ install -d -m755 \
${RPM_BUILD_ROOT}%milterstatedir \
${RPM_BUILD_ROOT}%pkgdatadir/template \
${RPM_BUILD_ROOT}%_initrddir \
${RPM_BUILD_ROOT}%homedir/daily.inc
${RPM_BUILD_ROOT}%homedir/{main,daily}.inc
rm -f ${RPM_BUILD_ROOT}%_sysconfdir/clamd.conf \
${RPM_BUILD_ROOT}%_libdir/*.la
for i in COPYING daily.{db,fp,hdb,info,ndb,pdb,zmd}; do
touch ${RPM_BUILD_ROOT}%homedir/daily.inc/$i
for i in cfg db fp hdb info mdb mdu ndb ndu pdb wdb zmd; do
touch ${RPM_BUILD_ROOT}%homedir/daily.inc/daily.$i
touch ${RPM_BUILD_ROOT}%homedir/main.inc/main.$i
done
touch ${RPM_BUILD_ROOT}%homedir/daily.inc/COPYING
touch ${RPM_BUILD_ROOT}%homedir/main.inc/COPYING
## prepare the server-files
mkdir _doc_server
@ -470,14 +472,8 @@ test "$1" = 0 || %_initrddir/clamav-milter condrestart >/dev/null || :
%ghost %attr(0664,root,%username) %verify(not size md5 mtime) %freshclamlog
%ghost %attr(0664,%username,%username) %homedir/daily.inc/COPYING
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.db
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.fp
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.hdb
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.info
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.ndb
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.pdb
%ghost %attr(0664,%username,%username) %homedir/daily.inc/daily.zmd
%ghost %attr(0664,%username,%username) %homedir/daily.inc/*
%ghost %attr(0664,%username,%username) %homedir/main.inc/*
## -----------------------
@ -503,7 +499,7 @@ test "$1" = 0 || %_initrddir/clamav-milter condrestart >/dev/null || :
%files milter
%defattr(-,root,root,-)
%doc clamav-milter/INSTALL
%doc clamav-milter/INSTALL clamav-milter/README.fedora
%_sbindir/*milter*
%_mandir/man8/clamav-milter*
%config(noreplace) %verify(not mtime) %_sysconfdir/clamd.d/milter.conf
@ -519,6 +515,16 @@ test "$1" = 0 || %_initrddir/clamav-milter condrestart >/dev/null || :
%changelog
* Mon Dec 31 2007 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de> - 0.92-4
- added a README.fedora to the milter package (#240610)
- ship original sources again; unrar is now licensed correctly (no more
stolen code put under GPL). Nevertheless, this license is not GPL
compatible, and to allow libclamav to be used by GPL applications,
unrar is disabled by a ./configure switch.
- use pkg-config in clamav-config to emulate --cflags and --libs
operations (fixes partly multilib issues)
- registered some more auto-updated files and marked them as %%ghost
* Fri Dec 21 2007 Tom "spot" Callaway <tcallawa@redhat.com> - 0.92-3
- updated to 0.92 (SECURITY):
- CVE-2007-6335 MEW PE File Integer Overflow Vulnerability

View File

@ -1,16 +1,16 @@
#! /bin/bash
# Copyright (C) 2004 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
#
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License.
#
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@ -19,7 +19,7 @@ function showHelp()
{
echo \
$"Usage: clamd-gen --service=<SERVICE> --version=<VERSION> --release=<RELEASE>
--license=<LICENSE> --username=>USERNAME>
--license=<LICENSE> --username=>USERNAME>
"
exit 0
}
@ -227,7 +227,7 @@ function rpm.genFiles
%dir %minitsvcdir
%config(noreplace) %verify(not mtime) %minitsvcdir/params
%config %minitsvcdir/run
%minitsvcdir/respawn
%minitsvcdir/respawn
%endif
EOF
}

View File

@ -28,7 +28,7 @@ CLAMD_CONFIGFILE=/etc/clamd.d/${CLAMD_SERVICE}.conf
CLAMD_OPTIONS=
## backward-compatibility check...
for i in /var/run/clamd.${CLAMD_SERVICE}/clamd.sock \
/var/run/clamav.${CLAMD_SERVICE}/clamd.sock; do
/var/run/clamav.${CLAMD_SERVICE}/clamd.sock; do
CLAMD_SOCKET=$i
test ! -e "$i" || break
done

View File

@ -1,15 +1,15 @@
#! /bin/bash
# Copyright (C) 2005 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
#
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 of the License.
#
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
@ -33,7 +33,7 @@ case $FRESHCLAM_DELAY in
(disabled-warn)
echo $"\
WARNING: update of clamav database is disabled; please see
'$f'
'$f'
for information how to enable the periodic update resp. how to turn
off this message." >&2
exit 1

View File

@ -1 +1 @@
0.91.2
0.92

View File

@ -1 +1,2 @@
554d44a5b2265808750553d2e4d0d6fb clamav-0.92.clean.tar.gz
e500651858a9187a87025c8a5c23969c clamav-0.92.tar.gz
5ac3264d9b01b7dce93f646e247b2621 clamav-0.92.tar.gz.sig

View File

@ -1,2 +1,2 @@
http://prdownloads.sourceforge.net/sourceforge/clamav/
clamav-(.*?)\.tar\.
clamav-([0-9.-]*?)\.tar\.