]> git.ipfire.org Git - thirdparty/systemd.git/log
thirdparty/systemd.git
8 months agomkosi: Bump to Fedora 42
Daan De Meyer [Tue, 18 Mar 2025 19:35:59 +0000 (20:35 +0100)] 
mkosi: Bump to Fedora 42

Beta was just released, let's switch to Fedora 42 which coincidentally
also has a crucial fix for its nsswitch.conf to make the next commits
actually work.

(cherry picked from commit 9165d924069001a4968961e13892c059ffc7a30c)

8 months agoTEST-73-LOCALE: do not unnecessarily restart systemd-localed
Yu Watanabe [Thu, 13 Mar 2025 03:11:40 +0000 (12:11 +0900)] 
TEST-73-LOCALE: do not unnecessarily restart systemd-localed

It is not necessary to clear previous keymap assignment, as
`localectl set-keymap` will anyway overwrite the previous assignment.

This drops the unnecessary restart of systemd-localed in the loop.
The mkosi test image contains about 500~700 keymaps. The test
performance is greatly improved by reducing the number of restarts,
especially when the test is running with sanitizers.

On Fedora 41 with sanitizers,
Before:
1/1 systemd:integration-tests / TEST-73-LOCALE OK             1157.50s
After:
1/1 systemd:integration-tests / TEST-73-LOCALE OK              104.43s

(cherry picked from commit d8a353552a924592d41a1538ee95d516c9facf30)

8 months agoci/mkosi: enable sanitizers on Fedora 41
Yu Watanabe [Mon, 10 Mar 2025 16:54:28 +0000 (01:54 +0900)] 
ci/mkosi: enable sanitizers on Fedora 41

It seems the recent update of LLVM package in Fedora rawhide breaks
sanitizers, and udevd freezes after false-positive (I guess) issue is
detected:

systemd-udevd[2646]: =================================================================
systemd-udevd[2646]: ==2646==ERROR: AddressSanitizer: stack-buffer-underflow on address 0x7ffc3a642660 at pc 0x555627ac022b bp 0x7ffc3a6422b0 sp 0x7ffc3a6422a8
systemd-udevd[2646]: READ of size 8 at 0x7ffc3a642660 thread T0 ((udev-worker))

llvm-19.1.7-11.fc43 worked fine, but llvm-20.1.0-1.fc43 does not.
To avoid the issue, let's enable sanitizer on Fedora 41, and disable it
on Fedora rawhide.

Closes #36678.

(cherry picked from commit 9670922d4480af35bf6ab20ef5de3a41b4d48c4d)

8 months agomkosi: Skip other build scripts if we're running clangd
Daan De Meyer [Fri, 7 Mar 2025 15:05:49 +0000 (16:05 +0100)] 
mkosi: Skip other build scripts if we're running clangd

(cherry picked from commit 7c94fd1db6ef482f2037dc38838b896d204e7382)

8 months agomkosi: Switch to --rerun-build-scripts in mkosi.clangd
Daan De Meyer [Fri, 7 Mar 2025 14:56:24 +0000 (15:56 +0100)] 
mkosi: Switch to --rerun-build-scripts in mkosi.clangd

(cherry picked from commit f0efc7ef346f4217e32e01d5d52a0258f4bfae22)

8 months agomkosi: Disable BuildSourcesEphemeral=
Daan De Meyer [Thu, 6 Mar 2025 22:20:59 +0000 (23:20 +0100)] 
mkosi: Disable BuildSourcesEphemeral=

Let's stop using BuildSourcesEphemeral= and instead make sure we don't
generate any auxiliary files during the mkosi build process.

We achieve this through a combination of trap to remove any new files
we create and bind mounts from /tmp over existing files whenever we need
to modify an existing file.

We also add a CI step to ensure we don't regress

(cherry picked from commit 2e6a041376a60f26b297f92a41df3125f75c62fb)

8 months agomkosi: update fedora commit reference
Daan De Meyer [Fri, 7 Mar 2025 12:38:00 +0000 (13:38 +0100)] 
mkosi: update fedora commit reference

38b41a729e Clean up debuginfo files as well in %clean
7bc5883654 Fix missing question mark
d22561d59e Also drop auxiliary files related to sysusers compat
e825459f2d Change python-zstd depenedency to python-zstandard
0a3907745e Version 257.4
1bdfa29ce2 Neuter sysusers macros

(cherry picked from commit b9ad203e05696bdbae30cce84e4c30f50b15bd6c)

8 months agomkosi: update fedora commit reference
Daan De Meyer [Wed, 5 Mar 2025 20:27:17 +0000 (21:27 +0100)] 
mkosi: update fedora commit reference

4ab2a9e539 Drop old self-Obsoletes and provides
ec182495e7 Drop libbpf versioned dependency version to 1.4.7
1f8d2b0ebd Make self-obsoletes for the sysusers split conditional
0d95af264f Include epoch in versioned libbpf dependency
8230f501b6 Make sure we pull in libbpf >= 1.5.0 if libbpf is installed

(cherry picked from commit ba6a152000191bacf2c5a0470719d6a39c5e15e2)

8 months agomkosi: Don't install dnf anymore on Fedora
Daan De Meyer [Wed, 5 Mar 2025 19:07:59 +0000 (20:07 +0100)] 
mkosi: Don't install dnf anymore on Fedora

We have dnf5 on Fedora, no need to install dnf there anymore

(cherry picked from commit 4435dd7c72f180400afea00a454a453993880a3c)

8 months agoudev: make udevadm and friends not warn about unknown settings
Yu Watanabe [Fri, 21 Mar 2025 00:54:45 +0000 (09:54 +0900)] 
udev: make udevadm and friends not warn about unknown settings

Without this change, when e.g. event_timeout= is specified in udev.conf,
udevadm and friends which loads udev.conf warn about unknown key:
===
$ udevadm info /sys/class/net/lo
/run/udev/udev.conf.d/test-17.conf:1: Unknown key 'event_timeout', ignoring.
/run/udev/udev.conf.d/test-17.conf:2: Unknown key 'timeout_signal', ignoring.
===

Follow-up for 07f5e35fe7967c824a87f18a3a1d3c22e5be70f5 (v256).

(cherry picked from commit 90670111a9f18aff7d37fa3ec3bc5b73ce3b784d)

8 months agoedit-util: don't leave custom editor args around if we shall fall back
Mike Yuan [Thu, 20 Mar 2025 16:01:19 +0000 (17:01 +0100)] 
edit-util: don't leave custom editor args around if we shall fall back

Also, let's complain loudly if the editor acquired from envvar
is not present.

Fixes #36796

(cherry picked from commit d2e49d9389f390740ce5a1f48e944bb55036bbfe)

8 months agomemory-util: make mempcpy_typesafe nestable
Mike Yuan [Thu, 20 Mar 2025 16:27:39 +0000 (17:27 +0100)] 
memory-util: make mempcpy_typesafe nestable

(cherry picked from commit b062cf19f4a185afd2d86ccf8a85d77bba6f93e6)

8 months agocgroup: whenever we migrate a PID to a unit, explicitly drop unit from empty notifica...
Lennart Poettering [Wed, 19 Mar 2025 15:54:27 +0000 (16:54 +0100)] 
cgroup: whenever we migrate a PID to a unit, explicitly drop unit from empty notification queue

