Red Hat Bugzilla – Bug 11993
Pump does not increment secs field in DHCP DISCOVER packet
Last modified: 2008-05-01 11:37:56 EDT
According to RFCs 951 and 2131, the "secs" field in the DHCP protocol
packet should contain the number of seconds since the client started trying
to find an address. However, in pump 0.7.9, the secs field is always set
This results in pump never receiving a DHCP Offer, because our DHCP relay
is configured not to forward packets with a secs field under 3 seconds.
The bug lies on line 580 of file dhcp.c. First of all, there should be a
htons() call to convert the number of seconds into network byte order.
However, since this number is always zero, it's not surprising that this
The more insidious bug is that this secs field is never set to anything
greater than zero. When the packet is created via a call to
prepareRequest(), the startTime value is initialized to the current uptime,
and the secs is computed as the difference between the two (which is always
zero). I assume that the same packet is then retransmitted several times,
over the course of several seconds, without incrementing the secs field.
Later, within the same process, prepareRequest() is called again to start
off a second round of DHCP Discover packets, and again it resets the
startTime to the current uptime, resulting in the secs field never being
set to a nonzero time.
I don't have a patch, but it seems like there should be a global startTime
variable that is initialized at program start, and this global variable
should be used to calculate the value for the secs field.
Pump has stopped working with RoadRunner on three of the four RedHat Linux 6.2
systems that I maintain. The supplied dhcpcd clients do work, so I converted
from pump to dhcpcd as a workaround. As in this case, pump never receives a
DHCP offer, so I think it likely that this problem is the reason that pump
stopped working with RoadRunner, assuming that RoadRunner has been updating
their DHCP server software.
I'm going to put a pump-0.8.8 out tonight with this fix; it will be available
from ftp://people.redhat.com/ewt. I'd love to know if this works any better for
There is also a mailing list for pump, sending a message with a subject of
subscribe to email@example.com will get you on it.
I compiled pump - 0.8.8 and tried to obtain an address from central florida
It failed as before.