Re: Ethereal comparison 1.265 vs 1.270 DHCP Discover



On Fri, 2005-02-11 at 16:02 -0500, Bill Moss wrote:
> Bootstrap Protocol identical down to
> 
> 1.270:
> Option 53 DHCP Message TYPE = DHCP Discover
> Option 57: Maximum DHCP Message Size = 548
> Option 51: IP Address Lease Time = infinity
> Option 55: Parameter Request List
> Option 12: Host Name = "localhost.localdomain"
> == SMC DHCP does not send an ARP. It is stuck here. It doesn't like 
> something about the way this message is constructed. All checksums are 
> correct in all parts of the message.
> 
> 1.265
> Option 53 DHCP Message TYPE = DHCP Discover
> Option 57: Maximum DHCP Message Size = 548
> Option 51: IP Address Lease Time = infinity
> Option 55: Parameter Request List
> Option 60: Vendor class identifier = "Linux 2.6.10-1.760_FC3 i686"
> Option 61: Client identifier
> == SMC DHCP immcdiately sends an ARP and the process continues to completion

Bill,

Could you apply this patch, rebuild, and try again?  It should revert
the DHCP message options to what they were before, ie making it send the
Client & Class ID but not the hostname.

Dan
? bmoss-test.patch
? debian.patch
? foo
? dhcpcd/cli.diff
Index: dhcpcd/dhcpcd.c
===================================================================
RCS file: /cvs/gnome/NetworkManager/dhcpcd/dhcpcd.c,v
retrieving revision 1.6
diff -u -r1.6 dhcpcd.c
--- dhcpcd/dhcpcd.c	10 Feb 2005 20:54:04 -0000	1.6
+++ dhcpcd/dhcpcd.c	11 Feb 2005 22:08:13 -0000
@@ -38,6 +38,10 @@
 #include "dhcpcd.h"
 #include "client.h"
 
+#include <netinet/in.h>
+#include <sys/utsname.h>
+#include <net/if_arp.h>
+
 
 /*
  * DHCP Client Daemon v1.3.22-pl4
@@ -226,6 +230,25 @@
 	class_id_setup (iface, iface->client_options->class_id);
 	client_id_setup (iface, iface->client_options->client_id);
 
+{
+/* Reconstruct the old way of doing things */
+	struct utsname sname;
+	char *c;
+	/* Dump kernel info into class_id */
+	if ( uname(&sname) )
+		syslog (LOG_ERR,"class_id_setup(): uname returned an error: %m\n");
+	snprintf (iface->cls_id, DHCP_CLASS_ID_MAX_LEN, "%s", sname.sysname);
+	iface->cls_id_len = strlen (iface->cls_id);
+
+	/* dump ether addr into client_id */
+	c = iface->cli_id;
+	*c++ = ARPHRD_ETHER;	/* type: Ethernet address */
+	memcpy (c, iface->chaddr, ETH_ALEN);
+	iface->cli_id_len = ETH_ALEN + 1;
+
+	/* Blank hostname */
+	iface->client_options->host_name[0] = '\0';
+}
 	return iface;
 
 err_out:


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]