diff options
author | Tom Wijsman <tomwij@gentoo.org> | 2013-10-08 20:04:09 +0000 |
---|---|---|
committer | Tom Wijsman <tomwij@gentoo.org> | 2013-10-08 20:04:09 +0000 |
commit | dfd6ffe0e58d8883094a04486d5a6e2c3ba6e6e6 (patch) | |
tree | a8a479cd998bfa055df4e29ee21e3c396eb717c4 /net-proxy | |
parent | Revision bump: EAPI 5 and added new configure option (diff) | |
download | gentoo-2-dfd6ffe0e58d8883094a04486d5a6e2c3ba6e6e6.tar.gz gentoo-2-dfd6ffe0e58d8883094a04486d5a6e2c3ba6e6e6.tar.bz2 gentoo-2-dfd6ffe0e58d8883094a04486d5a6e2c3ba6e6e6.zip |
Version bump to 0.2.6, patch DoS due to patching bug for security bug #455324; removal of forced openrc dependency.
(Portage version: HEAD/cvs/Linux x86_64, signed Manifest commit with key 6D34E57D)
Diffstat (limited to 'net-proxy')
-rw-r--r-- | net-proxy/c-icap/ChangeLog | 9 | ||||
-rw-r--r-- | net-proxy/c-icap/c-icap-0.2.6.ebuild | 113 | ||||
-rw-r--r-- | net-proxy/c-icap/files/c-icap-0.2.6-fix-icap-parsing.patch | 11 |
3 files changed, 132 insertions, 1 deletions
diff --git a/net-proxy/c-icap/ChangeLog b/net-proxy/c-icap/ChangeLog index 42ecc5862069..777c34c52685 100644 --- a/net-proxy/c-icap/ChangeLog +++ b/net-proxy/c-icap/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for net-proxy/c-icap # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-proxy/c-icap/ChangeLog,v 1.24 2013/01/04 13:53:38 flameeyes Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-proxy/c-icap/ChangeLog,v 1.25 2013/10/08 20:04:08 tomwij Exp $ + +*c-icap-0.2.6 (08 Oct 2013) + + 08 Oct 2013; Tom Wijsman <TomWij@gentoo.org> +c-icap-0.2.6.ebuild, + +files/c-icap-0.2.6-fix-icap-parsing.patch: + Version bump to 0.2.6, patch DoS due to patching bug for security bug #455324; + removal of forced openrc dependency. *c-icap-0.2.5 (04 Jan 2013) diff --git a/net-proxy/c-icap/c-icap-0.2.6.ebuild b/net-proxy/c-icap/c-icap-0.2.6.ebuild new file mode 100644 index 000000000000..940057295921 --- /dev/null +++ b/net-proxy/c-icap/c-icap-0.2.6.ebuild @@ -0,0 +1,113 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/c-icap/c-icap-0.2.6.ebuild,v 1.1 2013/10/08 20:04:08 tomwij Exp $ + +EAPI="5" + +inherit eutils multilib flag-o-matic + +MY_PN="${PN/-/_}" +MY_P="${MY_PN}-${PV}" + +DESCRIPTION="C Implementation of an ICAP server" +HOMEPAGE="http://c-icap.sourceforge.net/" +SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz" + +LICENSE="LGPL-2.1" +SLOT="0" +KEYWORDS="~amd64 ~arm ~x86" +IUSE="berkdb ipv6 ldap" + +RDEPEND="berkdb? ( sys-libs/db ) + ldap? ( net-nds/openldap ) + sys-libs/zlib" + +DEPEND="${RDEPEND}" +RDEPEND="${RDEPEND}" + +S="${WORKDIR}/${MY_P}" + +src_prepare() { + epatch "${FILESDIR}"/c-icap-0.2.6-fix-icap-parsing.patch +} + +src_configure() { + # some void *** pointers get casted around and can be troublesome to + # fix properly. + append-flags -fno-strict-aliasing + + econf \ + --sysconfdir=/etc/${PN} \ + --disable-dependency-tracking \ + --disable-maintainer-mode \ + --disable-static \ + --enable-large-files \ + $(use_enable ipv6) \ + $(use_with berkdb bdb) \ + $(use_with ldap) +} + +src_compile() { + emake LOGDIR="/var/log" +} + +src_install() { + emake \ + LOGDIR="/var/log" \ + DESTDIR="${D}" install + + find "${D}" -name '*.la' -delete || die + + # Move the daemon out of the way + dodir /usr/libexec + mv "${D}"/usr/bin/c-icap "${D}"/usr/libexec || die + + # Remove the default configuration files since we have etc-update to + # take care of it for us. + rm "${D}"/etc/${PN}/c-icap.*.default || die + + # Fix the configuration file; for some reason it's a bit messy + # around. + sed -i \ + -e 's:/usr/var/:/var/:g' \ + -e 's:/var/log/:/var/log/c-icap/:g' \ + -e 's:/usr/etc/:/etc/c-icap/:g' \ + -e 's:/usr/local/c-icap/etc/:/etc/c-icap/:g' \ + -e 's:/usr/lib/:/usr/'$(get_libdir)'/:g' \ + "${D}"/etc/${PN}/c-icap.conf \ + || die + + dodoc AUTHORS README TODO ChangeLog + + newinitd "${FILESDIR}/${PN}.init.3" ${PN} + newconfd "${FILESDIR}/${PN}.conf" ${PN} + keepdir /var/log/c-icap + + insopts -m0644 + insinto /etc/logrotate.d + newins "${FILESDIR}"/${PN}.logrotate ${PN} + + # avoid triggering portage's symlink protection; this is handled by + # the init script anyway. + rm -rf "${D}"/var/run +} + +pkg_postinst() { + elog "To enable Squid to call the ICAP modules from a local server you should set" + elog "the following in your squid.conf:" + elog "" + elog " icap_enable on" + elog "" + elog " # not strictly needed, but some modules might make use of these" + elog " icap_send_client_ip on" + elog " icap_send_client_username on" + elog "" + elog " icap_service service_req reqmod_precache bypass=1 icap://localhost:1344/service" + elog " adaptation_access service_req allow all" + elog "" + elog " icap_service service_resp respmod_precache bypass=0 icap://localhost:1344/service" + elog " adaptation_access service_resp allow all" + elog "" + elog "You obviously will have to replace \"service\" with the actual ICAP service to" + elog "use." +} diff --git a/net-proxy/c-icap/files/c-icap-0.2.6-fix-icap-parsing.patch b/net-proxy/c-icap/files/c-icap-0.2.6-fix-icap-parsing.patch new file mode 100644 index 000000000000..b0275edefee5 --- /dev/null +++ b/net-proxy/c-icap/files/c-icap-0.2.6-fix-icap-parsing.patch @@ -0,0 +1,11 @@ +--- c-icap-0.2.2.orig/request.c 2013-02-03 16:37:43.000000000 +0000 ++++ c-icap-02.2/request.c 2012-06-19 12:55:51.000000000 +0000 +@@ -267,7 +267,7 @@ + req->req_server[servnamelen] = '\0'; + if (*end == '/') { /*service */ + start = ++end; +- while (*end != ' ' && *end != '?') ++ while (*end && *end != ' ' && *end != '?') + end++; + len = end - start; + if (len > 0) { |