diff options
author | Daniel Black <dragonheart@gentoo.org> | 2006-07-09 06:27:22 +0000 |
---|---|---|
committer | Daniel Black <dragonheart@gentoo.org> | 2006-07-09 06:27:22 +0000 |
commit | 5781ccbb4e495879cd8de8cef4614175092cd017 (patch) | |
tree | e08110a3cb380fb8d6e3750e91f501ce9c8ba31d /net-firewall | |
parent | Marked stable on mips. (diff) | |
download | historical-5781ccbb4e495879cd8de8cef4614175092cd017.tar.gz historical-5781ccbb4e495879cd8de8cef4614175092cd017.tar.bz2 historical-5781ccbb4e495879cd8de8cef4614175092cd017.zip |
separated extensions USE flag into imq and l7filter as promised to vapier/hansmi/wolf31o2(?) (long time ago). Added upstream patch for errnum (bug #139726)
Package-Manager: portage-2.1.1_pre2-r6
Diffstat (limited to 'net-firewall')
-rw-r--r-- | net-firewall/iptables/ChangeLog | 12 | ||||
-rw-r--r-- | net-firewall/iptables/Manifest | 29 | ||||
-rw-r--r-- | net-firewall/iptables/files/1.3.5-files/iptables-1.3.5-errno.patch | 28 | ||||
-rw-r--r-- | net-firewall/iptables/files/digest-iptables-1.3.5-r3 | 9 | ||||
-rw-r--r-- | net-firewall/iptables/iptables-1.3.5-r3.ebuild | 170 |
5 files changed, 237 insertions, 11 deletions
diff --git a/net-firewall/iptables/ChangeLog b/net-firewall/iptables/ChangeLog index 1c328b3b8dad..2163aaf90f3d 100644 --- a/net-firewall/iptables/ChangeLog +++ b/net-firewall/iptables/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for net-firewall/iptables # Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-firewall/iptables/ChangeLog,v 1.104 2006/06/12 17:08:48 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-firewall/iptables/ChangeLog,v 1.105 2006/07/09 06:27:22 dragonheart Exp $ + +*iptables-1.3.5-r3 (09 Jul 2006) + + 09 Jul 2006; Daniel Black <dragonheart@gentoo.org> + +files/1.3.5-files/iptables-1.3.5-errno.patch, +iptables-1.3.5-r3.ebuild: + separated extensions patch as promised to vapier/hansmi/wolf31o2(?). Added + upstream patch for errnum (bug #139726) thanks to Rance Hall and upstream + dev Daniel 12 Jun 2006; Chris Gianelloni <wolf31o2@gentoo.org> iptables-1.3.5-r1.ebuild: @@ -26,7 +34,7 @@ *iptables-1.3.5-r2 (04 Jun 2006) - 04 Jun 2006; Daniel Black <dragonheart@gentoo.org> iptables-1.3.5-r2.ebuild files/digest-iptables-1.3.5-r2: + 04 Jun 2006; Daniel Black <dragonheart@gentoo.org> iptables-1.3.5-r2.ebuild: update l7-filter patch version *iptables-1.3.5-r1 (02 May 2006) diff --git a/net-firewall/iptables/Manifest b/net-firewall/iptables/Manifest index 28110fe566e4..abfd034df9e0 100644 --- a/net-firewall/iptables/Manifest +++ b/net-firewall/iptables/Manifest @@ -45,6 +45,10 @@ AUX 1.3.1-files/iptables-1.3.1-compilefix.patch 358 RMD160 359adb7cc1876e664a69b MD5 d6121c3a118e7a06de577383c1c99fe0 files/1.3.1-files/iptables-1.3.1-compilefix.patch 358 RMD160 359adb7cc1876e664a69bba472fa97155df808ab files/1.3.1-files/iptables-1.3.1-compilefix.patch 358 SHA256 b0e802e86e601f5229a8f1bbbdfbe4c97b13ede4931e5ee2d73f176c7f121e99 files/1.3.1-files/iptables-1.3.1-compilefix.patch 358 +AUX 1.3.5-files/iptables-1.3.5-errno.patch 689 RMD160 67ce38c86fbef574e8f7d2f4ebffbecff35bf59f SHA1 7a45e68e5d332529ab5697886417cff59ef53fe1 SHA256 09eff37038db0fd66cb68f5e84dd93c031445f29e3a50afe18d3d389fe5cded1 +MD5 b27a0ebcd83384e92ee63d64da85af69 files/1.3.5-files/iptables-1.3.5-errno.patch 689 +RMD160 67ce38c86fbef574e8f7d2f4ebffbecff35bf59f files/1.3.5-files/iptables-1.3.5-errno.patch 689 +SHA256 09eff37038db0fd66cb68f5e84dd93c031445f29e3a50afe18d3d389fe5cded1 files/1.3.5-files/iptables-1.3.5-errno.patch 689 AUX ip6tables-1.2.9-r1.confd 266 RMD160 e42235c98c8fec22bad9e8953939d7d0dc64cd1d SHA1 e1fc7e8e9b0963d7ac0bee50dd97ae1ad637eefe SHA256 8434238fad47255691fda04dfff08ab65de44661678d680fab21cc51922a5c68 MD5 dd4f4563c89d33fc6987043d95531e05 files/ip6tables-1.2.9-r1.confd 266 RMD160 e42235c98c8fec22bad9e8953939d7d0dc64cd1d files/ip6tables-1.2.9-r1.confd 266 @@ -73,7 +77,7 @@ AUX iptables-1.3.2.init 2548 RMD160 fef1e2c096171e32eb3e62e79eb7043033153ef6 SHA MD5 be57c10dd117e845d0367ac4abfdc6d2 files/iptables-1.3.2.init 2548 RMD160 fef1e2c096171e32eb3e62e79eb7043033153ef6 files/iptables-1.3.2.init 2548 SHA256 3ededc7a04ed94ac847d438e7980e1d4a53bfac830eb73c9d420b24b76358e44 files/iptables-1.3.2.init 2548 -DIST iptables-1.2.11.tar.bz2 156988 RMD160 66e0fa391444a1e169feaf2fc67b5f8622ec1d89 SHA256 be7bd67232fddbe3ce81f40f5b79123380a2e67cd166ec06e650842f8acb373d +DIST iptables-1.2.11.tar.bz2 156988 RMD160 66e0fa391444a1e169feaf2fc67b5f8622ec1d89 SHA1 1a2236e2705b02834aaa506632c08cf8a647efa2 SHA256 be7bd67232fddbe3ce81f40f5b79123380a2e67cd166ec06e650842f8acb373d DIST iptables-1.3.0-imq1.diff 5369 RMD160 8ca1fa3bfea02d27232d8d8cb0a12586dd4537b5 SHA1 bdf665cacc985fceaadf119ae7a756caca1589ad SHA256 0f9d36e48b3f1e83ef9e1d39c19e7271a889a31c65c396c416200eb143f1795b DIST iptables-1.3.4.tar.bz2 189847 RMD160 3e37965406ae8a39896dead16e5a3722fc9256b4 SHA1 47a779204306dd8499ca73df4c3a5233f23dfaae SHA256 2067ed2134adde5f50716dd1d3752dfb023a634ff274af88eb635e5a1bba1bda DIST iptables-1.3.5.tar.bz2 191820 RMD160 3364e0f37f67ba4aa9ac9caa6f11adb67887e528 SHA1 6dbeeee13517fa02852960b6f6e51115c7548a09 SHA256 1d8ee8634d167b0f1a8872b6547910c11bae676699faf2b4bc2c84a128449c3c @@ -96,14 +100,18 @@ EBUILD iptables-1.3.5-r2.ebuild 5077 RMD160 0d1b6c9178f45d1a5b639ac56fb8367b44ff MD5 d6e50a2e4a031240b4986b8002951922 iptables-1.3.5-r2.ebuild 5077 RMD160 0d1b6c9178f45d1a5b639ac56fb8367b44ff045c iptables-1.3.5-r2.ebuild 5077 SHA256 e474a32b06a9ddd3b7feaa589d069c5191f2f290591cd9d65015ce64917687ec iptables-1.3.5-r2.ebuild 5077 +EBUILD iptables-1.3.5-r3.ebuild 5241 RMD160 5991dc79f8ad2ccaa452df9bc0360ee2c4dd2326 SHA1 8212263500cb66619ba7d27f5838fac219f34c88 SHA256 d5102e65285357386d6635c1ac816320bfc8770ad0f6e1bad9c9dde38089faac +MD5 394593497a454f0f24dcf449aacd07a7 iptables-1.3.5-r3.ebuild 5241 +RMD160 5991dc79f8ad2ccaa452df9bc0360ee2c4dd2326 iptables-1.3.5-r3.ebuild 5241 +SHA256 d5102e65285357386d6635c1ac816320bfc8770ad0f6e1bad9c9dde38089faac iptables-1.3.5-r3.ebuild 5241 EBUILD iptables-1.3.5.ebuild 5064 RMD160 f8e01015e5804862da12168cca8da9bf451dfb14 SHA1 d1b64266e3cadc4932729d10219ba37962abbc54 SHA256 1a37910c39e95ed8efbf2aaf132fc8c6878b61e0cbeb635ca072d9a68193f94e MD5 925412ddd3ef1cda9a5c0016c2268c06 iptables-1.3.5.ebuild 5064 RMD160 f8e01015e5804862da12168cca8da9bf451dfb14 iptables-1.3.5.ebuild 5064 SHA256 1a37910c39e95ed8efbf2aaf132fc8c6878b61e0cbeb635ca072d9a68193f94e iptables-1.3.5.ebuild 5064 -MISC ChangeLog 22454 RMD160 782845868a7e82487897eae0de7589a8a9996790 SHA1 724d3ed9a453909c3486ed75c050ea5738fb909a SHA256 79663aea5feddc8e2a91b90f20b1b2135fb8b4335dd6e0cd41bc2765b4782c51 -MD5 08e251ba22c66e46930b38e2f21de070 ChangeLog 22454 -RMD160 782845868a7e82487897eae0de7589a8a9996790 ChangeLog 22454 -SHA256 79663aea5feddc8e2a91b90f20b1b2135fb8b4335dd6e0cd41bc2765b4782c51 ChangeLog 22454 +MISC ChangeLog 22756 RMD160 20a244972032969fed86e7d4b05365025282167e SHA1 c8c2bfea92d1a4b17a7d4b45609d0f06911d1af7 SHA256 af5ea455f1e876ef5d097d96452d6615851af7b9c37ef85dc0528083714be915 +MD5 66b5e25829455c11e1032071b9756ff8 ChangeLog 22756 +RMD160 20a244972032969fed86e7d4b05365025282167e ChangeLog 22756 +SHA256 af5ea455f1e876ef5d097d96452d6615851af7b9c37ef85dc0528083714be915 ChangeLog 22756 MISC metadata.xml 164 RMD160 f43cbec30b7074319087c9acffdb9354b17b0db3 SHA1 9c213f5803676c56439df3716be07d6692588856 SHA256 f5f2891f2a4791cd31350bb2bb572131ad7235cd0eeb124c9912c187ac10ce92 MD5 9a09f8d531c582e78977dbfd96edc1f2 metadata.xml 164 RMD160 f43cbec30b7074319087c9acffdb9354b17b0db3 metadata.xml 164 @@ -123,10 +131,13 @@ SHA256 91af3410c7dc59b6e89e0ef49860324769521f291bc7299de62392b8232f71e5 files/di MD5 d82cc3133eb927e81ab276517942bda8 files/digest-iptables-1.3.5-r2 756 RMD160 d25e371e2340dab6d400d7b05a185b5dea41ae6d files/digest-iptables-1.3.5-r2 756 SHA256 5526edeb288993a93689f0d39cacd94bc6dbd0f8f41ea3b4e30b1d4790acee72 files/digest-iptables-1.3.5-r2 756 +MD5 d82cc3133eb927e81ab276517942bda8 files/digest-iptables-1.3.5-r3 756 +RMD160 d25e371e2340dab6d400d7b05a185b5dea41ae6d files/digest-iptables-1.3.5-r3 756 +SHA256 5526edeb288993a93689f0d39cacd94bc6dbd0f8f41ea3b4e30b1d4790acee72 files/digest-iptables-1.3.5-r3 756 -----BEGIN PGP SIGNATURE----- -Version: GnuPG v1.4.3 (GNU/Linux) +Version: GnuPG v1.4.4-ecc0.1.6 (GNU/Linux) -iD8DBQFEoL4oamhnQswr0vIRAhhAAJ93rbn6JbLrxGXn29AiPDaSFoLZZACfR7oy -GIpwWFMS98pqt/8H+3tc+rM= -=2pTw +iD8DBQFEsKNLmdTrptrqvGERAsHLAJ9nMXHTcIyv4sihbmj4VE/L0iPDmQCfa39w +Ab/O7NHwimq//P0EPbBKg6M= +=5F37 -----END PGP SIGNATURE----- diff --git a/net-firewall/iptables/files/1.3.5-files/iptables-1.3.5-errno.patch b/net-firewall/iptables/files/1.3.5-files/iptables-1.3.5-errno.patch new file mode 100644 index 000000000000..5897bb1ecb97 --- /dev/null +++ b/net-firewall/iptables/files/1.3.5-files/iptables-1.3.5-errno.patch @@ -0,0 +1,28 @@ +Index: libiptc/libiptc.c +=================================================================== +--- libiptc/libiptc.c (revision 6587) ++++ libiptc/libiptc.c (revision 6588) +@@ -2096,10 +2096,8 @@ + + ret = setsockopt(sockfd, TC_IPPROTO, SO_SET_REPLACE, repl, + sizeof(*repl) + repl->size); +- if (ret < 0) { +- errno = ret; ++ if (ret < 0) + goto out_free_newcounters; +- } + + /* Put counters back. */ + strcpy(newcounters->name, (*handle)->info.name); +@@ -2190,10 +2188,8 @@ + + ret = setsockopt(sockfd, TC_IPPROTO, SO_SET_ADD_COUNTERS, + newcounters, counterlen); +- if (ret < 0) { +- errno = ret; ++ if (ret < 0) + goto out_free_newcounters; +- } + + free(repl->counters); + free(repl); diff --git a/net-firewall/iptables/files/digest-iptables-1.3.5-r3 b/net-firewall/iptables/files/digest-iptables-1.3.5-r3 new file mode 100644 index 000000000000..cb7e3908a25a --- /dev/null +++ b/net-firewall/iptables/files/digest-iptables-1.3.5-r3 @@ -0,0 +1,9 @@ +MD5 9adae8be9562775a176fc1b275b3cb29 iptables-1.3.0-imq1.diff 5369 +RMD160 8ca1fa3bfea02d27232d8d8cb0a12586dd4537b5 iptables-1.3.0-imq1.diff 5369 +SHA256 0f9d36e48b3f1e83ef9e1d39c19e7271a889a31c65c396c416200eb143f1795b iptables-1.3.0-imq1.diff 5369 +MD5 00fb916fa8040ca992a5ace56d905ea5 iptables-1.3.5.tar.bz2 191820 +RMD160 3364e0f37f67ba4aa9ac9caa6f11adb67887e528 iptables-1.3.5.tar.bz2 191820 +SHA256 1d8ee8634d167b0f1a8872b6547910c11bae676699faf2b4bc2c84a128449c3c iptables-1.3.5.tar.bz2 191820 +MD5 b590a0f6fe809f8e1852ee96687644f9 netfilter-layer7-v2.2.tar.gz 88944 +RMD160 cf421e6ef4acf5b9107feacaee6566d55ad21683 netfilter-layer7-v2.2.tar.gz 88944 +SHA256 e82cc356ece2bea3da2bb4b467063a96337ced4bde6127a44f0296245e74d57d netfilter-layer7-v2.2.tar.gz 88944 diff --git a/net-firewall/iptables/iptables-1.3.5-r3.ebuild b/net-firewall/iptables/iptables-1.3.5-r3.ebuild new file mode 100644 index 000000000000..244d6ffd309b --- /dev/null +++ b/net-firewall/iptables/iptables-1.3.5-r3.ebuild @@ -0,0 +1,170 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-firewall/iptables/iptables-1.3.5-r3.ebuild,v 1.1 2006/07/09 06:27:22 dragonheart Exp $ + +inherit eutils flag-o-matic toolchain-funcs linux-info + +L7_PV="2.2" +L7_P="netfilter-layer7-v${L7_PV}" +L7_PATCH="iptables-layer7-${L7_PV}.patch" +IMQ_PATCH="iptables-1.3.0-imq1.diff" + +DESCRIPTION="Linux kernel (2.4+) firewall, NAT and packet mangling tools" +HOMEPAGE="http://www.iptables.org/ http://www.linuximq.net/ http://l7-filter.sf.net/" +SRC_URI="http://iptables.org/projects/iptables/files/${P}.tar.bz2 + imq? ( http://www.linuximq.net/patchs/${IMQ_PATCH} ) + l7filter? ( mirror://sourceforge/l7-filter/${L7_P}.tar.gz )" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" +IUSE="ipv6 static imq l7filter" + +DEPEND="virtual/os-headers + l7filter? ( virtual/linux-sources ) + imq? ( virtual/linux-sources )" +RDEPEND="" + +pkg_setup() { + if use l7filter || use imq; then + ewarn "WARNING: 3rd party extensions has been enabled." + ewarn "This means that iptables will use your currently installed" + ewarn "kernel in ${KERNEL_DIR} as headers for iptables." + ewarn + linux-info_pkg_setup + fi + + if use l7filter && \ + [ ! -f "${KERNEL_DIR}/net/ipv4/netfilter/ipt_layer7.c" ]; then + die "For layer 7 support emerge net-misc/l7-filter-${L7_PV} before this" + fi + if use imq && \ + [ ! -f "${KERNEL_DIR}/net/ipv4/netfilter/ipt_IMQ.c" ]; then + die "For IMQ support add a patch from http://www.linuximq.net/patches.html to your kernel" + fi +} + +src_unpack() { + unpack ${P}.tar.bz2 + use l7filter && unpack ${L7_P}.tar.gz + cd "${S}" + + EPATCH_OPTS="-p0" \ + epatch "${FILESDIR}"/1.3.1-files/install_ipv6_apps.patch + EPATCH_OPTS="-p1" \ + epatch "${FILESDIR}"/1.3.1-files/install_all_dev_files.patch-1.3.1 + + # this provide's grsec's stealth match + EPATCH_OPTS="-p0" \ + epatch "${FILESDIR}"/1.3.1-files/grsecurity-1.2.8-iptables.patch-1.3.1 + sed -i \ + -e "s/PF_EXT_SLIB:=/PF_EXT_SLIB:=stealth /g" \ + extensions/Makefile || die "failed to enable stealth extension" + + EPATCH_OPTS="-p1" \ + epatch "${FILESDIR}"/1.3.1-files/${PN}-1.3.1-compilefix.patch + + # bug #139726 + epatch "${FILESDIR}"/1.3.5-files/${P}-errno.patch + + if use imq ; then + EPATCH_OPTS="-p1" epatch "${DISTDIR}"/${IMQ_PATCH} + chmod +x extensions/{.IMQ-test*,.childlevel-test*} + fi + if use l7filter ; then + EPATCH_OPTS="-p1" epatch "${WORKDIR}"/${L7_P}/${L7_PATCH} + chmod +x extensions/.layer7-test* + fi +} + + +src_defs() { + # these are used in both of src_compile and src_install + myconf="${myconf} PREFIX=" + myconf="${myconf} LIBDIR=/$(get_libdir)" + myconf="${myconf} BINDIR=/sbin" + myconf="${myconf} MANDIR=/usr/share/man" + myconf="${myconf} INCDIR=/usr/include" + # iptables and libraries are now installed to /sbin and /lib, so that + # systems with remote network-mounted /usr filesystems can get their + # network interfaces up and running correctly without /usr. + use ipv6 || myconf="${myconf} DO_IPV6=0" + use static && myconf="${myconf} NO_SHARED_LIBS=0" + export myconf + if ! use l7filter && ! use imq; then + export KERNEL_DIR="/usr" + diemsg="failure" + else + diemsg="failure - with l7filter or imq patch added" + fi + export diemsg +} + + +src_compile() { + src_defs + + # iptables will NOT work correctly unless -O[123] are present! + replace-flags -O0 -O2 + get-flag -O || append-flags -O2 + + # prevent it from causing ICMP errors. + # http://bugs.gentoo.org/show_bug.cgi?id=23645 + filter-flags -fstack-protector + + emake -j1 \ + COPT_FLAGS="${CFLAGS}" ${myconf} \ + KERNEL_DIR="${KERNEL_DIR}" \ + CC="$(tc-getCC)" \ + || die "${diemsg}" +} + +src_install() { + src_defs + make ${myconf} \ + DESTDIR="${D}" \ + KERNEL_DIR="${KERNEL_DIR}" \ + install install-devel || die "${diemsg}" + + dodir /usr/$(get_libdir) + mv -f "${D}"/$(get_libdir)/*.a "${D}"/usr/$(get_libdir) + + keepdir /var/lib/iptables + newinitd "${FILESDIR}"/${PN}-1.3.2.init iptables + newconfd "${FILESDIR}"/${PN}-1.3.2.confd iptables + + if use ipv6 ; then + keepdir /var/lib/ip6tables + newinitd "${FILESDIR}"/iptables-1.3.2.init ip6tables + newconfd "${FILESDIR}"/ip6tables-1.3.2.confd ip6tables + fi +} + +pkg_postinst() { + einfo "This package now includes an initscript which loads and saves" + einfo "rules stored in /var/lib/iptables/rules-save" + use ipv6 && einfo "and /var/lib/ip6tables/rules-save" + einfo "This location can be changed in /etc/conf.d/iptables" + einfo + einfo "If you are using the iptables initsscript you should save your" + einfo "rules using the new iptables version before rebooting." + einfo + einfo "If you are upgrading to a >=2.4.21 kernel you may need to rebuild" + einfo "iptables." + einfo + ewarn "!!! ipforwarding is not a part of the iptables initscripts." + einfo + einfo "To enable ipforwarding at bootup:" + einfo "/etc/sysctl.conf and set net.ipv4.ip_forward = 1" + if use ipv6 ; then + einfo "and/or" + einfo " net.ipv6.ip_forward = 1" + einfo "for ipv6." + fi + if has_version '=net-firewall/iptables-1.2*' ; then + echo + ewarn "When upgrading from iptables-1.2.x, you may be unable to remove" + ewarn "rules added with iptables-1.2.x. This is a known issue, please see:" + ewarn "http://bugs.gentoo.org/92535" + fi +} |