Package: kxc
Version: 0.15-4.1+b1
Severity: important
Tags: patch

Dear Maintainer,

The script
/usr/share/initramfs-tools/scripts/init-premount/kxc-premount-net writes
a line to /etc/resolv.conf adding a "nameserver $IPV4DNS0" even if that
environment variable is empty. If I understand correctly that variable
is only set if a DNS is passed via the ip= kernel parameter. Popular
simple configurations like ip=dhcp will then have no DNS server set
there, which will end up with a bad /etc/resolv.conf line with
"namesever ".

-- System Information:
Debian Release: trixie/sid
  APT prefers testing
  APT policy: (990, 'testing'), (500, 'stable'), (300, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux 6.4.0-1-amd64 (SMP w/8 CPU threads; PREEMPT)
Kernel taint flags: TAINT_CPU_OUT_OF_SPEC, TAINT_USER, TAINT_OOT_MODULE, 
TAINT_UNSIGNED_MODULE
Locale: LANG=en_IE.UTF-8, LC_CTYPE=en_IE.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_IE:en
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages kxc depends on:
ii  cryptsetup  2:2.6.1-6+b1
ii  kxgencert   0.15-4.1+b1

kxc recommends no packages.

kxc suggests no packages.

-- no debconf information
--- /tmp/kxc-premount-net       2024-03-06 21:34:23.392212084 +0100
+++ /usr/share/initramfs-tools/scripts/init-premount/kxc-premount-net   
2024-03-06 21:35:18.080475021 +0100
@@ -22,7 +22,7 @@
 configure_networking
 
 # Configure a basic resolv.conf based on our networking.
-if ! [ -s /etc/resolv.conf ]; then
+if ! [ -s /etc/resolv.conf -a -n "$IPV4DNS0" ]; then
        echo "nameserver $IPV4DNS0" >> /etc/resolv.conf
 fi
 
  • Bug#1065573: kxc: initramfs script writes a line to reso... Leandro Lucarella

Reply via email to