From: Jose Alberto Suarez Lopez Date: Tue, 24 Apr 2007 13:49:40 +0000 (+0000) Subject: First commit X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=acad42918fd36b9d6e8bedf9f71674314ae64b04;p=gentoo.git First commit Package-Manager: portage-2.1.2.2 --- diff --git a/net-proxy/ufdbguard/ChangeLog b/net-proxy/ufdbguard/ChangeLog new file mode 100644 index 000000000000..557d8b88768e --- /dev/null +++ b/net-proxy/ufdbguard/ChangeLog @@ -0,0 +1,8 @@ +# ChangeLog for net-proxy/ufdbguard +# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/ufdbguard/ChangeLog,v 1.1 2007/04/24 13:49:40 bass Exp $ + +*ufdbguard-1.11 (24 Apr 2007) + + 24 Apr 2007; J.Alberto Suárez López : + Initial import. diff --git a/net-proxy/ufdbguard/files/digest-ufdbguard-1.11 b/net-proxy/ufdbguard/files/digest-ufdbguard-1.11 new file mode 100644 index 000000000000..07347c58eef3 --- /dev/null +++ b/net-proxy/ufdbguard/files/digest-ufdbguard-1.11 @@ -0,0 +1,3 @@ +MD5 4c5face3013045de88c570ae2665dc1f ufdbGuard-1.11.tar.gz 586455 +RMD160 bf5386f65283a41de2263566b812f0f20c22a9fe ufdbGuard-1.11.tar.gz 586455 +SHA256 5ce227a5cc23c2f6b6f5ccac3e59711386feaa751ff56a922890e4cb240528f3 ufdbGuard-1.11.tar.gz 586455 diff --git a/net-proxy/ufdbguard/files/ufdbguard.confd b/net-proxy/ufdbguard/files/ufdbguard.confd new file mode 100644 index 000000000000..c80752dc0349 --- /dev/null +++ b/net-proxy/ufdbguard/files/ufdbguard.confd @@ -0,0 +1,9 @@ +UFDB_OPTS="" +UFDB_GT="alwaysallow alwaysdeny" + +UFDB_CONFDIR="/etc/ufdbguard" +UFDB_CONF="${UFDB_CONFDIR}/ufdbGuard.conf" +UFDB_PIDFILE="/var/run/ufdbguardd.pid" +UFDB_BINARY="/usr/bin/ufdbguardd" + +UFDB_LOGDIR=$( grep logdir ${UFDB_CONF} 2>/dev/null | awk '{print $2}' ) UFDB_USER="squid" diff --git a/net-proxy/ufdbguard/files/ufdbguard.initd b/net-proxy/ufdbguard/files/ufdbguard.initd new file mode 100644 index 000000000000..f704dbd5309a --- /dev/null +++ b/net-proxy/ufdbguard/files/ufdbguard.initd @@ -0,0 +1,43 @@ +#!/sbin/runscript +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/ufdbguard/files/ufdbguard.initd,v 1.3 2007/04/24 13:49:40 bass Exp $ + +depend() { + need net + before squid + use logger +} + +ufgt() { + if [ -f "/etc/ufdbguard/blacklists/${1}/domains" ] ; then + einfo "Generating domainlist $1" + /usr/bin/ufdbGenTable -t ${1} -d ${UFDB_CONFDIR}/blacklists/${1}/domains + fi +} + +start() { + + if [ -n "${UFDB_GT}" ] ; then + for gt in ${UFDB_GT} ; do + ufgt ${gt} + done + fi + + if [ ! -d "${UFDB_LOGDIR}" ] ; then + mkdir -p ${UFDB_LOGDIR} + chown -R ${UFDB_USER} ${UFDB_LOGDIR} + fi + + ebegin "Starting ufdbGuard" + start-stop-daemon --start --chuid ${UFDB_USER} \ + --exec ${UFDB_BINARY} --pidfile ${UFDB_PIDFILE} -- -c ${UFDB_CONF} \ + ${UFDB_OPTS} + eend $? "Failed to start ufdbguard" +} + +stop() { + ebegin "Stopping ufdbguard" + start-stop-daemon --stop --exec ${UFDB_BINARY} --pidfile ${UFDB_PIDFILE} + eend $? "Failed to stop ufdbguard" +} diff --git a/net-proxy/ufdbguard/metadata.xml b/net-proxy/ufdbguard/metadata.xml new file mode 100644 index 000000000000..2c5bd1d92d46 --- /dev/null +++ b/net-proxy/ufdbguard/metadata.xml @@ -0,0 +1,12 @@ + + + + no-herd + + bass@gentoo.org + + + + The fastest URL filter with 25,000 URL verifications/sec to filter unwanted web content. ufdbGuard is a redirector for the Squid internet proxy. + + diff --git a/net-proxy/ufdbguard/ufdbguard-1.11.ebuild b/net-proxy/ufdbguard/ufdbguard-1.11.ebuild new file mode 100644 index 000000000000..613e9c651faa --- /dev/null +++ b/net-proxy/ufdbguard/ufdbguard-1.11.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-proxy/ufdbguard/ufdbguard-1.11.ebuild,v 1.1 2007/04/24 13:49:40 bass Exp $ + +inherit eutils +DESCRIPTION="ufdbGuard is a redirector for the Squid internet proxy." +HOMEPAGE="http://ufdbguard.sf.net" +SRC_URI="mirror://sourceforge/ufdbguard/ufdbGuard-${PV}.tar.gz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86" + +DEPEND="dev-libs/openssl + app-arch/bzip2 + dev-util/yacc + sys-devel/flex" +RDEPEND="${DEPEND} + net-misc/wget + net-proxy/squid" + +S="${WORKDIR}/ufdbGuard-${PV}" + +src_compile() { + ./configure \ + --host=${CHOST} \ + --prefix=/usr \ + --with-ufdb-config=/etc/ufdbguard \ + --with-ufdb-logdir=/var/log/ufdbguard \ + --with-ufdb-dbhome=/etc/ufdbguard/blacklists \ + --infodir=/usr/share/info \ + --mandir=/usr/share/man || die "./configure failed" + + emake || die "emake failed" +} + +src_install() { + dodoc CHANGELOG INSTALL README README.multithreaded TODO + dodoc doc/*.html doc/*.txt src/UFDB + dohtml doc/*.html + + dobin src/ufdbGenTable src/ufdbGuard src/mtserver/ufdbgclient src/mtserver/ufdbguardd src/ufdbGrab + + dodir /etc/ufdbguard/blacklists + insinto /etc/ufdbguard + doins src/ufdbGuard.conf + + newconfd ${FILESDIR}/ufdbguard.confd ufdbguard + newinitd ${FILESDIR}/ufdbguard.initd ufdbguard +} + +pkg_postinst() { + einfo "Add ufdbguard port to services:" + einfo 'echo "ufdbguardd 3977/tcp" >> /etc/services ' +}