diff options
author | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-11-22 15:46:03 +0000 |
---|---|---|
committer | Diego Elio Pettenò <flameeyes@gentoo.org> | 2010-11-22 15:46:03 +0000 |
commit | 7a0a239d34c07cf1bdfbeebd023ca67a20a34a23 (patch) | |
tree | 0e1f8594e69192caff3c7349e22a3a8b34b1b88b /net-proxy/squidclamav | |
parent | Initial import of the c-icap server to be used with Squid and SquidClamav 6. (diff) | |
download | historical-7a0a239d34c07cf1bdfbeebd023ca67a20a34a23.tar.gz historical-7a0a239d34c07cf1bdfbeebd023ca67a20a34a23.tar.bz2 historical-7a0a239d34c07cf1bdfbeebd023ca67a20a34a23.zip |
Version bump (closes bug #313089), this time using the c-icap module. Need a keyword request for x86.
Package-Manager: portage-2.2.0_alpha4/cvs/Linux x86_64
Diffstat (limited to 'net-proxy/squidclamav')
-rw-r--r-- | net-proxy/squidclamav/ChangeLog | 11 | ||||
-rw-r--r-- | net-proxy/squidclamav/files/squidclamav-6.1-crash.patch | 19 | ||||
-rw-r--r-- | net-proxy/squidclamav/metadata.xml | 15 | ||||
-rw-r--r-- | net-proxy/squidclamav/squidclamav-6.1.ebuild | 59 |
4 files changed, 99 insertions, 5 deletions
diff --git a/net-proxy/squidclamav/ChangeLog b/net-proxy/squidclamav/ChangeLog index a09cfc7f21c1..a7f49139d020 100644 --- a/net-proxy/squidclamav/ChangeLog +++ b/net-proxy/squidclamav/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for net-proxy/squidclamav -# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidclamav/ChangeLog,v 1.10 2009/10/18 15:14:25 mrness Exp $ +# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidclamav/ChangeLog,v 1.11 2010/11/22 15:46:03 flameeyes Exp $ + +*squidclamav-6.1 (22 Nov 2010) + + 22 Nov 2010; Diego E. Pettenò <flameeyes@gentoo.org> + +squidclamav-6.1.ebuild, +files/squidclamav-6.1-crash.patch, metadata.xml: + Version bump (closes bug #313089), this time using the c-icap module. Need a + keyword request for x86. 18 Oct 2009; Alin Năstac <mrness@gentoo.org> -squidclamav-3.6.ebuild, -files/squidclamav-3.6-gentoo.patch: diff --git a/net-proxy/squidclamav/files/squidclamav-6.1-crash.patch b/net-proxy/squidclamav/files/squidclamav-6.1-crash.patch new file mode 100644 index 000000000000..f197aac6618c --- /dev/null +++ b/net-proxy/squidclamav/files/squidclamav-6.1-crash.patch @@ -0,0 +1,19 @@ +Index: squidclamav-6.1/src/squidclamav.c +=================================================================== +--- squidclamav-6.1.orig/src/squidclamav.c ++++ squidclamav-6.1/src/squidclamav.c +@@ -427,8 +427,12 @@ int squidclamav_check_preview_handler(ch + } else { + data->user = NULL; + } +- data->clientip = ci_buffer_alloc(strlen(clientip)+1); +- strcpy(data->clientip, clientip); ++ if (clientip != NULL) { ++ data->clientip = ci_buffer_alloc(strlen(clientip)+1); ++ strcpy(data->clientip, clientip); ++ } else { ++ data->clientip = NULL; ++ } + + data->body = ci_simple_file_new(MAX_OBJECT_SIZE); + if (SEND_PERCENT_BYTES >= 0 && START_SEND_AFTER == 0) { diff --git a/net-proxy/squidclamav/metadata.xml b/net-proxy/squidclamav/metadata.xml index b8bdd9e16a4e..acde2989538a 100644 --- a/net-proxy/squidclamav/metadata.xml +++ b/net-proxy/squidclamav/metadata.xml @@ -1,7 +1,16 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> <pkgmetadata> -<herd>net-proxy</herd> -<longdescription>SquidClamAV is a Squid redirector which allows easy antivirus file scanning. -It can use either a local or a remote ClamAV daemon.</longdescription> + <maintainer> + <email>flameeyes@gentoo.org</email> + <description>Co-maintainer, not trying to call for exclusive</description> + </maintainer> + <herd>net-proxy</herd> + + <longdescription> + SquidClamAV is a <pkg>net-proxy/squid</pkg> redirector which allows easy antivirus file + scanning. It can use either a local or a remote ClamAV daemon. As + of version 6.0, it is now an ICAP module for + <pkg>net-proxy/c-icap</pkg>. + </longdescription> </pkgmetadata> diff --git a/net-proxy/squidclamav/squidclamav-6.1.ebuild b/net-proxy/squidclamav/squidclamav-6.1.ebuild new file mode 100644 index 000000000000..58347b9824fd --- /dev/null +++ b/net-proxy/squidclamav/squidclamav-6.1.ebuild @@ -0,0 +1,59 @@ +# Copyright 1999-2010 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/squidclamav/squidclamav-6.1.ebuild,v 1.1 2010/11/22 15:46:03 flameeyes Exp $ + +EAPI=2 + +inherit eutils + +DESCRIPTION="HTTP Antivirus for Squid based on ClamAv and ICAP" +HOMEPAGE="http://squidclamav.darold.net/" +SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64" +IUSE="" + +RDEPEND="net-proxy/c-icap" +DEPEND="${RDEPEND}" + +src_prepare() { + epatch "${FILESDIR}/${P}-crash.patch" +} + +src_install() { + emake DESTDIR="${D}" install || die + find "${D}" -name '*.la' -delete || die + + # delete its own documentation installed + rm -r "${D}"/usr/share/${PN} || die + + dodoc README AUTHORS ChangeLog || die + + # Fix configuration file to adapt to the Gentoo configuration + sed -i \ + -e '/clamd_local/s:/tmp/clamd:/var/run/clamav/clamd.sock:' \ + "${D}"/etc/squidclamav.conf || die +} + +pkg_postinst() { + elog "Starting from version 6, Squid Clamav is now a module for the c-icap" + elog "server, which is called from squid, rather than being a redirector" + elog "directly." + elog "" + elog "To enable the service, you should add this to your c-icap.conf file:" + elog "" + elog " Service clamav squidclamav.so" + elog "" + elog "And then this to squid.conf (for a local ICAP server):" + elog "" + elog " icap_enable on" + elog "" + elog " # not strictly needed, but useful for special access" + elog " icap_send_client_ip on" + elog " icap_send_client_username on" + elog "" + elog " icap_service clamav respmod_precache bypass=0 icap://localhost:1344/clamav" + elog " adaptation_access clamav allow all" +} |