summaryrefslogtreecommitdiff
diff options
authorMichael Biebl <[email protected]>2023-03-03 17:57:30 +0100
committergit-ubuntu importer <[email protected]>2023-03-03 22:32:30 +0000
commit659fe666817356d07c3a54196cf899195e920d0e (patch)
tree1e8aed8d622826555b8929aba63486b0b568a9b6
parent6cddc2c88c0896676688e705e90a4d7da2a0796f (diff)
1.42.2-2 (patches unapplied)
Imported using git-ubuntu import.
-rw-r--r--debian/changelog9
-rw-r--r--debian/patches/dnsmasq-process-both-global-and-per-device-configuration.patch30
-rw-r--r--debian/patches/man-update-documentation-about-global-DNS-configuration.patch51
-rw-r--r--debian/patches/series2
4 files changed, 92 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog
index cd978cf1b..d12ec10a9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+network-manager (1.42.2-2) unstable; urgency=medium
+
+ * dnsmasq: process both global and per-device configuration.
+ Cherry-pick upstream patch to fix a regression introduced in 1.42 when
+ using the dnsmasq DNS backend and a global DNS configuration.
+ (Closes: #1031891)
+
+ -- Michael Biebl <[email protected]> Fri, 03 Mar 2023 17:57:30 +0100
+
network-manager (1.42.2-1) unstable; urgency=medium
* New upstream version 1.42.2
diff --git a/debian/patches/dnsmasq-process-both-global-and-per-device-configuration.patch b/debian/patches/dnsmasq-process-both-global-and-per-device-configuration.patch
new file mode 100644
index 000000000..0f0fdbc36
--- /dev/null
+++ b/debian/patches/dnsmasq-process-both-global-and-per-device-configuration.patch
@@ -0,0 +1,30 @@
+From: Beniamino Galvani <[email protected]>
+Date: Thu, 2 Mar 2023 18:02:48 +0100
+Subject: dnsmasq: process both global and per-device configuration
+
+The global configuration now can be valid when there are no global
+domains defined. The dnsmasq backend must process it and then, if
+there is no global default domain, also process the per-connection
+settings.
+
+Fixes: 1f0d1d78d2a2 ('dns-manager: always apply options from [global-dns]')
+(cherry picked from commit 5c0a927e0fd983a963f49cf8dccba6a82c95ef94)
+(cherry picked from commit 89888f85aa5c6f115d2dda1888b4e5ce0946c634)
+---
+ src/core/dns/nm-dns-dnsmasq.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/core/dns/nm-dns-dnsmasq.c b/src/core/dns/nm-dns-dnsmasq.c
+index 8ae1bb9..05aeff4 100644
+--- a/src/core/dns/nm-dns-dnsmasq.c
++++ b/src/core/dns/nm-dns-dnsmasq.c
+@@ -922,7 +922,8 @@ create_update_args(NMDnsDnsmasq *self,
+
+ if (global_config)
+ add_global_config(self, &servers, global_config);
+- else {
++
++ if (!global_config || !nm_global_dns_config_lookup_domain(global_config, "*")) {
+ c_list_for_each_entry (ip_data, ip_data_lst_head, ip_data_lst)
+ add_ip_config(self, &servers, ip_data);
+ }
diff --git a/debian/patches/man-update-documentation-about-global-DNS-configuration.patch b/debian/patches/man-update-documentation-about-global-DNS-configuration.patch
new file mode 100644
index 000000000..d5e88bb11
--- /dev/null
+++ b/debian/patches/man-update-documentation-about-global-DNS-configuration.patch
@@ -0,0 +1,51 @@
+From: Beniamino Galvani <[email protected]>
+Date: Thu, 2 Mar 2023 22:15:46 +0100
+Subject: man: update documentation about global DNS configuration
+
+Now the settings in the [global-dns] section are used *in addition* to
+connection-specific ones. Only the global domains sections, when
+valid, override connection settings. Update the man page to clarify
+that.
+
+Fixes: 1f0d1d78d2a2 ('dns-manager: always apply options from [global-dns]')
+(cherry picked from commit f57a848da5aa1a18cdcec22e9564462dea68a53f)
+(cherry picked from commit 82134e4f832ff68e5fd8f9968cae32c6aed82ea6)
+---
+ man/NetworkManager.conf.xml | 17 +++++++++++------
+ 1 file changed, 11 insertions(+), 6 deletions(-)
+
+diff --git a/man/NetworkManager.conf.xml b/man/NetworkManager.conf.xml
+index 2c1fc85..0dcf805 100644
+--- a/man/NetworkManager.conf.xml
++++ b/man/NetworkManager.conf.xml
+@@ -1453,8 +1453,8 @@ managed=1
+
+ <refsect1>
+ <title><literal>global-dns</literal> section</title>
+- <para>This section specifies global DNS settings that override
+- connection-specific configuration.</para>
++ <para>This section specifies DNS settings that are applied
++ globally, in addition to connection-specific ones.</para>
+ <para>
+ <variablelist>
+ <varlistentry>
+@@ -1482,10 +1482,15 @@ managed=1
+ <para>Sections with a name starting with the "global-dns-domain-"
+ prefix allow to define global DNS configuration for specific
+ domains. The part of section name after "global-dns-domain-"
+- specifies the domain name a section applies to. More specific
+- domains have the precedence over less specific ones and the
+- default domain is represented by the wildcard "*". A default
+- domain section is mandatory.
++ specifies the domain name a section applies to (for example, a
++ section could be named "global-dns-domain-foobar.com"). More
++ specific domains have the precedence over less specific ones and
++ the default domain is represented by the wildcard "*".
++
++ To be valid, global DNS domains must include a section for the
++ default domain "*". When the global DNS domains are valid, the
++ name servers and domains defined globally override the ones from
++ active connections.
+ </para>
+ <para>
+ <variablelist>
diff --git a/debian/patches/series b/debian/patches/series
index a2d7e06db..17887c890 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1 +1,3 @@
Force-online-state-with-unmanaged-devices.patch
+dnsmasq-process-both-global-and-per-device-configuration.patch
+man-update-documentation-about-global-DNS-configuration.patch