From 7c59acba5699c9c58090a7a738669669a7307023 Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sat, 21 Aug 2021 23:14:26 +0100 Subject: gentoo resync : 21.08.2021 --- net-misc/oidentd/Manifest | 3 + .../files/oidentd-3.0.0-ipv6-masquerade.patch | 85 ++++++++++++++++++++++ net-misc/oidentd/oidentd-3.0.0-r1.ebuild | 59 +++++++++++++++ 3 files changed, 147 insertions(+) create mode 100644 net-misc/oidentd/files/oidentd-3.0.0-ipv6-masquerade.patch create mode 100644 net-misc/oidentd/oidentd-3.0.0-r1.ebuild (limited to 'net-misc/oidentd') diff --git a/net-misc/oidentd/Manifest b/net-misc/oidentd/Manifest index ad4b036204a4..7d0e6abbc1c1 100644 --- a/net-misc/oidentd/Manifest +++ b/net-misc/oidentd/Manifest @@ -1,6 +1,9 @@ AUX oidentd-2.0.7-init 837 BLAKE2B ab01ed3d6675f6196edcf7712c9f2e77369edc2481433788e63a3a82e591831869623723002f49a4498ed10ba7657f51dbc795895384213e473eba950e7ba7be SHA512 ebd072d86fa879017bb43f8f9cdd0ea563f337b558552ebdc27c980376889dfd22f2d6bdeb424ca3e2dbe62a78ceb80208ee26398aed0c38c4f973646d6d80d3 AUX oidentd-2.2.2-confd 69 BLAKE2B 37fac35c28304f92942844ee7652f52496cdc4c66da67d449127c3e9b61c715afb25cae7379137d8b9e2863d44e72535734c595c8edcc18f94b8c3841cd216ab SHA512 639f062b61b3aac829d6d16497d548290d8de3e161a1d8037b689593374b89028243b9369109b1b4b55d125ec665f1433bb971ea873a2e6e1b6b15eabfad8e6a AUX oidentd-2.5.0-respect-ar.patch 250 BLAKE2B e756da25bca3a2e98be1a625c99f33b20ebb237cd7a3fe8f6e01664db328636451bd7af70cc16e08e45344511660787836358f92c2fa1806998dcf35f73fdc10 SHA512 6ddb24e88e864359faf8f6aa6a28de01067b0cc20c349e8c9f6ec4dafde26636e7cce3e11e137c12cd868f0de85546462be599333966ad8bf850cea5afc9b62c +AUX oidentd-3.0.0-ipv6-masquerade.patch 2302 BLAKE2B c291c43037d7b30e15b0c4599614a06fd6a0f3bc66bc2ae83c8c22ace90eda3f4b43b6e9606710fc0fa6eb1baa2aba9b8bbfb65a5be0b774e6cbf0d39e161b9d SHA512 7cfacf126cd2369c71729380d75b662540ae4d7f1e8ee0510fc1d9f99d78d9538aa03d927dbb642c31e36d3d9b9df86fb5036e8abcf3145b9287046189642c9c DIST oidentd-2.5.0.tar.xz 195536 BLAKE2B ea6327fc415811b7050503daa393639f5740e9c1681794cfadf447e4968024aed7e0367ba804209d236c295777f856297b62c1d7e307c268c3d9fad9b240b7f5 SHA512 31ff2cad2afaa9f07a0aa35ad904047de78f168f9e6d6a3fcf7397eb89e6b930c30741eb1de44e3c2c24f48ca7d860cafd2771f464b336d400ab6d98384e9320 +DIST oidentd-3.0.0.tar.xz 187088 BLAKE2B ca824119cbb54aee52658c9a167ace88b2ed7f118565d7be043e19534a323772d18a043d803cd553c7408a525e3c717ffb990fb8794b4af4e8ac6c1efe4571c0 SHA512 92e733272979c08bba012f33aa6e0eadc15e18e03c24258b0333f74c201df87cc619012e2d8da69aac10c15684691464f59551c9b9d83e690b3902e47f649c68 EBUILD oidentd-2.5.0.ebuild 1254 BLAKE2B 928c432bef758266ecd842a3aaea3a4fe55468598a4867d1502eec42a73e540b62591f277f96f4874f38c1e9069f3ccdc6a32a8390c0fc619aa8d9a643511bb6 SHA512 0ea39fead9d40f11229831e53551430788baf885b25efa476b7695057a182279b187b142b50113530a3b2177f577ec5a1f0b60dd88346e23fa807b90055b36f8 +EBUILD oidentd-3.0.0-r1.ebuild 1283 BLAKE2B 2927c0036a8150c70ead57c1dfcf939d74c21f0041096947625dc171b11520ba69bae84ee37a97f0a0be2039a122e3ddd8a9624a91d1b45356d98da1a28ed5bd SHA512 40be13b814098f848aa9c4bbfd005655e75ff8e2316d56fe817541474e14ee1dec32858c1ae111788db75c9dc962e3bdb74e22880c554fa8e2fb496a3f1b809b MISC metadata.xml 569 BLAKE2B ebb1379e780eeeca09af18ca713b55a27c5b3479e66f5571a61de890de3472605a808cdcf950ff7df72de67423d11fc5dc0963bfe8c852b457b606f90094f49c SHA512 154609210a6c893d55d0150e62122a803295d2bea19d61b2e77400083eaa2172b2a427566a7350e944c9a27cdf84f3babdde87f320f4fd05ebeae0712c313de7 diff --git a/net-misc/oidentd/files/oidentd-3.0.0-ipv6-masquerade.patch b/net-misc/oidentd/files/oidentd-3.0.0-ipv6-masquerade.patch new file mode 100644 index 000000000000..47573e3f08a7 --- /dev/null +++ b/net-misc/oidentd/files/oidentd-3.0.0-ipv6-masquerade.patch @@ -0,0 +1,85 @@ +From 5fdbfea671f75f869abeadd02a36bc941b25020f Mon Sep 17 00:00:00 2001 +From: Janik Rabe +Date: Tue, 17 Aug 2021 19:28:46 +0100 +Subject: [PATCH] Allow using masquerading without IPv6 support on Linux + +--- + ChangeLog | 4 ++++ + NEWS | 4 ++++ + src/kernel/linux.c | 10 +++++++++- + 3 files changed, 17 insertions(+), 1 deletion(-) + +diff --git a/ChangeLog b/ChangeLog +index 8102669..09f8db6 100644 +--- a/ChangeLog ++++ b/ChangeLog +@@ -1,3 +1,7 @@ ++2021-08-17 Janik Rabe ++ ++ * Allow using masquerading without IPv6 support on Linux. ++ + 2021-08-16 Janik Rabe + + * Released as version 3.0.0. +diff --git a/NEWS b/NEWS +index bb64455..8820d3a 100644 +--- a/NEWS ++++ b/NEWS +@@ -1,3 +1,7 @@ ++Unreleased changes ++ ++ * Allow using masquerading without IPv6 support on Linux. ++ + Changes in version 3.0.0 + + * Support for '--debug' is now included by default. +diff --git a/src/kernel/linux.c b/src/kernel/linux.c +index db0296c..f68e433 100644 +--- a/src/kernel/linux.c ++++ b/src/kernel/linux.c +@@ -462,10 +462,12 @@ static int masq_ct_line(char *line, + in_addr_t remotem4; + in_addr_t localn4; + in_addr_t remoten4; ++#if WANT_IPV6 + struct in6_addr localm6; + struct in6_addr remotem6; + struct in6_addr localn6; + struct in6_addr remoten6; ++#endif + u_int32_t nport_temp; + u_int32_t mport_temp; + u_int32_t masq_lport_temp; +@@ -511,6 +513,8 @@ static int masq_ct_line(char *line, + sin_setv4(remoten4, &remoten_ss); + + break; ++ ++#if WANT_IPV6 + case AF_INET6: + if (strcasecmp(family, "ipv6")) + return 1; +@@ -527,9 +531,11 @@ static int masq_ct_line(char *line, + sin_setv6(&remoten6, &remoten_ss); + + break; ++#endif ++ + default: + debug("masq_ct_line: bad address family %d", faddr->ss_family); +- return -1; ++ return 1; + } + + masq_lport = (in_port_t) masq_lport_temp; +@@ -561,8 +567,10 @@ static int masq_ct_line(char *line, + if (con_uid == MISSING_UID && faddr->ss_family == AF_INET) + con_uid = get_user4(htons(masq_lport), htons(masq_fport), laddr, &remotem_ss); + ++#if WANT_IPV6 + if (con_uid == MISSING_UID && faddr->ss_family == AF_INET6) + con_uid = get_user6(htons(masq_lport), htons(masq_fport), laddr, &remotem_ss); ++#endif + + if (con_uid == MISSING_UID) + return -1; diff --git a/net-misc/oidentd/oidentd-3.0.0-r1.ebuild b/net-misc/oidentd/oidentd-3.0.0-r1.ebuild new file mode 100644 index 000000000000..3c1eea07ecf3 --- /dev/null +++ b/net-misc/oidentd/oidentd-3.0.0-r1.ebuild @@ -0,0 +1,59 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit systemd + +DESCRIPTION="Another (RFC1413 compliant) ident daemon" +HOMEPAGE="https://oidentd.janikrabe.com/" +SRC_URI="https://files.janikrabe.com/pub/${PN}/releases/${PV}/${P}.tar.xz" + +LICENSE="BSD-2 GPL-2 LGPL-2+" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86" +IUSE="debug ipv6 masquerade selinux" + +DEPEND="masquerade? ( net-libs/libnetfilter_conntrack )" + +RDEPEND=" + ${DEPEND} + acct-user/oidentd + acct-group/oidentd + selinux? ( sec-policy/selinux-oident ) +" + +BDEPEND=" + sys-devel/bison + sys-devel/flex +" + +PATCHES=( "${FILESDIR}/${P}-ipv6-masquerade.patch" ) + +src_prepare() { + sed -i '/ExecStart/ s|$| -u oidentd -g oidentd|' contrib/systemd/*.service || die + + default +} + +src_configure() { + local myconf=( + $(use_enable debug) + $(use_enable ipv6) + $(use_enable masquerade libnfct) + $(use_enable masquerade nat) + --enable-xdgbdir + ) + econf "${myconf[@]}" +} + +src_install() { + default + + newinitd "${FILESDIR}"/${PN}-2.0.7-init ${PN} + newconfd "${FILESDIR}"/${PN}-2.2.2-confd ${PN} + + systemd_dounit contrib/systemd/${PN}@.service + systemd_dounit contrib/systemd/${PN}.socket + systemd_dounit contrib/systemd/${PN}.service +} -- cgit v1.2.3