Browse Source

[dhcp] Ignore ProxyDHCPACKs without PXE options

Suggested-by: Wissam Shoukair <wissams@mellanox.com>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 8 years ago
parent
commit
0a34c2aab9
1 changed files with 4 additions and 0 deletions
  1. 4
    0
      src/net/udp/dhcp.c

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

@@ -670,6 +670,8 @@ static void dhcp_proxy_rx ( struct dhcp_session *dhcp,
670 670
 		DBGC ( dhcp, " (%s/", inet_ntoa ( server_id ) );
671 671
 		DBGC ( dhcp, "%s)", inet_ntoa ( pseudo_id ) );
672 672
 	}
673
+	if ( dhcp_has_pxeopts ( dhcppkt ) )
674
+		DBGC ( dhcp, " pxe" );
673 675
 	DBGC ( dhcp, "\n" );
674 676
 
675 677
 	/* Filter out unacceptable responses */
@@ -679,6 +681,8 @@ static void dhcp_proxy_rx ( struct dhcp_session *dhcp,
679 681
 		return;
680 682
 	if ( ( pseudo_id.s_addr != dhcp->proxy_server.s_addr ) )
681 683
 		return;
684
+	if ( ! dhcp_has_pxeopts ( dhcppkt ) )
685
+		return;
682 686
 
683 687
 	/* Register settings */
684 688
 	if ( ( rc = register_settings ( settings, NULL,

Loading…
Cancel
Save