A unit might be pending in the empty queue still when we add a PID to
the cgroup. At that point, let's explicitly remove the unit from that
queue.

Fixes: #36781
(cherry picked from commit bb160976b0d2d84d3b23149ce6a4d5b89a665643)

8 months agosd-varlink: fix overwrite of loop count
Yu Watanabe [Tue, 18 Mar 2025 16:33:09 +0000 (01:33 +0900)] 
sd-varlink: fix overwrite of loop count

Fixes a bug introduced by 206504a594492f4b97259bbe345dde4e520df7dc (v255).

(cherry picked from commit a65d2de6d163daae715aa2a05869dbe65d2a0f01)

8 months agoinitctl: fix error handling
Yu Watanabe [Tue, 18 Mar 2025 16:32:12 +0000 (01:32 +0900)] 
initctl: fix error handling

Fixes a bug introduced by cc090ca7fec93cd6b41bd7a756cd5fe32df44764 (v246).

(cherry picked from commit 59cb9b12abc7efb714d15d357c96bd86ef2ddafc)

8 months agosd_bus_open_user_machine(): Don't shortcut without necessary env
Daan De Meyer [Mon, 17 Mar 2025 11:28:37 +0000 (12:28 +0100)] 
sd_bus_open_user_machine(): Don't shortcut without necessary env

Don't shortcut if we don't have the necessary environment variables
set in sd_bus_open_user_machine().

(cherry picked from commit 9e34c34b7b027da24b084a58246c1d88bdbcc817)

8 months agotest-network: check that network configuration is stable with KeepConfiguration=yes
Matteo Croce [Wed, 12 Mar 2025 13:36:14 +0000 (14:36 +0100)] 
test-network: check that network configuration is stable with KeepConfiguration=yes

Check that when networkd restarts, and the network configures
KeepConfiguration=yes, the network configuration is never changed.

Ensure this by dumping the `ip monitor` output when networkd is restarting.

Co-authored-by: Yu Watanabe <watanabe.yu+github@gmail.com>
(cherry picked from commit 912a48572de1411cff2964452e0d7a021b43921f)

8 months agonetwork: do not remove static routes on other interfaces that are currently in the...
Yu Watanabe [Sat, 15 Mar 2025 00:38:09 +0000 (09:38 +0900)] 
network: do not remove static routes on other interfaces that are currently in the pending state

Otherwise, even if .network file has KeepConfiguration=yes, routes on
an interfaces may be removed on restart.

Fixes a bug introduced by 8d01e44c1f0e00b414d36bd1b46ecff548242208.

(cherry picked from commit cf28def391d1cc06c9757d2413cd7a31b38f59e1)

8 months agoudevadm: check number of passed arguments
Lennart Poettering [Fri, 14 Mar 2025 10:43:07 +0000 (11:43 +0100)] 
udevadm: check number of passed arguments

We didn't check the number of arguments first, hence ended up outputting
some ugly complaints with `(null)` in a format string. And what's worse
accepted any number of arguments, where we'd ignore all but the first
two though.

(cherry picked from commit e5dfe2cd8d32c3ddd3ca6763dbbe2d0ea2ab61aa)

8 months agonsresource: fix GID check in io.systemd.UserDatabase.GetGroupRecord method
Yu Watanabe [Wed, 12 Mar 2025 18:27:31 +0000 (03:27 +0900)] 
nsresource: fix GID check in io.systemd.UserDatabase.GetGroupRecord method

Fixes a bug in 8aee931e7ae1adb01eeac0e1e4c0aef6ed3969ec (v256).

(cherry picked from commit e0111277e4a27409874863b13ad3c2b3726c1bd5)

8 months agogetty-generator: don't use "3270!tty1" when instantiating serial-getty@.service on...
Franck Bui [Wed, 12 Mar 2025 16:51:39 +0000 (17:51 +0100)] 
getty-generator: don't use "3270!tty1" when instantiating serial-getty@.service on s390x

Path of the 3270 console in /sys is "/sys/class/tty/3270!tty1" but its device
node is "/dev/3270/tty1".

(cherry picked from commit dbe61d9ec7d9c197856756378af6add930b5a5a9)

8 months agotest-execute: prominently show which test we are about to enter
Lennart Poettering [Thu, 13 Mar 2025 10:49:13 +0000 (11:49 +0100)] 
test-execute: prominently show which test we are about to enter

(cherry picked from commit 66c2a2e42ac5d6cbd526f4bba31dcd3218550cde)

8 months agoexecute: add some minor debug logging
Lennart Poettering [Thu, 13 Mar 2025 10:43:08 +0000 (11:43 +0100)] 
execute: add some minor debug logging

(cherry picked from commit 2544075c0bb57b475b28a8f4193f2640b9c8ab29)

8 months agopid1: don't connect to oomd in test runs
Lennart Poettering [Thu, 13 Mar 2025 10:13:44 +0000 (11:13 +0100)] 
pid1: don't connect to oomd in test runs

(cherry picked from commit ec5bcf0b699bcd9d6cc597a73317f0540031ad20)

8 months agoanalyze: don't connect to bus from analyze test run
Lennart Poettering [Wed, 12 Mar 2025 17:19:34 +0000 (18:19 +0100)] 
analyze: don't connect to bus from analyze test run

This thing should not be "live", hence don't try to connect to the bus,
or bind the private bus socket.

Fixes: #36540
(cherry picked from commit 71a737d68db8c8a72fdc076d0ec87f43d3ecd7a1)

8 months agomanager: explicitly create our private runtime directory
Lennart Poettering [Thu, 13 Mar 2025 10:43:46 +0000 (11:43 +0100)] 
manager: explicitly create our private runtime directory

So far /run/systemd/ was created as side-effect of initializing the
D-Bus client/server. But in one of the next commits we'll suppress
connecting to D-Bus in test runs, hence let's move the logic our of the
D-Bus code and into manager_startup().

Then, also drop creating it again and again in PID 1 at various places,
and just rely on it to exist.

(cherry picked from commit e75fbee6248736d2a71aa96438b495887ef761ea)

8 months agoboot: fallback to unrestricted allocation if initrd allocation doesn't fit below...
Lennart Poettering [Wed, 12 Mar 2025 19:14:40 +0000 (20:14 +0100)] 
boot: fallback to unrestricted allocation if initrd allocation doesn't fit below 4g (#36715)

Fixes: #36706
(cherry picked from commit c5a50467921f615846b3bbe3c3ff592953a6163a)

8 months agoumount: do not move busy network mounts
Antonio Alvarez Feijoo [Mon, 10 Mar 2025 11:21:26 +0000 (12:21 +0100)] 
umount: do not move busy network mounts

If a network mount returns EBUSY on umount, the logic introduced in
6dc68a00cfc816678fd713b12ae2a4cf2ae6da85 causes shutdown to hang indefinitely on
`fstatat()` (i.e., within `is_dir(m->path, true)`). Hence, skip this logic for
network mounts (following the same motivation we use to skip read-only mounts in
this kind of file systems).

Fixes 6dc68a00cfc816678fd713b12ae2a4cf2ae6da85

(cherry picked from commit cef2181cda87cbecd6e92f6d7a3bb8556067a88e)

