Blame SOURCES/0005-dhcp-internal-default-client-id-rh1695723.patch

97acb4
From c63d39ed73da9cd804e7ace3b11debb49ed5f6b4 Mon Sep 17 00:00:00 2001
b1b5c9
From: Francesco Giudici <fgiudici@redhat.com>
b1b5c9
Date: Tue, 9 Apr 2019 11:41:27 +0200
b1b5c9
Subject: [PATCH] dhcp/internal: make default dhcp-client-id based on systemd
b1b5c9
 DUID-EN
b1b5c9
b1b5c9
For RHEL-7 we want to stick to the legacy behavior of the internal
b1b5c9
dhcp client: the default dhcp-client-id is based on systemd DUID-EN.
b1b5c9
b1b5c9
https://bugzilla.redhat.com/show_bug.cgi?id=1695723
b1b5c9
b1b5c9
This reverts commit cfd696cc3cf43f5f510046b757949546bcee4cdc.
b1b5c9
---
b1b5c9
 src/dhcp/nm-dhcp-manager.c | 2 +-
b1b5c9
 src/dhcp/nm-dhcp-systemd.c | 3 ++-
b1b5c9
 2 files changed, 3 insertions(+), 2 deletions(-)
b1b5c9
b1b5c9
diff --git a/src/dhcp/nm-dhcp-manager.c b/src/dhcp/nm-dhcp-manager.c
97acb4
index fe843a2ce43c..b998bf465b25 100644
b1b5c9
--- a/src/dhcp/nm-dhcp-manager.c
b1b5c9
+++ b/src/dhcp/nm-dhcp-manager.c
b1b5c9
@@ -237,7 +237,7 @@ client_start (NMDhcpManager *self,
b1b5c9
 	 *
b1b5c9
 	 * - for IPv4, the calling code may determine a client-id (from NM's connection profile).
b1b5c9
 	 *   If present, it is taken. If not present, the DHCP plugin uses a plugin specific default.
b1b5c9
-	 *     - for "internal" plugin, the default is just "mac".
b1b5c9
+	 *     - for "internal" plugin, the default is just "duid".
b1b5c9
 	 *     - for "dhclient", we try to get the configuration from dhclient's /etc/dhcp or fallback
b1b5c9
 	 *       to whatever dhclient uses by default.
b1b5c9
 	 *   We do it this way, because for dhclient the user may configure a default
b1b5c9
diff --git a/src/dhcp/nm-dhcp-systemd.c b/src/dhcp/nm-dhcp-systemd.c
97acb4
index 1cd5ba278283..b6344d9bbf9c 100644
b1b5c9
--- a/src/dhcp/nm-dhcp-systemd.c
b1b5c9
+++ b/src/dhcp/nm-dhcp-systemd.c
b1b5c9
@@ -750,7 +750,8 @@ ip4_start (NMDhcpClient *client,
b1b5c9
 
b1b5c9
 	client_id = nm_dhcp_client_get_client_id (client);
b1b5c9
 	if (!client_id) {
b1b5c9
-		client_id_new = nm_utils_dhcp_client_id_mac (arp_type, hwaddr_arr, hwaddr_len);
b1b5c9
+		client_id_new = nm_utils_dhcp_client_id_systemd_node_specific (TRUE,
b1b5c9
+		                                                               nm_dhcp_client_get_iface (client));
b1b5c9
 		client_id = client_id_new;
b1b5c9
 	}
b1b5c9
 
b1b5c9
-- 
97acb4
2.21.0
b1b5c9