1
0
mirror of https://github.com/systemd/systemd.git synced 2025-01-07 21:18:41 +03:00
Commit Graph

78360 Commits

Author SHA1 Message Date
wrvsrx
09664a2759
Merge 1b8cf8baf3 into 1737bc0c1e 2024-12-30 19:59:30 +01:00
Luca Boccassi
1737bc0c1e
mkosi: switch to github mirror of openSUSE sources from build.opensuse.org (#35789)
The commit history of
[src.opensuse.org](https://src.opensuse.org/pool/systemd/src/branch/devel)
has been reset again to 2015 (both branches, factory and devel)... this
is unusable for now. I'd suggest switching to the github mirror of
code.opensuse.org, maintained since 2019 (at least github is not down
that often and the commit history does not change).
2024-12-30 18:42:29 +00:00
Antonio Alvarez Feijoo
07638ce2a4
mkosi: switch to github mirror of openSUSE sources from build.opensuse.org
The current src.opensuse.org is very unstable and commit hashes are reset (or
even removed) every now and then. While the official repo is not fixed, let's
move to a more stable source, the github mirror of code.opensuse.org, maintained
since 2019.
2024-12-30 17:39:16 +01:00
Antonio Alvarez Feijoo
8a6ad7c837
mkosi: add libopenssl devel package to openSUSE tools tree
Otherwise, the build fails with:

```
INFO: autodetecting backend as ninja
INFO: calculating backend command to run: /usr/bin/ninja -C /mnt/work/src/systemd/upstream-fork/main/build-mkosi
ninja: Entering directory `/mnt/work/src/systemd/upstream-fork/main/build-mkosi'
[463/2561] Compiling C object src/shared/libsystemd-shared-258.a.p/openssl-util.c.o
FAILED: src/shared/libsystemd-shared-258.a.p/openssl-util.c.o
cc -Isrc/shared/libsystemd-shared-258.a.p -Isrc/shared -I../src/shared -Isrc/basic -I../src/basic -Isrc/fundamental -I../src/fundamental -Isrc/systemd -I../src/systemd -I. -I.. -I../src/libsystemd/sd-bus -I../src/libsystemd/sd-device -I../src/libsystemd/sd-event -I../src/libsystemd/sd-hwdb -I../src/libsystemd/sd-id128 -I../src/libsystemd/sd-journal -I../src/libsystemd/sd-json -I../src/libsystemd/sd-netlink -I../src/libsystemd/sd-network -I../src/libsystemd/sd-path -I../src/libsystemd/sd-resolve -I../src/libsystemd/sd-varlink -I/usr/include/blkid -I/usr/include/libmount -I/usr/include/p11-kit-1 -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=gnu11 -O0 -g -Wno-missing-field-initializers -Wno-unused-parameter -Wno-nonnull-compare -Warray-bounds -Warray-bounds=2 -Wdate-time -Wendif-labels -Werror=format=2 -Werror=format-signedness -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Werror=missing-declarations -Werror=missing-prototypes -Werror=overflow -Werror=override-init -Werror=return-type -Werror=shift-count-overflow -Werror=shift-overflow=2 -Werror=strict-flex-arrays -Werror=undef -Wfloat-equal -Wimplicit-fallthrough=5 -Winit-self -Wlogical-op -Wmissing-include-dirs -Wmissing-noreturn -Wnested-externs -Wold-style-definition -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-aliasing=2 -Wstrict-prototypes -Wsuggest-attribute=noreturn -Wunused-function -Wwrite-strings -Wzero-length-bounds -fdiagnostics-show-option -fno-common -fstack-protector -fstack-protector-strong -fstrict-flex-arrays=3 --param=ssp-buffer-size=4 -Wno-unused-result -Werror=shadow -fPIC -fno-strict-aliasing -fstrict-flex-arrays=1 -fvisibility=hidden -fno-omit-frame-pointer -include config.h -pthread -fvisibility=default -MD -MQ src/shared/libsystemd-shared-258.a.p/openssl-util.c.o -MF src/shared/libsystemd-shared-258.a.p/openssl-util.c.o.d -o src/shared/libsystemd-shared-258.a.p/openssl-util.c.o -c ../src/shared/openssl-util.c
../src/shared/openssl-util.c: In function ‘openssl_ask_password_ui_read’:
../src/shared/openssl-util.c:1395:65: error: implicit declaration of function ‘UI_method_get_ex_data’; did you mean ‘UI_method_get_reader’? [-Wimplicit-function-declaration]
 1395 |                 AskPasswordRequest *req = (AskPasswordRequest*) UI_method_get_ex_data(UI_get_method(ui), 0);
      |                                                                 ^~~~~~~~~~~~~~~~~~~~~
      |                                                                 UI_method_get_reader
../src/shared/openssl-util.c:1395:65: warning: nested extern declaration of ‘UI_method_get_ex_data’ [-Wnested-externs]
../src/shared/openssl-util.c:1395:43: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast]
 1395 |                 AskPasswordRequest *req = (AskPasswordRequest*) UI_method_get_ex_data(UI_get_method(ui), 0);
      |                                           ^
../src/shared/openssl-util.c: In function ‘openssl_ask_password_ui_new’:
../src/shared/openssl-util.c:1479:13: error: implicit declaration of function ‘UI_method_set_ex_data’; did you mean ‘UI_method_set_reader’? [-Wimplicit-function-declaration]
 1479 |         if (UI_method_set_ex_data(ui->method, 0, &ui->request) == 0)
      |             ^~~~~~~~~~~~~~~~~~~~~
      |             UI_method_set_reader
../src/shared/openssl-util.c:1479:13: warning: nested extern declaration of ‘UI_method_set_ex_data’ [-Wnested-externs]
[480/2561] Compiling C object src/shared/libsystemd-shared-258.a.p/pkcs11-util.c.o
ninja: build stopped: subcommand failed.
```
2024-12-30 17:38:36 +01:00
Mike Yuan
25a306f6c4
Follow-ups for recent PRs plus modernizations prompted thereby (#35760)
Please backport the first commit to stable.
2024-12-30 16:35:59 +01:00
Antonio Alvarez Feijoo
37c2be73e7 mkosi: update openSUSE commit reference
Force-pushed as usual, now HEAD is v257.1.
2024-12-30 11:31:38 +00:00
Antonio Alvarez Feijoo
84624d8c99 ukify: fix typos 2024-12-30 10:50:25 +00:00
cvlc12
2cc58b6c8a man: change "secureboot-private-key.pem" filename for consistency 2024-12-30 09:14:29 +09:00
Michal Sekletar
f1a0f311e6 man: adjust description of PrivateUsers= so it is in line with reality
When the option is not available unit will not even start so there is
no security risk.

Fixes #34983
2024-12-29 14:38:00 +09:00
Mike Yuan
1e4e557262
tree-wide: replace FLAGS_SET(..., 1 << v) with BIT_SET(..., v) 2024-12-28 15:08:00 +01:00
Mike Yuan
382f3438d9
shared/condition: use BIT_SET where appropriate 2024-12-28 15:08:00 +01:00
Mike Yuan
6f3854fd63
capability-util: make CAPABILITY_QUINTET_NULL const, introduce capability_quintet_is_fully_set() helper
Follow-up for 1184626a26

See 9bb64f1b8d for rationale
of the first change.
2024-12-28 15:08:00 +01:00
Mike Yuan
d5e12dc75e
capability-util: minor modernizations 2024-12-28 15:08:00 +01:00
Mike Yuan
3217fd5915
sd-varlink: add missing error check in sd_varlink_listen_auto()
Follow-up for 50994b2f91
2024-12-28 14:49:22 +01:00
Mike Yuan
5ce8d7d839
core/unit-serialize: fix serialization of markers
Follow-up for ff68472a20
2024-12-28 14:49:17 +01:00
Yu Watanabe
80797bbb91 locale-setup: do not load locale from environemnt when /etc/locale.conf is unchanged
Previously, when /etc/locale.conf is unchanged, locales were loaded from
possibly outdated environment variable.

Fixes a bug introduced by 018befcff6 (v253).
Fixes #35717.
2024-12-28 12:04:01 +00:00
Yu Watanabe
51a0a3b049 machine: GC machine when no leader PID is set
After d8854ff1ac, if a serialized
leader PID of a machine is already dead when deserialized, then the
leader PID and PIDFD are unset for the machine, and subsequent
machine_start() -> machine_watch_pidfd() will trigger an assertion.
This makes a Machine object without leader PID GCed.

Fixes a bug introduced by the combination of
d8854ff1ac (v255) and
1762c2c045 (v257).

Fixes #35602.
2024-12-28 12:03:20 +00:00
Yu Watanabe
8bc4a6e5cd TEST-74-AUX: add reproducer of issue #35746
Addresses https://github.com/systemd/systemd/pull/35752#pullrequestreview-2523080117.
2024-12-28 12:02:13 +00:00
Yu Watanabe
084f361b50 systemctl: also ignore ENOENT in checking inhibitors
Fixes a bug caused by 804874d26a.
Follow-up for a1417e5563.
Fixes #35757.
2024-12-28 12:00:22 +00:00
Yu Watanabe
156f90cf62
logs-show: skip journal entry with an invalid timestamp (#35774)
Fixes #35737.
2024-12-28 20:34:15 +09:00
Yu Watanabe
ac3f3026a9 string-util: modernize split_pair()
- use _cleanup_free_ attribute,
- rename output arguments,
- trigger assertion when an empty separator is passed.
2024-12-28 16:16:27 +09:00
Yu Watanabe
27c992dd9f fuzz-journal-remote: use ASSERT_OK() and friends 2024-12-28 14:17:47 +09:00
Yu Watanabe
f19f640513 logs-show: skip journal entry with an invalid timestamp
Follow-up for 275e6be052.
Fixes oss-fuzz#385221809 (https://issues.oss-fuzz.com/issues/385221809).
Fixes #35737.
2024-12-28 14:13:39 +09:00
Yu Watanabe
f587da03c2
Grammar fixes to manpages (#35753)
Fix some missing commas, missing conjunction words, wrong
inflections, and trim excess parenthesizing.
2024-12-28 12:46:56 +09:00
Alexander Krabler
8207345140 docs: Clarify requirement 2024-12-28 12:24:42 +09:00
Luca Boccassi
842a674d4f creds: fix use-after-free in varlink interface
All other usages of sd_varlink_call* do not free the json return parameter,
and it is owned by the varlink object instead. Do the same here.

TEST-54-CREDS.sh[1074]: ==1074==ERROR: AddressSanitizer: heap-use-after-free on address 0x50c00000095a at pc 0x55cf8cd18a0f bp 0x7ffd7b9d4f10 sp 0x7ffd7b9d4f08
TEST-54-CREDS.sh[1074]: READ of size 2 at 0x50c00000095a thread T0 ((sd-mkdcreds))
TEST-54-CREDS.sh[1074]:     #0 0x55cf8cd18a0e in sd_json_variant_unref /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:887:16
TEST-54-CREDS.sh[1074]:     #1 0x55cf8cd4cecb in varlink_clear_current /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:593:22
TEST-54-CREDS.sh[1074]:     #2 0x55cf8cd4975e in varlink_clear /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:614:9
TEST-54-CREDS.sh[1074]:     #3 0x55cf8cd3dc3c in varlink_destroy /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:651:9
TEST-54-CREDS.sh[1074]:     #4 0x55cf8cd3dc3c in sd_varlink_unref /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:657:1
TEST-54-CREDS.sh[1074]:     #5 0x55cf8cb47a82 in sd_varlink_unrefp /usr/src/debug/systemd/src/systemd/sd-varlink.h:279:1
TEST-54-CREDS.sh[1074]:     #6 0x55cf8cb47a82 in ipc_decrypt_credential /usr/src/debug/systemd/src/shared/creds-util.c:1660:1
TEST-54-CREDS.sh[1074]:     #7 0x55cf8caca99a in maybe_decrypt_and_write_credential /usr/src/debug/systemd/src/core/exec-credential.c:486:29
TEST-54-CREDS.sh[1074]:     #8 0x55cf8cac790b in load_credential /usr/src/debug/systemd/src/core/exec-credential.c:713:16
TEST-54-CREDS.sh[1074]:     #9 0x55cf8cac5403 in acquire_credentials /usr/src/debug/systemd/src/core/exec-credential.c:819:29
TEST-54-CREDS.sh[1074]:     #10 0x55cf8cac5403 in setup_credentials_internal /usr/src/debug/systemd/src/core/exec-credential.c:1023:13
TEST-54-CREDS.sh[1074]:     #11 0x55cf8cac42d4 in exec_setup_credentials /usr/src/debug/systemd/src/core/exec-credential.c:1168:21
TEST-54-CREDS.sh[1074]:     #12 0x55cf8ca59569 in exec_invoke /usr/src/debug/systemd/src/core/exec-invoke.c:4866:13
TEST-54-CREDS.sh[1074]:     #13 0x55cf8ca428d8 in run /usr/src/debug/systemd/src/core/executor.c:244:13
TEST-54-CREDS.sh[1074]:     #14 0x55cf8ca428d8 in main /usr/src/debug/systemd/src/core/executor.c:275:13
TEST-54-CREDS.sh[1074]:     #15 0x7f64b40110c7 in __libc_start_call_main (/lib64/libc.so.6+0x40c7) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #16 0x7f64b401118a in __libc_start_main@GLIBC_2.2.5 (/lib64/libc.so.6+0x418a) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #17 0x55cf8ca41cb4  (/usr/lib/systemd/systemd-executor+0x124cb4) (BuildId: 24f2b1608c3aaee3226cdd14fa2b6e6741156222)
TEST-54-CREDS.sh[1074]: 0x50c00000095a is located 26 bytes inside of 120-byte region [0x50c000000940,0x50c0000009b8)
TEST-54-CREDS.sh[1074]: freed by thread T0 ((sd-mkdcreds)) here:
TEST-54-CREDS.sh[1074]:     #0 0x7f64b48d57ea in free (/usr/lib/clang/19/lib/x86_64-redhat-linux-gnu/libclang_rt.asan.so+0xd57ea) (BuildId: c59bbd28ceb74038a60373d4a8cd4c258bcf0b4e)
TEST-54-CREDS.sh[1074]:     #1 0x55cf8cd188ab in sd_json_variant_unref /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:895:25
TEST-54-CREDS.sh[1074]:     #2 0x55cf8cb47a4c in sd_json_variant_unrefp /usr/src/debug/systemd/src/systemd/sd-json.h:98:1
TEST-54-CREDS.sh[1074]:     #3 0x55cf8cb47a4c in ipc_decrypt_credential /usr/src/debug/systemd/src/shared/creds-util.c:1660:1
TEST-54-CREDS.sh[1074]:     #4 0x55cf8caca99a in maybe_decrypt_and_write_credential /usr/src/debug/systemd/src/core/exec-credential.c:486:29
TEST-54-CREDS.sh[1074]:     #5 0x55cf8cac790b in load_credential /usr/src/debug/systemd/src/core/exec-credential.c:713:16
TEST-54-CREDS.sh[1074]:     #6 0x55cf8cac5403 in acquire_credentials /usr/src/debug/systemd/src/core/exec-credential.c:819:29
TEST-54-CREDS.sh[1074]:     #7 0x55cf8cac5403 in setup_credentials_internal /usr/src/debug/systemd/src/core/exec-credential.c:1023:13
TEST-54-CREDS.sh[1074]:     #8 0x55cf8cac42d4 in exec_setup_credentials /usr/src/debug/systemd/src/core/exec-credential.c:1168:21
TEST-54-CREDS.sh[1074]:     #9 0x55cf8ca59569 in exec_invoke /usr/src/debug/systemd/src/core/exec-invoke.c:4866:13
TEST-54-CREDS.sh[1074]:     #10 0x55cf8ca428d8 in run /usr/src/debug/systemd/src/core/executor.c:244:13
TEST-54-CREDS.sh[1074]:     #11 0x55cf8ca428d8 in main /usr/src/debug/systemd/src/core/executor.c:275:13
TEST-54-CREDS.sh[1074]:     #12 0x7f64b40110c7 in __libc_start_call_main (/lib64/libc.so.6+0x40c7) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #13 0x7f64b401118a in __libc_start_main@GLIBC_2.2.5 (/lib64/libc.so.6+0x418a) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #14 0x55cf8ca41cb4  (/usr/lib/systemd/systemd-executor+0x124cb4) (BuildId: 24f2b1608c3aaee3226cdd14fa2b6e6741156222)
TEST-54-CREDS.sh[1074]: previously allocated by thread T0 ((sd-mkdcreds)) here:
TEST-54-CREDS.sh[1074]:     #0 0x7f64b48d5a83 in malloc (/usr/lib/clang/19/lib/x86_64-redhat-linux-gnu/libclang_rt.asan.so+0xd5a83) (BuildId: c59bbd28ceb74038a60373d4a8cd4c258bcf0b4e)
TEST-54-CREDS.sh[1074]:     #1 0x55cf8cd16bb7 in malloc_multiply /usr/src/debug/systemd/src/basic/alloc-util.h:119:16
TEST-54-CREDS.sh[1074]:     #2 0x55cf8cd16bb7 in sd_json_variant_new_object /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:737:13
TEST-54-CREDS.sh[1074]:     #3 0x55cf8cd32e58 in json_parse_internal /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:3161:29
TEST-54-CREDS.sh[1074]:     #4 0x55cf8cd37326 in sd_json_parse_with_source /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:3408:16
TEST-54-CREDS.sh[1074]:     #5 0x55cf8cd37326 in sd_json_parse /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:3437:16
TEST-54-CREDS.sh[1074]:     #6 0x55cf8cd3f753 in varlink_parse_message /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:962:13
TEST-54-CREDS.sh[1074]:     #7 0x55cf8cd3f753 in sd_varlink_process /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:1466:13
TEST-54-CREDS.sh[1074]:     #8 0x55cf8cd4c0a9 in sd_varlink_call_full /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:2160:21
TEST-54-CREDS.sh[1074]:     #9 0x55cf8cd4d617 in sd_varlink_callb_ap /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:2237:16
TEST-54-CREDS.sh[1074]:     #10 0x55cf8cd4da3c in sd_varlink_callb /usr/src/debug/systemd/src/libsystemd/sd-varlink/sd-varlink.c:2251:13
TEST-54-CREDS.sh[1074]:     #11 0x55cf8cb47686 in ipc_decrypt_credential /usr/src/debug/systemd/src/shared/creds-util.c:1623:13
TEST-54-CREDS.sh[1074]:     #12 0x55cf8caca99a in maybe_decrypt_and_write_credential /usr/src/debug/systemd/src/core/exec-credential.c:486:29
TEST-54-CREDS.sh[1074]:     #13 0x55cf8cac790b in load_credential /usr/src/debug/systemd/src/core/exec-credential.c:713:16
TEST-54-CREDS.sh[1074]:     #14 0x55cf8cac5403 in acquire_credentials /usr/src/debug/systemd/src/core/exec-credential.c:819:29
TEST-54-CREDS.sh[1074]:     #15 0x55cf8cac5403 in setup_credentials_internal /usr/src/debug/systemd/src/core/exec-credential.c:1023:13
TEST-54-CREDS.sh[1074]:     #16 0x55cf8cac42d4 in exec_setup_credentials /usr/src/debug/systemd/src/core/exec-credential.c:1168:21
TEST-54-CREDS.sh[1074]:     #17 0x55cf8ca59569 in exec_invoke /usr/src/debug/systemd/src/core/exec-invoke.c:4866:13
TEST-54-CREDS.sh[1074]:     #18 0x55cf8ca428d8 in run /usr/src/debug/systemd/src/core/executor.c:244:13
TEST-54-CREDS.sh[1074]:     #19 0x55cf8ca428d8 in main /usr/src/debug/systemd/src/core/executor.c:275:13
TEST-54-CREDS.sh[1074]:     #20 0x7f64b40110c7 in __libc_start_call_main (/lib64/libc.so.6+0x40c7) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #21 0x7f64b401118a in __libc_start_main@GLIBC_2.2.5 (/lib64/libc.so.6+0x418a) (BuildId: 159846287d47eef88f2a478f59803f6e8fc81d05)
TEST-54-CREDS.sh[1074]:     #22 0x55cf8ca41cb4  (/usr/lib/systemd/systemd-executor+0x124cb4) (BuildId: 24f2b1608c3aaee3226cdd14fa2b6e6741156222)
TEST-54-CREDS.sh[1074]: SUMMARY: AddressSanitizer: heap-use-after-free /usr/src/debug/systemd/src/libsystemd/sd-json/sd-json.c:887:16 in sd_json_variant_unref
TEST-54-CREDS.sh[1074]: Shadow bytes around the buggy address:
TEST-54-CREDS.sh[1074]:   0x50c000000680: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000700: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd
TEST-54-CREDS.sh[1074]:   0x50c000000780: fa fa fa fa fa fa fa fa 00 00 00 00 00 00 00 00
TEST-54-CREDS.sh[1074]:   0x50c000000800: 00 00 00 00 00 00 00 00 fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000880: fd fd fd fd fd fd fd fd fd fd fd fd fd fd fd fa
TEST-54-CREDS.sh[1074]: =>0x50c000000900: fa fa fa fa fa fa fa fa fd fd fd[fd]fd fd fd fd
TEST-54-CREDS.sh[1074]:   0x50c000000980: fd fd fd fd fd fd fd fa fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000a00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000a80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000b00: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]:   0x50c000000b80: fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa fa
TEST-54-CREDS.sh[1074]: Shadow byte legend (one shadow byte represents 8 application bytes):
TEST-54-CREDS.sh[1074]:   Addressable:           00
TEST-54-CREDS.sh[1074]:   Partially addressable: 01 02 03 04 05 06 07
TEST-54-CREDS.sh[1074]:   Heap left redzone:       fa
TEST-54-CREDS.sh[1074]:   Freed heap region:       fd
TEST-54-CREDS.sh[1074]:   Stack left redzone:      f1
TEST-54-CREDS.sh[1074]:   Stack mid redzone:       f2
TEST-54-CREDS.sh[1074]:   Stack right redzone:     f3
TEST-54-CREDS.sh[1074]:   Stack after return:      f5
TEST-54-CREDS.sh[1074]:   Stack use after scope:   f8
TEST-54-CREDS.sh[1074]:   Global redzone:          f9
TEST-54-CREDS.sh[1074]:   Global init order:       f6
TEST-54-CREDS.sh[1074]:   Poisoned by user:        f7
TEST-54-CREDS.sh[1074]:   Container overflow:      fc
TEST-54-CREDS.sh[1074]:   Array cookie:            ac
TEST-54-CREDS.sh[1074]:   Intra object redzone:    bb
TEST-54-CREDS.sh[1074]:   ASan internal:           fe
TEST-54-CREDS.sh[1074]:   Left alloca redzone:     ca
TEST-54-CREDS.sh[1074]:   Right alloca redzone:    cb

Follow-up for 2c3cbc5c01
2024-12-27 17:28:56 +00:00
Luca Boccassi
4db0252c7f mkosi: update opensuse spec repo commit 2024-12-26 13:35:29 +00:00
Luca Boccassi
34fcd36388
tree-wide: add missing header for glibc < 2.34 (#35756)
`unistd.h` gets into the dependency tree via
`/usr/include/bits/sigstksz.h`, which was added with glibc-2.34.
2024-12-26 12:24:26 +00:00
Daan De Meyer
3737cd4a46
ptyfwd: fix draining on exit (#35752)
Fixes a bug introduced by #35663.
Fixes #35746.
2024-12-26 11:53:46 +01:00
Antonio Alvarez Feijoo
7cb72bdaeb
udevd: add missing header for glibc < 2.34
```
[77/1697] Compiling C object udevadm.p/src_udev_udevd.c.o
FAILED: udevadm.p/src_udev_udevd.c.o
cc -Iudevadm.p -I. -I.. -Isrc/basic -I../src/basic -Isrc/fundamental -I../src/fundamental -Isrc/systemd -I../src/systemd -I../src/libsystemd/sd-bus -I../src/libsystemd/sd-device -I../src/libsystemd/sd-event -I../src/libsystemd/sd-hwdb -I../src/libsystemd/sd-id128 -I../src/libsystemd/sd-journal -I../src/libsystemd/sd-json -I../src/libsystemd/sd-netlink -I../src/libsystemd/sd-network -I../src/libsystemd/sd-path -I../src/libsystemd/sd-resolve -I../src/libsystemd/sd-varlink -Isrc/shared -I../src/shared -I/usr/include/blkid -I/usr/include/kmod -fdiagnostics-color=always -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -Wextra -std=gnu11 -O0 -g -Wno-missing-field-initializers -Wno-unused-parameter -Wno-nonnull-compare -Warray-bounds -Warray-bounds=2 -Wdate-time -Wendif-labels -Werror=format=2 -Werror=format-signedness -Werror=implicit-function-declaration -Werror=implicit-int -Werror=incompatible-pointer-types -Werror=int-conversion -Werror=missing-declarations -Werror=missing-prototypes -Werror=overflow -Werror=override-init -Werror=return-type -Werror=shift-count-overflow -Werror=shift-overflow=2 -Werror=undef -Wfloat-equal -Wimplicit-fallthrough=5 -Winit-self -Wlogical-op -Wmissing-include-dirs -Wmissing-noreturn -Wnested-externs -Wold-style-definition -Wpointer-arith -Wredundant-decls -Wshadow -Wstrict-aliasing=2 -Wstrict-prototypes -Wsuggest-attribute=noreturn -Wunused-function -Wwrite-strings -Wzero-length-bounds -fdiagnostics-show-option -fno-common -fstack-protector -fstack-protector-strong --param=ssp-buffer-size=4 -Wno-unused-result -Werror=shadow -fno-strict-aliasing -fvisibility=hidden -fno-omit-frame-pointer -include config.h -pthread -MD -MQ udevadm.p/src_udev_udevd.c.o -MF udevadm.p/src_udev_udevd.c.o.d -o udevadm.p/src_udev_udevd.c.o -c ../src/udev/udevd.c
../src/udev/udevd.c: In function ‘run_udevd’:
../src/udev/udevd.c:67:23: error: implicit declaration of function ‘fork’ [-Werror=implicit-function-declaration]
   67 |                 pid = fork();
      |                       ^~~~
../src/udev/udevd.c:75:24: error: implicit declaration of function ‘setsid’; did you mean ‘setbit’? [-Werror=implicit-function-declaration]
   75 |                 (void) setsid();
      |                        ^~~~~~
      |                        setbit
../src/udev/udevd.c:75:24: warning: nested extern declaration of ‘setsid’ [-Wnested-externs]
```

Follow-up for 394a678aec
2024-12-26 11:02:55 +01:00
Antonio Alvarez Feijoo
b1378b4c01
vmspawn-register: add missing header for glibc < 2.34
Fixes #35755
2024-12-26 11:02:34 +01:00
Jan Engelhardt
19740d330a man: grammar fixes for userdbctl(1) 2024-12-25 17:24:39 +01:00
Jan Engelhardt
84d3266de1 man: grammar fixes for varlinkctl(1)
Fix some missing commas, missing conjunction words, wrong
inflections, and trim excess parenthesizing.
2024-12-25 17:24:39 +01:00
Jan Engelhardt
c592ebdf4f man: grammar fixes for introductory adverbs/phrases 2024-12-25 17:24:38 +01:00
Jan Engelhardt
44855c77a1 man: expand word contractions
For written text, contractions are not normally used.
2024-12-25 17:00:31 +01:00
Jan Engelhardt
82ea392a99 man: grammar fixes for "regardless" 2024-12-25 17:00:31 +01:00
Jan Engelhardt
91dc2a52f5 man: grammar fixes: replace "respectively"
Unlike the German "bzw.", "respectively" cannot be used as an infix,
and is not abbreviated either.
2024-12-25 17:00:26 +01:00
Yu Watanabe
d3218c4c80 ptyfwd: try to drain on exit only once
Reading or writing a fd may fail with EBUSY, and the loop might run
without doing mostly nothing and the event loop may finish with ELOOP.
2024-12-25 17:51:42 +09:00
Yu Watanabe
7647378b74 ptyfwd,run: process remaining outputs in IO event sources
This partially reverts 12807b5a49.

Otherwise, reading or writing a fd in on_exit_event() handler may return
EBUSY, and the event loop may finish with -ELOOP.

Also, this makes drained() returns true if the PTY forwarder is already
disconnected, for safety. Hence, it is not necessary to re-introduce
pty_forward_is_done().
2024-12-25 17:50:15 +09:00
Yu Watanabe
bb4244f454 ptyfwd: fix infinite loop
This makes we exit from the loop in do_shovel() when
PTYForward.out_buffer_write_len is zero but PTYForward.out_buffer_full
is non-zero.

Fixes a bug introduced by 5e6a48bf99.
Fixes #35746.
2024-12-25 17:17:22 +09:00
Yu Watanabe
16bcf7e044
Drop legacy glibc version check and inclusion of linux/memfd.h (#35748) 2024-12-25 13:58:02 +09:00
Daan De Meyer
54b4ec8870 docs: Explicitly mention ~/.local/bin in section on installing mkosi 2024-12-25 13:54:11 +09:00
Daan De Meyer
ece81f339f docs: Use meson compile instead of ninja
"ninja -C build mkosi" doesn't actually work and fails because ninja
thinks the mkosi target does not exist. "meson compile -C build mkosi"
dpes work so let's use that instead.

Fixes #35741
2024-12-25 13:52:13 +09:00
Salvatore Cocuzza
2d94868970 po: Translated using Weblate (Italian)
Currently translated at 100.0% (257 of 257 strings)

Co-authored-by: Salvatore Cocuzza <info@salvatorecocuzza.it>
Translate-URL: https://translate.fedoraproject.org/projects/systemd/main/it/
Translation: systemd/main
2024-12-25 13:47:59 +09:00
Mike Yuan
c415a4816c
tree-wide: drop inclusion of linux/memfd.h
We carry our own definitions in missing_mman.h, and otherwise
sys/mman.h is employed. Let's drop the unneeded detection/inclusion
of linux/memfd.h hence.
2024-12-24 16:56:21 +01:00
Mike Yuan
3ac386de0a
basic/missing_threads: drop glibc < 2.16 check
glibc 2.16 has been our baseline for ~10y
(c.f. 3dd26f3e3a)
2024-12-24 16:55:21 +01:00
Ivan Kruglov
544b7718b3 machine: add debugging info to trace #35115 2024-12-23 16:38:22 +00:00
Yu Watanabe
8567f1342b meson: sort source files 2024-12-23 09:33:09 +01:00
Ani Sinha
fde7adab3b Use device3.xml for testing chid_match
device3.xml was not used. Use it now.
2024-12-22 18:29:03 +00:00
Thorsten Kukuk
50994b2f91 sd-varlink: add sd_varlink_server_listen_name (#35697) 2024-12-22 17:25:55 +00:00