8 months agocore/main: correct retval for reexec/switch-root/soft-reboot
Mike Yuan [Wed, 5 Mar 2025 17:35:50 +0000 (18:35 +0100)] 
core/main: correct retval for reexec/switch-root/soft-reboot

For these objectives we ought to execve() at the end, i.e. if we
ever hit the return path something went wrong in do_reexecute().
Let's properly report that via retval.

(cherry picked from commit 590e0e3bacb012bc86ff46f8dbe3f1b415e9cafd)

8 months agocore/main: preemptively check existence of init only if we're switching root
Mike Yuan [Sat, 8 Mar 2025 19:09:58 +0000 (20:09 +0100)] 
core/main: preemptively check existence of init only if we're switching root

Follow-up for aaa27e2e21c04339914f26b7125789087eb51166

The commit described about system potentially becoming undebuggable
after switching into broken root or whatnot. But notably we can never
activate emergency.target after do_reexecute() failure, since the Manager
has been destructed. Plus, for a normal reexecution the fallback shell logic
triggered on non-existent /sbin/init is kinda useful. Let's hence guard
the extra check behind switch-root.

Also, move the check below /run/nextroot/ detection.

(cherry picked from commit 93e19483dc9fae94d713d036ecee669450bd002d)

8 months agocore/main: assign mac_init() retval to r
Mike Yuan [Wed, 5 Mar 2025 17:22:19 +0000 (18:22 +0100)] 
core/main: assign mac_init() retval to r

If it fails, we'd submit the errno to supervisor via sd_notify() later.

(cherry picked from commit 550f4718bc6b11d8801af3b7eb888aa4ba0fdc90)

8 months agocore/main: log about save_env() error
Mike Yuan [Sat, 8 Mar 2025 19:04:17 +0000 (20:04 +0100)] 
core/main: log about save_env() error

(cherry picked from commit eda75b2cb27f171130191d1613c04c9d5e929efd)

8 months agomeson: bump version to 257.4 v257.4
Luca Boccassi [Thu, 6 Mar 2025 14:38:30 +0000 (14:38 +0000)] 
meson: bump version to 257.4

8 months agotest: Connect test unit to console when running interactively
Daan De Meyer [Mon, 3 Mar 2025 11:35:11 +0000 (12:35 +0100)] 
test: Connect test unit to console when running interactively

When running interactively, let's connect the test unit directly
to the console. This enables adding "bash" anywhere within an
integration test to get a shell within the test environment.

(cherry picked from commit fe7413d1955bbf0f8fe869543c423025a22a4671)

8 months agotest: Disable status messages when we start running a test
Daan De Meyer [Mon, 3 Mar 2025 11:33:56 +0000 (12:33 +0100)] 
test: Disable status messages when we start running a test

As soon as we start running a test, we want pid 1 to stop showing
status messages so let's tell pid 1 to stop showing status messages.

(cherry picked from commit 070de658a9f2bf48d26035ddbe861f79dfff2be4)

8 months agotest: Move getty-pre.target logic into integration-test-wrapper.py
Daan De Meyer [Mon, 3 Mar 2025 10:51:13 +0000 (11:51 +0100)] 
test: Move getty-pre.target logic into integration-test-wrapper.py

Also pull in getty-pre.target via Wants= so it actually gets pulled
into the transaction.

(cherry picked from commit 854a8c21d00e070bffd0c754812b29c5a4acd324)

8 months agotest: Check stdin for interactivity, not stderr
Daan De Meyer [Mon, 3 Mar 2025 10:44:42 +0000 (11:44 +0100)] 
test: Check stdin for interactivity, not stderr

(cherry picked from commit c9a50ebd8f2142808fca45dc2acff8ddc391cf7e)

