[Bug 1832672] Re: systemd-resolve not ignoring comments in /etc/hosts
Steve Langasek
steve.langasek at canonical.com
Fri Nov 15 16:41:38 UTC 2019
Hello Bruno, or anyone else affected,
Accepted systemd into bionic-proposed. The package will build now and be
available at
https://launchpad.net/ubuntu/+source/systemd/237-3ubuntu10.33 in a few
hours, and then in the -proposed repository.
Please help us by testing this new package. See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed. Your feedback will aid us getting this
update out to other Ubuntu users.
If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested and change the tag from
verification-needed-bionic to verification-done-bionic. If it does not
fix the bug for you, please add a comment stating that, and change the
tag to verification-failed-bionic. In either case, without details of
your testing we will not be able to proceed.
Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in
advance for helping!
N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.
** Tags removed: verification-done verification-done-bionic
** Tags added: verification-needed verification-needed-bionic
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to systemd in Ubuntu.
https://bugs.launchpad.net/bugs/1832672
Title:
systemd-resolve not ignoring comments in /etc/hosts
Status in systemd:
Unknown
Status in systemd package in Ubuntu:
Fix Released
Status in systemd source package in Bionic:
Fix Committed
Bug description:
[impact]
resolved does not ignore comments properly in /etc/hosts
[test case]
see original description below
[regression potential]
as this modifies resolved parsing of /etc/hosts, regressions would
likely be in hostname lookups from hosts in /etc/hosts, or failure(s)
to parse /etc/hosts correctly.
[other info]
original description:
---
$ lsb_release -rd
Description: Ubuntu 18.04.2 LTS
Release: 18.04
$ LANG=C apt-cache policy systemd
systemd:
Installed: 237-3ubuntu10.22
Candidate: 237-3ubuntu10.22
Version table:
*** 237-3ubuntu10.22 500
500 http://ch.archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages
100 /var/lib/dpkg/status
237-3ubuntu10.19 500
500 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages
237-3ubuntu10 500
500 http://ch.archive.ubuntu.com/ubuntu bionic/main amd64 Packages
500 http://mirrors.kernel.org/ubuntu bionic/main amd64 Packages
$ head -1 /etc/hosts
127.0.2.1 foo # bar
$ /usr/bin/systemd-resolve -4 bar
expected
----------
bar: resolve call failed: 'bar' not found
What happened instead
---------------------
bar: 127.0.2.1
HOSTS(5)
> Text from a "#" character until the end of the line is a comment, and is ignored.
This is fixed in upstream:
https://github.com/systemd/systemd/issues/10779
https://github.com/systemd/systemd/commit/bd0052777981044cf54a1e9d6e3acb1c3d813656
Please backport to current LTS version.
I accidentally connected to wrong systems because of this bug.
To manage notifications about this bug go to:
https://bugs.launchpad.net/systemd/+bug/1832672/+subscriptions
More information about the foundations-bugs
mailing list