Reply to remote unicast DHCP requests

Paúl Ortiz Imedio portizimedio at
Tue May 3 10:17:01 UTC 2011

I am trying to figure out the behaviour of the DHCP server when replying to 
unicast DHCP Requests from clients at remote subnets (RENEWING state). At 
that moment, no DHCP Relay is being used.
I have looked for the subject in previous posts related to this topic and in 
the source code too, but I have not found it coherent.
Let me copy a comment from the code at dhcprequest( ):
    If ciaddr was specified and Requested Address was not, then
    we really only know for sure what network a packet came from
    if it came through a BOOTP gateway - if it came through an
    IP router, we'll just have to assume that it's cool.
The comment continues, but I understand that this paragraph is not 
It is said that the ciaddr will be assumed to be ok if there is no giaddr (it 
comes from an IP router). However, after the comments it is required that  
"packet -> shared_network"  is not null to answer with a DHCPACK. I am not 
using advanced options such as link-selection or subnet-selection, and giaddr 
is empty, so in locate_network( ) it is assigned (when possible): 
packet -> shared_network = packet -> interface -> shared_network
The interface at which my server is receiving the DHCPREQUEST does not belong 
to any shared_network, so packet -> shared_network is null and the unicast
packet is not being answered with the DHCPACK I am waiting. The client has to 
enter REBINDING state to extend its lease.
Am I missing something?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the dhcp-users mailing list