Lennart Poettering [Thu, 24 Oct 2024 09:36:48 +0000 (11:36 +0200)]
run0: optionally show superhero emoji on each shell prompt
This makes use of the infra introduced in
229d4a980607e9478cf1935793652ddd9a14618b to indicate visually on each prompt that we are in superuser mode temporarily.
pick
ad5de3222f userdbctl: add some basic client-side filtering
Lennart Poettering [Fri, 25 Oct 2024 14:25:01 +0000 (16:25 +0200)]
Merge pull request #34891 from poettering/run0-pty
run0: add --pty and --pipe switches to force allocation of a pty or pipe
Lennart Poettering [Fri, 25 Oct 2024 07:29:38 +0000 (09:29 +0200)]
ci: add some basic testing of the new --pty and --pipe switches
Lennart Poettering [Thu, 24 Oct 2024 21:27:59 +0000 (23:27 +0200)]
run0: add options to force allocation of PTY or of pipe use
Fixes: #33033
Lennart Poettering [Thu, 24 Oct 2024 21:12:31 +0000 (23:12 +0200)]
tree-wide: use isatty_safe() everywhere
Lennart Poettering [Fri, 25 Oct 2024 11:57:44 +0000 (13:57 +0200)]
update TODO
Lennart Poettering [Fri, 25 Oct 2024 08:06:31 +0000 (10:06 +0200)]
Merge pull request #34877 from aafeijoo-suse/veritysetup-fixes
veritysetup-generator: minor man/code changes
Lennart Poettering [Fri, 25 Oct 2024 07:22:03 +0000 (09:22 +0200)]
Merge pull request #34880 from poettering/change-user-on-pam-always
core: make sure that if PAMName= is set we always do the full user ch…
Lennart Poettering [Thu, 24 Oct 2024 20:51:49 +0000 (22:51 +0200)]
test: add quick test to verify the PAM stack really ran in all run0 modes of operation
Lennart Poettering [Thu, 24 Oct 2024 08:52:56 +0000 (10:52 +0200)]
core: make sure that if PAMName= is set we always do the full user changing even if no user is specified explicitly
When PAMName= is set this should be enough to go through our entire user
changing story, so that PAM is definitely run, and environment variables
definitely pulled in and so on.
Previously, it would happen that under some circumstances we might no do
this when transitioning from root to root itself even though PAM was
enabled.
Fixes: #34682
Lennart Poettering [Thu, 24 Oct 2024 20:36:22 +0000 (22:36 +0200)]
Merge pull request #34875 from poettering/userdbctl-filter
userdbctl: add some basic client-side filtering
Lennart Poettering [Thu, 24 Oct 2024 08:50:16 +0000 (10:50 +0200)]
user-util: tighten shell validation a tiny bit
Mike Yuan [Thu, 24 Oct 2024 17:44:10 +0000 (19:44 +0200)]
Merge pull request #34799 from YHNdnzj/service-followups
core: follow-ups for live mount
Lennart Poettering [Wed, 23 Oct 2024 20:12:29 +0000 (22:12 +0200)]
ci: give new userdbctl some CI exposure
Lennart Poettering [Wed, 23 Oct 2024 20:07:05 +0000 (22:07 +0200)]
user-record: fix indentation
Lennart Poettering [Wed, 23 Oct 2024 20:34:34 +0000 (22:34 +0200)]
userdbctl: set shell/home cell type to TABLE_PATH
This only matters for sorting, and we currently don't support sorting by
path, hence this is of no real effect, but it certainly is more correct.
Lennart Poettering [Wed, 23 Oct 2024 19:44:24 +0000 (21:44 +0200)]
userdbctl: grey out nologin shell in tabular output
Lennart Poettering [Wed, 23 Oct 2024 19:36:06 +0000 (21:36 +0200)]
userdbctl: optionally hide UID range boundaries in output
Lennart Poettering [Wed, 23 Oct 2024 13:19:36 +0000 (15:19 +0200)]
userdbctl: add some basic client-side filtering
This adds some basic client-side user/group filtering to "userdbctl":
1. by uid/gid min/max
2. by user "disposition" (i.e. show only regular users with "userdbctl
user -R")
3. by fuzzy name (i.e. search by substring/levenshtein of user name,
real name, and other identifiers of the user/group record).
In the long run we also want to support this server side, but let's
start out with doing this client-side, since many backends won't support
server-side filtering anytime soon anyway, so we need it in either case.
Antonio Alvarez Feijoo [Thu, 24 Oct 2024 08:07:45 +0000 (10:07 +0200)]
veritysetup-generator: remove unused code
Antonio Alvarez Feijoo [Thu, 24 Oct 2024 08:07:28 +0000 (10:07 +0200)]
man/veritysetup-generator: document veritytab kernel command line option
Antonio Alvarez Feijoo [Thu, 24 Oct 2024 07:54:48 +0000 (09:54 +0200)]
man: fix links to veritysetup(8)
Yu Watanabe [Thu, 24 Oct 2024 07:42:48 +0000 (16:42 +0900)]
man: insert a comma before 'and'
Follow-up for
bd91f23acfecc92ede6965d752540a758b3e6c79.
Yu Watanabe [Thu, 24 Oct 2024 07:34:49 +0000 (16:34 +0900)]
Merge pull request #27916 from yuwata/test-execute-credstore
test: update permission of credstore
Yu Watanabe [Wed, 23 Oct 2024 08:10:33 +0000 (17:10 +0900)]
Revert "TEST-55-OOMD: workaround for kernel regression in 6.12-rcX"
This reverts commit
88bbf187a9b2ebe0732caa1e886616ae5f8186da.
The kernel regression has been hopefully fixed by
https://github.com/torvalds/linux/commit/
c6508124193d42bbc3224571eb75bfa4c1821fbb
which is included in 6.12-rc4.
Let's drop the workaround.
Anders Jonsson [Thu, 24 Oct 2024 00:56:39 +0000 (02:56 +0200)]
po: Translated using Weblate (Swedish)
Currently translated at 100.0% (253 of 253 strings)
Co-authored-by: Anders Jonsson <anders.jonsson@norsjovallen.se>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/sv/
Translation: systemd/main
Daan De Meyer [Tue, 22 Oct 2024 12:22:47 +0000 (14:22 +0200)]
docs: Mention that a local build might be required to use mkosi
Currently we need ukify with support for --profile and --join-profile
which isn't in an official release yet so mention that a local build
from source might be required.
Yu Watanabe [Wed, 23 Oct 2024 08:20:38 +0000 (17:20 +0900)]
man/network: suggest to not request IA_NA when received RA with Managed bit unset
Follow-up for
1f5a052963464755e87a075f6f4a8867b2199311.
Yu Watanabe [Wed, 23 Oct 2024 20:32:12 +0000 (05:32 +0900)]
Merge pull request #34834 from yuwata/protect-home-tmpfs-read-only
core/namespace: make ProtectHome=tmpfs makes /home and friends read-only as documented
Łukasz Stelmach [Wed, 23 Oct 2024 10:58:36 +0000 (12:58 +0200)]
core: don't forget about fallback_smack_process_label
Call setup_smack() also when only fallback_smack_process_label is set.
Fixes:
75689fb2d41f
Yu Watanabe [Sat, 19 Oct 2024 05:40:13 +0000 (14:40 +0900)]
core/namespace: replace MOUNT_PRIVATE_TMP_READ_ONLY with MOUNT_PRIVATE_TMP with .read_only = true
Yu Watanabe [Sat, 19 Oct 2024 03:46:05 +0000 (12:46 +0900)]
core/namespace: coding style cleanups
Yu Watanabe [Sat, 19 Oct 2024 05:38:08 +0000 (14:38 +0900)]
core/namespace: honor MountEntry.read_only, .options, and so on in static entries
Otherwise, ProtectHome=tmpfs makes /home/ and friends not read-only.
Also, mount options for /run/ specified in MountAPIVFS=yes are not
applied.
The function append_static_mounts() was introduced in
5327c910d2fc1ae91bd0b891be92b30379c7467b, but at that time, there were
neither .read_only nor .options in the struct. But, when later the
struct is extended, the function was not updated and they were not
copied from the static table.
The fields has been used in static tables since
e4da7d8c796a1fd11ecfa80fb8a48eac9e823f06, and also in
94293d65cd4125347e21b3e423d0e245226b1be2.
Fixes #34825.
Integral [Wed, 23 Oct 2024 08:32:02 +0000 (16:32 +0800)]
refactor: replace sizeof in loop with ELEMENTSOF & FOREACH_ELEMENT (#34863)
Lennart Poettering [Wed, 23 Oct 2024 08:27:04 +0000 (10:27 +0200)]
update TODO
Yu Watanabe [Wed, 23 Oct 2024 08:23:26 +0000 (17:23 +0900)]
Yu Watanabe [Wed, 23 Oct 2024 08:22:22 +0000 (17:22 +0900)]
Yu Watanabe [Wed, 23 Oct 2024 08:13:55 +0000 (17:13 +0900)]
Lennart Poettering [Wed, 23 Oct 2024 08:25:18 +0000 (10:25 +0200)]
Merge pull request #34850 from poettering/openat-report-new-tweaks
openat_report_new() tweaks
Ronan Pigott [Tue, 22 Oct 2024 15:20:17 +0000 (08:20 -0700)]
network: adjust log message about DNR
The only possible error return in this position is -ENODATA, which is
not interesting.
Lennart Poettering [Wed, 23 Oct 2024 08:24:23 +0000 (10:24 +0200)]
Merge pull request #34861 from poettering/can-idle
logind: introduce CanIdle/CanLock properties on logind session dbus objects
Luca Boccassi [Tue, 22 Oct 2024 16:23:22 +0000 (17:23 +0100)]
mkosi: update debian commit reference
*
07a294d0c6 Do not mask systemd-gpt-auto-generator in upstream CI builds
*
5636398bf7 Backport patch to fix test failures with tzdata 2024b-1
*
354ded4946 Update changelog for 256.7-2 release
*
e38c7c5345 Backport fixes for upstream autopkgtest suite
*
249676834c Disable utmp support, not y2038 safe
*
822d44da42 initramfs-tools: support missing /etc/udev/udev.conf
*
ad71ebf700 systemd-boot: depend on systemd for kernel-install
*
5bf7008ef8 d/systemd.postinst: do not restart systemd-binfmt.service if masked
*
58d5aa1b41 d/rules: mask systemd-gpt-auto-generator on Ubuntu
*
481987d85c Update changelog for 256.7-1 release
*
ce7f3d4b43 Revert "autopkgtest: skip TEST-64-UDEV-STORAGE due to qemu crash"
*
7007e73b22 Mark dependencies on clang and bpftool as :native
*
0e120cf704 Update upstream source from tag 'upstream/256.7'
|\
| *
914aae055c New upstream version 256.7
*
fcea89cb00 d/t/upstream: honor /etc/apt configured by autopkgtest
Mike Yuan [Tue, 22 Oct 2024 21:46:33 +0000 (23:46 +0200)]
Merge pull request #34860 from enr0n/varlinkctl-fixes
Fix varlinkctl output with `--more`
Luca Boccassi [Tue, 22 Oct 2024 16:04:41 +0000 (17:04 +0100)]
logind: allow read/write to char-hvc devices
virtio console uses /dev/hvc* so we need access to write wall
messages
Mike Yuan [Wed, 16 Oct 2024 14:30:10 +0000 (16:30 +0200)]
core: clean up errors for live mounting
* Use SD_BUS_ERROR_NOT_SUPPORTED where appropriate
* Use Service object in service_can_live_mount()
* Include errno in bus error message
Mike Yuan [Wed, 16 Oct 2024 19:41:20 +0000 (21:41 +0200)]
core/service: fix one wording
Mike Yuan [Wed, 16 Oct 2024 19:19:43 +0000 (21:19 +0200)]
core/service: add missing serialization for Service.live_mount_result
Mike Yuan [Tue, 22 Oct 2024 17:30:50 +0000 (19:30 +0200)]
core/service: call service_enter_running() if live mount fails
service_enter_running() would re-arm timer for RuntimeMaxSec=,
hence it should be called instead of disabling timer completely
when live mount operation fails, in a similar fashion as
service_enter_reload_by_notify().
Mike Yuan [Wed, 16 Oct 2024 19:18:04 +0000 (21:18 +0200)]
core/service: introduce service_live_mount_finish()
that combines updating Service.live_mount_result and
service_mount_request_reply()
Mike Yuan [Wed, 16 Oct 2024 19:16:23 +0000 (21:16 +0200)]
core/service: place occurrences of SERVICE_MOUNTING closer to reload states
Mike Yuan [Wed, 16 Oct 2024 16:59:45 +0000 (18:59 +0200)]
core/unit: put the reload job back to queue if unit is refreshing
Mike Yuan [Tue, 22 Oct 2024 17:18:10 +0000 (19:18 +0200)]
shared/bus-util: debug log when falling back to session bus
Follow-up for
d0316b7a0d356ba12325ce5a00b0cbe0bc359461
Mike Yuan [Sat, 19 Oct 2024 16:56:50 +0000 (18:56 +0200)]
basic/fs-util: move unlink_tempfilep() to tmpfile-util
Mike Yuan [Sat, 19 Oct 2024 16:29:36 +0000 (18:29 +0200)]
man/org.freedesktop.systemd1: complete version info for ManagedOOMMemoryPressureDurationUSec
Follow-up for
63d4c4271ca529f8357a84cbc075170fffdb3de8
Some unit types were left out.
Lennart Poettering [Tue, 22 Oct 2024 16:12:20 +0000 (18:12 +0200)]
logind: also check session class in session_get_idle_hint()
Lennart Poettering [Tue, 22 Oct 2024 16:11:25 +0000 (18:11 +0200)]
logind: use RET_GATHER() at one more place
Lennart Poettering [Tue, 22 Oct 2024 16:08:19 +0000 (18:08 +0200)]
logind: add CanIdle + CanLock dbus properties to session object
Clients should be able to know if the idle logic is available on a
session without secondary knowledge about the session class. Let's hence
expose a property for that.
Similar for the screen lock concept.
Fixes: #34844
Nick Rosbrook [Tue, 22 Oct 2024 16:09:55 +0000 (12:09 -0400)]
varlinkctl: set SD_JSON_FORMAT_FLUSH when --more is set
This makes it possible to process continuous replies with jq etc.
Nick Rosbrook [Tue, 22 Oct 2024 16:03:50 +0000 (12:03 -0400)]
varlinkctl: do not clobber format flags in verb_call
Currently, when SD_JSON_FORMAT_OFF is set in verb_call, the json format
flags are set to SD_JSON_FORMAT_PRETTY_AUTO|SD_JSON_FORMAT_COLOR_AUTO,
rather than or'ing those flags in. This means that other flags that may
have been set, e.g. SD_JSON_FORMAT_SEQ when --more is set, will be
clobbered.
Fix this by masking SD_JSON_FORMAT_OFF out, and then or'ing the new
flags in.
Lennart Poettering [Tue, 22 Oct 2024 16:00:12 +0000 (18:00 +0200)]
Merge pull request #34848 from yuwata/network-dhcpv6-do-not-request-ia-pd-on-info-req
network/dhcp6: do not request IA_PD on information requesting mode
Ronan Pigott [Mon, 21 Oct 2024 06:16:49 +0000 (23:16 -0700)]
resolved: validate noerror response for CNAMEs
CNAME doesn't exist at the zone apex. When we get an unsigned noerror
response to a direct query for a CNAME record, we don't yet know if this
name is zone apex. We already request the correct DS record in this
case, but previously skipped it at validation time, causing the answer
to appear bogus. Make sure to also consider the DS record for the query
name for negative replies.
Lennart Poettering [Tue, 22 Oct 2024 15:49:40 +0000 (17:49 +0200)]
fs-util: move attempts counter in openat_report_new() into loop
Lennart Poettering [Tue, 22 Oct 2024 15:47:22 +0000 (17:47 +0200)]
label: move label_ops_reset() up a bit
Let#s move it close to label_ops_set(), since it is somewhat symmetric
to it.
Lennart Poettering [Tue, 22 Oct 2024 15:47:16 +0000 (17:47 +0200)]
label: add missing assert() to label_ops_set()
Lennart Poettering [Tue, 22 Oct 2024 08:25:26 +0000 (10:25 +0200)]
shared: get rid of fileio-label.[ch]
Move the renaming function to reboot-util.h (since it writes out
/run/nologin at shutdown), and let's get rid of fileio-label.[ch] now
that it serves no purpose anymore.
Lennart Poettering [Tue, 22 Oct 2024 08:19:03 +0000 (10:19 +0200)]
fileio: port write_string_file_full() to openat_report_new()
This brings two benefits: we will label the created file only if it is
actually created, and we can correctly delete any file we create again
on failure.
Lennart Poettering [Tue, 22 Oct 2024 08:09:20 +0000 (10:09 +0200)]
fileio: port write_string_file() to LabelOps, and thus add WRITE_STRING_FILE_LABEL flag
Given that we have the LabelOps abstraction these days, we can teach
write_string_file() to use it, which means we can get rid of
fileio-label.[ch] as a separate concept.
(The only reason that fileio-label.[ch] exists independently of
fileio.[ch] was that the former linekd to libselinux potentially, and
thus had to be in src/shared/ while the other always was in src/basic/.
But the LabelOps vtable provides us with a nice work-around)
Lennart Poettering [Mon, 21 Oct 2024 20:58:25 +0000 (22:58 +0200)]
fs-util: tweak how openat_report_new() operates when O_CREAT is used on a dangling symlink
One of the big mistakes of Linux is that when you create a file with
open() and O_CREAT and the file already exists as dangling symlink that
the symlink will be followed and the file created that it points to.
This has resulted in many vulnerabilities, and triggered the creation of
the O_MOFOLLOW flag, addressing the problem.
O_NOFOLLOW is less than ideal in many ways, but in particular one: when
actually creating a file it makes sense to set, because it is a problem
to follow final symlinks in that case. But if the file is already
existing, it actually does make sense to follow the symlinks. With
openat_report_new() we distinguish these two cases anyway (the whole
function exists only to distinguish the create and the exists-already
case after all), hence let's do something about this: let's simply never
create files "through symlinks".
This can be implemented very easily: just pass O_NOFOLLOW to the 2nd
openat() call, where we actually create files.
And then basically remove
0dd82dab91eaac5e7b17bd5e9a1e07c6d2b78dca
again, because we don't need to care anymore, we already will see ELOOP
when we touch a symlink.
Note that this change means that openat_report_new() will thus start to
deviate from plain openat() behaviour in this one small detail: when
actually creating files we will *never* follow the symlink. That should
be a systematic improvement of security.
Fixes: #34088
Lennart Poettering [Mon, 21 Oct 2024 20:43:18 +0000 (22:43 +0200)]
fs-util: always call label post ops in xopenat_full(), in both success and error path
For SELinux it is essential that we reset the file creation label both
in the success and in the error path, hence do so.
Moreover, when calling the label post ops do it if possible with the
opened fd of the inode itself, rather than always going via its path,
simply to reduce the attack surface.
Lennart Poettering [Mon, 21 Oct 2024 20:40:52 +0000 (22:40 +0200)]
fs-util: don't second guess openat_report_new() return values
If openat_report_new() fails, then 'made_file' will be false, as no file
was created, hence there's no need to skip the unlinkat() explicitly
early, given that we check for 'made_file' anyway in the error path. The
extra error code checks are hence entirely redundant.
Lennart Poettering [Mon, 21 Oct 2024 20:07:56 +0000 (22:07 +0200)]
label: tweak LabelOps post() hook to take "created" boolean
We have two distinct implementations of the post hook.
1. For SELinux we just reset the selinux label we told the kernel
earlier to use for new inodes.
2. For SMACK we might apply an xattr to the specified file.
The two calls are quite different: the first call we want to call in all
cases (failure or success), the latter only if we actually managed to
create an inode, in which case it is called on the inode.
Lennart Poettering [Mon, 21 Oct 2024 19:56:05 +0000 (21:56 +0200)]
fs-util: always go through the unlink cleanup paths in xopenat_full()
We didn't go through it at all if label_ops_post() failed.
Lennart Poettering [Mon, 21 Oct 2024 19:54:37 +0000 (21:54 +0200)]
fs-util: remove misplaced RET_NERRNO()
Daan De Meyer [Tue, 22 Oct 2024 11:37:59 +0000 (13:37 +0200)]
Merge pull request #34851 from DaanDeMeyer/medium
bus-util: Return ENOMEDIUM if XDG_RUNTIME_DIR is unset
Yu Watanabe [Tue, 22 Oct 2024 06:32:12 +0000 (15:32 +0900)]
TEST-02-UNITTESTS: reuse $TEST_MATCH_SUBTEST to specify unit tests to be run
Then, we can easily test specific unit tests in qemu or container.
Yu Watanabe [Mon, 5 Jun 2023 05:18:47 +0000 (14:18 +0900)]
test-execute: update permission of credstore
Follow-up for
40fb9eebbc075ce1e63100386d2c5f177ad7d738.
Daan De Meyer [Tue, 22 Oct 2024 10:32:02 +0000 (12:32 +0200)]
bus-util: Fix bus_log_connect_error()
Daan De Meyer [Tue, 22 Oct 2024 09:12:17 +0000 (11:12 +0200)]
bus-util: Special case when DBUS_SESSION_BUS_ADDRESS is set and XDG_RUNTIME_DIR isn't
We noticed some failures because we have code that connects to user
managers by setting DBUS_SESSION_BUS_ADDRESS without setting XDG_RUNTIME_DIR.
If that's the case, connect to the user session bus instead of the
private manager bus as we can't connect to the latter if XDG_RUNTIME_DIR
is not set.
Daan De Meyer [Tue, 22 Oct 2024 08:59:27 +0000 (10:59 +0200)]
bus-util: Return ENOMEDIUM if XDG_RUNTIME_DIR is unset
bus_log_connect_error() checks for ENOMEDIUM, not ENXIO.
Lennart Poettering [Tue, 22 Oct 2024 07:06:56 +0000 (09:06 +0200)]
Merge pull request #34761 from ikruglov/ikruglov/io-systemd-Machine-GetAddresses
machine: add Addresses, OSRelease, and UIDShift fields in varlink io.systemd.Machine.List output
Lennart Poettering [Tue, 22 Oct 2024 07:05:36 +0000 (09:05 +0200)]
Merge pull request #30952 from rpigott/resolved-dnr
RFC9463: Discovery of Network-designated Resolvers
Luca Boccassi [Mon, 21 Oct 2024 16:31:09 +0000 (17:31 +0100)]
test: CET/EET are deprecated, use Europe/Berlin and Kyiv
The links moved to the legacy dataset so they won't be available by
default, so stop using them and just use the city ones instead
Yu Watanabe [Mon, 21 Oct 2024 19:28:27 +0000 (04:28 +0900)]
man: suggest to use DHCPv6Client= when upstream provides RA with the Managed bit unset
Follow-up for
daf9f42f9183c206c0f8308efece019797e95e89.
Yu Watanabe [Sun, 20 Oct 2024 19:41:57 +0000 (04:41 +0900)]
network/dhcp6: do not request IA_PD when running in the other-information mode
This reverts the following commits:
-
180cc5421d9712fb95a6bbc725dc8ba459360c8b
"sd-dhcp6-client: allow to request IA_PD on information requesting mode"
-
cf7a403e470368049165ecff7ac7686928778d7c
"sd-dhcp6-lease: adjust information refresh time with lifetime of IA_PD"
-
1918eda30d12e1ba3ee55921c18ec53267463e24
"network/dhcp6: process hostname and IA_PD on information requesting mode"
As per discussion in #34299,
https://github.com/systemd/systemd/issues/34299#issuecomment-
2425153221
the offending commits violate RFC 8415 section 18.2.6:
> The client uses an Information-request message to obtain
> configuration information without having addresses and/or delegated
> prefixes assigned to it.
Daan De Meyer [Mon, 21 Oct 2024 16:55:33 +0000 (18:55 +0200)]
Merge pull request #34628 from DaanDeMeyer/measure
Rework TEST-86-MULTI-PROFILE-UKI + associated bugfixes
Ronan Pigott [Wed, 26 Jun 2024 00:01:59 +0000 (17:01 -0700)]
resolve: move sd-* api into libsystemd-network
This duplicates the svc param constants for the benefit of the
resolved-core library.
Ronan Pigott [Thu, 4 Apr 2024 02:04:33 +0000 (19:04 -0700)]
ndisc: implement ndisc_option_build_encrypted_dns
This is only used by the fuzzer so far.
Ronan Pigott [Wed, 3 Apr 2024 20:16:05 +0000 (13:16 -0700)]
network: add dnr resolvers to networkctl status json output
Ronan Pigott [Thu, 25 Jan 2024 06:49:03 +0000 (23:49 -0700)]
test/fuzz: add dnr packets
The structure of DNR options is considerably more complicated than most
DHCP options, and as a result the fuzzer has poor coverage of these code
paths.
This adds some DNR packets to the fuzzing corpus, not with the intent of
capturing some specific edge case, but with the intent to rapidly
improve the fuzzers' coverage of these codepaths by giving it a valid
example to begin with.
Also include an ndisc router advert with a few Encrypted DNS options,
for the same purpose.
Ronan Pigott [Mon, 22 Jan 2024 21:37:42 +0000 (14:37 -0700)]
network: Serialize ipv6ra DNR
Serialize DNR servers acquired by ipv6ra option, same as the V4/V6 DNR
DHCP options.
Ronan Pigott [Mon, 22 Jan 2024 21:37:42 +0000 (14:37 -0700)]
network: Introduce IPv6RA UseDNR= option
Same as the DHCP v4/v6 options, this controls the use of DNR received
from ipv6ra.
Ronan Pigott [Sat, 20 Jan 2024 01:26:26 +0000 (18:26 -0700)]
ndisc: Parse RFC9463 encrypted DNS (DNR) option
This option is equivalent to the V4/V6 DNR options for DHCP.
Ronan Pigott [Thu, 18 Jan 2024 02:35:20 +0000 (19:35 -0700)]
test-network: add DHCPv6 DNR test
Same as the DHCPv4 test.
Ronan Pigott [Thu, 18 Jan 2024 02:27:21 +0000 (19:27 -0700)]
network: Serialize DHCPv6 DNR servers
This serializes DNR servers acquired by V6_DNR option, equivalent to the
V4_DNR option.
Ronan Pigott [Thu, 18 Jan 2024 01:16:47 +0000 (18:16 -0700)]
network: Introduce UseDNR DHCPv6 option
This is equivalent to the DHCPv4 option introduced earlier.
Ronan Pigott [Wed, 17 Jan 2024 23:49:02 +0000 (16:49 -0700)]
network: Parse RFC9463 DHCPv6 DNR option
Implement the parsing for V6_DNR DHCPv6 option. This does the same as
the DHCP V4_DNR option.
Ronan Pigott [Tue, 23 Jan 2024 20:12:30 +0000 (13:12 -0700)]
dhcp6: use dns_name_from_wire_format
Convert some of the option parsing to use dns_name_from_wire_format,
introduced earlier. No change in behavior intended.
Ronan Pigott [Thu, 25 Jan 2024 00:53:35 +0000 (17:53 -0700)]
test-dhcp6: terminate fqdn option
The encoded fqdn in this option must be properly terminated. We will
soon validate that this field is correctly encoded, so correct it in the
test.
Ronan Pigott [Tue, 16 Jan 2024 23:07:54 +0000 (16:07 -0700)]
test-network: add test for DHCPv4 DNR
This will test that networkd/resolved can understand the V4_DNR DHCP
option.
Ronan Pigott [Tue, 16 Jan 2024 07:04:41 +0000 (00:04 -0700)]
network: Serialize DNR servers
Implement serialization/deserialization for DNR servers. This re-uses
the string format in place for user configuration of DoT servers, and as
a consequence non-DoT servers are discarded when recording the link
configuration, for correctness.
This also enables sd-resolved to use these servers as it would other DNS
servers.