Browse Source

[dhcp] Ignore DHCPACKs containing incorrect IP addresses

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 14 years ago
parent
commit
ba6aca3424
1 changed files with 2 additions and 0 deletions
  1. 2
    0
      src/net/udp/dhcp.c

+ 2
- 0
src/net/udp/dhcp.c View File

528
 		return;
528
 		return;
529
 	if ( server_id.s_addr != dhcp->server.s_addr )
529
 	if ( server_id.s_addr != dhcp->server.s_addr )
530
 		return;
530
 		return;
531
+	if ( ip.s_addr != dhcp->offer.s_addr )
532
+		return;
531
 
533
 
532
 	/* Record assigned address */
534
 	/* Record assigned address */
533
 	dhcp->local.sin_addr = ip;
535
 	dhcp->local.sin_addr = ip;

Loading…
Cancel
Save