diff options
author | Roy Marples <uberlord@gentoo.org> | 2007-04-11 19:43:38 +0000 |
---|---|---|
committer | Roy Marples <uberlord@gentoo.org> | 2007-04-11 19:43:38 +0000 |
commit | 4919eec0781bf12ec2bdaac1775c426710759942 (patch) | |
tree | efb2a3971285b1e31ddb8a785ef0d5200e24aea3 /net-misc/dhcpcd | |
parent | ppc stable, bug #164466 (diff) | |
download | gentoo-2-4919eec0781bf12ec2bdaac1775c426710759942.tar.gz gentoo-2-4919eec0781bf12ec2bdaac1775c426710759942.tar.bz2 gentoo-2-4919eec0781bf12ec2bdaac1775c426710759942.zip |
Add patch to enfore a minimum dhcp message size of 300 bytes for crappy servers, #173399. Thanks to Kim for finding the issue.
(Portage version: 2.1.2.3)
Diffstat (limited to 'net-misc/dhcpcd')
-rw-r--r-- | net-misc/dhcpcd/ChangeLog | 9 | ||||
-rw-r--r-- | net-misc/dhcpcd/dhcpcd-3.0.16-r1.ebuild | 37 | ||||
-rw-r--r-- | net-misc/dhcpcd/files/dhcpcd-3.0.16-min-message.patch | 24 | ||||
-rw-r--r-- | net-misc/dhcpcd/files/digest-dhcpcd-3.0.16-r1 | 3 |
4 files changed, 72 insertions, 1 deletions
diff --git a/net-misc/dhcpcd/ChangeLog b/net-misc/dhcpcd/ChangeLog index 47a31a25b268..b3a314901bb5 100644 --- a/net-misc/dhcpcd/ChangeLog +++ b/net-misc/dhcpcd/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for net-misc/dhcpcd # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcpcd/ChangeLog,v 1.141 2007/04/08 10:51:48 corsair Exp $ +# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcpcd/ChangeLog,v 1.142 2007/04/11 19:43:38 uberlord Exp $ + +*dhcpcd-3.0.16-r1 (11 Apr 2007) + + 11 Apr 2007; Roy Marples <uberlord@gentoo.org> + +files/dhcpcd-3.0.16-min-message.patch, +dhcpcd-3.0.16-r1.ebuild: + Add patch to enfore a minimum dhcp message size of 300 bytes for crappy + servers, #173399. Thanks to Kim for finding the issue. 08 Apr 2007; Markus Rothe <corsair@gentoo.org> dhcpcd-3.0.16.ebuild: Stable on ppc64; bug #166921 diff --git a/net-misc/dhcpcd/dhcpcd-3.0.16-r1.ebuild b/net-misc/dhcpcd/dhcpcd-3.0.16-r1.ebuild new file mode 100644 index 000000000000..4181f7b016de --- /dev/null +++ b/net-misc/dhcpcd/dhcpcd-3.0.16-r1.ebuild @@ -0,0 +1,37 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-misc/dhcpcd/dhcpcd-3.0.16-r1.ebuild,v 1.1 2007/04/11 19:43:38 uberlord Exp $ + +inherit eutils toolchain-funcs + +DESCRIPTION="A DHCP client" +HOMEPAGE="http://dhcpcd.berlios.de" +SRC_URI="http://download.berlios.de/${PN}/${P}.tar.bz2" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 ~arm hppa ia64 ~mips ppc ppc64 ~s390 ~sh sparc ~sparc-fbsd x86 ~x86-fbsd" +IUSE="" + +DEPEND="" +PROVIDE="virtual/dhcpc" + +src_unpack() { + unpack ${A} + cd "${S}" + + # Redefine the location of ntp.drift + sed -i -e 's,#define NTPDRIFTFILE\t.*,#define NTPDRIFTFILE\t\t\"/var/lib/ntp/ntp.drift\",' \ + pathnames.h || die "sed failed" + + epatch "${FILESDIR}"/${P}-min-message.patch +} + +src_compile() { + emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" || die +} + +src_install() { + emake DESTDIR="${D}" install || die + dodoc ChangeLog +} diff --git a/net-misc/dhcpcd/files/dhcpcd-3.0.16-min-message.patch b/net-misc/dhcpcd/files/dhcpcd-3.0.16-min-message.patch new file mode 100644 index 000000000000..c1448c2c493b --- /dev/null +++ b/net-misc/dhcpcd/files/dhcpcd-3.0.16-min-message.patch @@ -0,0 +1,24 @@ +Index: dhcp.c +=================================================================== +--- dhcp.c (revision 188) ++++ dhcp.c (working copy) +@@ -38,6 +38,7 @@ + #include "logger.h" + #include "socket.h" + ++#define DHCP_PACKET_LENTH_MIN 300 + #define BROADCAST_FLAG 0x8000 + + static const char *dhcp_message[] = { +@@ -266,6 +267,11 @@ + + *p++ = DHCP_END; + ++#ifdef DHCP_PACKET_LENTH_MIN ++ while (p - m < DHCP_PACKET_LENTH_MIN) ++ *p++ = 0; ++#endif ++ + message_length = p - m; + + memset (&packet, 0, sizeof (struct udp_dhcp_packet)); diff --git a/net-misc/dhcpcd/files/digest-dhcpcd-3.0.16-r1 b/net-misc/dhcpcd/files/digest-dhcpcd-3.0.16-r1 new file mode 100644 index 000000000000..4ddc5918d873 --- /dev/null +++ b/net-misc/dhcpcd/files/digest-dhcpcd-3.0.16-r1 @@ -0,0 +1,3 @@ +MD5 f100349190074dced9bced60dcc1b9f7 dhcpcd-3.0.16.tar.bz2 31639 +RMD160 24ab33bf453a0eb3301fc879e7e98f607aaf14d6 dhcpcd-3.0.16.tar.bz2 31639 +SHA256 324318a4d9feabf313011bdf8e0152beb904e7f4611cc539f767304343639be7 dhcpcd-3.0.16.tar.bz2 31639 |