8 months agonetwork: Use RTNH_COMPARE_MASK in route_can_update() (#36585)
Daan De Meyer [Mon, 3 Mar 2025 20:00:33 +0000 (21:00 +0100)] 
network: Use RTNH_COMPARE_MASK in route_can_update() (#36585)

Let's only compare flags that can be set by userspace and not all flags.

Fixes a bug introduced by 7027cdbd79c26d5a8890759a37d70165c8aeb214 (v256).
Fixes #36544

(cherry picked from commit 9fd25fd3ce4012e737688f0f1f3400c3e21c99f7)

8 months agodns-stream: only read DNS packet data if we identified the peer properly
Lennart Poettering [Mon, 3 Mar 2025 23:17:21 +0000 (00:17 +0100)] 
dns-stream: only read DNS packet data if we identified the peer properly

If we use TCP fastopen to connect to a DNS server via TCP, and it
responds really quickly between our connection attempt and our immediate
check back, then we have not identified the peer yet, and will not be
able to use the peer metadata to fill in our packet info.

Let's fix that, and simply not read from the socket until identification
is complete.

Fixes: #34956
(cherry picked from commit facc9439a76b4c3a5c273c71bd7a676e4c74778c)

8 months agoresolved: pick up new DNSSEC KSC from 2024
Lennart Poettering [Mon, 3 Mar 2025 21:40:05 +0000 (22:40 +0100)] 
resolved: pick up new DNSSEC KSC from 2024

Import thew new key from https://data.iana.org/root-anchors/root-anchors.xml.

The old one remains valid, as per provided data.

Fixes: #36260
(cherry picked from commit 8113361e82eea2741290f7117034d356acb3ab4d)

8 months agohwdb-util: drop unused value assignment
Yu Watanabe [Tue, 18 Feb 2025 18:46:55 +0000 (03:46 +0900)] 
hwdb-util: drop unused value assignment

The values assigned to 'r' were never used, and overwritten by the next
call of read_line_full().

Fixes CID#1548043 and CID#1548064.

(cherry picked from commit 00575cfd696a2a335decb66580727fafd3c152aa)

8 months agope-binary: fix array overrun
Yu Watanabe [Tue, 18 Feb 2025 18:09:38 +0000 (03:09 +0900)] 
pe-binary: fix array overrun

This is a kind of paranoia, as memeqzero() does not read anyting if
length is zero. But, strictly speaking C language does not allow such,
and Coverity warn about that.

Fixes CID#1561177.

(cherry picked from commit 6529ab0b066c93a6b8a8bf24b999d67e67a261f5)

8 months agope-binary: trivial coding style fixlets
Yu Watanabe [Tue, 18 Feb 2025 18:02:32 +0000 (03:02 +0900)] 
pe-binary: trivial coding style fixlets

(cherry picked from commit 2bf5d698d641afb1cec0b9ffb397722622afa8ea)

8 months agogenerator: insert parentheses to make the code clearer
Yu Watanabe [Tue, 18 Feb 2025 17:45:30 +0000 (02:45 +0900)] 
generator: insert parentheses to make the code clearer

Silence CID#1563781.

(cherry picked from commit 3428c4b818fcd303997deb0dbcaf7cea60942bcf)

8 months agoasync: voidify call of fsync()
Yu Watanabe [Tue, 18 Feb 2025 17:34:13 +0000 (02:34 +0900)] 
async: voidify call of fsync()

Fixes CID#1564787.

(cherry picked from commit b0e5cde687dacf885e4000da804ddcd900a83152)

8 months agoTEST-13-NSPAWN.nss-mymachines: Use negative matching switch
Michal Koutný [Tue, 25 Feb 2025 10:36:51 +0000 (11:36 +0100)] 
TEST-13-NSPAWN.nss-mymachines: Use negative matching switch

The test expects _not_ to find the patterns but the run_and_grep would
still print 'FAIL:' message. Use the dedicated -n option that inverts
the semantics cleaner than shell's !.

(cherry picked from commit c4b75966075e01d39556a87caa778eb63d96d6f6)

8 months agotests: remove cache=unsafe from TEST-64-UDEV-STORAGE
Jörg Behrmann [Sun, 2 Mar 2025 14:52:08 +0000 (15:52 +0100)] 
tests: remove cache=unsafe from TEST-64-UDEV-STORAGE

mkosi switch to the newer -blockdev qemu option in systemd/mkosi#3557 [1], but
cache=unsafe is an option only -drive supports.

Since the qemu-system_x86-64 man page [2] says this, cache.writeback=on is the
default and mkosi setting the other two options to the values corresponding to
unsafe, it should be fine to drop the cache=unsafe option.

┌─────────────┬─────────────────┬──────────────┬────────────────┐
│             │ cache.writeback │ cache.direct │ cache.no-flush │
├─────────────┼─────────────────┼──────────────┼────────────────┤
│writeback    │ on              │ off          │ off            │
├─────────────┼─────────────────┼──────────────┼────────────────┤
│none         │ on              │ on           │ off            │
├─────────────┼─────────────────┼──────────────┼────────────────┤
│writethrough │ off             │ off          │ off            │
├─────────────┼─────────────────┼──────────────┼────────────────┤
│directsync   │ off             │ on           │ off            │
├─────────────┼─────────────────┼──────────────┼────────────────┤
│unsafe       │ on              │ off          │ on             │
└─────────────┴─────────────────┴──────────────┴────────────────┘

[1] https://github.com/systemd/mkosi/pull/3557
[2] https://manpages.ubuntu.com/manpages/noble/en/man1/qemu-system-x86_64.1.html

(cherry picked from commit 759fdb3a35f96906de471b2c6c2bc2864dc25564)

8 months agosd-id128: gracefully handle systems where kernel keyring access is blocked
Lennart Poettering [Sun, 2 Mar 2025 06:51:05 +0000 (07:51 +0100)] 
sd-id128: gracefully handle systems where kernel keyring access is blocked

In various scenarios we invoke containers with access to the kernel
keyring blocked. Let's make sure we can handle this properly: when the
invocation ID is stored in in the kernel keyring and we try to read it
and get EPERM we should handle it gracefully, like EOPNOTSUPP.

(cherry picked from commit f2e38b01e052ebd50eaf98763bd9709e880c0a75)

8 months agovmspawn: switch from -drive to -blockdev option
Jörg Behrmann [Sun, 2 Mar 2025 15:07:54 +0000 (16:07 +0100)] 
vmspawn: switch from -drive to -blockdev option

(cherry picked from commit 369655330d57a82b6f346a77798968f135221c99)

8 months agobuild(deps): bump github/codeql-action from 3.27.5 to 3.28.10
dependabot[bot] [Sat, 1 Mar 2025 09:57:32 +0000 (09:57 +0000)] 
build(deps): bump github/codeql-action from 3.27.5 to 3.28.10

Bumps [github/codeql-action](https://github.com/github/codeql-action) from 3.27.5 to 3.28.10.
- [Release notes](https://github.com/github/codeql-action/releases)
- [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md)
- [Commits](https://github.com/github/codeql-action/compare/f09c1c0a94de965c15400f5634aa42fac8fb8f88...b56ba49b26e50535fa1e7f7db0f4f7b4bf65d80d)

---
updated-dependencies:
- dependency-name: github/codeql-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit a60cb5c4251a984423a68e35d9202ca758018030)

8 months agobuild(deps): bump redhat-plumbers-in-action/differential-shellcheck
dependabot[bot] [Sat, 1 Mar 2025 09:57:22 +0000 (09:57 +0000)] 
build(deps): bump redhat-plumbers-in-action/differential-shellcheck

Bumps [redhat-plumbers-in-action/differential-shellcheck](https://github.com/redhat-plumbers-in-action/differential-shellcheck) from 5.4.0 to 5.5.3.
- [Release notes](https://github.com/redhat-plumbers-in-action/differential-shellcheck/releases)
- [Changelog](https://github.com/redhat-plumbers-in-action/differential-shellcheck/blob/main/docs/CHANGELOG.md)
- [Commits](https://github.com/redhat-plumbers-in-action/differential-shellcheck/compare/cc6721c45a8800cc666de45493545a07a638d121...dd551ce780d8af741f8cd8bab6982667b906b457)

---
updated-dependencies:
- dependency-name: redhat-plumbers-in-action/differential-shellcheck
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit c736862058018859a5e3d4f827d2df8b49fb85e5)

8 months agotmpfiles: fix output value assignment
Yu Watanabe [Fri, 28 Feb 2025 11:25:05 +0000 (20:25 +0900)] 
tmpfiles: fix output value assignment

Fixes a bug in 7eeda1da90c79ba420a6d82c1d9589b23048d79f (v256).

(cherry picked from commit 914d1ec171eb0e27ced472aed2d05eae19b265da)

8 months agorecurse-dir: fix wrong assertion and error code in log
Yu Watanabe [Fri, 28 Feb 2025 11:22:42 +0000 (20:22 +0900)] 
recurse-dir: fix wrong assertion and error code in log

Fixes a bug in b5a07e524e42d2594174ca1a5b72aa4fdb9af94c (v250).

(cherry picked from commit 91421f8379b66316f937d56c60c2e782b7a79eca)

8 months agomachine-id-setup: bhyve also provides a uuid
Dan McGregor [Thu, 27 Feb 2025 22:18:23 +0000 (16:18 -0600)] 
machine-id-setup: bhyve also provides a uuid

When using UEFI with bhyve it behaves similarly to qemu, and provides
a product_uuid. Use it if found, just like with qemu.

(cherry picked from commit 113c159ba9c4e8052ae162e12faba28b102a90d0)

8 months agotest: Do not add integration tests if want_tests == 'false'
Daan De Meyer [Tue, 25 Feb 2025 09:59:20 +0000 (10:59 +0100)] 
test: Do not add integration tests if want_tests == 'false'

(cherry picked from commit 890e1ad3183458aa0337e4e6a1a9afa26d706e36)

8 months agolibfido2-util: accept cached pin in fido2_generate_hmac_hash()
Martin Wilck [Mon, 17 Feb 2025 17:40:35 +0000 (18:40 +0100)] 
libfido2-util: accept cached pin in fido2_generate_hmac_hash()

fido2_generate_hmac_hash() sets req->keyring to "fido2-pin" when
calling ask_password_auto(), suggesting that a key by this name
can be read from the kernel keyring. But the keyring is never
opened because the ASK_PASSWORD_ACCEPT_CACHED flag is not set.

Set ASK_PASSWORD_ACCEPT_CACHED to allow automated / scripted
setup of encrypted volumes with FIDO2. If the PIN turns out to
be invalid, clear ASK_PASSWORD_ACCEPT_CACHED to avoid retrying
and possible lockout.

(cherry picked from commit 505c2f21377019c058de16aa9e2d8db005e97e6f)

8 months agosbsign: Fix wrong variable being passed to log_error_errno()
Daan De Meyer [Wed, 26 Feb 2025 09:32:25 +0000 (10:32 +0100)] 
sbsign: Fix wrong variable being passed to log_error_errno()

(cherry picked from commit ba6a904442bd6b6e0fad9910fb5e69c44bddfa47)

8 months agoexec-invoke: Fix invalid use of error variable
Daan De Meyer [Wed, 26 Feb 2025 21:34:33 +0000 (22:34 +0100)] 
exec-invoke: Fix invalid use of error variable

Follow up for 406f1775017a5631bc91a1f53ac5e50f4fbfac0c

(cherry picked from commit f215835cb88fd18fca68561b8ff1149632939e94)

8 months agoexec-invoke: Fix unshare() error handling
Daan De Meyer [Wed, 26 Feb 2025 21:31:35 +0000 (22:31 +0100)] 
exec-invoke: Fix unshare() error handling

Follow up for cd58b5a13537fc89b669ff9232ba2206214c9fa1

(cherry picked from commit c78b06b1d23b95e4ea5f507a719bded6a2737581)

8 months agomeson: Add missing dbus_programs dependency on update-dbus-docs
Daan De Meyer [Wed, 26 Feb 2025 21:06:41 +0000 (22:06 +0100)] 
meson: Add missing dbus_programs dependency on update-dbus-docs

All dbus programs have to be up-to-date for update-dbus-docs to
produce the expected output, so add the missing dependency.

(cherry picked from commit 461bd9277a69833a534518c263d00443f2f6fbf4)

8 months agocore/service: do not propagate reload for combined RELOADING=1 + READY=1 when notify...
Mike Yuan [Wed, 26 Feb 2025 14:02:58 +0000 (15:02 +0100)] 
core/service: do not propagate reload for combined RELOADING=1 + READY=1 when notify-reload

Follow-up for 3bd28bf721dc70722ff1c675026ed0b44ad968a3

SERVICE_RELOAD_SIGNAL state can only be reached via explicit reload jobs,
and we have a clear distinction between that and plain RELOADING=1
notifications, the latter of which is issued by clients doing reload
outside of our job engine. I.e. upon SERVICE_RELOAD_SIGNAL + RELOADING=1
we don't propagate reload jobs again, since that's done during transaction
construction stage already. The handling of combined RELOADING=1 + READY=1
so far is bogus however, as it tries to propagate duplicate reload jobs.
Amend this by following the logic for standalone RELOADING=1.

(cherry picked from commit c337a1301f2de4105fc8023e45db20238c6a895a)

8 months agodocs: Use mkosi -R instead of mkosi -t none
Daan De Meyer [Wed, 26 Feb 2025 13:58:53 +0000 (14:58 +0100)] 
docs: Use mkosi -R instead of mkosi -t none

mkosi now supports -R to rerun build scripts without rebuilding the
image so let's document that instead of the current hack to prevent
the rebuild by changing the output format.

(cherry picked from commit 031a474c916758f906ed556c7d2ea3e92ff481a6)

8 months agomkosi: Update to latest
Daan De Meyer [Wed, 26 Feb 2025 13:58:39 +0000 (14:58 +0100)] 
mkosi: Update to latest

(cherry picked from commit 6ccb14af882673dd488ec86ef9f9e8421b126300)

8 months agoimport/pull-tar: fix flag set
Antonio Alvarez Feijoo [Wed, 26 Feb 2025 10:14:17 +0000 (11:14 +0100)] 
import/pull-tar: fix flag set

There is a typo passing flags to `install_file()`, if `IMPORT_READ_ONLY` is set,
`IMPORT_SYNC` is never checked.

(cherry picked from commit 5d2d0c055b1ec68d4fc5d4ec85390fc427171ff3)

8 months agotpm2-setup: add missing O_CLOEXEC at two places
Lennart Poettering [Wed, 26 Feb 2025 08:10:16 +0000 (09:10 +0100)] 
tpm2-setup: add missing O_CLOEXEC at two places

(cherry picked from commit f4e5a730002fa7ed714b89775c3e5fae6d003aae)

8 months agocopy: Invoke hardlink context cleanup before restoring timestamps
Andreas Stührk [Tue, 25 Feb 2025 23:05:41 +0000 (00:05 +0100)] 
copy: Invoke hardlink context cleanup before restoring timestamps

When hardlink recreation is requested, it creates temporary files that
will be deleted once the context is destroyed. The deletion
(potentially) updates the directory's timestamps, so it's crucial that
the deletion happens before the directory timestamps are restored when
`COPY_RESTORE_DIRECTORY_TIMESTAMPS` is requested.

(cherry picked from commit b66291444b8d4022ce68121af8e6f99d29ebefd0)

8 months agopackit: Switch to meson.version for the current version
Daan De Meyer [Tue, 25 Feb 2025 11:01:53 +0000 (12:01 +0100)] 
packit: Switch to meson.version for the current version

(cherry picked from commit 6a558625162591b34f6daf7e8878d79f78e3e8be)

8 months agomkosi: update fedora commit reference
Daan De Meyer [Tue, 25 Feb 2025 18:30:42 +0000 (19:30 +0100)] 
mkosi: update fedora commit reference

9b6884d2e1 Stop using version_no_tilde for github archives
5671cf6132 List the fallback Source0 first

(cherry picked from commit 89a5ea6583840261896b2d5e8ac60dedde7da422)

8 months agomkosi: Enable History= option
Daan De Meyer [Mon, 24 Feb 2025 09:56:26 +0000 (10:56 +0100)] 
mkosi: Enable History= option

This option makes mkosi "remember" all the CLI options specified on
the command line when building an image. This means they don't need
to be specified again when booting the image afterwards or doing any
other operation on the image with "mkosi xxx".

As an example of how this is useful, currently, when running "mkosi
-d opensuse -f" to build an opensuse image and then running "mkosi
sandbox -- meson test -C build TEST-86-MULTI-UKI-PROFILE", running
the test will try to add virtiofs mounts of the fedora~rawhide build
directory on my machine instead of the opensuse one. With the History=
option enabled, it will use the opensuse tumbleweed directory as expected.

We stop setting --extra-search-path and --output-dir in the integration test
wrapper as these are settings that are "remembered" by enabling the History=
option.

(cherry picked from commit 75cf5b0d3a6045e72dacd90f90ae14fa6d817be1)

8 months agoTEST-64-UDEV-STORAGE: Stop using mkosi configure scripts
Daan De Meyer [Mon, 24 Feb 2025 16:14:01 +0000 (17:14 +0100)] 
TEST-64-UDEV-STORAGE: Stop using mkosi configure scripts

Now that we have mkosi sandbox, meson runs with the mkosi tools tree
mounted (if one is used at all), so we can implement all the qemu feature
checks in meson itself, removing the need for mkosi configure scripts.

(cherry picked from commit ba29de84cf3967ac3b06707348493d5ddc65c7d8)

8 months agoTEST-53-ISSUE-16347: Implement rtc via custom argument
Daan De Meyer [Mon, 24 Feb 2025 16:12:22 +0000 (17:12 +0100)] 
TEST-53-ISSUE-16347: Implement rtc via custom argument

Let's get rid of the configure script for this use case by just
implementing the necessary logic in integration-test-wrapper.py.
We need to get rid of our usage of configure scripts to allow enabling
the History= setting.

(cherry picked from commit 2db2cb3034e71600d25ab1c181f692265d3833fe)

8 months agomkosi: Update to latest
Daan De Meyer [Mon, 24 Feb 2025 21:24:52 +0000 (22:24 +0100)] 
mkosi: Update to latest

(cherry picked from commit 4b8edc68f9f4111ccb5ba40c048431874ce8afab)

8 months agorepart: when using erofs and log level is not debug, use --quiet
Luca Boccassi [Sun, 23 Feb 2025 19:05:24 +0000 (19:05 +0000)] 
repart: when using erofs and log level is not debug, use --quiet

mkfs.erofs is extremely verbose and will log every single file added
to the filesystem, which is a lot of them when building a rootfs.

(cherry picked from commit 323213cfea8b78d44f63b8a83f74fbd1f79f1775)

8 months agofuzz: tentatively disable fuzz-compress on oss-fuzz
Yu Watanabe [Sat, 22 Feb 2025 20:34:55 +0000 (05:34 +0900)] 
fuzz: tentatively disable fuzz-compress on oss-fuzz

It does not work on oss-fuzz for some reasons. See #11018.

(cherry picked from commit 0656b3a083b48a2cccb90ee1f7fed949d9283b76)

8 months agotest: split VM-only subtests from TEST-74-AUX-UTILS to new VM-only test
Luca Boccassi [Thu, 21 Nov 2024 09:51:14 +0000 (09:51 +0000)] 
test: split VM-only subtests from TEST-74-AUX-UTILS to new VM-only test

TEST-74-AUX-UTILS covers many subtests, as it's a catch-all job, and a few
need a VM to run. The job is thus marked VM-only. But that means in settings
where we can't run VM tests (no KVM available), the entire thing is skipped,
losing tons of coverage that doesn't need skipping.

Move the VM-only subtests to TEST-87-AUX-UTILS-VM that is configured to only
run in VMs under both runners. This way we keep the existing tests as-is, and
we can add new VM-only tests without worrying. This is how the rest of the
tests are organized.

Follow-up for f4faac20730cbb339ae05ed6e20da687a2868e76

(cherry picked from commit 3f9539a97f3b4747ff22a530bac39dec24ac58af)

8 months agofuzz: decompress_startswith() may return zero
Yu Watanabe [Sat, 22 Feb 2025 19:59:46 +0000 (04:59 +0900)] 
fuzz: decompress_startswith() may return zero

Fixes #36472.

(cherry picked from commit 339f2f2eeb883b201f59076900e3bee7ff143460)

9 months agotest-network: add test case for KeepConfiguration=yes with RTPROT_BOOT
Yu Watanabe [Mon, 17 Feb 2025 17:05:07 +0000 (02:05 +0900)] 
test-network: add test case for KeepConfiguration=yes with RTPROT_BOOT

For issue #36411.

(cherry picked from commit 1cac0676dafb45c64940c36d7d75ce1e04eb831c)

9 months agonetwork/route: do not remove any foreign routes when KeepConfiguration=yes
Yu Watanabe [Mon, 17 Feb 2025 17:08:10 +0000 (02:08 +0900)] 
network/route: do not remove any foreign routes when KeepConfiguration=yes

Without this change, only foreign routes with RTPROT_KERNEL, RTPROT_STATIC,
RTPROT_DHCP, RTPROT_RA, and RTPROT_REDIRECT are kept, and foreign routes with
other protocol e.g. RTPROT_BOOT are removed even if KeepConfiguration=yes.

Fixes a regression in dd6d53a8dc58c5e6e310b09ba7f7a22600a87ba9 (v257).
Fixes #36411.

(cherry picked from commit 724faccf45b6933bb30c56cf99acf6373fffbc70)

9 months agosbsign: Don't set bit in SpcPeImageData->flags
Daan De Meyer [Fri, 21 Feb 2025 21:41:26 +0000 (22:41 +0100)] 
sbsign: Don't set bit in SpcPeImageData->flags

Neither sbsign nor pesign set this flag in SpcPeImageData->flags,
which is about which resources should be included specifying "Which
portions of the Windows PE file are hashed." according to the
authenticode spec. However, this is followed by "Although flags is
always present, it is ignored when calculating the file hash for both
signing and verification purposes". So as it doesn't seem to do
anything useful and the other tools don't set any of these flags
either, let's follow suite and not set this flag ourselves either.

(cherry picked from commit 66584a9335f9a3be5666209ddb34ae7d7f547189)

9 months agodocs/CONTROL_GROUP_INTERFACE: fix typo
Lin Jian [Fri, 21 Feb 2025 13:07:27 +0000 (21:07 +0800)] 
docs/CONTROL_GROUP_INTERFACE: fix typo

(cherry picked from commit 7593173c947d7ac2a4a890c570501034f3a4f9b1)

9 months agodocs: Clarify that login1 signals are not emitted for convenience objects
Philip Withnall [Thu, 20 Feb 2025 18:15:43 +0000 (18:15 +0000)] 
docs: Clarify that login1 signals are not emitted for convenience objects

While this is obvious if you spend a few minutes thinking about how
D-Bus signals work (in this case, they are broadcast from a system
service, so cannot apply to a specific user/session/seat), it’s a bit
easy to overlook this while putting code together which uses the login1
D-Bus API, so it’s helpful to point this hazard out specifically in the
docs.

The signals can only be emitted on the canonical objects. The
convenience objects are useful for method calls, as the calling context
can be used to dereference ‘self’ and ‘auto’, but this can’t work for
signals.

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
(cherry picked from commit 82b32b997c51e259ddf66a0ec6bd7631b0ea781d)

9 months agodocs: Fix some confusing wording in various D-Bus docs
Philip Withnall [Thu, 20 Feb 2025 18:13:00 +0000 (18:13 +0000)] 
docs: Fix some confusing wording in various D-Bus docs

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
(cherry picked from commit 5fe4edd3fccd2a14ec3488daeac80ddb33bc71db)

9 months agoman: fix typo in systemd.watchdog_device kernel option
Ahmad Fatoum [Thu, 20 Feb 2025 11:53:49 +0000 (12:53 +0100)] 
man: fix typo in systemd.watchdog_device kernel option

The option that systemd actually looks for has an underscore and no dash
as can be seen in src/core/main.c.

The man/kernel-command-line.xml documentation also gets it right with
this file being the only instance of watchdog-device being used.

Fixes: c75396c30bd9 ("documentation: add description for watchdog device path")
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
(cherry picked from commit 6f8a9d0917d6fe42c674466bffead9ac19db98e9)

9 months agotools/dbus_exporter: set LD_ORIGIN_PATH if procfs is not available
Luca Boccassi [Fri, 8 Nov 2024 22:41:09 +0000 (22:41 +0000)] 
tools/dbus_exporter: set LD_ORIGIN_PATH if procfs is not available

The script runs the binaries which try to find the internal libs via /proc/self/exe due
to glibc's RPATH resolution and fail:

/var/cache/src/systemd/tools/dbus_exporter.py interfaces
 /var/cache/src/systemd/build/systemd
 /var/cache/src/systemd/build/systemd-homed
 /var/cache/src/systemd/build/systemd-hostnamed
 /var/cache/src/systemd/build/systemd-importd
 /var/cache/src/systemd/build/systemd-localed
 /var/cache/src/systemd/build/systemd-logind
 /var/cache/src/systemd/build/systemd-machined
 /var/cache/src/systemd/build/systemd-networkd
 /var/cache/src/systemd/build/systemd-oomd
 /var/cache/src/systemd/build/systemd-portabled
 /var/cache/src/systemd/build/systemd-resolved
 /var/cache/src/systemd/build/systemd-sysupdated
 /var/cache/src/systemd/build/systemd-timedated
execve("/var/cache/src/systemd/build/systemd", ["/var/cache/src/systemd/build/sys"..., "--bus-introspect", "list"], 0x7ffc7ab68600 /* 20 vars */) = 0
brk(NULL)                               = 0x56265bf70000
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f56ced7f000
readlinkat(AT_FDCWD, "/proc/self/exe", 0x7ffedeaa7a90, 4096) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=20293, ...}) = 0
mmap(NULL, 20293, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f56ced7a000
close(3)                                = 0
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/x86_64-linux-gnu/", {st_mode=S_IFDIR|0755, st_size=19312, ...}, 0) = 0
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v4/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v3/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/glibc-hwcaps/x86-64-v2/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/", {st_mode=S_IFDIR|0755, st_size=19312, ...}, 0) = 0
openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v4/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v4/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v3/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v3/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v2/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/glibc-hwcaps/x86-64-v2/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/lib/", {st_mode=S_IFDIR|0755, st_size=642, ...}, 0) = 0
openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v4/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v4/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v3/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v3/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v2/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/glibc-hwcaps/x86-64-v2/", 0x7ffedeaa80b0, 0) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/libsystemd-core-258.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
newfstatat(AT_FDCWD, "/usr/lib/", {st_mode=S_IFDIR|0755, st_size=642, ...}, 0) = 0
writev(2, [{iov_base="/var/cache/src/systemd/build/sys"..., iov_len=36},
           {iov_base=": ", iov_len=2},
           {iov_base="error while loading shared libra"..., iov_len=36},
           {iov_base=": ", iov_len=2},
           {iov_base="libsystemd-core-258.so", iov_len=22},
           {iov_base=": ", iov_len=2},
           {iov_base="cannot open shared object file", iov_len=30},
           {iov_base=": ", iov_len=2},
           {iov_base="No such file or directory", iov_len=25},
           {iov_base="\n", iov_len=1}],
           10/var/cache/src/systemd/build/systemd: error while loading shared libraries: libsystemd-core-258.so: cannot open shared object file: No such file or directory
) = 158

(cherry picked from commit c6a932fd0db5bfcc523d0a57351b906bce2955cd)

9 months agoshell completion: add kernel-identify/inspect verbs for bootctl
Luca Boccassi [Tue, 18 Feb 2025 21:15:08 +0000 (21:15 +0000)] 
shell completion: add kernel-identify/inspect verbs for bootctl

Follow-up for a05255981ba5b04f1cf54ea656fbce1dfd9c3a68
Follow-up for 3e0a3a0259324b4c40a9a62c8506fe683cd0273b

(cherry picked from commit 6a6d4c3f3c123a1cbb6770f1cae8c130a48333e1)

9 months agoukify: print all remaining log-like output to stderr
Luca Boccassi [Mon, 17 Feb 2025 19:44:15 +0000 (19:44 +0000)] 
ukify: print all remaining log-like output to stderr

We want to be able to capture stdout for json and such, so convert
all remaining logging to stderr.

(cherry picked from commit cf4deeaf1e822ade5c1fbbe2584b23a2d0988439)

9 months agoUpdate footer.html to 2025
Anthony Avina [Mon, 17 Feb 2025 19:33:42 +0000 (13:33 -0600)] 
Update footer.html to 2025

Updating footer to reflect current year: 2025

(cherry picked from commit 1bcb739f080a56ab578129d9a87e061d92059eb5)

9 months agodissect: fix log_debug_errno assert due to r=0
Luca Boccassi [Mon, 17 Feb 2025 01:04:33 +0000 (01:04 +0000)] 
dissect: fix log_debug_errno assert due to r=0

systemd-dissect[612]: Assertion '(_error) != 0' failed at src/shared/dissect-image.c:3436, function dissected_image_load_verity_sig_partition(). Aborting.

(cherry picked from commit 135640c140ba32915b97d23e8d6c1cc3fd6c6a2a)

9 months agoman/networkd.conf: add missing whitespace between words
Louis Sautier [Sat, 15 Feb 2025 23:05:13 +0000 (00:05 +0100)] 
man/networkd.conf: add missing whitespace between words

Signed-off-by: Louis Sautier <sautier.louis@gmail.com>
(cherry picked from commit 24af6a0d0afcce3268ff60b7fea2f203cd820985)

9 months agoukify: if the specified kernel is not a valid PE file try to decompress it
Luca Boccassi [Thu, 13 Feb 2025 19:44:12 +0000 (19:44 +0000)] 
ukify: if the specified kernel is not a valid PE file try to decompress it

On some distros on some architectures (e.g.: Ubuntu arm64) the kernel is shipped as
a gzipped file, which the UEFI firmware does not understand.
If pefile fails to parse it, try to decompress it.

(cherry picked from commit 0dd03215f1e402092f6c6da213708045e445a9ed)

9 months agoukify: fix zboot parsing with zstd
Luca Boccassi [Thu, 13 Feb 2025 19:43:00 +0000 (19:43 +0000)] 
ukify: fix zboot parsing with zstd

The header starts with 'zstd', not 'zstd22':

$ ukify build --linux vmlinuz-6.13+unreleased-cloud-arm64 --initrd /boot/initrd.img-6.12.12-amd64 --output uki
Kernel version not specified, starting autodetection 😖.
Real-Mode Kernel Header magic not found
+ readelf --notes vmlinuz-6.13+unreleased-cloud-arm64
readelf: Error: Not an ELF file - it has the wrong magic bytes at the start
Traceback (most recent call last):
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 2510, in <module>
    main()
    ~~~~^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 2499, in main
    make_uki(opts)
    ~~~~~~~~^^^^^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 1328, in make_uki
    opts.uname = Uname.scrape(linux, opts=opts)
                 ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 384, in scrape
    version = func(filename, opts=opts)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 374, in scrape_generic
    text = maybe_decompress(filename)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 221, in maybe_decompress
    return get_zboot_kernel(f)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 201, in get_zboot_kernel
    raise NotImplementedError(f'unknown compressed type: {comp_type!r}')
NotImplementedError: unknown compressed type: b'zstd\x00\x00'

(cherry picked from commit a6d51ae582c863c01c581f1e31492910d53b0427)

9 months agoukify: switch from zstd to zstandard
Luca Boccassi [Thu, 13 Feb 2025 19:38:45 +0000 (19:38 +0000)] 
ukify: switch from zstd to zstandard

The zstd library does not support stream decompression, and it
requires the zstd header to contain extra metadata, that the kernel
build does not append:

$ file -k vmlinuz-6.13+unreleased-cloud-arm64
vmlinuz-6.13+unreleased-cloud-arm64: PE32+ executable (EFI application) Aarch64 (stripped to external PDB), for MS Windows, 2 sections\012- data
$ ukify build --linux vmlinuz-6.13+unreleased-cloud-arm64 --initrd /boot/initrd.img-6.12.12-amd64 --output uki
Kernel version not specified, starting autodetection 😖.
Real-Mode Kernel Header magic not found
+ readelf --notes vmlinuz-6.13+unreleased-cloud-arm64
readelf: Error: Not an ELF file - it has the wrong magic bytes at the start
Traceback (most recent call last):
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 2508, in <module>
    main()
    ~~~~^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 2497, in main
    make_uki(opts)
    ~~~~~~~~^^^^^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 1326, in make_uki
    opts.uname = Uname.scrape(linux, opts=opts)
                 ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 382, in scrape
    version = func(filename, opts=opts)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 372, in scrape_generic
    text = maybe_decompress(filename)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 219, in maybe_decompress
    return get_zboot_kernel(f)
  File "/home/bluca/git/systemd/src/ukify/ukify.py", line 199, in get_zboot_kernel
    return cast(bytes, zstd.uncompress(f.read(size)))
                       ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^
zstd.Error: Input data invalid or missing content size in frame header.

This appears to be by design:

https://github.com/sergey-dryabzhinsky/python-zstd/issues/53

Switch to python3-zstandard, which works.

(cherry picked from commit fbc6fecf1adbd34bd541c04d04ceef2695caa80a)

9 months agosysupdate: Don't use compression extension for UKIs in manpage
Daan De Meyer [Thu, 13 Feb 2025 12:03:39 +0000 (13:03 +0100)] 
sysupdate: Don't use compression extension for UKIs in manpage

UKIs should generally not be compressed since the kernel image and
initrd in them will already be compressed so let's remove the compression
suffix from the examples in the sysupdate manpage.

(cherry picked from commit 5ca1865ad95a10b744321d21293587ed1d446ee6)

9 months agobasic/linux: update kernel headers from v6.14-rc1
Yu Watanabe [Thu, 6 Feb 2025 10:41:27 +0000 (19:41 +0900)] 
basic/linux: update kernel headers from v6.14-rc1

Co-authored-by: Rudi Heitbaum <rudi@heitbaum.com>
(cherry picked from commit 0d879453acdc86b0d742c5854420c116d0f23ba4)

9 months agobasic/linux: update kernel headers from v6.13-rc6
Yu Watanabe [Mon, 6 Jan 2025 14:10:22 +0000 (23:10 +0900)] 
basic/linux: update kernel headers from v6.13-rc6

This also removes README and moves the explanation about the header
modification to the script.

(cherry picked from commit 62e9cd6b09f835d3e1ebc686b3fe055107ed823e)

9 months agomkosi: update fedora commit reference
Daan De Meyer [Wed, 19 Feb 2025 12:46:47 +0000 (13:46 +0100)] 
mkosi: update fedora commit reference

6c7c4a510d Do not use dynamic spec generation for non-upstream builds
6201755b36 Allow co-installation of systemd-sysusers-standalone and systemd
eba1721678 Split out -sysusers and -shared
ac9c438e27 Use dynamic spec generation for triggers
3671a5cc79 Move more auxiliary files into subpackages
5c40e08728 Remove patch that is already upstream
49ec9f3286 Move some files into subpackages
2c0b984bf4 Version 257.3
d66f997915 Add explicit BR: libxcrypt-devel
1ffa7bf7c7 Make Georgian mapping patch downstream-only
de4ae54a34 Backport PR #36194 to add Georgian mapping to kbd-model-map
cc9bce7893 Drop override of $PATH in the user manager
d0973df863 Backport patch to emit audit events from systemd-sysusers
e54ec2f978 Trim changelog entries that are not relevant to users

(cherry picked from commit 759abb6d523fd619916c1ad9d1832fe5c8dd3043)

9 months agomkosi: update fedora commit reference
Zbigniew Jędrzejewski-Szmek [Thu, 16 Jan 2025 21:26:30 +0000 (22:26 +0100)] 
mkosi: update fedora commit reference

c7fecc18eb Skip test_sysusers_defined on upstream builds
f257050ddd Add a .editorconfig file
aa5546e9ed Add a few mkosi artifact directories to .gitignore
01e5bc1c93 Set SBAT in sd-boot when building on OBS
a7eec4d33d Run upstream integration test suite with Fedora CI

(cherry picked from commit 6e1b24820fb6eae83cb8935867d4ef846cc36428)

9 months agomkosi: update fedora commit reference
Daan De Meyer [Mon, 13 Jan 2025 15:18:33 +0000 (16:18 +0100)] 
mkosi: update fedora commit reference

fd36e4c562 Rebuilt for the bin-sbin merge (2nd attempt)
cddeca136f Rebuilt for the bin-sbin merge (2nd attempt)
20cc578e59 Enable signing systemd-boot on OBS builds
b1bd57ecce Revert use of PrivateTmp=disconnected
30f50b1870 Drop patch numbers
1814bfe794 remove STI test
3a9c32b8a9 Version 257.2
4df2711a9f Add bcond for OBS-specific quirks
e570cd53df spec: drop trailing whitespace
c7379c9460 Replace 'udevadm hwdb' with systemd-hwdb
3386f5d704 Rename source .abignore file
fd860fd12d Drop a build dependency on a linter package: pytest-flakes
133ae30e33 Drop patches based on %upstream macro instead of patch number
e157552c6c Always build in release mode
fc47a92e4a Re-enable upstream behaviour of systemd-tmpfiles --purge
62abb21906 Version 257.1
35e6814ef4 Add patch for test-time-util
bd8339bf00 sysusers: support new ! line flag for creating fully locked accounts
c2f5f4a68a Version 257
31aaef8e17 Enable slow tests during build

(cherry picked from commit 9876c273907bf07290056f67500ac2bf069b6d9c)

9 months agomkosi: update arch commit reference
Daan De Meyer [Tue, 18 Feb 2025 13:16:28 +0000 (14:16 +0100)] 
mkosi: update arch commit reference

1b4994657d return if not a git repository (skip backports and reverts)
9d3374e98b move patch up
2416b7d81c upgpkg: 257.3-1: new upstream release

(cherry picked from commit 840ce150a65e12ae1a2639c107d8e178b9b89f7b)

9 months agomkosi: update arch commit reference
Daan De Meyer [Mon, 13 Jan 2025 15:11:07 +0000 (16:11 +0100)] 
mkosi: update arch commit reference

8160e63e52 Limit logic required for building locally
3a62443e41 OBS build: add support for xz and zst compression formats
9667464ad7 Get rid of _tag variable
73dc492b5e upgpkg: 257.2-2: rebuild with changes for service restart
6b7355b5bb do not restart any templated units
332718f955 exclude vmspawn units from restart as well
5a749a6716 exclude systemd-nspawn@* services from restart
8a10796f8b upgpkg: 257.2-1: new upstream release
16294a0b44 Add support for building from git in OBS
38b664eed4 upgpkg: 257.1-1: new upstream release
e26158dda9 upgpkg: 257-1: new upstream release
c984b75c3f restart services after upgrade...
27fae2c192 upgpkg: 256.9-1: new upstream release
1afdd08a60 upgpkg: 256.8-2: apply: shutdown: close DM block device before issuing DM_DEV_REMOVE ioctl

(cherry picked from commit 55455280dad6eff628b014f5df5e640f850a651b)