summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /net-proxy/havp
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'net-proxy/havp')
-rw-r--r--net-proxy/havp/Manifest1
-rw-r--r--net-proxy/havp/files/havp-0.92a-r1-pkg-config-libclamav.patch66
-rw-r--r--net-proxy/havp/files/havp-0.92a-run.patch51
-rw-r--r--net-proxy/havp/files/havp.initd59
-rw-r--r--net-proxy/havp/havp-0.92a-r1.ebuild74
-rw-r--r--net-proxy/havp/metadata.xml7
6 files changed, 258 insertions, 0 deletions
diff --git a/net-proxy/havp/Manifest b/net-proxy/havp/Manifest
new file mode 100644
index 000000000000..124bf361223d
--- /dev/null
+++ b/net-proxy/havp/Manifest
@@ -0,0 +1 @@
+DIST havp-0.92a.tar.gz 121987 SHA256 0dec86390b5738184aa7155af0c66dd00a97476fcd7377bcec8f1f0bf50f0e9a SHA512 3eb742519795a7d10520bdc1c78af0d3bf580a56e14f90bff9f519607a4e82cbf704372bd6da2fc05fcd436d580f4c226874d8df7770d22e2160b5d01afb9c62 WHIRLPOOL 9459d3bab10ed5a6b9053b72795f1e3729765665804fd01f5bae64170510a4427212357ff987cfbb4e93c9770702bb23d18d37dbfdfbc37958f16ff6890178f2
diff --git a/net-proxy/havp/files/havp-0.92a-r1-pkg-config-libclamav.patch b/net-proxy/havp/files/havp-0.92a-r1-pkg-config-libclamav.patch
new file mode 100644
index 000000000000..ea761f7e3476
--- /dev/null
+++ b/net-proxy/havp/files/havp-0.92a-r1-pkg-config-libclamav.patch
@@ -0,0 +1,66 @@
+--- a/configure.in
++++ b/configure.in
+@@ -5,6 +5,7 @@
+ unset CDPATH
+
+ AC_PROG_CXX
++PKG_PROG_PKG_CONFIG
+
+ AC_PREFIX_DEFAULT(/usr/local)
+
+@@ -83,48 +84,15 @@
+ AC_DEFINE(SSLTUNNEL)
+ fi
+
+-AC_MSG_CHECKING(for ClamAV scanner library)
+-
+ if test "$enable_clamav" = "yes"
+ then
+- clamprefix="`clamav-config --prefix 2>/dev/null`"
+- clamversion="`clamav-config --version 2>/dev/null`"
+-
+- if test "x$clamprefix" = "x"
+- then
+- AC_MSG_RESULT([clamav-config not found])
+-
+- echo ""
+- echo " Error finding ClamAV installation!"
+- echo " Add ClamAV binaries path to PATH and run configure again."
+- echo ""
+- echo " To disable ClamAV library support, use --disable-clamav."
+- echo ""
+-
+- exit 1
+- fi
+-
+- for cl in `clamav-config --cflags 2>/dev/null`; do
+- if test "x`echo $cl | perl -ne 'print if (/^-I/)' 2>/dev/null`" != "x"
+- then
+- CFLAGS="$CFLAGS $cl"
+- fi
+- done
+-
+- for cl in `clamav-config --libs 2>/dev/null`; do
+- if test "x`echo $cl | perl -ne 'print if (/(^-L|thread|c_r)/)' 2>/dev/null`" != "x"
+- then
+- LDFLAGS="$LDFLAGS $cl"
+- fi
+- done
+- LDFLAGS="$LDFLAGS -lclamav"
+-
+- SCANNEROBJECTS="clamlibscanner.o"
+- AC_DEFINE(USECLAMLIB)
+-
+- AC_MSG_RESULT([found $clamversion in $clamprefix])
+-else
+- AC_MSG_RESULT([disabled :-(])
++ PKG_CHECK_MODULES(clamav, libclamav,
++ [CFLAGS="$clamav_CFLAGS $CFLAGS"
++ LDFLAGS="$clamav_LIBS $LDFLAGS"
++
++ SCANNEROBJECTS="clamlibscanner.o"
++ AC_DEFINE(USECLAMLIB)
++ ])
+ fi
+
+ AC_MSG_CHECKING(for Trend Micro scanner)
diff --git a/net-proxy/havp/files/havp-0.92a-run.patch b/net-proxy/havp/files/havp-0.92a-run.patch
new file mode 100644
index 000000000000..d13761bee86d
--- /dev/null
+++ b/net-proxy/havp/files/havp-0.92a-run.patch
@@ -0,0 +1,51 @@
+--- a/etc/havp/havp.config.in
++++ b/etc/havp/havp.config.in
+@@ -39,7 +39,7 @@
+ # /etc/init.d/havp script requires this to work.
+ #
+ # Default:
+-# PIDFILE @localstatedir@/run/havp/havp.pid
++# PIDFILE /run/havp/havp.pid
+
+ #
+ # For performance reasons several instances of HAVP have to run.
+@@ -539,7 +539,7 @@
+ # Path to aveserver socket
+ #
+ # Default:
+-# AVESOCKET /var/run/aveserver
++# AVESOCKET /run/aveserver
+
+
+ #####
+@@ -551,7 +551,7 @@
+ # Path to sophie socket
+ #
+ # Default:
+-# SOPHIESOCKET /var/run/sophie
++# SOPHIESOCKET /run/sophie
+
+
+ #####
+@@ -600,7 +600,7 @@
+ # Path to avastd socket
+ #
+ # Default:
+-# AVASTSOCKET /var/run/avast4/local.sock
++# AVASTSOCKET /run/avast4/local.sock
+
+ # ..OR if you use avastd TCP socket, uncomment to enable use
+ #
+@@ -619,10 +619,10 @@
+
+ # Path to arcavird socket
+ #
+-# For version 2008, default socket is /var/run/arcad.ctl
++# For version 2008, default socket is /run/arcad.ctl
+ #
+ # Default:
+-# ARCAVIRSOCKET /var/run/arcavird.socket
++# ARCAVIRSOCKET /run/arcavird.socket
+
+ # Used Arcavir version
+ # 2007 = Version 2007 and earlier
diff --git a/net-proxy/havp/files/havp.initd b/net-proxy/havp/files/havp.initd
new file mode 100644
index 000000000000..44b00fcd0fbe
--- /dev/null
+++ b/net-proxy/havp/files/havp.initd
@@ -0,0 +1,59 @@
+#!/sbin/runscript
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+depend() {
+ need net
+ use clamd \
+ squid apache2 bfilter mman junkbuster oops polipo privoxy tinyproxy wwwoffled
+ #havp could be used in conjuction with any parent proxies enumerated above
+}
+
+get_havp_opt() {
+ eval HAVP_$1=`awk '/^[ \t]*'$1'[ \t]+/ { print $2; }' < /etc/havp/havp.config`
+}
+
+checkconfig() {
+ if [ ! -f /etc/havp/havp.config ] ; then
+ eerror "No /etc/havp/havp.config file exists!"
+ return 1
+ fi
+
+ local HAVP_USER
+ get_havp_opt USER
+ if [ -n "${HAVP_USER}" ] && ! getent passwd ${HAVP_USER} > /dev/null ; then
+ eerror "${HAVP_USER} user is missing!"
+ return 1
+ fi
+ local HAVP_GROUP
+ get_havp_opt GROUP
+ if [ -n "${HAVP_GROUP}" ] && ! getent group ${HAVP_GROUP} > /dev/null ; then
+ eerror "${HAVP_GROUP} group is missing!"
+ return 1
+ fi
+}
+
+
+start() {
+ checkconfig || return 1
+
+ checkpath --directory \
+ --owner "${HAVP_USER:-havp}:${HAVP_GROUP:-havp}" --mode 0755 /run/havp
+ checkpath --directory \
+ --owner "${HAVP_USER:-havp}:${HAVP_GROUP:-havp}" --mode 0700 /var/log/havp
+ checkpath --directory \
+ --owner "${HAVP_USER:-havp}:${HAVP_GROUP:-havp}" --mode 0750 /var/tmp/havp
+
+ ebegin "Starting HTTP AntiVirus Proxy"
+ start-stop-daemon --start --exec /usr/sbin/havp > /dev/null
+ eend $?
+}
+
+stop() {
+ local HAVP_PIDFILE
+ get_havp_opt PIDFILE
+
+ ebegin "Stopping HTTP AntiVirus Proxy"
+ start-stop-daemon --stop --pidfile=${HAVD_PIDFILE:-/var/run/havp/havp.pid}
+ eend $?
+}
diff --git a/net-proxy/havp/havp-0.92a-r1.ebuild b/net-proxy/havp/havp-0.92a-r1.ebuild
new file mode 100644
index 000000000000..8f5a0177c05b
--- /dev/null
+++ b/net-proxy/havp/havp-0.92a-r1.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+inherit autotools eutils toolchain-funcs user
+
+DESCRIPTION="HTTP AntiVirus Proxy"
+HOMEPAGE="http://www.server-side.de/"
+SRC_URI="http://www.server-side.de/download/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 x86"
+IUSE="clamav ssl"
+
+DEPEND="clamav? ( >=app-antivirus/clamav-0.98.5 )"
+RDEPEND="${DEPEND}"
+
+pkg_setup() {
+ enewgroup ${PN}
+ enewuser ${PN} -1 -1 /etc/${PN} ${PN}
+}
+
+src_prepare() {
+ epatch \
+ "${FILESDIR}"/${PN}-0.92a-run.patch \
+ "${FILESDIR}"/${PF}-pkg-config-libclamav.patch
+ sed -i configure.in -e '/^CFLAGS=/d' || die
+ mv configure.{in,ac} || die
+ eautoreconf
+}
+
+src_configure() {
+ tc-export AR
+ export CFLAGS="${CXXFLAGS}"
+ econf \
+ $(use_enable clamav) \
+ $(use_enable ssl ssl-tunnel) \
+ --localstatedir=/var
+}
+
+src_install() {
+ dosbin ${PN}/${PN}
+
+ newinitd "${FILESDIR}/${PN}.initd" ${PN}
+
+ insinto /etc
+ rm -r etc/${PN}/${PN}.config.in
+ doins -r etc/${PN}
+
+ dodoc ChangeLog
+}
+
+pkg_postinst() {
+ ewarn "/var/tmp/${PN} must be on a filesystem with mandatory locks!"
+ ewarn "You should add \"mand\" to the mount options on the relevant line in /etc/fstab."
+
+ if use ssl; then
+ echo
+ ewarn "Note: ssl USE flag only enable SSL pass-through, which means that"
+ ewarn " HTTPS pages will not be scanned for viruses!"
+ ewarn " It is impossible to decrypt data sent through SSL connections without knowing"
+ ewarn " the private key of the used certificate."
+ fi
+
+ if use clamav; then
+ echo
+ ewarn "If you plan to use clamav daemon, you should make sure clamav user can read"
+ ewarn "/var/tmp/${PN} content. This can be accomplished by enabling AllowSupplementaryGroups"
+ ewarn "in /etc/clamd.conf and adding clamav user to the ${PN} group."
+ fi
+}
diff --git a/net-proxy/havp/metadata.xml b/net-proxy/havp/metadata.xml
new file mode 100644
index 000000000000..547d2588d36c
--- /dev/null
+++ b/net-proxy/havp/metadata.xml
@@ -0,0 +1,7 @@
+<?xml version = '1.0' encoding = 'UTF-8'?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer><email>maintainer-needed@gentoo.org</email></maintainer>
+<longdescription>HAVP (HTTP AntiVirus proxy) is a proxy with an anti-virus
+filter. It does not cache or filter content.</longdescription>
+</pkgmetadata>