summaryrefslogtreecommitdiff
path: root/net-firewall/ipkungfu
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-firewall/ipkungfu
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.xz
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-firewall/ipkungfu')
-rw-r--r--net-firewall/ipkungfu/Manifest2
-rw-r--r--net-firewall/ipkungfu/files/ipkungfu.init20
-rw-r--r--net-firewall/ipkungfu/files/ipkungfu_noiseless.patch24
-rw-r--r--net-firewall/ipkungfu/files/nat_ftp.patch11
-rw-r--r--net-firewall/ipkungfu/ipkungfu-0.5.2-r1.ebuild58
-rw-r--r--net-firewall/ipkungfu/ipkungfu-0.6.1.ebuild48
-rw-r--r--net-firewall/ipkungfu/metadata.xml11
7 files changed, 174 insertions, 0 deletions
diff --git a/net-firewall/ipkungfu/Manifest b/net-firewall/ipkungfu/Manifest
new file mode 100644
index 00000000000..070635b8984
--- /dev/null
+++ b/net-firewall/ipkungfu/Manifest
@@ -0,0 +1,2 @@
+DIST ipkungfu-0.5.2.tgz 35985 RMD160 c60c0fd1361b4306c1a3d310b1430e71ef937982 SHA1 6d749633bb6d6d4a3284a9a350c7ea9c61c28acf SHA256 6543815384f1935631121fba833b5988ca6e88ff19646a561d0315b29f2f5ef8
+DIST ipkungfu-0.6.1.tar.bz2 104516 RMD160 5137ca4ffdd8ab8188fbd42a60da87a6c5149610 SHA1 ef57bbe666f8c946b99c3970ddc7f38c615b6efc SHA256 a1b19c588ecc9584c37e7578c869842f9ceb97b5fd8320abe5b4bd98c136fa76
diff --git a/net-firewall/ipkungfu/files/ipkungfu.init b/net-firewall/ipkungfu/files/ipkungfu.init
new file mode 100644
index 00000000000..29f54420dc2
--- /dev/null
+++ b/net-firewall/ipkungfu/files/ipkungfu.init
@@ -0,0 +1,20 @@
+#!/sbin/runscript
+# Copyright 1999-2004 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+depend() {
+ need logger net
+}
+
+start () {
+ ebegin "Starting ipkungfu"
+ /usr/sbin/ipkungfu --init
+ eend $? "Failed to start ipkungfu"
+}
+
+stop() {
+ ebegin "Stopping ipkungfu"
+ /usr/sbin/ipkungfu --disable > /dev/null
+ eend $? "Failed to stop ipkungfu"
+}
diff --git a/net-firewall/ipkungfu/files/ipkungfu_noiseless.patch b/net-firewall/ipkungfu/files/ipkungfu_noiseless.patch
new file mode 100644
index 00000000000..eed657f2dad
--- /dev/null
+++ b/net-firewall/ipkungfu/files/ipkungfu_noiseless.patch
@@ -0,0 +1,24 @@
+diff -ru ipkungfu-0.6.1.orig/ipkungfu.in ipkungfu-0.6.1/ipkungfu.in
+--- ipkungfu-0.6.1.orig/ipkungfu.in 2007-01-22 04:47:04.000000000 +0100
++++ ipkungfu-0.6.1/ipkungfu.in 2007-07-04 12:49:23.000000000 +0200
+@@ -753,11 +753,15 @@
+ fi
+
+ function delTestChain {
+-# {{{ Flush and delete test chains
+- $IPTABLES -t filter -F SYSTEST
+- $IPTABLES -t filter -X SYSTEST
+- $IPTABLES -t mangle -F SYSTEST
+- $IPTABLES -t mangle -X SYSTEST
++# {{{ Flush and delete test chains, if exist
++ if $IPTABLES -t filter -L SYSTEST > /dev/null 2>&1 ; then
++ $IPTABLES -t filter -F SYSTEST
++ $IPTABLES -t filter -X SYSTEST
++ fi
++ if $IPTABLES -t mangle -L SYSTEST > /dev/null 2>&1 ; then
++ $IPTABLES -t mangle -F SYSTEST
++ $IPTABLES -t mangle -X SYSTEST
++ fi
+ # }}}
+ }
+
diff --git a/net-firewall/ipkungfu/files/nat_ftp.patch b/net-firewall/ipkungfu/files/nat_ftp.patch
new file mode 100644
index 00000000000..db919c5565e
--- /dev/null
+++ b/net-firewall/ipkungfu/files/nat_ftp.patch
@@ -0,0 +1,11 @@
+--- ipkungfu 2003-10-03 13:05:59.000000000 -0400
++++ ipkungfu 2004-02-09 16:34:37.000000000 -0500
+@@ -138,7 +138,7 @@
+ if [ $INIT != 1 ] ; then
+ echo "Loading FTP NAT module..."
+ fi
+- $MODPROBE ip_nat_irc
++ $MODPROBE ip_nat_ftp
+ fi
+ fi
+ }
diff --git a/net-firewall/ipkungfu/ipkungfu-0.5.2-r1.ebuild b/net-firewall/ipkungfu/ipkungfu-0.5.2-r1.ebuild
new file mode 100644
index 00000000000..3b084543a63
--- /dev/null
+++ b/net-firewall/ipkungfu/ipkungfu-0.5.2-r1.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils
+
+DESCRIPTION="A nice iptables firewall script"
+HOMEPAGE="http://www.linuxkungfu.org/"
+SRC_URI="http://www.linuxkungfu.org/ipkungfu/${P}.tgz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc x86"
+IUSE=""
+
+DEPEND="net-firewall/iptables"
+RDEPEND="${DEPEND}
+ virtual/logger"
+
+src_unpack() {
+ unpack ${A}
+
+ # Patch ipkungfu to load the right module for ip_nat_ftp
+ # Fixes bug #42443. Thanks to George L. Emigh <george@georgelemigh.com>
+ cd "${WORKDIR}"/${P} && epatch "${FILESDIR}"/nat_ftp.patch
+
+ # man page comes bzip2'd, so bunzip2 it.
+ cd "${WORKDIR}"/${P}/files
+ bunzip2 ipkungfu.8.bz2
+}
+
+src_install() {
+
+ # Package comes with a hard coded shell script, so here we
+ # replicate what they did, but so it's compatible with portage.
+
+ # Install shell script executable
+ dosbin ipkungfu
+
+ # Install Gentoo init script
+ newinitd "${FILESDIR}"/ipkungfu.init ipkungfu
+
+ # Install config files into /etc
+ dodir /etc/ipkungfu
+ insinto /etc/ipkungfu
+ doins files/*.conf
+
+ # Install man page
+ doman files/ipkungfu.8
+
+ # Install documentation
+ dodoc COPYRIGHT Changelog FAQ INSTALL README gpl.txt
+}
+
+pkg_postinst() {
+ einfo "Be sure to edit the config files"
+ einfo "in /etc/ipkungfu before running"
+}
diff --git a/net-firewall/ipkungfu/ipkungfu-0.6.1.ebuild b/net-firewall/ipkungfu/ipkungfu-0.6.1.ebuild
new file mode 100644
index 00000000000..360fec9dd4c
--- /dev/null
+++ b/net-firewall/ipkungfu/ipkungfu-0.6.1.ebuild
@@ -0,0 +1,48 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+inherit eutils
+
+DESCRIPTION="A nice iptables firewall script"
+HOMEPAGE="http://www.linuxkungfu.org/"
+SRC_URI="http://www.linuxkungfu.org/ipkungfu/${P}.tar.bz2"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE=""
+
+DEPEND="net-firewall/iptables"
+RDEPEND="${DEPEND}
+ virtual/logger"
+
+src_compile() {
+ epatch "${FILESDIR}/ipkungfu_noiseless.patch" || die "Could not apply ipkungfu_noiseless.patch patch"
+ econf || die "Could not run econf"
+ emake || die "Couldn't run make"
+}
+
+src_install() {
+ make DESTDIR="${D}" install || die
+
+ # Install configuration files
+ make DESTDIR="${D}" install-config || die
+
+ # Install Gentoo init script
+ newinitd "${FILESDIR}"/ipkungfu.init ipkungfu
+}
+
+pkg_postinst() {
+ # Remove the cache dir so ipkungfu won't fail when running for
+ # the first time, case 0.6.0 was installed before.
+ rm -rf /etc/ipkungfu/cache
+
+ einfo "Be sure to, before running ipkungfu, edit the config files in:"
+ einfo "/etc/ipkungfu/"
+ echo
+ einfo "Also, be sure to run ipkungfu prior to rebooting,"
+ einfo "especially if you you're updating from <0.6.0 to >=0.6.0."
+ einfo "There are some significant configuration changes on this"
+ einfo "release covered by the ipkungfu script."
+}
diff --git a/net-firewall/ipkungfu/metadata.xml b/net-firewall/ipkungfu/metadata.xml
new file mode 100644
index 00000000000..1b0f1b3c4cd
--- /dev/null
+++ b/net-firewall/ipkungfu/metadata.xml
@@ -0,0 +1,11 @@
+<?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>
+ <name>Default assignee for orphaned packages</name>
+ </maintainer>
+ <longdescription lang="en">
+ ipkungfu is a nice iptables firewall script
+ </longdescription>
+</pkgmetadata>